import{ah as W,ai as $,J as v,b as E,a5 as T}from"./entry.0e219eb9.js";var N;const w=typeof window<"u",j=e=>typeof e=="string",O=()=>{};w&&((N=window==null?void 0:window.navigator)!=null&&N.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function P(e){return W()?($(e),!0):!1}function C(e,n,i={}){const{immediate:t=!0}=i,o=v(!1);let r=null;function a(){r&&(clearTimeout(r),r=null)}function l(){o.value=!1,a()}function u(...d){a(),o.value=!0,r=setTimeout(()=>{o.value=!1,r=null,e(...d)},E(n))}return t&&(o.value=!0,w&&u()),P(l),{isPending:o,start:u,stop:l}}function f(e){var n;const i=E(e);return(n=i==null?void 0:i.$el)!=null?n:i}const R=w?window:void 0;w&&window.document;const F=w?window.navigator:void 0;w&&window.location;function b(...e){let n,i,t,o;if(j(e[0])?([i,t,o]=e,n=R):[n,i,t,o]=e,!n)return O;let r=O;const a=T(()=>f(n),u=>{r(),u&&(u.addEventListener(i,t,o),r=()=>{u.removeEventListener(i,t,o),r=O})},{immediate:!0,flush:"post"}),l=()=>{a(),r()};return P(l),l}function G(e,n,i={}){const{window:t=R,ignore:o,capture:r=!0,detectIframe:a=!1}=i;if(!t)return;const l=v(!0);let u;const d=s=>{t.clearTimeout(u);const c=f(e),m=s.composedPath();!c||c===s.target||m.includes(c)||!l.value||o&&o.length>0&&o.some(L=>{const g=f(L);return g&&(s.target===g||m.includes(g))})||n(s)},p=[b(t,"click",d,{passive:!0,capture:r}),b(t,"pointerdown",s=>{const c=f(e);l.value=!!c&&!s.composedPath().includes(c)},{passive:!0}),b(t,"pointerup",s=>{if(s.button===0){const c=s.composedPath();s.composedPath=()=>c,u=t.setTimeout(()=>d(s),50)}},{passive:!0}),a&&b(t,"blur",s=>{var c;const m=f(e);((c=document.activeElement)==null?void 0:c.tagName)==="IFRAME"&&!(m!=null&&m.contains(document.activeElement))&&n(s)})].filter(Boolean);return()=>p.forEach(s=>s())}function H(e={}){const{navigator:n=F,read:i=!1,source:t,copiedDuring:o=1500}=e,r=["copy","cut"],a=Boolean(n&&"clipboard"in n),l=v(""),u=v(!1),d=C(()=>u.value=!1,o);function p(){n.clipboard.readText().then(s=>{l.value=s})}if(a&&i)for(const s of r)b(s,p);async function h(s=E(t)){a&&s!=null&&(await n.clipboard.writeText(s),l.value=s,u.value=!0,d.start())}return{isSupported:a,text:l,copied:u,copy:h}}const _=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},y="__vueuse_ssr_handlers__";_[y]=_[y]||{};_[y];var x=Object.getOwnPropertySymbols,k=Object.prototype.hasOwnProperty,A=Object.prototype.propertyIsEnumerable,S=(e,n)=>{var i={};for(var t in e)k.call(e,t)&&n.indexOf(t)<0&&(i[t]=e[t]);if(e!=null&&x)for(var t of x(e))n.indexOf(t)<0&&A.call(e,t)&&(i[t]=e[t]);return i};function B(e,n,i={}){const t=i,{window:o=R}=t,r=S(t,["window"]);let a;const l=o&&"ResizeObserver"in o,u=()=>{a&&(a.disconnect(),a=void 0)},d=T(()=>f(e),h=>{u(),l&&o&&h&&(a=new ResizeObserver(n),a.observe(h,r))},{immediate:!0,flush:"post"}),p=()=>{u(),d()};return P(p),{isSupported:l,stop:p}}function U(e,n={width:0,height:0},i={}){const t=v(n.width),o=v(n.height);return B(e,([r])=>{t.value=r.contentRect.width,o.value=r.contentRect.height},i),T(()=>f(e),r=>{t.value=r?n.width:0,o.value=r?n.height:0}),{width:t,height:o}}var I;(function(e){e.UP="UP",e.RIGHT="RIGHT",e.DOWN="DOWN",e.LEFT="LEFT",e.NONE="NONE"})(I||(I={}));export{U as a,G as o,H as u};
