Subversion Repositories wpShopGermany4

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
8392 daniel 1
function makeMap(str, expectsLowerCase) {
2
  const map = /* @__PURE__ */ Object.create(null);
3
  const list = str.split(",");
4
  for (let i = 0; i < list.length; i++) {
5
    map[list[i]] = true;
6
  }
7
  return expectsLowerCase ? (val) => !!map[val.toLowerCase()] : (val) => !!map[val];
8
}
9
 
10
const EMPTY_OBJ = Object.freeze({}) ;
11
const EMPTY_ARR = Object.freeze([]) ;
12
const NOOP = () => {
13
};
14
const NO = () => false;
15
const onRE = /^on[^a-z]/;
16
const isOn = (key) => onRE.test(key);
17
const isModelListener = (key) => key.startsWith("onUpdate:");
18
const extend = Object.assign;
19
const remove = (arr, el) => {
20
  const i = arr.indexOf(el);
21
  if (i > -1) {
22
    arr.splice(i, 1);
23
  }
24
};
25
const hasOwnProperty$1 = Object.prototype.hasOwnProperty;
26
const hasOwn = (val, key) => hasOwnProperty$1.call(val, key);
27
const isArray = Array.isArray;
28
const isMap = (val) => toTypeString(val) === "[object Map]";
29
const isSet = (val) => toTypeString(val) === "[object Set]";
30
const isDate = (val) => toTypeString(val) === "[object Date]";
31
const isRegExp = (val) => toTypeString(val) === "[object RegExp]";
32
const isFunction = (val) => typeof val === "function";
33
const isString = (val) => typeof val === "string";
34
const isSymbol = (val) => typeof val === "symbol";
35
const isObject = (val) => val !== null && typeof val === "object";
36
const isPromise = (val) => {
37
  return (isObject(val) || isFunction(val)) && isFunction(val.then) && isFunction(val.catch);
38
};
39
const objectToString = Object.prototype.toString;
40
const toTypeString = (value) => objectToString.call(value);
41
const toRawType = (value) => {
42
  return toTypeString(value).slice(8, -1);
43
};
44
const isPlainObject = (val) => toTypeString(val) === "[object Object]";
45
const isIntegerKey = (key) => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key;
46
const isReservedProp = /* @__PURE__ */ makeMap(
47
  // the leading comma is intentional so empty string "" is also included
48
  ",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"
49
);
50
const isBuiltInDirective = /* @__PURE__ */ makeMap(
51
  "bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"
52
);
53
const cacheStringFunction = (fn) => {
54
  const cache = /* @__PURE__ */ Object.create(null);
55
  return (str) => {
56
    const hit = cache[str];
57
    return hit || (cache[str] = fn(str));
58
  };
59
};
60
const camelizeRE = /-(\w)/g;
61
const camelize = cacheStringFunction((str) => {
62
  return str.replace(camelizeRE, (_, c) => c ? c.toUpperCase() : "");
63
});
64
const hyphenateRE = /\B([A-Z])/g;
65
const hyphenate = cacheStringFunction(
66
  (str) => str.replace(hyphenateRE, "-$1").toLowerCase()
67
);
68
const capitalize = cacheStringFunction((str) => {
69
  return str.charAt(0).toUpperCase() + str.slice(1);
70
});
71
const toHandlerKey = cacheStringFunction((str) => {
72
  const s = str ? `on${capitalize(str)}` : ``;
73
  return s;
74
});
75
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
76
const invokeArrayFns = (fns, arg) => {
77
  for (let i = 0; i < fns.length; i++) {
78
    fns[i](arg);
79
  }
80
};
81
const def = (obj, key, value) => {
82
  Object.defineProperty(obj, key, {
83
    configurable: true,
84
    enumerable: false,
85
    value
86
  });
87
};
88
const looseToNumber = (val) => {
89
  const n = parseFloat(val);
90
  return isNaN(n) ? val : n;
91
};
92
const toNumber = (val) => {
93
  const n = isString(val) ? Number(val) : NaN;
94
  return isNaN(n) ? val : n;
95
};
96
let _globalThis;
97
const getGlobalThis = () => {
98
  return _globalThis || (_globalThis = typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : {});
99
};
100
 
101
const PatchFlagNames = {
102
  [1]: `TEXT`,
103
  [2]: `CLASS`,
104
  [4]: `STYLE`,
105
  [8]: `PROPS`,
106
  [16]: `FULL_PROPS`,
107
  [32]: `HYDRATE_EVENTS`,
108
  [64]: `STABLE_FRAGMENT`,
109
  [128]: `KEYED_FRAGMENT`,
110
  [256]: `UNKEYED_FRAGMENT`,
111
  [512]: `NEED_PATCH`,
112
  [1024]: `DYNAMIC_SLOTS`,
113
  [2048]: `DEV_ROOT_FRAGMENT`,
114
  [-1]: `HOISTED`,
115
  [-2]: `BAIL`
116
};
117
 
118
const slotFlagsText = {
119
  [1]: "STABLE",
120
  [2]: "DYNAMIC",
121
  [3]: "FORWARDED"
122
};
123
 
124
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console";
125
const isGloballyAllowed = /* @__PURE__ */ makeMap(GLOBALS_ALLOWED);
126
 
127
const range = 2;
128
function generateCodeFrame(source, start = 0, end = source.length) {
129
  let lines = source.split(/(\r?\n)/);
130
  const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);
131
  lines = lines.filter((_, idx) => idx % 2 === 0);
132
  let count = 0;
133
  const res = [];
134
  for (let i = 0; i < lines.length; i++) {
135
    count += lines[i].length + (newlineSequences[i] && newlineSequences[i].length || 0);
136
    if (count >= start) {
137
      for (let j = i - range; j <= i + range || end > count; j++) {
138
        if (j < 0 || j >= lines.length)
139
          continue;
140
        const line = j + 1;
141
        res.push(
142
          `${line}${" ".repeat(Math.max(3 - String(line).length, 0))}|  ${lines[j]}`
143
        );
144
        const lineLength = lines[j].length;
145
        const newLineSeqLength = newlineSequences[j] && newlineSequences[j].length || 0;
146
        if (j === i) {
147
          const pad = start - (count - (lineLength + newLineSeqLength));
148
          const length = Math.max(
149
            1,
150
            end > count ? lineLength - pad : end - start
151
          );
152
          res.push(`   |  ` + " ".repeat(pad) + "^".repeat(length));
153
        } else if (j > i) {
154
          if (end > count) {
155
            const length = Math.max(Math.min(end - count, lineLength), 1);
156
            res.push(`   |  ` + "^".repeat(length));
157
          }
158
          count += lineLength + newLineSeqLength;
159
        }
160
      }
161
      break;
162
    }
163
  }
164
  return res.join("\n");
165
}
166
 
167
function normalizeStyle(value) {
168
  if (isArray(value)) {
169
    const res = {};
170
    for (let i = 0; i < value.length; i++) {
171
      const item = value[i];
172
      const normalized = isString(item) ? parseStringStyle(item) : normalizeStyle(item);
173
      if (normalized) {
174
        for (const key in normalized) {
175
          res[key] = normalized[key];
176
        }
177
      }
178
    }
179
    return res;
180
  } else if (isString(value) || isObject(value)) {
181
    return value;
182
  }
183
}
184
const listDelimiterRE = /;(?![^(]*\))/g;
185
const propertyDelimiterRE = /:([^]+)/;
186
const styleCommentRE = /\/\*[^]*?\*\//g;
187
function parseStringStyle(cssText) {
188
  const ret = {};
189
  cssText.replace(styleCommentRE, "").split(listDelimiterRE).forEach((item) => {
190
    if (item) {
191
      const tmp = item.split(propertyDelimiterRE);
192
      tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
193
    }
194
  });
195
  return ret;
196
}
197
function normalizeClass(value) {
198
  let res = "";
199
  if (isString(value)) {
200
    res = value;
201
  } else if (isArray(value)) {
202
    for (let i = 0; i < value.length; i++) {
203
      const normalized = normalizeClass(value[i]);
204
      if (normalized) {
205
        res += normalized + " ";
206
      }
207
    }
208
  } else if (isObject(value)) {
209
    for (const name in value) {
210
      if (value[name]) {
211
        res += name + " ";
212
      }
213
    }
214
  }
215
  return res.trim();
216
}
217
function normalizeProps(props) {
218
  if (!props)
219
    return null;
220
  let { class: klass, style } = props;
221
  if (klass && !isString(klass)) {
222
    props.class = normalizeClass(klass);
223
  }
224
  if (style) {
225
    props.style = normalizeStyle(style);
226
  }
227
  return props;
228
}
229
 
230
const HTML_TAGS = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot";
231
const SVG_TAGS = "svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view";
232
const VOID_TAGS = "area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr";
233
const isHTMLTag = /* @__PURE__ */ makeMap(HTML_TAGS);
234
const isSVGTag = /* @__PURE__ */ makeMap(SVG_TAGS);
235
const isVoidTag = /* @__PURE__ */ makeMap(VOID_TAGS);
236
 
237
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
238
const isSpecialBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs);
239
function includeBooleanAttr(value) {
240
  return !!value || value === "";
241
}
242
 
243
function looseCompareArrays(a, b) {
244
  if (a.length !== b.length)
245
    return false;
246
  let equal = true;
247
  for (let i = 0; equal && i < a.length; i++) {
248
    equal = looseEqual(a[i], b[i]);
249
  }
250
  return equal;
251
}
252
function looseEqual(a, b) {
253
  if (a === b)
254
    return true;
255
  let aValidType = isDate(a);
256
  let bValidType = isDate(b);
257
  if (aValidType || bValidType) {
258
    return aValidType && bValidType ? a.getTime() === b.getTime() : false;
259
  }
260
  aValidType = isSymbol(a);
261
  bValidType = isSymbol(b);
262
  if (aValidType || bValidType) {
263
    return a === b;
264
  }
265
  aValidType = isArray(a);
266
  bValidType = isArray(b);
267
  if (aValidType || bValidType) {
268
    return aValidType && bValidType ? looseCompareArrays(a, b) : false;
269
  }
270
  aValidType = isObject(a);
271
  bValidType = isObject(b);
272
  if (aValidType || bValidType) {
273
    if (!aValidType || !bValidType) {
274
      return false;
275
    }
276
    const aKeysCount = Object.keys(a).length;
277
    const bKeysCount = Object.keys(b).length;
278
    if (aKeysCount !== bKeysCount) {
279
      return false;
280
    }
281
    for (const key in a) {
282
      const aHasKey = a.hasOwnProperty(key);
283
      const bHasKey = b.hasOwnProperty(key);
284
      if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b[key])) {
285
        return false;
286
      }
287
    }
288
  }
289
  return String(a) === String(b);
290
}
291
function looseIndexOf(arr, val) {
292
  return arr.findIndex((item) => looseEqual(item, val));
293
}
294
 
