motion-v 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1 @@
1
+ (function(d,p){typeof exports=="object"&&typeof module<"u"?p(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],p):(d=typeof globalThis<"u"?globalThis:d||self,p(d["motion-v"]={},d.vue))})(this,function(d,p){"use strict";function Xs(e,t){e.indexOf(t)===-1&&e.push(t)}function Le(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class Ne{constructor(){this.subscriptions=[]}add(t){return Xs(this.subscriptions,t),()=>Le(this.subscriptions,t)}notify(t,n,s){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,s);else for(let r=0;r<i;r++){const o=this.subscriptions[r];o&&o(t,n,s)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}function Wt(e,t){return t?e*(1e3/t):0}const ke=new Set;function wt(e,t,n){e||ke.has(t)||(console.warn(t),ke.add(t))}const qs={skipAnimations:!1,useManualTiming:!1},N=e=>e;function Zs(e){let t=new Set,n=new Set,s=!1,i=!1;const r=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1};function a(u){r.has(u)&&(l.schedule(u),e()),u(o)}const l={schedule:(u,c=!1,f=!1)=>{const g=f&&s?t:n;return c&&r.add(u),g.has(u)||g.add(u),u},cancel:u=>{n.delete(u),r.delete(u)},process:u=>{if(o=u,s){i=!0;return}s=!0,[t,n]=[n,t],n.clear(),t.forEach(a),s=!1,i&&(i=!1,l.process(u))}};return l}const rt=["read","resolveKeyframes","update","preRender","render","postRender"],Js=40;function Qs(e,t){let n=!1,s=!0;const i={delta:0,timestamp:0,isProcessing:!1},r=()=>n=!0,o=rt.reduce((v,b)=>(v[b]=Zs(r),v),{}),{read:a,resolveKeyframes:l,update:u,preRender:c,render:f,postRender:h}=o,g=()=>{const v=performance.now();n=!1,i.delta=s?1e3/60:Math.max(Math.min(v-i.timestamp,Js),1),i.timestamp=v,i.isProcessing=!0,a.process(i),l.process(i),u.process(i),c.process(i),f.process(i),h.process(i),i.isProcessing=!1,n&&t&&(s=!1,e(g))},y=()=>{n=!0,s=!0,i.isProcessing||e(g)};return{schedule:rt.reduce((v,b)=>{const A=o[b];return v[b]=(M,V=!1,x=!1)=>(n||y(),A.schedule(M,V,x)),v},{}),cancel:v=>{for(let b=0;b<rt.length;b++)o[rt[b]].cancel(v)},state:i,steps:o}}const{schedule:P,cancel:R,state:j,steps:ti}=Qs(typeof requestAnimationFrame<"u"?requestAnimationFrame:N,!0);let Tt;function ei(){Tt=void 0}const k={now:()=>(Tt===void 0&&k.set(j.isProcessing||qs.useManualTiming?j.timestamp:performance.now()),Tt),set:e=>{Tt=e,queueMicrotask(ei)}},Ke=30,ni=e=>!isNaN(parseFloat(e)),W={current:void 0};class $e{constructor(t,n={}){this.version="11.11.11",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(s,i=!0)=>{const r=k.now();this.updatedAt!==r&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(s),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),i&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=k.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=ni(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&wt(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Ne);const s=this.events[t].add(n);return t==="change"?()=>{s(),P.read(()=>{this.events.change.getSize()||this.stop()})}:s}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t,n=!0){!n||!this.passiveEffect?this.updateAndNotify(t,n):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,n,s){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-s}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return W.current&&W.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){const t=k.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Ke)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Ke);return Wt(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function D(e,t){return new $e(e,t)}function Vt(e){let t;return()=>(t===void 0&&(t=e()),t)}const We=Vt(()=>window.ScrollTimeline!==void 0);class _t{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}then(t,n){return Promise.all(this.animations).then(t).catch(n)}getAll(t){return this.animations[0][t]}setAll(t,n){for(let s=0;s<this.animations.length;s++)this.animations[s][t]=n}attachTimeline(t,n){const s=this.animations.map(i=>We()&&i.attachTimeline?i.attachTimeline(t):n(i));return()=>{s.forEach((i,r)=>{i&&i(),this.animations[r].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let n=0;n<this.animations.length;n++)t=Math.max(t,this.animations[n].duration);return t}runAll(t){this.animations.forEach(n=>n[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}const O=e=>e*1e3,L=e=>e/1e3,si=5;function _e(e,t,n){const s=Math.max(t-si,0);return Wt(n-e(s),t-s)}d.warning=N,d.invariant=N,process.env.NODE_ENV!=="production"&&(d.warning=(e,t)=>{!e&&typeof console<"u"&&console.warn(t)},d.invariant=(e,t)=>{if(!e)throw new Error(t)});const _=(e,t,n)=>n>t?t:n<e?e:n,Gt=.001,ii=.01,Ge=10,ri=.05,oi=1;function ai({duration:e=800,bounce:t=.25,velocity:n=0,mass:s=1}){let i,r;d.warning(e<=O(Ge),"Spring duration must be 10 seconds or less");let o=1-t;o=_(ri,oi,o),e=_(ii,Ge,L(e)),o<1?(i=u=>{const c=u*o,f=c*e,h=c-n,g=zt(u,o),y=Math.exp(-f);return Gt-h/g*y},r=u=>{const f=u*o*e,h=f*n+n,g=Math.pow(o,2)*Math.pow(u,2)*e,y=Math.exp(-f),T=zt(Math.pow(u,2),o);return(-i(u)+Gt>0?-1:1)*((h-g)*y)/T}):(i=u=>{const c=Math.exp(-u*e),f=(u-n)*e+1;return-Gt+c*f},r=u=>{const c=Math.exp(-u*e),f=(n-u)*(e*e);return c*f});const a=5/e,l=ui(i,r,a);if(e=O(e),isNaN(l))return{stiffness:100,damping:10,duration:e};{const u=Math.pow(l,2)*s;return{stiffness:u,damping:o*2*Math.sqrt(s*u),duration:e}}}const li=12;function ui(e,t,n){let s=n;for(let i=1;i<li;i++)s=s-e(s)/t(s);return s}function zt(e,t){return e*Math.sqrt(1-t*t)}const ci=["duration","bounce"],fi=["stiffness","damping","mass"];function ze(e,t){return t.some(n=>e[n]!==void 0)}function hi(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!ze(e,fi)&&ze(e,ci)){const n=ai(e);t={...t,...n,mass:1},t.isResolvedFromDuration=!0}return t}function At({keyframes:e,restDelta:t,restSpeed:n,...s}){const i=e[0],r=e[e.length-1],o={done:!1,value:i},{stiffness:a,damping:l,mass:u,duration:c,velocity:f,isResolvedFromDuration:h}=hi({...s,velocity:-L(s.velocity||0)}),g=f||0,y=l/(2*Math.sqrt(a*u)),T=r-i,w=L(Math.sqrt(a/u)),v=Math.abs(T)<5;n||(n=v?.01:2),t||(t=v?.005:.5);let b;if(y<1){const A=zt(w,y);b=M=>{const V=Math.exp(-y*w*M);return r-V*((g+y*w*T)/A*Math.sin(A*M)+T*Math.cos(A*M))}}else if(y===1)b=A=>r-Math.exp(-w*A)*(T+(g+w*T)*A);else{const A=w*Math.sqrt(y*y-1);b=M=>{const V=Math.exp(-y*w*M),x=Math.min(A*M,300);return r-V*((g+y*w*T)*Math.sinh(x)+A*T*Math.cosh(x))/A}}return{calculatedDuration:h&&c||null,next:A=>{const M=b(A);if(h)o.done=A>=c;else{let V=0;y<1&&(V=A===0?O(g):_e(b,A,M));const x=Math.abs(V)<=n,B=Math.abs(r-M)<=t;o.done=x&&B}return o.value=o.done?r:M,o}}}const Ut=2e4;function Ue(e){let t=0;const n=50;let s=e.next(t);for(;!s.done&&t<Ut;)t+=n,s=e.next(t);return t>=Ut?1/0:t}function je(e,t=100,n){const s=n({...e,keyframes:[0,t]}),i=Math.min(Ue(s),Ut);return{type:"keyframes",ease:r=>s.next(i*r).value/t,duration:L(i)}}const ot=(e,t,n)=>e+(t-e)*n,J=(e,t,n)=>{const s=t-e;return s===0?1:(n-e)/s};function He(e,t){const n=e[e.length-1];for(let s=1;s<=t;s++){const i=J(0,t,s);e.push(ot(n,1,i))}}function jt(e){const t=[0];return He(t,e.length-1),t}const F=e=>!!(e&&e.getVelocity);function Mt(e,t,n){var s;if(typeof e=="string"){let i=document;t&&(d.invariant(!!t.current,"Scope provided, but no element detected."),i=t.current),n?((s=n[e])!==null&&s!==void 0||(n[e]=i.querySelectorAll(e)),e=n[e]):e=i.querySelectorAll(e)}else e instanceof Element&&(e=[e]);return Array.from(e||[])}function Ht(e){return typeof e=="object"&&!Array.isArray(e)}function Ye(e,t,n,s){return typeof e=="string"&&Ht(t)?Mt(e,n,s):e instanceof NodeList?Array.from(e):Array.isArray(e)?e:[e]}function at(e){return typeof e=="function"}function Xe(e,t,n,s){var i;return typeof t=="number"?t:t.startsWith("-")||t.startsWith("+")?Math.max(0,e+parseFloat(t)):t==="<"?n:(i=s.get(t))!==null&&i!==void 0?i:e}const qe=(e,t,n)=>{const s=t-e;return((n-e)%s+s)%s+e},Ze=e=>Array.isArray(e)&&typeof e[0]!="number";function di(e,t){return Ze(e)?e[qe(0,e.length,t)]:e}function pi(e,t,n){for(let s=0;s<e.length;s++){const i=e[s];i.at>t&&i.at<n&&(Le(e,i),s--)}}function mi(e,t,n,s,i,r){pi(e,i,r);for(let o=0;o<t.length;o++)e.push({value:t[o],at:ot(i,r,s[o]),easing:di(n,o)})}function gi(e,t){return e.at===t.at?e.value===null?1:t.value===null?-1:0:e.at-t.at}const yi="easeInOut";function vi(e,{defaultTransition:t={},...n}={},s,i){const r=t.duration||.3,o=new Map,a=new Map,l={},u=new Map;let c=0,f=0,h=0;for(let g=0;g<e.length;g++){const y=e[g];if(typeof y=="string"){u.set(y,f);continue}else if(!Array.isArray(y)){u.set(y.name,Xe(f,y.at,c,u));continue}let[T,w,v={}]=y;v.at!==void 0&&(f=Xe(f,v.at,c,u));let b=0;const A=(M,V,x,B=0,S=0)=>{const E=bi(M),{delay:I=0,times:Z=jt(E),type:Re="keyframes",...ml}=V;let{ease:Ks=t.ease||"easeOut",duration:$}=V;const $s=typeof I=="function"?I(B,S):I,Ws=E.length,_s=at(Re)?Re:i==null?void 0:i[Re];if(Ws<=2&&_s){let js=100;if(Ws===2&&Ti(E)){const gl=E[1]-E[0];js=Math.abs(gl)}const Hs={...ml};$!==void 0&&(Hs.duration=O($));const Ys=je(Hs,js,_s);Ks=Ys.ease,$=Ys.duration}$??($=r);const Gs=f+$s,zs=Gs+$;Z.length===1&&Z[0]===0&&(Z[1]=1);const Us=Z.length-E.length;Us>0&&He(Z,Us),E.length===1&&E.unshift(null),mi(x,E,Ks,Z,Gs,zs),b=Math.max($s+$,b),h=Math.max(zs,h)};if(F(T)){const M=Je(T,a);A(w,v,Qe("default",M))}else{const M=Ye(T,w,s,l),V=M.length;for(let x=0;x<V;x++){w=w,v=v;const B=M[x],S=Je(B,a);for(const E in w)A(w[E],Si(v,E),Qe(E,S),x,V)}}c=f,f+=b}return a.forEach((g,y)=>{for(const T in g){const w=g[T];w.sort(gi);const v=[],b=[],A=[];for(let V=0;V<w.length;V++){const{at:x,value:B,easing:S}=w[V];v.push(B),b.push(J(0,h,x)),A.push(S||"easeOut")}b[0]!==0&&(b.unshift(0),v.unshift(v[0]),A.unshift(yi)),b[b.length-1]!==1&&(b.push(1),v.push(null)),o.has(y)||o.set(y,{keyframes:{},transition:{}});const M=o.get(y);M.keyframes[T]=v,M.transition[T]={...t,duration:h,ease:A,times:b,...n}}}),o}function Je(e,t){return!t.has(e)&&t.set(e,{}),t.get(e)}function Qe(e,t){return t[e]||(t[e]=[]),t[e]}function bi(e){return Array.isArray(e)?e:[e]}function Si(e,t){return e&&e[t]?{...e,...e[t]}:{...e}}const wi=e=>typeof e=="number",Ti=e=>e.every(wi),K=new WeakMap,lt=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],H=new Set(lt),Vi={type:"spring",stiffness:500,damping:25,restSpeed:10},Ai=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Mi={type:"keyframes",duration:.8},Ei={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},xi=(e,{keyframes:t})=>t.length>2?Mi:H.has(e)?e.startsWith("scale")?Ai(t[1]):Vi:Ei;function Yt(e,t){return e?e[t]||e.default||e:void 0}const Pi=e=>e!==null;function ut(e,{repeat:t,repeatType:n="loop"},s){const i=e.filter(Pi),r=t&&n!=="loop"&&t%2===1?0:i.length-1;return!r||s===void 0?i[r]:s}const tn=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Ci=1e-7,Oi=12;function Fi(e,t,n,s,i){let r,o,a=0;do o=t+(n-t)/2,r=tn(o,s,i)-e,r>0?n=o:t=o;while(Math.abs(r)>Ci&&++a<Oi);return o}function Q(e,t,n,s){if(e===t&&n===s)return N;const i=r=>Fi(r,0,1,e,n);return r=>r===0||r===1?r:tn(i(r),t,s)}const Xt=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,qt=e=>t=>1-e(1-t),Zt=Q(.33,1.53,.69,.99),Et=qt(Zt),Jt=Xt(Et),Qt=e=>(e*=2)<1?.5*Et(e):.5*(2-Math.pow(2,-10*(e-1))),xt=e=>1-Math.sin(Math.acos(e)),en=qt(xt),te=Xt(xt),nn=e=>/^0[^.\s]+$/u.test(e);function Di(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||nn(e):!0}const sn=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),rn=e=>t=>typeof t=="string"&&t.startsWith(e),on=rn("--"),Bi=rn("var(--"),ee=e=>Bi(e)?Ii.test(e.split("/*")[0].trim()):!1,Ii=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Ri=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Li(e){const t=Ri.exec(e);if(!t)return[,];const[,n,s,i]=t;return[`--${n??s}`,i]}const Ni=4;function an(e,t,n=1){d.invariant(n<=Ni,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[s,i]=Li(e);if(!s)return;const r=window.getComputedStyle(t).getPropertyValue(s);if(r){const o=r.trim();return sn(o)?parseFloat(o):o}return ee(i)?an(i,t,n+1):i}const tt={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},ct={...tt,transform:e=>_(0,1,e)},Pt={...tt,default:1},ft=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),G=ft("deg"),et=ft("%"),m=ft("px"),ki=ft("vh"),Ki=ft("vw"),ln={...et,parse:e=>et.parse(e)/100,transform:e=>et.transform(e*100)},$i=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),un=e=>e===tt||e===m,cn=(e,t)=>parseFloat(e.split(", ")[t]),fn=(e,t)=>(n,{transform:s})=>{if(s==="none"||!s)return 0;const i=s.match(/^matrix3d\((.+)\)$/u);if(i)return cn(i[1],t);{const r=s.match(/^matrix\((.+)\)$/u);return r?cn(r[1],e):0}},Wi=new Set(["x","y","z"]),_i=lt.filter(e=>!Wi.has(e));function Gi(e){const t=[];return _i.forEach(n=>{const s=e.getValue(n);s!==void 0&&(t.push([n,s.get()]),s.set(n.startsWith("scale")?1:0))}),t}const nt={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:fn(4,13),y:fn(5,14)};nt.translateX=nt.x,nt.translateY=nt.y;const hn=e=>t=>t.test(e),dn=[tt,m,et,G,Ki,ki,{test:e=>e==="auto",parse:e=>e}],pn=e=>dn.find(hn(e)),Y=new Set;let ne=!1,se=!1;function mn(){if(se){const e=Array.from(Y).filter(s=>s.needsMeasurement),t=new Set(e.map(s=>s.element)),n=new Map;t.forEach(s=>{const i=Gi(s);i.length&&(n.set(s,i),s.render())}),e.forEach(s=>s.measureInitialState()),t.forEach(s=>{s.render();const i=n.get(s);i&&i.forEach(([r,o])=>{var a;(a=s.getValue(r))===null||a===void 0||a.set(o)})}),e.forEach(s=>s.measureEndState()),e.forEach(s=>{s.suspendedScrollY!==void 0&&window.scrollTo(0,s.suspendedScrollY)})}se=!1,ne=!1,Y.forEach(e=>e.complete()),Y.clear()}function gn(){Y.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(se=!0)})}function zi(){gn(),mn()}class ie{constructor(t,n,s,i,r,o=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=s,this.motionValue=i,this.element=r,this.isAsync=o}scheduleResolve(){this.isScheduled=!0,this.isAsync?(Y.add(this),ne||(ne=!0,P.read(gn),P.resolveKeyframes(mn))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:s,motionValue:i}=this;for(let r=0;r<t.length;r++)if(t[r]===null)if(r===0){const o=i==null?void 0:i.get(),a=t[t.length-1];if(o!==void 0)t[0]=o;else if(s&&n){const l=s.readValue(n,a);l!=null&&(t[0]=l)}t[0]===void 0&&(t[0]=a),i&&o===void 0&&i.set(t[0])}else t[r]=t[r-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),Y.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,Y.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}const ht=e=>Math.round(e*1e5)/1e5,re=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Ui(e){return e==null}const ji=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,oe=(e,t)=>n=>!!(typeof n=="string"&&ji.test(n)&&n.startsWith(e)||t&&!Ui(n)&&Object.prototype.hasOwnProperty.call(n,t)),yn=(e,t,n)=>s=>{if(typeof s!="string")return s;const[i,r,o,a]=s.match(re);return{[e]:parseFloat(i),[t]:parseFloat(r),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},Hi=e=>_(0,255,e),ae={...tt,transform:e=>Math.round(Hi(e))},X={test:oe("rgb","red"),parse:yn("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:s=1})=>"rgba("+ae.transform(e)+", "+ae.transform(t)+", "+ae.transform(n)+", "+ht(ct.transform(s))+")"};function Yi(e){let t="",n="",s="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),s=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),s=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,s+=s,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(s,16),alpha:i?parseInt(i,16)/255:1}}const le={test:oe("#"),parse:Yi,transform:X.transform},st={test:oe("hsl","hue"),parse:yn("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:s=1})=>"hsla("+Math.round(e)+", "+et.transform(ht(t))+", "+et.transform(ht(n))+", "+ht(ct.transform(s))+")"},C={test:e=>X.test(e)||le.test(e)||st.test(e),parse:e=>X.test(e)?X.parse(e):st.test(e)?st.parse(e):le.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?X.transform(e):st.transform(e)},Xi=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function qi(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(re))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(Xi))===null||n===void 0?void 0:n.length)||0)>0}const vn="number",bn="color",Zi="var",Ji="var(",Sn="${}",Qi=/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(e){const t=e.toString(),n=[],s={color:[],number:[],var:[]},i=[];let r=0;const a=t.replace(Qi,l=>(C.test(l)?(s.color.push(r),i.push(bn),n.push(C.parse(l))):l.startsWith(Ji)?(s.var.push(r),i.push(Zi),n.push(l)):(s.number.push(r),i.push(vn),n.push(parseFloat(l))),++r,Sn)).split(Sn);return{values:n,split:a,indexes:s,types:i}}function wn(e){return dt(e).values}function Tn(e){const{split:t,types:n}=dt(e),s=t.length;return i=>{let r="";for(let o=0;o<s;o++)if(r+=t[o],i[o]!==void 0){const a=n[o];a===vn?r+=ht(i[o]):a===bn?r+=C.transform(i[o]):r+=i[o]}return r}}const tr=e=>typeof e=="number"?0:e;function er(e){const t=wn(e);return Tn(e)(t.map(tr))}const it={test:qi,parse:wn,createTransformer:Tn,getAnimatableNone:er},nr=new Set(["brightness","contrast","saturate","opacity"]);function sr(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[s]=n.match(re)||[];if(!s)return e;const i=n.replace(s,"");let r=nr.has(t)?1:0;return s!==n&&(r*=100),t+"("+r+i+")"}const ir=/\b([a-z-]*)\(.*?\)/gu,ue={...it,getAnimatableNone:e=>{const t=e.match(ir);return t?t.map(sr).join(" "):e}},ce={borderWidth:m,borderTopWidth:m,borderRightWidth:m,borderBottomWidth:m,borderLeftWidth:m,borderRadius:m,radius:m,borderTopLeftRadius:m,borderTopRightRadius:m,borderBottomRightRadius:m,borderBottomLeftRadius:m,width:m,maxWidth:m,height:m,maxHeight:m,top:m,right:m,bottom:m,left:m,padding:m,paddingTop:m,paddingRight:m,paddingBottom:m,paddingLeft:m,margin:m,marginTop:m,marginRight:m,marginBottom:m,marginLeft:m,backgroundPositionX:m,backgroundPositionY:m},rr={rotate:G,rotateX:G,rotateY:G,rotateZ:G,scale:Pt,scaleX:Pt,scaleY:Pt,scaleZ:Pt,skew:G,skewX:G,skewY:G,distance:m,translateX:m,translateY:m,translateZ:m,x:m,y:m,z:m,perspective:m,transformPerspective:m,opacity:ct,originX:ln,originY:ln,originZ:m},Vn={...tt,transform:Math.round},fe={...ce,...rr,zIndex:Vn,size:m,fillOpacity:ct,strokeOpacity:ct,numOctaves:Vn},or={...fe,color:C,backgroundColor:C,outlineColor:C,fill:C,stroke:C,borderColor:C,borderTopColor:C,borderRightColor:C,borderBottomColor:C,borderLeftColor:C,filter:ue,WebkitFilter:ue},he=e=>or[e];function An(e,t){let n=he(e);return n!==ue&&(n=it),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const ar=new Set(["auto","none","0"]);function lr(e,t,n){let s=0,i;for(;s<e.length&&!i;){const r=e[s];typeof r=="string"&&!ar.has(r)&&dt(r).values.length&&(i=e[s]),s++}if(i&&n)for(const r of t)e[r]=An(n,i)}class Mn extends ie{constructor(t,n,s,i,r){super(t,n,s,i,r,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:s}=this;if(!n||!n.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let u=t[l];if(typeof u=="string"&&(u=u.trim(),ee(u))){const c=an(u,n.current);c!==void 0&&(t[l]=c),l===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!$i.has(s)||t.length!==2)return;const[i,r]=t,o=pn(i),a=pn(r);if(o!==a)if(un(o)&&un(a))for(let l=0;l<t.length;l++){const u=t[l];typeof u=="string"&&(t[l]=parseFloat(u))}else this.needsMeasurement=!0}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,s=[];for(let i=0;i<t.length;i++)Di(t[i])&&s.push(i);s.length&&lr(t,s,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:s}=this;if(!t||!t.current)return;s==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=nt[s](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&t.getValue(s,i).jump(i,!1)}measureEndState(){var t;const{element:n,name:s,unresolvedKeyframes:i}=this;if(!n||!n.current)return;const r=n.getValue(s);r&&r.jump(this.measuredOrigin,!1);const o=i.length-1,a=i[o];i[o]=nt[s](n.measureViewportBox(),window.getComputedStyle(n.current)),a!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=a),!((t=this.removedTransforms)===null||t===void 0)&&t.length&&this.removedTransforms.forEach(([l,u])=>{n.getValue(l).set(u)}),this.resolveNoneKeyframes()}}const En=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(it.test(e)||e==="0")&&!e.startsWith("url("));function ur(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function cr(e,t,n,s){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const r=e[e.length-1],o=En(i,t),a=En(r,t);return d.warning(o===a,`You are trying to animate ${t} from "${i}" to "${r}". ${i} is not an animatable value - to enable this animation set ${i} to a value animatable to ${r} via the \`style\` property.`),!o||!a?!1:ur(e)||(n==="spring"||at(n))&&s}const fr=40;class xn{constructor({autoplay:t=!0,delay:n=0,type:s="keyframes",repeat:i=0,repeatDelay:r=0,repeatType:o="loop",...a}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=k.now(),this.options={autoplay:t,delay:n,type:s,repeat:i,repeatDelay:r,repeatType:o,...a},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt?this.resolvedAt-this.createdAt>fr?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&zi(),this._resolved}onKeyframesResolved(t,n){this.resolvedAt=k.now(),this.hasAttemptedResolve=!0;const{name:s,type:i,velocity:r,delay:o,onComplete:a,onUpdate:l,isGenerator:u}=this.options;if(!u&&!cr(t,s,i,r))if(o)this.options.duration=0;else{l==null||l(ut(t,this.options,n)),a==null||a(),this.resolveFinishedPromise();return}const c=this.initPlayback(t,n);c!==!1&&(this._resolved={keyframes:t,finalKeyframe:n,...c},this.onPostResolved())}onPostResolved(){}then(t,n){return this.currentFinishedPromise.then(t,n)}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}}function de({keyframes:e,velocity:t=0,power:n=.8,timeConstant:s=325,bounceDamping:i=10,bounceStiffness:r=500,modifyTarget:o,min:a,max:l,restDelta:u=.5,restSpeed:c}){const f=e[0],h={done:!1,value:f},g=S=>a!==void 0&&S<a||l!==void 0&&S>l,y=S=>a===void 0?l:l===void 0||Math.abs(a-S)<Math.abs(l-S)?a:l;let T=n*t;const w=f+T,v=o===void 0?w:o(w);v!==w&&(T=v-f);const b=S=>-T*Math.exp(-S/s),A=S=>v+b(S),M=S=>{const E=b(S),I=A(S);h.done=Math.abs(E)<=u,h.value=h.done?v:I};let V,x;const B=S=>{g(h.value)&&(V=S,x=At({keyframes:[h.value,y(h.value)],velocity:_e(A,S,h.value),damping:i,stiffness:r,restDelta:u,restSpeed:c}))};return B(0),{calculatedDuration:null,next:S=>{let E=!1;return!x&&V===void 0&&(E=!0,M(S),B(S)),V!==void 0&&S>=V?x.next(S-V):(!E&&M(S),h)}}}const Pn=Q(.42,0,1,1),Cn=Q(0,0,.58,1),pe=Q(.42,0,.58,1),me=e=>Array.isArray(e)&&typeof e[0]=="number",On={linear:N,easeIn:Pn,easeInOut:pe,easeOut:Cn,circIn:xt,circInOut:te,circOut:en,backIn:Et,backInOut:Jt,backOut:Zt,anticipate:Qt},ge=e=>{if(me(e)){d.invariant(e.length===4,"Cubic bezier arrays must contain four numerical values.");const[t,n,s,i]=e;return Q(t,n,s,i)}else if(typeof e=="string")return d.invariant(On[e]!==void 0,`Invalid easing type '${e}'`),On[e];return e},hr=(e,t)=>n=>t(e(n)),Ct=(...e)=>e.reduce(hr);function ye(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function dr({hue:e,saturation:t,lightness:n,alpha:s}){e/=360,t/=100,n/=100;let i=0,r=0,o=0;if(!t)i=r=o=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;i=ye(l,a,e+1/3),r=ye(l,a,e),o=ye(l,a,e-1/3)}return{red:Math.round(i*255),green:Math.round(r*255),blue:Math.round(o*255),alpha:s}}function Ot(e,t){return n=>n>0?t:e}const ve=(e,t,n)=>{const s=e*e,i=n*(t*t-s)+s;return i<0?0:Math.sqrt(i)},pr=[le,X,st],mr=e=>pr.find(t=>t.test(e));function Fn(e){const t=mr(e);if(d.warning(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`),!t)return!1;let n=t.parse(e);return t===st&&(n=dr(n)),n}const Dn=(e,t)=>{const n=Fn(e),s=Fn(t);if(!n||!s)return Ot(e,t);const i={...n};return r=>(i.red=ve(n.red,s.red,r),i.green=ve(n.green,s.green,r),i.blue=ve(n.blue,s.blue,r),i.alpha=ot(n.alpha,s.alpha,r),X.transform(i))},be=new Set(["none","hidden"]);function gr(e,t){return be.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function yr(e,t){return n=>ot(e,t,n)}function Se(e){return typeof e=="number"?yr:typeof e=="string"?ee(e)?Ot:C.test(e)?Dn:Sr:Array.isArray(e)?Bn:typeof e=="object"?C.test(e)?Dn:vr:Ot}function Bn(e,t){const n=[...e],s=n.length,i=e.map((r,o)=>Se(r)(r,t[o]));return r=>{for(let o=0;o<s;o++)n[o]=i[o](r);return n}}function vr(e,t){const n={...e,...t},s={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(s[i]=Se(e[i])(e[i],t[i]));return i=>{for(const r in s)n[r]=s[r](i);return n}}function br(e,t){var n;const s=[],i={color:0,var:0,number:0};for(let r=0;r<t.values.length;r++){const o=t.types[r],a=e.indexes[o][i[o]],l=(n=e.values[a])!==null&&n!==void 0?n:0;s[r]=l,i[o]++}return s}const Sr=(e,t)=>{const n=it.createTransformer(t),s=dt(e),i=dt(t);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?be.has(e)&&!i.values.length||be.has(t)&&!s.values.length?gr(e,t):Ct(Bn(br(s,i),i.values),n):(d.warning(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),Ot(e,t))};function we(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?ot(e,t,n):Se(e)(e,t)}function wr(e,t,n){const s=[],i=n||we,r=e.length-1;for(let o=0;o<r;o++){let a=i(e[o],e[o+1]);if(t){const l=Array.isArray(t)?t[o]||N:t;a=Ct(l,a)}s.push(a)}return s}function Ft(e,t,{clamp:n=!0,ease:s,mixer:i}={}){const r=e.length;if(d.invariant(r===t.length,"Both input and output ranges must be the same length"),r===1)return()=>t[0];if(r===2&&e[0]===e[1])return()=>t[1];e[0]>e[r-1]&&(e=[...e].reverse(),t=[...t].reverse());const o=wr(t,s,i),a=o.length,l=u=>{let c=0;if(a>1)for(;c<e.length-2&&!(u<e[c+1]);c++);const f=J(e[c],e[c+1],u);return o[c](f)};return n?u=>l(_(e[0],e[r-1],u)):l}function Tr(e,t){return e.map(n=>n*t)}function Vr(e,t){return e.map(()=>t||pe).splice(0,e.length-1)}function pt({duration:e=300,keyframes:t,times:n,ease:s="easeInOut"}){const i=Ze(s)?s.map(ge):ge(s),r={done:!1,value:t[0]},o=Tr(n&&n.length===t.length?n:jt(t),e),a=Ft(o,t,{ease:Array.isArray(i)?i:Vr(t,i)});return{calculatedDuration:e,next:l=>(r.value=a(l),r.done=l>=e,r)}}const Ar=e=>{const t=({timestamp:n})=>e(n);return{start:()=>P.update(t,!0),stop:()=>R(t),now:()=>j.isProcessing?j.timestamp:k.now()}},Mr={decay:de,inertia:de,tween:pt,keyframes:pt,spring:At},Er=e=>e/100;class Dt extends xn{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();const{onStop:l}=this.options;l&&l()};const{name:n,motionValue:s,element:i,keyframes:r}=this.options,o=(i==null?void 0:i.KeyframeResolver)||ie,a=(l,u)=>this.onKeyframesResolved(l,u);this.resolver=new o(r,a,n,s,i),this.resolver.scheduleResolve()}initPlayback(t){const{type:n="keyframes",repeat:s=0,repeatDelay:i=0,repeatType:r,velocity:o=0}=this.options,a=at(n)?n:Mr[n]||pt;let l,u;a!==pt&&typeof t[0]!="number"&&(process.env.NODE_ENV!=="production"&&d.invariant(t.length===2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${t}`),l=Ct(Er,we(t[0],t[1])),t=[0,100]);const c=a({...this.options,keyframes:t});r==="mirror"&&(u=a({...this.options,keyframes:[...t].reverse(),velocity:-o})),c.calculatedDuration===null&&(c.calculatedDuration=Ue(c));const{calculatedDuration:f}=c,h=f+i,g=h*(s+1)-i;return{generator:c,mirroredGenerator:u,mapPercentToKeyframes:l,calculatedDuration:f,resolvedDuration:h,totalDuration:g}}onPostResolved(){const{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,n=!1){const{resolved:s}=this;if(!s){const{keyframes:S}=this.options;return{done:!0,value:S[S.length-1]}}const{finalKeyframe:i,generator:r,mirroredGenerator:o,mapPercentToKeyframes:a,keyframes:l,calculatedDuration:u,totalDuration:c,resolvedDuration:f}=s;if(this.startTime===null)return r.next(0);const{delay:h,repeat:g,repeatType:y,repeatDelay:T,onUpdate:w}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-c/this.speed,this.startTime)),n?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;const v=this.currentTime-h*(this.speed>=0?1:-1),b=this.speed>=0?v<0:v>c;this.currentTime=Math.max(v,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=c);let A=this.currentTime,M=r;if(g){const S=Math.min(this.currentTime,c)/f;let E=Math.floor(S),I=S%1;!I&&S>=1&&(I=1),I===1&&E--,E=Math.min(E,g+1),!!(E%2)&&(y==="reverse"?(I=1-I,T&&(I-=T/f)):y==="mirror"&&(M=o)),A=_(0,1,I)*f}const V=b?{done:!1,value:l[0]}:M.next(A);a&&(V.value=a(V.value));let{done:x}=V;!b&&u!==null&&(x=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const B=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&x);return B&&i!==void 0&&(V.value=ut(l,this.options,i)),w&&w(V.value),B&&this.finish(),V}get duration(){const{resolved:t}=this;return t?L(t.calculatedDuration):0}get time(){return L(this.currentTime)}set time(t){t=O(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=L(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;const{driver:t=Ar,onPlay:n,startTime:s}=this.options;this.driver||(this.driver=t(r=>this.tick(r))),n&&n();const i=this.driver.now();this.holdTime!==null?this.startTime=i-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=i):this.startTime=s??this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}}function xr(e){return new Dt(e)}const Pr=new Set(["opacity","clipPath","filter","transform"]),Cr=10,Or=(e,t)=>{let n="";const s=Math.max(Math.round(t/Cr),2);for(let i=0;i<s;i++)n+=e(J(0,s-1,i))+", ";return`linear(${n.substring(0,n.length-2)})`},Fr={linearEasing:void 0};function Dr(e,t){const n=Vt(e);return()=>{var s;return(s=Fr[t])!==null&&s!==void 0?s:n()}}const mt=Dr(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");function In(e){return!!(typeof e=="function"&&mt()||!e||typeof e=="string"&&(e in Te||mt())||me(e)||Array.isArray(e)&&e.every(In))}const gt=([e,t,n,s])=>`cubic-bezier(${e}, ${t}, ${n}, ${s})`,Te={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:gt([0,.65,.55,1]),circOut:gt([.55,0,1,.45]),backIn:gt([.31,.01,.66,-.59]),backOut:gt([.33,1.53,.69,.99])};function Rn(e,t){if(e)return typeof e=="function"&&mt()?Or(e,t):me(e)?gt(e):Array.isArray(e)?e.map(n=>Rn(n,t)||Te.easeOut):Te[e]}function Ln(e,t,n,{delay:s=0,duration:i=300,repeat:r=0,repeatType:o="loop",ease:a,times:l}={}){const u={[t]:n};l&&(u.offset=l);const c=Rn(a,i);return Array.isArray(c)&&(u.easing=c),e.animate(u,{delay:s,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:r+1,direction:o==="reverse"?"alternate":"normal"})}function Bt(e,t){e.timeline=t,e.onfinish=null}const Nn=Vt(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),It=10,Br=2e4;function Ir(e){return at(e.type)||e.type==="spring"||!In(e.ease)}function Rr(e,t){const n=new Dt({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0});let s={done:!1,value:e[0]};const i=[];let r=0;for(;!s.done&&r<Br;)s=n.sample(r),i.push(s.value),r+=It;return{times:void 0,keyframes:i,duration:r-It,ease:"linear"}}const kn={anticipate:Qt,backInOut:Jt,circInOut:te};function Lr(e){return e in kn}class Kn extends xn{constructor(t){super(t);const{name:n,motionValue:s,element:i,keyframes:r}=this.options;this.resolver=new Mn(r,(o,a)=>this.onKeyframesResolved(o,a),n,s,i),this.resolver.scheduleResolve()}initPlayback(t,n){var s;let{duration:i=300,times:r,ease:o,type:a,motionValue:l,name:u,startTime:c}=this.options;if(!(!((s=l.owner)===null||s===void 0)&&s.current))return!1;if(typeof o=="string"&&mt()&&Lr(o)&&(o=kn[o]),Ir(this.options)){const{onComplete:h,onUpdate:g,motionValue:y,element:T,...w}=this.options,v=Rr(t,w);t=v.keyframes,t.length===1&&(t[1]=t[0]),i=v.duration,r=v.times,o=v.ease,a="keyframes"}const f=Ln(l.owner.current,u,t,{...this.options,duration:i,times:r,ease:o});return f.startTime=c??this.calcStartTime(),this.pendingTimeline?(Bt(f,this.pendingTimeline),this.pendingTimeline=void 0):f.onfinish=()=>{const{onComplete:h}=this.options;l.set(ut(t,this.options,n)),h&&h(),this.cancel(),this.resolveFinishedPromise()},{animation:f,duration:i,times:r,type:a,ease:o,keyframes:t}}get duration(){const{resolved:t}=this;if(!t)return 0;const{duration:n}=t;return L(n)}get time(){const{resolved:t}=this;if(!t)return 0;const{animation:n}=t;return L(n.currentTime||0)}set time(t){const{resolved:n}=this;if(!n)return;const{animation:s}=n;s.currentTime=O(t)}get speed(){const{resolved:t}=this;if(!t)return 1;const{animation:n}=t;return n.playbackRate}set speed(t){const{resolved:n}=this;if(!n)return;const{animation:s}=n;s.playbackRate=t}get state(){const{resolved:t}=this;if(!t)return"idle";const{animation:n}=t;return n.playState}get startTime(){const{resolved:t}=this;if(!t)return null;const{animation:n}=t;return n.startTime}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{const{resolved:n}=this;if(!n)return N;const{animation:s}=n;Bt(s,t)}return N}play(){if(this.isStopped)return;const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.playState==="finished"&&this.updateFinishedPromise(),n.play()}pause(){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:t}=this;if(!t)return;const{animation:n,keyframes:s,duration:i,type:r,ease:o,times:a}=t;if(n.playState==="idle"||n.playState==="finished")return;if(this.time){const{motionValue:u,onUpdate:c,onComplete:f,element:h,...g}=this.options,y=new Dt({...g,keyframes:s,duration:i,type:r,ease:o,times:a,isGenerator:!0}),T=O(this.time);u.setWithVelocity(y.sample(T-It).value,y.sample(T).value,It)}const{onStop:l}=this.options;l&&l(),this.cancel()}complete(){const{resolved:t}=this;t&&t.animation.finish()}cancel(){const{resolved:t}=this;t&&t.animation.cancel()}static supports(t){const{motionValue:n,name:s,repeatDelay:i,repeatType:r,damping:o,type:a}=t;return Nn()&&s&&Pr.has(s)&&n&&n.owner&&n.owner.current instanceof HTMLElement&&!n.owner.getProps().onUpdate&&!i&&r!=="mirror"&&o!==0&&a!=="inertia"}}function Nr({when:e,delay:t,delayChildren:n,staggerChildren:s,staggerDirection:i,repeat:r,repeatType:o,repeatDelay:a,from:l,elapsed:u,...c}){return!!Object.keys(c).length}const $n=(e,t,n,s={},i,r)=>o=>{const a=Yt(s,e)||{},l=a.delay||s.delay||0;let{elapsed:u=0}=s;u=u-O(l);let c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-u,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:r?void 0:i};Nr(a)||(c={...c,...xi(e,c)}),c.duration&&(c.duration=O(c.duration)),c.repeatDelay&&(c.repeatDelay=O(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let f=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(c.duration=0,c.delay===0&&(f=!0)),f&&!r&&t.get()!==void 0){const h=ut(c.keyframes,a);if(h!==void 0)return P.update(()=>{c.onUpdate(h),c.onComplete()}),new _t([])}return!r&&Kn.supports(c)?new Kn(c):new Dt(c)},kr=e=>Array.isArray(e),Kr=e=>kr(e)?e[e.length-1]||0:e;function Wn(e){const t=[{},{}];return e==null||e.values.forEach((n,s)=>{t[0][s]=n.get(),t[1][s]=n.getVelocity()}),t}function _n(e,t,n,s){if(typeof t=="function"){const[i,r]=Wn(s);t=t(n!==void 0?n:e.custom,i,r)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,r]=Wn(s);t=t(n!==void 0?n:e.custom,i,r)}return t}function $r(e,t,n){const s=e.getProps();return _n(s,t,s.custom,e)}function Wr(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,D(n))}function _r(e,t){const n=$r(e,t);let{transitionEnd:s={},transition:i={},...r}=n||{};r={...r,...s};for(const o in r){const a=Kr(r[o]);Wr(e,o,a)}}const Ve=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Gr="data-"+Ve("framerAppearId");function zr(e){return e.props[Gr]}function Ur(e){return!!(F(e)&&e.add)}function jr(e,t){const n=e.getValue("willChange");if(Ur(n))return n.add(t)}function Hr({protectedKeys:e,needsAnimating:t},n){const s=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,s}function Yr(e,t,{delay:n=0,transitionOverride:s,type:i}={}){var r;let{transition:o=e.getDefaultTransition(),transitionEnd:a,...l}=t;s&&(o=s);const u=[],c=i&&e.animationState&&e.animationState.getState()[i];for(const f in l){const h=e.getValue(f,(r=e.latestValues[f])!==null&&r!==void 0?r:null),g=l[f];if(g===void 0||c&&Hr(c,f))continue;const y={delay:n,...Yt(o||{},f)};let T=!1;if(window.MotionHandoffAnimation){const v=zr(e);if(v){const b=window.MotionHandoffAnimation(v,f,P);b!==null&&(y.startTime=b,T=!0)}}jr(e,f),h.start($n(f,h,g,e.shouldReduceMotion&&H.has(f)?{type:!1}:y,e,T));const w=h.animation;w&&u.push(w)}return a&&Promise.all(u).then(()=>{P.update(()=>{a&&_r(e,a)})}),u}function Xr(e){return e instanceof SVGElement&&e.tagName!=="svg"}const qr={};function Zr(e,{layout:t,layoutId:n}){return H.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!qr[e]||e==="opacity")}function Gn(e,t,n){var s;const{style:i}=e,r={};for(const o in i)(F(i[o])||t.style&&F(t.style[o])||Zr(o,e)||((s=n==null?void 0:n.getValue(o))===null||s===void 0?void 0:s.liveStyle)!==void 0)&&(r[o]=i[o]);return r}function Jr(e,t,n){const s=Gn(e,t,n);for(const i in e)if(F(e[i])||F(t[i])){const r=lt.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;s[r]=e[i]}return s}const Qr=typeof window<"u",Ae={current:null},zn={current:!1};function to(){if(zn.current=!0,!!Qr)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ae.current=e.matches;e.addListener(t),t()}else Ae.current=!1}function eo(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function no(e){return typeof e=="string"||Array.isArray(e)}const so=["initial",...["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"]];function Un(e){return eo(e.animate)||so.some(t=>no(e[t]))}function io(e){return!!(Un(e)||e.variants)}function ro(e,t,n){for(const s in t){const i=t[s],r=n[s];if(F(i))e.addValue(s,i),process.env.NODE_ENV==="development"&&wt(i.version==="11.11.11",`Attempting to mix Framer Motion versions ${i.version} with 11.11.11 may not work as expected.`);else if(F(r))e.addValue(s,D(i,{owner:e}));else if(r!==i)if(e.hasValue(s)){const o=e.getValue(s);o.liveStyle===!0?o.jump(i):o.hasAnimated||o.set(i)}else{const o=e.getStaticValue(s);e.addValue(s,D(o!==void 0?o:i,{owner:e}))}}for(const s in n)t[s]===void 0&&e.removeValue(s);return t}const jn={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"]},Me={};for(const e in jn)Me[e]={isEnabled:t=>jn[e].some(n=>!!t[n])};const oo=[...dn,C,it],ao=e=>oo.find(hn(e)),Hn=()=>({min:0,max:0}),Ee=()=>({x:Hn(),y:Hn()}),Yn=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class Xn{scrapeMotionValuesFromProps(t,n,s){return{}}constructor({parent:t,props:n,presenceContext:s,reducedMotionConfig:i,blockInitialAnimation:r,visualState:o},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=ie,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 h=k.now();this.renderScheduledAt<h&&(this.renderScheduledAt=h,P.render(this.render,!1,!0))};const{latestValues:l,renderState:u}=o;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=s,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=a,this.blockInitialAnimation=!!r,this.isControllingVariants=Un(n),this.isVariantNode=io(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:c,...f}=this.scrapeMotionValuesFromProps(n,{},this);for(const h in f){const g=f[h];l[h]!==void 0&&F(g)&&g.set(l[h],!1)}}mount(t){this.current=t,K.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,s)=>this.bindToMotionValue(s,n)),zn.current||to(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Ae.current,process.env.NODE_ENV!=="production"&&wt(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){K.delete(this.current),this.projection&&this.projection.unmount(),R(this.notifyUpdate),R(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const s=H.has(t),i=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&P.preRender(this.notifyUpdate),s&&this.projection&&(this.projection.isTransformDirty=!0)}),r=n.on("renderRequest",this.scheduleRender);let o;window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),r(),o&&o(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Me){const n=Me[t];if(!n)continue;const{isEnabled:s,Feature:i}=n;if(!this.features[t]&&i&&s(this.props)&&(this.features[t]=new i(this)),this.features[t]){const r=this.features[t];r.isMounted?r.update():(r.mount(),r.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ee()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let s=0;s<Yn.length;s++){const i=Yn[s];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const r="on"+i,o=t[r];o&&(this.propEventSubscriptions[i]=this.on(i,o))}this.prevMotionValues=ro(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const s=this.values.get(t);n!==s&&(s&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let s=this.values.get(t);return s===void 0&&n!==void 0&&(s=D(n===null?void 0:n,{owner:this}),this.addValue(t,s)),s}readValue(t,n){var s;let i=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(s=this.getBaseTargetFromProps(this.props,t))!==null&&s!==void 0?s:this.readValueFromInstance(this.current,t,this.options);return i!=null&&(typeof i=="string"&&(sn(i)||nn(i))?i=parseFloat(i):!ao(i)&&it.test(n)&&(i=An(t,n)),this.setBaseTarget(t,F(i)?i.get():i)),F(i)?i.get():i}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:s}=this.props;let i;if(typeof s=="string"||typeof s=="object"){const o=_n(this.props,s,(n=this.presenceContext)===null||n===void 0?void 0:n.custom);o&&(i=o[t])}if(s&&i!==void 0)return i;const r=this.getBaseTargetFromProps(this.props,t);return r!==void 0&&!F(r)?r:this.initialValues[t]!==void 0&&i===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Ne),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class qn extends Xn{constructor(){super(...arguments),this.KeyframeResolver=Mn}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:s}){delete n[t],delete s[t]}}const Zn=(e,t)=>t&&typeof e=="number"?t.transform(e):e,lo={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},uo=lt.length;function co(e,t,n){let s="",i=!0;for(let r=0;r<uo;r++){const o=lt[r],a=e[o];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(o.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||n){const u=Zn(a,fe[o]);if(!l){i=!1;const c=lo[o]||o;s+=`${c}(${u}) `}n&&(t[o]=u)}}return s=s.trim(),n?s=n(t,i?"":s):i&&(s="none"),s}function Jn(e,t,n){const{style:s,vars:i,transformOrigin:r}=e;let o=!1,a=!1;for(const l in t){const u=t[l];if(H.has(l)){o=!0;continue}else if(on(l)){i[l]=u;continue}else{const c=Zn(u,fe[l]);l.startsWith("origin")?(a=!0,r[l]=c):s[l]=c}}if(t.transform||(o||n?s.transform=co(t,e.transform,n):s.transform&&(s.transform="none")),a){const{originX:l="50%",originY:u="50%",originZ:c=0}=r;s.transformOrigin=`${l} ${u} ${c}`}}function Qn(e,t,n){return typeof e=="string"?e:m.transform(t+n*e)}function fo(e,t,n){const s=Qn(t,e.x,e.width),i=Qn(n,e.y,e.height);return`${s} ${i}`}const ho={offset:"stroke-dashoffset",array:"stroke-dasharray"},po={offset:"strokeDashoffset",array:"strokeDasharray"};function mo(e,t,n=1,s=0,i=!0){e.pathLength=1;const r=i?ho:po;e[r.offset]=m.transform(-s);const o=m.transform(t),a=m.transform(n);e[r.array]=`${o} ${a}`}function go(e,{attrX:t,attrY:n,attrScale:s,originX:i,originY:r,pathLength:o,pathSpacing:a=1,pathOffset:l=0,...u},c,f){if(Jn(e,u,f),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:h,style:g,dimensions:y}=e;h.transform&&(y&&(g.transform=h.transform),delete h.transform),y&&(i!==void 0||r!==void 0||g.transform)&&(g.transformOrigin=fo(y,i!==void 0?i:.5,r!==void 0?r:.5)),t!==void 0&&(h.x=t),n!==void 0&&(h.y=n),s!==void 0&&(h.scale=s),o!==void 0&&mo(h,o,a,l,!1)}const ts=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 es(e,{style:t,vars:n},s,i){Object.assign(e.style,t,i&&i.getProjectionStyles(s));for(const r in n)e.style.setProperty(r,n[r])}function yo(e,t,n,s){es(e,t,void 0,s);for(const i in t.attrs)e.setAttribute(ts.has(i)?i:Ve(i),t.attrs[i])}const vo=e=>typeof e=="string"&&e.toLowerCase()==="svg";class bo extends qn{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ee}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(H.has(n)){const s=he(n);return s&&s.default||0}return n=ts.has(n)?n:Ve(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,s){return Jr(t,n,s)}build(t,n,s){go(t,n,this.isSVGTag,s.transformTemplate)}renderInstance(t,n,s,i){yo(t,n,s,i)}mount(t){this.isSVGTag=vo(t.tagName),super.mount(t)}}function So({top:e,left:t,right:n,bottom:s}){return{x:{min:t,max:n},y:{min:e,max:s}}}function wo(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),s=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:s.y,right:s.x}}function To(e,t){return So(wo(e.getBoundingClientRect(),t))}function Vo(e){return window.getComputedStyle(e)}class Ao extends qn{constructor(){super(...arguments),this.type="html",this.renderInstance=es}readValueFromInstance(t,n){if(H.has(n)){const s=he(n);return s&&s.default||0}else{const s=Vo(t),i=(on(n)?s.getPropertyValue(n):s[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return To(t,n)}build(t,n,s){Jn(t,n,s.transformTemplate)}scrapeMotionValuesFromProps(t,n,s){return Gn(t,n,s)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;F(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function Mo(e,t){return e in t}class Eo extends Xn{constructor(){super(...arguments),this.type="object"}readValueFromInstance(t,n){if(Mo(n,t)){const s=t[n];if(typeof s=="string"||typeof s=="number")return s}}getBaseTargetFromProps(){}removeValueFromRenderState(t,n){delete n.output[t]}measureInstanceViewportBox(){return Ee()}build(t,n){Object.assign(t.output,n)}renderInstance(t,{output:n}){Object.assign(t,n)}sortInstanceNodePosition(){return 0}}function ns(e){const t={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},n=Xr(e)?new bo(t):new Ao(t);n.mount(e),K.set(e,n)}function xo(e){const t={presenceContext:null,props:{},visualState:{renderState:{output:{}},latestValues:{}}},n=new Eo(t);n.mount(e),K.set(e,n)}function Po(e,t,n){const s=F(e)?e:D(e);return s.start($n("",s,t,n)),s.animation}function Co(e,t){return F(e)||typeof e=="number"||typeof e=="string"&&!Ht(t)}function ss(e,t,n,s){const i=[];if(Co(e,t))i.push(Po(e,Ht(t)&&t.default||t,n&&(n.default||n)));else{const r=Ye(e,t,s),o=r.length;d.invariant(!!o,"No valid elements provided.");for(let a=0;a<o;a++){const l=r[a],u=l instanceof Element?ns:xo;K.has(l)||u(l);const c=K.get(l),f={...n};"delay"in f&&typeof f.delay=="function"&&(f.delay=f.delay(a,o)),i.push(...Yr(c,{...t,transition:f},{}))}}return i}function Oo(e,t,n){const s=[];return vi(e,t,n,{spring:At}).forEach(({keyframes:r,transition:o},a)=>{s.push(...ss(a,r,o))}),s}function Fo(e){return Array.isArray(e)&&Array.isArray(e[0])}function is(e){function t(n,s,i){let r=[];Fo(n)?r=Oo(n,s,e):r=ss(n,s,i,e);const o=new _t(r);return e&&e.animations.push(o),o}return t}const rs=is();function Do(e,t,n){e.style.setProperty(`--${t}`,n)}function Bo(e,t,n){e.style[t]=n}const Io=Vt(()=>{try{document.createElement("div").animate({opacity:[1]})}catch{return!1}return!0}),Rt=new WeakMap;function Ro(e,t,n){for(let s=0;s<t.length;s++)t[s]===null&&(t[s]=s===0?n():t[s-1]),typeof t[s]=="number"&&ce[e]&&(t[s]=ce[e].transform(t[s]));!Io()&&t.length<2&&t.unshift(n())}const os="easeOut";function as(e){const t=Rt.get(e)||new Map;return Rt.set(e,t),Rt.get(e)}class Lo{constructor(t,n,s,i){const r=n.startsWith("--");this.setValue=r?Do:Bo,this.options=i,this.updateFinishedPromise(),d.invariant(typeof i.type!="string",`animateMini doesn't support "type" as a string. Did you mean to import { spring } from "framer-motion"?`);const o=as(t).get(n);o&&o.stop();const a=()=>n.startsWith("--")?t.style.getPropertyValue(n):window.getComputedStyle(t)[n];if(Array.isArray(s)||(s=[s]),Ro(n,s,a),at(i.type)){const u=je(i,100,i.type);i.ease=mt()?u.ease:os,i.duration=O(u.duration),i.type="keyframes"}else i.ease=i.ease||os;this.removeAnimation=()=>{var u;return(u=Rt.get(t))===null||u===void 0?void 0:u.delete(n)};const l=()=>{this.setValue(t,n,ut(s,this.options)),this.cancel(),this.resolveFinishedPromise()};Nn()?(this.animation=Ln(t,n,s,i),i.autoplay===!1&&this.animation.pause(),this.animation.onfinish=l,this.pendingTimeline&&Bt(this.animation,this.pendingTimeline),as(t).set(n,this)):l()}get duration(){return L(this.options.duration||300)}get time(){var t;return this.animation?L(((t=this.animation)===null||t===void 0?void 0:t.currentTime)||0):0}set time(t){this.animation&&(this.animation.currentTime=O(t))}get speed(){return this.animation?this.animation.playbackRate:1}set speed(t){this.animation&&(this.animation.playbackRate=t)}get state(){return this.animation?this.animation.playState:"finished"}get startTime(){return this.animation?this.animation.startTime:null}play(){this.state==="finished"&&this.updateFinishedPromise(),this.animation&&this.animation.play()}pause(){this.animation&&this.animation.pause()}stop(){!this.animation||this.state==="idle"||this.state==="finished"||(this.animation.commitStyles&&this.animation.commitStyles(),this.cancel())}complete(){this.animation&&this.animation.finish()}cancel(){this.removeAnimation();try{this.animation&&this.animation.cancel()}catch{}}then(t,n){return this.currentFinishedPromise.then(t,n)}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}attachTimeline(t){return this.animation?Bt(this.animation,t):this.pendingTimeline=t,N}}function No(e,t,n,s){const i=Mt(e,s),r=i.length;d.invariant(!!r,"No valid element provided.");const o=[];for(let a=0;a<r;a++){const l=i[a],u={...n};typeof u.delay=="function"&&(u.delay=u.delay(a,r));for(const c in t){const f=t[c],h={...Yt(n,c)};h.duration=h.duration?O(h.duration):h.duration,h.delay=O(h.delay||0),o.push(new Lo(l,c,f,h))}}return o}const ko=(e=>{function t(n,s,i){return new _t(No(n,s,i,e))}return t})(),Lt=new WeakMap;let z;function Ko(e,t){if(t){const{inlineSize:n,blockSize:s}=t[0];return{width:n,height:s}}else return e instanceof SVGElement&&"getBBox"in e?e.getBBox():{width:e.offsetWidth,height:e.offsetHeight}}function $o({target:e,contentRect:t,borderBoxSize:n}){var s;(s=Lt.get(e))===null||s===void 0||s.forEach(i=>{i({target:e,contentSize:t,get size(){return Ko(e,n)}})})}function Wo(e){e.forEach($o)}function _o(){typeof ResizeObserver>"u"||(z=new ResizeObserver(Wo))}function Go(e,t){z||_o();const n=Mt(e);return n.forEach(s=>{let i=Lt.get(s);i||(i=new Set,Lt.set(s,i)),i.add(t),z==null||z.observe(s)}),()=>{n.forEach(s=>{const i=Lt.get(s);i==null||i.delete(t),i!=null&&i.size||z==null||z.unobserve(s)})}}const Nt=new Set;let yt;function zo(){yt=()=>{const e={width:window.innerWidth,height:window.innerHeight},t={target:window,size:e,contentSize:e};Nt.forEach(n=>n(t))},window.addEventListener("resize",yt)}function Uo(e){return Nt.add(e),yt||zo(),()=>{Nt.delete(e),!Nt.size&&yt&&(yt=void 0)}}function jo(e,t){return typeof e=="function"?Uo(e):Go(e,t)}const Ho=50,ls=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),Yo=()=>({time:0,x:ls(),y:ls()}),Xo={x:{length:"Width",position:"Left"},y:{length:"Height",position:"Top"}};function us(e,t,n,s){const i=n[t],{length:r,position:o}=Xo[t],a=i.current,l=n.time;i.current=e[`scroll${o}`],i.scrollLength=e[`scroll${r}`]-e[`client${r}`],i.offset.length=0,i.offset[0]=0,i.offset[1]=i.scrollLength,i.progress=J(0,i.scrollLength,i.current);const u=s-l;i.velocity=u>Ho?0:Wt(i.current-a,u)}function qo(e,t,n){us(e,"x",t,n),us(e,"y",t,n),t.time=n}function Zo(e,t){const n={x:0,y:0};let s=e;for(;s&&s!==t;)if(s instanceof HTMLElement)n.x+=s.offsetLeft,n.y+=s.offsetTop,s=s.offsetParent;else if(s.tagName==="svg"){const i=s.getBoundingClientRect();s=s.parentElement;const r=s.getBoundingClientRect();n.x+=i.left-r.left,n.y+=i.top-r.top}else if(s instanceof SVGGraphicsElement){const{x:i,y:r}=s.getBBox();n.x+=i,n.y+=r;let o=null,a=s.parentNode;for(;!o;)a.tagName==="svg"&&(o=a),a=s.parentNode;s=o}else break;return n}const Jo={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]},xe={start:0,center:.5,end:1};function cs(e,t,n=0){let s=0;if(e in xe&&(e=xe[e]),typeof e=="string"){const i=parseFloat(e);e.endsWith("px")?s=i:e.endsWith("%")?e=i/100:e.endsWith("vw")?s=i/100*document.documentElement.clientWidth:e.endsWith("vh")?s=i/100*document.documentElement.clientHeight:e=i}return typeof e=="number"&&(s=t*e),n+s}const Qo=[0,0];function ta(e,t,n,s){let i=Array.isArray(e)?e:Qo,r=0,o=0;return typeof e=="number"?i=[e,e]:typeof e=="string"&&(e=e.trim(),e.includes(" ")?i=e.split(" "):i=[e,xe[e]?e:"0"]),r=cs(i[0],n,s),o=cs(i[1],t),r-o}const ea={x:0,y:0};function na(e){return"getBBox"in e&&e.tagName!=="svg"?e.getBBox():{width:e.clientWidth,height:e.clientHeight}}function sa(e,t,n){const{offset:s=Jo.All}=n,{target:i=e,axis:r="y"}=n,o=r==="y"?"height":"width",a=i!==e?Zo(i,e):ea,l=i===e?{width:e.scrollWidth,height:e.scrollHeight}:na(i),u={width:e.clientWidth,height:e.clientHeight};t[r].offset.length=0;let c=!t[r].interpolate;const f=s.length;for(let h=0;h<f;h++){const g=ta(s[h],u[o],l[o],a[r]);!c&&g!==t[r].interpolatorOffsets[h]&&(c=!0),t[r].offset[h]=g}c&&(t[r].interpolate=Ft(t[r].offset,jt(s)),t[r].interpolatorOffsets=[...t[r].offset]),t[r].progress=t[r].interpolate(t[r].current)}function ia(e,t=e,n){if(n.x.targetOffset=0,n.y.targetOffset=0,t!==e){let s=t;for(;s&&s!==e;)n.x.targetOffset+=s.offsetLeft,n.y.targetOffset+=s.offsetTop,s=s.offsetParent}n.x.targetLength=t===e?t.scrollWidth:t.clientWidth,n.y.targetLength=t===e?t.scrollHeight:t.clientHeight,n.x.containerLength=e.clientWidth,n.y.containerLength=e.clientHeight,process.env.NODE_ENV!=="production"&&e&&t&&t!==e&&wt(getComputedStyle(e).position!=="static","Please ensure that the container has a non-static position, like 'relative', 'fixed', or 'absolute' to ensure scroll offset is calculated correctly.")}function ra(e,t,n,s={}){return{measure:()=>ia(e,s.target,n),update:i=>{qo(e,n,i),(s.offset||s.target)&&sa(e,n,s)},notify:()=>t(n)}}const vt=new WeakMap,fs=new WeakMap,Pe=new WeakMap,hs=e=>e===document.documentElement?window:e;function kt(e,{container:t=document.documentElement,...n}={}){let s=Pe.get(t);s||(s=new Set,Pe.set(t,s));const i=Yo(),r=ra(t,e,i,n);if(s.add(r),!vt.has(t)){const a=()=>{for(const h of s)h.measure()},l=()=>{for(const h of s)h.update(j.timestamp)},u=()=>{for(const h of s)h.notify()},c=()=>{P.read(a,!1,!0),P.read(l,!1,!0),P.update(u,!1,!0)};vt.set(t,c);const f=hs(t);window.addEventListener("resize",c,{passive:!0}),t!==document.documentElement&&fs.set(t,jo(t,c)),f.addEventListener("scroll",c,{passive:!0})}const o=vt.get(t);return P.read(o,!1,!0),()=>{var a;R(o);const l=Pe.get(t);if(!l||(l.delete(r),l.size))return;const u=vt.get(t);vt.delete(t),u&&(hs(t).removeEventListener("scroll",u),(a=fs.get(t))===null||a===void 0||a(),window.removeEventListener("resize",u))}}function ds(e,t){let n;const s=()=>{const{currentTime:i}=t,o=(i===null?0:i.value)/100;n!==o&&e(o),n=o};return P.update(s,!0),()=>R(s)}function oa({source:e,container:t,axis:n="y"}){e&&(t=e);const s={value:0},i=kt(r=>{s.value=r[n].progress*100},{container:t,axis:n});return{currentTime:s,cancel:i}}const Ce=new Map;function ps({source:e,container:t=document.documentElement,axis:n="y"}={}){e&&(t=e),Ce.has(t)||Ce.set(t,{});const s=Ce.get(t);return s[n]||(s[n]=We()?new ScrollTimeline({source:t,axis:n}):oa({source:t,axis:n})),s[n]}function aa(e){return e.length===2}function ms(e){return e&&(e.target||e.offset)}function la(e,t){return aa(e)||ms(t)?kt(n=>{e(n[t.axis].progress,n)},t):ds(e,ps(t))}function ua(e,t){if(ms(t))return e.pause(),kt(n=>{e.time=e.duration*n[t.axis].progress},t);{const n=ps(t);return e.attachTimeline(n,s=>(s.pause(),ds(i=>{s.time=s.duration*i},n)))}}function gs(e,{axis:t="y",...n}={}){const s={axis:t,...n};return typeof e=="function"?la(e,s):ua(e,s)}const ca={some:0,all:1};function ys(e,t,{root:n,margin:s,amount:i="some"}={}){const r=Mt(e),o=new WeakMap,a=u=>{u.forEach(c=>{const f=o.get(c.target);if(c.isIntersecting!==!!f)if(c.isIntersecting){const h=t(c);typeof h=="function"?o.set(c.target,h):l.unobserve(c.target)}else f&&(f(c),o.delete(c.target))})},l=new IntersectionObserver(a,{root:n,rootMargin:s,threshold:typeof i=="number"?i:ca[i]});return r.forEach(u=>l.observe(u)),()=>l.disconnect()}function fa(e,t="end"){return n=>{n=t==="end"?Math.min(n,.999):Math.max(n,.001);const s=n*e,i=t==="end"?Math.floor(s):Math.ceil(s);return _(0,1,i/e)}}function ha(e,t){if(e==="first")return 0;{const n=t-1;return e==="last"?n:n/2}}function da(e=.1,{startDelay:t=0,from:n=0,ease:s}={}){return(i,r)=>{const o=typeof n=="number"?n:ha(n,r),a=Math.abs(o-i);let l=e*a;if(s){const u=r*e;l=ge(s)(l/u)*u}return t+l}}const pa=e=>e&&typeof e=="object"&&e.mix,ma=e=>pa(e)?e.mix:void 0;function vs(...e){const t=!Array.isArray(e[0]),n=t?0:-1,s=e[0+n],i=e[1+n],r=e[2+n],o=e[3+n],a=Ft(i,r,{mixer:ma(r[0]),...o});return t?a(s):a}function ga(e,t){const n=k.now(),s=({timestamp:i})=>{const r=i-n;r>=t&&(R(s),e(r-t))};return P.read(s,!0),()=>R(s)}function ya(e,t){return ga(e,O(t))}const Oe=(e,t)=>Math.abs(e-t);function va(e,t){const n=Oe(e.x,t.x),s=Oe(e.y,t.y);return Math.sqrt(n**2+s**2)}const ba=P,Sa=rt.reduce((e,t)=>(e[t]=n=>R(n),e),{});function bs(e,t){const n=typeof e=="string"&&!t?`${e}Context`:t,s=Symbol(n);return[o=>{const a=p.inject(s,o);if(a||a===null)return a;throw new Error(`Injection \`${s.toString()}\` not found. Component must be used within ${Array.isArray(e)?`one of the following components: ${e.join(", ")}`:`\`${e}\``}`)},o=>(p.provide(s,o),o)]}function q(e){return!!(e&&e.getVelocity)}const[wa,Ta]=bs("Motion");function Ss(e,t){if(typeof e=="object")return e;if(e&&t)return t[e]}function Va(e,t){return typeof e!=typeof t?!0:Array.isArray(e)&&Array.isArray(t)?!Aa(e,t):e!==t}function Aa(e,t){const n=t.length;if(n!==e.length)return!1;for(let s=0;s<n;s++)if(t[s]!==e[s])return!1;return!0}function Ma(e,t){!e.includes(t)&&e.push(t)}function Ea(e,t){const n=e.indexOf(t);n!==-1&&e.splice(n,1)}function xa(e,t){return e[t]?{...e,...e[t]}:{...e}}function ws(e){return e==null?void 0:e.startsWith("--")}function Pa(){}const Ca=e=>e;function Oa(e){return typeof e=="number"}const Fa=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","svg","switch","symbol","text","tspan","use","view","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"],Da=new Set(Fa);function Ba(e){return Da.has(e)}typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const Ts=e=>typeof e<"u",Vs={syntax:"<angle>",initialValue:"0deg",toDefaultUnit:e=>`${e}deg`},Ia={translate:{syntax:"<length-percentage>",initialValue:"0px",toDefaultUnit:e=>`${e}px`},rotate:Vs,scale:{syntax:"<number>",initialValue:1,toDefaultUnit:Ca},skew:Vs},Ra=["translate","scale","rotate","skew"],La=["","X","Y","Z"],Fe=new Map,Kt=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"];Ra.forEach(e=>{La.forEach(t=>{Kt.push(e+t),Fe.set(e+t,Ia[e])})});const Na=new Set(Kt),ka=e=>Na.has(e),As={x:"translateX",y:"translateY",z:"translateZ"};function Ka([e],[t]){return Kt.indexOf(e)-Kt.indexOf(t)}function $a(e,[t,n]){return`${e} ${t}(${n})`}function Wa(e){return e.sort(Ka).reduce($a,"").trim()}const _a={translate:[0,0],rotate:0,scale:1,skew:0,x:0,y:0,z:0},Ga={get:(e,t)=>{let n=ws(t)?e.style.getPropertyValue(t):getComputedStyle(e)[t];if(!n&&n!=="0"){const s=Fe.get(t);s&&(n=s.initialValue)}return n},set:(e,t,n)=>{ws(t)?e.style.setProperty(t,n):e.style[t]=n}};function De(e){var s;const t={},n=[];for(let i in e){let r=e[i];r=q(r)?r.get():r,ka(i)&&i in As&&(i=As[i]);let o=Array.isArray(r)?r[0]:r;const a=Fe.get(i);a?(o=Oa(r)?(s=a.toDefaultUnit)==null?void 0:s.call(a,r):r,n.push([i,o])):t[i]=o}return n.length&&(t.transform=Wa(n)),t}const Ms={fill:!0,stroke:!0,strokeWidth:!0,opacity:!0,fillOpacity:!0,strokeOpacity:!0,strokeLinecap:!0,strokeLinejoin:!0,strokeDasharray:!0,strokeDashoffset:!0,cx:!0,cy:!0,r:!0,d:!0,x:!0,y:!0,x1:!0,y1:!0,x2:!0,y2:!0,points:!0,pathLength:!0,transform:!0,viewBox:!0,width:!0,height:!0,preserveAspectRatio:!0,clipPath:!0,filter:!0,mask:!0,stopColor:!0,stopOpacity:!0,gradientTransform:!0,gradientUnits:!0,spreadMethod:!0,markerEnd:!0,markerMid:!0,markerStart:!0,textAnchor:!0,dominantBaseline:!0,fontFamily:!0,fontSize:!0,fontWeight:!0,letterSpacing:!0,vectorEffect:!0};function za(e){const t={},n={};for(const s in e)if(s in Ms){const i=Ms[s],r=typeof i=="string"?i:s,o=e[s];t[r]=q(o)?o.get():o}else n[s]=e[s];return{attributes:t,style:n}}function Es(e){return e?e.flatMap(t=>t.type===p.Fragment?Es(t.children):[t]):[]}const Ua=p.defineComponent({name:"PrimitiveSlot",inheritAttrs:!1,setup(e,{attrs:t,slots:n}){return()=>{var l,u;if(!n.default)return null;const s=Es(n.default()),i=s.findIndex(c=>c.type!==p.Comment);if(i===-1)return s;const r=s[i];(l=r.props)==null||delete l.ref;const o=r.props?p.mergeProps(t,r.props):t;t.class&&((u=r.props)!=null&&u.class)&&delete r.props.class;const a=p.cloneVNode(r,o);for(const c in o)c.startsWith("on")&&(a.props||(a.props={}),a.props[c]=o[c]);return s.length===1?a:(s[i]=a,s)}}}),ja=p.defineComponent({name:"Primitive",inheritAttrs:!1,props:{asChild:{type:Boolean,default:!1},as:{type:[String,Object],default:"div"}},setup(e,{attrs:t,slots:n}){const s=e.asChild?"template":e.as;return typeof s=="string"&&["area","img","input"].includes(s)?()=>p.h(s,t):s!=="template"?()=>p.h(e.as,t,{default:n.default}):()=>p.h(Ua,t,{default:n.default})}});var xs=function(){},Ps=function(){};process.env.NODE_ENV!=="production"&&(xs=function(e,t){!e&&typeof console<"u"&&console.warn(t)},Ps=function(e,t){if(!e)throw new Error(t)});class Cs{constructor(t){this.state=t}update(){}}class Ha{constructor(t){this.features=[],this.features=[new Ya(t),new Xa(t),new qa(t),new Za(t)]}mount(){this.features.forEach(t=>t.mount())}unmount(){this.features.forEach(t=>t.unmount())}update(){this.features.forEach(t=>t.update())}}function bt(e,t,n){e.dispatchEvent(new CustomEvent(t,{detail:{originalEvent:n}}))}class Be extends Cs{updateGestureSubscriptions(){const t=this.isActive();t&&!this.removeGestureSubscriptions?this.removeGestureSubscriptions=this.subscribeEvents():!t&&this.removeGestureSubscriptions&&(this.removeGestureSubscriptions(),this.removeGestureSubscriptions=void 0)}unmount(){var t;(t=this.removeGestureSubscriptions)==null||t.call(this)}}function Os(e,t,n){return s=>{s.pointerType&&s.pointerType!=="mouse"||(n(),bt(e,t,s))}}class Ya extends Be{isActive(){return!!this.state.getOptions().hover}constructor(t){super(t),this.subscribeEvents=()=>{const n=this.state.getElement(),s=Os(n,"hoverstart",()=>{this.state.setActive("hover",!0)}),i=Os(n,"hoverend",()=>{this.state.setActive("hover",!1)});return n.addEventListener("pointerenter",s),n.addEventListener("pointerleave",i),()=>{n.removeEventListener("pointerenter",s),n.removeEventListener("pointerleave",i)}}}mount(){this.updateGestureSubscriptions()}update(){this.updateGestureSubscriptions()}}class Xa extends Be{isActive(){return!!this.state.getOptions().press}constructor(t){super(t),this.subscribeEvents=()=>{const n=this.state.getElement(),s=r=>{this.state.setActive("press",!1),bt(n,"pressend",r),window.removeEventListener("pointerup",s)},i=r=>{this.state.setActive("press",!0),bt(n,"pressstart",r),window.addEventListener("pointerup",s)};return n.addEventListener("pointerdown",i),()=>{n.removeEventListener("pointerdown",i),window.removeEventListener("pointerup",s)}}}mount(){this.updateGestureSubscriptions()}update(){this.updateGestureSubscriptions()}}class qa extends Be{isActive(){return!!this.state.getOptions().inView}constructor(t){super(t),this.subscribeEvents=()=>{var r;const n=this.state.getElement(),{once:s,...i}=((r=this.state.getOptions())==null?void 0:r.inViewOptions)||{};return ys(n,o=>{if(this.state.setActive("inView",!0),bt(n,"viewenter",o),!s)return a=>{this.state.setActive("inView",!1),bt(n,"viewleave",a)}},i)}}mount(){this.updateGestureSubscriptions()}update(){this.updateGestureSubscriptions()}}class Za extends Cs{constructor(){super(...arguments),this.handlers={}}mount(){const t=this.state.getElement();t&&(this.handlers.motionstart=n=>{var i,r;const s=n.detail.target;(r=(i=this.state.getOptions()).onMotionStart)==null||r.call(i,s)},this.handlers.motioncomplete=n=>{var i,r;const s=n.detail.target;(r=(i=this.state.getOptions()).onMotionComplete)==null||r.call(i,s)},this.handlers.hoverstart=n=>{var i,r;const s=n.detail;(r=(i=this.state.getOptions()).onHoverStart)==null||r.call(i,s)},this.handlers.hoverend=n=>{var i,r;const s=n.detail;(r=(i=this.state.getOptions()).onHoverEnd)==null||r.call(i,s)},this.handlers.pressstart=n=>{var i,r;const s=n.detail;(r=(i=this.state.getOptions()).onPressStart)==null||r.call(i,s)},this.handlers.pressend=n=>{var i,r;const s=n.detail;(r=(i=this.state.getOptions()).onPressEnd)==null||r.call(i,s)},this.handlers.viewenter=n=>{var i,r;const s=n.detail.target;(r=(i=this.state.getOptions()).onViewEnter)==null||r.call(i,s)},this.handlers.viewleave=n=>{var i,r;const s=n.detail.target;(r=(i=this.state.getOptions()).onViewLeave)==null||r.call(i,s)},Object.entries(this.handlers).forEach(([n,s])=>{t.addEventListener(n,s)}))}unmount(){const t=this.state.getElement();t&&Object.entries(this.handlers).forEach(([n,s])=>{s&&(t.removeEventListener(n,s),delete this.handlers[n])})}}let U;const Fs=e=>e.next(),Ja=e=>e.animateUpdates();function Qa(){if(!U)return;const e=U.sort(el).map(Ja);e.forEach(Fs),e.forEach(Fs),U=void 0}function Ds(e){U?Ma(U,e):(U=[e],requestAnimationFrame(Qa))}function tl(e){U&&Ea(U,e)}function el(e,t){return e.getDepth()-t.getDepth()}function Bs(e,t,n){return new CustomEvent(e,{detail:{target:t,isExit:n}})}const Is=["initial","animate","inView","hover","press","exit","drag"],$t=new WeakMap;class nl{constructor(t,n){this.element=null,this.context={},this.activeStates={initial:!0,animate:!0},this.options=t,this.parent=n,this.depth=(n==null?void 0:n.depth)+1||0,this.initContext();const s=t.initial===!1?"animate":"initial";this.featureManager=new Ha(this),this.initTarget(s)}initContext(){var t;for(const n of Is)this.context[n]=typeof this.options[n]=="string"?this.options[n]:(t=this.parent)==null?void 0:t.context[n]}initTarget(t){this.baseTarget=Ss(this.options[t]||this.context[t],this.options.variants)||{},this.target={...this.baseTarget}}get initial(){return Ts(this.options.initial)?this.options.initial:this.context.initial}mount(t){var s;Ps(!!t,"Animation state must be mounted with valid Element"),this.element=t,$t.set(t,this),K.get(t)||ns(t);const n=K.get(t);if(this.visualElement=n,n.update(this.options,(s=this.parent)==null?void 0:s.context),typeof this.initial=="object")for(const i in this.initial)n.setStaticValue(i,this.initial[i]);else if(typeof this.initial=="string"&&this.options.variants)for(const i in this.options.variants[this.initial])n.setStaticValue(i,this.options.variants[this.initial][i]);this.featureManager.mount()}unmount(){var t;$t.delete(this.element),tl(this),(t=K.get(this.element))==null||t.unmount(),this.featureManager.unmount()}update(t){var n;this.options=t,this.visualElement.update(this.options,(n=this.parent)==null?void 0:n.context),this.featureManager.update(),Ds(this)}setActive(t,n){this.element&&(this.activeStates[t]=n,Ds(this))}*animateUpdates(){const t=this.target;this.target={};const n={};for(const l of Is){if(!this.activeStates[l])continue;const u=Ss(Ts(this.options[l])?this.options[l]:this.context[l],this.options.variants);if(!u)continue;const c={...t,...u};for(const f in c)f!=="transition"&&(this.target[f]=u[f],n[f]=xa(u.transition??this.options.transition??{},f))}const s=new Set([...Object.keys(this.target),...Object.keys(t)]),i=[];s.forEach(l=>{var u;this.target[l]===void 0&&(this.target[l]=this.baseTarget[l]),Va(t[l],this.target[l])&&((u=this.baseTarget)[l]??(u[l]=Ga.get(this.element,l)),i.push(()=>rs(this.element,{[l]:this.target[l]==="none"?_a[l]:this.target[l]},n[l]||{})))}),yield;const r=i.map(l=>l()).filter(Boolean);if(!r.length)return;const o=this.target;this.element.dispatchEvent(Bs("motionstart",o));const a=this.activeStates.exit;Promise.all(r).then(()=>{this.element.dispatchEvent(Bs("motioncomplete",{...o},a))}).catch(Pa)}isMounted(){return!!this.element}getDepth(){return this.depth}getOptions(){return this.options}getElement(){return this.element}getTarget(){return this.target}}const St=new WeakMap;function Rs(e){const t=St.get(e);t&&e.removeEventListener("motioncomplete",t),St.delete(e)}const[sl,il]=bs("AnimatePresenceContext"),rl=p.defineComponent({name:"Motion",inheritAttrs:!1,__name:"Motion",props:p.mergeDefaults({as:{},asChild:{type:Boolean},inViewOptions:{},inView:{},press:{},hover:{},initial:{type:[String,Object,Boolean]},animate:{},exit:{},variants:{},style:{},transformTemplate:{type:Function},transition:{},onMotionStart:{type:Function},onMotionComplete:{type:Function},onHoverStart:{type:Function},onHoverEnd:{type:Function},onPressStart:{type:Function},onPressEnd:{type:Function},onViewEnter:{type:Function},onViewLeave:{type:Function}},{as:"div",asChild:!1,initial:void 0,animate:void 0,hover:void 0,inView:void 0}),setup(e){const t=e,{initial:n,safeUnmount:s}=sl({initial:p.ref(void 0),safeUnmount:()=>!0}),i=wa(null),r=p.useAttrs(),o=new nl({...r,...t},i);Ta(o);const a=p.getCurrentInstance();p.onMounted(()=>{o.mount(a==null?void 0:a.vnode.el),o.update({...r,...t,style:{...De(o.getTarget()),...t.style}})}),p.onUnmounted(()=>{s(a==null?void 0:a.vnode.el)&&o.unmount()}),p.onUpdated(()=>{o.update({...r,...t,initial:n.value===!1?n.value:t.initial===!0?void 0:t.initial})});function l(){const u={...r};Object.keys(r).forEach(f=>{q(r[f])&&(u[f]=r[f].get())});let c={};if(!o.isMounted()&&Ba(t.as)){const{attributes:f,style:h}=za(o.getTarget());Object.assign(u,f),Object.assign(c,h,t.style)}return c=De(c),u.style=De(c),u}return(u,c)=>(p.openBlock(),p.createBlock(p.unref(ja),p.mergeProps({as:u.as,"as-child":u.asChild},l()),{default:p.withCtx(()=>[p.renderSlot(u.$slots,"default")]),_:3},16,["as","as-child"]))}}),ol=p.defineComponent({name:"AnimatePresence",inheritAttrs:!1,__name:"AnimatePresence",props:{mode:{default:"sync"},initial:{type:Boolean,default:!0},multiple:{type:Boolean,default:!1},as:{}},setup(e){const t=e,{initial:n}=p.toRefs(t);il({initial:n,safeUnmount(r){return!St.has(r)}});function s(r){const o=$t.get(r);o&&(Rs(r),o.setActive("exit",!1))}function i(r,o){const a=$t.get(r);if(!a)return o();a.setActive("exit",!0),Rs(r);function l(u){var c;(c=u==null?void 0:u.detail)!=null&&c.isExit&&(St.delete(r),a.unmount(),o())}St.set(r,l),r.addEventListener("motioncomplete",l)}return(r,o)=>(p.openBlock(),p.createBlock(p.resolveDynamicComponent(r.multiple?p.TransitionGroup:p.Transition),p.mergeProps({tag:r.multiple?r.as:void 0,css:!1,mode:r.mode==="wait"?"out-in":void 0},r.$attrs,{onEnter:s,onLeave:i}),{default:p.withCtx(()=>[p.renderSlot(r.$slots,"default")]),_:3},16,["tag","mode"]))}});function Ie(e){const t=D(e()),n=()=>t.set(e()),s=()=>P.preRender(n,!1,!0);let i;const r=a=>{i=a.map(l=>l.on("change",s))},o=()=>{i.forEach(a=>a()),R(n)};return p.onUnmounted(()=>{o()}),{subscribe:r,unsubscribe:o,value:t}}function al(e){W.current=[];const{value:t,subscribe:n,unsubscribe:s}=Ie(e);return n(W.current),W.current=void 0,p.onBeforeUpdate(()=>{s(),W.current=[],e(),n(W.current),W.current=void 0}),t}function ll(e,t,n,s){if(typeof e=="function")return al(e);const i=typeof t=="function"?t:vs(t,n,s);return Array.isArray(e)?Ls(e,i):Ls([e],([r])=>i(r))}function Ls(e,t){const n=[],{value:s,subscribe:i}=Ie(()=>{n.length=0;const r=e.length;for(let o=0;o<r;o++)n[o]=e[o].get();return t(n)});return i(e),s}function ul(e){let t=0;const n=({timestamp:i,delta:r})=>{t||(t=i),e(i-t,r)},s=()=>R(n);p.onBeforeUpdate(()=>{s(),P.update(n,!0)}),p.onUnmounted(()=>s()),P.update(n,!0)}function cl(){const e=D(0);return ul(t=>e.set(t)),e}function fl(e,...t){const n=e.length;function s(){let o="";for(let a=0;a<n;a++){o+=e[a];const l=t[a];l&&(o+=q(l)?l.get():l)}return o}const{value:i,subscribe:r}=Ie(s);return r(t.filter(q)),i}function Ns(e){return typeof e=="number"?e:parseFloat(e)}function hl(e,t={}){let n=null;const s=D(q(e)?Ns(e.get()):e);let i=s.get(),r=()=>{};const o=()=>{n&&(n.stop(),n=null)},a=()=>{const l=n;(l==null?void 0:l.time)===0&&l.sample(j.delta),o(),n=xr({keyframes:[s.get(),i],velocity:s.getVelocity(),type:"spring",restDelta:.001,restSpeed:.01,...t,onUpdate:r})};return p.watch(()=>JSON.stringify(t),()=>{const l=s.attach((u,c)=>(i=u,r=c,P.update(a),s.get()),o);p.onBeforeUnmount(()=>l())},{immediate:!0}),q(e)&&e.on("change",l=>{s.set(Ns(l))}),s}function ks(e,t){xs(!!(!t||t.value),`You have defined a ${e} options but the provided ref is not yet hydrated, probably because it's defined higher up the tree. Try calling useScroll() in the same component as the ref.`)}function dl(){return{scrollX:D(0),scrollY:D(0),scrollXProgress:D(0),scrollYProgress:D(0)}}function pl({container:e,target:t,...n}={}){const s=dl();let i;const r=()=>{i==null||i(),i=gs((o,{x:a,y:l})=>{s.scrollX.set(a.current),s.scrollXProgress.set(a.progress),s.scrollY.set(l.current),s.scrollYProgress.set(l.progress)},{...n,container:(e==null?void 0:e.value)??void 0,target:(t==null?void 0:t.value)??void 0})};return p.onMounted(()=>{ks("target",t),ks("container",e),r()}),p.onUnmounted(()=>i==null?void 0:i()),p.watch(()=>[e==null?void 0:e.value,t==null?void 0:t.value,n.offset],r),s}d.AnimatePresence=ol,d.Motion=rl,d.MotionValue=$e,d.animate=rs,d.animateMini=ko,d.anticipate=Qt,d.backIn=Et,d.backInOut=Jt,d.backOut=Zt,d.cancelFrame=R,d.cancelSync=Sa,d.circIn=xt,d.circInOut=te,d.circOut=en,d.clamp=_,d.createScopedAnimate=is,d.cubicBezier=Q,d.delay=ya,d.distance=Oe,d.distance2D=va,d.easeIn=Pn,d.easeInOut=pe,d.easeOut=Cn,d.frame=P,d.frameData=j,d.frameSteps=ti,d.inView=ys,d.inertia=de,d.interpolate=Ft,d.keyframes=pt,d.mirrorEasing=Xt,d.mix=we,d.motionValue=D,d.pipe=Ct,d.progress=J,d.reverseEasing=qt,d.scroll=gs,d.scrollInfo=kt,d.spring=At,d.stagger=da,d.steps=fa,d.sync=ba,d.transform=vs,d.useMotionTemplate=fl,d.useMotionValue=D,d.useScroll=pl,d.useSpring=hl,d.useTime=cl,d.useTransform=ll,d.wrap=qe,Object.defineProperty(d,Symbol.toStringTag,{value:"Module"})});
@@ -1,5 +1,5 @@
1
1
  export interface AnimatePresenceProps {
2
- mode?: 'wait' | 'popLayout' | 'sync';
2
+ mode?: 'wait' | 'sync';
3
3
  initial?: boolean;
4
4
  multiple?: boolean;
5
5
  as?: string;
@@ -21,7 +21,7 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_WithDefaults<
21
21
  initial: boolean;
22
22
  multiple: boolean;
23
23
  }>>>, {
24
- mode: "wait" | "popLayout" | "sync";
24
+ mode: "wait" | "sync";
25
25
  initial: boolean;
26
26
  multiple: boolean;
27
27
  }, {}>;
@@ -1,12 +1,11 @@
1
- import { Options } from '../state/types';
2
1
  import { IntrinsicElementAttributes } from 'vue';
2
+ import { ElementType, Options, SVGAttributesWithMotionValues, SetMotionValueType } from '../types';
3
3
  export interface MotionProps<T extends ElementType = 'div'> extends Options {
4
4
  as?: T;
5
5
  asChild?: boolean;
6
6
  }
7
- type ElementType = keyof IntrinsicElementAttributes;
8
7
  declare const _default: <T extends ElementType = "div">(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
9
- props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & Readonly<import('vue').ExtractPropTypes<{}>>, never>, never> & (MotionProps<T> & Omit<IntrinsicElementAttributes[T], "asChild" | keyof Options>)> & import('vue').PublicProps;
8
+ props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & Readonly<import('vue').ExtractPropTypes<{}>>, never>, never> & (Omit<SetMotionValueType<IntrinsicElementAttributes, keyof SVGAttributesWithMotionValues>[T], keyof Options | "asChild"> & MotionProps<T>)> & import('vue').PublicProps;
10
9
  expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
11
10
  attrs: any;
12
11
  slots: {
@@ -34,6 +34,6 @@ export declare const Primitive: import('vue').DefineComponent<{
34
34
  default: string;
35
35
  };
36
36
  }>>, {
37
- asChild: boolean;
38
37
  as: AsTag;
38
+ asChild: boolean;
39
39
  }, {}>;
@@ -1,7 +1,2 @@
1
1
  import { MotionState } from '../state/motion-state';
2
- import { Ref } from 'vue';
3
2
  export declare const injectMotion: <T extends MotionState = MotionState>(fallback?: T) => T extends null ? MotionState : MotionState, provideMotion: (contextValue: MotionState) => MotionState;
4
- export interface PresenceContext {
5
- initial: Ref<boolean>;
6
- }
7
- export declare const injectAnimatePresence: <T extends PresenceContext = PresenceContext>(fallback?: T) => T extends null ? PresenceContext : PresenceContext, provideAnimatePresence: (contextValue: PresenceContext) => PresenceContext;
@@ -3,5 +3,6 @@ export declare const doneCallbacks: WeakMap<Element, VoidFunction>;
3
3
  export declare function removeDoneCallback(element: Element): void;
4
4
  export interface PresenceContext {
5
5
  initial: Ref<boolean>;
6
+ safeUnmount: (el: Element) => boolean;
6
7
  }
7
8
  export declare const injectAnimatePresence: <T extends PresenceContext = PresenceContext>(fallback?: T) => T extends null ? PresenceContext : PresenceContext, provideAnimatePresence: (contextValue: PresenceContext) => PresenceContext;
@@ -1,4 +1,4 @@
1
- import { VariantLabels } from '../../../state/types';
1
+ import { VariantLabels } from '../../../types';
2
2
  export interface BoundingBox {
3
3
  top: number;
4
4
  right: number;
@@ -1,4 +1,4 @@
1
- import { Options } from '../../state/types';
1
+ import { Options } from '../../types';
2
2
  export interface StateHandlers {
3
3
  enable: VoidFunction;
4
4
  disable: VoidFunction;
@@ -1,4 +1,4 @@
1
- import { Variant } from './types';
1
+ import { Variant } from '../types';
2
2
  export type MotionEventNames = 'motionstart' | 'motioncomplete' | 'hoverstart' | 'hoverend' | 'pressstart' | 'pressend' | 'viewenter' | 'viewleave';
3
3
  export declare function motionEvent(name: MotionEventNames, target: Variant, isExit?: boolean): CustomEvent<{
4
4
  target: Variant;
@@ -1,5 +1,5 @@
1
- import { Options } from './types';
2
- import { DOMKeyframesDefinition } from 'framer-motion';
1
+ import { Options } from '../types';
2
+ import { DOMKeyframesDefinition, VisualElement } from 'framer-motion';
3
3
  declare const STATE_TYPES: readonly ["initial", "animate", "inView", "hover", "press", "exit", "drag"];
4
4
  type StateType = typeof STATE_TYPES[number];
5
5
  export declare const mountedStates: WeakMap<Element, MotionState>;
@@ -13,11 +13,11 @@ export declare class MotionState {
13
13
  private baseTarget;
14
14
  private target;
15
15
  private featureManager;
16
- private visualElement;
16
+ visualElement: VisualElement;
17
17
  constructor(options: Options, parent?: MotionState);
18
18
  private initContext;
19
19
  private initTarget;
20
- get initial(): string | boolean | import('./types').Variant;
20
+ get initial(): string | boolean | import('../types').Variant;
21
21
  mount(element: HTMLElement): void;
22
22
  unmount(): void;
23
23
  update(options: Options): void;
@@ -1,7 +1,11 @@
1
1
  import { DOMKeyframesDefinition } from 'framer-motion';
2
- import { MotionStyle } from './types';
2
+ import { MotionStyle } from '../types';
3
3
  export declare const style: {
4
4
  get: (element: Element, name: string) => string | undefined;
5
5
  set: (element: Element, name: string, value: string | number) => void;
6
6
  };
7
7
  export declare function createStyles(keyframes?: MotionStyle | DOMKeyframesDefinition): any;
8
+ export declare function convertSvgStyleToAttributes(keyframes?: MotionStyle | DOMKeyframesDefinition): {
9
+ attributes: Record<string, any>;
10
+ style: Record<string, any>;
11
+ };
@@ -1,4 +1,4 @@
1
- import { CssPropertyDefinition } from './types';
1
+ import { CssPropertyDefinition } from '../types';
2
2
  /**
3
3
  * A list of all transformable axes. We'll use this list to generated a version
4
4
  * of each axes for each transform.
@@ -1,4 +1,4 @@
1
- import { Options } from './types';
1
+ import { Options } from '../types';
2
2
  import { DynamicAnimationOptions, Variant } from 'framer-motion';
3
3
  import { IntrinsicElementAttributes } from 'vue';
4
4
  export declare function resolveVariant(definition?: Options['initial'], variants?: Options['variants']): Variant | undefined;
@@ -1,3 +1,5 @@
1
1
  export * from './transform';
2
2
  export * from './framer-motion';
3
+ export * from './motion-values';
4
+ export * from './state';
3
5
  export type MotionEventNames = 'motionstart' | 'motioncomplete' | 'hoverstart' | 'hoverend' | 'pressstart' | 'pressend' | 'viewenter' | 'viewleave' | 'dragstart' | 'dragend' | 'dragcancel' | 'dragmove' | 'drag';
@@ -0,0 +1,91 @@
1
+ import { MotionValue } from 'framer-motion/dom';
2
+ import { Options } from './state';
3
+ import { AriaAttributes, Events, SVGAttributes } from 'vue';
4
+ type EventHandlers<E> = {
5
+ [K in keyof E]?: E[K] extends (...args: any) => any ? E[K] : (payload: E[K]) => void;
6
+ };
7
+ type EventKeys = keyof EventHandlers<Events>;
8
+ interface SVGAttributesWithoutMotionProps extends Pick<SVGAttributes, Exclude<keyof SVGAttributes, keyof Options | keyof AriaAttributes | EventKeys>> {
9
+ }
10
+ /**
11
+ * @public
12
+ */
13
+ export interface CustomValueType {
14
+ mix: (from: any, to: any) => (p: number) => number | string;
15
+ toValue: () => number | string;
16
+ }
17
+ export type MakeCustomValueType<T> = {
18
+ [K in keyof T]: T[K] | CustomValueType;
19
+ };
20
+ export type MakeMotion<T> = MakeCustomValueType<{
21
+ [K in keyof T]: T[K] | MotionValue<number> | MotionValue<string> | MotionValue<any>;
22
+ }>;
23
+ /**
24
+ * Blanket-accept any SVG attribute as a `MotionValue`
25
+ * @public
26
+ */
27
+ export type SVGAttributesAsMotionValues = MakeMotion<SVGAttributesWithoutMotionProps>;
28
+ export interface SVGAttributesWithMotionValues {
29
+ svg: SVGAttributesAsMotionValues;
30
+ animate: SVGAttributesAsMotionValues;
31
+ animateMotion: SVGAttributesAsMotionValues;
32
+ animateTransform: SVGAttributesAsMotionValues;
33
+ circle: SVGAttributesAsMotionValues;
34
+ clipPath: SVGAttributesAsMotionValues;
35
+ defs: SVGAttributesAsMotionValues;
36
+ desc: SVGAttributesAsMotionValues;
37
+ ellipse: SVGAttributesAsMotionValues;
38
+ feBlend: SVGAttributesAsMotionValues;
39
+ feColorMatrix: SVGAttributesAsMotionValues;
40
+ feComponentTransfer: SVGAttributesAsMotionValues;
41
+ feComposite: SVGAttributesAsMotionValues;
42
+ feConvolveMatrix: SVGAttributesAsMotionValues;
43
+ feDiffuseLighting: SVGAttributesAsMotionValues;
44
+ feDisplacementMap: SVGAttributesAsMotionValues;
45
+ feDistantLight: SVGAttributesAsMotionValues;
46
+ feDropShadow: SVGAttributesAsMotionValues;
47
+ feFlood: SVGAttributesAsMotionValues;
48
+ feFuncA: SVGAttributesAsMotionValues;
49
+ feFuncB: SVGAttributesAsMotionValues;
50
+ feFuncG: SVGAttributesAsMotionValues;
51
+ feFuncR: SVGAttributesAsMotionValues;
52
+ feGaussianBlur: SVGAttributesAsMotionValues;
53
+ feImage: SVGAttributesAsMotionValues;
54
+ feMerge: SVGAttributesAsMotionValues;
55
+ feMergeNode: SVGAttributesAsMotionValues;
56
+ feMorphology: SVGAttributesAsMotionValues;
57
+ feOffset: SVGAttributesAsMotionValues;
58
+ fePointLight: SVGAttributesAsMotionValues;
59
+ feSpecularLighting: SVGAttributesAsMotionValues;
60
+ feSpotLight: SVGAttributesAsMotionValues;
61
+ feTile: SVGAttributesAsMotionValues;
62
+ feTurbulence: SVGAttributesAsMotionValues;
63
+ filter: SVGAttributesAsMotionValues;
64
+ foreignObject: SVGAttributesAsMotionValues;
65
+ g: SVGAttributesAsMotionValues;
66
+ image: SVGAttributesAsMotionValues;
67
+ line: SVGAttributesAsMotionValues;
68
+ linearGradient: SVGAttributesAsMotionValues;
69
+ marker: SVGAttributesAsMotionValues;
70
+ mask: SVGAttributesAsMotionValues;
71
+ metadata: SVGAttributesAsMotionValues;
72
+ mpath: SVGAttributesAsMotionValues;
73
+ path: SVGAttributesAsMotionValues;
74
+ pattern: SVGAttributesAsMotionValues;
75
+ polygon: SVGAttributesAsMotionValues;
76
+ polyline: SVGAttributesAsMotionValues;
77
+ radialGradient: SVGAttributesAsMotionValues;
78
+ rect: SVGAttributesAsMotionValues;
79
+ stop: SVGAttributesAsMotionValues;
80
+ switch: SVGAttributesAsMotionValues;
81
+ symbol: SVGAttributesAsMotionValues;
82
+ text: SVGAttributesAsMotionValues;
83
+ textPath: SVGAttributesAsMotionValues;
84
+ tspan: SVGAttributesAsMotionValues;
85
+ use: SVGAttributesAsMotionValues;
86
+ view: SVGAttributesAsMotionValues;
87
+ }
88
+ export type SetMotionValueType<T, Keys extends keyof T> = {
89
+ [K in keyof T]: K extends Keys ? SVGAttributesAsMotionValues : T[K];
90
+ };
91
+ export {};
@@ -1,8 +1,8 @@
1
- import { TransformProperties } from '../types';
2
1
  import { DOMKeyframesDefinition, DynamicAnimationOptions } from 'framer-motion';
3
2
  import { MotionValue } from 'framer-motion/dom';
4
3
  import { animate } from '../../node_modules/framer-motion/dist/es/animation/animate/index.mjs';
5
4
  import { IntrinsicElementAttributes } from 'vue';
5
+ import { TransformProperties } from './transform';
6
6
  type AnimationPlaybackControls = ReturnType<typeof animate>;
7
7
  export interface Variant extends DOMKeyframesDefinition {
8
8
  transition?: DynamicAnimationOptions;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "motion-v",
3
- "version": "0.2.1",
3
+ "version": "0.2.3",
4
4
  "description": "",
5
5
  "author": "",
6
6
  "license": "MIT",
@@ -9,16 +9,20 @@
9
9
  "type": "git",
10
10
  "url": "https://github.com/rick-hup/motion-vue.git"
11
11
  },
12
- "keywords": [],
12
+ "keywords": [
13
+ "vue",
14
+ "motion",
15
+ "motionone"
16
+ ],
13
17
  "sideEffects": false,
14
18
  "exports": {
15
19
  ".": {
16
20
  "types": "./dist/src/index.d.ts",
17
21
  "import": "./dist/index.js",
18
- "require": "./dist/index.cjs"
22
+ "require": "./dist/index.umd.cjs"
19
23
  }
20
24
  },
21
- "main": "./dist/index.cjs",
25
+ "main": "./dist/index.umd.cjs",
22
26
  "module": "./dist/index.js",
23
27
  "types": "./dist/src/index.d.ts",
24
28
  "files": [