import{ac as V,ad as W,a1 as L,s as $,e as U,r as z,c as b,a7 as E,w,X as A,Z as N,u as D,U as I,t as p,a4 as k,a5 as B,aa as G,v as M,o as J,M as q}from"./index-BhaIiTEj.js";function ae(e,t){var o;const n=$();return U(()=>{n.value=e()},{...t,flush:(o=void 0)!=null?o:"sync"}),z(n)}function x(e){return k()?(B(e),!0):!1}function ce(e){let t=!1,o;const n=W(!0);return(...r)=>(t||(o=n.run(()=>e(...r)),t=!0),o)}function fe(e){let t=0,o,n;const r=()=>{t-=1,n&&t<=0&&(n.stop(),o=void 0,n=void 0)};return(...u)=>(t+=1,n||(n=W(!0),o=n.run(()=>e(...u))),x(r),o)}function X(e){if(!A(e))return N(e);const t=new Proxy({},{get(o,n,r){return D(Reflect.get(e.value,n,r))},set(o,n,r){return A(e.value[n])&&!A(r)?e.value[n].value=r:e.value[n]=r,!0},deleteProperty(o,n){return Reflect.deleteProperty(e.value,n)},has(o,n){return Reflect.has(e.value,n)},ownKeys(){return Object.keys(e.value)},getOwnPropertyDescriptor(){return{enumerable:!0,configurable:!0}}});return N(t)}function Z(e){return X(b(e))}function de(e,...t){const o=t.flat(),n=o[0];return Z(()=>Object.fromEntries(typeof n=="function"?Object.entries(I(e)).filter(([r,u])=>!n(p(u),r)):Object.entries(I(e)).filter(r=>!o.includes(r[0]))))}const K=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const H=e=>typeof e<"u",Q=Object.prototype.toString,Y=e=>Q.call(e)==="[object Object]",F=()=>{},pe=ee();function ee(){var e,t;return K&&((e=window?.navigator)==null?void 0:e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((t=window?.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test(window?.navigator.userAgent))}function te(e){return E()}function j(e){return Array.isArray(e)?e:[e]}function ve(...e){if(e.length!==1)return G(...e);const t=e[0];return typeof t=="function"?z(V(()=>({get:t,set:F}))):M(t)}function me(e,t=1e4){return V((o,n)=>{let r=p(e),u;const i=()=>setTimeout(()=>{r=p(e),n()},p(t));return x(()=>{clearTimeout(u)}),{get(){return o(),r},set(s){r=s,n(),clearTimeout(u),u=i()}}})}function be(e,t){te()&&L(e,t)}function ne(e,t,o){return w(e,t,{...o,immediate:!0})}const R=K?window:void 0;function S(e){var t;const o=p(e);return(t=o?.$el)!=null?t:o}function oe(...e){const t=[],o=()=>{t.forEach(s=>s()),t.length=0},n=(s,l,a,c)=>(s.addEventListener(l,a,c),()=>s.removeEventListener(l,a,c)),r=b(()=>{const s=j(p(e[0])).filter(l=>l!=null);return s.every(l=>typeof l!="string")?s:void 0}),u=ne(()=>{var s,l;return[(l=(s=r.value)==null?void 0:s.map(a=>S(a)))!=null?l:[R].filter(a=>a!=null),j(p(r.value?e[1]:e[0])),j(D(r.value?e[2]:e[1])),p(r.value?e[3]:e[2])]},([s,l,a,c])=>{if(o(),!s?.length||!l?.length||!a?.length)return;const v=Y(c)?{...c}:c;t.push(...s.flatMap(m=>l.flatMap(f=>a.map(y=>n(m,f,y,v)))))},{flush:"post"}),i=()=>{u(),o()};return x(o),i}function re(){const e=$(!1),t=E();return t&&J(()=>{e.value=!0},t),e}function se(e){const t=re();return b(()=>(t.value,!!e()))}function ie(e){return typeof e=="function"?e:typeof e=="string"?t=>t.key===e:Array.isArray(e)?t=>e.includes(t.key):()=>!0}function ye(...e){let t,o,n={};e.length===3?(t=e[0],o=e[1],n=e[2]):e.length===2?typeof e[1]=="object"?(t=!0,o=e[0],n=e[1]):(t=e[0],o=e[1]):(t=!0,o=e[0]);const{target:r=R,eventName:u="keydown",passive:i=!1,dedupe:s=!1}=n,l=ie(t);return oe(r,u,c=>{c.repeat&&p(s)||l(c)&&o(c)},i)}function ue(e){return JSON.parse(JSON.stringify(e))}function ge(e,t,o={}){const{window:n=R,...r}=o;let u;const i=se(()=>n&&"ResizeObserver"in n),s=()=>{u&&(u.disconnect(),u=void 0)},l=b(()=>{const v=p(e);return Array.isArray(v)?v.map(m=>S(m)):[S(v)]}),a=w(l,v=>{if(s(),i.value&&n){u=new ResizeObserver(t);for(const m of v)m&&u.observe(m,r)}},{immediate:!0,flush:"post"}),c=()=>{s(),a()};return x(c),{isSupported:i,stop:c}}function he(e,t,o,n={}){var r,u,i;const{clone:s=!1,passive:l=!1,eventName:a,deep:c=!1,defaultValue:v,shouldEmit:m}=n,f=E(),y=o||f?.emit||((r=f?.$emit)==null?void 0:r.bind(f))||((i=(u=f?.proxy)==null?void 0:u.$emit)==null?void 0:i.bind(f?.proxy));let g=a;t||(t="modelValue"),g=g||`update:${t.toString()}`;const T=d=>s?typeof s=="function"?s(d):ue(d):d,_=()=>H(e[t])?T(e[t]):v,C=d=>{m?m(d)&&y(g,d):y(g,d)};if(l){const d=_(),P=M(d);let h=!1;return w(()=>e[t],O=>{h||(h=!0,P.value=T(O),q(()=>h=!1))}),w(P,O=>{!h&&(O!==e[t]||c)&&C(O)},{deep:c}),P}else return b({get(){return _()},set(d){C(d)}})}function Oe(){const e=E(),t=M(),o=b(()=>["#text","#comment"].includes(t.value?.$el.nodeName)?t.value?.$el.nextElementSibling:S(t)),n=Object.assign({},e.exposed),r={};for(const i in e.props)Object.defineProperty(r,i,{enumerable:!0,configurable:!0,get:()=>e.props[i]});if(Object.keys(n).length>0)for(const i in n)Object.defineProperty(r,i,{enumerable:!0,configurable:!0,get:()=>n[i]});Object.defineProperty(r,"$el",{enumerable:!0,configurable:!0,get:()=>e.vnode.el}),e.exposed=r;function u(i){if(t.value=i,!!i&&(Object.defineProperty(r,"$el",{enumerable:!0,configurable:!0,get:()=>i instanceof Element?i:i.$el}),!(i instanceof Element)&&!Object.hasOwn(i,"$el"))){const s=i.$.exposed,l=Object.assign({},r);for(const a in s)Object.defineProperty(l,a,{enumerable:!0,configurable:!0,get:()=>s[a]});e.exposed=l}}return{forwardRef:u,currentRef:t,currentElement:o}}export{j as a,Y as b,x as c,he as d,S as e,me as f,ge as g,ae as h,K as i,fe as j,be as k,pe as l,oe as m,R as n,ye as o,ce as p,re as q,de as r,ve as t,Oe as u,ne as w};