295
const toDisplayString = (val) => {
296
  return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? JSON.stringify(val, replacer, 2) : String(val);
297
};
298
const replacer = (_key, val) => {
299
  if (val && val.__v_isRef) {
300
    return replacer(_key, val.value);
301
  } else if (isMap(val)) {
302
    return {
303
      [`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val2]) => {
304
        entries[`${key} =>`] = val2;
305
        return entries;
306
      }, {})
307
    };
308
  } else if (isSet(val)) {
309
    return {
310
      [`Set(${val.size})`]: [...val.values()]
311
    };
312
  } else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {
313
    return String(val);
314
  }
315
  return val;
316
};
317
 
318
function warn$1(msg, ...args) {
319
  console.warn(`[Vue warn] ${msg}`, ...args);
320
}
321
 
322
let activeEffectScope;
323
class EffectScope {
324
  constructor(detached = false) {
325
    this.detached = detached;
326
    /**
327
     * @internal
328
     */
329
    this._active = true;
330
    /**
331
     * @internal
332
     */
333
    this.effects = [];
334
    /**
335
     * @internal
336
     */
337
    this.cleanups = [];
338
    this.parent = activeEffectScope;
339
    if (!detached && activeEffectScope) {
340
      this.index = (activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(
341
        this
342
      ) - 1;
343
    }
344
  }
345
  get active() {
346
    return this._active;
347
  }
348
  run(fn) {
349
    if (this._active) {
350
      const currentEffectScope = activeEffectScope;
351
      try {
352
        activeEffectScope = this;
353
        return fn();
354
      } finally {
355
        activeEffectScope = currentEffectScope;
356
      }
357
    } else {
358
      warn$1(`cannot run an inactive effect scope.`);
359
    }
360
  }
361
  /**
362
   * This should only be called on non-detached scopes
363
   * @internal
364
   */
365
  on() {
366
    activeEffectScope = this;
367
  }
368
  /**
369
   * This should only be called on non-detached scopes
370
   * @internal
371
   */
372
  off() {
373
    activeEffectScope = this.parent;
374
  }
375
  stop(fromParent) {
376
    if (this._active) {
377
      let i, l;
378
      for (i = 0, l = this.effects.length; i < l; i++) {
379
        this.effects[i].stop();
380
      }
381
      for (i = 0, l = this.cleanups.length; i < l; i++) {
382
        this.cleanups[i]();
383
      }
384
      if (this.scopes) {
385
        for (i = 0, l = this.scopes.length; i < l; i++) {
386
          this.scopes[i].stop(true);
387
        }
388
      }
389
      if (!this.detached && this.parent && !fromParent) {
390
        const last = this.parent.scopes.pop();
391
        if (last && last !== this) {
392
          this.parent.scopes[this.index] = last;
393
          last.index = this.index;
394
        }
395
      }
396
      this.parent = void 0;
397
      this._active = false;
398
    }
399
  }
400
}
401
function effectScope(detached) {
402
  return new EffectScope(detached);
403
}
404
function recordEffectScope(effect, scope = activeEffectScope) {
405
  if (scope && scope.active) {
406
    scope.effects.push(effect);
407
  }
408
}
409
function getCurrentScope() {
410
  return activeEffectScope;
411
}
412
function onScopeDispose(fn) {
413
  if (activeEffectScope) {
414
    activeEffectScope.cleanups.push(fn);
415
  } else {
416
    warn$1(
417
      `onScopeDispose() is called when there is no active effect scope to be associated with.`
418
    );
419
  }
420
}
421
 
422
const createDep = (effects) => {
423
  const dep = new Set(effects);
424
  dep.w = 0;
425
  dep.n = 0;
426
  return dep;
427
};
428
const wasTracked = (dep) => (dep.w & trackOpBit) > 0;
429
const newTracked = (dep) => (dep.n & trackOpBit) > 0;
430
const initDepMarkers = ({ deps }) => {
431
  if (deps.length) {
432
    for (let i = 0; i < deps.length; i++) {
433
      deps[i].w |= trackOpBit;
434
    }
435
  }
436
};
437
const finalizeDepMarkers = (effect) => {
438
  const { deps } = effect;
439
  if (deps.length) {
440
    let ptr = 0;
441
    for (let i = 0; i < deps.length; i++) {
442
      const dep = deps[i];
443
      if (wasTracked(dep) && !newTracked(dep)) {
444
        dep.delete(effect);
445
      } else {
446
        deps[ptr++] = dep;
447
      }
448
      dep.w &= ~trackOpBit;
449
      dep.n &= ~trackOpBit;
450
    }
451
    deps.length = ptr;
452
  }
453
};
454
 
455
const targetMap = /* @__PURE__ */ new WeakMap();
456
let effectTrackDepth = 0;
457
let trackOpBit = 1;
458
const maxMarkerBits = 30;
459
let activeEffect;
460
const ITERATE_KEY = Symbol("iterate" );
461
const MAP_KEY_ITERATE_KEY = Symbol("Map key iterate" );
462
class ReactiveEffect {
463
  constructor(fn, scheduler = null, scope) {
464
    this.fn = fn;
465
    this.scheduler = scheduler;
466
    this.active = true;
467
    this.deps = [];
468
    this.parent = void 0;
469
    recordEffectScope(this, scope);
470
  }
471
  run() {
472
    if (!this.active) {
473
      return this.fn();
474
    }
475
    let parent = activeEffect;
476
    let lastShouldTrack = shouldTrack;
477
    while (parent) {
478
      if (parent === this) {
479
        return;
480
      }
481
      parent = parent.parent;
482
    }
483
    try {
484
      this.parent = activeEffect;
485
      activeEffect = this;
486
      shouldTrack = true;
487
      trackOpBit = 1 << ++effectTrackDepth;
488
      if (effectTrackDepth <= maxMarkerBits) {
489
        initDepMarkers(this);
490
      } else {
491
        cleanupEffect(this);
492
      }
493
      return this.fn();
494
    } finally {
495
      if (effectTrackDepth <= maxMarkerBits) {
496
        finalizeDepMarkers(this);
497
      }
498
      trackOpBit = 1 << --effectTrackDepth;
499
      activeEffect = this.parent;
500
      shouldTrack = lastShouldTrack;
501
      this.parent = void 0;
502
      if (this.deferStop) {
503
        this.stop();
504
      }
505
    }
506
  }
507
  stop() {
508
    if (activeEffect === this) {
509
      this.deferStop = true;
510
    } else if (this.active) {
511
      cleanupEffect(this);
512
      if (this.onStop) {
513
        this.onStop();
514
      }
515
      this.active = false;
516
    }
517
  }
518
}
519
function cleanupEffect(effect2) {
520
  const { deps } = effect2;
521
  if (deps.length) {
522
    for (let i = 0; i < deps.length; i++) {
523
      deps[i].delete(effect2);
524
    }
525
    deps.length = 0;
526
  }
527
}
528
function effect(fn, options) {
529
  if (fn.effect instanceof ReactiveEffect) {
530
    fn = fn.effect.fn;
531
  }
532
  const _effect = new ReactiveEffect(fn);
533
  if (options) {
534
    extend(_effect, options);
535
    if (options.scope)
536
      recordEffectScope(_effect, options.scope);
537
  }
538
  if (!options || !options.lazy) {
539
    _effect.run();
540
  }
541
  const runner = _effect.run.bind(_effect);
542
  runner.effect = _effect;
543
  return runner;
544
}
545
function stop(runner) {
546
  runner.effect.stop();
547
}
548
let shouldTrack = true;
549
const trackStack = [];
550
function pauseTracking() {
551
  trackStack.push(shouldTrack);
552
  shouldTrack = false;
553
}
554
function resetTracking() {
555
  const last = trackStack.pop();
556
  shouldTrack = last === void 0 ? true : last;
557
}
558
function track(target, type, key) {
559
  if (shouldTrack && activeEffect) {
560
    let depsMap = targetMap.get(target);
561
    if (!depsMap) {
562
      targetMap.set(target, depsMap = /* @__PURE__ */ new Map());
563
    }
564
    let dep = depsMap.get(key);
565
    if (!dep) {
566
      depsMap.set(key, dep = createDep());
567
    }
568
    const eventInfo = { effect: activeEffect, target, type, key } ;
569
    trackEffects(dep, eventInfo);
570
  }
571
}
572
function trackEffects(dep, debuggerEventExtraInfo) {
573
  let shouldTrack2 = false;
574
  if (effectTrackDepth <= maxMarkerBits) {
575
    if (!newTracked(dep)) {
576
      dep.n |= trackOpBit;
577
      shouldTrack2 = !wasTracked(dep);
578
    }
579
  } else {
580
    shouldTrack2 = !dep.has(activeEffect);
581
  }
582
  if (shouldTrack2) {
583
    dep.add(activeEffect);
584
    activeEffect.deps.push(dep);
585
    if (activeEffect.onTrack) {
586
      activeEffect.onTrack(
587
        extend(
588
          {
589
            effect: activeEffect
590
          },
591
          debuggerEventExtraInfo
592
        )
593
      );
594
    }
595
  }
596
}
597
function trigger(target, type, key, newValue, oldValue, oldTarget) {
598
  const depsMap = targetMap.get(target);
599
  if (!depsMap) {
600
    return;
601
  }
602
  let deps = [];
603
  if (type === "clear") {
604
    deps = [...depsMap.values()];
605
  } else if (key === "length" && isArray(target)) {
606
    const newLength = Number(newValue);
607
    depsMap.forEach((dep, key2) => {
608
      if (key2 === "length" || key2 >= newLength) {
609
        deps.push(dep);
610
      }
611
    });
612
  } else {
613
    if (key !== void 0) {
614
      deps.push(depsMap.get(key));
615
    }
616
    switch (type) {
617
      case "add":
618
        if (!isArray(target)) {
619
          deps.push(depsMap.get(ITERATE_KEY));
620
          if (isMap(target)) {
621
            deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));
622
          }
623
        } else if (isIntegerKey(key)) {
624
          deps.push(depsMap.get("length"));
625
        }
626
        break;
627
      case "delete":
628
        if (!isArray(target)) {
629
          deps.push(depsMap.get(ITERATE_KEY));
630
          if (isMap(target)) {
631
            deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));
632
          }
633
        }
634
        break;
635
      case "set":
636
        if (isMap(target)) {
637
          deps.push(depsMap.get(ITERATE_KEY));
638
        }
639
        break;
640
    }
641
  }
642
  const eventInfo = { target, type, key, newValue, oldValue, oldTarget } ;
643
  if (deps.length === 1) {
644
    if (deps[0]) {
645
      {
646
        triggerEffects(deps[0], eventInfo);
647
      }
648
    }
649
  } else {
650
    const effects = [];
651
    for (const dep of deps) {
652
      if (dep) {
653
        effects.push(...dep);
654
      }
655
    }
656
    {
657
      triggerEffects(createDep(effects), eventInfo);
658
    }
659
  }
660
}
661
function triggerEffects(dep, debuggerEventExtraInfo) {
662
  const effects = isArray(dep) ? dep : [...dep];
663
  for (const effect2 of effects) {
664
    if (effect2.computed) {
665
      triggerEffect(effect2, debuggerEventExtraInfo);
666
    }
667
  }
668
  for (const effect2 of effects) {
669
    if (!effect2.computed) {
670
      triggerEffect(effect2, debuggerEventExtraInfo);
671
    }
672
  }
673
}
674
function triggerEffect(effect2, debuggerEventExtraInfo) {
675
  if (effect2 !== activeEffect || effect2.allowRecurse) {
676
    if (effect2.onTrigger) {
677
      effect2.onTrigger(extend({ effect: effect2 }, debuggerEventExtraInfo));
678
    }
679
    if (effect2.scheduler) {
680
      effect2.scheduler();
681
    } else {
682
      effect2.run();
683
    }
684
  }
685
}
686
function getDepFromReactive(object, key) {
687
  var _a;
688
  return (_a = targetMap.get(object)) == null ? void 0 : _a.get(key);
689
}
690
 
691
const isNonTrackableKeys = /* @__PURE__ */ makeMap(`__proto__,__v_isRef,__isVue`);
692
const builtInSymbols = new Set(
693
  /* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((key) => key !== "arguments" && key !== "caller").map((key) => Symbol[key]).filter(isSymbol)
694
);
695
const arrayInstrumentations = /* @__PURE__ */ createArrayInstrumentations();
696
function createArrayInstrumentations() {
697
  const instrumentations = {};
698
  ["includes", "indexOf", "lastIndexOf"].forEach((key) => {
699
    instrumentations[key] = function(...args) {
700
      const arr = toRaw(this);
701
      for (let i = 0, l = this.length; i < l; i++) {
702
        track(arr, "get", i + "");
703
      }
704
      const res = arr[key](...args);
705
      if (res === -1 || res === false) {
706
        return arr[key](...args.map(toRaw));
707
      } else {
708
        return res;
709
      }
710
    };
711
  });
712
  ["push", "pop", "shift", "unshift", "splice"].forEach((key) => {
713
    instrumentations[key] = function(...args) {
714
      pauseTracking();
715
      const res = toRaw(this)[key].apply(this, args);
716
      resetTracking();
717
      return res;
718
    };
719
  });
720
  return instrumentations;
721
}
722
function hasOwnProperty(key) {
723
  const obj = toRaw(this);
724
  track(obj, "has", key);
725
  return obj.hasOwnProperty(key);
726
}
727
class BaseReactiveHandler {
728
  constructor(_isReadonly = false, _shallow = false) {
729
    this._isReadonly = _isReadonly;
730
    this._shallow = _shallow;
731
  }
732
  get(target, key, receiver) {
733
    const isReadonly2 = this._isReadonly, shallow = this._shallow;
734
    if (key === "__v_isReactive") {
735
      return !isReadonly2;
736
    } else if (key === "__v_isReadonly") {
737
      return isReadonly2;
738
    } else if (key === "__v_isShallow") {
739
      return shallow;
740
    } else if (key === "__v_raw" && receiver === (isReadonly2 ? shallow ? shallowReadonlyMap : readonlyMap : shallow ? shallowReactiveMap : reactiveMap).get(target)) {
741
      return target;
742
    }
743
    const targetIsArray = isArray(target);
744
    if (!isReadonly2) {
745
      if (targetIsArray && hasOwn(arrayInstrumentations, key)) {
746
        return Reflect.get(arrayInstrumentations, key, receiver);
747
      }
748
      if (key === "hasOwnProperty") {
749
        return hasOwnProperty;
750
      }
751
    }
752
    const res = Reflect.get(target, key, receiver);
753
    if (isSymbol(key) ? builtInSymbols.has(key) : isNonTrackableKeys(key)) {
754
      return res;
755
    }
756
    if (!isReadonly2) {
757
      track(target, "get", key);
758
    }
759
    if (shallow) {
760
      return res;
761
    }
762
    if (isRef(res)) {
763
      return targetIsArray && isIntegerKey(key) ? res : res.value;
764
    }
765
    if (isObject(res)) {
766
      return isReadonly2 ? readonly(res) : reactive(res);
767
    }
768
    return res;
769
  }
770
}
771
class MutableReactiveHandler extends BaseReactiveHandler {
772
  constructor(shallow = false) {
773
    super(false, shallow);
774
  }
775
  set(target, key, value, receiver) {
776
    let oldValue = target[key];
777
    if (isReadonly(oldValue) && isRef(oldValue) && !isRef(value)) {
778
      return false;
779
    }
780
    if (!this._shallow) {
781
      if (!isShallow(value) && !isReadonly(value)) {
782
        oldValue = toRaw(oldValue);
783
        value = toRaw(value);
784
      }
785
      if (!isArray(target) && isRef(oldValue) && !isRef(value)) {
786
        oldValue.value = value;
787
        return true;
788
      }
789
    }
790
    const hadKey = isArray(target) && isIntegerKey(key) ? Number(key) < target.length : hasOwn(target, key);
791
    const result = Reflect.set(target, key, value, receiver);
792
    if (target === toRaw(receiver)) {
793
      if (!hadKey) {
794
        trigger(target, "add", key, value);
795
      } else if (hasChanged(value, oldValue)) {
796
        trigger(target, "set", key, value, oldValue);
797
      }
798
    }
799
    return result;
800
  }
801
  deleteProperty(target, key) {
802
    const hadKey = hasOwn(target, key);
803
    const oldValue = target[key];
804
    const result = Reflect.deleteProperty(target, key);
805
    if (result && hadKey) {
806
      trigger(target, "delete", key, void 0, oldValue);
807
    }
808
    return result;
809
  }
810
  has(target, key) {
811
    const result = Reflect.has(target, key);
812
    if (!isSymbol(key) || !builtInSymbols.has(key)) {
813
      track(target, "has", key);
814
    }
815
    return result;
816
  }
817
  ownKeys(target) {
818
    track(
819
      target,
820
      "iterate",
821
      isArray(target) ? "length" : ITERATE_KEY
822
    );
823
    return Reflect.ownKeys(target);
824
  }
825
}
826
class ReadonlyReactiveHandler extends BaseReactiveHandler {
827
  constructor(shallow = false) {
828
    super(true, shallow);
829
  }
830
  set(target, key) {
831
    {
832
      warn$1(
833
        `Set operation on key "${String(key)}" failed: target is readonly.`,
834
        target
835
      );
836
    }
837
    return true;
838
  }
839
  deleteProperty(target, key) {
840
    {
841
      warn$1(
842
        `Delete operation on key "${String(key)}" failed: target is readonly.`,
843
        target
844
      );
845
    }
846
    return true;
847
  }
848
}
849
const mutableHandlers = /* @__PURE__ */ new MutableReactiveHandler();
850
const readonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler();
851
const shallowReactiveHandlers = /* @__PURE__ */ new MutableReactiveHandler(
852
  true
853
);
854
const shallowReadonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler(true);
855
 
856
const toShallow = (value) => value;
857
const getProto = (v) => Reflect.getPrototypeOf(v);
858
function get(target, key, isReadonly = false, isShallow = false) {
859
  target = target["__v_raw"];
860
  const rawTarget = toRaw(target);
861
  const rawKey = toRaw(key);
862
  if (!isReadonly) {
863
    if (hasChanged(key, rawKey)) {
864
      track(rawTarget, "get", key);
865
    }
866
    track(rawTarget, "get", rawKey);
867
  }
868
  const { has: has2 } = getProto(rawTarget);
869
  const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;
870
  if (has2.call(rawTarget, key)) {
871
    return wrap(target.get(key));
872
  } else if (has2.call(rawTarget, rawKey)) {
873
    return wrap(target.get(rawKey));
874
  } else if (target !== rawTarget) {
875
    target.get(key);
876
  }
877
}
878
function has(key, isReadonly = false) {
879
  const target = this["__v_raw"];
880
  const rawTarget = toRaw(target);
881
  const rawKey = toRaw(key);
882
  if (!isReadonly) {
883
    if (hasChanged(key, rawKey)) {
884
      track(rawTarget, "has", key);
885
    }
886
    track(rawTarget, "has", rawKey);
887
  }
888
  return key === rawKey ? target.has(key) : target.has(key) || target.has(rawKey);
889
}
890
function size(target, isReadonly = false) {
891
  target = target["__v_raw"];
892
  !isReadonly && track(toRaw(target), "iterate", ITERATE_KEY);
893
  return Reflect.get(target, "size", target);
894
}
895
function add(value) {
896
  value = toRaw(value);
897
  const target = toRaw(this);
898
  const proto = getProto(target);
899
  const hadKey = proto.has.call(target, value);
900
  if (!hadKey) {
901
    target.add(value);
902
    trigger(target, "add", value, value);
903
  }
904
  return this;
905
}
906
function set(key, value) {
907
  value = toRaw(value);
908
  const target = toRaw(this);
909
  const { has: has2, get: get2 } = getProto(target);
910
  let hadKey = has2.call(target, key);
911
  if (!hadKey) {
912
    key = toRaw(key);
913
    hadKey = has2.call(target, key);
914
  } else {
915
    checkIdentityKeys(target, has2, key);
916
  }
917
  const oldValue = get2.call(target, key);
918
  target.set(key, value);
919
  if (!hadKey) {
920
    trigger(target, "add", key, value);
921
  } else if (hasChanged(value, oldValue)) {
922
    trigger(target, "set", key, value, oldValue);
923
  }
924
  return this;
925
}
926
function deleteEntry(key) {
927
  const target = toRaw(this);
928
  const { has: has2, get: get2 } = getProto(target);
929
  let hadKey = has2.call(target, key);
930
  if (!hadKey) {
931
    key = toRaw(key);
932
    hadKey = has2.call(target, key);
933
  } else {
934
    checkIdentityKeys(target, has2, key);
935
  }
936
  const oldValue = get2 ? get2.call(target, key) : void 0;
937
  const result = target.delete(key);
938
  if (hadKey) {
939
    trigger(target, "delete", key, void 0, oldValue);
940
  }
941
  return result;
942
}
943
function clear() {
944
  const target = toRaw(this);
945
  const hadItems = target.size !== 0;
946
  const oldTarget = isMap(target) ? new Map(target) : new Set(target) ;
947
  const result = target.clear();
948
  if (hadItems) {
949
    trigger(target, "clear", void 0, void 0, oldTarget);
950
  }
951
  return result;
952
}
953
function createForEach(isReadonly, isShallow) {
954
  return function forEach(callback, thisArg) {
955
    const observed = this;
956
    const target = observed["__v_raw"];
957
    const rawTarget = toRaw(target);
958
    const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;
959
    !isReadonly && track(rawTarget, "iterate", ITERATE_KEY);
960
    return target.forEach((value, key) => {
961
      return callback.call(thisArg, wrap(value), wrap(key), observed);
962
    });
963
  };
964
}
965
function createIterableMethod(method, isReadonly, isShallow) {
966
  return function(...args) {
967
    const target = this["__v_raw"];
968
    const rawTarget = toRaw(target);
969
    const targetIsMap = isMap(rawTarget);
970
    const isPair = method === "entries" || method === Symbol.iterator && targetIsMap;
971
    const isKeyOnly = method === "keys" && targetIsMap;
972
    const innerIterator = target[method](...args);
973
    const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;
974
    !isReadonly && track(
975
      rawTarget,
976
      "iterate",
977
      isKeyOnly ? MAP_KEY_ITERATE_KEY : ITERATE_KEY
978
    );
979
    return {
980
      // iterator protocol
981
      next() {
982
        const { value, done } = innerIterator.next();
983
        return done ? { value, done } : {
984
          value: isPair ? [wrap(value[0]), wrap(value[1])] : wrap(value),
985
          done
986
        };
987
      },
988
      // iterable protocol
989
      [Symbol.iterator]() {
990
        return this;
991
      }
992
    };
993
  };
994
}
995
function createReadonlyMethod(type) {
996
  return function(...args) {
997
    {
998
      const key = args[0] ? `on key "${args[0]}" ` : ``;
999
      console.warn(
1000
        `${capitalize(type)} operation ${key}failed: target is readonly.`,
1001
        toRaw(this)
1002
      );
1003
    }
1004
    return type === "delete" ? false : this;
1005
  };
1006
}
1007
function createInstrumentations() {
1008
  const mutableInstrumentations2 = {
1009
    get(key) {
1010
      return get(this, key);
1011
    },
1012
    get size() {
1013
      return size(this);
1014
    },
1015
    has,
1016
    add,
1017
    set,
1018
    delete: deleteEntry,
1019
    clear,
1020
    forEach: createForEach(false, false)
1021
  };
1022
  const shallowInstrumentations2 = {
1023
    get(key) {
1024
      return get(this, key, false, true);
1025
    },
1026
    get size() {
1027
      return size(this);
1028
    },
1029
    has,
1030
    add,
1031
    set,
1032
    delete: deleteEntry,
1033
    clear,
1034
    forEach: createForEach(false, true)
1035
  };
1036
  const readonlyInstrumentations2 = {
1037
    get(key) {
1038
      return get(this, key, true);
1039
    },
1040
    get size() {
1041
      return size(this, true);
1042
    },
1043
    has(key) {
1044
      return has.call(this, key, true);
1045
    },
1046
    add: createReadonlyMethod("add"),
1047
    set: createReadonlyMethod("set"),
1048
    delete: createReadonlyMethod("delete"),
1049
    clear: createReadonlyMethod("clear"),
1050
    forEach: createForEach(true, false)
1051
  };
1052
  const shallowReadonlyInstrumentations2 = {
1053
    get(key) {
1054
      return get(this, key, true, true);
1055
    },
1056
    get size() {
1057
      return size(this, true);
1058
    },
1059
    has(key) {
1060
      return has.call(this, key, true);
1061
    },
1062
    add: createReadonlyMethod("add"),
1063
    set: createReadonlyMethod("set"),
1064
    delete: createReadonlyMethod("delete"),
1065
    clear: createReadonlyMethod("clear"),
1066
    forEach: createForEach(true, true)
1067
  };
1068
  const iteratorMethods = ["keys", "values", "entries", Symbol.iterator];
1069
  iteratorMethods.forEach((method) => {
1070
    mutableInstrumentations2[method] = createIterableMethod(
1071
      method,
1072
      false,
1073
      false
1074
    );
1075
    readonlyInstrumentations2[method] = createIterableMethod(
1076
      method,
1077
      true,
1078
      false
1079
    );
1080
    shallowInstrumentations2[method] = createIterableMethod(
1081
      method,
1082
      false,
1083
      true
1084
    );
1085
    shallowReadonlyInstrumentations2[method] = createIterableMethod(
1086
      method,
1087
      true,
1088
      true
1089
    );
1090
  });
1091
  return [
1092
    mutableInstrumentations2,
1093
    readonlyInstrumentations2,
1094
    shallowInstrumentations2,
1095
    shallowReadonlyInstrumentations2
1096
  ];
1097
}
1098
const [
1099
  mutableInstrumentations,
1100
  readonlyInstrumentations,
1101
  shallowInstrumentations,
1102
  shallowReadonlyInstrumentations
1103
] = /* @__PURE__ */ createInstrumentations();
1104
function createInstrumentationGetter(isReadonly, shallow) {
1105
  const instrumentations = shallow ? isReadonly ? shallowReadonlyInstrumentations : shallowInstrumentations : isReadonly ? readonlyInstrumentations : mutableInstrumentations;
1106
  return (target, key, receiver) => {
1107
    if (key === "__v_isReactive") {
1108
      return !isReadonly;
1109
    } else if (key === "__v_isReadonly") {
1110
      return isReadonly;
1111
    } else if (key === "__v_raw") {
1112
      return target;
1113
    }
1114
    return Reflect.get(
1115
      hasOwn(instrumentations, key) && key in target ? instrumentations : target,
1116
      key,
1117
      receiver
1118
    );
1119
  };
1120
}
1121
const mutableCollectionHandlers = {
1122
  get: /* @__PURE__ */ createInstrumentationGetter(false, false)
1123
};
1124
const shallowCollectionHandlers = {
1125
  get: /* @__PURE__ */ createInstrumentationGetter(false, true)
1126
};
1127
const readonlyCollectionHandlers = {
1128
  get: /* @__PURE__ */ createInstrumentationGetter(true, false)
1129
};
1130
const shallowReadonlyCollectionHandlers = {
1131
  get: /* @__PURE__ */ createInstrumentationGetter(true, true)
1132
};
1133
function checkIdentityKeys(target, has2, key) {
1134
  const rawKey = toRaw(key);
1135
  if (rawKey !== key && has2.call(target, rawKey)) {
1136
    const type = toRawType(target);
1137
    console.warn(
1138
      `Reactive ${type} contains both the raw and reactive versions of the same object${type === `Map` ? ` as keys` : ``}, which can lead to inconsistencies. Avoid differentiating between the raw and reactive versions of an object and only use the reactive version if possible.`
1139
    );
1140
  }
1141
}
1142
 
1143
const reactiveMap = /* @__PURE__ */ new WeakMap();
1144
const shallowReactiveMap = /* @__PURE__ */ new WeakMap();
1145
const readonlyMap = /* @__PURE__ */ new WeakMap();
1146
const shallowReadonlyMap = /* @__PURE__ */ new WeakMap();
1147
function targetTypeMap(rawType) {
1148
  switch (rawType) {
1149
    case "Object":
1150
    case "Array":
1151
      return 1 /* COMMON */;
1152
    case "Map":
1153
    case "Set":
1154
    case "WeakMap":
1155
    case "WeakSet":
1156
      return 2 /* COLLECTION */;
1157
    default:
1158
      return 0 /* INVALID */;
1159
  }
1160
}
1161
function getTargetType(value) {
1162
  return value["__v_skip"] || !Object.isExtensible(value) ? 0 /* INVALID */ : targetTypeMap(toRawType(value));
1163
}
1164
function reactive(target) {
1165
  if (isReadonly(target)) {
1166
    return target;
1167
  }
1168
  return createReactiveObject(
1169
    target,
1170
    false,
1171
    mutableHandlers,
1172
    mutableCollectionHandlers,
1173
    reactiveMap
1174
  );
1175
}
1176
function shallowReactive(target) {
1177
  return createReactiveObject(
1178
    target,
1179
    false,
1180
    shallowReactiveHandlers,
1181
    shallowCollectionHandlers,
1182
    shallowReactiveMap
1183
  );
1184
}
1185
function readonly(target) {
1186
  return createReactiveObject(
1187
    target,
1188
    true,
1189
    readonlyHandlers,
1190
    readonlyCollectionHandlers,
1191
    readonlyMap
1192
  );
1193
}
1194
function shallowReadonly(target) {
1195
  return createReactiveObject(
1196
    target,
1197
    true,
1198
    shallowReadonlyHandlers,
1199
    shallowReadonlyCollectionHandlers,
1200
    shallowReadonlyMap
1201
  );
1202
}
1203
function createReactiveObject(target, isReadonly2, baseHandlers, collectionHandlers, proxyMap) {
1204
  if (!isObject(target)) {
1205
    {
1206
      console.warn(`value cannot be made reactive: ${String(target)}`);
1207
    }
1208
    return target;
1209
  }
1210
  if (target["__v_raw"] && !(isReadonly2 && target["__v_isReactive"])) {
1211
    return target;
1212
  }
1213
  const existingProxy = proxyMap.get(target);
1214
  if (existingProxy) {
1215
    return existingProxy;
1216
  }
1217
  const targetType = getTargetType(target);
1218
  if (targetType === 0 /* INVALID */) {
1219
    return target;
1220
  }
1221
  const proxy = new Proxy(
1222
    target,
1223
    targetType === 2 /* COLLECTION */ ? collectionHandlers : baseHandlers
1224
  );
1225
  proxyMap.set(target, proxy);
1226
  return proxy;
1227
}
1228
function isReactive(value) {
1229
  if (isReadonly(value)) {
1230
    return isReactive(value["__v_raw"]);
1231
  }
1232
  return !!(value && value["__v_isReactive"]);
1233
}
1234
function isReadonly(value) {
1235
  return !!(value && value["__v_isReadonly"]);
1236
}
1237
function isShallow(value) {
1238
  return !!(value && value["__v_isShallow"]);
1239
}
1240
function isProxy(value) {
1241
  return isReactive(value) || isReadonly(value);
1242
}
1243
function toRaw(observed) {
1244
  const raw = observed && observed["__v_raw"];
1245
  return raw ? toRaw(raw) : observed;
1246
}
1247
function markRaw(value) {
1248
  def(value, "__v_skip", true);
1249
  return value;
1250
}
1251
const toReactive = (value) => isObject(value) ? reactive(value) : value;
1252
const toReadonly = (value) => isObject(value) ? readonly(value) : value;
1253
 
1254
function trackRefValue(ref2) {
1255
  if (shouldTrack && activeEffect) {
1256
    ref2 = toRaw(ref2);
1257
    {
1258
      trackEffects(ref2.dep || (ref2.dep = createDep()), {
1259
        target: ref2,
1260
        type: "get",
1261
        key: "value"
1262
      });
1263
    }
1264
  }
1265
}
1266
function triggerRefValue(ref2, newVal) {
1267
  ref2 = toRaw(ref2);
1268
  const dep = ref2.dep;
1269
  if (dep) {
1270
    {
1271
      triggerEffects(dep, {
1272
        target: ref2,
1273
        type: "set",
1274
        key: "value",
1275
        newValue: newVal
1276
      });
1277
    }
1278
  }
1279
}
1280
function isRef(r) {
1281
  return !!(r && r.__v_isRef === true);
1282
}
1283
function ref(value) {
1284
  return createRef(value, false);
1285
}
1286
function shallowRef(value) {
1287
  return createRef(value, true);
1288
}
1289
function createRef(rawValue, shallow) {
1290
  if (isRef(rawValue)) {
1291
    return rawValue;
1292
  }
1293
  return new RefImpl(rawValue, shallow);
1294
}
1295
class RefImpl {
1296
  constructor(value, __v_isShallow) {
1297
    this.__v_isShallow = __v_isShallow;
1298
    this.dep = void 0;
1299
    this.__v_isRef = true;
1300
    this._rawValue = __v_isShallow ? value : toRaw(value);
1301
    this._value = __v_isShallow ? value : toReactive(value);
1302
  }
1303
  get value() {
1304
    trackRefValue(this);
1305
    return this._value;
1306
  }
1307
  set value(newVal) {
1308
    const useDirectValue = this.__v_isShallow || isShallow(newVal) || isReadonly(newVal);
1309
    newVal = useDirectValue ? newVal : toRaw(newVal);
1310
    if (hasChanged(newVal, this._rawValue)) {
1311
      this._rawValue = newVal;
1312
      this._value = useDirectValue ? newVal : toReactive(newVal);
1313
      triggerRefValue(this, newVal);
1314
    }
1315
  }
1316
}
1317
function triggerRef(ref2) {
1318
  triggerRefValue(ref2, ref2.value );
1319
}
1320
function unref(ref2) {
1321
  return isRef(ref2) ? ref2.value : ref2;
1322
}
1323
function toValue(source) {
1324
  return isFunction(source) ? source() : unref(source);
1325
}
1326
const shallowUnwrapHandlers = {
1327
  get: (target, key, receiver) => unref(Reflect.get(target, key, receiver)),
1328
  set: (target, key, value, receiver) => {
1329
    const oldValue = target[key];
1330
    if (isRef(oldValue) && !isRef(value)) {
1331
      oldValue.value = value;
1332
      return true;
1333
    } else {
1334
      return Reflect.set(target, key, value, receiver);
1335
    }
1336
  }
1337
};
1338
function proxyRefs(objectWithRefs) {
1339
  return isReactive(objectWithRefs) ? objectWithRefs : new Proxy(objectWithRefs, shallowUnwrapHandlers);
1340
}
1341
class CustomRefImpl {
1342
  constructor(factory) {
1343
    this.dep = void 0;
1344
    this.__v_isRef = true;
1345
    const { get, set } = factory(
1346
      () => trackRefValue(this),
1347
      () => triggerRefValue(this)
1348
    );
1349
    this._get = get;
1350
    this._set = set;
1351
  }
1352
  get value() {
1353
    return this._get();
1354
  }
1355
  set value(newVal) {
1356
    this._set(newVal);
1357
  }
1358
}
1359
function customRef(factory) {
1360
  return new CustomRefImpl(factory);
1361
}
1362
function toRefs(object) {
1363
  if (!isProxy(object)) {
1364
    console.warn(`toRefs() expects a reactive object but received a plain one.`);
1365
  }
1366
  const ret = isArray(object) ? new Array(object.length) : {};
1367
  for (const key in object) {
1368
    ret[key] = propertyToRef(object, key);
1369
  }
1370
  return ret;
1371
}
1372
class ObjectRefImpl {
1373
  constructor(_object, _key, _defaultValue) {
1374
    this._object = _object;
1375
    this._key = _key;
1376
    this._defaultValue = _defaultValue;
1377
    this.__v_isRef = true;
1378
  }
1379
  get value() {
1380
    const val = this._object[this._key];
1381
    return val === void 0 ? this._defaultValue : val;
1382
  }
1383
  set value(newVal) {
1384
    this._object[this._key] = newVal;
1385
  }
1386
  get dep() {
1387
    return getDepFromReactive(toRaw(this._object), this._key);
1388
  }
1389
}
1390
class GetterRefImpl {
1391
  constructor(_getter) {
1392
    this._getter = _getter;
1393
    this.__v_isRef = true;
1394
    this.__v_isReadonly = true;
1395
  }
1396
  get value() {
1397
    return this._getter();
1398
  }
1399
}
1400
function toRef(source, key, defaultValue) {
1401
  if (isRef(source)) {
1402
    return source;
1403
  } else if (isFunction(source)) {
1404
    return new GetterRefImpl(source);
1405
  } else if (isObject(source) && arguments.length > 1) {
1406
    return propertyToRef(source, key, defaultValue);
1407
  } else {
1408
    return ref(source);
1409
  }
1410
}
1411
function propertyToRef(source, key, defaultValue) {
1412
  const val = source[key];
1413
  return isRef(val) ? val : new ObjectRefImpl(source, key, defaultValue);
1414
}
1415
 
1416
class ComputedRefImpl {
1417
  constructor(getter, _setter, isReadonly, isSSR) {
1418
    this._setter = _setter;
1419
    this.dep = void 0;
1420
    this.__v_isRef = true;
1421
    this["__v_isReadonly"] = false;
1422
    this._dirty = true;
1423
    this.effect = new ReactiveEffect(getter, () => {
1424
      if (!this._dirty) {
1425
        this._dirty = true;
1426
        triggerRefValue(this);
1427
      }
1428
    });
1429
    this.effect.computed = this;
1430
    this.effect.active = this._cacheable = !isSSR;
1431
    this["__v_isReadonly"] = isReadonly;
1432
  }
1433
  get value() {
1434
    const self = toRaw(this);
1435
    trackRefValue(self);
1436
    if (self._dirty || !self._cacheable) {
1437
      self._dirty = false;
1438
      self._value = self.effect.run();
1439
    }
1440
    return self._value;
1441
  }
1442
  set value(newValue) {
1443
    this._setter(newValue);
1444
  }
1445
}
1446
function computed$1(getterOrOptions, debugOptions, isSSR = false) {
1447
  let getter;
1448
  let setter;
1449
  const onlyGetter = isFunction(getterOrOptions);
1450
  if (onlyGetter) {
1451
    getter = getterOrOptions;
1452
    setter = () => {
1453
      console.warn("Write operation failed: computed value is readonly");
1454
    } ;
1455
  } else {
1456
    getter = getterOrOptions.get;
1457
    setter = getterOrOptions.set;
1458
  }
1459
  const cRef = new ComputedRefImpl(getter, setter, onlyGetter || !setter, isSSR);
1460
  if (debugOptions && !isSSR) {
1461
    cRef.effect.onTrack = debugOptions.onTrack;
1462
    cRef.effect.onTrigger = debugOptions.onTrigger;
1463
  }
1464
  return cRef;
1465
}
1466
 
1467
const stack = [];
1468
function pushWarningContext(vnode) {
1469
  stack.push(vnode);
1470
}
1471
function popWarningContext() {
1472
  stack.pop();
1473
}
1474
function warn(msg, ...args) {
1475
  pauseTracking();
1476
  const instance = stack.length ? stack[stack.length - 1].component : null;
1477
  const appWarnHandler = instance && instance.appContext.config.warnHandler;
1478
  const trace = getComponentTrace();
1479
  if (appWarnHandler) {
1480
    callWithErrorHandling(
1481
      appWarnHandler,
1482
      instance,
1483
      11,
1484
      [
1485
        msg + args.join(""),
1486
        instance && instance.proxy,
1487
        trace.map(
1488
          ({ vnode }) => `at <${formatComponentName(instance, vnode.type)}>`
1489
        ).join("\n"),
1490
        trace
1491
      ]
1492
    );
1493
  } else {
1494
    const warnArgs = [`[Vue warn]: ${msg}`, ...args];
1495
    if (trace.length && // avoid spamming console during tests
1496
    true) {
1497
      warnArgs.push(`
1498
`, ...formatTrace(trace));
1499
    }
1500
    console.warn(...warnArgs);
1501
  }
1502
  resetTracking();
1503
}
1504
function getComponentTrace() {
1505
  let currentVNode = stack[stack.length - 1];
1506
  if (!currentVNode) {
1507
    return [];
1508
  }
1509
  const normalizedStack = [];
1510
  while (currentVNode) {
1511
    const last = normalizedStack[0];
1512
    if (last && last.vnode === currentVNode) {
1513
      last.recurseCount++;
1514
    } else {
1515
      normalizedStack.push({
1516
        vnode: currentVNode,
1517
        recurseCount: 0
1518
      });
1519
    }
1520
    const parentInstance = currentVNode.component && currentVNode.component.parent;
1521
    currentVNode = parentInstance && parentInstance.vnode;
1522
  }
1523
  return normalizedStack;
1524
}
1525
function formatTrace(trace) {
1526
  const logs = [];
1527
  trace.forEach((entry, i) => {
1528
    logs.push(...i === 0 ? [] : [`
1529
`], ...formatTraceEntry(entry));
1530
  });
1531
  return logs;
1532
}
1533
function formatTraceEntry({ vnode, recurseCount }) {
1534
  const postfix = recurseCount > 0 ? `... (${recurseCount} recursive calls)` : ``;
1535
  const isRoot = vnode.component ? vnode.component.parent == null : false;
1536
  const open = ` at <${formatComponentName(
1537
    vnode.component,
1538
    vnode.type,
1539
    isRoot
1540
  )}`;
1541
  const close = `>` + postfix;
1542
  return vnode.props ? [open, ...formatProps(vnode.props), close] : [open + close];
1543
}
1544
function formatProps(props) {
1545
  const res = [];
1546
  const keys = Object.keys(props);
1547
  keys.slice(0, 3).forEach((key) => {
1548
    res.push(...formatProp(key, props[key]));
1549
  });
1550
  if (keys.length > 3) {
1551
    res.push(` ...`);
1552
  }
1553
  return res;
1554
}
1555
function formatProp(key, value, raw) {
1556
  if (isString(value)) {
1557
    value = JSON.stringify(value);
1558
    return raw ? value : [`${key}=${value}`];
1559
  } else if (typeof value === "number" || typeof value === "boolean" || value == null) {
1560
    return raw ? value : [`${key}=${value}`];
1561
  } else if (isRef(value)) {
1562
    value = formatProp(key, toRaw(value.value), true);
1563
    return raw ? value : [`${key}=Ref<`, value, `>`];
1564
  } else if (isFunction(value)) {
1565
    return [`${key}=fn${value.name ? `<${value.name}>` : ``}`];
1566
  } else {
1567
    value = toRaw(value);
1568
    return raw ? value : [`${key}=`, value];
1569
  }
1570
}
1571
function assertNumber(val, type) {
1572
  if (val === void 0) {
1573
    return;
1574
  } else if (typeof val !== "number") {
1575
    warn(`${type} is not a valid number - got ${JSON.stringify(val)}.`);
1576
  } else if (isNaN(val)) {
1577
    warn(`${type} is NaN - the duration expression might be incorrect.`);
1578
  }
1579
}
1580
 
1581
const ErrorTypeStrings = {
1582
  ["sp"]: "serverPrefetch hook",
1583
  ["bc"]: "beforeCreate hook",
1584
  ["c"]: "created hook",
1585
  ["bm"]: "beforeMount hook",
1586
  ["m"]: "mounted hook",
1587
  ["bu"]: "beforeUpdate hook",
1588
  ["u"]: "updated",
1589
  ["bum"]: "beforeUnmount hook",
1590
  ["um"]: "unmounted hook",
1591
  ["a"]: "activated hook",
1592
  ["da"]: "deactivated hook",
1593
  ["ec"]: "errorCaptured hook",
1594
  ["rtc"]: "renderTracked hook",
1595
  ["rtg"]: "renderTriggered hook",
1596
  [0]: "setup function",
1597
  [1]: "render function",
1598
  [2]: "watcher getter",
1599
  [3]: "watcher callback",
1600
  [4]: "watcher cleanup function",
1601
  [5]: "native event handler",
1602
  [6]: "component event handler",
1603
  [7]: "vnode hook",
1604
  [8]: "directive hook",
1605
  [9]: "transition hook",
1606
  [10]: "app errorHandler",
1607
  [11]: "app warnHandler",
1608
  [12]: "ref function",
1609
  [13]: "async component loader",
1610
  [14]: "scheduler flush. This is likely a Vue internals bug. Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/core"
1611
};
1612
function callWithErrorHandling(fn, instance, type, args) {
1613
  let res;
1614
  try {
1615
    res = args ? fn(...args) : fn();
1616
  } catch (err) {
1617
    handleError(err, instance, type);
1618
  }
1619
  return res;
1620
}
1621
function callWithAsyncErrorHandling(fn, instance, type, args) {
1622
  if (isFunction(fn)) {
1623
    const res = callWithErrorHandling(fn, instance, type, args);
1624
    if (res && isPromise(res)) {
1625
      res.catch((err) => {
1626
        handleError(err, instance, type);
1627
      });
1628
    }
1629
    return res;
1630
  }
1631
  const values = [];
1632
  for (let i = 0; i < fn.length; i++) {
1633
    values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));
1634
  }
1635
  return values;
1636
}
1637
function handleError(err, instance, type, throwInDev = true) {
1638
  const contextVNode = instance ? instance.vnode : null;
1639
  if (instance) {
1640
    let cur = instance.parent;
1641
    const exposedInstance = instance.proxy;
1642
    const errorInfo = ErrorTypeStrings[type] ;
1643
    while (cur) {
1644
      const errorCapturedHooks = cur.ec;
1645
      if (errorCapturedHooks) {
1646
        for (let i = 0; i < errorCapturedHooks.length; i++) {
1647
          if (errorCapturedHooks[i](err, exposedInstance, errorInfo) === false) {
1648
            return;
1649
          }
1650
        }
1651
      }
1652
      cur = cur.parent;
1653
    }
1654
    const appErrorHandler = instance.appContext.config.errorHandler;
1655
    if (appErrorHandler) {
1656
      callWithErrorHandling(
1657
        appErrorHandler,
1658
        null,
1659
        10,
1660
        [err, exposedInstance, errorInfo]
1661
      );
1662
      return;
1663
    }
1664
  }
1665
  logError(err, type, contextVNode, throwInDev);
1666
}
1667
function logError(err, type, contextVNode, throwInDev = true) {
1668
  {
1669
    const info = ErrorTypeStrings[type];
1670
    if (contextVNode) {
1671
      pushWarningContext(contextVNode);
1672
    }
1673
    warn(`Unhandled error${info ? ` during execution of ${info}` : ``}`);
1674
    if (contextVNode) {
1675
      popWarningContext();
1676
    }
1677
    if (throwInDev) {
1678
      throw err;
1679
    } else {
1680
      console.error(err);
1681
    }
1682
  }
1683
}
1684
 
1685
let isFlushing = false;
1686
let isFlushPending = false;
1687
const queue = [];
1688
let flushIndex = 0;
1689
const pendingPostFlushCbs = [];
1690
let activePostFlushCbs = null;
1691
let postFlushIndex = 0;
1692
const resolvedPromise = /* @__PURE__ */ Promise.resolve();
1693
let currentFlushPromise = null;
1694
const RECURSION_LIMIT = 100;
1695
function nextTick(fn) {
1696
  const p = currentFlushPromise || resolvedPromise;
1697
  return fn ? p.then(this ? fn.bind(this) : fn) : p;
1698
}
1699
function findInsertionIndex(id) {
1700
  let start = flushIndex + 1;
1701
  let end = queue.length;
1702
  while (start < end) {
1703
    const middle = start + end >>> 1;
1704
    const middleJobId = getId(queue[middle]);
1705
    middleJobId < id ? start = middle + 1 : end = middle;
1706
  }
1707
  return start;
1708
}
1709
function queueJob(job) {
1710
  if (!queue.length || !queue.includes(
1711
    job,
1712
    isFlushing && job.allowRecurse ? flushIndex + 1 : flushIndex
1713
  )) {
1714
    if (job.id == null) {
1715
      queue.push(job);
1716
    } else {
1717
      queue.splice(findInsertionIndex(job.id), 0, job);
1718
    }
1719
    queueFlush();
1720
  }
1721
}
1722
function queueFlush() {
1723
  if (!isFlushing && !isFlushPending) {
1724
    isFlushPending = true;
1725
    currentFlushPromise = resolvedPromise.then(flushJobs);
1726
  }
1727
}
1728
function invalidateJob(job) {
1729
  const i = queue.indexOf(job);
1730
  if (i > flushIndex) {
1731
    queue.splice(i, 1);
1732
  }
1733
}
1734
function queuePostFlushCb(cb) {
1735
  if (!isArray(cb)) {
1736
    if (!activePostFlushCbs || !activePostFlushCbs.includes(
1737
      cb,
1738
      cb.allowRecurse ? postFlushIndex + 1 : postFlushIndex
1739
    )) {
1740
      pendingPostFlushCbs.push(cb);
1741
    }
1742
  } else {
1743
    pendingPostFlushCbs.push(...cb);
1744
  }
1745
  queueFlush();
1746
}
1747
function flushPreFlushCbs(seen, i = isFlushing ? flushIndex + 1 : 0) {
1748
  {
1749
    seen = seen || /* @__PURE__ */ new Map();
1750
  }
1751
  for (; i < queue.length; i++) {
1752
    const cb = queue[i];
1753
    if (cb && cb.pre) {
1754
      if (checkRecursiveUpdates(seen, cb)) {
1755
        continue;
1756
      }
1757
      queue.splice(i, 1);
1758
      i--;
1759
      cb();
1760
    }
1761
  }
1762
}
1763
function flushPostFlushCbs(seen) {
1764
  if (pendingPostFlushCbs.length) {
1765
    const deduped = [...new Set(pendingPostFlushCbs)];
1766
    pendingPostFlushCbs.length = 0;
1767
    if (activePostFlushCbs) {
1768
      activePostFlushCbs.push(...deduped);
1769
      return;
1770
    }
1771
    activePostFlushCbs = deduped;
1772
    {
1773
      seen = seen || /* @__PURE__ */ new Map();
1774
    }
1775
    activePostFlushCbs.sort((a, b) => getId(a) - getId(b));
1776
    for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) {
1777
      if (checkRecursiveUpdates(seen, activePostFlushCbs[postFlushIndex])) {
1778
        continue;
1779
      }
1780
      activePostFlushCbs[postFlushIndex]();
1781
    }
1782
    activePostFlushCbs = null;
1783
    postFlushIndex = 0;
1784
  }
1785
}
1786
const getId = (job) => job.id == null ? Infinity : job.id;
1787
const comparator = (a, b) => {
1788
  const diff = getId(a) - getId(b);
1789
  if (diff === 0) {
1790
    if (a.pre && !b.pre)
1791
      return -1;
1792
    if (b.pre && !a.pre)
1793
      return 1;
1794
  }
1795
  return diff;
1796
};
1797
function flushJobs(seen) {
1798
  isFlushPending = false;
1799
  isFlushing = true;
1800
  {
1801
    seen = seen || /* @__PURE__ */ new Map();
1802
  }
1803
  queue.sort(comparator);
1804
  const check = (job) => checkRecursiveUpdates(seen, job) ;
1805
  try {
1806
    for (flushIndex = 0; flushIndex < queue.length; flushIndex++) {
1807
      const job = queue[flushIndex];
1808
      if (job && job.active !== false) {
1809
        if (check(job)) {
1810
          continue;
1811
        }
1812
        callWithErrorHandling(job, null, 14);
1813
      }
1814
    }
1815
  } finally {
1816
    flushIndex = 0;
1817
    queue.length = 0;
1818
    flushPostFlushCbs(seen);
1819
    isFlushing = false;
1820
    currentFlushPromise = null;
1821
    if (queue.length || pendingPostFlushCbs.length) {
1822
      flushJobs(seen);
1823
    }
1824
  }
1825
}
1826
function checkRecursiveUpdates(seen, fn) {
1827
  if (!seen.has(fn)) {
1828
    seen.set(fn, 1);
1829
  } else {
1830
    const count = seen.get(fn);
1831
    if (count > RECURSION_LIMIT) {
1832
      const instance = fn.ownerInstance;
1833
      const componentName = instance && getComponentName(instance.type);
1834
      warn(
1835
        `Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`
1836
      );
1837
      return true;
1838
    } else {
1839
      seen.set(fn, count + 1);
1840
    }
1841
  }
1842
}
1843
 
1844
let isHmrUpdating = false;
1845
const hmrDirtyComponents = /* @__PURE__ */ new Set();
1846
{
1847
  getGlobalThis().__VUE_HMR_RUNTIME__ = {
1848
    createRecord: tryWrap(createRecord),
1849
    rerender: tryWrap(rerender),
1850
    reload: tryWrap(reload)
1851
  };
1852
}
1853
const map = /* @__PURE__ */ new Map();
1854
function registerHMR(instance) {
1855
  const id = instance.type.__hmrId;
1856
  let record = map.get(id);
1857
  if (!record) {
1858
    createRecord(id, instance.type);
1859
    record = map.get(id);
1860
  }
1861
  record.instances.add(instance);
1862
}
1863
function unregisterHMR(instance) {
1864
  map.get(instance.type.__hmrId).instances.delete(instance);
1865
}
1866
function createRecord(id, initialDef) {
1867
  if (map.has(id)) {
1868
    return false;
1869
  }
1870
  map.set(id, {
1871
    initialDef: normalizeClassComponent(initialDef),
1872
    instances: /* @__PURE__ */ new Set()
1873
  });
1874
  return true;
1875
}
1876
function normalizeClassComponent(component) {
1877
  return isClassComponent(component) ? component.__vccOpts : component;
1878
}
1879
function rerender(id, newRender) {
1880
  const record = map.get(id);
1881
  if (!record) {
1882
    return;
1883
  }
1884
  record.initialDef.render = newRender;
1885
  [...record.instances].forEach((instance) => {
1886
    if (newRender) {
1887
      instance.render = newRender;
1888
      normalizeClassComponent(instance.type).render = newRender;
1889
    }
1890
    instance.renderCache = [];
1891
    isHmrUpdating = true;
1892
    instance.update();
1893
    isHmrUpdating = false;
1894
  });
1895
}
1896
function reload(id, newComp) {
1897
  const record = map.get(id);
1898
  if (!record)
1899
    return;
1900
  newComp = normalizeClassComponent(newComp);
1901
  updateComponentDef(record.initialDef, newComp);
1902
  const instances = [...record.instances];
1903
  for (const instance of instances) {
1904
    const oldComp = normalizeClassComponent(instance.type);
1905
    if (!hmrDirtyComponents.has(oldComp)) {
1906
      if (oldComp !== record.initialDef) {
1907
        updateComponentDef(oldComp, newComp);
1908
      }
1909
      hmrDirtyComponents.add(oldComp);
1910
    }
1911
    instance.appContext.propsCache.delete(instance.type);
1912
    instance.appContext.emitsCache.delete(instance.type);
1913
    instance.appContext.optionsCache.delete(instance.type);
1914
    if (instance.ceReload) {
1915
      hmrDirtyComponents.add(oldComp);
1916
      instance.ceReload(newComp.styles);
1917
      hmrDirtyComponents.delete(oldComp);
1918
    } else if (instance.parent) {
1919
      queueJob(instance.parent.update);
1920
    } else if (instance.appContext.reload) {
1921
      instance.appContext.reload();
1922
    } else if (typeof window !== "undefined") {
1923
      window.location.reload();
1924
    } else {
1925
      console.warn(
1926
        "[HMR] Root or manually mounted instance modified. Full reload required."
1927
      );
1928
    }
1929
  }
1930
  queuePostFlushCb(() => {
1931
    for (const instance of instances) {
1932
      hmrDirtyComponents.delete(
1933
        normalizeClassComponent(instance.type)
1934
      );
1935
    }
1936
  });
1937
}
1938
function updateComponentDef(oldComp, newComp) {
1939
  extend(oldComp, newComp);
1940
  for (const key in oldComp) {
1941
    if (key !== "__file" && !(key in newComp)) {
1942
      delete oldComp[key];
1943
    }
1944
  }
1945
}
1946
function tryWrap(fn) {
1947
  return (id, arg) => {
1948
    try {
1949
      return fn(id, arg);
1950
    } catch (e) {
1951
      console.error(e);
1952
      console.warn(
1953
        `[HMR] Something went wrong during Vue component hot-reload. Full reload required.`
1954
      );
1955
    }
1956
  };
1957
}
1958
 
1959
let devtools;
1960
let buffer = [];
1961
let devtoolsNotInstalled = false;
1962
function emit$1(event, ...args) {
1963
  if (devtools) {
1964
    devtools.emit(event, ...args);
1965
  } else if (!devtoolsNotInstalled) {
1966
    buffer.push({ event, args });
1967
  }
1968
}
1969
function setDevtoolsHook(hook, target) {
1970
  var _a, _b;
1971
  devtools = hook;
1972
  if (devtools) {
1973
    devtools.enabled = true;
1974
    buffer.forEach(({ event, args }) => devtools.emit(event, ...args));
1975
    buffer = [];
1976
  } else if (
1977
    // handle late devtools injection - only do this if we are in an actual
1978
    // browser environment to avoid the timer handle stalling test runner exit
1979
    // (#4815)
1980
    typeof window !== "undefined" && // some envs mock window but not fully
1981
    window.HTMLElement && // also exclude jsdom
1982
    !((_b = (_a = window.navigator) == null ? void 0 : _a.userAgent) == null ? void 0 : _b.includes("jsdom"))
1983
  ) {
1984
    const replay = target.__VUE_DEVTOOLS_HOOK_REPLAY__ = target.__VUE_DEVTOOLS_HOOK_REPLAY__ || [];
1985
    replay.push((newHook) => {
1986
      setDevtoolsHook(newHook, target);
1987
    });
1988
    setTimeout(() => {
1989
      if (!devtools) {
1990
        target.__VUE_DEVTOOLS_HOOK_REPLAY__ = null;
1991
        devtoolsNotInstalled = true;
1992
        buffer = [];
1993
      }
1994
    }, 3e3);
1995
  } else {
1996
    devtoolsNotInstalled = true;
1997
    buffer = [];
1998
  }
1999
}
2000
function devtoolsInitApp(app, version) {
2001
  emit$1("app:init" /* APP_INIT */, app, version, {
2002
    Fragment,
2003
    Text,
2004
    Comment,
2005
    Static
2006
  });
2007
}
2008
function devtoolsUnmountApp(app) {
2009
  emit$1("app:unmount" /* APP_UNMOUNT */, app);
2010
}
2011
const devtoolsComponentAdded = /* @__PURE__ */ createDevtoolsComponentHook(
2012
  "component:added" /* COMPONENT_ADDED */
2013
);
2014
const devtoolsComponentUpdated = /* @__PURE__ */ createDevtoolsComponentHook("component:updated" /* COMPONENT_UPDATED */);
2015
const _devtoolsComponentRemoved = /* @__PURE__ */ createDevtoolsComponentHook(
2016
  "component:removed" /* COMPONENT_REMOVED */
2017
);
2018
const devtoolsComponentRemoved = (component) => {
2019
  if (devtools && typeof devtools.cleanupBuffer === "function" && // remove the component if it wasn't buffered
2020
  !devtools.cleanupBuffer(component)) {
2021
    _devtoolsComponentRemoved(component);
2022
  }
2023
};
2024
function createDevtoolsComponentHook(hook) {
2025
  return (component) => {
2026
    emit$1(
2027
      hook,
2028
      component.appContext.app,
2029
      component.uid,
2030
      component.parent ? component.parent.uid : void 0,
2031
      component
2032
    );
2033
  };
2034
}
2035
const devtoolsPerfStart = /* @__PURE__ */ createDevtoolsPerformanceHook(
2036
  "perf:start" /* PERFORMANCE_START */
2037
);
2038
const devtoolsPerfEnd = /* @__PURE__ */ createDevtoolsPerformanceHook(
2039
  "perf:end" /* PERFORMANCE_END */
2040
);
2041
function createDevtoolsPerformanceHook(hook) {
2042
  return (component, type, time) => {
2043
    emit$1(hook, component.appContext.app, component.uid, component, type, time);
2044
  };
2045
}
2046
function devtoolsComponentEmit(component, event, params) {
2047
  emit$1(
2048
    "component:emit" /* COMPONENT_EMIT */,
2049
    component.appContext.app,
2050
    component,
2051
    event,
2052
    params
2053
  );
2054
}
2055
 
2056
function emit(instance, event, ...rawArgs) {
2057
  if (instance.isUnmounted)
2058
    return;
2059
  const props = instance.vnode.props || EMPTY_OBJ;
2060
  {
2061
    const {
2062
      emitsOptions,
2063
      propsOptions: [propsOptions]
2064
    } = instance;
2065
    if (emitsOptions) {
2066
      if (!(event in emitsOptions) && true) {
2067
        if (!propsOptions || !(toHandlerKey(event) in propsOptions)) {
2068
          warn(
2069
            `Component emitted event "${event}" but it is neither declared in the emits option nor as an "${toHandlerKey(event)}" prop.`
2070
          );
2071
        }
2072
      } else {
2073
        const validator = emitsOptions[event];
2074
        if (isFunction(validator)) {
2075
          const isValid = validator(...rawArgs);
2076
          if (!isValid) {
2077
            warn(
2078
              `Invalid event arguments: event validation failed for event "${event}".`
2079
            );
2080
          }
2081
        }
2082
      }
2083
    }
2084
  }
2085
  let args = rawArgs;
2086
  const isModelListener = event.startsWith("update:");
2087
  const modelArg = isModelListener && event.slice(7);
2088
  if (modelArg && modelArg in props) {
2089
    const modifiersKey = `${modelArg === "modelValue" ? "model" : modelArg}Modifiers`;
2090
    const { number, trim } = props[modifiersKey] || EMPTY_OBJ;
2091
    if (trim) {
2092
      args = rawArgs.map((a) => isString(a) ? a.trim() : a);
2093
    }
2094
    if (number) {
2095
      args = rawArgs.map(looseToNumber);
2096
    }
2097
  }
2098
  {
2099
    devtoolsComponentEmit(instance, event, args);
2100
  }
2101
  {
2102
    const lowerCaseEvent = event.toLowerCase();
2103
    if (lowerCaseEvent !== event && props[toHandlerKey(lowerCaseEvent)]) {
2104
      warn(
2105
        `Event "${lowerCaseEvent}" is emitted in component ${formatComponentName(
2106
          instance,
2107
          instance.type
2108
        )} but the handler is registered for "${event}". Note that HTML attributes are case-insensitive and you cannot use v-on to listen to camelCase events when using in-DOM templates. You should probably use "${hyphenate(event)}" instead of "${event}".`
2109
      );
2110
    }
2111
  }
2112
  let handlerName;
2113
  let handler = props[handlerName = toHandlerKey(event)] || // also try camelCase event handler (#2249)
2114
  props[handlerName = toHandlerKey(camelize(event))];
2115
  if (!handler && isModelListener) {
2116
    handler = props[handlerName = toHandlerKey(hyphenate(event))];
2117
  }
2118
  if (handler) {
2119
    callWithAsyncErrorHandling(
2120
      handler,
2121
      instance,
2122
      6,
2123
      args
2124
    );
2125
  }
2126
  const onceHandler = props[handlerName + `Once`];
2127
  if (onceHandler) {
2128
    if (!instance.emitted) {
2129
      instance.emitted = {};
2130
    } else if (instance.emitted[handlerName]) {
2131
      return;
2132
    }
2133
    instance.emitted[handlerName] = true;
2134
    callWithAsyncErrorHandling(
2135
      onceHandler,
2136
      instance,
2137
      6,
2138
      args
2139
    );
2140
  }
2141
}
2142
function normalizeEmitsOptions(comp, appContext, asMixin = false) {
2143
  const cache = appContext.emitsCache;
2144
  const cached = cache.get(comp);
2145
  if (cached !== void 0) {
2146
    return cached;
2147
  }
2148
  const raw = comp.emits;
2149
  let normalized = {};
2150
  let hasExtends = false;
2151
  if (!isFunction(comp)) {
2152
    const extendEmits = (raw2) => {
2153
      const normalizedFromExtend = normalizeEmitsOptions(raw2, appContext, true);
2154
      if (normalizedFromExtend) {
2155
        hasExtends = true;
2156
        extend(normalized, normalizedFromExtend);
2157
      }
2158
    };
2159
    if (!asMixin && appContext.mixins.length) {
2160
      appContext.mixins.forEach(extendEmits);
2161
    }
2162
    if (comp.extends) {
2163
      extendEmits(comp.extends);
2164
    }
2165
    if (comp.mixins) {
2166
      comp.mixins.forEach(extendEmits);
2167
    }
2168
  }
2169
  if (!raw && !hasExtends) {
2170
    if (isObject(comp)) {
2171
      cache.set(comp, null);
2172
    }
2173
    return null;
2174
  }
2175
  if (isArray(raw)) {
2176
    raw.forEach((key) => normalized[key] = null);
2177
  } else {
2178
    extend(normalized, raw);
2179
  }
2180
  if (isObject(comp)) {
2181
    cache.set(comp, normalized);
2182
  }
2183
  return normalized;
2184
}
2185
function isEmitListener(options, key) {
2186
  if (!options || !isOn(key)) {
2187
    return false;
2188
  }
2189
  key = key.slice(2).replace(/Once$/, "");
2190
  return hasOwn(options, key[0].toLowerCase() + key.slice(1)) || hasOwn(options, hyphenate(key)) || hasOwn(options, key);
2191
}
2192
 
2193
let currentRenderingInstance = null;
2194
let currentScopeId = null;
2195
function setCurrentRenderingInstance(instance) {
2196
  const prev = currentRenderingInstance;
2197
  currentRenderingInstance = instance;
2198
  currentScopeId = instance && instance.type.__scopeId || null;
2199
  return prev;
2200
}
2201
function pushScopeId(id) {
2202
  currentScopeId = id;
2203
}
2204
function popScopeId() {
2205
  currentScopeId = null;
2206
}
2207
const withScopeId = (_id) => withCtx;
2208
function withCtx(fn, ctx = currentRenderingInstance, isNonScopedSlot) {
2209
  if (!ctx)
2210
    return fn;
2211
  if (fn._n) {
2212
    return fn;
2213
  }
2214
  const renderFnWithContext = (...args) => {
2215
    if (renderFnWithContext._d) {
2216
      setBlockTracking(-1);
2217
    }
2218
    const prevInstance = setCurrentRenderingInstance(ctx);
2219
    let res;
2220
    try {
2221
      res = fn(...args);
2222
    } finally {
2223
      setCurrentRenderingInstance(prevInstance);
2224
      if (renderFnWithContext._d) {
2225
        setBlockTracking(1);
2226
      }
2227
    }
2228
    {
2229
      devtoolsComponentUpdated(ctx);
2230
    }
2231
    return res;
2232
  };
2233
  renderFnWithContext._n = true;
2234
  renderFnWithContext._c = true;
2235
  renderFnWithContext._d = true;
2236
  return renderFnWithContext;
2237
}
2238
 
2239
let accessedAttrs = false;
2240
function markAttrsAccessed() {
2241
  accessedAttrs = true;
2242
}
2243
function renderComponentRoot(instance) {
2244
  const {
2245
    type: Component,
2246
    vnode,
2247
    proxy,
2248
    withProxy,
2249
    props,
2250
    propsOptions: [propsOptions],
2251
    slots,
2252
    attrs,
2253
    emit,
2254
    render,
2255
    renderCache,
2256
    data,
2257
    setupState,
2258
    ctx,
2259
    inheritAttrs
2260
  } = instance;
2261
  let result;
2262
  let fallthroughAttrs;
2263
  const prev = setCurrentRenderingInstance(instance);
2264
  {
2265
    accessedAttrs = false;
2266
  }
2267
  try {
2268
    if (vnode.shapeFlag & 4) {
2269
      const proxyToUse = withProxy || proxy;
2270
      result = normalizeVNode(
2271
        render.call(
2272
          proxyToUse,
2273
          proxyToUse,
2274
          renderCache,
2275
          props,
2276
          setupState,
2277
          data,
2278
          ctx
2279
        )
2280
      );
2281
      fallthroughAttrs = attrs;
2282
    } else {
2283
      const render2 = Component;
2284
      if (attrs === props) {
2285
        markAttrsAccessed();
2286
      }
2287
      result = normalizeVNode(
2288
        render2.length > 1 ? render2(
2289
          props,
2290
          true ? {
2291
            get attrs() {
2292
              markAttrsAccessed();
2293
              return attrs;
2294
            },
2295
            slots,
2296
            emit
2297
          } : { attrs, slots, emit }
2298
        ) : render2(
2299
          props,
2300
          null
2301
          /* we know it doesn't need it */
2302
        )
2303
      );
2304
      fallthroughAttrs = Component.props ? attrs : getFunctionalFallthrough(attrs);
2305
    }
2306
  } catch (err) {
2307
    blockStack.length = 0;
2308
    handleError(err, instance, 1);
2309
    result = createVNode(Comment);
2310
  }
2311
  let root = result;
2312
  let setRoot = void 0;
2313
  if (result.patchFlag > 0 && result.patchFlag & 2048) {
2314
    [root, setRoot] = getChildRoot(result);
2315
  }
2316
  if (fallthroughAttrs && inheritAttrs !== false) {
2317
    const keys = Object.keys(fallthroughAttrs);
2318
    const { shapeFlag } = root;
2319
    if (keys.length) {
2320
      if (shapeFlag & (1 | 6)) {
2321
        if (propsOptions && keys.some(isModelListener)) {
2322
          fallthroughAttrs = filterModelListeners(
2323
            fallthroughAttrs,
2324
            propsOptions
2325
          );
2326
        }
2327
        root = cloneVNode(root, fallthroughAttrs);
2328
      } else if (!accessedAttrs && root.type !== Comment) {
2329
        const allAttrs = Object.keys(attrs);
2330
        const eventAttrs = [];
2331
        const extraAttrs = [];
2332
        for (let i = 0, l = allAttrs.length; i < l; i++) {
2333
          const key = allAttrs[i];
2334
          if (isOn(key)) {
2335
            if (!isModelListener(key)) {
2336
              eventAttrs.push(key[2].toLowerCase() + key.slice(3));
2337
            }
2338
          } else {
2339
            extraAttrs.push(key);
2340
          }
2341
        }
2342
        if (extraAttrs.length) {
2343
          warn(
2344
            `Extraneous non-props attributes (${extraAttrs.join(", ")}) were passed to component but could not be automatically inherited because component renders fragment or text root nodes.`
2345
          );
2346
        }
2347
        if (eventAttrs.length) {
2348
          warn(
2349
            `Extraneous non-emits event listeners (${eventAttrs.join(", ")}) were passed to component but could not be automatically inherited because component renders fragment or text root nodes. If the listener is intended to be a component custom event listener only, declare it using the "emits" option.`
2350
          );
2351
        }
2352
      }
2353
    }
2354
  }
2355
  if (vnode.dirs) {
2356
    if (!isElementRoot(root)) {
2357
      warn(
2358
        `Runtime directive used on component with non-element root node. The directives will not function as intended.`
2359
      );
2360
    }
2361
    root = cloneVNode(root);
2362
    root.dirs = root.dirs ? root.dirs.concat(vnode.dirs) : vnode.dirs;
2363
  }
2364
  if (vnode.transition) {
2365
    if (!isElementRoot(root)) {
2366
      warn(
2367
        `Component inside <Transition> renders non-element root node that cannot be animated.`
2368
      );
2369
    }
2370
    root.transition = vnode.transition;
2371
  }
2372
  if (setRoot) {
2373
    setRoot(root);
2374
  } else {
2375
    result = root;
2376
  }
2377
  setCurrentRenderingInstance(prev);
2378
  return result;
2379
}
2380
const getChildRoot = (vnode) => {
2381
  const rawChildren = vnode.children;
2382
  const dynamicChildren = vnode.dynamicChildren;
2383
  const childRoot = filterSingleRoot(rawChildren);
2384
  if (!childRoot) {
2385
    return [vnode, void 0];
2386
  }
2387
  const index = rawChildren.indexOf(childRoot);
2388
  const dynamicIndex = dynamicChildren ? dynamicChildren.indexOf(childRoot) : -1;
2389
  const setRoot = (updatedRoot) => {
2390
    rawChildren[index] = updatedRoot;
2391
    if (dynamicChildren) {
2392
      if (dynamicIndex > -1) {
2393
        dynamicChildren[dynamicIndex] = updatedRoot;
2394
      } else if (updatedRoot.patchFlag > 0) {
2395
        vnode.dynamicChildren = [...dynamicChildren, updatedRoot];
2396
      }
2397
    }
2398
  };
2399
  return [normalizeVNode(childRoot), setRoot];
2400
};
2401
function filterSingleRoot(children) {
2402
  let singleRoot;
2403
  for (let i = 0; i < children.length; i++) {
2404
    const child = children[i];
2405
    if (isVNode(child)) {
2406
      if (child.type !== Comment || child.children === "v-if") {
2407
        if (singleRoot) {
2408
          return;
2409
        } else {
2410
          singleRoot = child;
2411
        }
2412
      }
2413
    } else {
2414
      return;
2415
    }
2416
  }
2417
  return singleRoot;
2418
}
2419
const getFunctionalFallthrough = (attrs) => {
2420
  let res;
2421
  for (const key in attrs) {
2422
    if (key === "class" || key === "style" || isOn(key)) {
2423
      (res || (res = {}))[key] = attrs[key];
2424
    }
2425
  }
2426
  return res;
2427
};
2428
const filterModelListeners = (attrs, props) => {
2429
  const res = {};
2430
  for (const key in attrs) {
2431
    if (!isModelListener(key) || !(key.slice(9) in props)) {
2432
      res[key] = attrs[key];
2433
    }
2434
  }
2435
  return res;
2436
};
2437
const isElementRoot = (vnode) => {
2438
  return vnode.shapeFlag & (6 | 1) || vnode.type === Comment;
2439
};
2440
function shouldUpdateComponent(prevVNode, nextVNode, optimized) {
2441
  const { props: prevProps, children: prevChildren, component } = prevVNode;
2442
  const { props: nextProps, children: nextChildren, patchFlag } = nextVNode;
2443
  const emits = component.emitsOptions;
2444
  if ((prevChildren || nextChildren) && isHmrUpdating) {
2445
    return true;
2446
  }
2447
  if (nextVNode.dirs || nextVNode.transition) {
2448
    return true;
2449
  }
2450
  if (optimized && patchFlag >= 0) {
2451
    if (patchFlag & 1024) {
2452
      return true;
2453
    }
2454
    if (patchFlag & 16) {
2455
      if (!prevProps) {
2456
        return !!nextProps;
2457
      }
2458
      return hasPropsChanged(prevProps, nextProps, emits);
2459
    } else if (patchFlag & 8) {
2460
      const dynamicProps = nextVNode.dynamicProps;
2461
      for (let i = 0; i < dynamicProps.length; i++) {
2462
        const key = dynamicProps[i];
2463
        if (nextProps[key] !== prevProps[key] && !isEmitListener(emits, key)) {
2464
          return true;
2465
        }
2466
      }
2467
    }
2468
  } else {
2469
    if (prevChildren || nextChildren) {
2470
      if (!nextChildren || !nextChildren.$stable) {
2471
        return true;
2472
      }
2473
    }
2474
    if (prevProps === nextProps) {
2475
      return false;
2476
    }
2477
    if (!prevProps) {
2478
      return !!nextProps;
2479
    }
2480
    if (!nextProps) {
2481
      return true;
2482
    }
2483
    return hasPropsChanged(prevProps, nextProps, emits);
2484
  }
2485
  return false;
2486
}
2487
function hasPropsChanged(prevProps, nextProps, emitsOptions) {
2488
  const nextKeys = Object.keys(nextProps);
2489
  if (nextKeys.length !== Object.keys(prevProps).length) {
2490
    return true;
2491
  }
2492
  for (let i = 0; i < nextKeys.length; i++) {
2493
    const key = nextKeys[i];
2494
    if (nextProps[key] !== prevProps[key] && !isEmitListener(emitsOptions, key)) {
2495
      return true;
2496
    }
2497
  }
2498
  return false;
2499
}
2500
function updateHOCHostEl({ vnode, parent }, el) {
2501
  while (parent && parent.subTree === vnode) {
2502
    (vnode = parent.vnode).el = el;
2503
    parent = parent.parent;
2504
  }
2505
}
2506
 
2507
const isSuspense = (type) => type.__isSuspense;
2508
const SuspenseImpl = {
2509
  name: "Suspense",
2510
  // In order to make Suspense tree-shakable, we need to avoid importing it
2511
  // directly in the renderer. The renderer checks for the __isSuspense flag
2512
  // on a vnode's type and calls the `process` method, passing in renderer
2513
  // internals.
2514
  __isSuspense: true,
2515
  process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals) {
2516
    if (n1 == null) {
2517
      mountSuspense(
2518
        n2,
2519
        container,
2520
        anchor,
2521
        parentComponent,
2522
        parentSuspense,
2523
        isSVG,
2524
        slotScopeIds,
2525
        optimized,
2526
        rendererInternals
2527
      );
2528
    } else {
2529
      patchSuspense(
2530
        n1,
2531
        n2,
2532
        container,
2533
        anchor,
2534
        parentComponent,
2535
        isSVG,
2536
        slotScopeIds,
2537
        optimized,
2538
        rendererInternals
2539
      );
2540
    }
2541
  },
2542
  hydrate: hydrateSuspense,
2543
  create: createSuspenseBoundary,
2544
  normalize: normalizeSuspenseChildren
2545
};
2546
const Suspense = SuspenseImpl ;
2547
function triggerEvent(vnode, name) {
2548
  const eventListener = vnode.props && vnode.props[name];
2549
  if (isFunction(eventListener)) {
2550
    eventListener();
2551
  }
2552
}
2553
function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals) {
2554
  const {
2555
    p: patch,
2556
    o: { createElement }
2557
  } = rendererInternals;
2558
  const hiddenContainer = createElement("div");
2559
  const suspense = vnode.suspense = createSuspenseBoundary(
2560
    vnode,
2561
    parentSuspense,
2562
    parentComponent,
2563
    container,
2564
    hiddenContainer,
2565
    anchor,
2566
    isSVG,
2567
    slotScopeIds,
2568
    optimized,
2569
    rendererInternals
2570
  );
2571
  patch(
2572
    null,
2573
    suspense.pendingBranch = vnode.ssContent,
2574
    hiddenContainer,
2575
    null,
2576
    parentComponent,
2577
    suspense,
2578
    isSVG,
2579
    slotScopeIds
2580
  );
2581
  if (suspense.deps > 0) {
2582
    triggerEvent(vnode, "onPending");
2583
    triggerEvent(vnode, "onFallback");
2584
    patch(
2585
      null,
2586
      vnode.ssFallback,
2587
      container,
2588
      anchor,
2589
      parentComponent,
2590
      null,
2591
      // fallback tree will not have suspense context
2592
      isSVG,
2593
      slotScopeIds
2594
    );
2595
    setActiveBranch(suspense, vnode.ssFallback);
2596
  } else {
2597
    suspense.resolve(false, true);
2598
  }
2599
}
2600
function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, { p: patch, um: unmount, o: { createElement } }) {
2601
  const suspense = n2.suspense = n1.suspense;
2602
  suspense.vnode = n2;
2603
  n2.el = n1.el;
2604
  const newBranch = n2.ssContent;
2605
  const newFallback = n2.ssFallback;
2606
  const { activeBranch, pendingBranch, isInFallback, isHydrating } = suspense;
2607
  if (pendingBranch) {
2608
    suspense.pendingBranch = newBranch;
2609
    if (isSameVNodeType(newBranch, pendingBranch)) {
2610
      patch(
2611
        pendingBranch,
2612
        newBranch,
2613
        suspense.hiddenContainer,
2614
        null,
2615
        parentComponent,
2616
        suspense,
2617
        isSVG,
2618
        slotScopeIds,
2619
        optimized
2620
      );
2621
      if (suspense.deps <= 0) {
2622
        suspense.resolve();
2623
      } else if (isInFallback) {
2624
        patch(
2625
          activeBranch,
2626
          newFallback,
2627
          container,
2628
          anchor,
2629
          parentComponent,
2630
          null,
2631
          // fallback tree will not have suspense context
2632
          isSVG,
2633
          slotScopeIds,
2634
          optimized
2635
        );
2636
        setActiveBranch(suspense, newFallback);
2637
      }
2638
    } else {
2639
      suspense.pendingId++;
2640
      if (isHydrating) {
2641
        suspense.isHydrating = false;
2642
        suspense.activeBranch = pendingBranch;
2643
      } else {
2644
        unmount(pendingBranch, parentComponent, suspense);
2645
      }
2646
      suspense.deps = 0;
2647
      suspense.effects.length = 0;
2648
      suspense.hiddenContainer = createElement("div");
2649
      if (isInFallback) {
2650
        patch(
2651
          null,
2652
          newBranch,
2653
          suspense.hiddenContainer,
2654
          null,
2655
          parentComponent,
2656
          suspense,
2657
          isSVG,
2658
          slotScopeIds,
2659
          optimized
2660
        );
2661
        if (suspense.deps <= 0) {
2662
          suspense.resolve();
2663
        } else {
2664
          patch(
2665
            activeBranch,
2666
            newFallback,
2667
            container,
2668
            anchor,
2669
            parentComponent,
2670
            null,
2671
            // fallback tree will not have suspense context
2672
            isSVG,
2673
            slotScopeIds,
2674
            optimized
2675
          );
2676
          setActiveBranch(suspense, newFallback);
2677
        }
2678
      } else if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {
2679
        patch(
2680
          activeBranch,
2681
          newBranch,
2682
          container,
2683
          anchor,
2684
          parentComponent,
2685
          suspense,
2686
          isSVG,
2687
          slotScopeIds,
2688
          optimized
2689
        );
2690
        suspense.resolve(true);
2691
      } else {
2692
        patch(
2693
          null,
2694
          newBranch,
2695
          suspense.hiddenContainer,
2696
          null,
2697
          parentComponent,
2698
          suspense,
2699
          isSVG,
2700
          slotScopeIds,
2701
          optimized
2702
        );
2703
        if (suspense.deps <= 0) {
2704
          suspense.resolve();
2705
        }
2706
      }
2707
    }
2708
  } else {
2709
    if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {
2710
      patch(
2711
        activeBranch,
2712
        newBranch,
2713
        container,
2714
        anchor,
2715
        parentComponent,
2716
        suspense,
2717
        isSVG,
2718
        slotScopeIds,
2719
        optimized
2720
      );
2721
      setActiveBranch(suspense, newBranch);
2722
    } else {
2723
      triggerEvent(n2, "onPending");
2724
      suspense.pendingBranch = newBranch;
2725
      suspense.pendingId++;
2726
      patch(
2727
        null,
2728
        newBranch,
2729
        suspense.hiddenContainer,
2730
        null,
2731
        parentComponent,
2732
        suspense,
2733
        isSVG,
2734
        slotScopeIds,
2735
        optimized
2736
      );
2737
      if (suspense.deps <= 0) {
2738
        suspense.resolve();
2739
      } else {
2740
        const { timeout, pendingId } = suspense;
2741
        if (timeout > 0) {
2742
          setTimeout(() => {
2743
            if (suspense.pendingId === pendingId) {
2744
              suspense.fallback(newFallback);
2745
            }
2746
          }, timeout);
2747
        } else if (timeout === 0) {
2748
          suspense.fallback(newFallback);
2749
        }
2750
      }
2751
    }
2752
  }
2753
}
2754
let hasWarned = false;
2755
function createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals, isHydrating = false) {
2756
  if (!hasWarned) {
2757
    hasWarned = true;
2758
    console[console.info ? "info" : "log"](
2759
      `<Suspense> is an experimental feature and its API will likely change.`
2760
    );
2761
  }
2762
  const {
2763
    p: patch,
2764
    m: move,
2765
    um: unmount,
2766
    n: next,
2767
    o: { parentNode, remove }
2768
  } = rendererInternals;
2769
  let parentSuspenseId;
2770
  const isSuspensible = isVNodeSuspensible(vnode);
2771
  if (isSuspensible) {
2772
    if (parentSuspense == null ? void 0 : parentSuspense.pendingBranch) {
2773
      parentSuspenseId = parentSuspense.pendingId;
2774
      parentSuspense.deps++;
2775
    }
2776
  }
2777
  const timeout = vnode.props ? toNumber(vnode.props.timeout) : void 0;
2778
  {
2779
    assertNumber(timeout, `Suspense timeout`);
2780
  }
2781
  const suspense = {
2782
    vnode,
2783
    parent: parentSuspense,
2784
    parentComponent,
2785
    isSVG,
2786
    container,
2787
    hiddenContainer,
2788
    anchor,
2789
    deps: 0,
2790
    pendingId: 0,
2791
    timeout: typeof timeout === "number" ? timeout : -1,
2792
    activeBranch: null,
2793
    pendingBranch: null,
2794
    isInFallback: true,
2795
    isHydrating,
2796
    isUnmounted: false,
2797
    effects: [],
2798
    resolve(resume = false, sync = false) {
2799
      {
2800
        if (!resume && !suspense.pendingBranch) {
2801
          throw new Error(
2802
            `suspense.resolve() is called without a pending branch.`
2803
          );
2804
        }
2805
        if (suspense.isUnmounted) {
2806
          throw new Error(
2807
            `suspense.resolve() is called on an already unmounted suspense boundary.`
2808
          );
2809
        }
2810
      }
2811
      const {
2812
        vnode: vnode2,
2813
        activeBranch,
2814
        pendingBranch,
2815
        pendingId,
2816
        effects,
2817
        parentComponent: parentComponent2,
2818
        container: container2
2819
      } = suspense;
2820
      if (suspense.isHydrating) {
2821
        suspense.isHydrating = false;
2822
      } else if (!resume) {
2823
        const delayEnter = activeBranch && pendingBranch.transition && pendingBranch.transition.mode === "out-in";
2824
        if (delayEnter) {
2825
          activeBranch.transition.afterLeave = () => {
2826
            if (pendingId === suspense.pendingId) {
2827
              move(pendingBranch, container2, anchor2, 0);
2828
            }
2829
          };
2830
        }
2831
        let { anchor: anchor2 } = suspense;
2832
        if (activeBranch) {
2833
          anchor2 = next(activeBranch);
2834
          unmount(activeBranch, parentComponent2, suspense, true);
2835
        }
2836
        if (!delayEnter) {
2837
          move(pendingBranch, container2, anchor2, 0);
2838
        }
2839
      }
2840
      setActiveBranch(suspense, pendingBranch);
2841
      suspense.pendingBranch = null;
2842
      suspense.isInFallback = false;
2843
      let parent = suspense.parent;
2844
      let hasUnresolvedAncestor = false;
2845
      while (parent) {
2846
        if (parent.pendingBranch) {
2847
          parent.effects.push(...effects);
2848
          hasUnresolvedAncestor = true;
2849
          break;
2850
        }
2851
        parent = parent.parent;
2852
      }
2853
      if (!hasUnresolvedAncestor) {
2854
        queuePostFlushCb(effects);
2855
      }
2856
      suspense.effects = [];
2857
      if (isSuspensible) {
2858
        if (parentSuspense && parentSuspense.pendingBranch && parentSuspenseId === parentSuspense.pendingId) {
2859
          parentSuspense.deps--;
2860
          if (parentSuspense.deps === 0 && !sync) {
2861
            parentSuspense.resolve();
2862
          }
2863
        }
2864
      }
2865
      triggerEvent(vnode2, "onResolve");
2866
    },
2867
    fallback(fallbackVNode) {
2868
      if (!suspense.pendingBranch) {
2869
        return;
2870
      }
2871
      const { vnode: vnode2, activeBranch, parentComponent: parentComponent2, container: container2, isSVG: isSVG2 } = suspense;
2872
      triggerEvent(vnode2, "onFallback");
2873
      const anchor2 = next(activeBranch);
2874
      const mountFallback = () => {
2875
        if (!suspense.isInFallback) {
2876
          return;
2877
        }
2878
        patch(
2879
          null,
2880
          fallbackVNode,
2881
          container2,
2882
          anchor2,
2883
          parentComponent2,
2884
          null,
2885
          // fallback tree will not have suspense context
2886
          isSVG2,
2887
          slotScopeIds,
2888
          optimized
2889
        );
2890
        setActiveBranch(suspense, fallbackVNode);
2891
      };
2892
      const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === "out-in";
2893
      if (delayEnter) {
2894
        activeBranch.transition.afterLeave = mountFallback;
2895
      }
2896
      suspense.isInFallback = true;
2897
      unmount(
2898
        activeBranch,
2899
        parentComponent2,
2900
        null,
2901
        // no suspense so unmount hooks fire now
2902
        true
2903
        // shouldRemove
2904
      );
2905
      if (!delayEnter) {
2906
        mountFallback();
2907
      }
2908
    },
2909
    move(container2, anchor2, type) {
2910
      suspense.activeBranch && move(suspense.activeBranch, container2, anchor2, type);
2911
      suspense.container = container2;
2912
    },
2913
    next() {
2914
      return suspense.activeBranch && next(suspense.activeBranch);
2915
    },
2916
    registerDep(instance, setupRenderEffect) {
2917
      const isInPendingSuspense = !!suspense.pendingBranch;
2918
      if (isInPendingSuspense) {
2919
        suspense.deps++;
2920
      }
2921
      const hydratedEl = instance.vnode.el;
2922
      instance.asyncDep.catch((err) => {
2923
        handleError(err, instance, 0);
2924
      }).then((asyncSetupResult) => {
2925
        if (instance.isUnmounted || suspense.isUnmounted || suspense.pendingId !== instance.suspenseId) {
2926
          return;
2927
        }
2928
        instance.asyncResolved = true;
2929
        const { vnode: vnode2 } = instance;
2930
        {
2931
          pushWarningContext(vnode2);
2932
        }
2933
        handleSetupResult(instance, asyncSetupResult, false);
2934
        if (hydratedEl) {
2935
          vnode2.el = hydratedEl;
2936
        }
2937
        const placeholder = !hydratedEl && instance.subTree.el;
2938
        setupRenderEffect(
2939
          instance,
2940
          vnode2,
2941
          // component may have been moved before resolve.
2942
          // if this is not a hydration, instance.subTree will be the comment
2943
          // placeholder.
2944
          parentNode(hydratedEl || instance.subTree.el),
2945
          // anchor will not be used if this is hydration, so only need to
2946
          // consider the comment placeholder case.
2947
          hydratedEl ? null : next(instance.subTree),
2948
          suspense,
2949
          isSVG,
2950
          optimized
2951
        );
2952
        if (placeholder) {
2953
          remove(placeholder);
2954
        }
2955
        updateHOCHostEl(instance, vnode2.el);
2956
        {
2957
          popWarningContext();
2958
        }
2959
        if (isInPendingSuspense && --suspense.deps === 0) {
2960
          suspense.resolve();
2961
        }
2962
      });
2963
    },
2964
    unmount(parentSuspense2, doRemove) {
2965
      suspense.isUnmounted = true;
2966
      if (suspense.activeBranch) {
2967
        unmount(
2968
          suspense.activeBranch,
2969
          parentComponent,
2970
          parentSuspense2,
2971
          doRemove
2972
        );
2973
      }
2974
      if (suspense.pendingBranch) {
2975
        unmount(
2976
          suspense.pendingBranch,
2977
          parentComponent,
2978
          parentSuspense2,
2979
          doRemove
2980
        );
2981
      }
2982
    }
2983
  };
2984
  return suspense;
2985
}
2986
function hydrateSuspense(node, vnode, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals, hydrateNode) {
2987
  const suspense = vnode.suspense = createSuspenseBoundary(
2988
    vnode,
2989
    parentSuspense,
2990
    parentComponent,
2991
    node.parentNode,
2992
    document.createElement("div"),
2993
    null,
2994
    isSVG,
2995
    slotScopeIds,
2996
    optimized,
2997
    rendererInternals,
2998
    true
2999
    /* hydrating */
3000
  );
3001
  const result = hydrateNode(
3002
    node,
3003
    suspense.pendingBranch = vnode.ssContent,
3004
    parentComponent,
3005
    suspense,
3006
    slotScopeIds,
3007
    optimized
3008
  );
3009
  if (suspense.deps === 0) {
3010
    suspense.resolve(false, true);
3011
  }
3012
  return result;
3013
}
3014
function normalizeSuspenseChildren(vnode) {
3015
  const { shapeFlag, children } = vnode;
3016
  const isSlotChildren = shapeFlag & 32;
3017
  vnode.ssContent = normalizeSuspenseSlot(
3018
    isSlotChildren ? children.default : children
3019
  );
3020
  vnode.ssFallback = isSlotChildren ? normalizeSuspenseSlot(children.fallback) : createVNode(Comment);
3021
}
3022
function normalizeSuspenseSlot(s) {
3023
  let block;
3024
  if (isFunction(s)) {
3025
    const trackBlock = isBlockTreeEnabled && s._c;
3026
    if (trackBlock) {
3027
      s._d = false;
3028
      openBlock();
3029
    }
3030
    s = s();
3031
    if (trackBlock) {
3032
      s._d = true;
3033
      block = currentBlock;
3034
      closeBlock();
3035
    }
3036
  }
3037
  if (isArray(s)) {
3038
    const singleChild = filterSingleRoot(s);
3039
    if (!singleChild) {
3040
      warn(`<Suspense> slots expect a single root node.`);
3041
    }
3042
    s = singleChild;
3043
  }
3044
  s = normalizeVNode(s);
3045
  if (block && !s.dynamicChildren) {
3046
    s.dynamicChildren = block.filter((c) => c !== s);
3047
  }
3048
  return s;
3049
}
3050
function queueEffectWithSuspense(fn, suspense) {
3051
  if (suspense && suspense.pendingBranch) {
3052
    if (isArray(fn)) {
3053
      suspense.effects.push(...fn);
3054
    } else {
3055
      suspense.effects.push(fn);
3056
    }
3057
  } else {
3058
    queuePostFlushCb(fn);
3059
  }
3060
}
3061
function setActiveBranch(suspense, branch) {
3062
  suspense.activeBranch = branch;
3063
  const { vnode, parentComponent } = suspense;
3064
  const el = vnode.el = branch.el;
3065
  if (parentComponent && parentComponent.subTree === vnode) {
3066
    parentComponent.vnode.el = el;
3067
    updateHOCHostEl(parentComponent, el);
3068
  }
3069
}
3070
function isVNodeSuspensible(vnode) {
3071
  var _a;
3072
  return ((_a = vnode.props) == null ? void 0 : _a.suspensible) != null && vnode.props.suspensible !== false;
3073
}
3074
 
3075
function watchEffect(effect, options) {
3076
  return doWatch(effect, null, options);
3077
}
3078
function watchPostEffect(effect, options) {
3079
  return doWatch(
3080
    effect,
3081
    null,
3082
    extend({}, options, { flush: "post" })
3083
  );
3084
}
3085
function watchSyncEffect(effect, options) {
3086
  return doWatch(
3087
    effect,
3088
    null,
3089
    extend({}, options, { flush: "sync" })
3090
  );
3091
}
3092
const INITIAL_WATCHER_VALUE = {};
3093
function watch(source, cb, options) {
3094
  if (!isFunction(cb)) {
3095
    warn(
3096
      `\`watch(fn, options?)\` signature has been moved to a separate API. Use \`watchEffect(fn, options?)\` instead. \`watch\` now only supports \`watch(source, cb, options?) signature.`
3097
    );
3098
  }
3099
  return doWatch(source, cb, options);
3100
}
3101
function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EMPTY_OBJ) {
3102
  var _a;
3103
  if (!cb) {
3104
    if (immediate !== void 0) {
3105
      warn(
3106
        `watch() "immediate" option is only respected when using the watch(source, callback, options?) signature.`
3107
      );
3108
    }
3109
    if (deep !== void 0) {
3110
      warn(
3111
        `watch() "deep" option is only respected when using the watch(source, callback, options?) signature.`
3112
      );
3113
    }
3114
  }
3115
  const warnInvalidSource = (s) => {
3116
    warn(
3117
      `Invalid watch source: `,
3118
      s,
3119
      `A watch source can only be a getter/effect function, a ref, a reactive object, or an array of these types.`
3120
    );
3121
  };
3122
  const instance = getCurrentScope() === ((_a = currentInstance) == null ? void 0 : _a.scope) ? currentInstance : null;
3123
  let getter;
3124
  let forceTrigger = false;
3125
  let isMultiSource = false;
3126
  if (isRef(source)) {
3127
    getter = () => source.value;
3128
    forceTrigger = isShallow(source);
3129
  } else if (isReactive(source)) {
3130
    getter = () => source;
3131
    deep = true;
3132
  } else if (isArray(source)) {
3133
    isMultiSource = true;
3134
    forceTrigger = source.some((s) => isReactive(s) || isShallow(s));
3135
    getter = () => source.map((s) => {
3136
      if (isRef(s)) {
3137
        return s.value;
3138
      } else if (isReactive(s)) {
3139
        return traverse(s);
3140
      } else if (isFunction(s)) {
3141
        return callWithErrorHandling(s, instance, 2);
3142
      } else {
3143
        warnInvalidSource(s);
3144
      }
3145
    });
3146
  } else if (isFunction(source)) {
3147
    if (cb) {
3148
      getter = () => callWithErrorHandling(source, instance, 2);
3149
    } else {
3150
      getter = () => {
3151
        if (instance && instance.isUnmounted) {
3152
          return;
3153
        }
3154
        if (cleanup) {
3155
          cleanup();
3156
        }
3157
        return callWithAsyncErrorHandling(
3158
          source,
3159
          instance,
3160
          3,
3161
          [onCleanup]
3162
        );
3163
      };
3164
    }
3165
  } else {
3166
    getter = NOOP;
3167
    warnInvalidSource(source);
3168
  }
3169
  if (cb && deep) {
3170
    const baseGetter = getter;
3171
    getter = () => traverse(baseGetter());
3172
  }
3173
  let cleanup;
3174
  let onCleanup = (fn) => {
3175
    cleanup = effect.onStop = () => {
3176
      callWithErrorHandling(fn, instance, 4);
3177
    };
3178
  };
3179
  let oldValue = isMultiSource ? new Array(source.length).fill(INITIAL_WATCHER_VALUE) : INITIAL_WATCHER_VALUE;
3180
  const job = () => {
3181
    if (!effect.active) {
3182
      return;
3183
    }
3184
    if (cb) {
3185
      const newValue = effect.run();
3186
      if (deep || forceTrigger || (isMultiSource ? newValue.some((v, i) => hasChanged(v, oldValue[i])) : hasChanged(newValue, oldValue)) || false) {
3187
        if (cleanup) {
3188
          cleanup();
3189
        }
3190
        callWithAsyncErrorHandling(cb, instance, 3, [
3191
          newValue,
3192
          // pass undefined as the old value when it's changed for the first time
3193
          oldValue === INITIAL_WATCHER_VALUE ? void 0 : isMultiSource && oldValue[0] === INITIAL_WATCHER_VALUE ? [] : oldValue,
3194
          onCleanup
3195
        ]);
3196
        oldValue = newValue;
3197
      }
3198
    } else {
3199
      effect.run();
3200
    }
3201
  };
3202
  job.allowRecurse = !!cb;
3203
  let scheduler;
3204
  if (flush === "sync") {
3205
    scheduler = job;
3206
  } else if (flush === "post") {
3207
    scheduler = () => queuePostRenderEffect(job, instance && instance.suspense);
3208
  } else {
3209
    job.pre = true;
3210
    if (instance)
3211
      job.id = instance.uid;
3212
    scheduler = () => queueJob(job);
3213
  }
3214
  const effect = new ReactiveEffect(getter, scheduler);
3215
  {
3216
    effect.onTrack = onTrack;
3217
    effect.onTrigger = onTrigger;
3218
  }
3219
  if (cb) {
3220
    if (immediate) {
3221
      job();
3222
    } else {
3223
      oldValue = effect.run();
3224
    }
3225
  } else if (flush === "post") {
3226
    queuePostRenderEffect(
3227
      effect.run.bind(effect),
3228
      instance && instance.suspense
3229
    );
3230
  } else {
3231
    effect.run();
3232
  }
3233
  const unwatch = () => {
3234
    effect.stop();
3235
    if (instance && instance.scope) {
3236
      remove(instance.scope.effects, effect);
3237
    }
3238
  };
3239
  return unwatch;
3240
}
3241
function instanceWatch(source, value, options) {
3242
  const publicThis = this.proxy;
3243
  const getter = isString(source) ? source.includes(".") ? createPathGetter(publicThis, source) : () => publicThis[source] : source.bind(publicThis, publicThis);
3244
  let cb;
3245
  if (isFunction(value)) {
3246
    cb = value;
3247
  } else {
3248
    cb = value.handler;
3249
    options = value;
3250
  }
3251
  const cur = currentInstance;
3252
  setCurrentInstance(this);
3253
  const res = doWatch(getter, cb.bind(publicThis), options);
3254
  if (cur) {
3255
    setCurrentInstance(cur);
3256
  } else {
3257
    unsetCurrentInstance();
3258
  }
3259
  return res;
3260
}
3261
function createPathGetter(ctx, path) {
3262
  const segments = path.split(".");
3263
  return () => {
3264
    let cur = ctx;
3265
    for (let i = 0; i < segments.length && cur; i++) {
3266
      cur = cur[segments[i]];
3267
    }
3268
    return cur;
3269
  };
3270
}
3271
function traverse(value, seen) {
3272
  if (!isObject(value) || value["__v_skip"]) {
3273
    return value;
3274
  }
3275
  seen = seen || /* @__PURE__ */ new Set();
3276
  if (seen.has(value)) {
3277
    return value;
3278
  }
3279
  seen.add(value);
3280
  if (isRef(value)) {
3281
    traverse(value.value, seen);
3282
  } else if (isArray(value)) {
3283
    for (let i = 0; i < value.length; i++) {
3284
      traverse(value[i], seen);
3285
    }
3286
  } else if (isSet(value) || isMap(value)) {
3287
    value.forEach((v) => {
3288
      traverse(v, seen);
3289
    });
3290
  } else if (isPlainObject(value)) {
3291
    for (const key in value) {
3292
      traverse(value[key], seen);
3293
    }
3294
  }
3295
  return value;
3296
}
3297
 
