1import{r as v}from"./react-vendor-CYeJtJt3.js";var Is={exports:{}},Jt={};/** 2 * @license React 3 * react-jsx-runtime.production.min.js 4 * 5 * Copyright (c) Facebook, Inc. and its affiliates. 6 * 7 * This source code is licensed under the MIT license found in the 8 * LICENSE file in the root directory of this source tree. 9 */var vr=v,xr=Symbol.for("react.element"),Tr=Symbol.for("react.fragment"),Pr=Object.prototype.hasOwnProperty,Sr=vr.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,br={key:!0,ref:!0,__self:!0,__source:!0};function Os(t,e,n){var s,i={},o=null,r=null;n!==void 0&&(o=""+n),e.key!==void 0&&(o=""+e.key),e.ref!==void 0&&(r=e.ref);for(s in e)Pr.call(e,s)&&!br.hasOwnProperty(s)&&(i[s]=e[s]);if(t&&t.defaultProps)for(s in e=t.defaultProps,e)i[s]===void 0&&(i[s]=e[s]);return{$$typeof:xr,type:t,key:o,ref:r,props:i,_owner:Sr.current}}Jt.Fragment=Tr;Jt.jsx=Os;Jt.jsxs=Os;Is.exports=Jt;var z=Is.exports;const je=v.createContext({});function Ne(t){const e=v.useRef(null);return e.current===null&&(e.current=t()),e.current}const Ue=typeof window<"u",js=Ue?v.useLayoutEffect:v.useEffect,Qt=v.createContext(null);function We(t,e){t.indexOf(e)===-1&&t.push(e)}function Ke(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}const X=(t,e,n)=>n>e?e:n<t?t:n;let Gt=()=>{};const Y={},Ns=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t);function Us(t){return typeof t=="object"&&t!==null}const Ws=t=>/^0[^.\s]+$/u.test(t);function $e(t){let e;return()=>(e===void 0&&(e=t()),e)}const K=t=>t,wr=(t,e)=>n=>e(t(n)),kt=(...t)=>t.reduce(wr),Ct=(t,e,n)=>{const s=e-t;return s===0?1:(n-t)/s};class _e{constructor(){this.subscriptions=[]}add(e){return We(this.subscriptions,e),()=>Ke(this.subscriptions,e)}notify(e,n,s){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](e,n,s);else for(let o=0;o<i;o++){const r=this.subscriptions[o];r&&r(e,n,s)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const _=t=>t*1e3,G=t=>t/1e3;function Ks(t,e){return e?t*(1e3/e):0}const $s=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,Ar=1e-7,Vr=12;function Cr(t,e,n,s,i){let o,r,a=0;do r=e+(n-e)/2,o=$s(r,s,i)-t,o>0?n=r:e=r;while(Math.abs(o)>Ar&&++a<Vr);return r}function Ft(t,e,n,s){if(t===e&&n===s)return K;const i=o=>Cr(o,0,1,t,n);return o=>o===0||o===1?o:$s(i(o),e,s)}const _s=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,Gs=t=>e=>1-t(1-e),Hs=Ft(.33,1.53,.69,.99),Ge=Gs(Hs),zs=_s(Ge),Xs=t=>(t*=2)<1?.5*Ge(t):.5*(2-Math.pow(2,-10*(t-1))),He=t=>1-Math.sin(Math.acos(t)),Ys=Gs(He),qs=_s(He),Mr=Ft(.42,0,1,1),Dr=Ft(0,0,.58,1),Zs=Ft(.42,0,.58,1),Rr=t=>Array.isArray(t)&&typeof t[0]!="number",Js=t=>Array.isArray(t)&&typeof t[0]=="number",Sn={linear:K,easeIn:Mr,easeInOut:Zs,easeOut:Dr,circIn:He,circInOut:qs,circOut:Ys,backIn:Ge,backInOut:zs,backOut:Hs,anticipate:Xs},Er=t=>typeof t=="string",bn=t=>{if(Js(t)){Gt(t.length===4);const[e,n,s,i]=t;return Ft(e,n,s,i)}else if(Er(t))return Gt(Sn[t]!==void 0),Sn[t];return t},Ot=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],wn={value:null,addProjectionMetrics:null};function Lr(t,e){let n=new Set,s=new Set,i=!1,o=!1;const r=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1},l=0;function c(h){r.has(h)&&(u.schedule(h),t()),l++,h(a)}const u={schedule:(h,f=!1,d=!1)=>{const p=d&&i?n:s;return f&&r.add(h),p.has(h)||p.add(h),h},cancel:h=>{s.delete(h),r.delete(h)},process:h=>{if(a=h,i){o=!0;return}
vendor: 13,033 bytes, line 9
9i=!0,[n,s]=[s,n],n.forEach(c),e&&wn.value&&wn.value.frameloop[e].push(l),l=0,n.clear(),i=!1,o&&(o=!1,u.process(h))}};return u}const kr=40;function Qs(t,e){let n=!1,s=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,r=Ot.reduce((y,w)=>(y[w]=Lr(o,e?w:void 0),y),{}),{setup:a,read:l,resolveKeyframes:c,preUpdate:u,update:h,preRender:f,render:d,postRender:m}=r,p=()=>{const y=Y.useManualTiming?i.timestamp:performance.now();n=!1,Y.useManualTiming||(i.delta=s?1e3/60:Math.max(Math.min(y-i.timestamp,kr),1)),i.timestamp=y,i.isProcessing=!0,a.process(i),l.process(i),c.process(i),u.process(i),h.process(i),f.process(i),d.process(i),m.process(i),i.isProcessing=!1,n&&e&&(s=!1,t(p))},x=()=>{n=!0,s=!0,i.isProcessing||t(p)};return{schedule:Ot.reduce((y,w)=>{const P=r[w];return y[w]=(A,V=!1,b=!1)=>(n||x(),P.schedule(A,V,b)),y},{}),cancel:y=>{for(let w=0;w<Ot.length;w++)r[Ot[w]].cancel(y)},state:i,steps:r}}const{schedule:C,cancel:J,state:F,steps:se}=Qs(typeof requestAnimationFrame<"u"?requestAnimationFrame:K,!0);let Wt;function Fr(){Wt=void 0}const j={now:()=>(Wt===void 0&&j.set(F.isProcessing||Y.useManualTiming?F.timestamp:performance.now()),Wt),set:t=>{Wt=t,queueMicrotask(Fr)}},ti=t=>e=>typeof e=="string"&&e.startsWith(t),ze=ti("--"),Br=ti("var(--"),Xe=t=>Br(t)?Ir.test(t.split("/*")[0].trim()):!1,Ir=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,yt={test:t=>typeof t=="number",parse:parseFloat,transform:t=>t},Mt={...yt,transform:t=>X(0,1,t)},jt={...yt,default:1},St=t=>Math.round(t*1e5)/1e5,Ye=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Or(t){return t==null}const jr=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,qe=(t,e)=>n=>!!(typeof n=="string"&&jr.test(n)&&n.startsWith(t)||e&&!Or(n)&&Object.prototype.hasOwnProperty.call(n,e)),ei=(t,e,n)=>s=>{if(typeof s!="string")return s;const[i,o,r,a]=s.match(Ye);return{[t]:parseFloat(i),[e]:parseFloat(o),[n]:parseFloat(r),alpha:a!==void 0?parseFloat(a):1}},Nr=t=>X(0,255,t),ie={...yt,transform:t=>Math.round(Nr(t))},it={test:qe("rgb","red"),parse:ei("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:s=1})=>"rgba("+ie.transform(t)+", "+ie.transform(e)+", "+ie.transform(n)+", "+St(Mt.transform(s))+")"};function Ur(t){let e="",n="",s="",i="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),s=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),s=t.substring(3,4),i=t.substring(4,5),e+=e,n+=n,s+=s,i+=i),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(s,16),alpha:i?parseInt(i,16)/255:1}}const ve={test:qe("#"),parse:Ur,transform:it.transform},Bt=t=>({test:e=>typeof e=="string"&&e.endsWith(t)&&e.split(" ").length===1,parse:parseFloat,transform:e=>`${e}${t}`}),Z=Bt("deg"),H=Bt("%"),S=Bt("px"),Wr=Bt("vh"),Kr=Bt("vw"),An={...H,parse:t=>H.parse(t)/100,transform:t=>H.transform(t*100)},ut={test:qe("hsl","hue"),parse:ei("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:s=1})=>"hsla("+Math.round(t)+", "+H.transform(St(e))+", "+H.transform(St(n))+", "+St(Mt.transform(s))+")"},E={test:t=>it.test(t)||ve.test(t)||ut.test(t),parse:t=>it.test(t)?it.parse(t):ut.test(t)?ut.parse(t):ve.parse(t),transform:t=>typeof t=="string"?t:t.hasOwnProperty("red")?it.transform(t):ut.transform(t),getAnimatableNone:t=>{const e=E.parse(t);return e.alpha=0,E.transform(e)}},$r=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function _r(t){var e,n;return isNaN(t)&&typeof t=="string"&&(((e=t.match(Ye))==null?void 0:e.length)||0)+(((n=t.match($r))==null?void 0:n.length)||0)>0}const ni="number",si="color",Gr="var",Hr="var(",Vn="${}",zr=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Dt(t){const e=t.toString(),n=[],s={color:[],number:[],var:[]},i=[];let o=0;const a=e.replace(zr,l=>(E.test(l)?(s.color.push(o),i.push(si),n.push(E.parse(l))):l.startsWith(Hr)?(s.var.push(o),i.push(Gr),n.push(l)):(s.number.push(o),i.push(ni),n.push(parseFloat(l))),++o,Vn)).split(Vn);return{values:n,split:a,indexes:s,types:i}}function ii(t){return Dt(t).values}function ri(t){const{split:e,types:n}=Dt(t),s=e.length;return i=>{let o="";for(let r=0;r<s;r++)if(o+=e[r],i[r]!==void 0){const a=n[r];a===ni?o+=St(i[r]):a===si?o+=E.transform(i[r]):o+=i[r]}return o}}const Xr=t=>typeof t=="number"?0:E.test(t)?E.getAnimatableNone(t):t;function Yr(t){const e=ii(t);return ri(t)(e.map(Xr))}const Q={test:_r,parse:ii,createTransformer:ri,getAnimatableNone:Yr};function re(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+(e-t)*6*n:n<1/2?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function qr({hue:t,saturation:e,lightness:n,alpha:s}){t/=360,e/=100,n/=100;let i=0,o=0,r=0;if(!e)i=o=r=n;else{const a=n<.5?n*(1+e):n+e-n*e,l=2*n-a;i=re(l,a,t+1/3),o=re(l,a,t),r=re(l,a,t-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(r*255),alpha:s}}function Ht(t,e){return n=>n>0?e:t}const M=(t,e,n)=>t+(e-t)*n,oe=(t,e,n)=>{const s=t*t,i=n*(e*e-s)+s;return i<0?0:Math.sqrt(i)},Zr=[ve,it,ut],Jr=t=>Zr.find(e=>e.test(t));function Cn(t){const e=Jr(t);if(!e)return!1;let n=e.parse(t);return e===ut&&(n=qr(n)),n}const Mn=(t,e)=>{const n=Cn(t),s=Cn(e);if(!n||!s)return Ht(t,e);const i={...n};return o=>(i.red=oe(n.red,s.red,o),i.green=oe(n.green,s.green,o),i.blue=oe(n.blue,s.blue,o),i.alpha=M(n.alpha,s.alpha,o),it.transform(i))},xe=new Set(["none","hidden"]);function Qr(t,e){return xe.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}function to(t,e){return n=>M(t,e,n)}function Ze(t){return typeof t=="number"?to:typeof t=="string"?Xe(t)?Ht:E.test(t)?Mn:so:Array.isArray(t)?oi:typeof t=="object"?E.test(t)?Mn:eo:Ht}function oi(t,e){const n=[...t],s=n.length,i=t.map((o,r)=>Ze(o)(o,e[r]));return o=>{for(let r=0;r<s;r++)n[r]=i[r](o);return n}}function eo(t,e){const n={...t,...e},s={};for(const i in n)t[i]!==void 0&&e[i]!==void 0&&(s[i]=Ze(t[i])(t[i],e[i]));return i=>{for(const o in s)n[o]=s[o](i);return n}}function no(t,e){const n=[],s={color:0,var:0,number:0};for(let i=0;i<e.values.length;i++){const o=e.types[i],r=t.indexes[o][s[o]],a=t.values[r]??0;n[i]=a,s[o]++}return n}const so=(t,e)=>{const n=Q.createTransformer(e),s=Dt(t),i=Dt(e);return s.indexes.var.length===i.indexes.var.length&&s.indexes.color.length===i.indexes.color.length&&s.indexes.number.length>=i.indexes.number.length?xe.has(t)&&!i.values.length||xe.has(e)&&!s.values.length?Qr(t,e):kt(oi(no(s,i),i.values),n):Ht(t,e)};function ai(t,e,n){return typeof t=="number"&&typeof e=="number"&&typeof n=="number"?M(t,e,n):Ze(t)(t,e)}const io=t=>{const e=({timestamp:n})=>t(n);return{start:(n=!0)=>C.update(e,n),stop:()=>J(e),now:()=>F.isProcessing?F.timestamp:j.now()}},li=(t,e,n=10)=>{let s="";const i=Math.max(Math.round(e/n),2);for(let o=0;o<i;o++)s+=Math.round(t(o/(i-1))*1e4)/1e4+", ";return`linear(${s.substring(0,s.length-2)})`},zt=2e4;function Je(t){let e=0;const n=50;let s=t.next(e);for(;!s.done&&e<zt;)e+=n,s=t.next(e);return e>=zt?1/0:e}function ro(t,e=100,n){const s=n({...t,keyframes:[0,e]}),i=Math.min(Je(s),zt);return{type:"keyframes",ease:o=>s.next(i*o).value/e,duration:G(i)}}const oo=5;function ui(t,e,n){const s=Math.max(e-oo,0);return Ks(n-t(s),e-s)}const D={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},ae=.001;function ao({duration:t=D.duration,bounce:e=D.bounce,velocity:n=D.velocity,mass:s=D.mass}){let i,o,r=1-e;r=X(D.minDamping,D.maxDamping,r),t=X(D.minDuration,D.maxDuration,G(t)),r<1?(i=c=>{const u=c*r,h=u*t,f=u-n,d=Te(c,r),m=Math.exp(-h);return ae-f/d*m},o=c=>{const h=c*r*t,f=h*n+n,d=Math.pow(r,2)*Math.pow(c,2)*t,m=Math.exp(-h),p=Te(Math.pow(c,2),r);return(-i(c)+ae>0?-1:1)*((f-d)*m)/p}):(i=c=>{const u=Math.exp(-c*t),h=(c-n)*t+1;return-ae+u*h},o=c=>{const u=Math.exp(-c*t),h=(n-c)*(t*t);return u*h});const a=5/t,l=uo(i,o,a);if(t=_(t),isNaN(l))return{stiffness:D.stiffness,damping:D.damping,duration:t};{const c=Math.pow(l,2)*s;return{stiffness:c,damping:r*2*Math.sqrt(s*c),duration:t}}}const lo=12;function uo(t,e,n){let s=n;for(let i=1;i<lo;i++)s=s-t(s)/e(s);return s}function Te(t,e){return t*Math.sqrt(1-e*e)}const co=["duration","bounce"],ho=["stiffness","damping","mass"];function Dn(t,e){return e.some(n=>t[n]!==void 0)}function fo(t){let e={velocity:D.velocity,stiffness:D.stiffness,damping:D.damping,mass:D.mass,isResolvedFromDuration:!1,...t};if(!Dn(t,ho)&&Dn(t,co))if(t.visualDuration){const n=t.visualDuration,s=2*Math.PI/(n*1.2),i=s*s,o=2*X(.05,1,1-(t.bounce||0))*Math.sqrt(i);e={...e,mass:D.mass,stiffness:i,damping:o}}else{const n=ao(t);e={...e,...n,mass:D.mass},e.isResolvedFromDuration=!0}return e}function Xt(t=D.visualDuration,e=D.bounce){const n=typeof t!="object"?{visualDuration:t,keyframes:[0,1],bounce:e}:t;let{restSpeed:s,restDelta:i}=n;const o=n.keyframes[0],r=n.keyframes[n.keyframes.length-1],a={done:!1,value:o},{stiffness:l,damping:c,mass:u,duration:h,velocity:f,isResolvedFromDuration:d}=fo({...n,velocity:-G(n.velocity||0)}),m=f||0,p=c/(2*Math.sqrt(l*u)),x=r-o,g=G(Math.sqrt(l/u)),T=Math.abs(x)<5;s||(s=T?D.restSpeed.granular:D.restSpeed.default),i||(i=T?D.restDelta.granular:D.restDelta.default);let y;if(p<1){const P=Te(g,p);y=A=>{const V=Math.exp(-p*g*A);return r-V*((m+p*g*x)/P*Math.sin(P*A)+x*Math.cos(P*A))}}else if(p===1)y=P=>r-Math.exp(-g*P)*(x+(m+g*x)*P);else{const P=g*Math.sqrt(p*p-1);y=A=>{const V=Math.exp(-p*g*A),b=Math.min(P*A,300);return r-V*((m+p*g*x)*Math.sinh(b)+P*x*Math.cosh(b))/P}}const w={calculatedDuration:d&&h||null,next:P=>{const A=y(P);if(d)a.done=P>=h;else{let V=P===0?m:0;p<1&&(V=P===0?_(m):ui(y,P,A));const b=Math.abs(V)<=s,L=Math.abs(r-A)<=i;a.done=b&&L}return a.value=a.done?r:A,a},toString:()=>{const P=Math.min(Je(w),zt),A=li(V=>w.next(P*V).value,P,30);return P+"ms "+A},toTransition:()=>{}};return w}Xt.applyToOptions=t=>{const e=ro(t,100,Xt);return t.ease=e.ease,t.duration=_(e.duration),t.type="keyframes",t};function Pe({keyframes:t,velocity:e=0,power:n=.8,timeConstant:s=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:r,min:a,max:l,restDelta:c=.5,restSpeed:u}){const h=t[0],f={done:!1,value:h},d=b=>a!==void 0&&b<a||l!==void 0&&b>l,m=b=>a===void 0?l:l===void 0||Math.abs(a-b)<Math.abs(l-b)?a:l;let p=n*e;const x=h+p,g=r===void 0?x:r(x);g!==x&&(p=g-h);const T=b=>-p*Math.exp(-b/s),y=b=>g+T(b),w=b=>{const L=T(b),I=y(b);f.done=Math.abs(L)<=c,f.value=f.done?g:I};let P,A;const V=b=>{d(f.value)&&(P=b,A=Xt({keyframes:[f.value,m(f.value)],velocity:ui(y,b,f.value),damping:i,stiffness:o,restDelta:c,restSpeed:u}))};return V(0),{calculatedDuration:null,next:b=>{let L=!1;return!A&&P===void 0&&(L=!0,w(b),V(b)),P!==void 0&&b>=P?A.next(b-P):(!L&&w(b),f)}}}function mo(t,e,n){const s=[],i=n||Y.mix||ai,o=t.length-1;for(let r=0;r<o;r++){let a=i(t[r],t[r+1]);if(e){const l=Array.isArray(e)?e[r]||K:e;a=kt(l,a)}s.push(a)}return s}function po(t,e,{clamp:n=!0,ease:s,mixer:i}={}){const o=t.length;if(Gt(o===e.length),o===1)return()=>e[0];if(o===2&&e[0]===e[1])return()=>e[1];const r=t[0]===t[1];t[0]>t[o-1]&&(t=[...t].reverse(),e=[...e].reverse());const a=mo(e,s,i),l=a.length,c=u=>{if(r&&u<t[0])return e[0];let h=0;if(l>1)for(;h<t.length-2&&!(u<t[h+1]);h++);const f=Ct(t[h],t[h+1],u);return a[h](f)};return n?u=>c(X(t[0],t[o-1],u)):c}function go(t,e){const n=t[t.length-1];for(let s=1;s<=e;s++){const i=Ct(0,e,s);t.push(M(n,1,i))}}function yo(t){const e=[0];return go(e,t.length-1),e}function vo(t,e){return t.map(n=>n*e)}function xo(t,e){return t.map(()=>e||Zs).splice(0,t.length-1)}function bt({duration:t=300,keyframes:e,times:n,ease:s="easeInOut"}){const i=Rr(s)?s.map(bn):bn(s),o={done:!1,value:e[0]},r=vo(n&&n.length===e.length?n:yo(e),t),a=po(r,e,{ease:Array.isArray(i)?i:xo(e,i)});return{calculatedDuration:t,next:l=>(o.value=a(l),o.done=l>=t,o)}}const To=t=>t!==null;function Qe(t,{repeat:e,repeatType:n="loop"},s,i=1){const o=t.filter(To),a=i<0||e&&n!=="loop"&&e%2===1?0:o.length-1;return!a||s===void 0?o[a]:s}const Po={decay:Pe,inertia:Pe,tween:bt,keyframes:bt,spring:Xt};function ci(t){typeof t.type=="string"&&(t.type=Po[t.type])}class tn{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(e=>{this.resolve=e})}notifyFinished(){this.resolve()}then(e,n){return this.finished.then(e,n)}}const So=t=>t/100;class en extends tn{constructor(e){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{var s,i;const{motionValue:n}=this.options;n&&n.updatedAt!==j.now()&&this.tick(j.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(i=(s=this.options).onStop)==null||i.call(s))},this.options=e,this.initAnimation(),this.play(),e.autoplay===!1&&this.pause()}initAnimation(){const{options:e}=this;ci(e);
9const{type:n=bt,repeat:s=0,repeatDelay:i=0,repeatType:o,velocity:r=0}=e;let{keyframes:a}=e;const l=n||bt;l!==bt&&typeof a[0]!="number"&&(this.mixKeyframes=kt(So,ai(a[0],a[1])),a=[0,100]);const c=l({...e,keyframes:a});o==="mirror"&&(this.mirroredGenerator=l({...e,keyframes:[...a].reverse(),velocity:-r})),c.calculatedDuration===null&&(c.calculatedDuration=Je(c));const{calculatedDuration:u}=c;this.calculatedDuration=u,this.resolvedDuration=u+i,this.totalDuration=this.resolvedDuration*(s+1)-i,this.generator=c}updateTime(e){const n=Math.round(e-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(e,n=!1){const{generator:s,totalDuration:i,mixKeyframes:o,mirroredGenerator:r,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return s.next(0);const{delay:c=0,keyframes:u,repeat:h,repeatType:f,repeatDelay:d,type:m,onUpdate:p,finalKeyframe:x}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-i/this.speed,this.startTime)),n?this.currentTime=e:this.updateTime(e);const g=this.currentTime-c*(this.playbackSpeed>=0?1:-1),T=this.playbackSpeed>=0?g<0:g>i;this.currentTime=Math.max(g,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let y=this.currentTime,w=s;if(h){const b=Math.min(this.currentTime,i)/a;let L=Math.floor(b),I=b%1;!I&&b>=1&&(I=1),I===1&&L--,L=Math.min(L,h+1),!!(L%2)&&(f==="reverse"?(I=1-I,d&&(I-=d/a)):f==="mirror"&&(w=r)),y=X(0,1,I)*a}const P=T?{done:!1,value:u[0]}:w.next(y);o&&(P.value=o(P.value));let{done:A}=P;!T&&l!==null&&(A=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const V=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&A);return V&&m!==Pe&&(P.value=Qe(u,this.options,x,this.speed)),p&&p(P.value),V&&this.finish(),P}then(e,n){return this.finished.then(e,n)}get duration(){return G(this.calculatedDuration)}get time(){return G(this.currentTime)}set time(e){var n;e=_(e),this.currentTime=e,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.playbackSpeed),(n=this.driver)==null||n.start(!1)}get speed(){return this.playbackSpeed}set speed(e){this.updateTime(j.now());const n=this.playbackSpeed!==e;this.playbackSpeed=e,n&&(this.time=G(this.currentTime))}play(){var i,o;if(this.isStopped)return;const{driver:e=io,startTime:n}=this.options;this.driver||(this.driver=e(r=>this.tick(r))),(o=(i=this.options).onPlay)==null||o.call(i);const s=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=s):this.holdTime!==null?this.startTime=s-this.holdTime:this.startTime||(this.startTime=n??s),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(j.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var e,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(e=this.options).onComplete)==null||n.call(e)}cancel(){var e,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(e=this.options).onCancel)==null||n.call(e)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}attachTimeline(e){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),e.observe(this)}}function bo(t){for(let e=1;e<t.length;e++)t[e]??(t[e]=t[e-1])}const rt=t=>t*180/Math.PI,Se=t=>{const e=rt(Math.atan2(t[1],t[0]));return be(e)},wo={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:t=>(Math.abs(t[0])+Math.abs(t[3]))/2,rotate:Se,rotateZ:Se,skewX:t=>rt(Math.atan(t[1])),skewY:t=>rt(Math.atan(t[2])),skew:t=>(Math.abs(t[1])+Math.abs(t[2]))/2},be=t=>(t=t%360,t<0&&(t+=360),t),Rn=Se,En=t=>Math.sqrt(t[0]*t[0]+t[1]*t[1]),Ln=t=>Math.sqrt(t[4]*t[4]+t[5]*t[5]),Ao={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:En,scaleY:Ln,scale:t=>(En(t)+Ln(t))/2,rotateX:t=>be(rt(Math.atan2(t[6],t[5]))),rotateY:t=>be(rt(Math.atan2(-t[2],t[0]))),rotateZ:Rn,rotate:Rn,skewX:t=>rt(Math.atan(t[4])),skewY:t=>rt(Math.atan(t[1])),skew:t=>(Math.abs(t[1])+Math.abs(t[4]))/2};function we(t){return t.includes("scale")?1:0}function Ae(t,e){if(!t||t==="none")return we(e);const n=t.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let s,i;if(n)s=Ao,i=n;else{const a=t.match(/^matrix\(([-\d.e\s,]+)\)$/u);s=wo,i=a}if(!i)return we(e);const o=s[e],r=i[1].split(",").map(Co);return typeof o=="function"?o(r):r[o]}const Vo=(t,e)=>{const{transform:n="none"}=getComputedStyle(t);return Ae(n,e)};function Co(t){return parseFloat(t.trim())}const vt=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],xt=new Set(vt),kn=t=>t===yt||t===S,Mo=new Set(["x","y","z"]),Do=vt.filter(t=>!Mo.has(t));function Ro(t){const e=[];
9return Do.forEach(n=>{const s=t.getValue(n);s!==void 0&&(e.push([n,s.get()]),s.set(n.startsWith("scale")?1:0))}),e}const ot={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:(t,{transform:e})=>Ae(e,"x"),y:(t,{transform:e})=>Ae(e,"y")};ot.translateX=ot.x;ot.translateY=ot.y;const at=new Set;let Ve=!1,Ce=!1,Me=!1;function hi(){if(Ce){const t=Array.from(at).filter(s=>s.needsMeasurement),e=new Set(t.map(s=>s.element)),n=new Map;e.forEach(s=>{const i=Ro(s);i.length&&(n.set(s,i),s.render())}),t.forEach(s=>s.measureInitialState()),e.forEach(s=>{s.render();const i=n.get(s);i&&i.forEach(([o,r])=>{var a;(a=s.getValue(o))==null||a.set(r)})}),t.forEach(s=>s.measureEndState()),t.forEach(s=>{s.suspendedScrollY!==void 0&&window.scrollTo(0,s.suspendedScrollY)})}Ce=!1,Ve=!1,at.forEach(t=>t.complete(Me)),at.clear()}function fi(){at.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(Ce=!0)})}function Eo(){Me=!0,fi(),hi(),Me=!1}class nn{constructor(e,n,s,i,o,r=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...e],this.onComplete=n,this.name=s,this.motionValue=i,this.element=o,this.isAsync=r}scheduleResolve(){this.state="scheduled",this.isAsync?(at.add(this),Ve||(Ve=!0,C.read(fi),C.resolveKeyframes(hi))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:n,element:s,motionValue:i}=this;if(e[0]===null){const o=i==null?void 0:i.get(),r=e[e.length-1];if(o!==void 0)e[0]=o;else if(s&&n){const a=s.readValue(n,r);a!=null&&(e[0]=a)}e[0]===void 0&&(e[0]=r),i&&o===void 0&&i.set(e[0])}bo(e)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(e=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,e),at.delete(this)}cancel(){this.state==="scheduled"&&(at.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Lo=t=>t.startsWith("--");function ko(t,e,n){Lo(e)?t.style.setProperty(e,n):t.style[e]=n}const Fo=$e(()=>window.ScrollTimeline!==void 0),Bo={};function Io(t,e){const n=$e(t);return()=>Bo[e]??n()}const di=Io(()=>{try{document.createElement("div").animate({opacity:0}
9,{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Pt=([t,e,n,s])=>`cubic-bezier(${t}, ${e}, ${n}, ${s})`,Fn={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Pt([0,.65,.55,1]),circOut:Pt([.55,0,1,.45]),backIn:Pt([.31,.01,.66,-.59]),backOut:Pt([.33,1.53,.69,.99])};function mi(t,e){if(t)return typeof t=="function"?di()?li(t,e):"ease-out":Js(t)?Pt(t):Array.isArray(t)?t.map(n=>mi(n,e)||Fn.easeOut):Fn[t]}function Oo(t,e,n,{delay:s=0,duration:i=300,repeat:o=0,repeatType:r="loop",ease:a="easeOut",times:l}={},c=void 0){const u={[e]:n};l&&(u.offset=l);const h=mi(a,i);Array.isArray(h)&&(u.easing=h);const f={delay:s,duration:i,easing:Array.isArray(h)?"linear":h,fill:"both",iterations:o+1,direction:r==="reverse"?"alternate":"normal"};return c&&(f.pseudoElement=c),t.animate(u,f)}function pi(t){return typeof t=="function"&&"applyToOptions"in t}function jo({type:t,...e}){return pi(t)&&di()?t.applyToOptions(e):(e.duration??(e.duration=300),e.ease??(e.ease="easeOut"),e)}class No extends tn{constructor(e){if(super(),this.finishedTime=null,this.isStopped=!1,!e)return;const{element:n,name:s,keyframes:i,pseudoElement:o,allowFlatten:r=!1,finalKeyframe:a,onComplete:l}=e;this.isPseudoElement=!!o,this.allowFlatten=r,this.options=e,Gt(typeof e.type!="string");const c=jo(e);this.animation=Oo(n,s,i,c,o),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!o){const u=Qe(i,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(u):ko(n,s,u),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var e,n;(n=(e=this.animation).finish)==null||n.call(e)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:e}=this;e==="idle"||e==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var e,n;this.isPseudoElement||(n=(e=this.animation).commitStyles)==null||n.call(e)}get duration(){var n,s;const e=((s=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:s.call(n).duration)||0;return G(Number(e))}get time(){return G(Number(this.animation.currentTime)||0)}set time(e){this.finishedTime=null,this.animation.currentTime=_(e)}get speed(){return this.animation.playbackRate}set speed(e){e<0&&(this.finishedTime=null),this.animation.playbackRate=e}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(e){this.animation.startTime=e}attachTimeline({timeline:e,observe:n}){var s;return this.allowFlatten&&((s=this.animation.effect)==null||s.updateTiming({easing:"linear"})),this.animation.onfinish=null,e&&Fo()?(this.animation.timeline=e,K):n(this)}}const gi={anticipate:Xs,backInOut:zs,circInOut:qs};function Uo(t){return t in gi}function Wo(t){typeof t.ease=="string"&&Uo(t.ease)&&(t.ease=gi[t.ease])}const Bn=10;class Ko extends No{constructor(e){Wo(e),ci(e),super(e),e.startTime&&(this.startTime=e.startTime),this.options=e}updateMotionValue(e){const{motionValue:n,onUpdate:s,onComplete:i,element:o,...r}=this.options;if(!n)return;if(e!==void 0){n.set(e);return}const a=new en({...r,autoplay:!1}),l=_(this.finishedTime??this.time);n.setWithVelocity(a.sample(l-Bn).value,a.sample(l).value,Bn),a.stop()}}const In=(t,e)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(Q.test(t)||t==="0")&&!t.startsWith("url("));function $o(t){const e=t[0];if(t.length===1)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}function _o(t,e,n,s){const i=t[0];if(i===null)return!1;if(e==="display"||e==="visibility")return!0;const o=t[t.length-1],r=In(i,e),a=In(o,e);return!r||!a?!1:$o(t)||(n==="spring"||pi(n))&&s}function De(t){t.duration=0,t.type}const Go=new Set(["opacity","clipPath","filter","transform"]),Ho=$e(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function zo(t){var u;const{motionValue:e,name:n,repeatDelay:s,repeatType:i,damping:o,type:r}=t;if(!(((u=e==null?void 0:e.owner)==null?void 0:u.current)instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:c}=e.owner.getProps();return Ho()&&n&&Go.has(n)&&(n!=="transform"||!c)&&!l&&!s&&i!=="mirror"&&o!==0&&r!=="inertia"}const Xo=40;class Yo extends tn{constructor({autoplay:e=!0,delay:n=0,type:s="
9keyframes",repeat:i=0,repeatDelay:o=0,repeatType:r="loop",keyframes:a,name:l,motionValue:c,element:u,...h}){var m;super(),this.stop=()=>{var p,x;this._animation&&(this._animation.stop(),(p=this.stopTimeline)==null||p.call(this)),(x=this.keyframeResolver)==null||x.cancel()},this.createdAt=j.now();const f={autoplay:e,delay:n,type:s,repeat:i,repeatDelay:o,repeatType:r,name:l,motionValue:c,element:u,...h},d=(u==null?void 0:u.KeyframeResolver)||nn;this.keyframeResolver=new d(a,(p,x,g)=>this.onKeyframesResolved(p,x,f,!g),l,c,u),(m=this.keyframeResolver)==null||m.scheduleResolve()}onKeyframesResolved(e,n,s,i){this.keyframeResolver=void 0;const{name:o,type:r,velocity:a,delay:l,isHandoff:c,onUpdate:u}=s;this.resolvedAt=j.now(),_o(e,o,r,a)||((Y.instantAnimations||!l)&&(u==null||u(Qe(e,s,n))),e[0]=e[e.length-1],De(s),s.repeat=0);const f={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>Xo?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...s,keyframes:e},d=!c&&zo(f)?new Ko({...f,element:f.motionValue.owner.current}):new en(f);d.finished.then(()=>this.notifyFinished()).catch(K),this.pendingTimeline&&(this.stopTimeline=d.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=d}get finished(){return this._animation?this.animation.finished:this._finished}then(e,n){return this.finished.finally(e).then(()=>{})}get animation(){var e;return this._animation||((e=this.keyframeResolver)==null||e.resume(),Eo()),this._animation}get duration(){return this.animation.duration}get time(){return this.animation.time}set time(e){this.animation.time=e}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(e){this.animation.speed=e}get startTime(){return this.animation.startTime}attachTimeline(e){return this._animation?this.stopTimeline=this.animation.attachTimeline(e):this.pendingTimeline=e,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var e;this._animation&&this.animation.cancel(),(e=this.keyframeResolver)==null||e.cancel()}}const qo=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Zo(t){const e=qo.exec(t);if(!e)return[,];const[,n,s,i]=e;return[`--${n??s}`,i]}function yi(t,e,n=1){const[s,i]=Zo(t);if(!s)return;const o=window.getComputedStyle(e).getPropertyValue(s);if(o){const r=o.trim();return Ns(r)?parseFloat(r):r}return Xe(i)?yi(i,e,n+1):i}function sn(t,e){return(t==null?void 0:t[e])??(t==null?void 0:t.default)??t}const vi=new Set(["width","height","top","left","right","bottom",...vt]),Jo={test:t=>t==="auto",parse:t=>t},xi=t=>e=>e.test(t),Ti=[yt,S,H,Z,Kr,Wr,Jo],On=t=>Ti.find(xi(t));function Qo(t){return typeof t=="number"?t===0:t!==null?t==="none"||t==="0"||Ws(t):!0}const ta=new Set(["brightness","contrast","saturate","opacity"]);function ea(t){const[e,n]=t.slice(0,-1).split("(");if(e==="drop-shadow")return t;const[s]=n.match(Ye)||[];if(!s)return t;const i=n.replace(s,"");let o=ta.has(e)?1:0;return s!==n&&(o*=100),e+"("+o+i+")"}const na=/\b([a-z-]*)\(.*?\)/gu,Re={...Q,getAnimatableNone:t=>{const e=t.match(na);return e?e.map(ea).join(" "):t}},jn={...yt,transform:Math.round},sa={rotate:Z,rotateX:Z,rotateY:Z,rotateZ:Z,scale:jt,scaleX:jt,scaleY:jt,scaleZ:jt,skew:Z,skewX:Z,skewY:Z,distance:S,translateX:S,translateY:S,translateZ:S,x:S,y:S,z:S,perspective:S,transformPerspective:S,opacity:Mt,originX:An,originY:An,originZ:S},rn={borderWidth:S,borderTopWidth:S,borderRightWidth:S,borderBottomWidth:S,borderLeftWidth:S,borderRadius:S,radius:S,borderTopLeftRadius:S,borderTopRightRadius:S,borderBottomRightRadius:S,borderBottomLeftRadius:S,width:S,maxWidth:S,height:S,maxHeight:S,top:S,right:S,bottom:S,left:S,padding:S,paddingTop:S,paddingRight:S,paddingBottom:S,paddingLeft:S,margin:S,marginTop:S,marginRight:S,marginBottom:S,marginLeft:S,backgroundPositionX:S,backgroundPositionY:S,...sa,zIndex:jn,fillOpacity:Mt,strokeOpacity:Mt,numOctaves:jn},ia={...rn,color:E,backgroundColor:E,outlineColor:E,fill:E,stroke:E,borderColor:E,borderTopColor:E,borderRightColor:E,borderBottomColor:E,borderLeftColor:E,filter:Re,WebkitFilter:Re},Pi=t=>ia[t];function Si(t,e){let n=Pi(t);return n!==Re&&(n=Q),n.getAnimatableNone?n.getAnimatableNone(e):void 0}
vendor: 1,652 bytes, line 9
9const ra=new Set(["auto","none","0"]);function oa(t,e,n){let s=0,i;for(;s<t.length&&!i;){const o=t[s];typeof o=="string"&&!ra.has(o)&&Dt(o).values.length&&(i=t[s]),s++}if(i&&n)for(const o of e)t[o]=Si(n,i)}class aa extends nn{constructor(e,n,s,i,o){super(e,n,s,i,o,!0)}readKeyframes(){const{unresolvedKeyframes:e,element:n,name:s}=this;if(!n||!n.current)return;super.readKeyframes();for(let l=0;l<e.length;l++){let c=e[l];if(typeof c=="string"&&(c=c.trim(),Xe(c))){const u=yi(c,n.current);u!==void 0&&(e[l]=u),l===e.length-1&&(this.finalKeyframe=c)}}if(this.resolveNoneKeyframes(),!vi.has(s)||e.length!==2)return;const[i,o]=e,r=On(i),a=On(o);if(r!==a)if(kn(r)&&kn(a))for(let l=0;l<e.length;l++){const c=e[l];typeof c=="string"&&(e[l]=parseFloat(c))}else ot[s]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:e,name:n}=this,s=[];for(let i=0;i<e.length;i++)(e[i]===null||Qo(e[i]))&&s.push(i);s.length&&oa(e,s,n)}measureInitialState(){const{element:e,unresolvedKeyframes:n,name:s}=this;if(!e||!e.current)return;s==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=ot[s](e.measureViewportBox(),window.getComputedStyle(e.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&e.getValue(s,i).jump(i,!1)}measureEndState(){var a;const{element:e,name:n,unresolvedKeyframes:s}=this;if(!e||!e.current)return;const i=e.getValue(n);i&&i.jump(this.measuredOrigin,!1);const o=s.length-1,r=s[o];s[o]=ot[n](e.measureViewportBox(),window.getComputedStyle(e.current)),r!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=r),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEac
9h(([l,c])=>{e.getValue(l).set(c)}),this.resolveNoneKeyframes()}}function la(t,e,n){if(t instanceof EventTarget)return[t];if(typeof t=="string"){const i=document.querySelectorAll(t);return i?Array.from(i):[]}return Array.from(t)}const bi=(t,e)=>e&&typeof t=="number"?e.transform(t):t;function wi(t){return Us(t)&&"offsetHeight"in t}const Nn=30,ua=t=>!isNaN(parseFloat(t));class ca{constructor(e,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=s=>{var o;const i=j.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(s),this.current!==this.prev&&((o=this.events.change)==null||o.notify(this.current),this.dependents))for(const r of this.dependents)r.dirty()},this.hasAnimated=!1,this.setCurrent(e),this.owner=n.owner}setCurrent(e){this.current=e,this.updatedAt=j.now(),this.canTrackVelocity===null&&e!==void 0&&(this.canTrackVelocity=ua(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,n){this.events[e]||(this.events[e]=new _e);const s=this.events[e].add(n);return e==="change"?()=>{s(),C.read(()=>{this.events.change.getSize()||this.stop()})}:s}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,n){this.passiveEffect=e,this.stopPassiveEffect=n}set(e){this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e)}setWithVelocity(e,n,s){this.set(n),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-s}jump(e,n=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var e;(e=this.events.change)==null||e.notify(this.current)}addDependent(e){this.dependents||(this.dependents=new Set),this.dependents.add(e)}removeDependent(e){this.dependents&&this.dependents.delete(e)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const e=j.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||e-this.updatedAt>Nn)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Nn);return Ks(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(e){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=e(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(){var e,n;(e=this.dependents)==null||e.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function pt(t,e){return new ca(t,e)}const{schedule:on,cancel:sc}=Qs(queueMicrotask,!1),$={x:!1,y:!1};function Ai(){return $.x||$.y}function ha(t){return t==="x"||t==="y"?$[t]?null:($[t]=!0,()=>{$[t]=!1}):$.x||$.y?null:($.x=$.y=!0,()=>{$.x=$.y=!1})}function Vi(t,e){const n=la(t),s=new AbortController,i={passive:!0,...e,signal:s.signal};return[n,i,()=>s.abort()]}function Un(t){return!(t.pointerType==="touch"||Ai())}function fa(t,e,n={}){const[s,i,o]=Vi(t,n),r=a=>{if(!Un(a))return;const{target:l}=a,c=e(l,a);if(typeof c!="function"||!l)return;const u=h=>{Un(h)&&(c(h),l.removeEventListener("pointerleave",u))};l.addEventListener("pointerleave",u,i)};return s.forEach(a=>{a.addEventListener("pointerenter",r,i)}),o}const Ci=(t,e)=>e?t===e?!0:Ci(t,e.parentElement):!1,an=t=>t.pointerType==="mouse"?typeof t.button!="number"||t.button<=0:t.isPrimary!==!1,da=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function ma(t){return da.has(t.tagName)||t.tabIndex!==-1}
9const Kt=new WeakSet;function Wn(t){return e=>{e.key==="Enter"&&t(e)}}function le(t,e){t.dispatchEvent(new PointerEvent("pointer"+e,{isPrimary:!0,bubbles:!0}))}const pa=(t,e)=>{const n=t.currentTarget;if(!n)return;const s=Wn(()=>{if(Kt.has(n))return;le(n,"down");const i=Wn(()=>{le(n,"up")}),o=()=>le(n,"cancel");n.addEventListener("keyup",i,e),n.addEventListener("blur",o,e)});n.addEventListener("keydown",s,e),n.addEventListener("blur",()=>n.removeEventListener("keydown",s),e)};function Kn(t){return an(t)&&!Ai()}function ga(t,e,n={}){const[s,i,o]=Vi(t,n),r=a=>{const l=a.currentTarget;if(!Kn(a))return;Kt.add(l);const c=e(l,a),u=(d,m)=>{window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",f),Kt.has(l)&&Kt.delete(l),Kn(d)&&typeof c=="function"&&c(d,{success:m})},h=d=>{u(d,l===window||l===document||n.useGlobalTarget||Ci(l,d.target))},f=d=>{u(d,!1)};window.addEventListener("pointerup",h,i),window.addEventListener("pointercancel",f,i)};return s.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",r,i),wi(a)&&(a.addEventListener("focus",c=>pa(c,i)),!ma(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),o}function Mi(t){return Us(t)&&"ownerSVGElement"in t}function ya(t){return Mi(t)&&t.tagName==="svg"}const B=t=>!!(t&&t.getVelocity),va=[...Ti,E,Q],xa=t=>va.find(xi(t)),ln=v.createContext({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"});class Ta extends v.Component{getSnapshotBeforeUpdate(e){const n=this.props.childRef.current;if(n&&e.isPresent&&!this.props.isPresent){const s=n.offsetParent,i=wi(s)&&s.offsetWidth||0,o=this.props.sizeRef.current;o.height=n.offsetHeight||0,o.width=n.offsetWidth||0,o.top=n.offsetTop,o.left=n.offsetLeft,o.right=i-o.width-o.left}return null}componentDidUpdate(){}render(){return this.props.children}}function Pa({children:t,isPresent:e,anchorX:n,root:s}){const i=v.useId(),o=v.useRef(null),r=v.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:a}=v.useContext(ln);return v.useInsertionEffect(()=>{const{width:l,height:c,top:u,left:h,right:f}=r.current;if(e||!o.current||!l||!c)return;const d=n==="left"?`left: ${h}`:`right: ${f}`;o.current.dataset.motionPopId=i;const m=document.createElement("style");a&&(m.nonce=a);const p=s??document.head;return p.appendChild(m),m.sheet&&m.sheet.insertRule(` 10 [data-motion-pop-id="${i}"] { 11 position: absolute !important; 12 width: ${l}px !important; 13 height: ${c}px !important; 14 ${d}px !important; 15 top: ${u}px !important; 16 } 17 `),()=>{p.contains(m)&&p.removeChild(m)}},[e]),z.jsx(Ta,{isPresent:e,childRef:o,sizeRef:r,children:v.cloneElement(t,{ref:o})})}const Sa=({children:t,initial:e,isPresent:n,onExitComplete:s,custom:i,presenceAffectsLayout:o,mode:r,anchorX:a,root:l})=>{const c=Ne(ba),u=v.useId();let h=!0,f=v.useMemo(()=>(h=!1,{id:u,initial:e,isPresent:n,custom:i,onExitComplete:d=>{c.set(d,!0);for(const m of c.values())if(!m)return;s&&s()},register:d=>(c.set(d,!1),()=>c.delete(d))}),[n,c,s]);return o&&h&&(f={...f}),v.useMemo(()=>{c.forEach((d,m)=>c.set(m,!1))},[n]),v.useEffect(()=>{!n&&!c.size&&s&&s()},[n]),r==="popLayout"&&(t=z.jsx(Pa,{isPresent:n,anchorX:a,root:l,children:t})),z.jsx(Qt.Provider,{value:f,children:t})};function ba(){return new Map}function Di(t=!0){const e=v.useContext(Qt);if(e===null)return[!0,null];const{isPresent:n,onExitComplete:s,register:i}=e,o=v.useId();v.useEffect(()=>{if(t)return i(o)},[t]);const r=v.useCallback(()=>t&&s&&s(o),[o,s,t]);return!n&&s?[!1,r]:[!0]}const Nt=t=>t.key||"";function $n(t){const e=[];return v.Children.forEach(t,n=>{v.isValidElement(n)&&e.push(n)}),e}const ic=({children:t,custom:e,initial:n=!0,onExitComplete:s,presenceAffectsLayout:i=!0,mode:o="sync",propagate:r=!1,anchorX:a="left",root:l})=>{const[c,u]=Di(r),h=v.useMemo(()=>$n(t),[t]),f=r&&!c?[]:h.map(Nt),d=v.useRef(!0),m=v.useRef(h),p=Ne(()=>new Map),[x,g]=v.useState(h),[T,y]=v.useState(h);js(()=>{d.current=!1,m.current=h;for(let A=0;A<T.length;A++){const V=Nt(T[A]);f.includes(V)?p.delete(V):p.get(V)!==!0&&p.set(V,!1)}},[T,f.length,f.join("-")]);const w=[];if(h!==x){let A=[...h];for(let V=0;V<T.length;V++){const b=T[V],L=Nt(b);f.includes(L)||(A.splice(V,0,b),w.push(b))}return o==="wait"&&w.length&&(A=w),y($n(A)),g(h),null}const{forceRender:P}=v.useContext(je);return z.jsx(z.Fragment,{children:T.map(A=>{const V=Nt(A),b=r&&!c?!1:h===T||f.includes(V),L=()=>
vendor: 9,413 bytes, line 17
17{if(p.has(V))p.set(V,!0);else return;let I=!0;p.forEach(q=>{q||(I=!1)}),I&&(P==null||P(),y(m.current),r&&(u==null||u()),s&&s())};return z.jsx(Sa,{isPresent:b,initial:!d.current||n?void 0:!1,custom:e,presenceAffectsLayout:i,mode:o,root:l,onExitComplete:b?void 0:L,anchorX:a,children:A},V)})})},Ri=v.createContext({strict:!1}),_n={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"]},gt={};for(const t in _n)gt[t]={isEnabled:e=>_n[t].some(n=>!!e[n])};function wa(t){for(const e in t)gt[e]={...gt[e],...t[e]}}const Aa=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Yt(t){return t.startsWith("while")||t.startsWith("drag")&&t!=="draggable"||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||Aa.has(t)}let Ei=t=>!Yt(t);function Va(t){typeof t=="function"&&(Ei=e=>e.startsWith("on")?!Yt(e):t(e))}try{Va(require("@emotion/is-prop-valid").default)}catch{}function Ca(t,e,n){const s={};for(const i in t)i==="values"&&typeof t.values=="object"||(Ei(i)||n===!0&&Yt(i)||!e&&!Yt(i)||t.draggable&&i.startsWith("onDrag"))&&(s[i]=t[i]);return s}const te=v.createContext({});function ee(t){return t!==null&&typeof t=="object"&&typeof t.start=="function"}function Rt(t){return typeof t=="string"||Array.isArray(t)}const un=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],cn=["initial",...un];function ne(t){return ee(t.animate)||cn.some(e=>Rt(t[e]))}function Li(t){return!!(ne(t)||t.variants)}function Ma(t,e){if(ne(t)){const{initial:n,animate:s}=t;return{initial:n===!1||Rt(n)?n:void 0,animate:Rt(s)?s:void 0}}return t.inherit!==!1?e:{}}function Da(t){const{initial:e,animate:n}=Ma(t,v.useContext(te));return v.useMemo(()=>({initial:e,animate:n}),[Gn(e),Gn(n)])}function Gn(t){return Array.isArray(t)?t.join(" "):t}const Et={};function Ra(t){for(const e in t)Et[e]=t[e],ze(e)&&(Et[e].isCSSVariable=!0)}function ki(t,{layout:e,layoutId:n}){return xt.has(t)||t.startsWith("origin")||(e||n!==void 0)&&(!!Et[t]||t==="opacity")}const Ea={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},La=vt.length;function ka(t,e,n){let s="",i=!0;for(let o=0;o<La;o++){const r=vt[o],a=t[r];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(r.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||n){const c=bi(a,rn[r]);if(!l){i=!1;const u=Ea[r]||r;s+=`${u}(${c}) `}n&&(e[r]=c)}}return s=s.trim(),n?s=n(e,i?"":s):i&&(s="none"),s}function hn(t,e,n){const{style:s,vars:i,transformOrigin:o}=t;let r=!1,a=!1;for(const l in e){const c=e[l];if(xt.has(l)){r=!0;continue}else if(ze(l)){i[l]=c;continue}else{const u=bi(c,rn[l]);l.startsWith("origin")?(a=!0,o[l]=u):s[l]=u}}if(e.transform||(r||n?s.transform=ka(e,t.transform,n):s.transform&&(s.transform="none")),a){const{originX:l="50%",originY:c="50%",originZ:u=0}=o;s.transformOrigin=`${l} ${c} ${u}`}}const fn=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Fi(t,e,n){for(const s in e)!B(e[s])&&!ki(s,n)&&(t[s]=e[s])}function Fa({transformTemplate:t},e){return v.useMemo(()=>{const n=fn();return hn(n,e,t),Object.assign({},n.vars,n.style)},[e])}function Ba(t,e){const n=t.style||{},s={};return Fi(s,n,t),Object.assign(s,Fa(t,e)),s}function Ia(t,e){const n={},s=Ba(t,e);return t.drag&&t.dragListener!==!1&&(n.draggable=!1,s.userSelect=s.WebkitUserSelect=s.WebkitTouchCallout="none",s.touchAction=t.drag===!0?"none":`pan-${t.drag==="x"?"y":"x"}`),t.tabIndex===void 0&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=s,n}const Oa={offset:"stroke-dashoffset",array:"stroke-dasharray"},ja={offset:"strokeDashoffset",array:"strokeDasharray"};function Na(t,e,n=1,s=0,i=!0){t.pathLength=1;const o=i?Oa:ja;t[o.offset]=S.transform(-s);const r=S.transform(e),a=S.transform(n);t[o.array]=`${r} ${a}`}function Bi(t,{attrX:e,attrY:n,attrScale:s,pathLength:i,pathSpacing:o=1,pathOffset:r=0,...a},l,c,u){if(hn(t,a,c),l){t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox);return}t.attrs=t.style,t.style={};const{attrs:h,style:f}=t;h.transform&&(f.transform=h.transform,delete h.transform),(f.transform||h.transformOrigin)&&(f.transformOrigin=h.transformOrigin??"50% 50%",delete h.transformOrigin),f.transform&&(f.transformBox=(u==null?void 0:u.transformBox)??"fill-box",delete h.transformBox),e!==void 0&&(h.x=e),n!==void 0&&(h.y=n),s!==void 0&&(h.scale=s),i!==void 0&&Na(h,i,o,r,!1)}const Ii=()=>({...fn(),attrs:{}}),Oi=t=>typeof t=="string"&&t.toLowerCase()==="svg";function Ua(t,e,n,s){const i=v.useMemo(()=>{const o=Ii();return Bi(o,e,Oi(s),t.transformTemplate,t.style),{...o.attrs,style:{...o.style}}},[e]);if(t.style){const o={};Fi(o,t.style,t),i.style={...o,...i.style}}return i}const Wa=["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 dn(t){return typeof t!="string"||t.includes("-")?!1:!!(Wa.indexOf(t)>-1||/[A-Z]/u.test(t))}function Ka(t,e,n,{latestValues:s},i,o=!1){const a=(dn(t)?Ua:Ia)(e,s,i,t),l=Ca(e,typeof t=="string",o),c=t!==v.Fragment?{...l,...a,ref:n}:{},{children:u}=e,h=v.useMemo(()=>B(u)?u.get():u,[u]);return v.createElement(t,{...c,children:h})}function Hn(t){const e=[{},{}];return t==null||t.values.forEach((n,s)=>{e[0][s]=n.get(),e[1][s]=n.getVelocity()}),e}function mn(t,e,n,s){if(typeof e=="function"){const[i,o]=Hn(s);e=e(n!==void 0?n:t.custom,i,o)}if(typeof e=="string"&&(e=t.variants&&t.variants[e]),typeof e=="function"){const[i,o]=Hn(s);e=e(n!==void 0?n:t.custom,i,o)}return e}function $t(t){return B(t)?t.get():t}function $a({scrapeMotionValuesFromProps:t,createRenderState:e},n,s,i){return{latestValues:_a(n,s,i,t),renderState:e()}}function _a(t,e,n,s){const i={},o=s(t,{});for(const f in o)i[f]=$t(o[f]);let{initial:r,animate:a}=t;const l=ne(t),c=Li(t);e&&c&&!l&&t.inherit!==!1&&(r===void 0&&(r=e.initial),a===void 0&&(a=e.animate));let u=n?n.initial===!1:!1;u=u||r===!1;const h=u?a:r;if(h&&typeof h!="boolean"&&!ee(h)){const f=Array.isArray(h)?h:[h];for(let d=0;d<f.length;d++){const m=mn(t,f[d]);if(m){const{transitionEnd:p,transition:x,...g}=m;for(const T in g){let y=g[T];if(Array.isArray(y)){const w=u?y.length-1:0;y=y[w]}y!==null&&(i[T]=y)}for(const T in p)i[T]=p[T]}}}return i}const ji=t=>(e,n)=>{const s=v.useContext(te),i=v.useContext(Qt),o=()=>$a(t,e,s,i);return n?o():Ne(o)};function pn(t,e,n){var o;const{style:s}=t,i={};for(const r in s)(B(s[r])||e.style&&B(e.style[r])||ki(r,t)||((o=n==null?void 0:n.getValue(r))==null?void 0:o.liveStyle)!==void 0)&&(i[r]=s[r]);return i}const Ga=ji({scrapeMotionValuesFromProps:pn,createRenderState:fn});function Ni(t,e,n){const s=pn(t,e,n);for(const i in t)if(B(t[i])||B(e[i])){const o=vt.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;s[o]=t[i]}return s}const Ha=ji({scrapeMotionValuesFromProps:Ni,createRenderState:Ii}),za=Symbol.for("motionComponentSymbol");function ct(t){return t&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}function Xa(t,e,n){return v.useCallback(s=>{s&&t.onMount&&t.onMount(s),e&&(s?e.mount(s):e.unmount()),n&&(typeof n=="function"?n(s):ct(n)&&(n.current=s))},[e])}const gn=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Ya="framerAppearId",Ui="data-"+gn(Ya),Wi=v.createContext({});function qa(t,e,n,s,i){var p,x;const{visualElement:o}=v.useContext(te),r=v.useContext(Ri),a=v.useContext(Qt),l=v.useContext(ln).reducedMotion,c=v.useRef(null);s=s||r.renderer,!c.current&&s&&(c.current=s(t,{visualState:e,parent:o,props:n,presenceContext:a,blockInitialAnimation:a?a.initial===!1:!1,reducedMotionConfig:l}));const u=c.current,h=v.useContext(Wi);u&&!u.projection&&i&&(u.type==="html"||u.type==="svg")&&Za(c.current,n,i,h);const f=v.useRef(!1);v.useInsertionEffect(()=>{u&&f.current&&u.update(n,a)});const d=n[Ui],m=v.useRef(!!d&&!((p=window.MotionHandoffIsComplete)!=null&&p.call(window,d))&&((x=window.MotionHasOptimisedAnimation)==null?void 0:x.call(window,d)));return js(()=>{u&&(f.current=!0,window.MotionIsMounted=!0,u.updateFeatures(),u.scheduleRenderMicrotask(),m.current&&u.animationState&&u.animationState.animateChanges())}),v.useEffect(()=>{u&&(!m.current&&u.animationState&&u.animationState.animateChanges(),m.current&&(queueMicrotask(()=>{var g;(g=window.MotionHandoffMarkAsComplete)==null||g.call(window,d)}),m.current=!1),u.enteringChildren=void 0)}),u}function Za(t,e,n,s){const{layoutId:i,layout:o,drag:r,dragConstraints:a,layoutScroll:l,layoutRoot:c,layoutCrossfade:u}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:Ki(t.parent)),t.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:!!r||a&&ct(a),visualElement:t,animationType:typeof o=="str
17ing"?o:"both",initialPromotionConfig:s,crossfade:u,layoutScroll:l,layoutRoot:c})}function Ki(t){if(t)return t.options.allowProjection!==!1?t.projection:Ki(t.parent)}function ue(t,{forwardMotionProps:e=!1}={},n,s){n&&wa(n);const i=dn(t)?Ha:Ga;function o(a,l){let c;const u={...v.useContext(ln),...a,layoutId:Ja(a)},{isStatic:h}=u,f=Da(a),d=i(a,h);if(!h&&Ue){Qa();const m=tl(u);c=m.MeasureLayout,f.visualElement=qa(t,d,u,s,m.ProjectionNode)}return z.jsxs(te.Provider,{value:f,children:[c&&f.visualElement?z.jsx(c,{visualElement:f.visualElement,...u}):null,Ka(t,a,Xa(d,f.visualElement,l),d,h,e)]})}o.displayName=`motion.${typeof t=="string"?t:`create(${t.displayName??t.name??""})`}`;const r=v.forwardRef(o);return r[za]=t,r}function Ja({layoutId:t}){const e=v.useContext(je).id;return e&&t!==void 0?e+"-"+t:t}function Qa(t,e){v.useContext(Ri).strict}function tl(t){const{drag:e,layout:n}=gt;if(!e&&!n)return{};const s={...e,...n};return{MeasureLayout:e!=null&&e.isEnabled(t)||n!=null&&n.isEnabled(t)?s.MeasureLayout:void 0,ProjectionNode:s.ProjectionNode}}function el(t,e){if(typeof Proxy>"u")return ue;const n=new Map,s=(o,r)=>ue(o,r,t,e),i=(o,r)=>s(o,r);return new Proxy(i,{get:(o,r)=>r==="create"?s:(n.has(r)||n.set(r,ue(r,void 0,t,e)),n.get(r))})}function $i({top:t,left:e,right:n,bottom:s}){return{x:{min:e,max:n},y:{min:t,max:s}}}function nl({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}function sl(t,e){if(!e)return t;const n=e({x:t.left,y:t.top}),s=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:s.y,right:s.x}}function ce(t){return t===void 0||t===1}function Ee({scale:t,scaleX:e,scaleY:n}){return!ce(t)||!ce(e)||!ce(n)}function st(t){return Ee(t)||_i(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function _i(t){return zn(t.x)||zn(t.y)}function zn(t){return t&&t!=="0%"}function qt(t,e,n){const s=t-n,i=e*s;return n+i}function Xn(t,e,n,s,i){return i!==void 0&&(t=qt(t,i,s)),qt(t,n,s)+e}function Le(t,e=0,n=1,s,i){t.min=Xn(t.min,e,n,s,i),t.max=Xn(t.max,e,n,s,i)}function Gi(t,{x:e,y:n}){Le(t.x,e.translate,e.scale,e.originPoint),Le(t.y,n.translate,n.scale,n.originPoint)}const Yn=.999999999999,qn=1.0000000000001;function il(t,e,n,s=!1){const i=n.length;if(!i)return;e.x=e.y=1;let o,r;for(let a=0;a<i;a++){o=n[a],r=o.projectionDelta;const{visualElement:l}=o.options;l&&l.props.style&&l.props.style.display==="contents"||(s&&o.options.layoutScroll&&o.scroll&&o!==o.root&&ft(t,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),r&&(e.x*=r.x.scale,e.y*=r.y.scale,Gi(t,r)),s&&st(o.latestValues)&&ft(t,o.latestValues))}e.x<qn&&e.x>Yn&&(e.x=1),e.y<qn&&e.y>Yn&&(e.y=1)}function ht(t,e){t.min=t.min+e,t.max=t.max+e}function Zn(t,e,n,s,i=.5){const o=M(t.min,t.max,i);Le(t,e,n,o,s)}function ft(t,e){Zn(t.x,e.x,e.scaleX,e.scale,e.originX),Zn(t.y,e.y,e.scaleY,e.scale,e.originY)}function Hi(t,e){return $i(sl(t.getBoundingClientRect(),e))}function rl(t,e,n){const s=Hi(t,n),{scroll:i}=e;return i&&(ht(s.x,i.offset.x),ht(s.y,i.offset.y)),s}const Jn=()=>({translate:0,scale:1,origin:0,originPoint:0}),dt=()=>({x:Jn(),y:Jn()}),Qn=()=>({min:0,max:0}),R=()=>({x:Qn(),y:Qn()}),Zt={current:null},yn={current:!1};function zi(){if(yn.current=!0,!!Ue)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),e=()=>Zt.current=t.matches;t.addEventListener("change",e),e()}else Zt.current=!1}const ol=new WeakMap;function al(t,e,n){for(const s in e){const i=e[s],o=n[s];if(B(i))t.addValue(s,i);else if(B(o))t.addValue(s,pt(i,{owner:t}));else if(o!==i)if(t.hasValue(s)){const r=t.getValue(s);r.liveStyle===!0?r.jump(i):r.hasAnimated||r.set(i)}else{const r=t.getStaticValue(s);t.addValue(s,pt(r!==void 0?r:i,{owner:t}))}}for(const s in n)e[s]===void 0&&t.removeValue(s);return e}const ts=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class ll{scrapeMotionValuesFromProps(e,n,s){return{}}constructor({parent:e,props:n,presenceContext:s,reducedMotionConfig:i,blockInitialAnimation:o,visualState:r},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=nn,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.renderScheduledAt=0,this.scheduleRender=()=>{const f=j.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,C.render(this.render,!1,!0))};const{latestValues:l,renderState:c}=r;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=c,this.parent=e,this.props=n,this.presenceContext=s,this.depth=e?e.depth+1:0,this.reducedMotionConfig=i,this.options=a,this.blockInitialAnimation=!!o,this.isControllingVariants=ne(n),this.isVariantNode=Li(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);const{willChange:u,...h}=this.scrapeMotionValuesFromProps(n,{},this);for(const f in h){const d=h[f];l[f]!==void 0&&B(d)&&d.set(l[f])}}mount(e){var n;this.current=e,ol.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEac
vendor: 5,586 bytes, line 17
17h((s,i)=>this.bindToMotionValue(i,s)),yn.current||zi(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Zt.current,(n=this.parent)==null||n.addChild(this),this.update(this.props,this.presenceContext)}unmount(){var e;this.projection&&this.projection.unmount(),J(this.notifyUpdate),J(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(e=this.parent)==null||e.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const s=this.features[n];s&&(s.unmount(),s.isMounted=!1)}this.current=null}addChild(e){this.children.add(e),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(e)}removeChild(e){this.children.delete(e),this.enteringChildren&&this.enteringChildren.delete(e)}bindToMotionValue(e,n){this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();const s=xt.has(e);s&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",r=>{this.latestValues[e]=r,this.props.onUpdate&&C.preRender(this.notifyUpdate),s&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let o;window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,e,n)),this.valueSubscriptions.set(e,()=>{i(),o&&o(),n.owner&&n.stop()})}sortNodePosition(e){return!this.current||!this.sortInstanceNodePosition||this.type!==e.type?0:this.sortInstanceNodePosition(this.current,e.current)}updateFeatures(){let e="animation";for(e in gt){const n=gt[e];if(!n)continue;const{isEnabled:s,Feature:i}=n;if(!this.features[e]&&i&&s(this.props)&&(this.features[e]=new i(this)),this.features[e]){const o=this.features[e];o.isMounted?o.update():(o.mount(),o.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):R()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,n){this.latestValues[e]=n}update(e,n){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let s=0;s<ts.length;s++){const i=ts[s];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const o="on"+i,r=e[o];r&&(this.propEventSubscriptions[i]=this.on(i,r))}this.prevMotionValues=al(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(e){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(e),()=>n.variantChildren.delete(e)}addValue(e,n){const s=this.values.get(e);n!==s&&(s&&this.removeValue(e),this.bindToMotionValue(e,n),this.values.set(e,n),this.latestValues[e]=n.get())}removeValue(e){this.values.delete(e);const n=this.valueSubscriptions.get(e);n&&(n(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,n){if(this.props.values&&this.props.values[e])return this.props.values[e];let s=this.values.get(e);return s===void 0&&n!==void 0&&(s=pt(n===null?void 0:n,{owner:this}),this.addValue(e,s)),s}readValue(e,n){let s=this.latestValues[e]!==void 0||!this.current?this.latestValues[e]:this.getBaseTargetFromProps(this.props,e)??this.readValueFromInstance(this.current,e,this.options);return s!=null&&(typeof s=="string"&&(Ns(s)||Ws(s))?s=parseFloat(s):!xa(s)&&Q.test(n)&&(s=Si(e,n)),this.setBaseTarget(e,B(s)?s.get():s)),B(s)?s.get():s}setBaseTarget(e,n){this.baseTarget[e]=n}getBaseTarget(e){var o;const{initial:n}=this.props;let s;if(typeof n=="string"||typeof n=="object"){const r=mn(this.props,n,(o=this.presenceContext)==null?void 0:o.custom);r&&(s=r[e])}if(n&&s!==void 0)return s;const i=this.getBaseTargetFromProps(this.props,e);return i!==void 0&&!B(i)?i:this.initialValues[e]!==void 0&&s===void 0?void 0:this.baseTarget[e]}on(e,n){return this.events[e]||(this.events[e]=new _e),this.events[e].add(n)}notify(e,...n){this.events[e]&&this.events[e].notify(...n)}scheduleRenderMicrotask(){on.render(this.render)}}class Xi extends ll{constructor(){super(...arguments),this.KeyframeResolver=aa}sortInstanceNodePosition(e,n){return e.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(e,n){return e.style?e.style[n]:void 0}removeValueFromRenderState(e,{vars:n,style:s}){delete n[e],delete s[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;B(e)&&(this.childSubscription=e.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function Yi(t,{style:e,vars:n},s,i){const o=t.style;let r;for(r in e)o[r]=e[r];i==null||i.applyProjectionStyles(o,s);for(r in n)o.setProperty(r,n[r])}function ul(t){return window.getComputedStyle(t)}class cl extends Xi{constructor(){super(...arguments),this.type="html",this.renderInstance=Yi}readValueFromInstance(e,n){var s;if(xt.has(n))return(s=this.projection)!=null&&s.isProjecting?we(n):Vo(e,n);{const i=ul(e),o=(ze(n)?i.getPropertyValue(n):i[n])||0;
17return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(e,{transformPagePoint:n}){return Hi(e,n)}build(e,n,s){hn(e,n,s.transformTemplate)}scrapeMotionValuesFromProps(e,n,s){return pn(e,n,s)}}const qi=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 hl(t,e,n,s){Yi(t,e,void 0,s);for(const i in e.attrs)t.setAttribute(qi.has(i)?i:gn(i),e.attrs[i])}class fl extends Xi{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=R}getBaseTargetFromProps(e,n){return e[n]}readValueFromInstance(e,n){if(xt.has(n)){const s=Pi(n);return s&&s.default||0}return n=qi.has(n)?n:gn(n),e.getAttribute(n)}scrapeMotionValuesFromProps(e,n,s){return Ni(e,n,s)}build(e,n,s){Bi(e,n,this.isSVGTag,s.transformTemplate,s.style)}renderInstance(e,n,s,i){hl(e,n,s,i)}mount(e){this.isSVGTag=Oi(e.tagName),super.mount(e)}}const dl=(t,e)=>dn(t)?new fl(e):new cl(e,{allowProjection:t!==v.Fragment});function mt(t,e,n){const s=t.getProps();return mn(s,e,n!==void 0?n:s.custom,t)}const ke=t=>Array.isArray(t);function ml(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,pt(n))}function pl(t){return ke(t)?t[t.length-1]||0:t}function gl(t,e){const n=mt(t,e);let{transitionEnd:s={},transition:i={},...o}=n||{};o={...o,...s};for(const r in o){const a=pl(o[r]);ml(t,r,a)}}function yl(t){return!!(B(t)&&t.add)}function Fe(t,e){const n=t.getValue("willChange");if(yl(n))return n.add(e);if(!n&&Y.WillChange){const s=new Y.WillChange("auto");t.addValue("willChange",s),s.add(e)}}function Zi(t){return t.props[Ui]}const vl=t=>t!==null;function xl(t,{repeat:e,repeatType:n="loop"},s){const i=t.filter(vl),o=e&&n!=="loop"&&e%2===1?0:i.length-1;return!o||s===void 0?i[o]:s}const Tl={type:"spring",stiffness:500,damping:25,restSpeed:10},Pl=t=>({type:"spring",stiffness:550,damping:t===0?2*Math.sqrt(550):30,restSpeed:10}),Sl={type:"keyframes",duration:.8},bl={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},wl=(t,{keyframes:e})=>e.length>2?Sl:xt.has(t)?t.startsWith("scale")?Pl(e[1]):Tl:bl;function Al({when:t,delay:e,delayChildren:n,staggerChildren:s,staggerDirection:i,repeat:o,repeatType:r,repeatDelay:a,from:l,elapsed:c,...u}){return!!Object.keys(u).length}const vn=(t,e,n,s={},i,o)=>r=>{const a=sn(s,t)||{},l=a.delay||s.delay||0;let{elapsed:c=0}=s;c=c-_(l);const u={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity(),...a,delay:-c,onUpdate:f=>{e.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{r(),a.onComplete&&a.onComplete()},name:t,motionValue:e,element:o?void 0:i};Al(a)||Object.assign(u,wl(t,u)),u.duration&&(u.duration=_(u.duration)),u.repeatDelay&&(u.repeatDelay=_(u.repeatDelay)),u.from!==void 0&&(u.keyframes[0]=u.from);let h=!1;if((u.type===!1||u.duration===0&&!u.repeatDelay)&&(De(u),u.delay===0&&(h=!0)),(Y.instantAnimations||Y.skipAnimations)&&(h=!0,De(u),u.delay=0),u.allowFlatten=!a.type&&!a.ease,h&&!o&&e.get()!==void 0){const f=xl(u.keyframes,a);if(f!==void 0){C.update(()=>{u.onUpdate(f),u.onComplete()});return}}return a.isSync?new en(u):new Yo(u)};function Vl({protectedKeys:t,needsAnimating:e},n){const s=t.hasOwnProperty(n)&&e[n]!==!0;return e[n]=!1,s}function Ji(t,e,{delay:n=0,transitionOverride:s,type:i}={}){let{transition:o=t.getDefaultTransition(),transitionEnd:r,...a}=e;s&&(o=s);const l=[],c=i&&t.animationState&&t.animationState.getState()[i];for(const u in a){const h=t.getValue(u,t.latestValues[u]??null),f=a[u];if(f===void 0||c&&Vl(c,u))continue;const d={delay:n,...sn(o||{},u)},m=h.get();if(m!==void 0&&!h.isAnimating&&!Array.isArray(f)&&f===m&&!d.velocity)continue;let p=!1;if(window.MotionHandoffAnimation){const g=Zi(t);if(g){const T=window.MotionHandoffAnimation(g,u,C);T!==null&&(d.startTime=T,p=!0)}}Fe(t,u),h.start(vn(u,h,f,t.shouldReduceMotion&&vi.has(u)?{type:!1}:d,t,p));const x=h.animation;x&&l.push(x)}return r&&Promise.all(l).then(()=>{C.update(()=>{r&&gl(t,r)})}),l}function Qi(t,e,n,s=0,i=1){const o=Array.from(t).sort((c,u)=>c.sortNodePosition(u)).indexOf(e),r=t.size,a=(r-1)*s;return typeof n=="function"?n(o,r):i===1?o*s:a-o*s}function Be(t,e,n={}){var l;const s=mt(t,e,n.type==="exit"?(l=t.presenceContext)==null?void 0:l.custom:void 0);let{transition:i=t.getDefaultTransition()||{}}=s||{};
vendor: 25,449 bytes, line 17
17n.transitionOverride&&(i=n.transitionOverride);const o=s?()=>Promise.all(Ji(t,s,n)):()=>Promise.resolve(),r=t.variantChildren&&t.variantChildren.size?(c=0)=>{const{delayChildren:u=0,staggerChildren:h,staggerDirection:f}=i;return Cl(t,e,c,u,h,f,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[c,u]=a==="beforeChildren"?[o,r]:[r,o];return c().then(()=>u())}else return Promise.all([o(),r(n.delay)])}function Cl(t,e,n=0,s=0,i=0,o=1,r){const a=[];for(const l of t.variantChildren)l.notify("AnimationStart",e),a.push(Be(l,e,{...r,delay:n+(typeof s=="function"?0:s)+Qi(t.variantChildren,l,s,i,o)}).then(()=>l.notify("AnimationComplete",e)));return Promise.all(a)}function Ml(t,e,n={}){t.notify("AnimationStart",e);let s;if(Array.isArray(e)){const i=e.map(o=>Be(t,o,n));s=Promise.all(i)}else if(typeof e=="string")s=Be(t,e,n);else{const i=typeof e=="function"?mt(t,e,n.custom):e;s=Promise.all(Ji(t,i,n))}return s.then(()=>{t.notify("AnimationComplete",e)})}function tr(t,e){if(!Array.isArray(e))return!1;const n=e.length;if(n!==t.length)return!1;for(let s=0;s<n;s++)if(e[s]!==t[s])return!1;return!0}const Dl=cn.length;function er(t){if(!t)return;if(!t.isControllingVariants){const n=t.parent?er(t.parent)||{}:{};return t.props.initial!==void 0&&(n.initial=t.props.initial),n}const e={};for(let n=0;n<Dl;n++){const s=cn[n],i=t.props[s];(Rt(i)||i===!1)&&(e[s]=i)}return e}const Rl=[...un].reverse(),El=un.length;function Ll(t){return e=>Promise.all(e.map(({animation:n,options:s})=>Ml(t,n,s)))}function kl(t){let e=Ll(t),n=es(),s=!0;const i=l=>(c,u)=>{var f;const h=mt(t,u,l==="exit"?(f=t.presenceContext)==null?void 0:f.custom:void 0);if(h){const{transition:d,transitionEnd:m,...p}=h;c={...c,...p,...m}}return c};function o(l){e=l(t)}function r(l){const{props:c}=t,u=er(t.parent)||{},h=[],f=new Set;let d={},m=1/0;for(let x=0;x<El;x++){const g=Rl[x],T=n[g],y=c[g]!==void 0?c[g]:u[g],w=Rt(y),P=g===l?T.isActive:null;P===!1&&(m=x);let A=y===u[g]&&y!==c[g]&&w;if(A&&s&&t.manuallyAnimateOnMount&&(A=!1),T.protectedKeys={...d},!T.isActive&&P===null||!y&&!T.prevProp||ee(y)||typeof y=="boolean")continue;const V=Fl(T.prevProp,y);let b=V||g===l&&T.isActive&&!A&&w||x>m&&w,L=!1;const I=Array.isArray(y)?y:[y];let q=I.reduce(i(g),{});P===!1&&(q={});const{prevResolvedValues:xn={}}=T,gr={...xn,...q},Tn=k=>{b=!0,f.has(k)&&(L=!0,f.delete(k)),T.needsAnimating[k]=!0;const N=t.getValue(k);N&&(N.liveStyle=!1)};for(const k in gr){const N=q[k],et=xn[k];if(d.hasOwnProperty(k))continue;let lt=!1;ke(N)&&ke(et)?lt=!tr(N,et):lt=N!==et,lt?N!=null?Tn(k):f.add(k):N!==void 0&&f.has(k)?Tn(k):T.protectedKeys[k]=!0}T.prevProp=y,T.prevResolvedValues=q,T.isActive&&(d={...d,...q}),s&&t.blockInitialAnimation&&(b=!1);const Pn=A&&V;b&&(!Pn||L)&&h.push(...I.map(k=>{const N={type:g};if(typeof k=="string"&&s&&!Pn&&t.manuallyAnimateOnMount&&t.parent){const{parent:et}=t,lt=mt(et,k);if(et.enteringChildren&<){const{delayChildren:yr}=lt.transition||{};N.delay=Qi(et.enteringChildren,t,yr)}}return{animation:k,options:N}}))}if(f.size){const x={};if(typeof c.initial!="boolean"){const g=mt(t,Array.isArray(c.initial)?c.initial[0]:c.initial);g&&g.transition&&(x.transition=g.transition)}f.forEach(g=>{const T=t.getBaseTarget(g),y=t.getValue(g);y&&(y.liveStyle=!0),x[g]=T??null}),h.push({animation:x})}let p=!!h.length;return s&&(c.initial===!1||c.initial===c.animate)&&!t.manuallyAnimateOnMount&&(p=!1),s=!1,p?e(h):Promise.resolve()}function a(l,c){var h;if(n[l].isActive===c)return Promise.resolve();(h=t.variantChildren)==null||h.forEach(f=>{var d;return(d=f.animationState)==null?void 0:d.setActive(l,c)}),n[l].isActive=c;const u=r(l);for(const f in n)n[f].protectedKeys={};return u}return{animateChanges:r,setActive:a,setAnimateFunction:o,getState:()=>n,reset:()=>{n=es(),s=!0}}}function Fl(t,e){return typeof e=="string"?e!==t:Array.isArray(e)?!tr(e,t):!1}function nt(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function es(){return{animate:nt(!0),whileInView:nt(),whileHover:nt(),whileTap:nt(),whileDrag:nt(),whileFocus:nt(),exit:nt()}}class tt{constructor(e){this.isMounted=!1,this.node=e}update(){}}class Bl extends tt{constructor(e){super(e),e.animationState||(e.animationState=kl(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();ee(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:n}=this.node.prevProps||{};e!==n&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),(e=this.unmountControls)==null||e.call(this)}}let Il=0;class Ol extends tt{constructor(){super(...arguments),this.id=Il++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:n}=this.node.presenceContext,{isPresent:s}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===s)return;const i=this.node.animationState.setActive("exit",!e);n&&!e&&i.then(()=>{n(this.id)})}mount(){const{register:e,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),e&&(this.unmount=e(this.id))}unmount(){}}const jl={animation:{Feature:Bl},exit:{Feature:Ol}};function Lt(t,e,n,s={passive:!0}){return t.addEventListener(e,n,s),()=>t.removeEventListener(e,n)}function It(t){return{point:{x:t.pageX,y:t.pageY}}}const Nl=t=>e=>an(e)&&t(e,It(e));function wt(t,e,n,s){return Lt(t,e,Nl(n),s)}const nr=1e-4,Ul=1-nr,Wl=1+nr,sr=.01,Kl=0-sr,$l=0+sr;function O(t){return t.max-t.min}function _l(t,e,n){return Math.abs(t-e)<=n}function ns(t,e,n,s=.5){t.origin=s,t.originPoint=M(e.min,e.max,t.origin),t.scale=O(n)/O(e),t.translate=M(n.min,n.max,t.origin)-t.originPoint,(t.scale>=Ul&&t.scale<=Wl||isNaN(t.scale))&&(t.scale=1),(t.translate>=Kl&&t.translate<=$l||isNaN(t.translate))&&(t.translate=0)}function At(t,e,n,s){ns(t.x,e.x,n.x,s?s.originX:void 0),ns(t.y,e.y,n.y,s?s.originY:void 0)}function ss(t,e,n){t.min=n.min+e.min,t.max=t.min+O(e)}function Gl(t,e,n){ss(t.x,e.x,n.x),ss(t.y,e.y,n.y)}function is(t,e,n){t.min=e.min-n.min,t.max=t.min+O(e)}function Vt(t,e,n){is(t.x,e.x,n.x),is(t.y,e.y,n.y)}function W(t){return[t("x"),t("y")]}const ir=({current:t})=>t?t.ownerDocument.defaultView:null,rs=(t,e)=>Math.abs(t-e);function Hl(t,e){const n=rs(t.x,e.x),s=rs(t.y,e.y);return Math.sqrt(n**2+s**2)}class rr{constructor(e,n,{transformPagePoint:s,contextWindow:i=window,dragSnapToOrigin:o=!1,distanceThreshold:r=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=fe(this.lastMoveEventInfo,this.history),d=this.startEvent!==null,m=Hl(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!d&&!m)return;const{point:p}=f,{timestamp:x}=F;this.history.push({...p,timestamp:x});const{onStart:g,onMove:T}=this.handlers;d||(g&&g(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),T&&T(this.lastMoveEvent,f)},this.handlePointerMove=(f,d)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=he(d,this.transformPagePoint),C.update(this.updatePoint,!0)},this.handlePointerUp=(f,d)=>{this.end();const{onEnd:m,onSessionEnd:p,resumeAnimation:x}=this.handlers;if(this.dragSnapToOrigin&&x&&x(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const g=fe(f.type==="pointercancel"?this.lastMoveEventInfo:he(d,this.transformPagePoint),this.history);this.startEvent&&m&&m(f,g),p&&p(f,g)},!an(e))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=s,this.distanceThreshold=r,this.contextWindow=i||window;const a=It(e),l=he(a,this.transformPagePoint),{point:c}=l,{timestamp:u}=F;this.history=[{...c,timestamp:u}];const{onSessionStart:h}=n;h&&h(e,fe(l,this.history)),this.removeListeners=kt(wt(this.contextWindow,"pointermove",this.handlePointerMove),wt(this.contextWindow,"pointerup",this.handlePointerUp),wt(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),J(this.updatePoint)}}function he(t,e){return e?{point:e(t.point)}:t}function os(t,e){return{x:t.x-e.x,y:t.y-e.y}}function fe({point:t},e){return{point:t,delta:os(t,or(e)),offset:os(t,zl(e)),velocity:Xl(e,.1)}}function zl(t){return t[0]}function or(t){return t[t.length-1]}function Xl(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,s=null;const i=or(t);for(;n>=0&&(s=t[n],!(i.timestamp-s.timestamp>_(e)));)n--;if(!s)return{x:0,y:0};const o=G(i.timestamp-s.timestamp);if(o===0)return{x:0,y:0};const r={x:(i.x-s.x)/o,y:(i.y-s.y)/o};return r.x===1/0&&(r.x=0),r.y===1/0&&(r.y=0),r}function Yl(t,{min:e,max:n},s){return e!==void 0&&t<e?t=s?M(e,t,s.min):Math.max(t,e):n!==void 0&&t>n&&(t=s?M(n,t,s.max):Math.min(t,n)),t}function as(t,e,n){return{min:e!==void 0?t.min+e:void 0,max:n!==void 0?t.max+n-(t.max-t.min):void 0}}function ql(t,{top:e,left:n,bottom:s,right:i}){return{x:as(t.x,n,i),y:as(t.y,e,s)}}function ls(t,e){let n=e.min-t.min,s=e.max-t.max;return e.max-e.min<t.max-t.min&&([n,s]=[s,n]),{min:n,max:s}}function Zl(t,e){return{x:ls(t.x,e.x),y:ls(t.y,e.y)}}function Jl(t,e){let n=.5;const s=O(t),i=O(e);return i>s?n=Ct(e.min,e.max-s,t.min):s>i&&(n=Ct(t.min,t.max-i,e.min)),X(0,1,n)}function Ql(t,e){const n={};return e.min!==void 0&&(n.min=e.min-t.min),e.max!==void 0&&(n.max=e.max-t.min),n}const Ie=.35;function tu(t=Ie){return t===!1?t=0:t===!0&&(t=Ie),{x:us(t,"left","right"),y:us(t,"top","bottom")}}function us(t,e,n){return{min:cs(t,e),max:cs(t,n)}}function cs(t,e){return typeof t=="number"?t:t[e]||0}const eu=new WeakMap;class nu{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=R(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e}start(e,{snapToCursor:n=!1,distanceThreshold:s}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const o=h=>{const{dragSnapToOrigin:f}=this.getProps();f?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(It(h).point)},r=(h,f)=>{const{drag:d,dragPropagation:m,onDragStart:p}=this.getProps();if(d&&!m&&(this.openDragLock&&this.openDragLock(),this.openDragLock=ha(d),!this.openDragLock))return;this.latestPointerEvent=h,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),W(g=>{let T=this.getAxisMotionValue(g).get()||0;if(H.test(T)){const{projection:y}=this.visualElement;if(y&&y.layout){const w=y.layout.layoutBox[g];w&&(T=O(w)*(parseFloat(T)/100))}}this.originPoint[g]=T}),p&&C.postRender(()=>p(h,f)),Fe(this.visualElement,"transform");const{animationState:x}=this.visualElement;x&&x.setActive("whileDrag",!0)},a=(h,f)=>{this.latestPointerEvent=h,this.latestPanInfo=f;const{dragPropagation:d,dragDirectionLock:m,onDirectionLock:p,onDrag:x}=this.getProps();if(!d&&!this.openDragLock)return;const{offset:g}=f;if(m&&this.currentDirection===null){this.currentDirection=su(g),this.currentDirection!==null&&p&&p(this.currentDirection);return}this.updateAxis("x",f.point,g),this.updateAxis("y",f.point,g),this.visualElement.render(),x&&x(h,f)},l=(h,f)=>{this.latestPointerEvent=h,this.latestPanInfo=f,this.stop(h,f),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>W(h=>{var f;return this.getAnimationState(h)==="paused"&&((f=this.getAxisMotionValue(h).animation)==null?void 0:f.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new rr(e,{onSessionStart:o,onStart:r,onMove:a,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,distanceThreshold:s,contextWindow:ir(this.visualElement)})}stop(e,n){const s=e||this.latestPointerEvent,i=n||this.latestPanInfo,o=this.isDragging;if(this.cancel(),!o||!i||!s)return;const{velocity:r}=i;this.startAnimation(r);const{onDragEnd:a}=this.getProps();a&&C.postRender(()=>a(s,i))}cancel(){this.isDragging=!1;const{projection:e,animationState:n}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:s}=this.getProps();!s&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(e,n,s){const{drag:i}=this.getProps();if(!s||!Ut(e,i,this.currentDirection))return;const o=this.getAxisMotionValue(e);let r=this.originPoint[e]+s[e];this.constraints&&this.constraints[e]&&(r=Yl(r,this.constraints[e],this.elastic[e])),o.set(r)}resolveConstraints(){var o;const{dragConstraints:e,dragElastic:n}=this.getProps(),s=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(o=this.visualElement.projection)==null?void 0:o.layout,i=this.constraints;e&&ct(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):e&&s?this.constraints=ql(s.layoutBox,e):this.constraints=!1,this.elastic=tu(n),i!==this.constraints&&s&&this.constraints&&!this.hasMutatedConstraints&&W(r=>{this.constraints!==!1&&this.getAxisMotionValue(r)&&(this.constraints[r]=Ql(s.layoutBox[r],this.constraints[r]))})}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:n}=this.getProps();if(!e||!ct(e))return!1;const s=e.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const o=rl(s,i.root,this.visualElement.getTransformPagePoint());let r=Zl(i.layout.layoutBox,o);if(n){const a=n(nl(r));this.hasMutatedConstraints=!!a,a&&(r=$i(a))}return r}startAnimation(e){const{drag:n,dragMomentum:s,dragElastic:i,dragTransition:o,dragSnapToOrigin:r,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},c=W(u=>{if(!Ut(u,n,this.currentDirection))return;let h=l&&l[u]||{};r&&(h={min:0,max:0});const f=i?200:1e6,d=i?40:1e7,m={type:"inertia",velocity:s?e[u]:0,bounceStiffness:f,bounceDamping:d,timeConstant:750,restDelta:1,restSpeed:10,...o,...h};return this.startAxisValueAnimation(u,m)});return Promise.all(c).then(a)}startAxisValueAnimation(e,n){const s=this.getAxisMotionValue(e);return Fe(this.visualElement,e),s.start(vn(e,s,0,n,this.visualElement,!1))}stopAnimation(){W(e=>this.getAxisMotionValue(e).stop())}pauseAnimation(){W(e=>{var n;return(n=this.getAxisMotionValue(e).animation)==null?void 0:n.pause()})}getAnimationState(e){var n;return(n=this.getAxisMotionValue(e).animation)==null?void 0:n.state}getAxisMotionValue(e){const n=`_drag${e.toUpperCase()}`,s=this.visualElement.getProps(),i=s[n];return i||this.visualElement.getValue(e,(s.initial?s.initial[e]:void 0)||0)}snapToCursor(e){W(n=>{const{drag:s}=this.getProps();if(!Ut(n,s,this.currentDirection))return;const{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){const{min:r,max:a}=i.layout.layoutBox[n];o.set(e[n]-M(r,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:n}=this.getProps(),{projection:s}=this.visualElement;if(!ct(n)||!s||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};W(r=>{const a=this.getAxisMotionValue(r);if(a&&this.constraints!==!1){const l=a.get();i[r]=Jl({min:l,max:l},this.constraints[r])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",s.root&&s.root.updateScroll(),s.updateLayout(),this.resolveConstraints(),W(r=>{if(!Ut(r,e,null))return;const a=this.getAxisMotionValue(r),{min:l,max:c}=this.constraints[r];a.set(M(l,c,i[r]))})}addListeners(){if(!this.visualElement.current)return;eu.set(this.visualElement,this);const e=this.visualElement.current,n=wt(e,"pointerdown",l=>{const{drag:c,dragListener:u=!0}=this.getProps();c&&u&&this.start(l)}),s=()=>{const{dragConstraints:l}=this.getProps();ct(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,o=i.addEventListener("measure",s);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),C.read(s);const r=Lt(window,"resize",()=>this.scalePositionWithinConstraints()),a=i.addEventListener("didUpdate",({delta:l,hasLayoutChanged:c})=>{this.isDragging&&c&&(W(u=>{const h=this.getAxisMotionValue(u);h&&(this.originPoint[u]+=l[u].translate,h.set(h.get()+l[u].translate))}),this.visualElement.render())});return()=>{r(),n(),o(),a&&a()}}getProps(){const e=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:s=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:r=Ie,dragMomentum:a=!0}=e;return{...e,drag:n,dragDirectionLock:s,dragPropagation:i,dragConstraints:o,dragElastic:r,dragMomentum:a}}}function Ut(t,e,n){return(e===!0||e===t)&&(n===null||n===t)}function su(t,e=10){let n=null;return Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x"),n}class iu extends tt{constructor(e){super(e),this.removeGroupControls=K,this.removeListeners=K,this.controls=new nu(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||K}unmount(){this.removeGroupControls(),this.removeListeners()}}const hs=t=>(e,n)=>{t&&C.postRender(()=>t(e,n))};class ru extends tt{constructor(){super(...arguments),this.removePointerDownListener=K}onPointerDown(e){this.session=new rr(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:ir(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:n,onPan:s,onPanEnd:i}=this.node.getProps();return{onSessionStart:hs(e),onStart:hs(n),onMove:s,onEnd:(o,r)=>{delete this.session,i&&C.postRender(()=>i(o,r))}}}mount(){this.removePointerDownListener=wt(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const _t={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function fs(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}const Tt={correct:(t,e)=>{if(!e.target)return t;if(typeof t=="string")if(S.test(t))t=parseFloat(t);else return t;const n=fs(t,e.target.x),s=fs(t,e.target.y);return`${n}% ${s}%`}},ou={correct:(t,{treeScale:e,projectionDelta:n})=>{const s=t,i=Q.parse(t);if(i.length>5)return s;const o=Q.createTransformer(t),r=typeof i[0]!="number"?1:0,a=n.x.scale*e.x,l=n.y.scale*e.y;i[0+r]/=a,i[1+r]/=l;const c=M(a,l,.5);return typeof i[2+r]=="number"&&(i[2+r]/=c),typeof i[3+r]=="number"&&(i[3+r]/=c),o(i)}};let de=!1;class au extends v.Component{componentDidMount(){const{visualElement:e,layoutGroup:n,switchLayoutGroup:s,layoutId:i}=this.props,{projection:o}=e;Ra(lu),o&&(n.group&&n.group.add(o),s&&s.register&&i&&s.register(o),de&&o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),_t.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:n,visualElement:s,drag:i,isPresent:o}=this.props,{projection:r}=s;return r&&(r.isPresent=o,de=!0,i||e.layoutDependency!==n||n===void 0||e.isPresent!==o?r.willUpdate():this.safeToRemove(),e.isPresent!==o&&(o?r.promote():r.relegate()||C.postRender(()=>{const a=r.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),on.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:e,layoutGroup:n,switchLayoutGroup:s}=this.props,{projection:i}=e;de=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),s&&s.deregister&&s.deregister(i))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function ar(t){const[e,n]=Di(),s=v.useContext(je);return z.jsx(au,{...t,layoutGroup:s,switchLayoutGroup:v.useContext(Wi),isPresent:e,safeToRemove:n})}const lu={borderRadius:{...Tt,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Tt,borderTopRightRadius:Tt,borderBottomLeftRadius:Tt,borderBottomRightRadius:Tt,boxShadow:ou};function uu(t,e,n){const s=B(t)?t:pt(t);return s.start(vn("",s,e,n)),s.animation}const cu=(t,e)=>t.depth-e.depth;class hu{constructor(){this.children=[],this.isDirty=!1}add(e){We(this.children,e),this.isDirty=!0}remove(e){Ke(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(cu),this.isDirty=!1,this.children.forEach(e)}}function fu(t,e){const n=j.now(),s=({timestamp:i})=>{const o=i-n;o>=e&&(J(s),t(o-e))};return C.setup(s,!0),()=>J(s)}const lr=["TopLeft","TopRight","BottomLeft","BottomRight"],du=lr.length,ds=t=>typeof t=="string"?parseFloat(t):t,ms=t=>typeof t=="number"||S.test(t);function mu(t,e,n,s,i,o){i?(t.opacity=M(0,n.opacity??1,pu(s)),t.opacityExit=M(e.opacity??1,0,gu(s))):o&&(t.opacity=M(e.opacity??1,n.opacity??1,s));for(let r=0;r<du;r++){const a=`border${lr[r]}Radius`;let l=ps(e,a),c=ps(n,a);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||ms(l)===ms(c)?(t[a]=Math.max(M(ds(l),ds(c),s),0),(H.test(c)||H.test(l))&&(t[a]+="%")):t[a]=c}(e.rotate||n.rotate)&&(t.rotate=M(e.rotate||0,n.rotate||0,s))}function ps(t,e){return t[e]!==void 0?t[e]:t.borderRadius}const pu=ur(0,.5,Ys),gu=ur(.5,.95,K);function ur(t,e,n){return s=>s<t?0:s>e?1:n(Ct(t,e,s))}function gs(t,e){t.min=e.min,t.max=e.max}function U(t,e){gs(t.x,e.x),gs(t.y,e.y)}function ys(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}function vs(t,e,n,s,i){return t-=e,t=qt(t,1/n,s),i!==void 0&&(t=qt(t,1/i,s)),t}function yu(t,e=0,n=1,s=.5,i,o=t,r=t){if(H.test(e)&&(e=parseFloat(e),e=M(r.min,r.max,e/100)-r.min),typeof e!="number")return;let a=M(o.min,o.max,s);t===o&&(a-=e),t.min=vs(t.min,e,n,a,i),t.max=vs(t.max,e,n,a,i)}function xs(t,e,[n,s,i],o,r){yu(t,e[n],e[s],e[i],e.scale,o,r)}const vu=["x","scaleX","originX"],xu=["y","scaleY","originY"];function Ts(t,e,n,s){xs(t.x,e,vu,n?n.x:void 0,s?s.x:void 0),xs(t.y,e,xu,n?n.y:void 0,s?s.y:void 0)}function Ps(t){return t.translate===0&&t.scale===1}function cr(t){return Ps(t.x)&&Ps(t.y)}function Ss(t,e){return t.min===e.min&&t.max===e.max}function Tu(t,e){return Ss(t.x,e.x)&&Ss(t.y,e.y)}function bs(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function hr(t,e){return bs(t.x,e.x)&&bs(t.y,e.y)}function ws(t){return O(t.x)/O(t.y)}function As(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}class Pu{constructor(){this.members=[]}add(e){We(this.members,e),e.scheduleRender()}remove(e){if(Ke(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(e){const n=this.members.findIndex(i=>e===i);if(n===0)return!1;let s;for(let i=n;i>=0;i--){const o=this.members[i];if(o.isPresent!==!1){s=o;break}}return s?(this.promote(s),!0):!1}promote(e,n){const s=this.lead;if(e!==s&&(this.prevLead=s,this.lead=e,e.show(),s)){s.instance&&s.scheduleRender(),e.scheduleRender(),e.resumeFrom=s,n&&(e.resumeFrom.preserveOpacity=!0),s.snapshot&&(e.snapshot=s.snapshot,e.snapshot.latestValues=s.animationValues||s.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);const{crossfade:i}=e.options;i===!1&&s.hide()}}exitAnimationComplete(){this.members.forEach(e=>{const{options:n,resumingFrom:s}=e;n.onExitComplete&&n.onExitComplete(),s&&s.options.onExitComplete&&s.options.onExitComplete()})}scheduleRender(){this.members.forEach(e=>{e.instance&&e.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function Su(t,e,n){let s="";const i=t.x.translate/e.x,o=t.y.translate/e.y,r=(n==null?void 0:n.z)||0;if((i||o||r)&&(s=`translate3d(${i}px, ${o}px, ${r}px) `),(e.x!==1||e.y!==1)&&(s+=`scale(${1/e.x}, ${1/e.y}) `),n){const{transformPerspective:c,rotate:u,rotateX:h,rotateY:f,skewX:d,skewY:m}=n;c&&(s=`perspective(${c}px) ${s}`),u&&(s+=`rotate(${u}deg) `),h&&(s+=`rotateX(${h}deg) `),f&&(s+=`rotateY(${f}deg) `),d&&(s+=`skewX(${d}deg) `),m&&(s+=`skewY(${m}deg) `)}const a=t.x.scale*e.x,l=t.y.scale*e.y;return(a!==1||l!==1)&&(s+=`scale(${a}, ${l})`),s||"none"}const me=["","X","Y","Z"],bu=1e3;let wu=0;function pe(t,e,n,s){const{latestValues:i}=e;i[t]&&(n[t]=i[t],e.setStaticValue(t,0),s&&(s[t]=0))}function fr(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;const{visualElement:e}=t.options;if(!e)return;const n=Zi(e);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:o}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",C,!(i||o))}const{parent:s}=t;s&&!s.hasCheckedOptimisedAppear&&fr(s)}function dr({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:s,resetTransform:i}){return class{constructor(r={},a=e==null?void 0:e()){this.id=wu++,this.animationId=0,this.animationCommitId=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.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>
vendor: 4,292 bytes, line 17
17{this.projectionUpdateScheduled=!1,this.nodes.forEach(Cu),this.nodes.forEach(Eu),this.nodes.forEach(Lu),this.nodes.forEach(Mu)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=r,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new hu)}addEventListener(r,a){return this.eventHandlers.has(r)||this.eventHandlers.set(r,new _e),this.eventHandlers.get(r).add(a)}notifyListeners(r,...a){const l=this.eventHandlers.get(r);l&&l.notify(...a)}hasListeners(r){return this.eventHandlers.has(r)}mount(r){if(this.instance)return;this.isSVG=Mi(r)&&!ya(r),this.instance=r;const{layoutId:a,layout:l,visualElement:c}=this.options;if(c&&!c.current&&c.mount(r),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),t){let u,h=0;const f=()=>this.root.updateBlockedByResize=!1;C.read(()=>{h=window.innerWidth}),t(r,()=>{const d=window.innerWidth;d!==h&&(h=d,this.root.updateBlockedByResize=!0,u&&u(),u=fu(f,250),_t.hasAnimatedSinceResize&&(_t.hasAnimatedSinceResize=!1,this.nodes.forEach(Ms)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||l)&&this.addEventListener("didUpdate",({delta:u,hasLayoutChanged:h,hasRelativeLayoutChanged:f,layout:d})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const m=this.options.transition||c.getDefaultTransition()||Ou,{onLayoutAnimationStart:p,onLayoutAnimationComplete:x}=c.getProps(),g=!this.targetLayout||!hr(this.targetLayout,d),T=!h&&f;if(this.options.layoutRoot||this.resumeFrom||T||h&&(g||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const y={...sn(m,"layout"),onPlay:p,onComplete:x};(c.shouldReduceMotion||this.options.layoutRoot)&&(y.delay=0,y.type=!1),this.startAnimation(y),this.setAnimationOrigin(u,T)}else h||Ms(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=d})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const r=this.getStack();r&&r.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),J(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(ku),this.animationId++)}getTransformTemplate(){const{visualElement:r}=this.options;return r&&r.getProps().transformTemplate}willUpdate(r=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&fr(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let u=0;u<this.path.length;u++){const h=this.path[u];h.shouldResetTransform=!0,h.updateScroll("snapshot"),h.options.layoutRoot&&h.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),r&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Vs);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Cs);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Ru),this.nodes.forEach(Au),this.nodes.forEach(Vu)):this.nodes.forEach(Cs),this.clearAllSnapshots();const a=j.now();F.delta=X(0,1e3/60,a-F.timestamp),F.timestamp=a,F.isProcessing=!0,se.update.process(F),se.preRender.process(F),se.render.process(F),F.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,on.read(this.scheduleUpdate))}
vendor: 19,716 bytes, line 17
17clearAllSnapshots(){this.nodes.forEach(Du),this.sharedNodes.forEach(Fu)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,C.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){C.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!O(this.snapshot.measuredBox.x)&&!O(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const r=this.layout;this.layout=this.measure(!1),this.layoutCorrected=R(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,r?r.layoutBox:void 0)}updateScroll(r="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===r&&(a=!1),a&&this.instance){const l=s(this.instance);this.scroll={animationId:this.root.animationId,phase:r,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!i)return;const r=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!cr(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,u=c!==this.prevTransformTemplateValue;r&&this.instance&&(a||st(this.latestValues)||u)&&(i(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(r=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return r&&(l=this.removeTransform(l)),ju(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var c;const{visualElement:r}=this.options;if(!r)return R();const a=r.measureViewportBox();if(!(((c=this.scroll)==null?void 0:c.wasRoot)||this.path.some(Nu))){const{scroll:u}=this.root;u&&(ht(a.x,u.offset.x),ht(a.y,u.offset.y))}return a}removeElementScroll(r){var l;const a=R();if(U(a,r),(l=this.scroll)!=null&&l.wasRoot)return a;for(let c=0;c<this.path.length;c++){const u=this.path[c],{scroll:h,options:f}=u;u!==this.root&&h&&f.layoutScroll&&(h.wasRoot&&U(a,r),ht(a.x,h.offset.x),ht(a.y,h.offset.y))}return a}applyTransform(r,a=!1){const l=R();U(l,r);for(let c=0;c<this.path.length;c++){const u=this.path[c];!a&&u.options.layoutScroll&&u.scroll&&u!==u.root&&ft(l,{x:-u.scroll.offset.x,y:-u.scroll.offset.y}),st(u.latestValues)&&ft(l,u.latestValues)}return st(this.latestValues)&&ft(l,this.latestValues),l}removeTransform(r){const a=R();U(a,r);for(let l=0;l<this.path.length;l++){const c=this.path[l];if(!c.instance||!st(c.latestValues))continue;Ee(c.latestValues)&&c.updateSnapshot();const u=R(),h=c.measurePageBox();U(u,h),Ts(a,c.latestValues,c.snapshot?c.snapshot.layoutBox:void 0,u)}return st(this.latestValues)&&Ts(a,this.latestValues),a}setTargetDelta(r){this.targetDelta=r,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(r){this.options={...this.options,...r,crossfade:r.crossfade!==void 0?r.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!==F.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(r=!1){var f;const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(r||l&&this.isSharedProjectionDirty||this.isProjectionDirty||(f=this.parent)!=null&&f.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:u,layoutId:h}=this.options;if(!(!this.layout||!(u||h))){if(this.resolvedRelativeTargetAt=F.timestamp,!this.targetDelta&&!this.relativeTarget){const d=this.getClosestProjectingParent();d&&d.layout&&this.animationProgress!==1?(this.relativeParent=d,this.forceRelativeParentToResolveTarget(),this.relativeTarget=R(),this.relativeTargetOrigin=R(),Vt(this.relativeTargetOrigin,this.layout.layoutBox,d.layout.layoutBox),U(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=R(),this.targetWithTransforms=R()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Gl(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):U(this.target,this.layout.layoutBox),Gi(this.target,this.targetDelta)):U(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget)){this.attemptToResolveRelativeTarget=!1;const d=this.getClosestProjectingParent();d&&!!d.resumingFrom==!!this.resumingFrom&&!d.options.layoutScroll&&d.target&&this.animationProgress!==1?(this.relativeParent=d,this.forceRelativeParentToResolveTarget(),this.relativeTarget=R(),this.relativeTargetOrigin=R(),Vt(this.relativeTargetOrigin,this.target,d.target),U(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}}}getClosestProjectingParent(){if(!(!this.parent||Ee(this.parent.latestValues)||_i(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 m;const r=this.getLead(),a=!!this.resumingFrom||this!==r;let l=!0;if((this.isProjectionDirty||(m=this.parent)!=null&&m.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===F.timestamp&&(l=!1),l)return;const{layout:c,layoutId:u}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||u))return;U(this.layoutCorrected,this.layout.layoutBox);const h=this.treeScale.x,f=this.treeScale.y;il(this.layoutCorrected,this.treeScale,this.path,a),r.layout&&!r.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(r.target=r.layout.layoutBox,r.targetWithTransforms=R());const{target:d}=r;if(!d){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(ys(this.prevProjectionDelta.x,this.projectionDelta.x),ys(this.prevProjectionDelta.y,this.projectionDelta.y)),At(this.projectionDelta,this.layoutCorrected,d,this.latestValues),(this.treeScale.x!==h||this.treeScale.y!==f||!As(this.projectionDelta.x,this.prevProjectionDelta.x)||!As(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",d))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(r=!0){var a;if((a=this.options.visualElement)==null||a.scheduleRender(),r){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=dt(),this.projectionDelta=dt(),this.projectionDeltaWithTransform=dt()}setAnimationOrigin(r,a=!1){const l=this.snapshot,c=l?l.latestValues:{},u={...this.latestValues},h=dt();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const f=R(),d=l?l.source:void 0,m=this.layout?this.layout.source:void 0,p=d!==m,x=this.getStack(),g=!x||x.members.length<=1,T=!!(p&&!g&&this.options.crossfade===!0&&!this.path.some(Iu));this.animationProgress=0;let y;this.mixTargetDelta=w=>{const P=w/1e3;Ds(h.x,r.x,P),Ds(h.y,r.y,P),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Vt(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Bu(this.relativeTarget,this.relativeTargetOrigin,f,P),y&&Tu(this.relativeTarget,y)&&(this.isProjectionDirty=!1),y||(y=R()),U(y,this.relativeTarget)),p&&(this.animationValues=u,mu(u,c,this.latestValues,P,T,g)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=P},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(r){var a,l,c;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(c=(l=this.resumingFrom)==null?void 0:l.currentAnimation)==null||c.stop(),this.pendingAnimation&&(J(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=C.update(()=>{_t.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=pt(0)),this.currentAnimation=uu(this.motionValue,[0,1e3],{...r,velocity:0,isSync:!0,onUpdate:u=>{this.mixTargetDelta(u),r.onUpdate&&r.onUpdate(u)},onStop:()=>{},onComplete:()=>{r.onComplete&&r.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 r=this.getStack();r&&r.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(bu),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const r=this.getLead();let{targetWithTransforms:a,target:l,layout:c,latestValues:u}=r;if(!(!a||!l||!c)){if(this!==r&&this.layout&&c&&mr(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||R();const h=O(this.layout.layoutBox.x);l.x.min=r.target.x.min,l.x.max=l.x.min+h;const f=O(this.layout.layoutBox.y);l.y.min=r.target.y.min,l.y.max=l.y.min+f}U(a,l),ft(a,u),At(this.projectionDeltaWithTransform,this.layoutCorrected,a,u)}}registerSharedNode(r,a){this.sharedNodes.has(r)||this.sharedNodes.set(r,new Pu),this.sharedNodes.get(r).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const r=this.getStack();return r?r.lead===this:!0}getLead(){var a;const{layoutId:r}=this.options;return r?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:r}=this.options;return r?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:r}=this.options;if(r)return this.root.sharedNodes.get(r)}promote({needsReset:r,transition:a,preserveFollowOpacity:l}={}){const c=this.getStack();c&&c.promote(this,l),r&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const r=this.getStack();return r?r.relegate(this):!1}resetSkewAndRotation(){const{visualElement:r}=this.options;if(!r)return;let a=!1;const{latestValues:l}=r;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const c={};l.z&&pe("z",r,c,this.animationValues);for(let u=0;u<me.length;u++)pe(`rotate${me[u]}`,r,c,this.animationValues),pe(`skew${me[u]}`,r,c,this.animationValues);r.render();for(const u in c)r.setStaticValue(u,c[u]),this.animationValues&&(this.animationValues[u]=c[u]);r.scheduleRender()}applyProjectionStyles(r,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){r.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,r.visibility="",r.opacity="",r.pointerEvents=$t(a==null?void 0:a.pointerEvents)||"",r.transform=l?l(this.latestValues,""):"none";return}const c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){this.options.layoutId&&(r.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,r.pointerEvents=$t(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!st(this.latestValues)&&(r.transform=l?l({},""):"none",this.hasProjected=!1);return}r.visibility="";const u=c.animationValues||c.latestValues;this.applyTransformsToTarget();let h=Su(this.projectionDeltaWithTransform,this.treeScale,u);l&&(h=l(u,h)),r.transform=h;const{x:f,y:d}=this.projectionDelta;r.transformOrigin=`${f.origin*100}% ${d.origin*100}% 0`,c.animationValues?r.opacity=c===this?u.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:u.opacityExit:r.opacity=c===this?u.opacity!==void 0?u.opacity:"":u.opacityExit!==void 0?u.opacityExit:0;for(const m in Et){if(u[m]===void 0)continue;const{correct:p,applyTo:x,isCSSVariable:g}=Et[m],T=h==="none"?u[m]:p(u[m],c);if(x){const y=x.length;for(let w=0;w<y;w++)r[x[w]]=T}else g?this.options.visualElement.renderState.vars[m]=T:r[m]=T}this.options.layoutId&&(r.pointerEvents=c===this?$t(a==null?void 0:a.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(r=>{var a;return(a=r.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Vs),this.root.sharedNodes.clear()}}}function Au(t){t.updateLayout()}function Vu(t){var n;const e=((n=t.resumeFrom)==null?void 0:n.snapshot)||t.snapshot;if(t.isLead()&&t.layout&&e&&t.hasListeners("didUpdate")){const{layoutBox:s,measuredBox:i}=t.layout,{animationType:o}=t.options,r=e.source!==t.layout.source;o==="size"?W(h=>{const f=r?e.measuredBox[h]:e.layoutBox[h],d=O(f);f.min=s[h].min,f.max=f.min+d}):mr(o,e.layoutBox,s)&&W(h=>{const f=r?e.measuredBox[h]:e.layoutBox[h],d=O(s[h]);f.max=f.min+d,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[h].max=t.relativeTarget[h].min+d)});const a=dt();At(a,s,e.layoutBox);const l=dt();r?At(l,t.applyTransform(i,!0),e.measuredBox):At(l,s,e.layoutBox);const c=!cr(a);let u=!1;if(!t.resumeFrom){const h=t.getClosestProjectingParent();if(h&&!h.resumeFrom){const{snapshot:f,layout:d}=h;if(f&&d){const m=R();Vt(m,e.layoutBox,f.layoutBox);const p=R();Vt(p,s,d.layoutBox),hr(m,p)||(u=!0),h.options.layoutRoot&&(t.relativeTarget=p,t.relativeTargetOrigin=m,t.relativeParent=h)}}}t.notifyListeners("didUpdate",{layout:s,snapshot:e,delta:l,layoutDelta:a,hasLayoutChanged:c,hasRelativeLayoutChanged:u})}else if(t.isLead()){const{onExitComplete:s}=t.options;s&&s()}t.options.transition=void 0}function Cu(t){t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function Mu(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function Du(t){t.clearSnapshot()}function Vs(t){t.clearMeasurements()}function Cs(t){t.isLayoutDirty=!1}function Ru(t){const{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function Ms(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function Eu(t){t.resolveTargetDelta()}function Lu(t){t.calcProjection()}function ku(t){t.resetSkewAndRotation()}function Fu(t){t.removeLeadSnapshot()}function Ds(t,e,n){t.translate=M(e.translate,0,n),t.scale=M(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function Rs(t,e,n,s){t.min=M(e.min,n.min,s),t.max=M(e.max,n.max,s)}function Bu(t,e,n,s){Rs(t.x,e.x,n.x,s),Rs(t.y,e.y,n.y,s)}function Iu(t){return t.animationValues&&t.animationValues.opacityExit!==void 0}const Ou={duration:.45,ease:[.4,0,.1,1]},Es=t=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),Ls=Es("applewebkit/")&&!Es("chrome/")?Math.round:K;function ks(t){t.min=Ls(t.min),t.max=Ls(t.max)}function ju(t){ks(t.x),ks(t.y)}function mr(t,e,n){return t==="position"||t==="preserve-aspect"&&!_l(ws(e),ws(n),.2)}function Nu(t){var e;return t!==t.root&&((e=t.scroll)==null?void 0:e.wasRoot)}const Uu=dr({attachResizeListener:(t,e)=>Lt(t,"resize",e),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),ge={current:void 0},pr=dr({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!ge.current){const t=new Uu({});t.mount(window),t.setOptions({layoutScroll:!0}),ge.current=t}return ge.current},resetTransform:(t,e)=>{t.style.transform=e!==void 0?e:"none"},checkIsScrollRoot:t=>window.getComputedStyle(t).position==="fixed"}),Wu={pan:{Feature:ru},drag:{Feature:iu,ProjectionNode:pr,MeasureLayout:ar}};function Fs(t,e,n){const{props:s}=t;t.animationState&&s.whileHover&&t.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,o=s[i];o&&C.postRender(()=>o(e,It(e)))}class Ku extends tt{mount(){const{current:e}=this.node;e&&(this.unmount=fa(e,(n,s)=>(Fs(this.node,s,"Start"),i=>Fs(this.node,i,"End"))))}unmount(){}}class $u extends tt{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch{e=!0}!e||!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=kt(Lt(this.node.current,"focus",()=>this.onFocus()),Lt(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Bs(t,e,n){const{props:s}=t;if(t.current instanceof HTMLButtonElement&&t.current.disabled)return;t.animationState&&s.whileTap&&t.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),o=s[i];o&&C.postRender(()=>o(e,It(e)))}class _u extends tt{mount(){const{current:e}=this.node;e&&(this.unmount=ga(e,(n,s)=>(Bs(this.node,s,"Start"),(i,{success:o})=>Bs(this.node,i,o?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Oe=new WeakMap,ye=new WeakMap,Gu=t=>{const e=Oe.get(t.target);e&&e(t)},Hu=t=>{t.forEach(Gu)};function zu({root:t,...e}){const n=t||document;ye.has(n)||ye.set(n,{});const s=ye.get(n),i=JSON.stringify(e);return s[i]||(s[i]=new IntersectionObserver(Hu,{root:t,...e})),s[i]}function Xu(t,e,n){const s=zu(e);return Oe.set(t,n),s.observe(t),()=>{Oe.delete(t),s.unobserve(t)}}const Yu={some:0,all:1};class qu extends tt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:n,margin:s,amount:i="some",once:o}=e,r={root:n?n.current:void 0,rootMargin:s,threshold:typeof i=="number"?i:Yu[i]},a=l=>{const{isIntersecting:c}=l;if(this.isInView===c||(this.isInView=c,o&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);const{onViewportEnter:u,onViewportLeave:h}=this.node.getProps(),f=c?u:h;f&&f(l)};return Xu(this.node.current,r,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:e,prevProps:n}=this.node;["amount","margin","root"].some(Zu(e,n))&&this.startObserver()}unmount(){}}function Zu({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}
17const Ju={inView:{Feature:qu},tap:{Feature:_u},focus:{Feature:$u},hover:{Feature:Ku}},Qu={layout:{ProjectionNode:pr,MeasureLayout:ar}},tc={...jl,...Ju,...Wu,...Qu},oc=el(tc,dl);function ac(){!yn.current&&zi();const[t]=v.useState(Zt.current);return t}export{ic as A,z as j,oc as m,ac as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.