import{a as e,r as t,t as n}from"./isObject-BNleAbAq.js";import{F as r,P as i,_ as a,g as o,i as ee,v as te,x as s}from"./isArrayLikeObject-CpNOZLZH.js";import{_ as c,b as l,c as u,g as d,h as f,m as p,u as m,v as h,w as ne,x as g}from"./graphlib-DIH_KtCr.js";import{a as _,c as re,i as v,n as y,o as b,r as x,s as S,t as ie,u as ae}from"./_initCloneObject-BuQ4-jhh.js";function oe(e,t){return e&&S(t,g(t),e)}function se(e,t){return e&&S(t,b(t),e)}function ce(e,t){return S(e,c(e),t)}var C=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)l(t,c(e)),e=_(e);return t}:h;function le(e,t){return S(e,C(e),t)}function w(e){return d(e,b,C)}var T=Object.prototype.hasOwnProperty;function E(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]==`string`&&T.call(e,`index`)&&(n.index=e.index,n.input=e.input),n}function D(e,t){var n=t?x(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var O=/\w*$/;function k(e){var t=new e.constructor(e.source,O.exec(e));return t.lastIndex=e.lastIndex,t}var A=e?e.prototype:void 0,j=A?A.valueOf:void 0;function M(e){return j?Object(j.call(e)):{}}var N=`[object Boolean]`,P=`[object Date]`,F=`[object Map]`,I=`[object Number]`,L=`[object RegExp]`,R=`[object Set]`,z=`[object String]`,B=`[object Symbol]`,V=`[object ArrayBuffer]`,H=`[object DataView]`,U=`[object Float32Array]`,W=`[object Float64Array]`,ue=`[object Int8Array]`,de=`[object Int16Array]`,fe=`[object Int32Array]`,pe=`[object Uint8Array]`,me=`[object Uint8ClampedArray]`,he=`[object Uint16Array]`,ge=`[object Uint32Array]`;function _e(e,t,n){var r=e.constructor;switch(t){case V:return x(e);case N:case P:return new r(+e);case H:return D(e,n);case U:case W:case ue:case de:case fe:case pe:case me:case he:case ge:return y(e,n);case F:return new r;case I:case z:return new r(e);case L:return k(e);case R:return new r;case B:return M(e)}}var ve=`[object Map]`;function ye(e){return t(e)&&p(e)==ve}var G=o&&o.isMap,be=G?a(G):ye,xe=`[object Set]`;function Se(e){return t(e)&&p(e)==xe}var K=o&&o.isSet,Ce=K?a(K):Se,we=1,Te=2,Ee=4,q=`[object Arguments]`,De=`[object Array]`,Oe=`[object Boolean]`,ke=`[object Date]`,Ae=`[object Error]`,J=`[object Function]`,je=`[object GeneratorFunction]`,Me=`[object Map]`,Ne=`[object Number]`,Y=`[object Object]`,Pe=`[object RegExp]`,Fe=`[object Set]`,Ie=`[object String]`,Le=`[object Symbol]`,Re=`[object WeakMap]`,ze=`[object ArrayBuffer]`,Be=`[object DataView]`,Ve=`[object Float32Array]`,He=`[object Float64Array]`,Ue=`[object Int8Array]`,We=`[object Int16Array]`,X=`[object Int32Array]`,Ge=`[object Uint8Array]`,Ke=`[object Uint8ClampedArray]`,qe=`[object Uint16Array]`,Je=`[object Uint32Array]`,Z={};Z[q]=Z[De]=Z[ze]=Z[Be]=Z[Oe]=Z[ke]=Z[Ve]=Z[He]=Z[Ue]=Z[We]=Z[X]=Z[Me]=Z[Ne]=Z[Y]=Z[Pe]=Z[Fe]=Z[Ie]=Z[Le]=Z[Ge]=Z[Ke]=Z[qe]=Z[Je]=!0,Z[Ae]=Z[J]=Z[Re]=!1;function Q(e,t,r,a,o,s){var c,l=t&we,u=t&Te,d=t&Ee;if(r&&(c=o?r(e,a,o,s):r(e)),c!==void 0)return c;if(!n(e))return e;var m=i(e);if(m){if(c=E(e),!l)return ae(e,c)}else{var h=p(e),_=h==J||h==je;if(te(e))return v(e,l);if(h==Y||h==q||_&&!o){if(c=u||_?{}:ie(e),!l)return u?le(e,se(c,e)):ce(e,oe(c,e))}else{if(!Z[h])return o?e:{};c=_e(e,h,l)}}s||=new ee;var y=s.get(e);if(y)return y;s.set(e,c),Ce(e)?e.forEach(function(n){c.add(Q(n,t,r,n,e,s))}):be(e)&&e.forEach(function(n,i){c.set(i,Q(n,t,r,i,e,s))});var x=m?void 0:(d?u?w:f:u?b:g)(e);return ne(x||e,function(n,i){x&&(i=n,n=e[i]),re(c,i,Q(n,t,r,i,e,s))}),c}function $(e,t){var n=-1,r=s(e)?Array(e.length):[];return u(e,function(e,i,a){r[++n]=t(e,i,a)}),r}function Ye(e,t){return(i(e)?r:$)(e,m(t,3))}export{$ as n,Q as r,Ye as t};