3298
function validateDirectiveName(name) {
3299
  if (isBuiltInDirective(name)) {
3300
    warn("Do not use built-in directive ids as custom directive id: " + name);
3301
  }
3302
}
3303
function withDirectives(vnode, directives) {
3304
  const internalInstance = currentRenderingInstance;
3305
  if (internalInstance === null) {
3306
    warn(`withDirectives can only be used inside render functions.`);
3307
    return vnode;
3308
  }
3309
  const instance = getExposeProxy(internalInstance) || internalInstance.proxy;
3310
  const bindings = vnode.dirs || (vnode.dirs = []);
3311
  for (let i = 0; i < directives.length; i++) {
3312
    let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];
3313
    if (dir) {
3314
      if (isFunction(dir)) {
3315
        dir = {
3316
          mounted: dir,
3317
          updated: dir
3318
        };
3319
      }
3320
      if (dir.deep) {
3321
        traverse(value);
3322
      }
3323
      bindings.push({
3324
        dir,
3325
        instance,
3326
        value,
3327
        oldValue: void 0,
3328
        arg,
3329
        modifiers
3330
      });
3331
    }
3332
  }
3333
  return vnode;
3334
}
3335
function invokeDirectiveHook(vnode, prevVNode, instance, name) {
3336
  const bindings = vnode.dirs;
3337
  const oldBindings = prevVNode && prevVNode.dirs;
3338
  for (let i = 0; i < bindings.length; i++) {
3339
    const binding = bindings[i];
3340
    if (oldBindings) {
3341
      binding.oldValue = oldBindings[i].value;
3342
    }
3343
    let hook = binding.dir[name];
3344
    if (hook) {
3345
      pauseTracking();
3346
      callWithAsyncErrorHandling(hook, instance, 8, [
3347
        vnode.el,
3348
        binding,
3349
        vnode,
3350
        prevVNode
3351
      ]);
3352
      resetTracking();
3353
    }
3354
  }
3355
}
3356
 
