-
Notifications
You must be signed in to change notification settings - Fork 12
/
chunk-OFVMVYRI.js
29 lines (29 loc) · 200 KB
/
chunk-OFVMVYRI.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import{a as Qo,b as Ko,c as Jo}from"./chunk-GMAX22QU.js";import"./chunk-OT5GAY2Z.js";import{a as le,b as Yo,d as Wo}from"./chunk-E4FB6IMX.js";import{a as Xo}from"./chunk-ENUDN6ZE.js";import{f as Sn,g as wn,i as It,j as Zo}from"./chunk-MVBTB2OL.js";import"./chunk-QH77Q77Q.js";import{B as Fo,Gb as bn,Hc as kn,Ib as _n,Jb as zn,P as Ro,Rb as Cn,Tb as Vo,Ua as Lo,Ya as Po,sc as Uo,tb as $o,wa as jo}from"./chunk-SBXTKZGS.js";import{Aa as Gi,Ab as xn,B as bo,Ba as At,Ca as Bt,D as So,Da as Fi,Db as Mt,Ea as Ri,Eb as Et,Fa as Q,Fb as P,Ga as pn,Hb as ji,Hc as Go,Ja as zo,K as wo,Kd as Yi,La as Vt,Ld as qo,Md as Ht,Na as se,O as _o,Ob as qt,Pd as Nn,Rb as Li,Rd as Ho,Sb as Pi,Tb as d,Tc as En,Ub as l,Vb as U,Wb as $i,Xb as Vi,Yb as De,Yc as Xi,Zb as qi,_ as cn,_b as Oo,ac as et,cc as Y,dc as To,ec as Do,f as Oe,g as go,ga as hn,h as xo,ic as vn,jc as yt,kb as I,kc as nt,la as mn,lb as at,lc as it,mc as Hi,nb as gn,nc as a,oc as Ui,pc as Zi,qa as mt,r as vo,ra as fn,rb as Co,sa as Te,sc as Ao,tb as No,tc as Bo,uc as Mo,vb as ko,vc as Io,wc as Ae,wd as yn,x as Eo,y as yo,yc as Be}from"./chunk-WVUROUXZ.js";import{a as vt}from"./chunk-RKLIRILV.js";var Wi=Math.PI,Qi=2*Wi,Ut=1e-6,cd=Qi-Ut;function Ki(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function ta(){return new Ki}Ki.prototype=ta.prototype={constructor:Ki,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,i){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+i)},bezierCurveTo:function(t,e,n,i,r,o){this._+="C"+ +t+","+ +e+","+ +n+","+ +i+","+(this._x1=+r)+","+(this._y1=+o)},arcTo:function(t,e,n,i,r){t=+t,e=+e,n=+n,i=+i,r=+r;var o=this._x1,s=this._y1,u=n-t,c=i-e,h=o-t,m=s-e,f=h*h+m*m;if(r<0)throw new Error("negative radius: "+r);if(this._x1===null)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(f>Ut)if(!(Math.abs(m*u-c*h)>Ut)||!r)this._+="L"+(this._x1=t)+","+(this._y1=e);else{var p=n-o,x=i-s,E=u*u+c*c,v=p*p+x*x,S=Math.sqrt(E),b=Math.sqrt(f),z=r*Math.tan((Wi-Math.acos((E+f-v)/(2*S*b)))/2),k=z/b,N=z/S;Math.abs(k-1)>Ut&&(this._+="L"+(t+k*h)+","+(e+k*m)),this._+="A"+r+","+r+",0,0,"+ +(m*p>h*x)+","+(this._x1=t+N*u)+","+(this._y1=e+N*c)}},arc:function(t,e,n,i,r,o){t=+t,e=+e,n=+n,o=!!o;var s=n*Math.cos(i),u=n*Math.sin(i),c=t+s,h=e+u,m=1^o,f=o?i-r:r-i;if(n<0)throw new Error("negative radius: "+n);this._x1===null?this._+="M"+c+","+h:(Math.abs(this._x1-c)>Ut||Math.abs(this._y1-h)>Ut)&&(this._+="L"+c+","+h),n&&(f<0&&(f=f%Qi+Qi),f>cd?this._+="A"+n+","+n+",0,1,"+m+","+(t-s)+","+(e-u)+"A"+n+","+n+",0,1,"+m+","+(this._x1=c)+","+(this._y1=h):f>Ut&&(this._+="A"+n+","+n+",0,"+ +(f>=Wi)+","+m+","+(this._x1=t+n*Math.cos(r))+","+(this._y1=e+n*Math.sin(r))))},rect:function(t,e,n,i){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +i+"h"+-n+"Z"},toString:function(){return this._}};var Ji=ta;function Zt(t){return function(){return t}}var Pg=Array.prototype.slice;function ea(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function na(t){this._context=t}na.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e);break}}};function ue(t){return new na(t)}function ia(t){return t[0]}function ra(t){return t[1]}function On(t,e){var n=Zt(!0),i=null,r=ue,o=null;t=typeof t=="function"?t:t===void 0?ia:Zt(t),e=typeof e=="function"?e:e===void 0?ra:Zt(e);function s(u){var c,h=(u=ea(u)).length,m,f=!1,p;for(i==null&&(o=r(p=Ji())),c=0;c<=h;++c)!(c<h&&n(m=u[c],c,u))===f&&((f=!f)?o.lineStart():o.lineEnd()),f&&o.point(+t(m,c,u),+e(m,c,u));if(p)return o=null,p+""||null}return s.x=function(u){return arguments.length?(t=typeof u=="function"?u:Zt(+u),s):t},s.y=function(u){return arguments.length?(e=typeof u=="function"?u:Zt(+u),s):e},s.defined=function(u){return arguments.length?(n=typeof u=="function"?u:Zt(!!u),s):n},s.curve=function(u){return arguments.length?(r=u,i!=null&&(o=r(i)),s):r},s.context=function(u){return arguments.length?(u==null?i=o=null:o=r(i=u),s):i},s}function oa(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function aa(t){this._context=t}aa.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:oa(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:oa(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function tr(t){return new aa(t)}var hd={value:()=>{}};function la(){for(var t=0,e=arguments.length,n={},i;t<e;++t){if(!(i=arguments[t]+"")||i in n||/[\s.]/.test(i))throw new Error("illegal type: "+i);n[i]=[]}return new Tn(n)}function Tn(t){this._=t}function md(t,e){return t.trim().split(/^|\s+/).map(function(n){var i="",r=n.indexOf(".");if(r>=0&&(i=n.slice(r+1),n=n.slice(0,r)),n&&!e.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:i}})}Tn.prototype=la.prototype={constructor:Tn,on:function(t,e){var n=this._,i=md(t+"",n),r,o=-1,s=i.length;if(arguments.length<2){for(;++o<s;)if((r=(t=i[o]).type)&&(r=fd(n[r],t.name)))return r;return}if(e!=null&&typeof e!="function")throw new Error("invalid callback: "+e);for(;++o<s;)if(r=(t=i[o]).type)n[r]=sa(n[r],t.name,e);else if(e==null)for(r in n)n[r]=sa(n[r],t.name,null);return this},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new Tn(t)},call:function(t,e){if((r=arguments.length-2)>0)for(var n=new Array(r),i=0,r,o;i<r;++i)n[i]=arguments[i+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=this._[t],i=0,r=o.length;i<r;++i)o[i].value.apply(e,n)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var i=this._[t],r=0,o=i.length;r<o;++r)i[r].value.apply(e,n)}};function fd(t,e){for(var n=0,i=t.length,r;n<i;++n)if((r=t[n]).name===e)return r.value}function sa(t,e,n){for(var i=0,r=t.length;i<r;++i)if(t[i].name===e){t[i]=hd,t=t.slice(0,i).concat(t.slice(i+1));break}return n!=null&&t.push({name:e,value:n}),t}var Me=la;var Dn="http://www.w3.org/1999/xhtml",er={svg:"http://www.w3.org/2000/svg",xhtml:Dn,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Nt(t){var e=t+="",n=e.indexOf(":");return n>=0&&(e=t.slice(0,n))!=="xmlns"&&(t=t.slice(n+1)),er.hasOwnProperty(e)?{space:er[e],local:t}:t}function pd(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===Dn&&e.documentElement.namespaceURI===Dn?e.createElement(t):e.createElementNS(n,t)}}function gd(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function An(t){var e=Nt(t);return(e.local?gd:pd)(e)}function xd(){}function Xt(t){return t==null?xd:function(){return this.querySelector(t)}}function ua(t){typeof t!="function"&&(t=Xt(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o=e[r],s=o.length,u=i[r]=new Array(s),c,h,m=0;m<s;++m)(c=o[m])&&(h=t.call(c,c.__data__,m,o))&&("__data__"in c&&(h.__data__=c.__data__),u[m]=h);return new L(i,this._parents)}function Bn(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function vd(){return[]}function Ie(t){return t==null?vd:function(){return this.querySelectorAll(t)}}function Ed(t){return function(){var e=t.apply(this,arguments);return e==null?[]:Bn(e)}}function da(t){typeof t=="function"?t=Ed(t):t=Ie(t);for(var e=this._groups,n=e.length,i=[],r=[],o=0;o<n;++o)for(var s=e[o],u=s.length,c,h=0;h<u;++h)(c=s[h])&&(i.push(t.call(c,c.__data__,h,s)),r.push(c));return new L(i,r)}function Ge(t){return function(){return this.matches(t)}}function Mn(t){return function(e){return e.matches(t)}}var yd=Array.prototype.find;function bd(t){return function(){return yd.call(this.children,t)}}function Sd(){return this.firstElementChild}function ca(t){return this.select(t==null?Sd:bd(typeof t=="function"?t:Mn(t)))}var wd=Array.prototype.filter;function _d(){return this.children}function zd(t){return function(){return wd.call(this.children,t)}}function ha(t){return this.selectAll(t==null?_d:zd(typeof t=="function"?t:Mn(t)))}function ma(t){typeof t!="function"&&(t=Ge(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o=e[r],s=o.length,u=i[r]=[],c,h=0;h<s;++h)(c=o[h])&&t.call(c,c.__data__,h,o)&&u.push(c);return new L(i,this._parents)}function In(t){return new Array(t.length)}function fa(){return new L(this._enter||this._groups.map(In),this._parents)}function Fe(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}Fe.prototype={constructor:Fe,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};function pa(t){return function(){return t}}function Cd(t,e,n,i,r,o){for(var s=0,u,c=e.length,h=o.length;s<h;++s)(u=e[s])?(u.__data__=o[s],i[s]=u):n[s]=new Fe(t,o[s]);for(;s<c;++s)(u=e[s])&&(r[s]=u)}function Nd(t,e,n,i,r,o,s){var u,c,h=new Map,m=e.length,f=o.length,p=new Array(m),x;for(u=0;u<m;++u)(c=e[u])&&(p[u]=x=s.call(c,c.__data__,u,e)+"",h.has(x)?r[u]=c:h.set(x,c));for(u=0;u<f;++u)x=s.call(t,o[u],u,o)+"",(c=h.get(x))?(i[u]=c,c.__data__=o[u],h.delete(x)):n[u]=new Fe(t,o[u]);for(u=0;u<m;++u)(c=e[u])&&h.get(p[u])===c&&(r[u]=c)}function kd(t){return t.__data__}function ga(t,e){if(!arguments.length)return Array.from(this,kd);var n=e?Nd:Cd,i=this._parents,r=this._groups;typeof t!="function"&&(t=pa(t));for(var o=r.length,s=new Array(o),u=new Array(o),c=new Array(o),h=0;h<o;++h){var m=i[h],f=r[h],p=f.length,x=Bn(t.call(m,m&&m.__data__,h,i)),E=x.length,v=u[h]=new Array(E),S=s[h]=new Array(E),b=c[h]=new Array(p);n(m,f,v,S,b,x,e);for(var z=0,k=0,N,G;z<E;++z)if(N=v[z]){for(z>=k&&(k=z+1);!(G=S[k])&&++k<E;);N._next=G||null}}return s=new L(s,i),s._enter=u,s._exit=c,s}function xa(){return new L(this._exit||this._groups.map(In),this._parents)}function va(t,e,n){var i=this.enter(),r=this,o=this.exit();return i=typeof t=="function"?t(i):i.append(t+""),e!=null&&(r=e(r)),n==null?o.remove():n(o),i&&r?i.merge(r).order():r}function Ea(t){if(!(t instanceof L))throw new Error("invalid merge");for(var e=this._groups,n=t._groups,i=e.length,r=n.length,o=Math.min(i,r),s=new Array(i),u=0;u<o;++u)for(var c=e[u],h=n[u],m=c.length,f=s[u]=new Array(m),p,x=0;x<m;++x)(p=c[x]||h[x])&&(f[x]=p);for(;u<i;++u)s[u]=e[u];return new L(s,this._parents)}function ya(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var i=t[e],r=i.length-1,o=i[r],s;--r>=0;)(s=i[r])&&(o&&s.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(s,o),o=s);return this}function ba(t){t||(t=Od);function e(f,p){return f&&p?t(f.__data__,p.__data__):!f-!p}for(var n=this._groups,i=n.length,r=new Array(i),o=0;o<i;++o){for(var s=n[o],u=s.length,c=r[o]=new Array(u),h,m=0;m<u;++m)(h=s[m])&&(c[m]=h);c.sort(e)}return new L(r,this._parents).order()}function Od(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function Sa(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function wa(){return Array.from(this)}function _a(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var i=t[e],r=0,o=i.length;r<o;++r){var s=i[r];if(s)return s}return null}function za(){let t=0;for(let e of this)++t;return t}function Ca(){return!this.node()}function Na(t){for(var e=this._groups,n=0,i=e.length;n<i;++n)for(var r=e[n],o=0,s=r.length,u;o<s;++o)(u=r[o])&&t.call(u,u.__data__,o,r);return this}function Td(t){return function(){this.removeAttribute(t)}}function Dd(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Ad(t,e){return function(){this.setAttribute(t,e)}}function Bd(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Md(t,e){return function(){var n=e.apply(this,arguments);n==null?this.removeAttribute(t):this.setAttribute(t,n)}}function Id(t,e){return function(){var n=e.apply(this,arguments);n==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function ka(t,e){var n=Nt(t);if(arguments.length<2){var i=this.node();return n.local?i.getAttributeNS(n.space,n.local):i.getAttribute(n)}return this.each((e==null?n.local?Dd:Td:typeof e=="function"?n.local?Id:Md:n.local?Bd:Ad)(n,e))}function Gn(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Gd(t){return function(){this.style.removeProperty(t)}}function Fd(t,e,n){return function(){this.style.setProperty(t,e,n)}}function Rd(t,e,n){return function(){var i=e.apply(this,arguments);i==null?this.style.removeProperty(t):this.style.setProperty(t,i,n)}}function Oa(t,e,n){return arguments.length>1?this.each((e==null?Gd:typeof e=="function"?Rd:Fd)(t,e,n??"")):Gt(this.node(),t)}function Gt(t,e){return t.style.getPropertyValue(e)||Gn(t).getComputedStyle(t,null).getPropertyValue(e)}function jd(t){return function(){delete this[t]}}function Ld(t,e){return function(){this[t]=e}}function Pd(t,e){return function(){var n=e.apply(this,arguments);n==null?delete this[t]:this[t]=n}}function Ta(t,e){return arguments.length>1?this.each((e==null?jd:typeof e=="function"?Pd:Ld)(t,e)):this.node()[t]}function Da(t){return t.trim().split(/^|\s+/)}function nr(t){return t.classList||new Aa(t)}function Aa(t){this._node=t,this._names=Da(t.getAttribute("class")||"")}Aa.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};function Ba(t,e){for(var n=nr(t),i=-1,r=e.length;++i<r;)n.add(e[i])}function Ma(t,e){for(var n=nr(t),i=-1,r=e.length;++i<r;)n.remove(e[i])}function $d(t){return function(){Ba(this,t)}}function Vd(t){return function(){Ma(this,t)}}function qd(t,e){return function(){(e.apply(this,arguments)?Ba:Ma)(this,t)}}function Ia(t,e){var n=Da(t+"");if(arguments.length<2){for(var i=nr(this.node()),r=-1,o=n.length;++r<o;)if(!i.contains(n[r]))return!1;return!0}return this.each((typeof e=="function"?qd:e?$d:Vd)(n,e))}function Hd(){this.textContent=""}function Ud(t){return function(){this.textContent=t}}function Zd(t){return function(){var e=t.apply(this,arguments);this.textContent=e??""}}function Ga(t){return arguments.length?this.each(t==null?Hd:(typeof t=="function"?Zd:Ud)(t)):this.node().textContent}function Xd(){this.innerHTML=""}function Yd(t){return function(){this.innerHTML=t}}function Wd(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e??""}}function Fa(t){return arguments.length?this.each(t==null?Xd:(typeof t=="function"?Wd:Yd)(t)):this.node().innerHTML}function Qd(){this.nextSibling&&this.parentNode.appendChild(this)}function Ra(){return this.each(Qd)}function Kd(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function ja(){return this.each(Kd)}function La(t){var e=typeof t=="function"?t:An(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}function Jd(){return null}function Pa(t,e){var n=typeof t=="function"?t:An(t),i=e==null?Jd:typeof e=="function"?e:Xt(e);return this.select(function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)})}function tc(){var t=this.parentNode;t&&t.removeChild(this)}function $a(){return this.each(tc)}function ec(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function nc(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Va(t){return this.select(t?nc:ec)}function qa(t){return arguments.length?this.property("__data__",t):this.node().__data__}function ic(t){return function(e){t.call(this,e,this.__data__)}}function rc(t){return t.trim().split(/^|\s+/).map(function(e){var n="",i=e.indexOf(".");return i>=0&&(n=e.slice(i+1),e=e.slice(0,i)),{type:e,name:n}})}function oc(t){return function(){var e=this.__on;if(e){for(var n=0,i=-1,r=e.length,o;n<r;++n)o=e[n],(!t.type||o.type===t.type)&&o.name===t.name?this.removeEventListener(o.type,o.listener,o.options):e[++i]=o;++i?e.length=i:delete this.__on}}}function ac(t,e,n){return function(){var i=this.__on,r,o=ic(e);if(i){for(var s=0,u=i.length;s<u;++s)if((r=i[s]).type===t.type&&r.name===t.name){this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=o,r.options=n),r.value=e;return}}this.addEventListener(t.type,o,n),r={type:t.type,name:t.name,value:e,listener:o,options:n},i?i.push(r):this.__on=[r]}}function Ha(t,e,n){var i=rc(t+""),r,o=i.length,s;if(arguments.length<2){var u=this.node().__on;if(u){for(var c=0,h=u.length,m;c<h;++c)for(r=0,m=u[c];r<o;++r)if((s=i[r]).type===m.type&&s.name===m.name)return m.value}return}for(u=e?ac:oc,r=0;r<o;++r)this.each(u(i[r],e,n));return this}function Ua(t,e,n){var i=Gn(t),r=i.CustomEvent;typeof r=="function"?r=new r(e,n):(r=i.document.createEvent("Event"),n?(r.initEvent(e,n.bubbles,n.cancelable),r.detail=n.detail):r.initEvent(e,!1,!1)),t.dispatchEvent(r)}function sc(t,e){return function(){return Ua(this,t,e)}}function lc(t,e){return function(){return Ua(this,t,e.apply(this,arguments))}}function Za(t,e){return this.each((typeof e=="function"?lc:sc)(t,e))}function*Xa(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var i=t[e],r=0,o=i.length,s;r<o;++r)(s=i[r])&&(yield s)}var ir=[null];function L(t,e){this._groups=t,this._parents=e}function Ya(){return new L([[document.documentElement]],ir)}function uc(){return this}L.prototype=Ya.prototype={constructor:L,select:ua,selectAll:da,selectChild:ca,selectChildren:ha,filter:ma,data:ga,enter:fa,exit:xa,join:va,merge:Ea,selection:uc,order:ya,sort:ba,call:Sa,nodes:wa,node:_a,size:za,empty:Ca,each:Na,attr:ka,style:Oa,property:Ta,classed:Ia,text:Ga,html:Fa,raise:Ra,lower:ja,append:La,insert:Pa,remove:$a,clone:Va,datum:qa,on:Ha,dispatch:Za,[Symbol.iterator]:Xa};var kt=Ya;function bt(t){return typeof t=="string"?new L([[document.querySelector(t)]],[document.documentElement]):new L([[t]],ir)}function Wa(t){let e;for(;e=t.sourceEvent;)t=e;return t}function Ot(t,e){if(t=Wa(t),e===void 0&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var i=n.createSVGPoint();return i.x=t.clientX,i.y=t.clientY,i=i.matrixTransform(e.getScreenCTM().inverse()),[i.x,i.y]}if(e.getBoundingClientRect){var r=e.getBoundingClientRect();return[t.clientX-r.left-e.clientLeft,t.clientY-r.top-e.clientTop]}}return[t.pageX,t.pageY]}function Fn(t){t.preventDefault(),t.stopImmediatePropagation()}function rr(t){var e=t.document.documentElement,n=bt(t).on("dragstart.drag",Fn,!0);"onselectstart"in e?n.on("selectstart.drag",Fn,!0):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function or(t,e){var n=t.document.documentElement,i=bt(t).on("dragstart.drag",null);e&&(i.on("click.drag",Fn,!0),setTimeout(function(){i.on("click.drag",null)},0)),"onselectstart"in n?i.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}function Rn(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function ar(t,e){var n=Object.create(t.prototype);for(var i in e)n[i]=e[i];return n}function Le(){}var Re=.7,Ln=1/Re,de="\\s*([+-]?\\d+)\\s*",je="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",wt="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",dc=/^#([0-9a-f]{3,8})$/,cc=new RegExp("^rgb\\("+[de,de,de]+"\\)$"),hc=new RegExp("^rgb\\("+[wt,wt,wt]+"\\)$"),mc=new RegExp("^rgba\\("+[de,de,de,je]+"\\)$"),fc=new RegExp("^rgba\\("+[wt,wt,wt,je]+"\\)$"),pc=new RegExp("^hsl\\("+[je,wt,wt]+"\\)$"),gc=new RegExp("^hsla\\("+[je,wt,wt,je]+"\\)$"),Qa={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Rn(Le,Ft,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:Ka,formatHex:Ka,formatHsl:xc,formatRgb:Ja,toString:Ja});function Ka(){return this.rgb().formatHex()}function xc(){return rs(this).formatHsl()}function Ja(){return this.rgb().formatRgb()}function Ft(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=dc.exec(t))?(n=e[1].length,e=parseInt(e[1],16),n===6?ts(e):n===3?new rt(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):n===8?jn(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):n===4?jn(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=cc.exec(t))?new rt(e[1],e[2],e[3],1):(e=hc.exec(t))?new rt(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=mc.exec(t))?jn(e[1],e[2],e[3],e[4]):(e=fc.exec(t))?jn(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=pc.exec(t))?is(e[1],e[2]/100,e[3]/100,1):(e=gc.exec(t))?is(e[1],e[2]/100,e[3]/100,e[4]):Qa.hasOwnProperty(t)?ts(Qa[t]):t==="transparent"?new rt(NaN,NaN,NaN,0):null}function ts(t){return new rt(t>>16&255,t>>8&255,t&255,1)}function jn(t,e,n,i){return i<=0&&(t=e=n=NaN),new rt(t,e,n,i)}function vc(t){return t instanceof Le||(t=Ft(t)),t?(t=t.rgb(),new rt(t.r,t.g,t.b,t.opacity)):new rt}function ce(t,e,n,i){return arguments.length===1?vc(t):new rt(t,e,n,i??1)}function rt(t,e,n,i){this.r=+t,this.g=+e,this.b=+n,this.opacity=+i}Rn(rt,ce,ar(Le,{brighter:function(t){return t=t==null?Ln:Math.pow(Ln,t),new rt(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=t==null?Re:Math.pow(Re,t),new rt(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:es,formatHex:es,formatRgb:ns,toString:ns}));function es(){return"#"+sr(this.r)+sr(this.g)+sr(this.b)}function ns(){var t=this.opacity;return t=isNaN(t)?1:Math.max(0,Math.min(1,t)),(t===1?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(t===1?")":", "+t+")")}function sr(t){return t=Math.max(0,Math.min(255,Math.round(t)||0)),(t<16?"0":"")+t.toString(16)}function is(t,e,n,i){return i<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new St(t,e,n,i)}function rs(t){if(t instanceof St)return new St(t.h,t.s,t.l,t.opacity);if(t instanceof Le||(t=Ft(t)),!t)return new St;if(t instanceof St)return t;t=t.rgb();var e=t.r/255,n=t.g/255,i=t.b/255,r=Math.min(e,n,i),o=Math.max(e,n,i),s=NaN,u=o-r,c=(o+r)/2;return u?(e===o?s=(n-i)/u+(n<i)*6:n===o?s=(i-e)/u+2:s=(e-n)/u+4,u/=c<.5?o+r:2-o-r,s*=60):u=c>0&&c<1?0:s,new St(s,u,c,t.opacity)}function os(t,e,n,i){return arguments.length===1?rs(t):new St(t,e,n,i??1)}function St(t,e,n,i){this.h=+t,this.s=+e,this.l=+n,this.opacity=+i}Rn(St,os,ar(Le,{brighter:function(t){return t=t==null?Ln:Math.pow(Ln,t),new St(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=t==null?Re:Math.pow(Re,t),new St(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*e,r=2*n-i;return new rt(lr(t>=240?t-240:t+120,r,i),lr(t,r,i),lr(t<120?t+240:t-120,r,i),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return t=isNaN(t)?1:Math.max(0,Math.min(1,t)),(t===1?"hsl(":"hsla(")+(this.h||0)+", "+(this.s||0)*100+"%, "+(this.l||0)*100+"%"+(t===1?")":", "+t+")")}}));function lr(t,e,n){return(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)*255}function ur(t,e,n,i,r){var o=t*t,s=o*t;return((1-3*t+3*o-s)*e+(4-6*o+3*s)*n+(1+3*t+3*o-3*s)*i+s*r)/6}function as(t){var e=t.length-1;return function(n){var i=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),r=t[i],o=t[i+1],s=i>0?t[i-1]:2*r-o,u=i<e-1?t[i+2]:2*o-r;return ur((n-i/e)*e,s,r,o,u)}}function ss(t){var e=t.length;return function(n){var i=Math.floor(((n%=1)<0?++n:n)*e),r=t[(i+e-1)%e],o=t[i%e],s=t[(i+1)%e],u=t[(i+2)%e];return ur((n-i/e)*e,r,o,s,u)}}var dr=t=>()=>t;function Ec(t,e){return function(n){return t+n*e}}function yc(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(i){return Math.pow(t+i*e,n)}}function ls(t){return(t=+t)==1?Pn:function(e,n){return n-e?yc(e,n,t):dr(isNaN(e)?n:e)}}function Pn(t,e){var n=e-t;return n?Ec(t,n):dr(isNaN(t)?e:t)}var $n=function t(e){var n=ls(e);function i(r,o){var s=n((r=ce(r)).r,(o=ce(o)).r),u=n(r.g,o.g),c=n(r.b,o.b),h=Pn(r.opacity,o.opacity);return function(m){return r.r=s(m),r.g=u(m),r.b=c(m),r.opacity=h(m),r+""}}return i.gamma=t,i}(1);function us(t){return function(e){var n=e.length,i=new Array(n),r=new Array(n),o=new Array(n),s,u;for(s=0;s<n;++s)u=ce(e[s]),i[s]=u.r||0,r[s]=u.g||0,o[s]=u.b||0;return i=t(i),r=t(r),o=t(o),u.opacity=1,function(c){return u.r=i(c),u.g=r(c),u.b=o(c),u+""}}}var bc=us(as),Sc=us(ss);function st(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}var hr=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,cr=new RegExp(hr.source,"g");function wc(t){return function(){return t}}function _c(t){return function(e){return t(e)+""}}function mr(t,e){var n=hr.lastIndex=cr.lastIndex=0,i,r,o,s=-1,u=[],c=[];for(t=t+"",e=e+"";(i=hr.exec(t))&&(r=cr.exec(e));)(o=r.index)>n&&(o=e.slice(n,o),u[s]?u[s]+=o:u[++s]=o),(i=i[0])===(r=r[0])?u[s]?u[s]+=r:u[++s]=r:(u[++s]=null,c.push({i:s,x:st(i,r)})),n=cr.lastIndex;return n<e.length&&(o=e.slice(n),u[s]?u[s]+=o:u[++s]=o),u.length<2?c[0]?_c(c[0].x):wc(e):(e=c.length,function(h){for(var m=0,f;m<e;++m)u[(f=c[m]).i]=f.x(h);return u.join("")})}var ds=180/Math.PI,Vn={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function fr(t,e,n,i,r,o){var s,u,c;return(s=Math.sqrt(t*t+e*e))&&(t/=s,e/=s),(c=t*n+e*i)&&(n-=t*c,i-=e*c),(u=Math.sqrt(n*n+i*i))&&(n/=u,i/=u,c/=u),t*i<e*n&&(t=-t,e=-e,c=-c,s=-s),{translateX:r,translateY:o,rotate:Math.atan2(e,t)*ds,skewX:Math.atan(c)*ds,scaleX:s,scaleY:u}}var qn;function cs(t){let e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?Vn:fr(e.a,e.b,e.c,e.d,e.e,e.f)}function hs(t){return t==null?Vn:(qn||(qn=document.createElementNS("http://www.w3.org/2000/svg","g")),qn.setAttribute("transform",t),(t=qn.transform.baseVal.consolidate())?(t=t.matrix,fr(t.a,t.b,t.c,t.d,t.e,t.f)):Vn)}function ms(t,e,n,i){function r(h){return h.length?h.pop()+" ":""}function o(h,m,f,p,x,E){if(h!==f||m!==p){var v=x.push("translate(",null,e,null,n);E.push({i:v-4,x:st(h,f)},{i:v-2,x:st(m,p)})}else(f||p)&&x.push("translate("+f+e+p+n)}function s(h,m,f,p){h!==m?(h-m>180?m+=360:m-h>180&&(h+=360),p.push({i:f.push(r(f)+"rotate(",null,i)-2,x:st(h,m)})):m&&f.push(r(f)+"rotate("+m+i)}function u(h,m,f,p){h!==m?p.push({i:f.push(r(f)+"skewX(",null,i)-2,x:st(h,m)}):m&&f.push(r(f)+"skewX("+m+i)}function c(h,m,f,p,x,E){if(h!==f||m!==p){var v=x.push(r(x)+"scale(",null,",",null,")");E.push({i:v-4,x:st(h,f)},{i:v-2,x:st(m,p)})}else(f!==1||p!==1)&&x.push(r(x)+"scale("+f+","+p+")")}return function(h,m){var f=[],p=[];return h=t(h),m=t(m),o(h.translateX,h.translateY,m.translateX,m.translateY,f,p),s(h.rotate,m.rotate,f,p),u(h.skewX,m.skewX,f,p),c(h.scaleX,h.scaleY,m.scaleX,m.scaleY,f,p),h=m=null,function(x){for(var E=-1,v=p.length,S;++E<v;)f[(S=p[E]).i]=S.x(x);return f.join("")}}}var pr=ms(cs,"px, ","px)","deg)"),gr=ms(hs,", ",")",")");var zc=1e-12;function fs(t){return((t=Math.exp(t))+1/t)/2}function Cc(t){return((t=Math.exp(t))-1/t)/2}function Nc(t){return((t=Math.exp(2*t))-1)/(t+1)}var xr=function t(e,n,i){function r(o,s){var u=o[0],c=o[1],h=o[2],m=s[0],f=s[1],p=s[2],x=m-u,E=f-c,v=x*x+E*E,S,b;if(v<zc)b=Math.log(p/h)/e,S=function(q){return[u+q*x,c+q*E,h*Math.exp(e*q*b)]};else{var z=Math.sqrt(v),k=(p*p-h*h+i*v)/(2*h*n*z),N=(p*p-h*h-i*v)/(2*p*n*z),G=Math.log(Math.sqrt(k*k+1)-k),M=Math.log(Math.sqrt(N*N+1)-N);b=(M-G)/e,S=function(q){var dt=q*b,ot=fs(G),dn=h/(n*z)*(ot*Nc(e*dt+G)-Cc(G));return[u+dn*x,c+dn*E,h*ot/fs(e*dt+G)]}}return S.duration=b*1e3*e/Math.SQRT2,S}return r.rho=function(o){var s=Math.max(.001,+o),u=s*s,c=u*u;return t(s,u,c)},r}(Math.SQRT2,2,4);var he=0,$e=0,Pe=0,gs=1e3,Hn,Ve,Un=0,Yt=0,Zn=0,qe=typeof performance=="object"&&performance.now?performance:Date,xs=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Ue(){return Yt||(xs(kc),Yt=qe.now()+Zn)}function kc(){Yt=0}function He(){this._call=this._time=this._next=null}He.prototype=Xn.prototype={constructor:He,restart:function(t,e,n){if(typeof t!="function")throw new TypeError("callback is not a function");n=(n==null?Ue():+n)+(e==null?0:+e),!this._next&&Ve!==this&&(Ve?Ve._next=this:Hn=this,Ve=this),this._call=t,this._time=n,vr()},stop:function(){this._call&&(this._call=null,this._time=1/0,vr())}};function Xn(t,e,n){var i=new He;return i.restart(t,e,n),i}function vs(){Ue(),++he;for(var t=Hn,e;t;)(e=Yt-t._time)>=0&&t._call.call(null,e),t=t._next;--he}function ps(){Yt=(Un=qe.now())+Zn,he=$e=0;try{vs()}finally{he=0,Tc(),Yt=0}}function Oc(){var t=qe.now(),e=t-Un;e>gs&&(Zn-=e,Un=t)}function Tc(){for(var t,e=Hn,n,i=1/0;e;)e._call?(i>e._time&&(i=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:Hn=n);Ve=t,vr(i)}function vr(t){if(!he){$e&&($e=clearTimeout($e));var e=t-Yt;e>24?(t<1/0&&($e=setTimeout(ps,t-qe.now()-Zn)),Pe&&(Pe=clearInterval(Pe))):(Pe||(Un=qe.now(),Pe=setInterval(Oc,gs)),he=1,xs(ps))}}function Yn(t,e,n){var i=new He;return e=e==null?0:+e,i.restart(r=>{i.stop(),t(r+e)},e,n),i}var Dc=Me("start","end","cancel","interrupt"),Ac=[],ys=0,Er=1,Qn=2,Wn=3,Es=4,Kn=5,Ze=6;function Rt(t,e,n,i,r,o){var s=t.__transition;if(!s)t.__transition={};else if(n in s)return;Bc(t,n,{name:e,index:i,group:r,on:Dc,tween:Ac,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:ys})}function Xe(t,e){var n=H(t,e);if(n.state>ys)throw new Error("too late; already scheduled");return n}function W(t,e){var n=H(t,e);if(n.state>Wn)throw new Error("too late; already running");return n}function H(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function Bc(t,e,n){var i=t.__transition,r;i[e]=n,n.timer=Xn(o,0,n.time);function o(h){n.state=Er,n.timer.restart(s,n.delay,n.time),n.delay<=h&&s(h-n.delay)}function s(h){var m,f,p,x;if(n.state!==Er)return c();for(m in i)if(x=i[m],x.name===n.name){if(x.state===Wn)return Yn(s);x.state===Es?(x.state=Ze,x.timer.stop(),x.on.call("interrupt",t,t.__data__,x.index,x.group),delete i[m]):+m<e&&(x.state=Ze,x.timer.stop(),x.on.call("cancel",t,t.__data__,x.index,x.group),delete i[m])}if(Yn(function(){n.state===Wn&&(n.state=Es,n.timer.restart(u,n.delay,n.time),u(h))}),n.state=Qn,n.on.call("start",t,t.__data__,n.index,n.group),n.state===Qn){for(n.state=Wn,r=new Array(p=n.tween.length),m=0,f=-1;m<p;++m)(x=n.tween[m].value.call(t,t.__data__,n.index,n.group))&&(r[++f]=x);r.length=f+1}}function u(h){for(var m=h<n.duration?n.ease.call(null,h/n.duration):(n.timer.restart(c),n.state=Kn,1),f=-1,p=r.length;++f<p;)r[f].call(t,m);n.state===Kn&&(n.on.call("end",t,t.__data__,n.index,n.group),c())}function c(){n.state=Ze,n.timer.stop(),delete i[e];for(var h in i)return;delete t.__transition}}function Wt(t,e){var n=t.__transition,i,r,o=!0,s;if(n){e=e==null?null:e+"";for(s in n){if((i=n[s]).name!==e){o=!1;continue}r=i.state>Qn&&i.state<Kn,i.state=Ze,i.timer.stop(),i.on.call(r?"interrupt":"cancel",t,t.__data__,i.index,i.group),delete n[s]}o&&delete t.__transition}}function bs(t){return this.each(function(){Wt(this,t)})}function Mc(t,e){var n,i;return function(){var r=W(this,t),o=r.tween;if(o!==n){i=n=o;for(var s=0,u=i.length;s<u;++s)if(i[s].name===e){i=i.slice(),i.splice(s,1);break}}r.tween=i}}function Ic(t,e,n){var i,r;if(typeof n!="function")throw new Error;return function(){var o=W(this,t),s=o.tween;if(s!==i){r=(i=s).slice();for(var u={name:e,value:n},c=0,h=r.length;c<h;++c)if(r[c].name===e){r[c]=u;break}c===h&&r.push(u)}o.tween=r}}function Ss(t,e){var n=this._id;if(t+="",arguments.length<2){for(var i=H(this.node(),n).tween,r=0,o=i.length,s;r<o;++r)if((s=i[r]).name===t)return s.value;return null}return this.each((e==null?Mc:Ic)(n,t,e))}function me(t,e,n){var i=t._id;return t.each(function(){var r=W(this,i);(r.value||(r.value={}))[e]=n.apply(this,arguments)}),function(r){return H(r,i).value[e]}}function Jn(t,e){var n;return(typeof e=="number"?st:e instanceof Ft?$n:(n=Ft(e))?(e=n,$n):mr)(t,e)}function Gc(t){return function(){this.removeAttribute(t)}}function Fc(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Rc(t,e,n){var i,r=n+"",o;return function(){var s=this.getAttribute(t);return s===r?null:s===i?o:o=e(i=s,n)}}function jc(t,e,n){var i,r=n+"",o;return function(){var s=this.getAttributeNS(t.space,t.local);return s===r?null:s===i?o:o=e(i=s,n)}}function Lc(t,e,n){var i,r,o;return function(){var s,u=n(this),c;return u==null?void this.removeAttribute(t):(s=this.getAttribute(t),c=u+"",s===c?null:s===i&&c===r?o:(r=c,o=e(i=s,u)))}}function Pc(t,e,n){var i,r,o;return function(){var s,u=n(this),c;return u==null?void this.removeAttributeNS(t.space,t.local):(s=this.getAttributeNS(t.space,t.local),c=u+"",s===c?null:s===i&&c===r?o:(r=c,o=e(i=s,u)))}}function ws(t,e){var n=Nt(t),i=n==="transform"?gr:Jn;return this.attrTween(t,typeof e=="function"?(n.local?Pc:Lc)(n,i,me(this,"attr."+t,e)):e==null?(n.local?Fc:Gc)(n):(n.local?jc:Rc)(n,i,e))}function $c(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function Vc(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function qc(t,e){var n,i;function r(){var o=e.apply(this,arguments);return o!==i&&(n=(i=o)&&Vc(t,o)),n}return r._value=e,r}function Hc(t,e){var n,i;function r(){var o=e.apply(this,arguments);return o!==i&&(n=(i=o)&&$c(t,o)),n}return r._value=e,r}function _s(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(e==null)return this.tween(n,null);if(typeof e!="function")throw new Error;var i=Nt(t);return this.tween(n,(i.local?qc:Hc)(i,e))}function Uc(t,e){return function(){Xe(this,t).delay=+e.apply(this,arguments)}}function Zc(t,e){return e=+e,function(){Xe(this,t).delay=e}}function zs(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?Uc:Zc)(e,t)):H(this.node(),e).delay}function Xc(t,e){return function(){W(this,t).duration=+e.apply(this,arguments)}}function Yc(t,e){return e=+e,function(){W(this,t).duration=e}}function Cs(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?Xc:Yc)(e,t)):H(this.node(),e).duration}function Wc(t,e){if(typeof e!="function")throw new Error;return function(){W(this,t).ease=e}}function Ns(t){var e=this._id;return arguments.length?this.each(Wc(e,t)):H(this.node(),e).ease}function Qc(t,e){return function(){var n=e.apply(this,arguments);if(typeof n!="function")throw new Error;W(this,t).ease=n}}function ks(t){if(typeof t!="function")throw new Error;return this.each(Qc(this._id,t))}function Os(t){typeof t!="function"&&(t=Ge(t));for(var e=this._groups,n=e.length,i=new Array(n),r=0;r<n;++r)for(var o=e[r],s=o.length,u=i[r]=[],c,h=0;h<s;++h)(c=o[h])&&t.call(c,c.__data__,h,o)&&u.push(c);return new K(i,this._parents,this._name,this._id)}function Ts(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,i=e.length,r=n.length,o=Math.min(i,r),s=new Array(i),u=0;u<o;++u)for(var c=e[u],h=n[u],m=c.length,f=s[u]=new Array(m),p,x=0;x<m;++x)(p=c[x]||h[x])&&(f[x]=p);for(;u<i;++u)s[u]=e[u];return new K(s,this._parents,this._name,this._id)}function Kc(t){return(t+"").trim().split(/^|\s+/).every(function(e){var n=e.indexOf(".");return n>=0&&(e=e.slice(0,n)),!e||e==="start"})}function Jc(t,e,n){var i,r,o=Kc(e)?Xe:W;return function(){var s=o(this,t),u=s.on;u!==i&&(r=(i=u).copy()).on(e,n),s.on=r}}function Ds(t,e){var n=this._id;return arguments.length<2?H(this.node(),n).on.on(t):this.each(Jc(n,t,e))}function t0(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}function As(){return this.on("end.remove",t0(this._id))}function Bs(t){var e=this._name,n=this._id;typeof t!="function"&&(t=Xt(t));for(var i=this._groups,r=i.length,o=new Array(r),s=0;s<r;++s)for(var u=i[s],c=u.length,h=o[s]=new Array(c),m,f,p=0;p<c;++p)(m=u[p])&&(f=t.call(m,m.__data__,p,u))&&("__data__"in m&&(f.__data__=m.__data__),h[p]=f,Rt(h[p],e,n,p,h,H(m,n)));return new K(o,this._parents,e,n)}function Ms(t){var e=this._name,n=this._id;typeof t!="function"&&(t=Ie(t));for(var i=this._groups,r=i.length,o=[],s=[],u=0;u<r;++u)for(var c=i[u],h=c.length,m,f=0;f<h;++f)if(m=c[f]){for(var p=t.call(m,m.__data__,f,c),x,E=H(m,n),v=0,S=p.length;v<S;++v)(x=p[v])&&Rt(x,e,n,v,p,E);o.push(p),s.push(m)}return new K(o,s,e,n)}var e0=kt.prototype.constructor;function Is(){return new e0(this._groups,this._parents)}function n0(t,e){var n,i,r;return function(){var o=Gt(this,t),s=(this.style.removeProperty(t),Gt(this,t));return o===s?null:o===n&&s===i?r:r=e(n=o,i=s)}}function Gs(t){return function(){this.style.removeProperty(t)}}function i0(t,e,n){var i,r=n+"",o;return function(){var s=Gt(this,t);return s===r?null:s===i?o:o=e(i=s,n)}}function r0(t,e,n){var i,r,o;return function(){var s=Gt(this,t),u=n(this),c=u+"";return u==null&&(c=u=(this.style.removeProperty(t),Gt(this,t))),s===c?null:s===i&&c===r?o:(r=c,o=e(i=s,u))}}function o0(t,e){var n,i,r,o="style."+e,s="end."+o,u;return function(){var c=W(this,t),h=c.on,m=c.value[o]==null?u||(u=Gs(e)):void 0;(h!==n||r!==m)&&(i=(n=h).copy()).on(s,r=m),c.on=i}}function Fs(t,e,n){var i=(t+="")=="transform"?pr:Jn;return e==null?this.styleTween(t,n0(t,i)).on("end.style."+t,Gs(t)):typeof e=="function"?this.styleTween(t,r0(t,i,me(this,"style."+t,e))).each(o0(this._id,t)):this.styleTween(t,i0(t,i,e),n).on("end.style."+t,null)}function a0(t,e,n){return function(i){this.style.setProperty(t,e.call(this,i),n)}}function s0(t,e,n){var i,r;function o(){var s=e.apply(this,arguments);return s!==r&&(i=(r=s)&&a0(t,s,n)),i}return o._value=e,o}function Rs(t,e,n){var i="style."+(t+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(e==null)return this.tween(i,null);if(typeof e!="function")throw new Error;return this.tween(i,s0(t,e,n??""))}function l0(t){return function(){this.textContent=t}}function u0(t){return function(){var e=t(this);this.textContent=e??""}}function js(t){return this.tween("text",typeof t=="function"?u0(me(this,"text",t)):l0(t==null?"":t+""))}function d0(t){return function(e){this.textContent=t.call(this,e)}}function c0(t){var e,n;function i(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&d0(r)),e}return i._value=t,i}function Ls(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(t==null)return this.tween(e,null);if(typeof t!="function")throw new Error;return this.tween(e,c0(t))}function Ps(){for(var t=this._name,e=this._id,n=ti(),i=this._groups,r=i.length,o=0;o<r;++o)for(var s=i[o],u=s.length,c,h=0;h<u;++h)if(c=s[h]){var m=H(c,e);Rt(c,t,n,h,s,{time:m.time+m.delay+m.duration,delay:0,duration:m.duration,ease:m.ease})}return new K(i,this._parents,t,n)}function $s(){var t,e,n=this,i=n._id,r=n.size();return new Promise(function(o,s){var u={value:s},c={value:function(){--r===0&&o()}};n.each(function(){var h=W(this,i),m=h.on;m!==t&&(e=(t=m).copy(),e._.cancel.push(u),e._.interrupt.push(u),e._.end.push(c)),h.on=e}),r===0&&o()})}var h0=0;function K(t,e,n,i){this._groups=t,this._parents=e,this._name=n,this._id=i}function Ye(t){return kt().transition(t)}function ti(){return++h0}var Qt=kt.prototype;K.prototype=Ye.prototype={constructor:K,select:Bs,selectAll:Ms,filter:Os,merge:Ts,selection:Is,transition:Ps,call:Qt.call,nodes:Qt.nodes,node:Qt.node,size:Qt.size,empty:Qt.empty,each:Qt.each,on:Ds,attr:ws,attrTween:_s,style:Fs,styleTween:Rs,text:js,textTween:Ls,remove:As,tween:Ss,delay:zs,duration:Cs,ease:Ns,easeVarying:ks,end:$s,[Symbol.iterator]:Qt[Symbol.iterator]};function ei(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var m0={time:null,delay:0,duration:250,ease:ei};function f0(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return n}function Vs(t){var e,n;t instanceof K?(e=t._id,t=t._name):(e=ti(),(n=m0).time=Ue(),t=t==null?null:t+"");for(var i=this._groups,r=i.length,o=0;o<r;++o)for(var s=i[o],u=s.length,c,h=0;h<u;++h)(c=s[h])&&Rt(c,t,e,h,s,n||f0(c,e));return new K(i,this._parents,t,e)}kt.prototype.interrupt=bs;kt.prototype.transition=Vs;var We=t=>()=>t;function yr(t,{sourceEvent:e,target:n,transform:i,dispatch:r}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:i,enumerable:!0,configurable:!0},_:{value:r}})}function _t(t,e,n){this.k=t,this.x=e,this.y=n}_t.prototype={constructor:_t,scale:function(t){return t===1?this:new _t(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new _t(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var jt=new _t(1,0,0);Qe.prototype=_t.prototype;function Qe(t){for(;!t.__zoom;)if(!(t=t.parentNode))return jt;return t.__zoom}function ni(t){t.stopImmediatePropagation()}function fe(t){t.preventDefault(),t.stopImmediatePropagation()}function p0(t){return(!t.ctrlKey||t.type==="wheel")&&!t.button}function g0(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t,t.hasAttribute("viewBox")?(t=t.viewBox.baseVal,[[t.x,t.y],[t.x+t.width,t.y+t.height]]):[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]):[[0,0],[t.clientWidth,t.clientHeight]]}function qs(){return this.__zoom||jt}function x0(t){return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function v0(){return navigator.maxTouchPoints||"ontouchstart"in this}function E0(t,e,n){var i=t.invertX(e[0][0])-n[0][0],r=t.invertX(e[1][0])-n[1][0],o=t.invertY(e[0][1])-n[0][1],s=t.invertY(e[1][1])-n[1][1];return t.translate(r>i?(i+r)/2:Math.min(0,i)||Math.max(0,r),s>o?(o+s)/2:Math.min(0,o)||Math.max(0,s))}function br(){var t=p0,e=g0,n=E0,i=x0,r=v0,o=[0,1/0],s=[[-1/0,-1/0],[1/0,1/0]],u=250,c=xr,h=Me("start","zoom","end"),m,f,p,x=500,E=150,v=0,S=10;function b(y){y.property("__zoom",qs).on("wheel.zoom",dt).on("mousedown.zoom",ot).on("dblclick.zoom",dn).filter(r).on("touchstart.zoom",ld).on("touchmove.zoom",ud).on("touchend.zoom touchcancel.zoom",dd).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}b.transform=function(y,C,w,O){var T=y.selection?y.selection():y;T.property("__zoom",qs),y!==T?G(y,C,w,O):T.interrupt().each(function(){M(this,arguments).event(O).start().zoom(null,typeof C=="function"?C.apply(this,arguments):C).end()})},b.scaleBy=function(y,C,w,O){b.scaleTo(y,function(){var T=this.__zoom.k,A=typeof C=="function"?C.apply(this,arguments):C;return T*A},w,O)},b.scaleTo=function(y,C,w,O){b.transform(y,function(){var T=e.apply(this,arguments),A=this.__zoom,B=w==null?N(T):typeof w=="function"?w.apply(this,arguments):w,F=A.invert(B),V=typeof C=="function"?C.apply(this,arguments):C;return n(k(z(A,V),B,F),T,s)},w,O)},b.translateBy=function(y,C,w,O){b.transform(y,function(){return n(this.__zoom.translate(typeof C=="function"?C.apply(this,arguments):C,typeof w=="function"?w.apply(this,arguments):w),e.apply(this,arguments),s)},null,O)},b.translateTo=function(y,C,w,O,T){b.transform(y,function(){var A=e.apply(this,arguments),B=this.__zoom,F=O==null?N(A):typeof O=="function"?O.apply(this,arguments):O;return n(jt.translate(F[0],F[1]).scale(B.k).translate(typeof C=="function"?-C.apply(this,arguments):-C,typeof w=="function"?-w.apply(this,arguments):-w),A,s)},O,T)};function z(y,C){return C=Math.max(o[0],Math.min(o[1],C)),C===y.k?y:new _t(C,y.x,y.y)}function k(y,C,w){var O=C[0]-w[0]*y.k,T=C[1]-w[1]*y.k;return O===y.x&&T===y.y?y:new _t(y.k,O,T)}function N(y){return[(+y[0][0]+ +y[1][0])/2,(+y[0][1]+ +y[1][1])/2]}function G(y,C,w,O){y.on("start.zoom",function(){M(this,arguments).event(O).start()}).on("interrupt.zoom end.zoom",function(){M(this,arguments).event(O).end()}).tween("zoom",function(){var T=this,A=arguments,B=M(T,A).event(O),F=e.apply(T,A),V=w==null?N(F):typeof w=="function"?w.apply(T,A):w,xt=Math.max(F[1][0]-F[0][0],F[1][1]-F[0][1]),X=T.__zoom,ct=typeof C=="function"?C.apply(T,A):C,zt=c(X.invert(V).concat(xt/X.k),ct.invert(V).concat(xt/ct.k));return function(ht){if(ht===1)ht=ct;else{var Ct=zt(ht),Ii=xt/Ct[2];ht=new _t(Ii,V[0]-Ct[0]*Ii,V[1]-Ct[1]*Ii)}B.zoom(null,ht)}})}function M(y,C,w){return!w&&y.__zooming||new q(y,C)}function q(y,C){this.that=y,this.args=C,this.active=0,this.sourceEvent=null,this.extent=e.apply(y,C),this.taps=0}q.prototype={event:function(y){return y&&(this.sourceEvent=y),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(y,C){return this.mouse&&y!=="mouse"&&(this.mouse[1]=C.invert(this.mouse[0])),this.touch0&&y!=="touch"&&(this.touch0[1]=C.invert(this.touch0[0])),this.touch1&&y!=="touch"&&(this.touch1[1]=C.invert(this.touch1[0])),this.that.__zoom=C,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(y){var C=bt(this.that).datum();h.call(y,this.that,new yr(y,{sourceEvent:this.sourceEvent,target:b,type:y,transform:this.that.__zoom,dispatch:h}),C)}};function dt(y,...C){if(!t.apply(this,arguments))return;var w=M(this,C).event(y),O=this.__zoom,T=Math.max(o[0],Math.min(o[1],O.k*Math.pow(2,i.apply(this,arguments)))),A=Ot(y);if(w.wheel)(w.mouse[0][0]!==A[0]||w.mouse[0][1]!==A[1])&&(w.mouse[1]=O.invert(w.mouse[0]=A)),clearTimeout(w.wheel);else{if(O.k===T)return;w.mouse=[A,O.invert(A)],Wt(this),w.start()}fe(y),w.wheel=setTimeout(B,E),w.zoom("mouse",n(k(z(O,T),w.mouse[0],w.mouse[1]),w.extent,s));function B(){w.wheel=null,w.end()}}function ot(y,...C){if(p||!t.apply(this,arguments))return;var w=M(this,C,!0).event(y),O=bt(y.view).on("mousemove.zoom",V,!0).on("mouseup.zoom",xt,!0),T=Ot(y,A),A=y.currentTarget,B=y.clientX,F=y.clientY;rr(y.view),ni(y),w.mouse=[T,this.__zoom.invert(T)],Wt(this),w.start();function V(X){if(fe(X),!w.moved){var ct=X.clientX-B,zt=X.clientY-F;w.moved=ct*ct+zt*zt>v}w.event(X).zoom("mouse",n(k(w.that.__zoom,w.mouse[0]=Ot(X,A),w.mouse[1]),w.extent,s))}function xt(X){O.on("mousemove.zoom mouseup.zoom",null),or(X.view,w.moved),fe(X),w.event(X).end()}}function dn(y,...C){if(t.apply(this,arguments)){var w=this.__zoom,O=Ot(y.changedTouches?y.changedTouches[0]:y,this),T=w.invert(O),A=w.k*(y.shiftKey?.5:2),B=n(k(z(w,A),O,T),e.apply(this,C),s);fe(y),u>0?bt(this).transition().duration(u).call(G,B,O,y):bt(this).call(b.transform,B,O,y)}}function ld(y,...C){if(t.apply(this,arguments)){var w=y.touches,O=w.length,T=M(this,C,y.changedTouches.length===O).event(y),A,B,F,V;for(ni(y),B=0;B<O;++B)F=w[B],V=Ot(F,this),V=[V,this.__zoom.invert(V),F.identifier],T.touch0?!T.touch1&&T.touch0[2]!==V[2]&&(T.touch1=V,T.taps=0):(T.touch0=V,A=!0,T.taps=1+!!m);m&&(m=clearTimeout(m)),A&&(T.taps<2&&(f=V[0],m=setTimeout(function(){m=null},x)),Wt(this),T.start())}}function ud(y,...C){if(this.__zooming){var w=M(this,C).event(y),O=y.changedTouches,T=O.length,A,B,F,V;for(fe(y),A=0;A<T;++A)B=O[A],F=Ot(B,this),w.touch0&&w.touch0[2]===B.identifier?w.touch0[0]=F:w.touch1&&w.touch1[2]===B.identifier&&(w.touch1[0]=F);if(B=w.that.__zoom,w.touch1){var xt=w.touch0[0],X=w.touch0[1],ct=w.touch1[0],zt=w.touch1[1],ht=(ht=ct[0]-xt[0])*ht+(ht=ct[1]-xt[1])*ht,Ct=(Ct=zt[0]-X[0])*Ct+(Ct=zt[1]-X[1])*Ct;B=z(B,Math.sqrt(ht/Ct)),F=[(xt[0]+ct[0])/2,(xt[1]+ct[1])/2],V=[(X[0]+zt[0])/2,(X[1]+zt[1])/2]}else if(w.touch0)F=w.touch0[0],V=w.touch0[1];else return;w.zoom("touch",n(k(B,F,V),w.extent,s))}}function dd(y,...C){if(this.__zooming){var w=M(this,C).event(y),O=y.changedTouches,T=O.length,A,B;for(ni(y),p&&clearTimeout(p),p=setTimeout(function(){p=null},x),A=0;A<T;++A)B=O[A],w.touch0&&w.touch0[2]===B.identifier?delete w.touch0:w.touch1&&w.touch1[2]===B.identifier&&delete w.touch1;if(w.touch1&&!w.touch0&&(w.touch0=w.touch1,delete w.touch1),w.touch0)w.touch0[1]=this.__zoom.invert(w.touch0[0]);else if(w.end(),w.taps===2&&(B=Ot(B,this),Math.hypot(f[0]-B[0],f[1]-B[1])<S)){var F=bt(this).on("dblclick.zoom");F&&F.apply(this,arguments)}}}return b.wheelDelta=function(y){return arguments.length?(i=typeof y=="function"?y:We(+y),b):i},b.filter=function(y){return arguments.length?(t=typeof y=="function"?y:We(!!y),b):t},b.touchable=function(y){return arguments.length?(r=typeof y=="function"?y:We(!!y),b):r},b.extent=function(y){return arguments.length?(e=typeof y=="function"?y:We([[+y[0][0],+y[0][1]],[+y[1][0],+y[1][1]]]),b):e},b.scaleExtent=function(y){return arguments.length?(o[0]=+y[0],o[1]=+y[1],b):[o[0],o[1]]},b.translateExtent=function(y){return arguments.length?(s[0][0]=+y[0][0],s[1][0]=+y[1][0],s[0][1]=+y[0][1],s[1][1]=+y[1][1],b):[[s[0][0],s[0][1]],[s[1][0],s[1][1]]]},b.constrain=function(y){return arguments.length?(n=y,b):n},b.duration=function(y){return arguments.length?(u=+y,b):u},b.interpolate=function(y){return arguments.length?(c=y,b):c},b.on=function(){var y=h.on.apply(h,arguments);return y===h?b:y},b.clickDistance=function(y){return arguments.length?(v=(y=+y)*y,b):Math.sqrt(v)},b.tapDistance=function(y){return arguments.length?(S=+y,b):S},b}var Hs,J,_e,tn;(function(t){t[t.META=0]="META",t[t.OP=1]="OP",t[t.SERIES=2]="SERIES"})(Hs||(Hs={})),function(t){t[t.META=0]="META",t[t.NODE=1]="NODE",t[t.BRIDGE=2]="BRIDGE"}(J||(J={})),function(t){t[t.INCLUDE=0]="INCLUDE",t[t.EXCLUDE=1]="EXCLUDE",t[t.UNSPECIFIED=2]="UNSPECIFIED"}(_e||(_e={})),function(t){t[t.META=0]="META",t[t.CORE=1]="CORE",t[t.BRIDGE=2]="BRIDGE"}(tn||(tn={}));var ii=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Zr(t,e){return t(e={exports:{}},e.exports),e.exports}var y0=function(){this.__data__=[],this.size=0},Ne=function(t,e){return t===e||t!=t&&e!=e},gi=function(t,e){for(var n=t.length;n--;)if(Ne(t[n][0],e))return n;return-1},b0=Array.prototype.splice,S0=function(t){var e=this.__data__,n=gi(e,t);return!(n<0)&&(n==e.length-1?e.pop():b0.call(e,n,1),--this.size,!0)},w0=function(t){var e=this.__data__,n=gi(e,t);return n<0?void 0:e[n][1]},_0=function(t){return gi(this.__data__,t)>-1},z0=function(t,e){var n=this.__data__,i=gi(n,t);return i<0?(++this.size,n.push([t,e])):n[i][1]=e,this};function pe(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var i=t[e];this.set(i[0],i[1])}}pe.prototype.clear=y0,pe.prototype.delete=S0,pe.prototype.get=w0,pe.prototype.has=_0,pe.prototype.set=z0;var xi=pe,C0=function(){this.__data__=new xi,this.size=0},N0=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},k0=function(t){return this.__data__.get(t)},O0=function(t){return this.__data__.has(t)},Fl=typeof ii=="object"&&ii&&ii.Object===Object&&ii,T0=typeof self=="object"&&self&&self.Object===Object&&self,pt=Fl||T0||Function("return this")(),ut=pt.Symbol,Rl=Object.prototype,D0=Rl.hasOwnProperty,A0=Rl.toString,Ke=ut?ut.toStringTag:void 0,B0=function(t){var e=D0.call(t,Ke),n=t[Ke];try{t[Ke]=void 0;var i=!0}catch{}var r=A0.call(t);return i&&(e?t[Ke]=n:delete t[Ke]),r},M0=Object.prototype.toString,I0=function(t){return M0.call(t)},Us=ut?ut.toStringTag:void 0,Pt=function(t){return t==null?t===void 0?"[object Undefined]":"[object Null]":Us&&Us in Object(t)?B0(t):I0(t)},tt=function(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")},Zs,on=function(t){if(!tt(t))return!1;var e=Pt(t);return e=="[object Function]"||e=="[object GeneratorFunction]"||e=="[object AsyncFunction]"||e=="[object Proxy]"},Sr=pt["__core-js_shared__"],Xs=(Zs=/[^.]+$/.exec(Sr&&Sr.keys&&Sr.keys.IE_PROTO||""))?"Symbol(src)_1."+Zs:"",G0=function(t){return!!Xs&&Xs in t},F0=Function.prototype.toString,ie=function(t){if(t!=null){try{return F0.call(t)}catch{}try{return t+""}catch{}}return""},R0=/^\[object .+?Constructor\]$/,j0=Function.prototype,L0=Object.prototype,P0=j0.toString,$0=L0.hasOwnProperty,V0=RegExp("^"+P0.call($0).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),q0=function(t){return!(!tt(t)||G0(t))&&(on(t)?V0:R0).test(ie(t))},H0=function(t,e){return t?.[e]},re=function(t,e){var n=H0(t,e);return q0(n)?n:void 0},en=re(pt,"Map"),nn=re(Object,"create"),U0=function(){this.__data__=nn?nn(null):{},this.size=0},Z0=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},X0=Object.prototype.hasOwnProperty,Y0=function(t){var e=this.__data__;if(nn){var n=e[t];return n==="__lodash_hash_undefined__"?void 0:n}return X0.call(e,t)?e[t]:void 0},W0=Object.prototype.hasOwnProperty,Q0=function(t){var e=this.__data__;return nn?e[t]!==void 0:W0.call(e,t)},K0=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=nn&&e===void 0?"__lodash_hash_undefined__":e,this};function ge(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var i=t[e];this.set(i[0],i[1])}}ge.prototype.clear=U0,ge.prototype.delete=Z0,ge.prototype.get=Y0,ge.prototype.has=Q0,ge.prototype.set=K0;var Ys=ge,J0=function(){this.size=0,this.__data__={hash:new Ys,map:new(en||xi),string:new Ys}},th=function(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null},vi=function(t,e){var n=t.__data__;return th(e)?n[typeof e=="string"?"string":"hash"]:n.map},eh=function(t){var e=vi(this,t).delete(t);return this.size-=e?1:0,e},nh=function(t){return vi(this,t).get(t)},ih=function(t){return vi(this,t).has(t)},rh=function(t,e){var n=vi(this,t),i=n.size;return n.set(t,e),this.size+=n.size==i?0:1,this};function xe(t){var e=-1,n=t==null?0:t.length;for(this.clear();++e<n;){var i=t[e];this.set(i[0],i[1])}}xe.prototype.clear=J0,xe.prototype.delete=eh,xe.prototype.get=nh,xe.prototype.has=ih,xe.prototype.set=rh;var Ei=xe,oh=function(t,e){var n=this.__data__;if(n instanceof xi){var i=n.__data__;if(!en||i.length<199)return i.push([t,e]),this.size=++n.size,this;n=this.__data__=new Ei(i)}return n.set(t,e),this.size=n.size,this};function ve(t){var e=this.__data__=new xi(t);this.size=e.size}ve.prototype.clear=C0,ve.prototype.delete=N0,ve.prototype.get=k0,ve.prototype.has=O0,ve.prototype.set=oh;var ye=ve,Xr=function(t,e){for(var n=-1,i=t==null?0:t.length;++n<i&&e(t[n],n,t)!==!1;);return t},si=function(){try{var t=re(Object,"defineProperty");return t({},"",{}),t}catch{}}(),yi=function(t,e,n){e=="__proto__"&&si?si(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n},ah=Object.prototype.hasOwnProperty,bi=function(t,e,n){var i=t[e];ah.call(t,e)&&Ne(i,n)&&(n!==void 0||e in t)||yi(t,e,n)},an=function(t,e,n,i){var r=!n;n||(n={});for(var o=-1,s=e.length;++o<s;){var u=e[o],c=i?i(n[u],t[u],u,n,t):void 0;c===void 0&&(c=t[u]),r?yi(n,u,c):bi(n,u,c)}return n},sh=function(t,e){for(var n=-1,i=Array(t);++n<t;)i[n]=e(n);return i},ft=function(t){return t!=null&&typeof t=="object"},Ws=function(t){return ft(t)&&Pt(t)=="[object Arguments]"},jl=Object.prototype,lh=jl.hasOwnProperty,uh=jl.propertyIsEnumerable,ze=Ws(function(){return arguments}())?Ws:function(t){return ft(t)&&lh.call(t,"callee")&&!uh.call(t,"callee")},$=Array.isArray,dh=function(){return!1},te=Zr(function(t,e){var n=e&&!e.nodeType&&e,i=n&&t&&!t.nodeType&&t,r=i&&i.exports===n?pt.Buffer:void 0,o=(r?r.isBuffer:void 0)||dh;t.exports=o}),ch=/^(?:0|[1-9]\d*)$/,Si=function(t,e){var n=typeof t;return!!(e=e??9007199254740991)&&(n=="number"||n!="symbol"&&ch.test(t))&&t>-1&&t%1==0&&t<e},Yr=function(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=9007199254740991},j={};j["[object Float32Array]"]=j["[object Float64Array]"]=j["[object Int8Array]"]=j["[object Int16Array]"]=j["[object Int32Array]"]=j["[object Uint8Array]"]=j["[object Uint8ClampedArray]"]=j["[object Uint16Array]"]=j["[object Uint32Array]"]=!0,j["[object Arguments]"]=j["[object Array]"]=j["[object ArrayBuffer]"]=j["[object Boolean]"]=j["[object DataView]"]=j["[object Date]"]=j["[object Error]"]=j["[object Function]"]=j["[object Map]"]=j["[object Number]"]=j["[object Object]"]=j["[object RegExp]"]=j["[object Set]"]=j["[object String]"]=j["[object WeakMap]"]=!1;var hh=function(t){return ft(t)&&Yr(t.length)&&!!j[Pt(t)]},wi=function(t){return function(e){return t(e)}},Ce=Zr(function(t,e){var n=e&&!e.nodeType&&e,i=n&&t&&!t.nodeType&&t,r=i&&i.exports===n&&Fl.process,o=function(){try{var s=i&&i.require&&i.require("util").types;return s||r&&r.binding&&r.binding("util")}catch{}}();t.exports=o}),Qs=Ce&&Ce.isTypedArray,sn=Qs?wi(Qs):hh,mh=Object.prototype.hasOwnProperty,Ll=function(t,e){var n=$(t),i=!n&&ze(t),r=!n&&!i&&te(t),o=!n&&!i&&!r&&sn(t),s=n||i||r||o,u=s?sh(t.length,String):[],c=u.length;for(var h in t)!e&&!mh.call(t,h)||s&&(h=="length"||r&&(h=="offset"||h=="parent")||o&&(h=="buffer"||h=="byteLength"||h=="byteOffset")||Si(h,c))||u.push(h);return u},fh=Object.prototype,_i=function(t){var e=t&&t.constructor;return t===(typeof e=="function"&&e.prototype||fh)},Pl=function(t,e){return function(n){return t(e(n))}},ph=Pl(Object.keys,Object),gh=Object.prototype.hasOwnProperty,Wr=function(t){if(!_i(t))return ph(t);var e=[];for(var n in Object(t))gh.call(t,n)&&n!="constructor"&&e.push(n);return e},Tt=function(t){return t!=null&&Yr(t.length)&&!on(t)},$t=function(t){return Tt(t)?Ll(t):Wr(t)},xh=function(t,e){return t&&an(e,$t(e),t)},vh=function(t){var e=[];if(t!=null)for(var n in Object(t))e.push(n);return e},Eh=Object.prototype.hasOwnProperty,yh=function(t){if(!tt(t))return vh(t);var e=_i(t),n=[];for(var i in t)(i!="constructor"||!e&&Eh.call(t,i))&&n.push(i);return n},oe=function(t){return Tt(t)?Ll(t,!0):yh(t)},bh=function(t,e){return t&&an(e,oe(e),t)},$l=Zr(function(t,e){var n=e&&!e.nodeType&&e,i=n&&t&&!t.nodeType&&t,r=i&&i.exports===n?pt.Buffer:void 0,o=r?r.allocUnsafe:void 0;t.exports=function(s,u){if(u)return s.slice();var c=s.length,h=o?o(c):new s.constructor(c);return s.copy(h),h}}),Vl=function(t,e){var n=-1,i=t.length;for(e||(e=Array(i));++n<i;)e[n]=t[n];return e},ql=function(t,e){for(var n=-1,i=t==null?0:t.length,r=0,o=[];++n<i;){var s=t[n];e(s,n,t)&&(o[r++]=s)}return o},Hl=function(){return[]},Sh=Object.prototype.propertyIsEnumerable,Ks=Object.getOwnPropertySymbols,Qr=Ks?function(t){return t==null?[]:(t=Object(t),ql(Ks(t),function(e){return Sh.call(t,e)}))}:Hl,wh=function(t,e){return an(t,Qr(t),e)},Kr=function(t,e){for(var n=-1,i=e.length,r=t.length;++n<i;)t[r+n]=e[n];return t},zi=Pl(Object.getPrototypeOf,Object),Ul=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)Kr(e,Qr(t)),t=zi(t);return e}:Hl,_h=function(t,e){return an(t,Ul(t),e)},Zl=function(t,e,n){var i=e(t);return $(t)?i:Kr(i,n(t))},Dr=function(t){return Zl(t,$t,Qr)},zh=function(t){return Zl(t,oe,Ul)},Ar=re(pt,"DataView"),Br=re(pt,"Promise"),be=re(pt,"Set"),Mr=re(pt,"WeakMap"),Ch=ie(Ar),Nh=ie(en),kh=ie(Br),Oh=ie(be),Th=ie(Mr),Kt=Pt;(Ar&&Kt(new Ar(new ArrayBuffer(1)))!="[object DataView]"||en&&Kt(new en)!="[object Map]"||Br&&Kt(Br.resolve())!="[object Promise]"||be&&Kt(new be)!="[object Set]"||Mr&&Kt(new Mr)!="[object WeakMap]")&&(Kt=function(t){var e=Pt(t),n=e=="[object Object]"?t.constructor:void 0,i=n?ie(n):"";if(i)switch(i){case Ch:return"[object DataView]";case Nh:return"[object Map]";case kh:return"[object Promise]";case Oh:return"[object Set]";case Th:return"[object WeakMap]"}return e});var ee=Kt,Dh=Object.prototype.hasOwnProperty,Ah=function(t){var e=t.length,n=new t.constructor(e);return e&&typeof t[0]=="string"&&Dh.call(t,"index")&&(n.index=t.index,n.input=t.input),n},li=pt.Uint8Array,Jr=function(t){var e=new t.constructor(t.byteLength);return new li(e).set(new li(t)),e},Bh=function(t,e){var n=e?Jr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)},Mh=/\w*$/,Ih=function(t){var e=new t.constructor(t.source,Mh.exec(t));return e.lastIndex=t.lastIndex,e},Js=ut?ut.prototype:void 0,tl=Js?Js.valueOf:void 0,Gh=function(t){return tl?Object(tl.call(t)):{}},Xl=function(t,e){var n=e?Jr(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)},Fh=function(t,e,n){var i=t.constructor;switch(e){case"[object ArrayBuffer]":return Jr(t);case"[object Boolean]":case"[object Date]":return new i(+t);case"[object DataView]":return Bh(t,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return Xl(t,n);case"[object Map]":return new i;case"[object Number]":case"[object String]":return new i(t);case"[object RegExp]":return Ih(t);case"[object Set]":return new i;case"[object Symbol]":return Gh(t)}},el=Object.create,Yl=function(){function t(){}return function(e){if(!tt(e))return{};if(el)return el(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}(),Wl=function(t){return typeof t.constructor!="function"||_i(t)?{}:Yl(zi(t))},Rh=function(t){return ft(t)&&ee(t)=="[object Map]"},nl=Ce&&Ce.isMap,jh=nl?wi(nl):Rh,Lh=function(t){return ft(t)&&ee(t)=="[object Set]"},il=Ce&&Ce.isSet,Ph=il?wi(il):Lh,R={};R["[object Arguments]"]=R["[object Array]"]=R["[object ArrayBuffer]"]=R["[object DataView]"]=R["[object Boolean]"]=R["[object Date]"]=R["[object Float32Array]"]=R["[object Float64Array]"]=R["[object Int8Array]"]=R["[object Int16Array]"]=R["[object Int32Array]"]=R["[object Map]"]=R["[object Number]"]=R["[object Object]"]=R["[object RegExp]"]=R["[object Set]"]=R["[object String]"]=R["[object Symbol]"]=R["[object Uint8Array]"]=R["[object Uint8ClampedArray]"]=R["[object Uint16Array]"]=R["[object Uint32Array]"]=!0,R["[object Error]"]=R["[object Function]"]=R["[object WeakMap]"]=!1;var Ql=function t(e,n,i,r,o,s){var u,c=1&n,h=2&n,m=4&n;if(i&&(u=o?i(e,r,o,s):i(e)),u!==void 0)return u;if(!tt(e))return e;var f=$(e);if(f){if(u=Ah(e),!c)return Vl(e,u)}else{var p=ee(e),x=p=="[object Function]"||p=="[object GeneratorFunction]";if(te(e))return $l(e,c);if(p=="[object Object]"||p=="[object Arguments]"||x&&!o){if(u=h||x?{}:Wl(e),!c)return h?_h(e,bh(u,e)):wh(e,xh(u,e))}else{if(!R[p])return o?e:{};u=Fh(e,p,c)}}s||(s=new ye);var E=s.get(e);if(E)return E;s.set(e,u),Ph(e)?e.forEach(function(S){u.add(t(S,n,i,S,e,s))}):jh(e)&&e.forEach(function(S,b){u.set(b,t(S,n,i,b,e,s))});var v=f?void 0:(m?h?zh:Dr:h?oe:$t)(e);return Xr(v||e,function(S,b){v&&(S=e[b=S]),bi(u,b,t(S,n,i,b,e,s))}),u},$h=function(t){return Ql(t,4)},to=function(t){return function(){return t}},eo=function(t){return function(e,n,i){for(var r=-1,o=Object(e),s=i(e),u=s.length;u--;){var c=s[t?u:++r];if(n(o[c],c,o)===!1)break}return e}}(),no=function(t,e){return t&&eo(t,e,$t)},Ci=function(t,e){return function(n,i){if(n==null)return n;if(!Tt(n))return t(n,i);for(var r=n.length,o=e?r:-1,s=Object(n);(e?o--:++o<r)&&i(s[o],o,s)!==!1;);return n}}(no),ae=function(t){return t},Kl=function(t){return typeof t=="function"?t:ae},Jl=function(t,e){return($(t)?Xr:Ci)(t,Kl(e))},tu=Jl,Vh=function(t,e){var n=[];return Ci(t,function(i,r,o){e(i,r,o)&&n.push(i)}),n},qh=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},Hh=function(t){return this.__data__.has(t)};function ri(t){var e=-1,n=t==null?0:t.length;for(this.__data__=new Ei;++e<n;)this.add(t[e])}ri.prototype.add=ri.prototype.push=qh,ri.prototype.has=Hh;var eu=ri,Uh=function(t,e){for(var n=-1,i=t==null?0:t.length;++n<i;)if(e(t[n],n,t))return!0;return!1},nu=function(t,e){return t.has(e)},iu=function(t,e,n,i,r,o){var s=1&n,u=t.length,c=e.length;if(u!=c&&!(s&&c>u))return!1;var h=o.get(t),m=o.get(e);if(h&&m)return h==e&&m==t;var f=-1,p=!0,x=2&n?new eu:void 0;for(o.set(t,e),o.set(e,t);++f<u;){var E=t[f],v=e[f];if(i)var S=s?i(v,E,f,e,t,o):i(E,v,f,t,e,o);if(S!==void 0){if(S)continue;p=!1;break}if(x){if(!Uh(e,function(b,z){if(!nu(x,z)&&(E===b||r(E,b,n,i,o)))return x.push(z)})){p=!1;break}}else if(E!==v&&!r(E,v,n,i,o)){p=!1;break}}return o.delete(t),o.delete(e),p},Zh=function(t){var e=-1,n=Array(t.size);return t.forEach(function(i,r){n[++e]=[r,i]}),n},io=function(t){var e=-1,n=Array(t.size);return t.forEach(function(i){n[++e]=i}),n},rl=ut?ut.prototype:void 0,wr=rl?rl.valueOf:void 0,Xh=function(t,e,n,i,r,o,s){switch(n){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!o(new li(t),new li(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return Ne(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var u=Zh;case"[object Set]":var c=1&i;if(u||(u=io),t.size!=e.size&&!c)return!1;var h=s.get(t);if(h)return h==e;i|=2,s.set(t,e);var m=iu(u(t),u(e),i,r,o,s);return s.delete(t),m;case"[object Symbol]":if(wr)return wr.call(t)==wr.call(e)}return!1},Yh=Object.prototype.hasOwnProperty,Wh=function(t,e,n,i,r,o){var s=1&n,u=Dr(t),c=u.length;if(c!=Dr(e).length&&!s)return!1;for(var h=c;h--;){var m=u[h];if(!(s?m in e:Yh.call(e,m)))return!1}var f=o.get(t),p=o.get(e);if(f&&p)return f==e&&p==t;var x=!0;o.set(t,e),o.set(e,t);for(var E=s;++h<c;){var v=t[m=u[h]],S=e[m];if(i)var b=s?i(S,v,m,e,t,o):i(v,S,m,t,e,o);if(!(b===void 0?v===S||r(v,S,n,i,o):b)){x=!1;break}E||(E=m=="constructor")}if(x&&!E){var z=t.constructor,k=e.constructor;z==k||!("constructor"in t)||!("constructor"in e)||typeof z=="function"&&z instanceof z&&typeof k=="function"&&k instanceof k||(x=!1)}return o.delete(t),o.delete(e),x},ol=Object.prototype.hasOwnProperty,Qh=function(t,e,n,i,r,o){var s=$(t),u=$(e),c=s?"[object Array]":ee(t),h=u?"[object Array]":ee(e),m=(c=c=="[object Arguments]"?"[object Object]":c)=="[object Object]",f=(h=h=="[object Arguments]"?"[object Object]":h)=="[object Object]",p=c==h;if(p&&te(t)){if(!te(e))return!1;s=!0,m=!1}if(p&&!m)return o||(o=new ye),s||sn(t)?iu(t,e,n,i,r,o):Xh(t,e,c,n,i,r,o);if(!(1&n)){var x=m&&ol.call(t,"__wrapped__"),E=f&&ol.call(e,"__wrapped__");if(x||E){var v=x?t.value():t,S=E?e.value():e;return o||(o=new ye),r(v,S,n,i,o)}}return!!p&&(o||(o=new ye),Wh(t,e,n,i,r,o))},ru=function t(e,n,i,r,o){return e===n||(e==null||n==null||!ft(e)&&!ft(n)?e!=e&&n!=n:Qh(e,n,i,r,t,o))},Kh=function(t,e,n,i){var r=n.length,o=r,s=!i;if(t==null)return!o;for(t=Object(t);r--;){var u=n[r];if(s&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++r<o;){var c=(u=n[r])[0],h=t[c],m=u[1];if(s&&u[2]){if(h===void 0&&!(c in t))return!1}else{var f=new ye;if(i)var p=i(h,m,c,t,e,f);if(!(p===void 0?ru(m,h,3,i,f):p))return!1}}return!0},ou=function(t){return t==t&&!tt(t)},Jh=function(t){for(var e=$t(t),n=e.length;n--;){var i=e[n],r=t[i];e[n]=[i,r,ou(r)]}return e},au=function(t,e){return function(n){return n!=null&&n[t]===e&&(e!==void 0||t in Object(n))}},tm=function(t){var e=Jh(t);return e.length==1&&e[0][2]?au(e[0][0],e[0][1]):function(n){return n===t||Kh(n,t,e)}},ne=function(t){return typeof t=="symbol"||ft(t)&&Pt(t)=="[object Symbol]"},em=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,nm=/^\w*$/,ro=function(t,e){if($(t))return!1;var n=typeof t;return!(n!="number"&&n!="symbol"&&n!="boolean"&&t!=null&&!ne(t))||nm.test(t)||!em.test(t)||e!=null&&t in Object(e)};function oo(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError("Expected a function");var n=function(){var i=arguments,r=e?e.apply(this,i):i[0],o=n.cache;if(o.has(r))return o.get(r);var s=t.apply(this,i);return n.cache=o.set(r,s)||o,s};return n.cache=new(oo.Cache||Ei),n}oo.Cache=Ei;var im=oo,rm=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,om=/\\(\\)?/g,am=function(t){var e=im(t,function(i){return n.size===500&&n.clear(),i}),n=e.cache;return e}(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(rm,function(n,i,r,o){e.push(r?o.replace(om,"$1"):i||n)}),e}),Se=function(t,e){for(var n=-1,i=t==null?0:t.length,r=Array(i);++n<i;)r[n]=e(t[n],n,t);return r},al=ut?ut.prototype:void 0,sl=al?al.toString:void 0,sm=function t(e){if(typeof e=="string")return e;if($(e))return Se(e,t)+"";if(ne(e))return sl?sl.call(e):"";var n=e+"";return n=="0"&&1/e==-1/0?"-0":n},su=function(t){return t==null?"":sm(t)},Ni=function(t,e){return $(t)?t:ro(t,e)?[t]:am(su(t))},ln=function(t){if(typeof t=="string"||ne(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e},ki=function(t,e){for(var n=0,i=(e=Ni(e,t)).length;t!=null&&n<i;)t=t[ln(e[n++])];return n&&n==i?t:void 0},lm=function(t,e,n){var i=t==null?void 0:ki(t,e);return i===void 0?n:i},um=function(t,e){return t!=null&&e in Object(t)},lu=function(t,e,n){for(var i=-1,r=(e=Ni(e,t)).length,o=!1;++i<r;){var s=ln(e[i]);if(!(o=t!=null&&n(t,s)))break;t=t[s]}return o||++i!=r?o:!!(r=t==null?0:t.length)&&Yr(r)&&Si(s,r)&&($(t)||ze(t))},uu=function(t,e){return t!=null&&lu(t,e,um)},dm=function(t,e){return ro(t)&&ou(e)?au(ln(t),e):function(n){var i=lm(n,t);return i===void 0&&i===e?uu(n,t):ru(e,i,3)}},du=function(t){return function(e){return e?.[t]}},cm=function(t){return function(e){return ki(e,t)}},hm=function(t){return ro(t)?du(ln(t)):cm(t)},Dt=function(t){return typeof t=="function"?t:t==null?ae:typeof t=="object"?$(t)?dm(t[0],t[1]):tm(t):hm(t)},cu=function(t,e){return($(t)?ql:Vh)(t,Dt(e))},mm=Object.prototype.hasOwnProperty,fm=function(t,e){return t!=null&&mm.call(t,e)},hu=function(t,e){return t!=null&&lu(t,e,fm)},pm=Object.prototype.hasOwnProperty,gm=function(t){if(t==null)return!0;if(Tt(t)&&($(t)||typeof t=="string"||typeof t.splice=="function"||te(t)||sn(t)||ze(t)))return!t.length;var e=ee(t);if(e=="[object Map]"||e=="[object Set]")return!t.size;if(_i(t))return!Wr(t).length;for(var n in t)if(pm.call(t,n))return!1;return!0},mu=function(t){return t===void 0},fu=function(t,e){var n=-1,i=Tt(t)?Array(t.length):[];return Ci(t,function(r,o,s){i[++n]=e(r,o,s)}),i},pu=function(t,e){return($(t)?Se:fu)(t,Dt(e))},xm=function(t,e,n,i){var r=-1,o=t==null?0:t.length;for(i&&o&&(n=t[++r]);++r<o;)n=e(n,t[r],r,t);return n},vm=function(t,e,n,i,r){return r(t,function(o,s,u){n=i?(i=!1,o):e(n,o,s,u)}),n},gu=function(t,e,n){var i=$(t)?xm:vm,r=arguments.length<3;return i(t,Dt(e),n,r,Ci)},Em=function(t){return typeof t=="string"||!$(t)&&ft(t)&&Pt(t)=="[object String]"},ym=du("length"),bm=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]"),Sm=function(t){return bm.test(t)},wm="[\\ud800-\\udfff]",Ir="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",Gr="\\ud83c[\\udffb-\\udfff]",xu="[^\\ud800-\\udfff]",vu="(?:\\ud83c[\\udde6-\\uddff]){2}",Eu="[\\ud800-\\udbff][\\udc00-\\udfff]",ll="(?:"+Ir+"|"+Gr+")?",_m="[\\ufe0e\\ufe0f]?"+ll+("(?:\\u200d(?:"+[xu,vu,Eu].join("|")+")[\\ufe0e\\ufe0f]?"+ll+")*"),zm="(?:"+[xu+Ir+"?",Ir,vu,Eu,wm].join("|")+")",ul=RegExp(Gr+"(?="+Gr+")|"+zm+_m,"g"),Cm=function(t){for(var e=ul.lastIndex=0;ul.test(t);)++e;return e},Nm=function(t){return Sm(t)?Cm(t):ym(t)},km=function(t){if(t==null)return 0;if(Tt(t))return Em(t)?Nm(t):t.length;var e=ee(t);return e=="[object Map]"||e=="[object Set]"?t.size:Wr(t).length},Om=function(t,e,n){var i=$(t),r=i||te(t)||sn(t);if(e=Dt(e),n==null){var o=t&&t.constructor;n=r?i?new o:[]:tt(t)&&on(o)?Yl(zi(t)):{}}return(r?Xr:no)(t,function(s,u,c){return e(n,s,u,c)}),n},dl=ut?ut.isConcatSpreadable:void 0,Tm=function(t){return $(t)||ze(t)||!!(dl&&t&&t[dl])},ao=function t(e,n,i,r,o){var s=-1,u=e.length;for(i||(i=Tm),o||(o=[]);++s<u;){var c=e[s];n>0&&i(c)?n>1?t(c,n-1,i,r,o):Kr(o,c):r||(o[o.length]=c)}return o},Dm=function(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)},cl=Math.max,yu=function(t,e,n){return e=cl(e===void 0?t.length-1:e,0),function(){for(var i=arguments,r=-1,o=cl(i.length-e,0),s=Array(o);++r<o;)s[r]=i[e+r];r=-1;for(var u=Array(e+1);++r<e;)u[r]=i[r];return u[e]=n(s),Dm(t,this,u)}},Am=si?function(t,e){return si(t,"toString",{configurable:!0,enumerable:!1,value:to(e),writable:!0})}:ae,Bm=Date.now,bu=function(t){var e=0,n=0;return function(){var i=Bm(),r=16-(i-n);if(n=i,r>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(Am),Oi=function(t,e){return bu(yu(t,e,ae),t+"")},Su=function(t,e,n,i){for(var r=t.length,o=n+(i?1:-1);i?o--:++o<r;)if(e(t[o],o,t))return o;return-1},Mm=function(t){return t!=t},Im=function(t,e,n){for(var i=n-1,r=t.length;++i<r;)if(t[i]===e)return i;return-1},Gm=function(t,e,n){return e==e?Im(t,e,n):Su(t,Mm,n)},Fm=function(t,e){return!!(t!=null&&t.length)&&Gm(t,e,0)>-1},Rm=function(t,e,n){for(var i=-1,r=t==null?0:t.length;++i<r;)if(n(e,t[i]))return!0;return!1},jm=function(){},Lm=be&&1/io(new be([,-0]))[1]==1/0?function(t){return new be(t)}:jm,Pm=function(t,e,n){var i=-1,r=Fm,o=t.length,s=!0,u=[],c=u;if(n)s=!1,r=Rm;else if(o>=200){var h=e?null:Lm(t);if(h)return io(h);s=!1,r=nu,c=new eu}else c=e?[]:u;t:for(;++i<o;){var m=t[i],f=e?e(m):m;if(m=n||m!==0?m:0,s&&f==f){for(var p=c.length;p--;)if(c[p]===f)continue t;e&&c.push(f),u.push(m)}else r(c,f,n)||(c!==u&&c.push(f),u.push(m))}return u},wu=function(t){return ft(t)&&Tt(t)},$m=Oi(function(t){return Pm(ao(t,1,wu,!0))}),Vm=function(t,e){return Se(e,function(n){return t[n]})},ui,_u=function(t){return t==null?[]:Vm(t,$t(t))};try{ui={clone:$h,constant:to,each:tu,filter:cu,has:hu,isArray:$,isEmpty:gm,isFunction:on,isUndefined:mu,keys:$t,map:pu,reduce:gu,size:km,transform:Om,union:$m,values:_u}}catch{}ui||(ui=window._);var _=ui,so=D;function D(t){this._isDirected=!_.has(t,"directed")||t.directed,this._isMultigraph=!!_.has(t,"multigraph")&&t.multigraph,this._isCompound=!!_.has(t,"compound")&&t.compound,this._label=void 0,this._defaultNodeLabelFn=_.constant(void 0),this._defaultEdgeLabelFn=_.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children["\0"]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}function hl(t,e){t[e]?t[e]++:t[e]=1}function ml(t,e){--t[e]||delete t[e]}function Je(t,e,n,i){var r=""+e,o=""+n;if(!t&&r>o){var s=r;r=o,o=s}return r+""+o+""+(_.isUndefined(i)?"\0":i)}function qm(t,e,n,i){var r=""+e,o=""+n;if(!t&&r>o){var s=r;r=o,o=s}var u={v:r,w:o};return i&&(u.name=i),u}function _r(t,e){return Je(t,e.v,e.w,e.name)}D.prototype._nodeCount=0,D.prototype._edgeCount=0,D.prototype.isDirected=function(){return this._isDirected},D.prototype.isMultigraph=function(){return this._isMultigraph},D.prototype.isCompound=function(){return this._isCompound},D.prototype.setGraph=function(t){return this._label=t,this},D.prototype.graph=function(){return this._label},D.prototype.setDefaultNodeLabel=function(t){return _.isFunction(t)||(t=_.constant(t)),this._defaultNodeLabelFn=t,this},D.prototype.nodeCount=function(){return this._nodeCount},D.prototype.nodes=function(){return _.keys(this._nodes)},D.prototype.sources=function(){var t=this;return _.filter(this.nodes(),function(e){return _.isEmpty(t._in[e])})},D.prototype.sinks=function(){var t=this;return _.filter(this.nodes(),function(e){return _.isEmpty(t._out[e])})},D.prototype.setNodes=function(t,e){var n=arguments,i=this;return _.each(t,function(r){n.length>1?i.setNode(r,e):i.setNode(r)}),this},D.prototype.setNode=function(t,e){return _.has(this._nodes,t)?(arguments.length>1&&(this._nodes[t]=e),this):(this._nodes[t]=arguments.length>1?e:this._defaultNodeLabelFn(t),this._isCompound&&(this._parent[t]="\0",this._children[t]={},this._children["\0"][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},D.prototype.node=function(t){return this._nodes[t]},D.prototype.hasNode=function(t){return _.has(this._nodes,t)},D.prototype.removeNode=function(t){var e=this;if(_.has(this._nodes,t)){var n=function(i){e.removeEdge(e._edgeObjs[i])};delete this._nodes[t],this._isCompound&&(this._removeFromParentsChildList(t),delete this._parent[t],_.each(this.children(t),function(i){e.setParent(i)}),delete this._children[t]),_.each(_.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],_.each(_.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},D.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(_.isUndefined(e))e="\0";else{for(var n=e+="";!_.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},D.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},D.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!=="\0")return e}},D.prototype.children=function(t){if(_.isUndefined(t)&&(t="\0"),this._isCompound){var e=this._children[t];if(e)return _.keys(e)}else{if(t==="\0")return this.nodes();if(this.hasNode(t))return[]}},D.prototype.predecessors=function(t){var e=this._preds[t];if(e)return _.keys(e)},D.prototype.successors=function(t){var e=this._sucs[t];if(e)return _.keys(e)},D.prototype.neighbors=function(t){var e=this.predecessors(t);if(e)return _.union(e,this.successors(t))},D.prototype.isLeaf=function(t){return(this.isDirected()?this.successors(t):this.neighbors(t)).length===0},D.prototype.filterNodes=function(t){var e=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});e.setGraph(this.graph());var n=this;_.each(this._nodes,function(o,s){t(s)&&e.setNode(s,o)}),_.each(this._edgeObjs,function(o){e.hasNode(o.v)&&e.hasNode(o.w)&&e.setEdge(o,n.edge(o))});var i={};function r(o){var s=n.parent(o);return s===void 0||e.hasNode(s)?(i[o]=s,s):s in i?i[s]:r(s)}return this._isCompound&&_.each(e.nodes(),function(o){e.setParent(o,r(o))}),e},D.prototype.setDefaultEdgeLabel=function(t){return _.isFunction(t)||(t=_.constant(t)),this._defaultEdgeLabelFn=t,this},D.prototype.edgeCount=function(){return this._edgeCount},D.prototype.edges=function(){return _.values(this._edgeObjs)},D.prototype.setPath=function(t,e){var n=this,i=arguments;return _.reduce(t,function(r,o){return i.length>1?n.setEdge(r,o,e):n.setEdge(r,o),o}),this},D.prototype.setEdge=function(){var t,e,n,i,r=!1,o=arguments[0];typeof o=="object"&&o!==null&&"v"in o?(t=o.v,e=o.w,n=o.name,arguments.length===2&&(i=arguments[1],r=!0)):(t=o,e=arguments[1],n=arguments[3],arguments.length>2&&(i=arguments[2],r=!0)),t=""+t,e=""+e,_.isUndefined(n)||(n=""+n);var s=Je(this._isDirected,t,e,n);if(_.has(this._edgeLabels,s))return r&&(this._edgeLabels[s]=i),this;if(!_.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[s]=r?i:this._defaultEdgeLabelFn(t,e,n);var u=qm(this._isDirected,t,e,n);return t=u.v,e=u.w,Object.freeze(u),this._edgeObjs[s]=u,hl(this._preds[e],t),hl(this._sucs[t],e),this._in[e][s]=u,this._out[t][s]=u,this._edgeCount++,this},D.prototype.edge=function(t,e,n){var i=arguments.length===1?_r(this._isDirected,arguments[0]):Je(this._isDirected,t,e,n);return this._edgeLabels[i]},D.prototype.hasEdge=function(t,e,n){var i=arguments.length===1?_r(this._isDirected,arguments[0]):Je(this._isDirected,t,e,n);return _.has(this._edgeLabels,i)},D.prototype.removeEdge=function(t,e,n){var i=arguments.length===1?_r(this._isDirected,arguments[0]):Je(this._isDirected,t,e,n),r=this._edgeObjs[i];return r&&(t=r.v,e=r.w,delete this._edgeLabels[i],delete this._edgeObjs[i],ml(this._preds[e],t),ml(this._sucs[t],e),delete this._in[e][i],delete this._out[t][i],this._edgeCount--),this},D.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var i=_.values(n);return e?_.filter(i,function(r){return r.v===e}):i}},D.prototype.outEdges=function(t,e){var n=this._out[t];if(n){var i=_.values(n);return e?_.filter(i,function(r){return r.w===e}):i}},D.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);if(n)return n.concat(this.outEdges(t,e))};var fl={Graph:so,version:"2.1.8"},Hm={write:function(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:Um(t),edges:Zm(t)};return _.isUndefined(t.graph())||(e.value=_.clone(t.graph())),e},read:function(t){var e=new so(t.options).setGraph(t.value);return _.each(t.nodes,function(n){e.setNode(n.v,n.value),n.parent&&e.setParent(n.v,n.parent)}),_.each(t.edges,function(n){e.setEdge({v:n.v,w:n.w,name:n.name},n.value)}),e}};function Um(t){return _.map(t.nodes(),function(e){var n=t.node(e),i=t.parent(e),r={v:e};return _.isUndefined(n)||(r.value=n),_.isUndefined(i)||(r.parent=i),r})}function Zm(t){return _.map(t.edges(),function(e){var n=t.edge(e),i={v:e.v,w:e.w};return _.isUndefined(e.name)||(i.name=e.name),_.isUndefined(n)||(i.value=n),i})}var Xm=function(t){var e,n={},i=[];function r(o){_.has(n,o)||(n[o]=!0,e.push(o),_.each(t.successors(o),r),_.each(t.predecessors(o),r))}return _.each(t.nodes(),function(o){e=[],r(o),e.length&&i.push(e)}),i},zu=lt;function lt(){this._arr=[],this._keyIndices={}}lt.prototype.size=function(){return this._arr.length},lt.prototype.keys=function(){return this._arr.map(function(t){return t.key})},lt.prototype.has=function(t){return _.has(this._keyIndices,t)},lt.prototype.priority=function(t){var e=this._keyIndices[t];if(e!==void 0)return this._arr[e].priority},lt.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},lt.prototype.add=function(t,e){var n=this._keyIndices;if(t=String(t),!_.has(n,t)){var i=this._arr,r=i.length;return n[t]=r,i.push({key:t,priority:e}),this._decrease(r),!0}return!1},lt.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var t=this._arr.pop();return delete this._keyIndices[t.key],this._heapify(0),t.key},lt.prototype.decrease=function(t,e){var n=this._keyIndices[t];if(e>this._arr[n].priority)throw new Error("New priority is greater than current priority. Key: "+t+" Old: "+this._arr[n].priority+" New: "+e);this._arr[n].priority=e,this._decrease(n)},lt.prototype._heapify=function(t){var e=this._arr,n=2*t,i=n+1,r=t;n<e.length&&(r=e[n].priority<e[r].priority?n:r,i<e.length&&(r=e[i].priority<e[r].priority?i:r),r!==t&&(this._swap(t,r),this._heapify(r)))},lt.prototype._decrease=function(t){for(var e,n=this._arr,i=n[t].priority;t!==0&&!(n[e=t>>1].priority<i);)this._swap(t,e),t=e},lt.prototype._swap=function(t,e){var n=this._arr,i=this._keyIndices,r=n[t],o=n[e];n[t]=o,n[e]=r,i[o.key]=t,i[r.key]=e};var Cu=function(t,e,n,i){return function(r,o,s,u){var c,h,m={},f=new zu,p=function(x){var E=x.v!==c?x.v:x.w,v=m[E],S=s(x),b=h.distance+S;if(S<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+x+" Weight: "+S);b<v.distance&&(v.distance=b,v.predecessor=c,f.decrease(E,b))};for(r.nodes().forEach(function(x){var E=x===o?0:Number.POSITIVE_INFINITY;m[x]={distance:E},f.add(x,E)});f.size()>0&&(c=f.removeMin(),(h=m[c]).distance!==Number.POSITIVE_INFINITY);)u(c).forEach(p);return m}(t,String(e),n||Ym,i||function(r){return t.outEdges(r)})},Ym=_.constant(1),Wm=function(t,e,n){return _.transform(t.nodes(),function(i,r){i[r]=Cu(t,r,e,n)},{})},Nu=function(t){var e=0,n=[],i={},r=[];function o(s){var u=i[s]={onStack:!0,lowlink:e,index:e++};if(n.push(s),t.successors(s).forEach(function(m){_.has(i,m)?i[m].onStack&&(u.lowlink=Math.min(u.lowlink,i[m].index)):(o(m),u.lowlink=Math.min(u.lowlink,i[m].lowlink))}),u.lowlink===u.index){var c,h=[];do c=n.pop(),i[c].onStack=!1,h.push(c);while(s!==c);r.push(h)}}return t.nodes().forEach(function(s){_.has(i,s)||o(s)}),r},Qm=function(t){return _.filter(Nu(t),function(e){return e.length>1||e.length===1&&t.hasEdge(e[0],e[0])})},Km=function(t,e,n){return function(i,r,o){var s={},u=i.nodes();return u.forEach(function(c){s[c]={},s[c][c]={distance:0},u.forEach(function(h){c!==h&&(s[c][h]={distance:Number.POSITIVE_INFINITY})}),o(c).forEach(function(h){var m=h.v===c?h.w:h.v,f=r(h);s[c][m]={distance:f,predecessor:c}})}),u.forEach(function(c){var h=s[c];u.forEach(function(m){var f=s[m];u.forEach(function(p){var x=f[c],E=h[p],v=f[p],S=x.distance+E.distance;S<v.distance&&(v.distance=S,v.predecessor=E.predecessor)})})}),s}(t,e||Jm,n||function(i){return t.outEdges(i)})},Jm=_.constant(1),zr=ku;function ku(t){var e={},n={},i=[];if(_.each(t.sinks(),function r(o){if(_.has(n,o))throw new di;_.has(e,o)||(n[o]=!0,e[o]=!0,_.each(t.predecessors(o),r),delete n[o],i.push(o))}),_.size(e)!==t.nodeCount())throw new di;return i}function di(){}ku.CycleException=di,di.prototype=new Error;var pl=function(t,e,n){_.isArray(e)||(e=[e]);var i=(t.isDirected()?t.successors:t.neighbors).bind(t),r=[],o={};return _.each(e,function(s){if(!t.hasNode(s))throw new Error("Graph does not have node: "+s);Ou(t,s,n==="post",o,i,r)}),r};function Ou(t,e,n,i,r,o){_.has(i,e)||(i[e]=!0,n||o.push(e),_.each(r(e),function(s){Ou(t,s,n,i,r,o)}),n&&o.push(e))}var ci,tf={Graph:fl.Graph,json:Hm,alg:{components:Xm,dijkstra:Cu,dijkstraAll:Wm,findCycles:Qm,floydWarshall:Km,isAcyclic:function(t){try{zr(t)}catch(e){if(e instanceof zr.CycleException)return!1;throw e}return!0},postorder:function(t,e){return pl(t,e,"post")},preorder:function(t,e){return pl(t,e,"pre")},prim:function(t,e){var n,i=new so,r={},o=new zu;function s(c){var h=c.v===n?c.w:c.v,m=o.priority(h);if(m!==void 0){var f=e(c);f<m&&(r[h]=n,o.decrease(h,f))}}if(t.nodeCount()===0)return i;_.each(t.nodes(),function(c){o.add(c,Number.POSITIVE_INFINITY),i.setNode(c)}),o.decrease(t.nodes()[0],0);for(var u=!1;o.size()>0;){if(n=o.removeMin(),_.has(r,n))i.setEdge(n,r[n]);else{if(u)throw new Error("Input graph is not connected: "+t);u=!0}t.nodeEdges(n).forEach(s)}return i},tarjan:Nu,topsort:zr},version:fl.version};try{ci=tf}catch{}ci||(ci=window.graphlib);var gt=ci,ef=function(t){return Ql(t,5)},rn=function(t,e,n){if(!tt(n))return!1;var i=typeof e;return!!(i=="number"?Tt(n)&&Si(e,n.length):i=="string"&&e in n)&&Ne(n[e],t)},Tu=Object.prototype,nf=Tu.hasOwnProperty,rf=Oi(function(t,e){t=Object(t);var n=-1,i=e.length,r=i>2?e[2]:void 0;for(r&&rn(e[0],e[1],r)&&(i=1);++n<i;)for(var o=e[n],s=oe(o),u=-1,c=s.length;++u<c;){var h=s[u],m=t[h];(m===void 0||Ne(m,Tu[h])&&!nf.call(t,h))&&(t[h]=o[h])}return t}),of=function(t){return function(e,n,i){var r=Object(e);if(!Tt(e)){var o=Dt(n);e=$t(e),n=function(u){return o(r[u],u,r)}}var s=t(e,n,i);return s>-1?r[o?e[s]:s]:void 0}},af=/^\s+|\s+$/g,sf=/^[-+]0x[0-9a-f]+$/i,lf=/^0b[01]+$/i,uf=/^0o[0-7]+$/i,df=parseInt,cf=function(t){if(typeof t=="number")return t;if(ne(t))return NaN;if(tt(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=tt(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=t.replace(af,"");var n=lf.test(t);return n||uf.test(t)?df(t.slice(2),n?2:8):sf.test(t)?NaN:+t},oi=function(t){return t?(t=cf(t))===1/0||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:t===0?t:0},hf=function(t){var e=oi(t),n=e%1;return e==e?n?e-n:e:0},mf=Math.max,ff=of(function(t,e,n){var i=t==null?0:t.length;if(!i)return-1;var r=n==null?0:hf(n);return r<0&&(r=mf(i+r,0)),Su(t,Dt(e),r)}),Du=function(t){return t!=null&&t.length?ao(t,1):[]},pf=function(t,e){return t==null?t:eo(t,Kl(e),oe)},gf=function(t){var e=t==null?0:t.length;return e?t[e-1]:void 0},xf=function(t,e){var n={};return e=Dt(e),no(t,function(i,r,o){yi(n,r,e(i,r,o))}),n},lo=function(t,e,n){for(var i=-1,r=t.length;++i<r;){var o=t[i],s=e(o);if(s!=null&&(u===void 0?s==s&&!ne(s):n(s,u)))var u=s,c=o}return c},vf=function(t,e){return t>e},Ef=function(t){return t&&t.length?lo(t,ae,vf):void 0},Fr=function(t,e,n){(n!==void 0&&!Ne(t[e],n)||n===void 0&&!(e in t))&&yi(t,e,n)},yf=Function.prototype,bf=Object.prototype,Au=yf.toString,Sf=bf.hasOwnProperty,wf=Au.call(Object),_f=function(t){if(!ft(t)||Pt(t)!="[object Object]")return!1;var e=zi(t);if(e===null)return!0;var n=Sf.call(e,"constructor")&&e.constructor;return typeof n=="function"&&n instanceof n&&Au.call(n)==wf},Rr=function(t,e){if((e!=="constructor"||typeof t[e]!="function")&&e!="__proto__")return t[e]},zf=function(t){return an(t,oe(t))},Cf=function(t,e,n,i,r,o,s){var u=Rr(t,n),c=Rr(e,n),h=s.get(c);if(h)Fr(t,n,h);else{var m=o?o(u,c,n+"",t,e,s):void 0,f=m===void 0;if(f){var p=$(c),x=!p&&te(c),E=!p&&!x&&sn(c);m=c,p||x||E?$(u)?m=u:wu(u)?m=Vl(u):x?(f=!1,m=$l(c,!0)):E?(f=!1,m=Xl(c,!0)):m=[]:_f(c)||ze(c)?(m=u,ze(u)?m=zf(u):tt(u)&&!on(u)||(m=Wl(c))):f=!1}f&&(s.set(c,m),r(m,c,i,o,s),s.delete(c)),Fr(t,n,m)}},Nf=function t(e,n,i,r,o){e!==n&&eo(n,function(s,u){if(o||(o=new ye),tt(s))Cf(e,n,u,i,t,r,o);else{var c=r?r(Rr(e,u),s,u+"",e,n,o):void 0;c===void 0&&(c=s),Fr(e,u,c)}},oe)},kf=function(t){return Oi(function(e,n){var i=-1,r=n.length,o=r>1?n[r-1]:void 0,s=r>2?n[2]:void 0;for(o=t.length>3&&typeof o=="function"?(r--,o):void 0,s&&rn(n[0],n[1],s)&&(o=r<3?void 0:o,r=1),e=Object(e);++i<r;){var u=n[i];u&&t(e,u,i,o)}return e})}(function(t,e,n){Nf(t,e,n)}),Bu=function(t,e){return t<e},Of=function(t){return t&&t.length?lo(t,ae,Bu):void 0},Tf=function(t,e){return t&&t.length?lo(t,Dt(e),Bu):void 0},Df=function(){return pt.Date.now()},Af=function(t,e,n,i){if(!tt(t))return t;for(var r=-1,o=(e=Ni(e,t)).length,s=o-1,u=t;u!=null&&++r<o;){var c=ln(e[r]),h=n;if(c==="__proto__"||c==="constructor"||c==="prototype")return t;if(r!=s){var m=u[c];(h=i?i(m,c,u):void 0)===void 0&&(h=tt(m)?m:Si(e[r+1])?[]:{})}bi(u,c,h),u=u[c]}return t},Bf=function(t,e,n){for(var i=-1,r=e.length,o={};++i<r;){var s=e[i],u=ki(t,s);n(u,s)&&Af(o,Ni(s,t),u)}return o},Mf=function(t,e){return Bf(t,e,function(n,i){return uu(t,i)})},If=function(t){return bu(yu(t,void 0,Du),t+"")}(function(t,e){return t==null?{}:Mf(t,e)}),Gf=Math.ceil,Ff=Math.max,Rf=function(t,e,n,i){for(var r=-1,o=Ff(Gf((e-t)/(n||1)),0),s=Array(o);o--;)s[i?o:++r]=t,t+=n;return s},jf=function(t){return function(e,n,i){return i&&typeof i!="number"&&rn(e,n,i)&&(n=i=void 0),e=oi(e),n===void 0?(n=e,e=0):n=oi(n),i=i===void 0?e<n?1:-1:oi(i),Rf(e,n,i,t)}}(),Lf=function(t,e){var n=t.length;for(t.sort(e);n--;)t[n]=t[n].value;return t},Pf=function(t,e){if(t!==e){var n=t!==void 0,i=t===null,r=t==t,o=ne(t),s=e!==void 0,u=e===null,c=e==e,h=ne(e);if(!u&&!h&&!o&&t>e||o&&s&&c&&!u&&!h||i&&s&&c||!n&&c||!r)return 1;if(!i&&!o&&!h&&t<e||h&&n&&r&&!i&&!o||u&&n&&r||!s&&r||!c)return-1}return 0},$f=function(t,e,n){for(var i=-1,r=t.criteria,o=e.criteria,s=r.length,u=n.length;++i<s;){var c=Pf(r[i],o[i]);if(c)return i>=u?c:c*(n[i]=="desc"?-1:1)}return t.index-e.index},Vf=function(t,e,n){e=e.length?Se(e,function(o){return $(o)?function(s){return ki(s,o.length===1?o[0]:o)}:o}):[ae];var i=-1;e=Se(e,wi(Dt));var r=fu(t,function(o,s,u){return{criteria:Se(e,function(c){return c(o)}),index:++i,value:o}});return Lf(r,function(o,s){return $f(o,s,n)})},qf=Oi(function(t,e){if(t==null)return[];var n=e.length;return n>1&&rn(t,e[0],e[1])?e=[]:n>2&&rn(e[0],e[1],e[2])&&(e=[e[0]]),Vf(t,ao(e,1),[])}),Hf=0,Uf=function(t){var e=++Hf;return su(t)+e},Zf=function(t,e,n){for(var i=-1,r=t.length,o=e.length,s={};++i<r;){var u=i<o?e[i]:void 0;n(s,t[i],u)}return s},hi,Xf=function(t,e){return Zf(t||[],e||[],bi)};try{hi={cloneDeep:ef,constant:to,defaults:rf,each:tu,filter:cu,find:ff,flatten:Du,forEach:Jl,forIn:pf,has:hu,isUndefined:mu,last:gf,map:pu,mapValues:xf,max:Ef,merge:kf,min:Of,minBy:Tf,now:Df,pick:If,range:jf,reduce:gu,sortBy:qf,uniqueId:Uf,values:_u,zipObject:Xf}}catch{}hi||(hi=window._);var g=hi,Yf=ai;function ai(){var t={};t._next=t._prev=t,this._sentinel=t}function gl(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function Wf(t,e){if(t!=="_next"&&t!=="_prev")return e}ai.prototype.dequeue=function(){var t=this._sentinel,e=t._prev;if(e!==t)return gl(e),e},ai.prototype.enqueue=function(t){var e=this._sentinel;t._prev&&t._next&&gl(t),t._next=e._next,e._next._prev=t,e._next=t,t._prev=e},ai.prototype.toString=function(){for(var t=[],e=this._sentinel,n=e._prev;n!==e;)t.push(JSON.stringify(n,Wf)),n=n._prev;return"["+t.join(", ")+"]"};var Qf=gt.Graph,Kf=function(t,e){if(t.nodeCount()<=1)return[];var n=function(r,o){var s=new Qf,u=0,c=0;g.forEach(r.nodes(),function(f){s.setNode(f,{v:f,in:0,out:0})}),g.forEach(r.edges(),function(f){var p=s.edge(f.v,f.w)||0,x=o(f),E=p+x;s.setEdge(f.v,f.w,E),c=Math.max(c,s.node(f.v).out+=x),u=Math.max(u,s.node(f.w).in+=x)});var h=g.range(c+u+3).map(function(){return new Yf}),m=u+1;return g.forEach(s.nodes(),function(f){jr(h,m,s.node(f))}),{graph:s,buckets:h,zeroIdx:m}}(t,e||Jf),i=function(r,o,s){for(var u,c=[],h=o[o.length-1],m=o[0];r.nodeCount();){for(;u=m.dequeue();)Cr(r,o,s,u);for(;u=h.dequeue();)Cr(r,o,s,u);if(r.nodeCount()){for(var f=o.length-2;f>0;--f)if(u=o[f].dequeue()){c=c.concat(Cr(r,o,s,u,!0));break}}}return c}(n.graph,n.buckets,n.zeroIdx);return g.flatten(g.map(i,function(r){return t.outEdges(r.v,r.w)}),!0)},Jf=g.constant(1);function Cr(t,e,n,i,r){var o=r?[]:void 0;return g.forEach(t.inEdges(i.v),function(s){var u=t.edge(s),c=t.node(s.v);r&&o.push({v:s.v,w:s.w}),c.out-=u,jr(e,n,c)}),g.forEach(t.outEdges(i.v),function(s){var u=t.edge(s),c=s.w,h=t.node(c);h.in-=u,jr(e,n,h)}),t.removeNode(i.v),o}function jr(t,e,n){n.out?n.in?t[n.out-n.in+e].enqueue(n):t[t.length-1].enqueue(n):t[0].enqueue(n)}var xl={run:function(t){var e=t.graph().acyclicer==="greedy"?Kf(t,function(n){return function(i){return n.edge(i).weight}}(t)):function(n){var i=[],r={},o={};function s(u){g.has(o,u)||(o[u]=!0,r[u]=!0,g.forEach(n.outEdges(u),function(c){g.has(r,c.w)?i.push(c):s(c.w)}),delete r[u])}return g.forEach(n.nodes(),s),i}(t);g.forEach(e,function(n){var i=t.edge(n);t.removeEdge(n),i.forwardName=n.name,i.reversed=!0,t.setEdge(n.w,n.v,i,g.uniqueId("rev"))})},undo:function(t){g.forEach(t.edges(),function(e){var n=t.edge(e);if(n.reversed){t.removeEdge(e);var i=n.forwardName;delete n.reversed,delete n.forwardName,t.setEdge(e.w,e.v,n,i)}})}},vl=gt.Graph,Z={addDummyNode:El,simplify:function(t){var e=new vl().setGraph(t.graph());return g.forEach(t.nodes(),function(n){e.setNode(n,t.node(n))}),g.forEach(t.edges(),function(n){var i=e.edge(n.v,n.w)||{weight:0,minlen:1},r=t.edge(n);e.setEdge(n.v,n.w,{weight:i.weight+r.weight,minlen:Math.max(i.minlen,r.minlen)})}),e},asNonCompoundGraph:function(t){var e=new vl({multigraph:t.isMultigraph()}).setGraph(t.graph());return g.forEach(t.nodes(),function(n){t.children(n).length||e.setNode(n,t.node(n))}),g.forEach(t.edges(),function(n){e.setEdge(n,t.edge(n))}),e},successorWeights:function(t){var e=g.map(t.nodes(),function(n){var i={};return g.forEach(t.outEdges(n),function(r){i[r.w]=(i[r.w]||0)+t.edge(r).weight}),i});return g.zipObject(t.nodes(),e)},predecessorWeights:function(t){var e=g.map(t.nodes(),function(n){var i={};return g.forEach(t.inEdges(n),function(r){i[r.v]=(i[r.v]||0)+t.edge(r).weight}),i});return g.zipObject(t.nodes(),e)},intersectRect:function(t,e){var n,i,r=t.x,o=t.y,s=e.x-r,u=e.y-o,c=t.width/2,h=t.height/2;if(!s&&!u)throw new Error("Not possible to find intersection inside of the rectangle");return Math.abs(u)*c>Math.abs(s)*h?(u<0&&(h=-h),n=h*s/u,i=h):(s<0&&(c=-c),n=c,i=c*u/s),{x:r+n,y:o+i}},buildLayerMatrix:function(t){var e=g.map(g.range(yl(t)+1),function(){return[]});return g.forEach(t.nodes(),function(n){var i=t.node(n),r=i.rank;g.isUndefined(r)||(e[r][i.order]=n)}),e},normalizeRanks:function(t){var e=g.min(g.map(t.nodes(),function(n){return t.node(n).rank}));g.forEach(t.nodes(),function(n){var i=t.node(n);g.has(i,"rank")&&(i.rank-=e)})},removeEmptyRanks:function(t){var e=g.min(g.map(t.nodes(),function(o){return t.node(o).rank})),n=[];g.forEach(t.nodes(),function(o){var s=t.node(o).rank-e;n[s]||(n[s]=[]),n[s].push(o)});var i=0,r=t.graph().nodeRankFactor;g.forEach(n,function(o,s){g.isUndefined(o)&&s%r!=0?--i:i&&g.forEach(o,function(u){t.node(u).rank+=i})})},addBorderNode:function(t,e,n,i){var r={width:0,height:0};return arguments.length>=4&&(r.rank=n,r.order=i),El(t,"border",r,e)},maxRank:yl,partition:function(t,e){var n={lhs:[],rhs:[]};return g.forEach(t,function(i){e(i)?n.lhs.push(i):n.rhs.push(i)}),n},time:function(t,e){var n=g.now();try{return e()}finally{console.log(t+" time: "+(g.now()-n)+"ms")}},notime:function(t,e){return e()}};function El(t,e,n,i){var r;do r=g.uniqueId(i);while(t.hasNode(r));return n.dummy=e,t.setNode(r,n),r}function yl(t){return g.max(g.map(t.nodes(),function(e){var n=t.node(e).rank;if(!g.isUndefined(n))return n}))}var bl={run:function(t){t.graph().dummyChains=[],g.forEach(t.edges(),function(e){(function(n,i){var r,o,s,u=i.v,c=n.node(u).rank,h=i.w,m=n.node(h).rank,f=i.name,p=n.edge(i),x=p.labelRank;if(m!==c+1){for(n.removeEdge(i),s=0,++c;c<m;++s,++c)p.points=[],o={width:0,height:0,edgeLabel:p,edgeObj:i,rank:c},r=Z.addDummyNode(n,"edge",o,"_d"),c===x&&(o.width=p.width,o.height=p.height,o.dummy="edge-label",o.labelpos=p.labelpos),n.setEdge(u,r,{weight:p.weight},f),s===0&&n.graph().dummyChains.push(r),u=r;n.setEdge(u,h,{weight:p.weight},f)}})(t,e)})},undo:function(t){g.forEach(t.graph().dummyChains,function(e){var n,i=t.node(e),r=i.edgeLabel;for(t.setEdge(i.edgeObj,r);i.dummy;)n=t.successors(e)[0],t.removeNode(e),r.points.push({x:i.x,y:i.y}),i.dummy==="edge-label"&&(r.x=i.x,r.y=i.y,r.width=i.width,r.height=i.height),e=n,i=t.node(e)})}},Mu=function(t){var e={};g.forEach(t.sources(),function n(i){var r=t.node(i);if(g.has(e,i))return r.rank;e[i]=!0;var o=g.min(g.map(t.outEdges(i),function(s){return n(s.w)-t.edge(s).minlen}));return o!==Number.POSITIVE_INFINITY&&o!=null||(o=0),r.rank=o})},Iu=function(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen},tp=gt.Graph,mi=Iu,Gu=function(t){var e,n,i=new tp({directed:!1}),r=t.nodes()[0],o=t.nodeCount();for(i.setNode(r,{});ep(i,t)<o;)e=np(i,t),n=i.hasNode(e.v)?mi(t,e):-mi(t,e),ip(i,t,n);return i};function ep(t,e){return g.forEach(t.nodes(),function n(i){g.forEach(e.nodeEdges(i),function(r){var o=r.v,s=i===o?r.w:o;t.hasNode(s)||mi(e,r)||(t.setNode(s,{}),t.setEdge(i,s,{}),n(s))})}),t.nodeCount()}function np(t,e){return g.minBy(e.edges(),function(n){if(t.hasNode(n.v)!==t.hasNode(n.w))return mi(e,n)})}function ip(t,e,n){g.forEach(t.nodes(),function(i){e.node(i).rank+=n})}var rp=Iu,op=Mu,ap=gt.alg.preorder,sp=gt.alg.postorder,lp=Z.simplify,up=Jt;function Jt(t){t=lp(t),op(t);var e,n=Gu(t);for(co(n),uo(n,t);e=ju(n);)Pu(n,t,e,Lu(n,t,e))}function uo(t,e){var n=sp(t,t.nodes());n=n.slice(0,n.length-1),g.forEach(n,function(i){(function(r,o,s){var u=r.node(s).parent;r.edge(s,u).cutvalue=Fu(r,o,s)})(t,e,i)})}function Fu(t,e,n){var i=t.node(n).parent,r=!0,o=e.edge(n,i),s=0;return o||(r=!1,o=e.edge(i,n)),s=o.weight,g.forEach(e.nodeEdges(n),function(u){var c,h,m=u.v===n,f=m?u.w:u.v;if(f!==i){var p=m===r,x=e.edge(u).weight;if(s+=p?x:-x,c=n,h=f,t.hasEdge(c,h)){var E=t.edge(n,f).cutvalue;s+=p?-E:E}}}),s}function co(t,e){arguments.length<2&&(e=t.nodes()[0]),Ru(t,{},1,e)}function Ru(t,e,n,i,r){var o=n,s=t.node(i);return e[i]=!0,g.forEach(t.neighbors(i),function(u){g.has(e,u)||(n=Ru(t,e,n,u,i))}),s.low=o,s.lim=n++,r?s.parent=r:delete s.parent,n}function ju(t){return g.find(t.edges(),function(e){return t.edge(e).cutvalue<0})}function Lu(t,e,n){var i=n.v,r=n.w;e.hasEdge(i,r)||(i=n.w,r=n.v);var o=t.node(i),s=t.node(r),u=o,c=!1;o.lim>s.lim&&(u=s,c=!0);var h=g.filter(e.edges(),function(m){return c===Sl(t,t.node(m.v),u)&&c!==Sl(t,t.node(m.w),u)});return g.minBy(h,function(m){return rp(e,m)})}function Pu(t,e,n,i){var r=n.v,o=n.w;t.removeEdge(r,o),t.setEdge(i.v,i.w,{}),co(t),uo(t,e),function(s,u){var c=g.find(s.nodes(),function(m){return!u.node(m).parent}),h=ap(s,c);h=h.slice(1),g.forEach(h,function(m){var f=s.node(m).parent,p=u.edge(m,f),x=!1;p||(p=u.edge(f,m),x=!0),u.node(m).rank=u.node(f).rank+(x?p.minlen:-p.minlen)})}(t,e)}function Sl(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}Jt.initLowLimValues=co,Jt.initCutValues=uo,Jt.calcCutValue=Fu,Jt.leaveEdge=ju,Jt.enterEdge=Lu,Jt.exchangeEdges=Pu;var $u=Mu,dp=function(t){switch(t.graph().ranker){case"network-simplex":wl(t);break;case"tight-tree":(function(e){$u(e),Gu(e)})(t);break;case"longest-path":cp(t);break;default:wl(t)}},cp=$u;function wl(t){up(t)}var hp=function(t){var e=function(n){var i={},r=0;function o(s){var u=r;g.forEach(n.children(s),o),i[s]={low:u,lim:r++}}return g.forEach(n.children(),o),i}(t);g.forEach(t.graph().dummyChains,function(n){for(var i=t.node(n),r=i.edgeObj,o=function(f,p,x,E){var v,S,b=[],z=[],k=Math.min(p[x].low,p[E].low),N=Math.max(p[x].lim,p[E].lim);v=x;do v=f.parent(v),b.push(v);while(v&&(p[v].low>k||N>p[v].lim));for(S=v,v=E;(v=f.parent(v))!==S;)z.push(v);return{path:b.concat(z.reverse()),lca:S}}(t,e,r.v,r.w),s=o.path,u=o.lca,c=0,h=s[c],m=!0;n!==r.w;){if(i=t.node(n),m){for(;(h=s[c])!==u&&t.node(h).maxRank<i.rank;)c++;h===u&&(m=!1)}if(!m){for(;c<s.length-1&&t.node(h=s[c+1]).minRank<=i.rank;)c++;h=s[c]}t.setParent(n,h),n=t.successors(n)[0]}})},_l={run:function(t){var e=Z.addDummyNode(t,"root",{},"_root"),n=function(s){var u={};function c(h,m){var f=s.children(h);f&&f.length&&g.forEach(f,function(p){c(p,m+1)}),u[h]=m}return g.forEach(s.children(),function(h){c(h,1)}),u}(t),i=g.max(g.values(n))-1,r=2*i+1;t.graph().nestingRoot=e,g.forEach(t.edges(),function(s){t.edge(s).minlen*=r});var o=function(s){return g.reduce(s.edges(),function(u,c){return u+s.edge(c).weight},0)}(t)+1;g.forEach(t.children(),function(s){Vu(t,e,r,o,i,n,s)}),t.graph().nodeRankFactor=r},cleanup:function(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,g.forEach(t.edges(),function(n){t.edge(n).nestingEdge&&t.removeEdge(n)})}};function Vu(t,e,n,i,r,o,s){var u=t.children(s);if(u.length){var c=Z.addBorderNode(t,"_bt"),h=Z.addBorderNode(t,"_bb"),m=t.node(s);t.setParent(c,s),m.borderTop=c,t.setParent(h,s),m.borderBottom=h,g.forEach(u,function(f){Vu(t,e,n,i,r,o,f);var p=t.node(f),x=p.borderTop?p.borderTop:f,E=p.borderBottom?p.borderBottom:f,v=p.borderTop?i:2*i,S=x!==E?1:r-o[s]+1;t.setEdge(c,x,{weight:v,minlen:S,nestingEdge:!0}),t.setEdge(E,h,{weight:v,minlen:S,nestingEdge:!0})}),t.parent(s)||t.setEdge(e,c,{weight:0,minlen:r+o[s]})}else s!==e&&t.setEdge(e,s,{weight:0,minlen:n})}var mp=function(t){g.forEach(t.children(),function e(n){var i=t.children(n),r=t.node(n);if(i.length&&g.forEach(i,e),g.has(r,"minRank")){r.borderLeft=[],r.borderRight=[];for(var o=r.minRank,s=r.maxRank+1;o<s;++o)zl(t,"borderLeft","_bl",n,r,o),zl(t,"borderRight","_br",n,r,o)}})};function zl(t,e,n,i,r,o){var s={width:0,height:0,rank:o,borderType:e},u=r[e][o-1],c=Z.addDummyNode(t,"border",s,n);r[e][o]=c,t.setParent(c,i),u&&t.setEdge(u,c,{weight:1})}var Cl={adjust:function(t){var e=t.graph().rankdir.toLowerCase();e!=="lr"&&e!=="rl"||Nl(t)},undo:function(t){var e=t.graph().rankdir.toLowerCase();e!=="bt"&&e!=="rl"||function(n){g.forEach(n.nodes(),function(i){Nr(n.node(i))}),g.forEach(n.edges(),function(i){var r=n.edge(i);g.forEach(r.points,Nr),g.has(r,"y")&&Nr(r)})}(t),e!=="lr"&&e!=="rl"||(function(n){g.forEach(n.nodes(),function(i){kr(n.node(i))}),g.forEach(n.edges(),function(i){var r=n.edge(i);g.forEach(r.points,kr),g.has(r,"x")&&kr(r)})}(t),Nl(t))}};function Nl(t){g.forEach(t.nodes(),function(e){kl(t.node(e))}),g.forEach(t.edges(),function(e){kl(t.edge(e))})}function kl(t){var e=t.width;t.width=t.height,t.height=e}function Nr(t){t.y=-t.y}function kr(t){var e=t.x;t.x=t.y,t.y=e}var fp=function(t){var e={},n=g.filter(t.nodes(),function(u){return!t.children(u).length}),i=g.max(g.map(n,function(u){return t.node(u).rank})),r=g.map(g.range(i+1),function(){return[]});function o(u){if(!g.has(e,u)){e[u]=!0;var c=t.node(u);r[c.rank].push(u),g.forEach(t.successors(u),o)}}var s=g.sortBy(n,function(u){return t.node(u).rank});return g.forEach(s,o),r},pp=function(t,e){for(var n=0,i=1;i<e.length;++i)n+=gp(t,e[i-1],e[i]);return n};function gp(t,e,n){for(var i=g.zipObject(n,g.map(n,function(h,m){return m})),r=g.flatten(g.map(e,function(h){return g.sortBy(g.map(t.outEdges(h),function(m){return{pos:i[m.w],weight:t.edge(m).weight}}),"pos")}),!0),o=1;o<n.length;)o<<=1;var s=2*o-1;o-=1;var u=g.map(new Array(s),function(){return 0}),c=0;return g.forEach(r.forEach(function(h){var m=h.pos+o;u[m]+=h.weight;for(var f=0;m>0;)m%2&&(f+=u[m+1]),u[m=m-1>>1]+=h.weight;c+=h.weight*f})),c}var xp=function(t,e){return g.map(e,function(n){var i=t.inEdges(n);if(i.length){var r=g.reduce(i,function(o,s){var u=t.edge(s),c=t.node(s.v);return{sum:o.sum+u.weight*c.order,weight:o.weight+u.weight}},{sum:0,weight:0});return{v:n,barycenter:r.sum/r.weight,weight:r.weight}}return{v:n}})},vp=function(t,e){var n={};return g.forEach(t,function(i,r){var o=n[i.v]={indegree:0,in:[],out:[],vs:[i.v],i:r};g.isUndefined(i.barycenter)||(o.barycenter=i.barycenter,o.weight=i.weight)}),g.forEach(e.edges(),function(i){var r=n[i.v],o=n[i.w];g.isUndefined(r)||g.isUndefined(o)||(o.indegree++,r.out.push(n[i.w]))}),function(i){var r=[];function o(c){return function(h){h.merged||(g.isUndefined(h.barycenter)||g.isUndefined(c.barycenter)||h.barycenter>=c.barycenter)&&function(m,f){var p=0,x=0;m.weight&&(p+=m.barycenter*m.weight,x+=m.weight),f.weight&&(p+=f.barycenter*f.weight,x+=f.weight),m.vs=f.vs.concat(m.vs),m.barycenter=p/x,m.weight=x,m.i=Math.min(f.i,m.i),f.merged=!0}(c,h)}}function s(c){return function(h){h.in.push(c),--h.indegree==0&&i.push(h)}}for(;i.length;){var u=i.pop();r.push(u),g.forEach(u.in.reverse(),o(u)),g.forEach(u.out,s(u))}return g.map(g.filter(r,function(c){return!c.merged}),function(c){return g.pick(c,["vs","i","barycenter","weight"])})}(g.filter(n,function(i){return!i.indegree}))},Ep=function(t,e){var n=Z.partition(t,function(f){return g.has(f,"barycenter")}),i=n.lhs,r=g.sortBy(n.rhs,function(f){return-f.i}),o=[],s=0,u=0,c=0;i.sort((h=!!e,function(f,p){return f.barycenter<p.barycenter?-1:f.barycenter>p.barycenter?1:h?p.i-f.i:f.i-p.i})),c=Ol(o,r,c),g.forEach(i,function(f){c+=f.vs.length,o.push(f.vs),s+=f.barycenter*f.weight,u+=f.weight,c=Ol(o,r,c)});var h,m={vs:g.flatten(o,!0)};return u&&(m.barycenter=s/u,m.weight=u),m};function Ol(t,e,n){for(var i;e.length&&(i=g.last(e)).i<=n;)e.pop(),t.push(i.vs),n++;return n}var yp=function t(e,n,i,r){var o=e.children(n),s=e.node(n),u=s?s.borderLeft:void 0,c=s?s.borderRight:void 0,h={};u&&(o=g.filter(o,function(v){return v!==u&&v!==c}));var m=xp(e,o);g.forEach(m,function(v){if(e.children(v.v).length){var S=t(e,v.v,i,r);h[v.v]=S,g.has(S,"barycenter")&&(b=v,z=S,g.isUndefined(b.barycenter)?(b.barycenter=z.barycenter,b.weight=z.weight):(b.barycenter=(b.barycenter*b.weight+z.barycenter*z.weight)/(b.weight+z.weight),b.weight+=z.weight))}var b,z});var f=vp(m,i);(function(v,S){g.forEach(v,function(b){b.vs=g.flatten(b.vs.map(function(z){return S[z]?S[z].vs:z}),!0)})})(f,h);var p=Ep(f,r);if(u&&(p.vs=g.flatten([u,p.vs,c],!0),e.predecessors(u).length)){var x=e.node(e.predecessors(u)[0]),E=e.node(e.predecessors(c)[0]);g.has(p,"barycenter")||(p.barycenter=0,p.weight=0),p.barycenter=(p.barycenter*p.weight+x.order+E.order)/(p.weight+2),p.weight+=2}return p},bp=gt.Graph,Sp=function(t,e,n){var i=function(o){for(var s;o.hasNode(s=g.uniqueId("_root")););return s}(t),r=new bp({compound:!0}).setGraph({root:i}).setDefaultNodeLabel(function(o){return t.node(o)});return g.forEach(t.nodes(),function(o){var s=t.node(o),u=t.parent(o);(s.rank===e||s.minRank<=e&&e<=s.maxRank)&&(r.setNode(o),r.setParent(o,u||i),g.forEach(t[n](o),function(c){var h=c.v===o?c.w:c.v,m=r.edge(h,o),f=g.isUndefined(m)?0:m.weight;r.setEdge(h,o,{weight:t.edge(c).weight+f})}),g.has(s,"minRank")&&r.setNode(o,{borderLeft:s.borderLeft[e],borderRight:s.borderRight[e]}))}),r},wp=function(t,e,n){var i,r={};g.forEach(n,function(o){for(var s,u,c=t.parent(o);c;){if((s=t.parent(c))?(u=r[s],r[s]=c):(u=i,i=c),u&&u!==c)return void e.setEdge(u,c);c=s}})},_p=gt.Graph,zp=function(t){var e=Z.maxRank(t),n=Tl(t,g.range(1,e+1),"inEdges"),i=Tl(t,g.range(e-1,-1,-1),"outEdges"),r=fp(t);Dl(t,r);for(var o,s=Number.POSITIVE_INFINITY,u=0,c=0;c<4;++u,++c){Cp(u%2?n:i,u%4>=2),r=Z.buildLayerMatrix(t);var h=pp(t,r);h<s&&(c=0,o=g.cloneDeep(r),s=h)}Dl(t,o)};function Tl(t,e,n){return g.map(e,function(i){return Sp(t,i,n)})}function Cp(t,e){var n=new _p;g.forEach(t,function(i){var r=i.graph().root,o=yp(i,r,n,e);g.forEach(o.vs,function(s,u){i.node(s).order=u}),wp(i,n,o.vs)})}function Dl(t,e){g.forEach(e,function(n){g.forEach(n,function(i,r){t.node(i).order=r})})}var Np=gt.Graph,kp=function(t){var e,n=Z.buildLayerMatrix(t),i=g.merge(Op(t,n),Tp(t,n)),r={};g.forEach(["u","d"],function(s){e=s==="u"?n:g.values(n).reverse(),g.forEach(["l","r"],function(u){u==="r"&&(e=g.map(e,function(f){return g.values(f).reverse()}));var c=(s==="u"?t.predecessors:t.successors).bind(t),h=Ap(t,e,i,c),m=Bp(t,e,h.root,h.align,u==="r");u==="r"&&(m=g.mapValues(m,function(f){return-f})),r[s+u]=m})});var o=Mp(t,r);return Ip(r,o),Gp(r,t.graph().align)};function Op(t,e){var n={};return g.reduce(e,function(i,r){var o=0,s=0,u=i.length,c=g.last(r);return g.forEach(r,function(h,m){var f=function(x,E){if(x.node(E).dummy)return g.find(x.predecessors(E),function(v){return x.node(v).dummy})}(t,h),p=f?t.node(f).order:u;(f||h===c)&&(g.forEach(r.slice(s,m+1),function(x){g.forEach(t.predecessors(x),function(E){var v=t.node(E),S=v.order;!(S<o||p<S)||v.dummy&&t.node(x).dummy||qu(n,E,x)})}),s=m+1,o=p)}),r}),n}function Tp(t,e){var n={};function i(r,o,s,u,c){var h;g.forEach(g.range(o,s),function(m){h=r[m],t.node(h).dummy&&g.forEach(t.predecessors(h),function(f){var p=t.node(f);p.dummy&&(p.order<u||p.order>c)&&qu(n,f,h)})})}return g.reduce(e,function(r,o){var s,u=-1,c=0;return g.forEach(o,function(h,m){if(t.node(h).dummy==="border"){var f=t.predecessors(h);f.length&&(s=t.node(f[0]).order,i(o,c,m,u,s),c=m,u=s)}i(o,c,o.length,s,r.length)}),o}),n}function qu(t,e,n){if(e>n){var i=e;e=n,n=i}var r=t[e];r||(t[e]=r={}),r[n]=!0}function Dp(t,e,n){if(e>n){var i=e;e=n,n=i}return g.has(t[e],n)}function Ap(t,e,n,i){var r={},o={},s={};return g.forEach(e,function(u){g.forEach(u,function(c,h){r[c]=c,o[c]=c,s[c]=h})}),g.forEach(e,function(u){var c=-1;g.forEach(u,function(h){var m=i(h);if(m.length)for(var f=((m=g.sortBy(m,function(v){return s[v]})).length-1)/2,p=Math.floor(f),x=Math.ceil(f);p<=x;++p){var E=m[p];o[h]===h&&c<s[E]&&!Dp(n,h,E)&&(o[E]=h,o[h]=r[h]=r[E],c=s[E])}})}),{root:r,align:o}}function Bp(t,e,n,i,r){var o={},s=function(h,m,f,p){var x=new Np,E=h.graph(),v=function(S,b,z){return function(k,N,G){var M,q=k.node(N),dt=k.node(G),ot=0;if(ot+=q.width/2,g.has(q,"labelpos"))switch(q.labelpos.toLowerCase()){case"l":M=-q.width/2;break;case"r":M=q.width/2}if(M&&(ot+=z?M:-M),M=0,ot+=(q.dummy?b:S)/2,ot+=(dt.dummy?b:S)/2,ot+=dt.width/2,g.has(dt,"labelpos"))switch(dt.labelpos.toLowerCase()){case"l":M=dt.width/2;break;case"r":M=-dt.width/2}return M&&(ot+=z?M:-M),M=0,ot}}(E.nodesep,E.edgesep,p);return g.forEach(m,function(S){var b;g.forEach(S,function(z){var k=f[z];if(x.setNode(k),b){var N=f[b],G=x.edge(N,k);x.setEdge(N,k,Math.max(v(h,z,b),G||0))}b=z})}),x}(t,e,n,r),u=r?"borderLeft":"borderRight";function c(h,m){for(var f=s.nodes(),p=f.pop(),x={};p;)x[p]?h(p):(x[p]=!0,f.push(p),f=f.concat(m(p))),p=f.pop()}return c(function(h){o[h]=s.inEdges(h).reduce(function(m,f){return Math.max(m,o[f.v]+s.edge(f))},0)},s.predecessors.bind(s)),c(function(h){var m=s.outEdges(h).reduce(function(p,x){return Math.min(p,o[x.w]-s.edge(x))},Number.POSITIVE_INFINITY),f=t.node(h);m!==Number.POSITIVE_INFINITY&&f.borderType!==u&&(o[h]=Math.max(o[h],m))},s.successors.bind(s)),g.forEach(i,function(h){o[h]=o[n[h]]}),o}function Mp(t,e){return g.minBy(g.values(e),function(n){var i=Number.NEGATIVE_INFINITY,r=Number.POSITIVE_INFINITY;return g.forIn(n,function(o,s){var u=function(c,h){return c.node(h).width}(t,s)/2;i=Math.max(o+u,i),r=Math.min(o-u,r)}),i-r})}function Ip(t,e){var n=g.values(e),i=g.min(n),r=g.max(n);g.forEach(["u","d"],function(o){g.forEach(["l","r"],function(s){var u,c=o+s,h=t[c];if(h!==e){var m=g.values(h);(u=s==="l"?i-g.min(m):r-g.max(m))&&(t[c]=g.mapValues(h,function(f){return f+u}))}})})}function Gp(t,e){return g.mapValues(t.ul,function(n,i){if(e)return t[e.toLowerCase()][i];var r=g.sortBy(g.map(t,i));return(r[1]+r[2])/2})}var Fp=kp,Rp=function(t){(function(e){var n=Z.buildLayerMatrix(e),i=e.graph().ranksep,r=0;g.forEach(n,function(o){var s=g.max(g.map(o,function(u){return e.node(u).height}));g.forEach(o,function(u){e.node(u).y=r+s/2}),r+=s+i})})(t=Z.asNonCompoundGraph(t)),g.forEach(Fp(t),function(e,n){t.node(n).x=e})},jp=Z.normalizeRanks,Lp=Z.removeEmptyRanks,Lt=Z,Pp=gt.Graph,$p=function(t,e){var n=e&&e.debugTiming?Lt.time:Lt.notime;n("layout",function(){var i=n(" buildLayoutGraph",function(){return function(r){var o=new Pp({multigraph:!0,compound:!0}),s=Tr(r.graph());return o.setGraph(g.merge({},qp,Or(s,Vp),g.pick(s,Hp))),g.forEach(r.nodes(),function(u){var c=Tr(r.node(u));o.setNode(u,g.defaults(Or(c,Up),Zp)),o.setParent(u,r.parent(u))}),g.forEach(r.edges(),function(u){var c=Tr(r.edge(u));o.setEdge(u,g.merge({},Yp,Or(c,Xp),g.pick(c,Wp)))}),o}(t)});n(" runLayout",function(){(function(r,o){o(" makeSpaceForEdgeLabels",function(){(function(s){var u=s.graph();u.ranksep/=2,g.forEach(s.edges(),function(c){var h=s.edge(c);h.minlen*=2,h.labelpos.toLowerCase()!=="c"&&(u.rankdir==="TB"||u.rankdir==="BT"?h.width+=h.labeloffset:h.height+=h.labeloffset)})})(r)}),o(" removeSelfEdges",function(){(function(s){g.forEach(s.edges(),function(u){if(u.v===u.w){var c=s.node(u.v);c.selfEdges||(c.selfEdges=[]),c.selfEdges.push({e:u,label:s.edge(u)}),s.removeEdge(u)}})})(r)}),o(" acyclic",function(){xl.run(r)}),o(" nestingGraph.run",function(){_l.run(r)}),o(" rank",function(){dp(Lt.asNonCompoundGraph(r))}),o(" injectEdgeLabelProxies",function(){(function(s){g.forEach(s.edges(),function(u){var c=s.edge(u);if(c.width&&c.height){var h=s.node(u.v),m={rank:(s.node(u.w).rank-h.rank)/2+h.rank,e:u};Lt.addDummyNode(s,"edge-proxy",m,"_ep")}})})(r)}),o(" removeEmptyRanks",function(){Lp(r)}),o(" nestingGraph.cleanup",function(){_l.cleanup(r)}),o(" normalizeRanks",function(){jp(r)}),o(" assignRankMinMax",function(){(function(s){var u=0;g.forEach(s.nodes(),function(c){var h=s.node(c);h.borderTop&&(h.minRank=s.node(h.borderTop).rank,h.maxRank=s.node(h.borderBottom).rank,u=g.max(u,h.maxRank))}),s.graph().maxRank=u})(r)}),o(" removeEdgeLabelProxies",function(){(function(s){g.forEach(s.nodes(),function(u){var c=s.node(u);c.dummy==="edge-proxy"&&(s.edge(c.e).labelRank=c.rank,s.removeNode(u))})})(r)}),o(" normalize.run",function(){bl.run(r)}),o(" parentDummyChains",function(){hp(r)}),o(" addBorderSegments",function(){mp(r)}),o(" order",function(){zp(r)}),o(" insertSelfEdges",function(){(function(s){var u=Lt.buildLayerMatrix(s);g.forEach(u,function(c){var h=0;g.forEach(c,function(m,f){var p=s.node(m);p.order=f+h,g.forEach(p.selfEdges,function(x){Lt.addDummyNode(s,"selfedge",{width:x.label.width,height:x.label.height,rank:p.rank,order:f+ ++h,e:x.e,label:x.label},"_se")}),delete p.selfEdges})})})(r)}),o(" adjustCoordinateSystem",function(){Cl.adjust(r)}),o(" position",function(){Rp(r)}),o(" positionSelfEdges",function(){(function(s){g.forEach(s.nodes(),function(u){var c=s.node(u);if(c.dummy==="selfedge"){var h=s.node(c.e.v),m=h.x+h.width/2,f=h.y,p=c.x-m,x=h.height/2;s.setEdge(c.e,c.label),s.removeNode(u),c.label.points=[{x:m+2*p/3,y:f-x},{x:m+5*p/6,y:f-x},{x:m+p,y:f},{x:m+5*p/6,y:f+x},{x:m+2*p/3,y:f+x}],c.label.x=c.x,c.label.y=c.y}})})(r)}),o(" removeBorderNodes",function(){(function(s){g.forEach(s.nodes(),function(u){if(s.children(u).length){var c=s.node(u),h=s.node(c.borderTop),m=s.node(c.borderBottom),f=s.node(g.last(c.borderLeft)),p=s.node(g.last(c.borderRight));c.width=Math.abs(p.x-f.x),c.height=Math.abs(m.y-h.y),c.x=f.x+c.width/2,c.y=h.y+c.height/2}}),g.forEach(s.nodes(),function(u){s.node(u).dummy==="border"&&s.removeNode(u)})})(r)}),o(" normalize.undo",function(){bl.undo(r)}),o(" fixupEdgeLabelCoords",function(){(function(s){g.forEach(s.edges(),function(u){var c=s.edge(u);if(g.has(c,"x"))switch(c.labelpos!=="l"&&c.labelpos!=="r"||(c.width-=c.labeloffset),c.labelpos){case"l":c.x-=c.width/2+c.labeloffset;break;case"r":c.x+=c.width/2+c.labeloffset}})})(r)}),o(" undoCoordinateSystem",function(){Cl.undo(r)}),o(" translateGraph",function(){(function(s){var u=Number.POSITIVE_INFINITY,c=0,h=Number.POSITIVE_INFINITY,m=0,f=s.graph(),p=f.marginx||0,x=f.marginy||0;function E(v){var S=v.x,b=v.y,z=v.width,k=v.height;u=Math.min(u,S-z/2),c=Math.max(c,S+z/2),h=Math.min(h,b-k/2),m=Math.max(m,b+k/2)}g.forEach(s.nodes(),function(v){E(s.node(v))}),g.forEach(s.edges(),function(v){var S=s.edge(v);g.has(S,"x")&&E(S)}),u-=p,h-=x,g.forEach(s.nodes(),function(v){var S=s.node(v);S.x-=u,S.y-=h}),g.forEach(s.edges(),function(v){var S=s.edge(v);g.forEach(S.points,function(b){b.x-=u,b.y-=h}),g.has(S,"x")&&(S.x-=u),g.has(S,"y")&&(S.y-=h)}),f.width=c-u+p,f.height=m-h+x})(r)}),o(" assignNodeIntersects",function(){(function(s){g.forEach(s.edges(),function(u){var c,h,m=s.edge(u),f=s.node(u.v),p=s.node(u.w);m.points?(c=m.points[0],h=m.points[m.points.length-1]):(m.points=[],c=p,h=f),m.points.unshift(Lt.intersectRect(f,c)),m.points.push(Lt.intersectRect(p,h))})})(r)}),o(" reversePoints",function(){(function(s){g.forEach(s.edges(),function(u){var c=s.edge(u);c.reversed&&c.points.reverse()})})(r)}),o(" acyclic.undo",function(){xl.undo(r)})})(i,n)}),n(" updateInputGraph",function(){(function(r,o){g.forEach(r.nodes(),function(s){var u=r.node(s),c=o.node(s);u&&(u.x=c.x,u.y=c.y,o.children(s).length&&(u.width=c.width,u.height=c.height))}),g.forEach(r.edges(),function(s){var u=r.edge(s),c=o.edge(s);u.points=c.points,g.has(c,"x")&&(u.x=c.x,u.y=c.y)}),r.graph().width=o.graph().width,r.graph().height=o.graph().height})(t,i)})})},Vp=["nodesep","edgesep","ranksep","marginx","marginy"],qp={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},Hp=["acyclicer","ranker","rankdir","align"],Up=["width","height"],Zp={width:0,height:0},Xp=["minlen","weight","width","height","labeloffset"],Yp={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},Wp=["labelpos"];function Or(t,e){return g.mapValues(g.pick(t,e),Number)}function Tr(t){var e={};return g.forEach(t,function(n,i){e[i.toLowerCase()]=n}),e}var Qp=gt.Graph,Hu={graphlib:gt,layout:$p,debug:{debugOrdering:function(t){var e=Z.buildLayerMatrix(t),n=new Qp({compound:!0,multigraph:!0}).setGraph({});return g.forEach(t.nodes(),function(i){n.setNode(i,{label:i}),n.setParent(i,"layer"+t.node(i).rank)}),g.forEach(t.edges(),function(i){n.setEdge(i.v,i.w,{},i.name)}),g.forEach(e,function(i,r){var o="layer"+r;n.setNode(o,{rank:"same"}),g.reduce(i,function(s,u){return n.setEdge(s,u,{style:"invis"}),u})}),n}},util:{time:Z.time,notime:Z.notime},version:"0.8.5"},Kp=Hu.graphlib,Jp=Hu.layout,Lr=class{constructor(e){this.cardinality=1,this.include=_e.UNSPECIFIED,this.isGroupNode=!1,this.parentNode=null,this.type=J.NODE,this.name=e.name,this.attr=e.attr||{},this.inputs=e.inputs,this.path=e.path||[],this.width=e.width,this.height=e.height}},Pr=class{constructor(){this.nodes={},this.edges=[]}};function tg(t){let e=new Pr;return t.nodes.map(n=>new Lr(n)).forEach(n=>{e.nodes[n.name]=n,n.inputs.forEach(i=>{(function(r,o,s){s.name!==o.name&&r.edges.push(Object.assign(Object.assign({},s.attr),{v:s.name,w:o.name}))})(e,n,i)})}),e}var $r=class{constructor(e,n={}){this.attr=null,this.bridgeGraph=null,this.cardinality=0,this.depth=1,this.include=_e.UNSPECIFIED,this.isGroupNode=!0,this.parentNode=null,this.type=J.META,this.name=e,this.metaGraph=ho(e,tn.META,n)}getFirstChild(){return this.metaGraph.node(this.metaGraph.nodes()[0])}getChildren(){return this.metaGraph.nodes().map(e=>this.metaGraph.node(e))}getRootNode(){let e=this.name.split("/"),n=this.name+"/("+e[e.length-1]+")";return this.metaGraph.node(n)}leaves(){let e,n=[],i=[this];for(;i.length;){let r=i.shift();r.isGroupNode?(e=r.metaGraph,e.nodes().forEach(o=>i.push(e.node(o)))):n.push(r.name)}return n}},Vr=class{constructor(e,n){this.v=e,this.w=n,this.baseEdgeList=[],this.inbound=null,this.name=null}addBaseEdge(e,n){this.baseEdgeList.push(e)}};function Uu(t,e={}){return new $r(t,e)}function Zu(t,e){return new Vr(t,e)}function ho(t,e,n){let i=n||{},r=new Kp.Graph(i);return r.setGraph({name:t,rankdir:i.rankdir||"BT",type:e}),r}function Xu(t){return`\u25EC${t}\u25EC`}var Al=Xu("ROOT"),eg=Xu("BRIDGE_GRAPH"),Ee={graph:{meta:{nodeSep:50,rankSep:50,edgeSep:5,align:void 0}},subScene:{meta:{paddingTop:20,paddingBottom:20,paddingLeft:20,paddingRight:20,labelHeight:20}},nodeSize:{meta:{width:100,maxLabelWidth:0,height:20},node:{width:80,height:20,labelOffset:10,maxLabelWidth:40},bridge:{width:5,height:5,radius:2,labelOffset:0}}},qr=class{constructor(e={}){this.graphOptions=e,this.index={},this.graphOptions.compound=!0,this.root=Uu(Al,this.graphOptions),this.index[Al]=this.root}getNodeMap(){return this.index}node(e){return this.index[e]}setNode(e,n){this.index[e]=n}getBridgeGraph(e){let n=this.index[e];if(!n)throw Error("Could not find node in hierarchy: "+e);if(!("metaGraph"in n))return null;let i=n;if(i.bridgeGraph)return i.bridgeGraph;let r=ho(eg,tn.BRIDGE,this.graphOptions);if(i.bridgeGraph=r,!n.parentNode||!("metaGraph"in n.parentNode))return r;let o=n.parentNode;return[o.metaGraph,this.getBridgeGraph(o.name)].forEach(s=>{s.edges().filter(u=>u.v===e||u.w===e).forEach(u=>{let c=u.w===e;s.edge(u).baseEdgeList.forEach(h=>{let[m,f]=c?[h.w,u.v]:[h.v,u.w],p=this.getChildName(e,m),x={v:c?f:p,w:c?p:f},E=r.edge(x);E||(E=Zu(x.v,x.w),E.inbound=c,r.setEdge(x.v,x.w,E)),E.addBaseEdge(h,this)})})}),r}getChildName(e,n){let i=this.index[n];for(;i;){if(i.parentNode&&i.parentNode.name===e)return i.name;i=i.parentNode}throw Error("Could not find immediate child for descendant: "+n)}getPredecessors(e){let n=this.index[e];if(!n)throw Error("Could not find node with name: "+e);return this.getOneWayEdges(n,!0)}getSuccessors(e){let n=this.index[e];if(!n)throw Error("Could not find node with name: "+e);return this.getOneWayEdges(n,!1)}getOneWayEdges(e,n){let i=[];if(!e.parentNode||!e.parentNode.isGroupNode)return i;let r=e.parentNode,o=r.metaGraph,s=this.getBridgeGraph(r.name);return Bl(o,e,n,i),Bl(s,e,n,i),i}};function ng(t,e){let n=new qr({rankdir:e.rankDirection});return function(i,r){Object.keys(r.nodes).forEach(o=>{let s=r.nodes[o],u=s.path,c=i.root;c.depth=Math.max(u.length,c.depth);for(let h=0;h<u.length&&(c.depth=Math.max(c.depth,u.length-h),c.cardinality+=s.cardinality,h!==u.length-1);h++){let m=u[h],f=i.node(m);f||(f=Uu(m,i.graphOptions),f.path=s.path.slice(0,h+1),f.parentNode=c,i.setNode(m,f),c.metaGraph.setNode(m,f)),c=f}i.setNode(s.name,s),s.parentNode=c,c.metaGraph.setNode(s.name,s)})}(n,t),function(i,r){let o=i.getNodeMap(),s=[],u=[],c=(h,m)=>{let f=0;for(;h;)m[f++]=h.name,h=h.parentNode;return f-1};r.edges.forEach(h=>{s=[],u=[];let m=c(r.nodes[h.v],s),f=c(r.nodes[h.w],u);for(;s[m]===u[f];)if(m--,f--,m<0||f<0)throw Error("No difference found between ancestor paths.");let p=o[s[m+1]],x=s[m],E=u[f],v=p.metaGraph.edge(x,E);v||(v=Zu(x,E),p.metaGraph.setEdge(x,E,v)),v.addBaseEdge(h,i)})}(n,t),n}function Bl(t,e,n,i){(n?t.inEdges(e.name):t.outEdges(e.name)).forEach(r=>{let o=t.edge(r);i.push(o)})}var Hr=class{constructor(e){this.hierarchy=e,this.index={},this.hasSubHierarchy={},this.root=new pi(this.hierarchy.root,this.hierarchy.graphOptions),this.index[e.root.name]=this.root,this.buildSubHierarchy(e.root.name),this.root.expanded=!0}getRenderInfoNodes(){return Object.values(this.index)}getSubHierarchy(){return this.hasSubHierarchy}buildSubHierarchy(e){if(e in this.hasSubHierarchy)return;this.hasSubHierarchy[e]=!0;let n=this.index[e];if(n.node.type!==J.META)return;let i=n,r=i.node.metaGraph,o=i.coreGraph;r.nodes().forEach(m=>{let f=this.getOrCreateRenderNodeByName(m);o.setNode(m,f)}),r.edges().forEach(m=>{let f=r.edge(m),p=new fi(f);o.setEdge(m.v,m.w,p)});let s=i.node.parentNode;if(!s)return;let u=this.getRenderNodeByName(s.name),c=(m,...f)=>f.concat([m?"IN":"OUT"]).join("~~"),h=this.hierarchy.getBridgeGraph(e);h.edges().forEach(m=>{r.node(m.w)?m.v:m.w}),h.edges().forEach(m=>{let f=h.edge(m),p=!!r.node(m.w),[x,E]=p?[m.w,m.v]:[m.v,m.w],v=G=>{let M=p?{v:G,w:e}:{v:e,w:G};return u.coreGraph.edge(M)},S=v(E);S||(S=v(c(p,E,s.name)));let b=c(p,e),z=c(p,E,e),k=o.node(z);if(!k){let G=o.node(b);if(!G){let q={name:b,type:J.BRIDGE,isGroupNode:!1,cardinality:0,parentNode:null,include:_e.UNSPECIFIED,inbound:p,attr:{}};G=new we(q),this.index[b]=G,o.setNode(b,G)}let M={name:z,type:J.BRIDGE,isGroupNode:!1,cardinality:1,parentNode:null,include:_e.UNSPECIFIED,inbound:p,attr:{}};k=new we(M),this.index[z]=k,o.setNode(z,k),o.setParent(z,b),G.node.cardinality++}let N=new fi(f);N.adjoiningMetaEdge=S,p?o.setEdge(z,x,N):o.setEdge(x,z,N)}),[!0,!1].forEach(m=>{let f=c(m,e);o.node(f)&&o.nodes().forEach(p=>{o.node(p).node.type!==J.BRIDGE&&(m?o.predecessors(p).length:o.successors(p).length)})})}getOrCreateRenderNodeByName(e){if(!e)return null;if(e in this.index)return this.index[e];let n=this.getNodeByName(e);return n?(this.index[e]=n.isGroupNode?new pi(n,this.hierarchy.graphOptions):new we(n),this.index[e]):null}getRenderNodeByName(e){return this.index[e]}getNodeByName(e){return this.hierarchy.node(e)}},we=class{constructor(e){this.node=e,this.expanded=!1,this.x=0,this.y=0,this.coreBox={width:0,height:0},this.outboxWidth=0,this.labelOffset=0,this.radius=0,this.labelHeight=0,this.paddingTop=0,this.paddingLeft=0,this.paddingRight=0,this.paddingBottom=0,this.width=e.width||0,this.height=e.height||0,this.displayName=e.name,this.attr=e.attr}},fi=class{constructor(e){this.metaEdge=e,this.adjoiningMetaEdge=null,this.weight=1,this.points=[],this.startMarkerId=null,this.endMarkerId=null}},pi=class extends we{constructor(e,n){super(e);let i=e.metaGraph.graph();n.compound=!0,this.coreGraph=ho(i.name,tn.CORE,n)}};function Yu(t,e=Ee){t.node.isGroupNode&&function(n,i){n.coreGraph.nodes().map(r=>n.coreGraph.node(r)).forEach(r=>{let{height:o,width:s}=r;switch(r.node.type){case J.NODE:Object.assign(r,i.nodeSize.node),r.height=o||i.nodeSize.node.height,r.width=s||i.nodeSize.node.width;break;case J.BRIDGE:Object.assign(r,i.nodeSize.bridge);break;case J.META:r.expanded?Yu(r,i):(Object.assign(r,i.nodeSize.meta),r.height=i.nodeSize.meta.height,r.width=i.nodeSize.meta.width);break;default:throw Error("Unrecognized node type: "+r.node.type)}r.expanded||function(u){u.coreBox.width=u.width,u.coreBox.height=u.height;let c=`${u.displayName}`.length,h=3;u.width=Math.max(u.coreBox.width,c*h)}(r)})}(t,e),t.node.type===J.META&&function(n,i){let r=i.subScene.meta;Object.assign(n,r),Object.assign(n.coreBox,function(u,c){Object.assign(u.graph(),{nodesep:c.nodeSep,ranksep:c.rankSep,edgesep:c.edgeSep,align:c.align});let h=[];if(u.nodes().forEach(E=>{u.node(E).node.type!==J.BRIDGE&&h.push(E)}),!h.length)return{width:0,height:0};Jp(u);let m=1/0,f=1/0,p=-1/0,x=-1/0;return h.forEach(E=>{let v=u.node(E),S=.5*v.width,b=v.x-S,z=v.x+S;m=b<m?b:m,p=z>p?z:p;let k=.5*v.height,N=v.y-k,G=v.y+k;f=N<f?N:f,x=G>x?G:x}),u.edges().forEach(E=>{let v=u.edge(E),S=u.node(v.metaEdge.v),b=u.node(v.metaEdge.w);if(v.points.length===3&&function(N){let G=Ml(N[0],N[1]);for(let M=1;M<N.length-1;M++){let q=Ml(N[M],N[M+1]);if(Math.abs(q-G)>1)return!1;G=q}return!0}(v.points)){if(S!=null){let N=S.expanded?S.x:Ur(S);v.points[0].x=N}if(b!=null){let N=b.expanded?b.x:Ur(b);v.points[2].x=N}v.points=[v.points[0],v.points[1]]}let z=v.points[v.points.length-2];b!=null&&(v.points[v.points.length-1]=Il(z,b));let k=v.points[1];S!=null&&(v.points[0]=Il(k,S)),v.points.forEach(N=>{m=N.x<m?N.x:m,p=N.x>p?N.x:p,f=N.y<f?N.y:f,x=N.y>x?N.y:x})}),u.nodes().forEach(E=>{let v=u.node(E);v.x-=m,v.y-=f}),u.edges().forEach(E=>{u.edge(E).points.forEach(v=>{v.x-=m,v.y-=f})}),{width:p-m,height:x-f}}(n.coreGraph,i.graph.meta));let o=0;n.coreGraph.nodeCount()>0&&o++;let s=o<=1?0:o;n.coreBox.width+=s+s,n.coreBox.height=r.labelHeight+n.coreBox.height,n.width=n.coreBox.width+r.paddingLeft+r.paddingRight,n.height=n.paddingTop+n.coreBox.height+n.paddingBottom}(t,e)}function Ml(t,e){let n=e.x-t.x,i=e.y-t.y;return 180*Math.atan(i/n)/Math.PI}function Ur(t){return t.expanded?t.x:t.x-t.width/2+0+t.coreBox.width/2}function Il(t,e){let n=e.expanded?e.x:Ur(e),i=e.y,r=t.x-n,o=t.y-i,s,u,c=e.expanded?e.width:e.coreBox.width,h=e.expanded?e.height:e.coreBox.height;return Math.abs(o)*c/2>Math.abs(r)*h/2?(o<0&&(h=-h),s=o===0?0:h/2*r/o,u=h/2):(r<0&&(c=-c),s=c/2,u=r===0?0:c/2*o/r),{x:n+s,y:i+u}}function Wu(t,e,n){let i=t.nodes.filter((u,c,h)=>h.findIndex(m=>m.id===u.id)!==c).map(u=>u.id);if(i.length)throw new Error(`Duplicated ids found: ${i.join(", ")}`);let r=function(u){let c={nodes:[]},h=Object.keys(u.compound||{}),m=new Map,f=(x,E=[])=>{let v=E.length===0;if(m.has(x))return m.get(x);for(let S=0;S<h.length;S++){let b=h[S];if(u.compound&&u.compound[b].indexOf(x)!==-1)return E.unshift(b),f(b,E)}return v&&m.set(x,E),E},p=x=>u.edges.filter(E=>E.w===x).map(E=>({name:E.v}));return u.nodes.forEach(x=>{let E=x.id,v=[...f(E),E],S=p(E);c.nodes.push({name:E,path:v,inputs:S,width:x.width,height:x.height,attr:Object.assign({},x)})}),c}(t),o=function(u,c){let h=(f,p)=>{for(let x of p.values())if(x.includes(f))return!0;return!1},m=(f,p=[])=>{if(Object.keys(f).length===0)return[...new Set(p)];let x=new Map(Object.keys(f).map(v=>[v,f[v]])),E={};for(let[v,S]of x)h(v,x)?E[v]=S:p=p.concat(v,S);return m(E,p)};return m(u).filter(f=>c.includes(f))}(t.compound||{},e?.expanded||[]),{renderInfo:s}=function(u,c="LR"){let h=ng(tg(u),{rankDirection:c}),m=function(f){return new Hr(f)}(h);return{hierarchy:h,renderInfo:m}}(r,e&&e.rankDirection?e.rankDirection:"LR");return function(u,c){c.forEach(h=>{let m=u.getRenderInfoNodes().find(x=>x.displayName===h),f=m&&m.node&&m.node.name||"",p=u.getRenderNodeByName(f);if(!p)throw new Error(`No nodes found: ${f}`);p.expanded=!0,u.buildSubHierarchy(f)})}(s,o),Yu(s.root,function(u={}){var c,h,m,f;let p=((c=u?.graph)===null||c===void 0?void 0:c.meta)||{},x=((h=u?.subScene)===null||h===void 0?void 0:h.meta)||{},E=((m=u?.nodeSize)===null||m===void 0?void 0:m.meta)||{},v=((f=u?.nodeSize)===null||f===void 0?void 0:f.node)||{},S=Ee.nodeSize.bridge;return{graph:{meta:Object.assign(Ee.graph.meta,p)},subScene:{meta:Object.assign(Ee.subScene.meta,x)},nodeSize:{meta:Object.assign(Ee.nodeSize.meta,E),node:Object.assign(Ee.nodeSize.node,v),bridge:S}}}(n)),Qu(s.root)}function Qu(t){let e=t.coreGraph.nodes().map(i=>t.coreGraph.node(i));return Object.assign(Object.assign({},Gl(t)),{expanded:t.expanded,nodes:t.expanded?(n=e,n.map(i=>i.node.type===J.META?Qu(i):Gl(i))):[],edges:t.expanded?ig(t):[]});var n}function Gl(t){return{id:t.node.name,name:t.node.name,type:t.node.type,attr:t.attr,parentNodeName:t.node.parentNode?t.node.parentNode.name:null,coreBox:Object.assign({},t.coreBox),x:t.x,y:t.y,width:t.width,height:t.height,radius:t.radius,labelHeight:t.labelHeight,labelOffset:t.labelOffset,outboxWidth:t.outboxWidth,paddingLeft:t.paddingLeft,paddingTop:t.paddingTop,paddingRight:t.paddingRight,paddingBottom:t.paddingBottom}}function ig(t){return t.coreGraph.edges().map(e=>({renderInfoEdge:t.coreGraph.edge(e),edge:e})).filter(({renderInfoEdge:e})=>e.metaEdge).map(({edge:e,renderInfoEdge:n})=>{let i=function(r,o){let s=o.points.map(u=>Object.assign({},u));if(o.adjoiningMetaEdge){let u=o.adjoiningMetaEdge.points,c=o.metaEdge.inbound,h=c?u[u.length-1]:u[0],m=s[c?0:s.length-1],f=r.x-r.width/2,p=r.y-r.height/2,x=h.x-f,E=h.y-p,v=-r.paddingLeft,S=-(r.paddingTop+r.labelHeight);m.x=x+v,m.y=E+S}return s}(t,n);return{adjoiningEdge:n.adjoiningMetaEdge?{w:n.adjoiningMetaEdge.metaEdge.w,v:n.adjoiningMetaEdge.metaEdge.v}:null,inbound:n.metaEdge.inbound,w:e.w,v:e.v,points:i,weight:n.weight,baseEdgeList:n.metaEdge.baseEdgeList}})}var rg=["nz-graph-defs",""],og=["nz-graph-edge",""],Ku=t=>({$implicit:t});function ag(t,e){if(t&1&&De(0,0),t&2){let n=Y();P("ngTemplateOutlet",n.customTemplate)("ngTemplateOutletContext",Be(2,Ku,n.edge))}}function sg(t,e){if(t&1&&(Q(),d(0,"text",2)(1,"textPath",3),a(2),l()()),t&2){let n=Y(2);I(),Et("href","#"+n.id),I(),Ui(n.edge.label)}}function lg(t,e){if(t&1&&(Q(),d(0,"g"),U(1,"path",1),Mt(2,sg,3,2,":svg:text",2),l()),t&2){let n=Y();I(),Et("marker-end","url(#edge-end-arrow)"),I(),qt(n.edge.label?2:-1)}}var ug=["nz-graph-node",""];function dg(t,e){if(t&1&&(Q(),De(0,0)),t&2){let n=Y();P("ngTemplateOutlet",n.customTemplate)("ngTemplateOutletContext",Be(2,Ku,n.node))}}function cg(t,e){if(t&1&&(Q(),U(0,"rect",1),d(1,"text",2),a(2),l()),t&2){let n=Y();Et("width",n.node.width)("height",n.node.height),I(2),Ui(n.node.id||n.node.name)}}var hg=["*"];function mg(t,e){return this.edgeTrackByFun(e)}var fg=(t,e)=>e.name,pg=t=>({renderNode:t,type:"root"}),gg=t=>({renderNode:t,type:"sub"});function xg(t,e){if(t&1&&(Q(),U(0,"g",6)),t&2){let n=e.$implicit,i=Y(2);P("edge",n)("edgeType",i.nzGraphLayoutConfig==null||i.nzGraphLayoutConfig.defaultEdge==null?null:i.nzGraphLayoutConfig.defaultEdge.type)("customTemplate",i.customGraphEdgeTemplate)}}function vg(t,e){if(t&1&&(Q(),U(0,"g",8)),t&2){let n=Y().$implicit,i=Y(2);P("node",n)("customTemplate",i.nodeTemplate)}}function Eg(t,e){if(t&1&&(Q(),U(0,"g",8)),t&2){let n=Y().$implicit,i=Y(2);P("node",n)("customTemplate",i.groupNodeTemplate)}}function yg(t,e){if(t&1&&(Q(),De(0,3)),t&2){let n=Y().$implicit;Y(2);let i=Hi(6);P("ngTemplateOutlet",i)("ngTemplateOutletContext",Be(2,gg,n))}}function bg(t,e){if(t&1&&Mt(0,vg,1,2,":svg:g",8)(1,Eg,1,2,":svg:g",8)(2,yg,1,4,":svg:ng-container",3),t&2){let n=e.$implicit;qt(n.type===1?0:-1),I(),qt(n.type===0?1:-1),I(),qt(n.expanded?2:-1)}}function Sg(t,e){if(t&1&&(Q(),d(0,"g")(1,"g",4)(2,"g",5),Li(3,xg,1,3,":svg:g",6,mg,!0),l(),d(5,"g",7),Li(6,bg,3,3,null,null,fg),l()()()),t&2){let n=e.renderNode,i=e.type,r=Y();Et("transform",i==="sub"?r.subGraphTransform(n):null),I(),Et("transform",r.coreTransform(n)),I(2),Pi(r.$asNzGraphEdges(n.edges)),I(3),Pi(r.typedNodes(n.nodes))}}var Ju=function(t){return t.LINE="line",t.CURVE="curve",t}(Ju||{});function wg(){return t=>t}var ke={graph:{meta:{nodeSep:50,rankSep:50,edgeSep:5}},subScene:{meta:{paddingTop:20,paddingBottom:20,paddingLeft:20,paddingRight:20,labelHeight:20}},nodeSize:{meta:{width:50,maxLabelWidth:0,height:50},node:{width:50,height:50,labelOffset:10,maxLabelWidth:40},bridge:{width:5,height:5,radius:2,labelOffset:0}}},Ti=class{toggle(e){this.expansionModel.toggle(e)}expand(e){let n=this.dataSource.compound||{},i=this.findParents(n,e,[e]);this.expansionModel.select(...i)}collapse(e){let n=this.dataSource.compound||{},i=this.findChildren(n,e,[e]);this.expansionModel.deselect(...i)}isExpanded(e){return this.expansionModel.isSelected(e)}collapseAll(){this.expansionModel.clear()}expandAll(){this.expansionModel.select(...Object.keys(this._data.value.compound||{}))}setData(e){this.expansionModel?.clear(),this.dataSource=e,this._data.next(e)}constructor(e){this._data=new go({}),this.expansionModel=new jo(!0),e&&(this.expansionModel?.clear(),this.dataSource=e,this._data.next(e))}connect(){let e=[this._data,this.expansionModel.changed];return bo(...e).pipe(vo(()=>this._data.value))}disconnect(){}findParents(e,n,i=[]){let r=Object.keys(e).filter(o=>o!==n).find(o=>e[o].includes(n));return r?this.findParents(e,r,[r,...i]):i}findChildren(e,n,i=[]){let r=Object.keys(e),o=(e[n]||[]).filter(s=>r.includes(s));return o&&o.length>0?o.reduce((s,u)=>Array.from(new Set([...s,...this.findChildren(e,u,[...i,u])])),i):i}},_g=(()=>{let e=class e{};e.\u0275fac=function(r){return new(r||e)},e.\u0275cmp=mt({type:e,selectors:[["defs","nz-graph-defs",""]],standalone:!0,features:[Ae],attrs:rg,decls:2,vars:0,consts:[["id","edge-end-arrow","viewBox","1 0 20 20","refX","8","refY","3.5","markerWidth","10","markerHeight","10","orient","auto",1,"nz-graph-edge-marker"],["points","0 0, 10 3.5, 0 7"]],template:function(r,o){r&1&&(Q(),d(0,"marker",0),U(1,"polygon",1),l())},encapsulation:2});let t=e;return t})(),zg=(()=>{let e=class e{get id(){return this.edge?.id||`${this.edge.v}--${this.edge.w}`}constructor(i,r){this.elementRef=i,this.cdr=r,this.line=On().x(o=>o.x).y(o=>o.y).curve(ue),this.injector=mn(zo),this.el=this.elementRef.nativeElement}ngOnInit(){this.initElementStyle()}ngOnChanges(i){let{edge:r,customTemplate:o,edgeType:s}=i;if(r&&ko(()=>{o&&this.initElementStyle(),this.setLine(),this.cdr.markForCheck()},{injector:this.injector}),s){let u=this.edgeType===Ju.LINE?ue:tr;this.line=On().x(c=>c.x).y(c=>c.y).curve(u)}}initElementStyle(){this.path=this.el.querySelector("path"),this.setElementData()}setLine(){this.setPath(this.line(this.edge.points))}setPath(i){this.path.setAttribute("d",i)}setElementData(){this.path&&(this.path.setAttribute("id",this.id),this.path.setAttribute("data-edge",this.id),this.path.setAttribute("data-v",`${this.edge.v}`),this.path.setAttribute("data-w",`${this.edge.w}`))}};e.\u0275fac=function(r){return new(r||e)(at(Vt),at(En))},e.\u0275cmp=mt({type:e,selectors:[["","nz-graph-edge",""]],inputs:{edge:"edge",edgeType:"edgeType",customTemplate:"customTemplate"},standalone:!0,features:[Gi,Ae],attrs:og,decls:2,vars:1,consts:[[3,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"nz-graph-edge-line"],["text-anchor","middle","dy","10",1,"nz-graph-edge-text"],["startOffset","50%"]],template:function(r,o){r&1&&Mt(0,ag,1,4,"ng-container",0)(1,lg,3,2,":svg:g"),r&2&&qt(o.customTemplate?0:1)},dependencies:[yn],encapsulation:2,changeDetection:0});let t=e;return t})(),Cg=(()=>{let e=class e{};e.\u0275fac=function(r){return new(r||e)},e.\u0275dir=Te({type:e,selectors:[["","nzGraphEdge",""]],exportAs:["nzGraphEdge"],standalone:!0});let t=e;return t})(),fo=(()=>{let e=class e{};e.\u0275fac=function(r){return new(r||e)},e.\u0275dir=Te({type:e,selectors:[["","nzGraphGroupNode",""]],exportAs:["nzGraphGroupNode"],standalone:!0});let t=e;return t})();var Di=class{},mo=(()=>{let e=class e{constructor(i,r,o,s,u){this.ngZone=i,this.el=r,this.builder=o,this.renderer2=s,this.graphComponent=u,this.animationInfo=null,this.initialState=!0,this.destroy$=new Oe,this.animationPlayer=null}ngOnInit(){this.ngZone.runOutsideAngular(()=>{yo(this.el.nativeElement,"click").pipe(So(i=>(i.preventDefault(),this.graphComponent.nzNodeClick.observers.length>0)),cn(this.destroy$)).subscribe(()=>{this.ngZone.run(()=>this.graphComponent.nzNodeClick.emit(this.node))})})}ngOnDestroy(){this.destroy$.next()}makeAnimation(){let i=this.getAnimationInfo();this.animationPlayer&&this.animationPlayer.destroy();let r,o=vt({},this.animationInfo);this.initialState?(r=this.builder.build([Ht({transform:`translate(${i.x}px, ${i.y}px)`}),Nn("g",[Ht({width:`${i.width}px`,height:`${i.height}px`})])]),this.initialState=!1):r=this.builder.build([Ht({transform:`translate(${o.x}px, ${o.y}px)`}),Nn("g",[Ht({width:`${o.width}px`,height:`${o.height}px`})]),qo([Nn("g",[Yi("150ms ease-out",Ht({width:`${i.width}px`,height:`${i.height}px`}))]),Yi("150ms ease-out",Ht({transform:`translate(${i.x}px, ${i.y}px)`}))])]),this.animationInfo=i,this.animationPlayer=r.create(this.el.nativeElement),this.animationPlayer.play();let s=new Oe;return this.animationPlayer.onDone(()=>{this.renderer2.setAttribute(this.el.nativeElement,"transform",`translate(${i.x}, ${i.y})`),s.next(),s.complete()}),s.asObservable()}makeNoAnimation(){let i=this.getAnimationInfo();this.renderer2.setAttribute(this.el.nativeElement,"transform",`translate(${i.x}, ${i.y})`)}getAnimationInfo(){let{x:i,y:r}=this.nodeTransform();return{width:this.node.width,height:this.node.height,x:i,y:r}}nodeTransform(){let i=this.computeCXPositionOfNodeShape()-this.node.width/2,r=this.node.y-this.node.height/2;return{x:i,y:r}}computeCXPositionOfNodeShape(){return this.node.expanded?this.node.x:this.node.x-this.node.width/2+this.node.coreBox.width/2}};e.\u0275fac=function(r){return new(r||e)(at(No),at(Vt),at(Ho),at(Co),at(Di))},e.\u0275cmp=mt({type:e,selectors:[["","nz-graph-node",""]],hostVars:7,hostBindings:function(r,o){r&2&&(Oo("id",o.node.id||o.node.name),ji("nz-graph-node-expanded",o.node.expanded)("nz-graph-group-node",o.node.type===0)("nz-graph-base-node",o.node.type===1))},inputs:{node:"node",noAnimation:[2,"noAnimation","noAnimation",Xi],customTemplate:"customTemplate"},standalone:!0,features:[xn,Ae],attrs:ug,decls:3,vars:1,consts:[[3,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"nz-graph-node-rect"],["x","10","y","20"]],template:function(r,o){r&1&&(Q(),d(0,"g"),Mt(1,dg,1,4,":svg:ng-container",0)(2,cg,3,3),l()),r&2&&(I(),qt(o.customTemplate?1:2))},dependencies:[yn],encapsulation:2,changeDetection:0});let t=e;return t})(),po=(()=>{let e=class e{};e.\u0275fac=function(r){return new(r||e)},e.\u0275dir=Te({type:e,selectors:[["","nzGraphNode",""]],exportAs:["nzGraphNode"],standalone:!0});let t=e;return t})(),td=(t,e,n)=>{let i=t.getBoundingClientRect(),r=e.getBBox();if(!r.width)return null;let o=(i.width-48)/i.width,s=n||Math.min(i.width/r.width,i.height/r.height,1)*o,u=(i.width-r.width*s)/2,c=(i.height-r.height*s)/2;return{x:u,y:c,k:s}},un=(()=>{let e=class e{constructor(i,r){this.element=i,this.cdr=r,this.nzMinZoom=.1,this.nzMaxZoom=10,this.nzTransformEvent=new se,this.nzZoomChange=new se,this.destroy$=new Oe}ngAfterViewInit(){this.bind()}ngOnDestroy(){this.unbind(),this.destroy$.next(),this.destroy$.complete()}bind(){this.svgElement=this.element.nativeElement.querySelector("svg"),this.gZoomElement=this.element.nativeElement.querySelector("svg > g");let{width:i,height:r}=this.element.nativeElement.getBoundingClientRect();this.svgSelection=Ye().selection().select(()=>this.svgElement),this.zoomBehavior=br().extent([[0,0],[i,r]]).scaleExtent([this.nzMinZoom,this.nzMaxZoom]).on("zoom",o=>{this.zoomed(o)}),this.svgSelection.call(this.zoomBehavior,jt.translate(0,0).scale(this.nzZoom||1)),this.reScale(0,this.nzZoom)}unbind(){this.svgSelection?.interrupt().selectAll("*").interrupt(),this.zoomBehavior&&this.zoomBehavior.on("end",null).on("zoom",null)}fitCenter(i=0){this.reScale(i)}focus(i,r=0){if(!this.svgElement.getElementById(`${i}`))return;let o=this.svgElement.getElementById(`${i}`),s=this.svgElement.getBoundingClientRect(),u=this.getRelativePositionInfo(o),c=Qe(this.svgElement),h=(u.topLeft.x+u.bottomRight.x)/2,m=(u.topLeft.y+u.bottomRight.y)/2,f=s.left+s.width/2-h,p=s.top+s.height/2-m;this.svgSelection.transition().duration(r).call(this.zoomBehavior.translateBy,f/c.k,p/c.k)}zoomed({transform:i}){let{x:r,y:o,k:s}=i;this.gZoomElement.setAttribute("transform",`translate(${r}, ${o})scale(${s})`),this.nzZoom=s,this.nzZoomChange.emit(this.nzZoom),this.nzTransformEvent.emit(i),this.cdr.markForCheck()}reScale(i,r){let o=td(this.svgElement,this.gZoomElement,r);if(!o)return;let{x:s,y:u,k:c}=o,h=jt.translate(s,u).scale(Math.max(c,this.nzMinZoom));this.svgSelection.transition().duration(i).call(this.zoomBehavior.transform,h).on("end.fitted",()=>{this.zoomBehavior.on("end.fitted",null)})}getRelativePositionInfo(i){let r=i.getBBox(),o=i.getScreenCTM(),s=this.svgElement.createSVGPoint(),u=this.svgElement.createSVGPoint();return s.x=r.x,s.y=r.y,u.x=r.x+r.width,u.y=r.y+r.height,s=s.matrixTransform(o),u=u.matrixTransform(o),{topLeft:s,bottomRight:u}}};e.\u0275fac=function(r){return new(r||e)(at(Vt),at(En))},e.\u0275dir=Te({type:e,selectors:[["","nz-graph-zoom",""]],inputs:{nzZoom:[2,"nzZoom","nzZoom",Ro],nzMinZoom:"nzMinZoom",nzMaxZoom:"nzMaxZoom"},outputs:{nzTransformEvent:"nzTransformEvent",nzZoomChange:"nzZoomChange"},exportAs:["nzGraphZoom"],standalone:!0,features:[xn]});let t=e;return t})();function Ng(t){return t&&typeof t.connect=="function"}var Bi=(()=>{let e=class e{constructor(i,r){this.cdr=i,this.elementRef=r,this.nzRankDirection="LR",this.nzAutoSize=!1,this.nzGraphInitialized=new se,this.nzGraphRendered=new se,this.nzNodeClick=new se,this.requestId=-1,this.transformStyle="",this.graphRenderedSubject$=new xo(1),this.renderInfo={labelHeight:0},this.mapOfNodeAttr={},this.mapOfEdgeAttr={},this.zoom=1,this.typedNodes=wg(),this.layoutSetting=ke,this.destroy$=new Oe,this.edgeTrackByFun=o=>`${o.v}-${o.w}`,this.subGraphTransform=o=>{let s=o.x-o.coreBox.width/2,u=o.y-o.height/2+o.paddingTop;return`translate(${s}, ${u})`},this.$asNzGraphEdges=o=>o,this.coreTransform=o=>`translate(0, ${o.parentNodeName?o.labelHeight:0})`,this.noAnimation=mn(Uo,{host:!0,optional:!0}),this.nzGraphZoom=mn(un,{optional:!0})}ngOnInit(){this.graphRenderedSubject$.pipe(wo(1),cn(this.destroy$)).subscribe(()=>{this.nzGraphZoom||this.fitCenter(),this.nzGraphInitialized.emit(this)})}ngOnChanges(i){let{nzAutoFit:r,nzRankDirection:o,nzGraphData:s,nzGraphLayoutConfig:u}=i;u&&(this.layoutSetting=this.mergeConfig(u.currentValue)),s&&this.dataSource!==this.nzGraphData&&this._switchDataSource(this.nzGraphData),(r&&!r.firstChange||o&&!o.firstChange)&&this.dataSource.dataSource&&this.drawGraph(this.dataSource.dataSource,{rankDirection:this.nzRankDirection,expanded:this.dataSource.expansionModel.selected||[]}).then(()=>{this.cdr.markForCheck()}),this.cdr.markForCheck()}ngAfterContentChecked(){this.dataSource&&!this._dataSubscription&&this.observeRenderChanges()}ngOnDestroy(){this.destroy$.next(),this.destroy$.complete(),this.dataSource&&typeof this.dataSource.disconnect=="function"&&this.dataSource.disconnect(),this._dataSubscription&&(this._dataSubscription.unsubscribe(),this._dataSubscription=null),$o(this.requestId)}fitCenter(){let{x:i,y:r,k:o}=td(this.elementRef.nativeElement.querySelector("svg"),this.elementRef.nativeElement.querySelector("svg > g"));o&&(this.zoom=o,this.transformStyle=`translate(${i}, ${r})scale(${o})`),this.cdr.markForCheck()}drawGraph(i,r,o=!1){return new Promise(s=>{this.requestId=requestAnimationFrame(()=>{let u=this.buildGraphInfo(i,r);this.renderInfo=u,this.cdr.markForCheck(),this.requestId=requestAnimationFrame(()=>{this.drawNodes(!this.noAnimation?.nzNoAnimation).then(()=>{this.cdr.markForCheck(),o?this.resizeNodeSize().then(()=>{let c=this.dataSource.dataSource;this.drawGraph(c,r,!1).then(()=>s())}):(this.graphRenderedSubject$.next(),this.nzGraphRendered.emit(this),s())})})}),this.cdr.markForCheck()})}drawNodes(i=!0){return new Promise(r=>{i?this.makeNodesAnimation().subscribe(()=>{r()}):(this.listOfNodeComponent.map(o=>{o.makeNoAnimation()}),r())})}resizeNodeSize(){return new Promise(i=>{let r=this.dataSource.dataSource,o=this.nzGraphZoom?.nzZoom||this.zoom||1;this.listOfNodeElement.forEach(s=>{let u=s.nativeElement;if(u){let c,h,m=u.querySelector("foreignObject > :first-child")?.getBoundingClientRect();if(m)c=m.width,h=m.height;else{let p=u.getBBox();c=p.width,h=p.height,o=1}let f=r.nodes.find(p=>`${p.id}`===s.nativeElement.id);f&&c&&h&&(f.height=h/o,f.width=c/o)}}),i()})}_switchDataSource(i){this.dataSource&&typeof this.dataSource.disconnect=="function"&&this.nzGraphData.disconnect(),this._dataSubscription&&(this._dataSubscription.unsubscribe(),this._dataSubscription=null),this.dataSource=i,this.observeRenderChanges()}observeRenderChanges(){let i,r={rankDirection:this.nzRankDirection};if(Ng(this.dataSource)&&(i=this.dataSource.connect()),i)this._dataSubscription=i.pipe(cn(this.destroy$)).subscribe(o=>{r={rankDirection:this.nzRankDirection,expanded:this.nzGraphData.expansionModel.selected},this.drawGraph(o,r,this.nzAutoSize).then(()=>{this.cdr.detectChanges()})});else throw Error("A valid data source must be provided.")}buildGraphInfo(i,r){this.parseInfo(i);let o=Wu(i,r,this.layoutSetting),s=u=>{u.forEach(c=>{let{x:h,y:m}=c;c.xOffset=h,c.yOffset=m,c.type===1&&this.mapOfNodeAttr.hasOwnProperty(c.name)?Object.assign(c,this.mapOfNodeAttr[c.name]):c.type===0&&(c.edges.forEach(f=>{this.mapOfEdgeAttr.hasOwnProperty(`${f.v}-${f.w}`)&&Object.assign(f,this.mapOfEdgeAttr[`${f.v}-${f.w}`])}),s(c.nodes))})};return s(o.nodes),o.edges.forEach(u=>{this.mapOfEdgeAttr.hasOwnProperty(`${u.v}-${u.w}`)&&Object.assign(u,this.mapOfEdgeAttr[`${u.v}-${u.w}`])}),o}makeNodesAnimation(){return Eo(this.listOfNodeComponent.map(i=>i.makeAnimation())).pipe(_o(()=>{this.cdr.detectChanges()}))}parseInfo(i){i.nodes.forEach(r=>{this.mapOfNodeAttr[r.id]=r}),i.edges.forEach(r=>{this.mapOfEdgeAttr[`${r.v}-${r.w}`]=r})}mergeConfig(i){let r=i?.layout||{},o=i?.subScene||{},s=i?.defaultNode||{},u=i?.defaultCompoundNode||{},c=ke.nodeSize.bridge,h={meta:vt(vt({},ke.graph.meta),r)},m={meta:vt(vt({},ke.subScene.meta),o)},f={meta:vt(vt({},ke.nodeSize.meta),u),node:vt(vt({},ke.nodeSize.node),s),bridge:c};return{graph:h,subScene:m,nodeSize:f}}};e.\u0275fac=function(r){return new(r||e)(at(En),at(Vt))},e.\u0275cmp=mt({type:e,selectors:[["nz-graph"]],contentQueries:function(r,o,s){if(r&1&&(vn(s,po,7,gn),vn(s,fo,7,gn),vn(s,Cg,7,gn)),r&2){let u;nt(u=it())&&(o.nodeTemplate=u.first),nt(u=it())&&(o.groupNodeTemplate=u.first),nt(u=it())&&(o.customGraphEdgeTemplate=u.first)}},viewQuery:function(r,o){if(r&1&&(yt(mo,5,Vt),yt(mo,5)),r&2){let s;nt(s=it())&&(o.listOfNodeElement=s),nt(s=it())&&(o.listOfNodeComponent=s)}},hostVars:4,hostBindings:function(r,o){r&2&&ji("nz-graph",!0)("nz-graph-auto-size",o.nzAutoSize)},inputs:{nzGraphData:"nzGraphData",nzRankDirection:"nzRankDirection",nzGraphLayoutConfig:"nzGraphLayoutConfig",nzAutoSize:[2,"nzAutoSize","nzAutoSize",Xi]},outputs:{nzGraphInitialized:"nzGraphInitialized",nzGraphRendered:"nzGraphRendered",nzNodeClick:"nzNodeClick"},exportAs:["nzGraph"],standalone:!0,features:[Io([{provide:Di,useExisting:e}]),xn,Gi,Ae],ngContentSelectors:hg,decls:7,vars:5,consts:[["groupTemplate",""],["width","100%","height","100%"],["nz-graph-defs",""],[3,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"core"],[1,"nz-graph-edges"],["nz-graph-edge","",1,"nz-graph-edge",3,"edge","edgeType","customTemplate"],[1,"nz-graph-nodes"],["nz-graph-node","",1,"nz-graph-node",3,"node","customTemplate"]],template:function(r,o){if(r&1&&(To(),Do(0),Q(),d(1,"svg",1),U(2,"defs",2),d(3,"g"),De(4,3),l()(),Mt(5,Sg,8,2,"ng-template",null,0,Go)),r&2){let s=Hi(6);I(3),Et("transform",o.transformStyle),I(),P("ngTemplateOutlet",s)("ngTemplateOutletContext",Be(3,pg,o.renderInfo))}},dependencies:[yn,zg,mo,_g],encapsulation:2,changeDetection:0});let t=e;return t})(),ed=(()=>{let e=class e{};e.\u0275fac=function(r){return new(r||e)},e.\u0275mod=fn({type:e}),e.\u0275inj=hn({});let t=e;return t})();function Tg(t,e){if(t&1){let n=qi();$i(0),Q(),d(1,"foreignObject",10),pn(),d(2,"div",11),et("click",function(){let r=Fi(n).$implicit,o=Y();return Ri(o.focusNode(r.id||r.name))}),d(3,"div",12),a(4),l()()(),Vi()}if(t&2){let n=e.$implicit;I(),Et("width",n.width)("height",n.height),I(3),Zi(" ",n.name," ")}}function Dg(t,e){if(t&1){let n=qi();$i(0),Q(),d(1,"foreignObject",10),pn(),d(2,"div",13),et("click",function(){let r=Fi(n).$implicit,o=Y();return Ri(o.focusNode(r.id||r.name))}),d(3,"div",12),a(4),l()()(),Vi()}if(t&2){let n=e.$implicit;I(),Et("width",n.width)("height",n.height),I(3),Zi(" ",n.name," ")}}var Mi=(()=>{let e=class e{constructor(){this.zoom=.5,this.testDef={nodes:[{id:"0",label:"0"},{id:"1",label:"1"},{id:"2",label:"2"},{id:"3",label:"3"},{id:"4",label:"4"},{id:"5",label:"5"},{id:"6",label:"6"},{id:"7",label:"7"},{id:"8",label:"8"},{id:"9",label:"9"},{id:"10",label:"10"},{id:"11",label:"11"},{id:"12",label:"12"},{id:"13",label:"13"},{id:"14",label:"14"},{id:"15",label:"15"}],edges:[{v:"0",w:"1"},{v:"0",w:"2"},{v:"0",w:"3"},{v:"0",w:"4"},{v:"0",w:"5"},{v:"0",w:"7"},{v:"0",w:"8"},{v:"0",w:"9"},{v:"0",w:"10"},{v:"0",w:"11"},{v:"0",w:"13"},{v:"0",w:"14"},{v:"0",w:"15"},{v:"2",w:"3"},{v:"4",w:"5"},{v:"4",w:"6"},{v:"5",w:"6"},{v:"7",w:"13"},{v:"8",w:"14"},{v:"9",w:"10"},{v:"10",w:"14"},{v:"10",w:"12"},{v:"11",w:"14"},{v:"12",w:"13"}],compound:{G0:["4","5","15"]}},this.rankDirection="TB",this.graphData=new Ti(this.testDef)}expand(i){this.graphData.expand(i)}collapse(i){this.graphData.collapse(i)}expandAll(){this.graphData.expandAll()}collapseAll(){this.graphData.collapseAll()}fit(){this.zoomController?.fitCenter()}focusNode(i){this.zoomController?.focus(i)}graphInitialized(i){this.zoomController?.fitCenter()}};e.\u0275fac=function(r){return new(r||e)},e.\u0275cmp=mt({type:e,selectors:[["nz-demo-graph-customized"]],viewQuery:function(r,o){if(r&1&&(yt(Bi,7),yt(un,7)),r&2){let s;nt(s=it())&&(o.nzGraphComponent=s.first),nt(s=it())&&(o.zoomController=s.first)}},decls:18,vars:4,consts:[["nz-button","","nzType","default",3,"click"],["nz-button","","nzType","primary",3,"click"],[3,"ngModelChange","ngModel"],["nz-radio-button","","nzValue","LR"],["nz-radio-button","","nzValue","RL"],["nz-radio-button","","nzValue","TB"],["nz-radio-button","","nzValue","BT"],["nz-graph-zoom","",3,"nzGraphInitialized","nzGraphData","nzAutoSize","nzRankDirection"],[4,"nzGraphNode"],[4,"nzGraphGroupNode"],["x","0","y","0"],[1,"graph-node","leaf-node",3,"click"],[1,"title"],[1,"graph-node","group-node",3,"click"]],template:function(r,o){r&1&&(d(0,"button",0),et("click",function(){return o.expandAll()}),a(1,"ExpandAll"),l(),d(2,"button",0),et("click",function(){return o.collapseAll()}),a(3,"CollapseAll"),l(),d(4,"button",1),et("click",function(){return o.fit()}),a(5,"Fit"),l(),d(6,"nz-radio-group",2),Mo("ngModelChange",function(u){return Bo(o.rankDirection,u)||(o.rankDirection=u),u}),d(7,"label",3),a(8,"LR"),l(),d(9,"label",4),a(10,"RL"),l(),d(11,"label",5),a(12,"TB"),l(),d(13,"label",6),a(14,"BT"),l()(),d(15,"nz-graph",7),et("nzGraphInitialized",function(u){return o.graphInitialized(u)}),Mt(16,Tg,5,3,"ng-container",8)(17,Dg,5,3,"ng-container",9),l()),r&2&&(I(6),Ao("ngModel",o.rankDirection),I(9),P("nzGraphData",o.graphData)("nzAutoSize",!0)("nzRankDirection",o.rankDirection))},dependencies:[Lo,Po,Bi,po,fo,un,Yo,le,Xo,Ko,Qo],styles:["nz-radio-group[_ngcontent-%COMP%]{float:right}button[_ngcontent-%COMP%]{margin-right:12px}nz-graph[_ngcontent-%COMP%]{height:400px}.graph-node[_ngcontent-%COMP%]{border:1px solid #8cc8ff;cursor:pointer;font-size:12px;height:100%;line-height:1.2;border-radius:0;text-align:center;word-break:break-all;display:block}.group-node[_ngcontent-%COMP%]{border-width:4px}.leaf-node[_ngcontent-%COMP%]{color:#1a90ff;background:#1a90ff26;min-height:30px;height:fit-content}.title[_ngcontent-%COMP%]{padding:4px;word-break:keep-all}"]});let t=e;return t})();var ad=(()=>{let e=class e{constructor(){this.expanded=!1}goLink(i){window&&(window.location.hash=i)}expandAllCode(){this.expanded=!this.expanded,this.codeBoxes.forEach(i=>i.expandCode(this.expanded))}};e.\u0275fac=function(r){return new(r||e)},e.\u0275cmp=mt({type:e,selectors:[["nz-demo-graph"]],viewQuery:function(r,o){if(r&1&&yt(It,5),r&2){let s;nt(s=it())&&(o.codeBoxes=s)}},decls:1019,vars:8,consts:[[1,"toc-affix",3,"nzOffsetTop"],["nzShowInkInFixed","",3,"nzClick","nzAffix"],["nzHref","#components-graph-demo-customized","nzTitle","\u81EA\u5B9A\u4E49"],["nzHref","#api","nzTitle","API"],[1,"markdown"],[1,"subtitle"],[1,"widget"],["aria-label","Edit this page on Github","href","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/graph/doc/index.zh-CN.md","target","_blank","rel","noopener noreferrer",1,"edit-button"],["nz-icon","","nzType","edit"],[2,"border-color","#faad14"],["id","\u4F55\u65F6\u4F7F\u7528"],["onclick","window.location.hash = '\u4F55\u65F6\u4F7F\u7528'",1,"anchor"],["id","\u5F15\u5165\u6A21\u5757"],["onclick","window.location.hash = '\u5F15\u5165\u6A21\u5757'",1,"anchor"],[1,"language-ts"],[1,"token","keyword"],[1,"token","punctuation"],[1,"token","string"],["id","\u5F15\u5165\u6837\u5F0F"],["onclick","window.location.hash = '\u5F15\u5165\u6837\u5F0F'",1,"anchor"],[1,"language-less"],[1,"token","variable"],["nz-icon","","nzType","appstore","nz-tooltip","","nzTooltipTitle","\u5C55\u5F00\u5168\u90E8\u4EE3\u7801",1,"code-box-expand-trigger",3,"click"],["nz-row","",3,"nzGutter"],["nz-col","",3,"nzSpan"],["nzTitle","\u81EA\u5B9A\u4E49","nzSelector","nz-demo-graph-customized","nzGenerateCommand","ng g ng-zorro-antd:graph-customized <name>","nzComponentName","NzDemoGraphCustomizedComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["demo",""],["intro",""],[1,"markdown","api-container"],["id","api"],["onclick","window.location.hash = 'api'",1,"anchor"],[1,"language-sh"],[1,"token","operator"],["id","nz-graph:standalone"],[1,"api-type-label","component"],[1,"api-type-label","standalone"],["onclick","window.location.hash = 'nz-graph:standalone'",1,"anchor"],["id","\u7EC4\u4EF6\u65B9\u6CD5"],["onclick","window.location.hash = '\u7EC4\u4EF6\u65B9\u6CD5'",1,"anchor"],["id","[nz-graph-zoom]:standalone"],[1,"api-type-label","directive"],["onclick","window.location.hash = '[nz-graph-zoom]:standalone'",1,"anchor"],["id","nzgraphdata"],["onclick","window.location.hash = 'nzgraphdata'",1,"anchor"],["id","nzgraphlayoutconfig"],["onclick","window.location.hash = 'nzgraphlayoutconfig'",1,"anchor"],["id","nzgraphdatadef"],["onclick","window.location.hash = 'nzgraphdatadef'",1,"anchor"],["id","nzgraphnode"],["onclick","window.location.hash = 'nzgraphnode'",1,"anchor"],["id","nzgraphedge"],["onclick","window.location.hash = 'nzgraphedge'",1,"anchor"],["id","nzgraphgroupnode"],["onclick","window.location.hash = 'nzgraphgroupnode'",1,"anchor"],["id","[nzgraphnode]"],["onclick","window.location.hash = '[nzgraphnode]'",1,"anchor"],[1,"language-html"],[1,"token","tag"],[1,"token","attr-name"],[1,"token","attr-value"],["id","[nzgraphgroupnode]"],["onclick","window.location.hash = '[nzgraphgroupnode]'",1,"anchor"],["id","[nzgraphedge]"],["onclick","window.location.hash = '[nzgraphedge]'",1,"anchor"],[1,"token","namespace"],["id","\u6837\u5F0F"],["onclick","window.location.hash = '\u6837\u5F0F'",1,"anchor"],["id","\u8BF4\u660E"],["onclick","window.location.hash = '\u8BF4\u660E'",1,"anchor"],["href","https://www.npmjs.com/package/dagre-compound","target","_blank","rel","noopener"],["href","https://github.com/angular/components/blob/master/src/cdk/collections/selection-model.ts","target","_blank","rel","noopener"]],template:function(r,o){r&1&&(d(0,"article")(1,"nz-affix",0)(2,"nz-anchor",1),et("nzClick",function(u){return o.goLink(u)}),U(3,"nz-link",2)(4,"nz-link",3),l()(),d(5,"section",4)(6,"h1"),a(7,"Graph"),d(8,"span",5),a(9,"\u6D41\u7A0B\u56FE"),l(),U(10,"span",6),d(11,"a",7),U(12,"span",8),l()(),d(13,"section",4),Bt(),d(14,"blockquote",9)(15,"p"),a(16,"NG-ZORRO \u5B9E\u9A8C\u6027\u529F\u80FD\u662F\u6307\u5DF2\u53D1\u5E03\u4F46\u4E0D\u7A33\u5B9A\u6216\u8005\u8FD8\u672A\u51C6\u5907\u597D\u7528\u4E8E\u751F\u4EA7\u73AF\u5883\u7684\u529F\u80FD\u3002"),l(),d(17,"p"),a(18,"\u5F00\u53D1\u8005\u6216\u7528\u6237\u53EF\u4EE5\u9009\u62E9\u5728\u6B63\u5F0F\u53D1\u5E03\u524D\u4F7F\u7528\u8FD9\u4E9B\u529F\u80FD\uFF0C\u4F46\u662F\u6BCF\u6B21\u53D1\u5E03\u7248\u672C\u65F6\u90FD\u53EF\u80FD\u5B58\u5728 "),d(19,"strong"),a(20,"breaking changes"),l(),a(21,"\u3002"),l()(),d(22,"h2",10)(23,"span"),a(24,"\u4F55\u65F6\u4F7F\u7528"),l(),d(25,"a",11),a(26,"#"),l()(),d(27,"p"),a(28,"\u9700\u8981\u5728\u7F51\u9875\u4E0A\u6E32\u67D3 GRAPH \u56FE\u65F6\u4F7F\u7528\u3002"),l(),d(29,"h3",12)(30,"span"),a(31,"\u5F15\u5165\u6A21\u5757"),l(),d(32,"a",13),a(33,"#"),l()(),d(34,"blockquote")(35,"p"),a(36,"\u76EE\u524D\u7EC4\u4EF6\u4F9D\u8D56 d3-drag d3-zoom d3-selection d3-transition d3-shape \u7528\u4E8E\u7ED8\u5236\u76F8\u5173\u5C5E\u6027\uFF08\u53EF\u80FD\u4F1A\u5728\u4E4B\u540E\u7684\u7248\u672C\u4E2D\u9010\u6B65\u66FF\u6362\uFF09"),l()(),d(37,"pre",14)(38,"code")(39,"span",15),a(40,"import"),l(),a(41," "),d(42,"span",16),a(43,"{"),l(),a(44," NzGraphModule "),d(45,"span",16),a(46,"}"),l(),a(47," "),d(48,"span",15),a(49,"from"),l(),a(50," "),d(51,"span",17),a(52,"'ng-zorro-antd/graph'"),l(),d(53,"span",16),a(54,";"),l()()(),d(55,"h3",18)(56,"span"),a(57,"\u5F15\u5165\u6837\u5F0F"),l(),d(58,"a",19),a(59,"#"),l()(),d(60,"pre",20)(61,"code")(62,"span",21),a(63,"@import"),l(),a(64," "),d(65,"span",17),a(66,"'node_modules/ng-zorro-antd/graph/style/entry.less'"),l(),d(67,"span",16),a(68,";"),l()()(),At(),l(),d(69,"h2")(70,"span"),a(71,"\u4EE3\u7801\u6F14\u793A"),l(),d(72,"span",22),et("click",function(){return o.expandAllCode()}),l()()(),d(73,"div",23)(74,"div",24)(75,"nz-code-box",25),U(76,"nz-demo-graph-customized",26),d(77,"div",27),Bt(),d(78,"p"),a(79,"\u81EA\u5B9A\u4E49 node \u6837\u5F0F\u3002"),l(),At(),l()()()(),d(80,"section",28),Bt(),d(81,"h2",29)(82,"span"),a(83,"API"),l(),d(84,"a",30),a(85,"#"),l()(),d(86,"p"),a(87,"\u5B89\u88C5\u4F9D\u8D56\uFF1A"),l(),d(88,"pre",31)(89,"code"),a(90,"npm install dagre"),d(91,"span",32),a(92,"-"),l(),a(93,"compound dagre d3"),d(94,"span",32),a(95,"-"),l(),a(96,"transition d3"),d(97,"span",32),a(98,"-"),l(),a(99,"zoom d3"),d(100,"span",32),a(101,"-"),l(),a(102,"selection d3"),d(103,"span",32),a(104,"-"),l(),a(105,"shape d3"),d(106,"span",32),a(107,"-"),l(),a(108,"drag "),d(109,"span",21),a(110,"@types"),l(),d(111,"span",32),a(112,"/"),l(),a(113,"d3"),l()(),d(114,"h3",33)(115,"span"),a(116,"nz-graph"),l(),d(117,"label",34),a(118,"component"),l(),d(119,"label",35),a(120,"standalone"),l(),d(121,"a",36),a(122,"#"),l()(),d(123,"table")(124,"thead")(125,"tr")(126,"th"),a(127,"\u53C2\u6570"),l(),d(128,"th"),a(129,"\u8BF4\u660E"),l(),d(130,"th"),a(131,"\u7C7B\u578B"),l(),d(132,"th"),a(133,"\u9ED8\u8BA4\u503C"),l()()(),d(134,"tbody")(135,"tr")(136,"td")(137,"code"),a(138,"[nzGraphData]"),l()(),d(139,"td"),a(140,"\u6570\u636E\u6E90"),l(),d(141,"td")(142,"code"),a(143,"NzGraphData(data: NzGraphDataDef?)"),l()(),d(144,"td"),a(145,"``"),l()(),d(146,"tr")(147,"td")(148,"code"),a(149,"[nzRankDirection]"),l()(),d(150,"td"),a(151,"\u56FE\u65B9\u5411"),l(),d(152,"td")(153,"code"),a(154,"TB"),l(),a(155," | "),d(156,"code"),a(157,"BT"),l(),a(158," | "),d(159,"code"),a(160,"LR"),l(),a(161," | "),d(162,"code"),a(163,"RL"),l()(),d(164,"td")(165,"code"),a(166,"LR"),l()()(),d(167,"tr")(168,"td")(169,"code"),a(170,"[nzAutoSize]"),l()(),d(171,"td"),a(172,"\u662F\u5426\u6839\u636E\u8282\u70B9\u5185\u5BB9\u81EA\u9002\u5E94\u9AD8\u5EA6(\u9ED8\u8BA4\u7B49\u9AD8)"),l(),d(173,"td")(174,"code"),a(175,"boolean"),l()(),d(176,"td")(177,"code"),a(178,"false"),l()()(),d(179,"tr")(180,"td")(181,"code"),a(182,"[nzGraphLayoutConfig]"),l()(),d(183,"td"),a(184,"\u5168\u5C40\u914D\u7F6E"),l(),d(185,"td")(186,"code"),a(187,"NzGraphLayoutConfig"),l()(),d(188,"td"),a(189,"``"),l()()()(),d(190,"h4",37)(191,"span"),a(192,"\u7EC4\u4EF6\u65B9\u6CD5"),l(),d(193,"a",38),a(194,"#"),l()(),d(195,"table")(196,"thead")(197,"tr")(198,"th"),a(199,"\u540D\u79F0"),l(),d(200,"th"),a(201,"\u63CF\u8FF0"),l()()(),d(202,"tbody")(203,"tr")(204,"td")(205,"code"),a(206,"fitCenter()"),l()(),d(207,"td"),a(208,"\u5C45\u4E2D\u56FE\u5E76\u81EA\u9002\u5E94\u7F29\u653E\uFF08\u5982\u4F7F\u7528\u7F29\u653E\u529F\u80FD\u8BF7\u4F7F\u7528 "),d(209,"code"),a(210,"nz-graph-zoom"),l(),a(211,"\uFF09"),l()()()(),d(212,"h3",39)(213,"span"),a(214,"[nz-graph-zoom]"),l(),d(215,"label",40),a(216,"directive"),l(),d(217,"label",35),a(218,"standalone"),l(),d(219,"a",41),a(220,"#"),l()(),d(221,"table")(222,"thead")(223,"tr")(224,"th"),a(225,"\u53C2\u6570"),l(),d(226,"th"),a(227,"\u8BF4\u660E"),l(),d(228,"th"),a(229,"\u7C7B\u578B"),l(),d(230,"th"),a(231,"\u9ED8\u8BA4\u503C"),l()()(),d(232,"tbody")(233,"tr")(234,"td")(235,"code"),a(236,"[(nzZoom)]"),l()(),d(237,"td"),a(238,"\u7F29\u653E\u6BD4\u4F8B"),l(),d(239,"td")(240,"code"),a(241,"number"),l()(),d(242,"td")(243,"code"),a(244,"1"),l()()(),d(245,"tr")(246,"td")(247,"code"),a(248,"[nzMinZoom]"),l()(),d(249,"td"),a(250,"\u6700\u5C0F\u7F29\u653E"),l(),d(251,"td")(252,"code"),a(253,"number"),l()(),d(254,"td")(255,"code"),a(256,"0.1"),l()()(),d(257,"tr")(258,"td")(259,"code"),a(260,"[nzMaxZoom]"),l()(),d(261,"td"),a(262,"\u6700\u5927\u7F29\u653E"),l(),d(263,"td")(264,"code"),a(265,"number"),l()(),d(266,"td")(267,"code"),a(268,"10"),l()()(),d(269,"tr")(270,"td")(271,"code"),a(272,"(nzTransformEvent)"),l()(),d(273,"td"),a(274,"\u7F29\u653E\u4E8B\u4EF6"),l(),d(275,"td")(276,"code"),a(277,"() => NzZoomTransform"),l()(),d(278,"td"),a(279,"``"),l()(),d(280,"tr")(281,"td")(282,"code"),a(283,"(fitCenter)"),l()(),d(284,"td"),a(285,"\u5C45\u4E2D\u56FE\u5E76\u81EA\u9002\u5E94\u7F29\u653E"),l(),d(286,"td")(287,"code"),a(288,"() => void"),l()(),d(289,"td")(290,"code"),a(291,"void"),l()()(),d(292,"tr")(293,"td")(294,"code"),a(295,"(focus)"),l()(),d(296,"td"),a(297,"\u5C45\u4E2D\u5355\u4E2A\u8282\u70B9"),l(),d(298,"td")(299,"code"),a(300,"(e: SVGGElement, duration: number) => void"),l()(),d(301,"td")(302,"code"),a(303,"void"),l()()()()(),d(304,"h4",42)(305,"span"),a(306,"NzGraphData"),l(),d(307,"a",43),a(308,"#"),l()(),d(309,"table")(310,"thead")(311,"tr")(312,"th"),a(313,"\u5C5E\u6027/\u65B9\u6CD5"),l(),d(314,"th"),a(315,"\u8BF4\u660E"),l(),d(316,"th"),a(317,"\u7C7B\u578B"),l()()(),d(318,"tbody")(319,"tr")(320,"td")(321,"code"),a(322,"setData"),l()(),d(323,"td"),a(324,"\u8BBE\u7F6E\u6570\u636E\u6E90"),l(),d(325,"td")(326,"code"),a(327,"(data: NzGraphDataDef) => void"),l()()(),d(328,"tr")(329,"td")(330,"code"),a(331,"toggle"),l()(),d(332,"td"),a(333,"\u6536\u8D77/\u5C55\u5F00 group \u8282\u70B9"),l(),d(334,"td")(335,"code"),a(336,"(nodeName: string) => void"),l()()(),d(337,"tr")(338,"td")(339,"code"),a(340,"expand"),l()(),d(341,"td"),a(342,"\u5C55\u5F00 group \u8282\u70B9"),l(),d(343,"td")(344,"code"),a(345,"(nodeName: string) => void"),l()()(),d(346,"tr")(347,"td")(348,"code"),a(349,"expandAll"),l()(),d(350,"td"),a(351,"\u5C55\u5F00\u5168\u90E8 group \u8282\u70B9"),l(),d(352,"td")(353,"code"),a(354,"(nodeName: string) => void"),l()()(),d(355,"tr")(356,"td")(357,"code"),a(358,"collapse"),l()(),d(359,"td"),a(360,"\u6536\u8D77\u5168\u90E8 group \u8282\u70B9"),l(),d(361,"td")(362,"code"),a(363,"(nodeName: string) => void"),l()()(),d(364,"tr")(365,"td")(366,"code"),a(367,"isExpand"),l()(),d(368,"td"),a(369,"\u83B7\u53D6 group \u8282\u70B9\u5C55\u5F00\u72B6\u6001"),l(),d(370,"td")(371,"code"),a(372,"(nodeName: string) => boolean"),l()()(),d(373,"tr")(374,"td")(375,"code"),a(376,"expansionModel"),l()(),d(377,"td"),a(378,"\u5C55\u5F00\u8282\u70B9\u5B58\u50A8\u5BF9\u8C61"),l(),d(379,"td")(380,"code"),a(381,"SelectionModel<string>"),l()()()()(),d(382,"h3",44)(383,"span"),a(384,"NzGraphLayoutConfig"),l(),d(385,"a",45),a(386,"#"),l()(),d(387,"table")(388,"thead")(389,"tr")(390,"th"),a(391,"\u5C5E\u6027"),l(),d(392,"th"),a(393,"\u8BF4\u660E"),l(),d(394,"th"),a(395,"\u7C7B\u578B"),l()()(),d(396,"tbody")(397,"tr")(398,"td")(399,"code"),a(400,"layout"),l()(),d(401,"td"),a(402,"\u5E03\u5C40\u53C2\u6570"),l(),d(403,"td")(404,"code"),a(405,"{ nodeSep: number; rankSep: number; edgeSep: number; }"),l()()(),d(406,"tr")(407,"td")(408,"code"),a(409,"subScene"),l()(),d(410,"td"),a(411,"group \u8282\u70B9"),l(),d(412,"td")(413,"code"),a(414,"{ paddingTop: number; paddingBottom: number; paddingLeft: number; paddingRight: number; labelHeight: number; }"),l()()(),d(415,"tr")(416,"td")(417,"code"),a(418,"defaultCompoundNode"),l()(),d(419,"td"),a(420,"group \u8282\u70B9 size"),l(),d(421,"td")(422,"code"),a(423,"{ width: number; height: number; maxLabelWidth: number; }"),l()()(),d(424,"tr")(425,"td")(426,"code"),a(427,"defaultNode"),l()(),d(428,"td"),a(429,"\u9ED8\u8BA4\u8282\u70B9 size"),l(),d(430,"td")(431,"code"),a(432,"{ width: number; height: number; labelOffset: number; maxLabelWidth: number; }"),l()()()()(),d(433,"h4",46)(434,"span"),a(435,"NzGraphDataDef"),l(),d(436,"a",47),a(437,"#"),l()(),d(438,"table")(439,"thead")(440,"tr")(441,"th"),a(442,"\u5C5E\u6027"),l(),d(443,"th"),a(444,"\u8BF4\u660E"),l(),d(445,"th"),a(446,"\u7C7B\u578B"),l(),d(447,"th"),a(448,"\u9ED8\u8BA4\u503C"),l()()(),d(449,"tbody")(450,"tr")(451,"td")(452,"code"),a(453,"nodes"),l()(),d(454,"td"),a(455,"\u8282\u70B9"),l(),d(456,"td")(457,"code"),a(458,"Array<{ id: number|string; label?: string; width?: number; height?: number; [key: string]: any; }>"),l()(),d(459,"td")(460,"code"),a(461,"[]"),l()()(),d(462,"tr")(463,"td")(464,"code"),a(465,"edges"),l()(),d(466,"td"),a(467,"\u7EBF"),l(),d(468,"td")(469,"code"),a(470,"Array<{ v: number|string; w: number|string; [key: string]: any; }>"),l()(),d(471,"td")(472,"code"),a(473,"[]"),l()()(),d(474,"tr")(475,"td")(476,"code"),a(477,"compound"),l()(),d(478,"td"),a(479,"\u5206\u7EC4"),l(),d(480,"td")(481,"code"),a(482,"{ [parent: string]: string[]; }"),l()(),d(483,"td")(484,"code"),a(485,"null"),l()()()()(),d(486,"h4",48)(487,"span"),a(488,"NzGraphNode"),l(),d(489,"a",49),a(490,"#"),l()(),d(491,"table")(492,"thead")(493,"tr")(494,"th"),a(495,"\u5C5E\u6027"),l(),d(496,"th"),a(497,"\u8BF4\u660E"),l(),d(498,"th"),a(499,"\u7C7B\u578B"),l()()(),d(500,"tbody")(501,"tr")(502,"td")(503,"code"),a(504,"id"),l()(),d(505,"td"),a(506,"id"),l(),d(507,"td")(508,"code"),a(509,"number|string"),l()()(),d(510,"tr")(511,"td")(512,"code"),a(513,"label?"),l()(),d(514,"td"),a(515,"\u8282\u70B9\u5185\u5BB9"),l(),d(516,"td")(517,"code"),a(518,"string"),l()()(),d(519,"tr")(520,"td")(521,"code"),a(522,"name"),l()(),d(523,"td"),a(524,"\u8282\u70B9\u540D\u79F0"),l(),d(525,"td")(526,"code"),a(527,"number|string"),l()()(),d(528,"tr")(529,"td")(530,"code"),a(531,"type"),l()(),d(532,"td"),a(533,"\u8282\u70B9\u7C7B\u578B(\u7EC4: 0, \u8282\u70B9: 1)"),l(),d(534,"td")(535,"code"),a(536,"number"),l()()(),d(537,"tr")(538,"td")(539,"code"),a(540,"parentNodeName"),l()(),d(541,"td"),a(542,"\u7236\u8282\u70B9\u540D\u79F0"),l(),d(543,"td")(544,"code"),a(545,"string"),l()()(),d(546,"tr")(547,"td")(548,"code"),a(549,"coreBox"),l()(),d(550,"td"),a(551,"\u5E03\u5C40\u9AD8\u5BBD"),l(),d(552,"td")(553,"code"),a(554,"{ width: number; height: number; }"),l()()(),d(555,"tr")(556,"td")(557,"code"),a(558,"xOffset"),l()(),d(559,"td"),a(560,"x \u504F\u79FB"),l(),d(561,"td")(562,"code"),a(563,"number"),l()()(),d(564,"tr")(565,"td")(566,"code"),a(567,"yOffset"),l()(),d(568,"td"),a(569,"y \u504F\u79FB"),l(),d(570,"td")(571,"code"),a(572,"number"),l()()(),d(573,"tr")(574,"td")(575,"code"),a(576,"width"),l()(),d(577,"td"),a(578,"\u5BBD\u5EA6"),l(),d(579,"td")(580,"code"),a(581,"number"),l()()(),d(582,"tr")(583,"td")(584,"code"),a(585,"height"),l()(),d(586,"td"),a(587,"\u9AD8\u5EA6"),l(),d(588,"td")(589,"code"),a(590,"number"),l()()(),d(591,"tr")(592,"td")(593,"code"),a(594,"[key: string]"),l()(),d(595,"td"),a(596,"\u7528\u6237\u8F93\u5165"),l(),d(597,"td")(598,"code"),a(599,"any"),l()()()()(),d(600,"h4",50)(601,"span"),a(602,"NzGraphEdge"),l(),d(603,"a",51),a(604,"#"),l()(),d(605,"table")(606,"thead")(607,"tr")(608,"th"),a(609,"\u5C5E\u6027"),l(),d(610,"th"),a(611,"\u8BF4\u660E"),l(),d(612,"th"),a(613,"\u7C7B\u578B"),l()()(),d(614,"tbody")(615,"tr")(616,"td")(617,"code"),a(618,"id"),l()(),d(619,"td"),a(620,"id"),l(),d(621,"td")(622,"code"),a(623,"string"),l()()(),d(624,"tr")(625,"td")(626,"code"),a(627,"v"),l()(),d(628,"td"),a(629,"\u8D77\u59CB\u8282\u70B9"),l(),d(630,"td")(631,"code"),a(632,"number|string"),l()()(),d(633,"tr")(634,"td")(635,"code"),a(636,"w"),l()(),d(637,"td"),a(638,"\u76EE\u6807\u8282\u70B9"),l(),d(639,"td")(640,"code"),a(641,"number|string"),l()()(),d(642,"tr")(643,"td")(644,"code"),a(645,"label?"),l()(),d(646,"td"),a(647,"\u7EBF\u5185\u5BB9"),l(),d(648,"td")(649,"code"),a(650,"string"),l()()(),d(651,"tr")(652,"td")(653,"code"),a(654,"points"),l()(),d(655,"td"),a(656,"points"),l(),d(657,"td")(658,"code"),a(659,"Array<{ x: number; y: number; }>"),l()()()()(),d(660,"h4",52)(661,"span"),a(662,"NzGraphGroupNode"),l(),d(663,"a",53),a(664,"#"),l()(),d(665,"table")(666,"thead")(667,"tr")(668,"th"),a(669,"\u5C5E\u6027"),l(),d(670,"th"),a(671,"\u7C7B\u578B"),l()()(),d(672,"tbody")(673,"tr")(674,"td")(675,"code"),a(676,"expanded"),l()(),d(677,"td")(678,"code"),a(679,"boolean"),l()()(),d(680,"tr")(681,"td")(682,"code"),a(683,"nodes"),l()(),d(684,"td")(685,"code"),a(686,"Array<NzGraphNode|NzGraphGroupNode>"),l()()(),d(687,"tr")(688,"td")(689,"code"),a(690,"edges"),l()(),d(691,"td")(692,"code"),a(693,"NzGraphEdge[]"),l()()()()(),d(694,"h3",54)(695,"span"),a(696,"[nzGraphNode]"),l(),d(697,"label",40),a(698,"directive"),l(),d(699,"a",55),a(700,"#"),l()(),d(701,"p"),a(702,"\u81EA\u5B9A\u4E49\u53F6\u5B50\u8282\u70B9\u6E32\u67D3\u6A21\u677F"),l(),d(703,"pre",56)(704,"code")(705,"span",57)(706,"span",57)(707,"span",16),a(708,"<"),l(),a(709,"nz-graph"),l(),a(710," "),d(711,"span",58),a(712,"[nzGraphData]"),l(),d(713,"span",59)(714,"span",16),a(715,"="),l(),d(716,"span",16),a(717,'"'),l(),a(718,"data"),d(719,"span",16),a(720,'"'),l()(),d(721,"span",16),a(722,">"),l()(),a(723,`
`),d(724,"span",57)(725,"span",57)(726,"span",16),a(727,"<"),l(),a(728,"ng-container"),l(),a(729," "),d(730,"span",58),a(731,"*nzGraphNode"),l(),d(732,"span",59)(733,"span",16),a(734,"="),l(),d(735,"span",16),a(736,'"'),l(),a(737,"let node"),d(738,"span",16),a(739,'"'),l()(),d(740,"span",16),a(741,">"),l()(),a(742,`
`),d(743,"span",57)(744,"span",57)(745,"span",16),a(746,"<"),l(),a(747,"span"),l(),d(748,"span",16),a(749,">"),l()(),a(750,"{{ node.name }} - {{ node.label }}"),d(751,"span",57)(752,"span",57)(753,"span",16),a(754,"</"),l(),a(755,"span"),l(),d(756,"span",16),a(757,">"),l()(),a(758,`
`),d(759,"span",57)(760,"span",57)(761,"span",16),a(762,"</"),l(),a(763,"ng-container"),l(),d(764,"span",16),a(765,">"),l()(),a(766,`
`),d(767,"span",57)(768,"span",57)(769,"span",16),a(770,"</"),l(),a(771,"nz-graph"),l(),d(772,"span",16),a(773,">"),l()()()(),d(774,"h3",60)(775,"span"),a(776,"[nzGraphGroupNode]"),l(),d(777,"label",40),a(778,"directive"),l(),d(779,"a",61),a(780,"#"),l()(),d(781,"p"),a(782,"\u81EA\u5B9A\u4E49\u7EC4\u8282\u70B9\u6E32\u67D3\u6A21\u677F"),l(),d(783,"pre",56)(784,"code")(785,"span",57)(786,"span",57)(787,"span",16),a(788,"<"),l(),a(789,"nz-graph"),l(),a(790," "),d(791,"span",58),a(792,"[nzGraphData]"),l(),d(793,"span",59)(794,"span",16),a(795,"="),l(),d(796,"span",16),a(797,'"'),l(),a(798,"data"),d(799,"span",16),a(800,'"'),l()(),d(801,"span",16),a(802,">"),l()(),a(803,`
`),d(804,"span",57)(805,"span",57)(806,"span",16),a(807,"<"),l(),a(808,"ng-container"),l(),a(809," "),d(810,"span",58),a(811,"*nzGraphGroupNode"),l(),d(812,"span",59)(813,"span",16),a(814,"="),l(),d(815,"span",16),a(816,'"'),l(),a(817,"let node"),d(818,"span",16),a(819,'"'),l()(),d(820,"span",16),a(821,">"),l()(),a(822,`
`),d(823,"span",57)(824,"span",57)(825,"span",16),a(826,"<"),l(),a(827,"span"),l(),d(828,"span",16),a(829,">"),l()(),a(830,"{{ node.name }} - {{ node.label }}"),d(831,"span",57)(832,"span",57)(833,"span",16),a(834,"</"),l(),a(835,"span"),l(),d(836,"span",16),a(837,">"),l()(),a(838,`
`),d(839,"span",57)(840,"span",57)(841,"span",16),a(842,"</"),l(),a(843,"ng-container"),l(),d(844,"span",16),a(845,">"),l()(),a(846,`
`),d(847,"span",57)(848,"span",57)(849,"span",16),a(850,"</"),l(),a(851,"nz-graph"),l(),d(852,"span",16),a(853,">"),l()()()(),d(854,"h3",62)(855,"span"),a(856,"[nzGraphEdge]"),l(),d(857,"label",40),a(858,"directive"),l(),d(859,"a",63),a(860,"#"),l()(),d(861,"p"),a(862,"\u81EA\u5B9A\u4E49\u8FB9\u6E32\u67D3\u6A21\u677F"),l(),d(863,"pre",56)(864,"code")(865,"span",57)(866,"span",57)(867,"span",16),a(868,"<"),l(),a(869,"nz-graph"),l(),a(870," "),d(871,"span",58),a(872,"[nzGraphData]"),l(),d(873,"span",59)(874,"span",16),a(875,"="),l(),d(876,"span",16),a(877,'"'),l(),a(878,"data"),d(879,"span",16),a(880,'"'),l()(),d(881,"span",16),a(882,">"),l()(),a(883,`
`),d(884,"span",57)(885,"span",57)(886,"span",16),a(887,"<"),l(),a(888,"ng-container"),l(),a(889," "),d(890,"span",58),a(891,"*nzGraphEdge"),l(),d(892,"span",59)(893,"span",16),a(894,"="),l(),d(895,"span",16),a(896,'"'),l(),a(897,"let edge"),d(898,"span",16),a(899,'"'),l()(),d(900,"span",16),a(901,">"),l()(),a(902,`
`),d(903,"span",57)(904,"span",57)(905,"span",16),a(906,"<"),l(),d(907,"span",64),a(908,"svg:"),l(),a(909,"g"),l(),d(910,"span",16),a(911,">"),l()(),a(912,`
`),d(913,"span",57)(914,"span",57)(915,"span",16),a(916,"<"),l(),a(917,"path"),l(),d(918,"span",16),a(919,">"),l()(),d(920,"span",57)(921,"span",57)(922,"span",16),a(923,"</"),l(),a(924,"path"),l(),d(925,"span",16),a(926,">"),l()(),a(927,`
`),d(928,"span",57)(929,"span",57)(930,"span",16),a(931,"</"),l(),d(932,"span",64),a(933,"svg:"),l(),a(934,"g"),l(),d(935,"span",16),a(936,">"),l()(),a(937,`
`),d(938,"span",57)(939,"span",57)(940,"span",16),a(941,"</"),l(),a(942,"ng-container"),l(),d(943,"span",16),a(944,">"),l()(),a(945,`
`),d(946,"span",57)(947,"span",57)(948,"span",16),a(949,"</"),l(),a(950,"nz-graph"),l(),d(951,"span",16),a(952,">"),l()()()(),d(953,"h3",65)(954,"span"),a(955,"\u6837\u5F0F"),l(),d(956,"a",66),a(957,"#"),l()(),d(958,"p"),a(959,"\u7EC4\u4EF6\u6837\u5F0F\u5305\u542B\u4E86\u5FC5\u8981\u7684\u5C5E\u6027\u548C\u7B80\u5355\u7684\u6837\u5F0F\uFF0C\u4F60\u53EF\u4EE5\u901A\u8FC7\u8986\u5199\u4E0B\u5217\u7C7B\u540D\u81EA\u5B9A\u4E49\u6837\u5F0F\u3002"),l(),d(960,"ul")(961,"li")(962,"code"),a(963,".nz-graph"),l(),d(964,"code"),a(965,"nz-graph"),l(),a(966," \u7EC4\u4EF6\u547D\u540D\u7A7A\u95F4"),l(),d(967,"li")(968,"code"),a(969,".nz-graph-nodes"),l(),a(970," \u8282\u70B9"),d(971,"ul")(972,"li")(973,"code"),a(974,".nz-graph-node"),l(),a(975," \u5355\u4E2A\u8282\u70B9"),l(),d(976,"li")(977,"code"),a(978,".nz-graph-node-expanded"),l(),a(979," \u5C55\u5F00\u8282\u70B9"),l(),d(980,"li")(981,"code"),a(982,".nz-graph-group-node"),l(),a(983," \u7EC4\u8282\u70B9"),l(),d(984,"li")(985,"code"),a(986,".nz-graph-base-node"),l(),a(987," \u53F6\u5B50\u8282\u70B9"),l()()(),d(988,"li")(989,"code"),a(990,".nz-graph-edges"),l(),a(991," \u8FDE\u63A5\u7EBF"),d(992,"ul")(993,"li")(994,"code"),a(995,".nz-graph-edge"),l(),a(996," \u5355\u6761\u7EBF"),d(997,"ul")(998,"li")(999,"code"),a(1e3,"path.nz-graph-edge-line"),l(),a(1001," \u7EBF path \u5143\u7D20"),l(),d(1002,"li")(1003,"code"),a(1004,".nz-graph-edge-text"),l(),a(1005," \u7EBF\u6587\u672C\u5143\u7D20"),l()()()()()(),d(1006,"h2",67)(1007,"span"),a(1008,"\u8BF4\u660E"),l(),d(1009,"a",68),a(1010,"#"),l()(),d(1011,"ul")(1012,"li")(1013,"a",69),a(1014,"dagre-compound"),l(),a(1015,": \u57FA\u4E8E Dagre \u7684 \u5D4C\u5957\u5E03\u5C40\u8BA1\u7B97\u5E93"),l(),d(1016,"li")(1017,"a",70),a(1018,"SelectionModel"),l()()(),At(),l()()),r&2&&(I(),P("nzOffsetTop",16),I(),P("nzAffix",!1),I(71),P("nzGutter",8),I(),P("nzSpan",24),I(),P("nzId","components-graph-demo-customized")("nzLink","components-graph-demo-customized")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/graph/demo/customized.md"))},dependencies:[It,Sn,wn,bn,zn,_n,kn,Cn,le,Mi],encapsulation:2});let t=e;return t})();var sd=(()=>{let e=class e{constructor(){this.expanded=!1}goLink(i){window&&(window.location.hash=i)}expandAllCode(){this.expanded=!this.expanded,this.codeBoxes.forEach(i=>i.expandCode(this.expanded))}};e.\u0275fac=function(r){return new(r||e)},e.\u0275cmp=mt({type:e,selectors:[["nz-demo-graph"]],viewQuery:function(r,o){if(r&1&&yt(It,5),r&2){let s;nt(s=it())&&(o.codeBoxes=s)}},decls:1023,vars:8,consts:[[1,"toc-affix",3,"nzOffsetTop"],["nzShowInkInFixed","",3,"nzClick","nzAffix"],["nzHref","#components-graph-demo-customized","nzTitle","Custom graph node"],["nzHref","#api","nzTitle","API"],[1,"markdown"],[1,"subtitle"],[1,"widget"],["aria-label","Edit this page on Github","href","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/graph/doc/index.en-US.md","target","_blank","rel","noopener noreferrer",1,"edit-button"],["nz-icon","","nzType","edit"],[2,"border-color","#faad14"],["id","when-to-use"],["onclick","window.location.hash = 'when-to-use'",1,"anchor"],["id","import-module"],["onclick","window.location.hash = 'import-module'",1,"anchor"],[1,"language-ts"],[1,"token","keyword"],[1,"token","punctuation"],[1,"token","string"],["id","import-style"],["onclick","window.location.hash = 'import-style'",1,"anchor"],[1,"language-less"],[1,"token","variable"],["nz-icon","","nzType","appstore","nz-tooltip","","nzTooltipTitle","Expand All Code",1,"code-box-expand-trigger",3,"click"],["nz-row","",3,"nzGutter"],["nz-col","",3,"nzSpan"],["nzTitle","Custom graph node","nzSelector","nz-demo-graph-customized","nzGenerateCommand","ng g ng-zorro-antd:graph-customized <name>","nzComponentName","NzDemoGraphCustomizedComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["demo",""],["intro",""],[1,"markdown","api-container"],["id","api"],["onclick","window.location.hash = 'api'",1,"anchor"],[1,"language-sh"],[1,"token","operator"],["id","nz-graph:standalone"],[1,"api-type-label","component"],[1,"api-type-label","standalone"],["onclick","window.location.hash = 'nz-graph:standalone'",1,"anchor"],["id","methods"],["onclick","window.location.hash = 'methods'",1,"anchor"],["id","[nz-graph-zoom]:standalone"],[1,"api-type-label","directive"],["onclick","window.location.hash = '[nz-graph-zoom]:standalone'",1,"anchor"],["id","nzgraphdata"],["onclick","window.location.hash = 'nzgraphdata'",1,"anchor"],["id","nzgraphlayoutconfig"],["onclick","window.location.hash = 'nzgraphlayoutconfig'",1,"anchor"],["id","nzgraphdatadef"],["onclick","window.location.hash = 'nzgraphdatadef'",1,"anchor"],["id","nzgraphnode"],["onclick","window.location.hash = 'nzgraphnode'",1,"anchor"],["id","nzgraphedge"],["onclick","window.location.hash = 'nzgraphedge'",1,"anchor"],["id","nzgraphgroupnode"],["onclick","window.location.hash = 'nzgraphgroupnode'",1,"anchor"],["id","[nzgraphnode]"],["onclick","window.location.hash = '[nzgraphnode]'",1,"anchor"],[1,"language-html"],[1,"token","tag"],[1,"token","attr-name"],[1,"token","attr-value"],["id","[nzgraphgroupnode]"],["onclick","window.location.hash = '[nzgraphgroupnode]'",1,"anchor"],["id","[nzgraphedge]"],["onclick","window.location.hash = '[nzgraphedge]'",1,"anchor"],[1,"token","namespace"],["id","styling"],["onclick","window.location.hash = 'styling'",1,"anchor"],["id","more"],["onclick","window.location.hash = 'more'",1,"anchor"],["href","https://www.npmjs.com/package/dagre-compound","target","_blank","rel","noopener"],["href","https://github.com/angular/components/blob/master/src/cdk/collections/selection-model.ts","target","_blank","rel","noopener"]],template:function(r,o){r&1&&(d(0,"article")(1,"nz-affix",0)(2,"nz-anchor",1),et("nzClick",function(u){return o.goLink(u)}),U(3,"nz-link",2)(4,"nz-link",3),l()(),d(5,"section",4)(6,"h1"),a(7,"Graph"),U(8,"span",5)(9,"span",6),d(10,"a",7),U(11,"span",8),l()(),d(12,"section",4),Bt(),d(13,"blockquote",9)(14,"p"),a(15,"NG-ZORRO experiments are features that are released but not yet considered stable or production ready"),l(),d(16,"p"),a(17,"Developers and users can opt-in into these features before they are fully released. But "),d(18,"strong"),a(19,"breaking changes"),l(),a(20," may occur with any release."),l()(),d(21,"h2",10)(22,"span"),a(23,"When To Use"),l(),d(24,"a",11),a(25,"#"),l()(),d(26,"p"),a(27,"When you want to use graph in Angular."),l(),d(28,"h3",12)(29,"span"),a(30,"Import Module"),l(),d(31,"a",13),a(32,"#"),l()(),d(33,"blockquote")(34,"p"),a(35,"Now, the graph depends on d3-drag d3-zoom d3-selection d3-transition d3-shape (may be removed in next major version)"),l()(),d(36,"pre",14)(37,"code")(38,"span",15),a(39,"import"),l(),a(40," "),d(41,"span",16),a(42,"{"),l(),a(43," NzGraphModule "),d(44,"span",16),a(45,"}"),l(),a(46," "),d(47,"span",15),a(48,"from"),l(),a(49," "),d(50,"span",17),a(51,"'ng-zorro-antd/graph'"),l(),d(52,"span",16),a(53,";"),l()()(),d(54,"h3",18)(55,"span"),a(56,"Import Style"),l(),d(57,"a",19),a(58,"#"),l()(),d(59,"pre",20)(60,"code")(61,"span",21),a(62,"@import"),l(),a(63," "),d(64,"span",17),a(65,"'node_modules/ng-zorro-antd/graph/style/entry.less'"),l(),d(66,"span",16),a(67,";"),l()()(),At(),l(),d(68,"h2")(69,"span"),a(70,"Examples"),l(),d(71,"span",22),et("click",function(){return o.expandAllCode()}),l()()(),d(72,"div",23)(73,"div",24)(74,"nz-code-box",25),U(75,"nz-demo-graph-customized",26),d(76,"div",27),Bt(),d(77,"p"),a(78,"Custom node style of graph."),l(),At(),l()()()(),d(79,"section",28),Bt(),d(80,"h2",29)(81,"span"),a(82,"API"),l(),d(83,"a",30),a(84,"#"),l()(),d(85,"p"),a(86,"Dependencies:"),l(),d(87,"pre",31)(88,"code"),a(89,"npm install dagre"),d(90,"span",32),a(91,"-"),l(),a(92,"compound dagre d3"),d(93,"span",32),a(94,"-"),l(),a(95,"transition d3"),d(96,"span",32),a(97,"-"),l(),a(98,"zoom d3"),d(99,"span",32),a(100,"-"),l(),a(101,"selection d3"),d(102,"span",32),a(103,"-"),l(),a(104,"shape d3"),d(105,"span",32),a(106,"-"),l(),a(107,"drag "),d(108,"span",21),a(109,"@types"),l(),d(110,"span",32),a(111,"/"),l(),a(112,"d3"),l()(),d(113,"h3",33)(114,"span"),a(115,"nz-graph"),l(),d(116,"label",34),a(117,"component"),l(),d(118,"label",35),a(119,"standalone"),l(),d(120,"a",36),a(121,"#"),l()(),d(122,"table")(123,"thead")(124,"tr")(125,"th"),a(126,"Parameter"),l(),d(127,"th"),a(128,"Description"),l(),d(129,"th"),a(130,"Type"),l(),d(131,"th"),a(132,"Default"),l()()(),d(133,"tbody")(134,"tr")(135,"td")(136,"code"),a(137,"[nzGraphData]"),l()(),d(138,"td"),a(139,"Data source"),l(),d(140,"td")(141,"code"),a(142,"NzGraphData(data: NzGraphDataDef?)"),l()(),d(143,"td"),a(144,"``"),l()(),d(145,"tr")(146,"td")(147,"code"),a(148,"[nzRankDirection]"),l()(),d(149,"td"),a(150,"Graph Direction"),l(),d(151,"td")(152,"code"),a(153,"TB"),l(),a(154," | "),d(155,"code"),a(156,"BT"),l(),a(157," | "),d(158,"code"),a(159,"LR"),l(),a(160," | "),d(161,"code"),a(162,"RL"),l()(),d(163,"td")(164,"code"),a(165,"LR"),l()()(),d(166,"tr")(167,"td")(168,"code"),a(169,"[nzAutoSize]"),l()(),d(170,"td"),a(171,"Whether to automatically adjust the height of the node, the default equal height"),l(),d(172,"td")(173,"code"),a(174,"boolean"),l()(),d(175,"td")(176,"code"),a(177,"false"),l()()(),d(178,"tr")(179,"td")(180,"code"),a(181,"[nzGraphLayoutConfig]"),l()(),d(182,"td"),a(183,"Global config of graph"),l(),d(184,"td")(185,"code"),a(186,"NzGraphLayoutConfig"),l()(),d(187,"td"),a(188,"``"),l()()()(),d(189,"h4",37)(190,"span"),a(191,"Methods"),l(),d(192,"a",38),a(193,"#"),l()(),d(194,"table")(195,"thead")(196,"tr")(197,"th"),a(198,"Method"),l(),d(199,"th"),a(200,"Description"),l()()(),d(201,"tbody")(202,"tr")(203,"td")(204,"code"),a(205,"fitCenter()"),l()(),d(206,"td"),a(207,"Move graph to center(use "),d(208,"code"),a(209,"nz-graph-zoom"),l(),a(210," instead if zooming is enabled)"),l()()()(),d(211,"h3",39)(212,"span"),a(213,"[nz-graph-zoom]"),l(),d(214,"label",40),a(215,"directive"),l(),d(216,"label",35),a(217,"standalone"),l(),d(218,"a",41),a(219,"#"),l()(),d(220,"table")(221,"thead")(222,"tr")(223,"th"),a(224,"Parameter"),l(),d(225,"th"),a(226,"Description"),l(),d(227,"th"),a(228,"Type"),l(),d(229,"th"),a(230,"Default"),l()()(),d(231,"tbody")(232,"tr")(233,"td")(234,"code"),a(235,"[(nzZoom)]"),l()(),d(236,"td"),a(237,"Default zoom scale"),l(),d(238,"td")(239,"code"),a(240,"number"),l()(),d(241,"td")(242,"code"),a(243,"1"),l()()(),d(244,"tr")(245,"td")(246,"code"),a(247,"[nzMinZoom]"),l()(),d(248,"td"),a(249,"Minimum zoom scale"),l(),d(250,"td")(251,"code"),a(252,"number"),l()(),d(253,"td")(254,"code"),a(255,"0.1"),l()()(),d(256,"tr")(257,"td")(258,"code"),a(259,"[nzMaxZoom]"),l()(),d(260,"td"),a(261,"Maximum zoom scale"),l(),d(262,"td")(263,"code"),a(264,"number"),l()(),d(265,"td")(266,"code"),a(267,"10"),l()()(),d(268,"tr")(269,"td")(270,"code"),a(271,"(nzTransformEvent)"),l()(),d(272,"td"),a(273,"Event of zooming"),l(),d(274,"td")(275,"code"),a(276,"() => NzZoomTransform"),l()(),d(277,"td"),a(278,"``"),l()(),d(279,"tr")(280,"td")(281,"code"),a(282,"(fitCenter)"),l()(),d(283,"td"),a(284,"Move graph to center"),l(),d(285,"td")(286,"code"),a(287,"() => void"),l()(),d(288,"td")(289,"code"),a(290,"void"),l()()(),d(291,"tr")(292,"td")(293,"code"),a(294,"(focus)"),l()(),d(295,"td"),a(296,"Move target node to center"),l(),d(297,"td")(298,"code"),a(299,"(e: SVGGElement, duration: number) => void"),l()(),d(300,"td")(301,"code"),a(302,"void"),l()()()()(),d(303,"h4",42)(304,"span"),a(305,"NzGraphData"),l(),d(306,"a",43),a(307,"#"),l()(),d(308,"table")(309,"thead")(310,"tr")(311,"th"),a(312,"Method"),l(),d(313,"th"),a(314,"Description"),l(),d(315,"th"),a(316,"Type"),l()()(),d(317,"tbody")(318,"tr")(319,"td")(320,"code"),a(321,"setData"),l()(),d(322,"td"),a(323,"set data source"),l(),d(324,"td")(325,"code"),a(326,"(data: NzGraphDataDef) => void"),l()()(),d(327,"tr")(328,"td")(329,"code"),a(330,"toggle"),l()(),d(331,"td"),a(332,"toggle group node"),l(),d(333,"td")(334,"code"),a(335,"(nodeName: string) => void"),l()()(),d(336,"tr")(337,"td")(338,"code"),a(339,"expand"),l()(),d(340,"td"),a(341,"expand group node"),l(),d(342,"td")(343,"code"),a(344,"(nodeName: string) => void"),l()()(),d(345,"tr")(346,"td")(347,"code"),a(348,"expandAll"),l()(),d(349,"td"),a(350,"expand all group nodes"),l(),d(351,"td")(352,"code"),a(353,"(nodeName: string) => void"),l()()(),d(354,"tr")(355,"td")(356,"code"),a(357,"collapse"),l()(),d(358,"td"),a(359,"collapse group node"),l(),d(360,"td")(361,"code"),a(362,"(nodeName: string) => void"),l()()(),d(363,"tr")(364,"td")(365,"code"),a(366,"isExpand"),l()(),d(367,"td"),a(368,"get if expanded of node"),l(),d(369,"td")(370,"code"),a(371,"(nodeName: string) => boolean"),l()()(),d(372,"tr")(373,"td")(374,"code"),a(375,"expansionModel"),l()(),d(376,"td"),a(377,"model of expanded nodes' info"),l(),d(378,"td")(379,"code"),a(380,"SelectionModel<string>"),l()()()()(),d(381,"h3",44)(382,"span"),a(383,"NzGraphLayoutConfig"),l(),d(384,"a",45),a(385,"#"),l()(),d(386,"table")(387,"thead")(388,"tr")(389,"th"),a(390,"Method"),l(),d(391,"th"),a(392,"Description"),l(),d(393,"th"),a(394,"Type"),l()()(),d(395,"tbody")(396,"tr")(397,"td")(398,"code"),a(399,"layout"),l()(),d(400,"td"),a(401,"graph layout config"),l(),d(402,"td")(403,"code"),a(404,"{ nodeSep: number; rankSep: number; edgeSep: number; }"),l()()(),d(405,"tr")(406,"td")(407,"code"),a(408,"subScene"),l()(),d(409,"td"),a(410,"group node config"),l(),d(411,"td")(412,"code"),a(413,"{ paddingTop: number; paddingBottom: number; paddingLeft: number; paddingRight: number; labelHeight: number; }"),l()()(),d(414,"tr")(415,"td")(416,"code"),a(417,"defaultCompoundNode"),l()(),d(418,"td"),a(419,"group node size"),l(),d(420,"td")(421,"code"),a(422,"{ width: number; height: number; maxLabelWidth: number; }"),l()()(),d(423,"tr")(424,"td")(425,"code"),a(426,"defaultNode"),l()(),d(427,"td"),a(428,"default node size"),l(),d(429,"td")(430,"code"),a(431,"{ width: number; height: number; labelOffset: number; maxLabelWidth: number; }"),l()()()()(),d(432,"h4",46)(433,"span"),a(434,"NzGraphDataDef"),l(),d(435,"a",47),a(436,"#"),l()(),d(437,"table")(438,"thead")(439,"tr")(440,"th"),a(441,"Parameter"),l(),d(442,"th"),a(443,"Description"),l(),d(444,"th"),a(445,"Type"),l(),d(446,"th"),a(447,"Default"),l()()(),d(448,"tbody")(449,"tr")(450,"td")(451,"code"),a(452,"nodes"),l()(),d(453,"td"),a(454,"nodes"),l(),d(455,"td")(456,"code"),a(457,"Array<{ id: number|string; label?: string; width?: number; height?: number; [key: string]: any; }>"),l()(),d(458,"td")(459,"code"),a(460,"[]"),l()()(),d(461,"tr")(462,"td")(463,"code"),a(464,"edges"),l()(),d(465,"td"),a(466,"edges"),l(),d(467,"td")(468,"code"),a(469,"Array<{ v: number|string; w: number|string; [key: string]: any; }>"),l()(),d(470,"td")(471,"code"),a(472,"[]"),l()()(),d(473,"tr")(474,"td")(475,"code"),a(476,"compound"),l()(),d(477,"td"),a(478,"group"),l(),d(479,"td")(480,"code"),a(481,"{ [parent: string]: string[]; }"),l()(),d(482,"td")(483,"code"),a(484,"null"),l()()()()(),d(485,"h4",48)(486,"span"),a(487,"NzGraphNode"),l(),d(488,"a",49),a(489,"#"),l()(),d(490,"table")(491,"thead")(492,"tr")(493,"th"),a(494,"Parameter"),l(),d(495,"th"),a(496,"Description"),l(),d(497,"th"),a(498,"Type"),l()()(),d(499,"tbody")(500,"tr")(501,"td")(502,"code"),a(503,"id"),l()(),d(504,"td"),a(505,"id"),l(),d(506,"td")(507,"code"),a(508,"number|string"),l()()(),d(509,"tr")(510,"td")(511,"code"),a(512,"label?"),l()(),d(513,"td"),a(514,"node content"),l(),d(515,"td")(516,"code"),a(517,"string"),l()()(),d(518,"tr")(519,"td")(520,"code"),a(521,"name"),l()(),d(522,"td"),a(523,"node name"),l(),d(524,"td")(525,"code"),a(526,"number|string"),l()()(),d(527,"tr")(528,"td")(529,"code"),a(530,"type"),l()(),d(531,"td"),a(532,"node type(group: 0, node: 1)"),l(),d(533,"td")(534,"code"),a(535,"number"),l()()(),d(536,"tr")(537,"td")(538,"code"),a(539,"parentNodeName"),l()(),d(540,"td"),a(541,"parentNode name"),l(),d(542,"td")(543,"code"),a(544,"string"),l()()(),d(545,"tr")(546,"td")(547,"code"),a(548,"coreBox"),l()(),d(549,"td"),a(550,"coreBox"),l(),d(551,"td")(552,"code"),a(553,"{ width: number; height: number; }"),l()()(),d(554,"tr")(555,"td")(556,"code"),a(557,"xOffset"),l()(),d(558,"td"),a(559,"x-offset"),l(),d(560,"td")(561,"code"),a(562,"number"),l()()(),d(563,"tr")(564,"td")(565,"code"),a(566,"yOffset"),l()(),d(567,"td"),a(568,"y-offset"),l(),d(569,"td")(570,"code"),a(571,"number"),l()()(),d(572,"tr")(573,"td")(574,"code"),a(575,"width"),l()(),d(576,"td"),a(577,"width"),l(),d(578,"td")(579,"code"),a(580,"number"),l()()(),d(581,"tr")(582,"td")(583,"code"),a(584,"height"),l()(),d(585,"td"),a(586,"height"),l(),d(587,"td")(588,"code"),a(589,"number"),l()()(),d(590,"tr")(591,"td")(592,"code"),a(593,"[key: string]"),l()(),d(594,"td"),a(595,"user inputs"),l(),d(596,"td")(597,"code"),a(598,"any"),l()()()()(),d(599,"h4",50)(600,"span"),a(601,"NzGraphEdge"),l(),d(602,"a",51),a(603,"#"),l()(),d(604,"table")(605,"thead")(606,"tr")(607,"th"),a(608,"Parameter"),l(),d(609,"th"),a(610,"Description"),l(),d(611,"th"),a(612,"Type"),l()()(),d(613,"tbody")(614,"tr")(615,"td")(616,"code"),a(617,"id"),l()(),d(618,"td"),a(619,"id"),l(),d(620,"td")(621,"code"),a(622,"string"),l()()(),d(623,"tr")(624,"td")(625,"code"),a(626,"v"),l()(),d(627,"td"),a(628,"source node"),l(),d(629,"td")(630,"code"),a(631,"number|string"),l()()(),d(632,"tr")(633,"td")(634,"code"),a(635,"w"),l()(),d(636,"td"),a(637,"target node"),l(),d(638,"td")(639,"code"),a(640,"number|string"),l()()(),d(641,"tr")(642,"td")(643,"code"),a(644,"label?"),l()(),d(645,"td"),a(646,"edge content"),l(),d(647,"td")(648,"code"),a(649,"string"),l()()(),d(650,"tr")(651,"td")(652,"code"),a(653,"points"),l()(),d(654,"td"),a(655,"points"),l(),d(656,"td")(657,"code"),a(658,"Array<{ x: number; y: number; }>"),l()()()()(),d(659,"h4",52)(660,"span"),a(661,"NzGraphGroupNode"),l(),d(662,"a",53),a(663,"#"),l()(),d(664,"table")(665,"thead")(666,"tr")(667,"th"),a(668,"Parameter"),l(),d(669,"th"),a(670,"Type"),l()()(),d(671,"tbody")(672,"tr")(673,"td")(674,"code"),a(675,"expanded"),l()(),d(676,"td")(677,"code"),a(678,"boolean"),l()()(),d(679,"tr")(680,"td")(681,"code"),a(682,"nodes"),l()(),d(683,"td")(684,"code"),a(685,"Array<NzGraphNode|NzGraphGroupNode>"),l()()(),d(686,"tr")(687,"td")(688,"code"),a(689,"edges"),l()(),d(690,"td")(691,"code"),a(692,"NzGraphEdge[]"),l()()()()(),d(693,"h3",54)(694,"span"),a(695,"[nzGraphNode]"),l(),d(696,"label",40),a(697,"directive"),l(),d(698,"a",55),a(699,"#"),l()(),d(700,"p"),a(701,"Customize the graph node template"),l(),d(702,"pre",56)(703,"code")(704,"span",57)(705,"span",57)(706,"span",16),a(707,"<"),l(),a(708,"nz-graph"),l(),a(709," "),d(710,"span",58),a(711,"[nzGraphData]"),l(),d(712,"span",59)(713,"span",16),a(714,"="),l(),d(715,"span",16),a(716,'"'),l(),a(717,"data"),d(718,"span",16),a(719,'"'),l()(),d(720,"span",16),a(721,">"),l()(),a(722,`
`),d(723,"span",57)(724,"span",57)(725,"span",16),a(726,"<"),l(),a(727,"ng-container"),l(),a(728," "),d(729,"span",58),a(730,"*nzGraphNode"),l(),d(731,"span",59)(732,"span",16),a(733,"="),l(),d(734,"span",16),a(735,'"'),l(),a(736,"let node"),d(737,"span",16),a(738,'"'),l()(),d(739,"span",16),a(740,">"),l()(),a(741,`
`),d(742,"span",57)(743,"span",57)(744,"span",16),a(745,"<"),l(),a(746,"span"),l(),d(747,"span",16),a(748,">"),l()(),a(749,"{{ node.name }} - {{ node.label }}"),d(750,"span",57)(751,"span",57)(752,"span",16),a(753,"</"),l(),a(754,"span"),l(),d(755,"span",16),a(756,">"),l()(),a(757,`
`),d(758,"span",57)(759,"span",57)(760,"span",16),a(761,"</"),l(),a(762,"ng-container"),l(),d(763,"span",16),a(764,">"),l()(),a(765,`
`),d(766,"span",57)(767,"span",57)(768,"span",16),a(769,"</"),l(),a(770,"nz-graph"),l(),d(771,"span",16),a(772,">"),l()()()(),d(773,"h3",60)(774,"span"),a(775,"[nzGraphGroupNode]"),l(),d(776,"label",40),a(777,"directive"),l(),d(778,"a",61),a(779,"#"),l()(),d(780,"p"),a(781,"Customize the graph group-node template"),l(),d(782,"pre",56)(783,"code")(784,"span",57)(785,"span",57)(786,"span",16),a(787,"<"),l(),a(788,"nz-graph"),l(),a(789," "),d(790,"span",58),a(791,"[nzGraphData]"),l(),d(792,"span",59)(793,"span",16),a(794,"="),l(),d(795,"span",16),a(796,'"'),l(),a(797,"data"),d(798,"span",16),a(799,'"'),l()(),d(800,"span",16),a(801,">"),l()(),a(802,`
`),d(803,"span",57)(804,"span",57)(805,"span",16),a(806,"<"),l(),a(807,"ng-container"),l(),a(808," "),d(809,"span",58),a(810,"*nzGraphGroupNode"),l(),d(811,"span",59)(812,"span",16),a(813,"="),l(),d(814,"span",16),a(815,'"'),l(),a(816,"let node"),d(817,"span",16),a(818,'"'),l()(),d(819,"span",16),a(820,">"),l()(),a(821,`
`),d(822,"span",57)(823,"span",57)(824,"span",16),a(825,"<"),l(),a(826,"span"),l(),d(827,"span",16),a(828,">"),l()(),a(829,"{{ node.name }} - {{ node.label }}"),d(830,"span",57)(831,"span",57)(832,"span",16),a(833,"</"),l(),a(834,"span"),l(),d(835,"span",16),a(836,">"),l()(),a(837,`
`),d(838,"span",57)(839,"span",57)(840,"span",16),a(841,"</"),l(),a(842,"ng-container"),l(),d(843,"span",16),a(844,">"),l()(),a(845,`
`),d(846,"span",57)(847,"span",57)(848,"span",16),a(849,"</"),l(),a(850,"nz-graph"),l(),d(851,"span",16),a(852,">"),l()()()(),d(853,"h3",62)(854,"span"),a(855,"[nzGraphEdge]"),l(),d(856,"label",40),a(857,"directive"),l(),d(858,"a",63),a(859,"#"),l()(),d(860,"p"),a(861,"Customize the graph edge template"),l(),d(862,"pre",56)(863,"code")(864,"span",57)(865,"span",57)(866,"span",16),a(867,"<"),l(),a(868,"nz-graph"),l(),a(869," "),d(870,"span",58),a(871,"[nzGraphData]"),l(),d(872,"span",59)(873,"span",16),a(874,"="),l(),d(875,"span",16),a(876,'"'),l(),a(877,"data"),d(878,"span",16),a(879,'"'),l()(),d(880,"span",16),a(881,">"),l()(),a(882,`
`),d(883,"span",57)(884,"span",57)(885,"span",16),a(886,"<"),l(),a(887,"ng-container"),l(),a(888," "),d(889,"span",58),a(890,"*nzGraphEdge"),l(),d(891,"span",59)(892,"span",16),a(893,"="),l(),d(894,"span",16),a(895,'"'),l(),a(896,"let edge"),d(897,"span",16),a(898,'"'),l()(),d(899,"span",16),a(900,">"),l()(),a(901,`
`),d(902,"span",57)(903,"span",57)(904,"span",16),a(905,"<"),l(),d(906,"span",64),a(907,"svg:"),l(),a(908,"g"),l(),d(909,"span",16),a(910,">"),l()(),a(911,`
`),d(912,"span",57)(913,"span",57)(914,"span",16),a(915,"<"),l(),a(916,"path"),l(),d(917,"span",16),a(918,">"),l()(),d(919,"span",57)(920,"span",57)(921,"span",16),a(922,"</"),l(),a(923,"path"),l(),d(924,"span",16),a(925,">"),l()(),a(926,`
`),d(927,"span",57)(928,"span",57)(929,"span",16),a(930,"</"),l(),d(931,"span",64),a(932,"svg:"),l(),a(933,"g"),l(),d(934,"span",16),a(935,">"),l()(),a(936,`
`),d(937,"span",57)(938,"span",57)(939,"span",16),a(940,"</"),l(),a(941,"ng-container"),l(),d(942,"span",16),a(943,">"),l()(),a(944,`
`),d(945,"span",57)(946,"span",57)(947,"span",16),a(948,"</"),l(),a(949,"nz-graph"),l(),d(950,"span",16),a(951,">"),l()()()(),d(952,"h3",65)(953,"span"),a(954,"Styling"),l(),d(955,"a",66),a(956,"#"),l()(),d(957,"p"),a(958,"The Component styles only contain the necessary positional properties and simple styles, you can customize the style by overriding the following class."),l(),d(959,"ul")(960,"li")(961,"code"),a(962,".nz-graph"),l(),d(963,"code"),a(964,"nz-graph"),l(),a(965," The "),d(966,"code"),a(967,"nz-graph"),l(),a(968," component namespace"),l(),d(969,"li")(970,"code"),a(971,".nz-graph-nodes"),l(),a(972," The class name of container covered all nodes"),d(973,"ul")(974,"li")(975,"code"),a(976,".nz-graph-node"),l(),a(977," The class name of "),d(978,"code"),a(979,"nz-graph-node"),l()(),d(980,"li")(981,"code"),a(982,".nz-graph-node-expanded"),l(),a(983," The class name of expanded node"),l(),d(984,"li")(985,"code"),a(986,".nz-graph-group-node"),l(),a(987," The class name of group node"),l(),d(988,"li")(989,"code"),a(990,".nz-graph-base-node"),l(),a(991," The class name of leaf(OP) node"),l()()(),d(992,"li")(993,"code"),a(994,".nz-graph-edges"),l(),a(995," The class name of container covered edges in the target node"),d(996,"ul")(997,"li")(998,"code"),a(999,".nz-graph-edge"),l(),a(1e3," The class name of edge"),d(1001,"ul")(1002,"li")(1003,"code"),a(1004,"path.nz-graph-edge-line"),l(),a(1005," The class name of svg:path element"),l(),d(1006,"li")(1007,"code"),a(1008,".nz-graph-edge-text"),l(),a(1009," The class name of svg:text element"),l()()()()()(),d(1010,"h2",67)(1011,"span"),a(1012,"More"),l(),d(1013,"a",68),a(1014,"#"),l()(),d(1015,"ul")(1016,"li")(1017,"a",69),a(1018,"dagre-compound"),l(),a(1019,": Dagre-based nested layout calculation library"),l(),d(1020,"li")(1021,"a",70),a(1022,"SelectionModel"),l()()(),At(),l()()),r&2&&(I(),P("nzOffsetTop",16),I(),P("nzAffix",!1),I(70),P("nzGutter",8),I(),P("nzSpan",24),I(),P("nzId","components-graph-demo-customized")("nzLink","components-graph-demo-customized")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/graph/demo/customized.md"))},dependencies:[It,Sn,wn,bn,zn,_n,kn,Cn,le,Mi],encapsulation:2});let t=e;return t})();var u5=(()=>{let e=class e{};e.\u0275fac=function(r){return new(r||e)},e.\u0275mod=fn({type:e}),e.\u0275inj=hn({imports:[Zo,ed,Wo,Vo,Jo,Fo.forChild([{path:"en",component:sd},{path:"zh",component:ad}])]});let t=e;return t})();export{u5 as NzDemoGraphModule};