import { $ as e, A as t, B as n, C as r, D as i, E as a, F as o, G as s, H as c, I as l, J as u, K as d, L as f, M as p, N as m, O as h, P as g, Q as _, R as v, S as ee, T as te, U as ne, V as re, W as ie, X as ae, Y as oe, Z as y, _ as b, a as x, b as se, c as ce, d as le, et as S, f as C, g as ue, h as de, i as w, it as fe, j as pe, k as me, l as he, m as ge, n as T, nt as _e, o as E, p as ve, q as ye, r as D, rt as be, s as xe, t as O, tt as k, u as Se, v as Ce, w as we, x as Te, y as Ee, z as A } from "./graphlib-VMWSbyYi.js";
//#region node_modules/lodash-es/_trimmedEndIndex.js
var De = /\s/;
function Oe(e) {
	for (var t = e.length; t-- && De.test(e.charAt(t)););
	return t;
}
//#endregion
//#region node_modules/lodash-es/_baseTrim.js
var ke = /^\s+/;
function Ae(e) {
	return e && e.slice(0, Oe(e) + 1).replace(ke, "");
}
//#endregion
//#region node_modules/lodash-es/toNumber.js
var je = NaN, Me = /^[-+]0x[0-9a-f]+$/i, Ne = /^0b[01]+$/i, Pe = /^0o[0-7]+$/i, Fe = parseInt;
function Ie(e) {
	if (typeof e == "number") return e;
	if (S(e)) return je;
	if (y(e)) {
		var t = typeof e.valueOf == "function" ? e.valueOf() : e;
		e = y(t) ? t + "" : t;
	}
	if (typeof e != "string") return e === 0 ? e : +e;
	e = Ae(e);
	var n = Ne.test(e);
	return n || Pe.test(e) ? Fe(e.slice(2), n ? 2 : 8) : Me.test(e) ? je : +e;
}
//#endregion
//#region node_modules/lodash-es/toFinite.js
var Le = Infinity, Re = 17976931348623157e292;
function j(e) {
	return e ? (e = Ie(e), e === Le || e === -Le ? (e < 0 ? -1 : 1) * Re : e === e ? e : 0) : e === 0 ? e : 0;
}
//#endregion
//#region node_modules/lodash-es/toInteger.js
function ze(e) {
	var t = j(e), n = t % 1;
	return t === t ? n ? t - n : t : 0;
}
//#endregion
//#region node_modules/lodash-es/_baseCreate.js
var Be = Object.create, Ve = function() {
	function e() {}
	return function(t) {
		if (!y(t)) return {};
		if (Be) return Be(t);
		e.prototype = t;
		var n = new e();
		return e.prototype = void 0, n;
	};
}();
//#endregion
//#region node_modules/lodash-es/_copyArray.js
function He(e, t) {
	var n = -1, r = e.length;
	for (t ||= Array(r); ++n < r;) t[n] = e[n];
	return t;
}
//#endregion
//#region node_modules/lodash-es/_baseAssignValue.js
function M(e, t, n) {
	t == "__proto__" && ye ? ye(e, t, {
		configurable: !0,
		enumerable: !0,
		value: n,
		writable: !0
	}) : e[t] = n;
}
//#endregion
//#region node_modules/lodash-es/_assignValue.js
var Ue = Object.prototype.hasOwnProperty;
function N(e, t, n) {
	var r = e[t];
	(!(Ue.call(e, t) && c(r, n)) || n === void 0 && !(t in e)) && M(e, t, n);
}
//#endregion
//#region node_modules/lodash-es/_copyObject.js
function P(e, t, n, r) {
	var i = !n;
	n ||= {};
	for (var a = -1, o = t.length; ++a < o;) {
		var s = t[a], c = r ? r(n[s], e[s], s, n, e) : void 0;
		c === void 0 && (c = e[s]), i ? M(n, s, c) : N(n, s, c);
	}
	return n;
}
//#endregion
//#region node_modules/lodash-es/_isIterateeCall.js
function F(e, t, n) {
	if (!y(n)) return !1;
	var r = typeof t;
	return (r == "number" ? A(n) && ne(t, n.length) : r == "string" && t in n) ? c(n[t], e) : !1;
}
//#endregion
//#region node_modules/lodash-es/_createAssigner.js
function We(e) {
	return n(function(t, n) {
		var r = -1, i = n.length, a = i > 1 ? n[i - 1] : void 0, o = i > 2 ? n[2] : void 0;
		for (a = e.length > 3 && typeof a == "function" ? (i--, a) : void 0, o && F(n[0], n[1], o) && (a = i < 3 ? void 0 : a, i = 1), t = Object(t); ++r < i;) {
			var s = n[r];
			s && e(t, s, r, a);
		}
		return t;
	});
}
//#endregion
//#region node_modules/lodash-es/_nativeKeysIn.js
function Ge(e) {
	var t = [];
	if (e != null) for (var n in Object(e)) t.push(n);
	return t;
}
//#endregion
//#region node_modules/lodash-es/_baseKeysIn.js
var Ke = Object.prototype.hasOwnProperty;
function qe(e) {
	if (!y(e)) return Ge(e);
	var t = v(e), n = [];
	for (var r in e) r == "constructor" && (t || !Ke.call(e, r)) || n.push(r);
	return n;
}
//#endregion
//#region node_modules/lodash-es/keysIn.js
function I(e) {
	return A(e) ? p(e, !0) : qe(e);
}
//#endregion
//#region node_modules/lodash-es/flatten.js
function L(e) {
	return e != null && e.length ? r(e, 1) : [];
}
//#endregion
//#region node_modules/lodash-es/_flatRest.js
function Je(e) {
	return d(re(e, void 0, L), e + "");
}
//#endregion
//#region node_modules/lodash-es/_getPrototype.js
var Ye = pe(Object.getPrototypeOf, Object), Xe = "[object Object]", Ze = Function.prototype, Qe = Object.prototype, $e = Ze.toString, et = Qe.hasOwnProperty, tt = $e.call(Object);
function nt(e) {
	if (!k(e) || _e(e) != Xe) return !1;
	var t = Ye(e);
	if (t === null) return !0;
	var n = et.call(t, "constructor") && t.constructor;
	return typeof n == "function" && n instanceof n && $e.call(n) == tt;
}
//#endregion
//#region node_modules/lodash-es/_hasUnicode.js
var rt = RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");
function it(e) {
	return rt.test(e);
}
//#endregion
//#region node_modules/lodash-es/_baseAssign.js
function at(e, t) {
	return e && P(t, me(t), e);
}
//#endregion
//#region node_modules/lodash-es/_baseAssignIn.js
function ot(e, t) {
	return e && P(t, I(t), e);
}
//#endregion
//#region node_modules/lodash-es/_cloneBuffer.js
var st = typeof exports == "object" && exports && !exports.nodeType && exports, ct = st && typeof module == "object" && module && !module.nodeType && module, lt = ct && ct.exports === st ? fe.Buffer : void 0, ut = lt ? lt.allocUnsafe : void 0;
function dt(e, t) {
	if (t) return e.slice();
	var n = e.length, r = ut ? ut(n) : new e.constructor(n);
	return e.copy(r), r;
}
//#endregion
//#region node_modules/lodash-es/_copySymbols.js
function ft(e, t) {
	return P(e, se(e), t);
}
//#endregion
//#region node_modules/lodash-es/_getSymbolsIn.js
var pt = Object.getOwnPropertySymbols ? function(e) {
	for (var t = []; e;) we(t, se(e)), e = Ye(e);
	return t;
} : Te;
//#endregion
//#region node_modules/lodash-es/_copySymbolsIn.js
function mt(e, t) {
	return P(e, pt(e), t);
}
//#endregion
//#region node_modules/lodash-es/_getAllKeysIn.js
function ht(e) {
	return Ee(e, I, pt);
}
//#endregion
//#region node_modules/lodash-es/_initCloneArray.js
var gt = Object.prototype.hasOwnProperty;
function _t(e) {
	var t = e.length, n = new e.constructor(t);
	return t && typeof e[0] == "string" && gt.call(e, "index") && (n.index = e.index, n.input = e.input), n;
}
//#endregion
//#region node_modules/lodash-es/_cloneArrayBuffer.js
function vt(e) {
	var t = new e.constructor(e.byteLength);
	return new ue(t).set(new ue(e)), t;
}
//#endregion
//#region node_modules/lodash-es/_cloneDataView.js
function yt(e, t) {
	var n = t ? vt(e.buffer) : e.buffer;
	return new e.constructor(n, e.byteOffset, e.byteLength);
}
//#endregion
//#region node_modules/lodash-es/_cloneRegExp.js
var bt = /\w*$/;
function xt(e) {
	var t = new e.constructor(e.source, bt.exec(e));
	return t.lastIndex = e.lastIndex, t;
}
//#endregion
//#region node_modules/lodash-es/_cloneSymbol.js
var St = be ? be.prototype : void 0, Ct = St ? St.valueOf : void 0;
function wt(e) {
	return Ct ? Object(Ct.call(e)) : {};
}
//#endregion
//#region node_modules/lodash-es/_cloneTypedArray.js
function Tt(e, t) {
	var n = t ? vt(e.buffer) : e.buffer;
	return new e.constructor(n, e.byteOffset, e.length);
}
//#endregion
//#region node_modules/lodash-es/_initCloneByTag.js
var Et = "[object Boolean]", Dt = "[object Date]", Ot = "[object Map]", kt = "[object Number]", At = "[object RegExp]", jt = "[object Set]", Mt = "[object String]", Nt = "[object Symbol]", Pt = "[object ArrayBuffer]", Ft = "[object DataView]", It = "[object Float32Array]", Lt = "[object Float64Array]", Rt = "[object Int8Array]", zt = "[object Int16Array]", Bt = "[object Int32Array]", Vt = "[object Uint8Array]", Ht = "[object Uint8ClampedArray]", Ut = "[object Uint16Array]", Wt = "[object Uint32Array]";
function Gt(e, t, n) {
	var r = e.constructor;
	switch (t) {
		case Pt: return vt(e);
		case Et:
		case Dt: return new r(+e);
		case Ft: return yt(e, n);
		case It:
		case Lt:
		case Rt:
		case zt:
		case Bt:
		case Vt:
		case Ht:
		case Ut:
		case Wt: return Tt(e, n);
		case Ot: return new r();
		case kt:
		case Mt: return new r(e);
		case At: return xt(e);
		case jt: return new r();
		case Nt: return wt(e);
	}
}
//#endregion
//#region node_modules/lodash-es/_initCloneObject.js
function Kt(e) {
	return typeof e.constructor == "function" && !v(e) ? Ve(Ye(e)) : {};
}
//#endregion
//#region node_modules/lodash-es/_baseIsMap.js
var qt = "[object Map]";
function Jt(e) {
	return k(e) && b(e) == qt;
}
//#endregion
//#region node_modules/lodash-es/isMap.js
var Yt = g && g.isMap, Xt = Yt ? o(Yt) : Jt, Zt = "[object Set]";
function Qt(e) {
	return k(e) && b(e) == Zt;
}
//#endregion
//#region node_modules/lodash-es/isSet.js
var $t = g && g.isSet, en = $t ? o($t) : Qt, tn = 1, nn = 2, rn = 4, an = "[object Arguments]", on = "[object Array]", sn = "[object Boolean]", cn = "[object Date]", ln = "[object Error]", un = "[object Function]", dn = "[object GeneratorFunction]", fn = "[object Map]", pn = "[object Number]", mn = "[object Object]", hn = "[object RegExp]", gn = "[object Set]", _n = "[object String]", vn = "[object Symbol]", yn = "[object WeakMap]", bn = "[object ArrayBuffer]", xn = "[object DataView]", Sn = "[object Float32Array]", Cn = "[object Float64Array]", wn = "[object Int8Array]", Tn = "[object Int16Array]", En = "[object Int32Array]", Dn = "[object Uint8Array]", On = "[object Uint8ClampedArray]", kn = "[object Uint16Array]", An = "[object Uint32Array]", R = {};
R[an] = R[on] = R[bn] = R[xn] = R[sn] = R[cn] = R[Sn] = R[Cn] = R[wn] = R[Tn] = R[En] = R[fn] = R[pn] = R[mn] = R[hn] = R[gn] = R[_n] = R[vn] = R[Dn] = R[On] = R[kn] = R[An] = !0, R[ln] = R[un] = R[yn] = !1;
function z(e, t, n, r, i, a) {
	var o, c = t & tn, u = t & nn, d = t & rn;
	if (n && (o = i ? n(e, r, i, a) : n(e)), o !== void 0) return o;
	if (!y(e)) return e;
	var f = _(e);
	if (f) {
		if (o = _t(e), !c) return He(e, o);
	} else {
		var p = b(e), m = p == un || p == dn;
		if (l(e)) return dt(e, c);
		if (p == mn || p == an || m && !i) {
			if (o = u || m ? {} : Kt(e), !c) return u ? mt(e, ot(o, e)) : ft(e, at(o, e));
		} else {
			if (!R[p]) return i ? e : {};
			o = Gt(e, p, c);
		}
	}
	a ||= new ee();
	var h = a.get(e);
	if (h) return h;
	a.set(e, o), en(e) ? e.forEach(function(r) {
		o.add(z(r, t, n, r, e, a));
	}) : Xt(e) && e.forEach(function(r, i) {
		o.set(i, z(r, t, n, i, e, a));
	});
	var g = f ? void 0 : (d ? u ? ht : Ce : u ? I : me)(e);
	return s(g || e, function(r, i) {
		g && (i = r, r = e[i]), N(o, i, z(r, t, n, i, e, a));
	}), o;
}
//#endregion
//#region node_modules/lodash-es/cloneDeep.js
var jn = 1, Mn = 4;
function Nn(e) {
	return z(e, jn | Mn);
}
//#endregion
//#region node_modules/lodash-es/now.js
var Pn = function() {
	return fe.Date.now();
}, Fn = Object.prototype, In = Fn.hasOwnProperty, Ln = n(function(e, t) {
	e = Object(e);
	var n = -1, r = t.length, i = r > 2 ? t[2] : void 0;
	for (i && F(t[0], t[1], i) && (r = 1); ++n < r;) for (var a = t[n], o = I(a), s = -1, l = o.length; ++s < l;) {
		var u = o[s], d = e[u];
		(d === void 0 || c(d, Fn[u]) && !In.call(e, u)) && (e[u] = a[u]);
	}
	return e;
});
//#endregion
//#region node_modules/lodash-es/_assignMergeValue.js
function Rn(e, t, n) {
	(n !== void 0 && !c(e[t], n) || n === void 0 && !(t in e)) && M(e, t, n);
}
//#endregion
//#region node_modules/lodash-es/_safeGet.js
function zn(e, t) {
	if (!(t === "constructor" && typeof e[t] == "function") && t != "__proto__") return e[t];
}
//#endregion
//#region node_modules/lodash-es/toPlainObject.js
function Bn(e) {
	return P(e, I(e));
}
//#endregion
//#region node_modules/lodash-es/_baseMergeDeep.js
function Vn(e, t, n, r, i, a, o) {
	var s = zn(e, n), c = zn(t, n), u = o.get(c);
	if (u) {
		Rn(e, n, u);
		return;
	}
	var d = a ? a(s, c, n + "", e, t, o) : void 0, p = d === void 0;
	if (p) {
		var h = _(c), g = !h && l(c), v = !h && !g && m(c);
		d = c, h || g || v ? _(s) ? d = s : ce(s) ? d = He(s) : g ? (p = !1, d = dt(c, !0)) : v ? (p = !1, d = Tt(c, !0)) : d = [] : nt(c) || f(c) ? (d = s, f(s) ? d = Bn(s) : (!y(s) || oe(s)) && (d = Kt(c))) : p = !1;
	}
	p && (o.set(c, d), i(d, c, r, a, o), o.delete(c)), Rn(e, n, d);
}
//#endregion
//#region node_modules/lodash-es/_baseMerge.js
function Hn(e, t, n, r, i) {
	e !== t && le(t, function(a, o) {
		if (i ||= new ee(), y(a)) Vn(e, t, o, n, Hn, r, i);
		else {
			var s = r ? r(zn(e, o), a, o + "", e, t, i) : void 0;
			s === void 0 && (s = a), Rn(e, o, s);
		}
	}, I);
}
//#endregion
//#region node_modules/lodash-es/last.js
function B(e) {
	var t = e == null ? 0 : e.length;
	return t ? e[t - 1] : void 0;
}
//#endregion
//#region node_modules/lodash-es/_createFind.js
function Un(e) {
	return function(t, n, r) {
		var i = Object(t);
		if (!A(t)) {
			var a = C(n, 3);
			t = me(t), n = function(e) {
				return a(i[e], e, i);
			};
		}
		var o = e(t, n, r);
		return o > -1 ? i[a ? t[o] : o] : void 0;
	};
}
//#endregion
//#region node_modules/lodash-es/findIndex.js
var Wn = Math.max;
function Gn(e, t, n) {
	var r = e == null ? 0 : e.length;
	if (!r) return -1;
	var i = n == null ? 0 : ze(n);
	return i < 0 && (i = Wn(r + i, 0)), ie(e, C(t, 3), i);
}
//#endregion
//#region node_modules/lodash-es/find.js
var Kn = Un(Gn);
//#endregion
//#region node_modules/lodash-es/_baseMap.js
function qn(e, t) {
	var n = -1, r = A(e) ? Array(e.length) : [];
	return he(e, function(e, i, a) {
		r[++n] = t(e, i, a);
	}), r;
}
//#endregion
//#region node_modules/lodash-es/map.js
function V(t, n) {
	return (_(t) ? e : qn)(t, C(n, 3));
}
//#endregion
//#region node_modules/lodash-es/forIn.js
function Jn(e, t) {
	return e == null ? e : le(e, xe(t), I);
}
//#endregion
//#region node_modules/lodash-es/forOwn.js
function Yn(e, t) {
	return e && Se(e, xe(t));
}
//#endregion
//#region node_modules/lodash-es/_baseGt.js
function Xn(e, t) {
	return e > t;
}
//#endregion
//#region node_modules/lodash-es/_baseHas.js
var Zn = Object.prototype.hasOwnProperty;
function Qn(e, t) {
	return e != null && Zn.call(e, t);
}
//#endregion
//#region node_modules/lodash-es/has.js
function $n(e, t) {
	return e != null && de(e, t, Qn);
}
//#endregion
//#region node_modules/lodash-es/isString.js
var er = "[object String]";
function tr(e) {
	return typeof e == "string" || !_(e) && k(e) && _e(e) == er;
}
//#endregion
//#region node_modules/lodash-es/_baseLt.js
function nr(e, t) {
	return e < t;
}
//#endregion
//#region node_modules/lodash-es/mapValues.js
function H(e, t) {
	var n = {};
	return t = C(t, 3), Se(e, function(e, r, i) {
		M(n, r, t(e, r, i));
	}), n;
}
//#endregion
//#region node_modules/lodash-es/_baseExtremum.js
function rr(e, t, n) {
	for (var r = -1, i = e.length; ++r < i;) {
		var a = e[r], o = t(a);
		if (o != null && (s === void 0 ? o === o && !S(o) : n(o, s))) var s = o, c = a;
	}
	return c;
}
//#endregion
//#region node_modules/lodash-es/max.js
function U(e) {
	return e && e.length ? rr(e, ae, Xn) : void 0;
}
//#endregion
//#region node_modules/lodash-es/merge.js
var ir = We(function(e, t, n) {
	Hn(e, t, n);
});
//#endregion
//#region node_modules/lodash-es/min.js
function W(e) {
	return e && e.length ? rr(e, ae, nr) : void 0;
}
//#endregion
//#region node_modules/lodash-es/minBy.js
function ar(e, t) {
	return e && e.length ? rr(e, C(t, 2), nr) : void 0;
}
//#endregion
//#region node_modules/lodash-es/_baseSet.js
function or(e, t, n, r) {
	if (!y(e)) return e;
	t = i(t, e);
	for (var o = -1, s = t.length, c = s - 1, l = e; l != null && ++o < s;) {
		var u = a(t[o]), d = n;
		if (u === "__proto__" || u === "constructor" || u === "prototype") return e;
		if (o != c) {
			var f = l[u];
			d = r ? r(f, u, l) : void 0, d === void 0 && (d = y(f) ? f : ne(t[o + 1]) ? [] : {});
		}
		N(l, u, d), l = l[u];
	}
	return e;
}
//#endregion
//#region node_modules/lodash-es/_basePickBy.js
function sr(e, t, n) {
	for (var r = -1, a = t.length, o = {}; ++r < a;) {
		var s = t[r], c = te(e, s);
		n(c, s) && or(o, i(s, e), c);
	}
	return o;
}
//#endregion
//#region node_modules/lodash-es/_baseSortBy.js
function cr(e, t) {
	var n = e.length;
	for (e.sort(t); n--;) e[n] = e[n].value;
	return e;
}
//#endregion
//#region node_modules/lodash-es/_compareAscending.js
function lr(e, t) {
	if (e !== t) {
		var n = e !== void 0, r = e === null, i = e === e, a = S(e), o = t !== void 0, s = t === null, c = t === t, l = S(t);
		if (!s && !l && !a && e > t || a && o && c && !s && !l || r && o && c || !n && c || !i) return 1;
		if (!r && !a && !l && e < t || l && n && i && !r && !a || s && n && i || !o && i || !c) return -1;
	}
	return 0;
}
//#endregion
//#region node_modules/lodash-es/_compareMultiple.js
function ur(e, t, n) {
	for (var r = -1, i = e.criteria, a = t.criteria, o = i.length, s = n.length; ++r < o;) {
		var c = lr(i[r], a[r]);
		if (c) return r >= s ? c : c * (n[r] == "desc" ? -1 : 1);
	}
	return e.index - t.index;
}
//#endregion
//#region node_modules/lodash-es/_baseOrderBy.js
function dr(t, n, r) {
	n = n.length ? e(n, function(e) {
		return _(e) ? function(t) {
			return te(t, e.length === 1 ? e[0] : e);
		} : e;
	}) : [ae];
	var i = -1;
	return n = e(n, o(C)), cr(qn(t, function(t, r, a) {
		return {
			criteria: e(n, function(e) {
				return e(t);
			}),
			index: ++i,
			value: t
		};
	}), function(e, t) {
		return ur(e, t, r);
	});
}
//#endregion
//#region node_modules/lodash-es/_asciiSize.js
var fr = ve("length"), pr = "\\ud800-\\udfff", mr = "\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff", hr = "\\ufe0e\\ufe0f", gr = "[" + pr + "]", G = "[" + mr + "]", _r = "\\ud83c[\\udffb-\\udfff]", vr = "(?:" + G + "|" + _r + ")", yr = "[^" + pr + "]", br = "(?:\\ud83c[\\udde6-\\uddff]){2}", xr = "[\\ud800-\\udbff][\\udc00-\\udfff]", Sr = "\\u200d", Cr = vr + "?", wr = "[" + hr + "]?", Tr = "(?:" + Sr + "(?:" + [
	yr,
	br,
	xr
].join("|") + ")" + wr + Cr + ")*", Er = wr + Cr + Tr, Dr = "(?:" + [
	yr + G + "?",
	G,
	br,
	xr,
	gr
].join("|") + ")", Or = RegExp(_r + "(?=" + _r + ")|" + Dr + Er, "g");
function kr(e) {
	for (var t = Or.lastIndex = 0; Or.test(e);) ++t;
	return t;
}
//#endregion
//#region node_modules/lodash-es/_stringSize.js
function Ar(e) {
	return it(e) ? kr(e) : fr(e);
}
//#endregion
//#region node_modules/lodash-es/_basePick.js
function jr(e, t) {
	return sr(e, t, function(t, n) {
		return ge(e, n);
	});
}
//#endregion
//#region node_modules/lodash-es/pick.js
var K = Je(function(e, t) {
	return e == null ? {} : jr(e, t);
}), Mr = Math.ceil, Nr = Math.max;
function Pr(e, t, n, r) {
	for (var i = -1, a = Nr(Mr((t - e) / (n || 1)), 0), o = Array(a); a--;) o[r ? a : ++i] = e, e += n;
	return o;
}
//#endregion
//#region node_modules/lodash-es/_createRange.js
function Fr(e) {
	return function(t, n, r) {
		return r && typeof r != "number" && F(t, n, r) && (n = r = void 0), t = j(t), n === void 0 ? (n = t, t = 0) : n = j(n), r = r === void 0 ? t < n ? 1 : -1 : j(r), Pr(t, n, r, e);
	};
}
//#endregion
//#region node_modules/lodash-es/range.js
var q = Fr(), Ir = "[object Map]", Lr = "[object Set]";
function Rr(e) {
	if (e == null) return 0;
	if (A(e)) return tr(e) ? Ar(e) : e.length;
	var n = b(e);
	return n == Ir || n == Lr ? e.size : t(e).length;
}
//#endregion
//#region node_modules/lodash-es/sortBy.js
var J = n(function(e, t) {
	if (e == null) return [];
	var n = t.length;
	return n > 1 && F(e, t[0], t[1]) ? t = [] : n > 2 && F(t[0], t[1], t[2]) && (t = [t[0]]), dr(e, r(t, 1), []);
}), zr = 0;
function Br(e) {
	var t = ++zr;
	return h(e) + t;
}
//#endregion
//#region node_modules/lodash-es/_baseZipObject.js
function Vr(e, t, n) {
	for (var r = -1, i = e.length, a = t.length, o = {}; ++r < i;) {
		var s = r < a ? t[r] : void 0;
		n(o, e[r], s);
	}
	return o;
}
//#endregion
//#region node_modules/lodash-es/zipObject.js
function Hr(e, t) {
	return Vr(e || [], t || [], N);
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/data/list.js
var Ur = class {
	constructor() {
		var e = {};
		e._next = e._prev = e, this._sentinel = e;
	}
	dequeue() {
		var e = this._sentinel, t = e._prev;
		if (t !== e) return Wr(t), t;
	}
	enqueue(e) {
		var t = this._sentinel;
		e._prev && e._next && Wr(e), e._next = t._next, t._next._prev = e, t._next = e, e._prev = t;
	}
	toString() {
		for (var e = [], t = this._sentinel, n = t._prev; n !== t;) e.push(JSON.stringify(n, Gr)), n = n._prev;
		return "[" + e.join(", ") + "]";
	}
};
function Wr(e) {
	e._prev._next = e._next, e._next._prev = e._prev, delete e._next, delete e._prev;
}
function Gr(e, t) {
	if (e !== "_next" && e !== "_prev") return t;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/greedy-fas.js
var Kr = u(1);
function qr(e, t) {
	if (e.nodeCount() <= 1) return [];
	var n = Xr(e, t || Kr);
	return L(V(Jr(n.graph, n.buckets, n.zeroIdx), function(t) {
		return e.outEdges(t.v, t.w);
	}));
}
function Jr(e, t, n) {
	for (var r = [], i = t[t.length - 1], a = t[0], o; e.nodeCount();) {
		for (; o = a.dequeue();) Yr(e, t, n, o);
		for (; o = i.dequeue();) Yr(e, t, n, o);
		if (e.nodeCount()) {
			for (var s = t.length - 2; s > 0; --s) if (o = t[s].dequeue(), o) {
				r = r.concat(Yr(e, t, n, o, !0));
				break;
			}
		}
	}
	return r;
}
function Yr(e, t, n, r, i) {
	var a = i ? [] : void 0;
	return E(e.inEdges(r.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, Zr(t, n, s);
	}), E(e.outEdges(r.v), function(r) {
		var i = e.edge(r), a = r.w, o = e.node(a);
		o.in -= i, Zr(t, n, o);
	}), e.removeNode(r.v), a;
}
function Xr(e, t) {
	var n = new O(), r = 0, i = 0;
	E(e.nodes(), function(e) {
		n.setNode(e, {
			v: e,
			in: 0,
			out: 0
		});
	}), E(e.edges(), function(e) {
		var a = n.edge(e.v, e.w) || 0, o = t(e), s = a + o;
		n.setEdge(e.v, e.w, s), i = Math.max(i, n.node(e.v).out += o), r = Math.max(r, n.node(e.w).in += o);
	});
	var a = q(i + r + 3).map(function() {
		return new Ur();
	}), o = r + 1;
	return E(n.nodes(), function(e) {
		Zr(a, o, n.node(e));
	}), {
		graph: n,
		buckets: a,
		zeroIdx: o
	};
}
function Zr(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);
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/acyclic.js
function Qr(e) {
	E(e.graph().acyclicer === "greedy" ? qr(e, t(e)) : $r(e), function(t) {
		var n = e.edge(t);
		e.removeEdge(t), n.forwardName = t.name, n.reversed = !0, e.setEdge(t.w, t.v, n, Br("rev"));
	});
	function t(e) {
		return function(t) {
			return e.edge(t).weight;
		};
	}
}
function $r(e) {
	var t = [], n = {}, r = {};
	function i(a) {
		Object.prototype.hasOwnProperty.call(r, a) || (r[a] = !0, n[a] = !0, E(e.outEdges(a), function(e) {
			Object.prototype.hasOwnProperty.call(n, e.w) ? t.push(e) : i(e.w);
		}), delete n[a]);
	}
	return E(e.nodes(), i), t;
}
function ei(e) {
	E(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);
		}
	});
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/util.js
function Y(e, t, n, r) {
	var i;
	do
		i = Br(r);
	while (e.hasNode(i));
	return n.dummy = t, e.setNode(i, n), i;
}
function ti(e) {
	var t = new O().setGraph(e.graph());
	return E(e.nodes(), function(n) {
		t.setNode(n, e.node(n));
	}), E(e.edges(), function(n) {
		var r = t.edge(n.v, n.w) || {
			weight: 0,
			minlen: 1
		}, i = e.edge(n);
		t.setEdge(n.v, n.w, {
			weight: r.weight + i.weight,
			minlen: Math.max(r.minlen, i.minlen)
		});
	}), t;
}
function ni(e) {
	var t = new O({ multigraph: e.isMultigraph() }).setGraph(e.graph());
	return E(e.nodes(), function(n) {
		e.children(n).length || t.setNode(n, e.node(n));
	}), E(e.edges(), function(n) {
		t.setEdge(n, e.edge(n));
	}), t;
}
function ri(e, t) {
	var n = e.x, r = e.y, i = t.x - n, a = t.y - r, o = e.width / 2, s = e.height / 2;
	if (!i && !a) throw Error("Not possible to find intersection inside of the rectangle");
	var c, l;
	return Math.abs(a) * o > Math.abs(i) * s ? (a < 0 && (s = -s), c = s * i / a, l = s) : (i < 0 && (o = -o), c = o, l = o * a / i), {
		x: n + c,
		y: r + l
	};
}
function X(e) {
	var t = V(q(si(e) + 1), function() {
		return [];
	});
	return E(e.nodes(), function(n) {
		var r = e.node(n), i = r.rank;
		D(i) || (t[i][r.order] = n);
	}), t;
}
function ii(e) {
	var t = W(V(e.nodes(), function(t) {
		return e.node(t).rank;
	}));
	E(e.nodes(), function(n) {
		var r = e.node(n);
		$n(r, "rank") && (r.rank -= t);
	});
}
function ai(e) {
	var t = W(V(e.nodes(), function(t) {
		return e.node(t).rank;
	})), n = [];
	E(e.nodes(), function(r) {
		var i = e.node(r).rank - t;
		n[i] || (n[i] = []), n[i].push(r);
	});
	var r = 0, i = e.graph().nodeRankFactor;
	E(n, function(t, n) {
		D(t) && n % i !== 0 ? --r : r && E(t, function(t) {
			e.node(t).rank += r;
		});
	});
}
function oi(e, t, n, r) {
	var i = {
		width: 0,
		height: 0
	};
	return arguments.length >= 4 && (i.rank = n, i.order = r), Y(e, "border", i, t);
}
function si(e) {
	return U(V(e.nodes(), function(t) {
		var n = e.node(t).rank;
		if (!D(n)) return n;
	}));
}
function ci(e, t) {
	var n = {
		lhs: [],
		rhs: []
	};
	return E(e, function(e) {
		t(e) ? n.lhs.push(e) : n.rhs.push(e);
	}), n;
}
function li(e, t) {
	var n = Pn();
	try {
		return t();
	} finally {
		console.log(e + " time: " + (Pn() - n) + "ms");
	}
}
function ui(e, t) {
	return t();
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/add-border-segments.js
function di(e) {
	function t(n) {
		var r = e.children(n), i = e.node(n);
		if (r.length && E(r, t), Object.prototype.hasOwnProperty.call(i, "minRank")) {
			i.borderLeft = [], i.borderRight = [];
			for (var a = i.minRank, o = i.maxRank + 1; a < o; ++a) fi(e, "borderLeft", "_bl", n, i, a), fi(e, "borderRight", "_br", n, i, a);
		}
	}
	E(e.children(), t);
}
function fi(e, t, n, r, i, a) {
	var o = {
		width: 0,
		height: 0,
		rank: a,
		borderType: t
	}, s = i[t][a - 1], c = Y(e, "border", o, n);
	i[t][a] = c, e.setParent(c, r), s && e.setEdge(s, c, { weight: 1 });
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/coordinate-system.js
function pi(e) {
	var t = e.graph().rankdir.toLowerCase();
	(t === "lr" || t === "rl") && hi(e);
}
function mi(e) {
	var t = e.graph().rankdir.toLowerCase();
	(t === "bt" || t === "rl") && _i(e), (t === "lr" || t === "rl") && (yi(e), hi(e));
}
function hi(e) {
	E(e.nodes(), function(t) {
		gi(e.node(t));
	}), E(e.edges(), function(t) {
		gi(e.edge(t));
	});
}
function gi(e) {
	var t = e.width;
	e.width = e.height, e.height = t;
}
function _i(e) {
	E(e.nodes(), function(t) {
		vi(e.node(t));
	}), E(e.edges(), function(t) {
		var n = e.edge(t);
		E(n.points, vi), Object.prototype.hasOwnProperty.call(n, "y") && vi(n);
	});
}
function vi(e) {
	e.y = -e.y;
}
function yi(e) {
	E(e.nodes(), function(t) {
		bi(e.node(t));
	}), E(e.edges(), function(t) {
		var n = e.edge(t);
		E(n.points, bi), Object.prototype.hasOwnProperty.call(n, "x") && bi(n);
	});
}
function bi(e) {
	var t = e.x;
	e.x = e.y, e.y = t;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/normalize.js
function xi(e) {
	e.graph().dummyChains = [], E(e.edges(), function(t) {
		Si(e, t);
	});
}
function Si(e, t) {
	var n = t.v, r = e.node(n).rank, i = t.w, a = e.node(i).rank, o = t.name, s = e.edge(t), c = s.labelRank;
	if (a !== r + 1) {
		e.removeEdge(t);
		var l = void 0, u, d;
		for (d = 0, ++r; r < a; ++d, ++r) s.points = [], l = {
			width: 0,
			height: 0,
			edgeLabel: s,
			edgeObj: t,
			rank: r
		}, u = Y(e, "edge", l, "_d"), r === c && (l.width = s.width, l.height = s.height, l.dummy = "edge-label", l.labelpos = s.labelpos), e.setEdge(n, u, { weight: s.weight }, o), d === 0 && e.graph().dummyChains.push(u), n = u;
		e.setEdge(n, i, { weight: s.weight }, o);
	}
}
function Ci(e) {
	E(e.graph().dummyChains, function(t) {
		var n = e.node(t), r = n.edgeLabel, i;
		for (e.setEdge(n.edgeObj, r); n.dummy;) i = e.successors(t)[0], e.removeNode(t), r.points.push({
			x: n.x,
			y: n.y
		}), n.dummy === "edge-label" && (r.x = n.x, r.y = n.y, r.width = n.width, r.height = n.height), t = i, n = e.node(t);
	});
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/rank/util.js
function wi(e) {
	var t = {};
	function n(r) {
		var i = e.node(r);
		if (Object.prototype.hasOwnProperty.call(t, r)) return i.rank;
		t[r] = !0;
		var a = W(V(e.outEdges(r), function(t) {
			return n(t.w) - e.edge(t).minlen;
		}));
		return (a === Infinity || a == null) && (a = 0), i.rank = a;
	}
	E(e.sources(), n);
}
function Z(e, t) {
	return e.node(t.w).rank - e.node(t.v).rank - e.edge(t).minlen;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/rank/feasible-tree.js
function Ti(e) {
	var t = new O({ directed: !1 }), n = e.nodes()[0], r = e.nodeCount();
	t.setNode(n, {});
	for (var i, a; Ei(t, e) < r;) i = Di(t, e), a = t.hasNode(i.v) ? Z(e, i) : -Z(e, i), Oi(t, e, a);
	return t;
}
function Ei(e, t) {
	function n(r) {
		E(t.nodeEdges(r), function(i) {
			var a = i.v, o = r === a ? i.w : a;
			!e.hasNode(o) && !Z(t, i) && (e.setNode(o, {}), e.setEdge(r, o, {}), n(o));
		});
	}
	return E(e.nodes(), n), e.nodeCount();
}
function Di(e, t) {
	return ar(t.edges(), function(n) {
		if (e.hasNode(n.v) !== e.hasNode(n.w)) return Z(t, n);
	});
}
function Oi(e, t, n) {
	E(e.nodes(), function(e) {
		t.node(e).rank += n;
	});
}
//#endregion
//#region node_modules/dagre-d3-es/src/graphlib/alg/topsort.js
u(1), u(1), ki.CycleException = Q;
function ki(e) {
	var t = {}, n = {}, r = [];
	function i(a) {
		if (Object.prototype.hasOwnProperty.call(n, a)) throw new Q();
		Object.prototype.hasOwnProperty.call(t, a) || (n[a] = !0, t[a] = !0, E(e.predecessors(a), i), delete n[a], r.push(a));
	}
	if (E(e.sinks(), i), Rr(t) !== e.nodeCount()) throw new Q();
	return r;
}
function Q() {}
Q.prototype = /* @__PURE__ */ Error();
//#endregion
//#region node_modules/dagre-d3-es/src/graphlib/alg/dfs.js
function Ai(e, t, n) {
	_(t) || (t = [t]);
	var r = (e.isDirected() ? e.successors : e.neighbors).bind(e), i = [], a = {};
	return E(t, function(t) {
		if (!e.hasNode(t)) throw Error("Graph does not have node: " + t);
		ji(e, t, n === "post", a, r, i);
	}), i;
}
function ji(e, t, n, r, i, a) {
	Object.prototype.hasOwnProperty.call(r, t) || (r[t] = !0, n || a.push(t), E(i(t), function(t) {
		ji(e, t, n, r, i, a);
	}), n && a.push(t));
}
//#endregion
//#region node_modules/dagre-d3-es/src/graphlib/alg/postorder.js
function Mi(e, t) {
	return Ai(e, t, "post");
}
//#endregion
//#region node_modules/dagre-d3-es/src/graphlib/alg/preorder.js
function Ni(e, t) {
	return Ai(e, t, "pre");
}
$.initLowLimValues = Li, $.initCutValues = Pi, $.calcCutValue = Ii, $.leaveEdge = zi, $.enterEdge = Bi, $.exchangeEdges = Vi;
function $(e) {
	e = ti(e), wi(e);
	var t = Ti(e);
	Li(t), Pi(t, e);
	for (var n, r; n = zi(t);) r = Bi(t, e, n), Vi(t, e, n, r);
}
function Pi(e, t) {
	var n = Mi(e, e.nodes());
	n = n.slice(0, n.length - 1), E(n, function(n) {
		Fi(e, t, n);
	});
}
function Fi(e, t, n) {
	var r = e.node(n).parent;
	e.edge(n, r).cutvalue = Ii(e, t, n);
}
function Ii(e, t, n) {
	var r = e.node(n).parent, i = !0, a = t.edge(n, r), o = 0;
	return a ||= (i = !1, t.edge(r, n)), o = a.weight, E(t.nodeEdges(n), function(a) {
		var s = a.v === n, c = s ? a.w : a.v;
		if (c !== r) {
			var l = s === i, u = t.edge(a).weight;
			if (o += l ? u : -u, Ui(e, n, c)) {
				var d = e.edge(n, c).cutvalue;
				o += l ? -d : d;
			}
		}
	}), o;
}
function Li(e, t) {
	arguments.length < 2 && (t = e.nodes()[0]), Ri(e, {}, 1, t);
}
function Ri(e, t, n, r, i) {
	var a = n, o = e.node(r);
	return t[r] = !0, E(e.neighbors(r), function(i) {
		Object.prototype.hasOwnProperty.call(t, i) || (n = Ri(e, t, n, i, r));
	}), o.low = a, o.lim = n++, i ? o.parent = i : delete o.parent, n;
}
function zi(e) {
	return Kn(e.edges(), function(t) {
		return e.edge(t).cutvalue < 0;
	});
}
function Bi(e, t, n) {
	var r = n.v, i = n.w;
	t.hasEdge(r, i) || (r = n.w, i = n.v);
	var a = e.node(r), o = e.node(i), s = a, c = !1;
	return a.lim > o.lim && (s = o, c = !0), ar(x(t.edges(), function(t) {
		return c === Wi(e, e.node(t.v), s) && c !== Wi(e, e.node(t.w), s);
	}), function(e) {
		return Z(t, e);
	});
}
function Vi(e, t, n, r) {
	var i = n.v, a = n.w;
	e.removeEdge(i, a), e.setEdge(r.v, r.w, {}), Li(e), Pi(e, t), Hi(e, t);
}
function Hi(e, t) {
	var n = Ni(e, Kn(e.nodes(), function(e) {
		return !t.node(e).parent;
	}));
	n = n.slice(1), E(n, function(n) {
		var r = e.node(n).parent, i = t.edge(n, r), a = !1;
		i || (i = t.edge(r, n), a = !0), t.node(n).rank = t.node(r).rank + (a ? i.minlen : -i.minlen);
	});
}
function Ui(e, t, n) {
	return e.hasEdge(t, n);
}
function Wi(e, t, n) {
	return n.low <= t.lim && t.lim <= n.lim;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/rank/index.js
function Gi(e) {
	switch (e.graph().ranker) {
		case "network-simplex":
			Ji(e);
			break;
		case "tight-tree":
			qi(e);
			break;
		case "longest-path":
			Ki(e);
			break;
		default: Ji(e);
	}
}
var Ki = wi;
function qi(e) {
	wi(e), Ti(e);
}
function Ji(e) {
	$(e);
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/nesting-graph.js
function Yi(e) {
	var t = Y(e, "root", {}, "_root"), n = Zi(e), r = U(w(n)) - 1, i = 2 * r + 1;
	e.graph().nestingRoot = t, E(e.edges(), function(t) {
		e.edge(t).minlen *= i;
	});
	var a = Qi(e) + 1;
	E(e.children(), function(o) {
		Xi(e, t, i, a, r, n, o);
	}), e.graph().nodeRankFactor = i;
}
function Xi(e, t, n, r, i, a, o) {
	var s = e.children(o);
	if (!s.length) {
		o !== t && e.setEdge(t, o, {
			weight: 0,
			minlen: n
		});
		return;
	}
	var c = oi(e, "_bt"), l = oi(e, "_bb"), u = e.node(o);
	e.setParent(c, o), u.borderTop = c, e.setParent(l, o), u.borderBottom = l, E(s, function(s) {
		Xi(e, t, n, r, i, a, s);
		var u = e.node(s), d = u.borderTop ? u.borderTop : s, f = u.borderBottom ? u.borderBottom : s, p = u.borderTop ? r : 2 * r, m = d === f ? i - a[o] + 1 : 1;
		e.setEdge(c, d, {
			weight: p,
			minlen: m,
			nestingEdge: !0
		}), e.setEdge(f, l, {
			weight: p,
			minlen: m,
			nestingEdge: !0
		});
	}), e.parent(o) || e.setEdge(t, c, {
		weight: 0,
		minlen: i + a[o]
	});
}
function Zi(e) {
	var t = {};
	function n(r, i) {
		var a = e.children(r);
		a && a.length && E(a, function(e) {
			n(e, i + 1);
		}), t[r] = i;
	}
	return E(e.children(), function(e) {
		n(e, 1);
	}), t;
}
function Qi(e) {
	return T(e.edges(), function(t, n) {
		return t + e.edge(n).weight;
	}, 0);
}
function $i(e) {
	var t = e.graph();
	e.removeNode(t.nestingRoot), delete t.nestingRoot, E(e.edges(), function(t) {
		e.edge(t).nestingEdge && e.removeEdge(t);
	});
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/add-subgraph-constraints.js
function ea(e, t, n) {
	var r = {}, i;
	E(n, function(n) {
		for (var a = e.parent(n), o, s; a;) {
			if (o = e.parent(a), o ? (s = r[o], r[o] = a) : (s = i, i = a), s && s !== a) {
				t.setEdge(s, a);
				return;
			}
			a = o;
		}
	});
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/build-layer-graph.js
function ta(e, t, n) {
	var r = na(e), i = new O({ compound: !0 }).setGraph({ root: r }).setDefaultNodeLabel(function(t) {
		return e.node(t);
	});
	return E(e.nodes(), function(a) {
		var o = e.node(a), s = e.parent(a);
		(o.rank === t || o.minRank <= t && t <= o.maxRank) && (i.setNode(a), i.setParent(a, s || r), E(e[n](a), function(t) {
			var n = t.v === a ? t.w : t.v, r = i.edge(n, a), o = D(r) ? 0 : r.weight;
			i.setEdge(n, a, { weight: e.edge(t).weight + o });
		}), Object.prototype.hasOwnProperty.call(o, "minRank") && i.setNode(a, {
			borderLeft: o.borderLeft[t],
			borderRight: o.borderRight[t]
		}));
	}), i;
}
function na(e) {
	for (var t; e.hasNode(t = Br("_root")););
	return t;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/cross-count.js
function ra(e, t) {
	for (var n = 0, r = 1; r < t.length; ++r) n += ia(e, t[r - 1], t[r]);
	return n;
}
function ia(e, t, n) {
	for (var r = Hr(n, V(n, function(e, t) {
		return t;
	})), i = L(V(t, function(t) {
		return J(V(e.outEdges(t), function(t) {
			return {
				pos: r[t.w],
				weight: e.edge(t).weight
			};
		}), "pos");
	})), a = 1; a < n.length;) a <<= 1;
	var o = 2 * a - 1;
	--a;
	var s = V(Array(o), function() {
		return 0;
	}), c = 0;
	return E(i.forEach(function(e) {
		var t = e.pos + a;
		s[t] += e.weight;
		for (var n = 0; t > 0;) t % 2 && (n += s[t + 1]), t = t - 1 >> 1, s[t] += e.weight;
		c += e.weight * n;
	})), c;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/init-order.js
function aa(e) {
	var t = {}, n = x(e.nodes(), function(t) {
		return !e.children(t).length;
	}), r = V(q(U(V(n, function(t) {
		return e.node(t).rank;
	})) + 1), function() {
		return [];
	});
	function i(n) {
		$n(t, n) || (t[n] = !0, r[e.node(n).rank].push(n), E(e.successors(n), i));
	}
	return E(J(n, function(t) {
		return e.node(t).rank;
	}), i), r;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/barycenter.js
function oa(e, t) {
	return V(t, function(t) {
		var n = e.inEdges(t);
		if (n.length) {
			var r = T(n, function(t, n) {
				var r = e.edge(n), i = e.node(n.v);
				return {
					sum: t.sum + r.weight * i.order,
					weight: t.weight + r.weight
				};
			}, {
				sum: 0,
				weight: 0
			});
			return {
				v: t,
				barycenter: r.sum / r.weight,
				weight: r.weight
			};
		} else return { v: t };
	});
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/resolve-conflicts.js
function sa(e, t) {
	var n = {};
	return E(e, function(e, t) {
		var r = n[e.v] = {
			indegree: 0,
			in: [],
			out: [],
			vs: [e.v],
			i: t
		};
		D(e.barycenter) || (r.barycenter = e.barycenter, r.weight = e.weight);
	}), E(t.edges(), function(e) {
		var t = n[e.v], r = n[e.w];
		!D(t) && !D(r) && (r.indegree++, t.out.push(n[e.w]));
	}), ca(x(n, function(e) {
		return !e.indegree;
	}));
}
function ca(e) {
	var t = [];
	function n(e) {
		return function(t) {
			t.merged || (D(t.barycenter) || D(e.barycenter) || t.barycenter >= e.barycenter) && la(e, t);
		};
	}
	function r(t) {
		return function(n) {
			n.in.push(t), --n.indegree === 0 && e.push(n);
		};
	}
	for (; e.length;) {
		var i = e.pop();
		t.push(i), E(i.in.reverse(), n(i)), E(i.out, r(i));
	}
	return V(x(t, function(e) {
		return !e.merged;
	}), function(e) {
		return K(e, [
			"vs",
			"i",
			"barycenter",
			"weight"
		]);
	});
}
function la(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;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/sort.js
function ua(e, t) {
	var n = ci(e, function(e) {
		return Object.prototype.hasOwnProperty.call(e, "barycenter");
	}), r = n.lhs, i = J(n.rhs, function(e) {
		return -e.i;
	}), a = [], o = 0, s = 0, c = 0;
	r.sort(fa(!!t)), c = da(a, i, c), E(r, function(e) {
		c += e.vs.length, a.push(e.vs), o += e.barycenter * e.weight, s += e.weight, c = da(a, i, c);
	});
	var l = { vs: L(a) };
	return s && (l.barycenter = o / s, l.weight = s), l;
}
function da(e, t, n) {
	for (var r; t.length && (r = B(t)).i <= n;) t.pop(), e.push(r.vs), n++;
	return n;
}
function fa(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;
	};
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/sort-subgraph.js
function pa(e, t, n, r) {
	var i = e.children(t), a = e.node(t), o = a ? a.borderLeft : void 0, s = a ? a.borderRight : void 0, c = {};
	o && (i = x(i, function(e) {
		return e !== o && e !== s;
	}));
	var l = oa(e, i);
	E(l, function(t) {
		if (e.children(t.v).length) {
			var i = pa(e, t.v, n, r);
			c[t.v] = i, Object.prototype.hasOwnProperty.call(i, "barycenter") && ha(t, i);
		}
	});
	var u = sa(l, n);
	ma(u, c);
	var d = ua(u, r);
	if (o && (d.vs = L([
		o,
		d.vs,
		s
	]), e.predecessors(o).length)) {
		var f = e.node(e.predecessors(o)[0]), p = e.node(e.predecessors(s)[0]);
		Object.prototype.hasOwnProperty.call(d, "barycenter") || (d.barycenter = 0, d.weight = 0), d.barycenter = (d.barycenter * d.weight + f.order + p.order) / (d.weight + 2), d.weight += 2;
	}
	return d;
}
function ma(e, t) {
	E(e, function(e) {
		e.vs = L(e.vs.map(function(e) {
			return t[e] ? t[e].vs : e;
		}));
	});
}
function ha(e, t) {
	D(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);
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/order/index.js
function ga(e) {
	var t = si(e), n = _a(e, q(1, t + 1), "inEdges"), r = _a(e, q(t - 1, -1, -1), "outEdges"), i = aa(e);
	ya(e, i);
	for (var a = Infinity, o, s = 0, c = 0; c < 4; ++s, ++c) {
		va(s % 2 ? n : r, s % 4 >= 2), i = X(e);
		var l = ra(e, i);
		l < a && (c = 0, o = Nn(i), a = l);
	}
	ya(e, o);
}
function _a(e, t, n) {
	return V(t, function(t) {
		return ta(e, t, n);
	});
}
function va(e, t) {
	var n = new O();
	E(e, function(e) {
		var r = e.graph().root, i = pa(e, r, n, t);
		E(i.vs, function(t, n) {
			e.node(t).order = n;
		}), ea(e, n, i.vs);
	});
}
function ya(e, t) {
	E(t, function(t) {
		E(t, function(t, n) {
			e.node(t).order = n;
		});
	});
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/parent-dummy-chains.js
function ba(e) {
	var t = Sa(e);
	E(e.graph().dummyChains, function(n) {
		for (var r = e.node(n), i = r.edgeObj, a = xa(e, t, i.v, i.w), o = a.path, s = a.lca, c = 0, l = o[c], u = !0; n !== i.w;) {
			if (r = e.node(n), u) {
				for (; (l = o[c]) !== s && e.node(l).maxRank < r.rank;) c++;
				l === s && (u = !1);
			}
			if (!u) {
				for (; c < o.length - 1 && e.node(l = o[c + 1]).minRank <= r.rank;) c++;
				l = o[c];
			}
			e.setParent(n, l), n = e.successors(n)[0];
		}
	});
}
function xa(e, t, n, r) {
	var i = [], a = [], o = Math.min(t[n].low, t[r].low), s = Math.max(t[n].lim, t[r].lim), c = n, l;
	do
		c = e.parent(c), i.push(c);
	while (c && (t[c].low > o || s > t[c].lim));
	for (l = c, c = r; (c = e.parent(c)) !== l;) a.push(c);
	return {
		path: i.concat(a.reverse()),
		lca: l
	};
}
function Sa(e) {
	var t = {}, n = 0;
	function r(i) {
		var a = n;
		E(e.children(i), r), t[i] = {
			low: a,
			lim: n++
		};
	}
	return E(e.children(), r), t;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/position/bk.js
function Ca(e, t) {
	var n = {};
	function r(t, r) {
		var i = 0, a = 0, o = t.length, s = B(r);
		return E(r, function(t, c) {
			var l = Ta(e, t), u = l ? e.node(l).order : o;
			(l || t === s) && (E(r.slice(a, c + 1), function(t) {
				E(e.predecessors(t), function(r) {
					var a = e.node(r), o = a.order;
					(o < i || u < o) && !(a.dummy && e.node(t).dummy) && Ea(n, r, t);
				});
			}), a = c + 1, i = u);
		}), r;
	}
	return T(t, r), n;
}
function wa(e, t) {
	var n = {};
	function r(t, r, i, a, o) {
		var s;
		E(q(r, i), function(r) {
			s = t[r], e.node(s).dummy && E(e.predecessors(s), function(t) {
				var r = e.node(t);
				r.dummy && (r.order < a || r.order > o) && Ea(n, t, s);
			});
		});
	}
	function i(t, n) {
		var i = -1, a, o = 0;
		return E(n, function(s, c) {
			if (e.node(s).dummy === "border") {
				var l = e.predecessors(s);
				l.length && (a = e.node(l[0]).order, r(n, o, c, i, a), o = c, i = a);
			}
			r(n, o, n.length, a, t.length);
		}), n;
	}
	return T(t, i), n;
}
function Ta(e, t) {
	if (e.node(t).dummy) return Kn(e.predecessors(t), function(t) {
		return e.node(t).dummy;
	});
}
function Ea(e, t, n) {
	if (t > n) {
		var r = t;
		t = n, n = r;
	}
	Object.prototype.hasOwnProperty.call(e, t) || Object.defineProperty(e, t, {
		enumerable: !0,
		configurable: !0,
		value: {},
		writable: !0
	});
	var i = e[t];
	Object.defineProperty(i, n, {
		enumerable: !0,
		configurable: !0,
		value: !0,
		writable: !0
	});
}
function Da(e, t, n) {
	if (t > n) {
		var r = t;
		t = n, n = r;
	}
	return !!e[t] && Object.prototype.hasOwnProperty.call(e[t], n);
}
function Oa(e, t, n, r) {
	var i = {}, a = {}, o = {};
	return E(t, function(e) {
		E(e, function(e, t) {
			i[e] = e, a[e] = e, o[e] = t;
		});
	}), E(t, function(e) {
		var t = -1;
		E(e, function(e) {
			var s = r(e);
			if (s.length) {
				s = J(s, function(e) {
					return o[e];
				});
				for (var c = (s.length - 1) / 2, l = Math.floor(c), u = Math.ceil(c); l <= u; ++l) {
					var d = s[l];
					a[e] === e && t < o[d] && !Da(n, e, d) && (a[d] = e, a[e] = i[e] = i[d], t = o[d]);
				}
			}
		});
	}), {
		root: i,
		align: a
	};
}
function ka(e, t, n, r, i) {
	var a = {}, o = Aa(e, t, n, i), s = i ? "borderLeft" : "borderRight";
	function c(e, t) {
		for (var n = o.nodes(), r = n.pop(), i = {}; r;) i[r] ? e(r) : (i[r] = !0, n.push(r), n = n.concat(t(r))), r = n.pop();
	}
	function l(e) {
		a[e] = o.inEdges(e).reduce(function(e, t) {
			return Math.max(e, a[t.v] + o.edge(t));
		}, 0);
	}
	function u(t) {
		var n = o.outEdges(t).reduce(function(e, t) {
			return Math.min(e, a[t.w] - o.edge(t));
		}, Infinity), r = e.node(t);
		n !== Infinity && r.borderType !== s && (a[t] = Math.max(a[t], n));
	}
	return c(l, o.predecessors.bind(o)), c(u, o.successors.bind(o)), E(r, function(e) {
		a[e] = a[n[e]];
	}), a;
}
function Aa(e, t, n, r) {
	var i = new O(), a = e.graph(), o = Fa(a.nodesep, a.edgesep, r);
	return E(t, function(t) {
		var r;
		E(t, function(t) {
			var a = n[t];
			if (i.setNode(a), r) {
				var s = n[r], c = i.edge(s, a);
				i.setEdge(s, a, Math.max(o(e, t, r), c || 0));
			}
			r = t;
		});
	}), i;
}
function ja(e, t) {
	return ar(w(t), function(t) {
		var n = -Infinity, r = Infinity;
		return Jn(t, function(t, i) {
			var a = Ia(e, i) / 2;
			n = Math.max(t + a, n), r = Math.min(t - a, r);
		}), n - r;
	});
}
function Ma(e, t) {
	var n = w(t), r = W(n), i = U(n);
	E(["u", "d"], function(n) {
		E(["l", "r"], function(a) {
			var o = n + a, s = e[o], c;
			if (s !== t) {
				var l = w(s);
				c = a === "l" ? r - W(l) : i - U(l), c && (e[o] = H(s, function(e) {
					return e + c;
				}));
			}
		});
	});
}
function Na(e, t) {
	return H(e.ul, function(n, r) {
		if (t) return e[t.toLowerCase()][r];
		var i = J(V(e, r));
		return (i[1] + i[2]) / 2;
	});
}
function Pa(e) {
	var t = X(e), n = ir(Ca(e, t), wa(e, t)), r = {}, i;
	return E(["u", "d"], function(a) {
		i = a === "u" ? t : w(t).reverse(), E(["l", "r"], function(t) {
			t === "r" && (i = V(i, function(e) {
				return w(e).reverse();
			}));
			var o = (a === "u" ? e.predecessors : e.successors).bind(e), s = Oa(e, i, n, o), c = ka(e, i, s.root, s.align, t === "r");
			t === "r" && (c = H(c, function(e) {
				return -e;
			})), r[a + t] = c;
		});
	}), Ma(r, ja(e, r)), Na(r, e.graph().align);
}
function Fa(e, t, n) {
	return function(r, i, a) {
		var o = r.node(i), s = r.node(a), c = 0, l;
		if (c += o.width / 2, Object.prototype.hasOwnProperty.call(o, "labelpos")) switch (o.labelpos.toLowerCase()) {
			case "l":
				l = -o.width / 2;
				break;
			case "r":
				l = o.width / 2;
				break;
		}
		if (l && (c += n ? l : -l), l = 0, c += (o.dummy ? t : e) / 2, c += (s.dummy ? t : e) / 2, c += s.width / 2, Object.prototype.hasOwnProperty.call(s, "labelpos")) switch (s.labelpos.toLowerCase()) {
			case "l":
				l = s.width / 2;
				break;
			case "r":
				l = -s.width / 2;
				break;
		}
		return l && (c += n ? l : -l), l = 0, c;
	};
}
function Ia(e, t) {
	return e.node(t).width;
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/position/index.js
function La(e) {
	e = ni(e), Ra(e), Yn(Pa(e), function(t, n) {
		e.node(n).x = t;
	});
}
function Ra(e) {
	var t = X(e), n = e.graph().ranksep, r = 0;
	E(t, function(t) {
		var i = U(V(t, function(t) {
			return e.node(t).height;
		}));
		E(t, function(t) {
			e.node(t).y = r + i / 2;
		}), r += i + n;
	});
}
//#endregion
//#region node_modules/dagre-d3-es/src/dagre/layout.js
function za(e, t) {
	var n = t && t.debugTiming ? li : ui;
	n("layout", () => {
		var t = n("  buildLayoutGraph", () => Xa(e));
		n("  runLayout", () => Ba(t, n)), n("  updateInputGraph", () => Va(e, t));
	});
}
function Ba(e, t) {
	t("    makeSpaceForEdgeLabels", () => Za(e)), t("    removeSelfEdges", () => oo(e)), t("    acyclic", () => Qr(e)), t("    nestingGraph.run", () => Yi(e)), t("    rank", () => Gi(ni(e))), t("    injectEdgeLabelProxies", () => Qa(e)), t("    removeEmptyRanks", () => ai(e)), t("    nestingGraph.cleanup", () => $i(e)), t("    normalizeRanks", () => ii(e)), t("    assignRankMinMax", () => $a(e)), t("    removeEdgeLabelProxies", () => eo(e)), t("    normalize.run", () => xi(e)), t("    parentDummyChains", () => ba(e)), t("    addBorderSegments", () => di(e)), t("    order", () => ga(e)), t("    insertSelfEdges", () => so(e)), t("    adjustCoordinateSystem", () => pi(e)), t("    position", () => La(e)), t("    positionSelfEdges", () => co(e)), t("    removeBorderNodes", () => ao(e)), t("    normalize.undo", () => Ci(e)), t("    fixupEdgeLabelCoords", () => ro(e)), t("    undoCoordinateSystem", () => mi(e)), t("    translateGraph", () => to(e)), t("    assignNodeIntersects", () => no(e)), t("    reversePoints", () => io(e)), t("    acyclic.undo", () => ei(e));
}
function Va(e, t) {
	E(e.nodes(), function(n) {
		var r = e.node(n), i = t.node(n);
		r && (r.x = i.x, r.y = i.y, t.children(n).length && (r.width = i.width, r.height = i.height));
	}), E(e.edges(), function(n) {
		var r = e.edge(n), i = t.edge(n);
		r.points = i.points, Object.prototype.hasOwnProperty.call(i, "x") && (r.x = i.x, r.y = i.y);
	}), e.graph().width = t.graph().width, e.graph().height = t.graph().height;
}
var Ha = [
	"nodesep",
	"edgesep",
	"ranksep",
	"marginx",
	"marginy"
], Ua = {
	ranksep: 50,
	edgesep: 20,
	nodesep: 50,
	rankdir: "tb"
}, Wa = [
	"acyclicer",
	"ranker",
	"rankdir",
	"align"
], Ga = ["width", "height"], Ka = {
	width: 0,
	height: 0
}, qa = [
	"minlen",
	"weight",
	"width",
	"height",
	"labeloffset"
], Ja = {
	minlen: 1,
	weight: 1,
	width: 0,
	height: 0,
	labeloffset: 10,
	labelpos: "r"
}, Ya = ["labelpos"];
function Xa(e) {
	var t = new O({
		multigraph: !0,
		compound: !0
	}), n = uo(e.graph());
	return t.setGraph(ir({}, Ua, lo(n, Ha), K(n, Wa))), E(e.nodes(), function(n) {
		var r = uo(e.node(n));
		t.setNode(n, Ln(lo(r, Ga), Ka)), t.setParent(n, e.parent(n));
	}), E(e.edges(), function(n) {
		var r = uo(e.edge(n));
		t.setEdge(n, ir({}, Ja, lo(r, qa), K(r, Ya)));
	}), t;
}
function Za(e) {
	var t = e.graph();
	t.ranksep /= 2, E(e.edges(), function(n) {
		var r = e.edge(n);
		r.minlen *= 2, r.labelpos.toLowerCase() !== "c" && (t.rankdir === "TB" || t.rankdir === "BT" ? r.width += r.labeloffset : r.height += r.labeloffset);
	});
}
function Qa(e) {
	E(e.edges(), function(t) {
		var n = e.edge(t);
		if (n.width && n.height) {
			var r = e.node(t.v);
			Y(e, "edge-proxy", {
				rank: (e.node(t.w).rank - r.rank) / 2 + r.rank,
				e: t
			}, "_ep");
		}
	});
}
function $a(e) {
	var t = 0;
	E(e.nodes(), function(n) {
		var r = e.node(n);
		r.borderTop && (r.minRank = e.node(r.borderTop).rank, r.maxRank = e.node(r.borderBottom).rank, t = U(t, r.maxRank));
	}), e.graph().maxRank = t;
}
function eo(e) {
	E(e.nodes(), function(t) {
		var n = e.node(t);
		n.dummy === "edge-proxy" && (e.edge(n.e).labelRank = n.rank, e.removeNode(t));
	});
}
function to(e) {
	var t = Infinity, n = 0, r = Infinity, i = 0, a = e.graph(), o = a.marginx || 0, s = a.marginy || 0;
	function c(e) {
		var a = e.x, o = e.y, s = e.width, c = e.height;
		t = Math.min(t, a - s / 2), n = Math.max(n, a + s / 2), r = Math.min(r, o - c / 2), i = Math.max(i, o + c / 2);
	}
	E(e.nodes(), function(t) {
		c(e.node(t));
	}), E(e.edges(), function(t) {
		var n = e.edge(t);
		Object.prototype.hasOwnProperty.call(n, "x") && c(n);
	}), t -= o, r -= s, E(e.nodes(), function(n) {
		var i = e.node(n);
		i.x -= t, i.y -= r;
	}), E(e.edges(), function(n) {
		var i = e.edge(n);
		E(i.points, function(e) {
			e.x -= t, e.y -= r;
		}), Object.prototype.hasOwnProperty.call(i, "x") && (i.x -= t), Object.prototype.hasOwnProperty.call(i, "y") && (i.y -= r);
	}), a.width = n - t + o, a.height = i - r + s;
}
function no(e) {
	E(e.edges(), function(t) {
		var n = e.edge(t), r = e.node(t.v), i = e.node(t.w), a, o;
		n.points ? (a = n.points[0], o = n.points[n.points.length - 1]) : (n.points = [], a = i, o = r), n.points.unshift(ri(r, a)), n.points.push(ri(i, o));
	});
}
function ro(e) {
	E(e.edges(), function(t) {
		var n = e.edge(t);
		if (Object.prototype.hasOwnProperty.call(n, "x")) switch ((n.labelpos === "l" || n.labelpos === "r") && (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;
				break;
		}
	});
}
function io(e) {
	E(e.edges(), function(t) {
		var n = e.edge(t);
		n.reversed && n.points.reverse();
	});
}
function ao(e) {
	E(e.nodes(), function(t) {
		if (e.children(t).length) {
			var n = e.node(t), r = e.node(n.borderTop), i = e.node(n.borderBottom), a = e.node(B(n.borderLeft)), o = e.node(B(n.borderRight));
			n.width = Math.abs(o.x - a.x), n.height = Math.abs(i.y - r.y), n.x = a.x + n.width / 2, n.y = r.y + n.height / 2;
		}
	}), E(e.nodes(), function(t) {
		e.node(t).dummy === "border" && e.removeNode(t);
	});
}
function oo(e) {
	E(e.edges(), function(t) {
		if (t.v === t.w) {
			var n = e.node(t.v);
			n.selfEdges ||= [], n.selfEdges.push({
				e: t,
				label: e.edge(t)
			}), e.removeEdge(t);
		}
	});
}
function so(e) {
	E(X(e), function(t) {
		var n = 0;
		E(t, function(t, r) {
			var i = e.node(t);
			i.order = r + n, E(i.selfEdges, function(t) {
				Y(e, "selfedge", {
					width: t.label.width,
					height: t.label.height,
					rank: i.rank,
					order: r + ++n,
					e: t.e,
					label: t.label
				}, "_se");
			}), delete i.selfEdges;
		});
	});
}
function co(e) {
	E(e.nodes(), function(t) {
		var n = e.node(t);
		if (n.dummy === "selfedge") {
			var r = e.node(n.e.v), i = r.x + r.width / 2, a = r.y, o = n.x - i, s = r.height / 2;
			e.setEdge(n.e, n.label), e.removeNode(t), n.label.points = [
				{
					x: i + 2 * o / 3,
					y: a - s
				},
				{
					x: i + 5 * o / 6,
					y: a - s
				},
				{
					x: i + o,
					y: a
				},
				{
					x: i + 5 * o / 6,
					y: a + s
				},
				{
					x: i + 2 * o / 3,
					y: a + s
				}
			], n.label.x = n.x, n.label.y = n.y;
		}
	});
}
function lo(e, t) {
	return H(K(e, t), Number);
}
function uo(e) {
	var t = {};
	return E(e, function(e, n) {
		t[n.toLowerCase()] = e;
	}), t;
}
//#endregion
export { V as n, z as r, za as t };

//# sourceMappingURL=dagre-3-RnF0EK.js.map