@hpcc-js/graph 3.1.1 → 3.2.0
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/assets/dagre-D0bY8RPD.js.map +1 -0
- package/dist/assets/graphviz-CMhlTALo.js.map +1 -0
- package/dist/index.js +9822 -191
- package/dist/index.js.map +1 -7
- package/dist/index.umd.cjs +8 -0
- package/dist/index.umd.cjs.map +1 -0
- package/package.json +20 -16
- package/src/GraphData.ts +1 -1
- package/src/GraphLayouts.ts +1 -1
- package/src/graph2/layouts/dagreWorker.ts +8 -48
- package/src/graph2/layouts/forceDirectedWorker.ts +7 -43
- package/src/graph2/layouts/graphvizWorker.ts +13 -77
- package/src/graph2/layouts/workers/dagre.ts +46 -0
- package/src/graph2/layouts/workers/dagreOptions.ts +35 -0
- package/src/graph2/layouts/workers/forceDirected.ts +38 -0
- package/src/graph2/layouts/workers/forceDirectedOptions.ts +30 -0
- package/src/graph2/layouts/workers/graphviz.ts +225 -0
- package/src/graph2/layouts/workers/graphvizOptions.ts +70 -0
- package/types/GraphData.d.ts +1 -1
- package/types/graph2/graphT.d.ts +1 -1
- package/types/graph2/layouts/dagreWorker.d.ts +3 -31
- package/types/graph2/layouts/forceDirectedWorker.d.ts +3 -28
- package/types/graph2/layouts/graphvizWorker.d.ts +3 -52
- package/types/graph2/layouts/workers/dagreOptions.d.ts +30 -0
- package/types/graph2/layouts/workers/forceDirectedOptions.d.ts +27 -0
- package/types/graph2/layouts/workers/graphvizOptions.d.ts +51 -0
package/package.json
CHANGED
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hpcc-js/graph",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.2.0",
|
|
4
4
|
"description": "hpcc-js - Viz Graph",
|
|
5
5
|
"type": "module",
|
|
6
|
+
"main": "./dist/index.umd.cjs",
|
|
7
|
+
"module": "./dist/index.js",
|
|
6
8
|
"exports": {
|
|
7
9
|
".": {
|
|
8
10
|
"types": "./types/index.d.ts",
|
|
9
|
-
"
|
|
11
|
+
"import": "./dist/index.js",
|
|
12
|
+
"require": "./dist/index.umd.cjs"
|
|
10
13
|
},
|
|
11
14
|
"./dist/*": "./dist/*"
|
|
12
15
|
},
|
|
13
|
-
"
|
|
14
|
-
"browser": "./dist/index.js",
|
|
16
|
+
"browser": "./dist/index.umd.cjs",
|
|
15
17
|
"types": "./types/index.d.ts",
|
|
16
18
|
"files": [
|
|
17
19
|
"dist/*",
|
|
@@ -19,9 +21,10 @@
|
|
|
19
21
|
"types/*"
|
|
20
22
|
],
|
|
21
23
|
"scripts": {
|
|
22
|
-
"clean": "rimraf --glob lib* types dist *.tsbuildinfo .turbo",
|
|
23
|
-
"bundle": "
|
|
24
|
-
"bundle-
|
|
24
|
+
"clean": "rimraf --glob lib* types dist *.tsbuildinfo .turbo ./workers/dist ./workers/lib-es6 ./workers/types",
|
|
25
|
+
"bundle": "vite build",
|
|
26
|
+
"bundle-workers": "vite build -c ./workers/vite.config.ts",
|
|
27
|
+
"bundle-watch": "vite --port 5509",
|
|
25
28
|
"gen-types": "tsc --project tsconfig.json",
|
|
26
29
|
"gen-types-watch": "npm run gen-types -- --watch",
|
|
27
30
|
"build": "run-p gen-types bundle",
|
|
@@ -35,24 +38,25 @@
|
|
|
35
38
|
"update-major": "npx --yes npm-check-updates -u"
|
|
36
39
|
},
|
|
37
40
|
"dependencies": {
|
|
38
|
-
"@hpcc-js/api": "^3.
|
|
39
|
-
"@hpcc-js/common": "^3.
|
|
40
|
-
"@hpcc-js/html": "^3.
|
|
41
|
-
"@hpcc-js/react": "^3.
|
|
42
|
-
"@hpcc-js/util": "^3.
|
|
41
|
+
"@hpcc-js/api": "^3.3.0",
|
|
42
|
+
"@hpcc-js/common": "^3.3.0",
|
|
43
|
+
"@hpcc-js/html": "^3.2.0",
|
|
44
|
+
"@hpcc-js/react": "^3.2.0",
|
|
45
|
+
"@hpcc-js/util": "^3.3.0"
|
|
43
46
|
},
|
|
44
47
|
"devDependencies": {
|
|
45
|
-
"@
|
|
46
|
-
"@hpcc-js/esbuild-plugins": "^1.3.0",
|
|
48
|
+
"@hpcc-js/esbuild-plugins": "^1.4.0",
|
|
47
49
|
"@hpcc-js/wasm-graphviz": "1.6.1",
|
|
48
50
|
"@types/d3-transition": "1.3.6",
|
|
51
|
+
"@types/dagre": "0.7.52",
|
|
49
52
|
"d3-force": "^1",
|
|
50
53
|
"d3-geo": "^1",
|
|
51
54
|
"d3-interpolate-path": "2.3.0",
|
|
52
55
|
"d3-sankey": "^0",
|
|
53
56
|
"d3-shape": "^1",
|
|
54
57
|
"d3-tile": "^1",
|
|
55
|
-
"d3-transition": "^1"
|
|
58
|
+
"d3-transition": "^1",
|
|
59
|
+
"dagre": "0.8.5"
|
|
56
60
|
},
|
|
57
61
|
"repository": {
|
|
58
62
|
"type": "git",
|
|
@@ -65,5 +69,5 @@
|
|
|
65
69
|
"url": "https://github.com/hpcc-systems/Visualization/issues"
|
|
66
70
|
},
|
|
67
71
|
"homepage": "https://github.com/hpcc-systems/Visualization",
|
|
68
|
-
"gitHead": "
|
|
72
|
+
"gitHead": "145a4d4c8189c70f08e9804e63959d6dd398bd9f"
|
|
69
73
|
}
|
package/src/GraphData.ts
CHANGED
package/src/GraphLayouts.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { forceCenter as d3ForceCenter, forceLink as d3ForceLink, forceManyBody as d3ForceManyBody, forceSimulation as d3ForceSimulation } from "d3-force";
|
|
2
|
-
import { GraphLabel, graphlib, layout } from "
|
|
2
|
+
import { GraphLabel, graphlib, layout } from "dagre";
|
|
3
3
|
import { GraphData } from "./GraphData.ts";
|
|
4
4
|
|
|
5
5
|
interface Pos {
|
|
@@ -1,59 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
export interface Node {
|
|
7
|
-
id: string;
|
|
8
|
-
text: string;
|
|
9
|
-
}
|
|
1
|
+
import { Data, type Hierarchy, type Options } from "./workers/dagreOptions.ts";
|
|
2
|
+
// @ts-ignore
|
|
3
|
+
import DagreWorker from "./workers/dagre.ts?worker&inline";
|
|
10
4
|
|
|
11
|
-
export
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export interface Hierarchy {
|
|
18
|
-
parent: string;
|
|
19
|
-
child: string;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export interface Data {
|
|
23
|
-
subgraphs: Subgraph[];
|
|
24
|
-
nodes: Node[];
|
|
25
|
-
links: Link[];
|
|
26
|
-
hierarchy: Hierarchy[];
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export interface Options {
|
|
30
|
-
rankdir: "TB" | "BT" | "LR" | "RL";
|
|
31
|
-
nodesep: number;
|
|
32
|
-
edgesep: number;
|
|
33
|
-
ranksep: number;
|
|
34
|
-
digraph: boolean;
|
|
35
|
-
}
|
|
5
|
+
export {
|
|
6
|
+
type Hierarchy,
|
|
7
|
+
type Options
|
|
8
|
+
};
|
|
36
9
|
|
|
37
10
|
export function dagre(data: Data, options: Options) {
|
|
38
11
|
|
|
39
|
-
const workerCode = `!function(){"use strict";var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function t(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var n={exports:{}};n.exports=function(){function e(n,r,o){function i(s,u){if(!r[s]){if(!n[s]){if(!u&&t)return t(s);if(a)return a(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var f=r[s]={exports:{}};n[s][0].call(f.exports,(function(e){return i(n[s][1][e]||e)}),f,f.exports,e,n,r,o)}return r[s].exports}for(var a=t,s=0;s<o.length;s++)i(o[s]);return i}return e}()({1:[function(e,t,n){t.exports={graphlib:e("./lib/graphlib"),layout:e("./lib/layout"),debug:e("./lib/debug"),util:{time:e("./lib/util").time,notime:e("./lib/util").notime},version:e("./lib/version")}},{"./lib/debug":6,"./lib/graphlib":7,"./lib/layout":9,"./lib/util":29,"./lib/version":30}],2:[function(e,t,n){var r=e("./lodash"),o=e("./greedy-fas");function i(e){var t="greedy"===e.graph().acyclicer?o(e,n(e)):a(e);function n(e){return function(t){return e.edge(t).weight}}r.forEach(t,(function(t){var n=e.edge(t);e.removeEdge(t),n.forwardName=t.name,n.reversed=!0,e.setEdge(t.w,t.v,n,r.uniqueId("rev"))}))}function a(e){var t=[],n={},o={};function i(a){r.has(o,a)||(o[a]=!0,n[a]=!0,r.forEach(e.outEdges(a),(function(e){r.has(n,e.w)?t.push(e):i(e.w)})),delete n[a])}return r.forEach(e.nodes(),i),t}function s(e){r.forEach(e.edges(),(function(t){var n=e.edge(t);if(n.reversed){e.removeEdge(t);var r=n.forwardName;delete n.reversed,delete n.forwardName,e.setEdge(t.w,t.v,n,r)}}))}t.exports={run:i,undo:s}},{"./greedy-fas":8,"./lodash":10}],3:[function(e,t,n){var r=e("./lodash"),o=e("./util");function i(e){function t(n){var o=e.children(n),i=e.node(n);if(o.length&&r.forEach(o,t),r.has(i,"minRank")){i.borderLeft=[],i.borderRight=[];for(var s=i.minRank,u=i.maxRank+1;s<u;++s)a(e,"borderLeft","_bl",n,i,s),a(e,"borderRight","_br",n,i,s)}}r.forEach(e.children(),t)}function a(e,t,n,r,i,a){var s={width:0,height:0,rank:a,borderType:t},u=i[t][a-1],c=o.addDummyNode(e,"border",s,n);i[t][a]=c,e.setParent(c,r),u&&e.setEdge(u,c,{weight:1})}t.exports=i},{"./lodash":10,"./util":29}],4:[function(e,t,n){var r=e("./lodash");function o(e){var t=e.graph().rankdir.toLowerCase();"lr"!==t&&"rl"!==t||a(e)}function i(e){var t=e.graph().rankdir.toLowerCase();"bt"!==t&&"rl"!==t||u(e),"lr"!==t&&"rl"!==t||(f(e),a(e))}function a(e){r.forEach(e.nodes(),(function(t){s(e.node(t))})),r.forEach(e.edges(),(function(t){s(e.edge(t))}))}function s(e){var t=e.width;e.width=e.height,e.height=t}function u(e){r.forEach(e.nodes(),(function(t){c(e.node(t))})),r.forEach(e.edges(),(function(t){var n=e.edge(t);r.forEach(n.points,c),r.has(n,"y")&&c(n)}))}function c(e){e.y=-e.y}function f(e){r.forEach(e.nodes(),(function(t){d(e.node(t))})),r.forEach(e.edges(),(function(t){var n=e.edge(t);r.forEach(n.points,d),r.has(n,"x")&&d(n)}))}function d(e){var t=e.x;e.x=e.y,e.y=t}t.exports={adjust:o,undo:i}},{"./lodash":10}],5:[function(e,t,n){function r(){var e={};e._next=e._prev=e,this._sentinel=e}function o(e){e._prev._next=e._next,e._next._prev=e._prev,delete e._next,delete e._prev}function i(e,t){if("_next"!==e&&"_prev"!==e)return t}t.exports=r,r.prototype.dequeue=function(){var e=this._sentinel,t=e._prev;if(t!==e)return o(t),t},r.prototype.enqueue=function(e){var t=this._sentinel;e._prev&&e._next&&o(e),e._next=t._next,t._next._prev=e,t._next=e,e._prev=t},r.prototype.toString=function(){for(var e=[],t=this._sentinel,n=t._prev;n!==t;)e.push(JSON.stringify(n,i)),n=n._prev;return"["+e.join(", ")+"]"}},{}],6:[function(e,t,n){var r=e("./lodash"),o=e("./util"),i=e("./graphlib").Graph;function a(e){var t=o.buildLayerMatrix(e),n=new i({compound:!0,multigraph:!0}).setGraph({});return r.forEach(e.nodes(),(function(t){n.setNode(t,{label:t}),n.setParent(t,"layer"+e.node(t).rank)})),r.forEach(e.edges(),(function(e){n.setEdge(e.v,e.w,{},e.name)})),r.forEach(t,(function(e,t){var o="layer"+t;n.setNode(o,{rank:"same"}),r.reduce(e,(function(e,t){return n.setEdge(e,t,{style:"invis"}),t}))})),n}t.exports={debugOrdering:a}},{"./graphlib":7,"./lodash":10,"./util":29}],7:[function(e,t,n){var r;if("function"==typeof e)try{r=e("graphlib")}catch(e){}r||(r=window.graphlib),t.exports=r},{graphlib:31}],8:[function(e,t,n){var r=e("./lodash"),o=e("./graphlib").Graph,i=e("./data/list");t.exports=s;var a=r.constant(1);function s(e,t){if(e.nodeCount()<=1)return[];var n=f(e,t||a),o=u(n.graph,n.buckets,n.zeroIdx);return r.flatten(r.map(o,(function(t){return e.outEdges(t.v,t.w)})),!0)}function u(e,t,n){for(var r,o=[],i=t[t.length-1],a=t[0];e.nodeCount();){for(;r=a.dequeue();)c(e,t,n,r);for(;r=i.dequeue();)c(e,t,n,r);if(e.nodeCount())for(var s=t.length-2;s>0;--s)if(r=t[s].dequeue()){o=o.concat(c(e,t,n,r,!0));break}}return o}function c(e,t,n,o,i){var a=i?[]:void 0;return r.forEach(e.inEdges(o.v),(function(r){var o=e.edge(r),s=e.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,d(t,n,s)})),r.forEach(e.outEdges(o.v),(function(r){var o=e.edge(r),i=r.w,a=e.node(i);a.in-=o,d(t,n,a)})),e.removeNode(o.v),a}function f(e,t){var n=new o,a=0,s=0;r.forEach(e.nodes(),(function(e){n.setNode(e,{v:e,in:0,out:0})})),r.forEach(e.edges(),(function(e){var r=n.edge(e.v,e.w)||0,o=t(e),i=r+o;n.setEdge(e.v,e.w,i),s=Math.max(s,n.node(e.v).out+=o),a=Math.max(a,n.node(e.w).in+=o)}));var u=r.range(s+a+3).map((function(){return new i})),c=a+1;return r.forEach(n.nodes(),(function(e){d(u,c,n.node(e))})),{graph:n,buckets:u,zeroIdx:c}}function d(e,t,n){n.out?n.in?e[n.out-n.in+t].enqueue(n):e[e.length-1].enqueue(n):e[0].enqueue(n)}},{"./data/list":5,"./graphlib":7,"./lodash":10}],9:[function(e,t,n){var r=e("./lodash"),o=e("./acyclic"),i=e("./normalize"),a=e("./rank"),s=e("./util").normalizeRanks,u=e("./parent-dummy-chains"),c=e("./util").removeEmptyRanks,f=e("./nesting-graph"),d=e("./add-border-segments"),h=e("./coordinate-system"),l=e("./order"),p=e("./position"),v=e("./util"),_=e("./graphlib").Graph;function y(e,t){var n=t&&t.debugTiming?v.time:v.notime;n("layout",(function(){var t=n(" buildLayoutGraph",(function(){return I(e)}));n(" runLayout",(function(){g(t,n)})),n(" updateInputGraph",(function(){b(e,t)}))}))}function g(e,t){t(" makeSpaceForEdgeLabels",(function(){S(e)})),t(" removeSelfEdges",(function(){B(e)})),t(" acyclic",(function(){o.run(e)})),t(" nestingGraph.run",(function(){f.run(e)})),t(" rank",(function(){a(v.asNonCompoundGraph(e))})),t(" injectEdgeLabelProxies",(function(){C(e)})),t(" removeEmptyRanks",(function(){c(e)})),t(" nestingGraph.cleanup",(function(){f.cleanup(e)})),t(" normalizeRanks",(function(){s(e)})),t(" assignRankMinMax",(function(){N(e)})),t(" removeEdgeLabelProxies",(function(){T(e)})),t(" normalize.run",(function(){i.run(e)})),t(" parentDummyChains",(function(){u(e)})),t(" addBorderSegments",(function(){d(e)})),t(" order",(function(){l(e)})),t(" insertSelfEdges",(function(){G(e)})),t(" adjustCoordinateSystem",(function(){h.adjust(e)})),t(" position",(function(){p(e)})),t(" positionSelfEdges",(function(){R(e)})),t(" removeBorderNodes",(function(){D(e)})),t(" normalize.undo",(function(){i.undo(e)})),t(" fixupEdgeLabelCoords",(function(){P(e)})),t(" undoCoordinateSystem",(function(){h.undo(e)})),t(" translateGraph",(function(){M(e)})),t(" assignNodeIntersects",(function(){L(e)})),t(" reversePoints",(function(){F(e)})),t(" acyclic.undo",(function(){o.undo(e)}))}function b(e,t){r.forEach(e.nodes(),(function(n){var r=e.node(n),o=t.node(n);r&&(r.x=o.x,r.y=o.y,t.children(n).length&&(r.width=o.width,r.height=o.height))})),r.forEach(e.edges(),(function(n){var o=e.edge(n),i=t.edge(n);o.points=i.points,r.has(i,"x")&&(o.x=i.x,o.y=i.y)})),e.graph().width=t.graph().width,e.graph().height=t.graph().height}t.exports=y;var m=["nodesep","edgesep","ranksep","marginx","marginy"],x={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},w=["acyclicer","ranker","rankdir","align"],E=["width","height"],j={width:0,height:0},k=["minlen","weight","width","height","labeloffset"],A={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},O=["labelpos"];function I(e){var t=new _({multigraph:!0,compound:!0}),n=z(e.graph());return t.setGraph(r.merge({},x,U(n,m),r.pick(n,w))),r.forEach(e.nodes(),(function(n){var o=z(e.node(n));t.setNode(n,r.defaults(U(o,E),j)),t.setParent(n,e.parent(n))})),r.forEach(e.edges(),(function(n){var o=z(e.edge(n));t.setEdge(n,r.merge({},A,U(o,k),r.pick(o,O)))})),t}function S(e){var t=e.graph();t.ranksep/=2,r.forEach(e.edges(),(function(n){var r=e.edge(n);r.minlen*=2,"c"!==r.labelpos.toLowerCase()&&("TB"===t.rankdir||"BT"===t.rankdir?r.width+=r.labeloffset:r.height+=r.labeloffset)}))}function C(e){r.forEach(e.edges(),(function(t){var n=e.edge(t);if(n.width&&n.height){var r=e.node(t.v),o={rank:(e.node(t.w).rank-r.rank)/2+r.rank,e:t};v.addDummyNode(e,"edge-proxy",o,"_ep")}}))}function N(e){var t=0;r.forEach(e.nodes(),(function(n){var o=e.node(n);o.borderTop&&(o.minRank=e.node(o.borderTop).rank,o.maxRank=e.node(o.borderBottom).rank,t=r.max(t,o.maxRank))})),e.graph().maxRank=t}function T(e){r.forEach(e.nodes(),(function(t){var n=e.node(t);"edge-proxy"===n.dummy&&(e.edge(n.e).labelRank=n.rank,e.removeNode(t))}))}function M(e){var t=Number.POSITIVE_INFINITY,n=0,o=Number.POSITIVE_INFINITY,i=0,a=e.graph(),s=a.marginx||0,u=a.marginy||0;function c(e){var r=e.x,a=e.y,s=e.width,u=e.height;t=Math.min(t,r-s/2),n=Math.max(n,r+s/2),o=Math.min(o,a-u/2),i=Math.max(i,a+u/2)}r.forEach(e.nodes(),(function(t){c(e.node(t))})),r.forEach(e.edges(),(function(t){var n=e.edge(t);r.has(n,"x")&&c(n)})),t-=s,o-=u,r.forEach(e.nodes(),(function(n){var r=e.node(n);r.x-=t,r.y-=o})),r.forEach(e.edges(),(function(n){var i=e.edge(n);r.forEach(i.points,(function(e){e.x-=t,e.y-=o})),r.has(i,"x")&&(i.x-=t),r.has(i,"y")&&(i.y-=o)})),a.width=n-t+s,a.height=i-o+u}function L(e){r.forEach(e.edges(),(function(t){var n,r,o=e.edge(t),i=e.node(t.v),a=e.node(t.w);o.points?(n=o.points[0],r=o.points[o.points.length-1]):(o.points=[],n=a,r=i),o.points.unshift(v.intersectRect(i,n)),o.points.push(v.intersectRect(a,r))}))}function P(e){r.forEach(e.edges(),(function(t){var n=e.edge(t);if(r.has(n,"x"))switch("l"!==n.labelpos&&"r"!==n.labelpos||(n.width-=n.labeloffset),n.labelpos){case"l":n.x-=n.width/2+n.labeloffset;break;case"r":n.x+=n.width/2+n.labeloffset}}))}function F(e){r.forEach(e.edges(),(function(t){var n=e.edge(t);n.reversed&&n.points.reverse()}))}function D(e){r.forEach(e.nodes(),(function(t){if(e.children(t).length){var n=e.node(t),o=e.node(n.borderTop),i=e.node(n.borderBottom),a=e.node(r.last(n.borderLeft)),s=e.node(r.last(n.borderRight));n.width=Math.abs(s.x-a.x),n.height=Math.abs(i.y-o.y),n.x=a.x+n.width/2,n.y=o.y+n.height/2}})),r.forEach(e.nodes(),(function(t){"border"===e.node(t).dummy&&e.removeNode(t)}))}function B(e){r.forEach(e.edges(),(function(t){if(t.v===t.w){var n=e.node(t.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e:t,label:e.edge(t)}),e.removeEdge(t)}}))}function G(e){var t=v.buildLayerMatrix(e);r.forEach(t,(function(t){var n=0;r.forEach(t,(function(t,o){var i=e.node(t);i.order=o+n,r.forEach(i.selfEdges,(function(t){v.addDummyNode(e,"selfedge",{width:t.label.width,height:t.label.height,rank:i.rank,order:o+ ++n,e:t.e,label:t.label},"_se")})),delete i.selfEdges}))}))}function R(e){r.forEach(e.nodes(),(function(t){var n=e.node(t);if("selfedge"===n.dummy){var r=e.node(n.e.v),o=r.x+r.width/2,i=r.y,a=n.x-o,s=r.height/2;e.setEdge(n.e,n.label),e.removeNode(t),n.label.points=[{x:o+2*a/3,y:i-s},{x:o+5*a/6,y:i-s},{x:o+a,y:i},{x:o+5*a/6,y:i+s},{x:o+2*a/3,y:i+s}],n.label.x=n.x,n.label.y=n.y}}))}function U(e,t){return r.mapValues(r.pick(e,t),Number)}function z(e){var t={};return r.forEach(e,(function(e,n){t[n.toLowerCase()]=e})),t}},{"./acyclic":2,"./add-border-segments":3,"./coordinate-system":4,"./graphlib":7,"./lodash":10,"./nesting-graph":11,"./normalize":12,"./order":17,"./parent-dummy-chains":22,"./position":24,"./rank":26,"./util":29}],10:[function(e,t,n){var r;if("function"==typeof e)try{r={cloneDeep:e("lodash/cloneDeep"),constant:e("lodash/constant"),defaults:e("lodash/defaults"),each:e("lodash/each"),filter:e("lodash/filter"),find:e("lodash/find"),flatten:e("lodash/flatten"),forEach:e("lodash/forEach"),forIn:e("lodash/forIn"),has:e("lodash/has"),isUndefined:e("lodash/isUndefined"),last:e("lodash/last"),map:e("lodash/map"),mapValues:e("lodash/mapValues"),max:e("lodash/max"),merge:e("lodash/merge"),min:e("lodash/min"),minBy:e("lodash/minBy"),now:e("lodash/now"),pick:e("lodash/pick"),range:e("lodash/range"),reduce:e("lodash/reduce"),sortBy:e("lodash/sortBy"),uniqueId:e("lodash/uniqueId"),values:e("lodash/values"),zipObject:e("lodash/zipObject")}}catch(e){}r||(r=window._),t.exports=r},{"lodash/cloneDeep":227,"lodash/constant":228,"lodash/defaults":229,"lodash/each":230,"lodash/filter":232,"lodash/find":233,"lodash/flatten":235,"lodash/forEach":236,"lodash/forIn":237,"lodash/has":239,"lodash/isUndefined":258,"lodash/last":261,"lodash/map":262,"lodash/mapValues":263,"lodash/max":264,"lodash/merge":266,"lodash/min":267,"lodash/minBy":268,"lodash/now":270,"lodash/pick":271,"lodash/range":273,"lodash/reduce":274,"lodash/sortBy":276,"lodash/uniqueId":286,"lodash/values":287,"lodash/zipObject":288}],11:[function(e,t,n){var r=e("./lodash"),o=e("./util");function i(e){var t=o.addDummyNode(e,"root",{},"_root"),n=s(e),i=r.max(r.values(n))-1,c=2*i+1;e.graph().nestingRoot=t,r.forEach(e.edges(),(function(t){e.edge(t).minlen*=c}));var f=u(e)+1;r.forEach(e.children(),(function(r){a(e,t,c,f,i,n,r)})),e.graph().nodeRankFactor=c}function a(e,t,n,i,s,u,c){var f=e.children(c);if(f.length){var d=o.addBorderNode(e,"_bt"),h=o.addBorderNode(e,"_bb"),l=e.node(c);e.setParent(d,c),l.borderTop=d,e.setParent(h,c),l.borderBottom=h,r.forEach(f,(function(r){a(e,t,n,i,s,u,r);var o=e.node(r),f=o.borderTop?o.borderTop:r,l=o.borderBottom?o.borderBottom:r,p=o.borderTop?i:2*i,v=f!==l?1:s-u[c]+1;e.setEdge(d,f,{weight:p,minlen:v,nestingEdge:!0}),e.setEdge(l,h,{weight:p,minlen:v,nestingEdge:!0})})),e.parent(c)||e.setEdge(t,d,{weight:0,minlen:s+u[c]})}else c!==t&&e.setEdge(t,c,{weight:0,minlen:n})}function s(e){var t={};function n(o,i){var a=e.children(o);a&&a.length&&r.forEach(a,(function(e){n(e,i+1)})),t[o]=i}return r.forEach(e.children(),(function(e){n(e,1)})),t}function u(e){return r.reduce(e.edges(),(function(t,n){return t+e.edge(n).weight}),0)}function c(e){var t=e.graph();e.removeNode(t.nestingRoot),delete t.nestingRoot,r.forEach(e.edges(),(function(t){e.edge(t).nestingEdge&&e.removeEdge(t)}))}t.exports={run:i,cleanup:c}},{"./lodash":10,"./util":29}],12:[function(e,t,n){var r=e("./lodash"),o=e("./util");function i(e){e.graph().dummyChains=[],r.forEach(e.edges(),(function(t){a(e,t)}))}function a(e,t){var n=t.v,r=e.node(n).rank,i=t.w,a=e.node(i).rank,s=t.name,u=e.edge(t),c=u.labelRank;if(a!==r+1){var f,d,h;for(e.removeEdge(t),h=0,++r;r<a;++h,++r)u.points=[],d={width:0,height:0,edgeLabel:u,edgeObj:t,rank:r},f=o.addDummyNode(e,"edge",d,"_d"),r===c&&(d.width=u.width,d.height=u.height,d.dummy="edge-label",d.labelpos=u.labelpos),e.setEdge(n,f,{weight:u.weight},s),0===h&&e.graph().dummyChains.push(f),n=f;e.setEdge(n,i,{weight:u.weight},s)}}function s(e){r.forEach(e.graph().dummyChains,(function(t){var n,r=e.node(t),o=r.edgeLabel;for(e.setEdge(r.edgeObj,o);r.dummy;)n=e.successors(t)[0],e.removeNode(t),o.points.push({x:r.x,y:r.y}),"edge-label"===r.dummy&&(o.x=r.x,o.y=r.y,o.width=r.width,o.height=r.height),t=n,r=e.node(t)}))}t.exports={run:i,undo:s}},{"./lodash":10,"./util":29}],13:[function(e,t,n){var r=e("../lodash");function o(e,t,n){var o,i={};r.forEach(n,(function(n){for(var r,a,s=e.parent(n);s;){if((r=e.parent(s))?(a=i[r],i[r]=s):(a=o,o=s),a&&a!==s)return void t.setEdge(a,s);s=r}}))}t.exports=o},{"../lodash":10}],14:[function(e,t,n){var r=e("../lodash");function o(e,t){return r.map(t,(function(t){var n=e.inEdges(t);if(n.length){var o=r.reduce(n,(function(t,n){var r=e.edge(n),o=e.node(n.v);return{sum:t.sum+r.weight*o.order,weight:t.weight+r.weight}}),{sum:0,weight:0});return{v:t,barycenter:o.sum/o.weight,weight:o.weight}}return{v:t}}))}t.exports=o},{"../lodash":10}],15:[function(e,t,n){var r=e("../lodash"),o=e("../graphlib").Graph;function i(e,t,n){var i=a(e),s=new o({compound:!0}).setGraph({root:i}).setDefaultNodeLabel((function(t){return e.node(t)}));return r.forEach(e.nodes(),(function(o){var a=e.node(o),u=e.parent(o);(a.rank===t||a.minRank<=t&&t<=a.maxRank)&&(s.setNode(o),s.setParent(o,u||i),r.forEach(e[n](o),(function(t){var n=t.v===o?t.w:t.v,i=s.edge(n,o),a=r.isUndefined(i)?0:i.weight;s.setEdge(n,o,{weight:e.edge(t).weight+a})})),r.has(a,"minRank")&&s.setNode(o,{borderLeft:a.borderLeft[t],borderRight:a.borderRight[t]}))})),s}function a(e){for(var t;e.hasNode(t=r.uniqueId("_root")););return t}t.exports=i},{"../graphlib":7,"../lodash":10}],16:[function(e,t,n){var r=e("../lodash");function o(e,t){for(var n=0,r=1;r<t.length;++r)n+=i(e,t[r-1],t[r]);return n}function i(e,t,n){for(var o=r.zipObject(n,r.map(n,(function(e,t){return t}))),i=r.flatten(r.map(t,(function(t){return r.sortBy(r.map(e.outEdges(t),(function(t){return{pos:o[t.w],weight:e.edge(t).weight}})),"pos")})),!0),a=1;a<n.length;)a<<=1;var s=2*a-1;a-=1;var u=r.map(new Array(s),(function(){return 0})),c=0;return r.forEach(i.forEach((function(e){var t=e.pos+a;u[t]+=e.weight;for(var n=0;t>0;)t%2&&(n+=u[t+1]),u[t=t-1>>1]+=e.weight;c+=e.weight*n}))),c}t.exports=o},{"../lodash":10}],17:[function(e,t,n){var r=e("../lodash"),o=e("./init-order"),i=e("./cross-count"),a=e("./sort-subgraph"),s=e("./build-layer-graph"),u=e("./add-subgraph-constraints"),c=e("../graphlib").Graph,f=e("../util");function d(e){var t=f.maxRank(e),n=h(e,r.range(1,t+1),"inEdges"),a=h(e,r.range(t-1,-1,-1),"outEdges"),s=o(e);p(e,s);for(var u,c=Number.POSITIVE_INFINITY,d=0,v=0;v<4;++d,++v){l(d%2?n:a,d%4>=2),s=f.buildLayerMatrix(e);var _=i(e,s);_<c&&(v=0,u=r.cloneDeep(s),c=_)}p(e,u)}function h(e,t,n){return r.map(t,(function(t){return s(e,t,n)}))}function l(e,t){var n=new c;r.forEach(e,(function(e){var o=e.graph().root,i=a(e,o,n,t);r.forEach(i.vs,(function(t,n){e.node(t).order=n})),u(e,n,i.vs)}))}function p(e,t){r.forEach(t,(function(t){r.forEach(t,(function(t,n){e.node(t).order=n}))}))}t.exports=d},{"../graphlib":7,"../lodash":10,"../util":29,"./add-subgraph-constraints":13,"./build-layer-graph":15,"./cross-count":16,"./init-order":18,"./sort-subgraph":20}],18:[function(e,t,n){var r=e("../lodash");function o(e){var t={},n=r.filter(e.nodes(),(function(t){return!e.children(t).length})),o=r.max(r.map(n,(function(t){return e.node(t).rank}))),i=r.map(r.range(o+1),(function(){return[]}));function a(n){if(!r.has(t,n)){t[n]=!0;var o=e.node(n);i[o.rank].push(n),r.forEach(e.successors(n),a)}}var s=r.sortBy(n,(function(t){return e.node(t).rank}));return r.forEach(s,a),i}t.exports=o},{"../lodash":10}],19:[function(e,t,n){var r=e("../lodash");function o(e,t){var n={};return r.forEach(e,(function(e,t){var o=n[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:t};r.isUndefined(e.barycenter)||(o.barycenter=e.barycenter,o.weight=e.weight)})),r.forEach(t.edges(),(function(e){var t=n[e.v],o=n[e.w];r.isUndefined(t)||r.isUndefined(o)||(o.indegree++,t.out.push(n[e.w]))})),i(r.filter(n,(function(e){return!e.indegree})))}function i(e){var t=[];function n(e){return function(t){t.merged||(r.isUndefined(t.barycenter)||r.isUndefined(e.barycenter)||t.barycenter>=e.barycenter)&&a(e,t)}}function o(t){return function(n){n.in.push(t),0==--n.indegree&&e.push(n)}}for(;e.length;){var i=e.pop();t.push(i),r.forEach(i.in.reverse(),n(i)),r.forEach(i.out,o(i))}return r.map(r.filter(t,(function(e){return!e.merged})),(function(e){return r.pick(e,["vs","i","barycenter","weight"])}))}function a(e,t){var n=0,r=0;e.weight&&(n+=e.barycenter*e.weight,r+=e.weight),t.weight&&(n+=t.barycenter*t.weight,r+=t.weight),e.vs=t.vs.concat(e.vs),e.barycenter=n/r,e.weight=r,e.i=Math.min(t.i,e.i),t.merged=!0}t.exports=o},{"../lodash":10}],20:[function(e,t,n){var r=e("../lodash"),o=e("./barycenter"),i=e("./resolve-conflicts"),a=e("./sort");function s(e,t,n,f){var d=e.children(t),h=e.node(t),l=h?h.borderLeft:void 0,p=h?h.borderRight:void 0,v={};l&&(d=r.filter(d,(function(e){return e!==l&&e!==p})));var _=o(e,d);r.forEach(_,(function(t){if(e.children(t.v).length){var o=s(e,t.v,n,f);v[t.v]=o,r.has(o,"barycenter")&&c(t,o)}}));var y=i(_,n);u(y,v);var g=a(y,f);if(l&&(g.vs=r.flatten([l,g.vs,p],!0),e.predecessors(l).length)){var b=e.node(e.predecessors(l)[0]),m=e.node(e.predecessors(p)[0]);r.has(g,"barycenter")||(g.barycenter=0,g.weight=0),g.barycenter=(g.barycenter*g.weight+b.order+m.order)/(g.weight+2),g.weight+=2}return g}function u(e,t){r.forEach(e,(function(e){e.vs=r.flatten(e.vs.map((function(e){return t[e]?t[e].vs:e})),!0)}))}function c(e,t){r.isUndefined(e.barycenter)?(e.barycenter=t.barycenter,e.weight=t.weight):(e.barycenter=(e.barycenter*e.weight+t.barycenter*t.weight)/(e.weight+t.weight),e.weight+=t.weight)}t.exports=s},{"../lodash":10,"./barycenter":14,"./resolve-conflicts":19,"./sort":21}],21:[function(e,t,n){var r=e("../lodash"),o=e("../util");function i(e,t){var n=o.partition(e,(function(e){return r.has(e,"barycenter")})),i=n.lhs,u=r.sortBy(n.rhs,(function(e){return-e.i})),c=[],f=0,d=0,h=0;i.sort(s(!!t)),h=a(c,u,h),r.forEach(i,(function(e){h+=e.vs.length,c.push(e.vs),f+=e.barycenter*e.weight,d+=e.weight,h=a(c,u,h)}));var l={vs:r.flatten(c,!0)};return d&&(l.barycenter=f/d,l.weight=d),l}function a(e,t,n){for(var o;t.length&&(o=r.last(t)).i<=n;)t.pop(),e.push(o.vs),n++;return n}function s(e){return function(t,n){return t.barycenter<n.barycenter?-1:t.barycenter>n.barycenter?1:e?n.i-t.i:t.i-n.i}}t.exports=i},{"../lodash":10,"../util":29}],22:[function(e,t,n){var r=e("./lodash");function o(e){var t=a(e);r.forEach(e.graph().dummyChains,(function(n){for(var r=e.node(n),o=r.edgeObj,a=i(e,t,o.v,o.w),s=a.path,u=a.lca,c=0,f=s[c],d=!0;n!==o.w;){if(r=e.node(n),d){for(;(f=s[c])!==u&&e.node(f).maxRank<r.rank;)c++;f===u&&(d=!1)}if(!d){for(;c<s.length-1&&e.node(f=s[c+1]).minRank<=r.rank;)c++;f=s[c]}e.setParent(n,f),n=e.successors(n)[0]}}))}function i(e,t,n,r){var o,i,a=[],s=[],u=Math.min(t[n].low,t[r].low),c=Math.max(t[n].lim,t[r].lim);o=n;do{o=e.parent(o),a.push(o)}while(o&&(t[o].low>u||c>t[o].lim));for(i=o,o=r;(o=e.parent(o))!==i;)s.push(o);return{path:a.concat(s.reverse()),lca:i}}function a(e){var t={},n=0;function o(i){var a=n;r.forEach(e.children(i),o),t[i]={low:a,lim:n++}}return r.forEach(e.children(),o),t}t.exports=o},{"./lodash":10}],23:[function(e,t,n){var r=e("../lodash"),o=e("../graphlib").Graph,i=e("../util");function a(e,t){var n={};function o(t,o){var i=0,a=0,s=t.length,f=r.last(o);return r.forEach(o,(function(t,d){var h=u(e,t),l=h?e.node(h).order:s;(h||t===f)&&(r.forEach(o.slice(a,d+1),(function(t){r.forEach(e.predecessors(t),(function(r){var o=e.node(r),a=o.order;!(a<i||l<a)||o.dummy&&e.node(t).dummy||c(n,r,t)}))})),a=d+1,i=l)})),o}return r.reduce(t,o),n}function s(e,t){var n={};function o(t,o,i,a,s){var u;r.forEach(r.range(o,i),(function(o){u=t[o],e.node(u).dummy&&r.forEach(e.predecessors(u),(function(t){var r=e.node(t);r.dummy&&(r.order<a||r.order>s)&&c(n,t,u)}))}))}function i(t,n){var i,a=-1,s=0;return r.forEach(n,(function(r,u){if("border"===e.node(r).dummy){var c=e.predecessors(r);c.length&&(i=e.node(c[0]).order,o(n,s,u,a,i),s=u,a=i)}o(n,s,n.length,i,t.length)})),n}return r.reduce(t,i),n}function u(e,t){if(e.node(t).dummy)return r.find(e.predecessors(t),(function(t){return e.node(t).dummy}))}function c(e,t,n){if(t>n){var r=t;t=n,n=r}var o=e[t];o||(e[t]=o={}),o[n]=!0}function f(e,t,n){if(t>n){var o=t;t=n,n=o}return r.has(e[t],n)}function d(e,t,n,o){var i={},a={},s={};return r.forEach(t,(function(e){r.forEach(e,(function(e,t){i[e]=e,a[e]=e,s[e]=t}))})),r.forEach(t,(function(e){var t=-1;r.forEach(e,(function(e){var u=o(e);if(u.length){u=r.sortBy(u,(function(e){return s[e]}));for(var c=(u.length-1)/2,d=Math.floor(c),h=Math.ceil(c);d<=h;++d){var l=u[d];a[e]===e&&t<s[l]&&!f(n,e,l)&&(a[l]=e,a[e]=i[e]=i[l],t=s[l])}}}))})),{root:i,align:a}}function h(e,t,n,o,i){var a={},s=l(e,t,n,i),u=i?"borderLeft":"borderRight";function c(e,t){for(var n=s.nodes(),r=n.pop(),o={};r;)o[r]?e(r):(o[r]=!0,n.push(r),n=n.concat(t(r))),r=n.pop()}function f(e){a[e]=s.inEdges(e).reduce((function(e,t){return Math.max(e,a[t.v]+s.edge(t))}),0)}function d(t){var n=s.outEdges(t).reduce((function(e,t){return Math.min(e,a[t.w]-s.edge(t))}),Number.POSITIVE_INFINITY),r=e.node(t);n!==Number.POSITIVE_INFINITY&&r.borderType!==u&&(a[t]=Math.max(a[t],n))}return c(f,s.predecessors.bind(s)),c(d,s.successors.bind(s)),r.forEach(o,(function(e){a[e]=a[n[e]]})),a}function l(e,t,n,i){var a=new o,s=e.graph(),u=g(s.nodesep,s.edgesep,i);return r.forEach(t,(function(t){var o;r.forEach(t,(function(t){var r=n[t];if(a.setNode(r),o){var i=n[o],s=a.edge(i,r);a.setEdge(i,r,Math.max(u(e,t,o),s||0))}o=t}))})),a}function p(e,t){return r.minBy(r.values(t),(function(t){var n=Number.NEGATIVE_INFINITY,o=Number.POSITIVE_INFINITY;return r.forIn(t,(function(t,r){var i=b(e,r)/2;n=Math.max(t+i,n),o=Math.min(t-i,o)})),n-o}))}function v(e,t){var n=r.values(t),o=r.min(n),i=r.max(n);r.forEach(["u","d"],(function(n){r.forEach(["l","r"],(function(a){var s,u=n+a,c=e[u];if(c!==t){var f=r.values(c);(s="l"===a?o-r.min(f):i-r.max(f))&&(e[u]=r.mapValues(c,(function(e){return e+s})))}}))}))}function _(e,t){return r.mapValues(e.ul,(function(n,o){if(t)return e[t.toLowerCase()][o];var i=r.sortBy(r.map(e,o));return(i[1]+i[2])/2}))}function y(e){var t,n=i.buildLayerMatrix(e),o=r.merge(a(e,n),s(e,n)),u={};r.forEach(["u","d"],(function(i){t="u"===i?n:r.values(n).reverse(),r.forEach(["l","r"],(function(n){"r"===n&&(t=r.map(t,(function(e){return r.values(e).reverse()})));var a=("u"===i?e.predecessors:e.successors).bind(e),s=d(e,t,o,a),c=h(e,t,s.root,s.align,"r"===n);"r"===n&&(c=r.mapValues(c,(function(e){return-e}))),u[i+n]=c}))}));var c=p(e,u);return v(u,c),_(u,e.graph().align)}function g(e,t,n){return function(o,i,a){var s,u=o.node(i),c=o.node(a),f=0;if(f+=u.width/2,r.has(u,"labelpos"))switch(u.labelpos.toLowerCase()){case"l":s=-u.width/2;break;case"r":s=u.width/2}if(s&&(f+=n?s:-s),s=0,f+=(u.dummy?t:e)/2,f+=(c.dummy?t:e)/2,f+=c.width/2,r.has(c,"labelpos"))switch(c.labelpos.toLowerCase()){case"l":s=c.width/2;break;case"r":s=-c.width/2}return s&&(f+=n?s:-s),s=0,f}}function b(e,t){return e.node(t).width}t.exports={positionX:y,findType1Conflicts:a,findType2Conflicts:s,addConflict:c,hasConflict:f,verticalAlignment:d,horizontalCompaction:h,alignCoordinates:v,findSmallestWidthAlignment:p,balance:_}},{"../graphlib":7,"../lodash":10,"../util":29}],24:[function(e,t,n){var r=e("../lodash"),o=e("../util"),i=e("./bk").positionX;function a(e){s(e=o.asNonCompoundGraph(e)),r.forEach(i(e),(function(t,n){e.node(n).x=t}))}function s(e){var t=o.buildLayerMatrix(e),n=e.graph().ranksep,i=0;r.forEach(t,(function(t){var o=r.max(r.map(t,(function(t){return e.node(t).height})));r.forEach(t,(function(t){e.node(t).y=i+o/2})),i+=o+n}))}t.exports=a},{"../lodash":10,"../util":29,"./bk":23}],25:[function(e,t,n){var r=e("../lodash"),o=e("../graphlib").Graph,i=e("./util").slack;function a(e){var t,n,r=new o({directed:!1}),a=e.nodes()[0],f=e.nodeCount();for(r.setNode(a,{});s(r,e)<f;)t=u(r,e),n=r.hasNode(t.v)?i(e,t):-i(e,t),c(r,e,n);return r}function s(e,t){function n(o){r.forEach(t.nodeEdges(o),(function(r){var a=r.v,s=o===a?r.w:a;e.hasNode(s)||i(t,r)||(e.setNode(s,{}),e.setEdge(o,s,{}),n(s))}))}return r.forEach(e.nodes(),n),e.nodeCount()}function u(e,t){return r.minBy(t.edges(),(function(n){if(e.hasNode(n.v)!==e.hasNode(n.w))return i(t,n)}))}function c(e,t,n){r.forEach(e.nodes(),(function(e){t.node(e).rank+=n}))}t.exports=a},{"../graphlib":7,"../lodash":10,"./util":28}],26:[function(e,t,n){var r=e("./util").longestPath,o=e("./feasible-tree"),i=e("./network-simplex");function a(e){switch(e.graph().ranker){case"network-simplex":default:c(e);break;case"tight-tree":u(e);break;case"longest-path":s(e)}}t.exports=a;var s=r;function u(e){r(e),o(e)}function c(e){i(e)}},{"./feasible-tree":25,"./network-simplex":27,"./util":28}],27:[function(e,t,n){var r=e("../lodash"),o=e("./feasible-tree"),i=e("./util").slack,a=e("./util").longestPath,s=e("../graphlib").alg.preorder,u=e("../graphlib").alg.postorder,c=e("../util").simplify;function f(e){e=c(e),a(e);var t,n=o(e);for(p(n),d(n,e);t=_(n);)g(n,e,t,y(n,e,t))}function d(e,t){var n=u(e,e.nodes());n=n.slice(0,n.length-1),r.forEach(n,(function(n){h(e,t,n)}))}function h(e,t,n){var r=e.node(n).parent;e.edge(n,r).cutvalue=l(e,t,n)}function l(e,t,n){var o=e.node(n).parent,i=!0,a=t.edge(n,o),s=0;return a||(i=!1,a=t.edge(o,n)),s=a.weight,r.forEach(t.nodeEdges(n),(function(r){var a=r.v===n,u=a?r.w:r.v;if(u!==o){var c=a===i,f=t.edge(r).weight;if(s+=c?f:-f,m(e,n,u)){var d=e.edge(n,u).cutvalue;s+=c?-d:d}}})),s}function p(e,t){arguments.length<2&&(t=e.nodes()[0]),v(e,{},1,t)}function v(e,t,n,o,i){var a=n,s=e.node(o);return t[o]=!0,r.forEach(e.neighbors(o),(function(i){r.has(t,i)||(n=v(e,t,n,i,o))})),s.low=a,s.lim=n++,i?s.parent=i:delete s.parent,n}function _(e){return r.find(e.edges(),(function(t){return e.edge(t).cutvalue<0}))}function y(e,t,n){var o=n.v,a=n.w;t.hasEdge(o,a)||(o=n.w,a=n.v);var s=e.node(o),u=e.node(a),c=s,f=!1;s.lim>u.lim&&(c=u,f=!0);var d=r.filter(t.edges(),(function(t){return f===x(e,e.node(t.v),c)&&f!==x(e,e.node(t.w),c)}));return r.minBy(d,(function(e){return i(t,e)}))}function g(e,t,n,r){var o=n.v,i=n.w;e.removeEdge(o,i),e.setEdge(r.v,r.w,{}),p(e),d(e,t),b(e,t)}function b(e,t){var n=r.find(e.nodes(),(function(e){return!t.node(e).parent})),o=s(e,n);o=o.slice(1),r.forEach(o,(function(n){var r=e.node(n).parent,o=t.edge(n,r),i=!1;o||(o=t.edge(r,n),i=!0),t.node(n).rank=t.node(r).rank+(i?o.minlen:-o.minlen)}))}function m(e,t,n){return e.hasEdge(t,n)}function x(e,t,n){return n.low<=t.lim&&t.lim<=n.lim}t.exports=f,f.initLowLimValues=p,f.initCutValues=d,f.calcCutValue=l,f.leaveEdge=_,f.enterEdge=y,f.exchangeEdges=g},{"../graphlib":7,"../lodash":10,"../util":29,"./feasible-tree":25,"./util":28}],28:[function(e,t,n){var r=e("../lodash");function o(e){var t={};function n(o){var i=e.node(o);if(r.has(t,o))return i.rank;t[o]=!0;var a=r.min(r.map(e.outEdges(o),(function(t){return n(t.w)-e.edge(t).minlen})));return a!==Number.POSITIVE_INFINITY&&null!=a||(a=0),i.rank=a}r.forEach(e.sources(),n)}function i(e,t){return e.node(t.w).rank-e.node(t.v).rank-e.edge(t).minlen}t.exports={longestPath:o,slack:i}},{"../lodash":10}],29:[function(e,t,n){var r=e("./lodash"),o=e("./graphlib").Graph;function i(e,t,n,o){var i;do{i=r.uniqueId(o)}while(e.hasNode(i));return n.dummy=t,e.setNode(i,n),i}function a(e){var t=(new o).setGraph(e.graph());return r.forEach(e.nodes(),(function(n){t.setNode(n,e.node(n))})),r.forEach(e.edges(),(function(n){var r=t.edge(n.v,n.w)||{weight:0,minlen:1},o=e.edge(n);t.setEdge(n.v,n.w,{weight:r.weight+o.weight,minlen:Math.max(r.minlen,o.minlen)})})),t}function s(e){var t=new o({multigraph:e.isMultigraph()}).setGraph(e.graph());return r.forEach(e.nodes(),(function(n){e.children(n).length||t.setNode(n,e.node(n))})),r.forEach(e.edges(),(function(n){t.setEdge(n,e.edge(n))})),t}function u(e){var t=r.map(e.nodes(),(function(t){var n={};return r.forEach(e.outEdges(t),(function(t){n[t.w]=(n[t.w]||0)+e.edge(t).weight})),n}));return r.zipObject(e.nodes(),t)}function c(e){var t=r.map(e.nodes(),(function(t){var n={};return r.forEach(e.inEdges(t),(function(t){n[t.v]=(n[t.v]||0)+e.edge(t).weight})),n}));return r.zipObject(e.nodes(),t)}function f(e,t){var n,r,o=e.x,i=e.y,a=t.x-o,s=t.y-i,u=e.width/2,c=e.height/2;if(!a&&!s)throw new Error("Not possible to find intersection inside of the rectangle");return Math.abs(s)*u>Math.abs(a)*c?(s<0&&(c=-c),n=c*a/s,r=c):(a<0&&(u=-u),n=u,r=u*s/a),{x:o+n,y:i+r}}function d(e){var t=r.map(r.range(v(e)+1),(function(){return[]}));return r.forEach(e.nodes(),(function(n){var o=e.node(n),i=o.rank;r.isUndefined(i)||(t[i][o.order]=n)})),t}function h(e){var t=r.min(r.map(e.nodes(),(function(t){return e.node(t).rank})));r.forEach(e.nodes(),(function(n){var o=e.node(n);r.has(o,"rank")&&(o.rank-=t)}))}function l(e){var t=r.min(r.map(e.nodes(),(function(t){return e.node(t).rank}))),n=[];r.forEach(e.nodes(),(function(r){var o=e.node(r).rank-t;n[o]||(n[o]=[]),n[o].push(r)}));var o=0,i=e.graph().nodeRankFactor;r.forEach(n,(function(t,n){r.isUndefined(t)&&n%i!=0?--o:o&&r.forEach(t,(function(t){e.node(t).rank+=o}))}))}function p(e,t,n,r){var o={width:0,height:0};return arguments.length>=4&&(o.rank=n,o.order=r),i(e,"border",o,t)}function v(e){return r.max(r.map(e.nodes(),(function(t){var n=e.node(t).rank;if(!r.isUndefined(n))return n})))}function _(e,t){var n={lhs:[],rhs:[]};return r.forEach(e,(function(e){t(e)?n.lhs.push(e):n.rhs.push(e)})),n}function y(e,t){var n=r.now();try{return t()}finally{console.log(e+" time: "+(r.now()-n)+"ms")}}function g(e,t){return t()}t.exports={addDummyNode:i,simplify:a,asNonCompoundGraph:s,successorWeights:u,predecessorWeights:c,intersectRect:f,buildLayerMatrix:d,normalizeRanks:h,removeEmptyRanks:l,addBorderNode:p,maxRank:v,partition:_,time:y,notime:g}},{"./graphlib":7,"./lodash":10}],30:[function(e,t,n){t.exports="0.8.5"},{}],31:[function(e,t,n){var r=e("./lib");t.exports={Graph:r.Graph,json:e("./lib/json"),alg:e("./lib/alg"),version:r.version}},{"./lib":47,"./lib/alg":38,"./lib/json":48}],32:[function(e,t,n){var r=e("../lodash");function o(e){var t,n={},o=[];function i(o){r.has(n,o)||(n[o]=!0,t.push(o),r.each(e.successors(o),i),r.each(e.predecessors(o),i))}return r.each(e.nodes(),(function(e){t=[],i(e),t.length&&o.push(t)})),o}t.exports=o},{"../lodash":49}],33:[function(e,t,n){var r=e("../lodash");function o(e,t,n){r.isArray(t)||(t=[t]);var o=(e.isDirected()?e.successors:e.neighbors).bind(e),a=[],s={};return r.each(t,(function(t){if(!e.hasNode(t))throw new Error("Graph does not have node: "+t);i(e,t,"post"===n,s,o,a)})),a}function i(e,t,n,o,a,s){r.has(o,t)||(o[t]=!0,n||s.push(t),r.each(a(t),(function(t){i(e,t,n,o,a,s)})),n&&s.push(t))}t.exports=o},{"../lodash":49}],34:[function(e,t,n){var r=e("./dijkstra"),o=e("../lodash");function i(e,t,n){return o.transform(e.nodes(),(function(o,i){o[i]=r(e,i,t,n)}),{})}t.exports=i},{"../lodash":49,"./dijkstra":35}],35:[function(e,t,n){var r=e("../lodash"),o=e("../data/priority-queue");t.exports=a;var i=r.constant(1);function a(e,t,n,r){return s(e,String(t),n||i,r||function(t){return e.outEdges(t)})}function s(e,t,n,r){var i,a,s={},u=new o,c=function(e){var t=e.v!==i?e.v:e.w,r=s[t],o=n(e),c=a.distance+o;if(o<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+e+" Weight: "+o);c<r.distance&&(r.distance=c,r.predecessor=i,u.decrease(t,c))};for(e.nodes().forEach((function(e){var n=e===t?0:Number.POSITIVE_INFINITY;s[e]={distance:n},u.add(e,n)}));u.size()>0&&(i=u.removeMin(),(a=s[i]).distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return s}},{"../data/priority-queue":45,"../lodash":49}],36:[function(e,t,n){var r=e("../lodash"),o=e("./tarjan");function i(e){return r.filter(o(e),(function(t){return t.length>1||1===t.length&&e.hasEdge(t[0],t[0])}))}t.exports=i},{"../lodash":49,"./tarjan":43}],37:[function(e,t,n){var r=e("../lodash");t.exports=i;var o=r.constant(1);function i(e,t,n){return a(e,t||o,n||function(t){return e.outEdges(t)})}function a(e,t,n){var r={},o=e.nodes();return o.forEach((function(e){r[e]={},r[e][e]={distance:0},o.forEach((function(t){e!==t&&(r[e][t]={distance:Number.POSITIVE_INFINITY})})),n(e).forEach((function(n){var o=n.v===e?n.w:n.v,i=t(n);r[e][o]={distance:i,predecessor:e}}))})),o.forEach((function(e){var t=r[e];o.forEach((function(n){var i=r[n];o.forEach((function(n){var r=i[e],o=t[n],a=i[n],s=r.distance+o.distance;s<a.distance&&(a.distance=s,a.predecessor=o.predecessor)}))}))})),r}},{"../lodash":49}],38:[function(e,t,n){t.exports={components:e("./components"),dijkstra:e("./dijkstra"),dijkstraAll:e("./dijkstra-all"),findCycles:e("./find-cycles"),floydWarshall:e("./floyd-warshall"),isAcyclic:e("./is-acyclic"),postorder:e("./postorder"),preorder:e("./preorder"),prim:e("./prim"),tarjan:e("./tarjan"),topsort:e("./topsort")}},{"./components":32,"./dijkstra":35,"./dijkstra-all":34,"./find-cycles":36,"./floyd-warshall":37,"./is-acyclic":39,"./postorder":40,"./preorder":41,"./prim":42,"./tarjan":43,"./topsort":44}],39:[function(e,t,n){var r=e("./topsort");function o(e){try{r(e)}catch(e){if(e instanceof r.CycleException)return!1;throw e}return!0}t.exports=o},{"./topsort":44}],40:[function(e,t,n){var r=e("./dfs");function o(e,t){return r(e,t,"post")}t.exports=o},{"./dfs":33}],41:[function(e,t,n){var r=e("./dfs");function o(e,t){return r(e,t,"pre")}t.exports=o},{"./dfs":33}],42:[function(e,t,n){var r=e("../lodash"),o=e("../graph"),i=e("../data/priority-queue");function a(e,t){var n,a=new o,s={},u=new i;function c(e){var r=e.v===n?e.w:e.v,o=u.priority(r);if(void 0!==o){var i=t(e);i<o&&(s[r]=n,u.decrease(r,i))}}if(0===e.nodeCount())return a;r.each(e.nodes(),(function(e){u.add(e,Number.POSITIVE_INFINITY),a.setNode(e)})),u.decrease(e.nodes()[0],0);for(var f=!1;u.size()>0;){if(n=u.removeMin(),r.has(s,n))a.setEdge(n,s[n]);else{if(f)throw new Error("Input graph is not connected: "+e);f=!0}e.nodeEdges(n).forEach(c)}return a}t.exports=a},{"../data/priority-queue":45,"../graph":46,"../lodash":49}],43:[function(e,t,n){var r=e("../lodash");function o(e){var t=0,n=[],o={},i=[];function a(s){var u=o[s]={onStack:!0,lowlink:t,index:t++};if(n.push(s),e.successors(s).forEach((function(e){r.has(o,e)?o[e].onStack&&(u.lowlink=Math.min(u.lowlink,o[e].index)):(a(e),u.lowlink=Math.min(u.lowlink,o[e].lowlink))})),u.lowlink===u.index){var c,f=[];do{c=n.pop(),o[c].onStack=!1,f.push(c)}while(s!==c);i.push(f)}}return e.nodes().forEach((function(e){r.has(o,e)||a(e)})),i}t.exports=o},{"../lodash":49}],44:[function(e,t,n){var r=e("../lodash");function o(e){var t={},n={},o=[];function a(s){if(r.has(n,s))throw new i;r.has(t,s)||(n[s]=!0,t[s]=!0,r.each(e.predecessors(s),a),delete n[s],o.push(s))}if(r.each(e.sinks(),a),r.size(t)!==e.nodeCount())throw new i;return o}function i(){}t.exports=o,o.CycleException=i,i.prototype=new Error},{"../lodash":49}],45:[function(e,t,n){var r=e("../lodash");function o(){this._arr=[],this._keyIndices={}}t.exports=o,o.prototype.size=function(){return this._arr.length},o.prototype.keys=function(){return this._arr.map((function(e){return e.key}))},o.prototype.has=function(e){return r.has(this._keyIndices,e)},o.prototype.priority=function(e){var t=this._keyIndices[e];if(void 0!==t)return this._arr[t].priority},o.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},o.prototype.add=function(e,t){var n=this._keyIndices;if(e=String(e),!r.has(n,e)){var o=this._arr,i=o.length;return n[e]=i,o.push({key:e,priority:t}),this._decrease(i),!0}return!1},o.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key},o.prototype.decrease=function(e,t){var n=this._keyIndices[e];if(t>this._arr[n].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[n].priority+" New: "+t);this._arr[n].priority=t,this._decrease(n)},o.prototype._heapify=function(e){var t=this._arr,n=2*e,r=n+1,o=e;n<t.length&&(o=t[n].priority<t[o].priority?n:o,r<t.length&&(o=t[r].priority<t[o].priority?r:o),o!==e&&(this._swap(e,o),this._heapify(o)))},o.prototype._decrease=function(e){for(var t,n=this._arr,r=n[e].priority;0!==e&&!(n[t=e>>1].priority<r);)this._swap(e,t),e=t},o.prototype._swap=function(e,t){var n=this._arr,r=this._keyIndices,o=n[e],i=n[t];n[e]=i,n[t]=o,r[i.key]=e,r[o.key]=t}},{"../lodash":49}],46:[function(e,t,n){var r=e("./lodash");t.exports=s;var o="\\0",i="\\0",a="";function s(e){this._isDirected=!r.has(e,"directed")||e.directed,this._isMultigraph=!!r.has(e,"multigraph")&&e.multigraph,this._isCompound=!!r.has(e,"compound")&&e.compound,this._label=void 0,this._defaultNodeLabelFn=r.constant(void 0),this._defaultEdgeLabelFn=r.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[i]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}function u(e,t){e[t]?e[t]++:e[t]=1}function c(e,t){--e[t]||delete e[t]}function f(e,t,n,i){var s=""+t,u=""+n;if(!e&&s>u){var c=s;s=u,u=c}return s+a+u+a+(r.isUndefined(i)?o:i)}function d(e,t,n,r){var o=""+t,i=""+n;if(!e&&o>i){var a=o;o=i,i=a}var s={v:o,w:i};return r&&(s.name=r),s}function h(e,t){return f(e,t.v,t.w,t.name)}s.prototype._nodeCount=0,s.prototype._edgeCount=0,s.prototype.isDirected=function(){return this._isDirected},s.prototype.isMultigraph=function(){return this._isMultigraph},s.prototype.isCompound=function(){return this._isCompound},s.prototype.setGraph=function(e){return this._label=e,this},s.prototype.graph=function(){return this._label},s.prototype.setDefaultNodeLabel=function(e){return r.isFunction(e)||(e=r.constant(e)),this._defaultNodeLabelFn=e,this},s.prototype.nodeCount=function(){return this._nodeCount},s.prototype.nodes=function(){return r.keys(this._nodes)},s.prototype.sources=function(){var e=this;return r.filter(this.nodes(),(function(t){return r.isEmpty(e._in[t])}))},s.prototype.sinks=function(){var e=this;return r.filter(this.nodes(),(function(t){return r.isEmpty(e._out[t])}))},s.prototype.setNodes=function(e,t){var n=arguments,o=this;return r.each(e,(function(e){n.length>1?o.setNode(e,t):o.setNode(e)})),this},s.prototype.setNode=function(e,t){return r.has(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=i,this._children[e]={},this._children[i][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)},s.prototype.node=function(e){return this._nodes[e]},s.prototype.hasNode=function(e){return r.has(this._nodes,e)},s.prototype.removeNode=function(e){var t=this;if(r.has(this._nodes,e)){var n=function(e){t.removeEdge(t._edgeObjs[e])};delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],r.each(this.children(e),(function(e){t.setParent(e)})),delete this._children[e]),r.each(r.keys(this._in[e]),n),delete this._in[e],delete this._preds[e],r.each(r.keys(this._out[e]),n),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this},s.prototype.setParent=function(e,t){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r.isUndefined(t))t=i;else{for(var n=t+="";!r.isUndefined(n);n=this.parent(n))if(n===e)throw new Error("Setting "+t+" as parent of "+e+" would create a cycle");this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this},s.prototype._removeFromParentsChildList=function(e){delete this._children[this._parent[e]][e]},s.prototype.parent=function(e){if(this._isCompound){var t=this._parent[e];if(t!==i)return t}},s.prototype.children=function(e){if(r.isUndefined(e)&&(e=i),this._isCompound){var t=this._children[e];if(t)return r.keys(t)}else{if(e===i)return this.nodes();if(this.hasNode(e))return[]}},s.prototype.predecessors=function(e){var t=this._preds[e];if(t)return r.keys(t)},s.prototype.successors=function(e){var t=this._sucs[e];if(t)return r.keys(t)},s.prototype.neighbors=function(e){var t=this.predecessors(e);if(t)return r.union(t,this.successors(e))},s.prototype.isLeaf=function(e){return 0===(this.isDirected()?this.successors(e):this.neighbors(e)).length},s.prototype.filterNodes=function(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var n=this;r.each(this._nodes,(function(n,r){e(r)&&t.setNode(r,n)})),r.each(this._edgeObjs,(function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,n.edge(e))}));var o={};function i(e){var r=n.parent(e);return void 0===r||t.hasNode(r)?(o[e]=r,r):r in o?o[r]:i(r)}return this._isCompound&&r.each(t.nodes(),(function(e){t.setParent(e,i(e))})),t},s.prototype.setDefaultEdgeLabel=function(e){return r.isFunction(e)||(e=r.constant(e)),this._defaultEdgeLabelFn=e,this},s.prototype.edgeCount=function(){return this._edgeCount},s.prototype.edges=function(){return r.values(this._edgeObjs)},s.prototype.setPath=function(e,t){var n=this,o=arguments;return r.reduce(e,(function(e,r){return o.length>1?n.setEdge(e,r,t):n.setEdge(e,r),r})),this},s.prototype.setEdge=function(){var e,t,n,o,i=!1,a=arguments[0];"object"==typeof a&&null!==a&&"v"in a?(e=a.v,t=a.w,n=a.name,2===arguments.length&&(o=arguments[1],i=!0)):(e=a,t=arguments[1],n=arguments[3],arguments.length>2&&(o=arguments[2],i=!0)),e=""+e,t=""+t,r.isUndefined(n)||(n=""+n);var s=f(this._isDirected,e,t,n);if(r.has(this._edgeLabels,s))return i&&(this._edgeLabels[s]=o),this;if(!r.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(t),this._edgeLabels[s]=i?o:this._defaultEdgeLabelFn(e,t,n);var c=d(this._isDirected,e,t,n);return e=c.v,t=c.w,Object.freeze(c),this._edgeObjs[s]=c,u(this._preds[t],e),u(this._sucs[e],t),this._in[t][s]=c,this._out[e][s]=c,this._edgeCount++,this},s.prototype.edge=function(e,t,n){var r=1===arguments.length?h(this._isDirected,arguments[0]):f(this._isDirected,e,t,n);return this._edgeLabels[r]},s.prototype.hasEdge=function(e,t,n){var o=1===arguments.length?h(this._isDirected,arguments[0]):f(this._isDirected,e,t,n);return r.has(this._edgeLabels,o)},s.prototype.removeEdge=function(e,t,n){var r=1===arguments.length?h(this._isDirected,arguments[0]):f(this._isDirected,e,t,n),o=this._edgeObjs[r];return o&&(e=o.v,t=o.w,delete this._edgeLabels[r],delete this._edgeObjs[r],c(this._preds[t],e),c(this._sucs[e],t),delete this._in[t][r],delete this._out[e][r],this._edgeCount--),this},s.prototype.inEdges=function(e,t){var n=this._in[e];if(n){var o=r.values(n);return t?r.filter(o,(function(e){return e.v===t})):o}},s.prototype.outEdges=function(e,t){var n=this._out[e];if(n){var o=r.values(n);return t?r.filter(o,(function(e){return e.w===t})):o}},s.prototype.nodeEdges=function(e,t){var n=this.inEdges(e,t);if(n)return n.concat(this.outEdges(e,t))}},{"./lodash":49}],47:[function(e,t,n){t.exports={Graph:e("./graph"),version:e("./version")}},{"./graph":46,"./version":50}],48:[function(e,t,n){var r=e("./lodash"),o=e("./graph");function i(e){var t={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:a(e),edges:s(e)};return r.isUndefined(e.graph())||(t.value=r.clone(e.graph())),t}function a(e){return r.map(e.nodes(),(function(t){var n=e.node(t),o=e.parent(t),i={v:t};return r.isUndefined(n)||(i.value=n),r.isUndefined(o)||(i.parent=o),i}))}function s(e){return r.map(e.edges(),(function(t){var n=e.edge(t),o={v:t.v,w:t.w};return r.isUndefined(t.name)||(o.name=t.name),r.isUndefined(n)||(o.value=n),o}))}function u(e){var t=new o(e.options).setGraph(e.value);return r.each(e.nodes,(function(e){t.setNode(e.v,e.value),e.parent&&t.setParent(e.v,e.parent)})),r.each(e.edges,(function(e){t.setEdge({v:e.v,w:e.w,name:e.name},e.value)})),t}t.exports={write:i,read:u}},{"./graph":46,"./lodash":49}],49:[function(e,t,n){var r;if("function"==typeof e)try{r={clone:e("lodash/clone"),constant:e("lodash/constant"),each:e("lodash/each"),filter:e("lodash/filter"),has:e("lodash/has"),isArray:e("lodash/isArray"),isEmpty:e("lodash/isEmpty"),isFunction:e("lodash/isFunction"),isUndefined:e("lodash/isUndefined"),keys:e("lodash/keys"),map:e("lodash/map"),reduce:e("lodash/reduce"),size:e("lodash/size"),transform:e("lodash/transform"),union:e("lodash/union"),values:e("lodash/values")}}catch(e){}r||(r=window._),t.exports=r},{"lodash/clone":226,"lodash/constant":228,"lodash/each":230,"lodash/filter":232,"lodash/has":239,"lodash/isArray":243,"lodash/isEmpty":247,"lodash/isFunction":248,"lodash/isUndefined":258,"lodash/keys":259,"lodash/map":262,"lodash/reduce":274,"lodash/size":275,"lodash/transform":284,"lodash/union":285,"lodash/values":287}],50:[function(e,t,n){t.exports="2.1.8"},{}],51:[function(e,t,n){var r=e("./_getNative")(e("./_root"),"DataView");t.exports=r},{"./_getNative":163,"./_root":208}],52:[function(e,t,n){var r=e("./_hashClear"),o=e("./_hashDelete"),i=e("./_hashGet"),a=e("./_hashHas"),s=e("./_hashSet");function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=o,u.prototype.get=i,u.prototype.has=a,u.prototype.set=s,t.exports=u},{"./_hashClear":172,"./_hashDelete":173,"./_hashGet":174,"./_hashHas":175,"./_hashSet":176}],53:[function(e,t,n){var r=e("./_listCacheClear"),o=e("./_listCacheDelete"),i=e("./_listCacheGet"),a=e("./_listCacheHas"),s=e("./_listCacheSet");function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=o,u.prototype.get=i,u.prototype.has=a,u.prototype.set=s,t.exports=u},{"./_listCacheClear":188,"./_listCacheDelete":189,"./_listCacheGet":190,"./_listCacheHas":191,"./_listCacheSet":192}],54:[function(e,t,n){var r=e("./_getNative")(e("./_root"),"Map");t.exports=r},{"./_getNative":163,"./_root":208}],55:[function(e,t,n){var r=e("./_mapCacheClear"),o=e("./_mapCacheDelete"),i=e("./_mapCacheGet"),a=e("./_mapCacheHas"),s=e("./_mapCacheSet");function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=o,u.prototype.get=i,u.prototype.has=a,u.prototype.set=s,t.exports=u},{"./_mapCacheClear":193,"./_mapCacheDelete":194,"./_mapCacheGet":195,"./_mapCacheHas":196,"./_mapCacheSet":197}],56:[function(e,t,n){var r=e("./_getNative")(e("./_root"),"Promise");t.exports=r},{"./_getNative":163,"./_root":208}],57:[function(e,t,n){var r=e("./_getNative")(e("./_root"),"Set");t.exports=r},{"./_getNative":163,"./_root":208}],58:[function(e,t,n){var r=e("./_MapCache"),o=e("./_setCacheAdd"),i=e("./_setCacheHas");function a(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++t<n;)this.add(e[t])}a.prototype.add=a.prototype.push=o,a.prototype.has=i,t.exports=a},{"./_MapCache":55,"./_setCacheAdd":210,"./_setCacheHas":211}],59:[function(e,t,n){var r=e("./_ListCache"),o=e("./_stackClear"),i=e("./_stackDelete"),a=e("./_stackGet"),s=e("./_stackHas"),u=e("./_stackSet");function c(e){var t=this.__data__=new r(e);this.size=t.size}c.prototype.clear=o,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=s,c.prototype.set=u,t.exports=c},{"./_ListCache":53,"./_stackClear":215,"./_stackDelete":216,"./_stackGet":217,"./_stackHas":218,"./_stackSet":219}],60:[function(e,t,n){var r=e("./_root").Symbol;t.exports=r},{"./_root":208}],61:[function(e,t,n){var r=e("./_root").Uint8Array;t.exports=r},{"./_root":208}],62:[function(e,t,n){var r=e("./_getNative")(e("./_root"),"WeakMap");t.exports=r},{"./_getNative":163,"./_root":208}],63:[function(e,t,n){function r(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}t.exports=r},{}],64:[function(e,t,n){function r(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}t.exports=r},{}],65:[function(e,t,n){function r(e,t){for(var n=-1,r=null==e?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}t.exports=r},{}],66:[function(e,t,n){var r=e("./_baseIndexOf");function o(e,t){return!(null==e||!e.length)&&r(e,t,0)>-1}t.exports=o},{"./_baseIndexOf":95}],67:[function(e,t,n){function r(e,t,n){for(var r=-1,o=null==e?0:e.length;++r<o;)if(n(t,e[r]))return!0;return!1}t.exports=r},{}],68:[function(e,t,n){var r=e("./_baseTimes"),o=e("./isArguments"),i=e("./isArray"),a=e("./isBuffer"),s=e("./_isIndex"),u=e("./isTypedArray"),c=Object.prototype.hasOwnProperty;function f(e,t){var n=i(e),f=!n&&o(e),d=!n&&!f&&a(e),h=!n&&!f&&!d&&u(e),l=n||f||d||h,p=l?r(e.length,String):[],v=p.length;for(var _ in e)!t&&!c.call(e,_)||l&&("length"==_||d&&("offset"==_||"parent"==_)||h&&("buffer"==_||"byteLength"==_||"byteOffset"==_)||s(_,v))||p.push(_);return p}t.exports=f},{"./_baseTimes":125,"./_isIndex":181,"./isArguments":242,"./isArray":243,"./isBuffer":246,"./isTypedArray":257}],69:[function(e,t,n){function r(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}t.exports=r},{}],70:[function(e,t,n){function r(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}t.exports=r},{}],71:[function(e,t,n){function r(e,t,n,r){var o=-1,i=null==e?0:e.length;for(r&&i&&(n=e[++o]);++o<i;)n=t(n,e[o],o,e);return n}t.exports=r},{}],72:[function(e,t,n){function r(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}t.exports=r},{}],73:[function(e,t,n){var r=e("./_baseProperty")("length");t.exports=r},{"./_baseProperty":117}],74:[function(e,t,n){var r=e("./_baseAssignValue"),o=e("./eq");function i(e,t,n){(void 0!==n&&!o(e[t],n)||void 0===n&&!(t in e))&&r(e,t,n)}t.exports=i},{"./_baseAssignValue":79,"./eq":231}],75:[function(e,t,n){var r=e("./_baseAssignValue"),o=e("./eq"),i=Object.prototype.hasOwnProperty;function a(e,t,n){var a=e[t];i.call(e,t)&&o(a,n)&&(void 0!==n||t in e)||r(e,t,n)}t.exports=a},{"./_baseAssignValue":79,"./eq":231}],76:[function(e,t,n){var r=e("./eq");function o(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return-1}t.exports=o},{"./eq":231}],77:[function(e,t,n){var r=e("./_copyObject"),o=e("./keys");function i(e,t){return e&&r(t,o(t),e)}t.exports=i},{"./_copyObject":143,"./keys":259}],78:[function(e,t,n){var r=e("./_copyObject"),o=e("./keysIn");function i(e,t){return e&&r(t,o(t),e)}t.exports=i},{"./_copyObject":143,"./keysIn":260}],79:[function(e,t,n){var r=e("./_defineProperty");function o(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}t.exports=o},{"./_defineProperty":153}],80:[function(e,t,n){var r=e("./_Stack"),o=e("./_arrayEach"),i=e("./_assignValue"),a=e("./_baseAssign"),s=e("./_baseAssignIn"),u=e("./_cloneBuffer"),c=e("./_copyArray"),f=e("./_copySymbols"),d=e("./_copySymbolsIn"),h=e("./_getAllKeys"),l=e("./_getAllKeysIn"),p=e("./_getTag"),v=e("./_initCloneArray"),_=e("./_initCloneByTag"),y=e("./_initCloneObject"),g=e("./isArray"),b=e("./isBuffer"),m=e("./isMap"),x=e("./isObject"),w=e("./isSet"),E=e("./keys"),j=1,k=2,A=4,O="[object Arguments]",I="[object Array]",S="[object Boolean]",C="[object Date]",N="[object Error]",T="[object Function]",M="[object GeneratorFunction]",L="[object Map]",P="[object Number]",F="[object Object]",D="[object RegExp]",B="[object Set]",G="[object String]",R="[object Symbol]",U="[object WeakMap]",z="[object ArrayBuffer]",V="[object DataView]",q="[object Float32Array]",K="[object Float64Array]",H="[object Int8Array]",Y="[object Int16Array]",\$="[object Int32Array]",W="[object Uint8Array]",J="[object Uint8ClampedArray]",X="[object Uint16Array]",Z="[object Uint32Array]",Q={};function ee(e,t,n,I,S,C){var N,L=t&j,P=t&k,D=t&A;if(n&&(N=S?n(e,I,S,C):n(e)),void 0!==N)return N;if(!x(e))return e;var B=g(e);if(B){if(N=v(e),!L)return c(e,N)}else{var G=p(e),R=G==T||G==M;if(b(e))return u(e,L);if(G==F||G==O||R&&!S){if(N=P||R?{}:y(e),!L)return P?d(e,s(N,e)):f(e,a(N,e))}else{if(!Q[G])return S?e:{};N=_(e,G,L)}}C||(C=new r);var U=C.get(e);if(U)return U;C.set(e,N),w(e)?e.forEach((function(r){N.add(ee(r,t,n,r,e,C))})):m(e)&&e.forEach((function(r,o){N.set(o,ee(r,t,n,o,e,C))}));var z=D?P?l:h:P?keysIn:E,V=B?void 0:z(e);return o(V||e,(function(r,o){V&&(r=e[o=r]),i(N,o,ee(r,t,n,o,e,C))})),N}Q[O]=Q[I]=Q[z]=Q[V]=Q[S]=Q[C]=Q[q]=Q[K]=Q[H]=Q[Y]=Q[\$]=Q[L]=Q[P]=Q[F]=Q[D]=Q[B]=Q[G]=Q[R]=Q[W]=Q[J]=Q[X]=Q[Z]=!0,Q[N]=Q[T]=Q[U]=!1,t.exports=ee},{"./_Stack":59,"./_arrayEach":64,"./_assignValue":75,"./_baseAssign":77,"./_baseAssignIn":78,"./_cloneBuffer":135,"./_copyArray":142,"./_copySymbols":144,"./_copySymbolsIn":145,"./_getAllKeys":159,"./_getAllKeysIn":160,"./_getTag":168,"./_initCloneArray":177,"./_initCloneByTag":178,"./_initCloneObject":179,"./isArray":243,"./isBuffer":246,"./isMap":250,"./isObject":251,"./isSet":254,"./keys":259}],81:[function(e,t,n){var r=e("./isObject"),o=Object.create,i=function(){function e(){}return function(t){if(!r(t))return{};if(o)return o(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();t.exports=i},{"./isObject":251}],82:[function(e,t,n){var r=e("./_baseForOwn"),o=e("./_createBaseEach")(r);t.exports=o},{"./_baseForOwn":88,"./_createBaseEach":148}],83:[function(e,t,n){var r=e("./isSymbol");function o(e,t,n){for(var o=-1,i=e.length;++o<i;){var a=e[o],s=t(a);if(null!=s&&(void 0===u?s==s&&!r(s):n(s,u)))var u=s,c=a}return c}t.exports=o},{"./isSymbol":256}],84:[function(e,t,n){var r=e("./_baseEach");function o(e,t){var n=[];return r(e,(function(e,r,o){t(e,r,o)&&n.push(e)})),n}t.exports=o},{"./_baseEach":82}],85:[function(e,t,n){function r(e,t,n,r){for(var o=e.length,i=n+(r?1:-1);r?i--:++i<o;)if(t(e[i],i,e))return i;return-1}t.exports=r},{}],86:[function(e,t,n){var r=e("./_arrayPush"),o=e("./_isFlattenable");function i(e,t,n,a,s){var u=-1,c=e.length;for(n||(n=o),s||(s=[]);++u<c;){var f=e[u];t>0&&n(f)?t>1?i(f,t-1,n,a,s):r(s,f):a||(s[s.length]=f)}return s}t.exports=i},{"./_arrayPush":70,"./_isFlattenable":180}],87:[function(e,t,n){var r=e("./_createBaseFor")();t.exports=r},{"./_createBaseFor":149}],88:[function(e,t,n){var r=e("./_baseFor"),o=e("./keys");function i(e,t){return e&&r(e,t,o)}t.exports=i},{"./_baseFor":87,"./keys":259}],89:[function(e,t,n){var r=e("./_castPath"),o=e("./_toKey");function i(e,t){for(var n=0,i=(t=r(t,e)).length;null!=e&&n<i;)e=e[o(t[n++])];return n&&n==i?e:void 0}t.exports=i},{"./_castPath":133,"./_toKey":223}],90:[function(e,t,n){var r=e("./_arrayPush"),o=e("./isArray");function i(e,t,n){var i=t(e);return o(e)?i:r(i,n(e))}t.exports=i},{"./_arrayPush":70,"./isArray":243}],91:[function(e,t,n){var r=e("./_Symbol"),o=e("./_getRawTag"),i=e("./_objectToString"),a="[object Null]",s="[object Undefined]",u=r?r.toStringTag:void 0;function c(e){return null==e?void 0===e?s:a:u&&u in Object(e)?o(e):i(e)}t.exports=c},{"./_Symbol":60,"./_getRawTag":165,"./_objectToString":205}],92:[function(e,t,n){function r(e,t){return e>t}t.exports=r},{}],93:[function(e,t,n){var r=Object.prototype.hasOwnProperty;function o(e,t){return null!=e&&r.call(e,t)}t.exports=o},{}],94:[function(e,t,n){function r(e,t){return null!=e&&t in Object(e)}t.exports=r},{}],95:[function(e,t,n){var r=e("./_baseFindIndex"),o=e("./_baseIsNaN"),i=e("./_strictIndexOf");function a(e,t,n){return t==t?i(e,t,n):r(e,o,n)}t.exports=a},{"./_baseFindIndex":85,"./_baseIsNaN":101,"./_strictIndexOf":220}],96:[function(e,t,n){var r=e("./_baseGetTag"),o=e("./isObjectLike"),i="[object Arguments]";function a(e){return o(e)&&r(e)==i}t.exports=a},{"./_baseGetTag":91,"./isObjectLike":252}],97:[function(e,t,n){var r=e("./_baseIsEqualDeep"),o=e("./isObjectLike");function i(e,t,n,a,s){return e===t||(null==e||null==t||!o(e)&&!o(t)?e!=e&&t!=t:r(e,t,n,a,i,s))}t.exports=i},{"./_baseIsEqualDeep":98,"./isObjectLike":252}],98:[function(e,t,n){var r=e("./_Stack"),o=e("./_equalArrays"),i=e("./_equalByTag"),a=e("./_equalObjects"),s=e("./_getTag"),u=e("./isArray"),c=e("./isBuffer"),f=e("./isTypedArray"),d=1,h="[object Arguments]",l="[object Array]",p="[object Object]",v=Object.prototype.hasOwnProperty;function _(e,t,n,_,y,g){var b=u(e),m=u(t),x=b?l:s(e),w=m?l:s(t),E=(x=x==h?p:x)==p,j=(w=w==h?p:w)==p,k=x==w;if(k&&c(e)){if(!c(t))return!1;b=!0,E=!1}if(k&&!E)return g||(g=new r),b||f(e)?o(e,t,n,_,y,g):i(e,t,x,n,_,y,g);if(!(n&d)){var A=E&&v.call(e,"__wrapped__"),O=j&&v.call(t,"__wrapped__");if(A||O){var I=A?e.value():e,S=O?t.value():t;return g||(g=new r),y(I,S,n,_,g)}}return!!k&&(g||(g=new r),a(e,t,n,_,y,g))}t.exports=_},{"./_Stack":59,"./_equalArrays":154,"./_equalByTag":155,"./_equalObjects":156,"./_getTag":168,"./isArray":243,"./isBuffer":246,"./isTypedArray":257}],99:[function(e,t,n){var r=e("./_getTag"),o=e("./isObjectLike"),i="[object Map]";function a(e){return o(e)&&r(e)==i}t.exports=a},{"./_getTag":168,"./isObjectLike":252}],100:[function(e,t,n){var r=e("./_Stack"),o=e("./_baseIsEqual"),i=1,a=2;function s(e,t,n,s){var u=n.length,c=u,f=!s;if(null==e)return!c;for(e=Object(e);u--;){var d=n[u];if(f&&d[2]?d[1]!==e[d[0]]:!(d[0]in e))return!1}for(;++u<c;){var h=(d=n[u])[0],l=e[h],p=d[1];if(f&&d[2]){if(void 0===l&&!(h in e))return!1}else{var v=new r;if(s)var _=s(l,p,h,e,t,v);if(!(void 0===_?o(p,l,i|a,s,v):_))return!1}}return!0}t.exports=s},{"./_Stack":59,"./_baseIsEqual":97}],101:[function(e,t,n){function r(e){return e!=e}t.exports=r},{}],102:[function(e,t,n){var r=e("./isFunction"),o=e("./_isMasked"),i=e("./isObject"),a=e("./_toSource"),s=/[\\\\^\$.*+?()[\\]{}|]/g,u=/^\\[object .+?Constructor\\]\$/,c=Function.prototype,f=Object.prototype,d=c.toString,h=f.hasOwnProperty,l=RegExp("^"+d.call(h).replace(s,"\\\\\$&").replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g,"\$1.*?")+"\$");function p(e){return!(!i(e)||o(e))&&(r(e)?l:u).test(a(e))}t.exports=p},{"./_isMasked":185,"./_toSource":224,"./isFunction":248,"./isObject":251}],103:[function(e,t,n){var r=e("./_getTag"),o=e("./isObjectLike"),i="[object Set]";function a(e){return o(e)&&r(e)==i}t.exports=a},{"./_getTag":168,"./isObjectLike":252}],104:[function(e,t,n){var r=e("./_baseGetTag"),o=e("./isLength"),i=e("./isObjectLike"),a="[object Arguments]",s="[object Array]",u="[object Boolean]",c="[object Date]",f="[object Error]",d="[object Function]",h="[object Map]",l="[object Number]",p="[object Object]",v="[object RegExp]",_="[object Set]",y="[object String]",g="[object WeakMap]",b="[object ArrayBuffer]",m="[object DataView]",x="[object Float64Array]",w="[object Int8Array]",E="[object Int16Array]",j="[object Int32Array]",k="[object Uint8Array]",A="[object Uint8ClampedArray]",O="[object Uint16Array]",I="[object Uint32Array]",S={};function C(e){return i(e)&&o(e.length)&&!!S[r(e)]}S["[object Float32Array]"]=S[x]=S[w]=S[E]=S[j]=S[k]=S[A]=S[O]=S[I]=!0,S[a]=S[s]=S[b]=S[u]=S[m]=S[c]=S[f]=S[d]=S[h]=S[l]=S[p]=S[v]=S[_]=S[y]=S[g]=!1,t.exports=C},{"./_baseGetTag":91,"./isLength":249,"./isObjectLike":252}],105:[function(e,t,n){var r=e("./_baseMatches"),o=e("./_baseMatchesProperty"),i=e("./identity"),a=e("./isArray"),s=e("./property");function u(e){return"function"==typeof e?e:null==e?i:"object"==typeof e?a(e)?o(e[0],e[1]):r(e):s(e)}t.exports=u},{"./_baseMatches":110,"./_baseMatchesProperty":111,"./identity":241,"./isArray":243,"./property":272}],106:[function(e,t,n){var r=e("./_isPrototype"),o=e("./_nativeKeys"),i=Object.prototype.hasOwnProperty;function a(e){if(!r(e))return o(e);var t=[];for(var n in Object(e))i.call(e,n)&&"constructor"!=n&&t.push(n);return t}t.exports=a},{"./_isPrototype":186,"./_nativeKeys":202}],107:[function(e,t,n){var r=e("./isObject"),o=e("./_isPrototype"),i=e("./_nativeKeysIn"),a=Object.prototype.hasOwnProperty;function s(e){if(!r(e))return i(e);var t=o(e),n=[];for(var s in e)("constructor"!=s||!t&&a.call(e,s))&&n.push(s);return n}t.exports=s},{"./_isPrototype":186,"./_nativeKeysIn":203,"./isObject":251}],108:[function(e,t,n){function r(e,t){return e<t}t.exports=r},{}],109:[function(e,t,n){var r=e("./_baseEach"),o=e("./isArrayLike");function i(e,t){var n=-1,i=o(e)?Array(e.length):[];return r(e,(function(e,r,o){i[++n]=t(e,r,o)})),i}t.exports=i},{"./_baseEach":82,"./isArrayLike":244}],110:[function(e,t,n){var r=e("./_baseIsMatch"),o=e("./_getMatchData"),i=e("./_matchesStrictComparable");function a(e){var t=o(e);return 1==t.length&&t[0][2]?i(t[0][0],t[0][1]):function(n){return n===e||r(n,e,t)}}t.exports=a},{"./_baseIsMatch":100,"./_getMatchData":162,"./_matchesStrictComparable":199}],111:[function(e,t,n){var r=e("./_baseIsEqual"),o=e("./get"),i=e("./hasIn"),a=e("./_isKey"),s=e("./_isStrictComparable"),u=e("./_matchesStrictComparable"),c=e("./_toKey"),f=1,d=2;function h(e,t){return a(e)&&s(t)?u(c(e),t):function(n){var a=o(n,e);return void 0===a&&a===t?i(n,e):r(t,a,f|d)}}t.exports=h},{"./_baseIsEqual":97,"./_isKey":183,"./_isStrictComparable":187,"./_matchesStrictComparable":199,"./_toKey":223,"./get":238,"./hasIn":240}],112:[function(e,t,n){var r=e("./_Stack"),o=e("./_assignMergeValue"),i=e("./_baseFor"),a=e("./_baseMergeDeep"),s=e("./isObject"),u=e("./keysIn"),c=e("./_safeGet");function f(e,t,n,d,h){e!==t&&i(t,(function(i,u){if(h||(h=new r),s(i))a(e,t,u,n,f,d,h);else{var l=d?d(c(e,u),i,u+"",e,t,h):void 0;void 0===l&&(l=i),o(e,u,l)}}),u)}t.exports=f},{"./_Stack":59,"./_assignMergeValue":74,"./_baseFor":87,"./_baseMergeDeep":113,"./_safeGet":209,"./isObject":251,"./keysIn":260}],113:[function(e,t,n){var r=e("./_assignMergeValue"),o=e("./_cloneBuffer"),i=e("./_cloneTypedArray"),a=e("./_copyArray"),s=e("./_initCloneObject"),u=e("./isArguments"),c=e("./isArray"),f=e("./isArrayLikeObject"),d=e("./isBuffer"),h=e("./isFunction"),l=e("./isObject"),p=e("./isPlainObject"),v=e("./isTypedArray"),_=e("./_safeGet"),y=e("./toPlainObject");function g(e,t,n,g,b,m,x){var w=_(e,n),E=_(t,n),j=x.get(E);if(j)r(e,n,j);else{var k=m?m(w,E,n+"",e,t,x):void 0,A=void 0===k;if(A){var O=c(E),I=!O&&d(E),S=!O&&!I&&v(E);k=E,O||I||S?c(w)?k=w:f(w)?k=a(w):I?(A=!1,k=o(E,!0)):S?(A=!1,k=i(E,!0)):k=[]:p(E)||u(E)?(k=w,u(w)?k=y(w):l(w)&&!h(w)||(k=s(E))):A=!1}A&&(x.set(E,k),b(k,E,g,m,x),x.delete(E)),r(e,n,k)}}t.exports=g},{"./_assignMergeValue":74,"./_cloneBuffer":135,"./_cloneTypedArray":139,"./_copyArray":142,"./_initCloneObject":179,"./_safeGet":209,"./isArguments":242,"./isArray":243,"./isArrayLikeObject":245,"./isBuffer":246,"./isFunction":248,"./isObject":251,"./isPlainObject":253,"./isTypedArray":257,"./toPlainObject":282}],114:[function(e,t,n){var r=e("./_arrayMap"),o=e("./_baseIteratee"),i=e("./_baseMap"),a=e("./_baseSortBy"),s=e("./_baseUnary"),u=e("./_compareMultiple"),c=e("./identity");function f(e,t,n){var f=-1;t=r(t.length?t:[c],s(o));var d=i(e,(function(e,n,o){return{criteria:r(t,(function(t){return t(e)})),index:++f,value:e}}));return a(d,(function(e,t){return u(e,t,n)}))}t.exports=f},{"./_arrayMap":69,"./_baseIteratee":105,"./_baseMap":109,"./_baseSortBy":124,"./_baseUnary":127,"./_compareMultiple":141,"./identity":241}],115:[function(e,t,n){var r=e("./_basePickBy"),o=e("./hasIn");function i(e,t){return r(e,t,(function(t,n){return o(e,n)}))}t.exports=i},{"./_basePickBy":116,"./hasIn":240}],116:[function(e,t,n){var r=e("./_baseGet"),o=e("./_baseSet"),i=e("./_castPath");function a(e,t,n){for(var a=-1,s=t.length,u={};++a<s;){var c=t[a],f=r(e,c);n(f,c)&&o(u,i(c,e),f)}return u}t.exports=a},{"./_baseGet":89,"./_baseSet":122,"./_castPath":133}],117:[function(e,t,n){function r(e){return function(t){return null==t?void 0:t[e]}}t.exports=r},{}],118:[function(e,t,n){var r=e("./_baseGet");function o(e){return function(t){return r(t,e)}}t.exports=o},{"./_baseGet":89}],119:[function(e,t,n){var r=Math.ceil,o=Math.max;function i(e,t,n,i){for(var a=-1,s=o(r((t-e)/(n||1)),0),u=Array(s);s--;)u[i?s:++a]=e,e+=n;return u}t.exports=i},{}],120:[function(e,t,n){function r(e,t,n,r,o){return o(e,(function(e,o,i){n=r?(r=!1,e):t(n,e,o,i)})),n}t.exports=r},{}],121:[function(e,t,n){var r=e("./identity"),o=e("./_overRest"),i=e("./_setToString");function a(e,t){return i(o(e,t,r),e+"")}t.exports=a},{"./_overRest":207,"./_setToString":213,"./identity":241}],122:[function(e,t,n){var r=e("./_assignValue"),o=e("./_castPath"),i=e("./_isIndex"),a=e("./isObject"),s=e("./_toKey");function u(e,t,n,u){if(!a(e))return e;for(var c=-1,f=(t=o(t,e)).length,d=f-1,h=e;null!=h&&++c<f;){var l=s(t[c]),p=n;if(c!=d){var v=h[l];void 0===(p=u?u(v,l,h):void 0)&&(p=a(v)?v:i(t[c+1])?[]:{})}r(h,l,p),h=h[l]}return e}t.exports=u},{"./_assignValue":75,"./_castPath":133,"./_isIndex":181,"./_toKey":223,"./isObject":251}],123:[function(e,t,n){var r=e("./constant"),o=e("./_defineProperty"),i=e("./identity"),a=o?function(e,t){return o(e,"toString",{configurable:!0,enumerable:!1,value:r(t),writable:!0})}:i;t.exports=a},{"./_defineProperty":153,"./constant":228,"./identity":241}],124:[function(e,t,n){function r(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}t.exports=r},{}],125:[function(e,t,n){function r(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}t.exports=r},{}],126:[function(e,t,n){var r=e("./_Symbol"),o=e("./_arrayMap"),i=e("./isArray"),a=e("./isSymbol"),s=1/0,u=r?r.prototype:void 0,c=u?u.toString:void 0;function f(e){if("string"==typeof e)return e;if(i(e))return o(e,f)+"";if(a(e))return c?c.call(e):"";var t=e+"";return"0"==t&&1/e==-s?"-0":t}t.exports=f},{"./_Symbol":60,"./_arrayMap":69,"./isArray":243,"./isSymbol":256}],127:[function(e,t,n){function r(e){return function(t){return e(t)}}t.exports=r},{}],128:[function(e,t,n){var r=e("./_SetCache"),o=e("./_arrayIncludes"),i=e("./_arrayIncludesWith"),a=e("./_cacheHas"),s=e("./_createSet"),u=e("./_setToArray"),c=200;function f(e,t,n){var f=-1,d=o,h=e.length,l=!0,p=[],v=p;if(n)l=!1,d=i;else if(h>=c){var _=t?null:s(e);if(_)return u(_);l=!1,d=a,v=new r}else v=t?[]:p;e:for(;++f<h;){var y=e[f],g=t?t(y):y;if(y=n||0!==y?y:0,l&&g==g){for(var b=v.length;b--;)if(v[b]===g)continue e;t&&v.push(g),p.push(y)}else d(v,g,n)||(v!==p&&v.push(g),p.push(y))}return p}t.exports=f},{"./_SetCache":58,"./_arrayIncludes":66,"./_arrayIncludesWith":67,"./_cacheHas":131,"./_createSet":152,"./_setToArray":212}],129:[function(e,t,n){var r=e("./_arrayMap");function o(e,t){return r(t,(function(t){return e[t]}))}t.exports=o},{"./_arrayMap":69}],130:[function(e,t,n){function r(e,t,n){for(var r=-1,o=e.length,i=t.length,a={};++r<o;){var s=r<i?t[r]:void 0;n(a,e[r],s)}return a}t.exports=r},{}],131:[function(e,t,n){function r(e,t){return e.has(t)}t.exports=r},{}],132:[function(e,t,n){var r=e("./identity");function o(e){return"function"==typeof e?e:r}t.exports=o},{"./identity":241}],133:[function(e,t,n){var r=e("./isArray"),o=e("./_isKey"),i=e("./_stringToPath"),a=e("./toString");function s(e,t){return r(e)?e:o(e,t)?[e]:i(a(e))}t.exports=s},{"./_isKey":183,"./_stringToPath":222,"./isArray":243,"./toString":283}],134:[function(e,t,n){var r=e("./_Uint8Array");function o(e){var t=new e.constructor(e.byteLength);return new r(t).set(new r(e)),t}t.exports=o},{"./_Uint8Array":61}],135:[function(e,t,n){var r=e("./_root"),o="object"==typeof n&&n&&!n.nodeType&&n,i=o&&"object"==typeof t&&t&&!t.nodeType&&t,a=i&&i.exports===o?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;function u(e,t){if(t)return e.slice();var n=e.length,r=s?s(n):new e.constructor(n);return e.copy(r),r}t.exports=u},{"./_root":208}],136:[function(e,t,n){var r=e("./_cloneArrayBuffer");function o(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}t.exports=o},{"./_cloneArrayBuffer":134}],137:[function(e,t,n){var r=/\\w*\$/;function o(e){var t=new e.constructor(e.source,r.exec(e));return t.lastIndex=e.lastIndex,t}t.exports=o},{}],138:[function(e,t,n){var r=e("./_Symbol"),o=r?r.prototype:void 0,i=o?o.valueOf:void 0;function a(e){return i?Object(i.call(e)):{}}t.exports=a},{"./_Symbol":60}],139:[function(e,t,n){var r=e("./_cloneArrayBuffer");function o(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}t.exports=o},{"./_cloneArrayBuffer":134}],140:[function(e,t,n){var r=e("./isSymbol");function o(e,t){if(e!==t){var n=void 0!==e,o=null===e,i=e==e,a=r(e),s=void 0!==t,u=null===t,c=t==t,f=r(t);if(!u&&!f&&!a&&e>t||a&&s&&c&&!u&&!f||o&&s&&c||!n&&c||!i)return 1;if(!o&&!a&&!f&&e<t||f&&n&&i&&!o&&!a||u&&n&&i||!s&&i||!c)return-1}return 0}t.exports=o},{"./isSymbol":256}],141:[function(e,t,n){var r=e("./_compareAscending");function o(e,t,n){for(var o=-1,i=e.criteria,a=t.criteria,s=i.length,u=n.length;++o<s;){var c=r(i[o],a[o]);if(c)return o>=u?c:c*("desc"==n[o]?-1:1)}return e.index-t.index}t.exports=o},{"./_compareAscending":140}],142:[function(e,t,n){function r(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}t.exports=r},{}],143:[function(e,t,n){var r=e("./_assignValue"),o=e("./_baseAssignValue");function i(e,t,n,i){var a=!n;n||(n={});for(var s=-1,u=t.length;++s<u;){var c=t[s],f=i?i(n[c],e[c],c,n,e):void 0;void 0===f&&(f=e[c]),a?o(n,c,f):r(n,c,f)}return n}t.exports=i},{"./_assignValue":75,"./_baseAssignValue":79}],144:[function(e,t,n){var r=e("./_copyObject"),o=e("./_getSymbols");function i(e,t){return r(e,o(e),t)}t.exports=i},{"./_copyObject":143,"./_getSymbols":166}],145:[function(e,t,n){var r=e("./_copyObject"),o=e("./_getSymbolsIn");function i(e,t){return r(e,o(e),t)}t.exports=i},{"./_copyObject":143,"./_getSymbolsIn":167}],146:[function(e,t,n){var r=e("./_root")["__core-js_shared__"];t.exports=r},{"./_root":208}],147:[function(e,t,n){var r=e("./_baseRest"),o=e("./_isIterateeCall");function i(e){return r((function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,s=i>2?n[2]:void 0;for(a=e.length>3&&"function"==typeof a?(i--,a):void 0,s&&o(n[0],n[1],s)&&(a=i<3?void 0:a,i=1),t=Object(t);++r<i;){var u=n[r];u&&e(t,u,r,a)}return t}))}t.exports=i},{"./_baseRest":121,"./_isIterateeCall":182}],148:[function(e,t,n){var r=e("./isArrayLike");function o(e,t){return function(n,o){if(null==n)return n;if(!r(n))return e(n,o);for(var i=n.length,a=t?i:-1,s=Object(n);(t?a--:++a<i)&&!1!==o(s[a],a,s););return n}}t.exports=o},{"./isArrayLike":244}],149:[function(e,t,n){function r(e){return function(t,n,r){for(var o=-1,i=Object(t),a=r(t),s=a.length;s--;){var u=a[e?s:++o];if(!1===n(i[u],u,i))break}return t}}t.exports=r},{}],150:[function(e,t,n){var r=e("./_baseIteratee"),o=e("./isArrayLike"),i=e("./keys");function a(e){return function(t,n,a){var s=Object(t);if(!o(t)){var u=r(n,3);t=i(t),n=function(e){return u(s[e],e,s)}}var c=e(t,n,a);return c>-1?s[u?t[c]:c]:void 0}}t.exports=a},{"./_baseIteratee":105,"./isArrayLike":244,"./keys":259}],151:[function(e,t,n){var r=e("./_baseRange"),o=e("./_isIterateeCall"),i=e("./toFinite");function a(e){return function(t,n,a){return a&&"number"!=typeof a&&o(t,n,a)&&(n=a=void 0),t=i(t),void 0===n?(n=t,t=0):n=i(n),a=void 0===a?t<n?1:-1:i(a),r(t,n,a,e)}}t.exports=a},{"./_baseRange":119,"./_isIterateeCall":182,"./toFinite":279}],152:[function(e,t,n){var r=e("./_Set"),o=e("./noop"),i=e("./_setToArray"),a=1/0,s=r&&1/i(new r([,-0]))[1]==a?function(e){return new r(e)}:o;t.exports=s},{"./_Set":57,"./_setToArray":212,"./noop":269}],153:[function(e,t,n){var r=e("./_getNative"),o=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();t.exports=o},{"./_getNative":163}],154:[function(e,t,n){var r=e("./_SetCache"),o=e("./_arraySome"),i=e("./_cacheHas"),a=1,s=2;function u(e,t,n,u,c,f){var d=n&a,h=e.length,l=t.length;if(h!=l&&!(d&&l>h))return!1;var p=f.get(e);if(p&&f.get(t))return p==t;var v=-1,_=!0,y=n&s?new r:void 0;for(f.set(e,t),f.set(t,e);++v<h;){var g=e[v],b=t[v];if(u)var m=d?u(b,g,v,t,e,f):u(g,b,v,e,t,f);if(void 0!==m){if(m)continue;_=!1;break}if(y){if(!o(t,(function(e,t){if(!i(y,t)&&(g===e||c(g,e,n,u,f)))return y.push(t)}))){_=!1;break}}else if(g!==b&&!c(g,b,n,u,f)){_=!1;break}}return f.delete(e),f.delete(t),_}t.exports=u},{"./_SetCache":58,"./_arraySome":72,"./_cacheHas":131}],155:[function(e,t,n){var r=e("./_Symbol"),o=e("./_Uint8Array"),i=e("./eq"),a=e("./_equalArrays"),s=e("./_mapToArray"),u=e("./_setToArray"),c=1,f=2,d="[object Boolean]",h="[object Date]",l="[object Error]",p="[object Map]",v="[object Number]",_="[object RegExp]",y="[object Set]",g="[object String]",b="[object Symbol]",m="[object ArrayBuffer]",x="[object DataView]",w=r?r.prototype:void 0,E=w?w.valueOf:void 0;function j(e,t,n,r,w,j,k){switch(n){case x:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case m:return!(e.byteLength!=t.byteLength||!j(new o(e),new o(t)));case d:case h:case v:return i(+e,+t);case l:return e.name==t.name&&e.message==t.message;case _:case g:return e==t+"";case p:var A=s;case y:var O=r&c;if(A||(A=u),e.size!=t.size&&!O)return!1;var I=k.get(e);if(I)return I==t;r|=f,k.set(e,t);var S=a(A(e),A(t),r,w,j,k);return k.delete(e),S;case b:if(E)return E.call(e)==E.call(t)}return!1}t.exports=j},{"./_Symbol":60,"./_Uint8Array":61,"./_equalArrays":154,"./_mapToArray":198,"./_setToArray":212,"./eq":231}],156:[function(e,t,n){var r=e("./_getAllKeys"),o=1,i=Object.prototype.hasOwnProperty;function a(e,t,n,a,s,u){var c=n&o,f=r(e),d=f.length;if(d!=r(t).length&&!c)return!1;for(var h=d;h--;){var l=f[h];if(!(c?l in t:i.call(t,l)))return!1}var p=u.get(e);if(p&&u.get(t))return p==t;var v=!0;u.set(e,t),u.set(t,e);for(var _=c;++h<d;){var y=e[l=f[h]],g=t[l];if(a)var b=c?a(g,y,l,t,e,u):a(y,g,l,e,t,u);if(!(void 0===b?y===g||s(y,g,n,a,u):b)){v=!1;break}_||(_="constructor"==l)}if(v&&!_){var m=e.constructor,x=t.constructor;m==x||!("constructor"in e)||!("constructor"in t)||"function"==typeof m&&m instanceof m&&"function"==typeof x&&x instanceof x||(v=!1)}return u.delete(e),u.delete(t),v}t.exports=a},{"./_getAllKeys":159}],157:[function(e,t,n){var r=e("./flatten"),o=e("./_overRest"),i=e("./_setToString");function a(e){return i(o(e,void 0,r),e+"")}t.exports=a},{"./_overRest":207,"./_setToString":213,"./flatten":235}],158:[function(t,n,r){(function(e){var t="object"==typeof e&&e&&e.Object===Object&&e;n.exports=t}).call(this,void 0!==e?e:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],159:[function(e,t,n){var r=e("./_baseGetAllKeys"),o=e("./_getSymbols"),i=e("./keys");function a(e){return r(e,i,o)}t.exports=a},{"./_baseGetAllKeys":90,"./_getSymbols":166,"./keys":259}],160:[function(e,t,n){var r=e("./_baseGetAllKeys"),o=e("./_getSymbolsIn"),i=e("./keysIn");function a(e){return r(e,i,o)}t.exports=a},{"./_baseGetAllKeys":90,"./_getSymbolsIn":167,"./keysIn":260}],161:[function(e,t,n){var r=e("./_isKeyable");function o(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}t.exports=o},{"./_isKeyable":184}],162:[function(e,t,n){var r=e("./_isStrictComparable"),o=e("./keys");function i(e){for(var t=o(e),n=t.length;n--;){var i=t[n],a=e[i];t[n]=[i,a,r(a)]}return t}t.exports=i},{"./_isStrictComparable":187,"./keys":259}],163:[function(e,t,n){var r=e("./_baseIsNative"),o=e("./_getValue");function i(e,t){var n=o(e,t);return r(n)?n:void 0}t.exports=i},{"./_baseIsNative":102,"./_getValue":169}],164:[function(e,t,n){var r=e("./_overArg")(Object.getPrototypeOf,Object);t.exports=r},{"./_overArg":206}],165:[function(e,t,n){var r=e("./_Symbol"),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,s=r?r.toStringTag:void 0;function u(e){var t=i.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var o=a.call(e);return r&&(t?e[s]=n:delete e[s]),o}t.exports=u},{"./_Symbol":60}],166:[function(e,t,n){var r=e("./_arrayFilter"),o=e("./stubArray"),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(e){return null==e?[]:(e=Object(e),r(a(e),(function(t){return i.call(e,t)})))}:o;t.exports=s},{"./_arrayFilter":65,"./stubArray":277}],167:[function(e,t,n){var r=e("./_arrayPush"),o=e("./_getPrototype"),i=e("./_getSymbols"),a=e("./stubArray"),s=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)r(t,i(e)),e=o(e);return t}:a;t.exports=s},{"./_arrayPush":70,"./_getPrototype":164,"./_getSymbols":166,"./stubArray":277}],168:[function(e,t,n){var r=e("./_DataView"),o=e("./_Map"),i=e("./_Promise"),a=e("./_Set"),s=e("./_WeakMap"),u=e("./_baseGetTag"),c=e("./_toSource"),f="[object Map]",d="[object Object]",h="[object Promise]",l="[object Set]",p="[object WeakMap]",v="[object DataView]",_=c(r),y=c(o),g=c(i),b=c(a),m=c(s),x=u;(r&&x(new r(new ArrayBuffer(1)))!=v||o&&x(new o)!=f||i&&x(i.resolve())!=h||a&&x(new a)!=l||s&&x(new s)!=p)&&(x=function(e){var t=u(e),n=t==d?e.constructor:void 0,r=n?c(n):"";if(r)switch(r){case _:return v;case y:return f;case g:return h;case b:return l;case m:return p}return t}),t.exports=x},{"./_DataView":51,"./_Map":54,"./_Promise":56,"./_Set":57,"./_WeakMap":62,"./_baseGetTag":91,"./_toSource":224}],169:[function(e,t,n){function r(e,t){return null==e?void 0:e[t]}t.exports=r},{}],170:[function(e,t,n){var r=e("./_castPath"),o=e("./isArguments"),i=e("./isArray"),a=e("./_isIndex"),s=e("./isLength"),u=e("./_toKey");function c(e,t,n){for(var c=-1,f=(t=r(t,e)).length,d=!1;++c<f;){var h=u(t[c]);if(!(d=null!=e&&n(e,h)))break;e=e[h]}return d||++c!=f?d:!!(f=null==e?0:e.length)&&s(f)&&a(h,f)&&(i(e)||o(e))}t.exports=c},{"./_castPath":133,"./_isIndex":181,"./_toKey":223,"./isArguments":242,"./isArray":243,"./isLength":249}],171:[function(e,t,n){var r=RegExp("[\\\\u200d\\\\ud800-\\\\udfff\\\\u0300-\\\\u036f\\\\ufe20-\\\\ufe2f\\\\u20d0-\\\\u20ff\\\\ufe0e\\\\ufe0f]");function o(e){return r.test(e)}t.exports=o},{}],172:[function(e,t,n){var r=e("./_nativeCreate");function o(){this.__data__=r?r(null):{},this.size=0}t.exports=o},{"./_nativeCreate":201}],173:[function(e,t,n){function r(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}t.exports=r},{}],174:[function(e,t,n){var r=e("./_nativeCreate"),o="__lodash_hash_undefined__",i=Object.prototype.hasOwnProperty;function a(e){var t=this.__data__;if(r){var n=t[e];return n===o?void 0:n}return i.call(t,e)?t[e]:void 0}t.exports=a},{"./_nativeCreate":201}],175:[function(e,t,n){var r=e("./_nativeCreate"),o=Object.prototype.hasOwnProperty;function i(e){var t=this.__data__;return r?void 0!==t[e]:o.call(t,e)}t.exports=i},{"./_nativeCreate":201}],176:[function(e,t,n){var r=e("./_nativeCreate"),o="__lodash_hash_undefined__";function i(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?o:t,this}t.exports=i},{"./_nativeCreate":201}],177:[function(e,t,n){var r=Object.prototype.hasOwnProperty;function o(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&r.call(e,"index")&&(n.index=e.index,n.input=e.input),n}t.exports=o},{}],178:[function(e,t,n){var r=e("./_cloneArrayBuffer"),o=e("./_cloneDataView"),i=e("./_cloneRegExp"),a=e("./_cloneSymbol"),s=e("./_cloneTypedArray"),u="[object Boolean]",c="[object Date]",f="[object Map]",d="[object Number]",h="[object RegExp]",l="[object Set]",p="[object String]",v="[object Symbol]",_="[object ArrayBuffer]",y="[object DataView]",g="[object Float32Array]",b="[object Float64Array]",m="[object Int8Array]",x="[object Int16Array]",w="[object Int32Array]",E="[object Uint8Array]",j="[object Uint8ClampedArray]",k="[object Uint16Array]",A="[object Uint32Array]";function O(e,t,n){var O=e.constructor;switch(t){case _:return r(e);case u:case c:return new O(+e);case y:return o(e,n);case g:case b:case m:case x:case w:case E:case j:case k:case A:return s(e,n);case f:return new O;case d:case p:return new O(e);case h:return i(e);case l:return new O;case v:return a(e)}}t.exports=O},{"./_cloneArrayBuffer":134,"./_cloneDataView":136,"./_cloneRegExp":137,"./_cloneSymbol":138,"./_cloneTypedArray":139}],179:[function(e,t,n){var r=e("./_baseCreate"),o=e("./_getPrototype"),i=e("./_isPrototype");function a(e){return"function"!=typeof e.constructor||i(e)?{}:r(o(e))}t.exports=a},{"./_baseCreate":81,"./_getPrototype":164,"./_isPrototype":186}],180:[function(e,t,n){var r=e("./_Symbol"),o=e("./isArguments"),i=e("./isArray"),a=r?r.isConcatSpreadable:void 0;function s(e){return i(e)||o(e)||!!(a&&e&&e[a])}t.exports=s},{"./_Symbol":60,"./isArguments":242,"./isArray":243}],181:[function(e,t,n){var r=9007199254740991,o=/^(?:0|[1-9]\\d*)\$/;function i(e,t){var n=typeof e;return!!(t=null==t?r:t)&&("number"==n||"symbol"!=n&&o.test(e))&&e>-1&&e%1==0&&e<t}t.exports=i},{}],182:[function(e,t,n){var r=e("./eq"),o=e("./isArrayLike"),i=e("./_isIndex"),a=e("./isObject");function s(e,t,n){if(!a(n))return!1;var s=typeof t;return!!("number"==s?o(n)&&i(t,n.length):"string"==s&&t in n)&&r(n[t],e)}t.exports=s},{"./_isIndex":181,"./eq":231,"./isArrayLike":244,"./isObject":251}],183:[function(e,t,n){var r=e("./isArray"),o=e("./isSymbol"),i=/\\.|\\[(?:[^[\\]]*|(["'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,a=/^\\w*\$/;function s(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!o(e))||a.test(e)||!i.test(e)||null!=t&&e in Object(t)}t.exports=s},{"./isArray":243,"./isSymbol":256}],184:[function(e,t,n){function r(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}t.exports=r},{}],185:[function(e,t,n){var r,o=e("./_coreJsData"),i=(r=/[^.]+\$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";function a(e){return!!i&&i in e}t.exports=a},{"./_coreJsData":146}],186:[function(e,t,n){var r=Object.prototype;function o(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||r)}t.exports=o},{}],187:[function(e,t,n){var r=e("./isObject");function o(e){return e==e&&!r(e)}t.exports=o},{"./isObject":251}],188:[function(e,t,n){function r(){this.__data__=[],this.size=0}t.exports=r},{}],189:[function(e,t,n){var r=e("./_assocIndexOf"),o=Array.prototype.splice;function i(e){var t=this.__data__,n=r(t,e);return!(n<0||(n==t.length-1?t.pop():o.call(t,n,1),--this.size,0))}t.exports=i},{"./_assocIndexOf":76}],190:[function(e,t,n){var r=e("./_assocIndexOf");function o(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}t.exports=o},{"./_assocIndexOf":76}],191:[function(e,t,n){var r=e("./_assocIndexOf");function o(e){return r(this.__data__,e)>-1}t.exports=o},{"./_assocIndexOf":76}],192:[function(e,t,n){var r=e("./_assocIndexOf");function o(e,t){var n=this.__data__,o=r(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}t.exports=o},{"./_assocIndexOf":76}],193:[function(e,t,n){var r=e("./_Hash"),o=e("./_ListCache"),i=e("./_Map");function a(){this.size=0,this.__data__={hash:new r,map:new(i||o),string:new r}}t.exports=a},{"./_Hash":52,"./_ListCache":53,"./_Map":54}],194:[function(e,t,n){var r=e("./_getMapData");function o(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}t.exports=o},{"./_getMapData":161}],195:[function(e,t,n){var r=e("./_getMapData");function o(e){return r(this,e).get(e)}t.exports=o},{"./_getMapData":161}],196:[function(e,t,n){var r=e("./_getMapData");function o(e){return r(this,e).has(e)}t.exports=o},{"./_getMapData":161}],197:[function(e,t,n){var r=e("./_getMapData");function o(e,t){var n=r(this,e),o=n.size;return n.set(e,t),this.size+=n.size==o?0:1,this}t.exports=o},{"./_getMapData":161}],198:[function(e,t,n){function r(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}t.exports=r},{}],199:[function(e,t,n){function r(e,t){return function(n){return null!=n&&n[e]===t&&(void 0!==t||e in Object(n))}}t.exports=r},{}],200:[function(e,t,n){var r=e("./memoize"),o=500;function i(e){var t=r(e,(function(e){return n.size===o&&n.clear(),e})),n=t.cache;return t}t.exports=i},{"./memoize":265}],201:[function(e,t,n){var r=e("./_getNative")(Object,"create");t.exports=r},{"./_getNative":163}],202:[function(e,t,n){var r=e("./_overArg")(Object.keys,Object);t.exports=r},{"./_overArg":206}],203:[function(e,t,n){function r(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}t.exports=r},{}],204:[function(e,t,n){var r=e("./_freeGlobal"),o="object"==typeof n&&n&&!n.nodeType&&n,i=o&&"object"==typeof t&&t&&!t.nodeType&&t,a=i&&i.exports===o&&r.process,s=function(){try{var e=i&&i.require&&i.require("util").types;return e||a&&a.binding&&a.binding("util")}catch(e){}}();t.exports=s},{"./_freeGlobal":158}],205:[function(e,t,n){var r=Object.prototype.toString;function o(e){return r.call(e)}t.exports=o},{}],206:[function(e,t,n){function r(e,t){return function(n){return e(t(n))}}t.exports=r},{}],207:[function(e,t,n){var r=e("./_apply"),o=Math.max;function i(e,t,n){return t=o(void 0===t?e.length-1:t,0),function(){for(var i=arguments,a=-1,s=o(i.length-t,0),u=Array(s);++a<s;)u[a]=i[t+a];a=-1;for(var c=Array(t+1);++a<t;)c[a]=i[a];return c[t]=n(u),r(e,this,c)}}t.exports=i},{"./_apply":63}],208:[function(e,t,n){var r=e("./_freeGlobal"),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();t.exports=i},{"./_freeGlobal":158}],209:[function(e,t,n){function r(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}t.exports=r},{}],210:[function(e,t,n){var r="__lodash_hash_undefined__";function o(e){return this.__data__.set(e,r),this}t.exports=o},{}],211:[function(e,t,n){function r(e){return this.__data__.has(e)}t.exports=r},{}],212:[function(e,t,n){function r(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}t.exports=r},{}],213:[function(e,t,n){var r=e("./_baseSetToString"),o=e("./_shortOut")(r);t.exports=o},{"./_baseSetToString":123,"./_shortOut":214}],214:[function(e,t,n){var r=800,o=16,i=Date.now;function a(e){var t=0,n=0;return function(){var a=i(),s=o-(a-n);if(n=a,s>0){if(++t>=r)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}t.exports=a},{}],215:[function(e,t,n){var r=e("./_ListCache");function o(){this.__data__=new r,this.size=0}t.exports=o},{"./_ListCache":53}],216:[function(e,t,n){function r(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}t.exports=r},{}],217:[function(e,t,n){function r(e){return this.__data__.get(e)}t.exports=r},{}],218:[function(e,t,n){function r(e){return this.__data__.has(e)}t.exports=r},{}],219:[function(e,t,n){var r=e("./_ListCache"),o=e("./_Map"),i=e("./_MapCache"),a=200;function s(e,t){var n=this.__data__;if(n instanceof r){var s=n.__data__;if(!o||s.length<a-1)return s.push([e,t]),this.size=++n.size,this;n=this.__data__=new i(s)}return n.set(e,t),this.size=n.size,this}t.exports=s},{"./_ListCache":53,"./_Map":54,"./_MapCache":55}],220:[function(e,t,n){function r(e,t,n){for(var r=n-1,o=e.length;++r<o;)if(e[r]===t)return r;return-1}t.exports=r},{}],221:[function(e,t,n){var r=e("./_asciiSize"),o=e("./_hasUnicode"),i=e("./_unicodeSize");function a(e){return o(e)?i(e):r(e)}t.exports=a},{"./_asciiSize":73,"./_hasUnicode":171,"./_unicodeSize":225}],222:[function(e,t,n){var r=e("./_memoizeCapped"),o=/[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|(["'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|\$))/g,i=/\\\\(\\\\)?/g,a=r((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(o,(function(e,n,r,o){t.push(r?o.replace(i,"\$1"):n||e)})),t}));t.exports=a},{"./_memoizeCapped":200}],223:[function(e,t,n){var r=e("./isSymbol"),o=1/0;function i(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-o?"-0":t}t.exports=i},{"./isSymbol":256}],224:[function(e,t,n){var r=Function.prototype.toString;function o(e){if(null!=e){try{return r.call(e)}catch(e){}try{return e+""}catch(e){}}return""}t.exports=o},{}],225:[function(e,t,n){var r="\\\\ud800-\\\\udfff",o="["+r+"]",i="[\\\\u0300-\\\\u036f\\\\ufe20-\\\\ufe2f\\\\u20d0-\\\\u20ff]",a="\\\\ud83c[\\\\udffb-\\\\udfff]",s="[^"+r+"]",u="(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}",c="[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]",f="(?:"+i+"|"+a+")?",d="[\\\\ufe0e\\\\ufe0f]?",h=d+f+"(?:\\\\u200d(?:"+[s,u,c].join("|")+")"+d+f+")*",l="(?:"+[s+i+"?",i,u,c,o].join("|")+")",p=RegExp(a+"(?="+a+")|"+l+h,"g");function v(e){for(var t=p.lastIndex=0;p.test(e);)++t;return t}t.exports=v},{}],226:[function(e,t,n){var r=e("./_baseClone"),o=4;function i(e){return r(e,o)}t.exports=i},{"./_baseClone":80}],227:[function(e,t,n){var r=e("./_baseClone"),o=1,i=4;function a(e){return r(e,o|i)}t.exports=a},{"./_baseClone":80}],228:[function(e,t,n){function r(e){return function(){return e}}t.exports=r},{}],229:[function(e,t,n){var r=e("./_baseRest"),o=e("./eq"),i=e("./_isIterateeCall"),a=e("./keysIn"),s=Object.prototype,u=s.hasOwnProperty,c=r((function(e,t){e=Object(e);var n=-1,r=t.length,c=r>2?t[2]:void 0;for(c&&i(t[0],t[1],c)&&(r=1);++n<r;)for(var f=t[n],d=a(f),h=-1,l=d.length;++h<l;){var p=d[h],v=e[p];(void 0===v||o(v,s[p])&&!u.call(e,p))&&(e[p]=f[p])}return e}));t.exports=c},{"./_baseRest":121,"./_isIterateeCall":182,"./eq":231,"./keysIn":260}],230:[function(e,t,n){t.exports=e("./forEach")},{"./forEach":236}],231:[function(e,t,n){function r(e,t){return e===t||e!=e&&t!=t}t.exports=r},{}],232:[function(e,t,n){var r=e("./_arrayFilter"),o=e("./_baseFilter"),i=e("./_baseIteratee"),a=e("./isArray");function s(e,t){return(a(e)?r:o)(e,i(t,3))}t.exports=s},{"./_arrayFilter":65,"./_baseFilter":84,"./_baseIteratee":105,"./isArray":243}],233:[function(e,t,n){var r=e("./_createFind")(e("./findIndex"));t.exports=r},{"./_createFind":150,"./findIndex":234}],234:[function(e,t,n){var r=e("./_baseFindIndex"),o=e("./_baseIteratee"),i=e("./toInteger"),a=Math.max;function s(e,t,n){var s=null==e?0:e.length;if(!s)return-1;var u=null==n?0:i(n);return u<0&&(u=a(s+u,0)),r(e,o(t,3),u)}t.exports=s},{"./_baseFindIndex":85,"./_baseIteratee":105,"./toInteger":280}],235:[function(e,t,n){var r=e("./_baseFlatten");function o(e){return null!=e&&e.length?r(e,1):[]}t.exports=o},{"./_baseFlatten":86}],236:[function(e,t,n){var r=e("./_arrayEach"),o=e("./_baseEach"),i=e("./_castFunction"),a=e("./isArray");function s(e,t){return(a(e)?r:o)(e,i(t))}t.exports=s},{"./_arrayEach":64,"./_baseEach":82,"./_castFunction":132,"./isArray":243}],237:[function(e,t,n){var r=e("./_baseFor"),o=e("./_castFunction"),i=e("./keysIn");function a(e,t){return null==e?e:r(e,o(t),i)}t.exports=a},{"./_baseFor":87,"./_castFunction":132,"./keysIn":260}],238:[function(e,t,n){var r=e("./_baseGet");function o(e,t,n){var o=null==e?void 0:r(e,t);return void 0===o?n:o}t.exports=o},{"./_baseGet":89}],239:[function(e,t,n){var r=e("./_baseHas"),o=e("./_hasPath");function i(e,t){return null!=e&&o(e,t,r)}t.exports=i},{"./_baseHas":93,"./_hasPath":170}],240:[function(e,t,n){var r=e("./_baseHasIn"),o=e("./_hasPath");function i(e,t){return null!=e&&o(e,t,r)}t.exports=i},{"./_baseHasIn":94,"./_hasPath":170}],241:[function(e,t,n){function r(e){return e}t.exports=r},{}],242:[function(e,t,n){var r=e("./_baseIsArguments"),o=e("./isObjectLike"),i=Object.prototype,a=i.hasOwnProperty,s=i.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(e){return o(e)&&a.call(e,"callee")&&!s.call(e,"callee")};t.exports=u},{"./_baseIsArguments":96,"./isObjectLike":252}],243:[function(e,t,n){var r=Array.isArray;t.exports=r},{}],244:[function(e,t,n){var r=e("./isFunction"),o=e("./isLength");function i(e){return null!=e&&o(e.length)&&!r(e)}t.exports=i},{"./isFunction":248,"./isLength":249}],245:[function(e,t,n){var r=e("./isArrayLike"),o=e("./isObjectLike");function i(e){return o(e)&&r(e)}t.exports=i},{"./isArrayLike":244,"./isObjectLike":252}],246:[function(e,t,n){var r=e("./_root"),o=e("./stubFalse"),i="object"==typeof n&&n&&!n.nodeType&&n,a=i&&"object"==typeof t&&t&&!t.nodeType&&t,s=a&&a.exports===i?r.Buffer:void 0,u=(s?s.isBuffer:void 0)||o;t.exports=u},{"./_root":208,"./stubFalse":278}],247:[function(e,t,n){var r=e("./_baseKeys"),o=e("./_getTag"),i=e("./isArguments"),a=e("./isArray"),s=e("./isArrayLike"),u=e("./isBuffer"),c=e("./_isPrototype"),f=e("./isTypedArray"),d="[object Map]",h="[object Set]",l=Object.prototype.hasOwnProperty;function p(e){if(null==e)return!0;if(s(e)&&(a(e)||"string"==typeof e||"function"==typeof e.splice||u(e)||f(e)||i(e)))return!e.length;var t=o(e);if(t==d||t==h)return!e.size;if(c(e))return!r(e).length;for(var n in e)if(l.call(e,n))return!1;return!0}t.exports=p},{"./_baseKeys":106,"./_getTag":168,"./_isPrototype":186,"./isArguments":242,"./isArray":243,"./isArrayLike":244,"./isBuffer":246,"./isTypedArray":257}],248:[function(e,t,n){var r=e("./_baseGetTag"),o=e("./isObject"),i="[object AsyncFunction]",a="[object Function]",s="[object GeneratorFunction]",u="[object Proxy]";function c(e){if(!o(e))return!1;var t=r(e);return t==a||t==s||t==i||t==u}t.exports=c},{"./_baseGetTag":91,"./isObject":251}],249:[function(e,t,n){var r=9007199254740991;function o(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}t.exports=o},{}],250:[function(e,t,n){var r=e("./_baseIsMap"),o=e("./_baseUnary"),i=e("./_nodeUtil"),a=i&&i.isMap,s=a?o(a):r;t.exports=s},{"./_baseIsMap":99,"./_baseUnary":127,"./_nodeUtil":204}],251:[function(e,t,n){function r(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}t.exports=r},{}],252:[function(e,t,n){function r(e){return null!=e&&"object"==typeof e}t.exports=r},{}],253:[function(e,t,n){var r=e("./_baseGetTag"),o=e("./_getPrototype"),i=e("./isObjectLike"),a="[object Object]",s=Function.prototype,u=Object.prototype,c=s.toString,f=u.hasOwnProperty,d=c.call(Object);function h(e){if(!i(e)||r(e)!=a)return!1;var t=o(e);if(null===t)return!0;var n=f.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&c.call(n)==d}t.exports=h},{"./_baseGetTag":91,"./_getPrototype":164,"./isObjectLike":252}],254:[function(e,t,n){var r=e("./_baseIsSet"),o=e("./_baseUnary"),i=e("./_nodeUtil"),a=i&&i.isSet,s=a?o(a):r;t.exports=s},{"./_baseIsSet":103,"./_baseUnary":127,"./_nodeUtil":204}],255:[function(e,t,n){var r=e("./_baseGetTag"),o=e("./isArray"),i=e("./isObjectLike"),a="[object String]";function s(e){return"string"==typeof e||!o(e)&&i(e)&&r(e)==a}t.exports=s},{"./_baseGetTag":91,"./isArray":243,"./isObjectLike":252}],256:[function(e,t,n){var r=e("./_baseGetTag"),o=e("./isObjectLike"),i="[object Symbol]";function a(e){return"symbol"==typeof e||o(e)&&r(e)==i}t.exports=a},{"./_baseGetTag":91,"./isObjectLike":252}],257:[function(e,t,n){var r=e("./_baseIsTypedArray"),o=e("./_baseUnary"),i=e("./_nodeUtil"),a=i&&i.isTypedArray,s=a?o(a):r;t.exports=s},{"./_baseIsTypedArray":104,"./_baseUnary":127,"./_nodeUtil":204}],258:[function(e,t,n){function r(e){return void 0===e}t.exports=r},{}],259:[function(e,t,n){var r=e("./_arrayLikeKeys"),o=e("./_baseKeys"),i=e("./isArrayLike");function a(e){return i(e)?r(e):o(e)}t.exports=a},{"./_arrayLikeKeys":68,"./_baseKeys":106,"./isArrayLike":244}],260:[function(e,t,n){var r=e("./_arrayLikeKeys"),o=e("./_baseKeysIn"),i=e("./isArrayLike");function a(e){return i(e)?r(e,!0):o(e)}t.exports=a},{"./_arrayLikeKeys":68,"./_baseKeysIn":107,"./isArrayLike":244}],261:[function(e,t,n){function r(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}t.exports=r},{}],262:[function(e,t,n){var r=e("./_arrayMap"),o=e("./_baseIteratee"),i=e("./_baseMap"),a=e("./isArray");function s(e,t){return(a(e)?r:i)(e,o(t,3))}t.exports=s},{"./_arrayMap":69,"./_baseIteratee":105,"./_baseMap":109,"./isArray":243}],263:[function(e,t,n){var r=e("./_baseAssignValue"),o=e("./_baseForOwn"),i=e("./_baseIteratee");function a(e,t){var n={};return t=i(t,3),o(e,(function(e,o,i){r(n,o,t(e,o,i))})),n}t.exports=a},{"./_baseAssignValue":79,"./_baseForOwn":88,"./_baseIteratee":105}],264:[function(e,t,n){var r=e("./_baseExtremum"),o=e("./_baseGt"),i=e("./identity");function a(e){return e&&e.length?r(e,i,o):void 0}t.exports=a},{"./_baseExtremum":83,"./_baseGt":92,"./identity":241}],265:[function(e,t,n){var r=e("./_MapCache"),o="Expected a function";function i(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError(o);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(i.Cache||r),n}i.Cache=r,t.exports=i},{"./_MapCache":55}],266:[function(e,t,n){var r=e("./_baseMerge"),o=e("./_createAssigner")((function(e,t,n){r(e,t,n)}));t.exports=o},{"./_baseMerge":112,"./_createAssigner":147}],267:[function(e,t,n){var r=e("./_baseExtremum"),o=e("./_baseLt"),i=e("./identity");function a(e){return e&&e.length?r(e,i,o):void 0}t.exports=a},{"./_baseExtremum":83,"./_baseLt":108,"./identity":241}],268:[function(e,t,n){var r=e("./_baseExtremum"),o=e("./_baseIteratee"),i=e("./_baseLt");function a(e,t){return e&&e.length?r(e,o(t,2),i):void 0}t.exports=a},{"./_baseExtremum":83,"./_baseIteratee":105,"./_baseLt":108}],269:[function(e,t,n){function r(){}t.exports=r},{}],270:[function(e,t,n){var r=e("./_root"),o=function(){return r.Date.now()};t.exports=o},{"./_root":208}],271:[function(e,t,n){var r=e("./_basePick"),o=e("./_flatRest")((function(e,t){return null==e?{}:r(e,t)}));t.exports=o},{"./_basePick":115,"./_flatRest":157}],272:[function(e,t,n){var r=e("./_baseProperty"),o=e("./_basePropertyDeep"),i=e("./_isKey"),a=e("./_toKey");function s(e){return i(e)?r(a(e)):o(e)}t.exports=s},{"./_baseProperty":117,"./_basePropertyDeep":118,"./_isKey":183,"./_toKey":223}],273:[function(e,t,n){var r=e("./_createRange")();t.exports=r},{"./_createRange":151}],274:[function(e,t,n){var r=e("./_arrayReduce"),o=e("./_baseEach"),i=e("./_baseIteratee"),a=e("./_baseReduce"),s=e("./isArray");function u(e,t,n){var u=s(e)?r:a,c=arguments.length<3;return u(e,i(t,4),n,c,o)}t.exports=u},{"./_arrayReduce":71,"./_baseEach":82,"./_baseIteratee":105,"./_baseReduce":120,"./isArray":243}],275:[function(e,t,n){var r=e("./_baseKeys"),o=e("./_getTag"),i=e("./isArrayLike"),a=e("./isString"),s=e("./_stringSize"),u="[object Map]",c="[object Set]";function f(e){if(null==e)return 0;if(i(e))return a(e)?s(e):e.length;var t=o(e);return t==u||t==c?e.size:r(e).length}t.exports=f},{"./_baseKeys":106,"./_getTag":168,"./_stringSize":221,"./isArrayLike":244,"./isString":255}],276:[function(e,t,n){var r=e("./_baseFlatten"),o=e("./_baseOrderBy"),i=e("./_baseRest"),a=e("./_isIterateeCall"),s=i((function(e,t){if(null==e)return[];var n=t.length;return n>1&&a(e,t[0],t[1])?t=[]:n>2&&a(t[0],t[1],t[2])&&(t=[t[0]]),o(e,r(t,1),[])}));t.exports=s},{"./_baseFlatten":86,"./_baseOrderBy":114,"./_baseRest":121,"./_isIterateeCall":182}],277:[function(e,t,n){function r(){return[]}t.exports=r},{}],278:[function(e,t,n){function r(){return!1}t.exports=r},{}],279:[function(e,t,n){var r=e("./toNumber"),o=1/0,i=17976931348623157e292;function a(e){return e?(e=r(e))===o||e===-o?(e<0?-1:1)*i:e==e?e:0:0===e?e:0}t.exports=a},{"./toNumber":281}],280:[function(e,t,n){var r=e("./toFinite");function o(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}t.exports=o},{"./toFinite":279}],281:[function(e,t,n){var r=e("./isObject"),o=e("./isSymbol"),i=NaN,a=/^\\s+|\\s+\$/g,s=/^[-+]0x[0-9a-f]+\$/i,u=/^0b[01]+\$/i,c=/^0o[0-7]+\$/i,f=parseInt;function d(e){if("number"==typeof e)return e;if(o(e))return i;if(r(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=r(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(a,"");var n=u.test(e);return n||c.test(e)?f(e.slice(2),n?2:8):s.test(e)?i:+e}t.exports=d},{"./isObject":251,"./isSymbol":256}],282:[function(e,t,n){var r=e("./_copyObject"),o=e("./keysIn");function i(e){return r(e,o(e))}t.exports=i},{"./_copyObject":143,"./keysIn":260}],283:[function(e,t,n){var r=e("./_baseToString");function o(e){return null==e?"":r(e)}t.exports=o},{"./_baseToString":126}],284:[function(e,t,n){var r=e("./_arrayEach"),o=e("./_baseCreate"),i=e("./_baseForOwn"),a=e("./_baseIteratee"),s=e("./_getPrototype"),u=e("./isArray"),c=e("./isBuffer"),f=e("./isFunction"),d=e("./isObject"),h=e("./isTypedArray");function l(e,t,n){var l=u(e),p=l||c(e)||h(e);if(t=a(t,4),null==n){var v=e&&e.constructor;n=p?l?new v:[]:d(e)&&f(v)?o(s(e)):{}}return(p?r:i)(e,(function(e,r,o){return t(n,e,r,o)})),n}t.exports=l},{"./_arrayEach":64,"./_baseCreate":81,"./_baseForOwn":88,"./_baseIteratee":105,"./_getPrototype":164,"./isArray":243,"./isBuffer":246,"./isFunction":248,"./isObject":251,"./isTypedArray":257}],285:[function(e,t,n){var r=e("./_baseFlatten"),o=e("./_baseRest"),i=e("./_baseUniq"),a=e("./isArrayLikeObject"),s=o((function(e){return i(r(e,1,a,!0))}));t.exports=s},{"./_baseFlatten":86,"./_baseRest":121,"./_baseUniq":128,"./isArrayLikeObject":245}],286:[function(e,t,n){var r=e("./toString"),o=0;function i(e){var t=++o;return r(e)+t}t.exports=i},{"./toString":283}],287:[function(e,t,n){var r=e("./_baseValues"),o=e("./keys");function i(e){return null==e?[]:r(e,o(e))}t.exports=i},{"./_baseValues":129,"./keys":259}],288:[function(e,t,n){var r=e("./_assignValue"),o=e("./_baseZipObject");function i(e,t){return o(e||[],t||[],r)}t.exports=i},{"./_assignValue":75,"./_baseZipObject":130}]},{},[1])(1);var r=n.exports,o={exports:{}};function i(e,t){var n=e.subgraphs,o=e.nodes,i=e.links,a=e.hierarchy,s=new r.graphlib.Graph({multigraph:!0,compound:!0,directed:!1!==t.digraph}).setGraph(t).setDefaultNodeLabel((function(){return{}})).setDefaultEdgeLabel((function(){return{}}));n.forEach((function(e){s.setNode(e.id,e)})),o.forEach((function(e){s.setNode(e.id,e)})),i.forEach((function(e){s.setEdge(e.source.id,e.target.id,e,e.id)})),a.forEach((function(e){s.setParent(e.child,e.parent)})),r.layout(s,{debugTiming:!1});var u=-s.graph().width/2||0,c=-s.graph().height/2;return s.nodes().forEach((function(e){var t=s.node(e);t.x+=u,t.y+=c})),s.edges().forEach((function(e){var t=s.edge(e);t.points=t.points.map((function(e){return[e.x+u,e.y+c]}))})),{subgraphs:n,nodes:o,links:i}}
|
|
40
|
-
/*!
|
|
41
|
-
* @overview es6-promise - a tiny implementation of Promises/A+.
|
|
42
|
-
* @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
|
|
43
|
-
* @license Licensed under MIT license
|
|
44
|
-
* See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE
|
|
45
|
-
* @version v4.2.8+1e68dce6
|
|
46
|
-
*/
|
|
47
|
-
!function(t){t.exports=function(){function t(e){var t=typeof e;return null!==e&&("object"===t||"function"===t)}function n(e){return"function"==typeof e}var r=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},o=0,i=void 0,a=void 0,s=function(e,t){m[o]=e,m[o+1]=t,2===(o+=2)&&(a?a(x):E())};function u(e){a=e}function c(e){s=e}var f="undefined"!=typeof window?window:void 0,d=f||{},h=d.MutationObserver||d.WebKitMutationObserver,l="undefined"==typeof self&&"undefined"!=typeof process&&"[object process]"==={}.toString.call(process),p="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function v(){return function(){return process.nextTick(x)}}function _(){return void 0!==i?function(){i(x)}:b()}function y(){var e=0,t=new h(x),n=document.createTextNode("");return t.observe(n,{characterData:!0}),function(){n.data=e=++e%2}}function g(){var e=new MessageChannel;return e.port1.onmessage=x,function(){return e.port2.postMessage(0)}}function b(){var e=setTimeout;return function(){return e(x,1)}}var m=new Array(1e3);function x(){for(var e=0;e<o;e+=2)(0,m[e])(m[e+1]),m[e]=void 0,m[e+1]=void 0;o=0}function w(){try{var e=Function("return this")().require("vertx");return i=e.runOnLoop||e.runOnContext,_()}catch(e){return b()}}var E=void 0;function j(e,t){var n=this,r=new this.constructor(O);void 0===r[A]&&Y(r);var o=n._state;if(o){var i=arguments[o-1];s((function(){return V(o,r,i,n._result)}))}else U(n,r,e,t);return r}function k(e){var t=this;if(e&&"object"==typeof e&&e.constructor===t)return e;var n=new t(O);return D(n,e),n}E=l?v():h?y():p?g():void 0===f?w():b();var A=Math.random().toString(36).substring(2);function O(){}var I=void 0,S=1,C=2;function N(){return new TypeError("You cannot resolve a promise with itself")}function T(){return new TypeError("A promises callback cannot return that same promise.")}function M(e,t,n,r){try{e.call(t,n,r)}catch(e){return e}}function L(e,t,n){s((function(e){var r=!1,o=M(n,t,(function(n){r||(r=!0,t!==n?D(e,n):G(e,n))}),(function(t){r||(r=!0,R(e,t))}),"Settle: "+(e._label||" unknown promise"));!r&&o&&(r=!0,R(e,o))}),e)}function P(e,t){t._state===S?G(e,t._result):t._state===C?R(e,t._result):U(t,void 0,(function(t){return D(e,t)}),(function(t){return R(e,t)}))}function F(e,t,r){t.constructor===e.constructor&&r===j&&t.constructor.resolve===k?P(e,t):void 0===r?G(e,t):n(r)?L(e,t,r):G(e,t)}function D(e,n){if(e===n)R(e,N());else if(t(n)){var r=void 0;try{r=n.then}catch(t){return void R(e,t)}F(e,n,r)}else G(e,n)}function B(e){e._onerror&&e._onerror(e._result),z(e)}function G(e,t){e._state===I&&(e._result=t,e._state=S,0!==e._subscribers.length&&s(z,e))}function R(e,t){e._state===I&&(e._state=C,e._result=t,s(B,e))}function U(e,t,n,r){var o=e._subscribers,i=o.length;e._onerror=null,o[i]=t,o[i+S]=n,o[i+C]=r,0===i&&e._state&&s(z,e)}function z(e){var t=e._subscribers,n=e._state;if(0!==t.length){for(var r=void 0,o=void 0,i=e._result,a=0;a<t.length;a+=3)r=t[a],o=t[a+n],r?V(n,r,o,i):o(i);e._subscribers.length=0}}function V(e,t,r,o){var i=n(r),a=void 0,s=void 0,u=!0;if(i){try{a=r(o)}catch(e){u=!1,s=e}if(t===a)return void R(t,T())}else a=o;t._state!==I||(i&&u?D(t,a):!1===u?R(t,s):e===S?G(t,a):e===C&&R(t,a))}function q(e,t){try{t((function(t){D(e,t)}),(function(t){R(e,t)}))}catch(t){R(e,t)}}var K=0;function H(){return K++}function Y(e){e[A]=K++,e._state=void 0,e._result=void 0,e._subscribers=[]}function \$(){return new Error("Array Methods must be provided an Array")}var W=function(){function e(e,t){this._instanceConstructor=e,this.promise=new e(O),this.promise[A]||Y(this.promise),r(t)?(this.length=t.length,this._remaining=t.length,this._result=new Array(this.length),0===this.length?G(this.promise,this._result):(this.length=this.length||0,this._enumerate(t),0===this._remaining&&G(this.promise,this._result))):R(this.promise,\$())}return e.prototype._enumerate=function(e){for(var t=0;this._state===I&&t<e.length;t++)this._eachEntry(e[t],t)},e.prototype._eachEntry=function(e,t){var n=this._instanceConstructor,r=n.resolve;if(r===k){var o=void 0,i=void 0,a=!1;try{o=e.then}catch(e){a=!0,i=e}if(o===j&&e._state!==I)this._settledAt(e._state,t,e._result);else if("function"!=typeof o)this._remaining--,this._result[t]=e;else if(n===te){var s=new n(O);a?R(s,i):F(s,e,o),this._willSettleAt(s,t)}else this._willSettleAt(new n((function(t){return t(e)})),t)}else this._willSettleAt(r(e),t)},e.prototype._settledAt=function(e,t,n){var r=this.promise;r._state===I&&(this._remaining--,e===C?R(r,n):this._result[t]=n),0===this._remaining&&G(r,this._result)},e.prototype._willSettleAt=function(e,t){var n=this;U(e,void 0,(function(e){return n._settledAt(S,t,e)}),(function(e){return n._settledAt(C,t,e)}))},e}();function J(e){return new W(this,e).promise}function X(e){var t=this;return r(e)?new t((function(n,r){for(var o=e.length,i=0;i<o;i++)t.resolve(e[i]).then(n,r)})):new t((function(e,t){return t(new TypeError("You must pass an array to race."))}))}function Z(e){var t=new this(O);return R(t,e),t}function Q(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function ee(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}var te=function(){function e(t){this[A]=H(),this._result=this._state=void 0,this._subscribers=[],O!==t&&("function"!=typeof t&&Q(),this instanceof e?q(this,t):ee())}return e.prototype.catch=function(e){return this.then(null,e)},e.prototype.finally=function(e){var t=this,r=t.constructor;return n(e)?t.then((function(t){return r.resolve(e()).then((function(){return t}))}),(function(t){return r.resolve(e()).then((function(){throw t}))})):t.then(e,e)},e}();function ne(){var t=void 0;if(void 0!==e)t=e;else if("undefined"!=typeof self)t=self;else try{t=Function("return this")()}catch(e){throw new Error("polyfill failed because global object is unavailable in this environment")}var n=t.Promise;if(n){var r=null;try{r=Object.prototype.toString.call(n.resolve())}catch(e){}if("[object Promise]"===r&&!n.cast)return}t.Promise=te}return te.prototype.then=j,te.all=J,te.race=X,te.resolve=k,te.reject=Z,te._setScheduler=u,te._setAsap=c,te._asap=s,te.polyfill=ne,te.Promise=te,te}()}(o),o.exports.polyfill(),self.onmessage=function(e){var t=i.apply(void 0,e.data);self.postMessage(t)}}();`;
|
|
48
|
-
|
|
49
|
-
const workerBlob = new Blob([workerCode], { type: "application/javascript" });
|
|
50
|
-
const workerUrl = URL.createObjectURL(workerBlob);
|
|
51
|
-
const worker = new Worker(workerUrl);
|
|
12
|
+
const worker = new DagreWorker();
|
|
52
13
|
const response = new Promise<string>(resolve => {
|
|
53
14
|
worker.onmessage = event => {
|
|
54
15
|
resolve(event.data);
|
|
55
16
|
worker.terminate();
|
|
56
|
-
URL.revokeObjectURL(workerUrl);
|
|
57
17
|
};
|
|
58
18
|
worker.postMessage([data, options]);
|
|
59
19
|
});
|
|
@@ -1,53 +1,17 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
export interface Link {
|
|
7
|
-
id: string;
|
|
8
|
-
source: Node;
|
|
9
|
-
target: Node;
|
|
10
|
-
}
|
|
1
|
+
import { type Data, type Options } from "./workers/forceDirectedOptions.ts";
|
|
2
|
+
// @ts-ignore
|
|
3
|
+
import ForceDirectedWorker from "./workers/forceDirected.ts?worker&inline";
|
|
11
4
|
|
|
12
|
-
export
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export interface Options {
|
|
18
|
-
alpha: number;
|
|
19
|
-
alphaMin: number;
|
|
20
|
-
alphaDecay: number;
|
|
21
|
-
velocityDecay: number;
|
|
22
|
-
repulsionStrength: number;
|
|
23
|
-
linkDistance: number;
|
|
24
|
-
linkStrength: number;
|
|
25
|
-
iterations: number;
|
|
26
|
-
pinCentroid: boolean;
|
|
27
|
-
forceStrength: number;
|
|
28
|
-
distanceMin: number;
|
|
29
|
-
distanceMax: number;
|
|
30
|
-
}
|
|
5
|
+
export {
|
|
6
|
+
type Options
|
|
7
|
+
};
|
|
31
8
|
|
|
32
9
|
export function forceDirected(data: Data, options: Options) {
|
|
33
|
-
|
|
34
|
-
const workerCode = `var forceDirected=function(t){"use strict";function n(t){return function(){return t}}function e(){return 1e-6*(Math.random()-.5)}function r(t,n,e,r){if(isNaN(n)||isNaN(e))return t;var i,o,s,u,a,c,f,l,h,v=t._root,y={data:r},p=t._x0,_=t._y0,d=t._x1,g=t._y1;if(!v)return t._root=y,t;for(;v.length;)if((c=n>=(o=(p+d)/2))?p=o:d=o,(f=e>=(s=(_+g)/2))?_=s:g=s,i=v,!(v=v[l=f<<1|c]))return i[l]=y,t;if(u=+t._x.call(null,v.data),a=+t._y.call(null,v.data),n===u&&e===a)return y.next=v,i?i[l]=y:t._root=y,t;do{i=i?i[l]=new Array(4):t._root=new Array(4),(c=n>=(o=(p+d)/2))?p=o:d=o,(f=e>=(s=(_+g)/2))?_=s:g=s}while((l=f<<1|c)==(h=(a>=s)<<1|u>=o));return i[h]=v,i[l]=y,t}function i(t,n,e,r,i){this.node=t,this.x0=n,this.y0=e,this.x1=r,this.y1=i}function o(t){return t[0]}function s(t){return t[1]}function u(t,n,e){var r=new a(null==n?o:n,null==e?s:e,NaN,NaN,NaN,NaN);return null==t?r:r.addAll(t)}function a(t,n,e,r,i,o){this._x=t,this._y=n,this._x0=e,this._y0=r,this._x1=i,this._y1=o,this._root=void 0}function c(t){for(var n={data:t.data},e=n;t=t.next;)e=e.next={data:t.data};return n}var f=u.prototype=a.prototype;f.copy=function(){var t,n,e=new a(this._x,this._y,this._x0,this._y0,this._x1,this._y1),r=this._root;if(!r)return e;if(!r.length)return e._root=c(r),e;for(t=[{source:r,target:e._root=new Array(4)}];r=t.pop();)for(var i=0;i<4;++i)(n=r.source[i])&&(n.length?t.push({source:n,target:r.target[i]=new Array(4)}):r.target[i]=c(n));return e},f.add=function(t){var n=+this._x.call(null,t),e=+this._y.call(null,t);return r(this.cover(n,e),n,e,t)},f.addAll=function(t){var n,e,i,o,s=t.length,u=new Array(s),a=new Array(s),c=1/0,f=1/0,l=-1/0,h=-1/0;for(e=0;e<s;++e)isNaN(i=+this._x.call(null,n=t[e]))||isNaN(o=+this._y.call(null,n))||(u[e]=i,a[e]=o,i<c&&(c=i),i>l&&(l=i),o<f&&(f=o),o>h&&(h=o));if(c>l||f>h)return this;for(this.cover(c,f).cover(l,h),e=0;e<s;++e)r(this,u[e],a[e],t[e]);return this},f.cover=function(t,n){if(isNaN(t=+t)||isNaN(n=+n))return this;var e=this._x0,r=this._y0,i=this._x1,o=this._y1;if(isNaN(e))i=(e=Math.floor(t))+1,o=(r=Math.floor(n))+1;else{for(var s,u,a=i-e,c=this._root;e>t||t>=i||r>n||n>=o;)switch(u=(n<r)<<1|t<e,(s=new Array(4))[u]=c,c=s,a*=2,u){case 0:i=e+a,o=r+a;break;case 1:e=i-a,o=r+a;break;case 2:i=e+a,r=o-a;break;case 3:e=i-a,r=o-a}this._root&&this._root.length&&(this._root=c)}return this._x0=e,this._y0=r,this._x1=i,this._y1=o,this},f.data=function(){var t=[];return this.visit((function(n){if(!n.length)do{t.push(n.data)}while(n=n.next)})),t},f.extent=function(t){return arguments.length?this.cover(+t[0][0],+t[0][1]).cover(+t[1][0],+t[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]},f.find=function(t,n,e){var r,o,s,u,a,c,f,l=this._x0,h=this._y0,v=this._x1,y=this._y1,p=[],_=this._root;for(_&&p.push(new i(_,l,h,v,y)),null==e?e=1/0:(l=t-e,h=n-e,v=t+e,y=n+e,e*=e);c=p.pop();)if(!(!(_=c.node)||(o=c.x0)>v||(s=c.y0)>y||(u=c.x1)<l||(a=c.y1)<h))if(_.length){var d=(o+u)/2,g=(s+a)/2;p.push(new i(_[3],d,g,u,a),new i(_[2],o,g,d,a),new i(_[1],d,s,u,g),new i(_[0],o,s,d,g)),(f=(n>=g)<<1|t>=d)&&(c=p[p.length-1],p[p.length-1]=p[p.length-1-f],p[p.length-1-f]=c)}else{var x=t-+this._x.call(null,_.data),w=n-+this._y.call(null,_.data),m=x*x+w*w;if(m<e){var b=Math.sqrt(e=m);l=t-b,h=n-b,v=t+b,y=n+b,r=_.data}}return r},f.remove=function(t){if(isNaN(o=+this._x.call(null,t))||isNaN(s=+this._y.call(null,t)))return this;var n,e,r,i,o,s,u,a,c,f,l,h,v=this._root,y=this._x0,p=this._y0,_=this._x1,d=this._y1;if(!v)return this;if(v.length)for(;;){if((c=o>=(u=(y+_)/2))?y=u:_=u,(f=s>=(a=(p+d)/2))?p=a:d=a,n=v,!(v=v[l=f<<1|c]))return this;if(!v.length)break;(n[l+1&3]||n[l+2&3]||n[l+3&3])&&(e=n,h=l)}for(;v.data!==t;)if(r=v,!(v=v.next))return this;return(i=v.next)&&delete v.next,r?(i?r.next=i:delete r.next,this):n?(i?n[l]=i:delete n[l],(v=n[0]||n[1]||n[2]||n[3])&&v===(n[3]||n[2]||n[1]||n[0])&&!v.length&&(e?e[h]=v:this._root=v),this):(this._root=i,this)},f.removeAll=function(t){for(var n=0,e=t.length;n<e;++n)this.remove(t[n]);return this},f.root=function(){return this._root},f.size=function(){var t=0;return this.visit((function(n){if(!n.length)do{++t}while(n=n.next)})),t},f.visit=function(t){var n,e,r,o,s,u,a=[],c=this._root;for(c&&a.push(new i(c,this._x0,this._y0,this._x1,this._y1));n=a.pop();)if(!t(c=n.node,r=n.x0,o=n.y0,s=n.x1,u=n.y1)&&c.length){var f=(r+s)/2,l=(o+u)/2;(e=c[3])&&a.push(new i(e,f,l,s,u)),(e=c[2])&&a.push(new i(e,r,l,f,u)),(e=c[1])&&a.push(new i(e,f,o,s,l)),(e=c[0])&&a.push(new i(e,r,o,f,l))}return this},f.visitAfter=function(t){var n,e=[],r=[];for(this._root&&e.push(new i(this._root,this._x0,this._y0,this._x1,this._y1));n=e.pop();){var o=n.node;if(o.length){var s,u=n.x0,a=n.y0,c=n.x1,f=n.y1,l=(u+c)/2,h=(a+f)/2;(s=o[0])&&e.push(new i(s,u,a,l,h)),(s=o[1])&&e.push(new i(s,l,a,c,h)),(s=o[2])&&e.push(new i(s,u,h,l,f)),(s=o[3])&&e.push(new i(s,l,h,c,f))}r.push(n)}for(;n=r.pop();)t(n.node,n.x0,n.y0,n.x1,n.y1);return this},f.x=function(t){return arguments.length?(this._x=t,this):this._x},f.y=function(t){return arguments.length?(this._y=t,this):this._y};var l="\$";function h(){}function v(t,n){var e=new h;if(t instanceof h)t.each((function(t,n){e.set(n,t)}));else if(Array.isArray(t)){var r,i=-1,o=t.length;if(null==n)for(;++i<o;)e.set(i,t[i]);else for(;++i<o;)e.set(n(r=t[i],i,t),r)}else if(t)for(var s in t)e.set(s,t[s]);return e}function y(){}h.prototype=v.prototype={constructor:h,has:function(t){return l+t in this},get:function(t){return this[l+t]},set:function(t,n){return this[l+t]=n,this},remove:function(t){var n=l+t;return n in this&&delete this[n]},clear:function(){for(var t in this)t[0]===l&&delete this[t]},keys:function(){var t=[];for(var n in this)n[0]===l&&t.push(n.slice(1));return t},values:function(){var t=[];for(var n in this)n[0]===l&&t.push(this[n]);return t},entries:function(){var t=[];for(var n in this)n[0]===l&&t.push({key:n.slice(1),value:this[n]});return t},size:function(){var t=0;for(var n in this)n[0]===l&&++t;return t},empty:function(){for(var t in this)if(t[0]===l)return!1;return!0},each:function(t){for(var n in this)n[0]===l&&t(this[n],n.slice(1),this)}};var p=v.prototype;function _(t){return t.index}function d(t,n){var e=t.get(n);if(!e)throw new Error("missing: "+n);return e}y.prototype={constructor:y,has:p.has,add:function(t){return this[l+(t+="")]=t,this},remove:p.remove,clear:p.clear,values:p.keys,size:p.size,empty:p.empty,each:p.each};var g={value:function(){}};function x(){for(var t,n=0,e=arguments.length,r={};n<e;++n){if(!(t=arguments[n]+"")||t in r||/[\\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new w(r)}function w(t){this._=t}function m(t,n){for(var e,r=0,i=t.length;r<i;++r)if((e=t[r]).name===n)return e.value}function b(t,n,e){for(var r=0,i=t.length;r<i;++r)if(t[r].name===n){t[r]=g,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=e&&t.push({name:n,value:e}),t}w.prototype=x.prototype={constructor:w,on:function(t,n){var e,r,i=this._,o=(r=i,(t+"").trim().split(/^|\\s+/).map((function(t){var n="",e=t.indexOf(".");if(e>=0&&(n=t.slice(e+1),t=t.slice(0,e)),t&&!r.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))),s=-1,u=o.length;if(!(arguments.length<2)){if(null!=n&&"function"!=typeof n)throw new Error("invalid callback: "+n);for(;++s<u;)if(e=(t=o[s]).type)i[e]=b(i[e],t.name,n);else if(null==n)for(e in i)i[e]=b(i[e],t.name,null);return this}for(;++s<u;)if((e=(t=o[s]).type)&&(e=m(i[e],t.name)))return e},copy:function(){var t={},n=this._;for(var e in n)t[e]=n[e].slice();return new w(t)},call:function(t,n){if((e=arguments.length-2)>0)for(var e,r,i=new Array(e),o=0;o<e;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=0,e=(r=this._[t]).length;o<e;++o)r[o].value.apply(n,i)},apply:function(t,n,e){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(n,e)}};var A,N,M=0,k=0,E=0,T=0,j=0,S=0,q="object"==typeof performance&&performance.now?performance:Date,D="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function O(){return j||(D(P),j=q.now()+S)}function P(){j=0}function z(){this._call=this._time=this._next=null}function C(t,n,e){var r=new z;return r.restart(t,n,e),r}function F(){j=(T=q.now())+S,M=k=0;try{!function(){O(),++M;for(var t,n=A;n;)(t=j-n._time)>=0&&n._call.call(null,t),n=n._next;--M}()}finally{M=0,function(){var t,n,e=A,r=1/0;for(;e;)e._call?(r>e._time&&(r=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:A=n);N=t,Y(r)}(),j=0}}function I(){var t=q.now(),n=t-T;n>1e3&&(S-=n,T=t)}function Y(t){M||(k&&(k=clearTimeout(k)),t-j>24?(t<1/0&&(k=setTimeout(F,t-q.now()-S)),E&&(E=clearInterval(E))):(E||(T=q.now(),E=setInterval(I,1e3)),M=1,D(F)))}function K(t){return t.x}function L(t){return t.y}z.prototype=C.prototype={constructor:z,restart:function(t,n,e){if("function"!=typeof t)throw new TypeError("callback is not a function");e=(null==e?O():+e)+(null==n?0:+n),this._next||N===this||(N?N._next=this:A=this,N=this),this._call=t,this._time=e,Y()},stop:function(){this._call&&(this._call=null,this._time=1/0,Y())}};var U=Math.PI*(3-Math.sqrt(5));var W="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};var \$={exports:{}};
|
|
35
|
-
/*!
|
|
36
|
-
* @overview es6-promise - a tiny implementation of Promises/A+.
|
|
37
|
-
* @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
|
|
38
|
-
* @license Licensed under MIT license
|
|
39
|
-
* See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE
|
|
40
|
-
* @version v4.2.8+1e68dce6
|
|
41
|
-
*/function B(t,r){var i=t.nodes,o=t.links,s=function(t){var r,i,o,s,u,a=_,c=function(t){return 1/Math.min(s[t.source.index],s[t.target.index])},f=n(30),l=1;function h(n){for(var o=0,s=t.length;o<l;++o)for(var a,c,f,h,v,y,p,_=0;_<s;++_)c=(a=t[_]).source,h=(f=a.target).x+f.vx-c.x-c.vx||e(),v=f.y+f.vy-c.y-c.vy||e(),h*=y=((y=Math.sqrt(h*h+v*v))-i[_])/y*n*r[_],v*=y,f.vx-=h*(p=u[_]),f.vy-=v*p,c.vx+=h*(p=1-p),c.vy+=v*p}function y(){if(o){var n,e,c=o.length,f=t.length,l=v(o,a);for(n=0,s=new Array(c);n<f;++n)(e=t[n]).index=n,"object"!=typeof e.source&&(e.source=d(l,e.source)),"object"!=typeof e.target&&(e.target=d(l,e.target)),s[e.source.index]=(s[e.source.index]||0)+1,s[e.target.index]=(s[e.target.index]||0)+1;for(n=0,u=new Array(f);n<f;++n)e=t[n],u[n]=s[e.source.index]/(s[e.source.index]+s[e.target.index]);r=new Array(f),p(),i=new Array(f),g()}}function p(){if(o)for(var n=0,e=t.length;n<e;++n)r[n]=+c(t[n],n,t)}function g(){if(o)for(var n=0,e=t.length;n<e;++n)i[n]=+f(t[n],n,t)}return null==t&&(t=[]),h.initialize=function(t){o=t,y()},h.links=function(n){return arguments.length?(t=n,y(),h):t},h.id=function(t){return arguments.length?(a=t,h):a},h.iterations=function(t){return arguments.length?(l=+t,h):l},h.strength=function(t){return arguments.length?(c="function"==typeof t?t:n(+t),p(),h):c},h.distance=function(t){return arguments.length?(f="function"==typeof t?t:n(+t),g(),h):f},h}(o).id((function(t){return t.id})).distance(r.linkDistance).strength(r.linkStrength),a=function(){var t,r,i,o,s=n(-30),a=1,c=1/0,f=.81;function l(n){var e,o=t.length,s=u(t,K,L).visitAfter(v);for(i=n,e=0;e<o;++e)r=t[e],s.visit(y)}function h(){if(t){var n,e,r=t.length;for(o=new Array(r),n=0;n<r;++n)e=t[n],o[e.index]=+s(e,n,t)}}function v(t){var n,e,r,i,s,u=0,a=0;if(t.length){for(r=i=s=0;s<4;++s)(n=t[s])&&(e=Math.abs(n.value))&&(u+=n.value,a+=e,r+=e*n.x,i+=e*n.y);t.x=r/a,t.y=i/a}else{(n=t).x=n.data.x,n.y=n.data.y;do{u+=o[n.data.index]}while(n=n.next)}t.value=u}function y(t,n,s,u){if(!t.value)return!0;var l=t.x-r.x,h=t.y-r.y,v=u-n,y=l*l+h*h;if(v*v/f<y)return y<c&&(0===l&&(y+=(l=e())*l),0===h&&(y+=(h=e())*h),y<a&&(y=Math.sqrt(a*y)),r.vx+=l*t.value*i/y,r.vy+=h*t.value*i/y),!0;if(!(t.length||y>=c)){(t.data!==r||t.next)&&(0===l&&(y+=(l=e())*l),0===h&&(y+=(h=e())*h),y<a&&(y=Math.sqrt(a*y)));do{t.data!==r&&(v=o[t.data.index]*i/y,r.vx+=l*v,r.vy+=h*v)}while(t=t.next)}}return l.initialize=function(n){t=n,h()},l.strength=function(t){return arguments.length?(s="function"==typeof t?t:n(+t),h(),l):s},l.distanceMin=function(t){return arguments.length?(a=t*t,l):Math.sqrt(a)},l.distanceMax=function(t){return arguments.length?(c=t*t,l):Math.sqrt(c)},l.theta=function(t){return arguments.length?(f=t*t,l):Math.sqrt(f)},l}().strength(r.repulsionStrength);return function(t){var n,e=1,r=.001,i=1-Math.pow(r,1/300),o=0,s=.6,u=v(),a=C(f),c=x("tick","end");function f(){l(),c.call("tick",n),e<r&&(a.stop(),c.call("end",n))}function l(r){var a,c,f=t.length;void 0===r&&(r=1);for(var l=0;l<r;++l)for(e+=(o-e)*i,u.each((function(t){t(e)})),a=0;a<f;++a)null==(c=t[a]).fx?c.x+=c.vx*=s:(c.x=c.fx,c.vx=0),null==c.fy?c.y+=c.vy*=s:(c.y=c.fy,c.vy=0);return n}function h(){for(var n,e=0,r=t.length;e<r;++e){if((n=t[e]).index=e,null!=n.fx&&(n.x=n.fx),null!=n.fy&&(n.y=n.fy),isNaN(n.x)||isNaN(n.y)){var i=10*Math.sqrt(e),o=e*U;n.x=i*Math.cos(o),n.y=i*Math.sin(o)}(isNaN(n.vx)||isNaN(n.vy))&&(n.vx=n.vy=0)}}function y(n){return n.initialize&&n.initialize(t),n}return null==t&&(t=[]),h(),n={tick:l,restart:function(){return a.restart(f),n},stop:function(){return a.stop(),n},nodes:function(e){return arguments.length?(t=e,h(),u.each(y),n):t},alpha:function(t){return arguments.length?(e=+t,n):e},alphaMin:function(t){return arguments.length?(r=+t,n):r},alphaDecay:function(t){return arguments.length?(i=+t,n):+i},alphaTarget:function(t){return arguments.length?(o=+t,n):o},velocityDecay:function(t){return arguments.length?(s=1-t,n):1-s},force:function(t,e){return arguments.length>1?(null==e?u.remove(t):u.set(t,y(e)),n):u.get(t)},find:function(n,e,r){var i,o,s,u,a,c=0,f=t.length;for(null==r?r=1/0:r*=r,c=0;c<f;++c)(s=(i=n-(u=t[c]).x)*i+(o=e-u.y)*o)<r&&(a=u,r=s);return a},on:function(t,e){return arguments.length>1?(c.on(t,e),n):c.on(t)}}}(i).force("link",s).force("charge",a).force("center",function(t,n){var e;function r(){var r,i,o=e.length,s=0,u=0;for(r=0;r<o;++r)s+=(i=e[r]).x,u+=i.y;for(s=s/o-t,u=u/o-n,r=0;r<o;++r)(i=e[r]).x-=s,i.y-=u}return null==t&&(t=0),null==n&&(n=0),r.initialize=function(t){e=t},r.x=function(n){return arguments.length?(t=+n,r):t},r.y=function(t){return arguments.length?(n=+t,r):n},r}()).alpha(r.alpha).alphaMin(r.alphaMin).alphaDecay(r.alphaDecay).velocityDecay(r.velocityDecay).stop().tick(r.iterations),{nodes:i,links:o}}return \$.exports=function(){function t(t){var n=typeof t;return null!==t&&("object"===n||"function"===n)}function n(t){return"function"==typeof t}var e=void 0;e=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)};var r=e,i=0,o=void 0,s=void 0,u=function(t,n){w[i]=t,w[i+1]=n,2===(i+=2)&&(s?s(m):A())};function a(t){s=t}function c(t){u=t}var f="undefined"!=typeof window?window:void 0,l=f||{},h=l.MutationObserver||l.WebKitMutationObserver,v="undefined"==typeof self&&"undefined"!=typeof process&&"[object process]"==={}.toString.call(process),y="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function p(){return function(){return process.nextTick(m)}}function _(){return void 0!==o?function(){o(m)}:x()}function d(){var t=0,n=new h(m),e=document.createTextNode("");return n.observe(e,{characterData:!0}),function(){e.data=t=++t%2}}function g(){var t=new MessageChannel;return t.port1.onmessage=m,function(){return t.port2.postMessage(0)}}function x(){var t=setTimeout;return function(){return t(m,1)}}var w=new Array(1e3);function m(){for(var t=0;t<i;t+=2)(0,w[t])(w[t+1]),w[t]=void 0,w[t+1]=void 0;i=0}function b(){try{var t=Function("return this")().require("vertx");return o=t.runOnLoop||t.runOnContext,_()}catch(t){return x()}}var A=void 0;function N(t,n){var e=this,r=new this.constructor(E);void 0===r[k]&&J(r);var i=e._state;if(i){var o=arguments[i-1];u((function(){return \$(i,r,o,e._result)}))}else L(e,r,t,n);return r}function M(t){var n=this;if(t&&"object"==typeof t&&t.constructor===n)return t;var e=new n(E);return F(e,t),e}A=v?p():h?d():y?g():void 0===f?b():x();var k=Math.random().toString(36).substring(2);function E(){}var T=void 0,j=1,S=2;function q(){return new TypeError("You cannot resolve a promise with itself")}function D(){return new TypeError("A promises callback cannot return that same promise.")}function O(t,n,e,r){try{t.call(n,e,r)}catch(t){return t}}function P(t,n,e){u((function(t){var r=!1,i=O(e,n,(function(e){r||(r=!0,n!==e?F(t,e):Y(t,e))}),(function(n){r||(r=!0,K(t,n))}),"Settle: "+(t._label||" unknown promise"));!r&&i&&(r=!0,K(t,i))}),t)}function z(t,n){n._state===j?Y(t,n._result):n._state===S?K(t,n._result):L(n,void 0,(function(n){return F(t,n)}),(function(n){return K(t,n)}))}function C(t,e,r){e.constructor===t.constructor&&r===N&&e.constructor.resolve===M?z(t,e):void 0===r?Y(t,e):n(r)?P(t,e,r):Y(t,e)}function F(n,e){if(n===e)K(n,q());else if(t(e)){var r=void 0;try{r=e.then}catch(t){return void K(n,t)}C(n,e,r)}else Y(n,e)}function I(t){t._onerror&&t._onerror(t._result),U(t)}function Y(t,n){t._state===T&&(t._result=n,t._state=j,0!==t._subscribers.length&&u(U,t))}function K(t,n){t._state===T&&(t._state=S,t._result=n,u(I,t))}function L(t,n,e,r){var i=t._subscribers,o=i.length;t._onerror=null,i[o]=n,i[o+j]=e,i[o+S]=r,0===o&&t._state&&u(U,t)}function U(t){var n=t._subscribers,e=t._state;if(0!==n.length){for(var r=void 0,i=void 0,o=t._result,s=0;s<n.length;s+=3)r=n[s],i=n[s+e],r?\$(e,r,i,o):i(o);t._subscribers.length=0}}function \$(t,e,r,i){var o=n(r),s=void 0,u=void 0,a=!0;if(o){try{s=r(i)}catch(t){a=!1,u=t}if(e===s)return void K(e,D())}else s=i;e._state!==T||(o&&a?F(e,s):!1===a?K(e,u):t===j?Y(e,s):t===S&&K(e,s))}function B(t,n){try{n((function(n){F(t,n)}),(function(n){K(t,n)}))}catch(n){K(t,n)}}var G=0;function H(){return G++}function J(t){t[k]=G++,t._state=void 0,t._result=void 0,t._subscribers=[]}function Q(){return new Error("Array Methods must be provided an Array")}var R=function(){function t(t,n){this._instanceConstructor=t,this.promise=new t(E),this.promise[k]||J(this.promise),r(n)?(this.length=n.length,this._remaining=n.length,this._result=new Array(this.length),0===this.length?Y(this.promise,this._result):(this.length=this.length||0,this._enumerate(n),0===this._remaining&&Y(this.promise,this._result))):K(this.promise,Q())}return t.prototype._enumerate=function(t){for(var n=0;this._state===T&&n<t.length;n++)this._eachEntry(t[n],n)},t.prototype._eachEntry=function(t,n){var e=this._instanceConstructor,r=e.resolve;if(r===M){var i=void 0,o=void 0,s=!1;try{i=t.then}catch(t){s=!0,o=t}if(i===N&&t._state!==T)this._settledAt(t._state,n,t._result);else if("function"!=typeof i)this._remaining--,this._result[n]=t;else if(e===et){var u=new e(E);s?K(u,o):C(u,t,i),this._willSettleAt(u,n)}else this._willSettleAt(new e((function(n){return n(t)})),n)}else this._willSettleAt(r(t),n)},t.prototype._settledAt=function(t,n,e){var r=this.promise;r._state===T&&(this._remaining--,t===S?K(r,e):this._result[n]=e),0===this._remaining&&Y(r,this._result)},t.prototype._willSettleAt=function(t,n){var e=this;L(t,void 0,(function(t){return e._settledAt(j,n,t)}),(function(t){return e._settledAt(S,n,t)}))},t}();function V(t){return new R(this,t).promise}function X(t){var n=this;return r(t)?new n((function(e,r){for(var i=t.length,o=0;o<i;o++)n.resolve(t[o]).then(e,r)})):new n((function(t,n){return n(new TypeError("You must pass an array to race."))}))}function Z(t){var n=new this(E);return K(n,t),n}function tt(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function nt(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}var et=function(){function t(n){this[k]=H(),this._result=this._state=void 0,this._subscribers=[],E!==n&&("function"!=typeof n&&tt(),this instanceof t?B(this,n):nt())}return t.prototype.catch=function(t){return this.then(null,t)},t.prototype.finally=function(t){var e=this,r=e.constructor;return n(t)?e.then((function(n){return r.resolve(t()).then((function(){return n}))}),(function(n){return r.resolve(t()).then((function(){throw n}))})):e.then(t,t)},t}();function rt(){var t=void 0;if(void 0!==W)t=W;else if("undefined"!=typeof self)t=self;else try{t=Function("return this")()}catch(t){throw new Error("polyfill failed because global object is unavailable in this environment")}var n=t.Promise;if(n){var e=null;try{e=Object.prototype.toString.call(n.resolve())}catch(t){}if("[object Promise]"===e&&!n.cast)return}t.Promise=et}return et.prototype.then=N,et.all=V,et.race=X,et.resolve=M,et.reject=Z,et._setScheduler=a,et._setAsap=c,et._asap=u,et.polyfill=rt,et.Promise=et,et}(),\$.exports.polyfill(),self.onmessage=function(t){var n=B.apply(void 0,t.data);self.postMessage(n)},t.forceDirected=B,t}({});`;
|
|
42
|
-
|
|
43
|
-
const workerBlob = new Blob([workerCode], { type: "application/javascript" });
|
|
44
|
-
const workerUrl = URL.createObjectURL(workerBlob);
|
|
45
|
-
const worker = new Worker(workerUrl);
|
|
10
|
+
const worker = new ForceDirectedWorker();
|
|
46
11
|
const response = new Promise<string>(resolve => {
|
|
47
12
|
worker.onmessage = event => {
|
|
48
13
|
resolve(event.data);
|
|
49
14
|
worker.terminate();
|
|
50
|
-
URL.revokeObjectURL(workerUrl);
|
|
51
15
|
};
|
|
52
16
|
worker.postMessage([data, options]);
|
|
53
17
|
});
|