You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

6 lines
19 KiB

/**
* @vue/reactivity v3.5.5
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/var VueReactivity=function(e){"use strict";let t,i,s,r;let n={},l=()=>{},a=Object.assign,o=(e,t)=>{let i=e.indexOf(t);i>-1&&e.splice(i,1)},u=Object.prototype.hasOwnProperty,c=(e,t)=>u.call(e,t),f=Array.isArray,h=e=>"[object Map]"===R(e),p=e=>"[object Set]"===R(e),d=e=>"function"==typeof e,_=e=>"string"==typeof e,v=e=>"symbol"==typeof e,g=e=>null!==e&&"object"==typeof e,y=Object.prototype.toString,R=e=>y.call(e),b=e=>R(e).slice(8,-1),w=e=>"[object Object]"===R(e),S=e=>_(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,E=(e,t)=>!Object.is(e,t),x=(e,t,i,s=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:s,value:i})};class T{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=t,!e&&t&&(this.index=(t.scopes||(t.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){let e,t;if(this._isPaused=!0,this.scopes)for(e=0,t=this.scopes.length;e<t;e++)this.scopes[e].pause();for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){let e,t;if(this._isPaused=!1,this.scopes)for(e=0,t=this.scopes.length;e<t;e++)this.scopes[e].resume();for(e=0,t=this.effects.length;e<t;e++)this.effects[e].resume()}}run(e){if(this._active){let i=t;try{return t=this,e()}finally{t=i}}}on(){t=this}off(){t=this.parent}stop(e){if(this._active){let t,i;for(t=0,i=this.effects.length;t<i;t++)this.effects[t].stop();for(t=0,i=this.cleanups.length;t<i;t++)this.cleanups[t]();if(this.scopes)for(t=0,i=this.scopes.length;t<i;t++)this.scopes[t].stop(!0);if(!this.detached&&this.parent&&!e){let e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0,this._active=!1}}}let m=/* @__PURE__ */new WeakSet;class A{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.nextEffect=void 0,this.cleanup=void 0,this.scheduler=void 0,t&&t.active&&t.effects.push(this)}pause(){this.flags|=64}resume(){64&this.flags&&(this.flags&=-65,m.has(this)&&(m.delete(this),this.trigger()))}notify(){(!(2&this.flags)||32&this.flags)&&(8&this.flags||(this.flags|=8,this.nextEffect=s,s=this))}run(){if(!(1&this.flags))return this.fn();this.flags|=2,K(this),O(this);let e=i,t=P;i=this,P=!0;try{return this.fn()}finally{I(this),i=e,P=t,this.flags&=-3}}stop(){if(1&this.flags){for(let e=this.deps;e;e=e.nextDep)C(e);this.deps=this.depsTail=void 0,K(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){64&this.flags?m.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){L(this)&&this.run()}get dirty(){return L(this)}}let k=0;function D(){let e;if(!(--k>0)){for(;s;){let t=s;for(s=void 0;t;){let i=t.nextEffect;if(t.nextEffect=void 0,t.flags&=-9,1&t.flags)try{t.trigger()}catch(t){e||(e=t)}t=i}}if(e)throw e}}function O(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function I(e){let t;let i=e.depsTail,s=i;for(;s;){let e=s.prevDep;-1===s.version?(s===i&&(i=e),C(s),function(e){let{prevDep:t,nextDep:i}=e;t&&(t.nextDep=i,e.prevDep=void 0),i&&(i.prevDep=t,e.nextDep=void 0)}(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=e}e.deps=t,e.depsTail=i}function L(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&j(t.dep.computed)||t.dep.version!==t.version)return!0;return!!e._dirty}function j(e){if(4&e.flags&&!(16&e.flags)||(e.flags&=-17,e.globalVersion===M))return;e.globalVersion=M;let t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&!L(e)){e.flags&=-3;return}let s=i,r=P;i=e,P=!0;try{O(e);let i=e.fn(e._value);(0===t.version||E(i,e._value))&&(e._value=i,t.version++)}catch(e){throw t.version++,e}finally{i=s,P=r,I(e),e.flags&=-3}}function C(e){let{dep:t,prevSub:i,nextSub:s}=e;if(i&&(i.nextSub=s,e.prevSub=void 0),s&&(s.prevSub=i,e.nextSub=void 0),t.subs===e&&(t.subs=i),!t.subs&&t.computed){t.computed.flags&=-5;for(let e=t.computed.deps;e;e=e.nextDep)C(e)}}let P=!0,W=[];function N(){W.push(P),P=!1}function V(){let e=W.pop();P=void 0===e||e}function K(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=i;i=void 0;try{t()}finally{i=e}}}let M=0;class H{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class U{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0}track(e){if(!i||!P||i===this.computed)return;let t=this.activeLink;if(void 0===t||t.sub!==i)t=this.activeLink=new H(i,this),i.deps?(t.prevDep=i.depsTail,i.depsTail.nextDep=t,i.depsTail=t):i.deps=i.depsTail=t,4&i.flags&&function e(t){let i=t.dep.computed;if(i&&!t.dep.subs){i.flags|=20;for(let t=i.deps;t;t=t.nextDep)e(t)}let s=t.dep.subs;s!==t&&(t.prevSub=s,s&&(s.nextSub=t)),t.dep.subs=t}(t);else if(-1===t.version&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=i.depsTail,t.nextDep=void 0,i.depsTail.nextDep=t,i.depsTail=t,i.deps===t&&(i.deps=e)}return t}trigger(e){this.version++,M++,this.notify(e)}notify(e){k++;try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()}finally{D()}}}let Y=/* @__PURE__ */new WeakMap,G=Symbol(""),z=Symbol(""),F=Symbol("");function B(e,t,s){if(P&&i){let t=Y.get(e);t||Y.set(e,t=/* @__PURE__ */new Map);let i=t.get(s);i||t.set(s,i=new U),i.track()}}function q(e,t,i,s,r,n){let l=Y.get(e);if(!l){M++;return}let a=e=>{e&&e.trigger()};if(k++,"clear"===t)l.forEach(a);else{let r=f(e),n=r&&S(i);if(r&&"length"===i){let e=Number(s);l.forEach((t,i)=>{("length"===i||i===F||!v(i)&&i>=e)&&a(t)})}else switch(void 0!==i&&a(l.get(i)),n&&a(l.get(F)),t){case"add":r?n&&a(l.get("length")):(a(l.get(G)),h(e)&&a(l.get(z)));break;case"delete":!r&&(a(l.get(G)),h(e)&&a(l.get(z)));break;case"set":h(e)&&a(l.get(G))}}D()}function J(e){let t=eF(e);return t===e?t:(B(t,"iterate",F),eG(e)?t:t.map(eB))}function Q(e){return B(e=eF(e),"iterate",F),e}let X={__proto__:null,[Symbol.iterator](){return Z(this,Symbol.iterator,eB)},concat(...e){return J(this).concat(...e.map(e=>f(e)?J(e):e))},entries(){return Z(this,"entries",e=>(e[1]=eB(e[1]),e))},every(e,t){return ee(this,"every",e,t,void 0,arguments)},filter(e,t){return ee(this,"filter",e,t,e=>e.map(eB),arguments)},find(e,t){return ee(this,"find",e,t,eB,arguments)},findIndex(e,t){return ee(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return ee(this,"findLast",e,t,eB,arguments)},findLastIndex(e,t){return ee(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return ee(this,"forEach",e,t,void 0,arguments)},includes(...e){return ei(this,"includes",e)},indexOf(...e){return ei(this,"indexOf",e)},join(e){return J(this).join(e)},lastIndexOf(...e){return ei(this,"lastIndexOf",e)},map(e,t){return ee(this,"map",e,t,void 0,arguments)},pop(){return es(this,"pop")},push(...e){return es(this,"push",e)},reduce(e,...t){return et(this,"reduce",e,t)},reduceRight(e,...t){return et(this,"reduceRight",e,t)},shift(){return es(this,"shift")},some(e,t){return ee(this,"some",e,t,void 0,arguments)},splice(...e){return es(this,"splice",e)},toReversed(){return J(this).toReversed()},toSorted(e){return J(this).toSorted(e)},toSpliced(...e){return J(this).toSpliced(...e)},unshift(...e){return es(this,"unshift",e)},values(){return Z(this,"values",eB)}};function Z(e,t,i){let s=Q(e),r=s[t]();return s===e||eG(e)||(r._next=r.next,r.next=()=>{let e=r._next();return e.value&&(e.value=i(e.value)),e}),r}let $=Array.prototype;function ee(e,t,i,s,r,n){let l=Q(e),a=l!==e&&!eG(e),o=l[t];if(o!==$[t]){let t=o.apply(e,n);return a?eB(t):t}let u=i;l!==e&&(a?u=function(t,s){return i.call(this,eB(t),s,e)}:i.length>2&&(u=function(t,s){return i.call(this,t,s,e)}));let c=o.call(l,u,s);return a&&r?r(c):c}function et(e,t,i,s){let r=Q(e),n=i;return r!==e&&(eG(e)?i.length>3&&(n=function(t,s,r){return i.call(this,t,s,r,e)}):n=function(t,s,r){return i.call(this,t,eB(s),r,e)}),r[t](n,...s)}function ei(e,t,i){let s=eF(e);B(s,"iterate",F);let r=s[t](...i);return(-1===r||!1===r)&&ez(i[0])?(i[0]=eF(i[0]),s[t](...i)):r}function es(e,t,i=[]){N(),k++;let s=eF(e)[t].apply(e,i);return D(),V(),s}let er=/* @__PURE__ *//*! #__NO_SIDE_EFFECTS__ */function(e){let t=/* @__PURE__ */Object.create(null);for(let i of e.split(","))t[i]=1;return e=>e in t}("__proto__,__v_isRef,__isVue"),en=new Set(/* @__PURE__ */Object.getOwnPropertyNames(Symbol).filter(e=>"arguments"!==e&&"caller"!==e).map(e=>Symbol[e]).filter(v));function el(e){v(e)||(e=String(e));let t=eF(this);return B(t,"has",e),t.hasOwnProperty(e)}class ea{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,i){let s=this._isReadonly,r=this._isShallow;if("__v_isReactive"===t)return!s;if("__v_isReadonly"===t)return s;if("__v_isShallow"===t)return r;if("__v_raw"===t)return i===(s?r?eV:eN:r?eW:eP).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(i)?e:void 0;let n=f(e);if(!s){let e;if(n&&(e=X[t]))return e;if("hasOwnProperty"===t)return el}let l=Reflect.get(e,t,eJ(e)?e:i);return(v(t)?en.has(t):er(t))?l:(s||B(e,"get",t),r)?l:eJ(l)?n&&S(t)?l:l.value:g(l)?s?eM(l):eK(l):l}}class eo extends ea{constructor(e=!1){super(!1,e)}set(e,t,i,s){let r=e[t];if(!this._isShallow){let t=eY(r);if(eG(i)||eY(i)||(r=eF(r),i=eF(i)),!f(e)&&eJ(r)&&!eJ(i))return!t&&(r.value=i,!0)}let n=f(e)&&S(t)?Number(t)<e.length:c(e,t),l=Reflect.set(e,t,i,eJ(e)?e:s);return e===eF(s)&&(n?E(i,r)&&q(e,"set",t,i):q(e,"add",t,i)),l}deleteProperty(e,t){let i=c(e,t);e[t];let s=Reflect.deleteProperty(e,t);return s&&i&&q(e,"delete",t,void 0),s}has(e,t){let i=Reflect.has(e,t);return v(t)&&en.has(t)||B(e,"has",t),i}ownKeys(e){return B(e,"iterate",f(e)?"length":G),Reflect.ownKeys(e)}}class eu extends ea{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}}let ec=/* @__PURE__ */new eo,ef=/* @__PURE__ */new eu,eh=/* @__PURE__ */new eo(!0),ep=/* @__PURE__ */new eu(!0),ed=e=>e,e_=e=>Reflect.getPrototypeOf(e);function ev(e,t,i=!1,s=!1){let r=eF(e=e.__v_raw),n=eF(t);i||(E(t,n)&&B(r,"get",t),B(r,"get",n));let{has:l}=e_(r),a=s?ed:i?eq:eB;return l.call(r,t)?a(e.get(t)):l.call(r,n)?a(e.get(n)):void(e!==r&&e.get(t))}function eg(e,t=!1){let i=this.__v_raw,s=eF(i),r=eF(e);return t||(E(e,r)&&B(s,"has",e),B(s,"has",r)),e===r?i.has(e):i.has(e)||i.has(r)}function ey(e,t=!1){return e=e.__v_raw,t||B(eF(e),"iterate",G),Reflect.get(e,"size",e)}function eR(e,t=!1){t||eG(e)||eY(e)||(e=eF(e));let i=eF(this);return e_(i).has.call(i,e)||(i.add(e),q(i,"add",e,e)),this}function eb(e,t,i=!1){i||eG(t)||eY(t)||(t=eF(t));let s=eF(this),{has:r,get:n}=e_(s),l=r.call(s,e);l||(e=eF(e),l=r.call(s,e));let a=n.call(s,e);return s.set(e,t),l?E(t,a)&&q(s,"set",e,t):q(s,"add",e,t),this}function ew(e){let t=eF(this),{has:i,get:s}=e_(t),r=i.call(t,e);r||(e=eF(e),r=i.call(t,e)),s&&s.call(t,e);let n=t.delete(e);return r&&q(t,"delete",e,void 0),n}function eS(){let e=eF(this),t=0!==e.size,i=e.clear();return t&&q(e,"clear",void 0,void 0),i}function eE(e,t){return function(i,s){let r=this,n=r.__v_raw,l=eF(n),a=t?ed:e?eq:eB;return e||B(l,"iterate",G),n.forEach((e,t)=>i.call(s,a(e),a(t),r))}}function ex(e,t,i){return function(...s){let r=this.__v_raw,n=eF(r),l=h(n),a="entries"===e||e===Symbol.iterator&&l,o=r[e](...s),u=i?ed:t?eq:eB;return t||B(n,"iterate","keys"===e&&l?z:G),{next(){let{value:e,done:t}=o.next();return t?{value:e,done:t}:{value:a?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function eT(e){return function(...t){return"delete"!==e&&("clear"===e?void 0:this)}}let[em,eA,ek,eD]=/* @__PURE__ */function(){let e={get(e){return ev(this,e)},get size(){return ey(this)},has:eg,add:eR,set:eb,delete:ew,clear:eS,forEach:eE(!1,!1)},t={get(e){return ev(this,e,!1,!0)},get size(){return ey(this)},has:eg,add(e){return eR.call(this,e,!0)},set(e,t){return eb.call(this,e,t,!0)},delete:ew,clear:eS,forEach:eE(!1,!0)},i={get(e){return ev(this,e,!0)},get size(){return ey(this,!0)},has(e){return eg.call(this,e,!0)},add:eT("add"),set:eT("set"),delete:eT("delete"),clear:eT("clear"),forEach:eE(!0,!1)},s={get(e){return ev(this,e,!0,!0)},get size(){return ey(this,!0)},has(e){return eg.call(this,e,!0)},add:eT("add"),set:eT("set"),delete:eT("delete"),clear:eT("clear"),forEach:eE(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(r=>{e[r]=ex(r,!1,!1),i[r]=ex(r,!0,!1),t[r]=ex(r,!1,!0),s[r]=ex(r,!0,!0)}),[e,i,t,s]}();function eO(e,t){let i=t?e?eD:ek:e?eA:em;return(t,s,r)=>"__v_isReactive"===s?!e:"__v_isReadonly"===s?e:"__v_raw"===s?t:Reflect.get(c(i,s)&&s in t?i:t,s,r)}let eI={get:/* @__PURE__ */eO(!1,!1)},eL={get:/* @__PURE__ */eO(!1,!0)},ej={get:/* @__PURE__ */eO(!0,!1)},eC={get:/* @__PURE__ */eO(!0,!0)},eP=/* @__PURE__ */new WeakMap,eW=/* @__PURE__ */new WeakMap,eN=/* @__PURE__ */new WeakMap,eV=/* @__PURE__ */new WeakMap;function eK(e){return eY(e)?e:eH(e,!1,ec,eI,eP)}function eM(e){return eH(e,!0,ef,ej,eN)}function eH(e,t,i,s,r){if(!g(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;let n=r.get(e);if(n)return n;let l=e.__v_skip||!Object.isExtensible(e)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}(b(e));if(0===l)return e;let a=new Proxy(e,2===l?s:i);return r.set(e,a),a}function eU(e){return eY(e)?eU(e.__v_raw):!!(e&&e.__v_isReactive)}function eY(e){return!!(e&&e.__v_isReadonly)}function eG(e){return!!(e&&e.__v_isShallow)}function ez(e){return!!e&&!!e.__v_raw}function eF(e){let t=e&&e.__v_raw;return t?eF(t):e}let eB=e=>g(e)?eK(e):e,eq=e=>g(e)?eM(e):e;function eJ(e){return!!e&&!0===e.__v_isRef}function eQ(e){return eX(e,!1)}function eX(e,t){return eJ(e)?e:new eZ(e,t)}class eZ{constructor(e,t){this.dep=new U,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:eF(e),this._value=t?e:eB(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,i=this.__v_isShallow||eG(e)||eY(e);E(e=i?e:eF(e),t)&&(this._rawValue=e,this._value=i?e:eB(e),this.dep.trigger())}}function e$(e){return eJ(e)?e.value:e}let e0={get:(e,t,i)=>"__v_raw"===t?e:e$(Reflect.get(e,t,i)),set:(e,t,i,s)=>{let r=e[t];return eJ(r)&&!eJ(i)?(r.value=i,!0):Reflect.set(e,t,i,s)}};class e1{constructor(e){this.__v_isRef=!0,this._value=void 0;let t=this.dep=new U,{get:i,set:s}=e(t.track.bind(t),t.trigger.bind(t));this._get=i,this._set=s}get value(){return this._value=this._get()}set value(e){this._set(e)}}class e2{constructor(e,t,i){this._object=e,this._key=t,this._defaultValue=i,this.__v_isRef=!0,this._value=void 0}get value(){let e=this._object[this._key];return this._value=void 0===e?this._defaultValue:e}set value(e){this._object[this._key]=e}get dep(){var e,t,i;return e=eF(this._object),t=this._key,null==(i=Y.get(e))?void 0:i.get(t)}}class e4{constructor(e){this._getter=e,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function e3(e,t,i){let s=e[t];return eJ(s)?s:new e2(e,t,i)}class e6{constructor(e,t,i){this.fn=e,this.setter=t,this._value=void 0,this.dep=new U(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=M-1,this.effect=this,this.__v_isReadonly=!t,this.isSSR=i}notify(){this.flags|=16,i!==this&&this.dep.notify()}get value(){let e=this.dep.track();return j(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}}let e8={},e5=/* @__PURE__ */new WeakMap;function e7(e,t=!1,i=r){if(i){let t=e5.get(i);t||e5.set(i,t=[]),t.push(e)}}function e9(e,t=1/0,i){if(t<=0||!g(e)||e.__v_skip||(i=i||/* @__PURE__ */new Set).has(e))return e;if(i.add(e),t--,eJ(e))e9(e.value,t,i);else if(f(e))for(let s=0;s<e.length;s++)e9(e[s],t,i);else if(p(e)||h(e))e.forEach(e=>{e9(e,t,i)});else if(w(e)){for(let s in e)e9(e[s],t,i);for(let s of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,s)&&e9(e[s],t,i)}return e}return e.ARRAY_ITERATE_KEY=F,e.EffectFlags={ACTIVE:1,1:"ACTIVE",RUNNING:2,2:"RUNNING",TRACKING:4,4:"TRACKING",NOTIFIED:8,8:"NOTIFIED",DIRTY:16,16:"DIRTY",ALLOW_RECURSE:32,32:"ALLOW_RECURSE",PAUSED:64,64:"PAUSED"},e.EffectScope=T,e.ITERATE_KEY=G,e.MAP_KEY_ITERATE_KEY=z,e.ReactiveEffect=A,e.ReactiveFlags={SKIP:"__v_skip",IS_REACTIVE:"__v_isReactive",IS_READONLY:"__v_isReadonly",IS_SHALLOW:"__v_isShallow",RAW:"__v_raw",IS_REF:"__v_isRef"},e.TrackOpTypes={GET:"get",HAS:"has",ITERATE:"iterate"},e.TriggerOpTypes={SET:"set",ADD:"add",DELETE:"delete",CLEAR:"clear"},e.WatchErrorCodes={WATCH_GETTER:2,2:"WATCH_GETTER",WATCH_CALLBACK:3,3:"WATCH_CALLBACK",WATCH_CLEANUP:4,4:"WATCH_CLEANUP"},e.computed=function(e,t,i=!1){let s,r;return d(e)?s=e:(s=e.get,r=e.set),new e6(s,r,i)},e.customRef=function(e){return new e1(e)},e.effect=function(e,t){e.effect instanceof A&&(e=e.effect.fn);let i=new A(e);t&&a(i,t);try{i.run()}catch(e){throw i.stop(),e}let s=i.run.bind(i);return s.effect=i,s},e.effectScope=function(e){return new T(e)},e.enableTracking=function(){W.push(P),P=!0},e.getCurrentScope=function(){return t},e.getCurrentWatcher=function(){return r},e.isProxy=ez,e.isReactive=eU,e.isReadonly=eY,e.isRef=eJ,e.isShallow=eG,e.markRaw=function(e){return!c(e,"__v_skip")&&Object.isExtensible(e)&&x(e,"__v_skip",!0),e},e.onEffectCleanup=function(e,t=!1){i instanceof A&&(i.cleanup=e)},e.onScopeDispose=function(e,i=!1){t&&t.cleanups.push(e)},e.onWatcherCleanup=e7,e.pauseTracking=N,e.proxyRefs=function(e){return eU(e)?e:new Proxy(e,e0)},e.reactive=eK,e.reactiveReadArray=J,e.readonly=eM,e.ref=eQ,e.resetTracking=V,e.shallowReactive=function(e){return eH(e,!1,eh,eL,eW)},e.shallowReadArray=Q,e.shallowReadonly=function(e){return eH(e,!0,ep,eC,eV)},e.shallowRef=function(e){return eX(e,!0)},e.stop=function(e){e.effect.stop()},e.toRaw=eF,e.toReactive=eB,e.toReadonly=eq,e.toRef=function(e,t,i){return eJ(e)?e:d(e)?new e4(e):g(e)&&arguments.length>1?e3(e,t,i):eQ(e)},e.toRefs=function(e){let t=f(e)?Array(e.length):{};for(let i in e)t[i]=e3(e,i);return t},e.toValue=function(e){return d(e)?e():e$(e)},e.track=B,e.traverse=e9,e.trigger=q,e.triggerRef=function(e){e.dep.trigger()},e.unref=e$,e.watch=function(e,i,s=n){let a,u,c,h;let{immediate:p,deep:_,once:v,scheduler:g,augmentJob:y,call:R}=s,b=e=>_?e:eG(e)||!1===_||0===_?e9(e,1):e9(e),w=!1,S=!1;if(eJ(e)?(u=()=>e.value,w=eG(e)):eU(e)?(u=()=>b(e),w=!0):f(e)?(S=!0,w=e.some(e=>eU(e)||eG(e)),u=()=>e.map(e=>eJ(e)?e.value:eU(e)?b(e):d(e)?R?R(e,2):e():void 0)):u=d(e)?i?R?()=>R(e,2):e:()=>{if(c){N();try{c()}finally{V()}}let t=r;r=a;try{return R?R(e,3,[h]):e(h)}finally{r=t}}:l,i&&_){let e=u,t=!0===_?1/0:_;u=()=>e9(e(),t)}let x=t,T=()=>{a.stop(),x&&o(x.effects,a)};if(v){if(i){let e=i;i=(...t)=>{e(...t),T()}}else{let e=u;u=()=>{e(),T()}}}let m=S?Array(e.length).fill(e8):e8,k=e=>{if(1&a.flags&&(a.dirty||e)){if(i){let e=a.run();if(_||w||(S?e.some((e,t)=>E(e,m[t])):E(e,m))){c&&c();let t=r;r=a;try{let t=[e,m===e8?void 0:S&&m[0]===e8?[]:m,h];R?R(i,3,t):i(...t),m=e}finally{r=t}}}else a.run()}};return y&&y(k),(a=new A(u)).scheduler=g?()=>g(k,!1):k,h=e=>e7(e,!1,a),c=a.onStop=()=>{let e=e5.get(a);if(e){if(R)R(e,4);else for(let t of e)t();e5.delete(a)}},i?p?k(!0):m=a.run():g?g(k.bind(null,!0),!0):a.run(),T.pause=a.pause.bind(a),T.resume=a.resume.bind(a),T.stop=T,T},e}({});