framer-motion 12.11.4 → 12.12.0

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.
Files changed (37) hide show
  1. package/dist/cjs/client.js +1 -1
  2. package/dist/cjs/{create-t9legXtK.js → create-BiMCrvDh.js} +75 -78
  3. package/dist/cjs/dom-mini.js +1 -3
  4. package/dist/cjs/dom.js +15 -17
  5. package/dist/cjs/index.js +15 -53
  6. package/dist/cjs/m.js +113 -115
  7. package/dist/dom.js +1 -1
  8. package/dist/es/animation/animate/single-value.mjs +1 -2
  9. package/dist/es/animation/animate/subject.mjs +1 -1
  10. package/dist/es/animation/sequence/create.mjs +1 -2
  11. package/dist/es/components/Reorder/Item.mjs +1 -1
  12. package/dist/es/index.mjs +0 -1
  13. package/dist/es/render/VisualElement.mjs +1 -2
  14. package/dist/es/render/dom/DOMVisualElement.mjs +1 -2
  15. package/dist/es/render/dom/use-render.mjs +2 -2
  16. package/dist/es/render/html/use-props.mjs +1 -1
  17. package/dist/es/render/html/utils/scrape-motion-values.mjs +1 -1
  18. package/dist/es/render/svg/utils/scrape-motion-values.mjs +1 -2
  19. package/dist/es/render/utils/motion-values.mjs +1 -2
  20. package/dist/es/value/use-motion-template.mjs +1 -1
  21. package/dist/es/value/use-spring.mjs +12 -52
  22. package/dist/es/value/use-will-change/is.mjs +1 -1
  23. package/dist/es/value/utils/resolve-motion-value.mjs +1 -1
  24. package/dist/framer-motion.dev.js +141 -110
  25. package/dist/framer-motion.js +1 -1
  26. package/dist/m.d.ts +3 -3
  27. package/dist/size-rollup-animate.js +1 -1
  28. package/dist/size-rollup-dom-animation-assets.js +1 -1
  29. package/dist/size-rollup-dom-animation-m.js +1 -1
  30. package/dist/size-rollup-dom-max-assets.js +1 -1
  31. package/dist/size-rollup-m.js +1 -1
  32. package/dist/size-rollup-motion.js +1 -1
  33. package/dist/types/client.d.ts +1 -1
  34. package/dist/types/index.d.ts +7 -9
  35. package/dist/{types.d-CQt5spQA.d.ts → types.d-CtuPurYT.d.ts} +3 -3
  36. package/package.json +3 -3
  37. package/dist/es/value/utils/is-motion-value.mjs +0 -3
