import{N as G,O as $,x as H,r as T,P as M,Q as w,R as B,S as tt,T as et,U as st,l as nt,n as ot,V as ct,W as D,i as rt}from"./@vue-COImUMPt.js";/*!
 * pinia v3.0.3
 * (c) 2025 Eduardo San Martin Morote
 * @license MIT
 */let J;const E=t=>J=t,K=Symbol();function k(t){return t&&typeof t=="object"&&Object.prototype.toString.call(t)==="[object Object]"&&typeof t.toJSON!="function"}var g;(function(t){t.direct="direct",t.patchObject="patch object",t.patchFunction="patch function"})(g||(g={}));function yt(){const t=M(!0),c=t.run(()=>H({}));let s=[],e=[];const a=D({install(r){E(a),a._a=r,r.provide(K,a),r.config.globalProperties.$pinia=a,e.forEach(u=>s.push(u)),e=[]},use(r){return this._a?s.push(r):e.push(r),this},_p:s,_a:null,_e:t,_s:new Map,state:c});return a}const Q=()=>{};function V(t,c,s,e=Q){t.push(c);const a=()=>{const r=t.indexOf(c);r>-1&&(t.splice(r,1),e())};return!s&&et()&&st(a),a}function O(t,...c){t.slice().forEach(s=>{s(...c)})}const ut=t=>t(),A=Symbol(),I=Symbol();function L(t,c){t instanceof Map&&c instanceof Map?c.forEach((s,e)=>t.set(e,s)):t instanceof Set&&c instanceof Set&&c.forEach(t.add,t);for(const s in c){if(!c.hasOwnProperty(s))continue;const e=c[s],a=t[s];k(a)&&k(e)&&t.hasOwnProperty(s)&&!w(e)&&!B(e)?t[s]=L(a,e):t[s]=e}return t}const at=Symbol();function ft(t){return!k(t)||!Object.prototype.hasOwnProperty.call(t,at)}const{assign:h}=Object;function lt(t){return!!(w(t)&&t.effect)}function it(t,c,s,e){const{state:a,actions:r,getters:u}=c,P=s.state.value[t];let y;function b(){P||(s.state.value[t]=a?a():{});const S=ct(s.state.value[t]);return h(S,r,Object.keys(u||{}).reduce((v,_)=>(v[_]=D(rt(()=>{E(s);const m=s._s.get(t);return u[_].call(m,m)})),v),{}))}return y=U(t,b,c,s,e,!0),y}function U(t,c,s={},e,a,r){let u;const P=h({actions:{}},s),y={deep:!0};let b,S,v=[],_=[],m;const j=e.state.value[t];!r&&!j&&(e.state.value[t]={}),H({});let W;function N(o){let n;b=S=!1,typeof o=="function"?(o(e.state.value[t]),n={type:g.patchFunction,storeId:t,events:m}):(L(e.state.value[t],o),n={type:g.patchObject,payload:o,storeId:t,events:m});const f=W=Symbol();ot().then(()=>{W===f&&(b=!0)}),S=!0,O(v,n,e.state.value[t])}const q=r?function(){const{state:n}=s,f=n?n():{};this.$patch(d=>{h(d,f)})}:Q;function z(){u.stop(),v=[],_=[],e._s.delete(t)}const F=(o,n="")=>{if(A in o)return o[I]=n,o;const f=function(){E(e);const d=Array.from(arguments),C=[],R=[];function Y(l){C.push(l)}function Z(l){R.push(l)}O(_,{args:d,name:f[I],store:i,after:Y,onError:Z});let x;try{x=o.apply(this&&this.$id===t?this:i,d)}catch(l){throw O(R,l),l}return x instanceof Promise?x.then(l=>(O(C,l),l)).catch(l=>(O(R,l),Promise.reject(l))):(O(C,x),x)};return f[A]=!0,f[I]=n,f},X={_p:e,$id:t,$onAction:V.bind(null,_),$patch:N,$reset:q,$subscribe(o,n={}){const f=V(v,o,n.detached,()=>d()),d=u.run(()=>nt(()=>e.state.value[t],C=>{(n.flush==="sync"?S:b)&&o({storeId:t,type:g.direct,events:m},C)},h({},y,n)));return f},$dispose:z},i=T(X);e._s.set(t,i);const p=(e._a&&e._a.runWithContext||ut)(()=>e._e.run(()=>(u=M()).run(()=>c({action:F}))));for(const o in p){const n=p[o];if(w(n)&&!lt(n)||B(n))r||(j&&ft(n)&&(w(n)?n.value=j[o]:L(n,j[o])),e.state.value[t][o]=n);else if(typeof n=="function"){const f=F(n,o);p[o]=f,P.actions[o]=n}}return h(i,p),h(tt(i),p),Object.defineProperty(i,"$state",{get:()=>e.state.value[t],set:o=>{N(n=>{h(n,o)})}}),e._p.forEach(o=>{h(i,u.run(()=>o({store:i,app:e._a,pinia:e,options:P})))}),j&&r&&s.hydrate&&s.hydrate(i.$state,j),b=!0,S=!0,i}/*! #__NO_SIDE_EFFECTS__ */function St(t,c,s){let e;const a=typeof c=="function";e=a?s:c;function r(u,P){const y=$();return u=u||(y?G(K,null):null),u&&E(u),u=J,u._s.has(t)||(a?U(t,c,e,u):it(t,e,u)),u._s.get(t)}return r.$id=t,r}export{yt as c,St as d};
