import{ca as se,l as ue,Z as K,aw as z,$ as ae,Y as D,cb as ce,ae as J,cc as fe,cd as de,aq as Z,c7 as Q,aI as ee,bR as k,b as I,ce as me}from"./Co0rzPff.js";function te(e){return fe()?(de(e),!0):!1}function Ve(e){let n=!1,t;const o=se(!0);return(...i)=>(n||(t=o.run(()=>e(...i)),n=!0),t)}function T(e){return typeof e=="function"?e():ue(e)}const ne=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const ve=e=>e!=null,pe=Object.prototype.toString,we=e=>pe.call(e)==="[object Object]",_=()=>{},he=ge();function ge(){var e,n;return ne&&((e=window==null?void 0:window.navigator)==null?void 0:e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((n=window==null?void 0:window.navigator)==null?void 0:n.maxTouchPoints)>2&&/iPad|Macintosh/.test(window==null?void 0:window.navigator.userAgent))}function B(e,n){function t(...o){return new Promise((i,l)=>{Promise.resolve(e(()=>n.apply(this,o),{fn:n,thisArg:this,args:o})).then(i).catch(l)})}return t}const oe=e=>e();function ye(e,n={}){let t,o,i=_;const l=u=>{clearTimeout(u),i(),i=_};return u=>{const f=T(e),s=T(n.maxWait);return t&&l(t),f<=0||s!==void 0&&s<=0?(o&&(l(o),o=null),Promise.resolve(u())):new Promise((a,d)=>{i=n.rejectOnCancel?d:a,s&&!o&&(o=setTimeout(()=>{t&&l(t),o=null,a(u())},s)),t=setTimeout(()=>{o&&l(o),o=null,a(u())},f)})}}function be(...e){let n=0,t,o=!0,i=_,l,v,u,f,s;!Z(e[0])&&typeof e[0]=="object"?{delay:v,trailing:u=!0,leading:f=!0,rejectOnCancel:s=!1}=e[0]:[v,u=!0,f=!0,s=!1]=e;const a=()=>{t&&(clearTimeout(t),t=void 0,i(),i=_)};return h=>{const r=T(v),c=Date.now()-n,w=()=>l=h();return a(),r<=0?(n=Date.now(),w()):(c>r&&(f||!o)?(n=Date.now(),w()):u&&(l=new Promise((y,S)=>{i=s?S:y,t=setTimeout(()=>{n=Date.now(),o=!0,y(w()),a()},Math.max(0,r-c))})),!f&&!t&&(t=setTimeout(()=>o=!0,r)),o=!1,l)}}function Se(e=oe){const n=D(!0);function t(){n.value=!1}function o(){n.value=!0}const i=(...l)=>{n.value&&e(...l)};return{isActive:ce(n),pause:t,resume:o,eventFilter:i}}function re(e){return Q()}function Ee(e,n=200,t={}){return B(ye(n,t),e)}function Te(e,n=200,t=!1,o=!0,i=!1){return B(be(n,t,o,i),e)}function Ae(e,n,t={}){const{eventFilter:o=oe,...i}=t;return J(e,B(o,n),i)}function _e(e,n,t={}){const{eventFilter:o,...i}=t,{eventFilter:l,pause:v,resume:u,isActive:f}=Se(o);return{stop:Ae(e,n,{...i,eventFilter:l}),pause:v,resume:u,isActive:f}}function ie(e,n=!0,t){re()?K(e,t):n?e():z(e)}function Oe(e,n){re()&&ae(e,n)}var U={};function Re(e,n,t){let o;Z(t)?o={evaluating:t}:o={};const{lazy:i=!1,evaluating:l=void 0,shallow:v=!0,onError:u=_}=o,f=D(!i),s=v?ee(n):D(n);let a=0;return me(async d=>{if(!f.value)return;a++;const h=a;let r=!1;l&&Promise.resolve().then(()=>{l.value=!0});try{const c=await e(w=>{d(()=>{l&&(l.value=!1),r||w()})});h===a&&(s.value=c)}catch(c){u(c)}finally{l&&h===a&&(l.value=!1),r=!0}}),i?I(()=>(f.value=!0,s.value)):s}const M=ne?window:void 0;function P(e){var n;const t=T(e);return(n=t==null?void 0:t.$el)!=null?n:t}function W(...e){let n,t,o,i;if(typeof e[0]=="string"||Array.isArray(e[0])?([t,o,i]=e,n=M):[n,t,o,i]=e,!n)return _;Array.isArray(t)||(t=[t]),Array.isArray(o)||(o=[o]);const l=[],v=()=>{l.forEach(a=>a()),l.length=0},u=(a,d,h,r)=>(a.addEventListener(d,h,r),()=>a.removeEventListener(d,h,r)),f=J(()=>[P(n),T(i)],([a,d])=>{if(v(),!a)return;const h=we(d)?{...d}:d;l.push(...t.flatMap(r=>o.map(c=>u(a,r,c,h))))},{immediate:!0,flush:"post"}),s=()=>{f(),v()};return te(s),s}let X=!1;function ze(e,n,t={}){const{window:o=M,ignore:i=[],capture:l=!0,detectIframe:v=!1}=t;if(!o)return _;he&&!X&&(X=!0,Array.from(o.document.body.children).forEach(r=>r.addEventListener("click",_)),o.document.documentElement.addEventListener("click",_));let u=!0;const f=r=>T(i).some(c=>{if(typeof c=="string")return Array.from(o.document.querySelectorAll(c)).some(w=>w===r.target||r.composedPath().includes(w));{const w=P(c);return w&&(r.target===w||r.composedPath().includes(w))}}),s=r=>{const c=P(e);if(!(!c||c===r.target||r.composedPath().includes(c))){if(r.detail===0&&(u=!f(r)),!u){u=!0;return}n(r)}};let a=!1;const d=[W(o,"click",r=>{a||(a=!0,setTimeout(()=>{a=!1},0),s(r))},{passive:!0,capture:l}),W(o,"pointerdown",r=>{const c=P(e);u=!f(r)&&!!(c&&!r.composedPath().includes(c))},{passive:!0}),v&&W(o,"blur",r=>{setTimeout(()=>{var c;const w=P(e);((c=o.document.activeElement)==null?void 0:c.tagName)==="IFRAME"&&!(w!=null&&w.contains(o.document.activeElement))&&n(r)},0)})].filter(Boolean);return()=>d.forEach(r=>r())}function De(){const e=D(!1),n=Q();return n&&K(()=>{e.value=!0},n),e}function Le(e){const n=De();return I(()=>(n.value,!!e()))}const V=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof U<"u"?U:typeof self<"u"?self:{},R="__vueuse_ssr_handlers__",Me=Pe();function Pe(){return R in V||(V[R]=V[R]||{}),V[R]}function We(e,n){return Me[e]||n}function Fe(e){return e==null?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":typeof e=="boolean"?"boolean":typeof e=="string"?"string":typeof e=="object"?"object":Number.isNaN(e)?"any":"number"}const Ie={boolean:{read:e=>e==="true",write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},Y="vueuse-storage";function le(e,n,t,o={}){var i;const{flush:l="pre",deep:v=!0,listenToStorageChanges:u=!0,writeDefaults:f=!0,mergeDefaults:s=!1,shallow:a,window:d=M,eventFilter:h,onError:r=m=>{console.error(m)},initOnMounted:c}=o,w=(a?ee:D)(typeof n=="function"?n():n);if(!t)try{t=We("getDefaultStorage",()=>{var m;return(m=M)==null?void 0:m.localStorage})()}catch(m){r(m)}if(!t)return w;const y=T(n),S=Fe(y),E=(i=o.serializer)!=null?i:Ie[S],{pause:C,resume:x}=_e(w,()=>H(w.value),{flush:l,deep:v,eventFilter:h});d&&u&&ie(()=>{t instanceof Storage?W(d,"storage",O):W(d,Y,A),c&&O()}),c||O();function N(m,g){if(d){const b={key:e,oldValue:m,newValue:g,storageArea:t};d.dispatchEvent(t instanceof Storage?new StorageEvent("storage",b):new CustomEvent(Y,{detail:b}))}}function H(m){try{const g=t.getItem(e);if(m==null)N(g,null),t.removeItem(e);else{const b=E.write(m);g!==b&&(t.setItem(e,b),N(g,b))}}catch(g){r(g)}}function p(m){const g=m?m.newValue:t.getItem(e);if(g==null)return f&&y!=null&&t.setItem(e,E.write(y)),y;if(!m&&s){const b=E.read(g);return typeof s=="function"?s(b,y):S==="object"&&!Array.isArray(b)?{...y,...b}:b}else return typeof g!="string"?g:E.read(g)}function O(m){if(!(m&&m.storageArea!==t)){if(m&&m.key==null){w.value=y;return}if(!(m&&m.key!==e)){C();try{(m==null?void 0:m.newValue)!==E.write(w.value)&&(w.value=p(m))}catch(g){r(g)}finally{m?z(x):x()}}}}function A(m){O(m.detail)}return w}function Je(e,n={}){const{delayEnter:t=0,delayLeave:o=0,window:i=M}=n,l=D(!1);let v;const u=f=>{const s=f?t:o;v&&(clearTimeout(v),v=void 0),s?v=setTimeout(()=>l.value=f,s):l.value=f};return i&&(W(e,"mouseenter",()=>u(!0),{passive:!0}),W(e,"mouseleave",()=>u(!1),{passive:!0})),l}function Ce(e,n,t={}){const{root:o,rootMargin:i="0px",threshold:l=0,window:v=M,immediate:u=!0}=t,f=Le(()=>v&&"IntersectionObserver"in v),s=I(()=>{const c=T(e);return(Array.isArray(c)?c:[c]).map(P).filter(ve)});let a=_;const d=D(u),h=f.value?J(()=>[s.value,P(o),d.value],([c,w])=>{if(a(),!d.value||!c.length)return;const y=new IntersectionObserver(n,{root:P(w),rootMargin:i,threshold:l});c.forEach(S=>S&&y.observe(S)),a=()=>{y.disconnect(),a=_}},{immediate:u,flush:"post"}):_,r=()=>{a(),h(),d.value=!1};return te(r),{isSupported:f,isActive:d,pause(){a(),d.value=!1},resume(){d.value=!0},stop:r}}function Ne(e,n={}){const{window:t=M,scrollTarget:o,threshold:i=0}=n,l=D(!1);return Ce(e,v=>{let u=l.value,f=0;for(const s of v)s.time>=f&&(f=s.time,u=s.isIntersecting);l.value=u},{root:o,window:t,threshold:i}),l}function je(e){return typeof Window<"u"&&e instanceof Window?e.document.documentElement:typeof Document<"u"&&e instanceof Document?e.documentElement:e}const $=1;function xe(e,n={}){const{throttle:t=0,idle:o=200,onStop:i=_,onScroll:l=_,offset:v={left:0,right:0,top:0,bottom:0},eventListenerOptions:u={capture:!1,passive:!0},behavior:f="auto",window:s=M,onError:a=p=>{console.error(p)}}=n,d=D(0),h=D(0),r=I({get(){return d.value},set(p){w(p,void 0)}}),c=I({get(){return h.value},set(p){w(void 0,p)}});function w(p,O){var A,m,g,b;if(!s)return;const L=T(e);if(!L)return;(g=L instanceof Document?s.document.body:L)==null||g.scrollTo({top:(A=T(O))!=null?A:c.value,left:(m=T(p))!=null?m:r.value,behavior:T(f)});const j=((b=L==null?void 0:L.document)==null?void 0:b.documentElement)||(L==null?void 0:L.documentElement)||L;r!=null&&(d.value=j.scrollLeft),c!=null&&(h.value=j.scrollTop)}const y=D(!1),S=k({left:!0,right:!1,top:!0,bottom:!1}),E=k({left:!1,right:!1,top:!1,bottom:!1}),C=p=>{y.value&&(y.value=!1,E.left=!1,E.right=!1,E.top=!1,E.bottom=!1,i(p))},x=Ee(C,t+o),N=p=>{var O;if(!s)return;const A=((O=p==null?void 0:p.document)==null?void 0:O.documentElement)||(p==null?void 0:p.documentElement)||P(p),{display:m,flexDirection:g}=getComputedStyle(A),b=A.scrollLeft;E.left=bd.value;const L=Math.abs(b)<=(v.left||0),j=Math.abs(b)+A.clientWidth>=A.scrollWidth-(v.right||0)-$;m==="flex"&&g==="row-reverse"?(S.left=j,S.right=L):(S.left=L,S.right=j),d.value=b;let F=A.scrollTop;p===s.document&&!F&&(F=s.document.body.scrollTop),E.top=Fh.value;const G=Math.abs(F)<=(v.top||0),q=Math.abs(F)+A.clientHeight>=A.scrollHeight-(v.bottom||0)-$;m==="flex"&&g==="column-reverse"?(S.top=q,S.bottom=G):(S.top=G,S.bottom=q),h.value=F},H=p=>{var O;if(!s)return;const A=(O=p.target.documentElement)!=null?O:p.target;N(A),y.value=!0,x(p),l(p)};return W(e,"scroll",t?Te(H,t,!0,!1):H,u),ie(()=>{try{const p=T(e);if(!p)return;N(p)}catch(p){a(p)}}),W(e,"scrollend",C,u),{x:r,y:c,isScrolling:y,arrivedState:S,directions:E,measure(){const p=T(e);s&&p&&N(p)}}}function ke(e,n,t={}){var o;const{direction:i="bottom",interval:l=100,canLoadMore:v=()=>!0}=t,u=k(xe(e,{...t,offset:{[i]:(o=t.distance)!=null?o:0,...t.offset}})),f=D(),s=I(()=>!!f.value),a=I(()=>je(T(e))),d=Ne(a);function h(){if(u.measure(),!a.value||!d.value||!v(a.value))return;const{scrollHeight:c,clientHeight:w,scrollWidth:y,clientWidth:S}=a.value,E=i==="bottom"||i==="top"?c<=w:y<=S;(u.arrivedState[i]||E)&&(f.value||(f.value=Promise.all([n(u),new Promise(C=>setTimeout(C,l))]).finally(()=>{f.value=null,z(()=>h())})))}const r=J(()=>[u.arrivedState[i],d.value],h,{immediate:!0});return Oe(r),{isLoading:s,reset(){z(()=>h())}}}function Be(e,n,t={}){const{window:o=M}=t;return le(e,n,o==null?void 0:o.localStorage,t)}function Ge(e,n,t={}){const{window:o=M}=t;return le(e,n,o==null?void 0:o.sessionStorage,t)}export{Ge as a,le as b,Re as c,Ve as d,Je as e,Ce as f,ke as g,Ee as h,ze as o,Be as u};