react-digraph
Version:
directed graph react component
2 lines • 401 kB
JavaScript
/*! For license information please see main.min.js.LICENSE.txt */
module.exports=function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/dist/",n(n.s=402)}([function(t,e){t.exports=require("react")},function(t,e,n){var r;try{r={cloneDeep:n(314),constant:n(75),defaults:n(315),each:n(107),filter:n(110),find:n(316),flatten:n(137),forEach:n(108),forIn:n(323),has:n(121),isUndefined:n(122),last:n(324),map:n(123),mapValues:n(325),max:n(326),merge:n(328),min:n(334),minBy:n(335),now:n(336),pick:n(337),range:n(342),reduce:n(125),sortBy:n(345),uniqueId:n(350),values:n(130),zipObject:n(351)}}catch(t){}r||(r=window._),t.exports=r},function(t,e){var n=Array.isArray;t.exports=n},function(t,e,n){"use strict";var r=n(1),o=n(7).Graph;function i(t,e,n,o){var i;do{i=r.uniqueId(o)}while(t.hasNode(i));return n.dummy=e,t.setNode(i,n),i}function a(t){return r.max(r.map(t.nodes(),(function(e){var n=t.node(e).rank;if(!r.isUndefined(n))return n})))}t.exports={addDummyNode:i,simplify:function(t){var e=(new o).setGraph(t.graph());return r.forEach(t.nodes(),(function(n){e.setNode(n,t.node(n))})),r.forEach(t.edges(),(function(n){var r=e.edge(n.v,n.w)||{weight:0,minlen:1},o=t.edge(n);e.setEdge(n.v,n.w,{weight:r.weight+o.weight,minlen:Math.max(r.minlen,o.minlen)})})),e},asNonCompoundGraph:function(t){var e=new o({multigraph:t.isMultigraph()}).setGraph(t.graph());return r.forEach(t.nodes(),(function(n){t.children(n).length||e.setNode(n,t.node(n))})),r.forEach(t.edges(),(function(n){e.setEdge(n,t.edge(n))})),e},successorWeights:function(t){var e=r.map(t.nodes(),(function(e){var n={};return r.forEach(t.outEdges(e),(function(e){n[e.w]=(n[e.w]||0)+t.edge(e).weight})),n}));return r.zipObject(t.nodes(),e)},predecessorWeights:function(t){var e=r.map(t.nodes(),(function(e){var n={};return r.forEach(t.inEdges(e),(function(e){n[e.v]=(n[e.v]||0)+t.edge(e).weight})),n}));return r.zipObject(t.nodes(),e)},intersectRect:function(t,e){var n,r,o=t.x,i=t.y,a=e.x-o,s=e.y-i,u=t.width/2,c=t.height/2;if(!a&&!s)throw new Error("Not possible to find intersection inside of the rectangle");Math.abs(s)*u>Math.abs(a)*c?(s<0&&(c=-c),n=c*a/s,r=c):(a<0&&(u=-u),n=u,r=u*s/a);return{x:o+n,y:i+r}},buildLayerMatrix:function(t){var e=r.map(r.range(a(t)+1),(function(){return[]}));return r.forEach(t.nodes(),(function(n){var o=t.node(n),i=o.rank;r.isUndefined(i)||(e[i][o.order]=n)})),e},normalizeRanks:function(t){var e=r.min(r.map(t.nodes(),(function(e){return t.node(e).rank})));r.forEach(t.nodes(),(function(n){var o=t.node(n);r.has(o,"rank")&&(o.rank-=e)}))},removeEmptyRanks:function(t){var e=r.min(r.map(t.nodes(),(function(e){return t.node(e).rank}))),n=[];r.forEach(t.nodes(),(function(r){var o=t.node(r).rank-e;n[o]||(n[o]=[]),n[o].push(r)}));var o=0,i=t.graph().nodeRankFactor;r.forEach(n,(function(e,n){r.isUndefined(e)&&n%i!=0?--o:o&&r.forEach(e,(function(e){t.node(e).rank+=o}))}))},addBorderNode:function(t,e,n,r){var o={width:0,height:0};arguments.length>=4&&(o.rank=n,o.order=r);return i(t,"border",o,e)},maxRank:a,partition:function(t,e){var n={lhs:[],rhs:[]};return r.forEach(t,(function(t){e(t)?n.lhs.push(t):n.rhs.push(t)})),n},time:function(t,e){var n=r.now();try{return e()}finally{console.log(t+" time: "+(r.now()-n)+"ms")}},notime:function(t,e){return e()}}},function(t,e,n){e.Point2D=n(382),e.Vector2D=n(383),e.Matrix2D=n(384)},function(t,e,n){var r;try{r={clone:n(201),constant:n(75),each:n(107),filter:n(110),has:n(121),isArray:n(2),isEmpty:n(278),isFunction:n(27),isUndefined:n(122),keys:n(12),map:n(123),reduce:n(125),size:n(281),transform:n(287),union:n(288),values:n(130)}}catch(t){}r||(r=window._),t.exports=r},function(t,e){t.exports=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},function(t,e,n){var r;try{r=n(199)}catch(t){}r||(r=window.graphlib),t.exports=r},function(t,e,n){var r=n(90),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();t.exports=i},function(t,e){t.exports=function(t){return null!=t&&"object"==typeof t}},function(t,e,n){var r=n(27),o=n(69);t.exports=function(t){return null!=t&&o(t.length)&&!r(t)}},function(t,e,n){var r=n(258),o=n(268),i=n(18),a=n(2),s=n(275);t.exports=function(t){return"function"==typeof t?t:null==t?i:"object"==typeof t?a(t)?o(t[0],t[1]):r(t):s(t)}},function(t,e,n){var r=n(93),o=n(71),i=n(10);t.exports=function(t){return i(t)?r(t):o(t)}},function(t,e,n){e.intersect=n(376),e.shape=n(144).newShape},,function(t,e,n){var r=n(212),o=n(218);t.exports=function(t,e){var n=o(t,e);return r(n)?n:void 0}},function(t,e,n){var r=n(22),o=n(214),i=n(215),a=r?r.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":a&&a in Object(t)?o(t):i(t)}},function(t,e,n){var r=n(93),o=n(238),i=n(10);t.exports=function(t){return i(t)?r(t,!0):o(t)}},function(t,e){t.exports=function(t){return t}},function(t,e,n){"use strict";var r=n(198);e.createRoot=r.createRoot,e.hydrateRoot=r.hydrateRoot},,function(t,e){t.exports=function(t,e){return t===e||t!=t&&e!=e}},function(t,e,n){var r=n(8).Symbol;t.exports=r},function(t,e,n){(function(t){var r=n(8),o=n(234),i=e&&!e.nodeType&&e,a=i&&"object"==typeof t&&t&&!t.nodeType&&t,s=a&&a.exports===i?r.Buffer:void 0,u=(s?s.isBuffer:void 0)||o;t.exports=u}).call(this,n(68)(t))},function(t,e,n){var r=n(243),o=n(65),i=n(244),a=n(102),s=n(245),u=n(16),c=n(91),l="[object Map]",f="[object Promise]",h="[object Set]",d="[object WeakMap]",p="[object DataView]",y=c(r),v=c(o),g=c(i),x=c(a),m=c(s),w=u;(r&&w(new r(new ArrayBuffer(1)))!=p||o&&w(new o)!=l||i&&w(i.resolve())!=f||a&&w(new a)!=h||s&&w(new s)!=d)&&(w=function(t){var e=u(t),n="[object Object]"==e?t.constructor:void 0,r=n?c(n):"";if(r)switch(r){case y:return p;case v:return l;case g:return f;case x:return h;case m:return d}return e}),t.exports=w},function(t,e,n){var r=n(16),o=n(9);t.exports=function(t){return"symbol"==typeof t||o(t)&&"[object Symbol]"==r(t)}},function(t,e,n){t.exports={graphlib:n(7),layout:n(313),debug:n(374),util:{time:n(3).time,notime:n(3).notime},version:n(375)}},function(t,e,n){var r=n(16),o=n(6);t.exports=function(t){if(!o(t))return!1;var e=r(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},function(t,e,n){var r=n(43),o=n(44);t.exports=function(t,e,n,i){var a=!n;n||(n={});for(var s=-1,u=e.length;++s<u;){var c=e[s],l=i?i(n[c],t[c],c,n,t):void 0;void 0===l&&(l=t[c]),a?o(n,c,l):r(n,c,l)}return n}},function(t,e,n){var r=n(233),o=n(9),i=Object.prototype,a=i.hasOwnProperty,s=i.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(t){return o(t)&&a.call(t,"callee")&&!s.call(t,"callee")};t.exports=u},function(t,e,n){var r=n(235),o=n(46),i=n(70),a=i&&i.isTypedArray,s=a?o(a):r;t.exports=s},function(t,e,n){var r=n(25);t.exports=function(t){if("string"==typeof t||r(t))return t;var e=t+"";return"0"==e&&1/t==-Infinity?"-0":e}},function(t,e,n){e.Point2D=n(377),e.Vector2D=n(378),e.Matrix2D=n(379)},function(t,e,n){"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n=function(t,e){var n=t[1]||"",r=t[3];if(!r)return n;if(e&&"function"==typeof btoa){var o=(a=r,s=btoa(unescape(encodeURIComponent(JSON.stringify(a)))),u="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(s),"/*# ".concat(u," */")),i=r.sources.map((function(t){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(t," */")}));return[n].concat(i).concat([o]).join("\n")}var a,s,u;return[n].join("\n")}(e,t);return e[2]?"@media ".concat(e[2]," {").concat(n,"}"):n})).join("")},e.i=function(t,n,r){"string"==typeof t&&(t=[[null,t,""]]);var o={};if(r)for(var i=0;i<this.length;i++){var a=this[i][0];null!=a&&(o[a]=!0)}for(var s=0;s<t.length;s++){var u=[].concat(t[s]);r&&o[u[0]]||(n&&(u[2]?u[2]="".concat(n," and ").concat(u[2]):u[2]=n),e.push(u))}},e}},,,,function(t,e,n){var r=n(62),o=n(63);"string"==typeof(o=o.__esModule?o.default:o)&&(o=[[t.i,o,""]]);var i={insert:"head",singleton:!1};r(o,i);t.exports=o.locals||{}},function(t,e,n){var r=n(39),o=n(207),i=n(208),a=n(209),s=n(210),u=n(211);function c(t){var e=this.__data__=new r(t);this.size=e.size}c.prototype.clear=o,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=s,c.prototype.set=u,t.exports=c},function(t,e,n){var r=n(202),o=n(203),i=n(204),a=n(205),s=n(206);function u(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=o,u.prototype.get=i,u.prototype.has=a,u.prototype.set=s,t.exports=u},function(t,e,n){var r=n(21);t.exports=function(t,e){for(var n=t.length;n--;)if(r(t[n][0],e))return n;return-1}},function(t,e,n){var r=n(15)(Object,"create");t.exports=r},function(t,e,n){var r=n(227);t.exports=function(t,e){var n=t.__data__;return r(e)?n["string"==typeof e?"string":"hash"]:n.map}},function(t,e,n){var r=n(44),o=n(21),i=Object.prototype.hasOwnProperty;t.exports=function(t,e,n){var a=t[e];i.call(t,e)&&o(a,n)&&(void 0!==n||e in t)||r(t,e,n)}},function(t,e,n){var r=n(92);t.exports=function(t,e,n){"__proto__"==e&&r?r(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}},function(t,e){var n=/^(?:0|[1-9]\d*)$/;t.exports=function(t,e){var r=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==r||"symbol"!=r&&n.test(t))&&t>-1&&t%1==0&&t<e}},function(t,e){t.exports=function(t){return function(e){return t(e)}}},function(t,e){var n=Object.prototype;t.exports=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||n)}},function(t,e,n){var r=n(94)(Object.getPrototypeOf,Object);t.exports=r},function(t,e,n){var r=n(76),o=n(256)(r);t.exports=o},function(t,e,n){var r=n(51),o=n(31);t.exports=function(t,e){for(var n=0,i=(e=r(e,t)).length;null!=t&&n<i;)t=t[o(e[n++])];return n&&n==i?t:void 0}},function(t,e,n){var r=n(2),o=n(79),i=n(270),a=n(117);t.exports=function(t,e){return r(t)?t:o(t,e)?[t]:i(a(t))}},function(t,e){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n<r;)o[n]=e(t[n],n,t);return o}},function(t,e,n){var r=n(18),o=n(126),i=n(127);t.exports=function(t,e){return i(o(t,e,r),t+"")}},function(t,e,n){var r=n(21),o=n(10),i=n(45),a=n(6);t.exports=function(t,e,n){if(!a(n))return!1;var s=typeof e;return!!("number"==s?o(n)&&i(e,n.length):"string"==s&&e in n)&&r(n[e],t)}},function(t,e,n){"use strict";var r=n(1);t.exports={longestPath:function(t){var e={};r.forEach(t.sources(),(function n(o){var i=t.node(o);if(r.has(e,o))return i.rank;e[o]=!0;var a=r.min(r.map(t.outEdges(o),(function(e){return n(e.w)-t.edge(e).minlen})));return a!==Number.POSITIVE_INFINITY&&null!=a||(a=0),i.rank=a}))},slack:function(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}}},,,,,,,function(t,e,n){"use strict";var r,o=function(){return void 0===r&&(r=Boolean(window&&document&&document.all&&!window.atob)),r},i=function(){var t={};return function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(t){n=null}t[e]=n}return t[e]}}(),a=[];function s(t){for(var e=-1,n=0;n<a.length;n++)if(a[n].identifier===t){e=n;break}return e}function u(t,e){for(var n={},r=[],o=0;o<t.length;o++){var i=t[o],u=e.base?i[0]+e.base:i[0],c=n[u]||0,l="".concat(u," ").concat(c);n[u]=c+1;var f=s(l),h={css:i[1],media:i[2],sourceMap:i[3]};-1!==f?(a[f].references++,a[f].updater(h)):a.push({identifier:l,updater:v(h,e),references:1}),r.push(l)}return r}function c(t){var e=document.createElement("style"),r=t.attributes||{};if(void 0===r.nonce){var o=n.nc;o&&(r.nonce=o)}if(Object.keys(r).forEach((function(t){e.setAttribute(t,r[t])})),"function"==typeof t.insert)t.insert(e);else{var a=i(t.insert||"head");if(!a)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");a.appendChild(e)}return e}var l,f=(l=[],function(t,e){return l[t]=e,l.filter(Boolean).join("\n")});function h(t,e,n,r){var o=n?"":r.media?"@media ".concat(r.media," {").concat(r.css,"}"):r.css;if(t.styleSheet)t.styleSheet.cssText=f(e,o);else{var i=document.createTextNode(o),a=t.childNodes;a[e]&&t.removeChild(a[e]),a.length?t.insertBefore(i,a[e]):t.appendChild(i)}}function d(t,e,n){var r=n.css,o=n.media,i=n.sourceMap;if(o?t.setAttribute("media",o):t.removeAttribute("media"),i&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleSheet)t.styleSheet.cssText=r;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(r))}}var p=null,y=0;function v(t,e){var n,r,o;if(e.singleton){var i=y++;n=p||(p=c(e)),r=h.bind(null,n,i,!1),o=h.bind(null,n,i,!0)}else n=c(e),r=d.bind(null,n,e),o=function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(n)};return r(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;r(t=e)}else o()}}t.exports=function(t,e){(e=e||{}).singleton||"boolean"==typeof e.singleton||(e.singleton=o());var n=u(t=t||[],e);return function(t){if(t=t||[],"[object Array]"===Object.prototype.toString.call(t)){for(var r=0;r<n.length;r++){var o=s(n[r]);a[o].references--}for(var i=u(t,e),c=0;c<n.length;c++){var l=s(n[c]);0===a[l].references&&(a[l].updater(),a.splice(l,1))}n=i}}}},function(t,e,n){"use strict";n.r(e);var r=n(33),o=n.n(r)()(!0);o.push([t.i,".view-wrapper{height:100%;width:100%;margin:0;display:flex;box-shadow:none;background:#f9f9f9;transition:opacity 0.167s;opacity:1;outline:none;user-select:none;position:relative}.view-wrapper>.graph{align-content:stretch;flex:1;width:100%;height:100%}.view-wrapper .node .shape>use.node{color:#1e90ff;stroke:#000;fill:#fff;filter:url(#dropshadow);stroke-width:0.5px;cursor:pointer;user-select:none}.view-wrapper .node .shape>use.node.hovered{stroke:#1e90ff}.view-wrapper .node .shape>use.node.selected{color:#fff;stroke:#1e90ff;stroke-width:1px;fill:#1e90ff}.view-wrapper .node .node-text{fill:#000;cursor:pointer;user-select:none}.view-wrapper .node .node-text.selected{fill:#fff;stroke:#fff}.view-wrapper .edge{color:#fff;stroke:#1e90ff;stroke-width:2px;marker-end:url(#end-arrow);cursor:pointer}.view-wrapper .edge .edge-text{stroke-width:0.5px;fill:#1e90ff;stroke:#1e90ff;cursor:pointer;user-select:none}.view-wrapper .edge .edge-text.edge-label-text{font-size:11px;stroke:none;fill:black}.view-wrapper .edge.selected{color:#1e90ff;stroke:#1e90ff}.view-wrapper .edge.selected .edge-text{fill:#fff;stroke:#fff}.view-wrapper .edge-mouse-handler{stroke:black;opacity:0;color:transparent;stroke-width:15px;cursor:pointer;pointer-events:all}.view-wrapper .arrow{fill:#1e90ff}.view-wrapper .graph-controls{position:absolute;bottom:30px;left:15px;display:grid;grid-template-columns:auto auto auto;grid-gap:15px;align-items:center;user-select:none}.view-wrapper .graph-controls>.slider-wrapper{background-color:#fff;color:#1e90ff;border:solid 1px #d3d3d3;padding:6.5px;border-radius:2px}.view-wrapper .graph-controls>.slider-wrapper>span{display:inline-block;vertical-align:middle}.view-wrapper .graph-controls>.slider-wrapper>.slider{position:relative;margin-left:4px;margin-right:4px;cursor:pointer;vertical-align:middle}.view-wrapper .graph-controls .slider-button{background-color:#fff;fill:#1e90ff;border:solid 1px #d3d3d3;outline:none;width:31px;height:31px;border-radius:2px;cursor:pointer;margin:0}.view-wrapper .graph-controls .slider-button>svg{vertical-align:middle}.view-wrapper .circle{fill:#d3d3d3}\n","",{version:3,sources:["webpack://styles/main.scss"],names:[],mappings:"AAuBA,cACE,WAAY,CACZ,UAAW,CACX,QAAS,CACT,YAAa,CACb,eAAgB,CAChB,kBATwB,CAUxB,yBAA0B,CAC1B,SAAU,CACV,YAAa,CACb,gBAAiB,CACjB,iBAAkB,CAXpB,qBAcI,qBAAsB,CACtB,MAAO,CACP,UAAW,CACX,WAAY,CAjBhB,oCAuBQ,aA9BkB,CA+BlB,WA7BU,CA8BV,SA/BW,CAgCX,uBAAwB,CACxB,kBAAmB,CACnB,cAAe,CACf,gBAAiB,CA7BzB,4CAgCU,cAvCgB,CAO1B,6CAmCU,UAzCS,CA0CT,cA3CgB,CA4ChB,gBAAiB,CACjB,YA7CgB,CAO1B,+BA4CM,SAjDY,CAkDZ,cAAe,CACf,gBAAiB,CA9CvB,wCAgDQ,SAtDW,CAuDX,WAvDW,CAMnB,oBAuDI,UA7De,CA8Df,cA/DsB,CAgEtB,gBAAiB,CACjB,0BAA2B,CAC3B,cAAe,CA3DnB,+BA8DM,kBAAmB,CACnB,YAtEoB,CAuEpB,cAvEoB,CAyEpB,cAAe,CACf,gBAAiB,CAnEvB,+CAsEQ,cAAe,CACf,WAAY,CACZ,UAAW,CAxEnB,6BA6EM,aApFoB,CAqFpB,cArFoB,CAO1B,wCAiFQ,SAvFW,CAwFX,WAxFW,CAMnB,kCAwFI,YAAa,CACb,SAAU,CACV,iBAAkB,CAClB,iBAAkB,CAClB,cAAe,CACf,kBAAmB,CA7FvB,qBAiGI,YAxGsB,CAO1B,8BAqGI,iBAAkB,CAClB,WAAY,CACZ,SAAU,CACV,YAAa,CACb,oCAAqC,CACrC,aAAc,CACd,kBAAmB,CACnB,gBAAiB,CA5GrB,8CA+GM,qBArHa,CAsHb,aAvHoB,CAwHpB,wBArHgB,CAsHhB,aAAc,CACd,iBAAkB,CAnHxB,mDAsHQ,oBAAqB,CACrB,qBAAsB,CAvH9B,sDA2HQ,iBAAkB,CAClB,eAAgB,CAChB,gBAAiB,CACjB,cAAe,CACf,qBAAsB,CA/H9B,6CAoIM,qBA1Ia,CA2Ib,YA5IoB,CA6IpB,wBA1IgB,CA2IhB,YAAa,CACb,UA1IY,CA2IZ,WA3IY,CA4IZ,iBAAkB,CAClB,cAAe,CACf,QAAS,CA5If,iDA+IQ,qBAAsB,CA/I9B,sBAqJI,YAzJkB",sourcesContent:['/*\n Copyright(c) 2018 Uber Technologies, Inc.\n\n Licensed under the Apache License, Version 2.0 (the "License");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an "AS IS" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n*/\n\n$primary-color: dodgerblue;\n$light-color: white;\n$dark-color: black;\n$light-grey: lightgrey;\n$background-color: #f9f9f9;\n$button-size: 31px;\n\n.view-wrapper {\n height: 100%;\n width: 100%;\n margin: 0;\n display: flex;\n box-shadow: none;\n background: $background-color;\n transition: opacity 0.167s;\n opacity: 1;\n outline: none;\n user-select: none;\n position: relative;\n\n > .graph {\n align-content: stretch;\n flex: 1;\n width: 100%;\n height: 100%;\n }\n\n .node {\n .shape {\n > use.node {\n color: $primary-color;\n stroke: $dark-color;\n fill: $light-color;\n filter: url(#dropshadow);\n stroke-width: 0.5px;\n cursor: pointer;\n user-select: none;\n\n &.hovered {\n stroke: $primary-color;\n }\n &.selected {\n color: $light-color;\n stroke: $primary-color;\n stroke-width: 1px;\n fill: $primary-color;\n }\n }\n }\n\n .node-text {\n fill: $dark-color;\n cursor: pointer;\n user-select: none;\n &.selected {\n fill: $light-color;\n stroke: $light-color;\n }\n }\n }\n\n .edge {\n color: $light-color;\n stroke: $primary-color;\n stroke-width: 2px;\n marker-end: url(#end-arrow);\n cursor: pointer;\n\n .edge-text {\n stroke-width: 0.5px;\n fill: $primary-color;\n stroke: $primary-color;\n\n cursor: pointer;\n user-select: none;\n\n &.edge-label-text {\n font-size: 11px; \n stroke: none;\n fill: black;\n }\n }\n\n &.selected {\n color: $primary-color;\n stroke: $primary-color;\n\n .edge-text {\n fill: $light-color;\n stroke: $light-color;\n }\n }\n }\n\n .edge-mouse-handler {\n stroke: black;\n opacity: 0;\n color: transparent;\n stroke-width: 15px;\n cursor: pointer;\n pointer-events: all;\n }\n\n .arrow {\n fill: $primary-color;\n }\n\n .graph-controls {\n position: absolute;\n bottom: 30px;\n left: 15px;\n display: grid;\n grid-template-columns: auto auto auto;\n grid-gap: 15px;\n align-items: center;\n user-select: none;\n\n > .slider-wrapper {\n background-color: $light-color;\n color: $primary-color;\n border: solid 1px $light-grey;\n padding: 6.5px;\n border-radius: 2px;\n\n > span {\n display: inline-block;\n vertical-align: middle;\n }\n\n > .slider {\n position: relative;\n margin-left: 4px;\n margin-right: 4px;\n cursor: pointer;\n vertical-align: middle;\n }\n }\n\n .slider-button {\n background-color: $light-color;\n fill: $primary-color;\n border: solid 1px $light-grey;\n outline: none;\n width: $button-size;\n height: $button-size;\n border-radius: 2px;\n cursor: pointer;\n margin: 0;\n\n > svg {\n vertical-align: middle;\n }\n }\n }\n\n .circle {\n fill: $light-grey;\n }\n}\n'],sourceRoot:""}]),e.default=o},function(t,e,n){"use strict";var r=n(5);t.exports=s;var o="\0",i="\0",a="";function s(t){this._isDirected=!r.has(t,"directed")||t.directed,this._isMultigraph=!!r.has(t,"multigraph")&&t.multigraph,this._isCompound=!!r.has(t,"compound")&&t.compound,this._label=void 0,this._defaultNodeLabelFn=r.constant(void 0),this._defaultEdgeLabelFn=r.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[i]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}function u(t,e){t[e]?t[e]++:t[e]=1}function c(t,e){--t[e]||delete t[e]}function l(t,e,n,i){var s=""+e,u=""+n;if(!t&&s>u){var c=s;s=u,u=c}return s+a+u+a+(r.isUndefined(i)?o:i)}function f(t,e){return l(t,e.v,e.w,e.name)}s.prototype._nodeCount=0,s.prototype._edgeCount=0,s.prototype.isDirected=function(){return this._isDirected},s.prototype.isMultigraph=function(){return this._isMultigraph},s.prototype.isCompound=function(){return this._isCompound},s.prototype.setGraph=function(t){return this._label=t,this},s.prototype.graph=function(){return this._label},s.prototype.setDefaultNodeLabel=function(t){return r.isFunction(t)||(t=r.constant(t)),this._defaultNodeLabelFn=t,this},s.prototype.nodeCount=function(){return this._nodeCount},s.prototype.nodes=function(){return r.keys(this._nodes)},s.prototype.sources=function(){var t=this;return r.filter(this.nodes(),(function(e){return r.isEmpty(t._in[e])}))},s.prototype.sinks=function(){var t=this;return r.filter(this.nodes(),(function(e){return r.isEmpty(t._out[e])}))},s.prototype.setNodes=function(t,e){var n=arguments,o=this;return r.each(t,(function(t){n.length>1?o.setNode(t,e):o.setNode(t)})),this},s.prototype.setNode=function(t,e){return r.has(this._nodes,t)?(arguments.length>1&&(this._nodes[t]=e),this):(this._nodes[t]=arguments.length>1?e:this._defaultNodeLabelFn(t),this._isCompound&&(this._parent[t]=i,this._children[t]={},this._children[i][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},s.prototype.node=function(t){return this._nodes[t]},s.prototype.hasNode=function(t){return r.has(this._nodes,t)},s.prototype.removeNode=function(t){var e=this;if(r.has(this._nodes,t)){var n=function(t){e.removeEdge(e._edgeObjs[t])};delete this._nodes[t],this._isCompound&&(this._removeFromParentsChildList(t),delete this._parent[t],r.each(this.children(t),(function(t){e.setParent(t)})),delete this._children[t]),r.each(r.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],r.each(r.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},s.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r.isUndefined(e))e=i;else{for(var n=e+="";!r.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},s.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},s.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!==i)return e}},s.prototype.children=function(t){if(r.isUndefined(t)&&(t=i),this._isCompound){var e=this._children[t];if(e)return r.keys(e)}else{if(t===i)return this.nodes();if(this.hasNode(t))return[]}},s.prototype.predecessors=function(t){var e=this._preds[t];if(e)return r.keys(e)},s.prototype.successors=function(t){var e=this._sucs[t];if(e)return r.keys(e)},s.prototype.neighbors=function(t){var e=this.predecessors(t);if(e)return r.union(e,this.successors(t))},s.prototype.isLeaf=function(t){return 0===(this.isDirected()?this.successors(t):this.neighbors(t)).length},s.prototype.filterNodes=function(t){var e=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});e.setGraph(this.graph());var n=this;r.each(this._nodes,(function(n,r){t(r)&&e.setNode(r,n)})),r.each(this._edgeObjs,(function(t){e.hasNode(t.v)&&e.hasNode(t.w)&&e.setEdge(t,n.edge(t))}));var o={};function i(t){var r=n.parent(t);return void 0===r||e.hasNode(r)?(o[t]=r,r):r in o?o[r]:i(r)}return this._isCompound&&r.each(e.nodes(),(function(t){e.setParent(t,i(t))})),e},s.prototype.setDefaultEdgeLabel=function(t){return r.isFunction(t)||(t=r.constant(t)),this._defaultEdgeLabelFn=t,this},s.prototype.edgeCount=function(){return this._edgeCount},s.prototype.edges=function(){return r.values(this._edgeObjs)},s.prototype.setPath=function(t,e){var n=this,o=arguments;return r.reduce(t,(function(t,r){return o.length>1?n.setEdge(t,r,e):n.setEdge(t,r),r})),this},s.prototype.setEdge=function(){var t,e,n,o,i=!1,a=arguments[0];"object"==typeof a&&null!==a&&"v"in a?(t=a.v,e=a.w,n=a.name,2===arguments.length&&(o=arguments[1],i=!0)):(t=a,e=arguments[1],n=arguments[3],arguments.length>2&&(o=arguments[2],i=!0)),t=""+t,e=""+e,r.isUndefined(n)||(n=""+n);var s=l(this._isDirected,t,e,n);if(r.has(this._edgeLabels,s))return i&&(this._edgeLabels[s]=o),this;if(!r.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[s]=i?o:this._defaultEdgeLabelFn(t,e,n);var c=function(t,e,n,r){var o=""+e,i=""+n;if(!t&&o>i){var a=o;o=i,i=a}var s={v:o,w:i};r&&(s.name=r);return s}(this._isDirected,t,e,n);return t=c.v,e=c.w,Object.freeze(c),this._edgeObjs[s]=c,u(this._preds[e],t),u(this._sucs[t],e),this._in[e][s]=c,this._out[t][s]=c,this._edgeCount++,this},s.prototype.edge=function(t,e,n){var r=1===arguments.length?f(this._isDirected,arguments[0]):l(this._isDirected,t,e,n);return this._edgeLabels[r]},s.prototype.hasEdge=function(t,e,n){var o=1===arguments.length?f(this._isDirected,arguments[0]):l(this._isDirected,t,e,n);return r.has(this._edgeLabels,o)},s.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?f(this._isDirected,arguments[0]):l(this._isDirected,t,e,n),o=this._edgeObjs[r];return o&&(t=o.v,e=o.w,delete this._edgeLabels[r],delete this._edgeObjs[r],c(this._preds[e],t),c(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},s.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var o=r.values(n);return e?r.filter(o,(function(t){return t.v===e})):o}},s.prototype.outEdges=function(t,e){var n=this._out[t];if(n){var o=r.values(n);return e?r.filter(o,(function(t){return t.w===e})):o}},s.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);if(n)return n.concat(this.outEdges(t,e))}},function(t,e,n){var r=n(15)(n(8),"Map");t.exports=r},function(t,e,n){var r=n(219),o=n(226),i=n(228),a=n(229),s=n(230);function u(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=o,u.prototype.get=i,u.prototype.has=a,u.prototype.set=s,t.exports=u},function(t,e){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e){t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},function(t,e,n){(function(t){var r=n(90),o=e&&!e.nodeType&&e,i=o&&"object"==typeof t&&t&&!t.nodeType&&t,a=i&&i.exports===o&&r.process,s=function(){try{var t=i&&i.require&&i.require("util").types;return t||a&&a.binding&&a.binding("util")}catch(t){}}();t.exports=s}).call(this,n(68)(t))},function(t,e,n){var r=n(47),o=n(236),i=Object.prototype.hasOwnProperty;t.exports=function(t){if(!r(t))return o(t);var e=[];for(var n in Object(t))i.call(t,n)&&"constructor"!=n&&e.push(n);return e}},function(t,e,n){var r=n(97),o=n(98),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(t){return null==t?[]:(t=Object(t),r(a(t),(function(e){return i.call(t,e)})))}:o;t.exports=s},function(t,e){t.exports=function(t,e){for(var n=-1,r=e.length,o=t.length;++n<r;)t[o+n]=e[n];return t}},function(t,e,n){var r=n(103);t.exports=function(t){var e=new t.constructor(t.byteLength);return new r(e).set(new r(t)),e}},function(t,e){t.exports=function(t){return function(){return t}}},function(t,e,n){var r=n(77),o=n(12);t.exports=function(t,e){return t&&r(t,e,o)}},function(t,e,n){var r=n(255)();t.exports=r},function(t,e){t.exports=function(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}},function(t,e,n){var r=n(2),o=n(25),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;t.exports=function(t,e){if(r(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!o(t))||(a.test(t)||!i.test(t)||null!=e&&t in Object(e))}},function(t,e,n){var r=n(73),o=n(289);t.exports=function t(e,n,i,a,s){var u=-1,c=e.length;for(i||(i=o),s||(s=[]);++u<c;){var l=e[u];n>0&&i(l)?n>1?t(l,n-1,i,a,s):r(s,l):a||(s[s.length]=l)}return s}},function(t,e,n){var r=n(25);t.exports=function(t,e,n){for(var o=-1,i=t.length;++o<i;){var a=t[o],s=e(a);if(null!=s&&(void 0===u?s==s&&!r(s):n(s,u)))var u=s,c=a}return c}},function(t,e,n){function r(t,e){this.init(t,e)}r.prototype.init=function(t,e){this.name=t,this.args=e},t.exports=r},function(t,e,n){var r=n(0),o=/-([a-z])/g,i=/^--[a-zA-Z0-9-]+$|^[^-]+$/;var a=r.version.split(".")[0]>=16;t.exports={PRESERVE_CUSTOM_ATTRIBUTES:a,camelCase:function(t){if("string"!=typeof t)throw new TypeError("First argument must be a string");return i.test(t)?t:t.toLowerCase().replace(o,(function(t,e){return e.toUpperCase()}))},invertObject:function(t,e){if(!t||"object"!=typeof t)throw new TypeError("First argument must be an object");var n,r,o="function"==typeof e,i={},a={};for(n in t)r=t[n],o&&(i=e(n,r))&&2===i.length?a[i[0]]=i[1]:"string"==typeof r&&(a[r]=n);return a},isCustomComponent:function(t,e){if(-1===t.indexOf("-"))return e&&"string"==typeof e.is;switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}}},,,,,,function(t,e,n){var r=n(38),o=n(67),i=n(43),a=n(231),s=n(237),u=n(95),c=n(96),l=n(240),f=n(241),h=n(100),d=n(242),p=n(24),y=n(246),v=n(247),g=n(105),x=n(2),m=n(23),w=n(251),b=n(6),E=n(253),_=n(12),M=n(17),N="[object Arguments]",k="[object Function]",A="[object Object]",C={};C[N]=C["[object Array]"]=C["[object ArrayBuffer]"]=C["[object DataView]"]=C["[object Boolean]"]=C["[object Date]"]=C["[object Float32Array]"]=C["[object Float64Array]"]=C["[object Int8Array]"]=C["[object Int16Array]"]=C["[object Int32Array]"]=C["[object Map]"]=C["[object Number]"]=C[A]=C["[object RegExp]"]=C["[object Set]"]=C["[object String]"]=C["[object Symbol]"]=C["[object Uint8Array]"]=C["[object Uint8ClampedArray]"]=C["[object Uint16Array]"]=C["[object Uint32Array]"]=!0,C["[object Error]"]=C[k]=C["[object WeakMap]"]=!1,t.exports=function t(e,n,S,P,O,T){var j,R=1&n,I=2&n,L=4&n;if(S&&(j=O?S(e,P,O,T):S(e)),void 0!==j)return j;if(!b(e))return e;var D=x(e);if(D){if(j=y(e),!R)return c(e,j)}else{var B=p(e),z=B==k||"[object GeneratorFunction]"==B;if(m(e))return u(e,R);if(B==A||B==N||z&&!O){if(j=I||z?{}:g(e),!R)return I?f(e,s(j,e)):l(e,a(j,e))}else{if(!C[B])return O?e:{};j=v(e,B,R)}}T||(T=new r);var U=T.get(e);if(U)return U;T.set(e,j),E(e)?e.forEach((function(r){j.add(t(r,n,S,r,e,T))})):w(e)&&e.forEach((function(r,o){j.set(o,t(r,n,S,o,e,T))}));var F=D?void 0:(L?I?d:h:I?M:_)(e);return o(F||e,(function(r,o){F&&(r=e[o=r]),i(j,o,t(r,n,S,o,e,T))})),j}},function(t,e,n){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(this,n(213))},function(t,e){var n=Function.prototype.toString;t.exports=function(t){if(null!=t){try{return n.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},function(t,e,n){var r=n(15),o=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=o},function(t,e,n){var r=n(232),o=n(29),i=n(2),a=n(23),s=n(45),u=n(30),c=Object.prototype.hasOwnProperty;t.exports=function(t,e){var n=i(t),l=!n&&o(t),f=!n&&!l&&a(t),h=!n&&!l&&!f&&u(t),d=n||l||f||h,p=d?r(t.length,String):[],y=p.length;for(var v in t)!e&&!c.call(t,v)||d&&("length"==v||f&&("offset"==v||"parent"==v)||h&&("buffer"==v||"byteLength"==v||"byteOffset"==v)||s(v,y))||p.push(v);return p}},function(t,e){t.exports=function(t,e){return function(n){return t(e(n))}}},function(t,e,n){(function(t){var r=n(8),o=e&&!e.nodeType&&e,i=o&&"object"==typeof t&&t&&!t.nodeType&&t,a=i&&i.exports===o?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var n=t.length,r=s?s(n):new t.constructor(n);return t.copy(r),r}}).call(this,n(68)(t))},function(t,e){t.exports=function(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}},function(t,e){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length,o=0,i=[];++n<r;){var a=t[n];e(a,n,t)&&(i[o++]=a)}return i}},function(t,e){t.exports=function(){return[]}},function(t,e,n){var r=n(73),o=n(48),i=n(72),a=n(98),s=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)r(e,i(t)),t=o(t);return e}:a;t.exports=s},function(t,e,n){var r=n(101),o=n(72),i=n(12);t.exports=function(t){return r(t,i,o)}},function(t,e,n){var r=n(73),o=n(2);t.exports=function(t,e,n){var i=e(t);return o(t)?i:r(i,n(t))}},function(t,e,n){var r=n(15)(n(8),"Set");t.exports=r},function(t,e,n){var r=n(8).Uint8Array;t.exports=r},function(t,e,n){var r=n(74);t.exports=function(t,e){var n=e?r(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}},function(t,e,n){var r=n(106),o=n(48),i=n(47);t.exports=function(t){return"function"!=typeof t.constructor||i(t)?{}:r(o(t))}},function(t,e,n){var r=n(6),o=Object.create,i=function(){function t(){}return function(e){if(!r(e))return{};if(o)return o(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();t.exports=i},function(t,e,n){t.exports=n(108)},function(t,e,n){var r=n(67),o=n(49),i=n(109),a=n(2);t.exports=function(t,e){return(a(t)?r:o)(t,i(e))}},function(t,e,n){var r=n(18);t.exports=function(t){return"function"==typeof t?t:r}},function(t,e,n){var r=n(97),o=n(257),i=n(11),a=n(2);t.exports=function(t,e){return(a(t)?r:o)(t,i(e,3))}},function(t,e,n){var r=n(260),o=n(9);t.exports=function t(e,n,i,a,s){return e===n||(null==e||null==n||!o(e)&&!o(n)?e!=e&&n!=n:r(e,n,i,a,t,s))}},function(t,e,n){var r=n(113),o=n(263),i=n(114);t.exports=function(t,e,n,a,s,u){var c=1&n,l=t.length,f=e.length;if(l!=f&&!(c&&f>l))return!1;var h=u.get(t),d=u.get(e);if(h&&d)return h==e&&d==t;var p=-1,y=!0,v=2&n?new r:void 0;for(u.set(t,e),u.set(e,t);++p<l;){var g=t[p],x=e[p];if(a)var m=c?a(x,g,p,e,t,u):a(g,x,p,t,e,u);if(void 0!==m){if(m)continue;y=!1;break}if(v){if(!o(e,(function(t,e){if(!i(v,e)&&(g===t||s(g,t,n,a,u)))return v.push(e)}))){y=!1;break}}else if(g!==x&&!s(g,x,n,a,u)){y=!1;break}}return u.delete(t),u.delete(e),y}},function(t,e,n){var r=n(66),o=n(261),i=n(262);function a(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new r;++e<n;)this.add(t[e])}a.prototype.add=a.prototype.push=o,a.prototype.has=i,t.exports=a},function(t,e){t.exports=function(t,e){return t.has(e)}},function(t,e,n){var r=n(6);t.exports=function(t){return t==t&&!r(t)}},function(t,e){t.exports=function(t,e){return function(n){return null!=n&&(n[t]===e&&(void 0!==e||t in Object(n)))}}},function(t,e,n){var r=n(273);t.exports=function(t){return null==t?"":r(t)}},function(t,e,n){var r=n(274),o=n(119);t.exports=function(t,e){return null!=t&&o(t,e,r)}},function(t,e,n){var r=n(51),o=n(29),i=n(2),a=n(45),s=n(69),u=n(31);t.exports=function(t,e,n){for(var c=-1,l=(e=r(e,t)).length,f=!1;++c<l;){var h=u(e[c]);if(!(f=null!=t&&n(t,h)))break;t=t[h]}return f||++c!=l?f:!!(l=null==t?0:t.length)&&s(l)&&a(h,l)&&(i(t)||o(t))}},function(t,e){t.exports=function(t){return function(e){return null==e?void 0:e[t]}}},function(t,e,n){var r=n(277),o=n(119);t.exports=function(t,e){return null!=t&&o(t,e,r)}},function(t,e){t.exports=function(t){return void 0===t}},function(t,e,n){var r=n(52),o=n(11),i=n(124),a=n(2);t.exports=function(t,e){return(a(t)?r:i)(t,o(e,3))}},function(t,e,n){var r=n(49),o=n(10);t.exports=function(t,e){var n=-1,i=o(t)?Array(t.length):[];return r(t,(function(t,r,o){i[++n]=e(t,r,o)})),i}},function(t,e,n){var r=n(279),o=n(49),i=n(11),a=n(280),s=n(2);t.exports=function(t,e,n){var u=s(t)?r:a,c=arguments.length<3;return u(t,i(e,4),n,c,o)}},function(t,e,n){var r=n(290),o=Math.max;t.exports=function(t,e,n){return e=o(void 0===e?t.length-1:e,0),function(){for(var i=arguments,a=-1,s=o(i.length-e,0),u=Array(s);++a<s;)u[a]=i[e+a];a=-1;for(var c=Array(e+1);++a<e;)c[a]=i[a];return c[e]=n(u),r(t,this,c)}}},function(t,e,n){var r=n(291),o=n(292)(r);t.exports=o},function(t,e){t.exports=function(t,e,n,r){for(var o=t.length,i=n+(r?1:-1);r?i--:++i<o;)if(e(t[i],i,t))return i;return-1}},function(t,e,n){var r=n(10),o=n(9);t.exports=function(t){return o(t)&&r(t)}},function(t,e,n){var r=n(301),o=n(12);t.exports=function(t){return null==t?[]:r(t,o(t))}},function(t,e,n){var r=n(5),o=n(132);t.exports=function(t,e,n,r){return function(t,e,n,r){var i,a,s={},u=new o,c=function(t){var e=t.v!==i?t.v:t.w,r=s[e],o=n(t),c=a.distance+o;if(o<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+t+" Weight: "+o);c<r.distance&&(r.distance=c,r.predecessor=i,u.decrease(e,c))};t.nodes().forEach((function(t){var n=t===e?0:Number.POSITIVE_INFINITY;s[t]={distance:n},u.add(t,n)}));for(;u.size()>0&&(i=u.removeMin(),(a=s[i]).distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return s}(t,String(e),n||i,r||function(e){return t.outEdges(e)})};var i=r.constant(1)},function(t,e,n){var r=n(5);function o(){this._arr=[],this._keyIndices={}}t.exports=o,o.prototype.size=function(){return this._arr.length},o.prototype.keys=function(){return this._arr.map((function(t){return t.key}))},o.prototype.has=function(t){return r.has(this._keyIndices,t)},o.prototype.priority=function(t){var e=this._keyIndices[t];if(void 0!==e)return this._arr[e].priority},o.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},o.prototype.add=function(t,e){var n=this._keyIndices;if(t=String(t),!r.has(n,t)){var o=this._arr,i=o.length;return n[t]=i,o.push({key:t,priority:e}),this._decrease(i),!0}return!1},o.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},o.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)},o.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,o=t;n<e.length&&(o=e[n].priority<e[o].priority?n:o,r<e.length&&(o=e[r].priority<e[o].priority?r:o),o!==t&&(this._swap(t,o),this._heapify(o)))},o.prototype._decrease=function(t){for(var e,n=this._arr,r=n[t].priority;0!==t&&!(n[e=t>>1].priority<r);)this._swap(t,e),t=e},o.prototype._swap=function(t,e){var n=this._arr,r=this._keyIndices,o=n[t],i=n[e];n[t]=i,n[e]=o,r[i.key]=t,r[o.key]=e}},function(t,e,n){var r=n(5);t.exports=function(t){var e=0,n=[],o={},i=[];function a(s){var u=o[s]={onStack:!0,lowlink:e,index:e++};if(n.push(s),t.successors(s).forEach((function(t){r.has(o,t)?o[t].onStack&&(u.lowlink=Math.min(u.lowlink,o[t].index)):(a(t),u.lowlink=Math.min(u.lowlink,o[t].lowlink))})),u.lowlink===u.index){var c,l=[];do{c=n.pop(),o[c].onStack=!1,l.push(c)}while(s!==c);i.push(l)}}return t.nodes().forEach((function(t){r.has(o,t)||a(t)})),i}},function(t,e,n){var r=n(5);function o(t){var e={},n={},o=[];if(r.each(t.sinks(),(function a(s){if(r.has(n,s))throw new i;r.has(e,s)||(n[s]=!0,e[s]=!0,r.each(t.predecessors(s),a),delete n[s],o.push(s))})),r.size(e)!==t.nodeCount())throw new i;return o}function i(){}t.exports=o,o.CycleException=i,i.prototype=new Error},function(t,e,n){var r=n(5);function o(t,e,n,i,a,s){r.has(i,e)||(i[e]=!0,n||s.push(e),r.each(a(e),(function(e){o(t,e,n,i,a,s)})),n&&s.push(e))}t.exports=function(t,e,n){r.isArray(e)||(e=[e]);var i=(t.isDirected()?t.successors:t.neighbors).bind(t),a=[],s={};return r.each(e,(function(e){if(!t.hasNode(e))throw new Error("Graph does not have node: "+e);o(t,e,"post"===n,s,i,a)})),a}},function(t,e,n){var r=n(320),o=1/0;t.exports=function(t){return t?(t=r(t))===o||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}},function(t,e,n){var r=n(80);t.exports=function(t){return(null==t?0:t.length)?r(t,1):[]}},function(t,e,n){var r=n(44),o=n(21);t.exports=function(t,e,n){(void 0!==n&&!o(t[e],n)||void 0===n&&!(e in t))&&r(t,e,n)}},function(t,e){t.exports=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}},function(t,e){t.exports=function(t,e){return t<e}},function(t,e,n){"use strict";var r=n(1),o=n(7).Graph,i=n(55).slack;function a(t,e){return r.forEach(t.nodes(),(function n(o){r.forEach(e.nodeEdges(o),(function(r){var a=r.v,s=o===a?r.w:a;t.hasNode(s)||i(e,r)||(t.setNode(s,{}),t.setEdge(o,s,{}),n(s))}))})),t.nodeCount()}function s(t,e){return r.minBy(e.edges(),(function(n){if(t.hasNode(n.v)!==t.hasNode(n.w))return i(e,n)}))}function u(t,e,n){r.forEach(t.nodes(),(function(t){e.node(t).rank+=n}))}t.exports=function(t){var e,n,r=new o({directed:!1}),c=t.nodes()[0],l=t.nodeCount();r.setNode(c,{});for(;a(r,t)<l;)e=s(r,t),n=r.hasNode(e.v)?i(t,e):-i(t,e),u(r,t,n);return r}},function(t,e,n){e.Polynomial=n(143),e.SqrtPolynomial=n(380)},function(t,e,n){function r(){this.init(arguments)}r.TOLERANCE=1e-6,r.ACCURACY=15,r.interpolate=function(t,e,n,r,o){if(t.constructor!==Array||e.constructor!==Array)throw new Error("Polynomial.interpolate: xs and ys must be arrays");if(isNaN(n)||isNaN(r)||isNaN(o))throw new Error("Polynomial.interpolate: n, offset, and x must be numbers");for(var i=0,a=0,s=new Array(n),u=new Array(n),c=0,l=Math.abs(o-t[r]),f=0;f<n;f++){var h=Math.abs(o-t[r+f]);h<l&&(c=f,l=h),s[f]=u[f]=e[r+f]}i=e[r+c],c--;for(var d=1;d<n;d++){for(f=0;f<n-d;f++){var p=t[r+f]-o,y=t[r+f+d]-o,v=s[f+1]-u[f],g=p-y;if(0==g){({y:0,dy:0});break}g=v/g,u[f]=y*g,s[f]=p*g}i+=a=2*(c+1)<n-d?s[c+1]:u[c--]}return{y:i,dy:a}},r.prototype.init=function(t){this.coefs=new Array;for(var e=t.length-1;e>=0;e--)this.coefs.push(t[e]);this._variable="t",this._s=0},r.prototype.eval=function(t){if(isNaN(t))throw new Error("Polynomial.eval: parameter must be a number");for(var e=0,n=this.coefs.length-1;n>=0;n--)e=e*t+this.coefs[n];return e},r.prototype.add=function(t){for(var e=new r,n=this.getDegree(),o=t.getDegree(),i=Math.max(n,o),a=0;a<=i;a++){var s=a<=n?this.coefs[a]:0,u=a<=o?t.coefs[a]:0;e.coefs[a]=s+u}return e},r.prototype.multiply=function(t){for(var e=new r,n=0;n<=this.getDegree()+t.getDegree();n++)e.coefs.push(0);for(n=0;n<=this.getDegree();n++)for(var o=0;o<=t.getDegree();o++)e.coefs[n+o]+=this.coefs[n]*t.coefs[o];return e},r.prototype.divide_scalar=function(t){for(var e=0;e<this.coefs.length;e++)this.coefs[e]/=t},r.prototype.simplify=function(){for(var t=this.getDegree();t>=0&&Math.abs(this.coefs[t])<=1e-15;t--)this.coefs.pop()},r.prototype.bisection=function(t,e){var n,o=this.eval(t),i=this.eval(e);if(Math.abs(o)<=r.TOLERANCE)n=t;else if(Math.abs(i)<=r.TOLERANCE)n=e;else if(o*i<=0)for(var a=Math.log(e-t),s=Math.LN10*r.ACCURACY,u=Math.ceil((a+s)/Math.LN2),c=0;c<u;c++){n=.5*(t+e);var l=this.eval(n);if(Math.abs(l)<=r.TOLERANCE)break;l*o<0?(e=n,i=l):(t=n,o=l)}return n},r.prototype.toString=function(){for(var t=new Array,e=new Array,n=this.coefs.length-1;n>=0;n--){var r=Math.round(1e3*this.coefs[n])/1e3;if(0!=r){var o=r<0?" - ":" + ";r=Math.abs(r),n>0&&(1==r?r=this._variable:r+=this._variable),n>1&&(r+="^"+n),e.push(o),t.push(r)}}e[0]=" + "==e[0]?"":"-";var i="";for(n=0;n<t.length;n++)i+=e[n]+t[n];return i},r.prototype.trapezoid=function(t,e,n){if(isNaN(t)||isNaN(e)||isNaN(n))throw new Error("Polynomial.trapezoid: parameters must be numbers");var r=e-t;if(1==n){var o=this.eval(t),i=this.eval(e);this._s=.5*r*(o+i)}else{for(var a=1<<n-2,s=r/a,u=t+.5*s,c=0,l=0;l<a;l++)c+=this.eval(u),u+=s;this._s=.5*(this._s+r*c/a)}if(isNaN(this._s))throw new Error("Polynomial.trapezoid: this._s is NaN");return this._s},r.prototype.simpson=function(t,e){if(isNaN(t)||isNaN(e))throw new Error("Polynomial.simpson: parameters must be numbers");for(var n=e-t,r=.5*n*(this.eval(t)+this.eval(e)),o=r,i=4*r/3,a=i,s=r,u=1,c=2;c<=20;c++){for(var l=n/u,f=t+.5*l,h=0,d=1;d<=u;d++)h+=this.eval(f),f+=l;if(i=(4*(r=o=.5*(o+n*h/u))-s)/3,Math.abs(i-a)<1e-7*Math.abs(a))break;a=i,s=r,u<<=1}return i},r.prototype.romberg=function(t,e){if(isNaN(t)||isNaN(e))throw new Error("Polynomial.romberg: parameters must be numbers");var n=new Array(21),o=new Array(21),i={y:0,dy:0};o[0]=1;for(var a=1;a<=20&&(n[a-1]=this.trapezoid(t,e,a),!(a>=3&&(i=r.interpolate(o,n,3,a-3,0),Math.abs(i.dy)<=1e-6*i.y)));a++)n[a]=n[a-1],o[a]=.25*o[a-1];return i.y},r.prototype.getDegree=function(){return this.coefs.length-1},r.prototype.getDerivative=function(){for(var t=new r,e=1;e<this.coefs.length;e++)t.coefs.push(e*this.coefs[e]);return t},r.prototype.getRoots=function(){var t;switch(this.simplify(),this.getDegree()){case 0:default:t=new Array;break;case 1:t=this.getLinearRoot();break;case 2:t=this.getQuadraticRoots();break;case 3:t=this.getCubicRoots();break;case 4:t=this.getQuarticRoots()}return t},r.prototype.getRootsInInterval=function(t,e){var n,r=new Array;if(1==this.getDegree())null!=(n=this.bisection(t,e))&&r.push(n);else{var o=this.getDerivative().getRootsInInterval(t,e);if(o.length>0){for(null!=(n=this.bisection(t,o[0]))&&r.push(n),i=0;i<=o.length-2;i++)null!=(n=this.bisection(o[i],o[i+1]))&&r.push(n);null!=(n=this.bisection(o[o.length-1],e))&&r.push(n)}else null!=(n=this.bisection(t,e))&&r.push(n)}return r},r.prototype.getLinearRoot=function(){var t=new Array,e=this.coefs[1];return 0!=e&&t.push(-this.coefs[0]/e),t},r.prototype.getQuadraticRoots=function(){var t=new Array;if(2==this.getDegree()){var e=this.coefs[2],n=this.coefs[1]/e,r=n*n-4*(this.coefs[0]/e);if(r>0){var o=Math.sqrt(r);t.push(.5*(-n+o)),t.push(.5*(-n-o))}else 0==r&&t.push(.5*-n)}return t},r.prototype.getCubicRoots=function(){var t=new Array;if(3==this.getDegree()){var e=this.coefs[3],n=this.coefs[2]/e,r=this.coefs[1]/e,o=(3*r-n*n)/3,i=(2*n*n*n-9*r*n+27*(this.coefs[0]/e))/27,a=n/3,s=i*i/4+o*o*o/27,u=i/2,c=this.zeroErrorEstimate();if(Math.abs(s)<=c&&(s=0),s>0){var l,f=Math.sqrt(s);l=(g=-u+f)>=0?Math.pow(g,1/3):-Math.pow(-g,1/3),(g=-u-f)>=0?l+=Math.pow(g,1/3):l-=Math.pow(-g,1/3),t.push(l-a)}else if(s<0){var h=Math.sqrt(-o/3),d=Math.atan2(Math.sqrt(-s),-u)/3,p=Math.cos(d),y=Math.sin(d),v=Math.sqrt(3);t.push(2*h*p-a),t.push(-h*(p+v*y)-a),t.push(-h*(p-v*y)-a)}else{var g;g=u>=0?-Math.pow(u,1/3):Math.pow(-u,1/3),t.push(2*g-a),t.push(-g-a)}}return t};var o=function(t){return"number"==typeof t?t?t<0?-1:1:t==t?t:NaN:NaN};r.prototype.getQuarticRoots=function(){var t=[],e=this.getDegree();if(4==e){var n=new r;n.coefs=this.coefs.slice(),n.divide_scalar(n.coefs[e]);Math.abs(n.coefs[0])<10*1e-15*Math.abs(n.coefs[3])&&(n.coefs[0]=0);var i,a=n.getDerivative(),s=a.getRoots().sort((function(t,e){return t-e})),u=[],c=s.length-1,l=this.bounds();maxabsX=Math.max(Math.abs(l.minX),Math.abs(l.maxX));var f=this.zeroErrorEstimate(maxabsX);for(i=0;i<=c;i++)u.push(n.eval(s[i]));for(i=0;i<=c;i++)Math.abs(u[i])<f&&(u[i]=0);i=0;var h=Math.max(.1*(l.maxX-l.minX)/e,1e-15),d=[],p=[];if(c>-1){for(0!=u[0]?o(u[0])!=o(n.eval(s[0]-h)-u[0])&&(d.push(s[0]-h),p.push([l.minX,s[0]])):(t.push(s[0],s[0]),i++);i<c;i++)0==u[i+1]?(t.push(s[i+1],s[i+1]),i++):o(u[i])!=o(u[i+1])&&(d.push((s[i]+s[i+1])/2),p.push([s[i],s[i+1]]));0!=u[c]&&o(u[c])!=o(n.eval(s[c]+h)-u[c])&&(d.push(s[c]+h),p.push([s[c],l.maxX]))}var y=function(t){return n.eval(t)},v=function(t){return a.eval(t)};if(d.length>0)for(i=0;i<d.length;i++)d[i]=r.newton_secant_bisection(d[i],y,v,32,p[i][0],p[i][1]);t=t.concat(d)}return t},r.prototype.zeroErrorEstimate=function(t){var e=this;if(void 0===t){var n=e.bounds();t=Math.max(Math.abs(n.minX),Math.abs(n.maxX))}if(t<.001)return 2*Math.abs(e.eval(1e-15));var r=e.coefs.length-1,o=e.coefs[r];return 10*1e-15*e.coefs.reduce((function(e,n,r){var i=n/o*Math.pow(t,r);return i>e?i:e}),0)},r.prototype.bounds_UpperReal_Fujiwara=function(){var t=this.coefs,e=t.length-1,n=t[e];1!=n&&(t=this.coefs.map((function(t){return t/n})));var r,o=t.map((function(t,n){return n<e?Math.pow(Math.abs(0==n?t/2:t),1/(e-n)):t})),i=function(t,e,n){return r(n)&&(t.max<e?(t.nearmax=t.max,t.max=e