@vue/compat 3.6.0-beta.7 → 3.6.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,30 +1,23 @@
1
1
  /**
2
- * @vue/compat v3.6.0-beta.7
2
+ * @vue/compat v3.6.0-beta.8
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
6
6
  var Vue = (function() {
7
-
8
- //#region \0rolldown/runtime.js
7
+ //#region \0rolldown/runtime.js
9
8
  var __defProp = Object.defineProperty;
10
9
  var __exportAll = (all, no_symbols) => {
11
10
  let target = {};
12
- for (var name in all) {
13
- __defProp(target, name, {
14
- get: all[name],
15
- enumerable: true
16
- });
17
- }
18
- if (!no_symbols) {
19
- __defProp(target, Symbol.toStringTag, { value: "Module" });
20
- }
11
+ for (var name in all) __defProp(target, name, {
12
+ get: all[name],
13
+ enumerable: true
14
+ });
15
+ if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
21
16
  return target;
22
17
  };
23
-
24
- //#endregion
25
-
26
- //#region packages/shared/src/makeMap.ts
27
- /**
18
+ //#endregion
19
+ //#region packages/shared/src/makeMap.ts
20
+ /**
28
21
  * Make a map and return a function for checking if a key
29
22
  * is in that map.
30
23
  * IMPORTANT: all calls of this function must be prefixed with
@@ -37,9 +30,8 @@ var Vue = (function() {
37
30
  for (const key of str.split(",")) map[key] = 1;
38
31
  return (val) => val in map;
39
32
  }
40
-
41
- //#endregion
42
- //#region packages/shared/src/general.ts
33
+ //#endregion
34
+ //#region packages/shared/src/general.ts
43
35
  const EMPTY_OBJ = Object.freeze({});
44
36
  const EMPTY_ARR = Object.freeze([]);
45
37
  const NOOP = () => {};
@@ -155,10 +147,9 @@ var Vue = (function() {
155
147
  function canSetValueDirectly(tagName) {
156
148
  return tagName !== "PROGRESS" && !tagName.includes("-");
157
149
  }
158
-
159
- //#endregion
160
- //#region packages/shared/src/patchFlags.ts
161
- /**
150
+ //#endregion
151
+ //#region packages/shared/src/patchFlags.ts
152
+ /**
162
153
  * dev only flag -> name mapping
163
154
  */
