@vue/compat 3.5.18 → 3.5.20
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.
- package/dist/vue.cjs.js +79 -92
- package/dist/vue.cjs.prod.js +64 -83
- package/dist/vue.esm-browser.js +79 -92
- package/dist/vue.esm-browser.prod.js +5 -5
- package/dist/vue.esm-bundler.js +79 -92
- package/dist/vue.global.js +79 -92
- package/dist/vue.global.prod.js +4 -4
- package/dist/vue.runtime.esm-browser.js +78 -77
- package/dist/vue.runtime.esm-browser.prod.js +3 -3
- package/dist/vue.runtime.esm-bundler.js +78 -77
- package/dist/vue.runtime.global.js +78 -77
- package/dist/vue.runtime.global.prod.js +3 -3
- package/package.json +3 -3
package/dist/vue.esm-browser.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.20
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -56,10 +56,10 @@ const isBuiltInDirective = /* @__PURE__ */ makeMap(
|
|
|
56
56
|
);
|
|
57
57
|
const cacheStringFunction = (fn) => {
|
|
58
58
|
const cache = /* @__PURE__ */ Object.create(null);
|
|
59
|
-
return (str) => {
|
|
59
|
+
return ((str) => {
|
|
60
60
|
const hit = cache[str];
|
|
61
61
|
return hit || (cache[str] = fn(str));
|
|
62
|
-
};
|
|
62
|
+
});
|
|
63
63
|
};
|
|
64
64
|
const camelizeRE = /-(\w)/g;
|
|
65
65
|
const camelize = cacheStringFunction(
|
|
@@ -1164,7 +1164,7 @@ const arrayInstrumentations = {
|
|
|
1164
1164
|
join(separator) {
|
|
1165
1165
|
return reactiveReadArray(this).join(separator);
|
|
1166
1166
|
},
|
|
1167
|
-
// keys() iterator only reads `length`, no
|
|
1167
|
+
// keys() iterator only reads `length`, no optimization required
|
|
1168
1168
|
lastIndexOf(...args) {
|
|
1169
1169
|
return searchProxy(this, "lastIndexOf", args);
|
|
1170
1170
|
},
|
|
@@ -1365,7 +1365,13 @@ class MutableReactiveHandler extends BaseReactiveHandler {
|
|
|
1365
1365
|
}
|
|
1366
1366
|
if (!isArray(target) && isRef(oldValue) && !isRef(value)) {
|
|
1367
1367
|
if (isOldValueReadonly) {
|
|
1368
|
-
|
|
1368
|
+
{
|
|
1369
|
+
warn$2(
|
|
1370
|
+
`Set operation on key "${String(key)}" failed: target is readonly.`,
|
|
1371
|
+
target[key]
|
|
1372
|
+
);
|
|
1373
|
+
}
|
|
1374
|
+
return true;
|
|
1369
1375
|
} else {
|
|
1370
1376
|
oldValue.value = value;
|
|
1371
1377
|
return true;
|
|
@@ -1510,7 +1516,7 @@ function createInstrumentations(readonly, shallow) {
|
|
|
1510
1516
|
get size() {
|
|
1511
1517
|
const target = this["__v_raw"];
|
|
1512
1518
|
!readonly && track(toRaw(target), "iterate", ITERATE_KEY);
|
|
1513
|
-
return
|
|
1519
|
+
return target.size;
|
|
1514
1520
|
},
|
|
1515
1521
|
has(key) {
|
|
1516
1522
|
const target = this["__v_raw"];
|
|
@@ -2732,7 +2738,9 @@ function rerender(id, newRender) {
|
|
|
2732
2738
|
}
|
|
2733
2739
|
instance.renderCache = [];
|
|
2734
2740
|
isHmrUpdating = true;
|
|
2735
|
-
instance.
|
|
2741
|
+
if (!(instance.job.flags & 8)) {
|
|
2742
|
+
instance.update();
|
|
2743
|
+
}
|
|
2736
2744
|
isHmrUpdating = false;
|
|
2737
2745
|
});
|
|
2738
2746
|
}
|
|
@@ -4324,7 +4332,7 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
|
4324
4332
|
const refs = owner.refs === EMPTY_OBJ ? owner.refs = {} : owner.refs;
|
|
4325
4333
|
const setupState = owner.setupState;
|
|
4326
4334
|
const rawSetupState = toRaw(setupState);
|
|
4327
|
-
const canSetSetupRef = setupState === EMPTY_OBJ ?
|
|
4335
|
+
const canSetSetupRef = setupState === EMPTY_OBJ ? NO : (key) => {
|
|
4328
4336
|
{
|
|
4329
4337
|
if (hasOwn(rawSetupState, key) && !isRef(rawSetupState[key])) {
|
|
4330
4338
|
warn$1(
|
|
@@ -4337,6 +4345,9 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
|
4337
4345
|
}
|
|
4338
4346
|
return hasOwn(rawSetupState, key);
|
|
4339
4347
|
};
|
|
4348
|
+
const canSetRef = (ref2) => {
|
|
4349
|
+
return !knownTemplateRefs.has(ref2);
|
|
4350
|
+
};
|
|
4340
4351
|
if (oldRef != null && oldRef !== ref) {
|
|
4341
4352
|
if (isString(oldRef)) {
|
|
4342
4353
|
refs[oldRef] = null;
|
|
@@ -4344,7 +4355,11 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
|
4344
4355
|
setupState[oldRef] = null;
|
|
4345
4356
|
}
|
|
4346
4357
|
} else if (isRef(oldRef)) {
|
|
4347
|
-
oldRef
|
|
4358
|
+
if (canSetRef(oldRef)) {
|
|
4359
|
+
oldRef.value = null;
|
|
4360
|
+
}
|
|
4361
|
+
const oldRawRefAtom = oldRawRef;
|
|
4362
|
+
if (oldRawRefAtom.k) refs[oldRawRefAtom.k] = null;
|
|
4348
4363
|
}
|
|
4349
4364
|
}
|
|
4350
4365
|
if (isFunction(ref)) {
|
|
@@ -4355,7 +4370,7 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
|
4355
4370
|
if (_isString || _isRef) {
|
|
4356
4371
|
const doSet = () => {
|
|
4357
4372
|
if (rawRef.f) {
|
|
4358
|
-
const existing = _isString ? canSetSetupRef(ref) ? setupState[ref] : refs[ref] : ref.value;
|
|
4373
|
+
const existing = _isString ? canSetSetupRef(ref) ? setupState[ref] : refs[ref] : canSetRef(ref) || !rawRef.k ? ref.value : refs[rawRef.k];
|
|
4359
4374
|
if (isUnmount) {
|
|
4360
4375
|
isArray(existing) && remove(existing, refValue);
|
|
4361
4376
|
} else {
|
|
@@ -4366,8 +4381,11 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
|
4366
4381
|
setupState[ref] = refs[ref];
|
|
4367
4382
|
}
|
|
4368
4383
|
} else {
|
|
4369
|
-
|
|
4370
|
-
if (
|
|
4384
|
+
const newVal = [refValue];
|
|
4385
|
+
if (canSetRef(ref)) {
|
|
4386
|
+
ref.value = newVal;
|
|
4387
|
+
}
|
|
4388
|
+
if (rawRef.k) refs[rawRef.k] = newVal;
|
|
4371
4389
|
}
|
|
4372
4390
|
} else if (!existing.includes(refValue)) {
|
|
4373
4391
|
existing.push(refValue);
|
|
@@ -4379,7 +4397,9 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
|
4379
4397
|
setupState[ref] = value;
|
|
4380
4398
|
}
|
|
4381
4399
|
} else if (_isRef) {
|
|
4382
|
-
ref
|
|
4400
|
+
if (canSetRef(ref)) {
|
|
4401
|
+
ref.value = value;
|
|
4402
|
+
}
|
|
4383
4403
|
if (rawRef.k) refs[rawRef.k] = value;
|
|
4384
4404
|
} else {
|
|
4385
4405
|
warn$1("Invalid template ref type:", ref, `(${typeof ref})`);
|
|
@@ -6139,7 +6159,7 @@ function legacyRenderSlot(instance, name, fallback, props, bindObject) {
|
|
|
6139
6159
|
}
|
|
6140
6160
|
return renderSlot(instance.slots, name, props, fallback && (() => fallback));
|
|
6141
6161
|
}
|
|
6142
|
-
function
|
|
6162
|
+
function legacyResolveScopedSlots(fns, raw, hasDynamicKeys) {
|
|
6143
6163
|
return createSlots(
|
|
6144
6164
|
raw || { $stable: !hasDynamicKeys },
|
|
6145
6165
|
mapKeyToName(fns)
|
|
@@ -6306,7 +6326,7 @@ function installCompatInstanceProperties(map) {
|
|
|
6306
6326
|
_b: () => legacyBindObjectProps,
|
|
6307
6327
|
_v: () => createTextVNode,
|
|
6308
6328
|
_e: () => createCommentVNode,
|
|
6309
|
-
_u: () =>
|
|
6329
|
+
_u: () => legacyResolveScopedSlots,
|
|
6310
6330
|
_g: () => legacyBindObjectListeners,
|
|
6311
6331
|
_d: () => legacyBindDynamicKeys,
|
|
6312
6332
|
_p: () => legacyPrependModifier
|
|
@@ -6477,10 +6497,10 @@ const PublicInstanceProxyHandlers = {
|
|
|
6477
6497
|
return true;
|
|
6478
6498
|
},
|
|
6479
6499
|
has({
|
|
6480
|
-
_: { data, setupState, accessCache, ctx, appContext, propsOptions }
|
|
6500
|
+
_: { data, setupState, accessCache, ctx, appContext, propsOptions, type }
|
|
6481
6501
|
}, key) {
|
|
6482
|
-
let normalizedProps;
|
|
6483
|
-
return !!accessCache[key] || data !== EMPTY_OBJ && hasOwn(data, key) || hasSetupBinding(setupState, key) || (normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key) || hasOwn(ctx, key) || hasOwn(publicPropertiesMap, key) || hasOwn(appContext.config.globalProperties, key);
|
|
6502
|
+
let normalizedProps, cssModules;
|
|
6503
|
+
return !!(accessCache[key] || data !== EMPTY_OBJ && key[0] !== "$" && hasOwn(data, key) || hasSetupBinding(setupState, key) || (normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key) || hasOwn(ctx, key) || hasOwn(publicPropertiesMap, key) || hasOwn(appContext.config.globalProperties, key) || (cssModules = type.__cssModules) && cssModules[key]);
|
|
6484
6504
|
},
|
|
6485
6505
|
defineProperty(target, key, descriptor) {
|
|
6486
6506
|
if (descriptor.get != null) {
|
|
@@ -7225,7 +7245,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7225
7245
|
return vm;
|
|
7226
7246
|
}
|
|
7227
7247
|
}
|
|
7228
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7248
|
+
Vue.version = `2.6.14-compat:${"3.5.20"}`;
|
|
7229
7249
|
Vue.config = singletonApp.config;
|
|
7230
7250
|
Vue.use = (plugin, ...options) => {
|
|
7231
7251
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -7239,22 +7259,22 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7239
7259
|
singletonApp.mixin(m);
|
|
7240
7260
|
return Vue;
|
|
7241
7261
|
};
|
|
7242
|
-
Vue.component = (name, comp) => {
|
|
7262
|
+
Vue.component = ((name, comp) => {
|
|
7243
7263
|
if (comp) {
|
|
7244
7264
|
singletonApp.component(name, comp);
|
|
7245
7265
|
return Vue;
|
|
7246
7266
|
} else {
|
|
7247
7267
|
return singletonApp.component(name);
|
|
7248
7268
|
}
|
|
7249
|
-
};
|
|
7250
|
-
Vue.directive = (name, dir) => {
|
|
7269
|
+
});
|
|
7270
|
+
Vue.directive = ((name, dir) => {
|
|
7251
7271
|
if (dir) {
|
|
7252
7272
|
singletonApp.directive(name, dir);
|
|
7253
7273
|
return Vue;
|
|
7254
7274
|
} else {
|
|
7255
7275
|
return singletonApp.directive(name);
|
|
7256
7276
|
}
|
|
7257
|
-
};
|
|
7277
|
+
});
|
|
7258
7278
|
Vue.options = { _base: Vue };
|
|
7259
7279
|
let cid = 1;
|
|
7260
7280
|
Vue.cid = cid;
|
|
@@ -7317,14 +7337,14 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7317
7337
|
assertCompatEnabled("GLOBAL_OBSERVABLE", null);
|
|
7318
7338
|
return reactive(target);
|
|
7319
7339
|
};
|
|
7320
|
-
Vue.filter = (name, filter) => {
|
|
7340
|
+
Vue.filter = ((name, filter) => {
|
|
7321
7341
|
if (filter) {
|
|
7322
7342
|
singletonApp.filter(name, filter);
|
|
7323
7343
|
return Vue;
|
|
7324
7344
|
} else {
|
|
7325
7345
|
return singletonApp.filter(name);
|
|
7326
7346
|
}
|
|
7327
|
-
};
|
|
7347
|
+
});
|
|
7328
7348
|
const util = {
|
|
7329
7349
|
warn: warn$1 ,
|
|
7330
7350
|
extend,
|
|
@@ -8318,7 +8338,7 @@ function isBoolean(...args) {
|
|
|
8318
8338
|
return args.some((elem) => elem.toLowerCase() === "boolean");
|
|
8319
8339
|
}
|
|
8320
8340
|
|
|
8321
|
-
const isInternalKey = (key) => key === "_" || key === "
|
|
8341
|
+
const isInternalKey = (key) => key === "_" || key === "_ctx" || key === "$stable";
|
|
8322
8342
|
const normalizeSlotValue = (value) => isArray(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
|
|
8323
8343
|
const normalizeSlot = (key, rawSlot, ctx) => {
|
|
8324
8344
|
if (rawSlot._n) {
|
|
@@ -8372,8 +8392,6 @@ const assignSlots = (slots, children, optimized) => {
|
|
|
8372
8392
|
const initSlots = (instance, children, optimized) => {
|
|
8373
8393
|
const slots = instance.slots = createInternalObject();
|
|
8374
8394
|
if (instance.vnode.shapeFlag & 32) {
|
|
8375
|
-
const cacheIndexes = children.__;
|
|
8376
|
-
if (cacheIndexes) def(slots, "__", cacheIndexes, true);
|
|
8377
8395
|
const type = children._;
|
|
8378
8396
|
if (type) {
|
|
8379
8397
|
assignSlots(slots, children, optimized);
|
|
@@ -8434,12 +8452,10 @@ function endMeasure(instance, type) {
|
|
|
8434
8452
|
if (instance.appContext.config.performance && isSupported()) {
|
|
8435
8453
|
const startTag = `vue-${type}-${instance.uid}`;
|
|
8436
8454
|
const endTag = startTag + `:end`;
|
|
8455
|
+
const measureName = `<${formatComponentName(instance, instance.type)}> ${type}`;
|
|
8437
8456
|
perf.mark(endTag);
|
|
8438
|
-
perf.measure(
|
|
8439
|
-
|
|
8440
|
-
startTag,
|
|
8441
|
-
endTag
|
|
8442
|
-
);
|
|
8457
|
+
perf.measure(measureName, startTag, endTag);
|
|
8458
|
+
perf.clearMeasures(measureName);
|
|
8443
8459
|
perf.clearMarks(startTag);
|
|
8444
8460
|
perf.clearMarks(endTag);
|
|
8445
8461
|
}
|
|
@@ -9656,6 +9672,12 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
9656
9672
|
}
|
|
9657
9673
|
};
|
|
9658
9674
|
const performLeave = () => {
|
|
9675
|
+
if (el._isLeaving) {
|
|
9676
|
+
el[leaveCbKey](
|
|
9677
|
+
true
|
|
9678
|
+
/* cancelled */
|
|
9679
|
+
);
|
|
9680
|
+
}
|
|
9659
9681
|
leave(el, () => {
|
|
9660
9682
|
remove2();
|
|
9661
9683
|
afterLeave && afterLeave();
|
|
@@ -9801,27 +9823,12 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
9801
9823
|
if (instance.type.__hmrId) {
|
|
9802
9824
|
unregisterHMR(instance);
|
|
9803
9825
|
}
|
|
9804
|
-
const {
|
|
9805
|
-
bum,
|
|
9806
|
-
scope,
|
|
9807
|
-
job,
|
|
9808
|
-
subTree,
|
|
9809
|
-
um,
|
|
9810
|
-
m,
|
|
9811
|
-
a,
|
|
9812
|
-
parent,
|
|
9813
|
-
slots: { __: slotCacheKeys }
|
|
9814
|
-
} = instance;
|
|
9826
|
+
const { bum, scope, job, subTree, um, m, a } = instance;
|
|
9815
9827
|
invalidateMount(m);
|
|
9816
9828
|
invalidateMount(a);
|
|
9817
9829
|
if (bum) {
|
|
9818
9830
|
invokeArrayFns(bum);
|
|
9819
9831
|
}
|
|
9820
|
-
if (parent && isArray(slotCacheKeys)) {
|
|
9821
|
-
slotCacheKeys.forEach((v) => {
|
|
9822
|
-
parent.renderCache[v] = void 0;
|
|
9823
|
-
});
|
|
9824
|
-
}
|
|
9825
9832
|
if (isCompatEnabled$1("INSTANCE_EVENT_HOOKS", instance)) {
|
|
9826
9833
|
instance.emit("hook:beforeDestroy");
|
|
9827
9834
|
}
|
|
@@ -9842,12 +9849,6 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
9842
9849
|
queuePostRenderEffect(() => {
|
|
9843
9850
|
instance.isUnmounted = true;
|
|
9844
9851
|
}, parentSuspense);
|
|
9845
|
-
if (parentSuspense && parentSuspense.pendingBranch && !parentSuspense.isUnmounted && instance.asyncDep && !instance.asyncResolved && instance.suspenseId === parentSuspense.pendingId) {
|
|
9846
|
-
parentSuspense.deps--;
|
|
9847
|
-
if (parentSuspense.deps === 0) {
|
|
9848
|
-
parentSuspense.resolve();
|
|
9849
|
-
}
|
|
9850
|
-
}
|
|
9851
9852
|
{
|
|
9852
9853
|
devtoolsComponentRemoved(instance);
|
|
9853
9854
|
}
|
|
@@ -9948,7 +9949,8 @@ function traverseStaticChildren(n1, n2, shallow = false) {
|
|
|
9948
9949
|
if (!shallow && c2.patchFlag !== -2)
|
|
9949
9950
|
traverseStaticChildren(c1, c2);
|
|
9950
9951
|
}
|
|
9951
|
-
if (c2.type === Text
|
|
9952
|
+
if (c2.type === Text && // avoid cached text nodes retaining detached dom nodes
|
|
9953
|
+
c2.patchFlag !== -1) {
|
|
9952
9954
|
c2.el = c1.el;
|
|
9953
9955
|
}
|
|
9954
9956
|
if (c2.type === Comment && !c2.el) {
|
|
@@ -12393,7 +12395,7 @@ function isMemoSame(cached, memo) {
|
|
|
12393
12395
|
return true;
|
|
12394
12396
|
}
|
|
12395
12397
|
|
|
12396
|
-
const version = "3.5.
|
|
12398
|
+
const version = "3.5.20";
|
|
12397
12399
|
const warn = warn$1 ;
|
|
12398
12400
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12399
12401
|
const devtools = devtools$1 ;
|
|
@@ -12837,6 +12839,8 @@ function patchClass(el, value, isSVG) {
|
|
|
12837
12839
|
const vShowOriginalDisplay = Symbol("_vod");
|
|
12838
12840
|
const vShowHidden = Symbol("_vsh");
|
|
12839
12841
|
const vShow = {
|
|
12842
|
+
// used for prop mismatch check during hydration
|
|
12843
|
+
name: "show",
|
|
12840
12844
|
beforeMount(el, { value }, { transition }) {
|
|
12841
12845
|
el[vShowOriginalDisplay] = el.style.display === "none" ? "" : el.style.display;
|
|
12842
12846
|
if (transition && value) {
|
|
@@ -12870,9 +12874,6 @@ const vShow = {
|
|
|
12870
12874
|
setDisplay(el, value);
|
|
12871
12875
|
}
|
|
12872
12876
|
};
|
|
12873
|
-
{
|
|
12874
|
-
vShow.name = "show";
|
|
12875
|
-
}
|
|
12876
12877
|
function setDisplay(el, value) {
|
|
12877
12878
|
el.style.display = value ? el[vShowOriginalDisplay] : "none";
|
|
12878
12879
|
el[vShowHidden] = !value;
|
|
@@ -13338,10 +13339,10 @@ function defineCustomElement(options, extraOptions, _createApp) {
|
|
|
13338
13339
|
VueCustomElement.def = Comp;
|
|
13339
13340
|
return VueCustomElement;
|
|
13340
13341
|
}
|
|
13341
|
-
|
|
13342
|
-
const defineSSRCustomElement = /* @__NO_SIDE_EFFECTS__ */ (options, extraOptions) => {
|
|
13342
|
+
|
|
13343
|
+
const defineSSRCustomElement = (/* @__NO_SIDE_EFFECTS__ */ (options, extraOptions) => {
|
|
13343
13344
|
return /* @__PURE__ */ defineCustomElement(options, extraOptions, createSSRApp);
|
|
13344
|
-
};
|
|
13345
|
+
});
|
|
13345
13346
|
const BaseClass = typeof HTMLElement !== "undefined" ? HTMLElement : class {
|
|
13346
13347
|
};
|
|
13347
13348
|
class VueElement extends BaseClass {
|
|
@@ -14211,13 +14212,13 @@ const modifierGuards = {
|
|
|
14211
14212
|
const withModifiers = (fn, modifiers) => {
|
|
14212
14213
|
const cache = fn._withMods || (fn._withMods = {});
|
|
14213
14214
|
const cacheKey = modifiers.join(".");
|
|
14214
|
-
return cache[cacheKey] || (cache[cacheKey] = (event, ...args) => {
|
|
14215
|
+
return cache[cacheKey] || (cache[cacheKey] = ((event, ...args) => {
|
|
14215
14216
|
for (let i = 0; i < modifiers.length; i++) {
|
|
14216
14217
|
const guard = modifierGuards[modifiers[i]];
|
|
14217
14218
|
if (guard && guard(event, modifiers)) return;
|
|
14218
14219
|
}
|
|
14219
14220
|
return fn(event, ...args);
|
|
14220
|
-
});
|
|
14221
|
+
}));
|
|
14221
14222
|
};
|
|
14222
14223
|
const keyNames = {
|
|
14223
14224
|
esc: "escape",
|
|
@@ -14247,7 +14248,7 @@ const withKeys = (fn, modifiers) => {
|
|
|
14247
14248
|
}
|
|
14248
14249
|
const cache = fn._withKeys || (fn._withKeys = {});
|
|
14249
14250
|
const cacheKey = modifiers.join(".");
|
|
14250
|
-
return cache[cacheKey] || (cache[cacheKey] = (event) => {
|
|
14251
|
+
return cache[cacheKey] || (cache[cacheKey] = ((event) => {
|
|
14251
14252
|
if (!("key" in event)) {
|
|
14252
14253
|
return;
|
|
14253
14254
|
}
|
|
@@ -14277,7 +14278,7 @@ const withKeys = (fn, modifiers) => {
|
|
|
14277
14278
|
}
|
|
14278
14279
|
}
|
|
14279
14280
|
}
|
|
14280
|
-
});
|
|
14281
|
+
}));
|
|
14281
14282
|
};
|
|
14282
14283
|
|
|
14283
14284
|
const rendererOptions = /* @__PURE__ */ extend({ patchProp }, nodeOps);
|
|
@@ -14291,13 +14292,13 @@ function ensureHydrationRenderer() {
|
|
|
14291
14292
|
enabledHydration = true;
|
|
14292
14293
|
return renderer;
|
|
14293
14294
|
}
|
|
14294
|
-
const render = (...args) => {
|
|
14295
|
+
const render = ((...args) => {
|
|
14295
14296
|
ensureRenderer().render(...args);
|
|
14296
|
-
};
|
|
14297
|
-
const hydrate = (...args) => {
|
|
14297
|
+
});
|
|
14298
|
+
const hydrate = ((...args) => {
|
|
14298
14299
|
ensureHydrationRenderer().hydrate(...args);
|
|
14299
|
-
};
|
|
14300
|
-
const createApp = (...args) => {
|
|
14300
|
+
});
|
|
14301
|
+
const createApp = ((...args) => {
|
|
14301
14302
|
const app = ensureRenderer().createApp(...args);
|
|
14302
14303
|
{
|
|
14303
14304
|
injectNativeTagCheck(app);
|
|
@@ -14334,8 +14335,8 @@ const createApp = (...args) => {
|
|
|
14334
14335
|
return proxy;
|
|
14335
14336
|
};
|
|
14336
14337
|
return app;
|
|
14337
|
-
};
|
|
14338
|
-
const createSSRApp = (...args) => {
|
|
14338
|
+
});
|
|
14339
|
+
const createSSRApp = ((...args) => {
|
|
14339
14340
|
const app = ensureHydrationRenderer().createApp(...args);
|
|
14340
14341
|
{
|
|
14341
14342
|
injectNativeTagCheck(app);
|
|
@@ -14349,7 +14350,7 @@ const createSSRApp = (...args) => {
|
|
|
14349
14350
|
}
|
|
14350
14351
|
};
|
|
14351
14352
|
return app;
|
|
14352
|
-
};
|
|
14353
|
+
});
|
|
14353
14354
|
function resolveRootNamespace(container) {
|
|
14354
14355
|
if (container instanceof SVGElement) {
|
|
14355
14356
|
return "svg";
|
|
@@ -16904,7 +16905,6 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
|
|
|
16904
16905
|
}
|
|
16905
16906
|
}
|
|
16906
16907
|
let cachedAsArray = false;
|
|
16907
|
-
const slotCacheKeys = [];
|
|
16908
16908
|
if (toCache.length === children.length && node.type === 1) {
|
|
16909
16909
|
if (node.tagType === 0 && node.codegenNode && node.codegenNode.type === 13 && isArray(node.codegenNode.children)) {
|
|
16910
16910
|
node.codegenNode.children = getCacheExpression(
|
|
@@ -16914,7 +16914,6 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
|
|
|
16914
16914
|
} else if (node.tagType === 1 && node.codegenNode && node.codegenNode.type === 13 && node.codegenNode.children && !isArray(node.codegenNode.children) && node.codegenNode.children.type === 15) {
|
|
16915
16915
|
const slot = getSlotNode(node.codegenNode, "default");
|
|
16916
16916
|
if (slot) {
|
|
16917
|
-
slotCacheKeys.push(context.cached.length);
|
|
16918
16917
|
slot.returns = getCacheExpression(
|
|
16919
16918
|
createArrayExpression(slot.returns)
|
|
16920
16919
|
);
|
|
@@ -16924,7 +16923,6 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
|
|
|
16924
16923
|
const slotName = findDir(node, "slot", true);
|
|
16925
16924
|
const slot = slotName && slotName.arg && getSlotNode(parent.codegenNode, slotName.arg);
|
|
16926
16925
|
if (slot) {
|
|
16927
|
-
slotCacheKeys.push(context.cached.length);
|
|
16928
16926
|
slot.returns = getCacheExpression(
|
|
16929
16927
|
createArrayExpression(slot.returns)
|
|
16930
16928
|
);
|
|
@@ -16934,23 +16932,12 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
|
|
|
16934
16932
|
}
|
|
16935
16933
|
if (!cachedAsArray) {
|
|
16936
16934
|
for (const child of toCache) {
|
|
16937
|
-
slotCacheKeys.push(context.cached.length);
|
|
16938
16935
|
child.codegenNode = context.cache(child.codegenNode);
|
|
16939
16936
|
}
|
|
16940
16937
|
}
|
|
16941
|
-
if (slotCacheKeys.length && node.type === 1 && node.tagType === 1 && node.codegenNode && node.codegenNode.type === 13 && node.codegenNode.children && !isArray(node.codegenNode.children) && node.codegenNode.children.type === 15) {
|
|
16942
|
-
node.codegenNode.children.properties.push(
|
|
16943
|
-
createObjectProperty(
|
|
16944
|
-
`__`,
|
|
16945
|
-
createSimpleExpression(JSON.stringify(slotCacheKeys), false)
|
|
16946
|
-
)
|
|
16947
|
-
);
|
|
16948
|
-
}
|
|
16949
16938
|
function getCacheExpression(value) {
|
|
16950
16939
|
const exp = context.cache(value);
|
|
16951
|
-
|
|
16952
|
-
exp.needArraySpread = true;
|
|
16953
|
-
}
|
|
16940
|
+
exp.needArraySpread = true;
|
|
16954
16941
|
return exp;
|
|
16955
16942
|
}
|
|
16956
16943
|
function getSlotNode(node2, name) {
|
|
@@ -18146,7 +18133,7 @@ function processIf(node, dir, context, processCodegen) {
|
|
|
18146
18133
|
continue;
|
|
18147
18134
|
}
|
|
18148
18135
|
if (sibling && sibling.type === 9) {
|
|
18149
|
-
if (dir.name === "else-if" && sibling.branches[sibling.branches.length - 1].condition === void 0) {
|
|
18136
|
+
if ((dir.name === "else-if" || dir.name === "else") && sibling.branches[sibling.branches.length - 1].condition === void 0) {
|
|
18150
18137
|
context.onError(
|
|
18151
18138
|
createCompilerError(30, node.loc)
|
|
18152
18139
|
);
|
|
@@ -19844,7 +19831,7 @@ const seen = /* @__PURE__ */ new WeakSet();
|
|
|
19844
19831
|
const transformMemo = (node, context) => {
|
|
19845
19832
|
if (node.type === 1) {
|
|
19846
19833
|
const dir = findDir(node, "memo");
|
|
19847
|
-
if (!dir || seen.has(node)) {
|
|
19834
|
+
if (!dir || seen.has(node) || context.inSSR) {
|
|
19848
19835
|
return;
|
|
19849
19836
|
}
|
|
19850
19837
|
seen.add(node);
|