3357
const leaveCbKey = Symbol("_leaveCb");
3358
const enterCbKey$1 = Symbol("_enterCb");
3359
function useTransitionState() {
3360
  const state = {
3361
    isMounted: false,
3362
    isLeaving: false,
3363
    isUnmounting: false,
3364
    leavingVNodes: /* @__PURE__ */ new Map()
3365
  };
3366
  onMounted(() => {
3367
    state.isMounted = true;
3368
  });
3369
  onBeforeUnmount(() => {
3370
    state.isUnmounting = true;
3371
  });
3372
  return state;
3373
}
3374
const TransitionHookValidator = [Function, Array];
3375
const BaseTransitionPropsValidators = {
3376
  mode: String,
3377
  appear: Boolean,
3378
  persisted: Boolean,
3379
  // enter
3380
  onBeforeEnter: TransitionHookValidator,
3381
  onEnter: TransitionHookValidator,
3382
  onAfterEnter: TransitionHookValidator,
3383
  onEnterCancelled: TransitionHookValidator,
3384
  // leave
3385
  onBeforeLeave: TransitionHookValidator,
3386
  onLeave: TransitionHookValidator,
3387
  onAfterLeave: TransitionHookValidator,
3388
  onLeaveCancelled: TransitionHookValidator,
3389
  // appear
3390
  onBeforeAppear: TransitionHookValidator,
3391
  onAppear: TransitionHookValidator,
3392
  onAfterAppear: TransitionHookValidator,
3393
  onAppearCancelled: TransitionHookValidator
3394
};
3395
const BaseTransitionImpl = {
3396
  name: `BaseTransition`,
3397
  props: BaseTransitionPropsValidators,
3398
  setup(props, { slots }) {
3399
    const instance = getCurrentInstance();
3400
    const state = useTransitionState();
3401
    let prevTransitionKey;
3402
    return () => {
3403
      const children = slots.default && getTransitionRawChildren(slots.default(), true);
3404
      if (!children || !children.length) {
3405
        return;
3406
      }
3407
      let child = children[0];
3408
      if (children.length > 1) {
3409
        let hasFound = false;
3410
        for (const c of children) {
3411
          if (c.type !== Comment) {
3412
            if (hasFound) {
3413
              warn(
3414
                "<transition> can only be used on a single element or component. Use <transition-group> for lists."
3415
              );
3416
              break;
3417
            }
3418
            child = c;
3419
            hasFound = true;
3420
          }
3421
        }
3422
      }
3423
      const rawProps = toRaw(props);
3424
      const { mode } = rawProps;
3425
      if (mode && mode !== "in-out" && mode !== "out-in" && mode !== "default") {
3426
        warn(`invalid <transition> mode: ${mode}`);
3427
      }
3428
      if (state.isLeaving) {
3429
        return emptyPlaceholder(child);
3430
      }
3431
      const innerChild = getKeepAliveChild(child);
3432
      if (!innerChild) {
3433
        return emptyPlaceholder(child);
3434
      }
3435
      const enterHooks = resolveTransitionHooks(
3436
        innerChild,
3437
        rawProps,
3438
        state,
3439
        instance
3440
      );
3441
      setTransitionHooks(innerChild, enterHooks);
3442
      const oldChild = instance.subTree;
3443
      const oldInnerChild = oldChild && getKeepAliveChild(oldChild);
3444
      let transitionKeyChanged = false;
3445
      const { getTransitionKey } = innerChild.type;
3446
      if (getTransitionKey) {
3447
        const key = getTransitionKey();
3448
        if (prevTransitionKey === void 0) {
3449
          prevTransitionKey = key;
3450
        } else if (key !== prevTransitionKey) {
3451
          prevTransitionKey = key;
3452
          transitionKeyChanged = true;
3453
        }
3454
      }
3455
      if (oldInnerChild && oldInnerChild.type !== Comment && (!isSameVNodeType(innerChild, oldInnerChild) || transitionKeyChanged)) {
3456
        const leavingHooks = resolveTransitionHooks(
3457
          oldInnerChild,
3458
          rawProps,
3459
          state,
3460
          instance
3461
        );
3462
        setTransitionHooks(oldInnerChild, leavingHooks);
3463
        if (mode === "out-in") {
3464
          state.isLeaving = true;
3465
          leavingHooks.afterLeave = () => {
3466
            state.isLeaving = false;
3467
            if (instance.update.active !== false) {
3468
              instance.update();
3469
            }
3470
          };
3471
          return emptyPlaceholder(child);
3472
        } else if (mode === "in-out" && innerChild.type !== Comment) {
3473
          leavingHooks.delayLeave = (el, earlyRemove, delayedLeave) => {
3474
            const leavingVNodesCache = getLeavingNodesForType(
3475
              state,
3476
              oldInnerChild
3477
            );
3478
            leavingVNodesCache[String(oldInnerChild.key)] = oldInnerChild;
3479
            el[leaveCbKey] = () => {
3480
              earlyRemove();
3481
              el[leaveCbKey] = void 0;
3482
              delete enterHooks.delayedLeave;
3483
            };
3484
            enterHooks.delayedLeave = delayedLeave;
3485
          };
3486
        }
3487
      }
3488
      return child;
3489
    };
3490
  }
3491
};
3492
const BaseTransition = BaseTransitionImpl;
3493
function getLeavingNodesForType(state, vnode) {
3494
  const { leavingVNodes } = state;
3495
  let leavingVNodesCache = leavingVNodes.get(vnode.type);
3496
  if (!leavingVNodesCache) {
3497
    leavingVNodesCache = /* @__PURE__ */ Object.create(null);
3498
    leavingVNodes.set(vnode.type, leavingVNodesCache);
3499
  }
3500
  return leavingVNodesCache;
3501
}
3502
function resolveTransitionHooks(vnode, props, state, instance) {
3503
  const {
3504
    appear,
3505
    mode,
3506
    persisted = false,
3507
    onBeforeEnter,
3508
    onEnter,
3509
    onAfterEnter,
3510
    onEnterCancelled,
3511
    onBeforeLeave,
3512
    onLeave,
3513
    onAfterLeave,
3514
    onLeaveCancelled,
3515
    onBeforeAppear,
3516
    onAppear,
3517
    onAfterAppear,
3518
    onAppearCancelled
3519
  } = props;
3520
  const key = String(vnode.key);
3521
  const leavingVNodesCache = getLeavingNodesForType(state, vnode);
3522
  const callHook = (hook, args) => {
3523
    hook && callWithAsyncErrorHandling(
3524
      hook,
3525
      instance,
3526
      9,
3527
      args
3528
    );
3529
  };
3530
  const callAsyncHook = (hook, args) => {
3531
    const done = args[1];
3532
    callHook(hook, args);
3533
    if (isArray(hook)) {
3534
      if (hook.every((hook2) => hook2.length <= 1))
3535
        done();
3536
    } else if (hook.length <= 1) {
3537
      done();
3538
    }
3539
  };
3540
  const hooks = {
3541
    mode,
3542
    persisted,
3543
    beforeEnter(el) {
3544
      let hook = onBeforeEnter;
3545
      if (!state.isMounted) {
3546
        if (appear) {
3547
          hook = onBeforeAppear || onBeforeEnter;
3548
        } else {
3549
          return;
3550
        }
3551
      }
3552
      if (el[leaveCbKey]) {
3553
        el[leaveCbKey](
3554
          true
3555
          /* cancelled */
3556
        );
3557
      }
3558
      const leavingVNode = leavingVNodesCache[key];
3559
      if (leavingVNode && isSameVNodeType(vnode, leavingVNode) && leavingVNode.el[leaveCbKey]) {
3560
        leavingVNode.el[leaveCbKey]();
3561
      }
3562
      callHook(hook, [el]);
3563
    },
3564
    enter(el) {
3565
      let hook = onEnter;
3566
      let afterHook = onAfterEnter;
3567
      let cancelHook = onEnterCancelled;
3568
      if (!state.isMounted) {
3569
        if (appear) {
3570
          hook = onAppear || onEnter;
3571
          afterHook = onAfterAppear || onAfterEnter;
3572
          cancelHook = onAppearCancelled || onEnterCancelled;
3573
        } else {
3574
          return;
3575
        }
3576
      }
3577
      let called = false;
3578
      const done = el[enterCbKey$1] = (cancelled) => {
3579
        if (called)
3580
          return;
3581
        called = true;
3582
        if (cancelled) {
3583
          callHook(cancelHook, [el]);
3584
        } else {
3585
          callHook(afterHook, [el]);
3586
        }
3587
        if (hooks.delayedLeave) {
3588
          hooks.delayedLeave();
3589
        }
3590
        el[enterCbKey$1] = void 0;
3591
      };
3592
      if (hook) {
3593
        callAsyncHook(hook, [el, done]);
3594
      } else {
3595
        done();
3596
      }
3597
    },
3598
    leave(el, remove) {
3599
      const key2 = String(vnode.key);
3600
      if (el[enterCbKey$1]) {
3601
        el[enterCbKey$1](
3602
          true
3603
          /* cancelled */
3604
        );
3605
      }
3606
      if (state.isUnmounting) {
3607
        return remove();
3608
      }
3609
      callHook(onBeforeLeave, [el]);
3610
      let called = false;
3611
      const done = el[leaveCbKey] = (cancelled) => {
3612
        if (called)
3613
          return;
3614
        called = true;
3615
        remove();
3616
        if (cancelled) {
3617
          callHook(onLeaveCancelled, [el]);
3618
        } else {
3619
          callHook(onAfterLeave, [el]);
3620
        }
3621
        el[leaveCbKey] = void 0;
3622
        if (leavingVNodesCache[key2] === vnode) {
3623
          delete leavingVNodesCache[key2];
3624
        }
3625
      };
3626
      leavingVNodesCache[key2] = vnode;
3627
      if (onLeave) {
3628
        callAsyncHook(onLeave, [el, done]);
3629
      } else {
3630
        done();
3631
      }
3632
    },
3633
    clone(vnode2) {
3634
      return resolveTransitionHooks(vnode2, props, state, instance);
3635
    }
3636
  };
3637
  return hooks;
3638
}
3639
function emptyPlaceholder(vnode) {
3640
  if (isKeepAlive(vnode)) {
3641
    vnode = cloneVNode(vnode);
3642
    vnode.children = null;
3643
    return vnode;
3644
  }
3645
}
3646
function getKeepAliveChild(vnode) {
3647
  return isKeepAlive(vnode) ? vnode.children ? vnode.children[0] : void 0 : vnode;
3648
}
3649
function setTransitionHooks(vnode, hooks) {
3650
  if (vnode.shapeFlag & 6 && vnode.component) {
3651
    setTransitionHooks(vnode.component.subTree, hooks);
3652
  } else if (vnode.shapeFlag & 128) {
3653
    vnode.ssContent.transition = hooks.clone(vnode.ssContent);
3654
    vnode.ssFallback.transition = hooks.clone(vnode.ssFallback);
3655
  } else {
3656
    vnode.transition = hooks;
3657
  }
3658
}
3659
function getTransitionRawChildren(children, keepComment = false, parentKey) {
3660
  let ret = [];
3661
  let keyedFragmentCount = 0;
3662
  for (let i = 0; i < children.length; i++) {
3663
    let child = children[i];
3664
    const key = parentKey == null ? child.key : String(parentKey) + String(child.key != null ? child.key : i);
3665
    if (child.type === Fragment) {
3666
      if (child.patchFlag & 128)
3667
        keyedFragmentCount++;
3668
      ret = ret.concat(
3669
        getTransitionRawChildren(child.children, keepComment, key)
3670
      );
3671
    } else if (keepComment || child.type !== Comment) {
3672
      ret.push(key != null ? cloneVNode(child, { key }) : child);
3673
    }
3674
  }
3675
  if (keyedFragmentCount > 1) {
3676
    for (let i = 0; i < ret.length; i++) {
3677
      ret[i].patchFlag = -2;
3678
    }
3679
  }
3680
  return ret;
3681
}
3682
 
