From 4eb38e4cfd811c7f03d658ea73793acaf32ba0b2 Mon Sep 17 00:00:00 2001 From: knsv Date: Sun, 15 Nov 2015 15:06:24 +0100 Subject: [PATCH] Fix for issues #239 and #257. --- dist/mermaid.css | 2 +- dist/mermaid.forest.css | 2 +- dist/mermaid.js | 393 ++++++------------ dist/mermaid.min.js | 31 +- dist/mermaid.slim.js | 393 ++++++------------ dist/mermaid.slim.min.js | 13 +- dist/mermaidAPI.js | 385 ++++++----------- dist/mermaidAPI.min.js | 31 +- dist/mermaidAPI.slim.js | 385 ++++++----------- dist/mermaidAPI.slim.min.js | 20 +- docs/content/usage.md | 17 + scripts/watch.sh | 2 +- src/diagrams/classDiagram/classDb.js | 24 +- src/diagrams/classDiagram/classRenderer.js | 64 +-- src/diagrams/example/exampleDb.js | 2 +- src/diagrams/example/exampleRenderer.js | 2 +- src/diagrams/flowchart/dagre-d3.js | 2 +- src/diagrams/flowchart/flowRenderer.js | 2 +- src/diagrams/flowchart/graphDb.js | 2 +- src/diagrams/gantt/ganttDb.js | 2 +- src/diagrams/sequenceDiagram/sequenceDb.js | 2 +- .../sequenceDiagram/sequenceRenderer.js | 3 +- src/less/default/mermaid.less | 2 +- src/less/forest/mermaid.less | 2 +- src/logger.js | 34 +- src/mermaid.js | 4 +- src/mermaidAPI.js | 10 +- src/utils.js | 6 +- src/utils.spec.js | 2 +- test/examples/classDiagram.html | 2 +- 30 files changed, 680 insertions(+), 1161 deletions(-) diff --git a/dist/mermaid.css b/dist/mermaid.css index a6e540b716..b895e1b1ca 100644 --- a/dist/mermaid.css +++ b/dist/mermaid.css @@ -253,7 +253,7 @@ text.actor { */ text { font-family: 'trebuchet ms', verdana, arial; - font-size: 28px; + font-size: 14px; } div.mermaidTooltip { position: absolute; diff --git a/dist/mermaid.forest.css b/dist/mermaid.forest.css index 1ee3c2535c..71f8c3259d 100644 --- a/dist/mermaid.forest.css +++ b/dist/mermaid.forest.css @@ -333,7 +333,7 @@ svg .classLabel .label { } text { font-family: 'trebuchet ms', verdana, arial; - font-size: 28px; + font-size: 14px; } div.mermaidTooltip { position: absolute; diff --git a/dist/mermaid.js b/dist/mermaid.js index da3cea77ad..82db5095d5 100644 --- a/dist/mermaid.js +++ b/dist/mermaid.js @@ -31057,7 +31057,7 @@ module.exports={ "chalk": "^0.5.1", "d3": "3.5.6", "dagre": "^0.7.4", - "dagre-d3": "~0.4.8", + "dagre-d3": "0.4.10", "he": "^0.5.0", "minimist": "^1.1.0", "mkdirp": "^0.5.0", @@ -31604,21 +31604,15 @@ module.exports = d3; },{"d3":4}],109:[function(require,module,exports){ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var relations = []; -var classes = undefined; +var classes; var idCache; -if (typeof Map !== 'undefined') { - classes = new Map(); -} +classes = {}; + // Functions to be run after graph rendering var funs = []; /** @@ -31629,24 +31623,24 @@ var funs = []; * @param style */ exports.addClass = function (id) { - if (typeof classes.get(id) === 'undefined') { - classes.set(id, { + if (typeof classes[id] === 'undefined') { + classes[id] = { id: id, methods: [], members: [] - }); + }; } }; exports.clear = function () { relations = []; - classes.clear(); + classes = {}; }; module.exports.getClass = function (id) { - return classes.get(id); + return classes[id]; }; -module.exports.getClasses = function (id) { +module.exports.getClasses = function () { return classes; }; @@ -31663,7 +31657,7 @@ exports.addRelation = function (relation) { }; exports.addMembers = function (className, MembersArr) { - var theClass = classes.get(className); + var theClass = classes[className]; if (typeof MembersArr === 'string') { if (MembersArr.substr(-1) === ')') { theClass.methods.push(MembersArr); @@ -31701,29 +31695,17 @@ exports.relationType = { 'use strict'; -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - -var _dagre = require('dagre'); - -var dagre = _interopRequireWildcard(_dagre); - var cd = require('./parser/classDiagram').parser; var cDDb = require('./classDb'); cd.yy = cDDb; var d3 = require('../../d3'); - +var Logger = require('../../logger'); +var dagre = require('dagre'); var log = new Logger.Log(); var idCache; -if (typeof Map !== 'undefined') { - idCache = new Map(); -} +idCache = {}; + var classCnt = 0; var conf = { dividerMargin: 10, @@ -31733,39 +31715,19 @@ var conf = { // Todo optimize var getGraphId = function getGraphId(label) { - var _iteratorNormalCompletion = true; - var _didIteratorError = false; - var _iteratorError = undefined; + var keys = Object.keys(idCache); - try { - for (var _iterator = idCache[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { - var _step$value = _slicedToArray(_step.value, 2); - - var id = _step$value[0]; - var classInfo = _step$value[1]; - - if (classInfo.label === label) { - return id; - } - } - } catch (err) { - _didIteratorError = true; - _iteratorError = err; - } finally { - try { - if (!_iteratorNormalCompletion && _iterator['return']) { - _iterator['return'](); - } - } finally { - if (_didIteratorError) { - throw _iteratorError; - } + var i; + for (i = 0; i < keys.length; i++) { + if (idCache[keys[i]].label === label) { + return keys[i]; } } return undefined; }; +window.tunk = getGraphId; /** * Setup arrow head and define the marker. The result is appended to the svg. */ @@ -31895,34 +31857,34 @@ var drawClass = function drawClass(elem, classDef) { .attr('x', conf.padding).attr('y', titleHeight + conf.dividerMargin + conf.textHeight).attr('fill', 'white').attr('class', 'classText'); var isFirst = true; - var _iteratorNormalCompletion2 = true; - var _didIteratorError2 = false; - var _iteratorError2 = undefined; + var _iteratorNormalCompletion = true; + var _didIteratorError = false; + var _iteratorError = undefined; try { - for (var _iterator2 = classDef.members[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) { - var member = _step2.value; + for (var _iterator = classDef.members[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { + var member = _step.value; addTspan(members, member, isFirst); isFirst = false; } - - //console.warn(JSON.stringify(classDef)); } catch (err) { - _didIteratorError2 = true; - _iteratorError2 = err; + _didIteratorError = true; + _iteratorError = err; } finally { try { - if (!_iteratorNormalCompletion2 && _iterator2['return']) { - _iterator2['return'](); + if (!_iteratorNormalCompletion && _iterator['return']) { + _iterator['return'](); } } finally { - if (_didIteratorError2) { - throw _iteratorError2; + if (_didIteratorError) { + throw _iteratorError; } } } + console.warn(JSON.stringify(classDef)); + var membersBox = members.node().getBBox(); var methodsLine = g.append('line') // text label for the x axis @@ -31932,28 +31894,28 @@ var drawClass = function drawClass(elem, classDef) { .attr('x', conf.padding).attr('y', titleHeight + 2 * conf.dividerMargin + membersBox.height + conf.textHeight).attr('fill', 'white').attr('class', 'classText'); isFirst = true; - var _iteratorNormalCompletion3 = true; - var _didIteratorError3 = false; - var _iteratorError3 = undefined; + var _iteratorNormalCompletion2 = true; + var _didIteratorError2 = false; + var _iteratorError2 = undefined; try { - for (var _iterator3 = classDef.methods[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { - var method = _step3.value; + for (var _iterator2 = classDef.methods[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) { + var method = _step2.value; addTspan(methods, method, isFirst); isFirst = false; } } catch (err) { - _didIteratorError3 = true; - _iteratorError3 = err; + _didIteratorError2 = true; + _iteratorError2 = err; } finally { try { - if (!_iteratorNormalCompletion3 && _iterator3['return']) { - _iterator3['return'](); + if (!_iteratorNormalCompletion2 && _iterator2['return']) { + _iterator2['return'](); } } finally { - if (_didIteratorError3) { - throw _iteratorError3; + if (_didIteratorError2) { + throw _iteratorError2; } } } @@ -31967,7 +31929,8 @@ var drawClass = function drawClass(elem, classDef) { classInfo.width = classBox.width + 2 * conf.padding; classInfo.height = classBox.height + conf.padding + 0.5 * conf.dividerMargin; - idCache.set(id, classInfo); + console.warn('setting id: ' + id + ' to ' + JSON.stringify(classInfo)); + idCache[id] = classInfo; classCnt++; return classInfo; }; @@ -32011,75 +31974,60 @@ module.exports.draw = function (text, id) { }); var classes = cDDb.getClasses(); - var _iteratorNormalCompletion4 = true; - var _didIteratorError4 = false; - var _iteratorError4 = undefined; - - try { - for (var _iterator4 = classes.values()[Symbol.iterator](), _step4; !(_iteratorNormalCompletion4 = (_step4 = _iterator4.next()).done); _iteratorNormalCompletion4 = true) { - var classDef = _step4.value; - - var node = drawClass(diagram, classDef); - // Add nodes to the graph. The first argument is the node id. The second is - // metadata about the node. In this case we're going to add labels to each of - // our nodes. - g.setNode(node.id, node); - log.info('Org height: ' + node.height); - //g.setNode("swilliams", { label: "Saul Williams", width: 160, height: 100 }); - //g.setNode("bpitt", { label: "Brad Pitt", width: 108, height: 100 }); - //g.setNode("hford", { label: "Harrison Ford", width: 168, height: 100 }); - //g.setNode("lwilson", { label: "Luke Wilson", width: 144, height: 100 }); - //g.setNode("kbacon", { label: "Kevin Bacon", width: 121, height: 100 }); - } - } catch (err) { - _didIteratorError4 = true; - _iteratorError4 = err; - } finally { - try { - if (!_iteratorNormalCompletion4 && _iterator4['return']) { - _iterator4['return'](); - } - } finally { - if (_didIteratorError4) { - throw _iteratorError4; - } - } + var keys = Object.keys(classes); + var i; + for (i = 0; i < keys.length; i++) { + var classDef = classes[keys[i]]; + var node = drawClass(diagram, classDef); + // Add nodes to the graph. The first argument is the node id. The second is + // metadata about the node. In this case we're going to add labels to each of + // our nodes. + g.setNode(node.id, node); + log.info('Org height: ' + node.height); + //g.setNode("swilliams", { label: "Saul Williams", width: 160, height: 100 }); + //g.setNode("bpitt", { label: "Brad Pitt", width: 108, height: 100 }); + //g.setNode("hford", { label: "Harrison Ford", width: 168, height: 100 }); + //g.setNode("lwilson", { label: "Luke Wilson", width: 144, height: 100 }); + //g.setNode("kbacon", { label: "Kevin Bacon", width: 121, height: 100 }); } var relations = cDDb.getRelations(); var i = 0; - var _iteratorNormalCompletion5 = true; - var _didIteratorError5 = false; - var _iteratorError5 = undefined; + var _iteratorNormalCompletion3 = true; + var _didIteratorError3 = false; + var _iteratorError3 = undefined; try { - for (var _iterator5 = relations[Symbol.iterator](), _step5; !(_iteratorNormalCompletion5 = (_step5 = _iterator5.next()).done); _iteratorNormalCompletion5 = true) { - var relation = _step5.value; + for (var _iterator3 = relations[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { + var relation = _step3.value; i = i + 1; + log.info('tjoho' + getGraphId(relation.id1) + getGraphId(relation.id2) + JSON.stringify(relation)); g.setEdge(getGraphId(relation.id1), getGraphId(relation.id2), { relation: relation }); } } catch (err) { - _didIteratorError5 = true; - _iteratorError5 = err; + _didIteratorError3 = true; + _iteratorError3 = err; } finally { try { - if (!_iteratorNormalCompletion5 && _iterator5['return']) { - _iterator5['return'](); + if (!_iteratorNormalCompletion3 && _iterator3['return']) { + _iterator3['return'](); } } finally { - if (_didIteratorError5) { - throw _iteratorError5; + if (_didIteratorError3) { + throw _iteratorError3; } } } dagre.layout(g); g.nodes().forEach(function (v) { - log.debug('Node ' + v + ': ' + JSON.stringify(g.node(v))); - d3.select('#' + v).attr('transform', 'translate(' + (g.node(v).x - g.node(v).width / 2) + ',' + (g.node(v).y - g.node(v).height / 2) + ' )'); - //d3.select('#' +v +' rect').attr('x',(g.node(v).x-(g.node(v).width/2))) - //.attr('y',(g.node(v).y-(g.node(v).height/2))); + if (typeof v !== 'undefined') { + log.debug('Node ' + v + ': ' + JSON.stringify(g.node(v))); + d3.select('#' + v).attr('transform', 'translate(' + (g.node(v).x - g.node(v).width / 2) + ',' + (g.node(v).y - g.node(v).height / 2) + ' )'); + //d3.select('#' +v +' rect').attr('x',(g.node(v).x-(g.node(v).width/2))) + //.attr('y',(g.node(v).y-(g.node(v).height/2))); + } }); g.edges().forEach(function (e) { log.debug('Edge ' + e.v + ' -> ' + e.w + ': ' + JSON.stringify(g.edge(e))); @@ -32913,12 +32861,7 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var message = ''; @@ -32952,16 +32895,10 @@ exports.parseError = function (err, hash) { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var db = require('./exampleDb'); var exampleParser = require('./parser/example.js'); var d3 = require('../../d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); /** @@ -33645,12 +33582,7 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { /* global window */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var dagreD3; @@ -33676,18 +33608,12 @@ module.exports = dagreD3; */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var graph = require('./graphDb'); var flow = require('./parser/flow'); var dot = require('./parser/dot'); var d3 = require('../../d3'); var dagreD3 = require('./dagre-d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var conf = {}; @@ -34118,12 +34044,7 @@ exports.draw = function (text, id, isDot) { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var d3 = require('../../d3'); @@ -36453,14 +36374,8 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var moment = require('moment'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var dateFormat = ''; @@ -38689,17 +38604,11 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var actors = {}; var actorKeys = []; var messages = []; var notes = []; - +var Logger = require('../../logger'); var log = new Logger.Log(); exports.addActor = function (id, name, description) { @@ -38836,17 +38745,11 @@ exports.apply = function (param) { 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var sq = require('./parser/sequenceDiagram').parser; sq.yy = require('./sequenceDb'); var svgDraw = require('./svgDraw'); var d3 = require('../../d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var conf = { @@ -39453,10 +39356,6 @@ exports.getNoteRect = function () { 'use strict'; -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } - var LEVELS = { debug: 1, info: 2, @@ -39500,59 +39399,45 @@ function formatTime(timestamp) { return t; } -var Log = (function () { - function Log(level) { - _classCallCheck(this, Log); +function Log(level) { + this.level = level; - this.level = level; - } - - _createClass(Log, [{ - key: 'log', - value: function log(str, level) { - var logLevel = this.level; - if (typeof logLevel === 'undefined') { - logLevel = defaultLevel; - } - if (logLevel <= level) { - if (typeof console !== 'undefined') { + this.log = function (str, level) { + var logLevel = this.level; + if (typeof logLevel === 'undefined') { + logLevel = defaultLevel; + } + if (logLevel <= level) { + if (typeof console !== 'undefined') { + //eslint-disable-line no-console + if (typeof console.log !== 'undefined') { //eslint-disable-line no-console - if (typeof console.log !== 'undefined') { - //eslint-disable-line no-console - return console.log('[' + formatTime(new Date()) + '] ' + str); //eslint-disable-line no-console - } + return console.log('[' + formatTime(new Date()) + '] ' + str); //eslint-disable-line no-console } } } - }, { - key: 'trace', - value: function trace(str) { - this.log(str, LEVELS.trace); - } - }, { - key: 'debug', - value: function debug(str) { - this.log(str, LEVELS.debug); - } - }, { - key: 'info', - value: function info(str) { - this.log(str, LEVELS.info); - } - }, { - key: 'warn', - value: function warn(str) { - this.log(str, LEVELS.warn); - } - }, { - key: 'error', - value: function error(str) { - this.log(str, LEVELS.error); - } - }]); + }; - return Log; -})(); + this.trace = function (str) { + this.log(str, LEVELS.trace); + }; + + this.debug = function (str) { + this.log(str, LEVELS.debug); + }; + + this.info = function (str) { + this.log(str, LEVELS.info); + }; + + this.warn = function (str) { + this.log(str, LEVELS.warn); + }; + + this.error = function (str) { + this.log(str, LEVELS.error); + }; +} exports.Log = Log; @@ -39579,11 +39464,7 @@ exports.Log = Log; 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); +var Logger = require('./logger'); var log = new Logger.Log(); var mermaidAPI = require('./mermaidAPI'); @@ -39823,7 +39704,7 @@ if (typeof document !== 'undefined') { /*! * Wait for document loaded before starting the execution */ - document.addEventListener('DOMContentLoaded', function () { + window.addEventListener('load', function () { exports.contentLoaded(); }, false); } @@ -39850,12 +39731,7 @@ if (typeof document !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('./logger'); var log = new Logger.Log(); var graph = require('./diagrams/flowchart/graphDb'); @@ -40264,6 +40140,8 @@ var render = function render(id, txt, cb, container) { var svgCode = d3.select('#d' + id).node().innerHTML.replace(/url\(#arrowhead/g, 'url(' + url + '#arrowhead', 'g'); svgCode = exports.decodeEntities(svgCode); + console.warn('here'); + //console.warn('mermaid decode: '); //console.warn(svgCode); //var he = require('he'); @@ -40271,13 +40149,15 @@ var render = function render(id, txt, cb, container) { if (typeof cb !== 'undefined') { cb(svgCode, graph.bindFunctions); } else { - log.warn('CB = undefined'); + log.warn('CB = undefined!'); } var node = d3.select('#d' + id).node(); if (node !== null && typeof node.remove === 'function') { d3.select('#d' + id).node().remove(); } + + return svgCode; }; exports.render = function (id, text, cb, containerElement) { @@ -40285,7 +40165,7 @@ exports.render = function (id, text, cb, containerElement) { // Todo handle rendering serverside using phantomjs } else { // In browser - render(id, text, cb, containerElement); + return render(id, text, cb, containerElement); } }; @@ -40349,16 +40229,7 @@ global.mermaidAPI = { */ 'use strict'; -Object.defineProperty(exports, '__esModule', { - value: true -}); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('./logger'); var log = new Logger.Log(); /** diff --git a/dist/mermaid.min.js b/dist/mermaid.min.js index d480b97e36..a6747fb7fb 100644 --- a/dist/mermaid.min.js +++ b/dist/mermaid.min.js @@ -1,23 +1,22 @@ -!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.mermaid=t()}}(function(){var define,module,exports;return function t(e,n,r){function i(u,o){if(!n[u]){if(!e[u]){var s="function"==typeof require&&require;if(!o&&s)return s(u,!0);if(a)return a(u,!0);var c=new Error("Cannot find module '"+u+"'");throw c.code="MODULE_NOT_FOUND",c}var l=n[u]={exports:{}};e[u][0].call(l.exports,function(t){var n=e[u][1][t];return i(n?n:t)},l,l.exports,t,e,n,r)}return n[u].exports}for(var a="function"==typeof require&&require,u=0;u=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=-1&&!i;a--){var u=a>=0?arguments[a]:t.cwd();if("string"!=typeof u)throw new TypeError("Arguments to path.resolve must be strings");u&&(n=u+"/"+n,i="/"===u.charAt(0))}return n=e(r(n.split("/"),function(t){return!!t}),!i).join("/"),(i?"/":"")+n||"."},n.normalize=function(t){var i=n.isAbsolute(t),a="/"===u(t,-1);return t=e(r(t.split("/"),function(t){return!!t}),!i).join("/"),t||i||(t="."),t&&a&&(t+="/"),(i?"/":"")+t},n.isAbsolute=function(t){return"/"===t.charAt(0)},n.join=function(){var t=Array.prototype.slice.call(arguments,0);return n.normalize(r(t,function(t){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},n.relative=function(t,e){function r(t){for(var e=0;e=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=n.resolve(t).substr(1),e=n.resolve(e).substr(1);for(var i=r(t.split("/")),a=r(e.split("/")),u=Math.min(i.length,a.length),o=u,s=0;u>s;s++)if(i[s]!==a[s]){o=s;break}for(var c=[],s=o;se&&(e=t.length+e),t.substr(e,n)}}).call(this,t("_process"))},{_process:3}],3:[function(t,e){function n(){}var r=e.exports={};r.nextTick=function(){var t="undefined"!=typeof window&&window.setImmediate,e="undefined"!=typeof window&&window.MutationObserver,n="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(t)return function(t){return window.setImmediate(t)};var r=[];if(e){var i=document.createElement("div"),a=new MutationObserver(function(){var t=r.slice();r.length=0,t.forEach(function(t){t()})});return a.observe(i,{attributes:!0}),function(t){r.length||i.setAttribute("yes","no"),r.push(t)}}return n?(window.addEventListener("message",function(t){var e=t.source;if((e===window||null===e)&&"process-tick"===t.data&&(t.stopPropagation(),r.length>0)){var n=r.shift();n()}},!0),function(t){r.push(t),window.postMessage("process-tick","*")}):function(t){setTimeout(t,0)}}(),r.title="browser",r.browser=!0,r.env={},r.argv=[],r.on=n,r.addListener=n,r.once=n,r.off=n,r.removeListener=n,r.removeAllListeners=n,r.emit=n,r.binding=function(){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(){throw new Error("process.chdir is not supported")}},{}],4:[function(t,e){!function(){function t(t){return t&&(t.ownerDocument||t.document||t).documentElement}function n(t){return t&&(t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView)}function r(t,e){return e>t?-1:t>e?1:t>=e?0:0/0}function i(t){return null===t?0/0:+t}function a(t){return!isNaN(t)}function u(t){return{left:function(e,n,r,i){for(arguments.length<3&&(r=0),arguments.length<4&&(i=e.length);i>r;){var a=r+i>>>1;t(e[a],n)<0?r=a+1:i=a}return r},right:function(e,n,r,i){for(arguments.length<3&&(r=0),arguments.length<4&&(i=e.length);i>r;){var a=r+i>>>1;t(e[a],n)>0?i=a:r=a+1}return r}}}function o(t){return t.length}function s(t){for(var e=1;t*e%1;)e*=10;return e}function c(t,e){for(var n in e)Object.defineProperty(t.prototype,n,{value:e[n],enumerable:!1})}function l(){this._=Object.create(null)}function h(t){return(t+="")===gu||t[0]===yu?yu+t:t}function f(t){return(t+="")[0]===yu?t.slice(1):t}function d(t){return h(t)in this._}function p(t){return(t=h(t))in this._&&delete this._[t]}function g(){var t=[];for(var e in this._)t.push(f(e));return t}function y(){var t=0;for(var e in this._)++t;return t}function m(){for(var t in this._)return!1;return!0}function v(){this._=Object.create(null)}function b(t){return t}function _(t,e,n){return function(){var r=n.apply(e,arguments);return r===e?t:r}}function x(t,e){if(e in t)return e;e=e.charAt(0).toUpperCase()+e.slice(1);for(var n=0,r=mu.length;r>n;++n){var i=mu[n]+e;if(i in t)return i}}function w(){}function A(){}function E(t){function e(){for(var e,r=n,i=-1,a=r.length;++in;n++)for(var i,a=t[n],u=0,o=a.length;o>u;u++)(i=a[u])&&e(i,u,n);return t}function $(t){return bu(t,ku),t}function G(t){var e,n;return function(r,i,a){var u,o=t[a].update,s=o.length;for(a!=n&&(n=a,e=0),i>=e&&(e=i+1);!(u=o[e])&&++e0&&(t=t.slice(0,o));var c=Du.get(t);return c&&(t=c,s=Z),o?e?i:r:e?w:a}function W(t,e){return function(n){var r=nu.event;nu.event=n,e[0]=this.__data__;try{t.apply(this,e)}finally{nu.event=r}}}function Z(t,e){var n=W(t,e);return function(t){var e=this,r=t.relatedTarget;r&&(r===e||8&r.compareDocumentPosition(e))||n.call(e,t)}}function X(e){var r=".dragsuppress-"+ ++Mu,i="click"+r,a=nu.select(n(e)).on("touchmove"+r,k).on("dragstart"+r,k).on("selectstart"+r,k);if(null==Cu&&(Cu="onselectstart"in e?!1:x(e.style,"userSelect")),Cu){var u=t(e).style,o=u[Cu];u[Cu]="none"}return function(t){if(a.on(r,null),Cu&&(u[Cu]=o),t){var e=function(){a.on(i,null)};a.on(i,function(){k(),e()},!0),setTimeout(e,0)}}}function K(t,e){e.changedTouches&&(e=e.changedTouches[0]);var r=t.ownerSVGElement||t;if(r.createSVGPoint){var i=r.createSVGPoint();if(0>Su){var a=n(t);if(a.scrollX||a.scrollY){r=nu.select("body").append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important");var u=r[0][0].getScreenCTM();Su=!(u.f||u.e),r.remove()}}return Su?(i.x=e.pageX,i.y=e.pageY):(i.x=e.clientX,i.y=e.clientY),i=i.matrixTransform(t.getScreenCTM().inverse()),[i.x,i.y]}var o=t.getBoundingClientRect();return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}function J(){return nu.event.changedTouches[0].identifier}function Q(t){return t>0?1:0>t?-1:0}function tt(t,e,n){return(e[0]-t[0])*(n[1]-t[1])-(e[1]-t[1])*(n[0]-t[0])}function et(t){return t>1?0:-1>t?Bu:Math.acos(t)}function nt(t){return t>1?Nu:-1>t?-Nu:Math.asin(t)}function rt(t){return((t=Math.exp(t))-1/t)/2}function it(t){return((t=Math.exp(t))+1/t)/2}function at(t){return((t=Math.exp(2*t))-1)/(t+1)}function ut(t){return(t=Math.sin(t/2))*t}function ot(){}function st(t,e,n){return this instanceof st?(this.h=+t,this.s=+e,void(this.l=+n)):arguments.length<2?t instanceof st?new st(t.h,t.s,t.l):wt(""+t,At,st):new st(t,e,n)}function ct(t,e,n){function r(t){return t>360?t-=360:0>t&&(t+=360),60>t?a+(u-a)*t/60:180>t?u:240>t?a+(u-a)*(240-t)/60:a}function i(t){return Math.round(255*r(t))}var a,u;return t=isNaN(t)?0:(t%=360)<0?t+360:t,e=isNaN(e)?0:0>e?0:e>1?1:e,n=0>n?0:n>1?1:n,u=.5>=n?n*(1+e):n+e-n*e,a=2*n-u,new vt(i(t+120),i(t),i(t-120))}function lt(t,e,n){return this instanceof lt?(this.h=+t,this.c=+e,void(this.l=+n)):arguments.length<2?t instanceof lt?new lt(t.h,t.c,t.l):t instanceof ft?pt(t.l,t.a,t.b):pt((t=Et((t=nu.rgb(t)).r,t.g,t.b)).l,t.a,t.b):new lt(t,e,n)}function ht(t,e,n){return isNaN(t)&&(t=0),isNaN(e)&&(e=0),new ft(n,Math.cos(t*=Iu)*e,Math.sin(t)*e)}function ft(t,e,n){return this instanceof ft?(this.l=+t,this.a=+e,void(this.b=+n)):arguments.length<2?t instanceof ft?new ft(t.l,t.a,t.b):t instanceof lt?ht(t.h,t.c,t.l):Et((t=vt(t)).r,t.g,t.b):new ft(t,e,n)}function dt(t,e,n){var r=(t+16)/116,i=r+e/500,a=r-n/200;return i=gt(i)*Hu,r=gt(r)*Wu,a=gt(a)*Zu,new vt(mt(3.2404542*i-1.5371385*r-.4985314*a),mt(-.969266*i+1.8760108*r+.041556*a),mt(.0556434*i-.2040259*r+1.0572252*a))}function pt(t,e,n){return t>0?new lt(Math.atan2(n,e)*Pu,Math.sqrt(e*e+n*n),t):new lt(0/0,0/0,t)}function gt(t){return t>.206893034?t*t*t:(t-4/29)/7.787037}function yt(t){return t>.008856?Math.pow(t,1/3):7.787037*t+4/29}function mt(t){return Math.round(255*(.00304>=t?12.92*t:1.055*Math.pow(t,1/2.4)-.055))}function vt(t,e,n){return this instanceof vt?(this.r=~~t,this.g=~~e,void(this.b=~~n)):arguments.length<2?t instanceof vt?new vt(t.r,t.g,t.b):wt(""+t,vt,ct):new vt(t,e,n)}function bt(t){return new vt(t>>16,t>>8&255,255&t)}function _t(t){return bt(t)+""}function xt(t){return 16>t?"0"+Math.max(0,t).toString(16):Math.min(255,t).toString(16)}function wt(t,e,n){t=t.toLowerCase();var r,i,a,u=0,o=0,s=0;if(r=/([a-z]+)\((.*)\)/.exec(t))switch(i=r[2].split(","),r[1]){case"hsl":return n(parseFloat(i[0]),parseFloat(i[1])/100,parseFloat(i[2])/100);case"rgb":return e(Dt(i[0]),Dt(i[1]),Dt(i[2]))}return(a=Ju.get(t))?e(a.r,a.g,a.b):(null==t||"#"!==t.charAt(0)||isNaN(a=parseInt(t.slice(1),16))||(4===t.length?(u=(3840&a)>>4,u=u>>4|u,o=240&a,o=o>>4|o,s=15&a,s=s<<4|s):7===t.length&&(u=(16711680&a)>>16,o=(65280&a)>>8,s=255&a)),e(u,o,s))}function At(t,e,n){var r,i,a=Math.min(t/=255,e/=255,n/=255),u=Math.max(t,e,n),o=u-a,s=(u+a)/2;return o?(i=.5>s?o/(u+a):o/(2-u-a),r=t==u?(e-n)/o+(n>e?6:0):e==u?(n-t)/o+2:(t-e)/o+4,r*=60):(r=0/0,i=s>0&&1>s?0:r),new st(r,i,s)}function Et(t,e,n){t=kt(t),e=kt(e),n=kt(n);var r=yt((.4124564*t+.3575761*e+.1804375*n)/Hu),i=yt((.2126729*t+.7151522*e+.072175*n)/Wu),a=yt((.0193339*t+.119192*e+.9503041*n)/Zu);return ft(116*i-16,500*(r-i),200*(i-a))}function kt(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Dt(t){var e=parseFloat(t);return"%"===t.charAt(t.length-1)?Math.round(2.55*e):e}function Ct(t){return"function"==typeof t?t:function(){return t}}function Mt(t){return function(e,n,r){return 2===arguments.length&&"function"==typeof n&&(r=n,n=null),St(e,n,t,r)}}function St(t,e,n,r){function i(){var t,e=s.status;if(!e&&Ft(s)||e>=200&&300>e||304===e){try{t=n.call(a,s)}catch(r){return void u.error.call(a,r)}u.load.call(a,t)}else u.error.call(a,s)}var a={},u=nu.dispatch("beforesend","progress","load","error"),o={},s=new XMLHttpRequest,c=null;return!this.XDomainRequest||"withCredentials"in s||!/^(http(s)?:)?\/\//.test(t)||(s=new XDomainRequest),"onload"in s?s.onload=s.onerror=i:s.onreadystatechange=function(){s.readyState>3&&i()},s.onprogress=function(t){var e=nu.event;nu.event=t;try{u.progress.call(a,s)}finally{nu.event=e}},a.header=function(t,e){return t=(t+"").toLowerCase(),arguments.length<2?o[t]:(null==e?delete o[t]:o[t]=e+"",a)},a.mimeType=function(t){return arguments.length?(e=null==t?null:t+"",a):e},a.responseType=function(t){return arguments.length?(c=t,a):c},a.response=function(t){return n=t,a},["get","post"].forEach(function(t){a[t]=function(){return a.send.apply(a,[t].concat(iu(arguments)))}}),a.send=function(n,r,i){if(2===arguments.length&&"function"==typeof r&&(i=r,r=null),s.open(n,t,!0),null==e||"accept"in o||(o.accept=e+",*/*"),s.setRequestHeader)for(var l in o)s.setRequestHeader(l,o[l]);return null!=e&&s.overrideMimeType&&s.overrideMimeType(e),null!=c&&(s.responseType=c),null!=i&&a.on("error",i).on("load",function(t){i(null,t)}),u.beforesend.call(a,s),s.send(null==r?null:r),a},a.abort=function(){return s.abort(),a},nu.rebind(a,u,"on"),null==r?a:a.get(Tt(r))}function Tt(t){return 1===t.length?function(e,n){t(null==e?n:null)}:t}function Ft(t){var e=t.responseType;return e&&"text"!==e?t.response:t.responseText}function Bt(){var t=Lt(),e=Ot()-t;e>24?(isFinite(e)&&(clearTimeout(no),no=setTimeout(Bt,e)),eo=0):(eo=1,io(Bt))}function Lt(){var t=Date.now();for(ro=Qu;ro;)t>=ro.t&&(ro.f=ro.c(t-ro.t)),ro=ro.n;return t}function Ot(){for(var t,e=Qu,n=1/0;e;)e.f?e=t?t.n=e.n:Qu=e.n:(e.t8?function(t){return t/n}:function(t){return t*n},symbol:t}}function Pt(t){var e=t.decimal,n=t.thousands,r=t.grouping,i=t.currency,a=r&&n?function(t,e){for(var i=t.length,a=[],u=0,o=r[0],s=0;i>0&&o>0&&(s+o+1>e&&(o=Math.max(1,e-s)),a.push(t.substring(i-=o,i+o)),!((s+=o+1)>e));)o=r[u=(u+1)%r.length];return a.reverse().join(n)}:b;return function(t){var n=uo.exec(t),r=n[1]||" ",u=n[2]||">",o=n[3]||"-",s=n[4]||"",c=n[5],l=+n[6],h=n[7],f=n[8],d=n[9],p=1,g="",y="",m=!1,v=!0;switch(f&&(f=+f.substring(1)),(c||"0"===r&&"="===u)&&(c=r="0",u="="),d){case"n":h=!0,d="g";break;case"%":p=100,y="%",d="f";break;case"p":p=100,y="%",d="r";break;case"b":case"o":case"x":case"X":"#"===s&&(g="0"+d.toLowerCase());case"c":v=!1;case"d":m=!0,f=0;break;case"s":p=-1,d="r"}"$"===s&&(g=i[0],y=i[1]),"r"!=d||f||(d="g"),null!=f&&("g"==d?f=Math.max(1,Math.min(21,f)):("e"==d||"f"==d)&&(f=Math.max(0,Math.min(20,f)))),d=oo.get(d)||Rt;var b=c&&h;return function(t){var n=y;if(m&&t%1)return"";var i=0>t||0===t&&0>1/t?(t=-t,"-"):"-"===o?"":o;if(0>p){var s=nu.formatPrefix(t,f);t=s.scale(t),n=s.symbol+y}else t*=p;t=d(t,f);var _,x,w=t.lastIndexOf(".");if(0>w){var A=v?t.lastIndexOf("e"):-1;0>A?(_=t,x=""):(_=t.substring(0,A),x=t.substring(A))}else _=t.substring(0,w),x=e+t.substring(w+1);!c&&h&&(_=a(_,1/0));var E=g.length+_.length+x.length+(b?0:i.length),k=l>E?new Array(E=l-E+1).join(r):"";return b&&(_=a(k+_,k.length?l-x.length:1/0)),i+=g,t=_+x,("<"===u?i+t+k:">"===u?k+i+t:"^"===u?k.substring(0,E>>=1)+i+t+k.substring(E):i+(b?t:k+t))+n}}}function Rt(t){return t+""}function qt(){this._=new Date(arguments.length>1?Date.UTC.apply(this,arguments):arguments[0])}function jt(t,e,n){function r(e){var n=t(e),r=a(n,1);return r-e>e-n?n:r}function i(n){return e(n=t(new co(n-1)),1),n}function a(t,n){return e(t=new co(+t),n),t}function u(t,r,a){var u=i(t),o=[];if(a>1)for(;r>u;)n(u)%a||o.push(new Date(+u)),e(u,1);else for(;r>u;)o.push(new Date(+u)),e(u,1);return o}function o(t,e,n){try{co=qt;var r=new qt;return r._=t,u(r,e,n)}finally{co=Date}}t.floor=t,t.round=r,t.ceil=i,t.offset=a,t.range=u;var s=t.utc=Ut(t);return s.floor=s,s.round=Ut(r),s.ceil=Ut(i),s.offset=Ut(a),s.range=o,t}function Ut(t){return function(e,n){try{co=qt;var r=new qt;return r._=e,t(r,n)._}finally{co=Date}}}function Yt(t){function e(t){function e(e){for(var n,i,a,u=[],o=-1,s=0;++oo;){if(r>=c)return-1;if(i=e.charCodeAt(o++),37===i){if(u=e.charAt(o++),a=S[u in ho?e.charAt(o++):u],!a||(r=a(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}function r(t,e,n){w.lastIndex=0;var r=w.exec(e.slice(n));return r?(t.w=A.get(r[0].toLowerCase()),n+r[0].length):-1}function i(t,e,n){_.lastIndex=0;var r=_.exec(e.slice(n));return r?(t.w=x.get(r[0].toLowerCase()),n+r[0].length):-1}function a(t,e,n){D.lastIndex=0;var r=D.exec(e.slice(n));return r?(t.m=C.get(r[0].toLowerCase()),n+r[0].length):-1}function u(t,e,n){E.lastIndex=0;var r=E.exec(e.slice(n));return r?(t.m=k.get(r[0].toLowerCase()),n+r[0].length):-1}function o(t,e,r){return n(t,M.c.toString(),e,r)}function s(t,e,r){return n(t,M.x.toString(),e,r)}function c(t,e,r){return n(t,M.X.toString(),e,r)}function l(t,e,n){var r=b.get(e.slice(n,n+=2).toLowerCase());return null==r?-1:(t.p=r,n)}var h=t.dateTime,f=t.date,d=t.time,p=t.periods,g=t.days,y=t.shortDays,m=t.months,v=t.shortMonths;e.utc=function(t){function n(t){try{co=qt;var e=new co;return e._=t,r(e)}finally{co=Date}}var r=e(t);return n.parse=function(t){try{co=qt;var e=r.parse(t);return e&&e._}finally{co=Date}},n.toString=r.toString,n},e.multi=e.utc.multi=se;var b=nu.map(),_=Vt(g),x=$t(g),w=Vt(y),A=$t(y),E=Vt(m),k=$t(m),D=Vt(v),C=$t(v);p.forEach(function(t,e){b.set(t.toLowerCase(),e)});var M={a:function(t){return y[t.getDay()]},A:function(t){return g[t.getDay()]},b:function(t){return v[t.getMonth()]},B:function(t){return m[t.getMonth()]},c:e(h),d:function(t,e){return zt(t.getDate(),e,2)},e:function(t,e){return zt(t.getDate(),e,2)},H:function(t,e){return zt(t.getHours(),e,2)},I:function(t,e){return zt(t.getHours()%12||12,e,2)},j:function(t,e){return zt(1+so.dayOfYear(t),e,3)},L:function(t,e){return zt(t.getMilliseconds(),e,3)},m:function(t,e){return zt(t.getMonth()+1,e,2)},M:function(t,e){return zt(t.getMinutes(),e,2)},p:function(t){return p[+(t.getHours()>=12)]},S:function(t,e){return zt(t.getSeconds(),e,2)},U:function(t,e){return zt(so.sundayOfYear(t),e,2)},w:function(t){return t.getDay()},W:function(t,e){return zt(so.mondayOfYear(t),e,2)},x:e(f),X:e(d),y:function(t,e){return zt(t.getFullYear()%100,e,2)},Y:function(t,e){return zt(t.getFullYear()%1e4,e,4)},Z:ue,"%":function(){return"%"}},S={a:r,A:i,b:a,B:u,c:o,d:te,e:te,H:ne,I:ne,j:ee,L:ae,m:Qt,M:re,p:l,S:ie,U:Ht,w:Gt,W:Wt,x:s,X:c,y:Xt,Y:Zt,Z:Kt,"%":oe};return e}function zt(t,e,n){var r=0>t?"-":"",i=(r?-t:t)+"",a=i.length;return r+(n>a?new Array(n-a+1).join(e)+i:i)}function Vt(t){return new RegExp("^(?:"+t.map(nu.requote).join("|")+")","i")}function $t(t){for(var e=new l,n=-1,r=t.length;++n68?1900:2e3)}function Qt(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function te(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function ee(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+3));return r?(t.j=+r[0],n+r[0].length):-1}function ne(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function re(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function ie(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function ae(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function ue(t){var e=t.getTimezoneOffset(),n=e>0?"-":"+",r=pu(e)/60|0,i=pu(e)%60;return n+zt(r,"0",2)+zt(i,"0",2)}function oe(t,e,n){po.lastIndex=0;var r=po.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function se(t){for(var e=t.length,n=-1;++n=0?1:-1,o=u*n,s=Math.cos(e),c=Math.sin(e),l=a*c,h=i*s+l*Math.cos(o),f=l*u*Math.sin(o);_o.add(Math.atan2(f,h)),r=t,i=s,a=c}var e,n,r,i,a;xo.point=function(u,o){xo.point=t,r=(e=u)*Iu,i=Math.cos(o=(n=o)*Iu/2+Bu/4),a=Math.sin(o)},xo.lineEnd=function(){t(e,n)}}function ge(t){var e=t[0],n=t[1],r=Math.cos(n);return[r*Math.cos(e),r*Math.sin(e),Math.sin(n)]}function ye(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function me(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 ve(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function be(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function _e(t){var e=Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}function xe(t){return[Math.atan2(t[1],t[0]),nt(t[2])]}function we(t,e){return pu(t[0]-e[0])o;++o)i.point((n=t[o])[0],n[1]);return void i.lineEnd()}var s=new Be(n,t,null,!0),c=new Be(n,null,s,!1);s.o=c,a.push(s),u.push(c),s=new Be(r,t,null,!1),c=new Be(r,null,s,!0),s.o=c,a.push(s),u.push(c)}}),u.sort(e),Fe(a),Fe(u),a.length){for(var o=0,s=n,c=u.length;c>o;++o)u[o].e=s=!s;for(var l,h,f=a[0];;){for(var d=f,p=!0;d.v;)if((d=d.n)===f)return;l=d.z,i.lineStart();do{if(d.v=d.o.v=!0,d.e){if(p)for(var o=0,c=l.length;c>o;++o)i.point((h=l[o])[0],h[1]);else r(d.x,d.n.x,1,i);d=d.n}else{if(p){l=d.p.z;for(var o=l.length-1;o>=0;--o)i.point((h=l[o])[0],h[1])}else r(d.x,d.p.x,-1,i);d=d.p}d=d.o,l=d.z,p=!p}while(!d.v);i.lineEnd()}}}function Fe(t){if(e=t.length){for(var e,n,r=0,i=t[0];++r0){for(x||(a.polygonStart(),x=!0),a.lineStart();++u1&&2&e&&n.push(n.pop().concat(n.shift())),d.push(n.filter(Oe))}var d,p,g,y=e(a),m=i.invert(r[0],r[1]),v={point:u,lineStart:s,lineEnd:c,polygonStart:function(){v.point=l,v.lineStart=h,v.lineEnd=f,d=[],p=[]},polygonEnd:function(){v.point=u,v.lineStart=s,v.lineEnd=c,d=nu.merge(d);var t=je(m,p);d.length?(x||(a.polygonStart(),x=!0),Te(d,Ie,t,n,a)):t&&(x||(a.polygonStart(),x=!0),a.lineStart(),n(null,null,1,a),a.lineEnd()),x&&(a.polygonEnd(),x=!1),d=p=null},sphere:function(){a.polygonStart(),a.lineStart(),n(null,null,1,a),a.lineEnd(),a.polygonEnd()}},b=Ne(),_=e(b),x=!1;return v}}function Oe(t){return t.length>1}function Ne(){var t,e=[];return{lineStart:function(){e.push(t=[])},point:function(e,n){t.push([e,n])},lineEnd:w,buffer:function(){var n=e;return e=[],t=null,n},rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))}}}function Ie(t,e){return((t=t.x)[0]<0?t[1]-Nu-Tu:Nu-t[1])-((e=e.x)[0]<0?e[1]-Nu-Tu:Nu-e[1])}function Pe(t){var e,n=0/0,r=0/0,i=0/0;return{lineStart:function(){t.lineStart(),e=1},point:function(a,u){var o=a>0?Bu:-Bu,s=pu(a-n);pu(s-Bu)0?Nu:-Nu),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(o,r),t.point(a,r),e=0):i!==o&&s>=Bu&&(pu(n-i)Tu?Math.atan((Math.sin(e)*(a=Math.cos(r))*Math.sin(n)-Math.sin(r)*(i=Math.cos(e))*Math.sin(t))/(i*a*u)):(e+r)/2}function qe(t,e,n,r){var i;if(null==t)i=n*Nu,r.point(-Bu,i),r.point(0,i),r.point(Bu,i),r.point(Bu,0),r.point(Bu,-i),r.point(0,-i),r.point(-Bu,-i),r.point(-Bu,0),r.point(-Bu,i);else if(pu(t[0]-e[0])>Tu){var a=t[0]o;++o){var c=e[o],l=c.length;if(l)for(var h=c[0],f=h[0],d=h[1]/2+Bu/4,p=Math.sin(d),g=Math.cos(d),y=1;;){y===l&&(y=0),t=c[y];var m=t[0],v=t[1]/2+Bu/4,b=Math.sin(v),_=Math.cos(v),x=m-f,w=x>=0?1:-1,A=w*x,E=A>Bu,k=p*b;if(_o.add(Math.atan2(k*w*Math.sin(A),g*_+k*Math.cos(A))),a+=E?x+w*Lu:x,E^f>=n^m>=n){var D=me(ge(h),ge(t));_e(D);var C=me(i,D);_e(C);var M=(E^x>=0?-1:1)*nt(C[2]);(r>M||r===M&&(D[0]||D[1]))&&(u+=E^x>=0?1:-1)}if(!y++)break;f=m,p=b,g=_,h=t}}return(-Tu>a||Tu>a&&0>_o)^1&u}function Ue(t){function e(t,e){return Math.cos(t)*Math.cos(e)>a}function n(t){var n,a,s,c,l;return{lineStart:function(){c=s=!1,l=1},point:function(h,f){var d,p=[h,f],g=e(h,f),y=u?g?0:i(h,f):g?i(h+(0>h?Bu:-Bu),f):0;if(!n&&(c=s=g)&&t.lineStart(),g!==s&&(d=r(n,p),(we(n,d)||we(p,d))&&(p[0]+=Tu,p[1]+=Tu,g=e(p[0],p[1]))),g!==s)l=0,g?(t.lineStart(),d=r(p,n),t.point(d[0],d[1])):(d=r(n,p),t.point(d[0],d[1]),t.lineEnd()),n=d;else if(o&&n&&u^g){var m;y&a||!(m=r(p,n,!0))||(l=0,u?(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])))}!g||n&&we(n,p)||t.point(p[0],p[1]),n=p,s=g,a=y},lineEnd:function(){s&&t.lineEnd(),n=null},clean:function(){return l|(c&&s)<<1}}}function r(t,e,n){var r=ge(t),i=ge(e),u=[1,0,0],o=me(r,i),s=ye(o,o),c=o[0],l=s-c*c;if(!l)return!n&&t;var h=a*s/l,f=-a*c/l,d=me(u,o),p=be(u,h),g=be(o,f);ve(p,g);var y=d,m=ye(p,y),v=ye(y,y),b=m*m-v*(ye(p,p)-1);if(!(0>b)){var _=Math.sqrt(b),x=be(y,(-m-_)/v);if(ve(x,p),x=xe(x),!n)return x;var w,A=t[0],E=e[0],k=t[1],D=e[1];A>E&&(w=A,A=E,E=w);var C=E-A,M=pu(C-Bu)C;if(!M&&k>D&&(w=k,k=D,D=w),S?M?k+D>0^x[1]<(pu(x[0]-A)Bu^(A<=x[0]&&x[0]<=E)){var T=be(y,(-m+_)/v);return ve(T,p),[x,xe(T)]}}}function i(e,n){var r=u?t:Bu-t,i=0;return-r>e?i|=1:e>r&&(i|=2),-r>n?i|=4:n>r&&(i|=8),i}var a=Math.cos(t),u=a>0,o=pu(a)>Tu,s=gn(t,6*Iu);return Le(e,n,s,u?[0,-t]:[-Bu,t-Bu])}function Ye(t,e,n,r){return function(i){var a,u=i.a,o=i.b,s=u.x,c=u.y,l=o.x,h=o.y,f=0,d=1,p=l-s,g=h-c;if(a=t-s,p||!(a>0)){if(a/=p,0>p){if(f>a)return;d>a&&(d=a)}else if(p>0){if(a>d)return;a>f&&(f=a)}if(a=n-s,p||!(0>a)){if(a/=p,0>p){if(a>d)return;a>f&&(f=a)}else if(p>0){if(f>a)return;d>a&&(d=a)}if(a=e-c,g||!(a>0)){if(a/=g,0>g){if(f>a)return;d>a&&(d=a)}else if(g>0){if(a>d)return;a>f&&(f=a)}if(a=r-c,g||!(0>a)){if(a/=g,0>g){if(a>d)return;a>f&&(f=a)}else if(g>0){if(f>a)return;d>a&&(d=a)}return f>0&&(i.a={x:s+f*p,y:c+f*g}),1>d&&(i.b={x:s+d*p,y:c+d*g}),i}}}}}}function ze(t,e,n,r){function i(r,i){return pu(r[0]-t)0?0:3:pu(r[0]-n)0?2:1:pu(r[1]-e)0?1:0:i>0?3:2}function a(t,e){return u(t.x,e.x)}function u(t,e){var n=i(t,1),r=i(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]; +!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.mermaid=t()}}(function(){var define,module,exports;return function t(e,n,r){function i(u,o){if(!n[u]){if(!e[u]){var s="function"==typeof require&&require;if(!o&&s)return s(u,!0);if(a)return a(u,!0);var c=new Error("Cannot find module '"+u+"'");throw c.code="MODULE_NOT_FOUND",c}var l=n[u]={exports:{}};e[u][0].call(l.exports,function(t){var n=e[u][1][t];return i(n?n:t)},l,l.exports,t,e,n,r)}return n[u].exports}for(var a="function"==typeof require&&require,u=0;u=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=-1&&!i;a--){var u=a>=0?arguments[a]:t.cwd();if("string"!=typeof u)throw new TypeError("Arguments to path.resolve must be strings");u&&(n=u+"/"+n,i="/"===u.charAt(0))}return n=e(r(n.split("/"),function(t){return!!t}),!i).join("/"),(i?"/":"")+n||"."},n.normalize=function(t){var i=n.isAbsolute(t),a="/"===u(t,-1);return t=e(r(t.split("/"),function(t){return!!t}),!i).join("/"),t||i||(t="."),t&&a&&(t+="/"),(i?"/":"")+t},n.isAbsolute=function(t){return"/"===t.charAt(0)},n.join=function(){var t=Array.prototype.slice.call(arguments,0);return n.normalize(r(t,function(t){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},n.relative=function(t,e){function r(t){for(var e=0;e=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=n.resolve(t).substr(1),e=n.resolve(e).substr(1);for(var i=r(t.split("/")),a=r(e.split("/")),u=Math.min(i.length,a.length),o=u,s=0;u>s;s++)if(i[s]!==a[s]){o=s;break}for(var c=[],s=o;se&&(e=t.length+e),t.substr(e,n)}}).call(this,t("_process"))},{_process:3}],3:[function(t,e){function n(){}var r=e.exports={};r.nextTick=function(){var t="undefined"!=typeof window&&window.setImmediate,e="undefined"!=typeof window&&window.MutationObserver,n="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(t)return function(t){return window.setImmediate(t)};var r=[];if(e){var i=document.createElement("div"),a=new MutationObserver(function(){var t=r.slice();r.length=0,t.forEach(function(t){t()})});return a.observe(i,{attributes:!0}),function(t){r.length||i.setAttribute("yes","no"),r.push(t)}}return n?(window.addEventListener("message",function(t){var e=t.source;if((e===window||null===e)&&"process-tick"===t.data&&(t.stopPropagation(),r.length>0)){var n=r.shift();n()}},!0),function(t){r.push(t),window.postMessage("process-tick","*")}):function(t){setTimeout(t,0)}}(),r.title="browser",r.browser=!0,r.env={},r.argv=[],r.on=n,r.addListener=n,r.once=n,r.off=n,r.removeListener=n,r.removeAllListeners=n,r.emit=n,r.binding=function(){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(){throw new Error("process.chdir is not supported")}},{}],4:[function(t,e){!function(){function t(t){return t&&(t.ownerDocument||t.document||t).documentElement}function n(t){return t&&(t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView)}function r(t,e){return e>t?-1:t>e?1:t>=e?0:0/0}function i(t){return null===t?0/0:+t}function a(t){return!isNaN(t)}function u(t){return{left:function(e,n,r,i){for(arguments.length<3&&(r=0),arguments.length<4&&(i=e.length);i>r;){var a=r+i>>>1;t(e[a],n)<0?r=a+1:i=a}return r},right:function(e,n,r,i){for(arguments.length<3&&(r=0),arguments.length<4&&(i=e.length);i>r;){var a=r+i>>>1;t(e[a],n)>0?i=a:r=a+1}return r}}}function o(t){return t.length}function s(t){for(var e=1;t*e%1;)e*=10;return e}function c(t,e){for(var n in e)Object.defineProperty(t.prototype,n,{value:e[n],enumerable:!1})}function l(){this._=Object.create(null)}function h(t){return(t+="")===gu||t[0]===yu?yu+t:t}function f(t){return(t+="")[0]===yu?t.slice(1):t}function d(t){return h(t)in this._}function p(t){return(t=h(t))in this._&&delete this._[t]}function g(){var t=[];for(var e in this._)t.push(f(e));return t}function y(){var t=0;for(var e in this._)++t;return t}function m(){for(var t in this._)return!1;return!0}function v(){this._=Object.create(null)}function b(t){return t}function _(t,e,n){return function(){var r=n.apply(e,arguments);return r===e?t:r}}function x(t,e){if(e in t)return e;e=e.charAt(0).toUpperCase()+e.slice(1);for(var n=0,r=mu.length;r>n;++n){var i=mu[n]+e;if(i in t)return i}}function w(){}function A(){}function E(t){function e(){for(var e,r=n,i=-1,a=r.length;++in;n++)for(var i,a=t[n],u=0,o=a.length;o>u;u++)(i=a[u])&&e(i,u,n);return t}function $(t){return bu(t,ku),t}function G(t){var e,n;return function(r,i,a){var u,o=t[a].update,s=o.length;for(a!=n&&(n=a,e=0),i>=e&&(e=i+1);!(u=o[e])&&++e0&&(t=t.slice(0,o));var c=Du.get(t);return c&&(t=c,s=Z),o?e?i:r:e?w:a}function W(t,e){return function(n){var r=nu.event;nu.event=n,e[0]=this.__data__;try{t.apply(this,e)}finally{nu.event=r}}}function Z(t,e){var n=W(t,e);return function(t){var e=this,r=t.relatedTarget;r&&(r===e||8&r.compareDocumentPosition(e))||n.call(e,t)}}function X(e){var r=".dragsuppress-"+ ++Mu,i="click"+r,a=nu.select(n(e)).on("touchmove"+r,k).on("dragstart"+r,k).on("selectstart"+r,k);if(null==Cu&&(Cu="onselectstart"in e?!1:x(e.style,"userSelect")),Cu){var u=t(e).style,o=u[Cu];u[Cu]="none"}return function(t){if(a.on(r,null),Cu&&(u[Cu]=o),t){var e=function(){a.on(i,null)};a.on(i,function(){k(),e()},!0),setTimeout(e,0)}}}function J(t,e){e.changedTouches&&(e=e.changedTouches[0]);var r=t.ownerSVGElement||t;if(r.createSVGPoint){var i=r.createSVGPoint();if(0>Su){var a=n(t);if(a.scrollX||a.scrollY){r=nu.select("body").append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important");var u=r[0][0].getScreenCTM();Su=!(u.f||u.e),r.remove()}}return Su?(i.x=e.pageX,i.y=e.pageY):(i.x=e.clientX,i.y=e.clientY),i=i.matrixTransform(t.getScreenCTM().inverse()),[i.x,i.y]}var o=t.getBoundingClientRect();return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}function K(){return nu.event.changedTouches[0].identifier}function Q(t){return t>0?1:0>t?-1:0}function tt(t,e,n){return(e[0]-t[0])*(n[1]-t[1])-(e[1]-t[1])*(n[0]-t[0])}function et(t){return t>1?0:-1>t?Bu:Math.acos(t)}function nt(t){return t>1?Ou:-1>t?-Ou:Math.asin(t)}function rt(t){return((t=Math.exp(t))-1/t)/2}function it(t){return((t=Math.exp(t))+1/t)/2}function at(t){return((t=Math.exp(2*t))-1)/(t+1)}function ut(t){return(t=Math.sin(t/2))*t}function ot(){}function st(t,e,n){return this instanceof st?(this.h=+t,this.s=+e,void(this.l=+n)):arguments.length<2?t instanceof st?new st(t.h,t.s,t.l):wt(""+t,At,st):new st(t,e,n)}function ct(t,e,n){function r(t){return t>360?t-=360:0>t&&(t+=360),60>t?a+(u-a)*t/60:180>t?u:240>t?a+(u-a)*(240-t)/60:a}function i(t){return Math.round(255*r(t))}var a,u;return t=isNaN(t)?0:(t%=360)<0?t+360:t,e=isNaN(e)?0:0>e?0:e>1?1:e,n=0>n?0:n>1?1:n,u=.5>=n?n*(1+e):n+e-n*e,a=2*n-u,new vt(i(t+120),i(t),i(t-120))}function lt(t,e,n){return this instanceof lt?(this.h=+t,this.c=+e,void(this.l=+n)):arguments.length<2?t instanceof lt?new lt(t.h,t.c,t.l):t instanceof ft?pt(t.l,t.a,t.b):pt((t=Et((t=nu.rgb(t)).r,t.g,t.b)).l,t.a,t.b):new lt(t,e,n)}function ht(t,e,n){return isNaN(t)&&(t=0),isNaN(e)&&(e=0),new ft(n,Math.cos(t*=Iu)*e,Math.sin(t)*e)}function ft(t,e,n){return this instanceof ft?(this.l=+t,this.a=+e,void(this.b=+n)):arguments.length<2?t instanceof ft?new ft(t.l,t.a,t.b):t instanceof lt?ht(t.h,t.c,t.l):Et((t=vt(t)).r,t.g,t.b):new ft(t,e,n)}function dt(t,e,n){var r=(t+16)/116,i=r+e/500,a=r-n/200;return i=gt(i)*Hu,r=gt(r)*Wu,a=gt(a)*Zu,new vt(mt(3.2404542*i-1.5371385*r-.4985314*a),mt(-.969266*i+1.8760108*r+.041556*a),mt(.0556434*i-.2040259*r+1.0572252*a))}function pt(t,e,n){return t>0?new lt(Math.atan2(n,e)*Ru,Math.sqrt(e*e+n*n),t):new lt(0/0,0/0,t)}function gt(t){return t>.206893034?t*t*t:(t-4/29)/7.787037}function yt(t){return t>.008856?Math.pow(t,1/3):7.787037*t+4/29}function mt(t){return Math.round(255*(.00304>=t?12.92*t:1.055*Math.pow(t,1/2.4)-.055))}function vt(t,e,n){return this instanceof vt?(this.r=~~t,this.g=~~e,void(this.b=~~n)):arguments.length<2?t instanceof vt?new vt(t.r,t.g,t.b):wt(""+t,vt,ct):new vt(t,e,n)}function bt(t){return new vt(t>>16,t>>8&255,255&t)}function _t(t){return bt(t)+""}function xt(t){return 16>t?"0"+Math.max(0,t).toString(16):Math.min(255,t).toString(16)}function wt(t,e,n){t=t.toLowerCase();var r,i,a,u=0,o=0,s=0;if(r=/([a-z]+)\((.*)\)/.exec(t))switch(i=r[2].split(","),r[1]){case"hsl":return n(parseFloat(i[0]),parseFloat(i[1])/100,parseFloat(i[2])/100);case"rgb":return e(Dt(i[0]),Dt(i[1]),Dt(i[2]))}return(a=Ku.get(t))?e(a.r,a.g,a.b):(null==t||"#"!==t.charAt(0)||isNaN(a=parseInt(t.slice(1),16))||(4===t.length?(u=(3840&a)>>4,u=u>>4|u,o=240&a,o=o>>4|o,s=15&a,s=s<<4|s):7===t.length&&(u=(16711680&a)>>16,o=(65280&a)>>8,s=255&a)),e(u,o,s))}function At(t,e,n){var r,i,a=Math.min(t/=255,e/=255,n/=255),u=Math.max(t,e,n),o=u-a,s=(u+a)/2;return o?(i=.5>s?o/(u+a):o/(2-u-a),r=t==u?(e-n)/o+(n>e?6:0):e==u?(n-t)/o+2:(t-e)/o+4,r*=60):(r=0/0,i=s>0&&1>s?0:r),new st(r,i,s)}function Et(t,e,n){t=kt(t),e=kt(e),n=kt(n);var r=yt((.4124564*t+.3575761*e+.1804375*n)/Hu),i=yt((.2126729*t+.7151522*e+.072175*n)/Wu),a=yt((.0193339*t+.119192*e+.9503041*n)/Zu);return ft(116*i-16,500*(r-i),200*(i-a))}function kt(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Dt(t){var e=parseFloat(t);return"%"===t.charAt(t.length-1)?Math.round(2.55*e):e}function Ct(t){return"function"==typeof t?t:function(){return t}}function Mt(t){return function(e,n,r){return 2===arguments.length&&"function"==typeof n&&(r=n,n=null),St(e,n,t,r)}}function St(t,e,n,r){function i(){var t,e=s.status;if(!e&&Ft(s)||e>=200&&300>e||304===e){try{t=n.call(a,s)}catch(r){return void u.error.call(a,r)}u.load.call(a,t)}else u.error.call(a,s)}var a={},u=nu.dispatch("beforesend","progress","load","error"),o={},s=new XMLHttpRequest,c=null;return!this.XDomainRequest||"withCredentials"in s||!/^(http(s)?:)?\/\//.test(t)||(s=new XDomainRequest),"onload"in s?s.onload=s.onerror=i:s.onreadystatechange=function(){s.readyState>3&&i()},s.onprogress=function(t){var e=nu.event;nu.event=t;try{u.progress.call(a,s)}finally{nu.event=e}},a.header=function(t,e){return t=(t+"").toLowerCase(),arguments.length<2?o[t]:(null==e?delete o[t]:o[t]=e+"",a)},a.mimeType=function(t){return arguments.length?(e=null==t?null:t+"",a):e},a.responseType=function(t){return arguments.length?(c=t,a):c},a.response=function(t){return n=t,a},["get","post"].forEach(function(t){a[t]=function(){return a.send.apply(a,[t].concat(iu(arguments)))}}),a.send=function(n,r,i){if(2===arguments.length&&"function"==typeof r&&(i=r,r=null),s.open(n,t,!0),null==e||"accept"in o||(o.accept=e+",*/*"),s.setRequestHeader)for(var l in o)s.setRequestHeader(l,o[l]);return null!=e&&s.overrideMimeType&&s.overrideMimeType(e),null!=c&&(s.responseType=c),null!=i&&a.on("error",i).on("load",function(t){i(null,t)}),u.beforesend.call(a,s),s.send(null==r?null:r),a},a.abort=function(){return s.abort(),a},nu.rebind(a,u,"on"),null==r?a:a.get(Tt(r))}function Tt(t){return 1===t.length?function(e,n){t(null==e?n:null)}:t}function Ft(t){var e=t.responseType;return e&&"text"!==e?t.response:t.responseText}function Bt(){var t=Lt(),e=Nt()-t;e>24?(isFinite(e)&&(clearTimeout(no),no=setTimeout(Bt,e)),eo=0):(eo=1,io(Bt))}function Lt(){var t=Date.now();for(ro=Qu;ro;)t>=ro.t&&(ro.f=ro.c(t-ro.t)),ro=ro.n;return t}function Nt(){for(var t,e=Qu,n=1/0;e;)e.f?e=t?t.n=e.n:Qu=e.n:(e.t8?function(t){return t/n}:function(t){return t*n},symbol:t}}function Rt(t){var e=t.decimal,n=t.thousands,r=t.grouping,i=t.currency,a=r&&n?function(t,e){for(var i=t.length,a=[],u=0,o=r[0],s=0;i>0&&o>0&&(s+o+1>e&&(o=Math.max(1,e-s)),a.push(t.substring(i-=o,i+o)),!((s+=o+1)>e));)o=r[u=(u+1)%r.length];return a.reverse().join(n)}:b;return function(t){var n=uo.exec(t),r=n[1]||" ",u=n[2]||">",o=n[3]||"-",s=n[4]||"",c=n[5],l=+n[6],h=n[7],f=n[8],d=n[9],p=1,g="",y="",m=!1,v=!0;switch(f&&(f=+f.substring(1)),(c||"0"===r&&"="===u)&&(c=r="0",u="="),d){case"n":h=!0,d="g";break;case"%":p=100,y="%",d="f";break;case"p":p=100,y="%",d="r";break;case"b":case"o":case"x":case"X":"#"===s&&(g="0"+d.toLowerCase());case"c":v=!1;case"d":m=!0,f=0;break;case"s":p=-1,d="r"}"$"===s&&(g=i[0],y=i[1]),"r"!=d||f||(d="g"),null!=f&&("g"==d?f=Math.max(1,Math.min(21,f)):("e"==d||"f"==d)&&(f=Math.max(0,Math.min(20,f)))),d=oo.get(d)||Pt;var b=c&&h;return function(t){var n=y;if(m&&t%1)return"";var i=0>t||0===t&&0>1/t?(t=-t,"-"):"-"===o?"":o;if(0>p){var s=nu.formatPrefix(t,f);t=s.scale(t),n=s.symbol+y}else t*=p;t=d(t,f);var _,x,w=t.lastIndexOf(".");if(0>w){var A=v?t.lastIndexOf("e"):-1;0>A?(_=t,x=""):(_=t.substring(0,A),x=t.substring(A))}else _=t.substring(0,w),x=e+t.substring(w+1);!c&&h&&(_=a(_,1/0));var E=g.length+_.length+x.length+(b?0:i.length),k=l>E?new Array(E=l-E+1).join(r):"";return b&&(_=a(k+_,k.length?l-x.length:1/0)),i+=g,t=_+x,("<"===u?i+t+k:">"===u?k+i+t:"^"===u?k.substring(0,E>>=1)+i+t+k.substring(E):i+(b?t:k+t))+n}}}function Pt(t){return t+""}function qt(){this._=new Date(arguments.length>1?Date.UTC.apply(this,arguments):arguments[0])}function jt(t,e,n){function r(e){var n=t(e),r=a(n,1);return r-e>e-n?n:r}function i(n){return e(n=t(new co(n-1)),1),n}function a(t,n){return e(t=new co(+t),n),t}function u(t,r,a){var u=i(t),o=[];if(a>1)for(;r>u;)n(u)%a||o.push(new Date(+u)),e(u,1);else for(;r>u;)o.push(new Date(+u)),e(u,1);return o}function o(t,e,n){try{co=qt;var r=new qt;return r._=t,u(r,e,n)}finally{co=Date}}t.floor=t,t.round=r,t.ceil=i,t.offset=a,t.range=u;var s=t.utc=Ut(t);return s.floor=s,s.round=Ut(r),s.ceil=Ut(i),s.offset=Ut(a),s.range=o,t}function Ut(t){return function(e,n){try{co=qt;var r=new qt;return r._=e,t(r,n)._}finally{co=Date}}}function Yt(t){function e(t){function e(e){for(var n,i,a,u=[],o=-1,s=0;++oo;){if(r>=c)return-1;if(i=e.charCodeAt(o++),37===i){if(u=e.charAt(o++),a=S[u in ho?e.charAt(o++):u],!a||(r=a(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}function r(t,e,n){w.lastIndex=0;var r=w.exec(e.slice(n));return r?(t.w=A.get(r[0].toLowerCase()),n+r[0].length):-1}function i(t,e,n){_.lastIndex=0;var r=_.exec(e.slice(n));return r?(t.w=x.get(r[0].toLowerCase()),n+r[0].length):-1}function a(t,e,n){D.lastIndex=0;var r=D.exec(e.slice(n));return r?(t.m=C.get(r[0].toLowerCase()),n+r[0].length):-1}function u(t,e,n){E.lastIndex=0;var r=E.exec(e.slice(n));return r?(t.m=k.get(r[0].toLowerCase()),n+r[0].length):-1}function o(t,e,r){return n(t,M.c.toString(),e,r)}function s(t,e,r){return n(t,M.x.toString(),e,r)}function c(t,e,r){return n(t,M.X.toString(),e,r)}function l(t,e,n){var r=b.get(e.slice(n,n+=2).toLowerCase());return null==r?-1:(t.p=r,n)}var h=t.dateTime,f=t.date,d=t.time,p=t.periods,g=t.days,y=t.shortDays,m=t.months,v=t.shortMonths;e.utc=function(t){function n(t){try{co=qt;var e=new co;return e._=t,r(e)}finally{co=Date}}var r=e(t);return n.parse=function(t){try{co=qt;var e=r.parse(t);return e&&e._}finally{co=Date}},n.toString=r.toString,n},e.multi=e.utc.multi=se;var b=nu.map(),_=Vt(g),x=$t(g),w=Vt(y),A=$t(y),E=Vt(m),k=$t(m),D=Vt(v),C=$t(v);p.forEach(function(t,e){b.set(t.toLowerCase(),e)});var M={a:function(t){return y[t.getDay()]},A:function(t){return g[t.getDay()]},b:function(t){return v[t.getMonth()]},B:function(t){return m[t.getMonth()]},c:e(h),d:function(t,e){return zt(t.getDate(),e,2)},e:function(t,e){return zt(t.getDate(),e,2)},H:function(t,e){return zt(t.getHours(),e,2)},I:function(t,e){return zt(t.getHours()%12||12,e,2)},j:function(t,e){return zt(1+so.dayOfYear(t),e,3)},L:function(t,e){return zt(t.getMilliseconds(),e,3)},m:function(t,e){return zt(t.getMonth()+1,e,2)},M:function(t,e){return zt(t.getMinutes(),e,2)},p:function(t){return p[+(t.getHours()>=12)]},S:function(t,e){return zt(t.getSeconds(),e,2)},U:function(t,e){return zt(so.sundayOfYear(t),e,2)},w:function(t){return t.getDay()},W:function(t,e){return zt(so.mondayOfYear(t),e,2)},x:e(f),X:e(d),y:function(t,e){return zt(t.getFullYear()%100,e,2)},Y:function(t,e){return zt(t.getFullYear()%1e4,e,4)},Z:ue,"%":function(){return"%"}},S={a:r,A:i,b:a,B:u,c:o,d:te,e:te,H:ne,I:ne,j:ee,L:ae,m:Qt,M:re,p:l,S:ie,U:Ht,w:Gt,W:Wt,x:s,X:c,y:Xt,Y:Zt,Z:Jt,"%":oe};return e}function zt(t,e,n){var r=0>t?"-":"",i=(r?-t:t)+"",a=i.length;return r+(n>a?new Array(n-a+1).join(e)+i:i)}function Vt(t){return new RegExp("^(?:"+t.map(nu.requote).join("|")+")","i")}function $t(t){for(var e=new l,n=-1,r=t.length;++n68?1900:2e3)}function Qt(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function te(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function ee(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+3));return r?(t.j=+r[0],n+r[0].length):-1}function ne(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function re(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function ie(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function ae(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function ue(t){var e=t.getTimezoneOffset(),n=e>0?"-":"+",r=pu(e)/60|0,i=pu(e)%60;return n+zt(r,"0",2)+zt(i,"0",2)}function oe(t,e,n){po.lastIndex=0;var r=po.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function se(t){for(var e=t.length,n=-1;++n=0?1:-1,o=u*n,s=Math.cos(e),c=Math.sin(e),l=a*c,h=i*s+l*Math.cos(o),f=l*u*Math.sin(o);_o.add(Math.atan2(f,h)),r=t,i=s,a=c}var e,n,r,i,a;xo.point=function(u,o){xo.point=t,r=(e=u)*Iu,i=Math.cos(o=(n=o)*Iu/2+Bu/4),a=Math.sin(o)},xo.lineEnd=function(){t(e,n)}}function ge(t){var e=t[0],n=t[1],r=Math.cos(n);return[r*Math.cos(e),r*Math.sin(e),Math.sin(n)]}function ye(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function me(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 ve(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function be(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function _e(t){var e=Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}function xe(t){return[Math.atan2(t[1],t[0]),nt(t[2])]}function we(t,e){return pu(t[0]-e[0])o;++o)i.point((n=t[o])[0],n[1]);return void i.lineEnd()}var s=new Be(n,t,null,!0),c=new Be(n,null,s,!1);s.o=c,a.push(s),u.push(c),s=new Be(r,t,null,!1),c=new Be(r,null,s,!0),s.o=c,a.push(s),u.push(c)}}),u.sort(e),Fe(a),Fe(u),a.length){for(var o=0,s=n,c=u.length;c>o;++o)u[o].e=s=!s;for(var l,h,f=a[0];;){for(var d=f,p=!0;d.v;)if((d=d.n)===f)return;l=d.z,i.lineStart();do{if(d.v=d.o.v=!0,d.e){if(p)for(var o=0,c=l.length;c>o;++o)i.point((h=l[o])[0],h[1]);else r(d.x,d.n.x,1,i);d=d.n}else{if(p){l=d.p.z;for(var o=l.length-1;o>=0;--o)i.point((h=l[o])[0],h[1])}else r(d.x,d.p.x,-1,i);d=d.p}d=d.o,l=d.z,p=!p}while(!d.v);i.lineEnd()}}}function Fe(t){if(e=t.length){for(var e,n,r=0,i=t[0];++r0){for(x||(a.polygonStart(),x=!0),a.lineStart();++u1&&2&e&&n.push(n.pop().concat(n.shift())),d.push(n.filter(Ne))}var d,p,g,y=e(a),m=i.invert(r[0],r[1]),v={point:u,lineStart:s,lineEnd:c,polygonStart:function(){v.point=l,v.lineStart=h,v.lineEnd=f,d=[],p=[]},polygonEnd:function(){v.point=u,v.lineStart=s,v.lineEnd=c,d=nu.merge(d);var t=je(m,p);d.length?(x||(a.polygonStart(),x=!0),Te(d,Ie,t,n,a)):t&&(x||(a.polygonStart(),x=!0),a.lineStart(),n(null,null,1,a),a.lineEnd()),x&&(a.polygonEnd(),x=!1),d=p=null},sphere:function(){a.polygonStart(),a.lineStart(),n(null,null,1,a),a.lineEnd(),a.polygonEnd()}},b=Oe(),_=e(b),x=!1;return v}}function Ne(t){return t.length>1}function Oe(){var t,e=[];return{lineStart:function(){e.push(t=[])},point:function(e,n){t.push([e,n])},lineEnd:w,buffer:function(){var n=e;return e=[],t=null,n},rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))}}}function Ie(t,e){return((t=t.x)[0]<0?t[1]-Ou-Tu:Ou-t[1])-((e=e.x)[0]<0?e[1]-Ou-Tu:Ou-e[1])}function Re(t){var e,n=0/0,r=0/0,i=0/0;return{lineStart:function(){t.lineStart(),e=1},point:function(a,u){var o=a>0?Bu:-Bu,s=pu(a-n);pu(s-Bu)0?Ou:-Ou),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(o,r),t.point(a,r),e=0):i!==o&&s>=Bu&&(pu(n-i)Tu?Math.atan((Math.sin(e)*(a=Math.cos(r))*Math.sin(n)-Math.sin(r)*(i=Math.cos(e))*Math.sin(t))/(i*a*u)):(e+r)/2}function qe(t,e,n,r){var i;if(null==t)i=n*Ou,r.point(-Bu,i),r.point(0,i),r.point(Bu,i),r.point(Bu,0),r.point(Bu,-i),r.point(0,-i),r.point(-Bu,-i),r.point(-Bu,0),r.point(-Bu,i);else if(pu(t[0]-e[0])>Tu){var a=t[0]o;++o){var c=e[o],l=c.length;if(l)for(var h=c[0],f=h[0],d=h[1]/2+Bu/4,p=Math.sin(d),g=Math.cos(d),y=1;;){y===l&&(y=0),t=c[y];var m=t[0],v=t[1]/2+Bu/4,b=Math.sin(v),_=Math.cos(v),x=m-f,w=x>=0?1:-1,A=w*x,E=A>Bu,k=p*b;if(_o.add(Math.atan2(k*w*Math.sin(A),g*_+k*Math.cos(A))),a+=E?x+w*Lu:x,E^f>=n^m>=n){var D=me(ge(h),ge(t));_e(D);var C=me(i,D);_e(C);var M=(E^x>=0?-1:1)*nt(C[2]);(r>M||r===M&&(D[0]||D[1]))&&(u+=E^x>=0?1:-1)}if(!y++)break;f=m,p=b,g=_,h=t}}return(-Tu>a||Tu>a&&0>_o)^1&u}function Ue(t){function e(t,e){return Math.cos(t)*Math.cos(e)>a}function n(t){var n,a,s,c,l;return{lineStart:function(){c=s=!1,l=1},point:function(h,f){var d,p=[h,f],g=e(h,f),y=u?g?0:i(h,f):g?i(h+(0>h?Bu:-Bu),f):0;if(!n&&(c=s=g)&&t.lineStart(),g!==s&&(d=r(n,p),(we(n,d)||we(p,d))&&(p[0]+=Tu,p[1]+=Tu,g=e(p[0],p[1]))),g!==s)l=0,g?(t.lineStart(),d=r(p,n),t.point(d[0],d[1])):(d=r(n,p),t.point(d[0],d[1]),t.lineEnd()),n=d;else if(o&&n&&u^g){var m;y&a||!(m=r(p,n,!0))||(l=0,u?(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])))}!g||n&&we(n,p)||t.point(p[0],p[1]),n=p,s=g,a=y},lineEnd:function(){s&&t.lineEnd(),n=null},clean:function(){return l|(c&&s)<<1}}}function r(t,e,n){var r=ge(t),i=ge(e),u=[1,0,0],o=me(r,i),s=ye(o,o),c=o[0],l=s-c*c;if(!l)return!n&&t;var h=a*s/l,f=-a*c/l,d=me(u,o),p=be(u,h),g=be(o,f);ve(p,g);var y=d,m=ye(p,y),v=ye(y,y),b=m*m-v*(ye(p,p)-1);if(!(0>b)){var _=Math.sqrt(b),x=be(y,(-m-_)/v);if(ve(x,p),x=xe(x),!n)return x;var w,A=t[0],E=e[0],k=t[1],D=e[1];A>E&&(w=A,A=E,E=w);var C=E-A,M=pu(C-Bu)C;if(!M&&k>D&&(w=k,k=D,D=w),S?M?k+D>0^x[1]<(pu(x[0]-A)Bu^(A<=x[0]&&x[0]<=E)){var T=be(y,(-m+_)/v);return ve(T,p),[x,xe(T)]}}}function i(e,n){var r=u?t:Bu-t,i=0;return-r>e?i|=1:e>r&&(i|=2),-r>n?i|=4:n>r&&(i|=8),i}var a=Math.cos(t),u=a>0,o=pu(a)>Tu,s=gn(t,6*Iu);return Le(e,n,s,u?[0,-t]:[-Bu,t-Bu])}function Ye(t,e,n,r){return function(i){var a,u=i.a,o=i.b,s=u.x,c=u.y,l=o.x,h=o.y,f=0,d=1,p=l-s,g=h-c;if(a=t-s,p||!(a>0)){if(a/=p,0>p){if(f>a)return;d>a&&(d=a)}else if(p>0){if(a>d)return;a>f&&(f=a)}if(a=n-s,p||!(0>a)){if(a/=p,0>p){if(a>d)return;a>f&&(f=a)}else if(p>0){if(f>a)return;d>a&&(d=a)}if(a=e-c,g||!(a>0)){if(a/=g,0>g){if(f>a)return;d>a&&(d=a)}else if(g>0){if(a>d)return;a>f&&(f=a)}if(a=r-c,g||!(0>a)){if(a/=g,0>g){if(a>d)return;a>f&&(f=a)}else if(g>0){if(f>a)return;d>a&&(d=a)}return f>0&&(i.a={x:s+f*p,y:c+f*g}),1>d&&(i.b={x:s+d*p,y:c+d*g}),i}}}}}}function ze(t,e,n,r){function i(r,i){return pu(r[0]-t)0?0:3:pu(r[0]-n)0?2:1:pu(r[1]-e)0?1:0:i>0?3:2}function a(t,e){return u(t.x,e.x)}function u(t,e){var n=i(t,1),r=i(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){function s(t){for(var e=0,n=y.length,r=t[1],i=0;n>i;++i)for(var a,u=1,o=y[i],s=o.length,c=o[0];s>u;++u)a=o[u],c[1]<=r?a[1]>r&&tt(c,a,t)>0&&++e:a[1]<=r&&tt(c,a,t)<0&&--e,c=a;return 0!==e}function c(a,o,s,c){var l=0,h=0;if(null==a||(l=i(a,s))!==(h=i(o,s))||u(a,o)<0^s>0){do c.point(0===l||3===l?t:n,l>1?r:e);while((l=(l+s+4)%4)!==h)}else c.point(o[0],o[1])}function l(i,a){return i>=t&&n>=i&&a>=e&&r>=a}function h(t,e){l(t,e)&&o.point(t,e)}function f(){S.point=p,y&&y.push(m=[]),E=!0,A=!1,x=w=0/0}function d(){g&&(p(v,b),_&&A&&C.rejoin(),g.push(C.buffer())),S.point=h,A&&o.lineEnd()}function p(t,e){t=Math.max(-No,Math.min(No,t)),e=Math.max(-No,Math.min(No,e));var n=l(t,e);if(y&&m.push([t,e]),E)v=t,b=e,_=n,E=!1,n&&(o.lineStart(),o.point(t,e));else if(n&&A)o.point(t,e);else{var r={a:{x:x,y:w},b:{x:t,y:e}};M(r)?(A||(o.lineStart(),o.point(r.a.x,r.a.y)),o.point(r.b.x,r.b.y),n||o.lineEnd(),k=!1):n&&(o.lineStart(),o.point(t,e),k=!1)}x=t,w=e,A=n}var g,y,m,v,b,_,x,w,A,E,k,D=o,C=Ne(),M=Ye(t,e,n,r),S={point:h,lineStart:f,lineEnd:d,polygonStart:function(){o=C,g=[],y=[],k=!0},polygonEnd:function(){o=D,g=nu.merge(g);var e=s([t,r]),n=k&&e,i=g.length;(n||i)&&(o.polygonStart(),n&&(o.lineStart(),c(null,null,1,o),o.lineEnd()),i&&Te(g,a,e,c,o),o.polygonEnd()),g=y=m=null}};return S}}function Ve(t){var e=0,n=Bu/3,r=on(t),i=r(e,n);return i.parallels=function(t){return arguments.length?r(e=t[0]*Bu/180,n=t[1]*Bu/180):[e/Bu*180,n/Bu*180]},i}function $e(t,e){function n(t,e){var n=Math.sqrt(a-2*i*Math.sin(e))/i;return[n*Math.sin(t*=i),u-n*Math.cos(t)]}var r=Math.sin(t),i=(r+Math.sin(e))/2,a=1+r*(2*i-r),u=Math.sqrt(a)/i;return n.invert=function(t,e){var n=u-e;return[Math.atan2(t,n)/i,nt((a-(t*t+n*n)*i*i)/(2*i))]},n}function Ge(){function t(t,e){Po+=i*t-r*e,r=t,i=e}var e,n,r,i;Yo.point=function(a,u){Yo.point=t,e=r=a,n=i=u},Yo.lineEnd=function(){t(e,n)}}function He(t,e){Ro>t&&(Ro=t),t>jo&&(jo=t),qo>e&&(qo=e),e>Uo&&(Uo=e)}function We(){function t(t,e){u.push("M",t,",",e,a)}function e(t,e){u.push("M",t,",",e),o.point=n}function n(t,e){u.push("L",t,",",e)}function r(){o.point=t}function i(){u.push("Z")}var a=Ze(4.5),u=[],o={point:t,lineStart:function(){o.point=e},lineEnd:r,polygonStart:function(){o.lineEnd=i},polygonEnd:function(){o.lineEnd=r,o.point=t},pointRadius:function(t){return a=Ze(t),o},result:function(){if(u.length){var t=u.join("");return u=[],t}}};return o}function Ze(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}function Xe(t,e){Eo+=t,ko+=e,++Do}function Ke(){function t(t,r){var i=t-e,a=r-n,u=Math.sqrt(i*i+a*a);Co+=u*(e+t)/2,Mo+=u*(n+r)/2,So+=u,Xe(e=t,n=r)}var e,n;Vo.point=function(r,i){Vo.point=t,Xe(e=r,n=i)}}function Je(){Vo.point=Xe}function Qe(){function t(t,e){var n=t-r,a=e-i,u=Math.sqrt(n*n+a*a);Co+=u*(r+t)/2,Mo+=u*(i+e)/2,So+=u,u=i*t-r*e,To+=u*(r+t),Fo+=u*(i+e),Bo+=3*u,Xe(r=t,i=e)}var e,n,r,i;Vo.point=function(a,u){Vo.point=t,Xe(e=r=a,n=i=u)},Vo.lineEnd=function(){t(e,n)}}function tn(t){function e(e,n){t.moveTo(e+u,n),t.arc(e,n,u,0,Lu)}function n(e,n){t.moveTo(e,n),o.point=r}function r(e,n){t.lineTo(e,n)}function i(){o.point=e}function a(){t.closePath()}var u=4.5,o={point:e,lineStart:function(){o.point=n},lineEnd:i,polygonStart:function(){o.lineEnd=a},polygonEnd:function(){o.lineEnd=i,o.point=e},pointRadius:function(t){return u=t,o},result:w};return o}function en(t){function e(t){return(o?r:n)(t)}function n(e){return an(e,function(n,r){n=t(n,r),e.point(n[0],n[1])})}function r(e){function n(n,r){n=t(n,r),e.point(n[0],n[1])}function r(){b=0/0,E.point=a,e.lineStart()}function a(n,r){var a=ge([n,r]),u=t(n,r);i(b,_,v,x,w,A,b=u[0],_=u[1],v=n,x=a[0],w=a[1],A=a[2],o,e),e.point(b,_)}function u(){E.point=n,e.lineEnd()}function s(){r(),E.point=c,E.lineEnd=l}function c(t,e){a(h=t,f=e),d=b,p=_,g=x,y=w,m=A,E.point=a}function l(){i(b,_,v,x,w,A,d,p,h,g,y,m,o,e),E.lineEnd=u,u()}var h,f,d,p,g,y,m,v,b,_,x,w,A,E={point:n,lineStart:r,lineEnd:u,polygonStart:function(){e.polygonStart(),E.lineStart=s},polygonEnd:function(){e.polygonEnd(),E.lineStart=r}};return E}function i(e,n,r,o,s,c,l,h,f,d,p,g,y,m){var v=l-e,b=h-n,_=v*v+b*b;if(_>4*a&&y--){var x=o+d,w=s+p,A=c+g,E=Math.sqrt(x*x+w*w+A*A),k=Math.asin(A/=E),D=pu(pu(A)-1)a||pu((v*T+b*F)/_-.5)>.3||u>o*d+s*p+c*g)&&(i(e,n,r,o,s,c,M,S,D,x/=E,w/=E,A,y,m),m.point(M,S),i(M,S,D,x,w,A,l,h,f,d,p,g,y,m))}}var a=.5,u=Math.cos(30*Iu),o=16;return e.precision=function(t){return arguments.length?(o=(a=t*t)>0&&16,e):Math.sqrt(a)},e}function nn(t){var e=en(function(e,n){return t([e*Pu,n*Pu])});return function(t){return sn(e(t))}}function rn(t){this.stream=t}function an(t,e){return{point:e,sphere:function(){t.sphere()},lineStart:function(){t.lineStart()},lineEnd:function(){t.lineEnd()},polygonStart:function(){t.polygonStart()},polygonEnd:function(){t.polygonEnd()}}}function un(t){return on(function(){return t})()}function on(t){function e(t){return t=o(t[0]*Iu,t[1]*Iu),[t[0]*f+s,c-t[1]*f]}function n(t){return t=o.invert((t[0]-s)/f,(c-t[1])/f),t&&[t[0]*Pu,t[1]*Pu]}function r(){o=Me(u=hn(m,v,_),a);var t=a(g,y);return s=d-t[0]*f,c=p+t[1]*f,i()}function i(){return l&&(l.valid=!1,l=null),e}var a,u,o,s,c,l,h=en(function(t,e){return t=a(t,e),[t[0]*f+s,c-t[1]*f]}),f=150,d=480,p=250,g=0,y=0,m=0,v=0,_=0,x=Oo,w=b,A=null,E=null;return e.stream=function(t){return l&&(l.valid=!1),l=sn(x(u,h(w(t)))),l.valid=!0,l},e.clipAngle=function(t){return arguments.length?(x=null==t?(A=t,Oo):Ue((A=+t)*Iu),i()):A},e.clipExtent=function(t){return arguments.length?(E=t,w=t?ze(t[0][0],t[0][1],t[1][0],t[1][1]):b,i()):E},e.scale=function(t){return arguments.length?(f=+t,r()):f},e.translate=function(t){return arguments.length?(d=+t[0],p=+t[1],r()):[d,p]},e.center=function(t){return arguments.length?(g=t[0]%360*Iu,y=t[1]%360*Iu,r()):[g*Pu,y*Pu]},e.rotate=function(t){return arguments.length?(m=t[0]%360*Iu,v=t[1]%360*Iu,_=t.length>2?t[2]%360*Iu:0,r()):[m*Pu,v*Pu,_*Pu]},nu.rebind(e,h,"precision"),function(){return a=t.apply(this,arguments),e.invert=a.invert&&n,r()}}function sn(t){return an(t,function(e,n){t.point(e*Iu,n*Iu)})}function cn(t,e){return[t,e]}function ln(t,e){return[t>Bu?t-Lu:-Bu>t?t+Lu:t,e]}function hn(t,e,n){return t?e||n?Me(dn(t),pn(e,n)):dn(t):e||n?pn(e,n):ln}function fn(t){return function(e,n){return e+=t,[e>Bu?e-Lu:-Bu>e?e+Lu:e,n]}}function dn(t){var e=fn(t);return e.invert=fn(-t),e}function pn(t,e){function n(t,e){var n=Math.cos(e),o=Math.cos(t)*n,s=Math.sin(t)*n,c=Math.sin(e),l=c*r+o*i;return[Math.atan2(s*a-l*u,o*r-c*i),nt(l*a+s*u)]}var r=Math.cos(t),i=Math.sin(t),a=Math.cos(e),u=Math.sin(e);return n.invert=function(t,e){var n=Math.cos(e),o=Math.cos(t)*n,s=Math.sin(t)*n,c=Math.sin(e),l=c*a-s*u;return[Math.atan2(s*a+c*u,o*r+l*i),nt(l*r-o*i)]},n}function gn(t,e){var n=Math.cos(t),r=Math.sin(t);return function(i,a,u,o){var s=u*e;null!=i?(i=yn(n,i),a=yn(n,a),(u>0?a>i:i>a)&&(i+=u*Lu)):(i=t+u*Lu,a=t-.5*s);for(var c,l=i;u>0?l>a:a>l;l-=s)o.point((c=xe([n,-r*Math.cos(l),-r*Math.sin(l)]))[0],c[1])}}function yn(t,e){var n=ge(e);n[0]-=t,_e(n);var r=et(-n[1]);return((-n[2]<0?-r:r)+2*Math.PI-Tu)%(2*Math.PI)}function mn(t,e,n){var r=nu.range(t,e-Tu,n).concat(e);return function(t){return r.map(function(e){return[t,e]})}}function vn(t,e,n){var r=nu.range(t,e-Tu,n).concat(e);return function(t){return r.map(function(e){return[e,t]})}}function bn(t){return t.source}function _n(t){return t.target}function xn(t,e,n,r){var i=Math.cos(e),a=Math.sin(e),u=Math.cos(r),o=Math.sin(r),s=i*Math.cos(t),c=i*Math.sin(t),l=u*Math.cos(n),h=u*Math.sin(n),f=2*Math.asin(Math.sqrt(ut(r-e)+i*u*ut(n-t))),d=1/Math.sin(f),p=f?function(t){var e=Math.sin(t*=f)*d,n=Math.sin(f-t)*d,r=n*s+e*l,i=n*c+e*h,u=n*a+e*o;return[Math.atan2(i,r)*Pu,Math.atan2(u,Math.sqrt(r*r+i*i))*Pu]}:function(){return[t*Pu,e*Pu]};return p.distance=f,p}function wn(){function t(t,i){var a=Math.sin(i*=Iu),u=Math.cos(i),o=pu((t*=Iu)-e),s=Math.cos(o);$o+=Math.atan2(Math.sqrt((o=u*Math.sin(o))*o+(o=r*a-n*u*s)*o),n*a+r*u*s),e=t,n=a,r=u}var e,n,r;Go.point=function(i,a){e=i*Iu,n=Math.sin(a*=Iu),r=Math.cos(a),Go.point=t},Go.lineEnd=function(){Go.point=Go.lineEnd=w}}function An(t,e){function n(e,n){var r=Math.cos(e),i=Math.cos(n),a=t(r*i);return[a*i*Math.sin(e),a*Math.sin(n)]}return n.invert=function(t,n){var r=Math.sqrt(t*t+n*n),i=e(r),a=Math.sin(i),u=Math.cos(i);return[Math.atan2(t*a,r*u),Math.asin(r&&n*a/r)]},n}function En(t,e){function n(t,e){u>0?-Nu+Tu>e&&(e=-Nu+Tu):e>Nu-Tu&&(e=Nu-Tu);var n=u/Math.pow(i(e),a);return[n*Math.sin(a*t),u-n*Math.cos(a*t)]}var r=Math.cos(t),i=function(t){return Math.tan(Bu/4+t/2)},a=t===e?Math.sin(t):Math.log(r/Math.cos(e))/Math.log(i(e)/i(t)),u=r*Math.pow(i(t),a)/a;return a?(n.invert=function(t,e){var n=u-e,r=Q(a)*Math.sqrt(t*t+n*n);return[Math.atan2(t,n)/a,2*Math.atan(Math.pow(u/r,1/a))-Nu]},n):Dn}function kn(t,e){function n(t,e){var n=a-e;return[n*Math.sin(i*t),a-n*Math.cos(i*t)]}var r=Math.cos(t),i=t===e?Math.sin(t):(r-Math.cos(e))/(e-t),a=r/i+t;return pu(i)i;i++){for(;r>1&&tt(t[n[r-2]],t[n[r-1]],t[i])<=0;)--r;n[r++]=i}return n.slice(0,r)}function Bn(t,e){return t[0]-e[0]||t[1]-e[1]}function Ln(t,e,n){return(n[0]-e[0])*(t[1]-e[1])<(n[1]-e[1])*(t[0]-e[0])}function On(t,e,n,r){var i=t[0],a=n[0],u=e[0]-i,o=r[0]-a,s=t[1],c=n[1],l=e[1]-s,h=r[1]-c,f=(o*(s-c)-h*(i-a))/(h*u-o*l);return[i+f*u,s+f*l]}function Nn(t){var e=t[0],n=t[t.length-1];return!(e[0]-n[0]||e[1]-n[1])}function In(){rr(this),this.edge=this.site=this.circle=null}function Pn(t){var e=is.pop()||new In;return e.site=t,e}function Rn(t){Wn(t),es.remove(t),is.push(t),rr(t)}function qn(t){var e=t.circle,n=e.x,r=e.cy,i={x:n,y:r},a=t.P,u=t.N,o=[t];Rn(t);for(var s=a;s.circle&&pu(n-s.circle.x)l;++l)c=o[l],s=o[l-1],tr(c.edge,s.site,c.site,i);s=o[0],c=o[h-1],c.edge=Jn(s.site,c.site,null,i),Hn(s),Hn(c)}function jn(t){for(var e,n,r,i,a=t.x,u=t.y,o=es._;o;)if(r=Un(o,u)-a,r>Tu)o=o.L;else{if(i=a-Yn(o,u),!(i>Tu)){r>-Tu?(e=o.P,n=o):i>-Tu?(e=o,n=o.N):e=n=o;break}if(!o.R){e=o;break}o=o.R}var s=Pn(t);if(es.insert(e,s),e||n){if(e===n)return Wn(e),n=Pn(e.site),es.insert(s,n),s.edge=n.edge=Jn(e.site,s.site),Hn(e),void Hn(n);if(!n)return void(s.edge=Jn(e.site,s.site));Wn(e),Wn(n);var c=e.site,l=c.x,h=c.y,f=t.x-l,d=t.y-h,p=n.site,g=p.x-l,y=p.y-h,m=2*(f*y-d*g),v=f*f+d*d,b=g*g+y*y,_={x:(y*v-d*b)/m+l,y:(f*b-g*v)/m+h};tr(n.edge,c,p,_),s.edge=Jn(c,t,null,_),n.edge=Jn(t,p,null,_),Hn(e),Hn(n)}}function Un(t,e){var n=t.site,r=n.x,i=n.y,a=i-e;if(!a)return r;var u=t.P;if(!u)return-(1/0);n=u.site;var o=n.x,s=n.y,c=s-e;if(!c)return o;var l=o-r,h=1/a-1/c,f=l/c;return h?(-f+Math.sqrt(f*f-2*h*(l*l/(-2*c)-s+c/2+i-a/2)))/h+r:(r+o)/2}function Yn(t,e){var n=t.N;if(n)return Un(n,e);var r=t.site;return r.y===e?r.x:1/0}function zn(t){this.site=t,this.edges=[]}function Vn(t){for(var e,n,r,i,a,u,o,s,c,l,h=t[0][0],f=t[1][0],d=t[0][1],p=t[1][1],g=ts,y=g.length;y--;)if(a=g[y],a&&a.prepare())for(o=a.edges,s=o.length,u=0;s>u;)l=o[u].end(),r=l.x,i=l.y,c=o[++u%s].start(),e=c.x,n=c.y,(pu(r-e)>Tu||pu(i-n)>Tu)&&(o.splice(u,0,new er(Qn(a.site,l,pu(r-h)Tu?{x:h,y:pu(e-h)Tu?{x:pu(n-p)Tu?{x:f,y:pu(e-f)Tu?{x:pu(n-d)=-Fu)){var d=s*s+c*c,p=l*l+h*h,g=(h*d-c*p)/f,y=(s*p-l*d)/f,h=y+o,m=as.pop()||new Gn;m.arc=t,m.site=i,m.x=g+u,m.y=h+Math.sqrt(g*g+y*y),m.cy=h,t.circle=m;for(var v=null,b=rs._;b;)if(m.yy||y>=o)return;if(f>p){if(a){if(a.y>=c)return}else a={x:y,y:s};n={x:y,y:c}}else{if(a){if(a.yr||r>1)if(f>p){if(a){if(a.y>=c)return}else a={x:(s-i)/r,y:s};n={x:(c-i)/r,y:c}}else{if(a){if(a.yd){if(a){if(a.x>=o)return}else a={x:u,y:r*u+i};n={x:o,y:r*o+i}}else{if(a){if(a.xa||h>u||r>f||i>d)){if(p=t.point){var p,g=e-t.x,y=n-t.y,m=g*g+y*y;if(s>m){var v=Math.sqrt(s=m);r=e-v,i=n-v,a=e+v,u=n+v,o=p}}for(var b=t.nodes,_=.5*(l+f),x=.5*(h+d),w=e>=_,A=n>=x,E=A<<1|w,k=E+4;k>E;++E)if(t=b[3&E])switch(3&E){case 0:c(t,l,h,_,x);break;case 1:c(t,_,h,f,x);break;case 2:c(t,l,x,_,d);break;case 3:c(t,_,x,f,d)}}}(t,r,i,a,u),o}function gr(t,e){t=nu.rgb(t),e=nu.rgb(e);var n=t.r,r=t.g,i=t.b,a=e.r-n,u=e.g-r,o=e.b-i;return function(t){return"#"+xt(Math.round(n+a*t))+xt(Math.round(r+u*t))+xt(Math.round(i+o*t))}}function yr(t,e){var n,r={},i={};for(n in t)n in e?r[n]=br(t[n],e[n]):i[n]=t[n];for(n in e)n in t||(i[n]=e[n]);return function(t){for(n in r)i[n]=r[n](t);return i}}function mr(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function vr(t,e){var n,r,i,a=os.lastIndex=ss.lastIndex=0,u=-1,o=[],s=[];for(t+="",e+="";(n=os.exec(t))&&(r=ss.exec(e));)(i=r.index)>a&&(i=e.slice(a,i),o[u]?o[u]+=i:o[++u]=i),(n=n[0])===(r=r[0])?o[u]?o[u]+=r:o[++u]=r:(o[++u]=null,s.push({i:u,x:mr(n,r)})),a=ss.lastIndex;return ar;++r)o[(n=s[r]).i]=n.x(t);return o.join("")})}function br(t,e){for(var n,r=nu.interpolators.length;--r>=0&&!(n=nu.interpolators[r](t,e)););return n}function _r(t,e){var n,r=[],i=[],a=t.length,u=e.length,o=Math.min(t.length,e.length);for(n=0;o>n;++n)r.push(br(t[n],e[n]));for(;a>n;++n)i[n]=t[n];for(;u>n;++n)i[n]=e[n];return function(t){for(n=0;o>n;++n)i[n]=r[n](t);return i}}function xr(t){return function(e){return 0>=e?0:e>=1?1:t(e)}}function wr(t){return function(e){return 1-t(1-e)}}function Ar(t){return function(e){return.5*(.5>e?t(2*e):2-t(2-2*e))}}function Er(t){return t*t}function kr(t){return t*t*t}function Dr(t){if(0>=t)return 0;if(t>=1)return 1;var e=t*t,n=e*t;return 4*(.5>t?n:3*(t-e)+n-.75)}function Cr(t){return function(e){return Math.pow(e,t)}}function Mr(t){return 1-Math.cos(t*Nu)}function Sr(t){return Math.pow(2,10*(t-1))}function Tr(t){return 1-Math.sqrt(1-t*t)}function Fr(t,e){var n;return arguments.length<2&&(e=.45),arguments.length?n=e/Lu*Math.asin(1/t):(t=1,n=e/4),function(r){return 1+t*Math.pow(2,-10*r)*Math.sin((r-n)*Lu/e)}}function Br(t){return t||(t=1.70158),function(e){return e*e*((t+1)*e-t)}}function Lr(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375}function Or(t,e){t=nu.hcl(t),e=nu.hcl(e);var n=t.h,r=t.c,i=t.l,a=e.h-n,u=e.c-r,o=e.l-i;return isNaN(u)&&(u=0,r=isNaN(r)?e.c:r),isNaN(a)?(a=0,n=isNaN(n)?e.h:n):a>180?a-=360:-180>a&&(a+=360),function(t){return ht(n+a*t,r+u*t,i+o*t)+""}}function Nr(t,e){t=nu.hsl(t),e=nu.hsl(e);var n=t.h,r=t.s,i=t.l,a=e.h-n,u=e.s-r,o=e.l-i;return isNaN(u)&&(u=0,r=isNaN(r)?e.s:r),isNaN(a)?(a=0,n=isNaN(n)?e.h:n):a>180?a-=360:-180>a&&(a+=360),function(t){return ct(n+a*t,r+u*t,i+o*t)+""}}function Ir(t,e){t=nu.lab(t),e=nu.lab(e);var n=t.l,r=t.a,i=t.b,a=e.l-n,u=e.a-r,o=e.b-i;return function(t){return dt(n+a*t,r+u*t,i+o*t)+""}}function Pr(t,e){return e-=t,function(n){return Math.round(t+e*n)}}function Rr(t){var e=[t.a,t.b],n=[t.c,t.d],r=jr(e),i=qr(e,n),a=jr(Ur(n,e,-i))||0;e[0]*n[1]180?l+=360:l-c>180&&(c+=360),i.push({i:r.push(r.pop()+"rotate(",null,")")-2,x:mr(c,l)})):l&&r.push(r.pop()+"rotate("+l+")"),h!=f?i.push({i:r.push(r.pop()+"skewX(",null,")")-2,x:mr(h,f)}):f&&r.push(r.pop()+"skewX("+f+")"),d[0]!=p[0]||d[1]!=p[1]?(n=r.push(r.pop()+"scale(",null,",",null,")"),i.push({i:n-4,x:mr(d[0],p[0])},{i:n-2,x:mr(d[1],p[1])})):(1!=p[0]||1!=p[1])&&r.push(r.pop()+"scale("+p+")"),n=i.length,function(t){for(var e,a=-1;++a=0;)n.push(i[r])}function ei(t,e){for(var n=[t],r=[];null!=(t=n.pop());)if(r.push(t),(a=t.children)&&(i=a.length))for(var i,a,u=-1;++un;++n)(e=t[n][1])>i&&(r=n,i=e);return r}function fi(t){return t.reduce(di,0)}function di(t,e){return t+e[1]}function pi(t,e){return gi(t,Math.ceil(Math.log(e.length)/Math.LN2+1))}function gi(t,e){for(var n=-1,r=+t[0],i=(t[1]-r)/e,a=[];++n<=e;)a[n]=i*n+r;return a}function yi(t){return[nu.min(t),nu.max(t)]}function mi(t,e){return t.value-e.value}function vi(t,e){var n=t._pack_next;t._pack_next=e,e._pack_prev=t,e._pack_next=n,n._pack_prev=e}function bi(t,e){t._pack_next=e,e._pack_prev=t}function _i(t,e){var n=e.x-t.x,r=e.y-t.y,i=t.r+e.r;return.999*i*i>n*n+r*r}function xi(t){function e(t){l=Math.min(t.x-t.r,l),h=Math.max(t.x+t.r,h),f=Math.min(t.y-t.r,f),d=Math.max(t.y+t.r,d)}if((n=t.children)&&(c=n.length)){var n,r,i,a,u,o,s,c,l=1/0,h=-(1/0),f=1/0,d=-(1/0);if(n.forEach(wi),r=n[0],r.x=-r.r,r.y=0,e(r),c>1&&(i=n[1],i.x=i.r,i.y=0,e(i),c>2))for(a=n[2],ki(r,i,a),e(a),vi(r,a),r._pack_prev=a,vi(a,i),i=r._pack_next,u=3;c>u;u++){ki(r,i,a=n[u]);var p=0,g=1,y=1;for(o=i._pack_next;o!==i;o=o._pack_next,g++)if(_i(o,a)){p=1;break}if(1==p)for(s=r._pack_prev;s!==o._pack_prev&&!_i(s,a);s=s._pack_prev,y++);p?(y>g||g==y&&i.ru;u++)a=n[u],a.x-=m,a.y-=v,b=Math.max(b,a.r+Math.sqrt(a.x*a.x+a.y*a.y));t.r=b,n.forEach(Ai)}}function wi(t){t._pack_next=t._pack_prev=t}function Ai(t){delete t._pack_next,delete t._pack_prev}function Ei(t,e,n,r){var i=t.children;if(t.x=e+=r*t.x,t.y=n+=r*t.y,t.r*=r,i)for(var a=-1,u=i.length;++a=0;)e=i[a],e.z+=n,e.m+=n,n+=e.s+(r+=e.c)}function Fi(t,e,n){return t.a.parent===e.parent?t.a:n}function Bi(t){return 1+nu.max(t,function(t){return t.y})}function Li(t){return t.reduce(function(t,e){return t+e.x},0)/t.length}function Oi(t){var e=t.children;return e&&e.length?Oi(e[0]):t}function Ni(t){var e,n=t.children;return n&&(e=n.length)?Ni(n[e-1]):t}function Ii(t){return{x:t.x,y:t.y,dx:t.dx,dy:t.dy}}function Pi(t,e){var n=t.x+e[3],r=t.y+e[0],i=t.dx-e[1]-e[3],a=t.dy-e[0]-e[2];return 0>i&&(n+=i/2,i=0),0>a&&(r+=a/2,a=0),{x:n,y:r,dx:i,dy:a}}function Ri(t){var e=t[0],n=t[t.length-1];return n>e?[e,n]:[n,e]}function qi(t){return t.rangeExtent?t.rangeExtent():Ri(t.range())}function ji(t,e,n,r){var i=n(t[0],t[1]),a=r(e[0],e[1]);return function(t){return a(i(t))}}function Ui(t,e){var n,r=0,i=t.length-1,a=t[r],u=t[i];return a>u&&(n=r,r=i,i=n,n=a,a=u,u=n),t[r]=e.floor(a),t[i]=e.ceil(u),t}function Yi(t){return t?{floor:function(e){return Math.floor(e/t)*t},ceil:function(e){return Math.ceil(e/t)*t}}:bs}function zi(t,e,n,r){var i=[],a=[],u=0,o=Math.min(t.length,e.length)-1;for(t[o]2?zi:ji,s=r?Vr:zr;return u=i(t,e,s,n),o=i(e,t,s,br),a}function a(t){return u(t)}var u,o;return a.invert=function(t){return o(t)},a.domain=function(e){return arguments.length?(t=e.map(Number),i()):t},a.range=function(t){return arguments.length?(e=t,i()):e},a.rangeRound=function(t){return a.range(t).interpolate(Pr)},a.clamp=function(t){return arguments.length?(r=t,i()):r},a.interpolate=function(t){return arguments.length?(n=t,i()):n},a.ticks=function(e){return Wi(t,e)},a.tickFormat=function(e,n){return Zi(t,e,n)},a.nice=function(e){return Gi(t,e),i()},a.copy=function(){return Vi(t,e,n,r)},i()}function $i(t,e){return nu.rebind(t,e,"range","rangeRound","interpolate","clamp")}function Gi(t,e){return Ui(t,Yi(Hi(t,e)[2]))}function Hi(t,e){null==e&&(e=10);var n=Ri(t),r=n[1]-n[0],i=Math.pow(10,Math.floor(Math.log(r/e)/Math.LN10)),a=e/r*i;return.15>=a?i*=10:.35>=a?i*=5:.75>=a&&(i*=2),n[0]=Math.ceil(n[0]/i)*i,n[1]=Math.floor(n[1]/i)*i+.5*i,n[2]=i,n}function Wi(t,e){return nu.range.apply(nu,Hi(t,e))}function Zi(t,e,n){var r=Hi(t,e);if(n){var i=uo.exec(n);if(i.shift(),"s"===i[8]){var a=nu.formatPrefix(Math.max(pu(r[0]),pu(r[1])));return i[7]||(i[7]="."+Xi(a.scale(r[2]))),i[8]="f",n=nu.format(i.join("")),function(t){return n(a.scale(t))+a.symbol}}i[7]||(i[7]="."+Ki(i[8],r)),n=i.join("")}else n=",."+Xi(r[2])+"f";return nu.format(n)}function Xi(t){return-Math.floor(Math.log(t)/Math.LN10+.01)}function Ki(t,e){var n=Xi(e[2]);return t in _s?Math.abs(n-Xi(Math.max(pu(e[0]),pu(e[1]))))+ +("e"!==t):n-2*("%"===t)}function Ji(t,e,n,r){function i(t){return(n?Math.log(0>t?0:t):-Math.log(t>0?0:-t))/Math.log(e)}function a(t){return n?Math.pow(e,t):-Math.pow(e,-t)}function u(e){return t(i(e))}return u.invert=function(e){return a(t.invert(e))},u.domain=function(e){return arguments.length?(n=e[0]>=0,t.domain((r=e.map(Number)).map(i)),u):r},u.base=function(n){return arguments.length?(e=+n,t.domain(r.map(i)),u):e},u.nice=function(){var e=Ui(r.map(i),n?Math:ws);return t.domain(e),r=e.map(a),u},u.ticks=function(){var t=Ri(r),u=[],o=t[0],s=t[1],c=Math.floor(i(o)),l=Math.ceil(i(s)),h=e%1?2:e;if(isFinite(l-c)){if(n){for(;l>c;c++)for(var f=1;h>f;f++)u.push(a(c)*f);u.push(a(c))}else for(u.push(a(c));c++0;f--)u.push(a(c)*f);for(c=0;u[c]s;l--);u=u.slice(c,l)}return u},u.tickFormat=function(t,e){if(!arguments.length)return xs;arguments.length<2?e=xs:"function"!=typeof e&&(e=nu.format(e));var r,o=Math.max(.1,t/u.ticks().length),s=n?(r=1e-12,Math.ceil):(r=-1e-12,Math.floor);return function(t){return t/a(s(i(t)+r))<=o?e(t):""}},u.copy=function(){return Ji(t.copy(),e,n,r)},$i(u,t)}function Qi(t,e,n){function r(e){return t(i(e))}var i=ta(e),a=ta(1/e);return r.invert=function(e){return a(t.invert(e))},r.domain=function(e){return arguments.length?(t.domain((n=e.map(Number)).map(i)),r):n},r.ticks=function(t){return Wi(n,t)},r.tickFormat=function(t,e){return Zi(n,t,e)},r.nice=function(t){return r.domain(Gi(n,t))},r.exponent=function(u){return arguments.length?(i=ta(e=u),a=ta(1/e),t.domain(n.map(i)),r):e},r.copy=function(){return Qi(t.copy(),e,n)},$i(r,t)}function ta(t){return function(e){return 0>e?-Math.pow(-e,t):Math.pow(e,t)}}function ea(t,e){function n(n){return a[((i.get(n)||("range"===e.t?i.set(n,t.push(n)):0/0))-1)%a.length]}function r(e,n){return nu.range(t.length).map(function(t){return e+n*t})}var i,a,u;return n.domain=function(r){if(!arguments.length)return t;t=[],i=new l;for(var a,u=-1,o=r.length;++un?[0/0,0/0]:[n>0?o[n-1]:t[0],ne?0/0:e/a+t,[e,e+1/a]},r.copy=function(){return ra(t,e,n)},i()}function ia(t,e){function n(n){return n>=n?e[nu.bisect(t,n)]:void 0}return n.domain=function(e){return arguments.length?(t=e,n):t},n.range=function(t){return arguments.length?(e=t,n):e},n.invertExtent=function(n){return n=e.indexOf(n),[t[n-1],t[n]]},n.copy=function(){return ia(t,e)},n}function aa(t){function e(t){return+t}return e.invert=e,e.domain=e.range=function(n){return arguments.length?(t=n.map(e),e):t},e.ticks=function(e){return Wi(t,e)},e.tickFormat=function(e,n){return Zi(t,e,n)},e.copy=function(){return aa(t)},e}function ua(){return 0}function oa(t){return t.innerRadius}function sa(t){return t.outerRadius}function ca(t){return t.startAngle}function la(t){return t.endAngle}function ha(t){return t&&t.padAngle}function fa(t,e,n,r){return(t-n)*e-(e-r)*t>0?0:1}function da(t,e,n,r,i){var a=t[0]-e[0],u=t[1]-e[1],o=(i?r:-r)/Math.sqrt(a*a+u*u),s=o*u,c=-o*a,l=t[0]+s,h=t[1]+c,f=e[0]+s,d=e[1]+c,p=(l+f)/2,g=(h+d)/2,y=f-l,m=d-h,v=y*y+m*m,b=n-r,_=l*d-f*h,x=(0>m?-1:1)*Math.sqrt(b*b*v-_*_),w=(_*m-y*x)/v,A=(-_*y-m*x)/v,E=(_*m+y*x)/v,k=(-_*y+m*x)/v,D=w-p,C=A-g,M=E-p,S=k-g;return D*D+C*C>M*M+S*S&&(w=E,A=k),[[w-s,A-c],[w*n/b,A*n/b]]}function pa(t){function e(e){function u(){c.push("M",a(t(l),o))}for(var s,c=[],l=[],h=-1,f=e.length,d=Ct(n),p=Ct(r);++h1&&i.push("H",r[0]),i.join("")}function va(t){for(var e=0,n=t.length,r=t[0],i=[r[0],",",r[1]];++e1){o=e[1],a=t[s],s++,r+="C"+(i[0]+u[0])+","+(i[1]+u[1])+","+(a[0]-o[0])+","+(a[1]-o[1])+","+a[0]+","+a[1];for(var c=2;c9&&(i=3*e/Math.sqrt(i),u[o]=i*n,u[o+1]=i*r));for(o=-1;++o<=s;)i=(t[Math.min(s,o+1)][0]-t[Math.max(0,o-1)][0])/(6*(1+u[o]*u[o])),a.push([i||0,u[o]*i||0]);return a}function Oa(t){return t.length<3?ga(t):t[0]+Aa(t,La(t))}function Na(t){for(var e,n,r,i=-1,a=t.length;++ir)return l();var i=a[a.active];i&&(--a.count,delete a[a.active],i.event&&i.event.interrupt.call(t,t.__data__,i.index)),a.active=r,u.event&&u.event.start.call(t,t.__data__,e),u.tween.forEach(function(n,r){(r=r.call(t,t.__data__,e))&&g.push(r)}),f=u.ease,h=u.duration,nu.timer(function(){return p.c=c(n||1)?Se:c,1},0,o)}function c(n){if(a.active!==r)return 1;for(var i=n/h,o=f(i),s=g.length;s>0;)g[--s].call(t,o);return i>=1?(u.event&&u.event.end.call(t,t.__data__,e),l()):void 0}function l(){return--a.count?delete a[r]:delete t[n],1}var h,f,d=u.delay,p=ro,g=[];return p.t=d+o,i>=d?s(i-d):void(p.c=s)},0,o)}}function Za(t,e,n){t.attr("transform",function(t){var r=e(t);return"translate("+(isFinite(r)?r:n(t))+",0)"})}function Xa(t,e,n){t.attr("transform",function(t){var r=e(t);return"translate(0,"+(isFinite(r)?r:n(t))+")"})}function Ka(t){return t.toISOString()}function Ja(t,e,n){function r(e){return t(e)}function i(t,n){var r=t[1]-t[0],i=r/n,a=nu.bisect(Hs,i);return a==Hs.length?[e.year,Hi(t.map(function(t){return t/31536e6}),n)[2]]:a?e[i/Hs[a-1]1?{floor:function(e){for(;n(e=t.floor(e));)e=Qa(e-1);return e},ceil:function(e){for(;n(e=t.ceil(e));)e=Qa(+e+1);return e}}:t))},r.ticks=function(t,e){var n=Ri(r.domain()),a=null==t?i(n,10):"number"==typeof t?i(n,t):!t.range&&[{range:t},e];return a&&(t=a[0],e=a[1]),t.range(n[0],Qa(+n[1]+1),1>e?1:e)},r.tickFormat=function(){return n},r.copy=function(){return Ja(t.copy(),e,n)},$i(r,t)}function Qa(t){return new Date(t)}function tu(t){return JSON.parse(t.responseText)}function eu(t){var e=au.createRange();return e.selectNode(au.body),e.createContextualFragment(t.responseText)}var nu={version:"3.5.6"},ru=[].slice,iu=function(t){return ru.call(t)},au=this.document;if(au)try{iu(au.documentElement.childNodes)[0].nodeType}catch(uu){iu=function(t){for(var e=t.length,n=new Array(e);e--;)n[e]=t[e];return n}}if(Date.now||(Date.now=function(){return+new Date}),au)try{au.createElement("DIV").style.setProperty("opacity",0,"")}catch(ou){var su=this.Element.prototype,cu=su.setAttribute,lu=su.setAttributeNS,hu=this.CSSStyleDeclaration.prototype,fu=hu.setProperty;su.setAttribute=function(t,e){cu.call(this,t,e+"")},su.setAttributeNS=function(t,e,n){lu.call(this,t,e,n+"")},hu.setProperty=function(t,e,n){fu.call(this,t,e+"",n)}}nu.ascending=r,nu.descending=function(t,e){return t>e?-1:e>t?1:e>=t?0:0/0},nu.min=function(t,e){var n,r,i=-1,a=t.length;if(1===arguments.length){for(;++i=r){n=r;break}for(;++ir&&(n=r)}else{for(;++i=r){n=r;break}for(;++ir&&(n=r)}return n},nu.max=function(t,e){var n,r,i=-1,a=t.length;if(1===arguments.length){for(;++i=r){n=r;break}for(;++in&&(n=r)}else{for(;++i=r){n=r;break}for(;++in&&(n=r)}return n},nu.extent=function(t,e){var n,r,i,a=-1,u=t.length;if(1===arguments.length){for(;++a=r){n=i=r;break}for(;++ar&&(n=r),r>i&&(i=r))}else{for(;++a=r){n=i=r;break}for(;++ar&&(n=r),r>i&&(i=r))}return[n,i]},nu.sum=function(t,e){var n,r=0,i=t.length,u=-1;if(1===arguments.length)for(;++u1?s/(l-1):void 0},nu.deviation=function(){var t=nu.variance.apply(this,arguments);return t?Math.sqrt(t):t};var du=u(r);nu.bisectLeft=du.left,nu.bisect=nu.bisectRight=du.right,nu.bisector=function(t){return u(1===t.length?function(e,n){return r(t(e),n)}:t)},nu.shuffle=function(t,e,n){(a=arguments.length)<3&&(n=t.length,2>a&&(e=0));for(var r,i,a=n-e;a;)i=Math.random()*a--|0,r=t[a+e],t[a+e]=t[i+e],t[i+e]=r;return t},nu.permute=function(t,e){for(var n=e.length,r=new Array(n);n--;)r[n]=t[e[n]];return r},nu.pairs=function(t){for(var e,n=0,r=t.length-1,i=t[0],a=new Array(0>r?0:r);r>n;)a[n]=[e=i,i=t[++n]];return a},nu.zip=function(){if(!(r=arguments.length))return[];for(var t=-1,e=nu.min(arguments,o),n=new Array(e);++t=0;)for(r=t[i],e=r.length;--e>=0;)n[--u]=r[e];return n};var pu=Math.abs;nu.range=function(t,e,n){if(arguments.length<3&&(n=1,arguments.length<2&&(e=t,t=0)),(e-t)/n===1/0)throw new Error("infinite range");var r,i=[],a=s(pu(n)),u=-1;if(t*=a,e*=a,n*=a,0>n)for(;(r=t+n*++u)>e;)i.push(r/a);else for(;(r=t+n*++u)=a.length)return r?r.call(i,u):n?u.sort(n):u;for(var s,c,h,f,d=-1,p=u.length,g=a[o++],y=new l;++d=a.length)return t;var r=[],i=u[n++];return t.forEach(function(t,i){r.push({key:t,values:e(i,n)})}),i?r.sort(function(t,e){return i(t.key,e.key)}):r}var n,r,i={},a=[],u=[];return i.map=function(e,n){return t(n,e,0)},i.entries=function(n){return e(t(nu.map,n,0),0)},i.key=function(t){return a.push(t),i},i.sortKeys=function(t){return u[a.length-1]=t,i},i.sortValues=function(t){return n=t,i},i.rollup=function(t){return r=t,i},i},nu.set=function(t){var e=new v;if(t)for(var n=0,r=t.length;r>n;++n)e.add(t[n]);return e},c(v,{has:d,add:function(t){return this._[h(t+="")]=!0,t},remove:p,values:g,size:y,empty:m,forEach:function(t){for(var e in this._)t.call(this,f(e))}}),nu.behavior={},nu.rebind=function(t,e){for(var n,r=1,i=arguments.length;++r=0&&(r=t.slice(n+1),t=t.slice(0,n)),t)return arguments.length<2?this[t].on(r):this[t].on(r,e);if(2===arguments.length){if(null==e)for(t in this)this.hasOwnProperty(t)&&this[t].on(r,null);return this}},nu.event=null,nu.requote=function(t){return t.replace(vu,"\\$&")};var vu=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,bu={}.__proto__?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)t[n]=e[n]},_u=function(t,e){return e.querySelector(t)},xu=function(t,e){return e.querySelectorAll(t)},wu=function(t,e){var n=t.matches||t[x(t,"matchesSelector")];return(wu=function(t,e){return n.call(t,e)})(t,e)};"function"==typeof Sizzle&&(_u=function(t,e){return Sizzle(t,e)[0]||null},xu=Sizzle,wu=Sizzle.matchesSelector),nu.selection=function(){return nu.select(au.documentElement)};var Au=nu.selection.prototype=[];Au.select=function(t){var e,n,r,i,a=[];t=S(t);for(var u=-1,o=this.length;++u=0&&(n=t.slice(0,e),t=t.slice(e+1)),Eu.hasOwnProperty(n)?{space:Eu[n],local:t}:t}},Au.attr=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node();return t=nu.ns.qualify(t),t.local?n.getAttributeNS(t.space,t.local):n.getAttribute(t)}for(e in t)this.each(F(e,t[e]));return this}return this.each(F(t,e))},Au.classed=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node(),r=(t=O(t)).length,i=-1;if(e=n.classList){for(;++ii){if("string"!=typeof t){2>i&&(e="");for(r in t)this.each(P(r,t[r],e));return this}if(2>i){var a=this.node();return n(a).getComputedStyle(a,null).getPropertyValue(t)}r=""}return this.each(P(t,e,r))},Au.property=function(t,e){if(arguments.length<2){if("string"==typeof t)return this.node()[t];for(e in t)this.each(R(e,t[e]));return this}return this.each(R(t,e))},Au.text=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}:null==t?function(){this.textContent=""}:function(){this.textContent=t}):this.node().textContent},Au.html=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}:null==t?function(){this.innerHTML=""}:function(){this.innerHTML=t}):this.node().innerHTML},Au.append=function(t){return t=q(t),this.select(function(){return this.appendChild(t.apply(this,arguments))})},Au.insert=function(t,e){return t=q(t),e=S(e),this.select(function(){return this.insertBefore(t.apply(this,arguments),e.apply(this,arguments)||null)})},Au.remove=function(){return this.each(j)},Au.data=function(t,e){function n(t,n){var r,i,a,u=t.length,h=n.length,f=Math.min(u,h),d=new Array(h),p=new Array(h),g=new Array(u);if(e){var y,m=new l,v=new Array(u);for(r=-1;++rr;++r)p[r]=U(n[r]);for(;u>r;++r)g[r]=t[r]}p.update=d,p.parentNode=d.parentNode=g.parentNode=t.parentNode,o.push(p),s.push(d),c.push(g)}var r,i,a=-1,u=this.length;if(!arguments.length){for(t=new Array(u=(r=this[0]).length);++aa;a++){i.push(e=[]),e.parentNode=(n=this[a]).parentNode;for(var o=0,s=n.length;s>o;o++)(r=n[o])&&t.call(r,r.__data__,o,a)&&e.push(r)}return M(i)},Au.order=function(){for(var t=-1,e=this.length;++t=0;)(n=r[i])&&(a&&a!==n.nextSibling&&a.parentNode.insertBefore(n,a),a=n);return this},Au.sort=function(t){t=z.apply(this,arguments);for(var e=-1,n=this.length;++et;t++)for(var n=this[t],r=0,i=n.length;i>r;r++){var a=n[r];if(a)return a}return null},Au.size=function(){var t=0;return V(this,function(){++t}),t};var ku=[];nu.selection.enter=$,nu.selection.enter.prototype=ku,ku.append=Au.append,ku.empty=Au.empty,ku.node=Au.node,ku.call=Au.call,ku.size=Au.size,ku.select=function(t){for(var e,n,r,i,a,u=[],o=-1,s=this.length;++or){if("string"!=typeof t){2>r&&(e=!1);for(n in t)this.each(H(n,t[n],e));return this}if(2>r)return(r=this.node()["__on"+t])&&r._;n=!1}return this.each(H(t,e,n))};var Du=nu.map({mouseenter:"mouseover",mouseleave:"mouseout"});au&&Du.forEach(function(t){"on"+t in au&&Du.remove(t)});var Cu,Mu=0;nu.mouse=function(t){return K(t,D())};var Su=this.navigator&&/WebKit/.test(this.navigator.userAgent)?-1:0;nu.touch=function(t,e,n){if(arguments.length<3&&(n=e,e=D().changedTouches),e)for(var r,i=0,a=e.length;a>i;++i)if((r=e[i]).identifier===n)return K(t,r)},nu.behavior.drag=function(){function t(){this.on("mousedown.drag",a).on("touchstart.drag",u)}function e(t,e,n,a,u){return function(){function o(){var t,n,r=e(f,g);r&&(t=r[0]-b[0],n=r[1]-b[1],p|=t|n,b=r,d({type:"drag",x:r[0]+c[0],y:r[1]+c[1],dx:t,dy:n}))}function s(){e(f,g)&&(m.on(a+y,null).on(u+y,null),v(p&&nu.event.target===h),d({type:"dragend"}))}var c,l=this,h=nu.event.target,f=l.parentNode,d=r.of(l,arguments),p=0,g=t(),y=".drag"+(null==g?"":"-"+g),m=nu.select(n(h)).on(a+y,o).on(u+y,s),v=X(h),b=e(f,g);i?(c=i.apply(l,arguments),c=[c.x-b[0],c.y-b[1]]):c=[0,0],d({type:"dragstart"})}}var r=C(t,"drag","dragstart","dragend"),i=null,a=e(w,nu.mouse,n,"mousemove","mouseup"),u=e(J,nu.touch,b,"touchmove","touchend");return t.origin=function(e){return arguments.length?(i=e,t):i},nu.rebind(t,r,"on")},nu.touches=function(t,e){return arguments.length<2&&(e=D().touches),e?iu(e).map(function(e){var n=K(t,e);return n.identifier=e.identifier,n}):[]};var Tu=1e-6,Fu=Tu*Tu,Bu=Math.PI,Lu=2*Bu,Ou=Lu-Tu,Nu=Bu/2,Iu=Bu/180,Pu=180/Bu,Ru=Math.SQRT2,qu=2,ju=4;nu.interpolateZoom=function(t,e){function n(t){var e=t*v;if(m){var n=it(g),u=a/(qu*f)*(n*at(Ru*e+g)-rt(g));return[r+u*c,i+u*l,a*n/it(Ru*e+g)]}return[r+t*c,i+t*l,a*Math.exp(Ru*e)]}var r=t[0],i=t[1],a=t[2],u=e[0],o=e[1],s=e[2],c=u-r,l=o-i,h=c*c+l*l,f=Math.sqrt(h),d=(s*s-a*a+ju*h)/(2*a*qu*f),p=(s*s-a*a-ju*h)/(2*s*qu*f),g=Math.log(Math.sqrt(d*d+1)-d),y=Math.log(Math.sqrt(p*p+1)-p),m=y-g,v=(m||Math.log(s/a))/Ru;return n.duration=1e3*v,n},nu.behavior.zoom=function(){function t(t){t.on(F,h).on(Yu+".zoom",d).on("dblclick.zoom",p).on(O,f)}function e(t){return[(t[0]-E.x)/E.k,(t[1]-E.y)/E.k]}function r(t){return[t[0]*E.k+E.x,t[1]*E.k+E.y]}function i(t){E.k=Math.max(M[0],Math.min(M[1],t))}function a(t,e){e=r(e),E.x+=t[0]-e[0],E.y+=t[1]-e[1]}function u(e,n,r,u){e.__chart__={x:E.x,y:E.y,k:E.k},i(Math.pow(2,u)),a(y=n,r),e=nu.select(e),S>0&&(e=e.transition().duration(S)),e.call(t.event)}function o(){x&&x.domain(_.range().map(function(t){return(t-E.x)/E.k}).map(_.invert)),A&&A.domain(w.range().map(function(t){return(t-E.y)/E.k}).map(w.invert))}function s(t){T++||t({type:"zoomstart"})}function c(t){o(),t({type:"zoom",scale:E.k,translate:[E.x,E.y]})}function l(t){--T||(t({type:"zoomend"}),y=null)}function h(){function t(){h=1,a(nu.mouse(i),d),c(o)}function r(){f.on(B,null).on(L,null),p(h&&nu.event.target===u),l(o)}var i=this,u=nu.event.target,o=N.of(i,arguments),h=0,f=nu.select(n(i)).on(B,t).on(L,r),d=e(nu.mouse(i)),p=X(i);Ps.call(i),s(o)}function f(){function t(){var t=nu.touches(p);return d=E.k,t.forEach(function(t){t.identifier in y&&(y[t.identifier]=e(t))}),t}function n(){var e=nu.event.target;nu.select(e).on(_,r).on(x,o),w.push(e);for(var n=nu.event.changedTouches,i=0,a=n.length;a>i;++i)y[n[i].identifier]=null;var s=t(),c=Date.now();if(1===s.length){if(500>c-b){var l=s[0];u(p,l,y[l.identifier],Math.floor(Math.log(E.k)/Math.LN2)+1),k()}b=c}else if(s.length>1){var l=s[0],h=s[1],f=l[0]-h[0],d=l[1]-h[1];m=f*f+d*d}}function r(){var t,e,n,r,u=nu.touches(p);Ps.call(p);for(var o=0,s=u.length;s>o;++o,r=null)if(n=u[o],r=y[n.identifier]){if(e)break;t=n,e=r}if(r){var l=(l=n[0]-t[0])*l+(l=n[1]-t[1])*l,h=m&&Math.sqrt(l/m);t=[(t[0]+n[0])/2,(t[1]+n[1])/2],e=[(e[0]+r[0])/2,(e[1]+r[1])/2],i(h*d)}b=null,a(t,e),c(g)}function o(){if(nu.event.touches.length){for(var e=nu.event.changedTouches,n=0,r=e.length;r>n;++n)delete y[e[n].identifier];for(var i in y)return void t()}nu.selectAll(w).on(v,null),A.on(F,h).on(O,f),D(),l(g)}var d,p=this,g=N.of(p,arguments),y={},m=0,v=".zoom-"+nu.event.changedTouches[0].identifier,_="touchmove"+v,x="touchend"+v,w=[],A=nu.select(p),D=X(p);n(),s(g),A.on(F,null).on(O,n)}function d(){var t=N.of(this,arguments);v?clearTimeout(v):(Ps.call(this),g=e(y=m||nu.mouse(this)),s(t)),v=setTimeout(function(){v=null,l(t)},50),k(),i(Math.pow(2,.002*Uu())*E.k),a(y,g),c(t)}function p(){var t=nu.mouse(this),n=Math.log(E.k)/Math.LN2;u(this,t,e(t),nu.event.shiftKey?Math.ceil(n)-1:Math.floor(n)+1)}var g,y,m,v,b,_,x,w,A,E={x:0,y:0,k:1},D=[960,500],M=zu,S=250,T=0,F="mousedown.zoom",B="mousemove.zoom",L="mouseup.zoom",O="touchstart.zoom",N=C(t,"zoomstart","zoom","zoomend");return Yu||(Yu="onwheel"in au?(Uu=function(){return-nu.event.deltaY*(nu.event.deltaMode?120:1)},"wheel"):"onmousewheel"in au?(Uu=function(){return nu.event.wheelDelta},"mousewheel"):(Uu=function(){return-nu.event.detail},"MozMousePixelScroll")),t.event=function(t){t.each(function(){var t=N.of(this,arguments),e=E;Ns?nu.select(this).transition().each("start.zoom",function(){E=this.__chart__||{x:0,y:0,k:1},s(t)}).tween("zoom:zoom",function(){var n=D[0],r=D[1],i=y?y[0]:n/2,a=y?y[1]:r/2,u=nu.interpolateZoom([(i-E.x)/E.k,(a-E.y)/E.k,n/E.k],[(i-e.x)/e.k,(a-e.y)/e.k,n/e.k]);return function(e){var r=u(e),o=n/r[2];this.__chart__=E={x:i-r[0]*o,y:a-r[1]*o,k:o},c(t)}}).each("interrupt.zoom",function(){l(t)}).each("end.zoom",function(){l(t)}):(this.__chart__=E,s(t),c(t),l(t))})},t.translate=function(e){return arguments.length?(E={x:+e[0],y:+e[1],k:E.k},o(),t):[E.x,E.y]},t.scale=function(e){return arguments.length?(E={x:E.x,y:E.y,k:+e},o(),t):E.k},t.scaleExtent=function(e){return arguments.length?(M=null==e?zu:[+e[0],+e[1]],t):M},t.center=function(e){return arguments.length?(m=e&&[+e[0],+e[1]],t):m},t.size=function(e){return arguments.length?(D=e&&[+e[0],+e[1]],t):D},t.duration=function(e){return arguments.length?(S=+e,t):S},t.x=function(e){return arguments.length?(x=e,_=e.copy(),E={x:0,y:0,k:1},t):x},t.y=function(e){return arguments.length?(A=e,w=e.copy(),E={x:0,y:0,k:1},t):A},nu.rebind(t,N,"on")};var Uu,Yu,zu=[0,1/0];nu.color=ot,ot.prototype.toString=function(){return this.rgb()+""},nu.hsl=st;var Vu=st.prototype=new ot;Vu.brighter=function(t){return t=Math.pow(.7,arguments.length?t:1),new st(this.h,this.s,this.l/t)},Vu.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new st(this.h,this.s,t*this.l)},Vu.rgb=function(){return ct(this.h,this.s,this.l)},nu.hcl=lt;var $u=lt.prototype=new ot;$u.brighter=function(t){return new lt(this.h,this.c,Math.min(100,this.l+Gu*(arguments.length?t:1)))},$u.darker=function(t){return new lt(this.h,this.c,Math.max(0,this.l-Gu*(arguments.length?t:1)))},$u.rgb=function(){return ht(this.h,this.c,this.l).rgb()},nu.lab=ft;var Gu=18,Hu=.95047,Wu=1,Zu=1.08883,Xu=ft.prototype=new ot;Xu.brighter=function(t){return new ft(Math.min(100,this.l+Gu*(arguments.length?t:1)),this.a,this.b)},Xu.darker=function(t){return new ft(Math.max(0,this.l-Gu*(arguments.length?t:1)),this.a,this.b)},Xu.rgb=function(){return dt(this.l,this.a,this.b)},nu.rgb=vt;var Ku=vt.prototype=new ot;Ku.brighter=function(t){t=Math.pow(.7,arguments.length?t:1);var e=this.r,n=this.g,r=this.b,i=30;return e||n||r?(e&&i>e&&(e=i),n&&i>n&&(n=i),r&&i>r&&(r=i),new vt(Math.min(255,e/t),Math.min(255,n/t),Math.min(255,r/t))):new vt(i,i,i)},Ku.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new vt(t*this.r,t*this.g,t*this.b)},Ku.hsl=function(){return At(this.r,this.g,this.b)},Ku.toString=function(){return"#"+xt(this.r)+xt(this.g)+xt(this.b)};var Ju=nu.map({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});Ju.forEach(function(t,e){Ju.set(t,bt(e))}),nu.functor=Ct,nu.xhr=Mt(b),nu.dsv=function(t,e){function n(t,n,a){arguments.length<3&&(a=n,n=null);var u=St(t,e,null==n?r:i(n),a);return u.row=function(t){return arguments.length?u.response(null==(n=t)?r:i(t)):n},u}function r(t){return n.parse(t.responseText)}function i(t){return function(e){return n.parse(e.responseText,t)}}function a(e){return e.map(u).join(t)}function u(t){return o.test(t)?'"'+t.replace(/\"/g,'""')+'"':t}var o=new RegExp('["'+t+"\n]"),s=t.charCodeAt(0);return n.parse=function(t,e){var r;return n.parseRows(t,function(t,n){if(r)return r(t,n-1);var i=new Function("d","return {"+t.map(function(t,e){return JSON.stringify(t)+": d["+e+"]"}).join(",")+"}");r=e?function(t,n){return e(i(t),n)}:i})},n.parseRows=function(t,e){function n(){if(l>=c)return u;if(i)return i=!1,a;var e=l;if(34===t.charCodeAt(e)){for(var n=e;n++l;){var r=t.charCodeAt(l++),o=1;if(10===r)i=!0;else if(13===r)i=!0,10===t.charCodeAt(l)&&(++l,++o);else if(r!==s)continue;return t.slice(e,l-o)}return t.slice(e)}for(var r,i,a={},u={},o=[],c=t.length,l=0,h=0;(r=n())!==u;){for(var f=[];r!==a&&r!==u;)f.push(r),r=n();e&&null==(f=e(f,h++))||o.push(f)}return o},n.format=function(e){if(Array.isArray(e[0]))return n.formatRows(e);var r=new v,i=[];return e.forEach(function(t){for(var e in t)r.has(e)||i.push(r.add(e))}),[i.map(u).join(t)].concat(e.map(function(e){return i.map(function(t){return u(e[t])}).join(t)})).join("\n")},n.formatRows=function(t){return t.map(a).join("\n")},n},nu.csv=nu.dsv(",","text/csv"),nu.tsv=nu.dsv(" ","text/tab-separated-values");var Qu,to,eo,no,ro,io=this[x(this,"requestAnimationFrame")]||function(t){setTimeout(t,17)};nu.timer=function(t,e,n){var r=arguments.length;2>r&&(e=0),3>r&&(n=Date.now());var i=n+e,a={c:t,t:i,f:!1,n:null};to?to.n=a:Qu=a, -to=a,eo||(no=clearTimeout(no),eo=1,io(Bt))},nu.timer.flush=function(){Lt(),Ot()},nu.round=function(t,e){return e?Math.round(t*(e=Math.pow(10,e)))/e:Math.round(t)};var ao=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"].map(It);nu.formatPrefix=function(t,e){var n=0;return t&&(0>t&&(t*=-1),e&&(t=nu.round(t,Nt(t,e))),n=1+Math.floor(1e-12+Math.log(t)/Math.LN10),n=Math.max(-24,Math.min(24,3*Math.floor((n-1)/3)))),ao[8+n/3]};var uo=/(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i,oo=nu.map({b:function(t){return t.toString(2)},c:function(t){return String.fromCharCode(t)},o:function(t){return t.toString(8)},x:function(t){return t.toString(16)},X:function(t){return t.toString(16).toUpperCase()},g:function(t,e){return t.toPrecision(e)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},r:function(t,e){return(t=nu.round(t,Nt(t,e))).toFixed(Math.max(0,Math.min(20,Nt(t*(1+1e-15),e))))}}),so=nu.time={},co=Date;qt.prototype={getDate:function(){return this._.getUTCDate()},getDay:function(){return this._.getUTCDay()},getFullYear:function(){return this._.getUTCFullYear()},getHours:function(){return this._.getUTCHours()},getMilliseconds:function(){return this._.getUTCMilliseconds()},getMinutes:function(){return this._.getUTCMinutes()},getMonth:function(){return this._.getUTCMonth()},getSeconds:function(){return this._.getUTCSeconds()},getTime:function(){return this._.getTime()},getTimezoneOffset:function(){return 0},valueOf:function(){return this._.valueOf()},setDate:function(){lo.setUTCDate.apply(this._,arguments)},setDay:function(){lo.setUTCDay.apply(this._,arguments)},setFullYear:function(){lo.setUTCFullYear.apply(this._,arguments)},setHours:function(){lo.setUTCHours.apply(this._,arguments)},setMilliseconds:function(){lo.setUTCMilliseconds.apply(this._,arguments)},setMinutes:function(){lo.setUTCMinutes.apply(this._,arguments)},setMonth:function(){lo.setUTCMonth.apply(this._,arguments)},setSeconds:function(){lo.setUTCSeconds.apply(this._,arguments)},setTime:function(){lo.setTime.apply(this._,arguments)}};var lo=Date.prototype;so.year=jt(function(t){return t=so.day(t),t.setMonth(0,1),t},function(t,e){t.setFullYear(t.getFullYear()+e)},function(t){return t.getFullYear()}),so.years=so.year.range,so.years.utc=so.year.utc.range,so.day=jt(function(t){var e=new co(2e3,0);return e.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()),e},function(t,e){t.setDate(t.getDate()+e)},function(t){return t.getDate()-1}),so.days=so.day.range,so.days.utc=so.day.utc.range,so.dayOfYear=function(t){var e=so.year(t);return Math.floor((t-e-6e4*(t.getTimezoneOffset()-e.getTimezoneOffset()))/864e5)},["sunday","monday","tuesday","wednesday","thursday","friday","saturday"].forEach(function(t,e){e=7-e;var n=so[t]=jt(function(t){return(t=so.day(t)).setDate(t.getDate()-(t.getDay()+e)%7),t},function(t,e){t.setDate(t.getDate()+7*Math.floor(e))},function(t){var n=so.year(t).getDay();return Math.floor((so.dayOfYear(t)+(n+e)%7)/7)-(n!==e)});so[t+"s"]=n.range,so[t+"s"].utc=n.utc.range,so[t+"OfYear"]=function(t){var n=so.year(t).getDay();return Math.floor((so.dayOfYear(t)+(n+e)%7)/7)}}),so.week=so.sunday,so.weeks=so.sunday.range,so.weeks.utc=so.sunday.utc.range,so.weekOfYear=so.sundayOfYear;var ho={"-":"",_:" ",0:"0"},fo=/^\s*\d+/,po=/^%/;nu.locale=function(t){return{numberFormat:Pt(t),timeFormat:Yt(t)}};var go=nu.locale({decimal:".",thousands:",",grouping:[3],currency:["$",""],dateTime:"%a %b %e %X %Y",date:"%m/%d/%Y",time:"%H:%M:%S",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"]});nu.format=go.numberFormat,nu.geo={},ce.prototype={s:0,t:0,add:function(t){le(t,this.t,yo),le(yo.s,this.s,this),this.s?this.t+=yo.t:this.s=yo.t},reset:function(){this.s=this.t=0},valueOf:function(){return this.s}};var yo=new ce;nu.geo.stream=function(t,e){t&&mo.hasOwnProperty(t.type)?mo[t.type](t,e):he(t,e)};var mo={Feature:function(t,e){he(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++rt?4*Bu+t:t,xo.lineStart=xo.lineEnd=xo.point=w}};nu.geo.bounds=function(){function t(t,e){b.push(_=[l=t,f=t]),h>e&&(h=e),e>d&&(d=e)}function e(e,n){var r=ge([e*Iu,n*Iu]);if(m){var i=me(m,r),a=[i[1],-i[0],0],u=me(a,i);_e(u),u=xe(u);var s=e-p,c=s>0?1:-1,g=u[0]*Pu*c,y=pu(s)>180;if(y^(g>c*p&&c*e>g)){var v=u[1]*Pu;v>d&&(d=v)}else if(g=(g+360)%360-180,y^(g>c*p&&c*e>g)){var v=-u[1]*Pu;h>v&&(h=v)}else h>n&&(h=n),n>d&&(d=n);y?p>e?o(l,e)>o(l,f)&&(f=e):o(e,f)>o(l,f)&&(l=e):f>=l?(l>e&&(l=e),e>f&&(f=e)):e>p?o(l,e)>o(l,f)&&(f=e):o(e,f)>o(l,f)&&(l=e)}else t(e,n);m=r,p=e}function n(){x.point=e}function r(){_[0]=l,_[1]=f,x.point=t,m=null}function i(t,n){if(m){var r=t-p;v+=pu(r)>180?r+(r>0?360:-360):r}else g=t,y=n;xo.point(t,n),e(t,n)}function a(){xo.lineStart()}function u(){i(g,y),xo.lineEnd(),pu(v)>Tu&&(l=-(f=180)),_[0]=l,_[1]=f,m=null}function o(t,e){return(e-=t)<0?e+360:e}function s(t,e){return t[0]-e[0]}function c(t,e){return e[0]<=e[1]?e[0]<=t&&t<=e[1]:t_o?(l=-(f=180),h=-(d=90)):v>Tu?d=90:-Tu>v&&(h=-90),_[0]=l,_[1]=f}};return function(t){d=f=-(l=h=1/0),b=[],nu.geo.stream(t,x);var e=b.length;if(e){b.sort(s);for(var n,r=1,i=b[0],a=[i];e>r;++r)n=b[r],c(n[0],i)||c(n[1],i)?(o(i[0],n[1])>o(i[0],i[1])&&(i[1]=n[1]),o(n[0],i[1])>o(i[0],i[1])&&(i[0]=n[0])):a.push(i=n);for(var u,n,p=-(1/0),e=a.length-1,r=0,i=a[e];e>=r;i=n,++r)n=a[r],(u=o(i[1],n[0]))>p&&(p=u,l=n[0],f=i[1])}return b=_=null,l===1/0||h===1/0?[[0/0,0/0],[0/0,0/0]]:[[l,h],[f,d]]}}(),nu.geo.centroid=function(t){wo=Ao=Eo=ko=Do=Co=Mo=So=To=Fo=Bo=0,nu.geo.stream(t,Lo);var e=To,n=Fo,r=Bo,i=e*e+n*n+r*r;return Fu>i&&(e=Co,n=Mo,r=So,Tu>Ao&&(e=Eo,n=ko,r=Do),i=e*e+n*n+r*r,Fu>i)?[0/0,0/0]:[Math.atan2(n,e)*Pu,nt(r/Math.sqrt(i))*Pu]};var wo,Ao,Eo,ko,Do,Co,Mo,So,To,Fo,Bo,Lo={sphere:w,point:Ae,lineStart:ke,lineEnd:De,polygonStart:function(){Lo.lineStart=Ce},polygonEnd:function(){Lo.lineStart=ke}},Oo=Le(Se,Pe,qe,[-Bu,-Bu/2]),No=1e9;nu.geo.clipExtent=function(){var t,e,n,r,i,a,u={stream:function(t){return i&&(i.valid=!1),i=a(t),i.valid=!0,i},extent:function(o){return arguments.length?(a=ze(t=+o[0][0],e=+o[0][1],n=+o[1][0],r=+o[1][1]),i&&(i.valid=!1,i=null),u):[[t,e],[n,r]]}};return u.extent([[0,0],[960,500]])},(nu.geo.conicEqualArea=function(){return Ve($e)}).raw=$e,nu.geo.albers=function(){return nu.geo.conicEqualArea().rotate([96,0]).center([-.6,38.7]).parallels([29.5,45.5]).scale(1070)},nu.geo.albersUsa=function(){function t(t){var a=t[0],u=t[1];return e=null,n(a,u),e||(r(a,u),e)||i(a,u),e}var e,n,r,i,a=nu.geo.albers(),u=nu.geo.conicEqualArea().rotate([154,0]).center([-2,58.5]).parallels([55,65]),o=nu.geo.conicEqualArea().rotate([157,0]).center([-3,19.9]).parallels([8,18]),s={point:function(t,n){e=[t,n]}};return t.invert=function(t){var e=a.scale(),n=a.translate(),r=(t[0]-n[0])/e,i=(t[1]-n[1])/e;return(i>=.12&&.234>i&&r>=-.425&&-.214>r?u:i>=.166&&.234>i&&r>=-.214&&-.115>r?o:a).invert(t)},t.stream=function(t){var e=a.stream(t),n=u.stream(t),r=o.stream(t);return{point:function(t,i){e.point(t,i),n.point(t,i),r.point(t,i)},sphere:function(){e.sphere(),n.sphere(),r.sphere()},lineStart:function(){e.lineStart(),n.lineStart(),r.lineStart()},lineEnd:function(){e.lineEnd(),n.lineEnd(),r.lineEnd()},polygonStart:function(){e.polygonStart(),n.polygonStart(),r.polygonStart()},polygonEnd:function(){e.polygonEnd(),n.polygonEnd(),r.polygonEnd()}}},t.precision=function(e){return arguments.length?(a.precision(e),u.precision(e),o.precision(e),t):a.precision()},t.scale=function(e){return arguments.length?(a.scale(e),u.scale(.35*e),o.scale(e),t.translate(a.translate())):a.scale()},t.translate=function(e){if(!arguments.length)return a.translate();var c=a.scale(),l=+e[0],h=+e[1];return n=a.translate(e).clipExtent([[l-.455*c,h-.238*c],[l+.455*c,h+.238*c]]).stream(s).point,r=u.translate([l-.307*c,h+.201*c]).clipExtent([[l-.425*c+Tu,h+.12*c+Tu],[l-.214*c-Tu,h+.234*c-Tu]]).stream(s).point,i=o.translate([l-.205*c,h+.212*c]).clipExtent([[l-.214*c+Tu,h+.166*c+Tu],[l-.115*c-Tu,h+.234*c-Tu]]).stream(s).point,t},t.scale(1070)};var Io,Po,Ro,qo,jo,Uo,Yo={point:w,lineStart:w,lineEnd:w,polygonStart:function(){Po=0,Yo.lineStart=Ge},polygonEnd:function(){Yo.lineStart=Yo.lineEnd=Yo.point=w,Io+=pu(Po/2)}},zo={point:He,lineStart:w,lineEnd:w,polygonStart:w,polygonEnd:w},Vo={point:Xe,lineStart:Ke,lineEnd:Je,polygonStart:function(){Vo.lineStart=Qe},polygonEnd:function(){Vo.point=Xe,Vo.lineStart=Ke,Vo.lineEnd=Je}};nu.geo.path=function(){function t(t){return t&&("function"==typeof o&&a.pointRadius(+o.apply(this,arguments)),u&&u.valid||(u=i(a)),nu.geo.stream(t,u)),a.result()}function e(){return u=null,t}var n,r,i,a,u,o=4.5;return t.area=function(t){return Io=0,nu.geo.stream(t,i(Yo)),Io},t.centroid=function(t){return Eo=ko=Do=Co=Mo=So=To=Fo=Bo=0,nu.geo.stream(t,i(Vo)),Bo?[To/Bo,Fo/Bo]:So?[Co/So,Mo/So]:Do?[Eo/Do,ko/Do]:[0/0,0/0]},t.bounds=function(t){return jo=Uo=-(Ro=qo=1/0),nu.geo.stream(t,i(zo)),[[Ro,qo],[jo,Uo]]},t.projection=function(t){return arguments.length?(i=(n=t)?t.stream||nn(t):b,e()):n},t.context=function(t){return arguments.length?(a=null==(r=t)?new We:new tn(t),"function"!=typeof o&&a.pointRadius(o),e()):r},t.pointRadius=function(e){return arguments.length?(o="function"==typeof e?e:(a.pointRadius(+e),+e),t):o},t.projection(nu.geo.albersUsa()).context(null)},nu.geo.transform=function(t){return{stream:function(e){var n=new rn(e);for(var r in t)n[r]=t[r];return n}}},rn.prototype={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()}},nu.geo.projection=un,nu.geo.projectionMutator=on,(nu.geo.equirectangular=function(){return un(cn)}).raw=cn.invert=cn,nu.geo.rotation=function(t){function e(e){return e=t(e[0]*Iu,e[1]*Iu),e[0]*=Pu,e[1]*=Pu,e}return t=hn(t[0]%360*Iu,t[1]*Iu,t.length>2?t[2]*Iu:0),e.invert=function(e){return e=t.invert(e[0]*Iu,e[1]*Iu),e[0]*=Pu,e[1]*=Pu,e},e},ln.invert=cn,nu.geo.circle=function(){function t(){var t="function"==typeof r?r.apply(this,arguments):r,e=hn(-t[0]*Iu,-t[1]*Iu,0).invert,i=[];return n(null,null,1,{point:function(t,n){i.push(t=e(t,n)),t[0]*=Pu,t[1]*=Pu}}),{type:"Polygon",coordinates:[i]}}var e,n,r=[0,0],i=6;return t.origin=function(e){return arguments.length?(r=e,t):r},t.angle=function(r){return arguments.length?(n=gn((e=+r)*Iu,i*Iu),t):e},t.precision=function(r){return arguments.length?(n=gn(e*Iu,(i=+r)*Iu),t):i},t.angle(90)},nu.geo.distance=function(t,e){var n,r=(e[0]-t[0])*Iu,i=t[1]*Iu,a=e[1]*Iu,u=Math.sin(r),o=Math.cos(r),s=Math.sin(i),c=Math.cos(i),l=Math.sin(a),h=Math.cos(a);return Math.atan2(Math.sqrt((n=h*u)*n+(n=c*l-s*h*o)*n),s*l+c*h*o)},nu.geo.graticule=function(){function t(){return{type:"MultiLineString",coordinates:e()}}function e(){return nu.range(Math.ceil(a/y)*y,i,y).map(f).concat(nu.range(Math.ceil(c/m)*m,s,m).map(d)).concat(nu.range(Math.ceil(r/p)*p,n,p).filter(function(t){return pu(t%y)>Tu}).map(l)).concat(nu.range(Math.ceil(o/g)*g,u,g).filter(function(t){return pu(t%m)>Tu}).map(h))}var n,r,i,a,u,o,s,c,l,h,f,d,p=10,g=p,y=90,m=360,v=2.5;return t.lines=function(){return e().map(function(t){return{type:"LineString",coordinates:t}})},t.outline=function(){return{type:"Polygon",coordinates:[f(a).concat(d(s).slice(1),f(i).reverse().slice(1),d(c).reverse().slice(1))]}},t.extent=function(e){return arguments.length?t.majorExtent(e).minorExtent(e):t.minorExtent()},t.majorExtent=function(e){return arguments.length?(a=+e[0][0],i=+e[1][0],c=+e[0][1],s=+e[1][1],a>i&&(e=a,a=i,i=e),c>s&&(e=c,c=s,s=e),t.precision(v)):[[a,c],[i,s]]},t.minorExtent=function(e){return arguments.length?(r=+e[0][0],n=+e[1][0],o=+e[0][1],u=+e[1][1],r>n&&(e=r,r=n,n=e),o>u&&(e=o,o=u,u=e),t.precision(v)):[[r,o],[n,u]]},t.step=function(e){return arguments.length?t.majorStep(e).minorStep(e):t.minorStep()},t.majorStep=function(e){return arguments.length?(y=+e[0],m=+e[1],t):[y,m]},t.minorStep=function(e){return arguments.length?(p=+e[0],g=+e[1],t):[p,g]},t.precision=function(e){return arguments.length?(v=+e,l=mn(o,u,90),h=vn(r,n,v),f=mn(c,s,90),d=vn(a,i,v),t):v},t.majorExtent([[-180,-90+Tu],[180,90-Tu]]).minorExtent([[-180,-80-Tu],[180,80+Tu]])},nu.geo.greatArc=function(){function t(){return{type:"LineString",coordinates:[e||r.apply(this,arguments),n||i.apply(this,arguments)]}}var e,n,r=bn,i=_n;return t.distance=function(){return nu.geo.distance(e||r.apply(this,arguments),n||i.apply(this,arguments))},t.source=function(n){return arguments.length?(r=n,e="function"==typeof n?null:n,t):r},t.target=function(e){return arguments.length?(i=e,n="function"==typeof e?null:e,t):i},t.precision=function(){return arguments.length?t:0},t},nu.geo.interpolate=function(t,e){return xn(t[0]*Iu,t[1]*Iu,e[0]*Iu,e[1]*Iu)},nu.geo.length=function(t){return $o=0,nu.geo.stream(t,Go),$o};var $o,Go={sphere:w,point:w,lineStart:wn,lineEnd:w,polygonStart:w,polygonEnd:w},Ho=An(function(t){return Math.sqrt(2/(1+t))},function(t){return 2*Math.asin(t/2)});(nu.geo.azimuthalEqualArea=function(){return un(Ho)}).raw=Ho;var Wo=An(function(t){var e=Math.acos(t);return e&&e/Math.sin(e)},b);(nu.geo.azimuthalEquidistant=function(){return un(Wo)}).raw=Wo,(nu.geo.conicConformal=function(){return Ve(En)}).raw=En,(nu.geo.conicEquidistant=function(){return Ve(kn)}).raw=kn;var Zo=An(function(t){return 1/t},Math.atan);(nu.geo.gnomonic=function(){return un(Zo)}).raw=Zo,Dn.invert=function(t,e){return[t,2*Math.atan(Math.exp(e))-Nu]},(nu.geo.mercator=function(){return Cn(Dn)}).raw=Dn;var Xo=An(function(){return 1},Math.asin);(nu.geo.orthographic=function(){return un(Xo)}).raw=Xo;var Ko=An(function(t){return 1/(1+t)},function(t){return 2*Math.atan(t)});(nu.geo.stereographic=function(){return un(Ko)}).raw=Ko,Mn.invert=function(t,e){return[-e,2*Math.atan(Math.exp(t))-Nu]},(nu.geo.transverseMercator=function(){var t=Cn(Mn),e=t.center,n=t.rotate;return t.center=function(t){return t?e([-t[1],t[0]]):(t=e(),[t[1],-t[0]])},t.rotate=function(t){return t?n([t[0],t[1],t.length>2?t[2]+90:90]):(t=n(),[t[0],t[1],t[2]-90])},n([0,0,90])}).raw=Mn,nu.geom={},nu.geom.hull=function(t){function e(t){if(t.length<3)return[];var e,i=Ct(n),a=Ct(r),u=t.length,o=[],s=[];for(e=0;u>e;e++)o.push([+i.call(this,t[e],e),+a.call(this,t[e],e),e]);for(o.sort(Bn),e=0;u>e;e++)s.push([o[e][0],-o[e][1]]);var c=Fn(o),l=Fn(s),h=l[0]===c[0],f=l[l.length-1]===c[c.length-1],d=[];for(e=c.length-1;e>=0;--e)d.push(t[o[c[e]][2]]);for(e=+h;e=r&&c.x<=a&&c.y>=i&&c.y<=u?[[r,u],[a,u],[a,i],[r,i]]:[];l.point=t[o]}),e}function n(t){return t.map(function(t,e){return{x:Math.round(a(t,e)/Tu)*Tu,y:Math.round(u(t,e)/Tu)*Tu,i:e}})}var r=Sn,i=Tn,a=r,u=i,o=us;return t?e(t):(e.links=function(t){return or(n(t)).edges.filter(function(t){return t.l&&t.r}).map(function(e){return{source:t[e.l.i],target:t[e.r.i]}})},e.triangles=function(t){var e=[];return or(n(t)).cells.forEach(function(n,r){for(var i,a,u=n.site,o=n.edges.sort($n),s=-1,c=o.length,l=o[c-1].edge,h=l.l===u?l.r:l.l;++s=c,f=r>=l,d=f<<1|h;t.leaf=!1,t=t.nodes[d]||(t.nodes[d]=fr()),h?i=c:o=c,f?u=l:s=l,a(t,e,n,r,i,u,o,s)}var l,h,f,d,p,g,y,m,v,b=Ct(o),_=Ct(s);if(null!=e)g=e,y=n,m=r,v=i;else if(m=v=-(g=y=1/0),h=[],f=[],p=t.length,u)for(d=0;p>d;++d)l=t[d],l.xm&&(m=l.x),l.y>v&&(v=l.y),h.push(l.x),f.push(l.y);else for(d=0;p>d;++d){var x=+b(l=t[d],d),w=+_(l,d);g>x&&(g=x),y>w&&(y=w),x>m&&(m=x),w>v&&(v=w),h.push(x),f.push(w)}var A=m-g,E=v-y;A>E?v=y+A:m=g+E;var k=fr();if(k.add=function(t){a(k,t,+b(t,++d),+_(t,d),g,y,m,v)},k.visit=function(t){dr(t,k,g,y,m,v)},k.find=function(t){return pr(k,t[0],t[1],g,y,m,v)},d=-1,null==e){for(;++d=0?t.slice(0,e):t,r=e>=0?t.slice(e+1):"in";return n=ls.get(n)||cs,r=hs.get(r)||b,xr(r(n.apply(null,ru.call(arguments,1))))},nu.interpolateHcl=Or,nu.interpolateHsl=Nr,nu.interpolateLab=Ir,nu.interpolateRound=Pr,nu.transform=function(t){var e=au.createElementNS(nu.ns.prefix.svg,"g");return(nu.transform=function(t){if(null!=t){e.setAttribute("transform",t);var n=e.transform.baseVal.consolidate()}return new Rr(n?n.matrix:fs)})(t)},Rr.prototype.toString=function(){return"translate("+this.translate+")rotate("+this.rotate+")skewX("+this.skew+")scale("+this.scale+")"};var fs={a:1,b:0,c:0,d:1,e:0,f:0};nu.interpolateTransform=Yr,nu.layout={},nu.layout.bundle=function(){return function(t){for(var e=[],n=-1,r=t.length;++no*o/y){if(p>s){var c=e.charge/s;t.px-=a*c,t.py-=u*c}return!0}if(e.point&&s&&p>s){var c=e.pointCharge/s;t.px-=a*c,t.py-=u*c}}return!e.charge}}function e(t){t.px=nu.event.x,t.py=nu.event.y,o.resume()}var n,r,i,a,u,o={},s=nu.dispatch("start","tick","end"),c=[1,1],l=.9,h=ds,f=ps,d=-30,p=gs,g=.1,y=.64,m=[],v=[];return o.tick=function(){if((r*=.99)<.005)return s.end({type:"end",alpha:r=0}),!0;var e,n,o,h,f,p,y,b,_,x=m.length,w=v.length;for(n=0;w>n;++n)o=v[n],h=o.source,f=o.target,b=f.x-h.x,_=f.y-h.y,(p=b*b+_*_)&&(p=r*a[n]*((p=Math.sqrt(p))-i[n])/p,b*=p,_*=p,f.x-=b*(y=h.weight/(f.weight+h.weight)),f.y-=_*y,h.x+=b*(y=1-y),h.y+=_*y);if((y=r*g)&&(b=c[0]/2,_=c[1]/2,n=-1,y))for(;++n0?t:0:t>0&&(s.start({type:"start",alpha:r=t}),nu.timer(o.tick)),o):r},o.start=function(){function t(t,r){if(!n){for(n=new Array(s),o=0;s>o;++o)n[o]=[];for(o=0;l>o;++o){var i=v[o];n[i.source.index].push(i.target),n[i.target.index].push(i.source)}}for(var a,u=n[e],o=-1,c=u.length;++oe;++e)(r=m[e]).index=e,r.weight=0;for(e=0;l>e;++e)r=v[e],"number"==typeof r.source&&(r.source=m[r.source]),"number"==typeof r.target&&(r.target=m[r.target]),++r.source.weight,++r.target.weight;for(e=0;s>e;++e)r=m[e],isNaN(r.x)&&(r.x=t("x",p)),isNaN(r.y)&&(r.y=t("y",g)),isNaN(r.px)&&(r.px=r.x),isNaN(r.py)&&(r.py=r.y);if(i=[],"function"==typeof h)for(e=0;l>e;++e)i[e]=+h.call(this,v[e],e);else for(e=0;l>e;++e)i[e]=h;if(a=[],"function"==typeof f)for(e=0;l>e;++e)a[e]=+f.call(this,v[e],e);else for(e=0;l>e;++e)a[e]=f;if(u=[],"function"==typeof d)for(e=0;s>e;++e)u[e]=+d.call(this,m[e],e);else for(e=0;s>e;++e)u[e]=d;return o.resume()},o.resume=function(){return o.alpha(.1)},o.stop=function(){return o.alpha(0)},o.drag=function(){return n||(n=nu.behavior.drag().origin(b).on("dragstart.force",Wr).on("drag.force",e).on("dragend.force",Zr)),arguments.length?void this.on("mouseover.force",Xr).on("mouseout.force",Kr).call(n):n},nu.rebind(o,s,"on")};var ds=20,ps=1,gs=1/0;nu.layout.hierarchy=function(){function t(i){var a,u=[i],o=[];for(i.depth=0;null!=(a=u.pop());)if(o.push(a),(c=n.call(t,a,a.depth))&&(s=c.length)){for(var s,c,l;--s>=0;)u.push(l=c[s]),l.parent=a,l.depth=a.depth+1;r&&(a.value=0),a.children=c}else r&&(a.value=+r.call(t,a,a.depth)||0),delete a.children;return ei(i,function(t){var n,i;e&&(n=t.children)&&n.sort(e),r&&(i=t.parent)&&(i.value+=t.value)}),o}var e=ii,n=ni,r=ri;return t.sort=function(n){return arguments.length?(e=n,t):e},t.children=function(e){return arguments.length?(n=e,t):n},t.value=function(e){return arguments.length?(r=e,t):r},t.revalue=function(e){return r&&(ti(e,function(t){t.children&&(t.value=0)}),ei(e,function(e){var n;e.children||(e.value=+r.call(t,e,e.depth)||0),(n=e.parent)&&(n.value+=e.value)})),e},t},nu.layout.partition=function(){function t(e,n,r,i){var a=e.children;if(e.x=n,e.y=e.depth*i,e.dx=r,e.dy=i,a&&(u=a.length)){var u,o,s,c=-1;for(r=e.value?r/e.value:0;++ch?-1:1),p=(h-s*d)/nu.sum(c),g=nu.range(s),y=[];return null!=n&&g.sort(n===ys?function(t,e){return c[e]-c[t]}:function(t,e){return n(u[t],u[e])}),g.forEach(function(t){y[t]={data:u[t],value:o=c[t],startAngle:l,endAngle:l+=o*p+d,padAngle:f}}),y}var e=Number,n=ys,r=0,i=Lu,a=0;return t.value=function(n){return arguments.length?(e=n,t):e},t.sort=function(e){return arguments.length?(n=e,t):n},t.startAngle=function(e){return arguments.length?(r=e,t):r},t.endAngle=function(e){return arguments.length?(i=e,t):i},t.padAngle=function(e){return arguments.length?(a=e,t):a},t};var ys={};nu.layout.stack=function(){function t(o,s){if(!(f=o.length))return o;var c=o.map(function(n,r){return e.call(t,n,r)}),l=c.map(function(e){return e.map(function(e,n){return[a.call(t,e,n),u.call(t,e,n)]})}),h=n.call(t,l,s);c=nu.permute(c,h),l=nu.permute(l,h);var f,d,p,g,y=r.call(t,l,s),m=c[0].length;for(p=0;m>p;++p)for(i.call(t,c[0][p],g=y[p],l[0][p][1]),d=1;f>d;++d)i.call(t,c[d][p],g+=l[d-1][p][1],l[d][p][1]);return o}var e=b,n=ci,r=li,i=si,a=ui,u=oi;return t.values=function(n){return arguments.length?(e=n,t):e},t.order=function(e){return arguments.length?(n="function"==typeof e?e:ms.get(e)||ci,t):n},t.offset=function(e){return arguments.length?(r="function"==typeof e?e:vs.get(e)||li,t):r},t.x=function(e){return arguments.length?(a=e,t):a},t.y=function(e){return arguments.length?(u=e,t):u},t.out=function(e){return arguments.length?(i=e,t):i},t};var ms=nu.map({"inside-out":function(t){var e,n,r=t.length,i=t.map(hi),a=t.map(fi),u=nu.range(r).sort(function(t,e){return i[t]-i[e]}),o=0,s=0,c=[],l=[];for(e=0;r>e;++e)n=u[e],s>o?(o+=a[n],c.push(n)):(s+=a[n],l.push(n));return l.reverse().concat(c)},reverse:function(t){return nu.range(t.length).reverse()},"default":ci}),vs=nu.map({silhouette:function(t){var e,n,r,i=t.length,a=t[0].length,u=[],o=0,s=[];for(n=0;a>n;++n){for(e=0,r=0;i>e;e++)r+=t[e][n][1];r>o&&(o=r),u.push(r)}for(n=0;a>n;++n)s[n]=(o-u[n])/2;return s},wiggle:function(t){var e,n,r,i,a,u,o,s,c,l=t.length,h=t[0],f=h.length,d=[];for(d[0]=s=c=0,n=1;f>n;++n){for(e=0,i=0;l>e;++e)i+=t[e][n][1];for(e=0,a=0,o=h[n][0]-h[n-1][0];l>e;++e){for(r=0,u=(t[e][n][1]-t[e][n-1][1])/(2*o);e>r;++r)u+=(t[r][n][1]-t[r][n-1][1])/o;a+=u*t[e][n][1]}d[n]=s-=i?a/i*o:0,c>s&&(c=s)}for(n=0;f>n;++n)d[n]-=c;return d},expand:function(t){var e,n,r,i=t.length,a=t[0].length,u=1/i,o=[];for(n=0;a>n;++n){for(e=0,r=0;i>e;e++)r+=t[e][n][1];if(r)for(e=0;i>e;e++)t[e][n][1]/=r;else for(e=0;i>e;e++)t[e][n][1]=u}for(n=0;a>n;++n)o[n]=0;return o},zero:li});nu.layout.histogram=function(){function t(t,a){for(var u,o,s=[],c=t.map(n,this),l=r.call(this,c,a),h=i.call(this,l,c,a),a=-1,f=c.length,d=h.length-1,p=e?1:1/f;++a0)for(a=-1;++a=l[0]&&o<=l[1]&&(u=s[nu.bisect(h,o,1,d)-1],u.y+=p,u.push(t[a]));return s}var e=!0,n=Number,r=yi,i=pi;return t.value=function(e){return arguments.length?(n=e,t):n},t.range=function(e){return arguments.length?(r=Ct(e),t):r},t.bins=function(e){return arguments.length?(i="number"==typeof e?function(t){return gi(t,e)}:Ct(e),t):i},t.frequency=function(n){return arguments.length?(e=!!n,t):e},t},nu.layout.pack=function(){function t(t,a){var u=n.call(this,t,a),o=u[0],s=i[0],c=i[1],l=null==e?Math.sqrt:"function"==typeof e?e:function(){return e};if(o.x=o.y=0,ei(o,function(t){t.r=+l(t.value)}),ei(o,xi),r){var h=r*(e?1:Math.max(2*o.r/s,2*o.r/c))/2;ei(o,function(t){t.r+=h; +}return function(o){function s(t){for(var e=0,n=y.length,r=t[1],i=0;n>i;++i)for(var a,u=1,o=y[i],s=o.length,c=o[0];s>u;++u)a=o[u],c[1]<=r?a[1]>r&&tt(c,a,t)>0&&++e:a[1]<=r&&tt(c,a,t)<0&&--e,c=a;return 0!==e}function c(a,o,s,c){var l=0,h=0;if(null==a||(l=i(a,s))!==(h=i(o,s))||u(a,o)<0^s>0){do c.point(0===l||3===l?t:n,l>1?r:e);while((l=(l+s+4)%4)!==h)}else c.point(o[0],o[1])}function l(i,a){return i>=t&&n>=i&&a>=e&&r>=a}function h(t,e){l(t,e)&&o.point(t,e)}function f(){S.point=p,y&&y.push(m=[]),E=!0,A=!1,x=w=0/0}function d(){g&&(p(v,b),_&&A&&C.rejoin(),g.push(C.buffer())),S.point=h,A&&o.lineEnd()}function p(t,e){t=Math.max(-Oo,Math.min(Oo,t)),e=Math.max(-Oo,Math.min(Oo,e));var n=l(t,e);if(y&&m.push([t,e]),E)v=t,b=e,_=n,E=!1,n&&(o.lineStart(),o.point(t,e));else if(n&&A)o.point(t,e);else{var r={a:{x:x,y:w},b:{x:t,y:e}};M(r)?(A||(o.lineStart(),o.point(r.a.x,r.a.y)),o.point(r.b.x,r.b.y),n||o.lineEnd(),k=!1):n&&(o.lineStart(),o.point(t,e),k=!1)}x=t,w=e,A=n}var g,y,m,v,b,_,x,w,A,E,k,D=o,C=Oe(),M=Ye(t,e,n,r),S={point:h,lineStart:f,lineEnd:d,polygonStart:function(){o=C,g=[],y=[],k=!0},polygonEnd:function(){o=D,g=nu.merge(g);var e=s([t,r]),n=k&&e,i=g.length;(n||i)&&(o.polygonStart(),n&&(o.lineStart(),c(null,null,1,o),o.lineEnd()),i&&Te(g,a,e,c,o),o.polygonEnd()),g=y=m=null}};return S}}function Ve(t){var e=0,n=Bu/3,r=on(t),i=r(e,n);return i.parallels=function(t){return arguments.length?r(e=t[0]*Bu/180,n=t[1]*Bu/180):[e/Bu*180,n/Bu*180]},i}function $e(t,e){function n(t,e){var n=Math.sqrt(a-2*i*Math.sin(e))/i;return[n*Math.sin(t*=i),u-n*Math.cos(t)]}var r=Math.sin(t),i=(r+Math.sin(e))/2,a=1+r*(2*i-r),u=Math.sqrt(a)/i;return n.invert=function(t,e){var n=u-e;return[Math.atan2(t,n)/i,nt((a-(t*t+n*n)*i*i)/(2*i))]},n}function Ge(){function t(t,e){Ro+=i*t-r*e,r=t,i=e}var e,n,r,i;Yo.point=function(a,u){Yo.point=t,e=r=a,n=i=u},Yo.lineEnd=function(){t(e,n)}}function He(t,e){Po>t&&(Po=t),t>jo&&(jo=t),qo>e&&(qo=e),e>Uo&&(Uo=e)}function We(){function t(t,e){u.push("M",t,",",e,a)}function e(t,e){u.push("M",t,",",e),o.point=n}function n(t,e){u.push("L",t,",",e)}function r(){o.point=t}function i(){u.push("Z")}var a=Ze(4.5),u=[],o={point:t,lineStart:function(){o.point=e},lineEnd:r,polygonStart:function(){o.lineEnd=i},polygonEnd:function(){o.lineEnd=r,o.point=t},pointRadius:function(t){return a=Ze(t),o},result:function(){if(u.length){var t=u.join("");return u=[],t}}};return o}function Ze(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}function Xe(t,e){Eo+=t,ko+=e,++Do}function Je(){function t(t,r){var i=t-e,a=r-n,u=Math.sqrt(i*i+a*a);Co+=u*(e+t)/2,Mo+=u*(n+r)/2,So+=u,Xe(e=t,n=r)}var e,n;Vo.point=function(r,i){Vo.point=t,Xe(e=r,n=i)}}function Ke(){Vo.point=Xe}function Qe(){function t(t,e){var n=t-r,a=e-i,u=Math.sqrt(n*n+a*a);Co+=u*(r+t)/2,Mo+=u*(i+e)/2,So+=u,u=i*t-r*e,To+=u*(r+t),Fo+=u*(i+e),Bo+=3*u,Xe(r=t,i=e)}var e,n,r,i;Vo.point=function(a,u){Vo.point=t,Xe(e=r=a,n=i=u)},Vo.lineEnd=function(){t(e,n)}}function tn(t){function e(e,n){t.moveTo(e+u,n),t.arc(e,n,u,0,Lu)}function n(e,n){t.moveTo(e,n),o.point=r}function r(e,n){t.lineTo(e,n)}function i(){o.point=e}function a(){t.closePath()}var u=4.5,o={point:e,lineStart:function(){o.point=n},lineEnd:i,polygonStart:function(){o.lineEnd=a},polygonEnd:function(){o.lineEnd=i,o.point=e},pointRadius:function(t){return u=t,o},result:w};return o}function en(t){function e(t){return(o?r:n)(t)}function n(e){return an(e,function(n,r){n=t(n,r),e.point(n[0],n[1])})}function r(e){function n(n,r){n=t(n,r),e.point(n[0],n[1])}function r(){b=0/0,E.point=a,e.lineStart()}function a(n,r){var a=ge([n,r]),u=t(n,r);i(b,_,v,x,w,A,b=u[0],_=u[1],v=n,x=a[0],w=a[1],A=a[2],o,e),e.point(b,_)}function u(){E.point=n,e.lineEnd()}function s(){r(),E.point=c,E.lineEnd=l}function c(t,e){a(h=t,f=e),d=b,p=_,g=x,y=w,m=A,E.point=a}function l(){i(b,_,v,x,w,A,d,p,h,g,y,m,o,e),E.lineEnd=u,u()}var h,f,d,p,g,y,m,v,b,_,x,w,A,E={point:n,lineStart:r,lineEnd:u,polygonStart:function(){e.polygonStart(),E.lineStart=s},polygonEnd:function(){e.polygonEnd(),E.lineStart=r}};return E}function i(e,n,r,o,s,c,l,h,f,d,p,g,y,m){var v=l-e,b=h-n,_=v*v+b*b;if(_>4*a&&y--){var x=o+d,w=s+p,A=c+g,E=Math.sqrt(x*x+w*w+A*A),k=Math.asin(A/=E),D=pu(pu(A)-1)a||pu((v*T+b*F)/_-.5)>.3||u>o*d+s*p+c*g)&&(i(e,n,r,o,s,c,M,S,D,x/=E,w/=E,A,y,m),m.point(M,S),i(M,S,D,x,w,A,l,h,f,d,p,g,y,m))}}var a=.5,u=Math.cos(30*Iu),o=16;return e.precision=function(t){return arguments.length?(o=(a=t*t)>0&&16,e):Math.sqrt(a)},e}function nn(t){var e=en(function(e,n){return t([e*Ru,n*Ru])});return function(t){return sn(e(t))}}function rn(t){this.stream=t}function an(t,e){return{point:e,sphere:function(){t.sphere()},lineStart:function(){t.lineStart()},lineEnd:function(){t.lineEnd()},polygonStart:function(){t.polygonStart()},polygonEnd:function(){t.polygonEnd()}}}function un(t){return on(function(){return t})()}function on(t){function e(t){return t=o(t[0]*Iu,t[1]*Iu),[t[0]*f+s,c-t[1]*f]}function n(t){return t=o.invert((t[0]-s)/f,(c-t[1])/f),t&&[t[0]*Ru,t[1]*Ru]}function r(){o=Me(u=hn(m,v,_),a);var t=a(g,y);return s=d-t[0]*f,c=p+t[1]*f,i()}function i(){return l&&(l.valid=!1,l=null),e}var a,u,o,s,c,l,h=en(function(t,e){return t=a(t,e),[t[0]*f+s,c-t[1]*f]}),f=150,d=480,p=250,g=0,y=0,m=0,v=0,_=0,x=No,w=b,A=null,E=null;return e.stream=function(t){return l&&(l.valid=!1),l=sn(x(u,h(w(t)))),l.valid=!0,l},e.clipAngle=function(t){return arguments.length?(x=null==t?(A=t,No):Ue((A=+t)*Iu),i()):A},e.clipExtent=function(t){return arguments.length?(E=t,w=t?ze(t[0][0],t[0][1],t[1][0],t[1][1]):b,i()):E},e.scale=function(t){return arguments.length?(f=+t,r()):f},e.translate=function(t){return arguments.length?(d=+t[0],p=+t[1],r()):[d,p]},e.center=function(t){return arguments.length?(g=t[0]%360*Iu,y=t[1]%360*Iu,r()):[g*Ru,y*Ru]},e.rotate=function(t){return arguments.length?(m=t[0]%360*Iu,v=t[1]%360*Iu,_=t.length>2?t[2]%360*Iu:0,r()):[m*Ru,v*Ru,_*Ru]},nu.rebind(e,h,"precision"),function(){return a=t.apply(this,arguments),e.invert=a.invert&&n,r()}}function sn(t){return an(t,function(e,n){t.point(e*Iu,n*Iu)})}function cn(t,e){return[t,e]}function ln(t,e){return[t>Bu?t-Lu:-Bu>t?t+Lu:t,e]}function hn(t,e,n){return t?e||n?Me(dn(t),pn(e,n)):dn(t):e||n?pn(e,n):ln}function fn(t){return function(e,n){return e+=t,[e>Bu?e-Lu:-Bu>e?e+Lu:e,n]}}function dn(t){var e=fn(t);return e.invert=fn(-t),e}function pn(t,e){function n(t,e){var n=Math.cos(e),o=Math.cos(t)*n,s=Math.sin(t)*n,c=Math.sin(e),l=c*r+o*i;return[Math.atan2(s*a-l*u,o*r-c*i),nt(l*a+s*u)]}var r=Math.cos(t),i=Math.sin(t),a=Math.cos(e),u=Math.sin(e);return n.invert=function(t,e){var n=Math.cos(e),o=Math.cos(t)*n,s=Math.sin(t)*n,c=Math.sin(e),l=c*a-s*u;return[Math.atan2(s*a+c*u,o*r+l*i),nt(l*r-o*i)]},n}function gn(t,e){var n=Math.cos(t),r=Math.sin(t);return function(i,a,u,o){var s=u*e;null!=i?(i=yn(n,i),a=yn(n,a),(u>0?a>i:i>a)&&(i+=u*Lu)):(i=t+u*Lu,a=t-.5*s);for(var c,l=i;u>0?l>a:a>l;l-=s)o.point((c=xe([n,-r*Math.cos(l),-r*Math.sin(l)]))[0],c[1])}}function yn(t,e){var n=ge(e);n[0]-=t,_e(n);var r=et(-n[1]);return((-n[2]<0?-r:r)+2*Math.PI-Tu)%(2*Math.PI)}function mn(t,e,n){var r=nu.range(t,e-Tu,n).concat(e);return function(t){return r.map(function(e){return[t,e]})}}function vn(t,e,n){var r=nu.range(t,e-Tu,n).concat(e);return function(t){return r.map(function(e){return[e,t]})}}function bn(t){return t.source}function _n(t){return t.target}function xn(t,e,n,r){var i=Math.cos(e),a=Math.sin(e),u=Math.cos(r),o=Math.sin(r),s=i*Math.cos(t),c=i*Math.sin(t),l=u*Math.cos(n),h=u*Math.sin(n),f=2*Math.asin(Math.sqrt(ut(r-e)+i*u*ut(n-t))),d=1/Math.sin(f),p=f?function(t){var e=Math.sin(t*=f)*d,n=Math.sin(f-t)*d,r=n*s+e*l,i=n*c+e*h,u=n*a+e*o;return[Math.atan2(i,r)*Ru,Math.atan2(u,Math.sqrt(r*r+i*i))*Ru]}:function(){return[t*Ru,e*Ru]};return p.distance=f,p}function wn(){function t(t,i){var a=Math.sin(i*=Iu),u=Math.cos(i),o=pu((t*=Iu)-e),s=Math.cos(o);$o+=Math.atan2(Math.sqrt((o=u*Math.sin(o))*o+(o=r*a-n*u*s)*o),n*a+r*u*s),e=t,n=a,r=u}var e,n,r;Go.point=function(i,a){e=i*Iu,n=Math.sin(a*=Iu),r=Math.cos(a),Go.point=t},Go.lineEnd=function(){Go.point=Go.lineEnd=w}}function An(t,e){function n(e,n){var r=Math.cos(e),i=Math.cos(n),a=t(r*i);return[a*i*Math.sin(e),a*Math.sin(n)]}return n.invert=function(t,n){var r=Math.sqrt(t*t+n*n),i=e(r),a=Math.sin(i),u=Math.cos(i);return[Math.atan2(t*a,r*u),Math.asin(r&&n*a/r)]},n}function En(t,e){function n(t,e){u>0?-Ou+Tu>e&&(e=-Ou+Tu):e>Ou-Tu&&(e=Ou-Tu);var n=u/Math.pow(i(e),a);return[n*Math.sin(a*t),u-n*Math.cos(a*t)]}var r=Math.cos(t),i=function(t){return Math.tan(Bu/4+t/2)},a=t===e?Math.sin(t):Math.log(r/Math.cos(e))/Math.log(i(e)/i(t)),u=r*Math.pow(i(t),a)/a;return a?(n.invert=function(t,e){var n=u-e,r=Q(a)*Math.sqrt(t*t+n*n);return[Math.atan2(t,n)/a,2*Math.atan(Math.pow(u/r,1/a))-Ou]},n):Dn}function kn(t,e){function n(t,e){var n=a-e;return[n*Math.sin(i*t),a-n*Math.cos(i*t)]}var r=Math.cos(t),i=t===e?Math.sin(t):(r-Math.cos(e))/(e-t),a=r/i+t;return pu(i)i;i++){for(;r>1&&tt(t[n[r-2]],t[n[r-1]],t[i])<=0;)--r;n[r++]=i}return n.slice(0,r)}function Bn(t,e){return t[0]-e[0]||t[1]-e[1]}function Ln(t,e,n){return(n[0]-e[0])*(t[1]-e[1])<(n[1]-e[1])*(t[0]-e[0])}function Nn(t,e,n,r){var i=t[0],a=n[0],u=e[0]-i,o=r[0]-a,s=t[1],c=n[1],l=e[1]-s,h=r[1]-c,f=(o*(s-c)-h*(i-a))/(h*u-o*l);return[i+f*u,s+f*l]}function On(t){var e=t[0],n=t[t.length-1];return!(e[0]-n[0]||e[1]-n[1])}function In(){rr(this),this.edge=this.site=this.circle=null}function Rn(t){var e=is.pop()||new In;return e.site=t,e}function Pn(t){Wn(t),es.remove(t),is.push(t),rr(t)}function qn(t){var e=t.circle,n=e.x,r=e.cy,i={x:n,y:r},a=t.P,u=t.N,o=[t];Pn(t);for(var s=a;s.circle&&pu(n-s.circle.x)l;++l)c=o[l],s=o[l-1],tr(c.edge,s.site,c.site,i);s=o[0],c=o[h-1],c.edge=Kn(s.site,c.site,null,i),Hn(s),Hn(c)}function jn(t){for(var e,n,r,i,a=t.x,u=t.y,o=es._;o;)if(r=Un(o,u)-a,r>Tu)o=o.L;else{if(i=a-Yn(o,u),!(i>Tu)){r>-Tu?(e=o.P,n=o):i>-Tu?(e=o,n=o.N):e=n=o;break}if(!o.R){e=o;break}o=o.R}var s=Rn(t);if(es.insert(e,s),e||n){if(e===n)return Wn(e),n=Rn(e.site),es.insert(s,n),s.edge=n.edge=Kn(e.site,s.site),Hn(e),void Hn(n);if(!n)return void(s.edge=Kn(e.site,s.site));Wn(e),Wn(n);var c=e.site,l=c.x,h=c.y,f=t.x-l,d=t.y-h,p=n.site,g=p.x-l,y=p.y-h,m=2*(f*y-d*g),v=f*f+d*d,b=g*g+y*y,_={x:(y*v-d*b)/m+l,y:(f*b-g*v)/m+h};tr(n.edge,c,p,_),s.edge=Kn(c,t,null,_),n.edge=Kn(t,p,null,_),Hn(e),Hn(n)}}function Un(t,e){var n=t.site,r=n.x,i=n.y,a=i-e;if(!a)return r;var u=t.P;if(!u)return-(1/0);n=u.site;var o=n.x,s=n.y,c=s-e;if(!c)return o;var l=o-r,h=1/a-1/c,f=l/c;return h?(-f+Math.sqrt(f*f-2*h*(l*l/(-2*c)-s+c/2+i-a/2)))/h+r:(r+o)/2}function Yn(t,e){var n=t.N;if(n)return Un(n,e);var r=t.site;return r.y===e?r.x:1/0}function zn(t){this.site=t,this.edges=[]}function Vn(t){for(var e,n,r,i,a,u,o,s,c,l,h=t[0][0],f=t[1][0],d=t[0][1],p=t[1][1],g=ts,y=g.length;y--;)if(a=g[y],a&&a.prepare())for(o=a.edges,s=o.length,u=0;s>u;)l=o[u].end(),r=l.x,i=l.y,c=o[++u%s].start(),e=c.x,n=c.y,(pu(r-e)>Tu||pu(i-n)>Tu)&&(o.splice(u,0,new er(Qn(a.site,l,pu(r-h)Tu?{x:h,y:pu(e-h)Tu?{x:pu(n-p)Tu?{x:f,y:pu(e-f)Tu?{x:pu(n-d)=-Fu)){var d=s*s+c*c,p=l*l+h*h,g=(h*d-c*p)/f,y=(s*p-l*d)/f,h=y+o,m=as.pop()||new Gn;m.arc=t,m.site=i,m.x=g+u,m.y=h+Math.sqrt(g*g+y*y),m.cy=h,t.circle=m;for(var v=null,b=rs._;b;)if(m.yy||y>=o)return;if(f>p){if(a){if(a.y>=c)return}else a={x:y,y:s};n={x:y,y:c}}else{if(a){if(a.yr||r>1)if(f>p){if(a){if(a.y>=c)return}else a={x:(s-i)/r,y:s};n={x:(c-i)/r,y:c}}else{if(a){if(a.yd){if(a){if(a.x>=o)return}else a={x:u,y:r*u+i};n={x:o,y:r*o+i}}else{if(a){if(a.xa||h>u||r>f||i>d)){if(p=t.point){var p,g=e-t.x,y=n-t.y,m=g*g+y*y;if(s>m){var v=Math.sqrt(s=m);r=e-v,i=n-v,a=e+v,u=n+v,o=p}}for(var b=t.nodes,_=.5*(l+f),x=.5*(h+d),w=e>=_,A=n>=x,E=A<<1|w,k=E+4;k>E;++E)if(t=b[3&E])switch(3&E){case 0:c(t,l,h,_,x);break;case 1:c(t,_,h,f,x);break;case 2:c(t,l,x,_,d);break;case 3:c(t,_,x,f,d)}}}(t,r,i,a,u),o}function gr(t,e){t=nu.rgb(t),e=nu.rgb(e);var n=t.r,r=t.g,i=t.b,a=e.r-n,u=e.g-r,o=e.b-i;return function(t){return"#"+xt(Math.round(n+a*t))+xt(Math.round(r+u*t))+xt(Math.round(i+o*t))}}function yr(t,e){var n,r={},i={};for(n in t)n in e?r[n]=br(t[n],e[n]):i[n]=t[n];for(n in e)n in t||(i[n]=e[n]);return function(t){for(n in r)i[n]=r[n](t);return i}}function mr(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function vr(t,e){var n,r,i,a=os.lastIndex=ss.lastIndex=0,u=-1,o=[],s=[];for(t+="",e+="";(n=os.exec(t))&&(r=ss.exec(e));)(i=r.index)>a&&(i=e.slice(a,i),o[u]?o[u]+=i:o[++u]=i),(n=n[0])===(r=r[0])?o[u]?o[u]+=r:o[++u]=r:(o[++u]=null,s.push({i:u,x:mr(n,r)})),a=ss.lastIndex;return ar;++r)o[(n=s[r]).i]=n.x(t);return o.join("")})}function br(t,e){for(var n,r=nu.interpolators.length;--r>=0&&!(n=nu.interpolators[r](t,e)););return n}function _r(t,e){var n,r=[],i=[],a=t.length,u=e.length,o=Math.min(t.length,e.length);for(n=0;o>n;++n)r.push(br(t[n],e[n]));for(;a>n;++n)i[n]=t[n];for(;u>n;++n)i[n]=e[n];return function(t){for(n=0;o>n;++n)i[n]=r[n](t);return i}}function xr(t){return function(e){return 0>=e?0:e>=1?1:t(e)}}function wr(t){return function(e){return 1-t(1-e)}}function Ar(t){return function(e){return.5*(.5>e?t(2*e):2-t(2-2*e))}}function Er(t){return t*t}function kr(t){return t*t*t}function Dr(t){if(0>=t)return 0;if(t>=1)return 1;var e=t*t,n=e*t;return 4*(.5>t?n:3*(t-e)+n-.75)}function Cr(t){return function(e){return Math.pow(e,t)}}function Mr(t){return 1-Math.cos(t*Ou)}function Sr(t){return Math.pow(2,10*(t-1))}function Tr(t){return 1-Math.sqrt(1-t*t)}function Fr(t,e){var n;return arguments.length<2&&(e=.45),arguments.length?n=e/Lu*Math.asin(1/t):(t=1,n=e/4),function(r){return 1+t*Math.pow(2,-10*r)*Math.sin((r-n)*Lu/e)}}function Br(t){return t||(t=1.70158),function(e){return e*e*((t+1)*e-t)}}function Lr(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375}function Nr(t,e){t=nu.hcl(t),e=nu.hcl(e);var n=t.h,r=t.c,i=t.l,a=e.h-n,u=e.c-r,o=e.l-i;return isNaN(u)&&(u=0,r=isNaN(r)?e.c:r),isNaN(a)?(a=0,n=isNaN(n)?e.h:n):a>180?a-=360:-180>a&&(a+=360),function(t){return ht(n+a*t,r+u*t,i+o*t)+""}}function Or(t,e){t=nu.hsl(t),e=nu.hsl(e);var n=t.h,r=t.s,i=t.l,a=e.h-n,u=e.s-r,o=e.l-i;return isNaN(u)&&(u=0,r=isNaN(r)?e.s:r),isNaN(a)?(a=0,n=isNaN(n)?e.h:n):a>180?a-=360:-180>a&&(a+=360),function(t){return ct(n+a*t,r+u*t,i+o*t)+""}}function Ir(t,e){t=nu.lab(t),e=nu.lab(e);var n=t.l,r=t.a,i=t.b,a=e.l-n,u=e.a-r,o=e.b-i;return function(t){return dt(n+a*t,r+u*t,i+o*t)+""}}function Rr(t,e){return e-=t,function(n){return Math.round(t+e*n)}}function Pr(t){var e=[t.a,t.b],n=[t.c,t.d],r=jr(e),i=qr(e,n),a=jr(Ur(n,e,-i))||0;e[0]*n[1]180?l+=360:l-c>180&&(c+=360),i.push({i:r.push(r.pop()+"rotate(",null,")")-2,x:mr(c,l)})):l&&r.push(r.pop()+"rotate("+l+")"),h!=f?i.push({i:r.push(r.pop()+"skewX(",null,")")-2,x:mr(h,f)}):f&&r.push(r.pop()+"skewX("+f+")"),d[0]!=p[0]||d[1]!=p[1]?(n=r.push(r.pop()+"scale(",null,",",null,")"),i.push({i:n-4,x:mr(d[0],p[0])},{i:n-2,x:mr(d[1],p[1])})):(1!=p[0]||1!=p[1])&&r.push(r.pop()+"scale("+p+")"),n=i.length,function(t){for(var e,a=-1;++a=0;)n.push(i[r])}function ei(t,e){for(var n=[t],r=[];null!=(t=n.pop());)if(r.push(t),(a=t.children)&&(i=a.length))for(var i,a,u=-1;++un;++n)(e=t[n][1])>i&&(r=n,i=e);return r}function fi(t){return t.reduce(di,0)}function di(t,e){return t+e[1]}function pi(t,e){return gi(t,Math.ceil(Math.log(e.length)/Math.LN2+1))}function gi(t,e){for(var n=-1,r=+t[0],i=(t[1]-r)/e,a=[];++n<=e;)a[n]=i*n+r;return a}function yi(t){return[nu.min(t),nu.max(t)]}function mi(t,e){return t.value-e.value}function vi(t,e){var n=t._pack_next;t._pack_next=e,e._pack_prev=t,e._pack_next=n,n._pack_prev=e}function bi(t,e){t._pack_next=e,e._pack_prev=t}function _i(t,e){var n=e.x-t.x,r=e.y-t.y,i=t.r+e.r;return.999*i*i>n*n+r*r}function xi(t){function e(t){l=Math.min(t.x-t.r,l),h=Math.max(t.x+t.r,h),f=Math.min(t.y-t.r,f),d=Math.max(t.y+t.r,d)}if((n=t.children)&&(c=n.length)){var n,r,i,a,u,o,s,c,l=1/0,h=-(1/0),f=1/0,d=-(1/0);if(n.forEach(wi),r=n[0],r.x=-r.r,r.y=0,e(r),c>1&&(i=n[1],i.x=i.r,i.y=0,e(i),c>2))for(a=n[2],ki(r,i,a),e(a),vi(r,a),r._pack_prev=a,vi(a,i),i=r._pack_next,u=3;c>u;u++){ki(r,i,a=n[u]);var p=0,g=1,y=1;for(o=i._pack_next;o!==i;o=o._pack_next,g++)if(_i(o,a)){p=1;break}if(1==p)for(s=r._pack_prev;s!==o._pack_prev&&!_i(s,a);s=s._pack_prev,y++);p?(y>g||g==y&&i.ru;u++)a=n[u],a.x-=m,a.y-=v,b=Math.max(b,a.r+Math.sqrt(a.x*a.x+a.y*a.y));t.r=b,n.forEach(Ai)}}function wi(t){t._pack_next=t._pack_prev=t}function Ai(t){delete t._pack_next,delete t._pack_prev}function Ei(t,e,n,r){var i=t.children;if(t.x=e+=r*t.x,t.y=n+=r*t.y,t.r*=r,i)for(var a=-1,u=i.length;++a=0;)e=i[a],e.z+=n,e.m+=n,n+=e.s+(r+=e.c)}function Fi(t,e,n){return t.a.parent===e.parent?t.a:n}function Bi(t){return 1+nu.max(t,function(t){return t.y})}function Li(t){return t.reduce(function(t,e){return t+e.x},0)/t.length}function Ni(t){var e=t.children;return e&&e.length?Ni(e[0]):t}function Oi(t){var e,n=t.children;return n&&(e=n.length)?Oi(n[e-1]):t}function Ii(t){return{x:t.x,y:t.y,dx:t.dx,dy:t.dy}}function Ri(t,e){var n=t.x+e[3],r=t.y+e[0],i=t.dx-e[1]-e[3],a=t.dy-e[0]-e[2];return 0>i&&(n+=i/2,i=0),0>a&&(r+=a/2,a=0),{x:n,y:r,dx:i,dy:a}}function Pi(t){var e=t[0],n=t[t.length-1];return n>e?[e,n]:[n,e]}function qi(t){return t.rangeExtent?t.rangeExtent():Pi(t.range())}function ji(t,e,n,r){var i=n(t[0],t[1]),a=r(e[0],e[1]);return function(t){return a(i(t))}}function Ui(t,e){var n,r=0,i=t.length-1,a=t[r],u=t[i];return a>u&&(n=r,r=i,i=n,n=a,a=u,u=n),t[r]=e.floor(a),t[i]=e.ceil(u),t}function Yi(t){return t?{floor:function(e){return Math.floor(e/t)*t},ceil:function(e){return Math.ceil(e/t)*t}}:bs}function zi(t,e,n,r){var i=[],a=[],u=0,o=Math.min(t.length,e.length)-1;for(t[o]2?zi:ji,s=r?Vr:zr;return u=i(t,e,s,n),o=i(e,t,s,br),a}function a(t){return u(t)}var u,o;return a.invert=function(t){return o(t)},a.domain=function(e){return arguments.length?(t=e.map(Number),i()):t},a.range=function(t){return arguments.length?(e=t,i()):e},a.rangeRound=function(t){return a.range(t).interpolate(Rr)},a.clamp=function(t){return arguments.length?(r=t,i()):r},a.interpolate=function(t){return arguments.length?(n=t,i()):n},a.ticks=function(e){return Wi(t,e)},a.tickFormat=function(e,n){return Zi(t,e,n)},a.nice=function(e){return Gi(t,e),i()},a.copy=function(){return Vi(t,e,n,r)},i()}function $i(t,e){return nu.rebind(t,e,"range","rangeRound","interpolate","clamp")}function Gi(t,e){return Ui(t,Yi(Hi(t,e)[2]))}function Hi(t,e){null==e&&(e=10);var n=Pi(t),r=n[1]-n[0],i=Math.pow(10,Math.floor(Math.log(r/e)/Math.LN10)),a=e/r*i;return.15>=a?i*=10:.35>=a?i*=5:.75>=a&&(i*=2),n[0]=Math.ceil(n[0]/i)*i,n[1]=Math.floor(n[1]/i)*i+.5*i,n[2]=i,n}function Wi(t,e){return nu.range.apply(nu,Hi(t,e))}function Zi(t,e,n){var r=Hi(t,e);if(n){var i=uo.exec(n);if(i.shift(),"s"===i[8]){var a=nu.formatPrefix(Math.max(pu(r[0]),pu(r[1])));return i[7]||(i[7]="."+Xi(a.scale(r[2]))),i[8]="f",n=nu.format(i.join("")),function(t){return n(a.scale(t))+a.symbol}}i[7]||(i[7]="."+Ji(i[8],r)),n=i.join("")}else n=",."+Xi(r[2])+"f";return nu.format(n)}function Xi(t){return-Math.floor(Math.log(t)/Math.LN10+.01)}function Ji(t,e){var n=Xi(e[2]);return t in _s?Math.abs(n-Xi(Math.max(pu(e[0]),pu(e[1]))))+ +("e"!==t):n-2*("%"===t)}function Ki(t,e,n,r){function i(t){return(n?Math.log(0>t?0:t):-Math.log(t>0?0:-t))/Math.log(e)}function a(t){return n?Math.pow(e,t):-Math.pow(e,-t)}function u(e){return t(i(e))}return u.invert=function(e){return a(t.invert(e))},u.domain=function(e){return arguments.length?(n=e[0]>=0,t.domain((r=e.map(Number)).map(i)),u):r},u.base=function(n){return arguments.length?(e=+n,t.domain(r.map(i)),u):e},u.nice=function(){var e=Ui(r.map(i),n?Math:ws);return t.domain(e),r=e.map(a),u},u.ticks=function(){var t=Pi(r),u=[],o=t[0],s=t[1],c=Math.floor(i(o)),l=Math.ceil(i(s)),h=e%1?2:e;if(isFinite(l-c)){if(n){for(;l>c;c++)for(var f=1;h>f;f++)u.push(a(c)*f);u.push(a(c))}else for(u.push(a(c));c++0;f--)u.push(a(c)*f);for(c=0;u[c]s;l--);u=u.slice(c,l)}return u},u.tickFormat=function(t,e){if(!arguments.length)return xs;arguments.length<2?e=xs:"function"!=typeof e&&(e=nu.format(e));var r,o=Math.max(.1,t/u.ticks().length),s=n?(r=1e-12,Math.ceil):(r=-1e-12,Math.floor);return function(t){return t/a(s(i(t)+r))<=o?e(t):""}},u.copy=function(){return Ki(t.copy(),e,n,r)},$i(u,t)}function Qi(t,e,n){function r(e){return t(i(e))}var i=ta(e),a=ta(1/e);return r.invert=function(e){return a(t.invert(e))},r.domain=function(e){return arguments.length?(t.domain((n=e.map(Number)).map(i)),r):n},r.ticks=function(t){return Wi(n,t)},r.tickFormat=function(t,e){return Zi(n,t,e)},r.nice=function(t){return r.domain(Gi(n,t))},r.exponent=function(u){return arguments.length?(i=ta(e=u),a=ta(1/e),t.domain(n.map(i)),r):e},r.copy=function(){return Qi(t.copy(),e,n)},$i(r,t)}function ta(t){return function(e){return 0>e?-Math.pow(-e,t):Math.pow(e,t)}}function ea(t,e){function n(n){return a[((i.get(n)||("range"===e.t?i.set(n,t.push(n)):0/0))-1)%a.length]}function r(e,n){return nu.range(t.length).map(function(t){return e+n*t})}var i,a,u;return n.domain=function(r){if(!arguments.length)return t;t=[],i=new l;for(var a,u=-1,o=r.length;++un?[0/0,0/0]:[n>0?o[n-1]:t[0],ne?0/0:e/a+t,[e,e+1/a]},r.copy=function(){return ra(t,e,n)},i()}function ia(t,e){function n(n){return n>=n?e[nu.bisect(t,n)]:void 0}return n.domain=function(e){return arguments.length?(t=e,n):t},n.range=function(t){return arguments.length?(e=t,n):e},n.invertExtent=function(n){return n=e.indexOf(n),[t[n-1],t[n]]},n.copy=function(){return ia(t,e)},n}function aa(t){function e(t){return+t}return e.invert=e,e.domain=e.range=function(n){return arguments.length?(t=n.map(e),e):t},e.ticks=function(e){return Wi(t,e)},e.tickFormat=function(e,n){return Zi(t,e,n)},e.copy=function(){return aa(t)},e}function ua(){return 0}function oa(t){return t.innerRadius}function sa(t){return t.outerRadius}function ca(t){return t.startAngle}function la(t){return t.endAngle}function ha(t){return t&&t.padAngle}function fa(t,e,n,r){return(t-n)*e-(e-r)*t>0?0:1}function da(t,e,n,r,i){var a=t[0]-e[0],u=t[1]-e[1],o=(i?r:-r)/Math.sqrt(a*a+u*u),s=o*u,c=-o*a,l=t[0]+s,h=t[1]+c,f=e[0]+s,d=e[1]+c,p=(l+f)/2,g=(h+d)/2,y=f-l,m=d-h,v=y*y+m*m,b=n-r,_=l*d-f*h,x=(0>m?-1:1)*Math.sqrt(b*b*v-_*_),w=(_*m-y*x)/v,A=(-_*y-m*x)/v,E=(_*m+y*x)/v,k=(-_*y+m*x)/v,D=w-p,C=A-g,M=E-p,S=k-g;return D*D+C*C>M*M+S*S&&(w=E,A=k),[[w-s,A-c],[w*n/b,A*n/b]]}function pa(t){function e(e){function u(){c.push("M",a(t(l),o))}for(var s,c=[],l=[],h=-1,f=e.length,d=Ct(n),p=Ct(r);++h1&&i.push("H",r[0]),i.join("")}function va(t){for(var e=0,n=t.length,r=t[0],i=[r[0],",",r[1]];++e1){o=e[1],a=t[s],s++,r+="C"+(i[0]+u[0])+","+(i[1]+u[1])+","+(a[0]-o[0])+","+(a[1]-o[1])+","+a[0]+","+a[1];for(var c=2;c9&&(i=3*e/Math.sqrt(i),u[o]=i*n,u[o+1]=i*r));for(o=-1;++o<=s;)i=(t[Math.min(s,o+1)][0]-t[Math.max(0,o-1)][0])/(6*(1+u[o]*u[o])),a.push([i||0,u[o]*i||0]);return a}function Na(t){return t.length<3?ga(t):t[0]+Aa(t,La(t))}function Oa(t){for(var e,n,r,i=-1,a=t.length;++ir)return l();var i=a[a.active];i&&(--a.count,delete a[a.active],i.event&&i.event.interrupt.call(t,t.__data__,i.index)),a.active=r,u.event&&u.event.start.call(t,t.__data__,e),u.tween.forEach(function(n,r){(r=r.call(t,t.__data__,e))&&g.push(r)}),f=u.ease,h=u.duration,nu.timer(function(){return p.c=c(n||1)?Se:c,1},0,o)}function c(n){if(a.active!==r)return 1;for(var i=n/h,o=f(i),s=g.length;s>0;)g[--s].call(t,o);return i>=1?(u.event&&u.event.end.call(t,t.__data__,e),l()):void 0}function l(){return--a.count?delete a[r]:delete t[n],1}var h,f,d=u.delay,p=ro,g=[];return p.t=d+o,i>=d?s(i-d):void(p.c=s)},0,o)}}function Za(t,e,n){t.attr("transform",function(t){var r=e(t);return"translate("+(isFinite(r)?r:n(t))+",0)"})}function Xa(t,e,n){t.attr("transform",function(t){var r=e(t);return"translate(0,"+(isFinite(r)?r:n(t))+")"})}function Ja(t){return t.toISOString()}function Ka(t,e,n){function r(e){return t(e)}function i(t,n){var r=t[1]-t[0],i=r/n,a=nu.bisect(Hs,i);return a==Hs.length?[e.year,Hi(t.map(function(t){return t/31536e6}),n)[2]]:a?e[i/Hs[a-1]1?{floor:function(e){for(;n(e=t.floor(e));)e=Qa(e-1);return e},ceil:function(e){for(;n(e=t.ceil(e));)e=Qa(+e+1);return e}}:t))},r.ticks=function(t,e){var n=Pi(r.domain()),a=null==t?i(n,10):"number"==typeof t?i(n,t):!t.range&&[{range:t},e];return a&&(t=a[0],e=a[1]),t.range(n[0],Qa(+n[1]+1),1>e?1:e)},r.tickFormat=function(){return n},r.copy=function(){return Ka(t.copy(),e,n)},$i(r,t)}function Qa(t){return new Date(t)}function tu(t){return JSON.parse(t.responseText)}function eu(t){var e=au.createRange();return e.selectNode(au.body),e.createContextualFragment(t.responseText)}var nu={version:"3.5.6"},ru=[].slice,iu=function(t){return ru.call(t)},au=this.document;if(au)try{iu(au.documentElement.childNodes)[0].nodeType}catch(uu){iu=function(t){for(var e=t.length,n=new Array(e);e--;)n[e]=t[e];return n}}if(Date.now||(Date.now=function(){return+new Date}),au)try{au.createElement("DIV").style.setProperty("opacity",0,"")}catch(ou){var su=this.Element.prototype,cu=su.setAttribute,lu=su.setAttributeNS,hu=this.CSSStyleDeclaration.prototype,fu=hu.setProperty;su.setAttribute=function(t,e){cu.call(this,t,e+"")},su.setAttributeNS=function(t,e,n){lu.call(this,t,e,n+"")},hu.setProperty=function(t,e,n){fu.call(this,t,e+"",n)}}nu.ascending=r,nu.descending=function(t,e){return t>e?-1:e>t?1:e>=t?0:0/0},nu.min=function(t,e){var n,r,i=-1,a=t.length;if(1===arguments.length){for(;++i=r){n=r;break}for(;++ir&&(n=r)}else{for(;++i=r){n=r;break}for(;++ir&&(n=r)}return n},nu.max=function(t,e){var n,r,i=-1,a=t.length;if(1===arguments.length){for(;++i=r){n=r;break}for(;++in&&(n=r)}else{for(;++i=r){n=r;break}for(;++in&&(n=r)}return n},nu.extent=function(t,e){var n,r,i,a=-1,u=t.length;if(1===arguments.length){for(;++a=r){n=i=r;break}for(;++ar&&(n=r),r>i&&(i=r))}else{for(;++a=r){n=i=r;break}for(;++ar&&(n=r),r>i&&(i=r))}return[n,i]},nu.sum=function(t,e){var n,r=0,i=t.length,u=-1;if(1===arguments.length)for(;++u1?s/(l-1):void 0},nu.deviation=function(){var t=nu.variance.apply(this,arguments);return t?Math.sqrt(t):t};var du=u(r);nu.bisectLeft=du.left,nu.bisect=nu.bisectRight=du.right,nu.bisector=function(t){return u(1===t.length?function(e,n){return r(t(e),n)}:t)},nu.shuffle=function(t,e,n){(a=arguments.length)<3&&(n=t.length,2>a&&(e=0));for(var r,i,a=n-e;a;)i=Math.random()*a--|0,r=t[a+e],t[a+e]=t[i+e],t[i+e]=r;return t},nu.permute=function(t,e){for(var n=e.length,r=new Array(n);n--;)r[n]=t[e[n]];return r},nu.pairs=function(t){for(var e,n=0,r=t.length-1,i=t[0],a=new Array(0>r?0:r);r>n;)a[n]=[e=i,i=t[++n]];return a},nu.zip=function(){if(!(r=arguments.length))return[];for(var t=-1,e=nu.min(arguments,o),n=new Array(e);++t=0;)for(r=t[i],e=r.length;--e>=0;)n[--u]=r[e];return n};var pu=Math.abs;nu.range=function(t,e,n){if(arguments.length<3&&(n=1,arguments.length<2&&(e=t,t=0)),(e-t)/n===1/0)throw new Error("infinite range");var r,i=[],a=s(pu(n)),u=-1;if(t*=a,e*=a,n*=a,0>n)for(;(r=t+n*++u)>e;)i.push(r/a);else for(;(r=t+n*++u)=a.length)return r?r.call(i,u):n?u.sort(n):u;for(var s,c,h,f,d=-1,p=u.length,g=a[o++],y=new l;++d=a.length)return t;var r=[],i=u[n++];return t.forEach(function(t,i){r.push({key:t,values:e(i,n)})}),i?r.sort(function(t,e){return i(t.key,e.key)}):r}var n,r,i={},a=[],u=[];return i.map=function(e,n){return t(n,e,0)},i.entries=function(n){return e(t(nu.map,n,0),0)},i.key=function(t){return a.push(t),i},i.sortKeys=function(t){return u[a.length-1]=t,i},i.sortValues=function(t){return n=t,i},i.rollup=function(t){return r=t,i},i},nu.set=function(t){var e=new v;if(t)for(var n=0,r=t.length;r>n;++n)e.add(t[n]);return e},c(v,{has:d,add:function(t){return this._[h(t+="")]=!0,t},remove:p,values:g,size:y,empty:m,forEach:function(t){for(var e in this._)t.call(this,f(e))}}),nu.behavior={},nu.rebind=function(t,e){for(var n,r=1,i=arguments.length;++r=0&&(r=t.slice(n+1),t=t.slice(0,n)),t)return arguments.length<2?this[t].on(r):this[t].on(r,e);if(2===arguments.length){if(null==e)for(t in this)this.hasOwnProperty(t)&&this[t].on(r,null);return this}},nu.event=null,nu.requote=function(t){return t.replace(vu,"\\$&")};var vu=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,bu={}.__proto__?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)t[n]=e[n]},_u=function(t,e){return e.querySelector(t)},xu=function(t,e){return e.querySelectorAll(t)},wu=function(t,e){var n=t.matches||t[x(t,"matchesSelector")];return(wu=function(t,e){return n.call(t,e)})(t,e)};"function"==typeof Sizzle&&(_u=function(t,e){return Sizzle(t,e)[0]||null},xu=Sizzle,wu=Sizzle.matchesSelector),nu.selection=function(){return nu.select(au.documentElement)};var Au=nu.selection.prototype=[];Au.select=function(t){var e,n,r,i,a=[];t=S(t);for(var u=-1,o=this.length;++u=0&&(n=t.slice(0,e),t=t.slice(e+1)),Eu.hasOwnProperty(n)?{space:Eu[n],local:t}:t}},Au.attr=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node();return t=nu.ns.qualify(t),t.local?n.getAttributeNS(t.space,t.local):n.getAttribute(t)}for(e in t)this.each(F(e,t[e]));return this}return this.each(F(t,e))},Au.classed=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node(),r=(t=N(t)).length,i=-1;if(e=n.classList){for(;++ii){if("string"!=typeof t){2>i&&(e="");for(r in t)this.each(R(r,t[r],e));return this}if(2>i){var a=this.node();return n(a).getComputedStyle(a,null).getPropertyValue(t)}r=""}return this.each(R(t,e,r))},Au.property=function(t,e){if(arguments.length<2){if("string"==typeof t)return this.node()[t];for(e in t)this.each(P(e,t[e]));return this}return this.each(P(t,e))},Au.text=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}:null==t?function(){this.textContent=""}:function(){this.textContent=t}):this.node().textContent},Au.html=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}:null==t?function(){this.innerHTML=""}:function(){this.innerHTML=t}):this.node().innerHTML},Au.append=function(t){return t=q(t),this.select(function(){return this.appendChild(t.apply(this,arguments))})},Au.insert=function(t,e){return t=q(t),e=S(e),this.select(function(){return this.insertBefore(t.apply(this,arguments),e.apply(this,arguments)||null)})},Au.remove=function(){return this.each(j)},Au.data=function(t,e){function n(t,n){var r,i,a,u=t.length,h=n.length,f=Math.min(u,h),d=new Array(h),p=new Array(h),g=new Array(u);if(e){var y,m=new l,v=new Array(u);for(r=-1;++rr;++r)p[r]=U(n[r]);for(;u>r;++r)g[r]=t[r]}p.update=d,p.parentNode=d.parentNode=g.parentNode=t.parentNode,o.push(p),s.push(d),c.push(g)}var r,i,a=-1,u=this.length;if(!arguments.length){for(t=new Array(u=(r=this[0]).length);++aa;a++){i.push(e=[]),e.parentNode=(n=this[a]).parentNode;for(var o=0,s=n.length;s>o;o++)(r=n[o])&&t.call(r,r.__data__,o,a)&&e.push(r)}return M(i)},Au.order=function(){for(var t=-1,e=this.length;++t=0;)(n=r[i])&&(a&&a!==n.nextSibling&&a.parentNode.insertBefore(n,a),a=n);return this},Au.sort=function(t){t=z.apply(this,arguments);for(var e=-1,n=this.length;++et;t++)for(var n=this[t],r=0,i=n.length;i>r;r++){var a=n[r];if(a)return a}return null},Au.size=function(){var t=0;return V(this,function(){++t}),t};var ku=[];nu.selection.enter=$,nu.selection.enter.prototype=ku,ku.append=Au.append,ku.empty=Au.empty,ku.node=Au.node,ku.call=Au.call,ku.size=Au.size,ku.select=function(t){for(var e,n,r,i,a,u=[],o=-1,s=this.length;++or){if("string"!=typeof t){2>r&&(e=!1);for(n in t)this.each(H(n,t[n],e));return this}if(2>r)return(r=this.node()["__on"+t])&&r._;n=!1}return this.each(H(t,e,n))};var Du=nu.map({mouseenter:"mouseover",mouseleave:"mouseout"});au&&Du.forEach(function(t){"on"+t in au&&Du.remove(t)});var Cu,Mu=0;nu.mouse=function(t){return J(t,D())};var Su=this.navigator&&/WebKit/.test(this.navigator.userAgent)?-1:0;nu.touch=function(t,e,n){if(arguments.length<3&&(n=e,e=D().changedTouches),e)for(var r,i=0,a=e.length;a>i;++i)if((r=e[i]).identifier===n)return J(t,r)},nu.behavior.drag=function(){function t(){this.on("mousedown.drag",a).on("touchstart.drag",u)}function e(t,e,n,a,u){return function(){function o(){var t,n,r=e(f,g);r&&(t=r[0]-b[0],n=r[1]-b[1],p|=t|n,b=r,d({type:"drag",x:r[0]+c[0],y:r[1]+c[1],dx:t,dy:n}))}function s(){e(f,g)&&(m.on(a+y,null).on(u+y,null),v(p&&nu.event.target===h),d({type:"dragend"}))}var c,l=this,h=nu.event.target,f=l.parentNode,d=r.of(l,arguments),p=0,g=t(),y=".drag"+(null==g?"":"-"+g),m=nu.select(n(h)).on(a+y,o).on(u+y,s),v=X(h),b=e(f,g);i?(c=i.apply(l,arguments),c=[c.x-b[0],c.y-b[1]]):c=[0,0],d({type:"dragstart"})}}var r=C(t,"drag","dragstart","dragend"),i=null,a=e(w,nu.mouse,n,"mousemove","mouseup"),u=e(K,nu.touch,b,"touchmove","touchend");return t.origin=function(e){return arguments.length?(i=e,t):i},nu.rebind(t,r,"on")},nu.touches=function(t,e){return arguments.length<2&&(e=D().touches),e?iu(e).map(function(e){var n=J(t,e);return n.identifier=e.identifier,n}):[]};var Tu=1e-6,Fu=Tu*Tu,Bu=Math.PI,Lu=2*Bu,Nu=Lu-Tu,Ou=Bu/2,Iu=Bu/180,Ru=180/Bu,Pu=Math.SQRT2,qu=2,ju=4;nu.interpolateZoom=function(t,e){function n(t){var e=t*v;if(m){var n=it(g),u=a/(qu*f)*(n*at(Pu*e+g)-rt(g));return[r+u*c,i+u*l,a*n/it(Pu*e+g)]}return[r+t*c,i+t*l,a*Math.exp(Pu*e)]}var r=t[0],i=t[1],a=t[2],u=e[0],o=e[1],s=e[2],c=u-r,l=o-i,h=c*c+l*l,f=Math.sqrt(h),d=(s*s-a*a+ju*h)/(2*a*qu*f),p=(s*s-a*a-ju*h)/(2*s*qu*f),g=Math.log(Math.sqrt(d*d+1)-d),y=Math.log(Math.sqrt(p*p+1)-p),m=y-g,v=(m||Math.log(s/a))/Pu;return n.duration=1e3*v,n},nu.behavior.zoom=function(){function t(t){t.on(F,h).on(Yu+".zoom",d).on("dblclick.zoom",p).on(N,f)}function e(t){return[(t[0]-E.x)/E.k,(t[1]-E.y)/E.k]}function r(t){return[t[0]*E.k+E.x,t[1]*E.k+E.y]}function i(t){E.k=Math.max(M[0],Math.min(M[1],t))}function a(t,e){e=r(e),E.x+=t[0]-e[0],E.y+=t[1]-e[1]}function u(e,n,r,u){e.__chart__={x:E.x,y:E.y,k:E.k},i(Math.pow(2,u)),a(y=n,r),e=nu.select(e),S>0&&(e=e.transition().duration(S)),e.call(t.event)}function o(){x&&x.domain(_.range().map(function(t){return(t-E.x)/E.k}).map(_.invert)),A&&A.domain(w.range().map(function(t){return(t-E.y)/E.k}).map(w.invert))}function s(t){T++||t({type:"zoomstart"})}function c(t){o(),t({type:"zoom",scale:E.k,translate:[E.x,E.y]})}function l(t){--T||(t({type:"zoomend"}),y=null)}function h(){function t(){h=1,a(nu.mouse(i),d),c(o)}function r(){f.on(B,null).on(L,null),p(h&&nu.event.target===u),l(o)}var i=this,u=nu.event.target,o=O.of(i,arguments),h=0,f=nu.select(n(i)).on(B,t).on(L,r),d=e(nu.mouse(i)),p=X(i);Rs.call(i),s(o)}function f(){function t(){var t=nu.touches(p);return d=E.k,t.forEach(function(t){t.identifier in y&&(y[t.identifier]=e(t))}),t}function n(){var e=nu.event.target;nu.select(e).on(_,r).on(x,o),w.push(e);for(var n=nu.event.changedTouches,i=0,a=n.length;a>i;++i)y[n[i].identifier]=null;var s=t(),c=Date.now();if(1===s.length){if(500>c-b){var l=s[0];u(p,l,y[l.identifier],Math.floor(Math.log(E.k)/Math.LN2)+1),k()}b=c}else if(s.length>1){var l=s[0],h=s[1],f=l[0]-h[0],d=l[1]-h[1];m=f*f+d*d}}function r(){var t,e,n,r,u=nu.touches(p);Rs.call(p);for(var o=0,s=u.length;s>o;++o,r=null)if(n=u[o],r=y[n.identifier]){if(e)break;t=n,e=r}if(r){var l=(l=n[0]-t[0])*l+(l=n[1]-t[1])*l,h=m&&Math.sqrt(l/m);t=[(t[0]+n[0])/2,(t[1]+n[1])/2],e=[(e[0]+r[0])/2,(e[1]+r[1])/2],i(h*d)}b=null,a(t,e),c(g)}function o(){if(nu.event.touches.length){for(var e=nu.event.changedTouches,n=0,r=e.length;r>n;++n)delete y[e[n].identifier];for(var i in y)return void t()}nu.selectAll(w).on(v,null),A.on(F,h).on(N,f),D(),l(g)}var d,p=this,g=O.of(p,arguments),y={},m=0,v=".zoom-"+nu.event.changedTouches[0].identifier,_="touchmove"+v,x="touchend"+v,w=[],A=nu.select(p),D=X(p);n(),s(g),A.on(F,null).on(N,n)}function d(){var t=O.of(this,arguments);v?clearTimeout(v):(Rs.call(this),g=e(y=m||nu.mouse(this)),s(t)),v=setTimeout(function(){v=null,l(t)},50),k(),i(Math.pow(2,.002*Uu())*E.k),a(y,g),c(t)}function p(){var t=nu.mouse(this),n=Math.log(E.k)/Math.LN2;u(this,t,e(t),nu.event.shiftKey?Math.ceil(n)-1:Math.floor(n)+1)}var g,y,m,v,b,_,x,w,A,E={x:0,y:0,k:1},D=[960,500],M=zu,S=250,T=0,F="mousedown.zoom",B="mousemove.zoom",L="mouseup.zoom",N="touchstart.zoom",O=C(t,"zoomstart","zoom","zoomend");return Yu||(Yu="onwheel"in au?(Uu=function(){return-nu.event.deltaY*(nu.event.deltaMode?120:1)},"wheel"):"onmousewheel"in au?(Uu=function(){return nu.event.wheelDelta},"mousewheel"):(Uu=function(){return-nu.event.detail},"MozMousePixelScroll")),t.event=function(t){t.each(function(){var t=O.of(this,arguments),e=E;Os?nu.select(this).transition().each("start.zoom",function(){E=this.__chart__||{x:0,y:0,k:1},s(t)}).tween("zoom:zoom",function(){var n=D[0],r=D[1],i=y?y[0]:n/2,a=y?y[1]:r/2,u=nu.interpolateZoom([(i-E.x)/E.k,(a-E.y)/E.k,n/E.k],[(i-e.x)/e.k,(a-e.y)/e.k,n/e.k]);return function(e){var r=u(e),o=n/r[2];this.__chart__=E={x:i-r[0]*o,y:a-r[1]*o,k:o},c(t)}}).each("interrupt.zoom",function(){l(t)}).each("end.zoom",function(){l(t)}):(this.__chart__=E,s(t),c(t),l(t))})},t.translate=function(e){return arguments.length?(E={x:+e[0],y:+e[1],k:E.k},o(),t):[E.x,E.y]},t.scale=function(e){return arguments.length?(E={x:E.x,y:E.y,k:+e},o(),t):E.k},t.scaleExtent=function(e){return arguments.length?(M=null==e?zu:[+e[0],+e[1]],t):M},t.center=function(e){return arguments.length?(m=e&&[+e[0],+e[1]],t):m},t.size=function(e){return arguments.length?(D=e&&[+e[0],+e[1]],t):D},t.duration=function(e){return arguments.length?(S=+e,t):S},t.x=function(e){return arguments.length?(x=e,_=e.copy(),E={x:0,y:0,k:1},t):x},t.y=function(e){return arguments.length?(A=e,w=e.copy(),E={x:0,y:0,k:1},t):A},nu.rebind(t,O,"on")};var Uu,Yu,zu=[0,1/0];nu.color=ot,ot.prototype.toString=function(){return this.rgb()+""},nu.hsl=st;var Vu=st.prototype=new ot;Vu.brighter=function(t){return t=Math.pow(.7,arguments.length?t:1),new st(this.h,this.s,this.l/t)},Vu.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new st(this.h,this.s,t*this.l)},Vu.rgb=function(){return ct(this.h,this.s,this.l)},nu.hcl=lt;var $u=lt.prototype=new ot;$u.brighter=function(t){return new lt(this.h,this.c,Math.min(100,this.l+Gu*(arguments.length?t:1)))},$u.darker=function(t){return new lt(this.h,this.c,Math.max(0,this.l-Gu*(arguments.length?t:1)))},$u.rgb=function(){return ht(this.h,this.c,this.l).rgb()},nu.lab=ft;var Gu=18,Hu=.95047,Wu=1,Zu=1.08883,Xu=ft.prototype=new ot;Xu.brighter=function(t){return new ft(Math.min(100,this.l+Gu*(arguments.length?t:1)),this.a,this.b)},Xu.darker=function(t){return new ft(Math.max(0,this.l-Gu*(arguments.length?t:1)),this.a,this.b)},Xu.rgb=function(){return dt(this.l,this.a,this.b)},nu.rgb=vt;var Ju=vt.prototype=new ot;Ju.brighter=function(t){t=Math.pow(.7,arguments.length?t:1);var e=this.r,n=this.g,r=this.b,i=30;return e||n||r?(e&&i>e&&(e=i),n&&i>n&&(n=i),r&&i>r&&(r=i),new vt(Math.min(255,e/t),Math.min(255,n/t),Math.min(255,r/t))):new vt(i,i,i)},Ju.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new vt(t*this.r,t*this.g,t*this.b)},Ju.hsl=function(){return At(this.r,this.g,this.b)},Ju.toString=function(){return"#"+xt(this.r)+xt(this.g)+xt(this.b)};var Ku=nu.map({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});Ku.forEach(function(t,e){Ku.set(t,bt(e))}),nu.functor=Ct,nu.xhr=Mt(b),nu.dsv=function(t,e){function n(t,n,a){arguments.length<3&&(a=n,n=null);var u=St(t,e,null==n?r:i(n),a);return u.row=function(t){return arguments.length?u.response(null==(n=t)?r:i(t)):n},u}function r(t){return n.parse(t.responseText)}function i(t){return function(e){return n.parse(e.responseText,t)}}function a(e){return e.map(u).join(t)}function u(t){return o.test(t)?'"'+t.replace(/\"/g,'""')+'"':t}var o=new RegExp('["'+t+"\n]"),s=t.charCodeAt(0);return n.parse=function(t,e){var r;return n.parseRows(t,function(t,n){if(r)return r(t,n-1);var i=new Function("d","return {"+t.map(function(t,e){return JSON.stringify(t)+": d["+e+"]"}).join(",")+"}");r=e?function(t,n){return e(i(t),n)}:i})},n.parseRows=function(t,e){function n(){if(l>=c)return u;if(i)return i=!1,a;var e=l;if(34===t.charCodeAt(e)){for(var n=e;n++l;){var r=t.charCodeAt(l++),o=1;if(10===r)i=!0;else if(13===r)i=!0,10===t.charCodeAt(l)&&(++l,++o);else if(r!==s)continue;return t.slice(e,l-o)}return t.slice(e)}for(var r,i,a={},u={},o=[],c=t.length,l=0,h=0;(r=n())!==u;){for(var f=[];r!==a&&r!==u;)f.push(r),r=n();e&&null==(f=e(f,h++))||o.push(f)}return o},n.format=function(e){if(Array.isArray(e[0]))return n.formatRows(e);var r=new v,i=[];return e.forEach(function(t){for(var e in t)r.has(e)||i.push(r.add(e))}),[i.map(u).join(t)].concat(e.map(function(e){return i.map(function(t){return u(e[t])}).join(t)})).join("\n")},n.formatRows=function(t){return t.map(a).join("\n")},n},nu.csv=nu.dsv(",","text/csv"),nu.tsv=nu.dsv(" ","text/tab-separated-values");var Qu,to,eo,no,ro,io=this[x(this,"requestAnimationFrame")]||function(t){setTimeout(t,17)};nu.timer=function(t,e,n){var r=arguments.length;2>r&&(e=0),3>r&&(n=Date.now());var i=n+e,a={c:t,t:i,f:!1,n:null};to?to.n=a:Qu=a, +to=a,eo||(no=clearTimeout(no),eo=1,io(Bt))},nu.timer.flush=function(){Lt(),Nt()},nu.round=function(t,e){return e?Math.round(t*(e=Math.pow(10,e)))/e:Math.round(t)};var ao=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"].map(It);nu.formatPrefix=function(t,e){var n=0;return t&&(0>t&&(t*=-1),e&&(t=nu.round(t,Ot(t,e))),n=1+Math.floor(1e-12+Math.log(t)/Math.LN10),n=Math.max(-24,Math.min(24,3*Math.floor((n-1)/3)))),ao[8+n/3]};var uo=/(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i,oo=nu.map({b:function(t){return t.toString(2)},c:function(t){return String.fromCharCode(t)},o:function(t){return t.toString(8)},x:function(t){return t.toString(16)},X:function(t){return t.toString(16).toUpperCase()},g:function(t,e){return t.toPrecision(e)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},r:function(t,e){return(t=nu.round(t,Ot(t,e))).toFixed(Math.max(0,Math.min(20,Ot(t*(1+1e-15),e))))}}),so=nu.time={},co=Date;qt.prototype={getDate:function(){return this._.getUTCDate()},getDay:function(){return this._.getUTCDay()},getFullYear:function(){return this._.getUTCFullYear()},getHours:function(){return this._.getUTCHours()},getMilliseconds:function(){return this._.getUTCMilliseconds()},getMinutes:function(){return this._.getUTCMinutes()},getMonth:function(){return this._.getUTCMonth()},getSeconds:function(){return this._.getUTCSeconds()},getTime:function(){return this._.getTime()},getTimezoneOffset:function(){return 0},valueOf:function(){return this._.valueOf()},setDate:function(){lo.setUTCDate.apply(this._,arguments)},setDay:function(){lo.setUTCDay.apply(this._,arguments)},setFullYear:function(){lo.setUTCFullYear.apply(this._,arguments)},setHours:function(){lo.setUTCHours.apply(this._,arguments)},setMilliseconds:function(){lo.setUTCMilliseconds.apply(this._,arguments)},setMinutes:function(){lo.setUTCMinutes.apply(this._,arguments)},setMonth:function(){lo.setUTCMonth.apply(this._,arguments)},setSeconds:function(){lo.setUTCSeconds.apply(this._,arguments)},setTime:function(){lo.setTime.apply(this._,arguments)}};var lo=Date.prototype;so.year=jt(function(t){return t=so.day(t),t.setMonth(0,1),t},function(t,e){t.setFullYear(t.getFullYear()+e)},function(t){return t.getFullYear()}),so.years=so.year.range,so.years.utc=so.year.utc.range,so.day=jt(function(t){var e=new co(2e3,0);return e.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()),e},function(t,e){t.setDate(t.getDate()+e)},function(t){return t.getDate()-1}),so.days=so.day.range,so.days.utc=so.day.utc.range,so.dayOfYear=function(t){var e=so.year(t);return Math.floor((t-e-6e4*(t.getTimezoneOffset()-e.getTimezoneOffset()))/864e5)},["sunday","monday","tuesday","wednesday","thursday","friday","saturday"].forEach(function(t,e){e=7-e;var n=so[t]=jt(function(t){return(t=so.day(t)).setDate(t.getDate()-(t.getDay()+e)%7),t},function(t,e){t.setDate(t.getDate()+7*Math.floor(e))},function(t){var n=so.year(t).getDay();return Math.floor((so.dayOfYear(t)+(n+e)%7)/7)-(n!==e)});so[t+"s"]=n.range,so[t+"s"].utc=n.utc.range,so[t+"OfYear"]=function(t){var n=so.year(t).getDay();return Math.floor((so.dayOfYear(t)+(n+e)%7)/7)}}),so.week=so.sunday,so.weeks=so.sunday.range,so.weeks.utc=so.sunday.utc.range,so.weekOfYear=so.sundayOfYear;var ho={"-":"",_:" ",0:"0"},fo=/^\s*\d+/,po=/^%/;nu.locale=function(t){return{numberFormat:Rt(t),timeFormat:Yt(t)}};var go=nu.locale({decimal:".",thousands:",",grouping:[3],currency:["$",""],dateTime:"%a %b %e %X %Y",date:"%m/%d/%Y",time:"%H:%M:%S",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"]});nu.format=go.numberFormat,nu.geo={},ce.prototype={s:0,t:0,add:function(t){le(t,this.t,yo),le(yo.s,this.s,this),this.s?this.t+=yo.t:this.s=yo.t},reset:function(){this.s=this.t=0},valueOf:function(){return this.s}};var yo=new ce;nu.geo.stream=function(t,e){t&&mo.hasOwnProperty(t.type)?mo[t.type](t,e):he(t,e)};var mo={Feature:function(t,e){he(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++rt?4*Bu+t:t,xo.lineStart=xo.lineEnd=xo.point=w}};nu.geo.bounds=function(){function t(t,e){b.push(_=[l=t,f=t]),h>e&&(h=e),e>d&&(d=e)}function e(e,n){var r=ge([e*Iu,n*Iu]);if(m){var i=me(m,r),a=[i[1],-i[0],0],u=me(a,i);_e(u),u=xe(u);var s=e-p,c=s>0?1:-1,g=u[0]*Ru*c,y=pu(s)>180;if(y^(g>c*p&&c*e>g)){var v=u[1]*Ru;v>d&&(d=v)}else if(g=(g+360)%360-180,y^(g>c*p&&c*e>g)){var v=-u[1]*Ru;h>v&&(h=v)}else h>n&&(h=n),n>d&&(d=n);y?p>e?o(l,e)>o(l,f)&&(f=e):o(e,f)>o(l,f)&&(l=e):f>=l?(l>e&&(l=e),e>f&&(f=e)):e>p?o(l,e)>o(l,f)&&(f=e):o(e,f)>o(l,f)&&(l=e)}else t(e,n);m=r,p=e}function n(){x.point=e}function r(){_[0]=l,_[1]=f,x.point=t,m=null}function i(t,n){if(m){var r=t-p;v+=pu(r)>180?r+(r>0?360:-360):r}else g=t,y=n;xo.point(t,n),e(t,n)}function a(){xo.lineStart()}function u(){i(g,y),xo.lineEnd(),pu(v)>Tu&&(l=-(f=180)),_[0]=l,_[1]=f,m=null}function o(t,e){return(e-=t)<0?e+360:e}function s(t,e){return t[0]-e[0]}function c(t,e){return e[0]<=e[1]?e[0]<=t&&t<=e[1]:t_o?(l=-(f=180),h=-(d=90)):v>Tu?d=90:-Tu>v&&(h=-90),_[0]=l,_[1]=f}};return function(t){d=f=-(l=h=1/0),b=[],nu.geo.stream(t,x);var e=b.length;if(e){b.sort(s);for(var n,r=1,i=b[0],a=[i];e>r;++r)n=b[r],c(n[0],i)||c(n[1],i)?(o(i[0],n[1])>o(i[0],i[1])&&(i[1]=n[1]),o(n[0],i[1])>o(i[0],i[1])&&(i[0]=n[0])):a.push(i=n);for(var u,n,p=-(1/0),e=a.length-1,r=0,i=a[e];e>=r;i=n,++r)n=a[r],(u=o(i[1],n[0]))>p&&(p=u,l=n[0],f=i[1])}return b=_=null,l===1/0||h===1/0?[[0/0,0/0],[0/0,0/0]]:[[l,h],[f,d]]}}(),nu.geo.centroid=function(t){wo=Ao=Eo=ko=Do=Co=Mo=So=To=Fo=Bo=0,nu.geo.stream(t,Lo);var e=To,n=Fo,r=Bo,i=e*e+n*n+r*r;return Fu>i&&(e=Co,n=Mo,r=So,Tu>Ao&&(e=Eo,n=ko,r=Do),i=e*e+n*n+r*r,Fu>i)?[0/0,0/0]:[Math.atan2(n,e)*Ru,nt(r/Math.sqrt(i))*Ru]};var wo,Ao,Eo,ko,Do,Co,Mo,So,To,Fo,Bo,Lo={sphere:w,point:Ae,lineStart:ke,lineEnd:De,polygonStart:function(){Lo.lineStart=Ce},polygonEnd:function(){Lo.lineStart=ke}},No=Le(Se,Re,qe,[-Bu,-Bu/2]),Oo=1e9;nu.geo.clipExtent=function(){var t,e,n,r,i,a,u={stream:function(t){return i&&(i.valid=!1),i=a(t),i.valid=!0,i},extent:function(o){return arguments.length?(a=ze(t=+o[0][0],e=+o[0][1],n=+o[1][0],r=+o[1][1]),i&&(i.valid=!1,i=null),u):[[t,e],[n,r]]}};return u.extent([[0,0],[960,500]])},(nu.geo.conicEqualArea=function(){return Ve($e)}).raw=$e,nu.geo.albers=function(){return nu.geo.conicEqualArea().rotate([96,0]).center([-.6,38.7]).parallels([29.5,45.5]).scale(1070)},nu.geo.albersUsa=function(){function t(t){var a=t[0],u=t[1];return e=null,n(a,u),e||(r(a,u),e)||i(a,u),e}var e,n,r,i,a=nu.geo.albers(),u=nu.geo.conicEqualArea().rotate([154,0]).center([-2,58.5]).parallels([55,65]),o=nu.geo.conicEqualArea().rotate([157,0]).center([-3,19.9]).parallels([8,18]),s={point:function(t,n){e=[t,n]}};return t.invert=function(t){var e=a.scale(),n=a.translate(),r=(t[0]-n[0])/e,i=(t[1]-n[1])/e;return(i>=.12&&.234>i&&r>=-.425&&-.214>r?u:i>=.166&&.234>i&&r>=-.214&&-.115>r?o:a).invert(t)},t.stream=function(t){var e=a.stream(t),n=u.stream(t),r=o.stream(t);return{point:function(t,i){e.point(t,i),n.point(t,i),r.point(t,i)},sphere:function(){e.sphere(),n.sphere(),r.sphere()},lineStart:function(){e.lineStart(),n.lineStart(),r.lineStart()},lineEnd:function(){e.lineEnd(),n.lineEnd(),r.lineEnd()},polygonStart:function(){e.polygonStart(),n.polygonStart(),r.polygonStart()},polygonEnd:function(){e.polygonEnd(),n.polygonEnd(),r.polygonEnd()}}},t.precision=function(e){return arguments.length?(a.precision(e),u.precision(e),o.precision(e),t):a.precision()},t.scale=function(e){return arguments.length?(a.scale(e),u.scale(.35*e),o.scale(e),t.translate(a.translate())):a.scale()},t.translate=function(e){if(!arguments.length)return a.translate();var c=a.scale(),l=+e[0],h=+e[1];return n=a.translate(e).clipExtent([[l-.455*c,h-.238*c],[l+.455*c,h+.238*c]]).stream(s).point,r=u.translate([l-.307*c,h+.201*c]).clipExtent([[l-.425*c+Tu,h+.12*c+Tu],[l-.214*c-Tu,h+.234*c-Tu]]).stream(s).point,i=o.translate([l-.205*c,h+.212*c]).clipExtent([[l-.214*c+Tu,h+.166*c+Tu],[l-.115*c-Tu,h+.234*c-Tu]]).stream(s).point,t},t.scale(1070)};var Io,Ro,Po,qo,jo,Uo,Yo={point:w,lineStart:w,lineEnd:w,polygonStart:function(){Ro=0,Yo.lineStart=Ge},polygonEnd:function(){Yo.lineStart=Yo.lineEnd=Yo.point=w,Io+=pu(Ro/2)}},zo={point:He,lineStart:w,lineEnd:w,polygonStart:w,polygonEnd:w},Vo={point:Xe,lineStart:Je,lineEnd:Ke,polygonStart:function(){Vo.lineStart=Qe},polygonEnd:function(){Vo.point=Xe,Vo.lineStart=Je,Vo.lineEnd=Ke}};nu.geo.path=function(){function t(t){return t&&("function"==typeof o&&a.pointRadius(+o.apply(this,arguments)),u&&u.valid||(u=i(a)),nu.geo.stream(t,u)),a.result()}function e(){return u=null,t}var n,r,i,a,u,o=4.5;return t.area=function(t){return Io=0,nu.geo.stream(t,i(Yo)),Io},t.centroid=function(t){return Eo=ko=Do=Co=Mo=So=To=Fo=Bo=0,nu.geo.stream(t,i(Vo)),Bo?[To/Bo,Fo/Bo]:So?[Co/So,Mo/So]:Do?[Eo/Do,ko/Do]:[0/0,0/0]},t.bounds=function(t){return jo=Uo=-(Po=qo=1/0),nu.geo.stream(t,i(zo)),[[Po,qo],[jo,Uo]]},t.projection=function(t){return arguments.length?(i=(n=t)?t.stream||nn(t):b,e()):n},t.context=function(t){return arguments.length?(a=null==(r=t)?new We:new tn(t),"function"!=typeof o&&a.pointRadius(o),e()):r},t.pointRadius=function(e){return arguments.length?(o="function"==typeof e?e:(a.pointRadius(+e),+e),t):o},t.projection(nu.geo.albersUsa()).context(null)},nu.geo.transform=function(t){return{stream:function(e){var n=new rn(e);for(var r in t)n[r]=t[r];return n}}},rn.prototype={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()}},nu.geo.projection=un,nu.geo.projectionMutator=on,(nu.geo.equirectangular=function(){return un(cn)}).raw=cn.invert=cn,nu.geo.rotation=function(t){function e(e){return e=t(e[0]*Iu,e[1]*Iu),e[0]*=Ru,e[1]*=Ru,e}return t=hn(t[0]%360*Iu,t[1]*Iu,t.length>2?t[2]*Iu:0),e.invert=function(e){return e=t.invert(e[0]*Iu,e[1]*Iu),e[0]*=Ru,e[1]*=Ru,e},e},ln.invert=cn,nu.geo.circle=function(){function t(){var t="function"==typeof r?r.apply(this,arguments):r,e=hn(-t[0]*Iu,-t[1]*Iu,0).invert,i=[];return n(null,null,1,{point:function(t,n){i.push(t=e(t,n)),t[0]*=Ru,t[1]*=Ru}}),{type:"Polygon",coordinates:[i]}}var e,n,r=[0,0],i=6;return t.origin=function(e){return arguments.length?(r=e,t):r},t.angle=function(r){return arguments.length?(n=gn((e=+r)*Iu,i*Iu),t):e},t.precision=function(r){return arguments.length?(n=gn(e*Iu,(i=+r)*Iu),t):i},t.angle(90)},nu.geo.distance=function(t,e){var n,r=(e[0]-t[0])*Iu,i=t[1]*Iu,a=e[1]*Iu,u=Math.sin(r),o=Math.cos(r),s=Math.sin(i),c=Math.cos(i),l=Math.sin(a),h=Math.cos(a);return Math.atan2(Math.sqrt((n=h*u)*n+(n=c*l-s*h*o)*n),s*l+c*h*o)},nu.geo.graticule=function(){function t(){return{type:"MultiLineString",coordinates:e()}}function e(){return nu.range(Math.ceil(a/y)*y,i,y).map(f).concat(nu.range(Math.ceil(c/m)*m,s,m).map(d)).concat(nu.range(Math.ceil(r/p)*p,n,p).filter(function(t){return pu(t%y)>Tu}).map(l)).concat(nu.range(Math.ceil(o/g)*g,u,g).filter(function(t){return pu(t%m)>Tu}).map(h))}var n,r,i,a,u,o,s,c,l,h,f,d,p=10,g=p,y=90,m=360,v=2.5;return t.lines=function(){return e().map(function(t){return{type:"LineString",coordinates:t}})},t.outline=function(){return{type:"Polygon",coordinates:[f(a).concat(d(s).slice(1),f(i).reverse().slice(1),d(c).reverse().slice(1))]}},t.extent=function(e){return arguments.length?t.majorExtent(e).minorExtent(e):t.minorExtent()},t.majorExtent=function(e){return arguments.length?(a=+e[0][0],i=+e[1][0],c=+e[0][1],s=+e[1][1],a>i&&(e=a,a=i,i=e),c>s&&(e=c,c=s,s=e),t.precision(v)):[[a,c],[i,s]]},t.minorExtent=function(e){return arguments.length?(r=+e[0][0],n=+e[1][0],o=+e[0][1],u=+e[1][1],r>n&&(e=r,r=n,n=e),o>u&&(e=o,o=u,u=e),t.precision(v)):[[r,o],[n,u]]},t.step=function(e){return arguments.length?t.majorStep(e).minorStep(e):t.minorStep()},t.majorStep=function(e){return arguments.length?(y=+e[0],m=+e[1],t):[y,m]},t.minorStep=function(e){return arguments.length?(p=+e[0],g=+e[1],t):[p,g]},t.precision=function(e){return arguments.length?(v=+e,l=mn(o,u,90),h=vn(r,n,v),f=mn(c,s,90),d=vn(a,i,v),t):v},t.majorExtent([[-180,-90+Tu],[180,90-Tu]]).minorExtent([[-180,-80-Tu],[180,80+Tu]])},nu.geo.greatArc=function(){function t(){return{type:"LineString",coordinates:[e||r.apply(this,arguments),n||i.apply(this,arguments)]}}var e,n,r=bn,i=_n;return t.distance=function(){return nu.geo.distance(e||r.apply(this,arguments),n||i.apply(this,arguments))},t.source=function(n){return arguments.length?(r=n,e="function"==typeof n?null:n,t):r},t.target=function(e){return arguments.length?(i=e,n="function"==typeof e?null:e,t):i},t.precision=function(){return arguments.length?t:0},t},nu.geo.interpolate=function(t,e){return xn(t[0]*Iu,t[1]*Iu,e[0]*Iu,e[1]*Iu)},nu.geo.length=function(t){return $o=0,nu.geo.stream(t,Go),$o};var $o,Go={sphere:w,point:w,lineStart:wn,lineEnd:w,polygonStart:w,polygonEnd:w},Ho=An(function(t){return Math.sqrt(2/(1+t))},function(t){return 2*Math.asin(t/2)});(nu.geo.azimuthalEqualArea=function(){return un(Ho)}).raw=Ho;var Wo=An(function(t){var e=Math.acos(t);return e&&e/Math.sin(e)},b);(nu.geo.azimuthalEquidistant=function(){return un(Wo)}).raw=Wo,(nu.geo.conicConformal=function(){return Ve(En)}).raw=En,(nu.geo.conicEquidistant=function(){return Ve(kn)}).raw=kn;var Zo=An(function(t){return 1/t},Math.atan);(nu.geo.gnomonic=function(){return un(Zo)}).raw=Zo,Dn.invert=function(t,e){return[t,2*Math.atan(Math.exp(e))-Ou]},(nu.geo.mercator=function(){return Cn(Dn)}).raw=Dn;var Xo=An(function(){return 1},Math.asin);(nu.geo.orthographic=function(){return un(Xo)}).raw=Xo;var Jo=An(function(t){return 1/(1+t)},function(t){return 2*Math.atan(t)});(nu.geo.stereographic=function(){return un(Jo)}).raw=Jo,Mn.invert=function(t,e){return[-e,2*Math.atan(Math.exp(t))-Ou]},(nu.geo.transverseMercator=function(){var t=Cn(Mn),e=t.center,n=t.rotate;return t.center=function(t){return t?e([-t[1],t[0]]):(t=e(),[t[1],-t[0]])},t.rotate=function(t){return t?n([t[0],t[1],t.length>2?t[2]+90:90]):(t=n(),[t[0],t[1],t[2]-90])},n([0,0,90])}).raw=Mn,nu.geom={},nu.geom.hull=function(t){function e(t){if(t.length<3)return[];var e,i=Ct(n),a=Ct(r),u=t.length,o=[],s=[];for(e=0;u>e;e++)o.push([+i.call(this,t[e],e),+a.call(this,t[e],e),e]);for(o.sort(Bn),e=0;u>e;e++)s.push([o[e][0],-o[e][1]]);var c=Fn(o),l=Fn(s),h=l[0]===c[0],f=l[l.length-1]===c[c.length-1],d=[];for(e=c.length-1;e>=0;--e)d.push(t[o[c[e]][2]]);for(e=+h;e=r&&c.x<=a&&c.y>=i&&c.y<=u?[[r,u],[a,u],[a,i],[r,i]]:[];l.point=t[o]}),e}function n(t){return t.map(function(t,e){return{x:Math.round(a(t,e)/Tu)*Tu,y:Math.round(u(t,e)/Tu)*Tu,i:e}})}var r=Sn,i=Tn,a=r,u=i,o=us;return t?e(t):(e.links=function(t){return or(n(t)).edges.filter(function(t){return t.l&&t.r}).map(function(e){return{source:t[e.l.i],target:t[e.r.i]}})},e.triangles=function(t){var e=[];return or(n(t)).cells.forEach(function(n,r){for(var i,a,u=n.site,o=n.edges.sort($n),s=-1,c=o.length,l=o[c-1].edge,h=l.l===u?l.r:l.l;++s=c,f=r>=l,d=f<<1|h;t.leaf=!1,t=t.nodes[d]||(t.nodes[d]=fr()),h?i=c:o=c,f?u=l:s=l,a(t,e,n,r,i,u,o,s)}var l,h,f,d,p,g,y,m,v,b=Ct(o),_=Ct(s);if(null!=e)g=e,y=n,m=r,v=i;else if(m=v=-(g=y=1/0),h=[],f=[],p=t.length,u)for(d=0;p>d;++d)l=t[d],l.xm&&(m=l.x),l.y>v&&(v=l.y),h.push(l.x),f.push(l.y);else for(d=0;p>d;++d){var x=+b(l=t[d],d),w=+_(l,d);g>x&&(g=x),y>w&&(y=w),x>m&&(m=x),w>v&&(v=w),h.push(x),f.push(w)}var A=m-g,E=v-y;A>E?v=y+A:m=g+E;var k=fr();if(k.add=function(t){a(k,t,+b(t,++d),+_(t,d),g,y,m,v)},k.visit=function(t){dr(t,k,g,y,m,v)},k.find=function(t){return pr(k,t[0],t[1],g,y,m,v)},d=-1,null==e){for(;++d=0?t.slice(0,e):t,r=e>=0?t.slice(e+1):"in";return n=ls.get(n)||cs,r=hs.get(r)||b,xr(r(n.apply(null,ru.call(arguments,1))))},nu.interpolateHcl=Nr,nu.interpolateHsl=Or,nu.interpolateLab=Ir,nu.interpolateRound=Rr,nu.transform=function(t){var e=au.createElementNS(nu.ns.prefix.svg,"g");return(nu.transform=function(t){if(null!=t){e.setAttribute("transform",t);var n=e.transform.baseVal.consolidate()}return new Pr(n?n.matrix:fs)})(t)},Pr.prototype.toString=function(){return"translate("+this.translate+")rotate("+this.rotate+")skewX("+this.skew+")scale("+this.scale+")"};var fs={a:1,b:0,c:0,d:1,e:0,f:0};nu.interpolateTransform=Yr,nu.layout={},nu.layout.bundle=function(){return function(t){for(var e=[],n=-1,r=t.length;++no*o/y){if(p>s){var c=e.charge/s;t.px-=a*c,t.py-=u*c}return!0}if(e.point&&s&&p>s){var c=e.pointCharge/s;t.px-=a*c,t.py-=u*c}}return!e.charge}}function e(t){t.px=nu.event.x,t.py=nu.event.y,o.resume()}var n,r,i,a,u,o={},s=nu.dispatch("start","tick","end"),c=[1,1],l=.9,h=ds,f=ps,d=-30,p=gs,g=.1,y=.64,m=[],v=[];return o.tick=function(){if((r*=.99)<.005)return s.end({type:"end",alpha:r=0}),!0;var e,n,o,h,f,p,y,b,_,x=m.length,w=v.length;for(n=0;w>n;++n)o=v[n],h=o.source,f=o.target,b=f.x-h.x,_=f.y-h.y,(p=b*b+_*_)&&(p=r*a[n]*((p=Math.sqrt(p))-i[n])/p,b*=p,_*=p,f.x-=b*(y=h.weight/(f.weight+h.weight)),f.y-=_*y,h.x+=b*(y=1-y),h.y+=_*y);if((y=r*g)&&(b=c[0]/2,_=c[1]/2,n=-1,y))for(;++n0?t:0:t>0&&(s.start({type:"start",alpha:r=t}),nu.timer(o.tick)),o):r},o.start=function(){function t(t,r){if(!n){for(n=new Array(s),o=0;s>o;++o)n[o]=[];for(o=0;l>o;++o){var i=v[o];n[i.source.index].push(i.target),n[i.target.index].push(i.source)}}for(var a,u=n[e],o=-1,c=u.length;++oe;++e)(r=m[e]).index=e,r.weight=0;for(e=0;l>e;++e)r=v[e],"number"==typeof r.source&&(r.source=m[r.source]),"number"==typeof r.target&&(r.target=m[r.target]),++r.source.weight,++r.target.weight;for(e=0;s>e;++e)r=m[e],isNaN(r.x)&&(r.x=t("x",p)),isNaN(r.y)&&(r.y=t("y",g)),isNaN(r.px)&&(r.px=r.x),isNaN(r.py)&&(r.py=r.y);if(i=[],"function"==typeof h)for(e=0;l>e;++e)i[e]=+h.call(this,v[e],e);else for(e=0;l>e;++e)i[e]=h;if(a=[],"function"==typeof f)for(e=0;l>e;++e)a[e]=+f.call(this,v[e],e);else for(e=0;l>e;++e)a[e]=f;if(u=[],"function"==typeof d)for(e=0;s>e;++e)u[e]=+d.call(this,m[e],e);else for(e=0;s>e;++e)u[e]=d;return o.resume()},o.resume=function(){return o.alpha(.1)},o.stop=function(){return o.alpha(0)},o.drag=function(){return n||(n=nu.behavior.drag().origin(b).on("dragstart.force",Wr).on("drag.force",e).on("dragend.force",Zr)),arguments.length?void this.on("mouseover.force",Xr).on("mouseout.force",Jr).call(n):n},nu.rebind(o,s,"on")};var ds=20,ps=1,gs=1/0;nu.layout.hierarchy=function(){function t(i){var a,u=[i],o=[];for(i.depth=0;null!=(a=u.pop());)if(o.push(a),(c=n.call(t,a,a.depth))&&(s=c.length)){for(var s,c,l;--s>=0;)u.push(l=c[s]),l.parent=a,l.depth=a.depth+1;r&&(a.value=0),a.children=c}else r&&(a.value=+r.call(t,a,a.depth)||0),delete a.children;return ei(i,function(t){var n,i;e&&(n=t.children)&&n.sort(e),r&&(i=t.parent)&&(i.value+=t.value)}),o}var e=ii,n=ni,r=ri;return t.sort=function(n){return arguments.length?(e=n,t):e},t.children=function(e){return arguments.length?(n=e,t):n},t.value=function(e){return arguments.length?(r=e,t):r},t.revalue=function(e){return r&&(ti(e,function(t){t.children&&(t.value=0)}),ei(e,function(e){var n;e.children||(e.value=+r.call(t,e,e.depth)||0),(n=e.parent)&&(n.value+=e.value)})),e},t},nu.layout.partition=function(){function t(e,n,r,i){var a=e.children;if(e.x=n,e.y=e.depth*i,e.dx=r,e.dy=i,a&&(u=a.length)){var u,o,s,c=-1;for(r=e.value?r/e.value:0;++ch?-1:1),p=(h-s*d)/nu.sum(c),g=nu.range(s),y=[];return null!=n&&g.sort(n===ys?function(t,e){return c[e]-c[t]}:function(t,e){return n(u[t],u[e])}),g.forEach(function(t){y[t]={data:u[t],value:o=c[t],startAngle:l,endAngle:l+=o*p+d,padAngle:f}}),y}var e=Number,n=ys,r=0,i=Lu,a=0;return t.value=function(n){return arguments.length?(e=n,t):e},t.sort=function(e){return arguments.length?(n=e,t):n},t.startAngle=function(e){return arguments.length?(r=e,t):r},t.endAngle=function(e){return arguments.length?(i=e,t):i},t.padAngle=function(e){return arguments.length?(a=e,t):a},t};var ys={};nu.layout.stack=function(){function t(o,s){if(!(f=o.length))return o;var c=o.map(function(n,r){return e.call(t,n,r)}),l=c.map(function(e){return e.map(function(e,n){return[a.call(t,e,n),u.call(t,e,n)]})}),h=n.call(t,l,s);c=nu.permute(c,h),l=nu.permute(l,h);var f,d,p,g,y=r.call(t,l,s),m=c[0].length;for(p=0;m>p;++p)for(i.call(t,c[0][p],g=y[p],l[0][p][1]),d=1;f>d;++d)i.call(t,c[d][p],g+=l[d-1][p][1],l[d][p][1]);return o}var e=b,n=ci,r=li,i=si,a=ui,u=oi;return t.values=function(n){return arguments.length?(e=n,t):e},t.order=function(e){return arguments.length?(n="function"==typeof e?e:ms.get(e)||ci,t):n},t.offset=function(e){return arguments.length?(r="function"==typeof e?e:vs.get(e)||li,t):r},t.x=function(e){return arguments.length?(a=e,t):a},t.y=function(e){return arguments.length?(u=e,t):u},t.out=function(e){return arguments.length?(i=e,t):i},t};var ms=nu.map({"inside-out":function(t){var e,n,r=t.length,i=t.map(hi),a=t.map(fi),u=nu.range(r).sort(function(t,e){return i[t]-i[e]}),o=0,s=0,c=[],l=[];for(e=0;r>e;++e)n=u[e],s>o?(o+=a[n],c.push(n)):(s+=a[n],l.push(n));return l.reverse().concat(c)},reverse:function(t){return nu.range(t.length).reverse()},"default":ci}),vs=nu.map({silhouette:function(t){var e,n,r,i=t.length,a=t[0].length,u=[],o=0,s=[];for(n=0;a>n;++n){for(e=0,r=0;i>e;e++)r+=t[e][n][1];r>o&&(o=r),u.push(r)}for(n=0;a>n;++n)s[n]=(o-u[n])/2;return s},wiggle:function(t){var e,n,r,i,a,u,o,s,c,l=t.length,h=t[0],f=h.length,d=[];for(d[0]=s=c=0,n=1;f>n;++n){for(e=0,i=0;l>e;++e)i+=t[e][n][1];for(e=0,a=0,o=h[n][0]-h[n-1][0];l>e;++e){for(r=0,u=(t[e][n][1]-t[e][n-1][1])/(2*o);e>r;++r)u+=(t[r][n][1]-t[r][n-1][1])/o;a+=u*t[e][n][1]}d[n]=s-=i?a/i*o:0,c>s&&(c=s)}for(n=0;f>n;++n)d[n]-=c;return d},expand:function(t){var e,n,r,i=t.length,a=t[0].length,u=1/i,o=[];for(n=0;a>n;++n){for(e=0,r=0;i>e;e++)r+=t[e][n][1];if(r)for(e=0;i>e;e++)t[e][n][1]/=r;else for(e=0;i>e;e++)t[e][n][1]=u}for(n=0;a>n;++n)o[n]=0;return o},zero:li});nu.layout.histogram=function(){function t(t,a){for(var u,o,s=[],c=t.map(n,this),l=r.call(this,c,a),h=i.call(this,l,c,a),a=-1,f=c.length,d=h.length-1,p=e?1:1/f;++a0)for(a=-1;++a=l[0]&&o<=l[1]&&(u=s[nu.bisect(h,o,1,d)-1],u.y+=p,u.push(t[a]));return s}var e=!0,n=Number,r=yi,i=pi;return t.value=function(e){return arguments.length?(n=e,t):n},t.range=function(e){return arguments.length?(r=Ct(e),t):r},t.bins=function(e){return arguments.length?(i="number"==typeof e?function(t){return gi(t,e)}:Ct(e),t):i},t.frequency=function(n){return arguments.length?(e=!!n,t):e},t},nu.layout.pack=function(){function t(t,a){var u=n.call(this,t,a),o=u[0],s=i[0],c=i[1],l=null==e?Math.sqrt:"function"==typeof e?e:function(){return e};if(o.x=o.y=0,ei(o,function(t){t.r=+l(t.value)}),ei(o,xi),r){var h=r*(e?1:Math.max(2*o.r/s,2*o.r/c))/2;ei(o,function(t){t.r+=h; -}),ei(o,xi),ei(o,function(t){t.r-=h})}return Ei(o,s/2,c/2,e?1:1/Math.max(2*o.r/s,2*o.r/c)),u}var e,n=nu.layout.hierarchy().sort(mi),r=0,i=[1,1];return t.size=function(e){return arguments.length?(i=e,t):i},t.radius=function(n){return arguments.length?(e=null==n||"function"==typeof n?n:+n,t):e},t.padding=function(e){return arguments.length?(r=+e,t):r},Qr(t,n)},nu.layout.tree=function(){function t(t,i){var l=u.call(this,t,i),h=l[0],f=e(h);if(ei(f,n),f.parent.m=-f.z,ti(f,r),c)ti(h,a);else{var d=h,p=h,g=h;ti(h,function(t){t.xp.x&&(p=t),t.depth>g.depth&&(g=t)});var y=o(d,p)/2-d.x,m=s[0]/(p.x+o(p,d)/2+y),v=s[1]/(g.depth||1);ti(h,function(t){t.x=(t.x+y)*m,t.y=t.depth*v})}return l}function e(t){for(var e,n={A:null,children:[t]},r=[n];null!=(e=r.pop());)for(var i,a=e.children,u=0,o=a.length;o>u;++u)r.push((a[u]=i={_:a[u],parent:e,children:(i=a[u].children)&&i.slice()||[],A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:u}).a=i);return n.children[0]}function n(t){var e=t.children,n=t.parent.children,r=t.i?n[t.i-1]:null;if(e.length){Ti(t);var a=(e[0].z+e[e.length-1].z)/2;r?(t.z=r.z+o(t._,r._),t.m=t.z-a):t.z=a}else r&&(t.z=r.z+o(t._,r._));t.parent.A=i(t,r,t.parent.A||n[0])}function r(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function i(t,e,n){if(e){for(var r,i=t,a=t,u=e,s=i.parent.children[0],c=i.m,l=a.m,h=u.m,f=s.m;u=Mi(u),i=Ci(i),u&&i;)s=Ci(s),a=Mi(a),a.a=t,r=u.z+h-i.z-c+o(u._,i._),r>0&&(Si(Fi(u,t,n),t,r),c+=r,l+=r),h+=u.m,c+=i.m,f+=s.m,l+=a.m;u&&!Mi(a)&&(a.t=u,a.m+=h-l),i&&!Ci(s)&&(s.t=i,s.m+=c-f,n=t)}return n}function a(t){t.x*=s[0],t.y=t.depth*s[1]}var u=nu.layout.hierarchy().sort(null).value(null),o=Di,s=[1,1],c=null;return t.separation=function(e){return arguments.length?(o=e,t):o},t.size=function(e){return arguments.length?(c=null==(s=e)?a:null,t):c?null:s},t.nodeSize=function(e){return arguments.length?(c=null==(s=e)?null:a,t):c?s:null},Qr(t,u)},nu.layout.cluster=function(){function t(t,a){var u,o=e.call(this,t,a),s=o[0],c=0;ei(s,function(t){var e=t.children;e&&e.length?(t.x=Li(e),t.y=Bi(e)):(t.x=u?c+=n(t,u):0,t.y=0,u=t)});var l=Oi(s),h=Ni(s),f=l.x-n(l,h)/2,d=h.x+n(h,l)/2;return ei(s,i?function(t){t.x=(t.x-s.x)*r[0],t.y=(s.y-t.y)*r[1]}:function(t){t.x=(t.x-f)/(d-f)*r[0],t.y=(1-(s.y?t.y/s.y:1))*r[1]}),o}var e=nu.layout.hierarchy().sort(null).value(null),n=Di,r=[1,1],i=!1;return t.separation=function(e){return arguments.length?(n=e,t):n},t.size=function(e){return arguments.length?(i=null==(r=e),t):i?null:r},t.nodeSize=function(e){return arguments.length?(i=null!=(r=e),t):i?r:null},Qr(t,e)},nu.layout.treemap=function(){function t(t,e){for(var n,r,i=-1,a=t.length;++ie?0:e),n.area=isNaN(r)||0>=r?0:r}function e(n){var a=n.children;if(a&&a.length){var u,o,s,c=h(n),l=[],f=a.slice(),p=1/0,g="slice"===d?c.dx:"dice"===d?c.dy:"slice-dice"===d?1&n.depth?c.dy:c.dx:Math.min(c.dx,c.dy);for(t(f,c.dx*c.dy/n.value),l.area=0;(s=f.length)>0;)l.push(u=f[s-1]),l.area+=u.area,"squarify"!==d||(o=r(l,g))<=p?(f.pop(),p=o):(l.area-=l.pop().area,i(l,g,c,!1),g=Math.min(c.dx,c.dy),l.length=l.area=0,p=1/0);l.length&&(i(l,g,c,!0),l.length=l.area=0),a.forEach(e)}}function n(e){var r=e.children;if(r&&r.length){var a,u=h(e),o=r.slice(),s=[];for(t(o,u.dx*u.dy/e.value),s.area=0;a=o.pop();)s.push(a),s.area+=a.area,null!=a.z&&(i(s,a.z?u.dx:u.dy,u,!o.length),s.length=s.area=0);r.forEach(n)}}function r(t,e){for(var n,r=t.area,i=0,a=1/0,u=-1,o=t.length;++un&&(a=n),n>i&&(i=n));return r*=r,e*=e,r?Math.max(e*i*p/r,r/(e*a*p)):1/0}function i(t,e,n,r){var i,a=-1,u=t.length,o=n.x,c=n.y,l=e?s(t.area/e):0;if(e==n.dx){for((r||l>n.dy)&&(l=n.dy);++an.dx)&&(l=n.dx);++an&&(e=1),1>n&&(t=0),function(){var n,r,i;do n=2*Math.random()-1,r=2*Math.random()-1,i=n*n+r*r;while(!i||i>1);return t+e*n*Math.sqrt(-2*Math.log(i)/i)}},logNormal:function(){var t=nu.random.normal.apply(nu,arguments);return function(){return Math.exp(t())}},bates:function(t){var e=nu.random.irwinHall(t);return function(){return e()/t}},irwinHall:function(t){return function(){for(var e=0,n=0;t>n;n++)e+=Math.random();return e}}},nu.scale={};var bs={floor:b,ceil:b};nu.scale.linear=function(){return Vi([0,1],[0,1],br,!1)};var _s={s:1,g:1,p:1,r:1,e:1};nu.scale.log=function(){return Ji(nu.scale.linear().domain([0,1]),10,!0,[1,10])};var xs=nu.format(".0e"),ws={floor:function(t){return-Math.ceil(-t)},ceil:function(t){return-Math.floor(-t)}};nu.scale.pow=function(){return Qi(nu.scale.linear(),1,[0,1])},nu.scale.sqrt=function(){return nu.scale.pow().exponent(.5)},nu.scale.ordinal=function(){return ea([],{t:"range",a:[[]]})},nu.scale.category10=function(){return nu.scale.ordinal().range(As)},nu.scale.category20=function(){return nu.scale.ordinal().range(Es)},nu.scale.category20b=function(){return nu.scale.ordinal().range(ks)},nu.scale.category20c=function(){return nu.scale.ordinal().range(Ds)};var As=[2062260,16744206,2924588,14034728,9725885,9197131,14907330,8355711,12369186,1556175].map(_t),Es=[2062260,11454440,16744206,16759672,2924588,10018698,14034728,16750742,9725885,12955861,9197131,12885140,14907330,16234194,8355711,13092807,12369186,14408589,1556175,10410725].map(_t),ks=[3750777,5395619,7040719,10264286,6519097,9216594,11915115,13556636,9202993,12426809,15186514,15190932,8666169,11356490,14049643,15177372,8077683,10834324,13528509,14589654].map(_t),Ds=[3244733,7057110,10406625,13032431,15095053,16616764,16625259,16634018,3253076,7652470,10607003,13101504,7695281,10394312,12369372,14342891,6513507,9868950,12434877,14277081].map(_t);nu.scale.quantile=function(){return na([],[])},nu.scale.quantize=function(){return ra(0,1,[0,1])},nu.scale.threshold=function(){return ia([.5],[0,1])},nu.scale.identity=function(){return aa([0,1])},nu.svg={},nu.svg.arc=function(){function t(){var t=Math.max(0,+n.apply(this,arguments)),c=Math.max(0,+r.apply(this,arguments)),l=u.apply(this,arguments)-Nu,h=o.apply(this,arguments)-Nu,f=Math.abs(h-l),d=l>h?0:1;if(t>c&&(p=c,c=t,t=p),f>=Ou)return e(c,d)+(t?e(t,1-d):"")+"Z";var p,g,y,m,v,b,_,x,w,A,E,k,D=0,C=0,M=[];if((m=(+s.apply(this,arguments)||0)/2)&&(y=a===Cs?Math.sqrt(t*t+c*c):+a.apply(this,arguments),d||(C*=-1),c&&(C=nt(y/c*Math.sin(m))),t&&(D=nt(y/t*Math.sin(m)))),c){v=c*Math.cos(l+C),b=c*Math.sin(l+C),_=c*Math.cos(h-C),x=c*Math.sin(h-C);var S=Math.abs(h-l-2*C)<=Bu?0:1;if(C&&fa(v,b,_,x)===d^S){var T=(l+h)/2;v=c*Math.cos(T),b=c*Math.sin(T),_=x=null}}else v=b=0;if(t){w=t*Math.cos(h-D),A=t*Math.sin(h-D),E=t*Math.cos(l+D),k=t*Math.sin(l+D);var F=Math.abs(l-h+2*D)<=Bu?0:1;if(D&&fa(w,A,E,k)===1-d^F){var B=(l+h)/2;w=t*Math.cos(B),A=t*Math.sin(B),E=k=null}}else w=A=0;if((p=Math.min(Math.abs(c-t)/2,+i.apply(this,arguments)))>.001){g=c>t^d?0:1;var L=null==E?[w,A]:null==_?[v,b]:On([v,b],[E,k],[_,x],[w,A]),O=v-L[0],N=b-L[1],I=_-L[0],P=x-L[1],R=1/Math.sin(Math.acos((O*I+N*P)/(Math.sqrt(O*O+N*N)*Math.sqrt(I*I+P*P)))/2),q=Math.sqrt(L[0]*L[0]+L[1]*L[1]);if(null!=_){var j=Math.min(p,(c-q)/(R+1)),U=da(null==E?[w,A]:[E,k],[v,b],c,j,d),Y=da([_,x],[w,A],c,j,d);p===j?M.push("M",U[0],"A",j,",",j," 0 0,",g," ",U[1],"A",c,",",c," 0 ",1-d^fa(U[1][0],U[1][1],Y[1][0],Y[1][1]),",",d," ",Y[1],"A",j,",",j," 0 0,",g," ",Y[0]):M.push("M",U[0],"A",j,",",j," 0 1,",g," ",Y[0])}else M.push("M",v,",",b);if(null!=E){var z=Math.min(p,(t-q)/(R-1)),V=da([v,b],[E,k],t,-z,d),$=da([w,A],null==_?[v,b]:[_,x],t,-z,d);p===z?M.push("L",$[0],"A",z,",",z," 0 0,",g," ",$[1],"A",t,",",t," 0 ",d^fa($[1][0],$[1][1],V[1][0],V[1][1]),",",1-d," ",V[1],"A",z,",",z," 0 0,",g," ",V[0]):M.push("L",$[0],"A",z,",",z," 0 0,",g," ",V[0])}else M.push("L",w,",",A)}else M.push("M",v,",",b),null!=_&&M.push("A",c,",",c," 0 ",S,",",d," ",_,",",x),M.push("L",w,",",A),null!=E&&M.push("A",t,",",t," 0 ",F,",",1-d," ",E,",",k);return M.push("Z"),M.join("")}function e(t,e){return"M0,"+t+"A"+t+","+t+" 0 1,"+e+" 0,"+-t+"A"+t+","+t+" 0 1,"+e+" 0,"+t}var n=oa,r=sa,i=ua,a=Cs,u=ca,o=la,s=ha;return t.innerRadius=function(e){return arguments.length?(n=Ct(e),t):n},t.outerRadius=function(e){return arguments.length?(r=Ct(e),t):r},t.cornerRadius=function(e){return arguments.length?(i=Ct(e),t):i},t.padRadius=function(e){return arguments.length?(a=e==Cs?Cs:Ct(e),t):a},t.startAngle=function(e){return arguments.length?(u=Ct(e),t):u},t.endAngle=function(e){return arguments.length?(o=Ct(e),t):o},t.padAngle=function(e){return arguments.length?(s=Ct(e),t):s},t.centroid=function(){var t=(+n.apply(this,arguments)+ +r.apply(this,arguments))/2,e=(+u.apply(this,arguments)+ +o.apply(this,arguments))/2-Nu;return[Math.cos(e)*t,Math.sin(e)*t]},t};var Cs="auto";nu.svg.line=function(){return pa(b)};var Ms=nu.map({linear:ga,"linear-closed":ya,step:ma,"step-before":va,"step-after":ba,basis:ka,"basis-open":Da,"basis-closed":Ca,bundle:Ma,cardinal:wa,"cardinal-open":_a,"cardinal-closed":xa,monotone:Oa});Ms.forEach(function(t,e){e.key=t,e.closed=/-closed$/.test(t)});var Ss=[0,2/3,1/3,0],Ts=[0,1/3,2/3,0],Fs=[0,1/6,2/3,1/6];nu.svg.line.radial=function(){var t=pa(Na);return t.radius=t.x,delete t.x,t.angle=t.y,delete t.y,t},va.reverse=ba,ba.reverse=va,nu.svg.area=function(){return Ia(b)},nu.svg.area.radial=function(){var t=Ia(Na);return t.radius=t.x,delete t.x,t.innerRadius=t.x0,delete t.x0,t.outerRadius=t.x1,delete t.x1,t.angle=t.y,delete t.y,t.startAngle=t.y0,delete t.y0,t.endAngle=t.y1,delete t.y1,t},nu.svg.chord=function(){function t(t,o){var s=e(this,a,t,o),c=e(this,u,t,o);return"M"+s.p0+r(s.r,s.p1,s.a1-s.a0)+(n(s,c)?i(s.r,s.p1,s.r,s.p0):i(s.r,s.p1,c.r,c.p0)+r(c.r,c.p1,c.a1-c.a0)+i(c.r,c.p1,s.r,s.p0))+"Z"}function e(t,e,n,r){var i=e.call(t,n,r),a=o.call(t,i,r),u=s.call(t,i,r)-Nu,l=c.call(t,i,r)-Nu;return{r:a,a0:u,a1:l,p0:[a*Math.cos(u),a*Math.sin(u)],p1:[a*Math.cos(l),a*Math.sin(l)]}}function n(t,e){return t.a0==e.a0&&t.a1==e.a1}function r(t,e,n){return"A"+t+","+t+" 0 "+ +(n>Bu)+",1 "+e}function i(t,e,n,r){return"Q 0,0 "+r}var a=bn,u=_n,o=Pa,s=ca,c=la;return t.radius=function(e){return arguments.length?(o=Ct(e),t):o},t.source=function(e){return arguments.length?(a=Ct(e),t):a},t.target=function(e){return arguments.length?(u=Ct(e),t):u},t.startAngle=function(e){return arguments.length?(s=Ct(e),t):s},t.endAngle=function(e){return arguments.length?(c=Ct(e),t):c},t},nu.svg.diagonal=function(){function t(t,i){var a=e.call(this,t,i),u=n.call(this,t,i),o=(a.y+u.y)/2,s=[a,{x:a.x,y:o},{x:u.x,y:o},u];return s=s.map(r),"M"+s[0]+"C"+s[1]+" "+s[2]+" "+s[3]}var e=bn,n=_n,r=Ra;return t.source=function(n){return arguments.length?(e=Ct(n),t):e},t.target=function(e){return arguments.length?(n=Ct(e),t):n},t.projection=function(e){return arguments.length?(r=e,t):r},t},nu.svg.diagonal.radial=function(){var t=nu.svg.diagonal(),e=Ra,n=t.projection;return t.projection=function(t){return arguments.length?n(qa(e=t)):e},t},nu.svg.symbol=function(){function t(t,r){return(Bs.get(e.call(this,t,r))||Ya)(n.call(this,t,r))}var e=Ua,n=ja;return t.type=function(n){return arguments.length?(e=Ct(n),t):e},t.size=function(e){return arguments.length?(n=Ct(e),t):n},t};var Bs=nu.map({circle:Ya,cross:function(t){var e=Math.sqrt(t/5)/2;return"M"+-3*e+","+-e+"H"+-e+"V"+-3*e+"H"+e+"V"+-e+"H"+3*e+"V"+e+"H"+e+"V"+3*e+"H"+-e+"V"+e+"H"+-3*e+"Z"},diamond:function(t){var e=Math.sqrt(t/(2*Os)),n=e*Os;return"M0,"+-e+"L"+n+",0 0,"+e+" "+-n+",0Z"},square:function(t){var e=Math.sqrt(t)/2;return"M"+-e+","+-e+"L"+e+","+-e+" "+e+","+e+" "+-e+","+e+"Z"},"triangle-down":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+n+"L"+e+","+-n+" "+-e+","+-n+"Z"},"triangle-up":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+-n+"L"+e+","+n+" "+-e+","+n+"Z"}});nu.svg.symbolTypes=Bs.keys();var Ls=Math.sqrt(3),Os=Math.tan(30*Iu);Au.transition=function(t){for(var e,n,r=Ns||++qs,i=Ha(t),a=[],u=Is||{time:Date.now(),ease:Dr,delay:0,duration:250},o=-1,s=this.length;++oa;a++){i.push(e=[]);for(var n=this[a],o=0,s=n.length;s>o;o++)(r=n[o])&&t.call(r,r.__data__,o,a)&&e.push(r)}return Va(i,this.namespace,this.id)},Rs.tween=function(t,e){var n=this.id,r=this.namespace;return arguments.length<2?this.node()[r][n].tween.get(t):V(this,null==e?function(e){e[r][n].tween.remove(t)}:function(i){i[r][n].tween.set(t,e)})},Rs.attr=function(t,e){function n(){this.removeAttribute(o)}function r(){this.removeAttributeNS(o.space,o.local)}function i(t){return null==t?n:(t+="",function(){var e,n=this.getAttribute(o);return n!==t&&(e=u(n,t),function(t){this.setAttribute(o,e(t))})})}function a(t){return null==t?r:(t+="",function(){var e,n=this.getAttributeNS(o.space,o.local);return n!==t&&(e=u(n,t),function(t){this.setAttributeNS(o.space,o.local,e(t))})})}if(arguments.length<2){for(e in t)this.attr(e,t[e]);return this}var u="transform"==t?Yr:br,o=nu.ns.qualify(t);return $a(this,"attr."+t,e,o.local?a:i)},Rs.attrTween=function(t,e){function n(t,n){var r=e.call(this,t,n,this.getAttribute(i));return r&&function(t){this.setAttribute(i,r(t))}}function r(t,n){var r=e.call(this,t,n,this.getAttributeNS(i.space,i.local));return r&&function(t){this.setAttributeNS(i.space,i.local,r(t))}}var i=nu.ns.qualify(t);return this.tween("attr."+t,i.local?r:n)},Rs.style=function(t,e,r){function i(){this.style.removeProperty(t)}function a(e){return null==e?i:(e+="",function(){var i,a=n(this).getComputedStyle(this,null).getPropertyValue(t);return a!==e&&(i=br(a,e),function(e){this.style.setProperty(t,i(e),r)})})}var u=arguments.length;if(3>u){if("string"!=typeof t){2>u&&(e="");for(r in t)this.style(r,t[r],e);return this}r=""}return $a(this,"style."+t,e,a)},Rs.styleTween=function(t,e,r){function i(i,a){var u=e.call(this,i,a,n(this).getComputedStyle(this,null).getPropertyValue(t));return u&&function(e){this.style.setProperty(t,u(e),r)}}return arguments.length<3&&(r=""),this.tween("style."+t,i)},Rs.text=function(t){return $a(this,"text",t,Ga)},Rs.remove=function(){var t=this.namespace;return this.each("end.transition",function(){var e;this[t].count<2&&(e=this.parentNode)&&e.removeChild(this)})},Rs.ease=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].ease:("function"!=typeof t&&(t=nu.ease.apply(nu,arguments)),V(this,function(r){r[n][e].ease=t}))},Rs.delay=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].delay:V(this,"function"==typeof t?function(r,i,a){r[n][e].delay=+t.call(r,r.__data__,i,a)}:(t=+t,function(r){r[n][e].delay=t}))},Rs.duration=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].duration:V(this,"function"==typeof t?function(r,i,a){r[n][e].duration=Math.max(1,t.call(r,r.__data__,i,a))}:(t=Math.max(1,t),function(r){r[n][e].duration=t}))},Rs.each=function(t,e){var n=this.id,r=this.namespace;if(arguments.length<2){var i=Is,a=Ns;try{Ns=n,V(this,function(e,i,a){Is=e[r][n],t.call(e,e.__data__,i,a)})}finally{Is=i,Ns=a}}else V(this,function(i){var a=i[r][n];(a.event||(a.event=nu.dispatch("start","end","interrupt"))).on(t,e)});return this},Rs.transition=function(){for(var t,e,n,r,i=this.id,a=++qs,u=this.namespace,o=[],s=0,c=this.length;c>s;s++){o.push(t=[]);for(var e=this[s],l=0,h=e.length;h>l;l++)(n=e[l])&&(r=n[u][i],Wa(n,l,u,a,{time:r.time,ease:r.ease,delay:r.delay+r.duration,duration:r.duration})),t.push(n)}return Va(o,u,a)},nu.svg.axis=function(){function t(t){t.each(function(){var t,c=nu.select(this),l=this.__chart__||n,h=this.__chart__=n.copy(),f=null==s?h.ticks?h.ticks.apply(h,o):h.domain():s,d=null==e?h.tickFormat?h.tickFormat.apply(h,o):b:e,p=c.selectAll(".tick").data(f,h),g=p.enter().insert("g",".domain").attr("class","tick").style("opacity",Tu),y=nu.transition(p.exit()).style("opacity",Tu).remove(),m=nu.transition(p.order()).style("opacity",1),v=Math.max(i,0)+u,_=qi(h),x=c.selectAll(".domain").data([0]),w=(x.enter().append("path").attr("class","domain"),nu.transition(x));g.append("line"),g.append("text");var A,E,k,D,C=g.select("line"),M=m.select("line"),S=p.select("text").text(d),T=g.select("text"),F=m.select("text"),B="top"===r||"left"===r?-1:1;if("bottom"===r||"top"===r?(t=Za,A="x",k="y",E="x2",D="y2",S.attr("dy",0>B?"0em":".71em").style("text-anchor","middle"),w.attr("d","M"+_[0]+","+B*a+"V0H"+_[1]+"V"+B*a)):(t=Xa,A="y",k="x",E="y2",D="x2",S.attr("dy",".32em").style("text-anchor",0>B?"end":"start"),w.attr("d","M"+B*a+","+_[0]+"H0V"+_[1]+"H"+B*a)),C.attr(D,B*i),T.attr(k,B*v),M.attr(E,0).attr(D,B*i),F.attr(A,0).attr(k,B*v),h.rangeBand){var L=h,O=L.rangeBand()/2;l=h=function(t){return L(t)+O}}else l.rangeBand?l=h:y.call(t,h,l);g.call(t,l,h),m.call(t,h,h)})}var e,n=nu.scale.linear(),r=js,i=6,a=6,u=3,o=[10],s=null;return t.scale=function(e){return arguments.length?(n=e,t):n},t.orient=function(e){return arguments.length?(r=e in Us?e+"":js,t):r},t.ticks=function(){return arguments.length?(o=arguments,t):o},t.tickValues=function(e){return arguments.length?(s=e,t):s},t.tickFormat=function(n){return arguments.length?(e=n,t):e},t.tickSize=function(e){var n=arguments.length;return n?(i=+e,a=+arguments[n-1],t):i},t.innerTickSize=function(e){return arguments.length?(i=+e,t):i},t.outerTickSize=function(e){return arguments.length?(a=+e,t):a},t.tickPadding=function(e){return arguments.length?(u=+e,t):u},t.tickSubdivide=function(){return arguments.length&&t},t};var js="bottom",Us={top:1,right:1,bottom:1,left:1};nu.svg.brush=function(){function t(n){n.each(function(){var n=nu.select(this).style("pointer-events","all").style("-webkit-tap-highlight-color","rgba(0,0,0,0)").on("mousedown.brush",a).on("touchstart.brush",a),u=n.selectAll(".background").data([0]);u.enter().append("rect").attr("class","background").style("visibility","hidden").style("cursor","crosshair"),n.selectAll(".extent").data([0]).enter().append("rect").attr("class","extent").style("cursor","move");var o=n.selectAll(".resize").data(g,b);o.exit().remove(),o.enter().append("g").attr("class",function(t){return"resize "+t}).style("cursor",function(t){return Ys[t]}).append("rect").attr("x",function(t){return/[ew]$/.test(t)?-3:null}).attr("y",function(t){return/^[ns]/.test(t)?-3:null}).attr("width",6).attr("height",6).style("visibility","hidden"),o.style("display",t.empty()?"none":null);var s,h=nu.transition(n),f=nu.transition(u);c&&(s=qi(c),f.attr("x",s[0]).attr("width",s[1]-s[0]),r(h)),l&&(s=qi(l),f.attr("y",s[0]).attr("height",s[1]-s[0]),i(h)),e(h)})}function e(t){t.selectAll(".resize").attr("transform",function(t){return"translate("+h[+/e$/.test(t)]+","+f[+/^s/.test(t)]+")"})}function r(t){t.select(".extent").attr("x",h[0]),t.selectAll(".extent,.n>rect,.s>rect").attr("width",h[1]-h[0])}function i(t){t.select(".extent").attr("y",f[0]),t.selectAll(".extent,.e>rect,.w>rect").attr("height",f[1]-f[0])}function a(){function a(){32==nu.event.keyCode&&(S||(b=null,F[0]-=h[1],F[1]-=f[1],S=2),k())}function g(){32==nu.event.keyCode&&2==S&&(F[0]+=h[1],F[1]+=f[1],S=0,k())}function y(){var t=nu.mouse(x),n=!1;_&&(t[0]+=_[0],t[1]+=_[1]),S||(nu.event.altKey?(b||(b=[(h[0]+h[1])/2,(f[0]+f[1])/2]),F[0]=h[+(t[0]l?(i=r,r=l):i=l),g[0]!=r||g[1]!=i?(n?o=null:u=null,g[0]=r,g[1]=i,!0):void 0}function v(){y(),E.style("pointer-events","all").selectAll(".resize").style("display",t.empty()?"none":null),nu.select("body").style("cursor",null),B.on("mousemove.brush",null).on("mouseup.brush",null).on("touchmove.brush",null).on("touchend.brush",null).on("keydown.brush",null).on("keyup.brush",null),T(),A({type:"brushend"})}var b,_,x=this,w=nu.select(nu.event.target),A=s.of(x,arguments),E=nu.select(x),D=w.datum(),C=!/^(n|s)$/.test(D)&&c,M=!/^(e|w)$/.test(D)&&l,S=w.classed("extent"),T=X(x),F=nu.mouse(x),B=nu.select(n(x)).on("keydown.brush",a).on("keyup.brush",g);if(nu.event.changedTouches?B.on("touchmove.brush",y).on("touchend.brush",v):B.on("mousemove.brush",y).on("mouseup.brush",v),E.interrupt().selectAll("*").interrupt(),S)F[0]=h[0]-F[0],F[1]=f[0]-F[1];else if(D){var L=+/w$/.test(D),O=+/^n/.test(D);_=[h[1-L]-F[0],f[1-O]-F[1]],F[0]=h[L],F[1]=f[O]}else nu.event.altKey&&(b=F.slice());E.style("pointer-events","none").selectAll(".resize").style("display",null),nu.select("body").style("cursor",w.style("cursor")),A({type:"brushstart"}),y()}var u,o,s=C(t,"brushstart","brush","brushend"),c=null,l=null,h=[0,0],f=[0,0],d=!0,p=!0,g=zs[0];return t.event=function(t){t.each(function(){var t=s.of(this,arguments),e={x:h,y:f,i:u,j:o},n=this.__chart__||e;this.__chart__=e,Ns?nu.select(this).transition().each("start.brush",function(){u=n.i,o=n.j,h=n.x,f=n.y,t({type:"brushstart"})}).tween("brush:brush",function(){var n=_r(h,e.x),r=_r(f,e.y);return u=o=null,function(i){h=e.x=n(i),f=e.y=r(i),t({type:"brush",mode:"resize"})}}).each("end.brush",function(){u=e.i,o=e.j,t({type:"brush",mode:"resize"}),t({type:"brushend"})}):(t({type:"brushstart"}),t({type:"brush",mode:"resize"}),t({type:"brushend"}))})},t.x=function(e){return arguments.length?(c=e,g=zs[!c<<1|!l],t):c},t.y=function(e){return arguments.length?(l=e,g=zs[!c<<1|!l],t):l},t.clamp=function(e){return arguments.length?(c&&l?(d=!!e[0],p=!!e[1]):c?d=!!e:l&&(p=!!e),t):c&&l?[d,p]:c?d:l?p:null},t.extent=function(e){var n,r,i,a,s;return arguments.length?(c&&(n=e[0],r=e[1],l&&(n=n[0],r=r[0]),u=[n,r],c.invert&&(n=c(n),r=c(r)),n>r&&(s=n,n=r,r=s),(n!=h[0]||r!=h[1])&&(h=[n,r])),l&&(i=e[0],a=e[1],c&&(i=i[1],a=a[1]),o=[i,a],l.invert&&(i=l(i),a=l(a)),i>a&&(s=i,i=a,a=s),(i!=f[0]||a!=f[1])&&(f=[i,a])),t):(c&&(u?(n=u[0],r=u[1]):(n=h[0],r=h[1],c.invert&&(n=c.invert(n),r=c.invert(r)),n>r&&(s=n,n=r,r=s))),l&&(o?(i=o[0],a=o[1]):(i=f[0],a=f[1],l.invert&&(i=l.invert(i),a=l.invert(a)),i>a&&(s=i,i=a,a=s))),c&&l?[[n,i],[r,a]]:c?[n,r]:l&&[i,a])},t.clear=function(){return t.empty()||(h=[0,0],f=[0,0],u=o=null),t},t.empty=function(){return!!c&&h[0]==h[1]||!!l&&f[0]==f[1]},nu.rebind(t,s,"on")};var Ys={n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},zs=[["n","e","s","w","nw","ne","se","sw"],["e","w"],["n","s"],[]],Vs=so.format=go.timeFormat,$s=Vs.utc,Gs=$s("%Y-%m-%dT%H:%M:%S.%LZ");Vs.iso=Date.prototype.toISOString&&+new Date("2000-01-01T00:00:00.000Z")?Ka:Gs,Ka.parse=function(t){var e=new Date(t);return isNaN(e)?null:e},Ka.toString=Gs.toString,so.second=jt(function(t){return new co(1e3*Math.floor(t/1e3))},function(t,e){t.setTime(t.getTime()+1e3*Math.floor(e))},function(t){return t.getSeconds()}),so.seconds=so.second.range,so.seconds.utc=so.second.utc.range,so.minute=jt(function(t){return new co(6e4*Math.floor(t/6e4))},function(t,e){t.setTime(t.getTime()+6e4*Math.floor(e))},function(t){return t.getMinutes()}),so.minutes=so.minute.range,so.minutes.utc=so.minute.utc.range,so.hour=jt(function(t){var e=t.getTimezoneOffset()/60;return new co(36e5*(Math.floor(t/36e5-e)+e))},function(t,e){t.setTime(t.getTime()+36e5*Math.floor(e))},function(t){return t.getHours()}),so.hours=so.hour.range,so.hours.utc=so.hour.utc.range,so.month=jt(function(t){return t=so.day(t),t.setDate(1),t},function(t,e){t.setMonth(t.getMonth()+e)},function(t){return t.getMonth()}),so.months=so.month.range,so.months.utc=so.month.utc.range;var Hs=[1e3,5e3,15e3,3e4,6e4,3e5,9e5,18e5,36e5,108e5,216e5,432e5,864e5,1728e5,6048e5,2592e6,7776e6,31536e6],Ws=[[so.second,1],[so.second,5],[so.second,15],[so.second,30],[so.minute,1],[so.minute,5],[so.minute,15],[so.minute,30],[so.hour,1],[so.hour,3],[so.hour,6],[so.hour,12],[so.day,1],[so.day,2],[so.week,1],[so.month,1],[so.month,3],[so.year,1]],Zs=Vs.multi([[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["%I:%M",function(t){return t.getMinutes()}],["%I %p",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}],["%Y",Se]]),Xs={range:function(t,e,n){return nu.range(Math.ceil(t/n)*n,+e,n).map(Qa)},floor:b,ceil:b};Ws.year=so.year,so.scale=function(){return Ja(nu.scale.linear(),Ws,Zs)};var Ks=Ws.map(function(t){return[t[0].utc,t[1]]}),Js=$s.multi([[".%L",function(t){return t.getUTCMilliseconds()}],[":%S",function(t){return t.getUTCSeconds()}],["%I:%M",function(t){return t.getUTCMinutes()}],["%I %p",function(t){return t.getUTCHours()}],["%a %d",function(t){return t.getUTCDay()&&1!=t.getUTCDate()}],["%b %d",function(t){return 1!=t.getUTCDate()}],["%B",function(t){return t.getUTCMonth()}],["%Y",Se]]);Ks.year=so.year.utc,so.scale.utc=function(){return Ja(nu.scale.linear(),Ks,Js)},nu.text=Mt(function(t){return t.responseText}),nu.json=function(t,e){return St(t,"application/json",tu,e)},nu.html=function(t,e){return St(t,"text/html",eu,e)},nu.xml=Mt(function(t){return t.responseXML}),"function"==typeof define&&define.amd?define(nu):"object"==typeof e&&e.exports&&(e.exports=nu),this.d3=nu}()},{}],5:[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":12,"./lib/graphlib":13,"./lib/intersect":14,"./lib/render":29,"./lib/util":31,"./lib/version":32}],6:[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"),u=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(u,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"),u=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(u,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"),u=i.append("path").attr("d","M 0 5 L 10 5").style("stroke-width",1).style("stroke-dasharray","1,0");a.applyStyle(u,n[r+"Style"])}var a=t("./util");e.exports={"default":n,normal:n,vee:r,undirected:i}},{"./util":31}],7:[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":22,"./util":31}],8:[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(u.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"),u=t("./d3");e.exports=n},{"./d3":11,"./label/add-label":22,"./lodash":25,"./util":31}],9:[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 u(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=s.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,"arrowhead")}),i}function r(t,e){var n=t.edge(e),r=t.node(e.v),a=t.node(e.w),u=n.points.slice(1,n.points.length-1);return u.unshift(c(r,u[0])),u.push(c(a,u[u.length-1])),i(n,u)}function i(t,e){var n=h.svg.line().x(function(t){return t.x}).y(function(t){return t.y});return s.has(t,"lineInterpolate")&&n.interpolate(t.lineInterpolate),s.has(t,"lineTension")&&n.tension(Number(t.lineTension)),n(e)}function a(t){var e=t.getBBox(),n=t.getTransformToElement(t.ownerSVGElement).translate(e.width/2,e.height/2);return{x:n.e,y:n.f}}function u(t,e){var n=t.enter().append("g").attr("class","edgePath").style("opacity",0);n.append("path").attr("class","path").attr("d",function(t){var n=e.edge(t),r=e.node(t.v).elem,u=s.range(n.points.length).map(function(){return a(r)});return i(n,u)}),n.append("defs")}function o(t,e){var n=t.exit();l.applyTransition(n,e).style("opacity",0).remove(),l.applyTransition(n.select("path.path"),e).attr("d",function(t){var n=e.node(t.v);if(n){var r=s.range(this.pathSegList.length).map(function(){return n});return i({},r)}return h.select(this).attr("d")})}var s=t("./lodash"),c=t("./intersect/intersect-node"),l=t("./util"),h=t("./d3");e.exports=n},{"./d3":11,"./intersect/intersect-node":18,"./lodash":25,"./util":31}],10:[function(t,e){"use strict"; +}),ei(o,xi),ei(o,function(t){t.r-=h})}return Ei(o,s/2,c/2,e?1:1/Math.max(2*o.r/s,2*o.r/c)),u}var e,n=nu.layout.hierarchy().sort(mi),r=0,i=[1,1];return t.size=function(e){return arguments.length?(i=e,t):i},t.radius=function(n){return arguments.length?(e=null==n||"function"==typeof n?n:+n,t):e},t.padding=function(e){return arguments.length?(r=+e,t):r},Qr(t,n)},nu.layout.tree=function(){function t(t,i){var l=u.call(this,t,i),h=l[0],f=e(h);if(ei(f,n),f.parent.m=-f.z,ti(f,r),c)ti(h,a);else{var d=h,p=h,g=h;ti(h,function(t){t.xp.x&&(p=t),t.depth>g.depth&&(g=t)});var y=o(d,p)/2-d.x,m=s[0]/(p.x+o(p,d)/2+y),v=s[1]/(g.depth||1);ti(h,function(t){t.x=(t.x+y)*m,t.y=t.depth*v})}return l}function e(t){for(var e,n={A:null,children:[t]},r=[n];null!=(e=r.pop());)for(var i,a=e.children,u=0,o=a.length;o>u;++u)r.push((a[u]=i={_:a[u],parent:e,children:(i=a[u].children)&&i.slice()||[],A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:u}).a=i);return n.children[0]}function n(t){var e=t.children,n=t.parent.children,r=t.i?n[t.i-1]:null;if(e.length){Ti(t);var a=(e[0].z+e[e.length-1].z)/2;r?(t.z=r.z+o(t._,r._),t.m=t.z-a):t.z=a}else r&&(t.z=r.z+o(t._,r._));t.parent.A=i(t,r,t.parent.A||n[0])}function r(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function i(t,e,n){if(e){for(var r,i=t,a=t,u=e,s=i.parent.children[0],c=i.m,l=a.m,h=u.m,f=s.m;u=Mi(u),i=Ci(i),u&&i;)s=Ci(s),a=Mi(a),a.a=t,r=u.z+h-i.z-c+o(u._,i._),r>0&&(Si(Fi(u,t,n),t,r),c+=r,l+=r),h+=u.m,c+=i.m,f+=s.m,l+=a.m;u&&!Mi(a)&&(a.t=u,a.m+=h-l),i&&!Ci(s)&&(s.t=i,s.m+=c-f,n=t)}return n}function a(t){t.x*=s[0],t.y=t.depth*s[1]}var u=nu.layout.hierarchy().sort(null).value(null),o=Di,s=[1,1],c=null;return t.separation=function(e){return arguments.length?(o=e,t):o},t.size=function(e){return arguments.length?(c=null==(s=e)?a:null,t):c?null:s},t.nodeSize=function(e){return arguments.length?(c=null==(s=e)?null:a,t):c?s:null},Qr(t,u)},nu.layout.cluster=function(){function t(t,a){var u,o=e.call(this,t,a),s=o[0],c=0;ei(s,function(t){var e=t.children;e&&e.length?(t.x=Li(e),t.y=Bi(e)):(t.x=u?c+=n(t,u):0,t.y=0,u=t)});var l=Ni(s),h=Oi(s),f=l.x-n(l,h)/2,d=h.x+n(h,l)/2;return ei(s,i?function(t){t.x=(t.x-s.x)*r[0],t.y=(s.y-t.y)*r[1]}:function(t){t.x=(t.x-f)/(d-f)*r[0],t.y=(1-(s.y?t.y/s.y:1))*r[1]}),o}var e=nu.layout.hierarchy().sort(null).value(null),n=Di,r=[1,1],i=!1;return t.separation=function(e){return arguments.length?(n=e,t):n},t.size=function(e){return arguments.length?(i=null==(r=e),t):i?null:r},t.nodeSize=function(e){return arguments.length?(i=null!=(r=e),t):i?r:null},Qr(t,e)},nu.layout.treemap=function(){function t(t,e){for(var n,r,i=-1,a=t.length;++ie?0:e),n.area=isNaN(r)||0>=r?0:r}function e(n){var a=n.children;if(a&&a.length){var u,o,s,c=h(n),l=[],f=a.slice(),p=1/0,g="slice"===d?c.dx:"dice"===d?c.dy:"slice-dice"===d?1&n.depth?c.dy:c.dx:Math.min(c.dx,c.dy);for(t(f,c.dx*c.dy/n.value),l.area=0;(s=f.length)>0;)l.push(u=f[s-1]),l.area+=u.area,"squarify"!==d||(o=r(l,g))<=p?(f.pop(),p=o):(l.area-=l.pop().area,i(l,g,c,!1),g=Math.min(c.dx,c.dy),l.length=l.area=0,p=1/0);l.length&&(i(l,g,c,!0),l.length=l.area=0),a.forEach(e)}}function n(e){var r=e.children;if(r&&r.length){var a,u=h(e),o=r.slice(),s=[];for(t(o,u.dx*u.dy/e.value),s.area=0;a=o.pop();)s.push(a),s.area+=a.area,null!=a.z&&(i(s,a.z?u.dx:u.dy,u,!o.length),s.length=s.area=0);r.forEach(n)}}function r(t,e){for(var n,r=t.area,i=0,a=1/0,u=-1,o=t.length;++un&&(a=n),n>i&&(i=n));return r*=r,e*=e,r?Math.max(e*i*p/r,r/(e*a*p)):1/0}function i(t,e,n,r){var i,a=-1,u=t.length,o=n.x,c=n.y,l=e?s(t.area/e):0;if(e==n.dx){for((r||l>n.dy)&&(l=n.dy);++an.dx)&&(l=n.dx);++an&&(e=1),1>n&&(t=0),function(){var n,r,i;do n=2*Math.random()-1,r=2*Math.random()-1,i=n*n+r*r;while(!i||i>1);return t+e*n*Math.sqrt(-2*Math.log(i)/i)}},logNormal:function(){var t=nu.random.normal.apply(nu,arguments);return function(){return Math.exp(t())}},bates:function(t){var e=nu.random.irwinHall(t);return function(){return e()/t}},irwinHall:function(t){return function(){for(var e=0,n=0;t>n;n++)e+=Math.random();return e}}},nu.scale={};var bs={floor:b,ceil:b};nu.scale.linear=function(){return Vi([0,1],[0,1],br,!1)};var _s={s:1,g:1,p:1,r:1,e:1};nu.scale.log=function(){return Ki(nu.scale.linear().domain([0,1]),10,!0,[1,10])};var xs=nu.format(".0e"),ws={floor:function(t){return-Math.ceil(-t)},ceil:function(t){return-Math.floor(-t)}};nu.scale.pow=function(){return Qi(nu.scale.linear(),1,[0,1])},nu.scale.sqrt=function(){return nu.scale.pow().exponent(.5)},nu.scale.ordinal=function(){return ea([],{t:"range",a:[[]]})},nu.scale.category10=function(){return nu.scale.ordinal().range(As)},nu.scale.category20=function(){return nu.scale.ordinal().range(Es)},nu.scale.category20b=function(){return nu.scale.ordinal().range(ks)},nu.scale.category20c=function(){return nu.scale.ordinal().range(Ds)};var As=[2062260,16744206,2924588,14034728,9725885,9197131,14907330,8355711,12369186,1556175].map(_t),Es=[2062260,11454440,16744206,16759672,2924588,10018698,14034728,16750742,9725885,12955861,9197131,12885140,14907330,16234194,8355711,13092807,12369186,14408589,1556175,10410725].map(_t),ks=[3750777,5395619,7040719,10264286,6519097,9216594,11915115,13556636,9202993,12426809,15186514,15190932,8666169,11356490,14049643,15177372,8077683,10834324,13528509,14589654].map(_t),Ds=[3244733,7057110,10406625,13032431,15095053,16616764,16625259,16634018,3253076,7652470,10607003,13101504,7695281,10394312,12369372,14342891,6513507,9868950,12434877,14277081].map(_t);nu.scale.quantile=function(){return na([],[])},nu.scale.quantize=function(){return ra(0,1,[0,1])},nu.scale.threshold=function(){return ia([.5],[0,1])},nu.scale.identity=function(){return aa([0,1])},nu.svg={},nu.svg.arc=function(){function t(){var t=Math.max(0,+n.apply(this,arguments)),c=Math.max(0,+r.apply(this,arguments)),l=u.apply(this,arguments)-Ou,h=o.apply(this,arguments)-Ou,f=Math.abs(h-l),d=l>h?0:1;if(t>c&&(p=c,c=t,t=p),f>=Nu)return e(c,d)+(t?e(t,1-d):"")+"Z";var p,g,y,m,v,b,_,x,w,A,E,k,D=0,C=0,M=[];if((m=(+s.apply(this,arguments)||0)/2)&&(y=a===Cs?Math.sqrt(t*t+c*c):+a.apply(this,arguments),d||(C*=-1),c&&(C=nt(y/c*Math.sin(m))),t&&(D=nt(y/t*Math.sin(m)))),c){v=c*Math.cos(l+C),b=c*Math.sin(l+C),_=c*Math.cos(h-C),x=c*Math.sin(h-C);var S=Math.abs(h-l-2*C)<=Bu?0:1;if(C&&fa(v,b,_,x)===d^S){var T=(l+h)/2;v=c*Math.cos(T),b=c*Math.sin(T),_=x=null}}else v=b=0;if(t){w=t*Math.cos(h-D),A=t*Math.sin(h-D),E=t*Math.cos(l+D),k=t*Math.sin(l+D);var F=Math.abs(l-h+2*D)<=Bu?0:1;if(D&&fa(w,A,E,k)===1-d^F){var B=(l+h)/2;w=t*Math.cos(B),A=t*Math.sin(B),E=k=null}}else w=A=0;if((p=Math.min(Math.abs(c-t)/2,+i.apply(this,arguments)))>.001){g=c>t^d?0:1;var L=null==E?[w,A]:null==_?[v,b]:Nn([v,b],[E,k],[_,x],[w,A]),N=v-L[0],O=b-L[1],I=_-L[0],R=x-L[1],P=1/Math.sin(Math.acos((N*I+O*R)/(Math.sqrt(N*N+O*O)*Math.sqrt(I*I+R*R)))/2),q=Math.sqrt(L[0]*L[0]+L[1]*L[1]);if(null!=_){var j=Math.min(p,(c-q)/(P+1)),U=da(null==E?[w,A]:[E,k],[v,b],c,j,d),Y=da([_,x],[w,A],c,j,d);p===j?M.push("M",U[0],"A",j,",",j," 0 0,",g," ",U[1],"A",c,",",c," 0 ",1-d^fa(U[1][0],U[1][1],Y[1][0],Y[1][1]),",",d," ",Y[1],"A",j,",",j," 0 0,",g," ",Y[0]):M.push("M",U[0],"A",j,",",j," 0 1,",g," ",Y[0])}else M.push("M",v,",",b);if(null!=E){var z=Math.min(p,(t-q)/(P-1)),V=da([v,b],[E,k],t,-z,d),$=da([w,A],null==_?[v,b]:[_,x],t,-z,d);p===z?M.push("L",$[0],"A",z,",",z," 0 0,",g," ",$[1],"A",t,",",t," 0 ",d^fa($[1][0],$[1][1],V[1][0],V[1][1]),",",1-d," ",V[1],"A",z,",",z," 0 0,",g," ",V[0]):M.push("L",$[0],"A",z,",",z," 0 0,",g," ",V[0])}else M.push("L",w,",",A)}else M.push("M",v,",",b),null!=_&&M.push("A",c,",",c," 0 ",S,",",d," ",_,",",x),M.push("L",w,",",A),null!=E&&M.push("A",t,",",t," 0 ",F,",",1-d," ",E,",",k);return M.push("Z"),M.join("")}function e(t,e){return"M0,"+t+"A"+t+","+t+" 0 1,"+e+" 0,"+-t+"A"+t+","+t+" 0 1,"+e+" 0,"+t}var n=oa,r=sa,i=ua,a=Cs,u=ca,o=la,s=ha;return t.innerRadius=function(e){return arguments.length?(n=Ct(e),t):n},t.outerRadius=function(e){return arguments.length?(r=Ct(e),t):r},t.cornerRadius=function(e){return arguments.length?(i=Ct(e),t):i},t.padRadius=function(e){return arguments.length?(a=e==Cs?Cs:Ct(e),t):a},t.startAngle=function(e){return arguments.length?(u=Ct(e),t):u},t.endAngle=function(e){return arguments.length?(o=Ct(e),t):o},t.padAngle=function(e){return arguments.length?(s=Ct(e),t):s},t.centroid=function(){var t=(+n.apply(this,arguments)+ +r.apply(this,arguments))/2,e=(+u.apply(this,arguments)+ +o.apply(this,arguments))/2-Ou;return[Math.cos(e)*t,Math.sin(e)*t]},t};var Cs="auto";nu.svg.line=function(){return pa(b)};var Ms=nu.map({linear:ga,"linear-closed":ya,step:ma,"step-before":va,"step-after":ba,basis:ka,"basis-open":Da,"basis-closed":Ca,bundle:Ma,cardinal:wa,"cardinal-open":_a,"cardinal-closed":xa,monotone:Na});Ms.forEach(function(t,e){e.key=t,e.closed=/-closed$/.test(t)});var Ss=[0,2/3,1/3,0],Ts=[0,1/3,2/3,0],Fs=[0,1/6,2/3,1/6];nu.svg.line.radial=function(){var t=pa(Oa);return t.radius=t.x,delete t.x,t.angle=t.y,delete t.y,t},va.reverse=ba,ba.reverse=va,nu.svg.area=function(){return Ia(b)},nu.svg.area.radial=function(){var t=Ia(Oa);return t.radius=t.x,delete t.x,t.innerRadius=t.x0,delete t.x0,t.outerRadius=t.x1,delete t.x1,t.angle=t.y,delete t.y,t.startAngle=t.y0,delete t.y0,t.endAngle=t.y1,delete t.y1,t},nu.svg.chord=function(){function t(t,o){var s=e(this,a,t,o),c=e(this,u,t,o);return"M"+s.p0+r(s.r,s.p1,s.a1-s.a0)+(n(s,c)?i(s.r,s.p1,s.r,s.p0):i(s.r,s.p1,c.r,c.p0)+r(c.r,c.p1,c.a1-c.a0)+i(c.r,c.p1,s.r,s.p0))+"Z"}function e(t,e,n,r){var i=e.call(t,n,r),a=o.call(t,i,r),u=s.call(t,i,r)-Ou,l=c.call(t,i,r)-Ou;return{r:a,a0:u,a1:l,p0:[a*Math.cos(u),a*Math.sin(u)],p1:[a*Math.cos(l),a*Math.sin(l)]}}function n(t,e){return t.a0==e.a0&&t.a1==e.a1}function r(t,e,n){return"A"+t+","+t+" 0 "+ +(n>Bu)+",1 "+e}function i(t,e,n,r){return"Q 0,0 "+r}var a=bn,u=_n,o=Ra,s=ca,c=la;return t.radius=function(e){return arguments.length?(o=Ct(e),t):o},t.source=function(e){return arguments.length?(a=Ct(e),t):a},t.target=function(e){return arguments.length?(u=Ct(e),t):u},t.startAngle=function(e){return arguments.length?(s=Ct(e),t):s},t.endAngle=function(e){return arguments.length?(c=Ct(e),t):c},t},nu.svg.diagonal=function(){function t(t,i){var a=e.call(this,t,i),u=n.call(this,t,i),o=(a.y+u.y)/2,s=[a,{x:a.x,y:o},{x:u.x,y:o},u];return s=s.map(r),"M"+s[0]+"C"+s[1]+" "+s[2]+" "+s[3]}var e=bn,n=_n,r=Pa;return t.source=function(n){return arguments.length?(e=Ct(n),t):e},t.target=function(e){return arguments.length?(n=Ct(e),t):n},t.projection=function(e){return arguments.length?(r=e,t):r},t},nu.svg.diagonal.radial=function(){var t=nu.svg.diagonal(),e=Pa,n=t.projection;return t.projection=function(t){return arguments.length?n(qa(e=t)):e},t},nu.svg.symbol=function(){function t(t,r){return(Bs.get(e.call(this,t,r))||Ya)(n.call(this,t,r))}var e=Ua,n=ja;return t.type=function(n){return arguments.length?(e=Ct(n),t):e},t.size=function(e){return arguments.length?(n=Ct(e),t):n},t};var Bs=nu.map({circle:Ya,cross:function(t){var e=Math.sqrt(t/5)/2;return"M"+-3*e+","+-e+"H"+-e+"V"+-3*e+"H"+e+"V"+-e+"H"+3*e+"V"+e+"H"+e+"V"+3*e+"H"+-e+"V"+e+"H"+-3*e+"Z"},diamond:function(t){var e=Math.sqrt(t/(2*Ns)),n=e*Ns;return"M0,"+-e+"L"+n+",0 0,"+e+" "+-n+",0Z"},square:function(t){var e=Math.sqrt(t)/2;return"M"+-e+","+-e+"L"+e+","+-e+" "+e+","+e+" "+-e+","+e+"Z"},"triangle-down":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+n+"L"+e+","+-n+" "+-e+","+-n+"Z"},"triangle-up":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+-n+"L"+e+","+n+" "+-e+","+n+"Z"}});nu.svg.symbolTypes=Bs.keys();var Ls=Math.sqrt(3),Ns=Math.tan(30*Iu);Au.transition=function(t){for(var e,n,r=Os||++qs,i=Ha(t),a=[],u=Is||{time:Date.now(),ease:Dr,delay:0,duration:250},o=-1,s=this.length;++oa;a++){i.push(e=[]);for(var n=this[a],o=0,s=n.length;s>o;o++)(r=n[o])&&t.call(r,r.__data__,o,a)&&e.push(r)}return Va(i,this.namespace,this.id)},Ps.tween=function(t,e){var n=this.id,r=this.namespace;return arguments.length<2?this.node()[r][n].tween.get(t):V(this,null==e?function(e){e[r][n].tween.remove(t)}:function(i){i[r][n].tween.set(t,e)})},Ps.attr=function(t,e){function n(){this.removeAttribute(o)}function r(){this.removeAttributeNS(o.space,o.local)}function i(t){return null==t?n:(t+="",function(){var e,n=this.getAttribute(o);return n!==t&&(e=u(n,t),function(t){this.setAttribute(o,e(t))})})}function a(t){return null==t?r:(t+="",function(){var e,n=this.getAttributeNS(o.space,o.local);return n!==t&&(e=u(n,t),function(t){this.setAttributeNS(o.space,o.local,e(t))})})}if(arguments.length<2){for(e in t)this.attr(e,t[e]);return this}var u="transform"==t?Yr:br,o=nu.ns.qualify(t);return $a(this,"attr."+t,e,o.local?a:i)},Ps.attrTween=function(t,e){function n(t,n){var r=e.call(this,t,n,this.getAttribute(i));return r&&function(t){this.setAttribute(i,r(t))}}function r(t,n){var r=e.call(this,t,n,this.getAttributeNS(i.space,i.local));return r&&function(t){this.setAttributeNS(i.space,i.local,r(t))}}var i=nu.ns.qualify(t);return this.tween("attr."+t,i.local?r:n)},Ps.style=function(t,e,r){function i(){this.style.removeProperty(t)}function a(e){return null==e?i:(e+="",function(){var i,a=n(this).getComputedStyle(this,null).getPropertyValue(t);return a!==e&&(i=br(a,e),function(e){this.style.setProperty(t,i(e),r)})})}var u=arguments.length;if(3>u){if("string"!=typeof t){2>u&&(e="");for(r in t)this.style(r,t[r],e);return this}r=""}return $a(this,"style."+t,e,a)},Ps.styleTween=function(t,e,r){function i(i,a){var u=e.call(this,i,a,n(this).getComputedStyle(this,null).getPropertyValue(t));return u&&function(e){this.style.setProperty(t,u(e),r)}}return arguments.length<3&&(r=""),this.tween("style."+t,i)},Ps.text=function(t){return $a(this,"text",t,Ga)},Ps.remove=function(){var t=this.namespace;return this.each("end.transition",function(){var e;this[t].count<2&&(e=this.parentNode)&&e.removeChild(this)})},Ps.ease=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].ease:("function"!=typeof t&&(t=nu.ease.apply(nu,arguments)),V(this,function(r){r[n][e].ease=t}))},Ps.delay=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].delay:V(this,"function"==typeof t?function(r,i,a){r[n][e].delay=+t.call(r,r.__data__,i,a)}:(t=+t,function(r){r[n][e].delay=t}))},Ps.duration=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].duration:V(this,"function"==typeof t?function(r,i,a){r[n][e].duration=Math.max(1,t.call(r,r.__data__,i,a))}:(t=Math.max(1,t),function(r){r[n][e].duration=t}))},Ps.each=function(t,e){var n=this.id,r=this.namespace;if(arguments.length<2){var i=Is,a=Os;try{Os=n,V(this,function(e,i,a){Is=e[r][n],t.call(e,e.__data__,i,a)})}finally{Is=i,Os=a}}else V(this,function(i){var a=i[r][n];(a.event||(a.event=nu.dispatch("start","end","interrupt"))).on(t,e)});return this},Ps.transition=function(){for(var t,e,n,r,i=this.id,a=++qs,u=this.namespace,o=[],s=0,c=this.length;c>s;s++){o.push(t=[]);for(var e=this[s],l=0,h=e.length;h>l;l++)(n=e[l])&&(r=n[u][i],Wa(n,l,u,a,{time:r.time,ease:r.ease,delay:r.delay+r.duration,duration:r.duration})),t.push(n)}return Va(o,u,a)},nu.svg.axis=function(){function t(t){t.each(function(){var t,c=nu.select(this),l=this.__chart__||n,h=this.__chart__=n.copy(),f=null==s?h.ticks?h.ticks.apply(h,o):h.domain():s,d=null==e?h.tickFormat?h.tickFormat.apply(h,o):b:e,p=c.selectAll(".tick").data(f,h),g=p.enter().insert("g",".domain").attr("class","tick").style("opacity",Tu),y=nu.transition(p.exit()).style("opacity",Tu).remove(),m=nu.transition(p.order()).style("opacity",1),v=Math.max(i,0)+u,_=qi(h),x=c.selectAll(".domain").data([0]),w=(x.enter().append("path").attr("class","domain"),nu.transition(x));g.append("line"),g.append("text");var A,E,k,D,C=g.select("line"),M=m.select("line"),S=p.select("text").text(d),T=g.select("text"),F=m.select("text"),B="top"===r||"left"===r?-1:1;if("bottom"===r||"top"===r?(t=Za,A="x",k="y",E="x2",D="y2",S.attr("dy",0>B?"0em":".71em").style("text-anchor","middle"),w.attr("d","M"+_[0]+","+B*a+"V0H"+_[1]+"V"+B*a)):(t=Xa,A="y",k="x",E="y2",D="x2",S.attr("dy",".32em").style("text-anchor",0>B?"end":"start"),w.attr("d","M"+B*a+","+_[0]+"H0V"+_[1]+"H"+B*a)),C.attr(D,B*i),T.attr(k,B*v),M.attr(E,0).attr(D,B*i),F.attr(A,0).attr(k,B*v),h.rangeBand){var L=h,N=L.rangeBand()/2;l=h=function(t){return L(t)+N}}else l.rangeBand?l=h:y.call(t,h,l);g.call(t,l,h),m.call(t,h,h)})}var e,n=nu.scale.linear(),r=js,i=6,a=6,u=3,o=[10],s=null;return t.scale=function(e){return arguments.length?(n=e,t):n},t.orient=function(e){return arguments.length?(r=e in Us?e+"":js,t):r},t.ticks=function(){return arguments.length?(o=arguments,t):o},t.tickValues=function(e){return arguments.length?(s=e,t):s},t.tickFormat=function(n){return arguments.length?(e=n,t):e},t.tickSize=function(e){var n=arguments.length;return n?(i=+e,a=+arguments[n-1],t):i},t.innerTickSize=function(e){return arguments.length?(i=+e,t):i},t.outerTickSize=function(e){return arguments.length?(a=+e,t):a},t.tickPadding=function(e){return arguments.length?(u=+e,t):u},t.tickSubdivide=function(){return arguments.length&&t},t};var js="bottom",Us={top:1,right:1,bottom:1,left:1};nu.svg.brush=function(){function t(n){n.each(function(){var n=nu.select(this).style("pointer-events","all").style("-webkit-tap-highlight-color","rgba(0,0,0,0)").on("mousedown.brush",a).on("touchstart.brush",a),u=n.selectAll(".background").data([0]);u.enter().append("rect").attr("class","background").style("visibility","hidden").style("cursor","crosshair"),n.selectAll(".extent").data([0]).enter().append("rect").attr("class","extent").style("cursor","move");var o=n.selectAll(".resize").data(g,b);o.exit().remove(),o.enter().append("g").attr("class",function(t){return"resize "+t}).style("cursor",function(t){return Ys[t]}).append("rect").attr("x",function(t){return/[ew]$/.test(t)?-3:null}).attr("y",function(t){return/^[ns]/.test(t)?-3:null}).attr("width",6).attr("height",6).style("visibility","hidden"),o.style("display",t.empty()?"none":null);var s,h=nu.transition(n),f=nu.transition(u);c&&(s=qi(c),f.attr("x",s[0]).attr("width",s[1]-s[0]),r(h)),l&&(s=qi(l),f.attr("y",s[0]).attr("height",s[1]-s[0]),i(h)),e(h)})}function e(t){t.selectAll(".resize").attr("transform",function(t){return"translate("+h[+/e$/.test(t)]+","+f[+/^s/.test(t)]+")"})}function r(t){t.select(".extent").attr("x",h[0]),t.selectAll(".extent,.n>rect,.s>rect").attr("width",h[1]-h[0])}function i(t){t.select(".extent").attr("y",f[0]),t.selectAll(".extent,.e>rect,.w>rect").attr("height",f[1]-f[0])}function a(){function a(){32==nu.event.keyCode&&(S||(b=null,F[0]-=h[1],F[1]-=f[1],S=2),k())}function g(){32==nu.event.keyCode&&2==S&&(F[0]+=h[1],F[1]+=f[1],S=0,k())}function y(){var t=nu.mouse(x),n=!1;_&&(t[0]+=_[0],t[1]+=_[1]),S||(nu.event.altKey?(b||(b=[(h[0]+h[1])/2,(f[0]+f[1])/2]),F[0]=h[+(t[0]l?(i=r,r=l):i=l),g[0]!=r||g[1]!=i?(n?o=null:u=null,g[0]=r,g[1]=i,!0):void 0}function v(){y(),E.style("pointer-events","all").selectAll(".resize").style("display",t.empty()?"none":null),nu.select("body").style("cursor",null),B.on("mousemove.brush",null).on("mouseup.brush",null).on("touchmove.brush",null).on("touchend.brush",null).on("keydown.brush",null).on("keyup.brush",null),T(),A({type:"brushend"})}var b,_,x=this,w=nu.select(nu.event.target),A=s.of(x,arguments),E=nu.select(x),D=w.datum(),C=!/^(n|s)$/.test(D)&&c,M=!/^(e|w)$/.test(D)&&l,S=w.classed("extent"),T=X(x),F=nu.mouse(x),B=nu.select(n(x)).on("keydown.brush",a).on("keyup.brush",g);if(nu.event.changedTouches?B.on("touchmove.brush",y).on("touchend.brush",v):B.on("mousemove.brush",y).on("mouseup.brush",v),E.interrupt().selectAll("*").interrupt(),S)F[0]=h[0]-F[0],F[1]=f[0]-F[1];else if(D){var L=+/w$/.test(D),N=+/^n/.test(D);_=[h[1-L]-F[0],f[1-N]-F[1]],F[0]=h[L],F[1]=f[N]}else nu.event.altKey&&(b=F.slice());E.style("pointer-events","none").selectAll(".resize").style("display",null),nu.select("body").style("cursor",w.style("cursor")),A({type:"brushstart"}),y()}var u,o,s=C(t,"brushstart","brush","brushend"),c=null,l=null,h=[0,0],f=[0,0],d=!0,p=!0,g=zs[0];return t.event=function(t){t.each(function(){var t=s.of(this,arguments),e={x:h,y:f,i:u,j:o},n=this.__chart__||e;this.__chart__=e,Os?nu.select(this).transition().each("start.brush",function(){u=n.i,o=n.j,h=n.x,f=n.y,t({type:"brushstart"})}).tween("brush:brush",function(){var n=_r(h,e.x),r=_r(f,e.y);return u=o=null,function(i){h=e.x=n(i),f=e.y=r(i),t({type:"brush",mode:"resize"})}}).each("end.brush",function(){u=e.i,o=e.j,t({type:"brush",mode:"resize"}),t({type:"brushend"})}):(t({type:"brushstart"}),t({type:"brush",mode:"resize"}),t({type:"brushend"}))})},t.x=function(e){return arguments.length?(c=e,g=zs[!c<<1|!l],t):c},t.y=function(e){return arguments.length?(l=e,g=zs[!c<<1|!l],t):l},t.clamp=function(e){return arguments.length?(c&&l?(d=!!e[0],p=!!e[1]):c?d=!!e:l&&(p=!!e),t):c&&l?[d,p]:c?d:l?p:null},t.extent=function(e){var n,r,i,a,s;return arguments.length?(c&&(n=e[0],r=e[1],l&&(n=n[0],r=r[0]),u=[n,r],c.invert&&(n=c(n),r=c(r)),n>r&&(s=n,n=r,r=s),(n!=h[0]||r!=h[1])&&(h=[n,r])),l&&(i=e[0],a=e[1],c&&(i=i[1],a=a[1]),o=[i,a],l.invert&&(i=l(i),a=l(a)),i>a&&(s=i,i=a,a=s),(i!=f[0]||a!=f[1])&&(f=[i,a])),t):(c&&(u?(n=u[0],r=u[1]):(n=h[0],r=h[1],c.invert&&(n=c.invert(n),r=c.invert(r)),n>r&&(s=n,n=r,r=s))),l&&(o?(i=o[0],a=o[1]):(i=f[0],a=f[1],l.invert&&(i=l.invert(i),a=l.invert(a)),i>a&&(s=i,i=a,a=s))),c&&l?[[n,i],[r,a]]:c?[n,r]:l&&[i,a])},t.clear=function(){return t.empty()||(h=[0,0],f=[0,0],u=o=null),t},t.empty=function(){return!!c&&h[0]==h[1]||!!l&&f[0]==f[1]},nu.rebind(t,s,"on")};var Ys={n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},zs=[["n","e","s","w","nw","ne","se","sw"],["e","w"],["n","s"],[]],Vs=so.format=go.timeFormat,$s=Vs.utc,Gs=$s("%Y-%m-%dT%H:%M:%S.%LZ");Vs.iso=Date.prototype.toISOString&&+new Date("2000-01-01T00:00:00.000Z")?Ja:Gs,Ja.parse=function(t){var e=new Date(t);return isNaN(e)?null:e},Ja.toString=Gs.toString,so.second=jt(function(t){return new co(1e3*Math.floor(t/1e3))},function(t,e){t.setTime(t.getTime()+1e3*Math.floor(e))},function(t){return t.getSeconds()}),so.seconds=so.second.range,so.seconds.utc=so.second.utc.range,so.minute=jt(function(t){return new co(6e4*Math.floor(t/6e4))},function(t,e){t.setTime(t.getTime()+6e4*Math.floor(e))},function(t){return t.getMinutes()}),so.minutes=so.minute.range,so.minutes.utc=so.minute.utc.range,so.hour=jt(function(t){var e=t.getTimezoneOffset()/60;return new co(36e5*(Math.floor(t/36e5-e)+e))},function(t,e){t.setTime(t.getTime()+36e5*Math.floor(e))},function(t){return t.getHours()}),so.hours=so.hour.range,so.hours.utc=so.hour.utc.range,so.month=jt(function(t){return t=so.day(t),t.setDate(1),t},function(t,e){t.setMonth(t.getMonth()+e)},function(t){return t.getMonth()}),so.months=so.month.range,so.months.utc=so.month.utc.range;var Hs=[1e3,5e3,15e3,3e4,6e4,3e5,9e5,18e5,36e5,108e5,216e5,432e5,864e5,1728e5,6048e5,2592e6,7776e6,31536e6],Ws=[[so.second,1],[so.second,5],[so.second,15],[so.second,30],[so.minute,1],[so.minute,5],[so.minute,15],[so.minute,30],[so.hour,1],[so.hour,3],[so.hour,6],[so.hour,12],[so.day,1],[so.day,2],[so.week,1],[so.month,1],[so.month,3],[so.year,1]],Zs=Vs.multi([[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["%I:%M",function(t){return t.getMinutes()}],["%I %p",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}],["%Y",Se]]),Xs={range:function(t,e,n){return nu.range(Math.ceil(t/n)*n,+e,n).map(Qa)},floor:b,ceil:b};Ws.year=so.year,so.scale=function(){return Ka(nu.scale.linear(),Ws,Zs)};var Js=Ws.map(function(t){return[t[0].utc,t[1]]}),Ks=$s.multi([[".%L",function(t){return t.getUTCMilliseconds()}],[":%S",function(t){return t.getUTCSeconds()}],["%I:%M",function(t){return t.getUTCMinutes()}],["%I %p",function(t){return t.getUTCHours()}],["%a %d",function(t){return t.getUTCDay()&&1!=t.getUTCDate()}],["%b %d",function(t){return 1!=t.getUTCDate()}],["%B",function(t){return t.getUTCMonth()}],["%Y",Se]]);Js.year=so.year.utc,so.scale.utc=function(){return Ka(nu.scale.linear(),Js,Ks)},nu.text=Mt(function(t){return t.responseText}),nu.json=function(t,e){return St(t,"application/json",tu,e)},nu.html=function(t,e){return St(t,"text/html",eu,e)},nu.xml=Mt(function(t){return t.responseXML}),"function"==typeof define&&define.amd?define(nu):"object"==typeof e&&e.exports&&(e.exports=nu),this.d3=nu}()},{}],5:[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":12,"./lib/graphlib":13,"./lib/intersect":14,"./lib/render":29,"./lib/util":31,"./lib/version":32}],6:[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"),u=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(u,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"),u=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(u,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"),u=i.append("path").attr("d","M 0 5 L 10 5").style("stroke-width",1).style("stroke-dasharray","1,0");a.applyStyle(u,n[r+"Style"])}var a=t("./util");e.exports={"default":n,normal:n,vee:r,undirected:i}},{"./util":31}],7:[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":22,"./util":31}],8:[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(u.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"),u=t("./d3");e.exports=n},{"./d3":11,"./label/add-label":22,"./lodash":25,"./util":31}],9:[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 u(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=s.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,"arrowhead")}),i}function r(t,e){var n=t.edge(e),r=t.node(e.v),a=t.node(e.w),u=n.points.slice(1,n.points.length-1);return u.unshift(c(r,u[0])),u.push(c(a,u[u.length-1])),i(n,u)}function i(t,e){var n=h.svg.line().x(function(t){return t.x}).y(function(t){return t.y});return s.has(t,"lineInterpolate")&&n.interpolate(t.lineInterpolate),s.has(t,"lineTension")&&n.tension(Number(t.lineTension)),n(e)}function a(t){var e=t.getBBox(),n=t.getTransformToElement(t.ownerSVGElement).translate(e.width/2,e.height/2);return{x:n.e,y:n.f}}function u(t,e){var n=t.enter().append("g").attr("class","edgePath").style("opacity",0);n.append("path").attr("class","path").attr("d",function(t){var n=e.edge(t),r=e.node(t.v).elem,u=s.range(n.points.length).map(function(){return a(r)});return i(n,u)}),n.append("defs")}function o(t,e){var n=t.exit();l.applyTransition(n,e).style("opacity",0).remove(),l.applyTransition(n.select("path.path"),e).attr("d",function(t){var n=e.node(t.v);if(n){var r=s.range(this.pathSegList.length).map(function(){return n});return i({},r)}return h.select(this).attr("d")})}var s=t("./lodash"),c=t("./intersect/intersect-node"),l=t("./util"),h=t("./d3");e.exports=n},{"./d3":11,"./intersect/intersect-node":18,"./lodash":25,"./util":31}],10:[function(t,e){"use strict"; -function n(t,e,n){var o=e.nodes().filter(function(t){return!a.isSubgraph(e,t)}),s=t.selectAll("g.node").data(o,function(t){return t}).classed("update",!0);return s.selectAll("*").remove(),s.enter().append("g").attr("class","node").style("opacity",0),s.each(function(t){var o=e.node(t),s=u.select(this),c=s.append("g").attr("class","label"),l=i(c,o),h=n[o.shape],f=r.pick(l.node().getBBox(),"width","height");o.elem=this,o.id&&s.attr("id",o.id),o.labelId&&c.attr("id",o.labelId),a.applyClass(s,o["class"],(s.classed("update")?"update ":"")+"node"),r.has(o,"width")&&(f.width=o.width),r.has(o,"height")&&(f.height=o.height),f.width+=o.paddingLeft+o.paddingRight,f.height+=o.paddingTop+o.paddingBottom,c.attr("transform","translate("+(o.paddingLeft-o.paddingRight)/2+","+(o.paddingTop-o.paddingBottom)/2+")");var d=h(u.select(this),f,o);a.applyStyle(d,o.style);var p=d.node().getBBox();o.width=p.width,o.height=p.height}),a.applyTransition(s.exit(),e).style("opacity",0).remove(),s}var r=t("./lodash"),i=t("./label/add-label"),a=t("./util"),u=t("./d3");e.exports=n},{"./d3":11,"./label/add-label":22,"./lodash":25,"./util":31}],11:[function(t,e){e.exports=window.d3},{}],12:[function(t,e){var n;if(t)try{n=t("dagre")}catch(r){}n||(n=window.dagre),e.exports=n},{dagre:54}],13:[function(t,e){var n;if(t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:33}],14:[function(t,e){e.exports={node:t("./intersect-node"),circle:t("./intersect-circle"),ellipse:t("./intersect-ellipse"),polygon:t("./intersect-polygon"),rect:t("./intersect-rect")}},{"./intersect-circle":15,"./intersect-ellipse":16,"./intersect-node":18,"./intersect-polygon":19,"./intersect-rect":20}],15:[function(t,e){function n(t,e,n){return r(t,e,e,n)}var r=t("./intersect-ellipse");e.exports=n},{"./intersect-ellipse":16}],16:[function(t,e){function n(t,e,n,r){var i=t.x,a=t.y,u=i-r.x,o=a-r.y,s=Math.sqrt(e*e*o*o+n*n*u*u),c=Math.abs(e*n*u/s);r.xm?(m-y)/g:(m+y)/g,m=u*c-a*l,b=0>m?(m-y)/g:(m+y)/g,{x:v,y:b})}function r(t,e){return t*e>0}e.exports=n},{}],18:[function(t,e){function n(t,e){return t.intersect(e)}e.exports=n},{}],19:[function(t,e){function n(t,e,n){var i=t.x,a=t.y,u=[],o=Number.POSITIVE_INFINITY,s=Number.POSITIVE_INFINITY;e.forEach(function(t){o=Math.min(o,t.x),s=Math.min(s,t.y)});for(var c=i-t.width/2-o,l=a-t.height/2-s,h=0;h1&&u.sort(function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),u=e.x-n.x,o=e.y-n.y,s=Math.sqrt(u*u+o*o);return s>a?-1:a===s?0:1}),u[0]):(console.log("NO INTERSECTION FOUND, RETURN NODE CENTER",t),t)}var r=t("./intersect-line");e.exports=n},{"./intersect-line":17}],20:[function(t,e){function n(t,e){var n,r,i=t.x,a=t.y,u=e.x-i,o=e.y-a,s=t.width/2,c=t.height/2;return Math.abs(o)*s>Math.abs(u)*c?(0>o&&(c=-c),n=0===o?0:c*u/o,r=c):(0>u&&(s=-s),n=s,r=0===u?0:s*o/u),{x:i+n,y:a+r}}e.exports=n},{}],21:[function(t,e){function n(t,e){var n=t.append("foreignObject").attr("width","100000"),i=n.append("xhtml:div"),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 u,o;return i.each(function(){u=this.clientWidth,o=this.clientHeight}),n.attr("width",u).attr("height",o),n}var r=t("../util");e.exports=n},{"../util":31}],22:[function(t,e){function n(t,e,n){var u=e.label,o=t.append("g");"svg"===e.labelType?a(o,e):"string"!=typeof u||"html"===e.labelType?i(o,e):r(o,e);var s,c=o.node().getBBox();switch(n){case"top":s=-e.height/2;break;case"bottom":s=e.height/2-c.height;break;default:s=-c.height/2}return o.attr("transform","translate("+-c.width/2+","+s+")"),o}var r=t("./add-text-label"),i=t("./add-html-label"),a=t("./add-svg-label");e.exports=n},{"./add-html-label":21,"./add-svg-label":23,"./add-text-label":24}],23:[function(t,e){function n(t,e){var n=t;return n.node().appendChild(e.label),r.applyStyle(n,e.labelStyle),n}var r=t("../util");e.exports=n},{"../util":31}],24:[function(t,e){function n(t,e){for(var n=t.append("text"),a=r(e.label).split("\n"),u=0;ua)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+t+" Weight: "+a);c0&&(i=s.removeMin(),u=o[i],u.distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return o}var i=t("../lodash"),a=t("../data/priority-queue");e.exports=n;var u=i.constant(1)},{"../data/priority-queue":47,"../lodash":51}],38:[function(t,e){function n(t){return r.filter(i(t),function(e){return e.length>1||1===e.length&&t.hasEdge(e[0],e[0])})}var r=t("../lodash"),i=t("./tarjan");e.exports=n},{"../lodash":51,"./tarjan":45}],39:[function(t,e){function n(t,e,n){return r(t,e||a,n||function(e){return t.outEdges(e)})}function r(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],u=a[n],o=r.distance+i.distance;oi&&(s[n]=u,c.decrease(n,i))}}var u,o=new i,s={},c=new 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(u=c.removeMin(),r.has(s,u))o.setEdge(u,s[u]);else{if(l)throw new Error("Input graph is not connected: "+t);l=!0}t.nodeEdges(u).forEach(n)}return o}var r=t("../lodash"),i=t("../graph"),a=t("../data/priority-queue");e.exports=n},{"../data/priority-queue":47,"../graph":48,"../lodash":51}],45:[function(t,e){function n(t){function e(o){var s=a[o]={onStack:!0,lowlink:n,index:n++};if(i.push(o),t.successors(o).forEach(function(t){r.has(a,t)?a[t].onStack&&(s.lowlink=Math.min(s.lowlink,a[t].index)):(e(t),s.lowlink=Math.min(s.lowlink,a[t].lowlink))}),s.lowlink===s.index){var c,l=[];do c=i.pop(),a[c].onStack=!1,l.push(c);while(o!==c);u.push(l)}}var n=0,i=[],a={},u=[];return t.nodes().forEach(function(t){r.has(a,t)||e(t)}),u}var r=t("../lodash");e.exports=n},{"../lodash":51}],46:[function(t,e){function n(t){function e(o){if(i.has(a,o))throw new r;i.has(n,o)||(a[o]=!0,n[o]=!0,i.each(t.predecessors(o),e),delete a[o],u.push(o))}var n={},a={},u=[];if(i.each(t.sinks(),e),i.size(n)!==t.nodeCount())throw new r;return u}function r(){}var i=t("../lodash");e.exports=n,n.CycleException=r},{"../lodash":51}],47:[function(t,e){function n(){this._arr=[],this._keyIndices={}}var r=t("../lodash");e.exports=n,n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(t){return t.key})},n.prototype.has=function(t){return r.has(this._keyIndices,t)},n.prototype.priority=function(t){var e=this._keyIndices[t];return void 0!==e?this._arr[e].priority:void 0},n.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},n.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},n.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},n.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)},n.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,i=t;n>1,!(n[e].prioritya){var u=i;i=a,a=u}return i+h+a+h+(s.isUndefined(r)?c:r)}function u(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var u=i;i=a,a=u}var o={v:i,w:a};return r&&(o.name=r),o}function o(t,e){return a(t,e.v,e.w,e.name)}var s=t("./lodash");e.exports=n;var c="\x00",l="\x00",h="";n.prototype._nodeCount=0,n.prototype._edgeCount=0,n.prototype.isDirected=function(){return this._isDirected},n.prototype.isMultigraph=function(){return this._isMultigraph},n.prototype.isCompound=function(){return this._isCompound},n.prototype.setGraph=function(t){return this._label=t,this},n.prototype.graph=function(){return this._label},n.prototype.setDefaultNodeLabel=function(t){return s.isFunction(t)||(t=s.constant(t)),this._defaultNodeLabelFn=t,this},n.prototype.nodeCount=function(){return this._nodeCount},n.prototype.nodes=function(){return s.keys(this._nodes)},n.prototype.sources=function(){return s.filter(this.nodes(),function(t){return s.isEmpty(this._in[t])},this)},n.prototype.sinks=function(){return s.filter(this.nodes(),function(t){return s.isEmpty(this._out[t])},this)},n.prototype.setNodes=function(t,e){var n=arguments;return s.each(t,function(t){n.length>1?this.setNode(t,e):this.setNode(t)},this),this},n.prototype.setNode=function(t,e){return s.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]=l,this._children[t]={},this._children[l][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},n.prototype.node=function(t){return this._nodes[t]},n.prototype.hasNode=function(t){return s.has(this._nodes,t)},n.prototype.removeNode=function(t){var e=this;if(s.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],s.each(this.children(t),function(t){this.setParent(t)},this),delete this._children[t]),s.each(s.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],s.each(s.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},n.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(s.isUndefined(e))e=l;else{e+="";for(var n=e;!s.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},n.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},n.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!==l)return e}},n.prototype.children=function(t){if(s.isUndefined(t)&&(t=l),this._isCompound){var e=this._children[t];if(e)return s.keys(e)}else{if(t===l)return this.nodes();if(this.hasNode(t))return[]}},n.prototype.predecessors=function(t){var e=this._preds[t];return e?s.keys(e):void 0},n.prototype.successors=function(t){var e=this._sucs[t];return e?s.keys(e):void 0},n.prototype.neighbors=function(t){var e=this.predecessors(t);return e?s.union(e,this.successors(t)):void 0},n.prototype.filterNodes=function(t){function e(t){var a=r.parent(t);return void 0===a||n.hasNode(a)?(i[t]=a,a):a in i?i[a]:e(a)}var n=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});n.setGraph(this.graph()),s.each(this._nodes,function(e,r){t(r)&&n.setNode(r,e)},this),s.each(this._edgeObjs,function(t){n.hasNode(t.v)&&n.hasNode(t.w)&&n.setEdge(t,this.edge(t))},this);var r=this,i={};return this._isCompound&&s.each(n.nodes(),function(t){n.setParent(t,e(t))}),n},n.prototype.setDefaultEdgeLabel=function(t){return s.isFunction(t)||(t=s.constant(t)),this._defaultEdgeLabelFn=t,this},n.prototype.edgeCount=function(){return this._edgeCount},n.prototype.edges=function(){return s.values(this._edgeObjs)},n.prototype.setPath=function(t,e){var n=this,r=arguments;return s.reduce(t,function(t,i){return r.length>1?n.setEdge(t,i,e):n.setEdge(t,i),i}),this},n.prototype.setEdge=function(){var t,e,n,i,o=!1,c=arguments[0];"object"==typeof c&&null!==c&&"v"in c?(t=c.v,e=c.w,n=c.name,2===arguments.length&&(i=arguments[1],o=!0)):(t=c,e=arguments[1],n=arguments[3],arguments.length>2&&(i=arguments[2],o=!0)),t=""+t,e=""+e,s.isUndefined(n)||(n=""+n);var l=a(this._isDirected,t,e,n);if(s.has(this._edgeLabels,l))return o&&(this._edgeLabels[l]=i),this;if(!s.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[l]=o?i:this._defaultEdgeLabelFn(t,e,n);var h=u(this._isDirected,t,e,n);return t=h.v,e=h.w,Object.freeze(h),this._edgeObjs[l]=h,r(this._preds[e],t),r(this._sucs[t],e),this._in[e][l]=h,this._out[t][l]=h,this._edgeCount++,this},n.prototype.edge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return this._edgeLabels[r]},n.prototype.hasEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return s.has(this._edgeLabels,r)},n.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n),u=this._edgeObjs[r];return u&&(t=u.v,e=u.w,delete this._edgeLabels[r],delete this._edgeObjs[r],i(this._preds[e],t),i(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},n.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var r=s.values(n);return e?s.filter(r,function(t){return t.v===e}):r}},n.prototype.outEdges=function(t,e){var n=this._out[t];if(n){var r=s.values(n);return e?s.filter(r,function(t){return t.w===e}):r}},n.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);return n?n.concat(this.outEdges(t,e)):void 0}},{"./lodash":51}],49:[function(t,e){e.exports={Graph:t("./graph"),version:t("./version")}},{"./graph":48,"./version":52}],50:[function(t,e){function n(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:r(t),edges:i(t)};return u.isUndefined(t.graph())||(e.value=u.clone(t.graph())),e}function r(t){return u.map(t.nodes(),function(e){var n=t.node(e),r=t.parent(e),i={v:e};return u.isUndefined(n)||(i.value=n),u.isUndefined(r)||(i.parent=r),i})}function i(t){return u.map(t.edges(),function(e){var n=t.edge(e),r={v:e.v,w:e.w};return u.isUndefined(e.name)||(r.name=e.name),u.isUndefined(n)||(r.value=n),r})}function a(t){var e=new o(t.options).setGraph(t.value);return u.each(t.nodes,function(t){e.setNode(t.v,t.value),t.parent&&e.setParent(t.v,t.parent)}),u.each(t.edges,function(t){e.setEdge({v:t.v,w:t.w,name:t.name},t.value)}),e}var u=t("./lodash"),o=t("./graph");e.exports={write:n,read:a}},{"./graph":48,"./lodash":51}],51:[function(t,e){var n;if("function"==typeof t)try{n=t("lodash")}catch(r){}n||(n=window._),e.exports=n},{lodash:53}],52:[function(t,e){e.exports="1.0.7"},{}],53:[function(t,e,n){(function(t){(function(){function r(t,e){if(t!==e){var n=null===t,r=t===k,i=t===t,a=null===e,u=e===k,o=e===e;if(t>e&&!a||!i||n&&!u&&o||r&&o)return 1;if(e>t&&!n||!o||a&&!r&&i||u&&i)return-1}return 0}function i(t,e,n){for(var r=t.length,i=n?r:-1;n?i--:++i-1;);return n}function c(t,e){for(var n=t.length;n--&&e.indexOf(t.charAt(n))>-1;);return n}function l(t,e){return r(t.criteria,e.criteria)||t.index-e.index}function h(t,e,n){for(var i=-1,a=t.criteria,u=e.criteria,o=a.length,s=n.length;++i=s)return c;var l=n[i];return c*("asc"===l||l===!0?1:-1)}}return t.index-e.index}function f(t){return Vt[t]}function d(t){return $t[t]}function p(t,e,n){return e?t=Wt[t]:n&&(t=Zt[t]),"\\"+t}function g(t){return"\\"+Zt[t]}function y(t,e,n){for(var r=t.length,i=e+(n?0:-1);n?i--:++i=t&&t>=9&&13>=t||32==t||160==t||5760==t||6158==t||t>=8192&&(8202>=t||8232==t||8233==t||8239==t||8287==t||12288==t||65279==t)}function b(t,e){for(var n=-1,r=t.length,i=-1,a=[];++ne,i=n?t.length:0,a=Gn(0,i,this.__views__),u=a.start,o=a.end,s=o-u,c=r?o:u-1,l=this.__iteratees__,h=l.length,f=0,d=wu(s,this.__takeCount__);if(!n||j>i||i==s&&d==s)return nn(r&&n?t.reverse():t,this.__actions__);var p=[];t:for(;s--&&d>f;){c+=e;for(var g=-1,y=t[c];++g=j?gn(e):null,c=e.length;s&&(u=Kt,o=!1,e=s);t:for(;++in&&(n=-n>i?0:i+n),r=r===k||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 Ce(t,e){var n=[];return Nu(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}function Me(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 Se(t,e,n,r){r||(r=[]);for(var i=-1,a=t.length;++ir;)t=t[e[r++]];return r&&r==i?t:k}}function Ne(t,e,n,r,i,a){return t===e?!0:null==t||null==e||!Oi(t)&&!m(e)?t!==t&&e!==e:Ie(t,e,Ne,n,r,i,a)}function Ie(t,e,n,r,i,a,u){var o=So(t),s=So(e),c=G,l=G;o||(c=nu.call(t),c==$?c=Q:c!=Q&&(o=zi(t))),s||(l=nu.call(e),l==$?l=Q:l!=Q&&(s=zi(e)));var h=c==Q,f=l==Q,d=c==l;if(d&&!o&&!h)return qn(t,e,c);if(!i){var p=h&&tu.call(t,"__wrapped__"),g=f&&tu.call(e,"__wrapped__");if(p||g)return n(p?t.value():t,g?e.value():e,r,i,a,u)}if(!d)return!1;a||(a=[]),u||(u=[]);for(var y=a.length;y--;)if(a[y]==t)return u[y]==e;a.push(t),u.push(e); +function n(t,e,n){var o=e.nodes().filter(function(t){return!a.isSubgraph(e,t)}),s=t.selectAll("g.node").data(o,function(t){return t}).classed("update",!0);return s.selectAll("*").remove(),s.enter().append("g").attr("class","node").style("opacity",0),s.each(function(t){var o=e.node(t),s=u.select(this),c=s.append("g").attr("class","label"),l=i(c,o),h=n[o.shape],f=r.pick(l.node().getBBox(),"width","height");o.elem=this,o.id&&s.attr("id",o.id),o.labelId&&c.attr("id",o.labelId),a.applyClass(s,o["class"],(s.classed("update")?"update ":"")+"node"),r.has(o,"width")&&(f.width=o.width),r.has(o,"height")&&(f.height=o.height),f.width+=o.paddingLeft+o.paddingRight,f.height+=o.paddingTop+o.paddingBottom,c.attr("transform","translate("+(o.paddingLeft-o.paddingRight)/2+","+(o.paddingTop-o.paddingBottom)/2+")");var d=h(u.select(this),f,o);a.applyStyle(d,o.style);var p=d.node().getBBox();o.width=p.width,o.height=p.height}),a.applyTransition(s.exit(),e).style("opacity",0).remove(),s}var r=t("./lodash"),i=t("./label/add-label"),a=t("./util"),u=t("./d3");e.exports=n},{"./d3":11,"./label/add-label":22,"./lodash":25,"./util":31}],11:[function(t,e){e.exports=window.d3},{}],12:[function(t,e){var n;if(t)try{n=t("dagre")}catch(r){}n||(n=window.dagre),e.exports=n},{dagre:54}],13:[function(t,e){var n;if(t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:33}],14:[function(t,e){e.exports={node:t("./intersect-node"),circle:t("./intersect-circle"),ellipse:t("./intersect-ellipse"),polygon:t("./intersect-polygon"),rect:t("./intersect-rect")}},{"./intersect-circle":15,"./intersect-ellipse":16,"./intersect-node":18,"./intersect-polygon":19,"./intersect-rect":20}],15:[function(t,e){function n(t,e,n){return r(t,e,e,n)}var r=t("./intersect-ellipse");e.exports=n},{"./intersect-ellipse":16}],16:[function(t,e){function n(t,e,n,r){var i=t.x,a=t.y,u=i-r.x,o=a-r.y,s=Math.sqrt(e*e*o*o+n*n*u*u),c=Math.abs(e*n*u/s);r.xm?(m-y)/g:(m+y)/g,m=u*c-a*l,b=0>m?(m-y)/g:(m+y)/g,{x:v,y:b})}function r(t,e){return t*e>0}e.exports=n},{}],18:[function(t,e){function n(t,e){return t.intersect(e)}e.exports=n},{}],19:[function(t,e){function n(t,e,n){var i=t.x,a=t.y,u=[],o=Number.POSITIVE_INFINITY,s=Number.POSITIVE_INFINITY;e.forEach(function(t){o=Math.min(o,t.x),s=Math.min(s,t.y)});for(var c=i-t.width/2-o,l=a-t.height/2-s,h=0;h1&&u.sort(function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),u=e.x-n.x,o=e.y-n.y,s=Math.sqrt(u*u+o*o);return s>a?-1:a===s?0:1}),u[0]):(console.log("NO INTERSECTION FOUND, RETURN NODE CENTER",t),t)}var r=t("./intersect-line");e.exports=n},{"./intersect-line":17}],20:[function(t,e){function n(t,e){var n,r,i=t.x,a=t.y,u=e.x-i,o=e.y-a,s=t.width/2,c=t.height/2;return Math.abs(o)*s>Math.abs(u)*c?(0>o&&(c=-c),n=0===o?0:c*u/o,r=c):(0>u&&(s=-s),n=s,r=0===u?0:s*o/u),{x:i+n,y:a+r}}e.exports=n},{}],21:[function(t,e){function n(t,e){var n=t.append("foreignObject").attr("width","100000"),i=n.append("xhtml:div"),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 u,o;return i.each(function(){u=this.clientWidth,o=this.clientHeight}),n.attr("width",u).attr("height",o),n}var r=t("../util");e.exports=n},{"../util":31}],22:[function(t,e){function n(t,e,n){var u=e.label,o=t.append("g");"svg"===e.labelType?a(o,e):"string"!=typeof u||"html"===e.labelType?i(o,e):r(o,e);var s,c=o.node().getBBox();switch(n){case"top":s=-e.height/2;break;case"bottom":s=e.height/2-c.height;break;default:s=-c.height/2}return o.attr("transform","translate("+-c.width/2+","+s+")"),o}var r=t("./add-text-label"),i=t("./add-html-label"),a=t("./add-svg-label");e.exports=n},{"./add-html-label":21,"./add-svg-label":23,"./add-text-label":24}],23:[function(t,e){function n(t,e){var n=t;return n.node().appendChild(e.label),r.applyStyle(n,e.labelStyle),n}var r=t("../util");e.exports=n},{"../util":31}],24:[function(t,e){function n(t,e){for(var n=t.append("text"),a=r(e.label).split("\n"),u=0;ua)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+t+" Weight: "+a);c0&&(i=s.removeMin(),u=o[i],u.distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return o}var i=t("../lodash"),a=t("../data/priority-queue");e.exports=n;var u=i.constant(1)},{"../data/priority-queue":47,"../lodash":51}],38:[function(t,e){function n(t){return r.filter(i(t),function(e){return e.length>1||1===e.length&&t.hasEdge(e[0],e[0])})}var r=t("../lodash"),i=t("./tarjan");e.exports=n},{"../lodash":51,"./tarjan":45}],39:[function(t,e){function n(t,e,n){return r(t,e||a,n||function(e){return t.outEdges(e)})}function r(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],u=a[n],o=r.distance+i.distance;oi&&(s[n]=u,c.decrease(n,i))}}var u,o=new i,s={},c=new 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(u=c.removeMin(),r.has(s,u))o.setEdge(u,s[u]);else{if(l)throw new Error("Input graph is not connected: "+t);l=!0}t.nodeEdges(u).forEach(n)}return o}var r=t("../lodash"),i=t("../graph"),a=t("../data/priority-queue");e.exports=n},{"../data/priority-queue":47,"../graph":48,"../lodash":51}],45:[function(t,e){function n(t){function e(o){var s=a[o]={onStack:!0,lowlink:n,index:n++};if(i.push(o),t.successors(o).forEach(function(t){r.has(a,t)?a[t].onStack&&(s.lowlink=Math.min(s.lowlink,a[t].index)):(e(t),s.lowlink=Math.min(s.lowlink,a[t].lowlink))}),s.lowlink===s.index){var c,l=[];do c=i.pop(),a[c].onStack=!1,l.push(c);while(o!==c);u.push(l)}}var n=0,i=[],a={},u=[];return t.nodes().forEach(function(t){r.has(a,t)||e(t)}),u}var r=t("../lodash");e.exports=n},{"../lodash":51}],46:[function(t,e){function n(t){function e(o){if(i.has(a,o))throw new r;i.has(n,o)||(a[o]=!0,n[o]=!0,i.each(t.predecessors(o),e),delete a[o],u.push(o))}var n={},a={},u=[];if(i.each(t.sinks(),e),i.size(n)!==t.nodeCount())throw new r;return u}function r(){}var i=t("../lodash");e.exports=n,n.CycleException=r},{"../lodash":51}],47:[function(t,e){function n(){this._arr=[],this._keyIndices={}}var r=t("../lodash");e.exports=n,n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(t){return t.key})},n.prototype.has=function(t){return r.has(this._keyIndices,t)},n.prototype.priority=function(t){var e=this._keyIndices[t];return void 0!==e?this._arr[e].priority:void 0},n.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},n.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},n.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},n.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)},n.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,i=t;n>1,!(n[e].prioritya){var u=i;i=a,a=u}return i+h+a+h+(s.isUndefined(r)?c:r)}function u(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var u=i;i=a,a=u}var o={v:i,w:a};return r&&(o.name=r),o}function o(t,e){return a(t,e.v,e.w,e.name)}var s=t("./lodash");e.exports=n;var c="\x00",l="\x00",h="";n.prototype._nodeCount=0,n.prototype._edgeCount=0,n.prototype.isDirected=function(){return this._isDirected},n.prototype.isMultigraph=function(){return this._isMultigraph},n.prototype.isCompound=function(){return this._isCompound},n.prototype.setGraph=function(t){return this._label=t,this},n.prototype.graph=function(){return this._label},n.prototype.setDefaultNodeLabel=function(t){return s.isFunction(t)||(t=s.constant(t)),this._defaultNodeLabelFn=t,this},n.prototype.nodeCount=function(){return this._nodeCount},n.prototype.nodes=function(){return s.keys(this._nodes)},n.prototype.sources=function(){return s.filter(this.nodes(),function(t){return s.isEmpty(this._in[t])},this)},n.prototype.sinks=function(){return s.filter(this.nodes(),function(t){return s.isEmpty(this._out[t])},this)},n.prototype.setNodes=function(t,e){var n=arguments;return s.each(t,function(t){n.length>1?this.setNode(t,e):this.setNode(t)},this),this},n.prototype.setNode=function(t,e){return s.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]=l,this._children[t]={},this._children[l][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},n.prototype.node=function(t){return this._nodes[t]},n.prototype.hasNode=function(t){return s.has(this._nodes,t)},n.prototype.removeNode=function(t){var e=this;if(s.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],s.each(this.children(t),function(t){this.setParent(t)},this),delete this._children[t]),s.each(s.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],s.each(s.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},n.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(s.isUndefined(e))e=l;else{e+="";for(var n=e;!s.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},n.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},n.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!==l)return e}},n.prototype.children=function(t){if(s.isUndefined(t)&&(t=l),this._isCompound){var e=this._children[t];if(e)return s.keys(e)}else{if(t===l)return this.nodes();if(this.hasNode(t))return[]}},n.prototype.predecessors=function(t){var e=this._preds[t];return e?s.keys(e):void 0},n.prototype.successors=function(t){var e=this._sucs[t];return e?s.keys(e):void 0},n.prototype.neighbors=function(t){var e=this.predecessors(t);return e?s.union(e,this.successors(t)):void 0},n.prototype.filterNodes=function(t){function e(t){var a=r.parent(t);return void 0===a||n.hasNode(a)?(i[t]=a,a):a in i?i[a]:e(a)}var n=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});n.setGraph(this.graph()),s.each(this._nodes,function(e,r){t(r)&&n.setNode(r,e)},this),s.each(this._edgeObjs,function(t){n.hasNode(t.v)&&n.hasNode(t.w)&&n.setEdge(t,this.edge(t))},this);var r=this,i={};return this._isCompound&&s.each(n.nodes(),function(t){n.setParent(t,e(t))}),n},n.prototype.setDefaultEdgeLabel=function(t){return s.isFunction(t)||(t=s.constant(t)),this._defaultEdgeLabelFn=t,this},n.prototype.edgeCount=function(){return this._edgeCount},n.prototype.edges=function(){return s.values(this._edgeObjs)},n.prototype.setPath=function(t,e){var n=this,r=arguments;return s.reduce(t,function(t,i){return r.length>1?n.setEdge(t,i,e):n.setEdge(t,i),i}),this},n.prototype.setEdge=function(){var t,e,n,i,o=!1,c=arguments[0];"object"==typeof c&&null!==c&&"v"in c?(t=c.v,e=c.w,n=c.name,2===arguments.length&&(i=arguments[1],o=!0)):(t=c,e=arguments[1],n=arguments[3],arguments.length>2&&(i=arguments[2],o=!0)),t=""+t,e=""+e,s.isUndefined(n)||(n=""+n);var l=a(this._isDirected,t,e,n);if(s.has(this._edgeLabels,l))return o&&(this._edgeLabels[l]=i),this;if(!s.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[l]=o?i:this._defaultEdgeLabelFn(t,e,n);var h=u(this._isDirected,t,e,n);return t=h.v,e=h.w,Object.freeze(h),this._edgeObjs[l]=h,r(this._preds[e],t),r(this._sucs[t],e),this._in[e][l]=h,this._out[t][l]=h,this._edgeCount++,this},n.prototype.edge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return this._edgeLabels[r]},n.prototype.hasEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return s.has(this._edgeLabels,r)},n.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n),u=this._edgeObjs[r];return u&&(t=u.v,e=u.w,delete this._edgeLabels[r],delete this._edgeObjs[r],i(this._preds[e],t),i(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},n.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var r=s.values(n);return e?s.filter(r,function(t){return t.v===e}):r}},n.prototype.outEdges=function(t,e){var n=this._out[t];if(n){var r=s.values(n);return e?s.filter(r,function(t){return t.w===e}):r}},n.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);return n?n.concat(this.outEdges(t,e)):void 0}},{"./lodash":51}],49:[function(t,e){e.exports={Graph:t("./graph"),version:t("./version")}},{"./graph":48,"./version":52}],50:[function(t,e){function n(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:r(t),edges:i(t)};return u.isUndefined(t.graph())||(e.value=u.clone(t.graph())),e}function r(t){return u.map(t.nodes(),function(e){var n=t.node(e),r=t.parent(e),i={v:e};return u.isUndefined(n)||(i.value=n),u.isUndefined(r)||(i.parent=r),i})}function i(t){return u.map(t.edges(),function(e){var n=t.edge(e),r={v:e.v,w:e.w};return u.isUndefined(e.name)||(r.name=e.name),u.isUndefined(n)||(r.value=n),r})}function a(t){var e=new o(t.options).setGraph(t.value);return u.each(t.nodes,function(t){e.setNode(t.v,t.value),t.parent&&e.setParent(t.v,t.parent)}),u.each(t.edges,function(t){e.setEdge({v:t.v,w:t.w,name:t.name},t.value)}),e}var u=t("./lodash"),o=t("./graph");e.exports={write:n,read:a}},{"./graph":48,"./lodash":51}],51:[function(t,e){var n;if("function"==typeof t)try{n=t("lodash")}catch(r){}n||(n=window._),e.exports=n},{lodash:53}],52:[function(t,e){e.exports="1.0.7"},{}],53:[function(t,e,n){(function(t){(function(){function r(t,e){if(t!==e){var n=null===t,r=t===k,i=t===t,a=null===e,u=e===k,o=e===e;if(t>e&&!a||!i||n&&!u&&o||r&&o)return 1;if(e>t&&!n||!o||a&&!r&&i||u&&i)return-1}return 0}function i(t,e,n){for(var r=t.length,i=n?r:-1;n?i--:++i-1;);return n}function c(t,e){for(var n=t.length;n--&&e.indexOf(t.charAt(n))>-1;);return n}function l(t,e){return r(t.criteria,e.criteria)||t.index-e.index}function h(t,e,n){for(var i=-1,a=t.criteria,u=e.criteria,o=a.length,s=n.length;++i=s)return c;var l=n[i];return c*("asc"===l||l===!0?1:-1)}}return t.index-e.index}function f(t){return Vt[t]}function d(t){return $t[t]}function p(t,e,n){return e?t=Wt[t]:n&&(t=Zt[t]),"\\"+t}function g(t){return"\\"+Zt[t]}function y(t,e,n){for(var r=t.length,i=e+(n?0:-1);n?i--:++i=t&&t>=9&&13>=t||32==t||160==t||5760==t||6158==t||t>=8192&&(8202>=t||8232==t||8233==t||8239==t||8287==t||12288==t||65279==t)}function b(t,e){for(var n=-1,r=t.length,i=-1,a=[];++ne,i=n?t.length:0,a=Gn(0,i,this.__views__),u=a.start,o=a.end,s=o-u,c=r?o:u-1,l=this.__iteratees__,h=l.length,f=0,d=wu(s,this.__takeCount__);if(!n||j>i||i==s&&d==s)return nn(r&&n?t.reverse():t,this.__actions__);var p=[];t:for(;s--&&d>f;){c+=e;for(var g=-1,y=t[c];++g=j?gn(e):null,c=e.length;s&&(u=Jt,o=!1,e=s);t:for(;++in&&(n=-n>i?0:i+n),r=r===k||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 Ce(t,e){var n=[];return Ou(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}function Me(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 Se(t,e,n,r){r||(r=[]);for(var i=-1,a=t.length;++ir;)t=t[e[r++]];return r&&r==i?t:k}}function Oe(t,e,n,r,i,a){return t===e?!0:null==t||null==e||!Ni(t)&&!m(e)?t!==t&&e!==e:Ie(t,e,Oe,n,r,i,a)}function Ie(t,e,n,r,i,a,u){var o=So(t),s=So(e),c=G,l=G;o||(c=nu.call(t),c==$?c=Q:c!=Q&&(o=zi(t))),s||(l=nu.call(e),l==$?l=Q:l!=Q&&(s=zi(e)));var h=c==Q,f=l==Q,d=c==l;if(d&&!o&&!h)return qn(t,e,c);if(!i){var p=h&&tu.call(t,"__wrapped__"),g=f&&tu.call(e,"__wrapped__");if(p||g)return n(p?t.value():t,g?e.value():e,r,i,a,u)}if(!d)return!1;a||(a=[]),u||(u=[]);for(var y=a.length;y--;)if(a[y]==t)return u[y]==e;a.push(t),u.push(e); -var m=(o?Rn:jn)(t,e,n,r,i,a,u);return a.pop(),u.pop(),m}function Pe(t,e,n){var r=e.length,i=r,a=!n;if(null==t)return!i;for(t=hr(t);r--;){var u=e[r];if(a&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++re&&(e=-e>i?0:i+e),n=n===k||n>i?i:+n||0,0>n&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var a=ja(i);++r=j,s=o?gn():null,c=[];s?(r=Kt,u=!1):(o=!1,s=e?[]:c);t:for(;++n=i){for(;i>r;){var a=r+i>>>1,u=t[a];(n?e>=u:e>u)&&null!==u?r=a+1:i=a}return i}return an(t,e,Ca,n)}function an(t,e,n,r){e=n(e);for(var i=0,a=t?t.length:0,u=e!==e,o=null===e,s=e===k;a>i;){var c=mu((i+a)/2),l=n(t[c]),h=l!==k,f=l===l;if(u)var d=f||r;else d=o?f&&h&&(r||null!=l):s?f&&(r||h):null==l?!1:r?e>=l:e>l;d?i=c+1:a=c}return wu(a,Su)}function un(t,e,n){if("function"!=typeof t)return Ca;if(e===k)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,r,i){return t.call(e,n,r,i)};case 4:return function(n,r,i,a){return t.call(e,n,r,i,a)};case 5:return function(n,r,i,a,u){return t.call(e,n,r,i,a,u)}}return function(){return t.apply(e,arguments)}}function on(t){var e=new au(t.byteLength),n=new du(e);return n.set(new du(t)),e}function sn(t,e,n){for(var r=n.length,i=-1,a=xu(t.length-r,0),u=-1,o=e.length,s=ja(o+a);++u2?n[i-2]:k,u=i>2?n[2]:k,o=i>1?n[i-1]:k;for("function"==typeof a?(a=un(a,o,5),i-=2):(a="function"==typeof o?o:k,i-=a?1:0),u&&Qn(n[0],n[1],u)&&(a=3>i?k:a,i=1);++r-1?n[u]:k}return Me(n,r,t)}}function wn(t){return function(e,n,r){return e&&e.length?(n=Un(n,r,3),i(e,n,t)):-1}}function An(t){return function(e,n,r){return n=Un(n,r,3),Me(e,n,t,!0)}}function En(t){return function(){for(var e,n=arguments.length,r=t?n:-1,i=0,a=ja(n);t?r--:++r=j)return e.plant(r).value();for(var i=0,u=n?a[i].apply(this,t):r;++iv){var E=o?te(o):k,D=xu(c-v,0),S=p?A:k,T=p?k:A,F=p?x:k,O=p?k:x;e|=p?B:L,e&=~(p?L:B),g||(e&=~(C|M));var N=[t,e,n,F,S,O,T,E,s,D],I=Bn.apply(k,N);return er(t)&&Yu(I,N),I.placeholder=w,I}}var P=f?n:this,R=d?P[t]:t;return o&&(x=sr(x,o)),h&&s=e||!bu(e))return"";var i=e-r;return n=null==n?" ":n+"",ya(n,gu(i/n.length)).slice(0,i)}function On(t,e,n,r){function i(){for(var e=-1,o=arguments.length,s=-1,c=r.length,l=ja(c+o);++ss))return!1;for(;++o-1&&t%1==0&&e>t}function Qn(t,e,n){if(!Oi(n))return!1;var r=typeof e;if("number"==r?Kn(n)&&Jn(e,n.length):"string"==r&&e in n){var i=n[e];return t===t?t===i:i!==i}return!1}function tr(t,e){var n=typeof t;if("string"==n&&kt.test(t)||"number"==n)return!0;if(So(t))return!1;var r=!Et.test(t);return r||null!=e&&t in hr(e)}function er(t){var n=Yn(t);if(!(n in K.prototype))return!1;var r=e[n];if(t===r)return!0;var i=ju(r);return!!i&&t===i[0]}function nr(t){return"number"==typeof t&&t>-1&&t%1==0&&Fu>=t}function rr(t){return t===t&&!Oi(t)}function ir(t,e){var n=t[1],r=e[1],i=n|r,a=O>i,u=r==O&&n==T||r==O&&n==N&&t[7].length<=e[8]||r==(O|N)&&n==T;if(!a&&!u)return t;r&C&&(t[2]=e[2],i|=n&C?0:S);var o=e[3];if(o){var s=t[3];t[3]=s?sn(s,o,e[4]):te(o),t[4]=s?b(t[3],V):te(e[4])}return o=e[5],o&&(s=t[5],t[5]=s?cn(s,o,e[6]):te(o),t[6]=s?b(t[5],V):te(e[6])),o=e[7],o&&(t[7]=te(o)),r&O&&(t[8]=null==t[8]?e[8]:wu(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i,t}function ar(t,e){return t===k?e:To(t,e,ar)}function ur(t,e){t=hr(t);for(var n=-1,r=e.length,i={};++nr;)u[++a]=We(t,r,r+=e);return u}function gr(t){for(var e=-1,n=t?t.length:0,r=-1,i=[];++ee?0:e)):[]}function mr(t,e,n){var r=t?t.length:0;return r?((n?Qn(t,e,n):null==e)&&(e=1),e=r-(+e||0),We(t,0,0>e?0:e)):[]}function vr(t,e,n){return t&&t.length?en(t,Un(e,n,3),!0,!0):[]}function br(t,e,n){return t&&t.length?en(t,Un(e,n,3),!0):[]}function _r(t,e,n,r){var i=t?t.length:0;return i?(n&&"number"!=typeof n&&Qn(t,e,n)&&(n=0,r=i),De(t,e,n,r)):[]}function xr(t){return t?t[0]:k}function wr(t,e,n){var r=t?t.length:0;return n&&Qn(t,e,n)&&(e=!1),r?Se(t,e):[]}function Ar(t){var e=t?t.length:0;return e?Se(t,!0):[]}function Er(t,e,n){var r=t?t.length:0;if(!r)return-1;if("number"==typeof n)n=0>n?xu(r+n,0):n;else if(n){var i=rn(t,e);return r>i&&(e===e?e===t[i]:t[i]!==t[i])?i:-1}return a(t,e,n||0)}function kr(t){return mr(t,1)}function Dr(t){var e=t?t.length:0;return e?t[e-1]:k}function Cr(t,e,n){var r=t?t.length:0;if(!r)return-1;var i=r;if("number"==typeof n)i=(0>n?xu(r+n,0):wu(n||0,r-1))+1;else if(n){i=rn(t,e,!0)-1;var a=t[i];return(e===e?e===a:a!==a)?i:-1}if(e!==e)return y(t,i,!0);for(;i--;)if(t[i]===e)return i;return-1}function Mr(){var t=arguments,e=t[0];if(!e||!e.length)return e;for(var n=0,r=zn(),i=t.length;++n-1;)fu.call(e,a,1);return e}function Sr(t,e,n){var r=[];if(!t||!t.length)return r;var i=-1,a=[],u=t.length;for(e=Un(e,n,3);++ie?0:e)):[]}function Lr(t,e,n){var r=t?t.length:0;return r?((n?Qn(t,e,n):null==e)&&(e=1),e=r-(+e||0),We(t,0>e?0:e)):[]}function Or(t,e,n){return t&&t.length?en(t,Un(e,n,3),!1,!0):[]}function Nr(t,e,n){return t&&t.length?en(t,Un(e,n,3)):[]}function Ir(t,e,n,r){var i=t?t.length:0;if(!i)return[];null!=e&&"boolean"!=typeof e&&(r=n,n=Qn(t,e,r)?k:e,e=!1);var u=Un();return(null!=n||u!==_e)&&(n=u(n,r,3)),e&&zn()==a?_(t,n):Qe(t,n)}function Pr(t){if(!t||!t.length)return[];var e=-1,n=0;t=oe(t,function(t){return Kn(t)?(n=xu(t.length,n),!0):void 0});for(var r=ja(n);++en?xu(i+n,0):n||0,"string"==typeof t||!So(t)&&Yi(t)?i>=n&&t.indexOf(e,n)>-1:!!i&&zn(t,e,n)>-1}function ti(t,e,n){var r=So(t)?se:Re;return e=Un(e,n,3),r(t,e)}function ei(t,e){return ti(t,La(e))}function ni(t,e,n){var r=So(t)?oe:Ce;return e=Un(e,n,3),r(t,function(t,n,r){return!e(t,n,r)})}function ri(t,e,n){if(n?Qn(t,e,n):null==e){t=lr(t);var r=t.length;return r>0?t[Ge(0,r-1)]:k}var i=-1,a=Hi(t),r=a.length,u=r-1;for(e=wu(0>e?0:+e||0,r);++i0&&(n=e.apply(this,arguments)),1>=t&&(e=k),n}}function di(t,e,n){function r(){d&&uu(d),c&&uu(c),g=0,c=d=p=k}function i(e,n){n&&uu(n),c=d=p=k,e&&(g=go(),l=t.apply(f,s),d||c||(s=f=k))}function a(){var t=e-(go()-h);0>=t||t>e?i(p,c):d=hu(a,t)}function u(){i(m,d)}function o(){if(s=arguments,h=go(),f=this,p=m&&(d||!v),y===!1)var n=v&&!d;else{c||v||(g=h);var r=y-(h-g),i=0>=r||r>y;i?(c&&(c=uu(c)),g=h,l=t.apply(f,s)):c||(c=hu(u,r))}return i&&d?d=uu(d):d||e===y||(d=hu(a,e)),n&&(i=!0,l=t.apply(f,s)),!i||d||c||(s=f=k),l}var s,c,l,h,f,d,p,g=0,y=!1,m=!0;if("function"!=typeof t)throw new Za(z);if(e=0>e?0:+e||0,n===!0){var v=!0;m=!1}else Oi(n)&&(v=!!n.leading,y="maxWait"in n&&xu(+n.maxWait||0,e),m="trailing"in n?!!n.trailing:m);return o.cancel=r,o}function pi(t,e){if("function"!=typeof t||e&&"function"!=typeof e)throw new Za(z);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 u=t.apply(this,r);return n.cache=a.set(i,u),u};return n.cache=new pi.Cache,n}function gi(t){if("function"!=typeof t)throw new Za(z);return function(){return!t.apply(this,arguments)}}function yi(t){return fi(2,t)}function mi(t,e){if("function"!=typeof t)throw new Za(z);return e=xu(e===k?t.length-1:+e||0,0),function(){for(var n=arguments,r=-1,i=xu(n.length-e,0),a=ja(i);++re}function Ei(t,e){return t>=e}function ki(t){return m(t)&&Kn(t)&&tu.call(t,"callee")&&!cu.call(t,"callee")}function Di(t){return t===!0||t===!1||m(t)&&nu.call(t)==H}function Ci(t){return m(t)&&nu.call(t)==W}function Mi(t){return!!t&&1===t.nodeType&&m(t)&&!ji(t)}function Si(t){return null==t?!0:Kn(t)&&(So(t)||Yi(t)||ki(t)||m(t)&&Li(t.splice))?!t.length:!jo(t).length}function Ti(t,e,n,r){n="function"==typeof n?un(n,r,3):k;var i=n?n(t,e):k;return i===k?Ne(t,e,n):!!i}function Fi(t){return m(t)&&"string"==typeof t.message&&nu.call(t)==Z}function Bi(t){return"number"==typeof t&&bu(t)}function Li(t){return Oi(t)&&nu.call(t)==X}function Oi(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function Ni(t,e,n,r){return n="function"==typeof n?un(n,r,3):k,Pe(t,Vn(e),n)}function Ii(t){return qi(t)&&t!=+t}function Pi(t){return null==t?!1:Li(t)?iu.test(Qa.call(t)):m(t)&&Ot.test(t)}function Ri(t){return null===t}function qi(t){return"number"==typeof t||m(t)&&nu.call(t)==J}function ji(t){var e;if(!m(t)||nu.call(t)!=Q||ki(t)||!tu.call(t,"constructor")&&(e=t.constructor,"function"==typeof e&&!(e instanceof e)))return!1;var n;return Te(t,function(t,e){n=e}),n===k||tu.call(t,n)}function Ui(t){return Oi(t)&&nu.call(t)==tt}function Yi(t){return"string"==typeof t||m(t)&&nu.call(t)==nt}function zi(t){return m(t)&&nr(t.length)&&!!Yt[nu.call(t)]}function Vi(t){return t===k}function $i(t,e){return e>t}function Gi(t,e){return e>=t}function Hi(t){var e=t?Uu(t):0;return nr(e)?e?te(t):[]:aa(t)}function Wi(t){return be(t,ta(t))}function Zi(t,e,n){var r=Ou(t);return n&&Qn(t,e,n)&&(e=k),e?me(r,e):r}function Xi(t){return Le(t,ta(t))}function Ki(t,e,n){var r=null==t?k:Oe(t,fr(e),e+"");return r===k?n:r}function Ji(t,e){if(null==t)return!1;var n=tu.call(t,e);if(!n&&!tr(e)){if(e=fr(e),t=1==e.length?t:Oe(t,We(e,0,-1)),null==t)return!1;e=Dr(e),n=tu.call(t,e)}return n||nr(t.length)&&Jn(e,t.length)&&(So(t)||ki(t))}function Qi(t,e,n){n&&Qn(t,e,n)&&(e=k);for(var r=-1,i=jo(t),a=i.length,u={};++r0;++r=wu(e,n)&&tn?0:+n||0,r),n-=e.length,n>=0&&t.indexOf(e,n)==n}function fa(t){return t=o(t),t&&_t.test(t)?t.replace(vt,d):t}function da(t){return t=o(t),t&&Mt.test(t)?t.replace(Ct,p):t||"(?:)"}function pa(t,e,n){t=o(t),e=+e;var r=t.length;if(r>=e||!bu(e))return t;var i=(e-r)/2,a=mu(i),u=gu(i);return n=Ln("",u,n),n.slice(0,a)+t+n}function ga(t,e,n){return(n?Qn(t,e,n):null==e)?e=0:e&&(e=+e),t=ba(t),Eu(t,e||(Lt.test(t)?16:10))}function ya(t,e){var n="";if(t=o(t),e=+e,1>e||!t||!bu(e))return n;do e%2&&(n+=t),e=mu(e/2),t+=t;while(e);return n}function ma(t,e,n){return t=o(t),n=null==n?0:wu(0>n?0:+n||0,t.length),t.lastIndexOf(e,n)==n}function va(t,n,r){var i=e.templateSettings;r&&Qn(t,n,r)&&(n=r=k),t=o(t),n=ye(me({},r||n),i,ge);var a,u,s=ye(me({},n.imports),i.imports,ge),c=jo(s),l=tn(s,c),h=0,f=n.interpolate||Pt,d="__p += '",p=Ha((n.escape||Pt).source+"|"+f.source+"|"+(f===At?Ft:Pt).source+"|"+(n.evaluate||Pt).source+"|$","g"),y="//# sourceURL="+("sourceURL"in n?n.sourceURL:"lodash.templateSources["+ ++Ut+"]")+"\n";t.replace(p,function(e,n,r,i,o,s){return r||(r=i),d+=t.slice(h,s).replace(Rt,g),n&&(a=!0,d+="' +\n__e("+n+") +\n'"),o&&(u=!0,d+="';\n"+o+";\n__p += '"),r&&(d+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),h=s+e.length,e}),d+="';\n";var m=n.variable;m||(d="with (obj) {\n"+d+"\n}\n"),d=(u?d.replace(pt,""):d).replace(gt,"$1").replace(yt,"$1;"),d="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(a?", __e = _.escape":"")+(u?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+d+"return __p\n}";var v=Ko(function(){return za(c,y+"return "+d).apply(k,l)});if(v.source=d,Fi(v))throw v;return v}function ba(t,e,n){var r=t;return(t=o(t))?(n?Qn(r,e,n):null==e)?t.slice(x(t),w(t)+1):(e+="",t.slice(s(t,e),c(t,e)+1)):t}function _a(t,e,n){var r=t;return t=o(t),t?t.slice((n?Qn(r,e,n):null==e)?x(t):s(t,e+"")):t}function xa(t,e,n){var r=t;return t=o(t),t?(n?Qn(r,e,n):null==e)?t.slice(0,w(t)+1):t.slice(0,c(t,e+"")+1):t}function wa(t,e,n){n&&Qn(t,e,n)&&(e=k);var r=I,i=P;if(null!=e)if(Oi(e)){var a="separator"in e?e.separator:a;r="length"in e?+e.length||0:r,i="omission"in e?o(e.omission):i}else r=+e||0;if(t=o(t),r>=t.length)return t;var u=r-i.length;if(1>u)return i;var s=t.slice(0,u);if(null==a)return s+i;if(Ui(a)){if(t.slice(u).search(a)){var c,l,h=t.slice(0,u);for(a.global||(a=Ha(a.source,(Bt.exec(a)||"")+"g")),a.lastIndex=0;c=a.exec(h);)l=c.index;s=s.slice(0,null==l?u:l)}}else if(t.indexOf(a,u)!=u){var f=s.lastIndexOf(a);f>-1&&(s=s.slice(0,f))}return s+i}function Aa(t){return t=o(t),t&&bt.test(t)?t.replace(mt,A):t}function Ea(t,e,n){return n&&Qn(t,e,n)&&(e=k),t=o(t),t.match(e||qt)||[]}function ka(t,e,n){return n&&Qn(t,e,n)&&(e=k),m(t)?Ma(t):_e(t,e)}function Da(t){return function(){return t}}function Ca(t){return t}function Ma(t){return qe(xe(t,!0))}function Sa(t,e){return je(t,xe(e,!0))}function Ta(t,e,n){if(null==n){var r=Oi(e),i=r?jo(e):k,a=i&&i.length?Le(e,i):k;(a?a.length:r)||(a=!1,n=e,e=t,t=this)}a||(a=Le(e,jo(e)));var u=!0,o=-1,s=Li(t),c=a.length;n===!1?u=!1:Oi(n)&&"chain"in n&&(u=n.chain);for(;++ot||!bu(t))return[];var r=-1,i=ja(wu(t,Mu));for(e=un(e,n,1);++rr?i[r]=e(r):e(r);return i}function Pa(t){var e=++eu;return o(t)+e}function Ra(t,e){return(+t||0)+(+e||0)}function qa(t,e,n){return n&&Qn(t,e,n)&&(e=k),e=Un(e,n,3),1==e.length?de(So(t)?t:lr(t),e):Je(t,e)}t=t?re.defaults(ne.Object(),t,re.pick(ne,jt)):ne;{var ja=t.Array,Ua=t.Date,Ya=t.Error,za=t.Function,Va=t.Math,$a=t.Number,Ga=t.Object,Ha=t.RegExp,Wa=t.String,Za=t.TypeError,Xa=ja.prototype,Ka=Ga.prototype,Ja=Wa.prototype,Qa=za.prototype.toString,tu=Ka.hasOwnProperty,eu=0,nu=Ka.toString,ru=ne._,iu=Ha("^"+Qa.call(tu).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),au=t.ArrayBuffer,uu=t.clearTimeout,ou=t.parseFloat,su=Va.pow,cu=Ka.propertyIsEnumerable,lu=$n(t,"Set"),hu=t.setTimeout,fu=Xa.splice,du=t.Uint8Array,pu=$n(t,"WeakMap"),gu=Va.ceil,yu=$n(Ga,"create"),mu=Va.floor,vu=$n(ja,"isArray"),bu=t.isFinite,_u=$n(Ga,"keys"),xu=Va.max,wu=Va.min,Au=$n(Ua,"now"),Eu=t.parseInt,ku=Va.random,Du=$a.NEGATIVE_INFINITY,Cu=$a.POSITIVE_INFINITY,Mu=4294967295,Su=Mu-1,Tu=Mu>>>1,Fu=9007199254740991,Bu=pu&&new pu,Lu={};e.support={}}e.templateSettings={escape:xt,evaluate:wt,interpolate:At,variable:"",imports:{_:e}};var Ou=function(){function t(){}return function(e){if(Oi(e)){t.prototype=e;var n=new t;t.prototype=k}return n||{}}}(),Nu=fn(Fe),Iu=fn(Be,!0),Pu=dn(),Ru=dn(!0),qu=Bu?function(t,e){return Bu.set(t,e),t}:Ca,ju=Bu?function(t){return Bu.get(t)}:Ba,Uu=ze("length"),Yu=function(){var t=0,e=0;return function(n,r){var i=go(),a=q-(i-e);if(e=i,a>0){if(++t>=R)return n}else t=0;return qu(n,r)}}(),zu=mi(function(t,e){return m(t)&&Kn(t)?Ae(t,Se(e,!1,!0)):[]}),Vu=wn(),$u=wn(!0),Gu=mi(function(t){for(var e=t.length,n=e,r=ja(h),i=zn(),u=i==a,o=[];n--;){var s=t[n]=Kn(s=t[n])?s:[];r[n]=u&&s.length>=120?gn(n&&s):null}var c=t[0],l=-1,h=c?c.length:0,f=r[0];t:for(;++l2?t[e-2]:k,r=e>1?t[e-1]:k;return e>2&&"function"==typeof n?e-=2:(n=e>1&&"function"==typeof r?(--e,r):k,r=k),t.length=e,Rr(t,n,r)}),to=mi(function(t){return t=Se(t),this.thru(function(e){return Qt(So(e)?e:[hr(e)],t)})}),eo=mi(function(t,e){return ve(t,Se(e))}),no=ln(function(t,e,n){tu.call(t,n)?++t[n]:t[n]=1}),ro=xn(Nu),io=xn(Iu,!0),ao=kn(ee,Nu),uo=kn(ie,Iu),oo=ln(function(t,e,n){tu.call(t,n)?t[n].push(e):t[n]=[e]}),so=ln(function(t,e,n){t[n]=e}),co=mi(function(t,e,n){var r=-1,i="function"==typeof e,a=tr(e),u=Kn(t)?ja(t.length):[];return Nu(t,function(t){var o=i?e:a&&null!=t?t[e]:k;u[++r]=o?o.apply(t,n):Xn(t,e,n)}),u}),lo=ln(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),ho=Fn(le,Nu),fo=Fn(he,Iu),po=mi(function(t,e){if(null==t)return[];var n=e[2];return n&&Qn(e[0],e[1],n)&&(e.length=1),Ke(t,Se(e),[])}),go=Au||function(){return(new Ua).getTime()},yo=mi(function(t,e,n){var r=C;if(n.length){var i=b(n,yo.placeholder);r|=B}return Pn(t,r,e,n,i)}),mo=mi(function(t,e){e=e.length?Se(e):Xi(t);for(var n=-1,r=e.length;++ne&&(e=-e>i?0:i+e),n=n===k||n>i?i:+n||0,0>n&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var a=ja(i);++r=j,s=o?gn():null,c=[];s?(r=Jt,u=!1):(o=!1,s=e?[]:c);t:for(;++n=i){for(;i>r;){var a=r+i>>>1,u=t[a];(n?e>=u:e>u)&&null!==u?r=a+1:i=a}return i}return an(t,e,Ca,n)}function an(t,e,n,r){e=n(e);for(var i=0,a=t?t.length:0,u=e!==e,o=null===e,s=e===k;a>i;){var c=mu((i+a)/2),l=n(t[c]),h=l!==k,f=l===l;if(u)var d=f||r;else d=o?f&&h&&(r||null!=l):s?f&&(r||h):null==l?!1:r?e>=l:e>l;d?i=c+1:a=c}return wu(a,Su)}function un(t,e,n){if("function"!=typeof t)return Ca;if(e===k)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,r,i){return t.call(e,n,r,i)};case 4:return function(n,r,i,a){return t.call(e,n,r,i,a)};case 5:return function(n,r,i,a,u){return t.call(e,n,r,i,a,u)}}return function(){return t.apply(e,arguments)}}function on(t){var e=new au(t.byteLength),n=new du(e);return n.set(new du(t)),e}function sn(t,e,n){for(var r=n.length,i=-1,a=xu(t.length-r,0),u=-1,o=e.length,s=ja(o+a);++u2?n[i-2]:k,u=i>2?n[2]:k,o=i>1?n[i-1]:k;for("function"==typeof a?(a=un(a,o,5),i-=2):(a="function"==typeof o?o:k,i-=a?1:0),u&&Qn(n[0],n[1],u)&&(a=3>i?k:a,i=1);++r-1?n[u]:k}return Me(n,r,t)}}function wn(t){return function(e,n,r){return e&&e.length?(n=Un(n,r,3),i(e,n,t)):-1}}function An(t){return function(e,n,r){return n=Un(n,r,3),Me(e,n,t,!0)}}function En(t){return function(){for(var e,n=arguments.length,r=t?n:-1,i=0,a=ja(n);t?r--:++r=j)return e.plant(r).value();for(var i=0,u=n?a[i].apply(this,t):r;++iv){var E=o?te(o):k,D=xu(c-v,0),S=p?A:k,T=p?k:A,F=p?x:k,N=p?k:x;e|=p?B:L,e&=~(p?L:B),g||(e&=~(C|M));var O=[t,e,n,F,S,N,T,E,s,D],I=Bn.apply(k,O);return er(t)&&Yu(I,O),I.placeholder=w,I}}var R=f?n:this,P=d?R[t]:t;return o&&(x=sr(x,o)),h&&s=e||!bu(e))return"";var i=e-r;return n=null==n?" ":n+"",ya(n,gu(i/n.length)).slice(0,i)}function Nn(t,e,n,r){function i(){for(var e=-1,o=arguments.length,s=-1,c=r.length,l=ja(c+o);++ss))return!1;for(;++o-1&&t%1==0&&e>t}function Qn(t,e,n){if(!Ni(n))return!1;var r=typeof e;if("number"==r?Jn(n)&&Kn(e,n.length):"string"==r&&e in n){var i=n[e];return t===t?t===i:i!==i}return!1}function tr(t,e){var n=typeof t;if("string"==n&&kt.test(t)||"number"==n)return!0;if(So(t))return!1;var r=!Et.test(t);return r||null!=e&&t in hr(e)}function er(t){var n=Yn(t);if(!(n in J.prototype))return!1;var r=e[n];if(t===r)return!0;var i=ju(r);return!!i&&t===i[0]}function nr(t){return"number"==typeof t&&t>-1&&t%1==0&&Fu>=t}function rr(t){return t===t&&!Ni(t)}function ir(t,e){var n=t[1],r=e[1],i=n|r,a=N>i,u=r==N&&n==T||r==N&&n==O&&t[7].length<=e[8]||r==(N|O)&&n==T;if(!a&&!u)return t;r&C&&(t[2]=e[2],i|=n&C?0:S);var o=e[3];if(o){var s=t[3];t[3]=s?sn(s,o,e[4]):te(o),t[4]=s?b(t[3],V):te(e[4])}return o=e[5],o&&(s=t[5],t[5]=s?cn(s,o,e[6]):te(o),t[6]=s?b(t[5],V):te(e[6])),o=e[7],o&&(t[7]=te(o)),r&N&&(t[8]=null==t[8]?e[8]:wu(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i,t}function ar(t,e){return t===k?e:To(t,e,ar)}function ur(t,e){t=hr(t);for(var n=-1,r=e.length,i={};++nr;)u[++a]=We(t,r,r+=e);return u}function gr(t){for(var e=-1,n=t?t.length:0,r=-1,i=[];++ee?0:e)):[]}function mr(t,e,n){var r=t?t.length:0;return r?((n?Qn(t,e,n):null==e)&&(e=1),e=r-(+e||0),We(t,0,0>e?0:e)):[]}function vr(t,e,n){return t&&t.length?en(t,Un(e,n,3),!0,!0):[]}function br(t,e,n){return t&&t.length?en(t,Un(e,n,3),!0):[]}function _r(t,e,n,r){var i=t?t.length:0;return i?(n&&"number"!=typeof n&&Qn(t,e,n)&&(n=0,r=i),De(t,e,n,r)):[]}function xr(t){return t?t[0]:k}function wr(t,e,n){var r=t?t.length:0;return n&&Qn(t,e,n)&&(e=!1),r?Se(t,e):[]}function Ar(t){var e=t?t.length:0;return e?Se(t,!0):[]}function Er(t,e,n){var r=t?t.length:0;if(!r)return-1;if("number"==typeof n)n=0>n?xu(r+n,0):n;else if(n){var i=rn(t,e);return r>i&&(e===e?e===t[i]:t[i]!==t[i])?i:-1}return a(t,e,n||0)}function kr(t){return mr(t,1)}function Dr(t){var e=t?t.length:0;return e?t[e-1]:k}function Cr(t,e,n){var r=t?t.length:0;if(!r)return-1;var i=r;if("number"==typeof n)i=(0>n?xu(r+n,0):wu(n||0,r-1))+1;else if(n){i=rn(t,e,!0)-1;var a=t[i];return(e===e?e===a:a!==a)?i:-1}if(e!==e)return y(t,i,!0);for(;i--;)if(t[i]===e)return i;return-1}function Mr(){var t=arguments,e=t[0];if(!e||!e.length)return e;for(var n=0,r=zn(),i=t.length;++n-1;)fu.call(e,a,1);return e}function Sr(t,e,n){var r=[];if(!t||!t.length)return r;var i=-1,a=[],u=t.length;for(e=Un(e,n,3);++ie?0:e)):[]}function Lr(t,e,n){var r=t?t.length:0;return r?((n?Qn(t,e,n):null==e)&&(e=1),e=r-(+e||0),We(t,0>e?0:e)):[]}function Nr(t,e,n){return t&&t.length?en(t,Un(e,n,3),!1,!0):[]}function Or(t,e,n){return t&&t.length?en(t,Un(e,n,3)):[]}function Ir(t,e,n,r){var i=t?t.length:0;if(!i)return[];null!=e&&"boolean"!=typeof e&&(r=n,n=Qn(t,e,r)?k:e,e=!1);var u=Un();return(null!=n||u!==_e)&&(n=u(n,r,3)),e&&zn()==a?_(t,n):Qe(t,n)}function Rr(t){if(!t||!t.length)return[];var e=-1,n=0;t=oe(t,function(t){return Jn(t)?(n=xu(t.length,n),!0):void 0});for(var r=ja(n);++en?xu(i+n,0):n||0,"string"==typeof t||!So(t)&&Yi(t)?i>=n&&t.indexOf(e,n)>-1:!!i&&zn(t,e,n)>-1}function ti(t,e,n){var r=So(t)?se:Pe;return e=Un(e,n,3),r(t,e)}function ei(t,e){return ti(t,La(e))}function ni(t,e,n){var r=So(t)?oe:Ce;return e=Un(e,n,3),r(t,function(t,n,r){return!e(t,n,r)})}function ri(t,e,n){if(n?Qn(t,e,n):null==e){t=lr(t);var r=t.length;return r>0?t[Ge(0,r-1)]:k}var i=-1,a=Hi(t),r=a.length,u=r-1;for(e=wu(0>e?0:+e||0,r);++i0&&(n=e.apply(this,arguments)),1>=t&&(e=k),n}}function di(t,e,n){function r(){d&&uu(d),c&&uu(c),g=0,c=d=p=k}function i(e,n){n&&uu(n),c=d=p=k,e&&(g=go(),l=t.apply(f,s),d||c||(s=f=k))}function a(){var t=e-(go()-h);0>=t||t>e?i(p,c):d=hu(a,t)}function u(){i(m,d)}function o(){if(s=arguments,h=go(),f=this,p=m&&(d||!v),y===!1)var n=v&&!d;else{c||v||(g=h);var r=y-(h-g),i=0>=r||r>y;i?(c&&(c=uu(c)),g=h,l=t.apply(f,s)):c||(c=hu(u,r))}return i&&d?d=uu(d):d||e===y||(d=hu(a,e)),n&&(i=!0,l=t.apply(f,s)),!i||d||c||(s=f=k),l}var s,c,l,h,f,d,p,g=0,y=!1,m=!0;if("function"!=typeof t)throw new Za(z);if(e=0>e?0:+e||0,n===!0){var v=!0;m=!1}else Ni(n)&&(v=!!n.leading,y="maxWait"in n&&xu(+n.maxWait||0,e),m="trailing"in n?!!n.trailing:m);return o.cancel=r,o}function pi(t,e){if("function"!=typeof t||e&&"function"!=typeof e)throw new Za(z);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 u=t.apply(this,r);return n.cache=a.set(i,u),u};return n.cache=new pi.Cache,n}function gi(t){if("function"!=typeof t)throw new Za(z);return function(){return!t.apply(this,arguments)}}function yi(t){return fi(2,t)}function mi(t,e){if("function"!=typeof t)throw new Za(z);return e=xu(e===k?t.length-1:+e||0,0),function(){for(var n=arguments,r=-1,i=xu(n.length-e,0),a=ja(i);++re}function Ei(t,e){return t>=e}function ki(t){return m(t)&&Jn(t)&&tu.call(t,"callee")&&!cu.call(t,"callee")}function Di(t){return t===!0||t===!1||m(t)&&nu.call(t)==H}function Ci(t){return m(t)&&nu.call(t)==W}function Mi(t){return!!t&&1===t.nodeType&&m(t)&&!ji(t)}function Si(t){return null==t?!0:Jn(t)&&(So(t)||Yi(t)||ki(t)||m(t)&&Li(t.splice))?!t.length:!jo(t).length}function Ti(t,e,n,r){n="function"==typeof n?un(n,r,3):k;var i=n?n(t,e):k;return i===k?Oe(t,e,n):!!i}function Fi(t){return m(t)&&"string"==typeof t.message&&nu.call(t)==Z}function Bi(t){return"number"==typeof t&&bu(t)}function Li(t){return Ni(t)&&nu.call(t)==X}function Ni(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function Oi(t,e,n,r){return n="function"==typeof n?un(n,r,3):k,Re(t,Vn(e),n)}function Ii(t){return qi(t)&&t!=+t}function Ri(t){return null==t?!1:Li(t)?iu.test(Qa.call(t)):m(t)&&Nt.test(t)}function Pi(t){return null===t}function qi(t){return"number"==typeof t||m(t)&&nu.call(t)==K}function ji(t){var e;if(!m(t)||nu.call(t)!=Q||ki(t)||!tu.call(t,"constructor")&&(e=t.constructor,"function"==typeof e&&!(e instanceof e)))return!1;var n;return Te(t,function(t,e){n=e}),n===k||tu.call(t,n)}function Ui(t){return Ni(t)&&nu.call(t)==tt}function Yi(t){return"string"==typeof t||m(t)&&nu.call(t)==nt}function zi(t){return m(t)&&nr(t.length)&&!!Yt[nu.call(t)]}function Vi(t){return t===k}function $i(t,e){return e>t}function Gi(t,e){return e>=t}function Hi(t){var e=t?Uu(t):0;return nr(e)?e?te(t):[]:aa(t)}function Wi(t){return be(t,ta(t))}function Zi(t,e,n){var r=Nu(t);return n&&Qn(t,e,n)&&(e=k),e?me(r,e):r}function Xi(t){return Le(t,ta(t))}function Ji(t,e,n){var r=null==t?k:Ne(t,fr(e),e+"");return r===k?n:r}function Ki(t,e){if(null==t)return!1;var n=tu.call(t,e);if(!n&&!tr(e)){if(e=fr(e),t=1==e.length?t:Ne(t,We(e,0,-1)),null==t)return!1;e=Dr(e),n=tu.call(t,e)}return n||nr(t.length)&&Kn(e,t.length)&&(So(t)||ki(t))}function Qi(t,e,n){n&&Qn(t,e,n)&&(e=k);for(var r=-1,i=jo(t),a=i.length,u={};++r0;++r=wu(e,n)&&tn?0:+n||0,r),n-=e.length,n>=0&&t.indexOf(e,n)==n}function fa(t){return t=o(t),t&&_t.test(t)?t.replace(vt,d):t}function da(t){return t=o(t),t&&Mt.test(t)?t.replace(Ct,p):t||"(?:)"}function pa(t,e,n){t=o(t),e=+e;var r=t.length;if(r>=e||!bu(e))return t;var i=(e-r)/2,a=mu(i),u=gu(i);return n=Ln("",u,n),n.slice(0,a)+t+n}function ga(t,e,n){return(n?Qn(t,e,n):null==e)?e=0:e&&(e=+e),t=ba(t),Eu(t,e||(Lt.test(t)?16:10))}function ya(t,e){var n="";if(t=o(t),e=+e,1>e||!t||!bu(e))return n;do e%2&&(n+=t),e=mu(e/2),t+=t;while(e);return n}function ma(t,e,n){return t=o(t),n=null==n?0:wu(0>n?0:+n||0,t.length),t.lastIndexOf(e,n)==n}function va(t,n,r){var i=e.templateSettings;r&&Qn(t,n,r)&&(n=r=k),t=o(t),n=ye(me({},r||n),i,ge);var a,u,s=ye(me({},n.imports),i.imports,ge),c=jo(s),l=tn(s,c),h=0,f=n.interpolate||Rt,d="__p += '",p=Ha((n.escape||Rt).source+"|"+f.source+"|"+(f===At?Ft:Rt).source+"|"+(n.evaluate||Rt).source+"|$","g"),y="//# sourceURL="+("sourceURL"in n?n.sourceURL:"lodash.templateSources["+ ++Ut+"]")+"\n";t.replace(p,function(e,n,r,i,o,s){return r||(r=i),d+=t.slice(h,s).replace(Pt,g),n&&(a=!0,d+="' +\n__e("+n+") +\n'"),o&&(u=!0,d+="';\n"+o+";\n__p += '"),r&&(d+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),h=s+e.length,e}),d+="';\n";var m=n.variable;m||(d="with (obj) {\n"+d+"\n}\n"),d=(u?d.replace(pt,""):d).replace(gt,"$1").replace(yt,"$1;"),d="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(a?", __e = _.escape":"")+(u?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+d+"return __p\n}";var v=Jo(function(){return za(c,y+"return "+d).apply(k,l)});if(v.source=d,Fi(v))throw v;return v}function ba(t,e,n){var r=t;return(t=o(t))?(n?Qn(r,e,n):null==e)?t.slice(x(t),w(t)+1):(e+="",t.slice(s(t,e),c(t,e)+1)):t}function _a(t,e,n){var r=t;return t=o(t),t?t.slice((n?Qn(r,e,n):null==e)?x(t):s(t,e+"")):t}function xa(t,e,n){var r=t;return t=o(t),t?(n?Qn(r,e,n):null==e)?t.slice(0,w(t)+1):t.slice(0,c(t,e+"")+1):t}function wa(t,e,n){n&&Qn(t,e,n)&&(e=k);var r=I,i=R;if(null!=e)if(Ni(e)){var a="separator"in e?e.separator:a;r="length"in e?+e.length||0:r,i="omission"in e?o(e.omission):i}else r=+e||0;if(t=o(t),r>=t.length)return t;var u=r-i.length;if(1>u)return i;var s=t.slice(0,u);if(null==a)return s+i;if(Ui(a)){if(t.slice(u).search(a)){var c,l,h=t.slice(0,u);for(a.global||(a=Ha(a.source,(Bt.exec(a)||"")+"g")),a.lastIndex=0;c=a.exec(h);)l=c.index;s=s.slice(0,null==l?u:l)}}else if(t.indexOf(a,u)!=u){var f=s.lastIndexOf(a);f>-1&&(s=s.slice(0,f))}return s+i}function Aa(t){return t=o(t),t&&bt.test(t)?t.replace(mt,A):t}function Ea(t,e,n){return n&&Qn(t,e,n)&&(e=k),t=o(t),t.match(e||qt)||[]}function ka(t,e,n){return n&&Qn(t,e,n)&&(e=k),m(t)?Ma(t):_e(t,e)}function Da(t){return function(){return t}}function Ca(t){return t}function Ma(t){return qe(xe(t,!0))}function Sa(t,e){return je(t,xe(e,!0))}function Ta(t,e,n){if(null==n){var r=Ni(e),i=r?jo(e):k,a=i&&i.length?Le(e,i):k;(a?a.length:r)||(a=!1,n=e,e=t,t=this)}a||(a=Le(e,jo(e)));var u=!0,o=-1,s=Li(t),c=a.length;n===!1?u=!1:Ni(n)&&"chain"in n&&(u=n.chain);for(;++ot||!bu(t))return[];var r=-1,i=ja(wu(t,Mu));for(e=un(e,n,1);++rr?i[r]=e(r):e(r);return i}function Ra(t){var e=++eu;return o(t)+e}function Pa(t,e){return(+t||0)+(+e||0)}function qa(t,e,n){return n&&Qn(t,e,n)&&(e=k),e=Un(e,n,3),1==e.length?de(So(t)?t:lr(t),e):Ke(t,e)}t=t?re.defaults(ne.Object(),t,re.pick(ne,jt)):ne;{var ja=t.Array,Ua=t.Date,Ya=t.Error,za=t.Function,Va=t.Math,$a=t.Number,Ga=t.Object,Ha=t.RegExp,Wa=t.String,Za=t.TypeError,Xa=ja.prototype,Ja=Ga.prototype,Ka=Wa.prototype,Qa=za.prototype.toString,tu=Ja.hasOwnProperty,eu=0,nu=Ja.toString,ru=ne._,iu=Ha("^"+Qa.call(tu).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),au=t.ArrayBuffer,uu=t.clearTimeout,ou=t.parseFloat,su=Va.pow,cu=Ja.propertyIsEnumerable,lu=$n(t,"Set"),hu=t.setTimeout,fu=Xa.splice,du=t.Uint8Array,pu=$n(t,"WeakMap"),gu=Va.ceil,yu=$n(Ga,"create"),mu=Va.floor,vu=$n(ja,"isArray"),bu=t.isFinite,_u=$n(Ga,"keys"),xu=Va.max,wu=Va.min,Au=$n(Ua,"now"),Eu=t.parseInt,ku=Va.random,Du=$a.NEGATIVE_INFINITY,Cu=$a.POSITIVE_INFINITY,Mu=4294967295,Su=Mu-1,Tu=Mu>>>1,Fu=9007199254740991,Bu=pu&&new pu,Lu={};e.support={}}e.templateSettings={escape:xt,evaluate:wt,interpolate:At,variable:"",imports:{_:e}};var Nu=function(){function t(){}return function(e){if(Ni(e)){t.prototype=e;var n=new t;t.prototype=k}return n||{}}}(),Ou=fn(Fe),Iu=fn(Be,!0),Ru=dn(),Pu=dn(!0),qu=Bu?function(t,e){return Bu.set(t,e),t}:Ca,ju=Bu?function(t){return Bu.get(t)}:Ba,Uu=ze("length"),Yu=function(){var t=0,e=0;return function(n,r){var i=go(),a=q-(i-e);if(e=i,a>0){if(++t>=P)return n}else t=0;return qu(n,r)}}(),zu=mi(function(t,e){return m(t)&&Jn(t)?Ae(t,Se(e,!1,!0)):[]}),Vu=wn(),$u=wn(!0),Gu=mi(function(t){for(var e=t.length,n=e,r=ja(h),i=zn(),u=i==a,o=[];n--;){var s=t[n]=Jn(s=t[n])?s:[];r[n]=u&&s.length>=120?gn(n&&s):null}var c=t[0],l=-1,h=c?c.length:0,f=r[0];t:for(;++l2?t[e-2]:k,r=e>1?t[e-1]:k;return e>2&&"function"==typeof n?e-=2:(n=e>1&&"function"==typeof r?(--e,r):k,r=k),t.length=e,Pr(t,n,r)}),to=mi(function(t){return t=Se(t),this.thru(function(e){return Qt(So(e)?e:[hr(e)],t)})}),eo=mi(function(t,e){return ve(t,Se(e))}),no=ln(function(t,e,n){tu.call(t,n)?++t[n]:t[n]=1}),ro=xn(Ou),io=xn(Iu,!0),ao=kn(ee,Ou),uo=kn(ie,Iu),oo=ln(function(t,e,n){tu.call(t,n)?t[n].push(e):t[n]=[e]}),so=ln(function(t,e,n){t[n]=e}),co=mi(function(t,e,n){var r=-1,i="function"==typeof e,a=tr(e),u=Jn(t)?ja(t.length):[];return Ou(t,function(t){var o=i?e:a&&null!=t?t[e]:k;u[++r]=o?o.apply(t,n):Xn(t,e,n)}),u}),lo=ln(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),ho=Fn(le,Ou),fo=Fn(he,Iu),po=mi(function(t,e){if(null==t)return[];var n=e[2];return n&&Qn(e[0],e[1],n)&&(e.length=1),Je(t,Se(e),[])}),go=Au||function(){return(new Ua).getTime()},yo=mi(function(t,e,n){var r=C;if(n.length){var i=b(n,yo.placeholder);r|=B}return Rn(t,r,e,n,i)}),mo=mi(function(t,e){e=e.length?Se(e):Xi(t);for(var n=-1,r=e.length;++n0||0>e)?new K(n):(0>t?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==k&&(e=+e||0,n=0>e?n.dropRight(-e):n.take(e-t)),n)},K.prototype.takeRightWhile=function(t,e){return this.reverse().takeWhile(t,e).reverse()},K.prototype.toArray=function(){return this.take(Cu)},Fe(K.prototype,function(t,n){var r=/^(?:filter|map|reject)|While$/.test(n),i=/^(?:first|last)$/.test(n),a=e[i?"take"+("last"==n?"Right":""):n];a&&(e.prototype[n]=function(){var e=i?[1]:arguments,n=this.__chain__,u=this.__wrapped__,o=!!this.__actions__.length,s=u instanceof K,c=e[0],l=s||So(u);l&&r&&"function"==typeof c&&1!=c.length&&(s=l=!1);var h=function(t){return i&&n?a(t,1)[0]:a.apply(k,ce([t],e))},f={func:zr,args:[h],thisArg:k},d=s&&!o;if(i&&!n)return d?(u=u.clone(),u.__actions__.push(f),t.call(u)):a.call(k,this.value())[0];if(!i&&l){u=d?u:new K(this);var p=t.apply(u,e);return p.__actions__.push(f),new v(p,n)}return this.thru(h)})}),ee(["join","pop","push","replace","shift","sort","splice","split","unshift"],function(t){var n=(/^(?:replace|split)$/.test(t)?Ja:Xa)[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",i=/^(?:join|pop|replace|shift)$/.test(t);e.prototype[t]=function(){var t=arguments;return i&&!this.__chain__?n.apply(this.value(),t):this[r](function(e){return n.apply(e,t)})}}),Fe(K.prototype,function(t,n){var r=e[n];if(r){var i=r.name,a=Lu[i]||(Lu[i]=[]);a.push({name:n,func:r})}}),Lu[Bn(k,M).name]=[{name:"wrapper",func:k}],K.prototype.clone=et,K.prototype.reverse=rt,K.prototype.value=Vt,e.prototype.chain=Vr,e.prototype.commit=$r,e.prototype.concat=to,e.prototype.plant=Gr,e.prototype.reverse=Hr,e.prototype.toString=Wr,e.prototype.run=e.prototype.toJSON=e.prototype.valueOf=e.prototype.value=Zr,e.prototype.collect=e.prototype.map,e.prototype.head=e.prototype.first,e.prototype.select=e.prototype.filter,e.prototype.tail=e.prototype.rest,e}var k,D="3.10.1",C=1,M=2,S=4,T=8,F=16,B=32,L=64,O=128,N=256,I=30,P="...",R=150,q=16,j=200,U=1,Y=2,z="Expected a function",V="__lodash_placeholder__",$="[object Arguments]",G="[object Array]",H="[object Boolean]",W="[object Date]",Z="[object Error]",X="[object Function]",K="[object Map]",J="[object Number]",Q="[object Object]",tt="[object RegExp]",et="[object Set]",nt="[object String]",rt="[object WeakMap]",it="[object ArrayBuffer]",at="[object Float32Array]",ut="[object Float64Array]",ot="[object Int8Array]",st="[object Int16Array]",ct="[object Int32Array]",lt="[object Uint8Array]",ht="[object Uint8ClampedArray]",ft="[object Uint16Array]",dt="[object Uint32Array]",pt=/\b__p \+= '';/g,gt=/\b(__p \+=) '' \+/g,yt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,mt=/&(?:amp|lt|gt|quot|#39|#96);/g,vt=/[&<>"'`]/g,bt=RegExp(mt.source),_t=RegExp(vt.source),xt=/<%-([\s\S]+?)%>/g,wt=/<%([\s\S]+?)%>/g,At=/<%=([\s\S]+?)%>/g,Et=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\n\\]|\\.)*?\1)\]/,kt=/^\w*$/,Dt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g,Ct=/^[:!,]|[\\^$.*+?()[\]{}|\/]|(^[0-9a-fA-Fnrtuvx])|([\n\r\u2028\u2029])/g,Mt=RegExp(Ct.source),St=/[\u0300-\u036f\ufe20-\ufe23]/g,Tt=/\\(\\)?/g,Ft=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Bt=/\w*$/,Lt=/^0[xX]/,Ot=/^\[object .+?Constructor\]$/,Nt=/^\d+$/,It=/[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g,Pt=/($^)/,Rt=/['\n\r\u2028\u2029\\]/g,qt=function(){var t="[A-Z\\xc0-\\xd6\\xd8-\\xde]",e="[a-z\\xdf-\\xf6\\xf8-\\xff]+";return RegExp(t+"+(?="+t+e+")|"+t+"?"+e+"|"+t+"+|[0-9]+","g")}(),jt=["Array","ArrayBuffer","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Math","Number","Object","RegExp","Set","String","_","clearTimeout","isFinite","parseFloat","parseInt","setTimeout","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap"],Ut=-1,Yt={};Yt[at]=Yt[ut]=Yt[ot]=Yt[st]=Yt[ct]=Yt[lt]=Yt[ht]=Yt[ft]=Yt[dt]=!0,Yt[$]=Yt[G]=Yt[it]=Yt[H]=Yt[W]=Yt[Z]=Yt[X]=Yt[K]=Yt[J]=Yt[Q]=Yt[tt]=Yt[et]=Yt[nt]=Yt[rt]=!1;var zt={};zt[$]=zt[G]=zt[it]=zt[H]=zt[W]=zt[at]=zt[ut]=zt[ot]=zt[st]=zt[ct]=zt[J]=zt[Q]=zt[tt]=zt[nt]=zt[lt]=zt[ht]=zt[ft]=zt[dt]=!0,zt[Z]=zt[X]=zt[K]=zt[et]=zt[rt]=!1;var Vt={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss"},$t={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},Gt={"&":"&","<":"<",">":">",""":'"',"'":"'","`":"`"},Ht={"function":!0,object:!0},Wt={0:"x30",1:"x31",2:"x32",3:"x33",4:"x34",5:"x35",6:"x36",7:"x37",8:"x38",9:"x39",A:"x41",B:"x42",C:"x43",D:"x44",E:"x45",F:"x46",a:"x61",b:"x62",c:"x63",d:"x64",e:"x65",f:"x66",n:"x6e",r:"x72",t:"x74",u:"x75",v:"x76",x:"x78"},Zt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Xt=Ht[typeof n]&&n&&!n.nodeType&&n,Kt=Ht[typeof e]&&e&&!e.nodeType&&e,Jt=Xt&&Kt&&"object"==typeof t&&t&&t.Object&&t,Qt=Ht[typeof self]&&self&&self.Object&&self,te=Ht[typeof window]&&window&&window.Object&&window,ee=Kt&&Kt.exports===Xt&&Xt,ne=Jt||te!==(this&&this.window)&&te||Qt||this,re=E();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(ne._=re,define(function(){return re})):Xt&&Kt?ee?(Kt.exports=re)._=re:Xt._=re:ne._=re}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],54:[function(t,e){e.exports={graphlib:t("./lib/graphlib"),layout:t("./lib/layout"),debug:t("./lib/debug"),util:{time:t("./lib/util").time,notime:t("./lib/util").notime},version:t("./lib/version")}},{"./lib/debug":59,"./lib/graphlib":60,"./lib/layout":62,"./lib/util":82,"./lib/version":83}],55:[function(t,e){"use strict";function n(t){function e(t){return function(e){return t.edge(e).weight}}var n="greedy"===t.graph().acyclicer?u(t,e(t)):r(t);a.each(n,function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,a.uniqueId("rev"))})}function r(t){function e(u){a.has(i,u)||(i[u]=!0,r[u]=!0,a.each(t.outEdges(u),function(t){a.has(r,t.w)?n.push(t):e(t.w)}),delete r[u])}var n=[],r={},i={};return a.each(t.nodes(),e),n}function i(t){a.each(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)}})}var a=t("./lodash"),u=t("./greedy-fas");e.exports={run:n,undo:i}},{"./greedy-fas":61,"./lodash":63}],56:[function(t,e){function n(t){function e(n){var a=t.children(n),u=t.node(n);if(a.length&&i.each(a,e),i.has(u,"minRank")){u.borderLeft=[],u.borderRight=[];for(var o=u.minRank,s=u.maxRank+1;s>o;++o)r(t,"borderLeft","_bl",n,u,o),r(t,"borderRight","_br",n,u,o)}}i.each(t.children(),e)}function r(t,e,n,r,i,u){var o={width:0,height:0,rank:u,borderType:e},s=i[e][u-1],c=a.addDummyNode(t,"border",o,n);i[e][u]=c,t.setParent(c,r),s&&t.setEdge(s,c,{weight:1})}var i=t("./lodash"),a=t("./util");e.exports=n},{"./lodash":63,"./util":82}],57:[function(t,e){"use strict";function n(t){var e=t.graph().rankdir.toLowerCase();("lr"===e||"rl"===e)&&i(t)}function r(t){var e=t.graph().rankdir.toLowerCase();("bt"===e||"rl"===e)&&u(t),("lr"===e||"rl"===e)&&(s(t),i(t))}function i(t){l.each(t.nodes(),function(e){a(t.node(e))}),l.each(t.edges(),function(e){a(t.edge(e))})}function a(t){var e=t.width;t.width=t.height,t.height=e}function u(t){l.each(t.nodes(),function(e){o(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,o),l.has(n,"y")&&o(n)})}function o(t){t.y=-t.y}function s(t){l.each(t.nodes(),function(e){c(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,c),l.has(n,"x")&&c(n)})}function c(t){var e=t.x;t.x=t.y,t.y=e}var l=t("./lodash");e.exports={adjust:n,undo:r}},{"./lodash":63}],58:[function(t,e){function n(){var t={};t._next=t._prev=t,this._sentinel=t}function r(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function i(t,e){return"_next"!==t&&"_prev"!==t?e:void 0}e.exports=n,n.prototype.dequeue=function(){var t=this._sentinel,e=t._prev;return e!==t?(r(e),e):void 0},n.prototype.enqueue=function(t){var e=this._sentinel;t._prev&&t._next&&r(t),t._next=e._next,e._next._prev=t,e._next=t,t._prev=e},n.prototype.toString=function(){for(var t=[],e=this._sentinel,n=e._prev;n!==e;)t.push(JSON.stringify(n,i)),n=n._prev;return"["+t.join(", ")+"]"}},{}],59:[function(t,e){function n(t){var e=i.buildLayerMatrix(t),n=new a({compound:!0,multigraph:!0}).setGraph({});return r.each(t.nodes(),function(e){n.setNode(e,{label:e}),n.setParent(e,"layer"+t.node(e).rank)}),r.each(t.edges(),function(t){n.setEdge(t.v,t.w,{},t.name)}),r.each(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}var r=t("./lodash"),i=t("./util"),a=t("./graphlib").Graph;e.exports={debugOrdering:n}},{"./graphlib":60,"./lodash":63,"./util":82}],60:[function(t,e){var n;if("function"==typeof t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:84}],61:[function(t,e){function n(t,e){if(t.nodeCount()<=1)return[];var n=a(t,e||l),i=r(n.graph,n.buckets,n.zeroIdx);return o.flatten(o.map(i,function(e){return t.outEdges(e.v,e.w)}),!0)}function r(t,e,n){for(var r,a=[],u=e[e.length-1],o=e[0];t.nodeCount();){for(;r=o.dequeue();)i(t,e,n,r);for(;r=u.dequeue();)i(t,e,n,r);if(t.nodeCount())for(var s=e.length-2;s>0;--s)if(r=e[s].dequeue()){a=a.concat(i(t,e,n,r,!0));break}}return a}function i(t,e,n,r,i){var a=i?[]:void 0;return o.each(t.inEdges(r.v),function(r){var o=t.edge(r),s=t.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,u(e,n,s)}),o.each(t.outEdges(r.v),function(r){var i=t.edge(r),a=r.w,o=t.node(a);o["in"]-=i,u(e,n,o)}),t.removeNode(r.v),a}function a(t,e){var n=new s,r=0,i=0;o.each(t.nodes(),function(t){n.setNode(t,{v:t,"in":0,out:0})}),o.each(t.edges(),function(t){var a=n.edge(t.v,t.w)||0,u=e(t),o=a+u;n.setEdge(t.v,t.w,o),i=Math.max(i,n.node(t.v).out+=u),r=Math.max(r,n.node(t.w)["in"]+=u)});var a=o.range(i+r+3).map(function(){return new c}),l=r+1;return o.each(n.nodes(),function(t){u(a,l,n.node(t))}),{graph:n,buckets:a,zeroIdx:l}}function u(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)}var o=t("./lodash"),s=t("./graphlib").Graph,c=t("./data/list");e.exports=n;var l=o.constant(1)},{"./data/list":58,"./graphlib":60,"./lodash":63}],62:[function(t,e){"use strict";function n(t,e){var n=e&&e.debugTiming?B.time:B.notime;n("layout",function(){var e=n(" buildLayoutGraph",function(){return a(t)});n(" runLayout",function(){r(e,n)}),n(" updateInputGraph",function(){i(t,e)})})}function r(t,e){e(" makeSpaceForEdgeLabels",function(){u(t)}),e(" removeSelfEdges",function(){g(t)}),e(" acyclic",function(){x.run(t)}),e(" nestingGraph.run",function(){C.run(t)}),e(" rank",function(){A(B.asNonCompoundGraph(t))}),e(" injectEdgeLabelProxies",function(){o(t)}),e(" removeEmptyRanks",function(){D(t)}),e(" nestingGraph.cleanup",function(){C.cleanup(t)}),e(" normalizeRanks",function(){E(t)}),e(" assignRankMinMax",function(){s(t)}),e(" removeEdgeLabelProxies",function(){c(t)}),e(" normalize.run",function(){w.run(t)}),e(" parentDummyChains",function(){k(t)}),e(" addBorderSegments",function(){M(t)}),e(" order",function(){T(t)}),e(" insertSelfEdges",function(){y(t)}),e(" adjustCoordinateSystem",function(){S.adjust(t)}),e(" position",function(){F(t)}),e(" positionSelfEdges",function(){m(t)}),e(" removeBorderNodes",function(){p(t)}),e(" normalize.undo",function(){w.undo(t)}),e(" fixupEdgeLabelCoords",function(){f(t)}),e(" undoCoordinateSystem",function(){S.undo(t)}),e(" translateGraph",function(){l(t)}),e(" assignNodeIntersects",function(){h(t)}),e(" reversePoints",function(){d(t)}),e(" acyclic.undo",function(){x.undo(t)})}function i(t,e){_.each(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))}),_.each(t.edges(),function(n){var r=t.edge(n),i=e.edge(n);r.points=i.points,_.has(i,"x")&&(r.x=i.x,r.y=i.y)}),t.graph().width=e.graph().width,t.graph().height=e.graph().height}function a(t){var e=new L({multigraph:!0,compound:!0}),n=b(t.graph());return e.setGraph(_.merge({},N,v(n,O),_.pick(n,I))),_.each(t.nodes(),function(n){var r=b(t.node(n));e.setNode(n,_.defaults(v(r,P),R)),e.setParent(n,t.parent(n))}),_.each(t.edges(),function(n){var r=b(t.edge(n));e.setEdge(n,_.merge({},j,v(r,q),_.pick(r,U)))}),e}function u(t){var e=t.graph();e.ranksep/=2,_.each(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)})}function o(t){_.each(t.edges(),function(e){var n=t.edge(e);if(n.width&&n.height){var r=t.node(e.v),i=t.node(e.w),a={rank:(i.rank-r.rank)/2+r.rank,e:e};B.addDummyNode(t,"edge-proxy",a,"_ep")}})}function s(t){var e=0;_.each(t.nodes(),function(n){var r=t.node(n);r.borderTop&&(r.minRank=t.node(r.borderTop).rank,r.maxRank=t.node(r.borderBottom).rank,e=_.max(e,r.maxRank))}),t.graph().maxRank=e}function c(t){_.each(t.nodes(),function(e){var n=t.node(e);"edge-proxy"===n.dummy&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))})}function l(t){function e(t){var e=t.x,u=t.y,o=t.width,s=t.height;n=Math.min(n,e-o/2),r=Math.max(r,e+o/2),i=Math.min(i,u-s/2),a=Math.max(a,u+s/2)}var n=Number.POSITIVE_INFINITY,r=0,i=Number.POSITIVE_INFINITY,a=0,u=t.graph(),o=u.marginx||0,s=u.marginy||0;_.each(t.nodes(),function(n){e(t.node(n))}),_.each(t.edges(),function(n){var r=t.edge(n);_.has(r,"x")&&e(r)}),n-=o,i-=s,_.each(t.nodes(),function(e){var r=t.node(e);r.x-=n,r.y-=i}),_.each(t.edges(),function(e){var r=t.edge(e);_.each(r.points,function(t){t.x-=n,t.y-=i}),_.has(r,"x")&&(r.x-=n),_.has(r,"y")&&(r.y-=i)}),u.width=r-n+o,u.height=a-i+s}function h(t){_.each(t.edges(),function(e){var n,r,i=t.edge(e),a=t.node(e.v),u=t.node(e.w);i.points?(n=i.points[0],r=i.points[i.points.length-1]):(i.points=[],n=u,r=a),i.points.unshift(B.intersectRect(a,n)),i.points.push(B.intersectRect(u,r))})}function f(t){_.each(t.edges(),function(e){var n=t.edge(e);if(_.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}})}function d(t){_.each(t.edges(),function(e){var n=t.edge(e);n.reversed&&n.points.reverse()})}function p(t){_.each(t.nodes(),function(e){if(t.children(e).length){var n=t.node(e),r=t.node(n.borderTop),i=t.node(n.borderBottom),a=t.node(_.last(n.borderLeft)),u=t.node(_.last(n.borderRight));n.width=Math.abs(u.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),_.each(t.nodes(),function(e){"border"===t.node(e).dummy&&t.removeNode(e)})}function g(t){_.each(t.edges(),function(e){if(e.v===e.w){var n=t.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e:e,label:t.edge(e)}),t.removeEdge(e)}})}function y(t){var e=B.buildLayerMatrix(t);_.each(e,function(e){var n=0;_.each(e,function(e,r){var i=t.node(e);i.order=r+n,_.each(i.selfEdges,function(e){B.addDummyNode(t,"selfedge",{width:e.label.width,height:e.label.height,rank:i.rank,order:r+ ++n,e:e.e,label:e.label},"_se")}),delete i.selfEdges})})}function m(t){_.each(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,u=n.x-i,o=r.height/2;t.setEdge(n.e,n.label),t.removeNode(e),n.label.points=[{x:i+2*u/3,y:a-o},{x:i+5*u/6,y:a-o},{x:i+u,y:a},{x:i+5*u/6,y:a+o},{x:i+2*u/3,y:a+o}],n.label.x=n.x,n.label.y=n.y}})}function v(t,e){return _.mapValues(_.pick(t,e),Number)}function b(t){var e={};return _.each(t,function(t,n){e[n.toLowerCase()]=t}),e}var _=t("./lodash"),x=t("./acyclic"),w=t("./normalize"),A=t("./rank"),E=t("./util").normalizeRanks,k=t("./parent-dummy-chains"),D=t("./util").removeEmptyRanks,C=t("./nesting-graph"),M=t("./add-border-segments"),S=t("./coordinate-system"),T=t("./order"),F=t("./position"),B=t("./util"),L=t("./graphlib").Graph;e.exports=n;var O=["nodesep","edgesep","ranksep","marginx","marginy"],N={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},I=["acyclicer","ranker","rankdir","align"],P=["width","height"],R={width:0,height:0},q=["minlen","weight","width","height","labeloffset"],j={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},U=["labelpos"]},{"./acyclic":55,"./add-border-segments":56,"./coordinate-system":57,"./graphlib":60,"./lodash":63,"./nesting-graph":64,"./normalize":65,"./order":70,"./parent-dummy-chains":75,"./position":77,"./rank":79,"./util":82}],63:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":51,lodash:104}],64:[function(t,e){function n(t){var e=s.addDummyNode(t,"root",{},"_root"),n=i(t),u=o.max(n)-1,c=2*u+1;t.graph().nestingRoot=e,o.each(t.edges(),function(e){t.edge(e).minlen*=c});var l=a(t)+1;o.each(t.children(),function(i){r(t,e,c,l,u,n,i)}),t.graph().nodeRankFactor=c}function r(t,e,n,i,a,u,c){var l=t.children(c);if(!l.length)return void(c!==e&&t.setEdge(e,c,{weight:0,minlen:n}));var h=s.addBorderNode(t,"_bt"),f=s.addBorderNode(t,"_bb"),d=t.node(c);t.setParent(h,c),d.borderTop=h,t.setParent(f,c),d.borderBottom=f,o.each(l,function(o){r(t,e,n,i,a,u,o);var s=t.node(o),l=s.borderTop?s.borderTop:o,d=s.borderBottom?s.borderBottom:o,p=s.borderTop?i:2*i,g=l!==d?1:a-u[c]+1;t.setEdge(h,l,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(d,f,{weight:p,minlen:g,nestingEdge:!0})}),t.parent(c)||t.setEdge(e,h,{weight:0,minlen:a+u[c]})}function i(t){function e(r,i){var a=t.children(r);a&&a.length&&o.each(a,function(t){e(t,i+1)}),n[r]=i}var n={};return o.each(t.children(),function(t){e(t,1)}),n}function a(t){return o.reduce(t.edges(),function(e,n){return e+t.edge(n).weight},0)}function u(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,o.each(t.edges(),function(e){var n=t.edge(e);n.nestingEdge&&t.removeEdge(e)})}var o=t("./lodash"),s=t("./util");e.exports={run:n,cleanup:u}},{"./lodash":63,"./util":82}],65:[function(t,e){"use strict";function n(t){t.graph().dummyChains=[],a.each(t.edges(),function(e){r(t,e)})}function r(t,e){var n=e.v,r=t.node(n).rank,i=e.w,a=t.node(i).rank,o=e.name,s=t.edge(e),c=s.labelRank;if(a!==r+1){t.removeEdge(e);var l,h,f;for(f=0,++r;a>r;++f,++r)s.points=[],h={width:0,height:0,edgeLabel:s,edgeObj:e,rank:r},l=u.addDummyNode(t,"edge",h,"_d"),r===c&&(h.width=s.width,h.height=s.height,h.dummy="edge-label",h.labelpos=s.labelpos),t.setEdge(n,l,{weight:s.weight},o),0===f&&t.graph().dummyChains.push(l),n=l;t.setEdge(n,i,{weight:s.weight},o)}}function i(t){a.each(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)})}var a=t("./lodash"),u=t("./util");e.exports={run:n,undo:i}},{"./lodash":63,"./util":82}],66:[function(t,e){function n(t,e,n){var i,a={};r.each(n,function(n){for(var r,u,o=t.parent(n);o;){if(r=t.parent(o),r?(u=a[r],a[r]=o):(u=i,i=o),u&&u!==o)return void e.setEdge(u,o);o=r}})}var r=t("../lodash");e.exports=n},{"../lodash":63}],67:[function(t,e){function n(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}})}var r=t("../lodash");e.exports=n},{"../lodash":63}],68:[function(t,e){function n(t,e,n){var u=r(t),o=new a({compound:!0}).setGraph({root:u}).setDefaultNodeLabel(function(e){return t.node(e)});return i.each(t.nodes(),function(r){var a=t.node(r),s=t.parent(r);(a.rank===e||a.minRank<=e&&e<=a.maxRank)&&(o.setNode(r),o.setParent(r,s||u),i.each(t[n](r),function(e){var n=e.v===r?e.w:e.v,a=o.edge(n,r),u=i.isUndefined(a)?0:a.weight;o.setEdge(n,r,{weight:t.edge(e).weight+u})}),i.has(a,"minRank")&&o.setNode(r,{borderLeft:a.borderLeft[e],borderRight:a.borderRight[e]}))}),o}function r(t){for(var e;t.hasNode(e=i.uniqueId("_root")););return e}var i=t("../lodash"),a=t("../graphlib").Graph;e.exports=n},{"../graphlib":60,"../lodash":63}],69:[function(t,e){"use strict";function n(t,e){for(var n=0,i=1;i0;)e%2&&(n+=s[e+1]),e=e-1>>1,s[e]+=t.weight;c+=t.weight*n})),c}var i=t("../lodash");e.exports=n},{"../lodash":63}],70:[function(t,e){"use strict";function n(t){var e=d.maxRank(t),n=r(t,u.range(1,e+1),"inEdges"),c=r(t,u.range(e-1,-1,-1),"outEdges"),l=o(t);a(t,l);for(var h,f=Number.POSITIVE_INFINITY,p=0,g=0;4>g;++p,++g){i(p%2?n:c,p%4>=2),l=d.buildLayerMatrix(t);var y=s(t,l);f>y&&(g=0,h=u.cloneDeep(l),f=y)}a(t,h)}function r(t,e,n){return u.map(e,function(e){return l(t,e,n)})}function i(t,e){var n=new f;u.each(t,function(t){var r=t.graph().root,i=c(t,r,n,e);u.each(i.vs,function(e,n){t.node(e).order=n}),h(t,n,i.vs)})}function a(t,e){u.each(e,function(e){u.each(e,function(e,n){t.node(e).order=n})})}var u=t("../lodash"),o=t("./init-order"),s=t("./cross-count"),c=t("./sort-subgraph"),l=t("./build-layer-graph"),h=t("./add-subgraph-constraints"),f=t("../graphlib").Graph,d=t("../util");e.exports=n},{"../graphlib":60,"../lodash":63,"../util":82,"./add-subgraph-constraints":66,"./build-layer-graph":68,"./cross-count":69,"./init-order":71,"./sort-subgraph":73}],71:[function(t,e){"use strict";function n(t){function e(i){if(!r.has(n,i)){n[i]=!0;var a=t.node(i);u[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})),u=r.map(r.range(a+1),function(){return[]}),o=r.sortBy(i,function(e){return t.node(e).rank});return r.each(o,e),u}var r=t("../lodash");e.exports=n},{"../lodash":63}],72:[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 u=t.pop();r.push(u),a.each(u["in"].reverse(),e(u)),a.each(u.out,n(u))}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":63}],73:[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=u(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=s(m,l);if(d&&(v.vs=a.flatten([d,v.vs,p],!0),t.predecessors(d).length)){var b=t.node(t.predecessors(d)[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 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"),u=t("./barycenter"),o=t("./resolve-conflicts"),s=t("./sort");e.exports=n},{"../lodash":63,"./barycenter":67,"./resolve-conflicts":72,"./sort":74}],74:[function(t,e){function n(t,e){var n=u.partition(t,function(t){return a.has(t,"barycenter")}),o=n.lhs,s=a.sortBy(n.rhs,function(t){return-t.i}),c=[],l=0,h=0,f=0;o.sort(i(!!e)),f=r(c,s,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,s,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.barycentern.barycenter?1:t?n.i-e.i:e.i-n.i}}var a=t("../lodash"),u=t("../util");e.exports=n},{"../lodash":63,"../util":82}],75:[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,u=r(t,e,a.v,a.w),o=u.path,s=u.lca,c=0,l=o[c],h=!0;n!==a.w;){if(i=t.node(n),h){for(;(l=o[c])!==s&&t.node(l).maxRanks||c>e[i].lim));for(a=i,i=r;(i=t.parent(i))!==a;)o.push(i);return{path:u.concat(o.reverse()),lca:a}}function i(t){function e(i){var u=r;a.each(t.children(i),e),n[i]={low:u,lim:r++}}var n={},r=0;return a.each(t.children(),e),n}var a=t("./lodash");e.exports=n},{"./lodash":63}],76:[function(t,e){"use strict";function n(t,e){function n(e,n){ +return t.apply(this,r)})}),Do=Tn(B),Co=Tn(L),Mo=mi(function(t,e){return Rn(t,O,k,k,k,Se(e))}),So=vu||function(t){return m(t)&&nr(t.length)&&nu.call(t)==G},To=hn(Ue),Fo=hn(function(t,e,n){return n?ye(t,e,n):me(t,e)}),Bo=bn(Fo,pe),Lo=bn(To,ar),No=An(Fe),Oo=An(Be),Io=Dn(Ru),Ro=Dn(Pu),Po=Cn(Fe),qo=Cn(Be),jo=_u?function(t){var e=null==t?k:t.constructor;return"function"==typeof e&&e.prototype===t||"function"!=typeof t&&Jn(t)?cr(t):Ni(t)?_u(t):[]}:cr,Uo=Mn(!0),Yo=Mn(),zo=mi(function(t,e){if(null==t)return{};if("function"!=typeof e[0]){var e=se(Se(e),Wa);return ur(t,Ae(ta(t),e))}var n=un(e[0],e[1],3);return or(t,function(t,e,r){return!n(t,e,r)})}),Vo=mi(function(t,e){return null==t?{}:"function"==typeof e[0]?or(t,un(e[0],e[1],3)):ur(t,Se(e))}),$o=yn(function(t,e,n){return e=e.toLowerCase(),t+(n?e.charAt(0).toUpperCase()+e.slice(1):e)}),Go=yn(function(t,e,n){return t+(n?"-":"")+e.toLowerCase()}),Ho=Sn(),Wo=Sn(!0),Zo=yn(function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}),Xo=yn(function(t,e,n){return t+(n?" ":"")+(e.charAt(0).toUpperCase()+e.slice(1))}),Jo=mi(function(t,e){try{return t.apply(k,e)}catch(n){return Fi(n)?n:new Ya(n)}}),Ko=mi(function(t,e){return function(n){return Xn(n,t,e)}}),Qo=mi(function(t,e){return function(n){return Xn(t,n,e)}}),ts=On("ceil"),es=On("floor"),ns=_n(Ai,Du),rs=_n($i,Cu),is=On("round");return e.prototype=n.prototype,v.prototype=Nu(n.prototype),v.prototype.constructor=v,J.prototype=Nu(n.prototype),J.prototype.constructor=J,$t.prototype["delete"]=Gt,$t.prototype.get=Ht,$t.prototype.has=Wt,$t.prototype.set=Zt,Xt.prototype.push=Kt,pi.Cache=$t,e.after=li,e.ary=hi,e.assign=Fo,e.at=eo,e.before=fi,e.bind=yo,e.bindAll=mo,e.bindKey=vo,e.callback=ka,e.chain=Ur,e.chunk=pr,e.compact=gr,e.constant=Da,e.countBy=no,e.create=Zi,e.curry=bo,e.curryRight=_o,e.debounce=di,e.defaults=Bo,e.defaultsDeep=Lo,e.defer=xo,e.delay=wo,e.difference=zu,e.drop=yr,e.dropRight=mr,e.dropRightWhile=vr,e.dropWhile=br,e.fill=_r,e.filter=Jr,e.flatten=wr,e.flattenDeep=Ar,e.flow=Ao,e.flowRight=Eo,e.forEach=ao,e.forEachRight=uo,e.forIn=Io,e.forInRight=Ro,e.forOwn=Po,e.forOwnRight=qo,e.functions=Xi,e.groupBy=oo,e.indexBy=so,e.initial=kr,e.intersection=Gu,e.invert=Qi,e.invoke=co,e.keys=jo,e.keysIn=ta,e.map=ti,e.mapKeys=Uo,e.mapValues=Yo,e.matches=Ma,e.matchesProperty=Sa,e.memoize=pi,e.merge=To,e.method=Ko,e.methodOf=Qo,e.mixin=Ta,e.modArgs=ko,e.negate=gi,e.omit=zo,e.once=yi,e.pairs=ea,e.partial=Do,e.partialRight=Co,e.partition=lo,e.pick=Vo,e.pluck=ei,e.property=La,e.propertyOf=Na,e.pull=Mr,e.pullAt=Hu,e.range=Oa,e.rearg=Mo,e.reject=ni,e.remove=Sr,e.rest=Tr,e.restParam=mi,e.set=ra,e.shuffle=ii,e.slice=Fr,e.sortBy=oi,e.sortByAll=po,e.sortByOrder=si,e.spread=vi,e.take=Br,e.takeRight=Lr,e.takeRightWhile=Nr,e.takeWhile=Or,e.tap=Yr,e.throttle=bi,e.thru=zr,e.times=Ia,e.toArray=Hi,e.toPlainObject=Wi,e.transform=ia,e.union=Xu,e.uniq=Ir,e.unzip=Rr,e.unzipWith=Pr,e.values=aa,e.valuesIn=ua,e.where=ci,e.without=Ju,e.wrap=_i,e.xor=qr,e.zip=Ku,e.zipObject=jr,e.zipWith=Qu,e.backflow=Eo,e.collect=ti,e.compose=Eo,e.each=ao,e.eachRight=uo,e.extend=Fo,e.iteratee=ka,e.methods=Xi,e.object=jr,e.select=Jr,e.tail=Tr,e.unique=Ir,Ta(e,e),e.add=Pa,e.attempt=Jo,e.camelCase=$o,e.capitalize=ca,e.ceil=ts,e.clone=xi,e.cloneDeep=wi,e.deburr=la,e.endsWith=ha,e.escape=fa,e.escapeRegExp=da,e.every=Xr,e.find=ro,e.findIndex=Vu,e.findKey=No,e.findLast=io,e.findLastIndex=$u,e.findLastKey=Oo,e.findWhere=Kr,e.first=xr,e.floor=es,e.get=Ji,e.gt=Ai,e.gte=Ei,e.has=Ki,e.identity=Ca,e.includes=Qr,e.indexOf=Er,e.inRange=oa,e.isArguments=ki,e.isArray=So,e.isBoolean=Di,e.isDate=Ci,e.isElement=Mi,e.isEmpty=Si,e.isEqual=Ti,e.isError=Fi,e.isFinite=Bi,e.isFunction=Li,e.isMatch=Oi,e.isNaN=Ii,e.isNative=Ri,e.isNull=Pi,e.isNumber=qi,e.isObject=Ni,e.isPlainObject=ji,e.isRegExp=Ui,e.isString=Yi,e.isTypedArray=zi,e.isUndefined=Vi,e.kebabCase=Go,e.last=Dr,e.lastIndexOf=Cr,e.lt=$i,e.lte=Gi,e.max=ns,e.min=rs,e.noConflict=Fa,e.noop=Ba,e.now=go,e.pad=pa,e.padLeft=Ho,e.padRight=Wo,e.parseInt=ga,e.random=sa,e.reduce=ho,e.reduceRight=fo,e.repeat=ya,e.result=na,e.round=is,e.runInContext=E,e.size=ai,e.snakeCase=Zo,e.some=ui,e.sortedIndex=Wu,e.sortedLastIndex=Zu,e.startCase=Xo,e.startsWith=ma,e.sum=qa,e.template=va,e.trim=ba,e.trimLeft=_a,e.trimRight=xa,e.trunc=wa,e.unescape=Aa,e.uniqueId=Ra,e.words=Ea,e.all=Xr,e.any=ui,e.contains=Qr,e.eq=Ti,e.detect=ro,e.foldl=ho,e.foldr=fo,e.head=xr,e.include=Qr,e.inject=ho,Ta(e,function(){var t={};return Fe(e,function(n,r){e.prototype[r]||(t[r]=n)}),t}(),!1),e.sample=ri,e.prototype.sample=function(t){return this.__chain__||null!=t?this.thru(function(e){return ri(e,t)}):ri(this.value())},e.VERSION=D,ee(["bind","bindKey","curry","curryRight","partial","partialRight"],function(t){e[t].placeholder=e}),ee(["drop","take"],function(t,e){J.prototype[t]=function(n){var r=this.__filtered__;if(r&&!e)return new J(this);n=null==n?1:xu(mu(n)||0,0);var i=this.clone();return r?i.__takeCount__=wu(i.__takeCount__,n):i.__views__.push({size:n,type:t+(i.__dir__<0?"Right":"")}),i},J.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}}),ee(["filter","map","takeWhile"],function(t,e){var n=e+1,r=n!=Y;J.prototype[t]=function(t,e){var i=this.clone();return i.__iteratees__.push({iteratee:Un(t,e,1),type:n}),i.__filtered__=i.__filtered__||r,i}}),ee(["first","last"],function(t,e){var n="take"+(e?"Right":"");J.prototype[t]=function(){return this[n](1).value()[0]}}),ee(["initial","rest"],function(t,e){var n="drop"+(e?"":"Right");J.prototype[t]=function(){return this.__filtered__?new J(this):this[n](1)}}),ee(["pluck","where"],function(t,e){var n=e?"filter":"map",r=e?qe:La;J.prototype[t]=function(t){return this[n](r(t))}}),J.prototype.compact=function(){return this.filter(Ca)},J.prototype.reject=function(t,e){return t=Un(t,e,1),this.filter(function(e){return!t(e)})},J.prototype.slice=function(t,e){t=null==t?0:+t||0;var n=this;return n.__filtered__&&(t>0||0>e)?new J(n):(0>t?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==k&&(e=+e||0,n=0>e?n.dropRight(-e):n.take(e-t)),n)},J.prototype.takeRightWhile=function(t,e){return this.reverse().takeWhile(t,e).reverse()},J.prototype.toArray=function(){return this.take(Cu)},Fe(J.prototype,function(t,n){var r=/^(?:filter|map|reject)|While$/.test(n),i=/^(?:first|last)$/.test(n),a=e[i?"take"+("last"==n?"Right":""):n];a&&(e.prototype[n]=function(){var e=i?[1]:arguments,n=this.__chain__,u=this.__wrapped__,o=!!this.__actions__.length,s=u instanceof J,c=e[0],l=s||So(u);l&&r&&"function"==typeof c&&1!=c.length&&(s=l=!1);var h=function(t){return i&&n?a(t,1)[0]:a.apply(k,ce([t],e))},f={func:zr,args:[h],thisArg:k},d=s&&!o;if(i&&!n)return d?(u=u.clone(),u.__actions__.push(f),t.call(u)):a.call(k,this.value())[0];if(!i&&l){u=d?u:new J(this);var p=t.apply(u,e);return p.__actions__.push(f),new v(p,n)}return this.thru(h)})}),ee(["join","pop","push","replace","shift","sort","splice","split","unshift"],function(t){var n=(/^(?:replace|split)$/.test(t)?Ka:Xa)[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",i=/^(?:join|pop|replace|shift)$/.test(t);e.prototype[t]=function(){var t=arguments;return i&&!this.__chain__?n.apply(this.value(),t):this[r](function(e){return n.apply(e,t)})}}),Fe(J.prototype,function(t,n){var r=e[n];if(r){var i=r.name,a=Lu[i]||(Lu[i]=[]);a.push({name:n,func:r})}}),Lu[Bn(k,M).name]=[{name:"wrapper",func:k}],J.prototype.clone=et,J.prototype.reverse=rt,J.prototype.value=Vt,e.prototype.chain=Vr,e.prototype.commit=$r,e.prototype.concat=to,e.prototype.plant=Gr,e.prototype.reverse=Hr,e.prototype.toString=Wr,e.prototype.run=e.prototype.toJSON=e.prototype.valueOf=e.prototype.value=Zr,e.prototype.collect=e.prototype.map,e.prototype.head=e.prototype.first,e.prototype.select=e.prototype.filter,e.prototype.tail=e.prototype.rest,e}var k,D="3.10.1",C=1,M=2,S=4,T=8,F=16,B=32,L=64,N=128,O=256,I=30,R="...",P=150,q=16,j=200,U=1,Y=2,z="Expected a function",V="__lodash_placeholder__",$="[object Arguments]",G="[object Array]",H="[object Boolean]",W="[object Date]",Z="[object Error]",X="[object Function]",J="[object Map]",K="[object Number]",Q="[object Object]",tt="[object RegExp]",et="[object Set]",nt="[object String]",rt="[object WeakMap]",it="[object ArrayBuffer]",at="[object Float32Array]",ut="[object Float64Array]",ot="[object Int8Array]",st="[object Int16Array]",ct="[object Int32Array]",lt="[object Uint8Array]",ht="[object Uint8ClampedArray]",ft="[object Uint16Array]",dt="[object Uint32Array]",pt=/\b__p \+= '';/g,gt=/\b(__p \+=) '' \+/g,yt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,mt=/&(?:amp|lt|gt|quot|#39|#96);/g,vt=/[&<>"'`]/g,bt=RegExp(mt.source),_t=RegExp(vt.source),xt=/<%-([\s\S]+?)%>/g,wt=/<%([\s\S]+?)%>/g,At=/<%=([\s\S]+?)%>/g,Et=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\n\\]|\\.)*?\1)\]/,kt=/^\w*$/,Dt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g,Ct=/^[:!,]|[\\^$.*+?()[\]{}|\/]|(^[0-9a-fA-Fnrtuvx])|([\n\r\u2028\u2029])/g,Mt=RegExp(Ct.source),St=/[\u0300-\u036f\ufe20-\ufe23]/g,Tt=/\\(\\)?/g,Ft=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Bt=/\w*$/,Lt=/^0[xX]/,Nt=/^\[object .+?Constructor\]$/,Ot=/^\d+$/,It=/[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g,Rt=/($^)/,Pt=/['\n\r\u2028\u2029\\]/g,qt=function(){var t="[A-Z\\xc0-\\xd6\\xd8-\\xde]",e="[a-z\\xdf-\\xf6\\xf8-\\xff]+";return RegExp(t+"+(?="+t+e+")|"+t+"?"+e+"|"+t+"+|[0-9]+","g")}(),jt=["Array","ArrayBuffer","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Math","Number","Object","RegExp","Set","String","_","clearTimeout","isFinite","parseFloat","parseInt","setTimeout","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap"],Ut=-1,Yt={};Yt[at]=Yt[ut]=Yt[ot]=Yt[st]=Yt[ct]=Yt[lt]=Yt[ht]=Yt[ft]=Yt[dt]=!0,Yt[$]=Yt[G]=Yt[it]=Yt[H]=Yt[W]=Yt[Z]=Yt[X]=Yt[J]=Yt[K]=Yt[Q]=Yt[tt]=Yt[et]=Yt[nt]=Yt[rt]=!1;var zt={};zt[$]=zt[G]=zt[it]=zt[H]=zt[W]=zt[at]=zt[ut]=zt[ot]=zt[st]=zt[ct]=zt[K]=zt[Q]=zt[tt]=zt[nt]=zt[lt]=zt[ht]=zt[ft]=zt[dt]=!0,zt[Z]=zt[X]=zt[J]=zt[et]=zt[rt]=!1;var Vt={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss"},$t={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},Gt={"&":"&","<":"<",">":">",""":'"',"'":"'","`":"`"},Ht={"function":!0,object:!0},Wt={0:"x30",1:"x31",2:"x32",3:"x33",4:"x34",5:"x35",6:"x36",7:"x37",8:"x38",9:"x39",A:"x41",B:"x42",C:"x43",D:"x44",E:"x45",F:"x46",a:"x61",b:"x62",c:"x63",d:"x64",e:"x65",f:"x66",n:"x6e",r:"x72",t:"x74",u:"x75",v:"x76",x:"x78"},Zt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Xt=Ht[typeof n]&&n&&!n.nodeType&&n,Jt=Ht[typeof e]&&e&&!e.nodeType&&e,Kt=Xt&&Jt&&"object"==typeof t&&t&&t.Object&&t,Qt=Ht[typeof self]&&self&&self.Object&&self,te=Ht[typeof window]&&window&&window.Object&&window,ee=Jt&&Jt.exports===Xt&&Xt,ne=Kt||te!==(this&&this.window)&&te||Qt||this,re=E();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(ne._=re,define(function(){return re})):Xt&&Jt?ee?(Jt.exports=re)._=re:Xt._=re:ne._=re}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],54:[function(t,e){e.exports={graphlib:t("./lib/graphlib"),layout:t("./lib/layout"),debug:t("./lib/debug"),util:{time:t("./lib/util").time,notime:t("./lib/util").notime},version:t("./lib/version")}},{"./lib/debug":59,"./lib/graphlib":60,"./lib/layout":62,"./lib/util":82,"./lib/version":83}],55:[function(t,e){"use strict";function n(t){function e(t){return function(e){return t.edge(e).weight}}var n="greedy"===t.graph().acyclicer?u(t,e(t)):r(t);a.each(n,function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,a.uniqueId("rev"))})}function r(t){function e(u){a.has(i,u)||(i[u]=!0,r[u]=!0,a.each(t.outEdges(u),function(t){a.has(r,t.w)?n.push(t):e(t.w)}),delete r[u])}var n=[],r={},i={};return a.each(t.nodes(),e),n}function i(t){a.each(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)}})}var a=t("./lodash"),u=t("./greedy-fas");e.exports={run:n,undo:i}},{"./greedy-fas":61,"./lodash":63}],56:[function(t,e){function n(t){function e(n){var a=t.children(n),u=t.node(n);if(a.length&&i.each(a,e),i.has(u,"minRank")){u.borderLeft=[],u.borderRight=[];for(var o=u.minRank,s=u.maxRank+1;s>o;++o)r(t,"borderLeft","_bl",n,u,o),r(t,"borderRight","_br",n,u,o)}}i.each(t.children(),e)}function r(t,e,n,r,i,u){var o={width:0,height:0,rank:u,borderType:e},s=i[e][u-1],c=a.addDummyNode(t,"border",o,n);i[e][u]=c,t.setParent(c,r),s&&t.setEdge(s,c,{weight:1})}var i=t("./lodash"),a=t("./util");e.exports=n},{"./lodash":63,"./util":82}],57:[function(t,e){"use strict";function n(t){var e=t.graph().rankdir.toLowerCase();("lr"===e||"rl"===e)&&i(t)}function r(t){var e=t.graph().rankdir.toLowerCase();("bt"===e||"rl"===e)&&u(t),("lr"===e||"rl"===e)&&(s(t),i(t))}function i(t){l.each(t.nodes(),function(e){a(t.node(e))}),l.each(t.edges(),function(e){a(t.edge(e))})}function a(t){var e=t.width;t.width=t.height,t.height=e}function u(t){l.each(t.nodes(),function(e){o(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,o),l.has(n,"y")&&o(n)})}function o(t){t.y=-t.y}function s(t){l.each(t.nodes(),function(e){c(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,c),l.has(n,"x")&&c(n)})}function c(t){var e=t.x;t.x=t.y,t.y=e}var l=t("./lodash");e.exports={adjust:n,undo:r}},{"./lodash":63}],58:[function(t,e){function n(){var t={};t._next=t._prev=t,this._sentinel=t}function r(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function i(t,e){return"_next"!==t&&"_prev"!==t?e:void 0}e.exports=n,n.prototype.dequeue=function(){var t=this._sentinel,e=t._prev;return e!==t?(r(e),e):void 0},n.prototype.enqueue=function(t){var e=this._sentinel;t._prev&&t._next&&r(t),t._next=e._next,e._next._prev=t,e._next=t,t._prev=e},n.prototype.toString=function(){for(var t=[],e=this._sentinel,n=e._prev;n!==e;)t.push(JSON.stringify(n,i)),n=n._prev;return"["+t.join(", ")+"]"}},{}],59:[function(t,e){function n(t){var e=i.buildLayerMatrix(t),n=new a({compound:!0,multigraph:!0}).setGraph({});return r.each(t.nodes(),function(e){n.setNode(e,{label:e}),n.setParent(e,"layer"+t.node(e).rank)}),r.each(t.edges(),function(t){n.setEdge(t.v,t.w,{},t.name)}),r.each(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}var r=t("./lodash"),i=t("./util"),a=t("./graphlib").Graph;e.exports={debugOrdering:n}},{"./graphlib":60,"./lodash":63,"./util":82}],60:[function(t,e){var n;if("function"==typeof t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:84}],61:[function(t,e){function n(t,e){if(t.nodeCount()<=1)return[];var n=a(t,e||l),i=r(n.graph,n.buckets,n.zeroIdx);return o.flatten(o.map(i,function(e){return t.outEdges(e.v,e.w)}),!0)}function r(t,e,n){for(var r,a=[],u=e[e.length-1],o=e[0];t.nodeCount();){for(;r=o.dequeue();)i(t,e,n,r);for(;r=u.dequeue();)i(t,e,n,r);if(t.nodeCount())for(var s=e.length-2;s>0;--s)if(r=e[s].dequeue()){a=a.concat(i(t,e,n,r,!0));break}}return a}function i(t,e,n,r,i){var a=i?[]:void 0;return o.each(t.inEdges(r.v),function(r){var o=t.edge(r),s=t.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,u(e,n,s)}),o.each(t.outEdges(r.v),function(r){var i=t.edge(r),a=r.w,o=t.node(a);o["in"]-=i,u(e,n,o)}),t.removeNode(r.v),a}function a(t,e){var n=new s,r=0,i=0;o.each(t.nodes(),function(t){n.setNode(t,{v:t,"in":0,out:0})}),o.each(t.edges(),function(t){var a=n.edge(t.v,t.w)||0,u=e(t),o=a+u;n.setEdge(t.v,t.w,o),i=Math.max(i,n.node(t.v).out+=u),r=Math.max(r,n.node(t.w)["in"]+=u)});var a=o.range(i+r+3).map(function(){return new c}),l=r+1;return o.each(n.nodes(),function(t){u(a,l,n.node(t))}),{graph:n,buckets:a,zeroIdx:l}}function u(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)}var o=t("./lodash"),s=t("./graphlib").Graph,c=t("./data/list");e.exports=n;var l=o.constant(1)},{"./data/list":58,"./graphlib":60,"./lodash":63}],62:[function(t,e){"use strict";function n(t,e){var n=e&&e.debugTiming?B.time:B.notime;n("layout",function(){var e=n(" buildLayoutGraph",function(){return a(t)});n(" runLayout",function(){r(e,n)}),n(" updateInputGraph",function(){i(t,e)})})}function r(t,e){e(" makeSpaceForEdgeLabels",function(){u(t)}),e(" removeSelfEdges",function(){g(t)}),e(" acyclic",function(){x.run(t)}),e(" nestingGraph.run",function(){C.run(t)}),e(" rank",function(){A(B.asNonCompoundGraph(t))}),e(" injectEdgeLabelProxies",function(){o(t)}),e(" removeEmptyRanks",function(){D(t)}),e(" nestingGraph.cleanup",function(){C.cleanup(t)}),e(" normalizeRanks",function(){E(t)}),e(" assignRankMinMax",function(){s(t)}),e(" removeEdgeLabelProxies",function(){c(t)}),e(" normalize.run",function(){w.run(t)}),e(" parentDummyChains",function(){k(t)}),e(" addBorderSegments",function(){M(t)}),e(" order",function(){T(t)}),e(" insertSelfEdges",function(){y(t)}),e(" adjustCoordinateSystem",function(){S.adjust(t)}),e(" position",function(){F(t)}),e(" positionSelfEdges",function(){m(t)}),e(" removeBorderNodes",function(){p(t)}),e(" normalize.undo",function(){w.undo(t)}),e(" fixupEdgeLabelCoords",function(){f(t)}),e(" undoCoordinateSystem",function(){S.undo(t)}),e(" translateGraph",function(){l(t)}),e(" assignNodeIntersects",function(){h(t)}),e(" reversePoints",function(){d(t)}),e(" acyclic.undo",function(){x.undo(t)})}function i(t,e){_.each(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))}),_.each(t.edges(),function(n){var r=t.edge(n),i=e.edge(n);r.points=i.points,_.has(i,"x")&&(r.x=i.x,r.y=i.y)}),t.graph().width=e.graph().width,t.graph().height=e.graph().height}function a(t){var e=new L({multigraph:!0,compound:!0}),n=b(t.graph());return e.setGraph(_.merge({},O,v(n,N),_.pick(n,I))),_.each(t.nodes(),function(n){var r=b(t.node(n));e.setNode(n,_.defaults(v(r,R),P)),e.setParent(n,t.parent(n))}),_.each(t.edges(),function(n){var r=b(t.edge(n));e.setEdge(n,_.merge({},j,v(r,q),_.pick(r,U)))}),e}function u(t){var e=t.graph();e.ranksep/=2,_.each(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)})}function o(t){_.each(t.edges(),function(e){var n=t.edge(e);if(n.width&&n.height){var r=t.node(e.v),i=t.node(e.w),a={rank:(i.rank-r.rank)/2+r.rank,e:e};B.addDummyNode(t,"edge-proxy",a,"_ep")}})}function s(t){var e=0;_.each(t.nodes(),function(n){var r=t.node(n);r.borderTop&&(r.minRank=t.node(r.borderTop).rank,r.maxRank=t.node(r.borderBottom).rank,e=_.max(e,r.maxRank))}),t.graph().maxRank=e}function c(t){_.each(t.nodes(),function(e){var n=t.node(e);"edge-proxy"===n.dummy&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))})}function l(t){function e(t){var e=t.x,u=t.y,o=t.width,s=t.height;n=Math.min(n,e-o/2),r=Math.max(r,e+o/2),i=Math.min(i,u-s/2),a=Math.max(a,u+s/2)}var n=Number.POSITIVE_INFINITY,r=0,i=Number.POSITIVE_INFINITY,a=0,u=t.graph(),o=u.marginx||0,s=u.marginy||0;_.each(t.nodes(),function(n){e(t.node(n))}),_.each(t.edges(),function(n){var r=t.edge(n);_.has(r,"x")&&e(r)}),n-=o,i-=s,_.each(t.nodes(),function(e){var r=t.node(e);r.x-=n,r.y-=i}),_.each(t.edges(),function(e){var r=t.edge(e);_.each(r.points,function(t){t.x-=n,t.y-=i}),_.has(r,"x")&&(r.x-=n),_.has(r,"y")&&(r.y-=i)}),u.width=r-n+o,u.height=a-i+s}function h(t){_.each(t.edges(),function(e){var n,r,i=t.edge(e),a=t.node(e.v),u=t.node(e.w);i.points?(n=i.points[0],r=i.points[i.points.length-1]):(i.points=[],n=u,r=a),i.points.unshift(B.intersectRect(a,n)),i.points.push(B.intersectRect(u,r))})}function f(t){_.each(t.edges(),function(e){var n=t.edge(e);if(_.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}})}function d(t){_.each(t.edges(),function(e){var n=t.edge(e);n.reversed&&n.points.reverse()})}function p(t){_.each(t.nodes(),function(e){if(t.children(e).length){var n=t.node(e),r=t.node(n.borderTop),i=t.node(n.borderBottom),a=t.node(_.last(n.borderLeft)),u=t.node(_.last(n.borderRight));n.width=Math.abs(u.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),_.each(t.nodes(),function(e){"border"===t.node(e).dummy&&t.removeNode(e)})}function g(t){_.each(t.edges(),function(e){if(e.v===e.w){var n=t.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e:e,label:t.edge(e)}),t.removeEdge(e)}})}function y(t){var e=B.buildLayerMatrix(t);_.each(e,function(e){var n=0;_.each(e,function(e,r){var i=t.node(e);i.order=r+n,_.each(i.selfEdges,function(e){B.addDummyNode(t,"selfedge",{width:e.label.width,height:e.label.height,rank:i.rank,order:r+ ++n,e:e.e,label:e.label},"_se")}),delete i.selfEdges})})}function m(t){_.each(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,u=n.x-i,o=r.height/2;t.setEdge(n.e,n.label),t.removeNode(e),n.label.points=[{x:i+2*u/3,y:a-o},{x:i+5*u/6,y:a-o},{x:i+u,y:a},{x:i+5*u/6,y:a+o},{x:i+2*u/3,y:a+o}],n.label.x=n.x,n.label.y=n.y}})}function v(t,e){return _.mapValues(_.pick(t,e),Number)}function b(t){var e={};return _.each(t,function(t,n){e[n.toLowerCase()]=t}),e}var _=t("./lodash"),x=t("./acyclic"),w=t("./normalize"),A=t("./rank"),E=t("./util").normalizeRanks,k=t("./parent-dummy-chains"),D=t("./util").removeEmptyRanks,C=t("./nesting-graph"),M=t("./add-border-segments"),S=t("./coordinate-system"),T=t("./order"),F=t("./position"),B=t("./util"),L=t("./graphlib").Graph;e.exports=n;var N=["nodesep","edgesep","ranksep","marginx","marginy"],O={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},I=["acyclicer","ranker","rankdir","align"],R=["width","height"],P={width:0,height:0},q=["minlen","weight","width","height","labeloffset"],j={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},U=["labelpos"]},{"./acyclic":55,"./add-border-segments":56,"./coordinate-system":57,"./graphlib":60,"./lodash":63,"./nesting-graph":64,"./normalize":65,"./order":70,"./parent-dummy-chains":75,"./position":77,"./rank":79,"./util":82}],63:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":51,lodash:104}],64:[function(t,e){function n(t){var e=s.addDummyNode(t,"root",{},"_root"),n=i(t),u=o.max(n)-1,c=2*u+1;t.graph().nestingRoot=e,o.each(t.edges(),function(e){t.edge(e).minlen*=c});var l=a(t)+1;o.each(t.children(),function(i){r(t,e,c,l,u,n,i)}),t.graph().nodeRankFactor=c}function r(t,e,n,i,a,u,c){var l=t.children(c);if(!l.length)return void(c!==e&&t.setEdge(e,c,{weight:0,minlen:n}));var h=s.addBorderNode(t,"_bt"),f=s.addBorderNode(t,"_bb"),d=t.node(c);t.setParent(h,c),d.borderTop=h,t.setParent(f,c),d.borderBottom=f,o.each(l,function(o){r(t,e,n,i,a,u,o);var s=t.node(o),l=s.borderTop?s.borderTop:o,d=s.borderBottom?s.borderBottom:o,p=s.borderTop?i:2*i,g=l!==d?1:a-u[c]+1;t.setEdge(h,l,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(d,f,{weight:p,minlen:g,nestingEdge:!0})}),t.parent(c)||t.setEdge(e,h,{weight:0,minlen:a+u[c]})}function i(t){function e(r,i){var a=t.children(r);a&&a.length&&o.each(a,function(t){e(t,i+1)}),n[r]=i}var n={};return o.each(t.children(),function(t){e(t,1)}),n}function a(t){return o.reduce(t.edges(),function(e,n){return e+t.edge(n).weight},0)}function u(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,o.each(t.edges(),function(e){var n=t.edge(e);n.nestingEdge&&t.removeEdge(e)})}var o=t("./lodash"),s=t("./util");e.exports={run:n,cleanup:u}},{"./lodash":63,"./util":82}],65:[function(t,e){"use strict";function n(t){t.graph().dummyChains=[],a.each(t.edges(),function(e){r(t,e)})}function r(t,e){var n=e.v,r=t.node(n).rank,i=e.w,a=t.node(i).rank,o=e.name,s=t.edge(e),c=s.labelRank;if(a!==r+1){t.removeEdge(e);var l,h,f;for(f=0,++r;a>r;++f,++r)s.points=[],h={width:0,height:0,edgeLabel:s,edgeObj:e,rank:r},l=u.addDummyNode(t,"edge",h,"_d"),r===c&&(h.width=s.width,h.height=s.height,h.dummy="edge-label",h.labelpos=s.labelpos),t.setEdge(n,l,{weight:s.weight},o),0===f&&t.graph().dummyChains.push(l),n=l;t.setEdge(n,i,{weight:s.weight},o)}}function i(t){a.each(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)})}var a=t("./lodash"),u=t("./util");e.exports={run:n,undo:i}},{"./lodash":63,"./util":82}],66:[function(t,e){function n(t,e,n){var i,a={};r.each(n,function(n){for(var r,u,o=t.parent(n);o;){if(r=t.parent(o),r?(u=a[r],a[r]=o):(u=i,i=o),u&&u!==o)return void e.setEdge(u,o);o=r}})}var r=t("../lodash");e.exports=n},{"../lodash":63}],67:[function(t,e){function n(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}})}var r=t("../lodash");e.exports=n},{"../lodash":63}],68:[function(t,e){function n(t,e,n){var u=r(t),o=new a({compound:!0}).setGraph({root:u}).setDefaultNodeLabel(function(e){return t.node(e)});return i.each(t.nodes(),function(r){var a=t.node(r),s=t.parent(r);(a.rank===e||a.minRank<=e&&e<=a.maxRank)&&(o.setNode(r),o.setParent(r,s||u),i.each(t[n](r),function(e){var n=e.v===r?e.w:e.v,a=o.edge(n,r),u=i.isUndefined(a)?0:a.weight;o.setEdge(n,r,{weight:t.edge(e).weight+u})}),i.has(a,"minRank")&&o.setNode(r,{borderLeft:a.borderLeft[e],borderRight:a.borderRight[e]}))}),o}function r(t){for(var e;t.hasNode(e=i.uniqueId("_root")););return e}var i=t("../lodash"),a=t("../graphlib").Graph;e.exports=n},{"../graphlib":60,"../lodash":63}],69:[function(t,e){"use strict";function n(t,e){for(var n=0,i=1;i0;)e%2&&(n+=s[e+1]),e=e-1>>1,s[e]+=t.weight;c+=t.weight*n})),c}var i=t("../lodash");e.exports=n},{"../lodash":63}],70:[function(t,e){"use strict";function n(t){var e=d.maxRank(t),n=r(t,u.range(1,e+1),"inEdges"),c=r(t,u.range(e-1,-1,-1),"outEdges"),l=o(t);a(t,l);for(var h,f=Number.POSITIVE_INFINITY,p=0,g=0;4>g;++p,++g){i(p%2?n:c,p%4>=2),l=d.buildLayerMatrix(t);var y=s(t,l);f>y&&(g=0,h=u.cloneDeep(l),f=y)}a(t,h)}function r(t,e,n){return u.map(e,function(e){return l(t,e,n)})}function i(t,e){var n=new f;u.each(t,function(t){var r=t.graph().root,i=c(t,r,n,e);u.each(i.vs,function(e,n){t.node(e).order=n}),h(t,n,i.vs)})}function a(t,e){u.each(e,function(e){u.each(e,function(e,n){t.node(e).order=n})})}var u=t("../lodash"),o=t("./init-order"),s=t("./cross-count"),c=t("./sort-subgraph"),l=t("./build-layer-graph"),h=t("./add-subgraph-constraints"),f=t("../graphlib").Graph,d=t("../util");e.exports=n},{"../graphlib":60,"../lodash":63,"../util":82,"./add-subgraph-constraints":66,"./build-layer-graph":68,"./cross-count":69,"./init-order":71,"./sort-subgraph":73}],71:[function(t,e){"use strict";function n(t){function e(i){if(!r.has(n,i)){n[i]=!0;var a=t.node(i);u[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})),u=r.map(r.range(a+1),function(){return[]}),o=r.sortBy(i,function(e){return t.node(e).rank});return r.each(o,e),u}var r=t("../lodash");e.exports=n},{"../lodash":63}],72:[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 u=t.pop();r.push(u),a.each(u["in"].reverse(),e(u)),a.each(u.out,n(u))}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":63}],73:[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=u(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=s(m,l);if(d&&(v.vs=a.flatten([d,v.vs,p],!0),t.predecessors(d).length)){var b=t.node(t.predecessors(d)[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 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"),u=t("./barycenter"),o=t("./resolve-conflicts"),s=t("./sort");e.exports=n},{"../lodash":63,"./barycenter":67,"./resolve-conflicts":72,"./sort":74}],74:[function(t,e){function n(t,e){var n=u.partition(t,function(t){return a.has(t,"barycenter")}),o=n.lhs,s=a.sortBy(n.rhs,function(t){return-t.i}),c=[],l=0,h=0,f=0;o.sort(i(!!e)),f=r(c,s,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,s,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.barycentern.barycenter?1:t?n.i-e.i:e.i-n.i}}var a=t("../lodash"),u=t("../util");e.exports=n},{"../lodash":63,"../util":82}],75:[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,u=r(t,e,a.v,a.w),o=u.path,s=u.lca,c=0,l=o[c],h=!0;n!==a.w;){if(i=t.node(n),h){for(;(l=o[c])!==s&&t.node(l).maxRanks||c>e[i].lim));for(a=i,i=r;(i=t.parent(i))!==a;)o.push(i);return{path:u.concat(o.reverse()),lca:a}}function i(t){function e(i){var u=r;a.each(t.children(i),e),n[i]={low:u,lim:r++}}var n={},r=0;return a.each(t.children(),e),n}var a=t("./lodash");e.exports=n},{"./lodash":63}],76:[function(t,e){"use strict";function n(t,e){function n(e,n){ var u=0,o=0,s=e.length,c=y.last(n);return y.each(n,function(e,l){var h=i(t,e),f=h?t.node(h).order:s;(h||e===c)&&(y.each(n.slice(o,l+1),function(e){y.each(t.predecessors(e),function(n){var i=t.node(n),o=i.order;!(u>o||o>f)||i.dummy&&t.node(e).dummy||a(r,n,e)})}),o=l+1,u=f)}),n}var r={};return y.reduce(e,n),r}function r(t,e){function n(e,n,r,u,o){var s;y.each(y.range(n,r),function(n){s=e[n],t.node(s).dummy&&y.each(t.predecessors(s),function(e){var n=t.node(e);n.dummy&&(n.ordero)&&a(i,e,s)})})}function r(e,r){var i,a=-1,u=0;return y.each(r,function(o,s){if("border"===t.node(o).dummy){var c=t.predecessors(o);c.length&&(i=t.node(c[0]).order,n(r,u,s,a,i),u=s,a=i)}n(r,u,r.length,i,e.length)}),r}var i={};return y.reduce(e,r),i}function i(t,e){return t.node(e).dummy?y.find(t.predecessors(e),function(e){return t.node(e).dummy}):void 0}function a(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 r=e;e=n,n=r}return y.has(t[e],n)}function o(t,e,n,r){var i={},a={},o={};return y.each(e,function(t){y.each(t,function(t,e){i[t]=t,a[t]=t,o[t]=e})}),y.each(e,function(t){var e=-1;y.each(t,function(t){var s=r(t);if(s.length){s=y.sortBy(s,function(t){return o[t]});for(var c=(s.length-1)/2,l=Math.floor(c),h=Math.ceil(c);h>=l;++l){var f=s[l];a[t]===t&&eu.lim&&(o=u,s=!0);var c=p.filter(e.edges(),function(e){return s===d(t,t.node(e.v),o)&&s!==d(t,t.node(e.w),o)});return p.min(c,function(t){return y(e,t)})}function l(t,e,n,i){var a=n.v,o=n.w;t.removeEdge(a,o),t.setEdge(i.v,i.w,{}),u(t),r(t,e),h(t,e)}function h(t,e){var n=p.find(t.nodes(),function(t){return!e.node(t).parent}),r=v(t,n);r=r.slice(1),p.each(r,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)})}function f(t,e,n){return t.hasEdge(e,n)}function d(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}var p=t("../lodash"),g=t("./feasible-tree"),y=t("./util").slack,m=t("./util").longestPath,v=t("../graphlib").alg.preorder,b=t("../graphlib").alg.postorder,_=t("../util").simplify;e.exports=n,n.initLowLimValues=u,n.initCutValues=r,n.calcCutValue=a,n.leaveEdge=s,n.enterEdge=c,n.exchangeEdges=l},{"../graphlib":60,"../lodash":63,"../util":82,"./feasible-tree":78,"./util":81}],81:[function(t,e){"use strict";function n(t){function e(r){var a=t.node(r);if(i.has(n,r))return a.rank;n[r]=!0;var u=i.min(i.map(t.outEdges(r),function(n){return e(n.w)-t.edge(n).minlen}));return u===Number.POSITIVE_INFINITY&&(u=0),a.rank=u}var n={};i.each(t.sources(),e)}function r(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}var i=t("../lodash");e.exports={longestPath:n,slack:r}},{"../lodash":63}],82:[function(t,e){"use strict";function n(t,e,n,r){var i;do i=y.uniqueId(r);while(t.hasNode(i));return n.dummy=e,t.setNode(i,n),i}function r(t){var e=(new m).setGraph(t.graph());return y.each(t.nodes(),function(n){e.setNode(n,t.node(n))}),y.each(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}function i(t){var e=new m({multigraph:t.isMultigraph()}).setGraph(t.graph());return y.each(t.nodes(),function(n){t.children(n).length||e.setNode(n,t.node(n))}),y.each(t.edges(),function(n){e.setEdge(n,t.edge(n))}),e}function a(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.outEdges(e),function(e){n[e.w]=(n[e.w]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function u(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.inEdges(e),function(e){n[e.v]=(n[e.v]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function o(t,e){var n=t.x,r=t.y,i=e.x-n,a=e.y-r,u=t.width/2,o=t.height/2;if(!i&&!a)throw new Error("Not possible to find intersection inside of the rectangle");var s,c;return Math.abs(a)*u>Math.abs(i)*o?(0>a&&(o=-o),s=o*i/a,c=o):(0>i&&(u=-u),s=u,c=u*a/i),{x:n+s,y:r+c}}function s(t){var e=y.map(y.range(f(t)+1),function(){return[]});return y.each(t.nodes(),function(n){var r=t.node(n),i=r.rank;y.isUndefined(i)||(e[i][r.order]=n)}),e}function c(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank}));y.each(t.nodes(),function(n){var r=t.node(n);y.has(r,"rank")&&(r.rank-=e)})}function l(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank})),n=[];y.each(t.nodes(),function(r){var i=t.node(r).rank-e;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=t.graph().nodeRankFactor;y.each(n,function(e,n){y.isUndefined(e)&&n%i!==0?--r:r&&y.each(e,function(e){t.node(e).rank+=r})})}function h(t,e,r,i){var a={width:0,height:0};return arguments.length>=4&&(a.rank=r,a.order=i),n(t,"border",a,e)}function f(t){return y.max(y.map(t.nodes(),function(e){var n=t.node(e).rank;return y.isUndefined(n)?void 0:n}))}function d(t,e){var n={lhs:[],rhs:[]};return y.each(t,function(t){e(t)?n.lhs.push(t):n.rhs.push(t)}),n}function p(t,e){var n=y.now();try{return e()}finally{console.log(t+" time: "+(y.now()-n)+"ms")}}function g(t,e){return e()}var y=t("./lodash"),m=t("./graphlib").Graph;e.exports={addDummyNode:n,simplify:r,asNonCompoundGraph:i,successorWeights:a,predecessorWeights:u,intersectRect:o,buildLayerMatrix:s,normalizeRanks:c,removeEmptyRanks:l,addBorderNode:h,maxRank:f,partition:d,time:p,notime:g}},{"./graphlib":60,"./lodash":63}],83:[function(t,e){e.exports="0.7.4"},{}],84:[function(t,e){e.exports=t(33)},{"./lib":100,"./lib/alg":91,"./lib/json":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/index.js":33}],85:[function(t,e){e.exports=t(34)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/components.js":34}],86:[function(t,e){e.exports=t(35)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dfs.js":35}],87:[function(t,e){e.exports=t(36)},{"../lodash":102,"./dijkstra":88,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra-all.js":36}],88:[function(t,e){e.exports=t(37)},{"../data/priority-queue":98,"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra.js":37}],89:[function(t,e){e.exports=t(38)},{"../lodash":102,"./tarjan":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/find-cycles.js":38}],90:[function(t,e){e.exports=t(39)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/floyd-warshall.js":39}],91:[function(t,e){e.exports=t(40)},{"./components":85,"./dijkstra":88,"./dijkstra-all":87,"./find-cycles":89,"./floyd-warshall":90,"./is-acyclic":92,"./postorder":93,"./preorder":94,"./prim":95,"./tarjan":96,"./topsort":97,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/index.js":40}],92:[function(t,e){e.exports=t(41)},{"./topsort":97,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/is-acyclic.js":41}],93:[function(t,e){e.exports=t(42)},{"./dfs":86,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/postorder.js":42}],94:[function(t,e){e.exports=t(43)},{"./dfs":86,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/preorder.js":43}],95:[function(t,e){e.exports=t(44)},{"../data/priority-queue":98,"../graph":99,"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/prim.js":44}],96:[function(t,e){e.exports=t(45)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/tarjan.js":45}],97:[function(t,e){e.exports=t(46)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/topsort.js":46}],98:[function(t,e){e.exports=t(47)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/data/priority-queue.js":47}],99:[function(t,e){e.exports=t(48)},{"./lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/graph.js":48}],100:[function(t,e){e.exports=t(49)},{"./graph":99,"./version":103,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/index.js":49}],101:[function(t,e){e.exports=t(50)},{"./graph":99,"./lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/json.js":50}],102:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":51,lodash:104}],103:[function(t,e){e.exports=t(52)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/version.js":52}],104:[function(t,e){e.exports=t(53)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/lodash/index.js":53}],105:[function(t,e,n){(function(t){!function(r){var i="object"==typeof n&&n,a="object"==typeof e&&e&&e.exports==i&&e,u="object"==typeof t&&t;(u.global===u||u.window===u)&&(r=u);var o=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,s=/[\x01-\x7F]/g,c=/[\x01-\t\x0B\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,l=/<\u20D2|=\u20E5|>\u20D2|\u205F\u200A|\u219D\u0338|\u2202\u0338|\u2220\u20D2|\u2229\uFE00|\u222A\uFE00|\u223C\u20D2|\u223D\u0331|\u223E\u0333|\u2242\u0338|\u224B\u0338|\u224D\u20D2|\u224E\u0338|\u224F\u0338|\u2250\u0338|\u2261\u20E5|\u2264\u20D2|\u2265\u20D2|\u2266\u0338|\u2267\u0338|\u2268\uFE00|\u2269\uFE00|\u226A\u0338|\u226A\u20D2|\u226B\u0338|\u226B\u20D2|\u227F\u0338|\u2282\u20D2|\u2283\u20D2|\u228A\uFE00|\u228B\uFE00|\u228F\u0338|\u2290\u0338|\u2293\uFE00|\u2294\uFE00|\u22B4\u20D2|\u22B5\u20D2|\u22D8\u0338|\u22D9\u0338|\u22DA\uFE00|\u22DB\uFE00|\u22F5\u0338|\u22F9\u0338|\u2933\u0338|\u29CF\u0338|\u29D0\u0338|\u2A6D\u0338|\u2A70\u0338|\u2A7D\u0338|\u2A7E\u0338|\u2AA1\u0338|\u2AA2\u0338|\u2AAC\uFE00|\u2AAD\uFE00|\u2AAF\u0338|\u2AB0\u0338|\u2AC5\u0338|\u2AC6\u0338|\u2ACB\uFE00|\u2ACC\uFE00|\u2AFD\u20E5|[\xA0-\u0113\u0116-\u0122\u0124-\u012B\u012E-\u014D\u0150-\u017E\u0192\u01B5\u01F5\u0237\u02C6\u02C7\u02D8-\u02DD\u0311\u0391-\u03A1\u03A3-\u03A9\u03B1-\u03C9\u03D1\u03D2\u03D5\u03D6\u03DC\u03DD\u03F0\u03F1\u03F5\u03F6\u0401-\u040C\u040E-\u044F\u0451-\u045C\u045E\u045F\u2002-\u2005\u2007-\u2010\u2013-\u2016\u2018-\u201A\u201C-\u201E\u2020-\u2022\u2025\u2026\u2030-\u2035\u2039\u203A\u203E\u2041\u2043\u2044\u204F\u2057\u205F-\u2063\u20AC\u20DB\u20DC\u2102\u2105\u210A-\u2113\u2115-\u211E\u2122\u2124\u2127-\u2129\u212C\u212D\u212F-\u2131\u2133-\u2138\u2145-\u2148\u2153-\u215E\u2190-\u219B\u219D-\u21A7\u21A9-\u21AE\u21B0-\u21B3\u21B5-\u21B7\u21BA-\u21DB\u21DD\u21E4\u21E5\u21F5\u21FD-\u2205\u2207-\u2209\u220B\u220C\u220F-\u2214\u2216-\u2218\u221A\u221D-\u2238\u223A-\u2257\u2259\u225A\u225C\u225F-\u2262\u2264-\u228B\u228D-\u229B\u229D-\u22A5\u22A7-\u22B0\u22B2-\u22BB\u22BD-\u22DB\u22DE-\u22E3\u22E6-\u22F7\u22F9-\u22FE\u2305\u2306\u2308-\u2310\u2312\u2313\u2315\u2316\u231C-\u231F\u2322\u2323\u232D\u232E\u2336\u233D\u233F\u237C\u23B0\u23B1\u23B4-\u23B6\u23DC-\u23DF\u23E2\u23E7\u2423\u24C8\u2500\u2502\u250C\u2510\u2514\u2518\u251C\u2524\u252C\u2534\u253C\u2550-\u256C\u2580\u2584\u2588\u2591-\u2593\u25A1\u25AA\u25AB\u25AD\u25AE\u25B1\u25B3-\u25B5\u25B8\u25B9\u25BD-\u25BF\u25C2\u25C3\u25CA\u25CB\u25EC\u25EF\u25F8-\u25FC\u2605\u2606\u260E\u2640\u2642\u2660\u2663\u2665\u2666\u266A\u266D-\u266F\u2713\u2717\u2720\u2736\u2758\u2772\u2773\u27C8\u27C9\u27E6-\u27ED\u27F5-\u27FA\u27FC\u27FF\u2902-\u2905\u290C-\u2913\u2916\u2919-\u2920\u2923-\u292A\u2933\u2935-\u2939\u293C\u293D\u2945\u2948-\u294B\u294E-\u2976\u2978\u2979\u297B-\u297F\u2985\u2986\u298B-\u2996\u299A\u299C\u299D\u29A4-\u29B7\u29B9\u29BB\u29BC\u29BE-\u29C5\u29C9\u29CD-\u29D0\u29DC-\u29DE\u29E3-\u29E5\u29EB\u29F4\u29F6\u2A00-\u2A02\u2A04\u2A06\u2A0C\u2A0D\u2A10-\u2A17\u2A22-\u2A27\u2A29\u2A2A\u2A2D-\u2A31\u2A33-\u2A3C\u2A3F\u2A40\u2A42-\u2A4D\u2A50\u2A53-\u2A58\u2A5A-\u2A5D\u2A5F\u2A66\u2A6A\u2A6D-\u2A75\u2A77-\u2A9A\u2A9D-\u2AA2\u2AA4-\u2AB0\u2AB3-\u2AC8\u2ACB\u2ACC\u2ACF-\u2ADB\u2AE4\u2AE6-\u2AE9\u2AEB-\u2AF3\u2AFD\uFB00-\uFB04]|\uD835[\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDCCF\uDD04\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDD6B]/g,h={"Á":"Aacute","á":"aacute","Ă":"Abreve","ă":"abreve","∾":"ac","∿":"acd","∾̳":"acE","Â":"Acirc","â":"acirc","´":"acute","А":"Acy","а":"acy","Æ":"AElig","æ":"aelig","⁡":"af","𝔄":"Afr","𝔞":"afr","À":"Agrave","à":"agrave","ℵ":"aleph","Α":"Alpha","α":"alpha","Ā":"Amacr","ā":"amacr","⨿":"amalg","&":"amp","⩕":"andand","⩓":"And","∧":"and","⩜":"andd","⩘":"andslope","⩚":"andv","∠":"ang","⦤":"ange","⦨":"angmsdaa","⦩":"angmsdab","⦪":"angmsdac","⦫":"angmsdad","⦬":"angmsdae","⦭":"angmsdaf","⦮":"angmsdag","⦯":"angmsdah","∡":"angmsd","∟":"angrt","⊾":"angrtvb","⦝":"angrtvbd","∢":"angsph","Å":"angst","⍼":"angzarr","Ą":"Aogon","ą":"aogon","𝔸":"Aopf","𝕒":"aopf","⩯":"apacir","≈":"ap","⩰":"apE","≊":"ape","≋":"apid","'":"apos","å":"aring","𝒜":"Ascr","𝒶":"ascr","≔":"colone","*":"ast","≍":"CupCap","Ã":"Atilde","ã":"atilde","Ä":"Auml","ä":"auml","∳":"awconint","⨑":"awint","≌":"bcong","϶":"bepsi","‵":"bprime","∽":"bsim","⋍":"bsime","∖":"setmn","⫧":"Barv","⊽":"barvee","⌅":"barwed","⌆":"Barwed","⎵":"bbrk","⎶":"bbrktbrk","Б":"Bcy","б":"bcy","„":"bdquo","∵":"becaus","⦰":"bemptyv","ℬ":"Bscr","Β":"Beta","β":"beta","ℶ":"beth","≬":"twixt","𝔅":"Bfr","𝔟":"bfr","⋂":"xcap","◯":"xcirc","⋃":"xcup","⨀":"xodot","⨁":"xoplus","⨂":"xotime","⨆":"xsqcup","★":"starf","▽":"xdtri","△":"xutri","⨄":"xuplus","⋁":"Vee","⋀":"Wedge","⤍":"rbarr","⧫":"lozf","▪":"squf","▴":"utrif","▾":"dtrif","◂":"ltrif","▸":"rtrif","␣":"blank","▒":"blk12","░":"blk14","▓":"blk34","█":"block","=⃥":"bne","≡⃥":"bnequiv","⫭":"bNot","⌐":"bnot","𝔹":"Bopf","𝕓":"bopf","⊥":"bot","⋈":"bowtie","⧉":"boxbox","┐":"boxdl","╕":"boxdL","╖":"boxDl","╗":"boxDL","┌":"boxdr","╒":"boxdR","╓":"boxDr","╔":"boxDR","─":"boxh","═":"boxH","┬":"boxhd","╤":"boxHd","╥":"boxhD","╦":"boxHD","┴":"boxhu","╧":"boxHu","╨":"boxhU","╩":"boxHU","⊟":"minusb","⊞":"plusb","⊠":"timesb","┘":"boxul","╛":"boxuL","╜":"boxUl","╝":"boxUL","└":"boxur","╘":"boxuR","╙":"boxUr","╚":"boxUR","│":"boxv","║":"boxV","┼":"boxvh","╪":"boxvH","╫":"boxVh","╬":"boxVH","┤":"boxvl","╡":"boxvL","╢":"boxVl","╣":"boxVL","├":"boxvr","╞":"boxvR","╟":"boxVr","╠":"boxVR","˘":"breve","¦":"brvbar","𝒷":"bscr","⁏":"bsemi","⧅":"bsolb","\\":"bsol","⟈":"bsolhsub","•":"bull","≎":"bump","⪮":"bumpE","≏":"bumpe","Ć":"Cacute","ć":"cacute","⩄":"capand","⩉":"capbrcup","⩋":"capcap","∩":"cap","⋒":"Cap","⩇":"capcup","⩀":"capdot","ⅅ":"DD","∩︀":"caps","⁁":"caret","ˇ":"caron","ℭ":"Cfr","⩍":"ccaps","Č":"Ccaron","č":"ccaron","Ç":"Ccedil","ç":"ccedil","Ĉ":"Ccirc","ĉ":"ccirc","∰":"Cconint","⩌":"ccups","⩐":"ccupssm","Ċ":"Cdot","ċ":"cdot","¸":"cedil","⦲":"cemptyv","¢":"cent","·":"middot","𝔠":"cfr","Ч":"CHcy","ч":"chcy","✓":"check","Χ":"Chi","χ":"chi","ˆ":"circ","≗":"cire","↺":"olarr","↻":"orarr","⊛":"oast","⊚":"ocir","⊝":"odash","⊙":"odot","®":"reg","Ⓢ":"oS","⊖":"ominus","⊕":"oplus","⊗":"otimes","○":"cir","⧃":"cirE","⨐":"cirfnint","⫯":"cirmid","⧂":"cirscir","∲":"cwconint","”":"rdquo","’":"rsquo","♣":"clubs",":":"colon","∷":"Colon","⩴":"Colone",",":"comma","@":"commat","∁":"comp","∘":"compfn","ℂ":"Copf","≅":"cong","⩭":"congdot","≡":"equiv","∮":"oint","∯":"Conint","𝕔":"copf","∐":"coprod","©":"copy","℗":"copysr","↵":"crarr","✗":"cross","⨯":"Cross","𝒞":"Cscr","𝒸":"cscr","⫏":"csub","⫑":"csube","⫐":"csup","⫒":"csupe","⋯":"ctdot","⤸":"cudarrl","⤵":"cudarrr","⋞":"cuepr","⋟":"cuesc","↶":"cularr","⤽":"cularrp","⩈":"cupbrcap","⩆":"cupcap","∪":"cup","⋓":"Cup","⩊":"cupcup","⊍":"cupdot","⩅":"cupor","∪︀":"cups","↷":"curarr","⤼":"curarrm","⋎":"cuvee","⋏":"cuwed","¤":"curren","∱":"cwint","⌭":"cylcty","†":"dagger","‡":"Dagger","ℸ":"daleth","↓":"darr","↡":"Darr","⇓":"dArr","‐":"dash","⫤":"Dashv","⊣":"dashv","⤏":"rBarr","˝":"dblac","Ď":"Dcaron","ď":"dcaron","Д":"Dcy","д":"dcy","⇊":"ddarr","ⅆ":"dd","⤑":"DDotrahd","⩷":"eDDot","°":"deg","∇":"Del","Δ":"Delta","δ":"delta","⦱":"demptyv","⥿":"dfisht","𝔇":"Dfr","𝔡":"dfr","⥥":"dHar","⇃":"dharl","⇂":"dharr","˙":"dot","`":"grave","˜":"tilde","⋄":"diam","♦":"diams","¨":"die","ϝ":"gammad","⋲":"disin","÷":"div","⋇":"divonx","Ђ":"DJcy","ђ":"djcy","⌞":"dlcorn","⌍":"dlcrop",$:"dollar","𝔻":"Dopf","𝕕":"dopf","⃜":"DotDot","≐":"doteq","≑":"eDot","∸":"minusd","∔":"plusdo","⊡":"sdotb","⇐":"lArr","⇔":"iff","⟸":"xlArr","⟺":"xhArr","⟹":"xrArr","⇒":"rArr","⊨":"vDash","⇑":"uArr","⇕":"vArr","∥":"par","⤓":"DownArrowBar","⇵":"duarr","̑":"DownBreve","⥐":"DownLeftRightVector","⥞":"DownLeftTeeVector","⥖":"DownLeftVectorBar","↽":"lhard","⥟":"DownRightTeeVector","⥗":"DownRightVectorBar","⇁":"rhard","↧":"mapstodown","⊤":"top","⤐":"RBarr","⌟":"drcorn","⌌":"drcrop","𝒟":"Dscr","𝒹":"dscr","Ѕ":"DScy","ѕ":"dscy","⧶":"dsol","Đ":"Dstrok","đ":"dstrok","⋱":"dtdot","▿":"dtri","⥯":"duhar","⦦":"dwangle","Џ":"DZcy","џ":"dzcy","⟿":"dzigrarr","É":"Eacute","é":"eacute","⩮":"easter","Ě":"Ecaron","ě":"ecaron","Ê":"Ecirc","ê":"ecirc","≖":"ecir","≕":"ecolon","Э":"Ecy","э":"ecy","Ė":"Edot","ė":"edot","ⅇ":"ee","≒":"efDot","𝔈":"Efr","𝔢":"efr","⪚":"eg","È":"Egrave","è":"egrave","⪖":"egs","⪘":"egsdot","⪙":"el","∈":"in","⏧":"elinters","ℓ":"ell","⪕":"els","⪗":"elsdot","Ē":"Emacr","ē":"emacr","∅":"empty","◻":"EmptySmallSquare","▫":"EmptyVerySmallSquare"," ":"emsp13"," ":"emsp14"," ":"emsp","Ŋ":"ENG","ŋ":"eng"," ":"ensp","Ę":"Eogon","ę":"eogon","𝔼":"Eopf","𝕖":"eopf","⋕":"epar","⧣":"eparsl","⩱":"eplus","ε":"epsi","Ε":"Epsilon","ϵ":"epsiv","≂":"esim","⩵":"Equal","=":"equals","≟":"equest","⇌":"rlhar","⩸":"equivDD","⧥":"eqvparsl","⥱":"erarr","≓":"erDot","ℯ":"escr","ℰ":"Escr","⩳":"Esim","Η":"Eta","η":"eta","Ð":"ETH","ð":"eth","Ë":"Euml","ë":"euml","€":"euro","!":"excl","∃":"exist","Ф":"Fcy","ф":"fcy","♀":"female","ffi":"ffilig","ff":"fflig","ffl":"ffllig","𝔉":"Ffr","𝔣":"ffr","fi":"filig","◼":"FilledSmallSquare",fj:"fjlig","♭":"flat","fl":"fllig","▱":"fltns","ƒ":"fnof","𝔽":"Fopf","𝕗":"fopf","∀":"forall","⋔":"fork","⫙":"forkv","ℱ":"Fscr","⨍":"fpartint","½":"half","⅓":"frac13","¼":"frac14","⅕":"frac15","⅙":"frac16","⅛":"frac18","⅔":"frac23","⅖":"frac25","¾":"frac34","⅗":"frac35","⅜":"frac38","⅘":"frac45","⅚":"frac56","⅝":"frac58","⅞":"frac78","⁄":"frasl","⌢":"frown","𝒻":"fscr","ǵ":"gacute","Γ":"Gamma","γ":"gamma","Ϝ":"Gammad","⪆":"gap","Ğ":"Gbreve","ğ":"gbreve","Ģ":"Gcedil","Ĝ":"Gcirc","ĝ":"gcirc","Г":"Gcy","г":"gcy","Ġ":"Gdot","ġ":"gdot","≥":"ge","≧":"gE","⪌":"gEl","⋛":"gel","⩾":"ges","⪩":"gescc","⪀":"gesdot","⪂":"gesdoto","⪄":"gesdotol","⋛︀":"gesl","⪔":"gesles","𝔊":"Gfr","𝔤":"gfr","≫":"gg","⋙":"Gg","ℷ":"gimel","Ѓ":"GJcy","ѓ":"gjcy","⪥":"gla","≷":"gl","⪒":"glE","⪤":"glj","⪊":"gnap","⪈":"gne","≩":"gnE","⋧":"gnsim","𝔾":"Gopf","𝕘":"gopf","⪢":"GreaterGreater","≳":"gsim","𝒢":"Gscr","ℊ":"gscr","⪎":"gsime","⪐":"gsiml","⪧":"gtcc","⩺":"gtcir",">":"gt","⋗":"gtdot","⦕":"gtlPar","⩼":"gtquest","⥸":"gtrarr","≩︀":"gvnE"," ":"hairsp","ℋ":"Hscr","Ъ":"HARDcy","ъ":"hardcy","⥈":"harrcir","↔":"harr","↭":"harrw","^":"Hat","ℏ":"hbar","Ĥ":"Hcirc","ĥ":"hcirc","♥":"hearts","…":"mldr","⊹":"hercon","𝔥":"hfr","ℌ":"Hfr","⤥":"searhk","⤦":"swarhk","⇿":"hoarr","∻":"homtht","↩":"larrhk","↪":"rarrhk","𝕙":"hopf","ℍ":"Hopf","―":"horbar","𝒽":"hscr","Ħ":"Hstrok","ħ":"hstrok","⁃":"hybull","Í":"Iacute","í":"iacute","⁣":"ic","Î":"Icirc","î":"icirc","И":"Icy","и":"icy","İ":"Idot","Е":"IEcy","е":"iecy","¡":"iexcl","𝔦":"ifr","ℑ":"Im","Ì":"Igrave","ì":"igrave","ⅈ":"ii","⨌":"qint","∭":"tint","⧜":"iinfin","℩":"iiota","IJ":"IJlig","ij":"ijlig","Ī":"Imacr","ī":"imacr","ℐ":"Iscr","ı":"imath","⊷":"imof","Ƶ":"imped","℅":"incare","∞":"infin","⧝":"infintie","⊺":"intcal","∫":"int","∬":"Int","ℤ":"Zopf","⨗":"intlarhk","⨼":"iprod","⁢":"it","Ё":"IOcy","ё":"iocy","Į":"Iogon","į":"iogon","𝕀":"Iopf","𝕚":"iopf","Ι":"Iota","ι":"iota","¿":"iquest","𝒾":"iscr","⋵":"isindot","⋹":"isinE","⋴":"isins","⋳":"isinsv","Ĩ":"Itilde","ĩ":"itilde","І":"Iukcy","і":"iukcy","Ï":"Iuml","ï":"iuml","Ĵ":"Jcirc","ĵ":"jcirc","Й":"Jcy","й":"jcy","𝔍":"Jfr","𝔧":"jfr","ȷ":"jmath","𝕁":"Jopf","𝕛":"jopf","𝒥":"Jscr","𝒿":"jscr","Ј":"Jsercy","ј":"jsercy","Є":"Jukcy","є":"jukcy","Κ":"Kappa","κ":"kappa","ϰ":"kappav","Ķ":"Kcedil","ķ":"kcedil","К":"Kcy","к":"kcy","𝔎":"Kfr","𝔨":"kfr","ĸ":"kgreen","Х":"KHcy","х":"khcy","Ќ":"KJcy","ќ":"kjcy","𝕂":"Kopf","𝕜":"kopf","𝒦":"Kscr","𝓀":"kscr","⇚":"lAarr","Ĺ":"Lacute","ĺ":"lacute","⦴":"laemptyv","ℒ":"Lscr","Λ":"Lambda","λ":"lambda","⟨":"lang","⟪":"Lang","⦑":"langd","⪅":"lap","«":"laquo","⇤":"larrb","⤟":"larrbfs","←":"larr","↞":"Larr","⤝":"larrfs","↫":"larrlp","⤹":"larrpl","⥳":"larrsim","↢":"larrtl","⤙":"latail","⤛":"lAtail","⪫":"lat","⪭":"late","⪭︀":"lates","⤌":"lbarr","⤎":"lBarr","❲":"lbbrk","{":"lcub","[":"lsqb","⦋":"lbrke","⦏":"lbrksld","⦍":"lbrkslu","Ľ":"Lcaron","ľ":"lcaron","Ļ":"Lcedil","ļ":"lcedil","⌈":"lceil","Л":"Lcy","л":"lcy","⤶":"ldca","“":"ldquo","⥧":"ldrdhar","⥋":"ldrushar","↲":"ldsh","≤":"le","≦":"lE","⇆":"lrarr","⟦":"lobrk","⥡":"LeftDownTeeVector","⥙":"LeftDownVectorBar","⌊":"lfloor","↼":"lharu","⇇":"llarr","⇋":"lrhar","⥎":"LeftRightVector","↤":"mapstoleft","⥚":"LeftTeeVector","⋋":"lthree","⧏":"LeftTriangleBar","⊲":"vltri","⊴":"ltrie","⥑":"LeftUpDownVector","⥠":"LeftUpTeeVector","⥘":"LeftUpVectorBar","↿":"uharl","⥒":"LeftVectorBar","⪋":"lEg","⋚":"leg","⩽":"les","⪨":"lescc","⩿":"lesdot","⪁":"lesdoto","⪃":"lesdotor","⋚︀":"lesg","⪓":"lesges","⋖":"ltdot","≶":"lg","⪡":"LessLess","≲":"lsim","⥼":"lfisht","𝔏":"Lfr","𝔩":"lfr","⪑":"lgE","⥢":"lHar","⥪":"lharul","▄":"lhblk","Љ":"LJcy","љ":"ljcy","≪":"ll","⋘":"Ll","⥫":"llhard","◺":"lltri","Ŀ":"Lmidot","ŀ":"lmidot","⎰":"lmoust","⪉":"lnap","⪇":"lne","≨":"lnE","⋦":"lnsim","⟬":"loang","⇽":"loarr","⟵":"xlarr","⟷":"xharr","⟼":"xmap","⟶":"xrarr","↬":"rarrlp","⦅":"lopar","𝕃":"Lopf","𝕝":"lopf","⨭":"loplus","⨴":"lotimes","∗":"lowast",_:"lowbar","↙":"swarr","↘":"searr","◊":"loz","(":"lpar","⦓":"lparlt","⥭":"lrhard","‎":"lrm","⊿":"lrtri","‹":"lsaquo","𝓁":"lscr","↰":"lsh","⪍":"lsime","⪏":"lsimg","‘":"lsquo","‚":"sbquo","Ł":"Lstrok","ł":"lstrok","⪦":"ltcc","⩹":"ltcir","<":"lt","⋉":"ltimes","⥶":"ltlarr","⩻":"ltquest","◃":"ltri","⦖":"ltrPar","⥊":"lurdshar","⥦":"luruhar","≨︀":"lvnE","¯":"macr","♂":"male","✠":"malt","⤅":"Map","↦":"map","↥":"mapstoup","▮":"marker","⨩":"mcomma","М":"Mcy","м":"mcy","—":"mdash","∺":"mDDot"," ":"MediumSpace","ℳ":"Mscr","𝔐":"Mfr","𝔪":"mfr","℧":"mho","µ":"micro","⫰":"midcir","∣":"mid","−":"minus","⨪":"minusdu","∓":"mp","⫛":"mlcp","⊧":"models","𝕄":"Mopf","𝕞":"mopf","𝓂":"mscr","Μ":"Mu","μ":"mu","⊸":"mumap","Ń":"Nacute","ń":"nacute","∠⃒":"nang","≉":"nap","⩰̸":"napE","≋̸":"napid","ʼn":"napos","♮":"natur","ℕ":"Nopf"," ":"nbsp","≎̸":"nbump","≏̸":"nbumpe","⩃":"ncap","Ň":"Ncaron","ň":"ncaron","Ņ":"Ncedil","ņ":"ncedil","≇":"ncong","⩭̸":"ncongdot","⩂":"ncup","Н":"Ncy","н":"ncy","–":"ndash","⤤":"nearhk","↗":"nearr","⇗":"neArr","≠":"ne","≐̸":"nedot","​":"ZeroWidthSpace","≢":"nequiv","⤨":"toea","≂̸":"nesim","\n":"NewLine","∄":"nexist","𝔑":"Nfr","𝔫":"nfr","≧̸":"ngE","≱":"nge","⩾̸":"nges","⋙̸":"nGg","≵":"ngsim","≫⃒":"nGt","≯":"ngt","≫̸":"nGtv","↮":"nharr","⇎":"nhArr","⫲":"nhpar","∋":"ni","⋼":"nis","⋺":"nisd","Њ":"NJcy","њ":"njcy","↚":"nlarr","⇍":"nlArr","‥":"nldr","≦̸":"nlE","≰":"nle","⩽̸":"nles","≮":"nlt","⋘̸":"nLl","≴":"nlsim","≪⃒":"nLt","⋪":"nltri","⋬":"nltrie","≪̸":"nLtv","∤":"nmid","⁠":"NoBreak","𝕟":"nopf","⫬":"Not","¬":"not","≭":"NotCupCap","∦":"npar","∉":"notin","≹":"ntgl","⋵̸":"notindot","⋹̸":"notinE","⋷":"notinvb","⋶":"notinvc","⧏̸":"NotLeftTriangleBar","≸":"ntlg","⪢̸":"NotNestedGreaterGreater","⪡̸":"NotNestedLessLess","∌":"notni","⋾":"notnivb","⋽":"notnivc","⊀":"npr","⪯̸":"npre","⋠":"nprcue","⧐̸":"NotRightTriangleBar","⋫":"nrtri","⋭":"nrtrie","⊏̸":"NotSquareSubset","⋢":"nsqsube","⊐̸":"NotSquareSuperset","⋣":"nsqsupe","⊂⃒":"vnsub","⊈":"nsube","⊁":"nsc","⪰̸":"nsce","⋡":"nsccue","≿̸":"NotSucceedsTilde","⊃⃒":"vnsup","⊉":"nsupe","≁":"nsim","≄":"nsime","⫽⃥":"nparsl","∂̸":"npart","⨔":"npolint","⤳̸":"nrarrc","↛":"nrarr","⇏":"nrArr","↝̸":"nrarrw","𝒩":"Nscr","𝓃":"nscr","⊄":"nsub","⫅̸":"nsubE","⊅":"nsup","⫆̸":"nsupE","Ñ":"Ntilde","ñ":"ntilde","Ν":"Nu","ν":"nu","#":"num","№":"numero"," ":"numsp","≍⃒":"nvap","⊬":"nvdash","⊭":"nvDash","⊮":"nVdash","⊯":"nVDash","≥⃒":"nvge",">⃒":"nvgt","⤄":"nvHarr","⧞":"nvinfin","⤂":"nvlArr","≤⃒":"nvle","<⃒":"nvlt","⊴⃒":"nvltrie","⤃":"nvrArr","⊵⃒":"nvrtrie","∼⃒":"nvsim","⤣":"nwarhk","↖":"nwarr","⇖":"nwArr","⤧":"nwnear","Ó":"Oacute","ó":"oacute","Ô":"Ocirc","ô":"ocirc","О":"Ocy","о":"ocy","Ő":"Odblac","ő":"odblac","⨸":"odiv","⦼":"odsold","Œ":"OElig","œ":"oelig","⦿":"ofcir","𝔒":"Ofr","𝔬":"ofr","˛":"ogon","Ò":"Ograve","ò":"ograve","⧁":"ogt","⦵":"ohbar","Ω":"ohm","⦾":"olcir","⦻":"olcross","‾":"oline","⧀":"olt","Ō":"Omacr","ō":"omacr","ω":"omega","Ο":"Omicron","ο":"omicron","⦶":"omid","𝕆":"Oopf","𝕠":"oopf","⦷":"opar","⦹":"operp","⩔":"Or","∨":"or","⩝":"ord","ℴ":"oscr","ª":"ordf","º":"ordm","⊶":"origof","⩖":"oror","⩗":"orslope","⩛":"orv","𝒪":"Oscr","Ø":"Oslash","ø":"oslash","⊘":"osol","Õ":"Otilde","õ":"otilde","⨶":"otimesas","⨷":"Otimes","Ö":"Ouml","ö":"ouml","⌽":"ovbar","⏞":"OverBrace","⎴":"tbrk","⏜":"OverParenthesis","¶":"para","⫳":"parsim","⫽":"parsl","∂":"part","П":"Pcy","п":"pcy","%":"percnt",".":"period","‰":"permil","‱":"pertenk","𝔓":"Pfr","𝔭":"pfr","Φ":"Phi","φ":"phi","ϕ":"phiv","☎":"phone","Π":"Pi","π":"pi","ϖ":"piv","ℎ":"planckh","⨣":"plusacir","⨢":"pluscir","+":"plus","⨥":"plusdu","⩲":"pluse","±":"pm","⨦":"plussim","⨧":"plustwo","⨕":"pointint","𝕡":"popf","ℙ":"Popf","£":"pound","⪷":"prap","⪻":"Pr","≺":"pr","≼":"prcue","⪯":"pre","≾":"prsim","⪹":"prnap","⪵":"prnE","⋨":"prnsim","⪳":"prE","′":"prime","″":"Prime","∏":"prod","⌮":"profalar","⌒":"profline","⌓":"profsurf","∝":"prop","⊰":"prurel","𝒫":"Pscr","𝓅":"pscr","Ψ":"Psi","ψ":"psi"," ":"puncsp","𝔔":"Qfr","𝔮":"qfr","𝕢":"qopf","ℚ":"Qopf","⁗":"qprime","𝒬":"Qscr","𝓆":"qscr","⨖":"quatint","?":"quest",'"':"quot","⇛":"rAarr","∽̱":"race","Ŕ":"Racute","ŕ":"racute","√":"Sqrt","⦳":"raemptyv","⟩":"rang","⟫":"Rang","⦒":"rangd","⦥":"range","»":"raquo","⥵":"rarrap","⇥":"rarrb","⤠":"rarrbfs","⤳":"rarrc","→":"rarr","↠":"Rarr","⤞":"rarrfs","⥅":"rarrpl","⥴":"rarrsim","⤖":"Rarrtl","↣":"rarrtl","↝":"rarrw","⤚":"ratail","⤜":"rAtail","∶":"ratio","❳":"rbbrk","}":"rcub","]":"rsqb","⦌":"rbrke","⦎":"rbrksld","⦐":"rbrkslu","Ř":"Rcaron","ř":"rcaron","Ŗ":"Rcedil","ŗ":"rcedil","⌉":"rceil","Р":"Rcy","р":"rcy","⤷":"rdca","⥩":"rdldhar","↳":"rdsh","ℜ":"Re","ℛ":"Rscr","ℝ":"Ropf","▭":"rect","⥽":"rfisht","⌋":"rfloor","𝔯":"rfr","⥤":"rHar","⇀":"rharu","⥬":"rharul","Ρ":"Rho","ρ":"rho","ϱ":"rhov","⇄":"rlarr","⟧":"robrk","⥝":"RightDownTeeVector","⥕":"RightDownVectorBar","⇉":"rrarr","⊢":"vdash","⥛":"RightTeeVector","⋌":"rthree","⧐":"RightTriangleBar","⊳":"vrtri","⊵":"rtrie","⥏":"RightUpDownVector","⥜":"RightUpTeeVector","⥔":"RightUpVectorBar","↾":"uharr","⥓":"RightVectorBar","˚":"ring","‏":"rlm","⎱":"rmoust","⫮":"rnmid","⟭":"roang","⇾":"roarr","⦆":"ropar","𝕣":"ropf","⨮":"roplus", "⨵":"rotimes","⥰":"RoundImplies",")":"rpar","⦔":"rpargt","⨒":"rppolint","›":"rsaquo","𝓇":"rscr","↱":"rsh","⋊":"rtimes","▹":"rtri","⧎":"rtriltri","⧴":"RuleDelayed","⥨":"ruluhar","℞":"rx","Ś":"Sacute","ś":"sacute","⪸":"scap","Š":"Scaron","š":"scaron","⪼":"Sc","≻":"sc","≽":"sccue","⪰":"sce","⪴":"scE","Ş":"Scedil","ş":"scedil","Ŝ":"Scirc","ŝ":"scirc","⪺":"scnap","⪶":"scnE","⋩":"scnsim","⨓":"scpolint","≿":"scsim","С":"Scy","с":"scy","⋅":"sdot","⩦":"sdote","⇘":"seArr","§":"sect",";":"semi","⤩":"tosa","✶":"sext","𝔖":"Sfr","𝔰":"sfr","♯":"sharp","Щ":"SHCHcy","щ":"shchcy","Ш":"SHcy","ш":"shcy","↑":"uarr","­":"shy","Σ":"Sigma","σ":"sigma","ς":"sigmaf","∼":"sim","⩪":"simdot","≃":"sime","⪞":"simg","⪠":"simgE","⪝":"siml","⪟":"simlE","≆":"simne","⨤":"simplus","⥲":"simrarr","⨳":"smashp","⧤":"smeparsl","⌣":"smile","⪪":"smt","⪬":"smte","⪬︀":"smtes","Ь":"SOFTcy","ь":"softcy","⌿":"solbar","⧄":"solb","/":"sol","𝕊":"Sopf","𝕤":"sopf","♠":"spades","⊓":"sqcap","⊓︀":"sqcaps","⊔":"sqcup","⊔︀":"sqcups","⊏":"sqsub","⊑":"sqsube","⊐":"sqsup","⊒":"sqsupe","□":"squ","𝒮":"Sscr","𝓈":"sscr","⋆":"Star","☆":"star","⊂":"sub","⋐":"Sub","⪽":"subdot","⫅":"subE","⊆":"sube","⫃":"subedot","⫁":"submult","⫋":"subnE","⊊":"subne","⪿":"subplus","⥹":"subrarr","⫇":"subsim","⫕":"subsub","⫓":"subsup","∑":"sum","♪":"sung","¹":"sup1","²":"sup2","³":"sup3","⊃":"sup","⋑":"Sup","⪾":"supdot","⫘":"supdsub","⫆":"supE","⊇":"supe","⫄":"supedot","⟉":"suphsol","⫗":"suphsub","⥻":"suplarr","⫂":"supmult","⫌":"supnE","⊋":"supne","⫀":"supplus","⫈":"supsim","⫔":"supsub","⫖":"supsup","⇙":"swArr","⤪":"swnwar","ß":"szlig"," ":"Tab","⌖":"target","Τ":"Tau","τ":"tau","Ť":"Tcaron","ť":"tcaron","Ţ":"Tcedil","ţ":"tcedil","Т":"Tcy","т":"tcy","⃛":"tdot","⌕":"telrec","𝔗":"Tfr","𝔱":"tfr","∴":"there4","Θ":"Theta","θ":"theta","ϑ":"thetav","  ":"ThickSpace"," ":"thinsp","Þ":"THORN","þ":"thorn","⨱":"timesbar","×":"times","⨰":"timesd","⌶":"topbot","⫱":"topcir","𝕋":"Topf","𝕥":"topf","⫚":"topfork","‴":"tprime","™":"trade","▵":"utri","≜":"trie","◬":"tridot","⨺":"triminus","⨹":"triplus","⧍":"trisb","⨻":"tritime","⏢":"trpezium","𝒯":"Tscr","𝓉":"tscr","Ц":"TScy","ц":"tscy","Ћ":"TSHcy","ћ":"tshcy","Ŧ":"Tstrok","ŧ":"tstrok","Ú":"Uacute","ú":"uacute","↟":"Uarr","⥉":"Uarrocir","Ў":"Ubrcy","ў":"ubrcy","Ŭ":"Ubreve","ŭ":"ubreve","Û":"Ucirc","û":"ucirc","У":"Ucy","у":"ucy","⇅":"udarr","Ű":"Udblac","ű":"udblac","⥮":"udhar","⥾":"ufisht","𝔘":"Ufr","𝔲":"ufr","Ù":"Ugrave","ù":"ugrave","⥣":"uHar","▀":"uhblk","⌜":"ulcorn","⌏":"ulcrop","◸":"ultri","Ū":"Umacr","ū":"umacr","⏟":"UnderBrace","⏝":"UnderParenthesis","⊎":"uplus","Ų":"Uogon","ų":"uogon","𝕌":"Uopf","𝕦":"uopf","⤒":"UpArrowBar","↕":"varr","υ":"upsi","ϒ":"Upsi","Υ":"Upsilon","⇈":"uuarr","⌝":"urcorn","⌎":"urcrop","Ů":"Uring","ů":"uring","◹":"urtri","𝒰":"Uscr","𝓊":"uscr","⋰":"utdot","Ũ":"Utilde","ũ":"utilde","Ü":"Uuml","ü":"uuml","⦧":"uwangle","⦜":"vangrt","⊊︀":"vsubne","⫋︀":"vsubnE","⊋︀":"vsupne","⫌︀":"vsupnE","⫨":"vBar","⫫":"Vbar","⫩":"vBarv","В":"Vcy","в":"vcy","⊩":"Vdash","⊫":"VDash","⫦":"Vdashl","⊻":"veebar","≚":"veeeq","⋮":"vellip","|":"vert","‖":"Vert","❘":"VerticalSeparator","≀":"wr","𝔙":"Vfr","𝔳":"vfr","𝕍":"Vopf","𝕧":"vopf","𝒱":"Vscr","𝓋":"vscr","⊪":"Vvdash","⦚":"vzigzag","Ŵ":"Wcirc","ŵ":"wcirc","⩟":"wedbar","≙":"wedgeq","℘":"wp","𝔚":"Wfr","𝔴":"wfr","𝕎":"Wopf","𝕨":"wopf","𝒲":"Wscr","𝓌":"wscr","𝔛":"Xfr","𝔵":"xfr","Ξ":"Xi","ξ":"xi","⋻":"xnis","𝕏":"Xopf","𝕩":"xopf","𝒳":"Xscr","𝓍":"xscr","Ý":"Yacute","ý":"yacute","Я":"YAcy","я":"yacy","Ŷ":"Ycirc","ŷ":"ycirc","Ы":"Ycy","ы":"ycy","¥":"yen","𝔜":"Yfr","𝔶":"yfr","Ї":"YIcy","ї":"yicy","𝕐":"Yopf","𝕪":"yopf","𝒴":"Yscr","𝓎":"yscr","Ю":"YUcy","ю":"yucy","ÿ":"yuml","Ÿ":"Yuml","Ź":"Zacute","ź":"zacute","Ž":"Zcaron","ž":"zcaron","З":"Zcy","з":"zcy","Ż":"Zdot","ż":"zdot","ℨ":"Zfr","Ζ":"Zeta","ζ":"zeta","𝔷":"zfr","Ж":"ZHcy","ж":"zhcy","⇝":"zigrarr","𝕫":"zopf","𝒵":"Zscr","𝓏":"zscr","‍":"zwj","‌":"zwnj"},f=/["&'<>`]/g,d={'"':""","&":"&","'":"'","<":"<",">":">","`":"`"},p=/&#(?:[xX][^a-fA-F0-9]|[^0-9xX])/,g=/[\0-\x08\x0B\x0E-\x1F\x7F-\x9F\uFDD0-\uFDEF\uFFFE\uFFFF]|[\uD83F\uD87F\uD8BF\uD8FF\uD93F\uD97F\uD9BF\uD9FF\uDA3F\uDA7F\uDABF\uDAFF\uDB3F\uDB7F\uDBBF\uDBFF][\uDFFE\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,y=/&#([0-9]+)(;?)|&#[xX]([a-fA-F0-9]+)(;?)|&([0-9a-zA-Z]+);|&(Aacute|iacute|Uacute|plusmn|otilde|Otilde|Agrave|agrave|yacute|Yacute|oslash|Oslash|Atilde|atilde|brvbar|Ccedil|ccedil|ograve|curren|divide|Eacute|eacute|Ograve|oacute|Egrave|egrave|ugrave|frac12|frac14|frac34|Ugrave|Oacute|Iacute|ntilde|Ntilde|uacute|middot|Igrave|igrave|iquest|aacute|laquo|THORN|micro|iexcl|icirc|Icirc|Acirc|ucirc|ecirc|Ocirc|ocirc|Ecirc|Ucirc|aring|Aring|aelig|AElig|acute|pound|raquo|acirc|times|thorn|szlig|cedil|COPY|Auml|ordf|ordm|uuml|macr|Uuml|auml|Ouml|ouml|para|nbsp|Euml|quot|QUOT|euml|yuml|cent|sect|copy|sup1|sup2|sup3|Iuml|iuml|shy|eth|reg|not|yen|amp|AMP|REG|uml|ETH|deg|gt|GT|LT|lt)([=a-zA-Z0-9])?/g,m={Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"⁡",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",amp:"&",AMP:"&",andand:"⩕",And:"⩓",and:"∧",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angmsd:"∡",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",apacir:"⩯",ap:"≈",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"⁡",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",barwed:"⌅",Barwed:"⌆",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",because:"∵",Because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxdl:"┐",boxdL:"╕",boxDl:"╖",boxDL:"╗",boxdr:"┌",boxdR:"╒",boxDr:"╓",boxDR:"╔",boxh:"─",boxH:"═",boxhd:"┬",boxHd:"╤",boxhD:"╥",boxHD:"╦",boxhu:"┴",boxHu:"╧",boxhU:"╨",boxHU:"╩",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxul:"┘",boxuL:"╛",boxUl:"╜",boxUL:"╝",boxur:"└",boxuR:"╘",boxUr:"╙",boxUR:"╚",boxv:"│",boxV:"║",boxvh:"┼",boxvH:"╪",boxVh:"╫",boxVH:"╬",boxvl:"┤",boxvL:"╡",boxVl:"╢",boxVL:"╣",boxvr:"├",boxvR:"╞",boxVr:"╟",boxVR:"╠",bprime:"‵",breve:"˘",Breve:"˘",brvbar:"¦",bscr:"𝒷",Bscr:"ℬ",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsolb:"⧅",bsol:"\\",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",capand:"⩄",capbrcup:"⩉",capcap:"⩋",cap:"∩",Cap:"⋒",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",centerdot:"·",CenterDot:"·",cfr:"𝔠",Cfr:"ℭ",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cir:"○",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",colon:":",Colon:"∷",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",conint:"∮",Conint:"∯",ContourIntegral:"∮",copf:"𝕔",Copf:"ℂ",coprod:"∐",Coproduct:"∐",copy:"©",COPY:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",cross:"✗",Cross:"⨯",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",cupbrcap:"⩈",cupcap:"⩆",CupCap:"≍",cup:"∪",Cup:"⋓",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",dagger:"†",Dagger:"‡",daleth:"ℸ",darr:"↓",Darr:"↡",dArr:"⇓",dash:"‐",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",ddagger:"‡",ddarr:"⇊",DD:"ⅅ",dd:"ⅆ",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",diamond:"⋄",Diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrowBar:"⤓",downarrow:"↓",DownArrow:"↓",Downarrow:"⇓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVectorBar:"⥖",DownLeftVector:"↽",DownRightTeeVector:"⥟",DownRightVectorBar:"⥗",DownRightVector:"⇁",DownTeeArrow:"↧",DownTee:"⊤",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",Ecirc:"Ê",ecirc:"ê",ecir:"≖",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",edot:"ė",eDot:"≑",ee:"ⅇ",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp13:" ",emsp14:" ",emsp:" ",ENG:"Ŋ",eng:"ŋ",ensp:" ",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",escr:"ℯ",Escr:"ℰ",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",exponentiale:"ⅇ",ExponentialE:"ⅇ",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",Ffr:"𝔉",ffr:"𝔣",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",forall:"∀",ForAll:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",fscr:"𝒻",Fscr:"ℱ",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",ge:"≥",gE:"≧",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",gescc:"⪩",ges:"⩾",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",gg:"≫",Gg:"⋙",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gla:"⪥",gl:"≷",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gne:"⪈",gnE:"≩",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"ℊ",gsim:"≳",gsime:"⪎",gsiml:"⪐",gtcc:"⪧",gtcir:"⩺",gt:">",GT:">",Gt:"≫",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",HARDcy:"Ъ",hardcy:"ъ",harrcir:"⥈",harr:"↔",hArr:"⇔",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",hfr:"𝔥",Hfr:"ℌ",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",hopf:"𝕙",Hopf:"ℍ",horbar:"―",HorizontalLine:"─",hscr:"𝒽",Hscr:"ℋ",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",Iacute:"Í",iacute:"í",ic:"⁣",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",ifr:"𝔦",Ifr:"ℑ",Igrave:"Ì",igrave:"ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"IJ",ijlig:"ij",Imacr:"Ī",imacr:"ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",Im:"ℑ",imof:"⊷",imped:"Ƶ",Implies:"⇒",incare:"℅","in":"∈",infin:"∞",infintie:"⧝",inodot:"ı",intcal:"⊺","int":"∫",Int:"∬",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"⁣",InvisibleTimes:"⁢",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",iscr:"𝒾",Iscr:"ℐ",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"⁢",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"ℒ",Lambda:"Λ",lambda:"λ",lang:"⟨",Lang:"⟪",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",larrb:"⇤",larrbfs:"⤟",larr:"←",Larr:"↞",lArr:"⇐",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",latail:"⤙",lAtail:"⤛",lat:"⪫",late:"⪭",lates:"⪭︀",lbarr:"⤌",lBarr:"⤎",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",le:"≤",lE:"≦",LeftAngleBracket:"⟨",LeftArrowBar:"⇤",leftarrow:"←",LeftArrow:"←",Leftarrow:"⇐",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVectorBar:"⥙",LeftDownVector:"⇃",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",leftrightarrow:"↔",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTeeArrow:"↤",LeftTee:"⊣",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangleBar:"⧏",LeftTriangle:"⊲",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVectorBar:"⥘",LeftUpVector:"↿",LeftVectorBar:"⥒",LeftVector:"↼",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",lescc:"⪨",les:"⩽",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",llarr:"⇇",ll:"≪",Ll:"⋘",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoustache:"⎰",lmoust:"⎰",lnap:"⪉",lnapprox:"⪉",lne:"⪇",lnE:"≨",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",longleftarrow:"⟵",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftrightarrow:"⟷",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longmapsto:"⟼",longrightarrow:"⟶",LongRightArrow:"⟶",Longrightarrow:"⟹",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"‎",lrtri:"⊿",lsaquo:"‹",lscr:"𝓁",Lscr:"ℒ",lsh:"↰",Lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",Lstrok:"Ł",lstrok:"ł",ltcc:"⪦",ltcir:"⩹",lt:"<",LT:"<",Lt:"≪",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",midast:"*",midcir:"⫰",mid:"∣",middot:"·",minusb:"⊟",minus:"−",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",mscr:"𝓂",Mscr:"ℳ",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natural:"♮",naturals:"ℕ",natur:"♮",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"–",nearhk:"⤤",nearr:"↗",neArr:"⇗",nearrow:"↗",ne:"≠",nedot:"≐̸",NegativeMediumSpace:"​",NegativeThickSpace:"​",NegativeThinSpace:"​",NegativeVeryThinSpace:"​",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:"\n",nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nharr:"↮",nhArr:"⇎",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlarr:"↚",nlArr:"⇍",nldr:"‥",nlE:"≦̸",nle:"≰",nleftarrow:"↚",nLeftarrow:"⇍",nleftrightarrow:"↮",nLeftrightarrow:"⇎",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"⁠",NonBreakingSpace:" ",nopf:"𝕟",Nopf:"ℕ",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangleBar:"⧏̸",NotLeftTriangle:"⋪",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangleBar:"⧐̸",NotRightTriangle:"⋫",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",nparallel:"∦",npar:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",nprec:"⊀",npreceq:"⪯̸",npre:"⪯̸",nrarrc:"⤳̸",nrarr:"↛",nrArr:"⇏",nrarrw:"↝̸",nrightarrow:"↛",nRightarrow:"⇏",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nvdash:"⊬",nvDash:"⊭",nVdash:"⊮",nVDash:"⊯",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwarr:"↖",nwArr:"⇖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",Ocirc:"Ô",ocirc:"ô",ocir:"⊚",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",orarr:"↻",Or:"⩔",or:"∨",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"ℴ",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",otimesas:"⨶",Otimes:"⨷",otimes:"⊗",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",para:"¶",parallel:"∥",par:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plus:"+",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",popf:"𝕡",Popf:"ℙ",pound:"£",prap:"⪷",Pr:"⪻",pr:"≺",prcue:"≼",precapprox:"⪷",prec:"≺",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",pre:"⪯",prE:"⪳",precsim:"≾",prime:"′",Prime:"″",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportional:"∝",Proportion:"∷",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:" ",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",qopf:"𝕢",Qopf:"ℚ",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",quot:'"',QUOT:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",rang:"⟩",Rang:"⟫",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarr:"→",Rarr:"↠",rArr:"⇒",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",ratail:"⤚",rAtail:"⤜",ratio:"∶",rationals:"ℚ",rbarr:"⤍",rBarr:"⤏",RBarr:"⤐",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",Re:"ℜ",rect:"▭",reg:"®",REG:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",rfr:"𝔯",Rfr:"ℜ",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩",RightArrowBar:"⇥",rightarrow:"→",RightArrow:"→",Rightarrow:"⇒",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVectorBar:"⥕",RightDownVector:"⇂",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTeeArrow:"↦",RightTee:"⊢",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangleBar:"⧐",RightTriangle:"⊳",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVectorBar:"⥔",RightUpVector:"↾",RightVectorBar:"⥓",RightVector:"⇀",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"‏",rmoustache:"⎱",rmoust:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",ropf:"𝕣",Ropf:"ℝ",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",rscr:"𝓇",Rscr:"ℛ",rsh:"↱",Rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"‚",scap:"⪸",Scaron:"Š",scaron:"š",Sc:"⪼",sc:"≻",sccue:"≽",sce:"⪰",scE:"⪴",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdotb:"⊡",sdot:"⋅",sdote:"⩦",searhk:"⤥",searr:"↘",seArr:"⇘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",solbar:"⌿",solb:"⧄",sol:"/",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",square:"□",Square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squ:"□",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",sub:"⊂",Sub:"⋐",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",subset:"⊂",Subset:"⋐",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succapprox:"⪸",succ:"≻",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",sum:"∑",Sum:"∑",sung:"♪",sup1:"¹",sup2:"²",sup3:"³",sup:"⊃",Sup:"⋑",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",supset:"⊃",Supset:"⋑",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swarr:"↙",swArr:"⇙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:" ",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",therefore:"∴",Therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:"  ",ThinSpace:" ",thinsp:" ",thkap:"≈",thksim:"∼",THORN:"Þ",thorn:"þ",tilde:"˜",Tilde:"∼",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",timesbar:"⨱",timesb:"⊠",times:"×",timesd:"⨰",tint:"∭",toea:"⤨",topbot:"⌶",topcir:"⫱",top:"⊤",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",trade:"™",TRADE:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",uarr:"↑",Uarr:"↟",uArr:"⇑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrowBar:"⤒",uparrow:"↑",UpArrow:"↑",Uparrow:"⇑",UpArrowDownArrow:"⇅",updownarrow:"↕",UpDownArrow:"↕",Updownarrow:"⇕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",upsi:"υ",Upsi:"ϒ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTeeArrow:"↥",UpTee:"⊥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",varr:"↕",vArr:"⇕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",vBar:"⫨",Vbar:"⫫",vBarv:"⫩",Vcy:"В",vcy:"в",vdash:"⊢",vDash:"⊨",Vdash:"⊩",VDash:"⊫",Vdashl:"⫦",veebar:"⊻",vee:"∨",Vee:"⋁",veeeq:"≚",vellip:"⋮",verbar:"|",Verbar:"‖",vert:"|",Vert:"‖",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",wedge:"∧",Wedge:"⋀",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xharr:"⟷",xhArr:"⟺",Xi:"Ξ",xi:"ξ",xlarr:"⟵",xlArr:"⟸",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrarr:"⟶",xrArr:"⟹",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",yuml:"ÿ",Yuml:"Ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"ℨ",ZeroWidthSpace:"​",Zeta:"Ζ",zeta:"ζ",zfr:"𝔷",Zfr:"ℨ",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",zopf:"𝕫",Zopf:"ℤ",Zscr:"𝒵",zscr:"𝓏",zwj:"‍",zwnj:"‌"},v={Aacute:"Á",aacute:"á",Acirc:"Â",acirc:"â",acute:"´",AElig:"Æ",aelig:"æ",Agrave:"À",agrave:"à",amp:"&",AMP:"&",Aring:"Å",aring:"å",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",brvbar:"¦",Ccedil:"Ç",ccedil:"ç",cedil:"¸",cent:"¢",copy:"©",COPY:"©",curren:"¤",deg:"°",divide:"÷",Eacute:"É",eacute:"é",Ecirc:"Ê",ecirc:"ê",Egrave:"È",egrave:"è",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",frac12:"½",frac14:"¼",frac34:"¾",gt:">",GT:">",Iacute:"Í",iacute:"í",Icirc:"Î",icirc:"î",iexcl:"¡",Igrave:"Ì",igrave:"ì",iquest:"¿",Iuml:"Ï",iuml:"ï",laquo:"«",lt:"<",LT:"<",macr:"¯",micro:"µ",middot:"·",nbsp:" ",not:"¬",Ntilde:"Ñ",ntilde:"ñ",Oacute:"Ó",oacute:"ó",Ocirc:"Ô",ocirc:"ô",Ograve:"Ò",ograve:"ò",ordf:"ª",ordm:"º",Oslash:"Ø",oslash:"ø",Otilde:"Õ",otilde:"õ",Ouml:"Ö",ouml:"ö",para:"¶",plusmn:"±",pound:"£",quot:'"',QUOT:'"',raquo:"»",reg:"®",REG:"®",sect:"§",shy:"­",sup1:"¹",sup2:"²",sup3:"³",szlig:"ß",THORN:"Þ",thorn:"þ",times:"×",Uacute:"Ú",uacute:"ú",Ucirc:"Û",ucirc:"û",Ugrave:"Ù",ugrave:"ù",uml:"¨",Uuml:"Ü",uuml:"ü",Yacute:"Ý",yacute:"ý",yen:"¥",yuml:"ÿ"},b={0:"�",128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"},_=[1,2,3,4,5,6,7,8,11,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,64976,64977,64978,64979,64980,64981,64982,64983,64984,64985,64986,64987,64988,64989,64990,64991,64992,64993,64994,64995,64996,64997,64998,64999,65e3,65001,65002,65003,65004,65005,65006,65007,65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111],x=String.fromCharCode,w={},A=w.hasOwnProperty,E=function(t,e){return A.call(t,e)},k=function(t,e){for(var n=-1,r=t.length;++n=55296&&57343>=t||t>1114111?(e&&S("character reference outside the permissible Unicode range"),"�"):E(b,t)?(e&&S("disallowed character reference"),b[t]):(e&&k(_,t)&&S("disallowed character reference"),t>65535&&(t-=65536,n+=x(t>>>10&1023|55296),t=56320|1023&t),n+=x(t))},M=function(t){return"&#x"+t.charCodeAt(0).toString(16).toUpperCase()+";"},S=function(t){throw Error("Parse error: "+t)},T=function(t,e){e=D(e,T.options);var n=e.strict;n&&g.test(t)&&S("forbidden code point");var r=e.encodeEverything,i=e.useNamedReferences,a=e.allowUnsafeSymbols;return r?(t=t.replace(s,function(t){return i&&E(h,t)?"&"+h[t]+";":M(t)}),i&&(t=t.replace(/>\u20D2/g,">⃒").replace(/<\u20D2/g,"<⃒").replace(/fj/g,"fj")),i&&(t=t.replace(l,function(t){return"&"+h[t]+";"}))):i?(a||(t=t.replace(f,function(t){return"&"+h[t]+";"})),t=t.replace(/>\u20D2/g,">⃒").replace(/<\u20D2/g,"<⃒"),t=t.replace(l,function(t){return"&"+h[t]+";"})):a||(t=t.replace(f,M)),t.replace(o,function(t){var e=t.charCodeAt(0),n=t.charCodeAt(1),r=1024*(e-55296)+n-56320+65536;return"&#x"+r.toString(16).toUpperCase()+";"}).replace(c,M)};T.options={allowUnsafeSymbols:!1,encodeEverything:!1,strict:!1,useNamedReferences:!1};var F=function(t,e){e=D(e,F.options);var n=e.strict;return n&&p.test(t)&&S("malformed character reference"),t.replace(y,function(t,r,i,a,u,o,s,c){var l,h,f,d,p;return r?(l=r,h=i,n&&!h&&S("character reference was not terminated by a semicolon"),C(l,n)):a?(f=a,h=u,n&&!h&&S("character reference was not terminated by a semicolon"),l=parseInt(f,16),C(l,n)):o?(d=o,E(m,d)?m[d]:(n&&S("named character reference was not terminated by a semicolon"),t)):(d=s,p=c,p&&e.isAttributeValue?(n&&"="==p&&S("`&` did not start a character reference"),t):(n&&S("named character reference was not terminated by a semicolon"),v[d]+(p||"")))})};F.options={isAttributeValue:!1,strict:!1};var B=function(t){return t.replace(f,function(t){return d[t]})},L={version:"0.5.0",encode:T,decode:F,escape:B,unescape:F};if("function"==typeof define&&"object"==typeof define.amd&&define.amd)define(function(){return L});else if(i&&!i.nodeType)if(a)a.exports=L;else for(var O in L)E(L,O)&&(i[O]=L[O]);else r.he=L}(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],106:[function(t,e,n){!function(t,r){"object"==typeof n&&"undefined"!=typeof e?e.exports=r():"function"==typeof define&&define.amd?define(r):t.moment=r()}(this,function(){"use strict";function n(){return In.apply(null,arguments)}function r(t){In=t}function i(t){return"[object Array]"===Object.prototype.toString.call(t)}function a(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function u(t,e){var n,r=[];for(n=0;n0)for(n in Rn)r=Rn[n],i=e[r],"undefined"!=typeof i&&(t[r]=i);return t}function g(t){p(this,t),this._d=new Date(null!=t._d?t._d.getTime():0/0),qn===!1&&(qn=!0,n.updateOffset(this),qn=!1)}function y(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function m(t){return 0>t?Math.ceil(t):Math.floor(t)}function v(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=m(e)),n}function b(t,e,n){var r,i=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),u=0;for(r=0;i>r;r++)(n&&t[r]!==e[r]||!n&&v(t[r])!==v(e[r]))&&u++;return u+a}function _(){}function x(t){return t?t.toLowerCase().replace("_","-"):t}function w(t){for(var e,n,r,i,a=0;a0;){if(r=A(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&b(i,n,!0)>=e-1)break;e--}a++}return null}function A(n){var r=null;if(!jn[n]&&"undefined"!=typeof e&&e&&e.exports)try{r=Pn._abbr,t("./locale/"+n),E(r)}catch(i){}return jn[n]}function E(t,e){var n;return t&&(n="undefined"==typeof e?D(t):k(t,e),n&&(Pn=n)),Pn._abbr}function k(t,e){return null!==e?(e.abbr=t,jn[t]=jn[t]||new _,jn[t].set(e),E(t),jn[t]):(delete jn[t],null)}function D(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Pn;if(!i(t)){if(e=A(t))return e;t=[t]}return w(t)}function C(t,e){var n=t.toLowerCase();Un[n]=Un[n+"s"]=Un[e]=t}function M(t){return"string"==typeof t?Un[t]||Un[t.toLowerCase()]:void 0}function S(t){var e,n,r={};for(n in t)o(t,n)&&(e=M(n),e&&(r[e]=t[n]));return r}function T(t,e){return function(r){return null!=r?(B(this,t,r),n.updateOffset(this,e),this):F(this,t)}}function F(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function B(t,e,n){return t._d["set"+(t._isUTC?"UTC":"")+e](n)}function L(t,e){var n;if("object"==typeof t)for(n in t)this.set(n,t[n]);else if(t=M(t),"function"==typeof this[t])return this[t](e);return this}function O(t,e,n){var r=""+Math.abs(t),i=e-r.length,a=t>=0;return(a?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}function N(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&($n[t]=i),e&&($n[e[0]]=function(){return O(i.apply(this,arguments),e[1],e[2])}),n&&($n[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function I(t){return t.match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"")}function P(t){var e,n,r=t.match(Yn);for(e=0,n=r.length;n>e;e++)r[e]=$n[r[e]]?$n[r[e]]:I(r[e]);return function(i){var a="";for(e=0;n>e;e++)a+=r[e]instanceof Function?r[e].call(i,t):r[e];return a}}function R(t,e){return t.isValid()?(e=q(e,t.localeData()),Vn[e]=Vn[e]||P(e),Vn[e](t)):t.localeData().invalidDate()}function q(t,e){function n(t){return e.longDateFormat(t)||t}var r=5;for(zn.lastIndex=0;r>=0&&zn.test(t);)t=t.replace(zn,n),zn.lastIndex=0,r-=1;return t}function j(t){return"function"==typeof t&&"[object Function]"===Object.prototype.toString.call(t)}function U(t,e,n){ur[t]=j(e)?e:function(t){return t&&n?n:e}}function Y(t,e){return o(ur,t)?ur[t](e._strict,e._locale):new RegExp(z(t))}function z(t){return t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,n,r,i){return e||n||r||i}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function V(t,e){var n,r=e;for("string"==typeof t&&(t=[t]),"number"==typeof e&&(r=function(t,n){n[e]=v(t)}),n=0;nr;r++){if(i=c([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(a="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(a.replace(".",""),"i")),n&&"MMMM"===e&&this._longMonthsParse[r].test(t))return r;if(n&&"MMM"===e&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}}function K(t,e){var n;return"string"==typeof e&&(e=t.localeData().monthsParse(e),"number"!=typeof e)?t:(n=Math.min(t.date(),H(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n),t)}function J(t){return null!=t?(K(this,t),n.updateOffset(this,!0),this):F(this,"Month")}function Q(){return H(this.year(),this.month())}function tt(t){var e,n=t._a;return n&&-2===h(t).overflow&&(e=n[cr]<0||n[cr]>11?cr:n[lr]<1||n[lr]>H(n[sr],n[cr])?lr:n[hr]<0||n[hr]>24||24===n[hr]&&(0!==n[fr]||0!==n[dr]||0!==n[pr])?hr:n[fr]<0||n[fr]>59?fr:n[dr]<0||n[dr]>59?dr:n[pr]<0||n[pr]>999?pr:-1,h(t)._overflowDayOfYear&&(sr>e||e>lr)&&(e=lr),h(t).overflow=e),t}function et(t){n.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function nt(t,e){var n=!0;return s(function(){return n&&(et(t+"\n"+(new Error).stack),n=!1),e.apply(this,arguments)},e)}function rt(t,e){mr[t]||(et(e),mr[t]=!0)}function it(t){var e,n,r=t._i,i=vr.exec(r);if(i){for(h(t).iso=!0,e=0,n=br.length;n>e;e++)if(br[e][1].exec(r)){t._f=br[e][0];break}for(e=0,n=_r.length;n>e;e++)if(_r[e][1].exec(r)){t._f+=(i[6]||" ")+_r[e][0];break}r.match(rr)&&(t._f+="Z"),At(t)}else t._isValid=!1}function at(t){var e=xr.exec(t._i);return null!==e?void(t._d=new Date(+e[1])):(it(t),void(t._isValid===!1&&(delete t._isValid,n.createFromInputFallback(t))))}function ut(t,e,n,r,i,a,u){var o=new Date(t,e,n,r,i,a,u);return 1970>t&&o.setFullYear(t),o}function ot(t){var e=new Date(Date.UTC.apply(null,arguments));return 1970>t&&e.setUTCFullYear(t),e}function st(t){return ct(t)?366:365}function ct(t){return t%4===0&&t%100!==0||t%400===0}function lt(){return ct(this.year())}function ht(t,e,n){var r,i=n-e,a=n-t.day();return a>i&&(a-=7),i-7>a&&(a+=7),r=Ft(t).add(a,"d"),{week:Math.ceil(r.dayOfYear()/7),year:r.year()}}function ft(t){return ht(t,this._week.dow,this._week.doy).week}function dt(){return this._week.dow}function pt(){return this._week.doy}function gt(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")}function yt(t){var e=ht(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")}function mt(t,e,n,r,i){var a,u=6+i-r,o=ot(t,0,1+u),s=o.getUTCDay();return i>s&&(s+=7),n=null!=n?1*n:i,a=1+u+7*(e-1)-s+n,{year:a>0?t:t-1,dayOfYear:a>0?a:st(t-1)+a}}function vt(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")}function bt(t,e,n){return null!=t?t:null!=e?e:n}function _t(t){var e=new Date;return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function xt(t){var e,n,r,i,a=[];if(!t._d){for(r=_t(t),t._w&&null==t._a[lr]&&null==t._a[cr]&&wt(t),t._dayOfYear&&(i=bt(t._a[sr],r[sr]),t._dayOfYear>st(i)&&(h(t)._overflowDayOfYear=!0),n=ot(i,0,t._dayOfYear),t._a[cr]=n.getUTCMonth(),t._a[lr]=n.getUTCDate()),e=0;3>e&&null==t._a[e];++e)t._a[e]=a[e]=r[e];for(;7>e;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[hr]&&0===t._a[fr]&&0===t._a[dr]&&0===t._a[pr]&&(t._nextDay=!0,t._a[hr]=0),t._d=(t._useUTC?ot:ut).apply(null,a),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[hr]=24)}}function wt(t){var e,n,r,i,a,u,o;e=t._w,null!=e.GG||null!=e.W||null!=e.E?(a=1,u=4,n=bt(e.GG,t._a[sr],ht(Ft(),1,4).year),r=bt(e.W,1),i=bt(e.E,1)):(a=t._locale._week.dow,u=t._locale._week.doy,n=bt(e.gg,t._a[sr],ht(Ft(),a,u).year),r=bt(e.w,1),null!=e.d?(i=e.d,a>i&&++r):i=null!=e.e?e.e+a:a),o=mt(n,r,i,u,a),t._a[sr]=o.year,t._dayOfYear=o.dayOfYear}function At(t){if(t._f===n.ISO_8601)return void it(t);t._a=[],h(t).empty=!0;var e,r,i,a,u,o=""+t._i,s=o.length,c=0;for(i=q(t._f,t._locale).match(Yn)||[],e=0;e0&&h(t).unusedInput.push(u),o=o.slice(o.indexOf(r)+r.length),c+=r.length),$n[a]?(r?h(t).empty=!1:h(t).unusedTokens.push(a),G(a,r,t)):t._strict&&!r&&h(t).unusedTokens.push(a);h(t).charsLeftOver=s-c,o.length>0&&h(t).unusedInput.push(o),h(t).bigHour===!0&&t._a[hr]<=12&&t._a[hr]>0&&(h(t).bigHour=void 0),t._a[hr]=Et(t._locale,t._a[hr],t._meridiem),xt(t),tt(t)}function Et(t,e,n){var r;return null==n?e:null!=t.meridiemHour?t.meridiemHour(e,n):null!=t.isPM?(r=t.isPM(n),r&&12>e&&(e+=12),r||12!==e||(e=0),e):e}function kt(t){var e,n,r,i,a;if(0===t._f.length)return h(t).invalidFormat=!0,void(t._d=new Date(0/0));for(i=0;ia)&&(r=a,n=e));s(t,n||e)}function Dt(t){if(!t._d){var e=S(t._i);t._a=[e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],xt(t)}}function Ct(t){var e=new g(tt(Mt(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=void 0),e}function Mt(t){var e=t._i,n=t._f;return t._locale=t._locale||D(t._l),null===e||void 0===n&&""===e?d({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),y(e)?new g(tt(e)):(i(n)?kt(t):n?At(t):a(e)?t._d=e:St(t),t))}function St(t){var e=t._i;void 0===e?t._d=new Date:a(e)?t._d=new Date(+e):"string"==typeof e?at(t):i(e)?(t._a=u(e.slice(0),function(t){return parseInt(t,10)}),xt(t)):"object"==typeof e?Dt(t):"number"==typeof e?t._d=new Date(e):n.createFromInputFallback(t)}function Tt(t,e,n,r,i){var a={};return"boolean"==typeof n&&(r=n,n=void 0),a._isAMomentObject=!0,a._useUTC=a._isUTC=i,a._l=n,a._i=t,a._f=e,a._strict=r,Ct(a)}function Ft(t,e,n,r){return Tt(t,e,n,r,!1)}function Bt(t,e){var n,r;if(1===e.length&&i(e[0])&&(e=e[0]),!e.length)return Ft();for(n=e[0],r=1;rt&&(t=-t,n="-"),n+O(~~(t/60),2)+e+O(~~t%60,2)})}function Rt(t){var e=(t||"").match(rr)||[],n=e[e.length-1]||[],r=(n+"").match(Dr)||["-",0,0],i=+(60*r[1])+v(r[2]);return"+"===r[0]?i:-i}function qt(t,e){var r,i;return e._isUTC?(r=e.clone(),i=(y(t)||a(t)?+t:+Ft(t))-+r,r._d.setTime(+r._d+i),n.updateOffset(r,!1),r):Ft(t).local()}function jt(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function Ut(t,e){var r,i=this._offset||0;return null!=t?("string"==typeof t&&(t=Rt(t)),Math.abs(t)<16&&(t=60*t),!this._isUTC&&e&&(r=jt(this)),this._offset=t,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==t&&(!e||this._changeInProgress?re(this,Jt(t-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?i:jt(this)}function Yt(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function zt(t){return this.utcOffset(0,t)}function Vt(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(jt(this),"m")),this}function $t(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(Rt(this._i)),this}function Gt(t){return t=t?Ft(t).utcOffset():0,(this.utcOffset()-t)%60===0}function Ht(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Wt(){if("undefined"!=typeof this._isDSTShifted)return this._isDSTShifted;var t={};if(p(t,this),t=Mt(t),t._a){var e=t._isUTC?c(t._a):Ft(t._a);this._isDSTShifted=this.isValid()&&b(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Zt(){return!this._isUTC}function Xt(){return this._isUTC}function Kt(){return this._isUTC&&0===this._offset}function Jt(t,e){var n,r,i,a=t,u=null;return It(t)?a={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(a={},e?a[e]=t:a.milliseconds=t):(u=Cr.exec(t))?(n="-"===u[1]?-1:1,a={y:0,d:v(u[lr])*n,h:v(u[hr])*n,m:v(u[fr])*n,s:v(u[dr])*n,ms:v(u[pr])*n}):(u=Mr.exec(t))?(n="-"===u[1]?-1:1,a={y:Qt(u[2],n),M:Qt(u[3],n),d:Qt(u[4],n),h:Qt(u[5],n),m:Qt(u[6],n),s:Qt(u[7],n),w:Qt(u[8],n)}):null==a?a={}:"object"==typeof a&&("from"in a||"to"in a)&&(i=ee(Ft(a.from),Ft(a.to)),a={},a.ms=i.milliseconds,a.M=i.months),r=new Nt(a),It(t)&&o(t,"_locale")&&(r._locale=t._locale),r}function Qt(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function te(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 ee(t,e){var n;return e=qt(e,t),t.isBefore(e)?n=te(t,e):(n=te(e,t),n.milliseconds=-n.milliseconds,n.months=-n.months),n}function ne(t,e){return function(n,r){var i,a;return null===r||isNaN(+r)||(rt(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=Jt(n,r),re(this,i,t),this}}function re(t,e,r,i){var a=e._milliseconds,u=e._days,o=e._months;i=null==i?!0:i,a&&t._d.setTime(+t._d+a*r),u&&B(t,"Date",F(t,"Date")+u*r),o&&K(t,F(t,"Month")+o*r),i&&n.updateOffset(t,u||o)}function ie(t,e){var n=t||Ft(),r=qt(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,Ft(n)))}function ae(){return new g(this)}function ue(t,e){var n;return e=M("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Ft(t),+this>+t):(n=y(t)?+t:+Ft(t),n<+this.clone().startOf(e))}function oe(t,e){var n;return e=M("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Ft(t),+t>+this):(n=y(t)?+t:+Ft(t),+this.clone().endOf(e)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 fe(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function de(){var t=this.clone().utc();return 0e;e++)if(this._weekdaysParse[e]||(n=Ft([2e3,1]).day(e),r="^"+this.weekdays(n,"")+"|^"+this.weekdaysShort(n,"")+"|^"+this.weekdaysMin(n,""),this._weekdaysParse[e]=new RegExp(r.replace(".",""),"i")),this._weekdaysParse[e].test(t))return e}function ze(t){var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=Re(t,this.localeData()),this.add(t-e,"d")):e}function Ve(t){var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")}function $e(t){return null==t?this.day()||7:this.day(this.day()%7?t:t-7)}function Ge(t,e){N(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}function He(t,e){return e._meridiemParse}function We(t){return"p"===(t+"").toLowerCase().charAt(0)}function Ze(t,e,n){return t>11?n?"pm":"PM":n?"am":"AM"}function Xe(t,e){e[pr]=v(1e3*("0."+t))}function Ke(){return this._isUTC?"UTC":""}function Je(){return this._isUTC?"Coordinated Universal Time":""}function Qe(t){return Ft(1e3*t)}function tn(){return Ft.apply(null,arguments).parseZone()}function en(t,e,n){var r=this._calendar[t];return"function"==typeof r?r.call(e,n):r}function nn(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.replace(/MMMM|MM|DD|dddd/g,function(t){return t.slice(1)}),this._longDateFormat[t])}function rn(){return this._invalidDate}function an(t){return this._ordinal.replace("%d",t)}function un(t){return t}function on(t,e,n,r){var i=this._relativeTime[n];return"function"==typeof i?i(t,e,n,r):i.replace(/%d/i,t)}function sn(t,e){var n=this._relativeTime[t>0?"future":"past"];return"function"==typeof n?n(e):n.replace(/%s/i,e)}function cn(t){var e,n;for(n in t)e=t[n],"function"==typeof e?this[n]=e:this["_"+n]=e;this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function ln(t,e,n,r){var i=D(),a=c().set(r,e);return i[n](a,t)}function hn(t,e,n,r,i){if("number"==typeof t&&(e=t,t=void 0),t=t||"",null!=e)return ln(t,e,n,i);var a,u=[];for(a=0;r>a;a++)u[a]=ln(t,a,n,i);return u}function fn(t,e){return hn(t,e,"months",12,"month")}function dn(t,e){return hn(t,e,"monthsShort",12,"month")}function pn(t,e){return hn(t,e,"weekdays",7,"day")}function gn(t,e){return hn(t,e,"weekdaysShort",7,"day")}function yn(t,e){return hn(t,e,"weekdaysMin",7,"day")}function mn(){var t=this._data;return this._milliseconds=Kr(this._milliseconds),this._days=Kr(this._days),this._months=Kr(this._months),t.milliseconds=Kr(t.milliseconds),t.seconds=Kr(t.seconds),t.minutes=Kr(t.minutes),t.hours=Kr(t.hours),t.months=Kr(t.months),t.years=Kr(t.years),this}function vn(t,e,n,r){var i=Jt(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function bn(t,e){return vn(this,t,e,1)}function _n(t,e){return vn(this,t,e,-1)}function xn(t){return 0>t?Math.floor(t):Math.ceil(t)}function wn(){var t,e,n,r,i,a=this._milliseconds,u=this._days,o=this._months,s=this._data;return a>=0&&u>=0&&o>=0||0>=a&&0>=u&&0>=o||(a+=864e5*xn(En(o)+u),u=0,o=0),s.milliseconds=a%1e3,t=m(a/1e3),s.seconds=t%60,e=m(t/60),s.minutes=e%60,n=m(e/60),s.hours=n%24,u+=m(n/24),i=m(An(u)),o+=i,u-=xn(En(i)),r=m(o/12),o%=12,s.days=u,s.months=o,s.years=r,this}function An(t){return 4800*t/146097}function En(t){return 146097*t/4800}function kn(t){var e,n,r=this._milliseconds;if(t=M(t),"month"===t||"year"===t)return e=this._days+r/864e5,n=this._months+An(e),"month"===t?n:n/12;switch(e=this._days+Math.round(En(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return 24*e+r/36e5;case"minute":return 1440*e+r/6e4;case"second":return 86400*e+r/1e3;case"millisecond":return Math.floor(864e5*e)+r;default:throw new Error("Unknown unit "+t)}}function Dn(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function Cn(t){return function(){return this.as(t)}}function Mn(t){return t=M(t),this[t+"s"]()}function Sn(t){return function(){return this._data[t]}}function Tn(){return m(this.days()/7)}function Fn(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}function Bn(t,e,n){var r=Jt(t).abs(),i=di(r.as("s")),a=di(r.as("m")),u=di(r.as("h")),o=di(r.as("d")),s=di(r.as("M")),c=di(r.as("y")),l=i0,l[4]=n,Fn.apply(null,l)}function Ln(t,e){return void 0===pi[t]?!1:void 0===e?pi[t]:(pi[t]=e,!0)}function On(t){var e=this.localeData(),n=Bn(this,!t,e);return t&&(n=e.pastFuture(+this,n)),e.postformat(n)}function Nn(){var t,e,n,r=gi(this._milliseconds)/1e3,i=gi(this._days),a=gi(this._months);t=m(r/60),e=m(t/60),r%=60,t%=60,n=m(a/12),a%=12;var u=n,o=a,s=i,c=e,l=t,h=r,f=this.asSeconds();return f?(0>f?"-":"")+"P"+(u?u+"Y":"")+(o?o+"M":"")+(s?s+"D":"")+(c||l||h?"T":"")+(c?c+"H":"")+(l?l+"M":"")+(h?h+"S":""):"P0D"}var In,Pn,Rn=n.momentProperties=[],qn=!1,jn={},Un={},Yn=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,zn=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Vn={},$n={},Gn=/\d/,Hn=/\d\d/,Wn=/\d{3}/,Zn=/\d{4}/,Xn=/[+-]?\d{6}/,Kn=/\d\d?/,Jn=/\d{1,3}/,Qn=/\d{1,4}/,tr=/[+-]?\d{1,6}/,er=/\d+/,nr=/[+-]?\d+/,rr=/Z|[+-]\d\d:?\d\d/gi,ir=/[+-]?\d+(\.\d{1,3})?/,ar=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,ur={},or={},sr=0,cr=1,lr=2,hr=3,fr=4,dr=5,pr=6;N("M",["MM",2],"Mo",function(){return this.month()+1}),N("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),N("MMMM",0,0,function(t){return this.localeData().months(this,t)}),C("month","M"),U("M",Kn),U("MM",Kn,Hn),U("MMM",ar),U("MMMM",ar),V(["M","MM"],function(t,e){e[cr]=v(t)-1}),V(["MMM","MMMM"],function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);null!=i?e[cr]=i:h(n).invalidMonth=t});var gr="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),yr="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),mr={};n.suppressDeprecationWarnings=!1;var vr=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,br=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],_r=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],xr=/^\/?Date\((\-?\d+)/i;n.createFromInputFallback=nt("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),N(0,["YY",2],0,function(){return this.year()%100}),N(0,["YYYY",4],0,"year"),N(0,["YYYYY",5],0,"year"),N(0,["YYYYYY",6,!0],0,"year"),C("year","y"),U("Y",nr),U("YY",Kn,Hn),U("YYYY",Qn,Zn),U("YYYYY",tr,Xn),U("YYYYYY",tr,Xn),V(["YYYYY","YYYYYY"],sr),V("YYYY",function(t,e){e[sr]=2===t.length?n.parseTwoDigitYear(t):v(t)}),V("YY",function(t,e){e[sr]=n.parseTwoDigitYear(t)}),n.parseTwoDigitYear=function(t){return v(t)+(v(t)>68?1900:2e3)};var wr=T("FullYear",!1);N("w",["ww",2],"wo","week"),N("W",["WW",2],"Wo","isoWeek"),C("week","w"),C("isoWeek","W"),U("w",Kn),U("ww",Kn,Hn),U("W",Kn),U("WW",Kn,Hn),$(["w","ww","W","WW"],function(t,e,n,r){e[r.substr(0,1)]=v(t)});var Ar={dow:0,doy:6};N("DDD",["DDDD",3],"DDDo","dayOfYear"),C("dayOfYear","DDD"),U("DDD",Jn),U("DDDD",Wn),V(["DDD","DDDD"],function(t,e,n){n._dayOfYear=v(t)}),n.ISO_8601=function(){};var Er=nt("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var t=Ft.apply(null,arguments);return this>t?this:t}),kr=nt("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var t=Ft.apply(null,arguments);return t>this?this:t});Pt("Z",":"),Pt("ZZ",""),U("Z",rr),U("ZZ",rr),V(["Z","ZZ"],function(t,e,n){n._useUTC=!0,n._tzm=Rt(t)});var Dr=/([\+\-]|\d\d)/gi;n.updateOffset=function(){};var Cr=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Mr=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/;Jt.fn=Nt.prototype;var Sr=ne(1,"add"),Tr=ne(-1,"subtract");n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var Fr=nt("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return void 0===t?this.localeData():this.locale(t)});N(0,["gg",2],0,function(){return this.weekYear()%100}),N(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Fe("gggg","weekYear"),Fe("ggggg","weekYear"),Fe("GGGG","isoWeekYear"),Fe("GGGGG","isoWeekYear"),C("weekYear","gg"),C("isoWeekYear","GG"),U("G",nr),U("g",nr),U("GG",Kn,Hn),U("gg",Kn,Hn),U("GGGG",Qn,Zn),U("gggg",Qn,Zn),U("GGGGG",tr,Xn),U("ggggg",tr,Xn),$(["gggg","ggggg","GGGG","GGGGG"],function(t,e,n,r){e[r.substr(0,2)]=v(t)}),$(["gg","GG"],function(t,e,r,i){e[i]=n.parseTwoDigitYear(t)}),N("Q",0,0,"quarter"),C("quarter","Q"),U("Q",Gn),V("Q",function(t,e){e[cr]=3*(v(t)-1)}),N("D",["DD",2],"Do","date"),C("date","D"),U("D",Kn),U("DD",Kn,Hn),U("Do",function(t,e){return t?e._ordinalParse:e._ordinalParseLenient}),V(["D","DD"],lr),V("Do",function(t,e){e[lr]=v(t.match(Kn)[0],10)});var Br=T("Date",!0);N("d",0,"do","day"),N("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),N("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),N("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),N("e",0,0,"weekday"),N("E",0,0,"isoWeekday"),C("day","d"),C("weekday","e"),C("isoWeekday","E"),U("d",Kn),U("e",Kn),U("E",Kn),U("dd",ar),U("ddd",ar),U("dddd",ar),$(["dd","ddd","dddd"],function(t,e,n){var r=n._locale.weekdaysParse(t);null!=r?e.d=r:h(n).invalidWeekday=t}),$(["d","e","E"],function(t,e,n,r){ -e[r]=v(t)});var Lr="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Or="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Nr="Su_Mo_Tu_We_Th_Fr_Sa".split("_");N("H",["HH",2],0,"hour"),N("h",["hh",2],0,function(){return this.hours()%12||12}),Ge("a",!0),Ge("A",!1),C("hour","h"),U("a",He),U("A",He),U("H",Kn),U("h",Kn),U("HH",Kn,Hn),U("hh",Kn,Hn),V(["H","HH"],hr),V(["a","A"],function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t}),V(["h","hh"],function(t,e,n){e[hr]=v(t),h(n).bigHour=!0});var Ir=/[ap]\.?m?\.?/i,Pr=T("Hours",!0);N("m",["mm",2],0,"minute"),C("minute","m"),U("m",Kn),U("mm",Kn,Hn),V(["m","mm"],fr);var Rr=T("Minutes",!1);N("s",["ss",2],0,"second"),C("second","s"),U("s",Kn),U("ss",Kn,Hn),V(["s","ss"],dr);var qr=T("Seconds",!1);N("S",0,0,function(){return~~(this.millisecond()/100)}),N(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),N(0,["SSS",3],0,"millisecond"),N(0,["SSSS",4],0,function(){return 10*this.millisecond()}),N(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),N(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),N(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),N(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),N(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),C("millisecond","ms"),U("S",Jn,Gn),U("SS",Jn,Hn),U("SSS",Jn,Wn);var jr;for(jr="SSSS";jr.length<=9;jr+="S")U(jr,er);for(jr="S";jr.length<=9;jr+="S")V(jr,Xe);var Ur=T("Milliseconds",!1);N("z",0,0,"zoneAbbr"),N("zz",0,0,"zoneName");var Yr=g.prototype;Yr.add=Sr,Yr.calendar=ie,Yr.clone=ae,Yr.diff=le,Yr.endOf=we,Yr.format=pe,Yr.from=ge,Yr.fromNow=ye,Yr.to=me,Yr.toNow=ve,Yr.get=L,Yr.invalidAt=Te,Yr.isAfter=ue,Yr.isBefore=oe,Yr.isBetween=se,Yr.isSame=ce,Yr.isValid=Me,Yr.lang=Fr,Yr.locale=be,Yr.localeData=_e,Yr.max=kr,Yr.min=Er,Yr.parsingFlags=Se,Yr.set=L,Yr.startOf=xe,Yr.subtract=Tr,Yr.toArray=De,Yr.toObject=Ce,Yr.toDate=ke,Yr.toISOString=de,Yr.toJSON=de,Yr.toString=fe,Yr.unix=Ee,Yr.valueOf=Ae,Yr.year=wr,Yr.isLeapYear=lt,Yr.weekYear=Le,Yr.isoWeekYear=Oe,Yr.quarter=Yr.quarters=Pe,Yr.month=J,Yr.daysInMonth=Q,Yr.week=Yr.weeks=gt,Yr.isoWeek=Yr.isoWeeks=yt,Yr.weeksInYear=Ie,Yr.isoWeeksInYear=Ne,Yr.date=Br,Yr.day=Yr.days=ze,Yr.weekday=Ve,Yr.isoWeekday=$e,Yr.dayOfYear=vt,Yr.hour=Yr.hours=Pr,Yr.minute=Yr.minutes=Rr,Yr.second=Yr.seconds=qr,Yr.millisecond=Yr.milliseconds=Ur,Yr.utcOffset=Ut,Yr.utc=zt,Yr.local=Vt,Yr.parseZone=$t,Yr.hasAlignedHourOffset=Gt,Yr.isDST=Ht,Yr.isDSTShifted=Wt,Yr.isLocal=Zt,Yr.isUtcOffset=Xt,Yr.isUtc=Kt,Yr.isUTC=Kt,Yr.zoneAbbr=Ke,Yr.zoneName=Je,Yr.dates=nt("dates accessor is deprecated. Use date instead.",Br),Yr.months=nt("months accessor is deprecated. Use month instead",J),Yr.years=nt("years accessor is deprecated. Use year instead",wr),Yr.zone=nt("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Yt);var zr=Yr,Vr={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},$r={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"},Gr="Invalid date",Hr="%d",Wr=/\d{1,2}/,Zr={future:"in %s",past:"%s ago",s:"a few 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"},Xr=_.prototype;Xr._calendar=Vr,Xr.calendar=en,Xr._longDateFormat=$r,Xr.longDateFormat=nn,Xr._invalidDate=Gr,Xr.invalidDate=rn,Xr._ordinal=Hr,Xr.ordinal=an,Xr._ordinalParse=Wr,Xr.preparse=un,Xr.postformat=un,Xr._relativeTime=Zr,Xr.relativeTime=on,Xr.pastFuture=sn,Xr.set=cn,Xr.months=W,Xr._months=gr,Xr.monthsShort=Z,Xr._monthsShort=yr,Xr.monthsParse=X,Xr.week=ft,Xr._week=Ar,Xr.firstDayOfYear=pt,Xr.firstDayOfWeek=dt,Xr.weekdays=qe,Xr._weekdays=Lr,Xr.weekdaysMin=Ue,Xr._weekdaysMin=Nr,Xr.weekdaysShort=je,Xr._weekdaysShort=Or,Xr.weekdaysParse=Ye,Xr.isPM=We,Xr._meridiemParse=Ir,Xr.meridiem=Ze,E("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,n=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+n}}),n.lang=nt("moment.lang is deprecated. Use moment.locale instead.",E),n.langData=nt("moment.langData is deprecated. Use moment.localeData instead.",D);var Kr=Math.abs,Jr=Cn("ms"),Qr=Cn("s"),ti=Cn("m"),ei=Cn("h"),ni=Cn("d"),ri=Cn("w"),ii=Cn("M"),ai=Cn("y"),ui=Sn("milliseconds"),oi=Sn("seconds"),si=Sn("minutes"),ci=Sn("hours"),li=Sn("days"),hi=Sn("months"),fi=Sn("years"),di=Math.round,pi={s:45,m:45,h:22,d:26,M:11},gi=Math.abs,yi=Nt.prototype;yi.abs=mn,yi.add=bn,yi.subtract=_n,yi.as=kn,yi.asMilliseconds=Jr,yi.asSeconds=Qr,yi.asMinutes=ti,yi.asHours=ei,yi.asDays=ni,yi.asWeeks=ri,yi.asMonths=ii,yi.asYears=ai,yi.valueOf=Dn,yi._bubble=wn,yi.get=Mn,yi.milliseconds=ui,yi.seconds=oi,yi.minutes=si,yi.hours=ci,yi.days=li,yi.weeks=Tn,yi.months=hi,yi.years=fi,yi.humanize=On,yi.toISOString=Nn,yi.toString=Nn,yi.toJSON=Nn,yi.locale=be,yi.localeData=_e,yi.toIsoString=nt("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Nn),yi.lang=Fr,N("X",0,0,"unix"),N("x",0,0,"valueOf"),U("x",nr),U("X",ir),V("X",function(t,e,n){n._d=new Date(1e3*parseFloat(t,10))}),V("x",function(t,e,n){n._d=new Date(v(t))}),n.version="2.10.6",r(Ft),n.fn=zr,n.min=Lt,n.max=Ot,n.utc=c,n.unix=Qe,n.months=fn,n.isDate=a,n.locale=E,n.invalid=d,n.duration=Jt,n.isMoment=y,n.weekdays=pn,n.parseZone=tn,n.localeData=D,n.isDuration=It,n.monthsShort=dn,n.weekdaysMin=yn,n.defineLocale=k,n.weekdaysShort=gn,n.normalizeUnits=M,n.relativeTimeThreshold=Ln;var mi=n;return mi})},{}],107:[function(t,e){e.exports={name:"mermaid",version:"0.5.5",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:{live:"live-server ./test/examples",lint:"node node_modules/eslint/bin/eslint.js src",jison:"gulp jison_legacy",watch:"source ./scripts/watch.sh",doc:"rm -r build;rm -r dist/www;gulp vartree;cp dist/www/all.html ../mermaid-pages/index.html;cp dist/mermaid.js ../mermaid-pages/javascripts/lib;cp dist/mermaid.forest.css ../mermaid-pages/stylesheets",tape:"node node_modules/.bin/tape test/cli_test-*.js",jasmine:"npm run jison &&node node_modules/jasmine-es6/bin/jasmine.js",posttest:"npm run jison",test:"npm run dist && npm run jasmine && npm run tape","dist-slim-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.slim.js -x d3 && cat dist/mermaid.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.slim.min.js","dist-slim-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.slim.js -x d3 && cat dist/mermaidAPI.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.slim.min.js","dist-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.js && cat dist/mermaid.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.min.js","dist-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.js && cat dist/mermaidAPI.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.min.js",dist:"npm run dist-slim-mermaid;npm run dist-slim-mermaidAPI; npm run dist-mermaid;npm run dist-mermaidAPI"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"3.5.6",dagre:"^0.7.4","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","babel-eslint":"^4.1.3",babelify:"^6.4.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4",dateformat:"^1.0.11",dox:"^0.8.0",eslint:"^1.6.0","eslint-watch":"^2.1.2","event-stream":"^3.2.0",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.9.0","gulp-bower":"0.0.10","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-dox":"^0.1.6","gulp-ext-replace":"^0.2.0","gulp-filelog":"^0.4.1","gulp-front-matter":"^1.2.3","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~2.1.0","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-marked":"^1.0.0","gulp-mdvars":"^2.0.0","gulp-qunit":"~1.2.1","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1","gulp-vartree":"^2.0.1","hogan.js":"^3.0.2",jasmine:"2.3.2","jasmine-es6":"0.0.18",jison:"zaach/jison",jsdom:"^7.0.2","jshint-stylish":"^2.0.1","map-stream":"0.0.6",marked:"^0.3.2","mock-browser":"^0.91.34",path:"^0.4.9",phantomjs:"^1.9.18",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3",testdom:"^2.0.0",uglifyjs:"^2.4.10","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],108:[function(t,e){"use strict";var n;if(t)try{n=t("d3")}catch(r){}n||(n=window.d3),e.exports=n,function(){var t=!1;if(t="tspans",n.selection.prototype.textwrap)return!1;if("undefined"==typeof t)var t=!1;n.selection.prototype.textwrap=n.selection.enter.prototype.textwrap=function(e,r){var i,r=parseInt(r)||0,a=this,u=function(t){var e=t[0][0],r=e.tagName.toString();if("rect"!==r)return!1;var i={};return i.x=n.select(e).attr("x")||0,i.y=n.select(e).attr("y")||0,i.width=n.select(e).attr("width")||0,i.height=n.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)||"[object Array]"===Object.prototype.toString.call(t)){var e=u(t);return e}return!1},s=function(t,e){var n=t;return 0!==e&&(n.x=parseInt(n.x)+e,n.y=parseInt(n.y)+e,n.width-=2*e,n.height-=2*e),n},c=o(e);if(r&&(c=s(c,r)),0!=a.length&&n&&e&&c){e=c;var l,h=function(t){var r=n.select(t[0].parentNode),a=r.select("text"),u=a.style("line-height"),o=a.text();a.remove();var s=r.append("foreignObject");s.attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);var c=s.append("xhtml:div").attr("class","wrapped");c.style("height",e.height).style("width",e.width).html(o),u&&c.style("line-height",u),i=r.select("foreignObject")},f=function(t){var a,u=t[0],o=u.parentNode,s=n.select(u),c=u.getBBox().height,l=u.getBBox().width,h=c,f=s.style("line-height");if(a=f&&parseInt(f)?parseInt(f.replace("px","")):h,l>e.width){var d=s.text();if(s.text(""),d){var p,g;if(-1!==d.indexOf(" ")){var p=" ";g=d.split(" ")}else{p="";var y=d.length,m=Math.ceil(l/e.width),v=Math.floor(y/m);v*m>=y||m++;for(var b,_,g=[],x=0;m>x;x++)_=x*v,b=d.substr(_,v),g.push(b)}for(var w=[],A=0,E={},x=0;xe.width&&C&&""!==C&&(A+=M,E={string:C,width:M,offset:A},w.push(E),s.text(""),s.text(D),x==g.length-1&&(k=D,s.text(k),S=u.getComputedTextLength())),x==g.length-1){s.text("");var T=k;T&&""!==T&&(S-A>0&&(S-=A),E={string:T,width:S,offset:A},w.push(E))}}var F;s.text("");for(var x=0;x0){w[x-1]}x*a0?a:void 0}),F.attr("x",function(){var t=e.x;return r&&(t+=r),t}))}}}s.attr("y",function(){var t=e.y;return a&&(t+=a),r&&(t+=r),t}),s.attr("x",function(){var t=e.x;return r&&(t+=r),t}),i=n.select(o).selectAll("text")};t&&("foreignobjects"==t?l=h:"tspans"==t&&(l=f)),t||(l="undefined"!=typeof SVGForeignObjectElement?h:f);for(var d=0;d "+t.w+": "+JSON.stringify(r.edge(t))),v(n,r.edge(t),r.edge(t).relation)}),n.attr("height","100%"),n.attr("width","100%")}},{"../../d3":108,"../../logger":127,"./classDb":109,"./parser/classDiagram":111,dagre:54}],111:[function(t,e,n){(function(r){"use strict";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,11],r=[1,12],i=[1,13],a=[1,15],u=[1,16],o=[1,17],s=[6,8],c=[1,26],l=[1,27],h=[1,28],f=[1,29],d=[1,30],p=[1,31],g=[6,8,13,17,23,26,27,28,29,30,31],y=[6,8,13,17,23,26,27,28,29,30,31,45,46,47],m=[23,45,46,47],v=[23,30,31,45,46,47],b=[23,26,27,28,29,45,46,47],_=[6,8,13],x=[1,46],w={trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,CLASS_DIAGRAM:5,NEWLINE:6,statements:7,EOF:8,statement:9,className:10,alphaNumToken:11,relationStatement:12,LABEL:13,classStatement:14,methodStatement:15,CLASS:16,STRUCT_START:17,members:18,STRUCT_STOP:19,MEMBER:20,SEPARATOR:21,relation:22,STR:23,relationType:24,lineType:25,AGGREGATION:26,EXTENSION:27,COMPOSITION:28,DEPENDENCY:29,LINE:30,DOTTED_LINE:31,commentToken:32,textToken:33,graphCodeTokens:34,textNoTagsToken:35,TAGSTART:36,TAGEND:37,"==":38,"--":39,PCT:40,DEFAULT:41,SPACE:42,MINUS:43,keywords:44,UNICODE_TEXT:45,NUM:46,ALPHA:47,$accept:0,$end:1},terminals_:{2:"error",5:"CLASS_DIAGRAM",6:"NEWLINE",8:"EOF",13:"LABEL",16:"CLASS",17:"STRUCT_START",19:"STRUCT_STOP",20:"MEMBER",21:"SEPARATOR",23:"STR",26:"AGGREGATION",27:"EXTENSION",28:"COMPOSITION",29:"DEPENDENCY",30:"LINE",31:"DOTTED_LINE",34:"graphCodeTokens",36:"TAGSTART",37:"TAGEND",38:"==",39:"--",40:"PCT",41:"DEFAULT",42:"SPACE",43:"MINUS",44:"keywords",45:"UNICODE_TEXT",46:"NUM",47:"ALPHA"},productions_:[0,[3,1],[4,4],[7,1],[7,3],[10,2],[10,1],[9,1],[9,2],[9,1],[9,1],[14,2],[14,5],[18,1],[18,2],[15,1],[15,2],[15,1],[15,1],[12,3],[12,4],[12,4],[12,5],[22,3],[22,2],[22,2],[22,1],[24,1],[24,1],[24,1],[24,1],[25,1],[25,1],[32,1],[32,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[35,1],[35,1],[35,1],[35,1],[11,1],[11,1],[11,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 5:this.$=a[u-1]+a[u];break;case 6:this.$=a[u];break;case 7:r.addRelation(a[u]);break;case 8:a[u-1].title=r.cleanupLabel(a[u]),r.addRelation(a[u-1]);break;case 12:r.addMembers(a[u-3],a[u-1]);break;case 13:this.$=[a[u]];break;case 14:a[u].push(a[u-1]),this.$=a[u];break;case 15:break;case 16:r.addMembers(a[u-1],r.cleanupLabel(a[u]));break;case 17:console.warn("Member",a[u]);break;case 18:break;case 19:this.$={id1:a[u-2],id2:a[u],relation:a[u-1],relationTitle1:"none",relationTitle2:"none"};break;case 20:this.$={id1:a[u-3],id2:a[u],relation:a[u-1],relationTitle1:a[u-2],relationTitle2:"none"};break;case 21:this.$={id1:a[u-3],id2:a[u],relation:a[u-2],relationTitle1:"none",relationTitle2:a[u-1]};break;case 22:this.$={id1:a[u-4],id2:a[u],relation:a[u-2],relationTitle1:a[u-3],relationTitle2:a[u-1]};break;case 23:this.$={type1:a[u-2],type2:a[u],lineType:a[u-1]};break;case 24:this.$={type1:"none",type2:a[u],lineType:a[u-1]};break;case 25:this.$={type1:a[u-1],type2:"none",lineType:a[u]};break;case 26:this.$={type1:"none",type2:"none",lineType:a[u]};break;case 27:this.$=r.relationType.AGGREGATION;break;case 28:this.$=r.relationType.EXTENSION;break;case 29:this.$=r.relationType.COMPOSITION;break;case 30:this.$=r.relationType.DEPENDENCY;break;case 31:this.$=r.lineType.LINE;break;case 32:this.$=r.lineType.DOTTED_LINE}},table:[{3:1,4:2,5:[1,3]},{1:[3]},{1:[2,1]},{6:[1,4]},{7:5,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:u,47:o},{8:[1,18]},{6:[1,19],8:[2,3]},e(s,[2,7],{13:[1,20]}),e(s,[2,9]),e(s,[2,10]),e(s,[2,15],{22:21,24:24,25:25,13:[1,23],23:[1,22],26:c,27:l,28:h,29:f,30:d,31:p}),{10:32,11:14,45:a,46:u,47:o},e(s,[2,17]),e(s,[2,18]),e(g,[2,6],{11:14,10:33,45:a,46:u,47:o}),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),{1:[2,2]},{7:34,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:u,47:o},e(s,[2,8]),{10:35,11:14,23:[1,36],45:a,46:u,47:o},{22:37,24:24,25:25,26:c,27:l,28:h,29:f,30:d,31:p},e(s,[2,16]),{25:38,30:d,31:p},e(m,[2,26],{24:39,26:c,27:l,28:h,29:f}),e(v,[2,27]),e(v,[2,28]),e(v,[2,29]),e(v,[2,30]),e(b,[2,31]),e(b,[2,32]),e(s,[2,11],{17:[1,40]}),e(g,[2,5]),{8:[2,4]},e(_,[2,19]),{10:41,11:14,45:a,46:u,47:o},{10:42,11:14,23:[1,43],45:a,46:u,47:o},e(m,[2,25],{24:44,26:c,27:l,28:h,29:f}),e(m,[2,24]),{18:45,20:x},e(_,[2,21]),e(_,[2,20]),{10:47,11:14,45:a,46:u,47:o},e(m,[2,23]),{19:[1,48]},{18:49,19:[2,13],20:x},e(_,[2,22]),e(s,[2,12]),{19:[2,14]}],defaultActions:{2:[2,1],18:[2,2],34:[2,4],49:[2,14]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},A=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:return 6;case 2:break;case 3:return 5;case 4:return this.begin("struct"),17;case 5:return this.popState(),19;case 6:break;case 7:return"MEMBER";case 8:return 16;case 9:this.begin("string"); - -break;case 10:this.popState();break;case 11:return"STR";case 12:return 27;case 13:return 27;case 14:return 29;case 15:return 29;case 16:return 28;case 17:return 26;case 18:return 30;case 19:return 31;case 20:return 13;case 21:return 43;case 22:return"DOT";case 23:return"PLUS";case 24:return 40;case 25:return"EQUALS";case 26:return"EQUALS";case 27:return 47;case 28:return"PUNCTUATION";case 29:return 46;case 30:return 45;case 31:return 42;case 32:return 8}},rules:[/^(?:%%[^\n]*)/,/^(?:\n+)/,/^(?:\s+)/,/^(?:classDiagram\b)/,/^(?:[\{])/,/^(?:\})/,/^(?:[\n])/,/^(?:[^\{\}\n]*)/,/^(?:class\b)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::[^#\n;]+)/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[A-Za-z]+)/,/^(?:[!"#$%&'*+,-.`?\\_\/])/,/^(?:[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:{string:{rules:[10,11],inclusive:!1},struct:{rules:[5,6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,8,9,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32],inclusive:!0}}};return t}();return w.lexer=A,t.prototype=w,w.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("_process"))},{_process:3,fs:1,path:2}],112:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=new a.Log,o="",s=!1;n.setMessage=function(t){u.debug("Setting message to: "+t),o=t},n.getMessage=function(){return o},n.setInfo=function(t){s=t},n.getInfo=function(){return s},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":127}],113:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=t("./exampleDb"),o=t("./parser/example.js"),s=t("../../d3"),c=new a.Log;n.draw=function(t,e,n){var r;r=o.parser,r.yy=u,c.debug("Renering example diagram"),r.parse(t);var i=s.select("#"+e),a=i.append("g");a.append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("mermaid "+n),i.attr("height",100),i.attr("width",400)}},{"../../d3":108,"../../logger":127,"./exampleDb":112,"./parser/example.js":114}],114:[function(t,e,n){(function(r){"use strict";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=[6,9,10,12],r={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,message:11,say:12,TXT:13,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo",12:"say",13:"TXT"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1],[8,1],[11,2]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:return r;case 4:break;case 6:r.setInfo(!0);break;case 7:r.setMessage(a[u]);break;case 8:this.$=a[u-1].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8],11:9,12:[1,10]},{1:[2,1]},e(n,[2,3]),e(n,[2,4]),e(n,[2,5]),e(n,[2,6]),e(n,[2,7]),{13:[1,11]},e(n,[2,8])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},i=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,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),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;ae[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]),"utf8");return n.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&n.main(r.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],115:[function(t,e){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var r,i=t("../../logger"),a=n(i),u=new a.Log;if(t)try{r=t("dagre-d3")}catch(o){u.debug("Could not load dagre-d3")}r||(r=window.dagreD3),e.exports=r},{"../../logger":127,"dagre-d3":5}],116:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=t("./graphDb"),o=t("./parser/flow"),s=t("./parser/dot"),c=t("../../d3"),l=t("./dagre-d3"),h=new a.Log,f={};e.exports.setConf=function(t){var e,n=Object.keys(t);for(e=0;e0&&(u=a.classes.join(" "));var o="";o=r(o,a.styles),i="undefined"==typeof a.text?a.id:a.text;var s="";f.htmlLabels?(s="html",i=i.replace(/fa:fa[\w\-]+/g,function(t){return''})):(i=i.replace(/
/g,"\n"),s="text");var c=0,l="";switch(a.type){case"round":c=5,l="rect";break;case"square":l="rect";break;case"diamond":l="question";break;case"odd":l="rect_left_inv_arrow";break;case"odd_right":l="rect_left_inv_arrow";break;case"circle":l="circle";break;case"ellipse":l="ellipse";break;case"group":l="rect",i="";break;default:l="rect"}e.setNode(a.id,{labelType:s,shape:l,label:i,rx:c,ry:c,"class":u,style:o,id:a.id})})},n.addEdges=function(t,e){var n,r,i=0;"undefined"!=typeof t.defaultStyle&&(r=t.defaultStyle.toString().replace(/,/g,";")),t.forEach(function(t){i++,n="arrow_open"===t.type?"none":"normal";var a="";if("undefined"!=typeof t.style)t.style.forEach(function(t){a=a+t+";"});else switch(t.stroke){case"normal":a="fill:none","undefined"!=typeof r&&(a=r);break;case"dotted":a="stroke: #333; fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":a="stroke: #333; stroke-width: 3.5px;fill:none"}if("undefined"==typeof t.text)"undefined"==typeof t.style?e.setEdge(t.start,t.end,{style:a,arrowhead:n},i):e.setEdge(t.start,t.end,{style:a,arrowheadStyle:"fill: #333",arrowhead:n},i);else{var u=t.text.replace(/
/g,"\n");"undefined"==typeof t.style?f.htmlLabels?e.setEdge(t.start,t.end,{labelType:"html",style:a,labelpos:"c",label:''+t.text+"",arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:"stroke: #333; stroke-width: 1.5px;fill:none",labelpos:"c",label:u,arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:a,arrowheadStyle:"fill: #333",label:u,arrowhead:n},i)}})},n.getClasses=function(t,e){var n;u.clear(),n=e?s.parser:o.parser,n.yy=u,n.parse(t);var r=u.getClasses();return"undefined"==typeof r["default"]&&(r["default"]={id:"default"},r["default"].styles=[],r["default"].clusterStyles=["rx:4px","fill: rgb(255, 255, 222)","rx: 4px","stroke: rgb(170, 170, 51)","stroke-width: 1px"],r["default"].nodeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"],r["default"].edgeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"]),r},n.draw=function(t,e,r){h.debug("Drawing flowchart");var i;u.clear(),i=r?s.parser:o.parser,i.yy=u;try{i.parse(t)}catch(a){h.debug("Parsing failed")}var d;d=u.getDirection(),"undefined"==typeof d&&(d="TD");var p,g=new l.graphlib.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:d,marginx:20,marginy:20}).setDefaultEdgeLabel(function(){return{}}),y=u.getSubGraphs(),m=0;for(m=y.length-1;m>=0;m--)p=y[m],u.addVertex(p.id,p.title,"group",void 0);var v=u.getVertices(),b=u.getEdges();m=0;var _;for(m=y.length-1;m>=0;m--)for(p=y[m],c.selectAll("cluster").append("text"),_=0;_0?t.split(",").forEach(function(t){"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)}):"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)};var setTooltip=function(t,e){"undefined"!=typeof e&&(tooltips[t]=e)},setClickFun=function setClickFun(id,functionName){"undefined"!=typeof functionName&&"undefined"!=typeof vertices[id]&&funs.push(function(element){var elem=d3.select(element).select("#"+id);null!==elem&&elem.on("click",function(){eval(functionName+"('"+id+"')")})})},setLink=function(t,e){"undefined"!=typeof e&&"undefined"!=typeof vertices[t]&&funs.push(function(n){var r=d3.select(n).select("#"+t);null!==r&&r.on("click",function(){window.open(e,"newTab")})})};exports.getTooltip=function(t){return tooltips[t]},exports.setClickEvent=function(t,e,n,r){t.indexOf(",")>0?t.split(",").forEach(function(t){setTooltip(t,r),setClickFun(t,e),setLink(t,n)}):(setTooltip(t,r),setClickFun(t,e),setLink(t,n))},exports.bindFunctions=function(t){funs.forEach(function(e){e(t)})},exports.getDirection=function(){return direction},exports.getVertices=function(){return vertices},exports.getEdges=function(){return edges},exports.getClasses=function(){return classes};var setupToolTips=function(t){var e=d3.select(".mermaidTooltip");null===e[0][0]&&(e=d3.select("body").append("div").attr("class","mermaidTooltip").style("opacity",0));var n=d3.select(t).select("svg"),r=n.selectAll("g.node");r.on("mouseover",function(){var t=d3.select(this),n=t.attr("title");if(null!==n){var r=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",r.left+(r.right-r.left)/2+"px").style("top",r.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}}).on("mouseout",function(){e.transition().duration(500).style("opacity",0);var t=d3.select(this);t.classed("hover",!1)})};funs.push(setupToolTips),exports.clear=function(){vertices={},classes={},edges=[],funs=[],funs.push(setupToolTips),subGraphs=[],subCount=0,tooltips=[]},exports.defaultStyle=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},exports.addSubGraph=function(t,e){function n(t){var e={"boolean":{},number:{},string:{}},n=[];return t.filter(function(t){var r=typeof t;return" "===t?!1:r in e?e[r].hasOwnProperty(t)?!1:e[r][t]=!0:n.indexOf(t)>=0?!1:n.push(t)})}var r=[];r=n(r.concat.apply(r,t));var i={id:"subGraph"+subCount,nodes:r,title:e};return subGraphs.push(i),subCount+=1,i.id};var getPosForId=function(t){var e;for(e=0;e2e3)){if(posCrossRef[secCount]=n,subGraphs[n].id===e)return{result:!0,count:0};for(var i=0,a=1;i=0){var o=t(e,u);if(o.result)return{result:!0,count:a+o.count};a+=o.count}i+=1}return{result:!1,count:a}}};exports.getDepthFirstPos=function(t){return posCrossRef[t]},exports.indexNodes=function(){secCount=-1,subGraphs.length>0&&indexNodes("none",subGraphs.length-1,0)},exports.getSubGraphs=function(){return subGraphs},exports.parseError=function(t,e){global.mermaidAPI.parseError(t,e)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../d3":108,"../../logger":127}],118:[function(t,e,n){(function(r){"use strict";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,5],r=[1,6],i=[1,12],a=[1,13],u=[1,14],o=[1,15],s=[1,16],c=[1,17],l=[1,18],h=[1,19],f=[1,20],d=[1,21],p=[1,22],g=[8,16,17,18,19,20,21,22,23,24,25,26],y=[1,37],m=[1,33],v=[1,34],b=[1,35],_=[1,36],x=[8,10,16,17,18,19,20,21,22,23,24,25,26,28,32,37,39,40,45,57,58],w=[10,28],A=[10,28,37,57,58],E=[2,49],k=[1,45],D=[1,48],C=[1,49],M=[1,52],S=[2,65],T=[1,65],F=[1,66],B=[1,67],L=[1,68],O=[1,69],N=[1,70],I=[1,71],P=[1,72],R=[1,73],q=[8,16,17,18,19,20,21,22,23,24,25,26,47],j=[10,28,37],U={trace:function(){},yy:{},symbols_:{error:2,expressions:3,graph:4,EOF:5,graphStatement:6,idStatement:7,"{":8,stmt_list:9,"}":10,strict:11,GRAPH:12,DIGRAPH:13,textNoTags:14,textNoTagsToken:15,ALPHA:16,NUM:17,COLON:18,PLUS:19,EQUALS:20,MULT:21,DOT:22,BRKT:23,SPACE:24,MINUS:25,keywords:26,stmt:27,";":28,node_stmt:29,edge_stmt:30,attr_stmt:31,"=":32,subgraph:33,attr_list:34,NODE:35,EDGE:36,"[":37,a_list:38,"]":39,",":40,edgeRHS:41,node_id:42,edgeop:43,port:44,":":45,compass_pt:46,SUBGRAPH:47,n:48,ne:49,e:50,se:51,s:52,sw:53,w:54,nw:55,c:56,ARROW_POINT:57,ARROW_OPEN:58,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",8:"{",10:"}",11:"strict",12:"GRAPH",13:"DIGRAPH",16:"ALPHA",17:"NUM",18:"COLON",19:"PLUS",20:"EQUALS",21:"MULT",22:"DOT",23:"BRKT",24:"SPACE",25:"MINUS",26:"keywords",28:";",32:"=",35:"NODE",36:"EDGE",37:"[",39:"]",40:",",45:":",47:"SUBGRAPH",48:"n",49:"ne",50:"e",51:"se",52:"s",53:"sw",54:"w",55:"nw",56:"c",57:"ARROW_POINT",58:"ARROW_OPEN"},productions_:[0,[3,2],[4,5],[4,6],[4,4],[6,1],[6,1],[7,1],[14,1],[14,2],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[9,1],[9,3],[27,1],[27,1],[27,1],[27,3],[27,1],[31,2],[31,2],[31,2],[34,4],[34,3],[34,3],[34,2],[38,5],[38,5],[38,3],[30,3],[30,3],[30,2],[30,2],[41,3],[41,3],[41,2],[41,2],[29,2],[29,1],[42,2],[42,1],[44,4],[44,2],[44,2],[33,5],[33,4],[33,3],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,0],[43,1],[43,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:this.$=a[u-1];break;case 2:this.$=a[u-4];break;case 3:this.$=a[u-5];break;case 4:this.$=a[u-3];break;case 8:case 10:case 11:this.$=a[u];break;case 9:this.$=a[u-1]+""+a[u];break;case 12:case 13:case 14:case 15:case 16:case 18:case 19:case 20:this.$=a[u];break;case 17:this.$="
";break;case 39:this.$="oy";break;case 40:r.addLink(a[u-1],a[u].id,a[u].op),this.$="oy";break;case 42:r.addLink(a[u-1],a[u].id,a[u].op),this.$={op:a[u-2],id:a[u-1]};break;case 44:this.$={op:a[u-1],id:a[u]};break;case 48:r.addVertex(a[u-1]),this.$=a[u-1];break;case 49:r.addVertex(a[u]),this.$=a[u];break;case 66:this.$="arrow";break;case 67:this.$="arrow_open"}},table:[{3:1,4:2,6:3,11:[1,4],12:n,13:r},{1:[3]},{5:[1,7]},{7:8,8:[1,9],14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{6:23,12:n,13:r},e(g,[2,5]),e(g,[2,6]),{1:[2,1]},{8:[1,24]},{7:30,8:y,9:25,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},e([8,10,28,32,37,39,40,45,57,58],[2,7],{15:38,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p}),e(x,[2,8]),e(x,[2,10]),e(x,[2,11]),e(x,[2,12]),e(x,[2,13]),e(x,[2,14]),e(x,[2,15]),e(x,[2,16]),e(x,[2,17]),e(x,[2,18]),e(x,[2,19]),e(x,[2,20]),{7:39,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{7:30,8:y,9:40,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,41]},{10:[2,21],28:[1,42]},e(w,[2,23]),e(w,[2,24]),e(w,[2,25]),e(A,E,{44:44,32:[1,43],45:k}),e(w,[2,27],{41:46,43:47,57:D,58:C}),e(w,[2,47],{43:47,34:50,41:51,37:M,57:D,58:C}),{34:53,37:M},{34:54,37:M},{34:55,37:M},{7:56,8:[1,57],14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{7:30,8:y,9:58,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},e(x,[2,9]),{8:[1,59]},{10:[1,60]},{5:[2,4]},{7:30,8:y,9:61,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{7:62,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},e(A,[2,48]),e(A,S,{14:10,15:11,7:63,46:64,16:i,17:a, -18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,48:T,49:F,50:B,51:L,52:O,53:N,54:I,55:P,56:R}),e(w,[2,41],{34:74,37:M}),{7:77,8:y,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,33:76,42:75,47:_},e(q,[2,66]),e(q,[2,67]),e(w,[2,46]),e(w,[2,40],{34:78,37:M}),{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:79,39:[1,80]},e(w,[2,28]),e(w,[2,29]),e(w,[2,30]),{8:[1,82]},{7:30,8:y,9:83,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,84]},{7:30,8:y,9:85,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{5:[2,2]},{10:[2,22]},e(w,[2,26]),e(A,[2,51],{45:[1,86]}),e(A,[2,52]),e(A,[2,56]),e(A,[2,57]),e(A,[2,58]),e(A,[2,59]),e(A,[2,60]),e(A,[2,61]),e(A,[2,62]),e(A,[2,63]),e(A,[2,64]),e(w,[2,38]),e(j,[2,44],{43:47,41:87,57:D,58:C}),e(j,[2,45],{43:47,41:88,57:D,58:C}),e(A,E,{44:44,45:k}),e(w,[2,39]),{39:[1,89]},e(w,[2,34],{34:90,37:M}),{32:[1,91]},{7:30,8:y,9:92,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,93]},e(A,[2,55]),{10:[1,94]},e(A,S,{46:95,48:T,49:F,50:B,51:L,52:O,53:N,54:I,55:P,56:R}),e(j,[2,42]),e(j,[2,43]),e(w,[2,33],{34:96,37:M}),e(w,[2,32]),{7:97,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{10:[1,98]},e(A,[2,54]),{5:[2,3]},e(A,[2,50]),e(w,[2,31]),{28:[1,99],39:[2,37],40:[1,100]},e(A,[2,53]),{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:101},{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:102},{39:[2,35]},{39:[2,36]}],defaultActions:{7:[2,1],41:[2,4],60:[2,2],61:[2,22],94:[2,3],101:[2,35],102:[2,36]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},Y=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:return"STYLE";case 1:return"LINKSTYLE";case 2:return"CLASSDEF";case 3:return"CLASS";case 4:return"CLICK";case 5:return 12;case 6:return 13;case 7:return 47;case 8:return 35;case 9:return 36;case 10:return"DIR";case 11:return"DIR";case 12:return"DIR";case 13:return"DIR";case 14:return"DIR";case 15:return"DIR";case 16:return 17;case 17:return 23;case 18:return 18;case 19:return 28;case 20:return 40;case 21:return 32;case 22:return 21;case 23:return 22;case 24:return"ARROW_CROSS";case 25:return 57;case 26:return"ARROW_CIRCLE";case 27:return 58;case 28:return 25;case 29:return 19;case 30:return 20;case 31:return 16;case 32:return"PIPE";case 33:return"PS";case 34:return"PE";case 35:return 37;case 36:return 39;case 37:return 8;case 38:return 10;case 39:return"QUOTE";case 40:return 24;case 41:return"NEWLINE";case 42:return 5}},rules:[/^(?:style\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:digraph\b)/,/^(?:subgraph\b)/,/^(?:node\b)/,/^(?:edge\b)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9])/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:=)/,/^(?:\*)/,/^(?:\.)/,/^(?:--[x])/,/^(?:->)/,/^(?:--[o])/,/^(?:--)/,/^(?:-)/,/^(?:\+)/,/^(?:=)/,/^(?:[\u0021-\u0027\u002A-\u002E\u003F\u0041-\u005A\u0061-\u007A\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)/,/^(?:\n)/,/^(?:$)/],conditions:{INITIAL:{rules:[0,1,2,3,4,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],inclusive:!0}}};return t}();return U.lexer=Y,t.prototype=U,U.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("_process"))},{_process:3,fs:1,path:2}],119:[function(t,e,n){(function(r){"use strict";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,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],u=[2,2],o=[1,12],s=[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],b=[1,28],_=[1,38],x=[1,40],w=[1,35],A=[1,39],E=[1,45],k=[1,44],D=[1,36],C=[1,37],M=[1,41],S=[1,42],T=[1,43],F=[1,8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],B=[1,53],L=[1,52],O=[1,54],N=[1,72],I=[1,80],P=[1,81],R=[1,66],q=[1,65],j=[1,85],U=[1,84],Y=[1,82],z=[1,83],V=[1,73],$=[1,68],G=[1,67],H=[1,63],W=[1,75],Z=[1,76],X=[1,77],K=[1,78],J=[1,79],Q=[1,70],tt=[1,69],et=[8,9,11],nt=[8,9,11,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64],rt=[1,115],it=[8,9,10,11,13,15,18,36,38,40,42,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,85,87,88,90,91,93,94,95,96,97],at=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,42,43,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],ut=[1,117],ot=[1,118],st=[8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],ct=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,43,46,50,51,52,53,54,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],lt=[13,18,46,81,85,87,88,90,91,93,94,95,96,97],ht=[13,18,46,49,65,81,85,87,88,90,91,93,94,95,96,97],ft=[1,191],dt=[1,188],pt=[1,195],gt=[1,192],yt=[1,189],mt=[1,196],vt=[1,186],bt=[1,187],_t=[1,190],xt=[1,193],wt=[1,194],At=[1,211],Et=[8,9,11,85],kt=[8,9,10,11,46,71,80,81,83,85,87,88,89,90,91],Dt={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,"(-":40,"-)":41,DIAMOND_START:42,DIAMOND_STOP:43,alphaNumStatement:44,alphaNumToken:45,MINUS:46,linkStatement:47,arrowText:48,TESTSTR:49,"--":50,ARROW_POINT:51,ARROW_CIRCLE:52,ARROW_CROSS:53,ARROW_OPEN:54,"-.":55,DOTTED_ARROW_POINT:56,DOTTED_ARROW_CIRCLE:57,DOTTED_ARROW_CROSS:58,DOTTED_ARROW_OPEN:59,"==":60,THICK_ARROW_POINT:61,THICK_ARROW_CIRCLE:62,THICK_ARROW_CROSS:63,THICK_ARROW_OPEN:64,PIPE:65,textToken:66,STR:67,commentText:68,commentToken:69,keywords:70,STYLE:71,LINKSTYLE:72,CLASSDEF:73,CLASS:74,CLICK:75,textNoTags:76,textNoTagsToken:77,DEFAULT:78,stylesOpt:79,HEX:80,NUM:81,commentStatement:82,PCT:83,style:84,COMMA:85,styleComponent:86,ALPHA:87,COLON:88,UNIT:89,BRKT:90,DOT:91,graphCodeTokens:92,PUNCTUATION:93,UNICODE_TEXT:94,PLUS:95,EQUALS:96,MULT:97,TAG_START:98,TAG_END:99,QUOTE:100,$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:"(-",41:"-)",42:"DIAMOND_START",43:"DIAMOND_STOP",46:"MINUS",49:"TESTSTR",50:"--",51:"ARROW_POINT",52:"ARROW_CIRCLE",53:"ARROW_CROSS",54:"ARROW_OPEN",55:"-.",56:"DOTTED_ARROW_POINT",57:"DOTTED_ARROW_CIRCLE",58:"DOTTED_ARROW_CROSS",59:"DOTTED_ARROW_OPEN",60:"==",61:"THICK_ARROW_POINT",62:"THICK_ARROW_CIRCLE",63:"THICK_ARROW_CROSS",64:"THICK_ARROW_OPEN",65:"PIPE",67:"STR",71:"STYLE",72:"LINKSTYLE",73:"CLASSDEF",74:"CLASS",75:"CLICK",78:"DEFAULT",80:"HEX",81:"NUM",83:"PCT",85:"COMMA",87:"ALPHA",88:"COLON",89:"UNIT",90:"BRKT",91:"DOT",93:"PUNCTUATION",94:"UNICODE_TEXT",95:"PLUS",96:"EQUALS",97:"MULT",98:"TAG_START",99:"TAG_END",100:"QUOTE"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,4],[4,4],[4,4],[4,4],[4,4],[19,2],[19,1],[20,1],[20,1],[20,1],[14,1],[14,1],[14,2],[22,2],[22,2],[22,1],[22,1],[21,2],[21,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,5],[7,4],[24,1],[24,1],[24,1],[23,3],[23,1],[33,4],[33,5],[33,6],[33,7],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,1],[33,2],[35,1],[35,2],[44,1],[44,1],[44,1],[44,1],[34,2],[34,3],[34,3],[34,1],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[48,3],[31,1],[31,2],[31,1],[68,1],[68,2],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[76,1],[76,2],[27,5],[27,5],[28,5],[29,5],[29,7],[29,5],[29,7],[25,5],[25,5],[26,5],[26,5],[82,3],[79,1],[79,3],[84,1],[84,2],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[69,1],[69,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[77,1],[77,1],[77,1],[77,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 2:this.$=[];break;case 3:a[u]!==[]&&a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 57:case 59:case 60:case 92:case 94:case 95:case 108:this.$=a[u];break;case 11:r.setDirection(a[u-1]),this.$=a[u-1];break;case 12:r.setDirection("LR"),this.$=a[u-1];break;case 13:r.setDirection("RL"),this.$=a[u-1];break;case 14:r.setDirection("BT"),this.$=a[u-1];break;case 15:r.setDirection("TB"),this.$=a[u-1];break;case 30:this.$=a[u-1];break;case 31:case 32:case 33:case 34:case 35:this.$=[];break;case 36:this.$=r.addSubGraph(a[u-1],a[u-3]);break;case 37:this.$=r.addSubGraph(a[u-1],void 0);break;case 41:r.addLink(a[u-2],a[u],a[u-1]),this.$=[a[u-2],a[u]];break;case 42:this.$=[a[u]];break;case 43:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"square");break;case 44:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"square");break;case 45:this.$=a[u-5],r.addVertex(a[u-5],a[u-2],"circle");break;case 46:this.$=a[u-6],r.addVertex(a[u-6],a[u-3],"circle");break;case 47:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"ellipse");break;case 48:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"ellipse");break;case 49:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"round");break;case 50:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"round");break;case 51:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"diamond");break;case 52:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"diamond");break;case 53:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"odd");break;case 54:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"odd");break;case 55:this.$=a[u],r.addVertex(a[u]);break;case 56:this.$=a[u-1],r.addVertex(a[u-1]);break;case 58:case 93:case 96:case 109:this.$=a[u-1]+""+a[u];break;case 61:this.$="v";break;case 62:this.$="-";break;case 63:a[u-1].text=a[u],this.$=a[u-1];break;case 64:case 65:a[u-2].text=a[u-1],this.$=a[u-2];break;case 66:this.$=a[u];break;case 67:this.$={type:"arrow",stroke:"normal",text:a[u-1]};break;case 68:this.$={type:"arrow_circle",stroke:"normal",text:a[u-1]};break;case 69:this.$={type:"arrow_cross",stroke:"normal",text:a[u-1]};break;case 70:this.$={type:"arrow_open",stroke:"normal",text:a[u-1]};break;case 71:this.$={type:"arrow",stroke:"dotted",text:a[u-1]};break;case 72:this.$={type:"arrow_circle",stroke:"dotted",text:a[u-1]};break;case 73:this.$={type:"arrow_cross",stroke:"dotted",text:a[u-1]};break;case 74:this.$={type:"arrow_open",stroke:"dotted",text:a[u-1]};break;case 75:this.$={type:"arrow",stroke:"thick",text:a[u-1]};break;case 76:this.$={type:"arrow_circle",stroke:"thick",text:a[u-1]};break;case 77:this.$={type:"arrow_cross",stroke:"thick",text:a[u-1]};break;case 78:this.$={type:"arrow_open",stroke:"thick",text:a[u-1]};break;case 79:this.$={type:"arrow",stroke:"normal"};break;case 80:this.$={type:"arrow_circle",stroke:"normal"};break;case 81:this.$={type:"arrow_cross",stroke:"normal"};break;case 82:this.$={type:"arrow_open",stroke:"normal"};break;case 83:this.$={type:"arrow",stroke:"dotted"};break;case 84:this.$={type:"arrow_circle",stroke:"dotted"};break;case 85:this.$={type:"arrow_cross",stroke:"dotted"};break;case 86:this.$={type:"arrow_open",stroke:"dotted"};break;case 87:this.$={type:"arrow",stroke:"thick"};break;case 88:this.$={type:"arrow_circle",stroke:"thick"};break;case 89:this.$={type:"arrow_cross",stroke:"thick"};break;case 90:this.$={type:"arrow_open",stroke:"thick"};break;case 91:this.$=a[u-1];break;case 110:case 111:this.$=a[u-4],r.addClass(a[u-2],a[u]);break;case 112:this.$=a[u-4],r.setClass(a[u-2],a[u]);break;case 113:this.$=a[u-4],r.setClickEvent(a[u-2],a[u],void 0,void 0);break;case 114:this.$=a[u-6],r.setClickEvent(a[u-4],a[u-2],void 0,a[u]);break;case 115:this.$=a[u-4],r.setClickEvent(a[u-2],void 0,a[u],void 0);break;case 116:this.$=a[u-6],r.setClickEvent(a[u-4],void 0,a[u-2],a[u]);break;case 117:this.$=a[u-4],r.addVertex(a[u-2],void 0,void 0,a[u]);break;case 118:case 119:case 120:this.$=a[u-4],r.updateLink(a[u-2],a[u]);break;case 122:this.$=[a[u]];break;case 123:a[u-2].push(a[u]),this.$=a[u-2];break;case 125:this.$=a[u-1]+a[u]}},table:[{3:1,4:2,9:n,10:r,12:i},{1:[3]},e(a,u,{5:6}),{4:7,9:n,10:r,12:i},{4:8,9:n,10:r,12:i},{10:[1,9]},{1:[2,1],6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(a,[2,9]),e(a,[2,10]),{13:[1,46],15:[1,47],16:[1,48],17:[1,49],18:[1,50]},e(F,[2,3]),e(F,[2,4]),e(F,[2,5]),e(F,[2,6]),e(F,[2,7]),e(F,[2,8]),{8:B,9:L,11:O,24:51},{8:B,9:L,11:O,24:55},{8:B,9:L,11:O,24:56},{8:B,9:L,11:O,24:57},{8:B,9:L,11:O,24:58},{8:B,9:L,11:O,24:59},{8:B,9:L,10:N,11:O,12:I,13:P,15:R,16:q,17:j,18:U,24:61,30:Y,31:60,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(et,[2,42],{34:86,47:87,50:[1,88],51:[1,91],52:[1,92],53:[1,93],54:[1,94],55:[1,89],56:[1,95],57:[1,96],58:[1,97],59:[1,98],60:[1,90],61:[1,99],62:[1,100],63:[1,101],64:[1,102]}),{10:[1,103]},{10:[1,104]},{10:[1,105]},{10:[1,106]},{10:[1,107]},e(nt,[2,55],{45:32,21:113,44:114,10:rt,13:h,15:[1,112],18:f,36:[1,108],38:[1,109],40:[1,110],42:[1,111],46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T}),e(it,[2,57]),e(it,[2,59]),e(it,[2,60]),e(it,[2,61]),e(it,[2,62]),e(at,[2,150]),e(at,[2,151]),e(at,[2,152]),e(at,[2,153]),e(at,[2,154]),e(at,[2,155]),e(at,[2,156]),e(at,[2,157]),e(at,[2,158]),e(at,[2,159]),e(at,[2,160]),{8:ut,9:ot,10:rt,14:116,21:119},{8:ut,9:ot,10:rt,14:120,21:119},{8:ut,9:ot,10:rt,14:121,21:119},{8:ut,9:ot,10:rt,14:122,21:119},{8:ut,9:ot,10:rt,14:123,21:119},e(F,[2,30]),e(F,[2,38]),e(F,[2,39]),e(F,[2,40]),e(F,[2,31]),e(F,[2,32]),e(F,[2,33]),e(F,[2,34]),e(F,[2,35]),{8:B,9:L,10:N,11:O,12:I,13:P,15:R,16:q,17:j,18:U,24:124,30:Y,32:z,45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(st,u,{5:126}),e(ct,[2,92]),e(ct,[2,94]),e(ct,[2,139]),e(ct,[2,140]),e(ct,[2,141]),e(ct,[2,142]),e(ct,[2,143]),e(ct,[2,144]),e(ct,[2,145]),e(ct,[2,146]),e(ct,[2,147]),e(ct,[2,148]),e(ct,[2,149]),e(ct,[2,97]),e(ct,[2,98]),e(ct,[2,99]),e(ct,[2,100]),e(ct,[2,101]),e(ct,[2,102]),e(ct,[2,103]),e(ct,[2,104]),e(ct,[2,105]),e(ct,[2,106]),e(ct,[2,107]),{13:h,18:f,33:127,35:29,44:30,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(lt,[2,66],{48:128,49:[1,129],65:[1,130]}),{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:131,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:132,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:133,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(ht,[2,79]),e(ht,[2,80]),e(ht,[2,81]),e(ht,[2,82]),e(ht,[2,83]),e(ht,[2,84]),e(ht,[2,85]),e(ht,[2,86]),e(ht,[2,87]),e(ht,[2,88]),e(ht,[2,89]),e(ht,[2,90]),{13:h,18:f,35:134,44:30,45:32,46:p,80:[1,135],81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{78:[1,136],81:[1,137]},{13:h,18:f,35:139,44:30,45:32,46:p,78:[1,138],81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{13:h,18:f,35:140,44:30,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{13:h,18:f,35:141,44:30,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:142,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:144,32:z,38:[1,143],45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:145,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:146,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:147,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(nt,[2,56]),e(it,[2,58]),e(nt,[2,29],{21:148,10:rt}),e(a,[2,11]),e(a,[2,21]),e(a,[2,22]),{9:[1,149]},e(a,[2,12]),e(a,[2,13]),e(a,[2,14]),e(a,[2,15]),e(st,u,{5:150}),e(ct,[2,93]),{6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,32:[1,151],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(et,[2,41]),e(lt,[2,63],{10:[1,152]}),{10:[1,153]},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:154,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,45:71,46:V,50:$,51:[1,155],52:[1,156],53:[1,157],54:[1,158],60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,45:71,46:V,50:$,56:[1,159],57:[1,160],58:[1,161],59:[1,162],60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,45:71,46:V,50:$,60:G,61:[1,163],62:[1,164],63:[1,165],64:[1,166],66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:[1,167],13:h,18:f,44:114,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:[1,168]},{10:[1,169]},{10:[1,170]},{10:[1,171]},{10:[1,172],13:h,18:f,44:114,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:[1,173],13:h,18:f,44:114,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:[1,174],13:h,18:f,44:114,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,37:[1,175],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,31:176,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,39:[1,177],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,41:[1,178],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,43:[1,179],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,37:[1,180],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(nt,[2,28]),e(a,[2,23]),{6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,32:[1,181],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(F,[2,37]),e(lt,[2,65]),e(lt,[2,64]),{10:N,12:I,13:P,15:R,16:q,17:j,18:U, -30:Y,32:z,45:71,46:V,50:$,60:G,65:[1,182],66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(lt,[2,67]),e(lt,[2,68]),e(lt,[2,69]),e(lt,[2,70]),e(lt,[2,71]),e(lt,[2,72]),e(lt,[2,73]),e(lt,[2,74]),e(lt,[2,75]),e(lt,[2,76]),e(lt,[2,77]),e(lt,[2,78]),{10:ft,46:dt,71:pt,79:183,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:197,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:198,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:199,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:200,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:201,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{13:h,18:f,35:202,44:30,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{13:h,18:f,35:203,44:30,45:32,46:p,67:[1,204],81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(nt,[2,43],{21:205,10:rt}),{10:N,12:I,13:P,15:R,16:q,17:j,18:U,30:Y,32:z,39:[1,206],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(nt,[2,49],{21:207,10:rt}),e(nt,[2,47],{21:208,10:rt}),e(nt,[2,51],{21:209,10:rt}),e(nt,[2,53],{21:210,10:rt}),e(F,[2,36]),e([10,13,18,46,81,85,87,88,90,91,93,94,95,96,97],[2,91]),e(et,[2,117],{85:At}),e(Et,[2,122],{86:212,10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,87:vt,88:bt,89:_t,90:xt,91:wt}),e(kt,[2,124]),e(kt,[2,126]),e(kt,[2,127]),e(kt,[2,128]),e(kt,[2,129]),e(kt,[2,130]),e(kt,[2,131]),e(kt,[2,132]),e(kt,[2,133]),e(kt,[2,134]),e(kt,[2,135]),e(kt,[2,136]),e(et,[2,118],{85:At}),e(et,[2,119],{85:At}),e(et,[2,120],{85:At}),e(et,[2,110],{85:At}),e(et,[2,111],{85:At}),e(et,[2,112],{45:32,44:114,13:h,18:f,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T}),e(et,[2,113],{45:32,44:114,10:[1,213],13:h,18:f,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T}),e(et,[2,115],{10:[1,214]}),e(nt,[2,44]),{39:[1,215]},e(nt,[2,50]),e(nt,[2,48]),e(nt,[2,52]),e(nt,[2,54]),{10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,84:216,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},e(kt,[2,125]),{67:[1,217]},{67:[1,218]},e(nt,[2,45],{21:219,10:rt}),e(Et,[2,123],{86:212,10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,87:vt,88:bt,89:_t,90:xt,91:wt}),e(et,[2,114]),e(et,[2,116]),e(nt,[2,46])],defaultActions:{},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},Ct=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:this.begin("string");break;case 2:this.popState();break;case 3:return"STR";case 4:return 71;case 5:return 78;case 6:return 72;case 7:return 73;case 8:return 74;case 9:return 75;case 10:return 12;case 11:return 30;case 12:return 32;case 13:return 13;case 14:return 13;case 15:return 13;case 16:return 13;case 17:return 13;case 18:return 13;case 19:return 81;case 20:return 90;case 21:return 88;case 22:return 8;case 23:return 85;case 24:return 97;case 25:return 16;case 26:return 15;case 27:return 17;case 28:return 18;case 29:return 53;case 30:return 51;case 31:return 52;case 32:return 54;case 33:return 58;case 34:return 56;case 35:return 57;case 36:return 59;case 37:return 58;case 38:return 56;case 39:return 57;case 40:return 59;case 41:return 63;case 42:return 61;case 43:return 62;case 44:return 64;case 45:return 50;case 46:return 55;case 47:return 60;case 48:return 40;case 49:return 41;case 50:return 46;case 51:return 91;case 52:return 95;case 53:return 83;case 54:return 96;case 55:return 96;case 56:return 87;case 57:return 93;case 58:return 94;case 59:return 65;case 60:return 38;case 61:return 39;case 62:return 36;case 63:return 37;case 64:return 42;case 65:return 43;case 66:return 100;case 67:return 9;case 68:return 10;case 69:return 11}},rules:[/^(?:%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:v\b)/,/^(?:\s*--[x]\s*)/,/^(?:\s*-->\s*)/,/^(?:\s*--[o]\s*)/,/^(?:\s*---\s*)/,/^(?:\s*-\.-[x]\s*)/,/^(?:\s*-\.->\s*)/,/^(?:\s*-\.-[o]\s*)/,/^(?:\s*-\.-\s*)/,/^(?:\s*.-[x]\s*)/,/^(?:\s*\.->\s*)/,/^(?:\s*\.-[o]\s*)/,/^(?:\s*\.-\s*)/,/^(?:\s*==[x]\s*)/,/^(?:\s*==>\s*)/,/^(?:\s*==[o]\s*)/,/^(?:\s*==[\=]\s*)/,/^(?:\s*--\s*)/,/^(?:\s*-\.\s*)/,/^(?:\s*==\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[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])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:\n+)/,/^(?:\s)/,/^(?:$)/],conditions:{string:{rules:[2,3],inclusive:!1},INITIAL:{rules:[0,1,4,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,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69],inclusive:!0}}};return t}();return Dt.lexer=Ct,t.prototype=Dt,Dt.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("_process"))},{_process:3,fs:1,path:2}],120:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=t("moment"),o=new a.Log,s="",c="",l=[],h=[],f="";n.clear=function(){l=[],h=[],f="",c="",m=0,d=void 0,p=void 0,x=[]},n.setDateFormat=function(t){s=t},n.getDateFormat=function(){return s},n.setTitle=function(t){c=t},n.getTitle=function(){return c},n.addSection=function(t){f=t,l.push(t)},n.getTasks=function(){for(var t=A(),e=10,n=0;!t&&e>n;)t=A(),n++;return h=x};var d,p,g=function(t,e,r){r=r.trim();var i=/^after\s+([\d\w\-]+)/,a=i.exec(r.trim());if(null!==a){var s=n.findTaskById(a[1]);if("undefined"==typeof s){var c=new Date;return c.setHours(0,0,0,0),c}return s.endTime}return u(r,e.trim(),!0).isValid()?u(r,e.trim(),!0).toDate():(o.debug("Invalid date:"+r),o.debug("With date format:"+e.trim()),new Date)},y=function(t,e,n){if(n=n.trim(),u(n,e.trim(),!0).isValid())return u(n,e.trim()).toDate();var r=u(t),i=/^([\d]+)([wdhms])/,a=i.exec(n.trim());if(null!==a){switch(a[2]){case"s":r.add(a[1],"seconds");break;case"m":r.add(a[1],"minutes");break;case"h":r.add(a[1],"hours");break;case"d":r.add(a[1],"days");break;case"w":r.add(a[1],"weeks")}return r.toDate()}return r.toDate()},m=0,v=function(t){return"undefined"==typeof t?(m+=1,"task"+m):t},b=function(t,e){var r;r=":"===e.substr(0,1)?e.substr(1,e.length):e;for(var i=r.split(","),a={},u=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 s;for(s=0;sn-e?n+i+1.5*u.sidePadding>o?e+r-5:n+r+5:(n-e)/2+e+r}).attr("y",function(t,r){return r*e+u.barHeight/2+(u.fontSize/2-2)+n}).attr("text-height",i).attr("class",function(t){for(var e=w(t.startTime),n=w(t.endTime),r=this.getBBox().width,i=0,a=0;an-e?n+r+1.5*u.sidePadding>o?"taskTextOutsideLeft taskTextOutside"+i+" "+s:"taskTextOutsideRight taskTextOutside"+i+" "+s:"taskText taskText"+i+" "+s})}function l(t,e,n,a){var o,s=[[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["h1 %I:%M",function(t){return t.getMinutes()}]],c=[["%Y",function(){return!0}]],l=[["%I:%M",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}]];"undefined"!=typeof u.axisFormatter&&(l=[],u.axisFormatter.forEach(function(t){var e=[];e[0]=t[0],e[1]=t[1],l.push(e)})),o=s.concat(l).concat(c);var h=i.svg.axis().scale(w).orient("bottom").tickSize(-a+e+u.gridLineStartPadding,0,0).tickFormat(i.time.format.multi(o));r>7&&230>r&&(h=h.ticks(i.time.monday.range)),b.append("g").attr("class","grid").attr("transform","translate("+t+", "+(a-50)+")").call(h).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em")}function h(t,e){for(var n=[],r=0,i=0;i0))return i[1]*t/2+e;for(var u=0;a>u;u++)return r+=n[a-1][1],i[1]*t/2+r*t+e}).attr("class",function(t){for(var e=0;er;++r)e.hasOwnProperty(t[r])||(e[t[r]]=!0,n.push(t[r]));return n}function p(t){for(var e=t.length,n={};e;)n[t[--e]]=(n[t[e]]||0)+1;return n}function g(t,e){return p(e)[t]||0}n.yy.clear(),n.parse(t);var y=document.getElementById(e);o=y.parentElement.offsetWidth,"undefined"==typeof o&&(o=1200),"undefined"!=typeof u.useWidth&&(o=u.useWidth);var m=n.yy.getTasks(),v=m.length*(u.barHeight+u.barGap)+2*u.topPadding;y.setAttribute("height","100%"),y.setAttribute("viewBox","0 0 "+o+" "+v);var b=i.select("#"+e),_=i.min(m,function(t){return t.startTime}),x=i.max(m,function(t){return t.endTime}),w=i.time.scale().domain([i.min(m,function(t){return t.startTime}),i.max(m,function(t){return t.endTime})]).rangeRound([0,o-150]),A=[];r=a.duration(x-_).asDays();for(var E=0;El&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},s=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,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),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;ae[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 10;case 1:break;case 2:break;case 3:break;case 4:return 4;case 5:return 11;case 6:return"date";case 7:return 12;case 8:return 13;case 9:return 14;case 10:return 15;case 11:return":";case 12:return 6;case 13:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\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:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return t}();return o.lexer=s,t.prototype=o,o.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("_process"))},{_process:3,fs:1,path:2}],123:[function(t,e,n){(function(r){"use strict";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=[2,2],r=[1,5],i=[1,7],a=[1,8],u=[1,11],o=[1,12],s=[1,13],c=[1,14],l=[1,16],h=[1,17],f=[1,7,9,10,14,16,18,19,20,21,22,33],d=[7,9,10,14,16,18,19,20,22,33],p=[1,51],g={trace:function(){},yy:{},symbols_:{error:2,start:3,SD:4,document:5,line:6,SPACE:7,statement:8,NL:9,participant:10,actor:11,signal:12,note_statement:13,title:14,text:15,loop:16,restOfLine:17,end:18,opt:19,alt:20,"else":21,note:22,placement:23,text2:24,over:25,actor_pair:26,spaceList:27,",":28,left_of:29,right_of:30,signaltype:31,actors:32,ACTOR:33,SOLID_OPEN_ARROW:34,DOTTED_OPEN_ARROW:35,SOLID_ARROW:36,DOTTED_ARROW:37,SOLID_CROSS:38,DOTTED_CROSS:39,TXT:40,$accept:0,$end:1},terminals_:{2:"error",4:"SD",7:"SPACE",9:"NL",10:"participant",14:"title",15:"text",16:"loop",17:"restOfLine",18:"end",19:"opt",20:"alt",21:"else",22:"note",25:"over",28:",",29:"left_of",30:"right_of",33:"ACTOR",34:"SOLID_OPEN_ARROW",35:"DOTTED_OPEN_ARROW",36:"SOLID_ARROW",37:"DOTTED_ARROW",38:"SOLID_CROSS",39:"DOTTED_CROSS",40:"TXT"},productions_:[0,[3,2],[5,0],[5,2],[6,2],[6,1],[6,1],[8,3],[8,2],[8,2],[8,4],[8,4],[8,4],[8,7],[13,4],[13,4],[27,2],[27,1],[26,3],[26,1],[23,1],[23,1],[12,4],[32,2],[32,1],[11,1],[31,1],[31,1],[31,1],[31,1],[31,1],[31,1],[24,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:return r.apply(a[u]),a[u];case 2:this.$=[];break;case 3:a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 5:this.$=a[u];break;case 6:this.$=[];break;case 7:this.$=a[u-1];break;case 11:a[u-1].unshift({type:"loopStart",loopText:a[u-2],signalType:r.LINETYPE.LOOP_START}),a[u-1].push({type:"loopEnd",loopText:a[u-2],signalType:r.LINETYPE.LOOP_END}),this.$=a[u-1];break;case 12:a[u-1].unshift({type:"optStart",optText:a[u-2],signalType:r.LINETYPE.OPT_START}),a[u-1].push({type:"optEnd",optText:a[u-2],signalType:r.LINETYPE.OPT_END}),this.$=a[u-1];break;case 13:a[u-4].unshift({type:"altStart",altText:a[u-5],signalType:r.LINETYPE.ALT_START}),a[u-4].push({type:"else",altText:a[u-2],signalType:r.LINETYPE.ALT_ELSE}),a[u-4]=a[u-4].concat(a[u-1]),a[u-4].push({type:"altEnd",signalType:r.LINETYPE.ALT_END}),this.$=a[u-4];break;case 14:this.$=[a[u-1],{type:"addNote",placement:a[u-2],actor:a[u-1].actor,text:a[u]}];break;case 15:a[u-2]=[].concat(a[u-1],a[u-1]).slice(0,2),a[u-2][0]=a[u-2][0].actor,a[u-2][1]=a[u-2][1].actor,this.$=[a[u-1],{type:"addNote",placement:r.PLACEMENT.OVER,actor:a[u-2].slice(0,2),text:a[u]}];break;case 18:this.$=[a[u-2],a[u]];break;case 19:this.$=a[u];break;case 20:this.$=r.PLACEMENT.LEFTOF;break;case 21:this.$=r.PLACEMENT.RIGHTOF;break;case 22:this.$=[a[u-3],a[u-1],{type:"addMessage",from:a[u-3].actor,to:a[u-1].actor,signalType:a[u-2],msg:a[u]}];break;case 25:this.$={type:"addActor",actor:a[u]};break;case 26:this.$=r.LINETYPE.SOLID_OPEN;break;case 27:this.$=r.LINETYPE.DOTTED_OPEN;break;case 28:this.$=r.LINETYPE.SOLID;break;case 29:this.$=r.LINETYPE.DOTTED;break;case 30:this.$=r.LINETYPE.SOLID_CROSS;break;case 31:this.$=r.LINETYPE.DOTTED_CROSS;break;case 32:this.$=a[u].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e([1,7,9,10,14,16,19,20,22,33],n,{5:3}),{1:[2,1],6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,22:l,33:h},e(f,[2,3]),{8:18,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,22:l,33:h},e(f,[2,5]),e(f,[2,6]),{11:19,33:h},{9:[1,20]},{9:[1,21]},{7:[1,22]},{17:[1,23]},{17:[1,24]},{17:[1,25]},{31:26,34:[1,27],35:[1,28],36:[1,29],37:[1,30],38:[1,31],39:[1,32]},{23:33,25:[1,34],29:[1,35],30:[1,36]},e([9,28,34,35,36,37,38,39,40],[2,25]),e(f,[2,4]),{9:[1,37]},e(f,[2,8]),e(f,[2,9]),{15:[1,38]},e(d,n,{5:39}),e(d,n,{5:40}),e([7,9,10,14,16,19,20,21,22,33],n,{5:41}),{11:42,33:h},{33:[2,26]},{33:[2,27]},{33:[2,28]},{33:[2,29]},{33:[2,30]},{33:[2,31]},{11:43,33:h},{11:45,26:44,33:h},{33:[2,20]},{33:[2,21]},e(f,[2,7]),{9:[1,46]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,47],19:s,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,48],19:s,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,21:[1,49],22:l,33:h},{24:50,40:p},{24:52,40:p},{24:53,40:p},{28:[1,54],40:[2,19]},e(f,[2,10]),e(f,[2,11]),e(f,[2,12]),{17:[1,55]},{9:[2,22]},{9:[2,32]},{9:[2,14]},{9:[2,15]},{11:56,33:h},e(d,n,{5:57}),{40:[2,18]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,58],19:s,20:c,22:l,33:h},e(f,[2,13])],defaultActions:{27:[2,26],28:[2,27],29:[2,28],30:[2,29],31:[2,30],32:[2,31],35:[2,20],36:[2,21],50:[2,22],51:[2,32],52:[2,14],53:[2,15],56:[2,18]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},y=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,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),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;ae[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:break;case 2:break;case 3:break;case 4:break;case 5:return 10;case 6:return this.begin("LINE"),16;case 7:return this.begin("LINE"),19;case 8:return this.begin("LINE"),20;case 9:return this.begin("LINE"),21;case 10:return this.popState(),17;case 11:return 18;case 12:return 29;case 13:return 30;case 14:return 25;case 15:return 22;case 16:return 14;case 17:return 4;case 18:return 28;case 19:return 9;case 20:return 33;case 21:return 36;case 22:return 37;case 23:return 34;case 24:return 35;case 25:return 38;case 26:return 39;case 27:return 40;case 28:return 9;case 29:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:participant\b)/i,/^(?:loop\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\->:\n,;]+)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[2,3,10],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29],inclusive:!0}}};return t}();return g.lexer=y,t.prototype=g,g.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("_process"))},{_process:3,fs:1,path:2}],124:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u={},o=[],s=[],c=[],l=new a.Log;n.addActor=function(t,e,n){u[t]={name:e,description:n},o.push(t)},n.addMessage=function(t,e,n,r){s.push({from:t,to:e,message:n,answer:r})},n.addSignal=function(t,e,n,r){l.debug("Adding message from="+t+" to="+e+" message="+n+" type="+r),s.push({from:t,to:e,message:n,type:r})},n.getMessages=function(){return s},n.getActors=function(){return u},n.getActor=function(t){return u[t]},n.getActorKeys=function(){return Object.keys(u)},n.clear=function(){u={},s=[]},n.LINETYPE={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},n.ARROWTYPE={FILLED:0,OPEN:1},n.PLACEMENT={LEFTOF:0,RIGHTOF:1,OVER:2},n.addNote=function(t,e,r){var i={actor:t,placement:e,message:r},a=[].concat(t,t);c.push(i),s.push({from:a[0],to:a[1],message:r,type:n.LINETYPE.NOTE,placement:e})},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)},n.apply=function(t){if(t instanceof Array)t.forEach(function(t){n.apply(t)});else switch(t.type){case"addActor":n.addActor(t.actor,t.actor,t.actor);break;case"addNote":n.addNote(t.actor,t.placement,t.text);break;case"addMessage":n.addSignal(t.from,t.to,t.msg,t.signalType);break;case"loopStart":n.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"optStart":n.addSignal(void 0,void 0,t.optText,t.signalType);break;case"optEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"altStart":n.addSignal(void 0,void 0,t.altText,t.signalType);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)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":127}],125:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=t("./parser/sequenceDiagram").parser;u.yy=t("./sequenceDb");var o=t("./svgDraw"),s=t("../../d3"),c=new a.Log,l={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,u=0;this.list.forEach(function(o){u++;var s=a.list.length-u+1;a.updateVal(o,"startx",t-s*l.boxMargin,Math.min),a.updateVal(o,"starty",e-s*l.boxMargin,Math.min),a.updateVal(o,"stopx",r+s*l.boxMargin,Math.max),a.updateVal(o,"stopy",i+s*l.boxMargin,Math.max),a.updateVal(n.bounds.data,"startx",t-s*l.boxMargin,Math.min),a.updateVal(n.bounds.data,"starty",e-s*l.boxMargin,Math.min),a.updateVal(n.bounds.data,"stopx",r+s*l.boxMargin,Math.max),a.updateVal(n.bounds.data,"stopy",i+s*l.boxMargin,Math.max)})},insert:function(t,e,r,i){var a,u,o,s;a=Math.min(t,r),o=Math.max(t,r),u=Math.min(e,i),s=Math.max(e,i),this.updateVal(n.bounds.data,"startx",a,Math.min),this.updateVal(n.bounds.data,"starty",u,Math.min),this.updateVal(n.bounds.data,"stopx",o,Math.max),this.updateVal(n.bounds.data,"stopy",s,Math.max),this.updateLoops(a,u,o,s)},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 h=function(t,e,r,i,a){var u=o.getNoteRect();u.x=e,u.y=r,u.width=a||l.width,u["class"]="note";var s=t.append("g"),c=o.drawRect(s,u),h=o.getTextObj();h.x=e-4,h.y=r-13,h.textMargin=l.noteMargin,h.dy="1em",h.text=i.message,h["class"]="noteText";var f=o.drawText(s,h,u.width-l.noteMargin),d=f[0][0].getBBox().height;!a&&d>l.width?(f.remove(),s=t.append("g"),f=o.drawText(s,h,2*u.width-l.noteMargin),d=f[0][0].getBBox().height,c.attr("width",2*u.width),n.bounds.insert(e,r,e+2*u.width,r+2*l.noteMargin+d)):n.bounds.insert(e,r,e+u.width,r+2*l.noteMargin+d),c.attr("height",d+2*l.noteMargin),n.bounds.bumpVerticalPos(d+2*l.noteMargin)},f=function(t,e,r,i,a){var o,s=t.append("g"),c=e+(r-e)/2,l=s.append("text").attr("x",c).attr("y",i-7).style("text-anchor","middle").attr("class","messageText").text(a.message);o="undefined"!=typeof l[0][0].getBBox?l[0][0].getBBox().width:l[0][0].getBoundingClientRect();var h;if(e===r){h=s.append("path").attr("d","M "+e+","+i+" C "+(e+60)+","+(i-10)+" "+(e+60)+","+(i+30)+" "+e+","+(i+20)),n.bounds.bumpVerticalPos(30);var f=Math.max(o/2,100);n.bounds.insert(e-f,n.bounds.getVerticalPos()-10,r+f,n.bounds.getVerticalPos())}else h=s.append("line"),h.attr("x1",e),h.attr("y1",i),h.attr("x2",r),h.attr("y2",i),n.bounds.insert(e,n.bounds.getVerticalPos()-10,r,n.bounds.getVerticalPos());a.type===u.yy.LINETYPE.DOTTED||a.type===u.yy.LINETYPE.DOTTED_CROSS||a.type===u.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0");var d=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;d=d.replace(/\(/g,"\\("),d=d.replace(/\)/g,"\\)"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(a.type===u.yy.LINETYPE.SOLID||a.type===u.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+d+"#arrowhead)"),(a.type===u.yy.LINETYPE.SOLID_CROSS||a.type===u.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+d+"#crosshead)")};e.exports.drawActors=function(t,e,r,i){var a;for(a=0;a/gi," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.attr("fill",e.fill),"undefined"!=typeof e["class"]&&i.attr("class",e["class"]);var a=i.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(r),"undefined"!=typeof i.textwrap&&i.textwrap({x:e.x,y:e.y,width:n,height:1800},e.textMargin),i},n.drawLabel=function(t,e){var r=n.getNoteRect();r.x=e.x,r.y=e.y,r.width=50,r.height=20,r.fill="#526e52",r.stroke="none",r["class"]="labelBox",n.drawRect(t,r),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,e.fill="white",n.drawText(t,e)};var r=-1;n.drawActor=function(t,e,i,a,u){var o=e+u.width/2,s=t.append("g");0===i&&(r++,s.append("line").attr("id","actor"+r).attr("x1",o).attr("y1",5).attr("x2",o).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var c=n.getNoteRect();c.x=e,c.y=i,c.fill="#eaeaea",c.width=u.width,c.height=u.height,c["class"]="actor",c.rx=3,c.ry=3,n.drawRect(s,c),s.append("text").attr("x",o).attr("y",i+u.height/2+5).attr("class","actor").style("text-anchor","middle").text(a)},n.drawLoop=function(t,e,r,i){var a=t.append("g"),u=function(t,e,n,r){a.append("line").attr("x1",t).attr("y1",e).attr("x2",n).attr("y2",r).attr("stroke-width",2).attr("stroke","#526e52").attr("class","loopLine")};u(e.startx,e.starty,e.stopx,e.starty),u(e.stopx,e.starty,e.stopx,e.stopy),u(e.startx,e.stopy,e.stopx,e.stopy),u(e.startx,e.starty,e.startx,e.stopy),"undefined"!=typeof e.elsey&&u(e.startx,e.elsey,e.stopx,e.elsey);var o=n.getTextObj();o.text=r,o.x=e.startx,o.y=e.starty,o.labelMargin=1.5*i.boxMargin,o["class"]="labelText",o.fill="white",n.drawLabel(a,o),o=n.getTextObj(),o.text="[ "+e.title+" ]",o.x=e.startx+(e.stopx-e.startx)/2,o.y=e.starty+1.5*i.boxMargin,o.anchor="middle",o["class"]="loopText",n.drawText(a,o),"undefined"!=typeof e.elseText&&(o.text="[ "+e.elseText+" ]",o.y=e.elsey+1.5*i.boxMargin,n.drawText(a,o))},n.insertArrowHead=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")},n.insertArrowCrossHead=function(t){var e=t.append("defs"),n=e.append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);n.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"),n.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")},n.getTextObj=function(){var t={x:0,y:0,fill:"black","text-anchor":"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0};return t},n.getNoteRect=function(){var t={x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0};return t}},{}],127:[function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t){var e=t.getUTCHours(),n=t.getUTCMinutes(),r=t.getSeconds(),i=t.getMilliseconds();10>e&&(e="0"+e),10>n&&(n="0"+n),10>r&&(r="0"+r),100>i&&(i="0"+i),10>i&&(i="00"+i);var a=e+":"+n+":"+r+" ("+i+")";return a}var a=function(){function t(t,e){for(var n=0;n=n&&"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log("["+i(new Date)+"] "+t):void 0}},{key:"trace",value:function(t){this.log(t,u.trace)}},{key:"debug",value:function(t){this.log(t,u.debug)}},{key:"info",value:function(t){this.log(t,u.info)}},{key:"warn",value:function(t){this.log(t,u.warn)}},{key:"error",value:function(t){this.log(t,u.error)}}]),t}();n.Log=s},{}],128:[function(t,e,n){(function(r){"use strict";function i(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var a=t("./logger"),u=i(a),o=new u.Log,s=t("./mermaidAPI"),c=0,l=t("he");e.exports.mermaidAPI=s;var h=function(){var t=s.getConfig();o.debug("Starting rendering diagrams");var e;arguments.length>=2?("undefined"!=typeof arguments[0]&&(r.mermaid.sequenceConfig=arguments[0]),e=arguments[1]):e=arguments[0];var n;"function"==typeof arguments[arguments.length-1]?(n=arguments[arguments.length-1],o.debug("Callback function found")):"undefined"!=typeof t.mermaid&&("function"==typeof t.mermaid.callback?(n=t.mermaid.callback,o.debug("Callback function found")):o.debug("No Callback function found")),e=void 0===e?document.querySelectorAll(".mermaid"):"string"==typeof e?document.querySelectorAll(e):e instanceof Node?[e]:e;var i;"undefined"!=typeof mermaid_config&&s.initialize(r.mermaid_config),o.debug("Start On Load before: "+r.mermaid.startOnLoad),"undefined"!=typeof r.mermaid.startOnLoad&&(o.debug("Start On Load inner: "+r.mermaid.startOnLoad),s.initialize({startOnLoad:r.mermaid.startOnLoad})),"undefined"!=typeof r.mermaid.ganttConfig&&s.initialize({gantt:r.mermaid.ganttConfig});var a,u=function(t,e){h.innerHTML=t,"undefined"!=typeof n&&n(f),e(h)};for(i=0;i0&&(r+=n.selectorText+" { "+n.style.cssText+" }\n")}}catch(l){"undefined"!=typeof n&&u.warn('Invalid CSS selector "'+n.selectorText+'"',l)}var h="",f="";for(var d in e)e.hasOwnProperty(d)&&"undefined"!=typeof d&&("default"===d?(e["default"].styles instanceof Array&&(h+="#"+t.id.trim()+" .node>rect { "+e[d].styles.join("; ")+"; }\n"),e["default"].nodeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .node text { "+e[d].nodeLabelStyles.join("; ")+"; }\n"),e["default"].edgeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .edgeLabel text { "+e[d].edgeLabelStyles.join("; ")+"; }\n"),e["default"].clusterStyles instanceof Array&&(h+="#"+t.id.trim()+" .cluster rect { "+e[d].clusterStyles.join("; ")+"; }\n")):e[d].styles instanceof Array&&(f+="#"+t.id.trim()+" ."+d+">rect { "+e[d].styles.join("; ")+"; }\n"));if(""!==r||""!==h||""!==f){var p=document.createElement("style");p.setAttribute("type","text/css"),p.setAttribute("title","mermaid-svg-internal-css"),p.innerHTML="/* */\n",t.insertBefore(p,t.firstChild)}};n.cloneCssStyles=s},{"./logger":127}]},{},[128])(128)}); \ No newline at end of file +var n="";return t>=55296&&57343>=t||t>1114111?(e&&S("character reference outside the permissible Unicode range"),"�"):E(b,t)?(e&&S("disallowed character reference"),b[t]):(e&&k(_,t)&&S("disallowed character reference"),t>65535&&(t-=65536,n+=x(t>>>10&1023|55296),t=56320|1023&t),n+=x(t))},M=function(t){return"&#x"+t.charCodeAt(0).toString(16).toUpperCase()+";"},S=function(t){throw Error("Parse error: "+t)},T=function(t,e){e=D(e,T.options);var n=e.strict;n&&g.test(t)&&S("forbidden code point");var r=e.encodeEverything,i=e.useNamedReferences,a=e.allowUnsafeSymbols;return r?(t=t.replace(s,function(t){return i&&E(h,t)?"&"+h[t]+";":M(t)}),i&&(t=t.replace(/>\u20D2/g,">⃒").replace(/<\u20D2/g,"<⃒").replace(/fj/g,"fj")),i&&(t=t.replace(l,function(t){return"&"+h[t]+";"}))):i?(a||(t=t.replace(f,function(t){return"&"+h[t]+";"})),t=t.replace(/>\u20D2/g,">⃒").replace(/<\u20D2/g,"<⃒"),t=t.replace(l,function(t){return"&"+h[t]+";"})):a||(t=t.replace(f,M)),t.replace(o,function(t){var e=t.charCodeAt(0),n=t.charCodeAt(1),r=1024*(e-55296)+n-56320+65536;return"&#x"+r.toString(16).toUpperCase()+";"}).replace(c,M)};T.options={allowUnsafeSymbols:!1,encodeEverything:!1,strict:!1,useNamedReferences:!1};var F=function(t,e){e=D(e,F.options);var n=e.strict;return n&&p.test(t)&&S("malformed character reference"),t.replace(y,function(t,r,i,a,u,o,s,c){var l,h,f,d,p;return r?(l=r,h=i,n&&!h&&S("character reference was not terminated by a semicolon"),C(l,n)):a?(f=a,h=u,n&&!h&&S("character reference was not terminated by a semicolon"),l=parseInt(f,16),C(l,n)):o?(d=o,E(m,d)?m[d]:(n&&S("named character reference was not terminated by a semicolon"),t)):(d=s,p=c,p&&e.isAttributeValue?(n&&"="==p&&S("`&` did not start a character reference"),t):(n&&S("named character reference was not terminated by a semicolon"),v[d]+(p||"")))})};F.options={isAttributeValue:!1,strict:!1};var B=function(t){return t.replace(f,function(t){return d[t]})},L={version:"0.5.0",encode:T,decode:F,escape:B,unescape:F};if("function"==typeof define&&"object"==typeof define.amd&&define.amd)define(function(){return L});else if(i&&!i.nodeType)if(a)a.exports=L;else for(var N in L)E(L,N)&&(i[N]=L[N]);else r.he=L}(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],106:[function(t,e,n){!function(t,r){"object"==typeof n&&"undefined"!=typeof e?e.exports=r():"function"==typeof define&&define.amd?define(r):t.moment=r()}(this,function(){"use strict";function n(){return In.apply(null,arguments)}function r(t){In=t}function i(t){return"[object Array]"===Object.prototype.toString.call(t)}function a(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function u(t,e){var n,r=[];for(n=0;n0)for(n in Pn)r=Pn[n],i=e[r],"undefined"!=typeof i&&(t[r]=i);return t}function g(t){p(this,t),this._d=new Date(null!=t._d?t._d.getTime():0/0),qn===!1&&(qn=!0,n.updateOffset(this),qn=!1)}function y(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function m(t){return 0>t?Math.ceil(t):Math.floor(t)}function v(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=m(e)),n}function b(t,e,n){var r,i=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),u=0;for(r=0;i>r;r++)(n&&t[r]!==e[r]||!n&&v(t[r])!==v(e[r]))&&u++;return u+a}function _(){}function x(t){return t?t.toLowerCase().replace("_","-"):t}function w(t){for(var e,n,r,i,a=0;a0;){if(r=A(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&b(i,n,!0)>=e-1)break;e--}a++}return null}function A(n){var r=null;if(!jn[n]&&"undefined"!=typeof e&&e&&e.exports)try{r=Rn._abbr,t("./locale/"+n),E(r)}catch(i){}return jn[n]}function E(t,e){var n;return t&&(n="undefined"==typeof e?D(t):k(t,e),n&&(Rn=n)),Rn._abbr}function k(t,e){return null!==e?(e.abbr=t,jn[t]=jn[t]||new _,jn[t].set(e),E(t),jn[t]):(delete jn[t],null)}function D(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Rn;if(!i(t)){if(e=A(t))return e;t=[t]}return w(t)}function C(t,e){var n=t.toLowerCase();Un[n]=Un[n+"s"]=Un[e]=t}function M(t){return"string"==typeof t?Un[t]||Un[t.toLowerCase()]:void 0}function S(t){var e,n,r={};for(n in t)o(t,n)&&(e=M(n),e&&(r[e]=t[n]));return r}function T(t,e){return function(r){return null!=r?(B(this,t,r),n.updateOffset(this,e),this):F(this,t)}}function F(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function B(t,e,n){return t._d["set"+(t._isUTC?"UTC":"")+e](n)}function L(t,e){var n;if("object"==typeof t)for(n in t)this.set(n,t[n]);else if(t=M(t),"function"==typeof this[t])return this[t](e);return this}function N(t,e,n){var r=""+Math.abs(t),i=e-r.length,a=t>=0;return(a?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}function O(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&($n[t]=i),e&&($n[e[0]]=function(){return N(i.apply(this,arguments),e[1],e[2])}),n&&($n[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function I(t){return t.match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"")}function R(t){var e,n,r=t.match(Yn);for(e=0,n=r.length;n>e;e++)r[e]=$n[r[e]]?$n[r[e]]:I(r[e]);return function(i){var a="";for(e=0;n>e;e++)a+=r[e]instanceof Function?r[e].call(i,t):r[e];return a}}function P(t,e){return t.isValid()?(e=q(e,t.localeData()),Vn[e]=Vn[e]||R(e),Vn[e](t)):t.localeData().invalidDate()}function q(t,e){function n(t){return e.longDateFormat(t)||t}var r=5;for(zn.lastIndex=0;r>=0&&zn.test(t);)t=t.replace(zn,n),zn.lastIndex=0,r-=1;return t}function j(t){return"function"==typeof t&&"[object Function]"===Object.prototype.toString.call(t)}function U(t,e,n){ur[t]=j(e)?e:function(t){return t&&n?n:e}}function Y(t,e){return o(ur,t)?ur[t](e._strict,e._locale):new RegExp(z(t))}function z(t){return t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,n,r,i){return e||n||r||i}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function V(t,e){var n,r=e;for("string"==typeof t&&(t=[t]),"number"==typeof e&&(r=function(t,n){n[e]=v(t)}),n=0;nr;r++){if(i=c([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(a="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(a.replace(".",""),"i")),n&&"MMMM"===e&&this._longMonthsParse[r].test(t))return r;if(n&&"MMM"===e&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}}function J(t,e){var n;return"string"==typeof e&&(e=t.localeData().monthsParse(e),"number"!=typeof e)?t:(n=Math.min(t.date(),H(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n),t)}function K(t){return null!=t?(J(this,t),n.updateOffset(this,!0),this):F(this,"Month")}function Q(){return H(this.year(),this.month())}function tt(t){var e,n=t._a;return n&&-2===h(t).overflow&&(e=n[cr]<0||n[cr]>11?cr:n[lr]<1||n[lr]>H(n[sr],n[cr])?lr:n[hr]<0||n[hr]>24||24===n[hr]&&(0!==n[fr]||0!==n[dr]||0!==n[pr])?hr:n[fr]<0||n[fr]>59?fr:n[dr]<0||n[dr]>59?dr:n[pr]<0||n[pr]>999?pr:-1,h(t)._overflowDayOfYear&&(sr>e||e>lr)&&(e=lr),h(t).overflow=e),t}function et(t){n.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function nt(t,e){var n=!0;return s(function(){return n&&(et(t+"\n"+(new Error).stack),n=!1),e.apply(this,arguments)},e)}function rt(t,e){mr[t]||(et(e),mr[t]=!0)}function it(t){var e,n,r=t._i,i=vr.exec(r);if(i){for(h(t).iso=!0,e=0,n=br.length;n>e;e++)if(br[e][1].exec(r)){t._f=br[e][0];break}for(e=0,n=_r.length;n>e;e++)if(_r[e][1].exec(r)){t._f+=(i[6]||" ")+_r[e][0];break}r.match(rr)&&(t._f+="Z"),At(t)}else t._isValid=!1}function at(t){var e=xr.exec(t._i);return null!==e?void(t._d=new Date(+e[1])):(it(t),void(t._isValid===!1&&(delete t._isValid,n.createFromInputFallback(t))))}function ut(t,e,n,r,i,a,u){var o=new Date(t,e,n,r,i,a,u);return 1970>t&&o.setFullYear(t),o}function ot(t){var e=new Date(Date.UTC.apply(null,arguments));return 1970>t&&e.setUTCFullYear(t),e}function st(t){return ct(t)?366:365}function ct(t){return t%4===0&&t%100!==0||t%400===0}function lt(){return ct(this.year())}function ht(t,e,n){var r,i=n-e,a=n-t.day();return a>i&&(a-=7),i-7>a&&(a+=7),r=Ft(t).add(a,"d"),{week:Math.ceil(r.dayOfYear()/7),year:r.year()}}function ft(t){return ht(t,this._week.dow,this._week.doy).week}function dt(){return this._week.dow}function pt(){return this._week.doy}function gt(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")}function yt(t){var e=ht(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")}function mt(t,e,n,r,i){var a,u=6+i-r,o=ot(t,0,1+u),s=o.getUTCDay();return i>s&&(s+=7),n=null!=n?1*n:i,a=1+u+7*(e-1)-s+n,{year:a>0?t:t-1,dayOfYear:a>0?a:st(t-1)+a}}function vt(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")}function bt(t,e,n){return null!=t?t:null!=e?e:n}function _t(t){var e=new Date;return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function xt(t){var e,n,r,i,a=[];if(!t._d){for(r=_t(t),t._w&&null==t._a[lr]&&null==t._a[cr]&&wt(t),t._dayOfYear&&(i=bt(t._a[sr],r[sr]),t._dayOfYear>st(i)&&(h(t)._overflowDayOfYear=!0),n=ot(i,0,t._dayOfYear),t._a[cr]=n.getUTCMonth(),t._a[lr]=n.getUTCDate()),e=0;3>e&&null==t._a[e];++e)t._a[e]=a[e]=r[e];for(;7>e;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[hr]&&0===t._a[fr]&&0===t._a[dr]&&0===t._a[pr]&&(t._nextDay=!0,t._a[hr]=0),t._d=(t._useUTC?ot:ut).apply(null,a),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[hr]=24)}}function wt(t){var e,n,r,i,a,u,o;e=t._w,null!=e.GG||null!=e.W||null!=e.E?(a=1,u=4,n=bt(e.GG,t._a[sr],ht(Ft(),1,4).year),r=bt(e.W,1),i=bt(e.E,1)):(a=t._locale._week.dow,u=t._locale._week.doy,n=bt(e.gg,t._a[sr],ht(Ft(),a,u).year),r=bt(e.w,1),null!=e.d?(i=e.d,a>i&&++r):i=null!=e.e?e.e+a:a),o=mt(n,r,i,u,a),t._a[sr]=o.year,t._dayOfYear=o.dayOfYear}function At(t){if(t._f===n.ISO_8601)return void it(t);t._a=[],h(t).empty=!0;var e,r,i,a,u,o=""+t._i,s=o.length,c=0;for(i=q(t._f,t._locale).match(Yn)||[],e=0;e0&&h(t).unusedInput.push(u),o=o.slice(o.indexOf(r)+r.length),c+=r.length),$n[a]?(r?h(t).empty=!1:h(t).unusedTokens.push(a),G(a,r,t)):t._strict&&!r&&h(t).unusedTokens.push(a);h(t).charsLeftOver=s-c,o.length>0&&h(t).unusedInput.push(o),h(t).bigHour===!0&&t._a[hr]<=12&&t._a[hr]>0&&(h(t).bigHour=void 0),t._a[hr]=Et(t._locale,t._a[hr],t._meridiem),xt(t),tt(t)}function Et(t,e,n){var r;return null==n?e:null!=t.meridiemHour?t.meridiemHour(e,n):null!=t.isPM?(r=t.isPM(n),r&&12>e&&(e+=12),r||12!==e||(e=0),e):e}function kt(t){var e,n,r,i,a;if(0===t._f.length)return h(t).invalidFormat=!0,void(t._d=new Date(0/0));for(i=0;ia)&&(r=a,n=e));s(t,n||e)}function Dt(t){if(!t._d){var e=S(t._i);t._a=[e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],xt(t)}}function Ct(t){var e=new g(tt(Mt(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=void 0),e}function Mt(t){var e=t._i,n=t._f;return t._locale=t._locale||D(t._l),null===e||void 0===n&&""===e?d({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),y(e)?new g(tt(e)):(i(n)?kt(t):n?At(t):a(e)?t._d=e:St(t),t))}function St(t){var e=t._i;void 0===e?t._d=new Date:a(e)?t._d=new Date(+e):"string"==typeof e?at(t):i(e)?(t._a=u(e.slice(0),function(t){return parseInt(t,10)}),xt(t)):"object"==typeof e?Dt(t):"number"==typeof e?t._d=new Date(e):n.createFromInputFallback(t)}function Tt(t,e,n,r,i){var a={};return"boolean"==typeof n&&(r=n,n=void 0),a._isAMomentObject=!0,a._useUTC=a._isUTC=i,a._l=n,a._i=t,a._f=e,a._strict=r,Ct(a)}function Ft(t,e,n,r){return Tt(t,e,n,r,!1)}function Bt(t,e){var n,r;if(1===e.length&&i(e[0])&&(e=e[0]),!e.length)return Ft();for(n=e[0],r=1;rt&&(t=-t,n="-"),n+N(~~(t/60),2)+e+N(~~t%60,2)})}function Pt(t){var e=(t||"").match(rr)||[],n=e[e.length-1]||[],r=(n+"").match(Dr)||["-",0,0],i=+(60*r[1])+v(r[2]);return"+"===r[0]?i:-i}function qt(t,e){var r,i;return e._isUTC?(r=e.clone(),i=(y(t)||a(t)?+t:+Ft(t))-+r,r._d.setTime(+r._d+i),n.updateOffset(r,!1),r):Ft(t).local()}function jt(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function Ut(t,e){var r,i=this._offset||0;return null!=t?("string"==typeof t&&(t=Pt(t)),Math.abs(t)<16&&(t=60*t),!this._isUTC&&e&&(r=jt(this)),this._offset=t,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==t&&(!e||this._changeInProgress?re(this,Kt(t-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?i:jt(this)}function Yt(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function zt(t){return this.utcOffset(0,t)}function Vt(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(jt(this),"m")),this}function $t(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(Pt(this._i)),this}function Gt(t){return t=t?Ft(t).utcOffset():0,(this.utcOffset()-t)%60===0}function Ht(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Wt(){if("undefined"!=typeof this._isDSTShifted)return this._isDSTShifted;var t={};if(p(t,this),t=Mt(t),t._a){var e=t._isUTC?c(t._a):Ft(t._a);this._isDSTShifted=this.isValid()&&b(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Zt(){return!this._isUTC}function Xt(){return this._isUTC}function Jt(){return this._isUTC&&0===this._offset}function Kt(t,e){var n,r,i,a=t,u=null;return It(t)?a={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(a={},e?a[e]=t:a.milliseconds=t):(u=Cr.exec(t))?(n="-"===u[1]?-1:1,a={y:0,d:v(u[lr])*n,h:v(u[hr])*n,m:v(u[fr])*n,s:v(u[dr])*n,ms:v(u[pr])*n}):(u=Mr.exec(t))?(n="-"===u[1]?-1:1,a={y:Qt(u[2],n),M:Qt(u[3],n),d:Qt(u[4],n),h:Qt(u[5],n),m:Qt(u[6],n),s:Qt(u[7],n),w:Qt(u[8],n)}):null==a?a={}:"object"==typeof a&&("from"in a||"to"in a)&&(i=ee(Ft(a.from),Ft(a.to)),a={},a.ms=i.milliseconds,a.M=i.months),r=new Ot(a),It(t)&&o(t,"_locale")&&(r._locale=t._locale),r}function Qt(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function te(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 ee(t,e){var n;return e=qt(e,t),t.isBefore(e)?n=te(t,e):(n=te(e,t),n.milliseconds=-n.milliseconds,n.months=-n.months),n}function ne(t,e){return function(n,r){var i,a;return null===r||isNaN(+r)||(rt(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=Kt(n,r),re(this,i,t),this}}function re(t,e,r,i){var a=e._milliseconds,u=e._days,o=e._months;i=null==i?!0:i,a&&t._d.setTime(+t._d+a*r),u&&B(t,"Date",F(t,"Date")+u*r),o&&J(t,F(t,"Month")+o*r),i&&n.updateOffset(t,u||o)}function ie(t,e){var n=t||Ft(),r=qt(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,Ft(n)))}function ae(){return new g(this)}function ue(t,e){var n;return e=M("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Ft(t),+this>+t):(n=y(t)?+t:+Ft(t),n<+this.clone().startOf(e))}function oe(t,e){var n;return e=M("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Ft(t),+t>+this):(n=y(t)?+t:+Ft(t),+this.clone().endOf(e)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 fe(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function de(){var t=this.clone().utc();return 0e;e++)if(this._weekdaysParse[e]||(n=Ft([2e3,1]).day(e),r="^"+this.weekdays(n,"")+"|^"+this.weekdaysShort(n,"")+"|^"+this.weekdaysMin(n,""),this._weekdaysParse[e]=new RegExp(r.replace(".",""),"i")),this._weekdaysParse[e].test(t))return e}function ze(t){var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=Pe(t,this.localeData()),this.add(t-e,"d")):e}function Ve(t){var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")}function $e(t){return null==t?this.day()||7:this.day(this.day()%7?t:t-7)}function Ge(t,e){O(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}function He(t,e){return e._meridiemParse}function We(t){return"p"===(t+"").toLowerCase().charAt(0)}function Ze(t,e,n){return t>11?n?"pm":"PM":n?"am":"AM"}function Xe(t,e){e[pr]=v(1e3*("0."+t))}function Je(){return this._isUTC?"UTC":""}function Ke(){return this._isUTC?"Coordinated Universal Time":""}function Qe(t){return Ft(1e3*t)}function tn(){return Ft.apply(null,arguments).parseZone()}function en(t,e,n){var r=this._calendar[t];return"function"==typeof r?r.call(e,n):r}function nn(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.replace(/MMMM|MM|DD|dddd/g,function(t){return t.slice(1)}),this._longDateFormat[t])}function rn(){return this._invalidDate}function an(t){return this._ordinal.replace("%d",t)}function un(t){return t}function on(t,e,n,r){var i=this._relativeTime[n];return"function"==typeof i?i(t,e,n,r):i.replace(/%d/i,t)}function sn(t,e){var n=this._relativeTime[t>0?"future":"past"];return"function"==typeof n?n(e):n.replace(/%s/i,e)}function cn(t){var e,n;for(n in t)e=t[n],"function"==typeof e?this[n]=e:this["_"+n]=e;this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function ln(t,e,n,r){var i=D(),a=c().set(r,e);return i[n](a,t)}function hn(t,e,n,r,i){if("number"==typeof t&&(e=t,t=void 0),t=t||"",null!=e)return ln(t,e,n,i);var a,u=[];for(a=0;r>a;a++)u[a]=ln(t,a,n,i);return u}function fn(t,e){return hn(t,e,"months",12,"month")}function dn(t,e){return hn(t,e,"monthsShort",12,"month")}function pn(t,e){return hn(t,e,"weekdays",7,"day")}function gn(t,e){return hn(t,e,"weekdaysShort",7,"day")}function yn(t,e){return hn(t,e,"weekdaysMin",7,"day")}function mn(){var t=this._data;return this._milliseconds=Jr(this._milliseconds),this._days=Jr(this._days),this._months=Jr(this._months),t.milliseconds=Jr(t.milliseconds),t.seconds=Jr(t.seconds),t.minutes=Jr(t.minutes),t.hours=Jr(t.hours),t.months=Jr(t.months),t.years=Jr(t.years),this}function vn(t,e,n,r){var i=Kt(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function bn(t,e){return vn(this,t,e,1)}function _n(t,e){return vn(this,t,e,-1)}function xn(t){return 0>t?Math.floor(t):Math.ceil(t)}function wn(){var t,e,n,r,i,a=this._milliseconds,u=this._days,o=this._months,s=this._data;return a>=0&&u>=0&&o>=0||0>=a&&0>=u&&0>=o||(a+=864e5*xn(En(o)+u),u=0,o=0),s.milliseconds=a%1e3,t=m(a/1e3),s.seconds=t%60,e=m(t/60),s.minutes=e%60,n=m(e/60),s.hours=n%24,u+=m(n/24),i=m(An(u)),o+=i,u-=xn(En(i)),r=m(o/12),o%=12,s.days=u,s.months=o,s.years=r,this}function An(t){return 4800*t/146097}function En(t){return 146097*t/4800}function kn(t){var e,n,r=this._milliseconds;if(t=M(t),"month"===t||"year"===t)return e=this._days+r/864e5,n=this._months+An(e),"month"===t?n:n/12;switch(e=this._days+Math.round(En(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return 24*e+r/36e5;case"minute":return 1440*e+r/6e4;case"second":return 86400*e+r/1e3;case"millisecond":return Math.floor(864e5*e)+r;default:throw new Error("Unknown unit "+t)}}function Dn(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function Cn(t){return function(){return this.as(t)}}function Mn(t){return t=M(t),this[t+"s"]()}function Sn(t){return function(){return this._data[t]}}function Tn(){return m(this.days()/7)}function Fn(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}function Bn(t,e,n){var r=Kt(t).abs(),i=di(r.as("s")),a=di(r.as("m")),u=di(r.as("h")),o=di(r.as("d")),s=di(r.as("M")),c=di(r.as("y")),l=i0,l[4]=n,Fn.apply(null,l)}function Ln(t,e){return void 0===pi[t]?!1:void 0===e?pi[t]:(pi[t]=e,!0)}function Nn(t){var e=this.localeData(),n=Bn(this,!t,e);return t&&(n=e.pastFuture(+this,n)),e.postformat(n)}function On(){var t,e,n,r=gi(this._milliseconds)/1e3,i=gi(this._days),a=gi(this._months);t=m(r/60),e=m(t/60),r%=60,t%=60,n=m(a/12),a%=12;var u=n,o=a,s=i,c=e,l=t,h=r,f=this.asSeconds();return f?(0>f?"-":"")+"P"+(u?u+"Y":"")+(o?o+"M":"")+(s?s+"D":"")+(c||l||h?"T":"")+(c?c+"H":"")+(l?l+"M":"")+(h?h+"S":""):"P0D"}var In,Rn,Pn=n.momentProperties=[],qn=!1,jn={},Un={},Yn=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,zn=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Vn={},$n={},Gn=/\d/,Hn=/\d\d/,Wn=/\d{3}/,Zn=/\d{4}/,Xn=/[+-]?\d{6}/,Jn=/\d\d?/,Kn=/\d{1,3}/,Qn=/\d{1,4}/,tr=/[+-]?\d{1,6}/,er=/\d+/,nr=/[+-]?\d+/,rr=/Z|[+-]\d\d:?\d\d/gi,ir=/[+-]?\d+(\.\d{1,3})?/,ar=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,ur={},or={},sr=0,cr=1,lr=2,hr=3,fr=4,dr=5,pr=6;O("M",["MM",2],"Mo",function(){return this.month()+1}),O("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),O("MMMM",0,0,function(t){return this.localeData().months(this,t)}),C("month","M"),U("M",Jn),U("MM",Jn,Hn),U("MMM",ar),U("MMMM",ar),V(["M","MM"],function(t,e){e[cr]=v(t)-1}),V(["MMM","MMMM"],function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);null!=i?e[cr]=i:h(n).invalidMonth=t});var gr="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),yr="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),mr={};n.suppressDeprecationWarnings=!1;var vr=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,br=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],_r=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],xr=/^\/?Date\((\-?\d+)/i;n.createFromInputFallback=nt("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),O(0,["YY",2],0,function(){return this.year()%100}),O(0,["YYYY",4],0,"year"),O(0,["YYYYY",5],0,"year"),O(0,["YYYYYY",6,!0],0,"year"),C("year","y"),U("Y",nr),U("YY",Jn,Hn),U("YYYY",Qn,Zn),U("YYYYY",tr,Xn),U("YYYYYY",tr,Xn),V(["YYYYY","YYYYYY"],sr),V("YYYY",function(t,e){e[sr]=2===t.length?n.parseTwoDigitYear(t):v(t)}),V("YY",function(t,e){e[sr]=n.parseTwoDigitYear(t)}),n.parseTwoDigitYear=function(t){return v(t)+(v(t)>68?1900:2e3)};var wr=T("FullYear",!1);O("w",["ww",2],"wo","week"),O("W",["WW",2],"Wo","isoWeek"),C("week","w"),C("isoWeek","W"),U("w",Jn),U("ww",Jn,Hn),U("W",Jn),U("WW",Jn,Hn),$(["w","ww","W","WW"],function(t,e,n,r){e[r.substr(0,1)]=v(t)});var Ar={dow:0,doy:6};O("DDD",["DDDD",3],"DDDo","dayOfYear"),C("dayOfYear","DDD"),U("DDD",Kn),U("DDDD",Wn),V(["DDD","DDDD"],function(t,e,n){n._dayOfYear=v(t)}),n.ISO_8601=function(){};var Er=nt("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var t=Ft.apply(null,arguments);return this>t?this:t}),kr=nt("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var t=Ft.apply(null,arguments);return t>this?this:t});Rt("Z",":"),Rt("ZZ",""),U("Z",rr),U("ZZ",rr),V(["Z","ZZ"],function(t,e,n){n._useUTC=!0,n._tzm=Pt(t)});var Dr=/([\+\-]|\d\d)/gi;n.updateOffset=function(){};var Cr=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Mr=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/;Kt.fn=Ot.prototype;var Sr=ne(1,"add"),Tr=ne(-1,"subtract");n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var Fr=nt("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return void 0===t?this.localeData():this.locale(t)});O(0,["gg",2],0,function(){return this.weekYear()%100}),O(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Fe("gggg","weekYear"),Fe("ggggg","weekYear"),Fe("GGGG","isoWeekYear"),Fe("GGGGG","isoWeekYear"),C("weekYear","gg"),C("isoWeekYear","GG"),U("G",nr),U("g",nr),U("GG",Jn,Hn),U("gg",Jn,Hn),U("GGGG",Qn,Zn),U("gggg",Qn,Zn),U("GGGGG",tr,Xn),U("ggggg",tr,Xn),$(["gggg","ggggg","GGGG","GGGGG"],function(t,e,n,r){e[r.substr(0,2)]=v(t)}),$(["gg","GG"],function(t,e,r,i){e[i]=n.parseTwoDigitYear(t)}),O("Q",0,0,"quarter"),C("quarter","Q"),U("Q",Gn),V("Q",function(t,e){e[cr]=3*(v(t)-1)}),O("D",["DD",2],"Do","date"),C("date","D"),U("D",Jn),U("DD",Jn,Hn),U("Do",function(t,e){return t?e._ordinalParse:e._ordinalParseLenient}),V(["D","DD"],lr),V("Do",function(t,e){e[lr]=v(t.match(Jn)[0],10)});var Br=T("Date",!0);O("d",0,"do","day"),O("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),O("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),O("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),O("e",0,0,"weekday"),O("E",0,0,"isoWeekday"),C("day","d"),C("weekday","e"),C("isoWeekday","E"),U("d",Jn),U("e",Jn),U("E",Jn),U("dd",ar),U("ddd",ar),U("dddd",ar),$(["dd","ddd","dddd"],function(t,e,n){var r=n._locale.weekdaysParse(t);null!=r?e.d=r:h(n).invalidWeekday=t}),$(["d","e","E"],function(t,e,n,r){ +e[r]=v(t)});var Lr="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Nr="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Or="Su_Mo_Tu_We_Th_Fr_Sa".split("_");O("H",["HH",2],0,"hour"),O("h",["hh",2],0,function(){return this.hours()%12||12}),Ge("a",!0),Ge("A",!1),C("hour","h"),U("a",He),U("A",He),U("H",Jn),U("h",Jn),U("HH",Jn,Hn),U("hh",Jn,Hn),V(["H","HH"],hr),V(["a","A"],function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t}),V(["h","hh"],function(t,e,n){e[hr]=v(t),h(n).bigHour=!0});var Ir=/[ap]\.?m?\.?/i,Rr=T("Hours",!0);O("m",["mm",2],0,"minute"),C("minute","m"),U("m",Jn),U("mm",Jn,Hn),V(["m","mm"],fr);var Pr=T("Minutes",!1);O("s",["ss",2],0,"second"),C("second","s"),U("s",Jn),U("ss",Jn,Hn),V(["s","ss"],dr);var qr=T("Seconds",!1);O("S",0,0,function(){return~~(this.millisecond()/100)}),O(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),O(0,["SSS",3],0,"millisecond"),O(0,["SSSS",4],0,function(){return 10*this.millisecond()}),O(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),O(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),O(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),O(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),O(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),C("millisecond","ms"),U("S",Kn,Gn),U("SS",Kn,Hn),U("SSS",Kn,Wn);var jr;for(jr="SSSS";jr.length<=9;jr+="S")U(jr,er);for(jr="S";jr.length<=9;jr+="S")V(jr,Xe);var Ur=T("Milliseconds",!1);O("z",0,0,"zoneAbbr"),O("zz",0,0,"zoneName");var Yr=g.prototype;Yr.add=Sr,Yr.calendar=ie,Yr.clone=ae,Yr.diff=le,Yr.endOf=we,Yr.format=pe,Yr.from=ge,Yr.fromNow=ye,Yr.to=me,Yr.toNow=ve,Yr.get=L,Yr.invalidAt=Te,Yr.isAfter=ue,Yr.isBefore=oe,Yr.isBetween=se,Yr.isSame=ce,Yr.isValid=Me,Yr.lang=Fr,Yr.locale=be,Yr.localeData=_e,Yr.max=kr,Yr.min=Er,Yr.parsingFlags=Se,Yr.set=L,Yr.startOf=xe,Yr.subtract=Tr,Yr.toArray=De,Yr.toObject=Ce,Yr.toDate=ke,Yr.toISOString=de,Yr.toJSON=de,Yr.toString=fe,Yr.unix=Ee,Yr.valueOf=Ae,Yr.year=wr,Yr.isLeapYear=lt,Yr.weekYear=Le,Yr.isoWeekYear=Ne,Yr.quarter=Yr.quarters=Re,Yr.month=K,Yr.daysInMonth=Q,Yr.week=Yr.weeks=gt,Yr.isoWeek=Yr.isoWeeks=yt,Yr.weeksInYear=Ie,Yr.isoWeeksInYear=Oe,Yr.date=Br,Yr.day=Yr.days=ze,Yr.weekday=Ve,Yr.isoWeekday=$e,Yr.dayOfYear=vt,Yr.hour=Yr.hours=Rr,Yr.minute=Yr.minutes=Pr,Yr.second=Yr.seconds=qr,Yr.millisecond=Yr.milliseconds=Ur,Yr.utcOffset=Ut,Yr.utc=zt,Yr.local=Vt,Yr.parseZone=$t,Yr.hasAlignedHourOffset=Gt,Yr.isDST=Ht,Yr.isDSTShifted=Wt,Yr.isLocal=Zt,Yr.isUtcOffset=Xt,Yr.isUtc=Jt,Yr.isUTC=Jt,Yr.zoneAbbr=Je,Yr.zoneName=Ke,Yr.dates=nt("dates accessor is deprecated. Use date instead.",Br),Yr.months=nt("months accessor is deprecated. Use month instead",K),Yr.years=nt("years accessor is deprecated. Use year instead",wr),Yr.zone=nt("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Yt);var zr=Yr,Vr={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},$r={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"},Gr="Invalid date",Hr="%d",Wr=/\d{1,2}/,Zr={future:"in %s",past:"%s ago",s:"a few 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"},Xr=_.prototype;Xr._calendar=Vr,Xr.calendar=en,Xr._longDateFormat=$r,Xr.longDateFormat=nn,Xr._invalidDate=Gr,Xr.invalidDate=rn,Xr._ordinal=Hr,Xr.ordinal=an,Xr._ordinalParse=Wr,Xr.preparse=un,Xr.postformat=un,Xr._relativeTime=Zr,Xr.relativeTime=on,Xr.pastFuture=sn,Xr.set=cn,Xr.months=W,Xr._months=gr,Xr.monthsShort=Z,Xr._monthsShort=yr,Xr.monthsParse=X,Xr.week=ft,Xr._week=Ar,Xr.firstDayOfYear=pt,Xr.firstDayOfWeek=dt,Xr.weekdays=qe,Xr._weekdays=Lr,Xr.weekdaysMin=Ue,Xr._weekdaysMin=Or,Xr.weekdaysShort=je,Xr._weekdaysShort=Nr,Xr.weekdaysParse=Ye,Xr.isPM=We,Xr._meridiemParse=Ir,Xr.meridiem=Ze,E("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,n=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+n}}),n.lang=nt("moment.lang is deprecated. Use moment.locale instead.",E),n.langData=nt("moment.langData is deprecated. Use moment.localeData instead.",D);var Jr=Math.abs,Kr=Cn("ms"),Qr=Cn("s"),ti=Cn("m"),ei=Cn("h"),ni=Cn("d"),ri=Cn("w"),ii=Cn("M"),ai=Cn("y"),ui=Sn("milliseconds"),oi=Sn("seconds"),si=Sn("minutes"),ci=Sn("hours"),li=Sn("days"),hi=Sn("months"),fi=Sn("years"),di=Math.round,pi={s:45,m:45,h:22,d:26,M:11},gi=Math.abs,yi=Ot.prototype;yi.abs=mn,yi.add=bn,yi.subtract=_n,yi.as=kn,yi.asMilliseconds=Kr,yi.asSeconds=Qr,yi.asMinutes=ti,yi.asHours=ei,yi.asDays=ni,yi.asWeeks=ri,yi.asMonths=ii,yi.asYears=ai,yi.valueOf=Dn,yi._bubble=wn,yi.get=Mn,yi.milliseconds=ui,yi.seconds=oi,yi.minutes=si,yi.hours=ci,yi.days=li,yi.weeks=Tn,yi.months=hi,yi.years=fi,yi.humanize=Nn,yi.toISOString=On,yi.toString=On,yi.toJSON=On,yi.locale=be,yi.localeData=_e,yi.toIsoString=nt("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",On),yi.lang=Fr,O("X",0,0,"unix"),O("x",0,0,"valueOf"),U("x",nr),U("X",ir),V("X",function(t,e,n){n._d=new Date(1e3*parseFloat(t,10))}),V("x",function(t,e,n){n._d=new Date(v(t))}),n.version="2.10.6",r(Ft),n.fn=zr,n.min=Lt,n.max=Nt,n.utc=c,n.unix=Qe,n.months=fn,n.isDate=a,n.locale=E,n.invalid=d,n.duration=Kt,n.isMoment=y,n.weekdays=pn,n.parseZone=tn,n.localeData=D,n.isDuration=It,n.monthsShort=dn,n.weekdaysMin=yn,n.defineLocale=k,n.weekdaysShort=gn,n.normalizeUnits=M,n.relativeTimeThreshold=Ln;var mi=n;return mi})},{}],107:[function(t,e){e.exports={name:"mermaid",version:"0.5.5",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:{live:"live-server ./test/examples",lint:"node node_modules/eslint/bin/eslint.js src",jison:"gulp jison_legacy",watch:"source ./scripts/watch.sh",doc:"rm -r build;rm -r dist/www;gulp vartree;cp dist/www/all.html ../mermaid-pages/index.html;cp dist/mermaid.js ../mermaid-pages/javascripts/lib;cp dist/mermaid.forest.css ../mermaid-pages/stylesheets",tape:"node node_modules/.bin/tape test/cli_test-*.js",jasmine:"npm run jison &&node node_modules/jasmine-es6/bin/jasmine.js",posttest:"npm run jison",test:"npm run dist && npm run jasmine && npm run tape","dist-slim-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.slim.js -x d3 && cat dist/mermaid.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.slim.min.js","dist-slim-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.slim.js -x d3 && cat dist/mermaidAPI.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.slim.min.js","dist-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.js && cat dist/mermaid.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.min.js","dist-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.js && cat dist/mermaidAPI.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.min.js",dist:"npm run dist-slim-mermaid;npm run dist-slim-mermaidAPI; npm run dist-mermaid;npm run dist-mermaidAPI"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"3.5.6",dagre:"^0.7.4","dagre-d3":"0.4.10",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","babel-eslint":"^4.1.3",babelify:"^6.4.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4",dateformat:"^1.0.11",dox:"^0.8.0",eslint:"^1.6.0","eslint-watch":"^2.1.2","event-stream":"^3.2.0",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.9.0","gulp-bower":"0.0.10","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-dox":"^0.1.6","gulp-ext-replace":"^0.2.0","gulp-filelog":"^0.4.1","gulp-front-matter":"^1.2.3","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~2.1.0","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-marked":"^1.0.0","gulp-mdvars":"^2.0.0","gulp-qunit":"~1.2.1","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1","gulp-vartree":"^2.0.1","hogan.js":"^3.0.2",jasmine:"2.3.2","jasmine-es6":"0.0.18",jison:"zaach/jison",jsdom:"^7.0.2","jshint-stylish":"^2.0.1","map-stream":"0.0.6",marked:"^0.3.2","mock-browser":"^0.91.34",path:"^0.4.9",phantomjs:"^1.9.18",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3",testdom:"^2.0.0",uglifyjs:"^2.4.10","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],108:[function(t,e){"use strict";var n;if(t)try{n=t("d3")}catch(r){}n||(n=window.d3),e.exports=n,function(){var t=!1;if(t="tspans",n.selection.prototype.textwrap)return!1;if("undefined"==typeof t)var t=!1;n.selection.prototype.textwrap=n.selection.enter.prototype.textwrap=function(e,r){var i,r=parseInt(r)||0,a=this,u=function(t){var e=t[0][0],r=e.tagName.toString();if("rect"!==r)return!1;var i={};return i.x=n.select(e).attr("x")||0,i.y=n.select(e).attr("y")||0,i.width=n.select(e).attr("width")||0,i.height=n.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)||"[object Array]"===Object.prototype.toString.call(t)){var e=u(t);return e}return!1},s=function(t,e){var n=t;return 0!==e&&(n.x=parseInt(n.x)+e,n.y=parseInt(n.y)+e,n.width-=2*e,n.height-=2*e),n},c=o(e);if(r&&(c=s(c,r)),0!=a.length&&n&&e&&c){e=c;var l,h=function(t){var r=n.select(t[0].parentNode),a=r.select("text"),u=a.style("line-height"),o=a.text();a.remove();var s=r.append("foreignObject");s.attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);var c=s.append("xhtml:div").attr("class","wrapped");c.style("height",e.height).style("width",e.width).html(o),u&&c.style("line-height",u),i=r.select("foreignObject")},f=function(t){var a,u=t[0],o=u.parentNode,s=n.select(u),c=u.getBBox().height,l=u.getBBox().width,h=c,f=s.style("line-height");if(a=f&&parseInt(f)?parseInt(f.replace("px","")):h,l>e.width){var d=s.text();if(s.text(""),d){var p,g;if(-1!==d.indexOf(" ")){var p=" ";g=d.split(" ")}else{p="";var y=d.length,m=Math.ceil(l/e.width),v=Math.floor(y/m);v*m>=y||m++;for(var b,_,g=[],x=0;m>x;x++)_=x*v,b=d.substr(_,v),g.push(b)}for(var w=[],A=0,E={},x=0;xe.width&&C&&""!==C&&(A+=M,E={string:C,width:M,offset:A},w.push(E),s.text(""),s.text(D),x==g.length-1&&(k=D,s.text(k),S=u.getComputedTextLength())),x==g.length-1){s.text("");var T=k;T&&""!==T&&(S-A>0&&(S-=A),E={string:T,width:S,offset:A},w.push(E))}}var F;s.text("");for(var x=0;x0){w[x-1]}x*a0?a:void 0}),F.attr("x",function(){var t=e.x;return r&&(t+=r),t}))}}}s.attr("y",function(){var t=e.y;return a&&(t+=a),r&&(t+=r),t}),s.attr("x",function(){var t=e.x;return r&&(t+=r),t}),i=n.select(o).selectAll("text")};t&&("foreignobjects"==t?l=h:"tspans"==t&&(l=f)),t||(l="undefined"!=typeof SVGForeignObjectElement?h:f);for(var d=0;d "+t.w+": "+JSON.stringify(u.edge(t))),p(i,u.edge(t),u.edge(t).relation)}),i.attr("height","100%"),i.attr("width","100%")}},{"../../d3":108,"../../logger":127,"./classDb":109,"./parser/classDiagram":111,dagre:54}],111:[function(t,e,n){(function(r){"use strict";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,11],r=[1,12],i=[1,13],a=[1,15],u=[1,16],o=[1,17],s=[6,8],c=[1,26],l=[1,27],h=[1,28],f=[1,29],d=[1,30],p=[1,31],g=[6,8,13,17,23,26,27,28,29,30,31],y=[6,8,13,17,23,26,27,28,29,30,31,45,46,47],m=[23,45,46,47],v=[23,30,31,45,46,47],b=[23,26,27,28,29,45,46,47],_=[6,8,13],x=[1,46],w={trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,CLASS_DIAGRAM:5,NEWLINE:6,statements:7,EOF:8,statement:9,className:10,alphaNumToken:11,relationStatement:12,LABEL:13,classStatement:14,methodStatement:15,CLASS:16,STRUCT_START:17,members:18,STRUCT_STOP:19,MEMBER:20,SEPARATOR:21,relation:22,STR:23,relationType:24,lineType:25,AGGREGATION:26,EXTENSION:27,COMPOSITION:28,DEPENDENCY:29,LINE:30,DOTTED_LINE:31,commentToken:32,textToken:33,graphCodeTokens:34,textNoTagsToken:35,TAGSTART:36,TAGEND:37,"==":38,"--":39,PCT:40,DEFAULT:41,SPACE:42,MINUS:43,keywords:44,UNICODE_TEXT:45,NUM:46,ALPHA:47,$accept:0,$end:1},terminals_:{2:"error",5:"CLASS_DIAGRAM",6:"NEWLINE",8:"EOF",13:"LABEL",16:"CLASS",17:"STRUCT_START",19:"STRUCT_STOP",20:"MEMBER",21:"SEPARATOR",23:"STR",26:"AGGREGATION",27:"EXTENSION",28:"COMPOSITION",29:"DEPENDENCY",30:"LINE",31:"DOTTED_LINE",34:"graphCodeTokens",36:"TAGSTART",37:"TAGEND",38:"==",39:"--",40:"PCT",41:"DEFAULT",42:"SPACE",43:"MINUS",44:"keywords",45:"UNICODE_TEXT",46:"NUM",47:"ALPHA"},productions_:[0,[3,1],[4,4],[7,1],[7,3],[10,2],[10,1],[9,1],[9,2],[9,1],[9,1],[14,2],[14,5],[18,1],[18,2],[15,1],[15,2],[15,1],[15,1],[12,3],[12,4],[12,4],[12,5],[22,3],[22,2],[22,2],[22,1],[24,1],[24,1],[24,1],[24,1],[25,1],[25,1],[32,1],[32,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[35,1],[35,1],[35,1],[35,1],[11,1],[11,1],[11,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 5:this.$=a[u-1]+a[u];break;case 6:this.$=a[u];break;case 7:r.addRelation(a[u]);break;case 8:a[u-1].title=r.cleanupLabel(a[u]),r.addRelation(a[u-1]);break;case 12:r.addMembers(a[u-3],a[u-1]);break;case 13:this.$=[a[u]];break;case 14:a[u].push(a[u-1]),this.$=a[u];break;case 15:break;case 16:r.addMembers(a[u-1],r.cleanupLabel(a[u]));break;case 17:console.warn("Member",a[u]);break;case 18:break;case 19:this.$={id1:a[u-2],id2:a[u],relation:a[u-1],relationTitle1:"none",relationTitle2:"none"};break;case 20:this.$={id1:a[u-3],id2:a[u],relation:a[u-1],relationTitle1:a[u-2],relationTitle2:"none"};break;case 21:this.$={id1:a[u-3],id2:a[u],relation:a[u-2],relationTitle1:"none",relationTitle2:a[u-1]};break;case 22:this.$={id1:a[u-4],id2:a[u],relation:a[u-2],relationTitle1:a[u-3],relationTitle2:a[u-1]};break;case 23:this.$={type1:a[u-2],type2:a[u],lineType:a[u-1]};break;case 24:this.$={type1:"none",type2:a[u],lineType:a[u-1]};break;case 25:this.$={type1:a[u-1],type2:"none",lineType:a[u]};break;case 26:this.$={type1:"none",type2:"none",lineType:a[u]};break;case 27:this.$=r.relationType.AGGREGATION;break;case 28:this.$=r.relationType.EXTENSION;break;case 29:this.$=r.relationType.COMPOSITION;break;case 30:this.$=r.relationType.DEPENDENCY;break;case 31:this.$=r.lineType.LINE;break;case 32:this.$=r.lineType.DOTTED_LINE}},table:[{3:1,4:2,5:[1,3]},{1:[3]},{1:[2,1]},{6:[1,4]},{7:5,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:u,47:o},{8:[1,18]},{6:[1,19],8:[2,3]},e(s,[2,7],{13:[1,20]}),e(s,[2,9]),e(s,[2,10]),e(s,[2,15],{22:21,24:24,25:25,13:[1,23],23:[1,22],26:c,27:l,28:h,29:f,30:d,31:p}),{10:32,11:14,45:a,46:u,47:o},e(s,[2,17]),e(s,[2,18]),e(g,[2,6],{11:14,10:33,45:a,46:u,47:o}),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),{1:[2,2]},{7:34,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:u,47:o},e(s,[2,8]),{10:35,11:14,23:[1,36],45:a,46:u,47:o},{22:37,24:24,25:25,26:c,27:l,28:h,29:f,30:d,31:p},e(s,[2,16]),{25:38,30:d,31:p},e(m,[2,26],{24:39,26:c,27:l,28:h,29:f}),e(v,[2,27]),e(v,[2,28]),e(v,[2,29]),e(v,[2,30]),e(b,[2,31]),e(b,[2,32]),e(s,[2,11],{17:[1,40]}),e(g,[2,5]),{8:[2,4]},e(_,[2,19]),{10:41,11:14,45:a,46:u,47:o},{10:42,11:14,23:[1,43],45:a,46:u,47:o},e(m,[2,25],{24:44,26:c,27:l,28:h,29:f}),e(m,[2,24]),{18:45,20:x},e(_,[2,21]),e(_,[2,20]),{10:47,11:14,45:a,46:u,47:o},e(m,[2,23]),{19:[1,48]},{18:49,19:[2,13],20:x},e(_,[2,22]),e(s,[2,12]),{19:[2,14]}],defaultActions:{2:[2,1],18:[2,2],34:[2,4],49:[2,14]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},A=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:return 6;case 2:break;case 3:return 5;case 4:return this.begin("struct"),17;case 5:return this.popState(),19;case 6:break;case 7:return"MEMBER";case 8:return 16;case 9:this.begin("string");break;case 10:this.popState();break;case 11:return"STR";case 12:return 27;case 13:return 27;case 14:return 29;case 15:return 29;case 16:return 28;case 17:return 26;case 18:return 30;case 19:return 31;case 20:return 13;case 21:return 43;case 22:return"DOT";case 23:return"PLUS";case 24:return 40;case 25:return"EQUALS";case 26:return"EQUALS";case 27:return 47;case 28:return"PUNCTUATION";case 29:return 46;case 30:return 45;case 31:return 42;case 32:return 8}},rules:[/^(?:%%[^\n]*)/,/^(?:\n+)/,/^(?:\s+)/,/^(?:classDiagram\b)/,/^(?:[\{])/,/^(?:\})/,/^(?:[\n])/,/^(?:[^\{\}\n]*)/,/^(?:class\b)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::[^#\n;]+)/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[A-Za-z]+)/,/^(?:[!"#$%&'*+,-.`?\\_\/])/,/^(?:[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:{string:{rules:[10,11],inclusive:!1},struct:{rules:[5,6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,8,9,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32],inclusive:!0}}};return t}();return w.lexer=A,t.prototype=w,w.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("_process"))},{_process:3,fs:1,path:2}],112:[function(t,e,n){(function(e){"use strict";var r=t("../../logger"),i=new r.Log,a="",u=!1;n.setMessage=function(t){i.debug("Setting message to: "+t),a=t},n.getMessage=function(){return a},n.setInfo=function(t){u=t},n.getInfo=function(){return u},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":127}],113:[function(t,e,n){"use strict";var r=t("./exampleDb"),i=t("./parser/example.js"),a=t("../../d3"),u=t("../../logger"),o=new u.Log;n.draw=function(t,e,n){var u;u=i.parser,u.yy=r,o.debug("Renering example diagram"),u.parse(t);var s=a.select("#"+e),c=s.append("g");c.append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("mermaid "+n),s.attr("height",100),s.attr("width",400)}},{"../../d3":108,"../../logger":127,"./exampleDb":112,"./parser/example.js":114}],114:[function(t,e,n){(function(r){"use strict";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=[6,9,10,12],r={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,message:11,say:12,TXT:13,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo",12:"say",13:"TXT"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1],[8,1],[11,2]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:return r;case 4:break;case 6:r.setInfo(!0);break;case 7:r.setMessage(a[u]);break;case 8:this.$=a[u-1].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8],11:9,12:[1,10]},{1:[2,1]},e(n,[2,3]),e(n,[2,4]),e(n,[2,5]),e(n,[2,6]),e(n,[2,7]),{13:[1,11]},e(n,[2,8])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},i=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,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),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;ae[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]),"utf8");return n.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&n.main(r.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],115:[function(t,e){"use strict";var n,r=t("../../logger"),i=new r.Log;if(t)try{n=t("dagre-d3")}catch(a){i.debug("Could not load dagre-d3")}n||(n=window.dagreD3),e.exports=n},{"../../logger":127,"dagre-d3":5}],116:[function(t,e,n){"use strict";var r=t("./graphDb"),i=t("./parser/flow"),a=t("./parser/dot"),u=t("../../d3"),o=t("./dagre-d3"),s=t("../../logger"),c=new s.Log,l={};e.exports.setConf=function(t){var e,n=Object.keys(t);for(e=0;e0&&(u=a.classes.join(" "));var o="";o=r(o,a.styles),i="undefined"==typeof a.text?a.id:a.text;var s="";l.htmlLabels?(s="html",i=i.replace(/fa:fa[\w\-]+/g,function(t){return''})):(i=i.replace(/
/g,"\n"),s="text");var c=0,h="";switch(a.type){case"round":c=5,h="rect";break;case"square":h="rect";break;case"diamond":h="question";break;case"odd":h="rect_left_inv_arrow";break;case"odd_right":h="rect_left_inv_arrow";break;case"circle":h="circle";break;case"ellipse":h="ellipse";break;case"group":h="rect",i="";break;default:h="rect"}e.setNode(a.id,{labelType:s,shape:h,label:i,rx:c,ry:c,"class":u,style:o,id:a.id})})},n.addEdges=function(t,e){var n,r,i=0;"undefined"!=typeof t.defaultStyle&&(r=t.defaultStyle.toString().replace(/,/g,";")),t.forEach(function(t){i++,n="arrow_open"===t.type?"none":"normal";var a="";if("undefined"!=typeof t.style)t.style.forEach(function(t){a=a+t+";"});else switch(t.stroke){case"normal":a="fill:none","undefined"!=typeof r&&(a=r);break;case"dotted":a="stroke: #333; fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":a="stroke: #333; stroke-width: 3.5px;fill:none"}if("undefined"==typeof t.text)"undefined"==typeof t.style?e.setEdge(t.start,t.end,{style:a,arrowhead:n},i):e.setEdge(t.start,t.end,{style:a,arrowheadStyle:"fill: #333",arrowhead:n},i);else{var u=t.text.replace(/
/g,"\n");"undefined"==typeof t.style?l.htmlLabels?e.setEdge(t.start,t.end,{labelType:"html",style:a,labelpos:"c",label:''+t.text+"",arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:"stroke: #333; stroke-width: 1.5px;fill:none",labelpos:"c",label:u,arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:a,arrowheadStyle:"fill: #333",label:u,arrowhead:n},i)}})},n.getClasses=function(t,e){var n;r.clear(),n=e?a.parser:i.parser,n.yy=r,n.parse(t);var u=r.getClasses();return"undefined"==typeof u["default"]&&(u["default"]={id:"default"},u["default"].styles=[],u["default"].clusterStyles=["rx:4px","fill: rgb(255, 255, 222)","rx: 4px","stroke: rgb(170, 170, 51)","stroke-width: 1px"],u["default"].nodeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"],u["default"].edgeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"]),u},n.draw=function(t,e,s){c.debug("Drawing flowchart");var h;r.clear(),h=s?a.parser:i.parser,h.yy=r;try{h.parse(t)}catch(f){c.debug("Parsing failed")}var d;d=r.getDirection(),"undefined"==typeof d&&(d="TD");var p,g=new o.graphlib.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:d,marginx:20,marginy:20}).setDefaultEdgeLabel(function(){return{}}),y=r.getSubGraphs(),m=0;for(m=y.length-1;m>=0;m--)p=y[m],r.addVertex(p.id,p.title,"group",void 0);var v=r.getVertices(),b=r.getEdges();m=0;var _;for(m=y.length-1;m>=0;m--)for(p=y[m],u.selectAll("cluster").append("text"),_=0;_0?t.split(",").forEach(function(t){"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)}):"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)};var setTooltip=function(t,e){"undefined"!=typeof e&&(tooltips[t]=e)},setClickFun=function setClickFun(id,functionName){"undefined"!=typeof functionName&&"undefined"!=typeof vertices[id]&&funs.push(function(element){var elem=d3.select(element).select("#"+id);null!==elem&&elem.on("click",function(){eval(functionName+"('"+id+"')")})})},setLink=function(t,e){"undefined"!=typeof e&&"undefined"!=typeof vertices[t]&&funs.push(function(n){var r=d3.select(n).select("#"+t);null!==r&&r.on("click",function(){window.open(e,"newTab")})})};exports.getTooltip=function(t){return tooltips[t]},exports.setClickEvent=function(t,e,n,r){t.indexOf(",")>0?t.split(",").forEach(function(t){setTooltip(t,r),setClickFun(t,e),setLink(t,n)}):(setTooltip(t,r),setClickFun(t,e),setLink(t,n))},exports.bindFunctions=function(t){funs.forEach(function(e){e(t)})},exports.getDirection=function(){return direction},exports.getVertices=function(){return vertices},exports.getEdges=function(){return edges},exports.getClasses=function(){return classes};var setupToolTips=function(t){var e=d3.select(".mermaidTooltip");null===e[0][0]&&(e=d3.select("body").append("div").attr("class","mermaidTooltip").style("opacity",0));var n=d3.select(t).select("svg"),r=n.selectAll("g.node");r.on("mouseover",function(){var t=d3.select(this),n=t.attr("title");if(null!==n){var r=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",r.left+(r.right-r.left)/2+"px").style("top",r.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}}).on("mouseout",function(){e.transition().duration(500).style("opacity",0);var t=d3.select(this);t.classed("hover",!1)})};funs.push(setupToolTips),exports.clear=function(){vertices={},classes={},edges=[],funs=[],funs.push(setupToolTips),subGraphs=[],subCount=0,tooltips=[]},exports.defaultStyle=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},exports.addSubGraph=function(t,e){function n(t){var e={"boolean":{},number:{},string:{}},n=[];return t.filter(function(t){var r=typeof t;return" "===t?!1:r in e?e[r].hasOwnProperty(t)?!1:e[r][t]=!0:n.indexOf(t)>=0?!1:n.push(t)})}var r=[];r=n(r.concat.apply(r,t));var i={id:"subGraph"+subCount,nodes:r,title:e};return subGraphs.push(i),subCount+=1,i.id};var getPosForId=function(t){var e;for(e=0;e2e3)){if(posCrossRef[secCount]=n,subGraphs[n].id===e)return{result:!0,count:0};for(var i=0,a=1;i=0){var o=t(e,u);if(o.result)return{result:!0,count:a+o.count};a+=o.count}i+=1}return{result:!1,count:a}}};exports.getDepthFirstPos=function(t){return posCrossRef[t]},exports.indexNodes=function(){secCount=-1,subGraphs.length>0&&indexNodes("none",subGraphs.length-1,0)},exports.getSubGraphs=function(){return subGraphs},exports.parseError=function(t,e){global.mermaidAPI.parseError(t,e)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../d3":108,"../../logger":127}],118:[function(t,e,n){(function(r){"use strict";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,5],r=[1,6],i=[1,12],a=[1,13],u=[1,14],o=[1,15],s=[1,16],c=[1,17],l=[1,18],h=[1,19],f=[1,20],d=[1,21],p=[1,22],g=[8,16,17,18,19,20,21,22,23,24,25,26],y=[1,37],m=[1,33],v=[1,34],b=[1,35],_=[1,36],x=[8,10,16,17,18,19,20,21,22,23,24,25,26,28,32,37,39,40,45,57,58],w=[10,28],A=[10,28,37,57,58],E=[2,49],k=[1,45],D=[1,48],C=[1,49],M=[1,52],S=[2,65],T=[1,65],F=[1,66],B=[1,67],L=[1,68],N=[1,69],O=[1,70],I=[1,71],R=[1,72],P=[1,73],q=[8,16,17,18,19,20,21,22,23,24,25,26,47],j=[10,28,37],U={trace:function(){},yy:{},symbols_:{error:2,expressions:3,graph:4,EOF:5,graphStatement:6,idStatement:7,"{":8,stmt_list:9,"}":10,strict:11,GRAPH:12,DIGRAPH:13,textNoTags:14,textNoTagsToken:15,ALPHA:16,NUM:17,COLON:18,PLUS:19,EQUALS:20,MULT:21,DOT:22,BRKT:23,SPACE:24,MINUS:25,keywords:26,stmt:27,";":28,node_stmt:29,edge_stmt:30,attr_stmt:31,"=":32,subgraph:33,attr_list:34,NODE:35,EDGE:36,"[":37,a_list:38,"]":39,",":40,edgeRHS:41,node_id:42,edgeop:43,port:44,":":45,compass_pt:46,SUBGRAPH:47,n:48,ne:49,e:50,se:51,s:52,sw:53,w:54,nw:55,c:56,ARROW_POINT:57,ARROW_OPEN:58,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",8:"{",10:"}",11:"strict",12:"GRAPH",13:"DIGRAPH",16:"ALPHA",17:"NUM",18:"COLON",19:"PLUS",20:"EQUALS",21:"MULT",22:"DOT",23:"BRKT",24:"SPACE",25:"MINUS",26:"keywords",28:";",32:"=",35:"NODE",36:"EDGE",37:"[",39:"]",40:",",45:":",47:"SUBGRAPH",48:"n",49:"ne",50:"e",51:"se",52:"s",53:"sw",54:"w",55:"nw",56:"c",57:"ARROW_POINT",58:"ARROW_OPEN"},productions_:[0,[3,2],[4,5],[4,6],[4,4],[6,1],[6,1],[7,1],[14,1],[14,2],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[9,1],[9,3],[27,1],[27,1],[27,1],[27,3],[27,1],[31,2],[31,2],[31,2],[34,4],[34,3],[34,3],[34,2],[38,5],[38,5],[38,3],[30,3],[30,3],[30,2],[30,2],[41,3],[41,3],[41,2],[41,2],[29,2],[29,1],[42,2],[42,1],[44,4],[44,2],[44,2],[33,5],[33,4],[33,3],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,0],[43,1],[43,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:this.$=a[u-1];break;case 2:this.$=a[u-4];break;case 3:this.$=a[u-5];break;case 4:this.$=a[u-3];break;case 8:case 10:case 11:this.$=a[u];break;case 9:this.$=a[u-1]+""+a[u];break;case 12:case 13:case 14:case 15:case 16:case 18:case 19:case 20:this.$=a[u];break;case 17:this.$="
";break;case 39:this.$="oy";break;case 40:r.addLink(a[u-1],a[u].id,a[u].op),this.$="oy";break;case 42:r.addLink(a[u-1],a[u].id,a[u].op),this.$={op:a[u-2],id:a[u-1]};break;case 44:this.$={op:a[u-1],id:a[u]};break;case 48:r.addVertex(a[u-1]),this.$=a[u-1];break;case 49:r.addVertex(a[u]),this.$=a[u];break;case 66:this.$="arrow";break;case 67:this.$="arrow_open"}},table:[{3:1,4:2,6:3,11:[1,4],12:n,13:r},{1:[3]},{5:[1,7]},{7:8,8:[1,9],14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{6:23,12:n,13:r},e(g,[2,5]),e(g,[2,6]),{1:[2,1]},{8:[1,24]},{7:30,8:y,9:25,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},e([8,10,28,32,37,39,40,45,57,58],[2,7],{15:38,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p}),e(x,[2,8]),e(x,[2,10]),e(x,[2,11]),e(x,[2,12]),e(x,[2,13]),e(x,[2,14]),e(x,[2,15]),e(x,[2,16]),e(x,[2,17]),e(x,[2,18]),e(x,[2,19]),e(x,[2,20]),{7:39,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{7:30,8:y,9:40,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,41]},{10:[2,21],28:[1,42]},e(w,[2,23]),e(w,[2,24]),e(w,[2,25]),e(A,E,{44:44,32:[1,43],45:k}),e(w,[2,27],{41:46,43:47,57:D,58:C}),e(w,[2,47],{43:47,34:50,41:51,37:M,57:D,58:C}),{34:53,37:M},{34:54,37:M},{34:55,37:M},{7:56,8:[1,57],14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{7:30,8:y,9:58,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},e(x,[2,9]),{8:[1,59]},{10:[1,60]},{5:[2,4]},{7:30,8:y,9:61,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{7:62,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},e(A,[2,48]),e(A,S,{14:10,15:11,7:63,46:64,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,48:T,49:F,50:B,51:L,52:N,53:O,54:I,55:R,56:P}),e(w,[2,41],{34:74,37:M}),{7:77,8:y,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,33:76,42:75,47:_},e(q,[2,66]),e(q,[2,67]),e(w,[2,46]),e(w,[2,40],{34:78,37:M}),{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:79,39:[1,80]},e(w,[2,28]),e(w,[2,29]),e(w,[2,30]),{8:[1,82]},{7:30,8:y,9:83,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,84]},{7:30,8:y,9:85,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{5:[2,2]},{10:[2,22]},e(w,[2,26]),e(A,[2,51],{45:[1,86]}),e(A,[2,52]),e(A,[2,56]),e(A,[2,57]),e(A,[2,58]),e(A,[2,59]),e(A,[2,60]),e(A,[2,61]),e(A,[2,62]),e(A,[2,63]),e(A,[2,64]),e(w,[2,38]),e(j,[2,44],{43:47,41:87,57:D,58:C}),e(j,[2,45],{43:47,41:88,57:D,58:C}),e(A,E,{44:44,45:k}),e(w,[2,39]),{39:[1,89]},e(w,[2,34],{34:90,37:M}),{32:[1,91]},{7:30,8:y,9:92,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,93]},e(A,[2,55]),{10:[1,94]},e(A,S,{46:95,48:T,49:F,50:B,51:L,52:N,53:O,54:I,55:R,56:P}),e(j,[2,42]),e(j,[2,43]),e(w,[2,33],{34:96,37:M}),e(w,[2,32]),{7:97,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{10:[1,98]},e(A,[2,54]),{5:[2,3]},e(A,[2,50]),e(w,[2,31]),{28:[1,99],39:[2,37],40:[1,100]},e(A,[2,53]),{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:101},{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:102},{39:[2,35]},{39:[2,36]}],defaultActions:{7:[2,1],41:[2,4],60:[2,2],61:[2,22],94:[2,3],101:[2,35],102:[2,36]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},Y=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:return"STYLE";case 1:return"LINKSTYLE";case 2:return"CLASSDEF";case 3:return"CLASS";case 4:return"CLICK";case 5:return 12;case 6:return 13;case 7:return 47;case 8:return 35;case 9:return 36;case 10:return"DIR";case 11:return"DIR";case 12:return"DIR";case 13:return"DIR";case 14:return"DIR";case 15:return"DIR";case 16:return 17;case 17:return 23;case 18:return 18;case 19:return 28;case 20:return 40;case 21:return 32;case 22:return 21;case 23:return 22;case 24:return"ARROW_CROSS";case 25:return 57;case 26:return"ARROW_CIRCLE";case 27:return 58;case 28:return 25;case 29:return 19;case 30:return 20;case 31:return 16;case 32:return"PIPE";case 33:return"PS";case 34:return"PE";case 35:return 37;case 36:return 39;case 37:return 8;case 38:return 10;case 39:return"QUOTE";case 40:return 24;case 41:return"NEWLINE";case 42:return 5}},rules:[/^(?:style\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:digraph\b)/,/^(?:subgraph\b)/,/^(?:node\b)/,/^(?:edge\b)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9])/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:=)/,/^(?:\*)/,/^(?:\.)/,/^(?:--[x])/,/^(?:->)/,/^(?:--[o])/,/^(?:--)/,/^(?:-)/,/^(?:\+)/,/^(?:=)/,/^(?:[\u0021-\u0027\u002A-\u002E\u003F\u0041-\u005A\u0061-\u007A\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)/,/^(?:\n)/,/^(?:$)/],conditions:{INITIAL:{rules:[0,1,2,3,4,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],inclusive:!0}}};return t}();return U.lexer=Y,t.prototype=U,U.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("_process"))},{_process:3,fs:1,path:2}],119:[function(t,e,n){(function(r){"use strict";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,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],u=[2,2],o=[1,12],s=[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],b=[1,28],_=[1,38],x=[1,40],w=[1,35],A=[1,39],E=[1,45],k=[1,44],D=[1,36],C=[1,37],M=[1,41],S=[1,42],T=[1,43],F=[1,8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],B=[1,53],L=[1,52],N=[1,54],O=[1,72],I=[1,80],R=[1,81],P=[1,66],q=[1,65],j=[1,85],U=[1,84],Y=[1,82],z=[1,83],V=[1,73],$=[1,68],G=[1,67],H=[1,63],W=[1,75],Z=[1,76],X=[1,77],J=[1,78],K=[1,79],Q=[1,70],tt=[1,69],et=[8,9,11],nt=[8,9,11,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64],rt=[1,115],it=[8,9,10,11,13,15,18,36,38,40,42,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,85,87,88,90,91,93,94,95,96,97],at=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,42,43,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],ut=[1,117],ot=[1,118],st=[8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],ct=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,43,46,50,51,52,53,54,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],lt=[13,18,46,81,85,87,88,90,91,93,94,95,96,97],ht=[13,18,46,49,65,81,85,87,88,90,91,93,94,95,96,97],ft=[1,191],dt=[1,188],pt=[1,195],gt=[1,192],yt=[1,189],mt=[1,196],vt=[1,186],bt=[1,187],_t=[1,190],xt=[1,193],wt=[1,194],At=[1,211],Et=[8,9,11,85],kt=[8,9,10,11,46,71,80,81,83,85,87,88,89,90,91],Dt={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,"(-":40,"-)":41,DIAMOND_START:42,DIAMOND_STOP:43,alphaNumStatement:44,alphaNumToken:45,MINUS:46,linkStatement:47,arrowText:48,TESTSTR:49,"--":50,ARROW_POINT:51,ARROW_CIRCLE:52,ARROW_CROSS:53,ARROW_OPEN:54,"-.":55,DOTTED_ARROW_POINT:56,DOTTED_ARROW_CIRCLE:57,DOTTED_ARROW_CROSS:58,DOTTED_ARROW_OPEN:59,"==":60,THICK_ARROW_POINT:61,THICK_ARROW_CIRCLE:62,THICK_ARROW_CROSS:63,THICK_ARROW_OPEN:64,PIPE:65,textToken:66,STR:67,commentText:68,commentToken:69,keywords:70,STYLE:71,LINKSTYLE:72,CLASSDEF:73,CLASS:74,CLICK:75,textNoTags:76,textNoTagsToken:77,DEFAULT:78,stylesOpt:79,HEX:80,NUM:81,commentStatement:82,PCT:83,style:84,COMMA:85,styleComponent:86,ALPHA:87,COLON:88,UNIT:89,BRKT:90,DOT:91,graphCodeTokens:92,PUNCTUATION:93,UNICODE_TEXT:94,PLUS:95,EQUALS:96,MULT:97,TAG_START:98,TAG_END:99,QUOTE:100,$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:"(-",41:"-)",42:"DIAMOND_START",43:"DIAMOND_STOP",46:"MINUS",49:"TESTSTR",50:"--",51:"ARROW_POINT",52:"ARROW_CIRCLE",53:"ARROW_CROSS",54:"ARROW_OPEN",55:"-.",56:"DOTTED_ARROW_POINT",57:"DOTTED_ARROW_CIRCLE",58:"DOTTED_ARROW_CROSS",59:"DOTTED_ARROW_OPEN",60:"==",61:"THICK_ARROW_POINT",62:"THICK_ARROW_CIRCLE",63:"THICK_ARROW_CROSS",64:"THICK_ARROW_OPEN",65:"PIPE",67:"STR",71:"STYLE",72:"LINKSTYLE",73:"CLASSDEF",74:"CLASS",75:"CLICK",78:"DEFAULT",80:"HEX",81:"NUM",83:"PCT",85:"COMMA",87:"ALPHA",88:"COLON",89:"UNIT",90:"BRKT",91:"DOT",93:"PUNCTUATION",94:"UNICODE_TEXT",95:"PLUS",96:"EQUALS",97:"MULT",98:"TAG_START",99:"TAG_END",100:"QUOTE"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,4],[4,4],[4,4],[4,4],[4,4],[19,2],[19,1],[20,1],[20,1],[20,1],[14,1],[14,1],[14,2],[22,2],[22,2],[22,1],[22,1],[21,2],[21,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,5],[7,4],[24,1],[24,1],[24,1],[23,3],[23,1],[33,4],[33,5],[33,6],[33,7],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,1],[33,2],[35,1],[35,2],[44,1],[44,1],[44,1],[44,1],[34,2],[34,3],[34,3],[34,1],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[48,3],[31,1],[31,2],[31,1],[68,1],[68,2],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[76,1],[76,2],[27,5],[27,5],[28,5],[29,5],[29,7],[29,5],[29,7],[25,5],[25,5],[26,5],[26,5],[82,3],[79,1],[79,3],[84,1],[84,2],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[69,1],[69,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[77,1],[77,1],[77,1],[77,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 2:this.$=[];break;case 3:a[u]!==[]&&a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 57:case 59:case 60:case 92:case 94:case 95:case 108:this.$=a[u];break;case 11:r.setDirection(a[u-1]),this.$=a[u-1];break;case 12:r.setDirection("LR"),this.$=a[u-1];break;case 13:r.setDirection("RL"),this.$=a[u-1];break;case 14:r.setDirection("BT"),this.$=a[u-1];break;case 15:r.setDirection("TB"),this.$=a[u-1];break;case 30:this.$=a[u-1];break;case 31:case 32:case 33:case 34:case 35:this.$=[];break;case 36:this.$=r.addSubGraph(a[u-1],a[u-3]);break;case 37:this.$=r.addSubGraph(a[u-1],void 0);break;case 41:r.addLink(a[u-2],a[u],a[u-1]),this.$=[a[u-2],a[u]];break;case 42:this.$=[a[u]];break;case 43:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"square");break;case 44:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"square");break;case 45:this.$=a[u-5],r.addVertex(a[u-5],a[u-2],"circle");break;case 46:this.$=a[u-6],r.addVertex(a[u-6],a[u-3],"circle");break;case 47:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"ellipse");break;case 48:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"ellipse");break;case 49:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"round");break;case 50:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"round");break;case 51:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"diamond");break;case 52:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"diamond");break;case 53:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"odd");break;case 54:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"odd");break;case 55:this.$=a[u],r.addVertex(a[u]);break;case 56:this.$=a[u-1],r.addVertex(a[u-1]);break;case 58:case 93:case 96:case 109:this.$=a[u-1]+""+a[u];break;case 61:this.$="v";break;case 62:this.$="-";break;case 63:a[u-1].text=a[u],this.$=a[u-1];break;case 64:case 65:a[u-2].text=a[u-1],this.$=a[u-2];break;case 66:this.$=a[u];break;case 67:this.$={type:"arrow",stroke:"normal",text:a[u-1]};break;case 68:this.$={type:"arrow_circle",stroke:"normal",text:a[u-1]};break;case 69:this.$={type:"arrow_cross",stroke:"normal",text:a[u-1]};break;case 70:this.$={type:"arrow_open",stroke:"normal",text:a[u-1]};break;case 71:this.$={type:"arrow",stroke:"dotted",text:a[u-1]};break;case 72:this.$={type:"arrow_circle",stroke:"dotted",text:a[u-1]};break;case 73:this.$={type:"arrow_cross",stroke:"dotted",text:a[u-1]};break;case 74:this.$={type:"arrow_open",stroke:"dotted",text:a[u-1]};break;case 75:this.$={type:"arrow",stroke:"thick",text:a[u-1]};break;case 76:this.$={type:"arrow_circle",stroke:"thick",text:a[u-1]};break;case 77:this.$={type:"arrow_cross",stroke:"thick",text:a[u-1]};break;case 78:this.$={type:"arrow_open",stroke:"thick",text:a[u-1]};break;case 79:this.$={type:"arrow",stroke:"normal"};break;case 80:this.$={type:"arrow_circle",stroke:"normal"};break;case 81:this.$={type:"arrow_cross",stroke:"normal"};break;case 82:this.$={type:"arrow_open",stroke:"normal"};break;case 83:this.$={type:"arrow",stroke:"dotted"};break;case 84:this.$={type:"arrow_circle",stroke:"dotted"};break;case 85:this.$={type:"arrow_cross",stroke:"dotted"};break;case 86:this.$={type:"arrow_open",stroke:"dotted"};break;case 87:this.$={type:"arrow",stroke:"thick"};break;case 88:this.$={type:"arrow_circle",stroke:"thick"};break;case 89:this.$={type:"arrow_cross",stroke:"thick"};break;case 90:this.$={type:"arrow_open",stroke:"thick"};break;case 91:this.$=a[u-1];break;case 110:case 111:this.$=a[u-4],r.addClass(a[u-2],a[u]);break;case 112:this.$=a[u-4],r.setClass(a[u-2],a[u]);break;case 113:this.$=a[u-4],r.setClickEvent(a[u-2],a[u],void 0,void 0);break;case 114:this.$=a[u-6],r.setClickEvent(a[u-4],a[u-2],void 0,a[u]);break;case 115:this.$=a[u-4],r.setClickEvent(a[u-2],void 0,a[u],void 0);break;case 116:this.$=a[u-6],r.setClickEvent(a[u-4],void 0,a[u-2],a[u]);break;case 117:this.$=a[u-4],r.addVertex(a[u-2],void 0,void 0,a[u]);break;case 118:case 119:case 120:this.$=a[u-4],r.updateLink(a[u-2],a[u]);break;case 122:this.$=[a[u]];break;case 123:a[u-2].push(a[u]),this.$=a[u-2];break;case 125:this.$=a[u-1]+a[u]}},table:[{3:1,4:2,9:n,10:r,12:i},{1:[3]},e(a,u,{5:6}),{4:7,9:n,10:r,12:i},{4:8,9:n,10:r,12:i},{10:[1,9]},{1:[2,1],6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(a,[2,9]),e(a,[2,10]),{13:[1,46],15:[1,47],16:[1,48],17:[1,49],18:[1,50]},e(F,[2,3]),e(F,[2,4]),e(F,[2,5]),e(F,[2,6]),e(F,[2,7]),e(F,[2,8]),{8:B,9:L,11:N,24:51},{8:B,9:L,11:N,24:55},{8:B,9:L,11:N,24:56},{8:B,9:L,11:N,24:57},{8:B,9:L,11:N,24:58},{8:B,9:L,11:N,24:59},{8:B,9:L,10:O,11:N,12:I,13:R,15:P,16:q,17:j,18:U,24:61,30:Y,31:60,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(et,[2,42],{34:86,47:87,50:[1,88],51:[1,91],52:[1,92],53:[1,93],54:[1,94],55:[1,89],56:[1,95],57:[1,96],58:[1,97],59:[1,98],60:[1,90],61:[1,99],62:[1,100],63:[1,101],64:[1,102]}),{10:[1,103]},{10:[1,104]},{10:[1,105]},{10:[1,106]},{10:[1,107]},e(nt,[2,55],{45:32,21:113,44:114,10:rt,13:h,15:[1,112],18:f,36:[1,108],38:[1,109],40:[1,110],42:[1,111],46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T}),e(it,[2,57]),e(it,[2,59]),e(it,[2,60]),e(it,[2,61]),e(it,[2,62]),e(at,[2,150]),e(at,[2,151]),e(at,[2,152]),e(at,[2,153]),e(at,[2,154]),e(at,[2,155]),e(at,[2,156]),e(at,[2,157]),e(at,[2,158]),e(at,[2,159]),e(at,[2,160]),{8:ut,9:ot,10:rt,14:116,21:119},{8:ut,9:ot,10:rt,14:120,21:119},{8:ut,9:ot,10:rt,14:121,21:119},{8:ut,9:ot,10:rt,14:122,21:119},{8:ut,9:ot,10:rt,14:123,21:119},e(F,[2,30]),e(F,[2,38]),e(F,[2,39]),e(F,[2,40]),e(F,[2,31]),e(F,[2,32]),e(F,[2,33]),e(F,[2,34]),e(F,[2,35]),{8:B,9:L,10:O,11:N,12:I,13:R,15:P,16:q,17:j,18:U,24:124,30:Y,32:z,45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(st,u,{5:126}),e(ct,[2,92]),e(ct,[2,94]),e(ct,[2,139]),e(ct,[2,140]),e(ct,[2,141]),e(ct,[2,142]),e(ct,[2,143]),e(ct,[2,144]),e(ct,[2,145]),e(ct,[2,146]),e(ct,[2,147]),e(ct,[2,148]),e(ct,[2,149]),e(ct,[2,97]),e(ct,[2,98]),e(ct,[2,99]),e(ct,[2,100]),e(ct,[2,101]),e(ct,[2,102]),e(ct,[2,103]),e(ct,[2,104]),e(ct,[2,105]),e(ct,[2,106]),e(ct,[2,107]),{13:h,18:f,33:127,35:29,44:30,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(lt,[2,66],{48:128,49:[1,129],65:[1,130]}),{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:131,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:132,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:133,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(ht,[2,79]),e(ht,[2,80]),e(ht,[2,81]),e(ht,[2,82]),e(ht,[2,83]),e(ht,[2,84]),e(ht,[2,85]),e(ht,[2,86]),e(ht,[2,87]),e(ht,[2,88]),e(ht,[2,89]),e(ht,[2,90]),{13:h,18:f,35:134,44:30,45:32,46:p,80:[1,135],81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{78:[1,136],81:[1,137]},{13:h,18:f,35:139,44:30,45:32,46:p,78:[1,138],81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{13:h,18:f,35:140,44:30,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{13:h,18:f,35:141,44:30,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:142,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:144,32:z,38:[1,143],45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:145,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:146,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:147,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(nt,[2,56]),e(it,[2,58]),e(nt,[2,29],{21:148,10:rt}),e(a,[2,11]),e(a,[2,21]),e(a,[2,22]),{9:[1,149]},e(a,[2,12]),e(a,[2,13]),e(a,[2,14]),e(a,[2,15]),e(st,u,{5:150}),e(ct,[2,93]),{6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,32:[1,151],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(et,[2,41]),e(lt,[2,63],{10:[1,152]}),{10:[1,153]},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:154,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,45:71,46:V,50:$,51:[1,155],52:[1,156],53:[1,157],54:[1,158],60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,45:71,46:V,50:$,56:[1,159],57:[1,160],58:[1,161],59:[1,162],60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,45:71,46:V,50:$,60:G,61:[1,163],62:[1,164],63:[1,165],64:[1,166],66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:[1,167],13:h,18:f,44:114,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:[1,168]},{10:[1,169]},{10:[1,170]},{10:[1,171]},{10:[1,172],13:h,18:f,44:114,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:[1,173],13:h,18:f,44:114,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:[1,174],13:h,18:f,44:114,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,37:[1,175],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,31:176,32:z,45:71,46:V,50:$,60:G,66:62,67:H,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,39:[1,177],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,41:[1,178],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,43:[1,179],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,37:[1,180],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(nt,[2,28]),e(a,[2,23]),{6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,32:[1,181],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(F,[2,37]),e(lt,[2,65]),e(lt,[2,64]),{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,45:71,46:V,50:$,60:G,65:[1,182],66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(lt,[2,67]),e(lt,[2,68]),e(lt,[2,69]),e(lt,[2,70]),e(lt,[2,71]),e(lt,[2,72]),e(lt,[2,73]),e(lt,[2,74]),e(lt,[2,75]),e(lt,[2,76]),e(lt,[2,77]),e(lt,[2,78]),{10:ft,46:dt,71:pt,79:183,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:197,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:198,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:199,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:200,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{10:ft,46:dt,71:pt,79:201,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},{13:h,18:f,35:202,44:30,45:32,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},{13:h,18:f,35:203,44:30,45:32,46:p,67:[1,204],81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(nt,[2,43],{21:205,10:rt}),{10:O,12:I,13:R,15:P,16:q,17:j,18:U,30:Y,32:z,39:[1,206],45:71,46:V,50:$,60:G,66:125,70:74,71:W,72:Z,73:X,74:J,75:K,77:64,78:Q,81:_,83:tt,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T},e(nt,[2,49],{21:207,10:rt}),e(nt,[2,47],{21:208,10:rt}),e(nt,[2,51],{21:209,10:rt}),e(nt,[2,53],{21:210,10:rt}),e(F,[2,36]),e([10,13,18,46,81,85,87,88,90,91,93,94,95,96,97],[2,91]),e(et,[2,117],{85:At}),e(Et,[2,122],{86:212,10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,87:vt,88:bt,89:_t,90:xt,91:wt}),e(kt,[2,124]),e(kt,[2,126]),e(kt,[2,127]),e(kt,[2,128]),e(kt,[2,129]),e(kt,[2,130]),e(kt,[2,131]),e(kt,[2,132]),e(kt,[2,133]),e(kt,[2,134]),e(kt,[2,135]),e(kt,[2,136]),e(et,[2,118],{85:At}),e(et,[2,119],{85:At}),e(et,[2,120],{85:At}),e(et,[2,110],{85:At}),e(et,[2,111],{85:At}),e(et,[2,112],{45:32,44:114,13:h,18:f,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T}),e(et,[2,113],{45:32,44:114,10:[1,213],13:h,18:f,46:p,81:_,85:x,87:w,88:A,90:E,91:k,93:D,94:C,95:M,96:S,97:T}),e(et,[2,115],{10:[1,214]}),e(nt,[2,44]),{39:[1,215]},e(nt,[2,50]),e(nt,[2,48]),e(nt,[2,52]),e(nt,[2,54]),{10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,84:216,86:185,87:vt,88:bt,89:_t,90:xt,91:wt},e(kt,[2,125]),{67:[1,217]},{67:[1,218]},e(nt,[2,45],{21:219,10:rt}),e(Et,[2,123],{86:212,10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,87:vt,88:bt,89:_t,90:xt,91:wt}),e(et,[2,114]),e(et,[2,116]),e(nt,[2,46])],defaultActions:{},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},Ct=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:this.begin("string");break;case 2:this.popState();break;case 3:return"STR";case 4:return 71;case 5:return 78;case 6:return 72;case 7:return 73;case 8:return 74;case 9:return 75;case 10:return 12;case 11:return 30;case 12:return 32;case 13:return 13;case 14:return 13;case 15:return 13;case 16:return 13;case 17:return 13;case 18:return 13;case 19:return 81;case 20:return 90;case 21:return 88;case 22:return 8;case 23:return 85;case 24:return 97;case 25:return 16;case 26:return 15;case 27:return 17;case 28:return 18;case 29:return 53;case 30:return 51;case 31:return 52;case 32:return 54;case 33:return 58;case 34:return 56;case 35:return 57;case 36:return 59;case 37:return 58;case 38:return 56;case 39:return 57;case 40:return 59;case 41:return 63;case 42:return 61;case 43:return 62;case 44:return 64;case 45:return 50;case 46:return 55;case 47:return 60;case 48:return 40;case 49:return 41;case 50:return 46;case 51:return 91;case 52:return 95;case 53:return 83;case 54:return 96;case 55:return 96;case 56:return 87;case 57:return 93;case 58:return 94;case 59:return 65;case 60:return 38;case 61:return 39;case 62:return 36;case 63:return 37;case 64:return 42;case 65:return 43;case 66:return 100;case 67:return 9;case 68:return 10;case 69:return 11}},rules:[/^(?:%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:v\b)/,/^(?:\s*--[x]\s*)/,/^(?:\s*-->\s*)/,/^(?:\s*--[o]\s*)/,/^(?:\s*---\s*)/,/^(?:\s*-\.-[x]\s*)/,/^(?:\s*-\.->\s*)/,/^(?:\s*-\.-[o]\s*)/,/^(?:\s*-\.-\s*)/,/^(?:\s*.-[x]\s*)/,/^(?:\s*\.->\s*)/,/^(?:\s*\.-[o]\s*)/,/^(?:\s*\.-\s*)/,/^(?:\s*==[x]\s*)/,/^(?:\s*==>\s*)/,/^(?:\s*==[o]\s*)/,/^(?:\s*==[\=]\s*)/,/^(?:\s*--\s*)/,/^(?:\s*-\.\s*)/,/^(?:\s*==\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[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])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:\n+)/,/^(?:\s)/,/^(?:$)/],conditions:{string:{rules:[2,3],inclusive:!1},INITIAL:{rules:[0,1,4,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,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69],inclusive:!0}}};return t}();return Dt.lexer=Ct,t.prototype=Dt,Dt.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("_process"))},{_process:3,fs:1,path:2}],120:[function(t,e,n){(function(e){"use strict";var r=t("moment"),i=t("../../logger"),a=new i.Log,u="",o="",s=[],c=[],l="";n.clear=function(){s=[],c=[],l="",o="",g=0,h=void 0,f=void 0,b=[]},n.setDateFormat=function(t){u=t},n.getDateFormat=function(){return u},n.setTitle=function(t){o=t},n.getTitle=function(){return o},n.addSection=function(t){l=t,s.push(t)},n.getTasks=function(){for(var t=x(),e=10,n=0;!t&&e>n;)t=x(),n++;return c=b};var h,f,d=function(t,e,i){i=i.trim();var u=/^after\s+([\d\w\-]+)/,o=u.exec(i.trim());if(null!==o){var s=n.findTaskById(o[1]);if("undefined"==typeof s){var c=new Date;return c.setHours(0,0,0,0),c}return s.endTime}return r(i,e.trim(),!0).isValid()?r(i,e.trim(),!0).toDate():(a.debug("Invalid date:"+i),a.debug("With date format:"+e.trim()),new Date)},p=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])/,u=a.exec(n.trim());if(null!==u){switch(u[2]){case"s":i.add(u[1],"seconds");break;case"m":i.add(u[1],"minutes");break;case"h":i.add(u[1],"hours");break;case"d":i.add(u[1],"days");break;case"w":i.add(u[1],"weeks")}return i.toDate()}return i.toDate()},g=0,y=function(t){return"undefined"==typeof t?(g+=1,"task"+g):t},m=function(t,e){var r;r=":"===e.substr(0,1)?e.substr(1,e.length):e;for(var i=r.split(","),a={},u=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 s;for(s=0;sn-e?n+i+1.5*u.sidePadding>o?e+r-5:n+r+5:(n-e)/2+e+r}).attr("y",function(t,r){return r*e+u.barHeight/2+(u.fontSize/2-2)+n}).attr("text-height",i).attr("class",function(t){for(var e=w(t.startTime),n=w(t.endTime),r=this.getBBox().width,i=0,a=0;an-e?n+r+1.5*u.sidePadding>o?"taskTextOutsideLeft taskTextOutside"+i+" "+s:"taskTextOutsideRight taskTextOutside"+i+" "+s:"taskText taskText"+i+" "+s})}function l(t,e,n,a){var o,s=[[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["h1 %I:%M",function(t){return t.getMinutes()}]],c=[["%Y",function(){return!0}]],l=[["%I:%M",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}]];"undefined"!=typeof u.axisFormatter&&(l=[],u.axisFormatter.forEach(function(t){var e=[];e[0]=t[0],e[1]=t[1],l.push(e)})),o=s.concat(l).concat(c);var h=i.svg.axis().scale(w).orient("bottom").tickSize(-a+e+u.gridLineStartPadding,0,0).tickFormat(i.time.format.multi(o));r>7&&230>r&&(h=h.ticks(i.time.monday.range)),b.append("g").attr("class","grid").attr("transform","translate("+t+", "+(a-50)+")").call(h).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em")}function h(t,e){for(var n=[],r=0,i=0;i0))return i[1]*t/2+e;for(var u=0;a>u;u++)return r+=n[a-1][1],i[1]*t/2+r*t+e}).attr("class",function(t){for(var e=0;er;++r)e.hasOwnProperty(t[r])||(e[t[r]]=!0,n.push(t[r]));return n}function p(t){for(var e=t.length,n={};e;)n[t[--e]]=(n[t[e]]||0)+1;return n}function g(t,e){return p(e)[t]||0}n.yy.clear(),n.parse(t);var y=document.getElementById(e);o=y.parentElement.offsetWidth,"undefined"==typeof o&&(o=1200),"undefined"!=typeof u.useWidth&&(o=u.useWidth);var m=n.yy.getTasks(),v=m.length*(u.barHeight+u.barGap)+2*u.topPadding;y.setAttribute("height","100%"),y.setAttribute("viewBox","0 0 "+o+" "+v);var b=i.select("#"+e),_=i.min(m,function(t){return t.startTime}),x=i.max(m,function(t){return t.endTime}),w=i.time.scale().domain([i.min(m,function(t){return t.startTime}),i.max(m,function(t){return t.endTime})]).rangeRound([0,o-150]),A=[];r=a.duration(x-_).asDays();for(var E=0;El&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},s=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,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),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;ae[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 10;case 1:break;case 2:break;case 3:break;case 4:return 4;case 5:return 11;case 6:return"date";case 7:return 12;case 8:return 13;case 9:return 14;case 10:return 15;case 11:return":";case 12:return 6;case 13:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\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:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return t}();return o.lexer=s,t.prototype=o,o.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("_process"))},{_process:3,fs:1,path:2}],123:[function(t,e,n){(function(r){"use strict";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=[2,2],r=[1,5],i=[1,7],a=[1,8],u=[1,11],o=[1,12],s=[1,13],c=[1,14],l=[1,16],h=[1,17],f=[1,7,9,10,14,16,18,19,20,21,22,33],d=[7,9,10,14,16,18,19,20,22,33],p=[1,51],g={trace:function(){},yy:{},symbols_:{error:2,start:3,SD:4,document:5,line:6,SPACE:7,statement:8,NL:9,participant:10,actor:11,signal:12,note_statement:13,title:14,text:15,loop:16,restOfLine:17,end:18,opt:19,alt:20,"else":21,note:22,placement:23,text2:24,over:25,actor_pair:26,spaceList:27,",":28,left_of:29,right_of:30,signaltype:31,actors:32,ACTOR:33,SOLID_OPEN_ARROW:34,DOTTED_OPEN_ARROW:35,SOLID_ARROW:36,DOTTED_ARROW:37,SOLID_CROSS:38,DOTTED_CROSS:39,TXT:40,$accept:0,$end:1},terminals_:{2:"error",4:"SD",7:"SPACE",9:"NL",10:"participant",14:"title",15:"text",16:"loop",17:"restOfLine",18:"end",19:"opt",20:"alt",21:"else",22:"note",25:"over",28:",",29:"left_of",30:"right_of",33:"ACTOR",34:"SOLID_OPEN_ARROW",35:"DOTTED_OPEN_ARROW",36:"SOLID_ARROW",37:"DOTTED_ARROW",38:"SOLID_CROSS",39:"DOTTED_CROSS",40:"TXT"},productions_:[0,[3,2],[5,0],[5,2],[6,2],[6,1],[6,1],[8,3],[8,2],[8,2],[8,4],[8,4],[8,4],[8,7],[13,4],[13,4],[27,2],[27,1],[26,3],[26,1],[23,1],[23,1],[12,4],[32,2],[32,1],[11,1],[31,1],[31,1],[31,1],[31,1],[31,1],[31,1],[24,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:return r.apply(a[u]),a[u];case 2:this.$=[];break;case 3:a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 5:this.$=a[u];break;case 6:this.$=[];break;case 7:this.$=a[u-1];break;case 11:a[u-1].unshift({type:"loopStart",loopText:a[u-2],signalType:r.LINETYPE.LOOP_START}),a[u-1].push({type:"loopEnd",loopText:a[u-2],signalType:r.LINETYPE.LOOP_END}),this.$=a[u-1];break;case 12:a[u-1].unshift({type:"optStart",optText:a[u-2],signalType:r.LINETYPE.OPT_START}),a[u-1].push({type:"optEnd",optText:a[u-2],signalType:r.LINETYPE.OPT_END}),this.$=a[u-1];break;case 13:a[u-4].unshift({type:"altStart",altText:a[u-5],signalType:r.LINETYPE.ALT_START}),a[u-4].push({type:"else",altText:a[u-2],signalType:r.LINETYPE.ALT_ELSE}),a[u-4]=a[u-4].concat(a[u-1]),a[u-4].push({type:"altEnd",signalType:r.LINETYPE.ALT_END}),this.$=a[u-4];break;case 14:this.$=[a[u-1],{type:"addNote",placement:a[u-2],actor:a[u-1].actor,text:a[u]}];break;case 15:a[u-2]=[].concat(a[u-1],a[u-1]).slice(0,2),a[u-2][0]=a[u-2][0].actor,a[u-2][1]=a[u-2][1].actor,this.$=[a[u-1],{type:"addNote",placement:r.PLACEMENT.OVER,actor:a[u-2].slice(0,2),text:a[u]}];break;case 18:this.$=[a[u-2],a[u]];break;case 19:this.$=a[u];break;case 20:this.$=r.PLACEMENT.LEFTOF;break;case 21:this.$=r.PLACEMENT.RIGHTOF;break;case 22:this.$=[a[u-3],a[u-1],{type:"addMessage",from:a[u-3].actor,to:a[u-1].actor,signalType:a[u-2],msg:a[u]}];break;case 25:this.$={type:"addActor",actor:a[u]};break;case 26:this.$=r.LINETYPE.SOLID_OPEN;break;case 27:this.$=r.LINETYPE.DOTTED_OPEN;break;case 28:this.$=r.LINETYPE.SOLID;break;case 29:this.$=r.LINETYPE.DOTTED;break;case 30:this.$=r.LINETYPE.SOLID_CROSS;break;case 31:this.$=r.LINETYPE.DOTTED_CROSS;break;case 32: +this.$=a[u].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e([1,7,9,10,14,16,19,20,22,33],n,{5:3}),{1:[2,1],6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,22:l,33:h},e(f,[2,3]),{8:18,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,22:l,33:h},e(f,[2,5]),e(f,[2,6]),{11:19,33:h},{9:[1,20]},{9:[1,21]},{7:[1,22]},{17:[1,23]},{17:[1,24]},{17:[1,25]},{31:26,34:[1,27],35:[1,28],36:[1,29],37:[1,30],38:[1,31],39:[1,32]},{23:33,25:[1,34],29:[1,35],30:[1,36]},e([9,28,34,35,36,37,38,39,40],[2,25]),e(f,[2,4]),{9:[1,37]},e(f,[2,8]),e(f,[2,9]),{15:[1,38]},e(d,n,{5:39}),e(d,n,{5:40}),e([7,9,10,14,16,19,20,21,22,33],n,{5:41}),{11:42,33:h},{33:[2,26]},{33:[2,27]},{33:[2,28]},{33:[2,29]},{33:[2,30]},{33:[2,31]},{11:43,33:h},{11:45,26:44,33:h},{33:[2,20]},{33:[2,21]},e(f,[2,7]),{9:[1,46]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,47],19:s,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,48],19:s,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,21:[1,49],22:l,33:h},{24:50,40:p},{24:52,40:p},{24:53,40:p},{28:[1,54],40:[2,19]},e(f,[2,10]),e(f,[2,11]),e(f,[2,12]),{17:[1,55]},{9:[2,22]},{9:[2,32]},{9:[2,14]},{9:[2,15]},{11:56,33:h},e(d,n,{5:57}),{40:[2,18]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,58],19:s,20:c,22:l,33:h},e(f,[2,13])],defaultActions:{27:[2,26],28:[2,27],29:[2,28],30:[2,29],31:[2,30],32:[2,31],35:[2,20],36:[2,21],50:[2,22],51:[2,32],52:[2,14],53:[2,15],56:[2,18]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,x,w,A,E,k,D,C=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},M={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),x=a[_]&&a[_][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[_])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,b?(v=b,b=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[x[1]][1],M.$=r[r.length-E],M._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(M._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(M,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;E&&(n=n.slice(0,-1*E*2),r=r.slice(0,-1*E),i=i.slice(0,-1*E)),n.push(this.productions_[x[1]][0]),r.push(M.$),i.push(M._$),k=a[n[n.length-2]][n[n.length-1]],n.push(k);break;case 3:return!0}}return!0}},y=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,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),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;ae[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:break;case 2:break;case 3:break;case 4:break;case 5:return 10;case 6:return this.begin("LINE"),16;case 7:return this.begin("LINE"),19;case 8:return this.begin("LINE"),20;case 9:return this.begin("LINE"),21;case 10:return this.popState(),17;case 11:return 18;case 12:return 29;case 13:return 30;case 14:return 25;case 15:return 22;case 16:return 14;case 17:return 4;case 18:return 28;case 19:return 9;case 20:return 33;case 21:return 36;case 22:return 37;case 23:return 34;case 24:return 35;case 25:return 38;case 26:return 39;case 27:return 40;case 28:return 9;case 29:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:participant\b)/i,/^(?:loop\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\->:\n,;]+)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[2,3,10],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29],inclusive:!0}}};return t}();return g.lexer=y,t.prototype=g,g.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("_process"))},{_process:3,fs:1,path:2}],124:[function(t,e,n){(function(e){"use strict";var r={},i=[],a=[],u=[],o=t("../../logger"),s=new o.Log;n.addActor=function(t,e,n){r[t]={name:e,description:n},i.push(t)},n.addMessage=function(t,e,n,r){a.push({from:t,to:e,message:n,answer:r})},n.addSignal=function(t,e,n,r){s.debug("Adding message from="+t+" to="+e+" message="+n+" type="+r),a.push({from:t,to:e,message:n,type:r})},n.getMessages=function(){return a},n.getActors=function(){return r},n.getActor=function(t){return r[t]},n.getActorKeys=function(){return Object.keys(r)},n.clear=function(){r={},a=[]},n.LINETYPE={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},n.ARROWTYPE={FILLED:0,OPEN:1},n.PLACEMENT={LEFTOF:0,RIGHTOF:1,OVER:2},n.addNote=function(t,e,r){var i={actor:t,placement:e,message:r},o=[].concat(t,t);u.push(i),a.push({from:o[0],to:o[1],message:r,type:n.LINETYPE.NOTE,placement:e})},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)},n.apply=function(t){if(t instanceof Array)t.forEach(function(t){n.apply(t)});else switch(t.type){case"addActor":n.addActor(t.actor,t.actor,t.actor);break;case"addNote":n.addNote(t.actor,t.placement,t.text);break;case"addMessage":n.addSignal(t.from,t.to,t.msg,t.signalType);break;case"loopStart":n.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"optStart":n.addSignal(void 0,void 0,t.optText,t.signalType);break;case"optEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"altStart":n.addSignal(void 0,void 0,t.altText,t.signalType);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)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":127}],125:[function(t,e,n){"use strict";var r=t("./parser/sequenceDiagram").parser;r.yy=t("./sequenceDb");var i=t("./svgDraw"),a=t("../../d3"),u=t("../../logger"),o=new u.Log,s={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,u=0;this.list.forEach(function(o){u++;var c=a.list.length-u+1;a.updateVal(o,"startx",t-c*s.boxMargin,Math.min),a.updateVal(o,"starty",e-c*s.boxMargin,Math.min),a.updateVal(o,"stopx",r+c*s.boxMargin,Math.max),a.updateVal(o,"stopy",i+c*s.boxMargin,Math.max),a.updateVal(n.bounds.data,"startx",t-c*s.boxMargin,Math.min),a.updateVal(n.bounds.data,"starty",e-c*s.boxMargin,Math.min),a.updateVal(n.bounds.data,"stopx",r+c*s.boxMargin,Math.max),a.updateVal(n.bounds.data,"stopy",i+c*s.boxMargin,Math.max)})},insert:function(t,e,r,i){var a,u,o,s;a=Math.min(t,r),o=Math.max(t,r),u=Math.min(e,i),s=Math.max(e,i),this.updateVal(n.bounds.data,"startx",a,Math.min),this.updateVal(n.bounds.data,"starty",u,Math.min),this.updateVal(n.bounds.data,"stopx",o,Math.max),this.updateVal(n.bounds.data,"stopy",s,Math.max),this.updateLoops(a,u,o,s)},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 c=function(t,e,r,a,u){var o=i.getNoteRect();o.x=e,o.y=r,o.width=u||s.width,o["class"]="note";var c=t.append("g"),l=i.drawRect(c,o),h=i.getTextObj();h.x=e-4,h.y=r-13,h.textMargin=s.noteMargin,h.dy="1em",h.text=a.message,h["class"]="noteText";var f=i.drawText(c,h,o.width-s.noteMargin),d=f[0][0].getBBox().height;!u&&d>s.width?(f.remove(),c=t.append("g"),f=i.drawText(c,h,2*o.width-s.noteMargin),d=f[0][0].getBBox().height,l.attr("width",2*o.width),n.bounds.insert(e,r,e+2*o.width,r+2*s.noteMargin+d)):n.bounds.insert(e,r,e+o.width,r+2*s.noteMargin+d),l.attr("height",d+2*s.noteMargin),n.bounds.bumpVerticalPos(d+2*s.noteMargin)},l=function(t,e,i,a,u){var o,s=t.append("g"),c=e+(i-e)/2,l=s.append("text").attr("x",c).attr("y",a-7).style("text-anchor","middle").attr("class","messageText").text(u.message);o="undefined"!=typeof l[0][0].getBBox?l[0][0].getBBox().width:l[0][0].getBoundingClientRect();var h;if(e===i){h=s.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=s.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());u.type===r.yy.LINETYPE.DOTTED||u.type===r.yy.LINETYPE.DOTTED_CROSS||u.type===r.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0");var d=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;d=d.replace(/\(/g,"\\("),d=d.replace(/\)/g,"\\)"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(u.type===r.yy.LINETYPE.SOLID||u.type===r.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+d+"#arrowhead)"),(u.type===r.yy.LINETYPE.SOLID_CROSS||u.type===r.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+d+"#crosshead)")};e.exports.drawActors=function(t,e,r,a){var u;for(u=0;u/gi," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.attr("fill",e.fill),"undefined"!=typeof e["class"]&&i.attr("class",e["class"]);var a=i.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(r),"undefined"!=typeof i.textwrap&&i.textwrap({x:e.x,y:e.y,width:n,height:1800},e.textMargin),i},n.drawLabel=function(t,e){var r=n.getNoteRect();r.x=e.x,r.y=e.y,r.width=50,r.height=20,r.fill="#526e52",r.stroke="none",r["class"]="labelBox",n.drawRect(t,r),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,e.fill="white",n.drawText(t,e)};var r=-1;n.drawActor=function(t,e,i,a,u){var o=e+u.width/2,s=t.append("g");0===i&&(r++,s.append("line").attr("id","actor"+r).attr("x1",o).attr("y1",5).attr("x2",o).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var c=n.getNoteRect();c.x=e,c.y=i,c.fill="#eaeaea",c.width=u.width,c.height=u.height,c["class"]="actor",c.rx=3,c.ry=3,n.drawRect(s,c),s.append("text").attr("x",o).attr("y",i+u.height/2+5).attr("class","actor").style("text-anchor","middle").text(a)},n.drawLoop=function(t,e,r,i){var a=t.append("g"),u=function(t,e,n,r){a.append("line").attr("x1",t).attr("y1",e).attr("x2",n).attr("y2",r).attr("stroke-width",2).attr("stroke","#526e52").attr("class","loopLine")};u(e.startx,e.starty,e.stopx,e.starty),u(e.stopx,e.starty,e.stopx,e.stopy),u(e.startx,e.stopy,e.stopx,e.stopy),u(e.startx,e.starty,e.startx,e.stopy),"undefined"!=typeof e.elsey&&u(e.startx,e.elsey,e.stopx,e.elsey);var o=n.getTextObj();o.text=r,o.x=e.startx,o.y=e.starty,o.labelMargin=1.5*i.boxMargin,o["class"]="labelText",o.fill="white",n.drawLabel(a,o),o=n.getTextObj(),o.text="[ "+e.title+" ]",o.x=e.startx+(e.stopx-e.startx)/2,o.y=e.starty+1.5*i.boxMargin,o.anchor="middle",o["class"]="loopText",n.drawText(a,o),"undefined"!=typeof e.elseText&&(o.text="[ "+e.elseText+" ]",o.y=e.elsey+1.5*i.boxMargin,n.drawText(a,o))},n.insertArrowHead=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")},n.insertArrowCrossHead=function(t){var e=t.append("defs"),n=e.append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);n.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"),n.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")},n.getTextObj=function(){var t={x:0,y:0,fill:"black","text-anchor":"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0};return t},n.getNoteRect=function(){var t={x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0};return t}},{}],127:[function(t,e,n){"use strict";function r(t){var e=t.getUTCHours(),n=t.getUTCMinutes(),r=t.getSeconds(),i=t.getMilliseconds();10>e&&(e="0"+e),10>n&&(n="0"+n),10>r&&(r="0"+r),100>i&&(i="0"+i),10>i&&(i="00"+i);var a=e+":"+n+":"+r+" ("+i+")";return a}function i(t){this.level=t,this.log=function(t,e){var n=this.level;return"undefined"==typeof n&&(n=u),e>=n&&"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log("["+r(new Date)+"] "+t):void 0},this.trace=function(t){this.log(t,a.trace)},this.debug=function(t){this.log(t,a.debug)},this.info=function(t){this.log(t,a.info)},this.warn=function(t){this.log(t,a.warn)},this.error=function(t){this.log(t,a.error)}}var a={debug:1,info:2,warn:3,error:4,fatal:5,"default":5},u=a.error;n.setLogLevel=function(t){u=t},n.Log=i},{}],128:[function(t,e,n){(function(r){"use strict";var i=t("./logger"),a=new i.Log,u=t("./mermaidAPI"),o=0,s=t("he");e.exports.mermaidAPI=u;var c=function(){var t=u.getConfig();a.debug("Starting rendering diagrams");var e;arguments.length>=2?("undefined"!=typeof arguments[0]&&(r.mermaid.sequenceConfig=arguments[0]),e=arguments[1]):e=arguments[0];var n;"function"==typeof arguments[arguments.length-1]?(n=arguments[arguments.length-1],a.debug("Callback function found")):"undefined"!=typeof t.mermaid&&("function"==typeof t.mermaid.callback?(n=t.mermaid.callback,a.debug("Callback function found")):a.debug("No Callback function found")),e=void 0===e?document.querySelectorAll(".mermaid"):"string"==typeof e?document.querySelectorAll(e):e instanceof Node?[e]:e;var i;"undefined"!=typeof mermaid_config&&u.initialize(r.mermaid_config),a.debug("Start On Load before: "+r.mermaid.startOnLoad),"undefined"!=typeof r.mermaid.startOnLoad&&(a.debug("Start On Load inner: "+r.mermaid.startOnLoad),u.initialize({startOnLoad:r.mermaid.startOnLoad})),"undefined"!=typeof r.mermaid.ganttConfig&&u.initialize({gantt:r.mermaid.ganttConfig});var c,l=function(t,e){h.innerHTML=t,"undefined"!=typeof n&&n(f),e(h)};for(i=0;i0&&(r+=n.selectorText+" { "+n.style.cssText+" }\n")}}catch(l){"undefined"!=typeof n&&i.warn('Invalid CSS selector "'+n.selectorText+'"',l)}var h="",f="";for(var d in e)e.hasOwnProperty(d)&&"undefined"!=typeof d&&("default"===d?(e["default"].styles instanceof Array&&(h+="#"+t.id.trim()+" .node>rect { "+e[d].styles.join("; ")+"; }\n"),e["default"].nodeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .node text { "+e[d].nodeLabelStyles.join("; ")+"; }\n"),e["default"].edgeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .edgeLabel text { "+e[d].edgeLabelStyles.join("; ")+"; }\n"),e["default"].clusterStyles instanceof Array&&(h+="#"+t.id.trim()+" .cluster rect { "+e[d].clusterStyles.join("; ")+"; }\n")):e[d].styles instanceof Array&&(f+="#"+t.id.trim()+" ."+d+">rect { "+e[d].styles.join("; ")+"; }\n"));if(""!==r||""!==h||""!==f){var p=document.createElement("style");p.setAttribute("type","text/css"),p.setAttribute("title","mermaid-svg-internal-css"),p.innerHTML="/* */\n",t.insertBefore(p,t.firstChild)}};n.cloneCssStyles=u},{"./logger":127}]},{},[128])(128)}); \ No newline at end of file diff --git a/dist/mermaid.slim.js b/dist/mermaid.slim.js index 0da0d62cb0..387ccd06b9 100644 --- a/dist/mermaid.slim.js +++ b/dist/mermaid.slim.js @@ -21552,7 +21552,7 @@ module.exports={ "chalk": "^0.5.1", "d3": "3.5.6", "dagre": "^0.7.4", - "dagre-d3": "~0.4.8", + "dagre-d3": "0.4.10", "he": "^0.5.0", "minimist": "^1.1.0", "mkdirp": "^0.5.0", @@ -22099,21 +22099,15 @@ module.exports = d3; },{"d3":"d3"}],108:[function(require,module,exports){ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var relations = []; -var classes = undefined; +var classes; var idCache; -if (typeof Map !== 'undefined') { - classes = new Map(); -} +classes = {}; + // Functions to be run after graph rendering var funs = []; /** @@ -22124,24 +22118,24 @@ var funs = []; * @param style */ exports.addClass = function (id) { - if (typeof classes.get(id) === 'undefined') { - classes.set(id, { + if (typeof classes[id] === 'undefined') { + classes[id] = { id: id, methods: [], members: [] - }); + }; } }; exports.clear = function () { relations = []; - classes.clear(); + classes = {}; }; module.exports.getClass = function (id) { - return classes.get(id); + return classes[id]; }; -module.exports.getClasses = function (id) { +module.exports.getClasses = function () { return classes; }; @@ -22158,7 +22152,7 @@ exports.addRelation = function (relation) { }; exports.addMembers = function (className, MembersArr) { - var theClass = classes.get(className); + var theClass = classes[className]; if (typeof MembersArr === 'string') { if (MembersArr.substr(-1) === ')') { theClass.methods.push(MembersArr); @@ -22196,29 +22190,17 @@ exports.relationType = { 'use strict'; -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - -var _dagre = require('dagre'); - -var dagre = _interopRequireWildcard(_dagre); - var cd = require('./parser/classDiagram').parser; var cDDb = require('./classDb'); cd.yy = cDDb; var d3 = require('../../d3'); - +var Logger = require('../../logger'); +var dagre = require('dagre'); var log = new Logger.Log(); var idCache; -if (typeof Map !== 'undefined') { - idCache = new Map(); -} +idCache = {}; + var classCnt = 0; var conf = { dividerMargin: 10, @@ -22228,39 +22210,19 @@ var conf = { // Todo optimize var getGraphId = function getGraphId(label) { - var _iteratorNormalCompletion = true; - var _didIteratorError = false; - var _iteratorError = undefined; + var keys = Object.keys(idCache); - try { - for (var _iterator = idCache[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { - var _step$value = _slicedToArray(_step.value, 2); - - var id = _step$value[0]; - var classInfo = _step$value[1]; - - if (classInfo.label === label) { - return id; - } - } - } catch (err) { - _didIteratorError = true; - _iteratorError = err; - } finally { - try { - if (!_iteratorNormalCompletion && _iterator['return']) { - _iterator['return'](); - } - } finally { - if (_didIteratorError) { - throw _iteratorError; - } + var i; + for (i = 0; i < keys.length; i++) { + if (idCache[keys[i]].label === label) { + return keys[i]; } } return undefined; }; +window.tunk = getGraphId; /** * Setup arrow head and define the marker. The result is appended to the svg. */ @@ -22390,34 +22352,34 @@ var drawClass = function drawClass(elem, classDef) { .attr('x', conf.padding).attr('y', titleHeight + conf.dividerMargin + conf.textHeight).attr('fill', 'white').attr('class', 'classText'); var isFirst = true; - var _iteratorNormalCompletion2 = true; - var _didIteratorError2 = false; - var _iteratorError2 = undefined; + var _iteratorNormalCompletion = true; + var _didIteratorError = false; + var _iteratorError = undefined; try { - for (var _iterator2 = classDef.members[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) { - var member = _step2.value; + for (var _iterator = classDef.members[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { + var member = _step.value; addTspan(members, member, isFirst); isFirst = false; } - - //console.warn(JSON.stringify(classDef)); } catch (err) { - _didIteratorError2 = true; - _iteratorError2 = err; + _didIteratorError = true; + _iteratorError = err; } finally { try { - if (!_iteratorNormalCompletion2 && _iterator2['return']) { - _iterator2['return'](); + if (!_iteratorNormalCompletion && _iterator['return']) { + _iterator['return'](); } } finally { - if (_didIteratorError2) { - throw _iteratorError2; + if (_didIteratorError) { + throw _iteratorError; } } } + console.warn(JSON.stringify(classDef)); + var membersBox = members.node().getBBox(); var methodsLine = g.append('line') // text label for the x axis @@ -22427,28 +22389,28 @@ var drawClass = function drawClass(elem, classDef) { .attr('x', conf.padding).attr('y', titleHeight + 2 * conf.dividerMargin + membersBox.height + conf.textHeight).attr('fill', 'white').attr('class', 'classText'); isFirst = true; - var _iteratorNormalCompletion3 = true; - var _didIteratorError3 = false; - var _iteratorError3 = undefined; + var _iteratorNormalCompletion2 = true; + var _didIteratorError2 = false; + var _iteratorError2 = undefined; try { - for (var _iterator3 = classDef.methods[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { - var method = _step3.value; + for (var _iterator2 = classDef.methods[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) { + var method = _step2.value; addTspan(methods, method, isFirst); isFirst = false; } } catch (err) { - _didIteratorError3 = true; - _iteratorError3 = err; + _didIteratorError2 = true; + _iteratorError2 = err; } finally { try { - if (!_iteratorNormalCompletion3 && _iterator3['return']) { - _iterator3['return'](); + if (!_iteratorNormalCompletion2 && _iterator2['return']) { + _iterator2['return'](); } } finally { - if (_didIteratorError3) { - throw _iteratorError3; + if (_didIteratorError2) { + throw _iteratorError2; } } } @@ -22462,7 +22424,8 @@ var drawClass = function drawClass(elem, classDef) { classInfo.width = classBox.width + 2 * conf.padding; classInfo.height = classBox.height + conf.padding + 0.5 * conf.dividerMargin; - idCache.set(id, classInfo); + console.warn('setting id: ' + id + ' to ' + JSON.stringify(classInfo)); + idCache[id] = classInfo; classCnt++; return classInfo; }; @@ -22506,75 +22469,60 @@ module.exports.draw = function (text, id) { }); var classes = cDDb.getClasses(); - var _iteratorNormalCompletion4 = true; - var _didIteratorError4 = false; - var _iteratorError4 = undefined; - - try { - for (var _iterator4 = classes.values()[Symbol.iterator](), _step4; !(_iteratorNormalCompletion4 = (_step4 = _iterator4.next()).done); _iteratorNormalCompletion4 = true) { - var classDef = _step4.value; - - var node = drawClass(diagram, classDef); - // Add nodes to the graph. The first argument is the node id. The second is - // metadata about the node. In this case we're going to add labels to each of - // our nodes. - g.setNode(node.id, node); - log.info('Org height: ' + node.height); - //g.setNode("swilliams", { label: "Saul Williams", width: 160, height: 100 }); - //g.setNode("bpitt", { label: "Brad Pitt", width: 108, height: 100 }); - //g.setNode("hford", { label: "Harrison Ford", width: 168, height: 100 }); - //g.setNode("lwilson", { label: "Luke Wilson", width: 144, height: 100 }); - //g.setNode("kbacon", { label: "Kevin Bacon", width: 121, height: 100 }); - } - } catch (err) { - _didIteratorError4 = true; - _iteratorError4 = err; - } finally { - try { - if (!_iteratorNormalCompletion4 && _iterator4['return']) { - _iterator4['return'](); - } - } finally { - if (_didIteratorError4) { - throw _iteratorError4; - } - } + var keys = Object.keys(classes); + var i; + for (i = 0; i < keys.length; i++) { + var classDef = classes[keys[i]]; + var node = drawClass(diagram, classDef); + // Add nodes to the graph. The first argument is the node id. The second is + // metadata about the node. In this case we're going to add labels to each of + // our nodes. + g.setNode(node.id, node); + log.info('Org height: ' + node.height); + //g.setNode("swilliams", { label: "Saul Williams", width: 160, height: 100 }); + //g.setNode("bpitt", { label: "Brad Pitt", width: 108, height: 100 }); + //g.setNode("hford", { label: "Harrison Ford", width: 168, height: 100 }); + //g.setNode("lwilson", { label: "Luke Wilson", width: 144, height: 100 }); + //g.setNode("kbacon", { label: "Kevin Bacon", width: 121, height: 100 }); } var relations = cDDb.getRelations(); var i = 0; - var _iteratorNormalCompletion5 = true; - var _didIteratorError5 = false; - var _iteratorError5 = undefined; + var _iteratorNormalCompletion3 = true; + var _didIteratorError3 = false; + var _iteratorError3 = undefined; try { - for (var _iterator5 = relations[Symbol.iterator](), _step5; !(_iteratorNormalCompletion5 = (_step5 = _iterator5.next()).done); _iteratorNormalCompletion5 = true) { - var relation = _step5.value; + for (var _iterator3 = relations[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { + var relation = _step3.value; i = i + 1; + log.info('tjoho' + getGraphId(relation.id1) + getGraphId(relation.id2) + JSON.stringify(relation)); g.setEdge(getGraphId(relation.id1), getGraphId(relation.id2), { relation: relation }); } } catch (err) { - _didIteratorError5 = true; - _iteratorError5 = err; + _didIteratorError3 = true; + _iteratorError3 = err; } finally { try { - if (!_iteratorNormalCompletion5 && _iterator5['return']) { - _iterator5['return'](); + if (!_iteratorNormalCompletion3 && _iterator3['return']) { + _iterator3['return'](); } } finally { - if (_didIteratorError5) { - throw _iteratorError5; + if (_didIteratorError3) { + throw _iteratorError3; } } } dagre.layout(g); g.nodes().forEach(function (v) { - log.debug('Node ' + v + ': ' + JSON.stringify(g.node(v))); - d3.select('#' + v).attr('transform', 'translate(' + (g.node(v).x - g.node(v).width / 2) + ',' + (g.node(v).y - g.node(v).height / 2) + ' )'); - //d3.select('#' +v +' rect').attr('x',(g.node(v).x-(g.node(v).width/2))) - //.attr('y',(g.node(v).y-(g.node(v).height/2))); + if (typeof v !== 'undefined') { + log.debug('Node ' + v + ': ' + JSON.stringify(g.node(v))); + d3.select('#' + v).attr('transform', 'translate(' + (g.node(v).x - g.node(v).width / 2) + ',' + (g.node(v).y - g.node(v).height / 2) + ' )'); + //d3.select('#' +v +' rect').attr('x',(g.node(v).x-(g.node(v).width/2))) + //.attr('y',(g.node(v).y-(g.node(v).height/2))); + } }); g.edges().forEach(function (e) { log.debug('Edge ' + e.v + ' -> ' + e.w + ': ' + JSON.stringify(g.edge(e))); @@ -23408,12 +23356,7 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var message = ''; @@ -23447,16 +23390,10 @@ exports.parseError = function (err, hash) { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var db = require('./exampleDb'); var exampleParser = require('./parser/example.js'); var d3 = require('../../d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); /** @@ -24140,12 +24077,7 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { /* global window */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var dagreD3; @@ -24171,18 +24103,12 @@ module.exports = dagreD3; */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var graph = require('./graphDb'); var flow = require('./parser/flow'); var dot = require('./parser/dot'); var d3 = require('../../d3'); var dagreD3 = require('./dagre-d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var conf = {}; @@ -24613,12 +24539,7 @@ exports.draw = function (text, id, isDot) { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var d3 = require('../../d3'); @@ -26948,14 +26869,8 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var moment = require('moment'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var dateFormat = ''; @@ -29184,17 +29099,11 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var actors = {}; var actorKeys = []; var messages = []; var notes = []; - +var Logger = require('../../logger'); var log = new Logger.Log(); exports.addActor = function (id, name, description) { @@ -29331,17 +29240,11 @@ exports.apply = function (param) { 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var sq = require('./parser/sequenceDiagram').parser; sq.yy = require('./sequenceDb'); var svgDraw = require('./svgDraw'); var d3 = require('../../d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var conf = { @@ -29948,10 +29851,6 @@ exports.getNoteRect = function () { 'use strict'; -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } - var LEVELS = { debug: 1, info: 2, @@ -29995,59 +29894,45 @@ function formatTime(timestamp) { return t; } -var Log = (function () { - function Log(level) { - _classCallCheck(this, Log); +function Log(level) { + this.level = level; - this.level = level; - } - - _createClass(Log, [{ - key: 'log', - value: function log(str, level) { - var logLevel = this.level; - if (typeof logLevel === 'undefined') { - logLevel = defaultLevel; - } - if (logLevel <= level) { - if (typeof console !== 'undefined') { + this.log = function (str, level) { + var logLevel = this.level; + if (typeof logLevel === 'undefined') { + logLevel = defaultLevel; + } + if (logLevel <= level) { + if (typeof console !== 'undefined') { + //eslint-disable-line no-console + if (typeof console.log !== 'undefined') { //eslint-disable-line no-console - if (typeof console.log !== 'undefined') { - //eslint-disable-line no-console - return console.log('[' + formatTime(new Date()) + '] ' + str); //eslint-disable-line no-console - } + return console.log('[' + formatTime(new Date()) + '] ' + str); //eslint-disable-line no-console } } } - }, { - key: 'trace', - value: function trace(str) { - this.log(str, LEVELS.trace); - } - }, { - key: 'debug', - value: function debug(str) { - this.log(str, LEVELS.debug); - } - }, { - key: 'info', - value: function info(str) { - this.log(str, LEVELS.info); - } - }, { - key: 'warn', - value: function warn(str) { - this.log(str, LEVELS.warn); - } - }, { - key: 'error', - value: function error(str) { - this.log(str, LEVELS.error); - } - }]); + }; - return Log; -})(); + this.trace = function (str) { + this.log(str, LEVELS.trace); + }; + + this.debug = function (str) { + this.log(str, LEVELS.debug); + }; + + this.info = function (str) { + this.log(str, LEVELS.info); + }; + + this.warn = function (str) { + this.log(str, LEVELS.warn); + }; + + this.error = function (str) { + this.log(str, LEVELS.error); + }; +} exports.Log = Log; @@ -30074,11 +29959,7 @@ exports.Log = Log; 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); +var Logger = require('./logger'); var log = new Logger.Log(); var mermaidAPI = require('./mermaidAPI'); @@ -30318,7 +30199,7 @@ if (typeof document !== 'undefined') { /*! * Wait for document loaded before starting the execution */ - document.addEventListener('DOMContentLoaded', function () { + window.addEventListener('load', function () { exports.contentLoaded(); }, false); } @@ -30345,12 +30226,7 @@ if (typeof document !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('./logger'); var log = new Logger.Log(); var graph = require('./diagrams/flowchart/graphDb'); @@ -30759,6 +30635,8 @@ var render = function render(id, txt, cb, container) { var svgCode = d3.select('#d' + id).node().innerHTML.replace(/url\(#arrowhead/g, 'url(' + url + '#arrowhead', 'g'); svgCode = exports.decodeEntities(svgCode); + console.warn('here'); + //console.warn('mermaid decode: '); //console.warn(svgCode); //var he = require('he'); @@ -30766,13 +30644,15 @@ var render = function render(id, txt, cb, container) { if (typeof cb !== 'undefined') { cb(svgCode, graph.bindFunctions); } else { - log.warn('CB = undefined'); + log.warn('CB = undefined!'); } var node = d3.select('#d' + id).node(); if (node !== null && typeof node.remove === 'function') { d3.select('#d' + id).node().remove(); } + + return svgCode; }; exports.render = function (id, text, cb, containerElement) { @@ -30780,7 +30660,7 @@ exports.render = function (id, text, cb, containerElement) { // Todo handle rendering serverside using phantomjs } else { // In browser - render(id, text, cb, containerElement); + return render(id, text, cb, containerElement); } }; @@ -30844,16 +30724,7 @@ global.mermaidAPI = { */ 'use strict'; -Object.defineProperty(exports, '__esModule', { - value: true -}); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('./logger'); var log = new Logger.Log(); /** diff --git a/dist/mermaid.slim.min.js b/dist/mermaid.slim.min.js index d33a3a9eba..bdfd7b15fc 100644 --- a/dist/mermaid.slim.min.js +++ b/dist/mermaid.slim.min.js @@ -5,11 +5,12 @@ for(var o in t)s&&Kr(o,e)||"constructor"==o&&(i||!ts.call(t,o))||a.push(o);retur weight:0,minlen:r}));var h=u.addBorderNode(t,"_bt"),d=u.addBorderNode(t,"_bb"),f=t.node(c);t.setParent(h,c),f.borderTop=h,t.setParent(d,c),f.borderBottom=d,o.each(l,function(o){n(t,e,r,i,a,s,o);var u=t.node(o),l=u.borderTop?u.borderTop:o,f=u.borderBottom?u.borderBottom:o,p=u.borderTop?i:2*i,g=l!==f?1:a-s[c]+1;t.setEdge(h,l,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(f,d,{weight:p,minlen:g,nestingEdge:!0})}),t.parent(c)||t.setEdge(e,h,{weight:0,minlen:a+s[c]})}function i(t){function e(n,i){var a=t.children(n);a&&a.length&&o.each(a,function(t){e(t,i+1)}),r[n]=i}var r={};return o.each(t.children(),function(t){e(t,1)}),r}function a(t){return o.reduce(t.edges(),function(e,r){return e+t.edge(r).weight},0)}function s(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,o.each(t.edges(),function(e){var r=t.edge(e);r.nestingEdge&&t.removeEdge(e)})}var o=t("./lodash"),u=t("./util");e.exports={run:r,cleanup:s}},{"./lodash":62,"./util":81}],64:[function(t,e){"use strict";function r(t){t.graph().dummyChains=[],a.each(t.edges(),function(e){n(t,e)})}function n(t,e){var r=e.v,n=t.node(r).rank,i=e.w,a=t.node(i).rank,o=e.name,u=t.edge(e),c=u.labelRank;if(a!==n+1){t.removeEdge(e);var l,h,d;for(d=0,++n;a>n;++d,++n)u.points=[],h={width:0,height:0,edgeLabel:u,edgeObj:e,rank:n},l=s.addDummyNode(t,"edge",h,"_d"),n===c&&(h.width=u.width,h.height=u.height,h.dummy="edge-label",h.labelpos=u.labelpos),t.setEdge(r,l,{weight:u.weight},o),0===d&&t.graph().dummyChains.push(l),r=l;t.setEdge(r,i,{weight:u.weight},o)}}function i(t){a.each(t.graph().dummyChains,function(e){var r,n=t.node(e),i=n.edgeLabel;for(t.setEdge(n.edgeObj,i);n.dummy;)r=t.successors(e)[0],t.removeNode(e),i.points.push({x:n.x,y:n.y}),"edge-label"===n.dummy&&(i.x=n.x,i.y=n.y,i.width=n.width,i.height=n.height),e=r,n=t.node(e)})}var a=t("./lodash"),s=t("./util");e.exports={run:r,undo:i}},{"./lodash":62,"./util":81}],65:[function(t,e){function r(t,e,r){var i,a={};n.each(r,function(r){for(var n,s,o=t.parent(r);o;){if(n=t.parent(o),n?(s=a[n],a[n]=o):(s=i,i=o),s&&s!==o)return void e.setEdge(s,o);o=n}})}var n=t("../lodash");e.exports=r},{"../lodash":62}],66:[function(t,e){function r(t,e){return n.map(e,function(e){var r=t.inEdges(e);if(r.length){var i=n.reduce(r,function(e,r){var n=t.edge(r),i=t.node(r.v);return{sum:e.sum+n.weight*i.order,weight:e.weight+n.weight}},{sum:0,weight:0});return{v:e,barycenter:i.sum/i.weight,weight:i.weight}}return{v:e}})}var n=t("../lodash");e.exports=r},{"../lodash":62}],67:[function(t,e){function r(t,e,r){var s=n(t),o=new a({compound:!0}).setGraph({root:s}).setDefaultNodeLabel(function(e){return t.node(e)});return i.each(t.nodes(),function(n){var a=t.node(n),u=t.parent(n);(a.rank===e||a.minRank<=e&&e<=a.maxRank)&&(o.setNode(n),o.setParent(n,u||s),i.each(t[r](n),function(e){var r=e.v===n?e.w:e.v,a=o.edge(r,n),s=i.isUndefined(a)?0:a.weight;o.setEdge(r,n,{weight:t.edge(e).weight+s})}),i.has(a,"minRank")&&o.setNode(n,{borderLeft:a.borderLeft[e],borderRight:a.borderRight[e]}))}),o}function n(t){for(var e;t.hasNode(e=i.uniqueId("_root")););return e}var i=t("../lodash"),a=t("../graphlib").Graph;e.exports=r},{"../graphlib":59,"../lodash":62}],68:[function(t,e){"use strict";function r(t,e){for(var r=0,i=1;i0;)e%2&&(r+=u[e+1]),e=e-1>>1,u[e]+=t.weight;c+=t.weight*r})),c}var i=t("../lodash");e.exports=r},{"../lodash":62}],69:[function(t,e){"use strict";function r(t){var e=f.maxRank(t),r=n(t,s.range(1,e+1),"inEdges"),c=n(t,s.range(e-1,-1,-1),"outEdges"),l=o(t);a(t,l);for(var h,d=Number.POSITIVE_INFINITY,p=0,g=0;4>g;++p,++g){i(p%2?r:c,p%4>=2),l=f.buildLayerMatrix(t);var y=u(t,l);d>y&&(g=0,h=s.cloneDeep(l),d=y)}a(t,h)}function n(t,e,r){return s.map(e,function(e){return l(t,e,r)})}function i(t,e){var r=new d;s.each(t,function(t){var n=t.graph().root,i=c(t,n,r,e);s.each(i.vs,function(e,r){t.node(e).order=r}),h(t,r,i.vs)})}function a(t,e){s.each(e,function(e){s.each(e,function(e,r){t.node(e).order=r})})}var s=t("../lodash"),o=t("./init-order"),u=t("./cross-count"),c=t("./sort-subgraph"),l=t("./build-layer-graph"),h=t("./add-subgraph-constraints"),d=t("../graphlib").Graph,f=t("../util");e.exports=r},{"../graphlib":59,"../lodash":62,"../util":81,"./add-subgraph-constraints":65,"./build-layer-graph":67,"./cross-count":68,"./init-order":70,"./sort-subgraph":72}],70:[function(t,e){"use strict";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":62}],71:[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":62}],72:[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":62,"./barycenter":66,"./resolve-conflicts":71,"./sort":73}],73:[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.barycenterr.barycenter?1:t?r.i-e.i:e.i-r.i}}var a=t("../lodash"),s=t("../util");e.exports=r},{"../lodash":62,"../util":81}],74:[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).maxRanku||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":62}],75:[function(t,e){"use strict";function r(t,e){function r(e,r){var s=0,o=0,u=e.length,c=y.last(r);return y.each(r,function(e,l){var h=i(t,e),d=h?t.node(h).order:u;(h||e===c)&&(y.each(r.slice(o,l+1),function(e){y.each(t.predecessors(e),function(r){var i=t.node(r),o=i.order;!(s>o||o>d)||i.dummy&&t.node(e).dummy||a(n,r,e)})}),o=l+1,s=d)}),r}var n={};return y.reduce(e,r),n}function n(t,e){function r(e,r,n,s,o){var u;y.each(y.range(r,n),function(r){u=e[r],t.node(u).dummy&&y.each(t.predecessors(u),function(e){var r=t.node(e);r.dummy&&(r.ordero)&&a(i,e,u)})})}function n(e,n){var i,a=-1,s=0;return y.each(n,function(o,u){if("border"===t.node(o).dummy){var c=t.predecessors(o);c.length&&(i=t.node(c[0]).order,r(n,s,u,a,i),s=u,a=i)}r(n,s,n.length,i,e.length)}),n}var i={};return y.reduce(e,n),i}function i(t,e){return t.node(e).dummy?y.find(t.predecessors(e),function(e){return t.node(e).dummy}):void 0}function a(t,e,r){if(e>r){var n=e;e=r,r=n}var i=t[e];i||(t[e]=i={}),i[r]=!0}function s(t,e,r){if(e>r){var n=e;e=r,r=n}return y.has(t[e],r)}function o(t,e,r,n){var i={},a={},o={};return y.each(e,function(t){y.each(t,function(t,e){i[t]=t,a[t]=t,o[t]=e})}),y.each(e,function(t){var e=-1;y.each(t,function(t){var u=n(t);if(u.length){u=y.sortBy(u,function(t){return o[t]});for(var c=(u.length-1)/2,l=Math.floor(c),h=Math.ceil(c);h>=l;++l){var d=u[l];a[t]===t&&es.lim&&(o=s,u=!0);var c=p.filter(e.edges(),function(e){return u===f(t,t.node(e.v),o)&&u!==f(t,t.node(e.w),o)});return p.min(c,function(t){return y(e,t)})}function l(t,e,r,i){var a=r.v,o=r.w;t.removeEdge(a,o),t.setEdge(i.v,i.w,{}),s(t),n(t,e),h(t,e)}function h(t,e){var r=p.find(t.nodes(),function(t){return!e.node(t).parent}),n=v(t,r);n=n.slice(1),p.each(n,function(r){var n=t.node(r).parent,i=e.edge(r,n),a=!1;i||(i=e.edge(n,r),a=!0),e.node(r).rank=e.node(n).rank+(a?i.minlen:-i.minlen)})}function d(t,e,r){return t.hasEdge(e,r)}function f(t,e,r){return r.low<=e.lim&&e.lim<=r.lim}var p=t("../lodash"),g=t("./feasible-tree"),y=t("./util").slack,m=t("./util").longestPath,v=t("../graphlib").alg.preorder,b=t("../graphlib").alg.postorder,_=t("../util").simplify;e.exports=r,r.initLowLimValues=s,r.initCutValues=n,r.calcCutValue=a,r.leaveEdge=u,r.enterEdge=c,r.exchangeEdges=l},{"../graphlib":59,"../lodash":62,"../util":81,"./feasible-tree":77,"./util":80}],80:[function(t,e){"use strict";function r(t){function e(n){var a=t.node(n);if(i.has(r,n))return a.rank;r[n]=!0;var s=i.min(i.map(t.outEdges(n),function(r){return e(r.w)-t.edge(r).minlen}));return s===Number.POSITIVE_INFINITY&&(s=0),a.rank=s}var r={};i.each(t.sources(),e)}function n(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}var i=t("../lodash");e.exports={longestPath:r,slack:n}},{"../lodash":62}],81:[function(t,e){"use strict";function r(t,e,r,n){var i;do i=y.uniqueId(n);while(t.hasNode(i));return r.dummy=e,t.setNode(i,r),i}function n(t){var e=(new m).setGraph(t.graph());return y.each(t.nodes(),function(r){e.setNode(r,t.node(r))}),y.each(t.edges(),function(r){var n=e.edge(r.v,r.w)||{weight:0,minlen:1},i=t.edge(r);e.setEdge(r.v,r.w,{weight:n.weight+i.weight,minlen:Math.max(n.minlen,i.minlen)})}),e}function i(t){var e=new m({multigraph:t.isMultigraph()}).setGraph(t.graph());return y.each(t.nodes(),function(r){t.children(r).length||e.setNode(r,t.node(r))}),y.each(t.edges(),function(r){e.setEdge(r,t.edge(r))}),e}function a(t){var e=y.map(t.nodes(),function(e){var r={};return y.each(t.outEdges(e),function(e){r[e.w]=(r[e.w]||0)+t.edge(e).weight}),r});return y.zipObject(t.nodes(),e)}function s(t){var e=y.map(t.nodes(),function(e){var r={};return y.each(t.inEdges(e),function(e){r[e.v]=(r[e.v]||0)+t.edge(e).weight}),r});return y.zipObject(t.nodes(),e)}function o(t,e){var r=t.x,n=t.y,i=e.x-r,a=e.y-n,s=t.width/2,o=t.height/2;if(!i&&!a)throw new Error("Not possible to find intersection inside of the rectangle");var u,c;return Math.abs(a)*s>Math.abs(i)*o?(0>a&&(o=-o),u=o*i/a,c=o):(0>i&&(s=-s),u=s,c=s*a/i),{x:r+u,y:n+c}}function u(t){var e=y.map(y.range(d(t)+1),function(){return[]});return y.each(t.nodes(),function(r){var n=t.node(r),i=n.rank;y.isUndefined(i)||(e[i][n.order]=r)}),e}function c(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank}));y.each(t.nodes(),function(r){var n=t.node(r);y.has(n,"rank")&&(n.rank-=e)})}function l(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank})),r=[];y.each(t.nodes(),function(n){var i=t.node(n).rank-e;r[i]||(r[i]=[]),r[i].push(n)});var n=0,i=t.graph().nodeRankFactor;y.each(r,function(e,r){y.isUndefined(e)&&r%i!==0?--n:n&&y.each(e,function(e){t.node(e).rank+=n})})}function h(t,e,n,i){var a={width:0,height:0};return arguments.length>=4&&(a.rank=n,a.order=i),r(t,"border",a,e)}function d(t){return y.max(y.map(t.nodes(),function(e){var r=t.node(e).rank;return y.isUndefined(r)?void 0:r}))}function f(t,e){var r={lhs:[],rhs:[]};return y.each(t,function(t){e(t)?r.lhs.push(t):r.rhs.push(t)}),r}function p(t,e){var r=y.now();try{return e()}finally{console.log(t+" time: "+(y.now()-r)+"ms")}}function g(t,e){return e()}var y=t("./lodash"),m=t("./graphlib").Graph;e.exports={addDummyNode:r,simplify:n,asNonCompoundGraph:i,successorWeights:a,predecessorWeights:s,intersectRect:o,buildLayerMatrix:u,normalizeRanks:c,removeEmptyRanks:l,addBorderNode:h,maxRank:d,partition:f,time:p,notime:g}},{"./graphlib":59,"./lodash":62}],82:[function(t,e){e.exports="0.7.4"},{}],83:[function(t,e){e.exports=t(32)},{"./lib":99,"./lib/alg":90,"./lib/json":100,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/index.js":32}],84:[function(t,e){e.exports=t(33)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/components.js":33}],85:[function(t,e){e.exports=t(34)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dfs.js":34}],86:[function(t,e){e.exports=t(35)},{"../lodash":101,"./dijkstra":87,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra-all.js":35}],87:[function(t,e){e.exports=t(36)},{"../data/priority-queue":97,"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra.js":36}],88:[function(t,e){e.exports=t(37)},{"../lodash":101,"./tarjan":95,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/find-cycles.js":37}],89:[function(t,e){e.exports=t(38)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/floyd-warshall.js":38}],90:[function(t,e){e.exports=t(39)},{"./components":84,"./dijkstra":87,"./dijkstra-all":86,"./find-cycles":88,"./floyd-warshall":89,"./is-acyclic":91,"./postorder":92,"./preorder":93,"./prim":94,"./tarjan":95,"./topsort":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/index.js":39}],91:[function(t,e){e.exports=t(40)},{"./topsort":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/is-acyclic.js":40}],92:[function(t,e){e.exports=t(41)},{"./dfs":85,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/postorder.js":41}],93:[function(t,e){e.exports=t(42)},{"./dfs":85,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/preorder.js":42}],94:[function(t,e){e.exports=t(43)},{"../data/priority-queue":97,"../graph":98,"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/prim.js":43}],95:[function(t,e){e.exports=t(44)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/tarjan.js":44}],96:[function(t,e){e.exports=t(45)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/topsort.js":45}],97:[function(t,e){e.exports=t(46)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/data/priority-queue.js":46}],98:[function(t,e){e.exports=t(47)},{"./lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/graph.js":47}],99:[function(t,e){e.exports=t(48)},{"./graph":98,"./version":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/index.js":48}],100:[function(t,e){e.exports=t(49)},{"./graph":98,"./lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/json.js":49}],101:[function(t,e){e.exports=t(50)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":50,lodash:103}],102:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/version.js":51}],103:[function(t,e){e.exports=t(52)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/lodash/index.js":52}],104:[function(t,e,r){(function(t){!function(n){var i="object"==typeof r&&r,a="object"==typeof e&&e&&e.exports==i&&e,s="object"==typeof t&&t;(s.global===s||s.window===s)&&(n=s);var o=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,u=/[\x01-\x7F]/g,c=/[\x01-\t\x0B\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,l=/<\u20D2|=\u20E5|>\u20D2|\u205F\u200A|\u219D\u0338|\u2202\u0338|\u2220\u20D2|\u2229\uFE00|\u222A\uFE00|\u223C\u20D2|\u223D\u0331|\u223E\u0333|\u2242\u0338|\u224B\u0338|\u224D\u20D2|\u224E\u0338|\u224F\u0338|\u2250\u0338|\u2261\u20E5|\u2264\u20D2|\u2265\u20D2|\u2266\u0338|\u2267\u0338|\u2268\uFE00|\u2269\uFE00|\u226A\u0338|\u226A\u20D2|\u226B\u0338|\u226B\u20D2|\u227F\u0338|\u2282\u20D2|\u2283\u20D2|\u228A\uFE00|\u228B\uFE00|\u228F\u0338|\u2290\u0338|\u2293\uFE00|\u2294\uFE00|\u22B4\u20D2|\u22B5\u20D2|\u22D8\u0338|\u22D9\u0338|\u22DA\uFE00|\u22DB\uFE00|\u22F5\u0338|\u22F9\u0338|\u2933\u0338|\u29CF\u0338|\u29D0\u0338|\u2A6D\u0338|\u2A70\u0338|\u2A7D\u0338|\u2A7E\u0338|\u2AA1\u0338|\u2AA2\u0338|\u2AAC\uFE00|\u2AAD\uFE00|\u2AAF\u0338|\u2AB0\u0338|\u2AC5\u0338|\u2AC6\u0338|\u2ACB\uFE00|\u2ACC\uFE00|\u2AFD\u20E5|[\xA0-\u0113\u0116-\u0122\u0124-\u012B\u012E-\u014D\u0150-\u017E\u0192\u01B5\u01F5\u0237\u02C6\u02C7\u02D8-\u02DD\u0311\u0391-\u03A1\u03A3-\u03A9\u03B1-\u03C9\u03D1\u03D2\u03D5\u03D6\u03DC\u03DD\u03F0\u03F1\u03F5\u03F6\u0401-\u040C\u040E-\u044F\u0451-\u045C\u045E\u045F\u2002-\u2005\u2007-\u2010\u2013-\u2016\u2018-\u201A\u201C-\u201E\u2020-\u2022\u2025\u2026\u2030-\u2035\u2039\u203A\u203E\u2041\u2043\u2044\u204F\u2057\u205F-\u2063\u20AC\u20DB\u20DC\u2102\u2105\u210A-\u2113\u2115-\u211E\u2122\u2124\u2127-\u2129\u212C\u212D\u212F-\u2131\u2133-\u2138\u2145-\u2148\u2153-\u215E\u2190-\u219B\u219D-\u21A7\u21A9-\u21AE\u21B0-\u21B3\u21B5-\u21B7\u21BA-\u21DB\u21DD\u21E4\u21E5\u21F5\u21FD-\u2205\u2207-\u2209\u220B\u220C\u220F-\u2214\u2216-\u2218\u221A\u221D-\u2238\u223A-\u2257\u2259\u225A\u225C\u225F-\u2262\u2264-\u228B\u228D-\u229B\u229D-\u22A5\u22A7-\u22B0\u22B2-\u22BB\u22BD-\u22DB\u22DE-\u22E3\u22E6-\u22F7\u22F9-\u22FE\u2305\u2306\u2308-\u2310\u2312\u2313\u2315\u2316\u231C-\u231F\u2322\u2323\u232D\u232E\u2336\u233D\u233F\u237C\u23B0\u23B1\u23B4-\u23B6\u23DC-\u23DF\u23E2\u23E7\u2423\u24C8\u2500\u2502\u250C\u2510\u2514\u2518\u251C\u2524\u252C\u2534\u253C\u2550-\u256C\u2580\u2584\u2588\u2591-\u2593\u25A1\u25AA\u25AB\u25AD\u25AE\u25B1\u25B3-\u25B5\u25B8\u25B9\u25BD-\u25BF\u25C2\u25C3\u25CA\u25CB\u25EC\u25EF\u25F8-\u25FC\u2605\u2606\u260E\u2640\u2642\u2660\u2663\u2665\u2666\u266A\u266D-\u266F\u2713\u2717\u2720\u2736\u2758\u2772\u2773\u27C8\u27C9\u27E6-\u27ED\u27F5-\u27FA\u27FC\u27FF\u2902-\u2905\u290C-\u2913\u2916\u2919-\u2920\u2923-\u292A\u2933\u2935-\u2939\u293C\u293D\u2945\u2948-\u294B\u294E-\u2976\u2978\u2979\u297B-\u297F\u2985\u2986\u298B-\u2996\u299A\u299C\u299D\u29A4-\u29B7\u29B9\u29BB\u29BC\u29BE-\u29C5\u29C9\u29CD-\u29D0\u29DC-\u29DE\u29E3-\u29E5\u29EB\u29F4\u29F6\u2A00-\u2A02\u2A04\u2A06\u2A0C\u2A0D\u2A10-\u2A17\u2A22-\u2A27\u2A29\u2A2A\u2A2D-\u2A31\u2A33-\u2A3C\u2A3F\u2A40\u2A42-\u2A4D\u2A50\u2A53-\u2A58\u2A5A-\u2A5D\u2A5F\u2A66\u2A6A\u2A6D-\u2A75\u2A77-\u2A9A\u2A9D-\u2AA2\u2AA4-\u2AB0\u2AB3-\u2AC8\u2ACB\u2ACC\u2ACF-\u2ADB\u2AE4\u2AE6-\u2AE9\u2AEB-\u2AF3\u2AFD\uFB00-\uFB04]|\uD835[\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDCCF\uDD04\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDD6B]/g,h={"Á":"Aacute","á":"aacute","Ă":"Abreve","ă":"abreve","∾":"ac","∿":"acd","∾̳":"acE","Â":"Acirc","â":"acirc","´":"acute","А":"Acy","а":"acy","Æ":"AElig","æ":"aelig","⁡":"af","𝔄":"Afr","𝔞":"afr","À":"Agrave","à":"agrave","ℵ":"aleph","Α":"Alpha","α":"alpha","Ā":"Amacr","ā":"amacr","⨿":"amalg","&":"amp","⩕":"andand","⩓":"And","∧":"and","⩜":"andd","⩘":"andslope","⩚":"andv","∠":"ang","⦤":"ange","⦨":"angmsdaa","⦩":"angmsdab","⦪":"angmsdac","⦫":"angmsdad","⦬":"angmsdae","⦭":"angmsdaf","⦮":"angmsdag","⦯":"angmsdah","∡":"angmsd","∟":"angrt","⊾":"angrtvb","⦝":"angrtvbd","∢":"angsph","Å":"angst","⍼":"angzarr","Ą":"Aogon","ą":"aogon","𝔸":"Aopf","𝕒":"aopf","⩯":"apacir","≈":"ap","⩰":"apE","≊":"ape","≋":"apid","'":"apos","å":"aring","𝒜":"Ascr","𝒶":"ascr","≔":"colone","*":"ast","≍":"CupCap","Ã":"Atilde","ã":"atilde","Ä":"Auml","ä":"auml","∳":"awconint","⨑":"awint","≌":"bcong","϶":"bepsi","‵":"bprime","∽":"bsim","⋍":"bsime","∖":"setmn","⫧":"Barv","⊽":"barvee","⌅":"barwed","⌆":"Barwed","⎵":"bbrk","⎶":"bbrktbrk","Б":"Bcy","б":"bcy","„":"bdquo","∵":"becaus","⦰":"bemptyv","ℬ":"Bscr","Β":"Beta","β":"beta","ℶ":"beth","≬":"twixt","𝔅":"Bfr","𝔟":"bfr","⋂":"xcap","◯":"xcirc","⋃":"xcup","⨀":"xodot","⨁":"xoplus","⨂":"xotime","⨆":"xsqcup","★":"starf","▽":"xdtri","△":"xutri","⨄":"xuplus","⋁":"Vee","⋀":"Wedge","⤍":"rbarr","⧫":"lozf","▪":"squf","▴":"utrif","▾":"dtrif","◂":"ltrif","▸":"rtrif","␣":"blank","▒":"blk12","░":"blk14","▓":"blk34","█":"block","=⃥":"bne","≡⃥":"bnequiv","⫭":"bNot","⌐":"bnot","𝔹":"Bopf","𝕓":"bopf","⊥":"bot","⋈":"bowtie","⧉":"boxbox","┐":"boxdl","╕":"boxdL","╖":"boxDl","╗":"boxDL","┌":"boxdr","╒":"boxdR","╓":"boxDr","╔":"boxDR","─":"boxh","═":"boxH","┬":"boxhd","╤":"boxHd","╥":"boxhD","╦":"boxHD","┴":"boxhu","╧":"boxHu","╨":"boxhU","╩":"boxHU","⊟":"minusb","⊞":"plusb","⊠":"timesb","┘":"boxul","╛":"boxuL","╜":"boxUl","╝":"boxUL","└":"boxur","╘":"boxuR","╙":"boxUr","╚":"boxUR","│":"boxv","║":"boxV","┼":"boxvh","╪":"boxvH","╫":"boxVh","╬":"boxVH","┤":"boxvl","╡":"boxvL","╢":"boxVl","╣":"boxVL","├":"boxvr","╞":"boxvR","╟":"boxVr","╠":"boxVR","˘":"breve","¦":"brvbar","𝒷":"bscr","⁏":"bsemi","⧅":"bsolb","\\":"bsol","⟈":"bsolhsub","•":"bull","≎":"bump","⪮":"bumpE","≏":"bumpe","Ć":"Cacute","ć":"cacute","⩄":"capand","⩉":"capbrcup","⩋":"capcap","∩":"cap","⋒":"Cap","⩇":"capcup","⩀":"capdot","ⅅ":"DD","∩︀":"caps","⁁":"caret","ˇ":"caron","ℭ":"Cfr","⩍":"ccaps","Č":"Ccaron","č":"ccaron","Ç":"Ccedil","ç":"ccedil","Ĉ":"Ccirc","ĉ":"ccirc","∰":"Cconint","⩌":"ccups","⩐":"ccupssm","Ċ":"Cdot","ċ":"cdot","¸":"cedil","⦲":"cemptyv","¢":"cent","·":"middot","𝔠":"cfr","Ч":"CHcy","ч":"chcy","✓":"check","Χ":"Chi","χ":"chi","ˆ":"circ","≗":"cire","↺":"olarr","↻":"orarr","⊛":"oast","⊚":"ocir","⊝":"odash","⊙":"odot","®":"reg","Ⓢ":"oS","⊖":"ominus","⊕":"oplus","⊗":"otimes","○":"cir","⧃":"cirE","⨐":"cirfnint","⫯":"cirmid","⧂":"cirscir","∲":"cwconint","”":"rdquo","’":"rsquo","♣":"clubs",":":"colon","∷":"Colon","⩴":"Colone",",":"comma","@":"commat","∁":"comp","∘":"compfn","ℂ":"Copf","≅":"cong","⩭":"congdot","≡":"equiv","∮":"oint","∯":"Conint","𝕔":"copf","∐":"coprod","©":"copy","℗":"copysr","↵":"crarr","✗":"cross","⨯":"Cross","𝒞":"Cscr","𝒸":"cscr","⫏":"csub","⫑":"csube","⫐":"csup","⫒":"csupe","⋯":"ctdot","⤸":"cudarrl","⤵":"cudarrr","⋞":"cuepr","⋟":"cuesc","↶":"cularr","⤽":"cularrp","⩈":"cupbrcap","⩆":"cupcap","∪":"cup","⋓":"Cup","⩊":"cupcup","⊍":"cupdot","⩅":"cupor","∪︀":"cups","↷":"curarr","⤼":"curarrm","⋎":"cuvee","⋏":"cuwed","¤":"curren","∱":"cwint","⌭":"cylcty","†":"dagger","‡":"Dagger","ℸ":"daleth","↓":"darr","↡":"Darr","⇓":"dArr","‐":"dash","⫤":"Dashv","⊣":"dashv","⤏":"rBarr","˝":"dblac","Ď":"Dcaron","ď":"dcaron","Д":"Dcy","д":"dcy","⇊":"ddarr","ⅆ":"dd","⤑":"DDotrahd","⩷":"eDDot","°":"deg","∇":"Del","Δ":"Delta","δ":"delta","⦱":"demptyv","⥿":"dfisht","𝔇":"Dfr","𝔡":"dfr","⥥":"dHar","⇃":"dharl","⇂":"dharr","˙":"dot","`":"grave","˜":"tilde","⋄":"diam","♦":"diams","¨":"die","ϝ":"gammad","⋲":"disin","÷":"div","⋇":"divonx","Ђ":"DJcy","ђ":"djcy","⌞":"dlcorn","⌍":"dlcrop",$:"dollar","𝔻":"Dopf","𝕕":"dopf","⃜":"DotDot","≐":"doteq","≑":"eDot","∸":"minusd","∔":"plusdo","⊡":"sdotb","⇐":"lArr","⇔":"iff","⟸":"xlArr","⟺":"xhArr","⟹":"xrArr","⇒":"rArr","⊨":"vDash","⇑":"uArr","⇕":"vArr","∥":"par","⤓":"DownArrowBar","⇵":"duarr","̑":"DownBreve","⥐":"DownLeftRightVector","⥞":"DownLeftTeeVector","⥖":"DownLeftVectorBar","↽":"lhard","⥟":"DownRightTeeVector","⥗":"DownRightVectorBar","⇁":"rhard","↧":"mapstodown","⊤":"top","⤐":"RBarr","⌟":"drcorn","⌌":"drcrop","𝒟":"Dscr","𝒹":"dscr","Ѕ":"DScy","ѕ":"dscy","⧶":"dsol","Đ":"Dstrok","đ":"dstrok","⋱":"dtdot","▿":"dtri","⥯":"duhar","⦦":"dwangle","Џ":"DZcy","џ":"dzcy","⟿":"dzigrarr","É":"Eacute","é":"eacute","⩮":"easter","Ě":"Ecaron","ě":"ecaron","Ê":"Ecirc","ê":"ecirc","≖":"ecir","≕":"ecolon","Э":"Ecy","э":"ecy","Ė":"Edot","ė":"edot","ⅇ":"ee","≒":"efDot","𝔈":"Efr","𝔢":"efr","⪚":"eg","È":"Egrave","è":"egrave","⪖":"egs","⪘":"egsdot","⪙":"el","∈":"in","⏧":"elinters","ℓ":"ell","⪕":"els","⪗":"elsdot","Ē":"Emacr","ē":"emacr","∅":"empty","◻":"EmptySmallSquare","▫":"EmptyVerySmallSquare"," ":"emsp13"," ":"emsp14"," ":"emsp","Ŋ":"ENG","ŋ":"eng"," ":"ensp","Ę":"Eogon","ę":"eogon","𝔼":"Eopf","𝕖":"eopf","⋕":"epar","⧣":"eparsl","⩱":"eplus","ε":"epsi","Ε":"Epsilon","ϵ":"epsiv","≂":"esim","⩵":"Equal","=":"equals","≟":"equest","⇌":"rlhar","⩸":"equivDD","⧥":"eqvparsl","⥱":"erarr","≓":"erDot","ℯ":"escr","ℰ":"Escr","⩳":"Esim","Η":"Eta","η":"eta","Ð":"ETH","ð":"eth","Ë":"Euml","ë":"euml","€":"euro","!":"excl","∃":"exist","Ф":"Fcy","ф":"fcy","♀":"female","ffi":"ffilig","ff":"fflig","ffl":"ffllig","𝔉":"Ffr","𝔣":"ffr","fi":"filig","◼":"FilledSmallSquare",fj:"fjlig","♭":"flat","fl":"fllig","▱":"fltns","ƒ":"fnof","𝔽":"Fopf","𝕗":"fopf","∀":"forall","⋔":"fork","⫙":"forkv","ℱ":"Fscr","⨍":"fpartint","½":"half","⅓":"frac13", "¼":"frac14","⅕":"frac15","⅙":"frac16","⅛":"frac18","⅔":"frac23","⅖":"frac25","¾":"frac34","⅗":"frac35","⅜":"frac38","⅘":"frac45","⅚":"frac56","⅝":"frac58","⅞":"frac78","⁄":"frasl","⌢":"frown","𝒻":"fscr","ǵ":"gacute","Γ":"Gamma","γ":"gamma","Ϝ":"Gammad","⪆":"gap","Ğ":"Gbreve","ğ":"gbreve","Ģ":"Gcedil","Ĝ":"Gcirc","ĝ":"gcirc","Г":"Gcy","г":"gcy","Ġ":"Gdot","ġ":"gdot","≥":"ge","≧":"gE","⪌":"gEl","⋛":"gel","⩾":"ges","⪩":"gescc","⪀":"gesdot","⪂":"gesdoto","⪄":"gesdotol","⋛︀":"gesl","⪔":"gesles","𝔊":"Gfr","𝔤":"gfr","≫":"gg","⋙":"Gg","ℷ":"gimel","Ѓ":"GJcy","ѓ":"gjcy","⪥":"gla","≷":"gl","⪒":"glE","⪤":"glj","⪊":"gnap","⪈":"gne","≩":"gnE","⋧":"gnsim","𝔾":"Gopf","𝕘":"gopf","⪢":"GreaterGreater","≳":"gsim","𝒢":"Gscr","ℊ":"gscr","⪎":"gsime","⪐":"gsiml","⪧":"gtcc","⩺":"gtcir",">":"gt","⋗":"gtdot","⦕":"gtlPar","⩼":"gtquest","⥸":"gtrarr","≩︀":"gvnE"," ":"hairsp","ℋ":"Hscr","Ъ":"HARDcy","ъ":"hardcy","⥈":"harrcir","↔":"harr","↭":"harrw","^":"Hat","ℏ":"hbar","Ĥ":"Hcirc","ĥ":"hcirc","♥":"hearts","…":"mldr","⊹":"hercon","𝔥":"hfr","ℌ":"Hfr","⤥":"searhk","⤦":"swarhk","⇿":"hoarr","∻":"homtht","↩":"larrhk","↪":"rarrhk","𝕙":"hopf","ℍ":"Hopf","―":"horbar","𝒽":"hscr","Ħ":"Hstrok","ħ":"hstrok","⁃":"hybull","Í":"Iacute","í":"iacute","⁣":"ic","Î":"Icirc","î":"icirc","И":"Icy","и":"icy","İ":"Idot","Е":"IEcy","е":"iecy","¡":"iexcl","𝔦":"ifr","ℑ":"Im","Ì":"Igrave","ì":"igrave","ⅈ":"ii","⨌":"qint","∭":"tint","⧜":"iinfin","℩":"iiota","IJ":"IJlig","ij":"ijlig","Ī":"Imacr","ī":"imacr","ℐ":"Iscr","ı":"imath","⊷":"imof","Ƶ":"imped","℅":"incare","∞":"infin","⧝":"infintie","⊺":"intcal","∫":"int","∬":"Int","ℤ":"Zopf","⨗":"intlarhk","⨼":"iprod","⁢":"it","Ё":"IOcy","ё":"iocy","Į":"Iogon","į":"iogon","𝕀":"Iopf","𝕚":"iopf","Ι":"Iota","ι":"iota","¿":"iquest","𝒾":"iscr","⋵":"isindot","⋹":"isinE","⋴":"isins","⋳":"isinsv","Ĩ":"Itilde","ĩ":"itilde","І":"Iukcy","і":"iukcy","Ï":"Iuml","ï":"iuml","Ĵ":"Jcirc","ĵ":"jcirc","Й":"Jcy","й":"jcy","𝔍":"Jfr","𝔧":"jfr","ȷ":"jmath","𝕁":"Jopf","𝕛":"jopf","𝒥":"Jscr","𝒿":"jscr","Ј":"Jsercy","ј":"jsercy","Є":"Jukcy","є":"jukcy","Κ":"Kappa","κ":"kappa","ϰ":"kappav","Ķ":"Kcedil","ķ":"kcedil","К":"Kcy","к":"kcy","𝔎":"Kfr","𝔨":"kfr","ĸ":"kgreen","Х":"KHcy","х":"khcy","Ќ":"KJcy","ќ":"kjcy","𝕂":"Kopf","𝕜":"kopf","𝒦":"Kscr","𝓀":"kscr","⇚":"lAarr","Ĺ":"Lacute","ĺ":"lacute","⦴":"laemptyv","ℒ":"Lscr","Λ":"Lambda","λ":"lambda","⟨":"lang","⟪":"Lang","⦑":"langd","⪅":"lap","«":"laquo","⇤":"larrb","⤟":"larrbfs","←":"larr","↞":"Larr","⤝":"larrfs","↫":"larrlp","⤹":"larrpl","⥳":"larrsim","↢":"larrtl","⤙":"latail","⤛":"lAtail","⪫":"lat","⪭":"late","⪭︀":"lates","⤌":"lbarr","⤎":"lBarr","❲":"lbbrk","{":"lcub","[":"lsqb","⦋":"lbrke","⦏":"lbrksld","⦍":"lbrkslu","Ľ":"Lcaron","ľ":"lcaron","Ļ":"Lcedil","ļ":"lcedil","⌈":"lceil","Л":"Lcy","л":"lcy","⤶":"ldca","“":"ldquo","⥧":"ldrdhar","⥋":"ldrushar","↲":"ldsh","≤":"le","≦":"lE","⇆":"lrarr","⟦":"lobrk","⥡":"LeftDownTeeVector","⥙":"LeftDownVectorBar","⌊":"lfloor","↼":"lharu","⇇":"llarr","⇋":"lrhar","⥎":"LeftRightVector","↤":"mapstoleft","⥚":"LeftTeeVector","⋋":"lthree","⧏":"LeftTriangleBar","⊲":"vltri","⊴":"ltrie","⥑":"LeftUpDownVector","⥠":"LeftUpTeeVector","⥘":"LeftUpVectorBar","↿":"uharl","⥒":"LeftVectorBar","⪋":"lEg","⋚":"leg","⩽":"les","⪨":"lescc","⩿":"lesdot","⪁":"lesdoto","⪃":"lesdotor","⋚︀":"lesg","⪓":"lesges","⋖":"ltdot","≶":"lg","⪡":"LessLess","≲":"lsim","⥼":"lfisht","𝔏":"Lfr","𝔩":"lfr","⪑":"lgE","⥢":"lHar","⥪":"lharul","▄":"lhblk","Љ":"LJcy","љ":"ljcy","≪":"ll","⋘":"Ll","⥫":"llhard","◺":"lltri","Ŀ":"Lmidot","ŀ":"lmidot","⎰":"lmoust","⪉":"lnap","⪇":"lne","≨":"lnE","⋦":"lnsim","⟬":"loang","⇽":"loarr","⟵":"xlarr","⟷":"xharr","⟼":"xmap","⟶":"xrarr","↬":"rarrlp","⦅":"lopar","𝕃":"Lopf","𝕝":"lopf","⨭":"loplus","⨴":"lotimes","∗":"lowast",_:"lowbar","↙":"swarr","↘":"searr","◊":"loz","(":"lpar","⦓":"lparlt","⥭":"lrhard","‎":"lrm","⊿":"lrtri","‹":"lsaquo","𝓁":"lscr","↰":"lsh","⪍":"lsime","⪏":"lsimg","‘":"lsquo","‚":"sbquo","Ł":"Lstrok","ł":"lstrok","⪦":"ltcc","⩹":"ltcir","<":"lt","⋉":"ltimes","⥶":"ltlarr","⩻":"ltquest","◃":"ltri","⦖":"ltrPar","⥊":"lurdshar","⥦":"luruhar","≨︀":"lvnE","¯":"macr","♂":"male","✠":"malt","⤅":"Map","↦":"map","↥":"mapstoup","▮":"marker","⨩":"mcomma","М":"Mcy","м":"mcy","—":"mdash","∺":"mDDot"," ":"MediumSpace","ℳ":"Mscr","𝔐":"Mfr","𝔪":"mfr","℧":"mho","µ":"micro","⫰":"midcir","∣":"mid","−":"minus","⨪":"minusdu","∓":"mp","⫛":"mlcp","⊧":"models","𝕄":"Mopf","𝕞":"mopf","𝓂":"mscr","Μ":"Mu","μ":"mu","⊸":"mumap","Ń":"Nacute","ń":"nacute","∠⃒":"nang","≉":"nap","⩰̸":"napE","≋̸":"napid","ʼn":"napos","♮":"natur","ℕ":"Nopf"," ":"nbsp","≎̸":"nbump","≏̸":"nbumpe","⩃":"ncap","Ň":"Ncaron","ň":"ncaron","Ņ":"Ncedil","ņ":"ncedil","≇":"ncong","⩭̸":"ncongdot","⩂":"ncup","Н":"Ncy","н":"ncy","–":"ndash","⤤":"nearhk","↗":"nearr","⇗":"neArr","≠":"ne","≐̸":"nedot","​":"ZeroWidthSpace","≢":"nequiv","⤨":"toea","≂̸":"nesim","\n":"NewLine","∄":"nexist","𝔑":"Nfr","𝔫":"nfr","≧̸":"ngE","≱":"nge","⩾̸":"nges","⋙̸":"nGg","≵":"ngsim","≫⃒":"nGt","≯":"ngt","≫̸":"nGtv","↮":"nharr","⇎":"nhArr","⫲":"nhpar","∋":"ni","⋼":"nis","⋺":"nisd","Њ":"NJcy","њ":"njcy","↚":"nlarr","⇍":"nlArr","‥":"nldr","≦̸":"nlE","≰":"nle","⩽̸":"nles","≮":"nlt","⋘̸":"nLl","≴":"nlsim","≪⃒":"nLt","⋪":"nltri","⋬":"nltrie","≪̸":"nLtv","∤":"nmid","⁠":"NoBreak","𝕟":"nopf","⫬":"Not","¬":"not","≭":"NotCupCap","∦":"npar","∉":"notin","≹":"ntgl","⋵̸":"notindot","⋹̸":"notinE","⋷":"notinvb","⋶":"notinvc","⧏̸":"NotLeftTriangleBar","≸":"ntlg","⪢̸":"NotNestedGreaterGreater","⪡̸":"NotNestedLessLess","∌":"notni","⋾":"notnivb","⋽":"notnivc","⊀":"npr","⪯̸":"npre","⋠":"nprcue","⧐̸":"NotRightTriangleBar","⋫":"nrtri","⋭":"nrtrie","⊏̸":"NotSquareSubset","⋢":"nsqsube","⊐̸":"NotSquareSuperset","⋣":"nsqsupe","⊂⃒":"vnsub","⊈":"nsube","⊁":"nsc","⪰̸":"nsce","⋡":"nsccue","≿̸":"NotSucceedsTilde","⊃⃒":"vnsup","⊉":"nsupe","≁":"nsim","≄":"nsime","⫽⃥":"nparsl","∂̸":"npart","⨔":"npolint","⤳̸":"nrarrc","↛":"nrarr","⇏":"nrArr","↝̸":"nrarrw","𝒩":"Nscr","𝓃":"nscr","⊄":"nsub","⫅̸":"nsubE","⊅":"nsup","⫆̸":"nsupE","Ñ":"Ntilde","ñ":"ntilde","Ν":"Nu","ν":"nu","#":"num","№":"numero"," ":"numsp","≍⃒":"nvap","⊬":"nvdash","⊭":"nvDash","⊮":"nVdash","⊯":"nVDash","≥⃒":"nvge",">⃒":"nvgt","⤄":"nvHarr","⧞":"nvinfin","⤂":"nvlArr","≤⃒":"nvle","<⃒":"nvlt","⊴⃒":"nvltrie","⤃":"nvrArr","⊵⃒":"nvrtrie","∼⃒":"nvsim","⤣":"nwarhk","↖":"nwarr","⇖":"nwArr","⤧":"nwnear","Ó":"Oacute","ó":"oacute","Ô":"Ocirc","ô":"ocirc","О":"Ocy","о":"ocy","Ő":"Odblac","ő":"odblac","⨸":"odiv","⦼":"odsold","Œ":"OElig","œ":"oelig","⦿":"ofcir","𝔒":"Ofr","𝔬":"ofr","˛":"ogon","Ò":"Ograve","ò":"ograve","⧁":"ogt","⦵":"ohbar","Ω":"ohm","⦾":"olcir","⦻":"olcross","‾":"oline","⧀":"olt","Ō":"Omacr","ō":"omacr","ω":"omega","Ο":"Omicron","ο":"omicron","⦶":"omid","𝕆":"Oopf","𝕠":"oopf","⦷":"opar","⦹":"operp","⩔":"Or","∨":"or","⩝":"ord","ℴ":"oscr","ª":"ordf","º":"ordm","⊶":"origof","⩖":"oror","⩗":"orslope","⩛":"orv","𝒪":"Oscr","Ø":"Oslash","ø":"oslash","⊘":"osol","Õ":"Otilde","õ":"otilde","⨶":"otimesas","⨷":"Otimes","Ö":"Ouml","ö":"ouml","⌽":"ovbar","⏞":"OverBrace","⎴":"tbrk","⏜":"OverParenthesis","¶":"para","⫳":"parsim","⫽":"parsl","∂":"part","П":"Pcy","п":"pcy","%":"percnt",".":"period","‰":"permil","‱":"pertenk","𝔓":"Pfr","𝔭":"pfr","Φ":"Phi","φ":"phi","ϕ":"phiv","☎":"phone","Π":"Pi","π":"pi","ϖ":"piv","ℎ":"planckh","⨣":"plusacir","⨢":"pluscir","+":"plus","⨥":"plusdu","⩲":"pluse","±":"pm","⨦":"plussim","⨧":"plustwo","⨕":"pointint","𝕡":"popf","ℙ":"Popf","£":"pound","⪷":"prap","⪻":"Pr","≺":"pr","≼":"prcue","⪯":"pre","≾":"prsim","⪹":"prnap","⪵":"prnE","⋨":"prnsim","⪳":"prE","′":"prime","″":"Prime","∏":"prod","⌮":"profalar","⌒":"profline","⌓":"profsurf","∝":"prop","⊰":"prurel","𝒫":"Pscr","𝓅":"pscr","Ψ":"Psi","ψ":"psi"," ":"puncsp","𝔔":"Qfr","𝔮":"qfr","𝕢":"qopf","ℚ":"Qopf","⁗":"qprime","𝒬":"Qscr","𝓆":"qscr","⨖":"quatint","?":"quest",'"':"quot","⇛":"rAarr","∽̱":"race","Ŕ":"Racute","ŕ":"racute","√":"Sqrt","⦳":"raemptyv","⟩":"rang","⟫":"Rang","⦒":"rangd","⦥":"range","»":"raquo","⥵":"rarrap","⇥":"rarrb","⤠":"rarrbfs","⤳":"rarrc","→":"rarr","↠":"Rarr","⤞":"rarrfs","⥅":"rarrpl","⥴":"rarrsim","⤖":"Rarrtl","↣":"rarrtl","↝":"rarrw","⤚":"ratail","⤜":"rAtail","∶":"ratio","❳":"rbbrk","}":"rcub","]":"rsqb","⦌":"rbrke","⦎":"rbrksld","⦐":"rbrkslu","Ř":"Rcaron","ř":"rcaron","Ŗ":"Rcedil","ŗ":"rcedil","⌉":"rceil","Р":"Rcy","р":"rcy","⤷":"rdca","⥩":"rdldhar","↳":"rdsh","ℜ":"Re","ℛ":"Rscr","ℝ":"Ropf","▭":"rect","⥽":"rfisht","⌋":"rfloor","𝔯":"rfr","⥤":"rHar","⇀":"rharu","⥬":"rharul","Ρ":"Rho","ρ":"rho","ϱ":"rhov","⇄":"rlarr","⟧":"robrk","⥝":"RightDownTeeVector","⥕":"RightDownVectorBar","⇉":"rrarr","⊢":"vdash","⥛":"RightTeeVector","⋌":"rthree","⧐":"RightTriangleBar","⊳":"vrtri","⊵":"rtrie","⥏":"RightUpDownVector","⥜":"RightUpTeeVector","⥔":"RightUpVectorBar","↾":"uharr","⥓":"RightVectorBar","˚":"ring","‏":"rlm","⎱":"rmoust","⫮":"rnmid","⟭":"roang","⇾":"roarr","⦆":"ropar","𝕣":"ropf","⨮":"roplus","⨵":"rotimes","⥰":"RoundImplies",")":"rpar","⦔":"rpargt","⨒":"rppolint","›":"rsaquo","𝓇":"rscr","↱":"rsh","⋊":"rtimes","▹":"rtri","⧎":"rtriltri","⧴":"RuleDelayed","⥨":"ruluhar","℞":"rx","Ś":"Sacute","ś":"sacute","⪸":"scap","Š":"Scaron","š":"scaron","⪼":"Sc","≻":"sc","≽":"sccue","⪰":"sce","⪴":"scE","Ş":"Scedil","ş":"scedil","Ŝ":"Scirc","ŝ":"scirc","⪺":"scnap","⪶":"scnE","⋩":"scnsim","⨓":"scpolint","≿":"scsim","С":"Scy","с":"scy","⋅":"sdot","⩦":"sdote","⇘":"seArr","§":"sect",";":"semi","⤩":"tosa","✶":"sext","𝔖":"Sfr","𝔰":"sfr","♯":"sharp","Щ":"SHCHcy","щ":"shchcy","Ш":"SHcy","ш":"shcy","↑":"uarr","­":"shy","Σ":"Sigma","σ":"sigma","ς":"sigmaf","∼":"sim","⩪":"simdot","≃":"sime","⪞":"simg","⪠":"simgE","⪝":"siml","⪟":"simlE","≆":"simne","⨤":"simplus","⥲":"simrarr","⨳":"smashp","⧤":"smeparsl","⌣":"smile","⪪":"smt","⪬":"smte","⪬︀":"smtes","Ь":"SOFTcy","ь":"softcy","⌿":"solbar","⧄":"solb","/":"sol","𝕊":"Sopf","𝕤":"sopf","♠":"spades","⊓":"sqcap","⊓︀":"sqcaps","⊔":"sqcup","⊔︀":"sqcups","⊏":"sqsub","⊑":"sqsube","⊐":"sqsup","⊒":"sqsupe","□":"squ","𝒮":"Sscr","𝓈":"sscr","⋆":"Star","☆":"star","⊂":"sub","⋐":"Sub","⪽":"subdot","⫅":"subE","⊆":"sube","⫃":"subedot","⫁":"submult","⫋":"subnE","⊊":"subne","⪿":"subplus","⥹":"subrarr","⫇":"subsim","⫕":"subsub","⫓":"subsup","∑":"sum","♪":"sung","¹":"sup1","²":"sup2","³":"sup3","⊃":"sup","⋑":"Sup","⪾":"supdot","⫘":"supdsub","⫆":"supE","⊇":"supe","⫄":"supedot","⟉":"suphsol","⫗":"suphsub","⥻":"suplarr","⫂":"supmult","⫌":"supnE","⊋":"supne","⫀":"supplus","⫈":"supsim","⫔":"supsub","⫖":"supsup","⇙":"swArr","⤪":"swnwar","ß":"szlig"," ":"Tab","⌖":"target","Τ":"Tau","τ":"tau","Ť":"Tcaron","ť":"tcaron","Ţ":"Tcedil","ţ":"tcedil","Т":"Tcy","т":"tcy","⃛":"tdot","⌕":"telrec","𝔗":"Tfr","𝔱":"tfr","∴":"there4","Θ":"Theta","θ":"theta","ϑ":"thetav","  ":"ThickSpace"," ":"thinsp","Þ":"THORN","þ":"thorn","⨱":"timesbar","×":"times","⨰":"timesd","⌶":"topbot","⫱":"topcir","𝕋":"Topf","𝕥":"topf","⫚":"topfork","‴":"tprime","™":"trade","▵":"utri","≜":"trie","◬":"tridot","⨺":"triminus","⨹":"triplus","⧍":"trisb","⨻":"tritime","⏢":"trpezium","𝒯":"Tscr","𝓉":"tscr","Ц":"TScy","ц":"tscy","Ћ":"TSHcy","ћ":"tshcy","Ŧ":"Tstrok","ŧ":"tstrok","Ú":"Uacute","ú":"uacute","↟":"Uarr","⥉":"Uarrocir","Ў":"Ubrcy","ў":"ubrcy","Ŭ":"Ubreve","ŭ":"ubreve","Û":"Ucirc","û":"ucirc","У":"Ucy","у":"ucy","⇅":"udarr","Ű":"Udblac","ű":"udblac","⥮":"udhar","⥾":"ufisht","𝔘":"Ufr","𝔲":"ufr","Ù":"Ugrave","ù":"ugrave","⥣":"uHar","▀":"uhblk","⌜":"ulcorn","⌏":"ulcrop","◸":"ultri","Ū":"Umacr","ū":"umacr","⏟":"UnderBrace","⏝":"UnderParenthesis","⊎":"uplus","Ų":"Uogon","ų":"uogon","𝕌":"Uopf","𝕦":"uopf","⤒":"UpArrowBar","↕":"varr","υ":"upsi","ϒ":"Upsi","Υ":"Upsilon","⇈":"uuarr","⌝":"urcorn","⌎":"urcrop","Ů":"Uring","ů":"uring","◹":"urtri","𝒰":"Uscr","𝓊":"uscr","⋰":"utdot","Ũ":"Utilde","ũ":"utilde","Ü":"Uuml","ü":"uuml","⦧":"uwangle","⦜":"vangrt","⊊︀":"vsubne","⫋︀":"vsubnE","⊋︀":"vsupne","⫌︀":"vsupnE","⫨":"vBar","⫫":"Vbar","⫩":"vBarv","В":"Vcy","в":"vcy","⊩":"Vdash","⊫":"VDash","⫦":"Vdashl","⊻":"veebar","≚":"veeeq","⋮":"vellip","|":"vert","‖":"Vert","❘":"VerticalSeparator","≀":"wr","𝔙":"Vfr","𝔳":"vfr","𝕍":"Vopf","𝕧":"vopf","𝒱":"Vscr","𝓋":"vscr","⊪":"Vvdash","⦚":"vzigzag","Ŵ":"Wcirc","ŵ":"wcirc","⩟":"wedbar","≙":"wedgeq","℘":"wp","𝔚":"Wfr","𝔴":"wfr","𝕎":"Wopf","𝕨":"wopf","𝒲":"Wscr","𝓌":"wscr","𝔛":"Xfr","𝔵":"xfr","Ξ":"Xi","ξ":"xi","⋻":"xnis","𝕏":"Xopf","𝕩":"xopf","𝒳":"Xscr","𝓍":"xscr","Ý":"Yacute","ý":"yacute","Я":"YAcy","я":"yacy","Ŷ":"Ycirc","ŷ":"ycirc","Ы":"Ycy","ы":"ycy","¥":"yen","𝔜":"Yfr","𝔶":"yfr","Ї":"YIcy","ї":"yicy","𝕐":"Yopf","𝕪":"yopf","𝒴":"Yscr","𝓎":"yscr","Ю":"YUcy","ю":"yucy","ÿ":"yuml","Ÿ":"Yuml","Ź":"Zacute","ź":"zacute","Ž":"Zcaron","ž":"zcaron","З":"Zcy","з":"zcy","Ż":"Zdot","ż":"zdot","ℨ":"Zfr","Ζ":"Zeta","ζ":"zeta","𝔷":"zfr","Ж":"ZHcy","ж":"zhcy","⇝":"zigrarr","𝕫":"zopf","𝒵":"Zscr","𝓏":"zscr","‍":"zwj","‌":"zwnj"},d=/["&'<>`]/g,f={'"':""","&":"&","'":"'","<":"<",">":">","`":"`"},p=/&#(?:[xX][^a-fA-F0-9]|[^0-9xX])/,g=/[\0-\x08\x0B\x0E-\x1F\x7F-\x9F\uFDD0-\uFDEF\uFFFE\uFFFF]|[\uD83F\uD87F\uD8BF\uD8FF\uD93F\uD97F\uD9BF\uD9FF\uDA3F\uDA7F\uDABF\uDAFF\uDB3F\uDB7F\uDBBF\uDBFF][\uDFFE\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,y=/&#([0-9]+)(;?)|&#[xX]([a-fA-F0-9]+)(;?)|&([0-9a-zA-Z]+);|&(Aacute|iacute|Uacute|plusmn|otilde|Otilde|Agrave|agrave|yacute|Yacute|oslash|Oslash|Atilde|atilde|brvbar|Ccedil|ccedil|ograve|curren|divide|Eacute|eacute|Ograve|oacute|Egrave|egrave|ugrave|frac12|frac14|frac34|Ugrave|Oacute|Iacute|ntilde|Ntilde|uacute|middot|Igrave|igrave|iquest|aacute|laquo|THORN|micro|iexcl|icirc|Icirc|Acirc|ucirc|ecirc|Ocirc|ocirc|Ecirc|Ucirc|aring|Aring|aelig|AElig|acute|pound|raquo|acirc|times|thorn|szlig|cedil|COPY|Auml|ordf|ordm|uuml|macr|Uuml|auml|Ouml|ouml|para|nbsp|Euml|quot|QUOT|euml|yuml|cent|sect|copy|sup1|sup2|sup3|Iuml|iuml|shy|eth|reg|not|yen|amp|AMP|REG|uml|ETH|deg|gt|GT|LT|lt)([=a-zA-Z0-9])?/g,m={Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"⁡",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",amp:"&",AMP:"&",andand:"⩕",And:"⩓",and:"∧",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angmsd:"∡",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",apacir:"⩯",ap:"≈",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"⁡",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",barwed:"⌅",Barwed:"⌆",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",because:"∵",Because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxdl:"┐",boxdL:"╕",boxDl:"╖",boxDL:"╗",boxdr:"┌",boxdR:"╒",boxDr:"╓",boxDR:"╔",boxh:"─",boxH:"═",boxhd:"┬",boxHd:"╤",boxhD:"╥",boxHD:"╦",boxhu:"┴",boxHu:"╧",boxhU:"╨",boxHU:"╩",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxul:"┘",boxuL:"╛",boxUl:"╜",boxUL:"╝",boxur:"└",boxuR:"╘",boxUr:"╙",boxUR:"╚",boxv:"│",boxV:"║",boxvh:"┼",boxvH:"╪",boxVh:"╫",boxVH:"╬",boxvl:"┤",boxvL:"╡",boxVl:"╢",boxVL:"╣",boxvr:"├",boxvR:"╞",boxVr:"╟",boxVR:"╠",bprime:"‵",breve:"˘",Breve:"˘",brvbar:"¦",bscr:"𝒷",Bscr:"ℬ",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsolb:"⧅",bsol:"\\",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",capand:"⩄",capbrcup:"⩉",capcap:"⩋",cap:"∩",Cap:"⋒",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",centerdot:"·",CenterDot:"·",cfr:"𝔠",Cfr:"ℭ",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cir:"○",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",colon:":",Colon:"∷",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",conint:"∮",Conint:"∯",ContourIntegral:"∮",copf:"𝕔",Copf:"ℂ",coprod:"∐",Coproduct:"∐",copy:"©",COPY:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",cross:"✗",Cross:"⨯",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",cupbrcap:"⩈",cupcap:"⩆",CupCap:"≍",cup:"∪",Cup:"⋓",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",dagger:"†",Dagger:"‡",daleth:"ℸ",darr:"↓",Darr:"↡",dArr:"⇓",dash:"‐",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",ddagger:"‡",ddarr:"⇊",DD:"ⅅ",dd:"ⅆ",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",diamond:"⋄",Diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrowBar:"⤓",downarrow:"↓",DownArrow:"↓",Downarrow:"⇓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVectorBar:"⥖",DownLeftVector:"↽",DownRightTeeVector:"⥟",DownRightVectorBar:"⥗",DownRightVector:"⇁",DownTeeArrow:"↧",DownTee:"⊤",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",Ecirc:"Ê",ecirc:"ê",ecir:"≖",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",edot:"ė",eDot:"≑",ee:"ⅇ",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp13:" ",emsp14:" ",emsp:" ",ENG:"Ŋ",eng:"ŋ",ensp:" ",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",escr:"ℯ",Escr:"ℰ",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",exponentiale:"ⅇ",ExponentialE:"ⅇ",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",Ffr:"𝔉",ffr:"𝔣",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",forall:"∀",ForAll:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",fscr:"𝒻",Fscr:"ℱ",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",ge:"≥",gE:"≧",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",gescc:"⪩",ges:"⩾",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",gg:"≫",Gg:"⋙",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gla:"⪥",gl:"≷",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gne:"⪈",gnE:"≩",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"ℊ",gsim:"≳",gsime:"⪎",gsiml:"⪐",gtcc:"⪧",gtcir:"⩺",gt:">",GT:">",Gt:"≫",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",HARDcy:"Ъ",hardcy:"ъ",harrcir:"⥈",harr:"↔",hArr:"⇔",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",hfr:"𝔥",Hfr:"ℌ",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",hopf:"𝕙",Hopf:"ℍ",horbar:"―",HorizontalLine:"─",hscr:"𝒽",Hscr:"ℋ",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",Iacute:"Í",iacute:"í",ic:"⁣",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",ifr:"𝔦",Ifr:"ℑ",Igrave:"Ì",igrave:"ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"IJ",ijlig:"ij",Imacr:"Ī",imacr:"ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",Im:"ℑ",imof:"⊷",imped:"Ƶ",Implies:"⇒",incare:"℅","in":"∈",infin:"∞",infintie:"⧝",inodot:"ı",intcal:"⊺","int":"∫",Int:"∬",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"⁣",InvisibleTimes:"⁢",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",iscr:"𝒾",Iscr:"ℐ",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"⁢",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"ℒ",Lambda:"Λ",lambda:"λ",lang:"⟨",Lang:"⟪",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",larrb:"⇤",larrbfs:"⤟",larr:"←",Larr:"↞",lArr:"⇐",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",latail:"⤙",lAtail:"⤛",lat:"⪫",late:"⪭",lates:"⪭︀",lbarr:"⤌",lBarr:"⤎",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",le:"≤",lE:"≦",LeftAngleBracket:"⟨",LeftArrowBar:"⇤",leftarrow:"←",LeftArrow:"←",Leftarrow:"⇐",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVectorBar:"⥙",LeftDownVector:"⇃",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",leftrightarrow:"↔",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTeeArrow:"↤",LeftTee:"⊣",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangleBar:"⧏",LeftTriangle:"⊲",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVectorBar:"⥘",LeftUpVector:"↿",LeftVectorBar:"⥒",LeftVector:"↼",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",lescc:"⪨",les:"⩽",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",llarr:"⇇",ll:"≪",Ll:"⋘",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoustache:"⎰",lmoust:"⎰",lnap:"⪉",lnapprox:"⪉",lne:"⪇",lnE:"≨",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",longleftarrow:"⟵",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftrightarrow:"⟷",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longmapsto:"⟼",longrightarrow:"⟶",LongRightArrow:"⟶",Longrightarrow:"⟹",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"‎",lrtri:"⊿",lsaquo:"‹",lscr:"𝓁",Lscr:"ℒ",lsh:"↰",Lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",Lstrok:"Ł",lstrok:"ł",ltcc:"⪦",ltcir:"⩹",lt:"<",LT:"<",Lt:"≪",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",midast:"*",midcir:"⫰",mid:"∣",middot:"·",minusb:"⊟",minus:"−",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",mscr:"𝓂",Mscr:"ℳ",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natural:"♮",naturals:"ℕ",natur:"♮",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"–",nearhk:"⤤",nearr:"↗",neArr:"⇗",nearrow:"↗",ne:"≠",nedot:"≐̸",NegativeMediumSpace:"​",NegativeThickSpace:"​",NegativeThinSpace:"​",NegativeVeryThinSpace:"​",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:"\n",nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nharr:"↮",nhArr:"⇎",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlarr:"↚",nlArr:"⇍",nldr:"‥",nlE:"≦̸",nle:"≰",nleftarrow:"↚",nLeftarrow:"⇍",nleftrightarrow:"↮",nLeftrightarrow:"⇎",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"⁠",NonBreakingSpace:" ",nopf:"𝕟",Nopf:"ℕ",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangleBar:"⧏̸",NotLeftTriangle:"⋪",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangleBar:"⧐̸",NotRightTriangle:"⋫",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",nparallel:"∦",npar:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",nprec:"⊀",npreceq:"⪯̸",npre:"⪯̸",nrarrc:"⤳̸",nrarr:"↛",nrArr:"⇏",nrarrw:"↝̸",nrightarrow:"↛",nRightarrow:"⇏",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nvdash:"⊬",nvDash:"⊭",nVdash:"⊮",nVDash:"⊯",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwarr:"↖",nwArr:"⇖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",Ocirc:"Ô",ocirc:"ô",ocir:"⊚",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",orarr:"↻",Or:"⩔",or:"∨",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"ℴ",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",otimesas:"⨶",Otimes:"⨷",otimes:"⊗",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",para:"¶",parallel:"∥",par:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plus:"+",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",popf:"𝕡",Popf:"ℙ",pound:"£",prap:"⪷",Pr:"⪻",pr:"≺",prcue:"≼",precapprox:"⪷",prec:"≺",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",pre:"⪯",prE:"⪳",precsim:"≾",prime:"′",Prime:"″",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportional:"∝",Proportion:"∷",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:" ",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",qopf:"𝕢",Qopf:"ℚ",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",quot:'"',QUOT:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",rang:"⟩",Rang:"⟫",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarr:"→",Rarr:"↠",rArr:"⇒",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",ratail:"⤚",rAtail:"⤜",ratio:"∶",rationals:"ℚ",rbarr:"⤍",rBarr:"⤏",RBarr:"⤐",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",Re:"ℜ",rect:"▭",reg:"®",REG:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",rfr:"𝔯",Rfr:"ℜ",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩", RightArrowBar:"⇥",rightarrow:"→",RightArrow:"→",Rightarrow:"⇒",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVectorBar:"⥕",RightDownVector:"⇂",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTeeArrow:"↦",RightTee:"⊢",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangleBar:"⧐",RightTriangle:"⊳",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVectorBar:"⥔",RightUpVector:"↾",RightVectorBar:"⥓",RightVector:"⇀",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"‏",rmoustache:"⎱",rmoust:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",ropf:"𝕣",Ropf:"ℝ",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",rscr:"𝓇",Rscr:"ℛ",rsh:"↱",Rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"‚",scap:"⪸",Scaron:"Š",scaron:"š",Sc:"⪼",sc:"≻",sccue:"≽",sce:"⪰",scE:"⪴",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdotb:"⊡",sdot:"⋅",sdote:"⩦",searhk:"⤥",searr:"↘",seArr:"⇘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",solbar:"⌿",solb:"⧄",sol:"/",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",square:"□",Square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squ:"□",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",sub:"⊂",Sub:"⋐",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",subset:"⊂",Subset:"⋐",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succapprox:"⪸",succ:"≻",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",sum:"∑",Sum:"∑",sung:"♪",sup1:"¹",sup2:"²",sup3:"³",sup:"⊃",Sup:"⋑",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",supset:"⊃",Supset:"⋑",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swarr:"↙",swArr:"⇙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:" ",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",therefore:"∴",Therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:"  ",ThinSpace:" ",thinsp:" ",thkap:"≈",thksim:"∼",THORN:"Þ",thorn:"þ",tilde:"˜",Tilde:"∼",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",timesbar:"⨱",timesb:"⊠",times:"×",timesd:"⨰",tint:"∭",toea:"⤨",topbot:"⌶",topcir:"⫱",top:"⊤",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",trade:"™",TRADE:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",uarr:"↑",Uarr:"↟",uArr:"⇑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrowBar:"⤒",uparrow:"↑",UpArrow:"↑",Uparrow:"⇑",UpArrowDownArrow:"⇅",updownarrow:"↕",UpDownArrow:"↕",Updownarrow:"⇕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",upsi:"υ",Upsi:"ϒ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTeeArrow:"↥",UpTee:"⊥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",varr:"↕",vArr:"⇕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",vBar:"⫨",Vbar:"⫫",vBarv:"⫩",Vcy:"В",vcy:"в",vdash:"⊢",vDash:"⊨",Vdash:"⊩",VDash:"⊫",Vdashl:"⫦",veebar:"⊻",vee:"∨",Vee:"⋁",veeeq:"≚",vellip:"⋮",verbar:"|",Verbar:"‖",vert:"|",Vert:"‖",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",wedge:"∧",Wedge:"⋀",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xharr:"⟷",xhArr:"⟺",Xi:"Ξ",xi:"ξ",xlarr:"⟵",xlArr:"⟸",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrarr:"⟶",xrArr:"⟹",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",yuml:"ÿ",Yuml:"Ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"ℨ",ZeroWidthSpace:"​",Zeta:"Ζ",zeta:"ζ",zfr:"𝔷",Zfr:"ℨ",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",zopf:"𝕫",Zopf:"ℤ",Zscr:"𝒵",zscr:"𝓏",zwj:"‍",zwnj:"‌"},v={Aacute:"Á",aacute:"á",Acirc:"Â",acirc:"â",acute:"´",AElig:"Æ",aelig:"æ",Agrave:"À",agrave:"à",amp:"&",AMP:"&",Aring:"Å",aring:"å",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",brvbar:"¦",Ccedil:"Ç",ccedil:"ç",cedil:"¸",cent:"¢",copy:"©",COPY:"©",curren:"¤",deg:"°",divide:"÷",Eacute:"É",eacute:"é",Ecirc:"Ê",ecirc:"ê",Egrave:"È",egrave:"è",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",frac12:"½",frac14:"¼",frac34:"¾",gt:">",GT:">",Iacute:"Í",iacute:"í",Icirc:"Î",icirc:"î",iexcl:"¡",Igrave:"Ì",igrave:"ì",iquest:"¿",Iuml:"Ï",iuml:"ï",laquo:"«",lt:"<",LT:"<",macr:"¯",micro:"µ",middot:"·",nbsp:" ",not:"¬",Ntilde:"Ñ",ntilde:"ñ",Oacute:"Ó",oacute:"ó",Ocirc:"Ô",ocirc:"ô",Ograve:"Ò",ograve:"ò",ordf:"ª",ordm:"º",Oslash:"Ø",oslash:"ø",Otilde:"Õ",otilde:"õ",Ouml:"Ö",ouml:"ö",para:"¶",plusmn:"±",pound:"£",quot:'"',QUOT:'"',raquo:"»",reg:"®",REG:"®",sect:"§",shy:"­",sup1:"¹",sup2:"²",sup3:"³",szlig:"ß",THORN:"Þ",thorn:"þ",times:"×",Uacute:"Ú",uacute:"ú",Ucirc:"Û",ucirc:"û",Ugrave:"Ù",ugrave:"ù",uml:"¨",Uuml:"Ü",uuml:"ü",Yacute:"Ý",yacute:"ý",yen:"¥",yuml:"ÿ"},b={0:"�",128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"},_=[1,2,3,4,5,6,7,8,11,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,64976,64977,64978,64979,64980,64981,64982,64983,64984,64985,64986,64987,64988,64989,64990,64991,64992,64993,64994,64995,64996,64997,64998,64999,65e3,65001,65002,65003,65004,65005,65006,65007,65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111],A=String.fromCharCode,w={},x=w.hasOwnProperty,E=function(t,e){return x.call(t,e)},D=function(t,e){for(var r=-1,n=t.length;++r=55296&&57343>=t||t>1114111?(e&&T("character reference outside the permissible Unicode range"),"�"):E(b,t)?(e&&T("disallowed character reference"),b[t]):(e&&D(_,t)&&T("disallowed character reference"),t>65535&&(t-=65536,r+=A(t>>>10&1023|55296),t=56320|1023&t),r+=A(t))},F=function(t){return"&#x"+t.charCodeAt(0).toString(16).toUpperCase()+";"},T=function(t){throw Error("Parse error: "+t)},S=function(t,e){e=k(e,S.options);var r=e.strict;r&&g.test(t)&&T("forbidden code point");var n=e.encodeEverything,i=e.useNamedReferences,a=e.allowUnsafeSymbols;return n?(t=t.replace(u,function(t){return i&&E(h,t)?"&"+h[t]+";":F(t)}),i&&(t=t.replace(/>\u20D2/g,">⃒").replace(/<\u20D2/g,"<⃒").replace(/fj/g,"fj")),i&&(t=t.replace(l,function(t){return"&"+h[t]+";"}))):i?(a||(t=t.replace(d,function(t){return"&"+h[t]+";"})),t=t.replace(/>\u20D2/g,">⃒").replace(/<\u20D2/g,"<⃒"),t=t.replace(l,function(t){return"&"+h[t]+";"})):a||(t=t.replace(d,F)),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,F)};S.options={allowUnsafeSymbols:!1,encodeEverything:!1,strict:!1,useNamedReferences:!1};var B=function(t,e){e=k(e,B.options);var r=e.strict;return r&&p.test(t)&&T("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&&T("character reference was not terminated by a semicolon"),C(l,r)):a?(d=a,h=s,r&&!h&&T("character reference was not terminated by a semicolon"),l=parseInt(d,16),C(l,r)):o?(f=o,E(m,f)?m[f]:(r&&T("named character reference was not terminated by a semicolon"),t)):(f=u,p=c,p&&e.isAttributeValue?(r&&"="==p&&T("`&` did not start a character reference"),t):(r&&T("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)E(O,I)&&(i[I]=O[I]);else n.he=O}(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],105:[function(t,e,r){!function(t,n){"object"==typeof r&&"undefined"!=typeof e?e.exports=n():"function"==typeof define&&define.amd?define(n):t.moment=n()}(this,function(){"use strict";function r(){return Nr.apply(null,arguments)}function n(t){Nr=t}function i(t){return"[object Array]"===Object.prototype.toString.call(t)}function a(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function s(t,e){var r,n=[];for(r=0;r0)for(r in Pr)n=Pr[r],i=e[n],"undefined"!=typeof i&&(t[n]=i);return t}function g(t){p(this,t),this._d=new Date(null!=t._d?t._d.getTime():0/0),Rr===!1&&(Rr=!0,r.updateOffset(this),Rr=!1)}function y(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function m(t){return 0>t?Math.ceil(t):Math.floor(t)}function v(t){var e=+t,r=0;return 0!==e&&isFinite(e)&&(r=m(e)),r}function b(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&&v(t[n])!==v(e[n]))&&s++;return s+a}function _(){}function A(t){return t?t.toLowerCase().replace("_","-"):t}function w(t){for(var e,r,n,i,a=0;a0;){if(n=x(i.slice(0,e).join("-")))return n;if(r&&r.length>=e&&b(i,r,!0)>=e-1)break;e--}a++}return null}function x(r){var n=null;if(!qr[r]&&"undefined"!=typeof e&&e&&e.exports)try{n=Mr._abbr,t("./locale/"+r),E(n)}catch(i){}return qr[r]}function E(t,e){var r;return t&&(r="undefined"==typeof e?k(t):D(t,e),r&&(Mr=r)),Mr._abbr}function D(t,e){return null!==e?(e.abbr=t,qr[t]=qr[t]||new _,qr[t].set(e),E(t),qr[t]):(delete qr[t],null)}function k(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Mr;if(!i(t)){if(e=x(t))return e;t=[t]}return w(t)}function C(t,e){var r=t.toLowerCase();jr[r]=jr[r+"s"]=jr[e]=t}function F(t){return"string"==typeof t?jr[t]||jr[t.toLowerCase()]:void 0}function T(t){var e,r,n={};for(r in t)o(t,r)&&(e=F(r),e&&(n[e]=t[r]));return n}function S(t,e){return function(n){return null!=n?(L(this,t,n),r.updateOffset(this,e),this):B(this,t)}}function B(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function L(t,e,r){return t._d["set"+(t._isUTC?"UTC":"")+e](r)}function O(t,e){var r;if("object"==typeof t)for(r in t)this.set(r,t[r]);else if(t=F(t),"function"==typeof this[t])return this[t](e);return this}function I(t,e,r){var n=""+Math.abs(t),i=e-n.length,a=t>=0;return(a?r?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+n}function N(t,e,r,n){var i=n;"string"==typeof n&&(i=function(){return this[n]()}),t&&(Vr[t]=i),e&&(Vr[e[0]]=function(){return I(i.apply(this,arguments),e[1],e[2])}),r&&(Vr[r]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function M(t){return t.match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"")}function P(t){var e,r,n=t.match(Ur);for(e=0,r=n.length;r>e;e++)n[e]=Vr[n[e]]?Vr[n[e]]:M(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 R(t,e){return t.isValid()?(e=q(e,t.localeData()),Gr[e]=Gr[e]||P(e),Gr[e](t)):t.localeData().invalidDate()}function q(t,e){function r(t){return e.longDateFormat(t)||t}var n=5;for(Yr.lastIndex=0;n>=0&&Yr.test(t);)t=t.replace(Yr,r),Yr.lastIndex=0,n-=1;return t}function j(t){return"function"==typeof t&&"[object Function]"===Object.prototype.toString.call(t)}function U(t,e,r){sn[t]=j(e)?e:function(t){return t&&r?r:e}}function Y(t,e){return o(sn,t)?sn[t](e._strict,e._locale):new RegExp(G(t))}function G(t){return t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,r,n,i){return e||r||n||i}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function V(t,e){var r,n=e;for("string"==typeof t&&(t=[t]),"number"==typeof e&&(n=function(t,r){r[e]=v(t)}),r=0;rn;n++){if(i=c([2e3,n]),r&&!this._longMonthsParse[n]&&(this._longMonthsParse[n]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[n]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),r||this._monthsParse[n]||(a="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[n]=new RegExp(a.replace(".",""),"i")),r&&"MMMM"===e&&this._longMonthsParse[n].test(t))return n;if(r&&"MMM"===e&&this._shortMonthsParse[n].test(t))return n;if(!r&&this._monthsParse[n].test(t))return n}}function K(t,e){var r;return"string"==typeof e&&(e=t.localeData().monthsParse(e),"number"!=typeof e)?t:(r=Math.min(t.date(),W(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,r),t)}function J(t){return null!=t?(K(this,t),r.updateOffset(this,!0),this):B(this,"Month")}function Q(){return W(this.year(),this.month())}function tt(t){var e,r=t._a;return r&&-2===h(t).overflow&&(e=r[cn]<0||r[cn]>11?cn:r[ln]<1||r[ln]>W(r[un],r[cn])?ln:r[hn]<0||r[hn]>24||24===r[hn]&&(0!==r[dn]||0!==r[fn]||0!==r[pn])?hn:r[dn]<0||r[dn]>59?dn:r[fn]<0||r[fn]>59?fn:r[pn]<0||r[pn]>999?pn:-1,h(t)._overflowDayOfYear&&(un>e||e>ln)&&(e=ln),h(t).overflow=e),t}function et(t){r.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function rt(t,e){var r=!0;return u(function(){return r&&(et(t+"\n"+(new Error).stack),r=!1),e.apply(this,arguments)},e)}function nt(t,e){mn[t]||(et(e),mn[t]=!0)}function it(t){var e,r,n=t._i,i=vn.exec(n);if(i){for(h(t).iso=!0,e=0,r=bn.length;r>e;e++)if(bn[e][1].exec(n)){t._f=bn[e][0];break}for(e=0,r=_n.length;r>e;e++)if(_n[e][1].exec(n)){t._f+=(i[6]||" ")+_n[e][0];break}n.match(rn)&&(t._f+="Z"),xt(t)}else t._isValid=!1}function at(t){var e=An.exec(t._i);return null!==e?void(t._d=new Date(+e[1])):(it(t),void(t._isValid===!1&&(delete t._isValid,r.createFromInputFallback(t))))}function st(t,e,r,n,i,a,s){var o=new Date(t,e,r,n,i,a,s);return 1970>t&&o.setFullYear(t),o}function ot(t){var e=new Date(Date.UTC.apply(null,arguments));return 1970>t&&e.setUTCFullYear(t),e}function ut(t){return ct(t)?366:365}function ct(t){return t%4===0&&t%100!==0||t%400===0}function lt(){return ct(this.year())}function ht(t,e,r){var n,i=r-e,a=r-t.day();return a>i&&(a-=7),i-7>a&&(a+=7),n=Bt(t).add(a,"d"),{week:Math.ceil(n.dayOfYear()/7),year:n.year()}}function dt(t){return ht(t,this._week.dow,this._week.doy).week}function ft(){return this._week.dow}function pt(){return this._week.doy}function gt(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")}function yt(t){var e=ht(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")}function mt(t,e,r,n,i){var a,s=6+i-n,o=ot(t,0,1+s),u=o.getUTCDay();return i>u&&(u+=7),r=null!=r?1*r:i,a=1+s+7*(e-1)-u+r,{year:a>0?t:t-1,dayOfYear:a>0?a:ut(t-1)+a}}function vt(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")}function bt(t,e,r){return null!=t?t:null!=e?e:r}function _t(t){var e=new Date;return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function At(t){var e,r,n,i,a=[];if(!t._d){for(n=_t(t),t._w&&null==t._a[ln]&&null==t._a[cn]&&wt(t),t._dayOfYear&&(i=bt(t._a[un],n[un]),t._dayOfYear>ut(i)&&(h(t)._overflowDayOfYear=!0),r=ot(i,0,t._dayOfYear),t._a[cn]=r.getUTCMonth(),t._a[ln]=r.getUTCDate()),e=0;3>e&&null==t._a[e];++e)t._a[e]=a[e]=n[e];for(;7>e;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[hn]&&0===t._a[dn]&&0===t._a[fn]&&0===t._a[pn]&&(t._nextDay=!0,t._a[hn]=0),t._d=(t._useUTC?ot:st).apply(null,a),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[hn]=24)}}function wt(t){var e,r,n,i,a,s,o;e=t._w,null!=e.GG||null!=e.W||null!=e.E?(a=1,s=4,r=bt(e.GG,t._a[un],ht(Bt(),1,4).year),n=bt(e.W,1),i=bt(e.E,1)):(a=t._locale._week.dow,s=t._locale._week.doy,r=bt(e.gg,t._a[un],ht(Bt(),a,s).year),n=bt(e.w,1),null!=e.d?(i=e.d,a>i&&++n):i=null!=e.e?e.e+a:a),o=mt(r,n,i,s,a),t._a[un]=o.year,t._dayOfYear=o.dayOfYear}function xt(t){if(t._f===r.ISO_8601)return void it(t);t._a=[],h(t).empty=!0;var e,n,i,a,s,o=""+t._i,u=o.length,c=0;for(i=q(t._f,t._locale).match(Ur)||[],e=0;e0&&h(t).unusedInput.push(s),o=o.slice(o.indexOf(n)+n.length),c+=n.length),Vr[a]?(n?h(t).empty=!1:h(t).unusedTokens.push(a),H(a,n,t)):t._strict&&!n&&h(t).unusedTokens.push(a);h(t).charsLeftOver=u-c,o.length>0&&h(t).unusedInput.push(o),h(t).bigHour===!0&&t._a[hn]<=12&&t._a[hn]>0&&(h(t).bigHour=void 0),t._a[hn]=Et(t._locale,t._a[hn],t._meridiem),At(t),tt(t)}function Et(t,e,r){var n;return null==r?e:null!=t.meridiemHour?t.meridiemHour(e,r):null!=t.isPM?(n=t.isPM(r),n&&12>e&&(e+=12),n||12!==e||(e=0),e):e}function Dt(t){var e,r,n,i,a;if(0===t._f.length)return h(t).invalidFormat=!0,void(t._d=new Date(0/0));for(i=0;ia)&&(n=a,r=e));u(t,r||e)}function kt(t){if(!t._d){var e=T(t._i);t._a=[e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],At(t)}}function Ct(t){var e=new g(tt(Ft(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=void 0),e}function Ft(t){var e=t._i,r=t._f;return t._locale=t._locale||k(t._l),null===e||void 0===r&&""===e?f({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),y(e)?new g(tt(e)):(i(r)?Dt(t):r?xt(t):a(e)?t._d=e:Tt(t),t))}function Tt(t){var e=t._i;void 0===e?t._d=new Date:a(e)?t._d=new Date(+e):"string"==typeof e?at(t):i(e)?(t._a=s(e.slice(0),function(t){return parseInt(t,10)}),At(t)):"object"==typeof e?kt(t):"number"==typeof e?t._d=new Date(e):r.createFromInputFallback(t)}function St(t,e,r,n,i){var a={};return"boolean"==typeof r&&(n=r,r=void 0),a._isAMomentObject=!0,a._useUTC=a._isUTC=i,a._l=r,a._i=t,a._f=e,a._strict=n,Ct(a)}function Bt(t,e,r,n){return St(t,e,r,n,!1)}function Lt(t,e){var r,n;if(1===e.length&&i(e[0])&&(e=e[0]),!e.length)return Bt();for(r=e[0],n=1;nt&&(t=-t,r="-"),r+I(~~(t/60),2)+e+I(~~t%60,2)})}function Rt(t){var e=(t||"").match(rn)||[],r=e[e.length-1]||[],n=(r+"").match(kn)||["-",0,0],i=+(60*n[1])+v(n[2]);return"+"===n[0]?i:-i}function qt(t,e){var n,i;return e._isUTC?(n=e.clone(),i=(y(t)||a(t)?+t:+Bt(t))-+n,n._d.setTime(+n._d+i),r.updateOffset(n,!1),n):Bt(t).local()}function jt(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function Ut(t,e){var n,i=this._offset||0;return null!=t?("string"==typeof t&&(t=Rt(t)),Math.abs(t)<16&&(t=60*t),!this._isUTC&&e&&(n=jt(this)),this._offset=t,this._isUTC=!0,null!=n&&this.add(n,"m"),i!==t&&(!e||this._changeInProgress?ne(this,Jt(t-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,r.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?i:jt(this)}function Yt(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function Gt(t){return this.utcOffset(0,t)}function Vt(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(jt(this),"m")),this}function $t(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(Rt(this._i)),this}function Ht(t){return t=t?Bt(t).utcOffset():0,(this.utcOffset()-t)%60===0}function Wt(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function zt(){if("undefined"!=typeof this._isDSTShifted)return this._isDSTShifted;var t={};if(p(t,this),t=Ft(t),t._a){var e=t._isUTC?c(t._a):Bt(t._a);this._isDSTShifted=this.isValid()&&b(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Zt(){return!this._isUTC}function Xt(){return this._isUTC}function Kt(){return this._isUTC&&0===this._offset}function Jt(t,e){var r,n,i,a=t,s=null;return Mt(t)?a={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(a={},e?a[e]=t:a.milliseconds=t):(s=Cn.exec(t))?(r="-"===s[1]?-1:1,a={y:0,d:v(s[ln])*r,h:v(s[hn])*r,m:v(s[dn])*r,s:v(s[fn])*r,ms:v(s[pn])*r}):(s=Fn.exec(t))?(r="-"===s[1]?-1:1,a={y:Qt(s[2],r),M:Qt(s[3],r),d:Qt(s[4],r),h:Qt(s[5],r),m:Qt(s[6],r),s:Qt(s[7],r),w:Qt(s[8],r)}):null==a?a={}:"object"==typeof a&&("from"in a||"to"in a)&&(i=ee(Bt(a.from),Bt(a.to)),a={},a.ms=i.milliseconds,a.M=i.months),n=new Nt(a),Mt(t)&&o(t,"_locale")&&(n._locale=t._locale),n}function Qt(t,e){var r=t&&parseFloat(t.replace(",","."));return(isNaN(r)?0:r)*e}function te(t,e){var r={milliseconds:0,months:0};return r.months=e.month()-t.month()+12*(e.year()-t.year()),t.clone().add(r.months,"M").isAfter(e)&&--r.months,r.milliseconds=+e-+t.clone().add(r.months,"M"),r}function ee(t,e){var r;return e=qt(e,t),t.isBefore(e)?r=te(t,e):(r=te(e,t),r.milliseconds=-r.milliseconds,r.months=-r.months),r}function re(t,e){return function(r,n){var i,a;return null===n||isNaN(+n)||(nt(e,"moment()."+e+"(period, number) is deprecated. Please use moment()."+e+"(number, period)."),a=r,r=n,n=a),r="string"==typeof r?+r:r,i=Jt(r,n),ne(this,i,t),this}}function ne(t,e,n,i){var a=e._milliseconds,s=e._days,o=e._months;i=null==i?!0:i,a&&t._d.setTime(+t._d+a*n),s&&L(t,"Date",B(t,"Date")+s*n),o&&K(t,B(t,"Month")+o*n),i&&r.updateOffset(t,s||o)}function ie(t,e){var r=t||Bt(),n=qt(r,this).startOf("day"),i=this.diff(n,"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,Bt(r)))}function ae(){return new g(this)}function se(t,e){var r;return e=F("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Bt(t),+this>+t):(r=y(t)?+t:+Bt(t),r<+this.clone().startOf(e))}function oe(t,e){var r;return e=F("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Bt(t),+t>+this):(r=y(t)?+t:+Bt(t),+this.clone().endOf(e)e-a?(r=t.clone().add(i-1,"months"),n=(e-a)/(a-r)):(r=t.clone().add(i+1,"months"),n=(e-a)/(r-a)),-(i+n)}function de(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function fe(){var t=this.clone().utc();return 0e;e++)if(this._weekdaysParse[e]||(r=Bt([2e3,1]).day(e),n="^"+this.weekdays(r,"")+"|^"+this.weekdaysShort(r,"")+"|^"+this.weekdaysMin(r,""),this._weekdaysParse[e]=new RegExp(n.replace(".",""),"i")),this._weekdaysParse[e].test(t))return e}function Ge(t){var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=Re(t,this.localeData()),this.add(t-e,"d")):e}function Ve(t){var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")}function $e(t){return null==t?this.day()||7:this.day(this.day()%7?t:t-7)}function He(t,e){N(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}function We(t,e){return e._meridiemParse}function ze(t){return"p"===(t+"").toLowerCase().charAt(0)}function Ze(t,e,r){return t>11?r?"pm":"PM":r?"am":"AM"}function Xe(t,e){e[pn]=v(1e3*("0."+t))}function Ke(){return this._isUTC?"UTC":""}function Je(){return this._isUTC?"Coordinated Universal Time":""}function Qe(t){return Bt(1e3*t)}function tr(){return Bt.apply(null,arguments).parseZone()}function er(t,e,r){var n=this._calendar[t];return"function"==typeof n?n.call(e,r):n}function rr(t){var e=this._longDateFormat[t],r=this._longDateFormat[t.toUpperCase()];return e||!r?e:(this._longDateFormat[t]=r.replace(/MMMM|MM|DD|dddd/g,function(t){ -return t.slice(1)}),this._longDateFormat[t])}function nr(){return this._invalidDate}function ir(t){return this._ordinal.replace("%d",t)}function ar(t){return t}function sr(t,e,r,n){var i=this._relativeTime[r];return"function"==typeof i?i(t,e,r,n):i.replace(/%d/i,t)}function or(t,e){var r=this._relativeTime[t>0?"future":"past"];return"function"==typeof r?r(e):r.replace(/%s/i,e)}function ur(t){var e,r;for(r in t)e=t[r],"function"==typeof e?this[r]=e:this["_"+r]=e;this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function cr(t,e,r,n){var i=k(),a=c().set(n,e);return i[r](a,t)}function lr(t,e,r,n,i){if("number"==typeof t&&(e=t,t=void 0),t=t||"",null!=e)return cr(t,e,r,i);var a,s=[];for(a=0;n>a;a++)s[a]=cr(t,a,r,i);return s}function hr(t,e){return lr(t,e,"months",12,"month")}function dr(t,e){return lr(t,e,"monthsShort",12,"month")}function fr(t,e){return lr(t,e,"weekdays",7,"day")}function pr(t,e){return lr(t,e,"weekdaysShort",7,"day")}function gr(t,e){return lr(t,e,"weekdaysMin",7,"day")}function yr(){var t=this._data;return this._milliseconds=Kn(this._milliseconds),this._days=Kn(this._days),this._months=Kn(this._months),t.milliseconds=Kn(t.milliseconds),t.seconds=Kn(t.seconds),t.minutes=Kn(t.minutes),t.hours=Kn(t.hours),t.months=Kn(t.months),t.years=Kn(t.years),this}function mr(t,e,r,n){var i=Jt(e,r);return t._milliseconds+=n*i._milliseconds,t._days+=n*i._days,t._months+=n*i._months,t._bubble()}function vr(t,e){return mr(this,t,e,1)}function br(t,e){return mr(this,t,e,-1)}function _r(t){return 0>t?Math.floor(t):Math.ceil(t)}function Ar(){var t,e,r,n,i,a=this._milliseconds,s=this._days,o=this._months,u=this._data;return a>=0&&s>=0&&o>=0||0>=a&&0>=s&&0>=o||(a+=864e5*_r(xr(o)+s),s=0,o=0),u.milliseconds=a%1e3,t=m(a/1e3),u.seconds=t%60,e=m(t/60),u.minutes=e%60,r=m(e/60),u.hours=r%24,s+=m(r/24),i=m(wr(s)),o+=i,s-=_r(xr(i)),n=m(o/12),o%=12,u.days=s,u.months=o,u.years=n,this}function wr(t){return 4800*t/146097}function xr(t){return 146097*t/4800}function Er(t){var e,r,n=this._milliseconds;if(t=F(t),"month"===t||"year"===t)return e=this._days+n/864e5,r=this._months+wr(e),"month"===t?r:r/12;switch(e=this._days+Math.round(xr(this._months)),t){case"week":return e/7+n/6048e5;case"day":return e+n/864e5;case"hour":return 24*e+n/36e5;case"minute":return 1440*e+n/6e4;case"second":return 86400*e+n/1e3;case"millisecond":return Math.floor(864e5*e)+n;default:throw new Error("Unknown unit "+t)}}function Dr(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function kr(t){return function(){return this.as(t)}}function Cr(t){return t=F(t),this[t+"s"]()}function Fr(t){return function(){return this._data[t]}}function Tr(){return m(this.days()/7)}function Sr(t,e,r,n,i){return i.relativeTime(e||1,!!r,t,n)}function Br(t,e,r){var n=Jt(t).abs(),i=fi(n.as("s")),a=fi(n.as("m")),s=fi(n.as("h")),o=fi(n.as("d")),u=fi(n.as("M")),c=fi(n.as("y")),l=i0,l[4]=r,Sr.apply(null,l)}function Lr(t,e){return void 0===pi[t]?!1:void 0===e?pi[t]:(pi[t]=e,!0)}function Or(t){var e=this.localeData(),r=Br(this,!t,e);return t&&(r=e.pastFuture(+this,r)),e.postformat(r)}function Ir(){var t,e,r,n=gi(this._milliseconds)/1e3,i=gi(this._days),a=gi(this._months);t=m(n/60),e=m(t/60),n%=60,t%=60,r=m(a/12),a%=12;var s=r,o=a,u=i,c=e,l=t,h=n,d=this.asSeconds();return d?(0>d?"-":"")+"P"+(s?s+"Y":"")+(o?o+"M":"")+(u?u+"D":"")+(c||l||h?"T":"")+(c?c+"H":"")+(l?l+"M":"")+(h?h+"S":""):"P0D"}var Nr,Mr,Pr=r.momentProperties=[],Rr=!1,qr={},jr={},Ur=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Yr=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Gr={},Vr={},$r=/\d/,Hr=/\d\d/,Wr=/\d{3}/,zr=/\d{4}/,Zr=/[+-]?\d{6}/,Xr=/\d\d?/,Kr=/\d{1,3}/,Jr=/\d{1,4}/,Qr=/[+-]?\d{1,6}/,tn=/\d+/,en=/[+-]?\d+/,rn=/Z|[+-]\d\d:?\d\d/gi,nn=/[+-]?\d+(\.\d{1,3})?/,an=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,sn={},on={},un=0,cn=1,ln=2,hn=3,dn=4,fn=5,pn=6;N("M",["MM",2],"Mo",function(){return this.month()+1}),N("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),N("MMMM",0,0,function(t){return this.localeData().months(this,t)}),C("month","M"),U("M",Xr),U("MM",Xr,Hr),U("MMM",an),U("MMMM",an),V(["M","MM"],function(t,e){e[cn]=v(t)-1}),V(["MMM","MMMM"],function(t,e,r,n){var i=r._locale.monthsParse(t,n,r._strict);null!=i?e[cn]=i:h(r).invalidMonth=t});var gn="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),yn="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),mn={};r.suppressDeprecationWarnings=!1;var vn=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,bn=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],_n=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],An=/^\/?Date\((\-?\d+)/i;r.createFromInputFallback=rt("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),N(0,["YY",2],0,function(){return this.year()%100}),N(0,["YYYY",4],0,"year"),N(0,["YYYYY",5],0,"year"),N(0,["YYYYYY",6,!0],0,"year"),C("year","y"),U("Y",en),U("YY",Xr,Hr),U("YYYY",Jr,zr),U("YYYYY",Qr,Zr),U("YYYYYY",Qr,Zr),V(["YYYYY","YYYYYY"],un),V("YYYY",function(t,e){e[un]=2===t.length?r.parseTwoDigitYear(t):v(t)}),V("YY",function(t,e){e[un]=r.parseTwoDigitYear(t)}),r.parseTwoDigitYear=function(t){return v(t)+(v(t)>68?1900:2e3)};var wn=S("FullYear",!1);N("w",["ww",2],"wo","week"),N("W",["WW",2],"Wo","isoWeek"),C("week","w"),C("isoWeek","W"),U("w",Xr),U("ww",Xr,Hr),U("W",Xr),U("WW",Xr,Hr),$(["w","ww","W","WW"],function(t,e,r,n){e[n.substr(0,1)]=v(t)});var xn={dow:0,doy:6};N("DDD",["DDDD",3],"DDDo","dayOfYear"),C("dayOfYear","DDD"),U("DDD",Kr),U("DDDD",Wr),V(["DDD","DDDD"],function(t,e,r){r._dayOfYear=v(t)}),r.ISO_8601=function(){};var En=rt("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var t=Bt.apply(null,arguments);return this>t?this:t}),Dn=rt("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var t=Bt.apply(null,arguments);return t>this?this:t});Pt("Z",":"),Pt("ZZ",""),U("Z",rn),U("ZZ",rn),V(["Z","ZZ"],function(t,e,r){r._useUTC=!0,r._tzm=Rt(t)});var kn=/([\+\-]|\d\d)/gi;r.updateOffset=function(){};var Cn=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Fn=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/;Jt.fn=Nt.prototype;var Tn=re(1,"add"),Sn=re(-1,"subtract");r.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var Bn=rt("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return void 0===t?this.localeData():this.locale(t)});N(0,["gg",2],0,function(){return this.weekYear()%100}),N(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Be("gggg","weekYear"),Be("ggggg","weekYear"),Be("GGGG","isoWeekYear"),Be("GGGGG","isoWeekYear"),C("weekYear","gg"),C("isoWeekYear","GG"),U("G",en),U("g",en),U("GG",Xr,Hr),U("gg",Xr,Hr),U("GGGG",Jr,zr),U("gggg",Jr,zr),U("GGGGG",Qr,Zr),U("ggggg",Qr,Zr),$(["gggg","ggggg","GGGG","GGGGG"],function(t,e,r,n){e[n.substr(0,2)]=v(t)}),$(["gg","GG"],function(t,e,n,i){e[i]=r.parseTwoDigitYear(t)}),N("Q",0,0,"quarter"),C("quarter","Q"),U("Q",$r),V("Q",function(t,e){e[cn]=3*(v(t)-1)}),N("D",["DD",2],"Do","date"),C("date","D"),U("D",Xr),U("DD",Xr,Hr),U("Do",function(t,e){return t?e._ordinalParse:e._ordinalParseLenient}),V(["D","DD"],ln),V("Do",function(t,e){e[ln]=v(t.match(Xr)[0],10)});var Ln=S("Date",!0);N("d",0,"do","day"),N("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),N("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),N("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),N("e",0,0,"weekday"),N("E",0,0,"isoWeekday"),C("day","d"),C("weekday","e"),C("isoWeekday","E"),U("d",Xr),U("e",Xr),U("E",Xr),U("dd",an),U("ddd",an),U("dddd",an),$(["dd","ddd","dddd"],function(t,e,r){var n=r._locale.weekdaysParse(t);null!=n?e.d=n:h(r).invalidWeekday=t}),$(["d","e","E"],function(t,e,r,n){e[n]=v(t)});var On="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),In="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Nn="Su_Mo_Tu_We_Th_Fr_Sa".split("_");N("H",["HH",2],0,"hour"),N("h",["hh",2],0,function(){return this.hours()%12||12}),He("a",!0),He("A",!1),C("hour","h"),U("a",We),U("A",We),U("H",Xr),U("h",Xr),U("HH",Xr,Hr),U("hh",Xr,Hr),V(["H","HH"],hn),V(["a","A"],function(t,e,r){r._isPm=r._locale.isPM(t),r._meridiem=t}),V(["h","hh"],function(t,e,r){e[hn]=v(t),h(r).bigHour=!0});var Mn=/[ap]\.?m?\.?/i,Pn=S("Hours",!0);N("m",["mm",2],0,"minute"),C("minute","m"),U("m",Xr),U("mm",Xr,Hr),V(["m","mm"],dn);var Rn=S("Minutes",!1);N("s",["ss",2],0,"second"),C("second","s"),U("s",Xr),U("ss",Xr,Hr),V(["s","ss"],fn);var qn=S("Seconds",!1);N("S",0,0,function(){return~~(this.millisecond()/100)}),N(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),N(0,["SSS",3],0,"millisecond"),N(0,["SSSS",4],0,function(){return 10*this.millisecond()}),N(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),N(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),N(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),N(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),N(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),C("millisecond","ms"),U("S",Kr,$r),U("SS",Kr,Hr),U("SSS",Kr,Wr);var jn;for(jn="SSSS";jn.length<=9;jn+="S")U(jn,tn);for(jn="S";jn.length<=9;jn+="S")V(jn,Xe);var Un=S("Milliseconds",!1);N("z",0,0,"zoneAbbr"),N("zz",0,0,"zoneName");var Yn=g.prototype;Yn.add=Tn,Yn.calendar=ie,Yn.clone=ae,Yn.diff=le,Yn.endOf=we,Yn.format=pe,Yn.from=ge,Yn.fromNow=ye,Yn.to=me,Yn.toNow=ve,Yn.get=O,Yn.invalidAt=Se,Yn.isAfter=se,Yn.isBefore=oe,Yn.isBetween=ue,Yn.isSame=ce,Yn.isValid=Fe,Yn.lang=Bn,Yn.locale=be,Yn.localeData=_e,Yn.max=Dn,Yn.min=En,Yn.parsingFlags=Te,Yn.set=O,Yn.startOf=Ae,Yn.subtract=Sn,Yn.toArray=ke,Yn.toObject=Ce,Yn.toDate=De,Yn.toISOString=fe,Yn.toJSON=fe,Yn.toString=de,Yn.unix=Ee,Yn.valueOf=xe,Yn.year=wn,Yn.isLeapYear=lt,Yn.weekYear=Oe,Yn.isoWeekYear=Ie,Yn.quarter=Yn.quarters=Pe,Yn.month=J,Yn.daysInMonth=Q,Yn.week=Yn.weeks=gt,Yn.isoWeek=Yn.isoWeeks=yt,Yn.weeksInYear=Me,Yn.isoWeeksInYear=Ne,Yn.date=Ln,Yn.day=Yn.days=Ge,Yn.weekday=Ve,Yn.isoWeekday=$e,Yn.dayOfYear=vt,Yn.hour=Yn.hours=Pn,Yn.minute=Yn.minutes=Rn,Yn.second=Yn.seconds=qn,Yn.millisecond=Yn.milliseconds=Un,Yn.utcOffset=Ut,Yn.utc=Gt,Yn.local=Vt,Yn.parseZone=$t,Yn.hasAlignedHourOffset=Ht,Yn.isDST=Wt,Yn.isDSTShifted=zt,Yn.isLocal=Zt,Yn.isUtcOffset=Xt,Yn.isUtc=Kt,Yn.isUTC=Kt,Yn.zoneAbbr=Ke,Yn.zoneName=Je,Yn.dates=rt("dates accessor is deprecated. Use date instead.",Ln),Yn.months=rt("months accessor is deprecated. Use month instead",J),Yn.years=rt("years accessor is deprecated. Use year instead",wn),Yn.zone=rt("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Yt);var Gn=Yn,Vn={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},$n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},Hn="Invalid date",Wn="%d",zn=/\d{1,2}/,Zn={future:"in %s",past:"%s ago",s:"a few 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"},Xn=_.prototype;Xn._calendar=Vn,Xn.calendar=er,Xn._longDateFormat=$n,Xn.longDateFormat=rr,Xn._invalidDate=Hn,Xn.invalidDate=nr,Xn._ordinal=Wn,Xn.ordinal=ir,Xn._ordinalParse=zn,Xn.preparse=ar,Xn.postformat=ar,Xn._relativeTime=Zn,Xn.relativeTime=sr,Xn.pastFuture=or,Xn.set=ur,Xn.months=z,Xn._months=gn,Xn.monthsShort=Z,Xn._monthsShort=yn,Xn.monthsParse=X,Xn.week=dt,Xn._week=xn,Xn.firstDayOfYear=pt,Xn.firstDayOfWeek=ft,Xn.weekdays=qe,Xn._weekdays=On,Xn.weekdaysMin=Ue,Xn._weekdaysMin=Nn,Xn.weekdaysShort=je,Xn._weekdaysShort=In,Xn.weekdaysParse=Ye,Xn.isPM=ze,Xn._meridiemParse=Mn,Xn.meridiem=Ze,E("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,r=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+r}}),r.lang=rt("moment.lang is deprecated. Use moment.locale instead.",E),r.langData=rt("moment.langData is deprecated. Use moment.localeData instead.",k);var Kn=Math.abs,Jn=kr("ms"),Qn=kr("s"),ti=kr("m"),ei=kr("h"),ri=kr("d"),ni=kr("w"),ii=kr("M"),ai=kr("y"),si=Fr("milliseconds"),oi=Fr("seconds"),ui=Fr("minutes"),ci=Fr("hours"),li=Fr("days"),hi=Fr("months"),di=Fr("years"),fi=Math.round,pi={s:45,m:45,h:22,d:26,M:11},gi=Math.abs,yi=Nt.prototype;yi.abs=yr,yi.add=vr,yi.subtract=br,yi.as=Er,yi.asMilliseconds=Jn,yi.asSeconds=Qn,yi.asMinutes=ti,yi.asHours=ei,yi.asDays=ri,yi.asWeeks=ni,yi.asMonths=ii,yi.asYears=ai,yi.valueOf=Dr,yi._bubble=Ar,yi.get=Cr,yi.milliseconds=si,yi.seconds=oi,yi.minutes=ui,yi.hours=ci,yi.days=li,yi.weeks=Tr,yi.months=hi,yi.years=di,yi.humanize=Or,yi.toISOString=Ir,yi.toString=Ir,yi.toJSON=Ir,yi.locale=be,yi.localeData=_e,yi.toIsoString=rt("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Ir),yi.lang=Bn,N("X",0,0,"unix"),N("x",0,0,"valueOf"),U("x",en),U("X",nn),V("X",function(t,e,r){r._d=new Date(1e3*parseFloat(t,10))}),V("x",function(t,e,r){r._d=new Date(v(t))}),r.version="2.10.6",n(Bt),r.fn=Gn,r.min=Ot,r.max=It,r.utc=c,r.unix=Qe,r.months=hr,r.isDate=a,r.locale=E,r.invalid=f,r.duration=Jt,r.isMoment=y,r.weekdays=fr,r.parseZone=tr,r.localeData=k,r.isDuration=Mt,r.monthsShort=dr,r.weekdaysMin=gr,r.defineLocale=D,r.weekdaysShort=pr,r.normalizeUnits=F,r.relativeTimeThreshold=Lr;var mi=r;return mi})},{}],106:[function(t,e){e.exports={name:"mermaid",version:"0.5.5",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:{live:"live-server ./test/examples",lint:"node node_modules/eslint/bin/eslint.js src",jison:"gulp jison_legacy",watch:"source ./scripts/watch.sh",doc:"rm -r build;rm -r dist/www;gulp vartree;cp dist/www/all.html ../mermaid-pages/index.html;cp dist/mermaid.js ../mermaid-pages/javascripts/lib;cp dist/mermaid.forest.css ../mermaid-pages/stylesheets",tape:"node node_modules/.bin/tape test/cli_test-*.js",jasmine:"npm run jison &&node node_modules/jasmine-es6/bin/jasmine.js",posttest:"npm run jison",test:"npm run dist && npm run jasmine && npm run tape","dist-slim-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.slim.js -x d3 && cat dist/mermaid.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.slim.min.js","dist-slim-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.slim.js -x d3 && cat dist/mermaidAPI.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.slim.min.js","dist-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.js && cat dist/mermaid.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.min.js","dist-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.js && cat dist/mermaidAPI.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.min.js",dist:"npm run dist-slim-mermaid;npm run dist-slim-mermaidAPI; npm run dist-mermaid;npm run dist-mermaidAPI"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"3.5.6",dagre:"^0.7.4","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","babel-eslint":"^4.1.3",babelify:"^6.4.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4",dateformat:"^1.0.11",dox:"^0.8.0",eslint:"^1.6.0","eslint-watch":"^2.1.2","event-stream":"^3.2.0",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.9.0","gulp-bower":"0.0.10","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-dox":"^0.1.6","gulp-ext-replace":"^0.2.0","gulp-filelog":"^0.4.1","gulp-front-matter":"^1.2.3","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~2.1.0","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-marked":"^1.0.0","gulp-mdvars":"^2.0.0","gulp-qunit":"~1.2.1","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1","gulp-vartree":"^2.0.1","hogan.js":"^3.0.2",jasmine:"2.3.2","jasmine-es6":"0.0.18",jison:"zaach/jison",jsdom:"^7.0.2","jshint-stylish":"^2.0.1","map-stream":"0.0.6",marked:"^0.3.2","mock-browser":"^0.91.34",path:"^0.4.9",phantomjs:"^1.9.18",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3",testdom:"^2.0.0",uglifyjs:"^2.4.10","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],107:[function(t,e){"use strict";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)||"[object Array]"===Object.prototype.toString.call(t)){var e=s(t);return e}return!1},u=function(t,e){var r=t;return 0!==e&&(r.x=parseInt(r.x)+e,r.y=parseInt(r.y)+e,r.width-=2*e,r.height-=2*e),r},c=o(e);if(n&&(c=u(c,n)),0!=a.length&&r&&e&&c){e=c;var l,h=function(t){var n=r.select(t[0].parentNode),a=n.select("text"),s=a.style("line-height"),o=a.text();a.remove();var u=n.append("foreignObject");u.attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);var c=u.append("xhtml:div").attr("class","wrapped");c.style("height",e.height).style("width",e.width).html(o),s&&c.style("line-height",s),i=n.select("foreignObject")},d=function(t){var a,s=t[0],o=s.parentNode,u=r.select(s),c=s.getBBox().height,l=s.getBBox().width,h=c,d=u.style("line-height");if(a=d&&parseInt(d)?parseInt(d.replace("px","")):h,l>e.width){var f=u.text();if(u.text(""),f){var p,g;if(-1!==f.indexOf(" ")){var p=" ";g=f.split(" ")}else{p="";var y=f.length,m=Math.ceil(l/e.width),v=Math.floor(y/m);v*m>=y||m++;for(var b,_,g=[],A=0;m>A;A++)_=A*v,b=f.substr(_,v),g.push(b)}for(var w=[],x=0,E={},A=0;Ae.width&&C&&""!==C&&(x+=F,E={string:C,width:F,offset:x},w.push(E),u.text(""),u.text(k),A==g.length-1&&(D=k,u.text(D),T=s.getComputedTextLength())),A==g.length-1){u.text("");var S=D;S&&""!==S&&(T-x>0&&(T-=x),E={string:S,width:T,offset:x},w.push(E))}}var B;u.text("");for(var A=0;A0){w[A-1]}A*a0?a:void 0}),B.attr("x",function(){var t=e.x;return n&&(t+=n),t}))}}}u.attr("y",function(){var t=e.y;return a&&(t+=a),n&&(t+=n),t}),u.attr("x",function(){var t=e.x;return n&&(t+=n),t}),i=r.select(o).selectAll("text")};t&&("foreignobjects"==t?l=h:"tspans"==t&&(l=d)),t||(l="undefined"!=typeof SVGForeignObjectElement?h:d);for(var f=0;f "+t.w+": "+JSON.stringify(n.edge(t))),v(r,n.edge(t),n.edge(t).relation)}),r.attr("height","100%"),r.attr("width","100%")}},{"../../d3":107,"../../logger":126,"./classDb":108,"./parser/classDiagram":110,dagre:53}],110:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[1,11],n=[1,12],i=[1,13],a=[1,15],s=[1,16],o=[1,17],u=[6,8],c=[1,26],l=[1,27],h=[1,28],d=[1,29],f=[1,30],p=[1,31],g=[6,8,13,17,23,26,27,28,29,30,31],y=[6,8,13,17,23,26,27,28,29,30,31,45,46,47],m=[23,45,46,47],v=[23,30,31,45,46,47],b=[23,26,27,28,29,45,46,47],_=[6,8,13],A=[1,46],w={trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,CLASS_DIAGRAM:5,NEWLINE:6,statements:7,EOF:8,statement:9,className:10,alphaNumToken:11,relationStatement:12,LABEL:13,classStatement:14,methodStatement:15,CLASS:16,STRUCT_START:17,members:18,STRUCT_STOP:19,MEMBER:20,SEPARATOR:21,relation:22,STR:23,relationType:24,lineType:25,AGGREGATION:26,EXTENSION:27,COMPOSITION:28,DEPENDENCY:29,LINE:30,DOTTED_LINE:31,commentToken:32,textToken:33,graphCodeTokens:34,textNoTagsToken:35,TAGSTART:36,TAGEND:37,"==":38,"--":39,PCT:40,DEFAULT:41,SPACE:42,MINUS:43,keywords:44,UNICODE_TEXT:45,NUM:46,ALPHA:47,$accept:0,$end:1},terminals_:{2:"error",5:"CLASS_DIAGRAM",6:"NEWLINE",8:"EOF",13:"LABEL",16:"CLASS",17:"STRUCT_START",19:"STRUCT_STOP",20:"MEMBER",21:"SEPARATOR",23:"STR",26:"AGGREGATION",27:"EXTENSION",28:"COMPOSITION",29:"DEPENDENCY",30:"LINE",31:"DOTTED_LINE",34:"graphCodeTokens",36:"TAGSTART",37:"TAGEND",38:"==",39:"--",40:"PCT",41:"DEFAULT",42:"SPACE",43:"MINUS",44:"keywords",45:"UNICODE_TEXT",46:"NUM",47:"ALPHA"},productions_:[0,[3,1],[4,4],[7,1],[7,3],[10,2],[10,1],[9,1],[9,2],[9,1],[9,1],[14,2],[14,5],[18,1],[18,2],[15,1],[15,2],[15,1],[15,1],[12,3],[12,4],[12,4],[12,5],[22,3],[22,2],[22,2],[22,1],[24,1],[24,1],[24,1],[24,1],[25,1],[25,1],[32,1],[32,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[35,1],[35,1],[35,1],[35,1],[11,1],[11,1],[11,1]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 5:this.$=a[s-1]+a[s];break;case 6:this.$=a[s];break;case 7:n.addRelation(a[s]);break;case 8:a[s-1].title=n.cleanupLabel(a[s]),n.addRelation(a[s-1]);break;case 12:n.addMembers(a[s-3],a[s-1]);break;case 13:this.$=[a[s]];break;case 14:a[s].push(a[s-1]),this.$=a[s];break;case 15:break;case 16:n.addMembers(a[s-1],n.cleanupLabel(a[s]));break;case 17:console.warn("Member",a[s]);break;case 18:break;case 19:this.$={id1:a[s-2],id2:a[s],relation:a[s-1],relationTitle1:"none",relationTitle2:"none"};break;case 20:this.$={id1:a[s-3],id2:a[s],relation:a[s-1],relationTitle1:a[s-2],relationTitle2:"none"};break;case 21:this.$={id1:a[s-3],id2:a[s],relation:a[s-2],relationTitle1:"none",relationTitle2:a[s-1]};break;case 22:this.$={id1:a[s-4],id2:a[s],relation:a[s-2],relationTitle1:a[s-3],relationTitle2:a[s-1]};break;case 23:this.$={type1:a[s-2],type2:a[s],lineType:a[s-1]};break;case 24:this.$={type1:"none",type2:a[s],lineType:a[s-1]};break;case 25:this.$={ -type1:a[s-1],type2:"none",lineType:a[s]};break;case 26:this.$={type1:"none",type2:"none",lineType:a[s]};break;case 27:this.$=n.relationType.AGGREGATION;break;case 28:this.$=n.relationType.EXTENSION;break;case 29:this.$=n.relationType.COMPOSITION;break;case 30:this.$=n.relationType.DEPENDENCY;break;case 31:this.$=n.lineType.LINE;break;case 32:this.$=n.lineType.DOTTED_LINE}},table:[{3:1,4:2,5:[1,3]},{1:[3]},{1:[2,1]},{6:[1,4]},{7:5,9:6,10:10,11:14,12:7,14:8,15:9,16:r,20:n,21:i,45:a,46:s,47:o},{8:[1,18]},{6:[1,19],8:[2,3]},e(u,[2,7],{13:[1,20]}),e(u,[2,9]),e(u,[2,10]),e(u,[2,15],{22:21,24:24,25:25,13:[1,23],23:[1,22],26:c,27:l,28:h,29:d,30:f,31:p}),{10:32,11:14,45:a,46:s,47:o},e(u,[2,17]),e(u,[2,18]),e(g,[2,6],{11:14,10:33,45:a,46:s,47:o}),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),{1:[2,2]},{7:34,9:6,10:10,11:14,12:7,14:8,15:9,16:r,20:n,21:i,45:a,46:s,47:o},e(u,[2,8]),{10:35,11:14,23:[1,36],45:a,46:s,47:o},{22:37,24:24,25:25,26:c,27:l,28:h,29:d,30:f,31:p},e(u,[2,16]),{25:38,30:f,31:p},e(m,[2,26],{24:39,26:c,27:l,28:h,29:d}),e(v,[2,27]),e(v,[2,28]),e(v,[2,29]),e(v,[2,30]),e(b,[2,31]),e(b,[2,32]),e(u,[2,11],{17:[1,40]}),e(g,[2,5]),{8:[2,4]},e(_,[2,19]),{10:41,11:14,45:a,46:s,47:o},{10:42,11:14,23:[1,43],45:a,46:s,47:o},e(m,[2,25],{24:44,26:c,27:l,28:h,29:d}),e(m,[2,24]),{18:45,20:A},e(_,[2,21]),e(_,[2,20]),{10:47,11:14,45:a,46:s,47:o},e(m,[2,23]),{19:[1,48]},{18:49,19:[2,13],20:A},e(_,[2,22]),e(u,[2,12]),{19:[2,14]}],defaultActions:{2:[2,1],18:[2,2],34:[2,4],49:[2,14]},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},x=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;ae[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(e,i[n]),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:{},performAction:function(t,e,r,n){switch(r){case 0:break;case 1:return 6;case 2:break;case 3:return 5;case 4:return this.begin("struct"),17;case 5:return this.popState(),19;case 6:break;case 7:return"MEMBER";case 8:return 16;case 9:this.begin("string");break;case 10:this.popState();break;case 11:return"STR";case 12:return 27;case 13:return 27;case 14:return 29;case 15:return 29;case 16:return 28;case 17:return 26;case 18:return 30;case 19:return 31;case 20:return 13;case 21:return 43;case 22:return"DOT";case 23:return"PLUS";case 24:return 40;case 25:return"EQUALS";case 26:return"EQUALS";case 27:return 47;case 28:return"PUNCTUATION";case 29:return 46;case 30:return 45;case 31:return 42;case 32:return 8}},rules:[/^(?:%%[^\n]*)/,/^(?:\n+)/,/^(?:\s+)/,/^(?:classDiagram\b)/,/^(?:[\{])/,/^(?:\})/,/^(?:[\n])/,/^(?:[^\{\}\n]*)/,/^(?:class\b)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::[^#\n;]+)/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[A-Za-z]+)/,/^(?:[!"#$%&'*+,-.`?\\_\/])/,/^(?:[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:{string:{rules:[10,11],inclusive:!1},struct:{rules:[5,6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,8,9,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32],inclusive:!0}}};return t}();return w.lexer=x,t.prototype=w,w.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],111:[function(t,e,r){(function(e){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e["default"]=t,e}var i=t("../../logger"),a=n(i),s=new a.Log,o="",u=!1;r.setMessage=function(t){s.debug("Setting message to: "+t),o=t},r.getMessage=function(){return o},r.setInfo=function(t){u=t},r.getInfo=function(){return u},r.parseError=function(t,r){e.mermaidAPI.parseError(t,r)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":126}],112:[function(t,e,r){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e["default"]=t,e}var i=t("../../logger"),a=n(i),s=t("./exampleDb"),o=t("./parser/example.js"),u=t("../../d3"),c=new a.Log;r.draw=function(t,e,r){var n;n=o.parser,n.yy=s,c.debug("Renering example diagram"),n.parse(t);var i=u.select("#"+e),a=i.append("g");a.append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("mermaid "+r),i.attr("height",100),i.attr("width",400)}},{"../../d3":107,"../../logger":126,"./exampleDb":111,"./parser/example.js":113}],113:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[6,9,10,12],n={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,message:11,say:12,TXT:13,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo",12:"say",13:"TXT"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1],[8,1],[11,2]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 1:return n;case 4:break;case 6:n.setInfo(!0);break;case 7:n.setMessage(a[s]);break;case 8:this.$=a[s-1].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e(r,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8],11:9,12:[1,10]},{1:[2,1]},e(r,[2,3]),e(r,[2,4]),e(r,[2,5]),e(r,[2,6]),e(r,[2,7]),{13:[1,11]},e(r,[2,8])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},i=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;ae[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(e,i[n]),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,r,n){switch(r){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 n.lexer=i,t.prototype=n,n.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],114:[function(t,e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e["default"]=t,e}var n,i=t("../../logger"),a=r(i),s=new a.Log;if(t)try{n=t("dagre-d3")}catch(o){s.debug("Could not load dagre-d3")}n||(n=window.dagreD3),e.exports=n},{"../../logger":126,"dagre-d3":4}],115:[function(t,e,r){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e["default"]=t,e}var i=t("../../logger"),a=n(i),s=t("./graphDb"),o=t("./parser/flow"),u=t("./parser/dot"),c=t("../../d3"),l=t("./dagre-d3"),h=new a.Log,d={};e.exports.setConf=function(t){var e,r=Object.keys(t);for(e=0;e0&&(s=a.classes.join(" "));var o="";o=n(o,a.styles),i="undefined"==typeof a.text?a.id:a.text;var u="";d.htmlLabels?(u="html",i=i.replace(/fa:fa[\w\-]+/g,function(t){return''})):(i=i.replace(/
/g,"\n"),u="text");var c=0,l="";switch(a.type){case"round":c=5,l="rect";break;case"square":l="rect";break;case"diamond":l="question";break;case"odd":l="rect_left_inv_arrow";break;case"odd_right":l="rect_left_inv_arrow";break;case"circle":l="circle";break;case"ellipse":l="ellipse";break;case"group":l="rect",i="";break;default:l="rect"}e.setNode(a.id,{labelType:u,shape:l,label:i,rx:c,ry:c,"class":s,style:o,id:a.id})})},r.addEdges=function(t,e){var r,n,i=0;"undefined"!=typeof t.defaultStyle&&(n=t.defaultStyle.toString().replace(/,/g,";")),t.forEach(function(t){i++,r="arrow_open"===t.type?"none":"normal";var a="";if("undefined"!=typeof t.style)t.style.forEach(function(t){a=a+t+";"});else switch(t.stroke){case"normal":a="fill:none","undefined"!=typeof n&&(a=n);break;case"dotted":a="stroke: #333; fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":a="stroke: #333; stroke-width: 3.5px;fill:none"}if("undefined"==typeof t.text)"undefined"==typeof t.style?e.setEdge(t.start,t.end,{style:a,arrowhead:r},i):e.setEdge(t.start,t.end,{style:a,arrowheadStyle:"fill: #333",arrowhead:r},i);else{var s=t.text.replace(/
/g,"\n");"undefined"==typeof t.style?d.htmlLabels?e.setEdge(t.start,t.end,{labelType:"html",style:a,labelpos:"c",label:''+t.text+"",arrowheadStyle:"fill: #333",arrowhead:r},i):e.setEdge(t.start,t.end,{labelType:"text",style:"stroke: #333; stroke-width: 1.5px;fill:none",labelpos:"c",label:s,arrowheadStyle:"fill: #333",arrowhead:r},i):e.setEdge(t.start,t.end,{labelType:"text",style:a,arrowheadStyle:"fill: #333",label:s,arrowhead:r},i)}})},r.getClasses=function(t,e){var r;s.clear(),r=e?u.parser:o.parser,r.yy=s,r.parse(t);var n=s.getClasses();return"undefined"==typeof n["default"]&&(n["default"]={id:"default"},n["default"].styles=[],n["default"].clusterStyles=["rx:4px","fill: rgb(255, 255, 222)","rx: 4px","stroke: rgb(170, 170, 51)","stroke-width: 1px"],n["default"].nodeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"],n["default"].edgeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"]),n},r.draw=function(t,e,n){h.debug("Drawing flowchart");var i;s.clear(),i=n?u.parser:o.parser,i.yy=s;try{i.parse(t)}catch(a){h.debug("Parsing failed")}var f;f=s.getDirection(),"undefined"==typeof f&&(f="TD");var p,g=new l.graphlib.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:f,marginx:20,marginy:20}).setDefaultEdgeLabel(function(){return{}}),y=s.getSubGraphs(),m=0;for(m=y.length-1;m>=0;m--)p=y[m],s.addVertex(p.id,p.title,"group",void 0);var v=s.getVertices(),b=s.getEdges();m=0;var _;for(m=y.length-1;m>=0;m--)for(p=y[m],c.selectAll("cluster").append("text"),_=0;_0?"future":"past"];return"function"==typeof r?r(e):r.replace(/%s/i,e)}function ur(t){var e,r;for(r in t)e=t[r],"function"==typeof e?this[r]=e:this["_"+r]=e;this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function cr(t,e,r,n){var i=k(),a=c().set(n,e);return i[r](a,t)}function lr(t,e,r,n,i){if("number"==typeof t&&(e=t,t=void 0),t=t||"",null!=e)return cr(t,e,r,i);var a,s=[];for(a=0;n>a;a++)s[a]=cr(t,a,r,i);return s}function hr(t,e){return lr(t,e,"months",12,"month")}function dr(t,e){return lr(t,e,"monthsShort",12,"month")}function fr(t,e){return lr(t,e,"weekdays",7,"day")}function pr(t,e){return lr(t,e,"weekdaysShort",7,"day")}function gr(t,e){return lr(t,e,"weekdaysMin",7,"day")}function yr(){var t=this._data;return this._milliseconds=Kn(this._milliseconds),this._days=Kn(this._days),this._months=Kn(this._months),t.milliseconds=Kn(t.milliseconds),t.seconds=Kn(t.seconds),t.minutes=Kn(t.minutes),t.hours=Kn(t.hours),t.months=Kn(t.months),t.years=Kn(t.years),this}function mr(t,e,r,n){var i=Jt(e,r);return t._milliseconds+=n*i._milliseconds,t._days+=n*i._days,t._months+=n*i._months,t._bubble()}function vr(t,e){return mr(this,t,e,1)}function br(t,e){return mr(this,t,e,-1)}function _r(t){return 0>t?Math.floor(t):Math.ceil(t)}function Ar(){var t,e,r,n,i,a=this._milliseconds,s=this._days,o=this._months,u=this._data;return a>=0&&s>=0&&o>=0||0>=a&&0>=s&&0>=o||(a+=864e5*_r(xr(o)+s),s=0,o=0),u.milliseconds=a%1e3,t=m(a/1e3),u.seconds=t%60,e=m(t/60),u.minutes=e%60,r=m(e/60),u.hours=r%24,s+=m(r/24),i=m(wr(s)),o+=i,s-=_r(xr(i)),n=m(o/12),o%=12,u.days=s,u.months=o,u.years=n,this}function wr(t){return 4800*t/146097}function xr(t){return 146097*t/4800}function Er(t){var e,r,n=this._milliseconds;if(t=F(t),"month"===t||"year"===t)return e=this._days+n/864e5,r=this._months+wr(e),"month"===t?r:r/12;switch(e=this._days+Math.round(xr(this._months)),t){case"week":return e/7+n/6048e5;case"day":return e+n/864e5;case"hour":return 24*e+n/36e5;case"minute":return 1440*e+n/6e4;case"second":return 86400*e+n/1e3;case"millisecond":return Math.floor(864e5*e)+n;default:throw new Error("Unknown unit "+t)}}function Dr(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function kr(t){return function(){return this.as(t)}}function Cr(t){return t=F(t),this[t+"s"]()}function Fr(t){return function(){return this._data[t]}}function Tr(){return m(this.days()/7)}function Sr(t,e,r,n,i){return i.relativeTime(e||1,!!r,t,n)}function Br(t,e,r){var n=Jt(t).abs(),i=fi(n.as("s")),a=fi(n.as("m")),s=fi(n.as("h")),o=fi(n.as("d")),u=fi(n.as("M")),c=fi(n.as("y")),l=i0,l[4]=r,Sr.apply(null,l)}function Lr(t,e){return void 0===pi[t]?!1:void 0===e?pi[t]:(pi[t]=e,!0)}function Or(t){var e=this.localeData(),r=Br(this,!t,e);return t&&(r=e.pastFuture(+this,r)),e.postformat(r)}function Ir(){var t,e,r,n=gi(this._milliseconds)/1e3,i=gi(this._days),a=gi(this._months);t=m(n/60),e=m(t/60),n%=60,t%=60,r=m(a/12),a%=12;var s=r,o=a,u=i,c=e,l=t,h=n,d=this.asSeconds();return d?(0>d?"-":"")+"P"+(s?s+"Y":"")+(o?o+"M":"")+(u?u+"D":"")+(c||l||h?"T":"")+(c?c+"H":"")+(l?l+"M":"")+(h?h+"S":""):"P0D"}var Nr,Mr,Pr=r.momentProperties=[],Rr=!1,qr={},jr={},Ur=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Yr=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Gr={},Vr={},$r=/\d/,Hr=/\d\d/,Wr=/\d{3}/,zr=/\d{4}/,Zr=/[+-]?\d{6}/,Xr=/\d\d?/,Kr=/\d{1,3}/,Jr=/\d{1,4}/,Qr=/[+-]?\d{1,6}/,tn=/\d+/,en=/[+-]?\d+/,rn=/Z|[+-]\d\d:?\d\d/gi,nn=/[+-]?\d+(\.\d{1,3})?/,an=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,sn={},on={},un=0,cn=1,ln=2,hn=3,dn=4,fn=5,pn=6;N("M",["MM",2],"Mo",function(){return this.month()+1}),N("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),N("MMMM",0,0,function(t){return this.localeData().months(this,t)}),C("month","M"),U("M",Xr),U("MM",Xr,Hr),U("MMM",an),U("MMMM",an),V(["M","MM"],function(t,e){e[cn]=v(t)-1}),V(["MMM","MMMM"],function(t,e,r,n){var i=r._locale.monthsParse(t,n,r._strict);null!=i?e[cn]=i:h(r).invalidMonth=t});var gn="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),yn="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),mn={};r.suppressDeprecationWarnings=!1;var vn=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,bn=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],_n=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],An=/^\/?Date\((\-?\d+)/i;r.createFromInputFallback=rt("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),N(0,["YY",2],0,function(){return this.year()%100}),N(0,["YYYY",4],0,"year"),N(0,["YYYYY",5],0,"year"),N(0,["YYYYYY",6,!0],0,"year"),C("year","y"),U("Y",en),U("YY",Xr,Hr),U("YYYY",Jr,zr),U("YYYYY",Qr,Zr),U("YYYYYY",Qr,Zr),V(["YYYYY","YYYYYY"],un),V("YYYY",function(t,e){e[un]=2===t.length?r.parseTwoDigitYear(t):v(t)}),V("YY",function(t,e){e[un]=r.parseTwoDigitYear(t)}),r.parseTwoDigitYear=function(t){return v(t)+(v(t)>68?1900:2e3)};var wn=S("FullYear",!1);N("w",["ww",2],"wo","week"),N("W",["WW",2],"Wo","isoWeek"),C("week","w"),C("isoWeek","W"),U("w",Xr),U("ww",Xr,Hr),U("W",Xr),U("WW",Xr,Hr),$(["w","ww","W","WW"],function(t,e,r,n){e[n.substr(0,1)]=v(t)});var xn={dow:0,doy:6};N("DDD",["DDDD",3],"DDDo","dayOfYear"),C("dayOfYear","DDD"),U("DDD",Kr),U("DDDD",Wr),V(["DDD","DDDD"],function(t,e,r){r._dayOfYear=v(t)}),r.ISO_8601=function(){};var En=rt("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var t=Bt.apply(null,arguments);return this>t?this:t}),Dn=rt("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var t=Bt.apply(null,arguments);return t>this?this:t});Pt("Z",":"),Pt("ZZ",""),U("Z",rn),U("ZZ",rn),V(["Z","ZZ"],function(t,e,r){r._useUTC=!0,r._tzm=Rt(t)});var kn=/([\+\-]|\d\d)/gi;r.updateOffset=function(){};var Cn=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Fn=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/;Jt.fn=Nt.prototype;var Tn=re(1,"add"),Sn=re(-1,"subtract");r.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var Bn=rt("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return void 0===t?this.localeData():this.locale(t)});N(0,["gg",2],0,function(){return this.weekYear()%100}),N(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Be("gggg","weekYear"),Be("ggggg","weekYear"),Be("GGGG","isoWeekYear"),Be("GGGGG","isoWeekYear"),C("weekYear","gg"),C("isoWeekYear","GG"),U("G",en),U("g",en),U("GG",Xr,Hr),U("gg",Xr,Hr),U("GGGG",Jr,zr),U("gggg",Jr,zr),U("GGGGG",Qr,Zr),U("ggggg",Qr,Zr),$(["gggg","ggggg","GGGG","GGGGG"],function(t,e,r,n){e[n.substr(0,2)]=v(t)}),$(["gg","GG"],function(t,e,n,i){e[i]=r.parseTwoDigitYear(t)}),N("Q",0,0,"quarter"),C("quarter","Q"),U("Q",$r),V("Q",function(t,e){e[cn]=3*(v(t)-1)}),N("D",["DD",2],"Do","date"),C("date","D"),U("D",Xr),U("DD",Xr,Hr),U("Do",function(t,e){return t?e._ordinalParse:e._ordinalParseLenient}),V(["D","DD"],ln),V("Do",function(t,e){e[ln]=v(t.match(Xr)[0],10)});var Ln=S("Date",!0);N("d",0,"do","day"),N("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),N("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),N("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),N("e",0,0,"weekday"),N("E",0,0,"isoWeekday"),C("day","d"),C("weekday","e"),C("isoWeekday","E"),U("d",Xr),U("e",Xr),U("E",Xr),U("dd",an),U("ddd",an),U("dddd",an),$(["dd","ddd","dddd"],function(t,e,r){var n=r._locale.weekdaysParse(t);null!=n?e.d=n:h(r).invalidWeekday=t}),$(["d","e","E"],function(t,e,r,n){e[n]=v(t)});var On="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),In="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Nn="Su_Mo_Tu_We_Th_Fr_Sa".split("_");N("H",["HH",2],0,"hour"),N("h",["hh",2],0,function(){return this.hours()%12||12}),He("a",!0),He("A",!1),C("hour","h"),U("a",We),U("A",We),U("H",Xr),U("h",Xr),U("HH",Xr,Hr),U("hh",Xr,Hr),V(["H","HH"],hn),V(["a","A"],function(t,e,r){r._isPm=r._locale.isPM(t),r._meridiem=t}),V(["h","hh"],function(t,e,r){e[hn]=v(t),h(r).bigHour=!0});var Mn=/[ap]\.?m?\.?/i,Pn=S("Hours",!0);N("m",["mm",2],0,"minute"),C("minute","m"),U("m",Xr),U("mm",Xr,Hr),V(["m","mm"],dn);var Rn=S("Minutes",!1);N("s",["ss",2],0,"second"),C("second","s"),U("s",Xr),U("ss",Xr,Hr),V(["s","ss"],fn);var qn=S("Seconds",!1);N("S",0,0,function(){return~~(this.millisecond()/100)}),N(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),N(0,["SSS",3],0,"millisecond"),N(0,["SSSS",4],0,function(){return 10*this.millisecond()}),N(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),N(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),N(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),N(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),N(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),C("millisecond","ms"),U("S",Kr,$r),U("SS",Kr,Hr),U("SSS",Kr,Wr);var jn;for(jn="SSSS";jn.length<=9;jn+="S")U(jn,tn);for(jn="S";jn.length<=9;jn+="S")V(jn,Xe);var Un=S("Milliseconds",!1);N("z",0,0,"zoneAbbr"),N("zz",0,0,"zoneName");var Yn=g.prototype;Yn.add=Tn,Yn.calendar=ie,Yn.clone=ae,Yn.diff=le,Yn.endOf=we,Yn.format=pe,Yn.from=ge,Yn.fromNow=ye,Yn.to=me,Yn.toNow=ve,Yn.get=O,Yn.invalidAt=Se,Yn.isAfter=se,Yn.isBefore=oe,Yn.isBetween=ue,Yn.isSame=ce,Yn.isValid=Fe,Yn.lang=Bn,Yn.locale=be,Yn.localeData=_e,Yn.max=Dn,Yn.min=En,Yn.parsingFlags=Te,Yn.set=O,Yn.startOf=Ae,Yn.subtract=Sn,Yn.toArray=ke,Yn.toObject=Ce,Yn.toDate=De,Yn.toISOString=fe,Yn.toJSON=fe,Yn.toString=de,Yn.unix=Ee,Yn.valueOf=xe,Yn.year=wn,Yn.isLeapYear=lt,Yn.weekYear=Oe,Yn.isoWeekYear=Ie,Yn.quarter=Yn.quarters=Pe,Yn.month=J,Yn.daysInMonth=Q,Yn.week=Yn.weeks=gt,Yn.isoWeek=Yn.isoWeeks=yt,Yn.weeksInYear=Me,Yn.isoWeeksInYear=Ne,Yn.date=Ln,Yn.day=Yn.days=Ge,Yn.weekday=Ve,Yn.isoWeekday=$e,Yn.dayOfYear=vt,Yn.hour=Yn.hours=Pn,Yn.minute=Yn.minutes=Rn,Yn.second=Yn.seconds=qn,Yn.millisecond=Yn.milliseconds=Un,Yn.utcOffset=Ut,Yn.utc=Gt,Yn.local=Vt,Yn.parseZone=$t,Yn.hasAlignedHourOffset=Ht,Yn.isDST=Wt,Yn.isDSTShifted=zt,Yn.isLocal=Zt,Yn.isUtcOffset=Xt,Yn.isUtc=Kt,Yn.isUTC=Kt,Yn.zoneAbbr=Ke,Yn.zoneName=Je,Yn.dates=rt("dates accessor is deprecated. Use date instead.",Ln),Yn.months=rt("months accessor is deprecated. Use month instead",J),Yn.years=rt("years accessor is deprecated. Use year instead",wn),Yn.zone=rt("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Yt);var Gn=Yn,Vn={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},$n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},Hn="Invalid date",Wn="%d",zn=/\d{1,2}/,Zn={future:"in %s",past:"%s ago",s:"a few 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"},Xn=_.prototype;Xn._calendar=Vn,Xn.calendar=er,Xn._longDateFormat=$n,Xn.longDateFormat=rr,Xn._invalidDate=Hn,Xn.invalidDate=nr,Xn._ordinal=Wn,Xn.ordinal=ir,Xn._ordinalParse=zn,Xn.preparse=ar,Xn.postformat=ar,Xn._relativeTime=Zn,Xn.relativeTime=sr,Xn.pastFuture=or,Xn.set=ur,Xn.months=z,Xn._months=gn,Xn.monthsShort=Z,Xn._monthsShort=yn,Xn.monthsParse=X,Xn.week=dt,Xn._week=xn,Xn.firstDayOfYear=pt,Xn.firstDayOfWeek=ft,Xn.weekdays=qe,Xn._weekdays=On,Xn.weekdaysMin=Ue,Xn._weekdaysMin=Nn,Xn.weekdaysShort=je,Xn._weekdaysShort=In,Xn.weekdaysParse=Ye,Xn.isPM=ze,Xn._meridiemParse=Mn,Xn.meridiem=Ze,E("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,r=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+r}}),r.lang=rt("moment.lang is deprecated. Use moment.locale instead.",E),r.langData=rt("moment.langData is deprecated. Use moment.localeData instead.",k);var Kn=Math.abs,Jn=kr("ms"),Qn=kr("s"),ti=kr("m"),ei=kr("h"),ri=kr("d"),ni=kr("w"),ii=kr("M"),ai=kr("y"),si=Fr("milliseconds"),oi=Fr("seconds"),ui=Fr("minutes"),ci=Fr("hours"),li=Fr("days"),hi=Fr("months"),di=Fr("years"),fi=Math.round,pi={s:45,m:45,h:22,d:26,M:11},gi=Math.abs,yi=Nt.prototype;yi.abs=yr,yi.add=vr,yi.subtract=br,yi.as=Er,yi.asMilliseconds=Jn,yi.asSeconds=Qn,yi.asMinutes=ti,yi.asHours=ei,yi.asDays=ri,yi.asWeeks=ni,yi.asMonths=ii,yi.asYears=ai,yi.valueOf=Dr,yi._bubble=Ar,yi.get=Cr,yi.milliseconds=si,yi.seconds=oi,yi.minutes=ui,yi.hours=ci,yi.days=li,yi.weeks=Tr,yi.months=hi,yi.years=di,yi.humanize=Or,yi.toISOString=Ir,yi.toString=Ir,yi.toJSON=Ir,yi.locale=be,yi.localeData=_e,yi.toIsoString=rt("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Ir),yi.lang=Bn,N("X",0,0,"unix"),N("x",0,0,"valueOf"),U("x",en),U("X",nn),V("X",function(t,e,r){r._d=new Date(1e3*parseFloat(t,10))}),V("x",function(t,e,r){r._d=new Date(v(t))}),r.version="2.10.6",n(Bt),r.fn=Gn,r.min=Ot,r.max=It,r.utc=c,r.unix=Qe,r.months=hr,r.isDate=a,r.locale=E,r.invalid=f,r.duration=Jt,r.isMoment=y,r.weekdays=fr,r.parseZone=tr,r.localeData=k,r.isDuration=Mt,r.monthsShort=dr,r.weekdaysMin=gr,r.defineLocale=D,r.weekdaysShort=pr,r.normalizeUnits=F,r.relativeTimeThreshold=Lr;var mi=r;return mi})},{}],106:[function(t,e){e.exports={name:"mermaid",version:"0.5.5",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:{live:"live-server ./test/examples",lint:"node node_modules/eslint/bin/eslint.js src",jison:"gulp jison_legacy",watch:"source ./scripts/watch.sh",doc:"rm -r build;rm -r dist/www;gulp vartree;cp dist/www/all.html ../mermaid-pages/index.html;cp dist/mermaid.js ../mermaid-pages/javascripts/lib;cp dist/mermaid.forest.css ../mermaid-pages/stylesheets",tape:"node node_modules/.bin/tape test/cli_test-*.js",jasmine:"npm run jison &&node node_modules/jasmine-es6/bin/jasmine.js",posttest:"npm run jison",test:"npm run dist && npm run jasmine && npm run tape","dist-slim-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.slim.js -x d3 && cat dist/mermaid.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.slim.min.js","dist-slim-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.slim.js -x d3 && cat dist/mermaidAPI.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.slim.min.js","dist-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.js && cat dist/mermaid.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.min.js","dist-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.js && cat dist/mermaidAPI.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.min.js",dist:"npm run dist-slim-mermaid;npm run dist-slim-mermaidAPI; npm run dist-mermaid;npm run dist-mermaidAPI"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"3.5.6",dagre:"^0.7.4","dagre-d3":"0.4.10",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","babel-eslint":"^4.1.3",babelify:"^6.4.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4",dateformat:"^1.0.11",dox:"^0.8.0",eslint:"^1.6.0","eslint-watch":"^2.1.2","event-stream":"^3.2.0",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.9.0","gulp-bower":"0.0.10","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-dox":"^0.1.6","gulp-ext-replace":"^0.2.0","gulp-filelog":"^0.4.1","gulp-front-matter":"^1.2.3","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~2.1.0","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-marked":"^1.0.0","gulp-mdvars":"^2.0.0","gulp-qunit":"~1.2.1","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1","gulp-vartree":"^2.0.1","hogan.js":"^3.0.2",jasmine:"2.3.2","jasmine-es6":"0.0.18",jison:"zaach/jison",jsdom:"^7.0.2","jshint-stylish":"^2.0.1","map-stream":"0.0.6",marked:"^0.3.2","mock-browser":"^0.91.34",path:"^0.4.9",phantomjs:"^1.9.18",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3",testdom:"^2.0.0",uglifyjs:"^2.4.10","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],107:[function(t,e){"use strict";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)||"[object Array]"===Object.prototype.toString.call(t)){var e=s(t);return e}return!1},u=function(t,e){var r=t;return 0!==e&&(r.x=parseInt(r.x)+e,r.y=parseInt(r.y)+e,r.width-=2*e,r.height-=2*e),r},c=o(e);if(n&&(c=u(c,n)),0!=a.length&&r&&e&&c){e=c;var l,h=function(t){var n=r.select(t[0].parentNode),a=n.select("text"),s=a.style("line-height"),o=a.text();a.remove();var u=n.append("foreignObject");u.attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);var c=u.append("xhtml:div").attr("class","wrapped");c.style("height",e.height).style("width",e.width).html(o),s&&c.style("line-height",s),i=n.select("foreignObject")},d=function(t){var a,s=t[0],o=s.parentNode,u=r.select(s),c=s.getBBox().height,l=s.getBBox().width,h=c,d=u.style("line-height");if(a=d&&parseInt(d)?parseInt(d.replace("px","")):h,l>e.width){var f=u.text();if(u.text(""),f){var p,g;if(-1!==f.indexOf(" ")){var p=" ";g=f.split(" ")}else{p="";var y=f.length,m=Math.ceil(l/e.width),v=Math.floor(y/m);v*m>=y||m++;for(var b,_,g=[],A=0;m>A;A++)_=A*v,b=f.substr(_,v),g.push(b)}for(var w=[],x=0,E={},A=0;Ae.width&&C&&""!==C&&(x+=F,E={string:C,width:F,offset:x},w.push(E),u.text(""),u.text(k),A==g.length-1&&(D=k,u.text(D),T=s.getComputedTextLength())),A==g.length-1){u.text("");var S=D;S&&""!==S&&(T-x>0&&(T-=x),E={string:S,width:T,offset:x},w.push(E))}}var B;u.text("");for(var A=0;A0){w[A-1]}A*a0?a:void 0}),B.attr("x",function(){var t=e.x;return n&&(t+=n),t}))}}}u.attr("y",function(){var t=e.y;return a&&(t+=a),n&&(t+=n),t}),u.attr("x",function(){var t=e.x;return n&&(t+=n),t}),i=r.select(o).selectAll("text")};t&&("foreignobjects"==t?l=h:"tspans"==t&&(l=d)),t||(l="undefined"!=typeof SVGForeignObjectElement?h:d);for(var f=0;f "+t.w+": "+JSON.stringify(s.edge(t))),p(i,s.edge(t),s.edge(t).relation)}),i.attr("height","100%"),i.attr("width","100%")}},{"../../d3":107,"../../logger":126,"./classDb":108,"./parser/classDiagram":110,dagre:53}],110:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[1,11],n=[1,12],i=[1,13],a=[1,15],s=[1,16],o=[1,17],u=[6,8],c=[1,26],l=[1,27],h=[1,28],d=[1,29],f=[1,30],p=[1,31],g=[6,8,13,17,23,26,27,28,29,30,31],y=[6,8,13,17,23,26,27,28,29,30,31,45,46,47],m=[23,45,46,47],v=[23,30,31,45,46,47],b=[23,26,27,28,29,45,46,47],_=[6,8,13],A=[1,46],w={trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,CLASS_DIAGRAM:5,NEWLINE:6,statements:7,EOF:8,statement:9,className:10,alphaNumToken:11,relationStatement:12,LABEL:13,classStatement:14,methodStatement:15,CLASS:16,STRUCT_START:17,members:18,STRUCT_STOP:19,MEMBER:20,SEPARATOR:21,relation:22,STR:23,relationType:24,lineType:25,AGGREGATION:26,EXTENSION:27,COMPOSITION:28,DEPENDENCY:29,LINE:30,DOTTED_LINE:31,commentToken:32,textToken:33,graphCodeTokens:34,textNoTagsToken:35,TAGSTART:36,TAGEND:37,"==":38,"--":39,PCT:40,DEFAULT:41,SPACE:42,MINUS:43,keywords:44,UNICODE_TEXT:45,NUM:46,ALPHA:47,$accept:0,$end:1},terminals_:{2:"error",5:"CLASS_DIAGRAM",6:"NEWLINE",8:"EOF",13:"LABEL",16:"CLASS",17:"STRUCT_START",19:"STRUCT_STOP",20:"MEMBER",21:"SEPARATOR",23:"STR",26:"AGGREGATION",27:"EXTENSION",28:"COMPOSITION",29:"DEPENDENCY",30:"LINE",31:"DOTTED_LINE",34:"graphCodeTokens",36:"TAGSTART",37:"TAGEND",38:"==",39:"--",40:"PCT",41:"DEFAULT",42:"SPACE",43:"MINUS",44:"keywords",45:"UNICODE_TEXT",46:"NUM",47:"ALPHA"},productions_:[0,[3,1],[4,4],[7,1],[7,3],[10,2],[10,1],[9,1],[9,2],[9,1],[9,1],[14,2],[14,5],[18,1],[18,2],[15,1],[15,2],[15,1],[15,1],[12,3],[12,4],[12,4],[12,5],[22,3],[22,2],[22,2],[22,1],[24,1],[24,1],[24,1],[24,1],[25,1],[25,1],[32,1],[32,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[35,1],[35,1],[35,1],[35,1],[11,1],[11,1],[11,1]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 5:this.$=a[s-1]+a[s];break;case 6:this.$=a[s];break;case 7:n.addRelation(a[s]);break;case 8:a[s-1].title=n.cleanupLabel(a[s]),n.addRelation(a[s-1]);break;case 12:n.addMembers(a[s-3],a[s-1]);break;case 13:this.$=[a[s]];break;case 14:a[s].push(a[s-1]),this.$=a[s];break;case 15:break;case 16:n.addMembers(a[s-1],n.cleanupLabel(a[s]));break;case 17:console.warn("Member",a[s]);break;case 18:break;case 19:this.$={id1:a[s-2],id2:a[s],relation:a[s-1],relationTitle1:"none",relationTitle2:"none"};break;case 20:this.$={id1:a[s-3],id2:a[s],relation:a[s-1],relationTitle1:a[s-2],relationTitle2:"none"};break;case 21:this.$={id1:a[s-3],id2:a[s],relation:a[s-2],relationTitle1:"none",relationTitle2:a[s-1]};break;case 22:this.$={id1:a[s-4],id2:a[s],relation:a[s-2],relationTitle1:a[s-3],relationTitle2:a[s-1]};break;case 23:this.$={type1:a[s-2],type2:a[s],lineType:a[s-1]};break;case 24:this.$={type1:"none",type2:a[s],lineType:a[s-1]};break;case 25:this.$={type1:a[s-1],type2:"none",lineType:a[s]};break;case 26:this.$={type1:"none",type2:"none",lineType:a[s]};break;case 27:this.$=n.relationType.AGGREGATION;break;case 28:this.$=n.relationType.EXTENSION;break;case 29:this.$=n.relationType.COMPOSITION;break;case 30:this.$=n.relationType.DEPENDENCY;break;case 31:this.$=n.lineType.LINE;break;case 32:this.$=n.lineType.DOTTED_LINE}},table:[{3:1,4:2,5:[1,3]},{1:[3]},{1:[2,1]},{6:[1,4]},{7:5,9:6,10:10,11:14,12:7,14:8,15:9,16:r,20:n,21:i,45:a,46:s,47:o},{8:[1,18]},{6:[1,19],8:[2,3]},e(u,[2,7],{13:[1,20]}),e(u,[2,9]),e(u,[2,10]),e(u,[2,15],{22:21,24:24,25:25,13:[1,23],23:[1,22],26:c,27:l,28:h,29:d,30:f,31:p}),{10:32,11:14,45:a,46:s,47:o},e(u,[2,17]),e(u,[2,18]),e(g,[2,6],{11:14,10:33,45:a,46:s,47:o}),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),{1:[2,2]},{7:34,9:6,10:10,11:14,12:7,14:8,15:9,16:r,20:n,21:i,45:a,46:s,47:o},e(u,[2,8]),{10:35,11:14,23:[1,36],45:a,46:s,47:o},{22:37,24:24,25:25,26:c,27:l,28:h,29:d,30:f, +31:p},e(u,[2,16]),{25:38,30:f,31:p},e(m,[2,26],{24:39,26:c,27:l,28:h,29:d}),e(v,[2,27]),e(v,[2,28]),e(v,[2,29]),e(v,[2,30]),e(b,[2,31]),e(b,[2,32]),e(u,[2,11],{17:[1,40]}),e(g,[2,5]),{8:[2,4]},e(_,[2,19]),{10:41,11:14,45:a,46:s,47:o},{10:42,11:14,23:[1,43],45:a,46:s,47:o},e(m,[2,25],{24:44,26:c,27:l,28:h,29:d}),e(m,[2,24]),{18:45,20:A},e(_,[2,21]),e(_,[2,20]),{10:47,11:14,45:a,46:s,47:o},e(m,[2,23]),{19:[1,48]},{18:49,19:[2,13],20:A},e(_,[2,22]),e(u,[2,12]),{19:[2,14]}],defaultActions:{2:[2,1],18:[2,2],34:[2,4],49:[2,14]},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},x=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;ae[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(e,i[n]),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:{},performAction:function(t,e,r,n){switch(r){case 0:break;case 1:return 6;case 2:break;case 3:return 5;case 4:return this.begin("struct"),17;case 5:return this.popState(),19;case 6:break;case 7:return"MEMBER";case 8:return 16;case 9:this.begin("string");break;case 10:this.popState();break;case 11:return"STR";case 12:return 27;case 13:return 27;case 14:return 29;case 15:return 29;case 16:return 28;case 17:return 26;case 18:return 30;case 19:return 31;case 20:return 13;case 21:return 43;case 22:return"DOT";case 23:return"PLUS";case 24:return 40;case 25:return"EQUALS";case 26:return"EQUALS";case 27:return 47;case 28:return"PUNCTUATION";case 29:return 46;case 30:return 45;case 31:return 42;case 32:return 8}},rules:[/^(?:%%[^\n]*)/,/^(?:\n+)/,/^(?:\s+)/,/^(?:classDiagram\b)/,/^(?:[\{])/,/^(?:\})/,/^(?:[\n])/,/^(?:[^\{\}\n]*)/,/^(?:class\b)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::[^#\n;]+)/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[A-Za-z]+)/,/^(?:[!"#$%&'*+,-.`?\\_\/])/,/^(?:[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:{string:{rules:[10,11],inclusive:!1},struct:{rules:[5,6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,8,9,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32],inclusive:!0}}};return t}();return w.lexer=x,t.prototype=w,w.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],111:[function(t,e,r){(function(e){"use strict";var n=t("../../logger"),i=new n.Log,a="",s=!1;r.setMessage=function(t){i.debug("Setting message to: "+t),a=t},r.getMessage=function(){return a},r.setInfo=function(t){s=t},r.getInfo=function(){return s},r.parseError=function(t,r){e.mermaidAPI.parseError(t,r)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":126}],112:[function(t,e,r){"use strict";var n=t("./exampleDb"),i=t("./parser/example.js"),a=t("../../d3"),s=t("../../logger"),o=new s.Log;r.draw=function(t,e,r){var s;s=i.parser,s.yy=n,o.debug("Renering example diagram"),s.parse(t);var u=a.select("#"+e),c=u.append("g");c.append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("mermaid "+r),u.attr("height",100),u.attr("width",400)}},{"../../d3":107,"../../logger":126,"./exampleDb":111,"./parser/example.js":113}],113:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[6,9,10,12],n={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,message:11,say:12,TXT:13,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo",12:"say",13:"TXT"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1],[8,1],[11,2]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 1:return n;case 4:break;case 6:n.setInfo(!0);break;case 7:n.setMessage(a[s]);break;case 8:this.$=a[s-1].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e(r,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8],11:9,12:[1,10]},{1:[2,1]},e(r,[2,3]),e(r,[2,4]),e(r,[2,5]),e(r,[2,6]),e(r,[2,7]),{13:[1,11]},e(r,[2,8])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},i=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;ae[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(e,i[n]),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,r,n){switch(r){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 n.lexer=i,t.prototype=n,n.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],114:[function(t,e){"use strict";var r,n=t("../../logger"),i=new n.Log;if(t)try{r=t("dagre-d3")}catch(a){i.debug("Could not load dagre-d3")}r||(r=window.dagreD3),e.exports=r},{"../../logger":126,"dagre-d3":4}],115:[function(t,e,r){"use strict";var n=t("./graphDb"),i=t("./parser/flow"),a=t("./parser/dot"),s=t("../../d3"),o=t("./dagre-d3"),u=t("../../logger"),c=new u.Log,l={};e.exports.setConf=function(t){var e,r=Object.keys(t);for(e=0;e0&&(s=a.classes.join(" "));var o="";o=n(o,a.styles),i="undefined"==typeof a.text?a.id:a.text;var u="";l.htmlLabels?(u="html",i=i.replace(/fa:fa[\w\-]+/g,function(t){return''})):(i=i.replace(/
/g,"\n"),u="text");var c=0,h="";switch(a.type){case"round":c=5,h="rect";break;case"square":h="rect";break;case"diamond":h="question";break;case"odd":h="rect_left_inv_arrow";break;case"odd_right":h="rect_left_inv_arrow";break;case"circle":h="circle";break;case"ellipse":h="ellipse";break;case"group":h="rect",i="";break;default:h="rect"}e.setNode(a.id,{labelType:u,shape:h,label:i,rx:c,ry:c,"class":s,style:o,id:a.id})})},r.addEdges=function(t,e){var r,n,i=0;"undefined"!=typeof t.defaultStyle&&(n=t.defaultStyle.toString().replace(/,/g,";")),t.forEach(function(t){i++,r="arrow_open"===t.type?"none":"normal";var a="";if("undefined"!=typeof t.style)t.style.forEach(function(t){a=a+t+";"});else switch(t.stroke){case"normal":a="fill:none","undefined"!=typeof n&&(a=n);break;case"dotted":a="stroke: #333; fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":a="stroke: #333; stroke-width: 3.5px;fill:none"}if("undefined"==typeof t.text)"undefined"==typeof t.style?e.setEdge(t.start,t.end,{style:a,arrowhead:r},i):e.setEdge(t.start,t.end,{style:a,arrowheadStyle:"fill: #333",arrowhead:r},i);else{var s=t.text.replace(/
/g,"\n");"undefined"==typeof t.style?l.htmlLabels?e.setEdge(t.start,t.end,{labelType:"html",style:a,labelpos:"c",label:''+t.text+"",arrowheadStyle:"fill: #333",arrowhead:r},i):e.setEdge(t.start,t.end,{labelType:"text",style:"stroke: #333; stroke-width: 1.5px;fill:none",labelpos:"c",label:s,arrowheadStyle:"fill: #333",arrowhead:r},i):e.setEdge(t.start,t.end,{labelType:"text",style:a,arrowheadStyle:"fill: #333",label:s,arrowhead:r},i)}})},r.getClasses=function(t,e){var r;n.clear(),r=e?a.parser:i.parser,r.yy=n,r.parse(t);var s=n.getClasses();return"undefined"==typeof s["default"]&&(s["default"]={id:"default"},s["default"].styles=[],s["default"].clusterStyles=["rx:4px","fill: rgb(255, 255, 222)","rx: 4px","stroke: rgb(170, 170, 51)","stroke-width: 1px"],s["default"].nodeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"],s["default"].edgeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"]),s},r.draw=function(t,e,u){c.debug("Drawing flowchart");var h;n.clear(),h=u?a.parser:i.parser,h.yy=n;try{h.parse(t)}catch(d){c.debug("Parsing failed")}var f;f=n.getDirection(),"undefined"==typeof f&&(f="TD");var p,g=new o.graphlib.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:f,marginx:20,marginy:20}).setDefaultEdgeLabel(function(){return{}}),y=n.getSubGraphs(),m=0;for(m=y.length-1;m>=0;m--)p=y[m],n.addVertex(p.id,p.title,"group",void 0);var v=n.getVertices(),b=n.getEdges();m=0;var _;for(m=y.length-1;m>=0;m--)for(p=y[m],s.selectAll("cluster").append("text"),_=0;_0?t.split(",").forEach(function(t){"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)}):"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)};var setTooltip=function(t,e){"undefined"!=typeof e&&(tooltips[t]=e)},setClickFun=function setClickFun(id,functionName){"undefined"!=typeof functionName&&"undefined"!=typeof vertices[id]&&funs.push(function(element){var elem=d3.select(element).select("#"+id);null!==elem&&elem.on("click",function(){eval(functionName+"('"+id+"')")})})},setLink=function(t,e){"undefined"!=typeof e&&"undefined"!=typeof vertices[t]&&funs.push(function(r){var n=d3.select(r).select("#"+t);null!==n&&n.on("click",function(){window.open(e,"newTab"); -exports.addVertex=function(t,e,r,n){var i;"undefined"!=typeof t&&0!==t.trim().length&&("undefined"==typeof vertices[t]&&(vertices[t]={id:t,styles:[],classes:[]}),"undefined"!=typeof e&&(i=e.trim(),'"'===i[0]&&'"'===i[i.length-1]&&(i=i.substring(1,i.length-1)),vertices[t].text=i),"undefined"!=typeof r&&(vertices[t].type=r),"undefined"!=typeof r&&(vertices[t].type=r),"undefined"!=typeof n&&null!==n&&n.forEach(function(e){vertices[t].styles.push(e)}))},exports.addLink=function(t,e,r,n){log.debug("Got edge",t,e);var i={start:t,end:e,type:void 0,text:""};n=r.text,"undefined"!=typeof n&&(i.text=n.trim(),'"'===i.text[0]&&'"'===i.text[i.text.length-1]&&(i.text=i.text.substring(1,i.text.length-1))),"undefined"!=typeof r&&(i.type=r.type,i.stroke=r.stroke),edges.push(i)},exports.updateLink=function(t,e){"default"===t?edges.defaultStyle=e:edges[t].style=e},exports.addClass=function(t,e){"undefined"==typeof classes[t]&&(classes[t]={id:t,styles:[]}),"undefined"!=typeof e&&null!==e&&e.forEach(function(e){classes[t].styles.push(e)})},exports.setDirection=function(t){direction=t},exports.setClass=function(t,e){t.indexOf(",")>0?t.split(",").forEach(function(t){"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)}):"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)};var setTooltip=function(t,e){"undefined"!=typeof e&&(tooltips[t]=e)},setClickFun=function setClickFun(id,functionName){"undefined"!=typeof functionName&&"undefined"!=typeof vertices[id]&&funs.push(function(element){var elem=d3.select(element).select("#"+id);null!==elem&&elem.on("click",function(){eval(functionName+"('"+id+"')")})})},setLink=function(t,e){"undefined"!=typeof e&&"undefined"!=typeof vertices[t]&&funs.push(function(r){var n=d3.select(r).select("#"+t);null!==n&&n.on("click",function(){window.open(e,"newTab")})})};exports.getTooltip=function(t){return tooltips[t]},exports.setClickEvent=function(t,e,r,n){t.indexOf(",")>0?t.split(",").forEach(function(t){setTooltip(t,n),setClickFun(t,e),setLink(t,r)}):(setTooltip(t,n),setClickFun(t,e),setLink(t,r))},exports.bindFunctions=function(t){funs.forEach(function(e){e(t)})},exports.getDirection=function(){return direction},exports.getVertices=function(){return vertices},exports.getEdges=function(){return edges},exports.getClasses=function(){return classes};var setupToolTips=function(t){var e=d3.select(".mermaidTooltip");null===e[0][0]&&(e=d3.select("body").append("div").attr("class","mermaidTooltip").style("opacity",0));var r=d3.select(t).select("svg"),n=r.selectAll("g.node");n.on("mouseover",function(){var t=d3.select(this),r=t.attr("title");if(null!==r){var n=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",n.left+(n.right-n.left)/2+"px").style("top",n.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}}).on("mouseout",function(){e.transition().duration(500).style("opacity",0);var t=d3.select(this);t.classed("hover",!1)})};funs.push(setupToolTips),exports.clear=function(){vertices={},classes={},edges=[],funs=[],funs.push(setupToolTips),subGraphs=[],subCount=0,tooltips=[]},exports.defaultStyle=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},exports.addSubGraph=function(t,e){function r(t){var e={"boolean":{},number:{},string:{}},r=[];return t.filter(function(t){var n=typeof t;return" "===t?!1:n in e?e[n].hasOwnProperty(t)?!1:e[n][t]=!0:r.indexOf(t)>=0?!1:r.push(t)})}var n=[];n=r(n.concat.apply(n,t));var i={id:"subGraph"+subCount,nodes:n,title:e};return subGraphs.push(i),subCount+=1,i.id};var getPosForId=function(t){var e;for(e=0;e2e3)){if(posCrossRef[secCount]=r,subGraphs[r].id===e)return{result:!0,count:0};for(var i=0,a=1;i=0){var o=t(e,s);if(o.result)return{result:!0,count:a+o.count};a+=o.count}i+=1}return{result:!1,count:a}}};exports.getDepthFirstPos=function(t){return posCrossRef[t]},exports.indexNodes=function(){secCount=-1,subGraphs.length>0&&indexNodes("none",subGraphs.length-1,0)},exports.getSubGraphs=function(){return subGraphs},exports.parseError=function(t,e){global.mermaidAPI.parseError(t,e)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../d3":107,"../../logger":126}],117:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[1,5],n=[1,6],i=[1,12],a=[1,13],s=[1,14],o=[1,15],u=[1,16],c=[1,17],l=[1,18],h=[1,19],d=[1,20],f=[1,21],p=[1,22],g=[8,16,17,18,19,20,21,22,23,24,25,26],y=[1,37],m=[1,33],v=[1,34],b=[1,35],_=[1,36],A=[8,10,16,17,18,19,20,21,22,23,24,25,26,28,32,37,39,40,45,57,58],w=[10,28],x=[10,28,37,57,58],E=[2,49],D=[1,45],k=[1,48],C=[1,49],F=[1,52],T=[2,65],S=[1,65],B=[1,66],L=[1,67],O=[1,68],I=[1,69],N=[1,70],M=[1,71],P=[1,72],R=[1,73],q=[8,16,17,18,19,20,21,22,23,24,25,26,47],j=[10,28,37],U={trace:function(){},yy:{},symbols_:{error:2,expressions:3,graph:4,EOF:5,graphStatement:6,idStatement:7,"{":8,stmt_list:9,"}":10,strict:11,GRAPH:12,DIGRAPH:13,textNoTags:14,textNoTagsToken:15,ALPHA:16,NUM:17,COLON:18,PLUS:19,EQUALS:20,MULT:21,DOT:22,BRKT:23,SPACE:24,MINUS:25,keywords:26,stmt:27,";":28,node_stmt:29,edge_stmt:30,attr_stmt:31,"=":32,subgraph:33,attr_list:34,NODE:35,EDGE:36,"[":37,a_list:38,"]":39,",":40,edgeRHS:41,node_id:42,edgeop:43,port:44,":":45,compass_pt:46,SUBGRAPH:47,n:48,ne:49,e:50,se:51,s:52,sw:53,w:54,nw:55,c:56,ARROW_POINT:57,ARROW_OPEN:58,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",8:"{",10:"}",11:"strict",12:"GRAPH",13:"DIGRAPH",16:"ALPHA",17:"NUM",18:"COLON",19:"PLUS",20:"EQUALS",21:"MULT",22:"DOT",23:"BRKT",24:"SPACE",25:"MINUS",26:"keywords",28:";",32:"=",35:"NODE",36:"EDGE",37:"[",39:"]",40:",",45:":",47:"SUBGRAPH",48:"n",49:"ne",50:"e",51:"se",52:"s",53:"sw",54:"w",55:"nw",56:"c",57:"ARROW_POINT",58:"ARROW_OPEN"},productions_:[0,[3,2],[4,5],[4,6],[4,4],[6,1],[6,1],[7,1],[14,1],[14,2],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[9,1],[9,3],[27,1],[27,1],[27,1],[27,3],[27,1],[31,2],[31,2],[31,2],[34,4],[34,3],[34,3],[34,2],[38,5],[38,5],[38,3],[30,3],[30,3],[30,2],[30,2],[41,3],[41,3],[41,2],[41,2],[29,2],[29,1],[42,2],[42,1],[44,4],[44,2],[44,2],[33,5],[33,4],[33,3],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,0],[43,1],[43,1]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 1:this.$=a[s-1];break;case 2:this.$=a[s-4];break;case 3:this.$=a[s-5];break;case 4:this.$=a[s-3];break;case 8:case 10:case 11:this.$=a[s];break;case 9:this.$=a[s-1]+""+a[s];break;case 12:case 13:case 14:case 15:case 16:case 18:case 19:case 20:this.$=a[s];break;case 17:this.$="
";break;case 39:this.$="oy";break;case 40:n.addLink(a[s-1],a[s].id,a[s].op),this.$="oy";break;case 42:n.addLink(a[s-1],a[s].id,a[s].op),this.$={op:a[s-2],id:a[s-1]};break;case 44:this.$={op:a[s-1],id:a[s]};break;case 48:n.addVertex(a[s-1]),this.$=a[s-1];break;case 49:n.addVertex(a[s]),this.$=a[s];break;case 66:this.$="arrow";break;case 67:this.$="arrow_open"}},table:[{3:1,4:2,6:3,11:[1,4],12:r,13:n},{1:[3]},{5:[1,7]},{7:8,8:[1,9],14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{6:23,12:r,13:n},e(g,[2,5]),e(g,[2,6]),{1:[2,1]},{8:[1,24]},{7:30,8:y,9:25,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},e([8,10,28,32,37,39,40,45,57,58],[2,7],{15:38,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p}),e(A,[2,8]),e(A,[2,10]),e(A,[2,11]),e(A,[2,12]),e(A,[2,13]),e(A,[2,14]),e(A,[2,15]),e(A,[2,16]),e(A,[2,17]),e(A,[2,18]),e(A,[2,19]),e(A,[2,20]),{7:39,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{7:30,8:y,9:40,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,41]},{10:[2,21],28:[1,42]},e(w,[2,23]),e(w,[2,24]),e(w,[2,25]),e(x,E,{44:44,32:[1,43],45:D}),e(w,[2,27],{41:46,43:47,57:k,58:C}),e(w,[2,47],{43:47,34:50,41:51,37:F,57:k,58:C}),{34:53,37:F},{34:54,37:F},{34:55,37:F},{7:56,8:[1,57],14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{7:30,8:y,9:58,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},e(A,[2,9]),{8:[1,59]},{10:[1,60]},{5:[2,4]},{7:30,8:y,9:61,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{7:62,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},e(x,[2,48]),e(x,T,{14:10,15:11,7:63,46:64,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,48:S,49:B,50:L,51:O,52:I,53:N,54:M,55:P,56:R}),e(w,[2,41],{34:74,37:F}),{7:77,8:y,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,33:76,42:75,47:_},e(q,[2,66]),e(q,[2,67]),e(w,[2,46]),e(w,[2,40],{34:78,37:F}),{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:79,39:[1,80]},e(w,[2,28]),e(w,[2,29]),e(w,[2,30]),{8:[1,82]},{7:30,8:y,9:83,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,84]},{7:30,8:y,9:85,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{5:[2,2]},{10:[2,22]},e(w,[2,26]),e(x,[2,51],{45:[1,86]}),e(x,[2,52]),e(x,[2,56]),e(x,[2,57]),e(x,[2,58]),e(x,[2,59]),e(x,[2,60]),e(x,[2,61]),e(x,[2,62]),e(x,[2,63]),e(x,[2,64]),e(w,[2,38]),e(j,[2,44],{43:47,41:87,57:k,58:C}),e(j,[2,45],{43:47,41:88,57:k,58:C}),e(x,E,{44:44,45:D}),e(w,[2,39]),{39:[1,89]},e(w,[2,34],{34:90,37:F}),{32:[1,91]},{7:30,8:y,9:92,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,93]},e(x,[2,55]),{10:[1,94]},e(x,T,{46:95,48:S,49:B,50:L,51:O,52:I,53:N,54:M,55:P,56:R}),e(j,[2,42]),e(j,[2,43]),e(w,[2,33],{34:96,37:F}),e(w,[2,32]),{7:97,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{10:[1,98]},e(x,[2,54]),{5:[2,3]},e(x,[2,50]),e(w,[2,31]),{28:[1,99],39:[2,37],40:[1,100]},e(x,[2,53]),{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:101},{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:102},{39:[2,35]},{39:[2,36]}],defaultActions:{7:[2,1],41:[2,4],60:[2,2],61:[2,22],94:[2,3],101:[2,35],102:[2,36]},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},Y=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;ae[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(e,i[n]),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:{},performAction:function(t,e,r,n){switch(r){case 0:return"STYLE";case 1:return"LINKSTYLE";case 2:return"CLASSDEF";case 3:return"CLASS";case 4:return"CLICK";case 5:return 12;case 6:return 13;case 7:return 47;case 8:return 35;case 9:return 36;case 10:return"DIR";case 11:return"DIR";case 12:return"DIR";case 13:return"DIR";case 14:return"DIR";case 15:return"DIR";case 16:return 17;case 17:return 23;case 18:return 18;case 19:return 28;case 20:return 40;case 21:return 32;case 22:return 21;case 23:return 22;case 24:return"ARROW_CROSS";case 25:return 57;case 26:return"ARROW_CIRCLE";case 27:return 58;case 28:return 25;case 29:return 19;case 30:return 20;case 31:return 16;case 32:return"PIPE";case 33:return"PS";case 34:return"PE";case 35:return 37;case 36:return 39;case 37:return 8;case 38:return 10;case 39:return"QUOTE";case 40:return 24;case 41:return"NEWLINE";case 42:return 5}},rules:[/^(?:style\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:digraph\b)/,/^(?:subgraph\b)/,/^(?:node\b)/,/^(?:edge\b)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9])/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:=)/,/^(?:\*)/,/^(?:\.)/,/^(?:--[x])/,/^(?:->)/,/^(?:--[o])/,/^(?:--)/,/^(?:-)/,/^(?:\+)/,/^(?:=)/,/^(?:[\u0021-\u0027\u002A-\u002E\u003F\u0041-\u005A\u0061-\u007A\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)/,/^(?:\n)/,/^(?:$)/],conditions:{INITIAL:{rules:[0,1,2,3,4,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],inclusive:!0}}};return t}();return U.lexer=Y,t.prototype=U,U.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],118:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[1,4],n=[1,3],i=[1,5],a=[1,8,9,10,11,13,18,30,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],s=[2,2],o=[1,12],u=[1,13],c=[1,14],l=[1,15],h=[1,31],d=[1,33],f=[1,22],p=[1,34],g=[1,24],y=[1,25],m=[1,26],v=[1,27],b=[1,28],_=[1,38],A=[1,40],w=[1,35],x=[1,39],E=[1,45],D=[1,44],k=[1,36],C=[1,37],F=[1,41],T=[1,42],S=[1,43],B=[1,8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],L=[1,53],O=[1,52],I=[1,54],N=[1,72],M=[1,80],P=[1,81],R=[1,66],q=[1,65],j=[1,85],U=[1,84],Y=[1,82],G=[1,83],V=[1,73],$=[1,68],H=[1,67],W=[1,63],z=[1,75],Z=[1,76],X=[1,77],K=[1,78],J=[1,79],Q=[1,70],tt=[1,69],et=[8,9,11],rt=[8,9,11,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64],nt=[1,115],it=[8,9,10,11,13,15,18,36,38,40,42,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,85,87,88,90,91,93,94,95,96,97],at=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,42,43,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],st=[1,117],ot=[1,118],ut=[8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],ct=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,43,46,50,51,52,53,54,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],lt=[13,18,46,81,85,87,88,90,91,93,94,95,96,97],ht=[13,18,46,49,65,81,85,87,88,90,91,93,94,95,96,97],dt=[1,191],ft=[1,188],pt=[1,195],gt=[1,192],yt=[1,189],mt=[1,196],vt=[1,186],bt=[1,187],_t=[1,190],At=[1,193],wt=[1,194],xt=[1,211],Et=[8,9,11,85],Dt=[8,9,10,11,46,71,80,81,83,85,87,88,89,90,91],kt={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,"(-":40,"-)":41,DIAMOND_START:42,DIAMOND_STOP:43,alphaNumStatement:44,alphaNumToken:45,MINUS:46,linkStatement:47,arrowText:48,TESTSTR:49,"--":50,ARROW_POINT:51,ARROW_CIRCLE:52,ARROW_CROSS:53,ARROW_OPEN:54,"-.":55,DOTTED_ARROW_POINT:56,DOTTED_ARROW_CIRCLE:57,DOTTED_ARROW_CROSS:58,DOTTED_ARROW_OPEN:59,"==":60,THICK_ARROW_POINT:61,THICK_ARROW_CIRCLE:62,THICK_ARROW_CROSS:63,THICK_ARROW_OPEN:64,PIPE:65,textToken:66,STR:67,commentText:68,commentToken:69,keywords:70,STYLE:71,LINKSTYLE:72,CLASSDEF:73,CLASS:74,CLICK:75,textNoTags:76,textNoTagsToken:77,DEFAULT:78,stylesOpt:79,HEX:80,NUM:81,commentStatement:82,PCT:83,style:84,COMMA:85,styleComponent:86,ALPHA:87,COLON:88,UNIT:89,BRKT:90,DOT:91,graphCodeTokens:92,PUNCTUATION:93,UNICODE_TEXT:94,PLUS:95,EQUALS:96,MULT:97,TAG_START:98,TAG_END:99,QUOTE:100,$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:"(-",41:"-)",42:"DIAMOND_START",43:"DIAMOND_STOP",46:"MINUS",49:"TESTSTR",50:"--",51:"ARROW_POINT",52:"ARROW_CIRCLE",53:"ARROW_CROSS",54:"ARROW_OPEN",55:"-.",56:"DOTTED_ARROW_POINT",57:"DOTTED_ARROW_CIRCLE",58:"DOTTED_ARROW_CROSS",59:"DOTTED_ARROW_OPEN",60:"==",61:"THICK_ARROW_POINT",62:"THICK_ARROW_CIRCLE",63:"THICK_ARROW_CROSS",64:"THICK_ARROW_OPEN",65:"PIPE",67:"STR",71:"STYLE",72:"LINKSTYLE",73:"CLASSDEF",74:"CLASS",75:"CLICK",78:"DEFAULT",80:"HEX",81:"NUM",83:"PCT",85:"COMMA",87:"ALPHA",88:"COLON",89:"UNIT",90:"BRKT",91:"DOT",93:"PUNCTUATION",94:"UNICODE_TEXT",95:"PLUS",96:"EQUALS",97:"MULT",98:"TAG_START",99:"TAG_END",100:"QUOTE"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,4],[4,4],[4,4],[4,4],[4,4],[19,2],[19,1],[20,1],[20,1],[20,1],[14,1],[14,1],[14,2],[22,2],[22,2],[22,1],[22,1],[21,2],[21,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,5],[7,4],[24,1],[24,1],[24,1],[23,3],[23,1],[33,4],[33,5],[33,6],[33,7],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,1],[33,2],[35,1],[35,2],[44,1],[44,1],[44,1],[44,1],[34,2],[34,3],[34,3],[34,1],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[48,3],[31,1],[31,2],[31,1],[68,1],[68,2],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[76,1],[76,2],[27,5],[27,5],[28,5],[29,5],[29,7],[29,5],[29,7],[25,5],[25,5],[26,5],[26,5],[82,3],[79,1],[79,3],[84,1],[84,2],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[69,1],[69,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[77,1],[77,1],[77,1],[77,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 2:this.$=[];break;case 3:a[s]!==[]&&a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 57:case 59:case 60:case 92:case 94:case 95:case 108:this.$=a[s];break;case 11:n.setDirection(a[s-1]),this.$=a[s-1];break;case 12:n.setDirection("LR"),this.$=a[s-1];break;case 13:n.setDirection("RL"),this.$=a[s-1];break;case 14:n.setDirection("BT"),this.$=a[s-1];break;case 15:n.setDirection("TB"),this.$=a[s-1];break;case 30:this.$=a[s-1];break;case 31:case 32:case 33:case 34:case 35:this.$=[];break;case 36:this.$=n.addSubGraph(a[s-1],a[s-3]);break;case 37:this.$=n.addSubGraph(a[s-1],void 0);break;case 41:n.addLink(a[s-2],a[s],a[s-1]),this.$=[a[s-2],a[s]];break;case 42:this.$=[a[s]];break;case 43:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"square");break;case 44:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"square");break;case 45:this.$=a[s-5],n.addVertex(a[s-5],a[s-2],"circle");break;case 46:this.$=a[s-6],n.addVertex(a[s-6],a[s-3],"circle");break;case 47:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"ellipse");break;case 48:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"ellipse");break;case 49:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"round");break;case 50:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"round");break;case 51:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"diamond");break;case 52:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"diamond");break;case 53:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"odd");break;case 54:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"odd");break;case 55:this.$=a[s],n.addVertex(a[s]);break;case 56:this.$=a[s-1],n.addVertex(a[s-1]);break;case 58:case 93:case 96:case 109:this.$=a[s-1]+""+a[s];break;case 61:this.$="v";break;case 62:this.$="-";break;case 63:a[s-1].text=a[s],this.$=a[s-1];break;case 64:case 65:a[s-2].text=a[s-1],this.$=a[s-2];break;case 66:this.$=a[s];break;case 67:this.$={type:"arrow",stroke:"normal",text:a[s-1]};break;case 68:this.$={type:"arrow_circle",stroke:"normal",text:a[s-1]};break;case 69:this.$={type:"arrow_cross",stroke:"normal",text:a[s-1]};break;case 70:this.$={type:"arrow_open",stroke:"normal",text:a[s-1]};break;case 71:this.$={type:"arrow",stroke:"dotted",text:a[s-1]};break;case 72:this.$={type:"arrow_circle",stroke:"dotted",text:a[s-1]};break;case 73:this.$={type:"arrow_cross",stroke:"dotted",text:a[s-1]};break;case 74:this.$={type:"arrow_open",stroke:"dotted",text:a[s-1]};break;case 75:this.$={type:"arrow",stroke:"thick",text:a[s-1]};break;case 76:this.$={type:"arrow_circle",stroke:"thick",text:a[s-1]};break;case 77:this.$={type:"arrow_cross",stroke:"thick",text:a[s-1]};break;case 78:this.$={type:"arrow_open",stroke:"thick",text:a[s-1]};break;case 79:this.$={type:"arrow",stroke:"normal"};break;case 80:this.$={type:"arrow_circle",stroke:"normal"};break;case 81: -this.$={type:"arrow_cross",stroke:"normal"};break;case 82:this.$={type:"arrow_open",stroke:"normal"};break;case 83:this.$={type:"arrow",stroke:"dotted"};break;case 84:this.$={type:"arrow_circle",stroke:"dotted"};break;case 85:this.$={type:"arrow_cross",stroke:"dotted"};break;case 86:this.$={type:"arrow_open",stroke:"dotted"};break;case 87:this.$={type:"arrow",stroke:"thick"};break;case 88:this.$={type:"arrow_circle",stroke:"thick"};break;case 89:this.$={type:"arrow_cross",stroke:"thick"};break;case 90:this.$={type:"arrow_open",stroke:"thick"};break;case 91:this.$=a[s-1];break;case 110:case 111:this.$=a[s-4],n.addClass(a[s-2],a[s]);break;case 112:this.$=a[s-4],n.setClass(a[s-2],a[s]);break;case 113:this.$=a[s-4],n.setClickEvent(a[s-2],a[s],void 0,void 0);break;case 114:this.$=a[s-6],n.setClickEvent(a[s-4],a[s-2],void 0,a[s]);break;case 115:this.$=a[s-4],n.setClickEvent(a[s-2],void 0,a[s],void 0);break;case 116:this.$=a[s-6],n.setClickEvent(a[s-4],void 0,a[s-2],a[s]);break;case 117:this.$=a[s-4],n.addVertex(a[s-2],void 0,void 0,a[s]);break;case 118:case 119:case 120:this.$=a[s-4],n.updateLink(a[s-2],a[s]);break;case 122:this.$=[a[s]];break;case 123:a[s-2].push(a[s]),this.$=a[s-2];break;case 125:this.$=a[s-1]+a[s]}},table:[{3:1,4:2,9:r,10:n,12:i},{1:[3]},e(a,s,{5:6}),{4:7,9:r,10:n,12:i},{4:8,9:r,10:n,12:i},{10:[1,9]},{1:[2,1],6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(a,[2,9]),e(a,[2,10]),{13:[1,46],15:[1,47],16:[1,48],17:[1,49],18:[1,50]},e(B,[2,3]),e(B,[2,4]),e(B,[2,5]),e(B,[2,6]),e(B,[2,7]),e(B,[2,8]),{8:L,9:O,11:I,24:51},{8:L,9:O,11:I,24:55},{8:L,9:O,11:I,24:56},{8:L,9:O,11:I,24:57},{8:L,9:O,11:I,24:58},{8:L,9:O,11:I,24:59},{8:L,9:O,10:N,11:I,12:M,13:P,15:R,16:q,17:j,18:U,24:61,30:Y,31:60,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(et,[2,42],{34:86,47:87,50:[1,88],51:[1,91],52:[1,92],53:[1,93],54:[1,94],55:[1,89],56:[1,95],57:[1,96],58:[1,97],59:[1,98],60:[1,90],61:[1,99],62:[1,100],63:[1,101],64:[1,102]}),{10:[1,103]},{10:[1,104]},{10:[1,105]},{10:[1,106]},{10:[1,107]},e(rt,[2,55],{45:32,21:113,44:114,10:nt,13:h,15:[1,112],18:d,36:[1,108],38:[1,109],40:[1,110],42:[1,111],46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S}),e(it,[2,57]),e(it,[2,59]),e(it,[2,60]),e(it,[2,61]),e(it,[2,62]),e(at,[2,150]),e(at,[2,151]),e(at,[2,152]),e(at,[2,153]),e(at,[2,154]),e(at,[2,155]),e(at,[2,156]),e(at,[2,157]),e(at,[2,158]),e(at,[2,159]),e(at,[2,160]),{8:st,9:ot,10:nt,14:116,21:119},{8:st,9:ot,10:nt,14:120,21:119},{8:st,9:ot,10:nt,14:121,21:119},{8:st,9:ot,10:nt,14:122,21:119},{8:st,9:ot,10:nt,14:123,21:119},e(B,[2,30]),e(B,[2,38]),e(B,[2,39]),e(B,[2,40]),e(B,[2,31]),e(B,[2,32]),e(B,[2,33]),e(B,[2,34]),e(B,[2,35]),{8:L,9:O,10:N,11:I,12:M,13:P,15:R,16:q,17:j,18:U,24:124,30:Y,32:G,45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(ut,s,{5:126}),e(ct,[2,92]),e(ct,[2,94]),e(ct,[2,139]),e(ct,[2,140]),e(ct,[2,141]),e(ct,[2,142]),e(ct,[2,143]),e(ct,[2,144]),e(ct,[2,145]),e(ct,[2,146]),e(ct,[2,147]),e(ct,[2,148]),e(ct,[2,149]),e(ct,[2,97]),e(ct,[2,98]),e(ct,[2,99]),e(ct,[2,100]),e(ct,[2,101]),e(ct,[2,102]),e(ct,[2,103]),e(ct,[2,104]),e(ct,[2,105]),e(ct,[2,106]),e(ct,[2,107]),{13:h,18:d,33:127,35:29,44:30,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(lt,[2,66],{48:128,49:[1,129],65:[1,130]}),{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:131,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:132,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:133,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(ht,[2,79]),e(ht,[2,80]),e(ht,[2,81]),e(ht,[2,82]),e(ht,[2,83]),e(ht,[2,84]),e(ht,[2,85]),e(ht,[2,86]),e(ht,[2,87]),e(ht,[2,88]),e(ht,[2,89]),e(ht,[2,90]),{13:h,18:d,35:134,44:30,45:32,46:p,80:[1,135],81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{78:[1,136],81:[1,137]},{13:h,18:d,35:139,44:30,45:32,46:p,78:[1,138],81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{13:h,18:d,35:140,44:30,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{13:h,18:d,35:141,44:30,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:142,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:144,32:G,38:[1,143],45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:145,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:146,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:147,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(rt,[2,56]),e(it,[2,58]),e(rt,[2,29],{21:148,10:nt}),e(a,[2,11]),e(a,[2,21]),e(a,[2,22]),{9:[1,149]},e(a,[2,12]),e(a,[2,13]),e(a,[2,14]),e(a,[2,15]),e(ut,s,{5:150}),e(ct,[2,93]),{6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,32:[1,151],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(et,[2,41]),e(lt,[2,63],{10:[1,152]}),{10:[1,153]},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:154,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,45:71,46:V,50:$,51:[1,155],52:[1,156],53:[1,157],54:[1,158],60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,45:71,46:V,50:$,56:[1,159],57:[1,160],58:[1,161],59:[1,162],60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,45:71,46:V,50:$,60:H,61:[1,163],62:[1,164],63:[1,165],64:[1,166],66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:[1,167],13:h,18:d,44:114,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:[1,168]},{10:[1,169]},{10:[1,170]},{10:[1,171]},{10:[1,172],13:h,18:d,44:114,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:[1,173],13:h,18:d,44:114,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:[1,174],13:h,18:d,44:114,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,37:[1,175],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:176,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,39:[1,177],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,41:[1,178],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,43:[1,179],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,37:[1,180],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(rt,[2,28]),e(a,[2,23]),{6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,32:[1,181],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(B,[2,37]),e(lt,[2,65]),e(lt,[2,64]),{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,45:71,46:V,50:$,60:H,65:[1,182],66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(lt,[2,67]),e(lt,[2,68]),e(lt,[2,69]),e(lt,[2,70]),e(lt,[2,71]),e(lt,[2,72]),e(lt,[2,73]),e(lt,[2,74]),e(lt,[2,75]),e(lt,[2,76]),e(lt,[2,77]),e(lt,[2,78]),{10:dt,46:ft,71:pt,79:183,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:197,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:198,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:199,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:200,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:201,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{13:h,18:d,35:202,44:30,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{13:h,18:d,35:203,44:30,45:32,46:p,67:[1,204],81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(rt,[2,43],{21:205,10:nt}),{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,39:[1,206],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(rt,[2,49],{21:207,10:nt}),e(rt,[2,47],{21:208,10:nt}),e(rt,[2,51],{21:209,10:nt}),e(rt,[2,53],{21:210,10:nt}),e(B,[2,36]),e([10,13,18,46,81,85,87,88,90,91,93,94,95,96,97],[2,91]),e(et,[2,117],{85:xt}),e(Et,[2,122],{86:212,10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,87:vt,88:bt,89:_t,90:At,91:wt}),e(Dt,[2,124]),e(Dt,[2,126]),e(Dt,[2,127]),e(Dt,[2,128]),e(Dt,[2,129]),e(Dt,[2,130]),e(Dt,[2,131]),e(Dt,[2,132]),e(Dt,[2,133]),e(Dt,[2,134]),e(Dt,[2,135]),e(Dt,[2,136]),e(et,[2,118],{85:xt}),e(et,[2,119],{85:xt}),e(et,[2,120],{85:xt}),e(et,[2,110],{85:xt}),e(et,[2,111],{85:xt}),e(et,[2,112],{45:32,44:114,13:h,18:d,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S}),e(et,[2,113],{45:32,44:114,10:[1,213],13:h,18:d,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S}),e(et,[2,115],{10:[1,214]}),e(rt,[2,44]),{39:[1,215]},e(rt,[2,50]),e(rt,[2,48]),e(rt,[2,52]),e(rt,[2,54]),{10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,84:216,86:185,87:vt,88:bt,89:_t,90:At,91:wt},e(Dt,[2,125]),{67:[1,217]},{67:[1,218]},e(rt,[2,45],{21:219,10:nt}),e(Et,[2,123],{86:212,10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,87:vt,88:bt,89:_t,90:At,91:wt}),e(et,[2,114]),e(et,[2,116]),e(rt,[2,46])],defaultActions:{},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},Ct=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;ae[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(e,i[n]),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:{},performAction:function(t,e,r,n){switch(r){case 0:break;case 1:this.begin("string");break;case 2:this.popState();break;case 3:return"STR";case 4:return 71;case 5:return 78;case 6:return 72;case 7:return 73;case 8:return 74;case 9:return 75;case 10:return 12;case 11:return 30;case 12:return 32;case 13:return 13;case 14:return 13;case 15:return 13;case 16:return 13;case 17:return 13;case 18:return 13;case 19:return 81;case 20:return 90;case 21:return 88;case 22:return 8;case 23:return 85;case 24:return 97;case 25:return 16;case 26:return 15;case 27:return 17;case 28:return 18;case 29:return 53;case 30:return 51;case 31:return 52;case 32:return 54;case 33:return 58;case 34:return 56;case 35:return 57;case 36:return 59;case 37:return 58;case 38:return 56;case 39:return 57;case 40:return 59;case 41:return 63;case 42:return 61;case 43:return 62;case 44:return 64;case 45:return 50;case 46:return 55;case 47:return 60;case 48:return 40;case 49:return 41;case 50:return 46;case 51:return 91;case 52:return 95;case 53:return 83;case 54:return 96;case 55:return 96;case 56:return 87;case 57:return 93;case 58:return 94;case 59:return 65;case 60:return 38;case 61:return 39;case 62:return 36;case 63:return 37;case 64:return 42;case 65:return 43;case 66:return 100;case 67:return 9;case 68:return 10;case 69:return 11}},rules:[/^(?:%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:v\b)/,/^(?:\s*--[x]\s*)/,/^(?:\s*-->\s*)/,/^(?:\s*--[o]\s*)/,/^(?:\s*---\s*)/,/^(?:\s*-\.-[x]\s*)/,/^(?:\s*-\.->\s*)/,/^(?:\s*-\.-[o]\s*)/,/^(?:\s*-\.-\s*)/,/^(?:\s*.-[x]\s*)/,/^(?:\s*\.->\s*)/,/^(?:\s*\.-[o]\s*)/,/^(?:\s*\.-\s*)/,/^(?:\s*==[x]\s*)/,/^(?:\s*==>\s*)/,/^(?:\s*==[o]\s*)/,/^(?:\s*==[\=]\s*)/,/^(?:\s*--\s*)/,/^(?:\s*-\.\s*)/,/^(?:\s*==\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[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])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:\n+)/,/^(?:\s)/,/^(?:$)/],conditions:{string:{rules:[2,3],inclusive:!1},INITIAL:{rules:[0,1,4,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,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69],inclusive:!0}}};return t}();return kt.lexer=Ct,t.prototype=kt,kt.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],119:[function(t,e,r){(function(e){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e["default"]=t,e}var i=t("../../logger"),a=n(i),s=t("moment"),o=new a.Log,u="",c="",l=[],h=[],d="";r.clear=function(){l=[],h=[],d="",c="",m=0,f=void 0,p=void 0,A=[]},r.setDateFormat=function(t){u=t},r.getDateFormat=function(){return u},r.setTitle=function(t){c=t},r.getTitle=function(){return c},r.addSection=function(t){d=t,l.push(t)},r.getTasks=function(){for(var t=x(),e=10,r=0;!t&&e>r;)t=x(),r++;return h=A};var f,p,g=function(t,e,n){n=n.trim();var i=/^after\s+([\d\w\-]+)/,a=i.exec(n.trim());if(null!==a){var u=r.findTaskById(a[1]);if("undefined"==typeof u){var c=new Date;return c.setHours(0,0,0,0),c}return u.endTime}return s(n,e.trim(),!0).isValid()?s(n,e.trim(),!0).toDate():(o.debug("Invalid date:"+n),o.debug("With date format:"+e.trim()),new Date)},y=function(t,e,r){if(r=r.trim(),s(r,e.trim(),!0).isValid())return s(r,e.trim()).toDate();var n=s(t),i=/^([\d]+)([wdhms])/,a=i.exec(r.trim());if(null!==a){switch(a[2]){case"s":n.add(a[1],"seconds");break;case"m":n.add(a[1],"minutes");break;case"h":n.add(a[1],"hours");break;case"d":n.add(a[1],"days");break;case"w":n.add(a[1],"weeks")}return n.toDate()}return n.toDate()},m=0,v=function(t){return"undefined"==typeof t?(m+=1,"task"+m):t},b=function(t,e){var n;n=":"===e.substr(0,1)?e.substr(1,e.length):e;for(var i=n.split(","),a={},s=r.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;ur-e?r+i+1.5*s.sidePadding>o?e+n-5:r+n+5:(r-e)/2+e+n}).attr("y",function(t,n){return n*e+s.barHeight/2+(s.fontSize/2-2)+r}).attr("text-height",i).attr("class",function(t){for(var e=w(t.startTime),r=w(t.endTime),n=this.getBBox().width,i=0,a=0;ar-e?r+n+1.5*s.sidePadding>o?"taskTextOutsideLeft taskTextOutside"+i+" "+u:"taskTextOutsideRight taskTextOutside"+i+" "+u:"taskText taskText"+i+" "+u})}function l(t,e,r,a){var o,u=[[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["h1 %I:%M",function(t){return t.getMinutes()}]],c=[["%Y",function(){ -return!0}]],l=[["%I:%M",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}]];"undefined"!=typeof s.axisFormatter&&(l=[],s.axisFormatter.forEach(function(t){var e=[];e[0]=t[0],e[1]=t[1],l.push(e)})),o=u.concat(l).concat(c);var h=i.svg.axis().scale(w).orient("bottom").tickSize(-a+e+s.gridLineStartPadding,0,0).tickFormat(i.time.format.multi(o));n>7&&230>n&&(h=h.ticks(i.time.monday.range)),b.append("g").attr("class","grid").attr("transform","translate("+t+", "+(a-50)+")").call(h).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em")}function h(t,e){for(var r=[],n=0,i=0;i0))return i[1]*t/2+e;for(var s=0;a>s;s++)return n+=r[a-1][1],i[1]*t/2+n*t+e}).attr("class",function(t){for(var e=0;en;++n)e.hasOwnProperty(t[n])||(e[t[n]]=!0,r.push(t[n]));return r}function p(t){for(var e=t.length,r={};e;)r[t[--e]]=(r[t[e]]||0)+1;return r}function g(t,e){return p(e)[t]||0}r.yy.clear(),r.parse(t);var y=document.getElementById(e);o=y.parentElement.offsetWidth,"undefined"==typeof o&&(o=1200),"undefined"!=typeof s.useWidth&&(o=s.useWidth);var m=r.yy.getTasks(),v=m.length*(s.barHeight+s.barGap)+2*s.topPadding;y.setAttribute("height","100%"),y.setAttribute("viewBox","0 0 "+o+" "+v);var b=i.select("#"+e),_=i.min(m,function(t){return t.startTime}),A=i.max(m,function(t){return t.endTime}),w=i.time.scale().domain([i.min(m,function(t){return t.startTime}),i.max(m,function(t){return t.endTime})]).rangeRound([0,o-150]),x=[];n=a.duration(A-_).asDays();for(var E=0;El&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},u=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;ae[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(e,i[n]),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,r,n){switch(r){case 0:return 10;case 1:break;case 2:break;case 3:break;case 4:return 4;case 5:return 11;case 6:return"date";case 7:return 12;case 8:return 13;case 9:return 14;case 10:return 15;case 11:return":";case 12:return 6;case 13:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\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:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return t}();return o.lexer=u,t.prototype=o,o.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],122:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[2,2],n=[1,5],i=[1,7],a=[1,8],s=[1,11],o=[1,12],u=[1,13],c=[1,14],l=[1,16],h=[1,17],d=[1,7,9,10,14,16,18,19,20,21,22,33],f=[7,9,10,14,16,18,19,20,22,33],p=[1,51],g={trace:function(){},yy:{},symbols_:{error:2,start:3,SD:4,document:5,line:6,SPACE:7,statement:8,NL:9,participant:10,actor:11,signal:12,note_statement:13,title:14,text:15,loop:16,restOfLine:17,end:18,opt:19,alt:20,"else":21,note:22,placement:23,text2:24,over:25,actor_pair:26,spaceList:27,",":28,left_of:29,right_of:30,signaltype:31,actors:32,ACTOR:33,SOLID_OPEN_ARROW:34,DOTTED_OPEN_ARROW:35,SOLID_ARROW:36,DOTTED_ARROW:37,SOLID_CROSS:38,DOTTED_CROSS:39,TXT:40,$accept:0,$end:1},terminals_:{2:"error",4:"SD",7:"SPACE",9:"NL",10:"participant",14:"title",15:"text",16:"loop",17:"restOfLine",18:"end",19:"opt",20:"alt",21:"else",22:"note",25:"over",28:",",29:"left_of",30:"right_of",33:"ACTOR",34:"SOLID_OPEN_ARROW",35:"DOTTED_OPEN_ARROW",36:"SOLID_ARROW",37:"DOTTED_ARROW",38:"SOLID_CROSS",39:"DOTTED_CROSS",40:"TXT"},productions_:[0,[3,2],[5,0],[5,2],[6,2],[6,1],[6,1],[8,3],[8,2],[8,2],[8,4],[8,4],[8,4],[8,7],[13,4],[13,4],[27,2],[27,1],[26,3],[26,1],[23,1],[23,1],[12,4],[32,2],[32,1],[11,1],[31,1],[31,1],[31,1],[31,1],[31,1],[31,1],[24,1]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 1:return n.apply(a[s]),a[s];case 2:this.$=[];break;case 3:a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 5:this.$=a[s];break;case 6:this.$=[];break;case 7:this.$=a[s-1];break;case 11:a[s-1].unshift({type:"loopStart",loopText:a[s-2],signalType:n.LINETYPE.LOOP_START}),a[s-1].push({type:"loopEnd",loopText:a[s-2],signalType:n.LINETYPE.LOOP_END}),this.$=a[s-1];break;case 12:a[s-1].unshift({type:"optStart",optText:a[s-2],signalType:n.LINETYPE.OPT_START}),a[s-1].push({type:"optEnd",optText:a[s-2],signalType:n.LINETYPE.OPT_END}),this.$=a[s-1];break;case 13:a[s-4].unshift({type:"altStart",altText:a[s-5],signalType:n.LINETYPE.ALT_START}),a[s-4].push({type:"else",altText:a[s-2],signalType:n.LINETYPE.ALT_ELSE}),a[s-4]=a[s-4].concat(a[s-1]),a[s-4].push({type:"altEnd",signalType:n.LINETYPE.ALT_END}),this.$=a[s-4];break;case 14:this.$=[a[s-1],{type:"addNote",placement:a[s-2],actor:a[s-1].actor,text:a[s]}];break;case 15: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:n.PLACEMENT.OVER,actor:a[s-2].slice(0,2),text:a[s]}];break;case 18:this.$=[a[s-2],a[s]];break;case 19:this.$=a[s];break;case 20:this.$=n.PLACEMENT.LEFTOF;break;case 21:this.$=n.PLACEMENT.RIGHTOF;break;case 22: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 25:this.$={type:"addActor",actor:a[s]};break;case 26:this.$=n.LINETYPE.SOLID_OPEN;break;case 27:this.$=n.LINETYPE.DOTTED_OPEN;break;case 28:this.$=n.LINETYPE.SOLID;break;case 29:this.$=n.LINETYPE.DOTTED;break;case 30:this.$=n.LINETYPE.SOLID_CROSS;break;case 31:this.$=n.LINETYPE.DOTTED_CROSS;break;case 32:this.$=a[s].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e([1,7,9,10,14,16,19,20,22,33],r,{5:3}),{1:[2,1],6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,22:l,33:h},e(d,[2,3]),{8:18,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,22:l,33:h},e(d,[2,5]),e(d,[2,6]),{11:19,33:h},{9:[1,20]},{9:[1,21]},{7:[1,22]},{17:[1,23]},{17:[1,24]},{17:[1,25]},{31:26,34:[1,27],35:[1,28],36:[1,29],37:[1,30],38:[1,31],39:[1,32]},{23:33,25:[1,34],29:[1,35],30:[1,36]},e([9,28,34,35,36,37,38,39,40],[2,25]),e(d,[2,4]),{9:[1,37]},e(d,[2,8]),e(d,[2,9]),{15:[1,38]},e(f,r,{5:39}),e(f,r,{5:40}),e([7,9,10,14,16,19,20,21,22,33],r,{5:41}),{11:42,33:h},{33:[2,26]},{33:[2,27]},{33:[2,28]},{33:[2,29]},{33:[2,30]},{33:[2,31]},{11:43,33:h},{11:45,26:44,33:h},{33:[2,20]},{33:[2,21]},e(d,[2,7]),{9:[1,46]},{6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,47],19:u,20:c,22:l,33:h},{6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,48],19:u,20:c,22:l,33:h},{6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,21:[1,49],22:l,33:h},{24:50,40:p},{24:52,40:p},{24:53,40:p},{28:[1,54],40:[2,19]},e(d,[2,10]),e(d,[2,11]),e(d,[2,12]),{17:[1,55]},{9:[2,22]},{9:[2,32]},{9:[2,14]},{9:[2,15]},{11:56,33:h},e(f,r,{5:57}),{40:[2,18]},{6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,58],19:u,20:c,22:l,33:h},e(d,[2,13])],defaultActions:{27:[2,26],28:[2,27],29:[2,28],30:[2,29],31:[2,30],32:[2,31],35:[2,20],36:[2,21],50:[2,22],51:[2,32],52:[2,14],53:[2,15],56:[2,18]},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},y=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;ae[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(e,i[n]),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,r,n){switch(r){case 0:return 9;case 1:break;case 2:break;case 3:break;case 4:break;case 5:return 10;case 6:return this.begin("LINE"),16;case 7:return this.begin("LINE"),19;case 8:return this.begin("LINE"),20;case 9:return this.begin("LINE"),21;case 10:return this.popState(),17;case 11:return 18;case 12:return 29;case 13:return 30;case 14:return 25;case 15:return 22;case 16:return 14;case 17:return 4;case 18:return 28;case 19:return 9;case 20:return 33;case 21:return 36;case 22:return 37;case 23:return 34;case 24:return 35;case 25:return 38;case 26:return 39;case 27:return 40;case 28:return 9;case 29:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:participant\b)/i,/^(?:loop\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\->:\n,;]+)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[2,3,10],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29],inclusive:!0}}};return t}();return g.lexer=y,t.prototype=g,g.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],123:[function(t,e,r){(function(e){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e["default"]=t,e}var i=t("../../logger"),a=n(i),s={},o=[],u=[],c=[],l=new a.Log;r.addActor=function(t,e,r){s[t]={name:e,description:r},o.push(t)},r.addMessage=function(t,e,r,n){u.push({from:t,to:e,message:r,answer:n})},r.addSignal=function(t,e,r,n){l.debug("Adding message from="+t+" to="+e+" message="+r+" type="+n),u.push({from:t,to:e,message:r,type:n})},r.getMessages=function(){return u},r.getActors=function(){return s},r.getActor=function(t){return s[t]},r.getActorKeys=function(){return Object.keys(s)},r.clear=function(){s={},u=[]},r.LINETYPE={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},r.ARROWTYPE={FILLED:0,OPEN:1},r.PLACEMENT={LEFTOF:0,RIGHTOF:1,OVER:2},r.addNote=function(t,e,n){var i={actor:t,placement:e,message:n},a=[].concat(t,t);c.push(i),u.push({from:a[0],to:a[1],message:n,type:r.LINETYPE.NOTE,placement:e})},r.parseError=function(t,r){e.mermaidAPI.parseError(t,r)},r.apply=function(t){if(t instanceof Array)t.forEach(function(t){r.apply(t)});else switch(t.type){case"addActor":r.addActor(t.actor,t.actor,t.actor);break;case"addNote":r.addNote(t.actor,t.placement,t.text);break;case"addMessage":r.addSignal(t.from,t.to,t.msg,t.signalType);break;case"loopStart":r.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":r.addSignal(void 0,void 0,void 0,t.signalType);break;case"optStart":r.addSignal(void 0,void 0,t.optText,t.signalType);break;case"optEnd":r.addSignal(void 0,void 0,void 0,t.signalType);break;case"altStart":r.addSignal(void 0,void 0,t.altText,t.signalType);break;case"else":r.addSignal(void 0,void 0,t.altText,t.signalType);break;case"altEnd":r.addSignal(void 0,void 0,void 0,t.signalType)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":126}],124:[function(t,e,r){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e["default"]=t,e}var i=t("../../logger"),a=n(i),s=t("./parser/sequenceDiagram").parser;s.yy=t("./sequenceDb");var o=t("./svgDraw"),u=t("../../d3"),c=new a.Log,l={diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!1,bottomMarginAdj:1};r.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,r,n){t[e]="undefined"==typeof t[e]?r:n(r,t[e])},updateLoops:function(t,e,n,i){var a=this,s=0;this.list.forEach(function(o){s++;var u=a.list.length-s+1;a.updateVal(o,"startx",t-u*l.boxMargin,Math.min),a.updateVal(o,"starty",e-u*l.boxMargin,Math.min),a.updateVal(o,"stopx",n+u*l.boxMargin,Math.max),a.updateVal(o,"stopy",i+u*l.boxMargin,Math.max),a.updateVal(r.bounds.data,"startx",t-u*l.boxMargin,Math.min),a.updateVal(r.bounds.data,"starty",e-u*l.boxMargin,Math.min),a.updateVal(r.bounds.data,"stopx",n+u*l.boxMargin,Math.max),a.updateVal(r.bounds.data,"stopy",i+u*l.boxMargin,Math.max)})},insert:function(t,e,n,i){var a,s,o,u;a=Math.min(t,n),o=Math.max(t,n),s=Math.min(e,i),u=Math.max(e,i),this.updateVal(r.bounds.data,"startx",a,Math.min),this.updateVal(r.bounds.data,"starty",s,Math.min),this.updateVal(r.bounds.data,"stopx",o,Math.max),this.updateVal(r.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=r.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 h=function(t,e,n,i,a){var s=o.getNoteRect();s.x=e,s.y=n,s.width=a||l.width,s["class"]="note";var u=t.append("g"),c=o.drawRect(u,s),h=o.getTextObj();h.x=e-4,h.y=n-13,h.textMargin=l.noteMargin,h.dy="1em",h.text=i.message,h["class"]="noteText";var d=o.drawText(u,h,s.width-l.noteMargin),f=d[0][0].getBBox().height;!a&&f>l.width?(d.remove(),u=t.append("g"),d=o.drawText(u,h,2*s.width-l.noteMargin),f=d[0][0].getBBox().height,c.attr("width",2*s.width),r.bounds.insert(e,n,e+2*s.width,n+2*l.noteMargin+f)):r.bounds.insert(e,n,e+s.width,n+2*l.noteMargin+f),c.attr("height",f+2*l.noteMargin),r.bounds.bumpVerticalPos(f+2*l.noteMargin)},d=function(t,e,n,i,a){var o,u=t.append("g"),c=e+(n-e)/2,l=u.append("text").attr("x",c).attr("y",i-7).style("text-anchor","middle").attr("class","messageText").text(a.message);o="undefined"!=typeof l[0][0].getBBox?l[0][0].getBBox().width:l[0][0].getBoundingClientRect();var h;if(e===n){h=u.append("path").attr("d","M "+e+","+i+" C "+(e+60)+","+(i-10)+" "+(e+60)+","+(i+30)+" "+e+","+(i+20)),r.bounds.bumpVerticalPos(30);var d=Math.max(o/2,100);r.bounds.insert(e-d,r.bounds.getVerticalPos()-10,n+d,r.bounds.getVerticalPos())}else h=u.append("line"),h.attr("x1",e),h.attr("y1",i),h.attr("x2",n),h.attr("y2",i),r.bounds.insert(e,r.bounds.getVerticalPos()-10,n,r.bounds.getVerticalPos());a.type===s.yy.LINETYPE.DOTTED||a.type===s.yy.LINETYPE.DOTTED_CROSS||a.type===s.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0");var f=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;f=f.replace(/\(/g,"\\("),f=f.replace(/\)/g,"\\)"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(a.type===s.yy.LINETYPE.SOLID||a.type===s.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+f+"#arrowhead)"),(a.type===s.yy.LINETYPE.SOLID_CROSS||a.type===s.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+f+"#crosshead)")};e.exports.drawActors=function(t,e,n,i){var a;for(a=0;a0?t.split(",").forEach(function(t){setTooltip(t,n),setClickFun(t,e),setLink(t,r)}):(setTooltip(t,n),setClickFun(t,e),setLink(t,r))},exports.bindFunctions=function(t){funs.forEach(function(e){e(t)})},exports.getDirection=function(){return direction},exports.getVertices=function(){return vertices},exports.getEdges=function(){return edges},exports.getClasses=function(){return classes};var setupToolTips=function(t){var e=d3.select(".mermaidTooltip");null===e[0][0]&&(e=d3.select("body").append("div").attr("class","mermaidTooltip").style("opacity",0));var r=d3.select(t).select("svg"),n=r.selectAll("g.node");n.on("mouseover",function(){var t=d3.select(this),r=t.attr("title");if(null!==r){var n=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",n.left+(n.right-n.left)/2+"px").style("top",n.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}}).on("mouseout",function(){e.transition().duration(500).style("opacity",0);var t=d3.select(this);t.classed("hover",!1)})};funs.push(setupToolTips),exports.clear=function(){vertices={},classes={},edges=[],funs=[],funs.push(setupToolTips),subGraphs=[],subCount=0,tooltips=[]},exports.defaultStyle=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},exports.addSubGraph=function(t,e){function r(t){var e={"boolean":{},number:{},string:{}},r=[];return t.filter(function(t){var n=typeof t;return" "===t?!1:n in e?e[n].hasOwnProperty(t)?!1:e[n][t]=!0:r.indexOf(t)>=0?!1:r.push(t)})}var n=[];n=r(n.concat.apply(n,t));var i={id:"subGraph"+subCount,nodes:n,title:e};return subGraphs.push(i),subCount+=1,i.id};var getPosForId=function(t){var e;for(e=0;e2e3)){if(posCrossRef[secCount]=r,subGraphs[r].id===e)return{result:!0,count:0};for(var i=0,a=1;i=0){var o=t(e,s);if(o.result)return{result:!0,count:a+o.count};a+=o.count}i+=1}return{result:!1,count:a}}};exports.getDepthFirstPos=function(t){return posCrossRef[t]},exports.indexNodes=function(){secCount=-1,subGraphs.length>0&&indexNodes("none",subGraphs.length-1,0)},exports.getSubGraphs=function(){return subGraphs},exports.parseError=function(t,e){global.mermaidAPI.parseError(t,e)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../d3":107,"../../logger":126}],117:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[1,5],n=[1,6],i=[1,12],a=[1,13],s=[1,14],o=[1,15],u=[1,16],c=[1,17],l=[1,18],h=[1,19],d=[1,20],f=[1,21],p=[1,22],g=[8,16,17,18,19,20,21,22,23,24,25,26],y=[1,37],m=[1,33],v=[1,34],b=[1,35],_=[1,36],A=[8,10,16,17,18,19,20,21,22,23,24,25,26,28,32,37,39,40,45,57,58],w=[10,28],x=[10,28,37,57,58],E=[2,49],D=[1,45],k=[1,48],C=[1,49],F=[1,52],T=[2,65],S=[1,65],B=[1,66],L=[1,67],O=[1,68],I=[1,69],N=[1,70],M=[1,71],P=[1,72],R=[1,73],q=[8,16,17,18,19,20,21,22,23,24,25,26,47],j=[10,28,37],U={trace:function(){},yy:{},symbols_:{error:2,expressions:3,graph:4,EOF:5,graphStatement:6,idStatement:7,"{":8,stmt_list:9,"}":10,strict:11,GRAPH:12,DIGRAPH:13,textNoTags:14,textNoTagsToken:15,ALPHA:16,NUM:17,COLON:18,PLUS:19,EQUALS:20,MULT:21,DOT:22,BRKT:23,SPACE:24,MINUS:25,keywords:26,stmt:27,";":28,node_stmt:29,edge_stmt:30,attr_stmt:31,"=":32,subgraph:33,attr_list:34,NODE:35,EDGE:36,"[":37,a_list:38,"]":39,",":40,edgeRHS:41,node_id:42,edgeop:43,port:44,":":45,compass_pt:46,SUBGRAPH:47,n:48,ne:49,e:50,se:51,s:52,sw:53,w:54,nw:55,c:56,ARROW_POINT:57,ARROW_OPEN:58,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",8:"{",10:"}",11:"strict",12:"GRAPH",13:"DIGRAPH",16:"ALPHA",17:"NUM",18:"COLON",19:"PLUS",20:"EQUALS",21:"MULT",22:"DOT",23:"BRKT",24:"SPACE",25:"MINUS",26:"keywords",28:";",32:"=",35:"NODE",36:"EDGE",37:"[",39:"]",40:",",45:":",47:"SUBGRAPH",48:"n",49:"ne",50:"e",51:"se",52:"s",53:"sw",54:"w",55:"nw",56:"c",57:"ARROW_POINT",58:"ARROW_OPEN"},productions_:[0,[3,2],[4,5],[4,6],[4,4],[6,1],[6,1],[7,1],[14,1],[14,2],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[9,1],[9,3],[27,1],[27,1],[27,1],[27,3],[27,1],[31,2],[31,2],[31,2],[34,4],[34,3],[34,3],[34,2],[38,5],[38,5],[38,3],[30,3],[30,3],[30,2],[30,2],[41,3],[41,3],[41,2],[41,2],[29,2],[29,1],[42,2],[42,1],[44,4],[44,2],[44,2],[33,5],[33,4],[33,3],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,0],[43,1],[43,1]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 1:this.$=a[s-1];break;case 2:this.$=a[s-4];break;case 3:this.$=a[s-5];break;case 4:this.$=a[s-3];break;case 8:case 10:case 11:this.$=a[s];break;case 9:this.$=a[s-1]+""+a[s];break;case 12:case 13:case 14:case 15:case 16:case 18:case 19:case 20:this.$=a[s];break;case 17:this.$="
";break;case 39:this.$="oy";break;case 40:n.addLink(a[s-1],a[s].id,a[s].op),this.$="oy";break;case 42:n.addLink(a[s-1],a[s].id,a[s].op),this.$={op:a[s-2],id:a[s-1]};break;case 44:this.$={op:a[s-1],id:a[s]};break;case 48:n.addVertex(a[s-1]),this.$=a[s-1];break;case 49:n.addVertex(a[s]),this.$=a[s];break;case 66:this.$="arrow";break;case 67:this.$="arrow_open"}},table:[{3:1,4:2,6:3,11:[1,4],12:r,13:n},{1:[3]},{5:[1,7]},{7:8,8:[1,9],14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{6:23,12:r,13:n},e(g,[2,5]),e(g,[2,6]),{1:[2,1]},{8:[1,24]},{7:30,8:y,9:25,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},e([8,10,28,32,37,39,40,45,57,58],[2,7],{15:38,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p}),e(A,[2,8]),e(A,[2,10]),e(A,[2,11]),e(A,[2,12]),e(A,[2,13]),e(A,[2,14]),e(A,[2,15]),e(A,[2,16]),e(A,[2,17]),e(A,[2,18]),e(A,[2,19]),e(A,[2,20]),{7:39,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{7:30,8:y,9:40,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,41]},{10:[2,21],28:[1,42]},e(w,[2,23]),e(w,[2,24]),e(w,[2,25]),e(x,E,{44:44,32:[1,43],45:D}),e(w,[2,27],{41:46,43:47,57:k,58:C}),e(w,[2,47],{43:47,34:50,41:51,37:F,57:k,58:C}),{34:53,37:F},{34:54,37:F},{34:55,37:F},{7:56,8:[1,57],14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{7:30,8:y,9:58,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},e(A,[2,9]),{8:[1,59]},{10:[1,60]},{5:[2,4]},{7:30,8:y,9:61,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{7:62,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},e(x,[2,48]),e(x,T,{14:10,15:11,7:63,46:64,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,48:S,49:B,50:L,51:O,52:I,53:N,54:M,55:P,56:R}),e(w,[2,41],{34:74,37:F}),{7:77,8:y,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,33:76,42:75,47:_},e(q,[2,66]),e(q,[2,67]),e(w,[2,46]),e(w,[2,40],{34:78,37:F}),{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:79,39:[1,80]},e(w,[2,28]),e(w,[2,29]),e(w,[2,30]),{8:[1,82]},{7:30,8:y,9:83,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,84]},{7:30,8:y,9:85,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{5:[2,2]},{10:[2,22]},e(w,[2,26]),e(x,[2,51],{45:[1,86]}),e(x,[2,52]),e(x,[2,56]),e(x,[2,57]),e(x,[2,58]),e(x,[2,59]),e(x,[2,60]),e(x,[2,61]),e(x,[2,62]),e(x,[2,63]),e(x,[2,64]),e(w,[2,38]),e(j,[2,44],{43:47,41:87,57:k,58:C}),e(j,[2,45],{43:47,41:88,57:k,58:C}),e(x,E,{44:44,45:D}),e(w,[2,39]),{39:[1,89]},e(w,[2,34],{34:90,37:F}),{32:[1,91]},{7:30,8:y,9:92,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:b,42:32,47:_},{10:[1,93]},e(x,[2,55]),{10:[1,94]},e(x,T,{46:95,48:S,49:B,50:L,51:O,52:I,53:N,54:M,55:P,56:R}),e(j,[2,42]),e(j,[2,43]),e(w,[2,33],{34:96,37:F}),e(w,[2,32]),{7:97,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{10:[1,98]},e(x,[2,54]),{5:[2,3]},e(x,[2,50]),e(w,[2,31]),{28:[1,99],39:[2,37],40:[1,100]},e(x,[2,53]),{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:101},{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:102},{39:[2,35]},{39:[2,36]}],defaultActions:{7:[2,1],41:[2,4],60:[2,2],61:[2,22],94:[2,3],101:[2,35],102:[2,36]},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},Y=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;ae[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(e,i[n]),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:{},performAction:function(t,e,r,n){switch(r){case 0:return"STYLE";case 1:return"LINKSTYLE";case 2:return"CLASSDEF";case 3:return"CLASS";case 4:return"CLICK";case 5:return 12;case 6:return 13;case 7:return 47;case 8:return 35;case 9:return 36;case 10:return"DIR";case 11:return"DIR";case 12:return"DIR";case 13:return"DIR";case 14:return"DIR";case 15:return"DIR";case 16:return 17;case 17:return 23;case 18:return 18;case 19:return 28;case 20:return 40;case 21:return 32;case 22:return 21;case 23:return 22;case 24:return"ARROW_CROSS";case 25:return 57;case 26:return"ARROW_CIRCLE";case 27:return 58;case 28:return 25;case 29:return 19;case 30:return 20;case 31:return 16;case 32:return"PIPE";case 33:return"PS";case 34:return"PE";case 35:return 37;case 36:return 39;case 37:return 8;case 38:return 10;case 39:return"QUOTE";case 40:return 24;case 41:return"NEWLINE";case 42:return 5}},rules:[/^(?:style\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:digraph\b)/,/^(?:subgraph\b)/,/^(?:node\b)/,/^(?:edge\b)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9])/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:=)/,/^(?:\*)/,/^(?:\.)/,/^(?:--[x])/,/^(?:->)/,/^(?:--[o])/,/^(?:--)/,/^(?:-)/,/^(?:\+)/,/^(?:=)/,/^(?:[\u0021-\u0027\u002A-\u002E\u003F\u0041-\u005A\u0061-\u007A\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)/,/^(?:\n)/,/^(?:$)/],conditions:{INITIAL:{rules:[0,1,2,3,4,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],inclusive:!0}}};return t}();return U.lexer=Y,t.prototype=U,U.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],118:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[1,4],n=[1,3],i=[1,5],a=[1,8,9,10,11,13,18,30,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],s=[2,2],o=[1,12],u=[1,13],c=[1,14],l=[1,15],h=[1,31],d=[1,33],f=[1,22],p=[1,34],g=[1,24],y=[1,25],m=[1,26],v=[1,27],b=[1,28],_=[1,38],A=[1,40],w=[1,35],x=[1,39],E=[1,45],D=[1,44],k=[1,36],C=[1,37],F=[1,41],T=[1,42],S=[1,43],B=[1,8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],L=[1,53],O=[1,52],I=[1,54],N=[1,72],M=[1,80],P=[1,81],R=[1,66],q=[1,65],j=[1,85],U=[1,84],Y=[1,82],G=[1,83],V=[1,73],$=[1,68],H=[1,67],W=[1,63],z=[1,75],Z=[1,76],X=[1,77],K=[1,78],J=[1,79],Q=[1,70],tt=[1,69],et=[8,9,11],rt=[8,9,11,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64],nt=[1,115],it=[8,9,10,11,13,15,18,36,38,40,42,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,85,87,88,90,91,93,94,95,96,97],at=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,42,43,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],st=[1,117],ot=[1,118],ut=[8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],ct=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,43,46,50,51,52,53,54,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],lt=[13,18,46,81,85,87,88,90,91,93,94,95,96,97],ht=[13,18,46,49,65,81,85,87,88,90,91,93,94,95,96,97],dt=[1,191],ft=[1,188],pt=[1,195],gt=[1,192],yt=[1,189],mt=[1,196],vt=[1,186],bt=[1,187],_t=[1,190],At=[1,193],wt=[1,194],xt=[1,211],Et=[8,9,11,85],Dt=[8,9,10,11,46,71,80,81,83,85,87,88,89,90,91],kt={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,"(-":40,"-)":41,DIAMOND_START:42,DIAMOND_STOP:43,alphaNumStatement:44,alphaNumToken:45,MINUS:46,linkStatement:47,arrowText:48,TESTSTR:49,"--":50,ARROW_POINT:51,ARROW_CIRCLE:52,ARROW_CROSS:53,ARROW_OPEN:54,"-.":55,DOTTED_ARROW_POINT:56,DOTTED_ARROW_CIRCLE:57,DOTTED_ARROW_CROSS:58,DOTTED_ARROW_OPEN:59,"==":60,THICK_ARROW_POINT:61,THICK_ARROW_CIRCLE:62,THICK_ARROW_CROSS:63,THICK_ARROW_OPEN:64,PIPE:65,textToken:66,STR:67,commentText:68,commentToken:69,keywords:70,STYLE:71,LINKSTYLE:72,CLASSDEF:73,CLASS:74,CLICK:75,textNoTags:76,textNoTagsToken:77,DEFAULT:78,stylesOpt:79,HEX:80,NUM:81,commentStatement:82,PCT:83,style:84,COMMA:85,styleComponent:86,ALPHA:87,COLON:88,UNIT:89,BRKT:90,DOT:91,graphCodeTokens:92,PUNCTUATION:93,UNICODE_TEXT:94,PLUS:95,EQUALS:96,MULT:97,TAG_START:98,TAG_END:99,QUOTE:100,$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:"(-",41:"-)",42:"DIAMOND_START",43:"DIAMOND_STOP",46:"MINUS",49:"TESTSTR",50:"--",51:"ARROW_POINT",52:"ARROW_CIRCLE",53:"ARROW_CROSS",54:"ARROW_OPEN",55:"-.",56:"DOTTED_ARROW_POINT",57:"DOTTED_ARROW_CIRCLE",58:"DOTTED_ARROW_CROSS",59:"DOTTED_ARROW_OPEN",60:"==",61:"THICK_ARROW_POINT",62:"THICK_ARROW_CIRCLE",63:"THICK_ARROW_CROSS",64:"THICK_ARROW_OPEN",65:"PIPE",67:"STR",71:"STYLE",72:"LINKSTYLE",73:"CLASSDEF",74:"CLASS",75:"CLICK",78:"DEFAULT",80:"HEX",81:"NUM",83:"PCT",85:"COMMA",87:"ALPHA",88:"COLON",89:"UNIT",90:"BRKT",91:"DOT",93:"PUNCTUATION",94:"UNICODE_TEXT",95:"PLUS",96:"EQUALS",97:"MULT",98:"TAG_START",99:"TAG_END",100:"QUOTE"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,4],[4,4],[4,4],[4,4],[4,4],[19,2],[19,1],[20,1],[20,1],[20,1],[14,1],[14,1],[14,2],[22,2],[22,2],[22,1],[22,1],[21,2],[21,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,5],[7,4],[24,1],[24,1],[24,1],[23,3],[23,1],[33,4],[33,5],[33,6],[33,7],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,1],[33,2],[35,1],[35,2],[44,1],[44,1],[44,1],[44,1],[34,2],[34,3],[34,3],[34,1],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[48,3],[31,1],[31,2],[31,1],[68,1],[68,2],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[76,1],[76,2],[27,5],[27,5],[28,5],[29,5],[29,7],[29,5],[29,7],[25,5],[25,5],[26,5],[26,5],[82,3],[79,1],[79,3],[84,1],[84,2],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[69,1],[69,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[77,1],[77,1],[77,1],[77,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 2:this.$=[];break;case 3:a[s]!==[]&&a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 57:case 59:case 60:case 92:case 94:case 95:case 108:this.$=a[s];break;case 11:n.setDirection(a[s-1]),this.$=a[s-1];break;case 12:n.setDirection("LR"),this.$=a[s-1];break;case 13:n.setDirection("RL"),this.$=a[s-1];break;case 14:n.setDirection("BT"),this.$=a[s-1];break;case 15:n.setDirection("TB"),this.$=a[s-1];break;case 30:this.$=a[s-1];break;case 31:case 32:case 33:case 34:case 35:this.$=[];break;case 36:this.$=n.addSubGraph(a[s-1],a[s-3]);break;case 37:this.$=n.addSubGraph(a[s-1],void 0);break;case 41:n.addLink(a[s-2],a[s],a[s-1]),this.$=[a[s-2],a[s]];break;case 42:this.$=[a[s]];break;case 43:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"square");break;case 44:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"square");break;case 45:this.$=a[s-5],n.addVertex(a[s-5],a[s-2],"circle");break;case 46:this.$=a[s-6],n.addVertex(a[s-6],a[s-3],"circle");break;case 47:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"ellipse");break;case 48:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"ellipse");break;case 49:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"round");break;case 50:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"round");break;case 51:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"diamond");break;case 52:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"diamond");break;case 53:this.$=a[s-3],n.addVertex(a[s-3],a[s-1],"odd");break;case 54:this.$=a[s-4],n.addVertex(a[s-4],a[s-2],"odd");break;case 55:this.$=a[s],n.addVertex(a[s]);break;case 56:this.$=a[s-1],n.addVertex(a[s-1]);break;case 58:case 93:case 96:case 109:this.$=a[s-1]+""+a[s];break;case 61:this.$="v";break;case 62:this.$="-";break;case 63:a[s-1].text=a[s],this.$=a[s-1];break;case 64:case 65:a[s-2].text=a[s-1],this.$=a[s-2];break;case 66:this.$=a[s];break;case 67:this.$={type:"arrow",stroke:"normal",text:a[s-1]};break;case 68:this.$={type:"arrow_circle",stroke:"normal",text:a[s-1]};break;case 69:this.$={type:"arrow_cross",stroke:"normal",text:a[s-1]};break;case 70:this.$={type:"arrow_open",stroke:"normal",text:a[s-1]};break;case 71:this.$={type:"arrow",stroke:"dotted",text:a[s-1]};break;case 72:this.$={type:"arrow_circle",stroke:"dotted",text:a[s-1]};break;case 73:this.$={type:"arrow_cross",stroke:"dotted",text:a[s-1]};break;case 74:this.$={type:"arrow_open",stroke:"dotted",text:a[s-1]};break;case 75:this.$={type:"arrow",stroke:"thick",text:a[s-1]};break;case 76:this.$={type:"arrow_circle",stroke:"thick",text:a[s-1]};break;case 77:this.$={type:"arrow_cross",stroke:"thick",text:a[s-1]};break;case 78:this.$={type:"arrow_open",stroke:"thick",text:a[s-1]};break;case 79:this.$={type:"arrow",stroke:"normal"};break;case 80:this.$={type:"arrow_circle",stroke:"normal"};break;case 81:this.$={type:"arrow_cross",stroke:"normal"};break;case 82:this.$={type:"arrow_open",stroke:"normal"};break;case 83:this.$={type:"arrow",stroke:"dotted"};break;case 84:this.$={type:"arrow_circle",stroke:"dotted"};break;case 85:this.$={type:"arrow_cross",stroke:"dotted"};break;case 86:this.$={type:"arrow_open",stroke:"dotted"};break;case 87:this.$={type:"arrow",stroke:"thick"};break;case 88:this.$={type:"arrow_circle",stroke:"thick"};break;case 89:this.$={type:"arrow_cross",stroke:"thick"};break;case 90:this.$={type:"arrow_open",stroke:"thick"};break;case 91:this.$=a[s-1];break;case 110:case 111:this.$=a[s-4],n.addClass(a[s-2],a[s]);break;case 112:this.$=a[s-4],n.setClass(a[s-2],a[s]);break;case 113:this.$=a[s-4],n.setClickEvent(a[s-2],a[s],void 0,void 0);break;case 114:this.$=a[s-6],n.setClickEvent(a[s-4],a[s-2],void 0,a[s]);break;case 115:this.$=a[s-4],n.setClickEvent(a[s-2],void 0,a[s],void 0);break;case 116:this.$=a[s-6],n.setClickEvent(a[s-4],void 0,a[s-2],a[s]);break;case 117:this.$=a[s-4],n.addVertex(a[s-2],void 0,void 0,a[s]);break;case 118:case 119:case 120:this.$=a[s-4],n.updateLink(a[s-2],a[s]);break;case 122:this.$=[a[s]];break;case 123:a[s-2].push(a[s]),this.$=a[s-2];break;case 125:this.$=a[s-1]+a[s]}},table:[{3:1,4:2,9:r,10:n,12:i},{1:[3]},e(a,s,{5:6}),{4:7,9:r,10:n,12:i},{4:8,9:r,10:n,12:i},{10:[1,9]},{1:[2,1],6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(a,[2,9]),e(a,[2,10]),{13:[1,46],15:[1,47],16:[1,48],17:[1,49],18:[1,50]},e(B,[2,3]),e(B,[2,4]),e(B,[2,5]),e(B,[2,6]),e(B,[2,7]),e(B,[2,8]),{8:L,9:O,11:I,24:51},{8:L,9:O,11:I,24:55},{8:L,9:O,11:I,24:56},{8:L,9:O,11:I,24:57},{8:L,9:O,11:I,24:58},{8:L,9:O,11:I,24:59},{8:L,9:O, +10:N,11:I,12:M,13:P,15:R,16:q,17:j,18:U,24:61,30:Y,31:60,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(et,[2,42],{34:86,47:87,50:[1,88],51:[1,91],52:[1,92],53:[1,93],54:[1,94],55:[1,89],56:[1,95],57:[1,96],58:[1,97],59:[1,98],60:[1,90],61:[1,99],62:[1,100],63:[1,101],64:[1,102]}),{10:[1,103]},{10:[1,104]},{10:[1,105]},{10:[1,106]},{10:[1,107]},e(rt,[2,55],{45:32,21:113,44:114,10:nt,13:h,15:[1,112],18:d,36:[1,108],38:[1,109],40:[1,110],42:[1,111],46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S}),e(it,[2,57]),e(it,[2,59]),e(it,[2,60]),e(it,[2,61]),e(it,[2,62]),e(at,[2,150]),e(at,[2,151]),e(at,[2,152]),e(at,[2,153]),e(at,[2,154]),e(at,[2,155]),e(at,[2,156]),e(at,[2,157]),e(at,[2,158]),e(at,[2,159]),e(at,[2,160]),{8:st,9:ot,10:nt,14:116,21:119},{8:st,9:ot,10:nt,14:120,21:119},{8:st,9:ot,10:nt,14:121,21:119},{8:st,9:ot,10:nt,14:122,21:119},{8:st,9:ot,10:nt,14:123,21:119},e(B,[2,30]),e(B,[2,38]),e(B,[2,39]),e(B,[2,40]),e(B,[2,31]),e(B,[2,32]),e(B,[2,33]),e(B,[2,34]),e(B,[2,35]),{8:L,9:O,10:N,11:I,12:M,13:P,15:R,16:q,17:j,18:U,24:124,30:Y,32:G,45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(ut,s,{5:126}),e(ct,[2,92]),e(ct,[2,94]),e(ct,[2,139]),e(ct,[2,140]),e(ct,[2,141]),e(ct,[2,142]),e(ct,[2,143]),e(ct,[2,144]),e(ct,[2,145]),e(ct,[2,146]),e(ct,[2,147]),e(ct,[2,148]),e(ct,[2,149]),e(ct,[2,97]),e(ct,[2,98]),e(ct,[2,99]),e(ct,[2,100]),e(ct,[2,101]),e(ct,[2,102]),e(ct,[2,103]),e(ct,[2,104]),e(ct,[2,105]),e(ct,[2,106]),e(ct,[2,107]),{13:h,18:d,33:127,35:29,44:30,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(lt,[2,66],{48:128,49:[1,129],65:[1,130]}),{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:131,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:132,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:133,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(ht,[2,79]),e(ht,[2,80]),e(ht,[2,81]),e(ht,[2,82]),e(ht,[2,83]),e(ht,[2,84]),e(ht,[2,85]),e(ht,[2,86]),e(ht,[2,87]),e(ht,[2,88]),e(ht,[2,89]),e(ht,[2,90]),{13:h,18:d,35:134,44:30,45:32,46:p,80:[1,135],81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{78:[1,136],81:[1,137]},{13:h,18:d,35:139,44:30,45:32,46:p,78:[1,138],81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{13:h,18:d,35:140,44:30,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{13:h,18:d,35:141,44:30,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:142,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:144,32:G,38:[1,143],45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:145,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:146,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:147,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(rt,[2,56]),e(it,[2,58]),e(rt,[2,29],{21:148,10:nt}),e(a,[2,11]),e(a,[2,21]),e(a,[2,22]),{9:[1,149]},e(a,[2,12]),e(a,[2,13]),e(a,[2,14]),e(a,[2,15]),e(ut,s,{5:150}),e(ct,[2,93]),{6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,32:[1,151],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(et,[2,41]),e(lt,[2,63],{10:[1,152]}),{10:[1,153]},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:154,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,45:71,46:V,50:$,51:[1,155],52:[1,156],53:[1,157],54:[1,158],60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,45:71,46:V,50:$,56:[1,159],57:[1,160],58:[1,161],59:[1,162],60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,45:71,46:V,50:$,60:H,61:[1,163],62:[1,164],63:[1,165],64:[1,166],66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:[1,167],13:h,18:d,44:114,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:[1,168]},{10:[1,169]},{10:[1,170]},{10:[1,171]},{10:[1,172],13:h,18:d,44:114,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:[1,173],13:h,18:d,44:114,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:[1,174],13:h,18:d,44:114,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,37:[1,175],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,31:176,32:G,45:71,46:V,50:$,60:H,66:62,67:W,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,39:[1,177],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,41:[1,178],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,43:[1,179],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,37:[1,180],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(rt,[2,28]),e(a,[2,23]),{6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,32:[1,181],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:b,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(B,[2,37]),e(lt,[2,65]),e(lt,[2,64]),{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,45:71,46:V,50:$,60:H,65:[1,182],66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(lt,[2,67]),e(lt,[2,68]),e(lt,[2,69]),e(lt,[2,70]),e(lt,[2,71]),e(lt,[2,72]),e(lt,[2,73]),e(lt,[2,74]),e(lt,[2,75]),e(lt,[2,76]),e(lt,[2,77]),e(lt,[2,78]),{10:dt,46:ft,71:pt,79:183,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:197,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:198,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:199,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:200,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{10:dt,46:ft,71:pt,79:201,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:bt,89:_t,90:At,91:wt},{13:h,18:d,35:202,44:30,45:32,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},{13:h,18:d,35:203,44:30,45:32,46:p,67:[1,204],81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(rt,[2,43],{21:205,10:nt}),{10:N,12:M,13:P,15:R,16:q,17:j,18:U,30:Y,32:G,39:[1,206],45:71,46:V,50:$,60:H,66:125,70:74,71:z,72:Z,73:X,74:K,75:J,77:64,78:Q,81:_,83:tt,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S},e(rt,[2,49],{21:207,10:nt}),e(rt,[2,47],{21:208,10:nt}),e(rt,[2,51],{21:209,10:nt}),e(rt,[2,53],{21:210,10:nt}),e(B,[2,36]),e([10,13,18,46,81,85,87,88,90,91,93,94,95,96,97],[2,91]),e(et,[2,117],{85:xt}),e(Et,[2,122],{86:212,10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,87:vt,88:bt,89:_t,90:At,91:wt}),e(Dt,[2,124]),e(Dt,[2,126]),e(Dt,[2,127]),e(Dt,[2,128]),e(Dt,[2,129]),e(Dt,[2,130]),e(Dt,[2,131]),e(Dt,[2,132]),e(Dt,[2,133]),e(Dt,[2,134]),e(Dt,[2,135]),e(Dt,[2,136]),e(et,[2,118],{85:xt}),e(et,[2,119],{85:xt}),e(et,[2,120],{85:xt}),e(et,[2,110],{85:xt}),e(et,[2,111],{85:xt}),e(et,[2,112],{45:32,44:114,13:h,18:d,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S}),e(et,[2,113],{45:32,44:114,10:[1,213],13:h,18:d,46:p,81:_,85:A,87:w,88:x,90:E,91:D,93:k,94:C,95:F,96:T,97:S}),e(et,[2,115],{10:[1,214]}),e(rt,[2,44]),{39:[1,215]},e(rt,[2,50]),e(rt,[2,48]),e(rt,[2,52]),e(rt,[2,54]),{10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,84:216,86:185,87:vt,88:bt,89:_t,90:At,91:wt},e(Dt,[2,125]),{67:[1,217]},{67:[1,218]},e(rt,[2,45],{21:219,10:nt}),e(Et,[2,123],{86:212,10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,87:vt,88:bt,89:_t,90:At,91:wt}),e(et,[2,114]),e(et,[2,116]),e(rt,[2,46])],defaultActions:{},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},Ct=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;ae[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(e,i[n]),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:{},performAction:function(t,e,r,n){switch(r){case 0:break;case 1:this.begin("string");break;case 2:this.popState();break;case 3:return"STR";case 4:return 71;case 5:return 78;case 6:return 72;case 7:return 73;case 8:return 74;case 9:return 75;case 10:return 12;case 11:return 30;case 12:return 32;case 13:return 13;case 14:return 13;case 15:return 13;case 16:return 13;case 17:return 13;case 18:return 13;case 19:return 81;case 20:return 90;case 21:return 88;case 22:return 8;case 23:return 85;case 24:return 97;case 25:return 16;case 26:return 15;case 27:return 17;case 28:return 18;case 29:return 53;case 30:return 51;case 31:return 52;case 32:return 54;case 33:return 58;case 34:return 56;case 35:return 57;case 36:return 59;case 37:return 58;case 38:return 56;case 39:return 57;case 40:return 59;case 41:return 63;case 42:return 61;case 43:return 62;case 44:return 64;case 45:return 50;case 46:return 55;case 47:return 60;case 48:return 40;case 49:return 41;case 50:return 46;case 51:return 91;case 52:return 95;case 53:return 83;case 54:return 96;case 55:return 96;case 56:return 87;case 57:return 93;case 58:return 94;case 59:return 65;case 60:return 38;case 61:return 39;case 62:return 36;case 63:return 37;case 64:return 42;case 65:return 43;case 66:return 100;case 67:return 9;case 68:return 10;case 69:return 11}},rules:[/^(?:%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:v\b)/,/^(?:\s*--[x]\s*)/,/^(?:\s*-->\s*)/,/^(?:\s*--[o]\s*)/,/^(?:\s*---\s*)/,/^(?:\s*-\.-[x]\s*)/,/^(?:\s*-\.->\s*)/,/^(?:\s*-\.-[o]\s*)/,/^(?:\s*-\.-\s*)/,/^(?:\s*.-[x]\s*)/,/^(?:\s*\.->\s*)/,/^(?:\s*\.-[o]\s*)/,/^(?:\s*\.-\s*)/,/^(?:\s*==[x]\s*)/,/^(?:\s*==>\s*)/,/^(?:\s*==[o]\s*)/,/^(?:\s*==[\=]\s*)/,/^(?:\s*--\s*)/,/^(?:\s*-\.\s*)/,/^(?:\s*==\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[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])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:\n+)/,/^(?:\s)/,/^(?:$)/],conditions:{string:{rules:[2,3],inclusive:!1},INITIAL:{rules:[0,1,4,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,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69],inclusive:!0}}};return t}();return kt.lexer=Ct,t.prototype=kt,kt.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],119:[function(t,e,r){(function(e){"use strict";var n=t("moment"),i=t("../../logger"),a=new i.Log,s="",o="",u=[],c=[],l="";r.clear=function(){u=[],c=[],l="",o="",g=0,h=void 0,d=void 0,b=[]},r.setDateFormat=function(t){s=t},r.getDateFormat=function(){return s},r.setTitle=function(t){o=t},r.getTitle=function(){return o},r.addSection=function(t){l=t,u.push(t)},r.getTasks=function(){for(var t=A(),e=10,r=0;!t&&e>r;)t=A(),r++;return c=b};var h,d,f=function(t,e,i){i=i.trim();var s=/^after\s+([\d\w\-]+)/,o=s.exec(i.trim());if(null!==o){var u=r.findTaskById(o[1]);if("undefined"==typeof u){var c=new Date;return c.setHours(0,0,0,0),c}return u.endTime}return n(i,e.trim(),!0).isValid()?n(i,e.trim(),!0).toDate():(a.debug("Invalid date:"+i),a.debug("With date format:"+e.trim()),new Date)},p=function(t,e,r){if(r=r.trim(),n(r,e.trim(),!0).isValid())return n(r,e.trim()).toDate();var i=n(t),a=/^([\d]+)([wdhms])/,s=a.exec(r.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()},g=0,y=function(t){return"undefined"==typeof t?(g+=1,"task"+g):t},m=function(t,e){var n;n=":"===e.substr(0,1)?e.substr(1,e.length):e;for(var i=n.split(","),a={},s=r.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;ur-e?r+i+1.5*s.sidePadding>o?e+n-5:r+n+5:(r-e)/2+e+n}).attr("y",function(t,n){return n*e+s.barHeight/2+(s.fontSize/2-2)+r}).attr("text-height",i).attr("class",function(t){for(var e=w(t.startTime),r=w(t.endTime),n=this.getBBox().width,i=0,a=0;ar-e?r+n+1.5*s.sidePadding>o?"taskTextOutsideLeft taskTextOutside"+i+" "+u:"taskTextOutsideRight taskTextOutside"+i+" "+u:"taskText taskText"+i+" "+u})}function l(t,e,r,a){var o,u=[[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["h1 %I:%M",function(t){return t.getMinutes()}]],c=[["%Y",function(){return!0}]],l=[["%I:%M",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}]];"undefined"!=typeof s.axisFormatter&&(l=[],s.axisFormatter.forEach(function(t){var e=[];e[0]=t[0],e[1]=t[1],l.push(e)})),o=u.concat(l).concat(c);var h=i.svg.axis().scale(w).orient("bottom").tickSize(-a+e+s.gridLineStartPadding,0,0).tickFormat(i.time.format.multi(o));n>7&&230>n&&(h=h.ticks(i.time.monday.range)),b.append("g").attr("class","grid").attr("transform","translate("+t+", "+(a-50)+")").call(h).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em")}function h(t,e){for(var r=[],n=0,i=0;i0))return i[1]*t/2+e;for(var s=0;a>s;s++)return n+=r[a-1][1],i[1]*t/2+n*t+e}).attr("class",function(t){for(var e=0;en;++n)e.hasOwnProperty(t[n])||(e[t[n]]=!0,r.push(t[n]));return r}function p(t){for(var e=t.length,r={};e;)r[t[--e]]=(r[t[e]]||0)+1;return r}function g(t,e){return p(e)[t]||0}r.yy.clear(),r.parse(t);var y=document.getElementById(e);o=y.parentElement.offsetWidth,"undefined"==typeof o&&(o=1200),"undefined"!=typeof s.useWidth&&(o=s.useWidth);var m=r.yy.getTasks(),v=m.length*(s.barHeight+s.barGap)+2*s.topPadding;y.setAttribute("height","100%"),y.setAttribute("viewBox","0 0 "+o+" "+v);var b=i.select("#"+e),_=i.min(m,function(t){return t.startTime; -},e.exports.setConf=function(t){var e=Object.keys(t);e.forEach(function(e){l[e]=t[e]})},e.exports.draw=function(t,n){s.yy.clear(),s.parse(t+"\n"),r.bounds.init();var i,a,f,p=u.select("#"+n),g=s.yy.getActors(),y=s.yy.getActorKeys(),m=s.yy.getMessages();e.exports.drawActors(p,g,y,0),o.insertArrowHead(p),o.insertArrowCrossHead(p),m.forEach(function(t){var e;switch(t.type){case s.yy.LINETYPE.NOTE:r.bounds.bumpVerticalPos(l.boxMargin),i=g[t.from].x,a=g[t.to].x,t.placement===s.yy.PLACEMENT.RIGHTOF?h(p,i+(l.width+l.actorMargin)/2,r.bounds.getVerticalPos(),t):t.placement===s.yy.PLACEMENT.LEFTOF?h(p,i-(l.width+l.actorMargin)/2,r.bounds.getVerticalPos(),t):t.to===t.from?h(p,i,r.bounds.getVerticalPos(),t):(f=Math.abs(i-a)+l.actorMargin,h(p,(i+a+l.width-f)/2,r.bounds.getVerticalPos(),t,f));break;case s.yy.LINETYPE.LOOP_START:r.bounds.bumpVerticalPos(l.boxMargin),r.bounds.newLoop(t.message),r.bounds.bumpVerticalPos(l.boxMargin+l.boxTextMargin);break;case s.yy.LINETYPE.LOOP_END:e=r.bounds.endLoop(),o.drawLoop(p,e,"loop",l),r.bounds.bumpVerticalPos(l.boxMargin);break;case s.yy.LINETYPE.OPT_START:r.bounds.bumpVerticalPos(l.boxMargin),r.bounds.newLoop(t.message),r.bounds.bumpVerticalPos(l.boxMargin+l.boxTextMargin);break;case s.yy.LINETYPE.OPT_END:e=r.bounds.endLoop(),o.drawLoop(p,e,"opt",l),r.bounds.bumpVerticalPos(l.boxMargin);break;case s.yy.LINETYPE.ALT_START:r.bounds.bumpVerticalPos(l.boxMargin),r.bounds.newLoop(t.message),r.bounds.bumpVerticalPos(l.boxMargin+l.boxTextMargin);break;case s.yy.LINETYPE.ALT_ELSE:r.bounds.bumpVerticalPos(l.boxMargin),e=r.bounds.addElseToLoop(t.message),r.bounds.bumpVerticalPos(l.boxMargin);break;case s.yy.LINETYPE.ALT_END:e=r.bounds.endLoop(),o.drawLoop(p,e,"alt",l),r.bounds.bumpVerticalPos(l.boxMargin);break;default:r.bounds.bumpVerticalPos(l.messageMargin),i=g[t.from].x+l.width/2,a=g[t.to].x+l.width/2,d(p,i,a,r.bounds.getVerticalPos(),t)}}),l.mirrorActors&&(r.bounds.bumpVerticalPos(2*l.boxMargin),e.exports.drawActors(p,g,y,r.bounds.getVerticalPos()));var v=r.bounds.getBounds();c.debug("For line height fix Querying: #"+n+" .actor-line");var b=u.selectAll("#"+n+" .actor-line");b.attr("y2",v.stopy);var _=v.stopy-v.starty+2*l.diagramMarginY;l.mirrorActors&&(_=_-l.boxMargin+l.bottomMarginAdj);var A=v.stopx-v.startx+2*l.diagramMarginX;l.useMaxWidth?(p.attr("height","100%"),p.attr("width","100%"),p.attr("style","max-width:"+A+"px;")):(p.attr("height",_),p.attr("width",A)),p.attr("viewBox",v.startx-l.diagramMarginX+" -"+l.diagramMarginY+" "+A+" "+_)}},{"../../d3":107,"../../logger":126,"./parser/sequenceDiagram":122,"./sequenceDb":123,"./svgDraw":125}],125:[function(t,e,r){"use strict";r.drawRect=function(t,e){var r=t.append("rect");return r.attr("x",e.x),r.attr("y",e.y),r.attr("fill",e.fill),r.attr("stroke",e.stroke),r.attr("width",e.width),r.attr("height",e.height),r.attr("rx",e.rx),r.attr("ry",e.ry),"undefined"!=typeof e["class"]&&r.attr("class",e["class"]),r},r.drawText=function(t,e,r){var n=e.text.replace(//gi," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.attr("fill",e.fill),"undefined"!=typeof e["class"]&&i.attr("class",e["class"]);var a=i.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(n),"undefined"!=typeof i.textwrap&&i.textwrap({x:e.x,y:e.y,width:r,height:1800},e.textMargin),i},r.drawLabel=function(t,e){var n=r.getNoteRect();n.x=e.x,n.y=e.y,n.width=50,n.height=20,n.fill="#526e52",n.stroke="none",n["class"]="labelBox",r.drawRect(t,n),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,e.fill="white",r.drawText(t,e)};var n=-1;r.drawActor=function(t,e,i,a,s){var o=e+s.width/2,u=t.append("g");0===i&&(n++,u.append("line").attr("id","actor"+n).attr("x1",o).attr("y1",5).attr("x2",o).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var c=r.getNoteRect();c.x=e,c.y=i,c.fill="#eaeaea",c.width=s.width,c.height=s.height,c["class"]="actor",c.rx=3,c.ry=3,r.drawRect(u,c),u.append("text").attr("x",o).attr("y",i+s.height/2+5).attr("class","actor").style("text-anchor","middle").text(a)},r.drawLoop=function(t,e,n,i){var a=t.append("g"),s=function(t,e,r,n){a.append("line").attr("x1",t).attr("y1",e).attr("x2",r).attr("y2",n).attr("stroke-width",2).attr("stroke","#526e52").attr("class","loopLine")};s(e.startx,e.starty,e.stopx,e.starty),s(e.stopx,e.starty,e.stopx,e.stopy),s(e.startx,e.stopy,e.stopx,e.stopy),s(e.startx,e.starty,e.startx,e.stopy),"undefined"!=typeof e.elsey&&s(e.startx,e.elsey,e.stopx,e.elsey);var o=r.getTextObj();o.text=n,o.x=e.startx,o.y=e.starty,o.labelMargin=1.5*i.boxMargin,o["class"]="labelText",o.fill="white",r.drawLabel(a,o),o=r.getTextObj(),o.text="[ "+e.title+" ]",o.x=e.startx+(e.stopx-e.startx)/2,o.y=e.starty+1.5*i.boxMargin,o.anchor="middle",o["class"]="loopText",r.drawText(a,o),"undefined"!=typeof e.elseText&&(o.text="[ "+e.elseText+" ]",o.y=e.elsey+1.5*i.boxMargin,r.drawText(a,o))},r.insertArrowHead=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")},r.insertArrowCrossHead=function(t){var e=t.append("defs"),r=e.append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);r.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"),r.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")},r.getTextObj=function(){var t={x:0,y:0,fill:"black","text-anchor":"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0};return t},r.getNoteRect=function(){var t={x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0};return t}},{}],126:[function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t){var e=t.getUTCHours(),r=t.getUTCMinutes(),n=t.getSeconds(),i=t.getMilliseconds();10>e&&(e="0"+e),10>r&&(r="0"+r),10>n&&(n="0"+n),100>i&&(i="0"+i),10>i&&(i="00"+i);var a=e+":"+r+":"+n+" ("+i+")";return a}var a=function(){function t(t,e){for(var r=0;r=r&&"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log("["+i(new Date)+"] "+t):void 0}},{key:"trace",value:function(t){this.log(t,s.trace)}},{key:"debug",value:function(t){this.log(t,s.debug)}},{key:"info",value:function(t){this.log(t,s.info)}},{key:"warn",value:function(t){this.log(t,s.warn)}},{key:"error",value:function(t){this.log(t,s.error)}}]),t}();r.Log=u},{}],127:[function(t,e,r){(function(n){"use strict";function i(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e["default"]=t,e}var a=t("./logger"),s=i(a),o=new s.Log,u=t("./mermaidAPI"),c=0,l=t("he");e.exports.mermaidAPI=u;var h=function(){var t=u.getConfig();o.debug("Starting rendering diagrams");var e;arguments.length>=2?("undefined"!=typeof arguments[0]&&(n.mermaid.sequenceConfig=arguments[0]),e=arguments[1]):e=arguments[0];var r;"function"==typeof arguments[arguments.length-1]?(r=arguments[arguments.length-1],o.debug("Callback function found")):"undefined"!=typeof t.mermaid&&("function"==typeof t.mermaid.callback?(r=t.mermaid.callback,o.debug("Callback function found")):o.debug("No Callback function found")),e=void 0===e?document.querySelectorAll(".mermaid"):"string"==typeof e?document.querySelectorAll(e):e instanceof Node?[e]:e;var i;"undefined"!=typeof mermaid_config&&u.initialize(n.mermaid_config),o.debug("Start On Load before: "+n.mermaid.startOnLoad),"undefined"!=typeof n.mermaid.startOnLoad&&(o.debug("Start On Load inner: "+n.mermaid.startOnLoad),u.initialize({startOnLoad:n.mermaid.startOnLoad})),"undefined"!=typeof n.mermaid.ganttConfig&&u.initialize({gantt:n.mermaid.ganttConfig});var a,s=function(t,e){h.innerHTML=t,"undefined"!=typeof r&&r(d),e(h)};for(i=0;i0&&(n+=r.selectorText+" { "+r.style.cssText+" }\n")}}catch(l){"undefined"!=typeof r&&s.warn('Invalid CSS selector "'+r.selectorText+'"',l)}var h="",d="";for(var f in e)e.hasOwnProperty(f)&&"undefined"!=typeof f&&("default"===f?(e["default"].styles instanceof Array&&(h+="#"+t.id.trim()+" .node>rect { "+e[f].styles.join("; ")+"; }\n"),e["default"].nodeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .node text { "+e[f].nodeLabelStyles.join("; ")+"; }\n"),e["default"].edgeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .edgeLabel text { "+e[f].edgeLabelStyles.join("; ")+"; }\n"),e["default"].clusterStyles instanceof Array&&(h+="#"+t.id.trim()+" .cluster rect { "+e[f].clusterStyles.join("; ")+"; }\n")):e[f].styles instanceof Array&&(d+="#"+t.id.trim()+" ."+f+">rect { "+e[f].styles.join("; ")+"; }\n"));if(""!==n||""!==h||""!==d){var p=document.createElement("style");p.setAttribute("type","text/css"),p.setAttribute("title","mermaid-svg-internal-css"),p.innerHTML="/* */\n",t.insertBefore(p,t.firstChild)}};r.cloneCssStyles=u},{"./logger":126}]},{},[127])(127)}); \ No newline at end of file +}),A=i.max(m,function(t){return t.endTime}),w=i.time.scale().domain([i.min(m,function(t){return t.startTime}),i.max(m,function(t){return t.endTime})]).rangeRound([0,o-150]),x=[];n=a.duration(A-_).asDays();for(var E=0;El&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},u=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;ae[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(e,i[n]),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,r,n){switch(r){case 0:return 10;case 1:break;case 2:break;case 3:break;case 4:return 4;case 5:return 11;case 6:return"date";case 7:return 12;case 8:return 13;case 9:return 14;case 10:return 15;case 11:return":";case 12:return 6;case 13:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\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:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return t}();return o.lexer=u,t.prototype=o,o.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],122:[function(t,e,r){(function(n){"use strict";var i=function(){function t(){this.yy={}}var e=function(t,e,r,n){for(r=r||{},n=t.length;n--;r[t[n]]=e);return r},r=[2,2],n=[1,5],i=[1,7],a=[1,8],s=[1,11],o=[1,12],u=[1,13],c=[1,14],l=[1,16],h=[1,17],d=[1,7,9,10,14,16,18,19,20,21,22,33],f=[7,9,10,14,16,18,19,20,22,33],p=[1,51],g={trace:function(){},yy:{},symbols_:{error:2,start:3,SD:4,document:5,line:6,SPACE:7,statement:8,NL:9,participant:10,actor:11,signal:12,note_statement:13,title:14,text:15,loop:16,restOfLine:17,end:18,opt:19,alt:20,"else":21,note:22,placement:23,text2:24,over:25,actor_pair:26,spaceList:27,",":28,left_of:29,right_of:30,signaltype:31,actors:32,ACTOR:33,SOLID_OPEN_ARROW:34,DOTTED_OPEN_ARROW:35,SOLID_ARROW:36,DOTTED_ARROW:37,SOLID_CROSS:38,DOTTED_CROSS:39,TXT:40,$accept:0,$end:1},terminals_:{2:"error",4:"SD",7:"SPACE",9:"NL",10:"participant",14:"title",15:"text",16:"loop",17:"restOfLine",18:"end",19:"opt",20:"alt",21:"else",22:"note",25:"over",28:",",29:"left_of",30:"right_of",33:"ACTOR",34:"SOLID_OPEN_ARROW",35:"DOTTED_OPEN_ARROW",36:"SOLID_ARROW",37:"DOTTED_ARROW",38:"SOLID_CROSS",39:"DOTTED_CROSS",40:"TXT"},productions_:[0,[3,2],[5,0],[5,2],[6,2],[6,1],[6,1],[8,3],[8,2],[8,2],[8,4],[8,4],[8,4],[8,7],[13,4],[13,4],[27,2],[27,1],[26,3],[26,1],[23,1],[23,1],[12,4],[32,2],[32,1],[11,1],[31,1],[31,1],[31,1],[31,1],[31,1],[31,1],[24,1]],performAction:function(t,e,r,n,i,a){var s=a.length-1;switch(i){case 1:return n.apply(a[s]),a[s];case 2:this.$=[];break;case 3:a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 5:this.$=a[s];break;case 6:this.$=[];break;case 7:this.$=a[s-1];break;case 11:a[s-1].unshift({type:"loopStart",loopText:a[s-2],signalType:n.LINETYPE.LOOP_START}),a[s-1].push({type:"loopEnd",loopText:a[s-2],signalType:n.LINETYPE.LOOP_END}),this.$=a[s-1];break;case 12:a[s-1].unshift({type:"optStart",optText:a[s-2],signalType:n.LINETYPE.OPT_START}),a[s-1].push({type:"optEnd",optText:a[s-2],signalType:n.LINETYPE.OPT_END}),this.$=a[s-1];break;case 13:a[s-4].unshift({type:"altStart",altText:a[s-5],signalType:n.LINETYPE.ALT_START}),a[s-4].push({type:"else",altText:a[s-2],signalType:n.LINETYPE.ALT_ELSE}),a[s-4]=a[s-4].concat(a[s-1]),a[s-4].push({type:"altEnd",signalType:n.LINETYPE.ALT_END}),this.$=a[s-4];break;case 14:this.$=[a[s-1],{type:"addNote",placement:a[s-2],actor:a[s-1].actor,text:a[s]}];break;case 15: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:n.PLACEMENT.OVER,actor:a[s-2].slice(0,2),text:a[s]}];break;case 18:this.$=[a[s-2],a[s]];break;case 19:this.$=a[s];break;case 20:this.$=n.PLACEMENT.LEFTOF;break;case 21:this.$=n.PLACEMENT.RIGHTOF;break;case 22: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 25:this.$={type:"addActor",actor:a[s]};break;case 26:this.$=n.LINETYPE.SOLID_OPEN;break;case 27:this.$=n.LINETYPE.DOTTED_OPEN;break;case 28:this.$=n.LINETYPE.SOLID;break;case 29:this.$=n.LINETYPE.DOTTED;break;case 30:this.$=n.LINETYPE.SOLID_CROSS;break;case 31:this.$=n.LINETYPE.DOTTED_CROSS;break;case 32:this.$=a[s].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e([1,7,9,10,14,16,19,20,22,33],r,{5:3}),{1:[2,1],6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,22:l,33:h},e(d,[2,3]),{8:18,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,22:l,33:h},e(d,[2,5]),e(d,[2,6]),{11:19,33:h},{9:[1,20]},{9:[1,21]},{7:[1,22]},{17:[1,23]},{17:[1,24]},{17:[1,25]},{31:26,34:[1,27],35:[1,28],36:[1,29],37:[1,30],38:[1,31],39:[1,32]},{23:33,25:[1,34],29:[1,35],30:[1,36]},e([9,28,34,35,36,37,38,39,40],[2,25]),e(d,[2,4]),{9:[1,37]},e(d,[2,8]),e(d,[2,9]),{15:[1,38]},e(f,r,{5:39}),e(f,r,{5:40}),e([7,9,10,14,16,19,20,21,22,33],r,{5:41}),{11:42,33:h},{33:[2,26]},{33:[2,27]},{33:[2,28]},{33:[2,29]},{33:[2,30]},{33:[2,31]},{11:43,33:h},{11:45,26:44,33:h},{33:[2,20]},{33:[2,21]},e(d,[2,7]),{9:[1,46]},{6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,47],19:u,20:c,22:l,33:h},{6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,48],19:u,20:c,22:l,33:h},{6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,21:[1,49],22:l,33:h},{24:50,40:p},{24:52,40:p},{24:53,40:p},{28:[1,54],40:[2,19]},e(d,[2,10]),e(d,[2,11]),e(d,[2,12]),{17:[1,55]},{9:[2,22]},{9:[2,32]},{9:[2,14]},{9:[2,15]},{11:56,33:h},e(f,r,{5:57}),{40:[2,18]},{6:4,7:n,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,58],19:u,20:c,22:l,33:h},e(d,[2,13])],defaultActions:{27:[2,26],28:[2,27],29:[2,28],30:[2,29],31:[2,30],32:[2,31],35:[2,20],36:[2,21],50:[2,22],51:[2,32],52:[2,14],53:[2,15],56:[2,18]},parseError:function(t,e){if(!e.recoverable){var r=function(t,e){this.message=t,this.hash=e};throw r.prototype=new Error,new r(t,e)}this.trace(t)},parse:function(t){var e=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,b,_,A,w,x,E,D,k,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(_=r[r.length-1],this.defaultActions[_]?A=this.defaultActions[_]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[_]&&a[_][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";k=[];for(x in a[_])this.terminals_[x]&&x>l&&k.push("'"+this.terminals_[x]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+k.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:k})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+v);switch(A[0]){case 1:r.push(v),n.push(f.yytext),i.push(f.yylloc),r.push(A[1]),v=null,b?(v=b,b=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(E=this.productions_[A[1]][1],F.$=n[n.length-E],F._$={first_line:i[i.length-(E||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(E||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(E||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(F,[s,u,o,p.yy,A[1],n,i].concat(d)),"undefined"!=typeof w)return w;E&&(r=r.slice(0,-1*E*2),n=n.slice(0,-1*E),i=i.slice(0,-1*E)),r.push(this.productions_[A[1]][0]),n.push(F.$),i.push(F._$),D=a[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0}},y=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;ae[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(e,i[n]),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,r,n){switch(r){case 0:return 9;case 1:break;case 2:break;case 3:break;case 4:break;case 5:return 10;case 6:return this.begin("LINE"),16;case 7:return this.begin("LINE"),19;case 8:return this.begin("LINE"),20;case 9:return this.begin("LINE"),21;case 10:return this.popState(),17;case 11:return 18;case 12:return 29;case 13:return 30;case 14:return 25;case 15:return 22;case 16:return 14;case 17:return 4;case 18:return 28;case 19:return 9;case 20:return 33;case 21:return 36;case 22:return 37;case 23:return 34;case 24:return 35;case 25:return 38;case 26:return 39;case 27:return 40;case 28:return 9;case 29:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:participant\b)/i,/^(?:loop\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\->:\n,;]+)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[2,3,10],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29],inclusive:!0}}};return t}();return g.lexer=y,t.prototype=g,g.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof r&&(r.parser=i,r.Parser=i.Parser,r.parse=function(){return i.parse.apply(i,arguments)},r.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),n.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return r.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&r.main(n.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],123:[function(t,e,r){(function(e){"use strict";var n={},i=[],a=[],s=[],o=t("../../logger"),u=new o.Log;r.addActor=function(t,e,r){n[t]={name:e,description:r},i.push(t)},r.addMessage=function(t,e,r,n){a.push({from:t,to:e,message:r,answer:n})},r.addSignal=function(t,e,r,n){u.debug("Adding message from="+t+" to="+e+" message="+r+" type="+n),a.push({from:t,to:e,message:r,type:n})},r.getMessages=function(){return a},r.getActors=function(){return n},r.getActor=function(t){return n[t]},r.getActorKeys=function(){return Object.keys(n)},r.clear=function(){n={},a=[]},r.LINETYPE={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},r.ARROWTYPE={FILLED:0,OPEN:1},r.PLACEMENT={LEFTOF:0,RIGHTOF:1,OVER:2},r.addNote=function(t,e,n){var i={actor:t,placement:e,message:n},o=[].concat(t,t);s.push(i),a.push({from:o[0],to:o[1],message:n,type:r.LINETYPE.NOTE,placement:e})},r.parseError=function(t,r){e.mermaidAPI.parseError(t,r)},r.apply=function(t){if(t instanceof Array)t.forEach(function(t){r.apply(t)});else switch(t.type){case"addActor":r.addActor(t.actor,t.actor,t.actor);break;case"addNote":r.addNote(t.actor,t.placement,t.text);break;case"addMessage":r.addSignal(t.from,t.to,t.msg,t.signalType);break;case"loopStart":r.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":r.addSignal(void 0,void 0,void 0,t.signalType);break;case"optStart":r.addSignal(void 0,void 0,t.optText,t.signalType);break;case"optEnd":r.addSignal(void 0,void 0,void 0,t.signalType);break;case"altStart":r.addSignal(void 0,void 0,t.altText,t.signalType);break;case"else":r.addSignal(void 0,void 0,t.altText,t.signalType);break;case"altEnd":r.addSignal(void 0,void 0,void 0,t.signalType)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":126}],124:[function(t,e,r){"use strict";var n=t("./parser/sequenceDiagram").parser;n.yy=t("./sequenceDb");var i=t("./svgDraw"),a=t("../../d3"),s=t("../../logger"),o=new s.Log,u={diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!1,bottomMarginAdj:1};r.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,r,n){t[e]="undefined"==typeof t[e]?r:n(r,t[e])},updateLoops:function(t,e,n,i){var a=this,s=0;this.list.forEach(function(o){s++;var c=a.list.length-s+1;a.updateVal(o,"startx",t-c*u.boxMargin,Math.min),a.updateVal(o,"starty",e-c*u.boxMargin,Math.min),a.updateVal(o,"stopx",n+c*u.boxMargin,Math.max),a.updateVal(o,"stopy",i+c*u.boxMargin,Math.max),a.updateVal(r.bounds.data,"startx",t-c*u.boxMargin,Math.min),a.updateVal(r.bounds.data,"starty",e-c*u.boxMargin,Math.min),a.updateVal(r.bounds.data,"stopx",n+c*u.boxMargin,Math.max),a.updateVal(r.bounds.data,"stopy",i+c*u.boxMargin,Math.max)})},insert:function(t,e,n,i){var a,s,o,u;a=Math.min(t,n),o=Math.max(t,n),s=Math.min(e,i),u=Math.max(e,i),this.updateVal(r.bounds.data,"startx",a,Math.min),this.updateVal(r.bounds.data,"starty",s,Math.min),this.updateVal(r.bounds.data,"stopx",o,Math.max),this.updateVal(r.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=r.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 c=function(t,e,n,a,s){var o=i.getNoteRect();o.x=e,o.y=n,o.width=s||u.width,o["class"]="note";var c=t.append("g"),l=i.drawRect(c,o),h=i.getTextObj();h.x=e-4,h.y=n-13,h.textMargin=u.noteMargin,h.dy="1em",h.text=a.message,h["class"]="noteText";var d=i.drawText(c,h,o.width-u.noteMargin),f=d[0][0].getBBox().height;!s&&f>u.width?(d.remove(),c=t.append("g"),d=i.drawText(c,h,2*o.width-u.noteMargin),f=d[0][0].getBBox().height,l.attr("width",2*o.width),r.bounds.insert(e,n,e+2*o.width,n+2*u.noteMargin+f)):r.bounds.insert(e,n,e+o.width,n+2*u.noteMargin+f),l.attr("height",f+2*u.noteMargin),r.bounds.bumpVerticalPos(f+2*u.noteMargin)},l=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)),r.bounds.bumpVerticalPos(30);var d=Math.max(o/2,100);r.bounds.insert(e-d,r.bounds.getVerticalPos()-10,i+d,r.bounds.getVerticalPos())}else h=u.append("line"),h.attr("x1",e),h.attr("y1",a),h.attr("x2",i),h.attr("y2",a),r.bounds.insert(e,r.bounds.getVerticalPos()-10,i,r.bounds.getVerticalPos());s.type===n.yy.LINETYPE.DOTTED||s.type===n.yy.LINETYPE.DOTTED_CROSS||s.type===n.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0");var f=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;f=f.replace(/\(/g,"\\("),f=f.replace(/\)/g,"\\)"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(s.type===n.yy.LINETYPE.SOLID||s.type===n.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+f+"#arrowhead)"),(s.type===n.yy.LINETYPE.SOLID_CROSS||s.type===n.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+f+"#crosshead)")};e.exports.drawActors=function(t,e,n,a){var s;for(s=0;s/gi," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.attr("fill",e.fill),"undefined"!=typeof e["class"]&&i.attr("class",e["class"]);var a=i.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(n),"undefined"!=typeof i.textwrap&&i.textwrap({x:e.x,y:e.y,width:r,height:1800},e.textMargin),i},r.drawLabel=function(t,e){var n=r.getNoteRect();n.x=e.x,n.y=e.y,n.width=50,n.height=20,n.fill="#526e52",n.stroke="none",n["class"]="labelBox",r.drawRect(t,n),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,e.fill="white",r.drawText(t,e)};var n=-1;r.drawActor=function(t,e,i,a,s){var o=e+s.width/2,u=t.append("g");0===i&&(n++,u.append("line").attr("id","actor"+n).attr("x1",o).attr("y1",5).attr("x2",o).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var c=r.getNoteRect();c.x=e,c.y=i,c.fill="#eaeaea",c.width=s.width,c.height=s.height,c["class"]="actor",c.rx=3,c.ry=3,r.drawRect(u,c),u.append("text").attr("x",o).attr("y",i+s.height/2+5).attr("class","actor").style("text-anchor","middle").text(a)},r.drawLoop=function(t,e,n,i){var a=t.append("g"),s=function(t,e,r,n){a.append("line").attr("x1",t).attr("y1",e).attr("x2",r).attr("y2",n).attr("stroke-width",2).attr("stroke","#526e52").attr("class","loopLine")};s(e.startx,e.starty,e.stopx,e.starty),s(e.stopx,e.starty,e.stopx,e.stopy),s(e.startx,e.stopy,e.stopx,e.stopy),s(e.startx,e.starty,e.startx,e.stopy),"undefined"!=typeof e.elsey&&s(e.startx,e.elsey,e.stopx,e.elsey);var o=r.getTextObj();o.text=n,o.x=e.startx,o.y=e.starty,o.labelMargin=1.5*i.boxMargin,o["class"]="labelText",o.fill="white",r.drawLabel(a,o),o=r.getTextObj(),o.text="[ "+e.title+" ]",o.x=e.startx+(e.stopx-e.startx)/2,o.y=e.starty+1.5*i.boxMargin,o.anchor="middle",o["class"]="loopText",r.drawText(a,o),"undefined"!=typeof e.elseText&&(o.text="[ "+e.elseText+" ]",o.y=e.elsey+1.5*i.boxMargin,r.drawText(a,o))},r.insertArrowHead=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")},r.insertArrowCrossHead=function(t){var e=t.append("defs"),r=e.append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);r.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"),r.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")},r.getTextObj=function(){var t={x:0,y:0,fill:"black","text-anchor":"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0};return t},r.getNoteRect=function(){var t={x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0};return t}},{}],126:[function(t,e,r){"use strict";function n(t){var e=t.getUTCHours(),r=t.getUTCMinutes(),n=t.getSeconds(),i=t.getMilliseconds();10>e&&(e="0"+e),10>r&&(r="0"+r),10>n&&(n="0"+n),100>i&&(i="0"+i),10>i&&(i="00"+i);var a=e+":"+r+":"+n+" ("+i+")";return a}function i(t){this.level=t,this.log=function(t,e){var r=this.level;return"undefined"==typeof r&&(r=s),e>=r&&"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log("["+n(new Date)+"] "+t):void 0},this.trace=function(t){this.log(t,a.trace)},this.debug=function(t){this.log(t,a.debug)},this.info=function(t){this.log(t,a.info)},this.warn=function(t){this.log(t,a.warn)},this.error=function(t){this.log(t,a.error)}}var a={debug:1,info:2,warn:3,error:4,fatal:5,"default":5},s=a.error;r.setLogLevel=function(t){s=t},r.Log=i},{}],127:[function(t,e,r){(function(n){"use strict";var i=t("./logger"),a=new i.Log,s=t("./mermaidAPI"),o=0,u=t("he");e.exports.mermaidAPI=s;var c=function(){var t=s.getConfig();a.debug("Starting rendering diagrams");var e;arguments.length>=2?("undefined"!=typeof arguments[0]&&(n.mermaid.sequenceConfig=arguments[0]),e=arguments[1]):e=arguments[0];var r;"function"==typeof arguments[arguments.length-1]?(r=arguments[arguments.length-1],a.debug("Callback function found")):"undefined"!=typeof t.mermaid&&("function"==typeof t.mermaid.callback?(r=t.mermaid.callback,a.debug("Callback function found")):a.debug("No Callback function found")),e=void 0===e?document.querySelectorAll(".mermaid"):"string"==typeof e?document.querySelectorAll(e):e instanceof Node?[e]:e;var i;"undefined"!=typeof mermaid_config&&s.initialize(n.mermaid_config),a.debug("Start On Load before: "+n.mermaid.startOnLoad),"undefined"!=typeof n.mermaid.startOnLoad&&(a.debug("Start On Load inner: "+n.mermaid.startOnLoad),s.initialize({startOnLoad:n.mermaid.startOnLoad})),"undefined"!=typeof n.mermaid.ganttConfig&&s.initialize({gantt:n.mermaid.ganttConfig});var c,l=function(t,e){h.innerHTML=t,"undefined"!=typeof r&&r(d),e(h)};for(i=0;i0&&(n+=r.selectorText+" { "+r.style.cssText+" }\n")}}catch(l){"undefined"!=typeof r&&i.warn('Invalid CSS selector "'+r.selectorText+'"',l)}var h="",d="";for(var f in e)e.hasOwnProperty(f)&&"undefined"!=typeof f&&("default"===f?(e["default"].styles instanceof Array&&(h+="#"+t.id.trim()+" .node>rect { "+e[f].styles.join("; ")+"; }\n"),e["default"].nodeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .node text { "+e[f].nodeLabelStyles.join("; ")+"; }\n"),e["default"].edgeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .edgeLabel text { "+e[f].edgeLabelStyles.join("; ")+"; }\n"),e["default"].clusterStyles instanceof Array&&(h+="#"+t.id.trim()+" .cluster rect { "+e[f].clusterStyles.join("; ")+"; }\n")):e[f].styles instanceof Array&&(d+="#"+t.id.trim()+" ."+f+">rect { "+e[f].styles.join("; ")+"; }\n"));if(""!==n||""!==h||""!==d){var p=document.createElement("style");p.setAttribute("type","text/css"),p.setAttribute("title","mermaid-svg-internal-css"),p.innerHTML="/* */\n",t.insertBefore(p,t.firstChild)}};r.cloneCssStyles=s},{"./logger":126}]},{},[127])(127)}); \ No newline at end of file diff --git a/dist/mermaidAPI.js b/dist/mermaidAPI.js index ea03b0c016..e6e79d6584 100644 --- a/dist/mermaidAPI.js +++ b/dist/mermaidAPI.js @@ -30724,7 +30724,7 @@ module.exports={ "chalk": "^0.5.1", "d3": "3.5.6", "dagre": "^0.7.4", - "dagre-d3": "~0.4.8", + "dagre-d3": "0.4.10", "he": "^0.5.0", "minimist": "^1.1.0", "mkdirp": "^0.5.0", @@ -31271,21 +31271,15 @@ module.exports = d3; },{"d3":4}],108:[function(require,module,exports){ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var relations = []; -var classes = undefined; +var classes; var idCache; -if (typeof Map !== 'undefined') { - classes = new Map(); -} +classes = {}; + // Functions to be run after graph rendering var funs = []; /** @@ -31296,24 +31290,24 @@ var funs = []; * @param style */ exports.addClass = function (id) { - if (typeof classes.get(id) === 'undefined') { - classes.set(id, { + if (typeof classes[id] === 'undefined') { + classes[id] = { id: id, methods: [], members: [] - }); + }; } }; exports.clear = function () { relations = []; - classes.clear(); + classes = {}; }; module.exports.getClass = function (id) { - return classes.get(id); + return classes[id]; }; -module.exports.getClasses = function (id) { +module.exports.getClasses = function () { return classes; }; @@ -31330,7 +31324,7 @@ exports.addRelation = function (relation) { }; exports.addMembers = function (className, MembersArr) { - var theClass = classes.get(className); + var theClass = classes[className]; if (typeof MembersArr === 'string') { if (MembersArr.substr(-1) === ')') { theClass.methods.push(MembersArr); @@ -31368,29 +31362,17 @@ exports.relationType = { 'use strict'; -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - -var _dagre = require('dagre'); - -var dagre = _interopRequireWildcard(_dagre); - var cd = require('./parser/classDiagram').parser; var cDDb = require('./classDb'); cd.yy = cDDb; var d3 = require('../../d3'); - +var Logger = require('../../logger'); +var dagre = require('dagre'); var log = new Logger.Log(); var idCache; -if (typeof Map !== 'undefined') { - idCache = new Map(); -} +idCache = {}; + var classCnt = 0; var conf = { dividerMargin: 10, @@ -31400,39 +31382,19 @@ var conf = { // Todo optimize var getGraphId = function getGraphId(label) { - var _iteratorNormalCompletion = true; - var _didIteratorError = false; - var _iteratorError = undefined; + var keys = Object.keys(idCache); - try { - for (var _iterator = idCache[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { - var _step$value = _slicedToArray(_step.value, 2); - - var id = _step$value[0]; - var classInfo = _step$value[1]; - - if (classInfo.label === label) { - return id; - } - } - } catch (err) { - _didIteratorError = true; - _iteratorError = err; - } finally { - try { - if (!_iteratorNormalCompletion && _iterator['return']) { - _iterator['return'](); - } - } finally { - if (_didIteratorError) { - throw _iteratorError; - } + var i; + for (i = 0; i < keys.length; i++) { + if (idCache[keys[i]].label === label) { + return keys[i]; } } return undefined; }; +window.tunk = getGraphId; /** * Setup arrow head and define the marker. The result is appended to the svg. */ @@ -31562,34 +31524,34 @@ var drawClass = function drawClass(elem, classDef) { .attr('x', conf.padding).attr('y', titleHeight + conf.dividerMargin + conf.textHeight).attr('fill', 'white').attr('class', 'classText'); var isFirst = true; - var _iteratorNormalCompletion2 = true; - var _didIteratorError2 = false; - var _iteratorError2 = undefined; + var _iteratorNormalCompletion = true; + var _didIteratorError = false; + var _iteratorError = undefined; try { - for (var _iterator2 = classDef.members[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) { - var member = _step2.value; + for (var _iterator = classDef.members[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { + var member = _step.value; addTspan(members, member, isFirst); isFirst = false; } - - //console.warn(JSON.stringify(classDef)); } catch (err) { - _didIteratorError2 = true; - _iteratorError2 = err; + _didIteratorError = true; + _iteratorError = err; } finally { try { - if (!_iteratorNormalCompletion2 && _iterator2['return']) { - _iterator2['return'](); + if (!_iteratorNormalCompletion && _iterator['return']) { + _iterator['return'](); } } finally { - if (_didIteratorError2) { - throw _iteratorError2; + if (_didIteratorError) { + throw _iteratorError; } } } + console.warn(JSON.stringify(classDef)); + var membersBox = members.node().getBBox(); var methodsLine = g.append('line') // text label for the x axis @@ -31599,28 +31561,28 @@ var drawClass = function drawClass(elem, classDef) { .attr('x', conf.padding).attr('y', titleHeight + 2 * conf.dividerMargin + membersBox.height + conf.textHeight).attr('fill', 'white').attr('class', 'classText'); isFirst = true; - var _iteratorNormalCompletion3 = true; - var _didIteratorError3 = false; - var _iteratorError3 = undefined; + var _iteratorNormalCompletion2 = true; + var _didIteratorError2 = false; + var _iteratorError2 = undefined; try { - for (var _iterator3 = classDef.methods[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { - var method = _step3.value; + for (var _iterator2 = classDef.methods[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) { + var method = _step2.value; addTspan(methods, method, isFirst); isFirst = false; } } catch (err) { - _didIteratorError3 = true; - _iteratorError3 = err; + _didIteratorError2 = true; + _iteratorError2 = err; } finally { try { - if (!_iteratorNormalCompletion3 && _iterator3['return']) { - _iterator3['return'](); + if (!_iteratorNormalCompletion2 && _iterator2['return']) { + _iterator2['return'](); } } finally { - if (_didIteratorError3) { - throw _iteratorError3; + if (_didIteratorError2) { + throw _iteratorError2; } } } @@ -31634,7 +31596,8 @@ var drawClass = function drawClass(elem, classDef) { classInfo.width = classBox.width + 2 * conf.padding; classInfo.height = classBox.height + conf.padding + 0.5 * conf.dividerMargin; - idCache.set(id, classInfo); + console.warn('setting id: ' + id + ' to ' + JSON.stringify(classInfo)); + idCache[id] = classInfo; classCnt++; return classInfo; }; @@ -31678,75 +31641,60 @@ module.exports.draw = function (text, id) { }); var classes = cDDb.getClasses(); - var _iteratorNormalCompletion4 = true; - var _didIteratorError4 = false; - var _iteratorError4 = undefined; - - try { - for (var _iterator4 = classes.values()[Symbol.iterator](), _step4; !(_iteratorNormalCompletion4 = (_step4 = _iterator4.next()).done); _iteratorNormalCompletion4 = true) { - var classDef = _step4.value; - - var node = drawClass(diagram, classDef); - // Add nodes to the graph. The first argument is the node id. The second is - // metadata about the node. In this case we're going to add labels to each of - // our nodes. - g.setNode(node.id, node); - log.info('Org height: ' + node.height); - //g.setNode("swilliams", { label: "Saul Williams", width: 160, height: 100 }); - //g.setNode("bpitt", { label: "Brad Pitt", width: 108, height: 100 }); - //g.setNode("hford", { label: "Harrison Ford", width: 168, height: 100 }); - //g.setNode("lwilson", { label: "Luke Wilson", width: 144, height: 100 }); - //g.setNode("kbacon", { label: "Kevin Bacon", width: 121, height: 100 }); - } - } catch (err) { - _didIteratorError4 = true; - _iteratorError4 = err; - } finally { - try { - if (!_iteratorNormalCompletion4 && _iterator4['return']) { - _iterator4['return'](); - } - } finally { - if (_didIteratorError4) { - throw _iteratorError4; - } - } + var keys = Object.keys(classes); + var i; + for (i = 0; i < keys.length; i++) { + var classDef = classes[keys[i]]; + var node = drawClass(diagram, classDef); + // Add nodes to the graph. The first argument is the node id. The second is + // metadata about the node. In this case we're going to add labels to each of + // our nodes. + g.setNode(node.id, node); + log.info('Org height: ' + node.height); + //g.setNode("swilliams", { label: "Saul Williams", width: 160, height: 100 }); + //g.setNode("bpitt", { label: "Brad Pitt", width: 108, height: 100 }); + //g.setNode("hford", { label: "Harrison Ford", width: 168, height: 100 }); + //g.setNode("lwilson", { label: "Luke Wilson", width: 144, height: 100 }); + //g.setNode("kbacon", { label: "Kevin Bacon", width: 121, height: 100 }); } var relations = cDDb.getRelations(); var i = 0; - var _iteratorNormalCompletion5 = true; - var _didIteratorError5 = false; - var _iteratorError5 = undefined; + var _iteratorNormalCompletion3 = true; + var _didIteratorError3 = false; + var _iteratorError3 = undefined; try { - for (var _iterator5 = relations[Symbol.iterator](), _step5; !(_iteratorNormalCompletion5 = (_step5 = _iterator5.next()).done); _iteratorNormalCompletion5 = true) { - var relation = _step5.value; + for (var _iterator3 = relations[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { + var relation = _step3.value; i = i + 1; + log.info('tjoho' + getGraphId(relation.id1) + getGraphId(relation.id2) + JSON.stringify(relation)); g.setEdge(getGraphId(relation.id1), getGraphId(relation.id2), { relation: relation }); } } catch (err) { - _didIteratorError5 = true; - _iteratorError5 = err; + _didIteratorError3 = true; + _iteratorError3 = err; } finally { try { - if (!_iteratorNormalCompletion5 && _iterator5['return']) { - _iterator5['return'](); + if (!_iteratorNormalCompletion3 && _iterator3['return']) { + _iterator3['return'](); } } finally { - if (_didIteratorError5) { - throw _iteratorError5; + if (_didIteratorError3) { + throw _iteratorError3; } } } dagre.layout(g); g.nodes().forEach(function (v) { - log.debug('Node ' + v + ': ' + JSON.stringify(g.node(v))); - d3.select('#' + v).attr('transform', 'translate(' + (g.node(v).x - g.node(v).width / 2) + ',' + (g.node(v).y - g.node(v).height / 2) + ' )'); - //d3.select('#' +v +' rect').attr('x',(g.node(v).x-(g.node(v).width/2))) - //.attr('y',(g.node(v).y-(g.node(v).height/2))); + if (typeof v !== 'undefined') { + log.debug('Node ' + v + ': ' + JSON.stringify(g.node(v))); + d3.select('#' + v).attr('transform', 'translate(' + (g.node(v).x - g.node(v).width / 2) + ',' + (g.node(v).y - g.node(v).height / 2) + ' )'); + //d3.select('#' +v +' rect').attr('x',(g.node(v).x-(g.node(v).width/2))) + //.attr('y',(g.node(v).y-(g.node(v).height/2))); + } }); g.edges().forEach(function (e) { log.debug('Edge ' + e.v + ' -> ' + e.w + ': ' + JSON.stringify(g.edge(e))); @@ -32580,12 +32528,7 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var message = ''; @@ -32619,16 +32562,10 @@ exports.parseError = function (err, hash) { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var db = require('./exampleDb'); var exampleParser = require('./parser/example.js'); var d3 = require('../../d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); /** @@ -33312,12 +33249,7 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { /* global window */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var dagreD3; @@ -33343,18 +33275,12 @@ module.exports = dagreD3; */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var graph = require('./graphDb'); var flow = require('./parser/flow'); var dot = require('./parser/dot'); var d3 = require('../../d3'); var dagreD3 = require('./dagre-d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var conf = {}; @@ -33785,12 +33711,7 @@ exports.draw = function (text, id, isDot) { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var d3 = require('../../d3'); @@ -36120,14 +36041,8 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var moment = require('moment'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var dateFormat = ''; @@ -38356,17 +38271,11 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var actors = {}; var actorKeys = []; var messages = []; var notes = []; - +var Logger = require('../../logger'); var log = new Logger.Log(); exports.addActor = function (id, name, description) { @@ -38503,17 +38412,11 @@ exports.apply = function (param) { 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var sq = require('./parser/sequenceDiagram').parser; sq.yy = require('./sequenceDb'); var svgDraw = require('./svgDraw'); var d3 = require('../../d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var conf = { @@ -39120,10 +39023,6 @@ exports.getNoteRect = function () { 'use strict'; -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } - var LEVELS = { debug: 1, info: 2, @@ -39167,59 +39066,45 @@ function formatTime(timestamp) { return t; } -var Log = (function () { - function Log(level) { - _classCallCheck(this, Log); - - this.level = level; - } +function Log(level) { + this.level = level; - _createClass(Log, [{ - key: 'log', - value: function log(str, level) { - var logLevel = this.level; - if (typeof logLevel === 'undefined') { - logLevel = defaultLevel; - } - if (logLevel <= level) { - if (typeof console !== 'undefined') { + this.log = function (str, level) { + var logLevel = this.level; + if (typeof logLevel === 'undefined') { + logLevel = defaultLevel; + } + if (logLevel <= level) { + if (typeof console !== 'undefined') { + //eslint-disable-line no-console + if (typeof console.log !== 'undefined') { //eslint-disable-line no-console - if (typeof console.log !== 'undefined') { - //eslint-disable-line no-console - return console.log('[' + formatTime(new Date()) + '] ' + str); //eslint-disable-line no-console - } + return console.log('[' + formatTime(new Date()) + '] ' + str); //eslint-disable-line no-console } } } - }, { - key: 'trace', - value: function trace(str) { - this.log(str, LEVELS.trace); - } - }, { - key: 'debug', - value: function debug(str) { - this.log(str, LEVELS.debug); - } - }, { - key: 'info', - value: function info(str) { - this.log(str, LEVELS.info); - } - }, { - key: 'warn', - value: function warn(str) { - this.log(str, LEVELS.warn); - } - }, { - key: 'error', - value: function error(str) { - this.log(str, LEVELS.error); - } - }]); + }; - return Log; -})(); + this.trace = function (str) { + this.log(str, LEVELS.trace); + }; + + this.debug = function (str) { + this.log(str, LEVELS.debug); + }; + + this.info = function (str) { + this.log(str, LEVELS.info); + }; + + this.warn = function (str) { + this.log(str, LEVELS.warn); + }; + + this.error = function (str) { + this.log(str, LEVELS.error); + }; +} exports.Log = Log; @@ -39240,12 +39125,7 @@ exports.Log = Log; */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('./logger'); var log = new Logger.Log(); var graph = require('./diagrams/flowchart/graphDb'); @@ -39654,6 +39534,8 @@ var render = function render(id, txt, cb, container) { var svgCode = d3.select('#d' + id).node().innerHTML.replace(/url\(#arrowhead/g, 'url(' + url + '#arrowhead', 'g'); svgCode = exports.decodeEntities(svgCode); + console.warn('here'); + //console.warn('mermaid decode: '); //console.warn(svgCode); //var he = require('he'); @@ -39661,13 +39543,15 @@ var render = function render(id, txt, cb, container) { if (typeof cb !== 'undefined') { cb(svgCode, graph.bindFunctions); } else { - log.warn('CB = undefined'); + log.warn('CB = undefined!'); } var node = d3.select('#d' + id).node(); if (node !== null && typeof node.remove === 'function') { d3.select('#d' + id).node().remove(); } + + return svgCode; }; exports.render = function (id, text, cb, containerElement) { @@ -39675,7 +39559,7 @@ exports.render = function (id, text, cb, containerElement) { // Todo handle rendering serverside using phantomjs } else { // In browser - render(id, text, cb, containerElement); + return render(id, text, cb, containerElement); } }; @@ -39739,16 +39623,7 @@ global.mermaidAPI = { */ 'use strict'; -Object.defineProperty(exports, '__esModule', { - value: true -}); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('./logger'); var log = new Logger.Log(); /** diff --git a/dist/mermaidAPI.min.js b/dist/mermaidAPI.min.js index 98010d91a1..7afbecd114 100644 --- a/dist/mermaidAPI.min.js +++ b/dist/mermaidAPI.min.js @@ -1,22 +1,21 @@ -!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.mermaidAPI=t()}}(function(){var define,module,exports;return function t(e,n,r){function i(u,o){if(!n[u]){if(!e[u]){var s="function"==typeof require&&require;if(!o&&s)return s(u,!0);if(a)return a(u,!0);var c=new Error("Cannot find module '"+u+"'");throw c.code="MODULE_NOT_FOUND",c}var l=n[u]={exports:{}};e[u][0].call(l.exports,function(t){var n=e[u][1][t];return i(n?n:t)},l,l.exports,t,e,n,r)}return n[u].exports}for(var a="function"==typeof require&&require,u=0;u=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=-1&&!i;a--){var u=a>=0?arguments[a]:t.cwd();if("string"!=typeof u)throw new TypeError("Arguments to path.resolve must be strings");u&&(n=u+"/"+n,i="/"===u.charAt(0))}return n=e(r(n.split("/"),function(t){return!!t}),!i).join("/"),(i?"/":"")+n||"."},n.normalize=function(t){var i=n.isAbsolute(t),a="/"===u(t,-1);return t=e(r(t.split("/"),function(t){return!!t}),!i).join("/"),t||i||(t="."),t&&a&&(t+="/"),(i?"/":"")+t},n.isAbsolute=function(t){return"/"===t.charAt(0)},n.join=function(){var t=Array.prototype.slice.call(arguments,0);return n.normalize(r(t,function(t){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},n.relative=function(t,e){function r(t){for(var e=0;e=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=n.resolve(t).substr(1),e=n.resolve(e).substr(1);for(var i=r(t.split("/")),a=r(e.split("/")),u=Math.min(i.length,a.length),o=u,s=0;u>s;s++)if(i[s]!==a[s]){o=s;break}for(var c=[],s=o;se&&(e=t.length+e),t.substr(e,n)}}).call(this,t("_process"))},{_process:3}],3:[function(t,e){function n(){}var r=e.exports={};r.nextTick=function(){var t="undefined"!=typeof window&&window.setImmediate,e="undefined"!=typeof window&&window.MutationObserver,n="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(t)return function(t){return window.setImmediate(t)};var r=[];if(e){var i=document.createElement("div"),a=new MutationObserver(function(){var t=r.slice();r.length=0,t.forEach(function(t){t()})});return a.observe(i,{attributes:!0}),function(t){r.length||i.setAttribute("yes","no"),r.push(t)}}return n?(window.addEventListener("message",function(t){var e=t.source;if((e===window||null===e)&&"process-tick"===t.data&&(t.stopPropagation(),r.length>0)){var n=r.shift();n()}},!0),function(t){r.push(t),window.postMessage("process-tick","*")}):function(t){setTimeout(t,0)}}(),r.title="browser",r.browser=!0,r.env={},r.argv=[],r.on=n,r.addListener=n,r.once=n,r.off=n,r.removeListener=n,r.removeAllListeners=n,r.emit=n,r.binding=function(){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(){throw new Error("process.chdir is not supported")}},{}],4:[function(t,e){!function(){function t(t){return t&&(t.ownerDocument||t.document||t).documentElement}function n(t){return t&&(t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView)}function r(t,e){return e>t?-1:t>e?1:t>=e?0:0/0}function i(t){return null===t?0/0:+t}function a(t){return!isNaN(t)}function u(t){return{left:function(e,n,r,i){for(arguments.length<3&&(r=0),arguments.length<4&&(i=e.length);i>r;){var a=r+i>>>1;t(e[a],n)<0?r=a+1:i=a}return r},right:function(e,n,r,i){for(arguments.length<3&&(r=0),arguments.length<4&&(i=e.length);i>r;){var a=r+i>>>1;t(e[a],n)>0?i=a:r=a+1}return r}}}function o(t){return t.length}function s(t){for(var e=1;t*e%1;)e*=10;return e}function c(t,e){for(var n in e)Object.defineProperty(t.prototype,n,{value:e[n],enumerable:!1})}function l(){this._=Object.create(null)}function h(t){return(t+="")===gu||t[0]===yu?yu+t:t}function f(t){return(t+="")[0]===yu?t.slice(1):t}function d(t){return h(t)in this._}function p(t){return(t=h(t))in this._&&delete this._[t]}function g(){var t=[];for(var e in this._)t.push(f(e));return t}function y(){var t=0;for(var e in this._)++t;return t}function m(){for(var t in this._)return!1;return!0}function v(){this._=Object.create(null)}function _(t){return t}function b(t,e,n){return function(){var r=n.apply(e,arguments);return r===e?t:r}}function x(t,e){if(e in t)return e;e=e.charAt(0).toUpperCase()+e.slice(1);for(var n=0,r=mu.length;r>n;++n){var i=mu[n]+e;if(i in t)return i}}function w(){}function A(){}function k(t){function e(){for(var e,r=n,i=-1,a=r.length;++in;n++)for(var i,a=t[n],u=0,o=a.length;o>u;u++)(i=a[u])&&e(i,u,n);return t}function W(t){return _u(t,Eu),t}function G(t){var e,n;return function(r,i,a){var u,o=t[a].update,s=o.length;for(a!=n&&(n=a,e=0),i>=e&&(e=i+1);!(u=o[e])&&++e0&&(t=t.slice(0,o));var c=Mu.get(t);return c&&(t=c,s=X),o?e?i:r:e?w:a}function V(t,e){return function(n){var r=nu.event;nu.event=n,e[0]=this.__data__;try{t.apply(this,e)}finally{nu.event=r}}}function X(t,e){var n=V(t,e);return function(t){var e=this,r=t.relatedTarget;r&&(r===e||8&r.compareDocumentPosition(e))||n.call(e,t)}}function Z(e){var r=".dragsuppress-"+ ++Cu,i="click"+r,a=nu.select(n(e)).on("touchmove"+r,E).on("dragstart"+r,E).on("selectstart"+r,E);if(null==Du&&(Du="onselectstart"in e?!1:x(e.style,"userSelect")),Du){var u=t(e).style,o=u[Du];u[Du]="none"}return function(t){if(a.on(r,null),Du&&(u[Du]=o),t){var e=function(){a.on(i,null)};a.on(i,function(){E(),e()},!0),setTimeout(e,0)}}}function K(t,e){e.changedTouches&&(e=e.changedTouches[0]);var r=t.ownerSVGElement||t;if(r.createSVGPoint){var i=r.createSVGPoint();if(0>Su){var a=n(t);if(a.scrollX||a.scrollY){r=nu.select("body").append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important");var u=r[0][0].getScreenCTM();Su=!(u.f||u.e),r.remove()}}return Su?(i.x=e.pageX,i.y=e.pageY):(i.x=e.clientX,i.y=e.clientY),i=i.matrixTransform(t.getScreenCTM().inverse()),[i.x,i.y]}var o=t.getBoundingClientRect();return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}function Q(){return nu.event.changedTouches[0].identifier}function J(t){return t>0?1:0>t?-1:0}function tt(t,e,n){return(e[0]-t[0])*(n[1]-t[1])-(e[1]-t[1])*(n[0]-t[0])}function et(t){return t>1?0:-1>t?Bu:Math.acos(t)}function nt(t){return t>1?Iu:-1>t?-Iu:Math.asin(t)}function rt(t){return((t=Math.exp(t))-1/t)/2}function it(t){return((t=Math.exp(t))+1/t)/2}function at(t){return((t=Math.exp(2*t))-1)/(t+1)}function ut(t){return(t=Math.sin(t/2))*t}function ot(){}function st(t,e,n){return this instanceof st?(this.h=+t,this.s=+e,void(this.l=+n)):arguments.length<2?t instanceof st?new st(t.h,t.s,t.l):wt(""+t,At,st):new st(t,e,n)}function ct(t,e,n){function r(t){return t>360?t-=360:0>t&&(t+=360),60>t?a+(u-a)*t/60:180>t?u:240>t?a+(u-a)*(240-t)/60:a}function i(t){return Math.round(255*r(t))}var a,u;return t=isNaN(t)?0:(t%=360)<0?t+360:t,e=isNaN(e)?0:0>e?0:e>1?1:e,n=0>n?0:n>1?1:n,u=.5>=n?n*(1+e):n+e-n*e,a=2*n-u,new vt(i(t+120),i(t),i(t-120))}function lt(t,e,n){return this instanceof lt?(this.h=+t,this.c=+e,void(this.l=+n)):arguments.length<2?t instanceof lt?new lt(t.h,t.c,t.l):t instanceof ft?pt(t.l,t.a,t.b):pt((t=kt((t=nu.rgb(t)).r,t.g,t.b)).l,t.a,t.b):new lt(t,e,n)}function ht(t,e,n){return isNaN(t)&&(t=0),isNaN(e)&&(e=0),new ft(n,Math.cos(t*=Nu)*e,Math.sin(t)*e)}function ft(t,e,n){return this instanceof ft?(this.l=+t,this.a=+e,void(this.b=+n)):arguments.length<2?t instanceof ft?new ft(t.l,t.a,t.b):t instanceof lt?ht(t.h,t.c,t.l):kt((t=vt(t)).r,t.g,t.b):new ft(t,e,n)}function dt(t,e,n){var r=(t+16)/116,i=r+e/500,a=r-n/200;return i=gt(i)*Hu,r=gt(r)*Vu,a=gt(a)*Xu,new vt(mt(3.2404542*i-1.5371385*r-.4985314*a),mt(-.969266*i+1.8760108*r+.041556*a),mt(.0556434*i-.2040259*r+1.0572252*a))}function pt(t,e,n){return t>0?new lt(Math.atan2(n,e)*Pu,Math.sqrt(e*e+n*n),t):new lt(0/0,0/0,t)}function gt(t){return t>.206893034?t*t*t:(t-4/29)/7.787037}function yt(t){return t>.008856?Math.pow(t,1/3):7.787037*t+4/29}function mt(t){return Math.round(255*(.00304>=t?12.92*t:1.055*Math.pow(t,1/2.4)-.055))}function vt(t,e,n){return this instanceof vt?(this.r=~~t,this.g=~~e,void(this.b=~~n)):arguments.length<2?t instanceof vt?new vt(t.r,t.g,t.b):wt(""+t,vt,ct):new vt(t,e,n)}function _t(t){return new vt(t>>16,t>>8&255,255&t)}function bt(t){return _t(t)+""}function xt(t){return 16>t?"0"+Math.max(0,t).toString(16):Math.min(255,t).toString(16)}function wt(t,e,n){t=t.toLowerCase();var r,i,a,u=0,o=0,s=0;if(r=/([a-z]+)\((.*)\)/.exec(t))switch(i=r[2].split(","),r[1]){case"hsl":return n(parseFloat(i[0]),parseFloat(i[1])/100,parseFloat(i[2])/100);case"rgb":return e(Mt(i[0]),Mt(i[1]),Mt(i[2]))}return(a=Qu.get(t))?e(a.r,a.g,a.b):(null==t||"#"!==t.charAt(0)||isNaN(a=parseInt(t.slice(1),16))||(4===t.length?(u=(3840&a)>>4,u=u>>4|u,o=240&a,o=o>>4|o,s=15&a,s=s<<4|s):7===t.length&&(u=(16711680&a)>>16,o=(65280&a)>>8,s=255&a)),e(u,o,s))}function At(t,e,n){var r,i,a=Math.min(t/=255,e/=255,n/=255),u=Math.max(t,e,n),o=u-a,s=(u+a)/2;return o?(i=.5>s?o/(u+a):o/(2-u-a),r=t==u?(e-n)/o+(n>e?6:0):e==u?(n-t)/o+2:(t-e)/o+4,r*=60):(r=0/0,i=s>0&&1>s?0:r),new st(r,i,s)}function kt(t,e,n){t=Et(t),e=Et(e),n=Et(n);var r=yt((.4124564*t+.3575761*e+.1804375*n)/Hu),i=yt((.2126729*t+.7151522*e+.072175*n)/Vu),a=yt((.0193339*t+.119192*e+.9503041*n)/Xu);return ft(116*i-16,500*(r-i),200*(i-a))}function Et(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Mt(t){var e=parseFloat(t);return"%"===t.charAt(t.length-1)?Math.round(2.55*e):e}function Dt(t){return"function"==typeof t?t:function(){return t}}function Ct(t){return function(e,n,r){return 2===arguments.length&&"function"==typeof n&&(r=n,n=null),St(e,n,t,r)}}function St(t,e,n,r){function i(){var t,e=s.status;if(!e&&Ft(s)||e>=200&&300>e||304===e){try{t=n.call(a,s)}catch(r){return void u.error.call(a,r)}u.load.call(a,t)}else u.error.call(a,s)}var a={},u=nu.dispatch("beforesend","progress","load","error"),o={},s=new XMLHttpRequest,c=null;return!this.XDomainRequest||"withCredentials"in s||!/^(http(s)?:)?\/\//.test(t)||(s=new XDomainRequest),"onload"in s?s.onload=s.onerror=i:s.onreadystatechange=function(){s.readyState>3&&i()},s.onprogress=function(t){var e=nu.event;nu.event=t;try{u.progress.call(a,s)}finally{nu.event=e}},a.header=function(t,e){return t=(t+"").toLowerCase(),arguments.length<2?o[t]:(null==e?delete o[t]:o[t]=e+"",a)},a.mimeType=function(t){return arguments.length?(e=null==t?null:t+"",a):e},a.responseType=function(t){return arguments.length?(c=t,a):c},a.response=function(t){return n=t,a},["get","post"].forEach(function(t){a[t]=function(){return a.send.apply(a,[t].concat(iu(arguments)))}}),a.send=function(n,r,i){if(2===arguments.length&&"function"==typeof r&&(i=r,r=null),s.open(n,t,!0),null==e||"accept"in o||(o.accept=e+",*/*"),s.setRequestHeader)for(var l in o)s.setRequestHeader(l,o[l]);return null!=e&&s.overrideMimeType&&s.overrideMimeType(e),null!=c&&(s.responseType=c),null!=i&&a.on("error",i).on("load",function(t){i(null,t)}),u.beforesend.call(a,s),s.send(null==r?null:r),a},a.abort=function(){return s.abort(),a},nu.rebind(a,u,"on"),null==r?a:a.get(Tt(r))}function Tt(t){return 1===t.length?function(e,n){t(null==e?n:null)}:t}function Ft(t){var e=t.responseType;return e&&"text"!==e?t.response:t.responseText}function Bt(){var t=Lt(),e=Ot()-t;e>24?(isFinite(e)&&(clearTimeout(no),no=setTimeout(Bt,e)),eo=0):(eo=1,io(Bt))}function Lt(){var t=Date.now();for(ro=Ju;ro;)t>=ro.t&&(ro.f=ro.c(t-ro.t)),ro=ro.n;return t}function Ot(){for(var t,e=Ju,n=1/0;e;)e.f?e=t?t.n=e.n:Ju=e.n:(e.t8?function(t){return t/n}:function(t){return t*n},symbol:t}}function Pt(t){var e=t.decimal,n=t.thousands,r=t.grouping,i=t.currency,a=r&&n?function(t,e){for(var i=t.length,a=[],u=0,o=r[0],s=0;i>0&&o>0&&(s+o+1>e&&(o=Math.max(1,e-s)),a.push(t.substring(i-=o,i+o)),!((s+=o+1)>e));)o=r[u=(u+1)%r.length];return a.reverse().join(n)}:_;return function(t){var n=uo.exec(t),r=n[1]||" ",u=n[2]||">",o=n[3]||"-",s=n[4]||"",c=n[5],l=+n[6],h=n[7],f=n[8],d=n[9],p=1,g="",y="",m=!1,v=!0;switch(f&&(f=+f.substring(1)),(c||"0"===r&&"="===u)&&(c=r="0",u="="),d){case"n":h=!0,d="g";break;case"%":p=100,y="%",d="f";break;case"p":p=100,y="%",d="r";break;case"b":case"o":case"x":case"X":"#"===s&&(g="0"+d.toLowerCase());case"c":v=!1;case"d":m=!0,f=0;break;case"s":p=-1,d="r"}"$"===s&&(g=i[0],y=i[1]),"r"!=d||f||(d="g"),null!=f&&("g"==d?f=Math.max(1,Math.min(21,f)):("e"==d||"f"==d)&&(f=Math.max(0,Math.min(20,f)))),d=oo.get(d)||Rt;var _=c&&h;return function(t){var n=y;if(m&&t%1)return"";var i=0>t||0===t&&0>1/t?(t=-t,"-"):"-"===o?"":o;if(0>p){var s=nu.formatPrefix(t,f);t=s.scale(t),n=s.symbol+y}else t*=p;t=d(t,f);var b,x,w=t.lastIndexOf(".");if(0>w){var A=v?t.lastIndexOf("e"):-1;0>A?(b=t,x=""):(b=t.substring(0,A),x=t.substring(A))}else b=t.substring(0,w),x=e+t.substring(w+1);!c&&h&&(b=a(b,1/0));var k=g.length+b.length+x.length+(_?0:i.length),E=l>k?new Array(k=l-k+1).join(r):"";return _&&(b=a(E+b,E.length?l-x.length:1/0)),i+=g,t=b+x,("<"===u?i+t+E:">"===u?E+i+t:"^"===u?E.substring(0,k>>=1)+i+t+E.substring(k):i+(_?t:E+t))+n}}}function Rt(t){return t+""}function jt(){this._=new Date(arguments.length>1?Date.UTC.apply(this,arguments):arguments[0])}function Yt(t,e,n){function r(e){var n=t(e),r=a(n,1);return r-e>e-n?n:r}function i(n){return e(n=t(new co(n-1)),1),n}function a(t,n){return e(t=new co(+t),n),t}function u(t,r,a){var u=i(t),o=[];if(a>1)for(;r>u;)n(u)%a||o.push(new Date(+u)),e(u,1);else for(;r>u;)o.push(new Date(+u)),e(u,1);return o}function o(t,e,n){try{co=jt;var r=new jt;return r._=t,u(r,e,n)}finally{co=Date}}t.floor=t,t.round=r,t.ceil=i,t.offset=a,t.range=u;var s=t.utc=Ut(t);return s.floor=s,s.round=Ut(r),s.ceil=Ut(i),s.offset=Ut(a),s.range=o,t}function Ut(t){return function(e,n){try{co=jt;var r=new jt;return r._=e,t(r,n)._}finally{co=Date}}}function $t(t){function e(t){function e(e){for(var n,i,a,u=[],o=-1,s=0;++oo;){if(r>=c)return-1;if(i=e.charCodeAt(o++),37===i){if(u=e.charAt(o++),a=S[u in ho?e.charAt(o++):u],!a||(r=a(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}function r(t,e,n){w.lastIndex=0;var r=w.exec(e.slice(n));return r?(t.w=A.get(r[0].toLowerCase()),n+r[0].length):-1}function i(t,e,n){b.lastIndex=0;var r=b.exec(e.slice(n));return r?(t.w=x.get(r[0].toLowerCase()),n+r[0].length):-1}function a(t,e,n){M.lastIndex=0;var r=M.exec(e.slice(n));return r?(t.m=D.get(r[0].toLowerCase()),n+r[0].length):-1}function u(t,e,n){k.lastIndex=0;var r=k.exec(e.slice(n));return r?(t.m=E.get(r[0].toLowerCase()),n+r[0].length):-1}function o(t,e,r){return n(t,C.c.toString(),e,r)}function s(t,e,r){return n(t,C.x.toString(),e,r)}function c(t,e,r){return n(t,C.X.toString(),e,r)}function l(t,e,n){var r=_.get(e.slice(n,n+=2).toLowerCase());return null==r?-1:(t.p=r,n)}var h=t.dateTime,f=t.date,d=t.time,p=t.periods,g=t.days,y=t.shortDays,m=t.months,v=t.shortMonths;e.utc=function(t){function n(t){try{co=jt;var e=new co;return e._=t,r(e)}finally{co=Date}}var r=e(t);return n.parse=function(t){try{co=jt;var e=r.parse(t);return e&&e._}finally{co=Date}},n.toString=r.toString,n},e.multi=e.utc.multi=se;var _=nu.map(),b=qt(g),x=Wt(g),w=qt(y),A=Wt(y),k=qt(m),E=Wt(m),M=qt(v),D=Wt(v);p.forEach(function(t,e){_.set(t.toLowerCase(),e)});var C={a:function(t){return y[t.getDay()]},A:function(t){return g[t.getDay()]},b:function(t){return v[t.getMonth()]},B:function(t){return m[t.getMonth()]},c:e(h),d:function(t,e){return zt(t.getDate(),e,2)},e:function(t,e){return zt(t.getDate(),e,2)},H:function(t,e){return zt(t.getHours(),e,2)},I:function(t,e){return zt(t.getHours()%12||12,e,2)},j:function(t,e){return zt(1+so.dayOfYear(t),e,3)},L:function(t,e){return zt(t.getMilliseconds(),e,3)},m:function(t,e){return zt(t.getMonth()+1,e,2)},M:function(t,e){return zt(t.getMinutes(),e,2)},p:function(t){return p[+(t.getHours()>=12)]},S:function(t,e){return zt(t.getSeconds(),e,2)},U:function(t,e){return zt(so.sundayOfYear(t),e,2)},w:function(t){return t.getDay()},W:function(t,e){return zt(so.mondayOfYear(t),e,2)},x:e(f),X:e(d),y:function(t,e){return zt(t.getFullYear()%100,e,2)},Y:function(t,e){return zt(t.getFullYear()%1e4,e,4)},Z:ue,"%":function(){return"%"}},S={a:r,A:i,b:a,B:u,c:o,d:te,e:te,H:ne,I:ne,j:ee,L:ae,m:Jt,M:re,p:l,S:ie,U:Ht,w:Gt,W:Vt,x:s,X:c,y:Zt,Y:Xt,Z:Kt,"%":oe};return e}function zt(t,e,n){var r=0>t?"-":"",i=(r?-t:t)+"",a=i.length;return r+(n>a?new Array(n-a+1).join(e)+i:i)}function qt(t){return new RegExp("^(?:"+t.map(nu.requote).join("|")+")","i")}function Wt(t){for(var e=new l,n=-1,r=t.length;++n68?1900:2e3)}function Jt(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function te(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function ee(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+3));return r?(t.j=+r[0],n+r[0].length):-1}function ne(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function re(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function ie(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function ae(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function ue(t){var e=t.getTimezoneOffset(),n=e>0?"-":"+",r=pu(e)/60|0,i=pu(e)%60;return n+zt(r,"0",2)+zt(i,"0",2)}function oe(t,e,n){po.lastIndex=0;var r=po.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function se(t){for(var e=t.length,n=-1;++n=0?1:-1,o=u*n,s=Math.cos(e),c=Math.sin(e),l=a*c,h=i*s+l*Math.cos(o),f=l*u*Math.sin(o);bo.add(Math.atan2(f,h)),r=t,i=s,a=c}var e,n,r,i,a;xo.point=function(u,o){xo.point=t,r=(e=u)*Nu,i=Math.cos(o=(n=o)*Nu/2+Bu/4),a=Math.sin(o)},xo.lineEnd=function(){t(e,n)}}function ge(t){var e=t[0],n=t[1],r=Math.cos(n);return[r*Math.cos(e),r*Math.sin(e),Math.sin(n)]}function ye(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function me(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 ve(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function _e(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function be(t){var e=Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}function xe(t){return[Math.atan2(t[1],t[0]),nt(t[2])]}function we(t,e){return pu(t[0]-e[0])o;++o)i.point((n=t[o])[0],n[1]);return void i.lineEnd()}var s=new Be(n,t,null,!0),c=new Be(n,null,s,!1);s.o=c,a.push(s),u.push(c),s=new Be(r,t,null,!1),c=new Be(r,null,s,!0),s.o=c,a.push(s),u.push(c)}}),u.sort(e),Fe(a),Fe(u),a.length){for(var o=0,s=n,c=u.length;c>o;++o)u[o].e=s=!s;for(var l,h,f=a[0];;){for(var d=f,p=!0;d.v;)if((d=d.n)===f)return;l=d.z,i.lineStart();do{if(d.v=d.o.v=!0,d.e){if(p)for(var o=0,c=l.length;c>o;++o)i.point((h=l[o])[0],h[1]);else r(d.x,d.n.x,1,i);d=d.n}else{if(p){l=d.p.z;for(var o=l.length-1;o>=0;--o)i.point((h=l[o])[0],h[1])}else r(d.x,d.p.x,-1,i);d=d.p}d=d.o,l=d.z,p=!p}while(!d.v);i.lineEnd()}}}function Fe(t){if(e=t.length){for(var e,n,r=0,i=t[0];++r0){for(x||(a.polygonStart(),x=!0),a.lineStart();++u1&&2&e&&n.push(n.pop().concat(n.shift())),d.push(n.filter(Oe))}var d,p,g,y=e(a),m=i.invert(r[0],r[1]),v={point:u,lineStart:s,lineEnd:c,polygonStart:function(){v.point=l,v.lineStart=h,v.lineEnd=f,d=[],p=[]},polygonEnd:function(){v.point=u,v.lineStart=s,v.lineEnd=c,d=nu.merge(d);var t=Ye(m,p);d.length?(x||(a.polygonStart(),x=!0),Te(d,Ne,t,n,a)):t&&(x||(a.polygonStart(),x=!0),a.lineStart(),n(null,null,1,a),a.lineEnd()),x&&(a.polygonEnd(),x=!1),d=p=null},sphere:function(){a.polygonStart(),a.lineStart(),n(null,null,1,a),a.lineEnd(),a.polygonEnd()}},_=Ie(),b=e(_),x=!1;return v}}function Oe(t){return t.length>1}function Ie(){var t,e=[];return{lineStart:function(){e.push(t=[])},point:function(e,n){t.push([e,n])},lineEnd:w,buffer:function(){var n=e;return e=[],t=null,n},rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))}}}function Ne(t,e){return((t=t.x)[0]<0?t[1]-Iu-Tu:Iu-t[1])-((e=e.x)[0]<0?e[1]-Iu-Tu:Iu-e[1])}function Pe(t){var e,n=0/0,r=0/0,i=0/0;return{lineStart:function(){t.lineStart(),e=1},point:function(a,u){var o=a>0?Bu:-Bu,s=pu(a-n);pu(s-Bu)0?Iu:-Iu),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(o,r),t.point(a,r),e=0):i!==o&&s>=Bu&&(pu(n-i)Tu?Math.atan((Math.sin(e)*(a=Math.cos(r))*Math.sin(n)-Math.sin(r)*(i=Math.cos(e))*Math.sin(t))/(i*a*u)):(e+r)/2}function je(t,e,n,r){var i;if(null==t)i=n*Iu,r.point(-Bu,i),r.point(0,i),r.point(Bu,i),r.point(Bu,0),r.point(Bu,-i),r.point(0,-i),r.point(-Bu,-i),r.point(-Bu,0),r.point(-Bu,i);else if(pu(t[0]-e[0])>Tu){var a=t[0]o;++o){var c=e[o],l=c.length;if(l)for(var h=c[0],f=h[0],d=h[1]/2+Bu/4,p=Math.sin(d),g=Math.cos(d),y=1;;){y===l&&(y=0),t=c[y];var m=t[0],v=t[1]/2+Bu/4,_=Math.sin(v),b=Math.cos(v),x=m-f,w=x>=0?1:-1,A=w*x,k=A>Bu,E=p*_;if(bo.add(Math.atan2(E*w*Math.sin(A),g*b+E*Math.cos(A))),a+=k?x+w*Lu:x,k^f>=n^m>=n){var M=me(ge(h),ge(t));be(M);var D=me(i,M);be(D);var C=(k^x>=0?-1:1)*nt(D[2]);(r>C||r===C&&(M[0]||M[1]))&&(u+=k^x>=0?1:-1)}if(!y++)break;f=m,p=_,g=b,h=t}}return(-Tu>a||Tu>a&&0>bo)^1&u}function Ue(t){function e(t,e){return Math.cos(t)*Math.cos(e)>a}function n(t){var n,a,s,c,l;return{lineStart:function(){c=s=!1,l=1},point:function(h,f){var d,p=[h,f],g=e(h,f),y=u?g?0:i(h,f):g?i(h+(0>h?Bu:-Bu),f):0;if(!n&&(c=s=g)&&t.lineStart(),g!==s&&(d=r(n,p),(we(n,d)||we(p,d))&&(p[0]+=Tu,p[1]+=Tu,g=e(p[0],p[1]))),g!==s)l=0,g?(t.lineStart(),d=r(p,n),t.point(d[0],d[1])):(d=r(n,p),t.point(d[0],d[1]),t.lineEnd()),n=d;else if(o&&n&&u^g){var m;y&a||!(m=r(p,n,!0))||(l=0,u?(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])))}!g||n&&we(n,p)||t.point(p[0],p[1]),n=p,s=g,a=y},lineEnd:function(){s&&t.lineEnd(),n=null},clean:function(){return l|(c&&s)<<1}}}function r(t,e,n){var r=ge(t),i=ge(e),u=[1,0,0],o=me(r,i),s=ye(o,o),c=o[0],l=s-c*c;if(!l)return!n&&t;var h=a*s/l,f=-a*c/l,d=me(u,o),p=_e(u,h),g=_e(o,f);ve(p,g);var y=d,m=ye(p,y),v=ye(y,y),_=m*m-v*(ye(p,p)-1);if(!(0>_)){var b=Math.sqrt(_),x=_e(y,(-m-b)/v);if(ve(x,p),x=xe(x),!n)return x;var w,A=t[0],k=e[0],E=t[1],M=e[1];A>k&&(w=A,A=k,k=w);var D=k-A,C=pu(D-Bu)D;if(!C&&E>M&&(w=E,E=M,M=w),S?C?E+M>0^x[1]<(pu(x[0]-A)Bu^(A<=x[0]&&x[0]<=k)){var T=_e(y,(-m+b)/v);return ve(T,p),[x,xe(T)]}}}function i(e,n){var r=u?t:Bu-t,i=0;return-r>e?i|=1:e>r&&(i|=2),-r>n?i|=4:n>r&&(i|=8),i}var a=Math.cos(t),u=a>0,o=pu(a)>Tu,s=gn(t,6*Nu);return Le(e,n,s,u?[0,-t]:[-Bu,t-Bu])}function $e(t,e,n,r){return function(i){var a,u=i.a,o=i.b,s=u.x,c=u.y,l=o.x,h=o.y,f=0,d=1,p=l-s,g=h-c;if(a=t-s,p||!(a>0)){if(a/=p,0>p){if(f>a)return;d>a&&(d=a)}else if(p>0){if(a>d)return;a>f&&(f=a)}if(a=n-s,p||!(0>a)){if(a/=p,0>p){if(a>d)return;a>f&&(f=a)}else if(p>0){if(f>a)return;d>a&&(d=a)}if(a=e-c,g||!(a>0)){if(a/=g,0>g){if(f>a)return;d>a&&(d=a)}else if(g>0){if(a>d)return;a>f&&(f=a)}if(a=r-c,g||!(0>a)){if(a/=g,0>g){if(a>d)return;a>f&&(f=a)}else if(g>0){if(f>a)return;d>a&&(d=a)}return f>0&&(i.a={x:s+f*p,y:c+f*g}),1>d&&(i.b={x:s+d*p,y:c+d*g}),i}}}}}}function ze(t,e,n,r){function i(r,i){return pu(r[0]-t)0?0:3:pu(r[0]-n)0?2:1:pu(r[1]-e)0?1:0:i>0?3:2}function a(t,e){return u(t.x,e.x)}function u(t,e){var n=i(t,1),r=i(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]; +!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.mermaidAPI=t()}}(function(){var define,module,exports;return function t(e,n,r){function i(u,o){if(!n[u]){if(!e[u]){var s="function"==typeof require&&require;if(!o&&s)return s(u,!0);if(a)return a(u,!0);var c=new Error("Cannot find module '"+u+"'");throw c.code="MODULE_NOT_FOUND",c}var l=n[u]={exports:{}};e[u][0].call(l.exports,function(t){var n=e[u][1][t];return i(n?n:t)},l,l.exports,t,e,n,r)}return n[u].exports}for(var a="function"==typeof require&&require,u=0;u=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=-1&&!i;a--){var u=a>=0?arguments[a]:t.cwd();if("string"!=typeof u)throw new TypeError("Arguments to path.resolve must be strings");u&&(n=u+"/"+n,i="/"===u.charAt(0))}return n=e(r(n.split("/"),function(t){return!!t}),!i).join("/"),(i?"/":"")+n||"."},n.normalize=function(t){var i=n.isAbsolute(t),a="/"===u(t,-1);return t=e(r(t.split("/"),function(t){return!!t}),!i).join("/"),t||i||(t="."),t&&a&&(t+="/"),(i?"/":"")+t},n.isAbsolute=function(t){return"/"===t.charAt(0)},n.join=function(){var t=Array.prototype.slice.call(arguments,0);return n.normalize(r(t,function(t){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},n.relative=function(t,e){function r(t){for(var e=0;e=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=n.resolve(t).substr(1),e=n.resolve(e).substr(1);for(var i=r(t.split("/")),a=r(e.split("/")),u=Math.min(i.length,a.length),o=u,s=0;u>s;s++)if(i[s]!==a[s]){o=s;break}for(var c=[],s=o;se&&(e=t.length+e),t.substr(e,n)}}).call(this,t("_process"))},{_process:3}],3:[function(t,e){function n(){}var r=e.exports={};r.nextTick=function(){var t="undefined"!=typeof window&&window.setImmediate,e="undefined"!=typeof window&&window.MutationObserver,n="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(t)return function(t){return window.setImmediate(t)};var r=[];if(e){var i=document.createElement("div"),a=new MutationObserver(function(){var t=r.slice();r.length=0,t.forEach(function(t){t()})});return a.observe(i,{attributes:!0}),function(t){r.length||i.setAttribute("yes","no"),r.push(t)}}return n?(window.addEventListener("message",function(t){var e=t.source;if((e===window||null===e)&&"process-tick"===t.data&&(t.stopPropagation(),r.length>0)){var n=r.shift();n()}},!0),function(t){r.push(t),window.postMessage("process-tick","*")}):function(t){setTimeout(t,0)}}(),r.title="browser",r.browser=!0,r.env={},r.argv=[],r.on=n,r.addListener=n,r.once=n,r.off=n,r.removeListener=n,r.removeAllListeners=n,r.emit=n,r.binding=function(){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(){throw new Error("process.chdir is not supported")}},{}],4:[function(t,e){!function(){function t(t){return t&&(t.ownerDocument||t.document||t).documentElement}function n(t){return t&&(t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView)}function r(t,e){return e>t?-1:t>e?1:t>=e?0:0/0}function i(t){return null===t?0/0:+t}function a(t){return!isNaN(t)}function u(t){return{left:function(e,n,r,i){for(arguments.length<3&&(r=0),arguments.length<4&&(i=e.length);i>r;){var a=r+i>>>1;t(e[a],n)<0?r=a+1:i=a}return r},right:function(e,n,r,i){for(arguments.length<3&&(r=0),arguments.length<4&&(i=e.length);i>r;){var a=r+i>>>1;t(e[a],n)>0?i=a:r=a+1}return r}}}function o(t){return t.length}function s(t){for(var e=1;t*e%1;)e*=10;return e}function c(t,e){for(var n in e)Object.defineProperty(t.prototype,n,{value:e[n],enumerable:!1})}function l(){this._=Object.create(null)}function h(t){return(t+="")===gu||t[0]===yu?yu+t:t}function f(t){return(t+="")[0]===yu?t.slice(1):t}function d(t){return h(t)in this._}function p(t){return(t=h(t))in this._&&delete this._[t]}function g(){var t=[];for(var e in this._)t.push(f(e));return t}function y(){var t=0;for(var e in this._)++t;return t}function m(){for(var t in this._)return!1;return!0}function v(){this._=Object.create(null)}function _(t){return t}function b(t,e,n){return function(){var r=n.apply(e,arguments);return r===e?t:r}}function x(t,e){if(e in t)return e;e=e.charAt(0).toUpperCase()+e.slice(1);for(var n=0,r=mu.length;r>n;++n){var i=mu[n]+e;if(i in t)return i}}function w(){}function A(){}function k(t){function e(){for(var e,r=n,i=-1,a=r.length;++in;n++)for(var i,a=t[n],u=0,o=a.length;o>u;u++)(i=a[u])&&e(i,u,n);return t}function W(t){return _u(t,Eu),t}function G(t){var e,n;return function(r,i,a){var u,o=t[a].update,s=o.length;for(a!=n&&(n=a,e=0),i>=e&&(e=i+1);!(u=o[e])&&++e0&&(t=t.slice(0,o));var c=Du.get(t);return c&&(t=c,s=X),o?e?i:r:e?w:a}function V(t,e){return function(n){var r=nu.event;nu.event=n,e[0]=this.__data__;try{t.apply(this,e)}finally{nu.event=r}}}function X(t,e){var n=V(t,e);return function(t){var e=this,r=t.relatedTarget;r&&(r===e||8&r.compareDocumentPosition(e))||n.call(e,t)}}function Z(e){var r=".dragsuppress-"+ ++Cu,i="click"+r,a=nu.select(n(e)).on("touchmove"+r,E).on("dragstart"+r,E).on("selectstart"+r,E);if(null==Mu&&(Mu="onselectstart"in e?!1:x(e.style,"userSelect")),Mu){var u=t(e).style,o=u[Mu];u[Mu]="none"}return function(t){if(a.on(r,null),Mu&&(u[Mu]=o),t){var e=function(){a.on(i,null)};a.on(i,function(){E(),e()},!0),setTimeout(e,0)}}}function K(t,e){e.changedTouches&&(e=e.changedTouches[0]);var r=t.ownerSVGElement||t;if(r.createSVGPoint){var i=r.createSVGPoint();if(0>Su){var a=n(t);if(a.scrollX||a.scrollY){r=nu.select("body").append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important");var u=r[0][0].getScreenCTM();Su=!(u.f||u.e),r.remove()}}return Su?(i.x=e.pageX,i.y=e.pageY):(i.x=e.clientX,i.y=e.clientY),i=i.matrixTransform(t.getScreenCTM().inverse()),[i.x,i.y]}var o=t.getBoundingClientRect();return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}function Q(){return nu.event.changedTouches[0].identifier}function J(t){return t>0?1:0>t?-1:0}function tt(t,e,n){return(e[0]-t[0])*(n[1]-t[1])-(e[1]-t[1])*(n[0]-t[0])}function et(t){return t>1?0:-1>t?Bu:Math.acos(t)}function nt(t){return t>1?Nu:-1>t?-Nu:Math.asin(t)}function rt(t){return((t=Math.exp(t))-1/t)/2}function it(t){return((t=Math.exp(t))+1/t)/2}function at(t){return((t=Math.exp(2*t))-1)/(t+1)}function ut(t){return(t=Math.sin(t/2))*t}function ot(){}function st(t,e,n){return this instanceof st?(this.h=+t,this.s=+e,void(this.l=+n)):arguments.length<2?t instanceof st?new st(t.h,t.s,t.l):wt(""+t,At,st):new st(t,e,n)}function ct(t,e,n){function r(t){return t>360?t-=360:0>t&&(t+=360),60>t?a+(u-a)*t/60:180>t?u:240>t?a+(u-a)*(240-t)/60:a}function i(t){return Math.round(255*r(t))}var a,u;return t=isNaN(t)?0:(t%=360)<0?t+360:t,e=isNaN(e)?0:0>e?0:e>1?1:e,n=0>n?0:n>1?1:n,u=.5>=n?n*(1+e):n+e-n*e,a=2*n-u,new vt(i(t+120),i(t),i(t-120))}function lt(t,e,n){return this instanceof lt?(this.h=+t,this.c=+e,void(this.l=+n)):arguments.length<2?t instanceof lt?new lt(t.h,t.c,t.l):t instanceof ft?pt(t.l,t.a,t.b):pt((t=kt((t=nu.rgb(t)).r,t.g,t.b)).l,t.a,t.b):new lt(t,e,n)}function ht(t,e,n){return isNaN(t)&&(t=0),isNaN(e)&&(e=0),new ft(n,Math.cos(t*=Iu)*e,Math.sin(t)*e)}function ft(t,e,n){return this instanceof ft?(this.l=+t,this.a=+e,void(this.b=+n)):arguments.length<2?t instanceof ft?new ft(t.l,t.a,t.b):t instanceof lt?ht(t.h,t.c,t.l):kt((t=vt(t)).r,t.g,t.b):new ft(t,e,n)}function dt(t,e,n){var r=(t+16)/116,i=r+e/500,a=r-n/200;return i=gt(i)*Hu,r=gt(r)*Vu,a=gt(a)*Xu,new vt(mt(3.2404542*i-1.5371385*r-.4985314*a),mt(-.969266*i+1.8760108*r+.041556*a),mt(.0556434*i-.2040259*r+1.0572252*a))}function pt(t,e,n){return t>0?new lt(Math.atan2(n,e)*Pu,Math.sqrt(e*e+n*n),t):new lt(0/0,0/0,t)}function gt(t){return t>.206893034?t*t*t:(t-4/29)/7.787037}function yt(t){return t>.008856?Math.pow(t,1/3):7.787037*t+4/29}function mt(t){return Math.round(255*(.00304>=t?12.92*t:1.055*Math.pow(t,1/2.4)-.055))}function vt(t,e,n){return this instanceof vt?(this.r=~~t,this.g=~~e,void(this.b=~~n)):arguments.length<2?t instanceof vt?new vt(t.r,t.g,t.b):wt(""+t,vt,ct):new vt(t,e,n)}function _t(t){return new vt(t>>16,t>>8&255,255&t)}function bt(t){return _t(t)+""}function xt(t){return 16>t?"0"+Math.max(0,t).toString(16):Math.min(255,t).toString(16)}function wt(t,e,n){t=t.toLowerCase();var r,i,a,u=0,o=0,s=0;if(r=/([a-z]+)\((.*)\)/.exec(t))switch(i=r[2].split(","),r[1]){case"hsl":return n(parseFloat(i[0]),parseFloat(i[1])/100,parseFloat(i[2])/100);case"rgb":return e(Dt(i[0]),Dt(i[1]),Dt(i[2]))}return(a=Qu.get(t))?e(a.r,a.g,a.b):(null==t||"#"!==t.charAt(0)||isNaN(a=parseInt(t.slice(1),16))||(4===t.length?(u=(3840&a)>>4,u=u>>4|u,o=240&a,o=o>>4|o,s=15&a,s=s<<4|s):7===t.length&&(u=(16711680&a)>>16,o=(65280&a)>>8,s=255&a)),e(u,o,s))}function At(t,e,n){var r,i,a=Math.min(t/=255,e/=255,n/=255),u=Math.max(t,e,n),o=u-a,s=(u+a)/2;return o?(i=.5>s?o/(u+a):o/(2-u-a),r=t==u?(e-n)/o+(n>e?6:0):e==u?(n-t)/o+2:(t-e)/o+4,r*=60):(r=0/0,i=s>0&&1>s?0:r),new st(r,i,s)}function kt(t,e,n){t=Et(t),e=Et(e),n=Et(n);var r=yt((.4124564*t+.3575761*e+.1804375*n)/Hu),i=yt((.2126729*t+.7151522*e+.072175*n)/Vu),a=yt((.0193339*t+.119192*e+.9503041*n)/Xu);return ft(116*i-16,500*(r-i),200*(i-a))}function Et(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Dt(t){var e=parseFloat(t);return"%"===t.charAt(t.length-1)?Math.round(2.55*e):e}function Mt(t){return"function"==typeof t?t:function(){return t}}function Ct(t){return function(e,n,r){return 2===arguments.length&&"function"==typeof n&&(r=n,n=null),St(e,n,t,r)}}function St(t,e,n,r){function i(){var t,e=s.status;if(!e&&Ft(s)||e>=200&&300>e||304===e){try{t=n.call(a,s)}catch(r){return void u.error.call(a,r)}u.load.call(a,t)}else u.error.call(a,s)}var a={},u=nu.dispatch("beforesend","progress","load","error"),o={},s=new XMLHttpRequest,c=null;return!this.XDomainRequest||"withCredentials"in s||!/^(http(s)?:)?\/\//.test(t)||(s=new XDomainRequest),"onload"in s?s.onload=s.onerror=i:s.onreadystatechange=function(){s.readyState>3&&i()},s.onprogress=function(t){var e=nu.event;nu.event=t;try{u.progress.call(a,s)}finally{nu.event=e}},a.header=function(t,e){return t=(t+"").toLowerCase(),arguments.length<2?o[t]:(null==e?delete o[t]:o[t]=e+"",a)},a.mimeType=function(t){return arguments.length?(e=null==t?null:t+"",a):e},a.responseType=function(t){return arguments.length?(c=t,a):c},a.response=function(t){return n=t,a},["get","post"].forEach(function(t){a[t]=function(){return a.send.apply(a,[t].concat(iu(arguments)))}}),a.send=function(n,r,i){if(2===arguments.length&&"function"==typeof r&&(i=r,r=null),s.open(n,t,!0),null==e||"accept"in o||(o.accept=e+",*/*"),s.setRequestHeader)for(var l in o)s.setRequestHeader(l,o[l]);return null!=e&&s.overrideMimeType&&s.overrideMimeType(e),null!=c&&(s.responseType=c),null!=i&&a.on("error",i).on("load",function(t){i(null,t)}),u.beforesend.call(a,s),s.send(null==r?null:r),a},a.abort=function(){return s.abort(),a},nu.rebind(a,u,"on"),null==r?a:a.get(Tt(r))}function Tt(t){return 1===t.length?function(e,n){t(null==e?n:null)}:t}function Ft(t){var e=t.responseType;return e&&"text"!==e?t.response:t.responseText}function Bt(){var t=Lt(),e=Ot()-t;e>24?(isFinite(e)&&(clearTimeout(no),no=setTimeout(Bt,e)),eo=0):(eo=1,io(Bt))}function Lt(){var t=Date.now();for(ro=Ju;ro;)t>=ro.t&&(ro.f=ro.c(t-ro.t)),ro=ro.n;return t}function Ot(){for(var t,e=Ju,n=1/0;e;)e.f?e=t?t.n=e.n:Ju=e.n:(e.t8?function(t){return t/n}:function(t){return t*n},symbol:t}}function Pt(t){var e=t.decimal,n=t.thousands,r=t.grouping,i=t.currency,a=r&&n?function(t,e){for(var i=t.length,a=[],u=0,o=r[0],s=0;i>0&&o>0&&(s+o+1>e&&(o=Math.max(1,e-s)),a.push(t.substring(i-=o,i+o)),!((s+=o+1)>e));)o=r[u=(u+1)%r.length];return a.reverse().join(n)}:_;return function(t){var n=uo.exec(t),r=n[1]||" ",u=n[2]||">",o=n[3]||"-",s=n[4]||"",c=n[5],l=+n[6],h=n[7],f=n[8],d=n[9],p=1,g="",y="",m=!1,v=!0;switch(f&&(f=+f.substring(1)),(c||"0"===r&&"="===u)&&(c=r="0",u="="),d){case"n":h=!0,d="g";break;case"%":p=100,y="%",d="f";break;case"p":p=100,y="%",d="r";break;case"b":case"o":case"x":case"X":"#"===s&&(g="0"+d.toLowerCase());case"c":v=!1;case"d":m=!0,f=0;break;case"s":p=-1,d="r"}"$"===s&&(g=i[0],y=i[1]),"r"!=d||f||(d="g"),null!=f&&("g"==d?f=Math.max(1,Math.min(21,f)):("e"==d||"f"==d)&&(f=Math.max(0,Math.min(20,f)))),d=oo.get(d)||Rt;var _=c&&h;return function(t){var n=y;if(m&&t%1)return"";var i=0>t||0===t&&0>1/t?(t=-t,"-"):"-"===o?"":o;if(0>p){var s=nu.formatPrefix(t,f);t=s.scale(t),n=s.symbol+y}else t*=p;t=d(t,f);var b,x,w=t.lastIndexOf(".");if(0>w){var A=v?t.lastIndexOf("e"):-1;0>A?(b=t,x=""):(b=t.substring(0,A),x=t.substring(A))}else b=t.substring(0,w),x=e+t.substring(w+1);!c&&h&&(b=a(b,1/0));var k=g.length+b.length+x.length+(_?0:i.length),E=l>k?new Array(k=l-k+1).join(r):"";return _&&(b=a(E+b,E.length?l-x.length:1/0)),i+=g,t=b+x,("<"===u?i+t+E:">"===u?E+i+t:"^"===u?E.substring(0,k>>=1)+i+t+E.substring(k):i+(_?t:E+t))+n}}}function Rt(t){return t+""}function jt(){this._=new Date(arguments.length>1?Date.UTC.apply(this,arguments):arguments[0])}function Yt(t,e,n){function r(e){var n=t(e),r=a(n,1);return r-e>e-n?n:r}function i(n){return e(n=t(new co(n-1)),1),n}function a(t,n){return e(t=new co(+t),n),t}function u(t,r,a){var u=i(t),o=[];if(a>1)for(;r>u;)n(u)%a||o.push(new Date(+u)),e(u,1);else for(;r>u;)o.push(new Date(+u)),e(u,1);return o}function o(t,e,n){try{co=jt;var r=new jt;return r._=t,u(r,e,n)}finally{co=Date}}t.floor=t,t.round=r,t.ceil=i,t.offset=a,t.range=u;var s=t.utc=Ut(t);return s.floor=s,s.round=Ut(r),s.ceil=Ut(i),s.offset=Ut(a),s.range=o,t}function Ut(t){return function(e,n){try{co=jt;var r=new jt;return r._=e,t(r,n)._}finally{co=Date}}}function $t(t){function e(t){function e(e){for(var n,i,a,u=[],o=-1,s=0;++oo;){if(r>=c)return-1;if(i=e.charCodeAt(o++),37===i){if(u=e.charAt(o++),a=S[u in ho?e.charAt(o++):u],!a||(r=a(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}function r(t,e,n){w.lastIndex=0;var r=w.exec(e.slice(n));return r?(t.w=A.get(r[0].toLowerCase()),n+r[0].length):-1}function i(t,e,n){b.lastIndex=0;var r=b.exec(e.slice(n));return r?(t.w=x.get(r[0].toLowerCase()),n+r[0].length):-1}function a(t,e,n){D.lastIndex=0;var r=D.exec(e.slice(n));return r?(t.m=M.get(r[0].toLowerCase()),n+r[0].length):-1}function u(t,e,n){k.lastIndex=0;var r=k.exec(e.slice(n));return r?(t.m=E.get(r[0].toLowerCase()),n+r[0].length):-1}function o(t,e,r){return n(t,C.c.toString(),e,r)}function s(t,e,r){return n(t,C.x.toString(),e,r)}function c(t,e,r){return n(t,C.X.toString(),e,r)}function l(t,e,n){var r=_.get(e.slice(n,n+=2).toLowerCase());return null==r?-1:(t.p=r,n)}var h=t.dateTime,f=t.date,d=t.time,p=t.periods,g=t.days,y=t.shortDays,m=t.months,v=t.shortMonths;e.utc=function(t){function n(t){try{co=jt;var e=new co;return e._=t,r(e)}finally{co=Date}}var r=e(t);return n.parse=function(t){try{co=jt;var e=r.parse(t);return e&&e._}finally{co=Date}},n.toString=r.toString,n},e.multi=e.utc.multi=se;var _=nu.map(),b=qt(g),x=Wt(g),w=qt(y),A=Wt(y),k=qt(m),E=Wt(m),D=qt(v),M=Wt(v);p.forEach(function(t,e){_.set(t.toLowerCase(),e)});var C={a:function(t){return y[t.getDay()]},A:function(t){return g[t.getDay()]},b:function(t){return v[t.getMonth()]},B:function(t){return m[t.getMonth()]},c:e(h),d:function(t,e){return zt(t.getDate(),e,2)},e:function(t,e){return zt(t.getDate(),e,2)},H:function(t,e){return zt(t.getHours(),e,2)},I:function(t,e){return zt(t.getHours()%12||12,e,2)},j:function(t,e){return zt(1+so.dayOfYear(t),e,3)},L:function(t,e){return zt(t.getMilliseconds(),e,3)},m:function(t,e){return zt(t.getMonth()+1,e,2)},M:function(t,e){return zt(t.getMinutes(),e,2)},p:function(t){return p[+(t.getHours()>=12)]},S:function(t,e){return zt(t.getSeconds(),e,2)},U:function(t,e){return zt(so.sundayOfYear(t),e,2)},w:function(t){return t.getDay()},W:function(t,e){return zt(so.mondayOfYear(t),e,2)},x:e(f),X:e(d),y:function(t,e){return zt(t.getFullYear()%100,e,2)},Y:function(t,e){return zt(t.getFullYear()%1e4,e,4)},Z:ue,"%":function(){return"%"}},S={a:r,A:i,b:a,B:u,c:o,d:te,e:te,H:ne,I:ne,j:ee,L:ae,m:Jt,M:re,p:l,S:ie,U:Ht,w:Gt,W:Vt,x:s,X:c,y:Zt,Y:Xt,Z:Kt,"%":oe};return e}function zt(t,e,n){var r=0>t?"-":"",i=(r?-t:t)+"",a=i.length;return r+(n>a?new Array(n-a+1).join(e)+i:i)}function qt(t){return new RegExp("^(?:"+t.map(nu.requote).join("|")+")","i")}function Wt(t){for(var e=new l,n=-1,r=t.length;++n68?1900:2e3)}function Jt(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function te(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function ee(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+3));return r?(t.j=+r[0],n+r[0].length):-1}function ne(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function re(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function ie(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function ae(t,e,n){fo.lastIndex=0;var r=fo.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function ue(t){var e=t.getTimezoneOffset(),n=e>0?"-":"+",r=pu(e)/60|0,i=pu(e)%60;return n+zt(r,"0",2)+zt(i,"0",2)}function oe(t,e,n){po.lastIndex=0;var r=po.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function se(t){for(var e=t.length,n=-1;++n=0?1:-1,o=u*n,s=Math.cos(e),c=Math.sin(e),l=a*c,h=i*s+l*Math.cos(o),f=l*u*Math.sin(o);bo.add(Math.atan2(f,h)),r=t,i=s,a=c}var e,n,r,i,a;xo.point=function(u,o){xo.point=t,r=(e=u)*Iu,i=Math.cos(o=(n=o)*Iu/2+Bu/4),a=Math.sin(o)},xo.lineEnd=function(){t(e,n)}}function ge(t){var e=t[0],n=t[1],r=Math.cos(n);return[r*Math.cos(e),r*Math.sin(e),Math.sin(n)]}function ye(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function me(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 ve(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function _e(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function be(t){var e=Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}function xe(t){return[Math.atan2(t[1],t[0]),nt(t[2])]}function we(t,e){return pu(t[0]-e[0])o;++o)i.point((n=t[o])[0],n[1]);return void i.lineEnd()}var s=new Be(n,t,null,!0),c=new Be(n,null,s,!1);s.o=c,a.push(s),u.push(c),s=new Be(r,t,null,!1),c=new Be(r,null,s,!0),s.o=c,a.push(s),u.push(c)}}),u.sort(e),Fe(a),Fe(u),a.length){for(var o=0,s=n,c=u.length;c>o;++o)u[o].e=s=!s;for(var l,h,f=a[0];;){for(var d=f,p=!0;d.v;)if((d=d.n)===f)return;l=d.z,i.lineStart();do{if(d.v=d.o.v=!0,d.e){if(p)for(var o=0,c=l.length;c>o;++o)i.point((h=l[o])[0],h[1]);else r(d.x,d.n.x,1,i);d=d.n}else{if(p){l=d.p.z;for(var o=l.length-1;o>=0;--o)i.point((h=l[o])[0],h[1])}else r(d.x,d.p.x,-1,i);d=d.p}d=d.o,l=d.z,p=!p}while(!d.v);i.lineEnd()}}}function Fe(t){if(e=t.length){for(var e,n,r=0,i=t[0];++r0){for(x||(a.polygonStart(),x=!0),a.lineStart();++u1&&2&e&&n.push(n.pop().concat(n.shift())),d.push(n.filter(Oe))}var d,p,g,y=e(a),m=i.invert(r[0],r[1]),v={point:u,lineStart:s,lineEnd:c,polygonStart:function(){v.point=l,v.lineStart=h,v.lineEnd=f,d=[],p=[]},polygonEnd:function(){v.point=u,v.lineStart=s,v.lineEnd=c,d=nu.merge(d);var t=Ye(m,p);d.length?(x||(a.polygonStart(),x=!0),Te(d,Ie,t,n,a)):t&&(x||(a.polygonStart(),x=!0),a.lineStart(),n(null,null,1,a),a.lineEnd()),x&&(a.polygonEnd(),x=!1),d=p=null},sphere:function(){a.polygonStart(),a.lineStart(),n(null,null,1,a),a.lineEnd(),a.polygonEnd()}},_=Ne(),b=e(_),x=!1;return v}}function Oe(t){return t.length>1}function Ne(){var t,e=[];return{lineStart:function(){e.push(t=[])},point:function(e,n){t.push([e,n])},lineEnd:w,buffer:function(){var n=e;return e=[],t=null,n},rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))}}}function Ie(t,e){return((t=t.x)[0]<0?t[1]-Nu-Tu:Nu-t[1])-((e=e.x)[0]<0?e[1]-Nu-Tu:Nu-e[1])}function Pe(t){var e,n=0/0,r=0/0,i=0/0;return{lineStart:function(){t.lineStart(),e=1},point:function(a,u){var o=a>0?Bu:-Bu,s=pu(a-n);pu(s-Bu)0?Nu:-Nu),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(o,r),t.point(a,r),e=0):i!==o&&s>=Bu&&(pu(n-i)Tu?Math.atan((Math.sin(e)*(a=Math.cos(r))*Math.sin(n)-Math.sin(r)*(i=Math.cos(e))*Math.sin(t))/(i*a*u)):(e+r)/2}function je(t,e,n,r){var i;if(null==t)i=n*Nu,r.point(-Bu,i),r.point(0,i),r.point(Bu,i),r.point(Bu,0),r.point(Bu,-i),r.point(0,-i),r.point(-Bu,-i),r.point(-Bu,0),r.point(-Bu,i);else if(pu(t[0]-e[0])>Tu){var a=t[0]o;++o){var c=e[o],l=c.length;if(l)for(var h=c[0],f=h[0],d=h[1]/2+Bu/4,p=Math.sin(d),g=Math.cos(d),y=1;;){y===l&&(y=0),t=c[y];var m=t[0],v=t[1]/2+Bu/4,_=Math.sin(v),b=Math.cos(v),x=m-f,w=x>=0?1:-1,A=w*x,k=A>Bu,E=p*_;if(bo.add(Math.atan2(E*w*Math.sin(A),g*b+E*Math.cos(A))),a+=k?x+w*Lu:x,k^f>=n^m>=n){var D=me(ge(h),ge(t));be(D);var M=me(i,D);be(M);var C=(k^x>=0?-1:1)*nt(M[2]);(r>C||r===C&&(D[0]||D[1]))&&(u+=k^x>=0?1:-1)}if(!y++)break;f=m,p=_,g=b,h=t}}return(-Tu>a||Tu>a&&0>bo)^1&u}function Ue(t){function e(t,e){return Math.cos(t)*Math.cos(e)>a}function n(t){var n,a,s,c,l;return{lineStart:function(){c=s=!1,l=1},point:function(h,f){var d,p=[h,f],g=e(h,f),y=u?g?0:i(h,f):g?i(h+(0>h?Bu:-Bu),f):0;if(!n&&(c=s=g)&&t.lineStart(),g!==s&&(d=r(n,p),(we(n,d)||we(p,d))&&(p[0]+=Tu,p[1]+=Tu,g=e(p[0],p[1]))),g!==s)l=0,g?(t.lineStart(),d=r(p,n),t.point(d[0],d[1])):(d=r(n,p),t.point(d[0],d[1]),t.lineEnd()),n=d;else if(o&&n&&u^g){var m;y&a||!(m=r(p,n,!0))||(l=0,u?(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])))}!g||n&&we(n,p)||t.point(p[0],p[1]),n=p,s=g,a=y},lineEnd:function(){s&&t.lineEnd(),n=null},clean:function(){return l|(c&&s)<<1}}}function r(t,e,n){var r=ge(t),i=ge(e),u=[1,0,0],o=me(r,i),s=ye(o,o),c=o[0],l=s-c*c;if(!l)return!n&&t;var h=a*s/l,f=-a*c/l,d=me(u,o),p=_e(u,h),g=_e(o,f);ve(p,g);var y=d,m=ye(p,y),v=ye(y,y),_=m*m-v*(ye(p,p)-1);if(!(0>_)){var b=Math.sqrt(_),x=_e(y,(-m-b)/v);if(ve(x,p),x=xe(x),!n)return x;var w,A=t[0],k=e[0],E=t[1],D=e[1];A>k&&(w=A,A=k,k=w);var M=k-A,C=pu(M-Bu)M;if(!C&&E>D&&(w=E,E=D,D=w),S?C?E+D>0^x[1]<(pu(x[0]-A)Bu^(A<=x[0]&&x[0]<=k)){var T=_e(y,(-m+b)/v);return ve(T,p),[x,xe(T)]}}}function i(e,n){var r=u?t:Bu-t,i=0;return-r>e?i|=1:e>r&&(i|=2),-r>n?i|=4:n>r&&(i|=8),i}var a=Math.cos(t),u=a>0,o=pu(a)>Tu,s=gn(t,6*Iu);return Le(e,n,s,u?[0,-t]:[-Bu,t-Bu])}function $e(t,e,n,r){return function(i){var a,u=i.a,o=i.b,s=u.x,c=u.y,l=o.x,h=o.y,f=0,d=1,p=l-s,g=h-c;if(a=t-s,p||!(a>0)){if(a/=p,0>p){if(f>a)return;d>a&&(d=a)}else if(p>0){if(a>d)return;a>f&&(f=a)}if(a=n-s,p||!(0>a)){if(a/=p,0>p){if(a>d)return;a>f&&(f=a)}else if(p>0){if(f>a)return;d>a&&(d=a)}if(a=e-c,g||!(a>0)){if(a/=g,0>g){if(f>a)return;d>a&&(d=a)}else if(g>0){if(a>d)return;a>f&&(f=a)}if(a=r-c,g||!(0>a)){if(a/=g,0>g){if(a>d)return;a>f&&(f=a)}else if(g>0){if(f>a)return;d>a&&(d=a)}return f>0&&(i.a={x:s+f*p,y:c+f*g}),1>d&&(i.b={x:s+d*p,y:c+d*g}),i}}}}}}function ze(t,e,n,r){function i(r,i){return pu(r[0]-t)0?0:3:pu(r[0]-n)0?2:1:pu(r[1]-e)0?1:0:i>0?3:2}function a(t,e){return u(t.x,e.x)}function u(t,e){var n=i(t,1),r=i(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){function s(t){for(var e=0,n=y.length,r=t[1],i=0;n>i;++i)for(var a,u=1,o=y[i],s=o.length,c=o[0];s>u;++u)a=o[u],c[1]<=r?a[1]>r&&tt(c,a,t)>0&&++e:a[1]<=r&&tt(c,a,t)<0&&--e,c=a;return 0!==e}function c(a,o,s,c){var l=0,h=0;if(null==a||(l=i(a,s))!==(h=i(o,s))||u(a,o)<0^s>0){do c.point(0===l||3===l?t:n,l>1?r:e);while((l=(l+s+4)%4)!==h)}else c.point(o[0],o[1])}function l(i,a){return i>=t&&n>=i&&a>=e&&r>=a}function h(t,e){l(t,e)&&o.point(t,e)}function f(){S.point=p,y&&y.push(m=[]),k=!0,A=!1,x=w=0/0}function d(){g&&(p(v,_),b&&A&&D.rejoin(),g.push(D.buffer())),S.point=h,A&&o.lineEnd()}function p(t,e){t=Math.max(-Io,Math.min(Io,t)),e=Math.max(-Io,Math.min(Io,e));var n=l(t,e);if(y&&m.push([t,e]),k)v=t,_=e,b=n,k=!1,n&&(o.lineStart(),o.point(t,e));else if(n&&A)o.point(t,e);else{var r={a:{x:x,y:w},b:{x:t,y:e}};C(r)?(A||(o.lineStart(),o.point(r.a.x,r.a.y)),o.point(r.b.x,r.b.y),n||o.lineEnd(),E=!1):n&&(o.lineStart(),o.point(t,e),E=!1)}x=t,w=e,A=n}var g,y,m,v,_,b,x,w,A,k,E,M=o,D=Ie(),C=$e(t,e,n,r),S={point:h,lineStart:f,lineEnd:d,polygonStart:function(){o=D,g=[],y=[],E=!0},polygonEnd:function(){o=M,g=nu.merge(g);var e=s([t,r]),n=E&&e,i=g.length;(n||i)&&(o.polygonStart(),n&&(o.lineStart(),c(null,null,1,o),o.lineEnd()),i&&Te(g,a,e,c,o),o.polygonEnd()),g=y=m=null}};return S}}function qe(t){var e=0,n=Bu/3,r=on(t),i=r(e,n);return i.parallels=function(t){return arguments.length?r(e=t[0]*Bu/180,n=t[1]*Bu/180):[e/Bu*180,n/Bu*180]},i}function We(t,e){function n(t,e){var n=Math.sqrt(a-2*i*Math.sin(e))/i;return[n*Math.sin(t*=i),u-n*Math.cos(t)]}var r=Math.sin(t),i=(r+Math.sin(e))/2,a=1+r*(2*i-r),u=Math.sqrt(a)/i;return n.invert=function(t,e){var n=u-e;return[Math.atan2(t,n)/i,nt((a-(t*t+n*n)*i*i)/(2*i))]},n}function Ge(){function t(t,e){Po+=i*t-r*e,r=t,i=e}var e,n,r,i;$o.point=function(a,u){$o.point=t,e=r=a,n=i=u},$o.lineEnd=function(){t(e,n)}}function He(t,e){Ro>t&&(Ro=t),t>Yo&&(Yo=t),jo>e&&(jo=e),e>Uo&&(Uo=e)}function Ve(){function t(t,e){u.push("M",t,",",e,a)}function e(t,e){u.push("M",t,",",e),o.point=n}function n(t,e){u.push("L",t,",",e)}function r(){o.point=t}function i(){u.push("Z")}var a=Xe(4.5),u=[],o={point:t,lineStart:function(){o.point=e},lineEnd:r,polygonStart:function(){o.lineEnd=i},polygonEnd:function(){o.lineEnd=r,o.point=t},pointRadius:function(t){return a=Xe(t),o},result:function(){if(u.length){var t=u.join("");return u=[],t}}};return o}function Xe(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}function Ze(t,e){ko+=t,Eo+=e,++Mo}function Ke(){function t(t,r){var i=t-e,a=r-n,u=Math.sqrt(i*i+a*a);Do+=u*(e+t)/2,Co+=u*(n+r)/2,So+=u,Ze(e=t,n=r)}var e,n;qo.point=function(r,i){qo.point=t,Ze(e=r,n=i)}}function Qe(){qo.point=Ze}function Je(){function t(t,e){var n=t-r,a=e-i,u=Math.sqrt(n*n+a*a);Do+=u*(r+t)/2,Co+=u*(i+e)/2,So+=u,u=i*t-r*e,To+=u*(r+t),Fo+=u*(i+e),Bo+=3*u,Ze(r=t,i=e)}var e,n,r,i;qo.point=function(a,u){qo.point=t,Ze(e=r=a,n=i=u)},qo.lineEnd=function(){t(e,n)}}function tn(t){function e(e,n){t.moveTo(e+u,n),t.arc(e,n,u,0,Lu)}function n(e,n){t.moveTo(e,n),o.point=r}function r(e,n){t.lineTo(e,n)}function i(){o.point=e}function a(){t.closePath()}var u=4.5,o={point:e,lineStart:function(){o.point=n},lineEnd:i,polygonStart:function(){o.lineEnd=a},polygonEnd:function(){o.lineEnd=i,o.point=e},pointRadius:function(t){return u=t,o},result:w};return o}function en(t){function e(t){return(o?r:n)(t)}function n(e){return an(e,function(n,r){n=t(n,r),e.point(n[0],n[1])})}function r(e){function n(n,r){n=t(n,r),e.point(n[0],n[1])}function r(){_=0/0,k.point=a,e.lineStart()}function a(n,r){var a=ge([n,r]),u=t(n,r);i(_,b,v,x,w,A,_=u[0],b=u[1],v=n,x=a[0],w=a[1],A=a[2],o,e),e.point(_,b)}function u(){k.point=n,e.lineEnd()}function s(){r(),k.point=c,k.lineEnd=l}function c(t,e){a(h=t,f=e),d=_,p=b,g=x,y=w,m=A,k.point=a}function l(){i(_,b,v,x,w,A,d,p,h,g,y,m,o,e),k.lineEnd=u,u()}var h,f,d,p,g,y,m,v,_,b,x,w,A,k={point:n,lineStart:r,lineEnd:u,polygonStart:function(){e.polygonStart(),k.lineStart=s},polygonEnd:function(){e.polygonEnd(),k.lineStart=r}};return k}function i(e,n,r,o,s,c,l,h,f,d,p,g,y,m){var v=l-e,_=h-n,b=v*v+_*_;if(b>4*a&&y--){var x=o+d,w=s+p,A=c+g,k=Math.sqrt(x*x+w*w+A*A),E=Math.asin(A/=k),M=pu(pu(A)-1)a||pu((v*T+_*F)/b-.5)>.3||u>o*d+s*p+c*g)&&(i(e,n,r,o,s,c,C,S,M,x/=k,w/=k,A,y,m),m.point(C,S),i(C,S,M,x,w,A,l,h,f,d,p,g,y,m))}}var a=.5,u=Math.cos(30*Nu),o=16;return e.precision=function(t){return arguments.length?(o=(a=t*t)>0&&16,e):Math.sqrt(a)},e}function nn(t){var e=en(function(e,n){return t([e*Pu,n*Pu])});return function(t){return sn(e(t))}}function rn(t){this.stream=t}function an(t,e){return{point:e,sphere:function(){t.sphere()},lineStart:function(){t.lineStart()},lineEnd:function(){t.lineEnd()},polygonStart:function(){t.polygonStart()},polygonEnd:function(){t.polygonEnd()}}}function un(t){return on(function(){return t})()}function on(t){function e(t){return t=o(t[0]*Nu,t[1]*Nu),[t[0]*f+s,c-t[1]*f]}function n(t){return t=o.invert((t[0]-s)/f,(c-t[1])/f),t&&[t[0]*Pu,t[1]*Pu]}function r(){o=Ce(u=hn(m,v,b),a);var t=a(g,y);return s=d-t[0]*f,c=p+t[1]*f,i()}function i(){return l&&(l.valid=!1,l=null),e}var a,u,o,s,c,l,h=en(function(t,e){return t=a(t,e),[t[0]*f+s,c-t[1]*f]}),f=150,d=480,p=250,g=0,y=0,m=0,v=0,b=0,x=Oo,w=_,A=null,k=null;return e.stream=function(t){return l&&(l.valid=!1),l=sn(x(u,h(w(t)))),l.valid=!0,l},e.clipAngle=function(t){return arguments.length?(x=null==t?(A=t,Oo):Ue((A=+t)*Nu),i()):A},e.clipExtent=function(t){return arguments.length?(k=t,w=t?ze(t[0][0],t[0][1],t[1][0],t[1][1]):_,i()):k},e.scale=function(t){return arguments.length?(f=+t,r()):f},e.translate=function(t){return arguments.length?(d=+t[0],p=+t[1],r()):[d,p]},e.center=function(t){return arguments.length?(g=t[0]%360*Nu,y=t[1]%360*Nu,r()):[g*Pu,y*Pu]},e.rotate=function(t){return arguments.length?(m=t[0]%360*Nu,v=t[1]%360*Nu,b=t.length>2?t[2]%360*Nu:0,r()):[m*Pu,v*Pu,b*Pu]},nu.rebind(e,h,"precision"),function(){return a=t.apply(this,arguments),e.invert=a.invert&&n,r()}}function sn(t){return an(t,function(e,n){t.point(e*Nu,n*Nu)})}function cn(t,e){return[t,e]}function ln(t,e){return[t>Bu?t-Lu:-Bu>t?t+Lu:t,e]}function hn(t,e,n){return t?e||n?Ce(dn(t),pn(e,n)):dn(t):e||n?pn(e,n):ln}function fn(t){return function(e,n){return e+=t,[e>Bu?e-Lu:-Bu>e?e+Lu:e,n]}}function dn(t){var e=fn(t);return e.invert=fn(-t),e}function pn(t,e){function n(t,e){var n=Math.cos(e),o=Math.cos(t)*n,s=Math.sin(t)*n,c=Math.sin(e),l=c*r+o*i;return[Math.atan2(s*a-l*u,o*r-c*i),nt(l*a+s*u)]}var r=Math.cos(t),i=Math.sin(t),a=Math.cos(e),u=Math.sin(e);return n.invert=function(t,e){var n=Math.cos(e),o=Math.cos(t)*n,s=Math.sin(t)*n,c=Math.sin(e),l=c*a-s*u;return[Math.atan2(s*a+c*u,o*r+l*i),nt(l*r-o*i)]},n}function gn(t,e){var n=Math.cos(t),r=Math.sin(t);return function(i,a,u,o){var s=u*e;null!=i?(i=yn(n,i),a=yn(n,a),(u>0?a>i:i>a)&&(i+=u*Lu)):(i=t+u*Lu,a=t-.5*s);for(var c,l=i;u>0?l>a:a>l;l-=s)o.point((c=xe([n,-r*Math.cos(l),-r*Math.sin(l)]))[0],c[1])}}function yn(t,e){var n=ge(e);n[0]-=t,be(n);var r=et(-n[1]);return((-n[2]<0?-r:r)+2*Math.PI-Tu)%(2*Math.PI)}function mn(t,e,n){var r=nu.range(t,e-Tu,n).concat(e);return function(t){return r.map(function(e){return[t,e]})}}function vn(t,e,n){var r=nu.range(t,e-Tu,n).concat(e);return function(t){return r.map(function(e){return[e,t]})}}function _n(t){return t.source}function bn(t){return t.target}function xn(t,e,n,r){var i=Math.cos(e),a=Math.sin(e),u=Math.cos(r),o=Math.sin(r),s=i*Math.cos(t),c=i*Math.sin(t),l=u*Math.cos(n),h=u*Math.sin(n),f=2*Math.asin(Math.sqrt(ut(r-e)+i*u*ut(n-t))),d=1/Math.sin(f),p=f?function(t){var e=Math.sin(t*=f)*d,n=Math.sin(f-t)*d,r=n*s+e*l,i=n*c+e*h,u=n*a+e*o;return[Math.atan2(i,r)*Pu,Math.atan2(u,Math.sqrt(r*r+i*i))*Pu]}:function(){return[t*Pu,e*Pu]};return p.distance=f,p}function wn(){function t(t,i){var a=Math.sin(i*=Nu),u=Math.cos(i),o=pu((t*=Nu)-e),s=Math.cos(o);Wo+=Math.atan2(Math.sqrt((o=u*Math.sin(o))*o+(o=r*a-n*u*s)*o),n*a+r*u*s),e=t,n=a,r=u}var e,n,r;Go.point=function(i,a){e=i*Nu,n=Math.sin(a*=Nu),r=Math.cos(a),Go.point=t},Go.lineEnd=function(){Go.point=Go.lineEnd=w}}function An(t,e){function n(e,n){var r=Math.cos(e),i=Math.cos(n),a=t(r*i);return[a*i*Math.sin(e),a*Math.sin(n)]}return n.invert=function(t,n){var r=Math.sqrt(t*t+n*n),i=e(r),a=Math.sin(i),u=Math.cos(i);return[Math.atan2(t*a,r*u),Math.asin(r&&n*a/r)]},n}function kn(t,e){function n(t,e){u>0?-Iu+Tu>e&&(e=-Iu+Tu):e>Iu-Tu&&(e=Iu-Tu);var n=u/Math.pow(i(e),a);return[n*Math.sin(a*t),u-n*Math.cos(a*t)]}var r=Math.cos(t),i=function(t){return Math.tan(Bu/4+t/2)},a=t===e?Math.sin(t):Math.log(r/Math.cos(e))/Math.log(i(e)/i(t)),u=r*Math.pow(i(t),a)/a;return a?(n.invert=function(t,e){var n=u-e,r=J(a)*Math.sqrt(t*t+n*n);return[Math.atan2(t,n)/a,2*Math.atan(Math.pow(u/r,1/a))-Iu]},n):Mn}function En(t,e){function n(t,e){var n=a-e;return[n*Math.sin(i*t),a-n*Math.cos(i*t)]}var r=Math.cos(t),i=t===e?Math.sin(t):(r-Math.cos(e))/(e-t),a=r/i+t;return pu(i)i;i++){for(;r>1&&tt(t[n[r-2]],t[n[r-1]],t[i])<=0;)--r;n[r++]=i}return n.slice(0,r)}function Bn(t,e){return t[0]-e[0]||t[1]-e[1]}function Ln(t,e,n){return(n[0]-e[0])*(t[1]-e[1])<(n[1]-e[1])*(t[0]-e[0])}function On(t,e,n,r){var i=t[0],a=n[0],u=e[0]-i,o=r[0]-a,s=t[1],c=n[1],l=e[1]-s,h=r[1]-c,f=(o*(s-c)-h*(i-a))/(h*u-o*l);return[i+f*u,s+f*l]}function In(t){var e=t[0],n=t[t.length-1];return!(e[0]-n[0]||e[1]-n[1])}function Nn(){rr(this),this.edge=this.site=this.circle=null}function Pn(t){var e=is.pop()||new Nn;return e.site=t,e}function Rn(t){Vn(t),es.remove(t),is.push(t),rr(t)}function jn(t){var e=t.circle,n=e.x,r=e.cy,i={x:n,y:r},a=t.P,u=t.N,o=[t];Rn(t);for(var s=a;s.circle&&pu(n-s.circle.x)l;++l)c=o[l],s=o[l-1],tr(c.edge,s.site,c.site,i);s=o[0],c=o[h-1],c.edge=Qn(s.site,c.site,null,i),Hn(s),Hn(c)}function Yn(t){for(var e,n,r,i,a=t.x,u=t.y,o=es._;o;)if(r=Un(o,u)-a,r>Tu)o=o.L;else{if(i=a-$n(o,u),!(i>Tu)){r>-Tu?(e=o.P,n=o):i>-Tu?(e=o,n=o.N):e=n=o;break}if(!o.R){e=o;break}o=o.R}var s=Pn(t);if(es.insert(e,s),e||n){if(e===n)return Vn(e),n=Pn(e.site),es.insert(s,n),s.edge=n.edge=Qn(e.site,s.site),Hn(e),void Hn(n);if(!n)return void(s.edge=Qn(e.site,s.site));Vn(e),Vn(n);var c=e.site,l=c.x,h=c.y,f=t.x-l,d=t.y-h,p=n.site,g=p.x-l,y=p.y-h,m=2*(f*y-d*g),v=f*f+d*d,_=g*g+y*y,b={x:(y*v-d*_)/m+l,y:(f*_-g*v)/m+h};tr(n.edge,c,p,b),s.edge=Qn(c,t,null,b),n.edge=Qn(t,p,null,b),Hn(e),Hn(n)}}function Un(t,e){var n=t.site,r=n.x,i=n.y,a=i-e;if(!a)return r;var u=t.P;if(!u)return-(1/0);n=u.site;var o=n.x,s=n.y,c=s-e;if(!c)return o;var l=o-r,h=1/a-1/c,f=l/c;return h?(-f+Math.sqrt(f*f-2*h*(l*l/(-2*c)-s+c/2+i-a/2)))/h+r:(r+o)/2}function $n(t,e){var n=t.N;if(n)return Un(n,e);var r=t.site;return r.y===e?r.x:1/0}function zn(t){this.site=t,this.edges=[]}function qn(t){for(var e,n,r,i,a,u,o,s,c,l,h=t[0][0],f=t[1][0],d=t[0][1],p=t[1][1],g=ts,y=g.length;y--;)if(a=g[y],a&&a.prepare())for(o=a.edges,s=o.length,u=0;s>u;)l=o[u].end(),r=l.x,i=l.y,c=o[++u%s].start(),e=c.x,n=c.y,(pu(r-e)>Tu||pu(i-n)>Tu)&&(o.splice(u,0,new er(Jn(a.site,l,pu(r-h)Tu?{x:h,y:pu(e-h)Tu?{x:pu(n-p)Tu?{x:f,y:pu(e-f)Tu?{x:pu(n-d)=-Fu)){var d=s*s+c*c,p=l*l+h*h,g=(h*d-c*p)/f,y=(s*p-l*d)/f,h=y+o,m=as.pop()||new Gn;m.arc=t,m.site=i,m.x=g+u,m.y=h+Math.sqrt(g*g+y*y),m.cy=h,t.circle=m;for(var v=null,_=rs._;_;)if(m.y<_.y||m.y===_.y&&m.x<=_.x){if(!_.L){v=_.P;break}_=_.L}else{if(!_.R){v=_;break}_=_.R}rs.insert(v,m),v||(ns=m)}}}}function Vn(t){var e=t.circle;e&&(e.P||(ns=e.N),rs.remove(e),as.push(e),rr(e),t.circle=null)}function Xn(t){for(var e,n=Jo,r=$e(t[0][0],t[0][1],t[1][0],t[1][1]),i=n.length;i--;)e=n[i],(!Zn(e,t)||!r(e)||pu(e.a.x-e.b.x)y||y>=o)return;if(f>p){if(a){if(a.y>=c)return}else a={x:y,y:s};n={x:y,y:c}}else{if(a){if(a.yr||r>1)if(f>p){if(a){if(a.y>=c)return}else a={x:(s-i)/r,y:s};n={x:(c-i)/r,y:c}}else{if(a){if(a.yd){if(a){if(a.x>=o)return}else a={x:u,y:r*u+i};n={x:o,y:r*o+i}}else{if(a){if(a.xa||h>u||r>f||i>d)){if(p=t.point){var p,g=e-t.x,y=n-t.y,m=g*g+y*y;if(s>m){var v=Math.sqrt(s=m);r=e-v,i=n-v,a=e+v,u=n+v,o=p}}for(var _=t.nodes,b=.5*(l+f),x=.5*(h+d),w=e>=b,A=n>=x,k=A<<1|w,E=k+4;E>k;++k)if(t=_[3&k])switch(3&k){case 0:c(t,l,h,b,x);break;case 1:c(t,b,h,f,x);break;case 2:c(t,l,x,b,d);break;case 3:c(t,b,x,f,d)}}}(t,r,i,a,u),o}function gr(t,e){t=nu.rgb(t),e=nu.rgb(e);var n=t.r,r=t.g,i=t.b,a=e.r-n,u=e.g-r,o=e.b-i;return function(t){return"#"+xt(Math.round(n+a*t))+xt(Math.round(r+u*t))+xt(Math.round(i+o*t))}}function yr(t,e){var n,r={},i={};for(n in t)n in e?r[n]=_r(t[n],e[n]):i[n]=t[n];for(n in e)n in t||(i[n]=e[n]);return function(t){for(n in r)i[n]=r[n](t);return i}}function mr(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function vr(t,e){var n,r,i,a=os.lastIndex=ss.lastIndex=0,u=-1,o=[],s=[];for(t+="",e+="";(n=os.exec(t))&&(r=ss.exec(e));)(i=r.index)>a&&(i=e.slice(a,i),o[u]?o[u]+=i:o[++u]=i),(n=n[0])===(r=r[0])?o[u]?o[u]+=r:o[++u]=r:(o[++u]=null,s.push({i:u,x:mr(n,r)})),a=ss.lastIndex;return ar;++r)o[(n=s[r]).i]=n.x(t);return o.join("")})}function _r(t,e){for(var n,r=nu.interpolators.length;--r>=0&&!(n=nu.interpolators[r](t,e)););return n}function br(t,e){var n,r=[],i=[],a=t.length,u=e.length,o=Math.min(t.length,e.length);for(n=0;o>n;++n)r.push(_r(t[n],e[n]));for(;a>n;++n)i[n]=t[n];for(;u>n;++n)i[n]=e[n];return function(t){for(n=0;o>n;++n)i[n]=r[n](t);return i}}function xr(t){return function(e){return 0>=e?0:e>=1?1:t(e)}}function wr(t){return function(e){return 1-t(1-e)}}function Ar(t){return function(e){return.5*(.5>e?t(2*e):2-t(2-2*e))}}function kr(t){return t*t}function Er(t){return t*t*t}function Mr(t){if(0>=t)return 0;if(t>=1)return 1;var e=t*t,n=e*t;return 4*(.5>t?n:3*(t-e)+n-.75)}function Dr(t){return function(e){return Math.pow(e,t)}}function Cr(t){return 1-Math.cos(t*Iu)}function Sr(t){return Math.pow(2,10*(t-1))}function Tr(t){return 1-Math.sqrt(1-t*t)}function Fr(t,e){var n;return arguments.length<2&&(e=.45),arguments.length?n=e/Lu*Math.asin(1/t):(t=1,n=e/4),function(r){return 1+t*Math.pow(2,-10*r)*Math.sin((r-n)*Lu/e)}}function Br(t){return t||(t=1.70158),function(e){return e*e*((t+1)*e-t)}}function Lr(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375}function Or(t,e){t=nu.hcl(t),e=nu.hcl(e);var n=t.h,r=t.c,i=t.l,a=e.h-n,u=e.c-r,o=e.l-i;return isNaN(u)&&(u=0,r=isNaN(r)?e.c:r),isNaN(a)?(a=0,n=isNaN(n)?e.h:n):a>180?a-=360:-180>a&&(a+=360),function(t){return ht(n+a*t,r+u*t,i+o*t)+""}}function Ir(t,e){t=nu.hsl(t),e=nu.hsl(e);var n=t.h,r=t.s,i=t.l,a=e.h-n,u=e.s-r,o=e.l-i;return isNaN(u)&&(u=0,r=isNaN(r)?e.s:r),isNaN(a)?(a=0,n=isNaN(n)?e.h:n):a>180?a-=360:-180>a&&(a+=360),function(t){return ct(n+a*t,r+u*t,i+o*t)+""}}function Nr(t,e){t=nu.lab(t),e=nu.lab(e);var n=t.l,r=t.a,i=t.b,a=e.l-n,u=e.a-r,o=e.b-i;return function(t){return dt(n+a*t,r+u*t,i+o*t)+""}}function Pr(t,e){return e-=t,function(n){return Math.round(t+e*n)}}function Rr(t){var e=[t.a,t.b],n=[t.c,t.d],r=Yr(e),i=jr(e,n),a=Yr(Ur(n,e,-i))||0;e[0]*n[1]180?l+=360:l-c>180&&(c+=360),i.push({i:r.push(r.pop()+"rotate(",null,")")-2,x:mr(c,l)})):l&&r.push(r.pop()+"rotate("+l+")"),h!=f?i.push({i:r.push(r.pop()+"skewX(",null,")")-2,x:mr(h,f)}):f&&r.push(r.pop()+"skewX("+f+")"),d[0]!=p[0]||d[1]!=p[1]?(n=r.push(r.pop()+"scale(",null,",",null,")"),i.push({i:n-4,x:mr(d[0],p[0])},{i:n-2,x:mr(d[1],p[1])})):(1!=p[0]||1!=p[1])&&r.push(r.pop()+"scale("+p+")"),n=i.length,function(t){for(var e,a=-1;++a=0;)n.push(i[r])}function ei(t,e){for(var n=[t],r=[];null!=(t=n.pop());)if(r.push(t),(a=t.children)&&(i=a.length))for(var i,a,u=-1;++un;++n)(e=t[n][1])>i&&(r=n,i=e);return r}function fi(t){return t.reduce(di,0)}function di(t,e){return t+e[1]}function pi(t,e){return gi(t,Math.ceil(Math.log(e.length)/Math.LN2+1))}function gi(t,e){for(var n=-1,r=+t[0],i=(t[1]-r)/e,a=[];++n<=e;)a[n]=i*n+r;return a}function yi(t){return[nu.min(t),nu.max(t)]}function mi(t,e){return t.value-e.value}function vi(t,e){var n=t._pack_next;t._pack_next=e,e._pack_prev=t,e._pack_next=n,n._pack_prev=e}function _i(t,e){t._pack_next=e,e._pack_prev=t}function bi(t,e){var n=e.x-t.x,r=e.y-t.y,i=t.r+e.r;return.999*i*i>n*n+r*r}function xi(t){function e(t){l=Math.min(t.x-t.r,l),h=Math.max(t.x+t.r,h),f=Math.min(t.y-t.r,f),d=Math.max(t.y+t.r,d)}if((n=t.children)&&(c=n.length)){var n,r,i,a,u,o,s,c,l=1/0,h=-(1/0),f=1/0,d=-(1/0);if(n.forEach(wi),r=n[0],r.x=-r.r,r.y=0,e(r),c>1&&(i=n[1],i.x=i.r,i.y=0,e(i),c>2))for(a=n[2],Ei(r,i,a),e(a),vi(r,a),r._pack_prev=a,vi(a,i),i=r._pack_next,u=3;c>u;u++){Ei(r,i,a=n[u]);var p=0,g=1,y=1;for(o=i._pack_next;o!==i;o=o._pack_next,g++)if(bi(o,a)){p=1;break}if(1==p)for(s=r._pack_prev;s!==o._pack_prev&&!bi(s,a);s=s._pack_prev,y++);p?(y>g||g==y&&i.ru;u++)a=n[u],a.x-=m,a.y-=v,_=Math.max(_,a.r+Math.sqrt(a.x*a.x+a.y*a.y));t.r=_,n.forEach(Ai)}}function wi(t){t._pack_next=t._pack_prev=t}function Ai(t){delete t._pack_next,delete t._pack_prev}function ki(t,e,n,r){var i=t.children;if(t.x=e+=r*t.x,t.y=n+=r*t.y,t.r*=r,i)for(var a=-1,u=i.length;++a=0;)e=i[a],e.z+=n,e.m+=n,n+=e.s+(r+=e.c)}function Fi(t,e,n){return t.a.parent===e.parent?t.a:n}function Bi(t){return 1+nu.max(t,function(t){return t.y})}function Li(t){return t.reduce(function(t,e){return t+e.x},0)/t.length}function Oi(t){var e=t.children;return e&&e.length?Oi(e[0]):t}function Ii(t){var e,n=t.children;return n&&(e=n.length)?Ii(n[e-1]):t}function Ni(t){return{x:t.x,y:t.y,dx:t.dx,dy:t.dy}}function Pi(t,e){var n=t.x+e[3],r=t.y+e[0],i=t.dx-e[1]-e[3],a=t.dy-e[0]-e[2];return 0>i&&(n+=i/2,i=0),0>a&&(r+=a/2,a=0),{x:n,y:r,dx:i,dy:a}}function Ri(t){var e=t[0],n=t[t.length-1];return n>e?[e,n]:[n,e]}function ji(t){return t.rangeExtent?t.rangeExtent():Ri(t.range())}function Yi(t,e,n,r){var i=n(t[0],t[1]),a=r(e[0],e[1]);return function(t){return a(i(t))}}function Ui(t,e){var n,r=0,i=t.length-1,a=t[r],u=t[i];return a>u&&(n=r,r=i,i=n,n=a,a=u,u=n),t[r]=e.floor(a),t[i]=e.ceil(u),t}function $i(t){return t?{floor:function(e){return Math.floor(e/t)*t},ceil:function(e){return Math.ceil(e/t)*t}}:_s}function zi(t,e,n,r){var i=[],a=[],u=0,o=Math.min(t.length,e.length)-1;for(t[o]2?zi:Yi,s=r?qr:zr;return u=i(t,e,s,n),o=i(e,t,s,_r),a}function a(t){return u(t)}var u,o;return a.invert=function(t){return o(t)},a.domain=function(e){return arguments.length?(t=e.map(Number),i()):t},a.range=function(t){return arguments.length?(e=t,i()):e},a.rangeRound=function(t){return a.range(t).interpolate(Pr)},a.clamp=function(t){return arguments.length?(r=t,i()):r},a.interpolate=function(t){return arguments.length?(n=t,i()):n},a.ticks=function(e){return Vi(t,e)},a.tickFormat=function(e,n){return Xi(t,e,n)},a.nice=function(e){return Gi(t,e),i()},a.copy=function(){return qi(t,e,n,r)},i()}function Wi(t,e){return nu.rebind(t,e,"range","rangeRound","interpolate","clamp")}function Gi(t,e){return Ui(t,$i(Hi(t,e)[2]))}function Hi(t,e){null==e&&(e=10);var n=Ri(t),r=n[1]-n[0],i=Math.pow(10,Math.floor(Math.log(r/e)/Math.LN10)),a=e/r*i;return.15>=a?i*=10:.35>=a?i*=5:.75>=a&&(i*=2),n[0]=Math.ceil(n[0]/i)*i,n[1]=Math.floor(n[1]/i)*i+.5*i,n[2]=i,n}function Vi(t,e){return nu.range.apply(nu,Hi(t,e))}function Xi(t,e,n){var r=Hi(t,e);if(n){var i=uo.exec(n);if(i.shift(),"s"===i[8]){var a=nu.formatPrefix(Math.max(pu(r[0]),pu(r[1])));return i[7]||(i[7]="."+Zi(a.scale(r[2]))),i[8]="f",n=nu.format(i.join("")),function(t){return n(a.scale(t))+a.symbol}}i[7]||(i[7]="."+Ki(i[8],r)),n=i.join("")}else n=",."+Zi(r[2])+"f";return nu.format(n)}function Zi(t){return-Math.floor(Math.log(t)/Math.LN10+.01)}function Ki(t,e){var n=Zi(e[2]);return t in bs?Math.abs(n-Zi(Math.max(pu(e[0]),pu(e[1]))))+ +("e"!==t):n-2*("%"===t)}function Qi(t,e,n,r){function i(t){return(n?Math.log(0>t?0:t):-Math.log(t>0?0:-t))/Math.log(e)}function a(t){return n?Math.pow(e,t):-Math.pow(e,-t)}function u(e){return t(i(e))}return u.invert=function(e){return a(t.invert(e))},u.domain=function(e){return arguments.length?(n=e[0]>=0,t.domain((r=e.map(Number)).map(i)),u):r},u.base=function(n){return arguments.length?(e=+n,t.domain(r.map(i)),u):e},u.nice=function(){var e=Ui(r.map(i),n?Math:ws);return t.domain(e),r=e.map(a),u},u.ticks=function(){var t=Ri(r),u=[],o=t[0],s=t[1],c=Math.floor(i(o)),l=Math.ceil(i(s)),h=e%1?2:e;if(isFinite(l-c)){if(n){for(;l>c;c++)for(var f=1;h>f;f++)u.push(a(c)*f);u.push(a(c))}else for(u.push(a(c));c++0;f--)u.push(a(c)*f);for(c=0;u[c]s;l--);u=u.slice(c,l)}return u},u.tickFormat=function(t,e){if(!arguments.length)return xs;arguments.length<2?e=xs:"function"!=typeof e&&(e=nu.format(e));var r,o=Math.max(.1,t/u.ticks().length),s=n?(r=1e-12,Math.ceil):(r=-1e-12,Math.floor);return function(t){return t/a(s(i(t)+r))<=o?e(t):""}},u.copy=function(){return Qi(t.copy(),e,n,r)},Wi(u,t)}function Ji(t,e,n){function r(e){return t(i(e))}var i=ta(e),a=ta(1/e);return r.invert=function(e){return a(t.invert(e))},r.domain=function(e){return arguments.length?(t.domain((n=e.map(Number)).map(i)),r):n},r.ticks=function(t){return Vi(n,t)},r.tickFormat=function(t,e){return Xi(n,t,e)},r.nice=function(t){return r.domain(Gi(n,t))},r.exponent=function(u){return arguments.length?(i=ta(e=u),a=ta(1/e),t.domain(n.map(i)),r):e},r.copy=function(){return Ji(t.copy(),e,n)},Wi(r,t)}function ta(t){return function(e){return 0>e?-Math.pow(-e,t):Math.pow(e,t)}}function ea(t,e){function n(n){return a[((i.get(n)||("range"===e.t?i.set(n,t.push(n)):0/0))-1)%a.length]}function r(e,n){return nu.range(t.length).map(function(t){return e+n*t})}var i,a,u;return n.domain=function(r){if(!arguments.length)return t;t=[],i=new l;for(var a,u=-1,o=r.length;++un?[0/0,0/0]:[n>0?o[n-1]:t[0],ne?0/0:e/a+t,[e,e+1/a]},r.copy=function(){return ra(t,e,n)},i()}function ia(t,e){function n(n){return n>=n?e[nu.bisect(t,n)]:void 0}return n.domain=function(e){return arguments.length?(t=e,n):t},n.range=function(t){return arguments.length?(e=t,n):e},n.invertExtent=function(n){return n=e.indexOf(n),[t[n-1],t[n]]},n.copy=function(){return ia(t,e)},n}function aa(t){function e(t){return+t}return e.invert=e,e.domain=e.range=function(n){return arguments.length?(t=n.map(e),e):t},e.ticks=function(e){return Vi(t,e)},e.tickFormat=function(e,n){return Xi(t,e,n)},e.copy=function(){return aa(t)},e}function ua(){return 0}function oa(t){return t.innerRadius}function sa(t){return t.outerRadius}function ca(t){return t.startAngle}function la(t){return t.endAngle}function ha(t){return t&&t.padAngle}function fa(t,e,n,r){return(t-n)*e-(e-r)*t>0?0:1}function da(t,e,n,r,i){var a=t[0]-e[0],u=t[1]-e[1],o=(i?r:-r)/Math.sqrt(a*a+u*u),s=o*u,c=-o*a,l=t[0]+s,h=t[1]+c,f=e[0]+s,d=e[1]+c,p=(l+f)/2,g=(h+d)/2,y=f-l,m=d-h,v=y*y+m*m,_=n-r,b=l*d-f*h,x=(0>m?-1:1)*Math.sqrt(_*_*v-b*b),w=(b*m-y*x)/v,A=(-b*y-m*x)/v,k=(b*m+y*x)/v,E=(-b*y+m*x)/v,M=w-p,D=A-g,C=k-p,S=E-g;return M*M+D*D>C*C+S*S&&(w=k,A=E),[[w-s,A-c],[w*n/_,A*n/_]]}function pa(t){function e(e){function u(){c.push("M",a(t(l),o))}for(var s,c=[],l=[],h=-1,f=e.length,d=Dt(n),p=Dt(r);++h1&&i.push("H",r[0]),i.join("")}function va(t){for(var e=0,n=t.length,r=t[0],i=[r[0],",",r[1]];++e1){o=e[1],a=t[s],s++,r+="C"+(i[0]+u[0])+","+(i[1]+u[1])+","+(a[0]-o[0])+","+(a[1]-o[1])+","+a[0]+","+a[1];for(var c=2;c9&&(i=3*e/Math.sqrt(i),u[o]=i*n,u[o+1]=i*r));for(o=-1;++o<=s;)i=(t[Math.min(s,o+1)][0]-t[Math.max(0,o-1)][0])/(6*(1+u[o]*u[o])),a.push([i||0,u[o]*i||0]);return a}function Oa(t){return t.length<3?ga(t):t[0]+Aa(t,La(t))}function Ia(t){for(var e,n,r,i=-1,a=t.length;++ir)return l();var i=a[a.active];i&&(--a.count,delete a[a.active],i.event&&i.event.interrupt.call(t,t.__data__,i.index)),a.active=r,u.event&&u.event.start.call(t,t.__data__,e),u.tween.forEach(function(n,r){(r=r.call(t,t.__data__,e))&&g.push(r)}),f=u.ease,h=u.duration,nu.timer(function(){return p.c=c(n||1)?Se:c,1},0,o)}function c(n){if(a.active!==r)return 1;for(var i=n/h,o=f(i),s=g.length;s>0;)g[--s].call(t,o);return i>=1?(u.event&&u.event.end.call(t,t.__data__,e),l()):void 0}function l(){return--a.count?delete a[r]:delete t[n],1}var h,f,d=u.delay,p=ro,g=[];return p.t=d+o,i>=d?s(i-d):void(p.c=s)},0,o)}}function Xa(t,e,n){t.attr("transform",function(t){var r=e(t);return"translate("+(isFinite(r)?r:n(t))+",0)"})}function Za(t,e,n){t.attr("transform",function(t){var r=e(t);return"translate(0,"+(isFinite(r)?r:n(t))+")"})}function Ka(t){return t.toISOString()}function Qa(t,e,n){function r(e){return t(e)}function i(t,n){var r=t[1]-t[0],i=r/n,a=nu.bisect(Hs,i);return a==Hs.length?[e.year,Hi(t.map(function(t){return t/31536e6}),n)[2]]:a?e[i/Hs[a-1]1?{floor:function(e){for(;n(e=t.floor(e));)e=Ja(e-1);return e},ceil:function(e){for(;n(e=t.ceil(e));)e=Ja(+e+1);return e}}:t))},r.ticks=function(t,e){var n=Ri(r.domain()),a=null==t?i(n,10):"number"==typeof t?i(n,t):!t.range&&[{range:t},e];return a&&(t=a[0],e=a[1]),t.range(n[0],Ja(+n[1]+1),1>e?1:e)},r.tickFormat=function(){return n},r.copy=function(){return Qa(t.copy(),e,n)},Wi(r,t)}function Ja(t){return new Date(t)}function tu(t){return JSON.parse(t.responseText)}function eu(t){var e=au.createRange();return e.selectNode(au.body),e.createContextualFragment(t.responseText)}var nu={version:"3.5.6"},ru=[].slice,iu=function(t){return ru.call(t)},au=this.document;if(au)try{iu(au.documentElement.childNodes)[0].nodeType}catch(uu){iu=function(t){for(var e=t.length,n=new Array(e);e--;)n[e]=t[e];return n}}if(Date.now||(Date.now=function(){return+new Date}),au)try{au.createElement("DIV").style.setProperty("opacity",0,"")}catch(ou){var su=this.Element.prototype,cu=su.setAttribute,lu=su.setAttributeNS,hu=this.CSSStyleDeclaration.prototype,fu=hu.setProperty;su.setAttribute=function(t,e){cu.call(this,t,e+"")},su.setAttributeNS=function(t,e,n){lu.call(this,t,e,n+"")},hu.setProperty=function(t,e,n){fu.call(this,t,e+"",n)}}nu.ascending=r,nu.descending=function(t,e){return t>e?-1:e>t?1:e>=t?0:0/0},nu.min=function(t,e){var n,r,i=-1,a=t.length;if(1===arguments.length){for(;++i=r){n=r;break}for(;++ir&&(n=r)}else{for(;++i=r){n=r;break}for(;++ir&&(n=r)}return n},nu.max=function(t,e){var n,r,i=-1,a=t.length;if(1===arguments.length){for(;++i=r){n=r;break}for(;++in&&(n=r)}else{for(;++i=r){n=r;break}for(;++in&&(n=r)}return n},nu.extent=function(t,e){var n,r,i,a=-1,u=t.length;if(1===arguments.length){for(;++a=r){n=i=r;break}for(;++ar&&(n=r),r>i&&(i=r))}else{for(;++a=r){n=i=r;break}for(;++ar&&(n=r),r>i&&(i=r))}return[n,i]},nu.sum=function(t,e){var n,r=0,i=t.length,u=-1;if(1===arguments.length)for(;++u1?s/(l-1):void 0},nu.deviation=function(){var t=nu.variance.apply(this,arguments);return t?Math.sqrt(t):t};var du=u(r);nu.bisectLeft=du.left,nu.bisect=nu.bisectRight=du.right,nu.bisector=function(t){return u(1===t.length?function(e,n){return r(t(e),n)}:t)},nu.shuffle=function(t,e,n){(a=arguments.length)<3&&(n=t.length,2>a&&(e=0));for(var r,i,a=n-e;a;)i=Math.random()*a--|0,r=t[a+e],t[a+e]=t[i+e],t[i+e]=r;return t},nu.permute=function(t,e){for(var n=e.length,r=new Array(n);n--;)r[n]=t[e[n]];return r},nu.pairs=function(t){for(var e,n=0,r=t.length-1,i=t[0],a=new Array(0>r?0:r);r>n;)a[n]=[e=i,i=t[++n]];return a},nu.zip=function(){if(!(r=arguments.length))return[];for(var t=-1,e=nu.min(arguments,o),n=new Array(e);++t=0;)for(r=t[i],e=r.length;--e>=0;)n[--u]=r[e];return n};var pu=Math.abs;nu.range=function(t,e,n){if(arguments.length<3&&(n=1,arguments.length<2&&(e=t,t=0)),(e-t)/n===1/0)throw new Error("infinite range");var r,i=[],a=s(pu(n)),u=-1;if(t*=a,e*=a,n*=a,0>n)for(;(r=t+n*++u)>e;)i.push(r/a);else for(;(r=t+n*++u)=a.length)return r?r.call(i,u):n?u.sort(n):u;for(var s,c,h,f,d=-1,p=u.length,g=a[o++],y=new l;++d=a.length)return t;var r=[],i=u[n++];return t.forEach(function(t,i){r.push({key:t,values:e(i,n)})}),i?r.sort(function(t,e){return i(t.key,e.key)}):r}var n,r,i={},a=[],u=[];return i.map=function(e,n){return t(n,e,0)},i.entries=function(n){return e(t(nu.map,n,0),0)},i.key=function(t){return a.push(t),i},i.sortKeys=function(t){return u[a.length-1]=t,i},i.sortValues=function(t){return n=t,i},i.rollup=function(t){return r=t,i},i},nu.set=function(t){var e=new v;if(t)for(var n=0,r=t.length;r>n;++n)e.add(t[n]);return e},c(v,{has:d,add:function(t){return this._[h(t+="")]=!0,t},remove:p,values:g,size:y,empty:m,forEach:function(t){for(var e in this._)t.call(this,f(e))}}),nu.behavior={},nu.rebind=function(t,e){for(var n,r=1,i=arguments.length;++r=0&&(r=t.slice(n+1),t=t.slice(0,n)),t)return arguments.length<2?this[t].on(r):this[t].on(r,e);if(2===arguments.length){if(null==e)for(t in this)this.hasOwnProperty(t)&&this[t].on(r,null);return this}},nu.event=null,nu.requote=function(t){return t.replace(vu,"\\$&")};var vu=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,_u={}.__proto__?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)t[n]=e[n]},bu=function(t,e){return e.querySelector(t)},xu=function(t,e){return e.querySelectorAll(t)},wu=function(t,e){var n=t.matches||t[x(t,"matchesSelector")];return(wu=function(t,e){return n.call(t,e)})(t,e)};"function"==typeof Sizzle&&(bu=function(t,e){return Sizzle(t,e)[0]||null},xu=Sizzle,wu=Sizzle.matchesSelector),nu.selection=function(){return nu.select(au.documentElement)};var Au=nu.selection.prototype=[];Au.select=function(t){var e,n,r,i,a=[];t=S(t);for(var u=-1,o=this.length;++u=0&&(n=t.slice(0,e),t=t.slice(e+1)),ku.hasOwnProperty(n)?{space:ku[n],local:t}:t}},Au.attr=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node();return t=nu.ns.qualify(t),t.local?n.getAttributeNS(t.space,t.local):n.getAttribute(t)}for(e in t)this.each(F(e,t[e]));return this}return this.each(F(t,e))},Au.classed=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node(),r=(t=O(t)).length,i=-1;if(e=n.classList){for(;++ii){if("string"!=typeof t){2>i&&(e="");for(r in t)this.each(P(r,t[r],e));return this}if(2>i){var a=this.node();return n(a).getComputedStyle(a,null).getPropertyValue(t)}r=""}return this.each(P(t,e,r))},Au.property=function(t,e){if(arguments.length<2){if("string"==typeof t)return this.node()[t];for(e in t)this.each(R(e,t[e]));return this}return this.each(R(t,e))},Au.text=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}:null==t?function(){this.textContent=""}:function(){this.textContent=t}):this.node().textContent},Au.html=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}:null==t?function(){this.innerHTML=""}:function(){this.innerHTML=t}):this.node().innerHTML},Au.append=function(t){return t=j(t),this.select(function(){return this.appendChild(t.apply(this,arguments))})},Au.insert=function(t,e){return t=j(t),e=S(e),this.select(function(){return this.insertBefore(t.apply(this,arguments),e.apply(this,arguments)||null)})},Au.remove=function(){return this.each(Y)},Au.data=function(t,e){function n(t,n){var r,i,a,u=t.length,h=n.length,f=Math.min(u,h),d=new Array(h),p=new Array(h),g=new Array(u);if(e){var y,m=new l,v=new Array(u);for(r=-1;++rr;++r)p[r]=U(n[r]);for(;u>r;++r)g[r]=t[r]}p.update=d,p.parentNode=d.parentNode=g.parentNode=t.parentNode,o.push(p),s.push(d),c.push(g)}var r,i,a=-1,u=this.length;if(!arguments.length){for(t=new Array(u=(r=this[0]).length);++aa;a++){i.push(e=[]),e.parentNode=(n=this[a]).parentNode;for(var o=0,s=n.length;s>o;o++)(r=n[o])&&t.call(r,r.__data__,o,a)&&e.push(r)}return C(i)},Au.order=function(){for(var t=-1,e=this.length;++t=0;)(n=r[i])&&(a&&a!==n.nextSibling&&a.parentNode.insertBefore(n,a),a=n);return this},Au.sort=function(t){t=z.apply(this,arguments);for(var e=-1,n=this.length;++et;t++)for(var n=this[t],r=0,i=n.length;i>r;r++){var a=n[r];if(a)return a}return null},Au.size=function(){var t=0;return q(this,function(){++t}),t};var Eu=[];nu.selection.enter=W,nu.selection.enter.prototype=Eu,Eu.append=Au.append,Eu.empty=Au.empty,Eu.node=Au.node,Eu.call=Au.call,Eu.size=Au.size,Eu.select=function(t){for(var e,n,r,i,a,u=[],o=-1,s=this.length;++or){if("string"!=typeof t){2>r&&(e=!1);for(n in t)this.each(H(n,t[n],e));return this}if(2>r)return(r=this.node()["__on"+t])&&r._;n=!1}return this.each(H(t,e,n))};var Mu=nu.map({mouseenter:"mouseover",mouseleave:"mouseout"});au&&Mu.forEach(function(t){"on"+t in au&&Mu.remove(t)});var Du,Cu=0;nu.mouse=function(t){return K(t,M())};var Su=this.navigator&&/WebKit/.test(this.navigator.userAgent)?-1:0;nu.touch=function(t,e,n){if(arguments.length<3&&(n=e,e=M().changedTouches),e)for(var r,i=0,a=e.length;a>i;++i)if((r=e[i]).identifier===n)return K(t,r)},nu.behavior.drag=function(){function t(){this.on("mousedown.drag",a).on("touchstart.drag",u)}function e(t,e,n,a,u){return function(){function o(){var t,n,r=e(f,g);r&&(t=r[0]-_[0],n=r[1]-_[1],p|=t|n,_=r,d({type:"drag",x:r[0]+c[0],y:r[1]+c[1],dx:t,dy:n}))}function s(){e(f,g)&&(m.on(a+y,null).on(u+y,null),v(p&&nu.event.target===h),d({type:"dragend"}))}var c,l=this,h=nu.event.target,f=l.parentNode,d=r.of(l,arguments),p=0,g=t(),y=".drag"+(null==g?"":"-"+g),m=nu.select(n(h)).on(a+y,o).on(u+y,s),v=Z(h),_=e(f,g);i?(c=i.apply(l,arguments),c=[c.x-_[0],c.y-_[1]]):c=[0,0],d({type:"dragstart"})}}var r=D(t,"drag","dragstart","dragend"),i=null,a=e(w,nu.mouse,n,"mousemove","mouseup"),u=e(Q,nu.touch,_,"touchmove","touchend");return t.origin=function(e){return arguments.length?(i=e,t):i},nu.rebind(t,r,"on")},nu.touches=function(t,e){return arguments.length<2&&(e=M().touches),e?iu(e).map(function(e){var n=K(t,e);return n.identifier=e.identifier,n}):[]};var Tu=1e-6,Fu=Tu*Tu,Bu=Math.PI,Lu=2*Bu,Ou=Lu-Tu,Iu=Bu/2,Nu=Bu/180,Pu=180/Bu,Ru=Math.SQRT2,ju=2,Yu=4;nu.interpolateZoom=function(t,e){function n(t){var e=t*v;if(m){var n=it(g),u=a/(ju*f)*(n*at(Ru*e+g)-rt(g));return[r+u*c,i+u*l,a*n/it(Ru*e+g)]}return[r+t*c,i+t*l,a*Math.exp(Ru*e)]}var r=t[0],i=t[1],a=t[2],u=e[0],o=e[1],s=e[2],c=u-r,l=o-i,h=c*c+l*l,f=Math.sqrt(h),d=(s*s-a*a+Yu*h)/(2*a*ju*f),p=(s*s-a*a-Yu*h)/(2*s*ju*f),g=Math.log(Math.sqrt(d*d+1)-d),y=Math.log(Math.sqrt(p*p+1)-p),m=y-g,v=(m||Math.log(s/a))/Ru;return n.duration=1e3*v,n},nu.behavior.zoom=function(){function t(t){t.on(F,h).on($u+".zoom",d).on("dblclick.zoom",p).on(O,f)}function e(t){return[(t[0]-k.x)/k.k,(t[1]-k.y)/k.k]}function r(t){return[t[0]*k.k+k.x,t[1]*k.k+k.y]}function i(t){k.k=Math.max(C[0],Math.min(C[1],t))}function a(t,e){e=r(e),k.x+=t[0]-e[0],k.y+=t[1]-e[1]}function u(e,n,r,u){e.__chart__={x:k.x,y:k.y,k:k.k},i(Math.pow(2,u)),a(y=n,r),e=nu.select(e),S>0&&(e=e.transition().duration(S)),e.call(t.event)}function o(){x&&x.domain(b.range().map(function(t){return(t-k.x)/k.k}).map(b.invert)),A&&A.domain(w.range().map(function(t){return(t-k.y)/k.k}).map(w.invert))}function s(t){T++||t({type:"zoomstart"})}function c(t){o(),t({type:"zoom",scale:k.k,translate:[k.x,k.y]})}function l(t){--T||(t({type:"zoomend"}),y=null)}function h(){function t(){h=1,a(nu.mouse(i),d),c(o)}function r(){f.on(B,null).on(L,null),p(h&&nu.event.target===u),l(o)}var i=this,u=nu.event.target,o=I.of(i,arguments),h=0,f=nu.select(n(i)).on(B,t).on(L,r),d=e(nu.mouse(i)),p=Z(i);Ps.call(i),s(o)}function f(){function t(){var t=nu.touches(p);return d=k.k,t.forEach(function(t){t.identifier in y&&(y[t.identifier]=e(t))}),t}function n(){var e=nu.event.target;nu.select(e).on(b,r).on(x,o),w.push(e);for(var n=nu.event.changedTouches,i=0,a=n.length;a>i;++i)y[n[i].identifier]=null;var s=t(),c=Date.now();if(1===s.length){if(500>c-_){var l=s[0];u(p,l,y[l.identifier],Math.floor(Math.log(k.k)/Math.LN2)+1),E()}_=c}else if(s.length>1){var l=s[0],h=s[1],f=l[0]-h[0],d=l[1]-h[1];m=f*f+d*d}}function r(){var t,e,n,r,u=nu.touches(p);Ps.call(p);for(var o=0,s=u.length;s>o;++o,r=null)if(n=u[o],r=y[n.identifier]){if(e)break;t=n,e=r}if(r){var l=(l=n[0]-t[0])*l+(l=n[1]-t[1])*l,h=m&&Math.sqrt(l/m);t=[(t[0]+n[0])/2,(t[1]+n[1])/2],e=[(e[0]+r[0])/2,(e[1]+r[1])/2],i(h*d)}_=null,a(t,e),c(g)}function o(){if(nu.event.touches.length){for(var e=nu.event.changedTouches,n=0,r=e.length;r>n;++n)delete y[e[n].identifier];for(var i in y)return void t()}nu.selectAll(w).on(v,null),A.on(F,h).on(O,f),M(),l(g)}var d,p=this,g=I.of(p,arguments),y={},m=0,v=".zoom-"+nu.event.changedTouches[0].identifier,b="touchmove"+v,x="touchend"+v,w=[],A=nu.select(p),M=Z(p);n(),s(g),A.on(F,null).on(O,n)}function d(){var t=I.of(this,arguments);v?clearTimeout(v):(Ps.call(this),g=e(y=m||nu.mouse(this)),s(t)),v=setTimeout(function(){v=null,l(t)},50),E(),i(Math.pow(2,.002*Uu())*k.k),a(y,g),c(t)}function p(){var t=nu.mouse(this),n=Math.log(k.k)/Math.LN2;u(this,t,e(t),nu.event.shiftKey?Math.ceil(n)-1:Math.floor(n)+1)}var g,y,m,v,_,b,x,w,A,k={x:0,y:0,k:1},M=[960,500],C=zu,S=250,T=0,F="mousedown.zoom",B="mousemove.zoom",L="mouseup.zoom",O="touchstart.zoom",I=D(t,"zoomstart","zoom","zoomend");return $u||($u="onwheel"in au?(Uu=function(){return-nu.event.deltaY*(nu.event.deltaMode?120:1)},"wheel"):"onmousewheel"in au?(Uu=function(){return nu.event.wheelDelta},"mousewheel"):(Uu=function(){return-nu.event.detail},"MozMousePixelScroll")),t.event=function(t){t.each(function(){var t=I.of(this,arguments),e=k;Is?nu.select(this).transition().each("start.zoom",function(){k=this.__chart__||{x:0,y:0,k:1},s(t)}).tween("zoom:zoom",function(){var n=M[0],r=M[1],i=y?y[0]:n/2,a=y?y[1]:r/2,u=nu.interpolateZoom([(i-k.x)/k.k,(a-k.y)/k.k,n/k.k],[(i-e.x)/e.k,(a-e.y)/e.k,n/e.k]);return function(e){var r=u(e),o=n/r[2];this.__chart__=k={x:i-r[0]*o,y:a-r[1]*o,k:o},c(t)}}).each("interrupt.zoom",function(){l(t)}).each("end.zoom",function(){l(t)}):(this.__chart__=k,s(t),c(t),l(t))})},t.translate=function(e){return arguments.length?(k={x:+e[0],y:+e[1],k:k.k},o(),t):[k.x,k.y]},t.scale=function(e){return arguments.length?(k={x:k.x,y:k.y,k:+e},o(),t):k.k},t.scaleExtent=function(e){return arguments.length?(C=null==e?zu:[+e[0],+e[1]],t):C},t.center=function(e){return arguments.length?(m=e&&[+e[0],+e[1]],t):m},t.size=function(e){return arguments.length?(M=e&&[+e[0],+e[1]],t):M},t.duration=function(e){return arguments.length?(S=+e,t):S},t.x=function(e){return arguments.length?(x=e,b=e.copy(),k={x:0,y:0,k:1},t):x},t.y=function(e){return arguments.length?(A=e,w=e.copy(),k={x:0,y:0,k:1},t):A},nu.rebind(t,I,"on")};var Uu,$u,zu=[0,1/0];nu.color=ot,ot.prototype.toString=function(){return this.rgb()+""},nu.hsl=st;var qu=st.prototype=new ot;qu.brighter=function(t){return t=Math.pow(.7,arguments.length?t:1),new st(this.h,this.s,this.l/t)},qu.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new st(this.h,this.s,t*this.l)},qu.rgb=function(){return ct(this.h,this.s,this.l)},nu.hcl=lt;var Wu=lt.prototype=new ot;Wu.brighter=function(t){return new lt(this.h,this.c,Math.min(100,this.l+Gu*(arguments.length?t:1)))},Wu.darker=function(t){return new lt(this.h,this.c,Math.max(0,this.l-Gu*(arguments.length?t:1)))},Wu.rgb=function(){return ht(this.h,this.c,this.l).rgb()},nu.lab=ft;var Gu=18,Hu=.95047,Vu=1,Xu=1.08883,Zu=ft.prototype=new ot;Zu.brighter=function(t){return new ft(Math.min(100,this.l+Gu*(arguments.length?t:1)),this.a,this.b)},Zu.darker=function(t){return new ft(Math.max(0,this.l-Gu*(arguments.length?t:1)),this.a,this.b)},Zu.rgb=function(){return dt(this.l,this.a,this.b)},nu.rgb=vt;var Ku=vt.prototype=new ot;Ku.brighter=function(t){t=Math.pow(.7,arguments.length?t:1);var e=this.r,n=this.g,r=this.b,i=30;return e||n||r?(e&&i>e&&(e=i),n&&i>n&&(n=i),r&&i>r&&(r=i),new vt(Math.min(255,e/t),Math.min(255,n/t),Math.min(255,r/t))):new vt(i,i,i)},Ku.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new vt(t*this.r,t*this.g,t*this.b)},Ku.hsl=function(){return At(this.r,this.g,this.b)},Ku.toString=function(){return"#"+xt(this.r)+xt(this.g)+xt(this.b)};var Qu=nu.map({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});Qu.forEach(function(t,e){Qu.set(t,_t(e))}),nu.functor=Dt,nu.xhr=Ct(_),nu.dsv=function(t,e){function n(t,n,a){arguments.length<3&&(a=n,n=null);var u=St(t,e,null==n?r:i(n),a);return u.row=function(t){return arguments.length?u.response(null==(n=t)?r:i(t)):n},u}function r(t){return n.parse(t.responseText)}function i(t){return function(e){return n.parse(e.responseText,t)}}function a(e){return e.map(u).join(t)}function u(t){return o.test(t)?'"'+t.replace(/\"/g,'""')+'"':t}var o=new RegExp('["'+t+"\n]"),s=t.charCodeAt(0);return n.parse=function(t,e){var r;return n.parseRows(t,function(t,n){if(r)return r(t,n-1);var i=new Function("d","return {"+t.map(function(t,e){return JSON.stringify(t)+": d["+e+"]"}).join(",")+"}");r=e?function(t,n){return e(i(t),n)}:i})},n.parseRows=function(t,e){function n(){if(l>=c)return u;if(i)return i=!1,a;var e=l;if(34===t.charCodeAt(e)){for(var n=e;n++l;){var r=t.charCodeAt(l++),o=1;if(10===r)i=!0;else if(13===r)i=!0,10===t.charCodeAt(l)&&(++l,++o);else if(r!==s)continue;return t.slice(e,l-o)}return t.slice(e)}for(var r,i,a={},u={},o=[],c=t.length,l=0,h=0;(r=n())!==u;){for(var f=[];r!==a&&r!==u;)f.push(r),r=n();e&&null==(f=e(f,h++))||o.push(f)}return o},n.format=function(e){if(Array.isArray(e[0]))return n.formatRows(e);var r=new v,i=[];return e.forEach(function(t){for(var e in t)r.has(e)||i.push(r.add(e))}),[i.map(u).join(t)].concat(e.map(function(e){return i.map(function(t){return u(e[t])}).join(t)})).join("\n")},n.formatRows=function(t){return t.map(a).join("\n")},n},nu.csv=nu.dsv(",","text/csv"),nu.tsv=nu.dsv(" ","text/tab-separated-values");var Ju,to,eo,no,ro,io=this[x(this,"requestAnimationFrame")]||function(t){setTimeout(t,17)};nu.timer=function(t,e,n){var r=arguments.length;2>r&&(e=0),3>r&&(n=Date.now());var i=n+e,a={c:t,t:i,f:!1,n:null};to?to.n=a:Ju=a, -to=a,eo||(no=clearTimeout(no),eo=1,io(Bt))},nu.timer.flush=function(){Lt(),Ot()},nu.round=function(t,e){return e?Math.round(t*(e=Math.pow(10,e)))/e:Math.round(t)};var ao=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"].map(Nt);nu.formatPrefix=function(t,e){var n=0;return t&&(0>t&&(t*=-1),e&&(t=nu.round(t,It(t,e))),n=1+Math.floor(1e-12+Math.log(t)/Math.LN10),n=Math.max(-24,Math.min(24,3*Math.floor((n-1)/3)))),ao[8+n/3]};var uo=/(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i,oo=nu.map({b:function(t){return t.toString(2)},c:function(t){return String.fromCharCode(t)},o:function(t){return t.toString(8)},x:function(t){return t.toString(16)},X:function(t){return t.toString(16).toUpperCase()},g:function(t,e){return t.toPrecision(e)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},r:function(t,e){return(t=nu.round(t,It(t,e))).toFixed(Math.max(0,Math.min(20,It(t*(1+1e-15),e))))}}),so=nu.time={},co=Date;jt.prototype={getDate:function(){return this._.getUTCDate()},getDay:function(){return this._.getUTCDay()},getFullYear:function(){return this._.getUTCFullYear()},getHours:function(){return this._.getUTCHours()},getMilliseconds:function(){return this._.getUTCMilliseconds()},getMinutes:function(){return this._.getUTCMinutes()},getMonth:function(){return this._.getUTCMonth()},getSeconds:function(){return this._.getUTCSeconds()},getTime:function(){return this._.getTime()},getTimezoneOffset:function(){return 0},valueOf:function(){return this._.valueOf()},setDate:function(){lo.setUTCDate.apply(this._,arguments)},setDay:function(){lo.setUTCDay.apply(this._,arguments)},setFullYear:function(){lo.setUTCFullYear.apply(this._,arguments)},setHours:function(){lo.setUTCHours.apply(this._,arguments)},setMilliseconds:function(){lo.setUTCMilliseconds.apply(this._,arguments)},setMinutes:function(){lo.setUTCMinutes.apply(this._,arguments)},setMonth:function(){lo.setUTCMonth.apply(this._,arguments)},setSeconds:function(){lo.setUTCSeconds.apply(this._,arguments)},setTime:function(){lo.setTime.apply(this._,arguments)}};var lo=Date.prototype;so.year=Yt(function(t){return t=so.day(t),t.setMonth(0,1),t},function(t,e){t.setFullYear(t.getFullYear()+e)},function(t){return t.getFullYear()}),so.years=so.year.range,so.years.utc=so.year.utc.range,so.day=Yt(function(t){var e=new co(2e3,0);return e.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()),e},function(t,e){t.setDate(t.getDate()+e)},function(t){return t.getDate()-1}),so.days=so.day.range,so.days.utc=so.day.utc.range,so.dayOfYear=function(t){var e=so.year(t);return Math.floor((t-e-6e4*(t.getTimezoneOffset()-e.getTimezoneOffset()))/864e5)},["sunday","monday","tuesday","wednesday","thursday","friday","saturday"].forEach(function(t,e){e=7-e;var n=so[t]=Yt(function(t){return(t=so.day(t)).setDate(t.getDate()-(t.getDay()+e)%7),t},function(t,e){t.setDate(t.getDate()+7*Math.floor(e))},function(t){var n=so.year(t).getDay();return Math.floor((so.dayOfYear(t)+(n+e)%7)/7)-(n!==e)});so[t+"s"]=n.range,so[t+"s"].utc=n.utc.range,so[t+"OfYear"]=function(t){var n=so.year(t).getDay();return Math.floor((so.dayOfYear(t)+(n+e)%7)/7)}}),so.week=so.sunday,so.weeks=so.sunday.range,so.weeks.utc=so.sunday.utc.range,so.weekOfYear=so.sundayOfYear;var ho={"-":"",_:" ",0:"0"},fo=/^\s*\d+/,po=/^%/;nu.locale=function(t){return{numberFormat:Pt(t),timeFormat:$t(t)}};var go=nu.locale({decimal:".",thousands:",",grouping:[3],currency:["$",""],dateTime:"%a %b %e %X %Y",date:"%m/%d/%Y",time:"%H:%M:%S",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"]});nu.format=go.numberFormat,nu.geo={},ce.prototype={s:0,t:0,add:function(t){le(t,this.t,yo),le(yo.s,this.s,this),this.s?this.t+=yo.t:this.s=yo.t},reset:function(){this.s=this.t=0},valueOf:function(){return this.s}};var yo=new ce;nu.geo.stream=function(t,e){t&&mo.hasOwnProperty(t.type)?mo[t.type](t,e):he(t,e)};var mo={Feature:function(t,e){he(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++rt?4*Bu+t:t,xo.lineStart=xo.lineEnd=xo.point=w}};nu.geo.bounds=function(){function t(t,e){_.push(b=[l=t,f=t]),h>e&&(h=e),e>d&&(d=e)}function e(e,n){var r=ge([e*Nu,n*Nu]);if(m){var i=me(m,r),a=[i[1],-i[0],0],u=me(a,i);be(u),u=xe(u);var s=e-p,c=s>0?1:-1,g=u[0]*Pu*c,y=pu(s)>180;if(y^(g>c*p&&c*e>g)){var v=u[1]*Pu;v>d&&(d=v)}else if(g=(g+360)%360-180,y^(g>c*p&&c*e>g)){var v=-u[1]*Pu;h>v&&(h=v)}else h>n&&(h=n),n>d&&(d=n);y?p>e?o(l,e)>o(l,f)&&(f=e):o(e,f)>o(l,f)&&(l=e):f>=l?(l>e&&(l=e),e>f&&(f=e)):e>p?o(l,e)>o(l,f)&&(f=e):o(e,f)>o(l,f)&&(l=e)}else t(e,n);m=r,p=e}function n(){x.point=e}function r(){b[0]=l,b[1]=f,x.point=t,m=null}function i(t,n){if(m){var r=t-p;v+=pu(r)>180?r+(r>0?360:-360):r}else g=t,y=n;xo.point(t,n),e(t,n)}function a(){xo.lineStart()}function u(){i(g,y),xo.lineEnd(),pu(v)>Tu&&(l=-(f=180)),b[0]=l,b[1]=f,m=null}function o(t,e){return(e-=t)<0?e+360:e}function s(t,e){return t[0]-e[0]}function c(t,e){return e[0]<=e[1]?e[0]<=t&&t<=e[1]:tbo?(l=-(f=180),h=-(d=90)):v>Tu?d=90:-Tu>v&&(h=-90),b[0]=l,b[1]=f}};return function(t){d=f=-(l=h=1/0),_=[],nu.geo.stream(t,x);var e=_.length;if(e){_.sort(s);for(var n,r=1,i=_[0],a=[i];e>r;++r)n=_[r],c(n[0],i)||c(n[1],i)?(o(i[0],n[1])>o(i[0],i[1])&&(i[1]=n[1]),o(n[0],i[1])>o(i[0],i[1])&&(i[0]=n[0])):a.push(i=n);for(var u,n,p=-(1/0),e=a.length-1,r=0,i=a[e];e>=r;i=n,++r)n=a[r],(u=o(i[1],n[0]))>p&&(p=u,l=n[0],f=i[1])}return _=b=null,l===1/0||h===1/0?[[0/0,0/0],[0/0,0/0]]:[[l,h],[f,d]]}}(),nu.geo.centroid=function(t){wo=Ao=ko=Eo=Mo=Do=Co=So=To=Fo=Bo=0,nu.geo.stream(t,Lo);var e=To,n=Fo,r=Bo,i=e*e+n*n+r*r;return Fu>i&&(e=Do,n=Co,r=So,Tu>Ao&&(e=ko,n=Eo,r=Mo),i=e*e+n*n+r*r,Fu>i)?[0/0,0/0]:[Math.atan2(n,e)*Pu,nt(r/Math.sqrt(i))*Pu]};var wo,Ao,ko,Eo,Mo,Do,Co,So,To,Fo,Bo,Lo={sphere:w,point:Ae,lineStart:Ee,lineEnd:Me,polygonStart:function(){Lo.lineStart=De},polygonEnd:function(){Lo.lineStart=Ee}},Oo=Le(Se,Pe,je,[-Bu,-Bu/2]),Io=1e9;nu.geo.clipExtent=function(){var t,e,n,r,i,a,u={stream:function(t){return i&&(i.valid=!1),i=a(t),i.valid=!0,i},extent:function(o){return arguments.length?(a=ze(t=+o[0][0],e=+o[0][1],n=+o[1][0],r=+o[1][1]),i&&(i.valid=!1,i=null),u):[[t,e],[n,r]]}};return u.extent([[0,0],[960,500]])},(nu.geo.conicEqualArea=function(){return qe(We)}).raw=We,nu.geo.albers=function(){return nu.geo.conicEqualArea().rotate([96,0]).center([-.6,38.7]).parallels([29.5,45.5]).scale(1070)},nu.geo.albersUsa=function(){function t(t){var a=t[0],u=t[1];return e=null,n(a,u),e||(r(a,u),e)||i(a,u),e}var e,n,r,i,a=nu.geo.albers(),u=nu.geo.conicEqualArea().rotate([154,0]).center([-2,58.5]).parallels([55,65]),o=nu.geo.conicEqualArea().rotate([157,0]).center([-3,19.9]).parallels([8,18]),s={point:function(t,n){e=[t,n]}};return t.invert=function(t){var e=a.scale(),n=a.translate(),r=(t[0]-n[0])/e,i=(t[1]-n[1])/e;return(i>=.12&&.234>i&&r>=-.425&&-.214>r?u:i>=.166&&.234>i&&r>=-.214&&-.115>r?o:a).invert(t)},t.stream=function(t){var e=a.stream(t),n=u.stream(t),r=o.stream(t);return{point:function(t,i){e.point(t,i),n.point(t,i),r.point(t,i)},sphere:function(){e.sphere(),n.sphere(),r.sphere()},lineStart:function(){e.lineStart(),n.lineStart(),r.lineStart()},lineEnd:function(){e.lineEnd(),n.lineEnd(),r.lineEnd()},polygonStart:function(){e.polygonStart(),n.polygonStart(),r.polygonStart()},polygonEnd:function(){e.polygonEnd(),n.polygonEnd(),r.polygonEnd()}}},t.precision=function(e){return arguments.length?(a.precision(e),u.precision(e),o.precision(e),t):a.precision()},t.scale=function(e){return arguments.length?(a.scale(e),u.scale(.35*e),o.scale(e),t.translate(a.translate())):a.scale()},t.translate=function(e){if(!arguments.length)return a.translate();var c=a.scale(),l=+e[0],h=+e[1];return n=a.translate(e).clipExtent([[l-.455*c,h-.238*c],[l+.455*c,h+.238*c]]).stream(s).point,r=u.translate([l-.307*c,h+.201*c]).clipExtent([[l-.425*c+Tu,h+.12*c+Tu],[l-.214*c-Tu,h+.234*c-Tu]]).stream(s).point,i=o.translate([l-.205*c,h+.212*c]).clipExtent([[l-.214*c+Tu,h+.166*c+Tu],[l-.115*c-Tu,h+.234*c-Tu]]).stream(s).point,t},t.scale(1070)};var No,Po,Ro,jo,Yo,Uo,$o={point:w,lineStart:w,lineEnd:w,polygonStart:function(){Po=0,$o.lineStart=Ge},polygonEnd:function(){$o.lineStart=$o.lineEnd=$o.point=w,No+=pu(Po/2)}},zo={point:He,lineStart:w,lineEnd:w,polygonStart:w,polygonEnd:w},qo={point:Ze,lineStart:Ke,lineEnd:Qe,polygonStart:function(){qo.lineStart=Je},polygonEnd:function(){qo.point=Ze,qo.lineStart=Ke,qo.lineEnd=Qe}};nu.geo.path=function(){function t(t){return t&&("function"==typeof o&&a.pointRadius(+o.apply(this,arguments)),u&&u.valid||(u=i(a)),nu.geo.stream(t,u)),a.result()}function e(){return u=null,t}var n,r,i,a,u,o=4.5;return t.area=function(t){return No=0,nu.geo.stream(t,i($o)),No},t.centroid=function(t){return ko=Eo=Mo=Do=Co=So=To=Fo=Bo=0,nu.geo.stream(t,i(qo)),Bo?[To/Bo,Fo/Bo]:So?[Do/So,Co/So]:Mo?[ko/Mo,Eo/Mo]:[0/0,0/0]},t.bounds=function(t){return Yo=Uo=-(Ro=jo=1/0),nu.geo.stream(t,i(zo)),[[Ro,jo],[Yo,Uo]]},t.projection=function(t){return arguments.length?(i=(n=t)?t.stream||nn(t):_,e()):n},t.context=function(t){return arguments.length?(a=null==(r=t)?new Ve:new tn(t),"function"!=typeof o&&a.pointRadius(o),e()):r},t.pointRadius=function(e){return arguments.length?(o="function"==typeof e?e:(a.pointRadius(+e),+e),t):o},t.projection(nu.geo.albersUsa()).context(null)},nu.geo.transform=function(t){return{stream:function(e){var n=new rn(e);for(var r in t)n[r]=t[r];return n}}},rn.prototype={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()}},nu.geo.projection=un,nu.geo.projectionMutator=on,(nu.geo.equirectangular=function(){return un(cn)}).raw=cn.invert=cn,nu.geo.rotation=function(t){function e(e){return e=t(e[0]*Nu,e[1]*Nu),e[0]*=Pu,e[1]*=Pu,e}return t=hn(t[0]%360*Nu,t[1]*Nu,t.length>2?t[2]*Nu:0),e.invert=function(e){return e=t.invert(e[0]*Nu,e[1]*Nu),e[0]*=Pu,e[1]*=Pu,e},e},ln.invert=cn,nu.geo.circle=function(){function t(){var t="function"==typeof r?r.apply(this,arguments):r,e=hn(-t[0]*Nu,-t[1]*Nu,0).invert,i=[];return n(null,null,1,{point:function(t,n){i.push(t=e(t,n)),t[0]*=Pu,t[1]*=Pu}}),{type:"Polygon",coordinates:[i]}}var e,n,r=[0,0],i=6;return t.origin=function(e){return arguments.length?(r=e,t):r},t.angle=function(r){return arguments.length?(n=gn((e=+r)*Nu,i*Nu),t):e},t.precision=function(r){return arguments.length?(n=gn(e*Nu,(i=+r)*Nu),t):i},t.angle(90)},nu.geo.distance=function(t,e){var n,r=(e[0]-t[0])*Nu,i=t[1]*Nu,a=e[1]*Nu,u=Math.sin(r),o=Math.cos(r),s=Math.sin(i),c=Math.cos(i),l=Math.sin(a),h=Math.cos(a);return Math.atan2(Math.sqrt((n=h*u)*n+(n=c*l-s*h*o)*n),s*l+c*h*o)},nu.geo.graticule=function(){function t(){return{type:"MultiLineString",coordinates:e()}}function e(){return nu.range(Math.ceil(a/y)*y,i,y).map(f).concat(nu.range(Math.ceil(c/m)*m,s,m).map(d)).concat(nu.range(Math.ceil(r/p)*p,n,p).filter(function(t){return pu(t%y)>Tu}).map(l)).concat(nu.range(Math.ceil(o/g)*g,u,g).filter(function(t){return pu(t%m)>Tu}).map(h))}var n,r,i,a,u,o,s,c,l,h,f,d,p=10,g=p,y=90,m=360,v=2.5;return t.lines=function(){return e().map(function(t){return{type:"LineString",coordinates:t}})},t.outline=function(){return{type:"Polygon",coordinates:[f(a).concat(d(s).slice(1),f(i).reverse().slice(1),d(c).reverse().slice(1))]}},t.extent=function(e){return arguments.length?t.majorExtent(e).minorExtent(e):t.minorExtent()},t.majorExtent=function(e){return arguments.length?(a=+e[0][0],i=+e[1][0],c=+e[0][1],s=+e[1][1],a>i&&(e=a,a=i,i=e),c>s&&(e=c,c=s,s=e),t.precision(v)):[[a,c],[i,s]]},t.minorExtent=function(e){return arguments.length?(r=+e[0][0],n=+e[1][0],o=+e[0][1],u=+e[1][1],r>n&&(e=r,r=n,n=e),o>u&&(e=o,o=u,u=e),t.precision(v)):[[r,o],[n,u]]},t.step=function(e){return arguments.length?t.majorStep(e).minorStep(e):t.minorStep()},t.majorStep=function(e){return arguments.length?(y=+e[0],m=+e[1],t):[y,m]},t.minorStep=function(e){return arguments.length?(p=+e[0],g=+e[1],t):[p,g]},t.precision=function(e){return arguments.length?(v=+e,l=mn(o,u,90),h=vn(r,n,v),f=mn(c,s,90),d=vn(a,i,v),t):v},t.majorExtent([[-180,-90+Tu],[180,90-Tu]]).minorExtent([[-180,-80-Tu],[180,80+Tu]])},nu.geo.greatArc=function(){function t(){return{type:"LineString",coordinates:[e||r.apply(this,arguments),n||i.apply(this,arguments)]}}var e,n,r=_n,i=bn;return t.distance=function(){return nu.geo.distance(e||r.apply(this,arguments),n||i.apply(this,arguments))},t.source=function(n){return arguments.length?(r=n,e="function"==typeof n?null:n,t):r},t.target=function(e){return arguments.length?(i=e,n="function"==typeof e?null:e,t):i},t.precision=function(){return arguments.length?t:0},t},nu.geo.interpolate=function(t,e){return xn(t[0]*Nu,t[1]*Nu,e[0]*Nu,e[1]*Nu)},nu.geo.length=function(t){return Wo=0,nu.geo.stream(t,Go),Wo};var Wo,Go={sphere:w,point:w,lineStart:wn,lineEnd:w,polygonStart:w,polygonEnd:w},Ho=An(function(t){return Math.sqrt(2/(1+t))},function(t){return 2*Math.asin(t/2)});(nu.geo.azimuthalEqualArea=function(){return un(Ho)}).raw=Ho;var Vo=An(function(t){var e=Math.acos(t);return e&&e/Math.sin(e)},_);(nu.geo.azimuthalEquidistant=function(){return un(Vo)}).raw=Vo,(nu.geo.conicConformal=function(){return qe(kn)}).raw=kn,(nu.geo.conicEquidistant=function(){return qe(En)}).raw=En;var Xo=An(function(t){return 1/t},Math.atan);(nu.geo.gnomonic=function(){return un(Xo)}).raw=Xo,Mn.invert=function(t,e){return[t,2*Math.atan(Math.exp(e))-Iu]},(nu.geo.mercator=function(){return Dn(Mn)}).raw=Mn;var Zo=An(function(){return 1},Math.asin);(nu.geo.orthographic=function(){return un(Zo)}).raw=Zo;var Ko=An(function(t){return 1/(1+t)},function(t){return 2*Math.atan(t)});(nu.geo.stereographic=function(){return un(Ko)}).raw=Ko,Cn.invert=function(t,e){return[-e,2*Math.atan(Math.exp(t))-Iu]},(nu.geo.transverseMercator=function(){var t=Dn(Cn),e=t.center,n=t.rotate;return t.center=function(t){return t?e([-t[1],t[0]]):(t=e(),[t[1],-t[0]])},t.rotate=function(t){return t?n([t[0],t[1],t.length>2?t[2]+90:90]):(t=n(),[t[0],t[1],t[2]-90])},n([0,0,90])}).raw=Cn,nu.geom={},nu.geom.hull=function(t){function e(t){if(t.length<3)return[];var e,i=Dt(n),a=Dt(r),u=t.length,o=[],s=[];for(e=0;u>e;e++)o.push([+i.call(this,t[e],e),+a.call(this,t[e],e),e]);for(o.sort(Bn),e=0;u>e;e++)s.push([o[e][0],-o[e][1]]);var c=Fn(o),l=Fn(s),h=l[0]===c[0],f=l[l.length-1]===c[c.length-1],d=[];for(e=c.length-1;e>=0;--e)d.push(t[o[c[e]][2]]);for(e=+h;e=r&&c.x<=a&&c.y>=i&&c.y<=u?[[r,u],[a,u],[a,i],[r,i]]:[];l.point=t[o]}),e}function n(t){return t.map(function(t,e){return{x:Math.round(a(t,e)/Tu)*Tu,y:Math.round(u(t,e)/Tu)*Tu,i:e}})}var r=Sn,i=Tn,a=r,u=i,o=us;return t?e(t):(e.links=function(t){return or(n(t)).edges.filter(function(t){return t.l&&t.r}).map(function(e){return{source:t[e.l.i],target:t[e.r.i]}})},e.triangles=function(t){var e=[];return or(n(t)).cells.forEach(function(n,r){for(var i,a,u=n.site,o=n.edges.sort(Wn),s=-1,c=o.length,l=o[c-1].edge,h=l.l===u?l.r:l.l;++s=c,f=r>=l,d=f<<1|h;t.leaf=!1,t=t.nodes[d]||(t.nodes[d]=fr()),h?i=c:o=c,f?u=l:s=l,a(t,e,n,r,i,u,o,s)}var l,h,f,d,p,g,y,m,v,_=Dt(o),b=Dt(s);if(null!=e)g=e,y=n,m=r,v=i;else if(m=v=-(g=y=1/0),h=[],f=[],p=t.length,u)for(d=0;p>d;++d)l=t[d],l.xm&&(m=l.x),l.y>v&&(v=l.y),h.push(l.x),f.push(l.y);else for(d=0;p>d;++d){var x=+_(l=t[d],d),w=+b(l,d);g>x&&(g=x),y>w&&(y=w),x>m&&(m=x),w>v&&(v=w),h.push(x),f.push(w)}var A=m-g,k=v-y;A>k?v=y+A:m=g+k;var E=fr();if(E.add=function(t){a(E,t,+_(t,++d),+b(t,d),g,y,m,v)},E.visit=function(t){dr(t,E,g,y,m,v)},E.find=function(t){return pr(E,t[0],t[1],g,y,m,v)},d=-1,null==e){for(;++d=0?t.slice(0,e):t,r=e>=0?t.slice(e+1):"in";return n=ls.get(n)||cs,r=hs.get(r)||_,xr(r(n.apply(null,ru.call(arguments,1))))},nu.interpolateHcl=Or,nu.interpolateHsl=Ir,nu.interpolateLab=Nr,nu.interpolateRound=Pr,nu.transform=function(t){var e=au.createElementNS(nu.ns.prefix.svg,"g");return(nu.transform=function(t){if(null!=t){e.setAttribute("transform",t);var n=e.transform.baseVal.consolidate()}return new Rr(n?n.matrix:fs)})(t)},Rr.prototype.toString=function(){return"translate("+this.translate+")rotate("+this.rotate+")skewX("+this.skew+")scale("+this.scale+")"};var fs={a:1,b:0,c:0,d:1,e:0,f:0};nu.interpolateTransform=$r,nu.layout={},nu.layout.bundle=function(){return function(t){for(var e=[],n=-1,r=t.length;++no*o/y){if(p>s){var c=e.charge/s;t.px-=a*c,t.py-=u*c}return!0}if(e.point&&s&&p>s){var c=e.pointCharge/s;t.px-=a*c,t.py-=u*c}}return!e.charge}}function e(t){t.px=nu.event.x,t.py=nu.event.y,o.resume()}var n,r,i,a,u,o={},s=nu.dispatch("start","tick","end"),c=[1,1],l=.9,h=ds,f=ps,d=-30,p=gs,g=.1,y=.64,m=[],v=[];return o.tick=function(){if((r*=.99)<.005)return s.end({type:"end",alpha:r=0}),!0;var e,n,o,h,f,p,y,_,b,x=m.length,w=v.length;for(n=0;w>n;++n)o=v[n],h=o.source,f=o.target,_=f.x-h.x,b=f.y-h.y,(p=_*_+b*b)&&(p=r*a[n]*((p=Math.sqrt(p))-i[n])/p,_*=p,b*=p,f.x-=_*(y=h.weight/(f.weight+h.weight)),f.y-=b*y,h.x+=_*(y=1-y),h.y+=b*y);if((y=r*g)&&(_=c[0]/2,b=c[1]/2,n=-1,y))for(;++n0?t:0:t>0&&(s.start({type:"start",alpha:r=t}),nu.timer(o.tick)),o):r},o.start=function(){function t(t,r){if(!n){for(n=new Array(s),o=0;s>o;++o)n[o]=[];for(o=0;l>o;++o){var i=v[o];n[i.source.index].push(i.target),n[i.target.index].push(i.source)}}for(var a,u=n[e],o=-1,c=u.length;++oe;++e)(r=m[e]).index=e,r.weight=0;for(e=0;l>e;++e)r=v[e],"number"==typeof r.source&&(r.source=m[r.source]),"number"==typeof r.target&&(r.target=m[r.target]),++r.source.weight,++r.target.weight;for(e=0;s>e;++e)r=m[e],isNaN(r.x)&&(r.x=t("x",p)),isNaN(r.y)&&(r.y=t("y",g)),isNaN(r.px)&&(r.px=r.x),isNaN(r.py)&&(r.py=r.y);if(i=[],"function"==typeof h)for(e=0;l>e;++e)i[e]=+h.call(this,v[e],e);else for(e=0;l>e;++e)i[e]=h;if(a=[],"function"==typeof f)for(e=0;l>e;++e)a[e]=+f.call(this,v[e],e);else for(e=0;l>e;++e)a[e]=f;if(u=[],"function"==typeof d)for(e=0;s>e;++e)u[e]=+d.call(this,m[e],e);else for(e=0;s>e;++e)u[e]=d;return o.resume()},o.resume=function(){return o.alpha(.1)},o.stop=function(){return o.alpha(0)},o.drag=function(){return n||(n=nu.behavior.drag().origin(_).on("dragstart.force",Vr).on("drag.force",e).on("dragend.force",Xr)),arguments.length?void this.on("mouseover.force",Zr).on("mouseout.force",Kr).call(n):n},nu.rebind(o,s,"on")};var ds=20,ps=1,gs=1/0;nu.layout.hierarchy=function(){function t(i){var a,u=[i],o=[];for(i.depth=0;null!=(a=u.pop());)if(o.push(a),(c=n.call(t,a,a.depth))&&(s=c.length)){for(var s,c,l;--s>=0;)u.push(l=c[s]),l.parent=a,l.depth=a.depth+1;r&&(a.value=0),a.children=c}else r&&(a.value=+r.call(t,a,a.depth)||0),delete a.children;return ei(i,function(t){var n,i;e&&(n=t.children)&&n.sort(e),r&&(i=t.parent)&&(i.value+=t.value)}),o}var e=ii,n=ni,r=ri;return t.sort=function(n){return arguments.length?(e=n,t):e},t.children=function(e){return arguments.length?(n=e,t):n},t.value=function(e){return arguments.length?(r=e,t):r},t.revalue=function(e){return r&&(ti(e,function(t){t.children&&(t.value=0)}),ei(e,function(e){var n;e.children||(e.value=+r.call(t,e,e.depth)||0),(n=e.parent)&&(n.value+=e.value)})),e},t},nu.layout.partition=function(){function t(e,n,r,i){var a=e.children;if(e.x=n,e.y=e.depth*i,e.dx=r,e.dy=i,a&&(u=a.length)){var u,o,s,c=-1;for(r=e.value?r/e.value:0;++ch?-1:1),p=(h-s*d)/nu.sum(c),g=nu.range(s),y=[];return null!=n&&g.sort(n===ys?function(t,e){return c[e]-c[t]}:function(t,e){return n(u[t],u[e])}),g.forEach(function(t){y[t]={data:u[t],value:o=c[t],startAngle:l,endAngle:l+=o*p+d,padAngle:f}}),y}var e=Number,n=ys,r=0,i=Lu,a=0;return t.value=function(n){return arguments.length?(e=n,t):e},t.sort=function(e){return arguments.length?(n=e,t):n},t.startAngle=function(e){return arguments.length?(r=e,t):r},t.endAngle=function(e){return arguments.length?(i=e,t):i},t.padAngle=function(e){return arguments.length?(a=e,t):a},t};var ys={};nu.layout.stack=function(){function t(o,s){if(!(f=o.length))return o;var c=o.map(function(n,r){return e.call(t,n,r)}),l=c.map(function(e){return e.map(function(e,n){return[a.call(t,e,n),u.call(t,e,n)]})}),h=n.call(t,l,s);c=nu.permute(c,h),l=nu.permute(l,h);var f,d,p,g,y=r.call(t,l,s),m=c[0].length;for(p=0;m>p;++p)for(i.call(t,c[0][p],g=y[p],l[0][p][1]),d=1;f>d;++d)i.call(t,c[d][p],g+=l[d-1][p][1],l[d][p][1]);return o}var e=_,n=ci,r=li,i=si,a=ui,u=oi;return t.values=function(n){return arguments.length?(e=n,t):e},t.order=function(e){return arguments.length?(n="function"==typeof e?e:ms.get(e)||ci,t):n},t.offset=function(e){return arguments.length?(r="function"==typeof e?e:vs.get(e)||li,t):r},t.x=function(e){return arguments.length?(a=e,t):a},t.y=function(e){return arguments.length?(u=e,t):u},t.out=function(e){return arguments.length?(i=e,t):i},t};var ms=nu.map({"inside-out":function(t){var e,n,r=t.length,i=t.map(hi),a=t.map(fi),u=nu.range(r).sort(function(t,e){return i[t]-i[e]}),o=0,s=0,c=[],l=[];for(e=0;r>e;++e)n=u[e],s>o?(o+=a[n],c.push(n)):(s+=a[n],l.push(n));return l.reverse().concat(c)},reverse:function(t){return nu.range(t.length).reverse()},"default":ci}),vs=nu.map({silhouette:function(t){var e,n,r,i=t.length,a=t[0].length,u=[],o=0,s=[];for(n=0;a>n;++n){for(e=0,r=0;i>e;e++)r+=t[e][n][1];r>o&&(o=r),u.push(r)}for(n=0;a>n;++n)s[n]=(o-u[n])/2;return s},wiggle:function(t){var e,n,r,i,a,u,o,s,c,l=t.length,h=t[0],f=h.length,d=[];for(d[0]=s=c=0,n=1;f>n;++n){for(e=0,i=0;l>e;++e)i+=t[e][n][1];for(e=0,a=0,o=h[n][0]-h[n-1][0];l>e;++e){for(r=0,u=(t[e][n][1]-t[e][n-1][1])/(2*o);e>r;++r)u+=(t[r][n][1]-t[r][n-1][1])/o;a+=u*t[e][n][1]}d[n]=s-=i?a/i*o:0,c>s&&(c=s)}for(n=0;f>n;++n)d[n]-=c;return d},expand:function(t){var e,n,r,i=t.length,a=t[0].length,u=1/i,o=[];for(n=0;a>n;++n){for(e=0,r=0;i>e;e++)r+=t[e][n][1];if(r)for(e=0;i>e;e++)t[e][n][1]/=r;else for(e=0;i>e;e++)t[e][n][1]=u}for(n=0;a>n;++n)o[n]=0;return o},zero:li});nu.layout.histogram=function(){function t(t,a){for(var u,o,s=[],c=t.map(n,this),l=r.call(this,c,a),h=i.call(this,l,c,a),a=-1,f=c.length,d=h.length-1,p=e?1:1/f;++a0)for(a=-1;++a=l[0]&&o<=l[1]&&(u=s[nu.bisect(h,o,1,d)-1],u.y+=p,u.push(t[a]));return s}var e=!0,n=Number,r=yi,i=pi;return t.value=function(e){return arguments.length?(n=e,t):n},t.range=function(e){return arguments.length?(r=Dt(e),t):r},t.bins=function(e){return arguments.length?(i="number"==typeof e?function(t){return gi(t,e)}:Dt(e),t):i},t.frequency=function(n){return arguments.length?(e=!!n,t):e},t},nu.layout.pack=function(){function t(t,a){var u=n.call(this,t,a),o=u[0],s=i[0],c=i[1],l=null==e?Math.sqrt:"function"==typeof e?e:function(){return e};if(o.x=o.y=0,ei(o,function(t){t.r=+l(t.value)}),ei(o,xi),r){var h=r*(e?1:Math.max(2*o.r/s,2*o.r/c))/2;ei(o,function(t){t.r+=h; +}return function(o){function s(t){for(var e=0,n=y.length,r=t[1],i=0;n>i;++i)for(var a,u=1,o=y[i],s=o.length,c=o[0];s>u;++u)a=o[u],c[1]<=r?a[1]>r&&tt(c,a,t)>0&&++e:a[1]<=r&&tt(c,a,t)<0&&--e,c=a;return 0!==e}function c(a,o,s,c){var l=0,h=0;if(null==a||(l=i(a,s))!==(h=i(o,s))||u(a,o)<0^s>0){do c.point(0===l||3===l?t:n,l>1?r:e);while((l=(l+s+4)%4)!==h)}else c.point(o[0],o[1])}function l(i,a){return i>=t&&n>=i&&a>=e&&r>=a}function h(t,e){l(t,e)&&o.point(t,e)}function f(){S.point=p,y&&y.push(m=[]),k=!0,A=!1,x=w=0/0}function d(){g&&(p(v,_),b&&A&&M.rejoin(),g.push(M.buffer())),S.point=h,A&&o.lineEnd()}function p(t,e){t=Math.max(-No,Math.min(No,t)),e=Math.max(-No,Math.min(No,e));var n=l(t,e);if(y&&m.push([t,e]),k)v=t,_=e,b=n,k=!1,n&&(o.lineStart(),o.point(t,e));else if(n&&A)o.point(t,e);else{var r={a:{x:x,y:w},b:{x:t,y:e}};C(r)?(A||(o.lineStart(),o.point(r.a.x,r.a.y)),o.point(r.b.x,r.b.y),n||o.lineEnd(),E=!1):n&&(o.lineStart(),o.point(t,e),E=!1)}x=t,w=e,A=n}var g,y,m,v,_,b,x,w,A,k,E,D=o,M=Ne(),C=$e(t,e,n,r),S={point:h,lineStart:f,lineEnd:d,polygonStart:function(){o=M,g=[],y=[],E=!0},polygonEnd:function(){o=D,g=nu.merge(g);var e=s([t,r]),n=E&&e,i=g.length;(n||i)&&(o.polygonStart(),n&&(o.lineStart(),c(null,null,1,o),o.lineEnd()),i&&Te(g,a,e,c,o),o.polygonEnd()),g=y=m=null}};return S}}function qe(t){var e=0,n=Bu/3,r=on(t),i=r(e,n);return i.parallels=function(t){return arguments.length?r(e=t[0]*Bu/180,n=t[1]*Bu/180):[e/Bu*180,n/Bu*180]},i}function We(t,e){function n(t,e){var n=Math.sqrt(a-2*i*Math.sin(e))/i;return[n*Math.sin(t*=i),u-n*Math.cos(t)]}var r=Math.sin(t),i=(r+Math.sin(e))/2,a=1+r*(2*i-r),u=Math.sqrt(a)/i;return n.invert=function(t,e){var n=u-e;return[Math.atan2(t,n)/i,nt((a-(t*t+n*n)*i*i)/(2*i))]},n}function Ge(){function t(t,e){Po+=i*t-r*e,r=t,i=e}var e,n,r,i;$o.point=function(a,u){$o.point=t,e=r=a,n=i=u},$o.lineEnd=function(){t(e,n)}}function He(t,e){Ro>t&&(Ro=t),t>Yo&&(Yo=t),jo>e&&(jo=e),e>Uo&&(Uo=e)}function Ve(){function t(t,e){u.push("M",t,",",e,a)}function e(t,e){u.push("M",t,",",e),o.point=n}function n(t,e){u.push("L",t,",",e)}function r(){o.point=t}function i(){u.push("Z")}var a=Xe(4.5),u=[],o={point:t,lineStart:function(){o.point=e},lineEnd:r,polygonStart:function(){o.lineEnd=i},polygonEnd:function(){o.lineEnd=r,o.point=t},pointRadius:function(t){return a=Xe(t),o},result:function(){if(u.length){var t=u.join("");return u=[],t}}};return o}function Xe(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}function Ze(t,e){ko+=t,Eo+=e,++Do}function Ke(){function t(t,r){var i=t-e,a=r-n,u=Math.sqrt(i*i+a*a);Mo+=u*(e+t)/2,Co+=u*(n+r)/2,So+=u,Ze(e=t,n=r)}var e,n;qo.point=function(r,i){qo.point=t,Ze(e=r,n=i)}}function Qe(){qo.point=Ze}function Je(){function t(t,e){var n=t-r,a=e-i,u=Math.sqrt(n*n+a*a);Mo+=u*(r+t)/2,Co+=u*(i+e)/2,So+=u,u=i*t-r*e,To+=u*(r+t),Fo+=u*(i+e),Bo+=3*u,Ze(r=t,i=e)}var e,n,r,i;qo.point=function(a,u){qo.point=t,Ze(e=r=a,n=i=u)},qo.lineEnd=function(){t(e,n)}}function tn(t){function e(e,n){t.moveTo(e+u,n),t.arc(e,n,u,0,Lu)}function n(e,n){t.moveTo(e,n),o.point=r}function r(e,n){t.lineTo(e,n)}function i(){o.point=e}function a(){t.closePath()}var u=4.5,o={point:e,lineStart:function(){o.point=n},lineEnd:i,polygonStart:function(){o.lineEnd=a},polygonEnd:function(){o.lineEnd=i,o.point=e},pointRadius:function(t){return u=t,o},result:w};return o}function en(t){function e(t){return(o?r:n)(t)}function n(e){return an(e,function(n,r){n=t(n,r),e.point(n[0],n[1])})}function r(e){function n(n,r){n=t(n,r),e.point(n[0],n[1])}function r(){_=0/0,k.point=a,e.lineStart()}function a(n,r){var a=ge([n,r]),u=t(n,r);i(_,b,v,x,w,A,_=u[0],b=u[1],v=n,x=a[0],w=a[1],A=a[2],o,e),e.point(_,b)}function u(){k.point=n,e.lineEnd()}function s(){r(),k.point=c,k.lineEnd=l}function c(t,e){a(h=t,f=e),d=_,p=b,g=x,y=w,m=A,k.point=a}function l(){i(_,b,v,x,w,A,d,p,h,g,y,m,o,e),k.lineEnd=u,u()}var h,f,d,p,g,y,m,v,_,b,x,w,A,k={point:n,lineStart:r,lineEnd:u,polygonStart:function(){e.polygonStart(),k.lineStart=s},polygonEnd:function(){e.polygonEnd(),k.lineStart=r}};return k}function i(e,n,r,o,s,c,l,h,f,d,p,g,y,m){var v=l-e,_=h-n,b=v*v+_*_;if(b>4*a&&y--){var x=o+d,w=s+p,A=c+g,k=Math.sqrt(x*x+w*w+A*A),E=Math.asin(A/=k),D=pu(pu(A)-1)a||pu((v*T+_*F)/b-.5)>.3||u>o*d+s*p+c*g)&&(i(e,n,r,o,s,c,C,S,D,x/=k,w/=k,A,y,m),m.point(C,S),i(C,S,D,x,w,A,l,h,f,d,p,g,y,m))}}var a=.5,u=Math.cos(30*Iu),o=16;return e.precision=function(t){return arguments.length?(o=(a=t*t)>0&&16,e):Math.sqrt(a)},e}function nn(t){var e=en(function(e,n){return t([e*Pu,n*Pu])});return function(t){return sn(e(t))}}function rn(t){this.stream=t}function an(t,e){return{point:e,sphere:function(){t.sphere()},lineStart:function(){t.lineStart()},lineEnd:function(){t.lineEnd()},polygonStart:function(){t.polygonStart()},polygonEnd:function(){t.polygonEnd()}}}function un(t){return on(function(){return t})()}function on(t){function e(t){return t=o(t[0]*Iu,t[1]*Iu),[t[0]*f+s,c-t[1]*f]}function n(t){return t=o.invert((t[0]-s)/f,(c-t[1])/f),t&&[t[0]*Pu,t[1]*Pu]}function r(){o=Ce(u=hn(m,v,b),a);var t=a(g,y);return s=d-t[0]*f,c=p+t[1]*f,i()}function i(){return l&&(l.valid=!1,l=null),e}var a,u,o,s,c,l,h=en(function(t,e){return t=a(t,e),[t[0]*f+s,c-t[1]*f]}),f=150,d=480,p=250,g=0,y=0,m=0,v=0,b=0,x=Oo,w=_,A=null,k=null;return e.stream=function(t){return l&&(l.valid=!1),l=sn(x(u,h(w(t)))),l.valid=!0,l},e.clipAngle=function(t){return arguments.length?(x=null==t?(A=t,Oo):Ue((A=+t)*Iu),i()):A},e.clipExtent=function(t){return arguments.length?(k=t,w=t?ze(t[0][0],t[0][1],t[1][0],t[1][1]):_,i()):k},e.scale=function(t){return arguments.length?(f=+t,r()):f},e.translate=function(t){return arguments.length?(d=+t[0],p=+t[1],r()):[d,p]},e.center=function(t){return arguments.length?(g=t[0]%360*Iu,y=t[1]%360*Iu,r()):[g*Pu,y*Pu]},e.rotate=function(t){return arguments.length?(m=t[0]%360*Iu,v=t[1]%360*Iu,b=t.length>2?t[2]%360*Iu:0,r()):[m*Pu,v*Pu,b*Pu]},nu.rebind(e,h,"precision"),function(){return a=t.apply(this,arguments),e.invert=a.invert&&n,r()}}function sn(t){return an(t,function(e,n){t.point(e*Iu,n*Iu)})}function cn(t,e){return[t,e]}function ln(t,e){return[t>Bu?t-Lu:-Bu>t?t+Lu:t,e]}function hn(t,e,n){return t?e||n?Ce(dn(t),pn(e,n)):dn(t):e||n?pn(e,n):ln}function fn(t){return function(e,n){return e+=t,[e>Bu?e-Lu:-Bu>e?e+Lu:e,n]}}function dn(t){var e=fn(t);return e.invert=fn(-t),e}function pn(t,e){function n(t,e){var n=Math.cos(e),o=Math.cos(t)*n,s=Math.sin(t)*n,c=Math.sin(e),l=c*r+o*i;return[Math.atan2(s*a-l*u,o*r-c*i),nt(l*a+s*u)]}var r=Math.cos(t),i=Math.sin(t),a=Math.cos(e),u=Math.sin(e);return n.invert=function(t,e){var n=Math.cos(e),o=Math.cos(t)*n,s=Math.sin(t)*n,c=Math.sin(e),l=c*a-s*u;return[Math.atan2(s*a+c*u,o*r+l*i),nt(l*r-o*i)]},n}function gn(t,e){var n=Math.cos(t),r=Math.sin(t);return function(i,a,u,o){var s=u*e;null!=i?(i=yn(n,i),a=yn(n,a),(u>0?a>i:i>a)&&(i+=u*Lu)):(i=t+u*Lu,a=t-.5*s);for(var c,l=i;u>0?l>a:a>l;l-=s)o.point((c=xe([n,-r*Math.cos(l),-r*Math.sin(l)]))[0],c[1])}}function yn(t,e){var n=ge(e);n[0]-=t,be(n);var r=et(-n[1]);return((-n[2]<0?-r:r)+2*Math.PI-Tu)%(2*Math.PI)}function mn(t,e,n){var r=nu.range(t,e-Tu,n).concat(e);return function(t){return r.map(function(e){return[t,e]})}}function vn(t,e,n){var r=nu.range(t,e-Tu,n).concat(e);return function(t){return r.map(function(e){return[e,t]})}}function _n(t){return t.source}function bn(t){return t.target}function xn(t,e,n,r){var i=Math.cos(e),a=Math.sin(e),u=Math.cos(r),o=Math.sin(r),s=i*Math.cos(t),c=i*Math.sin(t),l=u*Math.cos(n),h=u*Math.sin(n),f=2*Math.asin(Math.sqrt(ut(r-e)+i*u*ut(n-t))),d=1/Math.sin(f),p=f?function(t){var e=Math.sin(t*=f)*d,n=Math.sin(f-t)*d,r=n*s+e*l,i=n*c+e*h,u=n*a+e*o;return[Math.atan2(i,r)*Pu,Math.atan2(u,Math.sqrt(r*r+i*i))*Pu]}:function(){return[t*Pu,e*Pu]};return p.distance=f,p}function wn(){function t(t,i){var a=Math.sin(i*=Iu),u=Math.cos(i),o=pu((t*=Iu)-e),s=Math.cos(o);Wo+=Math.atan2(Math.sqrt((o=u*Math.sin(o))*o+(o=r*a-n*u*s)*o),n*a+r*u*s),e=t,n=a,r=u}var e,n,r;Go.point=function(i,a){e=i*Iu,n=Math.sin(a*=Iu),r=Math.cos(a),Go.point=t},Go.lineEnd=function(){Go.point=Go.lineEnd=w}}function An(t,e){function n(e,n){var r=Math.cos(e),i=Math.cos(n),a=t(r*i);return[a*i*Math.sin(e),a*Math.sin(n)]}return n.invert=function(t,n){var r=Math.sqrt(t*t+n*n),i=e(r),a=Math.sin(i),u=Math.cos(i);return[Math.atan2(t*a,r*u),Math.asin(r&&n*a/r)]},n}function kn(t,e){function n(t,e){u>0?-Nu+Tu>e&&(e=-Nu+Tu):e>Nu-Tu&&(e=Nu-Tu);var n=u/Math.pow(i(e),a);return[n*Math.sin(a*t),u-n*Math.cos(a*t)]}var r=Math.cos(t),i=function(t){return Math.tan(Bu/4+t/2)},a=t===e?Math.sin(t):Math.log(r/Math.cos(e))/Math.log(i(e)/i(t)),u=r*Math.pow(i(t),a)/a;return a?(n.invert=function(t,e){var n=u-e,r=J(a)*Math.sqrt(t*t+n*n);return[Math.atan2(t,n)/a,2*Math.atan(Math.pow(u/r,1/a))-Nu]},n):Dn}function En(t,e){function n(t,e){var n=a-e;return[n*Math.sin(i*t),a-n*Math.cos(i*t)]}var r=Math.cos(t),i=t===e?Math.sin(t):(r-Math.cos(e))/(e-t),a=r/i+t;return pu(i)i;i++){for(;r>1&&tt(t[n[r-2]],t[n[r-1]],t[i])<=0;)--r;n[r++]=i}return n.slice(0,r)}function Bn(t,e){return t[0]-e[0]||t[1]-e[1]}function Ln(t,e,n){return(n[0]-e[0])*(t[1]-e[1])<(n[1]-e[1])*(t[0]-e[0])}function On(t,e,n,r){var i=t[0],a=n[0],u=e[0]-i,o=r[0]-a,s=t[1],c=n[1],l=e[1]-s,h=r[1]-c,f=(o*(s-c)-h*(i-a))/(h*u-o*l);return[i+f*u,s+f*l]}function Nn(t){var e=t[0],n=t[t.length-1];return!(e[0]-n[0]||e[1]-n[1])}function In(){rr(this),this.edge=this.site=this.circle=null}function Pn(t){var e=is.pop()||new In;return e.site=t,e}function Rn(t){Vn(t),es.remove(t),is.push(t),rr(t)}function jn(t){var e=t.circle,n=e.x,r=e.cy,i={x:n,y:r},a=t.P,u=t.N,o=[t];Rn(t);for(var s=a;s.circle&&pu(n-s.circle.x)l;++l)c=o[l],s=o[l-1],tr(c.edge,s.site,c.site,i);s=o[0],c=o[h-1],c.edge=Qn(s.site,c.site,null,i),Hn(s),Hn(c)}function Yn(t){for(var e,n,r,i,a=t.x,u=t.y,o=es._;o;)if(r=Un(o,u)-a,r>Tu)o=o.L;else{if(i=a-$n(o,u),!(i>Tu)){r>-Tu?(e=o.P,n=o):i>-Tu?(e=o,n=o.N):e=n=o;break}if(!o.R){e=o;break}o=o.R}var s=Pn(t);if(es.insert(e,s),e||n){if(e===n)return Vn(e),n=Pn(e.site),es.insert(s,n),s.edge=n.edge=Qn(e.site,s.site),Hn(e),void Hn(n);if(!n)return void(s.edge=Qn(e.site,s.site));Vn(e),Vn(n);var c=e.site,l=c.x,h=c.y,f=t.x-l,d=t.y-h,p=n.site,g=p.x-l,y=p.y-h,m=2*(f*y-d*g),v=f*f+d*d,_=g*g+y*y,b={x:(y*v-d*_)/m+l,y:(f*_-g*v)/m+h};tr(n.edge,c,p,b),s.edge=Qn(c,t,null,b),n.edge=Qn(t,p,null,b),Hn(e),Hn(n)}}function Un(t,e){var n=t.site,r=n.x,i=n.y,a=i-e;if(!a)return r;var u=t.P;if(!u)return-(1/0);n=u.site;var o=n.x,s=n.y,c=s-e;if(!c)return o;var l=o-r,h=1/a-1/c,f=l/c;return h?(-f+Math.sqrt(f*f-2*h*(l*l/(-2*c)-s+c/2+i-a/2)))/h+r:(r+o)/2}function $n(t,e){var n=t.N;if(n)return Un(n,e);var r=t.site;return r.y===e?r.x:1/0}function zn(t){this.site=t,this.edges=[]}function qn(t){for(var e,n,r,i,a,u,o,s,c,l,h=t[0][0],f=t[1][0],d=t[0][1],p=t[1][1],g=ts,y=g.length;y--;)if(a=g[y],a&&a.prepare())for(o=a.edges,s=o.length,u=0;s>u;)l=o[u].end(),r=l.x,i=l.y,c=o[++u%s].start(),e=c.x,n=c.y,(pu(r-e)>Tu||pu(i-n)>Tu)&&(o.splice(u,0,new er(Jn(a.site,l,pu(r-h)Tu?{x:h,y:pu(e-h)Tu?{x:pu(n-p)Tu?{x:f,y:pu(e-f)Tu?{x:pu(n-d)=-Fu)){var d=s*s+c*c,p=l*l+h*h,g=(h*d-c*p)/f,y=(s*p-l*d)/f,h=y+o,m=as.pop()||new Gn;m.arc=t,m.site=i,m.x=g+u,m.y=h+Math.sqrt(g*g+y*y),m.cy=h,t.circle=m;for(var v=null,_=rs._;_;)if(m.y<_.y||m.y===_.y&&m.x<=_.x){if(!_.L){v=_.P;break}_=_.L}else{if(!_.R){v=_;break}_=_.R}rs.insert(v,m),v||(ns=m)}}}}function Vn(t){var e=t.circle;e&&(e.P||(ns=e.N),rs.remove(e),as.push(e),rr(e),t.circle=null)}function Xn(t){for(var e,n=Jo,r=$e(t[0][0],t[0][1],t[1][0],t[1][1]),i=n.length;i--;)e=n[i],(!Zn(e,t)||!r(e)||pu(e.a.x-e.b.x)y||y>=o)return;if(f>p){if(a){if(a.y>=c)return}else a={x:y,y:s};n={x:y,y:c}}else{if(a){if(a.yr||r>1)if(f>p){if(a){if(a.y>=c)return}else a={x:(s-i)/r,y:s};n={x:(c-i)/r,y:c}}else{if(a){if(a.yd){if(a){if(a.x>=o)return}else a={x:u,y:r*u+i};n={x:o,y:r*o+i}}else{if(a){if(a.xa||h>u||r>f||i>d)){if(p=t.point){var p,g=e-t.x,y=n-t.y,m=g*g+y*y;if(s>m){var v=Math.sqrt(s=m);r=e-v,i=n-v,a=e+v,u=n+v,o=p}}for(var _=t.nodes,b=.5*(l+f),x=.5*(h+d),w=e>=b,A=n>=x,k=A<<1|w,E=k+4;E>k;++k)if(t=_[3&k])switch(3&k){case 0:c(t,l,h,b,x);break;case 1:c(t,b,h,f,x);break;case 2:c(t,l,x,b,d);break;case 3:c(t,b,x,f,d)}}}(t,r,i,a,u),o}function gr(t,e){t=nu.rgb(t),e=nu.rgb(e);var n=t.r,r=t.g,i=t.b,a=e.r-n,u=e.g-r,o=e.b-i;return function(t){return"#"+xt(Math.round(n+a*t))+xt(Math.round(r+u*t))+xt(Math.round(i+o*t))}}function yr(t,e){var n,r={},i={};for(n in t)n in e?r[n]=_r(t[n],e[n]):i[n]=t[n];for(n in e)n in t||(i[n]=e[n]);return function(t){for(n in r)i[n]=r[n](t);return i}}function mr(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function vr(t,e){var n,r,i,a=os.lastIndex=ss.lastIndex=0,u=-1,o=[],s=[];for(t+="",e+="";(n=os.exec(t))&&(r=ss.exec(e));)(i=r.index)>a&&(i=e.slice(a,i),o[u]?o[u]+=i:o[++u]=i),(n=n[0])===(r=r[0])?o[u]?o[u]+=r:o[++u]=r:(o[++u]=null,s.push({i:u,x:mr(n,r)})),a=ss.lastIndex;return ar;++r)o[(n=s[r]).i]=n.x(t);return o.join("")})}function _r(t,e){for(var n,r=nu.interpolators.length;--r>=0&&!(n=nu.interpolators[r](t,e)););return n}function br(t,e){var n,r=[],i=[],a=t.length,u=e.length,o=Math.min(t.length,e.length);for(n=0;o>n;++n)r.push(_r(t[n],e[n]));for(;a>n;++n)i[n]=t[n];for(;u>n;++n)i[n]=e[n];return function(t){for(n=0;o>n;++n)i[n]=r[n](t);return i}}function xr(t){return function(e){return 0>=e?0:e>=1?1:t(e)}}function wr(t){return function(e){return 1-t(1-e)}}function Ar(t){return function(e){return.5*(.5>e?t(2*e):2-t(2-2*e))}}function kr(t){return t*t}function Er(t){return t*t*t}function Dr(t){if(0>=t)return 0;if(t>=1)return 1;var e=t*t,n=e*t;return 4*(.5>t?n:3*(t-e)+n-.75)}function Mr(t){return function(e){return Math.pow(e,t)}}function Cr(t){return 1-Math.cos(t*Nu)}function Sr(t){return Math.pow(2,10*(t-1))}function Tr(t){return 1-Math.sqrt(1-t*t)}function Fr(t,e){var n;return arguments.length<2&&(e=.45),arguments.length?n=e/Lu*Math.asin(1/t):(t=1,n=e/4),function(r){return 1+t*Math.pow(2,-10*r)*Math.sin((r-n)*Lu/e)}}function Br(t){return t||(t=1.70158),function(e){return e*e*((t+1)*e-t)}}function Lr(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375}function Or(t,e){t=nu.hcl(t),e=nu.hcl(e);var n=t.h,r=t.c,i=t.l,a=e.h-n,u=e.c-r,o=e.l-i;return isNaN(u)&&(u=0,r=isNaN(r)?e.c:r),isNaN(a)?(a=0,n=isNaN(n)?e.h:n):a>180?a-=360:-180>a&&(a+=360),function(t){return ht(n+a*t,r+u*t,i+o*t)+""}}function Nr(t,e){t=nu.hsl(t),e=nu.hsl(e);var n=t.h,r=t.s,i=t.l,a=e.h-n,u=e.s-r,o=e.l-i;return isNaN(u)&&(u=0,r=isNaN(r)?e.s:r),isNaN(a)?(a=0,n=isNaN(n)?e.h:n):a>180?a-=360:-180>a&&(a+=360),function(t){return ct(n+a*t,r+u*t,i+o*t)+""}}function Ir(t,e){t=nu.lab(t),e=nu.lab(e);var n=t.l,r=t.a,i=t.b,a=e.l-n,u=e.a-r,o=e.b-i;return function(t){return dt(n+a*t,r+u*t,i+o*t)+""}}function Pr(t,e){return e-=t,function(n){return Math.round(t+e*n)}}function Rr(t){var e=[t.a,t.b],n=[t.c,t.d],r=Yr(e),i=jr(e,n),a=Yr(Ur(n,e,-i))||0;e[0]*n[1]180?l+=360:l-c>180&&(c+=360),i.push({i:r.push(r.pop()+"rotate(",null,")")-2,x:mr(c,l)})):l&&r.push(r.pop()+"rotate("+l+")"),h!=f?i.push({i:r.push(r.pop()+"skewX(",null,")")-2,x:mr(h,f)}):f&&r.push(r.pop()+"skewX("+f+")"),d[0]!=p[0]||d[1]!=p[1]?(n=r.push(r.pop()+"scale(",null,",",null,")"),i.push({i:n-4,x:mr(d[0],p[0])},{i:n-2,x:mr(d[1],p[1])})):(1!=p[0]||1!=p[1])&&r.push(r.pop()+"scale("+p+")"),n=i.length,function(t){for(var e,a=-1;++a=0;)n.push(i[r])}function ei(t,e){for(var n=[t],r=[];null!=(t=n.pop());)if(r.push(t),(a=t.children)&&(i=a.length))for(var i,a,u=-1;++un;++n)(e=t[n][1])>i&&(r=n,i=e);return r}function fi(t){return t.reduce(di,0)}function di(t,e){return t+e[1]}function pi(t,e){return gi(t,Math.ceil(Math.log(e.length)/Math.LN2+1))}function gi(t,e){for(var n=-1,r=+t[0],i=(t[1]-r)/e,a=[];++n<=e;)a[n]=i*n+r;return a}function yi(t){return[nu.min(t),nu.max(t)]}function mi(t,e){return t.value-e.value}function vi(t,e){var n=t._pack_next;t._pack_next=e,e._pack_prev=t,e._pack_next=n,n._pack_prev=e}function _i(t,e){t._pack_next=e,e._pack_prev=t}function bi(t,e){var n=e.x-t.x,r=e.y-t.y,i=t.r+e.r;return.999*i*i>n*n+r*r}function xi(t){function e(t){l=Math.min(t.x-t.r,l),h=Math.max(t.x+t.r,h),f=Math.min(t.y-t.r,f),d=Math.max(t.y+t.r,d)}if((n=t.children)&&(c=n.length)){var n,r,i,a,u,o,s,c,l=1/0,h=-(1/0),f=1/0,d=-(1/0);if(n.forEach(wi),r=n[0],r.x=-r.r,r.y=0,e(r),c>1&&(i=n[1],i.x=i.r,i.y=0,e(i),c>2))for(a=n[2],Ei(r,i,a),e(a),vi(r,a),r._pack_prev=a,vi(a,i),i=r._pack_next,u=3;c>u;u++){Ei(r,i,a=n[u]);var p=0,g=1,y=1;for(o=i._pack_next;o!==i;o=o._pack_next,g++)if(bi(o,a)){p=1;break}if(1==p)for(s=r._pack_prev;s!==o._pack_prev&&!bi(s,a);s=s._pack_prev,y++);p?(y>g||g==y&&i.ru;u++)a=n[u],a.x-=m,a.y-=v,_=Math.max(_,a.r+Math.sqrt(a.x*a.x+a.y*a.y));t.r=_,n.forEach(Ai)}}function wi(t){t._pack_next=t._pack_prev=t}function Ai(t){delete t._pack_next,delete t._pack_prev}function ki(t,e,n,r){var i=t.children;if(t.x=e+=r*t.x,t.y=n+=r*t.y,t.r*=r,i)for(var a=-1,u=i.length;++a=0;)e=i[a],e.z+=n,e.m+=n,n+=e.s+(r+=e.c)}function Fi(t,e,n){return t.a.parent===e.parent?t.a:n}function Bi(t){return 1+nu.max(t,function(t){return t.y})}function Li(t){return t.reduce(function(t,e){return t+e.x},0)/t.length}function Oi(t){var e=t.children;return e&&e.length?Oi(e[0]):t}function Ni(t){var e,n=t.children;return n&&(e=n.length)?Ni(n[e-1]):t}function Ii(t){return{x:t.x,y:t.y,dx:t.dx,dy:t.dy}}function Pi(t,e){var n=t.x+e[3],r=t.y+e[0],i=t.dx-e[1]-e[3],a=t.dy-e[0]-e[2];return 0>i&&(n+=i/2,i=0),0>a&&(r+=a/2,a=0),{x:n,y:r,dx:i,dy:a}}function Ri(t){var e=t[0],n=t[t.length-1];return n>e?[e,n]:[n,e]}function ji(t){return t.rangeExtent?t.rangeExtent():Ri(t.range())}function Yi(t,e,n,r){var i=n(t[0],t[1]),a=r(e[0],e[1]);return function(t){return a(i(t))}}function Ui(t,e){var n,r=0,i=t.length-1,a=t[r],u=t[i];return a>u&&(n=r,r=i,i=n,n=a,a=u,u=n),t[r]=e.floor(a),t[i]=e.ceil(u),t}function $i(t){return t?{floor:function(e){return Math.floor(e/t)*t},ceil:function(e){return Math.ceil(e/t)*t}}:_s}function zi(t,e,n,r){var i=[],a=[],u=0,o=Math.min(t.length,e.length)-1;for(t[o]2?zi:Yi,s=r?qr:zr;return u=i(t,e,s,n),o=i(e,t,s,_r),a}function a(t){return u(t)}var u,o;return a.invert=function(t){return o(t)},a.domain=function(e){return arguments.length?(t=e.map(Number),i()):t},a.range=function(t){return arguments.length?(e=t,i()):e},a.rangeRound=function(t){return a.range(t).interpolate(Pr)},a.clamp=function(t){return arguments.length?(r=t,i()):r},a.interpolate=function(t){return arguments.length?(n=t,i()):n},a.ticks=function(e){return Vi(t,e)},a.tickFormat=function(e,n){return Xi(t,e,n)},a.nice=function(e){return Gi(t,e),i()},a.copy=function(){return qi(t,e,n,r)},i()}function Wi(t,e){return nu.rebind(t,e,"range","rangeRound","interpolate","clamp")}function Gi(t,e){return Ui(t,$i(Hi(t,e)[2]))}function Hi(t,e){null==e&&(e=10);var n=Ri(t),r=n[1]-n[0],i=Math.pow(10,Math.floor(Math.log(r/e)/Math.LN10)),a=e/r*i;return.15>=a?i*=10:.35>=a?i*=5:.75>=a&&(i*=2),n[0]=Math.ceil(n[0]/i)*i,n[1]=Math.floor(n[1]/i)*i+.5*i,n[2]=i,n}function Vi(t,e){return nu.range.apply(nu,Hi(t,e))}function Xi(t,e,n){var r=Hi(t,e);if(n){var i=uo.exec(n);if(i.shift(),"s"===i[8]){var a=nu.formatPrefix(Math.max(pu(r[0]),pu(r[1])));return i[7]||(i[7]="."+Zi(a.scale(r[2]))),i[8]="f",n=nu.format(i.join("")),function(t){return n(a.scale(t))+a.symbol}}i[7]||(i[7]="."+Ki(i[8],r)),n=i.join("")}else n=",."+Zi(r[2])+"f";return nu.format(n)}function Zi(t){return-Math.floor(Math.log(t)/Math.LN10+.01)}function Ki(t,e){var n=Zi(e[2]);return t in bs?Math.abs(n-Zi(Math.max(pu(e[0]),pu(e[1]))))+ +("e"!==t):n-2*("%"===t)}function Qi(t,e,n,r){function i(t){return(n?Math.log(0>t?0:t):-Math.log(t>0?0:-t))/Math.log(e)}function a(t){return n?Math.pow(e,t):-Math.pow(e,-t)}function u(e){return t(i(e))}return u.invert=function(e){return a(t.invert(e))},u.domain=function(e){return arguments.length?(n=e[0]>=0,t.domain((r=e.map(Number)).map(i)),u):r},u.base=function(n){return arguments.length?(e=+n,t.domain(r.map(i)),u):e},u.nice=function(){var e=Ui(r.map(i),n?Math:ws);return t.domain(e),r=e.map(a),u},u.ticks=function(){var t=Ri(r),u=[],o=t[0],s=t[1],c=Math.floor(i(o)),l=Math.ceil(i(s)),h=e%1?2:e;if(isFinite(l-c)){if(n){for(;l>c;c++)for(var f=1;h>f;f++)u.push(a(c)*f);u.push(a(c))}else for(u.push(a(c));c++0;f--)u.push(a(c)*f);for(c=0;u[c]s;l--);u=u.slice(c,l)}return u},u.tickFormat=function(t,e){if(!arguments.length)return xs;arguments.length<2?e=xs:"function"!=typeof e&&(e=nu.format(e));var r,o=Math.max(.1,t/u.ticks().length),s=n?(r=1e-12,Math.ceil):(r=-1e-12,Math.floor);return function(t){return t/a(s(i(t)+r))<=o?e(t):""}},u.copy=function(){return Qi(t.copy(),e,n,r)},Wi(u,t)}function Ji(t,e,n){function r(e){return t(i(e))}var i=ta(e),a=ta(1/e);return r.invert=function(e){return a(t.invert(e))},r.domain=function(e){return arguments.length?(t.domain((n=e.map(Number)).map(i)),r):n},r.ticks=function(t){return Vi(n,t)},r.tickFormat=function(t,e){return Xi(n,t,e)},r.nice=function(t){return r.domain(Gi(n,t))},r.exponent=function(u){return arguments.length?(i=ta(e=u),a=ta(1/e),t.domain(n.map(i)),r):e},r.copy=function(){return Ji(t.copy(),e,n)},Wi(r,t)}function ta(t){return function(e){return 0>e?-Math.pow(-e,t):Math.pow(e,t)}}function ea(t,e){function n(n){return a[((i.get(n)||("range"===e.t?i.set(n,t.push(n)):0/0))-1)%a.length]}function r(e,n){return nu.range(t.length).map(function(t){return e+n*t})}var i,a,u;return n.domain=function(r){if(!arguments.length)return t;t=[],i=new l;for(var a,u=-1,o=r.length;++un?[0/0,0/0]:[n>0?o[n-1]:t[0],ne?0/0:e/a+t,[e,e+1/a]},r.copy=function(){return ra(t,e,n)},i()}function ia(t,e){function n(n){return n>=n?e[nu.bisect(t,n)]:void 0}return n.domain=function(e){return arguments.length?(t=e,n):t},n.range=function(t){return arguments.length?(e=t,n):e},n.invertExtent=function(n){return n=e.indexOf(n),[t[n-1],t[n]]},n.copy=function(){return ia(t,e)},n}function aa(t){function e(t){return+t}return e.invert=e,e.domain=e.range=function(n){return arguments.length?(t=n.map(e),e):t},e.ticks=function(e){return Vi(t,e)},e.tickFormat=function(e,n){return Xi(t,e,n)},e.copy=function(){return aa(t)},e}function ua(){return 0}function oa(t){return t.innerRadius}function sa(t){return t.outerRadius}function ca(t){return t.startAngle}function la(t){return t.endAngle}function ha(t){return t&&t.padAngle}function fa(t,e,n,r){return(t-n)*e-(e-r)*t>0?0:1}function da(t,e,n,r,i){var a=t[0]-e[0],u=t[1]-e[1],o=(i?r:-r)/Math.sqrt(a*a+u*u),s=o*u,c=-o*a,l=t[0]+s,h=t[1]+c,f=e[0]+s,d=e[1]+c,p=(l+f)/2,g=(h+d)/2,y=f-l,m=d-h,v=y*y+m*m,_=n-r,b=l*d-f*h,x=(0>m?-1:1)*Math.sqrt(_*_*v-b*b),w=(b*m-y*x)/v,A=(-b*y-m*x)/v,k=(b*m+y*x)/v,E=(-b*y+m*x)/v,D=w-p,M=A-g,C=k-p,S=E-g;return D*D+M*M>C*C+S*S&&(w=k,A=E),[[w-s,A-c],[w*n/_,A*n/_]]}function pa(t){function e(e){function u(){c.push("M",a(t(l),o))}for(var s,c=[],l=[],h=-1,f=e.length,d=Mt(n),p=Mt(r);++h1&&i.push("H",r[0]),i.join("")}function va(t){for(var e=0,n=t.length,r=t[0],i=[r[0],",",r[1]];++e1){o=e[1],a=t[s],s++,r+="C"+(i[0]+u[0])+","+(i[1]+u[1])+","+(a[0]-o[0])+","+(a[1]-o[1])+","+a[0]+","+a[1];for(var c=2;c9&&(i=3*e/Math.sqrt(i),u[o]=i*n,u[o+1]=i*r));for(o=-1;++o<=s;)i=(t[Math.min(s,o+1)][0]-t[Math.max(0,o-1)][0])/(6*(1+u[o]*u[o])),a.push([i||0,u[o]*i||0]);return a}function Oa(t){return t.length<3?ga(t):t[0]+Aa(t,La(t))}function Na(t){for(var e,n,r,i=-1,a=t.length;++ir)return l();var i=a[a.active];i&&(--a.count,delete a[a.active],i.event&&i.event.interrupt.call(t,t.__data__,i.index)),a.active=r,u.event&&u.event.start.call(t,t.__data__,e),u.tween.forEach(function(n,r){(r=r.call(t,t.__data__,e))&&g.push(r)}),f=u.ease,h=u.duration,nu.timer(function(){return p.c=c(n||1)?Se:c,1},0,o)}function c(n){if(a.active!==r)return 1;for(var i=n/h,o=f(i),s=g.length;s>0;)g[--s].call(t,o);return i>=1?(u.event&&u.event.end.call(t,t.__data__,e),l()):void 0}function l(){return--a.count?delete a[r]:delete t[n],1}var h,f,d=u.delay,p=ro,g=[];return p.t=d+o,i>=d?s(i-d):void(p.c=s)},0,o)}}function Xa(t,e,n){t.attr("transform",function(t){var r=e(t);return"translate("+(isFinite(r)?r:n(t))+",0)"})}function Za(t,e,n){t.attr("transform",function(t){var r=e(t);return"translate(0,"+(isFinite(r)?r:n(t))+")"})}function Ka(t){return t.toISOString()}function Qa(t,e,n){function r(e){return t(e)}function i(t,n){var r=t[1]-t[0],i=r/n,a=nu.bisect(Hs,i);return a==Hs.length?[e.year,Hi(t.map(function(t){return t/31536e6}),n)[2]]:a?e[i/Hs[a-1]1?{floor:function(e){for(;n(e=t.floor(e));)e=Ja(e-1);return e},ceil:function(e){for(;n(e=t.ceil(e));)e=Ja(+e+1);return e}}:t))},r.ticks=function(t,e){var n=Ri(r.domain()),a=null==t?i(n,10):"number"==typeof t?i(n,t):!t.range&&[{range:t},e];return a&&(t=a[0],e=a[1]),t.range(n[0],Ja(+n[1]+1),1>e?1:e)},r.tickFormat=function(){return n},r.copy=function(){return Qa(t.copy(),e,n)},Wi(r,t)}function Ja(t){return new Date(t)}function tu(t){return JSON.parse(t.responseText)}function eu(t){var e=au.createRange();return e.selectNode(au.body),e.createContextualFragment(t.responseText)}var nu={version:"3.5.6"},ru=[].slice,iu=function(t){return ru.call(t)},au=this.document;if(au)try{iu(au.documentElement.childNodes)[0].nodeType}catch(uu){iu=function(t){for(var e=t.length,n=new Array(e);e--;)n[e]=t[e];return n}}if(Date.now||(Date.now=function(){return+new Date}),au)try{au.createElement("DIV").style.setProperty("opacity",0,"")}catch(ou){var su=this.Element.prototype,cu=su.setAttribute,lu=su.setAttributeNS,hu=this.CSSStyleDeclaration.prototype,fu=hu.setProperty;su.setAttribute=function(t,e){cu.call(this,t,e+"")},su.setAttributeNS=function(t,e,n){lu.call(this,t,e,n+"")},hu.setProperty=function(t,e,n){fu.call(this,t,e+"",n)}}nu.ascending=r,nu.descending=function(t,e){return t>e?-1:e>t?1:e>=t?0:0/0},nu.min=function(t,e){var n,r,i=-1,a=t.length;if(1===arguments.length){for(;++i=r){n=r;break}for(;++ir&&(n=r)}else{for(;++i=r){n=r;break}for(;++ir&&(n=r)}return n},nu.max=function(t,e){var n,r,i=-1,a=t.length;if(1===arguments.length){for(;++i=r){n=r;break}for(;++in&&(n=r)}else{for(;++i=r){n=r;break}for(;++in&&(n=r)}return n},nu.extent=function(t,e){var n,r,i,a=-1,u=t.length;if(1===arguments.length){for(;++a=r){n=i=r;break}for(;++ar&&(n=r),r>i&&(i=r))}else{for(;++a=r){n=i=r;break}for(;++ar&&(n=r),r>i&&(i=r))}return[n,i]},nu.sum=function(t,e){var n,r=0,i=t.length,u=-1;if(1===arguments.length)for(;++u1?s/(l-1):void 0},nu.deviation=function(){var t=nu.variance.apply(this,arguments);return t?Math.sqrt(t):t};var du=u(r);nu.bisectLeft=du.left,nu.bisect=nu.bisectRight=du.right,nu.bisector=function(t){return u(1===t.length?function(e,n){return r(t(e),n)}:t)},nu.shuffle=function(t,e,n){(a=arguments.length)<3&&(n=t.length,2>a&&(e=0));for(var r,i,a=n-e;a;)i=Math.random()*a--|0,r=t[a+e],t[a+e]=t[i+e],t[i+e]=r;return t},nu.permute=function(t,e){for(var n=e.length,r=new Array(n);n--;)r[n]=t[e[n]];return r},nu.pairs=function(t){for(var e,n=0,r=t.length-1,i=t[0],a=new Array(0>r?0:r);r>n;)a[n]=[e=i,i=t[++n]];return a},nu.zip=function(){if(!(r=arguments.length))return[];for(var t=-1,e=nu.min(arguments,o),n=new Array(e);++t=0;)for(r=t[i],e=r.length;--e>=0;)n[--u]=r[e];return n};var pu=Math.abs;nu.range=function(t,e,n){if(arguments.length<3&&(n=1,arguments.length<2&&(e=t,t=0)),(e-t)/n===1/0)throw new Error("infinite range");var r,i=[],a=s(pu(n)),u=-1;if(t*=a,e*=a,n*=a,0>n)for(;(r=t+n*++u)>e;)i.push(r/a);else for(;(r=t+n*++u)=a.length)return r?r.call(i,u):n?u.sort(n):u;for(var s,c,h,f,d=-1,p=u.length,g=a[o++],y=new l;++d=a.length)return t;var r=[],i=u[n++];return t.forEach(function(t,i){r.push({key:t,values:e(i,n)})}),i?r.sort(function(t,e){return i(t.key,e.key)}):r}var n,r,i={},a=[],u=[];return i.map=function(e,n){return t(n,e,0)},i.entries=function(n){return e(t(nu.map,n,0),0)},i.key=function(t){return a.push(t),i},i.sortKeys=function(t){return u[a.length-1]=t,i},i.sortValues=function(t){return n=t,i},i.rollup=function(t){return r=t,i},i},nu.set=function(t){var e=new v;if(t)for(var n=0,r=t.length;r>n;++n)e.add(t[n]);return e},c(v,{has:d,add:function(t){return this._[h(t+="")]=!0,t},remove:p,values:g,size:y,empty:m,forEach:function(t){for(var e in this._)t.call(this,f(e))}}),nu.behavior={},nu.rebind=function(t,e){for(var n,r=1,i=arguments.length;++r=0&&(r=t.slice(n+1),t=t.slice(0,n)),t)return arguments.length<2?this[t].on(r):this[t].on(r,e);if(2===arguments.length){if(null==e)for(t in this)this.hasOwnProperty(t)&&this[t].on(r,null);return this}},nu.event=null,nu.requote=function(t){return t.replace(vu,"\\$&")};var vu=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,_u={}.__proto__?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)t[n]=e[n]},bu=function(t,e){return e.querySelector(t)},xu=function(t,e){return e.querySelectorAll(t)},wu=function(t,e){var n=t.matches||t[x(t,"matchesSelector")];return(wu=function(t,e){return n.call(t,e)})(t,e)};"function"==typeof Sizzle&&(bu=function(t,e){return Sizzle(t,e)[0]||null},xu=Sizzle,wu=Sizzle.matchesSelector),nu.selection=function(){return nu.select(au.documentElement)};var Au=nu.selection.prototype=[];Au.select=function(t){var e,n,r,i,a=[];t=S(t);for(var u=-1,o=this.length;++u=0&&(n=t.slice(0,e),t=t.slice(e+1)),ku.hasOwnProperty(n)?{space:ku[n],local:t}:t}},Au.attr=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node();return t=nu.ns.qualify(t),t.local?n.getAttributeNS(t.space,t.local):n.getAttribute(t)}for(e in t)this.each(F(e,t[e]));return this}return this.each(F(t,e))},Au.classed=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node(),r=(t=O(t)).length,i=-1;if(e=n.classList){for(;++ii){if("string"!=typeof t){2>i&&(e="");for(r in t)this.each(P(r,t[r],e));return this}if(2>i){var a=this.node();return n(a).getComputedStyle(a,null).getPropertyValue(t)}r=""}return this.each(P(t,e,r))},Au.property=function(t,e){if(arguments.length<2){if("string"==typeof t)return this.node()[t];for(e in t)this.each(R(e,t[e]));return this}return this.each(R(t,e))},Au.text=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}:null==t?function(){this.textContent=""}:function(){this.textContent=t}):this.node().textContent},Au.html=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}:null==t?function(){this.innerHTML=""}:function(){this.innerHTML=t}):this.node().innerHTML},Au.append=function(t){return t=j(t),this.select(function(){return this.appendChild(t.apply(this,arguments))})},Au.insert=function(t,e){return t=j(t),e=S(e),this.select(function(){return this.insertBefore(t.apply(this,arguments),e.apply(this,arguments)||null)})},Au.remove=function(){return this.each(Y)},Au.data=function(t,e){function n(t,n){var r,i,a,u=t.length,h=n.length,f=Math.min(u,h),d=new Array(h),p=new Array(h),g=new Array(u);if(e){var y,m=new l,v=new Array(u);for(r=-1;++rr;++r)p[r]=U(n[r]);for(;u>r;++r)g[r]=t[r]}p.update=d,p.parentNode=d.parentNode=g.parentNode=t.parentNode,o.push(p),s.push(d),c.push(g)}var r,i,a=-1,u=this.length;if(!arguments.length){for(t=new Array(u=(r=this[0]).length);++aa;a++){i.push(e=[]),e.parentNode=(n=this[a]).parentNode;for(var o=0,s=n.length;s>o;o++)(r=n[o])&&t.call(r,r.__data__,o,a)&&e.push(r)}return C(i)},Au.order=function(){for(var t=-1,e=this.length;++t=0;)(n=r[i])&&(a&&a!==n.nextSibling&&a.parentNode.insertBefore(n,a),a=n);return this},Au.sort=function(t){t=z.apply(this,arguments);for(var e=-1,n=this.length;++et;t++)for(var n=this[t],r=0,i=n.length;i>r;r++){var a=n[r];if(a)return a}return null},Au.size=function(){var t=0;return q(this,function(){++t}),t};var Eu=[];nu.selection.enter=W,nu.selection.enter.prototype=Eu,Eu.append=Au.append,Eu.empty=Au.empty,Eu.node=Au.node,Eu.call=Au.call,Eu.size=Au.size,Eu.select=function(t){for(var e,n,r,i,a,u=[],o=-1,s=this.length;++or){if("string"!=typeof t){2>r&&(e=!1);for(n in t)this.each(H(n,t[n],e));return this}if(2>r)return(r=this.node()["__on"+t])&&r._;n=!1}return this.each(H(t,e,n))};var Du=nu.map({mouseenter:"mouseover",mouseleave:"mouseout"});au&&Du.forEach(function(t){"on"+t in au&&Du.remove(t)});var Mu,Cu=0;nu.mouse=function(t){return K(t,D())};var Su=this.navigator&&/WebKit/.test(this.navigator.userAgent)?-1:0;nu.touch=function(t,e,n){if(arguments.length<3&&(n=e,e=D().changedTouches),e)for(var r,i=0,a=e.length;a>i;++i)if((r=e[i]).identifier===n)return K(t,r)},nu.behavior.drag=function(){function t(){this.on("mousedown.drag",a).on("touchstart.drag",u)}function e(t,e,n,a,u){return function(){function o(){var t,n,r=e(f,g);r&&(t=r[0]-_[0],n=r[1]-_[1],p|=t|n,_=r,d({type:"drag",x:r[0]+c[0],y:r[1]+c[1],dx:t,dy:n}))}function s(){e(f,g)&&(m.on(a+y,null).on(u+y,null),v(p&&nu.event.target===h),d({type:"dragend"}))}var c,l=this,h=nu.event.target,f=l.parentNode,d=r.of(l,arguments),p=0,g=t(),y=".drag"+(null==g?"":"-"+g),m=nu.select(n(h)).on(a+y,o).on(u+y,s),v=Z(h),_=e(f,g);i?(c=i.apply(l,arguments),c=[c.x-_[0],c.y-_[1]]):c=[0,0],d({type:"dragstart"})}}var r=M(t,"drag","dragstart","dragend"),i=null,a=e(w,nu.mouse,n,"mousemove","mouseup"),u=e(Q,nu.touch,_,"touchmove","touchend");return t.origin=function(e){return arguments.length?(i=e,t):i},nu.rebind(t,r,"on")},nu.touches=function(t,e){return arguments.length<2&&(e=D().touches),e?iu(e).map(function(e){var n=K(t,e);return n.identifier=e.identifier,n}):[]};var Tu=1e-6,Fu=Tu*Tu,Bu=Math.PI,Lu=2*Bu,Ou=Lu-Tu,Nu=Bu/2,Iu=Bu/180,Pu=180/Bu,Ru=Math.SQRT2,ju=2,Yu=4;nu.interpolateZoom=function(t,e){function n(t){var e=t*v;if(m){var n=it(g),u=a/(ju*f)*(n*at(Ru*e+g)-rt(g));return[r+u*c,i+u*l,a*n/it(Ru*e+g)]}return[r+t*c,i+t*l,a*Math.exp(Ru*e)]}var r=t[0],i=t[1],a=t[2],u=e[0],o=e[1],s=e[2],c=u-r,l=o-i,h=c*c+l*l,f=Math.sqrt(h),d=(s*s-a*a+Yu*h)/(2*a*ju*f),p=(s*s-a*a-Yu*h)/(2*s*ju*f),g=Math.log(Math.sqrt(d*d+1)-d),y=Math.log(Math.sqrt(p*p+1)-p),m=y-g,v=(m||Math.log(s/a))/Ru;return n.duration=1e3*v,n},nu.behavior.zoom=function(){function t(t){t.on(F,h).on($u+".zoom",d).on("dblclick.zoom",p).on(O,f)}function e(t){return[(t[0]-k.x)/k.k,(t[1]-k.y)/k.k]}function r(t){return[t[0]*k.k+k.x,t[1]*k.k+k.y]}function i(t){k.k=Math.max(C[0],Math.min(C[1],t))}function a(t,e){e=r(e),k.x+=t[0]-e[0],k.y+=t[1]-e[1]}function u(e,n,r,u){e.__chart__={x:k.x,y:k.y,k:k.k},i(Math.pow(2,u)),a(y=n,r),e=nu.select(e),S>0&&(e=e.transition().duration(S)),e.call(t.event)}function o(){x&&x.domain(b.range().map(function(t){return(t-k.x)/k.k}).map(b.invert)),A&&A.domain(w.range().map(function(t){return(t-k.y)/k.k}).map(w.invert))}function s(t){T++||t({type:"zoomstart"})}function c(t){o(),t({type:"zoom",scale:k.k,translate:[k.x,k.y]})}function l(t){--T||(t({type:"zoomend"}),y=null)}function h(){function t(){h=1,a(nu.mouse(i),d),c(o)}function r(){f.on(B,null).on(L,null),p(h&&nu.event.target===u),l(o)}var i=this,u=nu.event.target,o=N.of(i,arguments),h=0,f=nu.select(n(i)).on(B,t).on(L,r),d=e(nu.mouse(i)),p=Z(i);Ps.call(i),s(o)}function f(){function t(){var t=nu.touches(p);return d=k.k,t.forEach(function(t){t.identifier in y&&(y[t.identifier]=e(t))}),t}function n(){var e=nu.event.target;nu.select(e).on(b,r).on(x,o),w.push(e);for(var n=nu.event.changedTouches,i=0,a=n.length;a>i;++i)y[n[i].identifier]=null;var s=t(),c=Date.now();if(1===s.length){if(500>c-_){var l=s[0];u(p,l,y[l.identifier],Math.floor(Math.log(k.k)/Math.LN2)+1),E()}_=c}else if(s.length>1){var l=s[0],h=s[1],f=l[0]-h[0],d=l[1]-h[1];m=f*f+d*d}}function r(){var t,e,n,r,u=nu.touches(p);Ps.call(p);for(var o=0,s=u.length;s>o;++o,r=null)if(n=u[o],r=y[n.identifier]){if(e)break;t=n,e=r}if(r){var l=(l=n[0]-t[0])*l+(l=n[1]-t[1])*l,h=m&&Math.sqrt(l/m);t=[(t[0]+n[0])/2,(t[1]+n[1])/2],e=[(e[0]+r[0])/2,(e[1]+r[1])/2],i(h*d)}_=null,a(t,e),c(g)}function o(){if(nu.event.touches.length){for(var e=nu.event.changedTouches,n=0,r=e.length;r>n;++n)delete y[e[n].identifier];for(var i in y)return void t()}nu.selectAll(w).on(v,null),A.on(F,h).on(O,f),D(),l(g)}var d,p=this,g=N.of(p,arguments),y={},m=0,v=".zoom-"+nu.event.changedTouches[0].identifier,b="touchmove"+v,x="touchend"+v,w=[],A=nu.select(p),D=Z(p);n(),s(g),A.on(F,null).on(O,n)}function d(){var t=N.of(this,arguments);v?clearTimeout(v):(Ps.call(this),g=e(y=m||nu.mouse(this)),s(t)),v=setTimeout(function(){v=null,l(t)},50),E(),i(Math.pow(2,.002*Uu())*k.k),a(y,g),c(t)}function p(){var t=nu.mouse(this),n=Math.log(k.k)/Math.LN2;u(this,t,e(t),nu.event.shiftKey?Math.ceil(n)-1:Math.floor(n)+1)}var g,y,m,v,_,b,x,w,A,k={x:0,y:0,k:1},D=[960,500],C=zu,S=250,T=0,F="mousedown.zoom",B="mousemove.zoom",L="mouseup.zoom",O="touchstart.zoom",N=M(t,"zoomstart","zoom","zoomend");return $u||($u="onwheel"in au?(Uu=function(){return-nu.event.deltaY*(nu.event.deltaMode?120:1)},"wheel"):"onmousewheel"in au?(Uu=function(){return nu.event.wheelDelta},"mousewheel"):(Uu=function(){return-nu.event.detail},"MozMousePixelScroll")),t.event=function(t){t.each(function(){var t=N.of(this,arguments),e=k;Ns?nu.select(this).transition().each("start.zoom",function(){k=this.__chart__||{x:0,y:0,k:1},s(t)}).tween("zoom:zoom",function(){var n=D[0],r=D[1],i=y?y[0]:n/2,a=y?y[1]:r/2,u=nu.interpolateZoom([(i-k.x)/k.k,(a-k.y)/k.k,n/k.k],[(i-e.x)/e.k,(a-e.y)/e.k,n/e.k]);return function(e){var r=u(e),o=n/r[2];this.__chart__=k={x:i-r[0]*o,y:a-r[1]*o,k:o},c(t)}}).each("interrupt.zoom",function(){l(t)}).each("end.zoom",function(){l(t)}):(this.__chart__=k,s(t),c(t),l(t))})},t.translate=function(e){return arguments.length?(k={x:+e[0],y:+e[1],k:k.k},o(),t):[k.x,k.y]},t.scale=function(e){return arguments.length?(k={x:k.x,y:k.y,k:+e},o(),t):k.k},t.scaleExtent=function(e){return arguments.length?(C=null==e?zu:[+e[0],+e[1]],t):C},t.center=function(e){return arguments.length?(m=e&&[+e[0],+e[1]],t):m},t.size=function(e){return arguments.length?(D=e&&[+e[0],+e[1]],t):D},t.duration=function(e){return arguments.length?(S=+e,t):S},t.x=function(e){return arguments.length?(x=e,b=e.copy(),k={x:0,y:0,k:1},t):x},t.y=function(e){return arguments.length?(A=e,w=e.copy(),k={x:0,y:0,k:1},t):A},nu.rebind(t,N,"on")};var Uu,$u,zu=[0,1/0];nu.color=ot,ot.prototype.toString=function(){return this.rgb()+""},nu.hsl=st;var qu=st.prototype=new ot;qu.brighter=function(t){return t=Math.pow(.7,arguments.length?t:1),new st(this.h,this.s,this.l/t)},qu.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new st(this.h,this.s,t*this.l)},qu.rgb=function(){return ct(this.h,this.s,this.l)},nu.hcl=lt;var Wu=lt.prototype=new ot;Wu.brighter=function(t){return new lt(this.h,this.c,Math.min(100,this.l+Gu*(arguments.length?t:1)))},Wu.darker=function(t){return new lt(this.h,this.c,Math.max(0,this.l-Gu*(arguments.length?t:1)))},Wu.rgb=function(){return ht(this.h,this.c,this.l).rgb()},nu.lab=ft;var Gu=18,Hu=.95047,Vu=1,Xu=1.08883,Zu=ft.prototype=new ot;Zu.brighter=function(t){return new ft(Math.min(100,this.l+Gu*(arguments.length?t:1)),this.a,this.b)},Zu.darker=function(t){return new ft(Math.max(0,this.l-Gu*(arguments.length?t:1)),this.a,this.b)},Zu.rgb=function(){return dt(this.l,this.a,this.b)},nu.rgb=vt;var Ku=vt.prototype=new ot;Ku.brighter=function(t){t=Math.pow(.7,arguments.length?t:1);var e=this.r,n=this.g,r=this.b,i=30;return e||n||r?(e&&i>e&&(e=i),n&&i>n&&(n=i),r&&i>r&&(r=i),new vt(Math.min(255,e/t),Math.min(255,n/t),Math.min(255,r/t))):new vt(i,i,i)},Ku.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new vt(t*this.r,t*this.g,t*this.b)},Ku.hsl=function(){return At(this.r,this.g,this.b)},Ku.toString=function(){return"#"+xt(this.r)+xt(this.g)+xt(this.b)};var Qu=nu.map({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});Qu.forEach(function(t,e){Qu.set(t,_t(e))}),nu.functor=Mt,nu.xhr=Ct(_),nu.dsv=function(t,e){function n(t,n,a){arguments.length<3&&(a=n,n=null);var u=St(t,e,null==n?r:i(n),a);return u.row=function(t){return arguments.length?u.response(null==(n=t)?r:i(t)):n},u}function r(t){return n.parse(t.responseText)}function i(t){return function(e){return n.parse(e.responseText,t)}}function a(e){return e.map(u).join(t)}function u(t){return o.test(t)?'"'+t.replace(/\"/g,'""')+'"':t}var o=new RegExp('["'+t+"\n]"),s=t.charCodeAt(0);return n.parse=function(t,e){var r;return n.parseRows(t,function(t,n){if(r)return r(t,n-1);var i=new Function("d","return {"+t.map(function(t,e){return JSON.stringify(t)+": d["+e+"]"}).join(",")+"}");r=e?function(t,n){return e(i(t),n)}:i})},n.parseRows=function(t,e){function n(){if(l>=c)return u;if(i)return i=!1,a;var e=l;if(34===t.charCodeAt(e)){for(var n=e;n++l;){var r=t.charCodeAt(l++),o=1;if(10===r)i=!0;else if(13===r)i=!0,10===t.charCodeAt(l)&&(++l,++o);else if(r!==s)continue;return t.slice(e,l-o)}return t.slice(e)}for(var r,i,a={},u={},o=[],c=t.length,l=0,h=0;(r=n())!==u;){for(var f=[];r!==a&&r!==u;)f.push(r),r=n();e&&null==(f=e(f,h++))||o.push(f)}return o},n.format=function(e){if(Array.isArray(e[0]))return n.formatRows(e);var r=new v,i=[];return e.forEach(function(t){for(var e in t)r.has(e)||i.push(r.add(e))}),[i.map(u).join(t)].concat(e.map(function(e){return i.map(function(t){return u(e[t])}).join(t)})).join("\n")},n.formatRows=function(t){return t.map(a).join("\n")},n},nu.csv=nu.dsv(",","text/csv"),nu.tsv=nu.dsv(" ","text/tab-separated-values");var Ju,to,eo,no,ro,io=this[x(this,"requestAnimationFrame")]||function(t){setTimeout(t,17)};nu.timer=function(t,e,n){var r=arguments.length;2>r&&(e=0),3>r&&(n=Date.now());var i=n+e,a={c:t,t:i,f:!1,n:null};to?to.n=a:Ju=a, +to=a,eo||(no=clearTimeout(no),eo=1,io(Bt))},nu.timer.flush=function(){Lt(),Ot()},nu.round=function(t,e){return e?Math.round(t*(e=Math.pow(10,e)))/e:Math.round(t)};var ao=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"].map(It);nu.formatPrefix=function(t,e){var n=0;return t&&(0>t&&(t*=-1),e&&(t=nu.round(t,Nt(t,e))),n=1+Math.floor(1e-12+Math.log(t)/Math.LN10),n=Math.max(-24,Math.min(24,3*Math.floor((n-1)/3)))),ao[8+n/3]};var uo=/(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i,oo=nu.map({b:function(t){return t.toString(2)},c:function(t){return String.fromCharCode(t)},o:function(t){return t.toString(8)},x:function(t){return t.toString(16)},X:function(t){return t.toString(16).toUpperCase()},g:function(t,e){return t.toPrecision(e)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},r:function(t,e){return(t=nu.round(t,Nt(t,e))).toFixed(Math.max(0,Math.min(20,Nt(t*(1+1e-15),e))))}}),so=nu.time={},co=Date;jt.prototype={getDate:function(){return this._.getUTCDate()},getDay:function(){return this._.getUTCDay()},getFullYear:function(){return this._.getUTCFullYear()},getHours:function(){return this._.getUTCHours()},getMilliseconds:function(){return this._.getUTCMilliseconds()},getMinutes:function(){return this._.getUTCMinutes()},getMonth:function(){return this._.getUTCMonth()},getSeconds:function(){return this._.getUTCSeconds()},getTime:function(){return this._.getTime()},getTimezoneOffset:function(){return 0},valueOf:function(){return this._.valueOf()},setDate:function(){lo.setUTCDate.apply(this._,arguments)},setDay:function(){lo.setUTCDay.apply(this._,arguments)},setFullYear:function(){lo.setUTCFullYear.apply(this._,arguments)},setHours:function(){lo.setUTCHours.apply(this._,arguments)},setMilliseconds:function(){lo.setUTCMilliseconds.apply(this._,arguments)},setMinutes:function(){lo.setUTCMinutes.apply(this._,arguments)},setMonth:function(){lo.setUTCMonth.apply(this._,arguments)},setSeconds:function(){lo.setUTCSeconds.apply(this._,arguments)},setTime:function(){lo.setTime.apply(this._,arguments)}};var lo=Date.prototype;so.year=Yt(function(t){return t=so.day(t),t.setMonth(0,1),t},function(t,e){t.setFullYear(t.getFullYear()+e)},function(t){return t.getFullYear()}),so.years=so.year.range,so.years.utc=so.year.utc.range,so.day=Yt(function(t){var e=new co(2e3,0);return e.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()),e},function(t,e){t.setDate(t.getDate()+e)},function(t){return t.getDate()-1}),so.days=so.day.range,so.days.utc=so.day.utc.range,so.dayOfYear=function(t){var e=so.year(t);return Math.floor((t-e-6e4*(t.getTimezoneOffset()-e.getTimezoneOffset()))/864e5)},["sunday","monday","tuesday","wednesday","thursday","friday","saturday"].forEach(function(t,e){e=7-e;var n=so[t]=Yt(function(t){return(t=so.day(t)).setDate(t.getDate()-(t.getDay()+e)%7),t},function(t,e){t.setDate(t.getDate()+7*Math.floor(e))},function(t){var n=so.year(t).getDay();return Math.floor((so.dayOfYear(t)+(n+e)%7)/7)-(n!==e)});so[t+"s"]=n.range,so[t+"s"].utc=n.utc.range,so[t+"OfYear"]=function(t){var n=so.year(t).getDay();return Math.floor((so.dayOfYear(t)+(n+e)%7)/7)}}),so.week=so.sunday,so.weeks=so.sunday.range,so.weeks.utc=so.sunday.utc.range,so.weekOfYear=so.sundayOfYear;var ho={"-":"",_:" ",0:"0"},fo=/^\s*\d+/,po=/^%/;nu.locale=function(t){return{numberFormat:Pt(t),timeFormat:$t(t)}};var go=nu.locale({decimal:".",thousands:",",grouping:[3],currency:["$",""],dateTime:"%a %b %e %X %Y",date:"%m/%d/%Y",time:"%H:%M:%S",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"]});nu.format=go.numberFormat,nu.geo={},ce.prototype={s:0,t:0,add:function(t){le(t,this.t,yo),le(yo.s,this.s,this),this.s?this.t+=yo.t:this.s=yo.t},reset:function(){this.s=this.t=0},valueOf:function(){return this.s}};var yo=new ce;nu.geo.stream=function(t,e){t&&mo.hasOwnProperty(t.type)?mo[t.type](t,e):he(t,e)};var mo={Feature:function(t,e){he(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++rt?4*Bu+t:t,xo.lineStart=xo.lineEnd=xo.point=w}};nu.geo.bounds=function(){function t(t,e){_.push(b=[l=t,f=t]),h>e&&(h=e),e>d&&(d=e)}function e(e,n){var r=ge([e*Iu,n*Iu]);if(m){var i=me(m,r),a=[i[1],-i[0],0],u=me(a,i);be(u),u=xe(u);var s=e-p,c=s>0?1:-1,g=u[0]*Pu*c,y=pu(s)>180;if(y^(g>c*p&&c*e>g)){var v=u[1]*Pu;v>d&&(d=v)}else if(g=(g+360)%360-180,y^(g>c*p&&c*e>g)){var v=-u[1]*Pu;h>v&&(h=v)}else h>n&&(h=n),n>d&&(d=n);y?p>e?o(l,e)>o(l,f)&&(f=e):o(e,f)>o(l,f)&&(l=e):f>=l?(l>e&&(l=e),e>f&&(f=e)):e>p?o(l,e)>o(l,f)&&(f=e):o(e,f)>o(l,f)&&(l=e)}else t(e,n);m=r,p=e}function n(){x.point=e}function r(){b[0]=l,b[1]=f,x.point=t,m=null}function i(t,n){if(m){var r=t-p;v+=pu(r)>180?r+(r>0?360:-360):r}else g=t,y=n;xo.point(t,n),e(t,n)}function a(){xo.lineStart()}function u(){i(g,y),xo.lineEnd(),pu(v)>Tu&&(l=-(f=180)),b[0]=l,b[1]=f,m=null}function o(t,e){return(e-=t)<0?e+360:e}function s(t,e){return t[0]-e[0]}function c(t,e){return e[0]<=e[1]?e[0]<=t&&t<=e[1]:tbo?(l=-(f=180),h=-(d=90)):v>Tu?d=90:-Tu>v&&(h=-90),b[0]=l,b[1]=f}};return function(t){d=f=-(l=h=1/0),_=[],nu.geo.stream(t,x);var e=_.length;if(e){_.sort(s);for(var n,r=1,i=_[0],a=[i];e>r;++r)n=_[r],c(n[0],i)||c(n[1],i)?(o(i[0],n[1])>o(i[0],i[1])&&(i[1]=n[1]),o(n[0],i[1])>o(i[0],i[1])&&(i[0]=n[0])):a.push(i=n);for(var u,n,p=-(1/0),e=a.length-1,r=0,i=a[e];e>=r;i=n,++r)n=a[r],(u=o(i[1],n[0]))>p&&(p=u,l=n[0],f=i[1])}return _=b=null,l===1/0||h===1/0?[[0/0,0/0],[0/0,0/0]]:[[l,h],[f,d]]}}(),nu.geo.centroid=function(t){wo=Ao=ko=Eo=Do=Mo=Co=So=To=Fo=Bo=0,nu.geo.stream(t,Lo);var e=To,n=Fo,r=Bo,i=e*e+n*n+r*r;return Fu>i&&(e=Mo,n=Co,r=So,Tu>Ao&&(e=ko,n=Eo,r=Do),i=e*e+n*n+r*r,Fu>i)?[0/0,0/0]:[Math.atan2(n,e)*Pu,nt(r/Math.sqrt(i))*Pu]};var wo,Ao,ko,Eo,Do,Mo,Co,So,To,Fo,Bo,Lo={sphere:w,point:Ae,lineStart:Ee,lineEnd:De,polygonStart:function(){Lo.lineStart=Me},polygonEnd:function(){Lo.lineStart=Ee}},Oo=Le(Se,Pe,je,[-Bu,-Bu/2]),No=1e9;nu.geo.clipExtent=function(){var t,e,n,r,i,a,u={stream:function(t){return i&&(i.valid=!1),i=a(t),i.valid=!0,i},extent:function(o){return arguments.length?(a=ze(t=+o[0][0],e=+o[0][1],n=+o[1][0],r=+o[1][1]),i&&(i.valid=!1,i=null),u):[[t,e],[n,r]]}};return u.extent([[0,0],[960,500]])},(nu.geo.conicEqualArea=function(){return qe(We)}).raw=We,nu.geo.albers=function(){return nu.geo.conicEqualArea().rotate([96,0]).center([-.6,38.7]).parallels([29.5,45.5]).scale(1070)},nu.geo.albersUsa=function(){function t(t){var a=t[0],u=t[1];return e=null,n(a,u),e||(r(a,u),e)||i(a,u),e}var e,n,r,i,a=nu.geo.albers(),u=nu.geo.conicEqualArea().rotate([154,0]).center([-2,58.5]).parallels([55,65]),o=nu.geo.conicEqualArea().rotate([157,0]).center([-3,19.9]).parallels([8,18]),s={point:function(t,n){e=[t,n]}};return t.invert=function(t){var e=a.scale(),n=a.translate(),r=(t[0]-n[0])/e,i=(t[1]-n[1])/e;return(i>=.12&&.234>i&&r>=-.425&&-.214>r?u:i>=.166&&.234>i&&r>=-.214&&-.115>r?o:a).invert(t)},t.stream=function(t){var e=a.stream(t),n=u.stream(t),r=o.stream(t);return{point:function(t,i){e.point(t,i),n.point(t,i),r.point(t,i)},sphere:function(){e.sphere(),n.sphere(),r.sphere()},lineStart:function(){e.lineStart(),n.lineStart(),r.lineStart()},lineEnd:function(){e.lineEnd(),n.lineEnd(),r.lineEnd()},polygonStart:function(){e.polygonStart(),n.polygonStart(),r.polygonStart()},polygonEnd:function(){e.polygonEnd(),n.polygonEnd(),r.polygonEnd()}}},t.precision=function(e){return arguments.length?(a.precision(e),u.precision(e),o.precision(e),t):a.precision()},t.scale=function(e){return arguments.length?(a.scale(e),u.scale(.35*e),o.scale(e),t.translate(a.translate())):a.scale()},t.translate=function(e){if(!arguments.length)return a.translate();var c=a.scale(),l=+e[0],h=+e[1];return n=a.translate(e).clipExtent([[l-.455*c,h-.238*c],[l+.455*c,h+.238*c]]).stream(s).point,r=u.translate([l-.307*c,h+.201*c]).clipExtent([[l-.425*c+Tu,h+.12*c+Tu],[l-.214*c-Tu,h+.234*c-Tu]]).stream(s).point,i=o.translate([l-.205*c,h+.212*c]).clipExtent([[l-.214*c+Tu,h+.166*c+Tu],[l-.115*c-Tu,h+.234*c-Tu]]).stream(s).point,t},t.scale(1070)};var Io,Po,Ro,jo,Yo,Uo,$o={point:w,lineStart:w,lineEnd:w,polygonStart:function(){Po=0,$o.lineStart=Ge},polygonEnd:function(){$o.lineStart=$o.lineEnd=$o.point=w,Io+=pu(Po/2)}},zo={point:He,lineStart:w,lineEnd:w,polygonStart:w,polygonEnd:w},qo={point:Ze,lineStart:Ke,lineEnd:Qe,polygonStart:function(){qo.lineStart=Je},polygonEnd:function(){qo.point=Ze,qo.lineStart=Ke,qo.lineEnd=Qe}};nu.geo.path=function(){function t(t){return t&&("function"==typeof o&&a.pointRadius(+o.apply(this,arguments)),u&&u.valid||(u=i(a)),nu.geo.stream(t,u)),a.result()}function e(){return u=null,t}var n,r,i,a,u,o=4.5;return t.area=function(t){return Io=0,nu.geo.stream(t,i($o)),Io},t.centroid=function(t){return ko=Eo=Do=Mo=Co=So=To=Fo=Bo=0,nu.geo.stream(t,i(qo)),Bo?[To/Bo,Fo/Bo]:So?[Mo/So,Co/So]:Do?[ko/Do,Eo/Do]:[0/0,0/0]},t.bounds=function(t){return Yo=Uo=-(Ro=jo=1/0),nu.geo.stream(t,i(zo)),[[Ro,jo],[Yo,Uo]]},t.projection=function(t){return arguments.length?(i=(n=t)?t.stream||nn(t):_,e()):n},t.context=function(t){return arguments.length?(a=null==(r=t)?new Ve:new tn(t),"function"!=typeof o&&a.pointRadius(o),e()):r},t.pointRadius=function(e){return arguments.length?(o="function"==typeof e?e:(a.pointRadius(+e),+e),t):o},t.projection(nu.geo.albersUsa()).context(null)},nu.geo.transform=function(t){return{stream:function(e){var n=new rn(e);for(var r in t)n[r]=t[r];return n}}},rn.prototype={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()}},nu.geo.projection=un,nu.geo.projectionMutator=on,(nu.geo.equirectangular=function(){return un(cn)}).raw=cn.invert=cn,nu.geo.rotation=function(t){function e(e){return e=t(e[0]*Iu,e[1]*Iu),e[0]*=Pu,e[1]*=Pu,e}return t=hn(t[0]%360*Iu,t[1]*Iu,t.length>2?t[2]*Iu:0),e.invert=function(e){return e=t.invert(e[0]*Iu,e[1]*Iu),e[0]*=Pu,e[1]*=Pu,e},e},ln.invert=cn,nu.geo.circle=function(){function t(){var t="function"==typeof r?r.apply(this,arguments):r,e=hn(-t[0]*Iu,-t[1]*Iu,0).invert,i=[];return n(null,null,1,{point:function(t,n){i.push(t=e(t,n)),t[0]*=Pu,t[1]*=Pu}}),{type:"Polygon",coordinates:[i]}}var e,n,r=[0,0],i=6;return t.origin=function(e){return arguments.length?(r=e,t):r},t.angle=function(r){return arguments.length?(n=gn((e=+r)*Iu,i*Iu),t):e},t.precision=function(r){return arguments.length?(n=gn(e*Iu,(i=+r)*Iu),t):i},t.angle(90)},nu.geo.distance=function(t,e){var n,r=(e[0]-t[0])*Iu,i=t[1]*Iu,a=e[1]*Iu,u=Math.sin(r),o=Math.cos(r),s=Math.sin(i),c=Math.cos(i),l=Math.sin(a),h=Math.cos(a);return Math.atan2(Math.sqrt((n=h*u)*n+(n=c*l-s*h*o)*n),s*l+c*h*o)},nu.geo.graticule=function(){function t(){return{type:"MultiLineString",coordinates:e()}}function e(){return nu.range(Math.ceil(a/y)*y,i,y).map(f).concat(nu.range(Math.ceil(c/m)*m,s,m).map(d)).concat(nu.range(Math.ceil(r/p)*p,n,p).filter(function(t){return pu(t%y)>Tu}).map(l)).concat(nu.range(Math.ceil(o/g)*g,u,g).filter(function(t){return pu(t%m)>Tu}).map(h))}var n,r,i,a,u,o,s,c,l,h,f,d,p=10,g=p,y=90,m=360,v=2.5;return t.lines=function(){return e().map(function(t){return{type:"LineString",coordinates:t}})},t.outline=function(){return{type:"Polygon",coordinates:[f(a).concat(d(s).slice(1),f(i).reverse().slice(1),d(c).reverse().slice(1))]}},t.extent=function(e){return arguments.length?t.majorExtent(e).minorExtent(e):t.minorExtent()},t.majorExtent=function(e){return arguments.length?(a=+e[0][0],i=+e[1][0],c=+e[0][1],s=+e[1][1],a>i&&(e=a,a=i,i=e),c>s&&(e=c,c=s,s=e),t.precision(v)):[[a,c],[i,s]]},t.minorExtent=function(e){return arguments.length?(r=+e[0][0],n=+e[1][0],o=+e[0][1],u=+e[1][1],r>n&&(e=r,r=n,n=e),o>u&&(e=o,o=u,u=e),t.precision(v)):[[r,o],[n,u]]},t.step=function(e){return arguments.length?t.majorStep(e).minorStep(e):t.minorStep()},t.majorStep=function(e){return arguments.length?(y=+e[0],m=+e[1],t):[y,m]},t.minorStep=function(e){return arguments.length?(p=+e[0],g=+e[1],t):[p,g]},t.precision=function(e){return arguments.length?(v=+e,l=mn(o,u,90),h=vn(r,n,v),f=mn(c,s,90),d=vn(a,i,v),t):v},t.majorExtent([[-180,-90+Tu],[180,90-Tu]]).minorExtent([[-180,-80-Tu],[180,80+Tu]])},nu.geo.greatArc=function(){function t(){return{type:"LineString",coordinates:[e||r.apply(this,arguments),n||i.apply(this,arguments)]}}var e,n,r=_n,i=bn;return t.distance=function(){return nu.geo.distance(e||r.apply(this,arguments),n||i.apply(this,arguments))},t.source=function(n){return arguments.length?(r=n,e="function"==typeof n?null:n,t):r},t.target=function(e){return arguments.length?(i=e,n="function"==typeof e?null:e,t):i},t.precision=function(){return arguments.length?t:0},t},nu.geo.interpolate=function(t,e){return xn(t[0]*Iu,t[1]*Iu,e[0]*Iu,e[1]*Iu)},nu.geo.length=function(t){return Wo=0,nu.geo.stream(t,Go),Wo};var Wo,Go={sphere:w,point:w,lineStart:wn,lineEnd:w,polygonStart:w,polygonEnd:w},Ho=An(function(t){return Math.sqrt(2/(1+t))},function(t){return 2*Math.asin(t/2)});(nu.geo.azimuthalEqualArea=function(){return un(Ho)}).raw=Ho;var Vo=An(function(t){var e=Math.acos(t);return e&&e/Math.sin(e)},_);(nu.geo.azimuthalEquidistant=function(){return un(Vo)}).raw=Vo,(nu.geo.conicConformal=function(){return qe(kn)}).raw=kn,(nu.geo.conicEquidistant=function(){return qe(En)}).raw=En;var Xo=An(function(t){return 1/t},Math.atan);(nu.geo.gnomonic=function(){return un(Xo)}).raw=Xo,Dn.invert=function(t,e){return[t,2*Math.atan(Math.exp(e))-Nu]},(nu.geo.mercator=function(){return Mn(Dn)}).raw=Dn;var Zo=An(function(){return 1},Math.asin);(nu.geo.orthographic=function(){return un(Zo)}).raw=Zo;var Ko=An(function(t){return 1/(1+t)},function(t){return 2*Math.atan(t)});(nu.geo.stereographic=function(){return un(Ko)}).raw=Ko,Cn.invert=function(t,e){return[-e,2*Math.atan(Math.exp(t))-Nu]},(nu.geo.transverseMercator=function(){var t=Mn(Cn),e=t.center,n=t.rotate;return t.center=function(t){return t?e([-t[1],t[0]]):(t=e(),[t[1],-t[0]])},t.rotate=function(t){return t?n([t[0],t[1],t.length>2?t[2]+90:90]):(t=n(),[t[0],t[1],t[2]-90])},n([0,0,90])}).raw=Cn,nu.geom={},nu.geom.hull=function(t){function e(t){if(t.length<3)return[];var e,i=Mt(n),a=Mt(r),u=t.length,o=[],s=[];for(e=0;u>e;e++)o.push([+i.call(this,t[e],e),+a.call(this,t[e],e),e]);for(o.sort(Bn),e=0;u>e;e++)s.push([o[e][0],-o[e][1]]);var c=Fn(o),l=Fn(s),h=l[0]===c[0],f=l[l.length-1]===c[c.length-1],d=[];for(e=c.length-1;e>=0;--e)d.push(t[o[c[e]][2]]);for(e=+h;e=r&&c.x<=a&&c.y>=i&&c.y<=u?[[r,u],[a,u],[a,i],[r,i]]:[];l.point=t[o]}),e}function n(t){return t.map(function(t,e){return{x:Math.round(a(t,e)/Tu)*Tu,y:Math.round(u(t,e)/Tu)*Tu,i:e}})}var r=Sn,i=Tn,a=r,u=i,o=us;return t?e(t):(e.links=function(t){return or(n(t)).edges.filter(function(t){return t.l&&t.r}).map(function(e){return{source:t[e.l.i],target:t[e.r.i]}})},e.triangles=function(t){var e=[];return or(n(t)).cells.forEach(function(n,r){for(var i,a,u=n.site,o=n.edges.sort(Wn),s=-1,c=o.length,l=o[c-1].edge,h=l.l===u?l.r:l.l;++s=c,f=r>=l,d=f<<1|h;t.leaf=!1,t=t.nodes[d]||(t.nodes[d]=fr()),h?i=c:o=c,f?u=l:s=l,a(t,e,n,r,i,u,o,s)}var l,h,f,d,p,g,y,m,v,_=Mt(o),b=Mt(s);if(null!=e)g=e,y=n,m=r,v=i;else if(m=v=-(g=y=1/0),h=[],f=[],p=t.length,u)for(d=0;p>d;++d)l=t[d],l.xm&&(m=l.x),l.y>v&&(v=l.y),h.push(l.x),f.push(l.y);else for(d=0;p>d;++d){var x=+_(l=t[d],d),w=+b(l,d);g>x&&(g=x),y>w&&(y=w),x>m&&(m=x),w>v&&(v=w),h.push(x),f.push(w)}var A=m-g,k=v-y;A>k?v=y+A:m=g+k;var E=fr();if(E.add=function(t){a(E,t,+_(t,++d),+b(t,d),g,y,m,v)},E.visit=function(t){dr(t,E,g,y,m,v)},E.find=function(t){return pr(E,t[0],t[1],g,y,m,v)},d=-1,null==e){for(;++d=0?t.slice(0,e):t,r=e>=0?t.slice(e+1):"in";return n=ls.get(n)||cs,r=hs.get(r)||_,xr(r(n.apply(null,ru.call(arguments,1))))},nu.interpolateHcl=Or,nu.interpolateHsl=Nr,nu.interpolateLab=Ir,nu.interpolateRound=Pr,nu.transform=function(t){var e=au.createElementNS(nu.ns.prefix.svg,"g");return(nu.transform=function(t){if(null!=t){e.setAttribute("transform",t);var n=e.transform.baseVal.consolidate()}return new Rr(n?n.matrix:fs)})(t)},Rr.prototype.toString=function(){return"translate("+this.translate+")rotate("+this.rotate+")skewX("+this.skew+")scale("+this.scale+")"};var fs={a:1,b:0,c:0,d:1,e:0,f:0};nu.interpolateTransform=$r,nu.layout={},nu.layout.bundle=function(){return function(t){for(var e=[],n=-1,r=t.length;++no*o/y){if(p>s){var c=e.charge/s;t.px-=a*c,t.py-=u*c}return!0}if(e.point&&s&&p>s){var c=e.pointCharge/s;t.px-=a*c,t.py-=u*c}}return!e.charge}}function e(t){t.px=nu.event.x,t.py=nu.event.y,o.resume()}var n,r,i,a,u,o={},s=nu.dispatch("start","tick","end"),c=[1,1],l=.9,h=ds,f=ps,d=-30,p=gs,g=.1,y=.64,m=[],v=[];return o.tick=function(){if((r*=.99)<.005)return s.end({type:"end",alpha:r=0}),!0;var e,n,o,h,f,p,y,_,b,x=m.length,w=v.length;for(n=0;w>n;++n)o=v[n],h=o.source,f=o.target,_=f.x-h.x,b=f.y-h.y,(p=_*_+b*b)&&(p=r*a[n]*((p=Math.sqrt(p))-i[n])/p,_*=p,b*=p,f.x-=_*(y=h.weight/(f.weight+h.weight)),f.y-=b*y,h.x+=_*(y=1-y),h.y+=b*y);if((y=r*g)&&(_=c[0]/2,b=c[1]/2,n=-1,y))for(;++n0?t:0:t>0&&(s.start({type:"start",alpha:r=t}),nu.timer(o.tick)),o):r},o.start=function(){function t(t,r){if(!n){for(n=new Array(s),o=0;s>o;++o)n[o]=[];for(o=0;l>o;++o){var i=v[o];n[i.source.index].push(i.target),n[i.target.index].push(i.source)}}for(var a,u=n[e],o=-1,c=u.length;++oe;++e)(r=m[e]).index=e,r.weight=0;for(e=0;l>e;++e)r=v[e],"number"==typeof r.source&&(r.source=m[r.source]),"number"==typeof r.target&&(r.target=m[r.target]),++r.source.weight,++r.target.weight;for(e=0;s>e;++e)r=m[e],isNaN(r.x)&&(r.x=t("x",p)),isNaN(r.y)&&(r.y=t("y",g)),isNaN(r.px)&&(r.px=r.x),isNaN(r.py)&&(r.py=r.y);if(i=[],"function"==typeof h)for(e=0;l>e;++e)i[e]=+h.call(this,v[e],e);else for(e=0;l>e;++e)i[e]=h;if(a=[],"function"==typeof f)for(e=0;l>e;++e)a[e]=+f.call(this,v[e],e);else for(e=0;l>e;++e)a[e]=f;if(u=[],"function"==typeof d)for(e=0;s>e;++e)u[e]=+d.call(this,m[e],e);else for(e=0;s>e;++e)u[e]=d;return o.resume()},o.resume=function(){return o.alpha(.1)},o.stop=function(){return o.alpha(0)},o.drag=function(){return n||(n=nu.behavior.drag().origin(_).on("dragstart.force",Vr).on("drag.force",e).on("dragend.force",Xr)),arguments.length?void this.on("mouseover.force",Zr).on("mouseout.force",Kr).call(n):n},nu.rebind(o,s,"on")};var ds=20,ps=1,gs=1/0;nu.layout.hierarchy=function(){function t(i){var a,u=[i],o=[];for(i.depth=0;null!=(a=u.pop());)if(o.push(a),(c=n.call(t,a,a.depth))&&(s=c.length)){for(var s,c,l;--s>=0;)u.push(l=c[s]),l.parent=a,l.depth=a.depth+1;r&&(a.value=0),a.children=c}else r&&(a.value=+r.call(t,a,a.depth)||0),delete a.children;return ei(i,function(t){var n,i;e&&(n=t.children)&&n.sort(e),r&&(i=t.parent)&&(i.value+=t.value)}),o}var e=ii,n=ni,r=ri;return t.sort=function(n){return arguments.length?(e=n,t):e},t.children=function(e){return arguments.length?(n=e,t):n},t.value=function(e){return arguments.length?(r=e,t):r},t.revalue=function(e){return r&&(ti(e,function(t){t.children&&(t.value=0)}),ei(e,function(e){var n;e.children||(e.value=+r.call(t,e,e.depth)||0),(n=e.parent)&&(n.value+=e.value)})),e},t},nu.layout.partition=function(){function t(e,n,r,i){var a=e.children;if(e.x=n,e.y=e.depth*i,e.dx=r,e.dy=i,a&&(u=a.length)){var u,o,s,c=-1;for(r=e.value?r/e.value:0;++ch?-1:1),p=(h-s*d)/nu.sum(c),g=nu.range(s),y=[];return null!=n&&g.sort(n===ys?function(t,e){return c[e]-c[t]}:function(t,e){return n(u[t],u[e])}),g.forEach(function(t){y[t]={data:u[t],value:o=c[t],startAngle:l,endAngle:l+=o*p+d,padAngle:f}}),y}var e=Number,n=ys,r=0,i=Lu,a=0;return t.value=function(n){return arguments.length?(e=n,t):e},t.sort=function(e){return arguments.length?(n=e,t):n},t.startAngle=function(e){return arguments.length?(r=e,t):r},t.endAngle=function(e){return arguments.length?(i=e,t):i},t.padAngle=function(e){return arguments.length?(a=e,t):a},t};var ys={};nu.layout.stack=function(){function t(o,s){if(!(f=o.length))return o;var c=o.map(function(n,r){return e.call(t,n,r)}),l=c.map(function(e){return e.map(function(e,n){return[a.call(t,e,n),u.call(t,e,n)]})}),h=n.call(t,l,s);c=nu.permute(c,h),l=nu.permute(l,h);var f,d,p,g,y=r.call(t,l,s),m=c[0].length;for(p=0;m>p;++p)for(i.call(t,c[0][p],g=y[p],l[0][p][1]),d=1;f>d;++d)i.call(t,c[d][p],g+=l[d-1][p][1],l[d][p][1]);return o}var e=_,n=ci,r=li,i=si,a=ui,u=oi;return t.values=function(n){return arguments.length?(e=n,t):e},t.order=function(e){return arguments.length?(n="function"==typeof e?e:ms.get(e)||ci,t):n},t.offset=function(e){return arguments.length?(r="function"==typeof e?e:vs.get(e)||li,t):r},t.x=function(e){return arguments.length?(a=e,t):a},t.y=function(e){return arguments.length?(u=e,t):u},t.out=function(e){return arguments.length?(i=e,t):i},t};var ms=nu.map({"inside-out":function(t){var e,n,r=t.length,i=t.map(hi),a=t.map(fi),u=nu.range(r).sort(function(t,e){return i[t]-i[e]}),o=0,s=0,c=[],l=[];for(e=0;r>e;++e)n=u[e],s>o?(o+=a[n],c.push(n)):(s+=a[n],l.push(n));return l.reverse().concat(c)},reverse:function(t){return nu.range(t.length).reverse()},"default":ci}),vs=nu.map({silhouette:function(t){var e,n,r,i=t.length,a=t[0].length,u=[],o=0,s=[];for(n=0;a>n;++n){for(e=0,r=0;i>e;e++)r+=t[e][n][1];r>o&&(o=r),u.push(r)}for(n=0;a>n;++n)s[n]=(o-u[n])/2;return s},wiggle:function(t){var e,n,r,i,a,u,o,s,c,l=t.length,h=t[0],f=h.length,d=[];for(d[0]=s=c=0,n=1;f>n;++n){for(e=0,i=0;l>e;++e)i+=t[e][n][1];for(e=0,a=0,o=h[n][0]-h[n-1][0];l>e;++e){for(r=0,u=(t[e][n][1]-t[e][n-1][1])/(2*o);e>r;++r)u+=(t[r][n][1]-t[r][n-1][1])/o;a+=u*t[e][n][1]}d[n]=s-=i?a/i*o:0,c>s&&(c=s)}for(n=0;f>n;++n)d[n]-=c;return d},expand:function(t){var e,n,r,i=t.length,a=t[0].length,u=1/i,o=[];for(n=0;a>n;++n){for(e=0,r=0;i>e;e++)r+=t[e][n][1];if(r)for(e=0;i>e;e++)t[e][n][1]/=r;else for(e=0;i>e;e++)t[e][n][1]=u}for(n=0;a>n;++n)o[n]=0;return o},zero:li});nu.layout.histogram=function(){function t(t,a){for(var u,o,s=[],c=t.map(n,this),l=r.call(this,c,a),h=i.call(this,l,c,a),a=-1,f=c.length,d=h.length-1,p=e?1:1/f;++a0)for(a=-1;++a=l[0]&&o<=l[1]&&(u=s[nu.bisect(h,o,1,d)-1],u.y+=p,u.push(t[a]));return s}var e=!0,n=Number,r=yi,i=pi;return t.value=function(e){return arguments.length?(n=e,t):n},t.range=function(e){return arguments.length?(r=Mt(e),t):r},t.bins=function(e){return arguments.length?(i="number"==typeof e?function(t){return gi(t,e)}:Mt(e),t):i},t.frequency=function(n){return arguments.length?(e=!!n,t):e},t},nu.layout.pack=function(){function t(t,a){var u=n.call(this,t,a),o=u[0],s=i[0],c=i[1],l=null==e?Math.sqrt:"function"==typeof e?e:function(){return e};if(o.x=o.y=0,ei(o,function(t){t.r=+l(t.value)}),ei(o,xi),r){var h=r*(e?1:Math.max(2*o.r/s,2*o.r/c))/2;ei(o,function(t){t.r+=h; -}),ei(o,xi),ei(o,function(t){t.r-=h})}return ki(o,s/2,c/2,e?1:1/Math.max(2*o.r/s,2*o.r/c)),u}var e,n=nu.layout.hierarchy().sort(mi),r=0,i=[1,1];return t.size=function(e){return arguments.length?(i=e,t):i},t.radius=function(n){return arguments.length?(e=null==n||"function"==typeof n?n:+n,t):e},t.padding=function(e){return arguments.length?(r=+e,t):r},Jr(t,n)},nu.layout.tree=function(){function t(t,i){var l=u.call(this,t,i),h=l[0],f=e(h);if(ei(f,n),f.parent.m=-f.z,ti(f,r),c)ti(h,a);else{var d=h,p=h,g=h;ti(h,function(t){t.xp.x&&(p=t),t.depth>g.depth&&(g=t)});var y=o(d,p)/2-d.x,m=s[0]/(p.x+o(p,d)/2+y),v=s[1]/(g.depth||1);ti(h,function(t){t.x=(t.x+y)*m,t.y=t.depth*v})}return l}function e(t){for(var e,n={A:null,children:[t]},r=[n];null!=(e=r.pop());)for(var i,a=e.children,u=0,o=a.length;o>u;++u)r.push((a[u]=i={_:a[u],parent:e,children:(i=a[u].children)&&i.slice()||[],A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:u}).a=i);return n.children[0]}function n(t){var e=t.children,n=t.parent.children,r=t.i?n[t.i-1]:null;if(e.length){Ti(t);var a=(e[0].z+e[e.length-1].z)/2;r?(t.z=r.z+o(t._,r._),t.m=t.z-a):t.z=a}else r&&(t.z=r.z+o(t._,r._));t.parent.A=i(t,r,t.parent.A||n[0])}function r(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function i(t,e,n){if(e){for(var r,i=t,a=t,u=e,s=i.parent.children[0],c=i.m,l=a.m,h=u.m,f=s.m;u=Ci(u),i=Di(i),u&&i;)s=Di(s),a=Ci(a),a.a=t,r=u.z+h-i.z-c+o(u._,i._),r>0&&(Si(Fi(u,t,n),t,r),c+=r,l+=r),h+=u.m,c+=i.m,f+=s.m,l+=a.m;u&&!Ci(a)&&(a.t=u,a.m+=h-l),i&&!Di(s)&&(s.t=i,s.m+=c-f,n=t)}return n}function a(t){t.x*=s[0],t.y=t.depth*s[1]}var u=nu.layout.hierarchy().sort(null).value(null),o=Mi,s=[1,1],c=null;return t.separation=function(e){return arguments.length?(o=e,t):o},t.size=function(e){return arguments.length?(c=null==(s=e)?a:null,t):c?null:s},t.nodeSize=function(e){return arguments.length?(c=null==(s=e)?null:a,t):c?s:null},Jr(t,u)},nu.layout.cluster=function(){function t(t,a){var u,o=e.call(this,t,a),s=o[0],c=0;ei(s,function(t){var e=t.children;e&&e.length?(t.x=Li(e),t.y=Bi(e)):(t.x=u?c+=n(t,u):0,t.y=0,u=t)});var l=Oi(s),h=Ii(s),f=l.x-n(l,h)/2,d=h.x+n(h,l)/2;return ei(s,i?function(t){t.x=(t.x-s.x)*r[0],t.y=(s.y-t.y)*r[1]}:function(t){t.x=(t.x-f)/(d-f)*r[0],t.y=(1-(s.y?t.y/s.y:1))*r[1]}),o}var e=nu.layout.hierarchy().sort(null).value(null),n=Mi,r=[1,1],i=!1;return t.separation=function(e){return arguments.length?(n=e,t):n},t.size=function(e){return arguments.length?(i=null==(r=e),t):i?null:r},t.nodeSize=function(e){return arguments.length?(i=null!=(r=e),t):i?r:null},Jr(t,e)},nu.layout.treemap=function(){function t(t,e){for(var n,r,i=-1,a=t.length;++ie?0:e),n.area=isNaN(r)||0>=r?0:r}function e(n){var a=n.children;if(a&&a.length){var u,o,s,c=h(n),l=[],f=a.slice(),p=1/0,g="slice"===d?c.dx:"dice"===d?c.dy:"slice-dice"===d?1&n.depth?c.dy:c.dx:Math.min(c.dx,c.dy);for(t(f,c.dx*c.dy/n.value),l.area=0;(s=f.length)>0;)l.push(u=f[s-1]),l.area+=u.area,"squarify"!==d||(o=r(l,g))<=p?(f.pop(),p=o):(l.area-=l.pop().area,i(l,g,c,!1),g=Math.min(c.dx,c.dy),l.length=l.area=0,p=1/0);l.length&&(i(l,g,c,!0),l.length=l.area=0),a.forEach(e)}}function n(e){var r=e.children;if(r&&r.length){var a,u=h(e),o=r.slice(),s=[];for(t(o,u.dx*u.dy/e.value),s.area=0;a=o.pop();)s.push(a),s.area+=a.area,null!=a.z&&(i(s,a.z?u.dx:u.dy,u,!o.length),s.length=s.area=0);r.forEach(n)}}function r(t,e){for(var n,r=t.area,i=0,a=1/0,u=-1,o=t.length;++un&&(a=n),n>i&&(i=n));return r*=r,e*=e,r?Math.max(e*i*p/r,r/(e*a*p)):1/0}function i(t,e,n,r){var i,a=-1,u=t.length,o=n.x,c=n.y,l=e?s(t.area/e):0;if(e==n.dx){for((r||l>n.dy)&&(l=n.dy);++an.dx)&&(l=n.dx);++an&&(e=1),1>n&&(t=0),function(){var n,r,i;do n=2*Math.random()-1,r=2*Math.random()-1,i=n*n+r*r;while(!i||i>1);return t+e*n*Math.sqrt(-2*Math.log(i)/i)}},logNormal:function(){var t=nu.random.normal.apply(nu,arguments);return function(){return Math.exp(t())}},bates:function(t){var e=nu.random.irwinHall(t);return function(){return e()/t}},irwinHall:function(t){return function(){for(var e=0,n=0;t>n;n++)e+=Math.random();return e}}},nu.scale={};var _s={floor:_,ceil:_};nu.scale.linear=function(){return qi([0,1],[0,1],_r,!1)};var bs={s:1,g:1,p:1,r:1,e:1};nu.scale.log=function(){return Qi(nu.scale.linear().domain([0,1]),10,!0,[1,10])};var xs=nu.format(".0e"),ws={floor:function(t){return-Math.ceil(-t)},ceil:function(t){return-Math.floor(-t)}};nu.scale.pow=function(){return Ji(nu.scale.linear(),1,[0,1])},nu.scale.sqrt=function(){return nu.scale.pow().exponent(.5)},nu.scale.ordinal=function(){return ea([],{t:"range",a:[[]]})},nu.scale.category10=function(){return nu.scale.ordinal().range(As)},nu.scale.category20=function(){return nu.scale.ordinal().range(ks)},nu.scale.category20b=function(){return nu.scale.ordinal().range(Es)},nu.scale.category20c=function(){return nu.scale.ordinal().range(Ms)};var As=[2062260,16744206,2924588,14034728,9725885,9197131,14907330,8355711,12369186,1556175].map(bt),ks=[2062260,11454440,16744206,16759672,2924588,10018698,14034728,16750742,9725885,12955861,9197131,12885140,14907330,16234194,8355711,13092807,12369186,14408589,1556175,10410725].map(bt),Es=[3750777,5395619,7040719,10264286,6519097,9216594,11915115,13556636,9202993,12426809,15186514,15190932,8666169,11356490,14049643,15177372,8077683,10834324,13528509,14589654].map(bt),Ms=[3244733,7057110,10406625,13032431,15095053,16616764,16625259,16634018,3253076,7652470,10607003,13101504,7695281,10394312,12369372,14342891,6513507,9868950,12434877,14277081].map(bt);nu.scale.quantile=function(){return na([],[])},nu.scale.quantize=function(){return ra(0,1,[0,1])},nu.scale.threshold=function(){return ia([.5],[0,1])},nu.scale.identity=function(){return aa([0,1])},nu.svg={},nu.svg.arc=function(){function t(){var t=Math.max(0,+n.apply(this,arguments)),c=Math.max(0,+r.apply(this,arguments)),l=u.apply(this,arguments)-Iu,h=o.apply(this,arguments)-Iu,f=Math.abs(h-l),d=l>h?0:1;if(t>c&&(p=c,c=t,t=p),f>=Ou)return e(c,d)+(t?e(t,1-d):"")+"Z";var p,g,y,m,v,_,b,x,w,A,k,E,M=0,D=0,C=[];if((m=(+s.apply(this,arguments)||0)/2)&&(y=a===Ds?Math.sqrt(t*t+c*c):+a.apply(this,arguments),d||(D*=-1),c&&(D=nt(y/c*Math.sin(m))),t&&(M=nt(y/t*Math.sin(m)))),c){v=c*Math.cos(l+D),_=c*Math.sin(l+D),b=c*Math.cos(h-D),x=c*Math.sin(h-D);var S=Math.abs(h-l-2*D)<=Bu?0:1;if(D&&fa(v,_,b,x)===d^S){var T=(l+h)/2;v=c*Math.cos(T),_=c*Math.sin(T),b=x=null}}else v=_=0;if(t){w=t*Math.cos(h-M),A=t*Math.sin(h-M),k=t*Math.cos(l+M),E=t*Math.sin(l+M);var F=Math.abs(l-h+2*M)<=Bu?0:1;if(M&&fa(w,A,k,E)===1-d^F){var B=(l+h)/2;w=t*Math.cos(B),A=t*Math.sin(B),k=E=null}}else w=A=0;if((p=Math.min(Math.abs(c-t)/2,+i.apply(this,arguments)))>.001){g=c>t^d?0:1;var L=null==k?[w,A]:null==b?[v,_]:On([v,_],[k,E],[b,x],[w,A]),O=v-L[0],I=_-L[1],N=b-L[0],P=x-L[1],R=1/Math.sin(Math.acos((O*N+I*P)/(Math.sqrt(O*O+I*I)*Math.sqrt(N*N+P*P)))/2),j=Math.sqrt(L[0]*L[0]+L[1]*L[1]);if(null!=b){var Y=Math.min(p,(c-j)/(R+1)),U=da(null==k?[w,A]:[k,E],[v,_],c,Y,d),$=da([b,x],[w,A],c,Y,d);p===Y?C.push("M",U[0],"A",Y,",",Y," 0 0,",g," ",U[1],"A",c,",",c," 0 ",1-d^fa(U[1][0],U[1][1],$[1][0],$[1][1]),",",d," ",$[1],"A",Y,",",Y," 0 0,",g," ",$[0]):C.push("M",U[0],"A",Y,",",Y," 0 1,",g," ",$[0])}else C.push("M",v,",",_);if(null!=k){var z=Math.min(p,(t-j)/(R-1)),q=da([v,_],[k,E],t,-z,d),W=da([w,A],null==b?[v,_]:[b,x],t,-z,d);p===z?C.push("L",W[0],"A",z,",",z," 0 0,",g," ",W[1],"A",t,",",t," 0 ",d^fa(W[1][0],W[1][1],q[1][0],q[1][1]),",",1-d," ",q[1],"A",z,",",z," 0 0,",g," ",q[0]):C.push("L",W[0],"A",z,",",z," 0 0,",g," ",q[0])}else C.push("L",w,",",A)}else C.push("M",v,",",_),null!=b&&C.push("A",c,",",c," 0 ",S,",",d," ",b,",",x),C.push("L",w,",",A),null!=k&&C.push("A",t,",",t," 0 ",F,",",1-d," ",k,",",E);return C.push("Z"),C.join("")}function e(t,e){return"M0,"+t+"A"+t+","+t+" 0 1,"+e+" 0,"+-t+"A"+t+","+t+" 0 1,"+e+" 0,"+t}var n=oa,r=sa,i=ua,a=Ds,u=ca,o=la,s=ha;return t.innerRadius=function(e){return arguments.length?(n=Dt(e),t):n},t.outerRadius=function(e){return arguments.length?(r=Dt(e),t):r},t.cornerRadius=function(e){return arguments.length?(i=Dt(e),t):i},t.padRadius=function(e){return arguments.length?(a=e==Ds?Ds:Dt(e),t):a},t.startAngle=function(e){return arguments.length?(u=Dt(e),t):u},t.endAngle=function(e){return arguments.length?(o=Dt(e),t):o},t.padAngle=function(e){return arguments.length?(s=Dt(e),t):s},t.centroid=function(){var t=(+n.apply(this,arguments)+ +r.apply(this,arguments))/2,e=(+u.apply(this,arguments)+ +o.apply(this,arguments))/2-Iu;return[Math.cos(e)*t,Math.sin(e)*t]},t};var Ds="auto";nu.svg.line=function(){return pa(_)};var Cs=nu.map({linear:ga,"linear-closed":ya,step:ma,"step-before":va,"step-after":_a,basis:Ea,"basis-open":Ma,"basis-closed":Da,bundle:Ca,cardinal:wa,"cardinal-open":ba,"cardinal-closed":xa,monotone:Oa});Cs.forEach(function(t,e){e.key=t,e.closed=/-closed$/.test(t)});var Ss=[0,2/3,1/3,0],Ts=[0,1/3,2/3,0],Fs=[0,1/6,2/3,1/6];nu.svg.line.radial=function(){var t=pa(Ia);return t.radius=t.x,delete t.x,t.angle=t.y,delete t.y,t},va.reverse=_a,_a.reverse=va,nu.svg.area=function(){return Na(_)},nu.svg.area.radial=function(){var t=Na(Ia);return t.radius=t.x,delete t.x,t.innerRadius=t.x0,delete t.x0,t.outerRadius=t.x1,delete t.x1,t.angle=t.y,delete t.y,t.startAngle=t.y0,delete t.y0,t.endAngle=t.y1,delete t.y1,t},nu.svg.chord=function(){function t(t,o){var s=e(this,a,t,o),c=e(this,u,t,o);return"M"+s.p0+r(s.r,s.p1,s.a1-s.a0)+(n(s,c)?i(s.r,s.p1,s.r,s.p0):i(s.r,s.p1,c.r,c.p0)+r(c.r,c.p1,c.a1-c.a0)+i(c.r,c.p1,s.r,s.p0))+"Z"}function e(t,e,n,r){var i=e.call(t,n,r),a=o.call(t,i,r),u=s.call(t,i,r)-Iu,l=c.call(t,i,r)-Iu;return{r:a,a0:u,a1:l,p0:[a*Math.cos(u),a*Math.sin(u)],p1:[a*Math.cos(l),a*Math.sin(l)]}}function n(t,e){return t.a0==e.a0&&t.a1==e.a1}function r(t,e,n){return"A"+t+","+t+" 0 "+ +(n>Bu)+",1 "+e}function i(t,e,n,r){return"Q 0,0 "+r}var a=_n,u=bn,o=Pa,s=ca,c=la;return t.radius=function(e){return arguments.length?(o=Dt(e),t):o},t.source=function(e){return arguments.length?(a=Dt(e),t):a},t.target=function(e){return arguments.length?(u=Dt(e),t):u},t.startAngle=function(e){return arguments.length?(s=Dt(e),t):s},t.endAngle=function(e){return arguments.length?(c=Dt(e),t):c},t},nu.svg.diagonal=function(){function t(t,i){var a=e.call(this,t,i),u=n.call(this,t,i),o=(a.y+u.y)/2,s=[a,{x:a.x,y:o},{x:u.x,y:o},u];return s=s.map(r),"M"+s[0]+"C"+s[1]+" "+s[2]+" "+s[3]}var e=_n,n=bn,r=Ra;return t.source=function(n){return arguments.length?(e=Dt(n),t):e},t.target=function(e){return arguments.length?(n=Dt(e),t):n},t.projection=function(e){return arguments.length?(r=e,t):r},t},nu.svg.diagonal.radial=function(){var t=nu.svg.diagonal(),e=Ra,n=t.projection;return t.projection=function(t){return arguments.length?n(ja(e=t)):e},t},nu.svg.symbol=function(){function t(t,r){return(Bs.get(e.call(this,t,r))||$a)(n.call(this,t,r))}var e=Ua,n=Ya;return t.type=function(n){return arguments.length?(e=Dt(n),t):e},t.size=function(e){return arguments.length?(n=Dt(e),t):n},t};var Bs=nu.map({circle:$a,cross:function(t){var e=Math.sqrt(t/5)/2;return"M"+-3*e+","+-e+"H"+-e+"V"+-3*e+"H"+e+"V"+-e+"H"+3*e+"V"+e+"H"+e+"V"+3*e+"H"+-e+"V"+e+"H"+-3*e+"Z"},diamond:function(t){var e=Math.sqrt(t/(2*Os)),n=e*Os;return"M0,"+-e+"L"+n+",0 0,"+e+" "+-n+",0Z"},square:function(t){var e=Math.sqrt(t)/2;return"M"+-e+","+-e+"L"+e+","+-e+" "+e+","+e+" "+-e+","+e+"Z"},"triangle-down":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+n+"L"+e+","+-n+" "+-e+","+-n+"Z"},"triangle-up":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+-n+"L"+e+","+n+" "+-e+","+n+"Z"}});nu.svg.symbolTypes=Bs.keys();var Ls=Math.sqrt(3),Os=Math.tan(30*Nu);Au.transition=function(t){for(var e,n,r=Is||++js,i=Ha(t),a=[],u=Ns||{time:Date.now(),ease:Mr,delay:0,duration:250},o=-1,s=this.length;++oa;a++){i.push(e=[]);for(var n=this[a],o=0,s=n.length;s>o;o++)(r=n[o])&&t.call(r,r.__data__,o,a)&&e.push(r)}return qa(i,this.namespace,this.id)},Rs.tween=function(t,e){var n=this.id,r=this.namespace;return arguments.length<2?this.node()[r][n].tween.get(t):q(this,null==e?function(e){e[r][n].tween.remove(t)}:function(i){i[r][n].tween.set(t,e)})},Rs.attr=function(t,e){function n(){this.removeAttribute(o)}function r(){this.removeAttributeNS(o.space,o.local)}function i(t){return null==t?n:(t+="",function(){var e,n=this.getAttribute(o);return n!==t&&(e=u(n,t),function(t){this.setAttribute(o,e(t))})})}function a(t){return null==t?r:(t+="",function(){var e,n=this.getAttributeNS(o.space,o.local);return n!==t&&(e=u(n,t),function(t){this.setAttributeNS(o.space,o.local,e(t))})})}if(arguments.length<2){for(e in t)this.attr(e,t[e]);return this}var u="transform"==t?$r:_r,o=nu.ns.qualify(t);return Wa(this,"attr."+t,e,o.local?a:i)},Rs.attrTween=function(t,e){function n(t,n){var r=e.call(this,t,n,this.getAttribute(i));return r&&function(t){this.setAttribute(i,r(t))}}function r(t,n){var r=e.call(this,t,n,this.getAttributeNS(i.space,i.local));return r&&function(t){this.setAttributeNS(i.space,i.local,r(t))}}var i=nu.ns.qualify(t);return this.tween("attr."+t,i.local?r:n)},Rs.style=function(t,e,r){function i(){this.style.removeProperty(t)}function a(e){return null==e?i:(e+="",function(){var i,a=n(this).getComputedStyle(this,null).getPropertyValue(t);return a!==e&&(i=_r(a,e),function(e){this.style.setProperty(t,i(e),r)})})}var u=arguments.length;if(3>u){if("string"!=typeof t){2>u&&(e="");for(r in t)this.style(r,t[r],e);return this}r=""}return Wa(this,"style."+t,e,a)},Rs.styleTween=function(t,e,r){function i(i,a){var u=e.call(this,i,a,n(this).getComputedStyle(this,null).getPropertyValue(t));return u&&function(e){this.style.setProperty(t,u(e),r)}}return arguments.length<3&&(r=""),this.tween("style."+t,i)},Rs.text=function(t){return Wa(this,"text",t,Ga)},Rs.remove=function(){var t=this.namespace;return this.each("end.transition",function(){var e;this[t].count<2&&(e=this.parentNode)&&e.removeChild(this)})},Rs.ease=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].ease:("function"!=typeof t&&(t=nu.ease.apply(nu,arguments)),q(this,function(r){r[n][e].ease=t}))},Rs.delay=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].delay:q(this,"function"==typeof t?function(r,i,a){r[n][e].delay=+t.call(r,r.__data__,i,a)}:(t=+t,function(r){r[n][e].delay=t}))},Rs.duration=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].duration:q(this,"function"==typeof t?function(r,i,a){r[n][e].duration=Math.max(1,t.call(r,r.__data__,i,a))}:(t=Math.max(1,t),function(r){r[n][e].duration=t}))},Rs.each=function(t,e){var n=this.id,r=this.namespace;if(arguments.length<2){var i=Ns,a=Is;try{Is=n,q(this,function(e,i,a){Ns=e[r][n],t.call(e,e.__data__,i,a)})}finally{Ns=i,Is=a}}else q(this,function(i){var a=i[r][n];(a.event||(a.event=nu.dispatch("start","end","interrupt"))).on(t,e)});return this},Rs.transition=function(){for(var t,e,n,r,i=this.id,a=++js,u=this.namespace,o=[],s=0,c=this.length;c>s;s++){o.push(t=[]);for(var e=this[s],l=0,h=e.length;h>l;l++)(n=e[l])&&(r=n[u][i],Va(n,l,u,a,{time:r.time,ease:r.ease,delay:r.delay+r.duration,duration:r.duration})),t.push(n)}return qa(o,u,a)},nu.svg.axis=function(){function t(t){t.each(function(){var t,c=nu.select(this),l=this.__chart__||n,h=this.__chart__=n.copy(),f=null==s?h.ticks?h.ticks.apply(h,o):h.domain():s,d=null==e?h.tickFormat?h.tickFormat.apply(h,o):_:e,p=c.selectAll(".tick").data(f,h),g=p.enter().insert("g",".domain").attr("class","tick").style("opacity",Tu),y=nu.transition(p.exit()).style("opacity",Tu).remove(),m=nu.transition(p.order()).style("opacity",1),v=Math.max(i,0)+u,b=ji(h),x=c.selectAll(".domain").data([0]),w=(x.enter().append("path").attr("class","domain"),nu.transition(x));g.append("line"),g.append("text");var A,k,E,M,D=g.select("line"),C=m.select("line"),S=p.select("text").text(d),T=g.select("text"),F=m.select("text"),B="top"===r||"left"===r?-1:1;if("bottom"===r||"top"===r?(t=Xa,A="x",E="y",k="x2",M="y2",S.attr("dy",0>B?"0em":".71em").style("text-anchor","middle"),w.attr("d","M"+b[0]+","+B*a+"V0H"+b[1]+"V"+B*a)):(t=Za,A="y",E="x",k="y2",M="x2",S.attr("dy",".32em").style("text-anchor",0>B?"end":"start"),w.attr("d","M"+B*a+","+b[0]+"H0V"+b[1]+"H"+B*a)),D.attr(M,B*i),T.attr(E,B*v),C.attr(k,0).attr(M,B*i),F.attr(A,0).attr(E,B*v),h.rangeBand){var L=h,O=L.rangeBand()/2;l=h=function(t){return L(t)+O}}else l.rangeBand?l=h:y.call(t,h,l);g.call(t,l,h),m.call(t,h,h)})}var e,n=nu.scale.linear(),r=Ys,i=6,a=6,u=3,o=[10],s=null;return t.scale=function(e){return arguments.length?(n=e,t):n},t.orient=function(e){return arguments.length?(r=e in Us?e+"":Ys,t):r},t.ticks=function(){return arguments.length?(o=arguments,t):o},t.tickValues=function(e){return arguments.length?(s=e,t):s},t.tickFormat=function(n){return arguments.length?(e=n,t):e},t.tickSize=function(e){var n=arguments.length;return n?(i=+e,a=+arguments[n-1],t):i},t.innerTickSize=function(e){return arguments.length?(i=+e,t):i},t.outerTickSize=function(e){return arguments.length?(a=+e,t):a},t.tickPadding=function(e){return arguments.length?(u=+e,t):u},t.tickSubdivide=function(){return arguments.length&&t},t};var Ys="bottom",Us={top:1,right:1,bottom:1,left:1};nu.svg.brush=function(){function t(n){n.each(function(){var n=nu.select(this).style("pointer-events","all").style("-webkit-tap-highlight-color","rgba(0,0,0,0)").on("mousedown.brush",a).on("touchstart.brush",a),u=n.selectAll(".background").data([0]);u.enter().append("rect").attr("class","background").style("visibility","hidden").style("cursor","crosshair"),n.selectAll(".extent").data([0]).enter().append("rect").attr("class","extent").style("cursor","move");var o=n.selectAll(".resize").data(g,_);o.exit().remove(),o.enter().append("g").attr("class",function(t){return"resize "+t}).style("cursor",function(t){return $s[t]}).append("rect").attr("x",function(t){return/[ew]$/.test(t)?-3:null}).attr("y",function(t){return/^[ns]/.test(t)?-3:null}).attr("width",6).attr("height",6).style("visibility","hidden"),o.style("display",t.empty()?"none":null);var s,h=nu.transition(n),f=nu.transition(u);c&&(s=ji(c),f.attr("x",s[0]).attr("width",s[1]-s[0]),r(h)),l&&(s=ji(l),f.attr("y",s[0]).attr("height",s[1]-s[0]),i(h)),e(h)})}function e(t){t.selectAll(".resize").attr("transform",function(t){return"translate("+h[+/e$/.test(t)]+","+f[+/^s/.test(t)]+")"})}function r(t){t.select(".extent").attr("x",h[0]),t.selectAll(".extent,.n>rect,.s>rect").attr("width",h[1]-h[0])}function i(t){t.select(".extent").attr("y",f[0]),t.selectAll(".extent,.e>rect,.w>rect").attr("height",f[1]-f[0])}function a(){function a(){32==nu.event.keyCode&&(S||(_=null,F[0]-=h[1],F[1]-=f[1],S=2),E())}function g(){32==nu.event.keyCode&&2==S&&(F[0]+=h[1],F[1]+=f[1],S=0,E())}function y(){var t=nu.mouse(x),n=!1;b&&(t[0]+=b[0],t[1]+=b[1]),S||(nu.event.altKey?(_||(_=[(h[0]+h[1])/2,(f[0]+f[1])/2]),F[0]=h[+(t[0]<_[0])],F[1]=f[+(t[1]<_[1])]):_=null),D&&m(t,c,0)&&(r(k),n=!0),C&&m(t,l,1)&&(i(k),n=!0),n&&(e(k),A({type:"brush",mode:S?"move":"resize"}))}function m(t,e,n){var r,i,a=ji(e),s=a[0],c=a[1],l=F[n],g=n?f:h,y=g[1]-g[0];return S&&(s-=l,c-=y+l),r=(n?p:d)?Math.max(s,Math.min(c,t[n])):t[n],S?i=(r+=l)+y:(_&&(l=Math.max(s,Math.min(c,2*_[n]-r))),r>l?(i=r,r=l):i=l),g[0]!=r||g[1]!=i?(n?o=null:u=null,g[0]=r,g[1]=i,!0):void 0}function v(){y(),k.style("pointer-events","all").selectAll(".resize").style("display",t.empty()?"none":null),nu.select("body").style("cursor",null),B.on("mousemove.brush",null).on("mouseup.brush",null).on("touchmove.brush",null).on("touchend.brush",null).on("keydown.brush",null).on("keyup.brush",null),T(),A({type:"brushend"})}var _,b,x=this,w=nu.select(nu.event.target),A=s.of(x,arguments),k=nu.select(x),M=w.datum(),D=!/^(n|s)$/.test(M)&&c,C=!/^(e|w)$/.test(M)&&l,S=w.classed("extent"),T=Z(x),F=nu.mouse(x),B=nu.select(n(x)).on("keydown.brush",a).on("keyup.brush",g);if(nu.event.changedTouches?B.on("touchmove.brush",y).on("touchend.brush",v):B.on("mousemove.brush",y).on("mouseup.brush",v),k.interrupt().selectAll("*").interrupt(),S)F[0]=h[0]-F[0],F[1]=f[0]-F[1];else if(M){var L=+/w$/.test(M),O=+/^n/.test(M);b=[h[1-L]-F[0],f[1-O]-F[1]],F[0]=h[L],F[1]=f[O]}else nu.event.altKey&&(_=F.slice());k.style("pointer-events","none").selectAll(".resize").style("display",null),nu.select("body").style("cursor",w.style("cursor")),A({type:"brushstart"}),y()}var u,o,s=D(t,"brushstart","brush","brushend"),c=null,l=null,h=[0,0],f=[0,0],d=!0,p=!0,g=zs[0];return t.event=function(t){t.each(function(){var t=s.of(this,arguments),e={x:h,y:f,i:u,j:o},n=this.__chart__||e;this.__chart__=e,Is?nu.select(this).transition().each("start.brush",function(){u=n.i,o=n.j,h=n.x,f=n.y,t({type:"brushstart"})}).tween("brush:brush",function(){var n=br(h,e.x),r=br(f,e.y);return u=o=null,function(i){h=e.x=n(i),f=e.y=r(i),t({type:"brush",mode:"resize"})}}).each("end.brush",function(){u=e.i,o=e.j,t({type:"brush",mode:"resize"}),t({type:"brushend"})}):(t({type:"brushstart"}),t({type:"brush",mode:"resize"}),t({type:"brushend"}))})},t.x=function(e){return arguments.length?(c=e,g=zs[!c<<1|!l],t):c},t.y=function(e){return arguments.length?(l=e,g=zs[!c<<1|!l],t):l},t.clamp=function(e){return arguments.length?(c&&l?(d=!!e[0],p=!!e[1]):c?d=!!e:l&&(p=!!e),t):c&&l?[d,p]:c?d:l?p:null},t.extent=function(e){var n,r,i,a,s;return arguments.length?(c&&(n=e[0],r=e[1],l&&(n=n[0],r=r[0]),u=[n,r],c.invert&&(n=c(n),r=c(r)),n>r&&(s=n,n=r,r=s),(n!=h[0]||r!=h[1])&&(h=[n,r])),l&&(i=e[0],a=e[1],c&&(i=i[1],a=a[1]),o=[i,a],l.invert&&(i=l(i),a=l(a)),i>a&&(s=i,i=a,a=s),(i!=f[0]||a!=f[1])&&(f=[i,a])),t):(c&&(u?(n=u[0],r=u[1]):(n=h[0],r=h[1],c.invert&&(n=c.invert(n),r=c.invert(r)),n>r&&(s=n,n=r,r=s))),l&&(o?(i=o[0],a=o[1]):(i=f[0],a=f[1],l.invert&&(i=l.invert(i),a=l.invert(a)),i>a&&(s=i,i=a,a=s))),c&&l?[[n,i],[r,a]]:c?[n,r]:l&&[i,a])},t.clear=function(){return t.empty()||(h=[0,0],f=[0,0],u=o=null),t},t.empty=function(){return!!c&&h[0]==h[1]||!!l&&f[0]==f[1]},nu.rebind(t,s,"on")};var $s={n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},zs=[["n","e","s","w","nw","ne","se","sw"],["e","w"],["n","s"],[]],qs=so.format=go.timeFormat,Ws=qs.utc,Gs=Ws("%Y-%m-%dT%H:%M:%S.%LZ");qs.iso=Date.prototype.toISOString&&+new Date("2000-01-01T00:00:00.000Z")?Ka:Gs,Ka.parse=function(t){var e=new Date(t);return isNaN(e)?null:e},Ka.toString=Gs.toString,so.second=Yt(function(t){return new co(1e3*Math.floor(t/1e3))},function(t,e){t.setTime(t.getTime()+1e3*Math.floor(e))},function(t){return t.getSeconds()}),so.seconds=so.second.range,so.seconds.utc=so.second.utc.range,so.minute=Yt(function(t){return new co(6e4*Math.floor(t/6e4))},function(t,e){t.setTime(t.getTime()+6e4*Math.floor(e))},function(t){return t.getMinutes()}),so.minutes=so.minute.range,so.minutes.utc=so.minute.utc.range,so.hour=Yt(function(t){var e=t.getTimezoneOffset()/60;return new co(36e5*(Math.floor(t/36e5-e)+e))},function(t,e){t.setTime(t.getTime()+36e5*Math.floor(e))},function(t){return t.getHours()}),so.hours=so.hour.range,so.hours.utc=so.hour.utc.range,so.month=Yt(function(t){return t=so.day(t),t.setDate(1),t},function(t,e){t.setMonth(t.getMonth()+e)},function(t){return t.getMonth()}),so.months=so.month.range,so.months.utc=so.month.utc.range;var Hs=[1e3,5e3,15e3,3e4,6e4,3e5,9e5,18e5,36e5,108e5,216e5,432e5,864e5,1728e5,6048e5,2592e6,7776e6,31536e6],Vs=[[so.second,1],[so.second,5],[so.second,15],[so.second,30],[so.minute,1],[so.minute,5],[so.minute,15],[so.minute,30],[so.hour,1],[so.hour,3],[so.hour,6],[so.hour,12],[so.day,1],[so.day,2],[so.week,1],[so.month,1],[so.month,3],[so.year,1]],Xs=qs.multi([[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["%I:%M",function(t){return t.getMinutes()}],["%I %p",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}],["%Y",Se]]),Zs={range:function(t,e,n){return nu.range(Math.ceil(t/n)*n,+e,n).map(Ja)},floor:_,ceil:_};Vs.year=so.year,so.scale=function(){return Qa(nu.scale.linear(),Vs,Xs)};var Ks=Vs.map(function(t){return[t[0].utc,t[1]]}),Qs=Ws.multi([[".%L",function(t){return t.getUTCMilliseconds()}],[":%S",function(t){return t.getUTCSeconds()}],["%I:%M",function(t){return t.getUTCMinutes()}],["%I %p",function(t){return t.getUTCHours()}],["%a %d",function(t){return t.getUTCDay()&&1!=t.getUTCDate()}],["%b %d",function(t){return 1!=t.getUTCDate()}],["%B",function(t){return t.getUTCMonth()}],["%Y",Se]]);Ks.year=so.year.utc,so.scale.utc=function(){return Qa(nu.scale.linear(),Ks,Qs)},nu.text=Ct(function(t){return t.responseText}),nu.json=function(t,e){return St(t,"application/json",tu,e)},nu.html=function(t,e){return St(t,"text/html",eu,e)},nu.xml=Ct(function(t){return t.responseXML}),"function"==typeof define&&define.amd?define(nu):"object"==typeof e&&e.exports&&(e.exports=nu),this.d3=nu}()},{}],5:[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":12,"./lib/graphlib":13,"./lib/intersect":14,"./lib/render":29,"./lib/util":31,"./lib/version":32}],6:[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"),u=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(u,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"),u=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(u,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"),u=i.append("path").attr("d","M 0 5 L 10 5").style("stroke-width",1).style("stroke-dasharray","1,0");a.applyStyle(u,n[r+"Style"])}var a=t("./util");e.exports={"default":n,normal:n,vee:r,undirected:i}},{"./util":31}],7:[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":22,"./util":31}],8:[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(u.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"),u=t("./d3");e.exports=n},{"./d3":11,"./label/add-label":22,"./lodash":25,"./util":31}],9:[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 u(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=s.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,"arrowhead")}),i}function r(t,e){var n=t.edge(e),r=t.node(e.v),a=t.node(e.w),u=n.points.slice(1,n.points.length-1);return u.unshift(c(r,u[0])),u.push(c(a,u[u.length-1])),i(n,u)}function i(t,e){var n=h.svg.line().x(function(t){return t.x}).y(function(t){return t.y});return s.has(t,"lineInterpolate")&&n.interpolate(t.lineInterpolate),s.has(t,"lineTension")&&n.tension(Number(t.lineTension)),n(e)}function a(t){var e=t.getBBox(),n=t.getTransformToElement(t.ownerSVGElement).translate(e.width/2,e.height/2);return{x:n.e,y:n.f}}function u(t,e){var n=t.enter().append("g").attr("class","edgePath").style("opacity",0);n.append("path").attr("class","path").attr("d",function(t){var n=e.edge(t),r=e.node(t.v).elem,u=s.range(n.points.length).map(function(){return a(r)});return i(n,u)}),n.append("defs")}function o(t,e){var n=t.exit();l.applyTransition(n,e).style("opacity",0).remove(),l.applyTransition(n.select("path.path"),e).attr("d",function(t){var n=e.node(t.v);if(n){var r=s.range(this.pathSegList.length).map(function(){return n});return i({},r)}return h.select(this).attr("d")})}var s=t("./lodash"),c=t("./intersect/intersect-node"),l=t("./util"),h=t("./d3");e.exports=n},{"./d3":11,"./intersect/intersect-node":18,"./lodash":25,"./util":31}],10:[function(t,e){"use strict"; +}),ei(o,xi),ei(o,function(t){t.r-=h})}return ki(o,s/2,c/2,e?1:1/Math.max(2*o.r/s,2*o.r/c)),u}var e,n=nu.layout.hierarchy().sort(mi),r=0,i=[1,1];return t.size=function(e){return arguments.length?(i=e,t):i},t.radius=function(n){return arguments.length?(e=null==n||"function"==typeof n?n:+n,t):e},t.padding=function(e){return arguments.length?(r=+e,t):r},Jr(t,n)},nu.layout.tree=function(){function t(t,i){var l=u.call(this,t,i),h=l[0],f=e(h);if(ei(f,n),f.parent.m=-f.z,ti(f,r),c)ti(h,a);else{var d=h,p=h,g=h;ti(h,function(t){t.xp.x&&(p=t),t.depth>g.depth&&(g=t)});var y=o(d,p)/2-d.x,m=s[0]/(p.x+o(p,d)/2+y),v=s[1]/(g.depth||1);ti(h,function(t){t.x=(t.x+y)*m,t.y=t.depth*v})}return l}function e(t){for(var e,n={A:null,children:[t]},r=[n];null!=(e=r.pop());)for(var i,a=e.children,u=0,o=a.length;o>u;++u)r.push((a[u]=i={_:a[u],parent:e,children:(i=a[u].children)&&i.slice()||[],A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:u}).a=i);return n.children[0]}function n(t){var e=t.children,n=t.parent.children,r=t.i?n[t.i-1]:null;if(e.length){Ti(t);var a=(e[0].z+e[e.length-1].z)/2;r?(t.z=r.z+o(t._,r._),t.m=t.z-a):t.z=a}else r&&(t.z=r.z+o(t._,r._));t.parent.A=i(t,r,t.parent.A||n[0])}function r(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function i(t,e,n){if(e){for(var r,i=t,a=t,u=e,s=i.parent.children[0],c=i.m,l=a.m,h=u.m,f=s.m;u=Ci(u),i=Mi(i),u&&i;)s=Mi(s),a=Ci(a),a.a=t,r=u.z+h-i.z-c+o(u._,i._),r>0&&(Si(Fi(u,t,n),t,r),c+=r,l+=r),h+=u.m,c+=i.m,f+=s.m,l+=a.m;u&&!Ci(a)&&(a.t=u,a.m+=h-l),i&&!Mi(s)&&(s.t=i,s.m+=c-f,n=t)}return n}function a(t){t.x*=s[0],t.y=t.depth*s[1]}var u=nu.layout.hierarchy().sort(null).value(null),o=Di,s=[1,1],c=null;return t.separation=function(e){return arguments.length?(o=e,t):o},t.size=function(e){return arguments.length?(c=null==(s=e)?a:null,t):c?null:s},t.nodeSize=function(e){return arguments.length?(c=null==(s=e)?null:a,t):c?s:null},Jr(t,u)},nu.layout.cluster=function(){function t(t,a){var u,o=e.call(this,t,a),s=o[0],c=0;ei(s,function(t){var e=t.children;e&&e.length?(t.x=Li(e),t.y=Bi(e)):(t.x=u?c+=n(t,u):0,t.y=0,u=t)});var l=Oi(s),h=Ni(s),f=l.x-n(l,h)/2,d=h.x+n(h,l)/2;return ei(s,i?function(t){t.x=(t.x-s.x)*r[0],t.y=(s.y-t.y)*r[1]}:function(t){t.x=(t.x-f)/(d-f)*r[0],t.y=(1-(s.y?t.y/s.y:1))*r[1]}),o}var e=nu.layout.hierarchy().sort(null).value(null),n=Di,r=[1,1],i=!1;return t.separation=function(e){return arguments.length?(n=e,t):n},t.size=function(e){return arguments.length?(i=null==(r=e),t):i?null:r},t.nodeSize=function(e){return arguments.length?(i=null!=(r=e),t):i?r:null},Jr(t,e)},nu.layout.treemap=function(){function t(t,e){for(var n,r,i=-1,a=t.length;++ie?0:e),n.area=isNaN(r)||0>=r?0:r}function e(n){var a=n.children;if(a&&a.length){var u,o,s,c=h(n),l=[],f=a.slice(),p=1/0,g="slice"===d?c.dx:"dice"===d?c.dy:"slice-dice"===d?1&n.depth?c.dy:c.dx:Math.min(c.dx,c.dy);for(t(f,c.dx*c.dy/n.value),l.area=0;(s=f.length)>0;)l.push(u=f[s-1]),l.area+=u.area,"squarify"!==d||(o=r(l,g))<=p?(f.pop(),p=o):(l.area-=l.pop().area,i(l,g,c,!1),g=Math.min(c.dx,c.dy),l.length=l.area=0,p=1/0);l.length&&(i(l,g,c,!0),l.length=l.area=0),a.forEach(e)}}function n(e){var r=e.children;if(r&&r.length){var a,u=h(e),o=r.slice(),s=[];for(t(o,u.dx*u.dy/e.value),s.area=0;a=o.pop();)s.push(a),s.area+=a.area,null!=a.z&&(i(s,a.z?u.dx:u.dy,u,!o.length),s.length=s.area=0);r.forEach(n)}}function r(t,e){for(var n,r=t.area,i=0,a=1/0,u=-1,o=t.length;++un&&(a=n),n>i&&(i=n));return r*=r,e*=e,r?Math.max(e*i*p/r,r/(e*a*p)):1/0}function i(t,e,n,r){var i,a=-1,u=t.length,o=n.x,c=n.y,l=e?s(t.area/e):0;if(e==n.dx){for((r||l>n.dy)&&(l=n.dy);++an.dx)&&(l=n.dx);++an&&(e=1),1>n&&(t=0),function(){var n,r,i;do n=2*Math.random()-1,r=2*Math.random()-1,i=n*n+r*r;while(!i||i>1);return t+e*n*Math.sqrt(-2*Math.log(i)/i)}},logNormal:function(){var t=nu.random.normal.apply(nu,arguments);return function(){return Math.exp(t())}},bates:function(t){var e=nu.random.irwinHall(t);return function(){return e()/t}},irwinHall:function(t){return function(){for(var e=0,n=0;t>n;n++)e+=Math.random();return e}}},nu.scale={};var _s={floor:_,ceil:_};nu.scale.linear=function(){return qi([0,1],[0,1],_r,!1)};var bs={s:1,g:1,p:1,r:1,e:1};nu.scale.log=function(){return Qi(nu.scale.linear().domain([0,1]),10,!0,[1,10])};var xs=nu.format(".0e"),ws={floor:function(t){return-Math.ceil(-t)},ceil:function(t){return-Math.floor(-t)}};nu.scale.pow=function(){return Ji(nu.scale.linear(),1,[0,1])},nu.scale.sqrt=function(){return nu.scale.pow().exponent(.5)},nu.scale.ordinal=function(){return ea([],{t:"range",a:[[]]})},nu.scale.category10=function(){return nu.scale.ordinal().range(As)},nu.scale.category20=function(){return nu.scale.ordinal().range(ks)},nu.scale.category20b=function(){return nu.scale.ordinal().range(Es)},nu.scale.category20c=function(){return nu.scale.ordinal().range(Ds)};var As=[2062260,16744206,2924588,14034728,9725885,9197131,14907330,8355711,12369186,1556175].map(bt),ks=[2062260,11454440,16744206,16759672,2924588,10018698,14034728,16750742,9725885,12955861,9197131,12885140,14907330,16234194,8355711,13092807,12369186,14408589,1556175,10410725].map(bt),Es=[3750777,5395619,7040719,10264286,6519097,9216594,11915115,13556636,9202993,12426809,15186514,15190932,8666169,11356490,14049643,15177372,8077683,10834324,13528509,14589654].map(bt),Ds=[3244733,7057110,10406625,13032431,15095053,16616764,16625259,16634018,3253076,7652470,10607003,13101504,7695281,10394312,12369372,14342891,6513507,9868950,12434877,14277081].map(bt);nu.scale.quantile=function(){return na([],[])},nu.scale.quantize=function(){return ra(0,1,[0,1])},nu.scale.threshold=function(){return ia([.5],[0,1])},nu.scale.identity=function(){return aa([0,1])},nu.svg={},nu.svg.arc=function(){function t(){var t=Math.max(0,+n.apply(this,arguments)),c=Math.max(0,+r.apply(this,arguments)),l=u.apply(this,arguments)-Nu,h=o.apply(this,arguments)-Nu,f=Math.abs(h-l),d=l>h?0:1;if(t>c&&(p=c,c=t,t=p),f>=Ou)return e(c,d)+(t?e(t,1-d):"")+"Z";var p,g,y,m,v,_,b,x,w,A,k,E,D=0,M=0,C=[];if((m=(+s.apply(this,arguments)||0)/2)&&(y=a===Ms?Math.sqrt(t*t+c*c):+a.apply(this,arguments),d||(M*=-1),c&&(M=nt(y/c*Math.sin(m))),t&&(D=nt(y/t*Math.sin(m)))),c){v=c*Math.cos(l+M),_=c*Math.sin(l+M),b=c*Math.cos(h-M),x=c*Math.sin(h-M);var S=Math.abs(h-l-2*M)<=Bu?0:1;if(M&&fa(v,_,b,x)===d^S){var T=(l+h)/2;v=c*Math.cos(T),_=c*Math.sin(T),b=x=null}}else v=_=0;if(t){w=t*Math.cos(h-D),A=t*Math.sin(h-D),k=t*Math.cos(l+D),E=t*Math.sin(l+D);var F=Math.abs(l-h+2*D)<=Bu?0:1;if(D&&fa(w,A,k,E)===1-d^F){var B=(l+h)/2;w=t*Math.cos(B),A=t*Math.sin(B),k=E=null}}else w=A=0;if((p=Math.min(Math.abs(c-t)/2,+i.apply(this,arguments)))>.001){g=c>t^d?0:1;var L=null==k?[w,A]:null==b?[v,_]:On([v,_],[k,E],[b,x],[w,A]),O=v-L[0],N=_-L[1],I=b-L[0],P=x-L[1],R=1/Math.sin(Math.acos((O*I+N*P)/(Math.sqrt(O*O+N*N)*Math.sqrt(I*I+P*P)))/2),j=Math.sqrt(L[0]*L[0]+L[1]*L[1]);if(null!=b){var Y=Math.min(p,(c-j)/(R+1)),U=da(null==k?[w,A]:[k,E],[v,_],c,Y,d),$=da([b,x],[w,A],c,Y,d);p===Y?C.push("M",U[0],"A",Y,",",Y," 0 0,",g," ",U[1],"A",c,",",c," 0 ",1-d^fa(U[1][0],U[1][1],$[1][0],$[1][1]),",",d," ",$[1],"A",Y,",",Y," 0 0,",g," ",$[0]):C.push("M",U[0],"A",Y,",",Y," 0 1,",g," ",$[0])}else C.push("M",v,",",_);if(null!=k){var z=Math.min(p,(t-j)/(R-1)),q=da([v,_],[k,E],t,-z,d),W=da([w,A],null==b?[v,_]:[b,x],t,-z,d);p===z?C.push("L",W[0],"A",z,",",z," 0 0,",g," ",W[1],"A",t,",",t," 0 ",d^fa(W[1][0],W[1][1],q[1][0],q[1][1]),",",1-d," ",q[1],"A",z,",",z," 0 0,",g," ",q[0]):C.push("L",W[0],"A",z,",",z," 0 0,",g," ",q[0])}else C.push("L",w,",",A)}else C.push("M",v,",",_),null!=b&&C.push("A",c,",",c," 0 ",S,",",d," ",b,",",x),C.push("L",w,",",A),null!=k&&C.push("A",t,",",t," 0 ",F,",",1-d," ",k,",",E);return C.push("Z"),C.join("")}function e(t,e){return"M0,"+t+"A"+t+","+t+" 0 1,"+e+" 0,"+-t+"A"+t+","+t+" 0 1,"+e+" 0,"+t}var n=oa,r=sa,i=ua,a=Ms,u=ca,o=la,s=ha;return t.innerRadius=function(e){return arguments.length?(n=Mt(e),t):n},t.outerRadius=function(e){return arguments.length?(r=Mt(e),t):r},t.cornerRadius=function(e){return arguments.length?(i=Mt(e),t):i},t.padRadius=function(e){return arguments.length?(a=e==Ms?Ms:Mt(e),t):a},t.startAngle=function(e){return arguments.length?(u=Mt(e),t):u},t.endAngle=function(e){return arguments.length?(o=Mt(e),t):o},t.padAngle=function(e){return arguments.length?(s=Mt(e),t):s},t.centroid=function(){var t=(+n.apply(this,arguments)+ +r.apply(this,arguments))/2,e=(+u.apply(this,arguments)+ +o.apply(this,arguments))/2-Nu;return[Math.cos(e)*t,Math.sin(e)*t]},t};var Ms="auto";nu.svg.line=function(){return pa(_)};var Cs=nu.map({linear:ga,"linear-closed":ya,step:ma,"step-before":va,"step-after":_a,basis:Ea,"basis-open":Da,"basis-closed":Ma,bundle:Ca,cardinal:wa,"cardinal-open":ba,"cardinal-closed":xa,monotone:Oa});Cs.forEach(function(t,e){e.key=t,e.closed=/-closed$/.test(t)});var Ss=[0,2/3,1/3,0],Ts=[0,1/3,2/3,0],Fs=[0,1/6,2/3,1/6];nu.svg.line.radial=function(){var t=pa(Na);return t.radius=t.x,delete t.x,t.angle=t.y,delete t.y,t},va.reverse=_a,_a.reverse=va,nu.svg.area=function(){return Ia(_)},nu.svg.area.radial=function(){var t=Ia(Na);return t.radius=t.x,delete t.x,t.innerRadius=t.x0,delete t.x0,t.outerRadius=t.x1,delete t.x1,t.angle=t.y,delete t.y,t.startAngle=t.y0,delete t.y0,t.endAngle=t.y1,delete t.y1,t},nu.svg.chord=function(){function t(t,o){var s=e(this,a,t,o),c=e(this,u,t,o);return"M"+s.p0+r(s.r,s.p1,s.a1-s.a0)+(n(s,c)?i(s.r,s.p1,s.r,s.p0):i(s.r,s.p1,c.r,c.p0)+r(c.r,c.p1,c.a1-c.a0)+i(c.r,c.p1,s.r,s.p0))+"Z"}function e(t,e,n,r){var i=e.call(t,n,r),a=o.call(t,i,r),u=s.call(t,i,r)-Nu,l=c.call(t,i,r)-Nu;return{r:a,a0:u,a1:l,p0:[a*Math.cos(u),a*Math.sin(u)],p1:[a*Math.cos(l),a*Math.sin(l)]}}function n(t,e){return t.a0==e.a0&&t.a1==e.a1}function r(t,e,n){return"A"+t+","+t+" 0 "+ +(n>Bu)+",1 "+e}function i(t,e,n,r){return"Q 0,0 "+r}var a=_n,u=bn,o=Pa,s=ca,c=la;return t.radius=function(e){return arguments.length?(o=Mt(e),t):o},t.source=function(e){return arguments.length?(a=Mt(e),t):a},t.target=function(e){return arguments.length?(u=Mt(e),t):u},t.startAngle=function(e){return arguments.length?(s=Mt(e),t):s},t.endAngle=function(e){return arguments.length?(c=Mt(e),t):c},t},nu.svg.diagonal=function(){function t(t,i){var a=e.call(this,t,i),u=n.call(this,t,i),o=(a.y+u.y)/2,s=[a,{x:a.x,y:o},{x:u.x,y:o},u];return s=s.map(r),"M"+s[0]+"C"+s[1]+" "+s[2]+" "+s[3]}var e=_n,n=bn,r=Ra;return t.source=function(n){return arguments.length?(e=Mt(n),t):e},t.target=function(e){return arguments.length?(n=Mt(e),t):n},t.projection=function(e){return arguments.length?(r=e,t):r},t},nu.svg.diagonal.radial=function(){var t=nu.svg.diagonal(),e=Ra,n=t.projection;return t.projection=function(t){return arguments.length?n(ja(e=t)):e},t},nu.svg.symbol=function(){function t(t,r){return(Bs.get(e.call(this,t,r))||$a)(n.call(this,t,r))}var e=Ua,n=Ya;return t.type=function(n){return arguments.length?(e=Mt(n),t):e},t.size=function(e){return arguments.length?(n=Mt(e),t):n},t};var Bs=nu.map({circle:$a,cross:function(t){var e=Math.sqrt(t/5)/2;return"M"+-3*e+","+-e+"H"+-e+"V"+-3*e+"H"+e+"V"+-e+"H"+3*e+"V"+e+"H"+e+"V"+3*e+"H"+-e+"V"+e+"H"+-3*e+"Z"},diamond:function(t){var e=Math.sqrt(t/(2*Os)),n=e*Os;return"M0,"+-e+"L"+n+",0 0,"+e+" "+-n+",0Z"},square:function(t){var e=Math.sqrt(t)/2;return"M"+-e+","+-e+"L"+e+","+-e+" "+e+","+e+" "+-e+","+e+"Z"},"triangle-down":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+n+"L"+e+","+-n+" "+-e+","+-n+"Z"},"triangle-up":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+-n+"L"+e+","+n+" "+-e+","+n+"Z"}});nu.svg.symbolTypes=Bs.keys();var Ls=Math.sqrt(3),Os=Math.tan(30*Iu);Au.transition=function(t){for(var e,n,r=Ns||++js,i=Ha(t),a=[],u=Is||{time:Date.now(),ease:Dr,delay:0,duration:250},o=-1,s=this.length;++oa;a++){i.push(e=[]);for(var n=this[a],o=0,s=n.length;s>o;o++)(r=n[o])&&t.call(r,r.__data__,o,a)&&e.push(r)}return qa(i,this.namespace,this.id)},Rs.tween=function(t,e){var n=this.id,r=this.namespace;return arguments.length<2?this.node()[r][n].tween.get(t):q(this,null==e?function(e){e[r][n].tween.remove(t)}:function(i){i[r][n].tween.set(t,e)})},Rs.attr=function(t,e){function n(){this.removeAttribute(o)}function r(){this.removeAttributeNS(o.space,o.local)}function i(t){return null==t?n:(t+="",function(){var e,n=this.getAttribute(o);return n!==t&&(e=u(n,t),function(t){this.setAttribute(o,e(t))})})}function a(t){return null==t?r:(t+="",function(){var e,n=this.getAttributeNS(o.space,o.local);return n!==t&&(e=u(n,t),function(t){this.setAttributeNS(o.space,o.local,e(t))})})}if(arguments.length<2){for(e in t)this.attr(e,t[e]);return this}var u="transform"==t?$r:_r,o=nu.ns.qualify(t);return Wa(this,"attr."+t,e,o.local?a:i)},Rs.attrTween=function(t,e){function n(t,n){var r=e.call(this,t,n,this.getAttribute(i));return r&&function(t){this.setAttribute(i,r(t))}}function r(t,n){var r=e.call(this,t,n,this.getAttributeNS(i.space,i.local));return r&&function(t){this.setAttributeNS(i.space,i.local,r(t))}}var i=nu.ns.qualify(t);return this.tween("attr."+t,i.local?r:n)},Rs.style=function(t,e,r){function i(){this.style.removeProperty(t)}function a(e){return null==e?i:(e+="",function(){var i,a=n(this).getComputedStyle(this,null).getPropertyValue(t);return a!==e&&(i=_r(a,e),function(e){this.style.setProperty(t,i(e),r)})})}var u=arguments.length;if(3>u){if("string"!=typeof t){2>u&&(e="");for(r in t)this.style(r,t[r],e);return this}r=""}return Wa(this,"style."+t,e,a)},Rs.styleTween=function(t,e,r){function i(i,a){var u=e.call(this,i,a,n(this).getComputedStyle(this,null).getPropertyValue(t));return u&&function(e){this.style.setProperty(t,u(e),r)}}return arguments.length<3&&(r=""),this.tween("style."+t,i)},Rs.text=function(t){return Wa(this,"text",t,Ga)},Rs.remove=function(){var t=this.namespace;return this.each("end.transition",function(){var e;this[t].count<2&&(e=this.parentNode)&&e.removeChild(this)})},Rs.ease=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].ease:("function"!=typeof t&&(t=nu.ease.apply(nu,arguments)),q(this,function(r){r[n][e].ease=t}))},Rs.delay=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].delay:q(this,"function"==typeof t?function(r,i,a){r[n][e].delay=+t.call(r,r.__data__,i,a)}:(t=+t,function(r){r[n][e].delay=t}))},Rs.duration=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].duration:q(this,"function"==typeof t?function(r,i,a){r[n][e].duration=Math.max(1,t.call(r,r.__data__,i,a))}:(t=Math.max(1,t),function(r){r[n][e].duration=t}))},Rs.each=function(t,e){var n=this.id,r=this.namespace;if(arguments.length<2){var i=Is,a=Ns;try{Ns=n,q(this,function(e,i,a){Is=e[r][n],t.call(e,e.__data__,i,a)})}finally{Is=i,Ns=a}}else q(this,function(i){var a=i[r][n];(a.event||(a.event=nu.dispatch("start","end","interrupt"))).on(t,e)});return this},Rs.transition=function(){for(var t,e,n,r,i=this.id,a=++js,u=this.namespace,o=[],s=0,c=this.length;c>s;s++){o.push(t=[]);for(var e=this[s],l=0,h=e.length;h>l;l++)(n=e[l])&&(r=n[u][i],Va(n,l,u,a,{time:r.time,ease:r.ease,delay:r.delay+r.duration,duration:r.duration})),t.push(n)}return qa(o,u,a)},nu.svg.axis=function(){function t(t){t.each(function(){var t,c=nu.select(this),l=this.__chart__||n,h=this.__chart__=n.copy(),f=null==s?h.ticks?h.ticks.apply(h,o):h.domain():s,d=null==e?h.tickFormat?h.tickFormat.apply(h,o):_:e,p=c.selectAll(".tick").data(f,h),g=p.enter().insert("g",".domain").attr("class","tick").style("opacity",Tu),y=nu.transition(p.exit()).style("opacity",Tu).remove(),m=nu.transition(p.order()).style("opacity",1),v=Math.max(i,0)+u,b=ji(h),x=c.selectAll(".domain").data([0]),w=(x.enter().append("path").attr("class","domain"),nu.transition(x));g.append("line"),g.append("text");var A,k,E,D,M=g.select("line"),C=m.select("line"),S=p.select("text").text(d),T=g.select("text"),F=m.select("text"),B="top"===r||"left"===r?-1:1;if("bottom"===r||"top"===r?(t=Xa,A="x",E="y",k="x2",D="y2",S.attr("dy",0>B?"0em":".71em").style("text-anchor","middle"),w.attr("d","M"+b[0]+","+B*a+"V0H"+b[1]+"V"+B*a)):(t=Za,A="y",E="x",k="y2",D="x2",S.attr("dy",".32em").style("text-anchor",0>B?"end":"start"),w.attr("d","M"+B*a+","+b[0]+"H0V"+b[1]+"H"+B*a)),M.attr(D,B*i),T.attr(E,B*v),C.attr(k,0).attr(D,B*i),F.attr(A,0).attr(E,B*v),h.rangeBand){var L=h,O=L.rangeBand()/2;l=h=function(t){return L(t)+O}}else l.rangeBand?l=h:y.call(t,h,l);g.call(t,l,h),m.call(t,h,h)})}var e,n=nu.scale.linear(),r=Ys,i=6,a=6,u=3,o=[10],s=null;return t.scale=function(e){return arguments.length?(n=e,t):n},t.orient=function(e){return arguments.length?(r=e in Us?e+"":Ys,t):r},t.ticks=function(){return arguments.length?(o=arguments,t):o},t.tickValues=function(e){return arguments.length?(s=e,t):s},t.tickFormat=function(n){return arguments.length?(e=n,t):e},t.tickSize=function(e){var n=arguments.length;return n?(i=+e,a=+arguments[n-1],t):i},t.innerTickSize=function(e){return arguments.length?(i=+e,t):i},t.outerTickSize=function(e){return arguments.length?(a=+e,t):a},t.tickPadding=function(e){return arguments.length?(u=+e,t):u},t.tickSubdivide=function(){return arguments.length&&t},t};var Ys="bottom",Us={top:1,right:1,bottom:1,left:1};nu.svg.brush=function(){function t(n){n.each(function(){var n=nu.select(this).style("pointer-events","all").style("-webkit-tap-highlight-color","rgba(0,0,0,0)").on("mousedown.brush",a).on("touchstart.brush",a),u=n.selectAll(".background").data([0]);u.enter().append("rect").attr("class","background").style("visibility","hidden").style("cursor","crosshair"),n.selectAll(".extent").data([0]).enter().append("rect").attr("class","extent").style("cursor","move");var o=n.selectAll(".resize").data(g,_);o.exit().remove(),o.enter().append("g").attr("class",function(t){return"resize "+t}).style("cursor",function(t){return $s[t]}).append("rect").attr("x",function(t){return/[ew]$/.test(t)?-3:null}).attr("y",function(t){return/^[ns]/.test(t)?-3:null}).attr("width",6).attr("height",6).style("visibility","hidden"),o.style("display",t.empty()?"none":null);var s,h=nu.transition(n),f=nu.transition(u);c&&(s=ji(c),f.attr("x",s[0]).attr("width",s[1]-s[0]),r(h)),l&&(s=ji(l),f.attr("y",s[0]).attr("height",s[1]-s[0]),i(h)),e(h)})}function e(t){t.selectAll(".resize").attr("transform",function(t){return"translate("+h[+/e$/.test(t)]+","+f[+/^s/.test(t)]+")"})}function r(t){t.select(".extent").attr("x",h[0]),t.selectAll(".extent,.n>rect,.s>rect").attr("width",h[1]-h[0])}function i(t){t.select(".extent").attr("y",f[0]),t.selectAll(".extent,.e>rect,.w>rect").attr("height",f[1]-f[0])}function a(){function a(){32==nu.event.keyCode&&(S||(_=null,F[0]-=h[1],F[1]-=f[1],S=2),E())}function g(){32==nu.event.keyCode&&2==S&&(F[0]+=h[1],F[1]+=f[1],S=0,E())}function y(){var t=nu.mouse(x),n=!1;b&&(t[0]+=b[0],t[1]+=b[1]),S||(nu.event.altKey?(_||(_=[(h[0]+h[1])/2,(f[0]+f[1])/2]),F[0]=h[+(t[0]<_[0])],F[1]=f[+(t[1]<_[1])]):_=null),M&&m(t,c,0)&&(r(k),n=!0),C&&m(t,l,1)&&(i(k),n=!0),n&&(e(k),A({type:"brush",mode:S?"move":"resize"}))}function m(t,e,n){var r,i,a=ji(e),s=a[0],c=a[1],l=F[n],g=n?f:h,y=g[1]-g[0];return S&&(s-=l,c-=y+l),r=(n?p:d)?Math.max(s,Math.min(c,t[n])):t[n],S?i=(r+=l)+y:(_&&(l=Math.max(s,Math.min(c,2*_[n]-r))),r>l?(i=r,r=l):i=l),g[0]!=r||g[1]!=i?(n?o=null:u=null,g[0]=r,g[1]=i,!0):void 0}function v(){y(),k.style("pointer-events","all").selectAll(".resize").style("display",t.empty()?"none":null),nu.select("body").style("cursor",null),B.on("mousemove.brush",null).on("mouseup.brush",null).on("touchmove.brush",null).on("touchend.brush",null).on("keydown.brush",null).on("keyup.brush",null),T(),A({type:"brushend"})}var _,b,x=this,w=nu.select(nu.event.target),A=s.of(x,arguments),k=nu.select(x),D=w.datum(),M=!/^(n|s)$/.test(D)&&c,C=!/^(e|w)$/.test(D)&&l,S=w.classed("extent"),T=Z(x),F=nu.mouse(x),B=nu.select(n(x)).on("keydown.brush",a).on("keyup.brush",g);if(nu.event.changedTouches?B.on("touchmove.brush",y).on("touchend.brush",v):B.on("mousemove.brush",y).on("mouseup.brush",v),k.interrupt().selectAll("*").interrupt(),S)F[0]=h[0]-F[0],F[1]=f[0]-F[1];else if(D){var L=+/w$/.test(D),O=+/^n/.test(D);b=[h[1-L]-F[0],f[1-O]-F[1]],F[0]=h[L],F[1]=f[O]}else nu.event.altKey&&(_=F.slice());k.style("pointer-events","none").selectAll(".resize").style("display",null),nu.select("body").style("cursor",w.style("cursor")),A({type:"brushstart"}),y()}var u,o,s=M(t,"brushstart","brush","brushend"),c=null,l=null,h=[0,0],f=[0,0],d=!0,p=!0,g=zs[0];return t.event=function(t){t.each(function(){var t=s.of(this,arguments),e={x:h,y:f,i:u,j:o},n=this.__chart__||e;this.__chart__=e,Ns?nu.select(this).transition().each("start.brush",function(){u=n.i,o=n.j,h=n.x,f=n.y,t({type:"brushstart"})}).tween("brush:brush",function(){var n=br(h,e.x),r=br(f,e.y);return u=o=null,function(i){h=e.x=n(i),f=e.y=r(i),t({type:"brush",mode:"resize"})}}).each("end.brush",function(){u=e.i,o=e.j,t({type:"brush",mode:"resize"}),t({type:"brushend"})}):(t({type:"brushstart"}),t({type:"brush",mode:"resize"}),t({type:"brushend"}))})},t.x=function(e){return arguments.length?(c=e,g=zs[!c<<1|!l],t):c},t.y=function(e){return arguments.length?(l=e,g=zs[!c<<1|!l],t):l},t.clamp=function(e){return arguments.length?(c&&l?(d=!!e[0],p=!!e[1]):c?d=!!e:l&&(p=!!e),t):c&&l?[d,p]:c?d:l?p:null},t.extent=function(e){var n,r,i,a,s;return arguments.length?(c&&(n=e[0],r=e[1],l&&(n=n[0],r=r[0]),u=[n,r],c.invert&&(n=c(n),r=c(r)),n>r&&(s=n,n=r,r=s),(n!=h[0]||r!=h[1])&&(h=[n,r])),l&&(i=e[0],a=e[1],c&&(i=i[1],a=a[1]),o=[i,a],l.invert&&(i=l(i),a=l(a)),i>a&&(s=i,i=a,a=s),(i!=f[0]||a!=f[1])&&(f=[i,a])),t):(c&&(u?(n=u[0],r=u[1]):(n=h[0],r=h[1],c.invert&&(n=c.invert(n),r=c.invert(r)),n>r&&(s=n,n=r,r=s))),l&&(o?(i=o[0],a=o[1]):(i=f[0],a=f[1],l.invert&&(i=l.invert(i),a=l.invert(a)),i>a&&(s=i,i=a,a=s))),c&&l?[[n,i],[r,a]]:c?[n,r]:l&&[i,a])},t.clear=function(){return t.empty()||(h=[0,0],f=[0,0],u=o=null),t},t.empty=function(){return!!c&&h[0]==h[1]||!!l&&f[0]==f[1]},nu.rebind(t,s,"on")};var $s={n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},zs=[["n","e","s","w","nw","ne","se","sw"],["e","w"],["n","s"],[]],qs=so.format=go.timeFormat,Ws=qs.utc,Gs=Ws("%Y-%m-%dT%H:%M:%S.%LZ");qs.iso=Date.prototype.toISOString&&+new Date("2000-01-01T00:00:00.000Z")?Ka:Gs,Ka.parse=function(t){var e=new Date(t);return isNaN(e)?null:e},Ka.toString=Gs.toString,so.second=Yt(function(t){return new co(1e3*Math.floor(t/1e3))},function(t,e){t.setTime(t.getTime()+1e3*Math.floor(e))},function(t){return t.getSeconds()}),so.seconds=so.second.range,so.seconds.utc=so.second.utc.range,so.minute=Yt(function(t){return new co(6e4*Math.floor(t/6e4))},function(t,e){t.setTime(t.getTime()+6e4*Math.floor(e))},function(t){return t.getMinutes()}),so.minutes=so.minute.range,so.minutes.utc=so.minute.utc.range,so.hour=Yt(function(t){var e=t.getTimezoneOffset()/60;return new co(36e5*(Math.floor(t/36e5-e)+e))},function(t,e){t.setTime(t.getTime()+36e5*Math.floor(e))},function(t){return t.getHours()}),so.hours=so.hour.range,so.hours.utc=so.hour.utc.range,so.month=Yt(function(t){return t=so.day(t),t.setDate(1),t},function(t,e){t.setMonth(t.getMonth()+e)},function(t){return t.getMonth()}),so.months=so.month.range,so.months.utc=so.month.utc.range;var Hs=[1e3,5e3,15e3,3e4,6e4,3e5,9e5,18e5,36e5,108e5,216e5,432e5,864e5,1728e5,6048e5,2592e6,7776e6,31536e6],Vs=[[so.second,1],[so.second,5],[so.second,15],[so.second,30],[so.minute,1],[so.minute,5],[so.minute,15],[so.minute,30],[so.hour,1],[so.hour,3],[so.hour,6],[so.hour,12],[so.day,1],[so.day,2],[so.week,1],[so.month,1],[so.month,3],[so.year,1]],Xs=qs.multi([[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["%I:%M",function(t){return t.getMinutes()}],["%I %p",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}],["%Y",Se]]),Zs={range:function(t,e,n){return nu.range(Math.ceil(t/n)*n,+e,n).map(Ja)},floor:_,ceil:_};Vs.year=so.year,so.scale=function(){return Qa(nu.scale.linear(),Vs,Xs)};var Ks=Vs.map(function(t){return[t[0].utc,t[1]]}),Qs=Ws.multi([[".%L",function(t){return t.getUTCMilliseconds()}],[":%S",function(t){return t.getUTCSeconds()}],["%I:%M",function(t){return t.getUTCMinutes()}],["%I %p",function(t){return t.getUTCHours()}],["%a %d",function(t){return t.getUTCDay()&&1!=t.getUTCDate()}],["%b %d",function(t){return 1!=t.getUTCDate()}],["%B",function(t){return t.getUTCMonth()}],["%Y",Se]]);Ks.year=so.year.utc,so.scale.utc=function(){return Qa(nu.scale.linear(),Ks,Qs)},nu.text=Ct(function(t){return t.responseText}),nu.json=function(t,e){return St(t,"application/json",tu,e)},nu.html=function(t,e){return St(t,"text/html",eu,e)},nu.xml=Ct(function(t){return t.responseXML}),"function"==typeof define&&define.amd?define(nu):"object"==typeof e&&e.exports&&(e.exports=nu),this.d3=nu}()},{}],5:[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":12,"./lib/graphlib":13,"./lib/intersect":14,"./lib/render":29,"./lib/util":31,"./lib/version":32}],6:[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"),u=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(u,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"),u=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(u,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"),u=i.append("path").attr("d","M 0 5 L 10 5").style("stroke-width",1).style("stroke-dasharray","1,0");a.applyStyle(u,n[r+"Style"])}var a=t("./util");e.exports={"default":n,normal:n,vee:r,undirected:i}},{"./util":31}],7:[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":22,"./util":31}],8:[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(u.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"),u=t("./d3");e.exports=n},{"./d3":11,"./label/add-label":22,"./lodash":25,"./util":31}],9:[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 u(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=s.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,"arrowhead")}),i}function r(t,e){var n=t.edge(e),r=t.node(e.v),a=t.node(e.w),u=n.points.slice(1,n.points.length-1);return u.unshift(c(r,u[0])),u.push(c(a,u[u.length-1])),i(n,u)}function i(t,e){var n=h.svg.line().x(function(t){return t.x}).y(function(t){return t.y});return s.has(t,"lineInterpolate")&&n.interpolate(t.lineInterpolate),s.has(t,"lineTension")&&n.tension(Number(t.lineTension)),n(e)}function a(t){var e=t.getBBox(),n=t.getTransformToElement(t.ownerSVGElement).translate(e.width/2,e.height/2);return{x:n.e,y:n.f}}function u(t,e){var n=t.enter().append("g").attr("class","edgePath").style("opacity",0);n.append("path").attr("class","path").attr("d",function(t){var n=e.edge(t),r=e.node(t.v).elem,u=s.range(n.points.length).map(function(){return a(r)});return i(n,u)}),n.append("defs")}function o(t,e){var n=t.exit();l.applyTransition(n,e).style("opacity",0).remove(),l.applyTransition(n.select("path.path"),e).attr("d",function(t){var n=e.node(t.v);if(n){var r=s.range(this.pathSegList.length).map(function(){return n});return i({},r)}return h.select(this).attr("d")})}var s=t("./lodash"),c=t("./intersect/intersect-node"),l=t("./util"),h=t("./d3");e.exports=n},{"./d3":11,"./intersect/intersect-node":18,"./lodash":25,"./util":31}],10:[function(t,e){"use strict"; -function n(t,e,n){var o=e.nodes().filter(function(t){return!a.isSubgraph(e,t)}),s=t.selectAll("g.node").data(o,function(t){return t}).classed("update",!0);return s.selectAll("*").remove(),s.enter().append("g").attr("class","node").style("opacity",0),s.each(function(t){var o=e.node(t),s=u.select(this),c=s.append("g").attr("class","label"),l=i(c,o),h=n[o.shape],f=r.pick(l.node().getBBox(),"width","height");o.elem=this,o.id&&s.attr("id",o.id),o.labelId&&c.attr("id",o.labelId),a.applyClass(s,o["class"],(s.classed("update")?"update ":"")+"node"),r.has(o,"width")&&(f.width=o.width),r.has(o,"height")&&(f.height=o.height),f.width+=o.paddingLeft+o.paddingRight,f.height+=o.paddingTop+o.paddingBottom,c.attr("transform","translate("+(o.paddingLeft-o.paddingRight)/2+","+(o.paddingTop-o.paddingBottom)/2+")");var d=h(u.select(this),f,o);a.applyStyle(d,o.style);var p=d.node().getBBox();o.width=p.width,o.height=p.height}),a.applyTransition(s.exit(),e).style("opacity",0).remove(),s}var r=t("./lodash"),i=t("./label/add-label"),a=t("./util"),u=t("./d3");e.exports=n},{"./d3":11,"./label/add-label":22,"./lodash":25,"./util":31}],11:[function(t,e){e.exports=window.d3},{}],12:[function(t,e){var n;if(t)try{n=t("dagre")}catch(r){}n||(n=window.dagre),e.exports=n},{dagre:54}],13:[function(t,e){var n;if(t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:33}],14:[function(t,e){e.exports={node:t("./intersect-node"),circle:t("./intersect-circle"),ellipse:t("./intersect-ellipse"),polygon:t("./intersect-polygon"),rect:t("./intersect-rect")}},{"./intersect-circle":15,"./intersect-ellipse":16,"./intersect-node":18,"./intersect-polygon":19,"./intersect-rect":20}],15:[function(t,e){function n(t,e,n){return r(t,e,e,n)}var r=t("./intersect-ellipse");e.exports=n},{"./intersect-ellipse":16}],16:[function(t,e){function n(t,e,n,r){var i=t.x,a=t.y,u=i-r.x,o=a-r.y,s=Math.sqrt(e*e*o*o+n*n*u*u),c=Math.abs(e*n*u/s);r.xm?(m-y)/g:(m+y)/g,m=u*c-a*l,_=0>m?(m-y)/g:(m+y)/g,{x:v,y:_})}function r(t,e){return t*e>0}e.exports=n},{}],18:[function(t,e){function n(t,e){return t.intersect(e)}e.exports=n},{}],19:[function(t,e){function n(t,e,n){var i=t.x,a=t.y,u=[],o=Number.POSITIVE_INFINITY,s=Number.POSITIVE_INFINITY;e.forEach(function(t){o=Math.min(o,t.x),s=Math.min(s,t.y)});for(var c=i-t.width/2-o,l=a-t.height/2-s,h=0;h1&&u.sort(function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),u=e.x-n.x,o=e.y-n.y,s=Math.sqrt(u*u+o*o);return s>a?-1:a===s?0:1}),u[0]):(console.log("NO INTERSECTION FOUND, RETURN NODE CENTER",t),t)}var r=t("./intersect-line");e.exports=n},{"./intersect-line":17}],20:[function(t,e){function n(t,e){var n,r,i=t.x,a=t.y,u=e.x-i,o=e.y-a,s=t.width/2,c=t.height/2;return Math.abs(o)*s>Math.abs(u)*c?(0>o&&(c=-c),n=0===o?0:c*u/o,r=c):(0>u&&(s=-s),n=s,r=0===u?0:s*o/u),{x:i+n,y:a+r}}e.exports=n},{}],21:[function(t,e){function n(t,e){var n=t.append("foreignObject").attr("width","100000"),i=n.append("xhtml:div"),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 u,o;return i.each(function(){u=this.clientWidth,o=this.clientHeight}),n.attr("width",u).attr("height",o),n}var r=t("../util");e.exports=n},{"../util":31}],22:[function(t,e){function n(t,e,n){var u=e.label,o=t.append("g");"svg"===e.labelType?a(o,e):"string"!=typeof u||"html"===e.labelType?i(o,e):r(o,e);var s,c=o.node().getBBox();switch(n){case"top":s=-e.height/2;break;case"bottom":s=e.height/2-c.height;break;default:s=-c.height/2}return o.attr("transform","translate("+-c.width/2+","+s+")"),o}var r=t("./add-text-label"),i=t("./add-html-label"),a=t("./add-svg-label");e.exports=n},{"./add-html-label":21,"./add-svg-label":23,"./add-text-label":24}],23:[function(t,e){function n(t,e){var n=t;return n.node().appendChild(e.label),r.applyStyle(n,e.labelStyle),n}var r=t("../util");e.exports=n},{"../util":31}],24:[function(t,e){function n(t,e){for(var n=t.append("text"),a=r(e.label).split("\n"),u=0;ua)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+t+" Weight: "+a);c0&&(i=s.removeMin(),u=o[i],u.distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return o}var i=t("../lodash"),a=t("../data/priority-queue");e.exports=n;var u=i.constant(1)},{"../data/priority-queue":47,"../lodash":51}],38:[function(t,e){function n(t){return r.filter(i(t),function(e){return e.length>1||1===e.length&&t.hasEdge(e[0],e[0])})}var r=t("../lodash"),i=t("./tarjan");e.exports=n},{"../lodash":51,"./tarjan":45}],39:[function(t,e){function n(t,e,n){return r(t,e||a,n||function(e){return t.outEdges(e)})}function r(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],u=a[n],o=r.distance+i.distance;oi&&(s[n]=u,c.decrease(n,i))}}var u,o=new i,s={},c=new 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(u=c.removeMin(),r.has(s,u))o.setEdge(u,s[u]);else{if(l)throw new Error("Input graph is not connected: "+t);l=!0}t.nodeEdges(u).forEach(n)}return o}var r=t("../lodash"),i=t("../graph"),a=t("../data/priority-queue");e.exports=n},{"../data/priority-queue":47,"../graph":48,"../lodash":51}],45:[function(t,e){function n(t){function e(o){var s=a[o]={onStack:!0,lowlink:n,index:n++};if(i.push(o),t.successors(o).forEach(function(t){r.has(a,t)?a[t].onStack&&(s.lowlink=Math.min(s.lowlink,a[t].index)):(e(t),s.lowlink=Math.min(s.lowlink,a[t].lowlink))}),s.lowlink===s.index){var c,l=[];do c=i.pop(),a[c].onStack=!1,l.push(c);while(o!==c);u.push(l)}}var n=0,i=[],a={},u=[];return t.nodes().forEach(function(t){r.has(a,t)||e(t)}),u}var r=t("../lodash");e.exports=n},{"../lodash":51}],46:[function(t,e){function n(t){function e(o){if(i.has(a,o))throw new r;i.has(n,o)||(a[o]=!0,n[o]=!0,i.each(t.predecessors(o),e),delete a[o],u.push(o))}var n={},a={},u=[];if(i.each(t.sinks(),e),i.size(n)!==t.nodeCount())throw new r;return u}function r(){}var i=t("../lodash");e.exports=n,n.CycleException=r},{"../lodash":51}],47:[function(t,e){function n(){this._arr=[],this._keyIndices={}}var r=t("../lodash");e.exports=n,n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(t){return t.key})},n.prototype.has=function(t){return r.has(this._keyIndices,t)},n.prototype.priority=function(t){var e=this._keyIndices[t];return void 0!==e?this._arr[e].priority:void 0},n.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},n.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},n.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},n.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)},n.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,i=t;n>1,!(n[e].prioritya){var u=i;i=a,a=u}return i+h+a+h+(s.isUndefined(r)?c:r)}function u(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var u=i;i=a,a=u}var o={v:i,w:a};return r&&(o.name=r),o}function o(t,e){return a(t,e.v,e.w,e.name)}var s=t("./lodash");e.exports=n;var c="\x00",l="\x00",h="";n.prototype._nodeCount=0,n.prototype._edgeCount=0,n.prototype.isDirected=function(){return this._isDirected},n.prototype.isMultigraph=function(){return this._isMultigraph},n.prototype.isCompound=function(){return this._isCompound},n.prototype.setGraph=function(t){return this._label=t,this},n.prototype.graph=function(){return this._label},n.prototype.setDefaultNodeLabel=function(t){return s.isFunction(t)||(t=s.constant(t)),this._defaultNodeLabelFn=t,this},n.prototype.nodeCount=function(){return this._nodeCount},n.prototype.nodes=function(){return s.keys(this._nodes)},n.prototype.sources=function(){return s.filter(this.nodes(),function(t){return s.isEmpty(this._in[t])},this)},n.prototype.sinks=function(){return s.filter(this.nodes(),function(t){return s.isEmpty(this._out[t])},this)},n.prototype.setNodes=function(t,e){var n=arguments;return s.each(t,function(t){n.length>1?this.setNode(t,e):this.setNode(t)},this),this},n.prototype.setNode=function(t,e){return s.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]=l,this._children[t]={},this._children[l][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},n.prototype.node=function(t){return this._nodes[t]},n.prototype.hasNode=function(t){return s.has(this._nodes,t)},n.prototype.removeNode=function(t){var e=this;if(s.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],s.each(this.children(t),function(t){this.setParent(t)},this),delete this._children[t]),s.each(s.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],s.each(s.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},n.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(s.isUndefined(e))e=l;else{e+="";for(var n=e;!s.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},n.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},n.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!==l)return e}},n.prototype.children=function(t){if(s.isUndefined(t)&&(t=l),this._isCompound){var e=this._children[t];if(e)return s.keys(e)}else{if(t===l)return this.nodes();if(this.hasNode(t))return[]}},n.prototype.predecessors=function(t){var e=this._preds[t];return e?s.keys(e):void 0},n.prototype.successors=function(t){var e=this._sucs[t];return e?s.keys(e):void 0},n.prototype.neighbors=function(t){var e=this.predecessors(t);return e?s.union(e,this.successors(t)):void 0},n.prototype.filterNodes=function(t){function e(t){var a=r.parent(t);return void 0===a||n.hasNode(a)?(i[t]=a,a):a in i?i[a]:e(a)}var n=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});n.setGraph(this.graph()),s.each(this._nodes,function(e,r){t(r)&&n.setNode(r,e)},this),s.each(this._edgeObjs,function(t){n.hasNode(t.v)&&n.hasNode(t.w)&&n.setEdge(t,this.edge(t))},this);var r=this,i={};return this._isCompound&&s.each(n.nodes(),function(t){n.setParent(t,e(t))}),n},n.prototype.setDefaultEdgeLabel=function(t){return s.isFunction(t)||(t=s.constant(t)),this._defaultEdgeLabelFn=t,this},n.prototype.edgeCount=function(){return this._edgeCount},n.prototype.edges=function(){return s.values(this._edgeObjs)},n.prototype.setPath=function(t,e){var n=this,r=arguments;return s.reduce(t,function(t,i){return r.length>1?n.setEdge(t,i,e):n.setEdge(t,i),i}),this},n.prototype.setEdge=function(){var t,e,n,i,o=!1,c=arguments[0];"object"==typeof c&&null!==c&&"v"in c?(t=c.v,e=c.w,n=c.name,2===arguments.length&&(i=arguments[1],o=!0)):(t=c,e=arguments[1],n=arguments[3],arguments.length>2&&(i=arguments[2],o=!0)),t=""+t,e=""+e,s.isUndefined(n)||(n=""+n);var l=a(this._isDirected,t,e,n);if(s.has(this._edgeLabels,l))return o&&(this._edgeLabels[l]=i),this;if(!s.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[l]=o?i:this._defaultEdgeLabelFn(t,e,n);var h=u(this._isDirected,t,e,n);return t=h.v,e=h.w,Object.freeze(h),this._edgeObjs[l]=h,r(this._preds[e],t),r(this._sucs[t],e),this._in[e][l]=h,this._out[t][l]=h,this._edgeCount++,this},n.prototype.edge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return this._edgeLabels[r]},n.prototype.hasEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return s.has(this._edgeLabels,r)},n.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n),u=this._edgeObjs[r];return u&&(t=u.v,e=u.w,delete this._edgeLabels[r],delete this._edgeObjs[r],i(this._preds[e],t),i(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},n.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var r=s.values(n);return e?s.filter(r,function(t){return t.v===e}):r}},n.prototype.outEdges=function(t,e){var n=this._out[t];if(n){var r=s.values(n);return e?s.filter(r,function(t){return t.w===e}):r}},n.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);return n?n.concat(this.outEdges(t,e)):void 0}},{"./lodash":51}],49:[function(t,e){e.exports={Graph:t("./graph"),version:t("./version")}},{"./graph":48,"./version":52}],50:[function(t,e){function n(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:r(t),edges:i(t)};return u.isUndefined(t.graph())||(e.value=u.clone(t.graph())),e}function r(t){return u.map(t.nodes(),function(e){var n=t.node(e),r=t.parent(e),i={v:e};return u.isUndefined(n)||(i.value=n),u.isUndefined(r)||(i.parent=r),i})}function i(t){return u.map(t.edges(),function(e){var n=t.edge(e),r={v:e.v,w:e.w};return u.isUndefined(e.name)||(r.name=e.name),u.isUndefined(n)||(r.value=n),r})}function a(t){var e=new o(t.options).setGraph(t.value);return u.each(t.nodes,function(t){e.setNode(t.v,t.value),t.parent&&e.setParent(t.v,t.parent)}),u.each(t.edges,function(t){e.setEdge({v:t.v,w:t.w,name:t.name},t.value)}),e}var u=t("./lodash"),o=t("./graph");e.exports={write:n,read:a}},{"./graph":48,"./lodash":51}],51:[function(t,e){var n;if("function"==typeof t)try{n=t("lodash")}catch(r){}n||(n=window._),e.exports=n},{lodash:53}],52:[function(t,e){e.exports="1.0.7"},{}],53:[function(t,e,n){(function(t){(function(){function r(t,e){if(t!==e){var n=null===t,r=t===E,i=t===t,a=null===e,u=e===E,o=e===e;if(t>e&&!a||!i||n&&!u&&o||r&&o)return 1;if(e>t&&!n||!o||a&&!r&&i||u&&i)return-1}return 0}function i(t,e,n){for(var r=t.length,i=n?r:-1;n?i--:++i-1;);return n}function c(t,e){for(var n=t.length;n--&&e.indexOf(t.charAt(n))>-1;);return n}function l(t,e){return r(t.criteria,e.criteria)||t.index-e.index}function h(t,e,n){for(var i=-1,a=t.criteria,u=e.criteria,o=a.length,s=n.length;++i=s)return c;var l=n[i];return c*("asc"===l||l===!0?1:-1)}}return t.index-e.index}function f(t){return qt[t]}function d(t){return Wt[t]}function p(t,e,n){return e?t=Vt[t]:n&&(t=Xt[t]),"\\"+t}function g(t){return"\\"+Xt[t]}function y(t,e,n){for(var r=t.length,i=e+(n?0:-1);n?i--:++i=t&&t>=9&&13>=t||32==t||160==t||5760==t||6158==t||t>=8192&&(8202>=t||8232==t||8233==t||8239==t||8287==t||12288==t||65279==t)}function _(t,e){for(var n=-1,r=t.length,i=-1,a=[];++ne,i=n?t.length:0,a=Gn(0,i,this.__views__),u=a.start,o=a.end,s=o-u,c=r?o:u-1,l=this.__iteratees__,h=l.length,f=0,d=wu(s,this.__takeCount__);if(!n||Y>i||i==s&&d==s)return nn(r&&n?t.reverse():t,this.__actions__);var p=[];t:for(;s--&&d>f;){c+=e;for(var g=-1,y=t[c];++g=Y?gn(e):null,c=e.length;s&&(u=Kt,o=!1,e=s);t:for(;++in&&(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 De(t,e){var n=[];return Iu(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}function Ce(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 Se(t,e,n,r){r||(r=[]);for(var i=-1,a=t.length;++ir;)t=t[e[r++]];return r&&r==i?t:E}}function Ie(t,e,n,r,i,a){return t===e?!0:null==t||null==e||!Oi(t)&&!m(e)?t!==t&&e!==e:Ne(t,e,Ie,n,r,i,a)}function Ne(t,e,n,r,i,a,u){var o=So(t),s=So(e),c=G,l=G;o||(c=nu.call(t),c==W?c=J:c!=J&&(o=zi(t))),s||(l=nu.call(e),l==W?l=J:l!=J&&(s=zi(e)));var h=c==J,f=l==J,d=c==l;if(d&&!o&&!h)return jn(t,e,c);if(!i){var p=h&&tu.call(t,"__wrapped__"),g=f&&tu.call(e,"__wrapped__");if(p||g)return n(p?t.value():t,g?e.value():e,r,i,a,u)}if(!d)return!1;a||(a=[]),u||(u=[]);for(var y=a.length;y--;)if(a[y]==t)return u[y]==e;a.push(t),u.push(e); +function n(t,e,n){var o=e.nodes().filter(function(t){return!a.isSubgraph(e,t)}),s=t.selectAll("g.node").data(o,function(t){return t}).classed("update",!0);return s.selectAll("*").remove(),s.enter().append("g").attr("class","node").style("opacity",0),s.each(function(t){var o=e.node(t),s=u.select(this),c=s.append("g").attr("class","label"),l=i(c,o),h=n[o.shape],f=r.pick(l.node().getBBox(),"width","height");o.elem=this,o.id&&s.attr("id",o.id),o.labelId&&c.attr("id",o.labelId),a.applyClass(s,o["class"],(s.classed("update")?"update ":"")+"node"),r.has(o,"width")&&(f.width=o.width),r.has(o,"height")&&(f.height=o.height),f.width+=o.paddingLeft+o.paddingRight,f.height+=o.paddingTop+o.paddingBottom,c.attr("transform","translate("+(o.paddingLeft-o.paddingRight)/2+","+(o.paddingTop-o.paddingBottom)/2+")");var d=h(u.select(this),f,o);a.applyStyle(d,o.style);var p=d.node().getBBox();o.width=p.width,o.height=p.height}),a.applyTransition(s.exit(),e).style("opacity",0).remove(),s}var r=t("./lodash"),i=t("./label/add-label"),a=t("./util"),u=t("./d3");e.exports=n},{"./d3":11,"./label/add-label":22,"./lodash":25,"./util":31}],11:[function(t,e){e.exports=window.d3},{}],12:[function(t,e){var n;if(t)try{n=t("dagre")}catch(r){}n||(n=window.dagre),e.exports=n},{dagre:54}],13:[function(t,e){var n;if(t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:33}],14:[function(t,e){e.exports={node:t("./intersect-node"),circle:t("./intersect-circle"),ellipse:t("./intersect-ellipse"),polygon:t("./intersect-polygon"),rect:t("./intersect-rect")}},{"./intersect-circle":15,"./intersect-ellipse":16,"./intersect-node":18,"./intersect-polygon":19,"./intersect-rect":20}],15:[function(t,e){function n(t,e,n){return r(t,e,e,n)}var r=t("./intersect-ellipse");e.exports=n},{"./intersect-ellipse":16}],16:[function(t,e){function n(t,e,n,r){var i=t.x,a=t.y,u=i-r.x,o=a-r.y,s=Math.sqrt(e*e*o*o+n*n*u*u),c=Math.abs(e*n*u/s);r.xm?(m-y)/g:(m+y)/g,m=u*c-a*l,_=0>m?(m-y)/g:(m+y)/g,{x:v,y:_})}function r(t,e){return t*e>0}e.exports=n},{}],18:[function(t,e){function n(t,e){return t.intersect(e)}e.exports=n},{}],19:[function(t,e){function n(t,e,n){var i=t.x,a=t.y,u=[],o=Number.POSITIVE_INFINITY,s=Number.POSITIVE_INFINITY;e.forEach(function(t){o=Math.min(o,t.x),s=Math.min(s,t.y)});for(var c=i-t.width/2-o,l=a-t.height/2-s,h=0;h1&&u.sort(function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),u=e.x-n.x,o=e.y-n.y,s=Math.sqrt(u*u+o*o);return s>a?-1:a===s?0:1}),u[0]):(console.log("NO INTERSECTION FOUND, RETURN NODE CENTER",t),t)}var r=t("./intersect-line");e.exports=n},{"./intersect-line":17}],20:[function(t,e){function n(t,e){var n,r,i=t.x,a=t.y,u=e.x-i,o=e.y-a,s=t.width/2,c=t.height/2;return Math.abs(o)*s>Math.abs(u)*c?(0>o&&(c=-c),n=0===o?0:c*u/o,r=c):(0>u&&(s=-s),n=s,r=0===u?0:s*o/u),{x:i+n,y:a+r}}e.exports=n},{}],21:[function(t,e){function n(t,e){var n=t.append("foreignObject").attr("width","100000"),i=n.append("xhtml:div"),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 u,o;return i.each(function(){u=this.clientWidth,o=this.clientHeight}),n.attr("width",u).attr("height",o),n}var r=t("../util");e.exports=n},{"../util":31}],22:[function(t,e){function n(t,e,n){var u=e.label,o=t.append("g");"svg"===e.labelType?a(o,e):"string"!=typeof u||"html"===e.labelType?i(o,e):r(o,e);var s,c=o.node().getBBox();switch(n){case"top":s=-e.height/2;break;case"bottom":s=e.height/2-c.height;break;default:s=-c.height/2}return o.attr("transform","translate("+-c.width/2+","+s+")"),o}var r=t("./add-text-label"),i=t("./add-html-label"),a=t("./add-svg-label");e.exports=n},{"./add-html-label":21,"./add-svg-label":23,"./add-text-label":24}],23:[function(t,e){function n(t,e){var n=t;return n.node().appendChild(e.label),r.applyStyle(n,e.labelStyle),n}var r=t("../util");e.exports=n},{"../util":31}],24:[function(t,e){function n(t,e){for(var n=t.append("text"),a=r(e.label).split("\n"),u=0;ua)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+t+" Weight: "+a);c0&&(i=s.removeMin(),u=o[i],u.distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return o}var i=t("../lodash"),a=t("../data/priority-queue");e.exports=n;var u=i.constant(1)},{"../data/priority-queue":47,"../lodash":51}],38:[function(t,e){function n(t){return r.filter(i(t),function(e){return e.length>1||1===e.length&&t.hasEdge(e[0],e[0])})}var r=t("../lodash"),i=t("./tarjan");e.exports=n},{"../lodash":51,"./tarjan":45}],39:[function(t,e){function n(t,e,n){return r(t,e||a,n||function(e){return t.outEdges(e)})}function r(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],u=a[n],o=r.distance+i.distance;oi&&(s[n]=u,c.decrease(n,i))}}var u,o=new i,s={},c=new 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(u=c.removeMin(),r.has(s,u))o.setEdge(u,s[u]);else{if(l)throw new Error("Input graph is not connected: "+t);l=!0}t.nodeEdges(u).forEach(n)}return o}var r=t("../lodash"),i=t("../graph"),a=t("../data/priority-queue");e.exports=n},{"../data/priority-queue":47,"../graph":48,"../lodash":51}],45:[function(t,e){function n(t){function e(o){var s=a[o]={onStack:!0,lowlink:n,index:n++};if(i.push(o),t.successors(o).forEach(function(t){r.has(a,t)?a[t].onStack&&(s.lowlink=Math.min(s.lowlink,a[t].index)):(e(t),s.lowlink=Math.min(s.lowlink,a[t].lowlink))}),s.lowlink===s.index){var c,l=[];do c=i.pop(),a[c].onStack=!1,l.push(c);while(o!==c);u.push(l)}}var n=0,i=[],a={},u=[];return t.nodes().forEach(function(t){r.has(a,t)||e(t)}),u}var r=t("../lodash");e.exports=n},{"../lodash":51}],46:[function(t,e){function n(t){function e(o){if(i.has(a,o))throw new r;i.has(n,o)||(a[o]=!0,n[o]=!0,i.each(t.predecessors(o),e),delete a[o],u.push(o))}var n={},a={},u=[];if(i.each(t.sinks(),e),i.size(n)!==t.nodeCount())throw new r;return u}function r(){}var i=t("../lodash");e.exports=n,n.CycleException=r},{"../lodash":51}],47:[function(t,e){function n(){this._arr=[],this._keyIndices={}}var r=t("../lodash");e.exports=n,n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(t){return t.key})},n.prototype.has=function(t){return r.has(this._keyIndices,t)},n.prototype.priority=function(t){var e=this._keyIndices[t];return void 0!==e?this._arr[e].priority:void 0},n.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},n.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},n.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},n.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)},n.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,i=t;n>1,!(n[e].prioritya){var u=i;i=a,a=u}return i+h+a+h+(s.isUndefined(r)?c:r)}function u(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var u=i;i=a,a=u}var o={v:i,w:a};return r&&(o.name=r),o}function o(t,e){return a(t,e.v,e.w,e.name)}var s=t("./lodash");e.exports=n;var c="\x00",l="\x00",h="";n.prototype._nodeCount=0,n.prototype._edgeCount=0,n.prototype.isDirected=function(){return this._isDirected},n.prototype.isMultigraph=function(){return this._isMultigraph},n.prototype.isCompound=function(){return this._isCompound},n.prototype.setGraph=function(t){return this._label=t,this},n.prototype.graph=function(){return this._label},n.prototype.setDefaultNodeLabel=function(t){return s.isFunction(t)||(t=s.constant(t)),this._defaultNodeLabelFn=t,this},n.prototype.nodeCount=function(){return this._nodeCount},n.prototype.nodes=function(){return s.keys(this._nodes)},n.prototype.sources=function(){return s.filter(this.nodes(),function(t){return s.isEmpty(this._in[t])},this)},n.prototype.sinks=function(){return s.filter(this.nodes(),function(t){return s.isEmpty(this._out[t])},this)},n.prototype.setNodes=function(t,e){var n=arguments;return s.each(t,function(t){n.length>1?this.setNode(t,e):this.setNode(t)},this),this},n.prototype.setNode=function(t,e){return s.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]=l,this._children[t]={},this._children[l][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},n.prototype.node=function(t){return this._nodes[t]},n.prototype.hasNode=function(t){return s.has(this._nodes,t)},n.prototype.removeNode=function(t){var e=this;if(s.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],s.each(this.children(t),function(t){this.setParent(t)},this),delete this._children[t]),s.each(s.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],s.each(s.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},n.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(s.isUndefined(e))e=l;else{e+="";for(var n=e;!s.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},n.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},n.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!==l)return e}},n.prototype.children=function(t){if(s.isUndefined(t)&&(t=l),this._isCompound){var e=this._children[t];if(e)return s.keys(e)}else{if(t===l)return this.nodes();if(this.hasNode(t))return[]}},n.prototype.predecessors=function(t){var e=this._preds[t];return e?s.keys(e):void 0},n.prototype.successors=function(t){var e=this._sucs[t];return e?s.keys(e):void 0},n.prototype.neighbors=function(t){var e=this.predecessors(t);return e?s.union(e,this.successors(t)):void 0},n.prototype.filterNodes=function(t){function e(t){var a=r.parent(t);return void 0===a||n.hasNode(a)?(i[t]=a,a):a in i?i[a]:e(a)}var n=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});n.setGraph(this.graph()),s.each(this._nodes,function(e,r){t(r)&&n.setNode(r,e)},this),s.each(this._edgeObjs,function(t){n.hasNode(t.v)&&n.hasNode(t.w)&&n.setEdge(t,this.edge(t))},this);var r=this,i={};return this._isCompound&&s.each(n.nodes(),function(t){n.setParent(t,e(t))}),n},n.prototype.setDefaultEdgeLabel=function(t){return s.isFunction(t)||(t=s.constant(t)),this._defaultEdgeLabelFn=t,this},n.prototype.edgeCount=function(){return this._edgeCount},n.prototype.edges=function(){return s.values(this._edgeObjs)},n.prototype.setPath=function(t,e){var n=this,r=arguments;return s.reduce(t,function(t,i){return r.length>1?n.setEdge(t,i,e):n.setEdge(t,i),i}),this},n.prototype.setEdge=function(){var t,e,n,i,o=!1,c=arguments[0];"object"==typeof c&&null!==c&&"v"in c?(t=c.v,e=c.w,n=c.name,2===arguments.length&&(i=arguments[1],o=!0)):(t=c,e=arguments[1],n=arguments[3],arguments.length>2&&(i=arguments[2],o=!0)),t=""+t,e=""+e,s.isUndefined(n)||(n=""+n);var l=a(this._isDirected,t,e,n);if(s.has(this._edgeLabels,l))return o&&(this._edgeLabels[l]=i),this;if(!s.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[l]=o?i:this._defaultEdgeLabelFn(t,e,n);var h=u(this._isDirected,t,e,n);return t=h.v,e=h.w,Object.freeze(h),this._edgeObjs[l]=h,r(this._preds[e],t),r(this._sucs[t],e),this._in[e][l]=h,this._out[t][l]=h,this._edgeCount++,this},n.prototype.edge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return this._edgeLabels[r]},n.prototype.hasEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return s.has(this._edgeLabels,r)},n.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n),u=this._edgeObjs[r];return u&&(t=u.v,e=u.w,delete this._edgeLabels[r],delete this._edgeObjs[r],i(this._preds[e],t),i(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},n.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var r=s.values(n);return e?s.filter(r,function(t){return t.v===e}):r}},n.prototype.outEdges=function(t,e){var n=this._out[t];if(n){var r=s.values(n);return e?s.filter(r,function(t){return t.w===e}):r}},n.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);return n?n.concat(this.outEdges(t,e)):void 0}},{"./lodash":51}],49:[function(t,e){e.exports={Graph:t("./graph"),version:t("./version")}},{"./graph":48,"./version":52}],50:[function(t,e){function n(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:r(t),edges:i(t)};return u.isUndefined(t.graph())||(e.value=u.clone(t.graph())),e}function r(t){return u.map(t.nodes(),function(e){var n=t.node(e),r=t.parent(e),i={v:e};return u.isUndefined(n)||(i.value=n),u.isUndefined(r)||(i.parent=r),i})}function i(t){return u.map(t.edges(),function(e){var n=t.edge(e),r={v:e.v,w:e.w};return u.isUndefined(e.name)||(r.name=e.name),u.isUndefined(n)||(r.value=n),r})}function a(t){var e=new o(t.options).setGraph(t.value);return u.each(t.nodes,function(t){e.setNode(t.v,t.value),t.parent&&e.setParent(t.v,t.parent)}),u.each(t.edges,function(t){e.setEdge({v:t.v,w:t.w,name:t.name},t.value)}),e}var u=t("./lodash"),o=t("./graph");e.exports={write:n,read:a}},{"./graph":48,"./lodash":51}],51:[function(t,e){var n;if("function"==typeof t)try{n=t("lodash")}catch(r){}n||(n=window._),e.exports=n},{lodash:53}],52:[function(t,e){e.exports="1.0.7"},{}],53:[function(t,e,n){(function(t){(function(){function r(t,e){if(t!==e){var n=null===t,r=t===E,i=t===t,a=null===e,u=e===E,o=e===e;if(t>e&&!a||!i||n&&!u&&o||r&&o)return 1;if(e>t&&!n||!o||a&&!r&&i||u&&i)return-1}return 0}function i(t,e,n){for(var r=t.length,i=n?r:-1;n?i--:++i-1;);return n}function c(t,e){for(var n=t.length;n--&&e.indexOf(t.charAt(n))>-1;);return n}function l(t,e){return r(t.criteria,e.criteria)||t.index-e.index}function h(t,e,n){for(var i=-1,a=t.criteria,u=e.criteria,o=a.length,s=n.length;++i=s)return c;var l=n[i];return c*("asc"===l||l===!0?1:-1)}}return t.index-e.index}function f(t){return qt[t]}function d(t){return Wt[t]}function p(t,e,n){return e?t=Vt[t]:n&&(t=Xt[t]),"\\"+t}function g(t){return"\\"+Xt[t]}function y(t,e,n){for(var r=t.length,i=e+(n?0:-1);n?i--:++i=t&&t>=9&&13>=t||32==t||160==t||5760==t||6158==t||t>=8192&&(8202>=t||8232==t||8233==t||8239==t||8287==t||12288==t||65279==t)}function _(t,e){for(var n=-1,r=t.length,i=-1,a=[];++ne,i=n?t.length:0,a=Gn(0,i,this.__views__),u=a.start,o=a.end,s=o-u,c=r?o:u-1,l=this.__iteratees__,h=l.length,f=0,d=wu(s,this.__takeCount__);if(!n||Y>i||i==s&&d==s)return nn(r&&n?t.reverse():t,this.__actions__);var p=[];t:for(;s--&&d>f;){c+=e;for(var g=-1,y=t[c];++g=Y?gn(e):null,c=e.length;s&&(u=Kt,o=!1,e=s);t:for(;++in&&(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 Me(t,e){var n=[];return Nu(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}function Ce(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 Se(t,e,n,r){r||(r=[]);for(var i=-1,a=t.length;++ir;)t=t[e[r++]];return r&&r==i?t:E}}function Ne(t,e,n,r,i,a){return t===e?!0:null==t||null==e||!Oi(t)&&!m(e)?t!==t&&e!==e:Ie(t,e,Ne,n,r,i,a)}function Ie(t,e,n,r,i,a,u){var o=So(t),s=So(e),c=G,l=G;o||(c=nu.call(t),c==W?c=J:c!=J&&(o=zi(t))),s||(l=nu.call(e),l==W?l=J:l!=J&&(s=zi(e)));var h=c==J,f=l==J,d=c==l;if(d&&!o&&!h)return jn(t,e,c);if(!i){var p=h&&tu.call(t,"__wrapped__"),g=f&&tu.call(e,"__wrapped__");if(p||g)return n(p?t.value():t,g?e.value():e,r,i,a,u)}if(!d)return!1;a||(a=[]),u||(u=[]);for(var y=a.length;y--;)if(a[y]==t)return u[y]==e;a.push(t),u.push(e); -var m=(o?Rn:Yn)(t,e,n,r,i,a,u);return a.pop(),u.pop(),m}function Pe(t,e,n){var r=e.length,i=r,a=!n;if(null==t)return!i;for(t=hr(t);r--;){var u=e[r];if(a&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++re&&(e=-e>i?0:i+e),n=n===E||n>i?i:+n||0,0>n&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var a=Ya(i);++r=Y,s=o?gn():null,c=[];s?(r=Kt,u=!1):(o=!1,s=e?[]:c);t:for(;++n=i){for(;i>r;){var a=r+i>>>1,u=t[a];(n?e>=u:e>u)&&null!==u?r=a+1:i=a}return i}return an(t,e,Da,n)}function an(t,e,n,r){e=n(e);for(var i=0,a=t?t.length:0,u=e!==e,o=null===e,s=e===E;a>i;){var c=mu((i+a)/2),l=n(t[c]),h=l!==E,f=l===l;if(u)var d=f||r;else d=o?f&&h&&(r||null!=l):s?f&&(r||h):null==l?!1:r?e>=l:e>l;d?i=c+1:a=c}return wu(a,Su)}function un(t,e,n){if("function"!=typeof t)return Da;if(e===E)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,r,i){return t.call(e,n,r,i)};case 4:return function(n,r,i,a){return t.call(e,n,r,i,a)};case 5:return function(n,r,i,a,u){return t.call(e,n,r,i,a,u)}}return function(){return t.apply(e,arguments)}}function on(t){var e=new au(t.byteLength),n=new du(e);return n.set(new du(t)),e}function sn(t,e,n){for(var r=n.length,i=-1,a=xu(t.length-r,0),u=-1,o=e.length,s=Ya(o+a);++u2?n[i-2]:E,u=i>2?n[2]:E,o=i>1?n[i-1]:E;for("function"==typeof a?(a=un(a,o,5),i-=2):(a="function"==typeof o?o:E,i-=a?1:0),u&&Jn(n[0],n[1],u)&&(a=3>i?E:a,i=1);++r-1?n[u]:E}return Ce(n,r,t)}}function wn(t){return function(e,n,r){return e&&e.length?(n=Un(n,r,3),i(e,n,t)):-1}}function An(t){return function(e,n,r){return n=Un(n,r,3),Ce(e,n,t,!0)}}function kn(t){return function(){for(var e,n=arguments.length,r=t?n:-1,i=0,a=Ya(n);t?r--:++r=Y)return e.plant(r).value();for(var i=0,u=n?a[i].apply(this,t):r;++iv){var k=o?te(o):E,M=xu(c-v,0),S=p?A:E,T=p?E:A,F=p?x:E,O=p?E:x;e|=p?B:L,e&=~(p?L:B),g||(e&=~(D|C));var I=[t,e,n,F,S,O,T,k,s,M],N=Bn.apply(E,I);return er(t)&&$u(N,I),N.placeholder=w,N}}var P=f?n:this,R=d?P[t]:t;return o&&(x=sr(x,o)),h&&s=e||!_u(e))return"";var i=e-r;return n=null==n?" ":n+"",ya(n,gu(i/n.length)).slice(0,i)}function On(t,e,n,r){function i(){for(var e=-1,o=arguments.length,s=-1,c=r.length,l=Ya(c+o);++ss))return!1;for(;++o-1&&t%1==0&&e>t}function Jn(t,e,n){if(!Oi(n))return!1;var r=typeof e;if("number"==r?Kn(n)&&Qn(e,n.length):"string"==r&&e in n){var i=n[e];return t===t?t===i:i!==i}return!1}function tr(t,e){var n=typeof t;if("string"==n&&Et.test(t)||"number"==n)return!0;if(So(t))return!1;var r=!kt.test(t);return r||null!=e&&t in hr(e)}function er(t){var n=$n(t);if(!(n in K.prototype))return!1;var r=e[n];if(t===r)return!0;var i=Yu(r);return!!i&&t===i[0]}function nr(t){return"number"==typeof t&&t>-1&&t%1==0&&Fu>=t}function rr(t){return t===t&&!Oi(t)}function ir(t,e){var n=t[1],r=e[1],i=n|r,a=O>i,u=r==O&&n==T||r==O&&n==I&&t[7].length<=e[8]||r==(O|I)&&n==T;if(!a&&!u)return t;r&D&&(t[2]=e[2],i|=n&D?0:S);var o=e[3];if(o){var s=t[3];t[3]=s?sn(s,o,e[4]):te(o),t[4]=s?_(t[3],q):te(e[4])}return o=e[5],o&&(s=t[5],t[5]=s?cn(s,o,e[6]):te(o),t[6]=s?_(t[5],q):te(e[6])),o=e[7],o&&(t[7]=te(o)),r&O&&(t[8]=null==t[8]?e[8]:wu(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i,t}function ar(t,e){return t===E?e:To(t,e,ar)}function ur(t,e){t=hr(t);for(var n=-1,r=e.length,i={};++nr;)u[++a]=Ve(t,r,r+=e);return u}function gr(t){for(var e=-1,n=t?t.length:0,r=-1,i=[];++ee?0:e)):[]}function mr(t,e,n){var r=t?t.length:0;return r?((n?Jn(t,e,n):null==e)&&(e=1),e=r-(+e||0),Ve(t,0,0>e?0:e)):[]}function vr(t,e,n){return t&&t.length?en(t,Un(e,n,3),!0,!0):[]}function _r(t,e,n){return t&&t.length?en(t,Un(e,n,3),!0):[]}function br(t,e,n,r){var i=t?t.length:0;return i?(n&&"number"!=typeof n&&Jn(t,e,n)&&(n=0,r=i),Me(t,e,n,r)):[]}function xr(t){return t?t[0]:E}function wr(t,e,n){var r=t?t.length:0;return n&&Jn(t,e,n)&&(e=!1),r?Se(t,e):[]}function Ar(t){var e=t?t.length:0;return e?Se(t,!0):[]}function kr(t,e,n){var r=t?t.length:0;if(!r)return-1;if("number"==typeof n)n=0>n?xu(r+n,0):n;else if(n){var i=rn(t,e);return r>i&&(e===e?e===t[i]:t[i]!==t[i])?i:-1}return a(t,e,n||0)}function Er(t){return mr(t,1)}function Mr(t){var e=t?t.length:0;return e?t[e-1]:E}function Dr(t,e,n){var r=t?t.length:0;if(!r)return-1;var i=r;if("number"==typeof n)i=(0>n?xu(r+n,0):wu(n||0,r-1))+1;else if(n){i=rn(t,e,!0)-1;var a=t[i];return(e===e?e===a:a!==a)?i:-1}if(e!==e)return y(t,i,!0);for(;i--;)if(t[i]===e)return i;return-1}function Cr(){var t=arguments,e=t[0];if(!e||!e.length)return e;for(var n=0,r=zn(),i=t.length;++n-1;)fu.call(e,a,1);return e}function Sr(t,e,n){var r=[];if(!t||!t.length)return r;var i=-1,a=[],u=t.length;for(e=Un(e,n,3);++ie?0:e)):[]}function Lr(t,e,n){var r=t?t.length:0;return r?((n?Jn(t,e,n):null==e)&&(e=1),e=r-(+e||0),Ve(t,0>e?0:e)):[]}function Or(t,e,n){return t&&t.length?en(t,Un(e,n,3),!1,!0):[]}function Ir(t,e,n){return t&&t.length?en(t,Un(e,n,3)):[]}function Nr(t,e,n,r){var i=t?t.length:0;if(!i)return[];null!=e&&"boolean"!=typeof e&&(r=n,n=Jn(t,e,r)?E:e,e=!1);var u=Un();return(null!=n||u!==be)&&(n=u(n,r,3)),e&&zn()==a?b(t,n):Je(t,n)}function Pr(t){if(!t||!t.length)return[];var e=-1,n=0;t=oe(t,function(t){return Kn(t)?(n=xu(t.length,n),!0):void 0});for(var r=Ya(n);++en?xu(i+n,0):n||0,"string"==typeof t||!So(t)&&$i(t)?i>=n&&t.indexOf(e,n)>-1:!!i&&zn(t,e,n)>-1}function ti(t,e,n){var r=So(t)?se:Re;return e=Un(e,n,3),r(t,e)}function ei(t,e){return ti(t,La(e))}function ni(t,e,n){var r=So(t)?oe:De;return e=Un(e,n,3),r(t,function(t,n,r){return!e(t,n,r)})}function ri(t,e,n){if(n?Jn(t,e,n):null==e){t=lr(t);var r=t.length;return r>0?t[Ge(0,r-1)]:E}var i=-1,a=Hi(t),r=a.length,u=r-1;for(e=wu(0>e?0:+e||0,r);++i0&&(n=e.apply(this,arguments)),1>=t&&(e=E),n}}function di(t,e,n){function r(){d&&uu(d),c&&uu(c),g=0,c=d=p=E}function i(e,n){n&&uu(n),c=d=p=E,e&&(g=go(),l=t.apply(f,s),d||c||(s=f=E))}function a(){var t=e-(go()-h);0>=t||t>e?i(p,c):d=hu(a,t)}function u(){i(m,d)}function o(){if(s=arguments,h=go(),f=this,p=m&&(d||!v),y===!1)var n=v&&!d;else{c||v||(g=h);var r=y-(h-g),i=0>=r||r>y;i?(c&&(c=uu(c)),g=h,l=t.apply(f,s)):c||(c=hu(u,r))}return i&&d?d=uu(d):d||e===y||(d=hu(a,e)),n&&(i=!0,l=t.apply(f,s)),!i||d||c||(s=f=E),l}var s,c,l,h,f,d,p,g=0,y=!1,m=!0;if("function"!=typeof t)throw new Xa(z);if(e=0>e?0:+e||0,n===!0){var v=!0;m=!1}else Oi(n)&&(v=!!n.leading,y="maxWait"in n&&xu(+n.maxWait||0,e),m="trailing"in n?!!n.trailing:m);return o.cancel=r,o}function pi(t,e){if("function"!=typeof t||e&&"function"!=typeof e)throw new Xa(z);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 u=t.apply(this,r);return n.cache=a.set(i,u),u};return n.cache=new pi.Cache,n}function gi(t){if("function"!=typeof t)throw new Xa(z);return function(){return!t.apply(this,arguments)}}function yi(t){return fi(2,t)}function mi(t,e){if("function"!=typeof t)throw new Xa(z);return e=xu(e===E?t.length-1:+e||0,0),function(){for(var n=arguments,r=-1,i=xu(n.length-e,0),a=Ya(i);++re}function ki(t,e){return t>=e}function Ei(t){return m(t)&&Kn(t)&&tu.call(t,"callee")&&!cu.call(t,"callee")}function Mi(t){return t===!0||t===!1||m(t)&&nu.call(t)==H}function Di(t){return m(t)&&nu.call(t)==V}function Ci(t){return!!t&&1===t.nodeType&&m(t)&&!Yi(t)}function Si(t){return null==t?!0:Kn(t)&&(So(t)||$i(t)||Ei(t)||m(t)&&Li(t.splice))?!t.length:!Yo(t).length}function Ti(t,e,n,r){n="function"==typeof n?un(n,r,3):E;var i=n?n(t,e):E;return i===E?Ie(t,e,n):!!i}function Fi(t){return m(t)&&"string"==typeof t.message&&nu.call(t)==X}function Bi(t){return"number"==typeof t&&_u(t)}function Li(t){return Oi(t)&&nu.call(t)==Z}function Oi(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function Ii(t,e,n,r){return n="function"==typeof n?un(n,r,3):E,Pe(t,qn(e),n)}function Ni(t){return ji(t)&&t!=+t}function Pi(t){return null==t?!1:Li(t)?iu.test(Ja.call(t)):m(t)&&Ot.test(t)}function Ri(t){return null===t}function ji(t){return"number"==typeof t||m(t)&&nu.call(t)==Q}function Yi(t){var e;if(!m(t)||nu.call(t)!=J||Ei(t)||!tu.call(t,"constructor")&&(e=t.constructor,"function"==typeof e&&!(e instanceof e)))return!1;var n;return Te(t,function(t,e){n=e}),n===E||tu.call(t,n)}function Ui(t){return Oi(t)&&nu.call(t)==tt}function $i(t){return"string"==typeof t||m(t)&&nu.call(t)==nt}function zi(t){return m(t)&&nr(t.length)&&!!$t[nu.call(t)]}function qi(t){return t===E}function Wi(t,e){return e>t}function Gi(t,e){return e>=t}function Hi(t){var e=t?Uu(t):0;return nr(e)?e?te(t):[]:aa(t)}function Vi(t){return _e(t,ta(t))}function Xi(t,e,n){var r=Ou(t);return n&&Jn(t,e,n)&&(e=E),e?me(r,e):r}function Zi(t){return Le(t,ta(t))}function Ki(t,e,n){var r=null==t?E:Oe(t,fr(e),e+"");return r===E?n:r}function Qi(t,e){if(null==t)return!1;var n=tu.call(t,e);if(!n&&!tr(e)){if(e=fr(e),t=1==e.length?t:Oe(t,Ve(e,0,-1)),null==t)return!1;e=Mr(e),n=tu.call(t,e)}return n||nr(t.length)&&Qn(e,t.length)&&(So(t)||Ei(t))}function Ji(t,e,n){n&&Jn(t,e,n)&&(e=E);for(var r=-1,i=Yo(t),a=i.length,u={};++r0;++r=wu(e,n)&&tn?0:+n||0,r),n-=e.length,n>=0&&t.indexOf(e,n)==n}function fa(t){return t=o(t),t&&bt.test(t)?t.replace(vt,d):t}function da(t){return t=o(t),t&&Ct.test(t)?t.replace(Dt,p):t||"(?:)"}function pa(t,e,n){t=o(t),e=+e;var r=t.length;if(r>=e||!_u(e))return t;var i=(e-r)/2,a=mu(i),u=gu(i);return n=Ln("",u,n),n.slice(0,a)+t+n}function ga(t,e,n){return(n?Jn(t,e,n):null==e)?e=0:e&&(e=+e),t=_a(t),ku(t,e||(Lt.test(t)?16:10))}function ya(t,e){var n="";if(t=o(t),e=+e,1>e||!t||!_u(e))return n;do e%2&&(n+=t),e=mu(e/2),t+=t;while(e);return n}function ma(t,e,n){return t=o(t),n=null==n?0:wu(0>n?0:+n||0,t.length),t.lastIndexOf(e,n)==n}function va(t,n,r){var i=e.templateSettings;r&&Jn(t,n,r)&&(n=r=E),t=o(t),n=ye(me({},r||n),i,ge);var a,u,s=ye(me({},n.imports),i.imports,ge),c=Yo(s),l=tn(s,c),h=0,f=n.interpolate||Pt,d="__p += '",p=Ha((n.escape||Pt).source+"|"+f.source+"|"+(f===At?Ft:Pt).source+"|"+(n.evaluate||Pt).source+"|$","g"),y="//# sourceURL="+("sourceURL"in n?n.sourceURL:"lodash.templateSources["+ ++Ut+"]")+"\n";t.replace(p,function(e,n,r,i,o,s){return r||(r=i),d+=t.slice(h,s).replace(Rt,g),n&&(a=!0,d+="' +\n__e("+n+") +\n'"),o&&(u=!0,d+="';\n"+o+";\n__p += '"),r&&(d+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),h=s+e.length,e}),d+="';\n";var m=n.variable;m||(d="with (obj) {\n"+d+"\n}\n"),d=(u?d.replace(pt,""):d).replace(gt,"$1").replace(yt,"$1;"),d="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(a?", __e = _.escape":"")+(u?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+d+"return __p\n}";var v=Ko(function(){return za(c,y+"return "+d).apply(E,l)});if(v.source=d,Fi(v))throw v;return v}function _a(t,e,n){var r=t;return(t=o(t))?(n?Jn(r,e,n):null==e)?t.slice(x(t),w(t)+1):(e+="",t.slice(s(t,e),c(t,e)+1)):t}function ba(t,e,n){var r=t;return t=o(t),t?t.slice((n?Jn(r,e,n):null==e)?x(t):s(t,e+"")):t}function xa(t,e,n){var r=t;return t=o(t),t?(n?Jn(r,e,n):null==e)?t.slice(0,w(t)+1):t.slice(0,c(t,e+"")+1):t}function wa(t,e,n){n&&Jn(t,e,n)&&(e=E);var r=N,i=P;if(null!=e)if(Oi(e)){var a="separator"in e?e.separator:a;r="length"in e?+e.length||0:r,i="omission"in e?o(e.omission):i}else r=+e||0;if(t=o(t),r>=t.length)return t;var u=r-i.length;if(1>u)return i;var s=t.slice(0,u);if(null==a)return s+i;if(Ui(a)){if(t.slice(u).search(a)){var c,l,h=t.slice(0,u);for(a.global||(a=Ha(a.source,(Bt.exec(a)||"")+"g")),a.lastIndex=0;c=a.exec(h);)l=c.index;s=s.slice(0,null==l?u:l)}}else if(t.indexOf(a,u)!=u){var f=s.lastIndexOf(a);f>-1&&(s=s.slice(0,f))}return s+i}function Aa(t){return t=o(t),t&&_t.test(t)?t.replace(mt,A):t}function ka(t,e,n){return n&&Jn(t,e,n)&&(e=E),t=o(t),t.match(e||jt)||[]}function Ea(t,e,n){return n&&Jn(t,e,n)&&(e=E),m(t)?Ca(t):be(t,e)}function Ma(t){return function(){return t}}function Da(t){return t}function Ca(t){return je(xe(t,!0))}function Sa(t,e){return Ye(t,xe(e,!0))}function Ta(t,e,n){if(null==n){var r=Oi(e),i=r?Yo(e):E,a=i&&i.length?Le(e,i):E;(a?a.length:r)||(a=!1,n=e,e=t,t=this)}a||(a=Le(e,Yo(e)));var u=!0,o=-1,s=Li(t),c=a.length;n===!1?u=!1:Oi(n)&&"chain"in n&&(u=n.chain);for(;++ot||!_u(t))return[];var r=-1,i=Ya(wu(t,Cu));for(e=un(e,n,1);++rr?i[r]=e(r):e(r);return i}function Pa(t){var e=++eu;return o(t)+e}function Ra(t,e){return(+t||0)+(+e||0)}function ja(t,e,n){return n&&Jn(t,e,n)&&(e=E),e=Un(e,n,3),1==e.length?de(So(t)?t:lr(t),e):Qe(t,e)}t=t?re.defaults(ne.Object(),t,re.pick(ne,Yt)):ne;{var Ya=t.Array,Ua=t.Date,$a=t.Error,za=t.Function,qa=t.Math,Wa=t.Number,Ga=t.Object,Ha=t.RegExp,Va=t.String,Xa=t.TypeError,Za=Ya.prototype,Ka=Ga.prototype,Qa=Va.prototype,Ja=za.prototype.toString,tu=Ka.hasOwnProperty,eu=0,nu=Ka.toString,ru=ne._,iu=Ha("^"+Ja.call(tu).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),au=t.ArrayBuffer,uu=t.clearTimeout,ou=t.parseFloat,su=qa.pow,cu=Ka.propertyIsEnumerable,lu=Wn(t,"Set"),hu=t.setTimeout,fu=Za.splice,du=t.Uint8Array,pu=Wn(t,"WeakMap"),gu=qa.ceil,yu=Wn(Ga,"create"),mu=qa.floor,vu=Wn(Ya,"isArray"),_u=t.isFinite,bu=Wn(Ga,"keys"),xu=qa.max,wu=qa.min,Au=Wn(Ua,"now"),ku=t.parseInt,Eu=qa.random,Mu=Wa.NEGATIVE_INFINITY,Du=Wa.POSITIVE_INFINITY,Cu=4294967295,Su=Cu-1,Tu=Cu>>>1,Fu=9007199254740991,Bu=pu&&new pu,Lu={};e.support={}}e.templateSettings={escape:xt,evaluate:wt,interpolate:At,variable:"",imports:{_:e}};var Ou=function(){function t(){}return function(e){if(Oi(e)){t.prototype=e;var n=new t;t.prototype=E}return n||{}}}(),Iu=fn(Fe),Nu=fn(Be,!0),Pu=dn(),Ru=dn(!0),ju=Bu?function(t,e){return Bu.set(t,e),t}:Da,Yu=Bu?function(t){return Bu.get(t)}:Ba,Uu=ze("length"),$u=function(){var t=0,e=0;return function(n,r){var i=go(),a=j-(i-e);if(e=i,a>0){if(++t>=R)return n}else t=0;return ju(n,r)}}(),zu=mi(function(t,e){return m(t)&&Kn(t)?Ae(t,Se(e,!1,!0)):[]}),qu=wn(),Wu=wn(!0),Gu=mi(function(t){for(var e=t.length,n=e,r=Ya(h),i=zn(),u=i==a,o=[];n--;){var s=t[n]=Kn(s=t[n])?s:[];r[n]=u&&s.length>=120?gn(n&&s):null}var c=t[0],l=-1,h=c?c.length:0,f=r[0];t:for(;++l2?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,Rr(t,n,r)}),to=mi(function(t){return t=Se(t),this.thru(function(e){return Jt(So(e)?e:[hr(e)],t)})}),eo=mi(function(t,e){return ve(t,Se(e))}),no=ln(function(t,e,n){tu.call(t,n)?++t[n]:t[n]=1}),ro=xn(Iu),io=xn(Nu,!0),ao=En(ee,Iu),uo=En(ie,Nu),oo=ln(function(t,e,n){tu.call(t,n)?t[n].push(e):t[n]=[e]}),so=ln(function(t,e,n){t[n]=e}),co=mi(function(t,e,n){var r=-1,i="function"==typeof e,a=tr(e),u=Kn(t)?Ya(t.length):[];return Iu(t,function(t){var o=i?e:a&&null!=t?t[e]:E;u[++r]=o?o.apply(t,n):Zn(t,e,n)}),u}),lo=ln(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),ho=Fn(le,Iu),fo=Fn(he,Nu),po=mi(function(t,e){if(null==t)return[];var n=e[2];return n&&Jn(e[0],e[1],n)&&(e.length=1),Ke(t,Se(e),[])}),go=Au||function(){return(new Ua).getTime()},yo=mi(function(t,e,n){var r=D;if(n.length){var i=_(n,yo.placeholder);r|=B}return Pn(t,r,e,n,i)}),mo=mi(function(t,e){e=e.length?Se(e):Zi(t);for(var n=-1,r=e.length;++ne&&(e=-e>i?0:i+e),n=n===E||n>i?i:+n||0,0>n&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var a=Ya(i);++r=Y,s=o?gn():null,c=[];s?(r=Kt,u=!1):(o=!1,s=e?[]:c);t:for(;++n=i){for(;i>r;){var a=r+i>>>1,u=t[a];(n?e>=u:e>u)&&null!==u?r=a+1:i=a}return i}return an(t,e,Ma,n)}function an(t,e,n,r){e=n(e);for(var i=0,a=t?t.length:0,u=e!==e,o=null===e,s=e===E;a>i;){var c=mu((i+a)/2),l=n(t[c]),h=l!==E,f=l===l;if(u)var d=f||r;else d=o?f&&h&&(r||null!=l):s?f&&(r||h):null==l?!1:r?e>=l:e>l;d?i=c+1:a=c}return wu(a,Su)}function un(t,e,n){if("function"!=typeof t)return Ma;if(e===E)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,r,i){return t.call(e,n,r,i)};case 4:return function(n,r,i,a){return t.call(e,n,r,i,a)};case 5:return function(n,r,i,a,u){return t.call(e,n,r,i,a,u)}}return function(){return t.apply(e,arguments)}}function on(t){var e=new au(t.byteLength),n=new du(e);return n.set(new du(t)),e}function sn(t,e,n){for(var r=n.length,i=-1,a=xu(t.length-r,0),u=-1,o=e.length,s=Ya(o+a);++u2?n[i-2]:E,u=i>2?n[2]:E,o=i>1?n[i-1]:E;for("function"==typeof a?(a=un(a,o,5),i-=2):(a="function"==typeof o?o:E,i-=a?1:0),u&&Jn(n[0],n[1],u)&&(a=3>i?E:a,i=1);++r-1?n[u]:E}return Ce(n,r,t)}}function wn(t){return function(e,n,r){return e&&e.length?(n=Un(n,r,3),i(e,n,t)):-1}}function An(t){return function(e,n,r){return n=Un(n,r,3),Ce(e,n,t,!0)}}function kn(t){return function(){for(var e,n=arguments.length,r=t?n:-1,i=0,a=Ya(n);t?r--:++r=Y)return e.plant(r).value();for(var i=0,u=n?a[i].apply(this,t):r;++iv){var k=o?te(o):E,D=xu(c-v,0),S=p?A:E,T=p?E:A,F=p?x:E,O=p?E:x;e|=p?B:L,e&=~(p?L:B),g||(e&=~(M|C));var N=[t,e,n,F,S,O,T,k,s,D],I=Bn.apply(E,N);return er(t)&&$u(I,N),I.placeholder=w,I}}var P=f?n:this,R=d?P[t]:t;return o&&(x=sr(x,o)),h&&s=e||!_u(e))return"";var i=e-r;return n=null==n?" ":n+"",ya(n,gu(i/n.length)).slice(0,i)}function On(t,e,n,r){function i(){for(var e=-1,o=arguments.length,s=-1,c=r.length,l=Ya(c+o);++ss))return!1;for(;++o-1&&t%1==0&&e>t}function Jn(t,e,n){if(!Oi(n))return!1;var r=typeof e;if("number"==r?Kn(n)&&Qn(e,n.length):"string"==r&&e in n){var i=n[e];return t===t?t===i:i!==i}return!1}function tr(t,e){var n=typeof t;if("string"==n&&Et.test(t)||"number"==n)return!0;if(So(t))return!1;var r=!kt.test(t);return r||null!=e&&t in hr(e)}function er(t){var n=$n(t);if(!(n in K.prototype))return!1;var r=e[n];if(t===r)return!0;var i=Yu(r);return!!i&&t===i[0]}function nr(t){return"number"==typeof t&&t>-1&&t%1==0&&Fu>=t}function rr(t){return t===t&&!Oi(t)}function ir(t,e){var n=t[1],r=e[1],i=n|r,a=O>i,u=r==O&&n==T||r==O&&n==N&&t[7].length<=e[8]||r==(O|N)&&n==T;if(!a&&!u)return t;r&M&&(t[2]=e[2],i|=n&M?0:S);var o=e[3];if(o){var s=t[3];t[3]=s?sn(s,o,e[4]):te(o),t[4]=s?_(t[3],q):te(e[4])}return o=e[5],o&&(s=t[5],t[5]=s?cn(s,o,e[6]):te(o),t[6]=s?_(t[5],q):te(e[6])),o=e[7],o&&(t[7]=te(o)),r&O&&(t[8]=null==t[8]?e[8]:wu(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i,t}function ar(t,e){return t===E?e:To(t,e,ar)}function ur(t,e){t=hr(t);for(var n=-1,r=e.length,i={};++nr;)u[++a]=Ve(t,r,r+=e);return u}function gr(t){for(var e=-1,n=t?t.length:0,r=-1,i=[];++ee?0:e)):[]}function mr(t,e,n){var r=t?t.length:0;return r?((n?Jn(t,e,n):null==e)&&(e=1),e=r-(+e||0),Ve(t,0,0>e?0:e)):[]}function vr(t,e,n){return t&&t.length?en(t,Un(e,n,3),!0,!0):[]}function _r(t,e,n){return t&&t.length?en(t,Un(e,n,3),!0):[]}function br(t,e,n,r){var i=t?t.length:0;return i?(n&&"number"!=typeof n&&Jn(t,e,n)&&(n=0,r=i),De(t,e,n,r)):[]}function xr(t){return t?t[0]:E}function wr(t,e,n){var r=t?t.length:0;return n&&Jn(t,e,n)&&(e=!1),r?Se(t,e):[]}function Ar(t){var e=t?t.length:0;return e?Se(t,!0):[]}function kr(t,e,n){var r=t?t.length:0;if(!r)return-1;if("number"==typeof n)n=0>n?xu(r+n,0):n;else if(n){var i=rn(t,e);return r>i&&(e===e?e===t[i]:t[i]!==t[i])?i:-1}return a(t,e,n||0)}function Er(t){return mr(t,1)}function Dr(t){var e=t?t.length:0;return e?t[e-1]:E}function Mr(t,e,n){var r=t?t.length:0;if(!r)return-1;var i=r;if("number"==typeof n)i=(0>n?xu(r+n,0):wu(n||0,r-1))+1;else if(n){i=rn(t,e,!0)-1;var a=t[i];return(e===e?e===a:a!==a)?i:-1}if(e!==e)return y(t,i,!0);for(;i--;)if(t[i]===e)return i;return-1}function Cr(){var t=arguments,e=t[0];if(!e||!e.length)return e;for(var n=0,r=zn(),i=t.length;++n-1;)fu.call(e,a,1);return e}function Sr(t,e,n){var r=[];if(!t||!t.length)return r;var i=-1,a=[],u=t.length;for(e=Un(e,n,3);++ie?0:e)):[]}function Lr(t,e,n){var r=t?t.length:0;return r?((n?Jn(t,e,n):null==e)&&(e=1),e=r-(+e||0),Ve(t,0>e?0:e)):[]}function Or(t,e,n){return t&&t.length?en(t,Un(e,n,3),!1,!0):[]}function Nr(t,e,n){return t&&t.length?en(t,Un(e,n,3)):[]}function Ir(t,e,n,r){var i=t?t.length:0;if(!i)return[];null!=e&&"boolean"!=typeof e&&(r=n,n=Jn(t,e,r)?E:e,e=!1);var u=Un();return(null!=n||u!==be)&&(n=u(n,r,3)),e&&zn()==a?b(t,n):Je(t,n)}function Pr(t){if(!t||!t.length)return[];var e=-1,n=0;t=oe(t,function(t){return Kn(t)?(n=xu(t.length,n),!0):void 0});for(var r=Ya(n);++en?xu(i+n,0):n||0,"string"==typeof t||!So(t)&&$i(t)?i>=n&&t.indexOf(e,n)>-1:!!i&&zn(t,e,n)>-1}function ti(t,e,n){var r=So(t)?se:Re;return e=Un(e,n,3),r(t,e)}function ei(t,e){return ti(t,La(e))}function ni(t,e,n){var r=So(t)?oe:Me;return e=Un(e,n,3),r(t,function(t,n,r){return!e(t,n,r)})}function ri(t,e,n){if(n?Jn(t,e,n):null==e){t=lr(t);var r=t.length;return r>0?t[Ge(0,r-1)]:E}var i=-1,a=Hi(t),r=a.length,u=r-1;for(e=wu(0>e?0:+e||0,r);++i0&&(n=e.apply(this,arguments)),1>=t&&(e=E),n}}function di(t,e,n){function r(){d&&uu(d),c&&uu(c),g=0,c=d=p=E}function i(e,n){n&&uu(n),c=d=p=E,e&&(g=go(),l=t.apply(f,s),d||c||(s=f=E))}function a(){var t=e-(go()-h);0>=t||t>e?i(p,c):d=hu(a,t)}function u(){i(m,d)}function o(){if(s=arguments,h=go(),f=this,p=m&&(d||!v),y===!1)var n=v&&!d;else{c||v||(g=h);var r=y-(h-g),i=0>=r||r>y;i?(c&&(c=uu(c)),g=h,l=t.apply(f,s)):c||(c=hu(u,r))}return i&&d?d=uu(d):d||e===y||(d=hu(a,e)),n&&(i=!0,l=t.apply(f,s)),!i||d||c||(s=f=E),l}var s,c,l,h,f,d,p,g=0,y=!1,m=!0;if("function"!=typeof t)throw new Xa(z);if(e=0>e?0:+e||0,n===!0){var v=!0;m=!1}else Oi(n)&&(v=!!n.leading,y="maxWait"in n&&xu(+n.maxWait||0,e),m="trailing"in n?!!n.trailing:m);return o.cancel=r,o}function pi(t,e){if("function"!=typeof t||e&&"function"!=typeof e)throw new Xa(z);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 u=t.apply(this,r);return n.cache=a.set(i,u),u};return n.cache=new pi.Cache,n}function gi(t){if("function"!=typeof t)throw new Xa(z);return function(){return!t.apply(this,arguments)}}function yi(t){return fi(2,t)}function mi(t,e){if("function"!=typeof t)throw new Xa(z);return e=xu(e===E?t.length-1:+e||0,0),function(){for(var n=arguments,r=-1,i=xu(n.length-e,0),a=Ya(i);++re}function ki(t,e){return t>=e}function Ei(t){return m(t)&&Kn(t)&&tu.call(t,"callee")&&!cu.call(t,"callee")}function Di(t){return t===!0||t===!1||m(t)&&nu.call(t)==H}function Mi(t){return m(t)&&nu.call(t)==V}function Ci(t){return!!t&&1===t.nodeType&&m(t)&&!Yi(t)}function Si(t){return null==t?!0:Kn(t)&&(So(t)||$i(t)||Ei(t)||m(t)&&Li(t.splice))?!t.length:!Yo(t).length}function Ti(t,e,n,r){n="function"==typeof n?un(n,r,3):E;var i=n?n(t,e):E;return i===E?Ne(t,e,n):!!i}function Fi(t){return m(t)&&"string"==typeof t.message&&nu.call(t)==X}function Bi(t){return"number"==typeof t&&_u(t)}function Li(t){return Oi(t)&&nu.call(t)==Z}function Oi(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function Ni(t,e,n,r){return n="function"==typeof n?un(n,r,3):E,Pe(t,qn(e),n)}function Ii(t){return ji(t)&&t!=+t}function Pi(t){return null==t?!1:Li(t)?iu.test(Ja.call(t)):m(t)&&Ot.test(t)}function Ri(t){return null===t}function ji(t){return"number"==typeof t||m(t)&&nu.call(t)==Q}function Yi(t){var e;if(!m(t)||nu.call(t)!=J||Ei(t)||!tu.call(t,"constructor")&&(e=t.constructor,"function"==typeof e&&!(e instanceof e)))return!1;var n;return Te(t,function(t,e){n=e}),n===E||tu.call(t,n)}function Ui(t){return Oi(t)&&nu.call(t)==tt}function $i(t){return"string"==typeof t||m(t)&&nu.call(t)==nt}function zi(t){return m(t)&&nr(t.length)&&!!$t[nu.call(t)]}function qi(t){return t===E}function Wi(t,e){return e>t}function Gi(t,e){return e>=t}function Hi(t){var e=t?Uu(t):0;return nr(e)?e?te(t):[]:aa(t)}function Vi(t){return _e(t,ta(t))}function Xi(t,e,n){var r=Ou(t);return n&&Jn(t,e,n)&&(e=E),e?me(r,e):r}function Zi(t){return Le(t,ta(t))}function Ki(t,e,n){var r=null==t?E:Oe(t,fr(e),e+"");return r===E?n:r}function Qi(t,e){if(null==t)return!1;var n=tu.call(t,e);if(!n&&!tr(e)){if(e=fr(e),t=1==e.length?t:Oe(t,Ve(e,0,-1)),null==t)return!1;e=Dr(e),n=tu.call(t,e)}return n||nr(t.length)&&Qn(e,t.length)&&(So(t)||Ei(t))}function Ji(t,e,n){n&&Jn(t,e,n)&&(e=E);for(var r=-1,i=Yo(t),a=i.length,u={};++r0;++r=wu(e,n)&&tn?0:+n||0,r),n-=e.length,n>=0&&t.indexOf(e,n)==n}function fa(t){return t=o(t),t&&bt.test(t)?t.replace(vt,d):t}function da(t){return t=o(t),t&&Ct.test(t)?t.replace(Mt,p):t||"(?:)"}function pa(t,e,n){t=o(t),e=+e;var r=t.length;if(r>=e||!_u(e))return t;var i=(e-r)/2,a=mu(i),u=gu(i);return n=Ln("",u,n),n.slice(0,a)+t+n}function ga(t,e,n){return(n?Jn(t,e,n):null==e)?e=0:e&&(e=+e),t=_a(t),ku(t,e||(Lt.test(t)?16:10))}function ya(t,e){var n="";if(t=o(t),e=+e,1>e||!t||!_u(e))return n;do e%2&&(n+=t),e=mu(e/2),t+=t;while(e);return n}function ma(t,e,n){return t=o(t),n=null==n?0:wu(0>n?0:+n||0,t.length),t.lastIndexOf(e,n)==n}function va(t,n,r){var i=e.templateSettings;r&&Jn(t,n,r)&&(n=r=E),t=o(t),n=ye(me({},r||n),i,ge);var a,u,s=ye(me({},n.imports),i.imports,ge),c=Yo(s),l=tn(s,c),h=0,f=n.interpolate||Pt,d="__p += '",p=Ha((n.escape||Pt).source+"|"+f.source+"|"+(f===At?Ft:Pt).source+"|"+(n.evaluate||Pt).source+"|$","g"),y="//# sourceURL="+("sourceURL"in n?n.sourceURL:"lodash.templateSources["+ ++Ut+"]")+"\n";t.replace(p,function(e,n,r,i,o,s){return r||(r=i),d+=t.slice(h,s).replace(Rt,g),n&&(a=!0,d+="' +\n__e("+n+") +\n'"),o&&(u=!0,d+="';\n"+o+";\n__p += '"),r&&(d+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),h=s+e.length,e}),d+="';\n";var m=n.variable;m||(d="with (obj) {\n"+d+"\n}\n"),d=(u?d.replace(pt,""):d).replace(gt,"$1").replace(yt,"$1;"),d="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(a?", __e = _.escape":"")+(u?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+d+"return __p\n}";var v=Ko(function(){return za(c,y+"return "+d).apply(E,l)});if(v.source=d,Fi(v))throw v;return v}function _a(t,e,n){var r=t;return(t=o(t))?(n?Jn(r,e,n):null==e)?t.slice(x(t),w(t)+1):(e+="",t.slice(s(t,e),c(t,e)+1)):t}function ba(t,e,n){var r=t;return t=o(t),t?t.slice((n?Jn(r,e,n):null==e)?x(t):s(t,e+"")):t}function xa(t,e,n){var r=t;return t=o(t),t?(n?Jn(r,e,n):null==e)?t.slice(0,w(t)+1):t.slice(0,c(t,e+"")+1):t}function wa(t,e,n){n&&Jn(t,e,n)&&(e=E);var r=I,i=P;if(null!=e)if(Oi(e)){var a="separator"in e?e.separator:a;r="length"in e?+e.length||0:r,i="omission"in e?o(e.omission):i}else r=+e||0;if(t=o(t),r>=t.length)return t;var u=r-i.length;if(1>u)return i;var s=t.slice(0,u);if(null==a)return s+i;if(Ui(a)){if(t.slice(u).search(a)){var c,l,h=t.slice(0,u);for(a.global||(a=Ha(a.source,(Bt.exec(a)||"")+"g")),a.lastIndex=0;c=a.exec(h);)l=c.index;s=s.slice(0,null==l?u:l)}}else if(t.indexOf(a,u)!=u){var f=s.lastIndexOf(a);f>-1&&(s=s.slice(0,f))}return s+i}function Aa(t){return t=o(t),t&&_t.test(t)?t.replace(mt,A):t}function ka(t,e,n){return n&&Jn(t,e,n)&&(e=E),t=o(t),t.match(e||jt)||[]}function Ea(t,e,n){return n&&Jn(t,e,n)&&(e=E),m(t)?Ca(t):be(t,e)}function Da(t){return function(){return t}}function Ma(t){return t}function Ca(t){return je(xe(t,!0))}function Sa(t,e){return Ye(t,xe(e,!0))}function Ta(t,e,n){if(null==n){var r=Oi(e),i=r?Yo(e):E,a=i&&i.length?Le(e,i):E;(a?a.length:r)||(a=!1,n=e,e=t,t=this)}a||(a=Le(e,Yo(e)));var u=!0,o=-1,s=Li(t),c=a.length;n===!1?u=!1:Oi(n)&&"chain"in n&&(u=n.chain);for(;++ot||!_u(t))return[];var r=-1,i=Ya(wu(t,Cu));for(e=un(e,n,1);++rr?i[r]=e(r):e(r);return i}function Pa(t){var e=++eu;return o(t)+e}function Ra(t,e){return(+t||0)+(+e||0)}function ja(t,e,n){return n&&Jn(t,e,n)&&(e=E),e=Un(e,n,3),1==e.length?de(So(t)?t:lr(t),e):Qe(t,e)}t=t?re.defaults(ne.Object(),t,re.pick(ne,Yt)):ne;{var Ya=t.Array,Ua=t.Date,$a=t.Error,za=t.Function,qa=t.Math,Wa=t.Number,Ga=t.Object,Ha=t.RegExp,Va=t.String,Xa=t.TypeError,Za=Ya.prototype,Ka=Ga.prototype,Qa=Va.prototype,Ja=za.prototype.toString,tu=Ka.hasOwnProperty,eu=0,nu=Ka.toString,ru=ne._,iu=Ha("^"+Ja.call(tu).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),au=t.ArrayBuffer,uu=t.clearTimeout,ou=t.parseFloat,su=qa.pow,cu=Ka.propertyIsEnumerable,lu=Wn(t,"Set"),hu=t.setTimeout,fu=Za.splice,du=t.Uint8Array,pu=Wn(t,"WeakMap"),gu=qa.ceil,yu=Wn(Ga,"create"),mu=qa.floor,vu=Wn(Ya,"isArray"),_u=t.isFinite,bu=Wn(Ga,"keys"),xu=qa.max,wu=qa.min,Au=Wn(Ua,"now"),ku=t.parseInt,Eu=qa.random,Du=Wa.NEGATIVE_INFINITY,Mu=Wa.POSITIVE_INFINITY,Cu=4294967295,Su=Cu-1,Tu=Cu>>>1,Fu=9007199254740991,Bu=pu&&new pu,Lu={};e.support={}}e.templateSettings={escape:xt,evaluate:wt,interpolate:At,variable:"",imports:{_:e}};var Ou=function(){function t(){}return function(e){if(Oi(e)){t.prototype=e;var n=new t;t.prototype=E}return n||{}}}(),Nu=fn(Fe),Iu=fn(Be,!0),Pu=dn(),Ru=dn(!0),ju=Bu?function(t,e){return Bu.set(t,e),t}:Ma,Yu=Bu?function(t){return Bu.get(t)}:Ba,Uu=ze("length"),$u=function(){var t=0,e=0;return function(n,r){var i=go(),a=j-(i-e);if(e=i,a>0){if(++t>=R)return n}else t=0;return ju(n,r)}}(),zu=mi(function(t,e){return m(t)&&Kn(t)?Ae(t,Se(e,!1,!0)):[]}),qu=wn(),Wu=wn(!0),Gu=mi(function(t){for(var e=t.length,n=e,r=Ya(h),i=zn(),u=i==a,o=[];n--;){var s=t[n]=Kn(s=t[n])?s:[];r[n]=u&&s.length>=120?gn(n&&s):null}var c=t[0],l=-1,h=c?c.length:0,f=r[0];t:for(;++l2?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,Rr(t,n,r)}),to=mi(function(t){return t=Se(t),this.thru(function(e){return Jt(So(e)?e:[hr(e)],t)})}),eo=mi(function(t,e){return ve(t,Se(e))}),no=ln(function(t,e,n){tu.call(t,n)?++t[n]:t[n]=1}),ro=xn(Nu),io=xn(Iu,!0),ao=En(ee,Nu),uo=En(ie,Iu),oo=ln(function(t,e,n){tu.call(t,n)?t[n].push(e):t[n]=[e]}),so=ln(function(t,e,n){t[n]=e}),co=mi(function(t,e,n){var r=-1,i="function"==typeof e,a=tr(e),u=Kn(t)?Ya(t.length):[];return Nu(t,function(t){var o=i?e:a&&null!=t?t[e]:E;u[++r]=o?o.apply(t,n):Zn(t,e,n)}),u}),lo=ln(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),ho=Fn(le,Nu),fo=Fn(he,Iu),po=mi(function(t,e){if(null==t)return[];var n=e[2];return n&&Jn(e[0],e[1],n)&&(e.length=1),Ke(t,Se(e),[])}),go=Au||function(){return(new Ua).getTime()},yo=mi(function(t,e,n){var r=M;if(n.length){var i=_(n,yo.placeholder);r|=B}return Pn(t,r,e,n,i)}),mo=mi(function(t,e){e=e.length?Se(e):Zi(t);for(var n=-1,r=e.length;++n0||0>e)?new K(n):(0>t?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==E&&(e=+e||0,n=0>e?n.dropRight(-e):n.take(e-t)),n)},K.prototype.takeRightWhile=function(t,e){return this.reverse().takeWhile(t,e).reverse()},K.prototype.toArray=function(){return this.take(Du)},Fe(K.prototype,function(t,n){var r=/^(?:filter|map|reject)|While$/.test(n),i=/^(?:first|last)$/.test(n),a=e[i?"take"+("last"==n?"Right":""):n];a&&(e.prototype[n]=function(){var e=i?[1]:arguments,n=this.__chain__,u=this.__wrapped__,o=!!this.__actions__.length,s=u instanceof K,c=e[0],l=s||So(u);l&&r&&"function"==typeof c&&1!=c.length&&(s=l=!1);var h=function(t){return i&&n?a(t,1)[0]:a.apply(E,ce([t],e))},f={func:zr,args:[h],thisArg:E},d=s&&!o;if(i&&!n)return d?(u=u.clone(),u.__actions__.push(f),t.call(u)):a.call(E,this.value())[0];if(!i&&l){u=d?u:new K(this);var p=t.apply(u,e);return p.__actions__.push(f),new v(p,n)}return this.thru(h)})}),ee(["join","pop","push","replace","shift","sort","splice","split","unshift"],function(t){var n=(/^(?:replace|split)$/.test(t)?Qa:Za)[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",i=/^(?:join|pop|replace|shift)$/.test(t);e.prototype[t]=function(){var t=arguments;return i&&!this.__chain__?n.apply(this.value(),t):this[r](function(e){return n.apply(e,t)})}}),Fe(K.prototype,function(t,n){var r=e[n];if(r){var i=r.name,a=Lu[i]||(Lu[i]=[]);a.push({name:n,func:r})}}),Lu[Bn(E,C).name]=[{name:"wrapper",func:E}],K.prototype.clone=et,K.prototype.reverse=rt,K.prototype.value=qt,e.prototype.chain=qr,e.prototype.commit=Wr,e.prototype.concat=to,e.prototype.plant=Gr,e.prototype.reverse=Hr,e.prototype.toString=Vr,e.prototype.run=e.prototype.toJSON=e.prototype.valueOf=e.prototype.value=Xr,e.prototype.collect=e.prototype.map,e.prototype.head=e.prototype.first,e.prototype.select=e.prototype.filter,e.prototype.tail=e.prototype.rest,e}var E,M="3.10.1",D=1,C=2,S=4,T=8,F=16,B=32,L=64,O=128,I=256,N=30,P="...",R=150,j=16,Y=200,U=1,$=2,z="Expected a function",q="__lodash_placeholder__",W="[object Arguments]",G="[object Array]",H="[object Boolean]",V="[object Date]",X="[object Error]",Z="[object Function]",K="[object Map]",Q="[object Number]",J="[object Object]",tt="[object RegExp]",et="[object Set]",nt="[object String]",rt="[object WeakMap]",it="[object ArrayBuffer]",at="[object Float32Array]",ut="[object Float64Array]",ot="[object Int8Array]",st="[object Int16Array]",ct="[object Int32Array]",lt="[object Uint8Array]",ht="[object Uint8ClampedArray]",ft="[object Uint16Array]",dt="[object Uint32Array]",pt=/\b__p \+= '';/g,gt=/\b(__p \+=) '' \+/g,yt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,mt=/&(?:amp|lt|gt|quot|#39|#96);/g,vt=/[&<>"'`]/g,_t=RegExp(mt.source),bt=RegExp(vt.source),xt=/<%-([\s\S]+?)%>/g,wt=/<%([\s\S]+?)%>/g,At=/<%=([\s\S]+?)%>/g,kt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\n\\]|\\.)*?\1)\]/,Et=/^\w*$/,Mt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g,Dt=/^[:!,]|[\\^$.*+?()[\]{}|\/]|(^[0-9a-fA-Fnrtuvx])|([\n\r\u2028\u2029])/g,Ct=RegExp(Dt.source),St=/[\u0300-\u036f\ufe20-\ufe23]/g,Tt=/\\(\\)?/g,Ft=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Bt=/\w*$/,Lt=/^0[xX]/,Ot=/^\[object .+?Constructor\]$/,It=/^\d+$/,Nt=/[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g,Pt=/($^)/,Rt=/['\n\r\u2028\u2029\\]/g,jt=function(){var t="[A-Z\\xc0-\\xd6\\xd8-\\xde]",e="[a-z\\xdf-\\xf6\\xf8-\\xff]+";return RegExp(t+"+(?="+t+e+")|"+t+"?"+e+"|"+t+"+|[0-9]+","g")}(),Yt=["Array","ArrayBuffer","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Math","Number","Object","RegExp","Set","String","_","clearTimeout","isFinite","parseFloat","parseInt","setTimeout","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap"],Ut=-1,$t={};$t[at]=$t[ut]=$t[ot]=$t[st]=$t[ct]=$t[lt]=$t[ht]=$t[ft]=$t[dt]=!0,$t[W]=$t[G]=$t[it]=$t[H]=$t[V]=$t[X]=$t[Z]=$t[K]=$t[Q]=$t[J]=$t[tt]=$t[et]=$t[nt]=$t[rt]=!1;var zt={};zt[W]=zt[G]=zt[it]=zt[H]=zt[V]=zt[at]=zt[ut]=zt[ot]=zt[st]=zt[ct]=zt[Q]=zt[J]=zt[tt]=zt[nt]=zt[lt]=zt[ht]=zt[ft]=zt[dt]=!0,zt[X]=zt[Z]=zt[K]=zt[et]=zt[rt]=!1;var qt={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss"},Wt={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},Gt={"&":"&","<":"<",">":">",""":'"',"'":"'","`":"`"},Ht={"function":!0,object:!0},Vt={0:"x30",1:"x31",2:"x32",3:"x33",4:"x34",5:"x35",6:"x36",7:"x37",8:"x38",9:"x39",A:"x41",B:"x42",C:"x43",D:"x44",E:"x45",F:"x46",a:"x61",b:"x62",c:"x63",d:"x64",e:"x65",f:"x66",n:"x6e",r:"x72",t:"x74",u:"x75",v:"x76",x:"x78"},Xt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Zt=Ht[typeof n]&&n&&!n.nodeType&&n,Kt=Ht[typeof e]&&e&&!e.nodeType&&e,Qt=Zt&&Kt&&"object"==typeof t&&t&&t.Object&&t,Jt=Ht[typeof self]&&self&&self.Object&&self,te=Ht[typeof window]&&window&&window.Object&&window,ee=Kt&&Kt.exports===Zt&&Zt,ne=Qt||te!==(this&&this.window)&&te||Jt||this,re=k();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(ne._=re,define(function(){return re})):Zt&&Kt?ee?(Kt.exports=re)._=re:Zt._=re:ne._=re}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],54:[function(t,e){e.exports={graphlib:t("./lib/graphlib"),layout:t("./lib/layout"),debug:t("./lib/debug"),util:{time:t("./lib/util").time,notime:t("./lib/util").notime},version:t("./lib/version")}},{"./lib/debug":59,"./lib/graphlib":60,"./lib/layout":62,"./lib/util":82,"./lib/version":83}],55:[function(t,e){"use strict";function n(t){function e(t){return function(e){return t.edge(e).weight}}var n="greedy"===t.graph().acyclicer?u(t,e(t)):r(t);a.each(n,function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,a.uniqueId("rev"))})}function r(t){function e(u){a.has(i,u)||(i[u]=!0,r[u]=!0,a.each(t.outEdges(u),function(t){a.has(r,t.w)?n.push(t):e(t.w)}),delete r[u])}var n=[],r={},i={};return a.each(t.nodes(),e),n}function i(t){a.each(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)}})}var a=t("./lodash"),u=t("./greedy-fas");e.exports={run:n,undo:i}},{"./greedy-fas":61,"./lodash":63}],56:[function(t,e){function n(t){function e(n){var a=t.children(n),u=t.node(n);if(a.length&&i.each(a,e),i.has(u,"minRank")){u.borderLeft=[],u.borderRight=[];for(var o=u.minRank,s=u.maxRank+1;s>o;++o)r(t,"borderLeft","_bl",n,u,o),r(t,"borderRight","_br",n,u,o)}}i.each(t.children(),e)}function r(t,e,n,r,i,u){var o={width:0,height:0,rank:u,borderType:e},s=i[e][u-1],c=a.addDummyNode(t,"border",o,n);i[e][u]=c,t.setParent(c,r),s&&t.setEdge(s,c,{weight:1})}var i=t("./lodash"),a=t("./util");e.exports=n},{"./lodash":63,"./util":82}],57:[function(t,e){"use strict";function n(t){var e=t.graph().rankdir.toLowerCase();("lr"===e||"rl"===e)&&i(t)}function r(t){var e=t.graph().rankdir.toLowerCase();("bt"===e||"rl"===e)&&u(t),("lr"===e||"rl"===e)&&(s(t),i(t))}function i(t){l.each(t.nodes(),function(e){a(t.node(e))}),l.each(t.edges(),function(e){a(t.edge(e))})}function a(t){var e=t.width;t.width=t.height,t.height=e}function u(t){l.each(t.nodes(),function(e){o(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,o),l.has(n,"y")&&o(n)})}function o(t){t.y=-t.y}function s(t){l.each(t.nodes(),function(e){c(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,c),l.has(n,"x")&&c(n)})}function c(t){var e=t.x;t.x=t.y,t.y=e}var l=t("./lodash");e.exports={adjust:n,undo:r}},{"./lodash":63}],58:[function(t,e){function n(){var t={};t._next=t._prev=t,this._sentinel=t}function r(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function i(t,e){return"_next"!==t&&"_prev"!==t?e:void 0}e.exports=n,n.prototype.dequeue=function(){var t=this._sentinel,e=t._prev;return e!==t?(r(e),e):void 0},n.prototype.enqueue=function(t){var e=this._sentinel;t._prev&&t._next&&r(t),t._next=e._next,e._next._prev=t,e._next=t,t._prev=e},n.prototype.toString=function(){for(var t=[],e=this._sentinel,n=e._prev;n!==e;)t.push(JSON.stringify(n,i)),n=n._prev;return"["+t.join(", ")+"]"}},{}],59:[function(t,e){function n(t){var e=i.buildLayerMatrix(t),n=new a({compound:!0,multigraph:!0}).setGraph({});return r.each(t.nodes(),function(e){n.setNode(e,{label:e}),n.setParent(e,"layer"+t.node(e).rank)}),r.each(t.edges(),function(t){n.setEdge(t.v,t.w,{},t.name)}),r.each(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}var r=t("./lodash"),i=t("./util"),a=t("./graphlib").Graph;e.exports={debugOrdering:n}},{"./graphlib":60,"./lodash":63,"./util":82}],60:[function(t,e){var n;if("function"==typeof t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:84}],61:[function(t,e){function n(t,e){if(t.nodeCount()<=1)return[];var n=a(t,e||l),i=r(n.graph,n.buckets,n.zeroIdx);return o.flatten(o.map(i,function(e){return t.outEdges(e.v,e.w)}),!0)}function r(t,e,n){for(var r,a=[],u=e[e.length-1],o=e[0];t.nodeCount();){for(;r=o.dequeue();)i(t,e,n,r);for(;r=u.dequeue();)i(t,e,n,r);if(t.nodeCount())for(var s=e.length-2;s>0;--s)if(r=e[s].dequeue()){a=a.concat(i(t,e,n,r,!0));break}}return a}function i(t,e,n,r,i){var a=i?[]:void 0;return o.each(t.inEdges(r.v),function(r){var o=t.edge(r),s=t.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,u(e,n,s)}),o.each(t.outEdges(r.v),function(r){var i=t.edge(r),a=r.w,o=t.node(a);o["in"]-=i,u(e,n,o)}),t.removeNode(r.v),a}function a(t,e){var n=new s,r=0,i=0;o.each(t.nodes(),function(t){n.setNode(t,{v:t,"in":0,out:0})}),o.each(t.edges(),function(t){var a=n.edge(t.v,t.w)||0,u=e(t),o=a+u;n.setEdge(t.v,t.w,o),i=Math.max(i,n.node(t.v).out+=u),r=Math.max(r,n.node(t.w)["in"]+=u)});var a=o.range(i+r+3).map(function(){return new c}),l=r+1;return o.each(n.nodes(),function(t){u(a,l,n.node(t))}),{graph:n,buckets:a,zeroIdx:l}}function u(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)}var o=t("./lodash"),s=t("./graphlib").Graph,c=t("./data/list");e.exports=n;var l=o.constant(1)},{"./data/list":58,"./graphlib":60,"./lodash":63}],62:[function(t,e){"use strict";function n(t,e){var n=e&&e.debugTiming?B.time:B.notime;n("layout",function(){var e=n(" buildLayoutGraph",function(){return a(t)});n(" runLayout",function(){r(e,n)}),n(" updateInputGraph",function(){i(t,e)})})}function r(t,e){e(" makeSpaceForEdgeLabels",function(){u(t)}),e(" removeSelfEdges",function(){g(t)}),e(" acyclic",function(){x.run(t)}),e(" nestingGraph.run",function(){D.run(t)}),e(" rank",function(){A(B.asNonCompoundGraph(t))}),e(" injectEdgeLabelProxies",function(){o(t)}),e(" removeEmptyRanks",function(){M(t)}),e(" nestingGraph.cleanup",function(){D.cleanup(t)}),e(" normalizeRanks",function(){k(t)}),e(" assignRankMinMax",function(){s(t)}),e(" removeEdgeLabelProxies",function(){c(t)}),e(" normalize.run",function(){w.run(t)}),e(" parentDummyChains",function(){E(t)}),e(" addBorderSegments",function(){C(t)}),e(" order",function(){T(t)}),e(" insertSelfEdges",function(){y(t)}),e(" adjustCoordinateSystem",function(){S.adjust(t)}),e(" position",function(){F(t)}),e(" positionSelfEdges",function(){m(t)}),e(" removeBorderNodes",function(){p(t)}),e(" normalize.undo",function(){w.undo(t)}),e(" fixupEdgeLabelCoords",function(){f(t)}),e(" undoCoordinateSystem",function(){S.undo(t)}),e(" translateGraph",function(){l(t)}),e(" assignNodeIntersects",function(){h(t)}),e(" reversePoints",function(){d(t)}),e(" acyclic.undo",function(){x.undo(t)})}function i(t,e){b.each(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))}),b.each(t.edges(),function(n){var r=t.edge(n),i=e.edge(n);r.points=i.points,b.has(i,"x")&&(r.x=i.x,r.y=i.y)}),t.graph().width=e.graph().width,t.graph().height=e.graph().height}function a(t){var e=new L({multigraph:!0,compound:!0}),n=_(t.graph());return e.setGraph(b.merge({},I,v(n,O),b.pick(n,N))),b.each(t.nodes(),function(n){var r=_(t.node(n));e.setNode(n,b.defaults(v(r,P),R)),e.setParent(n,t.parent(n))}),b.each(t.edges(),function(n){var r=_(t.edge(n));e.setEdge(n,b.merge({},Y,v(r,j),b.pick(r,U)))}),e}function u(t){var e=t.graph();e.ranksep/=2,b.each(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)})}function o(t){b.each(t.edges(),function(e){var n=t.edge(e);if(n.width&&n.height){var r=t.node(e.v),i=t.node(e.w),a={rank:(i.rank-r.rank)/2+r.rank,e:e};B.addDummyNode(t,"edge-proxy",a,"_ep")}})}function s(t){var e=0;b.each(t.nodes(),function(n){var r=t.node(n);r.borderTop&&(r.minRank=t.node(r.borderTop).rank,r.maxRank=t.node(r.borderBottom).rank,e=b.max(e,r.maxRank))}),t.graph().maxRank=e}function c(t){b.each(t.nodes(),function(e){var n=t.node(e);"edge-proxy"===n.dummy&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))})}function l(t){function e(t){var e=t.x,u=t.y,o=t.width,s=t.height;n=Math.min(n,e-o/2),r=Math.max(r,e+o/2),i=Math.min(i,u-s/2),a=Math.max(a,u+s/2)}var n=Number.POSITIVE_INFINITY,r=0,i=Number.POSITIVE_INFINITY,a=0,u=t.graph(),o=u.marginx||0,s=u.marginy||0;b.each(t.nodes(),function(n){e(t.node(n))}),b.each(t.edges(),function(n){var r=t.edge(n);b.has(r,"x")&&e(r)}),n-=o,i-=s,b.each(t.nodes(),function(e){var r=t.node(e);r.x-=n,r.y-=i}),b.each(t.edges(),function(e){var r=t.edge(e);b.each(r.points,function(t){t.x-=n,t.y-=i}),b.has(r,"x")&&(r.x-=n),b.has(r,"y")&&(r.y-=i)}),u.width=r-n+o,u.height=a-i+s}function h(t){b.each(t.edges(),function(e){var n,r,i=t.edge(e),a=t.node(e.v),u=t.node(e.w);i.points?(n=i.points[0],r=i.points[i.points.length-1]):(i.points=[],n=u,r=a),i.points.unshift(B.intersectRect(a,n)),i.points.push(B.intersectRect(u,r))})}function f(t){b.each(t.edges(),function(e){var n=t.edge(e);if(b.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}})}function d(t){b.each(t.edges(),function(e){var n=t.edge(e);n.reversed&&n.points.reverse()})}function p(t){b.each(t.nodes(),function(e){if(t.children(e).length){var n=t.node(e),r=t.node(n.borderTop),i=t.node(n.borderBottom),a=t.node(b.last(n.borderLeft)),u=t.node(b.last(n.borderRight));n.width=Math.abs(u.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),b.each(t.nodes(),function(e){"border"===t.node(e).dummy&&t.removeNode(e)})}function g(t){b.each(t.edges(),function(e){if(e.v===e.w){var n=t.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e:e,label:t.edge(e)}),t.removeEdge(e)}})}function y(t){var e=B.buildLayerMatrix(t);b.each(e,function(e){var n=0;b.each(e,function(e,r){var i=t.node(e);i.order=r+n,b.each(i.selfEdges,function(e){B.addDummyNode(t,"selfedge",{width:e.label.width,height:e.label.height,rank:i.rank,order:r+ ++n,e:e.e,label:e.label},"_se")}),delete i.selfEdges})})}function m(t){b.each(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,u=n.x-i,o=r.height/2;t.setEdge(n.e,n.label),t.removeNode(e),n.label.points=[{x:i+2*u/3,y:a-o},{x:i+5*u/6,y:a-o},{x:i+u,y:a},{x:i+5*u/6,y:a+o},{x:i+2*u/3,y:a+o}],n.label.x=n.x,n.label.y=n.y}})}function v(t,e){return b.mapValues(b.pick(t,e),Number)}function _(t){var e={};return b.each(t,function(t,n){e[n.toLowerCase()]=t}),e}var b=t("./lodash"),x=t("./acyclic"),w=t("./normalize"),A=t("./rank"),k=t("./util").normalizeRanks,E=t("./parent-dummy-chains"),M=t("./util").removeEmptyRanks,D=t("./nesting-graph"),C=t("./add-border-segments"),S=t("./coordinate-system"),T=t("./order"),F=t("./position"),B=t("./util"),L=t("./graphlib").Graph;e.exports=n;var O=["nodesep","edgesep","ranksep","marginx","marginy"],I={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},N=["acyclicer","ranker","rankdir","align"],P=["width","height"],R={width:0,height:0},j=["minlen","weight","width","height","labeloffset"],Y={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},U=["labelpos"]},{"./acyclic":55,"./add-border-segments":56,"./coordinate-system":57,"./graphlib":60,"./lodash":63,"./nesting-graph":64,"./normalize":65,"./order":70,"./parent-dummy-chains":75,"./position":77,"./rank":79,"./util":82}],63:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":51,lodash:104}],64:[function(t,e){function n(t){var e=s.addDummyNode(t,"root",{},"_root"),n=i(t),u=o.max(n)-1,c=2*u+1;t.graph().nestingRoot=e,o.each(t.edges(),function(e){t.edge(e).minlen*=c});var l=a(t)+1;o.each(t.children(),function(i){r(t,e,c,l,u,n,i)}),t.graph().nodeRankFactor=c}function r(t,e,n,i,a,u,c){var l=t.children(c);if(!l.length)return void(c!==e&&t.setEdge(e,c,{weight:0,minlen:n}));var h=s.addBorderNode(t,"_bt"),f=s.addBorderNode(t,"_bb"),d=t.node(c);t.setParent(h,c),d.borderTop=h,t.setParent(f,c),d.borderBottom=f,o.each(l,function(o){r(t,e,n,i,a,u,o);var s=t.node(o),l=s.borderTop?s.borderTop:o,d=s.borderBottom?s.borderBottom:o,p=s.borderTop?i:2*i,g=l!==d?1:a-u[c]+1;t.setEdge(h,l,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(d,f,{weight:p,minlen:g,nestingEdge:!0})}),t.parent(c)||t.setEdge(e,h,{weight:0,minlen:a+u[c]})}function i(t){function e(r,i){var a=t.children(r);a&&a.length&&o.each(a,function(t){e(t,i+1)}),n[r]=i}var n={};return o.each(t.children(),function(t){e(t,1)}),n}function a(t){return o.reduce(t.edges(),function(e,n){return e+t.edge(n).weight},0)}function u(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,o.each(t.edges(),function(e){var n=t.edge(e);n.nestingEdge&&t.removeEdge(e)})}var o=t("./lodash"),s=t("./util");e.exports={run:n,cleanup:u}},{"./lodash":63,"./util":82}],65:[function(t,e){"use strict";function n(t){t.graph().dummyChains=[],a.each(t.edges(),function(e){r(t,e)})}function r(t,e){var n=e.v,r=t.node(n).rank,i=e.w,a=t.node(i).rank,o=e.name,s=t.edge(e),c=s.labelRank;if(a!==r+1){t.removeEdge(e);var l,h,f;for(f=0,++r;a>r;++f,++r)s.points=[],h={width:0,height:0,edgeLabel:s,edgeObj:e,rank:r},l=u.addDummyNode(t,"edge",h,"_d"),r===c&&(h.width=s.width,h.height=s.height,h.dummy="edge-label",h.labelpos=s.labelpos),t.setEdge(n,l,{weight:s.weight},o),0===f&&t.graph().dummyChains.push(l),n=l;t.setEdge(n,i,{weight:s.weight},o)}}function i(t){a.each(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)})}var a=t("./lodash"),u=t("./util");e.exports={run:n,undo:i}},{"./lodash":63,"./util":82}],66:[function(t,e){function n(t,e,n){var i,a={};r.each(n,function(n){for(var r,u,o=t.parent(n);o;){if(r=t.parent(o),r?(u=a[r],a[r]=o):(u=i,i=o),u&&u!==o)return void e.setEdge(u,o);o=r}})}var r=t("../lodash");e.exports=n},{"../lodash":63}],67:[function(t,e){function n(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}})}var r=t("../lodash");e.exports=n},{"../lodash":63}],68:[function(t,e){function n(t,e,n){var u=r(t),o=new a({compound:!0}).setGraph({root:u}).setDefaultNodeLabel(function(e){return t.node(e)});return i.each(t.nodes(),function(r){var a=t.node(r),s=t.parent(r);(a.rank===e||a.minRank<=e&&e<=a.maxRank)&&(o.setNode(r),o.setParent(r,s||u),i.each(t[n](r),function(e){var n=e.v===r?e.w:e.v,a=o.edge(n,r),u=i.isUndefined(a)?0:a.weight;o.setEdge(n,r,{weight:t.edge(e).weight+u})}),i.has(a,"minRank")&&o.setNode(r,{borderLeft:a.borderLeft[e],borderRight:a.borderRight[e]}))}),o}function r(t){for(var e;t.hasNode(e=i.uniqueId("_root")););return e}var i=t("../lodash"),a=t("../graphlib").Graph;e.exports=n},{"../graphlib":60,"../lodash":63}],69:[function(t,e){"use strict";function n(t,e){for(var n=0,i=1;i0;)e%2&&(n+=s[e+1]),e=e-1>>1,s[e]+=t.weight;c+=t.weight*n})),c}var i=t("../lodash");e.exports=n},{"../lodash":63}],70:[function(t,e){"use strict";function n(t){var e=d.maxRank(t),n=r(t,u.range(1,e+1),"inEdges"),c=r(t,u.range(e-1,-1,-1),"outEdges"),l=o(t);a(t,l);for(var h,f=Number.POSITIVE_INFINITY,p=0,g=0;4>g;++p,++g){i(p%2?n:c,p%4>=2),l=d.buildLayerMatrix(t);var y=s(t,l);f>y&&(g=0,h=u.cloneDeep(l),f=y)}a(t,h)}function r(t,e,n){return u.map(e,function(e){return l(t,e,n)})}function i(t,e){var n=new f;u.each(t,function(t){var r=t.graph().root,i=c(t,r,n,e);u.each(i.vs,function(e,n){t.node(e).order=n}),h(t,n,i.vs)})}function a(t,e){u.each(e,function(e){u.each(e,function(e,n){t.node(e).order=n})})}var u=t("../lodash"),o=t("./init-order"),s=t("./cross-count"),c=t("./sort-subgraph"),l=t("./build-layer-graph"),h=t("./add-subgraph-constraints"),f=t("../graphlib").Graph,d=t("../util");e.exports=n},{"../graphlib":60,"../lodash":63,"../util":82,"./add-subgraph-constraints":66,"./build-layer-graph":68,"./cross-count":69,"./init-order":71,"./sort-subgraph":73}],71:[function(t,e){"use strict";function n(t){function e(i){if(!r.has(n,i)){n[i]=!0;var a=t.node(i);u[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})),u=r.map(r.range(a+1),function(){return[]}),o=r.sortBy(i,function(e){return t.node(e).rank});return r.each(o,e),u}var r=t("../lodash");e.exports=n},{"../lodash":63}],72:[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 u=t.pop();r.push(u),a.each(u["in"].reverse(),e(u)),a.each(u.out,n(u))}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":63}],73:[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=u(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=s(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"),u=t("./barycenter"),o=t("./resolve-conflicts"),s=t("./sort");e.exports=n},{"../lodash":63,"./barycenter":67,"./resolve-conflicts":72,"./sort":74}],74:[function(t,e){function n(t,e){var n=u.partition(t,function(t){return a.has(t,"barycenter")}),o=n.lhs,s=a.sortBy(n.rhs,function(t){return-t.i}),c=[],l=0,h=0,f=0;o.sort(i(!!e)),f=r(c,s,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,s,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.barycentern.barycenter?1:t?n.i-e.i:e.i-n.i}}var a=t("../lodash"),u=t("../util");e.exports=n},{"../lodash":63,"../util":82}],75:[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,u=r(t,e,a.v,a.w),o=u.path,s=u.lca,c=0,l=o[c],h=!0;n!==a.w;){if(i=t.node(n),h){for(;(l=o[c])!==s&&t.node(l).maxRanks||c>e[i].lim));for(a=i,i=r;(i=t.parent(i))!==a;)o.push(i);return{path:u.concat(o.reverse()),lca:a}}function i(t){function e(i){var u=r;a.each(t.children(i),e),n[i]={low:u,lim:r++}}var n={},r=0;return a.each(t.children(),e),n}var a=t("./lodash");e.exports=n},{"./lodash":63}],76:[function(t,e){"use strict";function n(t,e){function n(e,n){ -var u=0,o=0,s=e.length,c=y.last(n);return y.each(n,function(e,l){var h=i(t,e),f=h?t.node(h).order:s;(h||e===c)&&(y.each(n.slice(o,l+1),function(e){y.each(t.predecessors(e),function(n){var i=t.node(n),o=i.order;!(u>o||o>f)||i.dummy&&t.node(e).dummy||a(r,n,e)})}),o=l+1,u=f)}),n}var r={};return y.reduce(e,n),r}function r(t,e){function n(e,n,r,u,o){var s;y.each(y.range(n,r),function(n){s=e[n],t.node(s).dummy&&y.each(t.predecessors(s),function(e){var n=t.node(e);n.dummy&&(n.ordero)&&a(i,e,s)})})}function r(e,r){var i,a=-1,u=0;return y.each(r,function(o,s){if("border"===t.node(o).dummy){var c=t.predecessors(o);c.length&&(i=t.node(c[0]).order,n(r,u,s,a,i),u=s,a=i)}n(r,u,r.length,i,e.length)}),r}var i={};return y.reduce(e,r),i}function i(t,e){return t.node(e).dummy?y.find(t.predecessors(e),function(e){return t.node(e).dummy}):void 0}function a(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 r=e;e=n,n=r}return y.has(t[e],n)}function o(t,e,n,r){var i={},a={},o={};return y.each(e,function(t){y.each(t,function(t,e){i[t]=t,a[t]=t,o[t]=e})}),y.each(e,function(t){var e=-1;y.each(t,function(t){var s=r(t);if(s.length){s=y.sortBy(s,function(t){return o[t]});for(var c=(s.length-1)/2,l=Math.floor(c),h=Math.ceil(c);h>=l;++l){var f=s[l];a[t]===t&&eu.lim&&(o=u,s=!0);var c=p.filter(e.edges(),function(e){return s===d(t,t.node(e.v),o)&&s!==d(t,t.node(e.w),o)});return p.min(c,function(t){return y(e,t)})}function l(t,e,n,i){var a=n.v,o=n.w;t.removeEdge(a,o),t.setEdge(i.v,i.w,{}),u(t),r(t,e),h(t,e)}function h(t,e){var n=p.find(t.nodes(),function(t){return!e.node(t).parent}),r=v(t,n);r=r.slice(1),p.each(r,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)})}function f(t,e,n){return t.hasEdge(e,n)}function d(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}var p=t("../lodash"),g=t("./feasible-tree"),y=t("./util").slack,m=t("./util").longestPath,v=t("../graphlib").alg.preorder,_=t("../graphlib").alg.postorder,b=t("../util").simplify;e.exports=n,n.initLowLimValues=u,n.initCutValues=r,n.calcCutValue=a,n.leaveEdge=s,n.enterEdge=c,n.exchangeEdges=l},{"../graphlib":60,"../lodash":63,"../util":82,"./feasible-tree":78,"./util":81}],81:[function(t,e){"use strict";function n(t){function e(r){var a=t.node(r);if(i.has(n,r))return a.rank;n[r]=!0;var u=i.min(i.map(t.outEdges(r),function(n){return e(n.w)-t.edge(n).minlen}));return u===Number.POSITIVE_INFINITY&&(u=0),a.rank=u}var n={};i.each(t.sources(),e)}function r(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}var i=t("../lodash");e.exports={longestPath:n,slack:r}},{"../lodash":63}],82:[function(t,e){"use strict";function n(t,e,n,r){var i;do i=y.uniqueId(r);while(t.hasNode(i));return n.dummy=e,t.setNode(i,n),i}function r(t){var e=(new m).setGraph(t.graph());return y.each(t.nodes(),function(n){e.setNode(n,t.node(n))}),y.each(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}function i(t){var e=new m({multigraph:t.isMultigraph()}).setGraph(t.graph());return y.each(t.nodes(),function(n){t.children(n).length||e.setNode(n,t.node(n))}),y.each(t.edges(),function(n){e.setEdge(n,t.edge(n))}),e}function a(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.outEdges(e),function(e){n[e.w]=(n[e.w]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function u(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.inEdges(e),function(e){n[e.v]=(n[e.v]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function o(t,e){var n=t.x,r=t.y,i=e.x-n,a=e.y-r,u=t.width/2,o=t.height/2;if(!i&&!a)throw new Error("Not possible to find intersection inside of the rectangle");var s,c;return Math.abs(a)*u>Math.abs(i)*o?(0>a&&(o=-o),s=o*i/a,c=o):(0>i&&(u=-u),s=u,c=u*a/i),{x:n+s,y:r+c}}function s(t){var e=y.map(y.range(f(t)+1),function(){return[]});return y.each(t.nodes(),function(n){var r=t.node(n),i=r.rank;y.isUndefined(i)||(e[i][r.order]=n)}),e}function c(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank}));y.each(t.nodes(),function(n){var r=t.node(n);y.has(r,"rank")&&(r.rank-=e)})}function l(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank})),n=[];y.each(t.nodes(),function(r){var i=t.node(r).rank-e;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=t.graph().nodeRankFactor;y.each(n,function(e,n){y.isUndefined(e)&&n%i!==0?--r:r&&y.each(e,function(e){t.node(e).rank+=r})})}function h(t,e,r,i){var a={width:0,height:0};return arguments.length>=4&&(a.rank=r,a.order=i),n(t,"border",a,e)}function f(t){return y.max(y.map(t.nodes(),function(e){var n=t.node(e).rank;return y.isUndefined(n)?void 0:n}))}function d(t,e){var n={lhs:[],rhs:[]};return y.each(t,function(t){e(t)?n.lhs.push(t):n.rhs.push(t)}),n}function p(t,e){var n=y.now();try{return e()}finally{console.log(t+" time: "+(y.now()-n)+"ms")}}function g(t,e){return e()}var y=t("./lodash"),m=t("./graphlib").Graph;e.exports={addDummyNode:n,simplify:r,asNonCompoundGraph:i,successorWeights:a,predecessorWeights:u,intersectRect:o,buildLayerMatrix:s,normalizeRanks:c,removeEmptyRanks:l,addBorderNode:h,maxRank:f,partition:d,time:p,notime:g}},{"./graphlib":60,"./lodash":63}],83:[function(t,e){e.exports="0.7.4"},{}],84:[function(t,e){e.exports=t(33)},{"./lib":100,"./lib/alg":91,"./lib/json":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/index.js":33}],85:[function(t,e){e.exports=t(34)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/components.js":34}],86:[function(t,e){e.exports=t(35)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dfs.js":35}],87:[function(t,e){e.exports=t(36)},{"../lodash":102,"./dijkstra":88,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra-all.js":36}],88:[function(t,e){e.exports=t(37)},{"../data/priority-queue":98,"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra.js":37}],89:[function(t,e){e.exports=t(38)},{"../lodash":102,"./tarjan":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/find-cycles.js":38}],90:[function(t,e){e.exports=t(39)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/floyd-warshall.js":39}],91:[function(t,e){e.exports=t(40)},{"./components":85,"./dijkstra":88,"./dijkstra-all":87,"./find-cycles":89,"./floyd-warshall":90,"./is-acyclic":92,"./postorder":93,"./preorder":94,"./prim":95,"./tarjan":96,"./topsort":97,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/index.js":40}],92:[function(t,e){e.exports=t(41)},{"./topsort":97,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/is-acyclic.js":41}],93:[function(t,e){e.exports=t(42)},{"./dfs":86,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/postorder.js":42}],94:[function(t,e){e.exports=t(43)},{"./dfs":86,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/preorder.js":43}],95:[function(t,e){e.exports=t(44)},{"../data/priority-queue":98,"../graph":99,"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/prim.js":44}],96:[function(t,e){e.exports=t(45)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/tarjan.js":45}],97:[function(t,e){e.exports=t(46)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/topsort.js":46}],98:[function(t,e){e.exports=t(47)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/data/priority-queue.js":47}],99:[function(t,e){e.exports=t(48)},{"./lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/graph.js":48}],100:[function(t,e){e.exports=t(49)},{"./graph":99,"./version":103,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/index.js":49}],101:[function(t,e){e.exports=t(50)},{"./graph":99,"./lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/json.js":50}],102:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":51,lodash:104}],103:[function(t,e){e.exports=t(52)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/version.js":52}],104:[function(t,e){e.exports=t(53)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/lodash/index.js":53}],105:[function(t,e,n){!function(t,r){"object"==typeof n&&"undefined"!=typeof e?e.exports=r():"function"==typeof define&&define.amd?define(r):t.moment=r()}(this,function(){"use strict";function n(){return Nn.apply(null,arguments)}function r(t){Nn=t}function i(t){return"[object Array]"===Object.prototype.toString.call(t)}function a(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function u(t,e){var n,r=[];for(n=0;n0)for(n in Rn)r=Rn[n],i=e[r],"undefined"!=typeof i&&(t[r]=i);return t}function g(t){p(this,t),this._d=new Date(null!=t._d?t._d.getTime():0/0),jn===!1&&(jn=!0,n.updateOffset(this),jn=!1)}function y(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function m(t){return 0>t?Math.ceil(t):Math.floor(t)}function v(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=m(e)),n}function _(t,e,n){var r,i=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),u=0;for(r=0;i>r;r++)(n&&t[r]!==e[r]||!n&&v(t[r])!==v(e[r]))&&u++;return u+a}function b(){}function x(t){return t?t.toLowerCase().replace("_","-"):t}function w(t){for(var e,n,r,i,a=0;a0;){if(r=A(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&_(i,n,!0)>=e-1)break;e--}a++}return null}function A(n){var r=null;if(!Yn[n]&&"undefined"!=typeof e&&e&&e.exports)try{r=Pn._abbr,t("./locale/"+n),k(r)}catch(i){}return Yn[n]}function k(t,e){var n;return t&&(n="undefined"==typeof e?M(t):E(t,e),n&&(Pn=n)),Pn._abbr}function E(t,e){return null!==e?(e.abbr=t,Yn[t]=Yn[t]||new b,Yn[t].set(e),k(t),Yn[t]):(delete Yn[t],null)}function M(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Pn;if(!i(t)){if(e=A(t))return e;t=[t]}return w(t)}function D(t,e){var n=t.toLowerCase();Un[n]=Un[n+"s"]=Un[e]=t}function C(t){return"string"==typeof t?Un[t]||Un[t.toLowerCase()]:void 0}function S(t){var e,n,r={};for(n in t)o(t,n)&&(e=C(n),e&&(r[e]=t[n]));return r}function T(t,e){return function(r){return null!=r?(B(this,t,r),n.updateOffset(this,e),this):F(this,t)}}function F(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function B(t,e,n){return t._d["set"+(t._isUTC?"UTC":"")+e](n)}function L(t,e){var n;if("object"==typeof t)for(n in t)this.set(n,t[n]);else if(t=C(t),"function"==typeof this[t])return this[t](e);return this}function O(t,e,n){var r=""+Math.abs(t),i=e-r.length,a=t>=0;return(a?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}function I(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&(Wn[t]=i),e&&(Wn[e[0]]=function(){return O(i.apply(this,arguments),e[1],e[2])}),n&&(Wn[n]=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 P(t){var e,n,r=t.match($n);for(e=0,n=r.length;n>e;e++)r[e]=Wn[r[e]]?Wn[r[e]]:N(r[e]);return function(i){var a="";for(e=0;n>e;e++)a+=r[e]instanceof Function?r[e].call(i,t):r[e];return a}}function R(t,e){return t.isValid()?(e=j(e,t.localeData()),qn[e]=qn[e]||P(e),qn[e](t)):t.localeData().invalidDate()}function j(t,e){function n(t){return e.longDateFormat(t)||t}var r=5;for(zn.lastIndex=0;r>=0&&zn.test(t);)t=t.replace(zn,n),zn.lastIndex=0,r-=1;return t}function Y(t){return"function"==typeof t&&"[object Function]"===Object.prototype.toString.call(t)}function U(t,e,n){ur[t]=Y(e)?e:function(t){return t&&n?n:e}}function $(t,e){return o(ur,t)?ur[t](e._strict,e._locale):new RegExp(z(t))}function z(t){return t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,n,r,i){return e||n||r||i}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function q(t,e){var n,r=e;for("string"==typeof t&&(t=[t]),"number"==typeof e&&(r=function(t,n){n[e]=v(t)}),n=0;nr;r++){if(i=c([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(a="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(a.replace(".",""),"i")),n&&"MMMM"===e&&this._longMonthsParse[r].test(t))return r;if(n&&"MMM"===e&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}}function K(t,e){var n;return"string"==typeof e&&(e=t.localeData().monthsParse(e),"number"!=typeof e)?t:(n=Math.min(t.date(),H(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n),t)}function Q(t){return null!=t?(K(this,t),n.updateOffset(this,!0),this):F(this,"Month")}function J(){return H(this.year(),this.month())}function tt(t){var e,n=t._a;return n&&-2===h(t).overflow&&(e=n[cr]<0||n[cr]>11?cr:n[lr]<1||n[lr]>H(n[sr],n[cr])?lr:n[hr]<0||n[hr]>24||24===n[hr]&&(0!==n[fr]||0!==n[dr]||0!==n[pr])?hr:n[fr]<0||n[fr]>59?fr:n[dr]<0||n[dr]>59?dr:n[pr]<0||n[pr]>999?pr:-1,h(t)._overflowDayOfYear&&(sr>e||e>lr)&&(e=lr),h(t).overflow=e),t}function et(t){n.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function nt(t,e){var n=!0;return s(function(){return n&&(et(t+"\n"+(new Error).stack),n=!1),e.apply(this,arguments)},e)}function rt(t,e){mr[t]||(et(e),mr[t]=!0)}function it(t){var e,n,r=t._i,i=vr.exec(r);if(i){for(h(t).iso=!0,e=0,n=_r.length;n>e;e++)if(_r[e][1].exec(r)){t._f=_r[e][0];break}for(e=0,n=br.length;n>e;e++)if(br[e][1].exec(r)){t._f+=(i[6]||" ")+br[e][0];break}r.match(rr)&&(t._f+="Z"),At(t)}else t._isValid=!1}function at(t){var e=xr.exec(t._i);return null!==e?void(t._d=new Date(+e[1])):(it(t),void(t._isValid===!1&&(delete t._isValid,n.createFromInputFallback(t))))}function ut(t,e,n,r,i,a,u){var o=new Date(t,e,n,r,i,a,u);return 1970>t&&o.setFullYear(t),o}function ot(t){var e=new Date(Date.UTC.apply(null,arguments));return 1970>t&&e.setUTCFullYear(t),e}function st(t){return ct(t)?366:365}function ct(t){return t%4===0&&t%100!==0||t%400===0}function lt(){return ct(this.year())}function ht(t,e,n){var r,i=n-e,a=n-t.day();return a>i&&(a-=7),i-7>a&&(a+=7),r=Ft(t).add(a,"d"),{week:Math.ceil(r.dayOfYear()/7),year:r.year()}}function ft(t){return ht(t,this._week.dow,this._week.doy).week}function dt(){return this._week.dow}function pt(){return this._week.doy}function gt(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")}function yt(t){var e=ht(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")}function mt(t,e,n,r,i){var a,u=6+i-r,o=ot(t,0,1+u),s=o.getUTCDay();return i>s&&(s+=7),n=null!=n?1*n:i,a=1+u+7*(e-1)-s+n,{year:a>0?t:t-1,dayOfYear:a>0?a:st(t-1)+a}}function vt(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")}function _t(t,e,n){return null!=t?t:null!=e?e:n}function bt(t){var e=new Date;return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function xt(t){var e,n,r,i,a=[];if(!t._d){for(r=bt(t),t._w&&null==t._a[lr]&&null==t._a[cr]&&wt(t),t._dayOfYear&&(i=_t(t._a[sr],r[sr]),t._dayOfYear>st(i)&&(h(t)._overflowDayOfYear=!0),n=ot(i,0,t._dayOfYear),t._a[cr]=n.getUTCMonth(),t._a[lr]=n.getUTCDate()),e=0;3>e&&null==t._a[e];++e)t._a[e]=a[e]=r[e];for(;7>e;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[hr]&&0===t._a[fr]&&0===t._a[dr]&&0===t._a[pr]&&(t._nextDay=!0,t._a[hr]=0),t._d=(t._useUTC?ot:ut).apply(null,a),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[hr]=24)}}function wt(t){var e,n,r,i,a,u,o;e=t._w,null!=e.GG||null!=e.W||null!=e.E?(a=1,u=4,n=_t(e.GG,t._a[sr],ht(Ft(),1,4).year),r=_t(e.W,1),i=_t(e.E,1)):(a=t._locale._week.dow,u=t._locale._week.doy,n=_t(e.gg,t._a[sr],ht(Ft(),a,u).year),r=_t(e.w,1),null!=e.d?(i=e.d,a>i&&++r):i=null!=e.e?e.e+a:a),o=mt(n,r,i,u,a),t._a[sr]=o.year,t._dayOfYear=o.dayOfYear}function At(t){if(t._f===n.ISO_8601)return void it(t);t._a=[],h(t).empty=!0;var e,r,i,a,u,o=""+t._i,s=o.length,c=0;for(i=j(t._f,t._locale).match($n)||[],e=0;e0&&h(t).unusedInput.push(u),o=o.slice(o.indexOf(r)+r.length),c+=r.length),Wn[a]?(r?h(t).empty=!1:h(t).unusedTokens.push(a),G(a,r,t)):t._strict&&!r&&h(t).unusedTokens.push(a);h(t).charsLeftOver=s-c,o.length>0&&h(t).unusedInput.push(o),h(t).bigHour===!0&&t._a[hr]<=12&&t._a[hr]>0&&(h(t).bigHour=void 0),t._a[hr]=kt(t._locale,t._a[hr],t._meridiem),xt(t),tt(t)}function kt(t,e,n){var r;return null==n?e:null!=t.meridiemHour?t.meridiemHour(e,n):null!=t.isPM?(r=t.isPM(n),r&&12>e&&(e+=12),r||12!==e||(e=0),e):e}function Et(t){var e,n,r,i,a;if(0===t._f.length)return h(t).invalidFormat=!0,void(t._d=new Date(0/0));for(i=0;ia)&&(r=a,n=e));s(t,n||e)}function Mt(t){if(!t._d){var e=S(t._i);t._a=[e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],xt(t)}}function Dt(t){var e=new g(tt(Ct(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=void 0),e}function Ct(t){var e=t._i,n=t._f;return t._locale=t._locale||M(t._l),null===e||void 0===n&&""===e?d({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),y(e)?new g(tt(e)):(i(n)?Et(t):n?At(t):a(e)?t._d=e:St(t),t))}function St(t){var e=t._i;void 0===e?t._d=new Date:a(e)?t._d=new Date(+e):"string"==typeof e?at(t):i(e)?(t._a=u(e.slice(0),function(t){return parseInt(t,10)}),xt(t)):"object"==typeof e?Mt(t):"number"==typeof e?t._d=new Date(e):n.createFromInputFallback(t)}function Tt(t,e,n,r,i){var a={};return"boolean"==typeof n&&(r=n,n=void 0),a._isAMomentObject=!0,a._useUTC=a._isUTC=i,a._l=n,a._i=t,a._f=e,a._strict=r,Dt(a)}function Ft(t,e,n,r){return Tt(t,e,n,r,!1)}function Bt(t,e){var n,r;if(1===e.length&&i(e[0])&&(e=e[0]),!e.length)return Ft();for(n=e[0],r=1;rt&&(t=-t,n="-"),n+O(~~(t/60),2)+e+O(~~t%60,2)})}function Rt(t){var e=(t||"").match(rr)||[],n=e[e.length-1]||[],r=(n+"").match(Mr)||["-",0,0],i=+(60*r[1])+v(r[2]);return"+"===r[0]?i:-i}function jt(t,e){var r,i;return e._isUTC?(r=e.clone(),i=(y(t)||a(t)?+t:+Ft(t))-+r,r._d.setTime(+r._d+i),n.updateOffset(r,!1),r):Ft(t).local()}function Yt(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function Ut(t,e){var r,i=this._offset||0;return null!=t?("string"==typeof t&&(t=Rt(t)),Math.abs(t)<16&&(t=60*t),!this._isUTC&&e&&(r=Yt(this)),this._offset=t,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==t&&(!e||this._changeInProgress?re(this,Qt(t-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?i:Yt(this)}function $t(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function zt(t){return this.utcOffset(0,t)}function qt(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(Yt(this),"m")),this}function Wt(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(Rt(this._i)),this}function Gt(t){return t=t?Ft(t).utcOffset():0,(this.utcOffset()-t)%60===0}function Ht(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Vt(){if("undefined"!=typeof this._isDSTShifted)return this._isDSTShifted;var t={};if(p(t,this),t=Ct(t),t._a){var e=t._isUTC?c(t._a):Ft(t._a);this._isDSTShifted=this.isValid()&&_(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Xt(){return!this._isUTC}function Zt(){return this._isUTC}function Kt(){return this._isUTC&&0===this._offset}function Qt(t,e){var n,r,i,a=t,u=null;return Nt(t)?a={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(a={},e?a[e]=t:a.milliseconds=t):(u=Dr.exec(t))?(n="-"===u[1]?-1:1,a={y:0,d:v(u[lr])*n,h:v(u[hr])*n,m:v(u[fr])*n,s:v(u[dr])*n,ms:v(u[pr])*n}):(u=Cr.exec(t))?(n="-"===u[1]?-1:1,a={y:Jt(u[2],n),M:Jt(u[3],n),d:Jt(u[4],n),h:Jt(u[5],n),m:Jt(u[6],n),s:Jt(u[7],n),w:Jt(u[8],n)}):null==a?a={}:"object"==typeof a&&("from"in a||"to"in a)&&(i=ee(Ft(a.from),Ft(a.to)),a={},a.ms=i.milliseconds,a.M=i.months),r=new It(a),Nt(t)&&o(t,"_locale")&&(r._locale=t._locale),r}function Jt(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function te(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 ee(t,e){var n;return e=jt(e,t),t.isBefore(e)?n=te(t,e):(n=te(e,t),n.milliseconds=-n.milliseconds,n.months=-n.months),n}function ne(t,e){return function(n,r){var i,a;return null===r||isNaN(+r)||(rt(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=Qt(n,r),re(this,i,t),this}}function re(t,e,r,i){var a=e._milliseconds,u=e._days,o=e._months;i=null==i?!0:i,a&&t._d.setTime(+t._d+a*r),u&&B(t,"Date",F(t,"Date")+u*r),o&&K(t,F(t,"Month")+o*r),i&&n.updateOffset(t,u||o)}function ie(t,e){var n=t||Ft(),r=jt(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,Ft(n)))}function ae(){return new g(this)}function ue(t,e){var n;return e=C("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Ft(t),+this>+t):(n=y(t)?+t:+Ft(t),n<+this.clone().startOf(e))}function oe(t,e){var n;return e=C("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Ft(t),+t>+this):(n=y(t)?+t:+Ft(t),+this.clone().endOf(e)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 fe(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function de(){var t=this.clone().utc();return 00||0>e)?new K(n):(0>t?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==E&&(e=+e||0,n=0>e?n.dropRight(-e):n.take(e-t)),n)},K.prototype.takeRightWhile=function(t,e){return this.reverse().takeWhile(t,e).reverse()},K.prototype.toArray=function(){return this.take(Mu)},Fe(K.prototype,function(t,n){var r=/^(?:filter|map|reject)|While$/.test(n),i=/^(?:first|last)$/.test(n),a=e[i?"take"+("last"==n?"Right":""):n];a&&(e.prototype[n]=function(){var e=i?[1]:arguments,n=this.__chain__,u=this.__wrapped__,o=!!this.__actions__.length,s=u instanceof K,c=e[0],l=s||So(u);l&&r&&"function"==typeof c&&1!=c.length&&(s=l=!1);var h=function(t){return i&&n?a(t,1)[0]:a.apply(E,ce([t],e))},f={func:zr,args:[h],thisArg:E},d=s&&!o;if(i&&!n)return d?(u=u.clone(),u.__actions__.push(f),t.call(u)):a.call(E,this.value())[0];if(!i&&l){u=d?u:new K(this);var p=t.apply(u,e);return p.__actions__.push(f),new v(p,n)}return this.thru(h)})}),ee(["join","pop","push","replace","shift","sort","splice","split","unshift"],function(t){var n=(/^(?:replace|split)$/.test(t)?Qa:Za)[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",i=/^(?:join|pop|replace|shift)$/.test(t);e.prototype[t]=function(){var t=arguments;return i&&!this.__chain__?n.apply(this.value(),t):this[r](function(e){return n.apply(e,t)})}}),Fe(K.prototype,function(t,n){var r=e[n];if(r){var i=r.name,a=Lu[i]||(Lu[i]=[]);a.push({name:n,func:r})}}),Lu[Bn(E,C).name]=[{name:"wrapper",func:E}],K.prototype.clone=et,K.prototype.reverse=rt,K.prototype.value=qt,e.prototype.chain=qr,e.prototype.commit=Wr,e.prototype.concat=to,e.prototype.plant=Gr,e.prototype.reverse=Hr,e.prototype.toString=Vr,e.prototype.run=e.prototype.toJSON=e.prototype.valueOf=e.prototype.value=Xr,e.prototype.collect=e.prototype.map,e.prototype.head=e.prototype.first,e.prototype.select=e.prototype.filter,e.prototype.tail=e.prototype.rest,e}var E,D="3.10.1",M=1,C=2,S=4,T=8,F=16,B=32,L=64,O=128,N=256,I=30,P="...",R=150,j=16,Y=200,U=1,$=2,z="Expected a function",q="__lodash_placeholder__",W="[object Arguments]",G="[object Array]",H="[object Boolean]",V="[object Date]",X="[object Error]",Z="[object Function]",K="[object Map]",Q="[object Number]",J="[object Object]",tt="[object RegExp]",et="[object Set]",nt="[object String]",rt="[object WeakMap]",it="[object ArrayBuffer]",at="[object Float32Array]",ut="[object Float64Array]",ot="[object Int8Array]",st="[object Int16Array]",ct="[object Int32Array]",lt="[object Uint8Array]",ht="[object Uint8ClampedArray]",ft="[object Uint16Array]",dt="[object Uint32Array]",pt=/\b__p \+= '';/g,gt=/\b(__p \+=) '' \+/g,yt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,mt=/&(?:amp|lt|gt|quot|#39|#96);/g,vt=/[&<>"'`]/g,_t=RegExp(mt.source),bt=RegExp(vt.source),xt=/<%-([\s\S]+?)%>/g,wt=/<%([\s\S]+?)%>/g,At=/<%=([\s\S]+?)%>/g,kt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\n\\]|\\.)*?\1)\]/,Et=/^\w*$/,Dt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g,Mt=/^[:!,]|[\\^$.*+?()[\]{}|\/]|(^[0-9a-fA-Fnrtuvx])|([\n\r\u2028\u2029])/g,Ct=RegExp(Mt.source),St=/[\u0300-\u036f\ufe20-\ufe23]/g,Tt=/\\(\\)?/g,Ft=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Bt=/\w*$/,Lt=/^0[xX]/,Ot=/^\[object .+?Constructor\]$/,Nt=/^\d+$/,It=/[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g,Pt=/($^)/,Rt=/['\n\r\u2028\u2029\\]/g,jt=function(){var t="[A-Z\\xc0-\\xd6\\xd8-\\xde]",e="[a-z\\xdf-\\xf6\\xf8-\\xff]+";return RegExp(t+"+(?="+t+e+")|"+t+"?"+e+"|"+t+"+|[0-9]+","g")}(),Yt=["Array","ArrayBuffer","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Math","Number","Object","RegExp","Set","String","_","clearTimeout","isFinite","parseFloat","parseInt","setTimeout","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap"],Ut=-1,$t={};$t[at]=$t[ut]=$t[ot]=$t[st]=$t[ct]=$t[lt]=$t[ht]=$t[ft]=$t[dt]=!0,$t[W]=$t[G]=$t[it]=$t[H]=$t[V]=$t[X]=$t[Z]=$t[K]=$t[Q]=$t[J]=$t[tt]=$t[et]=$t[nt]=$t[rt]=!1;var zt={};zt[W]=zt[G]=zt[it]=zt[H]=zt[V]=zt[at]=zt[ut]=zt[ot]=zt[st]=zt[ct]=zt[Q]=zt[J]=zt[tt]=zt[nt]=zt[lt]=zt[ht]=zt[ft]=zt[dt]=!0,zt[X]=zt[Z]=zt[K]=zt[et]=zt[rt]=!1;var qt={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss"},Wt={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},Gt={"&":"&","<":"<",">":">",""":'"',"'":"'","`":"`"},Ht={"function":!0,object:!0},Vt={0:"x30",1:"x31",2:"x32",3:"x33",4:"x34",5:"x35",6:"x36",7:"x37",8:"x38",9:"x39",A:"x41",B:"x42",C:"x43",D:"x44",E:"x45",F:"x46",a:"x61",b:"x62",c:"x63",d:"x64",e:"x65",f:"x66",n:"x6e",r:"x72",t:"x74",u:"x75",v:"x76",x:"x78"},Xt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Zt=Ht[typeof n]&&n&&!n.nodeType&&n,Kt=Ht[typeof e]&&e&&!e.nodeType&&e,Qt=Zt&&Kt&&"object"==typeof t&&t&&t.Object&&t,Jt=Ht[typeof self]&&self&&self.Object&&self,te=Ht[typeof window]&&window&&window.Object&&window,ee=Kt&&Kt.exports===Zt&&Zt,ne=Qt||te!==(this&&this.window)&&te||Jt||this,re=k();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(ne._=re,define(function(){return re})):Zt&&Kt?ee?(Kt.exports=re)._=re:Zt._=re:ne._=re}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],54:[function(t,e){e.exports={graphlib:t("./lib/graphlib"),layout:t("./lib/layout"),debug:t("./lib/debug"),util:{time:t("./lib/util").time,notime:t("./lib/util").notime},version:t("./lib/version")}},{"./lib/debug":59,"./lib/graphlib":60,"./lib/layout":62,"./lib/util":82,"./lib/version":83}],55:[function(t,e){"use strict";function n(t){function e(t){return function(e){return t.edge(e).weight}}var n="greedy"===t.graph().acyclicer?u(t,e(t)):r(t);a.each(n,function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,a.uniqueId("rev"))})}function r(t){function e(u){a.has(i,u)||(i[u]=!0,r[u]=!0,a.each(t.outEdges(u),function(t){a.has(r,t.w)?n.push(t):e(t.w)}),delete r[u])}var n=[],r={},i={};return a.each(t.nodes(),e),n}function i(t){a.each(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)}})}var a=t("./lodash"),u=t("./greedy-fas");e.exports={run:n,undo:i}},{"./greedy-fas":61,"./lodash":63}],56:[function(t,e){function n(t){function e(n){var a=t.children(n),u=t.node(n);if(a.length&&i.each(a,e),i.has(u,"minRank")){u.borderLeft=[],u.borderRight=[];for(var o=u.minRank,s=u.maxRank+1;s>o;++o)r(t,"borderLeft","_bl",n,u,o),r(t,"borderRight","_br",n,u,o)}}i.each(t.children(),e)}function r(t,e,n,r,i,u){var o={width:0,height:0,rank:u,borderType:e},s=i[e][u-1],c=a.addDummyNode(t,"border",o,n);i[e][u]=c,t.setParent(c,r),s&&t.setEdge(s,c,{weight:1})}var i=t("./lodash"),a=t("./util");e.exports=n},{"./lodash":63,"./util":82}],57:[function(t,e){"use strict";function n(t){var e=t.graph().rankdir.toLowerCase();("lr"===e||"rl"===e)&&i(t)}function r(t){var e=t.graph().rankdir.toLowerCase();("bt"===e||"rl"===e)&&u(t),("lr"===e||"rl"===e)&&(s(t),i(t))}function i(t){l.each(t.nodes(),function(e){a(t.node(e))}),l.each(t.edges(),function(e){a(t.edge(e))})}function a(t){var e=t.width;t.width=t.height,t.height=e}function u(t){l.each(t.nodes(),function(e){o(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,o),l.has(n,"y")&&o(n)})}function o(t){t.y=-t.y}function s(t){l.each(t.nodes(),function(e){c(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,c),l.has(n,"x")&&c(n)})}function c(t){var e=t.x;t.x=t.y,t.y=e}var l=t("./lodash");e.exports={adjust:n,undo:r}},{"./lodash":63}],58:[function(t,e){function n(){var t={};t._next=t._prev=t,this._sentinel=t}function r(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function i(t,e){return"_next"!==t&&"_prev"!==t?e:void 0}e.exports=n,n.prototype.dequeue=function(){var t=this._sentinel,e=t._prev;return e!==t?(r(e),e):void 0},n.prototype.enqueue=function(t){var e=this._sentinel;t._prev&&t._next&&r(t),t._next=e._next,e._next._prev=t,e._next=t,t._prev=e},n.prototype.toString=function(){for(var t=[],e=this._sentinel,n=e._prev;n!==e;)t.push(JSON.stringify(n,i)),n=n._prev;return"["+t.join(", ")+"]"}},{}],59:[function(t,e){function n(t){var e=i.buildLayerMatrix(t),n=new a({compound:!0,multigraph:!0}).setGraph({});return r.each(t.nodes(),function(e){n.setNode(e,{label:e}),n.setParent(e,"layer"+t.node(e).rank)}),r.each(t.edges(),function(t){n.setEdge(t.v,t.w,{},t.name)}),r.each(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}var r=t("./lodash"),i=t("./util"),a=t("./graphlib").Graph;e.exports={debugOrdering:n}},{"./graphlib":60,"./lodash":63,"./util":82}],60:[function(t,e){var n;if("function"==typeof t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:84}],61:[function(t,e){function n(t,e){if(t.nodeCount()<=1)return[];var n=a(t,e||l),i=r(n.graph,n.buckets,n.zeroIdx);return o.flatten(o.map(i,function(e){return t.outEdges(e.v,e.w)}),!0)}function r(t,e,n){for(var r,a=[],u=e[e.length-1],o=e[0];t.nodeCount();){for(;r=o.dequeue();)i(t,e,n,r);for(;r=u.dequeue();)i(t,e,n,r);if(t.nodeCount())for(var s=e.length-2;s>0;--s)if(r=e[s].dequeue()){a=a.concat(i(t,e,n,r,!0));break}}return a}function i(t,e,n,r,i){var a=i?[]:void 0;return o.each(t.inEdges(r.v),function(r){var o=t.edge(r),s=t.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,u(e,n,s)}),o.each(t.outEdges(r.v),function(r){var i=t.edge(r),a=r.w,o=t.node(a);o["in"]-=i,u(e,n,o)}),t.removeNode(r.v),a}function a(t,e){var n=new s,r=0,i=0;o.each(t.nodes(),function(t){n.setNode(t,{v:t,"in":0,out:0})}),o.each(t.edges(),function(t){var a=n.edge(t.v,t.w)||0,u=e(t),o=a+u;n.setEdge(t.v,t.w,o),i=Math.max(i,n.node(t.v).out+=u),r=Math.max(r,n.node(t.w)["in"]+=u)});var a=o.range(i+r+3).map(function(){return new c}),l=r+1;return o.each(n.nodes(),function(t){u(a,l,n.node(t))}),{graph:n,buckets:a,zeroIdx:l}}function u(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)}var o=t("./lodash"),s=t("./graphlib").Graph,c=t("./data/list");e.exports=n;var l=o.constant(1)},{"./data/list":58,"./graphlib":60,"./lodash":63}],62:[function(t,e){"use strict";function n(t,e){var n=e&&e.debugTiming?B.time:B.notime;n("layout",function(){var e=n(" buildLayoutGraph",function(){return a(t)});n(" runLayout",function(){r(e,n)}),n(" updateInputGraph",function(){i(t,e)})})}function r(t,e){e(" makeSpaceForEdgeLabels",function(){u(t)}),e(" removeSelfEdges",function(){g(t)}),e(" acyclic",function(){x.run(t)}),e(" nestingGraph.run",function(){M.run(t)}),e(" rank",function(){A(B.asNonCompoundGraph(t))}),e(" injectEdgeLabelProxies",function(){o(t)}),e(" removeEmptyRanks",function(){D(t)}),e(" nestingGraph.cleanup",function(){M.cleanup(t)}),e(" normalizeRanks",function(){k(t)}),e(" assignRankMinMax",function(){s(t)}),e(" removeEdgeLabelProxies",function(){c(t)}),e(" normalize.run",function(){w.run(t)}),e(" parentDummyChains",function(){E(t)}),e(" addBorderSegments",function(){C(t)}),e(" order",function(){T(t)}),e(" insertSelfEdges",function(){y(t)}),e(" adjustCoordinateSystem",function(){S.adjust(t)}),e(" position",function(){F(t)}),e(" positionSelfEdges",function(){m(t)}),e(" removeBorderNodes",function(){p(t)}),e(" normalize.undo",function(){w.undo(t)}),e(" fixupEdgeLabelCoords",function(){f(t)}),e(" undoCoordinateSystem",function(){S.undo(t)}),e(" translateGraph",function(){l(t)}),e(" assignNodeIntersects",function(){h(t)}),e(" reversePoints",function(){d(t)}),e(" acyclic.undo",function(){x.undo(t)})}function i(t,e){b.each(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))}),b.each(t.edges(),function(n){var r=t.edge(n),i=e.edge(n);r.points=i.points,b.has(i,"x")&&(r.x=i.x,r.y=i.y)}),t.graph().width=e.graph().width,t.graph().height=e.graph().height}function a(t){var e=new L({multigraph:!0,compound:!0}),n=_(t.graph());return e.setGraph(b.merge({},N,v(n,O),b.pick(n,I))),b.each(t.nodes(),function(n){var r=_(t.node(n));e.setNode(n,b.defaults(v(r,P),R)),e.setParent(n,t.parent(n))}),b.each(t.edges(),function(n){var r=_(t.edge(n));e.setEdge(n,b.merge({},Y,v(r,j),b.pick(r,U)))}),e}function u(t){var e=t.graph();e.ranksep/=2,b.each(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)})}function o(t){b.each(t.edges(),function(e){var n=t.edge(e);if(n.width&&n.height){var r=t.node(e.v),i=t.node(e.w),a={rank:(i.rank-r.rank)/2+r.rank,e:e};B.addDummyNode(t,"edge-proxy",a,"_ep")}})}function s(t){var e=0;b.each(t.nodes(),function(n){var r=t.node(n);r.borderTop&&(r.minRank=t.node(r.borderTop).rank,r.maxRank=t.node(r.borderBottom).rank,e=b.max(e,r.maxRank))}),t.graph().maxRank=e}function c(t){b.each(t.nodes(),function(e){var n=t.node(e);"edge-proxy"===n.dummy&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))})}function l(t){function e(t){var e=t.x,u=t.y,o=t.width,s=t.height;n=Math.min(n,e-o/2),r=Math.max(r,e+o/2),i=Math.min(i,u-s/2),a=Math.max(a,u+s/2)}var n=Number.POSITIVE_INFINITY,r=0,i=Number.POSITIVE_INFINITY,a=0,u=t.graph(),o=u.marginx||0,s=u.marginy||0;b.each(t.nodes(),function(n){e(t.node(n))}),b.each(t.edges(),function(n){var r=t.edge(n);b.has(r,"x")&&e(r)}),n-=o,i-=s,b.each(t.nodes(),function(e){var r=t.node(e);r.x-=n,r.y-=i}),b.each(t.edges(),function(e){var r=t.edge(e);b.each(r.points,function(t){t.x-=n,t.y-=i}),b.has(r,"x")&&(r.x-=n),b.has(r,"y")&&(r.y-=i)}),u.width=r-n+o,u.height=a-i+s}function h(t){b.each(t.edges(),function(e){var n,r,i=t.edge(e),a=t.node(e.v),u=t.node(e.w);i.points?(n=i.points[0],r=i.points[i.points.length-1]):(i.points=[],n=u,r=a),i.points.unshift(B.intersectRect(a,n)),i.points.push(B.intersectRect(u,r))})}function f(t){b.each(t.edges(),function(e){var n=t.edge(e);if(b.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}})}function d(t){b.each(t.edges(),function(e){var n=t.edge(e);n.reversed&&n.points.reverse()})}function p(t){b.each(t.nodes(),function(e){if(t.children(e).length){var n=t.node(e),r=t.node(n.borderTop),i=t.node(n.borderBottom),a=t.node(b.last(n.borderLeft)),u=t.node(b.last(n.borderRight));n.width=Math.abs(u.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),b.each(t.nodes(),function(e){"border"===t.node(e).dummy&&t.removeNode(e)})}function g(t){b.each(t.edges(),function(e){if(e.v===e.w){var n=t.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e:e,label:t.edge(e)}),t.removeEdge(e)}})}function y(t){var e=B.buildLayerMatrix(t);b.each(e,function(e){var n=0;b.each(e,function(e,r){var i=t.node(e);i.order=r+n,b.each(i.selfEdges,function(e){B.addDummyNode(t,"selfedge",{width:e.label.width,height:e.label.height,rank:i.rank,order:r+ ++n,e:e.e,label:e.label},"_se")}),delete i.selfEdges})})}function m(t){b.each(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,u=n.x-i,o=r.height/2;t.setEdge(n.e,n.label),t.removeNode(e),n.label.points=[{x:i+2*u/3,y:a-o},{x:i+5*u/6,y:a-o},{x:i+u,y:a},{x:i+5*u/6,y:a+o},{x:i+2*u/3,y:a+o}],n.label.x=n.x,n.label.y=n.y}})}function v(t,e){return b.mapValues(b.pick(t,e),Number)}function _(t){var e={};return b.each(t,function(t,n){e[n.toLowerCase()]=t}),e}var b=t("./lodash"),x=t("./acyclic"),w=t("./normalize"),A=t("./rank"),k=t("./util").normalizeRanks,E=t("./parent-dummy-chains"),D=t("./util").removeEmptyRanks,M=t("./nesting-graph"),C=t("./add-border-segments"),S=t("./coordinate-system"),T=t("./order"),F=t("./position"),B=t("./util"),L=t("./graphlib").Graph;e.exports=n;var O=["nodesep","edgesep","ranksep","marginx","marginy"],N={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},I=["acyclicer","ranker","rankdir","align"],P=["width","height"],R={width:0,height:0},j=["minlen","weight","width","height","labeloffset"],Y={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},U=["labelpos"]},{"./acyclic":55,"./add-border-segments":56,"./coordinate-system":57,"./graphlib":60,"./lodash":63,"./nesting-graph":64,"./normalize":65,"./order":70,"./parent-dummy-chains":75,"./position":77,"./rank":79,"./util":82}],63:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":51,lodash:104}],64:[function(t,e){function n(t){var e=s.addDummyNode(t,"root",{},"_root"),n=i(t),u=o.max(n)-1,c=2*u+1;t.graph().nestingRoot=e,o.each(t.edges(),function(e){t.edge(e).minlen*=c});var l=a(t)+1;o.each(t.children(),function(i){r(t,e,c,l,u,n,i)}),t.graph().nodeRankFactor=c}function r(t,e,n,i,a,u,c){var l=t.children(c);if(!l.length)return void(c!==e&&t.setEdge(e,c,{weight:0,minlen:n}));var h=s.addBorderNode(t,"_bt"),f=s.addBorderNode(t,"_bb"),d=t.node(c);t.setParent(h,c),d.borderTop=h,t.setParent(f,c),d.borderBottom=f,o.each(l,function(o){r(t,e,n,i,a,u,o);var s=t.node(o),l=s.borderTop?s.borderTop:o,d=s.borderBottom?s.borderBottom:o,p=s.borderTop?i:2*i,g=l!==d?1:a-u[c]+1;t.setEdge(h,l,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(d,f,{weight:p,minlen:g,nestingEdge:!0})}),t.parent(c)||t.setEdge(e,h,{weight:0,minlen:a+u[c]})}function i(t){function e(r,i){var a=t.children(r);a&&a.length&&o.each(a,function(t){e(t,i+1)}),n[r]=i}var n={};return o.each(t.children(),function(t){e(t,1)}),n}function a(t){return o.reduce(t.edges(),function(e,n){return e+t.edge(n).weight},0)}function u(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,o.each(t.edges(),function(e){var n=t.edge(e);n.nestingEdge&&t.removeEdge(e)})}var o=t("./lodash"),s=t("./util");e.exports={run:n,cleanup:u}},{"./lodash":63,"./util":82}],65:[function(t,e){"use strict";function n(t){t.graph().dummyChains=[],a.each(t.edges(),function(e){r(t,e)})}function r(t,e){var n=e.v,r=t.node(n).rank,i=e.w,a=t.node(i).rank,o=e.name,s=t.edge(e),c=s.labelRank;if(a!==r+1){t.removeEdge(e);var l,h,f;for(f=0,++r;a>r;++f,++r)s.points=[],h={width:0,height:0,edgeLabel:s,edgeObj:e,rank:r},l=u.addDummyNode(t,"edge",h,"_d"),r===c&&(h.width=s.width,h.height=s.height,h.dummy="edge-label",h.labelpos=s.labelpos),t.setEdge(n,l,{weight:s.weight},o),0===f&&t.graph().dummyChains.push(l),n=l;t.setEdge(n,i,{weight:s.weight},o)}}function i(t){a.each(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)})}var a=t("./lodash"),u=t("./util");e.exports={run:n,undo:i}},{"./lodash":63,"./util":82}],66:[function(t,e){function n(t,e,n){var i,a={};r.each(n,function(n){for(var r,u,o=t.parent(n);o;){if(r=t.parent(o),r?(u=a[r],a[r]=o):(u=i,i=o),u&&u!==o)return void e.setEdge(u,o);o=r}})}var r=t("../lodash");e.exports=n},{"../lodash":63}],67:[function(t,e){function n(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}})}var r=t("../lodash");e.exports=n},{"../lodash":63}],68:[function(t,e){function n(t,e,n){var u=r(t),o=new a({compound:!0}).setGraph({root:u}).setDefaultNodeLabel(function(e){return t.node(e)});return i.each(t.nodes(),function(r){var a=t.node(r),s=t.parent(r);(a.rank===e||a.minRank<=e&&e<=a.maxRank)&&(o.setNode(r),o.setParent(r,s||u),i.each(t[n](r),function(e){var n=e.v===r?e.w:e.v,a=o.edge(n,r),u=i.isUndefined(a)?0:a.weight;o.setEdge(n,r,{weight:t.edge(e).weight+u})}),i.has(a,"minRank")&&o.setNode(r,{borderLeft:a.borderLeft[e],borderRight:a.borderRight[e]}))}),o}function r(t){for(var e;t.hasNode(e=i.uniqueId("_root")););return e}var i=t("../lodash"),a=t("../graphlib").Graph;e.exports=n},{"../graphlib":60,"../lodash":63}],69:[function(t,e){"use strict";function n(t,e){for(var n=0,i=1;i0;)e%2&&(n+=s[e+1]),e=e-1>>1,s[e]+=t.weight;c+=t.weight*n})),c}var i=t("../lodash");e.exports=n},{"../lodash":63}],70:[function(t,e){"use strict";function n(t){var e=d.maxRank(t),n=r(t,u.range(1,e+1),"inEdges"),c=r(t,u.range(e-1,-1,-1),"outEdges"),l=o(t);a(t,l);for(var h,f=Number.POSITIVE_INFINITY,p=0,g=0;4>g;++p,++g){i(p%2?n:c,p%4>=2),l=d.buildLayerMatrix(t);var y=s(t,l);f>y&&(g=0,h=u.cloneDeep(l),f=y)}a(t,h)}function r(t,e,n){return u.map(e,function(e){return l(t,e,n)})}function i(t,e){var n=new f;u.each(t,function(t){var r=t.graph().root,i=c(t,r,n,e);u.each(i.vs,function(e,n){t.node(e).order=n}),h(t,n,i.vs)})}function a(t,e){u.each(e,function(e){u.each(e,function(e,n){t.node(e).order=n})})}var u=t("../lodash"),o=t("./init-order"),s=t("./cross-count"),c=t("./sort-subgraph"),l=t("./build-layer-graph"),h=t("./add-subgraph-constraints"),f=t("../graphlib").Graph,d=t("../util");e.exports=n},{"../graphlib":60,"../lodash":63,"../util":82,"./add-subgraph-constraints":66,"./build-layer-graph":68,"./cross-count":69,"./init-order":71,"./sort-subgraph":73}],71:[function(t,e){"use strict";function n(t){function e(i){if(!r.has(n,i)){n[i]=!0;var a=t.node(i);u[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})),u=r.map(r.range(a+1),function(){return[]}),o=r.sortBy(i,function(e){return t.node(e).rank});return r.each(o,e),u}var r=t("../lodash");e.exports=n},{"../lodash":63}],72:[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 u=t.pop();r.push(u),a.each(u["in"].reverse(),e(u)),a.each(u.out,n(u))}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":63}],73:[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=u(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=s(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"),u=t("./barycenter"),o=t("./resolve-conflicts"),s=t("./sort");e.exports=n},{"../lodash":63,"./barycenter":67,"./resolve-conflicts":72,"./sort":74}],74:[function(t,e){function n(t,e){var n=u.partition(t,function(t){return a.has(t,"barycenter")}),o=n.lhs,s=a.sortBy(n.rhs,function(t){return-t.i}),c=[],l=0,h=0,f=0;o.sort(i(!!e)),f=r(c,s,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,s,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.barycentern.barycenter?1:t?n.i-e.i:e.i-n.i}}var a=t("../lodash"),u=t("../util");e.exports=n},{"../lodash":63,"../util":82}],75:[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,u=r(t,e,a.v,a.w),o=u.path,s=u.lca,c=0,l=o[c],h=!0;n!==a.w;){if(i=t.node(n),h){for(;(l=o[c])!==s&&t.node(l).maxRanks||c>e[i].lim));for(a=i,i=r;(i=t.parent(i))!==a;)o.push(i);return{path:u.concat(o.reverse()),lca:a}}function i(t){function e(i){var u=r;a.each(t.children(i),e),n[i]={low:u,lim:r++}}var n={},r=0;return a.each(t.children(),e),n}var a=t("./lodash");e.exports=n},{"./lodash":63}],76:[function(t,e){"use strict";function n(t,e){function n(e,n){ +var u=0,o=0,s=e.length,c=y.last(n);return y.each(n,function(e,l){var h=i(t,e),f=h?t.node(h).order:s;(h||e===c)&&(y.each(n.slice(o,l+1),function(e){y.each(t.predecessors(e),function(n){var i=t.node(n),o=i.order;!(u>o||o>f)||i.dummy&&t.node(e).dummy||a(r,n,e)})}),o=l+1,u=f)}),n}var r={};return y.reduce(e,n),r}function r(t,e){function n(e,n,r,u,o){var s;y.each(y.range(n,r),function(n){s=e[n],t.node(s).dummy&&y.each(t.predecessors(s),function(e){var n=t.node(e);n.dummy&&(n.ordero)&&a(i,e,s)})})}function r(e,r){var i,a=-1,u=0;return y.each(r,function(o,s){if("border"===t.node(o).dummy){var c=t.predecessors(o);c.length&&(i=t.node(c[0]).order,n(r,u,s,a,i),u=s,a=i)}n(r,u,r.length,i,e.length)}),r}var i={};return y.reduce(e,r),i}function i(t,e){return t.node(e).dummy?y.find(t.predecessors(e),function(e){return t.node(e).dummy}):void 0}function a(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 r=e;e=n,n=r}return y.has(t[e],n)}function o(t,e,n,r){var i={},a={},o={};return y.each(e,function(t){y.each(t,function(t,e){i[t]=t,a[t]=t,o[t]=e})}),y.each(e,function(t){var e=-1;y.each(t,function(t){var s=r(t);if(s.length){s=y.sortBy(s,function(t){return o[t]});for(var c=(s.length-1)/2,l=Math.floor(c),h=Math.ceil(c);h>=l;++l){var f=s[l];a[t]===t&&eu.lim&&(o=u,s=!0);var c=p.filter(e.edges(),function(e){return s===d(t,t.node(e.v),o)&&s!==d(t,t.node(e.w),o)});return p.min(c,function(t){return y(e,t)})}function l(t,e,n,i){var a=n.v,o=n.w;t.removeEdge(a,o),t.setEdge(i.v,i.w,{}),u(t),r(t,e),h(t,e)}function h(t,e){var n=p.find(t.nodes(),function(t){return!e.node(t).parent}),r=v(t,n);r=r.slice(1),p.each(r,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)})}function f(t,e,n){return t.hasEdge(e,n)}function d(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}var p=t("../lodash"),g=t("./feasible-tree"),y=t("./util").slack,m=t("./util").longestPath,v=t("../graphlib").alg.preorder,_=t("../graphlib").alg.postorder,b=t("../util").simplify;e.exports=n,n.initLowLimValues=u,n.initCutValues=r,n.calcCutValue=a,n.leaveEdge=s,n.enterEdge=c,n.exchangeEdges=l},{"../graphlib":60,"../lodash":63,"../util":82,"./feasible-tree":78,"./util":81}],81:[function(t,e){"use strict";function n(t){function e(r){var a=t.node(r);if(i.has(n,r))return a.rank;n[r]=!0;var u=i.min(i.map(t.outEdges(r),function(n){return e(n.w)-t.edge(n).minlen}));return u===Number.POSITIVE_INFINITY&&(u=0),a.rank=u}var n={};i.each(t.sources(),e)}function r(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}var i=t("../lodash");e.exports={longestPath:n,slack:r}},{"../lodash":63}],82:[function(t,e){"use strict";function n(t,e,n,r){var i;do i=y.uniqueId(r);while(t.hasNode(i));return n.dummy=e,t.setNode(i,n),i}function r(t){var e=(new m).setGraph(t.graph());return y.each(t.nodes(),function(n){e.setNode(n,t.node(n))}),y.each(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}function i(t){var e=new m({multigraph:t.isMultigraph()}).setGraph(t.graph());return y.each(t.nodes(),function(n){t.children(n).length||e.setNode(n,t.node(n))}),y.each(t.edges(),function(n){e.setEdge(n,t.edge(n))}),e}function a(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.outEdges(e),function(e){n[e.w]=(n[e.w]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function u(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.inEdges(e),function(e){n[e.v]=(n[e.v]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function o(t,e){var n=t.x,r=t.y,i=e.x-n,a=e.y-r,u=t.width/2,o=t.height/2;if(!i&&!a)throw new Error("Not possible to find intersection inside of the rectangle");var s,c;return Math.abs(a)*u>Math.abs(i)*o?(0>a&&(o=-o),s=o*i/a,c=o):(0>i&&(u=-u),s=u,c=u*a/i),{x:n+s,y:r+c}}function s(t){var e=y.map(y.range(f(t)+1),function(){return[]});return y.each(t.nodes(),function(n){var r=t.node(n),i=r.rank;y.isUndefined(i)||(e[i][r.order]=n)}),e}function c(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank}));y.each(t.nodes(),function(n){var r=t.node(n);y.has(r,"rank")&&(r.rank-=e)})}function l(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank})),n=[];y.each(t.nodes(),function(r){var i=t.node(r).rank-e;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=t.graph().nodeRankFactor;y.each(n,function(e,n){y.isUndefined(e)&&n%i!==0?--r:r&&y.each(e,function(e){t.node(e).rank+=r})})}function h(t,e,r,i){var a={width:0,height:0};return arguments.length>=4&&(a.rank=r,a.order=i),n(t,"border",a,e)}function f(t){return y.max(y.map(t.nodes(),function(e){var n=t.node(e).rank;return y.isUndefined(n)?void 0:n}))}function d(t,e){var n={lhs:[],rhs:[]};return y.each(t,function(t){e(t)?n.lhs.push(t):n.rhs.push(t)}),n}function p(t,e){var n=y.now();try{return e()}finally{console.log(t+" time: "+(y.now()-n)+"ms")}}function g(t,e){return e()}var y=t("./lodash"),m=t("./graphlib").Graph;e.exports={addDummyNode:n,simplify:r,asNonCompoundGraph:i,successorWeights:a,predecessorWeights:u,intersectRect:o,buildLayerMatrix:s,normalizeRanks:c,removeEmptyRanks:l,addBorderNode:h,maxRank:f,partition:d,time:p,notime:g}},{"./graphlib":60,"./lodash":63}],83:[function(t,e){e.exports="0.7.4"},{}],84:[function(t,e){e.exports=t(33)},{"./lib":100,"./lib/alg":91,"./lib/json":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/index.js":33}],85:[function(t,e){e.exports=t(34)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/components.js":34}],86:[function(t,e){e.exports=t(35)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dfs.js":35}],87:[function(t,e){e.exports=t(36)},{"../lodash":102,"./dijkstra":88,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra-all.js":36}],88:[function(t,e){e.exports=t(37)},{"../data/priority-queue":98,"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra.js":37}],89:[function(t,e){e.exports=t(38)},{"../lodash":102,"./tarjan":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/find-cycles.js":38}],90:[function(t,e){e.exports=t(39)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/floyd-warshall.js":39}],91:[function(t,e){e.exports=t(40)},{"./components":85,"./dijkstra":88,"./dijkstra-all":87,"./find-cycles":89,"./floyd-warshall":90,"./is-acyclic":92,"./postorder":93,"./preorder":94,"./prim":95,"./tarjan":96,"./topsort":97,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/index.js":40}],92:[function(t,e){e.exports=t(41)},{"./topsort":97,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/is-acyclic.js":41}],93:[function(t,e){e.exports=t(42)},{"./dfs":86,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/postorder.js":42}],94:[function(t,e){e.exports=t(43)},{"./dfs":86,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/preorder.js":43}],95:[function(t,e){e.exports=t(44)},{"../data/priority-queue":98,"../graph":99,"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/prim.js":44}],96:[function(t,e){e.exports=t(45)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/tarjan.js":45}],97:[function(t,e){e.exports=t(46)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/topsort.js":46}],98:[function(t,e){e.exports=t(47)},{"../lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/data/priority-queue.js":47}],99:[function(t,e){e.exports=t(48)},{"./lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/graph.js":48}],100:[function(t,e){e.exports=t(49)},{"./graph":99,"./version":103,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/index.js":49}],101:[function(t,e){e.exports=t(50)},{"./graph":99,"./lodash":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/json.js":50}],102:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":51,lodash:104}],103:[function(t,e){e.exports=t(52)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/version.js":52}],104:[function(t,e){e.exports=t(53)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/lodash/index.js":53}],105:[function(t,e,n){!function(t,r){"object"==typeof n&&"undefined"!=typeof e?e.exports=r():"function"==typeof define&&define.amd?define(r):t.moment=r()}(this,function(){"use strict";function n(){return In.apply(null,arguments)}function r(t){In=t}function i(t){return"[object Array]"===Object.prototype.toString.call(t)}function a(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function u(t,e){var n,r=[];for(n=0;n0)for(n in Rn)r=Rn[n],i=e[r],"undefined"!=typeof i&&(t[r]=i);return t}function g(t){p(this,t),this._d=new Date(null!=t._d?t._d.getTime():0/0),jn===!1&&(jn=!0,n.updateOffset(this),jn=!1)}function y(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function m(t){return 0>t?Math.ceil(t):Math.floor(t)}function v(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=m(e)),n}function _(t,e,n){var r,i=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),u=0;for(r=0;i>r;r++)(n&&t[r]!==e[r]||!n&&v(t[r])!==v(e[r]))&&u++;return u+a}function b(){}function x(t){return t?t.toLowerCase().replace("_","-"):t}function w(t){for(var e,n,r,i,a=0;a0;){if(r=A(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&_(i,n,!0)>=e-1)break;e--}a++}return null}function A(n){var r=null;if(!Yn[n]&&"undefined"!=typeof e&&e&&e.exports)try{r=Pn._abbr,t("./locale/"+n),k(r)}catch(i){}return Yn[n]}function k(t,e){var n;return t&&(n="undefined"==typeof e?D(t):E(t,e),n&&(Pn=n)),Pn._abbr}function E(t,e){return null!==e?(e.abbr=t,Yn[t]=Yn[t]||new b,Yn[t].set(e),k(t),Yn[t]):(delete Yn[t],null)}function D(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Pn;if(!i(t)){if(e=A(t))return e;t=[t]}return w(t)}function M(t,e){var n=t.toLowerCase();Un[n]=Un[n+"s"]=Un[e]=t}function C(t){return"string"==typeof t?Un[t]||Un[t.toLowerCase()]:void 0}function S(t){var e,n,r={};for(n in t)o(t,n)&&(e=C(n),e&&(r[e]=t[n]));return r}function T(t,e){return function(r){return null!=r?(B(this,t,r),n.updateOffset(this,e),this):F(this,t)}}function F(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function B(t,e,n){return t._d["set"+(t._isUTC?"UTC":"")+e](n)}function L(t,e){var n;if("object"==typeof t)for(n in t)this.set(n,t[n]);else if(t=C(t),"function"==typeof this[t])return this[t](e);return this}function O(t,e,n){var r=""+Math.abs(t),i=e-r.length,a=t>=0;return(a?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}function N(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&(Wn[t]=i),e&&(Wn[e[0]]=function(){return O(i.apply(this,arguments),e[1],e[2])}),n&&(Wn[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function I(t){return t.match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"")}function P(t){var e,n,r=t.match($n);for(e=0,n=r.length;n>e;e++)r[e]=Wn[r[e]]?Wn[r[e]]:I(r[e]);return function(i){var a="";for(e=0;n>e;e++)a+=r[e]instanceof Function?r[e].call(i,t):r[e];return a}}function R(t,e){return t.isValid()?(e=j(e,t.localeData()),qn[e]=qn[e]||P(e),qn[e](t)):t.localeData().invalidDate()}function j(t,e){function n(t){return e.longDateFormat(t)||t}var r=5;for(zn.lastIndex=0;r>=0&&zn.test(t);)t=t.replace(zn,n),zn.lastIndex=0,r-=1;return t}function Y(t){return"function"==typeof t&&"[object Function]"===Object.prototype.toString.call(t)}function U(t,e,n){ur[t]=Y(e)?e:function(t){return t&&n?n:e}}function $(t,e){return o(ur,t)?ur[t](e._strict,e._locale):new RegExp(z(t))}function z(t){return t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,n,r,i){return e||n||r||i}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function q(t,e){var n,r=e;for("string"==typeof t&&(t=[t]),"number"==typeof e&&(r=function(t,n){n[e]=v(t)}),n=0;nr;r++){if(i=c([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(a="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(a.replace(".",""),"i")),n&&"MMMM"===e&&this._longMonthsParse[r].test(t))return r;if(n&&"MMM"===e&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}}function K(t,e){var n;return"string"==typeof e&&(e=t.localeData().monthsParse(e),"number"!=typeof e)?t:(n=Math.min(t.date(),H(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n),t)}function Q(t){return null!=t?(K(this,t),n.updateOffset(this,!0),this):F(this,"Month")}function J(){return H(this.year(),this.month())}function tt(t){var e,n=t._a;return n&&-2===h(t).overflow&&(e=n[cr]<0||n[cr]>11?cr:n[lr]<1||n[lr]>H(n[sr],n[cr])?lr:n[hr]<0||n[hr]>24||24===n[hr]&&(0!==n[fr]||0!==n[dr]||0!==n[pr])?hr:n[fr]<0||n[fr]>59?fr:n[dr]<0||n[dr]>59?dr:n[pr]<0||n[pr]>999?pr:-1,h(t)._overflowDayOfYear&&(sr>e||e>lr)&&(e=lr),h(t).overflow=e),t}function et(t){n.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function nt(t,e){var n=!0;return s(function(){return n&&(et(t+"\n"+(new Error).stack),n=!1),e.apply(this,arguments)},e)}function rt(t,e){mr[t]||(et(e),mr[t]=!0)}function it(t){var e,n,r=t._i,i=vr.exec(r);if(i){for(h(t).iso=!0,e=0,n=_r.length;n>e;e++)if(_r[e][1].exec(r)){t._f=_r[e][0];break}for(e=0,n=br.length;n>e;e++)if(br[e][1].exec(r)){t._f+=(i[6]||" ")+br[e][0];break}r.match(rr)&&(t._f+="Z"),At(t)}else t._isValid=!1}function at(t){var e=xr.exec(t._i);return null!==e?void(t._d=new Date(+e[1])):(it(t),void(t._isValid===!1&&(delete t._isValid,n.createFromInputFallback(t))))}function ut(t,e,n,r,i,a,u){var o=new Date(t,e,n,r,i,a,u);return 1970>t&&o.setFullYear(t),o}function ot(t){var e=new Date(Date.UTC.apply(null,arguments));return 1970>t&&e.setUTCFullYear(t),e}function st(t){return ct(t)?366:365}function ct(t){return t%4===0&&t%100!==0||t%400===0}function lt(){return ct(this.year())}function ht(t,e,n){var r,i=n-e,a=n-t.day();return a>i&&(a-=7),i-7>a&&(a+=7),r=Ft(t).add(a,"d"),{week:Math.ceil(r.dayOfYear()/7),year:r.year()}}function ft(t){return ht(t,this._week.dow,this._week.doy).week}function dt(){return this._week.dow}function pt(){return this._week.doy}function gt(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")}function yt(t){var e=ht(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")}function mt(t,e,n,r,i){var a,u=6+i-r,o=ot(t,0,1+u),s=o.getUTCDay();return i>s&&(s+=7),n=null!=n?1*n:i,a=1+u+7*(e-1)-s+n,{year:a>0?t:t-1,dayOfYear:a>0?a:st(t-1)+a}}function vt(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")}function _t(t,e,n){return null!=t?t:null!=e?e:n}function bt(t){var e=new Date;return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function xt(t){var e,n,r,i,a=[];if(!t._d){for(r=bt(t),t._w&&null==t._a[lr]&&null==t._a[cr]&&wt(t),t._dayOfYear&&(i=_t(t._a[sr],r[sr]),t._dayOfYear>st(i)&&(h(t)._overflowDayOfYear=!0),n=ot(i,0,t._dayOfYear),t._a[cr]=n.getUTCMonth(),t._a[lr]=n.getUTCDate()),e=0;3>e&&null==t._a[e];++e)t._a[e]=a[e]=r[e];for(;7>e;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[hr]&&0===t._a[fr]&&0===t._a[dr]&&0===t._a[pr]&&(t._nextDay=!0,t._a[hr]=0),t._d=(t._useUTC?ot:ut).apply(null,a),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[hr]=24)}}function wt(t){var e,n,r,i,a,u,o;e=t._w,null!=e.GG||null!=e.W||null!=e.E?(a=1,u=4,n=_t(e.GG,t._a[sr],ht(Ft(),1,4).year),r=_t(e.W,1),i=_t(e.E,1)):(a=t._locale._week.dow,u=t._locale._week.doy,n=_t(e.gg,t._a[sr],ht(Ft(),a,u).year),r=_t(e.w,1),null!=e.d?(i=e.d,a>i&&++r):i=null!=e.e?e.e+a:a),o=mt(n,r,i,u,a),t._a[sr]=o.year,t._dayOfYear=o.dayOfYear}function At(t){if(t._f===n.ISO_8601)return void it(t);t._a=[],h(t).empty=!0;var e,r,i,a,u,o=""+t._i,s=o.length,c=0;for(i=j(t._f,t._locale).match($n)||[],e=0;e0&&h(t).unusedInput.push(u),o=o.slice(o.indexOf(r)+r.length),c+=r.length),Wn[a]?(r?h(t).empty=!1:h(t).unusedTokens.push(a),G(a,r,t)):t._strict&&!r&&h(t).unusedTokens.push(a);h(t).charsLeftOver=s-c,o.length>0&&h(t).unusedInput.push(o),h(t).bigHour===!0&&t._a[hr]<=12&&t._a[hr]>0&&(h(t).bigHour=void 0),t._a[hr]=kt(t._locale,t._a[hr],t._meridiem),xt(t),tt(t)}function kt(t,e,n){var r;return null==n?e:null!=t.meridiemHour?t.meridiemHour(e,n):null!=t.isPM?(r=t.isPM(n),r&&12>e&&(e+=12),r||12!==e||(e=0),e):e}function Et(t){var e,n,r,i,a;if(0===t._f.length)return h(t).invalidFormat=!0,void(t._d=new Date(0/0));for(i=0;ia)&&(r=a,n=e));s(t,n||e)}function Dt(t){if(!t._d){var e=S(t._i);t._a=[e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],xt(t)}}function Mt(t){var e=new g(tt(Ct(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=void 0),e}function Ct(t){var e=t._i,n=t._f;return t._locale=t._locale||D(t._l),null===e||void 0===n&&""===e?d({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),y(e)?new g(tt(e)):(i(n)?Et(t):n?At(t):a(e)?t._d=e:St(t),t))}function St(t){var e=t._i;void 0===e?t._d=new Date:a(e)?t._d=new Date(+e):"string"==typeof e?at(t):i(e)?(t._a=u(e.slice(0),function(t){return parseInt(t,10)}),xt(t)):"object"==typeof e?Dt(t):"number"==typeof e?t._d=new Date(e):n.createFromInputFallback(t)}function Tt(t,e,n,r,i){var a={};return"boolean"==typeof n&&(r=n,n=void 0),a._isAMomentObject=!0,a._useUTC=a._isUTC=i,a._l=n,a._i=t,a._f=e,a._strict=r,Mt(a)}function Ft(t,e,n,r){return Tt(t,e,n,r,!1)}function Bt(t,e){var n,r;if(1===e.length&&i(e[0])&&(e=e[0]),!e.length)return Ft();for(n=e[0],r=1;rt&&(t=-t,n="-"),n+O(~~(t/60),2)+e+O(~~t%60,2)})}function Rt(t){var e=(t||"").match(rr)||[],n=e[e.length-1]||[],r=(n+"").match(Dr)||["-",0,0],i=+(60*r[1])+v(r[2]);return"+"===r[0]?i:-i}function jt(t,e){var r,i;return e._isUTC?(r=e.clone(),i=(y(t)||a(t)?+t:+Ft(t))-+r,r._d.setTime(+r._d+i),n.updateOffset(r,!1),r):Ft(t).local()}function Yt(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function Ut(t,e){var r,i=this._offset||0;return null!=t?("string"==typeof t&&(t=Rt(t)),Math.abs(t)<16&&(t=60*t),!this._isUTC&&e&&(r=Yt(this)),this._offset=t,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==t&&(!e||this._changeInProgress?re(this,Qt(t-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?i:Yt(this)}function $t(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function zt(t){return this.utcOffset(0,t)}function qt(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(Yt(this),"m")),this}function Wt(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(Rt(this._i)),this}function Gt(t){return t=t?Ft(t).utcOffset():0,(this.utcOffset()-t)%60===0}function Ht(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Vt(){if("undefined"!=typeof this._isDSTShifted)return this._isDSTShifted;var t={};if(p(t,this),t=Ct(t),t._a){var e=t._isUTC?c(t._a):Ft(t._a);this._isDSTShifted=this.isValid()&&_(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Xt(){return!this._isUTC}function Zt(){return this._isUTC}function Kt(){return this._isUTC&&0===this._offset}function Qt(t,e){var n,r,i,a=t,u=null;return It(t)?a={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(a={},e?a[e]=t:a.milliseconds=t):(u=Mr.exec(t))?(n="-"===u[1]?-1:1,a={y:0,d:v(u[lr])*n,h:v(u[hr])*n,m:v(u[fr])*n,s:v(u[dr])*n,ms:v(u[pr])*n}):(u=Cr.exec(t))?(n="-"===u[1]?-1:1,a={y:Jt(u[2],n),M:Jt(u[3],n),d:Jt(u[4],n),h:Jt(u[5],n),m:Jt(u[6],n),s:Jt(u[7],n),w:Jt(u[8],n)}):null==a?a={}:"object"==typeof a&&("from"in a||"to"in a)&&(i=ee(Ft(a.from),Ft(a.to)),a={},a.ms=i.milliseconds,a.M=i.months),r=new Nt(a),It(t)&&o(t,"_locale")&&(r._locale=t._locale),r}function Jt(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function te(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 ee(t,e){var n;return e=jt(e,t),t.isBefore(e)?n=te(t,e):(n=te(e,t),n.milliseconds=-n.milliseconds,n.months=-n.months),n}function ne(t,e){return function(n,r){var i,a;return null===r||isNaN(+r)||(rt(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=Qt(n,r),re(this,i,t),this}}function re(t,e,r,i){var a=e._milliseconds,u=e._days,o=e._months;i=null==i?!0:i,a&&t._d.setTime(+t._d+a*r),u&&B(t,"Date",F(t,"Date")+u*r),o&&K(t,F(t,"Month")+o*r),i&&n.updateOffset(t,u||o)}function ie(t,e){var n=t||Ft(),r=jt(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,Ft(n)))}function ae(){return new g(this)}function ue(t,e){var n;return e=C("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Ft(t),+this>+t):(n=y(t)?+t:+Ft(t),n<+this.clone().startOf(e))}function oe(t,e){var n;return e=C("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Ft(t),+t>+this):(n=y(t)?+t:+Ft(t),+this.clone().endOf(e)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 fe(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function de(){var t=this.clone().utc();return 0e;e++)if(this._weekdaysParse[e]||(n=Ft([2e3,1]).day(e),r="^"+this.weekdays(n,"")+"|^"+this.weekdaysShort(n,"")+"|^"+this.weekdaysMin(n,""),this._weekdaysParse[e]=new RegExp(r.replace(".",""),"i")),this._weekdaysParse[e].test(t))return e}function ze(t){var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=Re(t,this.localeData()),this.add(t-e,"d")):e}function qe(t){var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")}function We(t){return null==t?this.day()||7:this.day(this.day()%7?t:t-7)}function Ge(t,e){I(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}function He(t,e){return e._meridiemParse}function Ve(t){return"p"===(t+"").toLowerCase().charAt(0)}function Xe(t,e,n){return t>11?n?"pm":"PM":n?"am":"AM"}function Ze(t,e){e[pr]=v(1e3*("0."+t))}function Ke(){return this._isUTC?"UTC":""}function Qe(){return this._isUTC?"Coordinated Universal Time":""}function Je(t){return Ft(1e3*t)}function tn(){return Ft.apply(null,arguments).parseZone()}function en(t,e,n){var r=this._calendar[t];return"function"==typeof r?r.call(e,n):r}function nn(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.replace(/MMMM|MM|DD|dddd/g,function(t){return t.slice(1)}),this._longDateFormat[t])}function rn(){return this._invalidDate}function an(t){return this._ordinal.replace("%d",t)}function un(t){return t}function on(t,e,n,r){var i=this._relativeTime[n];return"function"==typeof i?i(t,e,n,r):i.replace(/%d/i,t)}function sn(t,e){var n=this._relativeTime[t>0?"future":"past"];return"function"==typeof n?n(e):n.replace(/%s/i,e)}function cn(t){var e,n;for(n in t)e=t[n],"function"==typeof e?this[n]=e:this["_"+n]=e;this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function ln(t,e,n,r){var i=M(),a=c().set(r,e);return i[n](a,t)}function hn(t,e,n,r,i){if("number"==typeof t&&(e=t,t=void 0),t=t||"",null!=e)return ln(t,e,n,i);var a,u=[];for(a=0;r>a;a++)u[a]=ln(t,a,n,i);return u}function fn(t,e){return hn(t,e,"months",12,"month")}function dn(t,e){return hn(t,e,"monthsShort",12,"month")}function pn(t,e){return hn(t,e,"weekdays",7,"day")}function gn(t,e){return hn(t,e,"weekdaysShort",7,"day")}function yn(t,e){return hn(t,e,"weekdaysMin",7,"day")}function mn(){var t=this._data;return this._milliseconds=Kr(this._milliseconds),this._days=Kr(this._days),this._months=Kr(this._months),t.milliseconds=Kr(t.milliseconds),t.seconds=Kr(t.seconds),t.minutes=Kr(t.minutes),t.hours=Kr(t.hours),t.months=Kr(t.months),t.years=Kr(t.years),this}function vn(t,e,n,r){var i=Qt(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function _n(t,e){return vn(this,t,e,1)}function bn(t,e){return vn(this,t,e,-1)}function xn(t){return 0>t?Math.floor(t):Math.ceil(t)}function wn(){var t,e,n,r,i,a=this._milliseconds,u=this._days,o=this._months,s=this._data;return a>=0&&u>=0&&o>=0||0>=a&&0>=u&&0>=o||(a+=864e5*xn(kn(o)+u),u=0,o=0),s.milliseconds=a%1e3,t=m(a/1e3),s.seconds=t%60,e=m(t/60),s.minutes=e%60,n=m(e/60),s.hours=n%24,u+=m(n/24),i=m(An(u)),o+=i,u-=xn(kn(i)),r=m(o/12),o%=12,s.days=u,s.months=o,s.years=r,this}function An(t){return 4800*t/146097}function kn(t){return 146097*t/4800}function En(t){var e,n,r=this._milliseconds;if(t=C(t),"month"===t||"year"===t)return e=this._days+r/864e5,n=this._months+An(e),"month"===t?n:n/12;switch(e=this._days+Math.round(kn(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return 24*e+r/36e5;case"minute":return 1440*e+r/6e4;case"second":return 86400*e+r/1e3;case"millisecond":return Math.floor(864e5*e)+r;default:throw new Error("Unknown unit "+t)}}function Mn(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function Dn(t){return function(){return this.as(t)}}function Cn(t){return t=C(t),this[t+"s"]()}function Sn(t){return function(){return this._data[t]}}function Tn(){return m(this.days()/7)}function Fn(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}function Bn(t,e,n){var r=Qt(t).abs(),i=di(r.as("s")),a=di(r.as("m")),u=di(r.as("h")),o=di(r.as("d")),s=di(r.as("M")),c=di(r.as("y")),l=i0,l[4]=n,Fn.apply(null,l)}function Ln(t,e){return void 0===pi[t]?!1:void 0===e?pi[t]:(pi[t]=e,!0)}function On(t){var e=this.localeData(),n=Bn(this,!t,e);return t&&(n=e.pastFuture(+this,n)),e.postformat(n)}function In(){var t,e,n,r=gi(this._milliseconds)/1e3,i=gi(this._days),a=gi(this._months);t=m(r/60),e=m(t/60),r%=60,t%=60,n=m(a/12),a%=12;var u=n,o=a,s=i,c=e,l=t,h=r,f=this.asSeconds();return f?(0>f?"-":"")+"P"+(u?u+"Y":"")+(o?o+"M":"")+(s?s+"D":"")+(c||l||h?"T":"")+(c?c+"H":"")+(l?l+"M":"")+(h?h+"S":""):"P0D"}var Nn,Pn,Rn=n.momentProperties=[],jn=!1,Yn={},Un={},$n=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,zn=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,qn={},Wn={},Gn=/\d/,Hn=/\d\d/,Vn=/\d{3}/,Xn=/\d{4}/,Zn=/[+-]?\d{6}/,Kn=/\d\d?/,Qn=/\d{1,3}/,Jn=/\d{1,4}/,tr=/[+-]?\d{1,6}/,er=/\d+/,nr=/[+-]?\d+/,rr=/Z|[+-]\d\d:?\d\d/gi,ir=/[+-]?\d+(\.\d{1,3})?/,ar=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,ur={},or={},sr=0,cr=1,lr=2,hr=3,fr=4,dr=5,pr=6;I("M",["MM",2],"Mo",function(){return this.month()+1}),I("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),I("MMMM",0,0,function(t){return this.localeData().months(this,t)}),D("month","M"),U("M",Kn),U("MM",Kn,Hn),U("MMM",ar),U("MMMM",ar),q(["M","MM"],function(t,e){e[cr]=v(t)-1}),q(["MMM","MMMM"],function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);null!=i?e[cr]=i:h(n).invalidMonth=t});var gr="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),yr="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),mr={};n.suppressDeprecationWarnings=!1;var vr=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,_r=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],br=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],xr=/^\/?Date\((\-?\d+)/i;n.createFromInputFallback=nt("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),I(0,["YY",2],0,function(){return this.year()%100}),I(0,["YYYY",4],0,"year"),I(0,["YYYYY",5],0,"year"),I(0,["YYYYYY",6,!0],0,"year"),D("year","y"),U("Y",nr),U("YY",Kn,Hn),U("YYYY",Jn,Xn),U("YYYYY",tr,Zn),U("YYYYYY",tr,Zn),q(["YYYYY","YYYYYY"],sr),q("YYYY",function(t,e){e[sr]=2===t.length?n.parseTwoDigitYear(t):v(t)}),q("YY",function(t,e){e[sr]=n.parseTwoDigitYear(t)}),n.parseTwoDigitYear=function(t){return v(t)+(v(t)>68?1900:2e3)};var wr=T("FullYear",!1);I("w",["ww",2],"wo","week"),I("W",["WW",2],"Wo","isoWeek"),D("week","w"),D("isoWeek","W"),U("w",Kn),U("ww",Kn,Hn),U("W",Kn),U("WW",Kn,Hn),W(["w","ww","W","WW"],function(t,e,n,r){e[r.substr(0,1)]=v(t)});var Ar={dow:0,doy:6};I("DDD",["DDDD",3],"DDDo","dayOfYear"),D("dayOfYear","DDD"),U("DDD",Qn),U("DDDD",Vn),q(["DDD","DDDD"],function(t,e,n){n._dayOfYear=v(t)}),n.ISO_8601=function(){};var kr=nt("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var t=Ft.apply(null,arguments);return this>t?this:t}),Er=nt("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var t=Ft.apply(null,arguments);return t>this?this:t});Pt("Z",":"),Pt("ZZ",""),U("Z",rr),U("ZZ",rr),q(["Z","ZZ"],function(t,e,n){n._useUTC=!0,n._tzm=Rt(t)});var Mr=/([\+\-]|\d\d)/gi;n.updateOffset=function(){};var Dr=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Cr=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/;Qt.fn=It.prototype;var Sr=ne(1,"add"),Tr=ne(-1,"subtract");n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var Fr=nt("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return void 0===t?this.localeData():this.locale(t)});I(0,["gg",2],0,function(){return this.weekYear()%100}),I(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Fe("gggg","weekYear"),Fe("ggggg","weekYear"),Fe("GGGG","isoWeekYear"),Fe("GGGGG","isoWeekYear"),D("weekYear","gg"),D("isoWeekYear","GG"),U("G",nr),U("g",nr),U("GG",Kn,Hn),U("gg",Kn,Hn),U("GGGG",Jn,Xn),U("gggg",Jn,Xn),U("GGGGG",tr,Zn),U("ggggg",tr,Zn),W(["gggg","ggggg","GGGG","GGGGG"],function(t,e,n,r){e[r.substr(0,2)]=v(t)}),W(["gg","GG"],function(t,e,r,i){e[i]=n.parseTwoDigitYear(t)}),I("Q",0,0,"quarter"),D("quarter","Q"),U("Q",Gn),q("Q",function(t,e){e[cr]=3*(v(t)-1)}),I("D",["DD",2],"Do","date"),D("date","D"),U("D",Kn),U("DD",Kn,Hn),U("Do",function(t,e){return t?e._ordinalParse:e._ordinalParseLenient}),q(["D","DD"],lr),q("Do",function(t,e){e[lr]=v(t.match(Kn)[0],10)});var Br=T("Date",!0);I("d",0,"do","day"),I("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),I("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),I("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),I("e",0,0,"weekday"),I("E",0,0,"isoWeekday"),D("day","d"),D("weekday","e"),D("isoWeekday","E"),U("d",Kn),U("e",Kn),U("E",Kn),U("dd",ar),U("ddd",ar),U("dddd",ar),W(["dd","ddd","dddd"],function(t,e,n){var r=n._locale.weekdaysParse(t);null!=r?e.d=r:h(n).invalidWeekday=t}),W(["d","e","E"],function(t,e,n,r){e[r]=v(t)});var Lr="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Or="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Ir="Su_Mo_Tu_We_Th_Fr_Sa".split("_");I("H",["HH",2],0,"hour"),I("h",["hh",2],0,function(){return this.hours()%12||12}),Ge("a",!0),Ge("A",!1),D("hour","h"),U("a",He),U("A",He),U("H",Kn),U("h",Kn),U("HH",Kn,Hn),U("hh",Kn,Hn),q(["H","HH"],hr),q(["a","A"],function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t}),q(["h","hh"],function(t,e,n){e[hr]=v(t),h(n).bigHour=!0});var Nr=/[ap]\.?m?\.?/i,Pr=T("Hours",!0);I("m",["mm",2],0,"minute"),D("minute","m"),U("m",Kn),U("mm",Kn,Hn),q(["m","mm"],fr);var Rr=T("Minutes",!1);I("s",["ss",2],0,"second"),D("second","s"),U("s",Kn),U("ss",Kn,Hn),q(["s","ss"],dr);var jr=T("Seconds",!1);I("S",0,0,function(){return~~(this.millisecond()/100)}),I(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),I(0,["SSS",3],0,"millisecond"),I(0,["SSSS",4],0,function(){return 10*this.millisecond()}),I(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),I(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),I(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),I(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),I(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),D("millisecond","ms"),U("S",Qn,Gn),U("SS",Qn,Hn),U("SSS",Qn,Vn);var Yr;for(Yr="SSSS";Yr.length<=9;Yr+="S")U(Yr,er);for(Yr="S";Yr.length<=9;Yr+="S")q(Yr,Ze);var Ur=T("Milliseconds",!1);I("z",0,0,"zoneAbbr"),I("zz",0,0,"zoneName");var $r=g.prototype;$r.add=Sr,$r.calendar=ie,$r.clone=ae,$r.diff=le,$r.endOf=we,$r.format=pe,$r.from=ge,$r.fromNow=ye,$r.to=me,$r.toNow=ve,$r.get=L,$r.invalidAt=Te,$r.isAfter=ue,$r.isBefore=oe,$r.isBetween=se,$r.isSame=ce,$r.isValid=Ce,$r.lang=Fr,$r.locale=_e,$r.localeData=be,$r.max=Er,$r.min=kr,$r.parsingFlags=Se,$r.set=L,$r.startOf=xe,$r.subtract=Tr,$r.toArray=Me,$r.toObject=De,$r.toDate=Ee,$r.toISOString=de,$r.toJSON=de,$r.toString=fe,$r.unix=ke,$r.valueOf=Ae,$r.year=wr,$r.isLeapYear=lt,$r.weekYear=Le,$r.isoWeekYear=Oe,$r.quarter=$r.quarters=Pe,$r.month=Q,$r.daysInMonth=J,$r.week=$r.weeks=gt,$r.isoWeek=$r.isoWeeks=yt,$r.weeksInYear=Ne,$r.isoWeeksInYear=Ie,$r.date=Br,$r.day=$r.days=ze,$r.weekday=qe,$r.isoWeekday=We,$r.dayOfYear=vt,$r.hour=$r.hours=Pr,$r.minute=$r.minutes=Rr,$r.second=$r.seconds=jr,$r.millisecond=$r.milliseconds=Ur,$r.utcOffset=Ut,$r.utc=zt,$r.local=qt,$r.parseZone=Wt,$r.hasAlignedHourOffset=Gt,$r.isDST=Ht,$r.isDSTShifted=Vt,$r.isLocal=Xt,$r.isUtcOffset=Zt,$r.isUtc=Kt,$r.isUTC=Kt,$r.zoneAbbr=Ke,$r.zoneName=Qe,$r.dates=nt("dates accessor is deprecated. Use date instead.",Br),$r.months=nt("months accessor is deprecated. Use month instead",Q),$r.years=nt("years accessor is deprecated. Use year instead",wr),$r.zone=nt("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",$t);var zr=$r,qr={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},Wr={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"},Gr="Invalid date",Hr="%d",Vr=/\d{1,2}/,Xr={future:"in %s",past:"%s ago",s:"a few 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"},Zr=b.prototype;Zr._calendar=qr,Zr.calendar=en,Zr._longDateFormat=Wr,Zr.longDateFormat=nn,Zr._invalidDate=Gr,Zr.invalidDate=rn,Zr._ordinal=Hr,Zr.ordinal=an,Zr._ordinalParse=Vr,Zr.preparse=un,Zr.postformat=un,Zr._relativeTime=Xr,Zr.relativeTime=on,Zr.pastFuture=sn,Zr.set=cn,Zr.months=V,Zr._months=gr,Zr.monthsShort=X,Zr._monthsShort=yr,Zr.monthsParse=Z,Zr.week=ft,Zr._week=Ar,Zr.firstDayOfYear=pt,Zr.firstDayOfWeek=dt,Zr.weekdays=je,Zr._weekdays=Lr,Zr.weekdaysMin=Ue,Zr._weekdaysMin=Ir,Zr.weekdaysShort=Ye,Zr._weekdaysShort=Or,Zr.weekdaysParse=$e,Zr.isPM=Ve,Zr._meridiemParse=Nr,Zr.meridiem=Xe,k("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,n=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+n}}),n.lang=nt("moment.lang is deprecated. Use moment.locale instead.",k),n.langData=nt("moment.langData is deprecated. Use moment.localeData instead.",M);var Kr=Math.abs,Qr=Dn("ms"),Jr=Dn("s"),ti=Dn("m"),ei=Dn("h"),ni=Dn("d"),ri=Dn("w"),ii=Dn("M"),ai=Dn("y"),ui=Sn("milliseconds"),oi=Sn("seconds"),si=Sn("minutes"),ci=Sn("hours"),li=Sn("days"),hi=Sn("months"),fi=Sn("years"),di=Math.round,pi={s:45,m:45,h:22,d:26,M:11},gi=Math.abs,yi=It.prototype;yi.abs=mn,yi.add=_n,yi.subtract=bn,yi.as=En,yi.asMilliseconds=Qr,yi.asSeconds=Jr,yi.asMinutes=ti,yi.asHours=ei,yi.asDays=ni,yi.asWeeks=ri,yi.asMonths=ii,yi.asYears=ai,yi.valueOf=Mn,yi._bubble=wn,yi.get=Cn,yi.milliseconds=ui,yi.seconds=oi,yi.minutes=si,yi.hours=ci,yi.days=li,yi.weeks=Tn,yi.months=hi,yi.years=fi,yi.humanize=On,yi.toISOString=In,yi.toString=In,yi.toJSON=In,yi.locale=_e,yi.localeData=be,yi.toIsoString=nt("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",In),yi.lang=Fr,I("X",0,0,"unix"),I("x",0,0,"valueOf"),U("x",nr),U("X",ir),q("X",function(t,e,n){n._d=new Date(1e3*parseFloat(t,10))}),q("x",function(t,e,n){n._d=new Date(v(t))}),n.version="2.10.6",r(Ft),n.fn=zr,n.min=Lt,n.max=Ot,n.utc=c,n.unix=Je,n.months=fn,n.isDate=a,n.locale=k,n.invalid=d,n.duration=Qt,n.isMoment=y,n.weekdays=pn,n.parseZone=tn,n.localeData=M,n.isDuration=Nt,n.monthsShort=dn,n.weekdaysMin=yn,n.defineLocale=E,n.weekdaysShort=gn,n.normalizeUnits=C,n.relativeTimeThreshold=Ln;var mi=n;return mi})},{}],106:[function(t,e){e.exports={name:"mermaid",version:"0.5.5",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:{live:"live-server ./test/examples",lint:"node node_modules/eslint/bin/eslint.js src",jison:"gulp jison_legacy",watch:"source ./scripts/watch.sh",doc:"rm -r build;rm -r dist/www;gulp vartree;cp dist/www/all.html ../mermaid-pages/index.html;cp dist/mermaid.js ../mermaid-pages/javascripts/lib;cp dist/mermaid.forest.css ../mermaid-pages/stylesheets",tape:"node node_modules/.bin/tape test/cli_test-*.js",jasmine:"npm run jison &&node node_modules/jasmine-es6/bin/jasmine.js",posttest:"npm run jison",test:"npm run dist && npm run jasmine && npm run tape","dist-slim-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.slim.js -x d3 && cat dist/mermaid.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.slim.min.js","dist-slim-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.slim.js -x d3 && cat dist/mermaidAPI.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.slim.min.js","dist-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.js && cat dist/mermaid.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.min.js","dist-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.js && cat dist/mermaidAPI.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.min.js",dist:"npm run dist-slim-mermaid;npm run dist-slim-mermaidAPI; npm run dist-mermaid;npm run dist-mermaidAPI"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"3.5.6",dagre:"^0.7.4","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","babel-eslint":"^4.1.3",babelify:"^6.4.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4",dateformat:"^1.0.11",dox:"^0.8.0",eslint:"^1.6.0","eslint-watch":"^2.1.2","event-stream":"^3.2.0",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.9.0","gulp-bower":"0.0.10","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-dox":"^0.1.6","gulp-ext-replace":"^0.2.0","gulp-filelog":"^0.4.1","gulp-front-matter":"^1.2.3","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~2.1.0","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-marked":"^1.0.0","gulp-mdvars":"^2.0.0","gulp-qunit":"~1.2.1","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1","gulp-vartree":"^2.0.1","hogan.js":"^3.0.2",jasmine:"2.3.2","jasmine-es6":"0.0.18",jison:"zaach/jison",jsdom:"^7.0.2","jshint-stylish":"^2.0.1","map-stream":"0.0.6",marked:"^0.3.2","mock-browser":"^0.91.34",path:"^0.4.9",phantomjs:"^1.9.18",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3",testdom:"^2.0.0",uglifyjs:"^2.4.10","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],107:[function(t,e){"use strict";var n;if(t)try{n=t("d3")}catch(r){}n||(n=window.d3),e.exports=n,function(){var t=!1;if(t="tspans",n.selection.prototype.textwrap)return!1;if("undefined"==typeof t)var t=!1;n.selection.prototype.textwrap=n.selection.enter.prototype.textwrap=function(e,r){var i,r=parseInt(r)||0,a=this,u=function(t){var e=t[0][0],r=e.tagName.toString();if("rect"!==r)return!1;var i={};return i.x=n.select(e).attr("x")||0,i.y=n.select(e).attr("y")||0,i.width=n.select(e).attr("width")||0,i.height=n.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)||"[object Array]"===Object.prototype.toString.call(t)){var e=u(t);return e}return!1},s=function(t,e){var n=t;return 0!==e&&(n.x=parseInt(n.x)+e,n.y=parseInt(n.y)+e,n.width-=2*e,n.height-=2*e),n},c=o(e);if(r&&(c=s(c,r)),0!=a.length&&n&&e&&c){e=c;var l,h=function(t){var r=n.select(t[0].parentNode),a=r.select("text"),u=a.style("line-height"),o=a.text();a.remove();var s=r.append("foreignObject");s.attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);var c=s.append("xhtml:div").attr("class","wrapped");c.style("height",e.height).style("width",e.width).html(o),u&&c.style("line-height",u),i=r.select("foreignObject")},f=function(t){var a,u=t[0],o=u.parentNode,s=n.select(u),c=u.getBBox().height,l=u.getBBox().width,h=c,f=s.style("line-height");if(a=f&&parseInt(f)?parseInt(f.replace("px","")):h,l>e.width){var d=s.text();if(s.text(""),d){var p,g;if(-1!==d.indexOf(" ")){var p=" ";g=d.split(" ")}else{p="";var y=d.length,m=Math.ceil(l/e.width),v=Math.floor(y/m);v*m>=y||m++;for(var _,b,g=[],x=0;m>x;x++)b=x*v,_=d.substr(b,v),g.push(_)}for(var w=[],A=0,k={},x=0;xe.width&&D&&""!==D&&(A+=C,k={string:D,width:C,offset:A},w.push(k),s.text(""),s.text(M),x==g.length-1&&(E=M,s.text(E),S=u.getComputedTextLength())),x==g.length-1){s.text("");var T=E;T&&""!==T&&(S-A>0&&(S-=A),k={string:T,width:S,offset:A},w.push(k))}}var F;s.text("");for(var x=0;x0){w[x-1]}x*a0?a:void 0}),F.attr("x",function(){var t=e.x;return r&&(t+=r),t}))}}}s.attr("y",function(){var t=e.y;return a&&(t+=a),r&&(t+=r),t}),s.attr("x",function(){var t=e.x;return r&&(t+=r),t}),i=n.select(o).selectAll("text")};t&&("foreignobjects"==t?l=h:"tspans"==t&&(l=f)),t||(l="undefined"!=typeof SVGForeignObjectElement?h:f);for(var d=0;d "+t.w+": "+JSON.stringify(r.edge(t))),v(n,r.edge(t),r.edge(t).relation)}),n.attr("height","100%"),n.attr("width","100%")}},{"../../d3":107,"../../logger":126,"./classDb":108,"./parser/classDiagram":110,dagre:54}],110:[function(t,e,n){(function(r){"use strict";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,11],r=[1,12],i=[1,13],a=[1,15],u=[1,16],o=[1,17],s=[6,8],c=[1,26],l=[1,27],h=[1,28],f=[1,29],d=[1,30],p=[1,31],g=[6,8,13,17,23,26,27,28,29,30,31],y=[6,8,13,17,23,26,27,28,29,30,31,45,46,47],m=[23,45,46,47],v=[23,30,31,45,46,47],_=[23,26,27,28,29,45,46,47],b=[6,8,13],x=[1,46],w={ -trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,CLASS_DIAGRAM:5,NEWLINE:6,statements:7,EOF:8,statement:9,className:10,alphaNumToken:11,relationStatement:12,LABEL:13,classStatement:14,methodStatement:15,CLASS:16,STRUCT_START:17,members:18,STRUCT_STOP:19,MEMBER:20,SEPARATOR:21,relation:22,STR:23,relationType:24,lineType:25,AGGREGATION:26,EXTENSION:27,COMPOSITION:28,DEPENDENCY:29,LINE:30,DOTTED_LINE:31,commentToken:32,textToken:33,graphCodeTokens:34,textNoTagsToken:35,TAGSTART:36,TAGEND:37,"==":38,"--":39,PCT:40,DEFAULT:41,SPACE:42,MINUS:43,keywords:44,UNICODE_TEXT:45,NUM:46,ALPHA:47,$accept:0,$end:1},terminals_:{2:"error",5:"CLASS_DIAGRAM",6:"NEWLINE",8:"EOF",13:"LABEL",16:"CLASS",17:"STRUCT_START",19:"STRUCT_STOP",20:"MEMBER",21:"SEPARATOR",23:"STR",26:"AGGREGATION",27:"EXTENSION",28:"COMPOSITION",29:"DEPENDENCY",30:"LINE",31:"DOTTED_LINE",34:"graphCodeTokens",36:"TAGSTART",37:"TAGEND",38:"==",39:"--",40:"PCT",41:"DEFAULT",42:"SPACE",43:"MINUS",44:"keywords",45:"UNICODE_TEXT",46:"NUM",47:"ALPHA"},productions_:[0,[3,1],[4,4],[7,1],[7,3],[10,2],[10,1],[9,1],[9,2],[9,1],[9,1],[14,2],[14,5],[18,1],[18,2],[15,1],[15,2],[15,1],[15,1],[12,3],[12,4],[12,4],[12,5],[22,3],[22,2],[22,2],[22,1],[24,1],[24,1],[24,1],[24,1],[25,1],[25,1],[32,1],[32,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[35,1],[35,1],[35,1],[35,1],[11,1],[11,1],[11,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 5:this.$=a[u-1]+a[u];break;case 6:this.$=a[u];break;case 7:r.addRelation(a[u]);break;case 8:a[u-1].title=r.cleanupLabel(a[u]),r.addRelation(a[u-1]);break;case 12:r.addMembers(a[u-3],a[u-1]);break;case 13:this.$=[a[u]];break;case 14:a[u].push(a[u-1]),this.$=a[u];break;case 15:break;case 16:r.addMembers(a[u-1],r.cleanupLabel(a[u]));break;case 17:console.warn("Member",a[u]);break;case 18:break;case 19:this.$={id1:a[u-2],id2:a[u],relation:a[u-1],relationTitle1:"none",relationTitle2:"none"};break;case 20:this.$={id1:a[u-3],id2:a[u],relation:a[u-1],relationTitle1:a[u-2],relationTitle2:"none"};break;case 21:this.$={id1:a[u-3],id2:a[u],relation:a[u-2],relationTitle1:"none",relationTitle2:a[u-1]};break;case 22:this.$={id1:a[u-4],id2:a[u],relation:a[u-2],relationTitle1:a[u-3],relationTitle2:a[u-1]};break;case 23:this.$={type1:a[u-2],type2:a[u],lineType:a[u-1]};break;case 24:this.$={type1:"none",type2:a[u],lineType:a[u-1]};break;case 25:this.$={type1:a[u-1],type2:"none",lineType:a[u]};break;case 26:this.$={type1:"none",type2:"none",lineType:a[u]};break;case 27:this.$=r.relationType.AGGREGATION;break;case 28:this.$=r.relationType.EXTENSION;break;case 29:this.$=r.relationType.COMPOSITION;break;case 30:this.$=r.relationType.DEPENDENCY;break;case 31:this.$=r.lineType.LINE;break;case 32:this.$=r.lineType.DOTTED_LINE}},table:[{3:1,4:2,5:[1,3]},{1:[3]},{1:[2,1]},{6:[1,4]},{7:5,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:u,47:o},{8:[1,18]},{6:[1,19],8:[2,3]},e(s,[2,7],{13:[1,20]}),e(s,[2,9]),e(s,[2,10]),e(s,[2,15],{22:21,24:24,25:25,13:[1,23],23:[1,22],26:c,27:l,28:h,29:f,30:d,31:p}),{10:32,11:14,45:a,46:u,47:o},e(s,[2,17]),e(s,[2,18]),e(g,[2,6],{11:14,10:33,45:a,46:u,47:o}),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),{1:[2,2]},{7:34,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:u,47:o},e(s,[2,8]),{10:35,11:14,23:[1,36],45:a,46:u,47:o},{22:37,24:24,25:25,26:c,27:l,28:h,29:f,30:d,31:p},e(s,[2,16]),{25:38,30:d,31:p},e(m,[2,26],{24:39,26:c,27:l,28:h,29:f}),e(v,[2,27]),e(v,[2,28]),e(v,[2,29]),e(v,[2,30]),e(_,[2,31]),e(_,[2,32]),e(s,[2,11],{17:[1,40]}),e(g,[2,5]),{8:[2,4]},e(b,[2,19]),{10:41,11:14,45:a,46:u,47:o},{10:42,11:14,23:[1,43],45:a,46:u,47:o},e(m,[2,25],{24:44,26:c,27:l,28:h,29:f}),e(m,[2,24]),{18:45,20:x},e(b,[2,21]),e(b,[2,20]),{10:47,11:14,45:a,46:u,47:o},e(m,[2,23]),{19:[1,48]},{18:49,19:[2,13],20:x},e(b,[2,22]),e(s,[2,12]),{19:[2,14]}],defaultActions:{2:[2,1],18:[2,2],34:[2,4],49:[2,14]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,M,D=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=D()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";M=[];for(A in a[b])this.terminals_[A]&&A>l&&M.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:M})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},A=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:return 6;case 2:break;case 3:return 5;case 4:return this.begin("struct"),17;case 5:return this.popState(),19;case 6:break;case 7:return"MEMBER";case 8:return 16;case 9:this.begin("string");break;case 10:this.popState();break;case 11:return"STR";case 12:return 27;case 13:return 27;case 14:return 29;case 15:return 29;case 16:return 28;case 17:return 26;case 18:return 30;case 19:return 31;case 20:return 13;case 21:return 43;case 22:return"DOT";case 23:return"PLUS";case 24:return 40;case 25:return"EQUALS";case 26:return"EQUALS";case 27:return 47;case 28:return"PUNCTUATION";case 29:return 46;case 30:return 45;case 31:return 42;case 32:return 8}},rules:[/^(?:%%[^\n]*)/,/^(?:\n+)/,/^(?:\s+)/,/^(?:classDiagram\b)/,/^(?:[\{])/,/^(?:\})/,/^(?:[\n])/,/^(?:[^\{\}\n]*)/,/^(?:class\b)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::[^#\n;]+)/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[A-Za-z]+)/,/^(?:[!"#$%&'*+,-.`?\\_\/])/,/^(?:[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:{string:{rules:[10,11],inclusive:!1},struct:{rules:[5,6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,8,9,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32],inclusive:!0}}};return t}();return w.lexer=A,t.prototype=w,w.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("_process"))},{_process:3,fs:1,path:2}],111:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=new a.Log,o="",s=!1;n.setMessage=function(t){u.debug("Setting message to: "+t),o=t},n.getMessage=function(){return o},n.setInfo=function(t){s=t},n.getInfo=function(){return s},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":126}],112:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=t("./exampleDb"),o=t("./parser/example.js"),s=t("../../d3"),c=new a.Log;n.draw=function(t,e,n){var r;r=o.parser,r.yy=u,c.debug("Renering example diagram"),r.parse(t);var i=s.select("#"+e),a=i.append("g");a.append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("mermaid "+n),i.attr("height",100),i.attr("width",400)}},{"../../d3":107,"../../logger":126,"./exampleDb":111,"./parser/example.js":113}],113:[function(t,e,n){(function(r){"use strict";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=[6,9,10,12],r={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,message:11,say:12,TXT:13,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo",12:"say",13:"TXT"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1],[8,1],[11,2]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:return r;case 4:break;case 6:r.setInfo(!0);break;case 7:r.setMessage(a[u]);break;case 8:this.$=a[u-1].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8],11:9,12:[1,10]},{1:[2,1]},e(n,[2,3]),e(n,[2,4]),e(n,[2,5]),e(n,[2,6]),e(n,[2,7]),{13:[1,11]},e(n,[2,8])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,M,D=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=D()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";M=[];for(A in a[b])this.terminals_[A]&&A>l&&M.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:M})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},i=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,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),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;ae[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]),"utf8");return n.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&n.main(r.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],114:[function(t,e){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var r,i=t("../../logger"),a=n(i),u=new a.Log;if(t)try{r=t("dagre-d3")}catch(o){u.debug("Could not load dagre-d3")}r||(r=window.dagreD3),e.exports=r},{"../../logger":126,"dagre-d3":5}],115:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=t("./graphDb"),o=t("./parser/flow"),s=t("./parser/dot"),c=t("../../d3"),l=t("./dagre-d3"),h=new a.Log,f={};e.exports.setConf=function(t){var e,n=Object.keys(t);for(e=0;e0&&(u=a.classes.join(" "));var o="";o=r(o,a.styles),i="undefined"==typeof a.text?a.id:a.text;var s="";f.htmlLabels?(s="html",i=i.replace(/fa:fa[\w\-]+/g,function(t){return''})):(i=i.replace(/
/g,"\n"),s="text");var c=0,l="";switch(a.type){case"round":c=5,l="rect";break;case"square":l="rect";break;case"diamond":l="question";break;case"odd":l="rect_left_inv_arrow";break;case"odd_right":l="rect_left_inv_arrow";break;case"circle":l="circle";break;case"ellipse":l="ellipse";break;case"group":l="rect",i="";break;default:l="rect"}e.setNode(a.id,{labelType:s,shape:l,label:i,rx:c,ry:c,"class":u,style:o,id:a.id})})},n.addEdges=function(t,e){var n,r,i=0;"undefined"!=typeof t.defaultStyle&&(r=t.defaultStyle.toString().replace(/,/g,";")),t.forEach(function(t){i++,n="arrow_open"===t.type?"none":"normal";var a="";if("undefined"!=typeof t.style)t.style.forEach(function(t){a=a+t+";"});else switch(t.stroke){case"normal":a="fill:none","undefined"!=typeof r&&(a=r);break;case"dotted":a="stroke: #333; fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":a="stroke: #333; stroke-width: 3.5px;fill:none"}if("undefined"==typeof t.text)"undefined"==typeof t.style?e.setEdge(t.start,t.end,{style:a,arrowhead:n},i):e.setEdge(t.start,t.end,{style:a,arrowheadStyle:"fill: #333",arrowhead:n},i);else{var u=t.text.replace(/
/g,"\n");"undefined"==typeof t.style?f.htmlLabels?e.setEdge(t.start,t.end,{labelType:"html",style:a,labelpos:"c",label:''+t.text+"",arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:"stroke: #333; stroke-width: 1.5px;fill:none",labelpos:"c",label:u,arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:a,arrowheadStyle:"fill: #333",label:u,arrowhead:n},i)}})},n.getClasses=function(t,e){var n;u.clear(),n=e?s.parser:o.parser,n.yy=u,n.parse(t);var r=u.getClasses();return"undefined"==typeof r["default"]&&(r["default"]={id:"default"},r["default"].styles=[],r["default"].clusterStyles=["rx:4px","fill: rgb(255, 255, 222)","rx: 4px","stroke: rgb(170, 170, 51)","stroke-width: 1px"],r["default"].nodeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"],r["default"].edgeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"]),r},n.draw=function(t,e,r){h.debug("Drawing flowchart");var i;u.clear(),i=r?s.parser:o.parser,i.yy=u;try{i.parse(t)}catch(a){h.debug("Parsing failed")}var d;d=u.getDirection(),"undefined"==typeof d&&(d="TD");var p,g=new l.graphlib.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:d,marginx:20,marginy:20}).setDefaultEdgeLabel(function(){return{}}),y=u.getSubGraphs(),m=0;for(m=y.length-1;m>=0;m--)p=y[m],u.addVertex(p.id,p.title,"group",void 0);var v=u.getVertices(),_=u.getEdges();m=0;var b;for(m=y.length-1;m>=0;m--)for(p=y[m],c.selectAll("cluster").append("text"),b=0;b0?t.split(",").forEach(function(t){"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)}):"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)};var setTooltip=function(t,e){"undefined"!=typeof e&&(tooltips[t]=e)},setClickFun=function setClickFun(id,functionName){"undefined"!=typeof functionName&&"undefined"!=typeof vertices[id]&&funs.push(function(element){var elem=d3.select(element).select("#"+id);null!==elem&&elem.on("click",function(){eval(functionName+"('"+id+"')")})})},setLink=function(t,e){"undefined"!=typeof e&&"undefined"!=typeof vertices[t]&&funs.push(function(n){var r=d3.select(n).select("#"+t);null!==r&&r.on("click",function(){window.open(e,"newTab")})})};exports.getTooltip=function(t){return tooltips[t]},exports.setClickEvent=function(t,e,n,r){t.indexOf(",")>0?t.split(",").forEach(function(t){setTooltip(t,r),setClickFun(t,e),setLink(t,n)}):(setTooltip(t,r),setClickFun(t,e),setLink(t,n))},exports.bindFunctions=function(t){funs.forEach(function(e){e(t)})},exports.getDirection=function(){return direction},exports.getVertices=function(){return vertices},exports.getEdges=function(){return edges},exports.getClasses=function(){return classes};var setupToolTips=function(t){var e=d3.select(".mermaidTooltip");null===e[0][0]&&(e=d3.select("body").append("div").attr("class","mermaidTooltip").style("opacity",0));var n=d3.select(t).select("svg"),r=n.selectAll("g.node");r.on("mouseover",function(){var t=d3.select(this),n=t.attr("title");if(null!==n){var r=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",r.left+(r.right-r.left)/2+"px").style("top",r.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}}).on("mouseout",function(){e.transition().duration(500).style("opacity",0);var t=d3.select(this);t.classed("hover",!1)})};funs.push(setupToolTips),exports.clear=function(){vertices={},classes={},edges=[],funs=[],funs.push(setupToolTips),subGraphs=[],subCount=0,tooltips=[]},exports.defaultStyle=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},exports.addSubGraph=function(t,e){function n(t){var e={"boolean":{},number:{},string:{}},n=[];return t.filter(function(t){var r=typeof t;return" "===t?!1:r in e?e[r].hasOwnProperty(t)?!1:e[r][t]=!0:n.indexOf(t)>=0?!1:n.push(t)})}var r=[];r=n(r.concat.apply(r,t));var i={id:"subGraph"+subCount,nodes:r,title:e};return subGraphs.push(i),subCount+=1,i.id};var getPosForId=function(t){var e;for(e=0;e2e3)){if(posCrossRef[secCount]=n,subGraphs[n].id===e)return{result:!0,count:0};for(var i=0,a=1;i=0){var o=t(e,u);if(o.result)return{result:!0,count:a+o.count};a+=o.count}i+=1}return{result:!1,count:a}}};exports.getDepthFirstPos=function(t){return posCrossRef[t]},exports.indexNodes=function(){secCount=-1,subGraphs.length>0&&indexNodes("none",subGraphs.length-1,0)},exports.getSubGraphs=function(){return subGraphs},exports.parseError=function(t,e){global.mermaidAPI.parseError(t,e)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../d3":107,"../../logger":126}],117:[function(t,e,n){(function(r){"use strict";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,5],r=[1,6],i=[1,12],a=[1,13],u=[1,14],o=[1,15],s=[1,16],c=[1,17],l=[1,18],h=[1,19],f=[1,20],d=[1,21],p=[1,22],g=[8,16,17,18,19,20,21,22,23,24,25,26],y=[1,37],m=[1,33],v=[1,34],_=[1,35],b=[1,36],x=[8,10,16,17,18,19,20,21,22,23,24,25,26,28,32,37,39,40,45,57,58],w=[10,28],A=[10,28,37,57,58],k=[2,49],E=[1,45],M=[1,48],D=[1,49],C=[1,52],S=[2,65],T=[1,65],F=[1,66],B=[1,67],L=[1,68],O=[1,69],I=[1,70],N=[1,71],P=[1,72],R=[1,73],j=[8,16,17,18,19,20,21,22,23,24,25,26,47],Y=[10,28,37],U={trace:function(){},yy:{},symbols_:{error:2,expressions:3,graph:4,EOF:5,graphStatement:6,idStatement:7,"{":8,stmt_list:9,"}":10,strict:11,GRAPH:12,DIGRAPH:13,textNoTags:14,textNoTagsToken:15,ALPHA:16,NUM:17,COLON:18,PLUS:19,EQUALS:20,MULT:21,DOT:22,BRKT:23,SPACE:24,MINUS:25,keywords:26,stmt:27,";":28,node_stmt:29,edge_stmt:30,attr_stmt:31,"=":32,subgraph:33,attr_list:34,NODE:35,EDGE:36,"[":37,a_list:38,"]":39,",":40,edgeRHS:41,node_id:42,edgeop:43,port:44,":":45,compass_pt:46,SUBGRAPH:47,n:48,ne:49,e:50,se:51,s:52,sw:53,w:54,nw:55,c:56,ARROW_POINT:57,ARROW_OPEN:58,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",8:"{",10:"}",11:"strict",12:"GRAPH",13:"DIGRAPH",16:"ALPHA",17:"NUM",18:"COLON",19:"PLUS",20:"EQUALS",21:"MULT",22:"DOT",23:"BRKT",24:"SPACE",25:"MINUS",26:"keywords",28:";",32:"=",35:"NODE",36:"EDGE",37:"[",39:"]",40:",",45:":",47:"SUBGRAPH",48:"n",49:"ne",50:"e",51:"se",52:"s",53:"sw",54:"w",55:"nw",56:"c",57:"ARROW_POINT",58:"ARROW_OPEN"},productions_:[0,[3,2],[4,5],[4,6],[4,4],[6,1],[6,1],[7,1],[14,1],[14,2],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[9,1],[9,3],[27,1],[27,1],[27,1],[27,3],[27,1],[31,2],[31,2],[31,2],[34,4],[34,3],[34,3],[34,2],[38,5],[38,5],[38,3],[30,3],[30,3],[30,2],[30,2],[41,3],[41,3],[41,2],[41,2],[29,2],[29,1],[42,2],[42,1],[44,4],[44,2],[44,2],[33,5],[33,4],[33,3],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,0],[43,1],[43,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:this.$=a[u-1];break;case 2:this.$=a[u-4];break;case 3:this.$=a[u-5];break;case 4:this.$=a[u-3];break;case 8:case 10:case 11:this.$=a[u];break;case 9:this.$=a[u-1]+""+a[u];break;case 12:case 13:case 14:case 15:case 16:case 18:case 19:case 20:this.$=a[u];break;case 17:this.$="
";break;case 39:this.$="oy";break;case 40:r.addLink(a[u-1],a[u].id,a[u].op),this.$="oy";break;case 42:r.addLink(a[u-1],a[u].id,a[u].op),this.$={op:a[u-2],id:a[u-1]};break;case 44:this.$={op:a[u-1],id:a[u]};break;case 48:r.addVertex(a[u-1]),this.$=a[u-1];break;case 49:r.addVertex(a[u]),this.$=a[u];break;case 66:this.$="arrow";break;case 67:this.$="arrow_open"}},table:[{3:1,4:2,6:3,11:[1,4],12:n,13:r},{1:[3]},{5:[1,7]},{7:8,8:[1,9],14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{6:23,12:n,13:r},e(g,[2,5]),e(g,[2,6]),{1:[2,1]},{8:[1,24]},{7:30,8:y,9:25,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},e([8,10,28,32,37,39,40,45,57,58],[2,7],{15:38,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p}),e(x,[2,8]),e(x,[2,10]),e(x,[2,11]),e(x,[2,12]),e(x,[2,13]),e(x,[2,14]),e(x,[2,15]),e(x,[2,16]),e(x,[2,17]),e(x,[2,18]),e(x,[2,19]),e(x,[2,20]),{7:39,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{7:30,8:y,9:40,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,41]},{10:[2,21],28:[1,42]},e(w,[2,23]),e(w,[2,24]),e(w,[2,25]),e(A,k,{44:44,32:[1,43],45:E}),e(w,[2,27],{41:46,43:47,57:M,58:D}),e(w,[2,47],{43:47,34:50,41:51,37:C,57:M,58:D}),{34:53,37:C},{34:54,37:C},{34:55,37:C},{7:56,8:[1,57],14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{7:30,8:y,9:58,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},e(x,[2,9]),{8:[1,59]},{10:[1,60]},{5:[2,4]},{7:30,8:y,9:61,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{7:62,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},e(A,[2,48]),e(A,S,{14:10,15:11,7:63,46:64,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,48:T,49:F,50:B,51:L,52:O,53:I,54:N,55:P,56:R}),e(w,[2,41],{34:74,37:C}),{7:77,8:y,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,33:76,42:75,47:b},e(j,[2,66]),e(j,[2,67]),e(w,[2,46]),e(w,[2,40],{34:78,37:C}),{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:79,39:[1,80]},e(w,[2,28]),e(w,[2,29]),e(w,[2,30]),{8:[1,82]},{7:30,8:y,9:83,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,84]},{7:30,8:y,9:85,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{5:[2,2]},{10:[2,22]},e(w,[2,26]),e(A,[2,51],{45:[1,86]}),e(A,[2,52]),e(A,[2,56]),e(A,[2,57]),e(A,[2,58]),e(A,[2,59]),e(A,[2,60]),e(A,[2,61]),e(A,[2,62]),e(A,[2,63]),e(A,[2,64]),e(w,[2,38]),e(Y,[2,44],{43:47,41:87,57:M,58:D}),e(Y,[2,45],{43:47,41:88,57:M,58:D}),e(A,k,{44:44,45:E}),e(w,[2,39]),{39:[1,89]},e(w,[2,34],{34:90,37:C}),{32:[1,91]},{7:30,8:y,9:92,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,93]},e(A,[2,55]),{10:[1,94]},e(A,S,{46:95,48:T,49:F,50:B,51:L,52:O,53:I,54:N,55:P,56:R}),e(Y,[2,42]),e(Y,[2,43]),e(w,[2,33],{34:96,37:C}),e(w,[2,32]),{7:97,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{10:[1,98]},e(A,[2,54]),{5:[2,3]},e(A,[2,50]),e(w,[2,31]),{28:[1,99],39:[2,37],40:[1,100]},e(A,[2,53]),{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:101},{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:102},{39:[2,35]},{39:[2,36]}],defaultActions:{7:[2,1],41:[2,4],60:[2,2],61:[2,22],94:[2,3],101:[2,35],102:[2,36]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,M,D=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=D()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";M=[];for(A in a[b])this.terminals_[A]&&A>l&&M.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:M})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:return"STYLE";case 1:return"LINKSTYLE";case 2:return"CLASSDEF";case 3:return"CLASS";case 4:return"CLICK";case 5:return 12;case 6:return 13;case 7:return 47;case 8:return 35;case 9:return 36;case 10:return"DIR";case 11:return"DIR";case 12:return"DIR";case 13:return"DIR";case 14:return"DIR";case 15:return"DIR";case 16:return 17;case 17:return 23;case 18:return 18;case 19:return 28;case 20:return 40;case 21:return 32;case 22:return 21;case 23:return 22;case 24:return"ARROW_CROSS";case 25:return 57;case 26:return"ARROW_CIRCLE";case 27:return 58;case 28:return 25;case 29:return 19;case 30:return 20;case 31:return 16;case 32:return"PIPE";case 33:return"PS";case 34:return"PE";case 35:return 37;case 36:return 39;case 37:return 8;case 38:return 10;case 39:return"QUOTE";case 40:return 24;case 41:return"NEWLINE";case 42:return 5}},rules:[/^(?:style\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:digraph\b)/,/^(?:subgraph\b)/,/^(?:node\b)/,/^(?:edge\b)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9])/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:=)/,/^(?:\*)/,/^(?:\.)/,/^(?:--[x])/,/^(?:->)/,/^(?:--[o])/,/^(?:--)/,/^(?:-)/,/^(?:\+)/,/^(?:=)/,/^(?:[\u0021-\u0027\u002A-\u002E\u003F\u0041-\u005A\u0061-\u007A\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)/,/^(?:\n)/,/^(?:$)/],conditions:{INITIAL:{rules:[0,1,2,3,4,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],inclusive:!0}}};return t}();return U.lexer=$,t.prototype=U,U.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("_process"))},{_process:3,fs:1,path:2}],118:[function(t,e,n){(function(r){"use strict";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,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],u=[2,2],o=[1,12],s=[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,38],x=[1,40],w=[1,35],A=[1,39],k=[1,45],E=[1,44],M=[1,36],D=[1,37],C=[1,41],S=[1,42],T=[1,43],F=[1,8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],B=[1,53],L=[1,52],O=[1,54],I=[1,72],N=[1,80],P=[1,81],R=[1,66],j=[1,65],Y=[1,85],U=[1,84],$=[1,82],z=[1,83],q=[1,73],W=[1,68],G=[1,67],H=[1,63],V=[1,75],X=[1,76],Z=[1,77],K=[1,78],Q=[1,79],J=[1,70],tt=[1,69],et=[8,9,11],nt=[8,9,11,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64],rt=[1,115],it=[8,9,10,11,13,15,18,36,38,40,42,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,85,87,88,90,91,93,94,95,96,97],at=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,42,43,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],ut=[1,117],ot=[1,118],st=[8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],ct=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,43,46,50,51,52,53,54,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],lt=[13,18,46,81,85,87,88,90,91,93,94,95,96,97],ht=[13,18,46,49,65,81,85,87,88,90,91,93,94,95,96,97],ft=[1,191],dt=[1,188],pt=[1,195],gt=[1,192],yt=[1,189],mt=[1,196],vt=[1,186],_t=[1,187],bt=[1,190],xt=[1,193],wt=[1,194],At=[1,211],kt=[8,9,11,85],Et=[8,9,10,11,46,71,80,81,83,85,87,88,89,90,91],Mt={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,"(-":40,"-)":41,DIAMOND_START:42,DIAMOND_STOP:43,alphaNumStatement:44,alphaNumToken:45,MINUS:46,linkStatement:47,arrowText:48,TESTSTR:49,"--":50,ARROW_POINT:51,ARROW_CIRCLE:52,ARROW_CROSS:53,ARROW_OPEN:54,"-.":55,DOTTED_ARROW_POINT:56,DOTTED_ARROW_CIRCLE:57,DOTTED_ARROW_CROSS:58,DOTTED_ARROW_OPEN:59,"==":60,THICK_ARROW_POINT:61,THICK_ARROW_CIRCLE:62,THICK_ARROW_CROSS:63,THICK_ARROW_OPEN:64,PIPE:65,textToken:66,STR:67,commentText:68,commentToken:69,keywords:70,STYLE:71,LINKSTYLE:72,CLASSDEF:73,CLASS:74,CLICK:75,textNoTags:76,textNoTagsToken:77,DEFAULT:78,stylesOpt:79,HEX:80,NUM:81,commentStatement:82,PCT:83,style:84,COMMA:85,styleComponent:86,ALPHA:87,COLON:88,UNIT:89,BRKT:90,DOT:91,graphCodeTokens:92,PUNCTUATION:93,UNICODE_TEXT:94,PLUS:95,EQUALS:96,MULT:97,TAG_START:98,TAG_END:99,QUOTE:100,$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:"(-",41:"-)",42:"DIAMOND_START",43:"DIAMOND_STOP",46:"MINUS",49:"TESTSTR",50:"--",51:"ARROW_POINT",52:"ARROW_CIRCLE",53:"ARROW_CROSS",54:"ARROW_OPEN",55:"-.",56:"DOTTED_ARROW_POINT",57:"DOTTED_ARROW_CIRCLE",58:"DOTTED_ARROW_CROSS",59:"DOTTED_ARROW_OPEN",60:"==",61:"THICK_ARROW_POINT",62:"THICK_ARROW_CIRCLE",63:"THICK_ARROW_CROSS",64:"THICK_ARROW_OPEN",65:"PIPE",67:"STR",71:"STYLE",72:"LINKSTYLE",73:"CLASSDEF",74:"CLASS",75:"CLICK",78:"DEFAULT",80:"HEX",81:"NUM",83:"PCT",85:"COMMA",87:"ALPHA",88:"COLON",89:"UNIT",90:"BRKT",91:"DOT",93:"PUNCTUATION",94:"UNICODE_TEXT",95:"PLUS",96:"EQUALS",97:"MULT",98:"TAG_START",99:"TAG_END",100:"QUOTE"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,4],[4,4],[4,4],[4,4],[4,4],[19,2],[19,1],[20,1],[20,1],[20,1],[14,1],[14,1],[14,2],[22,2],[22,2],[22,1],[22,1],[21,2],[21,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,5],[7,4],[24,1],[24,1],[24,1],[23,3],[23,1],[33,4],[33,5],[33,6],[33,7],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,1],[33,2],[35,1],[35,2],[44,1],[44,1],[44,1],[44,1],[34,2],[34,3],[34,3],[34,1],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[48,3],[31,1],[31,2],[31,1],[68,1],[68,2],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[76,1],[76,2],[27,5],[27,5],[28,5],[29,5],[29,7],[29,5],[29,7],[25,5],[25,5],[26,5],[26,5],[82,3],[79,1],[79,3],[84,1],[84,2],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[69,1],[69,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[77,1],[77,1],[77,1],[77,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 2:this.$=[];break;case 3:a[u]!==[]&&a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 57:case 59:case 60:case 92:case 94:case 95:case 108:this.$=a[u];break;case 11:r.setDirection(a[u-1]),this.$=a[u-1];break;case 12:r.setDirection("LR"),this.$=a[u-1];break;case 13:r.setDirection("RL"),this.$=a[u-1];break;case 14:r.setDirection("BT"), -this.$=a[u-1];break;case 15:r.setDirection("TB"),this.$=a[u-1];break;case 30:this.$=a[u-1];break;case 31:case 32:case 33:case 34:case 35:this.$=[];break;case 36:this.$=r.addSubGraph(a[u-1],a[u-3]);break;case 37:this.$=r.addSubGraph(a[u-1],void 0);break;case 41:r.addLink(a[u-2],a[u],a[u-1]),this.$=[a[u-2],a[u]];break;case 42:this.$=[a[u]];break;case 43:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"square");break;case 44:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"square");break;case 45:this.$=a[u-5],r.addVertex(a[u-5],a[u-2],"circle");break;case 46:this.$=a[u-6],r.addVertex(a[u-6],a[u-3],"circle");break;case 47:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"ellipse");break;case 48:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"ellipse");break;case 49:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"round");break;case 50:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"round");break;case 51:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"diamond");break;case 52:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"diamond");break;case 53:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"odd");break;case 54:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"odd");break;case 55:this.$=a[u],r.addVertex(a[u]);break;case 56:this.$=a[u-1],r.addVertex(a[u-1]);break;case 58:case 93:case 96:case 109:this.$=a[u-1]+""+a[u];break;case 61:this.$="v";break;case 62:this.$="-";break;case 63:a[u-1].text=a[u],this.$=a[u-1];break;case 64:case 65:a[u-2].text=a[u-1],this.$=a[u-2];break;case 66:this.$=a[u];break;case 67:this.$={type:"arrow",stroke:"normal",text:a[u-1]};break;case 68:this.$={type:"arrow_circle",stroke:"normal",text:a[u-1]};break;case 69:this.$={type:"arrow_cross",stroke:"normal",text:a[u-1]};break;case 70:this.$={type:"arrow_open",stroke:"normal",text:a[u-1]};break;case 71:this.$={type:"arrow",stroke:"dotted",text:a[u-1]};break;case 72:this.$={type:"arrow_circle",stroke:"dotted",text:a[u-1]};break;case 73:this.$={type:"arrow_cross",stroke:"dotted",text:a[u-1]};break;case 74:this.$={type:"arrow_open",stroke:"dotted",text:a[u-1]};break;case 75:this.$={type:"arrow",stroke:"thick",text:a[u-1]};break;case 76:this.$={type:"arrow_circle",stroke:"thick",text:a[u-1]};break;case 77:this.$={type:"arrow_cross",stroke:"thick",text:a[u-1]};break;case 78:this.$={type:"arrow_open",stroke:"thick",text:a[u-1]};break;case 79:this.$={type:"arrow",stroke:"normal"};break;case 80:this.$={type:"arrow_circle",stroke:"normal"};break;case 81:this.$={type:"arrow_cross",stroke:"normal"};break;case 82:this.$={type:"arrow_open",stroke:"normal"};break;case 83:this.$={type:"arrow",stroke:"dotted"};break;case 84:this.$={type:"arrow_circle",stroke:"dotted"};break;case 85:this.$={type:"arrow_cross",stroke:"dotted"};break;case 86:this.$={type:"arrow_open",stroke:"dotted"};break;case 87:this.$={type:"arrow",stroke:"thick"};break;case 88:this.$={type:"arrow_circle",stroke:"thick"};break;case 89:this.$={type:"arrow_cross",stroke:"thick"};break;case 90:this.$={type:"arrow_open",stroke:"thick"};break;case 91:this.$=a[u-1];break;case 110:case 111:this.$=a[u-4],r.addClass(a[u-2],a[u]);break;case 112:this.$=a[u-4],r.setClass(a[u-2],a[u]);break;case 113:this.$=a[u-4],r.setClickEvent(a[u-2],a[u],void 0,void 0);break;case 114:this.$=a[u-6],r.setClickEvent(a[u-4],a[u-2],void 0,a[u]);break;case 115:this.$=a[u-4],r.setClickEvent(a[u-2],void 0,a[u],void 0);break;case 116:this.$=a[u-6],r.setClickEvent(a[u-4],void 0,a[u-2],a[u]);break;case 117:this.$=a[u-4],r.addVertex(a[u-2],void 0,void 0,a[u]);break;case 118:case 119:case 120:this.$=a[u-4],r.updateLink(a[u-2],a[u]);break;case 122:this.$=[a[u]];break;case 123:a[u-2].push(a[u]),this.$=a[u-2];break;case 125:this.$=a[u-1]+a[u]}},table:[{3:1,4:2,9:n,10:r,12:i},{1:[3]},e(a,u,{5:6}),{4:7,9:n,10:r,12:i},{4:8,9:n,10:r,12:i},{10:[1,9]},{1:[2,1],6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(a,[2,9]),e(a,[2,10]),{13:[1,46],15:[1,47],16:[1,48],17:[1,49],18:[1,50]},e(F,[2,3]),e(F,[2,4]),e(F,[2,5]),e(F,[2,6]),e(F,[2,7]),e(F,[2,8]),{8:B,9:L,11:O,24:51},{8:B,9:L,11:O,24:55},{8:B,9:L,11:O,24:56},{8:B,9:L,11:O,24:57},{8:B,9:L,11:O,24:58},{8:B,9:L,11:O,24:59},{8:B,9:L,10:I,11:O,12:N,13:P,15:R,16:j,17:Y,18:U,24:61,30:$,31:60,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(et,[2,42],{34:86,47:87,50:[1,88],51:[1,91],52:[1,92],53:[1,93],54:[1,94],55:[1,89],56:[1,95],57:[1,96],58:[1,97],59:[1,98],60:[1,90],61:[1,99],62:[1,100],63:[1,101],64:[1,102]}),{10:[1,103]},{10:[1,104]},{10:[1,105]},{10:[1,106]},{10:[1,107]},e(nt,[2,55],{45:32,21:113,44:114,10:rt,13:h,15:[1,112],18:f,36:[1,108],38:[1,109],40:[1,110],42:[1,111],46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T}),e(it,[2,57]),e(it,[2,59]),e(it,[2,60]),e(it,[2,61]),e(it,[2,62]),e(at,[2,150]),e(at,[2,151]),e(at,[2,152]),e(at,[2,153]),e(at,[2,154]),e(at,[2,155]),e(at,[2,156]),e(at,[2,157]),e(at,[2,158]),e(at,[2,159]),e(at,[2,160]),{8:ut,9:ot,10:rt,14:116,21:119},{8:ut,9:ot,10:rt,14:120,21:119},{8:ut,9:ot,10:rt,14:121,21:119},{8:ut,9:ot,10:rt,14:122,21:119},{8:ut,9:ot,10:rt,14:123,21:119},e(F,[2,30]),e(F,[2,38]),e(F,[2,39]),e(F,[2,40]),e(F,[2,31]),e(F,[2,32]),e(F,[2,33]),e(F,[2,34]),e(F,[2,35]),{8:B,9:L,10:I,11:O,12:N,13:P,15:R,16:j,17:Y,18:U,24:124,30:$,32:z,45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(st,u,{5:126}),e(ct,[2,92]),e(ct,[2,94]),e(ct,[2,139]),e(ct,[2,140]),e(ct,[2,141]),e(ct,[2,142]),e(ct,[2,143]),e(ct,[2,144]),e(ct,[2,145]),e(ct,[2,146]),e(ct,[2,147]),e(ct,[2,148]),e(ct,[2,149]),e(ct,[2,97]),e(ct,[2,98]),e(ct,[2,99]),e(ct,[2,100]),e(ct,[2,101]),e(ct,[2,102]),e(ct,[2,103]),e(ct,[2,104]),e(ct,[2,105]),e(ct,[2,106]),e(ct,[2,107]),{13:h,18:f,33:127,35:29,44:30,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(lt,[2,66],{48:128,49:[1,129],65:[1,130]}),{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:131,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:132,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:133,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(ht,[2,79]),e(ht,[2,80]),e(ht,[2,81]),e(ht,[2,82]),e(ht,[2,83]),e(ht,[2,84]),e(ht,[2,85]),e(ht,[2,86]),e(ht,[2,87]),e(ht,[2,88]),e(ht,[2,89]),e(ht,[2,90]),{13:h,18:f,35:134,44:30,45:32,46:p,80:[1,135],81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{78:[1,136],81:[1,137]},{13:h,18:f,35:139,44:30,45:32,46:p,78:[1,138],81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{13:h,18:f,35:140,44:30,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{13:h,18:f,35:141,44:30,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:142,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:144,32:z,38:[1,143],45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:145,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:146,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:147,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(nt,[2,56]),e(it,[2,58]),e(nt,[2,29],{21:148,10:rt}),e(a,[2,11]),e(a,[2,21]),e(a,[2,22]),{9:[1,149]},e(a,[2,12]),e(a,[2,13]),e(a,[2,14]),e(a,[2,15]),e(st,u,{5:150}),e(ct,[2,93]),{6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,32:[1,151],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(et,[2,41]),e(lt,[2,63],{10:[1,152]}),{10:[1,153]},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:154,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,45:71,46:q,50:W,51:[1,155],52:[1,156],53:[1,157],54:[1,158],60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,45:71,46:q,50:W,56:[1,159],57:[1,160],58:[1,161],59:[1,162],60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,45:71,46:q,50:W,60:G,61:[1,163],62:[1,164],63:[1,165],64:[1,166],66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:[1,167],13:h,18:f,44:114,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:[1,168]},{10:[1,169]},{10:[1,170]},{10:[1,171]},{10:[1,172],13:h,18:f,44:114,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:[1,173],13:h,18:f,44:114,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:[1,174],13:h,18:f,44:114,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,37:[1,175],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,31:176,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,39:[1,177],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,41:[1,178],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,43:[1,179],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,37:[1,180],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(nt,[2,28]),e(a,[2,23]),{6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,32:[1,181],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(F,[2,37]),e(lt,[2,65]),e(lt,[2,64]),{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,45:71,46:q,50:W,60:G,65:[1,182],66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(lt,[2,67]),e(lt,[2,68]),e(lt,[2,69]),e(lt,[2,70]),e(lt,[2,71]),e(lt,[2,72]),e(lt,[2,73]),e(lt,[2,74]),e(lt,[2,75]),e(lt,[2,76]),e(lt,[2,77]),e(lt,[2,78]),{10:ft,46:dt,71:pt,79:183,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:197,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:198,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:199,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:200,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:201,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{13:h,18:f,35:202,44:30,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},{13:h,18:f,35:203,44:30,45:32,46:p,67:[1,204],81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(nt,[2,43],{21:205,10:rt}),{10:I,12:N,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,39:[1,206],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T},e(nt,[2,49],{21:207,10:rt}),e(nt,[2,47],{21:208,10:rt}),e(nt,[2,51],{21:209,10:rt}),e(nt,[2,53],{21:210,10:rt}),e(F,[2,36]),e([10,13,18,46,81,85,87,88,90,91,93,94,95,96,97],[2,91]),e(et,[2,117],{85:At}),e(kt,[2,122],{86:212,10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,87:vt,88:_t,89:bt,90:xt,91:wt}),e(Et,[2,124]),e(Et,[2,126]),e(Et,[2,127]),e(Et,[2,128]),e(Et,[2,129]),e(Et,[2,130]),e(Et,[2,131]),e(Et,[2,132]),e(Et,[2,133]),e(Et,[2,134]),e(Et,[2,135]),e(Et,[2,136]),e(et,[2,118],{85:At}),e(et,[2,119],{85:At}),e(et,[2,120],{85:At}),e(et,[2,110],{85:At}),e(et,[2,111],{85:At}),e(et,[2,112],{45:32,44:114,13:h,18:f,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T}),e(et,[2,113],{45:32,44:114,10:[1,213],13:h,18:f,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:M,94:D,95:C,96:S,97:T}),e(et,[2,115],{10:[1,214]}),e(nt,[2,44]),{39:[1,215]},e(nt,[2,50]),e(nt,[2,48]),e(nt,[2,52]),e(nt,[2,54]),{10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,84:216,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},e(Et,[2,125]),{67:[1,217]},{67:[1,218]},e(nt,[2,45],{21:219,10:rt}),e(kt,[2,123],{86:212,10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,87:vt,88:_t,89:bt,90:xt,91:wt}),e(et,[2,114]),e(et,[2,116]),e(nt,[2,46])],defaultActions:{},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,M,D=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=D()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";M=[];for(A in a[b])this.terminals_[A]&&A>l&&M.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:M})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},Dt=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:this.begin("string");break;case 2:this.popState();break;case 3:return"STR";case 4:return 71;case 5:return 78;case 6:return 72;case 7:return 73;case 8:return 74;case 9:return 75;case 10:return 12;case 11:return 30;case 12:return 32;case 13:return 13;case 14:return 13;case 15:return 13;case 16:return 13;case 17:return 13;case 18:return 13;case 19:return 81;case 20:return 90;case 21:return 88;case 22:return 8;case 23:return 85;case 24:return 97;case 25:return 16;case 26:return 15;case 27:return 17;case 28:return 18;case 29:return 53;case 30:return 51;case 31:return 52;case 32:return 54;case 33:return 58;case 34:return 56;case 35:return 57;case 36:return 59;case 37:return 58;case 38:return 56;case 39:return 57;case 40:return 59;case 41:return 63;case 42:return 61;case 43:return 62;case 44:return 64;case 45:return 50;case 46:return 55;case 47:return 60;case 48:return 40;case 49:return 41;case 50:return 46;case 51:return 91;case 52:return 95;case 53:return 83;case 54:return 96;case 55:return 96;case 56:return 87;case 57:return 93;case 58:return 94;case 59:return 65;case 60:return 38;case 61:return 39;case 62:return 36;case 63:return 37;case 64:return 42;case 65:return 43;case 66:return 100;case 67:return 9;case 68:return 10;case 69:return 11}},rules:[/^(?:%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:v\b)/,/^(?:\s*--[x]\s*)/,/^(?:\s*-->\s*)/,/^(?:\s*--[o]\s*)/,/^(?:\s*---\s*)/,/^(?:\s*-\.-[x]\s*)/,/^(?:\s*-\.->\s*)/,/^(?:\s*-\.-[o]\s*)/,/^(?:\s*-\.-\s*)/,/^(?:\s*.-[x]\s*)/,/^(?:\s*\.->\s*)/,/^(?:\s*\.-[o]\s*)/,/^(?:\s*\.-\s*)/,/^(?:\s*==[x]\s*)/,/^(?:\s*==>\s*)/,/^(?:\s*==[o]\s*)/,/^(?:\s*==[\=]\s*)/,/^(?:\s*--\s*)/,/^(?:\s*-\.\s*)/,/^(?:\s*==\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[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])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:\n+)/,/^(?:\s)/,/^(?:$)/],conditions:{string:{rules:[2,3],inclusive:!1},INITIAL:{rules:[0,1,4,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,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69],inclusive:!0}}};return t}();return Mt.lexer=Dt,t.prototype=Mt,Mt.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("_process"))},{_process:3,fs:1,path:2}],119:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=t("moment"),o=new a.Log,s="",c="",l=[],h=[],f="";n.clear=function(){l=[],h=[],f="",c="",m=0,d=void 0,p=void 0,x=[]},n.setDateFormat=function(t){s=t},n.getDateFormat=function(){return s},n.setTitle=function(t){c=t},n.getTitle=function(){return c},n.addSection=function(t){f=t,l.push(t)},n.getTasks=function(){for(var t=A(),e=10,n=0;!t&&e>n;)t=A(),n++;return h=x};var d,p,g=function(t,e,r){r=r.trim();var i=/^after\s+([\d\w\-]+)/,a=i.exec(r.trim());if(null!==a){var s=n.findTaskById(a[1]);if("undefined"==typeof s){var c=new Date;return c.setHours(0,0,0,0),c}return s.endTime}return u(r,e.trim(),!0).isValid()?u(r,e.trim(),!0).toDate():(o.debug("Invalid date:"+r),o.debug("With date format:"+e.trim()),new Date)},y=function(t,e,n){if(n=n.trim(),u(n,e.trim(),!0).isValid())return u(n,e.trim()).toDate();var r=u(t),i=/^([\d]+)([wdhms])/,a=i.exec(n.trim());if(null!==a){switch(a[2]){case"s":r.add(a[1],"seconds");break;case"m":r.add(a[1],"minutes");break;case"h":r.add(a[1],"hours");break;case"d":r.add(a[1],"days");break;case"w":r.add(a[1],"weeks")}return r.toDate()}return r.toDate()},m=0,v=function(t){return"undefined"==typeof t?(m+=1,"task"+m):t},_=function(t,e){var r;r=":"===e.substr(0,1)?e.substr(1,e.length):e;for(var i=r.split(","),a={},u=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 s;for(s=0;sn-e?n+i+1.5*u.sidePadding>o?e+r-5:n+r+5:(n-e)/2+e+r}).attr("y",function(t,r){return r*e+u.barHeight/2+(u.fontSize/2-2)+n}).attr("text-height",i).attr("class",function(t){for(var e=w(t.startTime),n=w(t.endTime),r=this.getBBox().width,i=0,a=0;an-e?n+r+1.5*u.sidePadding>o?"taskTextOutsideLeft taskTextOutside"+i+" "+s:"taskTextOutsideRight taskTextOutside"+i+" "+s:"taskText taskText"+i+" "+s})}function l(t,e,n,a){var o,s=[[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["h1 %I:%M",function(t){return t.getMinutes()}]],c=[["%Y",function(){return!0}]],l=[["%I:%M",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}]];"undefined"!=typeof u.axisFormatter&&(l=[],u.axisFormatter.forEach(function(t){var e=[];e[0]=t[0],e[1]=t[1],l.push(e)})),o=s.concat(l).concat(c);var h=i.svg.axis().scale(w).orient("bottom").tickSize(-a+e+u.gridLineStartPadding,0,0).tickFormat(i.time.format.multi(o));r>7&&230>r&&(h=h.ticks(i.time.monday.range)),_.append("g").attr("class","grid").attr("transform","translate("+t+", "+(a-50)+")").call(h).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em")}function h(t,e){for(var n=[],r=0,i=0;i0))return i[1]*t/2+e;for(var u=0;a>u;u++)return r+=n[a-1][1],i[1]*t/2+r*t+e}).attr("class",function(t){for(var e=0;er;++r)e.hasOwnProperty(t[r])||(e[t[r]]=!0,n.push(t[r]));return n}function p(t){for(var e=t.length,n={};e;)n[t[--e]]=(n[t[e]]||0)+1;return n}function g(t,e){return p(e)[t]||0}n.yy.clear(),n.parse(t);var y=document.getElementById(e);o=y.parentElement.offsetWidth,"undefined"==typeof o&&(o=1200),"undefined"!=typeof u.useWidth&&(o=u.useWidth);var m=n.yy.getTasks(),v=m.length*(u.barHeight+u.barGap)+2*u.topPadding;y.setAttribute("height","100%"),y.setAttribute("viewBox","0 0 "+o+" "+v);var _=i.select("#"+e),b=i.min(m,function(t){return t.startTime}),x=i.max(m,function(t){return t.endTime}),w=i.time.scale().domain([i.min(m,function(t){return t.startTime}),i.max(m,function(t){return t.endTime})]).rangeRound([0,o-150]),A=[];r=a.duration(x-b).asDays();for(var k=0;kl&&M.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:M})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},s=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,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),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;ae[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 10;case 1:break;case 2:break;case 3:break;case 4:return 4;case 5:return 11;case 6:return"date";case 7:return 12;case 8:return 13;case 9:return 14;case 10:return 15;case 11:return":";case 12:return 6;case 13:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\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:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return t}();return o.lexer=s,t.prototype=o,o.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("_process"))},{_process:3,fs:1,path:2}],122:[function(t,e,n){(function(r){"use strict";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=[2,2],r=[1,5],i=[1,7],a=[1,8],u=[1,11],o=[1,12],s=[1,13],c=[1,14],l=[1,16],h=[1,17],f=[1,7,9,10,14,16,18,19,20,21,22,33],d=[7,9,10,14,16,18,19,20,22,33],p=[1,51],g={trace:function(){},yy:{},symbols_:{error:2,start:3,SD:4,document:5,line:6,SPACE:7,statement:8,NL:9,participant:10,actor:11,signal:12,note_statement:13,title:14,text:15,loop:16,restOfLine:17,end:18,opt:19,alt:20,"else":21,note:22,placement:23,text2:24,over:25,actor_pair:26,spaceList:27,",":28,left_of:29,right_of:30,signaltype:31,actors:32,ACTOR:33,SOLID_OPEN_ARROW:34,DOTTED_OPEN_ARROW:35,SOLID_ARROW:36,DOTTED_ARROW:37,SOLID_CROSS:38,DOTTED_CROSS:39,TXT:40,$accept:0,$end:1},terminals_:{2:"error",4:"SD",7:"SPACE",9:"NL",10:"participant",14:"title",15:"text",16:"loop",17:"restOfLine",18:"end",19:"opt",20:"alt",21:"else",22:"note",25:"over",28:",",29:"left_of",30:"right_of",33:"ACTOR",34:"SOLID_OPEN_ARROW",35:"DOTTED_OPEN_ARROW",36:"SOLID_ARROW",37:"DOTTED_ARROW",38:"SOLID_CROSS",39:"DOTTED_CROSS",40:"TXT"},productions_:[0,[3,2],[5,0],[5,2],[6,2],[6,1],[6,1],[8,3],[8,2],[8,2],[8,4],[8,4],[8,4],[8,7],[13,4],[13,4],[27,2],[27,1],[26,3],[26,1],[23,1],[23,1],[12,4],[32,2],[32,1],[11,1],[31,1],[31,1],[31,1],[31,1],[31,1],[31,1],[24,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:return r.apply(a[u]),a[u];case 2:this.$=[];break;case 3:a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 5:this.$=a[u];break;case 6:this.$=[];break;case 7:this.$=a[u-1];break;case 11:a[u-1].unshift({type:"loopStart",loopText:a[u-2],signalType:r.LINETYPE.LOOP_START}),a[u-1].push({type:"loopEnd",loopText:a[u-2],signalType:r.LINETYPE.LOOP_END}),this.$=a[u-1];break;case 12:a[u-1].unshift({type:"optStart",optText:a[u-2],signalType:r.LINETYPE.OPT_START}),a[u-1].push({type:"optEnd",optText:a[u-2],signalType:r.LINETYPE.OPT_END}),this.$=a[u-1];break;case 13:a[u-4].unshift({type:"altStart",altText:a[u-5],signalType:r.LINETYPE.ALT_START}),a[u-4].push({type:"else",altText:a[u-2],signalType:r.LINETYPE.ALT_ELSE}),a[u-4]=a[u-4].concat(a[u-1]),a[u-4].push({type:"altEnd",signalType:r.LINETYPE.ALT_END}),this.$=a[u-4];break;case 14:this.$=[a[u-1],{type:"addNote",placement:a[u-2],actor:a[u-1].actor,text:a[u]}];break;case 15:a[u-2]=[].concat(a[u-1],a[u-1]).slice(0,2),a[u-2][0]=a[u-2][0].actor,a[u-2][1]=a[u-2][1].actor,this.$=[a[u-1],{type:"addNote",placement:r.PLACEMENT.OVER,actor:a[u-2].slice(0,2),text:a[u]}];break;case 18:this.$=[a[u-2],a[u]];break;case 19:this.$=a[u];break;case 20:this.$=r.PLACEMENT.LEFTOF;break;case 21:this.$=r.PLACEMENT.RIGHTOF;break;case 22:this.$=[a[u-3],a[u-1],{type:"addMessage",from:a[u-3].actor,to:a[u-1].actor,signalType:a[u-2],msg:a[u]}];break;case 25:this.$={type:"addActor",actor:a[u]};break;case 26:this.$=r.LINETYPE.SOLID_OPEN;break;case 27:this.$=r.LINETYPE.DOTTED_OPEN;break;case 28:this.$=r.LINETYPE.SOLID;break;case 29:this.$=r.LINETYPE.DOTTED;break;case 30:this.$=r.LINETYPE.SOLID_CROSS;break;case 31:this.$=r.LINETYPE.DOTTED_CROSS;break;case 32:this.$=a[u].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e([1,7,9,10,14,16,19,20,22,33],n,{5:3}),{1:[2,1],6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,22:l,33:h},e(f,[2,3]),{8:18,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,22:l,33:h},e(f,[2,5]),e(f,[2,6]),{11:19,33:h},{9:[1,20]},{9:[1,21]},{7:[1,22]},{17:[1,23]},{17:[1,24]},{17:[1,25]},{31:26,34:[1,27],35:[1,28],36:[1,29],37:[1,30],38:[1,31],39:[1,32]},{23:33,25:[1,34],29:[1,35],30:[1,36]},e([9,28,34,35,36,37,38,39,40],[2,25]),e(f,[2,4]),{9:[1,37]},e(f,[2,8]),e(f,[2,9]),{15:[1,38]},e(d,n,{5:39}),e(d,n,{5:40}),e([7,9,10,14,16,19,20,21,22,33],n,{5:41}),{11:42,33:h},{33:[2,26]},{33:[2,27]},{33:[2,28]},{33:[2,29]},{33:[2,30]},{33:[2,31]},{11:43,33:h},{11:45,26:44,33:h},{33:[2,20]},{33:[2,21]},e(f,[2,7]),{9:[1,46]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,47],19:s,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,48],19:s,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,21:[1,49],22:l,33:h},{24:50,40:p},{24:52,40:p},{24:53,40:p},{28:[1,54],40:[2,19]},e(f,[2,10]),e(f,[2,11]),e(f,[2,12]),{17:[1,55]},{9:[2,22]},{9:[2,32]},{9:[2,14]},{9:[2,15]},{11:56,33:h},e(d,n,{5:57}),{40:[2,18]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,58],19:s,20:c,22:l,33:h},e(f,[2,13])],defaultActions:{27:[2,26],28:[2,27],29:[2,28],30:[2,29],31:[2,30],32:[2,31],35:[2,20],36:[2,21],50:[2,22],51:[2,32],52:[2,14],53:[2,15],56:[2,18]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,M,D=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=D()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";M=[];for(A in a[b])this.terminals_[A]&&A>l&&M.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:M})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},y=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,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),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;ae[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:break;case 2:break;case 3:break;case 4:break;case 5:return 10;case 6:return this.begin("LINE"),16;case 7:return this.begin("LINE"),19;case 8:return this.begin("LINE"),20;case 9:return this.begin("LINE"),21;case 10:return this.popState(),17;case 11:return 18;case 12:return 29;case 13:return 30;case 14:return 25;case 15:return 22;case 16:return 14;case 17:return 4;case 18:return 28;case 19:return 9;case 20:return 33;case 21:return 36;case 22:return 37;case 23:return 34;case 24:return 35;case 25:return 38;case 26:return 39;case 27:return 40;case 28:return 9;case 29:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:participant\b)/i,/^(?:loop\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\->:\n,;]+)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[2,3,10],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29],inclusive:!0}}};return t}();return g.lexer=y,t.prototype=g,g.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("_process"))},{_process:3,fs:1,path:2}],123:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u={},o=[],s=[],c=[],l=new a.Log;n.addActor=function(t,e,n){u[t]={name:e,description:n},o.push(t)},n.addMessage=function(t,e,n,r){s.push({from:t,to:e,message:n,answer:r})},n.addSignal=function(t,e,n,r){l.debug("Adding message from="+t+" to="+e+" message="+n+" type="+r),s.push({from:t,to:e,message:n,type:r})},n.getMessages=function(){return s},n.getActors=function(){return u},n.getActor=function(t){return u[t]},n.getActorKeys=function(){return Object.keys(u)},n.clear=function(){u={},s=[]},n.LINETYPE={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},n.ARROWTYPE={FILLED:0,OPEN:1},n.PLACEMENT={LEFTOF:0,RIGHTOF:1,OVER:2},n.addNote=function(t,e,r){var i={actor:t,placement:e,message:r},a=[].concat(t,t);c.push(i),s.push({from:a[0],to:a[1],message:r,type:n.LINETYPE.NOTE,placement:e})},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)},n.apply=function(t){if(t instanceof Array)t.forEach(function(t){n.apply(t)});else switch(t.type){case"addActor":n.addActor(t.actor,t.actor,t.actor);break;case"addNote":n.addNote(t.actor,t.placement,t.text);break;case"addMessage":n.addSignal(t.from,t.to,t.msg,t.signalType);break;case"loopStart":n.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"optStart":n.addSignal(void 0,void 0,t.optText,t.signalType);break;case"optEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"altStart":n.addSignal(void 0,void 0,t.altText,t.signalType);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)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":126}],124:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),u=t("./parser/sequenceDiagram").parser;u.yy=t("./sequenceDb");var o=t("./svgDraw"),s=t("../../d3"),c=new a.Log,l={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,u=0;this.list.forEach(function(o){u++;var s=a.list.length-u+1;a.updateVal(o,"startx",t-s*l.boxMargin,Math.min),a.updateVal(o,"starty",e-s*l.boxMargin,Math.min),a.updateVal(o,"stopx",r+s*l.boxMargin,Math.max),a.updateVal(o,"stopy",i+s*l.boxMargin,Math.max),a.updateVal(n.bounds.data,"startx",t-s*l.boxMargin,Math.min),a.updateVal(n.bounds.data,"starty",e-s*l.boxMargin,Math.min),a.updateVal(n.bounds.data,"stopx",r+s*l.boxMargin,Math.max),a.updateVal(n.bounds.data,"stopy",i+s*l.boxMargin,Math.max)})},insert:function(t,e,r,i){var a,u,o,s;a=Math.min(t,r),o=Math.max(t,r),u=Math.min(e,i),s=Math.max(e,i),this.updateVal(n.bounds.data,"startx",a,Math.min),this.updateVal(n.bounds.data,"starty",u,Math.min),this.updateVal(n.bounds.data,"stopx",o,Math.max),this.updateVal(n.bounds.data,"stopy",s,Math.max),this.updateLoops(a,u,o,s)},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 h=function(t,e,r,i,a){var u=o.getNoteRect();u.x=e,u.y=r,u.width=a||l.width,u["class"]="note";var s=t.append("g"),c=o.drawRect(s,u),h=o.getTextObj();h.x=e-4,h.y=r-13,h.textMargin=l.noteMargin,h.dy="1em",h.text=i.message,h["class"]="noteText";var f=o.drawText(s,h,u.width-l.noteMargin),d=f[0][0].getBBox().height;!a&&d>l.width?(f.remove(),s=t.append("g"),f=o.drawText(s,h,2*u.width-l.noteMargin),d=f[0][0].getBBox().height,c.attr("width",2*u.width),n.bounds.insert(e,r,e+2*u.width,r+2*l.noteMargin+d)):n.bounds.insert(e,r,e+u.width,r+2*l.noteMargin+d),c.attr("height",d+2*l.noteMargin),n.bounds.bumpVerticalPos(d+2*l.noteMargin)},f=function(t,e,r,i,a){var o,s=t.append("g"),c=e+(r-e)/2,l=s.append("text").attr("x",c).attr("y",i-7).style("text-anchor","middle").attr("class","messageText").text(a.message);o="undefined"!=typeof l[0][0].getBBox?l[0][0].getBBox().width:l[0][0].getBoundingClientRect();var h;if(e===r){h=s.append("path").attr("d","M "+e+","+i+" C "+(e+60)+","+(i-10)+" "+(e+60)+","+(i+30)+" "+e+","+(i+20)),n.bounds.bumpVerticalPos(30);var f=Math.max(o/2,100);n.bounds.insert(e-f,n.bounds.getVerticalPos()-10,r+f,n.bounds.getVerticalPos())}else h=s.append("line"),h.attr("x1",e),h.attr("y1",i),h.attr("x2",r),h.attr("y2",i),n.bounds.insert(e,n.bounds.getVerticalPos()-10,r,n.bounds.getVerticalPos());a.type===u.yy.LINETYPE.DOTTED||a.type===u.yy.LINETYPE.DOTTED_CROSS||a.type===u.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0");var d=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;d=d.replace(/\(/g,"\\("),d=d.replace(/\)/g,"\\)"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(a.type===u.yy.LINETYPE.SOLID||a.type===u.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+d+"#arrowhead)"),(a.type===u.yy.LINETYPE.SOLID_CROSS||a.type===u.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+d+"#crosshead)")};e.exports.drawActors=function(t,e,r,i){var a;for(a=0;a/gi," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.attr("fill",e.fill),"undefined"!=typeof e["class"]&&i.attr("class",e["class"]);var a=i.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(r),"undefined"!=typeof i.textwrap&&i.textwrap({x:e.x,y:e.y,width:n,height:1800},e.textMargin),i},n.drawLabel=function(t,e){var r=n.getNoteRect();r.x=e.x,r.y=e.y,r.width=50,r.height=20,r.fill="#526e52",r.stroke="none",r["class"]="labelBox",n.drawRect(t,r),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,e.fill="white",n.drawText(t,e)};var r=-1;n.drawActor=function(t,e,i,a,u){var o=e+u.width/2,s=t.append("g");0===i&&(r++,s.append("line").attr("id","actor"+r).attr("x1",o).attr("y1",5).attr("x2",o).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var c=n.getNoteRect();c.x=e,c.y=i,c.fill="#eaeaea",c.width=u.width,c.height=u.height,c["class"]="actor",c.rx=3,c.ry=3,n.drawRect(s,c),s.append("text").attr("x",o).attr("y",i+u.height/2+5).attr("class","actor").style("text-anchor","middle").text(a)},n.drawLoop=function(t,e,r,i){var a=t.append("g"),u=function(t,e,n,r){a.append("line").attr("x1",t).attr("y1",e).attr("x2",n).attr("y2",r).attr("stroke-width",2).attr("stroke","#526e52").attr("class","loopLine")};u(e.startx,e.starty,e.stopx,e.starty),u(e.stopx,e.starty,e.stopx,e.stopy),u(e.startx,e.stopy,e.stopx,e.stopy),u(e.startx,e.starty,e.startx,e.stopy),"undefined"!=typeof e.elsey&&u(e.startx,e.elsey,e.stopx,e.elsey);var o=n.getTextObj();o.text=r,o.x=e.startx,o.y=e.starty,o.labelMargin=1.5*i.boxMargin,o["class"]="labelText",o.fill="white",n.drawLabel(a,o),o=n.getTextObj(),o.text="[ "+e.title+" ]",o.x=e.startx+(e.stopx-e.startx)/2,o.y=e.starty+1.5*i.boxMargin,o.anchor="middle",o["class"]="loopText",n.drawText(a,o),"undefined"!=typeof e.elseText&&(o.text="[ "+e.elseText+" ]",o.y=e.elsey+1.5*i.boxMargin,n.drawText(a,o))},n.insertArrowHead=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")},n.insertArrowCrossHead=function(t){var e=t.append("defs"),n=e.append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);n.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"),n.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")},n.getTextObj=function(){var t={x:0,y:0,fill:"black","text-anchor":"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0};return t},n.getNoteRect=function(){var t={x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0};return t}},{}],126:[function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t){var e=t.getUTCHours(),n=t.getUTCMinutes(),r=t.getSeconds(),i=t.getMilliseconds();10>e&&(e="0"+e),10>n&&(n="0"+n),10>r&&(r="0"+r),100>i&&(i="0"+i),10>i&&(i="00"+i);var a=e+":"+n+":"+r+" ("+i+")";return a}var a=function(){function t(t,e){for(var n=0;n=n&&"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log("["+i(new Date)+"] "+t):void 0}},{key:"trace",value:function(t){this.log(t,u.trace)}},{key:"debug",value:function(t){this.log(t,u.debug)}},{key:"info",value:function(t){this.log(t,u.info)}},{key:"warn",value:function(t){this.log(t,u.warn)}},{key:"error",value:function(t){this.log(t,u.error)}}]),t}();n.Log=s},{}],127:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("./logger"),a=r(i),u=new a.Log,o=t("./diagrams/flowchart/graphDb"),s=t("./utils"),c=t("./diagrams/flowchart/flowRenderer"),l=t("./diagrams/sequenceDiagram/sequenceRenderer"),h=t("./diagrams/example/exampleRenderer"),f=t("./diagrams/example/parser/example"),d=t("./diagrams/flowchart/parser/flow"),p=t("./diagrams/flowchart/parser/dot"),g=t("./diagrams/sequenceDiagram/parser/sequenceDiagram"),y=t("./diagrams/sequenceDiagram/sequenceDb"),m=t("./diagrams/example/exampleDb"),v=t("./diagrams/gantt/ganttRenderer"),_=t("./diagrams/gantt/parser/gantt"),b=t("./diagrams/gantt/ganttDb"),x=t("./diagrams/classDiagram/parser/classDiagram"),w=t("./diagrams/classDiagram/classRenderer"),A=t("./diagrams/classDiagram/classDb"),k=t("./d3"),E={logLevel:5,cloneCssStyles:!0,startOnLoad:!0,flowchart:{htmlLabels:!0,useMaxWidth:!0},sequenceDiagram:{diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0},gantt:{titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,sidePadding:75,gridLineStartPadding:35,fontSize:11,fontFamily:'"Open-Sans", "sans-serif"',numberSectionStyles:3,axisFormatter:[["%I:%M",function(t){return t.getHours()}],["w. %U",function(t){return 1==t.getDay()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%m-%y",function(t){return t.getMonth()}]]}};a.setLogLevel(E.logLevel);var M=function(t){var e,n=s.detectType(t);switch(n){case"graph":e=d,e.parser.yy=o;break;case"dotGraph":e=p,e.parser.yy=o;break;case"sequenceDiagram":e=g,e.parser.yy=y;break;case"info":e=f,e.parser.yy=m;break;case"gantt":e=_,e.parser.yy=b;break;case"classDiagram":e=x,e.parser.yy=A}try{return e.parse(t),!0}catch(r){return!1}};n.parse=M,n.version=function(){return t("../package.json").version},n.encodeEntities=function(t){var e=t;return e=e.replace(/style.*:\S*#.*;/g,function(t){var e=t.substring(0,t.length-1);return e}),e=e.replace(/classDef.*:\S*#.*;/g,function(t){var e=t.substring(0,t.length-1);return e}),e=e.replace(/#\w+\;/g,function(t){var e=t.substring(1,t.length-1),n=/^\+?\d+$/.test(e);return n?"fl°°"+e+"¶ß":"fl°"+e+"¶ß"})},n.decodeEntities=function(t){var e=t;return e=e.replace(/\fl\°\°/g,function(){return"&#"}),e=e.replace(/\fl\°/g,function(){return"&"}),e=e.replace(/¶ß/g,function(){return";"})};var D=function(t,e,r,i){"undefined"!=typeof i?k.select(i).append("div").attr("id","d"+t).append("svg").attr("id",t).attr("width","100%").attr("xmlns","http://www.w3.org/2000/svg").append("g"):k.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=e,e=n.encodeEntities(e);var a=k.select("#d"+t).node(),f=s.detectType(e),d={};switch(f){case"graph":c.setConf(E.flowchart),c.draw(e,t,!1),E.cloneCssStyles&&(d=c.getClasses(e,!1),s.cloneCssStyles(a.firstChild,d));break;case"dotGraph":c.setConf(E.flowchart),c.draw(e,t,!0),E.cloneCssStyles&&(d=c.getClasses(e,!0),s.cloneCssStyles(a.firstChild,d));break;case"sequenceDiagram":l.setConf(E.sequenceDiagram),l.draw(e,t),E.cloneCssStyles&&s.cloneCssStyles(a.firstChild,[]);break;case"gantt":v.setConf(E.gantt),v.draw(e,t),E.cloneCssStyles&&s.cloneCssStyles(a.firstChild,[]);break;case"classDiagram":w.setConf(E.gantt),w.draw(e,t),E.cloneCssStyles&&s.cloneCssStyles(a.firstChild,[]);break;case"info":h.draw(e,t,n.version()),E.cloneCssStyles&&s.cloneCssStyles(a.firstChild,[])}k.select("#d"+t).selectAll("foreignobject div").attr("xmlns","http://www.w3.org/1999/xhtml");var p=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;p=p.replace(/\(/g,"\\("),p=p.replace(/\)/g,"\\)");var g=k.select("#d"+t).node().innerHTML.replace(/url\(#arrowhead/g,"url("+p+"#arrowhead","g");g=n.decodeEntities(g),"undefined"!=typeof r?r(g,o.bindFunctions):u.warn("CB = undefined");var y=k.select("#d"+t).node();null!==y&&"function"==typeof y.remove&&k.select("#d"+t).node().remove()};n.render=function(t,e,n,r){"undefined"==typeof document||D(t,e,n,r)};var C=function(t){var e,n=Object.keys(t);for(e=0;e0&&(r+=n.selectorText+" { "+n.style.cssText+" }\n")}}catch(l){"undefined"!=typeof n&&u.warn('Invalid CSS selector "'+n.selectorText+'"',l)}var h="",f="";for(var d in e)e.hasOwnProperty(d)&&"undefined"!=typeof d&&("default"===d?(e["default"].styles instanceof Array&&(h+="#"+t.id.trim()+" .node>rect { "+e[d].styles.join("; ")+"; }\n"),e["default"].nodeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .node text { "+e[d].nodeLabelStyles.join("; ")+"; }\n"),e["default"].edgeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .edgeLabel text { "+e[d].edgeLabelStyles.join("; ")+"; }\n"),e["default"].clusterStyles instanceof Array&&(h+="#"+t.id.trim()+" .cluster rect { "+e[d].clusterStyles.join("; ")+"; }\n")):e[d].styles instanceof Array&&(f+="#"+t.id.trim()+" ."+d+">rect { "+e[d].styles.join("; ")+"; }\n"));if(""!==r||""!==h||""!==f){var p=document.createElement("style");p.setAttribute("type","text/css"),p.setAttribute("title","mermaid-svg-internal-css"),p.innerHTML="/* */\n",t.insertBefore(p,t.firstChild)}};n.cloneCssStyles=s},{"./logger":126}]},{},[127])(127)}); \ No newline at end of file +}function Ae(){return+this._d-6e4*(this._offset||0)}function ke(){return Math.floor(+this/1e3)}function Ee(){return this._offset?new Date(+this):this._d}function De(){var t=this;return[t.year(),t.month(),t.date(),t.hour(),t.minute(),t.second(),t.millisecond()]}function Me(){var t=this;return{years:t.year(),months:t.month(),date:t.date(),hours:t.hours(),minutes:t.minutes(),seconds:t.seconds(),milliseconds:t.milliseconds()}}function Ce(){return f(this)}function Se(){return s({},h(this))}function Te(){return h(this).overflow}function Fe(t,e){N(0,[t,t.length],0,e)}function Be(t,e,n){return ht(Ft([t,11,31+e-n]),e,n).week}function Le(t){var e=ht(this,this.localeData()._week.dow,this.localeData()._week.doy).year;return null==t?e:this.add(t-e,"y")}function Oe(t){var e=ht(this,1,4).year;return null==t?e:this.add(t-e,"y")}function Ne(){return Be(this.year(),1,4)}function Ie(){var t=this.localeData()._week;return Be(this.year(),t.dow,t.doy)}function Pe(t){return null==t?Math.ceil((this.month()+1)/3):this.month(3*(t-1)+this.month()%3)}function Re(t,e){return"string"!=typeof t?t:isNaN(t)?(t=e.weekdaysParse(t),"number"==typeof t?t:null):parseInt(t,10)}function je(t){return this._weekdays[t.day()]}function Ye(t){return this._weekdaysShort[t.day()]}function Ue(t){return this._weekdaysMin[t.day()]}function $e(t){var e,n,r;for(this._weekdaysParse=this._weekdaysParse||[],e=0;7>e;e++)if(this._weekdaysParse[e]||(n=Ft([2e3,1]).day(e),r="^"+this.weekdays(n,"")+"|^"+this.weekdaysShort(n,"")+"|^"+this.weekdaysMin(n,""),this._weekdaysParse[e]=new RegExp(r.replace(".",""),"i")),this._weekdaysParse[e].test(t))return e}function ze(t){var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=Re(t,this.localeData()),this.add(t-e,"d")):e}function qe(t){var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")}function We(t){return null==t?this.day()||7:this.day(this.day()%7?t:t-7)}function Ge(t,e){N(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}function He(t,e){return e._meridiemParse}function Ve(t){return"p"===(t+"").toLowerCase().charAt(0)}function Xe(t,e,n){return t>11?n?"pm":"PM":n?"am":"AM"}function Ze(t,e){e[pr]=v(1e3*("0."+t))}function Ke(){return this._isUTC?"UTC":""}function Qe(){return this._isUTC?"Coordinated Universal Time":""}function Je(t){return Ft(1e3*t)}function tn(){return Ft.apply(null,arguments).parseZone()}function en(t,e,n){var r=this._calendar[t];return"function"==typeof r?r.call(e,n):r}function nn(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.replace(/MMMM|MM|DD|dddd/g,function(t){return t.slice(1)}),this._longDateFormat[t])}function rn(){return this._invalidDate}function an(t){return this._ordinal.replace("%d",t)}function un(t){return t}function on(t,e,n,r){var i=this._relativeTime[n];return"function"==typeof i?i(t,e,n,r):i.replace(/%d/i,t)}function sn(t,e){var n=this._relativeTime[t>0?"future":"past"];return"function"==typeof n?n(e):n.replace(/%s/i,e)}function cn(t){var e,n;for(n in t)e=t[n],"function"==typeof e?this[n]=e:this["_"+n]=e;this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function ln(t,e,n,r){var i=D(),a=c().set(r,e);return i[n](a,t)}function hn(t,e,n,r,i){if("number"==typeof t&&(e=t,t=void 0),t=t||"",null!=e)return ln(t,e,n,i);var a,u=[];for(a=0;r>a;a++)u[a]=ln(t,a,n,i);return u}function fn(t,e){return hn(t,e,"months",12,"month")}function dn(t,e){return hn(t,e,"monthsShort",12,"month")}function pn(t,e){return hn(t,e,"weekdays",7,"day")}function gn(t,e){return hn(t,e,"weekdaysShort",7,"day")}function yn(t,e){return hn(t,e,"weekdaysMin",7,"day")}function mn(){var t=this._data;return this._milliseconds=Kr(this._milliseconds),this._days=Kr(this._days),this._months=Kr(this._months),t.milliseconds=Kr(t.milliseconds),t.seconds=Kr(t.seconds),t.minutes=Kr(t.minutes),t.hours=Kr(t.hours),t.months=Kr(t.months),t.years=Kr(t.years),this}function vn(t,e,n,r){var i=Qt(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function _n(t,e){return vn(this,t,e,1)}function bn(t,e){return vn(this,t,e,-1)}function xn(t){return 0>t?Math.floor(t):Math.ceil(t)}function wn(){var t,e,n,r,i,a=this._milliseconds,u=this._days,o=this._months,s=this._data;return a>=0&&u>=0&&o>=0||0>=a&&0>=u&&0>=o||(a+=864e5*xn(kn(o)+u),u=0,o=0),s.milliseconds=a%1e3,t=m(a/1e3),s.seconds=t%60,e=m(t/60),s.minutes=e%60,n=m(e/60),s.hours=n%24,u+=m(n/24),i=m(An(u)),o+=i,u-=xn(kn(i)),r=m(o/12),o%=12,s.days=u,s.months=o,s.years=r,this}function An(t){return 4800*t/146097}function kn(t){return 146097*t/4800}function En(t){var e,n,r=this._milliseconds;if(t=C(t),"month"===t||"year"===t)return e=this._days+r/864e5,n=this._months+An(e),"month"===t?n:n/12;switch(e=this._days+Math.round(kn(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return 24*e+r/36e5;case"minute":return 1440*e+r/6e4;case"second":return 86400*e+r/1e3;case"millisecond":return Math.floor(864e5*e)+r;default:throw new Error("Unknown unit "+t)}}function Dn(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function Mn(t){return function(){return this.as(t)}}function Cn(t){return t=C(t),this[t+"s"]()}function Sn(t){return function(){return this._data[t]}}function Tn(){return m(this.days()/7)}function Fn(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}function Bn(t,e,n){var r=Qt(t).abs(),i=di(r.as("s")),a=di(r.as("m")),u=di(r.as("h")),o=di(r.as("d")),s=di(r.as("M")),c=di(r.as("y")),l=i0,l[4]=n,Fn.apply(null,l)}function Ln(t,e){return void 0===pi[t]?!1:void 0===e?pi[t]:(pi[t]=e,!0)}function On(t){var e=this.localeData(),n=Bn(this,!t,e);return t&&(n=e.pastFuture(+this,n)),e.postformat(n)}function Nn(){var t,e,n,r=gi(this._milliseconds)/1e3,i=gi(this._days),a=gi(this._months);t=m(r/60),e=m(t/60),r%=60,t%=60,n=m(a/12),a%=12;var u=n,o=a,s=i,c=e,l=t,h=r,f=this.asSeconds();return f?(0>f?"-":"")+"P"+(u?u+"Y":"")+(o?o+"M":"")+(s?s+"D":"")+(c||l||h?"T":"")+(c?c+"H":"")+(l?l+"M":"")+(h?h+"S":""):"P0D"}var In,Pn,Rn=n.momentProperties=[],jn=!1,Yn={},Un={},$n=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,zn=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,qn={},Wn={},Gn=/\d/,Hn=/\d\d/,Vn=/\d{3}/,Xn=/\d{4}/,Zn=/[+-]?\d{6}/,Kn=/\d\d?/,Qn=/\d{1,3}/,Jn=/\d{1,4}/,tr=/[+-]?\d{1,6}/,er=/\d+/,nr=/[+-]?\d+/,rr=/Z|[+-]\d\d:?\d\d/gi,ir=/[+-]?\d+(\.\d{1,3})?/,ar=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,ur={},or={},sr=0,cr=1,lr=2,hr=3,fr=4,dr=5,pr=6;N("M",["MM",2],"Mo",function(){return this.month()+1}),N("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),N("MMMM",0,0,function(t){return this.localeData().months(this,t)}),M("month","M"),U("M",Kn),U("MM",Kn,Hn),U("MMM",ar),U("MMMM",ar),q(["M","MM"],function(t,e){e[cr]=v(t)-1}),q(["MMM","MMMM"],function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);null!=i?e[cr]=i:h(n).invalidMonth=t});var gr="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),yr="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),mr={};n.suppressDeprecationWarnings=!1;var vr=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,_r=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],br=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],xr=/^\/?Date\((\-?\d+)/i;n.createFromInputFallback=nt("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),N(0,["YY",2],0,function(){return this.year()%100}),N(0,["YYYY",4],0,"year"),N(0,["YYYYY",5],0,"year"),N(0,["YYYYYY",6,!0],0,"year"),M("year","y"),U("Y",nr),U("YY",Kn,Hn),U("YYYY",Jn,Xn),U("YYYYY",tr,Zn),U("YYYYYY",tr,Zn),q(["YYYYY","YYYYYY"],sr),q("YYYY",function(t,e){e[sr]=2===t.length?n.parseTwoDigitYear(t):v(t)}),q("YY",function(t,e){e[sr]=n.parseTwoDigitYear(t)}),n.parseTwoDigitYear=function(t){return v(t)+(v(t)>68?1900:2e3)};var wr=T("FullYear",!1);N("w",["ww",2],"wo","week"),N("W",["WW",2],"Wo","isoWeek"),M("week","w"),M("isoWeek","W"),U("w",Kn),U("ww",Kn,Hn),U("W",Kn),U("WW",Kn,Hn),W(["w","ww","W","WW"],function(t,e,n,r){e[r.substr(0,1)]=v(t)});var Ar={dow:0,doy:6};N("DDD",["DDDD",3],"DDDo","dayOfYear"),M("dayOfYear","DDD"),U("DDD",Qn),U("DDDD",Vn),q(["DDD","DDDD"],function(t,e,n){n._dayOfYear=v(t)}),n.ISO_8601=function(){};var kr=nt("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var t=Ft.apply(null,arguments);return this>t?this:t}),Er=nt("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var t=Ft.apply(null,arguments);return t>this?this:t});Pt("Z",":"),Pt("ZZ",""),U("Z",rr),U("ZZ",rr),q(["Z","ZZ"],function(t,e,n){n._useUTC=!0,n._tzm=Rt(t)});var Dr=/([\+\-]|\d\d)/gi;n.updateOffset=function(){};var Mr=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Cr=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/;Qt.fn=Nt.prototype;var Sr=ne(1,"add"),Tr=ne(-1,"subtract");n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var Fr=nt("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return void 0===t?this.localeData():this.locale(t)});N(0,["gg",2],0,function(){return this.weekYear()%100}),N(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Fe("gggg","weekYear"),Fe("ggggg","weekYear"),Fe("GGGG","isoWeekYear"),Fe("GGGGG","isoWeekYear"),M("weekYear","gg"),M("isoWeekYear","GG"),U("G",nr),U("g",nr),U("GG",Kn,Hn),U("gg",Kn,Hn),U("GGGG",Jn,Xn),U("gggg",Jn,Xn),U("GGGGG",tr,Zn),U("ggggg",tr,Zn),W(["gggg","ggggg","GGGG","GGGGG"],function(t,e,n,r){e[r.substr(0,2)]=v(t)}),W(["gg","GG"],function(t,e,r,i){e[i]=n.parseTwoDigitYear(t)}),N("Q",0,0,"quarter"),M("quarter","Q"),U("Q",Gn),q("Q",function(t,e){e[cr]=3*(v(t)-1)}),N("D",["DD",2],"Do","date"),M("date","D"),U("D",Kn),U("DD",Kn,Hn),U("Do",function(t,e){return t?e._ordinalParse:e._ordinalParseLenient}),q(["D","DD"],lr),q("Do",function(t,e){e[lr]=v(t.match(Kn)[0],10)});var Br=T("Date",!0);N("d",0,"do","day"),N("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),N("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),N("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),N("e",0,0,"weekday"),N("E",0,0,"isoWeekday"),M("day","d"),M("weekday","e"),M("isoWeekday","E"),U("d",Kn),U("e",Kn),U("E",Kn),U("dd",ar),U("ddd",ar),U("dddd",ar),W(["dd","ddd","dddd"],function(t,e,n){var r=n._locale.weekdaysParse(t);null!=r?e.d=r:h(n).invalidWeekday=t}),W(["d","e","E"],function(t,e,n,r){e[r]=v(t)});var Lr="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Or="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Nr="Su_Mo_Tu_We_Th_Fr_Sa".split("_");N("H",["HH",2],0,"hour"),N("h",["hh",2],0,function(){return this.hours()%12||12}),Ge("a",!0),Ge("A",!1),M("hour","h"),U("a",He),U("A",He),U("H",Kn),U("h",Kn),U("HH",Kn,Hn),U("hh",Kn,Hn),q(["H","HH"],hr),q(["a","A"],function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t}),q(["h","hh"],function(t,e,n){e[hr]=v(t),h(n).bigHour=!0});var Ir=/[ap]\.?m?\.?/i,Pr=T("Hours",!0);N("m",["mm",2],0,"minute"),M("minute","m"),U("m",Kn),U("mm",Kn,Hn),q(["m","mm"],fr);var Rr=T("Minutes",!1);N("s",["ss",2],0,"second"),M("second","s"),U("s",Kn),U("ss",Kn,Hn),q(["s","ss"],dr);var jr=T("Seconds",!1);N("S",0,0,function(){return~~(this.millisecond()/100)}),N(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),N(0,["SSS",3],0,"millisecond"),N(0,["SSSS",4],0,function(){return 10*this.millisecond()}),N(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),N(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),N(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),N(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),N(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),M("millisecond","ms"),U("S",Qn,Gn),U("SS",Qn,Hn),U("SSS",Qn,Vn);var Yr;for(Yr="SSSS";Yr.length<=9;Yr+="S")U(Yr,er);for(Yr="S";Yr.length<=9;Yr+="S")q(Yr,Ze);var Ur=T("Milliseconds",!1);N("z",0,0,"zoneAbbr"),N("zz",0,0,"zoneName");var $r=g.prototype;$r.add=Sr,$r.calendar=ie,$r.clone=ae,$r.diff=le,$r.endOf=we,$r.format=pe,$r.from=ge,$r.fromNow=ye,$r.to=me,$r.toNow=ve,$r.get=L,$r.invalidAt=Te,$r.isAfter=ue,$r.isBefore=oe,$r.isBetween=se,$r.isSame=ce,$r.isValid=Ce,$r.lang=Fr,$r.locale=_e,$r.localeData=be,$r.max=Er,$r.min=kr,$r.parsingFlags=Se,$r.set=L,$r.startOf=xe,$r.subtract=Tr,$r.toArray=De,$r.toObject=Me,$r.toDate=Ee,$r.toISOString=de,$r.toJSON=de,$r.toString=fe,$r.unix=ke,$r.valueOf=Ae,$r.year=wr,$r.isLeapYear=lt,$r.weekYear=Le,$r.isoWeekYear=Oe,$r.quarter=$r.quarters=Pe,$r.month=Q,$r.daysInMonth=J,$r.week=$r.weeks=gt,$r.isoWeek=$r.isoWeeks=yt,$r.weeksInYear=Ie,$r.isoWeeksInYear=Ne,$r.date=Br,$r.day=$r.days=ze,$r.weekday=qe,$r.isoWeekday=We,$r.dayOfYear=vt,$r.hour=$r.hours=Pr,$r.minute=$r.minutes=Rr,$r.second=$r.seconds=jr,$r.millisecond=$r.milliseconds=Ur,$r.utcOffset=Ut,$r.utc=zt,$r.local=qt,$r.parseZone=Wt,$r.hasAlignedHourOffset=Gt,$r.isDST=Ht,$r.isDSTShifted=Vt,$r.isLocal=Xt,$r.isUtcOffset=Zt,$r.isUtc=Kt,$r.isUTC=Kt,$r.zoneAbbr=Ke,$r.zoneName=Qe,$r.dates=nt("dates accessor is deprecated. Use date instead.",Br),$r.months=nt("months accessor is deprecated. Use month instead",Q),$r.years=nt("years accessor is deprecated. Use year instead",wr),$r.zone=nt("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",$t);var zr=$r,qr={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},Wr={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"},Gr="Invalid date",Hr="%d",Vr=/\d{1,2}/,Xr={future:"in %s",past:"%s ago",s:"a few 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"},Zr=b.prototype;Zr._calendar=qr,Zr.calendar=en,Zr._longDateFormat=Wr,Zr.longDateFormat=nn,Zr._invalidDate=Gr,Zr.invalidDate=rn,Zr._ordinal=Hr,Zr.ordinal=an,Zr._ordinalParse=Vr,Zr.preparse=un,Zr.postformat=un,Zr._relativeTime=Xr,Zr.relativeTime=on,Zr.pastFuture=sn,Zr.set=cn,Zr.months=V,Zr._months=gr,Zr.monthsShort=X,Zr._monthsShort=yr,Zr.monthsParse=Z,Zr.week=ft,Zr._week=Ar,Zr.firstDayOfYear=pt,Zr.firstDayOfWeek=dt,Zr.weekdays=je,Zr._weekdays=Lr,Zr.weekdaysMin=Ue,Zr._weekdaysMin=Nr,Zr.weekdaysShort=Ye,Zr._weekdaysShort=Or,Zr.weekdaysParse=$e,Zr.isPM=Ve,Zr._meridiemParse=Ir,Zr.meridiem=Xe,k("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,n=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+n}}),n.lang=nt("moment.lang is deprecated. Use moment.locale instead.",k),n.langData=nt("moment.langData is deprecated. Use moment.localeData instead.",D);var Kr=Math.abs,Qr=Mn("ms"),Jr=Mn("s"),ti=Mn("m"),ei=Mn("h"),ni=Mn("d"),ri=Mn("w"),ii=Mn("M"),ai=Mn("y"),ui=Sn("milliseconds"),oi=Sn("seconds"),si=Sn("minutes"),ci=Sn("hours"),li=Sn("days"),hi=Sn("months"),fi=Sn("years"),di=Math.round,pi={s:45,m:45,h:22,d:26,M:11},gi=Math.abs,yi=Nt.prototype;yi.abs=mn,yi.add=_n,yi.subtract=bn,yi.as=En,yi.asMilliseconds=Qr,yi.asSeconds=Jr,yi.asMinutes=ti,yi.asHours=ei,yi.asDays=ni,yi.asWeeks=ri,yi.asMonths=ii,yi.asYears=ai,yi.valueOf=Dn,yi._bubble=wn,yi.get=Cn,yi.milliseconds=ui,yi.seconds=oi,yi.minutes=si,yi.hours=ci,yi.days=li,yi.weeks=Tn,yi.months=hi,yi.years=fi,yi.humanize=On,yi.toISOString=Nn,yi.toString=Nn,yi.toJSON=Nn,yi.locale=_e,yi.localeData=be,yi.toIsoString=nt("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Nn),yi.lang=Fr,N("X",0,0,"unix"),N("x",0,0,"valueOf"),U("x",nr),U("X",ir),q("X",function(t,e,n){n._d=new Date(1e3*parseFloat(t,10))}),q("x",function(t,e,n){n._d=new Date(v(t))}),n.version="2.10.6",r(Ft),n.fn=zr,n.min=Lt,n.max=Ot,n.utc=c,n.unix=Je,n.months=fn,n.isDate=a,n.locale=k,n.invalid=d,n.duration=Qt,n.isMoment=y,n.weekdays=pn,n.parseZone=tn,n.localeData=D,n.isDuration=It,n.monthsShort=dn,n.weekdaysMin=yn,n.defineLocale=E,n.weekdaysShort=gn,n.normalizeUnits=C,n.relativeTimeThreshold=Ln;var mi=n;return mi})},{}],106:[function(t,e){e.exports={name:"mermaid",version:"0.5.5",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:{live:"live-server ./test/examples",lint:"node node_modules/eslint/bin/eslint.js src",jison:"gulp jison_legacy",watch:"source ./scripts/watch.sh",doc:"rm -r build;rm -r dist/www;gulp vartree;cp dist/www/all.html ../mermaid-pages/index.html;cp dist/mermaid.js ../mermaid-pages/javascripts/lib;cp dist/mermaid.forest.css ../mermaid-pages/stylesheets",tape:"node node_modules/.bin/tape test/cli_test-*.js",jasmine:"npm run jison &&node node_modules/jasmine-es6/bin/jasmine.js",posttest:"npm run jison",test:"npm run dist && npm run jasmine && npm run tape","dist-slim-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.slim.js -x d3 && cat dist/mermaid.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.slim.min.js","dist-slim-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.slim.js -x d3 && cat dist/mermaidAPI.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.slim.min.js","dist-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.js && cat dist/mermaid.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.min.js","dist-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.js && cat dist/mermaidAPI.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.min.js",dist:"npm run dist-slim-mermaid;npm run dist-slim-mermaidAPI; npm run dist-mermaid;npm run dist-mermaidAPI"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"3.5.6",dagre:"^0.7.4","dagre-d3":"0.4.10",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","babel-eslint":"^4.1.3",babelify:"^6.4.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4",dateformat:"^1.0.11",dox:"^0.8.0",eslint:"^1.6.0","eslint-watch":"^2.1.2","event-stream":"^3.2.0",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.9.0","gulp-bower":"0.0.10","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-dox":"^0.1.6","gulp-ext-replace":"^0.2.0","gulp-filelog":"^0.4.1","gulp-front-matter":"^1.2.3","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~2.1.0","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-marked":"^1.0.0","gulp-mdvars":"^2.0.0","gulp-qunit":"~1.2.1","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1","gulp-vartree":"^2.0.1","hogan.js":"^3.0.2",jasmine:"2.3.2","jasmine-es6":"0.0.18",jison:"zaach/jison",jsdom:"^7.0.2","jshint-stylish":"^2.0.1","map-stream":"0.0.6",marked:"^0.3.2","mock-browser":"^0.91.34",path:"^0.4.9",phantomjs:"^1.9.18",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3",testdom:"^2.0.0",uglifyjs:"^2.4.10","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],107:[function(t,e){"use strict";var n;if(t)try{n=t("d3")}catch(r){}n||(n=window.d3),e.exports=n,function(){var t=!1;if(t="tspans",n.selection.prototype.textwrap)return!1;if("undefined"==typeof t)var t=!1;n.selection.prototype.textwrap=n.selection.enter.prototype.textwrap=function(e,r){var i,r=parseInt(r)||0,a=this,u=function(t){var e=t[0][0],r=e.tagName.toString();if("rect"!==r)return!1;var i={};return i.x=n.select(e).attr("x")||0,i.y=n.select(e).attr("y")||0,i.width=n.select(e).attr("width")||0,i.height=n.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)||"[object Array]"===Object.prototype.toString.call(t)){var e=u(t);return e}return!1},s=function(t,e){var n=t;return 0!==e&&(n.x=parseInt(n.x)+e,n.y=parseInt(n.y)+e,n.width-=2*e,n.height-=2*e),n},c=o(e);if(r&&(c=s(c,r)),0!=a.length&&n&&e&&c){e=c;var l,h=function(t){var r=n.select(t[0].parentNode),a=r.select("text"),u=a.style("line-height"),o=a.text();a.remove();var s=r.append("foreignObject");s.attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);var c=s.append("xhtml:div").attr("class","wrapped");c.style("height",e.height).style("width",e.width).html(o),u&&c.style("line-height",u),i=r.select("foreignObject")},f=function(t){var a,u=t[0],o=u.parentNode,s=n.select(u),c=u.getBBox().height,l=u.getBBox().width,h=c,f=s.style("line-height");if(a=f&&parseInt(f)?parseInt(f.replace("px","")):h,l>e.width){var d=s.text();if(s.text(""),d){var p,g;if(-1!==d.indexOf(" ")){var p=" ";g=d.split(" ")}else{p="";var y=d.length,m=Math.ceil(l/e.width),v=Math.floor(y/m);v*m>=y||m++;for(var _,b,g=[],x=0;m>x;x++)b=x*v,_=d.substr(b,v),g.push(_)}for(var w=[],A=0,k={},x=0;xe.width&&M&&""!==M&&(A+=C,k={string:M,width:C,offset:A},w.push(k),s.text(""),s.text(D),x==g.length-1&&(E=D,s.text(E),S=u.getComputedTextLength())),x==g.length-1){s.text("");var T=E;T&&""!==T&&(S-A>0&&(S-=A),k={string:T,width:S,offset:A},w.push(k))}}var F;s.text("");for(var x=0;x0){w[x-1]}x*a0?a:void 0}),F.attr("x",function(){var t=e.x;return r&&(t+=r),t}))}}}s.attr("y",function(){var t=e.y;return a&&(t+=a),r&&(t+=r),t}),s.attr("x",function(){var t=e.x;return r&&(t+=r),t}),i=n.select(o).selectAll("text")};t&&("foreignobjects"==t?l=h:"tspans"==t&&(l=f)),t||(l="undefined"!=typeof SVGForeignObjectElement?h:f);for(var d=0;d "+t.w+": "+JSON.stringify(u.edge(t))),p(i,u.edge(t),u.edge(t).relation)}),i.attr("height","100%"),i.attr("width","100%")}},{"../../d3":107,"../../logger":126,"./classDb":108,"./parser/classDiagram":110,dagre:54}],110:[function(t,e,n){(function(r){"use strict";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,11],r=[1,12],i=[1,13],a=[1,15],u=[1,16],o=[1,17],s=[6,8],c=[1,26],l=[1,27],h=[1,28],f=[1,29],d=[1,30],p=[1,31],g=[6,8,13,17,23,26,27,28,29,30,31],y=[6,8,13,17,23,26,27,28,29,30,31,45,46,47],m=[23,45,46,47],v=[23,30,31,45,46,47],_=[23,26,27,28,29,45,46,47],b=[6,8,13],x=[1,46],w={trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,CLASS_DIAGRAM:5,NEWLINE:6,statements:7,EOF:8,statement:9,className:10,alphaNumToken:11,relationStatement:12,LABEL:13,classStatement:14,methodStatement:15,CLASS:16,STRUCT_START:17,members:18,STRUCT_STOP:19,MEMBER:20,SEPARATOR:21,relation:22,STR:23,relationType:24,lineType:25,AGGREGATION:26,EXTENSION:27,COMPOSITION:28,DEPENDENCY:29,LINE:30,DOTTED_LINE:31,commentToken:32,textToken:33,graphCodeTokens:34,textNoTagsToken:35,TAGSTART:36,TAGEND:37,"==":38,"--":39,PCT:40,DEFAULT:41,SPACE:42,MINUS:43,keywords:44,UNICODE_TEXT:45,NUM:46,ALPHA:47,$accept:0,$end:1},terminals_:{2:"error",5:"CLASS_DIAGRAM",6:"NEWLINE", +8:"EOF",13:"LABEL",16:"CLASS",17:"STRUCT_START",19:"STRUCT_STOP",20:"MEMBER",21:"SEPARATOR",23:"STR",26:"AGGREGATION",27:"EXTENSION",28:"COMPOSITION",29:"DEPENDENCY",30:"LINE",31:"DOTTED_LINE",34:"graphCodeTokens",36:"TAGSTART",37:"TAGEND",38:"==",39:"--",40:"PCT",41:"DEFAULT",42:"SPACE",43:"MINUS",44:"keywords",45:"UNICODE_TEXT",46:"NUM",47:"ALPHA"},productions_:[0,[3,1],[4,4],[7,1],[7,3],[10,2],[10,1],[9,1],[9,2],[9,1],[9,1],[14,2],[14,5],[18,1],[18,2],[15,1],[15,2],[15,1],[15,1],[12,3],[12,4],[12,4],[12,5],[22,3],[22,2],[22,2],[22,1],[24,1],[24,1],[24,1],[24,1],[25,1],[25,1],[32,1],[32,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[35,1],[35,1],[35,1],[35,1],[11,1],[11,1],[11,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 5:this.$=a[u-1]+a[u];break;case 6:this.$=a[u];break;case 7:r.addRelation(a[u]);break;case 8:a[u-1].title=r.cleanupLabel(a[u]),r.addRelation(a[u-1]);break;case 12:r.addMembers(a[u-3],a[u-1]);break;case 13:this.$=[a[u]];break;case 14:a[u].push(a[u-1]),this.$=a[u];break;case 15:break;case 16:r.addMembers(a[u-1],r.cleanupLabel(a[u]));break;case 17:console.warn("Member",a[u]);break;case 18:break;case 19:this.$={id1:a[u-2],id2:a[u],relation:a[u-1],relationTitle1:"none",relationTitle2:"none"};break;case 20:this.$={id1:a[u-3],id2:a[u],relation:a[u-1],relationTitle1:a[u-2],relationTitle2:"none"};break;case 21:this.$={id1:a[u-3],id2:a[u],relation:a[u-2],relationTitle1:"none",relationTitle2:a[u-1]};break;case 22:this.$={id1:a[u-4],id2:a[u],relation:a[u-2],relationTitle1:a[u-3],relationTitle2:a[u-1]};break;case 23:this.$={type1:a[u-2],type2:a[u],lineType:a[u-1]};break;case 24:this.$={type1:"none",type2:a[u],lineType:a[u-1]};break;case 25:this.$={type1:a[u-1],type2:"none",lineType:a[u]};break;case 26:this.$={type1:"none",type2:"none",lineType:a[u]};break;case 27:this.$=r.relationType.AGGREGATION;break;case 28:this.$=r.relationType.EXTENSION;break;case 29:this.$=r.relationType.COMPOSITION;break;case 30:this.$=r.relationType.DEPENDENCY;break;case 31:this.$=r.lineType.LINE;break;case 32:this.$=r.lineType.DOTTED_LINE}},table:[{3:1,4:2,5:[1,3]},{1:[3]},{1:[2,1]},{6:[1,4]},{7:5,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:u,47:o},{8:[1,18]},{6:[1,19],8:[2,3]},e(s,[2,7],{13:[1,20]}),e(s,[2,9]),e(s,[2,10]),e(s,[2,15],{22:21,24:24,25:25,13:[1,23],23:[1,22],26:c,27:l,28:h,29:f,30:d,31:p}),{10:32,11:14,45:a,46:u,47:o},e(s,[2,17]),e(s,[2,18]),e(g,[2,6],{11:14,10:33,45:a,46:u,47:o}),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),{1:[2,2]},{7:34,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:u,47:o},e(s,[2,8]),{10:35,11:14,23:[1,36],45:a,46:u,47:o},{22:37,24:24,25:25,26:c,27:l,28:h,29:f,30:d,31:p},e(s,[2,16]),{25:38,30:d,31:p},e(m,[2,26],{24:39,26:c,27:l,28:h,29:f}),e(v,[2,27]),e(v,[2,28]),e(v,[2,29]),e(v,[2,30]),e(_,[2,31]),e(_,[2,32]),e(s,[2,11],{17:[1,40]}),e(g,[2,5]),{8:[2,4]},e(b,[2,19]),{10:41,11:14,45:a,46:u,47:o},{10:42,11:14,23:[1,43],45:a,46:u,47:o},e(m,[2,25],{24:44,26:c,27:l,28:h,29:f}),e(m,[2,24]),{18:45,20:x},e(b,[2,21]),e(b,[2,20]),{10:47,11:14,45:a,46:u,47:o},e(m,[2,23]),{19:[1,48]},{18:49,19:[2,13],20:x},e(b,[2,22]),e(s,[2,12]),{19:[2,14]}],defaultActions:{2:[2,1],18:[2,2],34:[2,4],49:[2,14]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,D,M=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=M()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[b])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},A=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:return 6;case 2:break;case 3:return 5;case 4:return this.begin("struct"),17;case 5:return this.popState(),19;case 6:break;case 7:return"MEMBER";case 8:return 16;case 9:this.begin("string");break;case 10:this.popState();break;case 11:return"STR";case 12:return 27;case 13:return 27;case 14:return 29;case 15:return 29;case 16:return 28;case 17:return 26;case 18:return 30;case 19:return 31;case 20:return 13;case 21:return 43;case 22:return"DOT";case 23:return"PLUS";case 24:return 40;case 25:return"EQUALS";case 26:return"EQUALS";case 27:return 47;case 28:return"PUNCTUATION";case 29:return 46;case 30:return 45;case 31:return 42;case 32:return 8}},rules:[/^(?:%%[^\n]*)/,/^(?:\n+)/,/^(?:\s+)/,/^(?:classDiagram\b)/,/^(?:[\{])/,/^(?:\})/,/^(?:[\n])/,/^(?:[^\{\}\n]*)/,/^(?:class\b)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::[^#\n;]+)/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[A-Za-z]+)/,/^(?:[!"#$%&'*+,-.`?\\_\/])/,/^(?:[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:{string:{rules:[10,11],inclusive:!1},struct:{rules:[5,6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,8,9,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32],inclusive:!0}}};return t}();return w.lexer=A,t.prototype=w,w.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("_process"))},{_process:3,fs:1,path:2}],111:[function(t,e,n){(function(e){"use strict";var r=t("../../logger"),i=new r.Log,a="",u=!1;n.setMessage=function(t){i.debug("Setting message to: "+t),a=t},n.getMessage=function(){return a},n.setInfo=function(t){u=t},n.getInfo=function(){return u},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":126}],112:[function(t,e,n){"use strict";var r=t("./exampleDb"),i=t("./parser/example.js"),a=t("../../d3"),u=t("../../logger"),o=new u.Log;n.draw=function(t,e,n){var u;u=i.parser,u.yy=r,o.debug("Renering example diagram"),u.parse(t);var s=a.select("#"+e),c=s.append("g");c.append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("mermaid "+n),s.attr("height",100),s.attr("width",400)}},{"../../d3":107,"../../logger":126,"./exampleDb":111,"./parser/example.js":113}],113:[function(t,e,n){(function(r){"use strict";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=[6,9,10,12],r={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,message:11,say:12,TXT:13,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo",12:"say",13:"TXT"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1],[8,1],[11,2]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:return r;case 4:break;case 6:r.setInfo(!0);break;case 7:r.setMessage(a[u]);break;case 8:this.$=a[u-1].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8],11:9,12:[1,10]},{1:[2,1]},e(n,[2,3]),e(n,[2,4]),e(n,[2,5]),e(n,[2,6]),e(n,[2,7]),{13:[1,11]},e(n,[2,8])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,D,M=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=M()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[b])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},i=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,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),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;ae[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]),"utf8");return n.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&n.main(r.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],114:[function(t,e){"use strict";var n,r=t("../../logger"),i=new r.Log;if(t)try{n=t("dagre-d3")}catch(a){i.debug("Could not load dagre-d3")}n||(n=window.dagreD3),e.exports=n},{"../../logger":126,"dagre-d3":5}],115:[function(t,e,n){"use strict";var r=t("./graphDb"),i=t("./parser/flow"),a=t("./parser/dot"),u=t("../../d3"),o=t("./dagre-d3"),s=t("../../logger"),c=new s.Log,l={};e.exports.setConf=function(t){var e,n=Object.keys(t);for(e=0;e0&&(u=a.classes.join(" "));var o="";o=r(o,a.styles),i="undefined"==typeof a.text?a.id:a.text;var s="";l.htmlLabels?(s="html",i=i.replace(/fa:fa[\w\-]+/g,function(t){return''})):(i=i.replace(/
/g,"\n"),s="text");var c=0,h="";switch(a.type){case"round":c=5,h="rect";break;case"square":h="rect";break;case"diamond":h="question";break;case"odd":h="rect_left_inv_arrow";break;case"odd_right":h="rect_left_inv_arrow";break;case"circle":h="circle";break;case"ellipse":h="ellipse";break;case"group":h="rect",i="";break;default:h="rect"}e.setNode(a.id,{labelType:s,shape:h,label:i,rx:c,ry:c,"class":u,style:o,id:a.id})})},n.addEdges=function(t,e){var n,r,i=0;"undefined"!=typeof t.defaultStyle&&(r=t.defaultStyle.toString().replace(/,/g,";")),t.forEach(function(t){i++,n="arrow_open"===t.type?"none":"normal";var a="";if("undefined"!=typeof t.style)t.style.forEach(function(t){a=a+t+";"});else switch(t.stroke){case"normal":a="fill:none","undefined"!=typeof r&&(a=r);break;case"dotted":a="stroke: #333; fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":a="stroke: #333; stroke-width: 3.5px;fill:none"}if("undefined"==typeof t.text)"undefined"==typeof t.style?e.setEdge(t.start,t.end,{style:a,arrowhead:n},i):e.setEdge(t.start,t.end,{style:a,arrowheadStyle:"fill: #333",arrowhead:n},i);else{var u=t.text.replace(/
/g,"\n");"undefined"==typeof t.style?l.htmlLabels?e.setEdge(t.start,t.end,{labelType:"html",style:a,labelpos:"c",label:''+t.text+"",arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:"stroke: #333; stroke-width: 1.5px;fill:none",labelpos:"c",label:u,arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:a,arrowheadStyle:"fill: #333",label:u,arrowhead:n},i)}})},n.getClasses=function(t,e){var n;r.clear(),n=e?a.parser:i.parser,n.yy=r,n.parse(t);var u=r.getClasses();return"undefined"==typeof u["default"]&&(u["default"]={id:"default"},u["default"].styles=[],u["default"].clusterStyles=["rx:4px","fill: rgb(255, 255, 222)","rx: 4px","stroke: rgb(170, 170, 51)","stroke-width: 1px"],u["default"].nodeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"],u["default"].edgeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"]),u},n.draw=function(t,e,s){c.debug("Drawing flowchart");var h;r.clear(),h=s?a.parser:i.parser,h.yy=r;try{h.parse(t)}catch(f){c.debug("Parsing failed")}var d;d=r.getDirection(),"undefined"==typeof d&&(d="TD");var p,g=new o.graphlib.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:d,marginx:20,marginy:20}).setDefaultEdgeLabel(function(){return{}}),y=r.getSubGraphs(),m=0;for(m=y.length-1;m>=0;m--)p=y[m],r.addVertex(p.id,p.title,"group",void 0);var v=r.getVertices(),_=r.getEdges();m=0;var b;for(m=y.length-1;m>=0;m--)for(p=y[m],u.selectAll("cluster").append("text"),b=0;b0?t.split(",").forEach(function(t){"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)}):"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)};var setTooltip=function(t,e){"undefined"!=typeof e&&(tooltips[t]=e)},setClickFun=function setClickFun(id,functionName){"undefined"!=typeof functionName&&"undefined"!=typeof vertices[id]&&funs.push(function(element){var elem=d3.select(element).select("#"+id);null!==elem&&elem.on("click",function(){eval(functionName+"('"+id+"')")})})},setLink=function(t,e){"undefined"!=typeof e&&"undefined"!=typeof vertices[t]&&funs.push(function(n){var r=d3.select(n).select("#"+t);null!==r&&r.on("click",function(){window.open(e,"newTab")})})};exports.getTooltip=function(t){return tooltips[t]},exports.setClickEvent=function(t,e,n,r){t.indexOf(",")>0?t.split(",").forEach(function(t){setTooltip(t,r),setClickFun(t,e),setLink(t,n)}):(setTooltip(t,r),setClickFun(t,e),setLink(t,n))},exports.bindFunctions=function(t){funs.forEach(function(e){e(t)})},exports.getDirection=function(){return direction},exports.getVertices=function(){return vertices},exports.getEdges=function(){return edges},exports.getClasses=function(){return classes};var setupToolTips=function(t){var e=d3.select(".mermaidTooltip");null===e[0][0]&&(e=d3.select("body").append("div").attr("class","mermaidTooltip").style("opacity",0));var n=d3.select(t).select("svg"),r=n.selectAll("g.node");r.on("mouseover",function(){var t=d3.select(this),n=t.attr("title");if(null!==n){var r=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",r.left+(r.right-r.left)/2+"px").style("top",r.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}}).on("mouseout",function(){e.transition().duration(500).style("opacity",0);var t=d3.select(this);t.classed("hover",!1)})};funs.push(setupToolTips),exports.clear=function(){vertices={},classes={},edges=[],funs=[],funs.push(setupToolTips),subGraphs=[],subCount=0,tooltips=[]},exports.defaultStyle=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},exports.addSubGraph=function(t,e){function n(t){var e={"boolean":{},number:{},string:{}},n=[];return t.filter(function(t){var r=typeof t;return" "===t?!1:r in e?e[r].hasOwnProperty(t)?!1:e[r][t]=!0:n.indexOf(t)>=0?!1:n.push(t)})}var r=[];r=n(r.concat.apply(r,t));var i={id:"subGraph"+subCount,nodes:r,title:e};return subGraphs.push(i),subCount+=1,i.id};var getPosForId=function(t){var e;for(e=0;e2e3)){if(posCrossRef[secCount]=n,subGraphs[n].id===e)return{result:!0,count:0};for(var i=0,a=1;i=0){var o=t(e,u);if(o.result)return{result:!0,count:a+o.count};a+=o.count}i+=1}return{result:!1,count:a}}};exports.getDepthFirstPos=function(t){return posCrossRef[t]},exports.indexNodes=function(){secCount=-1,subGraphs.length>0&&indexNodes("none",subGraphs.length-1,0)},exports.getSubGraphs=function(){return subGraphs},exports.parseError=function(t,e){global.mermaidAPI.parseError(t,e)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../d3":107,"../../logger":126}],117:[function(t,e,n){(function(r){"use strict";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,5],r=[1,6],i=[1,12],a=[1,13],u=[1,14],o=[1,15],s=[1,16],c=[1,17],l=[1,18],h=[1,19],f=[1,20],d=[1,21],p=[1,22],g=[8,16,17,18,19,20,21,22,23,24,25,26],y=[1,37],m=[1,33],v=[1,34],_=[1,35],b=[1,36],x=[8,10,16,17,18,19,20,21,22,23,24,25,26,28,32,37,39,40,45,57,58],w=[10,28],A=[10,28,37,57,58],k=[2,49],E=[1,45],D=[1,48],M=[1,49],C=[1,52],S=[2,65],T=[1,65],F=[1,66],B=[1,67],L=[1,68],O=[1,69],N=[1,70],I=[1,71],P=[1,72],R=[1,73],j=[8,16,17,18,19,20,21,22,23,24,25,26,47],Y=[10,28,37],U={trace:function(){},yy:{},symbols_:{error:2,expressions:3,graph:4,EOF:5,graphStatement:6,idStatement:7,"{":8,stmt_list:9,"}":10,strict:11,GRAPH:12,DIGRAPH:13,textNoTags:14,textNoTagsToken:15,ALPHA:16,NUM:17,COLON:18,PLUS:19,EQUALS:20,MULT:21,DOT:22,BRKT:23,SPACE:24,MINUS:25,keywords:26,stmt:27,";":28,node_stmt:29,edge_stmt:30,attr_stmt:31,"=":32,subgraph:33,attr_list:34,NODE:35,EDGE:36,"[":37,a_list:38,"]":39,",":40,edgeRHS:41,node_id:42,edgeop:43,port:44,":":45,compass_pt:46,SUBGRAPH:47,n:48,ne:49,e:50,se:51,s:52,sw:53,w:54,nw:55,c:56,ARROW_POINT:57,ARROW_OPEN:58,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",8:"{",10:"}",11:"strict",12:"GRAPH",13:"DIGRAPH",16:"ALPHA",17:"NUM",18:"COLON",19:"PLUS",20:"EQUALS",21:"MULT",22:"DOT",23:"BRKT",24:"SPACE",25:"MINUS",26:"keywords",28:";",32:"=",35:"NODE",36:"EDGE",37:"[",39:"]",40:",",45:":",47:"SUBGRAPH",48:"n",49:"ne",50:"e",51:"se",52:"s",53:"sw",54:"w",55:"nw",56:"c",57:"ARROW_POINT",58:"ARROW_OPEN"},productions_:[0,[3,2],[4,5],[4,6],[4,4],[6,1],[6,1],[7,1],[14,1],[14,2],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[9,1],[9,3],[27,1],[27,1],[27,1],[27,3],[27,1],[31,2],[31,2],[31,2],[34,4],[34,3],[34,3],[34,2],[38,5],[38,5],[38,3],[30,3],[30,3],[30,2],[30,2],[41,3],[41,3],[41,2],[41,2],[29,2],[29,1],[42,2],[42,1],[44,4],[44,2],[44,2],[33,5],[33,4],[33,3],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,0],[43,1],[43,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:this.$=a[u-1];break;case 2:this.$=a[u-4];break;case 3:this.$=a[u-5];break;case 4:this.$=a[u-3];break;case 8:case 10:case 11:this.$=a[u];break;case 9:this.$=a[u-1]+""+a[u];break;case 12:case 13:case 14:case 15:case 16:case 18:case 19:case 20:this.$=a[u];break;case 17:this.$="
";break;case 39:this.$="oy";break;case 40:r.addLink(a[u-1],a[u].id,a[u].op),this.$="oy";break;case 42:r.addLink(a[u-1],a[u].id,a[u].op),this.$={op:a[u-2],id:a[u-1]};break;case 44:this.$={op:a[u-1],id:a[u]};break;case 48:r.addVertex(a[u-1]),this.$=a[u-1];break;case 49:r.addVertex(a[u]),this.$=a[u];break;case 66:this.$="arrow";break;case 67:this.$="arrow_open"}},table:[{3:1,4:2,6:3,11:[1,4],12:n,13:r},{1:[3]},{5:[1,7]},{7:8,8:[1,9],14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{6:23,12:n,13:r},e(g,[2,5]),e(g,[2,6]),{1:[2,1]},{8:[1,24]},{7:30,8:y,9:25,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},e([8,10,28,32,37,39,40,45,57,58],[2,7],{15:38,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p}),e(x,[2,8]),e(x,[2,10]),e(x,[2,11]),e(x,[2,12]),e(x,[2,13]),e(x,[2,14]),e(x,[2,15]),e(x,[2,16]),e(x,[2,17]),e(x,[2,18]),e(x,[2,19]),e(x,[2,20]),{7:39,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{7:30,8:y,9:40,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,41]},{10:[2,21],28:[1,42]},e(w,[2,23]),e(w,[2,24]),e(w,[2,25]),e(A,k,{44:44,32:[1,43],45:E}),e(w,[2,27],{41:46,43:47,57:D,58:M}),e(w,[2,47],{43:47,34:50,41:51,37:C,57:D,58:M}),{34:53,37:C},{34:54,37:C},{34:55,37:C},{7:56,8:[1,57],14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{7:30,8:y,9:58,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},e(x,[2,9]),{8:[1,59]},{10:[1,60]},{5:[2,4]},{7:30,8:y,9:61,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{7:62,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},e(A,[2,48]),e(A,S,{14:10,15:11,7:63,46:64,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,48:T,49:F,50:B,51:L,52:O,53:N,54:I,55:P,56:R}),e(w,[2,41],{34:74,37:C}),{7:77,8:y,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,33:76,42:75,47:b},e(j,[2,66]),e(j,[2,67]),e(w,[2,46]),e(w,[2,40],{34:78,37:C}),{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:79,39:[1,80]},e(w,[2,28]),e(w,[2,29]),e(w,[2,30]),{8:[1,82]},{7:30,8:y,9:83,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,84]},{7:30,8:y,9:85,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{5:[2,2]},{10:[2,22]},e(w,[2,26]),e(A,[2,51],{45:[1,86]}),e(A,[2,52]),e(A,[2,56]),e(A,[2,57]),e(A,[2,58]),e(A,[2,59]),e(A,[2,60]),e(A,[2,61]),e(A,[2,62]),e(A,[2,63]),e(A,[2,64]),e(w,[2,38]),e(Y,[2,44],{43:47,41:87,57:D,58:M}),e(Y,[2,45],{43:47,41:88,57:D,58:M}),e(A,k,{44:44,45:E}),e(w,[2,39]),{39:[1,89]},e(w,[2,34],{34:90,37:C}),{32:[1,91]},{7:30,8:y,9:92,12:m,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,93]},e(A,[2,55]),{10:[1,94]},e(A,S,{46:95,48:T,49:F,50:B,51:L,52:O,53:N,54:I,55:P,56:R}),e(Y,[2,42]),e(Y,[2,43]),e(w,[2,33],{34:96,37:C}),e(w,[2,32]),{7:97,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p},{10:[1,98]},e(A,[2,54]),{5:[2,3]},e(A,[2,50]),e(w,[2,31]),{28:[1,99],39:[2,37],40:[1,100]},e(A,[2,53]),{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:101},{7:81,14:10,15:11,16:i,17:a,18:u,19:o,20:s,21:c,22:l,23:h,24:f,25:d,26:p,38:102},{39:[2,35]},{39:[2,36]}],defaultActions:{7:[2,1],41:[2,4],60:[2,2],61:[2,22],94:[2,3],101:[2,35],102:[2,36]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,D,M=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=M()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[b])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:return"STYLE";case 1:return"LINKSTYLE";case 2:return"CLASSDEF";case 3:return"CLASS";case 4:return"CLICK";case 5:return 12;case 6:return 13;case 7:return 47;case 8:return 35;case 9:return 36;case 10:return"DIR";case 11:return"DIR";case 12:return"DIR";case 13:return"DIR";case 14:return"DIR";case 15:return"DIR";case 16:return 17;case 17:return 23;case 18:return 18;case 19:return 28;case 20:return 40;case 21:return 32;case 22:return 21;case 23:return 22;case 24:return"ARROW_CROSS";case 25:return 57;case 26:return"ARROW_CIRCLE";case 27:return 58;case 28:return 25;case 29:return 19;case 30:return 20;case 31:return 16;case 32:return"PIPE";case 33:return"PS";case 34:return"PE";case 35:return 37;case 36:return 39;case 37:return 8;case 38:return 10;case 39:return"QUOTE";case 40:return 24;case 41:return"NEWLINE";case 42:return 5}},rules:[/^(?:style\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:digraph\b)/,/^(?:subgraph\b)/,/^(?:node\b)/,/^(?:edge\b)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9])/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:=)/,/^(?:\*)/,/^(?:\.)/,/^(?:--[x])/,/^(?:->)/,/^(?:--[o])/,/^(?:--)/,/^(?:-)/,/^(?:\+)/,/^(?:=)/,/^(?:[\u0021-\u0027\u002A-\u002E\u003F\u0041-\u005A\u0061-\u007A\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)/,/^(?:\n)/,/^(?:$)/],conditions:{INITIAL:{rules:[0,1,2,3,4,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],inclusive:!0}}};return t}();return U.lexer=$,t.prototype=U,U.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("_process"))},{_process:3,fs:1,path:2}],118:[function(t,e,n){(function(r){"use strict";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,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],u=[2,2],o=[1,12],s=[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,38],x=[1,40],w=[1,35],A=[1,39],k=[1,45],E=[1,44],D=[1,36],M=[1,37],C=[1,41],S=[1,42],T=[1,43],F=[1,8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],B=[1,53],L=[1,52],O=[1,54],N=[1,72],I=[1,80],P=[1,81],R=[1,66],j=[1,65],Y=[1,85],U=[1,84],$=[1,82],z=[1,83],q=[1,73],W=[1,68],G=[1,67],H=[1,63],V=[1,75],X=[1,76],Z=[1,77],K=[1,78],Q=[1,79],J=[1,70],tt=[1,69],et=[8,9,11],nt=[8,9,11,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64],rt=[1,115],it=[8,9,10,11,13,15,18,36,38,40,42,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,85,87,88,90,91,93,94,95,96,97],at=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,42,43,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],ut=[1,117],ot=[1,118],st=[8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],ct=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,43,46,50,51,52,53,54,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],lt=[13,18,46,81,85,87,88,90,91,93,94,95,96,97],ht=[13,18,46,49,65,81,85,87,88,90,91,93,94,95,96,97],ft=[1,191],dt=[1,188],pt=[1,195],gt=[1,192],yt=[1,189],mt=[1,196],vt=[1,186],_t=[1,187],bt=[1,190],xt=[1,193],wt=[1,194],At=[1,211],kt=[8,9,11,85],Et=[8,9,10,11,46,71,80,81,83,85,87,88,89,90,91],Dt={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,"(-":40,"-)":41,DIAMOND_START:42,DIAMOND_STOP:43,alphaNumStatement:44,alphaNumToken:45,MINUS:46,linkStatement:47,arrowText:48,TESTSTR:49,"--":50,ARROW_POINT:51,ARROW_CIRCLE:52,ARROW_CROSS:53,ARROW_OPEN:54,"-.":55,DOTTED_ARROW_POINT:56,DOTTED_ARROW_CIRCLE:57,DOTTED_ARROW_CROSS:58,DOTTED_ARROW_OPEN:59,"==":60,THICK_ARROW_POINT:61,THICK_ARROW_CIRCLE:62,THICK_ARROW_CROSS:63,THICK_ARROW_OPEN:64,PIPE:65,textToken:66,STR:67,commentText:68,commentToken:69,keywords:70,STYLE:71,LINKSTYLE:72,CLASSDEF:73,CLASS:74,CLICK:75,textNoTags:76,textNoTagsToken:77,DEFAULT:78,stylesOpt:79,HEX:80,NUM:81,commentStatement:82,PCT:83,style:84,COMMA:85,styleComponent:86,ALPHA:87,COLON:88,UNIT:89,BRKT:90,DOT:91,graphCodeTokens:92,PUNCTUATION:93,UNICODE_TEXT:94,PLUS:95,EQUALS:96,MULT:97,TAG_START:98,TAG_END:99,QUOTE:100,$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:"(-",41:"-)",42:"DIAMOND_START",43:"DIAMOND_STOP",46:"MINUS",49:"TESTSTR",50:"--",51:"ARROW_POINT",52:"ARROW_CIRCLE",53:"ARROW_CROSS",54:"ARROW_OPEN",55:"-.",56:"DOTTED_ARROW_POINT",57:"DOTTED_ARROW_CIRCLE",58:"DOTTED_ARROW_CROSS",59:"DOTTED_ARROW_OPEN",60:"==",61:"THICK_ARROW_POINT",62:"THICK_ARROW_CIRCLE",63:"THICK_ARROW_CROSS",64:"THICK_ARROW_OPEN",65:"PIPE",67:"STR",71:"STYLE",72:"LINKSTYLE",73:"CLASSDEF",74:"CLASS",75:"CLICK",78:"DEFAULT",80:"HEX",81:"NUM",83:"PCT",85:"COMMA",87:"ALPHA",88:"COLON",89:"UNIT",90:"BRKT",91:"DOT",93:"PUNCTUATION",94:"UNICODE_TEXT",95:"PLUS",96:"EQUALS",97:"MULT",98:"TAG_START",99:"TAG_END",100:"QUOTE"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,4],[4,4],[4,4],[4,4],[4,4],[19,2],[19,1],[20,1],[20,1],[20,1],[14,1],[14,1],[14,2],[22,2],[22,2],[22,1],[22,1],[21,2],[21,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,5],[7,4],[24,1],[24,1],[24,1],[23,3],[23,1],[33,4],[33,5],[33,6],[33,7],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,1],[33,2],[35,1],[35,2],[44,1],[44,1],[44,1],[44,1],[34,2],[34,3],[34,3],[34,1],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[48,3],[31,1],[31,2],[31,1],[68,1],[68,2],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[76,1],[76,2],[27,5],[27,5],[28,5],[29,5],[29,7],[29,5],[29,7],[25,5],[25,5],[26,5],[26,5],[82,3],[79,1],[79,3],[84,1],[84,2],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[69,1],[69,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[77,1],[77,1],[77,1],[77,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 2:this.$=[];break;case 3:a[u]!==[]&&a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 57:case 59:case 60:case 92:case 94:case 95:case 108:this.$=a[u];break;case 11:r.setDirection(a[u-1]),this.$=a[u-1];break;case 12:r.setDirection("LR"),this.$=a[u-1];break;case 13:r.setDirection("RL"),this.$=a[u-1];break;case 14:r.setDirection("BT"),this.$=a[u-1];break;case 15:r.setDirection("TB"),this.$=a[u-1];break;case 30:this.$=a[u-1];break;case 31:case 32:case 33:case 34:case 35:this.$=[];break;case 36:this.$=r.addSubGraph(a[u-1],a[u-3]);break;case 37:this.$=r.addSubGraph(a[u-1],void 0);break;case 41:r.addLink(a[u-2],a[u],a[u-1]),this.$=[a[u-2],a[u]];break;case 42:this.$=[a[u]];break;case 43:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"square");break;case 44:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"square");break;case 45:this.$=a[u-5],r.addVertex(a[u-5],a[u-2],"circle");break;case 46:this.$=a[u-6],r.addVertex(a[u-6],a[u-3],"circle");break;case 47:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"ellipse");break;case 48:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"ellipse");break;case 49:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"round");break;case 50:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"round");break;case 51:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"diamond");break;case 52:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"diamond");break;case 53:this.$=a[u-3],r.addVertex(a[u-3],a[u-1],"odd");break;case 54:this.$=a[u-4],r.addVertex(a[u-4],a[u-2],"odd");break;case 55:this.$=a[u],r.addVertex(a[u]);break;case 56:this.$=a[u-1],r.addVertex(a[u-1]);break;case 58:case 93:case 96:case 109:this.$=a[u-1]+""+a[u];break;case 61:this.$="v";break;case 62:this.$="-";break;case 63:a[u-1].text=a[u],this.$=a[u-1];break;case 64:case 65:a[u-2].text=a[u-1],this.$=a[u-2];break;case 66:this.$=a[u];break;case 67:this.$={type:"arrow",stroke:"normal",text:a[u-1]};break;case 68:this.$={type:"arrow_circle",stroke:"normal", +text:a[u-1]};break;case 69:this.$={type:"arrow_cross",stroke:"normal",text:a[u-1]};break;case 70:this.$={type:"arrow_open",stroke:"normal",text:a[u-1]};break;case 71:this.$={type:"arrow",stroke:"dotted",text:a[u-1]};break;case 72:this.$={type:"arrow_circle",stroke:"dotted",text:a[u-1]};break;case 73:this.$={type:"arrow_cross",stroke:"dotted",text:a[u-1]};break;case 74:this.$={type:"arrow_open",stroke:"dotted",text:a[u-1]};break;case 75:this.$={type:"arrow",stroke:"thick",text:a[u-1]};break;case 76:this.$={type:"arrow_circle",stroke:"thick",text:a[u-1]};break;case 77:this.$={type:"arrow_cross",stroke:"thick",text:a[u-1]};break;case 78:this.$={type:"arrow_open",stroke:"thick",text:a[u-1]};break;case 79:this.$={type:"arrow",stroke:"normal"};break;case 80:this.$={type:"arrow_circle",stroke:"normal"};break;case 81:this.$={type:"arrow_cross",stroke:"normal"};break;case 82:this.$={type:"arrow_open",stroke:"normal"};break;case 83:this.$={type:"arrow",stroke:"dotted"};break;case 84:this.$={type:"arrow_circle",stroke:"dotted"};break;case 85:this.$={type:"arrow_cross",stroke:"dotted"};break;case 86:this.$={type:"arrow_open",stroke:"dotted"};break;case 87:this.$={type:"arrow",stroke:"thick"};break;case 88:this.$={type:"arrow_circle",stroke:"thick"};break;case 89:this.$={type:"arrow_cross",stroke:"thick"};break;case 90:this.$={type:"arrow_open",stroke:"thick"};break;case 91:this.$=a[u-1];break;case 110:case 111:this.$=a[u-4],r.addClass(a[u-2],a[u]);break;case 112:this.$=a[u-4],r.setClass(a[u-2],a[u]);break;case 113:this.$=a[u-4],r.setClickEvent(a[u-2],a[u],void 0,void 0);break;case 114:this.$=a[u-6],r.setClickEvent(a[u-4],a[u-2],void 0,a[u]);break;case 115:this.$=a[u-4],r.setClickEvent(a[u-2],void 0,a[u],void 0);break;case 116:this.$=a[u-6],r.setClickEvent(a[u-4],void 0,a[u-2],a[u]);break;case 117:this.$=a[u-4],r.addVertex(a[u-2],void 0,void 0,a[u]);break;case 118:case 119:case 120:this.$=a[u-4],r.updateLink(a[u-2],a[u]);break;case 122:this.$=[a[u]];break;case 123:a[u-2].push(a[u]),this.$=a[u-2];break;case 125:this.$=a[u-1]+a[u]}},table:[{3:1,4:2,9:n,10:r,12:i},{1:[3]},e(a,u,{5:6}),{4:7,9:n,10:r,12:i},{4:8,9:n,10:r,12:i},{10:[1,9]},{1:[2,1],6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(a,[2,9]),e(a,[2,10]),{13:[1,46],15:[1,47],16:[1,48],17:[1,49],18:[1,50]},e(F,[2,3]),e(F,[2,4]),e(F,[2,5]),e(F,[2,6]),e(F,[2,7]),e(F,[2,8]),{8:B,9:L,11:O,24:51},{8:B,9:L,11:O,24:55},{8:B,9:L,11:O,24:56},{8:B,9:L,11:O,24:57},{8:B,9:L,11:O,24:58},{8:B,9:L,11:O,24:59},{8:B,9:L,10:N,11:O,12:I,13:P,15:R,16:j,17:Y,18:U,24:61,30:$,31:60,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(et,[2,42],{34:86,47:87,50:[1,88],51:[1,91],52:[1,92],53:[1,93],54:[1,94],55:[1,89],56:[1,95],57:[1,96],58:[1,97],59:[1,98],60:[1,90],61:[1,99],62:[1,100],63:[1,101],64:[1,102]}),{10:[1,103]},{10:[1,104]},{10:[1,105]},{10:[1,106]},{10:[1,107]},e(nt,[2,55],{45:32,21:113,44:114,10:rt,13:h,15:[1,112],18:f,36:[1,108],38:[1,109],40:[1,110],42:[1,111],46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T}),e(it,[2,57]),e(it,[2,59]),e(it,[2,60]),e(it,[2,61]),e(it,[2,62]),e(at,[2,150]),e(at,[2,151]),e(at,[2,152]),e(at,[2,153]),e(at,[2,154]),e(at,[2,155]),e(at,[2,156]),e(at,[2,157]),e(at,[2,158]),e(at,[2,159]),e(at,[2,160]),{8:ut,9:ot,10:rt,14:116,21:119},{8:ut,9:ot,10:rt,14:120,21:119},{8:ut,9:ot,10:rt,14:121,21:119},{8:ut,9:ot,10:rt,14:122,21:119},{8:ut,9:ot,10:rt,14:123,21:119},e(F,[2,30]),e(F,[2,38]),e(F,[2,39]),e(F,[2,40]),e(F,[2,31]),e(F,[2,32]),e(F,[2,33]),e(F,[2,34]),e(F,[2,35]),{8:B,9:L,10:N,11:O,12:I,13:P,15:R,16:j,17:Y,18:U,24:124,30:$,32:z,45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(st,u,{5:126}),e(ct,[2,92]),e(ct,[2,94]),e(ct,[2,139]),e(ct,[2,140]),e(ct,[2,141]),e(ct,[2,142]),e(ct,[2,143]),e(ct,[2,144]),e(ct,[2,145]),e(ct,[2,146]),e(ct,[2,147]),e(ct,[2,148]),e(ct,[2,149]),e(ct,[2,97]),e(ct,[2,98]),e(ct,[2,99]),e(ct,[2,100]),e(ct,[2,101]),e(ct,[2,102]),e(ct,[2,103]),e(ct,[2,104]),e(ct,[2,105]),e(ct,[2,106]),e(ct,[2,107]),{13:h,18:f,33:127,35:29,44:30,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(lt,[2,66],{48:128,49:[1,129],65:[1,130]}),{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:131,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:132,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:133,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(ht,[2,79]),e(ht,[2,80]),e(ht,[2,81]),e(ht,[2,82]),e(ht,[2,83]),e(ht,[2,84]),e(ht,[2,85]),e(ht,[2,86]),e(ht,[2,87]),e(ht,[2,88]),e(ht,[2,89]),e(ht,[2,90]),{13:h,18:f,35:134,44:30,45:32,46:p,80:[1,135],81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{78:[1,136],81:[1,137]},{13:h,18:f,35:139,44:30,45:32,46:p,78:[1,138],81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{13:h,18:f,35:140,44:30,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{13:h,18:f,35:141,44:30,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:142,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:144,32:z,38:[1,143],45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:145,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:146,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:147,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(nt,[2,56]),e(it,[2,58]),e(nt,[2,29],{21:148,10:rt}),e(a,[2,11]),e(a,[2,21]),e(a,[2,22]),{9:[1,149]},e(a,[2,12]),e(a,[2,13]),e(a,[2,14]),e(a,[2,15]),e(st,u,{5:150}),e(ct,[2,93]),{6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,32:[1,151],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(et,[2,41]),e(lt,[2,63],{10:[1,152]}),{10:[1,153]},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:154,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,45:71,46:q,50:W,51:[1,155],52:[1,156],53:[1,157],54:[1,158],60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,45:71,46:q,50:W,56:[1,159],57:[1,160],58:[1,161],59:[1,162],60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,45:71,46:q,50:W,60:G,61:[1,163],62:[1,164],63:[1,165],64:[1,166],66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:[1,167],13:h,18:f,44:114,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:[1,168]},{10:[1,169]},{10:[1,170]},{10:[1,171]},{10:[1,172],13:h,18:f,44:114,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:[1,173],13:h,18:f,44:114,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:[1,174],13:h,18:f,44:114,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,37:[1,175],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,31:176,32:z,45:71,46:q,50:W,60:G,66:62,67:H,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,39:[1,177],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,41:[1,178],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,43:[1,179],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,37:[1,180],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(nt,[2,28]),e(a,[2,23]),{6:10,7:11,8:o,9:s,10:c,11:l,13:h,18:f,23:16,25:17,26:18,27:19,28:20,29:21,30:d,32:[1,181],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(F,[2,37]),e(lt,[2,65]),e(lt,[2,64]),{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,45:71,46:q,50:W,60:G,65:[1,182],66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(lt,[2,67]),e(lt,[2,68]),e(lt,[2,69]),e(lt,[2,70]),e(lt,[2,71]),e(lt,[2,72]),e(lt,[2,73]),e(lt,[2,74]),e(lt,[2,75]),e(lt,[2,76]),e(lt,[2,77]),e(lt,[2,78]),{10:ft,46:dt,71:pt,79:183,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:197,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:198,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:199,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:200,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{10:ft,46:dt,71:pt,79:201,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},{13:h,18:f,35:202,44:30,45:32,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},{13:h,18:f,35:203,44:30,45:32,46:p,67:[1,204],81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(nt,[2,43],{21:205,10:rt}),{10:N,12:I,13:P,15:R,16:j,17:Y,18:U,30:$,32:z,39:[1,206],45:71,46:q,50:W,60:G,66:125,70:74,71:V,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T},e(nt,[2,49],{21:207,10:rt}),e(nt,[2,47],{21:208,10:rt}),e(nt,[2,51],{21:209,10:rt}),e(nt,[2,53],{21:210,10:rt}),e(F,[2,36]),e([10,13,18,46,81,85,87,88,90,91,93,94,95,96,97],[2,91]),e(et,[2,117],{85:At}),e(kt,[2,122],{86:212,10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,87:vt,88:_t,89:bt,90:xt,91:wt}),e(Et,[2,124]),e(Et,[2,126]),e(Et,[2,127]),e(Et,[2,128]),e(Et,[2,129]),e(Et,[2,130]),e(Et,[2,131]),e(Et,[2,132]),e(Et,[2,133]),e(Et,[2,134]),e(Et,[2,135]),e(Et,[2,136]),e(et,[2,118],{85:At}),e(et,[2,119],{85:At}),e(et,[2,120],{85:At}),e(et,[2,110],{85:At}),e(et,[2,111],{85:At}),e(et,[2,112],{45:32,44:114,13:h,18:f,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T}),e(et,[2,113],{45:32,44:114,10:[1,213],13:h,18:f,46:p,81:b,85:x,87:w,88:A,90:k,91:E,93:D,94:M,95:C,96:S,97:T}),e(et,[2,115],{10:[1,214]}),e(nt,[2,44]),{39:[1,215]},e(nt,[2,50]),e(nt,[2,48]),e(nt,[2,52]),e(nt,[2,54]),{10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,84:216,86:185,87:vt,88:_t,89:bt,90:xt,91:wt},e(Et,[2,125]),{67:[1,217]},{67:[1,218]},e(nt,[2,45],{21:219,10:rt}),e(kt,[2,123],{86:212,10:ft,46:dt,71:pt,80:gt,81:yt,83:mt,87:vt,88:_t,89:bt,90:xt,91:wt}),e(et,[2,114]),e(et,[2,116]),e(nt,[2,46])],defaultActions:{},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,D,M=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=M()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[b])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},Mt=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:this.begin("string");break;case 2:this.popState();break;case 3:return"STR";case 4:return 71;case 5:return 78;case 6:return 72;case 7:return 73;case 8:return 74;case 9:return 75;case 10:return 12;case 11:return 30;case 12:return 32;case 13:return 13;case 14:return 13;case 15:return 13;case 16:return 13;case 17:return 13;case 18:return 13;case 19:return 81;case 20:return 90;case 21:return 88;case 22:return 8;case 23:return 85;case 24:return 97;case 25:return 16;case 26:return 15;case 27:return 17;case 28:return 18;case 29:return 53;case 30:return 51;case 31:return 52;case 32:return 54;case 33:return 58;case 34:return 56;case 35:return 57;case 36:return 59;case 37:return 58;case 38:return 56;case 39:return 57;case 40:return 59;case 41:return 63;case 42:return 61;case 43:return 62;case 44:return 64;case 45:return 50;case 46:return 55;case 47:return 60;case 48:return 40;case 49:return 41;case 50:return 46;case 51:return 91;case 52:return 95;case 53:return 83;case 54:return 96;case 55:return 96;case 56:return 87;case 57:return 93;case 58:return 94;case 59:return 65;case 60:return 38;case 61:return 39;case 62:return 36;case 63:return 37;case 64:return 42;case 65:return 43;case 66:return 100;case 67:return 9;case 68:return 10;case 69:return 11}},rules:[/^(?:%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:v\b)/,/^(?:\s*--[x]\s*)/,/^(?:\s*-->\s*)/,/^(?:\s*--[o]\s*)/,/^(?:\s*---\s*)/,/^(?:\s*-\.-[x]\s*)/,/^(?:\s*-\.->\s*)/,/^(?:\s*-\.-[o]\s*)/,/^(?:\s*-\.-\s*)/,/^(?:\s*.-[x]\s*)/,/^(?:\s*\.->\s*)/,/^(?:\s*\.-[o]\s*)/,/^(?:\s*\.-\s*)/,/^(?:\s*==[x]\s*)/,/^(?:\s*==>\s*)/,/^(?:\s*==[o]\s*)/,/^(?:\s*==[\=]\s*)/,/^(?:\s*--\s*)/,/^(?:\s*-\.\s*)/,/^(?:\s*==\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[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])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:\n+)/,/^(?:\s)/,/^(?:$)/],conditions:{string:{rules:[2,3],inclusive:!1},INITIAL:{rules:[0,1,4,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,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69],inclusive:!0}}};return t}();return Dt.lexer=Mt,t.prototype=Dt,Dt.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("_process"))},{_process:3,fs:1,path:2}],119:[function(t,e,n){(function(e){"use strict";var r=t("moment"),i=t("../../logger"),a=new i.Log,u="",o="",s=[],c=[],l="";n.clear=function(){s=[],c=[],l="",o="",g=0,h=void 0,f=void 0,_=[]},n.setDateFormat=function(t){u=t},n.getDateFormat=function(){return u},n.setTitle=function(t){o=t},n.getTitle=function(){return o},n.addSection=function(t){l=t,s.push(t)},n.getTasks=function(){for(var t=x(),e=10,n=0;!t&&e>n;)t=x(),n++;return c=_};var h,f,d=function(t,e,i){i=i.trim();var u=/^after\s+([\d\w\-]+)/,o=u.exec(i.trim());if(null!==o){var s=n.findTaskById(o[1]);if("undefined"==typeof s){var c=new Date;return c.setHours(0,0,0,0),c}return s.endTime}return r(i,e.trim(),!0).isValid()?r(i,e.trim(),!0).toDate():(a.debug("Invalid date:"+i),a.debug("With date format:"+e.trim()),new Date)},p=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])/,u=a.exec(n.trim());if(null!==u){switch(u[2]){case"s":i.add(u[1],"seconds");break;case"m":i.add(u[1],"minutes");break;case"h":i.add(u[1],"hours");break;case"d":i.add(u[1],"days");break;case"w":i.add(u[1],"weeks")}return i.toDate()}return i.toDate()},g=0,y=function(t){return"undefined"==typeof t?(g+=1,"task"+g):t},m=function(t,e){var r;r=":"===e.substr(0,1)?e.substr(1,e.length):e;for(var i=r.split(","),a={},u=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 s;for(s=0;sn-e?n+i+1.5*u.sidePadding>o?e+r-5:n+r+5:(n-e)/2+e+r}).attr("y",function(t,r){return r*e+u.barHeight/2+(u.fontSize/2-2)+n}).attr("text-height",i).attr("class",function(t){ +for(var e=w(t.startTime),n=w(t.endTime),r=this.getBBox().width,i=0,a=0;an-e?n+r+1.5*u.sidePadding>o?"taskTextOutsideLeft taskTextOutside"+i+" "+s:"taskTextOutsideRight taskTextOutside"+i+" "+s:"taskText taskText"+i+" "+s})}function l(t,e,n,a){var o,s=[[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["h1 %I:%M",function(t){return t.getMinutes()}]],c=[["%Y",function(){return!0}]],l=[["%I:%M",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}]];"undefined"!=typeof u.axisFormatter&&(l=[],u.axisFormatter.forEach(function(t){var e=[];e[0]=t[0],e[1]=t[1],l.push(e)})),o=s.concat(l).concat(c);var h=i.svg.axis().scale(w).orient("bottom").tickSize(-a+e+u.gridLineStartPadding,0,0).tickFormat(i.time.format.multi(o));r>7&&230>r&&(h=h.ticks(i.time.monday.range)),_.append("g").attr("class","grid").attr("transform","translate("+t+", "+(a-50)+")").call(h).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em")}function h(t,e){for(var n=[],r=0,i=0;i0))return i[1]*t/2+e;for(var u=0;a>u;u++)return r+=n[a-1][1],i[1]*t/2+r*t+e}).attr("class",function(t){for(var e=0;er;++r)e.hasOwnProperty(t[r])||(e[t[r]]=!0,n.push(t[r]));return n}function p(t){for(var e=t.length,n={};e;)n[t[--e]]=(n[t[e]]||0)+1;return n}function g(t,e){return p(e)[t]||0}n.yy.clear(),n.parse(t);var y=document.getElementById(e);o=y.parentElement.offsetWidth,"undefined"==typeof o&&(o=1200),"undefined"!=typeof u.useWidth&&(o=u.useWidth);var m=n.yy.getTasks(),v=m.length*(u.barHeight+u.barGap)+2*u.topPadding;y.setAttribute("height","100%"),y.setAttribute("viewBox","0 0 "+o+" "+v);var _=i.select("#"+e),b=i.min(m,function(t){return t.startTime}),x=i.max(m,function(t){return t.endTime}),w=i.time.scale().domain([i.min(m,function(t){return t.startTime}),i.max(m,function(t){return t.endTime})]).rangeRound([0,o-150]),A=[];r=a.duration(x-b).asDays();for(var k=0;kl&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},s=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,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),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;ae[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 10;case 1:break;case 2:break;case 3:break;case 4:return 4;case 5:return 11;case 6:return"date";case 7:return 12;case 8:return 13;case 9:return 14;case 10:return 15;case 11:return":";case 12:return 6;case 13:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\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:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return t}();return o.lexer=s,t.prototype=o,o.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("_process"))},{_process:3,fs:1,path:2}],122:[function(t,e,n){(function(r){"use strict";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=[2,2],r=[1,5],i=[1,7],a=[1,8],u=[1,11],o=[1,12],s=[1,13],c=[1,14],l=[1,16],h=[1,17],f=[1,7,9,10,14,16,18,19,20,21,22,33],d=[7,9,10,14,16,18,19,20,22,33],p=[1,51],g={trace:function(){},yy:{},symbols_:{error:2,start:3,SD:4,document:5,line:6,SPACE:7,statement:8,NL:9,participant:10,actor:11,signal:12,note_statement:13,title:14,text:15,loop:16,restOfLine:17,end:18,opt:19,alt:20,"else":21,note:22,placement:23,text2:24,over:25,actor_pair:26,spaceList:27,",":28,left_of:29,right_of:30,signaltype:31,actors:32,ACTOR:33,SOLID_OPEN_ARROW:34,DOTTED_OPEN_ARROW:35,SOLID_ARROW:36,DOTTED_ARROW:37,SOLID_CROSS:38,DOTTED_CROSS:39,TXT:40,$accept:0,$end:1},terminals_:{2:"error",4:"SD",7:"SPACE",9:"NL",10:"participant",14:"title",15:"text",16:"loop",17:"restOfLine",18:"end",19:"opt",20:"alt",21:"else",22:"note",25:"over",28:",",29:"left_of",30:"right_of",33:"ACTOR",34:"SOLID_OPEN_ARROW",35:"DOTTED_OPEN_ARROW",36:"SOLID_ARROW",37:"DOTTED_ARROW",38:"SOLID_CROSS",39:"DOTTED_CROSS",40:"TXT"},productions_:[0,[3,2],[5,0],[5,2],[6,2],[6,1],[6,1],[8,3],[8,2],[8,2],[8,4],[8,4],[8,4],[8,7],[13,4],[13,4],[27,2],[27,1],[26,3],[26,1],[23,1],[23,1],[12,4],[32,2],[32,1],[11,1],[31,1],[31,1],[31,1],[31,1],[31,1],[31,1],[24,1]],performAction:function(t,e,n,r,i,a){var u=a.length-1;switch(i){case 1:return r.apply(a[u]),a[u];case 2:this.$=[];break;case 3:a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 5:this.$=a[u];break;case 6:this.$=[];break;case 7:this.$=a[u-1];break;case 11:a[u-1].unshift({type:"loopStart",loopText:a[u-2],signalType:r.LINETYPE.LOOP_START}),a[u-1].push({type:"loopEnd",loopText:a[u-2],signalType:r.LINETYPE.LOOP_END}),this.$=a[u-1];break;case 12:a[u-1].unshift({type:"optStart",optText:a[u-2],signalType:r.LINETYPE.OPT_START}),a[u-1].push({type:"optEnd",optText:a[u-2],signalType:r.LINETYPE.OPT_END}),this.$=a[u-1];break;case 13:a[u-4].unshift({type:"altStart",altText:a[u-5],signalType:r.LINETYPE.ALT_START}),a[u-4].push({type:"else",altText:a[u-2],signalType:r.LINETYPE.ALT_ELSE}),a[u-4]=a[u-4].concat(a[u-1]),a[u-4].push({type:"altEnd",signalType:r.LINETYPE.ALT_END}),this.$=a[u-4];break;case 14:this.$=[a[u-1],{type:"addNote",placement:a[u-2],actor:a[u-1].actor,text:a[u]}];break;case 15:a[u-2]=[].concat(a[u-1],a[u-1]).slice(0,2),a[u-2][0]=a[u-2][0].actor,a[u-2][1]=a[u-2][1].actor,this.$=[a[u-1],{type:"addNote",placement:r.PLACEMENT.OVER,actor:a[u-2].slice(0,2),text:a[u]}];break;case 18:this.$=[a[u-2],a[u]];break;case 19:this.$=a[u];break;case 20:this.$=r.PLACEMENT.LEFTOF;break;case 21:this.$=r.PLACEMENT.RIGHTOF;break;case 22:this.$=[a[u-3],a[u-1],{type:"addMessage",from:a[u-3].actor,to:a[u-1].actor,signalType:a[u-2],msg:a[u]}];break;case 25:this.$={type:"addActor",actor:a[u]};break;case 26:this.$=r.LINETYPE.SOLID_OPEN;break;case 27:this.$=r.LINETYPE.DOTTED_OPEN;break;case 28:this.$=r.LINETYPE.SOLID;break;case 29:this.$=r.LINETYPE.DOTTED;break;case 30:this.$=r.LINETYPE.SOLID_CROSS;break;case 31:this.$=r.LINETYPE.DOTTED_CROSS;break;case 32:this.$=a[u].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e([1,7,9,10,14,16,19,20,22,33],n,{5:3}),{1:[2,1],6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,22:l,33:h},e(f,[2,3]),{8:18,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,22:l,33:h},e(f,[2,5]),e(f,[2,6]),{11:19,33:h},{9:[1,20]},{9:[1,21]},{7:[1,22]},{17:[1,23]},{17:[1,24]},{17:[1,25]},{31:26,34:[1,27],35:[1,28],36:[1,29],37:[1,30],38:[1,31],39:[1,32]},{23:33,25:[1,34],29:[1,35],30:[1,36]},e([9,28,34,35,36,37,38,39,40],[2,25]),e(f,[2,4]),{9:[1,37]},e(f,[2,8]),e(f,[2,9]),{15:[1,38]},e(d,n,{5:39}),e(d,n,{5:40}),e([7,9,10,14,16,19,20,21,22,33],n,{5:41}),{11:42,33:h},{33:[2,26]},{33:[2,27]},{33:[2,28]},{33:[2,29]},{33:[2,30]},{33:[2,31]},{11:43,33:h},{11:45,26:44,33:h},{33:[2,20]},{33:[2,21]},e(f,[2,7]),{9:[1,46]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,47],19:s,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,48],19:s,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,19:s,20:c,21:[1,49],22:l,33:h},{24:50,40:p},{24:52,40:p},{24:53,40:p},{28:[1,54],40:[2,19]},e(f,[2,10]),e(f,[2,11]),e(f,[2,12]),{17:[1,55]},{9:[2,22]},{9:[2,32]},{9:[2,14]},{9:[2,15]},{11:56,33:h},e(d,n,{5:57}),{40:[2,18]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:u,16:o,18:[1,58],19:s,20:c,22:l,33:h},e(f,[2,13])],defaultActions:{27:[2,26],28:[2,27],29:[2,28],30:[2,29],31:[2,30],32:[2,31],35:[2,20],36:[2,21],50:[2,22],51:[2,32],52:[2,14],53:[2,15],56:[2,18]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,u="",o=0,s=0,c=0,l=2,h=1,f=i.slice.call(arguments,1),d=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);d.setInput(t,p.yy),p.yy.lexer=d,p.yy.parser=this,"undefined"==typeof d.yylloc&&(d.yylloc={});var y=d.yylloc;i.push(y);var m=d.options&&d.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,x,w,A,k,E,D,M=function(){var t;return t=d.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?x=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=M()),x=a[b]&&a[b][v]),"undefined"==typeof x||!x.length||!x[0]){var S="";D=[];for(A in a[b])this.terminals_[A]&&A>l&&D.push("'"+this.terminals_[A]+"'");S=d.showPosition?"Parse error on line "+(o+1)+":\n"+d.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(S,{text:d.match,token:this.terminals_[v]||v,line:d.yylineno,loc:y,expected:D})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(x[0]){case 1:n.push(v),r.push(d.yytext),i.push(d.yylloc),n.push(x[1]),v=null,_?(v=_,_=null):(s=d.yyleng,u=d.yytext,o=d.yylineno,y=d.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[x[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),w=this.performAction.apply(C,[u,s,o,p.yy,x[1],r,i].concat(f)),"undefined"!=typeof w)return w;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[x[1]][0]),r.push(C.$),i.push(C._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},y=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,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),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;ae[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:break;case 2:break;case 3:break;case 4:break;case 5:return 10;case 6:return this.begin("LINE"),16;case 7:return this.begin("LINE"),19;case 8:return this.begin("LINE"),20;case 9:return this.begin("LINE"),21;case 10:return this.popState(),17;case 11:return 18;case 12:return 29;case 13:return 30;case 14:return 25;case 15:return 22;case 16:return 14;case 17:return 4;case 18:return 28;case 19:return 9;case 20:return 33;case 21:return 36;case 22:return 37;case 23:return 34;case 24:return 35;case 25:return 38;case 26:return 39;case 27:return 40;case 28:return 9;case 29:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:participant\b)/i,/^(?:loop\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\->:\n,;]+)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[2,3,10],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29],inclusive:!0}}};return t}();return g.lexer=y,t.prototype=g,g.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("_process"))},{_process:3,fs:1,path:2}],123:[function(t,e,n){(function(e){"use strict";var r={},i=[],a=[],u=[],o=t("../../logger"),s=new o.Log;n.addActor=function(t,e,n){r[t]={name:e,description:n},i.push(t)},n.addMessage=function(t,e,n,r){a.push({from:t,to:e,message:n,answer:r})},n.addSignal=function(t,e,n,r){s.debug("Adding message from="+t+" to="+e+" message="+n+" type="+r),a.push({from:t,to:e,message:n,type:r})},n.getMessages=function(){return a},n.getActors=function(){return r},n.getActor=function(t){return r[t]},n.getActorKeys=function(){return Object.keys(r)},n.clear=function(){r={},a=[]},n.LINETYPE={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},n.ARROWTYPE={FILLED:0,OPEN:1},n.PLACEMENT={LEFTOF:0,RIGHTOF:1,OVER:2},n.addNote=function(t,e,r){var i={actor:t,placement:e,message:r},o=[].concat(t,t);u.push(i),a.push({from:o[0],to:o[1],message:r,type:n.LINETYPE.NOTE,placement:e})},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)},n.apply=function(t){if(t instanceof Array)t.forEach(function(t){n.apply(t)});else switch(t.type){case"addActor":n.addActor(t.actor,t.actor,t.actor);break;case"addNote":n.addNote(t.actor,t.placement,t.text);break;case"addMessage":n.addSignal(t.from,t.to,t.msg,t.signalType);break;case"loopStart":n.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"optStart":n.addSignal(void 0,void 0,t.optText,t.signalType);break;case"optEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"altStart":n.addSignal(void 0,void 0,t.altText,t.signalType);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)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":126}],124:[function(t,e,n){"use strict";var r=t("./parser/sequenceDiagram").parser;r.yy=t("./sequenceDb");var i=t("./svgDraw"),a=t("../../d3"),u=t("../../logger"),o=new u.Log,s={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,u=0;this.list.forEach(function(o){u++;var c=a.list.length-u+1;a.updateVal(o,"startx",t-c*s.boxMargin,Math.min),a.updateVal(o,"starty",e-c*s.boxMargin,Math.min),a.updateVal(o,"stopx",r+c*s.boxMargin,Math.max),a.updateVal(o,"stopy",i+c*s.boxMargin,Math.max),a.updateVal(n.bounds.data,"startx",t-c*s.boxMargin,Math.min),a.updateVal(n.bounds.data,"starty",e-c*s.boxMargin,Math.min),a.updateVal(n.bounds.data,"stopx",r+c*s.boxMargin,Math.max),a.updateVal(n.bounds.data,"stopy",i+c*s.boxMargin,Math.max)})},insert:function(t,e,r,i){var a,u,o,s;a=Math.min(t,r),o=Math.max(t,r),u=Math.min(e,i),s=Math.max(e,i),this.updateVal(n.bounds.data,"startx",a,Math.min),this.updateVal(n.bounds.data,"starty",u,Math.min),this.updateVal(n.bounds.data,"stopx",o,Math.max),this.updateVal(n.bounds.data,"stopy",s,Math.max),this.updateLoops(a,u,o,s)},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 c=function(t,e,r,a,u){var o=i.getNoteRect();o.x=e,o.y=r,o.width=u||s.width,o["class"]="note";var c=t.append("g"),l=i.drawRect(c,o),h=i.getTextObj();h.x=e-4,h.y=r-13,h.textMargin=s.noteMargin,h.dy="1em",h.text=a.message,h["class"]="noteText";var f=i.drawText(c,h,o.width-s.noteMargin),d=f[0][0].getBBox().height;!u&&d>s.width?(f.remove(),c=t.append("g"),f=i.drawText(c,h,2*o.width-s.noteMargin),d=f[0][0].getBBox().height,l.attr("width",2*o.width),n.bounds.insert(e,r,e+2*o.width,r+2*s.noteMargin+d)):n.bounds.insert(e,r,e+o.width,r+2*s.noteMargin+d),l.attr("height",d+2*s.noteMargin),n.bounds.bumpVerticalPos(d+2*s.noteMargin)},l=function(t,e,i,a,u){var o,s=t.append("g"),c=e+(i-e)/2,l=s.append("text").attr("x",c).attr("y",a-7).style("text-anchor","middle").attr("class","messageText").text(u.message);o="undefined"!=typeof l[0][0].getBBox?l[0][0].getBBox().width:l[0][0].getBoundingClientRect();var h;if(e===i){h=s.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=s.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());u.type===r.yy.LINETYPE.DOTTED||u.type===r.yy.LINETYPE.DOTTED_CROSS||u.type===r.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0");var d=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;d=d.replace(/\(/g,"\\("),d=d.replace(/\)/g,"\\)"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(u.type===r.yy.LINETYPE.SOLID||u.type===r.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+d+"#arrowhead)"),(u.type===r.yy.LINETYPE.SOLID_CROSS||u.type===r.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+d+"#crosshead)")}; +e.exports.drawActors=function(t,e,r,a){var u;for(u=0;u/gi," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.attr("fill",e.fill),"undefined"!=typeof e["class"]&&i.attr("class",e["class"]);var a=i.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(r),"undefined"!=typeof i.textwrap&&i.textwrap({x:e.x,y:e.y,width:n,height:1800},e.textMargin),i},n.drawLabel=function(t,e){var r=n.getNoteRect();r.x=e.x,r.y=e.y,r.width=50,r.height=20,r.fill="#526e52",r.stroke="none",r["class"]="labelBox",n.drawRect(t,r),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,e.fill="white",n.drawText(t,e)};var r=-1;n.drawActor=function(t,e,i,a,u){var o=e+u.width/2,s=t.append("g");0===i&&(r++,s.append("line").attr("id","actor"+r).attr("x1",o).attr("y1",5).attr("x2",o).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var c=n.getNoteRect();c.x=e,c.y=i,c.fill="#eaeaea",c.width=u.width,c.height=u.height,c["class"]="actor",c.rx=3,c.ry=3,n.drawRect(s,c),s.append("text").attr("x",o).attr("y",i+u.height/2+5).attr("class","actor").style("text-anchor","middle").text(a)},n.drawLoop=function(t,e,r,i){var a=t.append("g"),u=function(t,e,n,r){a.append("line").attr("x1",t).attr("y1",e).attr("x2",n).attr("y2",r).attr("stroke-width",2).attr("stroke","#526e52").attr("class","loopLine")};u(e.startx,e.starty,e.stopx,e.starty),u(e.stopx,e.starty,e.stopx,e.stopy),u(e.startx,e.stopy,e.stopx,e.stopy),u(e.startx,e.starty,e.startx,e.stopy),"undefined"!=typeof e.elsey&&u(e.startx,e.elsey,e.stopx,e.elsey);var o=n.getTextObj();o.text=r,o.x=e.startx,o.y=e.starty,o.labelMargin=1.5*i.boxMargin,o["class"]="labelText",o.fill="white",n.drawLabel(a,o),o=n.getTextObj(),o.text="[ "+e.title+" ]",o.x=e.startx+(e.stopx-e.startx)/2,o.y=e.starty+1.5*i.boxMargin,o.anchor="middle",o["class"]="loopText",n.drawText(a,o),"undefined"!=typeof e.elseText&&(o.text="[ "+e.elseText+" ]",o.y=e.elsey+1.5*i.boxMargin,n.drawText(a,o))},n.insertArrowHead=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")},n.insertArrowCrossHead=function(t){var e=t.append("defs"),n=e.append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);n.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"),n.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")},n.getTextObj=function(){var t={x:0,y:0,fill:"black","text-anchor":"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0};return t},n.getNoteRect=function(){var t={x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0};return t}},{}],126:[function(t,e,n){"use strict";function r(t){var e=t.getUTCHours(),n=t.getUTCMinutes(),r=t.getSeconds(),i=t.getMilliseconds();10>e&&(e="0"+e),10>n&&(n="0"+n),10>r&&(r="0"+r),100>i&&(i="0"+i),10>i&&(i="00"+i);var a=e+":"+n+":"+r+" ("+i+")";return a}function i(t){this.level=t,this.log=function(t,e){var n=this.level;return"undefined"==typeof n&&(n=u),e>=n&&"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log("["+r(new Date)+"] "+t):void 0},this.trace=function(t){this.log(t,a.trace)},this.debug=function(t){this.log(t,a.debug)},this.info=function(t){this.log(t,a.info)},this.warn=function(t){this.log(t,a.warn)},this.error=function(t){this.log(t,a.error)}}var a={debug:1,info:2,warn:3,error:4,fatal:5,"default":5},u=a.error;n.setLogLevel=function(t){u=t},n.Log=i},{}],127:[function(t,e,n){(function(e){"use strict";var r=t("./logger"),i=new r.Log,a=t("./diagrams/flowchart/graphDb"),u=t("./utils"),o=t("./diagrams/flowchart/flowRenderer"),s=t("./diagrams/sequenceDiagram/sequenceRenderer"),c=t("./diagrams/example/exampleRenderer"),l=t("./diagrams/example/parser/example"),h=t("./diagrams/flowchart/parser/flow"),f=t("./diagrams/flowchart/parser/dot"),d=t("./diagrams/sequenceDiagram/parser/sequenceDiagram"),p=t("./diagrams/sequenceDiagram/sequenceDb"),g=t("./diagrams/example/exampleDb"),y=t("./diagrams/gantt/ganttRenderer"),m=t("./diagrams/gantt/parser/gantt"),v=t("./diagrams/gantt/ganttDb"),_=t("./diagrams/classDiagram/parser/classDiagram"),b=t("./diagrams/classDiagram/classRenderer"),x=t("./diagrams/classDiagram/classDb"),w=t("./d3"),A={logLevel:5,cloneCssStyles:!0,startOnLoad:!0,flowchart:{htmlLabels:!0,useMaxWidth:!0},sequenceDiagram:{diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0},gantt:{titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,sidePadding:75,gridLineStartPadding:35,fontSize:11,fontFamily:'"Open-Sans", "sans-serif"',numberSectionStyles:3,axisFormatter:[["%I:%M",function(t){return t.getHours()}],["w. %U",function(t){return 1==t.getDay()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%m-%y",function(t){return t.getMonth()}]]}};r.setLogLevel(A.logLevel);var k=function(t){var e,n=u.detectType(t);switch(n){case"graph":e=h,e.parser.yy=a;break;case"dotGraph":e=f,e.parser.yy=a;break;case"sequenceDiagram":e=d,e.parser.yy=p;break;case"info":e=l,e.parser.yy=g;break;case"gantt":e=m,e.parser.yy=v;break;case"classDiagram":e=_,e.parser.yy=x}try{return e.parse(t),!0}catch(r){return!1}};n.parse=k,n.version=function(){return t("../package.json").version},n.encodeEntities=function(t){var e=t;return e=e.replace(/style.*:\S*#.*;/g,function(t){var e=t.substring(0,t.length-1);return e}),e=e.replace(/classDef.*:\S*#.*;/g,function(t){var e=t.substring(0,t.length-1);return e}),e=e.replace(/#\w+\;/g,function(t){var e=t.substring(1,t.length-1),n=/^\+?\d+$/.test(e);return n?"fl°°"+e+"¶ß":"fl°"+e+"¶ß"})},n.decodeEntities=function(t){var e=t;return e=e.replace(/\fl\°\°/g,function(){return"&#"}),e=e.replace(/\fl\°/g,function(){return"&"}),e=e.replace(/¶ß/g,function(){return";"})};var E=function(t,e,r,l){"undefined"!=typeof l?w.select(l).append("div").attr("id","d"+t).append("svg").attr("id",t).attr("width","100%").attr("xmlns","http://www.w3.org/2000/svg").append("g"):w.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=e,e=n.encodeEntities(e);var h=w.select("#d"+t).node(),f=u.detectType(e),d={};switch(f){case"graph":o.setConf(A.flowchart),o.draw(e,t,!1),A.cloneCssStyles&&(d=o.getClasses(e,!1),u.cloneCssStyles(h.firstChild,d));break;case"dotGraph":o.setConf(A.flowchart),o.draw(e,t,!0),A.cloneCssStyles&&(d=o.getClasses(e,!0),u.cloneCssStyles(h.firstChild,d));break;case"sequenceDiagram":s.setConf(A.sequenceDiagram),s.draw(e,t),A.cloneCssStyles&&u.cloneCssStyles(h.firstChild,[]);break;case"gantt":y.setConf(A.gantt),y.draw(e,t),A.cloneCssStyles&&u.cloneCssStyles(h.firstChild,[]);break;case"classDiagram":b.setConf(A.gantt),b.draw(e,t),A.cloneCssStyles&&u.cloneCssStyles(h.firstChild,[]);break;case"info":c.draw(e,t,n.version()),A.cloneCssStyles&&u.cloneCssStyles(h.firstChild,[])}w.select("#d"+t).selectAll("foreignobject div").attr("xmlns","http://www.w3.org/1999/xhtml");var p=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;p=p.replace(/\(/g,"\\("),p=p.replace(/\)/g,"\\)");var g=w.select("#d"+t).node().innerHTML.replace(/url\(#arrowhead/g,"url("+p+"#arrowhead","g");g=n.decodeEntities(g),console.warn("here"),"undefined"!=typeof r?r(g,a.bindFunctions):i.warn("CB = undefined!");var m=w.select("#d"+t).node();return null!==m&&"function"==typeof m.remove&&w.select("#d"+t).node().remove(),g};n.render=function(t,e,n,r){return"undefined"!=typeof document?E(t,e,n,r):void 0};var D=function(t){var e,n=Object.keys(t);for(e=0;e0&&(r+=n.selectorText+" { "+n.style.cssText+" }\n")}}catch(l){"undefined"!=typeof n&&i.warn('Invalid CSS selector "'+n.selectorText+'"',l)}var h="",f="";for(var d in e)e.hasOwnProperty(d)&&"undefined"!=typeof d&&("default"===d?(e["default"].styles instanceof Array&&(h+="#"+t.id.trim()+" .node>rect { "+e[d].styles.join("; ")+"; }\n"),e["default"].nodeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .node text { "+e[d].nodeLabelStyles.join("; ")+"; }\n"),e["default"].edgeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .edgeLabel text { "+e[d].edgeLabelStyles.join("; ")+"; }\n"),e["default"].clusterStyles instanceof Array&&(h+="#"+t.id.trim()+" .cluster rect { "+e[d].clusterStyles.join("; ")+"; }\n")):e[d].styles instanceof Array&&(f+="#"+t.id.trim()+" ."+d+">rect { "+e[d].styles.join("; ")+"; }\n"));if(""!==r||""!==h||""!==f){var p=document.createElement("style");p.setAttribute("type","text/css"),p.setAttribute("title","mermaid-svg-internal-css"),p.innerHTML="/* */\n",t.insertBefore(p,t.firstChild)}};n.cloneCssStyles=u},{"./logger":126}]},{},[127])(127)}); \ No newline at end of file diff --git a/dist/mermaidAPI.slim.js b/dist/mermaidAPI.slim.js index 61dced6f54..8c71d022b5 100644 --- a/dist/mermaidAPI.slim.js +++ b/dist/mermaidAPI.slim.js @@ -21219,7 +21219,7 @@ module.exports={ "chalk": "^0.5.1", "d3": "3.5.6", "dagre": "^0.7.4", - "dagre-d3": "~0.4.8", + "dagre-d3": "0.4.10", "he": "^0.5.0", "minimist": "^1.1.0", "mkdirp": "^0.5.0", @@ -21766,21 +21766,15 @@ module.exports = d3; },{"d3":"d3"}],107:[function(require,module,exports){ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var relations = []; -var classes = undefined; +var classes; var idCache; -if (typeof Map !== 'undefined') { - classes = new Map(); -} +classes = {}; + // Functions to be run after graph rendering var funs = []; /** @@ -21791,24 +21785,24 @@ var funs = []; * @param style */ exports.addClass = function (id) { - if (typeof classes.get(id) === 'undefined') { - classes.set(id, { + if (typeof classes[id] === 'undefined') { + classes[id] = { id: id, methods: [], members: [] - }); + }; } }; exports.clear = function () { relations = []; - classes.clear(); + classes = {}; }; module.exports.getClass = function (id) { - return classes.get(id); + return classes[id]; }; -module.exports.getClasses = function (id) { +module.exports.getClasses = function () { return classes; }; @@ -21825,7 +21819,7 @@ exports.addRelation = function (relation) { }; exports.addMembers = function (className, MembersArr) { - var theClass = classes.get(className); + var theClass = classes[className]; if (typeof MembersArr === 'string') { if (MembersArr.substr(-1) === ')') { theClass.methods.push(MembersArr); @@ -21863,29 +21857,17 @@ exports.relationType = { 'use strict'; -var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })(); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - -var _dagre = require('dagre'); - -var dagre = _interopRequireWildcard(_dagre); - var cd = require('./parser/classDiagram').parser; var cDDb = require('./classDb'); cd.yy = cDDb; var d3 = require('../../d3'); - +var Logger = require('../../logger'); +var dagre = require('dagre'); var log = new Logger.Log(); var idCache; -if (typeof Map !== 'undefined') { - idCache = new Map(); -} +idCache = {}; + var classCnt = 0; var conf = { dividerMargin: 10, @@ -21895,39 +21877,19 @@ var conf = { // Todo optimize var getGraphId = function getGraphId(label) { - var _iteratorNormalCompletion = true; - var _didIteratorError = false; - var _iteratorError = undefined; + var keys = Object.keys(idCache); - try { - for (var _iterator = idCache[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { - var _step$value = _slicedToArray(_step.value, 2); - - var id = _step$value[0]; - var classInfo = _step$value[1]; - - if (classInfo.label === label) { - return id; - } - } - } catch (err) { - _didIteratorError = true; - _iteratorError = err; - } finally { - try { - if (!_iteratorNormalCompletion && _iterator['return']) { - _iterator['return'](); - } - } finally { - if (_didIteratorError) { - throw _iteratorError; - } + var i; + for (i = 0; i < keys.length; i++) { + if (idCache[keys[i]].label === label) { + return keys[i]; } } return undefined; }; +window.tunk = getGraphId; /** * Setup arrow head and define the marker. The result is appended to the svg. */ @@ -22057,34 +22019,34 @@ var drawClass = function drawClass(elem, classDef) { .attr('x', conf.padding).attr('y', titleHeight + conf.dividerMargin + conf.textHeight).attr('fill', 'white').attr('class', 'classText'); var isFirst = true; - var _iteratorNormalCompletion2 = true; - var _didIteratorError2 = false; - var _iteratorError2 = undefined; + var _iteratorNormalCompletion = true; + var _didIteratorError = false; + var _iteratorError = undefined; try { - for (var _iterator2 = classDef.members[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) { - var member = _step2.value; + for (var _iterator = classDef.members[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { + var member = _step.value; addTspan(members, member, isFirst); isFirst = false; } - - //console.warn(JSON.stringify(classDef)); } catch (err) { - _didIteratorError2 = true; - _iteratorError2 = err; + _didIteratorError = true; + _iteratorError = err; } finally { try { - if (!_iteratorNormalCompletion2 && _iterator2['return']) { - _iterator2['return'](); + if (!_iteratorNormalCompletion && _iterator['return']) { + _iterator['return'](); } } finally { - if (_didIteratorError2) { - throw _iteratorError2; + if (_didIteratorError) { + throw _iteratorError; } } } + console.warn(JSON.stringify(classDef)); + var membersBox = members.node().getBBox(); var methodsLine = g.append('line') // text label for the x axis @@ -22094,28 +22056,28 @@ var drawClass = function drawClass(elem, classDef) { .attr('x', conf.padding).attr('y', titleHeight + 2 * conf.dividerMargin + membersBox.height + conf.textHeight).attr('fill', 'white').attr('class', 'classText'); isFirst = true; - var _iteratorNormalCompletion3 = true; - var _didIteratorError3 = false; - var _iteratorError3 = undefined; + var _iteratorNormalCompletion2 = true; + var _didIteratorError2 = false; + var _iteratorError2 = undefined; try { - for (var _iterator3 = classDef.methods[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { - var method = _step3.value; + for (var _iterator2 = classDef.methods[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) { + var method = _step2.value; addTspan(methods, method, isFirst); isFirst = false; } } catch (err) { - _didIteratorError3 = true; - _iteratorError3 = err; + _didIteratorError2 = true; + _iteratorError2 = err; } finally { try { - if (!_iteratorNormalCompletion3 && _iterator3['return']) { - _iterator3['return'](); + if (!_iteratorNormalCompletion2 && _iterator2['return']) { + _iterator2['return'](); } } finally { - if (_didIteratorError3) { - throw _iteratorError3; + if (_didIteratorError2) { + throw _iteratorError2; } } } @@ -22129,7 +22091,8 @@ var drawClass = function drawClass(elem, classDef) { classInfo.width = classBox.width + 2 * conf.padding; classInfo.height = classBox.height + conf.padding + 0.5 * conf.dividerMargin; - idCache.set(id, classInfo); + console.warn('setting id: ' + id + ' to ' + JSON.stringify(classInfo)); + idCache[id] = classInfo; classCnt++; return classInfo; }; @@ -22173,75 +22136,60 @@ module.exports.draw = function (text, id) { }); var classes = cDDb.getClasses(); - var _iteratorNormalCompletion4 = true; - var _didIteratorError4 = false; - var _iteratorError4 = undefined; - - try { - for (var _iterator4 = classes.values()[Symbol.iterator](), _step4; !(_iteratorNormalCompletion4 = (_step4 = _iterator4.next()).done); _iteratorNormalCompletion4 = true) { - var classDef = _step4.value; - - var node = drawClass(diagram, classDef); - // Add nodes to the graph. The first argument is the node id. The second is - // metadata about the node. In this case we're going to add labels to each of - // our nodes. - g.setNode(node.id, node); - log.info('Org height: ' + node.height); - //g.setNode("swilliams", { label: "Saul Williams", width: 160, height: 100 }); - //g.setNode("bpitt", { label: "Brad Pitt", width: 108, height: 100 }); - //g.setNode("hford", { label: "Harrison Ford", width: 168, height: 100 }); - //g.setNode("lwilson", { label: "Luke Wilson", width: 144, height: 100 }); - //g.setNode("kbacon", { label: "Kevin Bacon", width: 121, height: 100 }); - } - } catch (err) { - _didIteratorError4 = true; - _iteratorError4 = err; - } finally { - try { - if (!_iteratorNormalCompletion4 && _iterator4['return']) { - _iterator4['return'](); - } - } finally { - if (_didIteratorError4) { - throw _iteratorError4; - } - } + var keys = Object.keys(classes); + var i; + for (i = 0; i < keys.length; i++) { + var classDef = classes[keys[i]]; + var node = drawClass(diagram, classDef); + // Add nodes to the graph. The first argument is the node id. The second is + // metadata about the node. In this case we're going to add labels to each of + // our nodes. + g.setNode(node.id, node); + log.info('Org height: ' + node.height); + //g.setNode("swilliams", { label: "Saul Williams", width: 160, height: 100 }); + //g.setNode("bpitt", { label: "Brad Pitt", width: 108, height: 100 }); + //g.setNode("hford", { label: "Harrison Ford", width: 168, height: 100 }); + //g.setNode("lwilson", { label: "Luke Wilson", width: 144, height: 100 }); + //g.setNode("kbacon", { label: "Kevin Bacon", width: 121, height: 100 }); } var relations = cDDb.getRelations(); var i = 0; - var _iteratorNormalCompletion5 = true; - var _didIteratorError5 = false; - var _iteratorError5 = undefined; + var _iteratorNormalCompletion3 = true; + var _didIteratorError3 = false; + var _iteratorError3 = undefined; try { - for (var _iterator5 = relations[Symbol.iterator](), _step5; !(_iteratorNormalCompletion5 = (_step5 = _iterator5.next()).done); _iteratorNormalCompletion5 = true) { - var relation = _step5.value; + for (var _iterator3 = relations[Symbol.iterator](), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) { + var relation = _step3.value; i = i + 1; + log.info('tjoho' + getGraphId(relation.id1) + getGraphId(relation.id2) + JSON.stringify(relation)); g.setEdge(getGraphId(relation.id1), getGraphId(relation.id2), { relation: relation }); } } catch (err) { - _didIteratorError5 = true; - _iteratorError5 = err; + _didIteratorError3 = true; + _iteratorError3 = err; } finally { try { - if (!_iteratorNormalCompletion5 && _iterator5['return']) { - _iterator5['return'](); + if (!_iteratorNormalCompletion3 && _iterator3['return']) { + _iterator3['return'](); } } finally { - if (_didIteratorError5) { - throw _iteratorError5; + if (_didIteratorError3) { + throw _iteratorError3; } } } dagre.layout(g); g.nodes().forEach(function (v) { - log.debug('Node ' + v + ': ' + JSON.stringify(g.node(v))); - d3.select('#' + v).attr('transform', 'translate(' + (g.node(v).x - g.node(v).width / 2) + ',' + (g.node(v).y - g.node(v).height / 2) + ' )'); - //d3.select('#' +v +' rect').attr('x',(g.node(v).x-(g.node(v).width/2))) - //.attr('y',(g.node(v).y-(g.node(v).height/2))); + if (typeof v !== 'undefined') { + log.debug('Node ' + v + ': ' + JSON.stringify(g.node(v))); + d3.select('#' + v).attr('transform', 'translate(' + (g.node(v).x - g.node(v).width / 2) + ',' + (g.node(v).y - g.node(v).height / 2) + ' )'); + //d3.select('#' +v +' rect').attr('x',(g.node(v).x-(g.node(v).width/2))) + //.attr('y',(g.node(v).y-(g.node(v).height/2))); + } }); g.edges().forEach(function (e) { log.debug('Edge ' + e.v + ' -> ' + e.w + ': ' + JSON.stringify(g.edge(e))); @@ -23075,12 +23023,7 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var message = ''; @@ -23114,16 +23057,10 @@ exports.parseError = function (err, hash) { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var db = require('./exampleDb'); var exampleParser = require('./parser/example.js'); var d3 = require('../../d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); /** @@ -23807,12 +23744,7 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { /* global window */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var dagreD3; @@ -23838,18 +23770,12 @@ module.exports = dagreD3; */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var graph = require('./graphDb'); var flow = require('./parser/flow'); var dot = require('./parser/dot'); var d3 = require('../../d3'); var dagreD3 = require('./dagre-d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var conf = {}; @@ -24280,12 +24206,7 @@ exports.draw = function (text, id, isDot) { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('../../logger'); var log = new Logger.Log(); var d3 = require('../../d3'); @@ -26615,14 +26536,8 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var moment = require('moment'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var dateFormat = ''; @@ -28851,17 +28766,11 @@ if (typeof require !== 'undefined' && typeof exports !== 'undefined') { */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var actors = {}; var actorKeys = []; var messages = []; var notes = []; - +var Logger = require('../../logger'); var log = new Logger.Log(); exports.addActor = function (id, name, description) { @@ -28998,17 +28907,11 @@ exports.apply = function (param) { 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('../../logger'); - -var Logger = _interopRequireWildcard(_logger); - var sq = require('./parser/sequenceDiagram').parser; sq.yy = require('./sequenceDb'); var svgDraw = require('./svgDraw'); var d3 = require('../../d3'); - +var Logger = require('../../logger'); var log = new Logger.Log(); var conf = { @@ -29615,10 +29518,6 @@ exports.getNoteRect = function () { 'use strict'; -var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })(); - -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } - var LEVELS = { debug: 1, info: 2, @@ -29662,59 +29561,45 @@ function formatTime(timestamp) { return t; } -var Log = (function () { - function Log(level) { - _classCallCheck(this, Log); - - this.level = level; - } +function Log(level) { + this.level = level; - _createClass(Log, [{ - key: 'log', - value: function log(str, level) { - var logLevel = this.level; - if (typeof logLevel === 'undefined') { - logLevel = defaultLevel; - } - if (logLevel <= level) { - if (typeof console !== 'undefined') { + this.log = function (str, level) { + var logLevel = this.level; + if (typeof logLevel === 'undefined') { + logLevel = defaultLevel; + } + if (logLevel <= level) { + if (typeof console !== 'undefined') { + //eslint-disable-line no-console + if (typeof console.log !== 'undefined') { //eslint-disable-line no-console - if (typeof console.log !== 'undefined') { - //eslint-disable-line no-console - return console.log('[' + formatTime(new Date()) + '] ' + str); //eslint-disable-line no-console - } + return console.log('[' + formatTime(new Date()) + '] ' + str); //eslint-disable-line no-console } } } - }, { - key: 'trace', - value: function trace(str) { - this.log(str, LEVELS.trace); - } - }, { - key: 'debug', - value: function debug(str) { - this.log(str, LEVELS.debug); - } - }, { - key: 'info', - value: function info(str) { - this.log(str, LEVELS.info); - } - }, { - key: 'warn', - value: function warn(str) { - this.log(str, LEVELS.warn); - } - }, { - key: 'error', - value: function error(str) { - this.log(str, LEVELS.error); - } - }]); + }; - return Log; -})(); + this.trace = function (str) { + this.log(str, LEVELS.trace); + }; + + this.debug = function (str) { + this.log(str, LEVELS.debug); + }; + + this.info = function (str) { + this.log(str, LEVELS.info); + }; + + this.warn = function (str) { + this.log(str, LEVELS.warn); + }; + + this.error = function (str) { + this.log(str, LEVELS.error); + }; +} exports.Log = Log; @@ -29735,12 +29620,7 @@ exports.Log = Log; */ 'use strict'; -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('./logger'); var log = new Logger.Log(); var graph = require('./diagrams/flowchart/graphDb'); @@ -30149,6 +30029,8 @@ var render = function render(id, txt, cb, container) { var svgCode = d3.select('#d' + id).node().innerHTML.replace(/url\(#arrowhead/g, 'url(' + url + '#arrowhead', 'g'); svgCode = exports.decodeEntities(svgCode); + console.warn('here'); + //console.warn('mermaid decode: '); //console.warn(svgCode); //var he = require('he'); @@ -30156,13 +30038,15 @@ var render = function render(id, txt, cb, container) { if (typeof cb !== 'undefined') { cb(svgCode, graph.bindFunctions); } else { - log.warn('CB = undefined'); + log.warn('CB = undefined!'); } var node = d3.select('#d' + id).node(); if (node !== null && typeof node.remove === 'function') { d3.select('#d' + id).node().remove(); } + + return svgCode; }; exports.render = function (id, text, cb, containerElement) { @@ -30170,7 +30054,7 @@ exports.render = function (id, text, cb, containerElement) { // Todo handle rendering serverside using phantomjs } else { // In browser - render(id, text, cb, containerElement); + return render(id, text, cb, containerElement); } }; @@ -30234,16 +30118,7 @@ global.mermaidAPI = { */ 'use strict'; -Object.defineProperty(exports, '__esModule', { - value: true -}); - -function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj['default'] = obj; return newObj; } } - -var _logger = require('./logger'); - -var Logger = _interopRequireWildcard(_logger); - +var Logger = require('./logger'); var log = new Logger.Log(); /** diff --git a/dist/mermaidAPI.slim.min.js b/dist/mermaidAPI.slim.min.js index f0872f496b..3490a2b5aa 100644 --- a/dist/mermaidAPI.slim.min.js +++ b/dist/mermaidAPI.slim.min.js @@ -1,12 +1,12 @@ -!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.mermaidAPI=t()}}(function(){var define,module,exports;return 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);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var l=n[s]={exports:{}};e[s][0].call(l.exports,function(t){var n=e[s][1][t];return i(n?n:t)},l,l.exports,t,e,n,r)}return n[s].exports}for(var a="function"==typeof require&&require,s=0;s=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=-1&&!i;a--){var s=a>=0?arguments[a]:t.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(n=s+"/"+n,i="/"===s.charAt(0))}return n=e(r(n.split("/"),function(t){return!!t}),!i).join("/"),(i?"/":"")+n||"."},n.normalize=function(t){var i=n.isAbsolute(t),a="/"===s(t,-1);return t=e(r(t.split("/"),function(t){return!!t}),!i).join("/"),t||i||(t="."),t&&a&&(t+="/"),(i?"/":"")+t},n.isAbsolute=function(t){return"/"===t.charAt(0)},n.join=function(){var t=Array.prototype.slice.call(arguments,0);return n.normalize(r(t,function(t){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},n.relative=function(t,e){function r(t){for(var e=0;e=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=n.resolve(t).substr(1),e=n.resolve(e).substr(1);for(var i=r(t.split("/")),a=r(e.split("/")),s=Math.min(i.length,a.length),o=s,u=0;s>u;u++)if(i[u]!==a[u]){o=u;break}for(var c=[],u=o;ue&&(e=t.length+e),t.substr(e,n)}}).call(this,t("_process"))},{_process:3}],3:[function(t,e){function n(){}var r=e.exports={};r.nextTick=function(){var t="undefined"!=typeof window&&window.setImmediate,e="undefined"!=typeof window&&window.MutationObserver,n="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(t)return function(t){return window.setImmediate(t)};var r=[];if(e){var i=document.createElement("div"),a=new MutationObserver(function(){var t=r.slice();r.length=0,t.forEach(function(t){t()})});return a.observe(i,{attributes:!0}),function(t){r.length||i.setAttribute("yes","no"),r.push(t)}}return n?(window.addEventListener("message",function(t){var e=t.source;if((e===window||null===e)&&"process-tick"===t.data&&(t.stopPropagation(),r.length>0)){var n=r.shift();n()}},!0),function(t){r.push(t),window.postMessage("process-tick","*")}):function(t){setTimeout(t,0)}}(),r.title="browser",r.browser=!0,r.env={},r.argv=[],r.on=n,r.addListener=n,r.once=n,r.off=n,r.removeListener=n,r.removeAllListeners=n,r.emit=n,r.binding=function(){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(){throw new Error("process.chdir is not supported")}},{}],4:[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":11,"./lib/graphlib":12,"./lib/intersect":13,"./lib/render":28,"./lib/util":30,"./lib/version":31}],5:[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":30}],6:[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":21,"./util":30}],7:[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":10,"./label/add-label":21,"./lodash":24,"./util":30}],8:[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,"arrowhead")}),i}function r(t,e){var n=t.edge(e),r=t.node(e.v),a=t.node(e.w),s=n.points.slice(1,n.points.length-1);return s.unshift(c(r,s[0])),s.push(c(a,s[s.length-1])),i(n,s)}function i(t,e){var n=h.svg.line().x(function(t){return t.x}).y(function(t){return t.y});return u.has(t,"lineInterpolate")&&n.interpolate(t.lineInterpolate),u.has(t,"lineTension")&&n.tension(Number(t.lineTension)),n(e)}function a(t){var e=t.getBBox(),n=t.getTransformToElement(t.ownerSVGElement).translate(e.width/2,e.height/2);return{x:n.e,y:n.f}}function s(t,e){var n=t.enter().append("g").attr("class","edgePath").style("opacity",0);n.append("path").attr("class","path").attr("d",function(t){var n=e.edge(t),r=e.node(t.v).elem,s=u.range(n.points.length).map(function(){return a(r)});return i(n,s)}),n.append("defs")}function o(t,e){var n=t.exit();l.applyTransition(n,e).style("opacity",0).remove(),l.applyTransition(n.select("path.path"),e).attr("d",function(t){var n=e.node(t.v);if(n){var r=u.range(this.pathSegList.length).map(function(){return n});return i({},r)}return h.select(this).attr("d")})}var u=t("./lodash"),c=t("./intersect/intersect-node"),l=t("./util"),h=t("./d3");e.exports=n},{"./d3":10,"./intersect/intersect-node":17,"./lodash":24,"./util":30}],9:[function(t,e){"use strict";function n(t,e,n){var o=e.nodes().filter(function(t){return!a.isSubgraph(e,t)}),u=t.selectAll("g.node").data(o,function(t){return t}).classed("update",!0);return u.selectAll("*").remove(),u.enter().append("g").attr("class","node").style("opacity",0),u.each(function(t){var o=e.node(t),u=s.select(this),c=u.append("g").attr("class","label"),l=i(c,o),h=n[o.shape],d=r.pick(l.node().getBBox(),"width","height");o.elem=this,o.id&&u.attr("id",o.id),o.labelId&&c.attr("id",o.labelId),a.applyClass(u,o["class"],(u.classed("update")?"update ":"")+"node"),r.has(o,"width")&&(d.width=o.width),r.has(o,"height")&&(d.height=o.height),d.width+=o.paddingLeft+o.paddingRight,d.height+=o.paddingTop+o.paddingBottom,c.attr("transform","translate("+(o.paddingLeft-o.paddingRight)/2+","+(o.paddingTop-o.paddingBottom)/2+")");var f=h(s.select(this),d,o);a.applyStyle(f,o.style);var p=f.node().getBBox();o.width=p.width,o.height=p.height}),a.applyTransition(u.exit(),e).style("opacity",0).remove(),u}var r=t("./lodash"),i=t("./label/add-label"),a=t("./util"),s=t("./d3");e.exports=n},{"./d3":10,"./label/add-label":21,"./lodash":24,"./util":30}],10:[function(t,e){e.exports=window.d3},{}],11:[function(t,e){var n;if(t)try{n=t("dagre")}catch(r){}n||(n=window.dagre),e.exports=n},{dagre:53}],12:[function(t,e){var n;if(t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:32}],13:[function(t,e){e.exports={node:t("./intersect-node"),circle:t("./intersect-circle"),ellipse:t("./intersect-ellipse"),polygon:t("./intersect-polygon"),rect:t("./intersect-rect")}},{"./intersect-circle":14,"./intersect-ellipse":15,"./intersect-node":17,"./intersect-polygon":18,"./intersect-rect":19}],14:[function(t,e){function n(t,e,n){return r(t,e,e,n)}var r=t("./intersect-ellipse");e.exports=n},{"./intersect-ellipse":15}],15:[function(t,e){function n(t,e,n,r){var i=t.x,a=t.y,s=i-r.x,o=a-r.y,u=Math.sqrt(e*e*o*o+n*n*s*s),c=Math.abs(e*n*s/u);r.xm?(m-y)/g:(m+y)/g,m=s*c-a*l,_=0>m?(m-y)/g:(m+y)/g,{x:v,y:_})}function r(t,e){return t*e>0}e.exports=n},{}],17:[function(t,e){function n(t,e){return t.intersect(e)}e.exports=n},{}],18:[function(t,e){function n(t,e,n){var i=t.x,a=t.y,s=[],o=Number.POSITIVE_INFINITY,u=Number.POSITIVE_INFINITY;e.forEach(function(t){o=Math.min(o,t.x),u=Math.min(u,t.y)});for(var c=i-t.width/2-o,l=a-t.height/2-u,h=0;h1&&s.sort(function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),s=e.x-n.x,o=e.y-n.y,u=Math.sqrt(s*s+o*o);return u>a?-1:a===u?0:1}),s[0]):(console.log("NO INTERSECTION FOUND, RETURN NODE CENTER",t),t)}var r=t("./intersect-line");e.exports=n},{"./intersect-line":16}],19:[function(t,e){function n(t,e){var n,r,i=t.x,a=t.y,s=e.x-i,o=e.y-a,u=t.width/2,c=t.height/2;return Math.abs(o)*u>Math.abs(s)*c?(0>o&&(c=-c),n=0===o?0:c*s/o,r=c):(0>s&&(u=-u),n=u,r=0===s?0:u*o/s),{x:i+n,y:a+r}}e.exports=n},{}],20:[function(t,e){function n(t,e){var n=t.append("foreignObject").attr("width","100000"),i=n.append("xhtml:div"),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 s,o;return i.each(function(){s=this.clientWidth,o=this.clientHeight}),n.attr("width",s).attr("height",o),n}var r=t("../util");e.exports=n},{"../util":30}],21:[function(t,e){function n(t,e,n){var s=e.label,o=t.append("g");"svg"===e.labelType?a(o,e):"string"!=typeof s||"html"===e.labelType?i(o,e):r(o,e);var u,c=o.node().getBBox();switch(n){case"top":u=-e.height/2;break;case"bottom":u=e.height/2-c.height;break;default:u=-c.height/2}return o.attr("transform","translate("+-c.width/2+","+u+")"),o}var r=t("./add-text-label"),i=t("./add-html-label"),a=t("./add-svg-label");e.exports=n},{"./add-html-label":20,"./add-svg-label":22,"./add-text-label":23}],22:[function(t,e){function n(t,e){var n=t;return n.node().appendChild(e.label),r.applyStyle(n,e.labelStyle),n}var r=t("../util");e.exports=n},{"../util":30}],23:[function(t,e){function n(t,e){for(var n=t.append("text"),a=r(e.label).split("\n"),s=0;sa)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+t+" Weight: "+a);c0&&(i=u.removeMin(),s=o[i],s.distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return o}var i=t("../lodash"),a=t("../data/priority-queue");e.exports=n;var s=i.constant(1)},{"../data/priority-queue":46,"../lodash":50}],37:[function(t,e){function n(t){return r.filter(i(t),function(e){return e.length>1||1===e.length&&t.hasEdge(e[0],e[0])})}var r=t("../lodash"),i=t("./tarjan");e.exports=n},{"../lodash":50,"./tarjan":44}],38:[function(t,e){function n(t,e,n){return r(t,e||a,n||function(e){return t.outEdges(e)})}function r(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],s=a[n],o=r.distance+i.distance;oi&&(u[n]=s,c.decrease(n,i))}}var s,o=new i,u={},c=new 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(s=c.removeMin(),r.has(u,s))o.setEdge(s,u[s]);else{if(l)throw new Error("Input graph is not connected: "+t);l=!0}t.nodeEdges(s).forEach(n)}return o}var r=t("../lodash"),i=t("../graph"),a=t("../data/priority-queue");e.exports=n},{"../data/priority-queue":46,"../graph":47,"../lodash":50}],44:[function(t,e){function n(t){function e(o){var u=a[o]={onStack:!0,lowlink:n,index:n++};if(i.push(o),t.successors(o).forEach(function(t){r.has(a,t)?a[t].onStack&&(u.lowlink=Math.min(u.lowlink,a[t].index)):(e(t),u.lowlink=Math.min(u.lowlink,a[t].lowlink))}),u.lowlink===u.index){var c,l=[];do c=i.pop(),a[c].onStack=!1,l.push(c);while(o!==c);s.push(l)}}var n=0,i=[],a={},s=[];return t.nodes().forEach(function(t){r.has(a,t)||e(t)}),s}var r=t("../lodash");e.exports=n},{"../lodash":50}],45:[function(t,e){function n(t){function e(o){if(i.has(a,o))throw new r;i.has(n,o)||(a[o]=!0,n[o]=!0,i.each(t.predecessors(o),e),delete a[o],s.push(o))}var n={},a={},s=[];if(i.each(t.sinks(),e),i.size(n)!==t.nodeCount())throw new r;return s}function r(){}var i=t("../lodash");e.exports=n,n.CycleException=r},{"../lodash":50}],46:[function(t,e){function n(){this._arr=[],this._keyIndices={}}var r=t("../lodash");e.exports=n,n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(t){return t.key})},n.prototype.has=function(t){return r.has(this._keyIndices,t)},n.prototype.priority=function(t){var e=this._keyIndices[t];return void 0!==e?this._arr[e].priority:void 0},n.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},n.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},n.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},n.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)},n.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,i=t;n>1,!(n[e].prioritya){var s=i;i=a,a=s}return i+h+a+h+(u.isUndefined(r)?c:r)}function s(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var s=i;i=a,a=s}var o={v:i,w:a};return r&&(o.name=r),o}function o(t,e){return a(t,e.v,e.w,e.name)}var u=t("./lodash");e.exports=n;var c="\x00",l="\x00",h="";n.prototype._nodeCount=0,n.prototype._edgeCount=0,n.prototype.isDirected=function(){return this._isDirected},n.prototype.isMultigraph=function(){return this._isMultigraph},n.prototype.isCompound=function(){return this._isCompound},n.prototype.setGraph=function(t){return this._label=t,this},n.prototype.graph=function(){return this._label},n.prototype.setDefaultNodeLabel=function(t){return u.isFunction(t)||(t=u.constant(t)),this._defaultNodeLabelFn=t,this},n.prototype.nodeCount=function(){return this._nodeCount},n.prototype.nodes=function(){return u.keys(this._nodes)},n.prototype.sources=function(){return u.filter(this.nodes(),function(t){return u.isEmpty(this._in[t])},this)},n.prototype.sinks=function(){return u.filter(this.nodes(),function(t){return u.isEmpty(this._out[t])},this)},n.prototype.setNodes=function(t,e){var n=arguments;return u.each(t,function(t){n.length>1?this.setNode(t,e):this.setNode(t)},this),this},n.prototype.setNode=function(t,e){return u.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]=l,this._children[t]={},this._children[l][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},n.prototype.node=function(t){return this._nodes[t]},n.prototype.hasNode=function(t){return u.has(this._nodes,t)},n.prototype.removeNode=function(t){var e=this;if(u.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],u.each(this.children(t),function(t){this.setParent(t)},this),delete this._children[t]),u.each(u.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],u.each(u.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},n.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(u.isUndefined(e))e=l;else{e+="";for(var n=e;!u.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},n.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},n.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!==l)return e}},n.prototype.children=function(t){if(u.isUndefined(t)&&(t=l),this._isCompound){var e=this._children[t];if(e)return u.keys(e)}else{if(t===l)return this.nodes();if(this.hasNode(t))return[]}},n.prototype.predecessors=function(t){var e=this._preds[t];return e?u.keys(e):void 0},n.prototype.successors=function(t){var e=this._sucs[t];return e?u.keys(e):void 0},n.prototype.neighbors=function(t){var e=this.predecessors(t);return e?u.union(e,this.successors(t)):void 0},n.prototype.filterNodes=function(t){function e(t){var a=r.parent(t);return void 0===a||n.hasNode(a)?(i[t]=a,a):a in i?i[a]:e(a)}var n=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});n.setGraph(this.graph()),u.each(this._nodes,function(e,r){t(r)&&n.setNode(r,e)},this),u.each(this._edgeObjs,function(t){n.hasNode(t.v)&&n.hasNode(t.w)&&n.setEdge(t,this.edge(t))},this);var r=this,i={};return this._isCompound&&u.each(n.nodes(),function(t){n.setParent(t,e(t))}),n},n.prototype.setDefaultEdgeLabel=function(t){return u.isFunction(t)||(t=u.constant(t)),this._defaultEdgeLabelFn=t,this},n.prototype.edgeCount=function(){return this._edgeCount},n.prototype.edges=function(){return u.values(this._edgeObjs)},n.prototype.setPath=function(t,e){var n=this,r=arguments;return u.reduce(t,function(t,i){return r.length>1?n.setEdge(t,i,e):n.setEdge(t,i),i}),this},n.prototype.setEdge=function(){var t,e,n,i,o=!1,c=arguments[0];"object"==typeof c&&null!==c&&"v"in c?(t=c.v,e=c.w,n=c.name,2===arguments.length&&(i=arguments[1],o=!0)):(t=c,e=arguments[1],n=arguments[3],arguments.length>2&&(i=arguments[2],o=!0)),t=""+t,e=""+e,u.isUndefined(n)||(n=""+n);var l=a(this._isDirected,t,e,n);if(u.has(this._edgeLabels,l))return o&&(this._edgeLabels[l]=i),this;if(!u.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[l]=o?i:this._defaultEdgeLabelFn(t,e,n);var h=s(this._isDirected,t,e,n);return t=h.v,e=h.w,Object.freeze(h),this._edgeObjs[l]=h,r(this._preds[e],t),r(this._sucs[t],e),this._in[e][l]=h,this._out[t][l]=h,this._edgeCount++,this},n.prototype.edge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return this._edgeLabels[r]},n.prototype.hasEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n);return u.has(this._edgeLabels,r)},n.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):a(this._isDirected,t,e,n),s=this._edgeObjs[r];return s&&(t=s.v,e=s.w,delete this._edgeLabels[r],delete this._edgeObjs[r],i(this._preds[e],t),i(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},n.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var r=u.values(n);return e?u.filter(r,function(t){return t.v===e}):r}},n.prototype.outEdges=function(t,e){var n=this._out[t];if(n){ -var r=u.values(n);return e?u.filter(r,function(t){return t.w===e}):r}},n.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);return n?n.concat(this.outEdges(t,e)):void 0}},{"./lodash":50}],48:[function(t,e){e.exports={Graph:t("./graph"),version:t("./version")}},{"./graph":47,"./version":51}],49:[function(t,e){function n(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:r(t),edges:i(t)};return s.isUndefined(t.graph())||(e.value=s.clone(t.graph())),e}function r(t){return s.map(t.nodes(),function(e){var n=t.node(e),r=t.parent(e),i={v:e};return s.isUndefined(n)||(i.value=n),s.isUndefined(r)||(i.parent=r),i})}function i(t){return s.map(t.edges(),function(e){var n=t.edge(e),r={v:e.v,w:e.w};return s.isUndefined(e.name)||(r.name=e.name),s.isUndefined(n)||(r.value=n),r})}function a(t){var e=new o(t.options).setGraph(t.value);return s.each(t.nodes,function(t){e.setNode(t.v,t.value),t.parent&&e.setParent(t.v,t.parent)}),s.each(t.edges,function(t){e.setEdge({v:t.v,w:t.w,name:t.name},t.value)}),e}var s=t("./lodash"),o=t("./graph");e.exports={write:n,read:a}},{"./graph":47,"./lodash":50}],50:[function(t,e){var n;if("function"==typeof t)try{n=t("lodash")}catch(r){}n||(n=window._),e.exports=n},{lodash:52}],51:[function(t,e){e.exports="1.0.7"},{}],52:[function(t,e,n){(function(t){(function(){function r(t,e){if(t!==e){var n=null===t,r=t===E,i=t===t,a=null===e,s=e===E,o=e===e;if(t>e&&!a||!i||n&&!s&&o||r&&o)return 1;if(e>t&&!n||!o||a&&!r&&i||s&&i)return-1}return 0}function i(t,e,n){for(var r=t.length,i=n?r:-1;n?i--:++i-1;);return n}function c(t,e){for(var n=t.length;n--&&e.indexOf(t.charAt(n))>-1;);return n}function l(t,e){return r(t.criteria,e.criteria)||t.index-e.index}function h(t,e,n){for(var i=-1,a=t.criteria,s=e.criteria,o=a.length,u=n.length;++i=u)return c;var l=n[i];return c*("asc"===l||l===!0?1:-1)}}return t.index-e.index}function d(t){return Gt[t]}function f(t){return Vt[t]}function p(t,e,n){return e?t=qt[t]:n&&(t=Xt[t]),"\\"+t}function g(t){return"\\"+Xt[t]}function y(t,e,n){for(var r=t.length,i=e+(n?0:-1);n?i--:++i=t&&t>=9&&13>=t||32==t||160==t||5760==t||6158==t||t>=8192&&(8202>=t||8232==t||8233==t||8239==t||8287==t||12288==t||65279==t)}function _(t,e){for(var n=-1,r=t.length,i=-1,a=[];++ne,i=n?t.length:0,a=Hn(0,i,this.__views__),s=a.start,o=a.end,u=o-s,c=r?o:s-1,l=this.__iteratees__,h=l.length,d=0,f=xs(u,this.__takeCount__);if(!n||Y>i||i==u&&f==u)return nn(r&&n?t.reverse():t,this.__actions__);var p=[];t:for(;u--&&f>d;){c+=e;for(var g=-1,y=t[c];++g=Y?gn(e):null,c=e.length;u&&(s=Kt,o=!1,e=u);t:for(;++in&&(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 Ce(t,e){var n=[];return Ls(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}function Fe(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 Te(t,e,n,r){r||(r=[]);for(var i=-1,a=t.length;++ir;)t=t[e[r++]];return r&&r==i?t:E}}function Le(t,e,n,r,i,a){return t===e?!0:null==t||null==e||!Mi(t)&&!m(e)?t!==t&&e!==e:Pe(t,e,Le,n,r,i,a)}function Pe(t,e,n,r,i,a,s){var o=To(t),u=To(e),c=H,l=H;o||(c=ns.call(t),c==V?c=J:c!=J&&(o=Wi(t))),u||(l=ns.call(e),l==V?l=J:l!=J&&(u=Wi(e)));var h=c==J,d=l==J,f=c==l;if(f&&!o&&!h)return jn(t,e,c);if(!i){var p=h&&ts.call(t,"__wrapped__"),g=d&&ts.call(e,"__wrapped__");if(p||g)return n(p?t.value():t,g?e.value():e,r,i,a,s)}if(!f)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?Rn:Yn)(t,e,n,r,i,a,s);return a.pop(),s.pop(),m}function Ne(t,e,n){var r=e.length,i=r,a=!n;if(null==t)return!i;for(t=hr(t);r--;){var s=e[r];if(a&&s[2]?s[1]!==t[s[0]]:!(s[0]in t))return!1}for(;++re&&(e=-e>i?0:i+e),n=n===E||n>i?i:+n||0,0>n&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var a=Ya(i);++r=Y,u=o?gn():null,c=[];u?(r=Kt,s=!1):(o=!1,u=e?[]:c);t:for(;++n=i){for(;i>r;){var a=r+i>>>1,s=t[a];(n?e>=s:e>s)&&null!==s?r=a+1:i=a}return i}return an(t,e,Ca,n)}function an(t,e,n,r){e=n(e);for(var i=0,a=t?t.length:0,s=e!==e,o=null===e,u=e===E;a>i;){var c=ms((i+a)/2),l=n(t[c]),h=l!==E,d=l===l;if(s)var f=d||r;else f=o?d&&h&&(r||null!=l):u?d&&(r||h):null==l?!1:r?e>=l:e>l;f?i=c+1:a=c}return xs(a,Ts)}function sn(t,e,n){if("function"!=typeof t)return Ca;if(e===E)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,r,i){return t.call(e,n,r,i)};case 4:return function(n,r,i,a){return t.call(e,n,r,i,a)};case 5:return function(n,r,i,a,s){return t.call(e,n,r,i,a,s)}}return function(){return t.apply(e,arguments)}}function on(t){var e=new as(t.byteLength),n=new fs(e);return n.set(new fs(t)),e}function un(t,e,n){for(var r=n.length,i=-1,a=As(t.length-r,0),s=-1,o=e.length,u=Ya(o+a);++s2?n[i-2]:E,s=i>2?n[2]:E,o=i>1?n[i-1]:E;for("function"==typeof a?(a=sn(a,o,5),i-=2):(a="function"==typeof o?o:E,i-=a?1:0),s&&Jn(n[0],n[1],s)&&(a=3>i?E:a,i=1);++r-1?n[s]:E}return Fe(n,r,t)}}function xn(t){return function(e,n,r){return e&&e.length?(n=$n(n,r,3),i(e,n,t)):-1}}function wn(t){return function(e,n,r){return n=$n(n,r,3),Fe(e,n,t,!0)}}function kn(t){return function(){for(var e,n=arguments.length,r=t?n:-1,i=0,a=Ya(n);t?r--:++r=Y)return e.plant(r).value();for(var i=0,s=n?a[i].apply(this,t):r;++iv){var k=o?te(o):E,D=As(c-v,0),T=p?w:E,S=p?E:w,B=p?A:E,M=p?E:A;e|=p?O:I,e&=~(p?I:O),g||(e&=~(C|F));var L=[t,e,n,B,T,M,S,k,u,D],P=On.apply(E,L);return er(t)&&Us(P,L),P.placeholder=x,P}}var N=d?n:this,R=f?N[t]:t;return o&&(A=ur(A,o)),h&&u=e||!_s(e))return"";var i=e-r;return n=null==n?" ":n+"",ya(n,gs(i/n.length)).slice(0,i)}function Mn(t,e,n,r){function i(){for(var e=-1,o=arguments.length,u=-1,c=r.length,l=Ya(c+o);++uu))return!1;for(;++o-1&&t%1==0&&e>t}function Jn(t,e,n){if(!Mi(n))return!1;var r=typeof e;if("number"==r?Kn(n)&&Qn(e,n.length):"string"==r&&e in n){var i=n[e];return t===t?t===i:i!==i}return!1}function tr(t,e){var n=typeof t;if("string"==n&&Et.test(t)||"number"==n)return!0;if(To(t))return!1;var r=!kt.test(t);return r||null!=e&&t in hr(e)}function er(t){var n=Un(t);if(!(n in K.prototype))return!1;var r=e[n];if(t===r)return!0;var i=Ys(r);return!!i&&t===i[0]}function nr(t){return"number"==typeof t&&t>-1&&t%1==0&&Bs>=t}function rr(t){return t===t&&!Mi(t)}function ir(t,e){var n=t[1],r=e[1],i=n|r,a=M>i,s=r==M&&n==S||r==M&&n==L&&t[7].length<=e[8]||r==(M|L)&&n==S;if(!a&&!s)return t;r&C&&(t[2]=e[2],i|=n&C?0:T);var o=e[3];if(o){var u=t[3];t[3]=u?un(u,o,e[4]):te(o),t[4]=u?_(t[3],G):te(e[4])}return o=e[5],o&&(u=t[5],t[5]=u?cn(u,o,e[6]):te(o),t[6]=u?_(t[5],G):te(e[6])),o=e[7],o&&(t[7]=te(o)),r&M&&(t[8]=null==t[8]?e[8]:xs(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i,t}function ar(t,e){return t===E?e:So(t,e,ar)}function sr(t,e){t=hr(t);for(var n=-1,r=e.length,i={};++nr;)s[++a]=qe(t,r,r+=e);return s}function gr(t){for(var e=-1,n=t?t.length:0,r=-1,i=[];++ee?0:e)):[]}function mr(t,e,n){var r=t?t.length:0;return r?((n?Jn(t,e,n):null==e)&&(e=1),e=r-(+e||0),qe(t,0,0>e?0:e)):[]}function vr(t,e,n){return t&&t.length?en(t,$n(e,n,3),!0,!0):[]}function _r(t,e,n){return t&&t.length?en(t,$n(e,n,3),!0):[]}function br(t,e,n,r){var i=t?t.length:0;return i?(n&&"number"!=typeof n&&Jn(t,e,n)&&(n=0,r=i),De(t,e,n,r)):[]}function Ar(t){return t?t[0]:E}function xr(t,e,n){var r=t?t.length:0;return n&&Jn(t,e,n)&&(e=!1),r?Te(t,e):[]}function wr(t){var e=t?t.length:0;return e?Te(t,!0):[]}function kr(t,e,n){var r=t?t.length:0;if(!r)return-1;if("number"==typeof n)n=0>n?As(r+n,0):n;else if(n){var i=rn(t,e);return r>i&&(e===e?e===t[i]:t[i]!==t[i])?i:-1}return a(t,e,n||0)}function Er(t){return mr(t,1)}function Dr(t){var e=t?t.length:0;return e?t[e-1]:E}function Cr(t,e,n){var r=t?t.length:0;if(!r)return-1;var i=r;if("number"==typeof n)i=(0>n?As(r+n,0):xs(n||0,r-1))+1;else if(n){i=rn(t,e,!0)-1;var a=t[i];return(e===e?e===a:a!==a)?i:-1}if(e!==e)return y(t,i,!0);for(;i--;)if(t[i]===e)return i;return-1}function Fr(){var t=arguments,e=t[0];if(!e||!e.length)return e;for(var n=0,r=Wn(),i=t.length;++n-1;)ds.call(e,a,1);return e}function Tr(t,e,n){var r=[];if(!t||!t.length)return r;var i=-1,a=[],s=t.length;for(e=$n(e,n,3);++ie?0:e)):[]}function Ir(t,e,n){var r=t?t.length:0;return r?((n?Jn(t,e,n):null==e)&&(e=1),e=r-(+e||0),qe(t,0>e?0:e)):[]}function Mr(t,e,n){return t&&t.length?en(t,$n(e,n,3),!1,!0):[]}function Lr(t,e,n){return t&&t.length?en(t,$n(e,n,3)):[]}function Pr(t,e,n,r){var i=t?t.length:0;if(!i)return[];null!=e&&"boolean"!=typeof e&&(r=n,n=Jn(t,e,r)?E:e,e=!1);var s=$n();return(null!=n||s!==be)&&(n=s(n,r,3)),e&&Wn()==a?b(t,n):Je(t,n)}function Nr(t){if(!t||!t.length)return[];var e=-1,n=0;t=oe(t,function(t){return Kn(t)?(n=As(t.length,n),!0):void 0});for(var r=Ya(n);++en?As(i+n,0):n||0,"string"==typeof t||!To(t)&&Ui(t)?i>=n&&t.indexOf(e,n)>-1:!!i&&Wn(t,e,n)>-1}function ti(t,e,n){var r=To(t)?ue:Re;return e=$n(e,n,3),r(t,e)}function ei(t,e){return ti(t,Ia(e))}function ni(t,e,n){var r=To(t)?oe:Ce;return e=$n(e,n,3),r(t,function(t,n,r){return!e(t,n,r)})}function ri(t,e,n){if(n?Jn(t,e,n):null==e){t=lr(t);var r=t.length;return r>0?t[He(0,r-1)]:E}var i=-1,a=zi(t),r=a.length,s=r-1;for(e=xs(0>e?0:+e||0,r);++i0&&(n=e.apply(this,arguments)),1>=t&&(e=E),n}}function fi(t,e,n){function r(){f&&ss(f),c&&ss(c),g=0,c=f=p=E}function i(e,n){n&&ss(n),c=f=p=E,e&&(g=go(),l=t.apply(d,u),f||c||(u=d=E))}function a(){var t=e-(go()-h);0>=t||t>e?i(p,c):f=hs(a,t)}function s(){i(m,f)}function o(){if(u=arguments,h=go(),d=this,p=m&&(f||!v),y===!1)var n=v&&!f;else{c||v||(g=h);var r=y-(h-g),i=0>=r||r>y;i?(c&&(c=ss(c)),g=h,l=t.apply(d,u)):c||(c=hs(s,r))}return i&&f?f=ss(f):f||e===y||(f=hs(a,e)),n&&(i=!0,l=t.apply(d,u)),!i||f||c||(u=d=E),l}var u,c,l,h,d,f,p,g=0,y=!1,m=!0;if("function"!=typeof t)throw new Xa(W);if(e=0>e?0:+e||0,n===!0){var v=!0;m=!1}else Mi(n)&&(v=!!n.leading,y="maxWait"in n&&As(+n.maxWait||0,e),m="trailing"in n?!!n.trailing:m);return o.cancel=r,o}function pi(t,e){if("function"!=typeof t||e&&"function"!=typeof e)throw new Xa(W);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 s=t.apply(this,r);return n.cache=a.set(i,s),s};return n.cache=new pi.Cache,n}function gi(t){if("function"!=typeof t)throw new Xa(W);return function(){return!t.apply(this,arguments)}}function yi(t){return di(2,t)}function mi(t,e){if("function"!=typeof t)throw new Xa(W);return e=As(e===E?t.length-1:+e||0,0),function(){for(var n=arguments,r=-1,i=As(n.length-e,0),a=Ya(i);++re}function ki(t,e){return t>=e}function Ei(t){return m(t)&&Kn(t)&&ts.call(t,"callee")&&!cs.call(t,"callee")}function Di(t){return t===!0||t===!1||m(t)&&ns.call(t)==z}function Ci(t){return m(t)&&ns.call(t)==q}function Fi(t){return!!t&&1===t.nodeType&&m(t)&&!Yi(t)}function Ti(t){return null==t?!0:Kn(t)&&(To(t)||Ui(t)||Ei(t)||m(t)&&Ii(t.splice))?!t.length:!Yo(t).length}function Si(t,e,n,r){n="function"==typeof n?sn(n,r,3):E;var i=n?n(t,e):E;return i===E?Le(t,e,n):!!i}function Bi(t){return m(t)&&"string"==typeof t.message&&ns.call(t)==X}function Oi(t){return"number"==typeof t&&_s(t)}function Ii(t){return Mi(t)&&ns.call(t)==Z}function Mi(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function Li(t,e,n,r){return n="function"==typeof n?sn(n,r,3):E,Ne(t,Gn(e),n)}function Pi(t){return ji(t)&&t!=+t}function Ni(t){return null==t?!1:Ii(t)?is.test(Ja.call(t)):m(t)&&Mt.test(t)}function Ri(t){return null===t}function ji(t){return"number"==typeof t||m(t)&&ns.call(t)==Q}function Yi(t){var e;if(!m(t)||ns.call(t)!=J||Ei(t)||!ts.call(t,"constructor")&&(e=t.constructor,"function"==typeof e&&!(e instanceof e)))return!1;var n;return Se(t,function(t,e){n=e}),n===E||ts.call(t,n)}function $i(t){return Mi(t)&&ns.call(t)==tt}function Ui(t){return"string"==typeof t||m(t)&&ns.call(t)==nt}function Wi(t){return m(t)&&nr(t.length)&&!!Ut[ns.call(t)]}function Gi(t){return t===E}function Vi(t,e){return e>t}function Hi(t,e){return e>=t}function zi(t){var e=t?$s(t):0;return nr(e)?e?te(t):[]:aa(t)}function qi(t){return _e(t,ta(t))}function Xi(t,e,n){var r=Ms(t);return n&&Jn(t,e,n)&&(e=E),e?me(r,e):r}function Zi(t){return Ie(t,ta(t))}function Ki(t,e,n){var r=null==t?E:Me(t,dr(e),e+"");return r===E?n:r}function Qi(t,e){if(null==t)return!1;var n=ts.call(t,e);if(!n&&!tr(e)){if(e=dr(e),t=1==e.length?t:Me(t,qe(e,0,-1)),null==t)return!1;e=Dr(e),n=ts.call(t,e)}return n||nr(t.length)&&Qn(e,t.length)&&(To(t)||Ei(t))}function Ji(t,e,n){n&&Jn(t,e,n)&&(e=E);for(var r=-1,i=Yo(t),a=i.length,s={};++r0;++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=-1&&!i;s--){var a=s>=0?arguments[s]:t.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(n=a+"/"+n,i="/"===a.charAt(0))}return n=e(r(n.split("/"),function(t){return!!t}),!i).join("/"),(i?"/":"")+n||"."},n.normalize=function(t){var i=n.isAbsolute(t),s="/"===a(t,-1);return t=e(r(t.split("/"),function(t){return!!t}),!i).join("/"),t||i||(t="."),t&&s&&(t+="/"),(i?"/":"")+t},n.isAbsolute=function(t){return"/"===t.charAt(0)},n.join=function(){var t=Array.prototype.slice.call(arguments,0);return n.normalize(r(t,function(t){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},n.relative=function(t,e){function r(t){for(var e=0;e=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=n.resolve(t).substr(1),e=n.resolve(e).substr(1);for(var i=r(t.split("/")),s=r(e.split("/")),a=Math.min(i.length,s.length),o=a,u=0;a>u;u++)if(i[u]!==s[u]){o=u;break}for(var c=[],u=o;ue&&(e=t.length+e),t.substr(e,n)}}).call(this,t("_process"))},{_process:3}],3:[function(t,e){function n(){}var r=e.exports={};r.nextTick=function(){var t="undefined"!=typeof window&&window.setImmediate,e="undefined"!=typeof window&&window.MutationObserver,n="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(t)return function(t){return window.setImmediate(t)};var r=[];if(e){var i=document.createElement("div"),s=new MutationObserver(function(){var t=r.slice();r.length=0,t.forEach(function(t){t()})});return s.observe(i,{attributes:!0}),function(t){r.length||i.setAttribute("yes","no"),r.push(t)}}return n?(window.addEventListener("message",function(t){var e=t.source;if((e===window||null===e)&&"process-tick"===t.data&&(t.stopPropagation(),r.length>0)){var n=r.shift();n()}},!0),function(t){r.push(t),window.postMessage("process-tick","*")}):function(t){setTimeout(t,0)}}(),r.title="browser",r.browser=!0,r.env={},r.argv=[],r.on=n,r.addListener=n,r.once=n,r.off=n,r.removeListener=n,r.removeAllListeners=n,r.emit=n,r.binding=function(){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(){throw new Error("process.chdir is not supported")}},{}],4:[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":11,"./lib/graphlib":12,"./lib/intersect":13,"./lib/render":28,"./lib/util":30,"./lib/version":31}],5:[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"),a=i.append("path").attr("d","M 0 0 L 10 5 L 0 10 z").style("stroke-width",1).style("stroke-dasharray","1,0");s.applyStyle(a,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"),a=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");s.applyStyle(a,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"),a=i.append("path").attr("d","M 0 5 L 10 5").style("stroke-width",1).style("stroke-dasharray","1,0");s.applyStyle(a,n[r+"Style"])}var s=t("./util");e.exports={"default":n,normal:n,vee:r,undirected:i}},{"./util":30}],6:[function(t,e){function n(t,e){var n=e.nodes().filter(function(t){return r.isSubgraph(e,t)}),s=t.selectAll("g.cluster").data(n,function(t){return t});return s.selectAll("*").remove(),s.enter().append("g").attr("class","cluster").attr("id",function(t){var n=e.node(t);return n.id}).style("opacity",0),r.applyTransition(s,e).style("opacity",1),s.each(function(t){var n=e.node(t),r=d3.select(this);d3.select(this).append("rect");var s=r.append("g").attr("class","label");i(s,n,n.clusterLabelPos)}),s.selectAll("rect").each(function(t){var n=e.node(t),i=d3.select(this);r.applyStyle(i,n.style)}),r.applyTransition(s.exit(),e).style("opacity",0).remove(),s}var r=t("./util"),i=t("./label/add-label");e.exports=n},{"./label/add-label":21,"./util":30}],7:[function(t,e){"use strict";function n(t,e){var n=t.selectAll("g.edgeLabel").data(e.edges(),function(t){return s.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),s=i(a.select(this),e.edge(t),0,0).classed("label",!0),o=s.node().getBBox();n.labelId&&s.attr("id",n.labelId),r.has(n,"width")||(n.width=o.width),r.has(n,"height")||(n.height=o.height)}),s.applyTransition(n.exit(),e).style("opacity",0).remove(),n}var r=t("./lodash"),i=t("./label/add-label"),s=t("./util"),a=t("./d3");e.exports=n},{"./d3":10,"./label/add-label":21,"./lodash":24,"./util":30}],8:[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 a(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,"arrowhead")}),i}function r(t,e){var n=t.edge(e),r=t.node(e.v),s=t.node(e.w),a=n.points.slice(1,n.points.length-1);return a.unshift(c(r,a[0])),a.push(c(s,a[a.length-1])),i(n,a)}function i(t,e){var n=h.svg.line().x(function(t){return t.x}).y(function(t){return t.y});return u.has(t,"lineInterpolate")&&n.interpolate(t.lineInterpolate),u.has(t,"lineTension")&&n.tension(Number(t.lineTension)),n(e)}function s(t){var e=t.getBBox(),n=t.getTransformToElement(t.ownerSVGElement).translate(e.width/2,e.height/2);return{x:n.e,y:n.f}}function a(t,e){var n=t.enter().append("g").attr("class","edgePath").style("opacity",0);n.append("path").attr("class","path").attr("d",function(t){var n=e.edge(t),r=e.node(t.v).elem,a=u.range(n.points.length).map(function(){return s(r)});return i(n,a)}),n.append("defs")}function o(t,e){var n=t.exit();l.applyTransition(n,e).style("opacity",0).remove(),l.applyTransition(n.select("path.path"),e).attr("d",function(t){var n=e.node(t.v);if(n){var r=u.range(this.pathSegList.length).map(function(){return n});return i({},r)}return h.select(this).attr("d")})}var u=t("./lodash"),c=t("./intersect/intersect-node"),l=t("./util"),h=t("./d3");e.exports=n},{"./d3":10,"./intersect/intersect-node":17,"./lodash":24,"./util":30}],9:[function(t,e){"use strict";function n(t,e,n){var o=e.nodes().filter(function(t){return!s.isSubgraph(e,t)}),u=t.selectAll("g.node").data(o,function(t){return t}).classed("update",!0);return u.selectAll("*").remove(),u.enter().append("g").attr("class","node").style("opacity",0),u.each(function(t){var o=e.node(t),u=a.select(this),c=u.append("g").attr("class","label"),l=i(c,o),h=n[o.shape],d=r.pick(l.node().getBBox(),"width","height");o.elem=this,o.id&&u.attr("id",o.id),o.labelId&&c.attr("id",o.labelId),s.applyClass(u,o["class"],(u.classed("update")?"update ":"")+"node"),r.has(o,"width")&&(d.width=o.width),r.has(o,"height")&&(d.height=o.height),d.width+=o.paddingLeft+o.paddingRight,d.height+=o.paddingTop+o.paddingBottom,c.attr("transform","translate("+(o.paddingLeft-o.paddingRight)/2+","+(o.paddingTop-o.paddingBottom)/2+")");var f=h(a.select(this),d,o);s.applyStyle(f,o.style);var p=f.node().getBBox();o.width=p.width,o.height=p.height}),s.applyTransition(u.exit(),e).style("opacity",0).remove(),u}var r=t("./lodash"),i=t("./label/add-label"),s=t("./util"),a=t("./d3");e.exports=n},{"./d3":10,"./label/add-label":21,"./lodash":24,"./util":30}],10:[function(t,e){e.exports=window.d3},{}],11:[function(t,e){var n;if(t)try{n=t("dagre")}catch(r){}n||(n=window.dagre),e.exports=n},{dagre:53}],12:[function(t,e){var n;if(t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:32}],13:[function(t,e){e.exports={node:t("./intersect-node"),circle:t("./intersect-circle"),ellipse:t("./intersect-ellipse"),polygon:t("./intersect-polygon"),rect:t("./intersect-rect")}},{"./intersect-circle":14,"./intersect-ellipse":15,"./intersect-node":17,"./intersect-polygon":18,"./intersect-rect":19}],14:[function(t,e){function n(t,e,n){return r(t,e,e,n)}var r=t("./intersect-ellipse");e.exports=n},{"./intersect-ellipse":15}],15:[function(t,e){function n(t,e,n,r){var i=t.x,s=t.y,a=i-r.x,o=s-r.y,u=Math.sqrt(e*e*o*o+n*n*a*a),c=Math.abs(e*n*a/u);r.xm?(m-y)/g:(m+y)/g,m=a*c-s*l,_=0>m?(m-y)/g:(m+y)/g,{x:v,y:_})}function r(t,e){return t*e>0}e.exports=n},{}],17:[function(t,e){function n(t,e){return t.intersect(e)}e.exports=n},{}],18:[function(t,e){function n(t,e,n){var i=t.x,s=t.y,a=[],o=Number.POSITIVE_INFINITY,u=Number.POSITIVE_INFINITY;e.forEach(function(t){o=Math.min(o,t.x),u=Math.min(u,t.y)});for(var c=i-t.width/2-o,l=s-t.height/2-u,h=0;h1&&a.sort(function(t,e){var r=t.x-n.x,i=t.y-n.y,s=Math.sqrt(r*r+i*i),a=e.x-n.x,o=e.y-n.y,u=Math.sqrt(a*a+o*o);return u>s?-1:s===u?0:1}),a[0]):(console.log("NO INTERSECTION FOUND, RETURN NODE CENTER",t),t)}var r=t("./intersect-line");e.exports=n},{"./intersect-line":16}],19:[function(t,e){function n(t,e){var n,r,i=t.x,s=t.y,a=e.x-i,o=e.y-s,u=t.width/2,c=t.height/2;return Math.abs(o)*u>Math.abs(a)*c?(0>o&&(c=-c),n=0===o?0:c*a/o,r=c):(0>a&&(u=-u),n=u,r=0===a?0:u*o/a),{x:i+n,y:s+r}}e.exports=n},{}],20:[function(t,e){function n(t,e){var n=t.append("foreignObject").attr("width","100000"),i=n.append("xhtml:div"),s=e.label;switch(typeof s){case"function":i.insert(s);break;case"object":i.insert(function(){return s});break;default:i.html(s)}r.applyStyle(i,e.labelStyle),i.style("display","inline-block"),i.style("white-space","nowrap");var a,o;return i.each(function(){a=this.clientWidth,o=this.clientHeight}),n.attr("width",a).attr("height",o),n}var r=t("../util");e.exports=n},{"../util":30}],21:[function(t,e){function n(t,e,n){var a=e.label,o=t.append("g");"svg"===e.labelType?s(o,e):"string"!=typeof a||"html"===e.labelType?i(o,e):r(o,e);var u,c=o.node().getBBox();switch(n){case"top":u=-e.height/2;break;case"bottom":u=e.height/2-c.height;break;default:u=-c.height/2}return o.attr("transform","translate("+-c.width/2+","+u+")"),o}var r=t("./add-text-label"),i=t("./add-html-label"),s=t("./add-svg-label");e.exports=n},{"./add-html-label":20,"./add-svg-label":22,"./add-text-label":23}],22:[function(t,e){function n(t,e){var n=t;return n.node().appendChild(e.label),r.applyStyle(n,e.labelStyle),n}var r=t("../util");e.exports=n},{"../util":30}],23:[function(t,e){function n(t,e){for(var n=t.append("text"),s=r(e.label).split("\n"),a=0;as)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+t+" Weight: "+s);c0&&(i=u.removeMin(),a=o[i],a.distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return o}var i=t("../lodash"),s=t("../data/priority-queue");e.exports=n;var a=i.constant(1)},{"../data/priority-queue":46,"../lodash":50}],37:[function(t,e){function n(t){return r.filter(i(t),function(e){return e.length>1||1===e.length&&t.hasEdge(e[0],e[0])})}var r=t("../lodash"),i=t("./tarjan");e.exports=n},{"../lodash":50,"./tarjan":44}],38:[function(t,e){function n(t,e,n){return r(t,e||s,n||function(e){return t.outEdges(e)})}function r(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,s=e(n);r[t][i]={distance:s,predecessor:t}})}),i.forEach(function(t){var e=r[t];i.forEach(function(n){var s=r[n];i.forEach(function(n){var r=s[t],i=e[n],a=s[n],o=r.distance+i.distance;oi&&(u[n]=a,c.decrease(n,i))}}var a,o=new i,u={},c=new s;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(a=c.removeMin(),r.has(u,a))o.setEdge(a,u[a]);else{if(l)throw new Error("Input graph is not connected: "+t);l=!0}t.nodeEdges(a).forEach(n)}return o}var r=t("../lodash"),i=t("../graph"),s=t("../data/priority-queue");e.exports=n},{"../data/priority-queue":46,"../graph":47,"../lodash":50}],44:[function(t,e){function n(t){function e(o){var u=s[o]={onStack:!0,lowlink:n,index:n++};if(i.push(o),t.successors(o).forEach(function(t){r.has(s,t)?s[t].onStack&&(u.lowlink=Math.min(u.lowlink,s[t].index)):(e(t),u.lowlink=Math.min(u.lowlink,s[t].lowlink))}),u.lowlink===u.index){var c,l=[];do c=i.pop(),s[c].onStack=!1,l.push(c);while(o!==c);a.push(l)}}var n=0,i=[],s={},a=[];return t.nodes().forEach(function(t){r.has(s,t)||e(t)}),a}var r=t("../lodash");e.exports=n},{"../lodash":50}],45:[function(t,e){function n(t){function e(o){if(i.has(s,o))throw new r;i.has(n,o)||(s[o]=!0,n[o]=!0,i.each(t.predecessors(o),e),delete s[o],a.push(o))}var n={},s={},a=[];if(i.each(t.sinks(),e),i.size(n)!==t.nodeCount())throw new r;return a}function r(){}var i=t("../lodash");e.exports=n,n.CycleException=r},{"../lodash":50}],46:[function(t,e){function n(){this._arr=[],this._keyIndices={}}var r=t("../lodash");e.exports=n,n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(t){return t.key})},n.prototype.has=function(t){return r.has(this._keyIndices,t)},n.prototype.priority=function(t){var e=this._keyIndices[t];return void 0!==e?this._arr[e].priority:void 0},n.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},n.prototype.add=function(t,e){var n=this._keyIndices;if(t=String(t),!r.has(n,t)){var i=this._arr,s=i.length;return n[t]=s,i.push({key:t,priority:e}),this._decrease(s),!0}return!1},n.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},n.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)},n.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,i=t;n>1,!(n[e].prioritys){var a=i;i=s,s=a}return i+h+s+h+(u.isUndefined(r)?c:r)}function a(t,e,n,r){var i=""+e,s=""+n;if(!t&&i>s){var a=i;i=s,s=a}var o={v:i,w:s};return r&&(o.name=r),o}function o(t,e){return s(t,e.v,e.w,e.name)}var u=t("./lodash");e.exports=n;var c="\x00",l="\x00",h="";n.prototype._nodeCount=0,n.prototype._edgeCount=0,n.prototype.isDirected=function(){return this._isDirected},n.prototype.isMultigraph=function(){return this._isMultigraph},n.prototype.isCompound=function(){return this._isCompound},n.prototype.setGraph=function(t){return this._label=t,this},n.prototype.graph=function(){return this._label},n.prototype.setDefaultNodeLabel=function(t){return u.isFunction(t)||(t=u.constant(t)),this._defaultNodeLabelFn=t,this},n.prototype.nodeCount=function(){return this._nodeCount},n.prototype.nodes=function(){return u.keys(this._nodes)},n.prototype.sources=function(){return u.filter(this.nodes(),function(t){return u.isEmpty(this._in[t])},this)},n.prototype.sinks=function(){return u.filter(this.nodes(),function(t){return u.isEmpty(this._out[t])},this)},n.prototype.setNodes=function(t,e){var n=arguments;return u.each(t,function(t){n.length>1?this.setNode(t,e):this.setNode(t)},this),this},n.prototype.setNode=function(t,e){return u.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]=l,this._children[t]={},this._children[l][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},n.prototype.node=function(t){return this._nodes[t]},n.prototype.hasNode=function(t){return u.has(this._nodes,t)},n.prototype.removeNode=function(t){var e=this;if(u.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],u.each(this.children(t),function(t){this.setParent(t)},this),delete this._children[t]),u.each(u.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],u.each(u.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},n.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(u.isUndefined(e))e=l;else{e+="";for(var n=e;!u.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},n.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},n.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!==l)return e}},n.prototype.children=function(t){if(u.isUndefined(t)&&(t=l),this._isCompound){var e=this._children[t];if(e)return u.keys(e)}else{if(t===l)return this.nodes();if(this.hasNode(t))return[]}},n.prototype.predecessors=function(t){var e=this._preds[t];return e?u.keys(e):void 0},n.prototype.successors=function(t){var e=this._sucs[t];return e?u.keys(e):void 0},n.prototype.neighbors=function(t){var e=this.predecessors(t);return e?u.union(e,this.successors(t)):void 0},n.prototype.filterNodes=function(t){function e(t){var s=r.parent(t);return void 0===s||n.hasNode(s)?(i[t]=s,s):s in i?i[s]:e(s)}var n=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});n.setGraph(this.graph()),u.each(this._nodes,function(e,r){t(r)&&n.setNode(r,e)},this),u.each(this._edgeObjs,function(t){n.hasNode(t.v)&&n.hasNode(t.w)&&n.setEdge(t,this.edge(t))},this);var r=this,i={};return this._isCompound&&u.each(n.nodes(),function(t){n.setParent(t,e(t))}),n},n.prototype.setDefaultEdgeLabel=function(t){return u.isFunction(t)||(t=u.constant(t)),this._defaultEdgeLabelFn=t,this},n.prototype.edgeCount=function(){return this._edgeCount},n.prototype.edges=function(){return u.values(this._edgeObjs)},n.prototype.setPath=function(t,e){var n=this,r=arguments;return u.reduce(t,function(t,i){return r.length>1?n.setEdge(t,i,e):n.setEdge(t,i),i}),this},n.prototype.setEdge=function(){var t,e,n,i,o=!1,c=arguments[0];"object"==typeof c&&null!==c&&"v"in c?(t=c.v,e=c.w,n=c.name,2===arguments.length&&(i=arguments[1],o=!0)):(t=c,e=arguments[1],n=arguments[3],arguments.length>2&&(i=arguments[2],o=!0)),t=""+t,e=""+e,u.isUndefined(n)||(n=""+n);var l=s(this._isDirected,t,e,n);if(u.has(this._edgeLabels,l))return o&&(this._edgeLabels[l]=i),this;if(!u.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[l]=o?i:this._defaultEdgeLabelFn(t,e,n);var h=a(this._isDirected,t,e,n);return t=h.v,e=h.w,Object.freeze(h),this._edgeObjs[l]=h,r(this._preds[e],t),r(this._sucs[t],e),this._in[e][l]=h,this._out[t][l]=h,this._edgeCount++,this},n.prototype.edge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):s(this._isDirected,t,e,n);return this._edgeLabels[r]},n.prototype.hasEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):s(this._isDirected,t,e,n);return u.has(this._edgeLabels,r)},n.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?o(this._isDirected,arguments[0]):s(this._isDirected,t,e,n),a=this._edgeObjs[r];return a&&(t=a.v,e=a.w,delete this._edgeLabels[r],delete this._edgeObjs[r],i(this._preds[e],t),i(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},n.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var r=u.values(n);return e?u.filter(r,function(t){return t.v===e}):r}},n.prototype.outEdges=function(t,e){var n=this._out[t];if(n){ +var r=u.values(n);return e?u.filter(r,function(t){return t.w===e}):r}},n.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);return n?n.concat(this.outEdges(t,e)):void 0}},{"./lodash":50}],48:[function(t,e){e.exports={Graph:t("./graph"),version:t("./version")}},{"./graph":47,"./version":51}],49:[function(t,e){function n(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:r(t),edges:i(t)};return a.isUndefined(t.graph())||(e.value=a.clone(t.graph())),e}function r(t){return a.map(t.nodes(),function(e){var n=t.node(e),r=t.parent(e),i={v:e};return a.isUndefined(n)||(i.value=n),a.isUndefined(r)||(i.parent=r),i})}function i(t){return a.map(t.edges(),function(e){var n=t.edge(e),r={v:e.v,w:e.w};return a.isUndefined(e.name)||(r.name=e.name),a.isUndefined(n)||(r.value=n),r})}function s(t){var e=new o(t.options).setGraph(t.value);return a.each(t.nodes,function(t){e.setNode(t.v,t.value),t.parent&&e.setParent(t.v,t.parent)}),a.each(t.edges,function(t){e.setEdge({v:t.v,w:t.w,name:t.name},t.value)}),e}var a=t("./lodash"),o=t("./graph");e.exports={write:n,read:s}},{"./graph":47,"./lodash":50}],50:[function(t,e){var n;if("function"==typeof t)try{n=t("lodash")}catch(r){}n||(n=window._),e.exports=n},{lodash:52}],51:[function(t,e){e.exports="1.0.7"},{}],52:[function(t,e,n){(function(t){(function(){function r(t,e){if(t!==e){var n=null===t,r=t===E,i=t===t,s=null===e,a=e===E,o=e===e;if(t>e&&!s||!i||n&&!a&&o||r&&o)return 1;if(e>t&&!n||!o||s&&!r&&i||a&&i)return-1}return 0}function i(t,e,n){for(var r=t.length,i=n?r:-1;n?i--:++i-1;);return n}function c(t,e){for(var n=t.length;n--&&e.indexOf(t.charAt(n))>-1;);return n}function l(t,e){return r(t.criteria,e.criteria)||t.index-e.index}function h(t,e,n){for(var i=-1,s=t.criteria,a=e.criteria,o=s.length,u=n.length;++i=u)return c;var l=n[i];return c*("asc"===l||l===!0?1:-1)}}return t.index-e.index}function d(t){return Wt[t]}function f(t){return Vt[t]}function p(t,e,n){return e?t=qt[t]:n&&(t=Xt[t]),"\\"+t}function g(t){return"\\"+Xt[t]}function y(t,e,n){for(var r=t.length,i=e+(n?0:-1);n?i--:++i=t&&t>=9&&13>=t||32==t||160==t||5760==t||6158==t||t>=8192&&(8202>=t||8232==t||8233==t||8239==t||8287==t||12288==t||65279==t)}function _(t,e){for(var n=-1,r=t.length,i=-1,s=[];++ne,i=n?t.length:0,s=Hn(0,i,this.__views__),a=s.start,o=s.end,u=o-a,c=r?o:a-1,l=this.__iteratees__,h=l.length,d=0,f=xa(u,this.__takeCount__);if(!n||Y>i||i==u&&f==u)return nn(r&&n?t.reverse():t,this.__actions__);var p=[];t:for(;u--&&f>d;){c+=e;for(var g=-1,y=t[c];++g=Y?gn(e):null,c=e.length;u&&(a=Kt,o=!1,e=u);t:for(;++in&&(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 Fe(t,e){var n=[];return Ma(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}function Ce(t,e,n,r){var i;return n(t,function(t,n,s){return e(t,n,s)?(i=r?n:t,!1):void 0}),i}function Te(t,e,n,r){r||(r=[]);for(var i=-1,s=t.length;++ir;)t=t[e[r++]];return r&&r==i?t:E}}function Me(t,e,n,r,i,s){return t===e?!0:null==t||null==e||!Li(t)&&!m(e)?t!==t&&e!==e:Ne(t,e,Me,n,r,i,s)}function Ne(t,e,n,r,i,s,a){var o=To(t),u=To(e),c=H,l=H;o||(c=na.call(t),c==V?c=J:c!=J&&(o=Gi(t))),u||(l=na.call(e),l==V?l=J:l!=J&&(u=Gi(e)));var h=c==J,d=l==J,f=c==l;if(f&&!o&&!h)return jn(t,e,c);if(!i){var p=h&&ta.call(t,"__wrapped__"),g=d&&ta.call(e,"__wrapped__");if(p||g)return n(p?t.value():t,g?e.value():e,r,i,s,a)}if(!f)return!1;s||(s=[]),a||(a=[]);for(var y=s.length;y--;)if(s[y]==t)return a[y]==e;s.push(t),a.push(e);var m=(o?Rn:Yn)(t,e,n,r,i,s,a);return s.pop(),a.pop(),m}function Pe(t,e,n){var r=e.length,i=r,s=!n;if(null==t)return!i;for(t=hr(t);r--;){var a=e[r];if(s&&a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++re&&(e=-e>i?0:i+e),n=n===E||n>i?i:+n||0,0>n&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var s=Ys(i);++r=Y,u=o?gn():null,c=[];u?(r=Kt,a=!1):(o=!1,u=e?[]:c);t:for(;++n=i){for(;i>r;){var s=r+i>>>1,a=t[s];(n?e>=a:e>a)&&null!==a?r=s+1:i=s}return i}return sn(t,e,Fs,n)}function sn(t,e,n,r){e=n(e);for(var i=0,s=t?t.length:0,a=e!==e,o=null===e,u=e===E;s>i;){var c=ma((i+s)/2),l=n(t[c]),h=l!==E,d=l===l;if(a)var f=d||r;else f=o?d&&h&&(r||null!=l):u?d&&(r||h):null==l?!1:r?e>=l:e>l;f?i=c+1:s=c}return xa(s,Ta)}function an(t,e,n){if("function"!=typeof t)return Fs;if(e===E)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,r,i){return t.call(e,n,r,i)};case 4:return function(n,r,i,s){return t.call(e,n,r,i,s)};case 5:return function(n,r,i,s,a){return t.call(e,n,r,i,s,a)}}return function(){return t.apply(e,arguments)}}function on(t){var e=new sa(t.byteLength),n=new fa(e);return n.set(new fa(t)),e}function un(t,e,n){for(var r=n.length,i=-1,s=Aa(t.length-r,0),a=-1,o=e.length,u=Ys(o+s);++a2?n[i-2]:E,a=i>2?n[2]:E,o=i>1?n[i-1]:E;for("function"==typeof s?(s=an(s,o,5),i-=2):(s="function"==typeof o?o:E,i-=s?1:0),a&&Jn(n[0],n[1],a)&&(s=3>i?E:s,i=1);++r-1?n[a]:E}return Ce(n,r,t)}}function xn(t){return function(e,n,r){return e&&e.length?(n=$n(n,r,3),i(e,n,t)):-1}}function wn(t){return function(e,n,r){return n=$n(n,r,3),Ce(e,n,t,!0)}}function kn(t){return function(){for(var e,n=arguments.length,r=t?n:-1,i=0,s=Ys(n);t?r--:++r=Y)return e.plant(r).value();for(var i=0,a=n?s[i].apply(this,t):r;++iv){var k=o?te(o):E,D=Aa(c-v,0),T=p?w:E,S=p?E:w,B=p?A:E,L=p?E:A;e|=p?O:I,e&=~(p?I:O),g||(e&=~(F|C));var M=[t,e,n,B,T,L,S,k,u,D],N=On.apply(E,M);return er(t)&&Ua(N,M),N.placeholder=x,N}}var P=d?n:this,R=f?P[t]:t;return o&&(A=ur(A,o)),h&&u=e||!_a(e))return"";var i=e-r;return n=null==n?" ":n+"",ys(n,ga(i/n.length)).slice(0,i)}function Ln(t,e,n,r){function i(){for(var e=-1,o=arguments.length,u=-1,c=r.length,l=Ys(c+o);++uu))return!1;for(;++o-1&&t%1==0&&e>t}function Jn(t,e,n){if(!Li(n))return!1;var r=typeof e;if("number"==r?Kn(n)&&Qn(e,n.length):"string"==r&&e in n){var i=n[e];return t===t?t===i:i!==i}return!1}function tr(t,e){var n=typeof t;if("string"==n&&Et.test(t)||"number"==n)return!0;if(To(t))return!1;var r=!kt.test(t);return r||null!=e&&t in hr(e)}function er(t){var n=Un(t);if(!(n in K.prototype))return!1;var r=e[n];if(t===r)return!0;var i=Ya(r);return!!i&&t===i[0]}function nr(t){return"number"==typeof t&&t>-1&&t%1==0&&Ba>=t}function rr(t){return t===t&&!Li(t)}function ir(t,e){var n=t[1],r=e[1],i=n|r,s=L>i,a=r==L&&n==S||r==L&&n==M&&t[7].length<=e[8]||r==(L|M)&&n==S;if(!s&&!a)return t;r&F&&(t[2]=e[2],i|=n&F?0:T);var o=e[3];if(o){var u=t[3];t[3]=u?un(u,o,e[4]):te(o),t[4]=u?_(t[3],W):te(e[4])}return o=e[5],o&&(u=t[5],t[5]=u?cn(u,o,e[6]):te(o),t[6]=u?_(t[5],W):te(e[6])),o=e[7],o&&(t[7]=te(o)),r&L&&(t[8]=null==t[8]?e[8]:xa(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i,t}function sr(t,e){return t===E?e:So(t,e,sr)}function ar(t,e){t=hr(t);for(var n=-1,r=e.length,i={};++nr;)a[++s]=qe(t,r,r+=e);return a}function gr(t){for(var e=-1,n=t?t.length:0,r=-1,i=[];++ee?0:e)):[]}function mr(t,e,n){var r=t?t.length:0;return r?((n?Jn(t,e,n):null==e)&&(e=1),e=r-(+e||0),qe(t,0,0>e?0:e)):[]}function vr(t,e,n){return t&&t.length?en(t,$n(e,n,3),!0,!0):[]}function _r(t,e,n){return t&&t.length?en(t,$n(e,n,3),!0):[]}function br(t,e,n,r){var i=t?t.length:0;return i?(n&&"number"!=typeof n&&Jn(t,e,n)&&(n=0,r=i),De(t,e,n,r)):[]}function Ar(t){return t?t[0]:E}function xr(t,e,n){var r=t?t.length:0;return n&&Jn(t,e,n)&&(e=!1),r?Te(t,e):[]}function wr(t){var e=t?t.length:0;return e?Te(t,!0):[]}function kr(t,e,n){var r=t?t.length:0;if(!r)return-1;if("number"==typeof n)n=0>n?Aa(r+n,0):n;else if(n){var i=rn(t,e);return r>i&&(e===e?e===t[i]:t[i]!==t[i])?i:-1}return s(t,e,n||0)}function Er(t){return mr(t,1)}function Dr(t){var e=t?t.length:0;return e?t[e-1]:E}function Fr(t,e,n){var r=t?t.length:0;if(!r)return-1;var i=r;if("number"==typeof n)i=(0>n?Aa(r+n,0):xa(n||0,r-1))+1;else if(n){i=rn(t,e,!0)-1;var s=t[i];return(e===e?e===s:s!==s)?i:-1}if(e!==e)return y(t,i,!0);for(;i--;)if(t[i]===e)return i;return-1}function Cr(){var t=arguments,e=t[0];if(!e||!e.length)return e;for(var n=0,r=Gn(),i=t.length;++n-1;)da.call(e,s,1);return e}function Tr(t,e,n){var r=[];if(!t||!t.length)return r;var i=-1,s=[],a=t.length;for(e=$n(e,n,3);++ie?0:e)):[]}function Ir(t,e,n){var r=t?t.length:0;return r?((n?Jn(t,e,n):null==e)&&(e=1),e=r-(+e||0),qe(t,0>e?0:e)):[]}function Lr(t,e,n){return t&&t.length?en(t,$n(e,n,3),!1,!0):[]}function Mr(t,e,n){return t&&t.length?en(t,$n(e,n,3)):[]}function Nr(t,e,n,r){var i=t?t.length:0;if(!i)return[];null!=e&&"boolean"!=typeof e&&(r=n,n=Jn(t,e,r)?E:e,e=!1);var a=$n();return(null!=n||a!==be)&&(n=a(n,r,3)),e&&Gn()==s?b(t,n):Je(t,n)}function Pr(t){if(!t||!t.length)return[];var e=-1,n=0;t=oe(t,function(t){return Kn(t)?(n=Aa(t.length,n),!0):void 0});for(var r=Ys(n);++en?Aa(i+n,0):n||0,"string"==typeof t||!To(t)&&Ui(t)?i>=n&&t.indexOf(e,n)>-1:!!i&&Gn(t,e,n)>-1}function ti(t,e,n){var r=To(t)?ue:Re;return e=$n(e,n,3),r(t,e)}function ei(t,e){return ti(t,Is(e))}function ni(t,e,n){var r=To(t)?oe:Fe;return e=$n(e,n,3),r(t,function(t,n,r){return!e(t,n,r)})}function ri(t,e,n){if(n?Jn(t,e,n):null==e){t=lr(t);var r=t.length;return r>0?t[He(0,r-1)]:E}var i=-1,s=zi(t),r=s.length,a=r-1;for(e=xa(0>e?0:+e||0,r);++i0&&(n=e.apply(this,arguments)),1>=t&&(e=E),n}}function fi(t,e,n){function r(){f&&aa(f),c&&aa(c),g=0,c=f=p=E}function i(e,n){n&&aa(n),c=f=p=E,e&&(g=go(),l=t.apply(d,u),f||c||(u=d=E))}function s(){var t=e-(go()-h);0>=t||t>e?i(p,c):f=ha(s,t)}function a(){i(m,f)}function o(){if(u=arguments,h=go(),d=this,p=m&&(f||!v),y===!1)var n=v&&!f;else{c||v||(g=h);var r=y-(h-g),i=0>=r||r>y;i?(c&&(c=aa(c)),g=h,l=t.apply(d,u)):c||(c=ha(a,r))}return i&&f?f=aa(f):f||e===y||(f=ha(s,e)),n&&(i=!0,l=t.apply(d,u)),!i||f||c||(u=d=E),l}var u,c,l,h,d,f,p,g=0,y=!1,m=!0;if("function"!=typeof t)throw new Xs(G);if(e=0>e?0:+e||0,n===!0){var v=!0;m=!1}else Li(n)&&(v=!!n.leading,y="maxWait"in n&&Aa(+n.maxWait||0,e),m="trailing"in n?!!n.trailing:m);return o.cancel=r,o}function pi(t,e){if("function"!=typeof t||e&&"function"!=typeof e)throw new Xs(G);var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],s=n.cache;if(s.has(i))return s.get(i);var a=t.apply(this,r);return n.cache=s.set(i,a),a};return n.cache=new pi.Cache,n}function gi(t){if("function"!=typeof t)throw new Xs(G);return function(){return!t.apply(this,arguments)}}function yi(t){return di(2,t)}function mi(t,e){if("function"!=typeof t)throw new Xs(G);return e=Aa(e===E?t.length-1:+e||0,0),function(){for(var n=arguments,r=-1,i=Aa(n.length-e,0),s=Ys(i);++re}function ki(t,e){return t>=e}function Ei(t){return m(t)&&Kn(t)&&ta.call(t,"callee")&&!ca.call(t,"callee")}function Di(t){return t===!0||t===!1||m(t)&&na.call(t)==z}function Fi(t){return m(t)&&na.call(t)==q}function Ci(t){return!!t&&1===t.nodeType&&m(t)&&!Yi(t)}function Ti(t){return null==t?!0:Kn(t)&&(To(t)||Ui(t)||Ei(t)||m(t)&&Ii(t.splice))?!t.length:!Yo(t).length}function Si(t,e,n,r){n="function"==typeof n?an(n,r,3):E;var i=n?n(t,e):E;return i===E?Me(t,e,n):!!i}function Bi(t){return m(t)&&"string"==typeof t.message&&na.call(t)==X}function Oi(t){return"number"==typeof t&&_a(t)}function Ii(t){return Li(t)&&na.call(t)==Z}function Li(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function Mi(t,e,n,r){return n="function"==typeof n?an(n,r,3):E,Pe(t,Wn(e),n)}function Ni(t){return ji(t)&&t!=+t}function Pi(t){return null==t?!1:Ii(t)?ia.test(Js.call(t)):m(t)&&Lt.test(t)}function Ri(t){return null===t}function ji(t){return"number"==typeof t||m(t)&&na.call(t)==Q}function Yi(t){var e;if(!m(t)||na.call(t)!=J||Ei(t)||!ta.call(t,"constructor")&&(e=t.constructor,"function"==typeof e&&!(e instanceof e)))return!1;var n;return Se(t,function(t,e){n=e}),n===E||ta.call(t,n)}function $i(t){return Li(t)&&na.call(t)==tt}function Ui(t){return"string"==typeof t||m(t)&&na.call(t)==nt}function Gi(t){return m(t)&&nr(t.length)&&!!Ut[na.call(t)]}function Wi(t){return t===E}function Vi(t,e){return e>t}function Hi(t,e){return e>=t}function zi(t){var e=t?$a(t):0;return nr(e)?e?te(t):[]:ss(t)}function qi(t){return _e(t,ts(t))}function Xi(t,e,n){var r=La(t);return n&&Jn(t,e,n)&&(e=E),e?me(r,e):r}function Zi(t){return Ie(t,ts(t))}function Ki(t,e,n){var r=null==t?E:Le(t,dr(e),e+"");return r===E?n:r}function Qi(t,e){if(null==t)return!1;var n=ta.call(t,e);if(!n&&!tr(e)){if(e=dr(e),t=1==e.length?t:Le(t,qe(e,0,-1)),null==t)return!1;e=Dr(e),n=ta.call(t,e)}return n||nr(t.length)&&Qn(e,t.length)&&(To(t)||Ei(t))}function Ji(t,e,n){n&&Jn(t,e,n)&&(e=E);for(var r=-1,i=Yo(t),s=i.length,a={};++r0;++r=xs(e,n)&&tn?0:+n||0,r),n-=e.length,n>=0&&t.indexOf(e,n)==n}function da(t){return t=o(t),t&&bt.test(t)?t.replace(vt,f):t}function fa(t){return t=o(t),t&&Ft.test(t)?t.replace(Ct,p):t||"(?:)"}function pa(t,e,n){t=o(t),e=+e;var r=t.length;if(r>=e||!_s(e))return t;var i=(e-r)/2,a=ms(i),s=gs(i);return n=In("",s,n),n.slice(0,a)+t+n}function ga(t,e,n){return(n?Jn(t,e,n):null==e)?e=0:e&&(e=+e),t=_a(t),ks(t,e||(It.test(t)?16:10))}function ya(t,e){var n="";if(t=o(t),e=+e,1>e||!t||!_s(e))return n;do e%2&&(n+=t),e=ms(e/2),t+=t;while(e);return n}function ma(t,e,n){return t=o(t),n=null==n?0:xs(0>n?0:+n||0,t.length),t.lastIndexOf(e,n)==n}function va(t,n,r){var i=e.templateSettings;r&&Jn(t,n,r)&&(n=r=E),t=o(t),n=ye(me({},r||n),i,ge);var a,s,u=ye(me({},n.imports),i.imports,ge),c=Yo(u),l=tn(u,c),h=0,d=n.interpolate||Nt,f="__p += '",p=za((n.escape||Nt).source+"|"+d.source+"|"+(d===wt?Bt:Nt).source+"|"+(n.evaluate||Nt).source+"|$","g"),y="//# sourceURL="+("sourceURL"in n?n.sourceURL:"lodash.templateSources["+ ++$t+"]")+"\n";t.replace(p,function(e,n,r,i,o,u){return r||(r=i),f+=t.slice(h,u).replace(Rt,g),n&&(a=!0,f+="' +\n__e("+n+") +\n'"),o&&(s=!0,f+="';\n"+o+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),h=u+e.length,e}),f+="';\n";var m=n.variable;m||(f="with (obj) {\n"+f+"\n}\n"),f=(s?f.replace(pt,""):f).replace(gt,"$1").replace(yt,"$1;"),f="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(a?", __e = _.escape":"")+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var v=Ko(function(){return Wa(c,y+"return "+f).apply(E,l)});if(v.source=f,Bi(v))throw v;return v}function _a(t,e,n){var r=t;return(t=o(t))?(n?Jn(r,e,n):null==e)?t.slice(A(t),x(t)+1):(e+="",t.slice(u(t,e),c(t,e)+1)):t}function ba(t,e,n){var r=t;return t=o(t),t?t.slice((n?Jn(r,e,n):null==e)?A(t):u(t,e+"")):t}function Aa(t,e,n){var r=t;return t=o(t),t?(n?Jn(r,e,n):null==e)?t.slice(0,x(t)+1):t.slice(0,c(t,e+"")+1):t}function xa(t,e,n){n&&Jn(t,e,n)&&(e=E);var r=P,i=N;if(null!=e)if(Mi(e)){var a="separator"in e?e.separator:a;r="length"in e?+e.length||0:r,i="omission"in e?o(e.omission):i}else r=+e||0;if(t=o(t),r>=t.length)return t;var s=r-i.length;if(1>s)return i;var u=t.slice(0,s);if(null==a)return u+i;if($i(a)){if(t.slice(s).search(a)){var c,l,h=t.slice(0,s);for(a.global||(a=za(a.source,(Ot.exec(a)||"")+"g")),a.lastIndex=0;c=a.exec(h);)l=c.index;u=u.slice(0,null==l?s:l)}}else if(t.indexOf(a,s)!=s){var d=u.lastIndexOf(a);d>-1&&(u=u.slice(0,d))}return u+i}function wa(t){return t=o(t),t&&_t.test(t)?t.replace(mt,w):t}function ka(t,e,n){return n&&Jn(t,e,n)&&(e=E),t=o(t),t.match(e||jt)||[]}function Ea(t,e,n){return n&&Jn(t,e,n)&&(e=E),m(t)?Fa(t):be(t,e)}function Da(t){return function(){return t}}function Ca(t){return t}function Fa(t){return je(Ae(t,!0))}function Ta(t,e){return Ye(t,Ae(e,!0))}function Sa(t,e,n){if(null==n){var r=Mi(e),i=r?Yo(e):E,a=i&&i.length?Ie(e,i):E;(a?a.length:r)||(a=!1,n=e,e=t,t=this)}a||(a=Ie(e,Yo(e)));var s=!0,o=-1,u=Ii(t),c=a.length;n===!1?s=!1:Mi(n)&&"chain"in n&&(s=n.chain);for(;++ot||!_s(t))return[];var r=-1,i=Ya(xs(t,Fs));for(e=sn(e,n,1);++rr?i[r]=e(r):e(r);return i}function Na(t){var e=++es;return o(t)+e}function Ra(t,e){return(+t||0)+(+e||0)}function ja(t,e,n){return n&&Jn(t,e,n)&&(e=E),e=$n(e,n,3),1==e.length?fe(To(t)?t:lr(t),e):Qe(t,e)}t=t?re.defaults(ne.Object(),t,re.pick(ne,Yt)):ne;{var Ya=t.Array,$a=t.Date,Ua=t.Error,Wa=t.Function,Ga=t.Math,Va=t.Number,Ha=t.Object,za=t.RegExp,qa=t.String,Xa=t.TypeError,Za=Ya.prototype,Ka=Ha.prototype,Qa=qa.prototype,Ja=Wa.prototype.toString,ts=Ka.hasOwnProperty,es=0,ns=Ka.toString,rs=ne._,is=za("^"+Ja.call(ts).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),as=t.ArrayBuffer,ss=t.clearTimeout,os=t.parseFloat,us=Ga.pow,cs=Ka.propertyIsEnumerable,ls=Vn(t,"Set"),hs=t.setTimeout,ds=Za.splice,fs=t.Uint8Array,ps=Vn(t,"WeakMap"),gs=Ga.ceil,ys=Vn(Ha,"create"),ms=Ga.floor,vs=Vn(Ya,"isArray"),_s=t.isFinite,bs=Vn(Ha,"keys"),As=Ga.max,xs=Ga.min,ws=Vn($a,"now"),ks=t.parseInt,Es=Ga.random,Ds=Va.NEGATIVE_INFINITY,Cs=Va.POSITIVE_INFINITY,Fs=4294967295,Ts=Fs-1,Ss=Fs>>>1,Bs=9007199254740991,Os=ps&&new ps,Is={};e.support={}}e.templateSettings={escape:At,evaluate:xt,interpolate:wt,variable:"",imports:{_:e}};var Ms=function(){function t(){}return function(e){if(Mi(e)){t.prototype=e;var n=new t;t.prototype=E}return n||{}}}(),Ls=dn(Be),Ps=dn(Oe,!0),Ns=fn(),Rs=fn(!0),js=Os?function(t,e){return Os.set(t,e),t}:Ca,Ys=Os?function(t){return Os.get(t)}:Oa,$s=We("length"),Us=function(){var t=0,e=0;return function(n,r){var i=go(),a=j-(i-e);if(e=i,a>0){if(++t>=R)return n}else t=0;return js(n,r)}}(),Ws=mi(function(t,e){return m(t)&&Kn(t)?we(t,Te(e,!1,!0)):[]}),Gs=xn(),Vs=xn(!0),Hs=mi(function(t){for(var e=t.length,n=e,r=Ya(h),i=Wn(),s=i==a,o=[];n--;){var u=t[n]=Kn(u=t[n])?u:[];r[n]=s&&u.length>=120?gn(n&&u):null}var c=t[0],l=-1,h=c?c.length:0,d=r[0];t:for(;++l2?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,Rr(t,n,r)}),to=mi(function(t){return t=Te(t),this.thru(function(e){return Jt(To(e)?e:[hr(e)],t)})}),eo=mi(function(t,e){return ve(t,Te(e))}),no=ln(function(t,e,n){ts.call(t,n)?++t[n]:t[n]=1}),ro=An(Ls),io=An(Ps,!0),ao=En(ee,Ls),so=En(ie,Ps),oo=ln(function(t,e,n){ts.call(t,n)?t[n].push(e):t[n]=[e]}),uo=ln(function(t,e,n){t[n]=e}),co=mi(function(t,e,n){var r=-1,i="function"==typeof e,a=tr(e),s=Kn(t)?Ya(t.length):[];return Ls(t,function(t){var o=i?e:a&&null!=t?t[e]:E;s[++r]=o?o.apply(t,n):Zn(t,e,n)}),s}),lo=ln(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),ho=Bn(le,Ls),fo=Bn(he,Ps),po=mi(function(t,e){if(null==t)return[];var n=e[2];return n&&Jn(e[0],e[1],n)&&(e.length=1),Ke(t,Te(e),[])}),go=ws||function(){return(new $a).getTime()},yo=mi(function(t,e,n){var r=C;if(n.length){var i=_(n,yo.placeholder);r|=O}return Nn(t,r,e,n,i)}),mo=mi(function(t,e){e=e.length?Te(e):Zi(t);for(var n=-1,r=e.length;++n0||0>e)?new K(n):(0>t?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==E&&(e=+e||0,n=0>e?n.dropRight(-e):n.take(e-t)),n)},K.prototype.takeRightWhile=function(t,e){return this.reverse().takeWhile(t,e).reverse()},K.prototype.toArray=function(){return this.take(Cs)},Be(K.prototype,function(t,n){var r=/^(?:filter|map|reject)|While$/.test(n),i=/^(?:first|last)$/.test(n),a=e[i?"take"+("last"==n?"Right":""):n];a&&(e.prototype[n]=function(){var e=i?[1]:arguments,n=this.__chain__,s=this.__wrapped__,o=!!this.__actions__.length,u=s instanceof K,c=e[0],l=u||To(s);l&&r&&"function"==typeof c&&1!=c.length&&(u=l=!1);var h=function(t){return i&&n?a(t,1)[0]:a.apply(E,ce([t],e))},d={func:Wr,args:[h],thisArg:E},f=u&&!o;if(i&&!n)return f?(s=s.clone(),s.__actions__.push(d),t.call(s)):a.call(E,this.value())[0];if(!i&&l){s=f?s:new K(this);var p=t.apply(s,e);return p.__actions__.push(d),new v(p,n)}return this.thru(h)})}),ee(["join","pop","push","replace","shift","sort","splice","split","unshift"],function(t){var n=(/^(?:replace|split)$/.test(t)?Qa:Za)[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",i=/^(?:join|pop|replace|shift)$/.test(t);e.prototype[t]=function(){var t=arguments;return i&&!this.__chain__?n.apply(this.value(),t):this[r](function(e){return n.apply(e,t)})}}),Be(K.prototype,function(t,n){var r=e[n];if(r){var i=r.name,a=Is[i]||(Is[i]=[]);a.push({name:n,func:r})}}),Is[On(E,F).name]=[{name:"wrapper",func:E}],K.prototype.clone=et,K.prototype.reverse=rt,K.prototype.value=Gt,e.prototype.chain=Gr,e.prototype.commit=Vr,e.prototype.concat=to,e.prototype.plant=Hr,e.prototype.reverse=zr,e.prototype.toString=qr,e.prototype.run=e.prototype.toJSON=e.prototype.valueOf=e.prototype.value=Xr,e.prototype.collect=e.prototype.map,e.prototype.head=e.prototype.first,e.prototype.select=e.prototype.filter,e.prototype.tail=e.prototype.rest,e}var E,D="3.10.1",C=1,F=2,T=4,S=8,B=16,O=32,I=64,M=128,L=256,P=30,N="...",R=150,j=16,Y=200,$=1,U=2,W="Expected a function",G="__lodash_placeholder__",V="[object Arguments]",H="[object Array]",z="[object Boolean]",q="[object Date]",X="[object Error]",Z="[object Function]",K="[object Map]",Q="[object Number]",J="[object Object]",tt="[object RegExp]",et="[object Set]",nt="[object String]",rt="[object WeakMap]",it="[object ArrayBuffer]",at="[object Float32Array]",st="[object Float64Array]",ot="[object Int8Array]",ut="[object Int16Array]",ct="[object Int32Array]",lt="[object Uint8Array]",ht="[object Uint8ClampedArray]",dt="[object Uint16Array]",ft="[object Uint32Array]",pt=/\b__p \+= '';/g,gt=/\b(__p \+=) '' \+/g,yt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,mt=/&(?:amp|lt|gt|quot|#39|#96);/g,vt=/[&<>"'`]/g,_t=RegExp(mt.source),bt=RegExp(vt.source),At=/<%-([\s\S]+?)%>/g,xt=/<%([\s\S]+?)%>/g,wt=/<%=([\s\S]+?)%>/g,kt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\n\\]|\\.)*?\1)\]/,Et=/^\w*$/,Dt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g,Ct=/^[:!,]|[\\^$.*+?()[\]{}|\/]|(^[0-9a-fA-Fnrtuvx])|([\n\r\u2028\u2029])/g,Ft=RegExp(Ct.source),Tt=/[\u0300-\u036f\ufe20-\ufe23]/g,St=/\\(\\)?/g,Bt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Ot=/\w*$/,It=/^0[xX]/,Mt=/^\[object .+?Constructor\]$/,Lt=/^\d+$/,Pt=/[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g,Nt=/($^)/,Rt=/['\n\r\u2028\u2029\\]/g,jt=function(){var t="[A-Z\\xc0-\\xd6\\xd8-\\xde]",e="[a-z\\xdf-\\xf6\\xf8-\\xff]+";return RegExp(t+"+(?="+t+e+")|"+t+"?"+e+"|"+t+"+|[0-9]+","g")}(),Yt=["Array","ArrayBuffer","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Math","Number","Object","RegExp","Set","String","_","clearTimeout","isFinite","parseFloat","parseInt","setTimeout","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap"],$t=-1,Ut={};Ut[at]=Ut[st]=Ut[ot]=Ut[ut]=Ut[ct]=Ut[lt]=Ut[ht]=Ut[dt]=Ut[ft]=!0,Ut[V]=Ut[H]=Ut[it]=Ut[z]=Ut[q]=Ut[X]=Ut[Z]=Ut[K]=Ut[Q]=Ut[J]=Ut[tt]=Ut[et]=Ut[nt]=Ut[rt]=!1;var Wt={};Wt[V]=Wt[H]=Wt[it]=Wt[z]=Wt[q]=Wt[at]=Wt[st]=Wt[ot]=Wt[ut]=Wt[ct]=Wt[Q]=Wt[J]=Wt[tt]=Wt[nt]=Wt[lt]=Wt[ht]=Wt[dt]=Wt[ft]=!0,Wt[X]=Wt[Z]=Wt[K]=Wt[et]=Wt[rt]=!1;var Gt={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss"},Vt={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},Ht={"&":"&","<":"<",">":">",""":'"',"'":"'","`":"`"},zt={"function":!0,object:!0},qt={0:"x30",1:"x31",2:"x32",3:"x33",4:"x34",5:"x35",6:"x36",7:"x37",8:"x38",9:"x39",A:"x41",B:"x42",C:"x43",D:"x44",E:"x45",F:"x46",a:"x61",b:"x62",c:"x63",d:"x64",e:"x65",f:"x66",n:"x6e",r:"x72",t:"x74",u:"x75",v:"x76",x:"x78"},Xt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Zt=zt[typeof n]&&n&&!n.nodeType&&n,Kt=zt[typeof e]&&e&&!e.nodeType&&e,Qt=Zt&&Kt&&"object"==typeof t&&t&&t.Object&&t,Jt=zt[typeof self]&&self&&self.Object&&self,te=zt[typeof window]&&window&&window.Object&&window,ee=Kt&&Kt.exports===Zt&&Zt,ne=Qt||te!==(this&&this.window)&&te||Jt||this,re=k();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(ne._=re,define(function(){return re})):Zt&&Kt?ee?(Kt.exports=re)._=re:Zt._=re:ne._=re}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],53:[function(t,e){e.exports={graphlib:t("./lib/graphlib"),layout:t("./lib/layout"),debug:t("./lib/debug"),util:{time:t("./lib/util").time,notime:t("./lib/util").notime},version:t("./lib/version")}},{"./lib/debug":58,"./lib/graphlib":59,"./lib/layout":61,"./lib/util":81,"./lib/version":82}],54:[function(t,e){"use strict";function n(t){function e(t){return function(e){return t.edge(e).weight}}var n="greedy"===t.graph().acyclicer?s(t,e(t)):r(t);a.each(n,function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,a.uniqueId("rev"))})}function r(t){function e(s){a.has(i,s)||(i[s]=!0,r[s]=!0,a.each(t.outEdges(s),function(t){a.has(r,t.w)?n.push(t):e(t.w)}),delete r[s])}var n=[],r={},i={};return a.each(t.nodes(),e),n}function i(t){a.each(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)}})}var a=t("./lodash"),s=t("./greedy-fas");e.exports={run:n,undo:i}},{"./greedy-fas":60,"./lodash":62}],55:[function(t,e){function n(t){function e(n){var a=t.children(n),s=t.node(n);if(a.length&&i.each(a,e),i.has(s,"minRank")){s.borderLeft=[],s.borderRight=[];for(var o=s.minRank,u=s.maxRank+1;u>o;++o)r(t,"borderLeft","_bl",n,s,o),r(t,"borderRight","_br",n,s,o)}}i.each(t.children(),e)}function r(t,e,n,r,i,s){var o={width:0,height:0,rank:s,borderType:e},u=i[e][s-1],c=a.addDummyNode(t,"border",o,n);i[e][s]=c,t.setParent(c,r),u&&t.setEdge(u,c,{weight:1})}var i=t("./lodash"),a=t("./util");e.exports=n},{"./lodash":62,"./util":81}],56:[function(t,e){"use strict";function n(t){var e=t.graph().rankdir.toLowerCase();("lr"===e||"rl"===e)&&i(t)}function r(t){var e=t.graph().rankdir.toLowerCase();("bt"===e||"rl"===e)&&s(t),("lr"===e||"rl"===e)&&(u(t),i(t))}function i(t){l.each(t.nodes(),function(e){a(t.node(e))}),l.each(t.edges(),function(e){a(t.edge(e))})}function a(t){var e=t.width;t.width=t.height,t.height=e}function s(t){l.each(t.nodes(),function(e){o(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,o),l.has(n,"y")&&o(n)})}function o(t){t.y=-t.y}function u(t){l.each(t.nodes(),function(e){c(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,c),l.has(n,"x")&&c(n)})}function c(t){var e=t.x;t.x=t.y,t.y=e}var l=t("./lodash");e.exports={adjust:n,undo:r}},{"./lodash":62}],57:[function(t,e){function n(){var t={};t._next=t._prev=t,this._sentinel=t}function r(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function i(t,e){return"_next"!==t&&"_prev"!==t?e:void 0}e.exports=n,n.prototype.dequeue=function(){var t=this._sentinel,e=t._prev;return e!==t?(r(e),e):void 0},n.prototype.enqueue=function(t){var e=this._sentinel;t._prev&&t._next&&r(t),t._next=e._next,e._next._prev=t,e._next=t,t._prev=e},n.prototype.toString=function(){for(var t=[],e=this._sentinel,n=e._prev;n!==e;)t.push(JSON.stringify(n,i)),n=n._prev;return"["+t.join(", ")+"]"}},{}],58:[function(t,e){function n(t){var e=i.buildLayerMatrix(t),n=new a({compound:!0,multigraph:!0}).setGraph({});return r.each(t.nodes(),function(e){n.setNode(e,{label:e}),n.setParent(e,"layer"+t.node(e).rank)}),r.each(t.edges(),function(t){n.setEdge(t.v,t.w,{},t.name)}),r.each(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}var r=t("./lodash"),i=t("./util"),a=t("./graphlib").Graph;e.exports={debugOrdering:n}},{"./graphlib":59,"./lodash":62,"./util":81}],59:[function(t,e){var n;if("function"==typeof t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:83}],60:[function(t,e){function n(t,e){if(t.nodeCount()<=1)return[];var n=a(t,e||l),i=r(n.graph,n.buckets,n.zeroIdx);return o.flatten(o.map(i,function(e){return t.outEdges(e.v,e.w)}),!0)}function r(t,e,n){for(var r,a=[],s=e[e.length-1],o=e[0];t.nodeCount();){for(;r=o.dequeue();)i(t,e,n,r);for(;r=s.dequeue();)i(t,e,n,r);if(t.nodeCount())for(var u=e.length-2;u>0;--u)if(r=e[u].dequeue()){a=a.concat(i(t,e,n,r,!0));break}}return a}function i(t,e,n,r,i){var a=i?[]:void 0;return o.each(t.inEdges(r.v),function(r){var o=t.edge(r),u=t.node(r.v);i&&a.push({v:r.v,w:r.w}),u.out-=o,s(e,n,u)}),o.each(t.outEdges(r.v),function(r){var i=t.edge(r),a=r.w,o=t.node(a);o["in"]-=i,s(e,n,o)}),t.removeNode(r.v),a}function a(t,e){var n=new u,r=0,i=0;o.each(t.nodes(),function(t){n.setNode(t,{v:t,"in":0,out:0})}),o.each(t.edges(),function(t){var a=n.edge(t.v,t.w)||0,s=e(t),o=a+s;n.setEdge(t.v,t.w,o),i=Math.max(i,n.node(t.v).out+=s),r=Math.max(r,n.node(t.w)["in"]+=s)});var a=o.range(i+r+3).map(function(){return new c}),l=r+1;return o.each(n.nodes(),function(t){s(a,l,n.node(t))}),{graph:n,buckets:a,zeroIdx:l}}function s(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)}var o=t("./lodash"),u=t("./graphlib").Graph,c=t("./data/list");e.exports=n;var l=o.constant(1)},{"./data/list":57,"./graphlib":59,"./lodash":62}],61:[function(t,e){"use strict";function n(t,e){var n=e&&e.debugTiming?O.time:O.notime;n("layout",function(){var e=n(" buildLayoutGraph",function(){return a(t)});n(" runLayout",function(){r(e,n)}),n(" updateInputGraph",function(){i(t,e)})})}function r(t,e){e(" makeSpaceForEdgeLabels",function(){s(t)}),e(" removeSelfEdges",function(){g(t)}),e(" acyclic",function(){A.run(t)}),e(" nestingGraph.run",function(){C.run(t)}),e(" rank",function(){w(O.asNonCompoundGraph(t))}),e(" injectEdgeLabelProxies",function(){o(t)}),e(" removeEmptyRanks",function(){D(t)}),e(" nestingGraph.cleanup",function(){C.cleanup(t)}),e(" normalizeRanks",function(){k(t)}),e(" assignRankMinMax",function(){u(t)}),e(" removeEdgeLabelProxies",function(){c(t)}),e(" normalize.run",function(){x.run(t)}),e(" parentDummyChains",function(){E(t)}),e(" addBorderSegments",function(){F(t)}),e(" order",function(){S(t)}),e(" insertSelfEdges",function(){y(t)}),e(" adjustCoordinateSystem",function(){T.adjust(t)}),e(" position",function(){B(t)}),e(" positionSelfEdges",function(){m(t)}),e(" removeBorderNodes",function(){p(t)}),e(" normalize.undo",function(){x.undo(t)}),e(" fixupEdgeLabelCoords",function(){d(t)}),e(" undoCoordinateSystem",function(){T.undo(t)}),e(" translateGraph",function(){l(t)}),e(" assignNodeIntersects",function(){h(t)}),e(" reversePoints",function(){f(t)}),e(" acyclic.undo",function(){A.undo(t)})}function i(t,e){b.each(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))}),b.each(t.edges(),function(n){var r=t.edge(n),i=e.edge(n);r.points=i.points,b.has(i,"x")&&(r.x=i.x,r.y=i.y)}),t.graph().width=e.graph().width,t.graph().height=e.graph().height}function a(t){var e=new I({multigraph:!0,compound:!0}),n=_(t.graph());return e.setGraph(b.merge({},L,v(n,M),b.pick(n,P))),b.each(t.nodes(),function(n){var r=_(t.node(n));e.setNode(n,b.defaults(v(r,N),R)),e.setParent(n,t.parent(n))}),b.each(t.edges(),function(n){var r=_(t.edge(n));e.setEdge(n,b.merge({},Y,v(r,j),b.pick(r,$)))}),e}function s(t){var e=t.graph();e.ranksep/=2,b.each(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)})}function o(t){b.each(t.edges(),function(e){var n=t.edge(e);if(n.width&&n.height){var r=t.node(e.v),i=t.node(e.w),a={rank:(i.rank-r.rank)/2+r.rank,e:e};O.addDummyNode(t,"edge-proxy",a,"_ep")}})}function u(t){var e=0;b.each(t.nodes(),function(n){var r=t.node(n);r.borderTop&&(r.minRank=t.node(r.borderTop).rank,r.maxRank=t.node(r.borderBottom).rank,e=b.max(e,r.maxRank))}),t.graph().maxRank=e}function c(t){b.each(t.nodes(),function(e){var n=t.node(e);"edge-proxy"===n.dummy&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))})}function l(t){function e(t){var e=t.x,s=t.y,o=t.width,u=t.height;n=Math.min(n,e-o/2),r=Math.max(r,e+o/2),i=Math.min(i,s-u/2),a=Math.max(a,s+u/2)}var n=Number.POSITIVE_INFINITY,r=0,i=Number.POSITIVE_INFINITY,a=0,s=t.graph(),o=s.marginx||0,u=s.marginy||0;b.each(t.nodes(),function(n){e(t.node(n))}),b.each(t.edges(),function(n){var r=t.edge(n);b.has(r,"x")&&e(r)}),n-=o,i-=u,b.each(t.nodes(),function(e){var r=t.node(e);r.x-=n,r.y-=i}),b.each(t.edges(),function(e){var r=t.edge(e);b.each(r.points,function(t){t.x-=n,t.y-=i}),b.has(r,"x")&&(r.x-=n),b.has(r,"y")&&(r.y-=i)}),s.width=r-n+o,s.height=a-i+u}function h(t){b.each(t.edges(),function(e){var n,r,i=t.edge(e),a=t.node(e.v),s=t.node(e.w);i.points?(n=i.points[0],r=i.points[i.points.length-1]):(i.points=[],n=s,r=a),i.points.unshift(O.intersectRect(a,n)),i.points.push(O.intersectRect(s,r))})}function d(t){b.each(t.edges(),function(e){var n=t.edge(e);if(b.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}})}function f(t){b.each(t.edges(),function(e){var n=t.edge(e);n.reversed&&n.points.reverse()})}function p(t){b.each(t.nodes(),function(e){if(t.children(e).length){var n=t.node(e),r=t.node(n.borderTop),i=t.node(n.borderBottom),a=t.node(b.last(n.borderLeft)),s=t.node(b.last(n.borderRight));n.width=Math.abs(s.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}}),b.each(t.nodes(),function(e){"border"===t.node(e).dummy&&t.removeNode(e)})}function g(t){b.each(t.edges(),function(e){if(e.v===e.w){var n=t.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e:e,label:t.edge(e)}),t.removeEdge(e)}})}function y(t){var e=O.buildLayerMatrix(t);b.each(e,function(e){var n=0;b.each(e,function(e,r){var i=t.node(e);i.order=r+n,b.each(i.selfEdges,function(e){O.addDummyNode(t,"selfedge",{width:e.label.width,height:e.label.height,rank:i.rank,order:r+ ++n,e:e.e,label:e.label},"_se")}),delete i.selfEdges})})}function m(t){b.each(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,s=n.x-i,o=r.height/2;t.setEdge(n.e,n.label),t.removeNode(e),n.label.points=[{x:i+2*s/3,y:a-o},{x:i+5*s/6,y:a-o},{x:i+s,y:a},{x:i+5*s/6,y:a+o},{x:i+2*s/3,y:a+o}],n.label.x=n.x,n.label.y=n.y}})}function v(t,e){return b.mapValues(b.pick(t,e),Number)}function _(t){var e={};return b.each(t,function(t,n){e[n.toLowerCase()]=t}),e}var b=t("./lodash"),A=t("./acyclic"),x=t("./normalize"),w=t("./rank"),k=t("./util").normalizeRanks,E=t("./parent-dummy-chains"),D=t("./util").removeEmptyRanks,C=t("./nesting-graph"),F=t("./add-border-segments"),T=t("./coordinate-system"),S=t("./order"),B=t("./position"),O=t("./util"),I=t("./graphlib").Graph;e.exports=n;var M=["nodesep","edgesep","ranksep","marginx","marginy"],L={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},P=["acyclicer","ranker","rankdir","align"],N=["width","height"],R={width:0,height:0},j=["minlen","weight","width","height","labeloffset"],Y={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},$=["labelpos"]},{"./acyclic":54,"./add-border-segments":55,"./coordinate-system":56,"./graphlib":59,"./lodash":62,"./nesting-graph":63,"./normalize":64,"./order":69,"./parent-dummy-chains":74,"./position":76,"./rank":78,"./util":81}],62:[function(t,e){e.exports=t(50)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":50,lodash:103}],63:[function(t,e){function n(t){var e=u.addDummyNode(t,"root",{},"_root"),n=i(t),s=o.max(n)-1,c=2*s+1;t.graph().nestingRoot=e,o.each(t.edges(),function(e){t.edge(e).minlen*=c});var l=a(t)+1;o.each(t.children(),function(i){r(t,e,c,l,s,n,i)}),t.graph().nodeRankFactor=c}function r(t,e,n,i,a,s,c){var l=t.children(c);if(!l.length)return void(c!==e&&t.setEdge(e,c,{ -weight:0,minlen:n}));var h=u.addBorderNode(t,"_bt"),d=u.addBorderNode(t,"_bb"),f=t.node(c);t.setParent(h,c),f.borderTop=h,t.setParent(d,c),f.borderBottom=d,o.each(l,function(o){r(t,e,n,i,a,s,o);var u=t.node(o),l=u.borderTop?u.borderTop:o,f=u.borderBottom?u.borderBottom:o,p=u.borderTop?i:2*i,g=l!==f?1:a-s[c]+1;t.setEdge(h,l,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(f,d,{weight:p,minlen:g,nestingEdge:!0})}),t.parent(c)||t.setEdge(e,h,{weight:0,minlen:a+s[c]})}function i(t){function e(r,i){var a=t.children(r);a&&a.length&&o.each(a,function(t){e(t,i+1)}),n[r]=i}var n={};return o.each(t.children(),function(t){e(t,1)}),n}function a(t){return o.reduce(t.edges(),function(e,n){return e+t.edge(n).weight},0)}function s(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,o.each(t.edges(),function(e){var n=t.edge(e);n.nestingEdge&&t.removeEdge(e)})}var o=t("./lodash"),u=t("./util");e.exports={run:n,cleanup:s}},{"./lodash":62,"./util":81}],64:[function(t,e){"use strict";function n(t){t.graph().dummyChains=[],a.each(t.edges(),function(e){r(t,e)})}function r(t,e){var n=e.v,r=t.node(n).rank,i=e.w,a=t.node(i).rank,o=e.name,u=t.edge(e),c=u.labelRank;if(a!==r+1){t.removeEdge(e);var l,h,d;for(d=0,++r;a>r;++d,++r)u.points=[],h={width:0,height:0,edgeLabel:u,edgeObj:e,rank:r},l=s.addDummyNode(t,"edge",h,"_d"),r===c&&(h.width=u.width,h.height=u.height,h.dummy="edge-label",h.labelpos=u.labelpos),t.setEdge(n,l,{weight:u.weight},o),0===d&&t.graph().dummyChains.push(l),n=l;t.setEdge(n,i,{weight:u.weight},o)}}function i(t){a.each(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)})}var a=t("./lodash"),s=t("./util");e.exports={run:n,undo:i}},{"./lodash":62,"./util":81}],65:[function(t,e){function n(t,e,n){var i,a={};r.each(n,function(n){for(var r,s,o=t.parent(n);o;){if(r=t.parent(o),r?(s=a[r],a[r]=o):(s=i,i=o),s&&s!==o)return void e.setEdge(s,o);o=r}})}var r=t("../lodash");e.exports=n},{"../lodash":62}],66:[function(t,e){function n(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}})}var r=t("../lodash");e.exports=n},{"../lodash":62}],67:[function(t,e){function n(t,e,n){var s=r(t),o=new a({compound:!0}).setGraph({root:s}).setDefaultNodeLabel(function(e){return t.node(e)});return i.each(t.nodes(),function(r){var a=t.node(r),u=t.parent(r);(a.rank===e||a.minRank<=e&&e<=a.maxRank)&&(o.setNode(r),o.setParent(r,u||s),i.each(t[n](r),function(e){var n=e.v===r?e.w:e.v,a=o.edge(n,r),s=i.isUndefined(a)?0:a.weight;o.setEdge(n,r,{weight:t.edge(e).weight+s})}),i.has(a,"minRank")&&o.setNode(r,{borderLeft:a.borderLeft[e],borderRight:a.borderRight[e]}))}),o}function r(t){for(var e;t.hasNode(e=i.uniqueId("_root")););return e}var i=t("../lodash"),a=t("../graphlib").Graph;e.exports=n},{"../graphlib":59,"../lodash":62}],68:[function(t,e){"use strict";function n(t,e){for(var n=0,i=1;i0;)e%2&&(n+=u[e+1]),e=e-1>>1,u[e]+=t.weight;c+=t.weight*n})),c}var i=t("../lodash");e.exports=n},{"../lodash":62}],69:[function(t,e){"use strict";function n(t){var e=f.maxRank(t),n=r(t,s.range(1,e+1),"inEdges"),c=r(t,s.range(e-1,-1,-1),"outEdges"),l=o(t);a(t,l);for(var h,d=Number.POSITIVE_INFINITY,p=0,g=0;4>g;++p,++g){i(p%2?n:c,p%4>=2),l=f.buildLayerMatrix(t);var y=u(t,l);d>y&&(g=0,h=s.cloneDeep(l),d=y)}a(t,h)}function r(t,e,n){return s.map(e,function(e){return l(t,e,n)})}function i(t,e){var n=new d;s.each(t,function(t){var r=t.graph().root,i=c(t,r,n,e);s.each(i.vs,function(e,n){t.node(e).order=n}),h(t,n,i.vs)})}function a(t,e){s.each(e,function(e){s.each(e,function(e,n){t.node(e).order=n})})}var s=t("../lodash"),o=t("./init-order"),u=t("./cross-count"),c=t("./sort-subgraph"),l=t("./build-layer-graph"),h=t("./add-subgraph-constraints"),d=t("../graphlib").Graph,f=t("../util");e.exports=n},{"../graphlib":59,"../lodash":62,"../util":81,"./add-subgraph-constraints":65,"./build-layer-graph":67,"./cross-count":68,"./init-order":70,"./sort-subgraph":72}],70:[function(t,e){"use strict";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":62}],71:[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":62}],72:[function(t,e){function n(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 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(f&&(v.vs=a.flatten([f,v.vs,p],!0),t.predecessors(f).length)){var _=t.node(t.predecessors(f)[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":62,"./barycenter":66,"./resolve-conflicts":71,"./sort":73}],73:[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,d=0;o.sort(i(!!e)),d=r(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=r(c,u,d)});var f={vs:a.flatten(c,!0)};return h&&(f.barycenter=l/h,f.weight=h),f}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.barycentern.barycenter?1:t?n.i-e.i:e.i-n.i}}var a=t("../lodash"),s=t("../util");e.exports=n},{"../lodash":62,"../util":81}],74:[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).maxRanku||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":62}],75:[function(t,e){"use strict";function n(t,e){function n(e,n){var s=0,o=0,u=e.length,c=y.last(n);return y.each(n,function(e,l){var h=i(t,e),d=h?t.node(h).order:u;(h||e===c)&&(y.each(n.slice(o,l+1),function(e){y.each(t.predecessors(e),function(n){var i=t.node(n),o=i.order;!(s>o||o>d)||i.dummy&&t.node(e).dummy||a(r,n,e)})}),o=l+1,s=d)}),n}var r={};return y.reduce(e,n),r}function r(t,e){function n(e,n,r,s,o){var u;y.each(y.range(n,r),function(n){u=e[n],t.node(u).dummy&&y.each(t.predecessors(u),function(e){var n=t.node(e);n.dummy&&(n.ordero)&&a(i,e,u)})})}function r(e,r){var i,a=-1,s=0;return y.each(r,function(o,u){if("border"===t.node(o).dummy){var c=t.predecessors(o);c.length&&(i=t.node(c[0]).order,n(r,s,u,a,i),s=u,a=i)}n(r,s,r.length,i,e.length)}),r}var i={};return y.reduce(e,r),i}function i(t,e){return t.node(e).dummy?y.find(t.predecessors(e),function(e){return t.node(e).dummy}):void 0}function a(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 s(t,e,n){if(e>n){var r=e;e=n,n=r}return y.has(t[e],n)}function o(t,e,n,r){var i={},a={},o={};return y.each(e,function(t){y.each(t,function(t,e){i[t]=t,a[t]=t,o[t]=e})}),y.each(e,function(t){var e=-1;y.each(t,function(t){var u=r(t);if(u.length){u=y.sortBy(u,function(t){return o[t]});for(var c=(u.length-1)/2,l=Math.floor(c),h=Math.ceil(c);h>=l;++l){var d=u[l];a[t]===t&&es.lim&&(o=s,u=!0);var c=p.filter(e.edges(),function(e){return u===f(t,t.node(e.v),o)&&u!==f(t,t.node(e.w),o)});return p.min(c,function(t){return y(e,t)})}function l(t,e,n,i){var a=n.v,o=n.w;t.removeEdge(a,o),t.setEdge(i.v,i.w,{}),s(t),r(t,e),h(t,e)}function h(t,e){var n=p.find(t.nodes(),function(t){return!e.node(t).parent}),r=v(t,n);r=r.slice(1),p.each(r,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)})}function d(t,e,n){return t.hasEdge(e,n)}function f(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}var p=t("../lodash"),g=t("./feasible-tree"),y=t("./util").slack,m=t("./util").longestPath,v=t("../graphlib").alg.preorder,_=t("../graphlib").alg.postorder,b=t("../util").simplify;e.exports=n,n.initLowLimValues=s,n.initCutValues=r,n.calcCutValue=a,n.leaveEdge=u,n.enterEdge=c,n.exchangeEdges=l},{"../graphlib":59,"../lodash":62,"../util":81,"./feasible-tree":77,"./util":80}],80:[function(t,e){"use strict";function n(t){function e(r){var a=t.node(r);if(i.has(n,r))return a.rank;n[r]=!0;var s=i.min(i.map(t.outEdges(r),function(n){return e(n.w)-t.edge(n).minlen}));return s===Number.POSITIVE_INFINITY&&(s=0),a.rank=s}var n={};i.each(t.sources(),e)}function r(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}var i=t("../lodash");e.exports={longestPath:n,slack:r}},{"../lodash":62}],81:[function(t,e){"use strict";function n(t,e,n,r){var i;do i=y.uniqueId(r);while(t.hasNode(i));return n.dummy=e,t.setNode(i,n),i}function r(t){var e=(new m).setGraph(t.graph());return y.each(t.nodes(),function(n){e.setNode(n,t.node(n))}),y.each(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}function i(t){var e=new m({multigraph:t.isMultigraph()}).setGraph(t.graph());return y.each(t.nodes(),function(n){t.children(n).length||e.setNode(n,t.node(n))}),y.each(t.edges(),function(n){e.setEdge(n,t.edge(n))}),e}function a(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.outEdges(e),function(e){n[e.w]=(n[e.w]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function s(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.inEdges(e),function(e){n[e.v]=(n[e.v]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function o(t,e){var n=t.x,r=t.y,i=e.x-n,a=e.y-r,s=t.width/2,o=t.height/2;if(!i&&!a)throw new Error("Not possible to find intersection inside of the rectangle");var u,c;return Math.abs(a)*s>Math.abs(i)*o?(0>a&&(o=-o),u=o*i/a,c=o):(0>i&&(s=-s),u=s,c=s*a/i),{x:n+u,y:r+c}}function u(t){var e=y.map(y.range(d(t)+1),function(){return[]});return y.each(t.nodes(),function(n){var r=t.node(n),i=r.rank;y.isUndefined(i)||(e[i][r.order]=n)}),e}function c(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank}));y.each(t.nodes(),function(n){var r=t.node(n);y.has(r,"rank")&&(r.rank-=e)})}function l(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank})),n=[];y.each(t.nodes(),function(r){var i=t.node(r).rank-e;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=t.graph().nodeRankFactor;y.each(n,function(e,n){y.isUndefined(e)&&n%i!==0?--r:r&&y.each(e,function(e){t.node(e).rank+=r})})}function h(t,e,r,i){var a={width:0,height:0};return arguments.length>=4&&(a.rank=r,a.order=i),n(t,"border",a,e)}function d(t){return y.max(y.map(t.nodes(),function(e){var n=t.node(e).rank;return y.isUndefined(n)?void 0:n}))}function f(t,e){var n={lhs:[],rhs:[]};return y.each(t,function(t){e(t)?n.lhs.push(t):n.rhs.push(t)}),n}function p(t,e){var n=y.now();try{return e()}finally{console.log(t+" time: "+(y.now()-n)+"ms")}}function g(t,e){return e()}var y=t("./lodash"),m=t("./graphlib").Graph;e.exports={addDummyNode:n,simplify:r,asNonCompoundGraph:i,successorWeights:a,predecessorWeights:s,intersectRect:o,buildLayerMatrix:u,normalizeRanks:c,removeEmptyRanks:l,addBorderNode:h,maxRank:d,partition:f,time:p,notime:g}},{"./graphlib":59,"./lodash":62}],82:[function(t,e){e.exports="0.7.4"},{}],83:[function(t,e){e.exports=t(32)},{"./lib":99,"./lib/alg":90,"./lib/json":100,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/index.js":32}],84:[function(t,e){e.exports=t(33)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/components.js":33}],85:[function(t,e){e.exports=t(34)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dfs.js":34}],86:[function(t,e){e.exports=t(35)},{"../lodash":101,"./dijkstra":87,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra-all.js":35}],87:[function(t,e){e.exports=t(36)},{"../data/priority-queue":97,"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra.js":36}],88:[function(t,e){e.exports=t(37)},{"../lodash":101,"./tarjan":95,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/find-cycles.js":37}],89:[function(t,e){e.exports=t(38)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/floyd-warshall.js":38}],90:[function(t,e){e.exports=t(39)},{"./components":84,"./dijkstra":87,"./dijkstra-all":86,"./find-cycles":88,"./floyd-warshall":89,"./is-acyclic":91,"./postorder":92,"./preorder":93,"./prim":94,"./tarjan":95,"./topsort":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/index.js":39}],91:[function(t,e){e.exports=t(40)},{"./topsort":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/is-acyclic.js":40}],92:[function(t,e){e.exports=t(41)},{"./dfs":85,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/postorder.js":41}],93:[function(t,e){e.exports=t(42)},{"./dfs":85,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/preorder.js":42}],94:[function(t,e){e.exports=t(43)},{"../data/priority-queue":97,"../graph":98,"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/prim.js":43}],95:[function(t,e){e.exports=t(44)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/tarjan.js":44}],96:[function(t,e){e.exports=t(45)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/topsort.js":45}],97:[function(t,e){e.exports=t(46)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/data/priority-queue.js":46}],98:[function(t,e){e.exports=t(47)},{"./lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/graph.js":47}],99:[function(t,e){e.exports=t(48)},{"./graph":98,"./version":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/index.js":48}],100:[function(t,e){e.exports=t(49)},{"./graph":98,"./lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/json.js":49}],101:[function(t,e){e.exports=t(50)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":50,lodash:103}],102:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/version.js":51}],103:[function(t,e){e.exports=t(52)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/lodash/index.js":52}],104:[function(t,e,n){!function(t,r){"object"==typeof n&&"undefined"!=typeof e?e.exports=r():"function"==typeof define&&define.amd?define(r):t.moment=r()}(this,function(){"use strict";function n(){return Pn.apply(null,arguments)}function r(t){Pn=t}function i(t){return"[object Array]"===Object.prototype.toString.call(t)}function a(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function s(t,e){var n,r=[];for(n=0;n0)for(n in Rn)r=Rn[n],i=e[r],"undefined"!=typeof i&&(t[r]=i);return t}function g(t){p(this,t),this._d=new Date(null!=t._d?t._d.getTime():0/0),jn===!1&&(jn=!0,n.updateOffset(this),jn=!1)}function y(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function m(t){return 0>t?Math.ceil(t):Math.floor(t)}function v(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=m(e)),n}function _(t,e,n){var r,i=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),s=0;for(r=0;i>r;r++)(n&&t[r]!==e[r]||!n&&v(t[r])!==v(e[r]))&&s++;return s+a}function b(){}function A(t){return t?t.toLowerCase().replace("_","-"):t}function x(t){for(var e,n,r,i,a=0;a0;){if(r=w(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&_(i,n,!0)>=e-1)break;e--}a++}return null}function w(n){var r=null;if(!Yn[n]&&"undefined"!=typeof e&&e&&e.exports)try{r=Nn._abbr,t("./locale/"+n),k(r)}catch(i){}return Yn[n]}function k(t,e){var n;return t&&(n="undefined"==typeof e?D(t):E(t,e),n&&(Nn=n)),Nn._abbr}function E(t,e){return null!==e?(e.abbr=t,Yn[t]=Yn[t]||new b,Yn[t].set(e),k(t),Yn[t]):(delete Yn[t],null)}function D(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Nn;if(!i(t)){if(e=w(t))return e;t=[t]}return x(t)}function C(t,e){var n=t.toLowerCase();$n[n]=$n[n+"s"]=$n[e]=t}function F(t){return"string"==typeof t?$n[t]||$n[t.toLowerCase()]:void 0}function T(t){var e,n,r={};for(n in t)o(t,n)&&(e=F(n),e&&(r[e]=t[n]));return r}function S(t,e){return function(r){return null!=r?(O(this,t,r),n.updateOffset(this,e),this):B(this,t)}}function B(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function O(t,e,n){return t._d["set"+(t._isUTC?"UTC":"")+e](n)}function I(t,e){var n;if("object"==typeof t)for(n in t)this.set(n,t[n]);else if(t=F(t),"function"==typeof this[t])return this[t](e);return this}function M(t,e,n){var r=""+Math.abs(t),i=e-r.length,a=t>=0;return(a?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}function L(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&(Vn[t]=i),e&&(Vn[e[0]]=function(){return M(i.apply(this,arguments),e[1],e[2])}),n&&(Vn[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function P(t){return t.match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"")}function N(t){var e,n,r=t.match(Un);for(e=0,n=r.length;n>e;e++)r[e]=Vn[r[e]]?Vn[r[e]]:P(r[e]);return function(i){var a="";for(e=0;n>e;e++)a+=r[e]instanceof Function?r[e].call(i,t):r[e];return a}}function R(t,e){return t.isValid()?(e=j(e,t.localeData()),Gn[e]=Gn[e]||N(e),Gn[e](t)):t.localeData().invalidDate()}function j(t,e){function n(t){return e.longDateFormat(t)||t}var r=5;for(Wn.lastIndex=0;r>=0&&Wn.test(t);)t=t.replace(Wn,n),Wn.lastIndex=0,r-=1;return t}function Y(t){return"function"==typeof t&&"[object Function]"===Object.prototype.toString.call(t)}function $(t,e,n){sr[t]=Y(e)?e:function(t){return t&&n?n:e}}function U(t,e){return o(sr,t)?sr[t](e._strict,e._locale):new RegExp(W(t))}function W(t){return t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,n,r,i){return e||n||r||i}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function G(t,e){var n,r=e;for("string"==typeof t&&(t=[t]),"number"==typeof e&&(r=function(t,n){n[e]=v(t)}),n=0;nr;r++){if(i=c([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(a="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(a.replace(".",""),"i")),n&&"MMMM"===e&&this._longMonthsParse[r].test(t))return r;if(n&&"MMM"===e&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}}function K(t,e){var n;return"string"==typeof e&&(e=t.localeData().monthsParse(e),"number"!=typeof e)?t:(n=Math.min(t.date(),z(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n),t)}function Q(t){return null!=t?(K(this,t),n.updateOffset(this,!0),this):B(this,"Month")}function J(){return z(this.year(),this.month())}function tt(t){var e,n=t._a;return n&&-2===h(t).overflow&&(e=n[cr]<0||n[cr]>11?cr:n[lr]<1||n[lr]>z(n[ur],n[cr])?lr:n[hr]<0||n[hr]>24||24===n[hr]&&(0!==n[dr]||0!==n[fr]||0!==n[pr])?hr:n[dr]<0||n[dr]>59?dr:n[fr]<0||n[fr]>59?fr:n[pr]<0||n[pr]>999?pr:-1,h(t)._overflowDayOfYear&&(ur>e||e>lr)&&(e=lr),h(t).overflow=e),t}function et(t){n.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function nt(t,e){var n=!0;return u(function(){return n&&(et(t+"\n"+(new Error).stack),n=!1),e.apply(this,arguments)},e)}function rt(t,e){mr[t]||(et(e),mr[t]=!0)}function it(t){var e,n,r=t._i,i=vr.exec(r);if(i){for(h(t).iso=!0,e=0,n=_r.length;n>e;e++)if(_r[e][1].exec(r)){t._f=_r[e][0];break}for(e=0,n=br.length;n>e;e++)if(br[e][1].exec(r)){t._f+=(i[6]||" ")+br[e][0];break}r.match(rr)&&(t._f+="Z"),wt(t)}else t._isValid=!1}function at(t){var e=Ar.exec(t._i);return null!==e?void(t._d=new Date(+e[1])):(it(t),void(t._isValid===!1&&(delete t._isValid,n.createFromInputFallback(t))))}function st(t,e,n,r,i,a,s){var o=new Date(t,e,n,r,i,a,s);return 1970>t&&o.setFullYear(t),o}function ot(t){var e=new Date(Date.UTC.apply(null,arguments));return 1970>t&&e.setUTCFullYear(t),e}function ut(t){return ct(t)?366:365}function ct(t){return t%4===0&&t%100!==0||t%400===0}function lt(){return ct(this.year())}function ht(t,e,n){var r,i=n-e,a=n-t.day();return a>i&&(a-=7),i-7>a&&(a+=7),r=Bt(t).add(a,"d"),{week:Math.ceil(r.dayOfYear()/7),year:r.year()}}function dt(t){return ht(t,this._week.dow,this._week.doy).week}function ft(){return this._week.dow}function pt(){return this._week.doy}function gt(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")}function yt(t){var e=ht(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")}function mt(t,e,n,r,i){var a,s=6+i-r,o=ot(t,0,1+s),u=o.getUTCDay();return i>u&&(u+=7),n=null!=n?1*n:i,a=1+s+7*(e-1)-u+n,{year:a>0?t:t-1,dayOfYear:a>0?a:ut(t-1)+a}}function vt(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")}function _t(t,e,n){return null!=t?t:null!=e?e:n}function bt(t){var e=new Date;return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function At(t){var e,n,r,i,a=[];if(!t._d){for(r=bt(t),t._w&&null==t._a[lr]&&null==t._a[cr]&&xt(t),t._dayOfYear&&(i=_t(t._a[ur],r[ur]),t._dayOfYear>ut(i)&&(h(t)._overflowDayOfYear=!0),n=ot(i,0,t._dayOfYear),t._a[cr]=n.getUTCMonth(),t._a[lr]=n.getUTCDate()),e=0;3>e&&null==t._a[e];++e)t._a[e]=a[e]=r[e];for(;7>e;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[hr]&&0===t._a[dr]&&0===t._a[fr]&&0===t._a[pr]&&(t._nextDay=!0,t._a[hr]=0),t._d=(t._useUTC?ot:st).apply(null,a),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm), -t._nextDay&&(t._a[hr]=24)}}function xt(t){var e,n,r,i,a,s,o;e=t._w,null!=e.GG||null!=e.W||null!=e.E?(a=1,s=4,n=_t(e.GG,t._a[ur],ht(Bt(),1,4).year),r=_t(e.W,1),i=_t(e.E,1)):(a=t._locale._week.dow,s=t._locale._week.doy,n=_t(e.gg,t._a[ur],ht(Bt(),a,s).year),r=_t(e.w,1),null!=e.d?(i=e.d,a>i&&++r):i=null!=e.e?e.e+a:a),o=mt(n,r,i,s,a),t._a[ur]=o.year,t._dayOfYear=o.dayOfYear}function wt(t){if(t._f===n.ISO_8601)return void it(t);t._a=[],h(t).empty=!0;var e,r,i,a,s,o=""+t._i,u=o.length,c=0;for(i=j(t._f,t._locale).match(Un)||[],e=0;e0&&h(t).unusedInput.push(s),o=o.slice(o.indexOf(r)+r.length),c+=r.length),Vn[a]?(r?h(t).empty=!1:h(t).unusedTokens.push(a),H(a,r,t)):t._strict&&!r&&h(t).unusedTokens.push(a);h(t).charsLeftOver=u-c,o.length>0&&h(t).unusedInput.push(o),h(t).bigHour===!0&&t._a[hr]<=12&&t._a[hr]>0&&(h(t).bigHour=void 0),t._a[hr]=kt(t._locale,t._a[hr],t._meridiem),At(t),tt(t)}function kt(t,e,n){var r;return null==n?e:null!=t.meridiemHour?t.meridiemHour(e,n):null!=t.isPM?(r=t.isPM(n),r&&12>e&&(e+=12),r||12!==e||(e=0),e):e}function Et(t){var e,n,r,i,a;if(0===t._f.length)return h(t).invalidFormat=!0,void(t._d=new Date(0/0));for(i=0;ia)&&(r=a,n=e));u(t,n||e)}function Dt(t){if(!t._d){var e=T(t._i);t._a=[e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],At(t)}}function Ct(t){var e=new g(tt(Ft(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=void 0),e}function Ft(t){var e=t._i,n=t._f;return t._locale=t._locale||D(t._l),null===e||void 0===n&&""===e?f({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),y(e)?new g(tt(e)):(i(n)?Et(t):n?wt(t):a(e)?t._d=e:Tt(t),t))}function Tt(t){var e=t._i;void 0===e?t._d=new Date:a(e)?t._d=new Date(+e):"string"==typeof e?at(t):i(e)?(t._a=s(e.slice(0),function(t){return parseInt(t,10)}),At(t)):"object"==typeof e?Dt(t):"number"==typeof e?t._d=new Date(e):n.createFromInputFallback(t)}function St(t,e,n,r,i){var a={};return"boolean"==typeof n&&(r=n,n=void 0),a._isAMomentObject=!0,a._useUTC=a._isUTC=i,a._l=n,a._i=t,a._f=e,a._strict=r,Ct(a)}function Bt(t,e,n,r){return St(t,e,n,r,!1)}function Ot(t,e){var n,r;if(1===e.length&&i(e[0])&&(e=e[0]),!e.length)return Bt();for(n=e[0],r=1;rt&&(t=-t,n="-"),n+M(~~(t/60),2)+e+M(~~t%60,2)})}function Rt(t){var e=(t||"").match(rr)||[],n=e[e.length-1]||[],r=(n+"").match(Dr)||["-",0,0],i=+(60*r[1])+v(r[2]);return"+"===r[0]?i:-i}function jt(t,e){var r,i;return e._isUTC?(r=e.clone(),i=(y(t)||a(t)?+t:+Bt(t))-+r,r._d.setTime(+r._d+i),n.updateOffset(r,!1),r):Bt(t).local()}function Yt(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function $t(t,e){var r,i=this._offset||0;return null!=t?("string"==typeof t&&(t=Rt(t)),Math.abs(t)<16&&(t=60*t),!this._isUTC&&e&&(r=Yt(this)),this._offset=t,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==t&&(!e||this._changeInProgress?re(this,Qt(t-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?i:Yt(this)}function Ut(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function Wt(t){return this.utcOffset(0,t)}function Gt(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(Yt(this),"m")),this}function Vt(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(Rt(this._i)),this}function Ht(t){return t=t?Bt(t).utcOffset():0,(this.utcOffset()-t)%60===0}function zt(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function qt(){if("undefined"!=typeof this._isDSTShifted)return this._isDSTShifted;var t={};if(p(t,this),t=Ft(t),t._a){var e=t._isUTC?c(t._a):Bt(t._a);this._isDSTShifted=this.isValid()&&_(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Xt(){return!this._isUTC}function Zt(){return this._isUTC}function Kt(){return this._isUTC&&0===this._offset}function Qt(t,e){var n,r,i,a=t,s=null;return Pt(t)?a={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(a={},e?a[e]=t:a.milliseconds=t):(s=Cr.exec(t))?(n="-"===s[1]?-1:1,a={y:0,d:v(s[lr])*n,h:v(s[hr])*n,m:v(s[dr])*n,s:v(s[fr])*n,ms:v(s[pr])*n}):(s=Fr.exec(t))?(n="-"===s[1]?-1:1,a={y:Jt(s[2],n),M:Jt(s[3],n),d:Jt(s[4],n),h:Jt(s[5],n),m:Jt(s[6],n),s:Jt(s[7],n),w:Jt(s[8],n)}):null==a?a={}:"object"==typeof a&&("from"in a||"to"in a)&&(i=ee(Bt(a.from),Bt(a.to)),a={},a.ms=i.milliseconds,a.M=i.months),r=new Lt(a),Pt(t)&&o(t,"_locale")&&(r._locale=t._locale),r}function Jt(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function te(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 ee(t,e){var n;return e=jt(e,t),t.isBefore(e)?n=te(t,e):(n=te(e,t),n.milliseconds=-n.milliseconds,n.months=-n.months),n}function ne(t,e){return function(n,r){var i,a;return null===r||isNaN(+r)||(rt(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=Qt(n,r),re(this,i,t),this}}function re(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&&O(t,"Date",B(t,"Date")+s*r),o&&K(t,B(t,"Month")+o*r),i&&n.updateOffset(t,s||o)}function ie(t,e){var n=t||Bt(),r=jt(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,Bt(n)))}function ae(){return new g(this)}function se(t,e){var n;return e=F("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Bt(t),+this>+t):(n=y(t)?+t:+Bt(t),n<+this.clone().startOf(e))}function oe(t,e){var n;return e=F("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Bt(t),+t>+this):(n=y(t)?+t:+Bt(t),+this.clone().endOf(e)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 de(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function fe(){var t=this.clone().utc();return 0e;e++)if(this._weekdaysParse[e]||(n=Bt([2e3,1]).day(e),r="^"+this.weekdays(n,"")+"|^"+this.weekdaysShort(n,"")+"|^"+this.weekdaysMin(n,""),this._weekdaysParse[e]=new RegExp(r.replace(".",""),"i")),this._weekdaysParse[e].test(t))return e}function We(t){var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=Re(t,this.localeData()),this.add(t-e,"d")):e}function Ge(t){var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")}function Ve(t){return null==t?this.day()||7:this.day(this.day()%7?t:t-7)}function He(t,e){L(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}function ze(t,e){return e._meridiemParse}function qe(t){return"p"===(t+"").toLowerCase().charAt(0)}function Xe(t,e,n){return t>11?n?"pm":"PM":n?"am":"AM"}function Ze(t,e){e[pr]=v(1e3*("0."+t))}function Ke(){return this._isUTC?"UTC":""}function Qe(){return this._isUTC?"Coordinated Universal Time":""}function Je(t){return Bt(1e3*t)}function tn(){return Bt.apply(null,arguments).parseZone()}function en(t,e,n){var r=this._calendar[t];return"function"==typeof r?r.call(e,n):r}function nn(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.replace(/MMMM|MM|DD|dddd/g,function(t){return t.slice(1)}),this._longDateFormat[t])}function rn(){return this._invalidDate}function an(t){return this._ordinal.replace("%d",t)}function sn(t){return t}function on(t,e,n,r){var i=this._relativeTime[n];return"function"==typeof i?i(t,e,n,r):i.replace(/%d/i,t)}function un(t,e){var n=this._relativeTime[t>0?"future":"past"];return"function"==typeof n?n(e):n.replace(/%s/i,e)}function cn(t){var e,n;for(n in t)e=t[n],"function"==typeof e?this[n]=e:this["_"+n]=e;this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function ln(t,e,n,r){var i=D(),a=c().set(r,e);return i[n](a,t)}function hn(t,e,n,r,i){if("number"==typeof t&&(e=t,t=void 0),t=t||"",null!=e)return ln(t,e,n,i);var a,s=[];for(a=0;r>a;a++)s[a]=ln(t,a,n,i);return s}function dn(t,e){return hn(t,e,"months",12,"month")}function fn(t,e){return hn(t,e,"monthsShort",12,"month")}function pn(t,e){return hn(t,e,"weekdays",7,"day")}function gn(t,e){return hn(t,e,"weekdaysShort",7,"day")}function yn(t,e){return hn(t,e,"weekdaysMin",7,"day")}function mn(){var t=this._data;return this._milliseconds=Kr(this._milliseconds),this._days=Kr(this._days),this._months=Kr(this._months),t.milliseconds=Kr(t.milliseconds),t.seconds=Kr(t.seconds),t.minutes=Kr(t.minutes),t.hours=Kr(t.hours),t.months=Kr(t.months),t.years=Kr(t.years),this}function vn(t,e,n,r){var i=Qt(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function _n(t,e){return vn(this,t,e,1)}function bn(t,e){return vn(this,t,e,-1)}function An(t){return 0>t?Math.floor(t):Math.ceil(t)}function xn(){var t,e,n,r,i,a=this._milliseconds,s=this._days,o=this._months,u=this._data;return a>=0&&s>=0&&o>=0||0>=a&&0>=s&&0>=o||(a+=864e5*An(kn(o)+s),s=0,o=0),u.milliseconds=a%1e3,t=m(a/1e3),u.seconds=t%60,e=m(t/60),u.minutes=e%60,n=m(e/60),u.hours=n%24,s+=m(n/24),i=m(wn(s)),o+=i,s-=An(kn(i)),r=m(o/12),o%=12,u.days=s,u.months=o,u.years=r,this}function wn(t){return 4800*t/146097}function kn(t){return 146097*t/4800}function En(t){var e,n,r=this._milliseconds;if(t=F(t),"month"===t||"year"===t)return e=this._days+r/864e5,n=this._months+wn(e),"month"===t?n:n/12;switch(e=this._days+Math.round(kn(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return 24*e+r/36e5;case"minute":return 1440*e+r/6e4;case"second":return 86400*e+r/1e3;case"millisecond":return Math.floor(864e5*e)+r;default:throw new Error("Unknown unit "+t)}}function Dn(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function Cn(t){return function(){return this.as(t)}}function Fn(t){return t=F(t),this[t+"s"]()}function Tn(t){return function(){return this._data[t]}}function Sn(){return m(this.days()/7)}function Bn(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}function On(t,e,n){var r=Qt(t).abs(),i=fi(r.as("s")),a=fi(r.as("m")),s=fi(r.as("h")),o=fi(r.as("d")),u=fi(r.as("M")),c=fi(r.as("y")),l=i0,l[4]=n,Bn.apply(null,l)}function In(t,e){return void 0===pi[t]?!1:void 0===e?pi[t]:(pi[t]=e,!0)}function Mn(t){var e=this.localeData(),n=On(this,!t,e);return t&&(n=e.pastFuture(+this,n)),e.postformat(n)}function Ln(){var t,e,n,r=gi(this._milliseconds)/1e3,i=gi(this._days),a=gi(this._months);t=m(r/60),e=m(t/60),r%=60,t%=60,n=m(a/12),a%=12;var s=n,o=a,u=i,c=e,l=t,h=r,d=this.asSeconds();return d?(0>d?"-":"")+"P"+(s?s+"Y":"")+(o?o+"M":"")+(u?u+"D":"")+(c||l||h?"T":"")+(c?c+"H":"")+(l?l+"M":"")+(h?h+"S":""):"P0D"}var Pn,Nn,Rn=n.momentProperties=[],jn=!1,Yn={},$n={},Un=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Wn=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Gn={},Vn={},Hn=/\d/,zn=/\d\d/,qn=/\d{3}/,Xn=/\d{4}/,Zn=/[+-]?\d{6}/,Kn=/\d\d?/,Qn=/\d{1,3}/,Jn=/\d{1,4}/,tr=/[+-]?\d{1,6}/,er=/\d+/,nr=/[+-]?\d+/,rr=/Z|[+-]\d\d:?\d\d/gi,ir=/[+-]?\d+(\.\d{1,3})?/,ar=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,sr={},or={},ur=0,cr=1,lr=2,hr=3,dr=4,fr=5,pr=6;L("M",["MM",2],"Mo",function(){return this.month()+1}),L("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),L("MMMM",0,0,function(t){return this.localeData().months(this,t)}),C("month","M"),$("M",Kn),$("MM",Kn,zn),$("MMM",ar),$("MMMM",ar),G(["M","MM"],function(t,e){e[cr]=v(t)-1}),G(["MMM","MMMM"],function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);null!=i?e[cr]=i:h(n).invalidMonth=t});var gr="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),yr="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),mr={};n.suppressDeprecationWarnings=!1;var vr=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,_r=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],br=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],Ar=/^\/?Date\((\-?\d+)/i;n.createFromInputFallback=nt("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),L(0,["YY",2],0,function(){return this.year()%100}),L(0,["YYYY",4],0,"year"),L(0,["YYYYY",5],0,"year"),L(0,["YYYYYY",6,!0],0,"year"),C("year","y"),$("Y",nr),$("YY",Kn,zn),$("YYYY",Jn,Xn),$("YYYYY",tr,Zn),$("YYYYYY",tr,Zn),G(["YYYYY","YYYYYY"],ur),G("YYYY",function(t,e){e[ur]=2===t.length?n.parseTwoDigitYear(t):v(t)}),G("YY",function(t,e){e[ur]=n.parseTwoDigitYear(t)}),n.parseTwoDigitYear=function(t){return v(t)+(v(t)>68?1900:2e3)};var xr=S("FullYear",!1);L("w",["ww",2],"wo","week"),L("W",["WW",2],"Wo","isoWeek"),C("week","w"),C("isoWeek","W"),$("w",Kn),$("ww",Kn,zn),$("W",Kn),$("WW",Kn,zn),V(["w","ww","W","WW"],function(t,e,n,r){e[r.substr(0,1)]=v(t)});var wr={dow:0,doy:6};L("DDD",["DDDD",3],"DDDo","dayOfYear"),C("dayOfYear","DDD"),$("DDD",Qn),$("DDDD",qn),G(["DDD","DDDD"],function(t,e,n){n._dayOfYear=v(t)}),n.ISO_8601=function(){};var kr=nt("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var t=Bt.apply(null,arguments);return this>t?this:t}),Er=nt("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var t=Bt.apply(null,arguments);return t>this?this:t});Nt("Z",":"),Nt("ZZ",""),$("Z",rr),$("ZZ",rr),G(["Z","ZZ"],function(t,e,n){n._useUTC=!0,n._tzm=Rt(t)});var Dr=/([\+\-]|\d\d)/gi;n.updateOffset=function(){};var Cr=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Fr=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/;Qt.fn=Lt.prototype;var Tr=ne(1,"add"),Sr=ne(-1,"subtract");n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var Br=nt("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return void 0===t?this.localeData():this.locale(t)});L(0,["gg",2],0,function(){return this.weekYear()%100}),L(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Be("gggg","weekYear"),Be("ggggg","weekYear"),Be("GGGG","isoWeekYear"),Be("GGGGG","isoWeekYear"),C("weekYear","gg"),C("isoWeekYear","GG"),$("G",nr),$("g",nr),$("GG",Kn,zn),$("gg",Kn,zn),$("GGGG",Jn,Xn),$("gggg",Jn,Xn),$("GGGGG",tr,Zn),$("ggggg",tr,Zn),V(["gggg","ggggg","GGGG","GGGGG"],function(t,e,n,r){e[r.substr(0,2)]=v(t)}),V(["gg","GG"],function(t,e,r,i){e[i]=n.parseTwoDigitYear(t)}),L("Q",0,0,"quarter"),C("quarter","Q"),$("Q",Hn),G("Q",function(t,e){e[cr]=3*(v(t)-1)}),L("D",["DD",2],"Do","date"),C("date","D"),$("D",Kn),$("DD",Kn,zn),$("Do",function(t,e){return t?e._ordinalParse:e._ordinalParseLenient}),G(["D","DD"],lr),G("Do",function(t,e){e[lr]=v(t.match(Kn)[0],10)});var Or=S("Date",!0);L("d",0,"do","day"),L("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),L("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),L("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),L("e",0,0,"weekday"),L("E",0,0,"isoWeekday"),C("day","d"),C("weekday","e"),C("isoWeekday","E"),$("d",Kn),$("e",Kn),$("E",Kn),$("dd",ar),$("ddd",ar),$("dddd",ar),V(["dd","ddd","dddd"],function(t,e,n){var r=n._locale.weekdaysParse(t);null!=r?e.d=r:h(n).invalidWeekday=t}),V(["d","e","E"],function(t,e,n,r){e[r]=v(t)});var Ir="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Mr="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Lr="Su_Mo_Tu_We_Th_Fr_Sa".split("_");L("H",["HH",2],0,"hour"),L("h",["hh",2],0,function(){return this.hours()%12||12}),He("a",!0),He("A",!1),C("hour","h"),$("a",ze),$("A",ze),$("H",Kn),$("h",Kn),$("HH",Kn,zn),$("hh",Kn,zn),G(["H","HH"],hr),G(["a","A"],function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t}),G(["h","hh"],function(t,e,n){e[hr]=v(t),h(n).bigHour=!0});var Pr=/[ap]\.?m?\.?/i,Nr=S("Hours",!0);L("m",["mm",2],0,"minute"),C("minute","m"),$("m",Kn),$("mm",Kn,zn),G(["m","mm"],dr);var Rr=S("Minutes",!1);L("s",["ss",2],0,"second"),C("second","s"),$("s",Kn),$("ss",Kn,zn),G(["s","ss"],fr);var jr=S("Seconds",!1);L("S",0,0,function(){return~~(this.millisecond()/100)}),L(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),L(0,["SSS",3],0,"millisecond"),L(0,["SSSS",4],0,function(){return 10*this.millisecond()}),L(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),L(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),L(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),L(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),L(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),C("millisecond","ms"),$("S",Qn,Hn),$("SS",Qn,zn),$("SSS",Qn,qn);var Yr;for(Yr="SSSS";Yr.length<=9;Yr+="S")$(Yr,er);for(Yr="S";Yr.length<=9;Yr+="S")G(Yr,Ze);var $r=S("Milliseconds",!1);L("z",0,0,"zoneAbbr"),L("zz",0,0,"zoneName");var Ur=g.prototype;Ur.add=Tr,Ur.calendar=ie,Ur.clone=ae,Ur.diff=le,Ur.endOf=xe,Ur.format=pe,Ur.from=ge,Ur.fromNow=ye,Ur.to=me,Ur.toNow=ve,Ur.get=I,Ur.invalidAt=Se,Ur.isAfter=se,Ur.isBefore=oe,Ur.isBetween=ue,Ur.isSame=ce,Ur.isValid=Fe,Ur.lang=Br,Ur.locale=_e,Ur.localeData=be,Ur.max=Er,Ur.min=kr,Ur.parsingFlags=Te,Ur.set=I,Ur.startOf=Ae,Ur.subtract=Sr,Ur.toArray=De,Ur.toObject=Ce,Ur.toDate=Ee,Ur.toISOString=fe,Ur.toJSON=fe,Ur.toString=de,Ur.unix=ke,Ur.valueOf=we,Ur.year=xr,Ur.isLeapYear=lt,Ur.weekYear=Ie,Ur.isoWeekYear=Me,Ur.quarter=Ur.quarters=Ne,Ur.month=Q,Ur.daysInMonth=J,Ur.week=Ur.weeks=gt,Ur.isoWeek=Ur.isoWeeks=yt,Ur.weeksInYear=Pe,Ur.isoWeeksInYear=Le,Ur.date=Or,Ur.day=Ur.days=We,Ur.weekday=Ge,Ur.isoWeekday=Ve,Ur.dayOfYear=vt,Ur.hour=Ur.hours=Nr,Ur.minute=Ur.minutes=Rr,Ur.second=Ur.seconds=jr,Ur.millisecond=Ur.milliseconds=$r,Ur.utcOffset=$t,Ur.utc=Wt,Ur.local=Gt,Ur.parseZone=Vt,Ur.hasAlignedHourOffset=Ht,Ur.isDST=zt,Ur.isDSTShifted=qt,Ur.isLocal=Xt,Ur.isUtcOffset=Zt,Ur.isUtc=Kt,Ur.isUTC=Kt,Ur.zoneAbbr=Ke,Ur.zoneName=Qe,Ur.dates=nt("dates accessor is deprecated. Use date instead.",Or),Ur.months=nt("months accessor is deprecated. Use month instead",Q),Ur.years=nt("years accessor is deprecated. Use year instead",xr),Ur.zone=nt("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Ut);var Wr=Ur,Gr={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},Vr={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"},Hr="Invalid date",zr="%d",qr=/\d{1,2}/,Xr={future:"in %s",past:"%s ago",s:"a few 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"},Zr=b.prototype;Zr._calendar=Gr,Zr.calendar=en,Zr._longDateFormat=Vr,Zr.longDateFormat=nn,Zr._invalidDate=Hr,Zr.invalidDate=rn,Zr._ordinal=zr,Zr.ordinal=an,Zr._ordinalParse=qr,Zr.preparse=sn,Zr.postformat=sn,Zr._relativeTime=Xr,Zr.relativeTime=on,Zr.pastFuture=un,Zr.set=cn,Zr.months=q,Zr._months=gr,Zr.monthsShort=X,Zr._monthsShort=yr,Zr.monthsParse=Z,Zr.week=dt,Zr._week=wr,Zr.firstDayOfYear=pt,Zr.firstDayOfWeek=ft,Zr.weekdays=je,Zr._weekdays=Ir,Zr.weekdaysMin=$e,Zr._weekdaysMin=Lr,Zr.weekdaysShort=Ye,Zr._weekdaysShort=Mr,Zr.weekdaysParse=Ue,Zr.isPM=qe,Zr._meridiemParse=Pr,Zr.meridiem=Xe,k("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,n=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+n}}),n.lang=nt("moment.lang is deprecated. Use moment.locale instead.",k),n.langData=nt("moment.langData is deprecated. Use moment.localeData instead.",D);var Kr=Math.abs,Qr=Cn("ms"),Jr=Cn("s"),ti=Cn("m"),ei=Cn("h"),ni=Cn("d"),ri=Cn("w"),ii=Cn("M"),ai=Cn("y"),si=Tn("milliseconds"),oi=Tn("seconds"),ui=Tn("minutes"),ci=Tn("hours"),li=Tn("days"),hi=Tn("months"),di=Tn("years"),fi=Math.round,pi={s:45,m:45,h:22,d:26,M:11},gi=Math.abs,yi=Lt.prototype;yi.abs=mn,yi.add=_n,yi.subtract=bn,yi.as=En,yi.asMilliseconds=Qr,yi.asSeconds=Jr,yi.asMinutes=ti,yi.asHours=ei,yi.asDays=ni,yi.asWeeks=ri,yi.asMonths=ii,yi.asYears=ai,yi.valueOf=Dn,yi._bubble=xn,yi.get=Fn,yi.milliseconds=si,yi.seconds=oi,yi.minutes=ui,yi.hours=ci,yi.days=li,yi.weeks=Sn,yi.months=hi,yi.years=di,yi.humanize=Mn,yi.toISOString=Ln,yi.toString=Ln,yi.toJSON=Ln,yi.locale=_e,yi.localeData=be,yi.toIsoString=nt("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Ln),yi.lang=Br,L("X",0,0,"unix"),L("x",0,0,"valueOf"),$("x",nr),$("X",ir),G("X",function(t,e,n){n._d=new Date(1e3*parseFloat(t,10))}),G("x",function(t,e,n){n._d=new Date(v(t))}),n.version="2.10.6",r(Bt),n.fn=Wr,n.min=It,n.max=Mt,n.utc=c,n.unix=Je,n.months=dn,n.isDate=a,n.locale=k,n.invalid=f,n.duration=Qt,n.isMoment=y,n.weekdays=pn,n.parseZone=tn,n.localeData=D,n.isDuration=Pt,n.monthsShort=fn,n.weekdaysMin=yn,n.defineLocale=E,n.weekdaysShort=gn,n.normalizeUnits=F,n.relativeTimeThreshold=In;var mi=n;return mi})},{}],105:[function(t,e){e.exports={name:"mermaid",version:"0.5.5",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:{live:"live-server ./test/examples",lint:"node node_modules/eslint/bin/eslint.js src",jison:"gulp jison_legacy",watch:"source ./scripts/watch.sh",doc:"rm -r build;rm -r dist/www;gulp vartree;cp dist/www/all.html ../mermaid-pages/index.html;cp dist/mermaid.js ../mermaid-pages/javascripts/lib;cp dist/mermaid.forest.css ../mermaid-pages/stylesheets",tape:"node node_modules/.bin/tape test/cli_test-*.js",jasmine:"npm run jison &&node node_modules/jasmine-es6/bin/jasmine.js",posttest:"npm run jison",test:"npm run dist && npm run jasmine && npm run tape","dist-slim-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.slim.js -x d3 && cat dist/mermaid.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.slim.min.js","dist-slim-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.slim.js -x d3 && cat dist/mermaidAPI.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.slim.min.js","dist-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.js && cat dist/mermaid.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.min.js","dist-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.js && cat dist/mermaidAPI.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.min.js",dist:"npm run dist-slim-mermaid;npm run dist-slim-mermaidAPI; npm run dist-mermaid;npm run dist-mermaidAPI"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"3.5.6",dagre:"^0.7.4","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","babel-eslint":"^4.1.3",babelify:"^6.4.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4",dateformat:"^1.0.11",dox:"^0.8.0",eslint:"^1.6.0","eslint-watch":"^2.1.2","event-stream":"^3.2.0",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.9.0","gulp-bower":"0.0.10","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-dox":"^0.1.6","gulp-ext-replace":"^0.2.0","gulp-filelog":"^0.4.1","gulp-front-matter":"^1.2.3","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~2.1.0","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-marked":"^1.0.0","gulp-mdvars":"^2.0.0","gulp-qunit":"~1.2.1","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1","gulp-vartree":"^2.0.1","hogan.js":"^3.0.2",jasmine:"2.3.2","jasmine-es6":"0.0.18",jison:"zaach/jison",jsdom:"^7.0.2","jshint-stylish":"^2.0.1","map-stream":"0.0.6",marked:"^0.3.2","mock-browser":"^0.91.34",path:"^0.4.9",phantomjs:"^1.9.18",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3",testdom:"^2.0.0",uglifyjs:"^2.4.10","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],106:[function(t,e){"use strict";var n;if(t)try{n=t("d3")}catch(r){}n||(n=window.d3),e.exports=n,function(){var t=!1;if(t="tspans",n.selection.prototype.textwrap)return!1;if("undefined"==typeof t)var t=!1;n.selection.prototype.textwrap=n.selection.enter.prototype.textwrap=function(e,r){var i,r=parseInt(r)||0,a=this,s=function(t){var e=t[0][0],r=e.tagName.toString();if("rect"!==r)return!1;var i={};return i.x=n.select(e).attr("x")||0,i.y=n.select(e).attr("y")||0,i.width=n.select(e).attr("width")||0,i.height=n.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)||"[object Array]"===Object.prototype.toString.call(t)){var e=s(t);return e}return!1},u=function(t,e){var n=t;return 0!==e&&(n.x=parseInt(n.x)+e,n.y=parseInt(n.y)+e,n.width-=2*e,n.height-=2*e),n},c=o(e);if(r&&(c=u(c,r)),0!=a.length&&n&&e&&c){e=c;var l,h=function(t){var r=n.select(t[0].parentNode),a=r.select("text"),s=a.style("line-height"),o=a.text();a.remove();var u=r.append("foreignObject");u.attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);var c=u.append("xhtml:div").attr("class","wrapped");c.style("height",e.height).style("width",e.width).html(o),s&&c.style("line-height",s),i=r.select("foreignObject")},d=function(t){var a,s=t[0],o=s.parentNode,u=n.select(s),c=s.getBBox().height,l=s.getBBox().width,h=c,d=u.style("line-height");if(a=d&&parseInt(d)?parseInt(d.replace("px","")):h,l>e.width){var f=u.text();if(u.text(""),f){var p,g;if(-1!==f.indexOf(" ")){var p=" ";g=f.split(" ")}else{p="";var y=f.length,m=Math.ceil(l/e.width),v=Math.floor(y/m);v*m>=y||m++;for(var _,b,g=[],A=0;m>A;A++)b=A*v,_=f.substr(b,v),g.push(_)}for(var x=[],w=0,k={},A=0;Ae.width&&C&&""!==C&&(w+=F,k={string:C,width:F,offset:w},x.push(k),u.text(""),u.text(D),A==g.length-1&&(E=D,u.text(E),T=s.getComputedTextLength())),A==g.length-1){u.text("");var S=E;S&&""!==S&&(T-w>0&&(T-=w),k={string:S,width:T,offset:w},x.push(k))}}var B;u.text("");for(var A=0;A0){x[A-1]}A*a0?a:void 0; +for(var o in t)a&&Qn(o,e)||"constructor"==o&&(i||!ta.call(t,o))||s.push(o);return s}function es(t){t=hr(t);for(var e=-1,n=Yo(t),r=n.length,i=Ys(r);++e=xa(e,n)&&tn?0:+n||0,r),n-=e.length,n>=0&&t.indexOf(e,n)==n}function ds(t){return t=o(t),t&&bt.test(t)?t.replace(vt,f):t}function fs(t){return t=o(t),t&&Ct.test(t)?t.replace(Ft,p):t||"(?:)"}function ps(t,e,n){t=o(t),e=+e;var r=t.length;if(r>=e||!_a(e))return t;var i=(e-r)/2,s=ma(i),a=ga(i);return n=In("",a,n),n.slice(0,s)+t+n}function gs(t,e,n){return(n?Jn(t,e,n):null==e)?e=0:e&&(e=+e),t=_s(t),ka(t,e||(It.test(t)?16:10))}function ys(t,e){var n="";if(t=o(t),e=+e,1>e||!t||!_a(e))return n;do e%2&&(n+=t),e=ma(e/2),t+=t;while(e);return n}function ms(t,e,n){return t=o(t),n=null==n?0:xa(0>n?0:+n||0,t.length),t.lastIndexOf(e,n)==n}function vs(t,n,r){var i=e.templateSettings;r&&Jn(t,n,r)&&(n=r=E),t=o(t),n=ye(me({},r||n),i,ge);var s,a,u=ye(me({},n.imports),i.imports,ge),c=Yo(u),l=tn(u,c),h=0,d=n.interpolate||Pt,f="__p += '",p=zs((n.escape||Pt).source+"|"+d.source+"|"+(d===wt?Bt:Pt).source+"|"+(n.evaluate||Pt).source+"|$","g"),y="//# sourceURL="+("sourceURL"in n?n.sourceURL:"lodash.templateSources["+ ++$t+"]")+"\n";t.replace(p,function(e,n,r,i,o,u){return r||(r=i),f+=t.slice(h,u).replace(Rt,g),n&&(s=!0,f+="' +\n__e("+n+") +\n'"),o&&(a=!0,f+="';\n"+o+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),h=u+e.length,e}),f+="';\n";var m=n.variable;m||(f="with (obj) {\n"+f+"\n}\n"),f=(a?f.replace(pt,""):f).replace(gt,"$1").replace(yt,"$1;"),f="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(s?", __e = _.escape":"")+(a?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var v=Ko(function(){return Gs(c,y+"return "+f).apply(E,l)});if(v.source=f,Bi(v))throw v;return v}function _s(t,e,n){var r=t;return(t=o(t))?(n?Jn(r,e,n):null==e)?t.slice(A(t),x(t)+1):(e+="",t.slice(u(t,e),c(t,e)+1)):t}function bs(t,e,n){var r=t;return t=o(t),t?t.slice((n?Jn(r,e,n):null==e)?A(t):u(t,e+"")):t}function As(t,e,n){var r=t;return t=o(t),t?(n?Jn(r,e,n):null==e)?t.slice(0,x(t)+1):t.slice(0,c(t,e+"")+1):t}function xs(t,e,n){n&&Jn(t,e,n)&&(e=E);var r=N,i=P;if(null!=e)if(Li(e)){var s="separator"in e?e.separator:s;r="length"in e?+e.length||0:r,i="omission"in e?o(e.omission):i}else r=+e||0;if(t=o(t),r>=t.length)return t;var a=r-i.length;if(1>a)return i;var u=t.slice(0,a);if(null==s)return u+i;if($i(s)){if(t.slice(a).search(s)){var c,l,h=t.slice(0,a);for(s.global||(s=zs(s.source,(Ot.exec(s)||"")+"g")),s.lastIndex=0;c=s.exec(h);)l=c.index;u=u.slice(0,null==l?a:l)}}else if(t.indexOf(s,a)!=a){var d=u.lastIndexOf(s);d>-1&&(u=u.slice(0,d))}return u+i}function ws(t){return t=o(t),t&&_t.test(t)?t.replace(mt,w):t}function ks(t,e,n){return n&&Jn(t,e,n)&&(e=E),t=o(t),t.match(e||jt)||[]}function Es(t,e,n){return n&&Jn(t,e,n)&&(e=E),m(t)?Cs(t):be(t,e)}function Ds(t){return function(){return t}}function Fs(t){return t}function Cs(t){return je(Ae(t,!0))}function Ts(t,e){return Ye(t,Ae(e,!0))}function Ss(t,e,n){if(null==n){var r=Li(e),i=r?Yo(e):E,s=i&&i.length?Ie(e,i):E;(s?s.length:r)||(s=!1,n=e,e=t,t=this)}s||(s=Ie(e,Yo(e)));var a=!0,o=-1,u=Ii(t),c=s.length;n===!1?a=!1:Li(n)&&"chain"in n&&(a=n.chain);for(;++ot||!_a(t))return[];var r=-1,i=Ys(xa(t,Ca));for(e=an(e,n,1);++rr?i[r]=e(r):e(r);return i}function Ps(t){var e=++ea;return o(t)+e}function Rs(t,e){return(+t||0)+(+e||0)}function js(t,e,n){return n&&Jn(t,e,n)&&(e=E),e=$n(e,n,3),1==e.length?fe(To(t)?t:lr(t),e):Qe(t,e)}t=t?re.defaults(ne.Object(),t,re.pick(ne,Yt)):ne;{var Ys=t.Array,$s=t.Date,Us=t.Error,Gs=t.Function,Ws=t.Math,Vs=t.Number,Hs=t.Object,zs=t.RegExp,qs=t.String,Xs=t.TypeError,Zs=Ys.prototype,Ks=Hs.prototype,Qs=qs.prototype,Js=Gs.prototype.toString,ta=Ks.hasOwnProperty,ea=0,na=Ks.toString,ra=ne._,ia=zs("^"+Js.call(ta).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),sa=t.ArrayBuffer,aa=t.clearTimeout,oa=t.parseFloat,ua=Ws.pow,ca=Ks.propertyIsEnumerable,la=Vn(t,"Set"),ha=t.setTimeout,da=Zs.splice,fa=t.Uint8Array,pa=Vn(t,"WeakMap"),ga=Ws.ceil,ya=Vn(Hs,"create"),ma=Ws.floor,va=Vn(Ys,"isArray"),_a=t.isFinite,ba=Vn(Hs,"keys"),Aa=Ws.max,xa=Ws.min,wa=Vn($s,"now"),ka=t.parseInt,Ea=Ws.random,Da=Vs.NEGATIVE_INFINITY,Fa=Vs.POSITIVE_INFINITY,Ca=4294967295,Ta=Ca-1,Sa=Ca>>>1,Ba=9007199254740991,Oa=pa&&new pa,Ia={};e.support={}}e.templateSettings={escape:At,evaluate:xt,interpolate:wt,variable:"",imports:{_:e}};var La=function(){function t(){}return function(e){if(Li(e)){t.prototype=e;var n=new t;t.prototype=E}return n||{}}}(),Ma=dn(Be),Na=dn(Oe,!0),Pa=fn(),Ra=fn(!0),ja=Oa?function(t,e){return Oa.set(t,e),t}:Fs,Ya=Oa?function(t){return Oa.get(t)}:Os,$a=Ge("length"),Ua=function(){var t=0,e=0;return function(n,r){var i=go(),s=j-(i-e);if(e=i,s>0){if(++t>=R)return n}else t=0;return ja(n,r)}}(),Ga=mi(function(t,e){return m(t)&&Kn(t)?we(t,Te(e,!1,!0)):[]}),Wa=xn(),Va=xn(!0),Ha=mi(function(t){for(var e=t.length,n=e,r=Ys(h),i=Gn(),a=i==s,o=[];n--;){var u=t[n]=Kn(u=t[n])?u:[];r[n]=a&&u.length>=120?gn(n&&u):null}var c=t[0],l=-1,h=c?c.length:0,d=r[0];t:for(;++l2?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,Rr(t,n,r)}),to=mi(function(t){return t=Te(t),this.thru(function(e){return Jt(To(e)?e:[hr(e)],t)})}),eo=mi(function(t,e){return ve(t,Te(e))}),no=ln(function(t,e,n){ta.call(t,n)?++t[n]:t[n]=1}),ro=An(Ma),io=An(Na,!0),so=En(ee,Ma),ao=En(ie,Na),oo=ln(function(t,e,n){ta.call(t,n)?t[n].push(e):t[n]=[e]}),uo=ln(function(t,e,n){t[n]=e}),co=mi(function(t,e,n){var r=-1,i="function"==typeof e,s=tr(e),a=Kn(t)?Ys(t.length):[];return Ma(t,function(t){var o=i?e:s&&null!=t?t[e]:E;a[++r]=o?o.apply(t,n):Zn(t,e,n)}),a}),lo=ln(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),ho=Bn(le,Ma),fo=Bn(he,Na),po=mi(function(t,e){if(null==t)return[];var n=e[2];return n&&Jn(e[0],e[1],n)&&(e.length=1),Ke(t,Te(e),[])}),go=wa||function(){return(new $s).getTime()},yo=mi(function(t,e,n){var r=F;if(n.length){var i=_(n,yo.placeholder);r|=O}return Pn(t,r,e,n,i)}),mo=mi(function(t,e){e=e.length?Te(e):Zi(t);for(var n=-1,r=e.length;++n0||0>e)?new K(n):(0>t?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==E&&(e=+e||0,n=0>e?n.dropRight(-e):n.take(e-t)),n)},K.prototype.takeRightWhile=function(t,e){return this.reverse().takeWhile(t,e).reverse()},K.prototype.toArray=function(){return this.take(Fa)},Be(K.prototype,function(t,n){var r=/^(?:filter|map|reject)|While$/.test(n),i=/^(?:first|last)$/.test(n),s=e[i?"take"+("last"==n?"Right":""):n];s&&(e.prototype[n]=function(){var e=i?[1]:arguments,n=this.__chain__,a=this.__wrapped__,o=!!this.__actions__.length,u=a instanceof K,c=e[0],l=u||To(a);l&&r&&"function"==typeof c&&1!=c.length&&(u=l=!1);var h=function(t){return i&&n?s(t,1)[0]:s.apply(E,ce([t],e))},d={func:Gr,args:[h],thisArg:E},f=u&&!o;if(i&&!n)return f?(a=a.clone(),a.__actions__.push(d),t.call(a)):s.call(E,this.value())[0];if(!i&&l){a=f?a:new K(this);var p=t.apply(a,e);return p.__actions__.push(d),new v(p,n)}return this.thru(h)})}),ee(["join","pop","push","replace","shift","sort","splice","split","unshift"],function(t){var n=(/^(?:replace|split)$/.test(t)?Qs:Zs)[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",i=/^(?:join|pop|replace|shift)$/.test(t);e.prototype[t]=function(){var t=arguments;return i&&!this.__chain__?n.apply(this.value(),t):this[r](function(e){return n.apply(e,t)})}}),Be(K.prototype,function(t,n){var r=e[n];if(r){var i=r.name,s=Ia[i]||(Ia[i]=[]);s.push({name:n,func:r})}}),Ia[On(E,C).name]=[{name:"wrapper",func:E}],K.prototype.clone=et,K.prototype.reverse=rt,K.prototype.value=Wt,e.prototype.chain=Wr,e.prototype.commit=Vr,e.prototype.concat=to,e.prototype.plant=Hr,e.prototype.reverse=zr,e.prototype.toString=qr,e.prototype.run=e.prototype.toJSON=e.prototype.valueOf=e.prototype.value=Xr,e.prototype.collect=e.prototype.map,e.prototype.head=e.prototype.first,e.prototype.select=e.prototype.filter,e.prototype.tail=e.prototype.rest,e}var E,D="3.10.1",F=1,C=2,T=4,S=8,B=16,O=32,I=64,L=128,M=256,N=30,P="...",R=150,j=16,Y=200,$=1,U=2,G="Expected a function",W="__lodash_placeholder__",V="[object Arguments]",H="[object Array]",z="[object Boolean]",q="[object Date]",X="[object Error]",Z="[object Function]",K="[object Map]",Q="[object Number]",J="[object Object]",tt="[object RegExp]",et="[object Set]",nt="[object String]",rt="[object WeakMap]",it="[object ArrayBuffer]",st="[object Float32Array]",at="[object Float64Array]",ot="[object Int8Array]",ut="[object Int16Array]",ct="[object Int32Array]",lt="[object Uint8Array]",ht="[object Uint8ClampedArray]",dt="[object Uint16Array]",ft="[object Uint32Array]",pt=/\b__p \+= '';/g,gt=/\b(__p \+=) '' \+/g,yt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,mt=/&(?:amp|lt|gt|quot|#39|#96);/g,vt=/[&<>"'`]/g,_t=RegExp(mt.source),bt=RegExp(vt.source),At=/<%-([\s\S]+?)%>/g,xt=/<%([\s\S]+?)%>/g,wt=/<%=([\s\S]+?)%>/g,kt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\n\\]|\\.)*?\1)\]/,Et=/^\w*$/,Dt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g,Ft=/^[:!,]|[\\^$.*+?()[\]{}|\/]|(^[0-9a-fA-Fnrtuvx])|([\n\r\u2028\u2029])/g,Ct=RegExp(Ft.source),Tt=/[\u0300-\u036f\ufe20-\ufe23]/g,St=/\\(\\)?/g,Bt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Ot=/\w*$/,It=/^0[xX]/,Lt=/^\[object .+?Constructor\]$/,Mt=/^\d+$/,Nt=/[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g,Pt=/($^)/,Rt=/['\n\r\u2028\u2029\\]/g,jt=function(){var t="[A-Z\\xc0-\\xd6\\xd8-\\xde]",e="[a-z\\xdf-\\xf6\\xf8-\\xff]+";return RegExp(t+"+(?="+t+e+")|"+t+"?"+e+"|"+t+"+|[0-9]+","g")}(),Yt=["Array","ArrayBuffer","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Math","Number","Object","RegExp","Set","String","_","clearTimeout","isFinite","parseFloat","parseInt","setTimeout","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap"],$t=-1,Ut={};Ut[st]=Ut[at]=Ut[ot]=Ut[ut]=Ut[ct]=Ut[lt]=Ut[ht]=Ut[dt]=Ut[ft]=!0,Ut[V]=Ut[H]=Ut[it]=Ut[z]=Ut[q]=Ut[X]=Ut[Z]=Ut[K]=Ut[Q]=Ut[J]=Ut[tt]=Ut[et]=Ut[nt]=Ut[rt]=!1;var Gt={};Gt[V]=Gt[H]=Gt[it]=Gt[z]=Gt[q]=Gt[st]=Gt[at]=Gt[ot]=Gt[ut]=Gt[ct]=Gt[Q]=Gt[J]=Gt[tt]=Gt[nt]=Gt[lt]=Gt[ht]=Gt[dt]=Gt[ft]=!0,Gt[X]=Gt[Z]=Gt[K]=Gt[et]=Gt[rt]=!1;var Wt={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss"},Vt={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},Ht={"&":"&","<":"<",">":">",""":'"',"'":"'","`":"`"},zt={"function":!0,object:!0},qt={0:"x30",1:"x31",2:"x32",3:"x33",4:"x34",5:"x35",6:"x36",7:"x37",8:"x38",9:"x39",A:"x41",B:"x42",C:"x43",D:"x44",E:"x45",F:"x46",a:"x61",b:"x62",c:"x63",d:"x64",e:"x65",f:"x66",n:"x6e",r:"x72",t:"x74",u:"x75",v:"x76",x:"x78"},Xt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Zt=zt[typeof n]&&n&&!n.nodeType&&n,Kt=zt[typeof e]&&e&&!e.nodeType&&e,Qt=Zt&&Kt&&"object"==typeof t&&t&&t.Object&&t,Jt=zt[typeof self]&&self&&self.Object&&self,te=zt[typeof window]&&window&&window.Object&&window,ee=Kt&&Kt.exports===Zt&&Zt,ne=Qt||te!==(this&&this.window)&&te||Jt||this,re=k();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(ne._=re,define(function(){return re})):Zt&&Kt?ee?(Kt.exports=re)._=re:Zt._=re:ne._=re}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],53:[function(t,e){e.exports={graphlib:t("./lib/graphlib"),layout:t("./lib/layout"),debug:t("./lib/debug"),util:{time:t("./lib/util").time,notime:t("./lib/util").notime},version:t("./lib/version")}},{"./lib/debug":58,"./lib/graphlib":59,"./lib/layout":61,"./lib/util":81,"./lib/version":82}],54:[function(t,e){"use strict";function n(t){function e(t){return function(e){return t.edge(e).weight}}var n="greedy"===t.graph().acyclicer?a(t,e(t)):r(t);s.each(n,function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,s.uniqueId("rev"))})}function r(t){function e(a){s.has(i,a)||(i[a]=!0,r[a]=!0,s.each(t.outEdges(a),function(t){s.has(r,t.w)?n.push(t):e(t.w)}),delete r[a])}var n=[],r={},i={};return s.each(t.nodes(),e),n}function i(t){s.each(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)}})}var s=t("./lodash"),a=t("./greedy-fas");e.exports={run:n,undo:i}},{"./greedy-fas":60,"./lodash":62}],55:[function(t,e){function n(t){function e(n){var s=t.children(n),a=t.node(n);if(s.length&&i.each(s,e),i.has(a,"minRank")){a.borderLeft=[],a.borderRight=[];for(var o=a.minRank,u=a.maxRank+1;u>o;++o)r(t,"borderLeft","_bl",n,a,o),r(t,"borderRight","_br",n,a,o)}}i.each(t.children(),e)}function r(t,e,n,r,i,a){var o={width:0,height:0,rank:a,borderType:e},u=i[e][a-1],c=s.addDummyNode(t,"border",o,n);i[e][a]=c,t.setParent(c,r),u&&t.setEdge(u,c,{weight:1})}var i=t("./lodash"),s=t("./util");e.exports=n},{"./lodash":62,"./util":81}],56:[function(t,e){"use strict";function n(t){var e=t.graph().rankdir.toLowerCase();("lr"===e||"rl"===e)&&i(t)}function r(t){var e=t.graph().rankdir.toLowerCase();("bt"===e||"rl"===e)&&a(t),("lr"===e||"rl"===e)&&(u(t),i(t))}function i(t){l.each(t.nodes(),function(e){s(t.node(e))}),l.each(t.edges(),function(e){s(t.edge(e))})}function s(t){var e=t.width;t.width=t.height,t.height=e}function a(t){l.each(t.nodes(),function(e){o(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,o),l.has(n,"y")&&o(n)})}function o(t){t.y=-t.y}function u(t){l.each(t.nodes(),function(e){c(t.node(e))}),l.each(t.edges(),function(e){var n=t.edge(e);l.each(n.points,c),l.has(n,"x")&&c(n)})}function c(t){var e=t.x;t.x=t.y,t.y=e}var l=t("./lodash");e.exports={adjust:n,undo:r}},{"./lodash":62}],57:[function(t,e){function n(){var t={};t._next=t._prev=t,this._sentinel=t}function r(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function i(t,e){return"_next"!==t&&"_prev"!==t?e:void 0}e.exports=n,n.prototype.dequeue=function(){var t=this._sentinel,e=t._prev;return e!==t?(r(e),e):void 0},n.prototype.enqueue=function(t){var e=this._sentinel;t._prev&&t._next&&r(t),t._next=e._next,e._next._prev=t,e._next=t,t._prev=e},n.prototype.toString=function(){for(var t=[],e=this._sentinel,n=e._prev;n!==e;)t.push(JSON.stringify(n,i)),n=n._prev;return"["+t.join(", ")+"]"}},{}],58:[function(t,e){function n(t){var e=i.buildLayerMatrix(t),n=new s({compound:!0,multigraph:!0}).setGraph({});return r.each(t.nodes(),function(e){n.setNode(e,{label:e}),n.setParent(e,"layer"+t.node(e).rank)}),r.each(t.edges(),function(t){n.setEdge(t.v,t.w,{},t.name)}),r.each(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}var r=t("./lodash"),i=t("./util"),s=t("./graphlib").Graph;e.exports={debugOrdering:n}},{"./graphlib":59,"./lodash":62,"./util":81}],59:[function(t,e){var n;if("function"==typeof t)try{n=t("graphlib")}catch(r){}n||(n=window.graphlib),e.exports=n},{graphlib:83}],60:[function(t,e){function n(t,e){if(t.nodeCount()<=1)return[];var n=s(t,e||l),i=r(n.graph,n.buckets,n.zeroIdx);return o.flatten(o.map(i,function(e){return t.outEdges(e.v,e.w)}),!0)}function r(t,e,n){for(var r,s=[],a=e[e.length-1],o=e[0];t.nodeCount();){for(;r=o.dequeue();)i(t,e,n,r);for(;r=a.dequeue();)i(t,e,n,r);if(t.nodeCount())for(var u=e.length-2;u>0;--u)if(r=e[u].dequeue()){s=s.concat(i(t,e,n,r,!0));break}}return s}function i(t,e,n,r,i){var s=i?[]:void 0;return o.each(t.inEdges(r.v),function(r){var o=t.edge(r),u=t.node(r.v);i&&s.push({v:r.v,w:r.w}),u.out-=o,a(e,n,u)}),o.each(t.outEdges(r.v),function(r){var i=t.edge(r),s=r.w,o=t.node(s);o["in"]-=i,a(e,n,o)}),t.removeNode(r.v),s}function s(t,e){var n=new u,r=0,i=0;o.each(t.nodes(),function(t){n.setNode(t,{v:t,"in":0,out:0})}),o.each(t.edges(),function(t){var s=n.edge(t.v,t.w)||0,a=e(t),o=s+a;n.setEdge(t.v,t.w,o),i=Math.max(i,n.node(t.v).out+=a),r=Math.max(r,n.node(t.w)["in"]+=a)});var s=o.range(i+r+3).map(function(){return new c}),l=r+1;return o.each(n.nodes(),function(t){a(s,l,n.node(t))}),{graph:n,buckets:s,zeroIdx:l}}function a(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)}var o=t("./lodash"),u=t("./graphlib").Graph,c=t("./data/list");e.exports=n;var l=o.constant(1)},{"./data/list":57,"./graphlib":59,"./lodash":62}],61:[function(t,e){"use strict";function n(t,e){var n=e&&e.debugTiming?O.time:O.notime;n("layout",function(){var e=n(" buildLayoutGraph",function(){return s(t)});n(" runLayout",function(){r(e,n)}),n(" updateInputGraph",function(){i(t,e)})})}function r(t,e){e(" makeSpaceForEdgeLabels",function(){a(t)}),e(" removeSelfEdges",function(){g(t)}),e(" acyclic",function(){A.run(t)}),e(" nestingGraph.run",function(){F.run(t)}),e(" rank",function(){w(O.asNonCompoundGraph(t))}),e(" injectEdgeLabelProxies",function(){o(t)}),e(" removeEmptyRanks",function(){D(t)}),e(" nestingGraph.cleanup",function(){F.cleanup(t)}),e(" normalizeRanks",function(){k(t)}),e(" assignRankMinMax",function(){u(t)}),e(" removeEdgeLabelProxies",function(){c(t)}),e(" normalize.run",function(){x.run(t)}),e(" parentDummyChains",function(){E(t)}),e(" addBorderSegments",function(){C(t)}),e(" order",function(){S(t)}),e(" insertSelfEdges",function(){y(t)}),e(" adjustCoordinateSystem",function(){T.adjust(t)}),e(" position",function(){B(t)}),e(" positionSelfEdges",function(){m(t)}),e(" removeBorderNodes",function(){p(t)}),e(" normalize.undo",function(){x.undo(t)}),e(" fixupEdgeLabelCoords",function(){d(t)}),e(" undoCoordinateSystem",function(){T.undo(t)}),e(" translateGraph",function(){l(t)}),e(" assignNodeIntersects",function(){h(t)}),e(" reversePoints",function(){f(t)}),e(" acyclic.undo",function(){A.undo(t)})}function i(t,e){b.each(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))}),b.each(t.edges(),function(n){var r=t.edge(n),i=e.edge(n);r.points=i.points,b.has(i,"x")&&(r.x=i.x,r.y=i.y)}),t.graph().width=e.graph().width,t.graph().height=e.graph().height}function s(t){var e=new I({multigraph:!0,compound:!0}),n=_(t.graph());return e.setGraph(b.merge({},M,v(n,L),b.pick(n,N))),b.each(t.nodes(),function(n){var r=_(t.node(n));e.setNode(n,b.defaults(v(r,P),R)),e.setParent(n,t.parent(n))}),b.each(t.edges(),function(n){var r=_(t.edge(n));e.setEdge(n,b.merge({},Y,v(r,j),b.pick(r,$)))}),e}function a(t){var e=t.graph();e.ranksep/=2,b.each(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)})}function o(t){b.each(t.edges(),function(e){var n=t.edge(e);if(n.width&&n.height){var r=t.node(e.v),i=t.node(e.w),s={rank:(i.rank-r.rank)/2+r.rank,e:e};O.addDummyNode(t,"edge-proxy",s,"_ep")}})}function u(t){var e=0;b.each(t.nodes(),function(n){var r=t.node(n);r.borderTop&&(r.minRank=t.node(r.borderTop).rank,r.maxRank=t.node(r.borderBottom).rank,e=b.max(e,r.maxRank))}),t.graph().maxRank=e}function c(t){b.each(t.nodes(),function(e){var n=t.node(e);"edge-proxy"===n.dummy&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))})}function l(t){function e(t){var e=t.x,a=t.y,o=t.width,u=t.height;n=Math.min(n,e-o/2),r=Math.max(r,e+o/2),i=Math.min(i,a-u/2),s=Math.max(s,a+u/2)}var n=Number.POSITIVE_INFINITY,r=0,i=Number.POSITIVE_INFINITY,s=0,a=t.graph(),o=a.marginx||0,u=a.marginy||0;b.each(t.nodes(),function(n){e(t.node(n))}),b.each(t.edges(),function(n){var r=t.edge(n);b.has(r,"x")&&e(r)}),n-=o,i-=u,b.each(t.nodes(),function(e){var r=t.node(e);r.x-=n,r.y-=i}),b.each(t.edges(),function(e){var r=t.edge(e);b.each(r.points,function(t){t.x-=n,t.y-=i}),b.has(r,"x")&&(r.x-=n),b.has(r,"y")&&(r.y-=i)}),a.width=r-n+o,a.height=s-i+u}function h(t){b.each(t.edges(),function(e){var n,r,i=t.edge(e),s=t.node(e.v),a=t.node(e.w);i.points?(n=i.points[0],r=i.points[i.points.length-1]):(i.points=[],n=a,r=s),i.points.unshift(O.intersectRect(s,n)),i.points.push(O.intersectRect(a,r))})}function d(t){b.each(t.edges(),function(e){var n=t.edge(e);if(b.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}})}function f(t){b.each(t.edges(),function(e){var n=t.edge(e);n.reversed&&n.points.reverse()})}function p(t){b.each(t.nodes(),function(e){if(t.children(e).length){var n=t.node(e),r=t.node(n.borderTop),i=t.node(n.borderBottom),s=t.node(b.last(n.borderLeft)),a=t.node(b.last(n.borderRight));n.width=Math.abs(a.x-s.x),n.height=Math.abs(i.y-r.y),n.x=s.x+n.width/2,n.y=r.y+n.height/2}}),b.each(t.nodes(),function(e){"border"===t.node(e).dummy&&t.removeNode(e)})}function g(t){b.each(t.edges(),function(e){if(e.v===e.w){var n=t.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e:e,label:t.edge(e)}),t.removeEdge(e)}})}function y(t){var e=O.buildLayerMatrix(t);b.each(e,function(e){var n=0;b.each(e,function(e,r){var i=t.node(e);i.order=r+n,b.each(i.selfEdges,function(e){O.addDummyNode(t,"selfedge",{width:e.label.width,height:e.label.height,rank:i.rank,order:r+ ++n,e:e.e,label:e.label},"_se")}),delete i.selfEdges})})}function m(t){b.each(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,s=r.y,a=n.x-i,o=r.height/2;t.setEdge(n.e,n.label),t.removeNode(e),n.label.points=[{x:i+2*a/3,y:s-o},{x:i+5*a/6,y:s-o},{x:i+a,y:s},{x:i+5*a/6,y:s+o},{x:i+2*a/3,y:s+o}],n.label.x=n.x,n.label.y=n.y}})}function v(t,e){return b.mapValues(b.pick(t,e),Number)}function _(t){var e={};return b.each(t,function(t,n){e[n.toLowerCase()]=t}),e}var b=t("./lodash"),A=t("./acyclic"),x=t("./normalize"),w=t("./rank"),k=t("./util").normalizeRanks,E=t("./parent-dummy-chains"),D=t("./util").removeEmptyRanks,F=t("./nesting-graph"),C=t("./add-border-segments"),T=t("./coordinate-system"),S=t("./order"),B=t("./position"),O=t("./util"),I=t("./graphlib").Graph;e.exports=n;var L=["nodesep","edgesep","ranksep","marginx","marginy"],M={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},N=["acyclicer","ranker","rankdir","align"],P=["width","height"],R={width:0,height:0},j=["minlen","weight","width","height","labeloffset"],Y={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},$=["labelpos"]},{"./acyclic":54,"./add-border-segments":55,"./coordinate-system":56,"./graphlib":59,"./lodash":62,"./nesting-graph":63,"./normalize":64,"./order":69,"./parent-dummy-chains":74,"./position":76,"./rank":78,"./util":81}],62:[function(t,e){e.exports=t(50)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":50,lodash:103}],63:[function(t,e){function n(t){var e=u.addDummyNode(t,"root",{},"_root"),n=i(t),a=o.max(n)-1,c=2*a+1;t.graph().nestingRoot=e,o.each(t.edges(),function(e){t.edge(e).minlen*=c});var l=s(t)+1;o.each(t.children(),function(i){r(t,e,c,l,a,n,i)}),t.graph().nodeRankFactor=c}function r(t,e,n,i,s,a,c){var l=t.children(c);if(!l.length)return void(c!==e&&t.setEdge(e,c,{ +weight:0,minlen:n}));var h=u.addBorderNode(t,"_bt"),d=u.addBorderNode(t,"_bb"),f=t.node(c);t.setParent(h,c),f.borderTop=h,t.setParent(d,c),f.borderBottom=d,o.each(l,function(o){r(t,e,n,i,s,a,o);var u=t.node(o),l=u.borderTop?u.borderTop:o,f=u.borderBottom?u.borderBottom:o,p=u.borderTop?i:2*i,g=l!==f?1:s-a[c]+1;t.setEdge(h,l,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(f,d,{weight:p,minlen:g,nestingEdge:!0})}),t.parent(c)||t.setEdge(e,h,{weight:0,minlen:s+a[c]})}function i(t){function e(r,i){var s=t.children(r);s&&s.length&&o.each(s,function(t){e(t,i+1)}),n[r]=i}var n={};return o.each(t.children(),function(t){e(t,1)}),n}function s(t){return o.reduce(t.edges(),function(e,n){return e+t.edge(n).weight},0)}function a(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,o.each(t.edges(),function(e){var n=t.edge(e);n.nestingEdge&&t.removeEdge(e)})}var o=t("./lodash"),u=t("./util");e.exports={run:n,cleanup:a}},{"./lodash":62,"./util":81}],64:[function(t,e){"use strict";function n(t){t.graph().dummyChains=[],s.each(t.edges(),function(e){r(t,e)})}function r(t,e){var n=e.v,r=t.node(n).rank,i=e.w,s=t.node(i).rank,o=e.name,u=t.edge(e),c=u.labelRank;if(s!==r+1){t.removeEdge(e);var l,h,d;for(d=0,++r;s>r;++d,++r)u.points=[],h={width:0,height:0,edgeLabel:u,edgeObj:e,rank:r},l=a.addDummyNode(t,"edge",h,"_d"),r===c&&(h.width=u.width,h.height=u.height,h.dummy="edge-label",h.labelpos=u.labelpos),t.setEdge(n,l,{weight:u.weight},o),0===d&&t.graph().dummyChains.push(l),n=l;t.setEdge(n,i,{weight:u.weight},o)}}function i(t){s.each(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)})}var s=t("./lodash"),a=t("./util");e.exports={run:n,undo:i}},{"./lodash":62,"./util":81}],65:[function(t,e){function n(t,e,n){var i,s={};r.each(n,function(n){for(var r,a,o=t.parent(n);o;){if(r=t.parent(o),r?(a=s[r],s[r]=o):(a=i,i=o),a&&a!==o)return void e.setEdge(a,o);o=r}})}var r=t("../lodash");e.exports=n},{"../lodash":62}],66:[function(t,e){function n(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}})}var r=t("../lodash");e.exports=n},{"../lodash":62}],67:[function(t,e){function n(t,e,n){var a=r(t),o=new s({compound:!0}).setGraph({root:a}).setDefaultNodeLabel(function(e){return t.node(e)});return i.each(t.nodes(),function(r){var s=t.node(r),u=t.parent(r);(s.rank===e||s.minRank<=e&&e<=s.maxRank)&&(o.setNode(r),o.setParent(r,u||a),i.each(t[n](r),function(e){var n=e.v===r?e.w:e.v,s=o.edge(n,r),a=i.isUndefined(s)?0:s.weight;o.setEdge(n,r,{weight:t.edge(e).weight+a})}),i.has(s,"minRank")&&o.setNode(r,{borderLeft:s.borderLeft[e],borderRight:s.borderRight[e]}))}),o}function r(t){for(var e;t.hasNode(e=i.uniqueId("_root")););return e}var i=t("../lodash"),s=t("../graphlib").Graph;e.exports=n},{"../graphlib":59,"../lodash":62}],68:[function(t,e){"use strict";function n(t,e){for(var n=0,i=1;i0;)e%2&&(n+=u[e+1]),e=e-1>>1,u[e]+=t.weight;c+=t.weight*n})),c}var i=t("../lodash");e.exports=n},{"../lodash":62}],69:[function(t,e){"use strict";function n(t){var e=f.maxRank(t),n=r(t,a.range(1,e+1),"inEdges"),c=r(t,a.range(e-1,-1,-1),"outEdges"),l=o(t);s(t,l);for(var h,d=Number.POSITIVE_INFINITY,p=0,g=0;4>g;++p,++g){i(p%2?n:c,p%4>=2),l=f.buildLayerMatrix(t);var y=u(t,l);d>y&&(g=0,h=a.cloneDeep(l),d=y)}s(t,h)}function r(t,e,n){return a.map(e,function(e){return l(t,e,n)})}function i(t,e){var n=new d;a.each(t,function(t){var r=t.graph().root,i=c(t,r,n,e);a.each(i.vs,function(e,n){t.node(e).order=n}),h(t,n,i.vs)})}function s(t,e){a.each(e,function(e){a.each(e,function(e,n){t.node(e).order=n})})}var a=t("../lodash"),o=t("./init-order"),u=t("./cross-count"),c=t("./sort-subgraph"),l=t("./build-layer-graph"),h=t("./add-subgraph-constraints"),d=t("../graphlib").Graph,f=t("../util");e.exports=n},{"../graphlib":59,"../lodash":62,"../util":81,"./add-subgraph-constraints":65,"./build-layer-graph":67,"./cross-count":68,"./init-order":70,"./sort-subgraph":72}],70:[function(t,e){"use strict";function n(t){function e(i){if(!r.has(n,i)){n[i]=!0;var s=t.node(i);a[s.rank].push(i),r.each(t.successors(i),e)}}var n={},i=r.filter(t.nodes(),function(e){return!t.children(e).length}),s=r.max(r.map(i,function(e){return t.node(e).rank})),a=r.map(r.range(s+1),function(){return[]}),o=r.sortBy(i,function(e){return t.node(e).rank});return r.each(o,e),a}var r=t("../lodash");e.exports=n},{"../lodash":62}],71:[function(t,e){"use strict";function n(t,e){var n={};s.each(t,function(t,e){var r=n[t.v]={indegree:0,"in":[],out:[],vs:[t.v],i:e};s.isUndefined(t.barycenter)||(r.barycenter=t.barycenter,r.weight=t.weight)}),s.each(e.edges(),function(t){var e=n[t.v],r=n[t.w];s.isUndefined(e)||s.isUndefined(r)||(r.indegree++,e.out.push(n[t.w]))});var i=s.filter(n,function(t){return!t.indegree});return r(i)}function r(t){function e(t){return function(e){e.merged||(s.isUndefined(e.barycenter)||s.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 a=t.pop();r.push(a),s.each(a["in"].reverse(),e(a)),s.each(a.out,n(a))}return s.chain(r).filter(function(t){return!t.merged}).map(function(t){return s.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 s=t("../lodash");e.exports=n},{"../lodash":62}],72:[function(t,e){function n(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=s.filter(h,function(t){return t!==f&&t!==p}));var y=a(t,h);s.each(y,function(e){if(t.children(e.v).length){var r=n(t,e.v,c,l);g[e.v]=r,s.has(r,"barycenter")&&i(e,r)}});var m=o(y,c);r(m,g);var v=u(m,l);if(f&&(v.vs=s.flatten([f,v.vs,p],!0),t.predecessors(f).length)){var _=t.node(t.predecessors(f)[0]),b=t.node(t.predecessors(p)[0]);s.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){s.each(t,function(t){t.vs=s.flatten(t.vs.map(function(t){return e[t]?e[t].vs:t}),!0)})}function i(t,e){s.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 s=t("../lodash"),a=t("./barycenter"),o=t("./resolve-conflicts"),u=t("./sort");e.exports=n},{"../lodash":62,"./barycenter":66,"./resolve-conflicts":71,"./sort":73}],73:[function(t,e){function n(t,e){var n=a.partition(t,function(t){return s.has(t,"barycenter")}),o=n.lhs,u=s.sortBy(n.rhs,function(t){return-t.i}),c=[],l=0,h=0,d=0;o.sort(i(!!e)),d=r(c,u,d),s.each(o,function(t){d+=t.vs.length,c.push(t.vs),l+=t.barycenter*t.weight,h+=t.weight,d=r(c,u,d)});var f={vs:s.flatten(c,!0)};return h&&(f.barycenter=l/h,f.weight=h),f}function r(t,e,n){for(var r;e.length&&(r=s.last(e)).i<=n;)e.pop(),t.push(r.vs),n++;return n}function i(t){return function(e,n){return e.barycentern.barycenter?1:t?n.i-e.i:e.i-n.i}}var s=t("../lodash"),a=t("../util");e.exports=n},{"../lodash":62,"../util":81}],74:[function(t,e){function n(t){var e=i(t);s.each(t.graph().dummyChains,function(n){for(var i=t.node(n),s=i.edgeObj,a=r(t,e,s.v,s.w),o=a.path,u=a.lca,c=0,l=o[c],h=!0;n!==s.w;){if(i=t.node(n),h){for(;(l=o[c])!==u&&t.node(l).maxRanku||c>e[i].lim));for(s=i,i=r;(i=t.parent(i))!==s;)o.push(i);return{path:a.concat(o.reverse()),lca:s}}function i(t){function e(i){var a=r;s.each(t.children(i),e),n[i]={low:a,lim:r++}}var n={},r=0;return s.each(t.children(),e),n}var s=t("./lodash");e.exports=n},{"./lodash":62}],75:[function(t,e){"use strict";function n(t,e){function n(e,n){var a=0,o=0,u=e.length,c=y.last(n);return y.each(n,function(e,l){var h=i(t,e),d=h?t.node(h).order:u;(h||e===c)&&(y.each(n.slice(o,l+1),function(e){y.each(t.predecessors(e),function(n){var i=t.node(n),o=i.order;!(a>o||o>d)||i.dummy&&t.node(e).dummy||s(r,n,e)})}),o=l+1,a=d)}),n}var r={};return y.reduce(e,n),r}function r(t,e){function n(e,n,r,a,o){var u;y.each(y.range(n,r),function(n){u=e[n],t.node(u).dummy&&y.each(t.predecessors(u),function(e){var n=t.node(e);n.dummy&&(n.ordero)&&s(i,e,u)})})}function r(e,r){var i,s=-1,a=0;return y.each(r,function(o,u){if("border"===t.node(o).dummy){var c=t.predecessors(o);c.length&&(i=t.node(c[0]).order,n(r,a,u,s,i),a=u,s=i)}n(r,a,r.length,i,e.length)}),r}var i={};return y.reduce(e,r),i}function i(t,e){return t.node(e).dummy?y.find(t.predecessors(e),function(e){return t.node(e).dummy}):void 0}function s(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 a(t,e,n){if(e>n){var r=e;e=n,n=r}return y.has(t[e],n)}function o(t,e,n,r){var i={},s={},o={};return y.each(e,function(t){y.each(t,function(t,e){i[t]=t,s[t]=t,o[t]=e})}),y.each(e,function(t){var e=-1;y.each(t,function(t){var u=r(t);if(u.length){u=y.sortBy(u,function(t){return o[t]});for(var c=(u.length-1)/2,l=Math.floor(c),h=Math.ceil(c);h>=l;++l){var d=u[l];s[t]===t&&ea.lim&&(o=a,u=!0);var c=p.filter(e.edges(),function(e){return u===f(t,t.node(e.v),o)&&u!==f(t,t.node(e.w),o)});return p.min(c,function(t){return y(e,t)})}function l(t,e,n,i){var s=n.v,o=n.w;t.removeEdge(s,o),t.setEdge(i.v,i.w,{}),a(t),r(t,e),h(t,e)}function h(t,e){var n=p.find(t.nodes(),function(t){return!e.node(t).parent}),r=v(t,n);r=r.slice(1),p.each(r,function(n){var r=t.node(n).parent,i=e.edge(n,r),s=!1;i||(i=e.edge(r,n),s=!0),e.node(n).rank=e.node(r).rank+(s?i.minlen:-i.minlen)})}function d(t,e,n){return t.hasEdge(e,n)}function f(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}var p=t("../lodash"),g=t("./feasible-tree"),y=t("./util").slack,m=t("./util").longestPath,v=t("../graphlib").alg.preorder,_=t("../graphlib").alg.postorder,b=t("../util").simplify;e.exports=n,n.initLowLimValues=a,n.initCutValues=r,n.calcCutValue=s,n.leaveEdge=u,n.enterEdge=c,n.exchangeEdges=l},{"../graphlib":59,"../lodash":62,"../util":81,"./feasible-tree":77,"./util":80}],80:[function(t,e){"use strict";function n(t){function e(r){var s=t.node(r);if(i.has(n,r))return s.rank;n[r]=!0;var a=i.min(i.map(t.outEdges(r),function(n){return e(n.w)-t.edge(n).minlen}));return a===Number.POSITIVE_INFINITY&&(a=0),s.rank=a}var n={};i.each(t.sources(),e)}function r(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}var i=t("../lodash");e.exports={longestPath:n,slack:r}},{"../lodash":62}],81:[function(t,e){"use strict";function n(t,e,n,r){var i;do i=y.uniqueId(r);while(t.hasNode(i));return n.dummy=e,t.setNode(i,n),i}function r(t){var e=(new m).setGraph(t.graph());return y.each(t.nodes(),function(n){e.setNode(n,t.node(n))}),y.each(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}function i(t){var e=new m({multigraph:t.isMultigraph()}).setGraph(t.graph());return y.each(t.nodes(),function(n){t.children(n).length||e.setNode(n,t.node(n))}),y.each(t.edges(),function(n){e.setEdge(n,t.edge(n))}),e}function s(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.outEdges(e),function(e){n[e.w]=(n[e.w]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function a(t){var e=y.map(t.nodes(),function(e){var n={};return y.each(t.inEdges(e),function(e){n[e.v]=(n[e.v]||0)+t.edge(e).weight}),n});return y.zipObject(t.nodes(),e)}function o(t,e){var n=t.x,r=t.y,i=e.x-n,s=e.y-r,a=t.width/2,o=t.height/2;if(!i&&!s)throw new Error("Not possible to find intersection inside of the rectangle");var u,c;return Math.abs(s)*a>Math.abs(i)*o?(0>s&&(o=-o),u=o*i/s,c=o):(0>i&&(a=-a),u=a,c=a*s/i),{x:n+u,y:r+c}}function u(t){var e=y.map(y.range(d(t)+1),function(){return[]});return y.each(t.nodes(),function(n){var r=t.node(n),i=r.rank;y.isUndefined(i)||(e[i][r.order]=n)}),e}function c(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank}));y.each(t.nodes(),function(n){var r=t.node(n);y.has(r,"rank")&&(r.rank-=e)})}function l(t){var e=y.min(y.map(t.nodes(),function(e){return t.node(e).rank})),n=[];y.each(t.nodes(),function(r){var i=t.node(r).rank-e;n[i]||(n[i]=[]),n[i].push(r)});var r=0,i=t.graph().nodeRankFactor;y.each(n,function(e,n){y.isUndefined(e)&&n%i!==0?--r:r&&y.each(e,function(e){t.node(e).rank+=r})})}function h(t,e,r,i){var s={width:0,height:0};return arguments.length>=4&&(s.rank=r,s.order=i),n(t,"border",s,e)}function d(t){return y.max(y.map(t.nodes(),function(e){var n=t.node(e).rank;return y.isUndefined(n)?void 0:n}))}function f(t,e){var n={lhs:[],rhs:[]};return y.each(t,function(t){e(t)?n.lhs.push(t):n.rhs.push(t)}),n}function p(t,e){var n=y.now();try{return e()}finally{console.log(t+" time: "+(y.now()-n)+"ms")}}function g(t,e){return e()}var y=t("./lodash"),m=t("./graphlib").Graph;e.exports={addDummyNode:n,simplify:r,asNonCompoundGraph:i,successorWeights:s,predecessorWeights:a,intersectRect:o,buildLayerMatrix:u,normalizeRanks:c,removeEmptyRanks:l,addBorderNode:h,maxRank:d,partition:f,time:p,notime:g}},{"./graphlib":59,"./lodash":62}],82:[function(t,e){e.exports="0.7.4"},{}],83:[function(t,e){e.exports=t(32)},{"./lib":99,"./lib/alg":90,"./lib/json":100,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/index.js":32}],84:[function(t,e){e.exports=t(33)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/components.js":33}],85:[function(t,e){e.exports=t(34)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dfs.js":34}],86:[function(t,e){e.exports=t(35)},{"../lodash":101,"./dijkstra":87,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra-all.js":35}],87:[function(t,e){e.exports=t(36)},{"../data/priority-queue":97,"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/dijkstra.js":36}],88:[function(t,e){e.exports=t(37)},{"../lodash":101,"./tarjan":95,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/find-cycles.js":37}],89:[function(t,e){e.exports=t(38)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/floyd-warshall.js":38}],90:[function(t,e){e.exports=t(39)},{"./components":84,"./dijkstra":87,"./dijkstra-all":86,"./find-cycles":88,"./floyd-warshall":89,"./is-acyclic":91,"./postorder":92,"./preorder":93,"./prim":94,"./tarjan":95,"./topsort":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/index.js":39}],91:[function(t,e){e.exports=t(40)},{"./topsort":96,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/is-acyclic.js":40}],92:[function(t,e){e.exports=t(41)},{"./dfs":85,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/postorder.js":41}],93:[function(t,e){e.exports=t(42)},{"./dfs":85,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/preorder.js":42}],94:[function(t,e){e.exports=t(43)},{"../data/priority-queue":97,"../graph":98,"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/prim.js":43}],95:[function(t,e){e.exports=t(44)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/tarjan.js":44}],96:[function(t,e){e.exports=t(45)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/alg/topsort.js":45}],97:[function(t,e){e.exports=t(46)},{"../lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/data/priority-queue.js":46}],98:[function(t,e){e.exports=t(47)},{"./lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/graph.js":47}],99:[function(t,e){e.exports=t(48)},{"./graph":98,"./version":102,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/index.js":48}],100:[function(t,e){e.exports=t(49)},{"./graph":98,"./lodash":101,"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/json.js":49}],101:[function(t,e){e.exports=t(50)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/lodash.js":50,lodash:103}],102:[function(t,e){e.exports=t(51)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/graphlib/lib/version.js":51}],103:[function(t,e){e.exports=t(52)},{"/Users/knut/Documents/source/mermaid/node_modules/dagre-d3/node_modules/lodash/index.js":52}],104:[function(t,e,n){!function(t,r){"object"==typeof n&&"undefined"!=typeof e?e.exports=r():"function"==typeof define&&define.amd?define(r):t.moment=r()}(this,function(){"use strict";function n(){return Nn.apply(null,arguments)}function r(t){Nn=t}function i(t){return"[object Array]"===Object.prototype.toString.call(t)}function s(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function a(t,e){var n,r=[];for(n=0;n0)for(n in Rn)r=Rn[n],i=e[r],"undefined"!=typeof i&&(t[r]=i);return t}function g(t){p(this,t),this._d=new Date(null!=t._d?t._d.getTime():0/0),jn===!1&&(jn=!0,n.updateOffset(this),jn=!1)}function y(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function m(t){return 0>t?Math.ceil(t):Math.floor(t)}function v(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=m(e)),n}function _(t,e,n){var r,i=Math.min(t.length,e.length),s=Math.abs(t.length-e.length),a=0;for(r=0;i>r;r++)(n&&t[r]!==e[r]||!n&&v(t[r])!==v(e[r]))&&a++;return a+s}function b(){}function A(t){return t?t.toLowerCase().replace("_","-"):t}function x(t){for(var e,n,r,i,s=0;s0;){if(r=w(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&_(i,n,!0)>=e-1)break;e--}s++}return null}function w(n){var r=null;if(!Yn[n]&&"undefined"!=typeof e&&e&&e.exports)try{r=Pn._abbr,t("./locale/"+n),k(r)}catch(i){}return Yn[n]}function k(t,e){var n;return t&&(n="undefined"==typeof e?D(t):E(t,e),n&&(Pn=n)),Pn._abbr}function E(t,e){return null!==e?(e.abbr=t,Yn[t]=Yn[t]||new b,Yn[t].set(e),k(t),Yn[t]):(delete Yn[t],null)}function D(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Pn;if(!i(t)){if(e=w(t))return e;t=[t]}return x(t)}function F(t,e){var n=t.toLowerCase();$n[n]=$n[n+"s"]=$n[e]=t}function C(t){return"string"==typeof t?$n[t]||$n[t.toLowerCase()]:void 0}function T(t){var e,n,r={};for(n in t)o(t,n)&&(e=C(n),e&&(r[e]=t[n]));return r}function S(t,e){return function(r){return null!=r?(O(this,t,r),n.updateOffset(this,e),this):B(this,t)}}function B(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function O(t,e,n){return t._d["set"+(t._isUTC?"UTC":"")+e](n)}function I(t,e){var n;if("object"==typeof t)for(n in t)this.set(n,t[n]);else if(t=C(t),"function"==typeof this[t])return this[t](e);return this}function L(t,e,n){var r=""+Math.abs(t),i=e-r.length,s=t>=0;return(s?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}function M(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&(Vn[t]=i),e&&(Vn[e[0]]=function(){return L(i.apply(this,arguments),e[1],e[2])}),n&&(Vn[n]=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 P(t){var e,n,r=t.match(Un);for(e=0,n=r.length;n>e;e++)r[e]=Vn[r[e]]?Vn[r[e]]:N(r[e]);return function(i){var s="";for(e=0;n>e;e++)s+=r[e]instanceof Function?r[e].call(i,t):r[e];return s}}function R(t,e){return t.isValid()?(e=j(e,t.localeData()),Wn[e]=Wn[e]||P(e),Wn[e](t)):t.localeData().invalidDate()}function j(t,e){function n(t){return e.longDateFormat(t)||t}var r=5;for(Gn.lastIndex=0;r>=0&&Gn.test(t);)t=t.replace(Gn,n),Gn.lastIndex=0,r-=1;return t}function Y(t){return"function"==typeof t&&"[object Function]"===Object.prototype.toString.call(t)}function $(t,e,n){ar[t]=Y(e)?e:function(t){return t&&n?n:e}}function U(t,e){return o(ar,t)?ar[t](e._strict,e._locale):new RegExp(G(t))}function G(t){return t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,n,r,i){return e||n||r||i}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function W(t,e){var n,r=e;for("string"==typeof t&&(t=[t]),"number"==typeof e&&(r=function(t,n){n[e]=v(t)}),n=0;nr;r++){if(i=c([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(s="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(s.replace(".",""),"i")),n&&"MMMM"===e&&this._longMonthsParse[r].test(t))return r;if(n&&"MMM"===e&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}}function K(t,e){var n;return"string"==typeof e&&(e=t.localeData().monthsParse(e),"number"!=typeof e)?t:(n=Math.min(t.date(),z(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n),t)}function Q(t){return null!=t?(K(this,t),n.updateOffset(this,!0),this):B(this,"Month")}function J(){return z(this.year(),this.month())}function tt(t){var e,n=t._a;return n&&-2===h(t).overflow&&(e=n[cr]<0||n[cr]>11?cr:n[lr]<1||n[lr]>z(n[ur],n[cr])?lr:n[hr]<0||n[hr]>24||24===n[hr]&&(0!==n[dr]||0!==n[fr]||0!==n[pr])?hr:n[dr]<0||n[dr]>59?dr:n[fr]<0||n[fr]>59?fr:n[pr]<0||n[pr]>999?pr:-1,h(t)._overflowDayOfYear&&(ur>e||e>lr)&&(e=lr),h(t).overflow=e),t}function et(t){n.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function nt(t,e){var n=!0;return u(function(){return n&&(et(t+"\n"+(new Error).stack),n=!1),e.apply(this,arguments)},e)}function rt(t,e){mr[t]||(et(e),mr[t]=!0)}function it(t){var e,n,r=t._i,i=vr.exec(r);if(i){for(h(t).iso=!0,e=0,n=_r.length;n>e;e++)if(_r[e][1].exec(r)){t._f=_r[e][0];break}for(e=0,n=br.length;n>e;e++)if(br[e][1].exec(r)){t._f+=(i[6]||" ")+br[e][0];break}r.match(rr)&&(t._f+="Z"),wt(t)}else t._isValid=!1}function st(t){var e=Ar.exec(t._i);return null!==e?void(t._d=new Date(+e[1])):(it(t),void(t._isValid===!1&&(delete t._isValid,n.createFromInputFallback(t))))}function at(t,e,n,r,i,s,a){var o=new Date(t,e,n,r,i,s,a);return 1970>t&&o.setFullYear(t),o}function ot(t){var e=new Date(Date.UTC.apply(null,arguments));return 1970>t&&e.setUTCFullYear(t),e}function ut(t){return ct(t)?366:365}function ct(t){return t%4===0&&t%100!==0||t%400===0}function lt(){return ct(this.year())}function ht(t,e,n){var r,i=n-e,s=n-t.day();return s>i&&(s-=7),i-7>s&&(s+=7),r=Bt(t).add(s,"d"),{week:Math.ceil(r.dayOfYear()/7),year:r.year()}}function dt(t){return ht(t,this._week.dow,this._week.doy).week}function ft(){return this._week.dow}function pt(){return this._week.doy}function gt(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")}function yt(t){var e=ht(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")}function mt(t,e,n,r,i){var s,a=6+i-r,o=ot(t,0,1+a),u=o.getUTCDay();return i>u&&(u+=7),n=null!=n?1*n:i,s=1+a+7*(e-1)-u+n,{year:s>0?t:t-1,dayOfYear:s>0?s:ut(t-1)+s}}function vt(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")}function _t(t,e,n){return null!=t?t:null!=e?e:n}function bt(t){var e=new Date;return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function At(t){var e,n,r,i,s=[];if(!t._d){for(r=bt(t),t._w&&null==t._a[lr]&&null==t._a[cr]&&xt(t),t._dayOfYear&&(i=_t(t._a[ur],r[ur]),t._dayOfYear>ut(i)&&(h(t)._overflowDayOfYear=!0),n=ot(i,0,t._dayOfYear),t._a[cr]=n.getUTCMonth(),t._a[lr]=n.getUTCDate()),e=0;3>e&&null==t._a[e];++e)t._a[e]=s[e]=r[e];for(;7>e;e++)t._a[e]=s[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[hr]&&0===t._a[dr]&&0===t._a[fr]&&0===t._a[pr]&&(t._nextDay=!0,t._a[hr]=0),t._d=(t._useUTC?ot:at).apply(null,s),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm), +t._nextDay&&(t._a[hr]=24)}}function xt(t){var e,n,r,i,s,a,o;e=t._w,null!=e.GG||null!=e.W||null!=e.E?(s=1,a=4,n=_t(e.GG,t._a[ur],ht(Bt(),1,4).year),r=_t(e.W,1),i=_t(e.E,1)):(s=t._locale._week.dow,a=t._locale._week.doy,n=_t(e.gg,t._a[ur],ht(Bt(),s,a).year),r=_t(e.w,1),null!=e.d?(i=e.d,s>i&&++r):i=null!=e.e?e.e+s:s),o=mt(n,r,i,a,s),t._a[ur]=o.year,t._dayOfYear=o.dayOfYear}function wt(t){if(t._f===n.ISO_8601)return void it(t);t._a=[],h(t).empty=!0;var e,r,i,s,a,o=""+t._i,u=o.length,c=0;for(i=j(t._f,t._locale).match(Un)||[],e=0;e0&&h(t).unusedInput.push(a),o=o.slice(o.indexOf(r)+r.length),c+=r.length),Vn[s]?(r?h(t).empty=!1:h(t).unusedTokens.push(s),H(s,r,t)):t._strict&&!r&&h(t).unusedTokens.push(s);h(t).charsLeftOver=u-c,o.length>0&&h(t).unusedInput.push(o),h(t).bigHour===!0&&t._a[hr]<=12&&t._a[hr]>0&&(h(t).bigHour=void 0),t._a[hr]=kt(t._locale,t._a[hr],t._meridiem),At(t),tt(t)}function kt(t,e,n){var r;return null==n?e:null!=t.meridiemHour?t.meridiemHour(e,n):null!=t.isPM?(r=t.isPM(n),r&&12>e&&(e+=12),r||12!==e||(e=0),e):e}function Et(t){var e,n,r,i,s;if(0===t._f.length)return h(t).invalidFormat=!0,void(t._d=new Date(0/0));for(i=0;is)&&(r=s,n=e));u(t,n||e)}function Dt(t){if(!t._d){var e=T(t._i);t._a=[e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],At(t)}}function Ft(t){var e=new g(tt(Ct(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=void 0),e}function Ct(t){var e=t._i,n=t._f;return t._locale=t._locale||D(t._l),null===e||void 0===n&&""===e?f({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),y(e)?new g(tt(e)):(i(n)?Et(t):n?wt(t):s(e)?t._d=e:Tt(t),t))}function Tt(t){var e=t._i;void 0===e?t._d=new Date:s(e)?t._d=new Date(+e):"string"==typeof e?st(t):i(e)?(t._a=a(e.slice(0),function(t){return parseInt(t,10)}),At(t)):"object"==typeof e?Dt(t):"number"==typeof e?t._d=new Date(e):n.createFromInputFallback(t)}function St(t,e,n,r,i){var s={};return"boolean"==typeof n&&(r=n,n=void 0),s._isAMomentObject=!0,s._useUTC=s._isUTC=i,s._l=n,s._i=t,s._f=e,s._strict=r,Ft(s)}function Bt(t,e,n,r){return St(t,e,n,r,!1)}function Ot(t,e){var n,r;if(1===e.length&&i(e[0])&&(e=e[0]),!e.length)return Bt();for(n=e[0],r=1;rt&&(t=-t,n="-"),n+L(~~(t/60),2)+e+L(~~t%60,2)})}function Rt(t){var e=(t||"").match(rr)||[],n=e[e.length-1]||[],r=(n+"").match(Dr)||["-",0,0],i=+(60*r[1])+v(r[2]);return"+"===r[0]?i:-i}function jt(t,e){var r,i;return e._isUTC?(r=e.clone(),i=(y(t)||s(t)?+t:+Bt(t))-+r,r._d.setTime(+r._d+i),n.updateOffset(r,!1),r):Bt(t).local()}function Yt(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function $t(t,e){var r,i=this._offset||0;return null!=t?("string"==typeof t&&(t=Rt(t)),Math.abs(t)<16&&(t=60*t),!this._isUTC&&e&&(r=Yt(this)),this._offset=t,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==t&&(!e||this._changeInProgress?re(this,Qt(t-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?i:Yt(this)}function Ut(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function Gt(t){return this.utcOffset(0,t)}function Wt(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(Yt(this),"m")),this}function Vt(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(Rt(this._i)),this}function Ht(t){return t=t?Bt(t).utcOffset():0,(this.utcOffset()-t)%60===0}function zt(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function qt(){if("undefined"!=typeof this._isDSTShifted)return this._isDSTShifted;var t={};if(p(t,this),t=Ct(t),t._a){var e=t._isUTC?c(t._a):Bt(t._a);this._isDSTShifted=this.isValid()&&_(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Xt(){return!this._isUTC}function Zt(){return this._isUTC}function Kt(){return this._isUTC&&0===this._offset}function Qt(t,e){var n,r,i,s=t,a=null;return Nt(t)?s={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(s={},e?s[e]=t:s.milliseconds=t):(a=Fr.exec(t))?(n="-"===a[1]?-1:1,s={y:0,d:v(a[lr])*n,h:v(a[hr])*n,m:v(a[dr])*n,s:v(a[fr])*n,ms:v(a[pr])*n}):(a=Cr.exec(t))?(n="-"===a[1]?-1:1,s={y:Jt(a[2],n),M:Jt(a[3],n),d:Jt(a[4],n),h:Jt(a[5],n),m:Jt(a[6],n),s:Jt(a[7],n),w:Jt(a[8],n)}):null==s?s={}:"object"==typeof s&&("from"in s||"to"in s)&&(i=ee(Bt(s.from),Bt(s.to)),s={},s.ms=i.milliseconds,s.M=i.months),r=new Mt(s),Nt(t)&&o(t,"_locale")&&(r._locale=t._locale),r}function Jt(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function te(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 ee(t,e){var n;return e=jt(e,t),t.isBefore(e)?n=te(t,e):(n=te(e,t),n.milliseconds=-n.milliseconds,n.months=-n.months),n}function ne(t,e){return function(n,r){var i,s;return null===r||isNaN(+r)||(rt(e,"moment()."+e+"(period, number) is deprecated. Please use moment()."+e+"(number, period)."),s=n,n=r,r=s),n="string"==typeof n?+n:n,i=Qt(n,r),re(this,i,t),this}}function re(t,e,r,i){var s=e._milliseconds,a=e._days,o=e._months;i=null==i?!0:i,s&&t._d.setTime(+t._d+s*r),a&&O(t,"Date",B(t,"Date")+a*r),o&&K(t,B(t,"Month")+o*r),i&&n.updateOffset(t,a||o)}function ie(t,e){var n=t||Bt(),r=jt(n,this).startOf("day"),i=this.diff(r,"days",!0),s=-6>i?"sameElse":-1>i?"lastWeek":0>i?"lastDay":1>i?"sameDay":2>i?"nextDay":7>i?"nextWeek":"sameElse";return this.format(e&&e[s]||this.localeData().calendar(s,this,Bt(n)))}function se(){return new g(this)}function ae(t,e){var n;return e=C("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Bt(t),+this>+t):(n=y(t)?+t:+Bt(t),n<+this.clone().startOf(e))}function oe(t,e){var n;return e=C("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Bt(t),+t>+this):(n=y(t)?+t:+Bt(t),+this.clone().endOf(e)e-s?(n=t.clone().add(i-1,"months"),r=(e-s)/(s-n)):(n=t.clone().add(i+1,"months"),r=(e-s)/(n-s)),-(i+r)}function de(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function fe(){var t=this.clone().utc();return 0e;e++)if(this._weekdaysParse[e]||(n=Bt([2e3,1]).day(e),r="^"+this.weekdays(n,"")+"|^"+this.weekdaysShort(n,"")+"|^"+this.weekdaysMin(n,""),this._weekdaysParse[e]=new RegExp(r.replace(".",""),"i")),this._weekdaysParse[e].test(t))return e}function Ge(t){var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=Re(t,this.localeData()),this.add(t-e,"d")):e}function We(t){var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")}function Ve(t){return null==t?this.day()||7:this.day(this.day()%7?t:t-7)}function He(t,e){M(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}function ze(t,e){return e._meridiemParse}function qe(t){return"p"===(t+"").toLowerCase().charAt(0)}function Xe(t,e,n){return t>11?n?"pm":"PM":n?"am":"AM"}function Ze(t,e){e[pr]=v(1e3*("0."+t))}function Ke(){return this._isUTC?"UTC":""}function Qe(){return this._isUTC?"Coordinated Universal Time":""}function Je(t){return Bt(1e3*t)}function tn(){return Bt.apply(null,arguments).parseZone()}function en(t,e,n){var r=this._calendar[t];return"function"==typeof r?r.call(e,n):r}function nn(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.replace(/MMMM|MM|DD|dddd/g,function(t){return t.slice(1)}),this._longDateFormat[t])}function rn(){return this._invalidDate}function sn(t){return this._ordinal.replace("%d",t)}function an(t){return t}function on(t,e,n,r){var i=this._relativeTime[n];return"function"==typeof i?i(t,e,n,r):i.replace(/%d/i,t)}function un(t,e){var n=this._relativeTime[t>0?"future":"past"];return"function"==typeof n?n(e):n.replace(/%s/i,e)}function cn(t){var e,n;for(n in t)e=t[n],"function"==typeof e?this[n]=e:this["_"+n]=e;this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function ln(t,e,n,r){var i=D(),s=c().set(r,e);return i[n](s,t)}function hn(t,e,n,r,i){if("number"==typeof t&&(e=t,t=void 0),t=t||"",null!=e)return ln(t,e,n,i);var s,a=[];for(s=0;r>s;s++)a[s]=ln(t,s,n,i);return a}function dn(t,e){return hn(t,e,"months",12,"month")}function fn(t,e){return hn(t,e,"monthsShort",12,"month")}function pn(t,e){return hn(t,e,"weekdays",7,"day")}function gn(t,e){return hn(t,e,"weekdaysShort",7,"day")}function yn(t,e){return hn(t,e,"weekdaysMin",7,"day")}function mn(){var t=this._data;return this._milliseconds=Kr(this._milliseconds),this._days=Kr(this._days),this._months=Kr(this._months),t.milliseconds=Kr(t.milliseconds),t.seconds=Kr(t.seconds),t.minutes=Kr(t.minutes),t.hours=Kr(t.hours),t.months=Kr(t.months),t.years=Kr(t.years),this}function vn(t,e,n,r){var i=Qt(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function _n(t,e){return vn(this,t,e,1)}function bn(t,e){return vn(this,t,e,-1)}function An(t){return 0>t?Math.floor(t):Math.ceil(t)}function xn(){var t,e,n,r,i,s=this._milliseconds,a=this._days,o=this._months,u=this._data;return s>=0&&a>=0&&o>=0||0>=s&&0>=a&&0>=o||(s+=864e5*An(kn(o)+a),a=0,o=0),u.milliseconds=s%1e3,t=m(s/1e3),u.seconds=t%60,e=m(t/60),u.minutes=e%60,n=m(e/60),u.hours=n%24,a+=m(n/24),i=m(wn(a)),o+=i,a-=An(kn(i)),r=m(o/12),o%=12,u.days=a,u.months=o,u.years=r,this}function wn(t){return 4800*t/146097}function kn(t){return 146097*t/4800}function En(t){var e,n,r=this._milliseconds;if(t=C(t),"month"===t||"year"===t)return e=this._days+r/864e5,n=this._months+wn(e),"month"===t?n:n/12;switch(e=this._days+Math.round(kn(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return 24*e+r/36e5;case"minute":return 1440*e+r/6e4;case"second":return 86400*e+r/1e3;case"millisecond":return Math.floor(864e5*e)+r;default:throw new Error("Unknown unit "+t)}}function Dn(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)}function Fn(t){return function(){return this.as(t)}}function Cn(t){return t=C(t),this[t+"s"]()}function Tn(t){return function(){return this._data[t]}}function Sn(){return m(this.days()/7)}function Bn(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}function On(t,e,n){var r=Qt(t).abs(),i=fi(r.as("s")),s=fi(r.as("m")),a=fi(r.as("h")),o=fi(r.as("d")),u=fi(r.as("M")),c=fi(r.as("y")),l=i0,l[4]=n,Bn.apply(null,l)}function In(t,e){return void 0===pi[t]?!1:void 0===e?pi[t]:(pi[t]=e,!0)}function Ln(t){var e=this.localeData(),n=On(this,!t,e);return t&&(n=e.pastFuture(+this,n)),e.postformat(n)}function Mn(){var t,e,n,r=gi(this._milliseconds)/1e3,i=gi(this._days),s=gi(this._months);t=m(r/60),e=m(t/60),r%=60,t%=60,n=m(s/12),s%=12;var a=n,o=s,u=i,c=e,l=t,h=r,d=this.asSeconds();return d?(0>d?"-":"")+"P"+(a?a+"Y":"")+(o?o+"M":"")+(u?u+"D":"")+(c||l||h?"T":"")+(c?c+"H":"")+(l?l+"M":"")+(h?h+"S":""):"P0D"}var Nn,Pn,Rn=n.momentProperties=[],jn=!1,Yn={},$n={},Un=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Gn=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Wn={},Vn={},Hn=/\d/,zn=/\d\d/,qn=/\d{3}/,Xn=/\d{4}/,Zn=/[+-]?\d{6}/,Kn=/\d\d?/,Qn=/\d{1,3}/,Jn=/\d{1,4}/,tr=/[+-]?\d{1,6}/,er=/\d+/,nr=/[+-]?\d+/,rr=/Z|[+-]\d\d:?\d\d/gi,ir=/[+-]?\d+(\.\d{1,3})?/,sr=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,ar={},or={},ur=0,cr=1,lr=2,hr=3,dr=4,fr=5,pr=6;M("M",["MM",2],"Mo",function(){return this.month()+1}),M("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),M("MMMM",0,0,function(t){return this.localeData().months(this,t)}),F("month","M"),$("M",Kn),$("MM",Kn,zn),$("MMM",sr),$("MMMM",sr),W(["M","MM"],function(t,e){e[cr]=v(t)-1}),W(["MMM","MMMM"],function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);null!=i?e[cr]=i:h(n).invalidMonth=t});var gr="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),yr="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),mr={};n.suppressDeprecationWarnings=!1;var vr=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,_r=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],br=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],Ar=/^\/?Date\((\-?\d+)/i;n.createFromInputFallback=nt("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),M(0,["YY",2],0,function(){return this.year()%100}),M(0,["YYYY",4],0,"year"),M(0,["YYYYY",5],0,"year"),M(0,["YYYYYY",6,!0],0,"year"),F("year","y"),$("Y",nr),$("YY",Kn,zn),$("YYYY",Jn,Xn),$("YYYYY",tr,Zn),$("YYYYYY",tr,Zn),W(["YYYYY","YYYYYY"],ur),W("YYYY",function(t,e){e[ur]=2===t.length?n.parseTwoDigitYear(t):v(t)}),W("YY",function(t,e){e[ur]=n.parseTwoDigitYear(t)}),n.parseTwoDigitYear=function(t){return v(t)+(v(t)>68?1900:2e3)};var xr=S("FullYear",!1);M("w",["ww",2],"wo","week"),M("W",["WW",2],"Wo","isoWeek"),F("week","w"),F("isoWeek","W"),$("w",Kn),$("ww",Kn,zn),$("W",Kn),$("WW",Kn,zn),V(["w","ww","W","WW"],function(t,e,n,r){e[r.substr(0,1)]=v(t)});var wr={dow:0,doy:6};M("DDD",["DDDD",3],"DDDo","dayOfYear"),F("dayOfYear","DDD"),$("DDD",Qn),$("DDDD",qn),W(["DDD","DDDD"],function(t,e,n){n._dayOfYear=v(t)}),n.ISO_8601=function(){};var kr=nt("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var t=Bt.apply(null,arguments);return this>t?this:t}),Er=nt("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var t=Bt.apply(null,arguments);return t>this?this:t});Pt("Z",":"),Pt("ZZ",""),$("Z",rr),$("ZZ",rr),W(["Z","ZZ"],function(t,e,n){n._useUTC=!0,n._tzm=Rt(t)});var Dr=/([\+\-]|\d\d)/gi;n.updateOffset=function(){};var Fr=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Cr=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/;Qt.fn=Mt.prototype;var Tr=ne(1,"add"),Sr=ne(-1,"subtract");n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";var Br=nt("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return void 0===t?this.localeData():this.locale(t)});M(0,["gg",2],0,function(){return this.weekYear()%100}),M(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Be("gggg","weekYear"),Be("ggggg","weekYear"),Be("GGGG","isoWeekYear"),Be("GGGGG","isoWeekYear"),F("weekYear","gg"),F("isoWeekYear","GG"),$("G",nr),$("g",nr),$("GG",Kn,zn),$("gg",Kn,zn),$("GGGG",Jn,Xn),$("gggg",Jn,Xn),$("GGGGG",tr,Zn),$("ggggg",tr,Zn),V(["gggg","ggggg","GGGG","GGGGG"],function(t,e,n,r){e[r.substr(0,2)]=v(t)}),V(["gg","GG"],function(t,e,r,i){e[i]=n.parseTwoDigitYear(t)}),M("Q",0,0,"quarter"),F("quarter","Q"),$("Q",Hn),W("Q",function(t,e){e[cr]=3*(v(t)-1)}),M("D",["DD",2],"Do","date"),F("date","D"),$("D",Kn),$("DD",Kn,zn),$("Do",function(t,e){return t?e._ordinalParse:e._ordinalParseLenient}),W(["D","DD"],lr),W("Do",function(t,e){e[lr]=v(t.match(Kn)[0],10)});var Or=S("Date",!0);M("d",0,"do","day"),M("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),M("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),M("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),M("e",0,0,"weekday"),M("E",0,0,"isoWeekday"),F("day","d"),F("weekday","e"),F("isoWeekday","E"),$("d",Kn),$("e",Kn),$("E",Kn),$("dd",sr),$("ddd",sr),$("dddd",sr),V(["dd","ddd","dddd"],function(t,e,n){var r=n._locale.weekdaysParse(t);null!=r?e.d=r:h(n).invalidWeekday=t}),V(["d","e","E"],function(t,e,n,r){e[r]=v(t)});var Ir="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Lr="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Mr="Su_Mo_Tu_We_Th_Fr_Sa".split("_");M("H",["HH",2],0,"hour"),M("h",["hh",2],0,function(){return this.hours()%12||12}),He("a",!0),He("A",!1),F("hour","h"),$("a",ze),$("A",ze),$("H",Kn),$("h",Kn),$("HH",Kn,zn),$("hh",Kn,zn),W(["H","HH"],hr),W(["a","A"],function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t}),W(["h","hh"],function(t,e,n){e[hr]=v(t),h(n).bigHour=!0});var Nr=/[ap]\.?m?\.?/i,Pr=S("Hours",!0);M("m",["mm",2],0,"minute"),F("minute","m"),$("m",Kn),$("mm",Kn,zn),W(["m","mm"],dr);var Rr=S("Minutes",!1);M("s",["ss",2],0,"second"),F("second","s"),$("s",Kn),$("ss",Kn,zn),W(["s","ss"],fr);var jr=S("Seconds",!1);M("S",0,0,function(){return~~(this.millisecond()/100)}),M(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),M(0,["SSS",3],0,"millisecond"),M(0,["SSSS",4],0,function(){return 10*this.millisecond()}),M(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),M(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),M(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),M(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),M(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),F("millisecond","ms"),$("S",Qn,Hn),$("SS",Qn,zn),$("SSS",Qn,qn);var Yr;for(Yr="SSSS";Yr.length<=9;Yr+="S")$(Yr,er);for(Yr="S";Yr.length<=9;Yr+="S")W(Yr,Ze);var $r=S("Milliseconds",!1);M("z",0,0,"zoneAbbr"),M("zz",0,0,"zoneName");var Ur=g.prototype;Ur.add=Tr,Ur.calendar=ie,Ur.clone=se,Ur.diff=le,Ur.endOf=xe,Ur.format=pe,Ur.from=ge,Ur.fromNow=ye,Ur.to=me,Ur.toNow=ve,Ur.get=I,Ur.invalidAt=Se,Ur.isAfter=ae,Ur.isBefore=oe,Ur.isBetween=ue,Ur.isSame=ce,Ur.isValid=Ce,Ur.lang=Br,Ur.locale=_e,Ur.localeData=be,Ur.max=Er,Ur.min=kr,Ur.parsingFlags=Te,Ur.set=I,Ur.startOf=Ae,Ur.subtract=Sr,Ur.toArray=De,Ur.toObject=Fe,Ur.toDate=Ee,Ur.toISOString=fe,Ur.toJSON=fe,Ur.toString=de,Ur.unix=ke,Ur.valueOf=we,Ur.year=xr,Ur.isLeapYear=lt,Ur.weekYear=Ie,Ur.isoWeekYear=Le,Ur.quarter=Ur.quarters=Pe,Ur.month=Q,Ur.daysInMonth=J,Ur.week=Ur.weeks=gt,Ur.isoWeek=Ur.isoWeeks=yt,Ur.weeksInYear=Ne,Ur.isoWeeksInYear=Me,Ur.date=Or,Ur.day=Ur.days=Ge,Ur.weekday=We,Ur.isoWeekday=Ve,Ur.dayOfYear=vt,Ur.hour=Ur.hours=Pr,Ur.minute=Ur.minutes=Rr,Ur.second=Ur.seconds=jr,Ur.millisecond=Ur.milliseconds=$r,Ur.utcOffset=$t,Ur.utc=Gt,Ur.local=Wt,Ur.parseZone=Vt,Ur.hasAlignedHourOffset=Ht,Ur.isDST=zt,Ur.isDSTShifted=qt,Ur.isLocal=Xt,Ur.isUtcOffset=Zt,Ur.isUtc=Kt,Ur.isUTC=Kt,Ur.zoneAbbr=Ke,Ur.zoneName=Qe,Ur.dates=nt("dates accessor is deprecated. Use date instead.",Or),Ur.months=nt("months accessor is deprecated. Use month instead",Q),Ur.years=nt("years accessor is deprecated. Use year instead",xr),Ur.zone=nt("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Ut);var Gr=Ur,Wr={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},Vr={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"},Hr="Invalid date",zr="%d",qr=/\d{1,2}/,Xr={future:"in %s",past:"%s ago",s:"a few 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"},Zr=b.prototype;Zr._calendar=Wr,Zr.calendar=en,Zr._longDateFormat=Vr,Zr.longDateFormat=nn,Zr._invalidDate=Hr,Zr.invalidDate=rn,Zr._ordinal=zr,Zr.ordinal=sn,Zr._ordinalParse=qr,Zr.preparse=an,Zr.postformat=an,Zr._relativeTime=Xr,Zr.relativeTime=on,Zr.pastFuture=un,Zr.set=cn,Zr.months=q,Zr._months=gr,Zr.monthsShort=X,Zr._monthsShort=yr,Zr.monthsParse=Z,Zr.week=dt,Zr._week=wr,Zr.firstDayOfYear=pt,Zr.firstDayOfWeek=ft,Zr.weekdays=je,Zr._weekdays=Ir,Zr.weekdaysMin=$e,Zr._weekdaysMin=Mr,Zr.weekdaysShort=Ye,Zr._weekdaysShort=Lr,Zr.weekdaysParse=Ue,Zr.isPM=qe,Zr._meridiemParse=Nr,Zr.meridiem=Xe,k("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,n=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+n}}),n.lang=nt("moment.lang is deprecated. Use moment.locale instead.",k),n.langData=nt("moment.langData is deprecated. Use moment.localeData instead.",D);var Kr=Math.abs,Qr=Fn("ms"),Jr=Fn("s"),ti=Fn("m"),ei=Fn("h"),ni=Fn("d"),ri=Fn("w"),ii=Fn("M"),si=Fn("y"),ai=Tn("milliseconds"),oi=Tn("seconds"),ui=Tn("minutes"),ci=Tn("hours"),li=Tn("days"),hi=Tn("months"),di=Tn("years"),fi=Math.round,pi={s:45,m:45,h:22,d:26,M:11},gi=Math.abs,yi=Mt.prototype;yi.abs=mn,yi.add=_n,yi.subtract=bn,yi.as=En,yi.asMilliseconds=Qr,yi.asSeconds=Jr,yi.asMinutes=ti,yi.asHours=ei,yi.asDays=ni,yi.asWeeks=ri,yi.asMonths=ii,yi.asYears=si,yi.valueOf=Dn,yi._bubble=xn,yi.get=Cn,yi.milliseconds=ai,yi.seconds=oi,yi.minutes=ui,yi.hours=ci,yi.days=li,yi.weeks=Sn,yi.months=hi,yi.years=di,yi.humanize=Ln,yi.toISOString=Mn,yi.toString=Mn,yi.toJSON=Mn,yi.locale=_e,yi.localeData=be,yi.toIsoString=nt("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Mn),yi.lang=Br,M("X",0,0,"unix"),M("x",0,0,"valueOf"),$("x",nr),$("X",ir),W("X",function(t,e,n){n._d=new Date(1e3*parseFloat(t,10))}),W("x",function(t,e,n){n._d=new Date(v(t))}),n.version="2.10.6",r(Bt),n.fn=Gr,n.min=It,n.max=Lt,n.utc=c,n.unix=Je,n.months=dn,n.isDate=s,n.locale=k,n.invalid=f,n.duration=Qt,n.isMoment=y,n.weekdays=pn,n.parseZone=tn,n.localeData=D,n.isDuration=Nt,n.monthsShort=fn,n.weekdaysMin=yn,n.defineLocale=E,n.weekdaysShort=gn,n.normalizeUnits=C,n.relativeTimeThreshold=In;var mi=n;return mi})},{}],105:[function(t,e){e.exports={name:"mermaid",version:"0.5.5",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:{live:"live-server ./test/examples",lint:"node node_modules/eslint/bin/eslint.js src",jison:"gulp jison_legacy",watch:"source ./scripts/watch.sh",doc:"rm -r build;rm -r dist/www;gulp vartree;cp dist/www/all.html ../mermaid-pages/index.html;cp dist/mermaid.js ../mermaid-pages/javascripts/lib;cp dist/mermaid.forest.css ../mermaid-pages/stylesheets",tape:"node node_modules/.bin/tape test/cli_test-*.js",jasmine:"npm run jison &&node node_modules/jasmine-es6/bin/jasmine.js",posttest:"npm run jison",test:"npm run dist && npm run jasmine && npm run tape","dist-slim-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.slim.js -x d3 && cat dist/mermaid.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.slim.min.js","dist-slim-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.slim.js -x d3 && cat dist/mermaidAPI.slim.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.slim.min.js","dist-mermaid":"node node_modules/browserify/bin/cmd.js src/mermaid.js -t babelify -s mermaid -o dist/mermaid.js && cat dist/mermaid.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaid.min.js","dist-mermaidAPI":"node node_modules/browserify/bin/cmd.js src/mermaidAPI.js -t babelify -s mermaidAPI -o dist/mermaidAPI.js && cat dist/mermaidAPI.js | node node_modules/uglifyjs/bin/uglifyjs -mc > dist/mermaidAPI.min.js",dist:"npm run dist-slim-mermaid;npm run dist-slim-mermaidAPI; npm run dist-mermaid;npm run dist-mermaidAPI"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"3.5.6",dagre:"^0.7.4","dagre-d3":"0.4.10",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","babel-eslint":"^4.1.3",babelify:"^6.4.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4",dateformat:"^1.0.11",dox:"^0.8.0",eslint:"^1.6.0","eslint-watch":"^2.1.2","event-stream":"^3.2.0",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.9.0","gulp-bower":"0.0.10","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-dox":"^0.1.6","gulp-ext-replace":"^0.2.0","gulp-filelog":"^0.4.1","gulp-front-matter":"^1.2.3","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~2.1.0","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-marked":"^1.0.0","gulp-mdvars":"^2.0.0","gulp-qunit":"~1.2.1","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1","gulp-vartree":"^2.0.1","hogan.js":"^3.0.2",jasmine:"2.3.2","jasmine-es6":"0.0.18",jison:"zaach/jison",jsdom:"^7.0.2","jshint-stylish":"^2.0.1","map-stream":"0.0.6",marked:"^0.3.2","mock-browser":"^0.91.34",path:"^0.4.9",phantomjs:"^1.9.18",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3",testdom:"^2.0.0",uglifyjs:"^2.4.10","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],106:[function(t,e){"use strict";var n;if(t)try{n=t("d3")}catch(r){}n||(n=window.d3),e.exports=n,function(){var t=!1;if(t="tspans",n.selection.prototype.textwrap)return!1;if("undefined"==typeof t)var t=!1;n.selection.prototype.textwrap=n.selection.enter.prototype.textwrap=function(e,r){var i,r=parseInt(r)||0,s=this,a=function(t){var e=t[0][0],r=e.tagName.toString();if("rect"!==r)return!1;var i={};return i.x=n.select(e).attr("x")||0,i.y=n.select(e).attr("y")||0,i.width=n.select(e).attr("width")||0,i.height=n.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)||"[object Array]"===Object.prototype.toString.call(t)){var e=a(t);return e}return!1},u=function(t,e){var n=t;return 0!==e&&(n.x=parseInt(n.x)+e,n.y=parseInt(n.y)+e,n.width-=2*e,n.height-=2*e),n},c=o(e);if(r&&(c=u(c,r)),0!=s.length&&n&&e&&c){e=c;var l,h=function(t){var r=n.select(t[0].parentNode),s=r.select("text"),a=s.style("line-height"),o=s.text();s.remove();var u=r.append("foreignObject");u.attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);var c=u.append("xhtml:div").attr("class","wrapped");c.style("height",e.height).style("width",e.width).html(o),a&&c.style("line-height",a),i=r.select("foreignObject")},d=function(t){var s,a=t[0],o=a.parentNode,u=n.select(a),c=a.getBBox().height,l=a.getBBox().width,h=c,d=u.style("line-height");if(s=d&&parseInt(d)?parseInt(d.replace("px","")):h,l>e.width){var f=u.text();if(u.text(""),f){var p,g;if(-1!==f.indexOf(" ")){var p=" ";g=f.split(" ")}else{p="";var y=f.length,m=Math.ceil(l/e.width),v=Math.floor(y/m);v*m>=y||m++;for(var _,b,g=[],A=0;m>A;A++)b=A*v,_=f.substr(b,v),g.push(_)}for(var x=[],w=0,k={},A=0;Ae.width&&F&&""!==F&&(w+=C,k={string:F,width:C,offset:w},x.push(k),u.text(""),u.text(D),A==g.length-1&&(E=D,u.text(E),T=a.getComputedTextLength())),A==g.length-1){u.text("");var S=E;S&&""!==S&&(T-w>0&&(T-=w),k={string:S,width:T,offset:w},x.push(k))}}var B;u.text("");for(var A=0;A0){x[A-1]}A*s0?s:void 0; -}),B.attr("x",function(){var t=e.x;return r&&(t+=r),t}))}}}u.attr("y",function(){var t=e.y;return a&&(t+=a),r&&(t+=r),t}),u.attr("x",function(){var t=e.x;return r&&(t+=r),t}),i=n.select(o).selectAll("text")};t&&("foreignobjects"==t?l=h:"tspans"==t&&(l=d)),t||(l="undefined"!=typeof SVGForeignObjectElement?h:d);for(var f=0;f "+t.w+": "+JSON.stringify(r.edge(t))),v(n,r.edge(t),r.edge(t).relation)}),n.attr("height","100%"),n.attr("width","100%")}},{"../../d3":106,"../../logger":125,"./classDb":107,"./parser/classDiagram":109,dagre:53}],109:[function(t,e,n){(function(r){"use strict";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,11],r=[1,12],i=[1,13],a=[1,15],s=[1,16],o=[1,17],u=[6,8],c=[1,26],l=[1,27],h=[1,28],d=[1,29],f=[1,30],p=[1,31],g=[6,8,13,17,23,26,27,28,29,30,31],y=[6,8,13,17,23,26,27,28,29,30,31,45,46,47],m=[23,45,46,47],v=[23,30,31,45,46,47],_=[23,26,27,28,29,45,46,47],b=[6,8,13],A=[1,46],x={trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,CLASS_DIAGRAM:5,NEWLINE:6,statements:7,EOF:8,statement:9,className:10,alphaNumToken:11,relationStatement:12,LABEL:13,classStatement:14,methodStatement:15,CLASS:16,STRUCT_START:17,members:18,STRUCT_STOP:19,MEMBER:20,SEPARATOR:21,relation:22,STR:23,relationType:24,lineType:25,AGGREGATION:26,EXTENSION:27,COMPOSITION:28,DEPENDENCY:29,LINE:30,DOTTED_LINE:31,commentToken:32,textToken:33,graphCodeTokens:34,textNoTagsToken:35,TAGSTART:36,TAGEND:37,"==":38,"--":39,PCT:40,DEFAULT:41,SPACE:42,MINUS:43,keywords:44,UNICODE_TEXT:45,NUM:46,ALPHA:47,$accept:0,$end:1},terminals_:{2:"error",5:"CLASS_DIAGRAM",6:"NEWLINE",8:"EOF",13:"LABEL",16:"CLASS",17:"STRUCT_START",19:"STRUCT_STOP",20:"MEMBER",21:"SEPARATOR",23:"STR",26:"AGGREGATION",27:"EXTENSION",28:"COMPOSITION",29:"DEPENDENCY",30:"LINE",31:"DOTTED_LINE",34:"graphCodeTokens",36:"TAGSTART",37:"TAGEND",38:"==",39:"--",40:"PCT",41:"DEFAULT",42:"SPACE",43:"MINUS",44:"keywords",45:"UNICODE_TEXT",46:"NUM",47:"ALPHA"},productions_:[0,[3,1],[4,4],[7,1],[7,3],[10,2],[10,1],[9,1],[9,2],[9,1],[9,1],[14,2],[14,5],[18,1],[18,2],[15,1],[15,2],[15,1],[15,1],[12,3],[12,4],[12,4],[12,5],[22,3],[22,2],[22,2],[22,1],[24,1],[24,1],[24,1],[24,1],[25,1],[25,1],[32,1],[32,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[35,1],[35,1],[35,1],[35,1],[11,1],[11,1],[11,1]],performAction:function(t,e,n,r,i,a){var s=a.length-1;switch(i){case 5:this.$=a[s-1]+a[s];break;case 6:this.$=a[s];break;case 7:r.addRelation(a[s]);break;case 8:a[s-1].title=r.cleanupLabel(a[s]),r.addRelation(a[s-1]);break;case 12:r.addMembers(a[s-3],a[s-1]);break;case 13:this.$=[a[s]];break;case 14:a[s].push(a[s-1]),this.$=a[s];break;case 15:break;case 16:r.addMembers(a[s-1],r.cleanupLabel(a[s]));break;case 17:console.warn("Member",a[s]);break;case 18:break;case 19:this.$={id1:a[s-2],id2:a[s],relation:a[s-1],relationTitle1:"none",relationTitle2:"none"};break;case 20:this.$={id1:a[s-3],id2:a[s],relation:a[s-1],relationTitle1:a[s-2],relationTitle2:"none"};break;case 21:this.$={id1:a[s-3],id2:a[s],relation:a[s-2],relationTitle1:"none",relationTitle2:a[s-1]};break;case 22:this.$={id1:a[s-4],id2:a[s],relation:a[s-2],relationTitle1:a[s-3],relationTitle2:a[s-1]};break;case 23:this.$={type1:a[s-2],type2:a[s],lineType:a[s-1]};break;case 24:this.$={type1:"none",type2:a[s],lineType:a[s-1]};break;case 25:this.$={type1:a[s-1],type2:"none",lineType:a[s]};break;case 26:this.$={type1:"none",type2:"none",lineType:a[s]};break;case 27:this.$=r.relationType.AGGREGATION;break;case 28:this.$=r.relationType.EXTENSION;break;case 29:this.$=r.relationType.COMPOSITION;break;case 30:this.$=r.relationType.DEPENDENCY;break;case 31:this.$=r.lineType.LINE;break;case 32:this.$=r.lineType.DOTTED_LINE}},table:[{3:1,4:2,5:[1,3]},{1:[3]},{1:[2,1]},{6:[1,4]},{7:5,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:s,47:o},{8:[1,18]},{6:[1,19],8:[2,3]},e(u,[2,7],{13:[1,20]}),e(u,[2,9]),e(u,[2,10]),e(u,[2,15],{22:21,24:24,25:25,13:[1,23],23:[1,22],26:c,27:l,28:h,29:d,30:f,31:p}),{10:32,11:14,45:a,46:s,47:o},e(u,[2,17]),e(u,[2,18]),e(g,[2,6],{11:14,10:33,45:a,46:s,47:o}),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),{1:[2,2]},{7:34,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:a,46:s,47:o},e(u,[2,8]),{10:35,11:14,23:[1,36],45:a,46:s,47:o},{22:37,24:24,25:25,26:c,27:l,28:h,29:d,30:f,31:p},e(u,[2,16]),{25:38,30:f,31:p},e(m,[2,26],{24:39,26:c,27:l,28:h,29:d}),e(v,[2,27]),e(v,[2,28]),e(v,[2,29]),e(v,[2,30]),e(_,[2,31]),e(_,[2,32]),e(u,[2,11],{17:[1,40]}),e(g,[2,5]),{8:[2,4]},e(b,[2,19]),{10:41,11:14,45:a,46:s,47:o},{10:42,11:14,23:[1,43],45:a,46:s,47:o},e(m,[2,25],{24:44,26:c,27:l,28:h,29:d}),e(m,[2,24]),{18:45,20:A},e(b,[2,21]),e(b,[2,20]),{10:47,11:14,45:a,46:s,47:o},e(m,[2,23]),{19:[1,48]},{18:49,19:[2,13],20:A},e(b,[2,22]),e(u,[2,12]),{19:[2,14]}],defaultActions:{2:[2,1],18:[2,2],34:[2,4],49:[2,14]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[b]&&a[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in a[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],F.$=r[r.length-k],F._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(F,[s,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(F.$),i.push(F._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},w=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:return 6;case 2:break;case 3:return 5;case 4:return this.begin("struct"),17;case 5:return this.popState(),19;case 6:break;case 7:return"MEMBER";case 8:return 16;case 9:this.begin("string");break;case 10:this.popState();break;case 11:return"STR";case 12:return 27;case 13:return 27;case 14:return 29;case 15:return 29;case 16:return 28;case 17:return 26;case 18:return 30;case 19:return 31;case 20:return 13;case 21:return 43;case 22:return"DOT";case 23:return"PLUS";case 24:return 40;case 25:return"EQUALS";case 26:return"EQUALS";case 27:return 47;case 28:return"PUNCTUATION";case 29:return 46;case 30:return 45;case 31:return 42;case 32:return 8}},rules:[/^(?:%%[^\n]*)/,/^(?:\n+)/,/^(?:\s+)/,/^(?:classDiagram\b)/,/^(?:[\{])/,/^(?:\})/,/^(?:[\n])/,/^(?:[^\{\}\n]*)/,/^(?:class\b)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::[^#\n;]+)/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[A-Za-z]+)/,/^(?:[!"#$%&'*+,-.`?\\_\/])/,/^(?:[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:{string:{rules:[10,11],inclusive:!1},struct:{rules:[5,6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,8,9,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32],inclusive:!0}}};return t}();return x.lexer=w,t.prototype=x,x.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("_process"))},{_process:3,fs:1,path:2}],110:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),s=new a.Log,o="",u=!1;n.setMessage=function(t){s.debug("Setting message to: "+t),o=t},n.getMessage=function(){return o},n.setInfo=function(t){u=t},n.getInfo=function(){return u},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":125}],111:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),s=t("./exampleDb"),o=t("./parser/example.js"),u=t("../../d3"),c=new a.Log;n.draw=function(t,e,n){var r;r=o.parser,r.yy=s,c.debug("Renering example diagram"),r.parse(t);var i=u.select("#"+e),a=i.append("g");a.append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("mermaid "+n),i.attr("height",100),i.attr("width",400)}},{"../../d3":106,"../../logger":125,"./exampleDb":110,"./parser/example.js":112}],112:[function(t,e,n){(function(r){"use strict";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=[6,9,10,12],r={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,message:11,say:12,TXT:13,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo",12:"say",13:"TXT"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1],[8,1],[11,2]],performAction:function(t,e,n,r,i,a){var s=a.length-1;switch(i){case 1:return r;case 4:break;case 6:r.setInfo(!0);break;case 7:r.setMessage(a[s]);break;case 8:this.$=a[s-1].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8],11:9,12:[1,10]},{1:[2,1]},e(n,[2,3]),e(n,[2,4]),e(n,[2,5]),e(n,[2,6]),e(n,[2,7]),{13:[1,11]},e(n,[2,8])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[b]&&a[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in a[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],F.$=r[r.length-k],F._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(F,[s,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(F.$),i.push(F._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},i=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,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),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;ae[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]),"utf8");return n.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&n.main(r.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],113:[function(t,e){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var r,i=t("../../logger"),a=n(i),s=new a.Log;if(t)try{r=t("dagre-d3")}catch(o){s.debug("Could not load dagre-d3")}r||(r=window.dagreD3),e.exports=r},{"../../logger":125,"dagre-d3":4}],114:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),s=t("./graphDb"),o=t("./parser/flow"),u=t("./parser/dot"),c=t("../../d3"),l=t("./dagre-d3"),h=new a.Log,d={};e.exports.setConf=function(t){var e,n=Object.keys(t);for(e=0;e0&&(s=a.classes.join(" "));var o="";o=r(o,a.styles),i="undefined"==typeof a.text?a.id:a.text;var u="";d.htmlLabels?(u="html",i=i.replace(/fa:fa[\w\-]+/g,function(t){return''})):(i=i.replace(/
/g,"\n"),u="text");var c=0,l="";switch(a.type){case"round":c=5,l="rect";break;case"square":l="rect";break;case"diamond":l="question";break;case"odd":l="rect_left_inv_arrow";break;case"odd_right":l="rect_left_inv_arrow";break;case"circle":l="circle";break;case"ellipse":l="ellipse";break;case"group":l="rect",i="";break;default:l="rect"}e.setNode(a.id,{labelType:u,shape:l,label:i,rx:c,ry:c,"class":s,style:o,id:a.id})})},n.addEdges=function(t,e){var n,r,i=0;"undefined"!=typeof t.defaultStyle&&(r=t.defaultStyle.toString().replace(/,/g,";")),t.forEach(function(t){i++,n="arrow_open"===t.type?"none":"normal";var a="";if("undefined"!=typeof t.style)t.style.forEach(function(t){a=a+t+";"});else switch(t.stroke){case"normal":a="fill:none","undefined"!=typeof r&&(a=r);break;case"dotted":a="stroke: #333; fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":a="stroke: #333; stroke-width: 3.5px;fill:none"}if("undefined"==typeof t.text)"undefined"==typeof t.style?e.setEdge(t.start,t.end,{style:a,arrowhead:n},i):e.setEdge(t.start,t.end,{style:a,arrowheadStyle:"fill: #333",arrowhead:n},i);else{var s=t.text.replace(/
/g,"\n");"undefined"==typeof t.style?d.htmlLabels?e.setEdge(t.start,t.end,{labelType:"html",style:a,labelpos:"c",label:''+t.text+"",arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:"stroke: #333; stroke-width: 1.5px;fill:none",labelpos:"c",label:s,arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:a,arrowheadStyle:"fill: #333",label:s,arrowhead:n},i)}})},n.getClasses=function(t,e){var n;s.clear(),n=e?u.parser:o.parser,n.yy=s,n.parse(t);var r=s.getClasses();return"undefined"==typeof r["default"]&&(r["default"]={id:"default"},r["default"].styles=[],r["default"].clusterStyles=["rx:4px","fill: rgb(255, 255, 222)","rx: 4px","stroke: rgb(170, 170, 51)","stroke-width: 1px"],r["default"].nodeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"],r["default"].edgeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"]),r},n.draw=function(t,e,r){h.debug("Drawing flowchart");var i;s.clear(),i=r?u.parser:o.parser,i.yy=s;try{i.parse(t)}catch(a){h.debug("Parsing failed")}var f;f=s.getDirection(),"undefined"==typeof f&&(f="TD");var p,g=new l.graphlib.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:f,marginx:20,marginy:20}).setDefaultEdgeLabel(function(){return{}}),y=s.getSubGraphs(),m=0;for(m=y.length-1;m>=0;m--)p=y[m],s.addVertex(p.id,p.title,"group",void 0);var v=s.getVertices(),_=s.getEdges();m=0;var b;for(m=y.length-1;m>=0;m--)for(p=y[m],c.selectAll("cluster").append("text"),b=0;b0?t.split(",").forEach(function(t){"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)}):"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)};var setTooltip=function(t,e){"undefined"!=typeof e&&(tooltips[t]=e)},setClickFun=function setClickFun(id,functionName){"undefined"!=typeof functionName&&"undefined"!=typeof vertices[id]&&funs.push(function(element){var elem=d3.select(element).select("#"+id);null!==elem&&elem.on("click",function(){eval(functionName+"('"+id+"')")})})},setLink=function(t,e){"undefined"!=typeof e&&"undefined"!=typeof vertices[t]&&funs.push(function(n){var r=d3.select(n).select("#"+t);null!==r&&r.on("click",function(){window.open(e,"newTab")})})};exports.getTooltip=function(t){return tooltips[t]},exports.setClickEvent=function(t,e,n,r){t.indexOf(",")>0?t.split(",").forEach(function(t){setTooltip(t,r),setClickFun(t,e),setLink(t,n)}):(setTooltip(t,r),setClickFun(t,e),setLink(t,n))},exports.bindFunctions=function(t){funs.forEach(function(e){e(t)})},exports.getDirection=function(){return direction},exports.getVertices=function(){return vertices},exports.getEdges=function(){return edges},exports.getClasses=function(){return classes};var setupToolTips=function(t){var e=d3.select(".mermaidTooltip");null===e[0][0]&&(e=d3.select("body").append("div").attr("class","mermaidTooltip").style("opacity",0));var n=d3.select(t).select("svg"),r=n.selectAll("g.node");r.on("mouseover",function(){var t=d3.select(this),n=t.attr("title");if(null!==n){var r=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",r.left+(r.right-r.left)/2+"px").style("top",r.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}}).on("mouseout",function(){e.transition().duration(500).style("opacity",0);var t=d3.select(this);t.classed("hover",!1)})};funs.push(setupToolTips),exports.clear=function(){vertices={},classes={},edges=[],funs=[],funs.push(setupToolTips),subGraphs=[],subCount=0,tooltips=[]},exports.defaultStyle=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},exports.addSubGraph=function(t,e){function n(t){var e={"boolean":{},number:{},string:{}},n=[];return t.filter(function(t){var r=typeof t;return" "===t?!1:r in e?e[r].hasOwnProperty(t)?!1:e[r][t]=!0:n.indexOf(t)>=0?!1:n.push(t)})}var r=[];r=n(r.concat.apply(r,t));var i={id:"subGraph"+subCount,nodes:r,title:e};return subGraphs.push(i),subCount+=1,i.id};var getPosForId=function(t){var e;for(e=0;e2e3)){if(posCrossRef[secCount]=n,subGraphs[n].id===e)return{result:!0,count:0};for(var i=0,a=1;i=0){var o=t(e,s);if(o.result)return{result:!0,count:a+o.count};a+=o.count}i+=1}return{result:!1,count:a}}};exports.getDepthFirstPos=function(t){return posCrossRef[t]},exports.indexNodes=function(){secCount=-1,subGraphs.length>0&&indexNodes("none",subGraphs.length-1,0)},exports.getSubGraphs=function(){return subGraphs},exports.parseError=function(t,e){global.mermaidAPI.parseError(t,e)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../d3":106,"../../logger":125}],116:[function(t,e,n){(function(r){"use strict";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,5],r=[1,6],i=[1,12],a=[1,13],s=[1,14],o=[1,15],u=[1,16],c=[1,17],l=[1,18],h=[1,19],d=[1,20],f=[1,21],p=[1,22],g=[8,16,17,18,19,20,21,22,23,24,25,26],y=[1,37],m=[1,33],v=[1,34],_=[1,35],b=[1,36],A=[8,10,16,17,18,19,20,21,22,23,24,25,26,28,32,37,39,40,45,57,58],x=[10,28],w=[10,28,37,57,58],k=[2,49],E=[1,45],D=[1,48],C=[1,49],F=[1,52],T=[2,65],S=[1,65],B=[1,66],O=[1,67],I=[1,68],M=[1,69],L=[1,70],P=[1,71],N=[1,72],R=[1,73],j=[8,16,17,18,19,20,21,22,23,24,25,26,47],Y=[10,28,37],$={trace:function(){},yy:{},symbols_:{error:2,expressions:3,graph:4,EOF:5,graphStatement:6,idStatement:7,"{":8,stmt_list:9,"}":10,strict:11,GRAPH:12,DIGRAPH:13,textNoTags:14,textNoTagsToken:15,ALPHA:16,NUM:17,COLON:18,PLUS:19,EQUALS:20,MULT:21,DOT:22,BRKT:23,SPACE:24,MINUS:25,keywords:26,stmt:27,";":28,node_stmt:29,edge_stmt:30,attr_stmt:31,"=":32,subgraph:33,attr_list:34,NODE:35,EDGE:36,"[":37,a_list:38,"]":39,",":40,edgeRHS:41,node_id:42,edgeop:43,port:44,":":45,compass_pt:46,SUBGRAPH:47,n:48,ne:49,e:50,se:51,s:52,sw:53,w:54,nw:55,c:56,ARROW_POINT:57,ARROW_OPEN:58,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",8:"{",10:"}",11:"strict",12:"GRAPH",13:"DIGRAPH",16:"ALPHA",17:"NUM",18:"COLON",19:"PLUS",20:"EQUALS",21:"MULT",22:"DOT",23:"BRKT",24:"SPACE",25:"MINUS",26:"keywords",28:";",32:"=",35:"NODE",36:"EDGE",37:"[",39:"]",40:",",45:":",47:"SUBGRAPH",48:"n",49:"ne",50:"e",51:"se",52:"s",53:"sw",54:"w",55:"nw",56:"c",57:"ARROW_POINT",58:"ARROW_OPEN"},productions_:[0,[3,2],[4,5],[4,6],[4,4],[6,1],[6,1],[7,1],[14,1],[14,2],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[9,1],[9,3],[27,1],[27,1],[27,1],[27,3],[27,1],[31,2],[31,2],[31,2],[34,4],[34,3],[34,3],[34,2],[38,5],[38,5],[38,3],[30,3],[30,3],[30,2],[30,2],[41,3],[41,3],[41,2],[41,2],[29,2],[29,1],[42,2],[42,1],[44,4],[44,2],[44,2],[33,5],[33,4],[33,3],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,0],[43,1],[43,1]],performAction:function(t,e,n,r,i,a){var s=a.length-1;switch(i){case 1:this.$=a[s-1];break;case 2:this.$=a[s-4];break;case 3:this.$=a[s-5];break;case 4:this.$=a[s-3];break;case 8:case 10:case 11:this.$=a[s];break;case 9:this.$=a[s-1]+""+a[s];break;case 12:case 13:case 14:case 15:case 16:case 18:case 19:case 20:this.$=a[s];break;case 17:this.$="
";break;case 39:this.$="oy";break;case 40:r.addLink(a[s-1],a[s].id,a[s].op),this.$="oy";break;case 42:r.addLink(a[s-1],a[s].id,a[s].op),this.$={op:a[s-2],id:a[s-1]};break;case 44:this.$={op:a[s-1],id:a[s]};break;case 48:r.addVertex(a[s-1]),this.$=a[s-1];break;case 49:r.addVertex(a[s]),this.$=a[s];break;case 66:this.$="arrow";break;case 67:this.$="arrow_open"}},table:[{3:1,4:2,6:3,11:[1,4],12:n,13:r},{1:[3]},{5:[1,7]},{7:8,8:[1,9],14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{6:23,12:n,13:r},e(g,[2,5]),e(g,[2,6]),{1:[2,1]},{8:[1,24]},{7:30,8:y,9:25,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},e([8,10,28,32,37,39,40,45,57,58],[2,7],{15:38,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p}),e(A,[2,8]),e(A,[2,10]),e(A,[2,11]),e(A,[2,12]),e(A,[2,13]),e(A,[2,14]),e(A,[2,15]),e(A,[2,16]),e(A,[2,17]),e(A,[2,18]),e(A,[2,19]),e(A,[2,20]),{7:39,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{7:30,8:y,9:40,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,41]},{10:[2,21],28:[1,42]},e(x,[2,23]),e(x,[2,24]),e(x,[2,25]),e(w,k,{44:44,32:[1,43],45:E}),e(x,[2,27],{41:46,43:47,57:D,58:C}),e(x,[2,47],{43:47,34:50,41:51,37:F,57:D,58:C}),{34:53,37:F},{34:54,37:F},{34:55,37:F},{7:56,8:[1,57],14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{7:30,8:y,9:58,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},e(A,[2,9]),{8:[1,59]},{10:[1,60]},{5:[2,4]},{7:30,8:y,9:61,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{7:62,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},e(w,[2,48]),e(w,T,{14:10,15:11,7:63,46:64,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,48:S,49:B,50:O,51:I,52:M,53:L,54:P,55:N,56:R}),e(x,[2,41],{34:74,37:F}),{7:77,8:y,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,33:76,42:75,47:b},e(j,[2,66]),e(j,[2,67]),e(x,[2,46]),e(x,[2,40],{34:78,37:F}),{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:79,39:[1,80]},e(x,[2,28]),e(x,[2,29]),e(x,[2,30]),{8:[1,82]},{7:30,8:y,9:83,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,84]},{7:30,8:y,9:85,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{5:[2,2]},{10:[2,22]},e(x,[2,26]),e(w,[2,51],{45:[1,86]}),e(w,[2,52]),e(w,[2,56]),e(w,[2,57]),e(w,[2,58]),e(w,[2,59]),e(w,[2,60]),e(w,[2,61]),e(w,[2,62]),e(w,[2,63]),e(w,[2,64]),e(x,[2,38]),e(Y,[2,44],{43:47,41:87,57:D,58:C}),e(Y,[2,45],{43:47,41:88,57:D,58:C}),e(w,k,{44:44,45:E}),e(x,[2,39]),{39:[1,89]},e(x,[2,34],{34:90,37:F}),{32:[1,91]},{7:30,8:y,9:92,12:m,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,93]},e(w,[2,55]),{10:[1,94]},e(w,T,{46:95,48:S,49:B,50:O,51:I,52:M,53:L,54:P,55:N,56:R}),e(Y,[2,42]),e(Y,[2,43]),e(x,[2,33],{34:96,37:F}),e(x,[2,32]),{7:97,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{10:[1,98]},e(w,[2,54]),{5:[2,3]},e(w,[2,50]),e(x,[2,31]),{28:[1,99],39:[2,37],40:[1,100]},e(w,[2,53]),{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:101},{7:81,14:10,15:11,16:i,17:a,18:s,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:102},{39:[2,35]},{39:[2,36]}],defaultActions:{7:[2,1],41:[2,4],60:[2,2],61:[2,22],94:[2,3],101:[2,35],102:[2,36]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[b]&&a[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in a[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],F.$=r[r.length-k],F._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(F,[s,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(F.$),i.push(F._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},U=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:return"STYLE";case 1:return"LINKSTYLE";case 2:return"CLASSDEF";case 3:return"CLASS";case 4:return"CLICK";case 5:return 12;case 6:return 13;case 7:return 47;case 8:return 35;case 9:return 36;case 10:return"DIR";case 11:return"DIR";case 12:return"DIR";case 13:return"DIR";case 14:return"DIR";case 15:return"DIR";case 16:return 17;case 17:return 23;case 18:return 18;case 19:return 28;case 20:return 40;case 21:return 32;case 22:return 21;case 23:return 22;case 24:return"ARROW_CROSS";case 25:return 57;case 26:return"ARROW_CIRCLE";case 27:return 58;case 28:return 25;case 29:return 19;case 30:return 20;case 31:return 16;case 32:return"PIPE";case 33:return"PS";case 34:return"PE";case 35:return 37;case 36:return 39;case 37:return 8;case 38:return 10;case 39:return"QUOTE";case 40:return 24;case 41:return"NEWLINE";case 42:return 5}},rules:[/^(?:style\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:digraph\b)/,/^(?:subgraph\b)/,/^(?:node\b)/,/^(?:edge\b)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9])/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:=)/,/^(?:\*)/,/^(?:\.)/,/^(?:--[x])/,/^(?:->)/,/^(?:--[o])/,/^(?:--)/,/^(?:-)/,/^(?:\+)/,/^(?:=)/,/^(?:[\u0021-\u0027\u002A-\u002E\u003F\u0041-\u005A\u0061-\u007A\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)/,/^(?:\n)/,/^(?:$)/], -conditions:{INITIAL:{rules:[0,1,2,3,4,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],inclusive:!0}}};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("_process"))},{_process:3,fs:1,path:2}],117:[function(t,e,n){(function(r){"use strict";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,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],s=[2,2],o=[1,12],u=[1,13],c=[1,14],l=[1,15],h=[1,31],d=[1,33],f=[1,22],p=[1,34],g=[1,24],y=[1,25],m=[1,26],v=[1,27],_=[1,28],b=[1,38],A=[1,40],x=[1,35],w=[1,39],k=[1,45],E=[1,44],D=[1,36],C=[1,37],F=[1,41],T=[1,42],S=[1,43],B=[1,8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],O=[1,53],I=[1,52],M=[1,54],L=[1,72],P=[1,80],N=[1,81],R=[1,66],j=[1,65],Y=[1,85],$=[1,84],U=[1,82],W=[1,83],G=[1,73],V=[1,68],H=[1,67],z=[1,63],q=[1,75],X=[1,76],Z=[1,77],K=[1,78],Q=[1,79],J=[1,70],tt=[1,69],et=[8,9,11],nt=[8,9,11,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64],rt=[1,115],it=[8,9,10,11,13,15,18,36,38,40,42,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,85,87,88,90,91,93,94,95,96,97],at=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,42,43,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],st=[1,117],ot=[1,118],ut=[8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],ct=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,43,46,50,51,52,53,54,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],lt=[13,18,46,81,85,87,88,90,91,93,94,95,96,97],ht=[13,18,46,49,65,81,85,87,88,90,91,93,94,95,96,97],dt=[1,191],ft=[1,188],pt=[1,195],gt=[1,192],yt=[1,189],mt=[1,196],vt=[1,186],_t=[1,187],bt=[1,190],At=[1,193],xt=[1,194],wt=[1,211],kt=[8,9,11,85],Et=[8,9,10,11,46,71,80,81,83,85,87,88,89,90,91],Dt={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,"(-":40,"-)":41,DIAMOND_START:42,DIAMOND_STOP:43,alphaNumStatement:44,alphaNumToken:45,MINUS:46,linkStatement:47,arrowText:48,TESTSTR:49,"--":50,ARROW_POINT:51,ARROW_CIRCLE:52,ARROW_CROSS:53,ARROW_OPEN:54,"-.":55,DOTTED_ARROW_POINT:56,DOTTED_ARROW_CIRCLE:57,DOTTED_ARROW_CROSS:58,DOTTED_ARROW_OPEN:59,"==":60,THICK_ARROW_POINT:61,THICK_ARROW_CIRCLE:62,THICK_ARROW_CROSS:63,THICK_ARROW_OPEN:64,PIPE:65,textToken:66,STR:67,commentText:68,commentToken:69,keywords:70,STYLE:71,LINKSTYLE:72,CLASSDEF:73,CLASS:74,CLICK:75,textNoTags:76,textNoTagsToken:77,DEFAULT:78,stylesOpt:79,HEX:80,NUM:81,commentStatement:82,PCT:83,style:84,COMMA:85,styleComponent:86,ALPHA:87,COLON:88,UNIT:89,BRKT:90,DOT:91,graphCodeTokens:92,PUNCTUATION:93,UNICODE_TEXT:94,PLUS:95,EQUALS:96,MULT:97,TAG_START:98,TAG_END:99,QUOTE:100,$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:"(-",41:"-)",42:"DIAMOND_START",43:"DIAMOND_STOP",46:"MINUS",49:"TESTSTR",50:"--",51:"ARROW_POINT",52:"ARROW_CIRCLE",53:"ARROW_CROSS",54:"ARROW_OPEN",55:"-.",56:"DOTTED_ARROW_POINT",57:"DOTTED_ARROW_CIRCLE",58:"DOTTED_ARROW_CROSS",59:"DOTTED_ARROW_OPEN",60:"==",61:"THICK_ARROW_POINT",62:"THICK_ARROW_CIRCLE",63:"THICK_ARROW_CROSS",64:"THICK_ARROW_OPEN",65:"PIPE",67:"STR",71:"STYLE",72:"LINKSTYLE",73:"CLASSDEF",74:"CLASS",75:"CLICK",78:"DEFAULT",80:"HEX",81:"NUM",83:"PCT",85:"COMMA",87:"ALPHA",88:"COLON",89:"UNIT",90:"BRKT",91:"DOT",93:"PUNCTUATION",94:"UNICODE_TEXT",95:"PLUS",96:"EQUALS",97:"MULT",98:"TAG_START",99:"TAG_END",100:"QUOTE"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,4],[4,4],[4,4],[4,4],[4,4],[19,2],[19,1],[20,1],[20,1],[20,1],[14,1],[14,1],[14,2],[22,2],[22,2],[22,1],[22,1],[21,2],[21,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,5],[7,4],[24,1],[24,1],[24,1],[23,3],[23,1],[33,4],[33,5],[33,6],[33,7],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,1],[33,2],[35,1],[35,2],[44,1],[44,1],[44,1],[44,1],[34,2],[34,3],[34,3],[34,1],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[48,3],[31,1],[31,2],[31,1],[68,1],[68,2],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[76,1],[76,2],[27,5],[27,5],[28,5],[29,5],[29,7],[29,5],[29,7],[25,5],[25,5],[26,5],[26,5],[82,3],[79,1],[79,3],[84,1],[84,2],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[69,1],[69,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[77,1],[77,1],[77,1],[77,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1]],performAction:function(t,e,n,r,i,a){var s=a.length-1;switch(i){case 2:this.$=[];break;case 3:a[s]!==[]&&a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 57:case 59:case 60:case 92:case 94:case 95:case 108:this.$=a[s];break;case 11:r.setDirection(a[s-1]),this.$=a[s-1];break;case 12:r.setDirection("LR"),this.$=a[s-1];break;case 13:r.setDirection("RL"),this.$=a[s-1];break;case 14:r.setDirection("BT"),this.$=a[s-1];break;case 15:r.setDirection("TB"),this.$=a[s-1];break;case 30:this.$=a[s-1];break;case 31:case 32:case 33:case 34:case 35:this.$=[];break;case 36:this.$=r.addSubGraph(a[s-1],a[s-3]);break;case 37:this.$=r.addSubGraph(a[s-1],void 0);break;case 41:r.addLink(a[s-2],a[s],a[s-1]),this.$=[a[s-2],a[s]];break;case 42:this.$=[a[s]];break;case 43:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"square");break;case 44:this.$=a[s-4],r.addVertex(a[s-4],a[s-2],"square");break;case 45:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],"circle");break;case 46:this.$=a[s-6],r.addVertex(a[s-6],a[s-3],"circle");break;case 47:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"ellipse");break;case 48:this.$=a[s-4],r.addVertex(a[s-4],a[s-2],"ellipse");break;case 49:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"round");break;case 50:this.$=a[s-4],r.addVertex(a[s-4],a[s-2],"round");break;case 51:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"diamond");break;case 52:this.$=a[s-4],r.addVertex(a[s-4],a[s-2],"diamond");break;case 53:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"odd");break;case 54:this.$=a[s-4],r.addVertex(a[s-4],a[s-2],"odd");break;case 55:this.$=a[s],r.addVertex(a[s]);break;case 56:this.$=a[s-1],r.addVertex(a[s-1]);break;case 58:case 93:case 96:case 109:this.$=a[s-1]+""+a[s];break;case 61:this.$="v";break;case 62:this.$="-";break;case 63:a[s-1].text=a[s],this.$=a[s-1];break;case 64:case 65:a[s-2].text=a[s-1],this.$=a[s-2];break;case 66:this.$=a[s];break;case 67:this.$={type:"arrow",stroke:"normal",text:a[s-1]};break;case 68:this.$={type:"arrow_circle",stroke:"normal",text:a[s-1]};break;case 69:this.$={type:"arrow_cross",stroke:"normal",text:a[s-1]};break;case 70:this.$={type:"arrow_open",stroke:"normal",text:a[s-1]};break;case 71:this.$={type:"arrow",stroke:"dotted",text:a[s-1]};break;case 72:this.$={type:"arrow_circle",stroke:"dotted",text:a[s-1]};break;case 73:this.$={type:"arrow_cross",stroke:"dotted",text:a[s-1]};break;case 74:this.$={type:"arrow_open",stroke:"dotted",text:a[s-1]};break;case 75:this.$={type:"arrow",stroke:"thick",text:a[s-1]};break;case 76:this.$={type:"arrow_circle",stroke:"thick",text:a[s-1]};break;case 77:this.$={type:"arrow_cross",stroke:"thick",text:a[s-1]};break;case 78:this.$={type:"arrow_open",stroke:"thick",text:a[s-1]};break;case 79:this.$={type:"arrow",stroke:"normal"};break;case 80:this.$={type:"arrow_circle",stroke:"normal"};break;case 81:this.$={type:"arrow_cross",stroke:"normal"};break;case 82:this.$={type:"arrow_open",stroke:"normal"};break;case 83:this.$={type:"arrow",stroke:"dotted"};break;case 84:this.$={type:"arrow_circle",stroke:"dotted"};break;case 85:this.$={type:"arrow_cross",stroke:"dotted"};break;case 86:this.$={type:"arrow_open",stroke:"dotted"};break;case 87:this.$={type:"arrow",stroke:"thick"};break;case 88:this.$={type:"arrow_circle",stroke:"thick"};break;case 89:this.$={type:"arrow_cross",stroke:"thick"};break;case 90:this.$={type:"arrow_open",stroke:"thick"};break;case 91:this.$=a[s-1];break;case 110:case 111:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 112:this.$=a[s-4],r.setClass(a[s-2],a[s]);break;case 113:this.$=a[s-4],r.setClickEvent(a[s-2],a[s],void 0,void 0);break;case 114:this.$=a[s-6],r.setClickEvent(a[s-4],a[s-2],void 0,a[s]);break;case 115:this.$=a[s-4],r.setClickEvent(a[s-2],void 0,a[s],void 0);break;case 116:this.$=a[s-6],r.setClickEvent(a[s-4],void 0,a[s-2],a[s]);break;case 117:this.$=a[s-4],r.addVertex(a[s-2],void 0,void 0,a[s]);break;case 118:case 119:case 120:this.$=a[s-4],r.updateLink(a[s-2],a[s]);break;case 122:this.$=[a[s]];break;case 123:a[s-2].push(a[s]),this.$=a[s-2];break;case 125:this.$=a[s-1]+a[s]}},table:[{3:1,4:2,9:n,10:r,12:i},{1:[3]},e(a,s,{5:6}),{4:7,9:n,10:r,12:i},{4:8,9:n,10:r,12:i},{10:[1,9]},{1:[2,1],6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(a,[2,9]),e(a,[2,10]),{13:[1,46],15:[1,47],16:[1,48],17:[1,49],18:[1,50]},e(B,[2,3]),e(B,[2,4]),e(B,[2,5]),e(B,[2,6]),e(B,[2,7]),e(B,[2,8]),{8:O,9:I,11:M,24:51},{8:O,9:I,11:M,24:55},{8:O,9:I,11:M,24:56},{8:O,9:I,11:M,24:57},{8:O,9:I,11:M,24:58},{8:O,9:I,11:M,24:59},{8:O,9:I,10:L,11:M,12:P,13:N,15:R,16:j,17:Y,18:$,24:61,30:U,31:60,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(et,[2,42],{34:86,47:87,50:[1,88],51:[1,91],52:[1,92],53:[1,93],54:[1,94],55:[1,89],56:[1,95],57:[1,96],58:[1,97],59:[1,98],60:[1,90],61:[1,99],62:[1,100],63:[1,101],64:[1,102]}),{10:[1,103]},{10:[1,104]},{10:[1,105]},{10:[1,106]},{10:[1,107]},e(nt,[2,55],{45:32,21:113,44:114,10:rt,13:h,15:[1,112],18:d,36:[1,108],38:[1,109],40:[1,110],42:[1,111],46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S}),e(it,[2,57]),e(it,[2,59]),e(it,[2,60]),e(it,[2,61]),e(it,[2,62]),e(at,[2,150]),e(at,[2,151]),e(at,[2,152]),e(at,[2,153]),e(at,[2,154]),e(at,[2,155]),e(at,[2,156]),e(at,[2,157]),e(at,[2,158]),e(at,[2,159]),e(at,[2,160]),{8:st,9:ot,10:rt,14:116,21:119},{8:st,9:ot,10:rt,14:120,21:119},{8:st,9:ot,10:rt,14:121,21:119},{8:st,9:ot,10:rt,14:122,21:119},{8:st,9:ot,10:rt,14:123,21:119},e(B,[2,30]),e(B,[2,38]),e(B,[2,39]),e(B,[2,40]),e(B,[2,31]),e(B,[2,32]),e(B,[2,33]),e(B,[2,34]),e(B,[2,35]),{8:O,9:I,10:L,11:M,12:P,13:N,15:R,16:j,17:Y,18:$,24:124,30:U,32:W,45:71,46:G,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(ut,s,{5:126}),e(ct,[2,92]),e(ct,[2,94]),e(ct,[2,139]),e(ct,[2,140]),e(ct,[2,141]),e(ct,[2,142]),e(ct,[2,143]),e(ct,[2,144]),e(ct,[2,145]),e(ct,[2,146]),e(ct,[2,147]),e(ct,[2,148]),e(ct,[2,149]),e(ct,[2,97]),e(ct,[2,98]),e(ct,[2,99]),e(ct,[2,100]),e(ct,[2,101]),e(ct,[2,102]),e(ct,[2,103]),e(ct,[2,104]),e(ct,[2,105]),e(ct,[2,106]),e(ct,[2,107]),{13:h,18:d,33:127,35:29,44:30,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(lt,[2,66],{48:128,49:[1,129],65:[1,130]}),{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:131,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:132,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:133,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(ht,[2,79]),e(ht,[2,80]),e(ht,[2,81]),e(ht,[2,82]),e(ht,[2,83]),e(ht,[2,84]),e(ht,[2,85]),e(ht,[2,86]),e(ht,[2,87]),e(ht,[2,88]),e(ht,[2,89]),e(ht,[2,90]),{13:h,18:d,35:134,44:30,45:32,46:p,80:[1,135],81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{78:[1,136],81:[1,137]},{13:h,18:d,35:139,44:30,45:32,46:p,78:[1,138],81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{13:h,18:d,35:140,44:30,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{13:h,18:d,35:141,44:30,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:142,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:144,32:W,38:[1,143],45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:145,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:146,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:147,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(nt,[2,56]),e(it,[2,58]),e(nt,[2,29],{21:148,10:rt}),e(a,[2,11]),e(a,[2,21]),e(a,[2,22]),{9:[1,149]},e(a,[2,12]),e(a,[2,13]),e(a,[2,14]),e(a,[2,15]),e(ut,s,{5:150}),e(ct,[2,93]),{6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,32:[1,151],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(et,[2,41]),e(lt,[2,63],{10:[1,152]}),{10:[1,153]},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:154,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,45:71,46:G,50:V,51:[1,155],52:[1,156],53:[1,157],54:[1,158],60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,45:71,46:G,50:V,56:[1,159],57:[1,160],58:[1,161],59:[1,162],60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,45:71,46:G,50:V,60:H,61:[1,163],62:[1,164],63:[1,165],64:[1,166],66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:[1,167],13:h,18:d,44:114,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:[1,168]},{10:[1,169]},{10:[1,170]},{10:[1,171]},{10:[1,172],13:h,18:d,44:114,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:[1,173],13:h,18:d,44:114,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:[1,174],13:h,18:d,44:114,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,37:[1,175],45:71,46:G,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,31:176,32:W,45:71,46:G,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,39:[1,177],45:71,46:G,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,41:[1,178],45:71,46:G,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,43:[1,179],45:71,46:G,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,37:[1,180],45:71,46:G,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(nt,[2,28]),e(a,[2,23]),{6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,32:[1,181],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(B,[2,37]),e(lt,[2,65]),e(lt,[2,64]),{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,45:71,46:G,50:V,60:H,65:[1,182],66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(lt,[2,67]),e(lt,[2,68]),e(lt,[2,69]),e(lt,[2,70]),e(lt,[2,71]),e(lt,[2,72]),e(lt,[2,73]),e(lt,[2,74]),e(lt,[2,75]),e(lt,[2,76]),e(lt,[2,77]),e(lt,[2,78]),{10:dt,46:ft,71:pt,79:183,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:197,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:198,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:199,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:200,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:201,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{13:h,18:d,35:202,44:30,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},{13:h,18:d,35:203,44:30,45:32,46:p,67:[1,204],81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(nt,[2,43],{21:205,10:rt}),{10:L,12:P,13:N,15:R,16:j,17:Y,18:$,30:U,32:W,39:[1,206],45:71,46:G,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S},e(nt,[2,49],{21:207,10:rt}),e(nt,[2,47],{21:208,10:rt}),e(nt,[2,51],{21:209,10:rt}),e(nt,[2,53],{21:210,10:rt}),e(B,[2,36]),e([10,13,18,46,81,85,87,88,90,91,93,94,95,96,97],[2,91]),e(et,[2,117],{85:wt}),e(kt,[2,122],{86:212,10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,87:vt,88:_t,89:bt,90:At,91:xt}),e(Et,[2,124]),e(Et,[2,126]),e(Et,[2,127]),e(Et,[2,128]),e(Et,[2,129]),e(Et,[2,130]),e(Et,[2,131]),e(Et,[2,132]),e(Et,[2,133]),e(Et,[2,134]),e(Et,[2,135]),e(Et,[2,136]),e(et,[2,118],{85:wt}),e(et,[2,119],{85:wt}),e(et,[2,120],{85:wt}),e(et,[2,110],{85:wt}),e(et,[2,111],{85:wt}),e(et,[2,112],{45:32,44:114,13:h,18:d,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S}),e(et,[2,113],{45:32,44:114,10:[1,213],13:h,18:d,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:C,95:F,96:T,97:S}),e(et,[2,115],{10:[1,214]}),e(nt,[2,44]),{39:[1,215]},e(nt,[2,50]),e(nt,[2,48]),e(nt,[2,52]),e(nt,[2,54]),{10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,84:216,86:185,87:vt,88:_t,89:bt,90:At,91:xt},e(Et,[2,125]),{67:[1,217]},{67:[1,218]},e(nt,[2,45],{21:219,10:rt}),e(kt,[2,123],{86:212,10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,87:vt,88:_t,89:bt,90:At,91:xt}),e(et,[2,114]),e(et,[2,116]),e(nt,[2,46])],defaultActions:{},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[b]&&a[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in a[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],F.$=r[r.length-k],F._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(F,[s,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(F.$),i.push(F._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},Ct=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,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),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;ae[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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:this.begin("string");break;case 2:this.popState();break;case 3:return"STR";case 4:return 71;case 5:return 78;case 6:return 72;case 7:return 73;case 8:return 74;case 9:return 75;case 10:return 12;case 11:return 30;case 12:return 32;case 13:return 13;case 14:return 13;case 15:return 13;case 16:return 13;case 17:return 13;case 18:return 13;case 19:return 81;case 20:return 90;case 21:return 88;case 22:return 8;case 23:return 85;case 24:return 97;case 25:return 16;case 26:return 15;case 27:return 17;case 28:return 18;case 29:return 53;case 30:return 51;case 31:return 52;case 32:return 54;case 33:return 58;case 34:return 56;case 35:return 57;case 36:return 59;case 37:return 58;case 38:return 56;case 39:return 57;case 40:return 59;case 41:return 63;case 42:return 61;case 43:return 62;case 44:return 64;case 45:return 50;case 46:return 55;case 47:return 60;case 48:return 40;case 49:return 41;case 50:return 46;case 51:return 91;case 52:return 95;case 53:return 83;case 54:return 96;case 55:return 96;case 56:return 87;case 57:return 93;case 58:return 94;case 59:return 65;case 60:return 38;case 61:return 39;case 62:return 36;case 63:return 37;case 64:return 42;case 65:return 43;case 66:return 100;case 67:return 9;case 68:return 10;case 69:return 11}},rules:[/^(?:%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:v\b)/,/^(?:\s*--[x]\s*)/,/^(?:\s*-->\s*)/,/^(?:\s*--[o]\s*)/,/^(?:\s*---\s*)/,/^(?:\s*-\.-[x]\s*)/,/^(?:\s*-\.->\s*)/,/^(?:\s*-\.-[o]\s*)/,/^(?:\s*-\.-\s*)/,/^(?:\s*.-[x]\s*)/,/^(?:\s*\.->\s*)/,/^(?:\s*\.-[o]\s*)/,/^(?:\s*\.-\s*)/,/^(?:\s*==[x]\s*)/,/^(?:\s*==>\s*)/,/^(?:\s*==[o]\s*)/,/^(?:\s*==[\=]\s*)/,/^(?:\s*--\s*)/,/^(?:\s*-\.\s*)/,/^(?:\s*==\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[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])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:\n+)/,/^(?:\s)/,/^(?:$)/], -conditions:{string:{rules:[2,3],inclusive:!1},INITIAL:{rules:[0,1,4,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,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69],inclusive:!0}}};return t}();return Dt.lexer=Ct,t.prototype=Dt,Dt.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("_process"))},{_process:3,fs:1,path:2}],118:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),s=t("moment"),o=new a.Log,u="",c="",l=[],h=[],d="";n.clear=function(){l=[],h=[],d="",c="",m=0,f=void 0,p=void 0,A=[]},n.setDateFormat=function(t){u=t},n.getDateFormat=function(){return u},n.setTitle=function(t){c=t},n.getTitle=function(){return c},n.addSection=function(t){d=t,l.push(t)},n.getTasks=function(){for(var t=w(),e=10,n=0;!t&&e>n;)t=w(),n++;return h=A};var f,p,g=function(t,e,r){r=r.trim();var i=/^after\s+([\d\w\-]+)/,a=i.exec(r.trim());if(null!==a){var u=n.findTaskById(a[1]);if("undefined"==typeof u){var c=new Date;return c.setHours(0,0,0,0),c}return u.endTime}return s(r,e.trim(),!0).isValid()?s(r,e.trim(),!0).toDate():(o.debug("Invalid date:"+r),o.debug("With date format:"+e.trim()),new Date)},y=function(t,e,n){if(n=n.trim(),s(n,e.trim(),!0).isValid())return s(n,e.trim()).toDate();var r=s(t),i=/^([\d]+)([wdhms])/,a=i.exec(n.trim());if(null!==a){switch(a[2]){case"s":r.add(a[1],"seconds");break;case"m":r.add(a[1],"minutes");break;case"h":r.add(a[1],"hours");break;case"d":r.add(a[1],"days");break;case"w":r.add(a[1],"weeks")}return r.toDate()}return r.toDate()},m=0,v=function(t){return"undefined"==typeof t?(m+=1,"task"+m):t},_=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;un-e?n+i+1.5*s.sidePadding>o?e+r-5:n+r+5:(n-e)/2+e+r}).attr("y",function(t,r){return r*e+s.barHeight/2+(s.fontSize/2-2)+n}).attr("text-height",i).attr("class",function(t){for(var e=x(t.startTime),n=x(t.endTime),r=this.getBBox().width,i=0,a=0;an-e?n+r+1.5*s.sidePadding>o?"taskTextOutsideLeft taskTextOutside"+i+" "+u:"taskTextOutsideRight taskTextOutside"+i+" "+u:"taskText taskText"+i+" "+u})}function l(t,e,n,a){var o,u=[[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["h1 %I:%M",function(t){return t.getMinutes()}]],c=[["%Y",function(){return!0}]],l=[["%I:%M",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}]];"undefined"!=typeof s.axisFormatter&&(l=[],s.axisFormatter.forEach(function(t){var e=[];e[0]=t[0],e[1]=t[1],l.push(e)})),o=u.concat(l).concat(c);var h=i.svg.axis().scale(x).orient("bottom").tickSize(-a+e+s.gridLineStartPadding,0,0).tickFormat(i.time.format.multi(o));r>7&&230>r&&(h=h.ticks(i.time.monday.range)),_.append("g").attr("class","grid").attr("transform","translate("+t+", "+(a-50)+")").call(h).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em")}function h(t,e){for(var n=[],r=0,i=0;i0))return i[1]*t/2+e;for(var s=0;a>s;s++)return r+=n[a-1][1],i[1]*t/2+r*t+e}).attr("class",function(t){for(var e=0;er;++r)e.hasOwnProperty(t[r])||(e[t[r]]=!0,n.push(t[r]));return n}function p(t){for(var e=t.length,n={};e;)n[t[--e]]=(n[t[e]]||0)+1;return n}function g(t,e){return p(e)[t]||0}n.yy.clear(),n.parse(t);var y=document.getElementById(e);o=y.parentElement.offsetWidth,"undefined"==typeof o&&(o=1200),"undefined"!=typeof s.useWidth&&(o=s.useWidth);var m=n.yy.getTasks(),v=m.length*(s.barHeight+s.barGap)+2*s.topPadding;y.setAttribute("height","100%"),y.setAttribute("viewBox","0 0 "+o+" "+v);var _=i.select("#"+e),b=i.min(m,function(t){return t.startTime}),A=i.max(m,function(t){return t.endTime}),x=i.time.scale().domain([i.min(m,function(t){return t.startTime}),i.max(m,function(t){return t.endTime})]).rangeRound([0,o-150]),w=[];r=a.duration(A-b).asDays();for(var k=0;kl&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],F.$=r[r.length-k],F._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(F,[s,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(F.$),i.push(F._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},u=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,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),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;ae[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 10;case 1:break;case 2:break;case 3:break;case 4:return 4;case 5:return 11;case 6:return"date";case 7:return 12;case 8:return 13;case 9:return 14;case 10:return 15;case 11:return":";case 12:return 6;case 13:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\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:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return t}();return o.lexer=u,t.prototype=o,o.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("_process"))},{_process:3,fs:1,path:2}],121:[function(t,e,n){(function(r){"use strict";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=[2,2],r=[1,5],i=[1,7],a=[1,8],s=[1,11],o=[1,12],u=[1,13],c=[1,14],l=[1,16],h=[1,17],d=[1,7,9,10,14,16,18,19,20,21,22,33],f=[7,9,10,14,16,18,19,20,22,33],p=[1,51],g={trace:function(){},yy:{},symbols_:{error:2,start:3,SD:4,document:5,line:6,SPACE:7,statement:8,NL:9,participant:10,actor:11,signal:12,note_statement:13,title:14,text:15,loop:16,restOfLine:17,end:18,opt:19,alt:20,"else":21,note:22,placement:23,text2:24,over:25,actor_pair:26,spaceList:27,",":28,left_of:29,right_of:30,signaltype:31,actors:32,ACTOR:33,SOLID_OPEN_ARROW:34,DOTTED_OPEN_ARROW:35,SOLID_ARROW:36,DOTTED_ARROW:37,SOLID_CROSS:38,DOTTED_CROSS:39,TXT:40,$accept:0,$end:1},terminals_:{2:"error",4:"SD",7:"SPACE",9:"NL",10:"participant",14:"title",15:"text",16:"loop",17:"restOfLine",18:"end",19:"opt",20:"alt",21:"else",22:"note",25:"over",28:",",29:"left_of",30:"right_of",33:"ACTOR",34:"SOLID_OPEN_ARROW",35:"DOTTED_OPEN_ARROW",36:"SOLID_ARROW",37:"DOTTED_ARROW",38:"SOLID_CROSS",39:"DOTTED_CROSS",40:"TXT"},productions_:[0,[3,2],[5,0],[5,2],[6,2],[6,1],[6,1],[8,3],[8,2],[8,2],[8,4],[8,4],[8,4],[8,7],[13,4],[13,4],[27,2],[27,1],[26,3],[26,1],[23,1],[23,1],[12,4],[32,2],[32,1],[11,1],[31,1],[31,1],[31,1],[31,1],[31,1],[31,1],[24,1]],performAction:function(t,e,n,r,i,a){var s=a.length-1;switch(i){case 1:return r.apply(a[s]),a[s];case 2:this.$=[];break;case 3:a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 5:this.$=a[s];break;case 6:this.$=[];break;case 7:this.$=a[s-1];break;case 11:a[s-1].unshift({type:"loopStart",loopText: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 12:a[s-1].unshift({type:"optStart",optText:a[s-2],signalType:r.LINETYPE.OPT_START}),a[s-1].push({type:"optEnd",optText:a[s-2],signalType:r.LINETYPE.OPT_END}),this.$=a[s-1];break;case 13:a[s-4].unshift({type:"altStart",altText:a[s-5],signalType:r.LINETYPE.ALT_START}),a[s-4].push({type:"else",altText:a[s-2],signalType:r.LINETYPE.ALT_ELSE}),a[s-4]=a[s-4].concat(a[s-1]),a[s-4].push({type:"altEnd",signalType:r.LINETYPE.ALT_END}),this.$=a[s-4];break;case 14:this.$=[a[s-1],{type:"addNote",placement:a[s-2],actor:a[s-1].actor,text:a[s]}];break;case 15: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 18:this.$=[a[s-2],a[s]];break;case 19:this.$=a[s];break;case 20:this.$=r.PLACEMENT.LEFTOF;break;case 21:this.$=r.PLACEMENT.RIGHTOF;break;case 22: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 25:this.$={type:"addActor",actor:a[s]};break;case 26:this.$=r.LINETYPE.SOLID_OPEN;break;case 27:this.$=r.LINETYPE.DOTTED_OPEN;break;case 28:this.$=r.LINETYPE.SOLID;break;case 29:this.$=r.LINETYPE.DOTTED;break;case 30:this.$=r.LINETYPE.SOLID_CROSS;break;case 31:this.$=r.LINETYPE.DOTTED_CROSS;break;case 32:this.$=a[s].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e([1,7,9,10,14,16,19,20,22,33],n,{5:3}),{1:[2,1],6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,22:l,33:h},e(d,[2,3]),{8:18,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,22:l,33:h},e(d,[2,5]),e(d,[2,6]),{11:19,33:h},{9:[1,20]},{9:[1,21]},{7:[1,22]},{17:[1,23]},{17:[1,24]},{17:[1,25]},{31:26,34:[1,27],35:[1,28],36:[1,29],37:[1,30],38:[1,31],39:[1,32]},{23:33,25:[1,34],29:[1,35],30:[1,36]},e([9,28,34,35,36,37,38,39,40],[2,25]),e(d,[2,4]),{9:[1,37]},e(d,[2,8]),e(d,[2,9]),{15:[1,38]},e(f,n,{5:39}),e(f,n,{5:40}),e([7,9,10,14,16,19,20,21,22,33],n,{5:41}),{11:42,33:h},{33:[2,26]},{33:[2,27]},{33:[2,28]},{33:[2,29]},{33:[2,30]},{33:[2,31]},{11:43,33:h},{11:45,26:44,33:h},{33:[2,20]},{33:[2,21]},e(d,[2,7]),{9:[1,46]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,47],19:u,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,48],19:u,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,19:u,20:c,21:[1,49],22:l,33:h},{24:50,40:p},{24:52,40:p},{24:53,40:p},{28:[1,54],40:[2,19]},e(d,[2,10]),e(d,[2,11]),e(d,[2,12]),{17:[1,55]},{9:[2,22]},{9:[2,32]},{9:[2,14]},{9:[2,15]},{11:56,33:h},e(f,n,{5:57}),{40:[2,18]},{6:4,7:r,8:6,9:i,10:a,11:15,12:9,13:10,14:s,16:o,18:[1,58],19:u,20:c,22:l,33:h},e(d,[2,13])],defaultActions:{27:[2,26],28:[2,27],29:[2,28],30:[2,29],31:[2,30],32:[2,31],35:[2,20],36:[2,21],50:[2,22],51:[2,32],52:[2,14],53:[2,15],56:[2,18]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],a=this.table,s="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,C=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},F={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=C()),A=a[b]&&a[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in a[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,s=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],F.$=r[r.length-k],F._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(F._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(F,[s,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(F.$),i.push(F._$),E=a[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},y=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,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),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;ae[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:break;case 2:break;case 3:break;case 4:break;case 5:return 10;case 6:return this.begin("LINE"),16;case 7:return this.begin("LINE"),19;case 8:return this.begin("LINE"),20;case 9:return this.begin("LINE"),21;case 10:return this.popState(),17;case 11:return 18;case 12:return 29;case 13:return 30;case 14:return 25;case 15:return 22;case 16:return 14;case 17:return 4;case 18:return 28;case 19:return 9;case 20:return 33;case 21:return 36;case 22:return 37;case 23:return 34;case 24:return 35;case 25:return 38;case 26:return 39;case 27:return 40;case 28:return 9;case 29:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:participant\b)/i,/^(?:loop\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\->:\n,;]+)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[2,3,10],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29], -inclusive:!0}}};return t}();return g.lexer=y,t.prototype=g,g.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("_process"))},{_process:3,fs:1,path:2}],122:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),s={},o=[],u=[],c=[],l=new a.Log;n.addActor=function(t,e,n){s[t]={name:e,description:n},o.push(t)},n.addMessage=function(t,e,n,r){u.push({from:t,to:e,message:n,answer:r})},n.addSignal=function(t,e,n,r){l.debug("Adding message from="+t+" to="+e+" message="+n+" type="+r),u.push({from:t,to:e,message:n,type:r})},n.getMessages=function(){return u},n.getActors=function(){return s},n.getActor=function(t){return s[t]},n.getActorKeys=function(){return Object.keys(s)},n.clear=function(){s={},u=[]},n.LINETYPE={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},n.ARROWTYPE={FILLED:0,OPEN:1},n.PLACEMENT={LEFTOF:0,RIGHTOF:1,OVER:2},n.addNote=function(t,e,r){var i={actor:t,placement:e,message:r},a=[].concat(t,t);c.push(i),u.push({from:a[0],to:a[1],message:r,type:n.LINETYPE.NOTE,placement:e})},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)},n.apply=function(t){if(t instanceof Array)t.forEach(function(t){n.apply(t)});else switch(t.type){case"addActor":n.addActor(t.actor,t.actor,t.actor);break;case"addNote":n.addNote(t.actor,t.placement,t.text);break;case"addMessage":n.addSignal(t.from,t.to,t.msg,t.signalType);break;case"loopStart":n.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"optStart":n.addSignal(void 0,void 0,t.optText,t.signalType);break;case"optEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"altStart":n.addSignal(void 0,void 0,t.altText,t.signalType);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)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":125}],123:[function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("../../logger"),a=r(i),s=t("./parser/sequenceDiagram").parser;s.yy=t("./sequenceDb");var o=t("./svgDraw"),u=t("../../d3"),c=new a.Log,l={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(o){s++;var u=a.list.length-s+1;a.updateVal(o,"startx",t-u*l.boxMargin,Math.min),a.updateVal(o,"starty",e-u*l.boxMargin,Math.min),a.updateVal(o,"stopx",r+u*l.boxMargin,Math.max),a.updateVal(o,"stopy",i+u*l.boxMargin,Math.max),a.updateVal(n.bounds.data,"startx",t-u*l.boxMargin,Math.min),a.updateVal(n.bounds.data,"starty",e-u*l.boxMargin,Math.min),a.updateVal(n.bounds.data,"stopx",r+u*l.boxMargin,Math.max),a.updateVal(n.bounds.data,"stopy",i+u*l.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 h=function(t,e,r,i,a){var s=o.getNoteRect();s.x=e,s.y=r,s.width=a||l.width,s["class"]="note";var u=t.append("g"),c=o.drawRect(u,s),h=o.getTextObj();h.x=e-4,h.y=r-13,h.textMargin=l.noteMargin,h.dy="1em",h.text=i.message,h["class"]="noteText";var d=o.drawText(u,h,s.width-l.noteMargin),f=d[0][0].getBBox().height;!a&&f>l.width?(d.remove(),u=t.append("g"),d=o.drawText(u,h,2*s.width-l.noteMargin),f=d[0][0].getBBox().height,c.attr("width",2*s.width),n.bounds.insert(e,r,e+2*s.width,r+2*l.noteMargin+f)):n.bounds.insert(e,r,e+s.width,r+2*l.noteMargin+f),c.attr("height",f+2*l.noteMargin),n.bounds.bumpVerticalPos(f+2*l.noteMargin)},d=function(t,e,r,i,a){var o,u=t.append("g"),c=e+(r-e)/2,l=u.append("text").attr("x",c).attr("y",i-7).style("text-anchor","middle").attr("class","messageText").text(a.message);o="undefined"!=typeof l[0][0].getBBox?l[0][0].getBBox().width:l[0][0].getBoundingClientRect();var h;if(e===r){h=u.append("path").attr("d","M "+e+","+i+" C "+(e+60)+","+(i-10)+" "+(e+60)+","+(i+30)+" "+e+","+(i+20)),n.bounds.bumpVerticalPos(30);var d=Math.max(o/2,100);n.bounds.insert(e-d,n.bounds.getVerticalPos()-10,r+d,n.bounds.getVerticalPos())}else h=u.append("line"),h.attr("x1",e),h.attr("y1",i),h.attr("x2",r),h.attr("y2",i),n.bounds.insert(e,n.bounds.getVerticalPos()-10,r,n.bounds.getVerticalPos());a.type===s.yy.LINETYPE.DOTTED||a.type===s.yy.LINETYPE.DOTTED_CROSS||a.type===s.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0");var f=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;f=f.replace(/\(/g,"\\("),f=f.replace(/\)/g,"\\)"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(a.type===s.yy.LINETYPE.SOLID||a.type===s.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+f+"#arrowhead)"),(a.type===s.yy.LINETYPE.SOLID_CROSS||a.type===s.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+f+"#crosshead)")};e.exports.drawActors=function(t,e,r,i){var a;for(a=0;a/gi," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.attr("fill",e.fill),"undefined"!=typeof e["class"]&&i.attr("class",e["class"]);var a=i.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(r),"undefined"!=typeof i.textwrap&&i.textwrap({x:e.x,y:e.y,width:n,height:1800},e.textMargin),i},n.drawLabel=function(t,e){var r=n.getNoteRect();r.x=e.x,r.y=e.y,r.width=50,r.height=20,r.fill="#526e52",r.stroke="none",r["class"]="labelBox",n.drawRect(t,r),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,e.fill="white",n.drawText(t,e)};var r=-1;n.drawActor=function(t,e,i,a,s){var o=e+s.width/2,u=t.append("g");0===i&&(r++,u.append("line").attr("id","actor"+r).attr("x1",o).attr("y1",5).attr("x2",o).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var c=n.getNoteRect();c.x=e,c.y=i,c.fill="#eaeaea",c.width=s.width,c.height=s.height,c["class"]="actor",c.rx=3,c.ry=3,n.drawRect(u,c),u.append("text").attr("x",o).attr("y",i+s.height/2+5).attr("class","actor").style("text-anchor","middle").text(a)},n.drawLoop=function(t,e,r,i){var a=t.append("g"),s=function(t,e,n,r){a.append("line").attr("x1",t).attr("y1",e).attr("x2",n).attr("y2",r).attr("stroke-width",2).attr("stroke","#526e52").attr("class","loopLine")};s(e.startx,e.starty,e.stopx,e.starty),s(e.stopx,e.starty,e.stopx,e.stopy),s(e.startx,e.stopy,e.stopx,e.stopy),s(e.startx,e.starty,e.startx,e.stopy),"undefined"!=typeof e.elsey&&s(e.startx,e.elsey,e.stopx,e.elsey);var o=n.getTextObj();o.text=r,o.x=e.startx,o.y=e.starty,o.labelMargin=1.5*i.boxMargin,o["class"]="labelText",o.fill="white",n.drawLabel(a,o),o=n.getTextObj(),o.text="[ "+e.title+" ]",o.x=e.startx+(e.stopx-e.startx)/2,o.y=e.starty+1.5*i.boxMargin,o.anchor="middle",o["class"]="loopText",n.drawText(a,o),"undefined"!=typeof e.elseText&&(o.text="[ "+e.elseText+" ]",o.y=e.elsey+1.5*i.boxMargin,n.drawText(a,o))},n.insertArrowHead=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")},n.insertArrowCrossHead=function(t){var e=t.append("defs"),n=e.append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);n.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"),n.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")},n.getTextObj=function(){var t={x:0,y:0,fill:"black","text-anchor":"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0};return t},n.getNoteRect=function(){var t={x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0};return t}},{}],125:[function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t){var e=t.getUTCHours(),n=t.getUTCMinutes(),r=t.getSeconds(),i=t.getMilliseconds();10>e&&(e="0"+e),10>n&&(n="0"+n),10>r&&(r="0"+r),100>i&&(i="0"+i),10>i&&(i="00"+i);var a=e+":"+n+":"+r+" ("+i+")";return a}var a=function(){function t(t,e){for(var n=0;n=n&&"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log("["+i(new Date)+"] "+t):void 0}},{key:"trace",value:function(t){this.log(t,s.trace)}},{key:"debug",value:function(t){this.log(t,s.debug)}},{key:"info",value:function(t){this.log(t,s.info)}},{key:"warn",value:function(t){this.log(t,s.warn)}},{key:"error",value:function(t){this.log(t,s.error)}}]),t}();n.Log=u},{}],126:[function(t,e,n){(function(e){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e["default"]=t,e}var i=t("./logger"),a=r(i),s=new a.Log,o=t("./diagrams/flowchart/graphDb"),u=t("./utils"),c=t("./diagrams/flowchart/flowRenderer"),l=t("./diagrams/sequenceDiagram/sequenceRenderer"),h=t("./diagrams/example/exampleRenderer"),d=t("./diagrams/example/parser/example"),f=t("./diagrams/flowchart/parser/flow"),p=t("./diagrams/flowchart/parser/dot"),g=t("./diagrams/sequenceDiagram/parser/sequenceDiagram"),y=t("./diagrams/sequenceDiagram/sequenceDb"),m=t("./diagrams/example/exampleDb"),v=t("./diagrams/gantt/ganttRenderer"),_=t("./diagrams/gantt/parser/gantt"),b=t("./diagrams/gantt/ganttDb"),A=t("./diagrams/classDiagram/parser/classDiagram"),x=t("./diagrams/classDiagram/classRenderer"),w=t("./diagrams/classDiagram/classDb"),k=t("./d3"),E={logLevel:5,cloneCssStyles:!0,startOnLoad:!0,flowchart:{htmlLabels:!0,useMaxWidth:!0},sequenceDiagram:{diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0},gantt:{titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,sidePadding:75,gridLineStartPadding:35,fontSize:11,fontFamily:'"Open-Sans", "sans-serif"',numberSectionStyles:3,axisFormatter:[["%I:%M",function(t){return t.getHours()}],["w. %U",function(t){return 1==t.getDay()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%m-%y",function(t){return t.getMonth()}]]}};a.setLogLevel(E.logLevel);var D=function(t){var e,n=u.detectType(t);switch(n){case"graph":e=f,e.parser.yy=o;break;case"dotGraph":e=p,e.parser.yy=o;break;case"sequenceDiagram":e=g,e.parser.yy=y;break;case"info":e=d,e.parser.yy=m;break;case"gantt":e=_,e.parser.yy=b;break;case"classDiagram":e=A,e.parser.yy=w}try{return e.parse(t),!0}catch(r){return!1}};n.parse=D,n.version=function(){return t("../package.json").version},n.encodeEntities=function(t){var e=t;return e=e.replace(/style.*:\S*#.*;/g,function(t){var e=t.substring(0,t.length-1);return e}),e=e.replace(/classDef.*:\S*#.*;/g,function(t){var e=t.substring(0,t.length-1);return e}),e=e.replace(/#\w+\;/g,function(t){var e=t.substring(1,t.length-1),n=/^\+?\d+$/.test(e);return n?"fl°°"+e+"¶ß":"fl°"+e+"¶ß"})},n.decodeEntities=function(t){var e=t;return e=e.replace(/\fl\°\°/g,function(){return"&#"}),e=e.replace(/\fl\°/g,function(){return"&"}),e=e.replace(/¶ß/g,function(){return";"})};var C=function(t,e,r,i){"undefined"!=typeof i?k.select(i).append("div").attr("id","d"+t).append("svg").attr("id",t).attr("width","100%").attr("xmlns","http://www.w3.org/2000/svg").append("g"):k.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=e,e=n.encodeEntities(e);var a=k.select("#d"+t).node(),d=u.detectType(e),f={};switch(d){case"graph":c.setConf(E.flowchart),c.draw(e,t,!1),E.cloneCssStyles&&(f=c.getClasses(e,!1),u.cloneCssStyles(a.firstChild,f));break;case"dotGraph":c.setConf(E.flowchart),c.draw(e,t,!0),E.cloneCssStyles&&(f=c.getClasses(e,!0),u.cloneCssStyles(a.firstChild,f));break;case"sequenceDiagram":l.setConf(E.sequenceDiagram),l.draw(e,t),E.cloneCssStyles&&u.cloneCssStyles(a.firstChild,[]);break;case"gantt":v.setConf(E.gantt),v.draw(e,t),E.cloneCssStyles&&u.cloneCssStyles(a.firstChild,[]);break;case"classDiagram":x.setConf(E.gantt),x.draw(e,t),E.cloneCssStyles&&u.cloneCssStyles(a.firstChild,[]);break;case"info":h.draw(e,t,n.version()),E.cloneCssStyles&&u.cloneCssStyles(a.firstChild,[])}k.select("#d"+t).selectAll("foreignobject div").attr("xmlns","http://www.w3.org/1999/xhtml");var p=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;p=p.replace(/\(/g,"\\("),p=p.replace(/\)/g,"\\)");var g=k.select("#d"+t).node().innerHTML.replace(/url\(#arrowhead/g,"url("+p+"#arrowhead","g");g=n.decodeEntities(g),"undefined"!=typeof r?r(g,o.bindFunctions):s.warn("CB = undefined");var y=k.select("#d"+t).node();null!==y&&"function"==typeof y.remove&&k.select("#d"+t).node().remove()};n.render=function(t,e,n,r){"undefined"==typeof document||C(t,e,n,r)};var F=function(t){var e,n=Object.keys(t);for(e=0;e0&&(r+=n.selectorText+" { "+n.style.cssText+" }\n")}}catch(l){"undefined"!=typeof n&&s.warn('Invalid CSS selector "'+n.selectorText+'"',l)}var h="",d="";for(var f in e)e.hasOwnProperty(f)&&"undefined"!=typeof f&&("default"===f?(e["default"].styles instanceof Array&&(h+="#"+t.id.trim()+" .node>rect { "+e[f].styles.join("; ")+"; }\n"),e["default"].nodeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .node text { "+e[f].nodeLabelStyles.join("; ")+"; }\n"),e["default"].edgeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .edgeLabel text { "+e[f].edgeLabelStyles.join("; ")+"; }\n"),e["default"].clusterStyles instanceof Array&&(h+="#"+t.id.trim()+" .cluster rect { "+e[f].clusterStyles.join("; ")+"; }\n")):e[f].styles instanceof Array&&(d+="#"+t.id.trim()+" ."+f+">rect { "+e[f].styles.join("; ")+"; }\n"));if(""!==r||""!==h||""!==d){var p=document.createElement("style");p.setAttribute("type","text/css"),p.setAttribute("title","mermaid-svg-internal-css"),p.innerHTML="/* */\n",t.insertBefore(p,t.firstChild)}};n.cloneCssStyles=u},{"./logger":125}]},{},[126])(126)}); \ No newline at end of file +}),B.attr("x",function(){var t=e.x;return r&&(t+=r),t}))}}}u.attr("y",function(){var t=e.y;return s&&(t+=s),r&&(t+=r),t}),u.attr("x",function(){var t=e.x;return r&&(t+=r),t}),i=n.select(o).selectAll("text")};t&&("foreignobjects"==t?l=h:"tspans"==t&&(l=d)),t||(l="undefined"!=typeof SVGForeignObjectElement?h:d);for(var f=0;f "+t.w+": "+JSON.stringify(a.edge(t))),p(i,a.edge(t),a.edge(t).relation)}),i.attr("height","100%"),i.attr("width","100%")}},{"../../d3":106,"../../logger":125,"./classDb":107,"./parser/classDiagram":109,dagre:53}],109:[function(t,e,n){(function(r){"use strict";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,11],r=[1,12],i=[1,13],s=[1,15],a=[1,16],o=[1,17],u=[6,8],c=[1,26],l=[1,27],h=[1,28],d=[1,29],f=[1,30],p=[1,31],g=[6,8,13,17,23,26,27,28,29,30,31],y=[6,8,13,17,23,26,27,28,29,30,31,45,46,47],m=[23,45,46,47],v=[23,30,31,45,46,47],_=[23,26,27,28,29,45,46,47],b=[6,8,13],A=[1,46],x={trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,CLASS_DIAGRAM:5,NEWLINE:6,statements:7,EOF:8,statement:9,className:10,alphaNumToken:11,relationStatement:12,LABEL:13,classStatement:14,methodStatement:15,CLASS:16,STRUCT_START:17,members:18,STRUCT_STOP:19,MEMBER:20,SEPARATOR:21,relation:22,STR:23,relationType:24,lineType:25,AGGREGATION:26,EXTENSION:27,COMPOSITION:28,DEPENDENCY:29,LINE:30,DOTTED_LINE:31,commentToken:32,textToken:33,graphCodeTokens:34,textNoTagsToken:35,TAGSTART:36,TAGEND:37,"==":38,"--":39,PCT:40,DEFAULT:41,SPACE:42,MINUS:43,keywords:44,UNICODE_TEXT:45,NUM:46,ALPHA:47,$accept:0,$end:1},terminals_:{2:"error",5:"CLASS_DIAGRAM",6:"NEWLINE",8:"EOF",13:"LABEL",16:"CLASS",17:"STRUCT_START",19:"STRUCT_STOP",20:"MEMBER",21:"SEPARATOR",23:"STR",26:"AGGREGATION",27:"EXTENSION",28:"COMPOSITION",29:"DEPENDENCY",30:"LINE",31:"DOTTED_LINE",34:"graphCodeTokens",36:"TAGSTART",37:"TAGEND",38:"==",39:"--",40:"PCT",41:"DEFAULT",42:"SPACE",43:"MINUS",44:"keywords",45:"UNICODE_TEXT",46:"NUM",47:"ALPHA"},productions_:[0,[3,1],[4,4],[7,1],[7,3],[10,2],[10,1],[9,1],[9,2],[9,1],[9,1],[14,2],[14,5],[18,1],[18,2],[15,1],[15,2],[15,1],[15,1],[12,3],[12,4],[12,4],[12,5],[22,3],[22,2],[22,2],[22,1],[24,1],[24,1],[24,1],[24,1],[25,1],[25,1],[32,1],[32,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[33,1],[35,1],[35,1],[35,1],[35,1],[11,1],[11,1],[11,1]],performAction:function(t,e,n,r,i,s){var a=s.length-1;switch(i){case 5:this.$=s[a-1]+s[a];break;case 6:this.$=s[a];break;case 7:r.addRelation(s[a]);break;case 8:s[a-1].title=r.cleanupLabel(s[a]),r.addRelation(s[a-1]);break;case 12:r.addMembers(s[a-3],s[a-1]);break;case 13:this.$=[s[a]];break;case 14:s[a].push(s[a-1]),this.$=s[a];break;case 15:break;case 16:r.addMembers(s[a-1],r.cleanupLabel(s[a]));break;case 17:console.warn("Member",s[a]);break;case 18:break;case 19:this.$={id1:s[a-2],id2:s[a],relation:s[a-1],relationTitle1:"none",relationTitle2:"none"};break;case 20:this.$={id1:s[a-3],id2:s[a],relation:s[a-1],relationTitle1:s[a-2],relationTitle2:"none"};break;case 21:this.$={id1:s[a-3],id2:s[a],relation:s[a-2],relationTitle1:"none",relationTitle2:s[a-1]};break;case 22:this.$={id1:s[a-4],id2:s[a],relation:s[a-2],relationTitle1:s[a-3],relationTitle2:s[a-1]};break;case 23:this.$={type1:s[a-2],type2:s[a],lineType:s[a-1]};break;case 24:this.$={type1:"none",type2:s[a],lineType:s[a-1]};break;case 25:this.$={type1:s[a-1],type2:"none",lineType:s[a]};break;case 26:this.$={type1:"none",type2:"none",lineType:s[a]};break;case 27:this.$=r.relationType.AGGREGATION;break;case 28:this.$=r.relationType.EXTENSION;break;case 29:this.$=r.relationType.COMPOSITION;break;case 30:this.$=r.relationType.DEPENDENCY;break;case 31:this.$=r.lineType.LINE;break;case 32:this.$=r.lineType.DOTTED_LINE}},table:[{3:1,4:2,5:[1,3]},{1:[3]},{1:[2,1]},{6:[1,4]},{7:5,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:s,46:a,47:o},{8:[1,18]},{6:[1,19],8:[2,3]},e(u,[2,7],{13:[1,20]}),e(u,[2,9]),e(u,[2,10]),e(u,[2,15],{22:21,24:24,25:25,13:[1,23],23:[1,22],26:c,27:l,28:h,29:d,30:f,31:p}),{10:32,11:14,45:s,46:a,47:o},e(u,[2,17]),e(u,[2,18]),e(g,[2,6],{11:14,10:33,45:s,46:a,47:o}),e(y,[2,46]),e(y,[2,47]),e(y,[2,48]),{1:[2,2]},{7:34,9:6,10:10,11:14,12:7,14:8,15:9,16:n,20:r,21:i,45:s,46:a,47:o},e(u,[2,8]),{10:35,11:14,23:[1,36],45:s,46:a,47:o},{22:37,24:24,25:25,26:c,27:l,28:h,29:d,30:f,31:p},e(u,[2,16]),{25:38,30:f,31:p},e(m,[2,26],{24:39,26:c,27:l,28:h,29:d}),e(v,[2,27]),e(v,[2,28]),e(v,[2,29]),e(v,[2,30]),e(_,[2,31]),e(_,[2,32]),e(u,[2,11],{17:[1,40]}),e(g,[2,5]),{8:[2,4]},e(b,[2,19]),{10:41,11:14,45:s,46:a,47:o},{10:42,11:14,23:[1,43],45:s,46:a,47:o},e(m,[2,25],{24:44,26:c,27:l,28:h,29:d}),e(m,[2,24]),{18:45,20:A},e(b,[2,21]),e(b,[2,20]),{10:47,11:14,45:s,46:a,47:o},e(m,[2,23]),{19:[1,48]},{18:49,19:[2,13],20:A},e(b,[2,22]),e(u,[2,12]),{19:[2,14]}],defaultActions:{2:[2,1],18:[2,2],34:[2,4],49:[2,14]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],s=this.table,a="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,F=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=F()),A=s[b]&&s[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in s[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,a=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(C,[a,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(C.$),i.push(C._$),E=s[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},w=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,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),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 s in i)this[s]=i[s];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(),s=0;se[0].length)){if(e=n,r=s,this.options.backtrack_lexer){if(t=this.test_match(n,i[s]),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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:return 6;case 2:break;case 3:return 5;case 4:return this.begin("struct"),17;case 5:return this.popState(),19;case 6:break;case 7:return"MEMBER";case 8:return 16;case 9:this.begin("string");break;case 10:this.popState();break;case 11:return"STR";case 12:return 27;case 13:return 27;case 14:return 29;case 15:return 29;case 16:return 28;case 17:return 26;case 18:return 30;case 19:return 31;case 20:return 13;case 21:return 43;case 22:return"DOT";case 23:return"PLUS";case 24:return 40;case 25:return"EQUALS";case 26:return"EQUALS";case 27:return 47;case 28:return"PUNCTUATION";case 29:return 46;case 30:return 45;case 31:return 42;case 32:return 8}},rules:[/^(?:%%[^\n]*)/,/^(?:\n+)/,/^(?:\s+)/,/^(?:classDiagram\b)/,/^(?:[\{])/,/^(?:\})/,/^(?:[\n])/,/^(?:[^\{\}\n]*)/,/^(?:class\b)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::[^#\n;]+)/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[A-Za-z]+)/,/^(?:[!"#$%&'*+,-.`?\\_\/])/,/^(?:[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:{string:{rules:[10,11],inclusive:!1},struct:{rules:[5,6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,8,9,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32],inclusive:!0}}};return t}();return x.lexer=w,t.prototype=x,x.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("_process"))},{_process:3,fs:1,path:2}],110:[function(t,e,n){(function(e){"use strict";var r=t("../../logger"),i=new r.Log,s="",a=!1;n.setMessage=function(t){i.debug("Setting message to: "+t),s=t},n.getMessage=function(){return s},n.setInfo=function(t){a=t},n.getInfo=function(){return a},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":125}],111:[function(t,e,n){"use strict";var r=t("./exampleDb"),i=t("./parser/example.js"),s=t("../../d3"),a=t("../../logger"),o=new a.Log;n.draw=function(t,e,n){var a;a=i.parser,a.yy=r,o.debug("Renering example diagram"),a.parse(t);var u=s.select("#"+e),c=u.append("g");c.append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("mermaid "+n),u.attr("height",100),u.attr("width",400)}},{"../../d3":106,"../../logger":125,"./exampleDb":110,"./parser/example.js":112}],112:[function(t,e,n){(function(r){"use strict";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=[6,9,10,12],r={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,message:11,say:12,TXT:13,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo",12:"say",13:"TXT"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1],[8,1],[11,2]],performAction:function(t,e,n,r,i,s){var a=s.length-1;switch(i){case 1:return r;case 4:break;case 6:r.setInfo(!0);break;case 7:r.setMessage(s[a]);break;case 8:this.$=s[a-1].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8],11:9,12:[1,10]},{1:[2,1]},e(n,[2,3]),e(n,[2,4]),e(n,[2,5]),e(n,[2,6]),e(n,[2,7]),{13:[1,11]},e(n,[2,8])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],s=this.table,a="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,F=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=F()),A=s[b]&&s[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in s[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,a=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(C,[a,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(C.$),i.push(C._$),E=s[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},i=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,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),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 s in i)this[s]=i[s];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(),s=0;se[0].length)){if(e=n,r=s,this.options.backtrack_lexer){if(t=this.test_match(n,i[s]),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]),"utf8");return n.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&n.main(r.argv.slice(1)))}).call(this,t("_process"))},{_process:3,fs:1,path:2}],113:[function(t,e){"use strict";var n,r=t("../../logger"),i=new r.Log;if(t)try{n=t("dagre-d3")}catch(s){i.debug("Could not load dagre-d3")}n||(n=window.dagreD3),e.exports=n},{"../../logger":125,"dagre-d3":4}],114:[function(t,e,n){"use strict";var r=t("./graphDb"),i=t("./parser/flow"),s=t("./parser/dot"),a=t("../../d3"),o=t("./dagre-d3"),u=t("../../logger"),c=new u.Log,l={};e.exports.setConf=function(t){var e,n=Object.keys(t);for(e=0;e0&&(a=s.classes.join(" "));var o="";o=r(o,s.styles),i="undefined"==typeof s.text?s.id:s.text;var u="";l.htmlLabels?(u="html",i=i.replace(/fa:fa[\w\-]+/g,function(t){return''})):(i=i.replace(/
/g,"\n"),u="text");var c=0,h="";switch(s.type){case"round":c=5,h="rect";break;case"square":h="rect";break;case"diamond":h="question";break;case"odd":h="rect_left_inv_arrow";break;case"odd_right":h="rect_left_inv_arrow";break;case"circle":h="circle";break;case"ellipse":h="ellipse";break;case"group":h="rect",i="";break;default:h="rect"}e.setNode(s.id,{labelType:u,shape:h,label:i,rx:c,ry:c,"class":a,style:o,id:s.id})})},n.addEdges=function(t,e){var n,r,i=0;"undefined"!=typeof t.defaultStyle&&(r=t.defaultStyle.toString().replace(/,/g,";")),t.forEach(function(t){i++,n="arrow_open"===t.type?"none":"normal";var s="";if("undefined"!=typeof t.style)t.style.forEach(function(t){s=s+t+";"});else switch(t.stroke){case"normal":s="fill:none","undefined"!=typeof r&&(s=r);break;case"dotted":s="stroke: #333; fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":s="stroke: #333; stroke-width: 3.5px;fill:none"}if("undefined"==typeof t.text)"undefined"==typeof t.style?e.setEdge(t.start,t.end,{style:s,arrowhead:n},i):e.setEdge(t.start,t.end,{style:s,arrowheadStyle:"fill: #333",arrowhead:n},i);else{var a=t.text.replace(/
/g,"\n");"undefined"==typeof t.style?l.htmlLabels?e.setEdge(t.start,t.end,{labelType:"html",style:s,labelpos:"c",label:''+t.text+"",arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:"stroke: #333; stroke-width: 1.5px;fill:none",labelpos:"c",label:a,arrowheadStyle:"fill: #333",arrowhead:n},i):e.setEdge(t.start,t.end,{labelType:"text",style:s,arrowheadStyle:"fill: #333",label:a,arrowhead:n},i)}})},n.getClasses=function(t,e){var n;r.clear(),n=e?s.parser:i.parser,n.yy=r,n.parse(t);var a=r.getClasses();return"undefined"==typeof a["default"]&&(a["default"]={id:"default"},a["default"].styles=[],a["default"].clusterStyles=["rx:4px","fill: rgb(255, 255, 222)","rx: 4px","stroke: rgb(170, 170, 51)","stroke-width: 1px"],a["default"].nodeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"],a["default"].edgeLabelStyles=["fill:#000","stroke:none","font-weight:300",'font-family:"Helvetica Neue",Helvetica,Arial,sans-serf',"font-size:14px"]),a},n.draw=function(t,e,u){c.debug("Drawing flowchart");var h;r.clear(),h=u?s.parser:i.parser,h.yy=r;try{h.parse(t)}catch(d){c.debug("Parsing failed")}var f;f=r.getDirection(),"undefined"==typeof f&&(f="TD");var p,g=new o.graphlib.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:f,marginx:20,marginy:20}).setDefaultEdgeLabel(function(){return{}}),y=r.getSubGraphs(),m=0;for(m=y.length-1;m>=0;m--)p=y[m],r.addVertex(p.id,p.title,"group",void 0);var v=r.getVertices(),_=r.getEdges();m=0;var b;for(m=y.length-1;m>=0;m--)for(p=y[m],a.selectAll("cluster").append("text"),b=0;b0?t.split(",").forEach(function(t){"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)}):"undefined"!=typeof vertices[t]&&vertices[t].classes.push(e)};var setTooltip=function(t,e){"undefined"!=typeof e&&(tooltips[t]=e)},setClickFun=function setClickFun(id,functionName){"undefined"!=typeof functionName&&"undefined"!=typeof vertices[id]&&funs.push(function(element){var elem=d3.select(element).select("#"+id);null!==elem&&elem.on("click",function(){eval(functionName+"('"+id+"')")})})},setLink=function(t,e){"undefined"!=typeof e&&"undefined"!=typeof vertices[t]&&funs.push(function(n){var r=d3.select(n).select("#"+t);null!==r&&r.on("click",function(){window.open(e,"newTab")})})};exports.getTooltip=function(t){return tooltips[t]},exports.setClickEvent=function(t,e,n,r){t.indexOf(",")>0?t.split(",").forEach(function(t){setTooltip(t,r),setClickFun(t,e),setLink(t,n)}):(setTooltip(t,r),setClickFun(t,e),setLink(t,n))},exports.bindFunctions=function(t){funs.forEach(function(e){e(t)})},exports.getDirection=function(){return direction},exports.getVertices=function(){return vertices},exports.getEdges=function(){return edges},exports.getClasses=function(){return classes};var setupToolTips=function(t){var e=d3.select(".mermaidTooltip");null===e[0][0]&&(e=d3.select("body").append("div").attr("class","mermaidTooltip").style("opacity",0));var n=d3.select(t).select("svg"),r=n.selectAll("g.node");r.on("mouseover",function(){var t=d3.select(this),n=t.attr("title");if(null!==n){var r=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",r.left+(r.right-r.left)/2+"px").style("top",r.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}}).on("mouseout",function(){e.transition().duration(500).style("opacity",0);var t=d3.select(this);t.classed("hover",!1)})};funs.push(setupToolTips),exports.clear=function(){vertices={},classes={},edges=[],funs=[],funs.push(setupToolTips),subGraphs=[],subCount=0,tooltips=[]},exports.defaultStyle=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},exports.addSubGraph=function(t,e){function n(t){var e={"boolean":{},number:{},string:{}},n=[];return t.filter(function(t){var r=typeof t;return" "===t?!1:r in e?e[r].hasOwnProperty(t)?!1:e[r][t]=!0:n.indexOf(t)>=0?!1:n.push(t)})}var r=[];r=n(r.concat.apply(r,t));var i={id:"subGraph"+subCount,nodes:r,title:e};return subGraphs.push(i),subCount+=1,i.id};var getPosForId=function(t){var e;for(e=0;e2e3)){if(posCrossRef[secCount]=n,subGraphs[n].id===e)return{result:!0,count:0};for(var i=0,s=1;i=0){var o=t(e,a);if(o.result)return{result:!0,count:s+o.count};s+=o.count}i+=1}return{result:!1,count:s}}};exports.getDepthFirstPos=function(t){return posCrossRef[t]},exports.indexNodes=function(){secCount=-1,subGraphs.length>0&&indexNodes("none",subGraphs.length-1,0)},exports.getSubGraphs=function(){return subGraphs},exports.parseError=function(t,e){global.mermaidAPI.parseError(t,e)}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../d3":106,"../../logger":125}],116:[function(t,e,n){(function(r){"use strict";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,5],r=[1,6],i=[1,12],s=[1,13],a=[1,14],o=[1,15],u=[1,16],c=[1,17],l=[1,18],h=[1,19],d=[1,20],f=[1,21],p=[1,22],g=[8,16,17,18,19,20,21,22,23,24,25,26],y=[1,37],m=[1,33],v=[1,34],_=[1,35],b=[1,36],A=[8,10,16,17,18,19,20,21,22,23,24,25,26,28,32,37,39,40,45,57,58],x=[10,28],w=[10,28,37,57,58],k=[2,49],E=[1,45],D=[1,48],F=[1,49],C=[1,52],T=[2,65],S=[1,65],B=[1,66],O=[1,67],I=[1,68],L=[1,69],M=[1,70],N=[1,71],P=[1,72],R=[1,73],j=[8,16,17,18,19,20,21,22,23,24,25,26,47],Y=[10,28,37],$={trace:function(){},yy:{},symbols_:{error:2,expressions:3,graph:4,EOF:5,graphStatement:6,idStatement:7,"{":8,stmt_list:9,"}":10,strict:11,GRAPH:12,DIGRAPH:13,textNoTags:14,textNoTagsToken:15,ALPHA:16,NUM:17,COLON:18,PLUS:19,EQUALS:20,MULT:21,DOT:22,BRKT:23,SPACE:24,MINUS:25,keywords:26,stmt:27,";":28,node_stmt:29,edge_stmt:30,attr_stmt:31,"=":32,subgraph:33,attr_list:34,NODE:35,EDGE:36,"[":37,a_list:38,"]":39,",":40,edgeRHS:41,node_id:42,edgeop:43,port:44,":":45,compass_pt:46,SUBGRAPH:47,n:48,ne:49,e:50,se:51,s:52,sw:53,w:54,nw:55,c:56,ARROW_POINT:57,ARROW_OPEN:58,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",8:"{",10:"}",11:"strict",12:"GRAPH",13:"DIGRAPH",16:"ALPHA",17:"NUM",18:"COLON",19:"PLUS",20:"EQUALS",21:"MULT",22:"DOT",23:"BRKT",24:"SPACE",25:"MINUS",26:"keywords",28:";",32:"=",35:"NODE",36:"EDGE",37:"[",39:"]",40:",",45:":",47:"SUBGRAPH",48:"n",49:"ne",50:"e",51:"se",52:"s",53:"sw",54:"w",55:"nw",56:"c",57:"ARROW_POINT",58:"ARROW_OPEN"},productions_:[0,[3,2],[4,5],[4,6],[4,4],[6,1],[6,1],[7,1],[14,1],[14,2],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[15,1],[9,1],[9,3],[27,1],[27,1],[27,1],[27,3],[27,1],[31,2],[31,2],[31,2],[34,4],[34,3],[34,3],[34,2],[38,5],[38,5],[38,3],[30,3],[30,3],[30,2],[30,2],[41,3],[41,3],[41,2],[41,2],[29,2],[29,1],[42,2],[42,1],[44,4],[44,2],[44,2],[33,5],[33,4],[33,3],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,0],[43,1],[43,1]],performAction:function(t,e,n,r,i,s){var a=s.length-1;switch(i){case 1:this.$=s[a-1];break;case 2:this.$=s[a-4];break;case 3:this.$=s[a-5];break;case 4:this.$=s[a-3];break;case 8:case 10:case 11:this.$=s[a];break;case 9:this.$=s[a-1]+""+s[a];break;case 12:case 13:case 14:case 15:case 16:case 18:case 19:case 20:this.$=s[a];break;case 17:this.$="
";break;case 39:this.$="oy";break;case 40:r.addLink(s[a-1],s[a].id,s[a].op),this.$="oy";break;case 42:r.addLink(s[a-1],s[a].id,s[a].op),this.$={op:s[a-2],id:s[a-1]};break;case 44:this.$={op:s[a-1],id:s[a]};break;case 48:r.addVertex(s[a-1]),this.$=s[a-1];break;case 49:r.addVertex(s[a]),this.$=s[a];break;case 66:this.$="arrow";break;case 67:this.$="arrow_open"}},table:[{3:1,4:2,6:3,11:[1,4],12:n,13:r},{1:[3]},{5:[1,7]},{7:8,8:[1,9],14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{6:23,12:n,13:r},e(g,[2,5]),e(g,[2,6]),{1:[2,1]},{8:[1,24]},{7:30,8:y,9:25,12:m,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},e([8,10,28,32,37,39,40,45,57,58],[2,7],{15:38,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p}),e(A,[2,8]),e(A,[2,10]),e(A,[2,11]),e(A,[2,12]),e(A,[2,13]),e(A,[2,14]),e(A,[2,15]),e(A,[2,16]),e(A,[2,17]),e(A,[2,18]),e(A,[2,19]),e(A,[2,20]),{7:39,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{7:30,8:y,9:40,12:m,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,41]},{10:[2,21],28:[1,42]},e(x,[2,23]),e(x,[2,24]),e(x,[2,25]),e(w,k,{44:44,32:[1,43],45:E}),e(x,[2,27],{41:46,43:47,57:D,58:F}),e(x,[2,47],{43:47,34:50,41:51,37:C,57:D,58:F}),{34:53,37:C},{34:54,37:C},{34:55,37:C},{7:56,8:[1,57],14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{7:30,8:y,9:58,12:m,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},e(A,[2,9]),{8:[1,59]},{10:[1,60]},{5:[2,4]},{7:30,8:y,9:61,12:m,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{7:62,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},e(w,[2,48]),e(w,T,{14:10,15:11,7:63,46:64,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,48:S,49:B,50:O,51:I,52:L,53:M,54:N,55:P,56:R}),e(x,[2,41],{34:74,37:C}),{7:77,8:y,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,33:76,42:75,47:b},e(j,[2,66]),e(j,[2,67]),e(x,[2,46]),e(x,[2,40],{34:78,37:C}),{7:81,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:79,39:[1,80]},e(x,[2,28]),e(x,[2,29]),e(x,[2,30]),{8:[1,82]},{7:30,8:y,9:83,12:m,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,84]},{7:30,8:y,9:85,12:m,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{5:[2,2]},{10:[2,22]},e(x,[2,26]),e(w,[2,51],{45:[1,86]}),e(w,[2,52]),e(w,[2,56]),e(w,[2,57]),e(w,[2,58]),e(w,[2,59]),e(w,[2,60]),e(w,[2,61]),e(w,[2,62]),e(w,[2,63]),e(w,[2,64]),e(x,[2,38]),e(Y,[2,44],{43:47,41:87,57:D,58:F}),e(Y,[2,45],{43:47,41:88,57:D,58:F}),e(w,k,{44:44,45:E}),e(x,[2,39]),{39:[1,89]},e(x,[2,34],{34:90,37:C}),{32:[1,91]},{7:30,8:y,9:92,12:m,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,27:26,29:27,30:28,31:29,33:31,35:v,36:_,42:32,47:b},{10:[1,93]},e(w,[2,55]),{10:[1,94]},e(w,T,{46:95,48:S,49:B,50:O,51:I,52:L,53:M,54:N,55:P,56:R}),e(Y,[2,42]),e(Y,[2,43]),e(x,[2,33],{34:96,37:C}),e(x,[2,32]),{7:97,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p},{10:[1,98]},e(w,[2,54]),{5:[2,3]},e(w,[2,50]),e(x,[2,31]),{28:[1,99],39:[2,37],40:[1,100]},e(w,[2,53]),{7:81,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:101},{7:81,14:10,15:11,16:i,17:s,18:a,19:o,20:u,21:c,22:l,23:h,24:d,25:f,26:p,38:102},{39:[2,35]},{39:[2,36]}],defaultActions:{7:[2,1],41:[2,4],60:[2,2],61:[2,22],94:[2,3],101:[2,35],102:[2,36]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],s=this.table,a="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,F=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=F()),A=s[b]&&s[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in s[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,a=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(C,[a,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(C.$),i.push(C._$),E=s[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},U=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,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),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 s in i)this[s]=i[s];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(),s=0;se[0].length)){if(e=n,r=s,this.options.backtrack_lexer){if(t=this.test_match(n,i[s]),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:{},performAction:function(t,e,n,r){switch(n){case 0:return"STYLE";case 1:return"LINKSTYLE";case 2:return"CLASSDEF";case 3:return"CLASS";case 4:return"CLICK";case 5:return 12;case 6:return 13;case 7:return 47;case 8:return 35;case 9:return 36;case 10:return"DIR";case 11:return"DIR";case 12:return"DIR";case 13:return"DIR";case 14:return"DIR";case 15:return"DIR";case 16:return 17;case 17:return 23;case 18:return 18;case 19:return 28;case 20:return 40;case 21:return 32;case 22:return 21;case 23:return 22;case 24:return"ARROW_CROSS";case 25:return 57;case 26:return"ARROW_CIRCLE";case 27:return 58;case 28:return 25;case 29:return 19;case 30:return 20;case 31:return 16;case 32:return"PIPE";case 33:return"PS";case 34:return"PE";case 35:return 37;case 36:return 39;case 37:return 8;case 38:return 10;case 39:return"QUOTE";case 40:return 24;case 41:return"NEWLINE";case 42:return 5}},rules:[/^(?:style\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:digraph\b)/,/^(?:subgraph\b)/,/^(?:node\b)/,/^(?:edge\b)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9])/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:=)/,/^(?:\*)/,/^(?:\.)/,/^(?:--[x])/,/^(?:->)/,/^(?:--[o])/,/^(?:--)/,/^(?:-)/,/^(?:\+)/,/^(?:=)/,/^(?:[\u0021-\u0027\u002A-\u002E\u003F\u0041-\u005A\u0061-\u007A\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)/,/^(?:\n)/,/^(?:$)/], +conditions:{INITIAL:{rules:[0,1,2,3,4,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],inclusive:!0}}};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("_process"))},{_process:3,fs:1,path:2}],117:[function(t,e,n){(function(r){"use strict";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],s=[1,8,9,10,11,13,18,30,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],a=[2,2],o=[1,12],u=[1,13],c=[1,14],l=[1,15],h=[1,31],d=[1,33],f=[1,22],p=[1,34],g=[1,24],y=[1,25],m=[1,26],v=[1,27],_=[1,28],b=[1,38],A=[1,40],x=[1,35],w=[1,39],k=[1,45],E=[1,44],D=[1,36],F=[1,37],C=[1,41],T=[1,42],S=[1,43],B=[1,8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],O=[1,53],I=[1,52],L=[1,54],M=[1,72],N=[1,80],P=[1,81],R=[1,66],j=[1,65],Y=[1,85],$=[1,84],U=[1,82],G=[1,83],W=[1,73],V=[1,68],H=[1,67],z=[1,63],q=[1,75],X=[1,76],Z=[1,77],K=[1,78],Q=[1,79],J=[1,70],tt=[1,69],et=[8,9,11],nt=[8,9,11,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64],rt=[1,115],it=[8,9,10,11,13,15,18,36,38,40,42,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,85,87,88,90,91,93,94,95,96,97],st=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,42,43,46,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],at=[1,117],ot=[1,118],ut=[8,9,10,11,13,18,30,32,46,71,72,73,74,75,81,85,87,88,90,91,93,94,95,96,97],ct=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,43,46,50,51,52,53,54,56,57,58,59,60,61,62,63,64,65,71,72,73,74,75,78,81,83,85,87,88,90,91,93,94,95,96,97],lt=[13,18,46,81,85,87,88,90,91,93,94,95,96,97],ht=[13,18,46,49,65,81,85,87,88,90,91,93,94,95,96,97],dt=[1,191],ft=[1,188],pt=[1,195],gt=[1,192],yt=[1,189],mt=[1,196],vt=[1,186],_t=[1,187],bt=[1,190],At=[1,193],xt=[1,194],wt=[1,211],kt=[8,9,11,85],Et=[8,9,10,11,46,71,80,81,83,85,87,88,89,90,91],Dt={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,"(-":40,"-)":41,DIAMOND_START:42,DIAMOND_STOP:43,alphaNumStatement:44,alphaNumToken:45,MINUS:46,linkStatement:47,arrowText:48,TESTSTR:49,"--":50,ARROW_POINT:51,ARROW_CIRCLE:52,ARROW_CROSS:53,ARROW_OPEN:54,"-.":55,DOTTED_ARROW_POINT:56,DOTTED_ARROW_CIRCLE:57,DOTTED_ARROW_CROSS:58,DOTTED_ARROW_OPEN:59,"==":60,THICK_ARROW_POINT:61,THICK_ARROW_CIRCLE:62,THICK_ARROW_CROSS:63,THICK_ARROW_OPEN:64,PIPE:65,textToken:66,STR:67,commentText:68,commentToken:69,keywords:70,STYLE:71,LINKSTYLE:72,CLASSDEF:73,CLASS:74,CLICK:75,textNoTags:76,textNoTagsToken:77,DEFAULT:78,stylesOpt:79,HEX:80,NUM:81,commentStatement:82,PCT:83,style:84,COMMA:85,styleComponent:86,ALPHA:87,COLON:88,UNIT:89,BRKT:90,DOT:91,graphCodeTokens:92,PUNCTUATION:93,UNICODE_TEXT:94,PLUS:95,EQUALS:96,MULT:97,TAG_START:98,TAG_END:99,QUOTE:100,$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:"(-",41:"-)",42:"DIAMOND_START",43:"DIAMOND_STOP",46:"MINUS",49:"TESTSTR",50:"--",51:"ARROW_POINT",52:"ARROW_CIRCLE",53:"ARROW_CROSS",54:"ARROW_OPEN",55:"-.",56:"DOTTED_ARROW_POINT",57:"DOTTED_ARROW_CIRCLE",58:"DOTTED_ARROW_CROSS",59:"DOTTED_ARROW_OPEN",60:"==",61:"THICK_ARROW_POINT",62:"THICK_ARROW_CIRCLE",63:"THICK_ARROW_CROSS",64:"THICK_ARROW_OPEN",65:"PIPE",67:"STR",71:"STYLE",72:"LINKSTYLE",73:"CLASSDEF",74:"CLASS",75:"CLICK",78:"DEFAULT",80:"HEX",81:"NUM",83:"PCT",85:"COMMA",87:"ALPHA",88:"COLON",89:"UNIT",90:"BRKT",91:"DOT",93:"PUNCTUATION",94:"UNICODE_TEXT",95:"PLUS",96:"EQUALS",97:"MULT",98:"TAG_START",99:"TAG_END",100:"QUOTE"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,4],[4,4],[4,4],[4,4],[4,4],[19,2],[19,1],[20,1],[20,1],[20,1],[14,1],[14,1],[14,2],[22,2],[22,2],[22,1],[22,1],[21,2],[21,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,5],[7,4],[24,1],[24,1],[24,1],[23,3],[23,1],[33,4],[33,5],[33,6],[33,7],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,4],[33,5],[33,1],[33,2],[35,1],[35,2],[44,1],[44,1],[44,1],[44,1],[34,2],[34,3],[34,3],[34,1],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[34,3],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[47,1],[48,3],[31,1],[31,2],[31,1],[68,1],[68,2],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[70,1],[76,1],[76,2],[27,5],[27,5],[28,5],[29,5],[29,7],[29,5],[29,7],[25,5],[25,5],[26,5],[26,5],[82,3],[79,1],[79,3],[84,1],[84,2],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[69,1],[69,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[66,1],[77,1],[77,1],[77,1],[77,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[45,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1]],performAction:function(t,e,n,r,i,s){var a=s.length-1;switch(i){case 2:this.$=[];break;case 3:s[a]!==[]&&s[a-1].push(s[a]),this.$=s[a-1];break;case 4:case 57:case 59:case 60:case 92:case 94:case 95:case 108:this.$=s[a];break;case 11:r.setDirection(s[a-1]),this.$=s[a-1];break;case 12:r.setDirection("LR"),this.$=s[a-1];break;case 13:r.setDirection("RL"),this.$=s[a-1];break;case 14:r.setDirection("BT"),this.$=s[a-1];break;case 15:r.setDirection("TB"),this.$=s[a-1];break;case 30:this.$=s[a-1];break;case 31:case 32:case 33:case 34:case 35:this.$=[];break;case 36:this.$=r.addSubGraph(s[a-1],s[a-3]);break;case 37:this.$=r.addSubGraph(s[a-1],void 0);break;case 41:r.addLink(s[a-2],s[a],s[a-1]),this.$=[s[a-2],s[a]];break;case 42:this.$=[s[a]];break;case 43:this.$=s[a-3],r.addVertex(s[a-3],s[a-1],"square");break;case 44:this.$=s[a-4],r.addVertex(s[a-4],s[a-2],"square");break;case 45:this.$=s[a-5],r.addVertex(s[a-5],s[a-2],"circle");break;case 46:this.$=s[a-6],r.addVertex(s[a-6],s[a-3],"circle");break;case 47:this.$=s[a-3],r.addVertex(s[a-3],s[a-1],"ellipse");break;case 48:this.$=s[a-4],r.addVertex(s[a-4],s[a-2],"ellipse");break;case 49:this.$=s[a-3],r.addVertex(s[a-3],s[a-1],"round");break;case 50:this.$=s[a-4],r.addVertex(s[a-4],s[a-2],"round");break;case 51:this.$=s[a-3],r.addVertex(s[a-3],s[a-1],"diamond");break;case 52:this.$=s[a-4],r.addVertex(s[a-4],s[a-2],"diamond");break;case 53:this.$=s[a-3],r.addVertex(s[a-3],s[a-1],"odd");break;case 54:this.$=s[a-4],r.addVertex(s[a-4],s[a-2],"odd");break;case 55:this.$=s[a],r.addVertex(s[a]);break;case 56:this.$=s[a-1],r.addVertex(s[a-1]);break;case 58:case 93:case 96:case 109:this.$=s[a-1]+""+s[a];break;case 61:this.$="v";break;case 62:this.$="-";break;case 63:s[a-1].text=s[a],this.$=s[a-1];break;case 64:case 65:s[a-2].text=s[a-1],this.$=s[a-2];break;case 66:this.$=s[a];break;case 67:this.$={type:"arrow",stroke:"normal",text:s[a-1]};break;case 68:this.$={type:"arrow_circle",stroke:"normal",text:s[a-1]};break;case 69:this.$={type:"arrow_cross",stroke:"normal",text:s[a-1]};break;case 70:this.$={type:"arrow_open",stroke:"normal",text:s[a-1]};break;case 71:this.$={type:"arrow",stroke:"dotted",text:s[a-1]};break;case 72:this.$={type:"arrow_circle",stroke:"dotted",text:s[a-1]};break;case 73:this.$={type:"arrow_cross",stroke:"dotted",text:s[a-1]};break;case 74:this.$={type:"arrow_open",stroke:"dotted",text:s[a-1]};break;case 75:this.$={type:"arrow",stroke:"thick",text:s[a-1]};break;case 76:this.$={type:"arrow_circle",stroke:"thick",text:s[a-1]};break;case 77:this.$={type:"arrow_cross",stroke:"thick",text:s[a-1]};break;case 78:this.$={type:"arrow_open",stroke:"thick",text:s[a-1]};break;case 79:this.$={type:"arrow",stroke:"normal"};break;case 80:this.$={type:"arrow_circle",stroke:"normal"};break;case 81:this.$={type:"arrow_cross",stroke:"normal"};break;case 82:this.$={type:"arrow_open",stroke:"normal"};break;case 83:this.$={type:"arrow",stroke:"dotted"};break;case 84:this.$={type:"arrow_circle",stroke:"dotted"};break;case 85:this.$={type:"arrow_cross",stroke:"dotted"};break;case 86:this.$={type:"arrow_open",stroke:"dotted"};break;case 87:this.$={type:"arrow",stroke:"thick"};break;case 88:this.$={type:"arrow_circle",stroke:"thick"};break;case 89:this.$={type:"arrow_cross",stroke:"thick"};break;case 90:this.$={type:"arrow_open",stroke:"thick"};break;case 91:this.$=s[a-1];break;case 110:case 111:this.$=s[a-4],r.addClass(s[a-2],s[a]);break;case 112:this.$=s[a-4],r.setClass(s[a-2],s[a]);break;case 113:this.$=s[a-4],r.setClickEvent(s[a-2],s[a],void 0,void 0);break;case 114:this.$=s[a-6],r.setClickEvent(s[a-4],s[a-2],void 0,s[a]);break;case 115:this.$=s[a-4],r.setClickEvent(s[a-2],void 0,s[a],void 0);break;case 116:this.$=s[a-6],r.setClickEvent(s[a-4],void 0,s[a-2],s[a]);break;case 117:this.$=s[a-4],r.addVertex(s[a-2],void 0,void 0,s[a]);break;case 118:case 119:case 120:this.$=s[a-4],r.updateLink(s[a-2],s[a]);break;case 122:this.$=[s[a]];break;case 123:s[a-2].push(s[a]),this.$=s[a-2];break;case 125:this.$=s[a-1]+s[a]}},table:[{3:1,4:2,9:n,10:r,12:i},{1:[3]},e(s,a,{5:6}),{4:7,9:n,10:r,12:i},{4:8,9:n,10:r,12:i},{10:[1,9]},{1:[2,1],6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(s,[2,9]),e(s,[2,10]),{13:[1,46],15:[1,47],16:[1,48],17:[1,49],18:[1,50]},e(B,[2,3]),e(B,[2,4]),e(B,[2,5]),e(B,[2,6]),e(B,[2,7]),e(B,[2,8]),{8:O,9:I,11:L,24:51},{8:O,9:I,11:L,24:55},{8:O,9:I,11:L,24:56},{8:O,9:I,11:L,24:57},{8:O,9:I,11:L,24:58},{8:O,9:I,11:L,24:59},{8:O,9:I,10:M,11:L,12:N,13:P,15:R,16:j,17:Y,18:$,24:61,30:U,31:60,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(et,[2,42],{34:86,47:87,50:[1,88],51:[1,91],52:[1,92],53:[1,93],54:[1,94],55:[1,89],56:[1,95],57:[1,96],58:[1,97],59:[1,98],60:[1,90],61:[1,99],62:[1,100],63:[1,101],64:[1,102]}),{10:[1,103]},{10:[1,104]},{10:[1,105]},{10:[1,106]},{10:[1,107]},e(nt,[2,55],{45:32,21:113,44:114,10:rt,13:h,15:[1,112],18:d,36:[1,108],38:[1,109],40:[1,110],42:[1,111],46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S}),e(it,[2,57]),e(it,[2,59]),e(it,[2,60]),e(it,[2,61]),e(it,[2,62]),e(st,[2,150]),e(st,[2,151]),e(st,[2,152]),e(st,[2,153]),e(st,[2,154]),e(st,[2,155]),e(st,[2,156]),e(st,[2,157]),e(st,[2,158]),e(st,[2,159]),e(st,[2,160]),{8:at,9:ot,10:rt,14:116,21:119},{8:at,9:ot,10:rt,14:120,21:119},{8:at,9:ot,10:rt,14:121,21:119},{8:at,9:ot,10:rt,14:122,21:119},{8:at,9:ot,10:rt,14:123,21:119},e(B,[2,30]),e(B,[2,38]),e(B,[2,39]),e(B,[2,40]),e(B,[2,31]),e(B,[2,32]),e(B,[2,33]),e(B,[2,34]),e(B,[2,35]),{8:O,9:I,10:M,11:L,12:N,13:P,15:R,16:j,17:Y,18:$,24:124,30:U,32:G,45:71,46:W,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(ut,a,{5:126}),e(ct,[2,92]),e(ct,[2,94]),e(ct,[2,139]),e(ct,[2,140]),e(ct,[2,141]),e(ct,[2,142]),e(ct,[2,143]),e(ct,[2,144]),e(ct,[2,145]),e(ct,[2,146]),e(ct,[2,147]),e(ct,[2,148]),e(ct,[2,149]),e(ct,[2,97]),e(ct,[2,98]),e(ct,[2,99]),e(ct,[2,100]),e(ct,[2,101]),e(ct,[2,102]),e(ct,[2,103]),e(ct,[2,104]),e(ct,[2,105]),e(ct,[2,106]),e(ct,[2,107]),{13:h,18:d,33:127,35:29,44:30,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(lt,[2,66],{48:128,49:[1,129],65:[1,130]}),{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:131,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:132,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:133,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(ht,[2,79]),e(ht,[2,80]),e(ht,[2,81]),e(ht,[2,82]),e(ht,[2,83]),e(ht,[2,84]),e(ht,[2,85]),e(ht,[2,86]),e(ht,[2,87]),e(ht,[2,88]),e(ht,[2,89]),e(ht,[2,90]),{13:h,18:d,35:134,44:30,45:32,46:p,80:[1,135],81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{78:[1,136],81:[1,137]},{13:h,18:d,35:139,44:30,45:32,46:p,78:[1,138],81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{13:h,18:d,35:140,44:30,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{13:h,18:d,35:141,44:30,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:142,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:144,32:G,38:[1,143],45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:145,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:146,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:147,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(nt,[2,56]),e(it,[2,58]),e(nt,[2,29],{21:148,10:rt}),e(s,[2,11]),e(s,[2,21]),e(s,[2,22]),{9:[1,149]},e(s,[2,12]),e(s,[2,13]),e(s,[2,14]),e(s,[2,15]),e(ut,a,{5:150}),e(ct,[2,93]),{6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,32:[1,151],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(et,[2,41]),e(lt,[2,63],{10:[1,152]}),{10:[1,153]},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:154,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,45:71,46:W,50:V,51:[1,155],52:[1,156],53:[1,157],54:[1,158],60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,45:71,46:W,50:V,56:[1,159],57:[1,160],58:[1,161],59:[1,162],60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,45:71,46:W,50:V,60:H,61:[1,163],62:[1,164],63:[1,165],64:[1,166],66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:[1,167],13:h,18:d,44:114,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:[1,168]},{10:[1,169]},{10:[1,170]},{10:[1,171]},{10:[1,172],13:h,18:d,44:114,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:[1,173],13:h,18:d,44:114,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:[1,174],13:h,18:d,44:114,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,37:[1,175],45:71,46:W,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,31:176,32:G,45:71,46:W,50:V,60:H,66:62,67:z,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,39:[1,177],45:71,46:W,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,41:[1,178],45:71,46:W,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,43:[1,179],45:71,46:W,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,37:[1,180],45:71,46:W,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(nt,[2,28]),e(s,[2,23]),{6:10,7:11,8:o,9:u,10:c,11:l,13:h,18:d,23:16,25:17,26:18,27:19,28:20,29:21,30:f,32:[1,181],33:23,35:29,44:30,45:32,46:p,71:g,72:y,73:m,74:v,75:_,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(B,[2,37]),e(lt,[2,65]),e(lt,[2,64]),{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,45:71,46:W,50:V,60:H,65:[1,182],66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(lt,[2,67]),e(lt,[2,68]),e(lt,[2,69]),e(lt,[2,70]),e(lt,[2,71]),e(lt,[2,72]),e(lt,[2,73]),e(lt,[2,74]),e(lt,[2,75]),e(lt,[2,76]),e(lt,[2,77]),e(lt,[2,78]),{10:dt,46:ft,71:pt,79:183,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:197,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:198,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:199,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:200,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{10:dt,46:ft,71:pt,79:201,80:gt,81:yt,83:mt,84:184,86:185,87:vt,88:_t,89:bt,90:At,91:xt},{13:h,18:d,35:202,44:30,45:32,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},{13:h,18:d,35:203,44:30,45:32,46:p,67:[1,204],81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(nt,[2,43],{21:205,10:rt}),{10:M,12:N,13:P,15:R,16:j,17:Y,18:$,30:U,32:G,39:[1,206],45:71,46:W,50:V,60:H,66:125,70:74,71:q,72:X,73:Z,74:K,75:Q,77:64,78:J,81:b,83:tt,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S},e(nt,[2,49],{21:207,10:rt}),e(nt,[2,47],{21:208,10:rt}),e(nt,[2,51],{21:209,10:rt}),e(nt,[2,53],{21:210,10:rt}),e(B,[2,36]),e([10,13,18,46,81,85,87,88,90,91,93,94,95,96,97],[2,91]),e(et,[2,117],{85:wt}),e(kt,[2,122],{86:212,10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,87:vt,88:_t,89:bt,90:At,91:xt}),e(Et,[2,124]),e(Et,[2,126]),e(Et,[2,127]),e(Et,[2,128]),e(Et,[2,129]),e(Et,[2,130]),e(Et,[2,131]),e(Et,[2,132]),e(Et,[2,133]),e(Et,[2,134]),e(Et,[2,135]),e(Et,[2,136]),e(et,[2,118],{85:wt}),e(et,[2,119],{85:wt}),e(et,[2,120],{85:wt}),e(et,[2,110],{85:wt}),e(et,[2,111],{85:wt}),e(et,[2,112],{45:32,44:114,13:h,18:d,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S}),e(et,[2,113],{45:32,44:114,10:[1,213],13:h,18:d,46:p,81:b,85:A,87:x,88:w,90:k,91:E,93:D,94:F,95:C,96:T,97:S}),e(et,[2,115],{10:[1,214]}),e(nt,[2,44]),{39:[1,215]},e(nt,[2,50]),e(nt,[2,48]),e(nt,[2,52]),e(nt,[2,54]),{10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,84:216,86:185,87:vt,88:_t,89:bt,90:At,91:xt},e(Et,[2,125]),{67:[1,217]},{67:[1,218]},e(nt,[2,45],{21:219,10:rt}),e(kt,[2,123],{86:212,10:dt,46:ft,71:pt,80:gt,81:yt,83:mt,87:vt,88:_t,89:bt,90:At,91:xt}),e(et,[2,114]),e(et,[2,116]),e(nt,[2,46])],defaultActions:{},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],s=this.table,a="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,F=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=F()),A=s[b]&&s[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in s[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,a=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(C,[a,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(C.$),i.push(C._$),E=s[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},Ft=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,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),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 s in i)this[s]=i[s];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(),s=0;se[0].length)){if(e=n,r=s,this.options.backtrack_lexer){if(t=this.test_match(n,i[s]),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:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:this.begin("string");break;case 2:this.popState();break;case 3:return"STR";case 4:return 71;case 5:return 78;case 6:return 72;case 7:return 73;case 8:return 74;case 9:return 75;case 10:return 12;case 11:return 30;case 12:return 32;case 13:return 13;case 14:return 13;case 15:return 13;case 16:return 13;case 17:return 13;case 18:return 13;case 19:return 81;case 20:return 90;case 21:return 88;case 22:return 8;case 23:return 85;case 24:return 97;case 25:return 16;case 26:return 15;case 27:return 17;case 28:return 18;case 29:return 53;case 30:return 51;case 31:return 52;case 32:return 54;case 33:return 58;case 34:return 56;case 35:return 57;case 36:return 59;case 37:return 58;case 38:return 56;case 39:return 57;case 40:return 59;case 41:return 63;case 42:return 61;case 43:return 62;case 44:return 64;case 45:return 50;case 46:return 55;case 47:return 60;case 48:return 40;case 49:return 41;case 50:return 46;case 51:return 91;case 52:return 95;case 53:return 83;case 54:return 96;case 55:return 96;case 56:return 87;case 57:return 93;case 58:return 94;case 59:return 65;case 60:return 38;case 61:return 39;case 62:return 36;case 63:return 37;case 64:return 42;case 65:return 43;case 66:return 100;case 67:return 9;case 68:return 10;case 69:return 11}},rules:[/^(?:%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:click\b)/,/^(?:graph\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:LR\b)/,/^(?:RL\b)/,/^(?:TB\b)/,/^(?:BT\b)/,/^(?:TD\b)/,/^(?:BR\b)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:v\b)/,/^(?:\s*--[x]\s*)/,/^(?:\s*-->\s*)/,/^(?:\s*--[o]\s*)/,/^(?:\s*---\s*)/,/^(?:\s*-\.-[x]\s*)/,/^(?:\s*-\.->\s*)/,/^(?:\s*-\.-[o]\s*)/,/^(?:\s*-\.-\s*)/,/^(?:\s*.-[x]\s*)/,/^(?:\s*\.->\s*)/,/^(?:\s*\.-[o]\s*)/,/^(?:\s*\.-\s*)/,/^(?:\s*==[x]\s*)/,/^(?:\s*==>\s*)/,/^(?:\s*==[o]\s*)/,/^(?:\s*==[\=]\s*)/,/^(?:\s*--\s*)/,/^(?:\s*-\.\s*)/,/^(?:\s*==\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:[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])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:\n+)/,/^(?:\s)/,/^(?:$)/], +conditions:{string:{rules:[2,3],inclusive:!1},INITIAL:{rules:[0,1,4,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,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69],inclusive:!0}}};return t}();return Dt.lexer=Ft,t.prototype=Dt,Dt.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("_process"))},{_process:3,fs:1,path:2}],118:[function(t,e,n){(function(e){"use strict";var r=t("moment"),i=t("../../logger"),s=new i.Log,a="",o="",u=[],c=[],l="";n.clear=function(){u=[],c=[],l="",o="",g=0,h=void 0,d=void 0,_=[]},n.setDateFormat=function(t){a=t},n.getDateFormat=function(){return a},n.setTitle=function(t){o=t},n.getTitle=function(){return o},n.addSection=function(t){l=t,u.push(t)},n.getTasks=function(){for(var t=A(),e=10,n=0;!t&&e>n;)t=A(),n++;return c=_};var h,d,f=function(t,e,i){i=i.trim();var a=/^after\s+([\d\w\-]+)/,o=a.exec(i.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(i,e.trim(),!0).isValid()?r(i,e.trim(),!0).toDate():(s.debug("Invalid date:"+i),s.debug("With date format:"+e.trim()),new Date)},p=function(t,e,n){if(n=n.trim(),r(n,e.trim(),!0).isValid())return r(n,e.trim()).toDate();var i=r(t),s=/^([\d]+)([wdhms])/,a=s.exec(n.trim());if(null!==a){switch(a[2]){case"s":i.add(a[1],"seconds");break;case"m":i.add(a[1],"minutes");break;case"h":i.add(a[1],"hours");break;case"d":i.add(a[1],"days");break;case"w":i.add(a[1],"weeks")}return i.toDate()}return i.toDate()},g=0,y=function(t){return"undefined"==typeof t?(g+=1,"task"+g):t},m=function(t,e){var r;r=":"===e.substr(0,1)?e.substr(1,e.length):e;for(var i=r.split(","),s={},a=n.getDateFormat(),o=!0;o;)o=!1,i[0].match(/^\s*active\s*$/)&&(s.active=!0,i.shift(1),o=!0),i[0].match(/^\s*done\s*$/)&&(s.done=!0,i.shift(1),o=!0),i[0].match(/^\s*crit\s*$/)&&(s.crit=!0,i.shift(1),o=!0);var u;for(u=0;un-e?n+i+1.5*a.sidePadding>o?e+r-5:n+r+5:(n-e)/2+e+r}).attr("y",function(t,r){return r*e+a.barHeight/2+(a.fontSize/2-2)+n}).attr("text-height",i).attr("class",function(t){for(var e=x(t.startTime),n=x(t.endTime),r=this.getBBox().width,i=0,s=0;sn-e?n+r+1.5*a.sidePadding>o?"taskTextOutsideLeft taskTextOutside"+i+" "+u:"taskTextOutsideRight taskTextOutside"+i+" "+u:"taskText taskText"+i+" "+u})}function l(t,e,n,s){var o,u=[[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["h1 %I:%M",function(t){return t.getMinutes()}]],c=[["%Y",function(){return!0}]],l=[["%I:%M",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}]];"undefined"!=typeof a.axisFormatter&&(l=[],a.axisFormatter.forEach(function(t){var e=[];e[0]=t[0],e[1]=t[1],l.push(e)})),o=u.concat(l).concat(c);var h=i.svg.axis().scale(x).orient("bottom").tickSize(-s+e+a.gridLineStartPadding,0,0).tickFormat(i.time.format.multi(o));r>7&&230>r&&(h=h.ticks(i.time.monday.range)),_.append("g").attr("class","grid").attr("transform","translate("+t+", "+(s-50)+")").call(h).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em")}function h(t,e){for(var n=[],r=0,i=0;i0))return i[1]*t/2+e;for(var a=0;s>a;a++)return r+=n[s-1][1],i[1]*t/2+r*t+e}).attr("class",function(t){for(var e=0;er;++r)e.hasOwnProperty(t[r])||(e[t[r]]=!0,n.push(t[r]));return n}function p(t){for(var e=t.length,n={};e;)n[t[--e]]=(n[t[e]]||0)+1;return n}function g(t,e){return p(e)[t]||0}n.yy.clear(),n.parse(t);var y=document.getElementById(e);o=y.parentElement.offsetWidth,"undefined"==typeof o&&(o=1200),"undefined"!=typeof a.useWidth&&(o=a.useWidth);var m=n.yy.getTasks(),v=m.length*(a.barHeight+a.barGap)+2*a.topPadding;y.setAttribute("height","100%"),y.setAttribute("viewBox","0 0 "+o+" "+v);var _=i.select("#"+e),b=i.min(m,function(t){return t.startTime}),A=i.max(m,function(t){return t.endTime}),x=i.time.scale().domain([i.min(m,function(t){return t.startTime}),i.max(m,function(t){return t.endTime})]).rangeRound([0,o-150]),w=[];r=s.duration(A-b).asDays();for(var k=0;kl&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,a=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(C,[a,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(C.$),i.push(C._$),E=s[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},u=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,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),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 s in i)this[s]=i[s];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(),s=0;se[0].length)){if(e=n,r=s,this.options.backtrack_lexer){if(t=this.test_match(n,i[s]),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 10;case 1:break;case 2:break;case 3:break;case 4:return 4;case 5:return 11;case 6:return"date";case 7:return 12;case 8:return 13;case 9:return 14;case 10:return 15;case 11:return":";case 12:return 6;case 13:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\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:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return t}();return o.lexer=u,t.prototype=o,o.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("_process"))},{_process:3,fs:1,path:2}],121:[function(t,e,n){(function(r){"use strict";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=[2,2],r=[1,5],i=[1,7],s=[1,8],a=[1,11],o=[1,12],u=[1,13],c=[1,14],l=[1,16],h=[1,17],d=[1,7,9,10,14,16,18,19,20,21,22,33],f=[7,9,10,14,16,18,19,20,22,33],p=[1,51],g={trace:function(){},yy:{},symbols_:{error:2,start:3,SD:4,document:5,line:6,SPACE:7,statement:8,NL:9,participant:10,actor:11,signal:12,note_statement:13,title:14,text:15,loop:16,restOfLine:17,end:18,opt:19,alt:20,"else":21,note:22,placement:23,text2:24,over:25,actor_pair:26,spaceList:27,",":28,left_of:29,right_of:30,signaltype:31,actors:32,ACTOR:33,SOLID_OPEN_ARROW:34,DOTTED_OPEN_ARROW:35,SOLID_ARROW:36,DOTTED_ARROW:37,SOLID_CROSS:38,DOTTED_CROSS:39,TXT:40,$accept:0,$end:1},terminals_:{2:"error",4:"SD",7:"SPACE",9:"NL",10:"participant",14:"title",15:"text",16:"loop",17:"restOfLine",18:"end",19:"opt",20:"alt",21:"else",22:"note",25:"over",28:",",29:"left_of",30:"right_of",33:"ACTOR",34:"SOLID_OPEN_ARROW",35:"DOTTED_OPEN_ARROW",36:"SOLID_ARROW",37:"DOTTED_ARROW",38:"SOLID_CROSS",39:"DOTTED_CROSS",40:"TXT"},productions_:[0,[3,2],[5,0],[5,2],[6,2],[6,1],[6,1],[8,3],[8,2],[8,2],[8,4],[8,4],[8,4],[8,7],[13,4],[13,4],[27,2],[27,1],[26,3],[26,1],[23,1],[23,1],[12,4],[32,2],[32,1],[11,1],[31,1],[31,1],[31,1],[31,1],[31,1],[31,1],[24,1]],performAction:function(t,e,n,r,i,s){var a=s.length-1;switch(i){case 1:return r.apply(s[a]),s[a];case 2:this.$=[];break;case 3:s[a-1].push(s[a]),this.$=s[a-1];break;case 4:case 5:this.$=s[a];break;case 6:this.$=[];break;case 7:this.$=s[a-1];break;case 11:s[a-1].unshift({type:"loopStart",loopText:s[a-2],signalType:r.LINETYPE.LOOP_START}),s[a-1].push({type:"loopEnd",loopText:s[a-2],signalType:r.LINETYPE.LOOP_END}),this.$=s[a-1];break;case 12:s[a-1].unshift({type:"optStart",optText:s[a-2],signalType:r.LINETYPE.OPT_START}),s[a-1].push({type:"optEnd",optText:s[a-2],signalType:r.LINETYPE.OPT_END}),this.$=s[a-1];break;case 13:s[a-4].unshift({type:"altStart",altText:s[a-5],signalType:r.LINETYPE.ALT_START}),s[a-4].push({type:"else",altText:s[a-2],signalType:r.LINETYPE.ALT_ELSE}),s[a-4]=s[a-4].concat(s[a-1]),s[a-4].push({type:"altEnd",signalType:r.LINETYPE.ALT_END}),this.$=s[a-4];break;case 14:this.$=[s[a-1],{type:"addNote",placement:s[a-2],actor:s[a-1].actor,text:s[a]}];break;case 15:s[a-2]=[].concat(s[a-1],s[a-1]).slice(0,2),s[a-2][0]=s[a-2][0].actor,s[a-2][1]=s[a-2][1].actor,this.$=[s[a-1],{type:"addNote",placement:r.PLACEMENT.OVER,actor:s[a-2].slice(0,2),text:s[a]}];break;case 18:this.$=[s[a-2],s[a]];break;case 19:this.$=s[a];break;case 20:this.$=r.PLACEMENT.LEFTOF;break;case 21:this.$=r.PLACEMENT.RIGHTOF;break;case 22:this.$=[s[a-3],s[a-1],{type:"addMessage",from:s[a-3].actor,to:s[a-1].actor,signalType:s[a-2],msg:s[a]}];break;case 25:this.$={type:"addActor",actor:s[a]};break;case 26:this.$=r.LINETYPE.SOLID_OPEN;break;case 27:this.$=r.LINETYPE.DOTTED_OPEN;break;case 28:this.$=r.LINETYPE.SOLID;break;case 29:this.$=r.LINETYPE.DOTTED;break;case 30:this.$=r.LINETYPE.SOLID_CROSS;break;case 31:this.$=r.LINETYPE.DOTTED_CROSS;break;case 32:this.$=s[a].substring(1).trim().replace(/\\n/gm,"\n")}},table:[{3:1,4:[1,2]},{1:[3]},e([1,7,9,10,14,16,19,20,22,33],n,{5:3}),{1:[2,1],6:4,7:r,8:6,9:i,10:s,11:15,12:9,13:10,14:a,16:o,19:u,20:c,22:l,33:h},e(d,[2,3]),{8:18,10:s,11:15,12:9,13:10,14:a,16:o,19:u,20:c,22:l,33:h},e(d,[2,5]),e(d,[2,6]),{11:19,33:h},{9:[1,20]},{9:[1,21]},{7:[1,22]},{17:[1,23]},{17:[1,24]},{17:[1,25]},{31:26,34:[1,27],35:[1,28],36:[1,29],37:[1,30],38:[1,31],39:[1,32]},{23:33,25:[1,34],29:[1,35],30:[1,36]},e([9,28,34,35,36,37,38,39,40],[2,25]),e(d,[2,4]),{9:[1,37]},e(d,[2,8]),e(d,[2,9]),{15:[1,38]},e(f,n,{5:39}),e(f,n,{5:40}),e([7,9,10,14,16,19,20,21,22,33],n,{5:41}),{11:42,33:h},{33:[2,26]},{33:[2,27]},{33:[2,28]},{33:[2,29]},{33:[2,30]},{33:[2,31]},{11:43,33:h},{11:45,26:44,33:h},{33:[2,20]},{33:[2,21]},e(d,[2,7]),{9:[1,46]},{6:4,7:r,8:6,9:i,10:s,11:15,12:9,13:10,14:a,16:o,18:[1,47],19:u,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:s,11:15,12:9,13:10,14:a,16:o,18:[1,48],19:u,20:c,22:l,33:h},{6:4,7:r,8:6,9:i,10:s,11:15,12:9,13:10,14:a,16:o,19:u,20:c,21:[1,49],22:l,33:h},{24:50,40:p},{24:52,40:p},{24:53,40:p},{28:[1,54],40:[2,19]},e(d,[2,10]),e(d,[2,11]),e(d,[2,12]),{17:[1,55]},{9:[2,22]},{9:[2,32]},{9:[2,14]},{9:[2,15]},{11:56,33:h},e(f,n,{5:57}),{40:[2,18]},{6:4,7:r,8:6,9:i,10:s,11:15,12:9,13:10,14:a,16:o,18:[1,58],19:u,20:c,22:l,33:h},e(d,[2,13])],defaultActions:{27:[2,26],28:[2,27],29:[2,28],30:[2,29],31:[2,30],32:[2,31],35:[2,20],36:[2,21],50:[2,22],51:[2,32],52:[2,14],53:[2,15],56:[2,18]},parseError:function(t,e){if(!e.recoverable){var n=function(t,e){this.message=t,this.hash=e};throw n.prototype=new Error,new n(t,e)}this.trace(t)},parse:function(t){var e=this,n=[0],r=[null],i=[],s=this.table,a="",o=0,u=0,c=0,l=2,h=1,d=i.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,"undefined"==typeof f.yylloc&&(f.yylloc={});var y=f.yylloc;i.push(y);var m=f.options&&f.options.ranges;this.parseError="function"==typeof p.yy.parseError?p.yy.parseError:Object.getPrototypeOf(this).parseError;for(var v,_,b,A,x,w,k,E,D,F=function(){var t;return t=f.lex()||h,"number"!=typeof t&&(t=e.symbols_[t]||t),t},C={};;){if(b=n[n.length-1],this.defaultActions[b]?A=this.defaultActions[b]:((null===v||"undefined"==typeof v)&&(v=F()),A=s[b]&&s[b][v]),"undefined"==typeof A||!A.length||!A[0]){var T="";D=[];for(w in s[b])this.terminals_[w]&&w>l&&D.push("'"+this.terminals_[w]+"'");T=f.showPosition?"Parse error on line "+(o+1)+":\n"+f.showPosition()+"\nExpecting "+D.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(o+1)+": Unexpected "+(v==h?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(T,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:D})}if(A[0]instanceof Array&&A.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+v);switch(A[0]){case 1:n.push(v),r.push(f.yytext),i.push(f.yylloc),n.push(A[1]),v=null,_?(v=_,_=null):(u=f.yyleng,a=f.yytext,o=f.yylineno,y=f.yylloc,c>0&&c--);break;case 2:if(k=this.productions_[A[1]][1],C.$=r[r.length-k],C._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},m&&(C._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),x=this.performAction.apply(C,[a,u,o,p.yy,A[1],r,i].concat(d)),"undefined"!=typeof x)return x;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[A[1]][0]),r.push(C.$),i.push(C._$),E=s[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},y=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,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),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 s in i)this[s]=i[s];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(),s=0;se[0].length)){if(e=n,r=s,this.options.backtrack_lexer){if(t=this.test_match(n,i[s]),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:break;case 2:break;case 3:break;case 4:break;case 5:return 10;case 6:return this.begin("LINE"),16;case 7:return this.begin("LINE"),19;case 8:return this.begin("LINE"),20;case 9:return this.begin("LINE"),21;case 10:return this.popState(),17;case 11:return 18;case 12:return 29;case 13:return 30;case 14:return 25;case 15:return 22;case 16:return 14;case 17:return 4;case 18:return 28;case 19:return 9;case 20:return 33;case 21:return 36;case 22:return 37;case 23:return 34;case 24:return 35;case 25:return 38;case 26:return 39;case 27:return 40;case 28:return 9;case 29:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:participant\b)/i,/^(?:loop\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\->:\n,;]+)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[2,3,10],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29],inclusive:!0}}};return t}();return g.lexer=y,t.prototype=g,g.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("_process"))},{_process:3,fs:1,path:2}],122:[function(t,e,n){(function(e){"use strict";var r={},i=[],s=[],a=[],o=t("../../logger"),u=new o.Log;n.addActor=function(t,e,n){r[t]={name:e,description:n},i.push(t)},n.addMessage=function(t,e,n,r){s.push({from:t,to:e,message:n,answer:r})},n.addSignal=function(t,e,n,r){u.debug("Adding message from="+t+" to="+e+" message="+n+" type="+r),s.push({from:t,to:e,message:n,type:r})},n.getMessages=function(){return s},n.getActors=function(){return r},n.getActor=function(t){return r[t]},n.getActorKeys=function(){return Object.keys(r)},n.clear=function(){r={},s=[]},n.LINETYPE={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},n.ARROWTYPE={FILLED:0,OPEN:1},n.PLACEMENT={LEFTOF:0,RIGHTOF:1,OVER:2},n.addNote=function(t,e,r){var i={actor:t,placement:e,message:r},o=[].concat(t,t);a.push(i),s.push({from:o[0],to:o[1],message:r,type:n.LINETYPE.NOTE,placement:e})},n.parseError=function(t,n){e.mermaidAPI.parseError(t,n)},n.apply=function(t){if(t instanceof Array)t.forEach(function(t){n.apply(t)});else switch(t.type){case"addActor":n.addActor(t.actor,t.actor,t.actor);break;case"addNote":n.addNote(t.actor,t.placement,t.text);break;case"addMessage":n.addSignal(t.from,t.to,t.msg,t.signalType);break;case"loopStart":n.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"optStart":n.addSignal(void 0,void 0,t.optText,t.signalType);break;case"optEnd":n.addSignal(void 0,void 0,void 0,t.signalType);break;case"altStart":n.addSignal(void 0,void 0,t.altText,t.signalType);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)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../../logger":125}],123:[function(t,e,n){"use strict";var r=t("./parser/sequenceDiagram").parser;r.yy=t("./sequenceDb");var i=t("./svgDraw"),s=t("../../d3"),a=t("../../logger"),o=new a.Log,u={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 s=this,a=0;this.list.forEach(function(o){a++;var c=s.list.length-a+1;s.updateVal(o,"startx",t-c*u.boxMargin,Math.min),s.updateVal(o,"starty",e-c*u.boxMargin,Math.min),s.updateVal(o,"stopx",r+c*u.boxMargin,Math.max),s.updateVal(o,"stopy",i+c*u.boxMargin,Math.max),s.updateVal(n.bounds.data,"startx",t-c*u.boxMargin,Math.min),s.updateVal(n.bounds.data,"starty",e-c*u.boxMargin,Math.min),s.updateVal(n.bounds.data,"stopx",r+c*u.boxMargin,Math.max),s.updateVal(n.bounds.data,"stopy",i+c*u.boxMargin,Math.max)})},insert:function(t,e,r,i){var s,a,o,u;s=Math.min(t,r),o=Math.max(t,r),a=Math.min(e,i),u=Math.max(e,i),this.updateVal(n.bounds.data,"startx",s,Math.min),this.updateVal(n.bounds.data,"starty",a,Math.min),this.updateVal(n.bounds.data,"stopx",o,Math.max),this.updateVal(n.bounds.data,"stopy",u,Math.max),this.updateLoops(s,a,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 c=function(t,e,r,s,a){var o=i.getNoteRect();o.x=e,o.y=r,o.width=a||u.width,o["class"]="note";var c=t.append("g"),l=i.drawRect(c,o),h=i.getTextObj();h.x=e-4,h.y=r-13,h.textMargin=u.noteMargin,h.dy="1em",h.text=s.message,h["class"]="noteText";var d=i.drawText(c,h,o.width-u.noteMargin),f=d[0][0].getBBox().height;!a&&f>u.width?(d.remove(),c=t.append("g"),d=i.drawText(c,h,2*o.width-u.noteMargin),f=d[0][0].getBBox().height,l.attr("width",2*o.width),n.bounds.insert(e,r,e+2*o.width,r+2*u.noteMargin+f)):n.bounds.insert(e,r,e+o.width,r+2*u.noteMargin+f),l.attr("height",f+2*u.noteMargin),n.bounds.bumpVerticalPos(f+2*u.noteMargin)},l=function(t,e,i,s,a){var o,u=t.append("g"),c=e+(i-e)/2,l=u.append("text").attr("x",c).attr("y",s-7).style("text-anchor","middle").attr("class","messageText").text(a.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+","+s+" C "+(e+60)+","+(s-10)+" "+(e+60)+","+(s+30)+" "+e+","+(s+20)),n.bounds.bumpVerticalPos(30);var d=Math.max(o/2,100);n.bounds.insert(e-d,n.bounds.getVerticalPos()-10,i+d,n.bounds.getVerticalPos())}else h=u.append("line"),h.attr("x1",e),h.attr("y1",s),h.attr("x2",i),h.attr("y2",s),n.bounds.insert(e,n.bounds.getVerticalPos()-10,i,n.bounds.getVerticalPos());a.type===r.yy.LINETYPE.DOTTED||a.type===r.yy.LINETYPE.DOTTED_CROSS||a.type===r.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0");var f=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;f=f.replace(/\(/g,"\\("),f=f.replace(/\)/g,"\\)"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(a.type===r.yy.LINETYPE.SOLID||a.type===r.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+f+"#arrowhead)"),(a.type===r.yy.LINETYPE.SOLID_CROSS||a.type===r.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+f+"#crosshead)")};e.exports.drawActors=function(t,e,r,s){var a;for(a=0;a/gi," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.attr("fill",e.fill),"undefined"!=typeof e["class"]&&i.attr("class",e["class"]);var s=i.append("tspan");return s.attr("x",e.x+2*e.textMargin),s.text(r),"undefined"!=typeof i.textwrap&&i.textwrap({x:e.x,y:e.y,width:n,height:1800},e.textMargin),i},n.drawLabel=function(t,e){var r=n.getNoteRect();r.x=e.x,r.y=e.y,r.width=50,r.height=20,r.fill="#526e52",r.stroke="none",r["class"]="labelBox",n.drawRect(t,r),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,e.fill="white",n.drawText(t,e)};var r=-1;n.drawActor=function(t,e,i,s,a){var o=e+a.width/2,u=t.append("g");0===i&&(r++,u.append("line").attr("id","actor"+r).attr("x1",o).attr("y1",5).attr("x2",o).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var c=n.getNoteRect();c.x=e,c.y=i,c.fill="#eaeaea",c.width=a.width,c.height=a.height,c["class"]="actor",c.rx=3,c.ry=3,n.drawRect(u,c),u.append("text").attr("x",o).attr("y",i+a.height/2+5).attr("class","actor").style("text-anchor","middle").text(s)},n.drawLoop=function(t,e,r,i){var s=t.append("g"),a=function(t,e,n,r){s.append("line").attr("x1",t).attr("y1",e).attr("x2",n).attr("y2",r).attr("stroke-width",2).attr("stroke","#526e52").attr("class","loopLine")};a(e.startx,e.starty,e.stopx,e.starty),a(e.stopx,e.starty,e.stopx,e.stopy),a(e.startx,e.stopy,e.stopx,e.stopy),a(e.startx,e.starty,e.startx,e.stopy),"undefined"!=typeof e.elsey&&a(e.startx,e.elsey,e.stopx,e.elsey);var o=n.getTextObj();o.text=r,o.x=e.startx,o.y=e.starty,o.labelMargin=1.5*i.boxMargin,o["class"]="labelText",o.fill="white",n.drawLabel(s,o),o=n.getTextObj(),o.text="[ "+e.title+" ]",o.x=e.startx+(e.stopx-e.startx)/2,o.y=e.starty+1.5*i.boxMargin,o.anchor="middle",o["class"]="loopText",n.drawText(s,o),"undefined"!=typeof e.elseText&&(o.text="[ "+e.elseText+" ]",o.y=e.elsey+1.5*i.boxMargin,n.drawText(s,o))},n.insertArrowHead=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")},n.insertArrowCrossHead=function(t){var e=t.append("defs"),n=e.append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);n.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"),n.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")},n.getTextObj=function(){var t={x:0,y:0,fill:"black","text-anchor":"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0};return t},n.getNoteRect=function(){var t={x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0};return t}},{}],125:[function(t,e,n){"use strict";function r(t){var e=t.getUTCHours(),n=t.getUTCMinutes(),r=t.getSeconds(),i=t.getMilliseconds();10>e&&(e="0"+e),10>n&&(n="0"+n),10>r&&(r="0"+r),100>i&&(i="0"+i),10>i&&(i="00"+i);var s=e+":"+n+":"+r+" ("+i+")";return s}function i(t){this.level=t,this.log=function(t,e){var n=this.level;return"undefined"==typeof n&&(n=a),e>=n&&"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log("["+r(new Date)+"] "+t):void 0},this.trace=function(t){this.log(t,s.trace)},this.debug=function(t){this.log(t,s.debug)},this.info=function(t){this.log(t,s.info)},this.warn=function(t){this.log(t,s.warn)},this.error=function(t){this.log(t,s.error)}}var s={debug:1,info:2,warn:3,error:4,fatal:5,"default":5},a=s.error;n.setLogLevel=function(t){a=t},n.Log=i},{}],126:[function(t,e,n){(function(e){"use strict";var r=t("./logger"),i=new r.Log,s=t("./diagrams/flowchart/graphDb"),a=t("./utils"),o=t("./diagrams/flowchart/flowRenderer"),u=t("./diagrams/sequenceDiagram/sequenceRenderer"),c=t("./diagrams/example/exampleRenderer"),l=t("./diagrams/example/parser/example"),h=t("./diagrams/flowchart/parser/flow"),d=t("./diagrams/flowchart/parser/dot"),f=t("./diagrams/sequenceDiagram/parser/sequenceDiagram"),p=t("./diagrams/sequenceDiagram/sequenceDb"),g=t("./diagrams/example/exampleDb"),y=t("./diagrams/gantt/ganttRenderer"),m=t("./diagrams/gantt/parser/gantt"),v=t("./diagrams/gantt/ganttDb"),_=t("./diagrams/classDiagram/parser/classDiagram"),b=t("./diagrams/classDiagram/classRenderer"),A=t("./diagrams/classDiagram/classDb"),x=t("./d3"),w={logLevel:5,cloneCssStyles:!0,startOnLoad:!0,flowchart:{htmlLabels:!0,useMaxWidth:!0},sequenceDiagram:{diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0},gantt:{titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,sidePadding:75,gridLineStartPadding:35,fontSize:11,fontFamily:'"Open-Sans", "sans-serif"',numberSectionStyles:3,axisFormatter:[["%I:%M",function(t){return t.getHours()}],["w. %U",function(t){return 1==t.getDay()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%m-%y",function(t){return t.getMonth()}]]}};r.setLogLevel(w.logLevel);var k=function(t){var e,n=a.detectType(t);switch(n){case"graph":e=h,e.parser.yy=s;break;case"dotGraph":e=d,e.parser.yy=s;break;case"sequenceDiagram":e=f,e.parser.yy=p;break;case"info":e=l,e.parser.yy=g;break;case"gantt":e=m,e.parser.yy=v;break;case"classDiagram":e=_,e.parser.yy=A}try{return e.parse(t),!0}catch(r){return!1}};n.parse=k,n.version=function(){return t("../package.json").version},n.encodeEntities=function(t){var e=t;return e=e.replace(/style.*:\S*#.*;/g,function(t){var e=t.substring(0,t.length-1);return e}),e=e.replace(/classDef.*:\S*#.*;/g,function(t){var e=t.substring(0,t.length-1);return e}),e=e.replace(/#\w+\;/g,function(t){var e=t.substring(1,t.length-1),n=/^\+?\d+$/.test(e);return n?"fl°°"+e+"¶ß":"fl°"+e+"¶ß"})},n.decodeEntities=function(t){var e=t;return e=e.replace(/\fl\°\°/g,function(){return"&#"}),e=e.replace(/\fl\°/g,function(){return"&"}),e=e.replace(/¶ß/g,function(){return";"})};var E=function(t,e,r,l){"undefined"!=typeof l?x.select(l).append("div").attr("id","d"+t).append("svg").attr("id",t).attr("width","100%").attr("xmlns","http://www.w3.org/2000/svg").append("g"):x.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=e,e=n.encodeEntities(e);var h=x.select("#d"+t).node(),d=a.detectType(e),f={};switch(d){case"graph":o.setConf(w.flowchart),o.draw(e,t,!1),w.cloneCssStyles&&(f=o.getClasses(e,!1),a.cloneCssStyles(h.firstChild,f));break;case"dotGraph":o.setConf(w.flowchart),o.draw(e,t,!0),w.cloneCssStyles&&(f=o.getClasses(e,!0),a.cloneCssStyles(h.firstChild,f));break;case"sequenceDiagram":u.setConf(w.sequenceDiagram),u.draw(e,t),w.cloneCssStyles&&a.cloneCssStyles(h.firstChild,[]);break;case"gantt":y.setConf(w.gantt),y.draw(e,t),w.cloneCssStyles&&a.cloneCssStyles(h.firstChild,[]);break;case"classDiagram":b.setConf(w.gantt),b.draw(e,t),w.cloneCssStyles&&a.cloneCssStyles(h.firstChild,[]);break;case"info":c.draw(e,t,n.version()),w.cloneCssStyles&&a.cloneCssStyles(h.firstChild,[])}x.select("#d"+t).selectAll("foreignobject div").attr("xmlns","http://www.w3.org/1999/xhtml");var p=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search;p=p.replace(/\(/g,"\\("),p=p.replace(/\)/g,"\\)");var g=x.select("#d"+t).node().innerHTML.replace(/url\(#arrowhead/g,"url("+p+"#arrowhead","g");g=n.decodeEntities(g),console.warn("here"),"undefined"!=typeof r?r(g,s.bindFunctions):i.warn("CB = undefined!");var m=x.select("#d"+t).node();return null!==m&&"function"==typeof m.remove&&x.select("#d"+t).node().remove(),g};n.render=function(t,e,n,r){return"undefined"!=typeof document?E(t,e,n,r):void 0};var D=function(t){var e,n=Object.keys(t);for(e=0;e0&&(r+=n.selectorText+" { "+n.style.cssText+" }\n")}}catch(l){"undefined"!=typeof n&&i.warn('Invalid CSS selector "'+n.selectorText+'"',l)}var h="",d="";for(var f in e)e.hasOwnProperty(f)&&"undefined"!=typeof f&&("default"===f?(e["default"].styles instanceof Array&&(h+="#"+t.id.trim()+" .node>rect { "+e[f].styles.join("; ")+"; }\n"),e["default"].nodeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .node text { "+e[f].nodeLabelStyles.join("; ")+"; }\n"),e["default"].edgeLabelStyles instanceof Array&&(h+="#"+t.id.trim()+" .edgeLabel text { "+e[f].edgeLabelStyles.join("; ")+"; }\n"),e["default"].clusterStyles instanceof Array&&(h+="#"+t.id.trim()+" .cluster rect { "+e[f].clusterStyles.join("; ")+"; }\n")):e[f].styles instanceof Array&&(d+="#"+t.id.trim()+" ."+f+">rect { "+e[f].styles.join("; ")+"; }\n"));if(""!==r||""!==h||""!==d){var p=document.createElement("style");p.setAttribute("type","text/css"),p.setAttribute("title","mermaid-svg-internal-css"),p.innerHTML="/* */\n",t.insertBefore(p,t.firstChild)}};n.cloneCssStyles=a},{"./logger":125}]},{},[126])(126)}); \ No newline at end of file diff --git a/docs/content/usage.md b/docs/content/usage.md index 95a473b919..9627b9e00c 100644 --- a/docs/content/usage.md +++ b/docs/content/usage.md @@ -77,6 +77,23 @@ Would end up like this: ``` An id is also added to mermaid tags without id. +###Labels out of bounds + +If you use dynamically loaded fonts that are loaded through CSS, such as Google fonts, mermaid should wait for the +whole page to have been loaded (dom + assets, particularly the fonts file). + +$(document).load(function() { + mermaid.initialize(); +}); +over + +$(document).ready(function() { + mermaid.initialize(); +}); + +Not doing so will most likely result in mermaid rendering graphs that have labels out of bounds. The default integration +in mermaid uses the window.load event to start rendering. + ### Calling **mermaid.init** By default, **mermaid.init** will be called when the document is ready, finding all elements with ``class="mermaid"``. If you are adding content after mermaid is loaded, or otherwise need diff --git a/scripts/watch.sh b/scripts/watch.sh index 690968efa0..48ee30e819 100644 --- a/scripts/watch.sh +++ b/scripts/watch.sh @@ -1,5 +1,5 @@ #!/usr/bin/env bash -watchify src/mermaid.js -s mermaid -t babelify -o dist/mermaid.js & +watchify src/mermaid.js -s mermaid -o dist/mermaid.js & live-server ./test/examples & node node_modules/eslint-watch/bin/esw src -w diff --git a/src/diagrams/classDiagram/classDb.js b/src/diagrams/classDiagram/classDb.js index e7b4ba1aa8..ebf0ea730b 100644 --- a/src/diagrams/classDiagram/classDb.js +++ b/src/diagrams/classDiagram/classDb.js @@ -1,14 +1,14 @@ -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); var relations = []; -let classes; +var classes; var idCache; -if(typeof Map !== 'undefined'){ - classes = new Map(); -} +classes = { +}; + // Functions to be run after graph rendering var funs = []; /** @@ -19,24 +19,24 @@ var funs = []; * @param style */ exports.addClass = function (id) { - if(typeof classes.get(id) === 'undefined'){ - classes.set(id, { + if(typeof classes[id] === 'undefined'){ + classes[id] = { id:id, methods:[], members:[] - }); + }; } }; exports.clear = function () { relations = []; - classes.clear(); + classes = {}; }; module.exports.getClass = function (id) { - return classes.get(id); + return classes[id]; }; -module.exports.getClasses = function (id) { +module.exports.getClasses = function () { return classes; }; @@ -53,7 +53,7 @@ exports.addRelation = function (relation) { }; exports.addMembers = function (className, MembersArr) { - var theClass = classes.get(className); + var theClass = classes[className]; if(typeof MembersArr === 'string'){ if(MembersArr.substr(-1) === ')'){ theClass.methods.push(MembersArr); diff --git a/src/diagrams/classDiagram/classRenderer.js b/src/diagrams/classDiagram/classRenderer.js index fe3812bcb6..24bf0d4e47 100644 --- a/src/diagrams/classDiagram/classRenderer.js +++ b/src/diagrams/classDiagram/classRenderer.js @@ -6,15 +6,14 @@ var cd = require('./parser/classDiagram').parser; var cDDb = require('./classDb'); cd.yy = cDDb; var d3 = require('../../d3'); -import * as Logger from '../../logger'; -import * as dagre from 'dagre'; +var Logger = require('../../logger'); +var dagre = require('dagre'); var log = new Logger.Log(); var idCache; -if (typeof Map !== 'undefined') { - idCache = new Map(); -} -let classCnt = 0; +idCache = {}; + +var classCnt = 0; var conf = { dividerMargin: 10, padding: 5, @@ -23,15 +22,19 @@ var conf = { // Todo optimize var getGraphId = function (label) { - for (var [id, classInfo] of idCache) { - if (classInfo.label === label) { - return id; - } + var keys = Object.keys(idCache); + + var i; + for(i=0;i ' + e.w + ': ' + JSON.stringify(g.edge(e))); diff --git a/src/diagrams/example/exampleDb.js b/src/diagrams/example/exampleDb.js index 4f7668ef62..c2b727755a 100644 --- a/src/diagrams/example/exampleDb.js +++ b/src/diagrams/example/exampleDb.js @@ -1,7 +1,7 @@ /** * Created by knut on 15-01-14. */ -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); var message = ''; diff --git a/src/diagrams/example/exampleRenderer.js b/src/diagrams/example/exampleRenderer.js index eec87898bf..2f4d332967 100644 --- a/src/diagrams/example/exampleRenderer.js +++ b/src/diagrams/example/exampleRenderer.js @@ -4,7 +4,7 @@ var db = require('./exampleDb'); var exampleParser = require('./parser/example.js'); var d3 = require('../../d3'); -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); /** diff --git a/src/diagrams/flowchart/dagre-d3.js b/src/diagrams/flowchart/dagre-d3.js index 3f6cf9e909..c0f01db288 100644 --- a/src/diagrams/flowchart/dagre-d3.js +++ b/src/diagrams/flowchart/dagre-d3.js @@ -1,5 +1,5 @@ /* global window */ -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); var dagreD3; diff --git a/src/diagrams/flowchart/flowRenderer.js b/src/diagrams/flowchart/flowRenderer.js index 06bdd2c8c3..8c0d8fa28b 100644 --- a/src/diagrams/flowchart/flowRenderer.js +++ b/src/diagrams/flowchart/flowRenderer.js @@ -6,7 +6,7 @@ var flow = require('./parser/flow'); var dot = require('./parser/dot'); var d3 = require('../../d3'); var dagreD3 = require('./dagre-d3'); -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); diff --git a/src/diagrams/flowchart/graphDb.js b/src/diagrams/flowchart/graphDb.js index 005ada77f8..6f188dc021 100644 --- a/src/diagrams/flowchart/graphDb.js +++ b/src/diagrams/flowchart/graphDb.js @@ -1,7 +1,7 @@ /** * Created by knut on 14-11-03. */ -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); var d3 = require('../../d3'); diff --git a/src/diagrams/gantt/ganttDb.js b/src/diagrams/gantt/ganttDb.js index 9d86404dfa..e341642cd8 100644 --- a/src/diagrams/gantt/ganttDb.js +++ b/src/diagrams/gantt/ganttDb.js @@ -2,7 +2,7 @@ * Created by knut on 15-01-14. */ var moment = require('moment'); -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); diff --git a/src/diagrams/sequenceDiagram/sequenceDb.js b/src/diagrams/sequenceDiagram/sequenceDb.js index 1404ef605d..284315bd0a 100644 --- a/src/diagrams/sequenceDiagram/sequenceDb.js +++ b/src/diagrams/sequenceDiagram/sequenceDb.js @@ -5,7 +5,7 @@ var actors = {}; var actorKeys = []; var messages = []; var notes = []; -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); diff --git a/src/diagrams/sequenceDiagram/sequenceRenderer.js b/src/diagrams/sequenceDiagram/sequenceRenderer.js index 59d5fa417d..df7125cd90 100644 --- a/src/diagrams/sequenceDiagram/sequenceRenderer.js +++ b/src/diagrams/sequenceDiagram/sequenceRenderer.js @@ -6,10 +6,9 @@ var sq = require('./parser/sequenceDiagram').parser; sq.yy = require('./sequenceDb'); var svgDraw = require('./svgDraw'); var d3 = require('../../d3'); -import * as Logger from '../../logger'; +var Logger = require('../../logger'); var log = new Logger.Log(); - var conf = { diagramMarginX:50, diff --git a/src/less/default/mermaid.less b/src/less/default/mermaid.less index 1179cbffc5..d031540ab3 100644 --- a/src/less/default/mermaid.less +++ b/src/less/default/mermaid.less @@ -6,7 +6,7 @@ text { font-family: 'trebuchet ms', verdana, arial; - font-size:28px; + font-size:14px; } div.mermaidTooltip { diff --git a/src/less/forest/mermaid.less b/src/less/forest/mermaid.less index 5d29559275..da2965456e 100644 --- a/src/less/forest/mermaid.less +++ b/src/less/forest/mermaid.less @@ -6,7 +6,7 @@ text { font-family: 'trebuchet ms', verdana, arial; - font-size:28px; + font-size:14px; } div.mermaidTooltip { diff --git a/src/logger.js b/src/logger.js index e5ee69946f..d3a2ee9fda 100644 --- a/src/logger.js +++ b/src/logger.js @@ -19,7 +19,7 @@ const LEVELS = { default: 5 }; -let defaultLevel = LEVELS.error; +var defaultLevel = LEVELS.error; exports.setLogLevel = function (level) { defaultLevel = level; @@ -54,13 +54,11 @@ function formatTime(timestamp) { } -class Log { - constructor(level) { - this.level = level; - } +function Log(level) { + this.level = level; - log(str, level) { - let logLevel = this.level; + this.log = function(str, level) { + var logLevel = this.level; if(typeof logLevel === 'undefined'){ logLevel = defaultLevel; } @@ -71,27 +69,27 @@ class Log { } } } - } + }; - trace(str) { + this.trace = function(str) { this.log(str, LEVELS.trace); - } + }; - debug(str) { + this.debug = function(str) { this.log(str, LEVELS.debug); - } + }; - info(str) { + this.info = function(str) { this.log(str, LEVELS.info); - } + }; - warn(str) { + this.warn = function(str) { this.log(str, LEVELS.warn); - } + }; - error(str) { + this.error = function(str) { this.log(str, LEVELS.error); - } + }; } exports.Log = Log; \ No newline at end of file diff --git a/src/mermaid.js b/src/mermaid.js index 7545e6d5a6..7e05d08523 100644 --- a/src/mermaid.js +++ b/src/mermaid.js @@ -17,7 +17,7 @@ * the diagrams to svg code. */ -import * as Logger from './logger'; +var Logger = require('./logger'); var log = new Logger.Log(); var mermaidAPI = require('./mermaidAPI'); @@ -270,7 +270,7 @@ if(typeof document !== 'undefined'){ /*! * Wait for document loaded before starting the execution */ - document.addEventListener('DOMContentLoaded', function(){ + window.addEventListener('load', function(){ exports.contentLoaded(); }, false); } diff --git a/src/mermaidAPI.js b/src/mermaidAPI.js index 249d8df7f8..9b71f77204 100644 --- a/src/mermaidAPI.js +++ b/src/mermaidAPI.js @@ -11,7 +11,7 @@ * returns a svg element for the graph. It is is then up to the user of the API to make use of the svg, either insert it * somewhere in the page or something completely different. */ -import * as Logger from './logger'; +var Logger = require('./logger'); var log = new Logger.Log(); var graph = require('./diagrams/flowchart/graphDb'); @@ -440,6 +440,8 @@ var render = function(id, txt, cb, container){ var svgCode = d3.select('#d'+id).node().innerHTML.replace(/url\(#arrowhead/g,'url('+url +'#arrowhead','g'); svgCode = exports.decodeEntities(svgCode); + console.warn('here'); + //console.warn('mermaid decode: '); //console.warn(svgCode); //var he = require('he'); @@ -447,13 +449,15 @@ var render = function(id, txt, cb, container){ if(typeof cb !== 'undefined'){ cb(svgCode,graph.bindFunctions); }else{ - log.warn('CB = undefined'); + log.warn('CB = undefined!'); } var node = d3.select('#d'+id).node(); if(node !== null && typeof node.remove === 'function'){ d3.select('#d'+id).node().remove(); } + + return svgCode; }; exports.render = function(id, text, cb, containerElement){ @@ -462,7 +466,7 @@ if(typeof document === 'undefined'){ } else{ // In browser - render( id, text, cb, containerElement); + return render( id, text, cb, containerElement); } }; diff --git a/src/utils.js b/src/utils.js index 6a00bf02ea..e03ae4b471 100644 --- a/src/utils.js +++ b/src/utils.js @@ -1,7 +1,7 @@ /** * Created by knut on 14-11-23. */ -import * as Logger from './logger'; +var Logger = require('./logger'); var log = new Logger.Log(); /** @@ -49,7 +49,7 @@ var detectType = function(text){ return 'graph'; }; -export {detectType}; +exports.detectType= detectType; /** * Copies all relevant CSS content into the graph SVG. @@ -134,4 +134,4 @@ var cloneCssStyles = function(svg, classes){ } }; -export {cloneCssStyles}; +exports.cloneCssStyles = cloneCssStyles; diff --git a/src/utils.spec.js b/src/utils.spec.js index a42771821a..d883e8b7e5 100644 --- a/src/utils.spec.js +++ b/src/utils.spec.js @@ -1,7 +1,7 @@ /** * Created by knut on 14-11-23. */ -import * as utils from './utils'; +var utils = require('./utils'); //var log = require('./logger').create(); describe('when detecting chart type ', function () { diff --git a/test/examples/classDiagram.html b/test/examples/classDiagram.html index 925a1b0448..0ef6dba9bd 100644 --- a/test/examples/classDiagram.html +++ b/test/examples/classDiagram.html @@ -3,10 +3,10 @@ + -