UNPKG

@chillicream/nitro-embedded

Version:
2 lines 1.18 MB
/*! For license information please see 670.c0fdf54a.chunk.js.LICENSE.txt */ (self.webpackChunknitro=self.webpackChunknitro||[]).push([[670],{8395:(e,t,n)=>{e.exports={graphlib:n(56497),layout:n(74809),debug:n(70692),util:{time:n(65795).time,notime:n(65795).notime},version:n(8563)}},37795:(e,t,n)=>{"use strict";let r=n(50476),o=n(65795).uniqueId;e.exports={run:function(e){("greedy"===e.graph().acyclicer?r(e,function(e){return t=>e.edge(t).weight}(e)):function(e){let t=[],n={},r={};function o(a){r.hasOwnProperty(a)||(r[a]=!0,n[a]=!0,e.outEdges(a).forEach((e=>{n.hasOwnProperty(e.w)?t.push(e):o(e.w)})),delete n[a])}return e.nodes().forEach(o),t}(e)).forEach((t=>{let n=e.edge(t);e.removeEdge(t),n.forwardName=t.name,n.reversed=!0,e.setEdge(t.w,t.v,n,o("rev"))}))},undo:function(e){e.edges().forEach((t=>{let n=e.edge(t);if(n.reversed){e.removeEdge(t);let r=n.forwardName;delete n.reversed,delete n.forwardName,e.setEdge(t.w,t.v,n,r)}}))}}},49298:(e,t,n)=>{let r=n(65795);function o(e,t,n,o,a,i){let s={width:0,height:0,rank:i,borderType:t},l=a[t][i-1],c=r.addDummyNode(e,"border",s,n);a[t][i]=c,e.setParent(c,o),l&&e.setEdge(l,c,{weight:1})}e.exports=function(e){e.children().forEach((function t(n){let r=e.children(n),a=e.node(n);if(r.length&&r.forEach(t),a.hasOwnProperty("minRank")){a.borderLeft=[],a.borderRight=[];for(let t=a.minRank,r=a.maxRank+1;t<r;++t)o(e,"borderLeft","_bl",n,a,t),o(e,"borderRight","_br",n,a,t)}}))}},6655:e=>{"use strict";function t(e){e.nodes().forEach((t=>n(e.node(t)))),e.edges().forEach((t=>n(e.edge(t))))}function n(e){let t=e.width;e.width=e.height,e.height=t}function r(e){e.y=-e.y}function o(e){let t=e.x;e.x=e.y,e.y=t}e.exports={adjust:function(e){let n=e.graph().rankdir.toLowerCase();"lr"!==n&&"rl"!==n||t(e)},undo:function(e){let n=e.graph().rankdir.toLowerCase();"bt"!==n&&"rl"!==n||function(e){e.nodes().forEach((t=>r(e.node(t)))),e.edges().forEach((t=>{let n=e.edge(t);n.points.forEach(r),n.hasOwnProperty("y")&&r(n)}))}(e);"lr"!==n&&"rl"!==n||(!function(e){e.nodes().forEach((t=>o(e.node(t)))),e.edges().forEach((t=>{let n=e.edge(t);n.points.forEach(o),n.hasOwnProperty("x")&&o(n)}))}(e),t(e))}}},71442:e=>{function t(e){e._prev._next=e._next,e._next._prev=e._prev,delete e._next,delete e._prev}function n(e,t){if("_next"!==e&&"_prev"!==e)return t}e.exports=class{constructor(){let e={};e._next=e._prev=e,this._sentinel=e}dequeue(){let e=this._sentinel,n=e._prev;if(n!==e)return t(n),n}enqueue(e){let n=this._sentinel;e._prev&&e._next&&t(e),e._next=n._next,n._next._prev=e,n._next=e,e._prev=n}toString(){let e=[],t=this._sentinel,r=t._prev;for(;r!==t;)e.push(JSON.stringify(r,n)),r=r._prev;return"["+e.join(", ")+"]"}}},70692:(e,t,n)=>{let r=n(65795),o=n(56497).Graph;e.exports={debugOrdering:function(e){let t=r.buildLayerMatrix(e),n=new o({compound:!0,multigraph:!0}).setGraph({});return e.nodes().forEach((t=>{n.setNode(t,{label:t}),n.setParent(t,"layer"+e.node(t).rank)})),e.edges().forEach((e=>n.setEdge(e.v,e.w,{},e.name))),t.forEach(((e,t)=>{let r="layer"+t;n.setNode(r,{rank:"same"}),e.reduce(((e,t)=>(n.setEdge(e,t,{style:"invis"}),t)))})),n}}},50476:(e,t,n)=>{let r=n(56497).Graph,o=n(71442);e.exports=function(e,t){if(e.nodeCount()<=1)return[];let n=function(e,t){let n=new r,a=0,i=0;e.nodes().forEach((e=>{n.setNode(e,{v:e,in:0,out:0})})),e.edges().forEach((e=>{let r=n.edge(e.v,e.w)||0,o=t(e),s=r+o;n.setEdge(e.v,e.w,s),i=Math.max(i,n.node(e.v).out+=o),a=Math.max(a,n.node(e.w).in+=o)}));let l=function(e){const t=[];for(let n=0;n<e;n++)t.push(n);return t}(i+a+3).map((()=>new o)),c=a+1;return n.nodes().forEach((e=>{s(l,c,n.node(e))})),{graph:n,buckets:l,zeroIdx:c}}(e,t||a);return function(e,t,n){let r,o=[],a=t[t.length-1],s=t[0];for(;e.nodeCount();){for(;r=s.dequeue();)i(e,t,n,r);for(;r=a.dequeue();)i(e,t,n,r);if(e.nodeCount())for(let a=t.length-2;a>0;--a)if(r=t[a].dequeue(),r){o=o.concat(i(e,t,n,r,!0));break}}return o}(n.graph,n.buckets,n.zeroIdx).flatMap((t=>e.outEdges(t.v,t.w)))};let a=()=>1;function i(e,t,n,r,o){let a=o?[]:void 0;return e.inEdges(r.v).forEach((r=>{let i=e.edge(r),l=e.node(r.v);o&&a.push({v:r.v,w:r.w}),l.out-=i,s(t,n,l)})),e.outEdges(r.v).forEach((r=>{let o=e.edge(r),a=r.w,i=e.node(a);i.in-=o,s(t,n,i)})),e.removeNode(r.v),a}function s(e,t,n){n.out?n.in?e[n.out-n.in+t].enqueue(n):e[e.length-1].enqueue(n):e[0].enqueue(n)}},74809:(e,t,n)=>{"use strict";let r=n(37795),o=n(6840),a=n(56930),i=n(65795).normalizeRanks,s=n(59069),l=n(65795).removeEmptyRanks,c=n(86960),u=n(49298),d=n(6655),p=n(61096),f=n(71383),h=n(65795),m=n(56497).Graph;e.exports=function(e,t){let n=t&&t.debugTiming?h.time:h.notime;n("layout",(()=>{let t=n(" buildLayoutGraph",(()=>function(e){let t=new m({multigraph:!0,compound:!0}),n=k(e.graph());return t.setGraph(Object.assign({},v,A(n,g),h.pick(n,y))),e.nodes().forEach((n=>{const r=A(k(e.node(n)),b);Object.keys(w).forEach((e=>{void 0===r[e]&&(r[e]=w[e])})),t.setNode(n,r),t.setParent(n,e.parent(n))})),e.edges().forEach((n=>{let r=k(e.edge(n));t.setEdge(n,Object.assign({},C,A(r,x),h.pick(r,S)))})),t}(e)));n(" runLayout",(()=>function(e,t){t(" makeSpaceForEdgeLabels",(()=>function(e){let t=e.graph();t.ranksep/=2,e.edges().forEach((n=>{let r=e.edge(n);r.minlen*=2,"c"!==r.labelpos.toLowerCase()&&("TB"===t.rankdir||"BT"===t.rankdir?r.width+=r.labeloffset:r.height+=r.labeloffset)}))}(e))),t(" removeSelfEdges",(()=>function(e){e.edges().forEach((t=>{if(t.v===t.w){var n=e.node(t.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e:t,label:e.edge(t)}),e.removeEdge(t)}}))}(e))),t(" acyclic",(()=>r.run(e))),t(" nestingGraph.run",(()=>c.run(e))),t(" rank",(()=>a(h.asNonCompoundGraph(e)))),t(" injectEdgeLabelProxies",(()=>function(e){e.edges().forEach((t=>{let n=e.edge(t);if(n.width&&n.height){let n=e.node(t.v),r={rank:(e.node(t.w).rank-n.rank)/2+n.rank,e:t};h.addDummyNode(e,"edge-proxy",r,"_ep")}}))}(e))),t(" removeEmptyRanks",(()=>l(e))),t(" nestingGraph.cleanup",(()=>c.cleanup(e))),t(" normalizeRanks",(()=>i(e))),t(" assignRankMinMax",(()=>function(e){let t=0;e.nodes().forEach((n=>{let r=e.node(n);r.borderTop&&(r.minRank=e.node(r.borderTop).rank,r.maxRank=e.node(r.borderBottom).rank,t=Math.max(t,r.maxRank))})),e.graph().maxRank=t}(e))),t(" removeEdgeLabelProxies",(()=>function(e){e.nodes().forEach((t=>{let n=e.node(t);"edge-proxy"===n.dummy&&(e.edge(n.e).labelRank=n.rank,e.removeNode(t))}))}(e))),t(" normalize.run",(()=>o.run(e))),t(" parentDummyChains",(()=>s(e))),t(" addBorderSegments",(()=>u(e))),t(" order",(()=>p(e))),t(" insertSelfEdges",(()=>function(e){var t=h.buildLayerMatrix(e);t.forEach((t=>{var n=0;t.forEach(((t,r)=>{var o=e.node(t);o.order=r+n,(o.selfEdges||[]).forEach((t=>{h.addDummyNode(e,"selfedge",{width:t.label.width,height:t.label.height,rank:o.rank,order:r+ ++n,e:t.e,label:t.label},"_se")})),delete o.selfEdges}))}))}(e))),t(" adjustCoordinateSystem",(()=>d.adjust(e))),t(" position",(()=>f(e))),t(" positionSelfEdges",(()=>function(e){e.nodes().forEach((t=>{var n=e.node(t);if("selfedge"===n.dummy){var r=e.node(n.e.v),o=r.x+r.width/2,a=r.y,i=n.x-o,s=r.height/2;e.setEdge(n.e,n.label),e.removeNode(t),n.label.points=[{x:o+2*i/3,y:a-s},{x:o+5*i/6,y:a-s},{x:o+i,y:a},{x:o+5*i/6,y:a+s},{x:o+2*i/3,y:a+s}],n.label.x=n.x,n.label.y=n.y}}))}(e))),t(" removeBorderNodes",(()=>function(e){e.nodes().forEach((t=>{if(e.children(t).length){let n=e.node(t),r=e.node(n.borderTop),o=e.node(n.borderBottom),a=e.node(n.borderLeft[n.borderLeft.length-1]),i=e.node(n.borderRight[n.borderRight.length-1]);n.width=Math.abs(i.x-a.x),n.height=Math.abs(o.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}})),e.nodes().forEach((t=>{"border"===e.node(t).dummy&&e.removeNode(t)}))}(e))),t(" normalize.undo",(()=>o.undo(e))),t(" fixupEdgeLabelCoords",(()=>function(e){e.edges().forEach((t=>{let n=e.edge(t);if(n.hasOwnProperty("x"))switch("l"!==n.labelpos&&"r"!==n.labelpos||(n.width-=n.labeloffset),n.labelpos){case"l":n.x-=n.width/2+n.labeloffset;break;case"r":n.x+=n.width/2+n.labeloffset}}))}(e))),t(" undoCoordinateSystem",(()=>d.undo(e))),t(" translateGraph",(()=>function(e){let t=Number.POSITIVE_INFINITY,n=0,r=Number.POSITIVE_INFINITY,o=0,a=e.graph(),i=a.marginx||0,s=a.marginy||0;function l(e){let a=e.x,i=e.y,s=e.width,l=e.height;t=Math.min(t,a-s/2),n=Math.max(n,a+s/2),r=Math.min(r,i-l/2),o=Math.max(o,i+l/2)}e.nodes().forEach((t=>l(e.node(t)))),e.edges().forEach((t=>{let n=e.edge(t);n.hasOwnProperty("x")&&l(n)})),t-=i,r-=s,e.nodes().forEach((n=>{let o=e.node(n);o.x-=t,o.y-=r})),e.edges().forEach((n=>{let o=e.edge(n);o.points.forEach((e=>{e.x-=t,e.y-=r})),o.hasOwnProperty("x")&&(o.x-=t),o.hasOwnProperty("y")&&(o.y-=r)})),a.width=n-t+i,a.height=o-r+s}(e))),t(" assignNodeIntersects",(()=>function(e){e.edges().forEach((t=>{let n,r,o=e.edge(t),a=e.node(t.v),i=e.node(t.w);o.points?(n=o.points[0],r=o.points[o.points.length-1]):(o.points=[],n=i,r=a),o.points.unshift(h.intersectRect(a,n)),o.points.push(h.intersectRect(i,r))}))}(e))),t(" reversePoints",(()=>function(e){e.edges().forEach((t=>{let n=e.edge(t);n.reversed&&n.points.reverse()}))}(e))),t(" acyclic.undo",(()=>r.undo(e)))}(t,n))),n(" updateInputGraph",(()=>function(e,t){e.nodes().forEach((n=>{let r=e.node(n),o=t.node(n);r&&(r.x=o.x,r.y=o.y,r.rank=o.rank,t.children(n).length&&(r.width=o.width,r.height=o.height))})),e.edges().forEach((n=>{let r=e.edge(n),o=t.edge(n);r.points=o.points,o.hasOwnProperty("x")&&(r.x=o.x,r.y=o.y)})),e.graph().width=t.graph().width,e.graph().height=t.graph().height}(e,t)))}))};let g=["nodesep","edgesep","ranksep","marginx","marginy"],v={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},y=["acyclicer","ranker","rankdir","align"],b=["width","height"],w={width:0,height:0},x=["minlen","weight","width","height","labeloffset"],C={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},S=["labelpos"];function A(e,t){return h.mapValues(h.pick(e,t),Number)}function k(e){var t={};return e&&Object.entries(e).forEach((e=>{let[n,r]=e;"string"===typeof n&&(n=n.toLowerCase()),t[n]=r})),t}},86960:(e,t,n)=>{let r=n(65795);function o(e,t,n,a,i,s,l){let c=e.children(l);if(!c.length)return void(l!==t&&e.setEdge(t,l,{weight:0,minlen:n}));let u=r.addBorderNode(e,"_bt"),d=r.addBorderNode(e,"_bb"),p=e.node(l);e.setParent(u,l),p.borderTop=u,e.setParent(d,l),p.borderBottom=d,c.forEach((r=>{o(e,t,n,a,i,s,r);let c=e.node(r),p=c.borderTop?c.borderTop:r,f=c.borderBottom?c.borderBottom:r,h=c.borderTop?a:2*a,m=p!==f?1:i-s[l]+1;e.setEdge(u,p,{weight:h,minlen:m,nestingEdge:!0}),e.setEdge(f,d,{weight:h,minlen:m,nestingEdge:!0})})),e.parent(l)||e.setEdge(t,u,{weight:0,minlen:i+s[l]})}e.exports={run:function(e){let t=r.addDummyNode(e,"root",{},"_root"),n=function(e){var t={};function n(r,o){var a=e.children(r);a&&a.length&&a.forEach((e=>n(e,o+1))),t[r]=o}return e.children().forEach((e=>n(e,1))),t}(e),a=Math.max(...Object.values(n))-1,i=2*a+1;e.graph().nestingRoot=t,e.edges().forEach((t=>e.edge(t).minlen*=i));let s=function(e){return e.edges().reduce(((t,n)=>t+e.edge(n).weight),0)}(e)+1;e.children().forEach((r=>o(e,t,i,s,a,n,r))),e.graph().nodeRankFactor=i},cleanup:function(e){var t=e.graph();e.removeNode(t.nestingRoot),delete t.nestingRoot,e.edges().forEach((t=>{e.edge(t).nestingEdge&&e.removeEdge(t)}))}}},6840:(e,t,n)=>{"use strict";let r=n(65795);e.exports={run:function(e){e.graph().dummyChains=[],e.edges().forEach((t=>function(e,t){let n,o,a,i=t.v,s=e.node(i).rank,l=t.w,c=e.node(l).rank,u=t.name,d=e.edge(t),p=d.labelRank;if(c===s+1)return;for(e.removeEdge(t),a=0,++s;s<c;++a,++s)d.points=[],o={width:0,height:0,edgeLabel:d,edgeObj:t,rank:s},n=r.addDummyNode(e,"edge",o,"_d"),s===p&&(o.width=d.width,o.height=d.height,o.dummy="edge-label",o.labelpos=d.labelpos),e.setEdge(i,n,{weight:d.weight},u),0===a&&e.graph().dummyChains.push(n),i=n;e.setEdge(i,l,{weight:d.weight},u)}(e,t)))},undo:function(e){e.graph().dummyChains.forEach((t=>{let n,r=e.node(t),o=r.edgeLabel;for(e.setEdge(r.edgeObj,o);r.dummy;)n=e.successors(t)[0],e.removeNode(t),o.points.push({x:r.x,y:r.y}),"edge-label"===r.dummy&&(o.x=r.x,o.y=r.y,o.width=r.width,o.height=r.height),t=n,r=e.node(t)}))}}},77203:e=>{e.exports=function(e,t,n){let r,o={};n.forEach((n=>{let a,i,s=e.parent(n);for(;s;){if(a=e.parent(s),a?(i=o[a],o[a]=s):(i=r,r=s),i&&i!==s)return void t.setEdge(i,s);s=a}}))}},5391:e=>{e.exports=function(e){return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).map((t=>{let n=e.inEdges(t);if(n.length){let r=n.reduce(((t,n)=>{let r=e.edge(n),o=e.node(n.v);return{sum:t.sum+r.weight*o.order,weight:t.weight+r.weight}}),{sum:0,weight:0});return{v:t,barycenter:r.sum/r.weight,weight:r.weight}}return{v:t}}))}},57041:(e,t,n)=>{let r=n(56497).Graph,o=n(65795);e.exports=function(e,t,n){let a=function(e){var t;for(;e.hasNode(t=o.uniqueId("_root")););return t}(e),i=new r({compound:!0}).setGraph({root:a}).setDefaultNodeLabel((t=>e.node(t)));return e.nodes().forEach((r=>{let o=e.node(r),s=e.parent(r);(o.rank===t||o.minRank<=t&&t<=o.maxRank)&&(i.setNode(r),i.setParent(r,s||a),e[n](r).forEach((t=>{let n=t.v===r?t.w:t.v,o=i.edge(n,r),a=void 0!==o?o.weight:0;i.setEdge(n,r,{weight:e.edge(t).weight+a})})),o.hasOwnProperty("minRank")&&i.setNode(r,{borderLeft:o.borderLeft[t],borderRight:o.borderRight[t]}))})),i}},97090:(e,t,n)=>{"use strict";let r=n(65795).zipObject;function o(e,t,n){let o=r(n,n.map(((e,t)=>t))),a=t.flatMap((t=>e.outEdges(t).map((t=>({pos:o[t.w],weight:e.edge(t).weight}))).sort(((e,t)=>e.pos-t.pos)))),i=1;for(;i<n.length;)i<<=1;let s=2*i-1;i-=1;let l=new Array(s).fill(0),c=0;return a.forEach((e=>{let t=e.pos+i;l[t]+=e.weight;let n=0;for(;t>0;)t%2&&(n+=l[t+1]),t=t-1>>1,l[t]+=e.weight;c+=e.weight*n})),c}e.exports=function(e,t){let n=0;for(let r=1;r<t.length;++r)n+=o(e,t[r-1],t[r]);return n}},61096:(e,t,n)=>{"use strict";let r=n(35357),o=n(97090),a=n(43377),i=n(57041),s=n(77203),l=n(56497).Graph,c=n(65795);function u(e,t,n){return t.map((function(t){return i(e,t,n)}))}function d(e,t){let n=new l;e.forEach((function(e){let r=e.graph().root,o=a(e,r,n,t);o.vs.forEach(((t,n)=>e.node(t).order=n)),s(e,n,o.vs)}))}function p(e,t){Object.values(t).forEach((t=>t.forEach(((t,n)=>e.node(t).order=n))))}e.exports=function e(t,n){if(n&&"function"===typeof n.customOrder)return void n.customOrder(t,e);let a=c.maxRank(t),i=u(t,c.range(1,a+1),"inEdges"),s=u(t,c.range(a-1,-1,-1),"outEdges"),l=r(t);if(p(t,l),n&&n.disableOptimalOrderHeuristic)return;let f,h=Number.POSITIVE_INFINITY;for(let r=0,u=0;u<4;++r,++u){d(r%2?i:s,r%4>=2),l=c.buildLayerMatrix(t);let e=o(t,l);e<h&&(u=0,f=Object.assign({},l),h=e)}p(t,f)}},35357:(e,t,n)=>{"use strict";let r=n(65795);e.exports=function(e){let t={},n=e.nodes().filter((t=>!e.children(t).length)),o=Math.max(...n.map((t=>e.node(t).rank))),a=r.range(o+1).map((()=>[]));return n.sort(((t,n)=>e.node(t).rank-e.node(n).rank)).forEach((function n(r){if(t[r])return;t[r]=!0;let o=e.node(r);a[o.rank].push(r),e.successors(r).forEach(n)})),a}},77666:(e,t,n)=>{"use strict";let r=n(65795);e.exports=function(e,t){let n={};return e.forEach(((e,t)=>{let r=n[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:t};void 0!==e.barycenter&&(r.barycenter=e.barycenter,r.weight=e.weight)})),t.edges().forEach((e=>{let t=n[e.v],r=n[e.w];void 0!==t&&void 0!==r&&(r.indegree++,t.out.push(n[e.w]))})),function(e){let t=[];function n(e){return t=>{t.merged||(void 0===t.barycenter||void 0===e.barycenter||t.barycenter>=e.barycenter)&&function(e,t){let n=0,r=0;e.weight&&(n+=e.barycenter*e.weight,r+=e.weight);t.weight&&(n+=t.barycenter*t.weight,r+=t.weight);e.vs=t.vs.concat(e.vs),e.barycenter=n/r,e.weight=r,e.i=Math.min(t.i,e.i),t.merged=!0}(e,t)}}function o(t){return n=>{n.in.push(t),0===--n.indegree&&e.push(n)}}for(;e.length;){let r=e.pop();t.push(r),r.in.reverse().forEach(n(r)),r.out.forEach(o(r))}return t.filter((e=>!e.merged)).map((e=>r.pick(e,["vs","i","barycenter","weight"])))}(Object.values(n).filter((e=>!e.indegree)))}},43377:(e,t,n)=>{let r=n(5391),o=n(77666),a=n(51410);e.exports=function e(t,n,i,s){let l=t.children(n),c=t.node(n),u=c?c.borderLeft:void 0,d=c?c.borderRight:void 0,p={};u&&(l=l.filter((e=>e!==u&&e!==d)));let f=r(t,l);f.forEach((n=>{if(t.children(n.v).length){let a=e(t,n.v,i,s);p[n.v]=a,a.hasOwnProperty("barycenter")&&(o=a,void 0!==(r=n).barycenter?(r.barycenter=(r.barycenter*r.weight+o.barycenter*o.weight)/(r.weight+o.weight),r.weight+=o.weight):(r.barycenter=o.barycenter,r.weight=o.weight))}var r,o}));let h=o(f,i);!function(e,t){e.forEach((e=>{e.vs=e.vs.flatMap((e=>t[e]?t[e].vs:e))}))}(h,p);let m=a(h,s);if(u&&(m.vs=[u,m.vs,d].flat(!0),t.predecessors(u).length)){let e=t.node(t.predecessors(u)[0]),n=t.node(t.predecessors(d)[0]);m.hasOwnProperty("barycenter")||(m.barycenter=0,m.weight=0),m.barycenter=(m.barycenter*m.weight+e.order+n.order)/(m.weight+2),m.weight+=2}return m}},51410:(e,t,n)=>{let r=n(65795);function o(e,t,n){let r;for(;t.length&&(r=t[t.length-1]).i<=n;)t.pop(),e.push(r.vs),n++;return n}e.exports=function(e,t){let n=r.partition(e,(e=>e.hasOwnProperty("barycenter"))),a=n.lhs,i=n.rhs.sort(((e,t)=>t.i-e.i)),s=[],l=0,c=0,u=0;a.sort((d=!!t,(e,t)=>e.barycenter<t.barycenter?-1:e.barycenter>t.barycenter?1:d?t.i-e.i:e.i-t.i)),u=o(s,i,u),a.forEach((e=>{u+=e.vs.length,s.push(e.vs),l+=e.barycenter*e.weight,c+=e.weight,u=o(s,i,u)}));var d;let p={vs:s.flat(!0)};c&&(p.barycenter=l/c,p.weight=c);return p}},59069:e=>{e.exports=function(e){let t=function(e){let t={},n=0;function r(o){let a=n;e.children(o).forEach(r),t[o]={low:a,lim:n++}}return e.children().forEach(r),t}(e);e.graph().dummyChains.forEach((n=>{let r=e.node(n),o=r.edgeObj,a=function(e,t,n,r){let o,a,i=[],s=[],l=Math.min(t[n].low,t[r].low),c=Math.max(t[n].lim,t[r].lim);o=n;do{o=e.parent(o),i.push(o)}while(o&&(t[o].low>l||c>t[o].lim));a=o,o=r;for(;(o=e.parent(o))!==a;)s.push(o);return{path:i.concat(s.reverse()),lca:a}}(e,t,o.v,o.w),i=a.path,s=a.lca,l=0,c=i[l],u=!0;for(;n!==o.w;){if(r=e.node(n),u){for(;(c=i[l])!==s&&e.node(c).maxRank<r.rank;)l++;c===s&&(u=!1)}if(!u){for(;l<i.length-1&&e.node(c=i[l+1]).minRank<=r.rank;)l++;c=i[l]}e.setParent(n,c),n=e.successors(n)[0]}}))}},52760:(e,t,n)=>{"use strict";let r=n(56497).Graph,o=n(65795);function a(e,t){let n={};return t.length&&t.reduce((function(t,r){let o=0,a=0,i=t.length,l=r[r.length-1];return r.forEach(((t,c)=>{let u=function(e,t){if(e.node(t).dummy)return e.predecessors(t).find((t=>e.node(t).dummy))}(e,t),d=u?e.node(u).order:i;(u||t===l)&&(r.slice(a,c+1).forEach((t=>{e.predecessors(t).forEach((r=>{let a=e.node(r),i=a.order;!(i<o||d<i)||a.dummy&&e.node(t).dummy||s(n,r,t)}))})),a=c+1,o=d)})),r})),n}function i(e,t){let n={};function r(t,r,a,i,l){let c;o.range(r,a).forEach((r=>{c=t[r],e.node(c).dummy&&e.predecessors(c).forEach((t=>{let r=e.node(t);r.dummy&&(r.order<i||r.order>l)&&s(n,t,c)}))}))}return t.length&&t.reduce((function(t,n){let o,a=-1,i=0;return n.forEach(((s,l)=>{if("border"===e.node(s).dummy){let t=e.predecessors(s);t.length&&(o=e.node(t[0]).order,r(n,i,l,a,o),i=l,a=o)}r(n,i,n.length,o,t.length)})),n})),n}function s(e,t,n){if(t>n){let e=t;t=n,n=e}let r=e[t];r||(e[t]=r={}),r[n]=!0}function l(e,t,n){if(t>n){let e=t;t=n,n=e}return!!e[t]&&e[t].hasOwnProperty(n)}function c(e,t,n,r){let o={},a={},i={};return t.forEach((e=>{e.forEach(((e,t)=>{o[e]=e,a[e]=e,i[e]=t}))})),t.forEach((e=>{let t=-1;e.forEach((e=>{let s=r(e);if(s.length){s=s.sort(((e,t)=>i[e]-i[t]));let r=(s.length-1)/2;for(let c=Math.floor(r),u=Math.ceil(r);c<=u;++c){let r=s[c];a[e]===e&&t<i[r]&&!l(n,e,r)&&(a[r]=e,a[e]=o[e]=o[r],t=i[r])}}}))})),{root:o,align:a}}function u(e,t,n,o,a){let i={},s=function(e,t,n,o){let a=new r,i=e.graph(),s=function(e,t,n){return(r,o,a)=>{let i,s=r.node(o),l=r.node(a),c=0;if(c+=s.width/2,s.hasOwnProperty("labelpos"))switch(s.labelpos.toLowerCase()){case"l":i=-s.width/2;break;case"r":i=s.width/2}if(i&&(c+=n?i:-i),i=0,c+=(s.dummy?t:e)/2,c+=(l.dummy?t:e)/2,c+=l.width/2,l.hasOwnProperty("labelpos"))switch(l.labelpos.toLowerCase()){case"l":i=l.width/2;break;case"r":i=-l.width/2}return i&&(c+=n?i:-i),i=0,c}}(i.nodesep,i.edgesep,o);return t.forEach((t=>{let r;t.forEach((t=>{let o=n[t];if(a.setNode(o),r){var i=n[r],l=a.edge(i,o);a.setEdge(i,o,Math.max(s(e,t,r),l||0))}r=t}))})),a}(e,t,n,a),l=a?"borderLeft":"borderRight";function c(e,t){let n=s.nodes(),r=n.pop(),o={};for(;r;)o[r]?e(r):(o[r]=!0,n.push(r),n=n.concat(t(r))),r=n.pop()}return c((function(e){i[e]=s.inEdges(e).reduce(((e,t)=>Math.max(e,i[t.v]+s.edge(t))),0)}),s.predecessors.bind(s)),c((function(t){let n=s.outEdges(t).reduce(((e,t)=>Math.min(e,i[t.w]-s.edge(t))),Number.POSITIVE_INFINITY),r=e.node(t);n!==Number.POSITIVE_INFINITY&&r.borderType!==l&&(i[t]=Math.max(i[t],n))}),s.successors.bind(s)),Object.keys(o).forEach((e=>i[e]=i[n[e]])),i}function d(e,t){return Object.values(t).reduce(((t,n)=>{let r=Number.NEGATIVE_INFINITY,o=Number.POSITIVE_INFINITY;Object.entries(n).forEach((t=>{let[n,a]=t,i=function(e,t){return e.node(t).width}(e,n)/2;r=Math.max(a+i,r),o=Math.min(a-i,o)}));const a=r-o;return a<t[0]&&(t=[a,n]),t}),[Number.POSITIVE_INFINITY,null])[1]}function p(e,t){let n=Object.values(t),r=Math.min(...n),a=Math.max(...n);["u","d"].forEach((n=>{["l","r"].forEach((i=>{let s=n+i,l=e[s];if(l===t)return;let c=Object.values(l),u=r-Math.min(...c);"l"!==i&&(u=a-Math.max(...c)),u&&(e[s]=o.mapValues(l,(e=>e+u)))}))}))}function f(e,t){return o.mapValues(e.ul,((n,r)=>{if(t)return e[t.toLowerCase()][r];{let t=Object.values(e).map((e=>e[r])).sort(((e,t)=>e-t));return(t[1]+t[2])/2}}))}e.exports={positionX:function(e){let t,n=o.buildLayerMatrix(e),r=Object.assign(a(e,n),i(e,n)),s={};["u","d"].forEach((a=>{t="u"===a?n:Object.values(n).reverse(),["l","r"].forEach((n=>{"r"===n&&(t=t.map((e=>Object.values(e).reverse())));let i=("u"===a?e.predecessors:e.successors).bind(e),l=c(e,t,r,i),d=u(e,t,l.root,l.align,"r"===n);"r"===n&&(d=o.mapValues(d,(e=>-e))),s[a+n]=d}))}));let l=d(e,s);return p(s,l),f(s,e.graph().align)},findType1Conflicts:a,findType2Conflicts:i,addConflict:s,hasConflict:l,verticalAlignment:c,horizontalCompaction:u,alignCoordinates:p,findSmallestWidthAlignment:d,balance:f}},71383:(e,t,n)=>{"use strict";let r=n(65795),o=n(52760).positionX;e.exports=function(e){(function(e){let t=r.buildLayerMatrix(e),n=e.graph().ranksep,o=0;t.forEach((t=>{const r=t.reduce(((t,n)=>{const r=e.node(n).height;return t>r?t:r}),0);t.forEach((t=>e.node(t).y=o+r/2)),o+=r+n}))})(e=r.asNonCompoundGraph(e)),Object.entries(o(e)).forEach((t=>{let[n,r]=t;return e.node(n).x=r}))}},29690:(e,t,n)=>{"use strict";var r=n(56497).Graph,o=n(20108).slack;function a(e,t){return e.nodes().forEach((function n(r){t.nodeEdges(r).forEach((a=>{var i=a.v,s=r===i?a.w:i;e.hasNode(s)||o(t,a)||(e.setNode(s,{}),e.setEdge(r,s,{}),n(s))}))})),e.nodeCount()}function i(e,t){return t.edges().reduce(((n,r)=>{let a=Number.POSITIVE_INFINITY;return e.hasNode(r.v)!==e.hasNode(r.w)&&(a=o(t,r)),a<n[0]?[a,r]:n}),[Number.POSITIVE_INFINITY,null])[1]}function s(e,t,n){e.nodes().forEach((e=>t.node(e).rank+=n))}e.exports=function(e){var t,n,l=new r({directed:!1}),c=e.nodes()[0],u=e.nodeCount();l.setNode(c,{});for(;a(l,e)<u;)t=i(l,e),n=l.hasNode(t.v)?o(e,t):-o(e,t),s(l,e,n);return l}},56930:(e,t,n)=>{"use strict";var r=n(20108).longestPath,o=n(29690),a=n(55495);e.exports=function(e){switch(e.graph().ranker){case"network-simplex":default:s(e);break;case"tight-tree":!function(e){r(e),o(e)}(e);break;case"longest-path":i(e)}};var i=r;function s(e){a(e)}},55495:(e,t,n)=>{"use strict";var r=n(29690),o=n(20108).slack,a=n(20108).longestPath,i=n(56497).alg.preorder,s=n(56497).alg.postorder,l=n(65795).simplify;function c(e){e=l(e),a(e);var t,n=r(e);for(p(n),u(n,e);t=h(n);)g(n,e,t,m(n,e,t))}function u(e,t){var n=s(e,e.nodes());(n=n.slice(0,n.length-1)).forEach((n=>function(e,t,n){var r=e.node(n),o=r.parent;e.edge(n,o).cutvalue=d(e,t,n)}(e,t,n)))}function d(e,t,n){var r=e.node(n).parent,o=!0,a=t.edge(n,r),i=0;return a||(o=!1,a=t.edge(r,n)),i=a.weight,t.nodeEdges(n).forEach((a=>{var s,l,c=a.v===n,u=c?a.w:a.v;if(u!==r){var d=c===o,p=t.edge(a).weight;if(i+=d?p:-p,s=n,l=u,e.hasEdge(s,l)){var f=e.edge(n,u).cutvalue;i+=d?-f:f}}})),i}function p(e,t){arguments.length<2&&(t=e.nodes()[0]),f(e,{},1,t)}function f(e,t,n,r,o){var a=n,i=e.node(r);return t[r]=!0,e.neighbors(r).forEach((o=>{t.hasOwnProperty(o)||(n=f(e,t,n,o,r))})),i.low=a,i.lim=n++,o?i.parent=o:delete i.parent,n}function h(e){return e.edges().find((t=>e.edge(t).cutvalue<0))}function m(e,t,n){var r=n.v,a=n.w;t.hasEdge(r,a)||(r=n.w,a=n.v);var i=e.node(r),s=e.node(a),l=i,c=!1;i.lim>s.lim&&(l=s,c=!0);var u=t.edges().filter((t=>c===v(e,e.node(t.v),l)&&c!==v(e,e.node(t.w),l)));return u.reduce(((e,n)=>o(t,n)<o(t,e)?n:e))}function g(e,t,n,r){var o=n.v,a=n.w;e.removeEdge(o,a),e.setEdge(r.v,r.w,{}),p(e),u(e,t),function(e,t){var n=e.nodes().find((e=>!t.node(e).parent)),r=i(e,n);(r=r.slice(1)).forEach((n=>{var r=e.node(n).parent,o=t.edge(n,r),a=!1;o||(o=t.edge(r,n),a=!0),t.node(n).rank=t.node(r).rank+(a?o.minlen:-o.minlen)}))}(e,t)}function v(e,t,n){return n.low<=t.lim&&t.lim<=n.lim}e.exports=c,c.initLowLimValues=p,c.initCutValues=u,c.calcCutValue=d,c.leaveEdge=h,c.enterEdge=m,c.exchangeEdges=g},20108:e=>{"use strict";e.exports={longestPath:function(e){var t={};e.sources().forEach((function n(r){var o=e.node(r);if(t.hasOwnProperty(r))return o.rank;t[r]=!0;var a=Math.min(...e.outEdges(r).map((t=>null==t?Number.POSITIVE_INFINITY:n(t.w)-e.edge(t).minlen)));return a===Number.POSITIVE_INFINITY&&(a=0),o.rank=a}))},slack:function(e,t){return e.node(t.w).rank-e.node(t.v).rank-e.edge(t).minlen}}},65795:(e,t,n)=>{"use strict";let r=n(56497).Graph;function o(e,t,n,r){let o;do{o=s(r)}while(e.hasNode(o));return n.dummy=t,e.setNode(o,n),o}function a(e){return Math.max(...e.nodes().map((t=>{let n=e.node(t).rank;return void 0===n?Number.MIN_VALUE:n})))}e.exports={addBorderNode:function(e,t,n,r){let a={width:0,height:0};arguments.length>=4&&(a.rank=n,a.order=r);return o(e,"border",a,t)},addDummyNode:o,asNonCompoundGraph:function(e){let t=new r({multigraph:e.isMultigraph()}).setGraph(e.graph());return e.nodes().forEach((n=>{e.children(n).length||t.setNode(n,e.node(n))})),e.edges().forEach((n=>{t.setEdge(n,e.edge(n))})),t},buildLayerMatrix:function(e){let t=l(a(e)+1).map((()=>[]));return e.nodes().forEach((n=>{let r=e.node(n),o=r.rank;void 0!==o&&(t[o][r.order]=n)})),t},intersectRect:function(e,t){let n,r,o=e.x,a=e.y,i=t.x-o,s=t.y-a,l=e.width/2,c=e.height/2;if(!i&&!s)throw new Error("Not possible to find intersection inside of the rectangle");Math.abs(s)*l>Math.abs(i)*c?(s<0&&(c=-c),n=c*i/s,r=c):(i<0&&(l=-l),n=l,r=l*s/i);return{x:o+n,y:a+r}},mapValues:function(e,t){let n=t;"string"===typeof t&&(n=e=>e[t]);return Object.entries(e).reduce(((e,t)=>{let[r,o]=t;return e[r]=n(o,r),e}),{})},maxRank:a,normalizeRanks:function(e){let t=Math.min(...e.nodes().map((t=>{let n=e.node(t).rank;return void 0===n?Number.MAX_VALUE:n})));e.nodes().forEach((n=>{let r=e.node(n);r.hasOwnProperty("rank")&&(r.rank-=t)}))},notime:function(e,t){return t()},partition:function(e,t){let n={lhs:[],rhs:[]};return e.forEach((e=>{t(e)?n.lhs.push(e):n.rhs.push(e)})),n},pick:function(e,t){const n={};for(const r of t)void 0!==e[r]&&(n[r]=e[r]);return n},predecessorWeights:function(e){let t=e.nodes().map((t=>{let n={};return e.inEdges(t).forEach((t=>{n[t.v]=(n[t.v]||0)+e.edge(t).weight})),n}));return c(e.nodes(),t)},range:l,removeEmptyRanks:function(e){let t=Math.min(...e.nodes().map((t=>e.node(t).rank))),n=[];e.nodes().forEach((r=>{let o=e.node(r).rank-t;n[o]||(n[o]=[]),n[o].push(r)}));let r=0,o=e.graph().nodeRankFactor;Array.from(n).forEach(((t,n)=>{void 0===t&&n%o!==0?--r:void 0!==t&&r&&t.forEach((t=>e.node(t).rank+=r))}))},simplify:function(e){let t=(new r).setGraph(e.graph());return e.nodes().forEach((n=>t.setNode(n,e.node(n)))),e.edges().forEach((n=>{let r=t.edge(n.v,n.w)||{weight:0,minlen:1},o=e.edge(n);t.setEdge(n.v,n.w,{weight:r.weight+o.weight,minlen:Math.max(r.minlen,o.minlen)})})),t},successorWeights:function(e){let t=e.nodes().map((t=>{let n={};return e.outEdges(t).forEach((t=>{n[t.w]=(n[t.w]||0)+e.edge(t).weight})),n}));return c(e.nodes(),t)},time:function(e,t){let n=Date.now();try{return t()}finally{console.log(e+" time: "+(Date.now()-n)+"ms")}},uniqueId:s,zipObject:c};let i=0;function s(e){var t=++i;return toString(e)+t}function l(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;null==t&&(t=e,e=0);let r=e=>e<t;n<0&&(r=e=>t<e);const o=[];for(let a=e;r(a);a+=n)o.push(a);return o}function c(e,t){return e.reduce(((e,n,r)=>(e[n]=t[r],e)),{})}},8563:e=>{e.exports="1.1.2"},56497:(e,t,n)=>{var r=n(38441);e.exports={Graph:r.Graph,json:n(84555),alg:n(56800),version:r.version}},94986:e=>{e.exports=function(e){var t,n={},r=[];function o(r){n.hasOwnProperty(r)||(n[r]=!0,t.push(r),e.successors(r).forEach(o),e.predecessors(r).forEach(o))}return e.nodes().forEach((function(e){t=[],o(e),t.length&&r.push(t)})),r}},22259:e=>{function t(e,t,n,o){for(var a=[[e,!1]];a.length>0;){var i=a.pop();i[1]?o.push(i[0]):n.hasOwnProperty(i[0])||(n[i[0]]=!0,a.push([i[0],!0]),r(t(i[0]),(e=>a.push([e,!1]))))}}function n(e,t,n,o){for(var a=[e];a.length>0;){var i=a.pop();n.hasOwnProperty(i)||(n[i]=!0,o.push(i),r(t(i),(e=>a.push(e))))}}function r(e,t){for(var n=e.length;n--;)t(e[n],n,e);return e}e.exports=function(e,r,o){Array.isArray(r)||(r=[r]);var a=e.isDirected()?t=>e.successors(t):t=>e.neighbors(t),i="post"===o?t:n,s=[],l={};return r.forEach((t=>{if(!e.hasNode(t))throw new Error("Graph does not have node: "+t);i(t,a,l,s)})),s}},57106:(e,t,n)=>{var r=n(45432);e.exports=function(e,t,n){return e.nodes().reduce((function(o,a){return o[a]=r(e,a,t,n),o}),{})}},45432:(e,t,n)=>{var r=n(71914);e.exports=function(e,t,n,a){return function(e,t,n,o){var a,i,s={},l=new r,c=function(e){var t=e.v!==a?e.v:e.w,r=s[t],o=n(e),c=i.distance+o;if(o<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+e+" Weight: "+o);c<r.distance&&(r.distance=c,r.predecessor=a,l.decrease(t,c))};e.nodes().forEach((function(e){var n=e===t?0:Number.POSITIVE_INFINITY;s[e]={distance:n},l.add(e,n)}));for(;l.size()>0&&(a=l.removeMin(),(i=s[a]).distance!==Number.POSITIVE_INFINITY);)o(a).forEach(c);return s}(e,String(t),n||o,a||function(t){return e.outEdges(t)})};var o=()=>1},97529:(e,t,n)=>{var r=n(34102);e.exports=function(e){return r(e).filter((function(t){return t.length>1||1===t.length&&e.hasEdge(t[0],t[0])}))}},64735:e=>{e.exports=function(e,n,r){return function(e,t,n){var r={},o=e.nodes();return o.forEach((function(e){r[e]={},r[e][e]={distance:0},o.forEach((function(t){e!==t&&(r[e][t]={distance:Number.POSITIVE_INFINITY})})),n(e).forEach((function(n){var o=n.v===e?n.w:n.v,a=t(n);r[e][o]={distance:a,predecessor:e}}))})),o.forEach((function(e){var t=r[e];o.forEach((function(n){var a=r[n];o.forEach((function(n){var r=a[e],o=t[n],i=a[n],s=r.distance+o.distance;s<i.distance&&(i.distance=s,i.predecessor=o.predecessor)}))}))})),r}(e,n||t,r||function(t){return e.outEdges(t)})};var t=()=>1},56800:(e,t,n)=>{e.exports={components:n(94986),dijkstra:n(45432),dijkstraAll:n(57106),findCycles:n(97529),floydWarshall:n(64735),isAcyclic:n(23891),postorder:n(1346),preorder:n(47673),prim:n(56558),tarjan:n(34102),topsort:n(45183)}},23891:(e,t,n)=>{var r=n(45183);e.exports=function(e){try{r(e)}catch(t){if(t instanceof r.CycleException)return!1;throw t}return!0}},1346:(e,t,n)=>{var r=n(22259);e.exports=function(e,t){return r(e,t,"post")}},47673:(e,t,n)=>{var r=n(22259);e.exports=function(e,t){return r(e,t,"pre")}},56558:(e,t,n)=>{var r=n(39509),o=n(71914);e.exports=function(e,t){var n,a=new r,i={},s=new o;function l(e){var r=e.v===n?e.w:e.v,o=s.priority(r);if(void 0!==o){var a=t(e);a<o&&(i[r]=n,s.decrease(r,a))}}if(0===e.nodeCount())return a;e.nodes().forEach((function(e){s.add(e,Number.POSITIVE_INFINITY),a.setNode(e)})),s.decrease(e.nodes()[0],0);var c=!1;for(;s.size()>0;){if(n=s.removeMin(),i.hasOwnProperty(n))a.setEdge(n,i[n]);else{if(c)throw new Error("Input graph is not connected: "+e);c=!0}e.nodeEdges(n).forEach(l)}return a}},34102:e=>{e.exports=function(e){var t=0,n=[],r={},o=[];function a(i){var s=r[i]={onStack:!0,lowlink:t,index:t++};if(n.push(i),e.successors(i).forEach((function(e){r.hasOwnProperty(e)?r[e].onStack&&(s.lowlink=Math.min(s.lowlink,r[e].index)):(a(e),s.lowlink=Math.min(s.lowlink,r[e].lowlink))})),s.lowlink===s.index){var l,c=[];do{l=n.pop(),r[l].onStack=!1,c.push(l)}while(i!==l);o.push(c)}}return e.nodes().forEach((function(e){r.hasOwnProperty(e)||a(e)})),o}},45183:e=>{function t(e){var t={},r={},o=[];if(e.sinks().forEach((function a(i){if(r.hasOwnProperty(i))throw new n;t.hasOwnProperty(i)||(r[i]=!0,t[i]=!0,e.predecessors(i).forEach(a),delete r[i],o.push(i))})),Object.keys(t).length!==e.nodeCount())throw new n;return o}class n extends Error{constructor(){super(...arguments)}}e.exports=t,t.CycleException=n},71914:(e,t,n)=>{var r=n(43693).default;e.exports=class{constructor(){r(this,"_arr",[]),r(this,"_keyIndices",{})}size(){return this._arr.length}keys(){return this._arr.map((function(e){return e.key}))}has(e){return this._keyIndices.hasOwnProperty(e)}priority(e){var t=this._keyIndices[e];if(void 0!==t)return this._arr[t].priority}min(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key}add(e,t){var n=this._keyIndices;if(e=String(e),!n.hasOwnProperty(e)){var r=this._arr,o=r.length;return n[e]=o,r.push({key:e,priority:t}),this._decrease(o),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,t){var n=this._keyIndices[e];if(t>this._arr[n].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[n].priority+" New: "+t);this._arr[n].priority=t,this._decrease(n)}_heapify(e){var t=this._arr,n=2*e,r=n+1,o=e;n<t.length&&(o=t[n].priority<t[o].priority?n:o,r<t.length&&(o=t[r].priority<t[o].priority?r:o),o!==e&&(this._swap(e,o),this._heapify(o)))}_decrease(e){for(var t,n=this._arr,r=n[e].priority;0!==e&&!(n[t=e>>1].priority<r);)this._swap(e,t),e=t}_swap(e,t){var n=this._arr,r=this._keyIndices,o=n[e],a=n[t];n[e]=a,n[t]=o,r[a.key]=e,r[o.key]=t}}},39509:(e,t,n)=>{"use strict";var r=n(43693).default,o="\0",a="\0",i="\x01";function s(e,t){e[t]?e[t]++:e[t]=1}function l(e,t){--e[t]||delete e[t]}function c(e,t,n,r){var a=""+t,s=""+n;if(!e&&a>s){var l=a;a=s,s=l}return a+i+s+i+(void 0===r?o:r)}function u(e,t){return c(e,t.v,t.w,t.name)}e.exports=class{constructor(e){r(this,"_isDirected",!0),r(this,"_isMultigraph",!1),r(this,"_isCompound",!1),r(this,"_label",void 0),r(this,"_defaultNodeLabelFn",(()=>{})),r(this,"_defaultEdgeLabelFn",(()=>{})),r(this,"_nodes",{}),r(this,"_in",{}),r(this,"_preds",{}),r(this,"_out",{}),r(this,"_sucs",{}),r(this,"_edgeObjs",{}),r(this,"_edgeLabels",{}),r(this,"_nodeCount",0),r(this,"_edgeCount",0),r(this,"_parent",void 0),r(this,"_children",void 0),e&&(this._isDirected=!e.hasOwnProperty("directed")||e.directed,this._isMultigraph=!!e.hasOwnProperty("multigraph")&&e.multigraph,this._isCompound=!!e.hasOwnProperty("compound")&&e.compound),this._isCompound&&(this._parent={},this._children={},this._children[a]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,"function"!==typeof e&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter((t=>0===Object.keys(e._in[t]).length))}sinks(){var e=this;return this.nodes().filter((t=>0===Object.keys(e._out[t]).length))}setNodes(e,t){var n=arguments,r=this;return e.forEach((function(e){n.length>1?r.setNode(e,t):r.setNode(e)})),this}setNode(e,t){return this._nodes.hasOwnProperty(e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=a,this._children[e]={},this._children[a][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return this._nodes.hasOwnProperty(e)}removeNode(e){var t=this;if(this._nodes.hasOwnProperty(e)){var n=e=>t.removeEdge(t._edgeObjs[e]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach((function(e){t.setParent(e)})),delete this._children[e]),Object.keys(this._in[e]).forEach(n),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(n),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(void 0===t)t=a;else{for(var n=t+="";void 0!==n;n=this.parent(n))if(n===e)throw new Error("Setting "+t+" as parent of "+e+" would create a cycle");this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==a)return t}}children(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:a;if(this._isCompound){var t=this._children[e];if(t)return Object.keys(t)}else{if(e===a)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var t=this._preds[e];if(t)return Object.keys(t)}successors(e){var t=this._sucs[e];if(t)return Object.keys(t)}neighbors(e){var t=this.predecessors(e);if(t){const r=new Set(t);for(var n of this.successors(e))r.add(n);return Array.from(r.values())}}isLeaf(e){return 0===(this.isDirected()?this.successors(e):this.neighbors(e)).length}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var n=this;Object.entries(this._nodes).forEach((function(n){let[r,o]=n;e(r)&&t.setNode(r,o)})),Object.values(this._edgeObjs).forEach((function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,n.edge(e))}));var r={};function o(e){var a=n.parent(e);return void 0===a||t.hasNode(a)?(r[e]=a,a):a in r?r[a]:o(a)}return this._isCompound&&t.nodes().forEach((e=>t.setParent(e,o(e)))),t}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,"function"!==typeof e&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,t){var n=this,r=arguments;return e.reduce((function(e,o){return r.length>1?n.setEdge(e,o,t):n.setEdge(e,o),o})),this}setEdge(){var e,t,n,r,o=!1,a=arguments[0];"object"===typeof a&&null!==a&&"v"in a?(e=a.v,t=a.w,n=a.name,2===arguments.length&&(r=arguments[1],o=!0)):(e=a,t=arguments[1],n=arguments[3],arguments.length>2&&(r=arguments[2],o=!0)),e=""+e,t=""+t,void 0!==n&&(n=""+n);var i=c(this._isDirected,e,t,n);if(this._edgeLabels.hasOwnProperty(i))return o&&(this._edgeLabels[i]=r),this;if(void 0!==n&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(t),this._edgeLabels[i]=o?r:this._defaultEdgeLabelFn(e,t,n);var l=function(e,t,n,r){var o=""+t,a=""+n;if(!e&&o>a){var i=o;o=a,a=i}var s={v:o,w:a};r&&(s.name=r);return s}(this._isDirected,e,t,n);return e=l.v,t=l.w,Object.freeze(l),this._edgeObjs[i]=l,s(this._preds[t],e),s(this._sucs[e],t),this._in[t][i]=l,this._out[e][i]=l,this._edgeCount++,this}edge(e,t,n){var r=1===arguments.length?u(this._isDirected,arguments[0]):c(this._isDirected,e,t,n);return this._edgeLabels[r]}edgeAsObj(){const e=this.edge(...arguments);return"object"!==typeof e?{label:e}:e}hasEdge(e,t,n){var r=1===arguments.length?u(this._isDirected,arguments[0]):c(this._isDirected,e,t,n);return this._edgeLabels.hasOwnProperty(r)}removeEdge(e,t,n){var r=1===arguments.length?u(this._isDirected,arguments[0]):c(this._isDirected,e,t,n),o=this._edgeObjs[r];return o&&(e=o.v,t=o.w,delete this._edgeLabels[r],delete this._edgeObjs[r],l(this._preds[t],e),l(this._sucs[e],t),delete this._in[t][r],delete this._out[e][r],this._edgeCount--),this}inEdges(e,t){var n=this._in[e];if(n){var r=Object.values(n);return t?r.filter((e=>e.v===t)):r}}outEdges(e,t){var n=this._out[e];if(n){var r=Object.values(n);return t?r.filter((e=>e.w===t)):r}}nodeEdges(e,t){var n=this.inEdges(e,t);if(n)return n.concat(this.outEdges(e,t))}}},38441:(e,t,n)=>{e.exports={Graph:n(39509),version:n(64905)}},84555:(e,t,n)=>{var r=n(39509);function o(e){return e.nodes().map((function(t){var n=e.node(t),r=e.parent(t),o={v:t};return void 0!==n&&(o.value=n),void 0!==r&&(o.parent=r),o}))}function a(e){return e.edges().map((function(t){var n=e.edge(t),r={v:t.v,w:t.w};return void 0!==t.name&&(r.name=t.name),void 0!==n&&(r.value=n),r}))}e.exports={write:function(e){var t={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:o(e),edges:a(e)};void 0!==e.graph()&&(t.value=structuredClone(e.graph()));return t},read:function(e){var t=new r(e.options).setGraph(e.value);return e.nodes.forEach((function(e){t.setNode(e.v,e.value),e.parent&&t.setParent(e.v,e.parent)})),e.edges.forEach((function(e){t.setEdge({v:e.v,w:e.w,name:e.name},e.value)})),t}}},64905:e=>{e.exports="2.2.2"},16491:(e,t,n)=>{"use strict";n.d(t,{A:()=>b});var r=n(58168),o=n(98587),a=n(9950),i=n(72004),s=n(36547),l=n(70505),c=n(80237),u=n(7148),d=n(44414);const p=["className","component"];var f=n(44501),h=n(24436),m=n(67550);const g=(0,n(1763).A)("MuiBox",["root"]),v=(0,h.A)(),y=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{themeId:t,defaultTheme:n,defaultClassName:f="MuiBox-root",generateClassName:h}=e,m=(0,s.Ay)("div",{shouldForwardProp:e=>"theme"!==e&&"sx"!==e&&"as"!==e})(l.A);return a.forwardRef((function(e,a){const s=(0,u.A)(n),l=(0,c.A)(e),{className:g,component:v="div"}=l,y=(0,o.A)(l,p);return(0,d.jsx)(m,(0,r.A)({as:v,ref:a,className:(0,i.A)(g,h?h(f):f),theme:t&&s[t]||s},y))}))}({themeId:m.A,defaultTheme:v,defaultClassName:g.root,generateClassName:f.A.generate}),b=y},48089:(e,t,n)=>{"use strict";n.d(t,{A:()=>v});var r=n(59703),o=n(85486),a=n(9950),i=n(72004),s=n(88465),l=n(59254),c=n(48283),u=n(2235),d=n(1763),p=n(423);function f(e){return(0,p.Ay)("MuiCard",e)}(0,d.A)("MuiCard",["root"]);var h=n(44414);const m=["className","raised"],g=(0,l.Ay)(u.A,{name:"MuiCard",slot:"Root",overridesResolver:(e,t)=>t.root})((()=>({overflow:"hidden"}))),v=a.forwardRef((function(e,t){const n=(0,c.A)({props:e,name:"MuiCard"}),{className:a,raised:l=!1}=n,u=(0,o.A)(n,m),d=(0,r.A)({},n,{raised:l}),p=(e=>{const{classes:t}=e;return(0,s.A)({root:["root"]},f,t)})(d);return(0,h.jsx)(g,(0,r.A)({className:(0,i.A)(p.root,a),elevation:l?8:void 0,ref:t,ownerState:d},u))}))},38039:(e,t,n)=>{"use strict";n.d(t,{A:()=>b});var r=n(59703),o=n(85486),a=n(9950),i=n(72004),s=n(88465),l=n(48283),c=n(59254),u=n(1763),d=n(423);function p(e){return(0,d.Ay)("MuiCardActionArea",e)}const f=(0,u.A)("MuiCardActionArea",["root","focusVisible","focusHighlight"]);var h=n(24184),m=n(44414);const g=["children","className","focusVisibleClassName"],v=(0,c.Ay)(h.A,{name:"MuiCardActionArea",slot:"Root",overridesResolver:(e,t)=>t.root})((e=>{let{theme:t}=e;return{display:"block",textAlign:"inherit",borderRadius:"inherit",width:"100%",["&:hover .".concat(f.focusHighlight)]:{opacity:(t.vars||t).palette.action.hoverOpacity,"@media (hover: none)":{opacity:0}},["&.".concat(f.focusVisible," .").concat(f.focusHighlight)]:{opacity:(t.vars||t).palette.action.focusOpacity}}})),y=(0,c.Ay)("span",{name:"MuiCardActionArea",slot:"FocusHighlight",overridesResolver:(e,t)=>t.focusHighlight})((e=>{let{theme:t}=e;return{overflow:"hidden",pointerEvents:"none",position:"absolute",top:0,right:0,bottom:0,left:0,borderRadius:"inherit",opacity:0,backgroundColor:"currentcolor",transition:t.transitions.create("opacity",{duration:t.transitions.duration.short})}})),b=a.forwardRef((function(e,t){const n=(0,l.A)({props:e,name:"MuiCardActionArea"}),{children:a,className:c,focusVisibleClassName:u}=n,d=(0,o.A)(n,g),f=n,h=(e=>{const{classes:t}=e;return(0,s.A)({root:["root"],focusHighlight:["focusHighlight"]},p,t)})(f);return(0,m.jsxs)(v,(0,r.A)({className:(0,i.A)(h.root,c),focusVisibleClassName:(0,i.A)(u,h.focusVisible),ref:t,ownerState:f},d,{children:[a,(0,m.jsx)(y,{className:h.focusHighlight,ownerState:f})]}))}))},50704:(e,t,n)=>{"use strict";n.d(t,{A:()=>g});var r=n(59703),o=n(85486),a=n(9950),i=n(72004),s=n(88465),l=n(59254),c=n(48283),u=n(1763),d=n(423);function p(e){return(0,d.Ay)("MuiCardContent",e)}(0,u.A)("MuiCardContent",["root"]);var f=n(44414);const h=["className","component"],m=(0,l.Ay)("div",{name:"MuiCardContent",slot:"Root",overridesResolver:(e,t)=>t.root})((()=>({padding:16,"&:last-child":{paddingBottom:24}}))),g=a.forwardRef((function(e,t){const n=(0,c.A)({props:e,name:"MuiCardContent"}),{className:a,component:l="div"}=n,u=(0,o.A)(n,h),d=(0,r.A)({},n,{component:l}),g=(e=>{const{classes:t}=e;return(0,s.A)({root:["root"]},p,t)})(d);return(0,f.jsx)(m,(0,r.A)({as:l,className:(0,i.A)(g.root,a),ownerState:d,ref:t},u))}))},45180:(e,t,n)=>{"use strict";n.d(t,{A:()=>x});var r=n(85486),o=n(59703),a=n(9950),i=n(72004),s=n(88465),l=n(82053),c=n(48283),u=n(59254),d=n(1763),p=n(423);function f(e){return(0,p.Ay)("MuiCardHeader",e)}const h=(0,d.A)("MuiCardHeader",["root","avatar","action","content","title","subheader"]);var m=n(44414);const g=["action","avatar","className","component","disableTypography","subheader","subheaderTypographyProps","title","titleTypographyProps"],v=(0,u.Ay)("div",{name:"MuiCardHeader",slot:"Root",overridesResolver:(e,t)=>(0,o.A)({["& .".concat(h.title)]:t.title,["& .".concat(h.subheader)]:t.subheader},t.root)})({display:"flex",alignItems:"center",padding:16}),y=(0,u.Ay)("div",{name:"MuiCardHeader",slot:"Avatar",overridesResolver:(e,t)=>t.avatar})({display:"flex",flex:"0 0 auto",marginRight:16}),b=(0,u.Ay)("div",{name:"MuiCardHeader",slot:"Action",overridesResolver:(e,t)=>t.action})({flex:"0 0 auto",alignSelf:"flex-start",marginTop:-4,marginRight:-8,marginBottom:-4}),w=(0,u.Ay)("div",{name:"MuiCardHeader",slot:"Content",overridesResolver:(e,t)=>t.content})({flex:"1 1 auto"}),x=a.forwardRef((function(e,t){const n=(0,c.A)({props:e,name:"MuiCardHeader"}),{action:a,avatar:u,className:d,component:p="div",disableTypography:h=!1,subheader:x,subheaderTypographyProps:C,title:S,titleTypographyProps:A}=n,k=(0,r.A)(n,g),E=(0,o.A)({},n,{component:p,disableTypography:h}),M=(e=>{const{classes:t}=e;return(0,s.A)({root:["root"],avatar:["avatar"],action:["action"],content:["content"],title:["title"],subheader:["subheader"]},f,t)})(E);let I=S;null==I||I.type===l.A||h||(I=(0,m.jsx)(l.A,(0,o.A)({variant:u?"body2":"h5",className:M.title,component:"span",display:"block"},A,{children:I})));let R=x;return null==R||R.type===l.A||h||(R=(0,m.jsx)(l.A,(0,o.A)({variant:u?"body2":"body1",className:M.subheader,color:"text.secondary",component:"span",display:"block"},C,{children:R}))),(0,m.jsxs)(v,(0,o.A)({className:(0,i.A)(M.root,d),as:p,ref:t,ownerState:E},k,{children:[u&&(0,m.jsx)(y,{className:M.avatar,ownerState:E,children:u}),(0,m.jsxs)(w,{className:M.content,ownerState:E,children:[I,R]}),a&&(0,m.jsx)(b,{className:M.action,ownerState:E,children:a})]}))}))},39694:(e,t,n)=>{"use strict";n.d(t,{Ay:()=>N});var r=n(85486),o=n(59703),a=n(9950),i=n(72004),s=n(88465),l=n(13815),c=n(67279),u=n(21209),d=n(31506),p=n(14857),f=n(70576),h=n(70827),m=n(44414);const g=["addEndListener","appear","children","container","direction","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function v(e,t,n){var r;const o=function(e,t,n){const r=t.getBoundingClientRect(),o=n&&n.getBoundingClientRect(),a=(0,h.A)(t);let i;if(t.fakeTransform)i=t.fakeTransform;else{const e=a.getComputedStyle(t);i=e.getPropertyValue("-webkit-transform")||e.getPropertyValue("transform")}let s=0,l=0;if(i&&"none"!==i&&"string"===typeof i){const e=i.split("(")[1].split(")")[0].split(",");s=parseInt(e[4],10),l=parseInt(e[5],10)}return"left"===e?"translateX(".concat(o?o.right+s-r.left:a.innerWidth+s-r.left,"px)"):"right"===e?"translateX(-".concat(o?r.right-o.left-s:r.left+r.width-s,"px)"):"up"===e?"translateY(".concat(o?o.bottom+l-r.top:a.innerHeight+l-r.top,"px)"):"translateY(-".concat(o?r.top-o.top+r.height-l:r.top+r.height-l,"px)")}(e,t,"function"===typeof(r=n)?r():r);o&&(t.style.webkitTransform=o,t.style.transform=o)}const y=a.forwardRef((function(e,t){const n=(0,p.A)(),i={enter:n.transitions.easing.easeOut,exit:n.transitions.easing.sharp},s={enter:n.transitions.duration.enteringScreen,exit:n.transitions.duration.leavingScreen},{addEndListener:l,appear:y=!0,children:b,container:w,direction:x="down",easing:C=i,in:S,onEnter:A,onEntered:k,onEntering:E,onExit:M,onExited:I,onExiting:R,style:P,timeout:T=s,TransitionComponent:D=c.Ay}=e,N=(0,r.A)(e,g),O=a.useRef(null),_=(0,d.A)(b.ref,O,t),F=e=>t=>{e&&(void 0===t?e(O.current):e(O.current,t))},j=F(((e,t)=>{v(x,e,w),(0,f.q)(e),A&&A(e,t)})),L=F(((e,t)=>{const r=(0,f.c)({timeout:T,style:P,easing:C},{mode:"enter"});e.style.webkitTransition=n.transitions.create("-webkit-transform",(0,o.A)({},r)),e.style.transition=n.transitions.create("transform",(0,o.A)({},r)),e.style.webkitTransform="none",e.style.transform="none",E&&E(e,t)})),z=F(k),H=F(R),V=F((e=>{const t=(0,f.c)({timeout:T,style:P,easing:C},{mode:"exit"});e.style.webkitTransition=n.transitions.create("-webkit-transform",t),e.style.transition=n.transitions.create("transform",t),v(x,e,w),M&&M(e)})),B=F((e=>{e.style.webkitTransition="",e.style.transition="",I&&I(e)})),U=a.useCallback((()=>{O.current&&v(x,O.current,w)}),[x,w]);return a.useEffect((()=>{if(S||"down"===x||"right"===x)return;const e=(0,u.A)((()=>{O.current&&v(x,O.current,w)})),t=(0,h.A)(O.current);return t.addEventListener("resize",e),()=>{e.clear(),t.removeEventListener("resize",e)}}),[x,S,w]),a.useEffect((()=>{S||U()}),[S,U]),(0,m.jsx)(D,(0,o.A)({nodeRef:O,onEnter:j,onEntered:z,onEntering:L,onExit:V,onExited:B,onExiting:H,addEndListener:e=>{l&&l(O.current,e)},appear:y,in:S,