markdown-flow-ui 0.1.118-dev.1 → 0.1.118-dev.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/index.cjs10.js +1 -1
- package/dist/_virtual/index.cjs11.js +1 -1
- package/dist/_virtual/index.cjs5.js +1 -1
- package/dist/_virtual/index.cjs6.js +1 -1
- package/dist/_virtual/index.es10.js +2 -3
- package/dist/_virtual/index.es10.js.map +1 -1
- package/dist/_virtual/index.es11.js +3 -2
- package/dist/_virtual/index.es11.js.map +1 -1
- package/dist/_virtual/index.es5.js +4 -4
- package/dist/_virtual/index.es6.js +4 -4
- package/dist/components/ContentRender/IframeSandbox.cjs.js +6 -6
- package/dist/components/ContentRender/IframeSandbox.cjs.js.map +1 -1
- package/dist/components/ContentRender/IframeSandbox.es.js +200 -200
- package/dist/components/ContentRender/IframeSandbox.es.js.map +1 -1
- package/dist/components/ContentRender/SandboxApp.cjs.js +12 -11
- package/dist/components/ContentRender/SandboxApp.cjs.js.map +1 -1
- package/dist/components/ContentRender/SandboxApp.es.js +82 -82
- package/dist/components/ContentRender/SandboxApp.es.js.map +1 -1
- package/dist/node_modules/@braintree/sanitize-url/dist/index.cjs.js +1 -1
- package/dist/node_modules/@braintree/sanitize-url/dist/index.es.js +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/layout-base/layout-base.cjs.js +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/layout-base/layout-base.cjs.js.map +1 -1
- package/dist/node_modules/cytoscape-fcose/node_modules/layout-base/layout-base.es.js +1 -1
- package/dist/node_modules/hast-util-to-jsx-runtime/lib/index.cjs.js +1 -1
- package/dist/node_modules/hast-util-to-jsx-runtime/lib/index.es.js +1 -1
- package/dist/node_modules/layout-base/layout-base.cjs.js +1 -1
- package/dist/node_modules/layout-base/layout-base.cjs.js.map +1 -1
- package/dist/node_modules/layout-base/layout-base.es.js +1 -1
- package/dist/node_modules/rc-util/es/ref.cjs.js +1 -1
- package/dist/node_modules/rc-util/es/ref.es.js +1 -1
- package/dist/node_modules/unified/lib/index.cjs.js +1 -1
- package/dist/node_modules/unified/lib/index.es.js +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const w=require("../../comma-separated-tokens/index.cjs.js"),u=require("../../devlop/lib/default.cjs.js"),f=require("../../property-information/index.cjs.js"),C=require("../../space-separated-tokens/index.cjs.js"),S=require("../../../_virtual/index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const w=require("../../comma-separated-tokens/index.cjs.js"),u=require("../../devlop/lib/default.cjs.js"),f=require("../../property-information/index.cjs.js"),C=require("../../space-separated-tokens/index.cjs.js"),S=require("../../../_virtual/index.cjs5.js"),N=require("../../hast-util-whitespace/lib/index.cjs.js"),x=require("../../estree-util-is-identifier-name/lib/index.cjs.js"),h=require("../../vfile-message/lib/index.cjs.js"),j=require("../../property-information/lib/find.cjs.js"),A=require("../../property-information/lib/hast-to-react.cjs.js"),T=require("../../unist-util-position/lib/index.cjs.js"),m={}.hasOwnProperty,F=new Map,P=/[A-Z]/g,q=new Set(["table","tbody","thead","tfoot","tr"]),J=new Set(["td","th"]),g="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function M(t,e){if(!e||e.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const r=e.filePath||void 0;let n;if(e.development){if(typeof e.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");n=K(r,e.jsxDEV)}else{if(typeof e.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof e.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");n=k(r,e.jsx,e.jsxs)}const s={Fragment:e.Fragment,ancestors:[],components:e.components||{},create:n,elementAttributeNameCase:e.elementAttributeNameCase||"react",evaluater:e.createEvaluater?e.createEvaluater():void 0,filePath:r,ignoreInvalidStyle:e.ignoreInvalidStyle||!1,passKeys:e.passKeys!==!1,passNode:e.passNode||!1,schema:e.space==="svg"?f.svg:f.html,stylePropertyNameCase:e.stylePropertyNameCase||"dom",tableCellAlignToStyle:e.tableCellAlignToStyle!==!1},i=E(s,t,void 0);return i&&typeof i!="string"?i:s.create(t,s.Fragment,{children:i||void 0},void 0)}function E(t,e,r){if(e.type==="element")return I(t,e,r);if(e.type==="mdxFlowExpression"||e.type==="mdxTextExpression")return L(t,e);if(e.type==="mdxJsxFlowElement"||e.type==="mdxJsxTextElement")return V(t,e,r);if(e.type==="mdxjsEsm")return $(t,e);if(e.type==="root")return D(t,e,r);if(e.type==="text")return O(t,e)}function I(t,e,r){const n=t.schema;let s=n;e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(s=f.svg,t.schema=s),t.ancestors.push(e);const i=b(t,e.tagName,!1),a=R(t,e);let o=d(t,e);return q.has(e.tagName)&&(o=o.filter(function(l){return typeof l=="string"?!N.whitespace(l):!0})),v(t,a,i,e),y(a,o),t.ancestors.pop(),t.schema=n,t.create(e,i,a,r)}function L(t,e){if(e.data&&e.data.estree&&t.evaluater){const n=e.data.estree.body[0];return u.ok(n.type==="ExpressionStatement"),t.evaluater.evaluateExpression(n.expression)}p(t,e.position)}function $(t,e){if(e.data&&e.data.estree&&t.evaluater)return t.evaluater.evaluateProgram(e.data.estree);p(t,e.position)}function V(t,e,r){const n=t.schema;let s=n;e.name==="svg"&&n.space==="html"&&(s=f.svg,t.schema=s),t.ancestors.push(e);const i=e.name===null?t.Fragment:b(t,e.name,!0),a=_(t,e),o=d(t,e);return v(t,a,i,e),y(a,o),t.ancestors.pop(),t.schema=n,t.create(e,i,a,r)}function D(t,e,r){const n={};return y(n,d(t,e)),t.create(e,t.Fragment,n,r)}function O(t,e){return e.value}function v(t,e,r,n){typeof r!="string"&&r!==t.Fragment&&t.passNode&&(e.node=n)}function y(t,e){if(e.length>0){const r=e.length>1?e:e[0];r&&(t.children=r)}}function k(t,e,r){return n;function n(s,i,a,o){const c=Array.isArray(a.children)?r:e;return o?c(i,a,o):c(i,a)}}function K(t,e){return r;function r(n,s,i,a){const o=Array.isArray(i.children),l=T.pointStart(n);return e(s,i,a,o,{columnNumber:l?l.column-1:void 0,fileName:t,lineNumber:l?l.line:void 0},void 0)}}function R(t,e){const r={};let n,s;for(s in e.properties)if(s!=="children"&&m.call(e.properties,s)){const i=B(t,s,e.properties[s]);if(i){const[a,o]=i;t.tableCellAlignToStyle&&a==="align"&&typeof o=="string"&&J.has(e.tagName)?n=o:r[a]=o}}if(n){const i=r.style||(r.style={});i[t.stylePropertyNameCase==="css"?"text-align":"textAlign"]=n}return r}function _(t,e){const r={};for(const n of e.attributes)if(n.type==="mdxJsxExpressionAttribute")if(n.data&&n.data.estree&&t.evaluater){const i=n.data.estree.body[0];u.ok(i.type==="ExpressionStatement");const a=i.expression;u.ok(a.type==="ObjectExpression");const o=a.properties[0];u.ok(o.type==="SpreadElement"),Object.assign(r,t.evaluater.evaluateExpression(o.argument))}else p(t,e.position);else{const s=n.name;let i;if(n.value&&typeof n.value=="object")if(n.value.data&&n.value.data.estree&&t.evaluater){const o=n.value.data.estree.body[0];u.ok(o.type==="ExpressionStatement"),i=t.evaluater.evaluateExpression(o.expression)}else p(t,e.position);else i=n.value===null?!0:n.value;r[s]=i}return r}function d(t,e){const r=[];let n=-1;const s=t.passKeys?new Map:F;for(;++n<e.children.length;){const i=e.children[n];let a;if(t.passKeys){const l=i.type==="element"?i.tagName:i.type==="mdxJsxFlowElement"||i.type==="mdxJsxTextElement"?i.name:void 0;if(l){const c=s.get(l)||0;a=l+"-"+c,s.set(l,c+1)}}const o=E(t,i,a);o!==void 0&&r.push(o)}return r}function B(t,e,r){const n=j.find(t.schema,e);if(!(r==null||typeof r=="number"&&Number.isNaN(r))){if(Array.isArray(r)&&(r=n.commaSeparated?w.stringify(r):C.stringify(r)),n.property==="style"){let s=typeof r=="object"?r:z(t,String(r));return t.stylePropertyNameCase==="css"&&(s=X(s)),["style",s]}return[t.elementAttributeNameCase==="react"&&n.space?A.hastToReact[n.property]||n.property:n.attribute,r]}}function z(t,e){try{return S.default(e,{reactCompat:!0})}catch(r){if(t.ignoreInvalidStyle)return{};const n=r,s=new h.VFileMessage("Cannot parse `style` attribute",{ancestors:t.ancestors,cause:n,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw s.file=t.filePath||void 0,s.url=g+"#cannot-parse-style-attribute",s}}function b(t,e,r){let n;if(!r)n={type:"Literal",value:e};else if(e.includes(".")){const s=e.split(".");let i=-1,a;for(;++i<s.length;){const o=x.name(s[i])?{type:"Identifier",name:s[i]}:{type:"Literal",value:s[i]};a=a?{type:"MemberExpression",object:a,property:o,computed:!!(i&&o.type==="Literal"),optional:!1}:o}n=a}else n=x.name(e)&&!/^[a-z]/.test(e)?{type:"Identifier",name:e}:{type:"Literal",value:e};if(n.type==="Literal"){const s=n.value;return m.call(t.components,s)?t.components[s]:s}if(t.evaluater)return t.evaluater.evaluateExpression(n);p(t)}function p(t,e){const r=new h.VFileMessage("Cannot handle MDX estrees without `createEvaluater`",{ancestors:t.ancestors,place:e,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw r.file=t.filePath||void 0,r.url=g+"#cannot-handle-mdx-estrees-without-createevaluater",r}function X(t){const e={};let r;for(r in t)m.call(t,r)&&(e[Z(r)]=t[r]);return e}function Z(t){let e=t.replace(P,G);return e.slice(0,3)==="ms-"&&(e="-"+e),e}function G(t){return"-"+t.toLowerCase()}exports.toJsxRuntime=M;
|
|
2
2
|
//# sourceMappingURL=index.cjs.js.map
|
|
@@ -2,7 +2,7 @@ import { stringify as w } from "../../comma-separated-tokens/index.es.js";
|
|
|
2
2
|
import { ok as u } from "../../devlop/lib/default.es.js";
|
|
3
3
|
import { svg as m, html as C } from "../../property-information/index.es.js";
|
|
4
4
|
import { stringify as N } from "../../space-separated-tokens/index.es.js";
|
|
5
|
-
import S from "../../../_virtual/index.
|
|
5
|
+
import S from "../../../_virtual/index.es5.js";
|
|
6
6
|
import { whitespace as j } from "../../hast-util-whitespace/lib/index.es.js";
|
|
7
7
|
import { name as x } from "../../estree-util-is-identifier-name/lib/index.es.js";
|
|
8
8
|
import { VFileMessage as h } from "../../vfile-message/lib/index.es.js";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const P=require("../../_virtual/layout-base.cjs.js");var W=P.__module.exports,b;function k(){return b||(b=1,(function(H,z){(function(D,v){H.exports=v()})(W,function(){return(function(E){var D={};function v(h){if(D[h])return D[h].exports;var n=D[h]={i:h,l:!1,exports:{}};return E[h].call(n.exports,n,n.exports,v),n.l=!0,n.exports}return v.m=E,v.c=D,v.i=function(h){return h},v.d=function(h,n,e){v.o(h,n)||Object.defineProperty(h,n,{configurable:!1,enumerable:!0,get:e})},v.n=function(h){var n=h&&h.__esModule?function(){return h.default}:function(){return h};return v.d(n,"a",n),n},v.o=function(h,n){return Object.prototype.hasOwnProperty.call(h,n)},v.p="",v(v.s=26)})([(function(E,D,v){function h(){}h.QUALITY=1,h.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,h.DEFAULT_INCREMENTAL=!1,h.DEFAULT_ANIMATION_ON_LAYOUT=!0,h.DEFAULT_ANIMATION_DURING_LAYOUT=!1,h.DEFAULT_ANIMATION_PERIOD=50,h.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,h.DEFAULT_GRAPH_MARGIN=15,h.NODE_DIMENSIONS_INCLUDE_LABELS=!1,h.SIMPLE_NODE_SIZE=40,h.SIMPLE_NODE_HALF_SIZE=h.SIMPLE_NODE_SIZE/2,h.EMPTY_COMPOUND_NODE_SIZE=40,h.MIN_EDGE_LENGTH=1,h.WORLD_BOUNDARY=1e6,h.INITIAL_WORLD_BOUNDARY=h.WORLD_BOUNDARY/1e3,h.WORLD_CENTER_X=1200,h.WORLD_CENTER_Y=900,E.exports=h}),(function(E,D,v){var h=v(2),n=v(8),e=v(9);function i(u,r,g){h.call(this,g),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=g,this.bendpoints=[],this.source=u,this.target=r}i.prototype=Object.create(h.prototype);for(var a in h)i[a]=h[a];i.prototype.getSource=function(){return this.source},i.prototype.getTarget=function(){return this.target},i.prototype.isInterGraph=function(){return this.isInterGraph},i.prototype.getLength=function(){return this.length},i.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},i.prototype.getBendpoints=function(){return this.bendpoints},i.prototype.getLca=function(){return this.lca},i.prototype.getSourceInLca=function(){return this.sourceInLca},i.prototype.getTargetInLca=function(){return this.targetInLca},i.prototype.getOtherEnd=function(u){if(this.source===u)return this.target;if(this.target===u)return this.source;throw"Node is not incident with this edge"},i.prototype.getOtherEndInGraph=function(u,r){for(var g=this.getOtherEnd(u),t=r.getGraphManager().getRoot();;){if(g.getOwner()==r)return g;if(g.getOwner()==t)break;g=g.getOwner().getParent()}return null},i.prototype.updateLength=function(){var u=new Array(4);this.isOverlapingSourceAndTarget=n.getIntersection(this.target.getRect(),this.source.getRect(),u),this.isOverlapingSourceAndTarget||(this.lengthX=u[0]-u[2],this.lengthY=u[1]-u[3],Math.abs(this.lengthX)<1&&(this.lengthX=e.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=e.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},i.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=e.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=e.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},E.exports=i}),(function(E,D,v){function h(n){this.vGraphObject=n}E.exports=h}),(function(E,D,v){var h=v(2),n=v(10),e=v(13),i=v(0),a=v(16),u=v(4);function r(t,o,s,l){s==null&&l==null&&(l=o),h.call(this,l),t.graphManager!=null&&(t=t.graphManager),this.estimatedSize=n.MIN_VALUE,this.inclusionTreeDepth=n.MAX_VALUE,this.vGraphObject=l,this.edges=[],this.graphManager=t,s!=null&&o!=null?this.rect=new e(o.x,o.y,s.width,s.height):this.rect=new e}r.prototype=Object.create(h.prototype);for(var g in h)r[g]=h[g];r.prototype.getEdges=function(){return this.edges},r.prototype.getChild=function(){return this.child},r.prototype.getOwner=function(){return this.owner},r.prototype.getWidth=function(){return this.rect.width},r.prototype.setWidth=function(t){this.rect.width=t},r.prototype.getHeight=function(){return this.rect.height},r.prototype.setHeight=function(t){this.rect.height=t},r.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},r.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},r.prototype.getCenter=function(){return new u(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},r.prototype.getLocation=function(){return new u(this.rect.x,this.rect.y)},r.prototype.getRect=function(){return this.rect},r.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},r.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},r.prototype.setRect=function(t,o){this.rect.x=t.x,this.rect.y=t.y,this.rect.width=o.width,this.rect.height=o.height},r.prototype.setCenter=function(t,o){this.rect.x=t-this.rect.width/2,this.rect.y=o-this.rect.height/2},r.prototype.setLocation=function(t,o){this.rect.x=t,this.rect.y=o},r.prototype.moveBy=function(t,o){this.rect.x+=t,this.rect.y+=o},r.prototype.getEdgeListToNode=function(t){var o=[],s=this;return s.edges.forEach(function(l){if(l.target==t){if(l.source!=s)throw"Incorrect edge source!";o.push(l)}}),o},r.prototype.getEdgesBetween=function(t){var o=[],s=this;return s.edges.forEach(function(l){if(!(l.source==s||l.target==s))throw"Incorrect edge source and/or target";(l.target==t||l.source==t)&&o.push(l)}),o},r.prototype.getNeighborsList=function(){var t=new Set,o=this;return o.edges.forEach(function(s){if(s.source==o)t.add(s.target);else{if(s.target!=o)throw"Incorrect incidency!";t.add(s.source)}}),t},r.prototype.withChildren=function(){var t=new Set,o,s;if(t.add(this),this.child!=null)for(var l=this.child.getNodes(),f=0;f<l.length;f++)o=l[f],s=o.withChildren(),s.forEach(function(p){t.add(p)});return t},r.prototype.getNoOfChildren=function(){var t=0,o;if(this.child==null)t=1;else for(var s=this.child.getNodes(),l=0;l<s.length;l++)o=s[l],t+=o.getNoOfChildren();return t==0&&(t=1),t},r.prototype.getEstimatedSize=function(){if(this.estimatedSize==n.MIN_VALUE)throw"assert failed";return this.estimatedSize},r.prototype.calcEstimatedSize=function(){return this.child==null?this.estimatedSize=(this.rect.width+this.rect.height)/2:(this.estimatedSize=this.child.calcEstimatedSize(),this.rect.width=this.estimatedSize,this.rect.height=this.estimatedSize,this.estimatedSize)},r.prototype.scatter=function(){var t,o,s=-i.INITIAL_WORLD_BOUNDARY,l=i.INITIAL_WORLD_BOUNDARY;t=i.WORLD_CENTER_X+a.nextDouble()*(l-s)+s;var f=-i.INITIAL_WORLD_BOUNDARY,p=i.INITIAL_WORLD_BOUNDARY;o=i.WORLD_CENTER_Y+a.nextDouble()*(p-f)+f,this.rect.x=t,this.rect.y=o},r.prototype.updateBounds=function(){if(this.getChild()==null)throw"assert failed";if(this.getChild().getNodes().length!=0){var t=this.getChild();if(t.updateBounds(!0),this.rect.x=t.getLeft(),this.rect.y=t.getTop(),this.setWidth(t.getRight()-t.getLeft()),this.setHeight(t.getBottom()-t.getTop()),i.NODE_DIMENSIONS_INCLUDE_LABELS){var o=t.getRight()-t.getLeft(),s=t.getBottom()-t.getTop();this.labelWidth>o&&(this.rect.x-=(this.labelWidth-o)/2,this.setWidth(this.labelWidth)),this.labelHeight>s&&(this.labelPos=="center"?this.rect.y-=(this.labelHeight-s)/2:this.labelPos=="top"&&(this.rect.y-=this.labelHeight-s),this.setHeight(this.labelHeight))}}},r.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==n.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},r.prototype.transform=function(t){var o=this.rect.x;o>i.WORLD_BOUNDARY?o=i.WORLD_BOUNDARY:o<-i.WORLD_BOUNDARY&&(o=-i.WORLD_BOUNDARY);var s=this.rect.y;s>i.WORLD_BOUNDARY?s=i.WORLD_BOUNDARY:s<-i.WORLD_BOUNDARY&&(s=-i.WORLD_BOUNDARY);var l=new u(o,s),f=t.inverseTransformPoint(l);this.setLocation(f.x,f.y)},r.prototype.getLeft=function(){return this.rect.x},r.prototype.getRight=function(){return this.rect.x+this.rect.width},r.prototype.getTop=function(){return this.rect.y},r.prototype.getBottom=function(){return this.rect.y+this.rect.height},r.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},E.exports=r}),(function(E,D,v){function h(n,e){n==null&&e==null?(this.x=0,this.y=0):(this.x=n,this.y=e)}h.prototype.getX=function(){return this.x},h.prototype.getY=function(){return this.y},h.prototype.setX=function(n){this.x=n},h.prototype.setY=function(n){this.y=n},h.prototype.getDifference=function(n){return new DimensionD(this.x-n.x,this.y-n.y)},h.prototype.getCopy=function(){return new h(this.x,this.y)},h.prototype.translate=function(n){return this.x+=n.width,this.y+=n.height,this},E.exports=h}),(function(E,D,v){var h=v(2),n=v(10),e=v(0),i=v(6),a=v(3),u=v(1),r=v(13),g=v(12),t=v(11);function o(l,f,p){h.call(this,p),this.estimatedSize=n.MIN_VALUE,this.margin=e.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=l,f!=null&&f instanceof i?this.graphManager=f:f!=null&&f instanceof Layout&&(this.graphManager=f.graphManager)}o.prototype=Object.create(h.prototype);for(var s in h)o[s]=h[s];o.prototype.getNodes=function(){return this.nodes},o.prototype.getEdges=function(){return this.edges},o.prototype.getGraphManager=function(){return this.graphManager},o.prototype.getParent=function(){return this.parent},o.prototype.getLeft=function(){return this.left},o.prototype.getRight=function(){return this.right},o.prototype.getTop=function(){return this.top},o.prototype.getBottom=function(){return this.bottom},o.prototype.isConnected=function(){return this.isConnected},o.prototype.add=function(l,f,p){if(f==null&&p==null){var c=l;if(this.graphManager==null)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(c)>-1)throw"Node already in graph!";return c.owner=this,this.getNodes().push(c),c}else{var d=l;if(!(this.getNodes().indexOf(f)>-1&&this.getNodes().indexOf(p)>-1))throw"Source or target not in graph!";if(!(f.owner==p.owner&&f.owner==this))throw"Both owners must be this graph!";return f.owner!=p.owner?null:(d.source=f,d.target=p,d.isInterGraph=!1,this.getEdges().push(d),f.edges.push(d),p!=f&&p.edges.push(d),d)}},o.prototype.remove=function(l){var f=l;if(l instanceof a){if(f==null)throw"Node is null!";if(!(f.owner!=null&&f.owner==this))throw"Owner graph is invalid!";if(this.graphManager==null)throw"Owner graph manager is invalid!";for(var p=f.edges.slice(),c,d=p.length,y=0;y<d;y++)c=p[y],c.isInterGraph?this.graphManager.remove(c):c.source.owner.remove(c);var L=this.nodes.indexOf(f);if(L==-1)throw"Node not in owner node list!";this.nodes.splice(L,1)}else if(l instanceof u){var c=l;if(c==null)throw"Edge is null!";if(!(c.source!=null&&c.target!=null))throw"Source and/or target is null!";if(!(c.source.owner!=null&&c.target.owner!=null&&c.source.owner==this&&c.target.owner==this))throw"Source and/or target owner is invalid!";var O=c.source.edges.indexOf(c),I=c.target.edges.indexOf(c);if(!(O>-1&&I>-1))throw"Source and/or target doesn't know this edge!";c.source.edges.splice(O,1),c.target!=c.source&&c.target.edges.splice(I,1);var L=c.source.owner.getEdges().indexOf(c);if(L==-1)throw"Not in owner's edge list!";c.source.owner.getEdges().splice(L,1)}},o.prototype.updateLeftTop=function(){for(var l=n.MAX_VALUE,f=n.MAX_VALUE,p,c,d,y=this.getNodes(),L=y.length,O=0;O<L;O++){var I=y[O];p=I.getTop(),c=I.getLeft(),l>p&&(l=p),f>c&&(f=c)}return l==n.MAX_VALUE?null:(y[0].getParent().paddingLeft!=null?d=y[0].getParent().paddingLeft:d=this.margin,this.left=f-d,this.top=l-d,new g(this.left,this.top))},o.prototype.updateBounds=function(l){for(var f=n.MAX_VALUE,p=-n.MAX_VALUE,c=n.MAX_VALUE,d=-n.MAX_VALUE,y,L,O,I,A,T=this.nodes,N=T.length,R=0;R<N;R++){var x=T[R];l&&x.child!=null&&x.updateBounds(),y=x.getLeft(),L=x.getRight(),O=x.getTop(),I=x.getBottom(),f>y&&(f=y),p<L&&(p=L),c>O&&(c=O),d<I&&(d=I)}var m=new r(f,c,p-f,d-c);f==n.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),T[0].getParent().paddingLeft!=null?A=T[0].getParent().paddingLeft:A=this.margin,this.left=m.x-A,this.right=m.x+m.width+A,this.top=m.y-A,this.bottom=m.y+m.height+A},o.calculateBounds=function(l){for(var f=n.MAX_VALUE,p=-n.MAX_VALUE,c=n.MAX_VALUE,d=-n.MAX_VALUE,y,L,O,I,A=l.length,T=0;T<A;T++){var N=l[T];y=N.getLeft(),L=N.getRight(),O=N.getTop(),I=N.getBottom(),f>y&&(f=y),p<L&&(p=L),c>O&&(c=O),d<I&&(d=I)}var R=new r(f,c,p-f,d-c);return R},o.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},o.prototype.getEstimatedSize=function(){if(this.estimatedSize==n.MIN_VALUE)throw"assert failed";return this.estimatedSize},o.prototype.calcEstimatedSize=function(){for(var l=0,f=this.nodes,p=f.length,c=0;c<p;c++){var d=f[c];l+=d.calcEstimatedSize()}return l==0?this.estimatedSize=e.EMPTY_COMPOUND_NODE_SIZE:this.estimatedSize=l/Math.sqrt(this.nodes.length),this.estimatedSize},o.prototype.updateConnected=function(){var l=this;if(this.nodes.length==0){this.isConnected=!0;return}var f=new t,p=new Set,c=this.nodes[0],d,y,L=c.withChildren();for(L.forEach(function(R){f.push(R),p.add(R)});f.length!==0;){c=f.shift(),d=c.getEdges();for(var O=d.length,I=0;I<O;I++){var A=d[I];if(y=A.getOtherEndInGraph(c,this),y!=null&&!p.has(y)){var T=y.withChildren();T.forEach(function(R){f.push(R),p.add(R)})}}}if(this.isConnected=!1,p.size>=this.nodes.length){var N=0;p.forEach(function(R){R.owner==l&&N++}),N==this.nodes.length&&(this.isConnected=!0)}},E.exports=o}),(function(E,D,v){var h,n=v(1);function e(i){h=v(5),this.layout=i,this.graphs=[],this.edges=[]}e.prototype.addRoot=function(){var i=this.layout.newGraph(),a=this.layout.newNode(null),u=this.add(i,a);return this.setRootGraph(u),this.rootGraph},e.prototype.add=function(i,a,u,r,g){if(u==null&&r==null&&g==null){if(i==null)throw"Graph is null!";if(a==null)throw"Parent node is null!";if(this.graphs.indexOf(i)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(i),i.parent!=null)throw"Already has a parent!";if(a.child!=null)throw"Already has a child!";return i.parent=a,a.child=i,i}else{g=u,r=a,u=i;var t=r.getOwner(),o=g.getOwner();if(!(t!=null&&t.getGraphManager()==this))throw"Source not in this graph mgr!";if(!(o!=null&&o.getGraphManager()==this))throw"Target not in this graph mgr!";if(t==o)return u.isInterGraph=!1,t.add(u,r,g);if(u.isInterGraph=!0,u.source=r,u.target=g,this.edges.indexOf(u)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(u),!(u.source!=null&&u.target!=null))throw"Edge source and/or target is null!";if(!(u.source.edges.indexOf(u)==-1&&u.target.edges.indexOf(u)==-1))throw"Edge already in source and/or target incidency list!";return u.source.edges.push(u),u.target.edges.push(u),u}},e.prototype.remove=function(i){if(i instanceof h){var a=i;if(a.getGraphManager()!=this)throw"Graph not in this graph mgr";if(!(a==this.rootGraph||a.parent!=null&&a.parent.graphManager==this))throw"Invalid parent node!";var u=[];u=u.concat(a.getEdges());for(var r,g=u.length,t=0;t<g;t++)r=u[t],a.remove(r);var o=[];o=o.concat(a.getNodes());var s;g=o.length;for(var t=0;t<g;t++)s=o[t],a.remove(s);a==this.rootGraph&&this.setRootGraph(null);var l=this.graphs.indexOf(a);this.graphs.splice(l,1),a.parent=null}else if(i instanceof n){if(r=i,r==null)throw"Edge is null!";if(!r.isInterGraph)throw"Not an inter-graph edge!";if(!(r.source!=null&&r.target!=null))throw"Source and/or target is null!";if(!(r.source.edges.indexOf(r)!=-1&&r.target.edges.indexOf(r)!=-1))throw"Source and/or target doesn't know this edge!";var l=r.source.edges.indexOf(r);if(r.source.edges.splice(l,1),l=r.target.edges.indexOf(r),r.target.edges.splice(l,1),!(r.source.owner!=null&&r.source.owner.getGraphManager()!=null))throw"Edge owner graph or owner graph manager is null!";if(r.source.owner.getGraphManager().edges.indexOf(r)==-1)throw"Not in owner graph manager's edge list!";var l=r.source.owner.getGraphManager().edges.indexOf(r);r.source.owner.getGraphManager().edges.splice(l,1)}},e.prototype.updateBounds=function(){this.rootGraph.updateBounds(!0)},e.prototype.getGraphs=function(){return this.graphs},e.prototype.getAllNodes=function(){if(this.allNodes==null){for(var i=[],a=this.getGraphs(),u=a.length,r=0;r<u;r++)i=i.concat(a[r].getNodes());this.allNodes=i}return this.allNodes},e.prototype.resetAllNodes=function(){this.allNodes=null},e.prototype.resetAllEdges=function(){this.allEdges=null},e.prototype.resetAllNodesToApplyGravitation=function(){this.allNodesToApplyGravitation=null},e.prototype.getAllEdges=function(){if(this.allEdges==null){var i=[],a=this.getGraphs();a.length;for(var u=0;u<a.length;u++)i=i.concat(a[u].getEdges());i=i.concat(this.edges),this.allEdges=i}return this.allEdges},e.prototype.getAllNodesToApplyGravitation=function(){return this.allNodesToApplyGravitation},e.prototype.setAllNodesToApplyGravitation=function(i){if(this.allNodesToApplyGravitation!=null)throw"assert failed";this.allNodesToApplyGravitation=i},e.prototype.getRoot=function(){return this.rootGraph},e.prototype.setRootGraph=function(i){if(i.getGraphManager()!=this)throw"Root not in this graph mgr!";this.rootGraph=i,i.parent==null&&(i.parent=this.layout.newNode("Root node"))},e.prototype.getLayout=function(){return this.layout},e.prototype.isOneAncestorOfOther=function(i,a){if(!(i!=null&&a!=null))throw"assert failed";if(i==a)return!0;var u=i.getOwner(),r;do{if(r=u.getParent(),r==null)break;if(r==a)return!0;if(u=r.getOwner(),u==null)break}while(!0);u=a.getOwner();do{if(r=u.getParent(),r==null)break;if(r==i)return!0;if(u=r.getOwner(),u==null)break}while(!0);return!1},e.prototype.calcLowestCommonAncestors=function(){for(var i,a,u,r,g,t=this.getAllEdges(),o=t.length,s=0;s<o;s++){if(i=t[s],a=i.source,u=i.target,i.lca=null,i.sourceInLca=a,i.targetInLca=u,a==u){i.lca=a.getOwner();continue}for(r=a.getOwner();i.lca==null;){for(i.targetInLca=u,g=u.getOwner();i.lca==null;){if(g==r){i.lca=g;break}if(g==this.rootGraph)break;if(i.lca!=null)throw"assert failed";i.targetInLca=g.getParent(),g=i.targetInLca.getOwner()}if(r==this.rootGraph)break;i.lca==null&&(i.sourceInLca=r.getParent(),r=i.sourceInLca.getOwner())}if(i.lca==null)throw"assert failed"}},e.prototype.calcLowestCommonAncestor=function(i,a){if(i==a)return i.getOwner();var u=i.getOwner();do{if(u==null)break;var r=a.getOwner();do{if(r==null)break;if(r==u)return r;r=r.getParent().getOwner()}while(!0);u=u.getParent().getOwner()}while(!0);return u},e.prototype.calcInclusionTreeDepths=function(i,a){i==null&&a==null&&(i=this.rootGraph,a=1);for(var u,r=i.getNodes(),g=r.length,t=0;t<g;t++)u=r[t],u.inclusionTreeDepth=a,u.child!=null&&this.calcInclusionTreeDepths(u.child,a+1)},e.prototype.includesInvalidEdge=function(){for(var i,a=this.edges.length,u=0;u<a;u++)if(i=this.edges[u],this.isOneAncestorOfOther(i.source,i.target))return!0;return!1},E.exports=e}),(function(E,D,v){var h=v(0);function n(){}for(var e in h)n[e]=h[e];n.MAX_ITERATIONS=2500,n.DEFAULT_EDGE_LENGTH=50,n.DEFAULT_SPRING_STRENGTH=.45,n.DEFAULT_REPULSION_STRENGTH=4500,n.DEFAULT_GRAVITY_STRENGTH=.4,n.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,n.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,n.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,n.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,n.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,n.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,n.COOLING_ADAPTATION_FACTOR=.33,n.ADAPTATION_LOWER_NODE_LIMIT=1e3,n.ADAPTATION_UPPER_NODE_LIMIT=5e3,n.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,n.MAX_NODE_DISPLACEMENT=n.MAX_NODE_DISPLACEMENT_INCREMENTAL*3,n.MIN_REPULSION_DIST=n.DEFAULT_EDGE_LENGTH/10,n.CONVERGENCE_CHECK_PERIOD=100,n.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,n.MIN_EDGE_LENGTH=1,n.GRID_CALCULATION_CHECK_PERIOD=10,E.exports=n}),(function(E,D,v){var h=v(12);function n(){}n.calcSeparationAmount=function(e,i,a,u){if(!e.intersects(i))throw"assert failed";var r=new Array(2);this.decideDirectionsForOverlappingNodes(e,i,r),a[0]=Math.min(e.getRight(),i.getRight())-Math.max(e.x,i.x),a[1]=Math.min(e.getBottom(),i.getBottom())-Math.max(e.y,i.y),e.getX()<=i.getX()&&e.getRight()>=i.getRight()?a[0]+=Math.min(i.getX()-e.getX(),e.getRight()-i.getRight()):i.getX()<=e.getX()&&i.getRight()>=e.getRight()&&(a[0]+=Math.min(e.getX()-i.getX(),i.getRight()-e.getRight())),e.getY()<=i.getY()&&e.getBottom()>=i.getBottom()?a[1]+=Math.min(i.getY()-e.getY(),e.getBottom()-i.getBottom()):i.getY()<=e.getY()&&i.getBottom()>=e.getBottom()&&(a[1]+=Math.min(e.getY()-i.getY(),i.getBottom()-e.getBottom()));var g=Math.abs((i.getCenterY()-e.getCenterY())/(i.getCenterX()-e.getCenterX()));i.getCenterY()===e.getCenterY()&&i.getCenterX()===e.getCenterX()&&(g=1);var t=g*a[0],o=a[1]/g;a[0]<o?o=a[0]:t=a[1],a[0]=-1*r[0]*(o/2+u),a[1]=-1*r[1]*(t/2+u)},n.decideDirectionsForOverlappingNodes=function(e,i,a){e.getCenterX()<i.getCenterX()?a[0]=-1:a[0]=1,e.getCenterY()<i.getCenterY()?a[1]=-1:a[1]=1},n.getIntersection2=function(e,i,a){var u=e.getCenterX(),r=e.getCenterY(),g=i.getCenterX(),t=i.getCenterY();if(e.intersects(i))return a[0]=u,a[1]=r,a[2]=g,a[3]=t,!0;var o=e.getX(),s=e.getY(),l=e.getRight(),f=e.getX(),p=e.getBottom(),c=e.getRight(),d=e.getWidthHalf(),y=e.getHeightHalf(),L=i.getX(),O=i.getY(),I=i.getRight(),A=i.getX(),T=i.getBottom(),N=i.getRight(),R=i.getWidthHalf(),x=i.getHeightHalf(),m=!1,w=!1;if(u===g){if(r>t)return a[0]=u,a[1]=s,a[2]=g,a[3]=T,!1;if(r<t)return a[0]=u,a[1]=p,a[2]=g,a[3]=O,!1}else if(r===t){if(u>g)return a[0]=o,a[1]=r,a[2]=I,a[3]=t,!1;if(u<g)return a[0]=l,a[1]=r,a[2]=L,a[3]=t,!1}else{var C=e.height/e.width,Y=i.height/i.width,M=(t-r)/(g-u),X=void 0,U=void 0,S=void 0,_=void 0,F=void 0,G=void 0;if(-C===M?u>g?(a[0]=f,a[1]=p,m=!0):(a[0]=l,a[1]=s,m=!0):C===M&&(u>g?(a[0]=o,a[1]=s,m=!0):(a[0]=c,a[1]=p,m=!0)),-Y===M?g>u?(a[2]=A,a[3]=T,w=!0):(a[2]=I,a[3]=O,w=!0):Y===M&&(g>u?(a[2]=L,a[3]=O,w=!0):(a[2]=N,a[3]=T,w=!0)),m&&w)return!1;if(u>g?r>t?(X=this.getCardinalDirection(C,M,4),U=this.getCardinalDirection(Y,M,2)):(X=this.getCardinalDirection(-C,M,3),U=this.getCardinalDirection(-Y,M,1)):r>t?(X=this.getCardinalDirection(-C,M,1),U=this.getCardinalDirection(-Y,M,3)):(X=this.getCardinalDirection(C,M,2),U=this.getCardinalDirection(Y,M,4)),!m)switch(X){case 1:_=s,S=u+-y/M,a[0]=S,a[1]=_;break;case 2:S=c,_=r+d*M,a[0]=S,a[1]=_;break;case 3:_=p,S=u+y/M,a[0]=S,a[1]=_;break;case 4:S=f,_=r+-d*M,a[0]=S,a[1]=_;break}if(!w)switch(U){case 1:G=O,F=g+-x/M,a[2]=F,a[3]=G;break;case 2:F=N,G=t+R*M,a[2]=F,a[3]=G;break;case 3:G=T,F=g+x/M,a[2]=F,a[3]=G;break;case 4:F=A,G=t+-R*M,a[2]=F,a[3]=G;break}}return!1},n.getCardinalDirection=function(e,i,a){return e>i?a:1+a%4},n.getIntersection=function(e,i,a,u){if(u==null)return this.getIntersection2(e,i,a);var r=e.x,g=e.y,t=i.x,o=i.y,s=a.x,l=a.y,f=u.x,p=u.y,c=void 0,d=void 0,y=void 0,L=void 0,O=void 0,I=void 0,A=void 0,T=void 0,N=void 0;return y=o-g,O=r-t,A=t*g-r*o,L=p-l,I=s-f,T=f*l-s*p,N=y*I-L*O,N===0?null:(c=(O*T-I*A)/N,d=(L*A-y*T)/N,new h(c,d))},n.angleOfVector=function(e,i,a,u){var r=void 0;return e!==a?(r=Math.atan((u-i)/(a-e)),a<e?r+=Math.PI:u<i&&(r+=this.TWO_PI)):u<i?r=this.ONE_AND_HALF_PI:r=this.HALF_PI,r},n.doIntersect=function(e,i,a,u){var r=e.x,g=e.y,t=i.x,o=i.y,s=a.x,l=a.y,f=u.x,p=u.y,c=(t-r)*(p-l)-(f-s)*(o-g);if(c===0)return!1;var d=((p-l)*(f-r)+(s-f)*(p-g))/c,y=((g-o)*(f-r)+(t-r)*(p-g))/c;return 0<d&&d<1&&0<y&&y<1},n.HALF_PI=.5*Math.PI,n.ONE_AND_HALF_PI=1.5*Math.PI,n.TWO_PI=2*Math.PI,n.THREE_PI=3*Math.PI,E.exports=n}),(function(E,D,v){function h(){}h.sign=function(n){return n>0?1:n<0?-1:0},h.floor=function(n){return n<0?Math.ceil(n):Math.floor(n)},h.ceil=function(n){return n<0?Math.floor(n):Math.ceil(n)},E.exports=h}),(function(E,D,v){function h(){}h.MAX_VALUE=2147483647,h.MIN_VALUE=-2147483648,E.exports=h}),(function(E,D,v){var h=(function(){function r(g,t){for(var o=0;o<t.length;o++){var s=t[o];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(g,s.key,s)}}return function(g,t,o){return t&&r(g.prototype,t),o&&r(g,o),g}})();function n(r,g){if(!(r instanceof g))throw new TypeError("Cannot call a class as a function")}var e=function(g){return{value:g,next:null,prev:null}},i=function(g,t,o,s){return g!==null?g.next=t:s.head=t,o!==null?o.prev=t:s.tail=t,t.prev=g,t.next=o,s.length++,t},a=function(g,t){var o=g.prev,s=g.next;return o!==null?o.next=s:t.head=s,s!==null?s.prev=o:t.tail=o,g.prev=g.next=null,t.length--,g},u=(function(){function r(g){var t=this;n(this,r),this.length=0,this.head=null,this.tail=null,g?.forEach(function(o){return t.push(o)})}return h(r,[{key:"size",value:function(){return this.length}},{key:"insertBefore",value:function(t,o){return i(o.prev,e(t),o,this)}},{key:"insertAfter",value:function(t,o){return i(o,e(t),o.next,this)}},{key:"insertNodeBefore",value:function(t,o){return i(o.prev,t,o,this)}},{key:"insertNodeAfter",value:function(t,o){return i(o,t,o.next,this)}},{key:"push",value:function(t){return i(this.tail,e(t),null,this)}},{key:"unshift",value:function(t){return i(null,e(t),this.head,this)}},{key:"remove",value:function(t){return a(t,this)}},{key:"pop",value:function(){return a(this.tail,this).value}},{key:"popNode",value:function(){return a(this.tail,this)}},{key:"shift",value:function(){return a(this.head,this).value}},{key:"shiftNode",value:function(){return a(this.head,this)}},{key:"get_object_at",value:function(t){if(t<=this.length()){for(var o=1,s=this.head;o<t;)s=s.next,o++;return s.value}}},{key:"set_object_at",value:function(t,o){if(t<=this.length()){for(var s=1,l=this.head;s<t;)l=l.next,s++;l.value=o}}}]),r})();E.exports=u}),(function(E,D,v){function h(n,e,i){this.x=null,this.y=null,n==null&&e==null&&i==null?(this.x=0,this.y=0):typeof n=="number"&&typeof e=="number"&&i==null?(this.x=n,this.y=e):n.constructor.name=="Point"&&e==null&&i==null&&(i=n,this.x=i.x,this.y=i.y)}h.prototype.getX=function(){return this.x},h.prototype.getY=function(){return this.y},h.prototype.getLocation=function(){return new h(this.x,this.y)},h.prototype.setLocation=function(n,e,i){n.constructor.name=="Point"&&e==null&&i==null?(i=n,this.setLocation(i.x,i.y)):typeof n=="number"&&typeof e=="number"&&i==null&&(parseInt(n)==n&&parseInt(e)==e?this.move(n,e):(this.x=Math.floor(n+.5),this.y=Math.floor(e+.5)))},h.prototype.move=function(n,e){this.x=n,this.y=e},h.prototype.translate=function(n,e){this.x+=n,this.y+=e},h.prototype.equals=function(n){if(n.constructor.name=="Point"){var e=n;return this.x==e.x&&this.y==e.y}return this==n},h.prototype.toString=function(){return new h().constructor.name+"[x="+this.x+",y="+this.y+"]"},E.exports=h}),(function(E,D,v){function h(n,e,i,a){this.x=0,this.y=0,this.width=0,this.height=0,n!=null&&e!=null&&i!=null&&a!=null&&(this.x=n,this.y=e,this.width=i,this.height=a)}h.prototype.getX=function(){return this.x},h.prototype.setX=function(n){this.x=n},h.prototype.getY=function(){return this.y},h.prototype.setY=function(n){this.y=n},h.prototype.getWidth=function(){return this.width},h.prototype.setWidth=function(n){this.width=n},h.prototype.getHeight=function(){return this.height},h.prototype.setHeight=function(n){this.height=n},h.prototype.getRight=function(){return this.x+this.width},h.prototype.getBottom=function(){return this.y+this.height},h.prototype.intersects=function(n){return!(this.getRight()<n.x||this.getBottom()<n.y||n.getRight()<this.x||n.getBottom()<this.y)},h.prototype.getCenterX=function(){return this.x+this.width/2},h.prototype.getMinX=function(){return this.getX()},h.prototype.getMaxX=function(){return this.getX()+this.width},h.prototype.getCenterY=function(){return this.y+this.height/2},h.prototype.getMinY=function(){return this.getY()},h.prototype.getMaxY=function(){return this.getY()+this.height},h.prototype.getWidthHalf=function(){return this.width/2},h.prototype.getHeightHalf=function(){return this.height/2},E.exports=h}),(function(E,D,v){var h=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function n(){}n.lastID=0,n.createID=function(e){return n.isPrimitive(e)?e:(e.uniqueID!=null||(e.uniqueID=n.getString(),n.lastID++),e.uniqueID)},n.getString=function(e){return e==null&&(e=n.lastID),"Object#"+e},n.isPrimitive=function(e){var i=typeof e>"u"?"undefined":h(e);return e==null||i!="object"&&i!="function"},E.exports=n}),(function(E,D,v){function h(s){if(Array.isArray(s)){for(var l=0,f=Array(s.length);l<s.length;l++)f[l]=s[l];return f}else return Array.from(s)}var n=v(0),e=v(6),i=v(3),a=v(1),u=v(5),r=v(4),g=v(17),t=v(27);function o(s){t.call(this),this.layoutQuality=n.QUALITY,this.createBendsAsNeeded=n.DEFAULT_CREATE_BENDS_AS_NEEDED,this.incremental=n.DEFAULT_INCREMENTAL,this.animationOnLayout=n.DEFAULT_ANIMATION_ON_LAYOUT,this.animationDuringLayout=n.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=n.DEFAULT_ANIMATION_PERIOD,this.uniformLeafNodeSizes=n.DEFAULT_UNIFORM_LEAF_NODE_SIZES,this.edgeToDummyNodes=new Map,this.graphManager=new e(this),this.isLayoutFinished=!1,this.isSubLayout=!1,this.isRemoteUse=!1,s!=null&&(this.isRemoteUse=s)}o.RANDOM_SEED=1,o.prototype=Object.create(t.prototype),o.prototype.getGraphManager=function(){return this.graphManager},o.prototype.getAllNodes=function(){return this.graphManager.getAllNodes()},o.prototype.getAllEdges=function(){return this.graphManager.getAllEdges()},o.prototype.getAllNodesToApplyGravitation=function(){return this.graphManager.getAllNodesToApplyGravitation()},o.prototype.newGraphManager=function(){var s=new e(this);return this.graphManager=s,s},o.prototype.newGraph=function(s){return new u(null,this.graphManager,s)},o.prototype.newNode=function(s){return new i(this.graphManager,s)},o.prototype.newEdge=function(s){return new a(null,null,s)},o.prototype.checkLayoutSuccess=function(){return this.graphManager.getRoot()==null||this.graphManager.getRoot().getNodes().length==0||this.graphManager.includesInvalidEdge()},o.prototype.runLayout=function(){this.isLayoutFinished=!1,this.tilingPreLayout&&this.tilingPreLayout(),this.initParameters();var s;return this.checkLayoutSuccess()?s=!1:s=this.layout(),n.ANIMATE==="during"?!1:(s&&(this.isSubLayout||this.doPostLayout()),this.tilingPostLayout&&this.tilingPostLayout(),this.isLayoutFinished=!0,s)},o.prototype.doPostLayout=function(){this.incremental||this.transform(),this.update()},o.prototype.update2=function(){if(this.createBendsAsNeeded&&(this.createBendpointsFromDummyNodes(),this.graphManager.resetAllEdges()),!this.isRemoteUse){for(var s=this.graphManager.getAllEdges(),l=0;l<s.length;l++)s[l];for(var f=this.graphManager.getRoot().getNodes(),l=0;l<f.length;l++)f[l];this.update(this.graphManager.getRoot())}},o.prototype.update=function(s){if(s==null)this.update2();else if(s instanceof i){var l=s;if(l.getChild()!=null)for(var f=l.getChild().getNodes(),p=0;p<f.length;p++)update(f[p]);if(l.vGraphObject!=null){var c=l.vGraphObject;c.update(l)}}else if(s instanceof a){var d=s;if(d.vGraphObject!=null){var y=d.vGraphObject;y.update(d)}}else if(s instanceof u){var L=s;if(L.vGraphObject!=null){var O=L.vGraphObject;O.update(L)}}},o.prototype.initParameters=function(){this.isSubLayout||(this.layoutQuality=n.QUALITY,this.animationDuringLayout=n.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=n.DEFAULT_ANIMATION_PERIOD,this.animationOnLayout=n.DEFAULT_ANIMATION_ON_LAYOUT,this.incremental=n.DEFAULT_INCREMENTAL,this.createBendsAsNeeded=n.DEFAULT_CREATE_BENDS_AS_NEEDED,this.uniformLeafNodeSizes=n.DEFAULT_UNIFORM_LEAF_NODE_SIZES),this.animationDuringLayout&&(this.animationOnLayout=!1)},o.prototype.transform=function(s){if(s==null)this.transform(new r(0,0));else{var l=new g,f=this.graphManager.getRoot().updateLeftTop();if(f!=null){l.setWorldOrgX(s.x),l.setWorldOrgY(s.y),l.setDeviceOrgX(f.x),l.setDeviceOrgY(f.y);for(var p=this.getAllNodes(),c,d=0;d<p.length;d++)c=p[d],c.transform(l)}}},o.prototype.positionNodesRandomly=function(s){if(s==null)this.positionNodesRandomly(this.getGraphManager().getRoot()),this.getGraphManager().getRoot().updateBounds(!0);else for(var l,f,p=s.getNodes(),c=0;c<p.length;c++)l=p[c],f=l.getChild(),f==null||f.getNodes().length==0?l.scatter():(this.positionNodesRandomly(f),l.updateBounds())},o.prototype.getFlatForest=function(){for(var s=[],l=!0,f=this.graphManager.getRoot().getNodes(),p=!0,c=0;c<f.length;c++)f[c].getChild()!=null&&(p=!1);if(!p)return s;var d=new Set,y=[],L=new Map,O=[];for(O=O.concat(f);O.length>0&&l;){for(y.push(O[0]);y.length>0&&l;){var I=y[0];y.splice(0,1),d.add(I);for(var A=I.getEdges(),c=0;c<A.length;c++){var T=A[c].getOtherEnd(I);if(L.get(I)!=T)if(!d.has(T))y.push(T),L.set(T,I);else{l=!1;break}}}if(!l)s=[];else{var N=[].concat(h(d));s.push(N);for(var c=0;c<N.length;c++){var R=N[c],x=O.indexOf(R);x>-1&&O.splice(x,1)}d=new Set,L=new Map}}return s},o.prototype.createDummyNodesForBendpoints=function(s){for(var l=[],f=s.source,p=this.graphManager.calcLowestCommonAncestor(s.source,s.target),c=0;c<s.bendpoints.length;c++){var d=this.newNode(null);d.setRect(new Point(0,0),new Dimension(1,1)),p.add(d);var y=this.newEdge(null);this.graphManager.add(y,f,d),l.add(d),f=d}var y=this.newEdge(null);return this.graphManager.add(y,f,s.target),this.edgeToDummyNodes.set(s,l),s.isInterGraph()?this.graphManager.remove(s):p.remove(s),l},o.prototype.createBendpointsFromDummyNodes=function(){var s=[];s=s.concat(this.graphManager.getAllEdges()),s=[].concat(h(this.edgeToDummyNodes.keys())).concat(s);for(var l=0;l<s.length;l++){var f=s[l];if(f.bendpoints.length>0){for(var p=this.edgeToDummyNodes.get(f),c=0;c<p.length;c++){var d=p[c],y=new r(d.getCenterX(),d.getCenterY()),L=f.bendpoints.get(c);L.x=y.x,L.y=y.y,d.getOwner().remove(d)}this.graphManager.add(f,f.source,f.target)}}},o.transform=function(s,l,f,p){if(f!=null&&p!=null){var c=l;if(s<=50){var d=l/f;c-=(l-d)/50*(50-s)}else{var y=l*p;c+=(y-l)/50*(s-50)}return c}else{var L,O;return s<=50?(L=9*l/500,O=l/10):(L=9*l/50,O=-8*l),L*s+O}},o.findCenterOfTree=function(s){var l=[];l=l.concat(s);var f=[],p=new Map,c=!1,d=null;(l.length==1||l.length==2)&&(c=!0,d=l[0]);for(var y=0;y<l.length;y++){var L=l[y],O=L.getNeighborsList().size;p.set(L,L.getNeighborsList().size),O==1&&f.push(L)}var I=[];for(I=I.concat(f);!c;){var A=[];A=A.concat(I),I=[];for(var y=0;y<l.length;y++){var L=l[y],T=l.indexOf(L);T>=0&&l.splice(T,1);var N=L.getNeighborsList();N.forEach(function(m){if(f.indexOf(m)<0){var w=p.get(m),C=w-1;C==1&&I.push(m),p.set(m,C)}})}f=f.concat(I),(l.length==1||l.length==2)&&(c=!0,d=l[0])}return d},o.prototype.setGraphManager=function(s){this.graphManager=s},E.exports=o}),(function(E,D,v){function h(){}h.seed=1,h.x=0,h.nextDouble=function(){return h.x=Math.sin(h.seed++)*1e4,h.x-Math.floor(h.x)},E.exports=h}),(function(E,D,v){var h=v(4);function n(e,i){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}n.prototype.getWorldOrgX=function(){return this.lworldOrgX},n.prototype.setWorldOrgX=function(e){this.lworldOrgX=e},n.prototype.getWorldOrgY=function(){return this.lworldOrgY},n.prototype.setWorldOrgY=function(e){this.lworldOrgY=e},n.prototype.getWorldExtX=function(){return this.lworldExtX},n.prototype.setWorldExtX=function(e){this.lworldExtX=e},n.prototype.getWorldExtY=function(){return this.lworldExtY},n.prototype.setWorldExtY=function(e){this.lworldExtY=e},n.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},n.prototype.setDeviceOrgX=function(e){this.ldeviceOrgX=e},n.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},n.prototype.setDeviceOrgY=function(e){this.ldeviceOrgY=e},n.prototype.getDeviceExtX=function(){return this.ldeviceExtX},n.prototype.setDeviceExtX=function(e){this.ldeviceExtX=e},n.prototype.getDeviceExtY=function(){return this.ldeviceExtY},n.prototype.setDeviceExtY=function(e){this.ldeviceExtY=e},n.prototype.transformX=function(e){var i=0,a=this.lworldExtX;return a!=0&&(i=this.ldeviceOrgX+(e-this.lworldOrgX)*this.ldeviceExtX/a),i},n.prototype.transformY=function(e){var i=0,a=this.lworldExtY;return a!=0&&(i=this.ldeviceOrgY+(e-this.lworldOrgY)*this.ldeviceExtY/a),i},n.prototype.inverseTransformX=function(e){var i=0,a=this.ldeviceExtX;return a!=0&&(i=this.lworldOrgX+(e-this.ldeviceOrgX)*this.lworldExtX/a),i},n.prototype.inverseTransformY=function(e){var i=0,a=this.ldeviceExtY;return a!=0&&(i=this.lworldOrgY+(e-this.ldeviceOrgY)*this.lworldExtY/a),i},n.prototype.inverseTransformPoint=function(e){var i=new h(this.inverseTransformX(e.x),this.inverseTransformY(e.y));return i},E.exports=n}),(function(E,D,v){function h(t){if(Array.isArray(t)){for(var o=0,s=Array(t.length);o<t.length;o++)s[o]=t[o];return s}else return Array.from(t)}var n=v(15),e=v(7),i=v(0),a=v(8),u=v(9);function r(){n.call(this),this.useSmartIdealEdgeLengthCalculation=e.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=e.DEFAULT_EDGE_LENGTH,this.springConstant=e.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=e.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=e.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=e.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=e.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=e.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*e.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=e.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=e.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=e.MAX_ITERATIONS}r.prototype=Object.create(n.prototype);for(var g in n)r[g]=n[g];r.prototype.initParameters=function(){n.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=e.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},r.prototype.calcIdealEdgeLengths=function(){for(var t,o,s,l,f,p,c=this.getGraphManager().getAllEdges(),d=0;d<c.length;d++)t=c[d],t.idealLength=this.idealEdgeLength,t.isInterGraph&&(s=t.getSource(),l=t.getTarget(),f=t.getSourceInLca().getEstimatedSize(),p=t.getTargetInLca().getEstimatedSize(),this.useSmartIdealEdgeLengthCalculation&&(t.idealLength+=f+p-2*i.SIMPLE_NODE_SIZE),o=t.getLca().getInclusionTreeDepth(),t.idealLength+=e.DEFAULT_EDGE_LENGTH*e.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR*(s.getInclusionTreeDepth()+l.getInclusionTreeDepth()-2*o))},r.prototype.initSpringEmbedder=function(){var t=this.getAllNodes().length;this.incremental?(t>e.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*e.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(t-e.ADAPTATION_LOWER_NODE_LIMIT)/(e.ADAPTATION_UPPER_NODE_LIMIT-e.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-e.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=e.MAX_NODE_DISPLACEMENT_INCREMENTAL):(t>e.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(e.COOLING_ADAPTATION_FACTOR,1-(t-e.ADAPTATION_LOWER_NODE_LIMIT)/(e.ADAPTATION_UPPER_NODE_LIMIT-e.ADAPTATION_LOWER_NODE_LIMIT)*(1-e.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=e.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},r.prototype.calcSpringForces=function(){for(var t=this.getAllEdges(),o,s=0;s<t.length;s++)o=t[s],this.calcSpringForce(o,o.idealLength)},r.prototype.calcRepulsionForces=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,s,l,f,p,c=this.getAllNodes(),d;if(this.useFRGridVariant)for(this.totalIterations%e.GRID_CALCULATION_CHECK_PERIOD==1&&t&&this.updateGrid(),d=new Set,s=0;s<c.length;s++)f=c[s],this.calculateRepulsionForceOfANode(f,d,t,o),d.add(f);else for(s=0;s<c.length;s++)for(f=c[s],l=s+1;l<c.length;l++)p=c[l],f.getOwner()==p.getOwner()&&this.calcRepulsionForce(f,p)},r.prototype.calcGravitationalForces=function(){for(var t,o=this.getAllNodesToApplyGravitation(),s=0;s<o.length;s++)t=o[s],this.calcGravitationalForce(t)},r.prototype.moveNodes=function(){for(var t=this.getAllNodes(),o,s=0;s<t.length;s++)o=t[s],o.move()},r.prototype.calcSpringForce=function(t,o){var s=t.getSource(),l=t.getTarget(),f,p,c,d;if(this.uniformLeafNodeSizes&&s.getChild()==null&&l.getChild()==null)t.updateLengthSimple();else if(t.updateLength(),t.isOverlapingSourceAndTarget)return;f=t.getLength(),f!=0&&(p=this.springConstant*(f-o),c=p*(t.lengthX/f),d=p*(t.lengthY/f),s.springForceX+=c,s.springForceY+=d,l.springForceX-=c,l.springForceY-=d)},r.prototype.calcRepulsionForce=function(t,o){var s=t.getRect(),l=o.getRect(),f=new Array(2),p=new Array(4),c,d,y,L,O,I,A;if(s.intersects(l)){a.calcSeparationAmount(s,l,f,e.DEFAULT_EDGE_LENGTH/2),I=2*f[0],A=2*f[1];var T=t.noOfChildren*o.noOfChildren/(t.noOfChildren+o.noOfChildren);t.repulsionForceX-=T*I,t.repulsionForceY-=T*A,o.repulsionForceX+=T*I,o.repulsionForceY+=T*A}else this.uniformLeafNodeSizes&&t.getChild()==null&&o.getChild()==null?(c=l.getCenterX()-s.getCenterX(),d=l.getCenterY()-s.getCenterY()):(a.getIntersection(s,l,p),c=p[2]-p[0],d=p[3]-p[1]),Math.abs(c)<e.MIN_REPULSION_DIST&&(c=u.sign(c)*e.MIN_REPULSION_DIST),Math.abs(d)<e.MIN_REPULSION_DIST&&(d=u.sign(d)*e.MIN_REPULSION_DIST),y=c*c+d*d,L=Math.sqrt(y),O=this.repulsionConstant*t.noOfChildren*o.noOfChildren/y,I=O*c/L,A=O*d/L,t.repulsionForceX-=I,t.repulsionForceY-=A,o.repulsionForceX+=I,o.repulsionForceY+=A},r.prototype.calcGravitationalForce=function(t){var o,s,l,f,p,c,d,y;o=t.getOwner(),s=(o.getRight()+o.getLeft())/2,l=(o.getTop()+o.getBottom())/2,f=t.getCenterX()-s,p=t.getCenterY()-l,c=Math.abs(f)+t.getWidth()/2,d=Math.abs(p)+t.getHeight()/2,t.getOwner()==this.graphManager.getRoot()?(y=o.getEstimatedSize()*this.gravityRangeFactor,(c>y||d>y)&&(t.gravitationForceX=-this.gravityConstant*f,t.gravitationForceY=-this.gravityConstant*p)):(y=o.getEstimatedSize()*this.compoundGravityRangeFactor,(c>y||d>y)&&(t.gravitationForceX=-this.gravityConstant*f*this.compoundGravityConstant,t.gravitationForceY=-this.gravityConstant*p*this.compoundGravityConstant))},r.prototype.isConverged=function(){var t,o=!1;return this.totalIterations>this.maxIterations/3&&(o=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),t=this.totalDisplacement<this.totalDisplacementThreshold,this.oldTotalDisplacement=this.totalDisplacement,t||o},r.prototype.animate=function(){this.animationDuringLayout&&!this.isSubLayout&&(this.notAnimatedIterations==this.animationPeriod?(this.update(),this.notAnimatedIterations=0):this.notAnimatedIterations++)},r.prototype.calcNoOfChildrenForAllNodes=function(){for(var t,o=this.graphManager.getAllNodes(),s=0;s<o.length;s++)t=o[s],t.noOfChildren=t.getNoOfChildren()},r.prototype.calcGrid=function(t){var o=0,s=0;o=parseInt(Math.ceil((t.getRight()-t.getLeft())/this.repulsionRange)),s=parseInt(Math.ceil((t.getBottom()-t.getTop())/this.repulsionRange));for(var l=new Array(o),f=0;f<o;f++)l[f]=new Array(s);for(var f=0;f<o;f++)for(var p=0;p<s;p++)l[f][p]=new Array;return l},r.prototype.addNodeToGrid=function(t,o,s){var l=0,f=0,p=0,c=0;l=parseInt(Math.floor((t.getRect().x-o)/this.repulsionRange)),f=parseInt(Math.floor((t.getRect().width+t.getRect().x-o)/this.repulsionRange)),p=parseInt(Math.floor((t.getRect().y-s)/this.repulsionRange)),c=parseInt(Math.floor((t.getRect().height+t.getRect().y-s)/this.repulsionRange));for(var d=l;d<=f;d++)for(var y=p;y<=c;y++)this.grid[d][y].push(t),t.setGridCoordinates(l,f,p,c)},r.prototype.updateGrid=function(){var t,o,s=this.getAllNodes();for(this.grid=this.calcGrid(this.graphManager.getRoot()),t=0;t<s.length;t++)o=s[t],this.addNodeToGrid(o,this.graphManager.getRoot().getLeft(),this.graphManager.getRoot().getTop())},r.prototype.calculateRepulsionForceOfANode=function(t,o,s,l){if(this.totalIterations%e.GRID_CALCULATION_CHECK_PERIOD==1&&s||l){var f=new Set;t.surrounding=new Array;for(var p,c=this.grid,d=t.startX-1;d<t.finishX+2;d++)for(var y=t.startY-1;y<t.finishY+2;y++)if(!(d<0||y<0||d>=c.length||y>=c[0].length)){for(var L=0;L<c[d][y].length;L++)if(p=c[d][y][L],!(t.getOwner()!=p.getOwner()||t==p)&&!o.has(p)&&!f.has(p)){var O=Math.abs(t.getCenterX()-p.getCenterX())-(t.getWidth()/2+p.getWidth()/2),I=Math.abs(t.getCenterY()-p.getCenterY())-(t.getHeight()/2+p.getHeight()/2);O<=this.repulsionRange&&I<=this.repulsionRange&&f.add(p)}}t.surrounding=[].concat(h(f))}for(d=0;d<t.surrounding.length;d++)this.calcRepulsionForce(t,t.surrounding[d])},r.prototype.calcRepulsionRange=function(){return 0},E.exports=r}),(function(E,D,v){var h=v(1),n=v(7);function e(a,u,r){h.call(this,a,u,r),this.idealLength=n.DEFAULT_EDGE_LENGTH}e.prototype=Object.create(h.prototype);for(var i in h)e[i]=h[i];E.exports=e}),(function(E,D,v){var h=v(3);function n(i,a,u,r){h.call(this,i,a,u,r),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0,this.startX=0,this.finishX=0,this.startY=0,this.finishY=0,this.surrounding=[]}n.prototype=Object.create(h.prototype);for(var e in h)n[e]=h[e];n.prototype.setGridCoordinates=function(i,a,u,r){this.startX=i,this.finishX=a,this.startY=u,this.finishY=r},E.exports=n}),(function(E,D,v){function h(n,e){this.width=0,this.height=0,n!==null&&e!==null&&(this.height=e,this.width=n)}h.prototype.getWidth=function(){return this.width},h.prototype.setWidth=function(n){this.width=n},h.prototype.getHeight=function(){return this.height},h.prototype.setHeight=function(n){this.height=n},E.exports=h}),(function(E,D,v){var h=v(14);function n(){this.map={},this.keys=[]}n.prototype.put=function(e,i){var a=h.createID(e);this.contains(a)||(this.map[a]=i,this.keys.push(e))},n.prototype.contains=function(e){return h.createID(e),this.map[e]!=null},n.prototype.get=function(e){var i=h.createID(e);return this.map[i]},n.prototype.keySet=function(){return this.keys},E.exports=n}),(function(E,D,v){var h=v(14);function n(){this.set={}}n.prototype.add=function(e){var i=h.createID(e);this.contains(i)||(this.set[i]=e)},n.prototype.remove=function(e){delete this.set[h.createID(e)]},n.prototype.clear=function(){this.set={}},n.prototype.contains=function(e){return this.set[h.createID(e)]==e},n.prototype.isEmpty=function(){return this.size()===0},n.prototype.size=function(){return Object.keys(this.set).length},n.prototype.addAllTo=function(e){for(var i=Object.keys(this.set),a=i.length,u=0;u<a;u++)e.push(this.set[i[u]])},n.prototype.size=function(){return Object.keys(this.set).length},n.prototype.addAll=function(e){for(var i=e.length,a=0;a<i;a++){var u=e[a];this.add(u)}},E.exports=n}),(function(E,D,v){var h=(function(){function a(u,r){for(var g=0;g<r.length;g++){var t=r[g];t.enumerable=t.enumerable||!1,t.configurable=!0,"value"in t&&(t.writable=!0),Object.defineProperty(u,t.key,t)}}return function(u,r,g){return r&&a(u.prototype,r),g&&a(u,g),u}})();function n(a,u){if(!(a instanceof u))throw new TypeError("Cannot call a class as a function")}var e=v(11),i=(function(){function a(u,r){n(this,a),(r!==null||r!==void 0)&&(this.compareFunction=this._defaultCompareFunction);var g=void 0;u instanceof e?g=u.size():g=u.length,this._quicksort(u,0,g-1)}return h(a,[{key:"_quicksort",value:function(r,g,t){if(g<t){var o=this._partition(r,g,t);this._quicksort(r,g,o),this._quicksort(r,o+1,t)}}},{key:"_partition",value:function(r,g,t){for(var o=this._get(r,g),s=g,l=t;;){for(;this.compareFunction(o,this._get(r,l));)l--;for(;this.compareFunction(this._get(r,s),o);)s++;if(s<l)this._swap(r,s,l),s++,l--;else return l}}},{key:"_get",value:function(r,g){return r instanceof e?r.get_object_at(g):r[g]}},{key:"_set",value:function(r,g,t){r instanceof e?r.set_object_at(g,t):r[g]=t}},{key:"_swap",value:function(r,g,t){var o=this._get(r,g);this._set(r,g,this._get(r,t)),this._set(r,t,o)}},{key:"_defaultCompareFunction",value:function(r,g){return g>r}}]),a})();E.exports=i}),(function(E,D,v){var h=(function(){function i(a,u){for(var r=0;r<u.length;r++){var g=u[r];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(a,g.key,g)}}return function(a,u,r){return u&&i(a.prototype,u),r&&i(a,r),a}})();function n(i,a){if(!(i instanceof a))throw new TypeError("Cannot call a class as a function")}var e=(function(){function i(a,u){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,t=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;n(this,i),this.sequence1=a,this.sequence2=u,this.match_score=r,this.mismatch_penalty=g,this.gap_penalty=t,this.iMax=a.length+1,this.jMax=u.length+1,this.grid=new Array(this.iMax);for(var o=0;o<this.iMax;o++){this.grid[o]=new Array(this.jMax);for(var s=0;s<this.jMax;s++)this.grid[o][s]=0}this.tracebackGrid=new Array(this.iMax);for(var l=0;l<this.iMax;l++){this.tracebackGrid[l]=new Array(this.jMax);for(var f=0;f<this.jMax;f++)this.tracebackGrid[l][f]=[null,null,null]}this.alignments=[],this.score=-1,this.computeGrids()}return h(i,[{key:"getScore",value:function(){return this.score}},{key:"getAlignments",value:function(){return this.alignments}},{key:"computeGrids",value:function(){for(var u=1;u<this.jMax;u++)this.grid[0][u]=this.grid[0][u-1]+this.gap_penalty,this.tracebackGrid[0][u]=[!1,!1,!0];for(var r=1;r<this.iMax;r++)this.grid[r][0]=this.grid[r-1][0]+this.gap_penalty,this.tracebackGrid[r][0]=[!1,!0,!1];for(var g=1;g<this.iMax;g++)for(var t=1;t<this.jMax;t++){var o=void 0;this.sequence1[g-1]===this.sequence2[t-1]?o=this.grid[g-1][t-1]+this.match_score:o=this.grid[g-1][t-1]+this.mismatch_penalty;var s=this.grid[g-1][t]+this.gap_penalty,l=this.grid[g][t-1]+this.gap_penalty,f=[o,s,l],p=this.arrayAllMaxIndexes(f);this.grid[g][t]=f[p[0]],this.tracebackGrid[g][t]=[p.includes(0),p.includes(1),p.includes(2)]}this.score=this.grid[this.iMax-1][this.jMax-1]}},{key:"alignmentTraceback",value:function(){var u=[];for(u.push({pos:[this.sequence1.length,this.sequence2.length],seq1:"",seq2:""});u[0];){var r=u[0],g=this.tracebackGrid[r.pos[0]][r.pos[1]];g[0]&&u.push({pos:[r.pos[0]-1,r.pos[1]-1],seq1:this.sequence1[r.pos[0]-1]+r.seq1,seq2:this.sequence2[r.pos[1]-1]+r.seq2}),g[1]&&u.push({pos:[r.pos[0]-1,r.pos[1]],seq1:this.sequence1[r.pos[0]-1]+r.seq1,seq2:"-"+r.seq2}),g[2]&&u.push({pos:[r.pos[0],r.pos[1]-1],seq1:"-"+r.seq1,seq2:this.sequence2[r.pos[1]-1]+r.seq2}),r.pos[0]===0&&r.pos[1]===0&&this.alignments.push({sequence1:r.seq1,sequence2:r.seq2}),u.shift()}return this.alignments}},{key:"getAllIndexes",value:function(u,r){for(var g=[],t=-1;(t=u.indexOf(r,t+1))!==-1;)g.push(t);return g}},{key:"arrayAllMaxIndexes",value:function(u){return this.getAllIndexes(u,Math.max.apply(null,u))}}]),i})();E.exports=e}),(function(E,D,v){var h=function(){};h.FDLayout=v(18),h.FDLayoutConstants=v(7),h.FDLayoutEdge=v(19),h.FDLayoutNode=v(20),h.DimensionD=v(21),h.HashMap=v(22),h.HashSet=v(23),h.IGeometry=v(8),h.IMath=v(9),h.Integer=v(10),h.Point=v(12),h.PointD=v(4),h.RandomSeed=v(16),h.RectangleD=v(13),h.Transform=v(17),h.UniqueIDGeneretor=v(14),h.Quicksort=v(24),h.LinkedList=v(11),h.LGraphObject=v(2),h.LGraph=v(5),h.LEdge=v(1),h.LGraphManager=v(6),h.LNode=v(3),h.Layout=v(15),h.LayoutConstants=v(0),h.NeedlemanWunsch=v(25),E.exports=h}),(function(E,D,v){function h(){this.listeners=[]}var n=h.prototype;n.addListener=function(e,i){this.listeners.push({event:e,callback:i})},n.removeListener=function(e,i){for(var a=this.listeners.length;a>=0;a--){var u=this.listeners[a];u.event===e&&u.callback===i&&this.listeners.splice(a,1)}},n.emit=function(e,i){for(var a=0;a<this.listeners.length;a++){var u=this.listeners[a];e===u.event&&u.callback(i)}},E.exports=h})])})})(P.__module)),P.__module.exports}exports.__require=k;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const P=require("../../_virtual/layout-base.cjs2.js");var W=P.__module.exports,b;function k(){return b||(b=1,(function(H,z){(function(D,v){H.exports=v()})(W,function(){return(function(E){var D={};function v(h){if(D[h])return D[h].exports;var n=D[h]={i:h,l:!1,exports:{}};return E[h].call(n.exports,n,n.exports,v),n.l=!0,n.exports}return v.m=E,v.c=D,v.i=function(h){return h},v.d=function(h,n,e){v.o(h,n)||Object.defineProperty(h,n,{configurable:!1,enumerable:!0,get:e})},v.n=function(h){var n=h&&h.__esModule?function(){return h.default}:function(){return h};return v.d(n,"a",n),n},v.o=function(h,n){return Object.prototype.hasOwnProperty.call(h,n)},v.p="",v(v.s=26)})([(function(E,D,v){function h(){}h.QUALITY=1,h.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,h.DEFAULT_INCREMENTAL=!1,h.DEFAULT_ANIMATION_ON_LAYOUT=!0,h.DEFAULT_ANIMATION_DURING_LAYOUT=!1,h.DEFAULT_ANIMATION_PERIOD=50,h.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,h.DEFAULT_GRAPH_MARGIN=15,h.NODE_DIMENSIONS_INCLUDE_LABELS=!1,h.SIMPLE_NODE_SIZE=40,h.SIMPLE_NODE_HALF_SIZE=h.SIMPLE_NODE_SIZE/2,h.EMPTY_COMPOUND_NODE_SIZE=40,h.MIN_EDGE_LENGTH=1,h.WORLD_BOUNDARY=1e6,h.INITIAL_WORLD_BOUNDARY=h.WORLD_BOUNDARY/1e3,h.WORLD_CENTER_X=1200,h.WORLD_CENTER_Y=900,E.exports=h}),(function(E,D,v){var h=v(2),n=v(8),e=v(9);function i(u,r,g){h.call(this,g),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=g,this.bendpoints=[],this.source=u,this.target=r}i.prototype=Object.create(h.prototype);for(var a in h)i[a]=h[a];i.prototype.getSource=function(){return this.source},i.prototype.getTarget=function(){return this.target},i.prototype.isInterGraph=function(){return this.isInterGraph},i.prototype.getLength=function(){return this.length},i.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},i.prototype.getBendpoints=function(){return this.bendpoints},i.prototype.getLca=function(){return this.lca},i.prototype.getSourceInLca=function(){return this.sourceInLca},i.prototype.getTargetInLca=function(){return this.targetInLca},i.prototype.getOtherEnd=function(u){if(this.source===u)return this.target;if(this.target===u)return this.source;throw"Node is not incident with this edge"},i.prototype.getOtherEndInGraph=function(u,r){for(var g=this.getOtherEnd(u),t=r.getGraphManager().getRoot();;){if(g.getOwner()==r)return g;if(g.getOwner()==t)break;g=g.getOwner().getParent()}return null},i.prototype.updateLength=function(){var u=new Array(4);this.isOverlapingSourceAndTarget=n.getIntersection(this.target.getRect(),this.source.getRect(),u),this.isOverlapingSourceAndTarget||(this.lengthX=u[0]-u[2],this.lengthY=u[1]-u[3],Math.abs(this.lengthX)<1&&(this.lengthX=e.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=e.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},i.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=e.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=e.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},E.exports=i}),(function(E,D,v){function h(n){this.vGraphObject=n}E.exports=h}),(function(E,D,v){var h=v(2),n=v(10),e=v(13),i=v(0),a=v(16),u=v(4);function r(t,o,s,l){s==null&&l==null&&(l=o),h.call(this,l),t.graphManager!=null&&(t=t.graphManager),this.estimatedSize=n.MIN_VALUE,this.inclusionTreeDepth=n.MAX_VALUE,this.vGraphObject=l,this.edges=[],this.graphManager=t,s!=null&&o!=null?this.rect=new e(o.x,o.y,s.width,s.height):this.rect=new e}r.prototype=Object.create(h.prototype);for(var g in h)r[g]=h[g];r.prototype.getEdges=function(){return this.edges},r.prototype.getChild=function(){return this.child},r.prototype.getOwner=function(){return this.owner},r.prototype.getWidth=function(){return this.rect.width},r.prototype.setWidth=function(t){this.rect.width=t},r.prototype.getHeight=function(){return this.rect.height},r.prototype.setHeight=function(t){this.rect.height=t},r.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},r.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},r.prototype.getCenter=function(){return new u(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},r.prototype.getLocation=function(){return new u(this.rect.x,this.rect.y)},r.prototype.getRect=function(){return this.rect},r.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},r.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},r.prototype.setRect=function(t,o){this.rect.x=t.x,this.rect.y=t.y,this.rect.width=o.width,this.rect.height=o.height},r.prototype.setCenter=function(t,o){this.rect.x=t-this.rect.width/2,this.rect.y=o-this.rect.height/2},r.prototype.setLocation=function(t,o){this.rect.x=t,this.rect.y=o},r.prototype.moveBy=function(t,o){this.rect.x+=t,this.rect.y+=o},r.prototype.getEdgeListToNode=function(t){var o=[],s=this;return s.edges.forEach(function(l){if(l.target==t){if(l.source!=s)throw"Incorrect edge source!";o.push(l)}}),o},r.prototype.getEdgesBetween=function(t){var o=[],s=this;return s.edges.forEach(function(l){if(!(l.source==s||l.target==s))throw"Incorrect edge source and/or target";(l.target==t||l.source==t)&&o.push(l)}),o},r.prototype.getNeighborsList=function(){var t=new Set,o=this;return o.edges.forEach(function(s){if(s.source==o)t.add(s.target);else{if(s.target!=o)throw"Incorrect incidency!";t.add(s.source)}}),t},r.prototype.withChildren=function(){var t=new Set,o,s;if(t.add(this),this.child!=null)for(var l=this.child.getNodes(),f=0;f<l.length;f++)o=l[f],s=o.withChildren(),s.forEach(function(p){t.add(p)});return t},r.prototype.getNoOfChildren=function(){var t=0,o;if(this.child==null)t=1;else for(var s=this.child.getNodes(),l=0;l<s.length;l++)o=s[l],t+=o.getNoOfChildren();return t==0&&(t=1),t},r.prototype.getEstimatedSize=function(){if(this.estimatedSize==n.MIN_VALUE)throw"assert failed";return this.estimatedSize},r.prototype.calcEstimatedSize=function(){return this.child==null?this.estimatedSize=(this.rect.width+this.rect.height)/2:(this.estimatedSize=this.child.calcEstimatedSize(),this.rect.width=this.estimatedSize,this.rect.height=this.estimatedSize,this.estimatedSize)},r.prototype.scatter=function(){var t,o,s=-i.INITIAL_WORLD_BOUNDARY,l=i.INITIAL_WORLD_BOUNDARY;t=i.WORLD_CENTER_X+a.nextDouble()*(l-s)+s;var f=-i.INITIAL_WORLD_BOUNDARY,p=i.INITIAL_WORLD_BOUNDARY;o=i.WORLD_CENTER_Y+a.nextDouble()*(p-f)+f,this.rect.x=t,this.rect.y=o},r.prototype.updateBounds=function(){if(this.getChild()==null)throw"assert failed";if(this.getChild().getNodes().length!=0){var t=this.getChild();if(t.updateBounds(!0),this.rect.x=t.getLeft(),this.rect.y=t.getTop(),this.setWidth(t.getRight()-t.getLeft()),this.setHeight(t.getBottom()-t.getTop()),i.NODE_DIMENSIONS_INCLUDE_LABELS){var o=t.getRight()-t.getLeft(),s=t.getBottom()-t.getTop();this.labelWidth>o&&(this.rect.x-=(this.labelWidth-o)/2,this.setWidth(this.labelWidth)),this.labelHeight>s&&(this.labelPos=="center"?this.rect.y-=(this.labelHeight-s)/2:this.labelPos=="top"&&(this.rect.y-=this.labelHeight-s),this.setHeight(this.labelHeight))}}},r.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==n.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},r.prototype.transform=function(t){var o=this.rect.x;o>i.WORLD_BOUNDARY?o=i.WORLD_BOUNDARY:o<-i.WORLD_BOUNDARY&&(o=-i.WORLD_BOUNDARY);var s=this.rect.y;s>i.WORLD_BOUNDARY?s=i.WORLD_BOUNDARY:s<-i.WORLD_BOUNDARY&&(s=-i.WORLD_BOUNDARY);var l=new u(o,s),f=t.inverseTransformPoint(l);this.setLocation(f.x,f.y)},r.prototype.getLeft=function(){return this.rect.x},r.prototype.getRight=function(){return this.rect.x+this.rect.width},r.prototype.getTop=function(){return this.rect.y},r.prototype.getBottom=function(){return this.rect.y+this.rect.height},r.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},E.exports=r}),(function(E,D,v){function h(n,e){n==null&&e==null?(this.x=0,this.y=0):(this.x=n,this.y=e)}h.prototype.getX=function(){return this.x},h.prototype.getY=function(){return this.y},h.prototype.setX=function(n){this.x=n},h.prototype.setY=function(n){this.y=n},h.prototype.getDifference=function(n){return new DimensionD(this.x-n.x,this.y-n.y)},h.prototype.getCopy=function(){return new h(this.x,this.y)},h.prototype.translate=function(n){return this.x+=n.width,this.y+=n.height,this},E.exports=h}),(function(E,D,v){var h=v(2),n=v(10),e=v(0),i=v(6),a=v(3),u=v(1),r=v(13),g=v(12),t=v(11);function o(l,f,p){h.call(this,p),this.estimatedSize=n.MIN_VALUE,this.margin=e.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=l,f!=null&&f instanceof i?this.graphManager=f:f!=null&&f instanceof Layout&&(this.graphManager=f.graphManager)}o.prototype=Object.create(h.prototype);for(var s in h)o[s]=h[s];o.prototype.getNodes=function(){return this.nodes},o.prototype.getEdges=function(){return this.edges},o.prototype.getGraphManager=function(){return this.graphManager},o.prototype.getParent=function(){return this.parent},o.prototype.getLeft=function(){return this.left},o.prototype.getRight=function(){return this.right},o.prototype.getTop=function(){return this.top},o.prototype.getBottom=function(){return this.bottom},o.prototype.isConnected=function(){return this.isConnected},o.prototype.add=function(l,f,p){if(f==null&&p==null){var c=l;if(this.graphManager==null)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(c)>-1)throw"Node already in graph!";return c.owner=this,this.getNodes().push(c),c}else{var d=l;if(!(this.getNodes().indexOf(f)>-1&&this.getNodes().indexOf(p)>-1))throw"Source or target not in graph!";if(!(f.owner==p.owner&&f.owner==this))throw"Both owners must be this graph!";return f.owner!=p.owner?null:(d.source=f,d.target=p,d.isInterGraph=!1,this.getEdges().push(d),f.edges.push(d),p!=f&&p.edges.push(d),d)}},o.prototype.remove=function(l){var f=l;if(l instanceof a){if(f==null)throw"Node is null!";if(!(f.owner!=null&&f.owner==this))throw"Owner graph is invalid!";if(this.graphManager==null)throw"Owner graph manager is invalid!";for(var p=f.edges.slice(),c,d=p.length,y=0;y<d;y++)c=p[y],c.isInterGraph?this.graphManager.remove(c):c.source.owner.remove(c);var L=this.nodes.indexOf(f);if(L==-1)throw"Node not in owner node list!";this.nodes.splice(L,1)}else if(l instanceof u){var c=l;if(c==null)throw"Edge is null!";if(!(c.source!=null&&c.target!=null))throw"Source and/or target is null!";if(!(c.source.owner!=null&&c.target.owner!=null&&c.source.owner==this&&c.target.owner==this))throw"Source and/or target owner is invalid!";var O=c.source.edges.indexOf(c),I=c.target.edges.indexOf(c);if(!(O>-1&&I>-1))throw"Source and/or target doesn't know this edge!";c.source.edges.splice(O,1),c.target!=c.source&&c.target.edges.splice(I,1);var L=c.source.owner.getEdges().indexOf(c);if(L==-1)throw"Not in owner's edge list!";c.source.owner.getEdges().splice(L,1)}},o.prototype.updateLeftTop=function(){for(var l=n.MAX_VALUE,f=n.MAX_VALUE,p,c,d,y=this.getNodes(),L=y.length,O=0;O<L;O++){var I=y[O];p=I.getTop(),c=I.getLeft(),l>p&&(l=p),f>c&&(f=c)}return l==n.MAX_VALUE?null:(y[0].getParent().paddingLeft!=null?d=y[0].getParent().paddingLeft:d=this.margin,this.left=f-d,this.top=l-d,new g(this.left,this.top))},o.prototype.updateBounds=function(l){for(var f=n.MAX_VALUE,p=-n.MAX_VALUE,c=n.MAX_VALUE,d=-n.MAX_VALUE,y,L,O,I,A,T=this.nodes,N=T.length,R=0;R<N;R++){var x=T[R];l&&x.child!=null&&x.updateBounds(),y=x.getLeft(),L=x.getRight(),O=x.getTop(),I=x.getBottom(),f>y&&(f=y),p<L&&(p=L),c>O&&(c=O),d<I&&(d=I)}var m=new r(f,c,p-f,d-c);f==n.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),T[0].getParent().paddingLeft!=null?A=T[0].getParent().paddingLeft:A=this.margin,this.left=m.x-A,this.right=m.x+m.width+A,this.top=m.y-A,this.bottom=m.y+m.height+A},o.calculateBounds=function(l){for(var f=n.MAX_VALUE,p=-n.MAX_VALUE,c=n.MAX_VALUE,d=-n.MAX_VALUE,y,L,O,I,A=l.length,T=0;T<A;T++){var N=l[T];y=N.getLeft(),L=N.getRight(),O=N.getTop(),I=N.getBottom(),f>y&&(f=y),p<L&&(p=L),c>O&&(c=O),d<I&&(d=I)}var R=new r(f,c,p-f,d-c);return R},o.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},o.prototype.getEstimatedSize=function(){if(this.estimatedSize==n.MIN_VALUE)throw"assert failed";return this.estimatedSize},o.prototype.calcEstimatedSize=function(){for(var l=0,f=this.nodes,p=f.length,c=0;c<p;c++){var d=f[c];l+=d.calcEstimatedSize()}return l==0?this.estimatedSize=e.EMPTY_COMPOUND_NODE_SIZE:this.estimatedSize=l/Math.sqrt(this.nodes.length),this.estimatedSize},o.prototype.updateConnected=function(){var l=this;if(this.nodes.length==0){this.isConnected=!0;return}var f=new t,p=new Set,c=this.nodes[0],d,y,L=c.withChildren();for(L.forEach(function(R){f.push(R),p.add(R)});f.length!==0;){c=f.shift(),d=c.getEdges();for(var O=d.length,I=0;I<O;I++){var A=d[I];if(y=A.getOtherEndInGraph(c,this),y!=null&&!p.has(y)){var T=y.withChildren();T.forEach(function(R){f.push(R),p.add(R)})}}}if(this.isConnected=!1,p.size>=this.nodes.length){var N=0;p.forEach(function(R){R.owner==l&&N++}),N==this.nodes.length&&(this.isConnected=!0)}},E.exports=o}),(function(E,D,v){var h,n=v(1);function e(i){h=v(5),this.layout=i,this.graphs=[],this.edges=[]}e.prototype.addRoot=function(){var i=this.layout.newGraph(),a=this.layout.newNode(null),u=this.add(i,a);return this.setRootGraph(u),this.rootGraph},e.prototype.add=function(i,a,u,r,g){if(u==null&&r==null&&g==null){if(i==null)throw"Graph is null!";if(a==null)throw"Parent node is null!";if(this.graphs.indexOf(i)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(i),i.parent!=null)throw"Already has a parent!";if(a.child!=null)throw"Already has a child!";return i.parent=a,a.child=i,i}else{g=u,r=a,u=i;var t=r.getOwner(),o=g.getOwner();if(!(t!=null&&t.getGraphManager()==this))throw"Source not in this graph mgr!";if(!(o!=null&&o.getGraphManager()==this))throw"Target not in this graph mgr!";if(t==o)return u.isInterGraph=!1,t.add(u,r,g);if(u.isInterGraph=!0,u.source=r,u.target=g,this.edges.indexOf(u)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(u),!(u.source!=null&&u.target!=null))throw"Edge source and/or target is null!";if(!(u.source.edges.indexOf(u)==-1&&u.target.edges.indexOf(u)==-1))throw"Edge already in source and/or target incidency list!";return u.source.edges.push(u),u.target.edges.push(u),u}},e.prototype.remove=function(i){if(i instanceof h){var a=i;if(a.getGraphManager()!=this)throw"Graph not in this graph mgr";if(!(a==this.rootGraph||a.parent!=null&&a.parent.graphManager==this))throw"Invalid parent node!";var u=[];u=u.concat(a.getEdges());for(var r,g=u.length,t=0;t<g;t++)r=u[t],a.remove(r);var o=[];o=o.concat(a.getNodes());var s;g=o.length;for(var t=0;t<g;t++)s=o[t],a.remove(s);a==this.rootGraph&&this.setRootGraph(null);var l=this.graphs.indexOf(a);this.graphs.splice(l,1),a.parent=null}else if(i instanceof n){if(r=i,r==null)throw"Edge is null!";if(!r.isInterGraph)throw"Not an inter-graph edge!";if(!(r.source!=null&&r.target!=null))throw"Source and/or target is null!";if(!(r.source.edges.indexOf(r)!=-1&&r.target.edges.indexOf(r)!=-1))throw"Source and/or target doesn't know this edge!";var l=r.source.edges.indexOf(r);if(r.source.edges.splice(l,1),l=r.target.edges.indexOf(r),r.target.edges.splice(l,1),!(r.source.owner!=null&&r.source.owner.getGraphManager()!=null))throw"Edge owner graph or owner graph manager is null!";if(r.source.owner.getGraphManager().edges.indexOf(r)==-1)throw"Not in owner graph manager's edge list!";var l=r.source.owner.getGraphManager().edges.indexOf(r);r.source.owner.getGraphManager().edges.splice(l,1)}},e.prototype.updateBounds=function(){this.rootGraph.updateBounds(!0)},e.prototype.getGraphs=function(){return this.graphs},e.prototype.getAllNodes=function(){if(this.allNodes==null){for(var i=[],a=this.getGraphs(),u=a.length,r=0;r<u;r++)i=i.concat(a[r].getNodes());this.allNodes=i}return this.allNodes},e.prototype.resetAllNodes=function(){this.allNodes=null},e.prototype.resetAllEdges=function(){this.allEdges=null},e.prototype.resetAllNodesToApplyGravitation=function(){this.allNodesToApplyGravitation=null},e.prototype.getAllEdges=function(){if(this.allEdges==null){var i=[],a=this.getGraphs();a.length;for(var u=0;u<a.length;u++)i=i.concat(a[u].getEdges());i=i.concat(this.edges),this.allEdges=i}return this.allEdges},e.prototype.getAllNodesToApplyGravitation=function(){return this.allNodesToApplyGravitation},e.prototype.setAllNodesToApplyGravitation=function(i){if(this.allNodesToApplyGravitation!=null)throw"assert failed";this.allNodesToApplyGravitation=i},e.prototype.getRoot=function(){return this.rootGraph},e.prototype.setRootGraph=function(i){if(i.getGraphManager()!=this)throw"Root not in this graph mgr!";this.rootGraph=i,i.parent==null&&(i.parent=this.layout.newNode("Root node"))},e.prototype.getLayout=function(){return this.layout},e.prototype.isOneAncestorOfOther=function(i,a){if(!(i!=null&&a!=null))throw"assert failed";if(i==a)return!0;var u=i.getOwner(),r;do{if(r=u.getParent(),r==null)break;if(r==a)return!0;if(u=r.getOwner(),u==null)break}while(!0);u=a.getOwner();do{if(r=u.getParent(),r==null)break;if(r==i)return!0;if(u=r.getOwner(),u==null)break}while(!0);return!1},e.prototype.calcLowestCommonAncestors=function(){for(var i,a,u,r,g,t=this.getAllEdges(),o=t.length,s=0;s<o;s++){if(i=t[s],a=i.source,u=i.target,i.lca=null,i.sourceInLca=a,i.targetInLca=u,a==u){i.lca=a.getOwner();continue}for(r=a.getOwner();i.lca==null;){for(i.targetInLca=u,g=u.getOwner();i.lca==null;){if(g==r){i.lca=g;break}if(g==this.rootGraph)break;if(i.lca!=null)throw"assert failed";i.targetInLca=g.getParent(),g=i.targetInLca.getOwner()}if(r==this.rootGraph)break;i.lca==null&&(i.sourceInLca=r.getParent(),r=i.sourceInLca.getOwner())}if(i.lca==null)throw"assert failed"}},e.prototype.calcLowestCommonAncestor=function(i,a){if(i==a)return i.getOwner();var u=i.getOwner();do{if(u==null)break;var r=a.getOwner();do{if(r==null)break;if(r==u)return r;r=r.getParent().getOwner()}while(!0);u=u.getParent().getOwner()}while(!0);return u},e.prototype.calcInclusionTreeDepths=function(i,a){i==null&&a==null&&(i=this.rootGraph,a=1);for(var u,r=i.getNodes(),g=r.length,t=0;t<g;t++)u=r[t],u.inclusionTreeDepth=a,u.child!=null&&this.calcInclusionTreeDepths(u.child,a+1)},e.prototype.includesInvalidEdge=function(){for(var i,a=this.edges.length,u=0;u<a;u++)if(i=this.edges[u],this.isOneAncestorOfOther(i.source,i.target))return!0;return!1},E.exports=e}),(function(E,D,v){var h=v(0);function n(){}for(var e in h)n[e]=h[e];n.MAX_ITERATIONS=2500,n.DEFAULT_EDGE_LENGTH=50,n.DEFAULT_SPRING_STRENGTH=.45,n.DEFAULT_REPULSION_STRENGTH=4500,n.DEFAULT_GRAVITY_STRENGTH=.4,n.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,n.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,n.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,n.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,n.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,n.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,n.COOLING_ADAPTATION_FACTOR=.33,n.ADAPTATION_LOWER_NODE_LIMIT=1e3,n.ADAPTATION_UPPER_NODE_LIMIT=5e3,n.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,n.MAX_NODE_DISPLACEMENT=n.MAX_NODE_DISPLACEMENT_INCREMENTAL*3,n.MIN_REPULSION_DIST=n.DEFAULT_EDGE_LENGTH/10,n.CONVERGENCE_CHECK_PERIOD=100,n.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,n.MIN_EDGE_LENGTH=1,n.GRID_CALCULATION_CHECK_PERIOD=10,E.exports=n}),(function(E,D,v){var h=v(12);function n(){}n.calcSeparationAmount=function(e,i,a,u){if(!e.intersects(i))throw"assert failed";var r=new Array(2);this.decideDirectionsForOverlappingNodes(e,i,r),a[0]=Math.min(e.getRight(),i.getRight())-Math.max(e.x,i.x),a[1]=Math.min(e.getBottom(),i.getBottom())-Math.max(e.y,i.y),e.getX()<=i.getX()&&e.getRight()>=i.getRight()?a[0]+=Math.min(i.getX()-e.getX(),e.getRight()-i.getRight()):i.getX()<=e.getX()&&i.getRight()>=e.getRight()&&(a[0]+=Math.min(e.getX()-i.getX(),i.getRight()-e.getRight())),e.getY()<=i.getY()&&e.getBottom()>=i.getBottom()?a[1]+=Math.min(i.getY()-e.getY(),e.getBottom()-i.getBottom()):i.getY()<=e.getY()&&i.getBottom()>=e.getBottom()&&(a[1]+=Math.min(e.getY()-i.getY(),i.getBottom()-e.getBottom()));var g=Math.abs((i.getCenterY()-e.getCenterY())/(i.getCenterX()-e.getCenterX()));i.getCenterY()===e.getCenterY()&&i.getCenterX()===e.getCenterX()&&(g=1);var t=g*a[0],o=a[1]/g;a[0]<o?o=a[0]:t=a[1],a[0]=-1*r[0]*(o/2+u),a[1]=-1*r[1]*(t/2+u)},n.decideDirectionsForOverlappingNodes=function(e,i,a){e.getCenterX()<i.getCenterX()?a[0]=-1:a[0]=1,e.getCenterY()<i.getCenterY()?a[1]=-1:a[1]=1},n.getIntersection2=function(e,i,a){var u=e.getCenterX(),r=e.getCenterY(),g=i.getCenterX(),t=i.getCenterY();if(e.intersects(i))return a[0]=u,a[1]=r,a[2]=g,a[3]=t,!0;var o=e.getX(),s=e.getY(),l=e.getRight(),f=e.getX(),p=e.getBottom(),c=e.getRight(),d=e.getWidthHalf(),y=e.getHeightHalf(),L=i.getX(),O=i.getY(),I=i.getRight(),A=i.getX(),T=i.getBottom(),N=i.getRight(),R=i.getWidthHalf(),x=i.getHeightHalf(),m=!1,w=!1;if(u===g){if(r>t)return a[0]=u,a[1]=s,a[2]=g,a[3]=T,!1;if(r<t)return a[0]=u,a[1]=p,a[2]=g,a[3]=O,!1}else if(r===t){if(u>g)return a[0]=o,a[1]=r,a[2]=I,a[3]=t,!1;if(u<g)return a[0]=l,a[1]=r,a[2]=L,a[3]=t,!1}else{var C=e.height/e.width,Y=i.height/i.width,M=(t-r)/(g-u),X=void 0,U=void 0,S=void 0,_=void 0,F=void 0,G=void 0;if(-C===M?u>g?(a[0]=f,a[1]=p,m=!0):(a[0]=l,a[1]=s,m=!0):C===M&&(u>g?(a[0]=o,a[1]=s,m=!0):(a[0]=c,a[1]=p,m=!0)),-Y===M?g>u?(a[2]=A,a[3]=T,w=!0):(a[2]=I,a[3]=O,w=!0):Y===M&&(g>u?(a[2]=L,a[3]=O,w=!0):(a[2]=N,a[3]=T,w=!0)),m&&w)return!1;if(u>g?r>t?(X=this.getCardinalDirection(C,M,4),U=this.getCardinalDirection(Y,M,2)):(X=this.getCardinalDirection(-C,M,3),U=this.getCardinalDirection(-Y,M,1)):r>t?(X=this.getCardinalDirection(-C,M,1),U=this.getCardinalDirection(-Y,M,3)):(X=this.getCardinalDirection(C,M,2),U=this.getCardinalDirection(Y,M,4)),!m)switch(X){case 1:_=s,S=u+-y/M,a[0]=S,a[1]=_;break;case 2:S=c,_=r+d*M,a[0]=S,a[1]=_;break;case 3:_=p,S=u+y/M,a[0]=S,a[1]=_;break;case 4:S=f,_=r+-d*M,a[0]=S,a[1]=_;break}if(!w)switch(U){case 1:G=O,F=g+-x/M,a[2]=F,a[3]=G;break;case 2:F=N,G=t+R*M,a[2]=F,a[3]=G;break;case 3:G=T,F=g+x/M,a[2]=F,a[3]=G;break;case 4:F=A,G=t+-R*M,a[2]=F,a[3]=G;break}}return!1},n.getCardinalDirection=function(e,i,a){return e>i?a:1+a%4},n.getIntersection=function(e,i,a,u){if(u==null)return this.getIntersection2(e,i,a);var r=e.x,g=e.y,t=i.x,o=i.y,s=a.x,l=a.y,f=u.x,p=u.y,c=void 0,d=void 0,y=void 0,L=void 0,O=void 0,I=void 0,A=void 0,T=void 0,N=void 0;return y=o-g,O=r-t,A=t*g-r*o,L=p-l,I=s-f,T=f*l-s*p,N=y*I-L*O,N===0?null:(c=(O*T-I*A)/N,d=(L*A-y*T)/N,new h(c,d))},n.angleOfVector=function(e,i,a,u){var r=void 0;return e!==a?(r=Math.atan((u-i)/(a-e)),a<e?r+=Math.PI:u<i&&(r+=this.TWO_PI)):u<i?r=this.ONE_AND_HALF_PI:r=this.HALF_PI,r},n.doIntersect=function(e,i,a,u){var r=e.x,g=e.y,t=i.x,o=i.y,s=a.x,l=a.y,f=u.x,p=u.y,c=(t-r)*(p-l)-(f-s)*(o-g);if(c===0)return!1;var d=((p-l)*(f-r)+(s-f)*(p-g))/c,y=((g-o)*(f-r)+(t-r)*(p-g))/c;return 0<d&&d<1&&0<y&&y<1},n.HALF_PI=.5*Math.PI,n.ONE_AND_HALF_PI=1.5*Math.PI,n.TWO_PI=2*Math.PI,n.THREE_PI=3*Math.PI,E.exports=n}),(function(E,D,v){function h(){}h.sign=function(n){return n>0?1:n<0?-1:0},h.floor=function(n){return n<0?Math.ceil(n):Math.floor(n)},h.ceil=function(n){return n<0?Math.floor(n):Math.ceil(n)},E.exports=h}),(function(E,D,v){function h(){}h.MAX_VALUE=2147483647,h.MIN_VALUE=-2147483648,E.exports=h}),(function(E,D,v){var h=(function(){function r(g,t){for(var o=0;o<t.length;o++){var s=t[o];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(g,s.key,s)}}return function(g,t,o){return t&&r(g.prototype,t),o&&r(g,o),g}})();function n(r,g){if(!(r instanceof g))throw new TypeError("Cannot call a class as a function")}var e=function(g){return{value:g,next:null,prev:null}},i=function(g,t,o,s){return g!==null?g.next=t:s.head=t,o!==null?o.prev=t:s.tail=t,t.prev=g,t.next=o,s.length++,t},a=function(g,t){var o=g.prev,s=g.next;return o!==null?o.next=s:t.head=s,s!==null?s.prev=o:t.tail=o,g.prev=g.next=null,t.length--,g},u=(function(){function r(g){var t=this;n(this,r),this.length=0,this.head=null,this.tail=null,g?.forEach(function(o){return t.push(o)})}return h(r,[{key:"size",value:function(){return this.length}},{key:"insertBefore",value:function(t,o){return i(o.prev,e(t),o,this)}},{key:"insertAfter",value:function(t,o){return i(o,e(t),o.next,this)}},{key:"insertNodeBefore",value:function(t,o){return i(o.prev,t,o,this)}},{key:"insertNodeAfter",value:function(t,o){return i(o,t,o.next,this)}},{key:"push",value:function(t){return i(this.tail,e(t),null,this)}},{key:"unshift",value:function(t){return i(null,e(t),this.head,this)}},{key:"remove",value:function(t){return a(t,this)}},{key:"pop",value:function(){return a(this.tail,this).value}},{key:"popNode",value:function(){return a(this.tail,this)}},{key:"shift",value:function(){return a(this.head,this).value}},{key:"shiftNode",value:function(){return a(this.head,this)}},{key:"get_object_at",value:function(t){if(t<=this.length()){for(var o=1,s=this.head;o<t;)s=s.next,o++;return s.value}}},{key:"set_object_at",value:function(t,o){if(t<=this.length()){for(var s=1,l=this.head;s<t;)l=l.next,s++;l.value=o}}}]),r})();E.exports=u}),(function(E,D,v){function h(n,e,i){this.x=null,this.y=null,n==null&&e==null&&i==null?(this.x=0,this.y=0):typeof n=="number"&&typeof e=="number"&&i==null?(this.x=n,this.y=e):n.constructor.name=="Point"&&e==null&&i==null&&(i=n,this.x=i.x,this.y=i.y)}h.prototype.getX=function(){return this.x},h.prototype.getY=function(){return this.y},h.prototype.getLocation=function(){return new h(this.x,this.y)},h.prototype.setLocation=function(n,e,i){n.constructor.name=="Point"&&e==null&&i==null?(i=n,this.setLocation(i.x,i.y)):typeof n=="number"&&typeof e=="number"&&i==null&&(parseInt(n)==n&&parseInt(e)==e?this.move(n,e):(this.x=Math.floor(n+.5),this.y=Math.floor(e+.5)))},h.prototype.move=function(n,e){this.x=n,this.y=e},h.prototype.translate=function(n,e){this.x+=n,this.y+=e},h.prototype.equals=function(n){if(n.constructor.name=="Point"){var e=n;return this.x==e.x&&this.y==e.y}return this==n},h.prototype.toString=function(){return new h().constructor.name+"[x="+this.x+",y="+this.y+"]"},E.exports=h}),(function(E,D,v){function h(n,e,i,a){this.x=0,this.y=0,this.width=0,this.height=0,n!=null&&e!=null&&i!=null&&a!=null&&(this.x=n,this.y=e,this.width=i,this.height=a)}h.prototype.getX=function(){return this.x},h.prototype.setX=function(n){this.x=n},h.prototype.getY=function(){return this.y},h.prototype.setY=function(n){this.y=n},h.prototype.getWidth=function(){return this.width},h.prototype.setWidth=function(n){this.width=n},h.prototype.getHeight=function(){return this.height},h.prototype.setHeight=function(n){this.height=n},h.prototype.getRight=function(){return this.x+this.width},h.prototype.getBottom=function(){return this.y+this.height},h.prototype.intersects=function(n){return!(this.getRight()<n.x||this.getBottom()<n.y||n.getRight()<this.x||n.getBottom()<this.y)},h.prototype.getCenterX=function(){return this.x+this.width/2},h.prototype.getMinX=function(){return this.getX()},h.prototype.getMaxX=function(){return this.getX()+this.width},h.prototype.getCenterY=function(){return this.y+this.height/2},h.prototype.getMinY=function(){return this.getY()},h.prototype.getMaxY=function(){return this.getY()+this.height},h.prototype.getWidthHalf=function(){return this.width/2},h.prototype.getHeightHalf=function(){return this.height/2},E.exports=h}),(function(E,D,v){var h=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function n(){}n.lastID=0,n.createID=function(e){return n.isPrimitive(e)?e:(e.uniqueID!=null||(e.uniqueID=n.getString(),n.lastID++),e.uniqueID)},n.getString=function(e){return e==null&&(e=n.lastID),"Object#"+e},n.isPrimitive=function(e){var i=typeof e>"u"?"undefined":h(e);return e==null||i!="object"&&i!="function"},E.exports=n}),(function(E,D,v){function h(s){if(Array.isArray(s)){for(var l=0,f=Array(s.length);l<s.length;l++)f[l]=s[l];return f}else return Array.from(s)}var n=v(0),e=v(6),i=v(3),a=v(1),u=v(5),r=v(4),g=v(17),t=v(27);function o(s){t.call(this),this.layoutQuality=n.QUALITY,this.createBendsAsNeeded=n.DEFAULT_CREATE_BENDS_AS_NEEDED,this.incremental=n.DEFAULT_INCREMENTAL,this.animationOnLayout=n.DEFAULT_ANIMATION_ON_LAYOUT,this.animationDuringLayout=n.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=n.DEFAULT_ANIMATION_PERIOD,this.uniformLeafNodeSizes=n.DEFAULT_UNIFORM_LEAF_NODE_SIZES,this.edgeToDummyNodes=new Map,this.graphManager=new e(this),this.isLayoutFinished=!1,this.isSubLayout=!1,this.isRemoteUse=!1,s!=null&&(this.isRemoteUse=s)}o.RANDOM_SEED=1,o.prototype=Object.create(t.prototype),o.prototype.getGraphManager=function(){return this.graphManager},o.prototype.getAllNodes=function(){return this.graphManager.getAllNodes()},o.prototype.getAllEdges=function(){return this.graphManager.getAllEdges()},o.prototype.getAllNodesToApplyGravitation=function(){return this.graphManager.getAllNodesToApplyGravitation()},o.prototype.newGraphManager=function(){var s=new e(this);return this.graphManager=s,s},o.prototype.newGraph=function(s){return new u(null,this.graphManager,s)},o.prototype.newNode=function(s){return new i(this.graphManager,s)},o.prototype.newEdge=function(s){return new a(null,null,s)},o.prototype.checkLayoutSuccess=function(){return this.graphManager.getRoot()==null||this.graphManager.getRoot().getNodes().length==0||this.graphManager.includesInvalidEdge()},o.prototype.runLayout=function(){this.isLayoutFinished=!1,this.tilingPreLayout&&this.tilingPreLayout(),this.initParameters();var s;return this.checkLayoutSuccess()?s=!1:s=this.layout(),n.ANIMATE==="during"?!1:(s&&(this.isSubLayout||this.doPostLayout()),this.tilingPostLayout&&this.tilingPostLayout(),this.isLayoutFinished=!0,s)},o.prototype.doPostLayout=function(){this.incremental||this.transform(),this.update()},o.prototype.update2=function(){if(this.createBendsAsNeeded&&(this.createBendpointsFromDummyNodes(),this.graphManager.resetAllEdges()),!this.isRemoteUse){for(var s=this.graphManager.getAllEdges(),l=0;l<s.length;l++)s[l];for(var f=this.graphManager.getRoot().getNodes(),l=0;l<f.length;l++)f[l];this.update(this.graphManager.getRoot())}},o.prototype.update=function(s){if(s==null)this.update2();else if(s instanceof i){var l=s;if(l.getChild()!=null)for(var f=l.getChild().getNodes(),p=0;p<f.length;p++)update(f[p]);if(l.vGraphObject!=null){var c=l.vGraphObject;c.update(l)}}else if(s instanceof a){var d=s;if(d.vGraphObject!=null){var y=d.vGraphObject;y.update(d)}}else if(s instanceof u){var L=s;if(L.vGraphObject!=null){var O=L.vGraphObject;O.update(L)}}},o.prototype.initParameters=function(){this.isSubLayout||(this.layoutQuality=n.QUALITY,this.animationDuringLayout=n.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=n.DEFAULT_ANIMATION_PERIOD,this.animationOnLayout=n.DEFAULT_ANIMATION_ON_LAYOUT,this.incremental=n.DEFAULT_INCREMENTAL,this.createBendsAsNeeded=n.DEFAULT_CREATE_BENDS_AS_NEEDED,this.uniformLeafNodeSizes=n.DEFAULT_UNIFORM_LEAF_NODE_SIZES),this.animationDuringLayout&&(this.animationOnLayout=!1)},o.prototype.transform=function(s){if(s==null)this.transform(new r(0,0));else{var l=new g,f=this.graphManager.getRoot().updateLeftTop();if(f!=null){l.setWorldOrgX(s.x),l.setWorldOrgY(s.y),l.setDeviceOrgX(f.x),l.setDeviceOrgY(f.y);for(var p=this.getAllNodes(),c,d=0;d<p.length;d++)c=p[d],c.transform(l)}}},o.prototype.positionNodesRandomly=function(s){if(s==null)this.positionNodesRandomly(this.getGraphManager().getRoot()),this.getGraphManager().getRoot().updateBounds(!0);else for(var l,f,p=s.getNodes(),c=0;c<p.length;c++)l=p[c],f=l.getChild(),f==null||f.getNodes().length==0?l.scatter():(this.positionNodesRandomly(f),l.updateBounds())},o.prototype.getFlatForest=function(){for(var s=[],l=!0,f=this.graphManager.getRoot().getNodes(),p=!0,c=0;c<f.length;c++)f[c].getChild()!=null&&(p=!1);if(!p)return s;var d=new Set,y=[],L=new Map,O=[];for(O=O.concat(f);O.length>0&&l;){for(y.push(O[0]);y.length>0&&l;){var I=y[0];y.splice(0,1),d.add(I);for(var A=I.getEdges(),c=0;c<A.length;c++){var T=A[c].getOtherEnd(I);if(L.get(I)!=T)if(!d.has(T))y.push(T),L.set(T,I);else{l=!1;break}}}if(!l)s=[];else{var N=[].concat(h(d));s.push(N);for(var c=0;c<N.length;c++){var R=N[c],x=O.indexOf(R);x>-1&&O.splice(x,1)}d=new Set,L=new Map}}return s},o.prototype.createDummyNodesForBendpoints=function(s){for(var l=[],f=s.source,p=this.graphManager.calcLowestCommonAncestor(s.source,s.target),c=0;c<s.bendpoints.length;c++){var d=this.newNode(null);d.setRect(new Point(0,0),new Dimension(1,1)),p.add(d);var y=this.newEdge(null);this.graphManager.add(y,f,d),l.add(d),f=d}var y=this.newEdge(null);return this.graphManager.add(y,f,s.target),this.edgeToDummyNodes.set(s,l),s.isInterGraph()?this.graphManager.remove(s):p.remove(s),l},o.prototype.createBendpointsFromDummyNodes=function(){var s=[];s=s.concat(this.graphManager.getAllEdges()),s=[].concat(h(this.edgeToDummyNodes.keys())).concat(s);for(var l=0;l<s.length;l++){var f=s[l];if(f.bendpoints.length>0){for(var p=this.edgeToDummyNodes.get(f),c=0;c<p.length;c++){var d=p[c],y=new r(d.getCenterX(),d.getCenterY()),L=f.bendpoints.get(c);L.x=y.x,L.y=y.y,d.getOwner().remove(d)}this.graphManager.add(f,f.source,f.target)}}},o.transform=function(s,l,f,p){if(f!=null&&p!=null){var c=l;if(s<=50){var d=l/f;c-=(l-d)/50*(50-s)}else{var y=l*p;c+=(y-l)/50*(s-50)}return c}else{var L,O;return s<=50?(L=9*l/500,O=l/10):(L=9*l/50,O=-8*l),L*s+O}},o.findCenterOfTree=function(s){var l=[];l=l.concat(s);var f=[],p=new Map,c=!1,d=null;(l.length==1||l.length==2)&&(c=!0,d=l[0]);for(var y=0;y<l.length;y++){var L=l[y],O=L.getNeighborsList().size;p.set(L,L.getNeighborsList().size),O==1&&f.push(L)}var I=[];for(I=I.concat(f);!c;){var A=[];A=A.concat(I),I=[];for(var y=0;y<l.length;y++){var L=l[y],T=l.indexOf(L);T>=0&&l.splice(T,1);var N=L.getNeighborsList();N.forEach(function(m){if(f.indexOf(m)<0){var w=p.get(m),C=w-1;C==1&&I.push(m),p.set(m,C)}})}f=f.concat(I),(l.length==1||l.length==2)&&(c=!0,d=l[0])}return d},o.prototype.setGraphManager=function(s){this.graphManager=s},E.exports=o}),(function(E,D,v){function h(){}h.seed=1,h.x=0,h.nextDouble=function(){return h.x=Math.sin(h.seed++)*1e4,h.x-Math.floor(h.x)},E.exports=h}),(function(E,D,v){var h=v(4);function n(e,i){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}n.prototype.getWorldOrgX=function(){return this.lworldOrgX},n.prototype.setWorldOrgX=function(e){this.lworldOrgX=e},n.prototype.getWorldOrgY=function(){return this.lworldOrgY},n.prototype.setWorldOrgY=function(e){this.lworldOrgY=e},n.prototype.getWorldExtX=function(){return this.lworldExtX},n.prototype.setWorldExtX=function(e){this.lworldExtX=e},n.prototype.getWorldExtY=function(){return this.lworldExtY},n.prototype.setWorldExtY=function(e){this.lworldExtY=e},n.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},n.prototype.setDeviceOrgX=function(e){this.ldeviceOrgX=e},n.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},n.prototype.setDeviceOrgY=function(e){this.ldeviceOrgY=e},n.prototype.getDeviceExtX=function(){return this.ldeviceExtX},n.prototype.setDeviceExtX=function(e){this.ldeviceExtX=e},n.prototype.getDeviceExtY=function(){return this.ldeviceExtY},n.prototype.setDeviceExtY=function(e){this.ldeviceExtY=e},n.prototype.transformX=function(e){var i=0,a=this.lworldExtX;return a!=0&&(i=this.ldeviceOrgX+(e-this.lworldOrgX)*this.ldeviceExtX/a),i},n.prototype.transformY=function(e){var i=0,a=this.lworldExtY;return a!=0&&(i=this.ldeviceOrgY+(e-this.lworldOrgY)*this.ldeviceExtY/a),i},n.prototype.inverseTransformX=function(e){var i=0,a=this.ldeviceExtX;return a!=0&&(i=this.lworldOrgX+(e-this.ldeviceOrgX)*this.lworldExtX/a),i},n.prototype.inverseTransformY=function(e){var i=0,a=this.ldeviceExtY;return a!=0&&(i=this.lworldOrgY+(e-this.ldeviceOrgY)*this.lworldExtY/a),i},n.prototype.inverseTransformPoint=function(e){var i=new h(this.inverseTransformX(e.x),this.inverseTransformY(e.y));return i},E.exports=n}),(function(E,D,v){function h(t){if(Array.isArray(t)){for(var o=0,s=Array(t.length);o<t.length;o++)s[o]=t[o];return s}else return Array.from(t)}var n=v(15),e=v(7),i=v(0),a=v(8),u=v(9);function r(){n.call(this),this.useSmartIdealEdgeLengthCalculation=e.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=e.DEFAULT_EDGE_LENGTH,this.springConstant=e.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=e.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=e.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=e.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=e.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=e.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*e.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=e.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=e.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=e.MAX_ITERATIONS}r.prototype=Object.create(n.prototype);for(var g in n)r[g]=n[g];r.prototype.initParameters=function(){n.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=e.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},r.prototype.calcIdealEdgeLengths=function(){for(var t,o,s,l,f,p,c=this.getGraphManager().getAllEdges(),d=0;d<c.length;d++)t=c[d],t.idealLength=this.idealEdgeLength,t.isInterGraph&&(s=t.getSource(),l=t.getTarget(),f=t.getSourceInLca().getEstimatedSize(),p=t.getTargetInLca().getEstimatedSize(),this.useSmartIdealEdgeLengthCalculation&&(t.idealLength+=f+p-2*i.SIMPLE_NODE_SIZE),o=t.getLca().getInclusionTreeDepth(),t.idealLength+=e.DEFAULT_EDGE_LENGTH*e.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR*(s.getInclusionTreeDepth()+l.getInclusionTreeDepth()-2*o))},r.prototype.initSpringEmbedder=function(){var t=this.getAllNodes().length;this.incremental?(t>e.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*e.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(t-e.ADAPTATION_LOWER_NODE_LIMIT)/(e.ADAPTATION_UPPER_NODE_LIMIT-e.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-e.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=e.MAX_NODE_DISPLACEMENT_INCREMENTAL):(t>e.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(e.COOLING_ADAPTATION_FACTOR,1-(t-e.ADAPTATION_LOWER_NODE_LIMIT)/(e.ADAPTATION_UPPER_NODE_LIMIT-e.ADAPTATION_LOWER_NODE_LIMIT)*(1-e.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=e.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},r.prototype.calcSpringForces=function(){for(var t=this.getAllEdges(),o,s=0;s<t.length;s++)o=t[s],this.calcSpringForce(o,o.idealLength)},r.prototype.calcRepulsionForces=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,s,l,f,p,c=this.getAllNodes(),d;if(this.useFRGridVariant)for(this.totalIterations%e.GRID_CALCULATION_CHECK_PERIOD==1&&t&&this.updateGrid(),d=new Set,s=0;s<c.length;s++)f=c[s],this.calculateRepulsionForceOfANode(f,d,t,o),d.add(f);else for(s=0;s<c.length;s++)for(f=c[s],l=s+1;l<c.length;l++)p=c[l],f.getOwner()==p.getOwner()&&this.calcRepulsionForce(f,p)},r.prototype.calcGravitationalForces=function(){for(var t,o=this.getAllNodesToApplyGravitation(),s=0;s<o.length;s++)t=o[s],this.calcGravitationalForce(t)},r.prototype.moveNodes=function(){for(var t=this.getAllNodes(),o,s=0;s<t.length;s++)o=t[s],o.move()},r.prototype.calcSpringForce=function(t,o){var s=t.getSource(),l=t.getTarget(),f,p,c,d;if(this.uniformLeafNodeSizes&&s.getChild()==null&&l.getChild()==null)t.updateLengthSimple();else if(t.updateLength(),t.isOverlapingSourceAndTarget)return;f=t.getLength(),f!=0&&(p=this.springConstant*(f-o),c=p*(t.lengthX/f),d=p*(t.lengthY/f),s.springForceX+=c,s.springForceY+=d,l.springForceX-=c,l.springForceY-=d)},r.prototype.calcRepulsionForce=function(t,o){var s=t.getRect(),l=o.getRect(),f=new Array(2),p=new Array(4),c,d,y,L,O,I,A;if(s.intersects(l)){a.calcSeparationAmount(s,l,f,e.DEFAULT_EDGE_LENGTH/2),I=2*f[0],A=2*f[1];var T=t.noOfChildren*o.noOfChildren/(t.noOfChildren+o.noOfChildren);t.repulsionForceX-=T*I,t.repulsionForceY-=T*A,o.repulsionForceX+=T*I,o.repulsionForceY+=T*A}else this.uniformLeafNodeSizes&&t.getChild()==null&&o.getChild()==null?(c=l.getCenterX()-s.getCenterX(),d=l.getCenterY()-s.getCenterY()):(a.getIntersection(s,l,p),c=p[2]-p[0],d=p[3]-p[1]),Math.abs(c)<e.MIN_REPULSION_DIST&&(c=u.sign(c)*e.MIN_REPULSION_DIST),Math.abs(d)<e.MIN_REPULSION_DIST&&(d=u.sign(d)*e.MIN_REPULSION_DIST),y=c*c+d*d,L=Math.sqrt(y),O=this.repulsionConstant*t.noOfChildren*o.noOfChildren/y,I=O*c/L,A=O*d/L,t.repulsionForceX-=I,t.repulsionForceY-=A,o.repulsionForceX+=I,o.repulsionForceY+=A},r.prototype.calcGravitationalForce=function(t){var o,s,l,f,p,c,d,y;o=t.getOwner(),s=(o.getRight()+o.getLeft())/2,l=(o.getTop()+o.getBottom())/2,f=t.getCenterX()-s,p=t.getCenterY()-l,c=Math.abs(f)+t.getWidth()/2,d=Math.abs(p)+t.getHeight()/2,t.getOwner()==this.graphManager.getRoot()?(y=o.getEstimatedSize()*this.gravityRangeFactor,(c>y||d>y)&&(t.gravitationForceX=-this.gravityConstant*f,t.gravitationForceY=-this.gravityConstant*p)):(y=o.getEstimatedSize()*this.compoundGravityRangeFactor,(c>y||d>y)&&(t.gravitationForceX=-this.gravityConstant*f*this.compoundGravityConstant,t.gravitationForceY=-this.gravityConstant*p*this.compoundGravityConstant))},r.prototype.isConverged=function(){var t,o=!1;return this.totalIterations>this.maxIterations/3&&(o=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),t=this.totalDisplacement<this.totalDisplacementThreshold,this.oldTotalDisplacement=this.totalDisplacement,t||o},r.prototype.animate=function(){this.animationDuringLayout&&!this.isSubLayout&&(this.notAnimatedIterations==this.animationPeriod?(this.update(),this.notAnimatedIterations=0):this.notAnimatedIterations++)},r.prototype.calcNoOfChildrenForAllNodes=function(){for(var t,o=this.graphManager.getAllNodes(),s=0;s<o.length;s++)t=o[s],t.noOfChildren=t.getNoOfChildren()},r.prototype.calcGrid=function(t){var o=0,s=0;o=parseInt(Math.ceil((t.getRight()-t.getLeft())/this.repulsionRange)),s=parseInt(Math.ceil((t.getBottom()-t.getTop())/this.repulsionRange));for(var l=new Array(o),f=0;f<o;f++)l[f]=new Array(s);for(var f=0;f<o;f++)for(var p=0;p<s;p++)l[f][p]=new Array;return l},r.prototype.addNodeToGrid=function(t,o,s){var l=0,f=0,p=0,c=0;l=parseInt(Math.floor((t.getRect().x-o)/this.repulsionRange)),f=parseInt(Math.floor((t.getRect().width+t.getRect().x-o)/this.repulsionRange)),p=parseInt(Math.floor((t.getRect().y-s)/this.repulsionRange)),c=parseInt(Math.floor((t.getRect().height+t.getRect().y-s)/this.repulsionRange));for(var d=l;d<=f;d++)for(var y=p;y<=c;y++)this.grid[d][y].push(t),t.setGridCoordinates(l,f,p,c)},r.prototype.updateGrid=function(){var t,o,s=this.getAllNodes();for(this.grid=this.calcGrid(this.graphManager.getRoot()),t=0;t<s.length;t++)o=s[t],this.addNodeToGrid(o,this.graphManager.getRoot().getLeft(),this.graphManager.getRoot().getTop())},r.prototype.calculateRepulsionForceOfANode=function(t,o,s,l){if(this.totalIterations%e.GRID_CALCULATION_CHECK_PERIOD==1&&s||l){var f=new Set;t.surrounding=new Array;for(var p,c=this.grid,d=t.startX-1;d<t.finishX+2;d++)for(var y=t.startY-1;y<t.finishY+2;y++)if(!(d<0||y<0||d>=c.length||y>=c[0].length)){for(var L=0;L<c[d][y].length;L++)if(p=c[d][y][L],!(t.getOwner()!=p.getOwner()||t==p)&&!o.has(p)&&!f.has(p)){var O=Math.abs(t.getCenterX()-p.getCenterX())-(t.getWidth()/2+p.getWidth()/2),I=Math.abs(t.getCenterY()-p.getCenterY())-(t.getHeight()/2+p.getHeight()/2);O<=this.repulsionRange&&I<=this.repulsionRange&&f.add(p)}}t.surrounding=[].concat(h(f))}for(d=0;d<t.surrounding.length;d++)this.calcRepulsionForce(t,t.surrounding[d])},r.prototype.calcRepulsionRange=function(){return 0},E.exports=r}),(function(E,D,v){var h=v(1),n=v(7);function e(a,u,r){h.call(this,a,u,r),this.idealLength=n.DEFAULT_EDGE_LENGTH}e.prototype=Object.create(h.prototype);for(var i in h)e[i]=h[i];E.exports=e}),(function(E,D,v){var h=v(3);function n(i,a,u,r){h.call(this,i,a,u,r),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0,this.startX=0,this.finishX=0,this.startY=0,this.finishY=0,this.surrounding=[]}n.prototype=Object.create(h.prototype);for(var e in h)n[e]=h[e];n.prototype.setGridCoordinates=function(i,a,u,r){this.startX=i,this.finishX=a,this.startY=u,this.finishY=r},E.exports=n}),(function(E,D,v){function h(n,e){this.width=0,this.height=0,n!==null&&e!==null&&(this.height=e,this.width=n)}h.prototype.getWidth=function(){return this.width},h.prototype.setWidth=function(n){this.width=n},h.prototype.getHeight=function(){return this.height},h.prototype.setHeight=function(n){this.height=n},E.exports=h}),(function(E,D,v){var h=v(14);function n(){this.map={},this.keys=[]}n.prototype.put=function(e,i){var a=h.createID(e);this.contains(a)||(this.map[a]=i,this.keys.push(e))},n.prototype.contains=function(e){return h.createID(e),this.map[e]!=null},n.prototype.get=function(e){var i=h.createID(e);return this.map[i]},n.prototype.keySet=function(){return this.keys},E.exports=n}),(function(E,D,v){var h=v(14);function n(){this.set={}}n.prototype.add=function(e){var i=h.createID(e);this.contains(i)||(this.set[i]=e)},n.prototype.remove=function(e){delete this.set[h.createID(e)]},n.prototype.clear=function(){this.set={}},n.prototype.contains=function(e){return this.set[h.createID(e)]==e},n.prototype.isEmpty=function(){return this.size()===0},n.prototype.size=function(){return Object.keys(this.set).length},n.prototype.addAllTo=function(e){for(var i=Object.keys(this.set),a=i.length,u=0;u<a;u++)e.push(this.set[i[u]])},n.prototype.size=function(){return Object.keys(this.set).length},n.prototype.addAll=function(e){for(var i=e.length,a=0;a<i;a++){var u=e[a];this.add(u)}},E.exports=n}),(function(E,D,v){var h=(function(){function a(u,r){for(var g=0;g<r.length;g++){var t=r[g];t.enumerable=t.enumerable||!1,t.configurable=!0,"value"in t&&(t.writable=!0),Object.defineProperty(u,t.key,t)}}return function(u,r,g){return r&&a(u.prototype,r),g&&a(u,g),u}})();function n(a,u){if(!(a instanceof u))throw new TypeError("Cannot call a class as a function")}var e=v(11),i=(function(){function a(u,r){n(this,a),(r!==null||r!==void 0)&&(this.compareFunction=this._defaultCompareFunction);var g=void 0;u instanceof e?g=u.size():g=u.length,this._quicksort(u,0,g-1)}return h(a,[{key:"_quicksort",value:function(r,g,t){if(g<t){var o=this._partition(r,g,t);this._quicksort(r,g,o),this._quicksort(r,o+1,t)}}},{key:"_partition",value:function(r,g,t){for(var o=this._get(r,g),s=g,l=t;;){for(;this.compareFunction(o,this._get(r,l));)l--;for(;this.compareFunction(this._get(r,s),o);)s++;if(s<l)this._swap(r,s,l),s++,l--;else return l}}},{key:"_get",value:function(r,g){return r instanceof e?r.get_object_at(g):r[g]}},{key:"_set",value:function(r,g,t){r instanceof e?r.set_object_at(g,t):r[g]=t}},{key:"_swap",value:function(r,g,t){var o=this._get(r,g);this._set(r,g,this._get(r,t)),this._set(r,t,o)}},{key:"_defaultCompareFunction",value:function(r,g){return g>r}}]),a})();E.exports=i}),(function(E,D,v){var h=(function(){function i(a,u){for(var r=0;r<u.length;r++){var g=u[r];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(a,g.key,g)}}return function(a,u,r){return u&&i(a.prototype,u),r&&i(a,r),a}})();function n(i,a){if(!(i instanceof a))throw new TypeError("Cannot call a class as a function")}var e=(function(){function i(a,u){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,t=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;n(this,i),this.sequence1=a,this.sequence2=u,this.match_score=r,this.mismatch_penalty=g,this.gap_penalty=t,this.iMax=a.length+1,this.jMax=u.length+1,this.grid=new Array(this.iMax);for(var o=0;o<this.iMax;o++){this.grid[o]=new Array(this.jMax);for(var s=0;s<this.jMax;s++)this.grid[o][s]=0}this.tracebackGrid=new Array(this.iMax);for(var l=0;l<this.iMax;l++){this.tracebackGrid[l]=new Array(this.jMax);for(var f=0;f<this.jMax;f++)this.tracebackGrid[l][f]=[null,null,null]}this.alignments=[],this.score=-1,this.computeGrids()}return h(i,[{key:"getScore",value:function(){return this.score}},{key:"getAlignments",value:function(){return this.alignments}},{key:"computeGrids",value:function(){for(var u=1;u<this.jMax;u++)this.grid[0][u]=this.grid[0][u-1]+this.gap_penalty,this.tracebackGrid[0][u]=[!1,!1,!0];for(var r=1;r<this.iMax;r++)this.grid[r][0]=this.grid[r-1][0]+this.gap_penalty,this.tracebackGrid[r][0]=[!1,!0,!1];for(var g=1;g<this.iMax;g++)for(var t=1;t<this.jMax;t++){var o=void 0;this.sequence1[g-1]===this.sequence2[t-1]?o=this.grid[g-1][t-1]+this.match_score:o=this.grid[g-1][t-1]+this.mismatch_penalty;var s=this.grid[g-1][t]+this.gap_penalty,l=this.grid[g][t-1]+this.gap_penalty,f=[o,s,l],p=this.arrayAllMaxIndexes(f);this.grid[g][t]=f[p[0]],this.tracebackGrid[g][t]=[p.includes(0),p.includes(1),p.includes(2)]}this.score=this.grid[this.iMax-1][this.jMax-1]}},{key:"alignmentTraceback",value:function(){var u=[];for(u.push({pos:[this.sequence1.length,this.sequence2.length],seq1:"",seq2:""});u[0];){var r=u[0],g=this.tracebackGrid[r.pos[0]][r.pos[1]];g[0]&&u.push({pos:[r.pos[0]-1,r.pos[1]-1],seq1:this.sequence1[r.pos[0]-1]+r.seq1,seq2:this.sequence2[r.pos[1]-1]+r.seq2}),g[1]&&u.push({pos:[r.pos[0]-1,r.pos[1]],seq1:this.sequence1[r.pos[0]-1]+r.seq1,seq2:"-"+r.seq2}),g[2]&&u.push({pos:[r.pos[0],r.pos[1]-1],seq1:"-"+r.seq1,seq2:this.sequence2[r.pos[1]-1]+r.seq2}),r.pos[0]===0&&r.pos[1]===0&&this.alignments.push({sequence1:r.seq1,sequence2:r.seq2}),u.shift()}return this.alignments}},{key:"getAllIndexes",value:function(u,r){for(var g=[],t=-1;(t=u.indexOf(r,t+1))!==-1;)g.push(t);return g}},{key:"arrayAllMaxIndexes",value:function(u){return this.getAllIndexes(u,Math.max.apply(null,u))}}]),i})();E.exports=e}),(function(E,D,v){var h=function(){};h.FDLayout=v(18),h.FDLayoutConstants=v(7),h.FDLayoutEdge=v(19),h.FDLayoutNode=v(20),h.DimensionD=v(21),h.HashMap=v(22),h.HashSet=v(23),h.IGeometry=v(8),h.IMath=v(9),h.Integer=v(10),h.Point=v(12),h.PointD=v(4),h.RandomSeed=v(16),h.RectangleD=v(13),h.Transform=v(17),h.UniqueIDGeneretor=v(14),h.Quicksort=v(24),h.LinkedList=v(11),h.LGraphObject=v(2),h.LGraph=v(5),h.LEdge=v(1),h.LGraphManager=v(6),h.LNode=v(3),h.Layout=v(15),h.LayoutConstants=v(0),h.NeedlemanWunsch=v(25),E.exports=h}),(function(E,D,v){function h(){this.listeners=[]}var n=h.prototype;n.addListener=function(e,i){this.listeners.push({event:e,callback:i})},n.removeListener=function(e,i){for(var a=this.listeners.length;a>=0;a--){var u=this.listeners[a];u.event===e&&u.callback===i&&this.listeners.splice(a,1)}},n.emit=function(e,i){for(var a=0;a<this.listeners.length;a++){var u=this.listeners[a];e===u.event&&u.callback(i)}},E.exports=h})])})})(P.__module)),P.__module.exports}exports.__require=k;
|
|
2
2
|
//# sourceMappingURL=layout-base.cjs.js.map
|