3683
/*! #__NO_SIDE_EFFECTS__ */
3684
// @__NO_SIDE_EFFECTS__
3685
function defineComponent(options, extraOptions) {
3686
  return isFunction(options) ? (
3687
    // #8326: extend call and options.name access are considered side-effects
3688
    // by Rollup, so we have to wrap it in a pure-annotated IIFE.
3689
    /* @__PURE__ */ (() => extend({ name: options.name }, extraOptions, { setup: options }))()
3690
  ) : options;
3691
}
3692
 
3693
const isAsyncWrapper = (i) => !!i.type.__asyncLoader;
3694
/*! #__NO_SIDE_EFFECTS__ */
3695
// @__NO_SIDE_EFFECTS__
3696
function defineAsyncComponent(source) {
3697
  if (isFunction(source)) {
3698
    source = { loader: source };
3699
  }
3700
  const {
3701
    loader,
3702
    loadingComponent,
3703
    errorComponent,
3704
    delay = 200,
3705
    timeout,
3706
    // undefined = never times out
3707
    suspensible = true,
3708
    onError: userOnError
3709
  } = source;
3710
  let pendingRequest = null;
3711
  let resolvedComp;
3712
  let retries = 0;
3713
  const retry = () => {
3714
    retries++;
3715
    pendingRequest = null;
3716
    return load();
3717
  };
3718
  const load = () => {
3719
    let thisRequest;
3720
    return pendingRequest || (thisRequest = pendingRequest = loader().catch((err) => {
3721
      err = err instanceof Error ? err : new Error(String(err));
3722
      if (userOnError) {
3723
        return new Promise((resolve, reject) => {
3724
          const userRetry = () => resolve(retry());
3725
          const userFail = () => reject(err);
3726
          userOnError(err, userRetry, userFail, retries + 1);
3727
        });
3728
      } else {
3729
        throw err;
3730
      }
3731
    }).then((comp) => {
3732
      if (thisRequest !== pendingRequest && pendingRequest) {
3733
        return pendingRequest;
3734
      }
3735
      if (!comp) {
3736
        warn(
3737
          `Async component loader resolved to undefined. If you are using retry(), make sure to return its return value.`
3738
        );
3739
      }
3740
      if (comp && (comp.__esModule || comp[Symbol.toStringTag] === "Module")) {
3741
        comp = comp.default;
3742
      }
3743
      if (comp && !isObject(comp) && !isFunction(comp)) {
3744
        throw new Error(`Invalid async component load result: ${comp}`);
3745
      }
3746
      resolvedComp = comp;
3747
      return comp;
3748
    }));
3749
  };
3750
  return defineComponent({
3751
    name: "AsyncComponentWrapper",
3752
    __asyncLoader: load,
3753
    get __asyncResolved() {
3754
      return resolvedComp;
3755
    },
3756
    setup() {
3757
      const instance = currentInstance;
3758
      if (resolvedComp) {
3759
        return () => createInnerComp(resolvedComp, instance);
3760
      }
3761
      const onError = (err) => {
3762
        pendingRequest = null;
3763
        handleError(
3764
          err,
3765
          instance,
3766
          13,
3767
          !errorComponent
3768
          /* do not throw in dev if user provided error component */
3769
        );
3770
      };
3771
      if (suspensible && instance.suspense || false) {
3772
        return load().then((comp) => {
3773
          return () => createInnerComp(comp, instance);
3774
        }).catch((err) => {
3775
          onError(err);
3776
          return () => errorComponent ? createVNode(errorComponent, {
3777
            error: err
3778
          }) : null;
3779
        });
3780
      }
3781
      const loaded = ref(false);
3782
      const error = ref();
3783
      const delayed = ref(!!delay);
3784
      if (delay) {
3785
        setTimeout(() => {
3786
          delayed.value = false;
3787
        }, delay);
3788
      }
3789
      if (timeout != null) {
3790
        setTimeout(() => {
3791
          if (!loaded.value && !error.value) {
3792
            const err = new Error(
3793
              `Async component timed out after ${timeout}ms.`
3794
            );
3795
            onError(err);
3796
            error.value = err;
3797
          }
3798
        }, timeout);
3799
      }
3800
      load().then(() => {
3801
        loaded.value = true;
3802
        if (instance.parent && isKeepAlive(instance.parent.vnode)) {
3803
          queueJob(instance.parent.update);
3804
        }
3805
      }).catch((err) => {
3806
        onError(err);
3807
        error.value = err;
3808
      });
3809
      return () => {
3810
        if (loaded.value && resolvedComp) {
3811
          return createInnerComp(resolvedComp, instance);
3812
        } else if (error.value && errorComponent) {
3813
          return createVNode(errorComponent, {
3814
            error: error.value
3815
          });
3816
        } else if (loadingComponent && !delayed.value) {
3817
          return createVNode(loadingComponent);
3818
        }
3819
      };
3820
    }
3821
  });
3822
}
3823
function createInnerComp(comp, parent) {
3824
  const { ref: ref2, props, children, ce } = parent.vnode;
3825
  const vnode = createVNode(comp, props, children);
3826
  vnode.ref = ref2;
3827
  vnode.ce = ce;
3828
  delete parent.vnode.ce;
3829
  return vnode;
3830
}
3831
 
