@applica-software-guru/react-admin 1.4.187 → 1.4.188

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -97,7 +97,7 @@ function print() { __p += __j.call(arguments, '') }
97
97
  }`;var Ke=e1(function(){return tt(T,Qe+"return "+le).apply(n,k)});if(Ke.source=le,Lp(Ke))throw Ke;return Ke}function JX(i){return st(i).toLowerCase()}function XX(i){return st(i).toUpperCase()}function ZX(i,l,d){if(i=st(i),i&&(d||l===n))return cQ(i);if(!i||!(l=Ln(l)))return i;var I=Cr(i),y=Cr(l),T=uQ(I,y),k=AQ(I,y)+1;return Lo(I,T,k).join("")}function _X(i,l,d){if(i=st(i),i&&(d||l===n))return i.slice(0,gQ(i)+1);if(!i||!(l=Ln(l)))return i;var I=Cr(i),y=AQ(I,Cr(l))+1;return Lo(I,0,y).join("")}function qX(i,l,d){if(i=st(i),i&&(d||l===n))return i.replace(Xr,"");if(!i||!(l=Ln(l)))return i;var I=Cr(i),y=uQ(I,Cr(l));return Lo(I,y).join("")}function $X(i,l){var d=ee,I=G;if(wt(l)){var y="separator"in l?l.separator:y;d="length"in l?We(l.length):d,I="omission"in l?Ln(l.omission):I}i=st(i);var T=i.length;if(ws(i)){var k=Cr(i);T=k.length}if(d>=T)return i;var V=d-Ts(I);if(V<1)return I;var Y=k?Lo(k,0,V).join(""):i.slice(0,V);if(y===n)return Y+I;if(k&&(V+=Y.length-V),Np(y)){if(i.slice(V).search(y)){var oe,ie=Y;for(y.global||(y=tp(y.source,st(za.exec(y))+"g")),y.lastIndex=0;oe=y.exec(ie);)var le=oe.index;Y=Y.slice(0,le===n?V:le)}}else if(i.indexOf(Ln(y),V)!=V){var Ie=Y.lastIndexOf(y);Ie>-1&&(Y=Y.slice(0,Ie))}return Y+I}function eZ(i){return i=st(i),i&&Au.test(i)?i.replace(uu,SU):i}var tZ=ks(function(i,l,d){return i+(d?" ":"")+l.toUpperCase()}),zp=tx("toUpperCase");function $x(i,l,d){return i=st(i),l=d?n:l,l===n?bU(i)?jU(i):pU(i):i.match(l)||[]}var e1=Je(function(i,l){try{return Rn(i,n,l)}catch(d){return Lp(d)?d:new Le(d)}}),nZ=eo(function(i,l){return rr(l,function(d){d=Dr(d),qr(i,d,Rp(i[d],i))}),i});function rZ(i){var l=i==null?0:i.length,d=je();return i=l?bt(i,function(I){if(typeof I[1]!="function")throw new or(a);return[d(I[0]),I[1]]}):[],Je(function(I){for(var y=-1;++y<l;){var T=i[y];if(Rn(T[0],this,I))return Rn(T[1],this,I)}})}function oZ(i){return SY(sr(i,h))}function Wp(i){return function(){return i}}function iZ(i,l){return i==null||i!==i?l:i}var sZ=rx(),aZ=rx(!0);function Qn(i){return i}function Up(i){return DQ(typeof i=="function"?i:sr(i,h))}function lZ(i){return kQ(sr(i,h))}function cZ(i,l){return RQ(i,sr(l,h))}var uZ=Je(function(i,l){return function(d){return _a(d,i,l)}}),AZ=Je(function(i,l){return function(d){return _a(i,d,l)}});function Yp(i,l,d){var I=Xt(l),y=Nu(l,I);d==null&&!(wt(l)&&(y.length||!I.length))&&(d=l,l=i,i=this,y=Nu(l,Xt(l)));var T=!(wt(d)&&"chain"in d)||!!d.chain,k=no(i);return rr(y,function(V){var Y=l[V];i[V]=Y,k&&(i.prototype[V]=function(){var oe=this.__chain__;if(T||oe){var ie=i(this.__wrapped__),le=ie.__actions__=vn(this.__actions__);return le.push({func:Y,args:arguments,thisArg:i}),ie.__chain__=oe,ie}return Y.apply(i,jo([this.value()],arguments))})}),i}function dZ(){return Zt._===this&&(Zt._=LU),this}function Gp(){}function gZ(i){return i=We(i),Je(function(l){return FQ(l,i)})}var fZ=yp(bt),pZ=yp(oQ),hZ=yp(Jf);function t1(i){return Pp(i)?Xf(Dr(i)):GY(i)}function CZ(i){return function(l){return i==null?n:xi(i,l)}}var EZ=ix(),IZ=ix(!0);function Kp(){return[]}function Jp(){return!1}function mZ(){return{}}function BZ(){return""}function vZ(){return!0}function yZ(i,l){if(i=We(i),i<1||i>N)return[];var d=X,I=on(i,X);l=je(l),i-=X;for(var y=qf(I,l);++d<i;)l(d);return y}function bZ(i){return Ne(i)?bt(i,Dr):Nn(i)?[i]:vn(Bx(st(i)))}function QZ(i){var l=++RU;return st(i)+l}var xZ=Yu(function(i,l){return i+l},0),wZ=bp("ceil"),TZ=Yu(function(i,l){return i/l},1),SZ=bp("floor");function PZ(i){return i&&i.length?Lu(i,Qn,cp):n}function OZ(i,l){return i&&i.length?Lu(i,je(l,2),cp):n}function jZ(i){return aQ(i,Qn)}function DZ(i,l){return aQ(i,je(l,2))}function MZ(i){return i&&i.length?Lu(i,Qn,gp):n}function kZ(i,l){return i&&i.length?Lu(i,je(l,2),gp):n}var RZ=Yu(function(i,l){return i*l},1),FZ=bp("round"),LZ=Yu(function(i,l){return i-l},0);function NZ(i){return i&&i.length?_f(i,Qn):0}function VZ(i,l){return i&&i.length?_f(i,je(l,2)):0}return w.after=lJ,w.ary=jx,w.assign=XJ,w.assignIn=Gx,w.assignInWith=oA,w.assignWith=ZJ,w.at=_J,w.before=Dx,w.bind=Rp,w.bindAll=nZ,w.bindKey=Mx,w.castArray=mJ,w.chain=Sx,w.chunk=SG,w.compact=PG,w.concat=OG,w.cond=rZ,w.conforms=oZ,w.constant=Wp,w.countBy=NK,w.create=qJ,w.curry=kx,w.curryRight=Rx,w.debounce=Fx,w.defaults=$J,w.defaultsDeep=eX,w.defer=cJ,w.delay=uJ,w.difference=jG,w.differenceBy=DG,w.differenceWith=MG,w.drop=kG,w.dropRight=RG,w.dropRightWhile=FG,w.dropWhile=LG,w.fill=NG,w.filter=HK,w.flatMap=UK,w.flatMapDeep=YK,w.flatMapDepth=GK,w.flatten=Qx,w.flattenDeep=VG,w.flattenDepth=HG,w.flip=AJ,w.flow=sZ,w.flowRight=aZ,w.fromPairs=zG,w.functions=aX,w.functionsIn=lX,w.groupBy=KK,w.initial=UG,w.intersection=YG,w.intersectionBy=GG,w.intersectionWith=KG,w.invert=uX,w.invertBy=AX,w.invokeMap=XK,w.iteratee=Up,w.keyBy=ZK,w.keys=Xt,w.keysIn=bn,w.map=qu,w.mapKeys=gX,w.mapValues=fX,w.matches=lZ,w.matchesProperty=cZ,w.memoize=eA,w.merge=pX,w.mergeWith=Kx,w.method=uZ,w.methodOf=AZ,w.mixin=Yp,w.negate=tA,w.nthArg=gZ,w.omit=hX,w.omitBy=CX,w.once=dJ,w.orderBy=_K,w.over=fZ,w.overArgs=gJ,w.overEvery=pZ,w.overSome=hZ,w.partial=Fp,w.partialRight=Lx,w.partition=qK,w.pick=EX,w.pickBy=Jx,w.property=t1,w.propertyOf=CZ,w.pull=_G,w.pullAll=wx,w.pullAllBy=qG,w.pullAllWith=$G,w.pullAt=eK,w.range=EZ,w.rangeRight=IZ,w.rearg=fJ,w.reject=tJ,w.remove=tK,w.rest=pJ,w.reverse=Mp,w.sampleSize=rJ,w.set=mX,w.setWith=BX,w.shuffle=oJ,w.slice=nK,w.sortBy=aJ,w.sortedUniq=cK,w.sortedUniqBy=uK,w.split=UX,w.spread=hJ,w.tail=AK,w.take=dK,w.takeRight=gK,w.takeRightWhile=fK,w.takeWhile=pK,w.tap=PK,w.throttle=CJ,w.thru=_u,w.toArray=Wx,w.toPairs=Xx,w.toPairsIn=Zx,w.toPath=bZ,w.toPlainObject=Yx,w.transform=vX,w.unary=EJ,w.union=hK,w.unionBy=CK,w.unionWith=EK,w.uniq=IK,w.uniqBy=mK,w.uniqWith=BK,w.unset=yX,w.unzip=kp,w.unzipWith=Tx,w.update=bX,w.updateWith=QX,w.values=Ls,w.valuesIn=xX,w.without=vK,w.words=$x,w.wrap=IJ,w.xor=yK,w.xorBy=bK,w.xorWith=QK,w.zip=xK,w.zipObject=wK,w.zipObjectDeep=TK,w.zipWith=SK,w.entries=Xx,w.entriesIn=Zx,w.extend=Gx,w.extendWith=oA,Yp(w,w),w.add=xZ,w.attempt=e1,w.camelCase=PX,w.capitalize=_x,w.ceil=wZ,w.clamp=wX,w.clone=BJ,w.cloneDeep=yJ,w.cloneDeepWith=bJ,w.cloneWith=vJ,w.conformsTo=QJ,w.deburr=qx,w.defaultTo=iZ,w.divide=TZ,w.endsWith=OX,w.eq=Ir,w.escape=jX,w.escapeRegExp=DX,w.every=VK,w.find=zK,w.findIndex=yx,w.findKey=tX,w.findLast=WK,w.findLastIndex=bx,w.findLastKey=nX,w.floor=SZ,w.forEach=Px,w.forEachRight=Ox,w.forIn=rX,w.forInRight=oX,w.forOwn=iX,w.forOwnRight=sX,w.get=Vp,w.gt=xJ,w.gte=wJ,w.has=cX,w.hasIn=Hp,w.head=xx,w.identity=Qn,w.includes=JK,w.indexOf=WG,w.inRange=TX,w.invoke=dX,w.isArguments=Si,w.isArray=Ne,w.isArrayBuffer=TJ,w.isArrayLike=yn,w.isArrayLikeObject=kt,w.isBoolean=SJ,w.isBuffer=No,w.isDate=PJ,w.isElement=OJ,w.isEmpty=jJ,w.isEqual=DJ,w.isEqualWith=MJ,w.isError=Lp,w.isFinite=kJ,w.isFunction=no,w.isInteger=Nx,w.isLength=nA,w.isMap=Vx,w.isMatch=RJ,w.isMatchWith=FJ,w.isNaN=LJ,w.isNative=NJ,w.isNil=HJ,w.isNull=VJ,w.isNumber=Hx,w.isObject=wt,w.isObjectLike=jt,w.isPlainObject=rl,w.isRegExp=Np,w.isSafeInteger=zJ,w.isSet=zx,w.isString=rA,w.isSymbol=Nn,w.isTypedArray=Fs,w.isUndefined=WJ,w.isWeakMap=UJ,w.isWeakSet=YJ,w.join=JG,w.kebabCase=MX,w.last=lr,w.lastIndexOf=XG,w.lowerCase=kX,w.lowerFirst=RX,w.lt=GJ,w.lte=KJ,w.max=PZ,w.maxBy=OZ,w.mean=jZ,w.meanBy=DZ,w.min=MZ,w.minBy=kZ,w.stubArray=Kp,w.stubFalse=Jp,w.stubObject=mZ,w.stubString=BZ,w.stubTrue=vZ,w.multiply=RZ,w.nth=ZG,w.noConflict=dZ,w.noop=Gp,w.now=$u,w.pad=FX,w.padEnd=LX,w.padStart=NX,w.parseInt=VX,w.random=SX,w.reduce=$K,w.reduceRight=eJ,w.repeat=HX,w.replace=zX,w.result=IX,w.round=FZ,w.runInContext=U,w.sample=nJ,w.size=iJ,w.snakeCase=WX,w.some=sJ,w.sortedIndex=rK,w.sortedIndexBy=oK,w.sortedIndexOf=iK,w.sortedLastIndex=sK,w.sortedLastIndexBy=aK,w.sortedLastIndexOf=lK,w.startCase=YX,w.startsWith=GX,w.subtract=LZ,w.sum=NZ,w.sumBy=VZ,w.template=KX,w.times=yZ,w.toFinite=ro,w.toInteger=We,w.toLength=Ux,w.toLower=JX,w.toNumber=cr,w.toSafeInteger=JJ,w.toString=st,w.toUpper=XX,w.trim=ZX,w.trimEnd=_X,w.trimStart=qX,w.truncate=$X,w.unescape=eZ,w.uniqueId=QZ,w.upperCase=tZ,w.upperFirst=zp,w.each=Px,w.eachRight=Ox,w.first=xx,Yp(w,function(){var i={};return Or(w,function(l,d){ct.call(w.prototype,d)||(i[d]=l)}),i}(),{chain:!1}),w.VERSION=r,rr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(i){w[i].placeholder=w}),rr(["drop","take"],function(i,l){qe.prototype[i]=function(d){d=d===n?1:Yt(We(d),0);var I=this.__filtered__&&!l?new qe(this):this.clone();return I.__filtered__?I.__takeCount__=on(d,I.__takeCount__):I.__views__.push({size:on(d,X),type:i+(I.__dir__<0?"Right":"")}),I},qe.prototype[i+"Right"]=function(d){return this.reverse()[i](d).reverse()}}),rr(["filter","map","takeWhile"],function(i,l){var d=l+1,I=d==_||d==z;qe.prototype[i]=function(y){var T=this.clone();return T.__iteratees__.push({iteratee:je(y,3),type:d}),T.__filtered__=T.__filtered__||I,T}}),rr(["head","last"],function(i,l){var d="take"+(l?"Right":"");qe.prototype[i]=function(){return this[d](1).value()[0]}}),rr(["initial","tail"],function(i,l){var d="drop"+(l?"":"Right");qe.prototype[i]=function(){return this.__filtered__?new qe(this):this[d](1)}}),qe.prototype.compact=function(){return this.filter(Qn)},qe.prototype.find=function(i){return this.filter(i).head()},qe.prototype.findLast=function(i){return this.reverse().find(i)},qe.prototype.invokeMap=Je(function(i,l){return typeof i=="function"?new qe(this):this.map(function(d){return _a(d,i,l)})}),qe.prototype.reject=function(i){return this.filter(tA(je(i)))},qe.prototype.slice=function(i,l){i=We(i);var d=this;return d.__filtered__&&(i>0||l<0)?new qe(d):(i<0?d=d.takeRight(-i):i&&(d=d.drop(i)),l!==n&&(l=We(l),d=l<0?d.dropRight(-l):d.take(l-i)),d)},qe.prototype.takeRightWhile=function(i){return this.reverse().takeWhile(i).reverse()},qe.prototype.toArray=function(){return this.take(X)},Or(qe.prototype,function(i,l){var d=/^(?:filter|find|map|reject)|While$/.test(l),I=/^(?:head|last)$/.test(l),y=w[I?"take"+(l=="last"?"Right":""):l],T=I||/^find/.test(l);y&&(w.prototype[l]=function(){var k=this.__wrapped__,V=I?[1]:arguments,Y=k instanceof qe,oe=V[0],ie=Y||Ne(k),le=function(Ze){var $e=y.apply(w,jo([Ze],V));return I&&Ie?$e[0]:$e};ie&&d&&typeof oe=="function"&&oe.length!=1&&(Y=ie=!1);var Ie=this.__chain__,Qe=!!this.__actions__.length,De=T&&!Ie,Ke=Y&&!Qe;if(!T&&ie){k=Ke?k:new qe(this);var Me=i.apply(k,V);return Me.__actions__.push({func:_u,args:[le],thisArg:n}),new ir(Me,Ie)}return De&&Ke?i.apply(this,V):(Me=this.thru(le),De?I?Me.value()[0]:Me.value():Me)})}),rr(["pop","push","shift","sort","splice","unshift"],function(i){var l=yu[i],d=/^(?:push|sort|unshift)$/.test(i)?"tap":"thru",I=/^(?:pop|shift)$/.test(i);w.prototype[i]=function(){var y=arguments;if(I&&!this.__chain__){var T=this.value();return l.apply(Ne(T)?T:[],y)}return this[d](function(k){return l.apply(Ne(k)?k:[],y)})}}),Or(qe.prototype,function(i,l){var d=w[l];if(d){var I=d.name+"";ct.call(js,I)||(js[I]=[]),js[I].push({name:l,func:d})}}),js[Uu(n,S).name]=[{name:"wrapper",func:n}],qe.prototype.clone=eY,qe.prototype.reverse=tY,qe.prototype.value=nY,w.prototype.at=OK,w.prototype.chain=jK,w.prototype.commit=DK,w.prototype.next=MK,w.prototype.plant=RK,w.prototype.reverse=FK,w.prototype.toJSON=w.prototype.valueOf=w.prototype.value=LK,w.prototype.first=w.prototype.head,Ua&&(w.prototype[Ua]=kK),w},Ss=DU();Bi?((Bi.exports=Ss)._=Ss,Uf._=Ss):Zt._=Ss}).call(dn)}(Sl,Sl.exports);var at=Sl.exports;const ne=Mr(at),vr=()=>{throw new Error("Method must be implemented")},Zh={fontFamily:"'Inter', sans-serif",menuOrientation:"vertical",miniDrawer:!1,container:!1,mode:"light",presetColor:"theme4",themeDirection:"ltr",appDefaultPath:"/",drawerWidth:260,horizontalMaxItems:6,spacing:2,setFontFamily:vr,setMenuOrientation:vr,setMiniDrawer:vr,setContainer:vr,setMode:vr,setPresetColor:vr,setThemeDirection:vr,setAppDefaultPath:vr,setDrawerWidth:vr,setHorizontalMaxItems:vr},VA=Q.createContext(Zh),YT=e=>e==="vertical",GT=e=>e==="horizontal",Pl=({initialConfig:e,children:t})=>{const[n,r]=Ll("theme-config",{...Zh,...e}),o=m=>r(B=>({...B,fontFamily:m})),s=m=>r(B=>({...B,menuOrientation:m})),a=m=>r(B=>({...B,miniDrawer:m})),c=m=>r(B=>({...B,container:m})),u=m=>r(B=>({...B,mode:m})),A=m=>r(B=>({...B,presetColor:m})),p=m=>r(B=>({...B,themeDirection:m})),h=m=>r(B=>({...B,appDefaultPath:m})),C=m=>r(B=>({...B,drawerWidth:m})),E=m=>r(B=>({...B,horizontalMaxItems:m}));return g.jsx(VA.Provider,{value:{...n,setFontFamily:o,setMenuOrientation:s,setMiniDrawer:a,setContainer:c,setMode:u,setPresetColor:A,setThemeDirection:p,setAppDefaultPath:h,setDrawerWidth:C,setHorizontalMaxItems:E,isVerticalLayout:YT,isHorizontalLayout:GT},children:t})};Pl.propTypes={children:f.node};const Ks=()=>{throw new Error("Not implemented")},_h={openItem:["dashboard"],openComponent:"buttons",selectedID:null,drawerOpen:!1,error:null,menu:[],activeItem:Ks,openDrawer:Ks,activeID:Ks,hasError:Ks,setMenu:Ks},HA=Q.createContext(_h),qh=({menu:e,children:t})=>{const[n,r]=Ll("menu-config",{..._h,menu:e}),o=A=>r(p=>({...p,menu:A})),s=A=>r(p=>({...p,openItem:A})),a=A=>r(p=>({...p,selectedID:A})),c=A=>r(p=>({...p,drawerOpen:A})),u=A=>r(p=>({...p,error:A}));return Q.useEffect(()=>{o(e)},[e]),g.jsx(HA.Provider,{value:{...n,setMenu:o,activeItem:s,openDrawer:c,activeID:a,hasError:u},children:t})},zA=Q.createContext(void 0),WA=Q.createContext(void 0),Go=()=>Q.useContext(HA),KT=["e-","entities/"],JT=e=>{let t=e;return KT.forEach(n=>{t=t!=null&&t.startsWith(n)?t==null?void 0:t.substring(n.length):t}),t},XT=(e,t)=>{var n,r;return((n=t.options)==null?void 0:n.group)===e.id||!((r=t.options)!=null&&r.group)&&e.id==="admin"},ZT=(e,t)=>{const n=JT(e.name);return(t==null?void 0:t.includes(`${n}:list`))||(t==null?void 0:t.includes(`${n}:find`))},UA=(e,t)=>{let n=e.find(r=>r.id===t);if(!n)for(let r=0;r<e.length;r++){const o=e[r];if(o.children&&(n=UA(o.children,t),n))return n}return n},$h=(e,t,n)=>{let r=e.find(o=>["group","collapse"].indexOf(o.type)!==-1&&XT(o,t));if(!r)for(let o=0;o<e.length;o++){const s=e[o];if(s.children&&(r=$h(s.children,t),r))return r}return r},eC=(e,t)=>{let n=e.find(r=>r.id===t);if(!n)for(let r=0;r<e.length;r++){const o=e[r];if(o.children&&(n=eC(o.children,t),n))return n}return n},tC=e=>e?e.type==="item"?!0:(e.children&&(e.children=e.children.filter(tC)),e.children&&e.children.length>0):!1,nC=e=>(e.children&&e.children.forEach(t=>{t.parent=e,nC(t)}),e),_T=({userMenu:e,resources:t,permissions:n,translate:r,roles:o})=>{const s=h=>(h.title=r(h.title,{_:h.title}),h.children&&h.children.forEach(C=>s(C)),h),a=Object.keys(t),c=(h,C)=>(h.children&&(h.children=h.children.filter(E=>{if(E.resource===!1){const m=E.roles||[];return!!(m.length===0||m.some(B=>o.includes(B)))}return E.type==="item"?C.includes(E.id):(c(E,C),E.children&&E.children.length>0)})),h),u=at.cloneDeep(e).map(h=>({type:"group",icon:_e.AntDesignOutlined,children:[],...h})).map(s).map(h=>c(h,a)),A=Object.values(t).map(h=>{var C;return((C=h.options)==null?void 0:C.group)||"admin"}).filter((h,C,E)=>E.indexOf(h)===C).filter(h=>h!==void 0&&eC(e,h)===null).map(h=>({id:h,title:r(`ra.menu.group.${h}`),type:"group",icon:_e.AntDesignOutlined,children:[]})),p=[...u,...A];return Object.values(t).forEach(h=>{var M,x,O,P;const C=$h(p,h),E=(M=C==null?void 0:C.children)==null?void 0:M.find(F=>F.id===h.name),m=(x=C==null?void 0:C.children)==null?void 0:x.some(F=>F.id===h.name),B=(E==null?void 0:E.roles)||((O=h.options)==null?void 0:O.roles)||[],v=!B||B.length===0||B.some(F=>o.includes(F));if(!ZT(h,n)||!h.hasList||!v){m&&((P=C==null?void 0:C.children)==null?void 0:P.length)>0&&(C.children=C.children.filter(F=>F.id!==h.name));return}C&&(C.children||(C.children=[]))}),p.filter(tC).map(nC)},YA=()=>{const e=D.useResourceDefinitions(),{isLoading:t,data:n}=D.useGetIdentity(),r=n&&n.id>0,{isLoading:o,permissions:s}=D.usePermissions(r),{menu:a}=Go(),c=D.useTranslate(),u=Q.useMemo(()=>{if(t||!n||n===null||(n==null?void 0:n.id)<=0)return null;const p=((n==null?void 0:n.roles)||[]).map(C=>C.id);return _T({resources:e,permissions:s,translate:c,userMenu:a,roles:p})},[t,o,n,e,s,c,a]),A=Q.useMemo(()=>t,[t]);return{menu:u,isLoading:A,getItem:p=>A?!1:UA(u,p),findInMenu:A?()=>{}:UA}},rC=()=>{const e=D.useTranslate(),{isLoading:t,menu:n,findInMenu:r}=YA(),{pathname:o}=pt.useLocation();return Q.useMemo(()=>{var h;const s=o.split("/").filter(C=>C);let a=at.cloneDeep(n),c=o,u=r(a,o);if(u||(u=r(a,s[s.length-1]),c=u?u.id:c),!u)for(let C=s.length;C>=0;C--){let E=s.slice(0,C).join("/");if(u=r(a,E),u){c=u.id;break}}const A=(h=u==null?void 0:u.url)==null?void 0:h.split("/");if(s.length>=(A==null?void 0:A.length)){const C=s[s.length-1];if(u){const E=C==="create"||o===u.url?"create":"edit",m=`resources.${c}.breadcrumbs.${E}`,B={id:`${c}-${E}`,type:"item",title:e(m,{_:e(m,{_:m})}),url:o,breadcrumbs:!0,parent:u};u.type="collapse",u.breadcrumbs=!0,u.children=u.children||[],u.children.push(B),u=B}}let p=[];if(u){let C={...u,last:!0};for(;C;)p.push(C),C=C.parent;p=p.reverse()}return{isLoading:t,navigation:{items:a},breadcrumbs:p}},[t,o,n,r,e])};var oC={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(dn,function(){var n=1e3,r=6e4,o=36e5,s="millisecond",a="second",c="minute",u="hour",A="day",p="week",h="month",C="quarter",E="year",m="date",B="Invalid Date",v=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,S=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(_){var q=["th","st","nd","rd"],z=_%100;return"["+_+(q[(z-20)%10]||q[z]||q[0])+"]"}},x=function(_,q,z){var Z=String(_);return!Z||Z.length>=q?_:""+Array(q+1-Z.length).join(z)+_},O={s:x,z:function(_){var q=-_.utcOffset(),z=Math.abs(q),Z=Math.floor(z/60),N=z%60;return(q<=0?"+":"-")+x(Z,2,"0")+":"+x(N,2,"0")},m:function _(q,z){if(q.date()<z.date())return-_(z,q);var Z=12*(z.year()-q.year())+(z.month()-q.month()),N=q.clone().add(Z,h),$=z-N<0,H=q.clone().add(Z+($?-1:1),h);return+(-(Z+(z-N)/($?N-H:H-N))||0)},a:function(_){return _<0?Math.ceil(_)||0:Math.floor(_)},p:function(_){return{M:h,y:E,w:p,d:A,D:m,h:u,m:c,s:a,ms:s,Q:C}[_]||String(_||"").toLowerCase().replace(/s$/,"")},u:function(_){return _===void 0}},P="en",F={};F[P]=M;var L="$isDayjsObject",K=function(_){return _ instanceof se||!(!_||!_[L])},J=function _(q,z,Z){var N;if(!q)return P;if(typeof q=="string"){var $=q.toLowerCase();F[$]&&(N=$),z&&(F[$]=z,N=$);var H=q.split("-");if(!N&&H.length>1)return _(H[0])}else{var X=q.name;F[X]=q,N=X}return!Z&&N&&(P=N),N||!Z&&P},ee=function(_,q){if(K(_))return _.clone();var z=typeof q=="object"?q:{};return z.date=_,z.args=arguments,new se(z)},G=O;G.l=J,G.i=K,G.w=function(_,q){return ee(_,{locale:q.$L,utc:q.$u,x:q.$x,$offset:q.$offset})};var se=function(){function _(z){this.$L=J(z.locale,null,!0),this.parse(z),this.$x=this.$x||z.x||{},this[L]=!0}var q=_.prototype;return q.parse=function(z){this.$d=function(Z){var N=Z.date,$=Z.utc;if(N===null)return new Date(NaN);if(G.u(N))return new Date;if(N instanceof Date)return new Date(N);if(typeof N=="string"&&!/Z$/i.test(N)){var H=N.match(v);if(H){var X=H[2]-1||0,ce=(H[7]||"0").substring(0,3);return $?new Date(Date.UTC(H[1],X,H[3]||1,H[4]||0,H[5]||0,H[6]||0,ce)):new Date(H[1],X,H[3]||1,H[4]||0,H[5]||0,H[6]||0,ce)}}return new Date(N)}(z),this.init()},q.init=function(){var z=this.$d;this.$y=z.getFullYear(),this.$M=z.getMonth(),this.$D=z.getDate(),this.$W=z.getDay(),this.$H=z.getHours(),this.$m=z.getMinutes(),this.$s=z.getSeconds(),this.$ms=z.getMilliseconds()},q.$utils=function(){return G},q.isValid=function(){return this.$d.toString()!==B},q.isSame=function(z,Z){var N=ee(z);return this.startOf(Z)<=N&&N<=this.endOf(Z)},q.isAfter=function(z,Z){return ee(z)<this.startOf(Z)},q.isBefore=function(z,Z){return this.endOf(Z)<ee(z)},q.$g=function(z,Z,N){return G.u(z)?this[Z]:this.set(N,z)},q.unix=function(){return Math.floor(this.valueOf()/1e3)},q.valueOf=function(){return this.$d.getTime()},q.startOf=function(z,Z){var N=this,$=!!G.u(Z)||Z,H=G.p(z),X=function(Ee,Be){var we=G.w(N.$u?Date.UTC(N.$y,Be,Ee):new Date(N.$y,Be,Ee),N);return $?we:we.endOf(A)},ce=function(Ee,Be){return G.w(N.toDate()[Ee].apply(N.toDate("s"),($?[0,0,0,0]:[23,59,59,999]).slice(Be)),N)},he=this.$W,ge=this.$M,fe=this.$D,Ce="set"+(this.$u?"UTC":"");switch(H){case E:return $?X(1,0):X(31,11);case h:return $?X(1,ge):X(0,ge+1);case p:var ve=this.$locale().weekStart||0,me=(he<ve?he+7:he)-ve;return X($?fe-me:fe+(6-me),ge);case A:case m:return ce(Ce+"Hours",0);case u:return ce(Ce+"Minutes",1);case c:return ce(Ce+"Seconds",2);case a:return ce(Ce+"Milliseconds",3);default:return this.clone()}},q.endOf=function(z){return this.startOf(z,!1)},q.$set=function(z,Z){var N,$=G.p(z),H="set"+(this.$u?"UTC":""),X=(N={},N[A]=H+"Date",N[m]=H+"Date",N[h]=H+"Month",N[E]=H+"FullYear",N[u]=H+"Hours",N[c]=H+"Minutes",N[a]=H+"Seconds",N[s]=H+"Milliseconds",N)[$],ce=$===A?this.$D+(Z-this.$W):Z;if($===h||$===E){var he=this.clone().set(m,1);he.$d[X](ce),he.init(),this.$d=he.set(m,Math.min(this.$D,he.daysInMonth())).$d}else X&&this.$d[X](ce);return this.init(),this},q.set=function(z,Z){return this.clone().$set(z,Z)},q.get=function(z){return this[G.p(z)]()},q.add=function(z,Z){var N,$=this;z=Number(z);var H=G.p(Z),X=function(ge){var fe=ee($);return G.w(fe.date(fe.date()+Math.round(ge*z)),$)};if(H===h)return this.set(h,this.$M+z);if(H===E)return this.set(E,this.$y+z);if(H===A)return X(1);if(H===p)return X(7);var ce=(N={},N[c]=r,N[u]=o,N[a]=n,N)[H]||1,he=this.$d.getTime()+z*ce;return G.w(he,this)},q.subtract=function(z,Z){return this.add(-1*z,Z)},q.format=function(z){var Z=this,N=this.$locale();if(!this.isValid())return N.invalidDate||B;var $=z||"YYYY-MM-DDTHH:mm:ssZ",H=G.z(this),X=this.$H,ce=this.$m,he=this.$M,ge=N.weekdays,fe=N.months,Ce=N.meridiem,ve=function(Be,we,de,Xe){return Be&&(Be[we]||Be(Z,$))||de[we].slice(0,Xe)},me=function(Be){return G.s(X%12||12,Be,"0")},Ee=Ce||function(Be,we,de){var Xe=Be<12?"AM":"PM";return de?Xe.toLowerCase():Xe};return $.replace(S,function(Be,we){return we||function(de){switch(de){case"YY":return String(Z.$y).slice(-2);case"YYYY":return G.s(Z.$y,4,"0");case"M":return he+1;case"MM":return G.s(he+1,2,"0");case"MMM":return ve(N.monthsShort,he,fe,3);case"MMMM":return ve(fe,he);case"D":return Z.$D;case"DD":return G.s(Z.$D,2,"0");case"d":return String(Z.$W);case"dd":return ve(N.weekdaysMin,Z.$W,ge,2);case"ddd":return ve(N.weekdaysShort,Z.$W,ge,3);case"dddd":return ge[Z.$W];case"H":return String(X);case"HH":return G.s(X,2,"0");case"h":return me(1);case"hh":return me(2);case"a":return Ee(X,ce,!0);case"A":return Ee(X,ce,!1);case"m":return String(ce);case"mm":return G.s(ce,2,"0");case"s":return String(Z.$s);case"ss":return G.s(Z.$s,2,"0");case"SSS":return G.s(Z.$ms,3,"0");case"Z":return H}return null}(Be)||H.replace(":","")})},q.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},q.diff=function(z,Z,N){var $,H=this,X=G.p(Z),ce=ee(z),he=(ce.utcOffset()-this.utcOffset())*r,ge=this-ce,fe=function(){return G.m(H,ce)};switch(X){case E:$=fe()/12;break;case h:$=fe();break;case C:$=fe()/3;break;case p:$=(ge-he)/6048e5;break;case A:$=(ge-he)/864e5;break;case u:$=ge/o;break;case c:$=ge/r;break;case a:$=ge/n;break;default:$=ge}return N?$:G.a($)},q.daysInMonth=function(){return this.endOf(h).$D},q.$locale=function(){return F[this.$L]},q.locale=function(z,Z){if(!z)return this.$L;var N=this.clone(),$=J(z,Z,!0);return $&&(N.$L=$),N},q.clone=function(){return G.w(this.$d,this)},q.toDate=function(){return new Date(this.valueOf())},q.toJSON=function(){return this.isValid()?this.toISOString():null},q.toISOString=function(){return this.$d.toISOString()},q.toString=function(){return this.$d.toUTCString()},_}(),ae=se.prototype;return ee.prototype=ae,[["$ms",s],["$s",a],["$m",c],["$H",u],["$W",A],["$M",h],["$y",E],["$D",m]].forEach(function(_){ae[_[1]]=function(q){return this.$g(q,_[0],_[1])}}),ee.extend=function(_,q){return _.$i||(_(q,se,ee),_.$i=!0),ee},ee.locale=J,ee.isDayjs=K,ee.unix=function(_){return ee(1e3*_)},ee.en=F[P],ee.Ls=F,ee.p={},ee})})(oC);var iC=oC.exports;const yr=Mr(iC),sC=e=>{const t=e.split(":");t.length===1&&t.push("00");const n=parseInt(t[0]),r=parseInt(t[1]);return yr().hour(n).minute(r)};function qT(){let e=new Date().getTime();return window.performance&&typeof window.performance.now=="function"&&(e+=performance.now()),"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(n){const r=(e+Math.random()*16)%16|0;return e=Math.floor(e/16),(n=="x"?r:r&3|8).toString(16)})}function GA(e={},t=[],n={}){const{isEmpty:r=ne.isEmpty}=n;return!ne.some(t,o=>r((e??{})[o.locale]))}function KA(e,t,n){if(!ne.isPlainObject(e)||t===void 0)return;const r=ne.isPlainObject(n)?n:{},o=!!((r==null?void 0:r.fallback)??!0);let s=e[String(t)];if(s===void 0&&o){const a=ne.isArray(r.fallbackLocales)&&!ne.isEmpty(r.fallbackLocales)?r.fallbackLocales:["en"];s=ne.chain(a).map(c=>e[String(c)]).reject(ne.isUndefined).first().value(),s===void 0&&(s=ne.chain(e).values().first().value())}return s}function Ko(e){this._maxSize=e,this.clear()}Ko.prototype.clear=function(){this._size=0,this._values=Object.create(null)},Ko.prototype.get=function(e){return this._values[e]},Ko.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var $T=/[^.^\]^[]+|(?=\[\]|\.\.)/g,aC=/^\d+$/,eS=/^\d/,tS=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,nS=/^\s*(['"]?)(.*?)(\1)\s*$/,JA=512,lC=new Ko(JA),cC=new Ko(JA),uC=new Ko(JA),Jo={Cache:Ko,split:ZA,normalizePath:XA,setter:function(e){var t=XA(e);return cC.get(e)||cC.set(e,function(r,o){for(var s=0,a=t.length,c=r;s<a-1;){var u=t[s];if(u==="__proto__"||u==="constructor"||u==="prototype")return r;c=c[t[s++]]}c[t[s]]=o})},getter:function(e,t){var n=XA(e);return uC.get(e)||uC.set(e,function(o){for(var s=0,a=n.length;s<a;)if(o!=null||!t)o=o[n[s++]];else return;return o})},join:function(e){return e.reduce(function(t,n){return t+(_A(n)||aC.test(n)?"["+n+"]":(t?".":"")+n)},"")},forEach:function(e,t,n){rS(Array.isArray(e)?e:ZA(e),t,n)}};function XA(e){return lC.get(e)||lC.set(e,ZA(e).map(function(t){return t.replace(nS,"$2")}))}function ZA(e){return e.match($T)||[""]}function rS(e,t,n){var r=e.length,o,s,a,c;for(s=0;s<r;s++)o=e[s],o&&(sS(o)&&(o='"'+o+'"'),c=_A(o),a=!c&&/^\d+$/.test(o),t.call(n,o,c,a,s,e))}function _A(e){return typeof e=="string"&&e&&["'",'"'].indexOf(e.charAt(0))!==-1}function oS(e){return e.match(eS)&&!e.match(aC)}function iS(e){return tS.test(e)}function sS(e){return!_A(e)&&(oS(e)||iS(e))}const aS=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,Ol=e=>e.match(aS)||[],jl=e=>e[0].toUpperCase()+e.slice(1),qA=(e,t)=>Ol(e).join(t).toLowerCase(),AC=e=>Ol(e).reduce((t,n)=>`${t}${t?n[0].toUpperCase()+n.slice(1).toLowerCase():n.toLowerCase()}`,"");var $A={words:Ol,upperFirst:jl,camelCase:AC,pascalCase:e=>jl(AC(e)),snakeCase:e=>qA(e,"_"),kebabCase:e=>qA(e,"-"),sentenceCase:e=>jl(qA(e," ")),titleCase:e=>Ol(e).map(jl).join(" ")},ed={exports:{}};ed.exports=function(e){return dC(lS(e),e)},ed.exports.array=dC;function dC(e,t){var n=e.length,r=new Array(n),o={},s=n,a=cS(t),c=uS(e);for(t.forEach(function(A){if(!c.has(A[0])||!c.has(A[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});s--;)o[s]||u(e[s],s,new Set);return r;function u(A,p,h){if(h.has(A)){var C;try{C=", node was:"+JSON.stringify(A)}catch{C=""}throw new Error("Cyclic dependency"+C)}if(!c.has(A))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(A));if(!o[p]){o[p]=!0;var E=a.get(A)||new Set;if(E=Array.from(E),p=E.length){h.add(A);do{var m=E[--p];u(m,c.get(m),h)}while(p);h.delete(A)}r[--n]=A}}}function lS(e){for(var t=new Set,n=0,r=e.length;n<r;n++){var o=e[n];t.add(o[0]),t.add(o[1])}return Array.from(t)}function cS(e){for(var t=new Map,n=0,r=e.length;n<r;n++){var o=e[n];t.has(o[0])||t.set(o[0],new Set),t.has(o[1])||t.set(o[1],new Set),t.get(o[0]).add(o[1])}return t}function uS(e){for(var t=new Map,n=0,r=e.length;n<r;n++)t.set(e[n],n);return t}var AS=ed.exports;const dS=Mr(AS),gS=Object.prototype.toString,fS=Error.prototype.toString,pS=RegExp.prototype.toString,hS=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",CS=/^Symbol\((.*)\)(.*)$/;function ES(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function gC(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const n=typeof e;if(n==="number")return ES(e);if(n==="string")return t?`"${e}"`:e;if(n==="function")return"[Function "+(e.name||"anonymous")+"]";if(n==="symbol")return hS.call(e).replace(CS,"Symbol($1)");const r=gS.call(e).slice(8,-1);return r==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):r==="Error"||e instanceof Error?"["+fS.call(e)+"]":r==="RegExp"?pS.call(e):null}function co(e,t){let n=gC(e,t);return n!==null?n:JSON.stringify(e,function(r,o){let s=gC(this[r],t);return s!==null?s:o},2)}function fC(e){return e==null?[]:[].concat(e)}let pC,hC,CC,IS=/\$\{\s*(\w+)\s*\}/g;pC=Symbol.toStringTag;class EC{constructor(t,n,r,o){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[pC]="Error",this.name="ValidationError",this.value=n,this.path=r,this.type=o,this.errors=[],this.inner=[],fC(t).forEach(s=>{if(gn.isError(s)){this.errors.push(...s.errors);const a=s.inner.length?s.inner:[s];this.inner.push(...a)}else this.errors.push(s)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}hC=Symbol.hasInstance,CC=Symbol.toStringTag;class gn extends Error{static formatError(t,n){const r=n.label||n.path||"this";return r!==n.path&&(n=Object.assign({},n,{path:r})),typeof t=="string"?t.replace(IS,(o,s)=>co(n[s])):typeof t=="function"?t(n):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,n,r,o,s){const a=new EC(t,n,r,o);if(s)return a;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[CC]="Error",this.name=a.name,this.message=a.message,this.type=a.type,this.value=a.value,this.path=a.path,this.errors=a.errors,this.inner=a.inner,Error.captureStackTrace&&Error.captureStackTrace(this,gn)}static[hC](t){return EC[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let br={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:n,originalValue:r})=>{const o=r!=null&&r!==n?` (cast from the value \`${co(r,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${co(n,!0)}\``+o:`${e} must match the configured type. The validated value was: \`${co(n,!0)}\``+o}},fn={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},uo={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},td={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},mS={isValue:"${path} field must be ${value}"},nd={noUnknown:"${path} field has unspecified keys: ${unknown}"};Object.assign(Object.create(null),{mixed:br,string:fn,number:uo,date:td,object:nd,array:{min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},boolean:mS,tuple:{notType:e=>{const{path:t,value:n,spec:r}=e,o=r.types.length;if(Array.isArray(n)){if(n.length<o)return`${t} tuple value has too few items, expected a length of ${o} but got ${n.length} for value: \`${co(n,!0)}\``;if(n.length>o)return`${t} tuple value has too many items, expected a length of ${o} but got ${n.length} for value: \`${co(n,!0)}\``}return gn.formatError(br.notType,e)}}});const rd=e=>e&&e.__isYupSchema__;class Dl{static fromOptions(t,n){if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:r,then:o,otherwise:s}=n,a=typeof r=="function"?r:(...c)=>c.every(u=>u===r);return new Dl(t,(c,u)=>{var A;let p=a(...c)?o:s;return(A=p==null?void 0:p(u))!=null?A:u})}constructor(t,n){this.fn=void 0,this.refs=t,this.refs=t,this.fn=n}resolve(t,n){let r=this.refs.map(s=>s.getValue(n==null?void 0:n.value,n==null?void 0:n.parent,n==null?void 0:n.context)),o=this.fn(r,t,n);if(o===void 0||o===t)return t;if(!rd(o))throw new TypeError("conditions must return a schema object");return o.resolve(n)}}const Ml={context:"$",value:"."};class Xo{constructor(t,n={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof t!="string")throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),t==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===Ml.context,this.isValue=this.key[0]===Ml.value,this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?Ml.context:this.isValue?Ml.value:"";this.path=this.key.slice(r.length),this.getter=this.path&&Jo.getter(this.path,!0),this.map=n.map}getValue(t,n,r){let o=this.isContext?r:this.isValue?t:n;return this.getter&&(o=this.getter(o||{})),this.map&&(o=this.map(o)),o}cast(t,n){return this.getValue(t,n==null?void 0:n.parent,n==null?void 0:n.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}}Xo.prototype.__isYupRef=!0;const Fr=e=>e==null;function Ui(e){function t({value:n,path:r="",options:o,originalValue:s,schema:a},c,u){const{name:A,test:p,params:h,message:C,skipAbsent:E}=e;let{parent:m,context:B,abortEarly:v=a.spec.abortEarly,disableStackTrace:S=a.spec.disableStackTrace}=o;function M(G){return Xo.isRef(G)?G.getValue(n,m,B):G}function x(G={}){const se=Object.assign({value:n,originalValue:s,label:a.spec.label,path:G.path||r,spec:a.spec,disableStackTrace:G.disableStackTrace||S},h,G.params);for(const _ of Object.keys(se))se[_]=M(se[_]);const ae=new gn(gn.formatError(G.message||C,se),n,se.path,G.type||A,se.disableStackTrace);return ae.params=se,ae}const O=v?c:u;let P={path:r,parent:m,type:A,from:o.from,createError:x,resolve:M,options:o,originalValue:s,schema:a};const F=G=>{gn.isError(G)?O(G):G?u(null):O(x())},L=G=>{gn.isError(G)?O(G):c(G)};if(E&&Fr(n))return F(!0);let J;try{var ee;if(J=p.call(P,n,P),typeof((ee=J)==null?void 0:ee.then)=="function"){if(o.sync)throw new Error(`Validation test of type: "${P.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(J).then(F,L)}}catch(G){L(G);return}F(J)}return t.OPTIONS=e,t}function BS(e,t,n,r=n){let o,s,a;return t?(Jo.forEach(t,(c,u,A)=>{let p=u?c.slice(1,c.length-1):c;e=e.resolve({context:r,parent:o,value:n});let h=e.type==="tuple",C=A?parseInt(p,10):0;if(e.innerType||h){if(h&&!A)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${a}" must contain an index to the tuple element, e.g. "${a}[0]"`);if(n&&C>=n.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${c}, in the path: ${t}. because there is no value at that index. `);o=n,n=n&&n[C],e=h?e.spec.types[C]:e.innerType}if(!A){if(!e.fields||!e.fields[p])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${a} which is a type: "${e.type}")`);o=n,n=n&&n[p],e=e.fields[p]}s=p,a=u?"["+c+"]":"."+c}),{schema:e,parent:o,parentPath:s}):{parent:o,parentPath:t,schema:e}}class kl extends Set{describe(){const t=[];for(const n of this.values())t.push(Xo.isRef(n)?n.describe():n);return t}resolveAll(t){let n=[];for(const r of this.values())n.push(t(r));return n}clone(){return new kl(this.values())}merge(t,n){const r=this.clone();return t.forEach(o=>r.add(o)),n.forEach(o=>r.delete(o)),r}}function Yi(e,t=new Map){if(rd(e)||!e||typeof e!="object")return e;if(t.has(e))return t.get(e);let n;if(e instanceof Date)n=new Date(e.getTime()),t.set(e,n);else if(e instanceof RegExp)n=new RegExp(e),t.set(e,n);else if(Array.isArray(e)){n=new Array(e.length),t.set(e,n);for(let r=0;r<e.length;r++)n[r]=Yi(e[r],t)}else if(e instanceof Map){n=new Map,t.set(e,n);for(const[r,o]of e.entries())n.set(r,Yi(o,t))}else if(e instanceof Set){n=new Set,t.set(e,n);for(const r of e)n.add(Yi(r,t))}else if(e instanceof Object){n={},t.set(e,n);for(const[r,o]of Object.entries(e))n[r]=Yi(o,t)}else throw Error(`Unable to clone ${e}`);return n}class Yn{constructor(t){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new kl,this._blacklist=new kl,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(br.notType)}),this.type=t.type,this._typeCheck=t.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},t==null?void 0:t.spec),this.withMutation(n=>{n.nonNullable()})}get _type(){return this.type}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;const n=Object.create(Object.getPrototypeOf(this));return n.type=this.type,n._typeCheck=this._typeCheck,n._whitelist=this._whitelist.clone(),n._blacklist=this._blacklist.clone(),n.internalTests=Object.assign({},this.internalTests),n.exclusiveTests=Object.assign({},this.exclusiveTests),n.deps=[...this.deps],n.conditions=[...this.conditions],n.tests=[...this.tests],n.transforms=[...this.transforms],n.spec=Yi(Object.assign({},this.spec,t)),n}label(t){let n=this.clone();return n.spec.label=t,n}meta(...t){if(t.length===0)return this.spec.meta;let n=this.clone();return n.spec.meta=Object.assign(n.spec.meta||{},t[0]),n}withMutation(t){let n=this._mutate;this._mutate=!0;let r=t(this);return this._mutate=n,r}concat(t){if(!t||t===this)return this;if(t.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${t.type}`);let n=this,r=t.clone();const o=Object.assign({},n.spec,r.spec);return r.spec=o,r.internalTests=Object.assign({},n.internalTests,r.internalTests),r._whitelist=n._whitelist.merge(t._whitelist,t._blacklist),r._blacklist=n._blacklist.merge(t._blacklist,t._whitelist),r.tests=n.tests,r.exclusiveTests=n.exclusiveTests,r.withMutation(s=>{t.tests.forEach(a=>{s.test(a.OPTIONS)})}),r.transforms=[...n.transforms,...r.transforms],r}isType(t){return t==null?!!(this.spec.nullable&&t===null||this.spec.optional&&t===void 0):this._typeCheck(t)}resolve(t){let n=this;if(n.conditions.length){let r=n.conditions;n=n.clone(),n.conditions=[],n=r.reduce((o,s)=>s.resolve(o,t),n),n=n.resolve(t)}return n}resolveOptions(t){var n,r,o,s;return Object.assign({},t,{from:t.from||[],strict:(n=t.strict)!=null?n:this.spec.strict,abortEarly:(r=t.abortEarly)!=null?r:this.spec.abortEarly,recursive:(o=t.recursive)!=null?o:this.spec.recursive,disableStackTrace:(s=t.disableStackTrace)!=null?s:this.spec.disableStackTrace})}cast(t,n={}){let r=this.resolve(Object.assign({value:t},n)),o=n.assert==="ignore-optionality",s=r._cast(t,n);if(n.assert!==!1&&!r.isType(s)){if(o&&Fr(s))return s;let a=co(t),c=co(s);throw new TypeError(`The value of ${n.path||"field"} could not be cast to a value that satisfies the schema type: "${r.type}".
98
98
 
99
99
  attempted value: ${a}
100
- `+(c!==a?`result of cast: ${c}`:""))}return s}_cast(t,n){let r=t===void 0?t:this.transforms.reduce((o,s)=>s.call(this,o,t,this),t);return r===void 0&&(r=this.getDefault(n)),r}_validate(t,n={},r,o){let{path:s,originalValue:a=t,strict:c=this.spec.strict}=n,u=t;c||(u=this._cast(u,Object.assign({assert:!1},n)));let A=[];for(let p of Object.values(this.internalTests))p&&A.push(p);this.runTests({path:s,value:u,originalValue:a,options:n,tests:A},r,p=>{if(p.length)return o(p,u);this.runTests({path:s,value:u,originalValue:a,options:n,tests:this.tests},r,o)})}runTests(t,n,r){let o=!1,{tests:s,value:a,originalValue:c,path:u,options:A}=t,p=B=>{o||(o=!0,n(B,a))},h=B=>{o||(o=!0,r(B,a))},C=s.length,E=[];if(!C)return h([]);let m={value:a,originalValue:c,path:u,options:A,schema:this};for(let B=0;B<s.length;B++){const v=s[B];v(m,p,function(M){M&&(Array.isArray(M)?E.push(...M):E.push(M)),--C<=0&&h(E)})}}asNestedTest({key:t,index:n,parent:r,parentPath:o,originalParent:s,options:a}){const c=t??n;if(c==null)throw TypeError("Must include `key` or `index` for nested validations");const u=typeof c=="number";let A=r[c];const p=Object.assign({},a,{strict:!0,parent:r,value:A,originalValue:s[c],key:void 0,[u?"index":"key"]:c,path:u||c.includes(".")?`${o||""}[${u?c:`"${c}"`}]`:(o?`${o}.`:"")+t});return(h,C,E)=>this.resolve(p)._validate(A,p,C,E)}validate(t,n){var r;let o=this.resolve(Object.assign({},n,{value:t})),s=(r=n==null?void 0:n.disableStackTrace)!=null?r:o.spec.disableStackTrace;return new Promise((a,c)=>o._validate(t,n,(u,A)=>{gn.isError(u)&&(u.value=A),c(u)},(u,A)=>{u.length?c(new gn(u,A,void 0,void 0,s)):a(A)}))}validateSync(t,n){var r;let o=this.resolve(Object.assign({},n,{value:t})),s,a=(r=n==null?void 0:n.disableStackTrace)!=null?r:o.spec.disableStackTrace;return o._validate(t,Object.assign({},n,{sync:!0}),(c,u)=>{throw gn.isError(c)&&(c.value=u),c},(c,u)=>{if(c.length)throw new gn(c,t,void 0,void 0,a);s=u}),s}isValid(t,n){return this.validate(t,n).then(()=>!0,r=>{if(gn.isError(r))return!1;throw r})}isValidSync(t,n){try{return this.validateSync(t,n),!0}catch(r){if(gn.isError(r))return!1;throw r}}_getDefault(t){let n=this.spec.default;return n==null?n:typeof n=="function"?n.call(this,t):Yi(n)}getDefault(t){return this.resolve(t||{})._getDefault(t)}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){return this.clone({strict:t})}nullability(t,n){const r=this.clone({nullable:t});return r.internalTests.nullable=Ui({message:n,name:"nullable",test(o){return o===null?this.schema.spec.nullable:!0}}),r}optionality(t,n){const r=this.clone({optional:t});return r.internalTests.optionality=Ui({message:n,name:"optionality",test(o){return o===void 0?this.schema.spec.optional:!0}}),r}optional(){return this.optionality(!0)}defined(t=br.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=br.notNull){return this.nullability(!1,t)}required(t=br.required){return this.clone().withMutation(n=>n.nonNullable(t).defined(t))}notRequired(){return this.clone().withMutation(t=>t.nullable().optional())}transform(t){let n=this.clone();return n.transforms.push(t),n}test(...t){let n;if(t.length===1?typeof t[0]=="function"?n={test:t[0]}:n=t[0]:t.length===2?n={name:t[0],test:t[1]}:n={name:t[0],message:t[1],test:t[2]},n.message===void 0&&(n.message=br.default),typeof n.test!="function")throw new TypeError("`test` is a required parameters");let r=this.clone(),o=Ui(n),s=n.exclusive||n.name&&r.exclusiveTests[n.name]===!0;if(n.exclusive&&!n.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return n.name&&(r.exclusiveTests[n.name]=!!n.exclusive),r.tests=r.tests.filter(a=>!(a.OPTIONS.name===n.name&&(s||a.OPTIONS.test===o.OPTIONS.test))),r.tests.push(o),r}when(t,n){!Array.isArray(t)&&typeof t!="string"&&(n=t,t=".");let r=this.clone(),o=fC(t).map(s=>new Xo(s));return o.forEach(s=>{s.isSibling&&r.deps.push(s.key)}),r.conditions.push(typeof n=="function"?new Dl(o,n):Dl.fromOptions(o,n)),r}typeError(t){let n=this.clone();return n.internalTests.typeError=Ui({message:t,name:"typeError",skipAbsent:!0,test(r){return this.schema._typeCheck(r)?!0:this.createError({params:{type:this.schema.type}})}}),n}oneOf(t,n=br.oneOf){let r=this.clone();return t.forEach(o=>{r._whitelist.add(o),r._blacklist.delete(o)}),r.internalTests.whiteList=Ui({message:n,name:"oneOf",skipAbsent:!0,test(o){let s=this.schema._whitelist,a=s.resolveAll(this.resolve);return a.includes(o)?!0:this.createError({params:{values:Array.from(s).join(", "),resolved:a}})}}),r}notOneOf(t,n=br.notOneOf){let r=this.clone();return t.forEach(o=>{r._blacklist.add(o),r._whitelist.delete(o)}),r.internalTests.blacklist=Ui({message:n,name:"notOneOf",test(o){let s=this.schema._blacklist,a=s.resolveAll(this.resolve);return a.includes(o)?this.createError({params:{values:Array.from(s).join(", "),resolved:a}}):!0}}),r}strip(t=!0){let n=this.clone();return n.spec.strip=t,n}describe(t){const n=(t?this.resolve(t):this).clone(),{label:r,meta:o,optional:s,nullable:a}=n.spec;return{meta:o,label:r,optional:s,nullable:a,default:n.getDefault(t),type:n.type,oneOf:n._whitelist.describe(),notOneOf:n._blacklist.describe(),tests:n.tests.map(u=>({name:u.OPTIONS.name,params:u.OPTIONS.params})).filter((u,A,p)=>p.findIndex(h=>h.name===u.name)===A)}}}Yn.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])Yn.prototype[`${e}At`]=function(t,n,r={}){const{parent:o,parentPath:s,schema:a}=BS(this,t,n,r.context);return a[e](o&&o[s],Object.assign({},r,{parent:o,path:t}))};for(const e of["equals","is"])Yn.prototype[e]=Yn.prototype.oneOf;for(const e of["not","nope"])Yn.prototype[e]=Yn.prototype.notOneOf;const vS=()=>!0;function IC(e){return new mC(e)}class mC extends Yn{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:vS},t))}}IC.prototype=mC.prototype;const yS=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function bS(e){const t=od(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(t.z===void 0&&t.plusMinus===void 0)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let n=0;return t.z!=="Z"&&t.plusMinus!==void 0&&(n=t.hourOffset*60+t.minuteOffset,t.plusMinus==="+"&&(n=0-n)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+n,t.second,t.millisecond)}function od(e){var t,n;const r=yS.exec(e);return r?{year:Lr(r[1]),month:Lr(r[2],1)-1,day:Lr(r[3],1),hour:Lr(r[4]),minute:Lr(r[5]),second:Lr(r[6]),millisecond:r[7]?Lr(r[7].substring(0,3)):0,precision:(t=(n=r[7])==null?void 0:n.length)!=null?t:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:Lr(r[10]),minuteOffset:Lr(r[11])}:null}function Lr(e,t=0){return Number(e)||t}let QS=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,xS=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,wS=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,TS="^\\d{4}-\\d{2}-\\d{2}",SS="\\d{2}:\\d{2}:\\d{2}",PS="(([+-]\\d{2}(:?\\d{2})?)|Z)",OS=new RegExp(`${TS}T${SS}(\\.\\d+)?${PS}$`),jS=e=>Fr(e)||e===e.trim(),DS={}.toString();function Nr(){return new BC}class BC extends Yn{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,n,r)=>{if(!r.spec.coerce||r.isType(t)||Array.isArray(t))return t;const o=t!=null&&t.toString?t.toString():t;return o===DS?t:o})})}required(t){return super.required(t).withMutation(n=>n.test({message:t||br.required,name:"required",skipAbsent:!0,test:r=>!!r.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(n=>n.OPTIONS.name!=="required"),t))}length(t,n=fn.length){return this.test({message:n,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(r){return r.length===this.resolve(t)}})}min(t,n=fn.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(r){return r.length>=this.resolve(t)}})}max(t,n=fn.max){return this.test({name:"max",exclusive:!0,message:n,params:{max:t},skipAbsent:!0,test(r){return r.length<=this.resolve(t)}})}matches(t,n){let r=!1,o,s;return n&&(typeof n=="object"?{excludeEmptyString:r=!1,message:o,name:s}=n:o=n),this.test({name:s||"matches",message:o||fn.matches,params:{regex:t},skipAbsent:!0,test:a=>a===""&&r||a.search(t)!==-1})}email(t=fn.email){return this.matches(QS,{name:"email",message:t,excludeEmptyString:!0})}url(t=fn.url){return this.matches(xS,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=fn.uuid){return this.matches(wS,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let n="",r,o;return t&&(typeof t=="object"?{message:n="",allowOffset:r=!1,precision:o=void 0}=t:n=t),this.matches(OS,{name:"datetime",message:n||fn.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:n||fn.datetime_offset,params:{allowOffset:r},skipAbsent:!0,test:s=>{if(!s||r)return!0;const a=od(s);return a?!!a.z:!1}}).test({name:"datetime_precision",message:n||fn.datetime_precision,params:{precision:o},skipAbsent:!0,test:s=>{if(!s||o==null)return!0;const a=od(s);return a?a.precision===o:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=fn.trim){return this.transform(n=>n!=null?n.trim():n).test({message:t,name:"trim",test:jS})}lowercase(t=fn.lowercase){return this.transform(n=>Fr(n)?n:n.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Fr(n)||n===n.toLowerCase()})}uppercase(t=fn.uppercase){return this.transform(n=>Fr(n)?n:n.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Fr(n)||n===n.toUpperCase()})}}Nr.prototype=BC.prototype;let MS=e=>e!=+e;function vC(){return new yC}class yC extends Yn{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!MS(t)}}),this.withMutation(()=>{this.transform((t,n,r)=>{if(!r.spec.coerce)return t;let o=t;if(typeof o=="string"){if(o=o.replace(/\s/g,""),o==="")return NaN;o=+o}return r.isType(o)||o===null?o:parseFloat(o)})})}min(t,n=uo.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(r){return r>=this.resolve(t)}})}max(t,n=uo.max){return this.test({message:n,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(r){return r<=this.resolve(t)}})}lessThan(t,n=uo.lessThan){return this.test({message:n,name:"max",exclusive:!0,params:{less:t},skipAbsent:!0,test(r){return r<this.resolve(t)}})}moreThan(t,n=uo.moreThan){return this.test({message:n,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(r){return r>this.resolve(t)}})}positive(t=uo.positive){return this.moreThan(0,t)}negative(t=uo.negative){return this.lessThan(0,t)}integer(t=uo.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:n=>Number.isInteger(n)})}truncate(){return this.transform(t=>Fr(t)?t:t|0)}round(t){var n;let r=["ceil","floor","round","trunc"];if(t=((n=t)==null?void 0:n.toLowerCase())||"round",t==="trunc")return this.truncate();if(r.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+r.join(", "));return this.transform(o=>Fr(o)?o:Math[t](o))}}vC.prototype=yC.prototype;let kS=new Date(""),RS=e=>Object.prototype.toString.call(e)==="[object Date]";class Rl extends Yn{constructor(){super({type:"date",check(t){return RS(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,n,r)=>!r.spec.coerce||r.isType(t)||t===null?t:(t=bS(t),isNaN(t)?Rl.INVALID_DATE:new Date(t)))})}prepareParam(t,n){let r;if(Xo.isRef(t))r=t;else{let o=this.cast(t);if(!this._typeCheck(o))throw new TypeError(`\`${n}\` must be a Date or a value that can be \`cast()\` to a Date`);r=o}return r}min(t,n=td.min){let r=this.prepareParam(t,"min");return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(o){return o>=this.resolve(r)}})}max(t,n=td.max){let r=this.prepareParam(t,"max");return this.test({message:n,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(o){return o<=this.resolve(r)}})}}Rl.INVALID_DATE=kS,Rl.prototype;function FS(e,t=[]){let n=[],r=new Set,o=new Set(t.map(([a,c])=>`${a}-${c}`));function s(a,c){let u=Jo.split(a)[0];r.add(u),o.has(`${c}-${u}`)||n.push([c,u])}for(const a of Object.keys(e)){let c=e[a];r.add(a),Xo.isRef(c)&&c.isSibling?s(c.path,a):rd(c)&&"deps"in c&&c.deps.forEach(u=>s(u,a))}return dS.array(Array.from(r),n).reverse()}function bC(e,t){let n=1/0;return e.some((r,o)=>{var s;if((s=t.path)!=null&&s.includes(r))return n=o,!0}),n}function QC(e){return(t,n)=>bC(e,t)-bC(e,n)}const LS=(e,t,n)=>{if(typeof e!="string")return e;let r=e;try{r=JSON.parse(e)}catch{}return n.isType(r)?r:e};function Fl(e){if("fields"in e){const t={};for(const[n,r]of Object.entries(e.fields))t[n]=Fl(r);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=Fl(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(Fl)}):"optional"in e?e.optional():e}const NS=(e,t)=>{const n=[...Jo.normalizePath(t)];if(n.length===1)return n[0]in e;let r=n.pop(),o=Jo.getter(Jo.join(n),!0)(e);return!!(o&&r in o)};let xC=e=>Object.prototype.toString.call(e)==="[object Object]";function VS(e,t){let n=Object.keys(e.fields);return Object.keys(t).filter(r=>n.indexOf(r)===-1)}const HS=QC([]);function id(e){return new wC(e)}class wC extends Yn{constructor(t){super({type:"object",check(n){return xC(n)||typeof n=="function"}}),this.fields=Object.create(null),this._sortErrors=HS,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,n={}){var r;let o=super._cast(t,n);if(o===void 0)return this.getDefault(n);if(!this._typeCheck(o))return o;let s=this.fields,a=(r=n.stripUnknown)!=null?r:this.spec.noUnknown,c=[].concat(this._nodes,Object.keys(o).filter(h=>!this._nodes.includes(h))),u={},A=Object.assign({},n,{parent:u,__validating:n.__validating||!1}),p=!1;for(const h of c){let C=s[h],E=h in o;if(C){let m,B=o[h];A.path=(n.path?`${n.path}.`:"")+h,C=C.resolve({value:B,context:n.context,parent:u});let v=C instanceof Yn?C.spec:void 0,S=v==null?void 0:v.strict;if(v!=null&&v.strip){p=p||h in o;continue}m=!n.__validating||!S?C.cast(o[h],A):o[h],m!==void 0&&(u[h]=m)}else E&&!a&&(u[h]=o[h]);(E!==h in u||u[h]!==o[h])&&(p=!0)}return p?u:o}_validate(t,n={},r,o){let{from:s=[],originalValue:a=t,recursive:c=this.spec.recursive}=n;n.from=[{schema:this,value:a},...s],n.__validating=!0,n.originalValue=a,super._validate(t,n,r,(u,A)=>{if(!c||!xC(A)){o(u,A);return}a=a||A;let p=[];for(let h of this._nodes){let C=this.fields[h];!C||Xo.isRef(C)||p.push(C.asNestedTest({options:n,key:h,parent:A,parentPath:n.path,originalParent:a}))}this.runTests({tests:p,value:A,originalValue:a,options:n},r,h=>{o(h.sort(this._sortErrors).concat(u),A)})})}clone(t){const n=super.clone(t);return n.fields=Object.assign({},this.fields),n._nodes=this._nodes,n._excludedEdges=this._excludedEdges,n._sortErrors=this._sortErrors,n}concat(t){let n=super.concat(t),r=n.fields;for(let[o,s]of Object.entries(this.fields)){const a=r[o];r[o]=a===void 0?s:a}return n.withMutation(o=>o.setFields(r,[...this._excludedEdges,...t._excludedEdges]))}_getDefault(t){if("default"in this.spec)return super._getDefault(t);if(!this._nodes.length)return;let n={};return this._nodes.forEach(r=>{var o;const s=this.fields[r];let a=t;(o=a)!=null&&o.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[r]})),n[r]=s&&"getDefault"in s?s.getDefault(a):void 0}),n}setFields(t,n){let r=this.clone();return r.fields=t,r._nodes=FS(t,n),r._sortErrors=QC(Object.keys(t)),n&&(r._excludedEdges=n),r}shape(t,n=[]){return this.clone().withMutation(r=>{let o=r._excludedEdges;return n.length&&(Array.isArray(n[0])||(n=[n]),o=[...r._excludedEdges,...n]),r.setFields(Object.assign(r.fields,t),o)})}partial(){const t={};for(const[n,r]of Object.entries(this.fields))t[n]="optional"in r&&r.optional instanceof Function?r.optional():r;return this.setFields(t)}deepPartial(){return Fl(this)}pick(t){const n={};for(const r of t)this.fields[r]&&(n[r]=this.fields[r]);return this.setFields(n,this._excludedEdges.filter(([r,o])=>t.includes(r)&&t.includes(o)))}omit(t){const n=[];for(const r of Object.keys(this.fields))t.includes(r)||n.push(r);return this.pick(n)}from(t,n,r){let o=Jo.getter(t,!0);return this.transform(s=>{if(!s)return s;let a=s;return NS(s,t)&&(a=Object.assign({},s),r||delete a[t],a[n]=o(s)),a})}json(){return this.transform(LS)}noUnknown(t=!0,n=nd.noUnknown){typeof t!="boolean"&&(n=t,t=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:n,test(o){if(o==null)return!0;const s=VS(this.schema,o);return!t||s.length===0||this.createError({params:{unknown:s.join(", ")}})}});return r.spec.noUnknown=t,r}unknown(t=!0,n=nd.noUnknown){return this.noUnknown(!t,n)}transformKeys(t){return this.transform(n=>{if(!n)return n;const r={};for(const o of Object.keys(n))r[t(o)]=n[o];return r})}camelCase(){return this.transformKeys($A.camelCase)}snakeCase(){return this.transformKeys($A.snakeCase)}constantCase(){return this.transformKeys(t=>$A.snakeCase(t).toUpperCase())}describe(t){const n=(t?this.resolve(t):this).clone(),r=super.describe(t);r.fields={};for(const[s,a]of Object.entries(n.fields)){var o;let c=t;(o=c)!=null&&o.value&&(c=Object.assign({},c,{parent:c.value,value:c.value[s]})),r.fields[s]=a.describe(c)}return r}}id.prototype=wC.prototype;const TC=IC().test("function","Invalid function",e=>ne.isFunction(e));class SC{constructor(){io(this,pi);io(this,Po,[])}get(t){if(Nr().required().validateSync(t),il(this,pi,sl).call(this)){const n=localStorage.getItem(t);return ne.isNil(n)?null:JSON.parse(n)}else return null}set(t,n){return Nr().required().validateSync(t),il(this,pi,sl).call(this)?(localStorage.setItem(t,JSON.stringify(n)),n):null}watch(t,n){Nr().required().validateSync(t),TC.validateSync(n),il(this,pi,sl).call(this)&&(xn(this,Po).push({key:t,callback:n}),window.addEventListener("storage",r=>{r.storageArea===localStorage&&r.key===t&&n(this.get(t))}))}unwatch(t,n){Nr().required().validateSync(t),TC.optional().default(ne.identity).validateSync(n),il(this,pi,sl).call(this)&&(n!==void 0?Vo(this,Po,ne.reject(xn(this,Po),r=>r.key===t&&r.callback===n)):Vo(this,Po,ne.reject(xn(this,Po),r=>r.key===t)))}}Po=new WeakMap,pi=new WeakSet,sl=function(){return typeof window<"u"};function PC(e){const[t]=ue.useLocaleState();return e!==void 0?String(e):t}function zS(e,t){const n=PC(t==null?void 0:t.locale);return KA(e,n,t)}function WS(e){const t=PC(e==null?void 0:e.locale);return Q.useCallback(r=>KA(r,t,e),[t,e])}const Js=new SC;function US(e,t,n){return function(r){const o=ne.isFunction(r)?r(t):r;return Js.set(e,o),n(o),o}}function Ll(e,t){var u;Nr().required().validateSync(e);const[n,r]=Q.useState(Js.get(e)??t),o=Q.useRef(t),s=ne.isEqual(o.current,t)?o.current:t,a=Q.useRef(),c=a.current;return Q.useEffect(()=>{r(Js.get(e)??s)},[e,s,r]),Q.useEffect(()=>{function A(p){r(p)}return Js.watch(e,A),()=>{Js.unwatch(e,A)}},[e,r]),(e!==(c==null?void 0:c.key)||!ne.isEqual(n,c==null?void 0:c.value))&&(a.current={key:e,value:n,setter:US(e,n,r)}),[n,((u=a.current)==null?void 0:u.setter)??ne.noop]}function OC(e){if(!ne.isPlainObject(e))throw new Error("[useMemoizedObject]: param must be a plain JS object");const[t,n]=Q.useState(e);return Q.useEffect(()=>{ne.isEqual(e,t)||n(e)},[e,t]),t}function Nl(){const[e,t]=Q.useState(null),n=!!e,r=Q.useCallback(a=>t((a==null?void 0:a.currentTarget)??null),[t]),o=Q.useCallback(()=>t(null),[t]),s=Q.useCallback(a=>{n?o():r(a)},[n,r,o]);return{anchorEl:e,open:n,handleClick:r,handleClose:o,handleToggle:s}}function YS(e,t){const[n,r]=Q.useState({width:1,height:1}),o=e.current;return Q.useEffect(()=>{function s(){var A;let c=0,u=0;switch(t){case"client":c=(o==null?void 0:o.clientWidth)??0,u=(o==null?void 0:o.clientHeight)??0;break;case"offset":c=(o==null?void 0:o.offsetWidth)??0,u=(o==null?void 0:o.offsetHeight)??0;break;case"scroll":c=(o==null?void 0:o.scrollWidth)??0,u=(o==null?void 0:o.scrollHeight)??0;break;case"bounding":default:{const p=((A=e.current)==null?void 0:A.getBoundingClientRect())??{width:0,height:0};c=p.width,u=p.height;break}}r({width:c,height:u})}const a=new ResizeObserver(s);return ne.isEmpty(e==null?void 0:e.current)||(a.observe(e==null?void 0:e.current),s()),()=>{a.disconnect()}},[o,t]),n}const sd=e=>{const t=D.useRecordContext(),n=D.useTranslate(),r=D.useResourceContext(),o=t!=null&&t.id?"edit":"create";return Q.useMemo(()=>{if(e===!1)return;const a=`resources.${r}.title`;return e||n(`resources.${r}.title.${o}`,{_:n(a,{_:a}),...t})},[o,t,r,n,e])};function dr(e,t,n){const r=ne.chain((e==null?void 0:e.sx)??{}).cloneDeepWith(a=>ne.isFunction(a)?a:void 0).value();n!=null&&n.defaults?ne.defaultsDeep(r,t):ne.merge(r,t);const[o,s]=Q.useState(r);return Q.useEffect(()=>{ne.isEqual(o,r)||s(r)},[o,r]),o}const jC=()=>Q.useContext(zA),GS=()=>Q.useContext(WA),pn=()=>Q.useContext(VA),DC=Ae(UT,{shouldForwardProp:e=>e!=="open"})(({theme:e,open:t})=>{const{drawerWidth:n}=pn();return{zIndex:e.zIndex.drawer+1,transition:e.transitions.create(["width","margin"],{easing:e.transitions.easing.sharp,duration:e.transitions.duration.leavingScreen}),...!t&&{width:`calc(100% - ${e.spacing(7.5)})`},...t&&{marginLeft:n,width:`calc(100% - ${n}px)`,transition:e.transitions.create(["width","margin"],{easing:e.transitions.easing.sharp,duration:e.transitions.duration.enteringScreen})}}}),KS=Q.forwardRef(function(t,n){const r=dr(t,{color:"text.primary"},{defaults:!0});return g.jsx(b.Button,{ref:n,...t,color:"secondary",variant:"text",sx:r})}),MC=Q.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),Vl=Q.createContext({}),ad=Q.createContext(null),Hl=typeof document<"u",JS=Hl?Q.useLayoutEffect:Q.useEffect,kC=Q.createContext({strict:!1}),ld=e=>e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),RC="data-"+ld("framerAppearId");function XS(e,t,n,r){const{visualElement:o}=Q.useContext(Vl),s=Q.useContext(kC),a=Q.useContext(ad),c=Q.useContext(MC).reducedMotion,u=Q.useRef();r=r||s.renderer,!u.current&&r&&(u.current=r(e,{visualState:t,parent:o,props:n,presenceContext:a,blockInitialAnimation:a?a.initial===!1:!1,reducedMotionConfig:c}));const A=u.current;Q.useInsertionEffect(()=>{A&&A.update(n,a)});const p=Q.useRef(!!(n[RC]&&!window.HandoffComplete));return JS(()=>{A&&(A.render(),p.current&&A.animationState&&A.animationState.animateChanges())}),Q.useEffect(()=>{A&&(A.updateFeatures(),!p.current&&A.animationState&&A.animationState.animateChanges(),p.current&&(p.current=!1,window.HandoffComplete=!0))}),A}function Gi(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function ZS(e,t,n){return Q.useCallback(r=>{r&&e.mount&&e.mount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):Gi(n)&&(n.current=r))},[t])}function Xs(e){return typeof e=="string"||Array.isArray(e)}function zl(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}const cd=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],ud=["initial",...cd];function Wl(e){return zl(e.animate)||ud.some(t=>Xs(e[t]))}function FC(e){return!!(Wl(e)||e.variants)}function _S(e,t){if(Wl(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Xs(n)?n:void 0,animate:Xs(r)?r:void 0}}return e.inherit!==!1?t:{}}function qS(e){const{initial:t,animate:n}=_S(e,Q.useContext(Vl));return Q.useMemo(()=>({initial:t,animate:n}),[LC(t),LC(n)])}function LC(e){return Array.isArray(e)?e.join(" "):e}const NC={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Zs={};for(const e in NC)Zs[e]={isEnabled:t=>NC[e].some(n=>!!t[n])};function $S(e){for(const t in e)Zs[t]={...Zs[t],...e[t]}}const VC=Q.createContext({}),HC=Q.createContext({}),eP=Symbol.for("motionComponentSymbol");function tP({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:o}){e&&$S(e);function s(c,u){let A;const p={...Q.useContext(MC),...c,layoutId:nP(c)},{isStatic:h}=p,C=qS(c),E=r(c,h);if(!h&&Hl){C.visualElement=XS(o,E,p,t);const m=Q.useContext(HC),B=Q.useContext(kC).strict;C.visualElement&&(A=C.visualElement.loadFeatures(p,B,e,m))}return R.createElement(Vl.Provider,{value:C},A&&C.visualElement?R.createElement(A,{visualElement:C.visualElement,...p}):null,n(o,c,ZS(E,C.visualElement,u),E,h,C.visualElement))}const a=Q.forwardRef(s);return a[eP]=o,a}function nP({layoutId:e}){const t=Q.useContext(VC).id;return t&&e!==void 0?t+"-"+e:e}function rP(e){function t(r,o={}){return tP(e(r,o))}if(typeof Proxy>"u")return t;const n=new Map;return new Proxy(t,{get:(r,o)=>(n.has(o)||n.set(o,t(o)),n.get(o))})}const oP=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Ad(e){return typeof e!="string"||e.includes("-")?!1:!!(oP.indexOf(e)>-1||/[A-Z]/.test(e))}const Ul={};function iP(e){Object.assign(Ul,e)}const _s=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Zo=new Set(_s);function zC(e,{layout:t,layoutId:n}){return Zo.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Ul[e]||e==="opacity")}const hn=e=>!!(e&&e.getVelocity),sP={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},aP=_s.length;function lP(e,{enableHardwareAcceleration:t=!0,allowTransformNone:n=!0},r,o){let s="";for(let a=0;a<aP;a++){const c=_s[a];if(e[c]!==void 0){const u=sP[c]||c;s+=`${u}(${e[c]}) `}}return t&&!e.z&&(s+="translateZ(0)"),s=s.trim(),o?s=o(e,r?"":s):n&&r&&(s="none"),s}const WC=e=>t=>typeof t=="string"&&t.startsWith(e),UC=WC("--"),dd=WC("var(--"),cP=/var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g,uP=(e,t)=>t&&typeof e=="number"?t.transform(e):e,Ao=(e,t,n)=>Math.min(Math.max(n,e),t),_o={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},qs={..._o,transform:e=>Ao(0,1,e)},Yl={..._o,default:1},$s=e=>Math.round(e*1e5)/1e5,Gl=/(-)?([\d]*\.?[\d])+/g,YC=/(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi,AP=/^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;function ea(e){return typeof e=="string"}const ta=e=>({test:t=>ea(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),go=ta("deg"),Qr=ta("%"),ke=ta("px"),dP=ta("vh"),gP=ta("vw"),GC={...Qr,parse:e=>Qr.parse(e)/100,transform:e=>Qr.transform(e*100)},KC={..._o,transform:Math.round},JC={borderWidth:ke,borderTopWidth:ke,borderRightWidth:ke,borderBottomWidth:ke,borderLeftWidth:ke,borderRadius:ke,radius:ke,borderTopLeftRadius:ke,borderTopRightRadius:ke,borderBottomRightRadius:ke,borderBottomLeftRadius:ke,width:ke,maxWidth:ke,height:ke,maxHeight:ke,size:ke,top:ke,right:ke,bottom:ke,left:ke,padding:ke,paddingTop:ke,paddingRight:ke,paddingBottom:ke,paddingLeft:ke,margin:ke,marginTop:ke,marginRight:ke,marginBottom:ke,marginLeft:ke,rotate:go,rotateX:go,rotateY:go,rotateZ:go,scale:Yl,scaleX:Yl,scaleY:Yl,scaleZ:Yl,skew:go,skewX:go,skewY:go,distance:ke,translateX:ke,translateY:ke,translateZ:ke,x:ke,y:ke,z:ke,perspective:ke,transformPerspective:ke,opacity:qs,originX:GC,originY:GC,originZ:ke,zIndex:KC,fillOpacity:qs,strokeOpacity:qs,numOctaves:KC};function gd(e,t,n,r){const{style:o,vars:s,transform:a,transformOrigin:c}=e;let u=!1,A=!1,p=!0;for(const h in t){const C=t[h];if(UC(h)){s[h]=C;continue}const E=JC[h],m=uP(C,E);if(Zo.has(h)){if(u=!0,a[h]=m,!p)continue;C!==(E.default||0)&&(p=!1)}else h.startsWith("origin")?(A=!0,c[h]=m):o[h]=m}if(t.transform||(u||r?o.transform=lP(e.transform,n,p,r):o.transform&&(o.transform="none")),A){const{originX:h="50%",originY:C="50%",originZ:E=0}=c;o.transformOrigin=`${h} ${C} ${E}`}}const fd=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function XC(e,t,n){for(const r in t)!hn(t[r])&&!zC(r,n)&&(e[r]=t[r])}function fP({transformTemplate:e},t,n){return Q.useMemo(()=>{const r=fd();return gd(r,t,{enableHardwareAcceleration:!n},e),Object.assign({},r.vars,r.style)},[t])}function pP(e,t,n){const r=e.style||{},o={};return XC(o,r,e),Object.assign(o,fP(e,t,n)),e.transformValues?e.transformValues(o):o}function hP(e,t,n){const r={},o=pP(e,t,n);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=o,r}const CP=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","transformValues","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Kl(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||CP.has(e)}let ZC=e=>!Kl(e);function EP(e){e&&(ZC=t=>t.startsWith("on")?!Kl(t):e(t))}try{EP(require("@emotion/is-prop-valid").default)}catch{}function IP(e,t,n){const r={};for(const o in e)o==="values"&&typeof e.values=="object"||(ZC(o)||n===!0&&Kl(o)||!t&&!Kl(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}function _C(e,t,n){return typeof e=="string"?e:ke.transform(t+n*e)}function mP(e,t,n){const r=_C(t,e.x,e.width),o=_C(n,e.y,e.height);return`${r} ${o}`}const BP={offset:"stroke-dashoffset",array:"stroke-dasharray"},vP={offset:"strokeDashoffset",array:"strokeDasharray"};function yP(e,t,n=1,r=0,o=!0){e.pathLength=1;const s=o?BP:vP;e[s.offset]=ke.transform(-r);const a=ke.transform(t),c=ke.transform(n);e[s.array]=`${a} ${c}`}function pd(e,{attrX:t,attrY:n,attrScale:r,originX:o,originY:s,pathLength:a,pathSpacing:c=1,pathOffset:u=0,...A},p,h,C){if(gd(e,A,p,C),h){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:E,style:m,dimensions:B}=e;E.transform&&(B&&(m.transform=E.transform),delete E.transform),B&&(o!==void 0||s!==void 0||m.transform)&&(m.transformOrigin=mP(B,o!==void 0?o:.5,s!==void 0?s:.5)),t!==void 0&&(E.x=t),n!==void 0&&(E.y=n),r!==void 0&&(E.scale=r),a!==void 0&&yP(E,a,c,u,!1)}const qC=()=>({...fd(),attrs:{}}),hd=e=>typeof e=="string"&&e.toLowerCase()==="svg";function bP(e,t,n,r){const o=Q.useMemo(()=>{const s=qC();return pd(s,t,{enableHardwareAcceleration:!1},hd(r),e.transformTemplate),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};XC(s,e.style,e),o.style={...s,...o.style}}return o}function QP(e=!1){return(n,r,o,{latestValues:s},a)=>{const u=(Ad(n)?bP:hP)(r,s,a,n),p={...IP(r,typeof n=="string",e),...u,ref:o},{children:h}=r,C=Q.useMemo(()=>hn(h)?h.get():h,[h]);return Q.createElement(n,{...p,children:C})}}function $C(e,{style:t,vars:n},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(const s in n)e.style.setProperty(s,n[s])}const eE=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function tE(e,t,n,r){$C(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(eE.has(o)?o:ld(o),t.attrs[o])}function Cd(e,t){const{style:n}=e,r={};for(const o in n)(hn(n[o])||t.style&&hn(t.style[o])||zC(o,e))&&(r[o]=n[o]);return r}function nE(e,t){const n=Cd(e,t);for(const r in e)if(hn(e[r])||hn(t[r])){const o=_s.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;n[o]=e[r]}return n}function Ed(e,t,n,r={},o={}){return typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,o)),typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,o)),t}function xP(e){const t=Q.useRef(null);return t.current===null&&(t.current=e()),t.current}const Jl=e=>Array.isArray(e),wP=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),TP=e=>Jl(e)?e[e.length-1]||0:e;function Xl(e){const t=hn(e)?e.get():e;return wP(t)?t.toValue():t}function SP({scrapeMotionValuesFromProps:e,createRenderState:t,onMount:n},r,o,s){const a={latestValues:PP(r,o,s,e),renderState:t()};return n&&(a.mount=c=>n(r,c,a)),a}const rE=e=>(t,n)=>{const r=Q.useContext(Vl),o=Q.useContext(ad),s=()=>SP(e,t,r,o);return n?s():xP(s)};function PP(e,t,n,r){const o={},s=r(e,{});for(const C in s)o[C]=Xl(s[C]);let{initial:a,animate:c}=e;const u=Wl(e),A=FC(e);t&&A&&!u&&e.inherit!==!1&&(a===void 0&&(a=t.initial),c===void 0&&(c=t.animate));let p=n?n.initial===!1:!1;p=p||a===!1;const h=p?c:a;return h&&typeof h!="boolean"&&!zl(h)&&(Array.isArray(h)?h:[h]).forEach(E=>{const m=Ed(e,E);if(!m)return;const{transitionEnd:B,transition:v,...S}=m;for(const M in S){let x=S[M];if(Array.isArray(x)){const O=p?x.length-1:0;x=x[O]}x!==null&&(o[M]=x)}for(const M in B)o[M]=B[M]}),o}const Pt=e=>e;class oE{constructor(){this.order=[],this.scheduled=new Set}add(t){if(!this.scheduled.has(t))return this.scheduled.add(t),this.order.push(t),!0}remove(t){const n=this.order.indexOf(t);n!==-1&&(this.order.splice(n,1),this.scheduled.delete(t))}clear(){this.order.length=0,this.scheduled.clear()}}function OP(e){let t=new oE,n=new oE,r=0,o=!1,s=!1;const a=new WeakSet,c={schedule:(u,A=!1,p=!1)=>{const h=p&&o,C=h?t:n;return A&&a.add(u),C.add(u)&&h&&o&&(r=t.order.length),u},cancel:u=>{n.remove(u),a.delete(u)},process:u=>{if(o){s=!0;return}if(o=!0,[t,n]=[n,t],n.clear(),r=t.order.length,r)for(let A=0;A<r;A++){const p=t.order[A];p(u),a.has(p)&&(c.schedule(p),e())}o=!1,s&&(s=!1,c.process(u))}};return c}const Zl=["prepare","read","update","preRender","render","postRender"],jP=40;function DP(e,t){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},s=Zl.reduce((h,C)=>(h[C]=OP(()=>n=!0),h),{}),a=h=>s[h].process(o),c=()=>{const h=performance.now();n=!1,o.delta=r?1e3/60:Math.max(Math.min(h-o.timestamp,jP),1),o.timestamp=h,o.isProcessing=!0,Zl.forEach(a),o.isProcessing=!1,n&&t&&(r=!1,e(c))},u=()=>{n=!0,r=!0,o.isProcessing||e(c)};return{schedule:Zl.reduce((h,C)=>{const E=s[C];return h[C]=(m,B=!1,v=!1)=>(n||u(),E.schedule(m,B,v)),h},{}),cancel:h=>Zl.forEach(C=>s[C].cancel(h)),state:o,steps:s}}const{schedule:ht,cancel:Vr,state:$t,steps:Id}=DP(typeof requestAnimationFrame<"u"?requestAnimationFrame:Pt,!0),MP={useVisualState:rE({scrapeMotionValuesFromProps:nE,createRenderState:qC,onMount:(e,t,{renderState:n,latestValues:r})=>{ht.read(()=>{try{n.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),ht.render(()=>{pd(n,r,{enableHardwareAcceleration:!1},hd(t.tagName),e.transformTemplate),tE(t,n)})}})},kP={useVisualState:rE({scrapeMotionValuesFromProps:Cd,createRenderState:fd})};function RP(e,{forwardMotionProps:t=!1},n,r){return{...Ad(e)?MP:kP,preloadedFeatures:n,useRender:QP(t),createVisualElement:r,Component:e}}function Hr(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const iE=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function _l(e,t="page"){return{point:{x:e[t+"X"],y:e[t+"Y"]}}}const FP=e=>t=>iE(t)&&e(t,_l(t));function zr(e,t,n,r){return Hr(e,t,FP(n),r)}const LP=(e,t)=>n=>t(e(n)),fo=(...e)=>e.reduce(LP);function sE(e){let t=null;return()=>{const n=()=>{t=null};return t===null?(t=e,n):!1}}const aE=sE("dragHorizontal"),lE=sE("dragVertical");function cE(e){let t=!1;if(e==="y")t=lE();else if(e==="x")t=aE();else{const n=aE(),r=lE();n&&r?t=()=>{n(),r()}:(n&&n(),r&&r())}return t}function uE(){const e=cE(!0);return e?(e(),!1):!0}class po{constructor(t){this.isMounted=!1,this.node=t}update(){}}function AE(e,t){const n="pointer"+(t?"enter":"leave"),r="onHover"+(t?"Start":"End"),o=(s,a)=>{if(s.pointerType==="touch"||uE())return;const c=e.getProps();e.animationState&&c.whileHover&&e.animationState.setActive("whileHover",t),c[r]&&ht.update(()=>c[r](s,a))};return zr(e.current,n,o,{passive:!e.getProps()[r]})}class NP extends po{mount(){this.unmount=fo(AE(this.node,!0),AE(this.node,!1))}unmount(){}}class VP extends po{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=fo(Hr(this.node.current,"focus",()=>this.onFocus()),Hr(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const dE=(e,t)=>t?e===t?!0:dE(e,t.parentElement):!1;function md(e,t){if(!t)return;const n=new PointerEvent("pointer"+e);t(n,_l(n))}class HP extends po{constructor(){super(...arguments),this.removeStartListeners=Pt,this.removeEndListeners=Pt,this.removeAccessibleListeners=Pt,this.startPointerPress=(t,n)=>{if(this.isPressing)return;this.removeEndListeners();const r=this.node.getProps(),s=zr(window,"pointerup",(c,u)=>{if(!this.checkPressEnd())return;const{onTap:A,onTapCancel:p,globalTapTarget:h}=this.node.getProps();ht.update(()=>{!h&&!dE(this.node.current,c.target)?p&&p(c,u):A&&A(c,u)})},{passive:!(r.onTap||r.onPointerUp)}),a=zr(window,"pointercancel",(c,u)=>this.cancelPress(c,u),{passive:!(r.onTapCancel||r.onPointerCancel)});this.removeEndListeners=fo(s,a),this.startPress(t,n)},this.startAccessiblePress=()=>{const t=s=>{if(s.key!=="Enter"||this.isPressing)return;const a=c=>{c.key!=="Enter"||!this.checkPressEnd()||md("up",(u,A)=>{const{onTap:p}=this.node.getProps();p&&ht.update(()=>p(u,A))})};this.removeEndListeners(),this.removeEndListeners=Hr(this.node.current,"keyup",a),md("down",(c,u)=>{this.startPress(c,u)})},n=Hr(this.node.current,"keydown",t),r=()=>{this.isPressing&&md("cancel",(s,a)=>this.cancelPress(s,a))},o=Hr(this.node.current,"blur",r);this.removeAccessibleListeners=fo(n,o)}}startPress(t,n){this.isPressing=!0;const{onTapStart:r,whileTap:o}=this.node.getProps();o&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),r&&ht.update(()=>r(t,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!uE()}cancelPress(t,n){if(!this.checkPressEnd())return;const{onTapCancel:r}=this.node.getProps();r&&ht.update(()=>r(t,n))}mount(){const t=this.node.getProps(),n=zr(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),r=Hr(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=fo(n,r)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const Bd=new WeakMap,vd=new WeakMap,zP=e=>{const t=Bd.get(e.target);t&&t(e)},WP=e=>{e.forEach(zP)};function UP({root:e,...t}){const n=e||document;vd.has(n)||vd.set(n,{});const r=vd.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(WP,{root:e,...t})),r[o]}function YP(e,t,n){const r=UP(t);return Bd.set(e,n),r.observe(e),()=>{Bd.delete(e),r.unobserve(e)}}const GP={some:0,all:1};class KP extends po{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:o="some",once:s}=t,a={root:n?n.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:GP[o]},c=u=>{const{isIntersecting:A}=u;if(this.isInView===A||(this.isInView=A,s&&!A&&this.hasEnteredView))return;A&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",A);const{onViewportEnter:p,onViewportLeave:h}=this.node.getProps(),C=A?p:h;C&&C(u)};return YP(this.node.current,a,c)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(JP(t,n))&&this.startObserver()}unmount(){}}function JP({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const XP={inView:{Feature:KP},tap:{Feature:HP},focus:{Feature:VP},hover:{Feature:NP}};function gE(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}function ZP(e){const t={};return e.values.forEach((n,r)=>t[r]=n.get()),t}function _P(e){const t={};return e.values.forEach((n,r)=>t[r]=n.getVelocity()),t}function ql(e,t,n){const r=e.getProps();return Ed(r,t,n!==void 0?n:r.custom,ZP(e),_P(e))}let na=Pt,gr=Pt;process.env.NODE_ENV!=="production"&&(na=(e,t)=>{!e&&typeof console<"u"&&console.warn(t)},gr=(e,t)=>{if(!e)throw new Error(t)});const ho=e=>e*1e3,Wr=e=>e/1e3,qP={current:!1},fE=e=>Array.isArray(e)&&typeof e[0]=="number";function pE(e){return!!(!e||typeof e=="string"&&hE[e]||fE(e)||Array.isArray(e)&&e.every(pE))}const ra=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,hE={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:ra([0,.65,.55,1]),circOut:ra([.55,0,1,.45]),backIn:ra([.31,.01,.66,-.59]),backOut:ra([.33,1.53,.69,.99])};function CE(e){if(e)return fE(e)?ra(e):Array.isArray(e)?e.map(CE):hE[e]}function $P(e,t,n,{delay:r=0,duration:o,repeat:s=0,repeatType:a="loop",ease:c,times:u}={}){const A={[t]:n};u&&(A.offset=u);const p=CE(c);return Array.isArray(p)&&(A.easing=p),e.animate(A,{delay:r,duration:o,easing:Array.isArray(p)?"linear":p,fill:"both",iterations:s+1,direction:a==="reverse"?"alternate":"normal"})}function eO(e,{repeat:t,repeatType:n="loop"}){const r=t&&n!=="loop"&&t%2===1?0:e.length-1;return e[r]}const EE=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,tO=1e-7,nO=12;function rO(e,t,n,r,o){let s,a,c=0;do a=t+(n-t)/2,s=EE(a,r,o)-e,s>0?n=a:t=a;while(Math.abs(s)>tO&&++c<nO);return a}function oa(e,t,n,r){if(e===t&&n===r)return Pt;const o=s=>rO(s,0,1,e,n);return s=>s===0||s===1?s:EE(o(s),t,r)}const oO=oa(.42,0,1,1),iO=oa(0,0,.58,1),IE=oa(.42,0,.58,1),sO=e=>Array.isArray(e)&&typeof e[0]!="number",mE=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,BE=e=>t=>1-e(1-t),yd=e=>1-Math.sin(Math.acos(e)),vE=BE(yd),aO=mE(yd),yE=oa(.33,1.53,.69,.99),bd=BE(yE),lO=mE(bd),bE={linear:Pt,easeIn:oO,easeInOut:IE,easeOut:iO,circIn:yd,circInOut:aO,circOut:vE,backIn:bd,backInOut:lO,backOut:yE,anticipate:e=>(e*=2)<1?.5*bd(e):.5*(2-Math.pow(2,-10*(e-1)))},QE=e=>{if(Array.isArray(e)){gr(e.length===4,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,o]=e;return oa(t,n,r,o)}else if(typeof e=="string")return gr(bE[e]!==void 0,`Invalid easing type '${e}'`),bE[e];return e},Qd=(e,t)=>n=>!!(ea(n)&&AP.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)),xE=(e,t,n)=>r=>{if(!ea(r))return r;const[o,s,a,c]=r.match(Gl);return{[e]:parseFloat(o),[t]:parseFloat(s),[n]:parseFloat(a),alpha:c!==void 0?parseFloat(c):1}},cO=e=>Ao(0,255,e),xd={..._o,transform:e=>Math.round(cO(e))},qo={test:Qd("rgb","red"),parse:xE("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+xd.transform(e)+", "+xd.transform(t)+", "+xd.transform(n)+", "+$s(qs.transform(r))+")"};function uO(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}const wd={test:Qd("#"),parse:uO,transform:qo.transform},Ki={test:Qd("hsl","hue"),parse:xE("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Qr.transform($s(t))+", "+Qr.transform($s(n))+", "+$s(qs.transform(r))+")"},an={test:e=>qo.test(e)||wd.test(e)||Ki.test(e),parse:e=>qo.test(e)?qo.parse(e):Ki.test(e)?Ki.parse(e):wd.parse(e),transform:e=>ea(e)?e:e.hasOwnProperty("red")?qo.transform(e):Ki.transform(e)},Qt=(e,t,n)=>-n*e+n*t+e;function Td(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function AO({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let o=0,s=0,a=0;if(!t)o=s=a=n;else{const c=n<.5?n*(1+t):n+t-n*t,u=2*n-c;o=Td(u,c,e+1/3),s=Td(u,c,e),a=Td(u,c,e-1/3)}return{red:Math.round(o*255),green:Math.round(s*255),blue:Math.round(a*255),alpha:r}}const Sd=(e,t,n)=>{const r=e*e;return Math.sqrt(Math.max(0,n*(t*t-r)+r))},dO=[wd,qo,Ki],gO=e=>dO.find(t=>t.test(e));function wE(e){const t=gO(e);gr(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`);let n=t.parse(e);return t===Ki&&(n=AO(n)),n}const TE=(e,t)=>{const n=wE(e),r=wE(t),o={...n};return s=>(o.red=Sd(n.red,r.red,s),o.green=Sd(n.green,r.green,s),o.blue=Sd(n.blue,r.blue,s),o.alpha=Qt(n.alpha,r.alpha,s),qo.transform(o))};function fO(e){var t,n;return isNaN(e)&&ea(e)&&(((t=e.match(Gl))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(YC))===null||n===void 0?void 0:n.length)||0)>0}const SE={regex:cP,countKey:"Vars",token:"${v}",parse:Pt},PE={regex:YC,countKey:"Colors",token:"${c}",parse:an.parse},OE={regex:Gl,countKey:"Numbers",token:"${n}",parse:_o.parse};function Pd(e,{regex:t,countKey:n,token:r,parse:o}){const s=e.tokenised.match(t);s&&(e["num"+n]=s.length,e.tokenised=e.tokenised.replace(t,r),e.values.push(...s.map(o)))}function $l(e){const t=e.toString(),n={value:t,tokenised:t,values:[],numVars:0,numColors:0,numNumbers:0};return n.value.includes("var(--")&&Pd(n,SE),Pd(n,PE),Pd(n,OE),n}function jE(e){return $l(e).values}function DE(e){const{values:t,numColors:n,numVars:r,tokenised:o}=$l(e),s=t.length;return a=>{let c=o;for(let u=0;u<s;u++)u<r?c=c.replace(SE.token,a[u]):u<r+n?c=c.replace(PE.token,an.transform(a[u])):c=c.replace(OE.token,$s(a[u]));return c}}const pO=e=>typeof e=="number"?0:e;function hO(e){const t=jE(e);return DE(e)(t.map(pO))}const Co={test:fO,parse:jE,createTransformer:DE,getAnimatableNone:hO},ME=(e,t)=>n=>`${n>0?t:e}`;function kE(e,t){return typeof e=="number"?n=>Qt(e,t,n):an.test(e)?TE(e,t):e.startsWith("var(")?ME(e,t):FE(e,t)}const RE=(e,t)=>{const n=[...e],r=n.length,o=e.map((s,a)=>kE(s,t[a]));return s=>{for(let a=0;a<r;a++)n[a]=o[a](s);return n}},CO=(e,t)=>{const n={...e,...t},r={};for(const o in n)e[o]!==void 0&&t[o]!==void 0&&(r[o]=kE(e[o],t[o]));return o=>{for(const s in r)n[s]=r[s](o);return n}},FE=(e,t)=>{const n=Co.createTransformer(t),r=$l(e),o=$l(t);return r.numVars===o.numVars&&r.numColors===o.numColors&&r.numNumbers>=o.numNumbers?fo(RE(r.values,o.values),n):(na(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),ME(e,t))},ia=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r},LE=(e,t)=>n=>Qt(e,t,n);function EO(e){return typeof e=="number"?LE:typeof e=="string"?an.test(e)?TE:FE:Array.isArray(e)?RE:typeof e=="object"?CO:LE}function IO(e,t,n){const r=[],o=n||EO(e[0]),s=e.length-1;for(let a=0;a<s;a++){let c=o(e[a],e[a+1]);if(t){const u=Array.isArray(t)?t[a]||Pt:t;c=fo(u,c)}r.push(c)}return r}function NE(e,t,{clamp:n=!0,ease:r,mixer:o}={}){const s=e.length;if(gr(s===t.length,"Both input and output ranges must be the same length"),s===1)return()=>t[0];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=IO(t,r,o),c=a.length,u=A=>{let p=0;if(c>1)for(;p<e.length-2&&!(A<e[p+1]);p++);const h=ia(e[p],e[p+1],A);return a[p](h)};return n?A=>u(Ao(e[0],e[s-1],A)):u}function mO(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const o=ia(0,t,r);e.push(Qt(n,1,o))}}function BO(e){const t=[0];return mO(t,e.length-1),t}function vO(e,t){return e.map(n=>n*t)}function yO(e,t){return e.map(()=>t||IE).splice(0,e.length-1)}function ec({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=sO(r)?r.map(QE):QE(r),s={done:!1,value:t[0]},a=vO(n&&n.length===t.length?n:BO(t),e),c=NE(a,t,{ease:Array.isArray(o)?o:yO(t,o)});return{calculatedDuration:e,next:u=>(s.value=c(u),s.done=u>=e,s)}}function VE(e,t){return t?e*(1e3/t):0}const bO=5;function HE(e,t,n){const r=Math.max(t-bO,0);return VE(n-e(r),t-r)}const Od=.001,QO=.01,zE=10,xO=.05,wO=1;function TO({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let o,s;na(e<=ho(zE),"Spring duration must be 10 seconds or less");let a=1-t;a=Ao(xO,wO,a),e=Ao(QO,zE,Wr(e)),a<1?(o=A=>{const p=A*a,h=p*e,C=p-n,E=jd(A,a),m=Math.exp(-h);return Od-C/E*m},s=A=>{const h=A*a*e,C=h*n+n,E=Math.pow(a,2)*Math.pow(A,2)*e,m=Math.exp(-h),B=jd(Math.pow(A,2),a);return(-o(A)+Od>0?-1:1)*((C-E)*m)/B}):(o=A=>{const p=Math.exp(-A*e),h=(A-n)*e+1;return-Od+p*h},s=A=>{const p=Math.exp(-A*e),h=(n-A)*(e*e);return p*h});const c=5/e,u=PO(o,s,c);if(e=ho(e),isNaN(u))return{stiffness:100,damping:10,duration:e};{const A=Math.pow(u,2)*r;return{stiffness:A,damping:a*2*Math.sqrt(r*A),duration:e}}}const SO=12;function PO(e,t,n){let r=n;for(let o=1;o<SO;o++)r=r-e(r)/t(r);return r}function jd(e,t){return e*Math.sqrt(1-t*t)}const OO=["duration","bounce"],jO=["stiffness","damping","mass"];function WE(e,t){return t.some(n=>e[n]!==void 0)}function DO(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!WE(e,jO)&&WE(e,OO)){const n=TO(e);t={...t,...n,mass:1},t.isResolvedFromDuration=!0}return t}function UE({keyframes:e,restDelta:t,restSpeed:n,...r}){const o=e[0],s=e[e.length-1],a={done:!1,value:o},{stiffness:c,damping:u,mass:A,duration:p,velocity:h,isResolvedFromDuration:C}=DO({...r,velocity:-Wr(r.velocity||0)}),E=h||0,m=u/(2*Math.sqrt(c*A)),B=s-o,v=Wr(Math.sqrt(c/A)),S=Math.abs(B)<5;n||(n=S?.01:2),t||(t=S?.005:.5);let M;if(m<1){const x=jd(v,m);M=O=>{const P=Math.exp(-m*v*O);return s-P*((E+m*v*B)/x*Math.sin(x*O)+B*Math.cos(x*O))}}else if(m===1)M=x=>s-Math.exp(-v*x)*(B+(E+v*B)*x);else{const x=v*Math.sqrt(m*m-1);M=O=>{const P=Math.exp(-m*v*O),F=Math.min(x*O,300);return s-P*((E+m*v*B)*Math.sinh(F)+x*B*Math.cosh(F))/x}}return{calculatedDuration:C&&p||null,next:x=>{const O=M(x);if(C)a.done=x>=p;else{let P=E;x!==0&&(m<1?P=HE(M,x,O):P=0);const F=Math.abs(P)<=n,L=Math.abs(s-O)<=t;a.done=F&&L}return a.value=a.done?s:O,a}}}function YE({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:s=500,modifyTarget:a,min:c,max:u,restDelta:A=.5,restSpeed:p}){const h=e[0],C={done:!1,value:h},E=K=>c!==void 0&&K<c||u!==void 0&&K>u,m=K=>c===void 0?u:u===void 0||Math.abs(c-K)<Math.abs(u-K)?c:u;let B=n*t;const v=h+B,S=a===void 0?v:a(v);S!==v&&(B=S-h);const M=K=>-B*Math.exp(-K/r),x=K=>S+M(K),O=K=>{const J=M(K),ee=x(K);C.done=Math.abs(J)<=A,C.value=C.done?S:ee};let P,F;const L=K=>{E(C.value)&&(P=K,F=UE({keyframes:[C.value,m(C.value)],velocity:HE(x,K,C.value),damping:o,stiffness:s,restDelta:A,restSpeed:p}))};return L(0),{calculatedDuration:null,next:K=>{let J=!1;return!F&&P===void 0&&(J=!0,O(K),L(K)),P!==void 0&&K>P?F.next(K-P):(!J&&O(K),C)}}}const MO=e=>{const t=({timestamp:n})=>e(n);return{start:()=>ht.update(t,!0),stop:()=>Vr(t),now:()=>$t.isProcessing?$t.timestamp:performance.now()}},GE=2e4;function KE(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<GE;)t+=n,r=e.next(t);return t>=GE?1/0:t}const kO={decay:YE,inertia:YE,tween:ec,keyframes:ec,spring:UE};function tc({autoplay:e=!0,delay:t=0,driver:n=MO,keyframes:r,type:o="keyframes",repeat:s=0,repeatDelay:a=0,repeatType:c="loop",onPlay:u,onStop:A,onComplete:p,onUpdate:h,...C}){let E=1,m=!1,B,v;const S=()=>{v=new Promise(X=>{B=X})};S();let M;const x=kO[o]||ec;let O;x!==ec&&typeof r[0]!="number"&&(process.env.NODE_ENV!=="production"&&gr(r.length===2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${r}`),O=NE([0,100],r,{clamp:!1}),r=[0,100]);const P=x({...C,keyframes:r});let F;c==="mirror"&&(F=x({...C,keyframes:[...r].reverse(),velocity:-(C.velocity||0)}));let L="idle",K=null,J=null,ee=null;P.calculatedDuration===null&&s&&(P.calculatedDuration=KE(P));const{calculatedDuration:G}=P;let se=1/0,ae=1/0;G!==null&&(se=G+a,ae=se*(s+1)-a);let _=0;const q=X=>{if(J===null)return;E>0&&(J=Math.min(J,X)),E<0&&(J=Math.min(X-ae/E,J)),K!==null?_=K:_=Math.round(X-J)*E;const ce=_-t*(E>=0?1:-1),he=E>=0?ce<0:ce>ae;_=Math.max(ce,0),L==="finished"&&K===null&&(_=ae);let ge=_,fe=P;if(s){const Ee=Math.min(_,ae)/se;let Be=Math.floor(Ee),we=Ee%1;!we&&Ee>=1&&(we=1),we===1&&Be--,Be=Math.min(Be,s+1),!!(Be%2)&&(c==="reverse"?(we=1-we,a&&(we-=a/se)):c==="mirror"&&(fe=F)),ge=Ao(0,1,we)*se}const Ce=he?{done:!1,value:r[0]}:fe.next(ge);O&&(Ce.value=O(Ce.value));let{done:ve}=Ce;!he&&G!==null&&(ve=E>=0?_>=ae:_<=0);const me=K===null&&(L==="finished"||L==="running"&&ve);return h&&h(Ce.value),me&&N(),Ce},z=()=>{M&&M.stop(),M=void 0},Z=()=>{L="idle",z(),B(),S(),J=ee=null},N=()=>{L="finished",p&&p(),z(),B()},$=()=>{if(m)return;M||(M=n(q));const X=M.now();u&&u(),K!==null?J=X-K:(!J||L==="finished")&&(J=X),L==="finished"&&S(),ee=J,K=null,L="running",M.start()};e&&$();const H={then(X,ce){return v.then(X,ce)},get time(){return Wr(_)},set time(X){X=ho(X),_=X,K!==null||!M||E===0?K=X:J=M.now()-X/E},get duration(){const X=P.calculatedDuration===null?KE(P):P.calculatedDuration;return Wr(X)},get speed(){return E},set speed(X){X===E||!M||(E=X,H.time=Wr(_))},get state(){return L},play:$,pause:()=>{L="paused",K=_},stop:()=>{m=!0,L!=="idle"&&(L="idle",A&&A(),Z())},cancel:()=>{ee!==null&&q(ee),Z()},complete:()=>{L="finished"},sample:X=>(J=0,q(X))};return H}function RO(e){let t;return()=>(t===void 0&&(t=e()),t)}const FO=RO(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),LO=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),nc=10,NO=2e4,VO=(e,t)=>t.type==="spring"||e==="backgroundColor"||!pE(t.ease);function HO(e,t,{onUpdate:n,onComplete:r,...o}){if(!(FO()&&LO.has(t)&&!o.repeatDelay&&o.repeatType!=="mirror"&&o.damping!==0&&o.type!=="inertia"))return!1;let a=!1,c,u,A=!1;const p=()=>{u=new Promise(x=>{c=x})};p();let{keyframes:h,duration:C=300,ease:E,times:m}=o;if(VO(t,o)){const x=tc({...o,repeat:0,delay:0});let O={done:!1,value:h[0]};const P=[];let F=0;for(;!O.done&&F<NO;)O=x.sample(F),P.push(O.value),F+=nc;m=void 0,h=P,C=F-nc,E="linear"}const B=$P(e.owner.current,t,h,{...o,duration:C,ease:E,times:m}),v=()=>{A=!1,B.cancel()},S=()=>{A=!0,ht.update(v),c(),p()};return B.onfinish=()=>{A||(e.set(eO(h,o)),r&&r(),S())},{then(x,O){return u.then(x,O)},attachTimeline(x){return B.timeline=x,B.onfinish=null,Pt},get time(){return Wr(B.currentTime||0)},set time(x){B.currentTime=ho(x)},get speed(){return B.playbackRate},set speed(x){B.playbackRate=x},get duration(){return Wr(C)},play:()=>{a||(B.play(),Vr(v))},pause:()=>B.pause(),stop:()=>{if(a=!0,B.playState==="idle")return;const{currentTime:x}=B;if(x){const O=tc({...o,autoplay:!1});e.setWithVelocity(O.sample(x-nc).value,O.sample(x).value,nc)}S()},complete:()=>{A||B.finish()},cancel:S}}function zO({keyframes:e,delay:t,onUpdate:n,onComplete:r}){const o=()=>(n&&n(e[e.length-1]),r&&r(),{time:0,speed:1,duration:0,play:Pt,pause:Pt,stop:Pt,then:s=>(s(),Promise.resolve()),cancel:Pt,complete:Pt});return t?tc({keyframes:[0,1],duration:0,delay:t,onComplete:o}):o()}const WO={type:"spring",stiffness:500,damping:25,restSpeed:10},UO=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),YO={type:"keyframes",duration:.8},GO={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},KO=(e,{keyframes:t})=>t.length>2?YO:Zo.has(e)?e.startsWith("scale")?UO(t[1]):WO:GO,Dd=(e,t)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(Co.test(t)||t==="0")&&!t.startsWith("url(")),JO=new Set(["brightness","contrast","saturate","opacity"]);function XO(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Gl)||[];if(!r)return e;const o=n.replace(r,"");let s=JO.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+o+")"}const ZO=/([a-z-]*)\(.*?\)/g,Md={...Co,getAnimatableNone:e=>{const t=e.match(ZO);return t?t.map(XO).join(" "):e}},_O={...JC,color:an,backgroundColor:an,outlineColor:an,fill:an,stroke:an,borderColor:an,borderTopColor:an,borderRightColor:an,borderBottomColor:an,borderLeftColor:an,filter:Md,WebkitFilter:Md},kd=e=>_O[e];function JE(e,t){let n=kd(e);return n!==Md&&(n=Co),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const XE=e=>/^0[^.\s]+$/.test(e);function qO(e){if(typeof e=="number")return e===0;if(e!==null)return e==="none"||e==="0"||XE(e)}function $O(e,t,n,r){const o=Dd(t,n);let s;Array.isArray(n)?s=[...n]:s=[null,n];const a=r.from!==void 0?r.from:e.get();let c;const u=[];for(let A=0;A<s.length;A++)s[A]===null&&(s[A]=A===0?a:s[A-1]),qO(s[A])&&u.push(A),typeof s[A]=="string"&&s[A]!=="none"&&s[A]!=="0"&&(c=s[A]);if(o&&u.length&&c)for(let A=0;A<u.length;A++){const p=u[A];s[p]=JE(t,c)}return s}function e4({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:s,repeatType:a,repeatDelay:c,from:u,elapsed:A,...p}){return!!Object.keys(p).length}function Rd(e,t){return e[t]||e.default||e}const t4={skipAnimations:!1},Fd=(e,t,n,r={})=>o=>{const s=Rd(r,e)||{},a=s.delay||r.delay||0;let{elapsed:c=0}=r;c=c-ho(a);const u=$O(t,e,n,s),A=u[0],p=u[u.length-1],h=Dd(e,A),C=Dd(e,p);na(h===C,`You are trying to animate ${e} from "${A}" to "${p}". ${A} is not an animatable value - to enable this animation set ${A} to a value animatable to ${p} via the \`style\` property.`);let E={keyframes:u,velocity:t.getVelocity(),ease:"easeOut",...s,delay:-c,onUpdate:m=>{t.set(m),s.onUpdate&&s.onUpdate(m)},onComplete:()=>{o(),s.onComplete&&s.onComplete()}};if(e4(s)||(E={...E,...KO(e,E)}),E.duration&&(E.duration=ho(E.duration)),E.repeatDelay&&(E.repeatDelay=ho(E.repeatDelay)),!h||!C||qP.current||s.type===!1||t4.skipAnimations)return zO(E);if(!r.isHandoff&&t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUpdate){const m=HO(t,e,E);if(m)return m}return tc(E)};function rc(e){return!!(hn(e)&&e.add)}const ZE=e=>/^\-?\d*\.?\d+$/.test(e);function Ld(e,t){e.indexOf(t)===-1&&e.push(t)}function Nd(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class Vd{constructor(){this.subscriptions=[]}add(t){return Ld(this.subscriptions,t),()=>Nd(this.subscriptions,t)}notify(t,n,r){const o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,n,r);else for(let s=0;s<o;s++){const a=this.subscriptions[s];a&&a(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const _E=new Set;function Hd(e,t,n){e||_E.has(t)||(console.warn(t),n&&console.warn(n),_E.add(t))}const n4=e=>!isNaN(parseFloat(e));class r4{constructor(t,n={}){this.version="10.18.0",this.timeDelta=0,this.lastUpdated=0,this.canTrackVelocity=!1,this.events={},this.updateAndNotify=(r,o=!0)=>{this.prev=this.current,this.current=r;const{delta:s,timestamp:a}=$t;this.lastUpdated!==a&&(this.timeDelta=s,this.lastUpdated=a,ht.postRender(this.scheduleVelocityCheck)),this.prev!==this.current&&this.events.change&&this.events.change.notify(this.current),this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()),o&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.scheduleVelocityCheck=()=>ht.postRender(this.velocityCheck),this.velocityCheck=({timestamp:r})=>{r!==this.lastUpdated&&(this.prev=this.current,this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=t,this.canTrackVelocity=n4(this.current),this.owner=n.owner}onChange(t){return process.env.NODE_ENV!=="production"&&Hd(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Vd);const r=this.events[t].add(n);return t==="change"?()=>{r(),ht.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t,n=!0){!n||!this.passiveEffect?this.updateAndNotify(t,n):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,n,r){this.set(n),this.prev=t,this.timeDelta=r}jump(t){this.updateAndNotify(t),this.prev=t,this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?VE(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Ji(e,t){return new r4(e,t)}const qE=e=>t=>t.test(e),$E=[_o,ke,Qr,go,gP,dP,{test:e=>e==="auto",parse:e=>e}],sa=e=>$E.find(qE(e)),o4=[...$E,an,Co],i4=e=>o4.find(qE(e));function s4(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Ji(n))}function a4(e,t){const n=ql(e,t);let{transitionEnd:r={},transition:o={},...s}=n?e.makeTargetAnimatable(n,!1):{};s={...s,...r};for(const a in s){const c=TP(s[a]);s4(e,a,c)}}function l4(e,t,n){var r,o;const s=Object.keys(t).filter(c=>!e.hasValue(c)),a=s.length;if(a)for(let c=0;c<a;c++){const u=s[c],A=t[u];let p=null;Array.isArray(A)&&(p=A[0]),p===null&&(p=(o=(r=n[u])!==null&&r!==void 0?r:e.readValue(u))!==null&&o!==void 0?o:t[u]),p!=null&&(typeof p=="string"&&(ZE(p)||XE(p))?p=parseFloat(p):!i4(p)&&Co.test(A)&&(p=JE(u,A)),e.addValue(u,Ji(p,{owner:e})),n[u]===void 0&&(n[u]=p),p!==null&&e.setBaseTarget(u,p))}}function c4(e,t){return t?(t[e]||t.default||t).from:void 0}function u4(e,t,n){const r={};for(const o in e){const s=c4(o,t);if(s!==void 0)r[o]=s;else{const a=n.getValue(o);a&&(r[o]=a.get())}}return r}function A4({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function d4(e,t){const n=e.get();if(Array.isArray(t)){for(let r=0;r<t.length;r++)if(t[r]!==n)return!0}else return n!==t}function eI(e,t,{delay:n=0,transitionOverride:r,type:o}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:a,...c}=e.makeTargetAnimatable(t);const u=e.getValue("willChange");r&&(s=r);const A=[],p=o&&e.animationState&&e.animationState.getState()[o];for(const h in c){const C=e.getValue(h),E=c[h];if(!C||E===void 0||p&&A4(p,h))continue;const m={delay:n,elapsed:0,...Rd(s||{},h)};if(window.HandoffAppearAnimations){const S=e.getProps()[RC];if(S){const M=window.HandoffAppearAnimations(S,h,C,ht);M!==null&&(m.elapsed=M,m.isHandoff=!0)}}let B=!m.isHandoff&&!d4(C,E);if(m.type==="spring"&&(C.getVelocity()||m.velocity)&&(B=!1),C.animation&&(B=!1),B)continue;C.start(Fd(h,C,E,e.shouldReduceMotion&&Zo.has(h)?{type:!1}:m));const v=C.animation;rc(u)&&(u.add(h),v.then(()=>u.remove(h))),A.push(v)}return a&&Promise.all(A).then(()=>{a&&a4(e,a)}),A}function zd(e,t,n={}){const r=ql(e,t,n.custom);let{transition:o=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(o=n.transitionOverride);const s=r?()=>Promise.all(eI(e,r,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:A=0,staggerChildren:p,staggerDirection:h}=o;return g4(e,t,A+u,p,h,n)}:()=>Promise.resolve(),{when:c}=o;if(c){const[u,A]=c==="beforeChildren"?[s,a]:[a,s];return u().then(()=>A())}else return Promise.all([s(),a(n.delay)])}function g4(e,t,n=0,r=0,o=1,s){const a=[],c=(e.variantChildren.size-1)*r,u=o===1?(A=0)=>A*r:(A=0)=>c-A*r;return Array.from(e.variantChildren).sort(f4).forEach((A,p)=>{A.notify("AnimationStart",t),a.push(zd(A,t,{...s,delay:n+u(p)}).then(()=>A.notify("AnimationComplete",t)))}),Promise.all(a)}function f4(e,t){return e.sortNodePosition(t)}function p4(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const o=t.map(s=>zd(e,s,n));r=Promise.all(o)}else if(typeof t=="string")r=zd(e,t,n);else{const o=typeof t=="function"?ql(e,t,n.custom):t;r=Promise.all(eI(e,o,n))}return r.then(()=>e.notify("AnimationComplete",t))}const h4=[...cd].reverse(),C4=cd.length;function E4(e){return t=>Promise.all(t.map(({animation:n,options:r})=>p4(e,n,r)))}function I4(e){let t=E4(e);const n=B4();let r=!0;const o=(u,A)=>{const p=ql(e,A);if(p){const{transition:h,transitionEnd:C,...E}=p;u={...u,...E,...C}}return u};function s(u){t=u(e)}function a(u,A){const p=e.getProps(),h=e.getVariantContext(!0)||{},C=[],E=new Set;let m={},B=1/0;for(let S=0;S<C4;S++){const M=h4[S],x=n[M],O=p[M]!==void 0?p[M]:h[M],P=Xs(O),F=M===A?x.isActive:null;F===!1&&(B=S);let L=O===h[M]&&O!==p[M]&&P;if(L&&r&&e.manuallyAnimateOnMount&&(L=!1),x.protectedKeys={...m},!x.isActive&&F===null||!O&&!x.prevProp||zl(O)||typeof O=="boolean")continue;let J=m4(x.prevProp,O)||M===A&&x.isActive&&!L&&P||S>B&&P,ee=!1;const G=Array.isArray(O)?O:[O];let se=G.reduce(o,{});F===!1&&(se={});const{prevResolvedValues:ae={}}=x,_={...ae,...se},q=z=>{J=!0,E.has(z)&&(ee=!0,E.delete(z)),x.needsAnimating[z]=!0};for(const z in _){const Z=se[z],N=ae[z];if(m.hasOwnProperty(z))continue;let $=!1;Jl(Z)&&Jl(N)?$=!gE(Z,N):$=Z!==N,$?Z!==void 0?q(z):E.add(z):Z!==void 0&&E.has(z)?q(z):x.protectedKeys[z]=!0}x.prevProp=O,x.prevResolvedValues=se,x.isActive&&(m={...m,...se}),r&&e.blockInitialAnimation&&(J=!1),J&&(!L||ee)&&C.push(...G.map(z=>({animation:z,options:{type:M,...u}})))}if(E.size){const S={};E.forEach(M=>{const x=e.getBaseTarget(M);x!==void 0&&(S[M]=x)}),C.push({animation:S})}let v=!!C.length;return r&&(p.initial===!1||p.initial===p.animate)&&!e.manuallyAnimateOnMount&&(v=!1),r=!1,v?t(C):Promise.resolve()}function c(u,A,p){var h;if(n[u].isActive===A)return Promise.resolve();(h=e.variantChildren)===null||h===void 0||h.forEach(E=>{var m;return(m=E.animationState)===null||m===void 0?void 0:m.setActive(u,A)}),n[u].isActive=A;const C=a(p,u);for(const E in n)n[E].protectedKeys={};return C}return{animateChanges:a,setActive:c,setAnimateFunction:s,getState:()=>n}}function m4(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!gE(t,e):!1}function $o(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function B4(){return{animate:$o(!0),whileInView:$o(),whileHover:$o(),whileTap:$o(),whileDrag:$o(),whileFocus:$o(),exit:$o()}}class v4 extends po{constructor(t){super(t),t.animationState||(t.animationState=I4(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();this.unmount(),zl(t)&&(this.unmount=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){}}let y4=0;class b4 extends po{constructor(){super(...arguments),this.id=y4++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n,custom:r}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===o)return;const s=this.node.animationState.setActive("exit",!t,{custom:r??this.node.getProps().custom});n&&!t&&s.then(()=>n(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const Q4={animation:{Feature:v4},exit:{Feature:b4}},tI=(e,t)=>Math.abs(e-t);function x4(e,t){const n=tI(e.x,t.x),r=tI(e.y,t.y);return Math.sqrt(n**2+r**2)}class nI{constructor(t,n,{transformPagePoint:r,contextWindow:o,dragSnapToOrigin:s=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const h=Ud(this.lastMoveEventInfo,this.history),C=this.startEvent!==null,E=x4(h.offset,{x:0,y:0})>=3;if(!C&&!E)return;const{point:m}=h,{timestamp:B}=$t;this.history.push({...m,timestamp:B});const{onStart:v,onMove:S}=this.handlers;C||(v&&v(this.lastMoveEvent,h),this.startEvent=this.lastMoveEvent),S&&S(this.lastMoveEvent,h)},this.handlePointerMove=(h,C)=>{this.lastMoveEvent=h,this.lastMoveEventInfo=Wd(C,this.transformPagePoint),ht.update(this.updatePoint,!0)},this.handlePointerUp=(h,C)=>{this.end();const{onEnd:E,onSessionEnd:m,resumeAnimation:B}=this.handlers;if(this.dragSnapToOrigin&&B&&B(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const v=Ud(h.type==="pointercancel"?this.lastMoveEventInfo:Wd(C,this.transformPagePoint),this.history);this.startEvent&&E&&E(h,v),m&&m(h,v)},!iE(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.contextWindow=o||window;const a=_l(t),c=Wd(a,this.transformPagePoint),{point:u}=c,{timestamp:A}=$t;this.history=[{...u,timestamp:A}];const{onSessionStart:p}=n;p&&p(t,Ud(c,this.history)),this.removeListeners=fo(zr(this.contextWindow,"pointermove",this.handlePointerMove),zr(this.contextWindow,"pointerup",this.handlePointerUp),zr(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Vr(this.updatePoint)}}function Wd(e,t){return t?{point:t(e.point)}:e}function rI(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Ud({point:e},t){return{point:e,delta:rI(e,oI(t)),offset:rI(e,w4(t)),velocity:T4(t,.1)}}function w4(e){return e[0]}function oI(e){return e[e.length-1]}function T4(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=oI(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>ho(t)));)n--;if(!r)return{x:0,y:0};const s=Wr(o.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const a={x:(o.x-r.x)/s,y:(o.y-r.y)/s};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function Sn(e){return e.max-e.min}function Yd(e,t=0,n=.01){return Math.abs(e-t)<=n}function iI(e,t,n,r=.5){e.origin=r,e.originPoint=Qt(t.min,t.max,e.origin),e.scale=Sn(n)/Sn(t),(Yd(e.scale,1,1e-4)||isNaN(e.scale))&&(e.scale=1),e.translate=Qt(n.min,n.max,e.origin)-e.originPoint,(Yd(e.translate)||isNaN(e.translate))&&(e.translate=0)}function aa(e,t,n,r){iI(e.x,t.x,n.x,r?r.originX:void 0),iI(e.y,t.y,n.y,r?r.originY:void 0)}function sI(e,t,n){e.min=n.min+t.min,e.max=e.min+Sn(t)}function S4(e,t,n){sI(e.x,t.x,n.x),sI(e.y,t.y,n.y)}function aI(e,t,n){e.min=t.min-n.min,e.max=e.min+Sn(t)}function la(e,t,n){aI(e.x,t.x,n.x),aI(e.y,t.y,n.y)}function P4(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?Qt(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?Qt(n,e,r.max):Math.min(e,n)),e}function lI(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function O4(e,{top:t,left:n,bottom:r,right:o}){return{x:lI(e.x,n,o),y:lI(e.y,t,r)}}function cI(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function j4(e,t){return{x:cI(e.x,t.x),y:cI(e.y,t.y)}}function D4(e,t){let n=.5;const r=Sn(e),o=Sn(t);return o>r?n=ia(t.min,t.max-r,e.min):r>o&&(n=ia(e.min,e.max-o,t.min)),Ao(0,1,n)}function M4(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Gd=.35;function k4(e=Gd){return e===!1?e=0:e===!0&&(e=Gd),{x:uI(e,"left","right"),y:uI(e,"top","bottom")}}function uI(e,t,n){return{min:AI(e,t),max:AI(e,n)}}function AI(e,t){return typeof e=="number"?e:e[t]||0}const dI=()=>({translate:0,scale:1,origin:0,originPoint:0}),Xi=()=>({x:dI(),y:dI()}),gI=()=>({min:0,max:0}),Nt=()=>({x:gI(),y:gI()});function Gn(e){return[e("x"),e("y")]}function fI({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function R4({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function F4(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Kd(e){return e===void 0||e===1}function Jd({scale:e,scaleX:t,scaleY:n}){return!Kd(e)||!Kd(t)||!Kd(n)}function ei(e){return Jd(e)||pI(e)||e.z||e.rotate||e.rotateX||e.rotateY}function pI(e){return hI(e.x)||hI(e.y)}function hI(e){return e&&e!=="0%"}function oc(e,t,n){const r=e-n,o=t*r;return n+o}function CI(e,t,n,r,o){return o!==void 0&&(e=oc(e,o,r)),oc(e,n,r)+t}function Xd(e,t=0,n=1,r,o){e.min=CI(e.min,t,n,r,o),e.max=CI(e.max,t,n,r,o)}function EI(e,{x:t,y:n}){Xd(e.x,t.translate,t.scale,t.originPoint),Xd(e.y,n.translate,n.scale,n.originPoint)}function L4(e,t,n,r=!1){const o=n.length;if(!o)return;t.x=t.y=1;let s,a;for(let c=0;c<o;c++){s=n[c],a=s.projectionDelta;const u=s.instance;u&&u.style&&u.style.display==="contents"||(r&&s.options.layoutScroll&&s.scroll&&s!==s.root&&Zi(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,EI(e,a)),r&&ei(s.latestValues)&&Zi(e,s.latestValues))}t.x=II(t.x),t.y=II(t.y)}function II(e){return Number.isInteger(e)||e>1.0000000000001||e<.999999999999?e:1}function Eo(e,t){e.min=e.min+t,e.max=e.max+t}function mI(e,t,[n,r,o]){const s=t[o]!==void 0?t[o]:.5,a=Qt(e.min,e.max,s);Xd(e,t[n],t[r],a,t.scale)}const N4=["x","scaleX","originX"],V4=["y","scaleY","originY"];function Zi(e,t){mI(e.x,t,N4),mI(e.y,t,V4)}function BI(e,t){return fI(F4(e.getBoundingClientRect(),t))}function H4(e,t,n){const r=BI(e,n),{scroll:o}=t;return o&&(Eo(r.x,o.offset.x),Eo(r.y,o.offset.y)),r}const vI=({current:e})=>e?e.ownerDocument.defaultView:null,z4=new WeakMap;class W4{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Nt(),this.visualElement=t}start(t,{snapToCursor:n=!1}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const o=p=>{const{dragSnapToOrigin:h}=this.getProps();h?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(_l(p,"page").point)},s=(p,h)=>{const{drag:C,dragPropagation:E,onDragStart:m}=this.getProps();if(C&&!E&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=cE(C),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Gn(v=>{let S=this.getAxisMotionValue(v).get()||0;if(Qr.test(S)){const{projection:M}=this.visualElement;if(M&&M.layout){const x=M.layout.layoutBox[v];x&&(S=Sn(x)*(parseFloat(S)/100))}}this.originPoint[v]=S}),m&&ht.update(()=>m(p,h),!1,!0);const{animationState:B}=this.visualElement;B&&B.setActive("whileDrag",!0)},a=(p,h)=>{const{dragPropagation:C,dragDirectionLock:E,onDirectionLock:m,onDrag:B}=this.getProps();if(!C&&!this.openGlobalLock)return;const{offset:v}=h;if(E&&this.currentDirection===null){this.currentDirection=U4(v),this.currentDirection!==null&&m&&m(this.currentDirection);return}this.updateAxis("x",h.point,v),this.updateAxis("y",h.point,v),this.visualElement.render(),B&&B(p,h)},c=(p,h)=>this.stop(p,h),u=()=>Gn(p=>{var h;return this.getAnimationState(p)==="paused"&&((h=this.getAxisMotionValue(p).animation)===null||h===void 0?void 0:h.play())}),{dragSnapToOrigin:A}=this.getProps();this.panSession=new nI(t,{onSessionStart:o,onStart:s,onMove:a,onSessionEnd:c,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:A,contextWindow:vI(this.visualElement)})}stop(t,n){const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:o}=n;this.startAnimation(o);const{onDragEnd:s}=this.getProps();s&&ht.update(()=>s(t,n))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:o}=this.getProps();if(!r||!ic(t,o,this.currentDirection))return;const s=this.getAxisMotionValue(t);let a=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(a=P4(a,this.constraints[t],this.elastic[t])),s.set(a)}resolveConstraints(){var t;const{dragConstraints:n,dragElastic:r}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,s=this.constraints;n&&Gi(n)?this.constraints||(this.constraints=this.resolveRefConstraints()):n&&o?this.constraints=O4(o.layoutBox,n):this.constraints=!1,this.elastic=k4(r),s!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&Gn(a=>{this.getAxisMotionValue(a)&&(this.constraints[a]=M4(o.layoutBox[a],this.constraints[a]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Gi(t))return!1;const r=t.current;gr(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:o}=this.visualElement;if(!o||!o.layout)return!1;const s=H4(r,o.root,this.visualElement.getTransformPagePoint());let a=j4(o.layout.layoutBox,s);if(n){const c=n(R4(a));this.hasMutatedConstraints=!!c,c&&(a=fI(c))}return a}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:o,dragTransition:s,dragSnapToOrigin:a,onDragTransitionEnd:c}=this.getProps(),u=this.constraints||{},A=Gn(p=>{if(!ic(p,n,this.currentDirection))return;let h=u&&u[p]||{};a&&(h={min:0,max:0});const C=o?200:1e6,E=o?40:1e7,m={type:"inertia",velocity:r?t[p]:0,bounceStiffness:C,bounceDamping:E,timeConstant:750,restDelta:1,restSpeed:10,...s,...h};return this.startAxisValueAnimation(p,m)});return Promise.all(A).then(c)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return r.start(Fd(t,r,0,n))}stopAnimation(){Gn(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Gn(t=>{var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.state}getAxisMotionValue(t){const n="_drag"+t.toUpperCase(),r=this.visualElement.getProps(),o=r[n];return o||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Gn(n=>{const{drag:r}=this.getProps();if(!ic(n,r,this.currentDirection))return;const{projection:o}=this.visualElement,s=this.getAxisMotionValue(n);if(o&&o.layout){const{min:a,max:c}=o.layout.layoutBox[n];s.set(t[n]-Qt(a,c,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Gi(n)||!r||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};Gn(a=>{const c=this.getAxisMotionValue(a);if(c){const u=c.get();o[a]=D4({min:u,max:u},this.constraints[a])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Gn(a=>{if(!ic(a,t,null))return;const c=this.getAxisMotionValue(a),{min:u,max:A}=this.constraints[a];c.set(Qt(u,A,o[a]))})}addListeners(){if(!this.visualElement.current)return;z4.set(this.visualElement,this);const t=this.visualElement.current,n=zr(t,"pointerdown",u=>{const{drag:A,dragListener:p=!0}=this.getProps();A&&p&&this.start(u)}),r=()=>{const{dragConstraints:u}=this.getProps();Gi(u)&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,s=o.addEventListener("measure",r);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),r();const a=Hr(window,"resize",()=>this.scalePositionWithinConstraints()),c=o.addEventListener("didUpdate",({delta:u,hasLayoutChanged:A})=>{this.isDragging&&A&&(Gn(p=>{const h=this.getAxisMotionValue(p);h&&(this.originPoint[p]+=u[p].translate,h.set(h.get()+u[p].translate))}),this.visualElement.render())});return()=>{a(),n(),s(),c&&c()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:o=!1,dragConstraints:s=!1,dragElastic:a=Gd,dragMomentum:c=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:o,dragConstraints:s,dragElastic:a,dragMomentum:c}}}function ic(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function U4(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class Y4 extends po{constructor(t){super(t),this.removeGroupControls=Pt,this.removeListeners=Pt,this.controls=new W4(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Pt}unmount(){this.removeGroupControls(),this.removeListeners()}}const yI=e=>(t,n)=>{e&&ht.update(()=>e(t,n))};class G4 extends po{constructor(){super(...arguments),this.removePointerDownListener=Pt}onPointerDown(t){this.session=new nI(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:vI(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:o}=this.node.getProps();return{onSessionStart:yI(t),onStart:yI(n),onMove:r,onEnd:(s,a)=>{delete this.session,o&&ht.update(()=>o(s,a))}}}mount(){this.removePointerDownListener=zr(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}function K4(){const e=Q.useContext(ad);if(e===null)return[!0,null];const{isPresent:t,onExitComplete:n,register:r}=e,o=Q.useId();return Q.useEffect(()=>r(o),[]),!t&&n?[!1,()=>n&&n(o)]:[!0]}const sc={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function bI(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const ca={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(ke.test(e))e=parseFloat(e);else return e;const n=bI(e,t.target.x),r=bI(e,t.target.y);return`${n}% ${r}%`}},J4={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=Co.parse(e);if(o.length>5)return r;const s=Co.createTransformer(e),a=typeof o[0]!="number"?1:0,c=n.x.scale*t.x,u=n.y.scale*t.y;o[0+a]/=c,o[1+a]/=u;const A=Qt(c,u,.5);return typeof o[2+a]=="number"&&(o[2+a]/=A),typeof o[3+a]=="number"&&(o[3+a]/=A),s(o)}};class X4 extends Q.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:o}=this.props,{projection:s}=t;iP(Z4),s&&(n.group&&n.group.add(s),r&&r.register&&o&&r.register(s),s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),sc.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:o,isPresent:s}=this.props,a=r.projection;return a&&(a.isPresent=s,o||t.layoutDependency!==n||n===void 0?a.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?a.promote():a.relegate()||ht.postRender(()=>{const c=a.getStack();(!c||!c.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),queueMicrotask(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:o}=t;o&&(o.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(o),r&&r.deregister&&r.deregister(o))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function QI(e){const[t,n]=K4(),r=Q.useContext(VC);return Q.createElement(X4,{...e,layoutGroup:r,switchLayoutGroup:Q.useContext(HC),isPresent:t,safeToRemove:n})}const Z4={borderRadius:{...ca,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:ca,borderTopRightRadius:ca,borderBottomLeftRadius:ca,borderBottomRightRadius:ca,boxShadow:J4},xI=["TopLeft","TopRight","BottomLeft","BottomRight"],_4=xI.length,wI=e=>typeof e=="string"?parseFloat(e):e,TI=e=>typeof e=="number"||ke.test(e);function q4(e,t,n,r,o,s){o?(e.opacity=Qt(0,n.opacity!==void 0?n.opacity:1,$4(r)),e.opacityExit=Qt(t.opacity!==void 0?t.opacity:1,0,ej(r))):s&&(e.opacity=Qt(t.opacity!==void 0?t.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let a=0;a<_4;a++){const c=`border${xI[a]}Radius`;let u=SI(t,c),A=SI(n,c);if(u===void 0&&A===void 0)continue;u||(u=0),A||(A=0),u===0||A===0||TI(u)===TI(A)?(e[c]=Math.max(Qt(wI(u),wI(A),r),0),(Qr.test(A)||Qr.test(u))&&(e[c]+="%")):e[c]=A}(t.rotate||n.rotate)&&(e.rotate=Qt(t.rotate||0,n.rotate||0,r))}function SI(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const $4=PI(0,.5,vE),ej=PI(.5,.95,Pt);function PI(e,t,n){return r=>r<e?0:r>t?1:n(ia(e,t,r))}function OI(e,t){e.min=t.min,e.max=t.max}function Kn(e,t){OI(e.x,t.x),OI(e.y,t.y)}function jI(e,t,n,r,o){return e-=t,e=oc(e,1/n,r),o!==void 0&&(e=oc(e,1/o,r)),e}function tj(e,t=0,n=1,r=.5,o,s=e,a=e){if(Qr.test(t)&&(t=parseFloat(t),t=Qt(a.min,a.max,t/100)-a.min),typeof t!="number")return;let c=Qt(s.min,s.max,r);e===s&&(c-=t),e.min=jI(e.min,t,n,c,o),e.max=jI(e.max,t,n,c,o)}function DI(e,t,[n,r,o],s,a){tj(e,t[n],t[r],t[o],t.scale,s,a)}const nj=["x","scaleX","originX"],rj=["y","scaleY","originY"];function MI(e,t,n,r){DI(e.x,t,nj,n?n.x:void 0,r?r.x:void 0),DI(e.y,t,rj,n?n.y:void 0,r?r.y:void 0)}function kI(e){return e.translate===0&&e.scale===1}function RI(e){return kI(e.x)&&kI(e.y)}function oj(e,t){return e.x.min===t.x.min&&e.x.max===t.x.max&&e.y.min===t.y.min&&e.y.max===t.y.max}function FI(e,t){return Math.round(e.x.min)===Math.round(t.x.min)&&Math.round(e.x.max)===Math.round(t.x.max)&&Math.round(e.y.min)===Math.round(t.y.min)&&Math.round(e.y.max)===Math.round(t.y.max)}function LI(e){return Sn(e.x)/Sn(e.y)}class ij{constructor(){this.members=[]}add(t){Ld(this.members,t),t.scheduleRender()}remove(t){if(Nd(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(o=>t===o);if(n===0)return!1;let r;for(let o=n;o>=0;o--){const s=this.members[o];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:o}=t.options;o===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function NI(e,t,n){let r="";const o=e.x.translate/t.x,s=e.y.translate/t.y;if((o||s)&&(r=`translate3d(${o}px, ${s}px, 0) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{rotate:u,rotateX:A,rotateY:p}=n;u&&(r+=`rotate(${u}deg) `),A&&(r+=`rotateX(${A}deg) `),p&&(r+=`rotateY(${p}deg) `)}const a=e.x.scale*t.x,c=e.y.scale*t.y;return(a!==1||c!==1)&&(r+=`scale(${a}, ${c})`),r||"none"}const sj=(e,t)=>e.depth-t.depth;class aj{constructor(){this.children=[],this.isDirty=!1}add(t){Ld(this.children,t),this.isDirty=!0}remove(t){Nd(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(sj),this.isDirty=!1,this.children.forEach(t)}}function lj(e,t){const n=performance.now(),r=({timestamp:o})=>{const s=o-n;s>=t&&(Vr(r),e(s-t))};return ht.read(r,!0),()=>Vr(r)}function cj(e){window.MotionDebug&&window.MotionDebug.record(e)}function uj(e){return e instanceof SVGElement&&e.tagName!=="svg"}function Aj(e,t,n){const r=hn(e)?e:Ji(e);return r.start(Fd("",r,t,n)),r.animation}const VI=["","X","Y","Z"],dj={visibility:"hidden"},HI=1e3;let gj=0;const ti={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0};function zI({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(a={},c=t==null?void 0:t()){this.id=gj++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,ti.totalNodes=ti.resolvedTargetDeltas=ti.recalculatedProjection=0,this.nodes.forEach(hj),this.nodes.forEach(Bj),this.nodes.forEach(vj),this.nodes.forEach(Cj),cj(ti)},this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=a,this.root=c?c.root||c:this,this.path=c?[...c.path,c]:[],this.parent=c,this.depth=c?c.depth+1:0;for(let u=0;u<this.path.length;u++)this.path[u].shouldResetTransform=!0;this.root===this&&(this.nodes=new aj)}addEventListener(a,c){return this.eventHandlers.has(a)||this.eventHandlers.set(a,new Vd),this.eventHandlers.get(a).add(c)}notifyListeners(a,...c){const u=this.eventHandlers.get(a);u&&u.notify(...c)}hasListeners(a){return this.eventHandlers.has(a)}mount(a,c=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=uj(a),this.instance=a;const{layoutId:u,layout:A,visualElement:p}=this.options;if(p&&!p.current&&p.mount(a),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),c&&(A||u)&&(this.isLayoutDirty=!0),e){let h;const C=()=>this.root.updateBlockedByResize=!1;e(a,()=>{this.root.updateBlockedByResize=!0,h&&h(),h=lj(C,250),sc.hasAnimatedSinceResize&&(sc.hasAnimatedSinceResize=!1,this.nodes.forEach(UI))})}u&&this.root.registerSharedNode(u,this),this.options.animate!==!1&&p&&(u||A)&&this.addEventListener("didUpdate",({delta:h,hasLayoutChanged:C,hasRelativeTargetChanged:E,layout:m})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const B=this.options.transition||p.getDefaultTransition()||wj,{onLayoutAnimationStart:v,onLayoutAnimationComplete:S}=p.getProps(),M=!this.targetLayout||!FI(this.targetLayout,m)||E,x=!C&&E;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||x||C&&(M||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(h,x);const O={...Rd(B,"layout"),onPlay:v,onComplete:S};(p.shouldReduceMotion||this.options.layoutRoot)&&(O.delay=0,O.type=!1),this.startAnimation(O)}else C||UI(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=m})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const a=this.getStack();a&&a.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Vr(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(yj),this.animationId++)}getTransformTemplate(){const{visualElement:a}=this.options;return a&&a.getProps().transformTemplate}willUpdate(a=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let p=0;p<this.path.length;p++){const h=this.path[p];h.shouldResetTransform=!0,h.updateScroll("snapshot"),h.options.layoutRoot&&h.willUpdate(!1)}const{layoutId:c,layout:u}=this.options;if(c===void 0&&!u)return;const A=this.getTransformTemplate();this.prevTransformTemplateValue=A?A(this.latestValues,""):void 0,this.updateSnapshot(),a&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(WI);return}this.isUpdating||this.nodes.forEach(Ij),this.isUpdating=!1,this.nodes.forEach(mj),this.nodes.forEach(fj),this.nodes.forEach(pj),this.clearAllSnapshots();const c=performance.now();$t.delta=Ao(0,1e3/60,c-$t.timestamp),$t.timestamp=c,$t.isProcessing=!0,Id.update.process($t),Id.preRender.process($t),Id.render.process($t),$t.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,queueMicrotask(()=>this.update()))}clearAllSnapshots(){this.nodes.forEach(Ej),this.sharedNodes.forEach(bj)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,ht.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){ht.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let u=0;u<this.path.length;u++)this.path[u].updateScroll();const a=this.layout;this.layout=this.measure(!1),this.layoutCorrected=Nt(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:c}=this.options;c&&c.notify("LayoutMeasure",this.layout.layoutBox,a?a.layoutBox:void 0)}updateScroll(a="measure"){let c=!!(this.options.layoutScroll&&this.instance);this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===a&&(c=!1),c&&(this.scroll={animationId:this.root.animationId,phase:a,isRoot:r(this.instance),offset:n(this.instance)})}resetTransform(){if(!o)return;const a=this.isLayoutDirty||this.shouldResetTransform,c=this.projectionDelta&&!RI(this.projectionDelta),u=this.getTransformTemplate(),A=u?u(this.latestValues,""):void 0,p=A!==this.prevTransformTemplateValue;a&&(c||ei(this.latestValues)||p)&&(o(this.instance,A),this.shouldResetTransform=!1,this.scheduleRender())}measure(a=!0){const c=this.measurePageBox();let u=this.removeElementScroll(c);return a&&(u=this.removeTransform(u)),Tj(u),{animationId:this.root.animationId,measuredBox:c,layoutBox:u,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:a}=this.options;if(!a)return Nt();const c=a.measureViewportBox(),{scroll:u}=this.root;return u&&(Eo(c.x,u.offset.x),Eo(c.y,u.offset.y)),c}removeElementScroll(a){const c=Nt();Kn(c,a);for(let u=0;u<this.path.length;u++){const A=this.path[u],{scroll:p,options:h}=A;if(A!==this.root&&p&&h.layoutScroll){if(p.isRoot){Kn(c,a);const{scroll:C}=this.root;C&&(Eo(c.x,-C.offset.x),Eo(c.y,-C.offset.y))}Eo(c.x,p.offset.x),Eo(c.y,p.offset.y)}}return c}applyTransform(a,c=!1){const u=Nt();Kn(u,a);for(let A=0;A<this.path.length;A++){const p=this.path[A];!c&&p.options.layoutScroll&&p.scroll&&p!==p.root&&Zi(u,{x:-p.scroll.offset.x,y:-p.scroll.offset.y}),ei(p.latestValues)&&Zi(u,p.latestValues)}return ei(this.latestValues)&&Zi(u,this.latestValues),u}removeTransform(a){const c=Nt();Kn(c,a);for(let u=0;u<this.path.length;u++){const A=this.path[u];if(!A.instance||!ei(A.latestValues))continue;Jd(A.latestValues)&&A.updateSnapshot();const p=Nt(),h=A.measurePageBox();Kn(p,h),MI(c,A.latestValues,A.snapshot?A.snapshot.layoutBox:void 0,p)}return ei(this.latestValues)&&MI(c,this.latestValues),c}setTargetDelta(a){this.targetDelta=a,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(a){this.options={...this.options,...a,crossfade:a.crossfade!==void 0?a.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==$t.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(a=!1){var c;const u=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=u.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=u.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=u.isSharedProjectionDirty);const A=!!this.resumingFrom||this!==u;if(!(a||A&&this.isSharedProjectionDirty||this.isProjectionDirty||!((c=this.parent)===null||c===void 0)&&c.isProjectionDirty||this.attemptToResolveRelativeTarget))return;const{layout:h,layoutId:C}=this.options;if(!(!this.layout||!(h||C))){if(this.resolvedRelativeTargetAt=$t.timestamp,!this.targetDelta&&!this.relativeTarget){const E=this.getClosestProjectingParent();E&&E.layout&&this.animationProgress!==1?(this.relativeParent=E,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Nt(),this.relativeTargetOrigin=Nt(),la(this.relativeTargetOrigin,this.layout.layoutBox,E.layout.layoutBox),Kn(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=Nt(),this.targetWithTransforms=Nt()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),S4(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Kn(this.target,this.layout.layoutBox),EI(this.target,this.targetDelta)):Kn(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const E=this.getClosestProjectingParent();E&&!!E.resumingFrom==!!this.resumingFrom&&!E.options.layoutScroll&&E.target&&this.animationProgress!==1?(this.relativeParent=E,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Nt(),this.relativeTargetOrigin=Nt(),la(this.relativeTargetOrigin,this.target,E.target),Kn(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}ti.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||Jd(this.parent.latestValues)||pI(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var a;const c=this.getLead(),u=!!this.resumingFrom||this!==c;let A=!0;if((this.isProjectionDirty||!((a=this.parent)===null||a===void 0)&&a.isProjectionDirty)&&(A=!1),u&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(A=!1),this.resolvedRelativeTargetAt===$t.timestamp&&(A=!1),A)return;const{layout:p,layoutId:h}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(p||h))return;Kn(this.layoutCorrected,this.layout.layoutBox);const C=this.treeScale.x,E=this.treeScale.y;L4(this.layoutCorrected,this.treeScale,this.path,u),c.layout&&!c.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(c.target=c.layout.layoutBox);const{target:m}=c;if(!m){this.projectionTransform&&(this.projectionDelta=Xi(),this.projectionTransform="none",this.scheduleRender());return}this.projectionDelta||(this.projectionDelta=Xi(),this.projectionDeltaWithTransform=Xi());const B=this.projectionTransform;aa(this.projectionDelta,this.layoutCorrected,m,this.latestValues),this.projectionTransform=NI(this.projectionDelta,this.treeScale),(this.projectionTransform!==B||this.treeScale.x!==C||this.treeScale.y!==E)&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",m)),ti.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(a=!0){if(this.options.scheduleRender&&this.options.scheduleRender(),a){const c=this.getStack();c&&c.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}setAnimationOrigin(a,c=!1){const u=this.snapshot,A=u?u.latestValues:{},p={...this.latestValues},h=Xi();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!c;const C=Nt(),E=u?u.source:void 0,m=this.layout?this.layout.source:void 0,B=E!==m,v=this.getStack(),S=!v||v.members.length<=1,M=!!(B&&!S&&this.options.crossfade===!0&&!this.path.some(xj));this.animationProgress=0;let x;this.mixTargetDelta=O=>{const P=O/1e3;YI(h.x,a.x,P),YI(h.y,a.y,P),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(la(C,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Qj(this.relativeTarget,this.relativeTargetOrigin,C,P),x&&oj(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=Nt()),Kn(x,this.relativeTarget)),B&&(this.animationValues=p,q4(p,A,this.latestValues,P,M,S)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=P},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(a){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(Vr(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ht.update(()=>{sc.hasAnimatedSinceResize=!0,this.currentAnimation=Aj(0,HI,{...a,onUpdate:c=>{this.mixTargetDelta(c),a.onUpdate&&a.onUpdate(c)},onComplete:()=>{a.onComplete&&a.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const a=this.getStack();a&&a.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(HI),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const a=this.getLead();let{targetWithTransforms:c,target:u,layout:A,latestValues:p}=a;if(!(!c||!u||!A)){if(this!==a&&this.layout&&A&&ZI(this.options.animationType,this.layout.layoutBox,A.layoutBox)){u=this.target||Nt();const h=Sn(this.layout.layoutBox.x);u.x.min=a.target.x.min,u.x.max=u.x.min+h;const C=Sn(this.layout.layoutBox.y);u.y.min=a.target.y.min,u.y.max=u.y.min+C}Kn(c,u),Zi(c,p),aa(this.projectionDeltaWithTransform,this.layoutCorrected,c,p)}}registerSharedNode(a,c){this.sharedNodes.has(a)||this.sharedNodes.set(a,new ij),this.sharedNodes.get(a).add(c);const A=c.options.initialPromotionConfig;c.promote({transition:A?A.transition:void 0,preserveFollowOpacity:A&&A.shouldPreserveFollowOpacity?A.shouldPreserveFollowOpacity(c):void 0})}isLead(){const a=this.getStack();return a?a.lead===this:!0}getLead(){var a;const{layoutId:c}=this.options;return c?((a=this.getStack())===null||a===void 0?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:c}=this.options;return c?(a=this.getStack())===null||a===void 0?void 0:a.prevLead:void 0}getStack(){const{layoutId:a}=this.options;if(a)return this.root.sharedNodes.get(a)}promote({needsReset:a,transition:c,preserveFollowOpacity:u}={}){const A=this.getStack();A&&A.promote(this,u),a&&(this.projectionDelta=void 0,this.needsReset=!0),c&&this.setOptions({transition:c})}relegate(){const a=this.getStack();return a?a.relegate(this):!1}resetRotation(){const{visualElement:a}=this.options;if(!a)return;let c=!1;const{latestValues:u}=a;if((u.rotate||u.rotateX||u.rotateY||u.rotateZ)&&(c=!0),!c)return;const A={};for(let p=0;p<VI.length;p++){const h="rotate"+VI[p];u[h]&&(A[h]=u[h],a.setStaticValue(h,0))}a.render();for(const p in A)a.setStaticValue(p,A[p]);a.scheduleRender()}getProjectionStyles(a){var c,u;if(!this.instance||this.isSVG)return;if(!this.isVisible)return dj;const A={visibility:""},p=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,A.opacity="",A.pointerEvents=Xl(a==null?void 0:a.pointerEvents)||"",A.transform=p?p(this.latestValues,""):"none",A;const h=this.getLead();if(!this.projectionDelta||!this.layout||!h.target){const B={};return this.options.layoutId&&(B.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,B.pointerEvents=Xl(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!ei(this.latestValues)&&(B.transform=p?p({},""):"none",this.hasProjected=!1),B}const C=h.animationValues||h.latestValues;this.applyTransformsToTarget(),A.transform=NI(this.projectionDeltaWithTransform,this.treeScale,C),p&&(A.transform=p(C,A.transform));const{x:E,y:m}=this.projectionDelta;A.transformOrigin=`${E.origin*100}% ${m.origin*100}% 0`,h.animationValues?A.opacity=h===this?(u=(c=C.opacity)!==null&&c!==void 0?c:this.latestValues.opacity)!==null&&u!==void 0?u:1:this.preserveOpacity?this.latestValues.opacity:C.opacityExit:A.opacity=h===this?C.opacity!==void 0?C.opacity:"":C.opacityExit!==void 0?C.opacityExit:0;for(const B in Ul){if(C[B]===void 0)continue;const{correct:v,applyTo:S}=Ul[B],M=A.transform==="none"?C[B]:v(C[B],h);if(S){const x=S.length;for(let O=0;O<x;O++)A[S[O]]=M}else A[B]=M}return this.options.layoutId&&(A.pointerEvents=h===this?Xl(a==null?void 0:a.pointerEvents)||"":"none"),A}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(a=>{var c;return(c=a.currentAnimation)===null||c===void 0?void 0:c.stop()}),this.root.nodes.forEach(WI),this.root.sharedNodes.clear()}}}function fj(e){e.updateLayout()}function pj(e){var t;const n=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:o}=e.layout,{animationType:s}=e.options,a=n.source!==e.layout.source;s==="size"?Gn(h=>{const C=a?n.measuredBox[h]:n.layoutBox[h],E=Sn(C);C.min=r[h].min,C.max=C.min+E}):ZI(s,n.layoutBox,r)&&Gn(h=>{const C=a?n.measuredBox[h]:n.layoutBox[h],E=Sn(r[h]);C.max=C.min+E,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[h].max=e.relativeTarget[h].min+E)});const c=Xi();aa(c,r,n.layoutBox);const u=Xi();a?aa(u,e.applyTransform(o,!0),n.measuredBox):aa(u,r,n.layoutBox);const A=!RI(c);let p=!1;if(!e.resumeFrom){const h=e.getClosestProjectingParent();if(h&&!h.resumeFrom){const{snapshot:C,layout:E}=h;if(C&&E){const m=Nt();la(m,n.layoutBox,C.layoutBox);const B=Nt();la(B,r,E.layoutBox),FI(m,B)||(p=!0),h.options.layoutRoot&&(e.relativeTarget=B,e.relativeTargetOrigin=m,e.relativeParent=h)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:u,layoutDelta:c,hasLayoutChanged:A,hasRelativeTargetChanged:p})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function hj(e){ti.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Cj(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Ej(e){e.clearSnapshot()}function WI(e){e.clearMeasurements()}function Ij(e){e.isLayoutDirty=!1}function mj(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function UI(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Bj(e){e.resolveTargetDelta()}function vj(e){e.calcProjection()}function yj(e){e.resetRotation()}function bj(e){e.removeLeadSnapshot()}function YI(e,t,n){e.translate=Qt(t.translate,0,n),e.scale=Qt(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function GI(e,t,n,r){e.min=Qt(t.min,n.min,r),e.max=Qt(t.max,n.max,r)}function Qj(e,t,n,r){GI(e.x,t.x,n.x,r),GI(e.y,t.y,n.y,r)}function xj(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const wj={duration:.45,ease:[.4,0,.1,1]},KI=e=>typeof navigator<"u"&&navigator.userAgent.toLowerCase().includes(e),JI=KI("applewebkit/")&&!KI("chrome/")?Math.round:Pt;function XI(e){e.min=JI(e.min),e.max=JI(e.max)}function Tj(e){XI(e.x),XI(e.y)}function ZI(e,t,n){return e==="position"||e==="preserve-aspect"&&!Yd(LI(t),LI(n),.2)}const Sj=zI({attachResizeListener:(e,t)=>Hr(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Zd={current:void 0},_I=zI({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Zd.current){const e=new Sj({});e.mount(window),e.setOptions({layoutScroll:!0}),Zd.current=e}return Zd.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Pj={pan:{Feature:G4},drag:{Feature:Y4,ProjectionNode:_I,MeasureLayout:QI}},Oj=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;function jj(e){const t=Oj.exec(e);if(!t)return[,];const[,n,r]=t;return[n,r]}const Dj=4;function _d(e,t,n=1){gr(n<=Dj,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,o]=jj(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const a=s.trim();return ZE(a)?parseFloat(a):a}else return dd(o)?_d(o,t,n+1):o}function Mj(e,{...t},n){const r=e.current;if(!(r instanceof Element))return{target:t,transitionEnd:n};n&&(n={...n}),e.values.forEach(o=>{const s=o.get();if(!dd(s))return;const a=_d(s,r);a&&o.set(a)});for(const o in t){const s=t[o];if(!dd(s))continue;const a=_d(s,r);a&&(t[o]=a,n||(n={}),n[o]===void 0&&(n[o]=s))}return{target:t,transitionEnd:n}}const kj=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),qI=e=>kj.has(e),Rj=e=>Object.keys(e).some(qI),ac=e=>e===_o||e===ke,$I=(e,t)=>parseFloat(e.split(", ")[t]),em=(e,t)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;const o=r.match(/^matrix3d\((.+)\)$/);if(o)return $I(o[1],t);{const s=r.match(/^matrix\((.+)\)$/);return s?$I(s[1],e):0}},Fj=new Set(["x","y","z"]),Lj=_s.filter(e=>!Fj.has(e));function Nj(e){const t=[];return Lj.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t.length&&e.render(),t}const _i={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:em(4,13),y:em(5,14)};_i.translateX=_i.x,_i.translateY=_i.y;const Vj=(e,t,n)=>{const r=t.measureViewportBox(),o=t.current,s=getComputedStyle(o),{display:a}=s,c={};a==="none"&&t.setStaticValue("display",e.display||"block"),n.forEach(A=>{c[A]=_i[A](r,s)}),t.render();const u=t.measureViewportBox();return n.forEach(A=>{const p=t.getValue(A);p&&p.jump(c[A]),e[A]=_i[A](u,s)}),e},Hj=(e,t,n={},r={})=>{t={...t},r={...r};const o=Object.keys(t).filter(qI);let s=[],a=!1;const c=[];if(o.forEach(u=>{const A=e.getValue(u);if(!e.hasValue(u))return;let p=n[u],h=sa(p);const C=t[u];let E;if(Jl(C)){const m=C.length,B=C[0]===null?1:0;p=C[B],h=sa(p);for(let v=B;v<m&&C[v]!==null;v++)E?gr(sa(C[v])===E,"All keyframes must be of the same type"):(E=sa(C[v]),gr(E===h||ac(h)&&ac(E),"Keyframes must be of the same dimension as the current value"))}else E=sa(C);if(h!==E)if(ac(h)&&ac(E)){const m=A.get();typeof m=="string"&&A.set(parseFloat(m)),typeof C=="string"?t[u]=parseFloat(C):Array.isArray(C)&&E===ke&&(t[u]=C.map(parseFloat))}else h!=null&&h.transform&&(E!=null&&E.transform)&&(p===0||C===0)?p===0?A.set(E.transform(p)):t[u]=h.transform(C):(a||(s=Nj(e),a=!0),c.push(u),r[u]=r[u]!==void 0?r[u]:t[u],A.jump(C))}),c.length){const u=c.indexOf("height")>=0?window.pageYOffset:null,A=Vj(t,e,c);return s.length&&s.forEach(([p,h])=>{e.getValue(p).set(h)}),e.render(),Hl&&u!==null&&window.scrollTo({top:u}),{target:A,transitionEnd:r}}else return{target:t,transitionEnd:r}};function zj(e,t,n,r){return Rj(t)?Hj(e,t,n,r):{target:t,transitionEnd:r}}const Wj=(e,t,n,r)=>{const o=Mj(e,t,r);return t=o.target,r=o.transitionEnd,zj(e,t,n,r)},qd={current:null},tm={current:!1};function Uj(){if(tm.current=!0,!!Hl)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>qd.current=e.matches;e.addListener(t),t()}else qd.current=!1}function Yj(e,t,n){const{willChange:r}=t;for(const o in t){const s=t[o],a=n[o];if(hn(s))e.addValue(o,s),rc(r)&&r.add(o),process.env.NODE_ENV==="development"&&Hd(s.version==="10.18.0",`Attempting to mix Framer Motion versions ${s.version} with 10.18.0 may not work as expected.`);else if(hn(a))e.addValue(o,Ji(s,{owner:e})),rc(r)&&r.remove(o);else if(a!==s)if(e.hasValue(o)){const c=e.getValue(o);!c.hasAnimated&&c.set(s)}else{const c=e.getStaticValue(o);e.addValue(o,Ji(c!==void 0?c:s,{owner:e}))}}for(const o in n)t[o]===void 0&&e.removeValue(o);return t}const nm=new WeakMap,rm=Object.keys(Zs),Gj=rm.length,om=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],Kj=ud.length;class Jj{constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:o,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.scheduleRender=()=>ht.render(this.render,!1,!0);const{latestValues:c,renderState:u}=s;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=a,this.isControllingVariants=Wl(n),this.isVariantNode=FC(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:A,...p}=this.scrapeMotionValuesFromProps(n,{});for(const h in p){const C=p[h];c[h]!==void 0&&hn(C)&&(C.set(c[h],!1),rc(A)&&A.add(h))}}scrapeMotionValuesFromProps(t,n){return{}}mount(t){this.current=t,nm.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),tm.current||Uj(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:qd.current,process.env.NODE_ENV!=="production"&&Hd(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){nm.delete(this.current),this.projection&&this.projection.unmount(),Vr(this.notifyUpdate),Vr(this.render),this.valueSubscriptions.forEach(t=>t()),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features)this.features[t].unmount();this.current=null}bindToMotionValue(t,n){const r=Zo.has(t),o=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&ht.update(this.notifyUpdate,!1,!0),r&&this.projection&&(this.projection.isTransformDirty=!0)}),s=n.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{o(),s()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}loadFeatures({children:t,...n},r,o,s){let a,c;if(process.env.NODE_ENV!=="production"&&o&&r){const u="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";n.ignoreStrict?na(!1,u):gr(!1,u)}for(let u=0;u<Gj;u++){const A=rm[u],{isEnabled:p,Feature:h,ProjectionNode:C,MeasureLayout:E}=Zs[A];C&&(a=C),p(n)&&(!this.features[A]&&h&&(this.features[A]=new h(this)),E&&(c=E))}if((this.type==="html"||this.type==="svg")&&!this.projection&&a){this.projection=new a(this.latestValues,this.parent&&this.parent.projection);const{layoutId:u,layout:A,drag:p,dragConstraints:h,layoutScroll:C,layoutRoot:E}=n;this.projection.setOptions({layoutId:u,layout:A,alwaysMeasureLayout:!!p||h&&Gi(h),visualElement:this,scheduleRender:()=>this.scheduleRender(),animationType:typeof A=="string"?A:"both",initialPromotionConfig:s,layoutScroll:C,layoutRoot:E})}return c}updateFeatures(){for(const t in this.features){const n=this.features[t];n.isMounted?n.update():(n.mount(),n.isMounted=!0)}}triggerBuild(){this.build(this.renderState,this.latestValues,this.options,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Nt()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}makeTargetAnimatable(t,n=!0){return this.makeTargetAnimatableFromInstance(t,this.props,n)}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<om.length;r++){const o=om[r];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);const s=t["on"+o];s&&(this.propEventSubscriptions[o]=this.on(o,s))}this.prevMotionValues=Yj(this,this.scrapeMotionValuesFromProps(t,this.prevProps),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}getVariantContext(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){const r=this.parent?this.parent.getVariantContext()||{}:{};return this.props.initial!==void 0&&(r.initial=this.props.initial),r}const n={};for(let r=0;r<Kj;r++){const o=ud[r],s=this.props[o];(Xs(s)||s===!1)&&(n[o]=s)}return n}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){n!==this.values.get(t)&&(this.removeValue(t),this.bindToMotionValue(t,n)),this.values.set(t,n),this.latestValues[t]=n.get()}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Ji(n,{owner:this}),this.addValue(t,r)),r}readValue(t){var n;return this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options)}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:r}=this.props,o=typeof r=="string"||typeof r=="object"?(n=Ed(this.props,r))===null||n===void 0?void 0:n[t]:void 0;if(r&&o!==void 0)return o;const s=this.getBaseTargetFromProps(this.props,t);return s!==void 0&&!hn(s)?s:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Vd),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class im extends Jj{sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}makeTargetAnimatableFromInstance({transition:t,transitionEnd:n,...r},{transformValues:o},s){let a=u4(r,t||{},this);if(o&&(n&&(n=o(n)),r&&(r=o(r)),a&&(a=o(a))),s){l4(this,r,a);const c=Wj(this,r,a,n);n=c.transitionEnd,r=c.target}return{transition:t,transitionEnd:n,...r}}}function Xj(e){return window.getComputedStyle(e)}class Zj extends im{constructor(){super(...arguments),this.type="html"}readValueFromInstance(t,n){if(Zo.has(n)){const r=kd(n);return r&&r.default||0}else{const r=Xj(t),o=(UC(n)?r.getPropertyValue(n):r[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return BI(t,n)}build(t,n,r,o){gd(t,n,r,o.transformTemplate)}scrapeMotionValuesFromProps(t,n){return Cd(t,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;hn(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}renderInstance(t,n,r,o){$C(t,n,r,o)}}class _j extends im{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Zo.has(n)){const r=kd(n);return r&&r.default||0}return n=eE.has(n)?n:ld(n),t.getAttribute(n)}measureInstanceViewportBox(){return Nt()}scrapeMotionValuesFromProps(t,n){return nE(t,n)}build(t,n,r,o){pd(t,n,r,this.isSVGTag,o.transformTemplate)}renderInstance(t,n,r,o){tE(t,n,r,o)}mount(t){this.isSVGTag=hd(t.tagName),super.mount(t)}}const qj=(e,t)=>Ad(e)?new _j(t,{enableHardwareAcceleration:!1}):new Zj(t,{enableHardwareAcceleration:!0}),$j={...Q4,...XP,...Pj,...{layout:{ProjectionNode:_I,MeasureLayout:QI}}},lc=rP((e,t)=>RP(e,t,$j,qj)),eD=(e,t,n)=>{const r=t-e;return((n-e)%r+r)%r+e};function sm(...e){const t=Q.useRef(0),[n,r]=Q.useState(e[t.current]),o=Q.useCallback(s=>{t.current=typeof s!="number"?eD(0,e.length,t.current+1):s,r(e[t.current])},[e.length,...e]);return[n,o]}function am({children:e,type:t="scale",direction:n="right",offset:r=10,scale:o={hover:1.05,tap:.95}}){let s,a;switch(n){case"up":case"left":s=r,a=0;break;case"right":case"down":default:s=0,a=r;break}const[c,u]=sm(s,a),[A,p]=sm(s,a);switch(t){case"rotate":return g.jsx(lc.div,{animate:{rotate:360},transition:{repeat:1/0,repeatType:"loop",duration:2,repeatDelay:0},children:e});case"slide":return n==="up"||n==="down"?g.jsx(lc.div,{animate:{y:A!==void 0?A:""},onHoverEnd:()=>p(),onHoverStart:()=>p(),children:e}):g.jsx(lc.div,{animate:{x:c!==void 0?c:""},onHoverEnd:()=>u(),onHoverStart:()=>u(),children:e});case"scale":default:return typeof o=="number"&&(o={hover:o,tap:o}),g.jsx(lc.div,{whileHover:{scale:o==null?void 0:o.hover},whileTap:{scale:o==null?void 0:o.tap},children:e})}}am.propTypes={children:f.node,offset:f.number,type:f.oneOf(["slide","scale","rotate"]),direction:f.oneOf(["up","down","left","right"]),scale:f.oneOfType([f.number,f.object])};function tD(e){return Dt("MuiSvgIcon",e)}Ft("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const nD=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],rD=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Oe(t)}`,`fontSize${Oe(n)}`]};return qt(o,tD,r)},oD=Ae("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Oe(n.color)}`],t[`fontSize${Oe(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,a,c,u,A,p,h,C,E,m;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(a=s.pxToRem)==null?void 0:a.call(s,20))||"1.25rem",medium:((c=e.typography)==null||(u=c.pxToRem)==null?void 0:u.call(c,24))||"1.5rem",large:((A=e.typography)==null||(p=A.pxToRem)==null?void 0:p.call(A,35))||"2.1875rem"}[t.fontSize],color:(h=(C=(e.vars||e).palette)==null||(C=C[t.color])==null?void 0:C.main)!=null?h:{action:(E=(e.vars||e).palette)==null||(E=E.action)==null?void 0:E.active,disabled:(m=(e.vars||e).palette)==null||(m=m.action)==null?void 0:m.disabled,inherit:void 0}[t.color]}}),$d=R.forwardRef(function(t,n){const r=Lt({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:a="inherit",component:c="svg",fontSize:u="medium",htmlColor:A,inheritViewBox:p=!1,titleAccess:h,viewBox:C="0 0 24 24"}=r,E=Ve(r,nD),m=R.isValidElement(o)&&o.type==="svg",B=W({},r,{color:a,component:c,fontSize:u,instanceFontSize:t.fontSize,inheritViewBox:p,viewBox:C,hasSvgAsChild:m}),v={};p||(v.viewBox=C);const S=rD(B);return g.jsxs(oD,W({as:c,className:Ue(S.root,s),focusable:"false",color:A,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n},v,E,m&&o.props,{ownerState:B,children:[m?o.props.children:o,h?g.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&($d.propTypes={children:f.node,classes:f.object,className:f.string,color:f.oneOfType([f.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),f.string]),component:f.elementType,fontSize:f.oneOfType([f.oneOf(["inherit","large","medium","small"]),f.string]),htmlColor:f.string,inheritViewBox:f.bool,shapeRendering:f.string,sx:f.oneOfType([f.arrayOf(f.oneOfType([f.func,f.object,f.bool])),f.func,f.object]),titleAccess:f.string,viewBox:f.string}),$d.muiName="SvgIcon";const lm=$d;function eg(e,t){function n(r,o){return g.jsx(lm,W({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=lm.muiName,R.memo(R.forwardRef(n))}const iD=eg(g.jsx("path",{d:"M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"}),"Person");function sD(e){return Dt("MuiAvatar",e)}Ft("MuiAvatar",["root","colorDefault","circular","rounded","square","img","fallback"]);const aD=["alt","children","className","component","imgProps","sizes","src","srcSet","variant"],lD=e=>{const{classes:t,variant:n,colorDefault:r}=e;return qt({root:["root",n,r&&"colorDefault"],img:["img"],fallback:["fallback"]},sD,t)},cD=Ae("div",{name:"MuiAvatar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],n.colorDefault&&t.colorDefault]}})(({theme:e,ownerState:t})=>W({position:"relative",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,width:40,height:40,fontFamily:e.typography.fontFamily,fontSize:e.typography.pxToRem(20),lineHeight:1,borderRadius:"50%",overflow:"hidden",userSelect:"none"},t.variant==="rounded"&&{borderRadius:(e.vars||e).shape.borderRadius},t.variant==="square"&&{borderRadius:0},t.colorDefault&&W({color:(e.vars||e).palette.background.default},e.vars?{backgroundColor:e.vars.palette.Avatar.defaultBg}:{backgroundColor:e.palette.mode==="light"?e.palette.grey[400]:e.palette.grey[600]}))),uD=Ae("img",{name:"MuiAvatar",slot:"Img",overridesResolver:(e,t)=>t.img})({width:"100%",height:"100%",textAlign:"center",objectFit:"cover",color:"transparent",textIndent:1e4}),AD=Ae(iD,{name:"MuiAvatar",slot:"Fallback",overridesResolver:(e,t)=>t.fallback})({width:"75%",height:"75%"});function dD({crossOrigin:e,referrerPolicy:t,src:n,srcSet:r}){const[o,s]=R.useState(!1);return R.useEffect(()=>{if(!n&&!r)return;s(!1);let a=!0;const c=new Image;return c.onload=()=>{a&&s("loaded")},c.onerror=()=>{a&&s("error")},c.crossOrigin=e,c.referrerPolicy=t,c.src=n,r&&(c.srcset=r),()=>{a=!1}},[e,t,n,r]),o}const cm=R.forwardRef(function(t,n){const r=Lt({props:t,name:"MuiAvatar"}),{alt:o,children:s,className:a,component:c="div",imgProps:u,sizes:A,src:p,srcSet:h,variant:C="circular"}=r,E=Ve(r,aD);let m=null;const B=dD(W({},u,{src:p,srcSet:h})),v=p||h,S=v&&B!=="error",M=W({},r,{colorDefault:!S,component:c,variant:C}),x=lD(M);return S?m=g.jsx(uD,W({alt:o,srcSet:h,src:p,sizes:A,ownerState:M,className:x.img},u)):s!=null?m=s:v&&o?m=o[0]:m=g.jsx(AD,{ownerState:M,className:x.fallback}),g.jsx(cD,W({as:c,ownerState:M,className:Ue(x.root,a),ref:n},E,{children:m}))});process.env.NODE_ENV!=="production"&&(cm.propTypes={alt:f.string,children:f.node,classes:f.object,className:f.string,component:f.elementType,imgProps:f.object,sizes:f.string,src:f.string,srcSet:f.string,sx:f.oneOfType([f.arrayOf(f.oneOfType([f.func,f.object,f.bool])),f.func,f.object]),variant:f.oneOfType([f.oneOf(["circular","rounded","square"]),f.string])});const gD=cm,en=(e,t)=>{switch(t){case"secondary":return e.palette.secondary;case"error":return e.palette.error;case"warning":return e.palette.warning;case"info":return e.palette.info;case"success":return e.palette.success;default:return e.palette.primary}};function fD({theme:e,color:t,type:n}){const r=en(e,t),{lighter:o,light:s,main:a,contrastText:c}=r;switch(n){case"filled":return{color:c,backgroundColor:a};case"outlined":return{color:a,border:"1px solid",borderColor:a,backgroundColor:"transparent"};case"combined":return{color:a,border:"1px solid",borderColor:s,backgroundColor:o};default:return{color:a,backgroundColor:o}}}function pD(e){switch(e){case"badge":return{border:"2px solid",fontSize:"0.675rem",width:20,height:20};case"xs":return{fontSize:"0.75rem",width:24,height:24};case"sm":return{fontSize:"0.875rem",width:32,height:32};case"lg":return{fontSize:"1.2rem",width:52,height:52};case"xl":return{fontSize:"1.5rem",width:64,height:64};case"md":default:return{fontSize:"1rem",width:40,height:40}}}const hD=Ae(gD,{shouldForwardProp:e=>e!=="color"&&e!=="type"&&e!=="size"})(({theme:e,variant:t,color:n,type:r,size:o})=>({...pD(o),...fD({variant:t,theme:e,color:n,type:r}),...o==="badge"&&{borderColor:e.palette.background.default}}));function ua({variant:e="circular",children:t,color:n="primary",type:r,size:o="md",...s}){const a=Bt();return g.jsx(hD,{variant:e,theme:a,color:n,type:r,size:o,...s,children:t})}ua.propTypes={children:f.node,color:f.string,type:f.string,size:f.string,variant:f.string};const um={p:2.5,"& .MuiCardHeader-action":{m:"0px auto",alignSelf:"center"}},Jn=Q.forwardRef(({border:e=!0,boxShadow:t,children:n,subheader:r,content:o=!0,contentSX:s={},darkTitle:a,divider:c=!0,elevation:u,secondary:A,shadow:p,sx:h={},title:C,modal:E=!1,color:m="default",...B},v)=>{const S=Bt();return t=S.palette.mode==="dark"?t||!0:t,g.jsxs(b.Card,{elevation:u||0,ref:v,...B,sx:{position:"relative",border:e?"1px solid":"none",borderRadius:1,borderColor:S.palette.mode==="dark"?S.palette.divider:S.palette.grey.A800,boxShadow:t&&(!e||S.palette.mode==="dark")?p||S.customShadows.z1:"inherit",":hover":{boxShadow:t?p||S.customShadows.z1:"inherit"},backgroundColor:m==="default"?S.palette.background.paper:Li(m==="primary"?S.palette.primary[100]:S.palette.secondary[100],.5),...E&&{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:{xs:"calc( 100% - 50px)",sm:"auto"},"& .MuiCardContent-root":{overflowY:"auto",minHeight:"auto",maxHeight:"calc(100vh - 200px)"}},...h},children:[!a&&C&&g.jsx(b.CardHeader,{sx:um,title:C,action:A,subheader:r}),a&&C&&g.jsx(b.CardHeader,{sx:um,title:g.jsx(b.Typography,{variant:"h4",children:C}),action:A}),C&&c&&g.jsx(b.Divider,{}),o&&g.jsx(b.CardContent,{sx:s,children:n}),!o&&n]})});Jn.propTypes={border:f.bool,boxShadow:f.bool,children:f.oneOfType([f.node,f.arrayOf(f.node)]),subheader:f.oneOfType([f.node,f.string]),content:f.bool,contentClass:f.string,contentSX:f.object,darkTitle:f.bool,divider:f.bool,elevation:f.number,secondary:f.oneOfType([f.node,f.string,f.object]),shadow:f.string,sx:f.object,title:f.oneOfType([f.node,f.string,f.object]),modal:f.bool,color:f.oneOf(["default","primary","secondary"])};function CD(e){return Dt("MuiTypography",e)}Ft("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const ED=["align","className","component","gutterBottom","noWrap","paragraph","variant","variantMapping"],ID=e=>{const{align:t,gutterBottom:n,noWrap:r,paragraph:o,variant:s,classes:a}=e,c={root:["root",s,e.align!=="inherit"&&`align${Oe(t)}`,n&&"gutterBottom",r&&"noWrap",o&&"paragraph"]};return qt(c,CD,a)},mD=Ae("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.variant&&t[n.variant],n.align!=="inherit"&&t[`align${Oe(n.align)}`],n.noWrap&&t.noWrap,n.gutterBottom&&t.gutterBottom,n.paragraph&&t.paragraph]}})(({theme:e,ownerState:t})=>W({margin:0},t.variant==="inherit"&&{font:"inherit"},t.variant!=="inherit"&&e.typography[t.variant],t.align!=="inherit"&&{textAlign:t.align},t.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t.gutterBottom&&{marginBottom:"0.35em"},t.paragraph&&{marginBottom:16})),Am={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},BD={primary:"primary.main",textPrimary:"text.primary",secondary:"secondary.main",textSecondary:"text.secondary",error:"error.main"},vD=e=>BD[e]||e,dm=R.forwardRef(function(t,n){const r=Lt({props:t,name:"MuiTypography"}),o=vD(r.color),s=Yw(W({},r,{color:o})),{align:a="inherit",className:c,component:u,gutterBottom:A=!1,noWrap:p=!1,paragraph:h=!1,variant:C="body1",variantMapping:E=Am}=s,m=Ve(s,ED),B=W({},s,{align:a,color:o,className:c,component:u,gutterBottom:A,noWrap:p,paragraph:h,variant:C,variantMapping:E}),v=u||(h?"p":E[C]||Am[C])||"span",S=ID(B);return g.jsx(mD,W({as:v,ref:n,ownerState:B,className:Ue(S.root,c)},m))});process.env.NODE_ENV!=="production"&&(dm.propTypes={align:f.oneOf(["center","inherit","justify","left","right"]),children:f.node,classes:f.object,className:f.string,component:f.elementType,gutterBottom:f.bool,noWrap:f.bool,paragraph:f.bool,sx:f.oneOfType([f.arrayOf(f.oneOfType([f.func,f.object,f.bool])),f.func,f.object]),variant:f.oneOfType([f.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),f.string]),variantMapping:f.object});const gm=dm,yD=eg(g.jsx("path",{d:"M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}),"MoreHoriz");function tg(e,t){return tg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},tg(e,t)}function ng(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,tg(e,t)}const fm={disabled:!1};var bD=process.env.NODE_ENV!=="production"?f.oneOfType([f.number,f.shape({enter:f.number,exit:f.number,appear:f.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&f.oneOfType([f.string,f.shape({enter:f.string,exit:f.string,active:f.string}),f.shape({enter:f.string,enterDone:f.string,enterActive:f.string,exit:f.string,exitDone:f.string,exitActive:f.string})]);const cc=Q.createContext(null);var QD=function(t){return t.scrollTop},Aa="unmounted",ni="exited",ri="entering",qi="entered",rg="exiting",Ur=function(e){ng(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var a=o,c=a&&!a.isMounting?r.enter:r.appear,u;return s.appearStatus=null,r.in?c?(u=ni,s.appearStatus=ri):u=qi:r.unmountOnExit||r.mountOnEnter?u=Aa:u=ni,s.state={status:u},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var a=o.in;return a&&s.status===Aa?{status:ni}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var a=this.state.status;this.props.in?a!==ri&&a!==qi&&(s=ri):(a===ri||a===qi)&&(s=rg)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,a,c;return s=a=c=o,o!=null&&typeof o!="number"&&(s=o.exit,a=o.enter,c=o.appear!==void 0?o.appear:a),{exit:s,enter:a,appear:c}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ri){if(this.props.unmountOnExit||this.props.mountOnEnter){var a=this.props.nodeRef?this.props.nodeRef.current:ji.findDOMNode(this);a&&QD(a)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===ni&&this.setState({status:Aa})},n.performEnter=function(o){var s=this,a=this.props.enter,c=this.context?this.context.isMounting:o,u=this.props.nodeRef?[c]:[ji.findDOMNode(this),c],A=u[0],p=u[1],h=this.getTimeouts(),C=c?h.appear:h.enter;if(!o&&!a||fm.disabled){this.safeSetState({status:qi},function(){s.props.onEntered(A)});return}this.props.onEnter(A,p),this.safeSetState({status:ri},function(){s.props.onEntering(A,p),s.onTransitionEnd(C,function(){s.safeSetState({status:qi},function(){s.props.onEntered(A,p)})})})},n.performExit=function(){var o=this,s=this.props.exit,a=this.getTimeouts(),c=this.props.nodeRef?void 0:ji.findDOMNode(this);if(!s||fm.disabled){this.safeSetState({status:ni},function(){o.props.onExited(c)});return}this.props.onExit(c),this.safeSetState({status:rg},function(){o.props.onExiting(c),o.onTransitionEnd(a.exit,function(){o.safeSetState({status:ni},function(){o.props.onExited(c)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,a=!0;return this.nextCallback=function(c){a&&(a=!1,s.nextCallback=null,o(c))},this.nextCallback.cancel=function(){a=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var a=this.props.nodeRef?this.props.nodeRef.current:ji.findDOMNode(this),c=o==null&&!this.props.addEndListener;if(!a||c){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var u=this.props.nodeRef?[this.nextCallback]:[a,this.nextCallback],A=u[0],p=u[1];this.props.addEndListener(A,p)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===Aa)return null;var s=this.props,a=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var c=Ve(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return Q.createElement(cc.Provider,{value:null},typeof a=="function"?a(o,c):Q.cloneElement(Q.Children.only(a),c))},t}(Q.Component);Ur.contextType=cc,Ur.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:f.shape({current:typeof Element>"u"?f.any:function(e,t,n,r,o,s){var a=e[t];return f.instanceOf(a&&"ownerDocument"in a?a.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:f.oneOfType([f.func.isRequired,f.element.isRequired]).isRequired,in:f.bool,mountOnEnter:f.bool,unmountOnExit:f.bool,appear:f.bool,enter:f.bool,exit:f.bool,timeout:function(t){var n=bD;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;s<r;s++)o[s-1]=arguments[s];return n.apply(void 0,[t].concat(o))},addEndListener:f.func,onEnter:f.func,onEntering:f.func,onEntered:f.func,onExit:f.func,onExiting:f.func,onExited:f.func}:{};function $i(){}Ur.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:$i,onEntering:$i,onEntered:$i,onExit:$i,onExiting:$i,onExited:$i},Ur.UNMOUNTED=Aa,Ur.EXITED=ni,Ur.ENTERING=ri,Ur.ENTERED=qi,Ur.EXITING=rg;const og=Ur;function xD(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ig(e,t){var n=function(s){return t&&Q.isValidElement(s)?t(s):s},r=Object.create(null);return e&&Q.Children.map(e,function(o){return o}).forEach(function(o){r[o.key]=n(o)}),r}function wD(e,t){e=e||{},t=t||{};function n(p){return p in t?t[p]:e[p]}var r=Object.create(null),o=[];for(var s in e)s in t?o.length&&(r[s]=o,o=[]):o.push(s);var a,c={};for(var u in t){if(r[u])for(a=0;a<r[u].length;a++){var A=r[u][a];c[r[u][a]]=n(A)}c[u]=n(u)}for(a=0;a<o.length;a++)c[o[a]]=n(o[a]);return c}function oi(e,t,n){return n[t]!=null?n[t]:e.props[t]}function TD(e,t){return ig(e.children,function(n){return Q.cloneElement(n,{onExited:t.bind(null,n),in:!0,appear:oi(n,"appear",e),enter:oi(n,"enter",e),exit:oi(n,"exit",e)})})}function SD(e,t,n){var r=ig(e.children),o=wD(t,r);return Object.keys(o).forEach(function(s){var a=o[s];if(Q.isValidElement(a)){var c=s in t,u=s in r,A=t[s],p=Q.isValidElement(A)&&!A.props.in;u&&(!c||p)?o[s]=Q.cloneElement(a,{onExited:n.bind(null,a),in:!0,exit:oi(a,"exit",e),enter:oi(a,"enter",e)}):!u&&c&&!p?o[s]=Q.cloneElement(a,{in:!1}):u&&c&&Q.isValidElement(A)&&(o[s]=Q.cloneElement(a,{onExited:n.bind(null,a),in:A.props.in,exit:oi(a,"exit",e),enter:oi(a,"enter",e)}))}}),o}var PD=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},OD={component:"div",childFactory:function(t){return t}},sg=function(e){ng(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var a=s.handleExited.bind(xD(s));return s.state={contextValue:{isMounting:!0},handleExited:a,firstRender:!0},s}var n=t.prototype;return n.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},n.componentWillUnmount=function(){this.mounted=!1},t.getDerivedStateFromProps=function(o,s){var a=s.children,c=s.handleExited,u=s.firstRender;return{children:u?TD(o,c):SD(o,a,c),firstRender:!1}},n.handleExited=function(o,s){var a=ig(this.props.children);o.key in a||(o.props.onExited&&o.props.onExited(s),this.mounted&&this.setState(function(c){var u=W({},c.children);return delete u[o.key],{children:u}}))},n.render=function(){var o=this.props,s=o.component,a=o.childFactory,c=Ve(o,["component","childFactory"]),u=this.state.contextValue,A=PD(this.state.children).map(a);return delete c.appear,delete c.enter,delete c.exit,s===null?Q.createElement(cc.Provider,{value:u},A):Q.createElement(cc.Provider,{value:u},Q.createElement(s,c,A))},t}(Q.Component);sg.propTypes=process.env.NODE_ENV!=="production"?{component:f.any,children:f.node,appear:f.bool,enter:f.bool,exit:f.bool,childFactory:f.func}:{},sg.defaultProps=OD;const jD=sg;function pm(e){const{className:t,classes:n,pulsate:r=!1,rippleX:o,rippleY:s,rippleSize:a,in:c,onExited:u,timeout:A}=e,[p,h]=R.useState(!1),C=Ue(t,n.ripple,n.rippleVisible,r&&n.ripplePulsate),E={width:a,height:a,top:-(a/2)+s,left:-(a/2)+o},m=Ue(n.child,p&&n.childLeaving,r&&n.childPulsate);return!c&&!p&&h(!0),R.useEffect(()=>{if(!c&&u!=null){const B=setTimeout(u,A);return()=>{clearTimeout(B)}}},[u,c,A]),g.jsx("span",{className:C,style:E,children:g.jsx("span",{className:m})})}process.env.NODE_ENV!=="production"&&(pm.propTypes={classes:f.object.isRequired,className:f.string,in:f.bool,onExited:f.func,pulsate:f.bool,rippleSize:f.number,rippleX:f.number,rippleY:f.number,timeout:f.number.isRequired});const Xn=Ft("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),DD=["center","classes","className"];let uc=e=>e,hm,Cm,Em,Im;const ag=550,MD=80,kD=Gt.keyframes(hm||(hm=uc`
100
+ `+(c!==a?`result of cast: ${c}`:""))}return s}_cast(t,n){let r=t===void 0?t:this.transforms.reduce((o,s)=>s.call(this,o,t,this),t);return r===void 0&&(r=this.getDefault(n)),r}_validate(t,n={},r,o){let{path:s,originalValue:a=t,strict:c=this.spec.strict}=n,u=t;c||(u=this._cast(u,Object.assign({assert:!1},n)));let A=[];for(let p of Object.values(this.internalTests))p&&A.push(p);this.runTests({path:s,value:u,originalValue:a,options:n,tests:A},r,p=>{if(p.length)return o(p,u);this.runTests({path:s,value:u,originalValue:a,options:n,tests:this.tests},r,o)})}runTests(t,n,r){let o=!1,{tests:s,value:a,originalValue:c,path:u,options:A}=t,p=B=>{o||(o=!0,n(B,a))},h=B=>{o||(o=!0,r(B,a))},C=s.length,E=[];if(!C)return h([]);let m={value:a,originalValue:c,path:u,options:A,schema:this};for(let B=0;B<s.length;B++){const v=s[B];v(m,p,function(M){M&&(Array.isArray(M)?E.push(...M):E.push(M)),--C<=0&&h(E)})}}asNestedTest({key:t,index:n,parent:r,parentPath:o,originalParent:s,options:a}){const c=t??n;if(c==null)throw TypeError("Must include `key` or `index` for nested validations");const u=typeof c=="number";let A=r[c];const p=Object.assign({},a,{strict:!0,parent:r,value:A,originalValue:s[c],key:void 0,[u?"index":"key"]:c,path:u||c.includes(".")?`${o||""}[${u?c:`"${c}"`}]`:(o?`${o}.`:"")+t});return(h,C,E)=>this.resolve(p)._validate(A,p,C,E)}validate(t,n){var r;let o=this.resolve(Object.assign({},n,{value:t})),s=(r=n==null?void 0:n.disableStackTrace)!=null?r:o.spec.disableStackTrace;return new Promise((a,c)=>o._validate(t,n,(u,A)=>{gn.isError(u)&&(u.value=A),c(u)},(u,A)=>{u.length?c(new gn(u,A,void 0,void 0,s)):a(A)}))}validateSync(t,n){var r;let o=this.resolve(Object.assign({},n,{value:t})),s,a=(r=n==null?void 0:n.disableStackTrace)!=null?r:o.spec.disableStackTrace;return o._validate(t,Object.assign({},n,{sync:!0}),(c,u)=>{throw gn.isError(c)&&(c.value=u),c},(c,u)=>{if(c.length)throw new gn(c,t,void 0,void 0,a);s=u}),s}isValid(t,n){return this.validate(t,n).then(()=>!0,r=>{if(gn.isError(r))return!1;throw r})}isValidSync(t,n){try{return this.validateSync(t,n),!0}catch(r){if(gn.isError(r))return!1;throw r}}_getDefault(t){let n=this.spec.default;return n==null?n:typeof n=="function"?n.call(this,t):Yi(n)}getDefault(t){return this.resolve(t||{})._getDefault(t)}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){return this.clone({strict:t})}nullability(t,n){const r=this.clone({nullable:t});return r.internalTests.nullable=Ui({message:n,name:"nullable",test(o){return o===null?this.schema.spec.nullable:!0}}),r}optionality(t,n){const r=this.clone({optional:t});return r.internalTests.optionality=Ui({message:n,name:"optionality",test(o){return o===void 0?this.schema.spec.optional:!0}}),r}optional(){return this.optionality(!0)}defined(t=br.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=br.notNull){return this.nullability(!1,t)}required(t=br.required){return this.clone().withMutation(n=>n.nonNullable(t).defined(t))}notRequired(){return this.clone().withMutation(t=>t.nullable().optional())}transform(t){let n=this.clone();return n.transforms.push(t),n}test(...t){let n;if(t.length===1?typeof t[0]=="function"?n={test:t[0]}:n=t[0]:t.length===2?n={name:t[0],test:t[1]}:n={name:t[0],message:t[1],test:t[2]},n.message===void 0&&(n.message=br.default),typeof n.test!="function")throw new TypeError("`test` is a required parameters");let r=this.clone(),o=Ui(n),s=n.exclusive||n.name&&r.exclusiveTests[n.name]===!0;if(n.exclusive&&!n.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return n.name&&(r.exclusiveTests[n.name]=!!n.exclusive),r.tests=r.tests.filter(a=>!(a.OPTIONS.name===n.name&&(s||a.OPTIONS.test===o.OPTIONS.test))),r.tests.push(o),r}when(t,n){!Array.isArray(t)&&typeof t!="string"&&(n=t,t=".");let r=this.clone(),o=fC(t).map(s=>new Xo(s));return o.forEach(s=>{s.isSibling&&r.deps.push(s.key)}),r.conditions.push(typeof n=="function"?new Dl(o,n):Dl.fromOptions(o,n)),r}typeError(t){let n=this.clone();return n.internalTests.typeError=Ui({message:t,name:"typeError",skipAbsent:!0,test(r){return this.schema._typeCheck(r)?!0:this.createError({params:{type:this.schema.type}})}}),n}oneOf(t,n=br.oneOf){let r=this.clone();return t.forEach(o=>{r._whitelist.add(o),r._blacklist.delete(o)}),r.internalTests.whiteList=Ui({message:n,name:"oneOf",skipAbsent:!0,test(o){let s=this.schema._whitelist,a=s.resolveAll(this.resolve);return a.includes(o)?!0:this.createError({params:{values:Array.from(s).join(", "),resolved:a}})}}),r}notOneOf(t,n=br.notOneOf){let r=this.clone();return t.forEach(o=>{r._blacklist.add(o),r._whitelist.delete(o)}),r.internalTests.blacklist=Ui({message:n,name:"notOneOf",test(o){let s=this.schema._blacklist,a=s.resolveAll(this.resolve);return a.includes(o)?this.createError({params:{values:Array.from(s).join(", "),resolved:a}}):!0}}),r}strip(t=!0){let n=this.clone();return n.spec.strip=t,n}describe(t){const n=(t?this.resolve(t):this).clone(),{label:r,meta:o,optional:s,nullable:a}=n.spec;return{meta:o,label:r,optional:s,nullable:a,default:n.getDefault(t),type:n.type,oneOf:n._whitelist.describe(),notOneOf:n._blacklist.describe(),tests:n.tests.map(u=>({name:u.OPTIONS.name,params:u.OPTIONS.params})).filter((u,A,p)=>p.findIndex(h=>h.name===u.name)===A)}}}Yn.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])Yn.prototype[`${e}At`]=function(t,n,r={}){const{parent:o,parentPath:s,schema:a}=BS(this,t,n,r.context);return a[e](o&&o[s],Object.assign({},r,{parent:o,path:t}))};for(const e of["equals","is"])Yn.prototype[e]=Yn.prototype.oneOf;for(const e of["not","nope"])Yn.prototype[e]=Yn.prototype.notOneOf;const vS=()=>!0;function IC(e){return new mC(e)}class mC extends Yn{constructor(t){super(typeof t=="function"?{type:"mixed",check:t}:Object.assign({type:"mixed",check:vS},t))}}IC.prototype=mC.prototype;const yS=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function bS(e){const t=od(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(t.z===void 0&&t.plusMinus===void 0)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let n=0;return t.z!=="Z"&&t.plusMinus!==void 0&&(n=t.hourOffset*60+t.minuteOffset,t.plusMinus==="+"&&(n=0-n)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+n,t.second,t.millisecond)}function od(e){var t,n;const r=yS.exec(e);return r?{year:Lr(r[1]),month:Lr(r[2],1)-1,day:Lr(r[3],1),hour:Lr(r[4]),minute:Lr(r[5]),second:Lr(r[6]),millisecond:r[7]?Lr(r[7].substring(0,3)):0,precision:(t=(n=r[7])==null?void 0:n.length)!=null?t:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:Lr(r[10]),minuteOffset:Lr(r[11])}:null}function Lr(e,t=0){return Number(e)||t}let QS=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,xS=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,wS=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,TS="^\\d{4}-\\d{2}-\\d{2}",SS="\\d{2}:\\d{2}:\\d{2}",PS="(([+-]\\d{2}(:?\\d{2})?)|Z)",OS=new RegExp(`${TS}T${SS}(\\.\\d+)?${PS}$`),jS=e=>Fr(e)||e===e.trim(),DS={}.toString();function Nr(){return new BC}class BC extends Yn{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,n,r)=>{if(!r.spec.coerce||r.isType(t)||Array.isArray(t))return t;const o=t!=null&&t.toString?t.toString():t;return o===DS?t:o})})}required(t){return super.required(t).withMutation(n=>n.test({message:t||br.required,name:"required",skipAbsent:!0,test:r=>!!r.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(n=>n.OPTIONS.name!=="required"),t))}length(t,n=fn.length){return this.test({message:n,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(r){return r.length===this.resolve(t)}})}min(t,n=fn.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(r){return r.length>=this.resolve(t)}})}max(t,n=fn.max){return this.test({name:"max",exclusive:!0,message:n,params:{max:t},skipAbsent:!0,test(r){return r.length<=this.resolve(t)}})}matches(t,n){let r=!1,o,s;return n&&(typeof n=="object"?{excludeEmptyString:r=!1,message:o,name:s}=n:o=n),this.test({name:s||"matches",message:o||fn.matches,params:{regex:t},skipAbsent:!0,test:a=>a===""&&r||a.search(t)!==-1})}email(t=fn.email){return this.matches(QS,{name:"email",message:t,excludeEmptyString:!0})}url(t=fn.url){return this.matches(xS,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=fn.uuid){return this.matches(wS,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let n="",r,o;return t&&(typeof t=="object"?{message:n="",allowOffset:r=!1,precision:o=void 0}=t:n=t),this.matches(OS,{name:"datetime",message:n||fn.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:n||fn.datetime_offset,params:{allowOffset:r},skipAbsent:!0,test:s=>{if(!s||r)return!0;const a=od(s);return a?!!a.z:!1}}).test({name:"datetime_precision",message:n||fn.datetime_precision,params:{precision:o},skipAbsent:!0,test:s=>{if(!s||o==null)return!0;const a=od(s);return a?a.precision===o:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=fn.trim){return this.transform(n=>n!=null?n.trim():n).test({message:t,name:"trim",test:jS})}lowercase(t=fn.lowercase){return this.transform(n=>Fr(n)?n:n.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Fr(n)||n===n.toLowerCase()})}uppercase(t=fn.uppercase){return this.transform(n=>Fr(n)?n:n.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Fr(n)||n===n.toUpperCase()})}}Nr.prototype=BC.prototype;let MS=e=>e!=+e;function vC(){return new yC}class yC extends Yn{constructor(){super({type:"number",check(t){return t instanceof Number&&(t=t.valueOf()),typeof t=="number"&&!MS(t)}}),this.withMutation(()=>{this.transform((t,n,r)=>{if(!r.spec.coerce)return t;let o=t;if(typeof o=="string"){if(o=o.replace(/\s/g,""),o==="")return NaN;o=+o}return r.isType(o)||o===null?o:parseFloat(o)})})}min(t,n=uo.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(r){return r>=this.resolve(t)}})}max(t,n=uo.max){return this.test({message:n,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(r){return r<=this.resolve(t)}})}lessThan(t,n=uo.lessThan){return this.test({message:n,name:"max",exclusive:!0,params:{less:t},skipAbsent:!0,test(r){return r<this.resolve(t)}})}moreThan(t,n=uo.moreThan){return this.test({message:n,name:"min",exclusive:!0,params:{more:t},skipAbsent:!0,test(r){return r>this.resolve(t)}})}positive(t=uo.positive){return this.moreThan(0,t)}negative(t=uo.negative){return this.lessThan(0,t)}integer(t=uo.integer){return this.test({name:"integer",message:t,skipAbsent:!0,test:n=>Number.isInteger(n)})}truncate(){return this.transform(t=>Fr(t)?t:t|0)}round(t){var n;let r=["ceil","floor","round","trunc"];if(t=((n=t)==null?void 0:n.toLowerCase())||"round",t==="trunc")return this.truncate();if(r.indexOf(t.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+r.join(", "));return this.transform(o=>Fr(o)?o:Math[t](o))}}vC.prototype=yC.prototype;let kS=new Date(""),RS=e=>Object.prototype.toString.call(e)==="[object Date]";class Rl extends Yn{constructor(){super({type:"date",check(t){return RS(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,n,r)=>!r.spec.coerce||r.isType(t)||t===null?t:(t=bS(t),isNaN(t)?Rl.INVALID_DATE:new Date(t)))})}prepareParam(t,n){let r;if(Xo.isRef(t))r=t;else{let o=this.cast(t);if(!this._typeCheck(o))throw new TypeError(`\`${n}\` must be a Date or a value that can be \`cast()\` to a Date`);r=o}return r}min(t,n=td.min){let r=this.prepareParam(t,"min");return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(o){return o>=this.resolve(r)}})}max(t,n=td.max){let r=this.prepareParam(t,"max");return this.test({message:n,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(o){return o<=this.resolve(r)}})}}Rl.INVALID_DATE=kS,Rl.prototype;function FS(e,t=[]){let n=[],r=new Set,o=new Set(t.map(([a,c])=>`${a}-${c}`));function s(a,c){let u=Jo.split(a)[0];r.add(u),o.has(`${c}-${u}`)||n.push([c,u])}for(const a of Object.keys(e)){let c=e[a];r.add(a),Xo.isRef(c)&&c.isSibling?s(c.path,a):rd(c)&&"deps"in c&&c.deps.forEach(u=>s(u,a))}return dS.array(Array.from(r),n).reverse()}function bC(e,t){let n=1/0;return e.some((r,o)=>{var s;if((s=t.path)!=null&&s.includes(r))return n=o,!0}),n}function QC(e){return(t,n)=>bC(e,t)-bC(e,n)}const LS=(e,t,n)=>{if(typeof e!="string")return e;let r=e;try{r=JSON.parse(e)}catch{}return n.isType(r)?r:e};function Fl(e){if("fields"in e){const t={};for(const[n,r]of Object.entries(e.fields))t[n]=Fl(r);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=Fl(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(Fl)}):"optional"in e?e.optional():e}const NS=(e,t)=>{const n=[...Jo.normalizePath(t)];if(n.length===1)return n[0]in e;let r=n.pop(),o=Jo.getter(Jo.join(n),!0)(e);return!!(o&&r in o)};let xC=e=>Object.prototype.toString.call(e)==="[object Object]";function VS(e,t){let n=Object.keys(e.fields);return Object.keys(t).filter(r=>n.indexOf(r)===-1)}const HS=QC([]);function id(e){return new wC(e)}class wC extends Yn{constructor(t){super({type:"object",check(n){return xC(n)||typeof n=="function"}}),this.fields=Object.create(null),this._sortErrors=HS,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,n={}){var r;let o=super._cast(t,n);if(o===void 0)return this.getDefault(n);if(!this._typeCheck(o))return o;let s=this.fields,a=(r=n.stripUnknown)!=null?r:this.spec.noUnknown,c=[].concat(this._nodes,Object.keys(o).filter(h=>!this._nodes.includes(h))),u={},A=Object.assign({},n,{parent:u,__validating:n.__validating||!1}),p=!1;for(const h of c){let C=s[h],E=h in o;if(C){let m,B=o[h];A.path=(n.path?`${n.path}.`:"")+h,C=C.resolve({value:B,context:n.context,parent:u});let v=C instanceof Yn?C.spec:void 0,S=v==null?void 0:v.strict;if(v!=null&&v.strip){p=p||h in o;continue}m=!n.__validating||!S?C.cast(o[h],A):o[h],m!==void 0&&(u[h]=m)}else E&&!a&&(u[h]=o[h]);(E!==h in u||u[h]!==o[h])&&(p=!0)}return p?u:o}_validate(t,n={},r,o){let{from:s=[],originalValue:a=t,recursive:c=this.spec.recursive}=n;n.from=[{schema:this,value:a},...s],n.__validating=!0,n.originalValue=a,super._validate(t,n,r,(u,A)=>{if(!c||!xC(A)){o(u,A);return}a=a||A;let p=[];for(let h of this._nodes){let C=this.fields[h];!C||Xo.isRef(C)||p.push(C.asNestedTest({options:n,key:h,parent:A,parentPath:n.path,originalParent:a}))}this.runTests({tests:p,value:A,originalValue:a,options:n},r,h=>{o(h.sort(this._sortErrors).concat(u),A)})})}clone(t){const n=super.clone(t);return n.fields=Object.assign({},this.fields),n._nodes=this._nodes,n._excludedEdges=this._excludedEdges,n._sortErrors=this._sortErrors,n}concat(t){let n=super.concat(t),r=n.fields;for(let[o,s]of Object.entries(this.fields)){const a=r[o];r[o]=a===void 0?s:a}return n.withMutation(o=>o.setFields(r,[...this._excludedEdges,...t._excludedEdges]))}_getDefault(t){if("default"in this.spec)return super._getDefault(t);if(!this._nodes.length)return;let n={};return this._nodes.forEach(r=>{var o;const s=this.fields[r];let a=t;(o=a)!=null&&o.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[r]})),n[r]=s&&"getDefault"in s?s.getDefault(a):void 0}),n}setFields(t,n){let r=this.clone();return r.fields=t,r._nodes=FS(t,n),r._sortErrors=QC(Object.keys(t)),n&&(r._excludedEdges=n),r}shape(t,n=[]){return this.clone().withMutation(r=>{let o=r._excludedEdges;return n.length&&(Array.isArray(n[0])||(n=[n]),o=[...r._excludedEdges,...n]),r.setFields(Object.assign(r.fields,t),o)})}partial(){const t={};for(const[n,r]of Object.entries(this.fields))t[n]="optional"in r&&r.optional instanceof Function?r.optional():r;return this.setFields(t)}deepPartial(){return Fl(this)}pick(t){const n={};for(const r of t)this.fields[r]&&(n[r]=this.fields[r]);return this.setFields(n,this._excludedEdges.filter(([r,o])=>t.includes(r)&&t.includes(o)))}omit(t){const n=[];for(const r of Object.keys(this.fields))t.includes(r)||n.push(r);return this.pick(n)}from(t,n,r){let o=Jo.getter(t,!0);return this.transform(s=>{if(!s)return s;let a=s;return NS(s,t)&&(a=Object.assign({},s),r||delete a[t],a[n]=o(s)),a})}json(){return this.transform(LS)}noUnknown(t=!0,n=nd.noUnknown){typeof t!="boolean"&&(n=t,t=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:n,test(o){if(o==null)return!0;const s=VS(this.schema,o);return!t||s.length===0||this.createError({params:{unknown:s.join(", ")}})}});return r.spec.noUnknown=t,r}unknown(t=!0,n=nd.noUnknown){return this.noUnknown(!t,n)}transformKeys(t){return this.transform(n=>{if(!n)return n;const r={};for(const o of Object.keys(n))r[t(o)]=n[o];return r})}camelCase(){return this.transformKeys($A.camelCase)}snakeCase(){return this.transformKeys($A.snakeCase)}constantCase(){return this.transformKeys(t=>$A.snakeCase(t).toUpperCase())}describe(t){const n=(t?this.resolve(t):this).clone(),r=super.describe(t);r.fields={};for(const[s,a]of Object.entries(n.fields)){var o;let c=t;(o=c)!=null&&o.value&&(c=Object.assign({},c,{parent:c.value,value:c.value[s]})),r.fields[s]=a.describe(c)}return r}}id.prototype=wC.prototype;const TC=IC().test("function","Invalid function",e=>ne.isFunction(e));class SC{constructor(){io(this,pi);io(this,Po,[])}get(t){if(Nr().required().validateSync(t),il(this,pi,sl).call(this)){const n=localStorage.getItem(t);return ne.isNil(n)?null:JSON.parse(n)}else return null}set(t,n){return Nr().required().validateSync(t),il(this,pi,sl).call(this)?(localStorage.setItem(t,JSON.stringify(n)),n):null}watch(t,n){Nr().required().validateSync(t),TC.validateSync(n),il(this,pi,sl).call(this)&&(xn(this,Po).push({key:t,callback:n}),window.addEventListener("storage",r=>{r.storageArea===localStorage&&r.key===t&&n(this.get(t))}))}unwatch(t,n){Nr().required().validateSync(t),TC.optional().default(ne.identity).validateSync(n),il(this,pi,sl).call(this)&&(n!==void 0?Vo(this,Po,ne.reject(xn(this,Po),r=>r.key===t&&r.callback===n)):Vo(this,Po,ne.reject(xn(this,Po),r=>r.key===t)))}}Po=new WeakMap,pi=new WeakSet,sl=function(){return typeof window<"u"};function PC(e){const[t]=ue.useLocaleState();return e!==void 0?String(e):t}function zS(e,t){const n=PC(t==null?void 0:t.locale);return KA(e,n,t)}function WS(e){const t=PC(e==null?void 0:e.locale);return Q.useCallback(r=>KA(r,t,e),[t,e])}const Js=new SC;function US(e,t,n){return function(r){const o=ne.isFunction(r)?r(t):r;return Js.set(e,o),n(o),o}}function Ll(e,t){var u;Nr().required().validateSync(e);const[n,r]=Q.useState(Js.get(e)??t),o=Q.useRef(t),s=ne.isEqual(o.current,t)?o.current:t,a=Q.useRef(),c=a.current;return Q.useEffect(()=>{r(Js.get(e)??s)},[e,s,r]),Q.useEffect(()=>{function A(p){r(p)}return Js.watch(e,A),()=>{Js.unwatch(e,A)}},[e,r]),(e!==(c==null?void 0:c.key)||!ne.isEqual(n,c==null?void 0:c.value))&&(a.current={key:e,value:n,setter:US(e,n,r)}),[n,((u=a.current)==null?void 0:u.setter)??ne.noop]}function OC(e){if(!ne.isPlainObject(e))throw new Error("[useMemoizedObject]: param must be a plain JS object");const[t,n]=Q.useState(e);return Q.useEffect(()=>{ne.isEqual(e,t)||n(e)},[e,t]),t}function Nl(){const[e,t]=Q.useState(null),n=!!e,r=Q.useCallback(a=>t((a==null?void 0:a.currentTarget)??null),[t]),o=Q.useCallback(()=>t(null),[t]),s=Q.useCallback(a=>{n?o():r(a)},[n,r,o]);return{anchorEl:e,open:n,handleClick:r,handleClose:o,handleToggle:s}}function YS(e,t){const[n,r]=Q.useState({width:1,height:1}),o=e.current;return Q.useEffect(()=>{function s(){var A;let c=0,u=0;switch(t){case"client":c=(o==null?void 0:o.clientWidth)??0,u=(o==null?void 0:o.clientHeight)??0;break;case"offset":c=(o==null?void 0:o.offsetWidth)??0,u=(o==null?void 0:o.offsetHeight)??0;break;case"scroll":c=(o==null?void 0:o.scrollWidth)??0,u=(o==null?void 0:o.scrollHeight)??0;break;case"bounding":default:{const p=((A=e.current)==null?void 0:A.getBoundingClientRect())??{width:0,height:0};c=p.width,u=p.height;break}}r({width:c,height:u})}const a=new ResizeObserver(s);return ne.isEmpty(e==null?void 0:e.current)||(a.observe(e==null?void 0:e.current),s()),()=>{a.disconnect()}},[o,t]),n}function sd(e){const t=D.useRecordContext(),n=D.useTranslate(),r=D.useResourceContext(),o=t!=null&&t.id?"edit":"create";return Q.useMemo(()=>{if(e===!1)return;const a=`resources.${r}.title`;return e||n(`resources.${r}.title.${o}`,{_:n(a,{_:a}),...t})},[o,t,r,n,e])}function dr(e,t,n){const r=ne.chain((e==null?void 0:e.sx)??{}).cloneDeepWith(a=>ne.isFunction(a)?a:void 0).value();n!=null&&n.defaults?ne.defaultsDeep(r,t):ne.merge(r,t);const[o,s]=Q.useState(r);return Q.useEffect(()=>{ne.isEqual(o,r)||s(r)},[o,r]),o}const jC=()=>Q.useContext(zA),GS=()=>Q.useContext(WA),pn=()=>Q.useContext(VA),DC=Ae(UT,{shouldForwardProp:e=>e!=="open"})(({theme:e,open:t})=>{const{drawerWidth:n}=pn();return{zIndex:e.zIndex.drawer+1,transition:e.transitions.create(["width","margin"],{easing:e.transitions.easing.sharp,duration:e.transitions.duration.leavingScreen}),...!t&&{width:`calc(100% - ${e.spacing(7.5)})`},...t&&{marginLeft:n,width:`calc(100% - ${n}px)`,transition:e.transitions.create(["width","margin"],{easing:e.transitions.easing.sharp,duration:e.transitions.duration.enteringScreen})}}}),KS=Q.forwardRef(function(t,n){const r=dr(t,{color:"text.primary"},{defaults:!0});return g.jsx(b.Button,{ref:n,...t,color:"secondary",variant:"text",sx:r})}),MC=Q.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),Vl=Q.createContext({}),ad=Q.createContext(null),Hl=typeof document<"u",JS=Hl?Q.useLayoutEffect:Q.useEffect,kC=Q.createContext({strict:!1}),ld=e=>e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),RC="data-"+ld("framerAppearId");function XS(e,t,n,r){const{visualElement:o}=Q.useContext(Vl),s=Q.useContext(kC),a=Q.useContext(ad),c=Q.useContext(MC).reducedMotion,u=Q.useRef();r=r||s.renderer,!u.current&&r&&(u.current=r(e,{visualState:t,parent:o,props:n,presenceContext:a,blockInitialAnimation:a?a.initial===!1:!1,reducedMotionConfig:c}));const A=u.current;Q.useInsertionEffect(()=>{A&&A.update(n,a)});const p=Q.useRef(!!(n[RC]&&!window.HandoffComplete));return JS(()=>{A&&(A.render(),p.current&&A.animationState&&A.animationState.animateChanges())}),Q.useEffect(()=>{A&&(A.updateFeatures(),!p.current&&A.animationState&&A.animationState.animateChanges(),p.current&&(p.current=!1,window.HandoffComplete=!0))}),A}function Gi(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function ZS(e,t,n){return Q.useCallback(r=>{r&&e.mount&&e.mount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):Gi(n)&&(n.current=r))},[t])}function Xs(e){return typeof e=="string"||Array.isArray(e)}function zl(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}const cd=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],ud=["initial",...cd];function Wl(e){return zl(e.animate)||ud.some(t=>Xs(e[t]))}function FC(e){return!!(Wl(e)||e.variants)}function _S(e,t){if(Wl(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Xs(n)?n:void 0,animate:Xs(r)?r:void 0}}return e.inherit!==!1?t:{}}function qS(e){const{initial:t,animate:n}=_S(e,Q.useContext(Vl));return Q.useMemo(()=>({initial:t,animate:n}),[LC(t),LC(n)])}function LC(e){return Array.isArray(e)?e.join(" "):e}const NC={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Zs={};for(const e in NC)Zs[e]={isEnabled:t=>NC[e].some(n=>!!t[n])};function $S(e){for(const t in e)Zs[t]={...Zs[t],...e[t]}}const VC=Q.createContext({}),HC=Q.createContext({}),eP=Symbol.for("motionComponentSymbol");function tP({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:o}){e&&$S(e);function s(c,u){let A;const p={...Q.useContext(MC),...c,layoutId:nP(c)},{isStatic:h}=p,C=qS(c),E=r(c,h);if(!h&&Hl){C.visualElement=XS(o,E,p,t);const m=Q.useContext(HC),B=Q.useContext(kC).strict;C.visualElement&&(A=C.visualElement.loadFeatures(p,B,e,m))}return R.createElement(Vl.Provider,{value:C},A&&C.visualElement?R.createElement(A,{visualElement:C.visualElement,...p}):null,n(o,c,ZS(E,C.visualElement,u),E,h,C.visualElement))}const a=Q.forwardRef(s);return a[eP]=o,a}function nP({layoutId:e}){const t=Q.useContext(VC).id;return t&&e!==void 0?t+"-"+e:e}function rP(e){function t(r,o={}){return tP(e(r,o))}if(typeof Proxy>"u")return t;const n=new Map;return new Proxy(t,{get:(r,o)=>(n.has(o)||n.set(o,t(o)),n.get(o))})}const oP=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Ad(e){return typeof e!="string"||e.includes("-")?!1:!!(oP.indexOf(e)>-1||/[A-Z]/.test(e))}const Ul={};function iP(e){Object.assign(Ul,e)}const _s=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Zo=new Set(_s);function zC(e,{layout:t,layoutId:n}){return Zo.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Ul[e]||e==="opacity")}const hn=e=>!!(e&&e.getVelocity),sP={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},aP=_s.length;function lP(e,{enableHardwareAcceleration:t=!0,allowTransformNone:n=!0},r,o){let s="";for(let a=0;a<aP;a++){const c=_s[a];if(e[c]!==void 0){const u=sP[c]||c;s+=`${u}(${e[c]}) `}}return t&&!e.z&&(s+="translateZ(0)"),s=s.trim(),o?s=o(e,r?"":s):n&&r&&(s="none"),s}const WC=e=>t=>typeof t=="string"&&t.startsWith(e),UC=WC("--"),dd=WC("var(--"),cP=/var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g,uP=(e,t)=>t&&typeof e=="number"?t.transform(e):e,Ao=(e,t,n)=>Math.min(Math.max(n,e),t),_o={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},qs={..._o,transform:e=>Ao(0,1,e)},Yl={..._o,default:1},$s=e=>Math.round(e*1e5)/1e5,Gl=/(-)?([\d]*\.?[\d])+/g,YC=/(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi,AP=/^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;function ea(e){return typeof e=="string"}const ta=e=>({test:t=>ea(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),go=ta("deg"),Qr=ta("%"),ke=ta("px"),dP=ta("vh"),gP=ta("vw"),GC={...Qr,parse:e=>Qr.parse(e)/100,transform:e=>Qr.transform(e*100)},KC={..._o,transform:Math.round},JC={borderWidth:ke,borderTopWidth:ke,borderRightWidth:ke,borderBottomWidth:ke,borderLeftWidth:ke,borderRadius:ke,radius:ke,borderTopLeftRadius:ke,borderTopRightRadius:ke,borderBottomRightRadius:ke,borderBottomLeftRadius:ke,width:ke,maxWidth:ke,height:ke,maxHeight:ke,size:ke,top:ke,right:ke,bottom:ke,left:ke,padding:ke,paddingTop:ke,paddingRight:ke,paddingBottom:ke,paddingLeft:ke,margin:ke,marginTop:ke,marginRight:ke,marginBottom:ke,marginLeft:ke,rotate:go,rotateX:go,rotateY:go,rotateZ:go,scale:Yl,scaleX:Yl,scaleY:Yl,scaleZ:Yl,skew:go,skewX:go,skewY:go,distance:ke,translateX:ke,translateY:ke,translateZ:ke,x:ke,y:ke,z:ke,perspective:ke,transformPerspective:ke,opacity:qs,originX:GC,originY:GC,originZ:ke,zIndex:KC,fillOpacity:qs,strokeOpacity:qs,numOctaves:KC};function gd(e,t,n,r){const{style:o,vars:s,transform:a,transformOrigin:c}=e;let u=!1,A=!1,p=!0;for(const h in t){const C=t[h];if(UC(h)){s[h]=C;continue}const E=JC[h],m=uP(C,E);if(Zo.has(h)){if(u=!0,a[h]=m,!p)continue;C!==(E.default||0)&&(p=!1)}else h.startsWith("origin")?(A=!0,c[h]=m):o[h]=m}if(t.transform||(u||r?o.transform=lP(e.transform,n,p,r):o.transform&&(o.transform="none")),A){const{originX:h="50%",originY:C="50%",originZ:E=0}=c;o.transformOrigin=`${h} ${C} ${E}`}}const fd=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function XC(e,t,n){for(const r in t)!hn(t[r])&&!zC(r,n)&&(e[r]=t[r])}function fP({transformTemplate:e},t,n){return Q.useMemo(()=>{const r=fd();return gd(r,t,{enableHardwareAcceleration:!n},e),Object.assign({},r.vars,r.style)},[t])}function pP(e,t,n){const r=e.style||{},o={};return XC(o,r,e),Object.assign(o,fP(e,t,n)),e.transformValues?e.transformValues(o):o}function hP(e,t,n){const r={},o=pP(e,t,n);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=o,r}const CP=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","transformValues","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Kl(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||CP.has(e)}let ZC=e=>!Kl(e);function EP(e){e&&(ZC=t=>t.startsWith("on")?!Kl(t):e(t))}try{EP(require("@emotion/is-prop-valid").default)}catch{}function IP(e,t,n){const r={};for(const o in e)o==="values"&&typeof e.values=="object"||(ZC(o)||n===!0&&Kl(o)||!t&&!Kl(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}function _C(e,t,n){return typeof e=="string"?e:ke.transform(t+n*e)}function mP(e,t,n){const r=_C(t,e.x,e.width),o=_C(n,e.y,e.height);return`${r} ${o}`}const BP={offset:"stroke-dashoffset",array:"stroke-dasharray"},vP={offset:"strokeDashoffset",array:"strokeDasharray"};function yP(e,t,n=1,r=0,o=!0){e.pathLength=1;const s=o?BP:vP;e[s.offset]=ke.transform(-r);const a=ke.transform(t),c=ke.transform(n);e[s.array]=`${a} ${c}`}function pd(e,{attrX:t,attrY:n,attrScale:r,originX:o,originY:s,pathLength:a,pathSpacing:c=1,pathOffset:u=0,...A},p,h,C){if(gd(e,A,p,C),h){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:E,style:m,dimensions:B}=e;E.transform&&(B&&(m.transform=E.transform),delete E.transform),B&&(o!==void 0||s!==void 0||m.transform)&&(m.transformOrigin=mP(B,o!==void 0?o:.5,s!==void 0?s:.5)),t!==void 0&&(E.x=t),n!==void 0&&(E.y=n),r!==void 0&&(E.scale=r),a!==void 0&&yP(E,a,c,u,!1)}const qC=()=>({...fd(),attrs:{}}),hd=e=>typeof e=="string"&&e.toLowerCase()==="svg";function bP(e,t,n,r){const o=Q.useMemo(()=>{const s=qC();return pd(s,t,{enableHardwareAcceleration:!1},hd(r),e.transformTemplate),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};XC(s,e.style,e),o.style={...s,...o.style}}return o}function QP(e=!1){return(n,r,o,{latestValues:s},a)=>{const u=(Ad(n)?bP:hP)(r,s,a,n),p={...IP(r,typeof n=="string",e),...u,ref:o},{children:h}=r,C=Q.useMemo(()=>hn(h)?h.get():h,[h]);return Q.createElement(n,{...p,children:C})}}function $C(e,{style:t,vars:n},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(const s in n)e.style.setProperty(s,n[s])}const eE=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function tE(e,t,n,r){$C(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(eE.has(o)?o:ld(o),t.attrs[o])}function Cd(e,t){const{style:n}=e,r={};for(const o in n)(hn(n[o])||t.style&&hn(t.style[o])||zC(o,e))&&(r[o]=n[o]);return r}function nE(e,t){const n=Cd(e,t);for(const r in e)if(hn(e[r])||hn(t[r])){const o=_s.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;n[o]=e[r]}return n}function Ed(e,t,n,r={},o={}){return typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,o)),typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,o)),t}function xP(e){const t=Q.useRef(null);return t.current===null&&(t.current=e()),t.current}const Jl=e=>Array.isArray(e),wP=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),TP=e=>Jl(e)?e[e.length-1]||0:e;function Xl(e){const t=hn(e)?e.get():e;return wP(t)?t.toValue():t}function SP({scrapeMotionValuesFromProps:e,createRenderState:t,onMount:n},r,o,s){const a={latestValues:PP(r,o,s,e),renderState:t()};return n&&(a.mount=c=>n(r,c,a)),a}const rE=e=>(t,n)=>{const r=Q.useContext(Vl),o=Q.useContext(ad),s=()=>SP(e,t,r,o);return n?s():xP(s)};function PP(e,t,n,r){const o={},s=r(e,{});for(const C in s)o[C]=Xl(s[C]);let{initial:a,animate:c}=e;const u=Wl(e),A=FC(e);t&&A&&!u&&e.inherit!==!1&&(a===void 0&&(a=t.initial),c===void 0&&(c=t.animate));let p=n?n.initial===!1:!1;p=p||a===!1;const h=p?c:a;return h&&typeof h!="boolean"&&!zl(h)&&(Array.isArray(h)?h:[h]).forEach(E=>{const m=Ed(e,E);if(!m)return;const{transitionEnd:B,transition:v,...S}=m;for(const M in S){let x=S[M];if(Array.isArray(x)){const O=p?x.length-1:0;x=x[O]}x!==null&&(o[M]=x)}for(const M in B)o[M]=B[M]}),o}const Pt=e=>e;class oE{constructor(){this.order=[],this.scheduled=new Set}add(t){if(!this.scheduled.has(t))return this.scheduled.add(t),this.order.push(t),!0}remove(t){const n=this.order.indexOf(t);n!==-1&&(this.order.splice(n,1),this.scheduled.delete(t))}clear(){this.order.length=0,this.scheduled.clear()}}function OP(e){let t=new oE,n=new oE,r=0,o=!1,s=!1;const a=new WeakSet,c={schedule:(u,A=!1,p=!1)=>{const h=p&&o,C=h?t:n;return A&&a.add(u),C.add(u)&&h&&o&&(r=t.order.length),u},cancel:u=>{n.remove(u),a.delete(u)},process:u=>{if(o){s=!0;return}if(o=!0,[t,n]=[n,t],n.clear(),r=t.order.length,r)for(let A=0;A<r;A++){const p=t.order[A];p(u),a.has(p)&&(c.schedule(p),e())}o=!1,s&&(s=!1,c.process(u))}};return c}const Zl=["prepare","read","update","preRender","render","postRender"],jP=40;function DP(e,t){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},s=Zl.reduce((h,C)=>(h[C]=OP(()=>n=!0),h),{}),a=h=>s[h].process(o),c=()=>{const h=performance.now();n=!1,o.delta=r?1e3/60:Math.max(Math.min(h-o.timestamp,jP),1),o.timestamp=h,o.isProcessing=!0,Zl.forEach(a),o.isProcessing=!1,n&&t&&(r=!1,e(c))},u=()=>{n=!0,r=!0,o.isProcessing||e(c)};return{schedule:Zl.reduce((h,C)=>{const E=s[C];return h[C]=(m,B=!1,v=!1)=>(n||u(),E.schedule(m,B,v)),h},{}),cancel:h=>Zl.forEach(C=>s[C].cancel(h)),state:o,steps:s}}const{schedule:ht,cancel:Vr,state:$t,steps:Id}=DP(typeof requestAnimationFrame<"u"?requestAnimationFrame:Pt,!0),MP={useVisualState:rE({scrapeMotionValuesFromProps:nE,createRenderState:qC,onMount:(e,t,{renderState:n,latestValues:r})=>{ht.read(()=>{try{n.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),ht.render(()=>{pd(n,r,{enableHardwareAcceleration:!1},hd(t.tagName),e.transformTemplate),tE(t,n)})}})},kP={useVisualState:rE({scrapeMotionValuesFromProps:Cd,createRenderState:fd})};function RP(e,{forwardMotionProps:t=!1},n,r){return{...Ad(e)?MP:kP,preloadedFeatures:n,useRender:QP(t),createVisualElement:r,Component:e}}function Hr(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const iE=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function _l(e,t="page"){return{point:{x:e[t+"X"],y:e[t+"Y"]}}}const FP=e=>t=>iE(t)&&e(t,_l(t));function zr(e,t,n,r){return Hr(e,t,FP(n),r)}const LP=(e,t)=>n=>t(e(n)),fo=(...e)=>e.reduce(LP);function sE(e){let t=null;return()=>{const n=()=>{t=null};return t===null?(t=e,n):!1}}const aE=sE("dragHorizontal"),lE=sE("dragVertical");function cE(e){let t=!1;if(e==="y")t=lE();else if(e==="x")t=aE();else{const n=aE(),r=lE();n&&r?t=()=>{n(),r()}:(n&&n(),r&&r())}return t}function uE(){const e=cE(!0);return e?(e(),!1):!0}class po{constructor(t){this.isMounted=!1,this.node=t}update(){}}function AE(e,t){const n="pointer"+(t?"enter":"leave"),r="onHover"+(t?"Start":"End"),o=(s,a)=>{if(s.pointerType==="touch"||uE())return;const c=e.getProps();e.animationState&&c.whileHover&&e.animationState.setActive("whileHover",t),c[r]&&ht.update(()=>c[r](s,a))};return zr(e.current,n,o,{passive:!e.getProps()[r]})}class NP extends po{mount(){this.unmount=fo(AE(this.node,!0),AE(this.node,!1))}unmount(){}}class VP extends po{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=fo(Hr(this.node.current,"focus",()=>this.onFocus()),Hr(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const dE=(e,t)=>t?e===t?!0:dE(e,t.parentElement):!1;function md(e,t){if(!t)return;const n=new PointerEvent("pointer"+e);t(n,_l(n))}class HP extends po{constructor(){super(...arguments),this.removeStartListeners=Pt,this.removeEndListeners=Pt,this.removeAccessibleListeners=Pt,this.startPointerPress=(t,n)=>{if(this.isPressing)return;this.removeEndListeners();const r=this.node.getProps(),s=zr(window,"pointerup",(c,u)=>{if(!this.checkPressEnd())return;const{onTap:A,onTapCancel:p,globalTapTarget:h}=this.node.getProps();ht.update(()=>{!h&&!dE(this.node.current,c.target)?p&&p(c,u):A&&A(c,u)})},{passive:!(r.onTap||r.onPointerUp)}),a=zr(window,"pointercancel",(c,u)=>this.cancelPress(c,u),{passive:!(r.onTapCancel||r.onPointerCancel)});this.removeEndListeners=fo(s,a),this.startPress(t,n)},this.startAccessiblePress=()=>{const t=s=>{if(s.key!=="Enter"||this.isPressing)return;const a=c=>{c.key!=="Enter"||!this.checkPressEnd()||md("up",(u,A)=>{const{onTap:p}=this.node.getProps();p&&ht.update(()=>p(u,A))})};this.removeEndListeners(),this.removeEndListeners=Hr(this.node.current,"keyup",a),md("down",(c,u)=>{this.startPress(c,u)})},n=Hr(this.node.current,"keydown",t),r=()=>{this.isPressing&&md("cancel",(s,a)=>this.cancelPress(s,a))},o=Hr(this.node.current,"blur",r);this.removeAccessibleListeners=fo(n,o)}}startPress(t,n){this.isPressing=!0;const{onTapStart:r,whileTap:o}=this.node.getProps();o&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),r&&ht.update(()=>r(t,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!uE()}cancelPress(t,n){if(!this.checkPressEnd())return;const{onTapCancel:r}=this.node.getProps();r&&ht.update(()=>r(t,n))}mount(){const t=this.node.getProps(),n=zr(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),r=Hr(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=fo(n,r)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const Bd=new WeakMap,vd=new WeakMap,zP=e=>{const t=Bd.get(e.target);t&&t(e)},WP=e=>{e.forEach(zP)};function UP({root:e,...t}){const n=e||document;vd.has(n)||vd.set(n,{});const r=vd.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(WP,{root:e,...t})),r[o]}function YP(e,t,n){const r=UP(t);return Bd.set(e,n),r.observe(e),()=>{Bd.delete(e),r.unobserve(e)}}const GP={some:0,all:1};class KP extends po{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:o="some",once:s}=t,a={root:n?n.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:GP[o]},c=u=>{const{isIntersecting:A}=u;if(this.isInView===A||(this.isInView=A,s&&!A&&this.hasEnteredView))return;A&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",A);const{onViewportEnter:p,onViewportLeave:h}=this.node.getProps(),C=A?p:h;C&&C(u)};return YP(this.node.current,a,c)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(JP(t,n))&&this.startObserver()}unmount(){}}function JP({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const XP={inView:{Feature:KP},tap:{Feature:HP},focus:{Feature:VP},hover:{Feature:NP}};function gE(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}function ZP(e){const t={};return e.values.forEach((n,r)=>t[r]=n.get()),t}function _P(e){const t={};return e.values.forEach((n,r)=>t[r]=n.getVelocity()),t}function ql(e,t,n){const r=e.getProps();return Ed(r,t,n!==void 0?n:r.custom,ZP(e),_P(e))}let na=Pt,gr=Pt;process.env.NODE_ENV!=="production"&&(na=(e,t)=>{!e&&typeof console<"u"&&console.warn(t)},gr=(e,t)=>{if(!e)throw new Error(t)});const ho=e=>e*1e3,Wr=e=>e/1e3,qP={current:!1},fE=e=>Array.isArray(e)&&typeof e[0]=="number";function pE(e){return!!(!e||typeof e=="string"&&hE[e]||fE(e)||Array.isArray(e)&&e.every(pE))}const ra=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,hE={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:ra([0,.65,.55,1]),circOut:ra([.55,0,1,.45]),backIn:ra([.31,.01,.66,-.59]),backOut:ra([.33,1.53,.69,.99])};function CE(e){if(e)return fE(e)?ra(e):Array.isArray(e)?e.map(CE):hE[e]}function $P(e,t,n,{delay:r=0,duration:o,repeat:s=0,repeatType:a="loop",ease:c,times:u}={}){const A={[t]:n};u&&(A.offset=u);const p=CE(c);return Array.isArray(p)&&(A.easing=p),e.animate(A,{delay:r,duration:o,easing:Array.isArray(p)?"linear":p,fill:"both",iterations:s+1,direction:a==="reverse"?"alternate":"normal"})}function eO(e,{repeat:t,repeatType:n="loop"}){const r=t&&n!=="loop"&&t%2===1?0:e.length-1;return e[r]}const EE=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,tO=1e-7,nO=12;function rO(e,t,n,r,o){let s,a,c=0;do a=t+(n-t)/2,s=EE(a,r,o)-e,s>0?n=a:t=a;while(Math.abs(s)>tO&&++c<nO);return a}function oa(e,t,n,r){if(e===t&&n===r)return Pt;const o=s=>rO(s,0,1,e,n);return s=>s===0||s===1?s:EE(o(s),t,r)}const oO=oa(.42,0,1,1),iO=oa(0,0,.58,1),IE=oa(.42,0,.58,1),sO=e=>Array.isArray(e)&&typeof e[0]!="number",mE=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,BE=e=>t=>1-e(1-t),yd=e=>1-Math.sin(Math.acos(e)),vE=BE(yd),aO=mE(yd),yE=oa(.33,1.53,.69,.99),bd=BE(yE),lO=mE(bd),bE={linear:Pt,easeIn:oO,easeInOut:IE,easeOut:iO,circIn:yd,circInOut:aO,circOut:vE,backIn:bd,backInOut:lO,backOut:yE,anticipate:e=>(e*=2)<1?.5*bd(e):.5*(2-Math.pow(2,-10*(e-1)))},QE=e=>{if(Array.isArray(e)){gr(e.length===4,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,o]=e;return oa(t,n,r,o)}else if(typeof e=="string")return gr(bE[e]!==void 0,`Invalid easing type '${e}'`),bE[e];return e},Qd=(e,t)=>n=>!!(ea(n)&&AP.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)),xE=(e,t,n)=>r=>{if(!ea(r))return r;const[o,s,a,c]=r.match(Gl);return{[e]:parseFloat(o),[t]:parseFloat(s),[n]:parseFloat(a),alpha:c!==void 0?parseFloat(c):1}},cO=e=>Ao(0,255,e),xd={..._o,transform:e=>Math.round(cO(e))},qo={test:Qd("rgb","red"),parse:xE("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+xd.transform(e)+", "+xd.transform(t)+", "+xd.transform(n)+", "+$s(qs.transform(r))+")"};function uO(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}const wd={test:Qd("#"),parse:uO,transform:qo.transform},Ki={test:Qd("hsl","hue"),parse:xE("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Qr.transform($s(t))+", "+Qr.transform($s(n))+", "+$s(qs.transform(r))+")"},an={test:e=>qo.test(e)||wd.test(e)||Ki.test(e),parse:e=>qo.test(e)?qo.parse(e):Ki.test(e)?Ki.parse(e):wd.parse(e),transform:e=>ea(e)?e:e.hasOwnProperty("red")?qo.transform(e):Ki.transform(e)},Qt=(e,t,n)=>-n*e+n*t+e;function Td(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function AO({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let o=0,s=0,a=0;if(!t)o=s=a=n;else{const c=n<.5?n*(1+t):n+t-n*t,u=2*n-c;o=Td(u,c,e+1/3),s=Td(u,c,e),a=Td(u,c,e-1/3)}return{red:Math.round(o*255),green:Math.round(s*255),blue:Math.round(a*255),alpha:r}}const Sd=(e,t,n)=>{const r=e*e;return Math.sqrt(Math.max(0,n*(t*t-r)+r))},dO=[wd,qo,Ki],gO=e=>dO.find(t=>t.test(e));function wE(e){const t=gO(e);gr(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`);let n=t.parse(e);return t===Ki&&(n=AO(n)),n}const TE=(e,t)=>{const n=wE(e),r=wE(t),o={...n};return s=>(o.red=Sd(n.red,r.red,s),o.green=Sd(n.green,r.green,s),o.blue=Sd(n.blue,r.blue,s),o.alpha=Qt(n.alpha,r.alpha,s),qo.transform(o))};function fO(e){var t,n;return isNaN(e)&&ea(e)&&(((t=e.match(Gl))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(YC))===null||n===void 0?void 0:n.length)||0)>0}const SE={regex:cP,countKey:"Vars",token:"${v}",parse:Pt},PE={regex:YC,countKey:"Colors",token:"${c}",parse:an.parse},OE={regex:Gl,countKey:"Numbers",token:"${n}",parse:_o.parse};function Pd(e,{regex:t,countKey:n,token:r,parse:o}){const s=e.tokenised.match(t);s&&(e["num"+n]=s.length,e.tokenised=e.tokenised.replace(t,r),e.values.push(...s.map(o)))}function $l(e){const t=e.toString(),n={value:t,tokenised:t,values:[],numVars:0,numColors:0,numNumbers:0};return n.value.includes("var(--")&&Pd(n,SE),Pd(n,PE),Pd(n,OE),n}function jE(e){return $l(e).values}function DE(e){const{values:t,numColors:n,numVars:r,tokenised:o}=$l(e),s=t.length;return a=>{let c=o;for(let u=0;u<s;u++)u<r?c=c.replace(SE.token,a[u]):u<r+n?c=c.replace(PE.token,an.transform(a[u])):c=c.replace(OE.token,$s(a[u]));return c}}const pO=e=>typeof e=="number"?0:e;function hO(e){const t=jE(e);return DE(e)(t.map(pO))}const Co={test:fO,parse:jE,createTransformer:DE,getAnimatableNone:hO},ME=(e,t)=>n=>`${n>0?t:e}`;function kE(e,t){return typeof e=="number"?n=>Qt(e,t,n):an.test(e)?TE(e,t):e.startsWith("var(")?ME(e,t):FE(e,t)}const RE=(e,t)=>{const n=[...e],r=n.length,o=e.map((s,a)=>kE(s,t[a]));return s=>{for(let a=0;a<r;a++)n[a]=o[a](s);return n}},CO=(e,t)=>{const n={...e,...t},r={};for(const o in n)e[o]!==void 0&&t[o]!==void 0&&(r[o]=kE(e[o],t[o]));return o=>{for(const s in r)n[s]=r[s](o);return n}},FE=(e,t)=>{const n=Co.createTransformer(t),r=$l(e),o=$l(t);return r.numVars===o.numVars&&r.numColors===o.numColors&&r.numNumbers>=o.numNumbers?fo(RE(r.values,o.values),n):(na(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),ME(e,t))},ia=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r},LE=(e,t)=>n=>Qt(e,t,n);function EO(e){return typeof e=="number"?LE:typeof e=="string"?an.test(e)?TE:FE:Array.isArray(e)?RE:typeof e=="object"?CO:LE}function IO(e,t,n){const r=[],o=n||EO(e[0]),s=e.length-1;for(let a=0;a<s;a++){let c=o(e[a],e[a+1]);if(t){const u=Array.isArray(t)?t[a]||Pt:t;c=fo(u,c)}r.push(c)}return r}function NE(e,t,{clamp:n=!0,ease:r,mixer:o}={}){const s=e.length;if(gr(s===t.length,"Both input and output ranges must be the same length"),s===1)return()=>t[0];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=IO(t,r,o),c=a.length,u=A=>{let p=0;if(c>1)for(;p<e.length-2&&!(A<e[p+1]);p++);const h=ia(e[p],e[p+1],A);return a[p](h)};return n?A=>u(Ao(e[0],e[s-1],A)):u}function mO(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const o=ia(0,t,r);e.push(Qt(n,1,o))}}function BO(e){const t=[0];return mO(t,e.length-1),t}function vO(e,t){return e.map(n=>n*t)}function yO(e,t){return e.map(()=>t||IE).splice(0,e.length-1)}function ec({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=sO(r)?r.map(QE):QE(r),s={done:!1,value:t[0]},a=vO(n&&n.length===t.length?n:BO(t),e),c=NE(a,t,{ease:Array.isArray(o)?o:yO(t,o)});return{calculatedDuration:e,next:u=>(s.value=c(u),s.done=u>=e,s)}}function VE(e,t){return t?e*(1e3/t):0}const bO=5;function HE(e,t,n){const r=Math.max(t-bO,0);return VE(n-e(r),t-r)}const Od=.001,QO=.01,zE=10,xO=.05,wO=1;function TO({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let o,s;na(e<=ho(zE),"Spring duration must be 10 seconds or less");let a=1-t;a=Ao(xO,wO,a),e=Ao(QO,zE,Wr(e)),a<1?(o=A=>{const p=A*a,h=p*e,C=p-n,E=jd(A,a),m=Math.exp(-h);return Od-C/E*m},s=A=>{const h=A*a*e,C=h*n+n,E=Math.pow(a,2)*Math.pow(A,2)*e,m=Math.exp(-h),B=jd(Math.pow(A,2),a);return(-o(A)+Od>0?-1:1)*((C-E)*m)/B}):(o=A=>{const p=Math.exp(-A*e),h=(A-n)*e+1;return-Od+p*h},s=A=>{const p=Math.exp(-A*e),h=(n-A)*(e*e);return p*h});const c=5/e,u=PO(o,s,c);if(e=ho(e),isNaN(u))return{stiffness:100,damping:10,duration:e};{const A=Math.pow(u,2)*r;return{stiffness:A,damping:a*2*Math.sqrt(r*A),duration:e}}}const SO=12;function PO(e,t,n){let r=n;for(let o=1;o<SO;o++)r=r-e(r)/t(r);return r}function jd(e,t){return e*Math.sqrt(1-t*t)}const OO=["duration","bounce"],jO=["stiffness","damping","mass"];function WE(e,t){return t.some(n=>e[n]!==void 0)}function DO(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!WE(e,jO)&&WE(e,OO)){const n=TO(e);t={...t,...n,mass:1},t.isResolvedFromDuration=!0}return t}function UE({keyframes:e,restDelta:t,restSpeed:n,...r}){const o=e[0],s=e[e.length-1],a={done:!1,value:o},{stiffness:c,damping:u,mass:A,duration:p,velocity:h,isResolvedFromDuration:C}=DO({...r,velocity:-Wr(r.velocity||0)}),E=h||0,m=u/(2*Math.sqrt(c*A)),B=s-o,v=Wr(Math.sqrt(c/A)),S=Math.abs(B)<5;n||(n=S?.01:2),t||(t=S?.005:.5);let M;if(m<1){const x=jd(v,m);M=O=>{const P=Math.exp(-m*v*O);return s-P*((E+m*v*B)/x*Math.sin(x*O)+B*Math.cos(x*O))}}else if(m===1)M=x=>s-Math.exp(-v*x)*(B+(E+v*B)*x);else{const x=v*Math.sqrt(m*m-1);M=O=>{const P=Math.exp(-m*v*O),F=Math.min(x*O,300);return s-P*((E+m*v*B)*Math.sinh(F)+x*B*Math.cosh(F))/x}}return{calculatedDuration:C&&p||null,next:x=>{const O=M(x);if(C)a.done=x>=p;else{let P=E;x!==0&&(m<1?P=HE(M,x,O):P=0);const F=Math.abs(P)<=n,L=Math.abs(s-O)<=t;a.done=F&&L}return a.value=a.done?s:O,a}}}function YE({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:s=500,modifyTarget:a,min:c,max:u,restDelta:A=.5,restSpeed:p}){const h=e[0],C={done:!1,value:h},E=K=>c!==void 0&&K<c||u!==void 0&&K>u,m=K=>c===void 0?u:u===void 0||Math.abs(c-K)<Math.abs(u-K)?c:u;let B=n*t;const v=h+B,S=a===void 0?v:a(v);S!==v&&(B=S-h);const M=K=>-B*Math.exp(-K/r),x=K=>S+M(K),O=K=>{const J=M(K),ee=x(K);C.done=Math.abs(J)<=A,C.value=C.done?S:ee};let P,F;const L=K=>{E(C.value)&&(P=K,F=UE({keyframes:[C.value,m(C.value)],velocity:HE(x,K,C.value),damping:o,stiffness:s,restDelta:A,restSpeed:p}))};return L(0),{calculatedDuration:null,next:K=>{let J=!1;return!F&&P===void 0&&(J=!0,O(K),L(K)),P!==void 0&&K>P?F.next(K-P):(!J&&O(K),C)}}}const MO=e=>{const t=({timestamp:n})=>e(n);return{start:()=>ht.update(t,!0),stop:()=>Vr(t),now:()=>$t.isProcessing?$t.timestamp:performance.now()}},GE=2e4;function KE(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<GE;)t+=n,r=e.next(t);return t>=GE?1/0:t}const kO={decay:YE,inertia:YE,tween:ec,keyframes:ec,spring:UE};function tc({autoplay:e=!0,delay:t=0,driver:n=MO,keyframes:r,type:o="keyframes",repeat:s=0,repeatDelay:a=0,repeatType:c="loop",onPlay:u,onStop:A,onComplete:p,onUpdate:h,...C}){let E=1,m=!1,B,v;const S=()=>{v=new Promise(X=>{B=X})};S();let M;const x=kO[o]||ec;let O;x!==ec&&typeof r[0]!="number"&&(process.env.NODE_ENV!=="production"&&gr(r.length===2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${r}`),O=NE([0,100],r,{clamp:!1}),r=[0,100]);const P=x({...C,keyframes:r});let F;c==="mirror"&&(F=x({...C,keyframes:[...r].reverse(),velocity:-(C.velocity||0)}));let L="idle",K=null,J=null,ee=null;P.calculatedDuration===null&&s&&(P.calculatedDuration=KE(P));const{calculatedDuration:G}=P;let se=1/0,ae=1/0;G!==null&&(se=G+a,ae=se*(s+1)-a);let _=0;const q=X=>{if(J===null)return;E>0&&(J=Math.min(J,X)),E<0&&(J=Math.min(X-ae/E,J)),K!==null?_=K:_=Math.round(X-J)*E;const ce=_-t*(E>=0?1:-1),he=E>=0?ce<0:ce>ae;_=Math.max(ce,0),L==="finished"&&K===null&&(_=ae);let ge=_,fe=P;if(s){const Ee=Math.min(_,ae)/se;let Be=Math.floor(Ee),we=Ee%1;!we&&Ee>=1&&(we=1),we===1&&Be--,Be=Math.min(Be,s+1),!!(Be%2)&&(c==="reverse"?(we=1-we,a&&(we-=a/se)):c==="mirror"&&(fe=F)),ge=Ao(0,1,we)*se}const Ce=he?{done:!1,value:r[0]}:fe.next(ge);O&&(Ce.value=O(Ce.value));let{done:ve}=Ce;!he&&G!==null&&(ve=E>=0?_>=ae:_<=0);const me=K===null&&(L==="finished"||L==="running"&&ve);return h&&h(Ce.value),me&&N(),Ce},z=()=>{M&&M.stop(),M=void 0},Z=()=>{L="idle",z(),B(),S(),J=ee=null},N=()=>{L="finished",p&&p(),z(),B()},$=()=>{if(m)return;M||(M=n(q));const X=M.now();u&&u(),K!==null?J=X-K:(!J||L==="finished")&&(J=X),L==="finished"&&S(),ee=J,K=null,L="running",M.start()};e&&$();const H={then(X,ce){return v.then(X,ce)},get time(){return Wr(_)},set time(X){X=ho(X),_=X,K!==null||!M||E===0?K=X:J=M.now()-X/E},get duration(){const X=P.calculatedDuration===null?KE(P):P.calculatedDuration;return Wr(X)},get speed(){return E},set speed(X){X===E||!M||(E=X,H.time=Wr(_))},get state(){return L},play:$,pause:()=>{L="paused",K=_},stop:()=>{m=!0,L!=="idle"&&(L="idle",A&&A(),Z())},cancel:()=>{ee!==null&&q(ee),Z()},complete:()=>{L="finished"},sample:X=>(J=0,q(X))};return H}function RO(e){let t;return()=>(t===void 0&&(t=e()),t)}const FO=RO(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),LO=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),nc=10,NO=2e4,VO=(e,t)=>t.type==="spring"||e==="backgroundColor"||!pE(t.ease);function HO(e,t,{onUpdate:n,onComplete:r,...o}){if(!(FO()&&LO.has(t)&&!o.repeatDelay&&o.repeatType!=="mirror"&&o.damping!==0&&o.type!=="inertia"))return!1;let a=!1,c,u,A=!1;const p=()=>{u=new Promise(x=>{c=x})};p();let{keyframes:h,duration:C=300,ease:E,times:m}=o;if(VO(t,o)){const x=tc({...o,repeat:0,delay:0});let O={done:!1,value:h[0]};const P=[];let F=0;for(;!O.done&&F<NO;)O=x.sample(F),P.push(O.value),F+=nc;m=void 0,h=P,C=F-nc,E="linear"}const B=$P(e.owner.current,t,h,{...o,duration:C,ease:E,times:m}),v=()=>{A=!1,B.cancel()},S=()=>{A=!0,ht.update(v),c(),p()};return B.onfinish=()=>{A||(e.set(eO(h,o)),r&&r(),S())},{then(x,O){return u.then(x,O)},attachTimeline(x){return B.timeline=x,B.onfinish=null,Pt},get time(){return Wr(B.currentTime||0)},set time(x){B.currentTime=ho(x)},get speed(){return B.playbackRate},set speed(x){B.playbackRate=x},get duration(){return Wr(C)},play:()=>{a||(B.play(),Vr(v))},pause:()=>B.pause(),stop:()=>{if(a=!0,B.playState==="idle")return;const{currentTime:x}=B;if(x){const O=tc({...o,autoplay:!1});e.setWithVelocity(O.sample(x-nc).value,O.sample(x).value,nc)}S()},complete:()=>{A||B.finish()},cancel:S}}function zO({keyframes:e,delay:t,onUpdate:n,onComplete:r}){const o=()=>(n&&n(e[e.length-1]),r&&r(),{time:0,speed:1,duration:0,play:Pt,pause:Pt,stop:Pt,then:s=>(s(),Promise.resolve()),cancel:Pt,complete:Pt});return t?tc({keyframes:[0,1],duration:0,delay:t,onComplete:o}):o()}const WO={type:"spring",stiffness:500,damping:25,restSpeed:10},UO=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),YO={type:"keyframes",duration:.8},GO={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},KO=(e,{keyframes:t})=>t.length>2?YO:Zo.has(e)?e.startsWith("scale")?UO(t[1]):WO:GO,Dd=(e,t)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(Co.test(t)||t==="0")&&!t.startsWith("url(")),JO=new Set(["brightness","contrast","saturate","opacity"]);function XO(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Gl)||[];if(!r)return e;const o=n.replace(r,"");let s=JO.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+o+")"}const ZO=/([a-z-]*)\(.*?\)/g,Md={...Co,getAnimatableNone:e=>{const t=e.match(ZO);return t?t.map(XO).join(" "):e}},_O={...JC,color:an,backgroundColor:an,outlineColor:an,fill:an,stroke:an,borderColor:an,borderTopColor:an,borderRightColor:an,borderBottomColor:an,borderLeftColor:an,filter:Md,WebkitFilter:Md},kd=e=>_O[e];function JE(e,t){let n=kd(e);return n!==Md&&(n=Co),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const XE=e=>/^0[^.\s]+$/.test(e);function qO(e){if(typeof e=="number")return e===0;if(e!==null)return e==="none"||e==="0"||XE(e)}function $O(e,t,n,r){const o=Dd(t,n);let s;Array.isArray(n)?s=[...n]:s=[null,n];const a=r.from!==void 0?r.from:e.get();let c;const u=[];for(let A=0;A<s.length;A++)s[A]===null&&(s[A]=A===0?a:s[A-1]),qO(s[A])&&u.push(A),typeof s[A]=="string"&&s[A]!=="none"&&s[A]!=="0"&&(c=s[A]);if(o&&u.length&&c)for(let A=0;A<u.length;A++){const p=u[A];s[p]=JE(t,c)}return s}function e4({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:s,repeatType:a,repeatDelay:c,from:u,elapsed:A,...p}){return!!Object.keys(p).length}function Rd(e,t){return e[t]||e.default||e}const t4={skipAnimations:!1},Fd=(e,t,n,r={})=>o=>{const s=Rd(r,e)||{},a=s.delay||r.delay||0;let{elapsed:c=0}=r;c=c-ho(a);const u=$O(t,e,n,s),A=u[0],p=u[u.length-1],h=Dd(e,A),C=Dd(e,p);na(h===C,`You are trying to animate ${e} from "${A}" to "${p}". ${A} is not an animatable value - to enable this animation set ${A} to a value animatable to ${p} via the \`style\` property.`);let E={keyframes:u,velocity:t.getVelocity(),ease:"easeOut",...s,delay:-c,onUpdate:m=>{t.set(m),s.onUpdate&&s.onUpdate(m)},onComplete:()=>{o(),s.onComplete&&s.onComplete()}};if(e4(s)||(E={...E,...KO(e,E)}),E.duration&&(E.duration=ho(E.duration)),E.repeatDelay&&(E.repeatDelay=ho(E.repeatDelay)),!h||!C||qP.current||s.type===!1||t4.skipAnimations)return zO(E);if(!r.isHandoff&&t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUpdate){const m=HO(t,e,E);if(m)return m}return tc(E)};function rc(e){return!!(hn(e)&&e.add)}const ZE=e=>/^\-?\d*\.?\d+$/.test(e);function Ld(e,t){e.indexOf(t)===-1&&e.push(t)}function Nd(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class Vd{constructor(){this.subscriptions=[]}add(t){return Ld(this.subscriptions,t),()=>Nd(this.subscriptions,t)}notify(t,n,r){const o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,n,r);else for(let s=0;s<o;s++){const a=this.subscriptions[s];a&&a(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const _E=new Set;function Hd(e,t,n){e||_E.has(t)||(console.warn(t),n&&console.warn(n),_E.add(t))}const n4=e=>!isNaN(parseFloat(e));class r4{constructor(t,n={}){this.version="10.18.0",this.timeDelta=0,this.lastUpdated=0,this.canTrackVelocity=!1,this.events={},this.updateAndNotify=(r,o=!0)=>{this.prev=this.current,this.current=r;const{delta:s,timestamp:a}=$t;this.lastUpdated!==a&&(this.timeDelta=s,this.lastUpdated=a,ht.postRender(this.scheduleVelocityCheck)),this.prev!==this.current&&this.events.change&&this.events.change.notify(this.current),this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()),o&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.scheduleVelocityCheck=()=>ht.postRender(this.velocityCheck),this.velocityCheck=({timestamp:r})=>{r!==this.lastUpdated&&(this.prev=this.current,this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=t,this.canTrackVelocity=n4(this.current),this.owner=n.owner}onChange(t){return process.env.NODE_ENV!=="production"&&Hd(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Vd);const r=this.events[t].add(n);return t==="change"?()=>{r(),ht.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t,n=!0){!n||!this.passiveEffect?this.updateAndNotify(t,n):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,n,r){this.set(n),this.prev=t,this.timeDelta=r}jump(t){this.updateAndNotify(t),this.prev=t,this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?VE(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Ji(e,t){return new r4(e,t)}const qE=e=>t=>t.test(e),$E=[_o,ke,Qr,go,gP,dP,{test:e=>e==="auto",parse:e=>e}],sa=e=>$E.find(qE(e)),o4=[...$E,an,Co],i4=e=>o4.find(qE(e));function s4(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Ji(n))}function a4(e,t){const n=ql(e,t);let{transitionEnd:r={},transition:o={},...s}=n?e.makeTargetAnimatable(n,!1):{};s={...s,...r};for(const a in s){const c=TP(s[a]);s4(e,a,c)}}function l4(e,t,n){var r,o;const s=Object.keys(t).filter(c=>!e.hasValue(c)),a=s.length;if(a)for(let c=0;c<a;c++){const u=s[c],A=t[u];let p=null;Array.isArray(A)&&(p=A[0]),p===null&&(p=(o=(r=n[u])!==null&&r!==void 0?r:e.readValue(u))!==null&&o!==void 0?o:t[u]),p!=null&&(typeof p=="string"&&(ZE(p)||XE(p))?p=parseFloat(p):!i4(p)&&Co.test(A)&&(p=JE(u,A)),e.addValue(u,Ji(p,{owner:e})),n[u]===void 0&&(n[u]=p),p!==null&&e.setBaseTarget(u,p))}}function c4(e,t){return t?(t[e]||t.default||t).from:void 0}function u4(e,t,n){const r={};for(const o in e){const s=c4(o,t);if(s!==void 0)r[o]=s;else{const a=n.getValue(o);a&&(r[o]=a.get())}}return r}function A4({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function d4(e,t){const n=e.get();if(Array.isArray(t)){for(let r=0;r<t.length;r++)if(t[r]!==n)return!0}else return n!==t}function eI(e,t,{delay:n=0,transitionOverride:r,type:o}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:a,...c}=e.makeTargetAnimatable(t);const u=e.getValue("willChange");r&&(s=r);const A=[],p=o&&e.animationState&&e.animationState.getState()[o];for(const h in c){const C=e.getValue(h),E=c[h];if(!C||E===void 0||p&&A4(p,h))continue;const m={delay:n,elapsed:0,...Rd(s||{},h)};if(window.HandoffAppearAnimations){const S=e.getProps()[RC];if(S){const M=window.HandoffAppearAnimations(S,h,C,ht);M!==null&&(m.elapsed=M,m.isHandoff=!0)}}let B=!m.isHandoff&&!d4(C,E);if(m.type==="spring"&&(C.getVelocity()||m.velocity)&&(B=!1),C.animation&&(B=!1),B)continue;C.start(Fd(h,C,E,e.shouldReduceMotion&&Zo.has(h)?{type:!1}:m));const v=C.animation;rc(u)&&(u.add(h),v.then(()=>u.remove(h))),A.push(v)}return a&&Promise.all(A).then(()=>{a&&a4(e,a)}),A}function zd(e,t,n={}){const r=ql(e,t,n.custom);let{transition:o=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(o=n.transitionOverride);const s=r?()=>Promise.all(eI(e,r,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:A=0,staggerChildren:p,staggerDirection:h}=o;return g4(e,t,A+u,p,h,n)}:()=>Promise.resolve(),{when:c}=o;if(c){const[u,A]=c==="beforeChildren"?[s,a]:[a,s];return u().then(()=>A())}else return Promise.all([s(),a(n.delay)])}function g4(e,t,n=0,r=0,o=1,s){const a=[],c=(e.variantChildren.size-1)*r,u=o===1?(A=0)=>A*r:(A=0)=>c-A*r;return Array.from(e.variantChildren).sort(f4).forEach((A,p)=>{A.notify("AnimationStart",t),a.push(zd(A,t,{...s,delay:n+u(p)}).then(()=>A.notify("AnimationComplete",t)))}),Promise.all(a)}function f4(e,t){return e.sortNodePosition(t)}function p4(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const o=t.map(s=>zd(e,s,n));r=Promise.all(o)}else if(typeof t=="string")r=zd(e,t,n);else{const o=typeof t=="function"?ql(e,t,n.custom):t;r=Promise.all(eI(e,o,n))}return r.then(()=>e.notify("AnimationComplete",t))}const h4=[...cd].reverse(),C4=cd.length;function E4(e){return t=>Promise.all(t.map(({animation:n,options:r})=>p4(e,n,r)))}function I4(e){let t=E4(e);const n=B4();let r=!0;const o=(u,A)=>{const p=ql(e,A);if(p){const{transition:h,transitionEnd:C,...E}=p;u={...u,...E,...C}}return u};function s(u){t=u(e)}function a(u,A){const p=e.getProps(),h=e.getVariantContext(!0)||{},C=[],E=new Set;let m={},B=1/0;for(let S=0;S<C4;S++){const M=h4[S],x=n[M],O=p[M]!==void 0?p[M]:h[M],P=Xs(O),F=M===A?x.isActive:null;F===!1&&(B=S);let L=O===h[M]&&O!==p[M]&&P;if(L&&r&&e.manuallyAnimateOnMount&&(L=!1),x.protectedKeys={...m},!x.isActive&&F===null||!O&&!x.prevProp||zl(O)||typeof O=="boolean")continue;let J=m4(x.prevProp,O)||M===A&&x.isActive&&!L&&P||S>B&&P,ee=!1;const G=Array.isArray(O)?O:[O];let se=G.reduce(o,{});F===!1&&(se={});const{prevResolvedValues:ae={}}=x,_={...ae,...se},q=z=>{J=!0,E.has(z)&&(ee=!0,E.delete(z)),x.needsAnimating[z]=!0};for(const z in _){const Z=se[z],N=ae[z];if(m.hasOwnProperty(z))continue;let $=!1;Jl(Z)&&Jl(N)?$=!gE(Z,N):$=Z!==N,$?Z!==void 0?q(z):E.add(z):Z!==void 0&&E.has(z)?q(z):x.protectedKeys[z]=!0}x.prevProp=O,x.prevResolvedValues=se,x.isActive&&(m={...m,...se}),r&&e.blockInitialAnimation&&(J=!1),J&&(!L||ee)&&C.push(...G.map(z=>({animation:z,options:{type:M,...u}})))}if(E.size){const S={};E.forEach(M=>{const x=e.getBaseTarget(M);x!==void 0&&(S[M]=x)}),C.push({animation:S})}let v=!!C.length;return r&&(p.initial===!1||p.initial===p.animate)&&!e.manuallyAnimateOnMount&&(v=!1),r=!1,v?t(C):Promise.resolve()}function c(u,A,p){var h;if(n[u].isActive===A)return Promise.resolve();(h=e.variantChildren)===null||h===void 0||h.forEach(E=>{var m;return(m=E.animationState)===null||m===void 0?void 0:m.setActive(u,A)}),n[u].isActive=A;const C=a(p,u);for(const E in n)n[E].protectedKeys={};return C}return{animateChanges:a,setActive:c,setAnimateFunction:s,getState:()=>n}}function m4(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!gE(t,e):!1}function $o(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function B4(){return{animate:$o(!0),whileInView:$o(),whileHover:$o(),whileTap:$o(),whileDrag:$o(),whileFocus:$o(),exit:$o()}}class v4 extends po{constructor(t){super(t),t.animationState||(t.animationState=I4(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();this.unmount(),zl(t)&&(this.unmount=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){}}let y4=0;class b4 extends po{constructor(){super(...arguments),this.id=y4++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n,custom:r}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===o)return;const s=this.node.animationState.setActive("exit",!t,{custom:r??this.node.getProps().custom});n&&!t&&s.then(()=>n(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const Q4={animation:{Feature:v4},exit:{Feature:b4}},tI=(e,t)=>Math.abs(e-t);function x4(e,t){const n=tI(e.x,t.x),r=tI(e.y,t.y);return Math.sqrt(n**2+r**2)}class nI{constructor(t,n,{transformPagePoint:r,contextWindow:o,dragSnapToOrigin:s=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const h=Ud(this.lastMoveEventInfo,this.history),C=this.startEvent!==null,E=x4(h.offset,{x:0,y:0})>=3;if(!C&&!E)return;const{point:m}=h,{timestamp:B}=$t;this.history.push({...m,timestamp:B});const{onStart:v,onMove:S}=this.handlers;C||(v&&v(this.lastMoveEvent,h),this.startEvent=this.lastMoveEvent),S&&S(this.lastMoveEvent,h)},this.handlePointerMove=(h,C)=>{this.lastMoveEvent=h,this.lastMoveEventInfo=Wd(C,this.transformPagePoint),ht.update(this.updatePoint,!0)},this.handlePointerUp=(h,C)=>{this.end();const{onEnd:E,onSessionEnd:m,resumeAnimation:B}=this.handlers;if(this.dragSnapToOrigin&&B&&B(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const v=Ud(h.type==="pointercancel"?this.lastMoveEventInfo:Wd(C,this.transformPagePoint),this.history);this.startEvent&&E&&E(h,v),m&&m(h,v)},!iE(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.contextWindow=o||window;const a=_l(t),c=Wd(a,this.transformPagePoint),{point:u}=c,{timestamp:A}=$t;this.history=[{...u,timestamp:A}];const{onSessionStart:p}=n;p&&p(t,Ud(c,this.history)),this.removeListeners=fo(zr(this.contextWindow,"pointermove",this.handlePointerMove),zr(this.contextWindow,"pointerup",this.handlePointerUp),zr(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Vr(this.updatePoint)}}function Wd(e,t){return t?{point:t(e.point)}:e}function rI(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Ud({point:e},t){return{point:e,delta:rI(e,oI(t)),offset:rI(e,w4(t)),velocity:T4(t,.1)}}function w4(e){return e[0]}function oI(e){return e[e.length-1]}function T4(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=oI(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>ho(t)));)n--;if(!r)return{x:0,y:0};const s=Wr(o.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const a={x:(o.x-r.x)/s,y:(o.y-r.y)/s};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function Sn(e){return e.max-e.min}function Yd(e,t=0,n=.01){return Math.abs(e-t)<=n}function iI(e,t,n,r=.5){e.origin=r,e.originPoint=Qt(t.min,t.max,e.origin),e.scale=Sn(n)/Sn(t),(Yd(e.scale,1,1e-4)||isNaN(e.scale))&&(e.scale=1),e.translate=Qt(n.min,n.max,e.origin)-e.originPoint,(Yd(e.translate)||isNaN(e.translate))&&(e.translate=0)}function aa(e,t,n,r){iI(e.x,t.x,n.x,r?r.originX:void 0),iI(e.y,t.y,n.y,r?r.originY:void 0)}function sI(e,t,n){e.min=n.min+t.min,e.max=e.min+Sn(t)}function S4(e,t,n){sI(e.x,t.x,n.x),sI(e.y,t.y,n.y)}function aI(e,t,n){e.min=t.min-n.min,e.max=e.min+Sn(t)}function la(e,t,n){aI(e.x,t.x,n.x),aI(e.y,t.y,n.y)}function P4(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?Qt(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?Qt(n,e,r.max):Math.min(e,n)),e}function lI(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function O4(e,{top:t,left:n,bottom:r,right:o}){return{x:lI(e.x,n,o),y:lI(e.y,t,r)}}function cI(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function j4(e,t){return{x:cI(e.x,t.x),y:cI(e.y,t.y)}}function D4(e,t){let n=.5;const r=Sn(e),o=Sn(t);return o>r?n=ia(t.min,t.max-r,e.min):r>o&&(n=ia(e.min,e.max-o,t.min)),Ao(0,1,n)}function M4(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Gd=.35;function k4(e=Gd){return e===!1?e=0:e===!0&&(e=Gd),{x:uI(e,"left","right"),y:uI(e,"top","bottom")}}function uI(e,t,n){return{min:AI(e,t),max:AI(e,n)}}function AI(e,t){return typeof e=="number"?e:e[t]||0}const dI=()=>({translate:0,scale:1,origin:0,originPoint:0}),Xi=()=>({x:dI(),y:dI()}),gI=()=>({min:0,max:0}),Nt=()=>({x:gI(),y:gI()});function Gn(e){return[e("x"),e("y")]}function fI({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function R4({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function F4(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Kd(e){return e===void 0||e===1}function Jd({scale:e,scaleX:t,scaleY:n}){return!Kd(e)||!Kd(t)||!Kd(n)}function ei(e){return Jd(e)||pI(e)||e.z||e.rotate||e.rotateX||e.rotateY}function pI(e){return hI(e.x)||hI(e.y)}function hI(e){return e&&e!=="0%"}function oc(e,t,n){const r=e-n,o=t*r;return n+o}function CI(e,t,n,r,o){return o!==void 0&&(e=oc(e,o,r)),oc(e,n,r)+t}function Xd(e,t=0,n=1,r,o){e.min=CI(e.min,t,n,r,o),e.max=CI(e.max,t,n,r,o)}function EI(e,{x:t,y:n}){Xd(e.x,t.translate,t.scale,t.originPoint),Xd(e.y,n.translate,n.scale,n.originPoint)}function L4(e,t,n,r=!1){const o=n.length;if(!o)return;t.x=t.y=1;let s,a;for(let c=0;c<o;c++){s=n[c],a=s.projectionDelta;const u=s.instance;u&&u.style&&u.style.display==="contents"||(r&&s.options.layoutScroll&&s.scroll&&s!==s.root&&Zi(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,EI(e,a)),r&&ei(s.latestValues)&&Zi(e,s.latestValues))}t.x=II(t.x),t.y=II(t.y)}function II(e){return Number.isInteger(e)||e>1.0000000000001||e<.999999999999?e:1}function Eo(e,t){e.min=e.min+t,e.max=e.max+t}function mI(e,t,[n,r,o]){const s=t[o]!==void 0?t[o]:.5,a=Qt(e.min,e.max,s);Xd(e,t[n],t[r],a,t.scale)}const N4=["x","scaleX","originX"],V4=["y","scaleY","originY"];function Zi(e,t){mI(e.x,t,N4),mI(e.y,t,V4)}function BI(e,t){return fI(F4(e.getBoundingClientRect(),t))}function H4(e,t,n){const r=BI(e,n),{scroll:o}=t;return o&&(Eo(r.x,o.offset.x),Eo(r.y,o.offset.y)),r}const vI=({current:e})=>e?e.ownerDocument.defaultView:null,z4=new WeakMap;class W4{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Nt(),this.visualElement=t}start(t,{snapToCursor:n=!1}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const o=p=>{const{dragSnapToOrigin:h}=this.getProps();h?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(_l(p,"page").point)},s=(p,h)=>{const{drag:C,dragPropagation:E,onDragStart:m}=this.getProps();if(C&&!E&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=cE(C),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Gn(v=>{let S=this.getAxisMotionValue(v).get()||0;if(Qr.test(S)){const{projection:M}=this.visualElement;if(M&&M.layout){const x=M.layout.layoutBox[v];x&&(S=Sn(x)*(parseFloat(S)/100))}}this.originPoint[v]=S}),m&&ht.update(()=>m(p,h),!1,!0);const{animationState:B}=this.visualElement;B&&B.setActive("whileDrag",!0)},a=(p,h)=>{const{dragPropagation:C,dragDirectionLock:E,onDirectionLock:m,onDrag:B}=this.getProps();if(!C&&!this.openGlobalLock)return;const{offset:v}=h;if(E&&this.currentDirection===null){this.currentDirection=U4(v),this.currentDirection!==null&&m&&m(this.currentDirection);return}this.updateAxis("x",h.point,v),this.updateAxis("y",h.point,v),this.visualElement.render(),B&&B(p,h)},c=(p,h)=>this.stop(p,h),u=()=>Gn(p=>{var h;return this.getAnimationState(p)==="paused"&&((h=this.getAxisMotionValue(p).animation)===null||h===void 0?void 0:h.play())}),{dragSnapToOrigin:A}=this.getProps();this.panSession=new nI(t,{onSessionStart:o,onStart:s,onMove:a,onSessionEnd:c,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:A,contextWindow:vI(this.visualElement)})}stop(t,n){const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:o}=n;this.startAnimation(o);const{onDragEnd:s}=this.getProps();s&&ht.update(()=>s(t,n))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:o}=this.getProps();if(!r||!ic(t,o,this.currentDirection))return;const s=this.getAxisMotionValue(t);let a=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(a=P4(a,this.constraints[t],this.elastic[t])),s.set(a)}resolveConstraints(){var t;const{dragConstraints:n,dragElastic:r}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,s=this.constraints;n&&Gi(n)?this.constraints||(this.constraints=this.resolveRefConstraints()):n&&o?this.constraints=O4(o.layoutBox,n):this.constraints=!1,this.elastic=k4(r),s!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&Gn(a=>{this.getAxisMotionValue(a)&&(this.constraints[a]=M4(o.layoutBox[a],this.constraints[a]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Gi(t))return!1;const r=t.current;gr(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:o}=this.visualElement;if(!o||!o.layout)return!1;const s=H4(r,o.root,this.visualElement.getTransformPagePoint());let a=j4(o.layout.layoutBox,s);if(n){const c=n(R4(a));this.hasMutatedConstraints=!!c,c&&(a=fI(c))}return a}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:o,dragTransition:s,dragSnapToOrigin:a,onDragTransitionEnd:c}=this.getProps(),u=this.constraints||{},A=Gn(p=>{if(!ic(p,n,this.currentDirection))return;let h=u&&u[p]||{};a&&(h={min:0,max:0});const C=o?200:1e6,E=o?40:1e7,m={type:"inertia",velocity:r?t[p]:0,bounceStiffness:C,bounceDamping:E,timeConstant:750,restDelta:1,restSpeed:10,...s,...h};return this.startAxisValueAnimation(p,m)});return Promise.all(A).then(c)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return r.start(Fd(t,r,0,n))}stopAnimation(){Gn(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Gn(t=>{var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.state}getAxisMotionValue(t){const n="_drag"+t.toUpperCase(),r=this.visualElement.getProps(),o=r[n];return o||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Gn(n=>{const{drag:r}=this.getProps();if(!ic(n,r,this.currentDirection))return;const{projection:o}=this.visualElement,s=this.getAxisMotionValue(n);if(o&&o.layout){const{min:a,max:c}=o.layout.layoutBox[n];s.set(t[n]-Qt(a,c,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Gi(n)||!r||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};Gn(a=>{const c=this.getAxisMotionValue(a);if(c){const u=c.get();o[a]=D4({min:u,max:u},this.constraints[a])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Gn(a=>{if(!ic(a,t,null))return;const c=this.getAxisMotionValue(a),{min:u,max:A}=this.constraints[a];c.set(Qt(u,A,o[a]))})}addListeners(){if(!this.visualElement.current)return;z4.set(this.visualElement,this);const t=this.visualElement.current,n=zr(t,"pointerdown",u=>{const{drag:A,dragListener:p=!0}=this.getProps();A&&p&&this.start(u)}),r=()=>{const{dragConstraints:u}=this.getProps();Gi(u)&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,s=o.addEventListener("measure",r);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),r();const a=Hr(window,"resize",()=>this.scalePositionWithinConstraints()),c=o.addEventListener("didUpdate",({delta:u,hasLayoutChanged:A})=>{this.isDragging&&A&&(Gn(p=>{const h=this.getAxisMotionValue(p);h&&(this.originPoint[p]+=u[p].translate,h.set(h.get()+u[p].translate))}),this.visualElement.render())});return()=>{a(),n(),s(),c&&c()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:o=!1,dragConstraints:s=!1,dragElastic:a=Gd,dragMomentum:c=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:o,dragConstraints:s,dragElastic:a,dragMomentum:c}}}function ic(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function U4(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class Y4 extends po{constructor(t){super(t),this.removeGroupControls=Pt,this.removeListeners=Pt,this.controls=new W4(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Pt}unmount(){this.removeGroupControls(),this.removeListeners()}}const yI=e=>(t,n)=>{e&&ht.update(()=>e(t,n))};class G4 extends po{constructor(){super(...arguments),this.removePointerDownListener=Pt}onPointerDown(t){this.session=new nI(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:vI(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:o}=this.node.getProps();return{onSessionStart:yI(t),onStart:yI(n),onMove:r,onEnd:(s,a)=>{delete this.session,o&&ht.update(()=>o(s,a))}}}mount(){this.removePointerDownListener=zr(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}function K4(){const e=Q.useContext(ad);if(e===null)return[!0,null];const{isPresent:t,onExitComplete:n,register:r}=e,o=Q.useId();return Q.useEffect(()=>r(o),[]),!t&&n?[!1,()=>n&&n(o)]:[!0]}const sc={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function bI(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const ca={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(ke.test(e))e=parseFloat(e);else return e;const n=bI(e,t.target.x),r=bI(e,t.target.y);return`${n}% ${r}%`}},J4={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=Co.parse(e);if(o.length>5)return r;const s=Co.createTransformer(e),a=typeof o[0]!="number"?1:0,c=n.x.scale*t.x,u=n.y.scale*t.y;o[0+a]/=c,o[1+a]/=u;const A=Qt(c,u,.5);return typeof o[2+a]=="number"&&(o[2+a]/=A),typeof o[3+a]=="number"&&(o[3+a]/=A),s(o)}};class X4 extends Q.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:o}=this.props,{projection:s}=t;iP(Z4),s&&(n.group&&n.group.add(s),r&&r.register&&o&&r.register(s),s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),sc.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:o,isPresent:s}=this.props,a=r.projection;return a&&(a.isPresent=s,o||t.layoutDependency!==n||n===void 0?a.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?a.promote():a.relegate()||ht.postRender(()=>{const c=a.getStack();(!c||!c.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),queueMicrotask(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:o}=t;o&&(o.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(o),r&&r.deregister&&r.deregister(o))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function QI(e){const[t,n]=K4(),r=Q.useContext(VC);return Q.createElement(X4,{...e,layoutGroup:r,switchLayoutGroup:Q.useContext(HC),isPresent:t,safeToRemove:n})}const Z4={borderRadius:{...ca,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:ca,borderTopRightRadius:ca,borderBottomLeftRadius:ca,borderBottomRightRadius:ca,boxShadow:J4},xI=["TopLeft","TopRight","BottomLeft","BottomRight"],_4=xI.length,wI=e=>typeof e=="string"?parseFloat(e):e,TI=e=>typeof e=="number"||ke.test(e);function q4(e,t,n,r,o,s){o?(e.opacity=Qt(0,n.opacity!==void 0?n.opacity:1,$4(r)),e.opacityExit=Qt(t.opacity!==void 0?t.opacity:1,0,ej(r))):s&&(e.opacity=Qt(t.opacity!==void 0?t.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let a=0;a<_4;a++){const c=`border${xI[a]}Radius`;let u=SI(t,c),A=SI(n,c);if(u===void 0&&A===void 0)continue;u||(u=0),A||(A=0),u===0||A===0||TI(u)===TI(A)?(e[c]=Math.max(Qt(wI(u),wI(A),r),0),(Qr.test(A)||Qr.test(u))&&(e[c]+="%")):e[c]=A}(t.rotate||n.rotate)&&(e.rotate=Qt(t.rotate||0,n.rotate||0,r))}function SI(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const $4=PI(0,.5,vE),ej=PI(.5,.95,Pt);function PI(e,t,n){return r=>r<e?0:r>t?1:n(ia(e,t,r))}function OI(e,t){e.min=t.min,e.max=t.max}function Kn(e,t){OI(e.x,t.x),OI(e.y,t.y)}function jI(e,t,n,r,o){return e-=t,e=oc(e,1/n,r),o!==void 0&&(e=oc(e,1/o,r)),e}function tj(e,t=0,n=1,r=.5,o,s=e,a=e){if(Qr.test(t)&&(t=parseFloat(t),t=Qt(a.min,a.max,t/100)-a.min),typeof t!="number")return;let c=Qt(s.min,s.max,r);e===s&&(c-=t),e.min=jI(e.min,t,n,c,o),e.max=jI(e.max,t,n,c,o)}function DI(e,t,[n,r,o],s,a){tj(e,t[n],t[r],t[o],t.scale,s,a)}const nj=["x","scaleX","originX"],rj=["y","scaleY","originY"];function MI(e,t,n,r){DI(e.x,t,nj,n?n.x:void 0,r?r.x:void 0),DI(e.y,t,rj,n?n.y:void 0,r?r.y:void 0)}function kI(e){return e.translate===0&&e.scale===1}function RI(e){return kI(e.x)&&kI(e.y)}function oj(e,t){return e.x.min===t.x.min&&e.x.max===t.x.max&&e.y.min===t.y.min&&e.y.max===t.y.max}function FI(e,t){return Math.round(e.x.min)===Math.round(t.x.min)&&Math.round(e.x.max)===Math.round(t.x.max)&&Math.round(e.y.min)===Math.round(t.y.min)&&Math.round(e.y.max)===Math.round(t.y.max)}function LI(e){return Sn(e.x)/Sn(e.y)}class ij{constructor(){this.members=[]}add(t){Ld(this.members,t),t.scheduleRender()}remove(t){if(Nd(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(o=>t===o);if(n===0)return!1;let r;for(let o=n;o>=0;o--){const s=this.members[o];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:o}=t.options;o===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function NI(e,t,n){let r="";const o=e.x.translate/t.x,s=e.y.translate/t.y;if((o||s)&&(r=`translate3d(${o}px, ${s}px, 0) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{rotate:u,rotateX:A,rotateY:p}=n;u&&(r+=`rotate(${u}deg) `),A&&(r+=`rotateX(${A}deg) `),p&&(r+=`rotateY(${p}deg) `)}const a=e.x.scale*t.x,c=e.y.scale*t.y;return(a!==1||c!==1)&&(r+=`scale(${a}, ${c})`),r||"none"}const sj=(e,t)=>e.depth-t.depth;class aj{constructor(){this.children=[],this.isDirty=!1}add(t){Ld(this.children,t),this.isDirty=!0}remove(t){Nd(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(sj),this.isDirty=!1,this.children.forEach(t)}}function lj(e,t){const n=performance.now(),r=({timestamp:o})=>{const s=o-n;s>=t&&(Vr(r),e(s-t))};return ht.read(r,!0),()=>Vr(r)}function cj(e){window.MotionDebug&&window.MotionDebug.record(e)}function uj(e){return e instanceof SVGElement&&e.tagName!=="svg"}function Aj(e,t,n){const r=hn(e)?e:Ji(e);return r.start(Fd("",r,t,n)),r.animation}const VI=["","X","Y","Z"],dj={visibility:"hidden"},HI=1e3;let gj=0;const ti={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0};function zI({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(a={},c=t==null?void 0:t()){this.id=gj++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,ti.totalNodes=ti.resolvedTargetDeltas=ti.recalculatedProjection=0,this.nodes.forEach(hj),this.nodes.forEach(Bj),this.nodes.forEach(vj),this.nodes.forEach(Cj),cj(ti)},this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=a,this.root=c?c.root||c:this,this.path=c?[...c.path,c]:[],this.parent=c,this.depth=c?c.depth+1:0;for(let u=0;u<this.path.length;u++)this.path[u].shouldResetTransform=!0;this.root===this&&(this.nodes=new aj)}addEventListener(a,c){return this.eventHandlers.has(a)||this.eventHandlers.set(a,new Vd),this.eventHandlers.get(a).add(c)}notifyListeners(a,...c){const u=this.eventHandlers.get(a);u&&u.notify(...c)}hasListeners(a){return this.eventHandlers.has(a)}mount(a,c=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=uj(a),this.instance=a;const{layoutId:u,layout:A,visualElement:p}=this.options;if(p&&!p.current&&p.mount(a),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),c&&(A||u)&&(this.isLayoutDirty=!0),e){let h;const C=()=>this.root.updateBlockedByResize=!1;e(a,()=>{this.root.updateBlockedByResize=!0,h&&h(),h=lj(C,250),sc.hasAnimatedSinceResize&&(sc.hasAnimatedSinceResize=!1,this.nodes.forEach(UI))})}u&&this.root.registerSharedNode(u,this),this.options.animate!==!1&&p&&(u||A)&&this.addEventListener("didUpdate",({delta:h,hasLayoutChanged:C,hasRelativeTargetChanged:E,layout:m})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const B=this.options.transition||p.getDefaultTransition()||wj,{onLayoutAnimationStart:v,onLayoutAnimationComplete:S}=p.getProps(),M=!this.targetLayout||!FI(this.targetLayout,m)||E,x=!C&&E;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||x||C&&(M||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(h,x);const O={...Rd(B,"layout"),onPlay:v,onComplete:S};(p.shouldReduceMotion||this.options.layoutRoot)&&(O.delay=0,O.type=!1),this.startAnimation(O)}else C||UI(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=m})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const a=this.getStack();a&&a.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Vr(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(yj),this.animationId++)}getTransformTemplate(){const{visualElement:a}=this.options;return a&&a.getProps().transformTemplate}willUpdate(a=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let p=0;p<this.path.length;p++){const h=this.path[p];h.shouldResetTransform=!0,h.updateScroll("snapshot"),h.options.layoutRoot&&h.willUpdate(!1)}const{layoutId:c,layout:u}=this.options;if(c===void 0&&!u)return;const A=this.getTransformTemplate();this.prevTransformTemplateValue=A?A(this.latestValues,""):void 0,this.updateSnapshot(),a&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(WI);return}this.isUpdating||this.nodes.forEach(Ij),this.isUpdating=!1,this.nodes.forEach(mj),this.nodes.forEach(fj),this.nodes.forEach(pj),this.clearAllSnapshots();const c=performance.now();$t.delta=Ao(0,1e3/60,c-$t.timestamp),$t.timestamp=c,$t.isProcessing=!0,Id.update.process($t),Id.preRender.process($t),Id.render.process($t),$t.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,queueMicrotask(()=>this.update()))}clearAllSnapshots(){this.nodes.forEach(Ej),this.sharedNodes.forEach(bj)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,ht.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){ht.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let u=0;u<this.path.length;u++)this.path[u].updateScroll();const a=this.layout;this.layout=this.measure(!1),this.layoutCorrected=Nt(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:c}=this.options;c&&c.notify("LayoutMeasure",this.layout.layoutBox,a?a.layoutBox:void 0)}updateScroll(a="measure"){let c=!!(this.options.layoutScroll&&this.instance);this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===a&&(c=!1),c&&(this.scroll={animationId:this.root.animationId,phase:a,isRoot:r(this.instance),offset:n(this.instance)})}resetTransform(){if(!o)return;const a=this.isLayoutDirty||this.shouldResetTransform,c=this.projectionDelta&&!RI(this.projectionDelta),u=this.getTransformTemplate(),A=u?u(this.latestValues,""):void 0,p=A!==this.prevTransformTemplateValue;a&&(c||ei(this.latestValues)||p)&&(o(this.instance,A),this.shouldResetTransform=!1,this.scheduleRender())}measure(a=!0){const c=this.measurePageBox();let u=this.removeElementScroll(c);return a&&(u=this.removeTransform(u)),Tj(u),{animationId:this.root.animationId,measuredBox:c,layoutBox:u,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:a}=this.options;if(!a)return Nt();const c=a.measureViewportBox(),{scroll:u}=this.root;return u&&(Eo(c.x,u.offset.x),Eo(c.y,u.offset.y)),c}removeElementScroll(a){const c=Nt();Kn(c,a);for(let u=0;u<this.path.length;u++){const A=this.path[u],{scroll:p,options:h}=A;if(A!==this.root&&p&&h.layoutScroll){if(p.isRoot){Kn(c,a);const{scroll:C}=this.root;C&&(Eo(c.x,-C.offset.x),Eo(c.y,-C.offset.y))}Eo(c.x,p.offset.x),Eo(c.y,p.offset.y)}}return c}applyTransform(a,c=!1){const u=Nt();Kn(u,a);for(let A=0;A<this.path.length;A++){const p=this.path[A];!c&&p.options.layoutScroll&&p.scroll&&p!==p.root&&Zi(u,{x:-p.scroll.offset.x,y:-p.scroll.offset.y}),ei(p.latestValues)&&Zi(u,p.latestValues)}return ei(this.latestValues)&&Zi(u,this.latestValues),u}removeTransform(a){const c=Nt();Kn(c,a);for(let u=0;u<this.path.length;u++){const A=this.path[u];if(!A.instance||!ei(A.latestValues))continue;Jd(A.latestValues)&&A.updateSnapshot();const p=Nt(),h=A.measurePageBox();Kn(p,h),MI(c,A.latestValues,A.snapshot?A.snapshot.layoutBox:void 0,p)}return ei(this.latestValues)&&MI(c,this.latestValues),c}setTargetDelta(a){this.targetDelta=a,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(a){this.options={...this.options,...a,crossfade:a.crossfade!==void 0?a.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==$t.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(a=!1){var c;const u=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=u.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=u.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=u.isSharedProjectionDirty);const A=!!this.resumingFrom||this!==u;if(!(a||A&&this.isSharedProjectionDirty||this.isProjectionDirty||!((c=this.parent)===null||c===void 0)&&c.isProjectionDirty||this.attemptToResolveRelativeTarget))return;const{layout:h,layoutId:C}=this.options;if(!(!this.layout||!(h||C))){if(this.resolvedRelativeTargetAt=$t.timestamp,!this.targetDelta&&!this.relativeTarget){const E=this.getClosestProjectingParent();E&&E.layout&&this.animationProgress!==1?(this.relativeParent=E,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Nt(),this.relativeTargetOrigin=Nt(),la(this.relativeTargetOrigin,this.layout.layoutBox,E.layout.layoutBox),Kn(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=Nt(),this.targetWithTransforms=Nt()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),S4(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Kn(this.target,this.layout.layoutBox),EI(this.target,this.targetDelta)):Kn(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const E=this.getClosestProjectingParent();E&&!!E.resumingFrom==!!this.resumingFrom&&!E.options.layoutScroll&&E.target&&this.animationProgress!==1?(this.relativeParent=E,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Nt(),this.relativeTargetOrigin=Nt(),la(this.relativeTargetOrigin,this.target,E.target),Kn(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}ti.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||Jd(this.parent.latestValues)||pI(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var a;const c=this.getLead(),u=!!this.resumingFrom||this!==c;let A=!0;if((this.isProjectionDirty||!((a=this.parent)===null||a===void 0)&&a.isProjectionDirty)&&(A=!1),u&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(A=!1),this.resolvedRelativeTargetAt===$t.timestamp&&(A=!1),A)return;const{layout:p,layoutId:h}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(p||h))return;Kn(this.layoutCorrected,this.layout.layoutBox);const C=this.treeScale.x,E=this.treeScale.y;L4(this.layoutCorrected,this.treeScale,this.path,u),c.layout&&!c.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(c.target=c.layout.layoutBox);const{target:m}=c;if(!m){this.projectionTransform&&(this.projectionDelta=Xi(),this.projectionTransform="none",this.scheduleRender());return}this.projectionDelta||(this.projectionDelta=Xi(),this.projectionDeltaWithTransform=Xi());const B=this.projectionTransform;aa(this.projectionDelta,this.layoutCorrected,m,this.latestValues),this.projectionTransform=NI(this.projectionDelta,this.treeScale),(this.projectionTransform!==B||this.treeScale.x!==C||this.treeScale.y!==E)&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",m)),ti.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(a=!0){if(this.options.scheduleRender&&this.options.scheduleRender(),a){const c=this.getStack();c&&c.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}setAnimationOrigin(a,c=!1){const u=this.snapshot,A=u?u.latestValues:{},p={...this.latestValues},h=Xi();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!c;const C=Nt(),E=u?u.source:void 0,m=this.layout?this.layout.source:void 0,B=E!==m,v=this.getStack(),S=!v||v.members.length<=1,M=!!(B&&!S&&this.options.crossfade===!0&&!this.path.some(xj));this.animationProgress=0;let x;this.mixTargetDelta=O=>{const P=O/1e3;YI(h.x,a.x,P),YI(h.y,a.y,P),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(la(C,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Qj(this.relativeTarget,this.relativeTargetOrigin,C,P),x&&oj(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=Nt()),Kn(x,this.relativeTarget)),B&&(this.animationValues=p,q4(p,A,this.latestValues,P,M,S)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=P},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(a){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(Vr(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ht.update(()=>{sc.hasAnimatedSinceResize=!0,this.currentAnimation=Aj(0,HI,{...a,onUpdate:c=>{this.mixTargetDelta(c),a.onUpdate&&a.onUpdate(c)},onComplete:()=>{a.onComplete&&a.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const a=this.getStack();a&&a.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(HI),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const a=this.getLead();let{targetWithTransforms:c,target:u,layout:A,latestValues:p}=a;if(!(!c||!u||!A)){if(this!==a&&this.layout&&A&&ZI(this.options.animationType,this.layout.layoutBox,A.layoutBox)){u=this.target||Nt();const h=Sn(this.layout.layoutBox.x);u.x.min=a.target.x.min,u.x.max=u.x.min+h;const C=Sn(this.layout.layoutBox.y);u.y.min=a.target.y.min,u.y.max=u.y.min+C}Kn(c,u),Zi(c,p),aa(this.projectionDeltaWithTransform,this.layoutCorrected,c,p)}}registerSharedNode(a,c){this.sharedNodes.has(a)||this.sharedNodes.set(a,new ij),this.sharedNodes.get(a).add(c);const A=c.options.initialPromotionConfig;c.promote({transition:A?A.transition:void 0,preserveFollowOpacity:A&&A.shouldPreserveFollowOpacity?A.shouldPreserveFollowOpacity(c):void 0})}isLead(){const a=this.getStack();return a?a.lead===this:!0}getLead(){var a;const{layoutId:c}=this.options;return c?((a=this.getStack())===null||a===void 0?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:c}=this.options;return c?(a=this.getStack())===null||a===void 0?void 0:a.prevLead:void 0}getStack(){const{layoutId:a}=this.options;if(a)return this.root.sharedNodes.get(a)}promote({needsReset:a,transition:c,preserveFollowOpacity:u}={}){const A=this.getStack();A&&A.promote(this,u),a&&(this.projectionDelta=void 0,this.needsReset=!0),c&&this.setOptions({transition:c})}relegate(){const a=this.getStack();return a?a.relegate(this):!1}resetRotation(){const{visualElement:a}=this.options;if(!a)return;let c=!1;const{latestValues:u}=a;if((u.rotate||u.rotateX||u.rotateY||u.rotateZ)&&(c=!0),!c)return;const A={};for(let p=0;p<VI.length;p++){const h="rotate"+VI[p];u[h]&&(A[h]=u[h],a.setStaticValue(h,0))}a.render();for(const p in A)a.setStaticValue(p,A[p]);a.scheduleRender()}getProjectionStyles(a){var c,u;if(!this.instance||this.isSVG)return;if(!this.isVisible)return dj;const A={visibility:""},p=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,A.opacity="",A.pointerEvents=Xl(a==null?void 0:a.pointerEvents)||"",A.transform=p?p(this.latestValues,""):"none",A;const h=this.getLead();if(!this.projectionDelta||!this.layout||!h.target){const B={};return this.options.layoutId&&(B.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,B.pointerEvents=Xl(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!ei(this.latestValues)&&(B.transform=p?p({},""):"none",this.hasProjected=!1),B}const C=h.animationValues||h.latestValues;this.applyTransformsToTarget(),A.transform=NI(this.projectionDeltaWithTransform,this.treeScale,C),p&&(A.transform=p(C,A.transform));const{x:E,y:m}=this.projectionDelta;A.transformOrigin=`${E.origin*100}% ${m.origin*100}% 0`,h.animationValues?A.opacity=h===this?(u=(c=C.opacity)!==null&&c!==void 0?c:this.latestValues.opacity)!==null&&u!==void 0?u:1:this.preserveOpacity?this.latestValues.opacity:C.opacityExit:A.opacity=h===this?C.opacity!==void 0?C.opacity:"":C.opacityExit!==void 0?C.opacityExit:0;for(const B in Ul){if(C[B]===void 0)continue;const{correct:v,applyTo:S}=Ul[B],M=A.transform==="none"?C[B]:v(C[B],h);if(S){const x=S.length;for(let O=0;O<x;O++)A[S[O]]=M}else A[B]=M}return this.options.layoutId&&(A.pointerEvents=h===this?Xl(a==null?void 0:a.pointerEvents)||"":"none"),A}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(a=>{var c;return(c=a.currentAnimation)===null||c===void 0?void 0:c.stop()}),this.root.nodes.forEach(WI),this.root.sharedNodes.clear()}}}function fj(e){e.updateLayout()}function pj(e){var t;const n=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:o}=e.layout,{animationType:s}=e.options,a=n.source!==e.layout.source;s==="size"?Gn(h=>{const C=a?n.measuredBox[h]:n.layoutBox[h],E=Sn(C);C.min=r[h].min,C.max=C.min+E}):ZI(s,n.layoutBox,r)&&Gn(h=>{const C=a?n.measuredBox[h]:n.layoutBox[h],E=Sn(r[h]);C.max=C.min+E,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[h].max=e.relativeTarget[h].min+E)});const c=Xi();aa(c,r,n.layoutBox);const u=Xi();a?aa(u,e.applyTransform(o,!0),n.measuredBox):aa(u,r,n.layoutBox);const A=!RI(c);let p=!1;if(!e.resumeFrom){const h=e.getClosestProjectingParent();if(h&&!h.resumeFrom){const{snapshot:C,layout:E}=h;if(C&&E){const m=Nt();la(m,n.layoutBox,C.layoutBox);const B=Nt();la(B,r,E.layoutBox),FI(m,B)||(p=!0),h.options.layoutRoot&&(e.relativeTarget=B,e.relativeTargetOrigin=m,e.relativeParent=h)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:u,layoutDelta:c,hasLayoutChanged:A,hasRelativeTargetChanged:p})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function hj(e){ti.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Cj(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Ej(e){e.clearSnapshot()}function WI(e){e.clearMeasurements()}function Ij(e){e.isLayoutDirty=!1}function mj(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function UI(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Bj(e){e.resolveTargetDelta()}function vj(e){e.calcProjection()}function yj(e){e.resetRotation()}function bj(e){e.removeLeadSnapshot()}function YI(e,t,n){e.translate=Qt(t.translate,0,n),e.scale=Qt(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function GI(e,t,n,r){e.min=Qt(t.min,n.min,r),e.max=Qt(t.max,n.max,r)}function Qj(e,t,n,r){GI(e.x,t.x,n.x,r),GI(e.y,t.y,n.y,r)}function xj(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const wj={duration:.45,ease:[.4,0,.1,1]},KI=e=>typeof navigator<"u"&&navigator.userAgent.toLowerCase().includes(e),JI=KI("applewebkit/")&&!KI("chrome/")?Math.round:Pt;function XI(e){e.min=JI(e.min),e.max=JI(e.max)}function Tj(e){XI(e.x),XI(e.y)}function ZI(e,t,n){return e==="position"||e==="preserve-aspect"&&!Yd(LI(t),LI(n),.2)}const Sj=zI({attachResizeListener:(e,t)=>Hr(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Zd={current:void 0},_I=zI({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Zd.current){const e=new Sj({});e.mount(window),e.setOptions({layoutScroll:!0}),Zd.current=e}return Zd.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Pj={pan:{Feature:G4},drag:{Feature:Y4,ProjectionNode:_I,MeasureLayout:QI}},Oj=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;function jj(e){const t=Oj.exec(e);if(!t)return[,];const[,n,r]=t;return[n,r]}const Dj=4;function _d(e,t,n=1){gr(n<=Dj,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,o]=jj(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const a=s.trim();return ZE(a)?parseFloat(a):a}else return dd(o)?_d(o,t,n+1):o}function Mj(e,{...t},n){const r=e.current;if(!(r instanceof Element))return{target:t,transitionEnd:n};n&&(n={...n}),e.values.forEach(o=>{const s=o.get();if(!dd(s))return;const a=_d(s,r);a&&o.set(a)});for(const o in t){const s=t[o];if(!dd(s))continue;const a=_d(s,r);a&&(t[o]=a,n||(n={}),n[o]===void 0&&(n[o]=s))}return{target:t,transitionEnd:n}}const kj=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),qI=e=>kj.has(e),Rj=e=>Object.keys(e).some(qI),ac=e=>e===_o||e===ke,$I=(e,t)=>parseFloat(e.split(", ")[t]),em=(e,t)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;const o=r.match(/^matrix3d\((.+)\)$/);if(o)return $I(o[1],t);{const s=r.match(/^matrix\((.+)\)$/);return s?$I(s[1],e):0}},Fj=new Set(["x","y","z"]),Lj=_s.filter(e=>!Fj.has(e));function Nj(e){const t=[];return Lj.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t.length&&e.render(),t}const _i={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:em(4,13),y:em(5,14)};_i.translateX=_i.x,_i.translateY=_i.y;const Vj=(e,t,n)=>{const r=t.measureViewportBox(),o=t.current,s=getComputedStyle(o),{display:a}=s,c={};a==="none"&&t.setStaticValue("display",e.display||"block"),n.forEach(A=>{c[A]=_i[A](r,s)}),t.render();const u=t.measureViewportBox();return n.forEach(A=>{const p=t.getValue(A);p&&p.jump(c[A]),e[A]=_i[A](u,s)}),e},Hj=(e,t,n={},r={})=>{t={...t},r={...r};const o=Object.keys(t).filter(qI);let s=[],a=!1;const c=[];if(o.forEach(u=>{const A=e.getValue(u);if(!e.hasValue(u))return;let p=n[u],h=sa(p);const C=t[u];let E;if(Jl(C)){const m=C.length,B=C[0]===null?1:0;p=C[B],h=sa(p);for(let v=B;v<m&&C[v]!==null;v++)E?gr(sa(C[v])===E,"All keyframes must be of the same type"):(E=sa(C[v]),gr(E===h||ac(h)&&ac(E),"Keyframes must be of the same dimension as the current value"))}else E=sa(C);if(h!==E)if(ac(h)&&ac(E)){const m=A.get();typeof m=="string"&&A.set(parseFloat(m)),typeof C=="string"?t[u]=parseFloat(C):Array.isArray(C)&&E===ke&&(t[u]=C.map(parseFloat))}else h!=null&&h.transform&&(E!=null&&E.transform)&&(p===0||C===0)?p===0?A.set(E.transform(p)):t[u]=h.transform(C):(a||(s=Nj(e),a=!0),c.push(u),r[u]=r[u]!==void 0?r[u]:t[u],A.jump(C))}),c.length){const u=c.indexOf("height")>=0?window.pageYOffset:null,A=Vj(t,e,c);return s.length&&s.forEach(([p,h])=>{e.getValue(p).set(h)}),e.render(),Hl&&u!==null&&window.scrollTo({top:u}),{target:A,transitionEnd:r}}else return{target:t,transitionEnd:r}};function zj(e,t,n,r){return Rj(t)?Hj(e,t,n,r):{target:t,transitionEnd:r}}const Wj=(e,t,n,r)=>{const o=Mj(e,t,r);return t=o.target,r=o.transitionEnd,zj(e,t,n,r)},qd={current:null},tm={current:!1};function Uj(){if(tm.current=!0,!!Hl)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>qd.current=e.matches;e.addListener(t),t()}else qd.current=!1}function Yj(e,t,n){const{willChange:r}=t;for(const o in t){const s=t[o],a=n[o];if(hn(s))e.addValue(o,s),rc(r)&&r.add(o),process.env.NODE_ENV==="development"&&Hd(s.version==="10.18.0",`Attempting to mix Framer Motion versions ${s.version} with 10.18.0 may not work as expected.`);else if(hn(a))e.addValue(o,Ji(s,{owner:e})),rc(r)&&r.remove(o);else if(a!==s)if(e.hasValue(o)){const c=e.getValue(o);!c.hasAnimated&&c.set(s)}else{const c=e.getStaticValue(o);e.addValue(o,Ji(c!==void 0?c:s,{owner:e}))}}for(const o in n)t[o]===void 0&&e.removeValue(o);return t}const nm=new WeakMap,rm=Object.keys(Zs),Gj=rm.length,om=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],Kj=ud.length;class Jj{constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:o,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.scheduleRender=()=>ht.render(this.render,!1,!0);const{latestValues:c,renderState:u}=s;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=a,this.isControllingVariants=Wl(n),this.isVariantNode=FC(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:A,...p}=this.scrapeMotionValuesFromProps(n,{});for(const h in p){const C=p[h];c[h]!==void 0&&hn(C)&&(C.set(c[h],!1),rc(A)&&A.add(h))}}scrapeMotionValuesFromProps(t,n){return{}}mount(t){this.current=t,nm.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),tm.current||Uj(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:qd.current,process.env.NODE_ENV!=="production"&&Hd(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){nm.delete(this.current),this.projection&&this.projection.unmount(),Vr(this.notifyUpdate),Vr(this.render),this.valueSubscriptions.forEach(t=>t()),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features)this.features[t].unmount();this.current=null}bindToMotionValue(t,n){const r=Zo.has(t),o=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&ht.update(this.notifyUpdate,!1,!0),r&&this.projection&&(this.projection.isTransformDirty=!0)}),s=n.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{o(),s()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}loadFeatures({children:t,...n},r,o,s){let a,c;if(process.env.NODE_ENV!=="production"&&o&&r){const u="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";n.ignoreStrict?na(!1,u):gr(!1,u)}for(let u=0;u<Gj;u++){const A=rm[u],{isEnabled:p,Feature:h,ProjectionNode:C,MeasureLayout:E}=Zs[A];C&&(a=C),p(n)&&(!this.features[A]&&h&&(this.features[A]=new h(this)),E&&(c=E))}if((this.type==="html"||this.type==="svg")&&!this.projection&&a){this.projection=new a(this.latestValues,this.parent&&this.parent.projection);const{layoutId:u,layout:A,drag:p,dragConstraints:h,layoutScroll:C,layoutRoot:E}=n;this.projection.setOptions({layoutId:u,layout:A,alwaysMeasureLayout:!!p||h&&Gi(h),visualElement:this,scheduleRender:()=>this.scheduleRender(),animationType:typeof A=="string"?A:"both",initialPromotionConfig:s,layoutScroll:C,layoutRoot:E})}return c}updateFeatures(){for(const t in this.features){const n=this.features[t];n.isMounted?n.update():(n.mount(),n.isMounted=!0)}}triggerBuild(){this.build(this.renderState,this.latestValues,this.options,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Nt()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}makeTargetAnimatable(t,n=!0){return this.makeTargetAnimatableFromInstance(t,this.props,n)}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<om.length;r++){const o=om[r];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);const s=t["on"+o];s&&(this.propEventSubscriptions[o]=this.on(o,s))}this.prevMotionValues=Yj(this,this.scrapeMotionValuesFromProps(t,this.prevProps),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}getVariantContext(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){const r=this.parent?this.parent.getVariantContext()||{}:{};return this.props.initial!==void 0&&(r.initial=this.props.initial),r}const n={};for(let r=0;r<Kj;r++){const o=ud[r],s=this.props[o];(Xs(s)||s===!1)&&(n[o]=s)}return n}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){n!==this.values.get(t)&&(this.removeValue(t),this.bindToMotionValue(t,n)),this.values.set(t,n),this.latestValues[t]=n.get()}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Ji(n,{owner:this}),this.addValue(t,r)),r}readValue(t){var n;return this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options)}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:r}=this.props,o=typeof r=="string"||typeof r=="object"?(n=Ed(this.props,r))===null||n===void 0?void 0:n[t]:void 0;if(r&&o!==void 0)return o;const s=this.getBaseTargetFromProps(this.props,t);return s!==void 0&&!hn(s)?s:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Vd),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class im extends Jj{sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}makeTargetAnimatableFromInstance({transition:t,transitionEnd:n,...r},{transformValues:o},s){let a=u4(r,t||{},this);if(o&&(n&&(n=o(n)),r&&(r=o(r)),a&&(a=o(a))),s){l4(this,r,a);const c=Wj(this,r,a,n);n=c.transitionEnd,r=c.target}return{transition:t,transitionEnd:n,...r}}}function Xj(e){return window.getComputedStyle(e)}class Zj extends im{constructor(){super(...arguments),this.type="html"}readValueFromInstance(t,n){if(Zo.has(n)){const r=kd(n);return r&&r.default||0}else{const r=Xj(t),o=(UC(n)?r.getPropertyValue(n):r[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return BI(t,n)}build(t,n,r,o){gd(t,n,r,o.transformTemplate)}scrapeMotionValuesFromProps(t,n){return Cd(t,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;hn(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}renderInstance(t,n,r,o){$C(t,n,r,o)}}class _j extends im{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Zo.has(n)){const r=kd(n);return r&&r.default||0}return n=eE.has(n)?n:ld(n),t.getAttribute(n)}measureInstanceViewportBox(){return Nt()}scrapeMotionValuesFromProps(t,n){return nE(t,n)}build(t,n,r,o){pd(t,n,r,this.isSVGTag,o.transformTemplate)}renderInstance(t,n,r,o){tE(t,n,r,o)}mount(t){this.isSVGTag=hd(t.tagName),super.mount(t)}}const qj=(e,t)=>Ad(e)?new _j(t,{enableHardwareAcceleration:!1}):new Zj(t,{enableHardwareAcceleration:!0}),$j={...Q4,...XP,...Pj,...{layout:{ProjectionNode:_I,MeasureLayout:QI}}},lc=rP((e,t)=>RP(e,t,$j,qj)),eD=(e,t,n)=>{const r=t-e;return((n-e)%r+r)%r+e};function sm(...e){const t=Q.useRef(0),[n,r]=Q.useState(e[t.current]),o=Q.useCallback(s=>{t.current=typeof s!="number"?eD(0,e.length,t.current+1):s,r(e[t.current])},[e.length,...e]);return[n,o]}function am({children:e,type:t="scale",direction:n="right",offset:r=10,scale:o={hover:1.05,tap:.95}}){let s,a;switch(n){case"up":case"left":s=r,a=0;break;case"right":case"down":default:s=0,a=r;break}const[c,u]=sm(s,a),[A,p]=sm(s,a);switch(t){case"rotate":return g.jsx(lc.div,{animate:{rotate:360},transition:{repeat:1/0,repeatType:"loop",duration:2,repeatDelay:0},children:e});case"slide":return n==="up"||n==="down"?g.jsx(lc.div,{animate:{y:A!==void 0?A:""},onHoverEnd:()=>p(),onHoverStart:()=>p(),children:e}):g.jsx(lc.div,{animate:{x:c!==void 0?c:""},onHoverEnd:()=>u(),onHoverStart:()=>u(),children:e});case"scale":default:return typeof o=="number"&&(o={hover:o,tap:o}),g.jsx(lc.div,{whileHover:{scale:o==null?void 0:o.hover},whileTap:{scale:o==null?void 0:o.tap},children:e})}}am.propTypes={children:f.node,offset:f.number,type:f.oneOf(["slide","scale","rotate"]),direction:f.oneOf(["up","down","left","right"]),scale:f.oneOfType([f.number,f.object])};function tD(e){return Dt("MuiSvgIcon",e)}Ft("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const nD=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],rD=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Oe(t)}`,`fontSize${Oe(n)}`]};return qt(o,tD,r)},oD=Ae("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Oe(n.color)}`],t[`fontSize${Oe(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,a,c,u,A,p,h,C,E,m;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(a=s.pxToRem)==null?void 0:a.call(s,20))||"1.25rem",medium:((c=e.typography)==null||(u=c.pxToRem)==null?void 0:u.call(c,24))||"1.5rem",large:((A=e.typography)==null||(p=A.pxToRem)==null?void 0:p.call(A,35))||"2.1875rem"}[t.fontSize],color:(h=(C=(e.vars||e).palette)==null||(C=C[t.color])==null?void 0:C.main)!=null?h:{action:(E=(e.vars||e).palette)==null||(E=E.action)==null?void 0:E.active,disabled:(m=(e.vars||e).palette)==null||(m=m.action)==null?void 0:m.disabled,inherit:void 0}[t.color]}}),$d=R.forwardRef(function(t,n){const r=Lt({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:a="inherit",component:c="svg",fontSize:u="medium",htmlColor:A,inheritViewBox:p=!1,titleAccess:h,viewBox:C="0 0 24 24"}=r,E=Ve(r,nD),m=R.isValidElement(o)&&o.type==="svg",B=W({},r,{color:a,component:c,fontSize:u,instanceFontSize:t.fontSize,inheritViewBox:p,viewBox:C,hasSvgAsChild:m}),v={};p||(v.viewBox=C);const S=rD(B);return g.jsxs(oD,W({as:c,className:Ue(S.root,s),focusable:"false",color:A,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n},v,E,m&&o.props,{ownerState:B,children:[m?o.props.children:o,h?g.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&($d.propTypes={children:f.node,classes:f.object,className:f.string,color:f.oneOfType([f.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),f.string]),component:f.elementType,fontSize:f.oneOfType([f.oneOf(["inherit","large","medium","small"]),f.string]),htmlColor:f.string,inheritViewBox:f.bool,shapeRendering:f.string,sx:f.oneOfType([f.arrayOf(f.oneOfType([f.func,f.object,f.bool])),f.func,f.object]),titleAccess:f.string,viewBox:f.string}),$d.muiName="SvgIcon";const lm=$d;function eg(e,t){function n(r,o){return g.jsx(lm,W({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=lm.muiName,R.memo(R.forwardRef(n))}const iD=eg(g.jsx("path",{d:"M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"}),"Person");function sD(e){return Dt("MuiAvatar",e)}Ft("MuiAvatar",["root","colorDefault","circular","rounded","square","img","fallback"]);const aD=["alt","children","className","component","imgProps","sizes","src","srcSet","variant"],lD=e=>{const{classes:t,variant:n,colorDefault:r}=e;return qt({root:["root",n,r&&"colorDefault"],img:["img"],fallback:["fallback"]},sD,t)},cD=Ae("div",{name:"MuiAvatar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],n.colorDefault&&t.colorDefault]}})(({theme:e,ownerState:t})=>W({position:"relative",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,width:40,height:40,fontFamily:e.typography.fontFamily,fontSize:e.typography.pxToRem(20),lineHeight:1,borderRadius:"50%",overflow:"hidden",userSelect:"none"},t.variant==="rounded"&&{borderRadius:(e.vars||e).shape.borderRadius},t.variant==="square"&&{borderRadius:0},t.colorDefault&&W({color:(e.vars||e).palette.background.default},e.vars?{backgroundColor:e.vars.palette.Avatar.defaultBg}:{backgroundColor:e.palette.mode==="light"?e.palette.grey[400]:e.palette.grey[600]}))),uD=Ae("img",{name:"MuiAvatar",slot:"Img",overridesResolver:(e,t)=>t.img})({width:"100%",height:"100%",textAlign:"center",objectFit:"cover",color:"transparent",textIndent:1e4}),AD=Ae(iD,{name:"MuiAvatar",slot:"Fallback",overridesResolver:(e,t)=>t.fallback})({width:"75%",height:"75%"});function dD({crossOrigin:e,referrerPolicy:t,src:n,srcSet:r}){const[o,s]=R.useState(!1);return R.useEffect(()=>{if(!n&&!r)return;s(!1);let a=!0;const c=new Image;return c.onload=()=>{a&&s("loaded")},c.onerror=()=>{a&&s("error")},c.crossOrigin=e,c.referrerPolicy=t,c.src=n,r&&(c.srcset=r),()=>{a=!1}},[e,t,n,r]),o}const cm=R.forwardRef(function(t,n){const r=Lt({props:t,name:"MuiAvatar"}),{alt:o,children:s,className:a,component:c="div",imgProps:u,sizes:A,src:p,srcSet:h,variant:C="circular"}=r,E=Ve(r,aD);let m=null;const B=dD(W({},u,{src:p,srcSet:h})),v=p||h,S=v&&B!=="error",M=W({},r,{colorDefault:!S,component:c,variant:C}),x=lD(M);return S?m=g.jsx(uD,W({alt:o,srcSet:h,src:p,sizes:A,ownerState:M,className:x.img},u)):s!=null?m=s:v&&o?m=o[0]:m=g.jsx(AD,{ownerState:M,className:x.fallback}),g.jsx(cD,W({as:c,ownerState:M,className:Ue(x.root,a),ref:n},E,{children:m}))});process.env.NODE_ENV!=="production"&&(cm.propTypes={alt:f.string,children:f.node,classes:f.object,className:f.string,component:f.elementType,imgProps:f.object,sizes:f.string,src:f.string,srcSet:f.string,sx:f.oneOfType([f.arrayOf(f.oneOfType([f.func,f.object,f.bool])),f.func,f.object]),variant:f.oneOfType([f.oneOf(["circular","rounded","square"]),f.string])});const gD=cm,en=(e,t)=>{switch(t){case"secondary":return e.palette.secondary;case"error":return e.palette.error;case"warning":return e.palette.warning;case"info":return e.palette.info;case"success":return e.palette.success;default:return e.palette.primary}};function fD({theme:e,color:t,type:n}){const r=en(e,t),{lighter:o,light:s,main:a,contrastText:c}=r;switch(n){case"filled":return{color:c,backgroundColor:a};case"outlined":return{color:a,border:"1px solid",borderColor:a,backgroundColor:"transparent"};case"combined":return{color:a,border:"1px solid",borderColor:s,backgroundColor:o};default:return{color:a,backgroundColor:o}}}function pD(e){switch(e){case"badge":return{border:"2px solid",fontSize:"0.675rem",width:20,height:20};case"xs":return{fontSize:"0.75rem",width:24,height:24};case"sm":return{fontSize:"0.875rem",width:32,height:32};case"lg":return{fontSize:"1.2rem",width:52,height:52};case"xl":return{fontSize:"1.5rem",width:64,height:64};case"md":default:return{fontSize:"1rem",width:40,height:40}}}const hD=Ae(gD,{shouldForwardProp:e=>e!=="color"&&e!=="type"&&e!=="size"})(({theme:e,variant:t,color:n,type:r,size:o})=>({...pD(o),...fD({variant:t,theme:e,color:n,type:r}),...o==="badge"&&{borderColor:e.palette.background.default}}));function ua({variant:e="circular",children:t,color:n="primary",type:r,size:o="md",...s}){const a=Bt();return g.jsx(hD,{variant:e,theme:a,color:n,type:r,size:o,...s,children:t})}ua.propTypes={children:f.node,color:f.string,type:f.string,size:f.string,variant:f.string};const um={p:2.5,"& .MuiCardHeader-action":{m:"0px auto",alignSelf:"center"}},Jn=Q.forwardRef(({border:e=!0,boxShadow:t,children:n,subheader:r,content:o=!0,contentSX:s={},darkTitle:a,divider:c=!0,elevation:u,secondary:A,shadow:p,sx:h={},title:C,modal:E=!1,color:m="default",...B},v)=>{const S=Bt();return t=S.palette.mode==="dark"?t||!0:t,g.jsxs(b.Card,{elevation:u||0,ref:v,...B,sx:{position:"relative",border:e?"1px solid":"none",borderRadius:1,borderColor:S.palette.mode==="dark"?S.palette.divider:S.palette.grey.A800,boxShadow:t&&(!e||S.palette.mode==="dark")?p||S.customShadows.z1:"inherit",":hover":{boxShadow:t?p||S.customShadows.z1:"inherit"},backgroundColor:m==="default"?S.palette.background.paper:Li(m==="primary"?S.palette.primary[100]:S.palette.secondary[100],.5),...E&&{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:{xs:"calc( 100% - 50px)",sm:"auto"},"& .MuiCardContent-root":{overflowY:"auto",minHeight:"auto",maxHeight:"calc(100vh - 200px)"}},...h},children:[!a&&C&&g.jsx(b.CardHeader,{sx:um,title:C,action:A,subheader:r}),a&&C&&g.jsx(b.CardHeader,{sx:um,title:g.jsx(b.Typography,{variant:"h4",children:C}),action:A}),C&&c&&g.jsx(b.Divider,{}),o&&g.jsx(b.CardContent,{sx:s,children:n}),!o&&n]})});Jn.propTypes={border:f.bool,boxShadow:f.bool,children:f.oneOfType([f.node,f.arrayOf(f.node)]),subheader:f.oneOfType([f.node,f.string]),content:f.bool,contentClass:f.string,contentSX:f.object,darkTitle:f.bool,divider:f.bool,elevation:f.number,secondary:f.oneOfType([f.node,f.string,f.object]),shadow:f.string,sx:f.object,title:f.oneOfType([f.node,f.string,f.object]),modal:f.bool,color:f.oneOf(["default","primary","secondary"])};function CD(e){return Dt("MuiTypography",e)}Ft("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const ED=["align","className","component","gutterBottom","noWrap","paragraph","variant","variantMapping"],ID=e=>{const{align:t,gutterBottom:n,noWrap:r,paragraph:o,variant:s,classes:a}=e,c={root:["root",s,e.align!=="inherit"&&`align${Oe(t)}`,n&&"gutterBottom",r&&"noWrap",o&&"paragraph"]};return qt(c,CD,a)},mD=Ae("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.variant&&t[n.variant],n.align!=="inherit"&&t[`align${Oe(n.align)}`],n.noWrap&&t.noWrap,n.gutterBottom&&t.gutterBottom,n.paragraph&&t.paragraph]}})(({theme:e,ownerState:t})=>W({margin:0},t.variant==="inherit"&&{font:"inherit"},t.variant!=="inherit"&&e.typography[t.variant],t.align!=="inherit"&&{textAlign:t.align},t.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t.gutterBottom&&{marginBottom:"0.35em"},t.paragraph&&{marginBottom:16})),Am={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},BD={primary:"primary.main",textPrimary:"text.primary",secondary:"secondary.main",textSecondary:"text.secondary",error:"error.main"},vD=e=>BD[e]||e,dm=R.forwardRef(function(t,n){const r=Lt({props:t,name:"MuiTypography"}),o=vD(r.color),s=Yw(W({},r,{color:o})),{align:a="inherit",className:c,component:u,gutterBottom:A=!1,noWrap:p=!1,paragraph:h=!1,variant:C="body1",variantMapping:E=Am}=s,m=Ve(s,ED),B=W({},s,{align:a,color:o,className:c,component:u,gutterBottom:A,noWrap:p,paragraph:h,variant:C,variantMapping:E}),v=u||(h?"p":E[C]||Am[C])||"span",S=ID(B);return g.jsx(mD,W({as:v,ref:n,ownerState:B,className:Ue(S.root,c)},m))});process.env.NODE_ENV!=="production"&&(dm.propTypes={align:f.oneOf(["center","inherit","justify","left","right"]),children:f.node,classes:f.object,className:f.string,component:f.elementType,gutterBottom:f.bool,noWrap:f.bool,paragraph:f.bool,sx:f.oneOfType([f.arrayOf(f.oneOfType([f.func,f.object,f.bool])),f.func,f.object]),variant:f.oneOfType([f.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),f.string]),variantMapping:f.object});const gm=dm,yD=eg(g.jsx("path",{d:"M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}),"MoreHoriz");function tg(e,t){return tg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},tg(e,t)}function ng(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,tg(e,t)}const fm={disabled:!1};var bD=process.env.NODE_ENV!=="production"?f.oneOfType([f.number,f.shape({enter:f.number,exit:f.number,appear:f.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&f.oneOfType([f.string,f.shape({enter:f.string,exit:f.string,active:f.string}),f.shape({enter:f.string,enterDone:f.string,enterActive:f.string,exit:f.string,exitDone:f.string,exitActive:f.string})]);const cc=Q.createContext(null);var QD=function(t){return t.scrollTop},Aa="unmounted",ni="exited",ri="entering",qi="entered",rg="exiting",Ur=function(e){ng(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var a=o,c=a&&!a.isMounting?r.enter:r.appear,u;return s.appearStatus=null,r.in?c?(u=ni,s.appearStatus=ri):u=qi:r.unmountOnExit||r.mountOnEnter?u=Aa:u=ni,s.state={status:u},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var a=o.in;return a&&s.status===Aa?{status:ni}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var a=this.state.status;this.props.in?a!==ri&&a!==qi&&(s=ri):(a===ri||a===qi)&&(s=rg)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,a,c;return s=a=c=o,o!=null&&typeof o!="number"&&(s=o.exit,a=o.enter,c=o.appear!==void 0?o.appear:a),{exit:s,enter:a,appear:c}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ri){if(this.props.unmountOnExit||this.props.mountOnEnter){var a=this.props.nodeRef?this.props.nodeRef.current:ji.findDOMNode(this);a&&QD(a)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===ni&&this.setState({status:Aa})},n.performEnter=function(o){var s=this,a=this.props.enter,c=this.context?this.context.isMounting:o,u=this.props.nodeRef?[c]:[ji.findDOMNode(this),c],A=u[0],p=u[1],h=this.getTimeouts(),C=c?h.appear:h.enter;if(!o&&!a||fm.disabled){this.safeSetState({status:qi},function(){s.props.onEntered(A)});return}this.props.onEnter(A,p),this.safeSetState({status:ri},function(){s.props.onEntering(A,p),s.onTransitionEnd(C,function(){s.safeSetState({status:qi},function(){s.props.onEntered(A,p)})})})},n.performExit=function(){var o=this,s=this.props.exit,a=this.getTimeouts(),c=this.props.nodeRef?void 0:ji.findDOMNode(this);if(!s||fm.disabled){this.safeSetState({status:ni},function(){o.props.onExited(c)});return}this.props.onExit(c),this.safeSetState({status:rg},function(){o.props.onExiting(c),o.onTransitionEnd(a.exit,function(){o.safeSetState({status:ni},function(){o.props.onExited(c)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,a=!0;return this.nextCallback=function(c){a&&(a=!1,s.nextCallback=null,o(c))},this.nextCallback.cancel=function(){a=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var a=this.props.nodeRef?this.props.nodeRef.current:ji.findDOMNode(this),c=o==null&&!this.props.addEndListener;if(!a||c){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var u=this.props.nodeRef?[this.nextCallback]:[a,this.nextCallback],A=u[0],p=u[1];this.props.addEndListener(A,p)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===Aa)return null;var s=this.props,a=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var c=Ve(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return Q.createElement(cc.Provider,{value:null},typeof a=="function"?a(o,c):Q.cloneElement(Q.Children.only(a),c))},t}(Q.Component);Ur.contextType=cc,Ur.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:f.shape({current:typeof Element>"u"?f.any:function(e,t,n,r,o,s){var a=e[t];return f.instanceOf(a&&"ownerDocument"in a?a.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:f.oneOfType([f.func.isRequired,f.element.isRequired]).isRequired,in:f.bool,mountOnEnter:f.bool,unmountOnExit:f.bool,appear:f.bool,enter:f.bool,exit:f.bool,timeout:function(t){var n=bD;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;s<r;s++)o[s-1]=arguments[s];return n.apply(void 0,[t].concat(o))},addEndListener:f.func,onEnter:f.func,onEntering:f.func,onEntered:f.func,onExit:f.func,onExiting:f.func,onExited:f.func}:{};function $i(){}Ur.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:$i,onEntering:$i,onEntered:$i,onExit:$i,onExiting:$i,onExited:$i},Ur.UNMOUNTED=Aa,Ur.EXITED=ni,Ur.ENTERING=ri,Ur.ENTERED=qi,Ur.EXITING=rg;const og=Ur;function xD(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ig(e,t){var n=function(s){return t&&Q.isValidElement(s)?t(s):s},r=Object.create(null);return e&&Q.Children.map(e,function(o){return o}).forEach(function(o){r[o.key]=n(o)}),r}function wD(e,t){e=e||{},t=t||{};function n(p){return p in t?t[p]:e[p]}var r=Object.create(null),o=[];for(var s in e)s in t?o.length&&(r[s]=o,o=[]):o.push(s);var a,c={};for(var u in t){if(r[u])for(a=0;a<r[u].length;a++){var A=r[u][a];c[r[u][a]]=n(A)}c[u]=n(u)}for(a=0;a<o.length;a++)c[o[a]]=n(o[a]);return c}function oi(e,t,n){return n[t]!=null?n[t]:e.props[t]}function TD(e,t){return ig(e.children,function(n){return Q.cloneElement(n,{onExited:t.bind(null,n),in:!0,appear:oi(n,"appear",e),enter:oi(n,"enter",e),exit:oi(n,"exit",e)})})}function SD(e,t,n){var r=ig(e.children),o=wD(t,r);return Object.keys(o).forEach(function(s){var a=o[s];if(Q.isValidElement(a)){var c=s in t,u=s in r,A=t[s],p=Q.isValidElement(A)&&!A.props.in;u&&(!c||p)?o[s]=Q.cloneElement(a,{onExited:n.bind(null,a),in:!0,exit:oi(a,"exit",e),enter:oi(a,"enter",e)}):!u&&c&&!p?o[s]=Q.cloneElement(a,{in:!1}):u&&c&&Q.isValidElement(A)&&(o[s]=Q.cloneElement(a,{onExited:n.bind(null,a),in:A.props.in,exit:oi(a,"exit",e),enter:oi(a,"enter",e)}))}}),o}var PD=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},OD={component:"div",childFactory:function(t){return t}},sg=function(e){ng(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var a=s.handleExited.bind(xD(s));return s.state={contextValue:{isMounting:!0},handleExited:a,firstRender:!0},s}var n=t.prototype;return n.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},n.componentWillUnmount=function(){this.mounted=!1},t.getDerivedStateFromProps=function(o,s){var a=s.children,c=s.handleExited,u=s.firstRender;return{children:u?TD(o,c):SD(o,a,c),firstRender:!1}},n.handleExited=function(o,s){var a=ig(this.props.children);o.key in a||(o.props.onExited&&o.props.onExited(s),this.mounted&&this.setState(function(c){var u=W({},c.children);return delete u[o.key],{children:u}}))},n.render=function(){var o=this.props,s=o.component,a=o.childFactory,c=Ve(o,["component","childFactory"]),u=this.state.contextValue,A=PD(this.state.children).map(a);return delete c.appear,delete c.enter,delete c.exit,s===null?Q.createElement(cc.Provider,{value:u},A):Q.createElement(cc.Provider,{value:u},Q.createElement(s,c,A))},t}(Q.Component);sg.propTypes=process.env.NODE_ENV!=="production"?{component:f.any,children:f.node,appear:f.bool,enter:f.bool,exit:f.bool,childFactory:f.func}:{},sg.defaultProps=OD;const jD=sg;function pm(e){const{className:t,classes:n,pulsate:r=!1,rippleX:o,rippleY:s,rippleSize:a,in:c,onExited:u,timeout:A}=e,[p,h]=R.useState(!1),C=Ue(t,n.ripple,n.rippleVisible,r&&n.ripplePulsate),E={width:a,height:a,top:-(a/2)+s,left:-(a/2)+o},m=Ue(n.child,p&&n.childLeaving,r&&n.childPulsate);return!c&&!p&&h(!0),R.useEffect(()=>{if(!c&&u!=null){const B=setTimeout(u,A);return()=>{clearTimeout(B)}}},[u,c,A]),g.jsx("span",{className:C,style:E,children:g.jsx("span",{className:m})})}process.env.NODE_ENV!=="production"&&(pm.propTypes={classes:f.object.isRequired,className:f.string,in:f.bool,onExited:f.func,pulsate:f.bool,rippleSize:f.number,rippleX:f.number,rippleY:f.number,timeout:f.number.isRequired});const Xn=Ft("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),DD=["center","classes","className"];let uc=e=>e,hm,Cm,Em,Im;const ag=550,MD=80,kD=Gt.keyframes(hm||(hm=uc`
101
101
  0% {
102
102
  transform: scale(0);
103
103
  opacity: 0.1;