package/dist/m.d.ts CHANGED
@@ -1093,7 +1093,7 @@ interface DraggableProps extends DragHandlers {
1093
1093
  * Applies constraints on the permitted draggable area.
1094
1094
  *
1095
1095
  * It can accept an object of optional `top`, `left`, `right`, and `bottom` values, measured in pixels.
1096
- * This will define a distance the named edge of the draggable component.
1096
+ * This will define a distance from the named edge of the draggable component.
1097
1097
  *
1098
1098
  * Alternatively, it can accept a `ref` to another component created with React's `useRef` hook.
1099
1099
  * This `ref` should be passed both to the draggable component's `dragConstraints` prop, and the `ref`
@@ -1153,7 +1153,7 @@ interface DraggableProps extends DragHandlers {
1153
1153
  /**
1154
1154
  * Allows you to change dragging inertia parameters.
1155
1155
  * When releasing a draggable Frame, an animation with type `inertia` starts. The animation is based on your dragging velocity. This property allows you to customize it.
1156
- * See {@link https://framer.com/api/animation/#inertia | Inertia} for all properties you can use.
1156
+ * See {@link https://motion.dev/docs/react-motion-component#dragtransition | Inertia} for all properties you can use.
1157
1157
  *
1158
1158
  * ```jsx
1159
1159
  * <motion.div
@@ -1802,7 +1802,7 @@ interface AnimationControls {
1802
1802
  * ```
1803
1803
  *
1804
1804
  * @param definition - Properties or variant label to animate to
1805
- * @param transition - Optional `transtion` to apply to a variant
1805
+ * @param transition - Optional `transition` to apply to a variant
1806
1806
  * @returns - A `Promise` that resolves when all animations have completed.
1807
1807
  *
1808
1808
  * @public
@@ -1 +1 @@
1
- function t(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}const e=(t,e,n)=>n>e?e:n<t?t:n;const n={},s=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),i=t=>/^0[^.\s]+$/u.test(t);function r(t){let e;return()=>(void 0===e&&(e=t()),e)}const a=t=>t,o=(t,e)=>n=>e(t(n)),l=(...t)=>t.reduce(o),u=(t,e,n)=>{const s=e-t;return 0===s?1:(n-t)/s};class h{constructor(){this.subscriptions=[]}add(e){var n,s;return n=this.subscriptions,s=e,-1===n.indexOf(s)&&n.push(s),()=>t(this.subscriptions,e)}notify(t,e,n){const s=this.subscriptions.length;if(s)if(1===s)this.subscriptions[0](t,e,n);else for(let i=0;i<s;i++){const s=this.subscriptions[i];s&&s(t,e,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const c=t=>1e3*t,d=t=>t/1e3;function p(t,e){return e?t*(1e3/e):0}const m=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t;function f(t,e,n,s){if(t===e&&n===s)return a;const i=e=>function(t,e,n,s,i){let r,a,o=0;do{a=e+(n-e)/2,r=m(a,s,i)-t,r>0?n=a:e=a}while(Math.abs(r)>1e-7&&++o<12);return a}(e,0,1,t,n);return t=>0===t||1===t?t:m(i(t),e,s)}const y=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,g=t=>e=>1-t(1-e),v=f(.33,1.53,.69,.99),b=g(v),w=y(b),T=t=>(t*=2)<1?.5*b(t):.5*(2-Math.pow(2,-10*(t-1))),M=t=>1-Math.sin(Math.acos(t)),V=g(M),A=y(M),S=f(.42,0,1,1),x=f(0,0,.58,1),k=f(.42,0,.58,1),C=t=>Array.isArray(t)&&"number"!=typeof t[0];function F(t,e){return C(t)?t[((t,e,n)=>{const s=e-t;return((n-t)%s+s)%s+t})(0,t.length,e)]:t}const P=t=>Array.isArray(t)&&"number"==typeof t[0],O={linear:a,easeIn:S,easeInOut:k,easeOut:x,circIn:M,circInOut:A,circOut:V,backIn:b,backInOut:w,backOut:v,anticipate:T},E=t=>{if(P(t)){t.length;const[e,n,s,i]=t;return f(e,n,s,i)}return"string"==typeof t?O[t]:t},D=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],I={value:null,addProjectionMetrics:null};function R(t,e){let s=!1,i=!0;const r={delta:0,timestamp:0,isProcessing:!1},a=()=>s=!0,o=D.reduce(((t,n)=>(t[n]=function(t,e){let n=new Set,s=new Set,i=!1,r=!1;const a=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1},l=0;function u(e){a.has(e)&&(h.schedule(e),t()),l++,e(o)}const h={schedule:(t,e=!1,r=!1)=>{const o=r&&i?n:s;return e&&a.add(t),o.has(t)||o.add(t),t},cancel:t=>{s.delete(t),a.delete(t)},process:t=>{o=t,i?r=!0:(i=!0,[n,s]=[s,n],n.forEach(u),e&&I.value&&I.value.frameloop[e].push(l),l=0,n.clear(),i=!1,r&&(r=!1,h.process(t)))}};return h}(a,e?n:void 0),t)),{}),{setup:l,read:u,resolveKeyframes:h,preUpdate:c,update:d,preRender:p,render:m,postRender:f}=o,y=()=>{const a=n.useManualTiming?r.timestamp:performance.now();s=!1,n.useManualTiming||(r.delta=i?1e3/60:Math.max(Math.min(a-r.timestamp,40),1)),r.timestamp=a,r.isProcessing=!0,l.process(r),u.process(r),h.process(r),c.process(r),d.process(r),p.process(r),m.process(r),f.process(r),r.isProcessing=!1,s&&e&&(i=!1,t(y))};return{schedule:D.reduce(((e,n)=>{const a=o[n];return e[n]=(e,n=!1,o=!1)=>(s||(s=!0,i=!0,r.isProcessing||t(y)),a.schedule(e,n,o)),e}),{}),cancel:t=>{for(let e=0;e<D.length;e++)o[D[e]].cancel(t)},state:r,steps:o}}const{schedule:B,cancel:N,state:K,steps:j}=R("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:a,!0);let W;function Y(){W=void 0}const $={now:()=>(void 0===W&&$.set(K.isProcessing||n.useManualTiming?K.timestamp:performance.now()),W),set:t=>{W=t,queueMicrotask(Y)}},L=t=>e=>"string"==typeof e&&e.startsWith(t),U=L("--"),X=L("var(--"),q=t=>!!X(t)&&z.test(t.split("/*")[0].trim()),z=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Z={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},H={...Z,transform:t=>e(0,1,t)},_={...Z,default:1},G=t=>Math.round(1e5*t)/1e5,J=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;const Q=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,tt=(t,e)=>n=>Boolean("string"==typeof n&&Q.test(n)&&n.startsWith(t)||e&&!function(t){return null==t}(n)&&Object.prototype.hasOwnProperty.call(n,e)),et=(t,e,n)=>s=>{if("string"!=typeof s)return s;const[i,r,a,o]=s.match(J);return{[t]:parseFloat(i),[e]:parseFloat(r),[n]:parseFloat(a),alpha:void 0!==o?parseFloat(o):1}},nt={...Z,transform:t=>Math.round((t=>e(0,255,t))(t))},st={test:tt("rgb","red"),parse:et("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:s=1})=>"rgba("+nt.transform(t)+", "+nt.transform(e)+", "+nt.transform(n)+", "+G(H.transform(s))+")"};const it={test:tt("#"),parse:function(t){let e="",n="",s="",i="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),s=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),s=t.substring(3,4),i=t.substring(4,5),e+=e,n+=n,s+=s,i+=i),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(s,16),alpha:i?parseInt(i,16)/255:1}},transform:st.transform},rt=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),at=rt("deg"),ot=rt("%"),lt=rt("px"),ut=rt("vh"),ht=rt("vw"),ct=(()=>({...ot,parse:t=>ot.parse(t)/100,transform:t=>ot.transform(100*t)}))(),dt={test:tt("hsl","hue"),parse:et("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:s=1})=>"hsla("+Math.round(t)+", "+ot.transform(G(e))+", "+ot.transform(G(n))+", "+G(H.transform(s))+")"},pt={test:t=>st.test(t)||it.test(t)||dt.test(t),parse:t=>st.test(t)?st.parse(t):dt.test(t)?dt.parse(t):it.parse(t),transform:t=>"string"==typeof t?t:t.hasOwnProperty("red")?st.transform(t):dt.transform(t)},mt=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;const ft="number",yt="color",gt=/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 vt(t){const e=t.toString(),n=[],s={color:[],number:[],var:[]},i=[];let r=0;const a=e.replace(gt,(t=>(pt.test(t)?(s.color.push(r),i.push(yt),n.push(pt.parse(t))):t.startsWith("var(")?(s.var.push(r),i.push("var"),n.push(t)):(s.number.push(r),i.push(ft),n.push(parseFloat(t))),++r,"${}"))).split("${}");return{values:n,split:a,indexes:s,types:i}}function bt(t){return vt(t).values}function wt(t){const{split:e,types:n}=vt(t),s=e.length;return t=>{let i="";for(let r=0;r<s;r++)if(i+=e[r],void 0!==t[r]){const e=n[r];i+=e===ft?G(t[r]):e===yt?pt.transform(t[r]):t[r]}return i}}const Tt=t=>"number"==typeof t?0:t;const Mt={test:function(t){return isNaN(t)&&"string"==typeof t&&(t.match(J)?.length||0)+(t.match(mt)?.length||0)>0},parse:bt,createTransformer:wt,getAnimatableNone:function(t){const e=bt(t);return wt(t)(e.map(Tt))}};function Vt(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function At(t,e){return n=>n>0?e:t}const St=(t,e,n)=>t+(e-t)*n,xt=(t,e,n)=>{const s=t*t,i=n*(e*e-s)+s;return i<0?0:Math.sqrt(i)},kt=[it,st,dt];function Ct(t){const e=(n=t,kt.find((t=>t.test(n))));var n;if(!Boolean(e))return!1;let s=e.parse(t);return e===dt&&(s=function({hue:t,saturation:e,lightness:n,alpha:s}){t/=360,n/=100;let i=0,r=0,a=0;if(e/=100){const s=n<.5?n*(1+e):n+e-n*e,o=2*n-s;i=Vt(o,s,t+1/3),r=Vt(o,s,t),a=Vt(o,s,t-1/3)}else i=r=a=n;return{red:Math.round(255*i),green:Math.round(255*r),blue:Math.round(255*a),alpha:s}}(s)),s}const Ft=(t,e)=>{const n=Ct(t),s=Ct(e);if(!n||!s)return At(t,e);const i={...n};return t=>(i.red=xt(n.red,s.red,t),i.green=xt(n.green,s.green,t),i.blue=xt(n.blue,s.blue,t),i.alpha=St(n.alpha,s.alpha,t),st.transform(i))},Pt=new Set(["none","hidden"]);function Ot(t,e){return n=>St(t,e,n)}function Et(t){return"number"==typeof t?Ot:"string"==typeof t?q(t)?At:pt.test(t)?Ft:Rt:Array.isArray(t)?Dt:"object"==typeof t?pt.test(t)?Ft:It:At}function Dt(t,e){const n=[...t],s=n.length,i=t.map(((t,n)=>Et(t)(t,e[n])));return t=>{for(let e=0;e<s;e++)n[e]=i[e](t);return n}}function It(t,e){const n={...t,...e},s={};for(const i in n)void 0!==t[i]&&void 0!==e[i]&&(s[i]=Et(t[i])(t[i],e[i]));return t=>{for(const e in s)n[e]=s[e](t);return n}}const Rt=(t,e)=>{const n=Mt.createTransformer(e),s=vt(t),i=vt(e);return s.indexes.var.length===i.indexes.var.length&&s.indexes.color.length===i.indexes.color.length&&s.indexes.number.length>=i.indexes.number.length?Pt.has(t)&&!i.values.length||Pt.has(e)&&!s.values.length?function(t,e){return Pt.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}(t,e):l(Dt(function(t,e){const n=[],s={color:0,var:0,number:0};for(let i=0;i<e.values.length;i++){const r=e.types[i],a=t.indexes[r][s[r]],o=t.values[a]??0;n[i]=o,s[r]++}return n}(s,i),i.values),n):At(t,e)};function Bt(t,e,n){if("number"==typeof t&&"number"==typeof e&&"number"==typeof n)return St(t,e,n);return Et(t)(t,e)}const Nt=t=>{const e=({timestamp:e})=>t(e);return{start:(t=!0)=>B.update(e,t),stop:()=>N(e),now:()=>K.isProcessing?K.timestamp:$.now()}},Kt=(t,e,n=10)=>{let s="";const i=Math.max(Math.round(e/n),2);for(let e=0;e<i;e++)s+=t(e/(i-1))+", ";return`linear(${s.substring(0,s.length-2)})`},jt=2e4;function Wt(t){let e=0;let n=t.next(e);for(;!n.done&&e<jt;)e+=50,n=t.next(e);return e>=jt?1/0:e}function Yt(t,e=100,n){const s=n({...t,keyframes:[0,e]}),i=Math.min(Wt(s),jt);return{type:"keyframes",ease:t=>s.next(i*t).value/e,duration:d(i)}}function $t(t,e,n){const s=Math.max(e-5,0);return p(n-t(s),e-s)}const Lt=100,Ut=10,Xt=1,qt=0,zt=800,Zt=.3,Ht=.3,_t={granular:.01,default:2},Gt={granular:.005,default:.5},Jt=.01,Qt=10,te=.05,ee=1,ne=.001;function se({duration:t=zt,bounce:n=Zt,velocity:s=qt,mass:i=Xt}){let r,a,o=1-n;o=e(te,ee,o),t=e(Jt,Qt,d(t)),o<1?(r=e=>{const n=e*o,i=n*t,r=n-s,a=re(e,o),l=Math.exp(-i);return ne-r/a*l},a=e=>{const n=e*o*t,i=n*s+s,a=Math.pow(o,2)*Math.pow(e,2)*t,l=Math.exp(-n),u=re(Math.pow(e,2),o);return(-r(e)+ne>0?-1:1)*((i-a)*l)/u}):(r=e=>Math.exp(-e*t)*((e-s)*t+1)-.001,a=e=>Math.exp(-e*t)*(t*t*(s-e)));const l=function(t,e,n){let s=n;for(let n=1;n<ie;n++)s-=t(s)/e(s);return s}(r,a,5/t);if(t=c(t),isNaN(l))return{stiffness:Lt,damping:Ut,duration:t};{const e=Math.pow(l,2)*i;return{stiffness:e,damping:2*o*Math.sqrt(i*e),duration:t}}}const ie=12;function re(t,e){return t*Math.sqrt(1-e*e)}const ae=["duration","bounce"],oe=["stiffness","damping","mass"];function le(t,e){return e.some((e=>void 0!==t[e]))}function ue(t=Ht,n=Zt){const s="object"!=typeof t?{visualDuration:t,keyframes:[0,1],bounce:n}:t;let{restSpeed:i,restDelta:r}=s;const a=s.keyframes[0],o=s.keyframes[s.keyframes.length-1],l={done:!1,value:a},{stiffness:u,damping:h,mass:p,duration:m,velocity:f,isResolvedFromDuration:y}=function(t){let n={velocity:qt,stiffness:Lt,damping:Ut,mass:Xt,isResolvedFromDuration:!1,...t};if(!le(t,oe)&&le(t,ae))if(t.visualDuration){const s=t.visualDuration,i=2*Math.PI/(1.2*s),r=i*i,a=2*e(.05,1,1-(t.bounce||0))*Math.sqrt(r);n={...n,mass:Xt,stiffness:r,damping:a}}else{const e=se(t);n={...n,...e,mass:Xt},n.isResolvedFromDuration=!0}return n}({...s,velocity:-d(s.velocity||0)}),g=f||0,v=h/(2*Math.sqrt(u*p)),b=o-a,w=d(Math.sqrt(u/p)),T=Math.abs(b)<5;let M;if(i||(i=T?_t.granular:_t.default),r||(r=T?Gt.granular:Gt.default),v<1){const t=re(w,v);M=e=>{const n=Math.exp(-v*w*e);return o-n*((g+v*w*b)/t*Math.sin(t*e)+b*Math.cos(t*e))}}else if(1===v)M=t=>o-Math.exp(-w*t)*(b+(g+w*b)*t);else{const t=w*Math.sqrt(v*v-1);M=e=>{const n=Math.exp(-v*w*e),s=Math.min(t*e,300);return o-n*((g+v*w*b)*Math.sinh(s)+t*b*Math.cosh(s))/t}}const V={calculatedDuration:y&&m||null,next:t=>{const e=M(t);if(y)l.done=t>=m;else{let n=0===t?g:0;v<1&&(n=0===t?c(g):$t(M,t,e));const s=Math.abs(n)<=i,a=Math.abs(o-e)<=r;l.done=s&&a}return l.value=l.done?o:e,l},toString:()=>{const t=Math.min(Wt(V),jt),e=Kt((e=>V.next(t*e).value),t,30);return t+"ms "+e},toTransition:()=>{}};return V}function he({keyframes:t,velocity:e=0,power:n=.8,timeConstant:s=325,bounceDamping:i=10,bounceStiffness:r=500,modifyTarget:a,min:o,max:l,restDelta:u=.5,restSpeed:h}){const c=t[0],d={done:!1,value:c},p=t=>void 0===o?l:void 0===l||Math.abs(o-t)<Math.abs(l-t)?o:l;let m=n*e;const f=c+m,y=void 0===a?f:a(f);y!==f&&(m=y-c);const g=t=>-m*Math.exp(-t/s),v=t=>y+g(t),b=t=>{const e=g(t),n=v(t);d.done=Math.abs(e)<=u,d.value=d.done?y:n};let w,T;const M=t=>{var e;(e=d.value,void 0!==o&&e<o||void 0!==l&&e>l)&&(w=t,T=ue({keyframes:[d.value,p(d.value)],velocity:$t(v,t,d.value),damping:i,stiffness:r,restDelta:u,restSpeed:h}))};return M(0),{calculatedDuration:null,next:t=>{let e=!1;return T||void 0!==w||(e=!0,b(t),M(t)),void 0!==w&&t>=w?T.next(t-w):(!e&&b(t),d)}}}function ce(t,s,{clamp:i=!0,ease:r,mixer:o}={}){const h=t.length;if(s.length,1===h)return()=>s[0];if(2===h&&s[0]===s[1])return()=>s[1];const c=t[0]===t[1];t[0]>t[h-1]&&(t=[...t].reverse(),s=[...s].reverse());const d=function(t,e,s){const i=[],r=s||n.mix||Bt,o=t.length-1;for(let n=0;n<o;n++){let s=r(t[n],t[n+1]);if(e){const t=Array.isArray(e)?e[n]||a:e;s=l(t,s)}i.push(s)}return i}(s,r,o),p=d.length,m=e=>{if(c&&e<t[0])return s[0];let n=0;if(p>1)for(;n<t.length-2&&!(e<t[n+1]);n++);const i=u(t[n],t[n+1],e);return d[n](i)};return i?n=>m(e(t[0],t[h-1],n)):m}function de(t,e){const n=t[t.length-1];for(let s=1;s<=e;s++){const i=u(0,e,s);t.push(St(n,1,i))}}function pe(t){const e=[0];return de(e,t.length-1),e}function me({duration:t=300,keyframes:e,times:n,ease:s="easeInOut"}){const i=C(s)?s.map(E):E(s),r={done:!1,value:e[0]},a=function(t,e){return t.map((t=>t*e))}(n&&n.length===e.length?n:pe(e),t),o=ce(a,e,{ease:Array.isArray(i)?i:(l=e,u=i,l.map((()=>u||k)).splice(0,l.length-1))});var l,u;return{calculatedDuration:t,next:e=>(r.value=o(e),r.done=e>=t,r)}}ue.applyToOptions=t=>{const e=Yt(t,100,ue);return t.ease=e.ease,t.duration=c(e.duration),t.type="keyframes",t};const fe=t=>null!==t;function ye(t,{repeat:e,repeatType:n="loop"},s,i=1){const r=t.filter(fe),a=i<0||e&&"loop"!==n&&e%2==1?0:r.length-1;return a&&void 0!==s?s:r[a]}const ge={decay:he,inertia:he,tween:me,keyframes:me,spring:ue};function ve(t){"string"==typeof t.type&&(t.type=ge[t.type])}class be{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise((t=>{this.resolve=t}))}notifyFinished(){this.resolve()}then(t,e){return this.finished.then(t,e)}}const we=t=>t/100;class Te extends be{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=(t=!0)=>{if(t){const{motionValue:t}=this.options;t&&t.updatedAt!==$.now()&&this.tick($.now())}this.isStopped=!0,"idle"!==this.state&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),!1===t.autoplay&&this.pause()}initAnimation(){const{options:t}=this;ve(t);const{type:e=me,repeat:n=0,repeatDelay:s=0,repeatType:i,velocity:r=0}=t;let{keyframes:a}=t;const o=e||me;o!==me&&"number"!=typeof a[0]&&(this.mixKeyframes=l(we,Bt(a[0],a[1])),a=[0,100]);const u=o({...t,keyframes:a});"mirror"===i&&(this.mirroredGenerator=o({...t,keyframes:[...a].reverse(),velocity:-r})),null===u.calculatedDuration&&(u.calculatedDuration=Wt(u));const{calculatedDuration:h}=u;this.calculatedDuration=h,this.resolvedDuration=h+s,this.totalDuration=this.resolvedDuration*(n+1)-s,this.generator=u}updateTime(t){const e=Math.round(t-this.startTime)*this.playbackSpeed;null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=e}tick(t,n=!1){const{generator:s,totalDuration:i,mixKeyframes:r,mirroredGenerator:a,resolvedDuration:o,calculatedDuration:l}=this;if(null===this.startTime)return s.next(0);const{delay:u=0,keyframes:h,repeat:c,repeatType:d,repeatDelay:p,type:m,onUpdate:f,finalKeyframe:y}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const g=this.currentTime-u*(this.playbackSpeed>=0?1:-1),v=this.playbackSpeed>=0?g<0:g>i;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=i);let b=this.currentTime,w=s;if(c){const t=Math.min(this.currentTime,i)/o;let n=Math.floor(t),s=t%1;!s&&t>=1&&(s=1),1===s&&n--,n=Math.min(n,c+1);Boolean(n%2)&&("reverse"===d?(s=1-s,p&&(s-=p/o)):"mirror"===d&&(w=a)),b=e(0,1,s)*o}const T=v?{done:!1,value:h[0]}:w.next(b);r&&(T.value=r(T.value));let{done:M}=T;v||null===l||(M=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const V=null===this.holdTime&&("finished"===this.state||"running"===this.state&&M);return V&&m!==he&&(T.value=ye(h,this.options,y,this.speed)),f&&f(T.value),V&&this.finish(),T}then(t,e){return this.finished.then(t,e)}get duration(){return d(this.calculatedDuration)}get time(){return d(this.currentTime)}set time(t){t=c(t),this.currentTime=t,null===this.startTime||null!==this.holdTime||0===this.playbackSpeed?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime($.now());const e=this.playbackSpeed!==t;this.playbackSpeed=t,e&&(this.time=d(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=Nt,startTime:e}=this.options;this.driver||(this.driver=t((t=>this.tick(t)))),this.options.onPlay?.();const n=this.driver.now();"finished"===this.state?(this.updateFinished(),this.startTime=n):null!==this.holdTime?this.startTime=n-this.holdTime:this.startTime||(this.startTime=e??n),"finished"===this.state&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime($.now()),this.holdTime=this.currentTime}complete(){"running"!==this.state&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}const Me=t=>180*t/Math.PI,Ve=t=>{const e=Me(Math.atan2(t[1],t[0]));return Se(e)},Ae={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:t=>(Math.abs(t[0])+Math.abs(t[3]))/2,rotate:Ve,rotateZ:Ve,skewX:t=>Me(Math.atan(t[1])),skewY:t=>Me(Math.atan(t[2])),skew:t=>(Math.abs(t[1])+Math.abs(t[2]))/2},Se=t=>((t%=360)<0&&(t+=360),t),xe=t=>Math.sqrt(t[0]*t[0]+t[1]*t[1]),ke=t=>Math.sqrt(t[4]*t[4]+t[5]*t[5]),Ce={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:xe,scaleY:ke,scale:t=>(xe(t)+ke(t))/2,rotateX:t=>Se(Me(Math.atan2(t[6],t[5]))),rotateY:t=>Se(Me(Math.atan2(-t[2],t[0]))),rotateZ:Ve,rotate:Ve,skewX:t=>Me(Math.atan(t[4])),skewY:t=>Me(Math.atan(t[1])),skew:t=>(Math.abs(t[1])+Math.abs(t[4]))/2};function Fe(t){return t.includes("scale")?1:0}function Pe(t,e){if(!t||"none"===t)return Fe(e);const n=t.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let s,i;if(n)s=Ce,i=n;else{const e=t.match(/^matrix\(([-\d.e\s,]+)\)$/u);s=Ae,i=e}if(!i)return Fe(e);const r=s[e],a=i[1].split(",").map(Oe);return"function"==typeof r?r(a):a[r]}function Oe(t){return parseFloat(t.trim())}const Ee=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],De=(()=>new Set(Ee))(),Ie=t=>t===Z||t===lt,Re=new Set(["x","y","z"]),Be=Ee.filter((t=>!Re.has(t)));const Ne={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:(t,{transform:e})=>Pe(e,"x"),y:(t,{transform:e})=>Pe(e,"y")};Ne.translateX=Ne.x,Ne.translateY=Ne.y;const Ke=new Set;let je=!1,We=!1,Ye=!1;function $e(){if(We){const t=Array.from(Ke).filter((t=>t.needsMeasurement)),e=new Set(t.map((t=>t.element))),n=new Map;e.forEach((t=>{const e=function(t){const e=[];return Be.forEach((n=>{const s=t.getValue(n);void 0!==s&&(e.push([n,s.get()]),s.set(n.startsWith("scale")?1:0))})),e}(t);e.length&&(n.set(t,e),t.render())})),t.forEach((t=>t.measureInitialState())),e.forEach((t=>{t.render();const e=n.get(t);e&&e.forEach((([e,n])=>{t.getValue(e)?.set(n)}))})),t.forEach((t=>t.measureEndState())),t.forEach((t=>{void 0!==t.suspendedScrollY&&window.scrollTo(0,t.suspendedScrollY)}))}We=!1,je=!1,Ke.forEach((t=>t.complete(Ye))),Ke.clear()}function Le(){Ke.forEach((t=>{t.readKeyframes(),t.needsMeasurement&&(We=!0)}))}class Ue{constructor(t,e,n,s,i,r=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=e,this.name=n,this.motionValue=s,this.element=i,this.isAsync=r}scheduleResolve(){this.state="scheduled",this.isAsync?(Ke.add(this),je||(je=!0,B.read(Le),B.resolveKeyframes($e))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:e,element:n,motionValue:s}=this;if(null===t[0]){const i=s?.get(),r=t[t.length-1];if(void 0!==i)t[0]=i;else if(n&&e){const s=n.readValue(e,r);null!=s&&(t[0]=s)}void 0===t[0]&&(t[0]=r),s&&void 0===i&&s.set(t[0])}!function(t){for(let e=1;e<t.length;e++)t[e]??(t[e]=t[e-1])}(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Ke.delete(this)}cancel(){"scheduled"===this.state&&(Ke.delete(this),this.state="pending")}resume(){"pending"===this.state&&this.scheduleResolve()}}const Xe=r((()=>void 0!==window.ScrollTimeline)),qe={};function ze(t,e){const n=r(t);return()=>qe[e]??n()}const Ze=ze((()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(t){return!1}return!0}),"linearEasing"),He=([t,e,n,s])=>`cubic-bezier(${t}, ${e}, ${n}, ${s})`,_e={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:He([0,.65,.55,1]),circOut:He([.55,0,1,.45]),backIn:He([.31,.01,.66,-.59]),backOut:He([.33,1.53,.69,.99])};function Ge(t,e){return t?"function"==typeof t?Ze()?Kt(t,e):"ease-out":P(t)?He(t):Array.isArray(t)?t.map((t=>Ge(t,e)||_e.easeOut)):_e[t]:void 0}function Je(t,e,n,{delay:s=0,duration:i=300,repeat:r=0,repeatType:a="loop",ease:o="easeOut",times:l}={},u=void 0){const h={[e]:n};l&&(h.offset=l);const c=Ge(o,i);Array.isArray(c)&&(h.easing=c);const d={delay:s,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:r+1,direction:"reverse"===a?"alternate":"normal"};u&&(d.pseudoElement=u);return t.animate(h,d)}function Qe(t){return"function"==typeof t&&"applyToOptions"in t}class tn extends be{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:e,name:n,keyframes:s,pseudoElement:i,allowFlatten:r=!1,finalKeyframe:a,onComplete:o}=t;this.isPseudoElement=Boolean(i),this.allowFlatten=r,this.options=t,t.type;const l=function({type:t,...e}){return Qe(t)&&Ze()?t.applyToOptions(e):(e.duration??(e.duration=300),e.ease??(e.ease="easeOut"),e)}(t);this.animation=Je(e,n,s,l,i),!1===l.autoplay&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const t=ye(s,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(t):function(t,e,n){(t=>t.startsWith("--"))(e)?t.style.setProperty(e,n):t.style[e]=n}(e,n,t),this.animation.cancel()}o?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),"finished"===this.state&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch(t){}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;"idle"!==t&&"finished"!==t&&(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return d(Number(t))}get time(){return d(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=c(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return null!==this.finishedTime?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:e}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&Xe()?(this.animation.timeline=t,a):e(this)}}const en={anticipate:T,backInOut:w,circInOut:A};function nn(t){"string"==typeof t.ease&&t.ease in en&&(t.ease=en[t.ease])}class sn extends tn{constructor(t){nn(t),ve(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:e,onUpdate:n,onComplete:s,element:i,...r}=this.options;if(!e)return;if(void 0!==t)return void e.set(t);const a=new Te({...r,autoplay:!1}),o=c(this.finishedTime??this.time);e.setWithVelocity(a.sample(o-10).value,a.sample(o).value,10),a.stop()}}const rn=(t,e)=>"zIndex"!==e&&(!("number"!=typeof t&&!Array.isArray(t))||!("string"!=typeof t||!Mt.test(t)&&"0"!==t||t.startsWith("url(")));const an=new Set(["opacity","clipPath","filter","transform"]),on=r((()=>Object.hasOwnProperty.call(Element.prototype,"animate")));class ln extends be{constructor({autoplay:t=!0,delay:e=0,type:n="keyframes",repeat:s=0,repeatDelay:i=0,repeatType:r="loop",keyframes:a,name:o,motionValue:l,element:u,...h}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=$.now();const c={autoplay:t,delay:e,type:n,repeat:s,repeatDelay:i,repeatType:r,name:o,motionValue:l,element:u,...h},d=u?.KeyframeResolver||Ue;this.keyframeResolver=new d(a,((t,e,n)=>this.onKeyframesResolved(t,e,c,!n)),o,l,u),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,e,s,i){this.keyframeResolver=void 0;const{name:r,type:o,velocity:l,delay:u,isHandoff:h,onUpdate:c}=s;this.resolvedAt=$.now(),function(t,e,n,s){const i=t[0];if(null===i)return!1;if("display"===e||"visibility"===e)return!0;const r=t[t.length-1],a=rn(i,e),o=rn(r,e);return!(!a||!o)&&(function(t){const e=t[0];if(1===t.length)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}(t)||("spring"===n||Qe(n))&&s)}(t,r,o,l)||(!n.instantAnimations&&u||c?.(ye(t,s,e)),t[0]=t[t.length-1],s.duration=0,s.repeat=0);const d={startTime:i?this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt:void 0,finalKeyframe:e,...s,keyframes:t},p=!h&&function(t){const{motionValue:e,name:n,repeatDelay:s,repeatType:i,damping:r,type:a}=t;if(!(e&&e.owner&&e.owner.current instanceof HTMLElement))return!1;const{onUpdate:o,transformTemplate:l}=e.owner.getProps();return on()&&n&&an.has(n)&&("transform"!==n||!l)&&!o&&!s&&"mirror"!==i&&0!==r&&"inertia"!==a}(d)?new sn({...d,element:d.motionValue.owner.current}):new Te(d);p.finished.then((()=>this.notifyFinished())).catch(a),this.pendingTimeline&&(this.stopTimeline=p.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=p}get finished(){return this._animation?this.animation.finished:this._finished}then(t,e){return this.finished.finally(t).then((()=>{}))}get animation(){return this._animation||(this.keyframeResolver?.resume(),Ye=!0,Le(),$e(),Ye=!1),this._animation}get duration(){return this.animation.duration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}class un{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map((t=>t.finished)))}getAll(t){return this.animations[0][t]}setAll(t,e){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=e}attachTimeline(t){const e=this.animations.map((e=>e.attachTimeline(t)));return()=>{e.forEach(((t,e)=>{t&&t(),this.animations[e].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 state(){return this.getAll("state")}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let e=0;e<this.animations.length;e++)t=Math.max(t,this.animations[e].duration);return t}runAll(t){this.animations.forEach((e=>e[t]()))}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class hn extends un{then(t,e){return this.finished.finally(t).then((()=>{}))}}const cn=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function dn(t,e,n=1){const[i,r]=function(t){const e=cn.exec(t);if(!e)return[,];const[,n,s,i]=e;return[`--${n??s}`,i]}(t);if(!i)return;const a=window.getComputedStyle(e).getPropertyValue(i);if(a){const t=a.trim();return s(t)?parseFloat(t):t}return q(r)?dn(r,e,n+1):r}function pn(t,e){return t?.[e]??t?.default??t}const mn=new Set(["width","height","top","left","right","bottom",...Ee]),fn=t=>e=>e.test(t),yn=[Z,lt,ot,at,ht,ut,{test:t=>"auto"===t,parse:t=>t}],gn=t=>yn.find(fn(t));const vn=new Set(["brightness","contrast","saturate","opacity"]);function bn(t){const[e,n]=t.slice(0,-1).split("(");if("drop-shadow"===e)return t;const[s]=n.match(J)||[];if(!s)return t;const i=n.replace(s,"");let r=vn.has(e)?1:0;return s!==n&&(r*=100),e+"("+r+i+")"}const wn=/\b([a-z-]*)\(.*?\)/gu,Tn={...Mt,getAnimatableNone:t=>{const e=t.match(wn);return e?e.map(bn).join(" "):t}},Mn={...Z,transform:Math.round},Vn={borderWidth:lt,borderTopWidth:lt,borderRightWidth:lt,borderBottomWidth:lt,borderLeftWidth:lt,borderRadius:lt,radius:lt,borderTopLeftRadius:lt,borderTopRightRadius:lt,borderBottomRightRadius:lt,borderBottomLeftRadius:lt,width:lt,maxWidth:lt,height:lt,maxHeight:lt,top:lt,right:lt,bottom:lt,left:lt,padding:lt,paddingTop:lt,paddingRight:lt,paddingBottom:lt,paddingLeft:lt,margin:lt,marginTop:lt,marginRight:lt,marginBottom:lt,marginLeft:lt,backgroundPositionX:lt,backgroundPositionY:lt,...{rotate:at,rotateX:at,rotateY:at,rotateZ:at,scale:_,scaleX:_,scaleY:_,scaleZ:_,skew:at,skewX:at,skewY:at,distance:lt,translateX:lt,translateY:lt,translateZ:lt,x:lt,y:lt,z:lt,perspective:lt,transformPerspective:lt,opacity:H,originX:ct,originY:ct,originZ:lt},zIndex:Mn,fillOpacity:H,strokeOpacity:H,numOctaves:Mn},An={...Vn,color:pt,backgroundColor:pt,outlineColor:pt,fill:pt,stroke:pt,borderColor:pt,borderTopColor:pt,borderRightColor:pt,borderBottomColor:pt,borderLeftColor:pt,filter:Tn,WebkitFilter:Tn},Sn=t=>An[t];function xn(t,e){let n=Sn(t);return n!==Tn&&(n=Mt),n.getAnimatableNone?n.getAnimatableNone(e):void 0}const kn=new Set(["auto","none","0"]);class Cn extends Ue{constructor(t,e,n,s,i){super(t,e,n,s,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:e,name:n}=this;if(!e||!e.current)return;super.readKeyframes();for(let n=0;n<t.length;n++){let s=t[n];if("string"==typeof s&&(s=s.trim(),q(s))){const i=dn(s,e.current);void 0!==i&&(t[n]=i),n===t.length-1&&(this.finalKeyframe=s)}}if(this.resolveNoneKeyframes(),!mn.has(n)||2!==t.length)return;const[s,i]=t,r=gn(s),a=gn(i);if(r!==a)if(Ie(r)&&Ie(a))for(let e=0;e<t.length;e++){const n=t[e];"string"==typeof n&&(t[e]=parseFloat(n))}else Ne[n]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:e}=this,n=[];for(let e=0;e<t.length;e++)(null===t[e]||("number"==typeof(s=t[e])?0===s:null===s||"none"===s||"0"===s||i(s)))&&n.push(e);var s;n.length&&function(t,e,n){let s,i=0;for(;i<t.length&&!s;){const e=t[i];"string"==typeof e&&!kn.has(e)&&vt(e).values.length&&(s=t[i]),i++}if(s&&n)for(const i of e)t[i]=xn(n,s)}(t,n,e)}measureInitialState(){const{element:t,unresolvedKeyframes:e,name:n}=this;if(!t||!t.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Ne[n](t.measureViewportBox(),window.getComputedStyle(t.current)),e[0]=this.measuredOrigin;const s=e[e.length-1];void 0!==s&&t.getValue(n,s).jump(s,!1)}measureEndState(){const{element:t,name:e,unresolvedKeyframes:n}=this;if(!t||!t.current)return;const s=t.getValue(e);s&&s.jump(this.measuredOrigin,!1);const i=n.length-1,r=n[i];n[i]=Ne[e](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==r&&void 0===this.finalKeyframe&&(this.finalKeyframe=r),this.removedTransforms?.length&&this.removedTransforms.forEach((([e,n])=>{t.getValue(e).set(n)})),this.resolveNoneKeyframes()}}class Fn{constructor(t,e={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=(t,e=!0)=>{const n=$.now();if(this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(t),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const t of this.dependents)t.dirty();e&&this.events.renderRequest?.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=e.owner}setCurrent(t){var e;this.current=t,this.updatedAt=$.now(),null===this.canTrackVelocity&&void 0!==t&&(this.canTrackVelocity=(e=this.current,!isNaN(parseFloat(e))))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,e){this.events[t]||(this.events[t]=new h);const n=this.events[t].add(e);return"change"===t?()=>{n(),B.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,e){this.passiveEffect=t,this.stopPassiveEffect=e}set(t,e=!0){e&&this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t,e)}setWithVelocity(t,e,n){this.set(e),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,e=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,e&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=$.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||t-this.updatedAt>30)return 0;const e=Math.min(this.updatedAt-this.prevUpdatedAt,30);return p(parseFloat(this.current)-parseFloat(this.prevFrameValue),e)}start(t){return this.stop(),new Promise((e=>{this.hasAnimated=!0,this.animation=t(e),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.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Pn(t,e){return new Fn(t,e)}const On=(t,e)=>e&&"number"==typeof t?e.transform(t):t,En=[...yn,pt,Mt],Dn=t=>Boolean(t&&t.getVelocity);function In(t){return"object"==typeof t&&!Array.isArray(t)}function Rn(t,e,n,s){return"string"==typeof t&&In(e)?function(t,e,n){if(t instanceof EventTarget)return[t];if("string"==typeof t){let s=document;e&&(s=e.current);const i=n?.[t]??s.querySelectorAll(t);return i?Array.from(i):[]}return Array.from(t)}(t,n,s):t instanceof NodeList?Array.from(t):Array.isArray(t)?t:[t]}function Bn(t,e,n){return t*(e+1)}function Nn(t,e,n,s){return"number"==typeof e?e:e.startsWith("-")||e.startsWith("+")?Math.max(0,t+parseFloat(e)):"<"===e?n:s.get(e)??t}function Kn(e,n,s,i,r,a){!function(e,n,s){for(let i=0;i<e.length;i++){const r=e[i];r.at>n&&r.at<s&&(t(e,r),i--)}}(e,r,a);for(let t=0;t<n.length;t++)e.push({value:n[t],at:St(r,a,i[t]),easing:F(s,t)})}function jn(t,e){for(let n=0;n<t.length;n++)t[n]=t[n]/(e+1)}function Wn(t,e){return t.at===e.at?null===t.value?1:null===e.value?-1:0:t.at-e.at}function Yn(t,e){return!e.has(t)&&e.set(t,{}),e.get(t)}function $n(t,e){return e[t]||(e[t]=[]),e[t]}function Ln(t){return Array.isArray(t)?t:[t]}function Un(t,e){return t&&t[e]?{...t,...t[e]}:{...t}}const Xn=t=>"number"==typeof t,qn=t=>t.every(Xn),zn=new WeakMap;function Zn(t){const e=[{},{}];return t?.values.forEach(((t,n)=>{e[0][n]=t.get(),e[1][n]=t.getVelocity()})),e}function Hn(t,e,n,s){if("function"==typeof e){const[i,r]=Zn(s);e=e(void 0!==n?n:t.custom,i,r)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[i,r]=Zn(s);e=e(void 0!==n?n:t.custom,i,r)}return e}function _n(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,Pn(n))}function Gn(t){return(t=>Array.isArray(t))(t)?t[t.length-1]||0:t}function Jn(t,e){const n=function(t,e,n){const s=t.getProps();return Hn(s,e,void 0!==n?n:s.custom,t)}(t,e);let{transitionEnd:s={},transition:i={},...r}=n||{};r={...r,...s};for(const e in r){_n(t,e,Gn(r[e]))}}function Qn(t,e){const s=t.getValue("willChange");if(i=s,Boolean(Dn(i)&&i.add))return s.add(e);if(!s&&n.WillChange){const s=new n.WillChange("auto");t.addValue("willChange",s),s.add(e)}var i}const ts=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),es="data-"+ts("framerAppearId");function ns(t){return t.props[es]}const ss=t=>null!==t;const is={type:"spring",stiffness:500,damping:25,restSpeed:10},rs={type:"keyframes",duration:.8},as={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},os=(t,{keyframes:e})=>e.length>2?rs:De.has(t)?t.startsWith("scale")?{type:"spring",stiffness:550,damping:0===e[1]?2*Math.sqrt(550):30,restSpeed:10}:is:as;const ls=(t,e,s,i={},r,a)=>o=>{const l=pn(i,t)||{},u=l.delay||i.delay||0;let{elapsed:h=0}=i;h-=c(u);const d={keyframes:Array.isArray(s)?s:[null,s],ease:"easeOut",velocity:e.getVelocity(),...l,delay:-h,onUpdate:t=>{e.set(t),l.onUpdate&&l.onUpdate(t)},onComplete:()=>{o(),l.onComplete&&l.onComplete()},name:t,motionValue:e,element:a?void 0:r};(function({when:t,delay:e,delayChildren:n,staggerChildren:s,staggerDirection:i,repeat:r,repeatType:a,repeatDelay:o,from:l,elapsed:u,...h}){return!!Object.keys(h).length})(l)||Object.assign(d,os(t,d)),d.duration&&(d.duration=c(d.duration)),d.repeatDelay&&(d.repeatDelay=c(d.repeatDelay)),void 0!==d.from&&(d.keyframes[0]=d.from);let p=!1;if((!1===d.type||0===d.duration&&!d.repeatDelay)&&(d.duration=0,0===d.delay&&(p=!0)),(n.instantAnimations||n.skipAnimations)&&(p=!0,d.duration=0,d.delay=0),d.allowFlatten=!l.type&&!l.ease,p&&!a&&void 0!==e.get()){const t=function(t,{repeat:e,repeatType:n="loop"},s){const i=t.filter(ss),r=e&&"loop"!==n&&e%2==1?0:i.length-1;return r&&void 0!==s?s:i[r]}(d.keyframes,l);if(void 0!==t)return void B.update((()=>{d.onUpdate(t),d.onComplete()}))}return l.isSync?new Te(d):new ln(d)};function us({protectedKeys:t,needsAnimating:e},n){const s=t.hasOwnProperty(n)&&!0!==e[n];return e[n]=!1,s}function hs(t,e,{delay:n=0,transitionOverride:s,type:i}={}){let{transition:r=t.getDefaultTransition(),transitionEnd:a,...o}=e;s&&(r=s);const l=[],u=i&&t.animationState&&t.animationState.getState()[i];for(const e in o){const s=t.getValue(e,t.latestValues[e]??null),i=o[e];if(void 0===i||u&&us(u,e))continue;const a={delay:n,...pn(r||{},e)},h=s.get();if(void 0!==h&&!s.isAnimating&&!Array.isArray(i)&&i===h&&!a.velocity)continue;let c=!1;if(window.MotionHandoffAnimation){const n=ns(t);if(n){const t=window.MotionHandoffAnimation(n,e,B);null!==t&&(a.startTime=t,c=!0)}}Qn(t,e),s.start(ls(e,s,i,t.shouldReduceMotion&&mn.has(e)?{type:!1}:a,t,c));const d=s.animation;d&&l.push(d)}return a&&Promise.all(l).then((()=>{B.update((()=>{a&&Jn(t,a)}))})),l}const cs={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"]},ds={};for(const t in cs)ds[t]={isEnabled:e=>cs[t].some((t=>!!e[t]))};const ps=()=>({x:{min:0,max:0},y:{min:0,max:0}}),ms="undefined"!=typeof window,fs={current:null},ys={current:!1};const gs=["initial","animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"];function vs(t){return null!==(e=t.animate)&&"object"==typeof e&&"function"==typeof e.start||gs.some((e=>function(t){return"string"==typeof t||Array.isArray(t)}(t[e])));var e}const bs=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class ws{scrapeMotionValuesFromProps(t,e,n){return{}}constructor({parent:t,props:e,presenceContext:n,reducedMotionConfig:s,blockInitialAnimation:i,visualState:r},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Ue,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 t=$.now();this.renderScheduledAt<t&&(this.renderScheduledAt=t,B.render(this.render,!1,!0))};const{latestValues:o,renderState:l}=r;this.latestValues=o,this.baseTarget={...o},this.initialValues=e.initial?{...o}:{},this.renderState=l,this.parent=t,this.props=e,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=s,this.options=a,this.blockInitialAnimation=Boolean(i),this.isControllingVariants=vs(e),this.isVariantNode=function(t){return Boolean(vs(t)||t.variants)}(e),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(t&&t.current);const{willChange:u,...h}=this.scrapeMotionValuesFromProps(e,{},this);for(const t in h){const e=h[t];void 0!==o[t]&&Dn(e)&&e.set(o[t],!1)}}mount(t){this.current=t,zn.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(((t,e)=>this.bindToMotionValue(e,t))),ys.current||function(){if(ys.current=!0,ms)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),e=()=>fs.current=t.matches;t.addListener(e),e()}else fs.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||fs.current),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),N(this.notifyUpdate),N(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 e=this.features[t];e&&(e.unmount(),e.isMounted=!1)}this.current=null}bindToMotionValue(t,e){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const n=De.has(t);n&&this.onBindTransform&&this.onBindTransform();const s=e.on("change",(e=>{this.latestValues[t]=e,this.props.onUpdate&&B.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),i=e.on("renderRequest",this.scheduleRender);let r;window.MotionCheckAppearSync&&(r=window.MotionCheckAppearSync(this,t,e)),this.valueSubscriptions.set(t,(()=>{s(),i(),r&&r(),e.owner&&e.stop()}))}sortNodePosition(t){return this.current&&this.sortInstanceNodePosition&&this.type===t.type?this.sortInstanceNodePosition(this.current,t.current):0}updateFeatures(){let t="animation";for(t in ds){const e=ds[t];if(!e)continue;const{isEnabled:n,Feature:s}=e;if(!this.features[t]&&s&&n(this.props)&&(this.features[t]=new s(this)),this.features[t]){const e=this.features[t];e.isMounted?e.update():(e.mount(),e.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):{x:{min:0,max:0},y:{min:0,max:0}}}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,e){this.latestValues[t]=e}update(t,e){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=e;for(let e=0;e<bs.length;e++){const n=bs[e];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);const s=t["on"+n];s&&(this.propEventSubscriptions[n]=this.on(n,s))}this.prevMotionValues=function(t,e,n){for(const s in e){const i=e[s],r=n[s];if(Dn(i))t.addValue(s,i);else if(Dn(r))t.addValue(s,Pn(i,{owner:t}));else if(r!==i)if(t.hasValue(s)){const e=t.getValue(s);!0===e.liveStyle?e.jump(i):e.hasAnimated||e.set(i)}else{const e=t.getStaticValue(s);t.addValue(s,Pn(void 0!==e?e:i,{owner:t}))}}for(const s in n)void 0===e[s]&&t.removeValue(s);return e}(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 e=this.getClosestVariantNode();if(e)return e.variantChildren&&e.variantChildren.add(t),()=>e.variantChildren.delete(t)}addValue(t,e){const n=this.values.get(t);e!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,e),this.values.set(t,e),this.latestValues[t]=e.get())}removeValue(t){this.values.delete(t);const e=this.valueSubscriptions.get(t);e&&(e(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,e){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return void 0===n&&void 0!==e&&(n=Pn(null===e?void 0:e,{owner:this}),this.addValue(t,n)),n}readValue(t,e){let n=void 0===this.latestValues[t]&&this.current?this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options):this.latestValues[t];var r;return null!=n&&("string"==typeof n&&(s(n)||i(n))?n=parseFloat(n):(r=n,!En.find(fn(r))&&Mt.test(e)&&(n=xn(t,e))),this.setBaseTarget(t,Dn(n)?n.get():n)),Dn(n)?n.get():n}setBaseTarget(t,e){this.baseTarget[t]=e}getBaseTarget(t){const{initial:e}=this.props;let n;if("string"==typeof e||"object"==typeof e){const s=Hn(this.props,e,this.presenceContext?.custom);s&&(n=s[t])}if(e&&void 0!==n)return n;const s=this.getBaseTargetFromProps(this.props,t);return void 0===s||Dn(s)?void 0!==this.initialValues[t]&&void 0===n?void 0:this.baseTarget[t]:s}on(t,e){return this.events[t]||(this.events[t]=new h),this.events[t].add(e)}notify(t,...e){this.events[t]&&this.events[t].notify(...e)}}class Ts extends ws{constructor(){super(...arguments),this.KeyframeResolver=Cn}sortInstanceNodePosition(t,e){return 2&t.compareDocumentPosition(e)?1:-1}getBaseTargetFromProps(t,e){return t.style?t.style[e]:void 0}removeValueFromRenderState(t,{vars:e,style:n}){delete e[t],delete n[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Dn(t)&&(this.childSubscription=t.on("change",(t=>{this.current&&(this.current.textContent=`${t}`)})))}}const Ms={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Vs=Ee.length;function As(t,e,n){const{style:s,vars:i,transformOrigin:r}=t;let a=!1,o=!1;for(const t in e){const n=e[t];if(De.has(t))a=!0;else if(U(t))i[t]=n;else{const e=On(n,Vn[t]);t.startsWith("origin")?(o=!0,r[t]=e):s[t]=e}}if(e.transform||(a||n?s.transform=function(t,e,n){let s="",i=!0;for(let r=0;r<Vs;r++){const a=Ee[r],o=t[a];if(void 0===o)continue;let l=!0;if(l="number"==typeof o?o===(a.startsWith("scale")?1:0):0===parseFloat(o),!l||n){const t=On(o,Vn[a]);l||(i=!1,s+=`${Ms[a]||a}(${t}) `),n&&(e[a]=t)}}return s=s.trim(),n?s=n(e,i?"":s):i&&(s="none"),s}(e,t.transform,n):s.transform&&(s.transform="none")),o){const{originX:t="50%",originY:e="50%",originZ:n=0}=r;s.transformOrigin=`${t} ${e} ${n}`}}function Ss(t,{style:e,vars:n},s,i){Object.assign(t.style,e,i&&i.getProjectionStyles(s));for(const e in n)t.style.setProperty(e,n[e])}const xs={};function ks(t,{layout:e,layoutId:n}){return De.has(t)||t.startsWith("origin")||(e||void 0!==n)&&(!!xs[t]||"opacity"===t)}function Cs(t,e,n){const{style:s}=t,i={};for(const r in s)(Dn(s[r])||e.style&&Dn(e.style[r])||ks(r,t)||void 0!==n?.getValue(r)?.liveStyle)&&(i[r]=s[r]);return i}class Fs extends Ts{constructor(){super(...arguments),this.type="html",this.renderInstance=Ss}readValueFromInstance(t,e){if(De.has(e))return this.projection?.isProjecting?Fe(e):((t,e)=>{const{transform:n="none"}=getComputedStyle(t);return Pe(n,e)})(t,e);{const s=(n=t,window.getComputedStyle(n)),i=(U(e)?s.getPropertyValue(e):s[e])||0;return"string"==typeof i?i.trim():i}var n}measureInstanceViewportBox(t,{transformPagePoint:e}){return function(t,e){return function({top:t,left:e,right:n,bottom:s}){return{x:{min:e,max:n},y:{min:t,max:s}}}(function(t,e){if(!e)return t;const n=e({x:t.left,y:t.top}),s=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:s.y,right:s.x}}(t.getBoundingClientRect(),e))}(t,e)}build(t,e,n){As(t,e,n.transformTemplate)}scrapeMotionValuesFromProps(t,e,n){return Cs(t,e,n)}}class Ps extends ws{constructor(){super(...arguments),this.type="object"}readValueFromInstance(t,e){if(function(t,e){return t in e}(e,t)){const n=t[e];if("string"==typeof n||"number"==typeof n)return n}}getBaseTargetFromProps(){}removeValueFromRenderState(t,e){delete e.output[t]}measureInstanceViewportBox(){return{x:{min:0,max:0},y:{min:0,max:0}}}build(t,e){Object.assign(t.output,e)}renderInstance(t,{output:e}){Object.assign(t,e)}sortInstanceNodePosition(){return 0}}const Os={offset:"stroke-dashoffset",array:"stroke-dasharray"},Es={offset:"strokeDashoffset",array:"strokeDasharray"};function Ds(t,{attrX:e,attrY:n,attrScale:s,pathLength:i,pathSpacing:r=1,pathOffset:a=0,...o},l,u,h){if(As(t,o,u),l)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:c,style:d}=t;c.transform&&(d.transform=c.transform,delete c.transform),(d.transform||c.transformOrigin)&&(d.transformOrigin=c.transformOrigin??"50% 50%",delete c.transformOrigin),d.transform&&(d.transformBox=h?.transformBox??"fill-box",delete c.transformBox),void 0!==e&&(c.x=e),void 0!==n&&(c.y=n),void 0!==s&&(c.scale=s),void 0!==i&&function(t,e,n=1,s=0,i=!0){t.pathLength=1;const r=i?Os:Es;t[r.offset]=lt.transform(-s);const a=lt.transform(e),o=lt.transform(n);t[r.array]=`${a} ${o}`}(c,i,r,a,!1)}const Is=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"]);class Rs extends Ts{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ps}getBaseTargetFromProps(t,e){return t[e]}readValueFromInstance(t,e){if(De.has(e)){const t=Sn(e);return t&&t.default||0}return e=Is.has(e)?e:ts(e),t.getAttribute(e)}scrapeMotionValuesFromProps(t,e,n){return function(t,e,n){const s=Cs(t,e,n);for(const n in t)(Dn(t[n])||Dn(e[n]))&&(s[-1!==Ee.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=t[n]);return s}(t,e,n)}build(t,e,n){Ds(t,e,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(t,e,n,s){!function(t,e,n,s){Ss(t,e,void 0,s);for(const n in e.attrs)t.setAttribute(Is.has(n)?n:ts(n),e.attrs[n])}(t,e,0,s)}mount(t){var e;this.isSVGTag="string"==typeof(e=t.tagName)&&"svg"===e.toLowerCase(),super.mount(t)}}function Bs(t){const e={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},n=function(t){return t instanceof SVGElement&&"svg"!==t.tagName}(t)?new Rs(e):new Fs(e);n.mount(t),zn.set(t,n)}function Ns(t){const e=new Ps({presenceContext:null,props:{},visualState:{renderState:{output:{}},latestValues:{}}});e.mount(t),zn.set(t,e)}function Ks(t,e,n,s){const i=[];if(function(t,e){return Dn(t)||"number"==typeof t||"string"==typeof t&&!In(e)}(t,e))i.push(function(t,e,n){const s=Dn(t)?t:Pn(t);return s.start(ls("",s,e,n)),s.animation}(t,In(e)&&e.default||e,n&&n.default||n));else{const r=Rn(t,e,s),a=r.length;for(let t=0;t<a;t++){const s=r[t],o=s instanceof Element?Bs:Ns;zn.has(s)||o(s);const l=zn.get(s),u={...n};"delay"in u&&"function"==typeof u.delay&&(u.delay=u.delay(t,a)),i.push(...hs(l,{...e,transition:u},{}))}}return i}function js(t,e,n){const s=[],i=function(t,{defaultTransition:e={},...n}={},s,i){const r=e.duration||.3,a=new Map,o=new Map,l={},h=new Map;let d=0,p=0,m=0;for(let n=0;n<t.length;n++){const a=t[n];if("string"==typeof a){h.set(a,p);continue}if(!Array.isArray(a)){h.set(a.name,Nn(p,a.at,d,h));continue}let[u,f,y={}]=a;void 0!==y.at&&(p=Nn(p,y.at,d,h));let g=0;const v=(t,n,s,a=0,o=0)=>{const l=Ln(t),{delay:u=0,times:h=pe(l),type:d="keyframes",repeat:f,repeatType:y,repeatDelay:v=0,...b}=n;let{ease:w=e.ease||"easeOut",duration:T}=n;const M="function"==typeof u?u(a,o):u,V=l.length,A=Qe(d)?d:i?.[d];if(V<=2&&A){let t=100;if(2===V&&qn(l)){const e=l[1]-l[0];t=Math.abs(e)}const e={...b};void 0!==T&&(e.duration=c(T));const n=Yt(e,t,A);w=n.ease,T=n.duration}T??(T=r);const S=p+M;1===h.length&&0===h[0]&&(h[1]=1);const x=h.length-l.length;if(x>0&&de(h,x),1===l.length&&l.unshift(null),f){T=Bn(T,f);const t=[...l],e=[...h];w=Array.isArray(w)?[...w]:[w];const n=[...w];for(let s=0;s<f;s++){l.push(...t);for(let i=0;i<t.length;i++)h.push(e[i]+(s+1)),w.push(0===i?"linear":F(n,i-1))}jn(h,f)}const k=S+T;Kn(s,l,w,h,S,k),g=Math.max(M+T,g),m=Math.max(k,m)};if(Dn(u))v(f,y,$n("default",Yn(u,o)));else{const t=Rn(u,f,s,l),e=t.length;for(let n=0;n<e;n++){const s=Yn(t[n],o);for(const t in f)v(f[t],Un(y,t),$n(t,s),n,e)}}d=p,p+=g}return o.forEach(((t,s)=>{for(const i in t){const r=t[i];r.sort(Wn);const o=[],l=[],h=[];for(let t=0;t<r.length;t++){const{at:e,value:n,easing:s}=r[t];o.push(n),l.push(u(0,m,e)),h.push(s||"easeOut")}0!==l[0]&&(l.unshift(0),o.unshift(o[0]),h.unshift("easeInOut")),1!==l[l.length-1]&&(l.push(1),o.push(null)),a.has(s)||a.set(s,{keyframes:{},transition:{}});const c=a.get(s);c.keyframes[i]=o,c.transition[i]={...e,duration:m,ease:h,times:l,...n}}})),a}(t,e,n,{spring:ue});return i.forEach((({keyframes:t,transition:e},n)=>{s.push(...Ks(n,t,e))})),s}function Ws(t){return function(e,n,s){let i=[];var r;r=e,i=Array.isArray(r)&&r.some(Array.isArray)?js(e,n,t):Ks(e,n,s,t);const a=new hn(i);return t&&t.animations.push(a),a}}const Ys=Ws();export{Ys as animate,Ws as createScopedAnimate};
1
+ function t(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}const e=(t,e,n)=>n>e?e:n<t?t:n;const n={},s=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),i=t=>/^0[^.\s]+$/u.test(t);function r(t){let e;return()=>(void 0===e&&(e=t()),e)}const a=t=>t,o=(t,e)=>n=>e(t(n)),l=(...t)=>t.reduce(o),u=(t,e,n)=>{const s=e-t;return 0===s?1:(n-t)/s};class h{constructor(){this.subscriptions=[]}add(e){var n,s;return n=this.subscriptions,s=e,-1===n.indexOf(s)&&n.push(s),()=>t(this.subscriptions,e)}notify(t,e,n){const s=this.subscriptions.length;if(s)if(1===s)this.subscriptions[0](t,e,n);else for(let i=0;i<s;i++){const s=this.subscriptions[i];s&&s(t,e,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const c=t=>1e3*t,d=t=>t/1e3;function p(t,e){return e?t*(1e3/e):0}const m=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t;function f(t,e,n,s){if(t===e&&n===s)return a;const i=e=>function(t,e,n,s,i){let r,a,o=0;do{a=e+(n-e)/2,r=m(a,s,i)-t,r>0?n=a:e=a}while(Math.abs(r)>1e-7&&++o<12);return a}(e,0,1,t,n);return t=>0===t||1===t?t:m(i(t),e,s)}const y=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,g=t=>e=>1-t(1-e),v=f(.33,1.53,.69,.99),b=g(v),w=y(b),T=t=>(t*=2)<1?.5*b(t):.5*(2-Math.pow(2,-10*(t-1))),M=t=>1-Math.sin(Math.acos(t)),V=g(M),A=y(M),S=f(.42,0,1,1),x=f(0,0,.58,1),k=f(.42,0,.58,1),C=t=>Array.isArray(t)&&"number"!=typeof t[0];function F(t,e){return C(t)?t[((t,e,n)=>{const s=e-t;return((n-t)%s+s)%s+t})(0,t.length,e)]:t}const P=t=>Array.isArray(t)&&"number"==typeof t[0],O={linear:a,easeIn:S,easeInOut:k,easeOut:x,circIn:M,circInOut:A,circOut:V,backIn:b,backInOut:w,backOut:v,anticipate:T},E=t=>{if(P(t)){t.length;const[e,n,s,i]=t;return f(e,n,s,i)}return"string"==typeof t?O[t]:t},D=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],I={value:null,addProjectionMetrics:null};function R(t,e){let s=!1,i=!0;const r={delta:0,timestamp:0,isProcessing:!1},a=()=>s=!0,o=D.reduce(((t,n)=>(t[n]=function(t,e){let n=new Set,s=new Set,i=!1,r=!1;const a=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1},l=0;function u(e){a.has(e)&&(h.schedule(e),t()),l++,e(o)}const h={schedule:(t,e=!1,r=!1)=>{const o=r&&i?n:s;return e&&a.add(t),o.has(t)||o.add(t),t},cancel:t=>{s.delete(t),a.delete(t)},process:t=>{o=t,i?r=!0:(i=!0,[n,s]=[s,n],n.forEach(u),e&&I.value&&I.value.frameloop[e].push(l),l=0,n.clear(),i=!1,r&&(r=!1,h.process(t)))}};return h}(a,e?n:void 0),t)),{}),{setup:l,read:u,resolveKeyframes:h,preUpdate:c,update:d,preRender:p,render:m,postRender:f}=o,y=()=>{const a=n.useManualTiming?r.timestamp:performance.now();s=!1,n.useManualTiming||(r.delta=i?1e3/60:Math.max(Math.min(a-r.timestamp,40),1)),r.timestamp=a,r.isProcessing=!0,l.process(r),u.process(r),h.process(r),c.process(r),d.process(r),p.process(r),m.process(r),f.process(r),r.isProcessing=!1,s&&e&&(i=!1,t(y))};return{schedule:D.reduce(((e,n)=>{const a=o[n];return e[n]=(e,n=!1,o=!1)=>(s||(s=!0,i=!0,r.isProcessing||t(y)),a.schedule(e,n,o)),e}),{}),cancel:t=>{for(let e=0;e<D.length;e++)o[D[e]].cancel(t)},state:r,steps:o}}const{schedule:B,cancel:N,state:K,steps:j}=R("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:a,!0);let W;function Y(){W=void 0}const $={now:()=>(void 0===W&&$.set(K.isProcessing||n.useManualTiming?K.timestamp:performance.now()),W),set:t=>{W=t,queueMicrotask(Y)}},L=t=>e=>"string"==typeof e&&e.startsWith(t),U=L("--"),X=L("var(--"),q=t=>!!X(t)&&z.test(t.split("/*")[0].trim()),z=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Z={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},H={...Z,transform:t=>e(0,1,t)},_={...Z,default:1},G=t=>Math.round(1e5*t)/1e5,J=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;const Q=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,tt=(t,e)=>n=>Boolean("string"==typeof n&&Q.test(n)&&n.startsWith(t)||e&&!function(t){return null==t}(n)&&Object.prototype.hasOwnProperty.call(n,e)),et=(t,e,n)=>s=>{if("string"!=typeof s)return s;const[i,r,a,o]=s.match(J);return{[t]:parseFloat(i),[e]:parseFloat(r),[n]:parseFloat(a),alpha:void 0!==o?parseFloat(o):1}},nt={...Z,transform:t=>Math.round((t=>e(0,255,t))(t))},st={test:tt("rgb","red"),parse:et("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:s=1})=>"rgba("+nt.transform(t)+", "+nt.transform(e)+", "+nt.transform(n)+", "+G(H.transform(s))+")"};const it={test:tt("#"),parse:function(t){let e="",n="",s="",i="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),s=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),s=t.substring(3,4),i=t.substring(4,5),e+=e,n+=n,s+=s,i+=i),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(s,16),alpha:i?parseInt(i,16)/255:1}},transform:st.transform},rt=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),at=rt("deg"),ot=rt("%"),lt=rt("px"),ut=rt("vh"),ht=rt("vw"),ct=(()=>({...ot,parse:t=>ot.parse(t)/100,transform:t=>ot.transform(100*t)}))(),dt={test:tt("hsl","hue"),parse:et("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:s=1})=>"hsla("+Math.round(t)+", "+ot.transform(G(e))+", "+ot.transform(G(n))+", "+G(H.transform(s))+")"},pt={test:t=>st.test(t)||it.test(t)||dt.test(t),parse:t=>st.test(t)?st.parse(t):dt.test(t)?dt.parse(t):it.parse(t),transform:t=>"string"==typeof t?t:t.hasOwnProperty("red")?st.transform(t):dt.transform(t)},mt=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;const ft="number",yt="color",gt=/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 vt(t){const e=t.toString(),n=[],s={color:[],number:[],var:[]},i=[];let r=0;const a=e.replace(gt,(t=>(pt.test(t)?(s.color.push(r),i.push(yt),n.push(pt.parse(t))):t.startsWith("var(")?(s.var.push(r),i.push("var"),n.push(t)):(s.number.push(r),i.push(ft),n.push(parseFloat(t))),++r,"${}"))).split("${}");return{values:n,split:a,indexes:s,types:i}}function bt(t){return vt(t).values}function wt(t){const{split:e,types:n}=vt(t),s=e.length;return t=>{let i="";for(let r=0;r<s;r++)if(i+=e[r],void 0!==t[r]){const e=n[r];i+=e===ft?G(t[r]):e===yt?pt.transform(t[r]):t[r]}return i}}const Tt=t=>"number"==typeof t?0:t;const Mt={test:function(t){return isNaN(t)&&"string"==typeof t&&(t.match(J)?.length||0)+(t.match(mt)?.length||0)>0},parse:bt,createTransformer:wt,getAnimatableNone:function(t){const e=bt(t);return wt(t)(e.map(Tt))}};function Vt(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function At(t,e){return n=>n>0?e:t}const St=(t,e,n)=>t+(e-t)*n,xt=(t,e,n)=>{const s=t*t,i=n*(e*e-s)+s;return i<0?0:Math.sqrt(i)},kt=[it,st,dt];function Ct(t){const e=(n=t,kt.find((t=>t.test(n))));var n;if(!Boolean(e))return!1;let s=e.parse(t);return e===dt&&(s=function({hue:t,saturation:e,lightness:n,alpha:s}){t/=360,n/=100;let i=0,r=0,a=0;if(e/=100){const s=n<.5?n*(1+e):n+e-n*e,o=2*n-s;i=Vt(o,s,t+1/3),r=Vt(o,s,t),a=Vt(o,s,t-1/3)}else i=r=a=n;return{red:Math.round(255*i),green:Math.round(255*r),blue:Math.round(255*a),alpha:s}}(s)),s}const Ft=(t,e)=>{const n=Ct(t),s=Ct(e);if(!n||!s)return At(t,e);const i={...n};return t=>(i.red=xt(n.red,s.red,t),i.green=xt(n.green,s.green,t),i.blue=xt(n.blue,s.blue,t),i.alpha=St(n.alpha,s.alpha,t),st.transform(i))},Pt=new Set(["none","hidden"]);function Ot(t,e){return n=>St(t,e,n)}function Et(t){return"number"==typeof t?Ot:"string"==typeof t?q(t)?At:pt.test(t)?Ft:Rt:Array.isArray(t)?Dt:"object"==typeof t?pt.test(t)?Ft:It:At}function Dt(t,e){const n=[...t],s=n.length,i=t.map(((t,n)=>Et(t)(t,e[n])));return t=>{for(let e=0;e<s;e++)n[e]=i[e](t);return n}}function It(t,e){const n={...t,...e},s={};for(const i in n)void 0!==t[i]&&void 0!==e[i]&&(s[i]=Et(t[i])(t[i],e[i]));return t=>{for(const e in s)n[e]=s[e](t);return n}}const Rt=(t,e)=>{const n=Mt.createTransformer(e),s=vt(t),i=vt(e);return s.indexes.var.length===i.indexes.var.length&&s.indexes.color.length===i.indexes.color.length&&s.indexes.number.length>=i.indexes.number.length?Pt.has(t)&&!i.values.length||Pt.has(e)&&!s.values.length?function(t,e){return Pt.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}(t,e):l(Dt(function(t,e){const n=[],s={color:0,var:0,number:0};for(let i=0;i<e.values.length;i++){const r=e.types[i],a=t.indexes[r][s[r]],o=t.values[a]??0;n[i]=o,s[r]++}return n}(s,i),i.values),n):At(t,e)};function Bt(t,e,n){if("number"==typeof t&&"number"==typeof e&&"number"==typeof n)return St(t,e,n);return Et(t)(t,e)}const Nt=t=>{const e=({timestamp:e})=>t(e);return{start:(t=!0)=>B.update(e,t),stop:()=>N(e),now:()=>K.isProcessing?K.timestamp:$.now()}},Kt=(t,e,n=10)=>{let s="";const i=Math.max(Math.round(e/n),2);for(let e=0;e<i;e++)s+=t(e/(i-1))+", ";return`linear(${s.substring(0,s.length-2)})`},jt=2e4;function Wt(t){let e=0;let n=t.next(e);for(;!n.done&&e<jt;)e+=50,n=t.next(e);return e>=jt?1/0:e}function Yt(t,e=100,n){const s=n({...t,keyframes:[0,e]}),i=Math.min(Wt(s),jt);return{type:"keyframes",ease:t=>s.next(i*t).value/e,duration:d(i)}}function $t(t,e,n){const s=Math.max(e-5,0);return p(n-t(s),e-s)}const Lt=100,Ut=10,Xt=1,qt=0,zt=800,Zt=.3,Ht=.3,_t={granular:.01,default:2},Gt={granular:.005,default:.5},Jt=.01,Qt=10,te=.05,ee=1,ne=.001;function se({duration:t=zt,bounce:n=Zt,velocity:s=qt,mass:i=Xt}){let r,a,o=1-n;o=e(te,ee,o),t=e(Jt,Qt,d(t)),o<1?(r=e=>{const n=e*o,i=n*t,r=n-s,a=re(e,o),l=Math.exp(-i);return ne-r/a*l},a=e=>{const n=e*o*t,i=n*s+s,a=Math.pow(o,2)*Math.pow(e,2)*t,l=Math.exp(-n),u=re(Math.pow(e,2),o);return(-r(e)+ne>0?-1:1)*((i-a)*l)/u}):(r=e=>Math.exp(-e*t)*((e-s)*t+1)-.001,a=e=>Math.exp(-e*t)*(t*t*(s-e)));const l=function(t,e,n){let s=n;for(let n=1;n<ie;n++)s-=t(s)/e(s);return s}(r,a,5/t);if(t=c(t),isNaN(l))return{stiffness:Lt,damping:Ut,duration:t};{const e=Math.pow(l,2)*i;return{stiffness:e,damping:2*o*Math.sqrt(i*e),duration:t}}}const ie=12;function re(t,e){return t*Math.sqrt(1-e*e)}const ae=["duration","bounce"],oe=["stiffness","damping","mass"];function le(t,e){return e.some((e=>void 0!==t[e]))}function ue(t=Ht,n=Zt){const s="object"!=typeof t?{visualDuration:t,keyframes:[0,1],bounce:n}:t;let{restSpeed:i,restDelta:r}=s;const a=s.keyframes[0],o=s.keyframes[s.keyframes.length-1],l={done:!1,value:a},{stiffness:u,damping:h,mass:p,duration:m,velocity:f,isResolvedFromDuration:y}=function(t){let n={velocity:qt,stiffness:Lt,damping:Ut,mass:Xt,isResolvedFromDuration:!1,...t};if(!le(t,oe)&&le(t,ae))if(t.visualDuration){const s=t.visualDuration,i=2*Math.PI/(1.2*s),r=i*i,a=2*e(.05,1,1-(t.bounce||0))*Math.sqrt(r);n={...n,mass:Xt,stiffness:r,damping:a}}else{const e=se(t);n={...n,...e,mass:Xt},n.isResolvedFromDuration=!0}return n}({...s,velocity:-d(s.velocity||0)}),g=f||0,v=h/(2*Math.sqrt(u*p)),b=o-a,w=d(Math.sqrt(u/p)),T=Math.abs(b)<5;let M;if(i||(i=T?_t.granular:_t.default),r||(r=T?Gt.granular:Gt.default),v<1){const t=re(w,v);M=e=>{const n=Math.exp(-v*w*e);return o-n*((g+v*w*b)/t*Math.sin(t*e)+b*Math.cos(t*e))}}else if(1===v)M=t=>o-Math.exp(-w*t)*(b+(g+w*b)*t);else{const t=w*Math.sqrt(v*v-1);M=e=>{const n=Math.exp(-v*w*e),s=Math.min(t*e,300);return o-n*((g+v*w*b)*Math.sinh(s)+t*b*Math.cosh(s))/t}}const V={calculatedDuration:y&&m||null,next:t=>{const e=M(t);if(y)l.done=t>=m;else{let n=0===t?g:0;v<1&&(n=0===t?c(g):$t(M,t,e));const s=Math.abs(n)<=i,a=Math.abs(o-e)<=r;l.done=s&&a}return l.value=l.done?o:e,l},toString:()=>{const t=Math.min(Wt(V),jt),e=Kt((e=>V.next(t*e).value),t,30);return t+"ms "+e},toTransition:()=>{}};return V}function he({keyframes:t,velocity:e=0,power:n=.8,timeConstant:s=325,bounceDamping:i=10,bounceStiffness:r=500,modifyTarget:a,min:o,max:l,restDelta:u=.5,restSpeed:h}){const c=t[0],d={done:!1,value:c},p=t=>void 0===o?l:void 0===l||Math.abs(o-t)<Math.abs(l-t)?o:l;let m=n*e;const f=c+m,y=void 0===a?f:a(f);y!==f&&(m=y-c);const g=t=>-m*Math.exp(-t/s),v=t=>y+g(t),b=t=>{const e=g(t),n=v(t);d.done=Math.abs(e)<=u,d.value=d.done?y:n};let w,T;const M=t=>{var e;(e=d.value,void 0!==o&&e<o||void 0!==l&&e>l)&&(w=t,T=ue({keyframes:[d.value,p(d.value)],velocity:$t(v,t,d.value),damping:i,stiffness:r,restDelta:u,restSpeed:h}))};return M(0),{calculatedDuration:null,next:t=>{let e=!1;return T||void 0!==w||(e=!0,b(t),M(t)),void 0!==w&&t>=w?T.next(t-w):(!e&&b(t),d)}}}function ce(t,s,{clamp:i=!0,ease:r,mixer:o}={}){const h=t.length;if(s.length,1===h)return()=>s[0];if(2===h&&s[0]===s[1])return()=>s[1];const c=t[0]===t[1];t[0]>t[h-1]&&(t=[...t].reverse(),s=[...s].reverse());const d=function(t,e,s){const i=[],r=s||n.mix||Bt,o=t.length-1;for(let n=0;n<o;n++){let s=r(t[n],t[n+1]);if(e){const t=Array.isArray(e)?e[n]||a:e;s=l(t,s)}i.push(s)}return i}(s,r,o),p=d.length,m=e=>{if(c&&e<t[0])return s[0];let n=0;if(p>1)for(;n<t.length-2&&!(e<t[n+1]);n++);const i=u(t[n],t[n+1],e);return d[n](i)};return i?n=>m(e(t[0],t[h-1],n)):m}function de(t,e){const n=t[t.length-1];for(let s=1;s<=e;s++){const i=u(0,e,s);t.push(St(n,1,i))}}function pe(t){const e=[0];return de(e,t.length-1),e}function me({duration:t=300,keyframes:e,times:n,ease:s="easeInOut"}){const i=C(s)?s.map(E):E(s),r={done:!1,value:e[0]},a=function(t,e){return t.map((t=>t*e))}(n&&n.length===e.length?n:pe(e),t),o=ce(a,e,{ease:Array.isArray(i)?i:(l=e,u=i,l.map((()=>u||k)).splice(0,l.length-1))});var l,u;return{calculatedDuration:t,next:e=>(r.value=o(e),r.done=e>=t,r)}}ue.applyToOptions=t=>{const e=Yt(t,100,ue);return t.ease=e.ease,t.duration=c(e.duration),t.type="keyframes",t};const fe=t=>null!==t;function ye(t,{repeat:e,repeatType:n="loop"},s,i=1){const r=t.filter(fe),a=i<0||e&&"loop"!==n&&e%2==1?0:r.length-1;return a&&void 0!==s?s:r[a]}const ge={decay:he,inertia:he,tween:me,keyframes:me,spring:ue};function ve(t){"string"==typeof t.type&&(t.type=ge[t.type])}class be{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise((t=>{this.resolve=t}))}notifyFinished(){this.resolve()}then(t,e){return this.finished.then(t,e)}}const we=t=>t/100;class Te extends be{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=(t=!0)=>{if(t){const{motionValue:t}=this.options;t&&t.updatedAt!==$.now()&&this.tick($.now())}this.isStopped=!0,"idle"!==this.state&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),!1===t.autoplay&&this.pause()}initAnimation(){const{options:t}=this;ve(t);const{type:e=me,repeat:n=0,repeatDelay:s=0,repeatType:i,velocity:r=0}=t;let{keyframes:a}=t;const o=e||me;o!==me&&"number"!=typeof a[0]&&(this.mixKeyframes=l(we,Bt(a[0],a[1])),a=[0,100]);const u=o({...t,keyframes:a});"mirror"===i&&(this.mirroredGenerator=o({...t,keyframes:[...a].reverse(),velocity:-r})),null===u.calculatedDuration&&(u.calculatedDuration=Wt(u));const{calculatedDuration:h}=u;this.calculatedDuration=h,this.resolvedDuration=h+s,this.totalDuration=this.resolvedDuration*(n+1)-s,this.generator=u}updateTime(t){const e=Math.round(t-this.startTime)*this.playbackSpeed;null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=e}tick(t,n=!1){const{generator:s,totalDuration:i,mixKeyframes:r,mirroredGenerator:a,resolvedDuration:o,calculatedDuration:l}=this;if(null===this.startTime)return s.next(0);const{delay:u=0,keyframes:h,repeat:c,repeatType:d,repeatDelay:p,type:m,onUpdate:f,finalKeyframe:y}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const g=this.currentTime-u*(this.playbackSpeed>=0?1:-1),v=this.playbackSpeed>=0?g<0:g>i;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=i);let b=this.currentTime,w=s;if(c){const t=Math.min(this.currentTime,i)/o;let n=Math.floor(t),s=t%1;!s&&t>=1&&(s=1),1===s&&n--,n=Math.min(n,c+1);Boolean(n%2)&&("reverse"===d?(s=1-s,p&&(s-=p/o)):"mirror"===d&&(w=a)),b=e(0,1,s)*o}const T=v?{done:!1,value:h[0]}:w.next(b);r&&(T.value=r(T.value));let{done:M}=T;v||null===l||(M=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const V=null===this.holdTime&&("finished"===this.state||"running"===this.state&&M);return V&&m!==he&&(T.value=ye(h,this.options,y,this.speed)),f&&f(T.value),V&&this.finish(),T}then(t,e){return this.finished.then(t,e)}get duration(){return d(this.calculatedDuration)}get time(){return d(this.currentTime)}set time(t){t=c(t),this.currentTime=t,null===this.startTime||null!==this.holdTime||0===this.playbackSpeed?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime($.now());const e=this.playbackSpeed!==t;this.playbackSpeed=t,e&&(this.time=d(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=Nt,startTime:e}=this.options;this.driver||(this.driver=t((t=>this.tick(t)))),this.options.onPlay?.();const n=this.driver.now();"finished"===this.state?(this.updateFinished(),this.startTime=n):null!==this.holdTime?this.startTime=n-this.holdTime:this.startTime||(this.startTime=e??n),"finished"===this.state&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime($.now()),this.holdTime=this.currentTime}complete(){"running"!==this.state&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}const Me=t=>180*t/Math.PI,Ve=t=>{const e=Me(Math.atan2(t[1],t[0]));return Se(e)},Ae={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:t=>(Math.abs(t[0])+Math.abs(t[3]))/2,rotate:Ve,rotateZ:Ve,skewX:t=>Me(Math.atan(t[1])),skewY:t=>Me(Math.atan(t[2])),skew:t=>(Math.abs(t[1])+Math.abs(t[2]))/2},Se=t=>((t%=360)<0&&(t+=360),t),xe=t=>Math.sqrt(t[0]*t[0]+t[1]*t[1]),ke=t=>Math.sqrt(t[4]*t[4]+t[5]*t[5]),Ce={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:xe,scaleY:ke,scale:t=>(xe(t)+ke(t))/2,rotateX:t=>Se(Me(Math.atan2(t[6],t[5]))),rotateY:t=>Se(Me(Math.atan2(-t[2],t[0]))),rotateZ:Ve,rotate:Ve,skewX:t=>Me(Math.atan(t[4])),skewY:t=>Me(Math.atan(t[1])),skew:t=>(Math.abs(t[1])+Math.abs(t[4]))/2};function Fe(t){return t.includes("scale")?1:0}function Pe(t,e){if(!t||"none"===t)return Fe(e);const n=t.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let s,i;if(n)s=Ce,i=n;else{const e=t.match(/^matrix\(([-\d.e\s,]+)\)$/u);s=Ae,i=e}if(!i)return Fe(e);const r=s[e],a=i[1].split(",").map(Oe);return"function"==typeof r?r(a):a[r]}function Oe(t){return parseFloat(t.trim())}const Ee=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],De=(()=>new Set(Ee))(),Ie=t=>t===Z||t===lt,Re=new Set(["x","y","z"]),Be=Ee.filter((t=>!Re.has(t)));const Ne={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:(t,{transform:e})=>Pe(e,"x"),y:(t,{transform:e})=>Pe(e,"y")};Ne.translateX=Ne.x,Ne.translateY=Ne.y;const Ke=new Set;let je=!1,We=!1,Ye=!1;function $e(){if(We){const t=Array.from(Ke).filter((t=>t.needsMeasurement)),e=new Set(t.map((t=>t.element))),n=new Map;e.forEach((t=>{const e=function(t){const e=[];return Be.forEach((n=>{const s=t.getValue(n);void 0!==s&&(e.push([n,s.get()]),s.set(n.startsWith("scale")?1:0))})),e}(t);e.length&&(n.set(t,e),t.render())})),t.forEach((t=>t.measureInitialState())),e.forEach((t=>{t.render();const e=n.get(t);e&&e.forEach((([e,n])=>{t.getValue(e)?.set(n)}))})),t.forEach((t=>t.measureEndState())),t.forEach((t=>{void 0!==t.suspendedScrollY&&window.scrollTo(0,t.suspendedScrollY)}))}We=!1,je=!1,Ke.forEach((t=>t.complete(Ye))),Ke.clear()}function Le(){Ke.forEach((t=>{t.readKeyframes(),t.needsMeasurement&&(We=!0)}))}class Ue{constructor(t,e,n,s,i,r=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=e,this.name=n,this.motionValue=s,this.element=i,this.isAsync=r}scheduleResolve(){this.state="scheduled",this.isAsync?(Ke.add(this),je||(je=!0,B.read(Le),B.resolveKeyframes($e))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:e,element:n,motionValue:s}=this;if(null===t[0]){const i=s?.get(),r=t[t.length-1];if(void 0!==i)t[0]=i;else if(n&&e){const s=n.readValue(e,r);null!=s&&(t[0]=s)}void 0===t[0]&&(t[0]=r),s&&void 0===i&&s.set(t[0])}!function(t){for(let e=1;e<t.length;e++)t[e]??(t[e]=t[e-1])}(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Ke.delete(this)}cancel(){"scheduled"===this.state&&(Ke.delete(this),this.state="pending")}resume(){"pending"===this.state&&this.scheduleResolve()}}const Xe=r((()=>void 0!==window.ScrollTimeline)),qe={};function ze(t,e){const n=r(t);return()=>qe[e]??n()}const Ze=ze((()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(t){return!1}return!0}),"linearEasing"),He=([t,e,n,s])=>`cubic-bezier(${t}, ${e}, ${n}, ${s})`,_e={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:He([0,.65,.55,1]),circOut:He([.55,0,1,.45]),backIn:He([.31,.01,.66,-.59]),backOut:He([.33,1.53,.69,.99])};function Ge(t,e){return t?"function"==typeof t?Ze()?Kt(t,e):"ease-out":P(t)?He(t):Array.isArray(t)?t.map((t=>Ge(t,e)||_e.easeOut)):_e[t]:void 0}function Je(t,e,n,{delay:s=0,duration:i=300,repeat:r=0,repeatType:a="loop",ease:o="easeOut",times:l}={},u=void 0){const h={[e]:n};l&&(h.offset=l);const c=Ge(o,i);Array.isArray(c)&&(h.easing=c);const d={delay:s,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:r+1,direction:"reverse"===a?"alternate":"normal"};u&&(d.pseudoElement=u);return t.animate(h,d)}function Qe(t){return"function"==typeof t&&"applyToOptions"in t}class tn extends be{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:e,name:n,keyframes:s,pseudoElement:i,allowFlatten:r=!1,finalKeyframe:a,onComplete:o}=t;this.isPseudoElement=Boolean(i),this.allowFlatten=r,this.options=t,t.type;const l=function({type:t,...e}){return Qe(t)&&Ze()?t.applyToOptions(e):(e.duration??(e.duration=300),e.ease??(e.ease="easeOut"),e)}(t);this.animation=Je(e,n,s,l,i),!1===l.autoplay&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const t=ye(s,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(t):function(t,e,n){(t=>t.startsWith("--"))(e)?t.style.setProperty(e,n):t.style[e]=n}(e,n,t),this.animation.cancel()}o?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),"finished"===this.state&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch(t){}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;"idle"!==t&&"finished"!==t&&(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return d(Number(t))}get time(){return d(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=c(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return null!==this.finishedTime?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:e}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&Xe()?(this.animation.timeline=t,a):e(this)}}const en={anticipate:T,backInOut:w,circInOut:A};function nn(t){"string"==typeof t.ease&&t.ease in en&&(t.ease=en[t.ease])}class sn extends tn{constructor(t){nn(t),ve(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:e,onUpdate:n,onComplete:s,element:i,...r}=this.options;if(!e)return;if(void 0!==t)return void e.set(t);const a=new Te({...r,autoplay:!1}),o=c(this.finishedTime??this.time);e.setWithVelocity(a.sample(o-10).value,a.sample(o).value,10),a.stop()}}const rn=(t,e)=>"zIndex"!==e&&(!("number"!=typeof t&&!Array.isArray(t))||!("string"!=typeof t||!Mt.test(t)&&"0"!==t||t.startsWith("url(")));const an=new Set(["opacity","clipPath","filter","transform"]),on=r((()=>Object.hasOwnProperty.call(Element.prototype,"animate")));class ln extends be{constructor({autoplay:t=!0,delay:e=0,type:n="keyframes",repeat:s=0,repeatDelay:i=0,repeatType:r="loop",keyframes:a,name:o,motionValue:l,element:u,...h}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=$.now();const c={autoplay:t,delay:e,type:n,repeat:s,repeatDelay:i,repeatType:r,name:o,motionValue:l,element:u,...h},d=u?.KeyframeResolver||Ue;this.keyframeResolver=new d(a,((t,e,n)=>this.onKeyframesResolved(t,e,c,!n)),o,l,u),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,e,s,i){this.keyframeResolver=void 0;const{name:r,type:o,velocity:l,delay:u,isHandoff:h,onUpdate:c}=s;this.resolvedAt=$.now(),function(t,e,n,s){const i=t[0];if(null===i)return!1;if("display"===e||"visibility"===e)return!0;const r=t[t.length-1],a=rn(i,e),o=rn(r,e);return!(!a||!o)&&(function(t){const e=t[0];if(1===t.length)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}(t)||("spring"===n||Qe(n))&&s)}(t,r,o,l)||(!n.instantAnimations&&u||c?.(ye(t,s,e)),t[0]=t[t.length-1],s.duration=0,s.repeat=0);const d={startTime:i?this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt:void 0,finalKeyframe:e,...s,keyframes:t},p=!h&&function(t){const{motionValue:e,name:n,repeatDelay:s,repeatType:i,damping:r,type:a}=t;if(!(e&&e.owner&&e.owner.current instanceof HTMLElement))return!1;const{onUpdate:o,transformTemplate:l}=e.owner.getProps();return on()&&n&&an.has(n)&&("transform"!==n||!l)&&!o&&!s&&"mirror"!==i&&0!==r&&"inertia"!==a}(d)?new sn({...d,element:d.motionValue.owner.current}):new Te(d);p.finished.then((()=>this.notifyFinished())).catch(a),this.pendingTimeline&&(this.stopTimeline=p.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=p}get finished(){return this._animation?this.animation.finished:this._finished}then(t,e){return this.finished.finally(t).then((()=>{}))}get animation(){return this._animation||(this.keyframeResolver?.resume(),Ye=!0,Le(),$e(),Ye=!1),this._animation}get duration(){return this.animation.duration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}class un{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map((t=>t.finished)))}getAll(t){return this.animations[0][t]}setAll(t,e){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=e}attachTimeline(t){const e=this.animations.map((e=>e.attachTimeline(t)));return()=>{e.forEach(((t,e)=>{t&&t(),this.animations[e].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 state(){return this.getAll("state")}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let e=0;e<this.animations.length;e++)t=Math.max(t,this.animations[e].duration);return t}runAll(t){this.animations.forEach((e=>e[t]()))}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class hn extends un{then(t,e){return this.finished.finally(t).then((()=>{}))}}const cn=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function dn(t,e,n=1){const[i,r]=function(t){const e=cn.exec(t);if(!e)return[,];const[,n,s,i]=e;return[`--${n??s}`,i]}(t);if(!i)return;const a=window.getComputedStyle(e).getPropertyValue(i);if(a){const t=a.trim();return s(t)?parseFloat(t):t}return q(r)?dn(r,e,n+1):r}function pn(t,e){return t?.[e]??t?.default??t}const mn=new Set(["width","height","top","left","right","bottom",...Ee]),fn=t=>e=>e.test(t),yn=[Z,lt,ot,at,ht,ut,{test:t=>"auto"===t,parse:t=>t}],gn=t=>yn.find(fn(t));const vn=new Set(["brightness","contrast","saturate","opacity"]);function bn(t){const[e,n]=t.slice(0,-1).split("(");if("drop-shadow"===e)return t;const[s]=n.match(J)||[];if(!s)return t;const i=n.replace(s,"");let r=vn.has(e)?1:0;return s!==n&&(r*=100),e+"("+r+i+")"}const wn=/\b([a-z-]*)\(.*?\)/gu,Tn={...Mt,getAnimatableNone:t=>{const e=t.match(wn);return e?e.map(bn).join(" "):t}},Mn={...Z,transform:Math.round},Vn={borderWidth:lt,borderTopWidth:lt,borderRightWidth:lt,borderBottomWidth:lt,borderLeftWidth:lt,borderRadius:lt,radius:lt,borderTopLeftRadius:lt,borderTopRightRadius:lt,borderBottomRightRadius:lt,borderBottomLeftRadius:lt,width:lt,maxWidth:lt,height:lt,maxHeight:lt,top:lt,right:lt,bottom:lt,left:lt,padding:lt,paddingTop:lt,paddingRight:lt,paddingBottom:lt,paddingLeft:lt,margin:lt,marginTop:lt,marginRight:lt,marginBottom:lt,marginLeft:lt,backgroundPositionX:lt,backgroundPositionY:lt,...{rotate:at,rotateX:at,rotateY:at,rotateZ:at,scale:_,scaleX:_,scaleY:_,scaleZ:_,skew:at,skewX:at,skewY:at,distance:lt,translateX:lt,translateY:lt,translateZ:lt,x:lt,y:lt,z:lt,perspective:lt,transformPerspective:lt,opacity:H,originX:ct,originY:ct,originZ:lt},zIndex:Mn,fillOpacity:H,strokeOpacity:H,numOctaves:Mn},An={...Vn,color:pt,backgroundColor:pt,outlineColor:pt,fill:pt,stroke:pt,borderColor:pt,borderTopColor:pt,borderRightColor:pt,borderBottomColor:pt,borderLeftColor:pt,filter:Tn,WebkitFilter:Tn},Sn=t=>An[t];function xn(t,e){let n=Sn(t);return n!==Tn&&(n=Mt),n.getAnimatableNone?n.getAnimatableNone(e):void 0}const kn=new Set(["auto","none","0"]);class Cn extends Ue{constructor(t,e,n,s,i){super(t,e,n,s,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:e,name:n}=this;if(!e||!e.current)return;super.readKeyframes();for(let n=0;n<t.length;n++){let s=t[n];if("string"==typeof s&&(s=s.trim(),q(s))){const i=dn(s,e.current);void 0!==i&&(t[n]=i),n===t.length-1&&(this.finalKeyframe=s)}}if(this.resolveNoneKeyframes(),!mn.has(n)||2!==t.length)return;const[s,i]=t,r=gn(s),a=gn(i);if(r!==a)if(Ie(r)&&Ie(a))for(let e=0;e<t.length;e++){const n=t[e];"string"==typeof n&&(t[e]=parseFloat(n))}else Ne[n]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:e}=this,n=[];for(let e=0;e<t.length;e++)(null===t[e]||("number"==typeof(s=t[e])?0===s:null===s||"none"===s||"0"===s||i(s)))&&n.push(e);var s;n.length&&function(t,e,n){let s,i=0;for(;i<t.length&&!s;){const e=t[i];"string"==typeof e&&!kn.has(e)&&vt(e).values.length&&(s=t[i]),i++}if(s&&n)for(const i of e)t[i]=xn(n,s)}(t,n,e)}measureInitialState(){const{element:t,unresolvedKeyframes:e,name:n}=this;if(!t||!t.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Ne[n](t.measureViewportBox(),window.getComputedStyle(t.current)),e[0]=this.measuredOrigin;const s=e[e.length-1];void 0!==s&&t.getValue(n,s).jump(s,!1)}measureEndState(){const{element:t,name:e,unresolvedKeyframes:n}=this;if(!t||!t.current)return;const s=t.getValue(e);s&&s.jump(this.measuredOrigin,!1);const i=n.length-1,r=n[i];n[i]=Ne[e](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==r&&void 0===this.finalKeyframe&&(this.finalKeyframe=r),this.removedTransforms?.length&&this.removedTransforms.forEach((([e,n])=>{t.getValue(e).set(n)})),this.resolveNoneKeyframes()}}class Fn{constructor(t,e={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=(t,e=!0)=>{const n=$.now();if(this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(t),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const t of this.dependents)t.dirty();e&&this.events.renderRequest?.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=e.owner}setCurrent(t){var e;this.current=t,this.updatedAt=$.now(),null===this.canTrackVelocity&&void 0!==t&&(this.canTrackVelocity=(e=this.current,!isNaN(parseFloat(e))))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,e){this.events[t]||(this.events[t]=new h);const n=this.events[t].add(e);return"change"===t?()=>{n(),B.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,e){this.passiveEffect=t,this.stopPassiveEffect=e}set(t,e=!0){e&&this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t,e)}setWithVelocity(t,e,n){this.set(e),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,e=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,e&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=$.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||t-this.updatedAt>30)return 0;const e=Math.min(this.updatedAt-this.prevUpdatedAt,30);return p(parseFloat(this.current)-parseFloat(this.prevFrameValue),e)}start(t){return this.stop(),new Promise((e=>{this.hasAnimated=!0,this.animation=t(e),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.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Pn(t,e){return new Fn(t,e)}const On=(t,e)=>e&&"number"==typeof t?e.transform(t):t,En=t=>Boolean(t&&t.getVelocity),Dn=[...yn,pt,Mt];function In(t){return"object"==typeof t&&!Array.isArray(t)}function Rn(t,e,n,s){return"string"==typeof t&&In(e)?function(t,e,n){if(t instanceof EventTarget)return[t];if("string"==typeof t){let s=document;e&&(s=e.current);const i=n?.[t]??s.querySelectorAll(t);return i?Array.from(i):[]}return Array.from(t)}(t,n,s):t instanceof NodeList?Array.from(t):Array.isArray(t)?t:[t]}function Bn(t,e,n){return t*(e+1)}function Nn(t,e,n,s){return"number"==typeof e?e:e.startsWith("-")||e.startsWith("+")?Math.max(0,t+parseFloat(e)):"<"===e?n:s.get(e)??t}function Kn(e,n,s,i,r,a){!function(e,n,s){for(let i=0;i<e.length;i++){const r=e[i];r.at>n&&r.at<s&&(t(e,r),i--)}}(e,r,a);for(let t=0;t<n.length;t++)e.push({value:n[t],at:St(r,a,i[t]),easing:F(s,t)})}function jn(t,e){for(let n=0;n<t.length;n++)t[n]=t[n]/(e+1)}function Wn(t,e){return t.at===e.at?null===t.value?1:null===e.value?-1:0:t.at-e.at}function Yn(t,e){return!e.has(t)&&e.set(t,{}),e.get(t)}function $n(t,e){return e[t]||(e[t]=[]),e[t]}function Ln(t){return Array.isArray(t)?t:[t]}function Un(t,e){return t&&t[e]?{...t,...t[e]}:{...t}}const Xn=t=>"number"==typeof t,qn=t=>t.every(Xn),zn=new WeakMap;function Zn(t){const e=[{},{}];return t?.values.forEach(((t,n)=>{e[0][n]=t.get(),e[1][n]=t.getVelocity()})),e}function Hn(t,e,n,s){if("function"==typeof e){const[i,r]=Zn(s);e=e(void 0!==n?n:t.custom,i,r)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[i,r]=Zn(s);e=e(void 0!==n?n:t.custom,i,r)}return e}function _n(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,Pn(n))}function Gn(t){return(t=>Array.isArray(t))(t)?t[t.length-1]||0:t}function Jn(t,e){const n=function(t,e,n){const s=t.getProps();return Hn(s,e,void 0!==n?n:s.custom,t)}(t,e);let{transitionEnd:s={},transition:i={},...r}=n||{};r={...r,...s};for(const e in r){_n(t,e,Gn(r[e]))}}function Qn(t,e){const s=t.getValue("willChange");if(i=s,Boolean(En(i)&&i.add))return s.add(e);if(!s&&n.WillChange){const s=new n.WillChange("auto");t.addValue("willChange",s),s.add(e)}var i}const ts=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),es="data-"+ts("framerAppearId");function ns(t){return t.props[es]}const ss=t=>null!==t;const is={type:"spring",stiffness:500,damping:25,restSpeed:10},rs={type:"keyframes",duration:.8},as={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},os=(t,{keyframes:e})=>e.length>2?rs:De.has(t)?t.startsWith("scale")?{type:"spring",stiffness:550,damping:0===e[1]?2*Math.sqrt(550):30,restSpeed:10}:is:as;const ls=(t,e,s,i={},r,a)=>o=>{const l=pn(i,t)||{},u=l.delay||i.delay||0;let{elapsed:h=0}=i;h-=c(u);const d={keyframes:Array.isArray(s)?s:[null,s],ease:"easeOut",velocity:e.getVelocity(),...l,delay:-h,onUpdate:t=>{e.set(t),l.onUpdate&&l.onUpdate(t)},onComplete:()=>{o(),l.onComplete&&l.onComplete()},name:t,motionValue:e,element:a?void 0:r};(function({when:t,delay:e,delayChildren:n,staggerChildren:s,staggerDirection:i,repeat:r,repeatType:a,repeatDelay:o,from:l,elapsed:u,...h}){return!!Object.keys(h).length})(l)||Object.assign(d,os(t,d)),d.duration&&(d.duration=c(d.duration)),d.repeatDelay&&(d.repeatDelay=c(d.repeatDelay)),void 0!==d.from&&(d.keyframes[0]=d.from);let p=!1;if((!1===d.type||0===d.duration&&!d.repeatDelay)&&(d.duration=0,0===d.delay&&(p=!0)),(n.instantAnimations||n.skipAnimations)&&(p=!0,d.duration=0,d.delay=0),d.allowFlatten=!l.type&&!l.ease,p&&!a&&void 0!==e.get()){const t=function(t,{repeat:e,repeatType:n="loop"},s){const i=t.filter(ss),r=e&&"loop"!==n&&e%2==1?0:i.length-1;return r&&void 0!==s?s:i[r]}(d.keyframes,l);if(void 0!==t)return void B.update((()=>{d.onUpdate(t),d.onComplete()}))}return l.isSync?new Te(d):new ln(d)};function us({protectedKeys:t,needsAnimating:e},n){const s=t.hasOwnProperty(n)&&!0!==e[n];return e[n]=!1,s}function hs(t,e,{delay:n=0,transitionOverride:s,type:i}={}){let{transition:r=t.getDefaultTransition(),transitionEnd:a,...o}=e;s&&(r=s);const l=[],u=i&&t.animationState&&t.animationState.getState()[i];for(const e in o){const s=t.getValue(e,t.latestValues[e]??null),i=o[e];if(void 0===i||u&&us(u,e))continue;const a={delay:n,...pn(r||{},e)},h=s.get();if(void 0!==h&&!s.isAnimating&&!Array.isArray(i)&&i===h&&!a.velocity)continue;let c=!1;if(window.MotionHandoffAnimation){const n=ns(t);if(n){const t=window.MotionHandoffAnimation(n,e,B);null!==t&&(a.startTime=t,c=!0)}}Qn(t,e),s.start(ls(e,s,i,t.shouldReduceMotion&&mn.has(e)?{type:!1}:a,t,c));const d=s.animation;d&&l.push(d)}return a&&Promise.all(l).then((()=>{B.update((()=>{a&&Jn(t,a)}))})),l}const cs={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"]},ds={};for(const t in cs)ds[t]={isEnabled:e=>cs[t].some((t=>!!e[t]))};const ps=()=>({x:{min:0,max:0},y:{min:0,max:0}}),ms="undefined"!=typeof window,fs={current:null},ys={current:!1};const gs=["initial","animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"];function vs(t){return null!==(e=t.animate)&&"object"==typeof e&&"function"==typeof e.start||gs.some((e=>function(t){return"string"==typeof t||Array.isArray(t)}(t[e])));var e}const bs=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class ws{scrapeMotionValuesFromProps(t,e,n){return{}}constructor({parent:t,props:e,presenceContext:n,reducedMotionConfig:s,blockInitialAnimation:i,visualState:r},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Ue,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 t=$.now();this.renderScheduledAt<t&&(this.renderScheduledAt=t,B.render(this.render,!1,!0))};const{latestValues:o,renderState:l}=r;this.latestValues=o,this.baseTarget={...o},this.initialValues=e.initial?{...o}:{},this.renderState=l,this.parent=t,this.props=e,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=s,this.options=a,this.blockInitialAnimation=Boolean(i),this.isControllingVariants=vs(e),this.isVariantNode=function(t){return Boolean(vs(t)||t.variants)}(e),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(t&&t.current);const{willChange:u,...h}=this.scrapeMotionValuesFromProps(e,{},this);for(const t in h){const e=h[t];void 0!==o[t]&&En(e)&&e.set(o[t],!1)}}mount(t){this.current=t,zn.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(((t,e)=>this.bindToMotionValue(e,t))),ys.current||function(){if(ys.current=!0,ms)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),e=()=>fs.current=t.matches;t.addListener(e),e()}else fs.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||fs.current),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),N(this.notifyUpdate),N(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 e=this.features[t];e&&(e.unmount(),e.isMounted=!1)}this.current=null}bindToMotionValue(t,e){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const n=De.has(t);n&&this.onBindTransform&&this.onBindTransform();const s=e.on("change",(e=>{this.latestValues[t]=e,this.props.onUpdate&&B.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),i=e.on("renderRequest",this.scheduleRender);let r;window.MotionCheckAppearSync&&(r=window.MotionCheckAppearSync(this,t,e)),this.valueSubscriptions.set(t,(()=>{s(),i(),r&&r(),e.owner&&e.stop()}))}sortNodePosition(t){return this.current&&this.sortInstanceNodePosition&&this.type===t.type?this.sortInstanceNodePosition(this.current,t.current):0}updateFeatures(){let t="animation";for(t in ds){const e=ds[t];if(!e)continue;const{isEnabled:n,Feature:s}=e;if(!this.features[t]&&s&&n(this.props)&&(this.features[t]=new s(this)),this.features[t]){const e=this.features[t];e.isMounted?e.update():(e.mount(),e.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):{x:{min:0,max:0},y:{min:0,max:0}}}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,e){this.latestValues[t]=e}update(t,e){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=e;for(let e=0;e<bs.length;e++){const n=bs[e];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);const s=t["on"+n];s&&(this.propEventSubscriptions[n]=this.on(n,s))}this.prevMotionValues=function(t,e,n){for(const s in e){const i=e[s],r=n[s];if(En(i))t.addValue(s,i);else if(En(r))t.addValue(s,Pn(i,{owner:t}));else if(r!==i)if(t.hasValue(s)){const e=t.getValue(s);!0===e.liveStyle?e.jump(i):e.hasAnimated||e.set(i)}else{const e=t.getStaticValue(s);t.addValue(s,Pn(void 0!==e?e:i,{owner:t}))}}for(const s in n)void 0===e[s]&&t.removeValue(s);return e}(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 e=this.getClosestVariantNode();if(e)return e.variantChildren&&e.variantChildren.add(t),()=>e.variantChildren.delete(t)}addValue(t,e){const n=this.values.get(t);e!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,e),this.values.set(t,e),this.latestValues[t]=e.get())}removeValue(t){this.values.delete(t);const e=this.valueSubscriptions.get(t);e&&(e(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,e){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return void 0===n&&void 0!==e&&(n=Pn(null===e?void 0:e,{owner:this}),this.addValue(t,n)),n}readValue(t,e){let n=void 0===this.latestValues[t]&&this.current?this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options):this.latestValues[t];var r;return null!=n&&("string"==typeof n&&(s(n)||i(n))?n=parseFloat(n):(r=n,!Dn.find(fn(r))&&Mt.test(e)&&(n=xn(t,e))),this.setBaseTarget(t,En(n)?n.get():n)),En(n)?n.get():n}setBaseTarget(t,e){this.baseTarget[t]=e}getBaseTarget(t){const{initial:e}=this.props;let n;if("string"==typeof e||"object"==typeof e){const s=Hn(this.props,e,this.presenceContext?.custom);s&&(n=s[t])}if(e&&void 0!==n)return n;const s=this.getBaseTargetFromProps(this.props,t);return void 0===s||En(s)?void 0!==this.initialValues[t]&&void 0===n?void 0:this.baseTarget[t]:s}on(t,e){return this.events[t]||(this.events[t]=new h),this.events[t].add(e)}notify(t,...e){this.events[t]&&this.events[t].notify(...e)}}class Ts extends ws{constructor(){super(...arguments),this.KeyframeResolver=Cn}sortInstanceNodePosition(t,e){return 2&t.compareDocumentPosition(e)?1:-1}getBaseTargetFromProps(t,e){return t.style?t.style[e]:void 0}removeValueFromRenderState(t,{vars:e,style:n}){delete e[t],delete n[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;En(t)&&(this.childSubscription=t.on("change",(t=>{this.current&&(this.current.textContent=`${t}`)})))}}const Ms={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Vs=Ee.length;function As(t,e,n){const{style:s,vars:i,transformOrigin:r}=t;let a=!1,o=!1;for(const t in e){const n=e[t];if(De.has(t))a=!0;else if(U(t))i[t]=n;else{const e=On(n,Vn[t]);t.startsWith("origin")?(o=!0,r[t]=e):s[t]=e}}if(e.transform||(a||n?s.transform=function(t,e,n){let s="",i=!0;for(let r=0;r<Vs;r++){const a=Ee[r],o=t[a];if(void 0===o)continue;let l=!0;if(l="number"==typeof o?o===(a.startsWith("scale")?1:0):0===parseFloat(o),!l||n){const t=On(o,Vn[a]);l||(i=!1,s+=`${Ms[a]||a}(${t}) `),n&&(e[a]=t)}}return s=s.trim(),n?s=n(e,i?"":s):i&&(s="none"),s}(e,t.transform,n):s.transform&&(s.transform="none")),o){const{originX:t="50%",originY:e="50%",originZ:n=0}=r;s.transformOrigin=`${t} ${e} ${n}`}}function Ss(t,{style:e,vars:n},s,i){Object.assign(t.style,e,i&&i.getProjectionStyles(s));for(const e in n)t.style.setProperty(e,n[e])}const xs={};function ks(t,{layout:e,layoutId:n}){return De.has(t)||t.startsWith("origin")||(e||void 0!==n)&&(!!xs[t]||"opacity"===t)}function Cs(t,e,n){const{style:s}=t,i={};for(const r in s)(En(s[r])||e.style&&En(e.style[r])||ks(r,t)||void 0!==n?.getValue(r)?.liveStyle)&&(i[r]=s[r]);return i}class Fs extends Ts{constructor(){super(...arguments),this.type="html",this.renderInstance=Ss}readValueFromInstance(t,e){if(De.has(e))return this.projection?.isProjecting?Fe(e):((t,e)=>{const{transform:n="none"}=getComputedStyle(t);return Pe(n,e)})(t,e);{const s=(n=t,window.getComputedStyle(n)),i=(U(e)?s.getPropertyValue(e):s[e])||0;return"string"==typeof i?i.trim():i}var n}measureInstanceViewportBox(t,{transformPagePoint:e}){return function(t,e){return function({top:t,left:e,right:n,bottom:s}){return{x:{min:e,max:n},y:{min:t,max:s}}}(function(t,e){if(!e)return t;const n=e({x:t.left,y:t.top}),s=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:s.y,right:s.x}}(t.getBoundingClientRect(),e))}(t,e)}build(t,e,n){As(t,e,n.transformTemplate)}scrapeMotionValuesFromProps(t,e,n){return Cs(t,e,n)}}class Ps extends ws{constructor(){super(...arguments),this.type="object"}readValueFromInstance(t,e){if(function(t,e){return t in e}(e,t)){const n=t[e];if("string"==typeof n||"number"==typeof n)return n}}getBaseTargetFromProps(){}removeValueFromRenderState(t,e){delete e.output[t]}measureInstanceViewportBox(){return{x:{min:0,max:0},y:{min:0,max:0}}}build(t,e){Object.assign(t.output,e)}renderInstance(t,{output:e}){Object.assign(t,e)}sortInstanceNodePosition(){return 0}}const Os={offset:"stroke-dashoffset",array:"stroke-dasharray"},Es={offset:"strokeDashoffset",array:"strokeDasharray"};function Ds(t,{attrX:e,attrY:n,attrScale:s,pathLength:i,pathSpacing:r=1,pathOffset:a=0,...o},l,u,h){if(As(t,o,u),l)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:c,style:d}=t;c.transform&&(d.transform=c.transform,delete c.transform),(d.transform||c.transformOrigin)&&(d.transformOrigin=c.transformOrigin??"50% 50%",delete c.transformOrigin),d.transform&&(d.transformBox=h?.transformBox??"fill-box",delete c.transformBox),void 0!==e&&(c.x=e),void 0!==n&&(c.y=n),void 0!==s&&(c.scale=s),void 0!==i&&function(t,e,n=1,s=0,i=!0){t.pathLength=1;const r=i?Os:Es;t[r.offset]=lt.transform(-s);const a=lt.transform(e),o=lt.transform(n);t[r.array]=`${a} ${o}`}(c,i,r,a,!1)}const Is=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"]);class Rs extends Ts{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ps}getBaseTargetFromProps(t,e){return t[e]}readValueFromInstance(t,e){if(De.has(e)){const t=Sn(e);return t&&t.default||0}return e=Is.has(e)?e:ts(e),t.getAttribute(e)}scrapeMotionValuesFromProps(t,e,n){return function(t,e,n){const s=Cs(t,e,n);for(const n in t)(En(t[n])||En(e[n]))&&(s[-1!==Ee.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=t[n]);return s}(t,e,n)}build(t,e,n){Ds(t,e,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(t,e,n,s){!function(t,e,n,s){Ss(t,e,void 0,s);for(const n in e.attrs)t.setAttribute(Is.has(n)?n:ts(n),e.attrs[n])}(t,e,0,s)}mount(t){var e;this.isSVGTag="string"==typeof(e=t.tagName)&&"svg"===e.toLowerCase(),super.mount(t)}}function Bs(t){const e={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},n=function(t){return t instanceof SVGElement&&"svg"!==t.tagName}(t)?new Rs(e):new Fs(e);n.mount(t),zn.set(t,n)}function Ns(t){const e=new Ps({presenceContext:null,props:{},visualState:{renderState:{output:{}},latestValues:{}}});e.mount(t),zn.set(t,e)}function Ks(t,e,n,s){const i=[];if(function(t,e){return En(t)||"number"==typeof t||"string"==typeof t&&!In(e)}(t,e))i.push(function(t,e,n){const s=En(t)?t:Pn(t);return s.start(ls("",s,e,n)),s.animation}(t,In(e)&&e.default||e,n&&n.default||n));else{const r=Rn(t,e,s),a=r.length;for(let t=0;t<a;t++){const s=r[t],o=s instanceof Element?Bs:Ns;zn.has(s)||o(s);const l=zn.get(s),u={...n};"delay"in u&&"function"==typeof u.delay&&(u.delay=u.delay(t,a)),i.push(...hs(l,{...e,transition:u},{}))}}return i}function js(t,e,n){const s=[],i=function(t,{defaultTransition:e={},...n}={},s,i){const r=e.duration||.3,a=new Map,o=new Map,l={},h=new Map;let d=0,p=0,m=0;for(let n=0;n<t.length;n++){const a=t[n];if("string"==typeof a){h.set(a,p);continue}if(!Array.isArray(a)){h.set(a.name,Nn(p,a.at,d,h));continue}let[u,f,y={}]=a;void 0!==y.at&&(p=Nn(p,y.at,d,h));let g=0;const v=(t,n,s,a=0,o=0)=>{const l=Ln(t),{delay:u=0,times:h=pe(l),type:d="keyframes",repeat:f,repeatType:y,repeatDelay:v=0,...b}=n;let{ease:w=e.ease||"easeOut",duration:T}=n;const M="function"==typeof u?u(a,o):u,V=l.length,A=Qe(d)?d:i?.[d];if(V<=2&&A){let t=100;if(2===V&&qn(l)){const e=l[1]-l[0];t=Math.abs(e)}const e={...b};void 0!==T&&(e.duration=c(T));const n=Yt(e,t,A);w=n.ease,T=n.duration}T??(T=r);const S=p+M;1===h.length&&0===h[0]&&(h[1]=1);const x=h.length-l.length;if(x>0&&de(h,x),1===l.length&&l.unshift(null),f){T=Bn(T,f);const t=[...l],e=[...h];w=Array.isArray(w)?[...w]:[w];const n=[...w];for(let s=0;s<f;s++){l.push(...t);for(let i=0;i<t.length;i++)h.push(e[i]+(s+1)),w.push(0===i?"linear":F(n,i-1))}jn(h,f)}const k=S+T;Kn(s,l,w,h,S,k),g=Math.max(M+T,g),m=Math.max(k,m)};if(En(u))v(f,y,$n("default",Yn(u,o)));else{const t=Rn(u,f,s,l),e=t.length;for(let n=0;n<e;n++){const s=Yn(t[n],o);for(const t in f)v(f[t],Un(y,t),$n(t,s),n,e)}}d=p,p+=g}return o.forEach(((t,s)=>{for(const i in t){const r=t[i];r.sort(Wn);const o=[],l=[],h=[];for(let t=0;t<r.length;t++){const{at:e,value:n,easing:s}=r[t];o.push(n),l.push(u(0,m,e)),h.push(s||"easeOut")}0!==l[0]&&(l.unshift(0),o.unshift(o[0]),h.unshift("easeInOut")),1!==l[l.length-1]&&(l.push(1),o.push(null)),a.has(s)||a.set(s,{keyframes:{},transition:{}});const c=a.get(s);c.keyframes[i]=o,c.transition[i]={...e,duration:m,ease:h,times:l,...n}}})),a}(t,e,n,{spring:ue});return i.forEach((({keyframes:t,transition:e},n)=>{s.push(...Ks(n,t,e))})),s}function Ws(t){return function(e,n,s){let i=[];var r;r=e,i=Array.isArray(r)&&r.some(Array.isArray)?js(e,n,t):Ks(e,n,s,t);const a=new hn(i);return t&&t.animations.push(a),a}}const Ys=Ws();export{Ys as animate,Ws as createScopedAnimate};
@@ -1 +1 @@
1
- const t=(t,e,r)=>r>e?e:r<t?t:r,e={};function r(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}function s(t){return"string"==typeof t||Array.isArray(t)}const a=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],o=["initial",...a];function n(t){return r(t.animate)||o.some((e=>s(t[e])))}function i(t){return Boolean(n(t)||t.variants)}const c="undefined"!=typeof window,l={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"]},f={};for(const t in l)f[t]={isEnabled:e=>l[t].some((t=>!!e[t]))};const d=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],p={value:null,addProjectionMetrics:null};function u(t,r){let s=!1,a=!0;const o={delta:0,timestamp:0,isProcessing:!1},n=()=>s=!0,i=d.reduce(((t,e)=>(t[e]=function(t,e){let r=new Set,s=new Set,a=!1,o=!1;const n=new WeakSet;let i={delta:0,timestamp:0,isProcessing:!1},c=0;function l(e){n.has(e)&&(f.schedule(e),t()),c++,e(i)}const f={schedule:(t,e=!1,o=!1)=>{const i=o&&a?r:s;return e&&n.add(t),i.has(t)||i.add(t),t},cancel:t=>{s.delete(t),n.delete(t)},process:t=>{i=t,a?o=!0:(a=!0,[r,s]=[s,r],r.forEach(l),e&&p.value&&p.value.frameloop[e].push(c),c=0,r.clear(),a=!1,o&&(o=!1,f.process(t)))}};return f}(n,r?e:void 0),t)),{}),{setup:c,read:l,resolveKeyframes:f,preUpdate:u,update:m,preRender:g,render:h,postRender:y}=i,v=()=>{const n=e.useManualTiming?o.timestamp:performance.now();s=!1,e.useManualTiming||(o.delta=a?1e3/60:Math.max(Math.min(n-o.timestamp,40),1)),o.timestamp=n,o.isProcessing=!0,c.process(o),l.process(o),f.process(o),u.process(o),m.process(o),g.process(o),h.process(o),y.process(o),o.isProcessing=!1,s&&r&&(a=!1,t(v))};return{schedule:d.reduce(((e,r)=>{const n=i[r];return e[r]=(e,r=!1,i=!1)=>(s||(s=!0,a=!0,o.isProcessing||t(v)),n.schedule(e,r,i)),e}),{}),cancel:t=>{for(let e=0;e<d.length;e++)i[d[e]].cancel(t)},state:o,steps:i}}const m=t=>e=>"string"==typeof e&&e.startsWith(t),g=m("--"),h=m("var(--"),y=t=>!!h(t)&&v.test(t.split("/*")[0].trim()),v=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,w={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},x={...w,transform:e=>t(0,1,e)},b={...w,default:1},k=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),P=k("deg"),B=k("%"),R=k("px"),T=k("vh"),X=k("vw"),Y=(()=>({...B,parse:t=>B.parse(t)/100,transform:t=>B.transform(100*t)}))(),O=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],S=(()=>new Set(O))(),W={...w,transform:Math.round},$={borderWidth:R,borderTopWidth:R,borderRightWidth:R,borderBottomWidth:R,borderLeftWidth:R,borderRadius:R,radius:R,borderTopLeftRadius:R,borderTopRightRadius:R,borderBottomRightRadius:R,borderBottomLeftRadius:R,width:R,maxWidth:R,height:R,maxHeight:R,top:R,right:R,bottom:R,left:R,padding:R,paddingTop:R,paddingRight:R,paddingBottom:R,paddingLeft:R,margin:R,marginTop:R,marginRight:R,marginBottom:R,marginLeft:R,backgroundPositionX:R,backgroundPositionY:R,...{rotate:P,rotateX:P,rotateY:P,rotateZ:P,scale:b,scaleX:b,scaleY:b,scaleZ:b,skew:P,skewX:P,skewY:P,distance:R,translateX:R,translateY:R,translateZ:R,x:R,y:R,z:R,perspective:R,transformPerspective:R,opacity:x,originX:Y,originY:Y,originZ:R},zIndex:W,fillOpacity:x,strokeOpacity:x,numOctaves:W},L=(t,e)=>e&&"number"==typeof t?e.transform(t):t,Z=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),V="data-"+Z("framerAppearId"),A={};function E(t,{layout:e,layoutId:r}){return S.has(t)||t.startsWith("origin")||(e||void 0!==r)&&(!!A[t]||"opacity"===t)}const F=t=>Boolean(t&&t.getVelocity),I={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},M=O.length;function z(t,e,r){const{style:s,vars:a,transformOrigin:o}=t;let n=!1,i=!1;for(const t in e){const r=e[t];if(S.has(t))n=!0;else if(g(t))a[t]=r;else{const e=L(r,$[t]);t.startsWith("origin")?(i=!0,o[t]=e):s[t]=e}}if(e.transform||(n||r?s.transform=function(t,e,r){let s="",a=!0;for(let o=0;o<M;o++){const n=O[o],i=t[n];if(void 0===i)continue;let c=!0;if(c="number"==typeof i?i===(n.startsWith("scale")?1:0):0===parseFloat(i),!c||r){const t=L(i,$[n]);c||(a=!1,s+=`${I[n]||n}(${t}) `),r&&(e[n]=t)}}return s=s.trim(),r?s=r(e,a?"":s):a&&(s="none"),s}(e,t.transform,r):s.transform&&(s.transform="none")),i){const{originX:t="50%",originY:e="50%",originZ:r=0}=o;s.transformOrigin=`${t} ${e} ${r}`}}const C=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function H(t){return"string"==typeof t&&!t.includes("-")&&!!(C.indexOf(t)>-1||/[A-Z]/u.test(t))}const D={offset:"stroke-dashoffset",array:"stroke-dasharray"},j={offset:"strokeDashoffset",array:"strokeDasharray"};function U(t,{attrX:e,attrY:r,attrScale:s,pathLength:a,pathSpacing:o=1,pathOffset:n=0,...i},c,l,f){if(z(t,i,l),c)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:d,style:p}=t;d.transform&&(p.transform=d.transform,delete d.transform),(p.transform||d.transformOrigin)&&(p.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),p.transform&&(p.transformBox=f?.transformBox??"fill-box",delete d.transformBox),void 0!==e&&(d.x=e),void 0!==r&&(d.y=r),void 0!==s&&(d.scale=s),void 0!==a&&function(t,e,r=1,s=0,a=!0){t.pathLength=1;const o=a?D:j;t[o.offset]=R.transform(-s);const n=R.transform(e),i=R.transform(r);t[o.array]=`${n} ${i}`}(d,a,o,n,!1)}const K=t=>"string"==typeof t&&"svg"===t.toLowerCase();function q(t){const e=[{},{}];return t?.values.forEach(((t,r)=>{e[0][r]=t.get(),e[1][r]=t.getVelocity()})),e}function G(t,e,r,s){if("function"==typeof e){const[a,o]=q(s);e=e(void 0!==r?r:t.custom,a,o)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[a,o]=q(s);e=e(void 0!==r?r:t.custom,a,o)}return e}function J(t,e,r){const{style:s}=t,a={};for(const o in s)(F(s[o])||e.style&&F(e.style[o])||E(o,t)||void 0!==r?.getValue(o)?.liveStyle)&&(a[o]=s[o]);return a}function N(t,e,r){const s=J(t,e,r);for(const r in t)if(F(t[r])||F(e[r])){s[-1!==O.indexOf(r)?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r]=t[r]}return s}export{T as A,$ as B,S as C,o as D,a as E,g as F,Z as G,e as M,s as a,c as b,u as c,F as d,E as e,f,z as g,U as h,n as i,K as j,H as k,i as l,r as m,N as n,V as o,w as p,x as q,G as r,J as s,t,B as u,y as v,R as w,O as x,P as y,X as z};
1
+ const t=(t,e,r)=>r>e?e:r<t?t:r,e={};function r(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}function s(t){return"string"==typeof t||Array.isArray(t)}const a=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],o=["initial",...a];function n(t){return r(t.animate)||o.some((e=>s(t[e])))}function i(t){return Boolean(n(t)||t.variants)}const c="undefined"!=typeof window,l={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"]},f={};for(const t in l)f[t]={isEnabled:e=>l[t].some((t=>!!e[t]))};const d=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],p={value:null,addProjectionMetrics:null};function u(t,r){let s=!1,a=!0;const o={delta:0,timestamp:0,isProcessing:!1},n=()=>s=!0,i=d.reduce(((t,e)=>(t[e]=function(t,e){let r=new Set,s=new Set,a=!1,o=!1;const n=new WeakSet;let i={delta:0,timestamp:0,isProcessing:!1},c=0;function l(e){n.has(e)&&(f.schedule(e),t()),c++,e(i)}const f={schedule:(t,e=!1,o=!1)=>{const i=o&&a?r:s;return e&&n.add(t),i.has(t)||i.add(t),t},cancel:t=>{s.delete(t),n.delete(t)},process:t=>{i=t,a?o=!0:(a=!0,[r,s]=[s,r],r.forEach(l),e&&p.value&&p.value.frameloop[e].push(c),c=0,r.clear(),a=!1,o&&(o=!1,f.process(t)))}};return f}(n,r?e:void 0),t)),{}),{setup:c,read:l,resolveKeyframes:f,preUpdate:u,update:m,preRender:g,render:h,postRender:y}=i,v=()=>{const n=e.useManualTiming?o.timestamp:performance.now();s=!1,e.useManualTiming||(o.delta=a?1e3/60:Math.max(Math.min(n-o.timestamp,40),1)),o.timestamp=n,o.isProcessing=!0,c.process(o),l.process(o),f.process(o),u.process(o),m.process(o),g.process(o),h.process(o),y.process(o),o.isProcessing=!1,s&&r&&(a=!1,t(v))};return{schedule:d.reduce(((e,r)=>{const n=i[r];return e[r]=(e,r=!1,i=!1)=>(s||(s=!0,a=!0,o.isProcessing||t(v)),n.schedule(e,r,i)),e}),{}),cancel:t=>{for(let e=0;e<d.length;e++)i[d[e]].cancel(t)},state:o,steps:i}}const m=t=>e=>"string"==typeof e&&e.startsWith(t),g=m("--"),h=m("var(--"),y=t=>!!h(t)&&v.test(t.split("/*")[0].trim()),v=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,w={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},x={...w,transform:e=>t(0,1,e)},b={...w,default:1},k=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),P=k("deg"),B=k("%"),R=k("px"),T=k("vh"),X=k("vw"),Y=(()=>({...B,parse:t=>B.parse(t)/100,transform:t=>B.transform(100*t)}))(),O=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],S=(()=>new Set(O))(),W={...w,transform:Math.round},$={borderWidth:R,borderTopWidth:R,borderRightWidth:R,borderBottomWidth:R,borderLeftWidth:R,borderRadius:R,radius:R,borderTopLeftRadius:R,borderTopRightRadius:R,borderBottomRightRadius:R,borderBottomLeftRadius:R,width:R,maxWidth:R,height:R,maxHeight:R,top:R,right:R,bottom:R,left:R,padding:R,paddingTop:R,paddingRight:R,paddingBottom:R,paddingLeft:R,margin:R,marginTop:R,marginRight:R,marginBottom:R,marginLeft:R,backgroundPositionX:R,backgroundPositionY:R,...{rotate:P,rotateX:P,rotateY:P,rotateZ:P,scale:b,scaleX:b,scaleY:b,scaleZ:b,skew:P,skewX:P,skewY:P,distance:R,translateX:R,translateY:R,translateZ:R,x:R,y:R,z:R,perspective:R,transformPerspective:R,opacity:x,originX:Y,originY:Y,originZ:R},zIndex:W,fillOpacity:x,strokeOpacity:x,numOctaves:W},L=(t,e)=>e&&"number"==typeof t?e.transform(t):t,Z=t=>Boolean(t&&t.getVelocity),V=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),A="data-"+V("framerAppearId"),E={};function F(t,{layout:e,layoutId:r}){return S.has(t)||t.startsWith("origin")||(e||void 0!==r)&&(!!E[t]||"opacity"===t)}const I={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},M=O.length;function z(t,e,r){const{style:s,vars:a,transformOrigin:o}=t;let n=!1,i=!1;for(const t in e){const r=e[t];if(S.has(t))n=!0;else if(g(t))a[t]=r;else{const e=L(r,$[t]);t.startsWith("origin")?(i=!0,o[t]=e):s[t]=e}}if(e.transform||(n||r?s.transform=function(t,e,r){let s="",a=!0;for(let o=0;o<M;o++){const n=O[o],i=t[n];if(void 0===i)continue;let c=!0;if(c="number"==typeof i?i===(n.startsWith("scale")?1:0):0===parseFloat(i),!c||r){const t=L(i,$[n]);c||(a=!1,s+=`${I[n]||n}(${t}) `),r&&(e[n]=t)}}return s=s.trim(),r?s=r(e,a?"":s):a&&(s="none"),s}(e,t.transform,r):s.transform&&(s.transform="none")),i){const{originX:t="50%",originY:e="50%",originZ:r=0}=o;s.transformOrigin=`${t} ${e} ${r}`}}const C={offset:"stroke-dashoffset",array:"stroke-dasharray"},H={offset:"strokeDashoffset",array:"strokeDasharray"};function D(t,{attrX:e,attrY:r,attrScale:s,pathLength:a,pathSpacing:o=1,pathOffset:n=0,...i},c,l,f){if(z(t,i,l),c)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:d,style:p}=t;d.transform&&(p.transform=d.transform,delete d.transform),(p.transform||d.transformOrigin)&&(p.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),p.transform&&(p.transformBox=f?.transformBox??"fill-box",delete d.transformBox),void 0!==e&&(d.x=e),void 0!==r&&(d.y=r),void 0!==s&&(d.scale=s),void 0!==a&&function(t,e,r=1,s=0,a=!0){t.pathLength=1;const o=a?C:H;t[o.offset]=R.transform(-s);const n=R.transform(e),i=R.transform(r);t[o.array]=`${n} ${i}`}(d,a,o,n,!1)}const j=t=>"string"==typeof t&&"svg"===t.toLowerCase(),U=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function K(t){return"string"==typeof t&&!t.includes("-")&&!!(U.indexOf(t)>-1||/[A-Z]/u.test(t))}function q(t){const e=[{},{}];return t?.values.forEach(((t,r)=>{e[0][r]=t.get(),e[1][r]=t.getVelocity()})),e}function G(t,e,r,s){if("function"==typeof e){const[a,o]=q(s);e=e(void 0!==r?r:t.custom,a,o)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[a,o]=q(s);e=e(void 0!==r?r:t.custom,a,o)}return e}function J(t,e,r){const{style:s}=t,a={};for(const o in s)(Z(s[o])||e.style&&Z(e.style[o])||F(o,t)||void 0!==r?.getValue(o)?.liveStyle)&&(a[o]=s[o]);return a}function N(t,e,r){const s=J(t,e,r);for(const r in t)if(Z(t[r])||Z(e[r])){s[-1!==O.indexOf(r)?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r]=t[r]}return s}export{T as A,$ as B,S as C,o as D,a as E,g as F,V as G,e as M,s as a,c as b,u as c,Z as d,F as e,f,z as g,D as h,n as i,j,K as k,i as l,r as m,N as n,A as o,w as p,x as q,G as r,J as s,t,B as u,y as v,R as w,O as x,P as y,X as z};
@@ -1 +1 @@
1
- import{jsxs as t,jsx as n}from"react/jsx-runtime";import{createContext as e,useContext as o,useMemo as r,useCallback as a,useLayoutEffect as i,useEffect as s,useRef as u,useInsertionEffect as l,forwardRef as c,Fragment as d,createElement as f}from"react";import{i as m,a as p,f as y,b as g,c as v,P as h,S,o as M,m as b,L as w,d as E,e as j,g as C,h as P,j as V,k as A,r as T,l as L,n as W,p as x,s as I,q as O}from"./size-rollup-dom-max-assets.js";const k=e({strict:!1}),D=e({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),R=e({});function F(t){const{initial:n,animate:e}=function(t,n){if(m(t)){const{initial:n,animate:e}=t;return{initial:!1===n||p(n)?n:void 0,animate:p(e)?e:void 0}}return!1!==t.inherit?n:{}}(t,o(R));return r((()=>({initial:n,animate:e})),[H(n),H(e)])}function H(t){return Array.isArray(t)?t.join(" "):t}const N=Symbol.for("motionComponentSymbol");function q(t,n,e){return a((o=>{o&&t.onMount&&t.onMount(o),n&&(o?n.mount(o):n.unmount()),e&&("function"==typeof e?e(o):g(e)&&(e.current=o))}),[n])}const B=v?i:s;function U(t,n,e,r,a){const{visualElement:i}=o(R),c=o(k),d=o(h),f=o(D).reducedMotion,m=u(null);r=r||c.renderer,!m.current&&r&&(m.current=r(t,{visualState:n,parent:i,props:e,presenceContext:d,blockInitialAnimation:!!d&&!1===d.initial,reducedMotionConfig:f}));const p=m.current,y=o(S);!p||p.projection||!a||"html"!==p.type&&"svg"!==p.type||function(t,n,e,o){const{layoutId:r,layout:a,drag:i,dragConstraints:s,layoutScroll:u,layoutRoot:l,layoutCrossfade:c}=n;t.projection=new e(t.latestValues,n["data-framer-portal-id"]?void 0:$(t.parent)),t.projection.setOptions({layoutId:r,layout:a,alwaysMeasureLayout:Boolean(i)||s&&g(s),visualElement:t,animationType:"string"==typeof a?a:"both",initialPromotionConfig:o,crossfade:c,layoutScroll:u,layoutRoot:l})}(m.current,e,a,y);const v=u(!1);l((()=>{p&&v.current&&p.update(e,d)}));const w=e[M],E=u(Boolean(w)&&!window.MotionHandoffIsComplete?.(w)&&window.MotionHasOptimisedAnimation?.(w));return B((()=>{p&&(v.current=!0,window.MotionIsMounted=!0,p.updateFeatures(),b.render(p.render),E.current&&p.animationState&&p.animationState.animateChanges())})),s((()=>{p&&(!E.current&&p.animationState&&p.animationState.animateChanges(),E.current&&(queueMicrotask((()=>{window.MotionHandoffMarkAsComplete?.(w)})),E.current=!1))})),p}function $(t){if(t)return!1!==t.options.allowProjection?t.projection:$(t.parent)}function _({preloadedFeatures:e,createVisualElement:r,useRender:a,useVisualState:i,Component:s}){function u(e,u){let l;const c={...o(D),...e,layoutId:z(e)},{isStatic:d}=c,f=F(e),m=i(e,d);if(!d&&v){o(k).strict;const t=function(t){const{drag:n,layout:e}=y;if(!n&&!e)return{};const o={...n,...e};return{MeasureLayout:n?.isEnabled(t)||e?.isEnabled(t)?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}(c);l=t.MeasureLayout,f.visualElement=U(s,m,c,r,t.ProjectionNode)}return t(R.Provider,{value:f,children:[l&&f.visualElement?n(l,{visualElement:f.visualElement,...c}):null,a(s,e,q(m,f.visualElement,u),m,d,f.visualElement)]})}e&&function(t){for(const n in t)y[n]={...y[n],...t[n]}}(e),u.displayName=`motion.${"string"==typeof s?s:`create(${s.displayName??s.name??""})`}`;const l=c(u);return l[N]=s,l}function z({layoutId:t}){const n=o(w).id;return n&&void 0!==t?n+"-"+t:t}const X=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Y(t,n,e){for(const o in n)E(n[o])||j(o,e)||(t[o]=n[o])}function G(t,n){const e={};return Y(e,t.style||{},t),Object.assign(e,function({transformTemplate:t},n){return r((()=>{const e={style:{},transform:{},transformOrigin:{},vars:{}};return C(e,n,t),Object.assign({},e.vars,e.style)}),[n])}(t,n)),e}function J(t,n){const e={},o=G(t,n);return t.drag&&!1!==t.dragListener&&(e.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=!0===t.drag?"none":"pan-"+("x"===t.drag?"y":"x")),void 0===t.tabIndex&&(t.onTap||t.onTapStart||t.whileTap)&&(e.tabIndex=0),e.style=o,e}const K=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Q(t){return t.startsWith("while")||t.startsWith("drag")&&"draggable"!==t||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||K.has(t)}let Z=t=>!Q(t);try{(tt=require("@emotion/is-prop-valid").default)&&(Z=t=>t.startsWith("on")?!Q(t):tt(t))}catch{}var tt;const nt=()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}});function et(t,n,e,o){const a=r((()=>{const e={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};return P(e,n,V(o),t.transformTemplate,t.style),{...e.attrs,style:{...e.style}}}),[n]);if(t.style){const n={};Y(n,t.style,t),a.style={...n,...a.style}}return a}function ot(t=!1){return(n,e,o,{latestValues:a},i)=>{const s=(A(n)?et:J)(e,a,i,n),u=function(t,n,e){const o={};for(const r in t)"values"===r&&"object"==typeof t.values||(Z(r)||!0===e&&Q(r)||!n&&!Q(r)||t.draggable&&r.startsWith("onDrag"))&&(o[r]=t[r]);return o}(e,"string"==typeof n,t),l=n!==d?{...u,...s,ref:o}:{},{children:c}=e,m=r((()=>E(c)?c.get():c),[c]);return f(n,{...l,children:m})}}const rt=t=>(n,e)=>{const r=o(R),a=o(h),i=()=>function({scrapeMotionValuesFromProps:t,createRenderState:n},e,o,r){return{latestValues:at(e,o,r,t),renderState:n()}}(t,n,r,a);return e?i():function(t){const n=u(null);return null===n.current&&(n.current=t()),n.current}(i)};function at(t,n,e,o){const r={},a=o(t,{});for(const t in a)r[t]=T(a[t]);let{initial:i,animate:s}=t;const u=m(t),l=L(t);n&&l&&!u&&!1!==t.inherit&&(void 0===i&&(i=n.initial),void 0===s&&(s=n.animate));let c=!!e&&!1===e.initial;c=c||!1===i;const d=c?s:i;if(d&&"boolean"!=typeof d&&!W(d)){const n=Array.isArray(d)?d:[d];for(let e=0;e<n.length;e++){const o=x(t,n[e]);if(o){const{transitionEnd:t,transition:n,...e}=o;for(const t in e){let n=e[t];if(Array.isArray(n)){n=n[c?n.length-1:0]}null!==n&&(r[t]=n)}for(const n in t)r[n]=t[n]}}}return r}const it={useVisualState:rt({scrapeMotionValuesFromProps:I,createRenderState:X})},st={useVisualState:rt({scrapeMotionValuesFromProps:O,createRenderState:nt})};function ut(t,n){return function(e,{forwardMotionProps:o}={forwardMotionProps:!1}){return _({...A(e)?st:it,preloadedFeatures:t,useRender:ot(o),createVisualElement:n,Component:e})}}const lt=ut()("div");export{lt as MotionDiv};
1
+ import{jsxs as t,jsx as n}from"react/jsx-runtime";import{createContext as e,useContext as o,useMemo as r,useCallback as a,useLayoutEffect as i,useEffect as s,useRef as u,useInsertionEffect as l,forwardRef as c,Fragment as d,createElement as f}from"react";import{i as m,a as p,f as y,b as g,c as v,P as h,S,o as M,m as b,L as w,d as E,e as j,g as C,h as P,j as V,k as A,r as T,l as L,n as W,p as x,s as I,q as O}from"./size-rollup-dom-max-assets.js";const k=e({strict:!1}),D=e({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),R=e({});function F(t){const{initial:n,animate:e}=function(t,n){if(m(t)){const{initial:n,animate:e}=t;return{initial:!1===n||p(n)?n:void 0,animate:p(e)?e:void 0}}return!1!==t.inherit?n:{}}(t,o(R));return r((()=>({initial:n,animate:e})),[H(n),H(e)])}function H(t){return Array.isArray(t)?t.join(" "):t}const N=Symbol.for("motionComponentSymbol");function q(t,n,e){return a((o=>{o&&t.onMount&&t.onMount(o),n&&(o?n.mount(o):n.unmount()),e&&("function"==typeof e?e(o):g(e)&&(e.current=o))}),[n])}const B=v?i:s;function U(t,n,e,r,a){const{visualElement:i}=o(R),c=o(k),d=o(h),f=o(D).reducedMotion,m=u(null);r=r||c.renderer,!m.current&&r&&(m.current=r(t,{visualState:n,parent:i,props:e,presenceContext:d,blockInitialAnimation:!!d&&!1===d.initial,reducedMotionConfig:f}));const p=m.current,y=o(S);!p||p.projection||!a||"html"!==p.type&&"svg"!==p.type||function(t,n,e,o){const{layoutId:r,layout:a,drag:i,dragConstraints:s,layoutScroll:u,layoutRoot:l,layoutCrossfade:c}=n;t.projection=new e(t.latestValues,n["data-framer-portal-id"]?void 0:$(t.parent)),t.projection.setOptions({layoutId:r,layout:a,alwaysMeasureLayout:Boolean(i)||s&&g(s),visualElement:t,animationType:"string"==typeof a?a:"both",initialPromotionConfig:o,crossfade:c,layoutScroll:u,layoutRoot:l})}(m.current,e,a,y);const v=u(!1);l((()=>{p&&v.current&&p.update(e,d)}));const w=e[M],E=u(Boolean(w)&&!window.MotionHandoffIsComplete?.(w)&&window.MotionHasOptimisedAnimation?.(w));return B((()=>{p&&(v.current=!0,window.MotionIsMounted=!0,p.updateFeatures(),b.render(p.render),E.current&&p.animationState&&p.animationState.animateChanges())})),s((()=>{p&&(!E.current&&p.animationState&&p.animationState.animateChanges(),E.current&&(queueMicrotask((()=>{window.MotionHandoffMarkAsComplete?.(w)})),E.current=!1))})),p}function $(t){if(t)return!1!==t.options.allowProjection?t.projection:$(t.parent)}function _({preloadedFeatures:e,createVisualElement:r,useRender:a,useVisualState:i,Component:s}){function u(e,u){let l;const c={...o(D),...e,layoutId:z(e)},{isStatic:d}=c,f=F(e),m=i(e,d);if(!d&&v){o(k).strict;const t=function(t){const{drag:n,layout:e}=y;if(!n&&!e)return{};const o={...n,...e};return{MeasureLayout:n?.isEnabled(t)||e?.isEnabled(t)?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}(c);l=t.MeasureLayout,f.visualElement=U(s,m,c,r,t.ProjectionNode)}return t(R.Provider,{value:f,children:[l&&f.visualElement?n(l,{visualElement:f.visualElement,...c}):null,a(s,e,q(m,f.visualElement,u),m,d,f.visualElement)]})}e&&function(t){for(const n in t)y[n]={...y[n],...t[n]}}(e),u.displayName=`motion.${"string"==typeof s?s:`create(${s.displayName??s.name??""})`}`;const l=c(u);return l[N]=s,l}function z({layoutId:t}){const n=o(w).id;return n&&void 0!==t?n+"-"+t:t}const X=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Y(t,n,e){for(const o in n)E(n[o])||j(o,e)||(t[o]=n[o])}function G(t,n){const e={};return Y(e,t.style||{},t),Object.assign(e,function({transformTemplate:t},n){return r((()=>{const e={style:{},transform:{},transformOrigin:{},vars:{}};return C(e,n,t),Object.assign({},e.vars,e.style)}),[n])}(t,n)),e}function J(t,n){const e={},o=G(t,n);return t.drag&&!1!==t.dragListener&&(e.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=!0===t.drag?"none":"pan-"+("x"===t.drag?"y":"x")),void 0===t.tabIndex&&(t.onTap||t.onTapStart||t.whileTap)&&(e.tabIndex=0),e.style=o,e}const K=()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}});function Q(t,n,e,o){const a=r((()=>{const e={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};return P(e,n,V(o),t.transformTemplate,t.style),{...e.attrs,style:{...e.style}}}),[n]);if(t.style){const n={};Y(n,t.style,t),a.style={...n,...a.style}}return a}const Z=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function tt(t){return t.startsWith("while")||t.startsWith("drag")&&"draggable"!==t||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||Z.has(t)}let nt=t=>!tt(t);try{(et=require("@emotion/is-prop-valid").default)&&(nt=t=>t.startsWith("on")?!tt(t):et(t))}catch{}var et;function ot(t=!1){return(n,e,o,{latestValues:a},i)=>{const s=(A(n)?Q:J)(e,a,i,n),u=function(t,n,e){const o={};for(const r in t)"values"===r&&"object"==typeof t.values||(nt(r)||!0===e&&tt(r)||!n&&!tt(r)||t.draggable&&r.startsWith("onDrag"))&&(o[r]=t[r]);return o}(e,"string"==typeof n,t),l=n!==d?{...u,...s,ref:o}:{},{children:c}=e,m=r((()=>E(c)?c.get():c),[c]);return f(n,{...l,children:m})}}const rt=t=>(n,e)=>{const r=o(R),a=o(h),i=()=>function({scrapeMotionValuesFromProps:t,createRenderState:n},e,o,r){return{latestValues:at(e,o,r,t),renderState:n()}}(t,n,r,a);return e?i():function(t){const n=u(null);return null===n.current&&(n.current=t()),n.current}(i)};function at(t,n,e,o){const r={},a=o(t,{});for(const t in a)r[t]=T(a[t]);let{initial:i,animate:s}=t;const u=m(t),l=L(t);n&&l&&!u&&!1!==t.inherit&&(void 0===i&&(i=n.initial),void 0===s&&(s=n.animate));let c=!!e&&!1===e.initial;c=c||!1===i;const d=c?s:i;if(d&&"boolean"!=typeof d&&!W(d)){const n=Array.isArray(d)?d:[d];for(let e=0;e<n.length;e++){const o=x(t,n[e]);if(o){const{transitionEnd:t,transition:n,...e}=o;for(const t in e){let n=e[t];if(Array.isArray(n)){n=n[c?n.length-1:0]}null!==n&&(r[t]=n)}for(const n in t)r[n]=t[n]}}}return r}const it={useVisualState:rt({scrapeMotionValuesFromProps:I,createRenderState:X})},st={useVisualState:rt({scrapeMotionValuesFromProps:O,createRenderState:K})};function ut(t,n){return function(e,{forwardMotionProps:o}={forwardMotionProps:!1}){return _({...A(e)?st:it,preloadedFeatures:t,useRender:ot(o),createVisualElement:n,Component:e})}}const lt=ut()("div");export{lt as MotionDiv};
@@ -1 +1 @@
1
- import{createContext as t}from"react";const e=(t,e,r)=>r>e?e:r<t?t:r,r={},s=t({});function a(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}function o(t){return"string"==typeof t||Array.isArray(t)}const n=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],i=["initial",...n];function c(t){return a(t.animate)||i.some((e=>o(t[e])))}function l(t){return Boolean(c(t)||t.variants)}const f="undefined"!=typeof window,p={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"]},d={};for(const t in p)d[t]={isEnabled:e=>p[t].some((t=>!!e[t]))};function u(t){return t&&"object"==typeof t&&Object.prototype.hasOwnProperty.call(t,"current")}const m=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],g={value:null,addProjectionMetrics:null};function h(t,e){let s=!1,a=!0;const o={delta:0,timestamp:0,isProcessing:!1},n=()=>s=!0,i=m.reduce(((t,r)=>(t[r]=function(t,e){let r=new Set,s=new Set,a=!1,o=!1;const n=new WeakSet;let i={delta:0,timestamp:0,isProcessing:!1},c=0;function l(e){n.has(e)&&(f.schedule(e),t()),c++,e(i)}const f={schedule:(t,e=!1,o=!1)=>{const i=o&&a?r:s;return e&&n.add(t),i.has(t)||i.add(t),t},cancel:t=>{s.delete(t),n.delete(t)},process:t=>{i=t,a?o=!0:(a=!0,[r,s]=[s,r],r.forEach(l),e&&g.value&&g.value.frameloop[e].push(c),c=0,r.clear(),a=!1,o&&(o=!1,f.process(t)))}};return f}(n,e?r:void 0),t)),{}),{setup:c,read:l,resolveKeyframes:f,preUpdate:p,update:d,preRender:u,render:h,postRender:y}=i,v=()=>{const n=r.useManualTiming?o.timestamp:performance.now();s=!1,r.useManualTiming||(o.delta=a?1e3/60:Math.max(Math.min(n-o.timestamp,40),1)),o.timestamp=n,o.isProcessing=!0,c.process(o),l.process(o),f.process(o),p.process(o),d.process(o),u.process(o),h.process(o),y.process(o),o.isProcessing=!1,s&&e&&(a=!1,t(v))};return{schedule:m.reduce(((e,r)=>{const n=i[r];return e[r]=(e,r=!1,i=!1)=>(s||(s=!0,a=!0,o.isProcessing||t(v)),n.schedule(e,r,i)),e}),{}),cancel:t=>{for(let e=0;e<m.length;e++)i[m[e]].cancel(t)},state:o,steps:i}}const y=t=>e=>"string"==typeof e&&e.startsWith(t),v=y("--"),w=y("var(--"),b=t=>!!w(t)&&x.test(t.split("/*")[0].trim()),x=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,k={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},P={...k,transform:t=>e(0,1,t)},S={...k,default:1},B=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),O=B("deg"),R=B("%"),T=B("px"),X=B("vh"),Y=B("vw"),W=(()=>({...R,parse:t=>R.parse(t)/100,transform:t=>R.transform(100*t)}))(),$=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],L=(()=>new Set($))(),V={...k,transform:Math.round},Z={borderWidth:T,borderTopWidth:T,borderRightWidth:T,borderBottomWidth:T,borderLeftWidth:T,borderRadius:T,radius:T,borderTopLeftRadius:T,borderTopRightRadius:T,borderBottomRightRadius:T,borderBottomLeftRadius:T,width:T,maxWidth:T,height:T,maxHeight:T,top:T,right:T,bottom:T,left:T,padding:T,paddingTop:T,paddingRight:T,paddingBottom:T,paddingLeft:T,margin:T,marginTop:T,marginRight:T,marginBottom:T,marginLeft:T,backgroundPositionX:T,backgroundPositionY:T,...{rotate:O,rotateX:O,rotateY:O,rotateZ:O,scale:S,scaleX:S,scaleY:S,scaleZ:S,skew:O,skewX:O,skewY:O,distance:T,translateX:T,translateY:T,translateZ:T,x:T,y:T,z:T,perspective:T,transformPerspective:T,opacity:P,originX:W,originY:W,originZ:T},zIndex:V,fillOpacity:P,strokeOpacity:P,numOctaves:V},I=(t,e)=>e&&"number"==typeof t?e.transform(t):t,{schedule:M,cancel:A}=h(queueMicrotask,!1),C=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),E="data-"+C("framerAppearId"),F=t(null),H=t({}),z={};function j(t){for(const e in t)z[e]=t[e],v(e)&&(z[e].isCSSVariable=!0)}function D(t,{layout:e,layoutId:r}){return L.has(t)||t.startsWith("origin")||(e||void 0!==r)&&(!!z[t]||"opacity"===t)}const K=t=>Boolean(t&&t.getVelocity),U={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},q=$.length;function G(t,e,r){const{style:s,vars:a,transformOrigin:o}=t;let n=!1,i=!1;for(const t in e){const r=e[t];if(L.has(t))n=!0;else if(v(t))a[t]=r;else{const e=I(r,Z[t]);t.startsWith("origin")?(i=!0,o[t]=e):s[t]=e}}if(e.transform||(n||r?s.transform=function(t,e,r){let s="",a=!0;for(let o=0;o<q;o++){const n=$[o],i=t[n];if(void 0===i)continue;let c=!0;if(c="number"==typeof i?i===(n.startsWith("scale")?1:0):0===parseFloat(i),!c||r){const t=I(i,Z[n]);c||(a=!1,s+=`${U[n]||n}(${t}) `),r&&(e[n]=t)}}return s=s.trim(),r?s=r(e,a?"":s):a&&(s="none"),s}(e,t.transform,r):s.transform&&(s.transform="none")),i){const{originX:t="50%",originY:e="50%",originZ:r=0}=o;s.transformOrigin=`${t} ${e} ${r}`}}const J=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function N(t){return"string"==typeof t&&!t.includes("-")&&!!(J.indexOf(t)>-1||/[A-Z]/u.test(t))}const Q={offset:"stroke-dashoffset",array:"stroke-dasharray"},_={offset:"strokeDashoffset",array:"strokeDasharray"};function tt(t,{attrX:e,attrY:r,attrScale:s,pathLength:a,pathSpacing:o=1,pathOffset:n=0,...i},c,l,f){if(G(t,i,l),c)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:p,style:d}=t;p.transform&&(d.transform=p.transform,delete p.transform),(d.transform||p.transformOrigin)&&(d.transformOrigin=p.transformOrigin??"50% 50%",delete p.transformOrigin),d.transform&&(d.transformBox=f?.transformBox??"fill-box",delete p.transformBox),void 0!==e&&(p.x=e),void 0!==r&&(p.y=r),void 0!==s&&(p.scale=s),void 0!==a&&function(t,e,r=1,s=0,a=!0){t.pathLength=1;const o=a?Q:_;t[o.offset]=T.transform(-s);const n=T.transform(e),i=T.transform(r);t[o.array]=`${n} ${i}`}(p,a,o,n,!1)}const et=t=>"string"==typeof t&&"svg"===t.toLowerCase();function rt(t){const e=[{},{}];return t?.values.forEach(((t,r)=>{e[0][r]=t.get(),e[1][r]=t.getVelocity()})),e}function st(t,e,r,s){if("function"==typeof e){const[a,o]=rt(s);e=e(void 0!==r?r:t.custom,a,o)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[a,o]=rt(s);e=e(void 0!==r?r:t.custom,a,o)}return e}function at(t){return K(t)?t.get():t}function ot(t,e,r){const{style:s}=t,a={};for(const o in s)(K(s[o])||e.style&&K(e.style[o])||D(o,t)||void 0!==r?.getValue(o)?.liveStyle)&&(a[o]=s[o]);return a}function nt(t,e,r){const s=ot(t,e,r);for(const r in t)if(K(t[r])||K(e[r])){s[-1!==$.indexOf(r)?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r]=t[r]}return s}export{$ as A,O as B,Y as C,X as D,Z as E,L as F,z as G,v as H,j as I,i as J,n as K,s as L,r as M,C as N,F as P,H as S,o as a,u as b,f as c,K as d,D as e,d as f,G as g,tt as h,c as i,et as j,N as k,l,M as m,a as n,E as o,st as p,nt as q,at as r,ot as s,h as t,k as u,P as v,e as w,R as x,b as y,T as z};
1
+ import{createContext as t}from"react";const e=(t,e,r)=>r>e?e:r<t?t:r,r={},s=t({});function a(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}function o(t){return"string"==typeof t||Array.isArray(t)}const n=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],i=["initial",...n];function c(t){return a(t.animate)||i.some((e=>o(t[e])))}function l(t){return Boolean(c(t)||t.variants)}const f="undefined"!=typeof window,p={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"]},d={};for(const t in p)d[t]={isEnabled:e=>p[t].some((t=>!!e[t]))};function u(t){return t&&"object"==typeof t&&Object.prototype.hasOwnProperty.call(t,"current")}const m=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],g={value:null,addProjectionMetrics:null};function h(t,e){let s=!1,a=!0;const o={delta:0,timestamp:0,isProcessing:!1},n=()=>s=!0,i=m.reduce(((t,r)=>(t[r]=function(t,e){let r=new Set,s=new Set,a=!1,o=!1;const n=new WeakSet;let i={delta:0,timestamp:0,isProcessing:!1},c=0;function l(e){n.has(e)&&(f.schedule(e),t()),c++,e(i)}const f={schedule:(t,e=!1,o=!1)=>{const i=o&&a?r:s;return e&&n.add(t),i.has(t)||i.add(t),t},cancel:t=>{s.delete(t),n.delete(t)},process:t=>{i=t,a?o=!0:(a=!0,[r,s]=[s,r],r.forEach(l),e&&g.value&&g.value.frameloop[e].push(c),c=0,r.clear(),a=!1,o&&(o=!1,f.process(t)))}};return f}(n,e?r:void 0),t)),{}),{setup:c,read:l,resolveKeyframes:f,preUpdate:p,update:d,preRender:u,render:h,postRender:y}=i,v=()=>{const n=r.useManualTiming?o.timestamp:performance.now();s=!1,r.useManualTiming||(o.delta=a?1e3/60:Math.max(Math.min(n-o.timestamp,40),1)),o.timestamp=n,o.isProcessing=!0,c.process(o),l.process(o),f.process(o),p.process(o),d.process(o),u.process(o),h.process(o),y.process(o),o.isProcessing=!1,s&&e&&(a=!1,t(v))};return{schedule:m.reduce(((e,r)=>{const n=i[r];return e[r]=(e,r=!1,i=!1)=>(s||(s=!0,a=!0,o.isProcessing||t(v)),n.schedule(e,r,i)),e}),{}),cancel:t=>{for(let e=0;e<m.length;e++)i[m[e]].cancel(t)},state:o,steps:i}}const y=t=>e=>"string"==typeof e&&e.startsWith(t),v=y("--"),w=y("var(--"),b=t=>!!w(t)&&x.test(t.split("/*")[0].trim()),x=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,k={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},P={...k,transform:t=>e(0,1,t)},S={...k,default:1},B=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),O=B("deg"),R=B("%"),T=B("px"),X=B("vh"),Y=B("vw"),W=(()=>({...R,parse:t=>R.parse(t)/100,transform:t=>R.transform(100*t)}))(),$=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],L=(()=>new Set($))(),V={...k,transform:Math.round},Z={borderWidth:T,borderTopWidth:T,borderRightWidth:T,borderBottomWidth:T,borderLeftWidth:T,borderRadius:T,radius:T,borderTopLeftRadius:T,borderTopRightRadius:T,borderBottomRightRadius:T,borderBottomLeftRadius:T,width:T,maxWidth:T,height:T,maxHeight:T,top:T,right:T,bottom:T,left:T,padding:T,paddingTop:T,paddingRight:T,paddingBottom:T,paddingLeft:T,margin:T,marginTop:T,marginRight:T,marginBottom:T,marginLeft:T,backgroundPositionX:T,backgroundPositionY:T,...{rotate:O,rotateX:O,rotateY:O,rotateZ:O,scale:S,scaleX:S,scaleY:S,scaleZ:S,skew:O,skewX:O,skewY:O,distance:T,translateX:T,translateY:T,translateZ:T,x:T,y:T,z:T,perspective:T,transformPerspective:T,opacity:P,originX:W,originY:W,originZ:T},zIndex:V,fillOpacity:P,strokeOpacity:P,numOctaves:V},I=(t,e)=>e&&"number"==typeof t?e.transform(t):t,{schedule:M,cancel:A}=h(queueMicrotask,!1),C=t=>Boolean(t&&t.getVelocity),E=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),F="data-"+E("framerAppearId"),H=t(null),z=t({}),j={};function D(t){for(const e in t)j[e]=t[e],v(e)&&(j[e].isCSSVariable=!0)}function K(t,{layout:e,layoutId:r}){return L.has(t)||t.startsWith("origin")||(e||void 0!==r)&&(!!j[t]||"opacity"===t)}const U={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},q=$.length;function G(t,e,r){const{style:s,vars:a,transformOrigin:o}=t;let n=!1,i=!1;for(const t in e){const r=e[t];if(L.has(t))n=!0;else if(v(t))a[t]=r;else{const e=I(r,Z[t]);t.startsWith("origin")?(i=!0,o[t]=e):s[t]=e}}if(e.transform||(n||r?s.transform=function(t,e,r){let s="",a=!0;for(let o=0;o<q;o++){const n=$[o],i=t[n];if(void 0===i)continue;let c=!0;if(c="number"==typeof i?i===(n.startsWith("scale")?1:0):0===parseFloat(i),!c||r){const t=I(i,Z[n]);c||(a=!1,s+=`${U[n]||n}(${t}) `),r&&(e[n]=t)}}return s=s.trim(),r?s=r(e,a?"":s):a&&(s="none"),s}(e,t.transform,r):s.transform&&(s.transform="none")),i){const{originX:t="50%",originY:e="50%",originZ:r=0}=o;s.transformOrigin=`${t} ${e} ${r}`}}const J={offset:"stroke-dashoffset",array:"stroke-dasharray"},N={offset:"strokeDashoffset",array:"strokeDasharray"};function Q(t,{attrX:e,attrY:r,attrScale:s,pathLength:a,pathSpacing:o=1,pathOffset:n=0,...i},c,l,f){if(G(t,i,l),c)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:p,style:d}=t;p.transform&&(d.transform=p.transform,delete p.transform),(d.transform||p.transformOrigin)&&(d.transformOrigin=p.transformOrigin??"50% 50%",delete p.transformOrigin),d.transform&&(d.transformBox=f?.transformBox??"fill-box",delete p.transformBox),void 0!==e&&(p.x=e),void 0!==r&&(p.y=r),void 0!==s&&(p.scale=s),void 0!==a&&function(t,e,r=1,s=0,a=!0){t.pathLength=1;const o=a?J:N;t[o.offset]=T.transform(-s);const n=T.transform(e),i=T.transform(r);t[o.array]=`${n} ${i}`}(p,a,o,n,!1)}const _=t=>"string"==typeof t&&"svg"===t.toLowerCase(),tt=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function et(t){return"string"==typeof t&&!t.includes("-")&&!!(tt.indexOf(t)>-1||/[A-Z]/u.test(t))}function rt(t){const e=[{},{}];return t?.values.forEach(((t,r)=>{e[0][r]=t.get(),e[1][r]=t.getVelocity()})),e}function st(t,e,r,s){if("function"==typeof e){const[a,o]=rt(s);e=e(void 0!==r?r:t.custom,a,o)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[a,o]=rt(s);e=e(void 0!==r?r:t.custom,a,o)}return e}function at(t){return C(t)?t.get():t}function ot(t,e,r){const{style:s}=t,a={};for(const o in s)(C(s[o])||e.style&&C(e.style[o])||K(o,t)||void 0!==r?.getValue(o)?.liveStyle)&&(a[o]=s[o]);return a}function nt(t,e,r){const s=ot(t,e,r);for(const r in t)if(C(t[r])||C(e[r])){s[-1!==$.indexOf(r)?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r]=t[r]}return s}export{$ as A,O as B,Y as C,X as D,Z as E,L as F,j as G,v as H,D as I,i as J,n as K,s as L,r as M,E as N,H as P,z as S,o as a,u as b,f as c,C as d,K as e,d as f,G as g,Q as h,c as i,_ as j,et as k,l,M as m,a as n,F as o,st as p,nt as q,at as r,ot as s,h as t,k as u,P as v,e as w,R as x,b as y,T as z};
@@ -1 +1 @@
1
- import{jsxs as t,jsx as e}from"react/jsx-runtime";import{createContext as n,useContext as r,useMemo as o,useCallback as a,useLayoutEffect as s,useEffect as i,useRef as c,useInsertionEffect as l,forwardRef as u,Fragment as f,createElement as d}from"react";const p={},m=n({}),g=n({strict:!1}),y=n({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),h=n({});function v(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}function w(t){return"string"==typeof t||Array.isArray(t)}const b=["initial","animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"];function S(t){return v(t.animate)||b.some((e=>w(t[e])))}function x(t){const{initial:e,animate:n}=function(t,e){if(S(t)){const{initial:e,animate:n}=t;return{initial:!1===e||w(e)?e:void 0,animate:w(n)?n:void 0}}return!1!==t.inherit?e:{}}(t,r(h));return o((()=>({initial:e,animate:n})),[M(e),M(n)])}function M(t){return Array.isArray(t)?t.join(" "):t}const P="undefined"!=typeof window,T={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"]},k={};for(const t in T)k[t]={isEnabled:e=>T[t].some((t=>!!e[t]))};const E=Symbol.for("motionComponentSymbol");function O(t){return t&&"object"==typeof t&&Object.prototype.hasOwnProperty.call(t,"current")}function V(t,e,n){return a((r=>{r&&t.onMount&&t.onMount(r),e&&(r?e.mount(r):e.unmount()),n&&("function"==typeof n?n(r):O(n)&&(n.current=r))}),[e])}const W=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],R={value:null,addProjectionMetrics:null};function C(t,e){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},a=()=>n=!0,s=W.reduce(((t,n)=>(t[n]=function(t,e){let n=new Set,r=new Set,o=!1,a=!1;const s=new WeakSet;let i={delta:0,timestamp:0,isProcessing:!1},c=0;function l(e){s.has(e)&&(u.schedule(e),t()),c++,e(i)}const u={schedule:(t,e=!1,a=!1)=>{const i=a&&o?n:r;return e&&s.add(t),i.has(t)||i.add(t),t},cancel:t=>{r.delete(t),s.delete(t)},process:t=>{i=t,o?a=!0:(o=!0,[n,r]=[r,n],n.forEach(l),e&&R.value&&R.value.frameloop[e].push(c),c=0,n.clear(),o=!1,a&&(a=!1,u.process(t)))}};return u}(a,e?n:void 0),t)),{}),{setup:i,read:c,resolveKeyframes:l,preUpdate:u,update:f,preRender:d,render:m,postRender:g}=s,y=()=>{const a=p.useManualTiming?o.timestamp:performance.now();n=!1,p.useManualTiming||(o.delta=r?1e3/60:Math.max(Math.min(a-o.timestamp,40),1)),o.timestamp=a,o.isProcessing=!0,i.process(o),c.process(o),l.process(o),u.process(o),f.process(o),d.process(o),m.process(o),g.process(o),o.isProcessing=!1,n&&e&&(r=!1,t(y))};return{schedule:W.reduce(((e,a)=>{const i=s[a];return e[a]=(e,a=!1,s=!1)=>(n||(n=!0,r=!0,o.isProcessing||t(y)),i.schedule(e,a,s)),e}),{}),cancel:t=>{for(let e=0;e<W.length;e++)s[W[e]].cancel(t)},state:o,steps:s}}const L=(t=>e=>"string"==typeof e&&e.startsWith(t))("--"),A={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},j={...A,transform:t=>((t,e,n)=>n>e?e:n<t?t:n)(0,1,t)},B={...A,default:1},I=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),X=I("deg"),Y=I("%"),$=I("px"),F=(()=>({...Y,parse:t=>Y.parse(t)/100,transform:t=>Y.transform(100*t)}))(),D=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],H=(()=>new Set(D))(),Z={...A,transform:Math.round},z={borderWidth:$,borderTopWidth:$,borderRightWidth:$,borderBottomWidth:$,borderLeftWidth:$,borderRadius:$,radius:$,borderTopLeftRadius:$,borderTopRightRadius:$,borderBottomRightRadius:$,borderBottomLeftRadius:$,width:$,maxWidth:$,height:$,maxHeight:$,top:$,right:$,bottom:$,left:$,padding:$,paddingTop:$,paddingRight:$,paddingBottom:$,paddingLeft:$,margin:$,marginTop:$,marginRight:$,marginBottom:$,marginLeft:$,backgroundPositionX:$,backgroundPositionY:$,...{rotate:X,rotateX:X,rotateY:X,rotateZ:X,scale:B,scaleX:B,scaleY:B,scaleZ:B,skew:X,skewX:X,skewY:X,distance:$,translateX:$,translateY:$,translateZ:$,x:$,y:$,z:$,perspective:$,transformPerspective:$,opacity:j,originX:F,originY:F,originZ:$},zIndex:Z,fillOpacity:j,strokeOpacity:j,numOctaves:Z},N=(t,e)=>e&&"number"==typeof t?e.transform(t):t,{schedule:U,cancel:q}=C(queueMicrotask,!1),K="data-"+"framerAppearId".replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase();const _=n(null),G=n({}),J=P?s:i;function Q(t,e,n,o,a){const{visualElement:s}=r(h),u=r(g),f=r(_),d=r(y).reducedMotion,p=c(null);o=o||u.renderer,!p.current&&o&&(p.current=o(t,{visualState:e,parent:s,props:n,presenceContext:f,blockInitialAnimation:!!f&&!1===f.initial,reducedMotionConfig:d}));const m=p.current,v=r(G);!m||m.projection||!a||"html"!==m.type&&"svg"!==m.type||function(t,e,n,r){const{layoutId:o,layout:a,drag:s,dragConstraints:i,layoutScroll:c,layoutRoot:l,layoutCrossfade:u}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:tt(t.parent)),t.projection.setOptions({layoutId:o,layout:a,alwaysMeasureLayout:Boolean(s)||i&&O(i),visualElement:t,animationType:"string"==typeof a?a:"both",initialPromotionConfig:r,crossfade:u,layoutScroll:c,layoutRoot:l})}(p.current,n,a,v);const w=c(!1);l((()=>{m&&w.current&&m.update(n,f)}));const b=n[K],S=c(Boolean(b)&&!window.MotionHandoffIsComplete?.(b)&&window.MotionHasOptimisedAnimation?.(b));return J((()=>{m&&(w.current=!0,window.MotionIsMounted=!0,m.updateFeatures(),U.render(m.render),S.current&&m.animationState&&m.animationState.animateChanges())})),i((()=>{m&&(!S.current&&m.animationState&&m.animationState.animateChanges(),S.current&&(queueMicrotask((()=>{window.MotionHandoffMarkAsComplete?.(b)})),S.current=!1))})),m}function tt(t){if(t)return!1!==t.options.allowProjection?t.projection:tt(t.parent)}function et({preloadedFeatures:n,createVisualElement:o,useRender:a,useVisualState:s,Component:i}){function c(n,c){let l;const u={...r(y),...n,layoutId:nt(n)},{isStatic:f}=u,d=x(n),p=s(n,f);if(!f&&P){r(g).strict;const t=function(t){const{drag:e,layout:n}=k;if(!e&&!n)return{};const r={...e,...n};return{MeasureLayout:e?.isEnabled(t)||n?.isEnabled(t)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(u);l=t.MeasureLayout,d.visualElement=Q(i,p,u,o,t.ProjectionNode)}return t(h.Provider,{value:d,children:[l&&d.visualElement?e(l,{visualElement:d.visualElement,...u}):null,a(i,n,V(p,d.visualElement,c),p,f,d.visualElement)]})}n&&function(t){for(const e in t)k[e]={...k[e],...t[e]}}(n),c.displayName=`motion.${"string"==typeof i?i:`create(${i.displayName??i.name??""})`}`;const l=u(c);return l[E]=i,l}function nt({layoutId:t}){const e=r(m).id;return e&&void 0!==t?e+"-"+t:t}const rt={};function ot(t,{layout:e,layoutId:n}){return H.has(t)||t.startsWith("origin")||(e||void 0!==n)&&(!!rt[t]||"opacity"===t)}const at=t=>Boolean(t&&t.getVelocity),st={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},it=D.length;function ct(t,e,n){const{style:r,vars:o,transformOrigin:a}=t;let s=!1,i=!1;for(const t in e){const n=e[t];if(H.has(t))s=!0;else if(L(t))o[t]=n;else{const e=N(n,z[t]);t.startsWith("origin")?(i=!0,a[t]=e):r[t]=e}}if(e.transform||(s||n?r.transform=function(t,e,n){let r="",o=!0;for(let a=0;a<it;a++){const s=D[a],i=t[s];if(void 0===i)continue;let c=!0;if(c="number"==typeof i?i===(s.startsWith("scale")?1:0):0===parseFloat(i),!c||n){const t=N(i,z[s]);c||(o=!1,r+=`${st[s]||s}(${t}) `),n&&(e[s]=t)}}return r=r.trim(),n?r=n(e,o?"":r):o&&(r="none"),r}(e,t.transform,n):r.transform&&(r.transform="none")),i){const{originX:t="50%",originY:e="50%",originZ:n=0}=a;r.transformOrigin=`${t} ${e} ${n}`}}const lt=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function ut(t,e,n){for(const r in e)at(e[r])||ot(r,n)||(t[r]=e[r])}function ft(t,e){const n={};return ut(n,t.style||{},t),Object.assign(n,function({transformTemplate:t},e){return o((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{}};return ct(n,e,t),Object.assign({},n.vars,n.style)}),[e])}(t,e)),n}function dt(t,e){const n={},r=ft(t,e);return t.drag&&!1!==t.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===t.drag?"none":"pan-"+("x"===t.drag?"y":"x")),void 0===t.tabIndex&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=r,n}const pt=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function mt(t){return t.startsWith("while")||t.startsWith("drag")&&"draggable"!==t||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||pt.has(t)}let gt=t=>!mt(t);try{(yt=require("@emotion/is-prop-valid").default)&&(gt=t=>t.startsWith("on")?!mt(t):yt(t))}catch{}var yt;const ht=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function vt(t){return"string"==typeof t&&!t.includes("-")&&!!(ht.indexOf(t)>-1||/[A-Z]/u.test(t))}const wt={offset:"stroke-dashoffset",array:"stroke-dasharray"},bt={offset:"strokeDashoffset",array:"strokeDasharray"};function St(t,{attrX:e,attrY:n,attrScale:r,pathLength:o,pathSpacing:a=1,pathOffset:s=0,...i},c,l,u){if(ct(t,i,l),c)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:f,style:d}=t;f.transform&&(d.transform=f.transform,delete f.transform),(d.transform||f.transformOrigin)&&(d.transformOrigin=f.transformOrigin??"50% 50%",delete f.transformOrigin),d.transform&&(d.transformBox=u?.transformBox??"fill-box",delete f.transformBox),void 0!==e&&(f.x=e),void 0!==n&&(f.y=n),void 0!==r&&(f.scale=r),void 0!==o&&function(t,e,n=1,r=0,o=!0){t.pathLength=1;const a=o?wt:bt;t[a.offset]=$.transform(-r);const s=$.transform(e),i=$.transform(n);t[a.array]=`${s} ${i}`}(f,o,a,s,!1)}const xt=()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}});function Mt(t,e,n,r){const a=o((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};var o;return St(n,e,"string"==typeof(o=r)&&"svg"===o.toLowerCase(),t.transformTemplate,t.style),{...n.attrs,style:{...n.style}}}),[e]);if(t.style){const e={};ut(e,t.style,t),a.style={...e,...a.style}}return a}function Pt(t=!1){return(e,n,r,{latestValues:a},s)=>{const i=(vt(e)?Mt:dt)(n,a,s,e),c=function(t,e,n){const r={};for(const o in t)"values"===o&&"object"==typeof t.values||(gt(o)||!0===n&&mt(o)||!e&&!mt(o)||t.draggable&&o.startsWith("onDrag"))&&(r[o]=t[o]);return r}(n,"string"==typeof e,t),l=e!==f?{...c,...i,ref:r}:{},{children:u}=n,p=o((()=>at(u)?u.get():u),[u]);return d(e,{...l,children:p})}}function Tt(t){const e=[{},{}];return t?.values.forEach(((t,n)=>{e[0][n]=t.get(),e[1][n]=t.getVelocity()})),e}function kt(t,e,n,r){if("function"==typeof e){const[o,a]=Tt(r);e=e(void 0!==n?n:t.custom,o,a)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[o,a]=Tt(r);e=e(void 0!==n?n:t.custom,o,a)}return e}const Et=t=>(e,n)=>{const o=r(h),a=r(_),s=()=>function({scrapeMotionValuesFromProps:t,createRenderState:e},n,r,o){return{latestValues:Ot(n,r,o,t),renderState:e()}}(t,e,o,a);return n?s():function(t){const e=c(null);return null===e.current&&(e.current=t()),e.current}(s)};function Ot(t,e,n,r){const o={},a=r(t,{});for(const t in a)o[t]=(s=a[t],at(s)?s.get():s);var s;let{initial:i,animate:c}=t;const l=S(t),u=function(t){return Boolean(S(t)||t.variants)}(t);e&&u&&!l&&!1!==t.inherit&&(void 0===i&&(i=e.initial),void 0===c&&(c=e.animate));let f=!!n&&!1===n.initial;f=f||!1===i;const d=f?c:i;if(d&&"boolean"!=typeof d&&!v(d)){const e=Array.isArray(d)?d:[d];for(let n=0;n<e.length;n++){const r=kt(t,e[n]);if(r){const{transitionEnd:t,transition:e,...n}=r;for(const t in n){let e=n[t];if(Array.isArray(e)){e=e[f?e.length-1:0]}null!==e&&(o[t]=e)}for(const e in t)o[e]=t[e]}}}return o}function Vt(t,e,n){const{style:r}=t,o={};for(const a in r)(at(r[a])||e.style&&at(e.style[a])||ot(a,t)||void 0!==n?.getValue(a)?.liveStyle)&&(o[a]=r[a]);return o}const Wt={useVisualState:Et({scrapeMotionValuesFromProps:Vt,createRenderState:lt})};const Rt={useVisualState:Et({scrapeMotionValuesFromProps:function(t,e,n){const r=Vt(t,e,n);for(const n in t)if(at(t[n])||at(e[n])){r[-1!==D.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=t[n]}return r},createRenderState:xt})};function Ct(t,e){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){return et({...vt(n)?Rt:Wt,preloadedFeatures:t,useRender:Pt(r),createVisualElement:e,Component:n})}}const Lt=Ct()("div");export{Lt as MotionDiv};
1
+ import{jsxs as t,jsx as e}from"react/jsx-runtime";import{createContext as n,useContext as r,useMemo as o,useCallback as a,useLayoutEffect as s,useEffect as i,useRef as c,useInsertionEffect as l,forwardRef as u,Fragment as f,createElement as d}from"react";const p={},m=n({}),g=n({strict:!1}),y=n({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),h=n({});function v(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}function w(t){return"string"==typeof t||Array.isArray(t)}const b=["initial","animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"];function S(t){return v(t.animate)||b.some((e=>w(t[e])))}function x(t){const{initial:e,animate:n}=function(t,e){if(S(t)){const{initial:e,animate:n}=t;return{initial:!1===e||w(e)?e:void 0,animate:w(n)?n:void 0}}return!1!==t.inherit?e:{}}(t,r(h));return o((()=>({initial:e,animate:n})),[M(e),M(n)])}function M(t){return Array.isArray(t)?t.join(" "):t}const P="undefined"!=typeof window,T={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"]},k={};for(const t in T)k[t]={isEnabled:e=>T[t].some((t=>!!e[t]))};const E=Symbol.for("motionComponentSymbol");function O(t){return t&&"object"==typeof t&&Object.prototype.hasOwnProperty.call(t,"current")}function V(t,e,n){return a((r=>{r&&t.onMount&&t.onMount(r),e&&(r?e.mount(r):e.unmount()),n&&("function"==typeof n?n(r):O(n)&&(n.current=r))}),[e])}const W=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],R={value:null,addProjectionMetrics:null};function C(t,e){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},a=()=>n=!0,s=W.reduce(((t,n)=>(t[n]=function(t,e){let n=new Set,r=new Set,o=!1,a=!1;const s=new WeakSet;let i={delta:0,timestamp:0,isProcessing:!1},c=0;function l(e){s.has(e)&&(u.schedule(e),t()),c++,e(i)}const u={schedule:(t,e=!1,a=!1)=>{const i=a&&o?n:r;return e&&s.add(t),i.has(t)||i.add(t),t},cancel:t=>{r.delete(t),s.delete(t)},process:t=>{i=t,o?a=!0:(o=!0,[n,r]=[r,n],n.forEach(l),e&&R.value&&R.value.frameloop[e].push(c),c=0,n.clear(),o=!1,a&&(a=!1,u.process(t)))}};return u}(a,e?n:void 0),t)),{}),{setup:i,read:c,resolveKeyframes:l,preUpdate:u,update:f,preRender:d,render:m,postRender:g}=s,y=()=>{const a=p.useManualTiming?o.timestamp:performance.now();n=!1,p.useManualTiming||(o.delta=r?1e3/60:Math.max(Math.min(a-o.timestamp,40),1)),o.timestamp=a,o.isProcessing=!0,i.process(o),c.process(o),l.process(o),u.process(o),f.process(o),d.process(o),m.process(o),g.process(o),o.isProcessing=!1,n&&e&&(r=!1,t(y))};return{schedule:W.reduce(((e,a)=>{const i=s[a];return e[a]=(e,a=!1,s=!1)=>(n||(n=!0,r=!0,o.isProcessing||t(y)),i.schedule(e,a,s)),e}),{}),cancel:t=>{for(let e=0;e<W.length;e++)s[W[e]].cancel(t)},state:o,steps:s}}const L=(t=>e=>"string"==typeof e&&e.startsWith(t))("--"),A={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},j={...A,transform:t=>((t,e,n)=>n>e?e:n<t?t:n)(0,1,t)},B={...A,default:1},I=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),X=I("deg"),Y=I("%"),$=I("px"),F=(()=>({...Y,parse:t=>Y.parse(t)/100,transform:t=>Y.transform(100*t)}))(),D=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],H=(()=>new Set(D))(),Z={...A,transform:Math.round},z={borderWidth:$,borderTopWidth:$,borderRightWidth:$,borderBottomWidth:$,borderLeftWidth:$,borderRadius:$,radius:$,borderTopLeftRadius:$,borderTopRightRadius:$,borderBottomRightRadius:$,borderBottomLeftRadius:$,width:$,maxWidth:$,height:$,maxHeight:$,top:$,right:$,bottom:$,left:$,padding:$,paddingTop:$,paddingRight:$,paddingBottom:$,paddingLeft:$,margin:$,marginTop:$,marginRight:$,marginBottom:$,marginLeft:$,backgroundPositionX:$,backgroundPositionY:$,...{rotate:X,rotateX:X,rotateY:X,rotateZ:X,scale:B,scaleX:B,scaleY:B,scaleZ:B,skew:X,skewX:X,skewY:X,distance:$,translateX:$,translateY:$,translateZ:$,x:$,y:$,z:$,perspective:$,transformPerspective:$,opacity:j,originX:F,originY:F,originZ:$},zIndex:Z,fillOpacity:j,strokeOpacity:j,numOctaves:Z},N=(t,e)=>e&&"number"==typeof t?e.transform(t):t,{schedule:U,cancel:q}=C(queueMicrotask,!1),K=t=>Boolean(t&&t.getVelocity),_="data-"+"framerAppearId".replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase();const G=n(null),J=n({}),Q=P?s:i;function tt(t,e,n,o,a){const{visualElement:s}=r(h),u=r(g),f=r(G),d=r(y).reducedMotion,p=c(null);o=o||u.renderer,!p.current&&o&&(p.current=o(t,{visualState:e,parent:s,props:n,presenceContext:f,blockInitialAnimation:!!f&&!1===f.initial,reducedMotionConfig:d}));const m=p.current,v=r(J);!m||m.projection||!a||"html"!==m.type&&"svg"!==m.type||function(t,e,n,r){const{layoutId:o,layout:a,drag:s,dragConstraints:i,layoutScroll:c,layoutRoot:l,layoutCrossfade:u}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:et(t.parent)),t.projection.setOptions({layoutId:o,layout:a,alwaysMeasureLayout:Boolean(s)||i&&O(i),visualElement:t,animationType:"string"==typeof a?a:"both",initialPromotionConfig:r,crossfade:u,layoutScroll:c,layoutRoot:l})}(p.current,n,a,v);const w=c(!1);l((()=>{m&&w.current&&m.update(n,f)}));const b=n[_],S=c(Boolean(b)&&!window.MotionHandoffIsComplete?.(b)&&window.MotionHasOptimisedAnimation?.(b));return Q((()=>{m&&(w.current=!0,window.MotionIsMounted=!0,m.updateFeatures(),U.render(m.render),S.current&&m.animationState&&m.animationState.animateChanges())})),i((()=>{m&&(!S.current&&m.animationState&&m.animationState.animateChanges(),S.current&&(queueMicrotask((()=>{window.MotionHandoffMarkAsComplete?.(b)})),S.current=!1))})),m}function et(t){if(t)return!1!==t.options.allowProjection?t.projection:et(t.parent)}function nt({preloadedFeatures:n,createVisualElement:o,useRender:a,useVisualState:s,Component:i}){function c(n,c){let l;const u={...r(y),...n,layoutId:rt(n)},{isStatic:f}=u,d=x(n),p=s(n,f);if(!f&&P){r(g).strict;const t=function(t){const{drag:e,layout:n}=k;if(!e&&!n)return{};const r={...e,...n};return{MeasureLayout:e?.isEnabled(t)||n?.isEnabled(t)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(u);l=t.MeasureLayout,d.visualElement=tt(i,p,u,o,t.ProjectionNode)}return t(h.Provider,{value:d,children:[l&&d.visualElement?e(l,{visualElement:d.visualElement,...u}):null,a(i,n,V(p,d.visualElement,c),p,f,d.visualElement)]})}n&&function(t){for(const e in t)k[e]={...k[e],...t[e]}}(n),c.displayName=`motion.${"string"==typeof i?i:`create(${i.displayName??i.name??""})`}`;const l=u(c);return l[E]=i,l}function rt({layoutId:t}){const e=r(m).id;return e&&void 0!==t?e+"-"+t:t}const ot={};function at(t,{layout:e,layoutId:n}){return H.has(t)||t.startsWith("origin")||(e||void 0!==n)&&(!!ot[t]||"opacity"===t)}const st={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},it=D.length;function ct(t,e,n){const{style:r,vars:o,transformOrigin:a}=t;let s=!1,i=!1;for(const t in e){const n=e[t];if(H.has(t))s=!0;else if(L(t))o[t]=n;else{const e=N(n,z[t]);t.startsWith("origin")?(i=!0,a[t]=e):r[t]=e}}if(e.transform||(s||n?r.transform=function(t,e,n){let r="",o=!0;for(let a=0;a<it;a++){const s=D[a],i=t[s];if(void 0===i)continue;let c=!0;if(c="number"==typeof i?i===(s.startsWith("scale")?1:0):0===parseFloat(i),!c||n){const t=N(i,z[s]);c||(o=!1,r+=`${st[s]||s}(${t}) `),n&&(e[s]=t)}}return r=r.trim(),n?r=n(e,o?"":r):o&&(r="none"),r}(e,t.transform,n):r.transform&&(r.transform="none")),i){const{originX:t="50%",originY:e="50%",originZ:n=0}=a;r.transformOrigin=`${t} ${e} ${n}`}}const lt=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function ut(t,e,n){for(const r in e)K(e[r])||at(r,n)||(t[r]=e[r])}function ft(t,e){const n={};return ut(n,t.style||{},t),Object.assign(n,function({transformTemplate:t},e){return o((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{}};return ct(n,e,t),Object.assign({},n.vars,n.style)}),[e])}(t,e)),n}function dt(t,e){const n={},r=ft(t,e);return t.drag&&!1!==t.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===t.drag?"none":"pan-"+("x"===t.drag?"y":"x")),void 0===t.tabIndex&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=r,n}const pt={offset:"stroke-dashoffset",array:"stroke-dasharray"},mt={offset:"strokeDashoffset",array:"strokeDasharray"};function gt(t,{attrX:e,attrY:n,attrScale:r,pathLength:o,pathSpacing:a=1,pathOffset:s=0,...i},c,l,u){if(ct(t,i,l),c)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:f,style:d}=t;f.transform&&(d.transform=f.transform,delete f.transform),(d.transform||f.transformOrigin)&&(d.transformOrigin=f.transformOrigin??"50% 50%",delete f.transformOrigin),d.transform&&(d.transformBox=u?.transformBox??"fill-box",delete f.transformBox),void 0!==e&&(f.x=e),void 0!==n&&(f.y=n),void 0!==r&&(f.scale=r),void 0!==o&&function(t,e,n=1,r=0,o=!0){t.pathLength=1;const a=o?pt:mt;t[a.offset]=$.transform(-r);const s=$.transform(e),i=$.transform(n);t[a.array]=`${s} ${i}`}(f,o,a,s,!1)}const yt=()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}});function ht(t,e,n,r){const a=o((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};var o;return gt(n,e,"string"==typeof(o=r)&&"svg"===o.toLowerCase(),t.transformTemplate,t.style),{...n.attrs,style:{...n.style}}}),[e]);if(t.style){const e={};ut(e,t.style,t),a.style={...e,...a.style}}return a}const vt=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function wt(t){return t.startsWith("while")||t.startsWith("drag")&&"draggable"!==t||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||vt.has(t)}let bt=t=>!wt(t);try{(St=require("@emotion/is-prop-valid").default)&&(bt=t=>t.startsWith("on")?!wt(t):St(t))}catch{}var St;const xt=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Mt(t){return"string"==typeof t&&!t.includes("-")&&!!(xt.indexOf(t)>-1||/[A-Z]/u.test(t))}function Pt(t=!1){return(e,n,r,{latestValues:a},s)=>{const i=(Mt(e)?ht:dt)(n,a,s,e),c=function(t,e,n){const r={};for(const o in t)"values"===o&&"object"==typeof t.values||(bt(o)||!0===n&&wt(o)||!e&&!wt(o)||t.draggable&&o.startsWith("onDrag"))&&(r[o]=t[o]);return r}(n,"string"==typeof e,t),l=e!==f?{...c,...i,ref:r}:{},{children:u}=n,p=o((()=>K(u)?u.get():u),[u]);return d(e,{...l,children:p})}}function Tt(t){const e=[{},{}];return t?.values.forEach(((t,n)=>{e[0][n]=t.get(),e[1][n]=t.getVelocity()})),e}function kt(t,e,n,r){if("function"==typeof e){const[o,a]=Tt(r);e=e(void 0!==n?n:t.custom,o,a)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[o,a]=Tt(r);e=e(void 0!==n?n:t.custom,o,a)}return e}const Et=t=>(e,n)=>{const o=r(h),a=r(G),s=()=>function({scrapeMotionValuesFromProps:t,createRenderState:e},n,r,o){return{latestValues:Ot(n,r,o,t),renderState:e()}}(t,e,o,a);return n?s():function(t){const e=c(null);return null===e.current&&(e.current=t()),e.current}(s)};function Ot(t,e,n,r){const o={},a=r(t,{});for(const t in a)o[t]=(s=a[t],K(s)?s.get():s);var s;let{initial:i,animate:c}=t;const l=S(t),u=function(t){return Boolean(S(t)||t.variants)}(t);e&&u&&!l&&!1!==t.inherit&&(void 0===i&&(i=e.initial),void 0===c&&(c=e.animate));let f=!!n&&!1===n.initial;f=f||!1===i;const d=f?c:i;if(d&&"boolean"!=typeof d&&!v(d)){const e=Array.isArray(d)?d:[d];for(let n=0;n<e.length;n++){const r=kt(t,e[n]);if(r){const{transitionEnd:t,transition:e,...n}=r;for(const t in n){let e=n[t];if(Array.isArray(e)){e=e[f?e.length-1:0]}null!==e&&(o[t]=e)}for(const e in t)o[e]=t[e]}}}return o}function Vt(t,e,n){const{style:r}=t,o={};for(const a in r)(K(r[a])||e.style&&K(e.style[a])||at(a,t)||void 0!==n?.getValue(a)?.liveStyle)&&(o[a]=r[a]);return o}const Wt={useVisualState:Et({scrapeMotionValuesFromProps:Vt,createRenderState:lt})};const Rt={useVisualState:Et({scrapeMotionValuesFromProps:function(t,e,n){const r=Vt(t,e,n);for(const n in t)if(K(t[n])||K(e[n])){r[-1!==D.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=t[n]}return r},createRenderState:yt})};function Ct(t,e){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){return nt({...Mt(n)?Rt:Wt,preloadedFeatures:t,useRender:Pt(r),createVisualElement:e,Component:n})}}const Lt=Ct()("div");export{Lt as MotionDiv};