3832
const isKeepAlive = (vnode) => vnode.type.__isKeepAlive;
3833
const KeepAliveImpl = {
3834
  name: `KeepAlive`,
3835
  // Marker for special handling inside the renderer. We are not using a ===
3836
  // check directly on KeepAlive in the renderer, because importing it directly
3837
  // would prevent it from being tree-shaken.
3838
  __isKeepAlive: true,
3839
  props: {
3840
    include: [String, RegExp, Array],
3841
    exclude: [String, RegExp, Array],
3842
    max: [String, Number]
3843
  },
3844
  setup(props, { slots }) {
3845
    const instance = getCurrentInstance();
3846
    const sharedContext = instance.ctx;
3847
    const cache = /* @__PURE__ */ new Map();
3848
    const keys = /* @__PURE__ */ new Set();
3849
    let current = null;
3850
    {
3851
      instance.__v_cache = cache;
3852
    }
3853
    const parentSuspense = instance.suspense;
3854
    const {
3855
      renderer: {
3856
        p: patch,
3857
        m: move,
3858
        um: _unmount,
3859
        o: { createElement }
3860
      }
3861
    } = sharedContext;
3862
    const storageContainer = createElement("div");
3863
    sharedContext.activate = (vnode, container, anchor, isSVG, optimized) => {
3864
      const instance2 = vnode.component;
3865
      move(vnode, container, anchor, 0, parentSuspense);
3866
      patch(
3867
        instance2.vnode,
3868
        vnode,
3869
        container,
3870
        anchor,
3871
        instance2,
3872
        parentSuspense,
3873
        isSVG,
3874
        vnode.slotScopeIds,
3875
        optimized
3876
      );
3877
      queuePostRenderEffect(() => {
3878
        instance2.isDeactivated = false;
3879
        if (instance2.a) {
3880
          invokeArrayFns(instance2.a);
3881
        }
3882
        const vnodeHook = vnode.props && vnode.props.onVnodeMounted;
3883
        if (vnodeHook) {
3884
          invokeVNodeHook(vnodeHook, instance2.parent, vnode);
3885
        }
3886
      }, parentSuspense);
3887
      {
3888
        devtoolsComponentAdded(instance2);
3889
      }
3890
    };
3891
    sharedContext.deactivate = (vnode) => {
3892
      const instance2 = vnode.component;
3893
      move(vnode, storageContainer, null, 1, parentSuspense);
3894
      queuePostRenderEffect(() => {
3895
        if (instance2.da) {
3896
          invokeArrayFns(instance2.da);
3897
        }
3898
        const vnodeHook = vnode.props && vnode.props.onVnodeUnmounted;
3899
        if (vnodeHook) {
3900
          invokeVNodeHook(vnodeHook, instance2.parent, vnode);
3901
        }
3902
        instance2.isDeactivated = true;
3903
      }, parentSuspense);
3904
      {
3905
        devtoolsComponentAdded(instance2);
3906
      }
3907
    };
3908
    function unmount(vnode) {
3909
      resetShapeFlag(vnode);
3910
      _unmount(vnode, instance, parentSuspense, true);
3911
    }
3912
    function pruneCache(filter) {
3913
      cache.forEach((vnode, key) => {
3914
        const name = getComponentName(vnode.type);
3915
        if (name && (!filter || !filter(name))) {
3916
          pruneCacheEntry(key);
3917
        }
3918
      });
3919
    }
3920
    function pruneCacheEntry(key) {
3921
      const cached = cache.get(key);
3922
      if (!current || !isSameVNodeType(cached, current)) {
3923
        unmount(cached);
3924
      } else if (current) {
3925
        resetShapeFlag(current);
3926
      }
3927
      cache.delete(key);
3928
      keys.delete(key);
3929
    }
3930
    watch(
3931
      () => [props.include, props.exclude],
3932
      ([include, exclude]) => {
3933
        include && pruneCache((name) => matches(include, name));
3934
        exclude && pruneCache((name) => !matches(exclude, name));
3935
      },
3936
      // prune post-render after `current` has been updated
3937
      { flush: "post", deep: true }
3938
    );
3939
    let pendingCacheKey = null;
3940
    const cacheSubtree = () => {
3941
      if (pendingCacheKey != null) {
3942
        cache.set(pendingCacheKey, getInnerChild(instance.subTree));
3943
      }
3944
    };
3945
    onMounted(cacheSubtree);
3946
    onUpdated(cacheSubtree);
3947
    onBeforeUnmount(() => {
3948
      cache.forEach((cached) => {
3949
        const { subTree, suspense } = instance;
3950
        const vnode = getInnerChild(subTree);
3951
        if (cached.type === vnode.type && cached.key === vnode.key) {
3952
          resetShapeFlag(vnode);
3953
          const da = vnode.component.da;
3954
          da && queuePostRenderEffect(da, suspense);
3955
          return;
3956
        }
3957
        unmount(cached);
3958
      });
3959
    });
3960
    return () => {
3961
      pendingCacheKey = null;
3962
      if (!slots.default) {
3963
        return null;
3964
      }
3965
      const children = slots.default();
3966
      const rawVNode = children[0];
3967
      if (children.length > 1) {
3968
        {
3969
          warn(`KeepAlive should contain exactly one component child.`);
3970
        }
3971
        current = null;
3972
        return children;
3973
      } else if (!isVNode(rawVNode) || !(rawVNode.shapeFlag & 4) && !(rawVNode.shapeFlag & 128)) {
3974
        current = null;
3975
        return rawVNode;
3976
      }
3977
      let vnode = getInnerChild(rawVNode);
3978
      const comp = vnode.type;
3979
      const name = getComponentName(
3980
        isAsyncWrapper(vnode) ? vnode.type.__asyncResolved || {} : comp
3981
      );
3982
      const { include, exclude, max } = props;
3983
      if (include && (!name || !matches(include, name)) || exclude && name && matches(exclude, name)) {
3984
        current = vnode;
3985
        return rawVNode;
3986
      }
3987
      const key = vnode.key == null ? comp : vnode.key;
3988
      const cachedVNode = cache.get(key);
3989
      if (vnode.el) {
3990
        vnode = cloneVNode(vnode);
3991
        if (rawVNode.shapeFlag & 128) {
3992
          rawVNode.ssContent = vnode;
3993
        }
3994
      }
3995
      pendingCacheKey = key;
3996
      if (cachedVNode) {
3997
        vnode.el = cachedVNode.el;
3998
        vnode.component = cachedVNode.component;
3999
        if (vnode.transition) {
4000
          setTransitionHooks(vnode, vnode.transition);
4001
        }
4002
        vnode.shapeFlag |= 512;
4003
        keys.delete(key);
4004
        keys.add(key);
4005
      } else {
4006
        keys.add(key);
4007
        if (max && keys.size > parseInt(max, 10)) {
4008
          pruneCacheEntry(keys.values().next().value);
4009
        }
4010
      }
4011
      vnode.shapeFlag |= 256;
4012
      current = vnode;
4013
      return isSuspense(rawVNode.type) ? rawVNode : vnode;
4014
    };
4015
  }
4016
};
4017
const KeepAlive = KeepAliveImpl;
4018
function matches(pattern, name) {
4019
  if (isArray(pattern)) {
4020
    return pattern.some((p) => matches(p, name));
4021
  } else if (isString(pattern)) {
4022
    return pattern.split(",").includes(name);
4023
  } else if (isRegExp(pattern)) {
4024
    return pattern.test(name);
4025
  }
4026
  return false;
4027
}
4028
function onActivated(hook, target) {
4029
  registerKeepAliveHook(hook, "a", target);
4030
}
4031
function onDeactivated(hook, target) {
4032
  registerKeepAliveHook(hook, "da", target);
4033
}
4034
function registerKeepAliveHook(hook, type, target = currentInstance) {
4035
  const wrappedHook = hook.__wdc || (hook.__wdc = () => {
4036
    let current = target;
4037
    while (current) {
4038
      if (current.isDeactivated) {
4039
        return;
4040
      }
4041
      current = current.parent;
4042
    }
4043
    return hook();
4044
  });
4045
  injectHook(type, wrappedHook, target);
4046
  if (target) {
4047
    let current = target.parent;
4048
    while (current && current.parent) {
4049
      if (isKeepAlive(current.parent.vnode)) {
4050
        injectToKeepAliveRoot(wrappedHook, type, target, current);
4051
      }
4052
      current = current.parent;
4053
    }
4054
  }
4055
}
4056
function injectToKeepAliveRoot(hook, type, target, keepAliveRoot) {
4057
  const injected = injectHook(
4058
    type,
4059
    hook,
4060
    keepAliveRoot,
4061
    true
4062
    /* prepend */
4063
  );
4064
  onUnmounted(() => {
4065
    remove(keepAliveRoot[type], injected);
4066
  }, target);
4067
}
4068
function resetShapeFlag(vnode) {
4069
  vnode.shapeFlag &= ~256;
4070
  vnode.shapeFlag &= ~512;
4071
}
4072
function getInnerChild(vnode) {
4073
  return vnode.shapeFlag & 128 ? vnode.ssContent : vnode;
4074
}
4075
 