164
155
  const PatchFlagNames = {
@@ -177,10 +168,9 @@ var Vue = (function() {
177
168
  [-1]: `CACHED`,
178
169
  [-2]: `BAIL`
179
170
  };
180
-
181
- //#endregion
182
- //#region packages/shared/src/slotFlags.ts
183
- /**
171
+ //#endregion
172
+ //#region packages/shared/src/slotFlags.ts
173
+ /**
184
174
  * Dev only
185
175
  */
186
176
  const slotFlagsText = {
@@ -188,14 +178,9 @@ var Vue = (function() {
188
178
  [2]: "DYNAMIC",
189
179
  [3]: "FORWARDED"
190
180
  };
191
-
192
- //#endregion
193
- //#region packages/shared/src/globalsAllowList.ts
194
- 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,Error,Symbol";
195
- const isGloballyAllowed = /* @__PURE__ */ makeMap(GLOBALS_ALLOWED);
196
-
197
- //#endregion
198
- //#region packages/shared/src/codeframe.ts
181
+ const isGloballyAllowed = /* @__PURE__ */ makeMap("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,Error,Symbol");
182
+ //#endregion
183
+ //#region packages/shared/src/codeframe.ts
199
184
  const range = 2;
200
185
  function generateCodeFrame(source, start = 0, end = source.length) {
201
186
  start = Math.max(0, Math.min(start, source.length));
@@ -232,9 +217,8 @@ var Vue = (function() {
232
217
  }
233
218
  return res.join("\n");
234
219
  }
235
-
236
- //#endregion
237
- //#region packages/shared/src/normalizeProp.ts
220
+ //#endregion
221
+ //#region packages/shared/src/normalizeProp.ts
238
222
  function normalizeStyle(value) {
239
223
  if (isArray(value)) {
240
224
  const res = {};
@@ -291,9 +275,8 @@ var Vue = (function() {
291
275
  if (style) props.style = normalizeStyle(style);
292
276
  return props;
293
277
  }
294
-
295
- //#endregion
296
- //#region packages/shared/src/domTagConfig.ts
278
+ //#endregion
279
+ //#region packages/shared/src/domTagConfig.ts
297
280
  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";
298
281
  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";
299
282
  const MATH_TAGS = "annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics";
@@ -318,10 +301,9 @@ var Vue = (function() {
318
301
  * Do NOT use in runtime code paths unless behind `__DEV__` flag.
319
302
  */
320
303
  const isVoidTag = /* @__PURE__ */ makeMap(VOID_TAGS);
321
-
322
- //#endregion
323
- //#region packages/shared/src/domAttrConfig.ts
324
- /**
304
+ //#endregion
305
+ //#region packages/shared/src/domAttrConfig.ts
306
+ /**
325
307
  * On the client we only need to offer special cases for boolean attributes that
326
308
  * have different names from their corresponding dom properties:
327
309
  * - itemscope -> N/A
@@ -373,16 +355,14 @@ var Vue = (function() {
373
355
  if (key === "sandbox" && tagName === "IFRAME") return true;
374
356
  return false;
375
357
  }
376
-
377
- //#endregion
378
- //#region packages/shared/src/escapeHtml.ts
358
+ //#endregion
359
+ //#region packages/shared/src/escapeHtml.ts
379
360
  const cssVarNameEscapeSymbolsRE = /[ !"#$%&'()*+,./:;<=>?@[\\\]^`{|}~]/g;
380
361
  function getEscapedCssVarName(key, doubleEscape) {
381
362
  return key.replace(cssVarNameEscapeSymbolsRE, (s) => doubleEscape ? s === "\"" ? "\\\\\\\"" : `\\\\${s}` : `\\${s}`);
382
363
  }
383
-
384
- //#endregion
385
- //#region packages/shared/src/looseEqual.ts
364
+ //#endregion
365
+ //#region packages/shared/src/looseEqual.ts
386
366
  function looseCompareArrays(a, b) {
387
367
  if (a.length !== b.length) return false;
388
368
  let equal = true;
@@ -416,9 +396,8 @@ var Vue = (function() {
416
396
  function looseIndexOf(arr, val) {
417
397
  return arr.findIndex((item) => looseEqual(item, val));
418
398
  }
419
-
420
- //#endregion
421
- //#region packages/shared/src/toDisplayString.ts
399
+ //#endregion
400
+ //#region packages/shared/src/toDisplayString.ts
422
401
  const isRef$1 = (val) => {
423
402
  return !!(val && val["__v_isRef"] === true);
424
403
  };
@@ -451,9 +430,8 @@ var Vue = (function() {
451
430
  var _description;
452
431
  return isSymbol(v) ? `Symbol(${(_description = v.description) !== null && _description !== void 0 ? _description : i})` : v;
453
432
  };
454
-
455
- //#endregion
456
- //#region packages/shared/src/subSequence.ts
433
+ //#endregion
434
+ //#region packages/shared/src/subSequence.ts
457
435
  function getSequence(arr) {
458
436
  const p = arr.slice();
459
437
  const result = [0];
@@ -489,10 +467,9 @@ var Vue = (function() {
489
467
  }
490
468
  return result;
491
469
  }
492
-
493
- //#endregion
494
- //#region packages/shared/src/cssVars.ts
495
- /**
470
+ //#endregion
471
+ //#region packages/shared/src/cssVars.ts
472
+ /**
496
473
  * Normalize CSS var value created by `v-bind` in `<style>` block
497
474
  * See https://github.com/vuejs/core/pull/12461#issuecomment-2495804664
498
475
  */
@@ -502,9 +479,8 @@ var Vue = (function() {
502
479
  if (typeof value !== "number" || !Number.isFinite(value)) console.warn("[Vue warn] Invalid value used for CSS binding. Expected a string or a finite number but received:", value);
503
480
  return String(value);
504
481
  }
505
-
506
- //#endregion
507
- //#region packages/reactivity/src/debug.ts
482
+ //#endregion
483
+ //#region packages/reactivity/src/debug.ts
508
484
  const triggerEventInfos = [];
509
485
  function onTrack(sub, debugInfo) {
510
486
  if (sub.onTrack) sub.onTrack(extend({ effect: sub }, debugInfo));
@@ -538,31 +514,11 @@ var Vue = (function() {
538
514
  }
539
515
  });
540
516
  }
541
-
542
- //#endregion
543
- //#region packages/reactivity/src/warning.ts
517
+ //#endregion
518
+ //#region packages/reactivity/src/warning.ts
544
519
  function warn$2(msg, ...args) {
545
520
  console.warn(`[Vue warn] ${msg}`, ...args);
546
521
  }
547
-
548
- //#endregion
549
- //#region packages/reactivity/src/system.ts
550
- const ReactiveFlags = {
551
- "None": 0,
552
- "0": "None",
553
- "Mutable": 1,
554
- "1": "Mutable",
555
- "Watching": 2,
556
- "2": "Watching",
557
- "RecursedCheck": 4,
558
- "4": "RecursedCheck",
559
- "Recursed": 8,
560
- "8": "Recursed",
561
- "Dirty": 16,
562
- "16": "Dirty",
563
- "Pending": 32,
564
- "32": "Pending"
565
- };
566
522
  const notifyBuffer = [];
567
523
  let batchDepth = 0;
568
524
  let activeSub = void 0;
@@ -770,9 +726,8 @@ var Vue = (function() {
770
726
  }
771
727
  return false;
772
728
  }
773
-
774
- //#endregion
775
- //#region packages/reactivity/src/dep.ts
729
+ //#endregion
730
+ //#region packages/reactivity/src/dep.ts
776
731
  var Dep = class {
777
732
  constructor(map, key) {
778
733
  this.map = map;
@@ -881,10 +836,9 @@ var Vue = (function() {
881
836
  const depMap = targetMap.get(object);
882
837
  return depMap && depMap.get(key);
883
838
  }
884
-
885
- //#endregion
886
- //#region packages/reactivity/src/arrayInstrumentations.ts
887
- /**
839
+ //#endregion
840
+ //#region packages/reactivity/src/arrayInstrumentations.ts
841
+ /**
888
842
  * Track array iteration and return:
889
843
  * - if input is reactive: a cloned raw array with reactive values
890
844
  * - if input is non-reactive or shallowReactive: the original raw array
@@ -1029,16 +983,25 @@ var Vue = (function() {
1029
983
  }
1030
984
  function reduce(self, method, fn, args) {
1031
985
  const arr = shallowReadArray(self);
986
+ const needsWrap = arr !== self && !/* @__PURE__ */ isShallow(self);
1032
987
  let wrappedFn = fn;
988
+ let wrapInitialAccumulator = false;
1033
989
  if (arr !== self) {
1034
- if (!/* @__PURE__ */ isShallow(self)) wrappedFn = function(acc, item, index) {
1035
- return fn.call(this, acc, toWrapped(self, item), index, self);
1036
- };
1037
- else if (fn.length > 3) wrappedFn = function(acc, item, index) {
990
+ if (needsWrap) {
991
+ wrapInitialAccumulator = args.length === 0;
992
+ wrappedFn = function(acc, item, index) {
993
+ if (wrapInitialAccumulator) {
994
+ wrapInitialAccumulator = false;
995
+ acc = toWrapped(self, acc);
996
+ }
997
+ return fn.call(this, acc, toWrapped(self, item), index, self);
998
+ };
999
+ } else if (fn.length > 3) wrappedFn = function(acc, item, index) {
1038
1000
  return fn.call(this, acc, item, index, self);
1039
1001
  };
1040
1002
  }
1041
- return arr[method](wrappedFn, ...args);
1003
+ const result = arr[method](wrappedFn, ...args);
1004
+ return wrapInitialAccumulator ? toWrapped(self, result) : result;
1042
1005
  }
1043
1006
  function searchProxy(self, method, args) {
1044
1007
  const arr = /* @__PURE__ */ toRaw(self);
@@ -1058,9 +1021,8 @@ var Vue = (function() {
1058
1021
  endBatch();
1059
1022
  return res;
1060
1023
  }
1061
-
1062
- //#endregion
1063
- //#region packages/reactivity/src/baseHandlers.ts
1024
+ //#endregion
1025
+ //#region packages/reactivity/src/baseHandlers.ts
1064
1026
  const isNonTrackableKeys = /* @__PURE__ */ makeMap(`__proto__,__v_isRef,__isVue`);
1065
1027
  const builtInSymbols = new Set(/* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((key) => key !== "arguments" && key !== "caller").map((key) => Symbol[key]).filter(isSymbol));
1066
1028
  function hasOwnProperty(key) {
@@ -1167,9 +1129,8 @@ var Vue = (function() {
1167
1129
  const readonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler();
1168
1130
  const shallowReactiveHandlers = /* @__PURE__ */ new MutableReactiveHandler(true);
1169
1131
  const shallowReadonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler(true);
1170
-
1171
- //#endregion
1172
- //#region packages/reactivity/src/collectionHandlers.ts
1132
+ //#endregion
1133
+ //#region packages/reactivity/src/collectionHandlers.ts
1173
1134
  const toShallow = (value) => value;
1174
1135
  const getProto = (v) => Reflect.getPrototypeOf(v);
1175
1136
  function createIterableMethod(method, isReadonly, isShallow) {
@@ -1252,11 +1213,13 @@ var Vue = (function() {
1252
1213
  clear: createReadonlyMethod("clear")
1253
1214
  } : {
1254
1215
  add(value) {
1255
- if (!shallow && !/* @__PURE__ */ isShallow(value) && !/* @__PURE__ */ isReadonly(value)) value = /* @__PURE__ */ toRaw(value);
1256
1216
  const target = /* @__PURE__ */ toRaw(this);
1257
- if (!getProto(target).has.call(target, value)) {
1258
- target.add(value);
1259
- trigger(target, "add", value, value);
1217
+ const proto = getProto(target);
1218
+ const rawValue = /* @__PURE__ */ toRaw(value);
1219
+ const valueToAdd = !shallow && !/* @__PURE__ */ isShallow(value) && !/* @__PURE__ */ isReadonly(value) ? rawValue : value;
1220
+ if (!(proto.has.call(target, valueToAdd) || hasChanged(value, valueToAdd) && proto.has.call(target, value) || hasChanged(rawValue, valueToAdd) && proto.has.call(target, rawValue))) {
1221
+ target.add(valueToAdd);
1222
+ trigger(target, "add", valueToAdd, valueToAdd);
1260
1223
  }
1261
1224
  return this;
1262
1225
  },
@@ -1327,9 +1290,8 @@ var Vue = (function() {
1327
1290
  warn$2(`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.`);
1328
1291
  }
1329
1292
  }
1330
-
1331
- //#endregion
1332
- //#region packages/reactivity/src/reactive.ts
1293
+ //#endregion
1294
+ //#region packages/reactivity/src/reactive.ts
1333
1295
  const reactiveMap = /* @__PURE__ */ new WeakMap();
1334
1296
  const shallowReactiveMap = /* @__PURE__ */ new WeakMap();
1335
1297
  const readonlyMap = /* @__PURE__ */ new WeakMap();
@@ -1591,9 +1553,8 @@ var Vue = (function() {
1591
1553
  * @param value - The value for which a readonly proxy shall be created.
1592
1554
  */
1593
1555
  const toReadonly = (value) => isObject(value) ? /* @__PURE__ */ readonly(value) : value;
1594
-
1595
- //#endregion
1596
- //#region packages/reactivity/src/ref.ts
1556
+ //#endregion
1557
+ //#region packages/reactivity/src/ref.ts
1597
1558
  /* @__NO_SIDE_EFFECTS__ */
1598
1559
  function isRef(r) {
1599
1560
  return r ? r["__v_isRef"] === true : false;
@@ -1660,7 +1621,7 @@ var Vue = (function() {
1660
1621
  }
1661
1622
  }
1662
1623
  update() {
1663
- this.flags &= ~16;
1624
+ this.flags &= -17;
1664
1625
  return hasChanged(this._oldValue, this._oldValue = this._rawValue);
1665
1626
  }
1666
1627
  };
@@ -1866,9 +1827,8 @@ var Vue = (function() {
1866
1827
  function propertyToRef(source, key, defaultValue) {
1867
1828
  return new ObjectRefImpl(source, key, defaultValue);
1868
1829
  }
1869
-
1870
- //#endregion
1871
- //#region packages/reactivity/src/effect.ts
1830
+ //#endregion
1831
+ //#region packages/reactivity/src/effect.ts
1872
1832
  var ReactiveEffect = class {
1873
1833
  fn() {}
1874
1834
  constructor(fn) {
@@ -1975,9 +1935,8 @@ var Vue = (function() {
1975
1935
  sub.cleanupsLength = 0;
1976
1936
  }
1977
1937
  }
1978
-
1979
- //#endregion
1980
- //#region packages/reactivity/src/effectScope.ts
1938
+ //#endregion
1939
+ //#region packages/reactivity/src/effectScope.ts
1981
1940
  let activeEffectScope;
1982
1941
  var EffectScope = class {
1983
1942
  constructor(detached = false) {
@@ -2084,10 +2043,9 @@ var Vue = (function() {
2084
2043
  if (activeEffectScope !== void 0) activeEffectScope.cleanups[activeEffectScope.cleanupsLength++] = fn;
2085
2044
  else if (!failSilently) warn$2("onScopeDispose() is called when there is no active effect scope to be associated with.");
2086
2045
  }
2087
-
2088
- //#endregion
2089
- //#region packages/reactivity/src/computed.ts
2090
- /**
2046
+ //#endregion
2047
+ //#region packages/reactivity/src/computed.ts
2048
+ /**
2091
2049
  * @private exported by @vue/reactivity for Vue core use, but not exported from
2092
2050
  * the main vue package
2093
2051
  */
@@ -2108,7 +2066,7 @@ var Vue = (function() {
2108
2066
  if (flags & 32) if (checkDirty(this.deps, this)) {
2109
2067
  this.flags = flags | 16;
2110
2068
  return true;
2111
- } else this.flags = flags & ~32;
2069
+ } else this.flags = flags & -33;
2112
2070
  return false;
2113
2071
  }
2114
2072
  /**
@@ -2117,7 +2075,7 @@ var Vue = (function() {
2117
2075
  */
2118
2076
  set _dirty(v) {
2119
2077
  if (v) this.flags |= 16;
2120
- else this.flags &= ~(16 | 32);
2078
+ else this.flags &= -49;
2121
2079
  }
2122
2080
  constructor(fn, setter) {
2123
2081
  this.fn = fn;
@@ -2127,7 +2085,7 @@ var Vue = (function() {
2127
2085
  this.subsTail = void 0;
2128
2086
  this.deps = void 0;
2129
2087
  this.depsTail = void 0;
2130
- this.flags = 1 | 16;
2088
+ this.flags = 17;
2131
2089
  this.__v_isRef = true;
2132
2090
  this["__v_isReadonly"] = !setter;
2133
2091
  }
@@ -2138,7 +2096,7 @@ var Vue = (function() {
2138
2096
  const subs = this.subs;
2139
2097
  if (subs !== void 0) shallowPropagate(subs);
2140
2098
  }
2141
- } else if (flags & 32) this.flags = flags & ~32;
2099
+ } else if (flags & 32) this.flags = flags & -33;
2142
2100
  if (activeSub !== void 0) {
2143
2101
  onTrack(activeSub, {
2144
2102
  target: this,
@@ -2185,9 +2143,8 @@ var Vue = (function() {
2185
2143
  }
2186
2144
  return cRef;
2187
2145
  }
2188
-
2189
- //#endregion
2190
- //#region packages/reactivity/src/constants.ts
2146
+ //#endregion
2147
+ //#region packages/reactivity/src/constants.ts
2191
2148
  const TrackOpTypes = {
2192
2149
  "GET": "get",
2193
2150
  "HAS": "has",
@@ -2199,9 +2156,8 @@ var Vue = (function() {
2199
2156
  "DELETE": "delete",
2200
2157
  "CLEAR": "clear"
2201
2158
  };
2202
-
2203
- //#endregion
2204
- //#region packages/reactivity/src/watch.ts
2159
+ //#endregion
2160
+ //#region packages/reactivity/src/watch.ts
2205
2161
  const INITIAL_WATCHER_VALUE = {};
2206
2162
  let activeWatcher = void 0;
2207
2163
  /**
@@ -2342,9 +2298,8 @@ var Vue = (function() {
2342
2298
  }
2343
2299
  return value;
2344
2300
  }
2345
-
2346
- //#endregion
2347
- //#region packages/runtime-core/src/warning.ts
2301
+ //#endregion
2302
+ //#region packages/runtime-core/src/warning.ts
2348
2303
  const stack$1 = [];
2349
2304
  /**
2350
2305
  * @internal
@@ -2369,8 +2324,8 @@ var Vue = (function() {
2369
2324
  const trace = getComponentTrace();
2370
2325
  if (appWarnHandler) callWithErrorHandling(appWarnHandler, instance, 11, [
2371
2326
  msg + args.map((a) => {
2372
- var _a$toString, _a$toString2;
2373
- return (_a$toString = (_a$toString2 = a.toString) === null || _a$toString2 === void 0 ? void 0 : _a$toString2.call(a)) !== null && _a$toString !== void 0 ? _a$toString : JSON.stringify(a);
2327
+ const toString = a.toString;
2328
+ return toString == null ? JSON.stringify(a) : toString.call(a);
2374
2329
  }).join(""),
2375
2330
  instance && instance.proxy || instance,
2376
2331
  trace.map(({ ctx }) => `at <${formatComponentName(instance, ctx.type)}>`).join("\n"),
@@ -2460,9 +2415,8 @@ var Vue = (function() {
2460
2415
  else if (isNaN(val)) warn$1(`${type} is NaN - the duration expression might be incorrect.`);
2461
2416
  }
2462
2417
  /* v8 ignore stop */
2463
-
2464
- //#endregion
2465
- //#region packages/runtime-core/src/errorHandling.ts
2418
+ //#endregion
2419
+ //#region packages/runtime-core/src/errorHandling.ts
2466
2420
  const ErrorCodes = {
2467
2421
  "SETUP_FUNCTION": 0,
2468
2422
  "0": "SETUP_FUNCTION",
@@ -2583,9 +2537,8 @@ var Vue = (function() {
2583
2537
  else console.error(err);
2584
2538
  }
2585
2539
  }
2586
-
2587
- //#endregion
2588
- //#region packages/runtime-core/src/scheduler.ts
2540
+ //#endregion
2541
+ //#region packages/runtime-core/src/scheduler.ts
2589
2542
  const jobs = [];
2590
2543
  let postJobs = [];
2591
2544
  let activePostJobs = null;
@@ -2736,9 +2689,8 @@ var Vue = (function() {
2736
2689
  seen.set(fn, count + 1);
2737
2690
  return false;
2738
2691
  }
2739
-
2740
- //#endregion
2741
- //#region packages/runtime-core/src/hmr.ts
2692
+ //#endregion
2693
+ //#region packages/runtime-core/src/hmr.ts
2742
2694
  let isHmrUpdating = false;
2743
2695
  const hmrDirtyComponents = /* @__PURE__ */ new Map();
2744
2696
  const hmrDirtyComponentsMode = /* @__PURE__ */ new Map();
@@ -2858,9 +2810,8 @@ var Vue = (function() {
2858
2810
  }
2859
2811
  };
2860
2812
  }
2861
-
2862
- //#endregion
2863
- //#region packages/runtime-core/src/devtools.ts
2813
+ //#endregion
2814
+ //#region packages/runtime-core/src/devtools.ts
2864
2815
  let devtools$1;
2865
2816
  let buffer = [];
2866
2817
  let devtoolsNotInstalled = false;
@@ -2927,9 +2878,8 @@ var Vue = (function() {
2927
2878
  function devtoolsComponentEmit(component, event, params) {
2928
2879
  emit$2("component:emit", component.appContext.app, component, event, params);
2929
2880
  }
2930
-
2931
- //#endregion
2932
- //#region packages/runtime-core/src/compat/compatConfig.ts
2881
+ //#endregion
2882
+ //#region packages/runtime-core/src/compat/compatConfig.ts
2933
2883
  const DeprecationTypes$1 = {
2934
2884
  "GLOBAL_MOUNT": "GLOBAL_MOUNT",
2935
2885
  "GLOBAL_MOUNT_CONTAINER": "GLOBAL_MOUNT_CONTAINER",
@@ -3198,9 +3148,8 @@ var Vue = (function() {
3198
3148
  if (enabled) warnDeprecation$1(key, instance, ...args);
3199
3149
  return enabled;
3200
3150
  }
3201
-
3202
- //#endregion
3203
- //#region packages/runtime-core/src/compat/instanceEventEmitter.ts
3151
+ //#endregion
3152
+ //#region packages/runtime-core/src/compat/instanceEventEmitter.ts
3204
3153
  const eventRegistryMap = /* @__PURE__ */ new WeakMap();
3205
3154
  function getRegistry(instance) {
3206
3155
  let events = eventRegistryMap.get(instance);
@@ -3252,10 +3201,9 @@ var Vue = (function() {
3252
3201
  if (cbs) callWithAsyncErrorHandling(cbs.map((cb) => cb.bind(instance.proxy)), instance, 6, args);
3253
3202
  return instance.proxy;
3254
3203
  }
3255
-
3256
- //#endregion
3257
- //#region packages/runtime-core/src/componentRenderContext.ts
3258
- /**
3204
+ //#endregion
3205
+ //#region packages/runtime-core/src/componentRenderContext.ts
3206
+ /**
3259
3207
  * mark the current rendering instance for asset resolution (e.g.
3260
3208
  * resolveComponent, resolveDirective) during render
3261
3209
  */
@@ -3324,9 +3272,8 @@ var Vue = (function() {
3324
3272
  if (isNonScopedSlot) renderFnWithContext._ns = true;
3325
3273
  return renderFnWithContext;
3326
3274
  }
3327
-
3328
- //#endregion
3329
- //#region packages/runtime-core/src/compat/customDirective.ts
3275
+ //#endregion
3276
+ //#region packages/runtime-core/src/compat/customDirective.ts
3330
3277
  const legacyDirectiveHookMap = {
3331
3278
  beforeMount: "bind",
3332
3279
  mounted: "inserted",
@@ -3350,9 +3297,8 @@ var Vue = (function() {
3350
3297
  return dir[mappedName];
3351
3298
  }
3352
3299
  }
3353
-
3354
- //#endregion
3355
- //#region packages/runtime-core/src/directives.ts
3300
+ //#endregion
3301
+ //#region packages/runtime-core/src/directives.ts
3356
3302
  function validateDirectiveName(name) {
3357
3303
  if (isBuiltInDirective(name)) warn$1("Do not use built-in directive ids as custom directive id: " + name);
3358
3304
  }
@@ -3406,9 +3352,8 @@ var Vue = (function() {
3406
3352
  }
3407
3353
  }
3408
3354
  }
3409
-
3410
- //#endregion
3411
- //#region packages/runtime-core/src/apiInject.ts
3355
+ //#endregion
3356
+ //#region packages/runtime-core/src/apiInject.ts
3412
3357
  function provide(key, value) {
3413
3358
  if (!currentInstance || currentInstance.isMounted && !isHmrUpdating) warn$1(`provide() can only be used inside setup().`);
3414
3359
  if (currentInstance) {
@@ -3435,16 +3380,14 @@ var Vue = (function() {
3435
3380
  function hasInjectionContext() {
3436
3381
  return !!(getCurrentGenericInstance() || currentApp);
3437
3382
  }
3438
-
3439
- //#endregion
3440
- //#region packages/runtime-core/src/helpers/useSsrContext.ts
3383
+ //#endregion
3384
+ //#region packages/runtime-core/src/helpers/useSsrContext.ts
3441
3385
  const ssrContextKey = Symbol.for("v-scx");
3442
3386
  const useSSRContext = () => {
3443
3387
  warn$1(`useSSRContext() is not supported in the global build.`);
3444
3388
  };
3445
-
3446
- //#endregion
3447
- //#region packages/runtime-core/src/apiWatch.ts
3389
+ //#endregion
3390
+ //#region packages/runtime-core/src/apiWatch.ts
3448
3391
  function watchEffect(effect, options) {
3449
3392
  return doWatch(effect, null, options);
3450
3393
  }
@@ -3525,9 +3468,8 @@ var Vue = (function() {
3525
3468
  return cur;
3526
3469
  };
3527
3470
  }
3528
-
3529
- //#endregion
3530
- //#region packages/runtime-core/src/components/Teleport.ts
3471
+ //#endregion
3472
+ //#region packages/runtime-core/src/components/Teleport.ts
3531
3473
  const TeleportEndKey = Symbol("_vte");
3532
3474
  const isTeleport = (type) => type.__isTeleport;
3533
3475
  const isTeleportDisabled = (props) => props && (props.disabled || props.disabled === "");
@@ -3723,9 +3665,8 @@ var Vue = (function() {
3723
3665
  }
3724
3666
  return targetAnchor;
3725
3667
  }
3726
-
3727
- //#endregion
3728
- //#region packages/runtime-core/src/components/BaseTransition.ts
3668
+ //#endregion
3669
+ //#region packages/runtime-core/src/components/BaseTransition.ts
3729
3670
  const leaveCbKey = Symbol("_leaveCb");
3730
3671
  const enterCbKey$1 = Symbol("_enterCb");
3731
3672
  function useTransitionState() {
@@ -3987,16 +3928,14 @@ var Vue = (function() {
3987
3928
  function checkTransitionMode(mode) {
3988
3929
  if (mode && mode !== "in-out" && mode !== "out-in" && mode !== "default") warn$1(`invalid <transition> mode: ${mode}`);
3989
3930
  }
3990
-
3991
- //#endregion
3992
- //#region packages/runtime-core/src/apiDefineComponent.ts
3931
+ //#endregion
3932
+ //#region packages/runtime-core/src/apiDefineComponent.ts
3993
3933
  /* @__NO_SIDE_EFFECTS__ */
3994
3934
  function defineComponent(options, extraOptions) {
3995
3935
  return isFunction(options) ? extend({ name: options.name }, extraOptions, { setup: options }) : options;
3996
3936
  }
3997
-
3998
- //#endregion
3999
- //#region packages/runtime-core/src/helpers/useId.ts
3937
+ //#endregion
3938
+ //#region packages/runtime-core/src/helpers/useId.ts
4000
3939
  function useId() {
4001
3940
  const i = getCurrentGenericInstance();
4002
3941
  if (i) return (i.appContext.config.idPrefix || "v") + "-" + i.ids[0] + i.ids[1]++;
@@ -4016,9 +3955,8 @@ var Vue = (function() {
4016
3955
  0
4017
3956
  ];
4018
3957
  }
4019
-
4020
- //#endregion
4021
- //#region packages/runtime-core/src/helpers/useTemplateRef.ts
3958
+ //#endregion
3959
+ //#region packages/runtime-core/src/helpers/useTemplateRef.ts
4022
3960
  const knownTemplateRefs = /* @__PURE__ */ new WeakSet();
4023
3961
  function useTemplateRef(key) {
4024
3962
  const i = getCurrentGenericInstance();
@@ -4040,9 +3978,8 @@ var Vue = (function() {
4040
3978
  let desc;
4041
3979
  return !!((desc = Object.getOwnPropertyDescriptor(refs, key)) && !desc.configurable);
4042
3980
  }
4043
-
4044
- //#endregion
4045
- //#region packages/runtime-core/src/rendererTemplateRef.ts
3981
+ //#endregion
3982
+ //#region packages/runtime-core/src/rendererTemplateRef.ts
4046
3983
  const pendingSetRefMap = /* @__PURE__ */ new WeakMap();
4047
3984
  /**
4048
3985
  * Function for handling a template ref
@@ -4139,20 +4076,12 @@ var Vue = (function() {
4139
4076
  pendingSetRefMap.delete(rawRef);
4140
4077
  }
4141
4078
  }
4142
-
4143
- //#endregion
4144
- //#region packages/runtime-core/src/hydration.ts
4079
+ //#endregion
4080
+ //#region packages/runtime-core/src/hydration.ts
4145
4081
  let isHydratingEnabled = false;
4146
4082
  function setIsHydratingEnabled(value) {
4147
4083
  isHydratingEnabled = value;
4148
4084
  }
4149
- /**
4150
- * VDOM hydration state.
4151
- * Also used by vapor interop plugin for tree-shaking:
4152
- * In non-hydration builds, this is never set to true, so the logic in
4153
- * vaporInteropImpl's hydrate/hydrateSlot can be tree-shaken.
4154
- */
4155
- let isHydrating = false;
4156
4085
  let hasLoggedMismatchError = false;
4157
4086
  const logMismatchError = () => {
4158
4087
  if (hasLoggedMismatchError) return;
@@ -4178,9 +4107,7 @@ var Vue = (function() {
4178
4107
  container._vnode = vnode;
4179
4108
  return;
4180
4109
  }
4181
- isHydrating = true;
4182
4110
  hydrateNode(container.firstChild, vnode, null, null, null);
4183
- isHydrating = false;
4184
4111
  flushPostFlushCbs();
4185
4112
  container._vnode = vnode;
4186
4113
  };
@@ -4549,9 +4476,8 @@ var Vue = (function() {
4549
4476
  return list.includes(MismatchTypeString[allowedType]);
4550
4477
  }
4551
4478
  }
4552
-
4553
- //#endregion
4554
- //#region packages/runtime-core/src/hydrationStrategies.ts
4479
+ //#endregion
4480
+ //#region packages/runtime-core/src/hydrationStrategies.ts
4555
4481
  let requestIdleCallback;
4556
4482
  let cancelIdleCallback;
4557
4483
  function ensureIdleCallbacks() {
@@ -4638,9 +4564,8 @@ var Vue = (function() {
4638
4564
  }
4639
4565
  } else cb(node);
4640
4566
  }
4641
-
4642
- //#endregion
4643
- //#region packages/runtime-core/src/apiAsyncComponent.ts
4567
+ //#endregion
4568
+ //#region packages/runtime-core/src/apiAsyncComponent.ts
4644
4569
  const isAsyncWrapper = (i) => !!i.type.__asyncLoader;
4645
4570
  /* @__NO_SIDE_EFFECTS__ */
4646
4571
  function defineAsyncComponent(source) {
@@ -4775,9 +4700,8 @@ var Vue = (function() {
4775
4700
  if (getResolvedComp()) doHydrate();
4776
4701
  else load().then(() => !instance.isUnmounted && doHydrate());
4777
4702
  }
4778
-
4779
- //#endregion
4780
- //#region packages/runtime-core/src/components/KeepAlive.ts
4703
+ //#endregion
4704
+ //#region packages/runtime-core/src/components/KeepAlive.ts
4781
4705
  const isKeepAlive = (vnode) => vnode.type.__isKeepAlive;
4782
4706
  const KeepAliveImpl = {
4783
4707
  name: `KeepAlive`,
@@ -4997,9 +4921,8 @@ var Vue = (function() {
4997
4921
  }, void 0, parentSuspense);
4998
4922
  devtoolsComponentAdded(instance);
4999
4923
  }
5000
-
5001
- //#endregion
5002
- //#region packages/runtime-core/src/apiLifecycle.ts
4924
+ //#endregion
4925
+ //#region packages/runtime-core/src/apiLifecycle.ts
5003
4926
  function injectHook(type, hook, target = currentInstance, prepend = false) {
5004
4927
  if (target) {
5005
4928
  const hooks = target[type] || (target[type] = []);
@@ -5033,9 +4956,8 @@ var Vue = (function() {
5033
4956
  function onErrorCaptured(hook, target = currentInstance) {
5034
4957
  injectHook("ec", hook, target);
5035
4958
  }
5036
-
5037
- //#endregion
5038
- //#region packages/runtime-core/src/compat/instanceChildren.ts
4959
+ //#endregion
4960
+ //#region packages/runtime-core/src/compat/instanceChildren.ts
5039
4961
  function getCompatChildren(instance) {
5040
4962
  assertCompatEnabled("INSTANCE_CHILDREN", instance);
5041
4963
  const root = instance.subTree;
@@ -5050,9 +4972,8 @@ var Vue = (function() {
5050
4972
  for (let i = 0; i < vnodes.length; i++) walk$1(vnodes[i], children);
5051
4973
  }
5052
4974
  }
5053
-
5054
- //#endregion
5055
- //#region packages/runtime-core/src/compat/instanceListeners.ts
4975
+ //#endregion
4976
+ //#region packages/runtime-core/src/compat/instanceListeners.ts
5056
4977
  function getCompatListeners(instance) {
5057
4978
  assertCompatEnabled("INSTANCE_LISTENERS", instance);
5058
4979
  const listeners = {};
@@ -5061,24 +4982,20 @@ var Vue = (function() {
5061
4982
  for (const key in rawProps) if (isOn(key)) listeners[key[2].toLowerCase() + key.slice(3)] = rawProps[key];
5062
4983
  return listeners;
5063
4984
  }
5064
-
5065
- //#endregion
5066
- //#region packages/runtime-core/src/helpers/resolveAssets.ts
5067
- const COMPONENTS = "components";
5068
4985
  const DIRECTIVES = "directives";
5069
4986
  const FILTERS = "filters";
5070
4987
  /**
5071
4988
  * @private
5072
4989
  */
5073
4990
  function resolveComponent(name, maybeSelfReference) {
5074
- return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
4991
+ return resolveAsset("components", name, true, maybeSelfReference) || name;
5075
4992
  }
5076
4993
  const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
5077
4994
  /**
5078
4995
  * @private
5079
4996
  */
5080
4997
  function resolveDynamicComponent(component) {
5081
- if (isString(component)) return resolveAsset(COMPONENTS, component, false) || component;
4998
+ if (isString(component)) return resolveAsset("components", component, false) || component;
5082
4999
  else return component || NULL_DYNAMIC_COMPONENT;
5083
5000
  }
5084
5001
  /**
@@ -5098,14 +5015,14 @@ var Vue = (function() {
5098
5015
  const instance = currentRenderingInstance || currentInstance;
5099
5016
  if (instance) {
5100
5017
  const Component = instance.type;
5101
- if (type === COMPONENTS) {
5018
+ if (type === "components") {
5102
5019
  const selfName = getComponentName(Component, false);
5103
5020
  if (selfName && (selfName === name || selfName === camelize(name) || selfName === capitalize(camelize(name)))) return Component;
5104
5021
  }
5105
5022
  const res = resolve(instance[type] || Component[type], name) || resolve(instance.appContext[type], name);
5106
5023
  if (!res && maybeSelfReference) return Component;
5107
5024
  if (warnMissing && !res) {
5108
- const extra = type === COMPONENTS ? "\nIf this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement." : ``;
5025
+ const extra = type === "components" ? "\nIf this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement." : ``;
5109
5026
  warn$1(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);
5110
5027
  }
5111
5028
  return res;
@@ -5114,9 +5031,8 @@ var Vue = (function() {
5114
5031
  function resolve(registry, name) {
5115
5032
  return registry && (registry[name] || registry[camelize(name)] || registry[capitalize(camelize(name))]);
5116
5033
  }
5117
-
5118
- //#endregion
5119
- //#region packages/runtime-core/src/compat/renderFn.ts
5034
+ //#endregion
5035
+ //#region packages/runtime-core/src/compat/renderFn.ts
5120
5036
  function convertLegacyRenderFn(instance) {
5121
5037
  const Component = instance.type;
5122
5038
  const render = Component.render;
@@ -5250,9 +5166,8 @@ var Vue = (function() {
5250
5166
  }
5251
5167
  /* v8 ignore stop */
5252
5168
  }
5253
-
5254
- //#endregion
5255
- //#region packages/runtime-core/src/compat/componentFunctional.ts
5169
+ //#endregion
5170
+ //#region packages/runtime-core/src/compat/componentFunctional.ts
5256
5171
  const normalizedFunctionalComponentMap = /* @__PURE__ */ new WeakMap();
5257
5172
  const legacySlotProxyHandlers = { get(target, key) {
5258
5173
  const slot = target[key];
@@ -5292,10 +5207,9 @@ var Vue = (function() {
5292
5207
  normalizedFunctionalComponentMap.set(comp, Func);
5293
5208
  return Func;
5294
5209
  }
5295
-
5296
- //#endregion
5297
- //#region packages/runtime-core/src/helpers/renderList.ts
5298
- /**
5210
+ //#endregion
5211
+ //#region packages/runtime-core/src/helpers/renderList.ts
5212
+ /**
5299
5213
  * Actual implementation
5300
5214
  */
5301
5215
  function renderList(source, renderItem, cache, index) {
@@ -5313,11 +5227,14 @@ var Vue = (function() {
5313
5227
  }
5314
5228
  ret = new Array(source.length);
5315
5229
  for (let i = 0, l = source.length; i < l; i++) ret[i] = renderItem(needsWrap ? isReadonlySource ? toReadonly(toReactive(source[i])) : toReactive(source[i]) : source[i], i, void 0, cached && cached[i]);
5316
- } else if (typeof source === "number") {
5317
- if (!Number.isInteger(source)) warn$1(`The v-for range expect an integer value but got ${source}.`);
5230
+ } else if (typeof source === "number") if (!Number.isInteger(source) || source < 0) {
5231
+ warn$1(`The v-for range expects a positive integer value but got ${source}.`);
5232
+ ret = [];
5233
+ } else {
5318
5234
  ret = new Array(source);
5319
5235
  for (let i = 0; i < source; i++) ret[i] = renderItem(i + 1, i, void 0, cached && cached[i]);
5320
- } else if (isObject(source)) if (source[Symbol.iterator]) ret = Array.from(source, (item, i) => renderItem(item, i, void 0, cached && cached[i]));
5236
+ }
5237
+ else if (isObject(source)) if (source[Symbol.iterator]) ret = Array.from(source, (item, i) => renderItem(item, i, void 0, cached && cached[i]));
5321
5238
  else {
5322
5239
  const keys = Object.keys(source);
5323
5240
  ret = new Array(keys.length);
@@ -5330,10 +5247,9 @@ var Vue = (function() {
5330
5247
  if (cache) cache[index] = ret;
5331
5248
  return ret;
5332
5249
  }
5333
-
5334
- //#endregion
5335
- //#region packages/runtime-core/src/helpers/createSlots.ts
5336
- /**
5250
+ //#endregion
5251
+ //#region packages/runtime-core/src/helpers/createSlots.ts
5252
+ /**
5337
5253
  * Compiler runtime helper for creating dynamic slots object
5338
5254
  * @private
5339
5255
  */
@@ -5349,10 +5265,9 @@ var Vue = (function() {
5349
5265
  }
5350
5266
  return slots;
5351
5267
  }
5352
-
5353
- //#endregion
5354
- //#region packages/runtime-core/src/helpers/renderSlot.ts
5355
- /**
5268
+ //#endregion
5269
+ //#region packages/runtime-core/src/helpers/renderSlot.ts
5270
+ /**
5356
5271
  * Compiler runtime helper for rendering `<slot/>`
5357
5272
  * @private
5358
5273
  */
@@ -5400,10 +5315,9 @@ var Vue = (function() {
5400
5315
  if (!vaporSlot.fallback && fallback) vaporSlot.fallback = fallback;
5401
5316
  }
5402
5317
  }
5403
-
5404
- //#endregion
5405
- //#region packages/runtime-core/src/helpers/toHandlers.ts
5406
- /**
5318
+ //#endregion
5319
+ //#region packages/runtime-core/src/helpers/toHandlers.ts
5320
+ /**
5407
5321
  * For prefixing keys in v-on="obj" with "on"
5408
5322
  * @private
5409
5323
  */
@@ -5416,9 +5330,8 @@ var Vue = (function() {
5416
5330
  for (const key in obj) ret[preserveCaseIfNecessary && /[A-Z]/.test(key) ? `on:${key}` : toHandlerKey(key)] = obj[key];
5417
5331
  return ret;
5418
5332
  }
5419
-
5420
- //#endregion
5421
- //#region packages/runtime-core/src/compat/renderHelpers.ts
5333
+ //#endregion
5334
+ //#region packages/runtime-core/src/compat/renderHelpers.ts
5422
5335
  function toObject(arr) {
5423
5336
  const res = {};
5424
5337
  for (let i = 0; i < arr.length; i++) if (arr[i]) extend(res, arr[i]);
@@ -5498,9 +5411,8 @@ var Vue = (function() {
5498
5411
  function legacyPrependModifier(value, symbol) {
5499
5412
  return typeof value === "string" ? symbol + value : value;
5500
5413
  }
5501
-
5502
- //#endregion
5503
- //#region packages/runtime-core/src/compat/instance.ts
5414
+ //#endregion
5415
+ //#region packages/runtime-core/src/compat/instance.ts
5504
5416
  function installCompatInstanceProperties(map) {
5505
5417
  const set = (target, key, val) => {
5506
5418
  target[key] = val;
@@ -5587,10 +5499,9 @@ var Vue = (function() {
5587
5499
  if (isCompatEnabled$1("PRIVATE_APIS", i)) return privateAPIs[key](i);
5588
5500
  };
5589
5501
  }
5590
-
5591
- //#endregion
5592
- //#region packages/runtime-core/src/componentPublicInstance.ts
5593
- /**
5502
+ //#endregion
5503
+ //#region packages/runtime-core/src/componentPublicInstance.ts
5504
+ /**
5594
5505
  * #2437 In Vue 3, functional components do not have a public instance proxy but
5595
5506
  * they exist in the internal parent chain. For code that relies on traversing
5596
5507
  * public $parent chains, skip functional ones and go to the parent instead.
@@ -5773,9 +5684,8 @@ var Vue = (function() {
5773
5684
  }
5774
5685
  });
5775
5686
  }
5776
-
5777
- //#endregion
5778
- //#region packages/runtime-core/src/compat/data.ts
5687
+ //#endregion
5688
+ //#region packages/runtime-core/src/compat/data.ts
5779
5689
  function deepMergeData(to, from) {
5780
5690
  for (const key in from) {
5781
5691
  const toVal = to[key];
@@ -5787,9 +5697,8 @@ var Vue = (function() {
5787
5697
  }
5788
5698
  return to;
5789
5699
  }
5790
-
5791
- //#endregion
5792
- //#region packages/runtime-core/src/apiSetupHelpers.ts
5700
+ //#endregion
5701
+ //#region packages/runtime-core/src/apiSetupHelpers.ts
5793
5702
  const warnRuntimeUsage = (method) => warn$1(`${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.`);
5794
5703
  function defineProps() {
5795
5704
  warnRuntimeUsage(`defineProps`);
@@ -5826,6 +5735,22 @@ var Vue = (function() {
5826
5735
  function defineOptions(options) {
5827
5736
  warnRuntimeUsage(`defineOptions`);
5828
5737
  }
5738
+ /**
5739
+ * Vue `<script setup>` compiler macro for providing type hints to IDEs for
5740
+ * slot name and slot props type checking.
5741
+ *
5742
+ * Example usage:
5743
+ * ```ts
5744
+ * const slots = defineSlots<{
5745
+ * default(props: { msg: string }): any
5746
+ * }>()
5747
+ * ```
5748
+ *
5749
+ * This is only usable inside `<script setup>`, is compiled away in the
5750
+ * output and should **not** be actually called at runtime.
5751
+ *
5752
+ * @see {@link https://vuejs.org/api/sfc-script-setup.html#defineslots}
5753
+ */
5829
5754
  function defineSlots() {
5830
5755
  warnRuntimeUsage(`defineSlots`);
5831
5756
  return null;
@@ -5942,23 +5867,31 @@ var Vue = (function() {
5942
5867
  */
5943
5868
  function withAsyncContext(getAwaitable) {
5944
5869
  const ctx = getCurrentGenericInstance();
5870
+ const inSSRSetup = isInSSRComponentSetup;
5945
5871
  if (!ctx) warn$1("withAsyncContext called without active current instance. This is likely a bug.");
5946
5872
  let awaitable = getAwaitable();
5947
5873
  setCurrentInstance(null, void 0);
5948
- const cleanup = () => setCurrentInstance(null, void 0);
5949
- if (isPromise(awaitable)) awaitable = awaitable.catch((e) => {
5874
+ if (inSSRSetup) setInSSRSetupState(false);
5875
+ const restore = () => {
5950
5876
  setCurrentInstance(ctx);
5877
+ if (inSSRSetup) setInSSRSetupState(true);
5878
+ };
5879
+ const cleanup = () => {
5880
+ setCurrentInstance(null, void 0);
5881
+ if (inSSRSetup) setInSSRSetupState(false);
5882
+ };
5883
+ if (isPromise(awaitable)) awaitable = awaitable.catch((e) => {
5884
+ restore();
5951
5885
  Promise.resolve().then(() => Promise.resolve().then(cleanup));
5952
5886
  throw e;
5953
5887
  });
5954
5888
  return [awaitable, () => {
5955
- setCurrentInstance(ctx);
5889
+ restore();
5956
5890
  Promise.resolve().then(cleanup);
5957
5891
  }];
5958
5892
  }
5959
-
5960
- //#endregion
5961
- //#region packages/runtime-core/src/componentOptions.ts
5893
+ //#endregion
5894
+ //#region packages/runtime-core/src/componentOptions.ts
5962
5895
  function createDuplicateChecker() {
5963
5896
  const cache = Object.create(null);
5964
5897
  return (type, key) => {
@@ -6222,9 +6155,8 @@ var Vue = (function() {
6222
6155
  for (const key in from) merged[key] = mergeAsArray$1(to[key], from[key]);
6223
6156
  return merged;
6224
6157
  }
6225
-
6226
- //#endregion
6227
- //#region packages/runtime-core/src/compat/globalConfig.ts
6158
+ //#endregion
6159
+ //#region packages/runtime-core/src/compat/globalConfig.ts
6228
6160
  function installLegacyConfigWarnings(config) {
6229
6161
  const legacyConfigOptions = {
6230
6162
  silent: "CONFIG_SILENT",
@@ -6253,9 +6185,8 @@ var Vue = (function() {
6253
6185
  if (key in internalOptionMergeStrats && softAssertCompatEnabled("CONFIG_OPTION_MERGE_STRATS", null)) return internalOptionMergeStrats[key];
6254
6186
  } });
6255
6187
  }
6256
-
6257
- //#endregion
6258
- //#region packages/runtime-core/src/compat/global.ts
6188
+ //#endregion
6189
+ //#region packages/runtime-core/src/compat/global.ts
6259
6190
  let isCopyingConfig = false;
6260
6191
  let singletonApp;
6261
6192
  let singletonCtor;
@@ -6274,7 +6205,7 @@ var Vue = (function() {
6274
6205
  if (options.el) return vm.$mount(options.el);
6275
6206
  else return vm;
6276
6207
  }
6277
- Vue.version = `2.6.14-compat:3.6.0-beta.7`;
6208
+ Vue.version = `2.6.14-compat:3.6.0-beta.8`;
6278
6209
  Vue.config = singletonApp.config;
6279
6210
  Vue.use = (plugin, ...options) => {
6280
6211
  if (plugin && isFunction(plugin.install)) plugin.install(Vue, ...options);
@@ -6554,9 +6485,8 @@ var Vue = (function() {
6554
6485
  }
6555
6486
  });
6556
6487
  }
6557
-
6558
- //#endregion
6559
- //#region packages/runtime-core/src/apiCreateApp.ts
6488
+ //#endregion
6489
+ //#region packages/runtime-core/src/apiCreateApp.ts
6560
6490
  function createAppContext() {
6561
6491
  return {
6562
6492
  app: null,
@@ -6687,9 +6617,8 @@ var Vue = (function() {
6687
6617
  * `app.runWithContext()`.
6688
6618
  */
6689
6619
  let currentApp = null;
6690
-
6691
- //#endregion
6692
- //#region packages/runtime-core/src/compat/componentVModel.ts
6620
+ //#endregion
6621
+ //#region packages/runtime-core/src/compat/componentVModel.ts
6693
6622
  const compatModelEventPrefix = `onModelCompat:`;
6694
6623
  const warnedTypes = /* @__PURE__ */ new WeakSet();
6695
6624
  function convertLegacyVModelProps(vnode) {
@@ -6730,9 +6659,8 @@ var Vue = (function() {
6730
6659
  const modelHandler = props && props[compatModelEventPrefix + event];
6731
6660
  if (modelHandler) callWithErrorHandling(modelHandler, instance, 6, args);
6732
6661
  }
6733
-
6734
- //#endregion
6735
- //#region packages/runtime-core/src/helpers/useModel.ts
6662
+ //#endregion
6663
+ //#region packages/runtime-core/src/helpers/useModel.ts
6736
6664
  function useModel(props, name, options = EMPTY_OBJ) {
6737
6665
  const i = getCurrentGenericInstance();
6738
6666
  if (!i) {
@@ -6803,9 +6731,8 @@ var Vue = (function() {
6803
6731
  const getModelModifiers = (props, modelName, getter) => {
6804
6732
  return getter(props, getModifierPropName(modelName)) || getter(props, `${camelize(modelName)}Modifiers`) || getter(props, `${hyphenate(modelName)}Modifiers`);
6805
6733
  };
6806
-
6807
- //#endregion
6808
- //#region packages/runtime-core/src/componentEmits.ts
6734
+ //#endregion
6735
+ //#region packages/runtime-core/src/componentEmits.ts
6809
6736
  function emit(instance, event, ...rawArgs) {
6810
6737
  return baseEmit(instance, instance.vnode.props || EMPTY_OBJ, defaultPropGetter, event, ...rawArgs);
6811
6738
  }
@@ -6899,10 +6826,9 @@ var Vue = (function() {
6899
6826
  key = key.slice(2).replace(/Once$/, "");
6900
6827
  return hasOwn(options, key[0].toLowerCase() + key.slice(1)) || hasOwn(options, hyphenate(key)) || hasOwn(options, key);
6901
6828
  }
6902
-
6903
- //#endregion
6904
- //#region packages/runtime-core/src/componentRenderUtils.ts
6905
- /**
6829
+ //#endregion
6830
+ //#region packages/runtime-core/src/componentRenderUtils.ts
6831
+ /**
6906
6832
  * dev only flag to track whether $attrs was used during render.
6907
6833
  * If $attrs was used during render then the warning for failed attrs
6908
6834
  * fallthrough can be suppressed.
@@ -7101,9 +7027,8 @@ var Vue = (function() {
7101
7027
  } else break;
7102
7028
  }
7103
7029
  }
7104
-
7105
- //#endregion
7106
- //#region packages/runtime-core/src/compat/props.ts
7030
+ //#endregion
7031
+ //#region packages/runtime-core/src/compat/props.ts
7107
7032
  function createPropsDefaultThis(instance, rawProps, propKey) {
7108
7033
  return new Proxy({}, { get(_, key) {
7109
7034
  warnDeprecation$1("PROPS_DEFAULT_THIS", null, propKey);
@@ -7117,9 +7042,8 @@ var Vue = (function() {
7117
7042
  }
7118
7043
  } });
7119
7044
  }
7120
-
7121
- //#endregion
7122
- //#region packages/runtime-core/src/compat/attrsFallthrough.ts
7045
+ //#endregion
7046
+ //#region packages/runtime-core/src/compat/attrsFallthrough.ts
7123
7047
  function shouldSkipAttr(key, instance) {
7124
7048
  if (key === "is") return true;
7125
7049
  if ((key === "class" || key === "style") && isCompatEnabled$1("INSTANCE_ATTRS_CLASS_STYLE", instance)) return true;
@@ -7127,10 +7051,9 @@ var Vue = (function() {
7127
7051
  if (key.startsWith("routerView") || key === "registerRouteInstance") return true;
7128
7052
  return false;
7129
7053
  }
7130
-
7131
- //#endregion
7132
- //#region packages/runtime-core/src/internalObject.ts
7133
- /**
7054
+ //#endregion
7055
+ //#region packages/runtime-core/src/internalObject.ts
7056
+ /**
7134
7057
  * Used during vnode props/slots normalization to check if the vnode props/slots
7135
7058
  * are the internal attrs / slots object of a component via
7136
7059
  * `Object.getPrototypeOf`. This is more performant than defining a
@@ -7139,9 +7062,8 @@ var Vue = (function() {
7139
7062
  const internalObjectProto = {};
7140
7063
  const createInternalObject = () => Object.create(internalObjectProto);
7141
7064
  const isInternalObject = (obj) => Object.getPrototypeOf(obj) === internalObjectProto;
7142
-
7143
- //#endregion
7144
- //#region packages/runtime-core/src/componentProps.ts
7065
+ //#endregion
7066
+ //#region packages/runtime-core/src/componentProps.ts
7145
7067
  function initProps(instance, rawProps, isStateful, isSSR = false) {
7146
7068
  const props = instance.props = {};
7147
7069
  const attrs = createInternalObject();
@@ -7444,9 +7366,8 @@ var Vue = (function() {
7444
7366
  function isBoolean(...args) {
7445
7367
  return args.some((elem) => elem.toLowerCase() === "boolean");
7446
7368
  }
7447
-
7448
- //#endregion
7449
- //#region packages/runtime-core/src/componentSlots.ts
7369
+ //#endregion
7370
+ //#region packages/runtime-core/src/componentSlots.ts
7450
7371
  const isInternalKey = (key) => key === "_" || key === "_ctx" || key === "$stable";
7451
7372
  const normalizeSlotValue = (value) => isArray(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
7452
7373
  const normalizeSlot = (key, rawSlot, ctx) => {
@@ -7513,9 +7434,8 @@ var Vue = (function() {
7513
7434
  for (const key in slots) if (!isInternalKey(key) && deletionComparisonTarget[key] == null) delete slots[key];
7514
7435
  }
7515
7436
  };
7516
-
7517
- //#endregion
7518
- //#region packages/runtime-core/src/profiling.ts
7437
+ //#endregion
7438
+ //#region packages/runtime-core/src/profiling.ts
7519
7439
  let supported;
7520
7440
  let perf;
7521
7441
  let cachedNow$1 = 0;
@@ -7552,9 +7472,8 @@ var Vue = (function() {
7552
7472
  } else supported = false;
7553
7473
  return supported;
7554
7474
  }
7555
-
7556
- //#endregion
7557
- //#region packages/runtime-core/src/renderer.ts
7475
+ //#endregion
7476
+ //#region packages/runtime-core/src/renderer.ts
7558
7477
  const MoveType = {
7559
7478
  "ENTER": 0,
7560
7479
  "0": "ENTER",
@@ -7944,7 +7863,7 @@ var Vue = (function() {
7944
7863
  if (isAsyncWrapperVNode && type.__asyncHydrate) type.__asyncHydrate(el, instance, hydrateSubTree);
7945
7864
  else hydrateSubTree();
7946
7865
  } else {
7947
- if (root.ce && root.ce._hasShadowRoot()) root.ce._injectChildStyle(type);
7866
+ if (root.ce && root.ce._hasShadowRoot()) root.ce._injectChildStyle(type, instance.parent ? instance.parent.type : void 0);
7948
7867
  startMeasure(instance, `render`);
7949
7868
  const subTree = instance.subTree = renderComponentRoot(instance);
7950
7869
  endMeasure(instance, `render`);
@@ -8466,12 +8385,11 @@ var Vue = (function() {
8466
8385
  if (instance) return resolveAsyncComponentPlaceholder(instance.subTree);
8467
8386
  return null;
8468
8387
  }
8469
-
8470
- //#endregion
8471
- //#region packages/runtime-core/src/components/Suspense.ts
8388
+ //#endregion
8389
+ //#region packages/runtime-core/src/components/Suspense.ts
8472
8390
  const isSuspense = (type) => type.__isSuspense;
8473
8391
  let suspenseId = 0;
8474
- const SuspenseImpl = {
8392
+ const Suspense = {
8475
8393
  name: "Suspense",
8476
8394
  __isSuspense: true,
8477
8395
  process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals) {
@@ -8489,7 +8407,6 @@ var Vue = (function() {
8489
8407
  hydrate: hydrateSuspense,
8490
8408
  normalize: normalizeSuspenseChildren
8491
8409
  };
8492
- const Suspense = SuspenseImpl;
8493
8410
  function triggerEvent(vnode, name) {
8494
8411
  const eventListener = vnode.props && vnode.props[name];
8495
8412
  if (isFunction(eventListener)) eventListener();
@@ -8750,9 +8667,8 @@ var Vue = (function() {
8750
8667
  const suspensible = vnode.props && vnode.props.suspensible;
8751
8668
  return suspensible != null && suspensible !== false;
8752
8669
  }
8753
-
8754
- //#endregion
8755
- //#region packages/runtime-core/src/compat/componentAsync.ts
8670
+ //#endregion
8671
+ //#region packages/runtime-core/src/compat/componentAsync.ts
8756
8672
  const normalizedAsyncComponentMap = /* @__PURE__ */ new WeakMap();
8757
8673
  function convertLegacyAsyncComponent(comp) {
8758
8674
  if (normalizedAsyncComponentMap.has(comp)) return normalizedAsyncComponentMap.get(comp);
@@ -8776,9 +8692,8 @@ var Vue = (function() {
8776
8692
  normalizedAsyncComponentMap.set(comp, converted);
8777
8693
  return converted;
8778
8694
  }
8779
-
8780
- //#endregion
8781
- //#region packages/runtime-core/src/compat/component.ts
8695
+ //#endregion
8696
+ //#region packages/runtime-core/src/compat/component.ts
8782
8697
  function convertLegacyComponent(comp, instance) {
8783
8698
  if (comp.__isBuiltIn) return comp;
8784
8699
  if (isFunction(comp) && comp.cid) {
@@ -8792,9 +8707,8 @@ var Vue = (function() {
8792
8707
  if (isObject(comp) && comp.functional && softAssertCompatEnabled("COMPONENT_FUNCTIONAL", instance, comp)) return convertLegacyFunctionalComponent(comp);
8793
8708
  return comp;
8794
8709
  }
8795
-
8796
- //#endregion
8797
- //#region packages/runtime-core/src/vnode.ts
8710
+ //#endregion
8711
+ //#region packages/runtime-core/src/vnode.ts
8798
8712
  const Fragment = Symbol.for("v-fgt");
8799
8713
  const Text = Symbol.for("v-txt");
8800
8714
  const Comment = Symbol.for("v-cmt");
@@ -9114,10 +9028,9 @@ var Vue = (function() {
9114
9028
  function invokeVNodeHook(hook, instance, vnode, prevVNode = null) {
9115
9029
  callWithAsyncErrorHandling(hook, instance, 7, [vnode, prevVNode]);
9116
9030
  }
9117
-
9118
- //#endregion
9119
- //#region packages/runtime-core/src/componentCurrentInstance.ts
9120
- /**
9031
+ //#endregion
9032
+ //#region packages/runtime-core/src/componentCurrentInstance.ts
9033
+ /**
9121
9034
  * @internal
9122
9035
  */
9123
9036
  let currentInstance = null;
@@ -9131,8 +9044,7 @@ var Vue = (function() {
9131
9044
  /**
9132
9045
  * @internal
9133
9046
  */
9134
- let simpleSetCurrentInstance;
9135
- simpleSetCurrentInstance = (i) => {
9047
+ let simpleSetCurrentInstance = (i) => {
9136
9048
  currentInstance = i;
9137
9049
  };
9138
9050
  setInSSRSetupState = (v) => {
@@ -9174,9 +9086,8 @@ var Vue = (function() {
9174
9086
  value: instance[key]
9175
9087
  };
9176
9088
  };
9177
-
9178
- //#endregion
9179
- //#region packages/runtime-core/src/component.ts
9089
+ //#endregion
9090
+ //#region packages/runtime-core/src/component.ts
9180
9091
  const emptyAppContext = /* @__PURE__ */ createAppContext();
9181
9092
  let uid = 0;
9182
9093
  function createComponentInstance(vnode, parent, suspense) {
@@ -9473,15 +9384,13 @@ var Vue = (function() {
9473
9384
  function isClassComponent(value) {
9474
9385
  return isFunction(value) && "__vccOpts" in value;
9475
9386
  }
9476
-
9477
- //#endregion
9478
- //#region packages/runtime-core/src/apiComputed.ts
9387
+ //#endregion
9388
+ //#region packages/runtime-core/src/apiComputed.ts
9479
9389
  const computed = (getterOrOptions, debugOptions) => {
9480
9390
  return /* @__PURE__ */ computed$1(getterOrOptions, debugOptions, isInSSRComponentSetup);
9481
9391
  };
9482
-
9483
- //#endregion
9484
- //#region packages/runtime-core/src/h.ts
9392
+ //#endregion
9393
+ //#region packages/runtime-core/src/h.ts
9485
9394
  function h(type, propsOrChildren, children) {
9486
9395
  try {
9487
9396
  setBlockTracking(-1);
@@ -9499,9 +9408,8 @@ var Vue = (function() {
9499
9408
  setBlockTracking(1);
9500
9409
  }
9501
9410
  }
9502
-
9503
- //#endregion
9504
- //#region packages/runtime-core/src/customFormatter.ts
9411
+ //#endregion
9412
+ //#region packages/runtime-core/src/customFormatter.ts
9505
9413
  function initCustomFormatter() {
9506
9414
  if (typeof window === "undefined") return;
9507
9415
  const vueStyle = { style: "color:#3ba776" };
@@ -9664,9 +9572,8 @@ var Vue = (function() {
9664
9572
  if (window.devtoolsFormatters) window.devtoolsFormatters.push(formatter);
9665
9573
  else window.devtoolsFormatters = [formatter];
9666
9574
  }
9667
-
9668
- //#endregion
9669
- //#region packages/runtime-core/src/helpers/withMemo.ts
9575
+ //#endregion
9576
+ //#region packages/runtime-core/src/helpers/withMemo.ts
9670
9577
  function withMemo(memo, render, cache, index) {
9671
9578
  const cached = cache[index];
9672
9579
  if (cached && isMemoSame(cached, memo)) return cached;
@@ -9682,10 +9589,9 @@ var Vue = (function() {
9682
9589
  if (isBlockTreeEnabled > 0 && currentBlock) currentBlock.push(cached);
9683
9590
  return true;
9684
9591
  }
9685
-
9686
- //#endregion
9687
- //#region packages/runtime-core/src/index.ts
9688
- const version = "3.6.0-beta.7";
9592
+ //#endregion
9593
+ //#region packages/runtime-core/src/index.ts
9594
+ const version = "3.6.0-beta.8";
9689
9595
  const warn = warn$1;
9690
9596
  /**
9691
9597
  * Runtime error messages. Only exposed in dev or esm builds.
@@ -9695,29 +9601,22 @@ var Vue = (function() {
9695
9601
  const devtools = devtools$1;
9696
9602
  const setDevtoolsHook = setDevtoolsHook$1;
9697
9603
  /**
9698
- * SSR utils for \@vue/server-renderer. Only exposed in ssr-possible builds.
9699
- * @internal
9700
- */
9701
- const ssrUtils = null;
9702
- /**
9703
9604
  * @internal only exposed in compat builds
9704
9605
  */
9705
9606
  const resolveFilter = resolveFilter$1;
9706
- const _compatUtils = {
9607
+ /**
9608
+ * @internal only exposed in compat builds.
9609
+ */
9610
+ const compatUtils = {
9707
9611
  warnDeprecation: warnDeprecation$1,
9708
9612
  createCompatVue: createCompatVue$1,
9709
9613
  isCompatEnabled: isCompatEnabled$1,
9710
9614
  checkCompatEnabled: checkCompatEnabled$1,
9711
9615
  softAssertCompatEnabled
9712
9616
  };
9713
- /**
9714
- * @internal only exposed in compat builds.
9715
- */
9716
- const compatUtils = _compatUtils;
9717
9617
  const DeprecationTypes = DeprecationTypes$1;
9718
-
9719
- //#endregion
9720
- //#region packages/runtime-dom/src/nodeOps.ts
9618
+ //#endregion
9619
+ //#region packages/runtime-dom/src/nodeOps.ts
9721
9620
  let policy = void 0;
9722
9621
  const tt = typeof window !== "undefined" && window.trustedTypes;
9723
9622
  if (tt) try {
@@ -9776,9 +9675,8 @@ var Vue = (function() {
9776
9675
  return [before ? before.nextSibling : parent.firstChild, anchor ? anchor.previousSibling : parent.lastChild];
9777
9676
  }
9778
9677
  };
9779
-
9780
- //#endregion
9781
- //#region packages/runtime-dom/src/components/Transition.ts
9678
+ //#endregion
9679
+ //#region packages/runtime-dom/src/components/Transition.ts
9782
9680
  const TRANSITION$1 = "transition";
9783
9681
  const ANIMATION = "animation";
9784
9682
  const vtcKey = Symbol("_vtc");
@@ -10034,9 +9932,8 @@ var Vue = (function() {
10034
9932
  function forceReflow(el) {
10035
9933
  return (el ? el.ownerDocument : document).body.offsetHeight;
10036
9934
  }
10037
-
10038
- //#endregion
10039
- //#region packages/runtime-dom/src/modules/class.ts
9935
+ //#endregion
9936
+ //#region packages/runtime-dom/src/modules/class.ts
10040
9937
  function patchClass(el, value, isSVG) {
10041
9938
  const transitionClasses = el[vtcKey];
10042
9939
  if (transitionClasses) value = (value ? [value, ...transitionClasses] : [...transitionClasses]).join(" ");
@@ -10044,9 +9941,8 @@ var Vue = (function() {
10044
9941
  else if (isSVG) el.setAttribute("class", value);
10045
9942
  else el.className = value;
10046
9943
  }
10047
-
10048
- //#endregion
10049
- //#region packages/runtime-dom/src/directives/vShow.ts
9944
+ //#endregion
9945
+ //#region packages/runtime-dom/src/directives/vShow.ts
10050
9946
  const vShowOriginalDisplay = Symbol("_vod");
10051
9947
  const vShowHidden = Symbol("_vsh");
10052
9948
  const vShow = {
@@ -10078,9 +9974,8 @@ var Vue = (function() {
10078
9974
  el.style.display = value ? el[vShowOriginalDisplay] : "none";
10079
9975
  el[vShowHidden] = !value;
10080
9976
  }
10081
-
10082
- //#endregion
10083
- //#region packages/runtime-dom/src/helpers/useCssVars.ts
9977
+ //#endregion
9978
+ //#region packages/runtime-dom/src/helpers/useCssVars.ts
10084
9979
  const CSS_VAR_TEXT = Symbol("CSS_VAR_TEXT");
10085
9980
  /**
10086
9981
  * Runtime helper for SFC's CSS variable injection feature.
@@ -10163,9 +10058,8 @@ var Vue = (function() {
10163
10058
  style[CSS_VAR_TEXT] = cssText;
10164
10059
  }
10165
10060
  }
10166
-
10167
- //#endregion
10168
- //#region packages/runtime-dom/src/modules/style.ts
10061
+ //#endregion
10062
+ //#region packages/runtime-dom/src/modules/style.ts
10169
10063
  const displayRE = /(?:^|;)\s*display\s*:/;
10170
10064
  function patchStyle(el, prev, next) {
10171
10065
  const style = el.style;
@@ -10228,9 +10122,8 @@ var Vue = (function() {
10228
10122
  }
10229
10123
  return rawName;
10230
10124
  }
10231
-
10232
- //#endregion
10233
- //#region packages/runtime-dom/src/modules/attrs.ts
10125
+ //#endregion
10126
+ //#region packages/runtime-dom/src/modules/attrs.ts
10234
10127
  const xlinkNS = "http://www.w3.org/1999/xlink";
10235
10128
  function patchAttr(el, key, value, isSVG, instance, isBoolean = isSpecialBooleanAttr(key)) {
10236
10129
  if (isSVG && key.startsWith("xlink:")) if (value == null) el.removeAttributeNS(xlinkNS, key.slice(6, key.length));
@@ -10256,9 +10149,8 @@ var Vue = (function() {
10256
10149
  }
10257
10150
  return false;
10258
10151
  }
10259
-
10260
- //#endregion
10261
- //#region packages/runtime-dom/src/modules/props.ts
10152
+ //#endregion
10153
+ //#region packages/runtime-dom/src/modules/props.ts
10262
10154
  function patchDOMProp(el, key, value, parentComponent, attrName) {
10263
10155
  if (key === "innerHTML" || key === "textContent") {
10264
10156
  if (value != null) el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
@@ -10299,9 +10191,8 @@ var Vue = (function() {
10299
10191
  }
10300
10192
  needRemove && el.removeAttribute(attrName || key);
10301
10193
  }
10302
-
10303
- //#endregion
10304
- //#region packages/runtime-dom/src/modules/events.ts
10194
+ //#endregion
10195
+ //#region packages/runtime-dom/src/modules/events.ts
10305
10196
  function addEventListener(el, event, handler, options) {
10306
10197
  el.addEventListener(event, handler, options);
10307
10198
  }
@@ -10363,9 +10254,8 @@ var Vue = (function() {
10363
10254
  return value.map((fn) => (e) => !e._stopped && fn && fn(e));
10364
10255
  } else return value;
10365
10256
  }
10366
-
10367
- //#endregion
10368
- //#region packages/runtime-dom/src/patchProp.ts
10257
+ //#endregion
10258
+ //#region packages/runtime-dom/src/patchProp.ts
10369
10259
  const patchProp = (el, key, prevValue, nextValue, namespace, parentComponent) => {
10370
10260
  const isSVG = namespace === "svg";
10371
10261
  if (key === "class") patchClass(el, nextValue, isSVG);
@@ -10375,7 +10265,7 @@ var Vue = (function() {
10375
10265
  } else if (key[0] === "." ? (key = key.slice(1), true) : key[0] === "^" ? (key = key.slice(1), false) : shouldSetAsProp(el, key, nextValue, isSVG)) {
10376
10266
  patchDOMProp(el, key, nextValue, parentComponent);
10377
10267
  if (!el.tagName.includes("-") && (key === "value" || key === "checked" || key === "selected")) patchAttr(el, key, nextValue, isSVG, parentComponent, key !== "value");
10378
- } else if (el._isVueCE && (/[A-Z]/.test(key) || !isString(nextValue))) patchDOMProp(el, camelize(key), nextValue, parentComponent, key);
10268
+ } else if (el._isVueCE && (shouldSetAsPropForVueCE(el, key) || el._def.__asyncLoader && (/[A-Z]/.test(key) || !isString(nextValue)))) patchDOMProp(el, camelize(key), nextValue, parentComponent, key);
10379
10269
  else {
10380
10270
  if (key === "true-value") el._trueValue = nextValue;
10381
10271
  else if (key === "false-value") el._falseValue = nextValue;
@@ -10392,9 +10282,14 @@ var Vue = (function() {
10392
10282
  if (isNativeOn(key) && isString(value)) return false;
10393
10283
  return key in el;
10394
10284
  }
10395
-
10396
- //#endregion
10397
- //#region packages/runtime-dom/src/apiCustomElement.ts
10285
+ function shouldSetAsPropForVueCE(el, key) {
10286
+ const props = el._def.props;
10287
+ if (!props) return false;
10288
+ const camelKey = camelize(key);
10289
+ return Array.isArray(props) ? props.some((prop) => camelize(prop) === camelKey) : Object.keys(props).some((prop) => camelize(prop) === camelKey);
10290
+ }
10291
+ //#endregion
10292
+ //#region packages/runtime-dom/src/apiCustomElement.ts
10398
10293
  const REMOVAL = {};
10399
10294
  /* @__NO_SIDE_EFFECTS__ */
10400
10295
  function defineCustomElement(options, extraOptions, _createApp) {
@@ -10422,6 +10317,7 @@ var Vue = (function() {
10422
10317
  this._resolved = false;
10423
10318
  this._numberProps = null;
10424
10319
  this._styleChildren = /* @__PURE__ */ new WeakSet();
10320
+ this._styleAnchors = /* @__PURE__ */ new WeakMap();
10425
10321
  this._patching = false;
10426
10322
  this._dirty = false;
10427
10323
  this._ob = null;
@@ -10440,7 +10336,7 @@ var Vue = (function() {
10440
10336
  if (!this.shadowRoot && !this._resolved) this._parseSlots();
10441
10337
  this._connected = true;
10442
10338
  let parent = this;
10443
- while (parent = parent && (parent.parentNode || parent.host)) if (parent instanceof VueElementBase) {
10339
+ while (parent = parent && (parent.assignedSlot || parent.parentNode || parent.host)) if (parent instanceof VueElementBase) {
10444
10340
  this._parent = parent;
10445
10341
  break;
10446
10342
  }
@@ -10533,6 +10429,7 @@ var Vue = (function() {
10533
10429
  this._styles.forEach((s) => this._root.removeChild(s));
10534
10430
  this._styles.length = 0;
10535
10431
  }
10432
+ this._styleAnchors.delete(this._def);
10536
10433
  this._applyStyles(newStyles);
10537
10434
  if (!this._instance.vapor) this._instance = null;
10538
10435
  this._update();
@@ -10598,18 +10495,26 @@ var Vue = (function() {
10598
10495
  }
10599
10496
  }
10600
10497
  }
10601
- _applyStyles(styles, owner) {
10498
+ _applyStyles(styles, owner, parentComp) {
10602
10499
  if (!styles) return;
10603
10500
  if (owner) {
10604
10501
  if (owner === this._def || this._styleChildren.has(owner)) return;
10605
10502
  this._styleChildren.add(owner);
10606
10503
  }
10607
10504
  const nonce = this._nonce;
10505
+ const root = this.shadowRoot;
10506
+ const insertionAnchor = parentComp ? this._getStyleAnchor(parentComp) || this._getStyleAnchor(this._def) : this._getRootStyleInsertionAnchor(root);
10507
+ let last = null;
10608
10508
  for (let i = styles.length - 1; i >= 0; i--) {
10609
10509
  const s = document.createElement("style");
10610
10510
  if (nonce) s.setAttribute("nonce", nonce);
10611
10511
  s.textContent = styles[i];
10612
- this.shadowRoot.prepend(s);
10512
+ root.insertBefore(s, last || insertionAnchor);
10513
+ last = s;
10514
+ if (i === 0) {
10515
+ if (!parentComp) this._styleAnchors.set(this._def, s);
10516
+ if (owner) this._styleAnchors.set(owner, s);
10517
+ }
10613
10518
  if (owner) {
10614
10519
  if (owner.__hmrId) {
10615
10520
  if (!this._childStyles) this._childStyles = /* @__PURE__ */ new Map();
@@ -10620,6 +10525,20 @@ var Vue = (function() {
10620
10525
  } else (this._styles || (this._styles = [])).push(s);
10621
10526
  }
10622
10527
  }
10528
+ _getStyleAnchor(comp) {
10529
+ if (!comp) return null;
10530
+ const anchor = this._styleAnchors.get(comp);
10531
+ if (anchor && anchor.parentNode === this.shadowRoot) return anchor;
10532
+ if (anchor) this._styleAnchors.delete(comp);
10533
+ return null;
10534
+ }
10535
+ _getRootStyleInsertionAnchor(root) {
10536
+ for (let i = 0; i < root.childNodes.length; i++) {
10537
+ const node = root.childNodes[i];
10538
+ if (!(node instanceof HTMLStyleElement)) return node;
10539
+ }
10540
+ return null;
10541
+ }
10623
10542
  /**
10624
10543
  * Only called when shadowRoot is false
10625
10544
  */
@@ -10682,8 +10601,8 @@ var Vue = (function() {
10682
10601
  /**
10683
10602
  * @internal
10684
10603
  */
10685
- _injectChildStyle(comp) {
10686
- this._applyStyles(comp.styles, comp);
10604
+ _injectChildStyle(comp, parentComp) {
10605
+ this._applyStyles(comp.styles, comp, parentComp);
10687
10606
  }
10688
10607
  /**
10689
10608
  * @internal
@@ -10710,6 +10629,7 @@ var Vue = (function() {
10710
10629
  */
10711
10630
  _removeChildStyle(comp) {
10712
10631
  this._styleChildren.delete(comp);
10632
+ this._styleAnchors.delete(comp);
10713
10633
  if (this._childStyles && comp.__hmrId) {
10714
10634
  const oldStyles = this._childStyles.get(comp.__hmrId);
10715
10635
  if (oldStyles) {
@@ -10778,16 +10698,14 @@ var Vue = (function() {
10778
10698
  const el = useHost("useShadowRoot");
10779
10699
  return el && el.shadowRoot;
10780
10700
  }
10781
-
10782
- //#endregion
10783
- //#region packages/runtime-dom/src/helpers/useCssModule.ts
10701
+ //#endregion
10702
+ //#region packages/runtime-dom/src/helpers/useCssModule.ts
10784
10703
  function useCssModule(name = "$style") {
10785
10704
  warn(`useCssModule() is not supported in the global build.`);
10786
10705
  return EMPTY_OBJ;
10787
10706
  }
10788
-
10789
- //#endregion
10790
- //#region packages/runtime-dom/src/components/TransitionGroup.ts
10707
+ //#endregion
10708
+ //#region packages/runtime-dom/src/components/TransitionGroup.ts
10791
10709
  const positionMap = /* @__PURE__ */ new WeakMap();
10792
10710
  const newPositionMap = /* @__PURE__ */ new WeakMap();
10793
10711
  const moveCbKey = Symbol("_moveCb");
@@ -10801,7 +10719,7 @@ var Vue = (function() {
10801
10719
  t.__isBuiltIn = true;
10802
10720
  return t;
10803
10721
  };
10804
- const TransitionGroupImpl = /* @__PURE__ */ decorate({
10722
+ const TransitionGroup = /* @__PURE__ */ decorate({
10805
10723
  name: "TransitionGroup",
10806
10724
  props: /* @__PURE__ */ extend({}, TransitionPropsValidators, {
10807
10725
  tag: String,
@@ -10853,7 +10771,6 @@ var Vue = (function() {
10853
10771
  };
10854
10772
  }
10855
10773
  });
10856
- const TransitionGroup = TransitionGroupImpl;
10857
10774
  function callPendingCbs(el) {
10858
10775
  if (el[moveCbKey]) el[moveCbKey]();
10859
10776
  if (el[enterCbKey]) el[enterCbKey]();
@@ -10919,9 +10836,8 @@ var Vue = (function() {
10919
10836
  };
10920
10837
  el.addEventListener("transitionend", cb);
10921
10838
  };
10922
-
10923
- //#endregion
10924
- //#region packages/runtime-dom/src/directives/vModel.ts
10839
+ //#endregion
10840
+ //#region packages/runtime-dom/src/directives/vModel.ts
10925
10841
  const getModelAssigner = (vnode) => {
10926
10842
  const fn = vnode.props["onUpdate:modelValue"] || vnode.props["onModelCompat:input"];
10927
10843
  return isArray(fn) ? (value) => invokeArrayFns(fn, value) : fn;
@@ -11151,9 +11067,8 @@ var Vue = (function() {
11151
11067
  const fn = resolveDynamicModel(el.tagName, vnode.props && vnode.props.type)[hook];
11152
11068
  fn && fn(el, binding, vnode, prevVNode);
11153
11069
  }
11154
-
11155
- //#endregion
11156
- //#region packages/runtime-dom/src/directives/vOn.ts
11070
+ //#endregion
11071
+ //#region packages/runtime-dom/src/directives/vOn.ts
11157
11072
  const systemModifiers = [
11158
11073
  "ctrl",
11159
11074
  "shift",
@@ -11226,9 +11141,8 @@ var Vue = (function() {
11226
11141
  }
11227
11142
  }));
11228
11143
  };
11229
-
11230
- //#endregion
11231
- //#region packages/runtime-dom/src/index.ts
11144
+ //#endregion
11145
+ //#region packages/runtime-dom/src/index.ts
11232
11146
  var src_exports = /* @__PURE__ */ __exportAll({
11233
11147
  BaseTransition: () => BaseTransition,
11234
11148
  BaseTransitionPropsValidators: () => BaseTransitionPropsValidators,
@@ -11361,7 +11275,7 @@ var Vue = (function() {
11361
11275
  shallowReadonly: () => shallowReadonly,
11362
11276
  shallowRef: () => shallowRef,
11363
11277
  ssrContextKey: () => ssrContextKey,
11364
- ssrUtils: () => ssrUtils,
11278
+ ssrUtils: () => null,
11365
11279
  stop: () => stop,
11366
11280
  toDisplayString: () => toDisplayString,
11367
11281
  toHandlerKey: () => toHandlerKey,
@@ -11514,16 +11428,14 @@ var Vue = (function() {
11514
11428
  * @internal
11515
11429
  */
11516
11430
  const initDirectivesForSSR = NOOP;
11517
-
11518
- //#endregion
11519
- //#region packages/vue-compat/src/dev.ts
11431
+ //#endregion
11432
+ //#region packages/vue-compat/src/dev.ts
11520
11433
  function initDev() {
11521
11434
  console.info("You are running a development build of Vue.\nMake sure to use the production build (*.prod.js) when deploying for production.");
11522
11435
  initCustomFormatter();
11523
11436
  }
11524
-
11525
- //#endregion
11526
- //#region packages/vue-compat/src/createCompatVue.ts
11437
+ //#endregion
11438
+ //#region packages/vue-compat/src/createCompatVue.ts
11527
11439
  initDev();
11528
11440
  function wrappedCreateApp(...args) {
11529
11441
  const app = createApp(...args);
@@ -11541,9 +11453,8 @@ var Vue = (function() {
11541
11453
  extend(Vue, src_exports);
11542
11454
  return Vue;
11543
11455
  }
11544
-
11545
- //#endregion
11546
- //#region packages/compiler-core/src/runtimeHelpers.ts
11456
+ //#endregion
11457
+ //#region packages/compiler-core/src/runtimeHelpers.ts
11547
11458
  const FRAGMENT = Symbol(`Fragment`);
11548
11459
  const TELEPORT = Symbol(`Teleport`);
11549
11460
  const SUSPENSE = Symbol(`Suspense`);
@@ -11636,9 +11547,8 @@ var Vue = (function() {
11636
11547
  helperNameMap[s] = helpers[s];
11637
11548
  });
11638
11549
  }
11639
-
11640
- //#endregion
11641
- //#region packages/compiler-core/src/ast.ts
11550
+ //#endregion
11551
+ //#region packages/compiler-core/src/ast.ts
11642
11552
  const locStub = {
11643
11553
  start: {
11644
11554
  line: 1,
@@ -11788,9 +11698,8 @@ var Vue = (function() {
11788
11698
  helper(getVNodeBlockHelper(inSSR, node.isComponent));
11789
11699
  }
11790
11700
  }
11791
-
11792
- //#endregion
11793
- //#region packages/compiler-core/src/tokenizer.ts
11701
+ //#endregion
11702
+ //#region packages/compiler-core/src/tokenizer.ts
11794
11703
  const defaultDelimitersOpen = new Uint8Array([123, 123]);
11795
11704
  const defaultDelimitersClose = new Uint8Array([125, 125]);
11796
11705
  /**
@@ -12497,9 +12406,8 @@ var Vue = (function() {
12497
12406
  }
12498
12407
  emitCodePoint(cp, consumed) {}
12499
12408
  };
12500
-
12501
- //#endregion
12502
- //#region packages/compiler-core/src/compat/compatConfig.ts
12409
+ //#endregion
12410
+ //#region packages/compiler-core/src/compat/compatConfig.ts
12503
12411
  const deprecationData = {
12504
12412
  ["COMPILER_IS_ON_ELEMENT"]: {
12505
12413
  message: "Platform-native elements with \"is\" prop will no longer be treated as components in Vue 3 unless the \"is\" value is explicitly prefixed with \"vue:\".",
@@ -12555,9 +12463,8 @@ var Vue = (function() {
12555
12463
  if (loc) err.loc = loc;
12556
12464
  context.onWarn(err);
12557
12465
  }
12558
-
12559
- //#endregion
12560
- //#region packages/compiler-core/src/errors.ts
12466
+ //#endregion
12467
+ //#region packages/compiler-core/src/errors.ts
12561
12468
  function defaultOnError(error) {
12562
12469
  throw error;
12563
12470
  }
@@ -12628,9 +12535,8 @@ var Vue = (function() {
12628
12535
  [51]: `"scopeId" option is only supported in module mode.`,
12629
12536
  [54]: ``
12630
12537
  };
12631
-
12632
- //#endregion
12633
- //#region packages/compiler-core/src/utils.ts
12538
+ //#endregion
12539
+ //#region packages/compiler-core/src/utils.ts
12634
12540
  const isStaticExp = (p) => p.type === 4 && p.isStatic;
12635
12541
  function isCoreComponent(tag) {
12636
12542
  switch (tag) {
@@ -12828,9 +12734,8 @@ var Vue = (function() {
12828
12734
  function isCommentOrWhitespace(node) {
12829
12735
  return node.type === 3 || isWhitespaceText(node);
12830
12736
  }
12831
-
12832
- //#endregion
12833
- //#region packages/compiler-core/src/parser.ts
12737
+ //#endregion
12738
+ //#region packages/compiler-core/src/parser.ts
12834
12739
  const defaultParserOptions = {
12835
12740
  parseMode: "base",
12836
12741
  ns: 0,
@@ -13361,9 +13266,8 @@ var Vue = (function() {
13361
13266
  currentRoot = null;
13362
13267
  return root;
13363
13268
  }
13364
-
13365
- //#endregion
13366
- //#region packages/compiler-core/src/transforms/cacheStatic.ts
13269
+ //#endregion
13270
+ //#region packages/compiler-core/src/transforms/cacheStatic.ts
13367
13271
  function cacheStatic(root, context) {
13368
13272
  walk(root, void 0, context, !!getSingleElementRoot(root));
13369
13273
  }
@@ -13557,9 +13461,8 @@ var Vue = (function() {
13557
13461
  const codegenNode = node.codegenNode;
13558
13462
  if (codegenNode.type === 13) return codegenNode.props;
13559
13463
  }
13560
-
13561
- //#endregion
13562
- //#region packages/compiler-core/src/transform.ts
13464
+ //#endregion
13465
+ //#region packages/compiler-core/src/transform.ts
13563
13466
  function getSelfName(filename) {
13564
13467
  const nameMatch = filename.replace(/\?.*$/, "").match(/([^/\\]+)\.\w+$/);
13565
13468
  return nameMatch ? capitalize(camelize(nameMatch[1])) : null;
@@ -13765,9 +13668,8 @@ var Vue = (function() {
13765
13668
  }
13766
13669
  };
13767
13670
  }
13768
-
13769
- //#endregion
13770
- //#region packages/compiler-core/src/codegen.ts
13671
+ //#endregion
13672
+ //#region packages/compiler-core/src/codegen.ts
13771
13673
  const PURE_ANNOTATION = `/*@__PURE__*/`;
13772
13674
  const aliasHelper = (s) => `${helperNameMap[s]}: _${helperNameMap[s]}`;
13773
13675
  function createCodegenContext(ast, { mode = "function", prefixIdentifiers = mode === "module", sourceMap = false, filename = `template.vue.html`, scopeId = null, optimizeImports = false, runtimeGlobalName = `Vue`, runtimeModuleName = `vue`, ssrRuntimeModuleName = "vue/server-renderer", ssr = false, isTS = false, inSSR = false }) {
@@ -14190,9 +14092,8 @@ var Vue = (function() {
14190
14092
  push(`)`);
14191
14093
  if (needArraySpread) push(`)]`);
14192
14094
  }
14193
-
14194
- //#endregion
14195
- //#region packages/compiler-core/src/validateExpression.ts
14095
+ //#endregion
14096
+ //#region packages/compiler-core/src/validateExpression.ts
14196
14097
  const prohibitedKeywordRE = new RegExp("\\b" + "arguments,await,break,case,catch,class,const,continue,debugger,default,delete,do,else,export,extends,finally,for,function,if,import,let,new,return,super,switch,throw,try,var,void,while,with,yield".split(",").join("\\b|\\b") + "\\b");
14197
14098
  const stripStringRE = /'(?:[^'\\]|\\.)*'|"(?:[^"\\]|\\.)*"|`(?:[^`\\]|\\.)*\$\{|\}(?:[^`\\]|\\.)*`|`(?:[^`\\]|\\.)*`/g;
14198
14099
  /**
@@ -14212,9 +14113,8 @@ var Vue = (function() {
14212
14113
  context.onError(createCompilerError(46, node.loc, void 0, message));
14213
14114
  }
14214
14115
  }
14215
-
14216
- //#endregion
14217
- //#region packages/compiler-core/src/transforms/transformExpression.ts
14116
+ //#endregion
14117
+ //#region packages/compiler-core/src/transforms/transformExpression.ts
14218
14118
  const transformExpression = (node, context) => {
14219
14119
  if (node.type === 5) node.content = processExpression(node.content, context);
14220
14120
  else if (node.type === 1) {
@@ -14234,9 +14134,8 @@ var Vue = (function() {
14234
14134
  validateBrowserExpression(node, context, asParams, asRawStatements);
14235
14135
  return node;
14236
14136
  }
14237
-
14238
- //#endregion
14239
- //#region packages/compiler-core/src/transforms/vIf.ts
14137
+ //#endregion
14138
+ //#region packages/compiler-core/src/transforms/vIf.ts
14240
14139
  const transformIf = createStructuralDirectiveTransform(/^(?:if|else|else-if)$/, (node, dir, context) => {
14241
14140
  return processIf(node, dir, context, (ifNode, branch, isRoot) => {
14242
14141
  const siblings = context.parent.children;
@@ -14357,9 +14256,8 @@ var Vue = (function() {
14357
14256
  else return node;
14358
14257
  else if (node.type === 20) node = node.value;
14359
14258
  }
14360
-
14361
- //#endregion
14362
- //#region packages/compiler-core/src/transforms/vFor.ts
14259
+ //#endregion
14260
+ //#region packages/compiler-core/src/transforms/vFor.ts
14363
14261
  const transformFor = createStructuralDirectiveTransform("for", (node, dir, context) => {
14364
14262
  const { helper, removeHelper } = context;
14365
14263
  return processFor(node, dir, context, (forNode) => {
@@ -14480,9 +14378,8 @@ var Vue = (function() {
14480
14378
  while (i--) if (args[i]) break;
14481
14379
  return args.slice(0, i + 1).map((arg, i) => arg || createSimpleExpression(`_`.repeat(i + 1), false));
14482
14380
  }
14483
-
14484
- //#endregion
14485
- //#region packages/compiler-core/src/transforms/vSlot.ts
14381
+ //#endregion
14382
+ //#region packages/compiler-core/src/transforms/vSlot.ts
14486
14383
  const defaultFallback = createSimpleExpression(`undefined`, false);
14487
14384
  const trackSlotScopes = (node, context) => {
14488
14385
  if (node.type === 1 && (node.tagType === 1 || node.tagType === 3)) {
@@ -14611,9 +14508,8 @@ var Vue = (function() {
14611
14508
  }
14612
14509
  return false;
14613
14510
  }
14614
-
14615
- //#endregion
14616
- //#region packages/compiler-core/src/transforms/transformElement.ts
14511
+ //#endregion
14512
+ //#region packages/compiler-core/src/transforms/transformElement.ts
14617
14513
  const directiveImportMap = /* @__PURE__ */ new WeakMap();
14618
14514
  const transformElement = (node, context) => {
14619
14515
  return function postTransformElement() {
@@ -14904,9 +14800,8 @@ var Vue = (function() {
14904
14800
  function isComponentTag(tag) {
14905
14801
  return tag === "component" || tag === "Component";
14906
14802
  }
14907
-
14908
- //#endregion
14909
- //#region packages/compiler-core/src/transforms/transformSlotOutlet.ts
14803
+ //#endregion
14804
+ //#region packages/compiler-core/src/transforms/transformSlotOutlet.ts
14910
14805
  const transformSlotOutlet = (node, context) => {
14911
14806
  if (isSlotOutlet(node)) {
14912
14807
  const { children, loc } = node;
@@ -14962,9 +14857,8 @@ var Vue = (function() {
14962
14857
  slotProps
14963
14858
  };
14964
14859
  }
14965
-
14966
- //#endregion
14967
- //#region packages/compiler-core/src/transforms/vOn.ts
14860
+ //#endregion
14861
+ //#region packages/compiler-core/src/transforms/vOn.ts
14968
14862
  const transformOn$1 = (dir, node, context, augmentor) => {
14969
14863
  const { loc, modifiers, arg } = dir;
14970
14864
  if (!dir.exp && !modifiers.length) context.onError(createCompilerError(35, loc));
@@ -15004,9 +14898,8 @@ var Vue = (function() {
15004
14898
  ret.props.forEach((p) => p.key.isHandlerKey = true);
15005
14899
  return ret;
15006
14900
  };
15007
-
15008
- //#endregion
15009
- //#region packages/compiler-core/src/transforms/vBind.ts
14901
+ //#endregion
14902
+ //#region packages/compiler-core/src/transforms/vBind.ts
15010
14903
  const transformBind = (dir, _node, context) => {
15011
14904
  const { modifiers, loc } = dir;
15012
14905
  const arg = dir.arg;
@@ -15036,9 +14929,8 @@ var Vue = (function() {
15036
14929
  arg.children.push(`)`);
15037
14930
  }
15038
14931
  };
15039
-
15040
- //#endregion
15041
- //#region packages/compiler-core/src/transforms/transformText.ts
14932
+ //#endregion
14933
+ //#region packages/compiler-core/src/transforms/transformText.ts
15042
14934
  const transformText = (node, context) => {
15043
14935
  if (node.type === 0 || node.type === 1 || node.type === 11 || node.type === 10) return () => {
15044
14936
  const children = node.children;
@@ -15079,9 +14971,8 @@ var Vue = (function() {
15079
14971
  }
15080
14972
  };
15081
14973
  };
15082
-
15083
- //#endregion
15084
- //#region packages/compiler-core/src/transforms/vOnce.ts
14974
+ //#endregion
14975
+ //#region packages/compiler-core/src/transforms/vOnce.ts
15085
14976
  const seen$1 = /* @__PURE__ */ new WeakSet();
15086
14977
  const transformOnce = (node, context) => {
15087
14978
  if (node.type === 1 && findDir(node, "once", true)) {
@@ -15096,9 +14987,8 @@ var Vue = (function() {
15096
14987
  };
15097
14988
  }
15098
14989
  };
15099
-
15100
- //#endregion
15101
- //#region packages/compiler-core/src/transforms/vModel.ts
14990
+ //#endregion
14991
+ //#region packages/compiler-core/src/transforms/vModel.ts
15102
14992
  const transformModel$1 = (dir, node, context) => {
15103
14993
  const { exp, arg } = dir;
15104
14994
  if (!exp) {
@@ -15139,9 +15029,8 @@ var Vue = (function() {
15139
15029
  function createTransformProps(props = []) {
15140
15030
  return { props };
15141
15031
  }
15142
-
15143
- //#endregion
15144
- //#region packages/compiler-core/src/compat/transformFilter.ts
15032
+ //#endregion
15033
+ //#region packages/compiler-core/src/compat/transformFilter.ts
15145
15034
  const validDivisionCharRE = /[\w).+\-_$\]]/;
15146
15035
  const transformFilter = (node, context) => {
15147
15036
  if (!isCompatEnabled("COMPILER_FILTERS", context)) return;
@@ -15253,9 +15142,8 @@ var Vue = (function() {
15253
15142
  return `${toValidAssetId(name, "filter")}(${exp}${args !== ")" ? "," + args : args}`;
15254
15143
  }
15255
15144
  }
15256
-
15257
- //#endregion
15258
- //#region packages/compiler-core/src/transforms/vMemo.ts
15145
+ //#endregion
15146
+ //#region packages/compiler-core/src/transforms/vMemo.ts
15259
15147
  const seen = /* @__PURE__ */ new WeakSet();
15260
15148
  const transformMemo = (node, context) => {
15261
15149
  if (node.type === 1) {
@@ -15277,9 +15165,8 @@ var Vue = (function() {
15277
15165
  };
15278
15166
  }
15279
15167
  };
15280
-
15281
- //#endregion
15282
- //#region packages/compiler-core/src/transforms/transformVBindShorthand.ts
15168
+ //#endregion
15169
+ //#region packages/compiler-core/src/transforms/transformVBindShorthand.ts
15283
15170
  const transformVBindShorthand = (node, context) => {
15284
15171
  if (node.type === 1) {
15285
15172
  for (const prop of node.props) if (prop.type === 7 && prop.name === "bind" && (!prop.exp || prop.exp.type === 4 && !prop.exp.content.trim()) && prop.arg) {
@@ -15294,9 +15181,8 @@ var Vue = (function() {
15294
15181
  }
15295
15182
  }
15296
15183
  };
15297
-
15298
- //#endregion
15299
- //#region packages/compiler-core/src/compile.ts
15184
+ //#endregion
15185
+ //#region packages/compiler-core/src/compile.ts
15300
15186
  function getBaseTransformPreset(prefixIdentifiers) {
15301
15187
  return [[
15302
15188
  transformVBindShorthand,
@@ -15334,13 +15220,11 @@ var Vue = (function() {
15334
15220
  }));
15335
15221
  return generate(ast, resolvedOptions);
15336
15222
  }
15337
-
15338
- //#endregion
15339
- //#region packages/compiler-core/src/transforms/noopDirectiveTransform.ts
15223
+ //#endregion
15224
+ //#region packages/compiler-core/src/transforms/noopDirectiveTransform.ts
15340
15225
  const noopDirectiveTransform = () => ({ props: [] });
15341
-
15342
- //#endregion
15343
- //#region packages/compiler-dom/src/runtimeHelpers.ts
15226
+ //#endregion
15227
+ //#region packages/compiler-dom/src/runtimeHelpers.ts
15344
15228
  const V_MODEL_RADIO = Symbol(`vModelRadio`);
15345
15229
  const V_MODEL_CHECKBOX = Symbol(`vModelCheckbox`);
15346
15230
  const V_MODEL_TEXT = Symbol(`vModelText`);
@@ -15363,9 +15247,8 @@ var Vue = (function() {
15363
15247
  [TRANSITION]: `Transition`,
15364
15248
  [TRANSITION_GROUP]: `TransitionGroup`
15365
15249
  });
15366
-
15367
- //#endregion
15368
- //#region packages/compiler-dom/src/decodeHtmlBrowser.ts
15250
+ //#endregion
15251
+ //#region packages/compiler-dom/src/decodeHtmlBrowser.ts
15369
15252
  let decoder;
15370
15253
  function decodeHtmlBrowser(raw, asAttr = false) {
15371
15254
  if (!decoder) decoder = document.createElement("div");
@@ -15377,9 +15260,8 @@ var Vue = (function() {
15377
15260
  return decoder.textContent;
15378
15261
  }
15379
15262
  }
15380
-
15381
- //#endregion
15382
- //#region packages/compiler-dom/src/parserOptions.ts
15263
+ //#endregion
15264
+ //#region packages/compiler-dom/src/parserOptions.ts
15383
15265
  const parserOptions = {
15384
15266
  parseMode: "html",
15385
15267
  isVoidTag,
@@ -15408,9 +15290,8 @@ var Vue = (function() {
15408
15290
  return ns;
15409
15291
  }
15410
15292
  };
15411
-
15412
- //#endregion
15413
- //#region packages/compiler-dom/src/transforms/transformStyle.ts
15293
+ //#endregion
15294
+ //#region packages/compiler-dom/src/transforms/transformStyle.ts
15414
15295
  const transformStyle = (node) => {
15415
15296
  if (node.type === 1) node.props.forEach((p, i) => {
15416
15297
  if (p.type === 6 && p.name === "style" && p.value) node.props[i] = {
@@ -15427,9 +15308,8 @@ var Vue = (function() {
15427
15308
  const normalized = parseStringStyle(cssText);
15428
15309
  return createSimpleExpression(JSON.stringify(normalized), false, loc, 3);
15429
15310
  };
15430
-
15431
- //#endregion
15432
- //#region packages/compiler-dom/src/errors.ts
15311
+ //#endregion
15312
+ //#region packages/compiler-dom/src/errors.ts
15433
15313
  function createDOMCompilerError(code, loc) {
15434
15314
  return createCompilerError(code, loc, DOMErrorMessages);
15435
15315
  }
@@ -15447,9 +15327,8 @@ var Vue = (function() {
15447
15327
  [64]: `Tags with side effect (<script> and <style>) are ignored in client component templates.`,
15448
15328
  [65]: ``
15449
15329
  };
15450
-
15451
- //#endregion
15452
- //#region packages/compiler-dom/src/transforms/vHtml.ts
15330
+ //#endregion
15331
+ //#region packages/compiler-dom/src/transforms/vHtml.ts
15453
15332
  const transformVHtml = (dir, node, context) => {
15454
15333
  const { exp, loc } = dir;
15455
15334
  if (!exp) context.onError(createDOMCompilerError(54, loc));
@@ -15459,9 +15338,8 @@ var Vue = (function() {
15459
15338
  }
15460
15339
  return { props: [createObjectProperty(createSimpleExpression(`innerHTML`, true, loc), exp || createSimpleExpression("", true))] };
15461
15340
  };
15462
-
15463
- //#endregion
15464
- //#region packages/compiler-dom/src/transforms/vText.ts
15341
+ //#endregion
15342
+ //#region packages/compiler-dom/src/transforms/vText.ts
15465
15343
  const transformVText = (dir, node, context) => {
15466
15344
  const { exp, loc } = dir;
15467
15345
  if (!exp) context.onError(createDOMCompilerError(56, loc));
@@ -15471,9 +15349,8 @@ var Vue = (function() {
15471
15349
  }
15472
15350
  return { props: [createObjectProperty(createSimpleExpression(`textContent`, true), exp ? getConstantType(exp, context) > 0 ? exp : createCallExpression(context.helperString(TO_DISPLAY_STRING), [exp], loc) : createSimpleExpression("", true))] };
15473
15351
  };
15474
-
15475
- //#endregion
15476
- //#region packages/compiler-dom/src/transforms/vModel.ts
15352
+ //#endregion
15353
+ //#region packages/compiler-dom/src/transforms/vModel.ts
15477
15354
  const transformModel = (dir, node, context) => {
15478
15355
  const baseResult = transformModel$1(dir, node, context);
15479
15356
  if (!baseResult.props.length || node.tagType === 1) return baseResult;
@@ -15515,9 +15392,8 @@ var Vue = (function() {
15515
15392
  baseResult.props = baseResult.props.filter((p) => !(p.key.type === 4 && p.key.content === "modelValue"));
15516
15393
  return baseResult;
15517
15394
  };
15518
-
15519
- //#endregion
15520
- //#region packages/compiler-dom/src/transforms/vOn.ts
15395
+ //#endregion
15396
+ //#region packages/compiler-dom/src/transforms/vOn.ts
15521
15397
  const isEventOptionModifier = /* @__PURE__ */ makeMap(`passive,once,capture`);
15522
15398
  const isNonKeyModifier = /* @__PURE__ */ makeMap("stop,prevent,self,ctrl,shift,alt,meta,exact,middle");
15523
15399
  const maybeKeyModifier = /* @__PURE__ */ makeMap("left,right");
@@ -15578,9 +15454,8 @@ var Vue = (function() {
15578
15454
  return { props: [createObjectProperty(key, handlerExp)] };
15579
15455
  });
15580
15456
  };
15581
-
15582
- //#endregion
15583
- //#region packages/compiler-dom/src/transforms/vShow.ts
15457
+ //#endregion
15458
+ //#region packages/compiler-dom/src/transforms/vShow.ts
15584
15459
  const transformShow = (dir, node, context) => {
15585
15460
  const { exp, loc } = dir;
15586
15461
  if (!exp) context.onError(createDOMCompilerError(62, loc));
@@ -15589,9 +15464,8 @@ var Vue = (function() {
15589
15464
  needRuntime: context.helper(V_SHOW)
15590
15465
  };
15591
15466
  };
15592
-
15593
- //#endregion
15594
- //#region packages/compiler-dom/src/transforms/Transition.ts
15467
+ //#endregion
15468
+ //#region packages/compiler-dom/src/transforms/Transition.ts
15595
15469
  const transformTransition = (node, context) => {
15596
15470
  if (node.type === 1 && node.tagType === 1) {
15597
15471
  if (context.isBuiltInComponent(node.tag) === TRANSITION) return postTransformTransition(node, context.onError);
@@ -15622,19 +15496,17 @@ var Vue = (function() {
15622
15496
  const child = children[0];
15623
15497
  return children.length !== 1 || child.type === 11 || child.type === 9 && child.branches.some(defaultHasMultipleChildren);
15624
15498
  }
15625
-
15626
- //#endregion
15627
- //#region packages/compiler-dom/src/transforms/ignoreSideEffectTags.ts
15499
+ //#endregion
15500
+ //#region packages/compiler-dom/src/transforms/ignoreSideEffectTags.ts
15628
15501
  const ignoreSideEffectTags = (node, context) => {
15629
15502
  if (node.type === 1 && node.tagType === 0 && (node.tag === "script" || node.tag === "style")) {
15630
15503
  context.onError(createDOMCompilerError(64, node.loc));
15631
15504
  context.removeNode();
15632
15505
  }
15633
15506
  };
15634
-
15635
- //#endregion
15636
- //#region packages/compiler-dom/src/htmlNesting.ts
15637
- /**
15507
+ //#endregion
15508
+ //#region packages/compiler-dom/src/htmlNesting.ts
15509
+ /**
15638
15510
  * Copied from https://github.com/MananTank/validate-html-nesting
15639
15511
  * with ISC license
15640
15512
  *
@@ -15822,9 +15694,8 @@ var Vue = (function() {
15822
15694
  h5: headings,
15823
15695
  h6: headings
15824
15696
  };
15825
-
15826
- //#endregion
15827
- //#region packages/compiler-dom/src/transforms/validateHtmlNesting.ts
15697
+ //#endregion
15698
+ //#region packages/compiler-dom/src/transforms/validateHtmlNesting.ts
15828
15699
  const validateHtmlNesting = (node, context) => {
15829
15700
  if (node.type === 1 && node.tagType === 0 && context.parent && context.parent.type === 1 && context.parent.tagType === 0 && !isValidHTMLNesting(context.parent.tag, node.tag)) {
15830
15701
  const error = /* @__PURE__ */ new SyntaxError(`<${node.tag}> cannot be child of <${context.parent.tag}>, according to HTML specifications. This can cause hydration errors or potentially disrupt future functionality.`);
@@ -15832,9 +15703,8 @@ var Vue = (function() {
15832
15703
  context.onWarn(error);
15833
15704
  }
15834
15705
  };
15835
-
15836
- //#endregion
15837
- //#region packages/compiler-dom/src/index.ts
15706
+ //#endregion
15707
+ //#region packages/compiler-dom/src/index.ts
15838
15708
  const DOMNodeTransforms = [transformStyle, ...[transformTransition, validateHtmlNesting]];
15839
15709
  const DOMDirectiveTransforms = {
15840
15710
  cloak: noopDirectiveTransform,
@@ -15855,9 +15725,8 @@ var Vue = (function() {
15855
15725
  transformHoist: null
15856
15726
  }));
15857
15727
  }
15858
-
15859
- //#endregion
15860
- //#region packages/vue-compat/src/index.ts
15728
+ //#endregion
15729
+ //#region packages/vue-compat/src/index.ts
15861
15730
  const compileCache = Object.create(null);
15862
15731
  function compileToFunction(template, options) {
15863
15732
  if (!isString(template)) if (template.nodeType) template = template.innerHTML;
@@ -15892,7 +15761,6 @@ var Vue = (function() {
15892
15761
  registerRuntimeCompiler(compileToFunction);
15893
15762
  const Vue = createCompatVue();
15894
15763
  Vue.compile = compileToFunction;
15895
-
15896
- //#endregion
15897
- return Vue;
15898
- })();
15764
+ //#endregion
15765
+ return Vue;
15766
+ })();