@vueuse/motion
Advanced tools
Comparing version 1.3.7 to 1.4.0
/*! | ||
* @vueuse/motion v1.3.6 | ||
* @vueuse/motion v1.4.0 | ||
* (c) 2021 | ||
* @license MIT | ||
*/ | ||
var VueuseMotion=function(t,e,r,n,i){"use strict";const a={};var o=1/60*1e3,s="undefined"!=typeof performance?function(){return performance.now()}:function(){return Date.now()},l="undefined"!=typeof window?function(t){return window.requestAnimationFrame(t)}:function(t){return setTimeout((function(){return t(s())}),o)};var u=!0,c=!1,p=!1,d={delta:0,timestamp:0},f=["read","update","preRender","render","postRender"],v=f.reduce((function(t,e){return t[e]=function(t){var e=[],r=[],n=0,i=!1,a=new WeakSet,o={schedule:function(t,o,s){void 0===o&&(o=!1),void 0===s&&(s=!1);var l=s&&i,u=l?e:r;return o&&a.add(t),-1===u.indexOf(t)&&(u.push(t),l&&i&&(n=e.length)),t},cancel:function(t){var e=r.indexOf(t);-1!==e&&r.splice(e,1),a.delete(t)},process:function(s){var l;if(i=!0,e=(l=[r,e])[0],(r=l[1]).length=0,n=e.length)for(var u=0;u<n;u++){var c=e[u];c(s),a.has(c)&&(o.schedule(c),t())}i=!1}};return o}((function(){return c=!0})),t}),{}),m=f.reduce((function(t,e){var r=v[e];return t[e]=function(t,e,n){return void 0===e&&(e=!1),void 0===n&&(n=!1),c||b(),r.schedule(t,e,n)},t}),{}),y=function(t){return v[t].process(d)},h=function(t){c=!1,d.delta=u?o:Math.max(Math.min(t-d.timestamp,40),1),d.timestamp=t,p=!0,f.forEach(y),p=!1,c&&(u=!1,l(h))},b=function(){c=!0,u=!0,p||l(h)};class g{constructor(){this.subscriptions=new Set}add(t){return this.subscriptions.add(t),()=>{this.subscriptions.delete(t)}}notify(t,e,r){if(this.subscriptions.size)for(const n of this.subscriptions)n(t,e,r)}clear(){this.subscriptions.clear()}}const w=t=>!isNaN(parseFloat(t));class O{constructor(t){this.timeDelta=0,this.lastUpdated=0,this.updateSubscribers=new g,this.canTrackVelocity=!1,this.updateAndNotify=t=>{this.prev=this.current,this.current=t;const{delta:e,timestamp:r}=d;this.lastUpdated!==r&&(this.timeDelta=e,this.lastUpdated=r),m.postRender(this.scheduleVelocityCheck),this.updateSubscribers.notify(this.current)},this.scheduleVelocityCheck=()=>m.postRender(this.velocityCheck),this.velocityCheck=({timestamp:t})=>{this.canTrackVelocity||(this.canTrackVelocity=w(this.current)),t!==this.lastUpdated&&(this.prev=this.current)},this.prev=this.current=t,this.canTrackVelocity=w(this.current)}onChange(t){return this.updateSubscribers.add(t)}clearListeners(){this.updateSubscribers.clear()}set(t){this.updateAndNotify(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?i.velocityPerSecond(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}start(t){return this.stop(),new Promise((e=>{const{stop:r}=t(e);this.stopAnimation=r})).then((()=>this.clearAnimation()))}stop(){this.stopAnimation&&this.stopAnimation(),this.clearAnimation()}isAnimating(){return!!this.stopAnimation}clearAnimation(){this.stopAnimation=null}destroy(){this.updateSubscribers.clear(),this.stop()}}const{isArray:k}=Array;function x(){const t={},r=r=>{const n=r=>{t[r]&&(t[r].stop(),t[r].destroy(),e.del(t,r))};r?k(r)?r.forEach(n):n(r):Object.keys(t).forEach(n)};return n.tryOnUnmounted(r),{motionValues:t,get:(r,n,i)=>{if(t[r])return t[r];const a=new O(n);return a.onChange((t=>{e.set(i,r,t)})),e.set(t,r,a),a},stop:r}} | ||
var VueuseMotion=function(e,t,n,o,r){"use strict";const s={};var i=1/60*1e3,a="undefined"!=typeof performance?function(){return performance.now()}:function(){return Date.now()},c="undefined"!=typeof window?function(e){return window.requestAnimationFrame(e)}:function(e){return setTimeout((function(){return e(a())}),i)};var l=!0,u=!1,p=!1,f={delta:0,timestamp:0},d=["read","update","preRender","render","postRender"],h=d.reduce((function(e,t){return e[t]=function(e){var t=[],n=[],o=0,r=!1,s=new WeakSet,i={schedule:function(e,i,a){void 0===i&&(i=!1),void 0===a&&(a=!1);var c=a&&r,l=c?t:n;return i&&s.add(e),-1===l.indexOf(e)&&(l.push(e),c&&r&&(o=t.length)),e},cancel:function(e){var t=n.indexOf(e);-1!==t&&n.splice(t,1),s.delete(e)},process:function(a){var c;if(r=!0,t=(c=[n,t])[0],(n=c[1]).length=0,o=t.length)for(var l=0;l<o;l++){var u=t[l];u(a),s.has(u)&&(i.schedule(u),e())}r=!1}};return i}((function(){return u=!0})),e}),{}),v=d.reduce((function(e,t){var n=h[t];return e[t]=function(e,t,o){return void 0===t&&(t=!1),void 0===o&&(o=!1),u||g(),n.schedule(e,t,o)},e}),{}),y=function(e){return h[e].process(f)},m=function(e){u=!1,f.delta=l?i:Math.max(Math.min(e-f.timestamp,40),1),f.timestamp=e,p=!0,d.forEach(y),p=!1,u&&(l=!1,c(m))},g=function(){u=!0,l=!0,p||c(m)};class b{constructor(){this.subscriptions=new Set}add(e){return this.subscriptions.add(e),()=>{this.subscriptions.delete(e)}}notify(e,t,n){if(this.subscriptions.size)for(const o of this.subscriptions)o(e,t,n)}clear(){this.subscriptions.clear()}}const _=e=>!isNaN(parseFloat(e));class w{constructor(e){this.timeDelta=0,this.lastUpdated=0,this.updateSubscribers=new b,this.canTrackVelocity=!1,this.updateAndNotify=e=>{this.prev=this.current,this.current=e;const{delta:t,timestamp:n}=f;this.lastUpdated!==n&&(this.timeDelta=t,this.lastUpdated=n),v.postRender(this.scheduleVelocityCheck),this.updateSubscribers.notify(this.current)},this.scheduleVelocityCheck=()=>v.postRender(this.velocityCheck),this.velocityCheck=({timestamp:e})=>{this.canTrackVelocity||(this.canTrackVelocity=_(this.current)),e!==this.lastUpdated&&(this.prev=this.current)},this.prev=this.current=e,this.canTrackVelocity=_(this.current)}onChange(e){return this.updateSubscribers.add(e)}clearListeners(){this.updateSubscribers.clear()}set(e){this.updateAndNotify(e)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?r.velocityPerSecond(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}start(e){return this.stop(),new Promise((t=>{const{stop:n}=e(t);this.stopAnimation=n})).then((()=>this.clearAnimation()))}stop(){this.stopAnimation&&this.stopAnimation(),this.clearAnimation()}isAnimating(){return!!this.stopAnimation}clearAnimation(){this.stopAnimation=null}destroy(){this.updateSubscribers.clear(),this.stop()}}const{isArray:E}=Array;function N(){const e={},n=n=>{const o=n=>{e[n]&&(e[n].stop(),e[n].destroy(),t.del(e,n))};n?E(n)?n.forEach(o):o(n):Object.keys(e).forEach(o)};return o.tryOnUnmounted(n),{motionValues:e,get:(n,o,r)=>{if(e[n])return e[n];const s=new w(o);return s.onChange((e=>{t.set(r,n,e)})),t.set(e,n,s),s},stop:n}} | ||
/*! ***************************************************************************** | ||
@@ -20,2 +20,2 @@ Copyright (c) Microsoft Corporation. | ||
PERFORMANCE OF THIS SOFTWARE. | ||
***************************************************************************** */var V=function(){return(V=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++)for(var i in e=arguments[r])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)},A=function(t,e){return function(r){return Math.max(Math.min(r,e),t)}},T=function(t){return t%1?Number(t.toFixed(5)):t},L=/(-)?([\d]*\.?[\d])+/g,j=/(#[0-9a-f]{6}|#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2,3}\s*\/*\s*[\d\.]+%?\))/gi,C=/^(#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2,3}\s*\/*\s*[\d\.]+%?\))$/i;function I(t){return"string"==typeof t}var R={test:function(t){return"number"==typeof t},parse:parseFloat,transform:function(t){return t}},E=V(V({},R),{transform:A(0,1)}),M=V(V({},R),{default:1}),P=function(t){return{test:function(e){return I(e)&&e.endsWith(t)&&1===e.split(" ").length},parse:parseFloat,transform:function(e){return""+e+t}}},z=P("deg"),S=P("%"),B=P("px"),F=V(V({},S),{parse:function(t){return S.parse(t)/100},transform:function(t){return S.transform(100*t)}}),N=function(t,e){return function(r){return I(r)&&C.test(r)&&r.startsWith(t)||e&&Object.prototype.hasOwnProperty.call(r,e)}},U=function(t,e,r){return function(n){var i;if(!I(n))return n;var a=n.match(L),o=a[1],s=a[2],l=a[3];return(i={})[t]=parseFloat(a[0]),i[e]=parseFloat(o),i[r]=parseFloat(s),i.alpha=void 0!==l?parseFloat(l):1,i}},W={test:N("hsl","hue"),parse:U("hue","saturation","lightness"),transform:function(t){var e=t.saturation,r=t.lightness,n=t.alpha,i=void 0===n?1:n;return"hsla("+Math.round(t.hue)+", "+S.transform(T(e))+", "+S.transform(T(r))+", "+T(E.transform(i))+")"}},$=A(0,255),D=V(V({},R),{transform:function(t){return Math.round($(t))}}),X={test:N("rgb","red"),parse:U("red","green","blue"),transform:function(t){var e=t.green,r=t.blue,n=t.alpha,i=void 0===n?1:n;return"rgba("+D.transform(t.red)+", "+D.transform(e)+", "+D.transform(r)+", "+T(E.transform(i))+")"}};var Y={test:N("#"),parse:function(t){var e="",r="",n="",i="";return t.length>5?(e=t.substr(1,2),r=t.substr(3,2),n=t.substr(5,2),i=t.substr(7,2)):(e=t.substr(1,1),r=t.substr(2,1),n=t.substr(3,1),i=t.substr(4,1),e+=e,r+=r,n+=n,i+=i),{red:parseInt(e,16),green:parseInt(r,16),blue:parseInt(n,16),alpha:i?parseInt(i,16)/255:1}},transform:X.transform},Z={test:function(t){return X.test(t)||Y.test(t)||W.test(t)},parse:function(t){return X.test(t)?X.parse(t):W.test(t)?W.parse(t):Y.parse(t)},transform:function(t){return I(t)?t:t.hasOwnProperty("red")?X.transform(t):W.transform(t)}},_="${c}",H="${n}";function q(t){var e=[],r=0,n=t.match(j);n&&(r=n.length,t=t.replace(j,_),e.push.apply(e,n.map(Z.parse)));var i=t.match(L);return i&&(t=t.replace(L,H),e.push.apply(e,i.map(R.parse))),{values:e,numColors:r,tokenised:t}}function G(t){return q(t).values}function J(t){var e=q(t),r=e.numColors,n=e.tokenised,i=e.values.length;return function(t){for(var e=n,a=0;a<i;a++)e=e.replace(a<r?_:H,a<r?Z.transform(t[a]):T(t[a]));return e}}var K=function(t){return"number"==typeof t?0:t};var Q={test:function(t){var e,r,n,i;return isNaN(t)&&I(t)&&(null!==(r=null===(e=t.match(L))||void 0===e?void 0:e.length)&&void 0!==r?r:0)+(null!==(i=null===(n=t.match(j))||void 0===n?void 0:n.length)&&void 0!==i?i:0)>0},parse:G,createTransformer:J,getAnimatableNone:function(t){var e=G(t);return J(t)(e.map(K))}},tt=new Set(["brightness","contrast","saturate","opacity"]);function et(t){var e=t.slice(0,-1).split("("),r=e[0],n=e[1];if("drop-shadow"===r)return t;var i=(n.match(L)||[])[0];if(!i)return t;var a=n.replace(i,""),o=tt.has(r)?1:0;return i!==n&&(o*=100),r+"("+o+a+")"}var rt=/([a-z-]*)\(.*?\)/g,nt=V(V({},Q),{getAnimatableNone:function(t){var e=t.match(rt);return e?e.map(et).join(" "):t}});const it=()=>({type:"spring",stiffness:500,damping:25,restDelta:.5,restSpeed:10}),at=t=>({type:"spring",stiffness:550,damping:0===t?100:30,restDelta:.01,restSpeed:10}),ot=()=>({type:"keyframes",ease:"linear",duration:300}),st=t=>({type:"keyframes",duration:800,values:t}),lt={default:at,x:it,y:it,z:it,rotate:it,rotateX:it,rotateY:it,rotateZ:it,scaleX:at,scaleY:at,scale:at,backgroundColor:ot,color:ot,opacity:ot},ut=(t,e)=>{let r;return r=Array.isArray(e)?st:lt[t]||lt.default,{to:e,...r(e)}},ct={...R,transform:Math.round},pt={color:Z,backgroundColor:Z,outlineColor:Z,fill:Z,stroke:Z,borderColor:Z,borderTopColor:Z,borderRightColor:Z,borderBottomColor:Z,borderLeftColor:Z,borderWidth:B,borderTopWidth:B,borderRightWidth:B,borderBottomWidth:B,borderLeftWidth:B,borderRadius:B,radius:B,borderTopLeftRadius:B,borderTopRightRadius:B,borderBottomRightRadius:B,borderBottomLeftRadius:B,width:B,maxWidth:B,height:B,maxHeight:B,size:B,top:B,right:B,bottom:B,left:B,padding:B,paddingTop:B,paddingRight:B,paddingBottom:B,paddingLeft:B,margin:B,marginTop:B,marginRight:B,marginBottom:B,marginLeft:B,rotate:z,rotateX:z,rotateY:z,rotateZ:z,scale:M,scaleX:M,scaleY:M,scaleZ:M,skew:z,skewX:z,skewY:z,distance:B,translateX:B,translateY:B,translateZ:B,x:B,y:B,z:B,perspective:B,transformPerspective:B,opacity:E,originX:F,originY:F,originZ:B,zIndex:ct,filter:nt,WebkitFilter:nt,fillOpacity:E,strokeOpacity:E,numOctaves:ct},dt=t=>pt[t],ft=(t,e)=>e&&"number"==typeof t&&e.transform?e.transform(t):t;const vt={linear:i.linear,easeIn:i.easeIn,easeInOut:i.easeInOut,easeOut:i.easeOut,circIn:i.circIn,circInOut:i.circInOut,circOut:i.circOut,backIn:i.backIn,backInOut:i.backInOut,backOut:i.backOut,anticipate:i.anticipate,bounceIn:i.bounceIn,bounceInOut:i.bounceInOut,bounceOut:i.bounceOut},mt=t=>{if(Array.isArray(t)){const[e,r,n,a]=t;return i.cubicBezier(e,r,n,a)}return"string"==typeof t?vt[t]:t},yt=(t,e)=>"zIndex"!==t&&(!("number"!=typeof e&&!Array.isArray(e))||!("string"!=typeof e||!Q.test(e)||e.startsWith("url(")));function ht({ease:t,times:e,delay:r,...n}){const i={...n};return e&&(i.offset=e),t&&(i.ease=(t=>Array.isArray(t)&&"number"!=typeof t[0])(t)?t.map(mt):mt(t)),r&&(i.elapsed=-r),i}function bt(t,e,r){return Array.isArray(e.to)&&(t.duration||(t.duration=800)),function(t){Array.isArray(t.to)&&null===t.to[0]&&(t.to=[...t.to],t.to[0]=t.from)}(e),function({delay:t,repeat:e,repeatType:r,repeatDelay:n,from:i,...a}){return!!Object.keys(a).length}(t)||(t={...t,...ut(r,e.to)}),{...e,...ht(t)}}function gt(t,e,r,n,a){const o=function(t,e){return t[e]||t.default||t}(n,t);let s=null==o.from?e.get():o.from;const l=yt(t,r);"none"===s&&l&&"string"==typeof r&&(s=function(t,e){let r=dt(t);return r!==nt&&(r=Q),r.getAnimatableNone?r.getAnimatableNone(e):void 0}(t,r));return yt(t,s)&&l&&!1!==o.type?function(l){const u={from:s,to:r,velocity:n.velocity?n.velocity:e.getVelocity(),onUpdate:t=>e.set(t)};return"inertia"===o.type||"decay"===o.type?i.inertia({...u,...o}):i.animate({...bt(o,u,t),onUpdate:t=>{u.onUpdate(t),o.onUpdate&&o.onUpdate(t)},onComplete:()=>{n.onComplete&&n.onComplete(),a&&a(),l&&l()}})}:function(t){return e.set(r),n.onComplete&&n.onComplete(),a&&a(),t&&t(),{stop:()=>{}}}}function wt(){const{motionValues:t,stop:e,get:r}=x();return{motionValues:t,stop:e,push:(t,e,n,i={},a)=>{const o=r(t,n[t],n);if(i&&i.immediate)return void o.set(e);const s=gt(t,o,e,i,a);o.start(s)}}}function Ot(t,n={},{push:i,stop:a}=wt()){const o=e.ref(n),s=t=>{if(!o||!o.value||!o.value[t])throw new Error(`The variant ${t} does not exist.`);return o.value[t]},l=e=>{let n=r.isObject(e)&&e.transition;return n||"string"!=typeof e||(e=s(e)),n&&delete e.transition,Promise.all(Object.entries(e).map((([r,a])=>new Promise((o=>{i(r,a,t,n||ut(r,e[r]),o)})))))};return{apply:l,set:e=>{let n=r.isObject(e)?e:s(e);n.transition&&delete n.transition,Object.entries(n).forEach((([e,r])=>{i(e,r,t,{immediate:!0})}))},stopTransitions:a,leave:async t=>{let e;o&&o.value&&(o.value.leave&&(e=o.value.leave),!o.value.leave&&o.value.initial&&(e=o.value.initial)),e?(await l(e),t()):t()}}}const kt="undefined"!=typeof window;function xt({target:t,state:n,variants:i,apply:a}){const o=e.ref(!1),s=e.ref(!1),l=e.ref(!1),u=e.computed((()=>{let t=[];return i.value.hovered&&(t=[...t,...Object.keys(i.value.hovered)]),i.value.tapped&&(t=[...t,...Object.keys(i.value.tapped)]),i.value.focused&&(t=[...t,...Object.keys(i.value.focused)]),t})),c=e.computed((()=>{const t={};Object.assign(t,n.value),o.value&&i.value.hovered&&Object.assign(t,i.value.hovered),s.value&&i.value.tapped&&Object.assign(t,i.value.tapped),l.value&&i.value.focused&&Object.assign(t,i.value.focused);for(const e in t)u.value.includes(e)||delete t[e];return t}));e.watch(t,(t=>{t&&(i.value.hovered&&(r.useEventListener(t,"mouseenter",(()=>{o.value=!0})),r.useEventListener(t,"mouseleave",(()=>{o.value=!1,s.value=!1})),r.useEventListener(t,"mouseout",(()=>{o.value=!1,s.value=!1}))),i.value.tapped&&(kt&&null===window.onmousedown&&(r.useEventListener(t,"mousedown",(()=>{s.value=!0})),r.useEventListener(t,"mouseup",(()=>{s.value=!1}))),kt&&null===window.onpointerdown&&(r.useEventListener(t,"pointerdown",(()=>{s.value=!0})),r.useEventListener(t,"pointerup",(()=>{s.value=!1}))),kt&&null===window.ontouchstart&&(r.useEventListener(t,"touchstart",(()=>{s.value=!0})),r.useEventListener(t,"touchend",(()=>{s.value=!1})))),i.value.focused&&(r.useEventListener(t,"focus",(()=>{l.value=!0})),r.useEventListener(t,"blur",(()=>{l.value=!1}))))}),{immediate:!0}),e.watch(c,(t=>{a(t)}))}function Vt(t,n={syncVariants:!0,lifeCycleHooks:!0,visibilityHooks:!0,eventListeners:!0}){n.lifeCycleHooks&&function({target:t,variants:r,variant:n}){e.watch(t,(()=>{r.value&&r.value.enter&&(r.value.initial&&(n.value="initial"),e.nextTick((()=>n.value="enter")))}),{immediate:!0,flush:"pre"})}(t),n.syncVariants&&function({state:t,apply:r}){e.watch(t,(t=>{t&&r(t)}),{immediate:!0})}(t),n.visibilityHooks&&function({target:t,variants:n,variant:i}){let a=r.noop;const o=e.watch(t,(e=>{e&&(a=r.useIntersectionObserver(t,(([{isIntersecting:t}])=>{n.value&&n.value.visible&&(i.value=t?"visible":"initial")})).stop)}),{immediate:!0})}(t),n.eventListeners&&xt(t)}function At(t={}){const r=e.reactive({...t}),n=e.ref({});return e.watch(r,(()=>{const t={};for(const[e,n]of Object.entries(r)){const r=dt(e),i=ft(n,r);t[e]=i}n.value=t}),{immediate:!0,deep:!0}),{state:r,style:n}}function Tt(t){const r=e.ref(t);let n;const{state:i,style:a}=At(),o=e.watch(r,(t=>{if(t){for(const r of Object.keys(pt))null!=t.style[r]&&""!==t.style[r]&&e.set(i,r,t.style[r]);if(n)for(const r in n)e.set(t.style,r,n[r])}})),s=e.watch(a,(t=>{if(r.value&&r.value.style)for(const n in t)e.set(r.value.style,n,t[n]);else n=t}),{immediate:!0});return{style:i,stop:()=>{o(),s()}}}const Lt={x:"translateX",y:"translateY",z:"translateZ"};function jt(t={},r=!0){const n=e.reactive({...t}),i=e.ref("");return e.watch(n,(t=>{let e="",n=!1;if(r&&(t.x||t.y||t.z)){e+=`translate3d(${[t.x||0,t.y||0,t.z||0].map(B.transform).join(",")}) `,n=!0}for(const[n,i]of Object.entries(t)){if(r&&("x"===n||"y"===n||"z"===n))continue;const t=dt(n),a=ft(i,t);e+=`${Lt[n]||n}(${a}) `}r&&!n&&(e+="translateZ(0px) "),i.value=e.trim()}),{immediate:!0,deep:!0}),{state:n,transform:i}}function Ct(t){const r=e.ref(t);let n;const{state:i,transform:a}=jt(),o=e.watch(r,(t=>{t&&n&&(t.style.transform=n)})),s=e.watch(a,(t=>{r.value&&r.value.style?r.value.style.transform=t:n=t}),{immediate:!0});return{transform:i,stop:()=>{o(),s()}}}const It=["","X","Y","Z"],Rt=["transformPerspective","x","y","z"];["perspective","translate","scale","rotate","skew"].forEach((t=>{It.forEach((e=>{Rt.push(t+e)}))}));const Et=new Set(Rt);function Mt(t){return Et.has(t)}function Pt(t){const r=e.ref(t),{style:n}=Tt(r),{transform:i}=Ct(r),a=e.reactive({});return e.watch(a,(t=>{for(const r in t){const a=Mt(r)?i:n;a[r]&&a[r]===t[r]||e.set(a,r,t[r])}}),{immediate:!0,deep:!0}),{motionProperties:a,style:n,transform:i}}function zt(t={}){const r=e.ref(t),n=e.ref();return{state:e.computed((()=>{if(n.value)return r.value[n.value]})),variant:n}}function St(t,r={},n){const i=e.ref(r),a=e.ref(t),{motionProperties:o}=Pt(a),{variant:s,state:l}=zt(i),u={target:a,variant:s,variants:i,state:l,motionProperties:o,...Ot(o,i)};return Vt(u,n),u}const Bt=["initial","enter","leave","visible","hovered","tapped","focused","delay"],Ft=t=>{const n=(n,i,o)=>{const s=e.ref(t||{});((t,e)=>{const n=t.props?t.props:t.data&&t.data.attrs?t.data.attrs:{};n&&(n.variants&&r.isObject(n.variants)&&(e.value={...e.value,...n.variants}),Bt.forEach((t=>{if("delay"!==t)n&&n[t]&&r.isObject(n[t])&&(e.value[t]=n[t]);else if(n&&n[t]&&r.isNumber(n[t])){const r=n[t];e&&e.value&&(e.value.enter&&(e.value.enter.transition||(e.value.enter.transition={}),e.value.enter.transition={...e.value.enter.transition,delay:r}),e.value.visible&&(e.value.visible.transition||(e.value.visible.transition={}),e.value.visible.transition={...e.value.visible.transition,delay:r}))}})))})(o,s);const l=St(n,s);i.value&&e.set(a,i.value,l)},i=(t,r,n)=>{r.value&&a[r.value]&&e.del(a,r.value)};return{created:n,unmounted:i,bind:n,unbind:i}},Nt={initial:{opacity:0},enter:{opacity:1}},Ut={initial:{opacity:0},visible:{opacity:1}},Wt={initial:{scale:0,opacity:0},enter:{scale:1,opacity:1}},$t={initial:{scale:0,opacity:0},visible:{scale:1,opacity:1}},Dt={initial:{x:-100,rotate:90,opacity:0},enter:{x:0,rotate:0,opacity:1}},Xt={initial:{x:-100,rotate:90,opacity:0},visible:{x:0,rotate:0,opacity:1}},Yt={initial:{x:100,rotate:-90,opacity:0},enter:{x:0,rotate:0,opacity:1}},Zt={initial:{x:100,rotate:-90,opacity:0},visible:{x:0,rotate:0,opacity:1}},_t={initial:{y:-100,rotate:-90,opacity:0},enter:{y:0,rotate:0,opacity:1}},Ht={initial:{y:-100,rotate:-90,opacity:0},visible:{y:0,rotate:0,opacity:1}},qt={initial:{y:100,rotate:90,opacity:0},enter:{y:0,rotate:0,opacity:1}},Gt={initial:{y:100,rotate:90,opacity:0},visible:{y:0,rotate:0,opacity:1}},Jt={initial:{x:-100,opacity:0},enter:{x:0,opacity:1}},Kt={initial:{x:-100,opacity:0},visible:{x:0,opacity:1}},Qt={initial:{x:100,opacity:0},enter:{x:0,opacity:1}},te={initial:{x:100,opacity:0},visible:{x:0,opacity:1}},ee={initial:{y:-100,opacity:0},enter:{y:0,opacity:1}},re={initial:{y:-100,opacity:0},visible:{y:0,opacity:1}},ne={initial:{y:100,opacity:0},enter:{y:0,opacity:1}},ie={initial:{y:100,opacity:0},visible:{y:0,opacity:1}};var ae=Object.freeze({__proto__:null,fade:Nt,fadeVisible:Ut,pop:Wt,popVisible:$t,rollBottom:qt,rollLeft:Dt,rollRight:Yt,rollTop:_t,rollVisibleBottom:Gt,rollVisibleLeft:Xt,rollVisibleRight:Zt,rollVisibleTop:Ht,slideBottom:ne,slideLeft:Jt,slideRight:Qt,slideTop:ee,slideVisibleBottom:ie,slideVisibleLeft:Kt,slideVisibleRight:te,slideVisibleTop:re});function oe(t){const e="àáâäæãåāăąçćčđďèéêëēėęěğǵḧîïíīįìłḿñńǹňôöòóœøōõőṕŕřßśšşșťțûüùúūǘůűųẃẍÿýžźż·/_,:;",r=new RegExp(e.split("").join("|"),"g");return t.toString().replace(/[A-Z]/g,(t=>"-"+t)).toLowerCase().replace(/\s+/g,"-").replace(r,(t=>"aaaaaaaaaacccddeeeeeeeegghiiiiiilmnnnnoooooooooprrsssssttuuuuuuuuuwxyyzzz------".charAt(e.indexOf(t)))).replace(/&/g,"-and-").replace(/[^\w\-]+/g,"").replace(/\-\-+/g,"-").replace(/^-+/,"").replace(/-+$/,"")}const se={install(t,e){if(t.directive("motion",Ft()),!e||e&&!e.excludePresets)for(const e in ae){const r=ae[e];t.directive(`motion-${oe(e)}`,Ft(r))}if(e&&e.directives)for(const r in e.directives){const n=e.directives[r];0,t.directive(`motion-${r}`,Ft(n))}}};return t.MotionDirective=Ft,t.MotionPlugin=se,t.fade=Nt,t.fadeVisible=Ut,t.isMotionInstance=function(t){const r=t;return void 0!==r.apply&&n.isFunction(r.apply)&&void 0!==r.set&&n.isFunction(r.set)&&void 0!==r.stopTransitions&&n.isFunction(r.stopTransitions)&&void 0!==r.target&&e.isRef(r.target)},t.pop=Wt,t.popVisible=$t,t.reactiveStyle=At,t.reactiveTransform=jt,t.rollBottom=qt,t.rollLeft=Dt,t.rollRight=Yt,t.rollTop=_t,t.rollVisibleBottom=Gt,t.rollVisibleLeft=Xt,t.rollVisibleRight=Zt,t.rollVisibleTop=Ht,t.slideBottom=ne,t.slideLeft=Jt,t.slideRight=Qt,t.slideTop=ee,t.slideVisibleBottom=ie,t.slideVisibleLeft=Kt,t.slideVisibleRight=te,t.slideVisibleTop=re,t.slugify=oe,t.useElementStyle=Tt,t.useElementTransform=Ct,t.useMotion=St,t.useMotionControls=Ot,t.useMotionProperties=Pt,t.useMotionTransitions=wt,t.useMotionVariants=zt,t.useMotions=function(){return a},t.useSpring=function(t,r){const n=e.ref(t);let a={};e.watch(n,(t=>{t&&(a=t instanceof HTMLElement||t instanceof SVGElement?Pt(t).motionProperties:{...t})}),{immediate:!0});const{stop:o,get:s}=x();return{set:t=>Promise.all(Object.entries(t).map((([t,e])=>{const n=s(t,e,a);return n.start((t=>i.animate({type:"spring",from:n.get(),to:e,velocity:n.getVelocity(),onUpdate:t=>n.set(t),onComplete:t,...r})))}))),stop:o,values:a}},Object.defineProperty(t,"__esModule",{value:!0}),t}({},VueDemi,VueUse,shared,popmotion); | ||
***************************************************************************** */var O=function(){return(O=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)},V=function(e,t){return function(n){return Math.max(Math.min(n,t),e)}},k=function(e){return e%1?Number(e.toFixed(5)):e},x=/(-)?([\d]*\.?[\d])+/g,S=/(#[0-9a-f]{6}|#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2,3}\s*\/*\s*[\d\.]+%?\))/gi,C=/^(#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2,3}\s*\/*\s*[\d\.]+%?\))$/i;function R(e){return"string"==typeof e}var $={test:function(e){return"number"==typeof e},parse:parseFloat,transform:function(e){return e}},D=O(O({},$),{transform:V(0,1)}),A=O(O({},$),{default:1}),j=function(e){return{test:function(t){return R(t)&&t.endsWith(e)&&1===t.split(" ").length},parse:parseFloat,transform:function(t){return""+t+e}}},T=j("deg"),I=j("%"),P=j("px"),M=O(O({},I),{parse:function(e){return I.parse(e)/100},transform:function(e){return I.transform(100*e)}}),F=function(e,t){return function(n){return R(n)&&C.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)}},L=function(e,t,n){return function(o){var r;if(!R(o))return o;var s=o.match(x),i=s[1],a=s[2],c=s[3];return(r={})[e]=parseFloat(s[0]),r[t]=parseFloat(i),r[n]=parseFloat(a),r.alpha=void 0!==c?parseFloat(c):1,r}},U={test:F("hsl","hue"),parse:L("hue","saturation","lightness"),transform:function(e){var t=e.saturation,n=e.lightness,o=e.alpha,r=void 0===o?1:o;return"hsla("+Math.round(e.hue)+", "+I.transform(k(t))+", "+I.transform(k(n))+", "+k(D.transform(r))+")"}},z=V(0,255),B=O(O({},$),{transform:function(e){return Math.round(z(e))}}),W={test:F("rgb","red"),parse:L("red","green","blue"),transform:function(e){var t=e.green,n=e.blue,o=e.alpha,r=void 0===o?1:o;return"rgba("+B.transform(e.red)+", "+B.transform(t)+", "+B.transform(n)+", "+k(D.transform(r))+")"}};var H={test:F("#"),parse:function(e){var t="",n="",o="",r="";return e.length>5?(t=e.substr(1,2),n=e.substr(3,2),o=e.substr(5,2),r=e.substr(7,2)):(t=e.substr(1,1),n=e.substr(2,1),o=e.substr(3,1),r=e.substr(4,1),t+=t,n+=n,o+=o,r+=r),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(o,16),alpha:r?parseInt(r,16)/255:1}},transform:W.transform},X={test:function(e){return W.test(e)||H.test(e)||U.test(e)},parse:function(e){return W.test(e)?W.parse(e):U.test(e)?U.parse(e):H.parse(e)},transform:function(e){return R(e)?e:e.hasOwnProperty("red")?W.transform(e):U.transform(e)}},Y="${c}",Z="${n}";function K(e){var t=[],n=0,o=e.match(S);o&&(n=o.length,e=e.replace(S,Y),t.push.apply(t,o.map(X.parse)));var r=e.match(x);return r&&(e=e.replace(x,Z),t.push.apply(t,r.map($.parse))),{values:t,numColors:n,tokenised:e}}function q(e){return K(e).values}function J(e){var t=K(e),n=t.numColors,o=t.tokenised,r=t.values.length;return function(e){for(var t=o,s=0;s<r;s++)t=t.replace(s<n?Y:Z,s<n?X.transform(e[s]):k(e[s]));return t}}var G=function(e){return"number"==typeof e?0:e};var Q={test:function(e){var t,n,o,r;return isNaN(e)&&R(e)&&(null!==(n=null===(t=e.match(x))||void 0===t?void 0:t.length)&&void 0!==n?n:0)+(null!==(r=null===(o=e.match(S))||void 0===o?void 0:o.length)&&void 0!==r?r:0)>0},parse:q,createTransformer:J,getAnimatableNone:function(e){var t=q(e);return J(e)(t.map(G))}},ee=new Set(["brightness","contrast","saturate","opacity"]);function te(e){var t=e.slice(0,-1).split("("),n=t[0],o=t[1];if("drop-shadow"===n)return e;var r=(o.match(x)||[])[0];if(!r)return e;var s=o.replace(r,""),i=ee.has(n)?1:0;return r!==o&&(i*=100),n+"("+i+s+")"}var ne=/([a-z-]*)\(.*?\)/g,oe=O(O({},Q),{getAnimatableNone:function(e){var t=e.match(ne);return t?t.map(te).join(" "):e}});const re=()=>({type:"spring",stiffness:500,damping:25,restDelta:.5,restSpeed:10}),se=e=>({type:"spring",stiffness:550,damping:0===e?100:30,restDelta:.01,restSpeed:10}),ie=()=>({type:"keyframes",ease:"linear",duration:300}),ae=e=>({type:"keyframes",duration:800,values:e}),ce={default:se,x:re,y:re,z:re,rotate:re,rotateX:re,rotateY:re,rotateZ:re,scaleX:se,scaleY:se,scale:se,backgroundColor:ie,color:ie,opacity:ie},le=(e,t)=>{let n;return n=Array.isArray(t)?ae:ce[e]||ce.default,{to:t,...n(t)}},ue={...$,transform:Math.round},pe={color:X,backgroundColor:X,outlineColor:X,fill:X,stroke:X,borderColor:X,borderTopColor:X,borderRightColor:X,borderBottomColor:X,borderLeftColor:X,borderWidth:P,borderTopWidth:P,borderRightWidth:P,borderBottomWidth:P,borderLeftWidth:P,borderRadius:P,radius:P,borderTopLeftRadius:P,borderTopRightRadius:P,borderBottomRightRadius:P,borderBottomLeftRadius:P,width:P,maxWidth:P,height:P,maxHeight:P,size:P,top:P,right:P,bottom:P,left:P,padding:P,paddingTop:P,paddingRight:P,paddingBottom:P,paddingLeft:P,margin:P,marginTop:P,marginRight:P,marginBottom:P,marginLeft:P,rotate:T,rotateX:T,rotateY:T,rotateZ:T,scale:A,scaleX:A,scaleY:A,scaleZ:A,skew:T,skewX:T,skewY:T,distance:P,translateX:P,translateY:P,translateZ:P,x:P,y:P,z:P,perspective:P,transformPerspective:P,opacity:D,originX:M,originY:M,originZ:P,zIndex:ue,filter:oe,WebkitFilter:oe,fillOpacity:D,strokeOpacity:D,numOctaves:ue},fe=e=>pe[e],de=(e,t)=>t&&"number"==typeof e&&t.transform?t.transform(e):e;const he={linear:r.linear,easeIn:r.easeIn,easeInOut:r.easeInOut,easeOut:r.easeOut,circIn:r.circIn,circInOut:r.circInOut,circOut:r.circOut,backIn:r.backIn,backInOut:r.backInOut,backOut:r.backOut,anticipate:r.anticipate,bounceIn:r.bounceIn,bounceInOut:r.bounceInOut,bounceOut:r.bounceOut},ve=e=>{if(Array.isArray(e)){const[t,n,o,s]=e;return r.cubicBezier(t,n,o,s)}return"string"==typeof e?he[e]:e},ye=(e,t)=>"zIndex"!==e&&(!("number"!=typeof t&&!Array.isArray(t))||!("string"!=typeof t||!Q.test(t)||t.startsWith("url(")));function me({ease:e,times:t,delay:n,...o}){const r={...o};return t&&(r.offset=t),e&&(r.ease=(e=>Array.isArray(e)&&"number"!=typeof e[0])(e)?e.map(ve):ve(e)),n&&(r.elapsed=-n),r}function ge(e,t,n){return Array.isArray(t.to)&&(e.duration||(e.duration=800)),function(e){Array.isArray(e.to)&&null===e.to[0]&&(e.to=[...e.to],e.to[0]=e.from)}(t),function({delay:e,repeat:t,repeatType:n,repeatDelay:o,from:r,...s}){return!!Object.keys(s).length}(e)||(e={...e,...le(n,t.to)}),{...t,...me(e)}}function be(e,t,n,o,s){const i=function(e,t){return e[t]||e.default||e}(o,e);let a=null==i.from?t.get():i.from;const c=ye(e,n);"none"===a&&c&&"string"==typeof n&&(a=function(e,t){let n=fe(e);return n!==oe&&(n=Q),n.getAnimatableNone?n.getAnimatableNone(t):void 0}(e,n));return ye(e,a)&&c&&!1!==i.type?function(c){const l={from:a,to:n,velocity:o.velocity?o.velocity:t.getVelocity(),onUpdate:e=>t.set(e)};return"inertia"===i.type||"decay"===i.type?r.inertia({...l,...i}):r.animate({...ge(i,l,e),onUpdate:e=>{l.onUpdate(e),i.onUpdate&&i.onUpdate(e)},onComplete:()=>{o.onComplete&&o.onComplete(),s&&s(),c&&c()}})}:function(e){return t.set(n),o.onComplete&&o.onComplete(),s&&s(),e&&e(),{stop:()=>{}}}}function _e(){const{motionValues:e,stop:t,get:n}=N();return{motionValues:e,stop:t,push:(e,t,o,r={},s)=>{const i=n(e,o[e],o);if(r&&r.immediate)return void i.set(t);const a=be(e,i,t,r,s);i.start(a)}}}function we(e,o={},{push:r,stop:s}=_e()){const i=t.ref(o),a=e=>{if(!i||!i.value||!i.value[e])throw new Error(`The variant ${e} does not exist.`);return i.value[e]},c=t=>{let o=n.isObject(t)&&t.transition;return o||"string"!=typeof t||(t=a(t)),o&&delete t.transition,Promise.all(Object.entries(t).map((([n,s])=>new Promise((i=>{r(n,s,e,o||le(n,t[n]),i)})))))};return{apply:c,set:t=>{let o=n.isObject(t)?t:a(t);o.transition&&delete o.transition,Object.entries(o).forEach((([t,n])=>{r(t,n,e,{immediate:!0})}))},stopTransitions:s,leave:async e=>{let t;i&&i.value&&(i.value.leave&&(t=i.value.leave),!i.value.leave&&i.value.initial&&(t=i.value.initial)),t?(await c(t),e()):e()}}}const Ee="undefined"!=typeof window;function Ne({target:e,state:o,variants:r,apply:s}){const i=t.ref(!1),a=t.ref(!1),c=t.ref(!1),l=t.computed((()=>{let e=[];return r.value.hovered&&(e=[...e,...Object.keys(r.value.hovered)]),r.value.tapped&&(e=[...e,...Object.keys(r.value.tapped)]),r.value.focused&&(e=[...e,...Object.keys(r.value.focused)]),e})),u=t.computed((()=>{const e={};Object.assign(e,o.value),i.value&&r.value.hovered&&Object.assign(e,r.value.hovered),a.value&&r.value.tapped&&Object.assign(e,r.value.tapped),c.value&&r.value.focused&&Object.assign(e,r.value.focused);for(const t in e)l.value.includes(t)||delete e[t];return e}));t.watch(e,(e=>{e&&(r.value.hovered&&(n.useEventListener(e,"mouseenter",(()=>{i.value=!0})),n.useEventListener(e,"mouseleave",(()=>{i.value=!1,a.value=!1})),n.useEventListener(e,"mouseout",(()=>{i.value=!1,a.value=!1}))),r.value.tapped&&(Ee&&null===window.onmousedown&&(n.useEventListener(e,"mousedown",(()=>{a.value=!0})),n.useEventListener(e,"mouseup",(()=>{a.value=!1}))),Ee&&null===window.onpointerdown&&(n.useEventListener(e,"pointerdown",(()=>{a.value=!0})),n.useEventListener(e,"pointerup",(()=>{a.value=!1}))),Ee&&null===window.ontouchstart&&(n.useEventListener(e,"touchstart",(()=>{a.value=!0})),n.useEventListener(e,"touchend",(()=>{a.value=!1})))),r.value.focused&&(n.useEventListener(e,"focus",(()=>{c.value=!0})),n.useEventListener(e,"blur",(()=>{c.value=!1}))))}),{immediate:!0}),t.watch(u,(e=>{s(e)}))}function Oe(e,o={syncVariants:!0,lifeCycleHooks:!0,visibilityHooks:!0,eventListeners:!0}){o.lifeCycleHooks&&function({target:e,variants:n,variant:o}){t.watch(e,(()=>{n.value&&n.value.enter&&(n.value.initial&&(o.value="initial"),t.nextTick((()=>o.value="enter")))}),{immediate:!0,flush:"pre"})}(e),o.syncVariants&&function({state:e,apply:n}){t.watch(e,(e=>{e&&n(e)}),{immediate:!0})}(e),o.visibilityHooks&&function({target:e,variants:o,variant:r}){let s=n.noop;const i=t.watch(e,(t=>{t&&(s=n.useIntersectionObserver(e,(([{isIntersecting:e}])=>{o.value&&o.value.visible&&(r.value=e?"visible":"initial")})).stop)}),{immediate:!0})}(e),o.eventListeners&&Ne(e)}function Ve(e={}){const n=t.reactive({...e}),o=t.ref({});return t.watch(n,(()=>{const e={};for(const[t,o]of Object.entries(n)){const n=fe(t),r=de(o,n);e[t]=r}o.value=e}),{immediate:!0,deep:!0}),{state:n,style:o}}function ke(e){let n;const{state:o,style:r}=Ve(),s=t.watch(e,(e=>{if(e){for(const n of Object.keys(pe))null!==e.style[n]&&""!==e.style[n]&&t.set(o,n,e.style[n]);if(n)for(const o in n)t.set(e.style,o,n[o])}})),i=t.watch(r,(o=>{if(e.value&&e.value.style)for(const n in o)t.set(e.value.style,n,o[n]);else n=o}),{immediate:!0});return{style:o,stop:()=>{s(),i()}}}const xe={x:"translateX",y:"translateY",z:"translateZ"};function Se(e={},n=!0){const o=t.reactive({...e}),r=t.ref("");return t.watch(o,(e=>{let t="",o=!1;if(n&&(e.x||e.y||e.z)){t+=`translate3d(${[e.x||0,e.y||0,e.z||0].map(P.transform).join(",")}) `,o=!0}for(const[o,r]of Object.entries(e)){if(n&&("x"===o||"y"===o||"z"===o))continue;const e=fe(o),s=de(r,e);t+=`${xe[o]||o}(${s}) `}n&&!o&&(t+="translateZ(0px) "),r.value=t.trim()}),{immediate:!0,deep:!0}),{state:o,transform:r}}function Ce(e){const t=e.trim().split(/\) |\)/);if(1===t.length)return{};return t.reduce(((e,t)=>{if(!t)return e;const[n,o]=t.split("("),r=o.split(",").map((e=>(e=>e.endsWith("px")||e.endsWith("deg")?parseFloat(e):isNaN(Number(e))?Number(e):e)(e.endsWith(")")?e.replace(")",""):e.trim()))),s=1===r.length?r[0]:r;return{...e,[n]:s}}),{})}function Re(e){let n;const{state:o,transform:r}=Se(),s=t.watch(e,(e=>{e&&(e.style.transform&&Object.entries(Ce(e.style.transform)).forEach((([e,n])=>{t.set(o,e,n)})),n&&(e.style.transform=n))})),i=t.watch(r,(t=>{e.value&&e.value.style?e.value.style.transform=t:n=t}),{immediate:!0});return{transform:o,stop:()=>{s(),i()}}}const $e=["","X","Y","Z"],De=["transformPerspective","x","y","z"];["perspective","translate","scale","rotate","skew"].forEach((e=>{$e.forEach((t=>{De.push(e+t)}))}));const Ae=new Set(De);function je(e){return Ae.has(e)}function Te(e){const n=t.ref(e),{style:o}=ke(n),{transform:r}=Re(n),s=t.reactive({});return t.watch(s,(e=>{for(const n in e){const s=je(n)?r:o;s[n]&&s[n]===e[n]||t.set(s,n,e[n])}}),{immediate:!0,deep:!0}),{motionProperties:s,style:o,transform:r}}function Ie(e={}){const n=t.ref(e),o=t.ref();return{state:t.computed((()=>{if(o.value)return n.value[o.value]})),variant:o}}function Pe(e,t){const n=Object.create(null),o=e.split(",");for(let e=0;e<o.length;e++)n[o[e]]=!0;return t?e=>!!n[e.toLowerCase()]:e=>!!n[e]}const Me=Pe("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt");function Fe(e){if(Je(e)){const t={};for(let n=0;n<e.length;n++){const o=e[n],r=Fe(et(o)?ze(o):o);if(r)for(const e in r)t[e]=r[e]}return t}if(nt(e))return e}const Le=/;(?![^(]*\))/g,Ue=/:(.+)/;function ze(e){const t={};return e.split(Le).forEach((e=>{if(e){const n=e.split(Ue);n.length>1&&(t[n[0].trim()]=n[1].trim())}})),t}function Be(e){let t="";if(et(e))t=e;else if(Je(e))for(let n=0;n<e.length;n++){const o=Be(e[n]);o&&(t+=o+" ")}else if(nt(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const We="production"!==process.env.NODE_ENV?Object.freeze({}):{};"production"===process.env.NODE_ENV||Object.freeze([]);const He=()=>{},Xe=/^on[^a-z]/,Ye=e=>Xe.test(e),Ze=Object.assign,Ke=Object.prototype.hasOwnProperty,qe=(e,t)=>Ke.call(e,t),Je=Array.isArray,Ge=e=>"[object Map]"===rt(e),Qe=e=>"function"==typeof e,et=e=>"string"==typeof e,tt=e=>"symbol"==typeof e,nt=e=>null!==e&&"object"==typeof e,ot=Object.prototype.toString,rt=e=>ot.call(e),st=e=>rt(e).slice(8,-1),it=e=>et(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,at=(e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))})((e=>e.charAt(0).toUpperCase()+e.slice(1))),ct=(e,t)=>e!==t&&(e==e||t==t),lt=new WeakMap,ut=[];let pt;const ft=Symbol("production"!==process.env.NODE_ENV?"iterate":""),dt=Symbol("production"!==process.env.NODE_ENV?"Map key iterate":"");function ht(e,t=We){(function(e){return e&&!0===e._isEffect})(e)&&(e=e.raw);const n=function(e,t){const n=function(){if(!n.active)return t.scheduler?void 0:e();if(!ut.includes(n)){mt(n);try{return bt.push(gt),gt=!0,ut.push(n),pt=n,e()}finally{ut.pop(),wt(),pt=ut[ut.length-1]}}};return n.id=yt++,n.allowRecurse=!!t.allowRecurse,n._isEffect=!0,n.active=!0,n.raw=e,n.deps=[],n.options=t,n}(e,t);return t.lazy||n(),n}function vt(e){e.active&&(mt(e),e.options.onStop&&e.options.onStop(),e.active=!1)}let yt=0;function mt(e){const{deps:t}=e;if(t.length){for(let n=0;n<t.length;n++)t[n].delete(e);t.length=0}}let gt=!0;const bt=[];function _t(){bt.push(gt),gt=!1}function wt(){const e=bt.pop();gt=void 0===e||e}function Et(e,t,n){if(!gt||void 0===pt)return;let o=lt.get(e);o||lt.set(e,o=new Map);let r=o.get(n);r||o.set(n,r=new Set),r.has(pt)||(r.add(pt),pt.deps.push(r),"production"!==process.env.NODE_ENV&&pt.options.onTrack&&pt.options.onTrack({effect:pt,target:e,type:t,key:n}))}function Nt(e,t,n,o,r,s){const i=lt.get(e);if(!i)return;const a=new Set,c=e=>{e&&e.forEach((e=>{(e!==pt||e.allowRecurse)&&a.add(e)}))};if("clear"===t)i.forEach(c);else if("length"===n&&Je(e))i.forEach(((e,t)=>{("length"===t||t>=o)&&c(e)}));else switch(void 0!==n&&c(i.get(n)),t){case"add":Je(e)?it(n)&&c(i.get("length")):(c(i.get(ft)),Ge(e)&&c(i.get(dt)));break;case"delete":Je(e)||(c(i.get(ft)),Ge(e)&&c(i.get(dt)));break;case"set":Ge(e)&&c(i.get(ft))}a.forEach((i=>{"production"!==process.env.NODE_ENV&&i.options.onTrigger&&i.options.onTrigger({effect:i,target:e,key:n,type:t,newValue:o,oldValue:r,oldTarget:s}),i.options.scheduler?i.options.scheduler(i):i()}))}const Ot=Pe("__proto__,__v_isRef,__isVue"),Vt=new Set(Object.getOwnPropertyNames(Symbol).map((e=>Symbol[e])).filter(tt)),kt=$t(),xt=$t(!1,!0),St=$t(!0),Ct=$t(!0,!0),Rt={};function $t(e=!1,t=!1){return function(n,o,r){if("__v_isReactive"===o)return!e;if("__v_isReadonly"===o)return e;if("__v_raw"===o&&r===(e?rn:on).get(n))return n;const s=Je(n);if(!e&&s&&qe(Rt,o))return Reflect.get(Rt,o,r);const i=Reflect.get(n,o,r);if(tt(o)?Vt.has(o):Ot(o))return i;if(e||Et(n,"get",o),t)return i;if(vn(i)){return!s||!it(o)?i.value:i}return nt(i)?e?an(i):sn(i):i}}["includes","indexOf","lastIndexOf"].forEach((e=>{const t=Array.prototype[e];Rt[e]=function(...e){const n=dn(this);for(let e=0,t=this.length;e<t;e++)Et(n,"get",e+"");const o=t.apply(n,e);return-1===o||!1===o?t.apply(n,e.map(dn)):o}})),["push","pop","shift","unshift","splice"].forEach((e=>{const t=Array.prototype[e];Rt[e]=function(...e){_t();const n=t.apply(this,e);return wt(),n}}));function Dt(e=!1){return function(t,n,o,r){const s=t[n];if(!e&&(o=dn(o),!Je(t)&&vn(s)&&!vn(o)))return s.value=o,!0;const i=Je(t)&&it(n)?Number(n)<t.length:qe(t,n),a=Reflect.set(t,n,o,r);return t===dn(r)&&(i?ct(o,s)&&Nt(t,"set",n,o,s):Nt(t,"add",n,o)),a}}const At={get:kt,set:Dt(),deleteProperty:function(e,t){const n=qe(e,t),o=e[t],r=Reflect.deleteProperty(e,t);return r&&n&&Nt(e,"delete",t,void 0,o),r},has:function(e,t){const n=Reflect.has(e,t);return tt(t)&&Vt.has(t)||Et(e,"has",t),n},ownKeys:function(e){return Et(e,"iterate",Je(e)?"length":ft),Reflect.ownKeys(e)}},jt={get:St,set:(e,t)=>("production"!==process.env.NODE_ENV&&console.warn(`Set operation on key "${String(t)}" failed: target is readonly.`,e),!0),deleteProperty:(e,t)=>("production"!==process.env.NODE_ENV&&console.warn(`Delete operation on key "${String(t)}" failed: target is readonly.`,e),!0)};Ze({},At,{get:xt,set:Dt(!0)});const Tt=Ze({},jt,{get:Ct}),It=e=>nt(e)?sn(e):e,Pt=e=>nt(e)?an(e):e,Mt=e=>e,Ft=e=>Reflect.getPrototypeOf(e);function Lt(e,t,n=!1,o=!1){const r=dn(e=e.__v_raw),s=dn(t);t!==s&&!n&&Et(r,"get",t),!n&&Et(r,"get",s);const{has:i}=Ft(r),a=n?Pt:o?Mt:It;return i.call(r,t)?a(e.get(t)):i.call(r,s)?a(e.get(s)):void 0}function Ut(e,t=!1){const n=this.__v_raw,o=dn(n),r=dn(e);return e!==r&&!t&&Et(o,"has",e),!t&&Et(o,"has",r),e===r?n.has(e):n.has(e)||n.has(r)}function zt(e,t=!1){return e=e.__v_raw,!t&&Et(dn(e),"iterate",ft),Reflect.get(e,"size",e)}function Bt(e){e=dn(e);const t=dn(this),n=Ft(t).has.call(t,e);return t.add(e),n||Nt(t,"add",e,e),this}function Wt(e,t){t=dn(t);const n=dn(this),{has:o,get:r}=Ft(n);let s=o.call(n,e);s?"production"!==process.env.NODE_ENV&&nn(n,o,e):(e=dn(e),s=o.call(n,e));const i=r.call(n,e);return n.set(e,t),s?ct(t,i)&&Nt(n,"set",e,t,i):Nt(n,"add",e,t),this}function Ht(e){const t=dn(this),{has:n,get:o}=Ft(t);let r=n.call(t,e);r?"production"!==process.env.NODE_ENV&&nn(t,n,e):(e=dn(e),r=n.call(t,e));const s=o?o.call(t,e):void 0,i=t.delete(e);return r&&Nt(t,"delete",e,void 0,s),i}function Xt(){const e=dn(this),t=0!==e.size,n="production"!==process.env.NODE_ENV?Ge(e)?new Map(e):new Set(e):void 0,o=e.clear();return t&&Nt(e,"clear",void 0,void 0,n),o}function Yt(e,t){return function(n,o){const r=this,s=r.__v_raw,i=dn(s),a=e?Pt:t?Mt:It;return!e&&Et(i,"iterate",ft),s.forEach(((e,t)=>n.call(o,a(e),a(t),r)))}}function Zt(e,t,n){return function(...o){const r=this.__v_raw,s=dn(r),i=Ge(s),a="entries"===e||e===Symbol.iterator&&i,c="keys"===e&&i,l=r[e](...o),u=t?Pt:n?Mt:It;return!t&&Et(s,"iterate",c?dt:ft),{next(){const{value:e,done:t}=l.next();return t?{value:e,done:t}:{value:a?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function Kt(e){return function(...t){if("production"!==process.env.NODE_ENV){const n=t[0]?`on key "${t[0]}" `:"";console.warn(`${at(e)} operation ${n}failed: target is readonly.`,dn(this))}return"delete"!==e&&this}}const qt={get(e){return Lt(this,e)},get size(){return zt(this)},has:Ut,add:Bt,set:Wt,delete:Ht,clear:Xt,forEach:Yt(!1,!1)},Jt={get(e){return Lt(this,e,!1,!0)},get size(){return zt(this)},has:Ut,add:Bt,set:Wt,delete:Ht,clear:Xt,forEach:Yt(!1,!0)},Gt={get(e){return Lt(this,e,!0)},get size(){return zt(this,!0)},has(e){return Ut.call(this,e,!0)},add:Kt("add"),set:Kt("set"),delete:Kt("delete"),clear:Kt("clear"),forEach:Yt(!0,!1)};function Qt(e,t){const n=t?Jt:e?Gt:qt;return(t,o,r)=>"__v_isReactive"===o?!e:"__v_isReadonly"===o?e:"__v_raw"===o?t:Reflect.get(qe(n,o)&&o in t?n:t,o,r)}["keys","values","entries",Symbol.iterator].forEach((e=>{qt[e]=Zt(e,!1,!1),Gt[e]=Zt(e,!0,!1),Jt[e]=Zt(e,!1,!0)}));const en={get:Qt(!1,!1)},tn={get:Qt(!0,!1)};function nn(e,t,n){const o=dn(n);if(o!==n&&t.call(e,o)){const t=st(e);console.warn(`Reactive ${t} contains both the raw and reactive versions of the same object${"Map"===t?" as keys":""}, which can lead to inconsistencies. Avoid differentiating between the raw and reactive versions of an object and only use the reactive version if possible.`)}}const on=new WeakMap,rn=new WeakMap;function sn(e){return e&&e.__v_isReadonly?e:ln(e,!1,At,en)}function an(e){return ln(e,!0,jt,tn)}function cn(e){return ln(e,!0,Tt,tn)}function ln(e,t,n,o){if(!nt(e))return"production"!==process.env.NODE_ENV&&console.warn(`value cannot be made reactive: ${String(e)}`),e;if(e.__v_raw&&(!t||!e.__v_isReactive))return e;const r=t?rn:on,s=r.get(e);if(s)return s;const i=(a=e).__v_skip||!Object.isExtensible(a)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}(st(a));var a;if(0===i)return e;const c=new Proxy(e,2===i?o:n);return r.set(e,c),c}function un(e){return pn(e)?un(e.__v_raw):!(!e||!e.__v_isReactive)}function pn(e){return!(!e||!e.__v_isReadonly)}function fn(e){return un(e)||pn(e)}function dn(e){return e&&dn(e.__v_raw)||e}const hn=e=>nt(e)?sn(e):e;function vn(e){return Boolean(e&&!0===e.__v_isRef)}function yn(e){return function(e,t=!1){if(vn(e))return e;return new mn(e,t)}(e)}class mn{constructor(e,t=!1){this._rawValue=e,this._shallow=t,this.__v_isRef=!0,this._value=t?e:hn(e)}get value(){return Et(dn(this),"get","value"),this._value}set value(e){ct(dn(e),this._rawValue)&&(this._rawValue=e,this._value=this._shallow?e:hn(e),Nt(dn(this),"set","value",e))}}const gn=[];function bn(e,...t){_t();const n=gn.length?gn[gn.length-1].component:null,o=n&&n.appContext.config.warnHandler,r=function(){let e=gn[gn.length-1];if(!e)return[];const t=[];for(;e;){const n=t[0];n&&n.vnode===e?n.recurseCount++:t.push({vnode:e,recurseCount:0});const o=e.component&&e.component.parent;e=o&&o.vnode}return t}();if(o)Nn(o,n,11,[e+t.join(""),n&&n.proxy,r.map((({vnode:e})=>`at <${So(n,e.type)}>`)).join("\n"),r]);else{const n=[`[Vue warn]: ${e}`,...t];r.length&&n.push("\n",...function(e){const t=[];return e.forEach(((e,n)=>{t.push(...0===n?[]:["\n"],...function({vnode:e,recurseCount:t}){const n=t>0?`... (${t} recursive calls)`:"",o=` at <${So(e.component,e.type,!!e.component&&null==e.component.parent)}`,r=">"+n;return e.props?[o,..._n(e.props),r]:[o+r]}(e))})),t}(r)),console.warn(...n)}wt()}function _n(e){const t=[],n=Object.keys(e);return n.slice(0,3).forEach((n=>{t.push(...wn(n,e[n]))})),n.length>3&&t.push(" ..."),t}function wn(e,t,n){return et(t)?(t=JSON.stringify(t),n?t:[`${e}=${t}`]):"number"==typeof t||"boolean"==typeof t||null==t?n?t:[`${e}=${t}`]:vn(t)?(t=wn(e,dn(t.value),!0),n?t:[`${e}=Ref<`,t,">"]):Qe(t)?[`${e}=fn${t.name?`<${t.name}>`:""}`]:(t=dn(t),n?t:[`${e}=`,t])}const En={bc:"beforeCreate hook",c:"created hook",bm:"beforeMount hook",m:"mounted hook",bu:"beforeUpdate hook",u:"updated",bum:"beforeUnmount hook",um:"unmounted hook",a:"activated hook",da:"deactivated hook",ec:"errorCaptured hook",rtc:"renderTracked hook",rtg:"renderTriggered hook",0:"setup function",1:"render function",2:"watcher getter",3:"watcher callback",4:"watcher cleanup function",5:"native event handler",6:"component event handler",7:"vnode hook",8:"directive hook",9:"transition hook",10:"app errorHandler",11:"app warnHandler",12:"ref function",13:"async component loader",14:"scheduler flush. This is likely a Vue internals bug. Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/vue-next"};function Nn(e,t,n,o){let r;try{r=o?e(...o):e()}catch(e){Vn(e,t,n)}return r}function On(e,t,n,o){if(Qe(e)){const s=Nn(e,t,n,o);return s&&(nt(r=s)&&Qe(r.then)&&Qe(r.catch))&&s.catch((e=>{Vn(e,t,n)})),s}var r;const s=[];for(let r=0;r<e.length;r++)s.push(On(e[r],t,n,o));return s}function Vn(e,t,n,o=!0){const r=t?t.vnode:null;if(t){let o=t.parent;const r=t.proxy,s="production"!==process.env.NODE_ENV?En[n]:n;for(;o;){const t=o.ec;if(t)for(let n=0;n<t.length;n++)if(!1===t[n](e,r,s))return;o=o.parent}const i=t.appContext.config.errorHandler;if(i)return void Nn(i,null,10,[e,r,s])}!function(e,t,n,o=!0){if("production"!==process.env.NODE_ENV){const r=En[t];if(n&&gn.push(n),bn("Unhandled error"+(r?` during execution of ${r}`:"")),n&&gn.pop(),o)throw e;console.error(e)}else console.error(e)}(e,n,r,o)}let kn=!1,xn=!1;const Sn=[];let Cn=0;const Rn=[];let $n=null,Dn=0;const An=[];let jn=null,Tn=0;const In=Promise.resolve();let Pn=null,Mn=null;function Fn(e){const t=Pn||In;return e?t.then(this?e.bind(this):e):t}function Ln(e){Sn.length&&Sn.includes(e,kn&&e.allowRecurse?Cn+1:Cn)||e===Mn||(Sn.push(e),Un())}function Un(){kn||xn||(xn=!0,Pn=In.then(Xn))}function zn(e,t,n,o){Je(e)?n.push(...e):t&&t.includes(e,e.allowRecurse?o+1:o)||n.push(e),Un()}function Bn(e){zn(e,jn,An,Tn)}function Wn(e,t=null){if(Rn.length){for(Mn=t,$n=[...new Set(Rn)],Rn.length=0,"production"!==process.env.NODE_ENV&&(e=e||new Map),Dn=0;Dn<$n.length;Dn++)"production"!==process.env.NODE_ENV&&Yn(e,$n[Dn]),$n[Dn]();$n=null,Dn=0,Mn=null,Wn(e,t)}}const Hn=e=>null==e.id?1/0:e.id;function Xn(e){xn=!1,kn=!0,"production"!==process.env.NODE_ENV&&(e=e||new Map),Wn(e),Sn.sort(((e,t)=>Hn(e)-Hn(t)));try{for(Cn=0;Cn<Sn.length;Cn++){const t=Sn[Cn];t&&("production"!==process.env.NODE_ENV&&Yn(e,t),Nn(t,null,14))}}finally{Cn=0,Sn.length=0,function(e){if(An.length){const t=[...new Set(An)];if(An.length=0,jn)return void jn.push(...t);for(jn=t,"production"!==process.env.NODE_ENV&&(e=e||new Map),jn.sort(((e,t)=>Hn(e)-Hn(t))),Tn=0;Tn<jn.length;Tn++)"production"!==process.env.NODE_ENV&&Yn(e,jn[Tn]),jn[Tn]();jn=null,Tn=0}}(e),kn=!1,Pn=null,(Sn.length||An.length)&&Xn(e)}}function Yn(e,t){if(e.has(t)){const n=e.get(t);if(n>100)throw new Error("Maximum recursive updates exceeded. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.");e.set(t,n+1)}else e.set(t,1)}const Zn=new Set;if("production"!==process.env.NODE_ENV){("undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{}).__VUE_HMR_RUNTIME__={createRecord:qn((function(e,t){t||(bn("HMR API usage is out of date.\nPlease upgrade vue-loader/vite/rollup-plugin-vue or other relevant dependency that handles Vue SFC compilation."),t={});if(Kn.has(e))return!1;return Kn.set(e,{component:Co(t)?t.__vccOpts:t,instances:new Set}),!0})),rerender:qn((function(e,t){const n=Kn.get(e);if(!n)return;t&&(n.component.render=t);Array.from(n.instances).forEach((e=>{t&&(e.render=t),e.renderCache=[],e.update()}))})),reload:qn((function(e,t){const n=Kn.get(e);if(!n)return;const{component:o,instances:r}=n;if(!Zn.has(o)){t=Co(t)?t.__vccOpts:t,Ze(o,t);for(const e in o)e in t||delete o[e];Zn.add(o),Bn((()=>{Zn.delete(o)}))}Array.from(r).forEach((e=>{e.parent?Ln(e.parent.update):e.appContext.reload?e.appContext.reload():"undefined"!=typeof window?window.location.reload():console.warn("[HMR] Root or manually mounted instance modified. Full reload required.")}))}))}}const Kn=new Map;function qn(e){return(t,n)=>{try{return e(t,n)}catch(e){console.error(e),console.warn("[HMR] Something went wrong during Vue component hot-reload. Full reload required.")}}}let Jn=null;function Gn(e){if(Qe(e)&&(e=e()),Je(e)){const t=function(e){let t;for(let n=0;n<e.length;n++){const o=e[n];if(!uo(o))return;if(o.type!==lo||"v-if"===o.children){if(t)return;t=o}}return t}(e);"production"===process.env.NODE_ENV||t||bn("<Suspense> slots expect a single root node."),e=t}return _o(e)}let Qn=0;const eo=e=>Qn+=e;const to={};function no(e,t,{immediate:n,deep:o,flush:r,onTrack:s,onTrigger:i}=We,a=ko){"production"===process.env.NODE_ENV||t||(void 0!==n&&bn('watch() "immediate" option is only respected when using the watch(source, callback, options?) signature.'),void 0!==o&&bn('watch() "deep" option is only respected when using the watch(source, callback, options?) signature.'));const c=e=>{bn("Invalid watch source: ",e,"A watch source can only be a getter/effect function, a ref, a reactive object, or an array of these types.")};let l,u,p=!1;if(vn(e)?(l=()=>e.value,p=!!e._shallow):un(e)?(l=()=>e,o=!0):Je(e)?l=()=>e.map((e=>vn(e)?e.value:un(e)?ro(e):Qe(e)?Nn(e,a,2,[a&&a.proxy]):void("production"!==process.env.NODE_ENV&&c(e)))):Qe(e)?l=t?()=>Nn(e,a,2,[a&&a.proxy]):()=>{if(!a||!a.isUnmounted)return u&&u(),Nn(e,a,3,[f])}:(l=He,"production"!==process.env.NODE_ENV&&c(e)),t&&o){const e=l;l=()=>ro(e())}const f=e=>{u=y.options.onStop=()=>{Nn(e,a,4)}};let d=Je(e)?[]:to;const h=()=>{if(y.active)if(t){const e=y();(o||p||ct(e,d))&&(u&&u(),On(t,a,3,[e,d===to?void 0:d,f]),d=e)}else y()};let v;h.allowRecurse=!!t,v="sync"===r?h:"post"===r?()=>so(h,a&&a.suspense):()=>{!a||a.isMounted?function(e){zn(e,$n,Rn,Dn)}(h):h()};const y=ht(l,{lazy:!0,onTrack:s,onTrigger:i,scheduler:v});return function(e,t=ko){t&&(t.effects||(t.effects=[])).push(e)}(y,a),t?n?h():d=y():"post"===r?so(y,a&&a.suspense):y(),()=>{vt(y),a&&((e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)})(a.effects,y)}}function oo(e,t,n){const o=this.proxy;return no(et(e)?()=>o[e]:e.bind(o),t.bind(o),n,this)}function ro(e,t=new Set){if(!nt(e)||t.has(e))return e;if(t.add(e),vn(e))ro(e.value,t);else if(Je(e))for(let n=0;n<e.length;n++)ro(e[n],t);else if("[object Set]"===rt(e)||Ge(e))e.forEach((e=>{ro(e,t)}));else for(const n in e)ro(e[n],t);return e}const so=function(e,t){t&&t.pendingBranch?Je(e)?t.effects.push(...e):t.effects.push(e):Bn(e)},io=Symbol(),ao=Symbol("production"!==process.env.NODE_ENV?"Fragment":void 0),co=Symbol("production"!==process.env.NODE_ENV?"Text":void 0),lo=Symbol("production"!==process.env.NODE_ENV?"Comment":void 0);Symbol("production"!==process.env.NODE_ENV?"Static":void 0);function uo(e){return!!e&&!0===e.__v_isVNode}const po="__vInternal",fo=({key:e})=>null!=e?e:null,ho=({ref:e})=>null!=e?et(e)||vn(e)||Qe(e)?{i:Jn,r:e}:e:null,vo="production"!==process.env.NODE_ENV?(...e)=>yo(...e):yo;function yo(e,t=null,n=null,o=0,r=null,s=!1){if(e&&e!==io||("production"===process.env.NODE_ENV||e||bn(`Invalid vnode type when creating vnode: ${e}.`),e=lo),uo(e)){const o=mo(e,t,!0);return n&&wo(o,n),o}if(Co(e)&&(e=e.__vccOpts),t){(fn(t)||po in t)&&(t=Ze({},t));let{class:e,style:n}=t;e&&!et(e)&&(t.class=Be(e)),nt(n)&&(fn(n)&&!Je(n)&&(n=Ze({},n)),t.style=Fe(n))}const i=et(e)?1:(e=>e.__isSuspense)(e)?128:(e=>e.__isTeleport)(e)?64:nt(e)?4:Qe(e)?2:0;"production"!==process.env.NODE_ENV&&4&i&&fn(e)&&bn("Vue received a Component which was made a reactive object. This can lead to unnecessary performance overhead, and should be avoided by marking the component with `markRaw` or using `shallowRef` instead of `ref`.","\nComponent that was made reactive: ",e=dn(e));const a={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&fo(t),ref:t&&ho(t),scopeId:null,children:null,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:i,patchFlag:o,dynamicProps:r,dynamicChildren:null,appContext:null};if("production"!==process.env.NODE_ENV&&a.key!=a.key&&bn("VNode created with invalid key (NaN). VNode type:",a.type),wo(a,n),128&i){const{content:e,fallback:t}=function(e){const{shapeFlag:t,children:n}=e;let o,r;return 32&t?(o=Gn(n.default),r=Gn(n.fallback)):(o=Gn(n),r=_o(null)),{content:o,fallback:r}}(a);a.ssContent=e,a.ssFallback=t}return a}function mo(e,t,n=!1){const{props:o,ref:r,patchFlag:s,children:i}=e,a=t?function(...e){const t=Ze({},e[0]);for(let n=1;n<e.length;n++){const o=e[n];for(const e in o)if("class"===e)t.class!==o.class&&(t.class=Be([t.class,o.class]));else if("style"===e)t.style=Fe([t.style,o.style]);else if(Ye(e)){const n=t[e],r=o[e];n!==r&&(t[e]=n?[].concat(n,o[e]):r)}else""!==e&&(t[e]=o[e])}return t}(o||{},t):o;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:a,key:a&&fo(a),ref:t&&t.ref?n&&r?Je(r)?r.concat(ho(t)):[r,ho(t)]:ho(t):r,scopeId:e.scopeId,children:"production"!==process.env.NODE_ENV&&-1===s&&Je(i)?i.map(go):i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==ao?-1===s?16:16|s:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&mo(e.ssContent),ssFallback:e.ssFallback&&mo(e.ssFallback),el:e.el,anchor:e.anchor}}function go(e){const t=mo(e);return Je(e.children)&&(t.children=e.children.map(go)),t}function bo(e=" ",t=0){return vo(co,null,e,t)}function _o(e){return null==e||"boolean"==typeof e?vo(lo):Je(e)?vo(ao,null,e):"object"==typeof e?null===e.el?e:mo(e):vo(co,null,String(e))}function wo(e,t){let n=0;const{shapeFlag:o}=e;if(null==t)t=null;else if(Je(t))n=16;else if("object"==typeof t){if(1&o||64&o){const n=t.default;return void(n&&(n._c&&eo(1),wo(e,n()),n._c&&eo(-1)))}{n=32;const e=t._;e||po in t||(t._ctx=Jn)}}else Qe(t)?(t={default:t,_ctx:Jn},n=32):(t=String(t),64&o?(n=16,t=[bo(t)]):n=8);e.children=t,e.shapeFlag|=n}function Eo(e,t,n){const o=n.appContext.config.optionMergeStrategies,{mixins:r,extends:s}=t;s&&Eo(e,s,n),r&&r.forEach((t=>Eo(e,t,n)));for(const r in t)e[r]=o&&qe(o,r)?o[r](e[r],t[r],n.proxy,r):t[r]}const No=e=>e?4&e.vnode.shapeFlag?e.exposed?e.exposed:e.proxy:No(e.parent):null,Oo=Ze(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>"production"!==process.env.NODE_ENV?cn(e.props):e.props,$attrs:e=>"production"!==process.env.NODE_ENV?cn(e.attrs):e.attrs,$slots:e=>"production"!==process.env.NODE_ENV?cn(e.slots):e.slots,$refs:e=>"production"!==process.env.NODE_ENV?cn(e.refs):e.refs,$parent:e=>No(e.parent),$root:e=>No(e.root),$emit:e=>e.emit,$options:e=>__VUE_OPTIONS_API__?function(e){const t=e.type,{__merged:n,mixins:o,extends:r}=t;if(n)return n;const s=e.appContext.mixins;if(!s.length&&!o&&!r)return t;const i={};return s.forEach((t=>Eo(i,t,e))),Eo(i,t,e),t.__merged=i}(e):e.type,$forceUpdate:e=>()=>Ln(e.update),$nextTick:e=>Fn.bind(e.proxy),$watch:e=>__VUE_OPTIONS_API__?oo.bind(e):He}),Vo={get({_:e},t){const{ctx:n,setupState:o,data:r,props:s,accessCache:i,type:a,appContext:c}=e;if("__v_skip"===t)return!0;if("production"!==process.env.NODE_ENV&&"__isVue"===t)return!0;let l;if("$"!==t[0]){const a=i[t];if(void 0!==a)switch(a){case 0:return o[t];case 1:return r[t];case 3:return n[t];case 2:return s[t]}else{if(o!==We&&qe(o,t))return i[t]=0,o[t];if(r!==We&&qe(r,t))return i[t]=1,r[t];if((l=e.propsOptions[0])&&qe(l,t))return i[t]=2,s[t];if(n!==We&&qe(n,t))return i[t]=3,n[t];__VUE_OPTIONS_API__,i[t]=4}}const u=Oo[t];let p,f;return u?("$attrs"===t&&(Et(e,"get",t),process),u(e)):(p=a.__cssModules)&&(p=p[t])?p:n!==We&&qe(n,t)?(i[t]=3,n[t]):(f=c.config.globalProperties,qe(f,t)?f[t]:void process)},set({_:e},t,n){const{data:o,setupState:r,ctx:s}=e;if(r!==We&&qe(r,t))r[t]=n;else if(o!==We&&qe(o,t))o[t]=n;else if(qe(e.props,t))return"production"!==process.env.NODE_ENV&&bn(`Attempting to mutate prop "${t}". Props are readonly.`,e),!1;return"$"===t[0]&&t.slice(1)in e?("production"!==process.env.NODE_ENV&&bn(`Attempting to mutate public property "${t}". Properties starting with $ are reserved and readonly.`,e),!1):("production"!==process.env.NODE_ENV&&t in e.appContext.config.globalProperties?Object.defineProperty(s,t,{enumerable:!0,configurable:!0,value:n}):s[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:r,propsOptions:s}},i){let a;return void 0!==n[i]||e!==We&&qe(e,i)||t!==We&&qe(t,i)||(a=s[0])&&qe(a,i)||qe(o,i)||qe(Oo,i)||qe(r.config.globalProperties,i)}};"production"!==process.env.NODE_ENV&&(Vo.ownKeys=e=>(bn("Avoid app logic that relies on enumerating keys on a component instance. The keys will be empty in production mode to avoid performance overhead."),Reflect.ownKeys(e))),Ze({},Vo,{get(e,t){if(t!==Symbol.unscopables)return Vo.get(e,t,e)},has(e,t){const n="_"!==t[0]&&!Me(t);return"production"!==process.env.NODE_ENV&&!n&&Vo.has(e,t)&&bn(`Property ${JSON.stringify(t)} should not start with _ which is a reserved prefix for Vue internals.`),n}});let ko=null;const xo=/(?:^|[-_])(\w)/g;function So(e,t,n=!1){let o=function(e){return Qe(e)&&e.displayName||e.name}(t);if(!o&&t.__file){const e=t.__file.match(/([^/\\]+)\.\w+$/);e&&(o=e[1])}if(!o&&e&&e.parent){const n=e=>{for(const n in e)if(e[n]===t)return n};o=n(e.components||e.parent.type.components)||n(e.appContext.components)}return o?o.replace(xo,(e=>e.toUpperCase())).replace(/[-_]/g,""):n?"App":"Anonymous"}function Co(e){return Qe(e)&&"__vccOpts"in e}function Ro(e){const t=yn(e),n=yn();var o,r,s;return o=t,r=e=>{e&&(n.value=e.$el?e.$el:e)},s={immediate:!0},"production"===process.env.NODE_ENV||Qe(r)||bn("`watch(fn, options?)` signature has been moved to a separate API. Use `watchEffect(fn, options?)` instead. `watch` now only supports `watch(source, cb, options?) signature."),no(o,r,s),n}function $o(e,n={},o){const r=t.ref(n),s=Ro(e),{motionProperties:i}=Te(s),{variant:a,state:c}=Ie(r),l={target:s,variant:a,variants:r,state:c,motionProperties:i,...we(i,r)};return Oe(l,o),l}Symbol("production"!==process.env.NODE_ENV?"ssrContext":"");const Do=["initial","enter","leave","visible","hovered","tapped","focused","delay"],Ao=e=>{const o=(o,r,i)=>{const a=t.ref(e||{});((e,t)=>{const o=e.props?e.props:e.data&&e.data.attrs?e.data.attrs:{};o&&(o.variants&&n.isObject(o.variants)&&(t.value={...t.value,...o.variants}),Do.forEach((e=>{if("delay"!==e)o&&o[e]&&n.isObject(o[e])&&(t.value[e]=o[e]);else if(o&&o[e]&&n.isNumber(o[e])){const n=o[e];t&&t.value&&(t.value.enter&&(t.value.enter.transition||(t.value.enter.transition={}),t.value.enter.transition={...t.value.enter.transition,delay:n}),t.value.visible&&(t.value.visible.transition||(t.value.visible.transition={}),t.value.visible.transition={...t.value.visible.transition,delay:n}))}})))})(i,a);const c=$o(o,a);r.value&&t.set(s,r.value,c)},r=(e,n,o)=>{n.value&&s[n.value]&&t.del(s,n.value)};return{created:o,unmounted:r,bind:o,unbind:r}},jo={initial:{opacity:0},enter:{opacity:1}},To={initial:{opacity:0},visible:{opacity:1}},Io={initial:{scale:0,opacity:0},enter:{scale:1,opacity:1}},Po={initial:{scale:0,opacity:0},visible:{scale:1,opacity:1}},Mo={initial:{x:-100,rotate:90,opacity:0},enter:{x:0,rotate:0,opacity:1}},Fo={initial:{x:-100,rotate:90,opacity:0},visible:{x:0,rotate:0,opacity:1}},Lo={initial:{x:100,rotate:-90,opacity:0},enter:{x:0,rotate:0,opacity:1}},Uo={initial:{x:100,rotate:-90,opacity:0},visible:{x:0,rotate:0,opacity:1}},zo={initial:{y:-100,rotate:-90,opacity:0},enter:{y:0,rotate:0,opacity:1}},Bo={initial:{y:-100,rotate:-90,opacity:0},visible:{y:0,rotate:0,opacity:1}},Wo={initial:{y:100,rotate:90,opacity:0},enter:{y:0,rotate:0,opacity:1}},Ho={initial:{y:100,rotate:90,opacity:0},visible:{y:0,rotate:0,opacity:1}},Xo={initial:{x:-100,opacity:0},enter:{x:0,opacity:1}},Yo={initial:{x:-100,opacity:0},visible:{x:0,opacity:1}},Zo={initial:{x:100,opacity:0},enter:{x:0,opacity:1}},Ko={initial:{x:100,opacity:0},visible:{x:0,opacity:1}},qo={initial:{y:-100,opacity:0},enter:{y:0,opacity:1}},Jo={initial:{y:-100,opacity:0},visible:{y:0,opacity:1}},Go={initial:{y:100,opacity:0},enter:{y:0,opacity:1}},Qo={initial:{y:100,opacity:0},visible:{y:0,opacity:1}};var er=Object.freeze({__proto__:null,fade:jo,fadeVisible:To,pop:Io,popVisible:Po,rollBottom:Wo,rollLeft:Mo,rollRight:Lo,rollTop:zo,rollVisibleBottom:Ho,rollVisibleLeft:Fo,rollVisibleRight:Uo,rollVisibleTop:Bo,slideBottom:Go,slideLeft:Xo,slideRight:Zo,slideTop:qo,slideVisibleBottom:Qo,slideVisibleLeft:Yo,slideVisibleRight:Ko,slideVisibleTop:Jo});function tr(e){const t="àáâäæãåāăąçćčđďèéêëēėęěğǵḧîïíīįìłḿñńǹňôöòóœøōõőṕŕřßśšşșťțûüùúūǘůűųẃẍÿýžźż·/_,:;",n=new RegExp(t.split("").join("|"),"g");return e.toString().replace(/[A-Z]/g,(e=>"-"+e)).toLowerCase().replace(/\s+/g,"-").replace(n,(e=>"aaaaaaaaaacccddeeeeeeeegghiiiiiilmnnnnoooooooooprrsssssttuuuuuuuuuwxyyzzz------".charAt(t.indexOf(e)))).replace(/&/g,"-and-").replace(/[^\w\-]+/g,"").replace(/\-\-+/g,"-").replace(/^-+/,"").replace(/-+$/,"")}const nr={install(e,t){if(e.directive("motion",Ao()),!t||t&&!t.excludePresets)for(const t in er){const n=er[t];e.directive(`motion-${tr(t)}`,Ao(n))}if(t&&t.directives)for(const n in t.directives){const o=t.directives[n];0,e.directive(`motion-${n}`,Ao(o))}}};return e.MotionDirective=Ao,e.MotionPlugin=nr,e.fade=jo,e.fadeVisible=To,e.isMotionInstance=function(e){const n=e;return void 0!==n.apply&&o.isFunction(n.apply)&&void 0!==n.set&&o.isFunction(n.set)&&void 0!==n.stopTransitions&&o.isFunction(n.stopTransitions)&&void 0!==n.target&&t.isRef(n.target)},e.pop=Io,e.popVisible=Po,e.reactiveStyle=Ve,e.reactiveTransform=Se,e.rollBottom=Wo,e.rollLeft=Mo,e.rollRight=Lo,e.rollTop=zo,e.rollVisibleBottom=Ho,e.rollVisibleLeft=Fo,e.rollVisibleRight=Uo,e.rollVisibleTop=Bo,e.slideBottom=Go,e.slideLeft=Xo,e.slideRight=Zo,e.slideTop=qo,e.slideVisibleBottom=Qo,e.slideVisibleLeft=Yo,e.slideVisibleRight=Ko,e.slideVisibleTop=Jo,e.slugify=tr,e.useElementStyle=ke,e.useElementTransform=Re,e.useMotion=$o,e.useMotionControls=we,e.useMotionProperties=Te,e.useMotionTransitions=_e,e.useMotionVariants=Ie,e.useMotions=function(){return s},e.useSpring=function(e,n){const o=t.ref(e);let s={};t.watch(o,(e=>{if(!e)return;let t=e;e.$el&&(t=e.$el),s=t instanceof HTMLElement||t instanceof SVGElement?Te(t).motionProperties:{...e}}),{immediate:!0});const{stop:i,get:a}=N();return{set:e=>Promise.all(Object.entries(e).map((([e,t])=>{const o=a(e,t,s);return o.start((e=>r.animate({type:"spring",from:o.get(),to:t,velocity:o.getVelocity(),onUpdate:e=>o.set(e),onComplete:e,...n})))}))),stop:i,values:s}},Object.defineProperty(e,"__esModule",{value:!0}),e}({},VueDemi,VueUse,shared,popmotion); |
{ | ||
"name": "@vueuse/motion", | ||
"version": "1.3.7", | ||
"version": "1.4.0", | ||
"description": "🤹 Vue Composables putting your components in motion", | ||
@@ -47,5 +47,5 @@ "repository": "https://github.com/vueuse/motion", | ||
"dependencies": { | ||
"@vueuse/core": "^4.3.6", | ||
"@vueuse/core": "^4.4.0", | ||
"popmotion": "^9.3.1", | ||
"vue-demi": "0.7.2" | ||
"vue-demi": "0.7.3" | ||
}, | ||
@@ -52,0 +52,0 @@ "peerDependencies": { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
946904
22424
149
+ Addedvue-demi@0.7.3(transitive)
- Removedvue-demi@0.7.2(transitive)
Updated@vueuse/core@^4.4.0
Updatedvue-demi@0.7.3