4076
function injectHook(type, hook, target = currentInstance, prepend = false) {
4077
  if (target) {
4078
    const hooks = target[type] || (target[type] = []);
4079
    const wrappedHook = hook.__weh || (hook.__weh = (...args) => {
4080
      if (target.isUnmounted) {
4081
        return;
4082
      }
4083
      pauseTracking();
4084
      setCurrentInstance(target);
4085
      const res = callWithAsyncErrorHandling(hook, target, type, args);
4086
      unsetCurrentInstance();
4087
      resetTracking();
4088
      return res;
4089
    });
4090
    if (prepend) {
4091
      hooks.unshift(wrappedHook);
4092
    } else {
4093
      hooks.push(wrappedHook);
4094
    }
4095
    return wrappedHook;
4096
  } else {
4097
    const apiName = toHandlerKey(ErrorTypeStrings[type].replace(/ hook$/, ""));
4098
    warn(
4099
      `${apiName} is called when there is no active component instance to be associated with. Lifecycle injection APIs can only be used during execution of setup().` + (` If you are using async setup(), make sure to register lifecycle hooks before the first await statement.` )
4100
    );
4101
  }
4102
}
4103
const createHook = (lifecycle) => (hook, target = currentInstance) => (
4104
  // post-create lifecycle registrations are noops during SSR (except for serverPrefetch)
4105
  (!isInSSRComponentSetup || lifecycle === "sp") && injectHook(lifecycle, (...args) => hook(...args), target)
4106
);
4107
const onBeforeMount = createHook("bm");
4108
const onMounted = createHook("m");
4109
const onBeforeUpdate = createHook("bu");
4110
const onUpdated = createHook("u");
4111
const onBeforeUnmount = createHook("bum");
4112
const onUnmounted = createHook("um");
4113
const onServerPrefetch = createHook("sp");
4114
const onRenderTriggered = createHook(
4115
  "rtg"
4116
);
4117
const onRenderTracked = createHook(
4118
  "rtc"
4119
);
4120
function onErrorCaptured(hook, target = currentInstance) {
4121
  injectHook("ec", hook, target);
4122
}
4123
 
4124
const COMPONENTS = "components";
4125
const DIRECTIVES = "directives";
4126
function resolveComponent(name, maybeSelfReference) {
4127
  return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
4128
}
4129
const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
4130
function resolveDynamicComponent(component) {
4131
  if (isString(component)) {
4132
    return resolveAsset(COMPONENTS, component, false) || component;
4133
  } else {
4134
    return component || NULL_DYNAMIC_COMPONENT;
4135
  }
4136
}
4137
function resolveDirective(name) {
4138
  return resolveAsset(DIRECTIVES, name);
4139
}
4140
function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
4141
  const instance = currentRenderingInstance || currentInstance;
4142
  if (instance) {
4143
    const Component = instance.type;
4144
    if (type === COMPONENTS) {
4145
      const selfName = getComponentName(
4146
        Component,
4147
        false
4148
        /* do not include inferred name to avoid breaking existing code */
4149
      );
4150
      if (selfName && (selfName === name || selfName === camelize(name) || selfName === capitalize(camelize(name)))) {
4151
        return Component;
4152
      }
4153
    }
4154
    const res = (
4155
      // local registration
4156
      // check instance[type] first which is resolved for options API
4157
      resolve(instance[type] || Component[type], name) || // global registration
4158
      resolve(instance.appContext[type], name)
4159
    );
4160
    if (!res && maybeSelfReference) {
4161
      return Component;
4162
    }
4163
    if (warnMissing && !res) {
4164
      const extra = type === COMPONENTS ? `
4165
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.` : ``;
4166
      warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);
4167
    }
4168
    return res;
4169
  } else {
4170
    warn(
4171
      `resolve${capitalize(type.slice(0, -1))} can only be used in render() or setup().`
4172
    );
4173
  }
4174
}
4175
function resolve(registry, name) {
4176
  return registry && (registry[name] || registry[camelize(name)] || registry[capitalize(camelize(name))]);
4177
}
4178
 
4179
function renderList(source, renderItem, cache, index) {
4180
  let ret;
4181
  const cached = cache && cache[index];
4182
  if (isArray(source) || isString(source)) {
4183
    ret = new Array(source.length);
4184
    for (let i = 0, l = source.length; i < l; i++) {
4185
      ret[i] = renderItem(source[i], i, void 0, cached && cached[i]);
4186
    }
4187
  } else if (typeof source === "number") {
4188
    if (!Number.isInteger(source)) {
4189
      warn(`The v-for range expect an integer value but got ${source}.`);
4190
    }
4191
    ret = new Array(source);
4192
    for (let i = 0; i < source; i++) {
4193
      ret[i] = renderItem(i + 1, i, void 0, cached && cached[i]);
4194
    }
4195
  } else if (isObject(source)) {
4196
    if (source[Symbol.iterator]) {
4197
      ret = Array.from(
4198
        source,
4199
        (item, i) => renderItem(item, i, void 0, cached && cached[i])
4200
      );
4201
    } else {
4202
      const keys = Object.keys(source);
4203
      ret = new Array(keys.length);
4204
      for (let i = 0, l = keys.length; i < l; i++) {
4205
        const key = keys[i];
4206
        ret[i] = renderItem(source[key], key, i, cached && cached[i]);
4207
      }
4208
    }
4209
  } else {
4210
    ret = [];
4211
  }
4212
  if (cache) {
4213
    cache[index] = ret;
4214
  }
4215
  return ret;
4216
}
4217
 
4218
function createSlots(slots, dynamicSlots) {
4219
  for (let i = 0; i < dynamicSlots.length; i++) {
4220
    const slot = dynamicSlots[i];
4221
    if (isArray(slot)) {
4222
      for (let j = 0; j < slot.length; j++) {
4223
        slots[slot[j].name] = slot[j].fn;
4224
      }
4225
    } else if (slot) {
4226
      slots[slot.name] = slot.key ? (...args) => {
4227
        const res = slot.fn(...args);
4228
        if (res)
4229
          res.key = slot.key;
4230
        return res;
4231
      } : slot.fn;
4232
    }
4233
  }
4234
  return slots;
4235
}
4236
 
