import{am as T,an as N,ao as I,a3 as U,j as m,h as v,ap as S,aq as j,ar as B,L as M,Q as Y,g as K,as as $,ah as q,at as z,au as C,y as G,av as Q,aw as Z,ax as F,ay as H,S as x,az as E,aA as d}from"./DhlfkVbH.js";import{b as J,g as V}from"./CwfCwap7.js";let _=!1,P=Symbol();function ne(e,r,i){const n=i[r]??(i[r]={store:null,source:U(void 0),unsubscribe:I});if(n.store!==e&&!(P in i))if(n.unsubscribe(),n.store=e??null,e==null)n.source.v=void 0,n.unsubscribe=I;else{var t=!0;n.unsubscribe=J(e,s=>{t?n.source.v=s:m(n.source,s)}),t=!1}return e&&P in i?V(e):v(n.source)}function ie(){const e={};function r(){T(()=>{for(var i in e)e[i].unsubscribe();N(e,P,{enumerable:!1,value:!0})})}return[e,r]}function W(e){var r=_;try{return _=!1,[e(),_]}finally{_=r}}const X={get(e,r){if(!e.exclude.includes(r))return e.props[r]},set(e,r){return!1},getOwnPropertyDescriptor(e,r){if(!e.exclude.includes(r)&&r in e.props)return{enumerable:!0,configurable:!0,value:e.props[r]}},has(e,r){return e.exclude.includes(r)?!1:r in e.props},ownKeys(e){return Reflect.ownKeys(e.props).filter(r=>!e.exclude.includes(r))}};function te(e,r,i){return new Proxy({props:e,exclude:r},X)}const k={get(e,r){let i=e.props.length;for(;i--;){let n=e.props[i];if(d(n)&&(n=n()),typeof n=="object"&&n!==null&&r in n)return n[r]}},set(e,r,i){let n=e.props.length;for(;n--;){let t=e.props[n];d(t)&&(t=t());const s=S(t,r);if(s&&s.set)return s.set(i),!0}return!1},getOwnPropertyDescriptor(e,r){let i=e.props.length;for(;i--;){let n=e.props[i];if(d(n)&&(n=n()),typeof n=="object"&&n!==null&&r in n){const t=S(n,r);return t&&!t.configurable&&(t.configurable=!0),t}}},has(e,r){if(r===x||r===E)return!1;for(let i of e.props)if(d(i)&&(i=i()),i!=null&&r in i)return!0;return!1},ownKeys(e){const r=[];for(let i of e.props)if(d(i)&&(i=i()),!!i){for(const n in i)r.includes(n)||r.push(n);for(const n of Object.getOwnPropertySymbols(i))r.includes(n)||r.push(n)}return r}};function ue(...e){return new Proxy({props:e},k)}function se(e,r,i,n){var y;var t=!Q||(i&Z)!==0,s=(i&C)!==0,R=(i&H)!==0,a=n,b=!0,h=()=>(b&&(b=!1,a=R?G(n):n),a),l;if(s){var A=x in e||E in e;l=((y=S(e,r))==null?void 0:y.set)??(A&&r in e?u=>e[r]=u:void 0)}var o,w=!1;s?[o,w]=W(()=>e[r]):o=e[r],o===void 0&&n!==void 0&&(o=h(),l&&(t&&j(),l(o)));var f;if(t?f=()=>{var u=e[r];return u===void 0?h():(b=!0,u)}:f=()=>{var u=e[r];return u!==void 0&&(a=void 0),u===void 0?a:u},t&&!(i&B))return f;if(l){var D=e.$$legacy;return function(u,p){return arguments.length>0?((!t||!p||D||w)&&l(p?f():u),u):f()}}var g=!1,c=(i&F?M:Y)(()=>(g=!1,f()));s&&v(c);var L=q;return function(u,p){if(arguments.length>0){const O=p?v(c):t&&s?K(u):u;return m(c,O),g=!0,a!==void 0&&(a=O),u}return $&&g||L.f&z?c.v:v(c)}}export{ne as a,ue as b,se as p,te as r,ie as s};