4237
function renderSlot(slots, name, props = {}, fallback, noSlotted) {
4238
  if (currentRenderingInstance.isCE || currentRenderingInstance.parent && isAsyncWrapper(currentRenderingInstance.parent) && currentRenderingInstance.parent.isCE) {
4239
    if (name !== "default")
4240
      props.name = name;
4241
    return createVNode("slot", props, fallback && fallback());
4242
  }
4243
  let slot = slots[name];
4244
  if (slot && slot.length > 1) {
4245
    warn(
4246
      `SSR-optimized slot function detected in a non-SSR-optimized render function. You need to mark this component with $dynamic-slots in the parent template.`
4247
    );
4248
    slot = () => [];
4249
  }
4250
  if (slot && slot._c) {
4251
    slot._d = false;
4252
  }
4253
  openBlock();
4254
  const validSlotContent = slot && ensureValidVNode(slot(props));
4255
  const rendered = createBlock(
4256
    Fragment,
4257
    {
4258
      key: props.key || // slot content array of a dynamic conditional slot may have a branch
4259
      // key attached in the `createSlots` helper, respect that
4260
      validSlotContent && validSlotContent.key || `_${name}`
4261
    },
4262
    validSlotContent || (fallback ? fallback() : []),
4263
    validSlotContent && slots._ === 1 ? 64 : -2
4264
  );
4265
  if (!noSlotted && rendered.scopeId) {
4266
    rendered.slotScopeIds = [rendered.scopeId + "-s"];
4267
  }
4268
  if (slot && slot._c) {
4269
    slot._d = true;
4270
  }
4271
  return rendered;
4272
}
4273
function ensureValidVNode(vnodes) {
4274
  return vnodes.some((child) => {
4275
    if (!isVNode(child))
4276
      return true;
4277
    if (child.type === Comment)
4278
      return false;
4279
    if (child.type === Fragment && !ensureValidVNode(child.children))
4280
      return false;
4281
    return true;
4282
  }) ? vnodes : null;
4283
}
4284
 
4285
function toHandlers(obj, preserveCaseIfNecessary) {
4286
  const ret = {};
4287
  if (!isObject(obj)) {
4288
    warn(`v-on with no argument expects an object value.`);
4289
    return ret;
4290
  }
4291
  for (const key in obj) {
4292
    ret[preserveCaseIfNecessary && /[A-Z]/.test(key) ? `on:${key}` : toHandlerKey(key)] = obj[key];
4293
  }
4294
  return ret;
4295
}
4296
 
4297
const getPublicInstance = (i) => {
4298
  if (!i)
4299
    return null;
4300
  if (isStatefulComponent(i))
4301
    return getExposeProxy(i) || i.proxy;
4302
  return getPublicInstance(i.parent);
4303
};
4304
const publicPropertiesMap = (
4305
  // Move PURE marker to new line to workaround compiler discarding it
4306
  // due to type annotation
4307
  /* @__PURE__ */ extend(/* @__PURE__ */ Object.create(null), {
4308
    $: (i) => i,
4309
    $el: (i) => i.vnode.el,
4310
    $data: (i) => i.data,
4311
    $props: (i) => shallowReadonly(i.props) ,
4312
    $attrs: (i) => shallowReadonly(i.attrs) ,
4313
    $slots: (i) => shallowReadonly(i.slots) ,
4314
    $refs: (i) => shallowReadonly(i.refs) ,
4315
    $parent: (i) => getPublicInstance(i.parent),
4316
    $root: (i) => getPublicInstance(i.root),
4317
    $emit: (i) => i.emit,
4318
    $options: (i) => resolveMergedOptions(i) ,
4319
    $forceUpdate: (i) => i.f || (i.f = () => queueJob(i.update)),
4320
    $nextTick: (i) => i.n || (i.n = nextTick.bind(i.proxy)),
4321
    $watch: (i) => instanceWatch.bind(i)
4322
  })
4323
);
4324
const isReservedPrefix = (key) => key === "_" || key === "$";
4325
const hasSetupBinding = (state, key) => state !== EMPTY_OBJ && !state.__isScriptSetup && hasOwn(state, key);
4326
const PublicInstanceProxyHandlers = {
4327
  get({ _: instance }, key) {
4328
    const { ctx, setupState, data, props, accessCache, type, appContext } = instance;
4329
    if (key === "__isVue") {
4330
      return true;
4331
    }
4332
    let normalizedProps;
4333
    if (key[0] !== "$") {
4334
      const n = accessCache[key];
4335
      if (n !== void 0) {
4336
        switch (n) {
4337
          case 1 /* SETUP */:
4338
            return setupState[key];
4339
          case 2 /* DATA */:
4340
            return data[key];
4341
          case 4 /* CONTEXT */:
4342
            return ctx[key];
4343
          case 3 /* PROPS */:
4344
            return props[key];
4345
        }
4346
      } else if (hasSetupBinding(setupState, key)) {
4347
        accessCache[key] = 1 /* SETUP */;
4348
        return setupState[key];
4349
      } else if (data !== EMPTY_OBJ && hasOwn(data, key)) {
4350
        accessCache[key] = 2 /* DATA */;
4351
        return data[key];
4352
      } else if (
4353
        // only cache other properties when instance has declared (thus stable)
4354
        // props
4355
        (normalizedProps = instance.propsOptions[0]) && hasOwn(normalizedProps, key)
4356
      ) {
4357
        accessCache[key] = 3 /* PROPS */;
4358
        return props[key];
4359
      } else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {
4360
        accessCache[key] = 4 /* CONTEXT */;
4361
        return ctx[key];
4362
      } else if (shouldCacheAccess) {
4363
        accessCache[key] = 0 /* OTHER */;
4364
      }
4365
    }
4366
    const publicGetter = publicPropertiesMap[key];
4367
    let cssModule, globalProperties;
4368
    if (publicGetter) {
4369
      if (key === "$attrs") {
4370
        track(instance, "get", key);
4371
        markAttrsAccessed();
4372
      } else if (key === "$slots") {
4373
        track(instance, "get", key);
4374
      }
4375
      return publicGetter(instance);
4376
    } else if (
4377
      // css module (injected by vue-loader)
4378
      (cssModule = type.__cssModules) && (cssModule = cssModule[key])
4379
    ) {
4380
      return cssModule;
4381
    } else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {
4382
      accessCache[key] = 4 /* CONTEXT */;
4383
      return ctx[key];
4384
    } else if (
4385
      // global properties
4386
      globalProperties = appContext.config.globalProperties, hasOwn(globalProperties, key)
4387
    ) {
4388
      {
4389
        return globalProperties[key];
4390
      }
4391
    } else if (currentRenderingInstance && (!isString(key) || // #1091 avoid internal isRef/isVNode checks on component instance leading
4392
    // to infinite warning loop
4393
    key.indexOf("__v") !== 0)) {
4394
      if (data !== EMPTY_OBJ && isReservedPrefix(key[0]) && hasOwn(data, key)) {
4395
        warn(
4396
          `Property ${JSON.stringify(
4397
            key
4398
          )} must be accessed via $data because it starts with a reserved character ("$" or "_") and is not proxied on the render context.`
4399
        );
4400
      } else if (instance === currentRenderingInstance) {
4401
        warn(
4402
          `Property ${JSON.stringify(key)} was accessed during render but is not defined on instance.`
4403
        );
4404
      }
4405
    }
4406
  },
4407
  set({ _: instance }, key, value) {
4408
    const { data, setupState, ctx } = instance;
4409
    if (hasSetupBinding(setupState, key)) {
4410
      setupState[key] = value;
4411
      return true;
4412
    } else if (setupState.__isScriptSetup && hasOwn(setupState, key)) {
4413
      warn(`Cannot mutate <script setup> binding "${key}" from Options API.`);
4414
      return false;
4415
    } else if (data !== EMPTY_OBJ && hasOwn(data, key)) {
4416
      data[key] = value;
4417
      return true;
4418
    } else if (hasOwn(instance.props, key)) {
4419
      warn(`Attempting to mutate prop "${key}". Props are readonly.`);
4420
      return false;
4421
    }
4422
    if (key[0] === "$" && key.slice(1) in instance) {
4423
      warn(
4424
        `Attempting to mutate public property "${key}". Properties starting with $ are reserved and readonly.`
4425
      );
4426
      return false;
4427
    } else {
4428
      if (key in instance.appContext.config.globalProperties) {
4429
        Object.defineProperty(ctx, key, {
4430
          enumerable: true,
4431
          configurable: true,
4432
          value
4433
        });
4434
      } else {
4435
        ctx[key] = value;
4436
      }
4437
    }
4438
    return true;
4439
  },
4440
  has({
4441
    _: { data, setupState, accessCache, ctx, appContext, propsOptions }
4442
  }, key) {
4443
    let normalizedProps;
4444
    return !!accessCache[key] || data !== EMPTY_OBJ && hasOwn(data, key) || hasSetupBinding(setupState, key) || (normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key) || hasOwn(ctx, key) || hasOwn(publicPropertiesMap, key) || hasOwn(appContext.config.globalProperties, key);
4445
  },
4446
  defineProperty(target, key, descriptor) {
4447
    if (descriptor.get != null) {
4448
      target._.accessCache[key] = 0;
4449
    } else if (hasOwn(descriptor, "value")) {
4450
      this.set(target, key, descriptor.value, null);
4451
    }
4452
    return Reflect.defineProperty(target, key, descriptor);
4453
  }
4454
};
4455
{
4456
  PublicInstanceProxyHandlers.ownKeys = (target) => {
4457
    warn(
4458
      `Avoid app logic that relies on enumerating keys on a component instance. The keys will be empty in production mode to avoid performance overhead.`
4459
    );
4460
    return Reflect.ownKeys(target);
4461
  };
4462
}
4463
const RuntimeCompiledPublicInstanceProxyHandlers = /* @__PURE__ */ extend(
4464
  {},
4465
  PublicInstanceProxyHandlers,
4466
  {
4467
    get(target, key) {
4468
      if (key === Symbol.unscopables) {
4469
        return;
4470
      }
4471
      return PublicInstanceProxyHandlers.get(target, key, target);
4472
    },
4473
    has(_, key) {
4474
      const has = key[0] !== "_" && !isGloballyAllowed(key);
4475
      if (!has && PublicInstanceProxyHandlers.has(_, key)) {
4476
        warn(
4477
          `Property ${JSON.stringify(
4478
            key
4479
          )} should not start with _ which is a reserved prefix for Vue internals.`
4480
        );
4481
      }
4482
      return has;
4483
    }
4484
  }
4485
);
4486
function createDevRenderContext(instance) {
4487
  const target = {};
4488
  Object.defineProperty(target, `_`, {
4489
    configurable: true,
4490
    enumerable: false,
4491
    get: () => instance
4492
  });
4493
  Object.keys(publicPropertiesMap).forEach((key) => {
4494
    Object.defineProperty(target, key, {
4495
      configurable: true,
4496
      enumerable: false,
4497
      get: () => publicPropertiesMap[key](instance),
4498
      // intercepted by the proxy so no need for implementation,
4499
      // but needed to prevent set errors
4500
      set: NOOP
4501
    });
4502
  });
4503
  return target;
4504
}
4505
function exposePropsOnRenderContext(instance) {
4506
  const {
4507
    ctx,
4508
    propsOptions: [propsOptions]
4509
  } = instance;
4510
  if (propsOptions) {
4511
    Object.keys(propsOptions).forEach((key) => {
4512
      Object.defineProperty(ctx, key, {
4513
        enumerable: true,
4514
        configurable: true,
4515
        get: () => instance.props[key],
4516
        set: NOOP
4517
      });
4518
    });
4519
  }
4520
}
4521
function exposeSetupStateOnRenderContext(instance) {
4522
  const { ctx, setupState } = instance;
4523
  Object.keys(toRaw(setupState)).forEach((key) => {
4524
    if (!setupState.__isScriptSetup) {
4525
      if (isReservedPrefix(key[0])) {
4526
        warn(
4527
          `setup() return property ${JSON.stringify(
4528
            key
4529
          )} should not start with "$" or "_" which are reserved prefixes for Vue internals.`
4530
        );
4531
        return;
4532
      }
4533
      Object.defineProperty(ctx, key, {
4534
        enumerable: true,
4535
        configurable: true,
4536
        get: () => setupState[key],
4537
        set: NOOP
4538
      });
4539
    }
4540
  });
4541
}
4542
 
4543
const warnRuntimeUsage = (method) => warn(
4544
  `${method}() is a compiler-hint helper that is only usable inside <script setup> of a single file component. Its arguments should be compiled away and passing it at runtime has no effect.`
4545
);
4546
function defineProps() {
4547
  {
4548
    warnRuntimeUsage(`defineProps`);
4549
  }
4550
  return null;
4551
}
4552
function defineEmits() {
4553
  {
4554
    warnRuntimeUsage(`defineEmits`);
4555
  }
4556
  return null;
4557
}
4558
function defineExpose(exposed) {
4559
  {
4560
    warnRuntimeUsage(`defineExpose`);
4561
  }
4562
}
4563
function defineOptions(options) {
4564
  {
4565
    warnRuntimeUsage(`defineOptions`);
4566
  }
4567
}
4568
function defineSlots() {
4569
  {
4570
    warnRuntimeUsage(`defineSlots`);
4571
  }
4572
  return null;
4573
}
4574
function defineModel() {
4575
  {
4576
    warnRuntimeUsage("defineModel");
4577
  }
4578
}
4579
function withDefaults(props, defaults) {
4580
  {
4581
    warnRuntimeUsage(`withDefaults`);
4582
  }
4583
  return null;
4584
}
4585
function useSlots() {
4586
  return getContext().slots;
4587
}
4588
function useAttrs() {
4589
  return getContext().attrs;
4590
}
4591
function useModel(props, name, options) {
4592
  const i = getCurrentInstance();
4593
  if (!i) {
4594
    warn(`useModel() called without active instance.`);
4595
    return ref();
4596
  }
4597
  if (!i.propsOptions[0][name]) {
4598
    warn(`useModel() called with prop "${name}" which is not declared.`);
4599
    return ref();
4600
  }
4601
  if (options && options.local) {
4602
    const proxy = ref(props[name]);
4603
    watch(
4604
      () => props[name],
4605
      (v) => proxy.value = v
4606
    );
4607
    watch(proxy, (value) => {
4608
      if (value !== props[name]) {
4609
        i.emit(`update:${name}`, value);
4610
      }
4611
    });
4612
    return proxy;
4613
  } else {
4614
    return {
4615
      __v_isRef: true,
4616
      get value() {
4617
        return props[name];
4618
      },
4619
      set value(value) {
4620
        i.emit(`update:${name}`, value);
4621
      }
4622
    };
4623
  }
4624
}
4625
function getContext() {
4626
  const i = getCurrentInstance();
4627
  if (!i) {
4628
    warn(`useContext() called without active instance.`);
4629
  }
4630
  return i.setupContext || (i.setupContext = createSetupContext(i));
4631
}
4632
function normalizePropsOrEmits(props) {
4633
  return isArray(props) ? props.reduce(
4634
    (normalized, p) => (normalized[p] = null, normalized),
4635
    {}
4636
  ) : props;
4637
}
4638
function mergeDefaults(raw, defaults) {
4639
  const props = normalizePropsOrEmits(raw);
4640
  for (const key in defaults) {
4641
    if (key.startsWith("__skip"))
4642
      continue;
4643
    let opt = props[key];
4644
    if (opt) {
4645
      if (isArray(opt) || isFunction(opt)) {
4646
        opt = props[key] = { type: opt, default: defaults[key] };
4647
      } else {
4648
        opt.default = defaults[key];
4649
      }
4650
    } else if (opt === null) {
4651
      opt = props[key] = { default: defaults[key] };
4652
    } else {
4653
      warn(`props default key "${key}" has no corresponding declaration.`);
4654
    }
4655
    if (opt && defaults[`__skip_${key}`]) {
4656
      opt.skipFactory = true;
4657
    }
4658
  }
4659
  return props;
4660
}
4661
function mergeModels(a, b) {
4662
  if (!a || !b)
4663
    return a || b;
4664
  if (isArray(a) && isArray(b))
4665
    return a.concat(b);
4666
  return extend({}, normalizePropsOrEmits(a), normalizePropsOrEmits(b));
4667
}
4668
function createPropsRestProxy(props, excludedKeys) {
4669
  const ret = {};
4670
  for (const key in props) {
4671
    if (!excludedKeys.includes(key)) {
4672
      Object.defineProperty(ret, key, {
4673
        enumerable: true,
4674
        get: () => props[key]
4675
      });
4676
    }
4677
  }
4678
  return ret;
4679
}
4680
function withAsyncContext(getAwaitable) {
4681
  const ctx = getCurrentInstance();
4682
  if (!ctx) {
4683
    warn(
4684
      `withAsyncContext called without active current instance. This is likely a bug.`
4685
    );
4686
  }
4687
  let awaitable = getAwaitable();
4688
  unsetCurrentInstance();
4689
  if (isPromise(awaitable)) {
4690
    awaitable = awaitable.catch((e) => {
4691
      setCurrentInstance(ctx);
4692
      throw e;
4693
    });
4694
  }
4695
  return [awaitable, () => setCurrentInstance(ctx)];
4696
}
4697
 
4698
function createDuplicateChecker() {
4699
  const cache = /* @__PURE__ */ Object.create(null);
4700
  return (type, key) => {
4701
    if (cache[key]) {
4702
      warn(`${type} property "${key}" is already defined in ${cache[key]}.`);
4703
    } else {
4704
      cache[key] = type;
4705
    }
4706
  };
4707
}
4708
let shouldCacheAccess = true;
4709
function applyOptions(instance) {
4710
  const options = resolveMergedOptions(instance);
4711
  const publicThis = instance.proxy;
4712
  const ctx = instance.ctx;
4713
  shouldCacheAccess = false;
4714
  if (options.beforeCreate) {
4715
    callHook$1(options.beforeCreate, instance, "bc");
4716
  }
4717
  const {
4718
    // state
4719
    data: dataOptions,
4720
    computed: computedOptions,
4721
    methods,
4722
    watch: watchOptions,
4723
    provide: provideOptions,
4724
    inject: injectOptions,
4725
    // lifecycle
4726
    created,
4727
    beforeMount,
4728
    mounted,
4729
    beforeUpdate,
4730
    updated,
4731
    activated,
4732
    deactivated,
4733
    beforeDestroy,
4734
    beforeUnmount,
4735
    destroyed,
4736
    unmounted,
4737
    render,
4738
    renderTracked,
4739
    renderTriggered,
4740
    errorCaptured,
4741
    serverPrefetch,
4742
    // public API
4743
    expose,
4744
    inheritAttrs,
4745
    // assets
4746
    components,
4747
    directives,
4748
    filters
4749
  } = options;
4750
  const checkDuplicateProperties = createDuplicateChecker() ;
4751
  {
4752
    const [propsOptions] = instance.propsOptions;
4753
    if (propsOptions) {
4754
      for (const key in propsOptions) {
4755
        checkDuplicateProperties("Props" /* PROPS */, key);
4756
      }
4757
    }
4758
  }
4759
  if (injectOptions) {
4760
    resolveInjections(injectOptions, ctx, checkDuplicateProperties);
4761
  }
4762
  if (methods) {
4763
    for (const key in methods) {
4764
      const methodHandler = methods[key];
4765
      if (isFunction(methodHandler)) {
4766
        {
4767
          Object.defineProperty(ctx, key, {
4768
            value: methodHandler.bind(publicThis),
4769
            configurable: true,
4770
            enumerable: true,
4771
            writable: true
4772
          });
4773
        }
4774
        {
4775
          checkDuplicateProperties("Methods" /* METHODS */, key);
4776
        }
4777
      } else {
4778
        warn(
4779
          `Method "${key}" has type "${typeof methodHandler}" in the component definition. Did you reference the function correctly?`
4780
        );
4781
      }
4782
    }
4783
  }
4784
  if (dataOptions) {
4785
    if (!isFunction(dataOptions)) {
4786
      warn(
4787
        `The data option must be a function. Plain object usage is no longer supported.`
4788
      );
4789
    }
4790
    const data = dataOptions.call(publicThis, publicThis);
4791
    if (isPromise(data)) {
4792
      warn(
4793
        `data() returned a Promise - note data() cannot be async; If you intend to perform data fetching before component renders, use async setup() + <Suspense>.`
4794
      );
4795
    }
4796
    if (!isObject(data)) {
4797
      warn(`data() should return an object.`);
4798
    } else {
4799
      instance.data = reactive(data);
4800
      {
4801
        for (const key in data) {
4802
          checkDuplicateProperties("Data" /* DATA */, key);
4803
          if (!isReservedPrefix(key[0])) {
4804
            Object.defineProperty(ctx, key, {
4805
              configurable: true,
4806
              enumerable: true,
4807
              get: () => data[key],
4808
              set: NOOP
4809
            });
4810
          }
4811
        }
4812
      }
4813
    }
4814
  }
4815
  shouldCacheAccess = true;
4816
  if (computedOptions) {
4817
    for (const key in computedOptions) {
4818
      const opt = computedOptions[key];
4819
      const get = isFunction(opt) ? opt.bind(publicThis, publicThis) : isFunction(opt.get) ? opt.get.bind(publicThis, publicThis) : NOOP;
4820
      if (get === NOOP) {
4821
        warn(`Computed property "${key}" has no getter.`);
4822
      }