@vue/compat 3.5.17 → 3.5.18
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 +69 -32
- package/dist/vue.cjs.prod.js +44 -21
- package/dist/vue.esm-browser.js +65 -31
- package/dist/vue.esm-browser.prod.js +8 -8
- package/dist/vue.esm-bundler.js +65 -31
- package/dist/vue.global.js +65 -31
- package/dist/vue.global.prod.js +8 -8
- package/dist/vue.runtime.esm-browser.js +53 -27
- package/dist/vue.runtime.esm-browser.prod.js +3 -3
- package/dist/vue.runtime.esm-bundler.js +53 -27
- package/dist/vue.runtime.global.js +53 -27
- package/dist/vue.runtime.global.prod.js +3 -3
- package/package.json +3 -3
package/dist/vue.cjs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.18
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -437,6 +437,24 @@ const stringifySymbol = (v, i = "") => {
|
|
|
437
437
|
);
|
|
438
438
|
};
|
|
439
439
|
|
|
440
|
+
function normalizeCssVarValue(value) {
|
|
441
|
+
if (value == null) {
|
|
442
|
+
return "initial";
|
|
443
|
+
}
|
|
444
|
+
if (typeof value === "string") {
|
|
445
|
+
return value === "" ? " " : value;
|
|
446
|
+
}
|
|
447
|
+
if (typeof value !== "number" || !Number.isFinite(value)) {
|
|
448
|
+
{
|
|
449
|
+
console.warn(
|
|
450
|
+
"[Vue warn] Invalid value used for CSS binding. Expected a string or a finite number but received:",
|
|
451
|
+
value
|
|
452
|
+
);
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
return String(value);
|
|
456
|
+
}
|
|
457
|
+
|
|
440
458
|
function warn$2(msg, ...args) {
|
|
441
459
|
console.warn(`[Vue warn] ${msg}`, ...args);
|
|
442
460
|
}
|
|
@@ -5035,10 +5053,8 @@ function resolveCssVars(instance, vnode, expectedMap) {
|
|
|
5035
5053
|
if (instance.getCssVars && (vnode === root || root && root.type === Fragment && root.children.includes(vnode))) {
|
|
5036
5054
|
const cssVars = instance.getCssVars();
|
|
5037
5055
|
for (const key in cssVars) {
|
|
5038
|
-
|
|
5039
|
-
|
|
5040
|
-
String(cssVars[key])
|
|
5041
|
-
);
|
|
5056
|
+
const value = normalizeCssVarValue(cssVars[key]);
|
|
5057
|
+
expectedMap.set(`--${getEscapedCssVarName(key)}`, value);
|
|
5042
5058
|
}
|
|
5043
5059
|
}
|
|
5044
5060
|
if (vnode === root && instance.parent) {
|
|
@@ -5227,16 +5243,19 @@ function defineAsyncComponent(source) {
|
|
|
5227
5243
|
__asyncLoader: load,
|
|
5228
5244
|
__asyncHydrate(el, instance, hydrate) {
|
|
5229
5245
|
let patched = false;
|
|
5230
|
-
|
|
5231
|
-
|
|
5232
|
-
|
|
5246
|
+
(instance.bu || (instance.bu = [])).push(() => patched = true);
|
|
5247
|
+
const performHydrate = () => {
|
|
5248
|
+
if (patched) {
|
|
5249
|
+
{
|
|
5233
5250
|
warn$1(
|
|
5234
|
-
`Skipping lazy hydration for component '${getComponentName(resolvedComp)}': it was updated before lazy hydration performed.`
|
|
5251
|
+
`Skipping lazy hydration for component '${getComponentName(resolvedComp) || resolvedComp.__file}': it was updated before lazy hydration performed.`
|
|
5235
5252
|
);
|
|
5236
|
-
return;
|
|
5237
5253
|
}
|
|
5238
|
-
|
|
5239
|
-
}
|
|
5254
|
+
return;
|
|
5255
|
+
}
|
|
5256
|
+
hydrate();
|
|
5257
|
+
};
|
|
5258
|
+
const doHydrate = hydrateStrategy ? () => {
|
|
5240
5259
|
const teardown = hydrateStrategy(
|
|
5241
5260
|
performHydrate,
|
|
5242
5261
|
(cb) => forEachElement(el, cb)
|
|
@@ -5244,8 +5263,7 @@ function defineAsyncComponent(source) {
|
|
|
5244
5263
|
if (teardown) {
|
|
5245
5264
|
(instance.bum || (instance.bum = [])).push(teardown);
|
|
5246
5265
|
}
|
|
5247
|
-
|
|
5248
|
-
} : hydrate;
|
|
5266
|
+
} : performHydrate;
|
|
5249
5267
|
if (resolvedComp) {
|
|
5250
5268
|
doHydrate();
|
|
5251
5269
|
} else {
|
|
@@ -6664,15 +6682,15 @@ function withDefaults(props, defaults) {
|
|
|
6664
6682
|
return null;
|
|
6665
6683
|
}
|
|
6666
6684
|
function useSlots() {
|
|
6667
|
-
return getContext().slots;
|
|
6685
|
+
return getContext("useSlots").slots;
|
|
6668
6686
|
}
|
|
6669
6687
|
function useAttrs() {
|
|
6670
|
-
return getContext().attrs;
|
|
6688
|
+
return getContext("useAttrs").attrs;
|
|
6671
6689
|
}
|
|
6672
|
-
function getContext() {
|
|
6690
|
+
function getContext(calledFunctionName) {
|
|
6673
6691
|
const i = getCurrentInstance();
|
|
6674
6692
|
if (!i) {
|
|
6675
|
-
warn$1(
|
|
6693
|
+
warn$1(`${calledFunctionName}() called without active instance.`);
|
|
6676
6694
|
}
|
|
6677
6695
|
return i.setupContext || (i.setupContext = createSetupContext(i));
|
|
6678
6696
|
}
|
|
@@ -6931,7 +6949,8 @@ function applyOptions(instance) {
|
|
|
6931
6949
|
expose.forEach((key) => {
|
|
6932
6950
|
Object.defineProperty(exposed, key, {
|
|
6933
6951
|
get: () => publicThis[key],
|
|
6934
|
-
set: (val) => publicThis[key] = val
|
|
6952
|
+
set: (val) => publicThis[key] = val,
|
|
6953
|
+
enumerable: true
|
|
6935
6954
|
});
|
|
6936
6955
|
});
|
|
6937
6956
|
} else if (!instance.exposed) {
|
|
@@ -7256,7 +7275,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7256
7275
|
return vm;
|
|
7257
7276
|
}
|
|
7258
7277
|
}
|
|
7259
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7278
|
+
Vue.version = `2.6.14-compat:${"3.5.18"}`;
|
|
7260
7279
|
Vue.config = singletonApp.config;
|
|
7261
7280
|
Vue.use = (plugin, ...options) => {
|
|
7262
7281
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -7848,7 +7867,7 @@ function provide(key, value) {
|
|
|
7848
7867
|
}
|
|
7849
7868
|
}
|
|
7850
7869
|
function inject(key, defaultValue, treatDefaultAsFactory = false) {
|
|
7851
|
-
const instance =
|
|
7870
|
+
const instance = getCurrentInstance();
|
|
7852
7871
|
if (instance || currentApp) {
|
|
7853
7872
|
let provides = currentApp ? currentApp._context.provides : instance ? instance.parent == null || instance.ce ? instance.vnode.appContext && instance.vnode.appContext.provides : instance.parent.provides : void 0;
|
|
7854
7873
|
if (provides && key in provides) {
|
|
@@ -7863,7 +7882,7 @@ function inject(key, defaultValue, treatDefaultAsFactory = false) {
|
|
|
7863
7882
|
}
|
|
7864
7883
|
}
|
|
7865
7884
|
function hasInjectionContext() {
|
|
7866
|
-
return !!(
|
|
7885
|
+
return !!(getCurrentInstance() || currentApp);
|
|
7867
7886
|
}
|
|
7868
7887
|
|
|
7869
7888
|
function createPropsDefaultThis(instance, rawProps, propKey) {
|
|
@@ -8349,7 +8368,7 @@ function isBoolean(...args) {
|
|
|
8349
8368
|
return args.some((elem) => elem.toLowerCase() === "boolean");
|
|
8350
8369
|
}
|
|
8351
8370
|
|
|
8352
|
-
const isInternalKey = (key) => key
|
|
8371
|
+
const isInternalKey = (key) => key === "_" || key === "__" || key === "_ctx" || key === "$stable";
|
|
8353
8372
|
const normalizeSlotValue = (value) => isArray(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
|
|
8354
8373
|
const normalizeSlot = (key, rawSlot, ctx) => {
|
|
8355
8374
|
if (rawSlot._n) {
|
|
@@ -9092,6 +9111,7 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
9092
9111
|
if (!initialVNode.el) {
|
|
9093
9112
|
const placeholder = instance.subTree = createVNode(Comment);
|
|
9094
9113
|
processCommentNode(null, placeholder, container, anchor);
|
|
9114
|
+
initialVNode.placeholder = placeholder.el;
|
|
9095
9115
|
}
|
|
9096
9116
|
} else {
|
|
9097
9117
|
setupRenderEffect(
|
|
@@ -9617,7 +9637,11 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
9617
9637
|
for (i = toBePatched - 1; i >= 0; i--) {
|
|
9618
9638
|
const nextIndex = s2 + i;
|
|
9619
9639
|
const nextChild = c2[nextIndex];
|
|
9620
|
-
const
|
|
9640
|
+
const anchorVNode = c2[nextIndex + 1];
|
|
9641
|
+
const anchor = nextIndex + 1 < l2 ? (
|
|
9642
|
+
// #13559, fallback to el placeholder for unresolved async component
|
|
9643
|
+
anchorVNode.el || anchorVNode.placeholder
|
|
9644
|
+
) : parentAnchor;
|
|
9621
9645
|
if (newIndexToOldIndexMap[i] === 0) {
|
|
9622
9646
|
patch(
|
|
9623
9647
|
null,
|
|
@@ -11612,6 +11636,7 @@ function cloneVNode(vnode, extraProps, mergeRef = false, cloneTransition = false
|
|
|
11612
11636
|
suspense: vnode.suspense,
|
|
11613
11637
|
ssContent: vnode.ssContent && cloneVNode(vnode.ssContent),
|
|
11614
11638
|
ssFallback: vnode.ssFallback && cloneVNode(vnode.ssFallback),
|
|
11639
|
+
placeholder: vnode.placeholder,
|
|
11615
11640
|
el: vnode.el,
|
|
11616
11641
|
anchor: vnode.anchor,
|
|
11617
11642
|
ctx: vnode.ctx,
|
|
@@ -12418,7 +12443,7 @@ function isMemoSame(cached, memo) {
|
|
|
12418
12443
|
return true;
|
|
12419
12444
|
}
|
|
12420
12445
|
|
|
12421
|
-
const version = "3.5.
|
|
12446
|
+
const version = "3.5.18";
|
|
12422
12447
|
const warn = warn$1 ;
|
|
12423
12448
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12424
12449
|
const devtools = devtools$1 ;
|
|
@@ -15909,14 +15934,15 @@ function isReferencedIdentifier(id, parent, parentStack) {
|
|
|
15909
15934
|
if (id.name === "arguments") {
|
|
15910
15935
|
return false;
|
|
15911
15936
|
}
|
|
15912
|
-
if (isReferenced(id, parent)) {
|
|
15937
|
+
if (isReferenced(id, parent, parentStack[parentStack.length - 2])) {
|
|
15913
15938
|
return true;
|
|
15914
15939
|
}
|
|
15915
15940
|
switch (parent.type) {
|
|
15916
15941
|
case "AssignmentExpression":
|
|
15917
15942
|
case "AssignmentPattern":
|
|
15918
15943
|
return true;
|
|
15919
|
-
case "
|
|
15944
|
+
case "ObjectProperty":
|
|
15945
|
+
return parent.key !== id && isInDestructureAssignment(parent, parentStack);
|
|
15920
15946
|
case "ArrayPattern":
|
|
15921
15947
|
return isInDestructureAssignment(parent, parentStack);
|
|
15922
15948
|
}
|
|
@@ -16085,7 +16111,7 @@ function isReferenced(node, parent, grandparent) {
|
|
|
16085
16111
|
if (parent.key === node) {
|
|
16086
16112
|
return !!parent.computed;
|
|
16087
16113
|
}
|
|
16088
|
-
return
|
|
16114
|
+
return !grandparent || grandparent.type !== "ObjectPattern";
|
|
16089
16115
|
// no: class { NODE = value; }
|
|
16090
16116
|
// yes: class { [NODE] = value; }
|
|
16091
16117
|
// yes: class { key = NODE; }
|
|
@@ -16135,6 +16161,9 @@ function isReferenced(node, parent, grandparent) {
|
|
|
16135
16161
|
// yes: export { NODE as foo };
|
|
16136
16162
|
// no: export { NODE as foo } from "foo";
|
|
16137
16163
|
case "ExportSpecifier":
|
|
16164
|
+
if (grandparent == null ? void 0 : grandparent.source) {
|
|
16165
|
+
return false;
|
|
16166
|
+
}
|
|
16138
16167
|
return parent.local === node;
|
|
16139
16168
|
// no: import NODE from "foo";
|
|
16140
16169
|
// no: import * as NODE from "foo";
|
|
@@ -16215,7 +16244,7 @@ function isCoreComponent(tag) {
|
|
|
16215
16244
|
return BASE_TRANSITION;
|
|
16216
16245
|
}
|
|
16217
16246
|
}
|
|
16218
|
-
const nonIdentifierRE =
|
|
16247
|
+
const nonIdentifierRE = /^$|^\d|[^\$\w\xA0-\uFFFF]/;
|
|
16219
16248
|
const isSimpleIdentifier = (name) => !nonIdentifierRE.test(name);
|
|
16220
16249
|
const getExpSource = (exp) => exp.type === 4 ? exp.content : exp.loc.source;
|
|
16221
16250
|
const isMemberExpressionNode = (exp, context) => {
|
|
@@ -16313,6 +16342,9 @@ function hasDynamicKeyVBind(node) {
|
|
|
16313
16342
|
function isText$1(node) {
|
|
16314
16343
|
return node.type === 5 || node.type === 2;
|
|
16315
16344
|
}
|
|
16345
|
+
function isVPre(p) {
|
|
16346
|
+
return p.type === 7 && p.name === "pre";
|
|
16347
|
+
}
|
|
16316
16348
|
function isVSlot(p) {
|
|
16317
16349
|
return p.type === 7 && p.name === "slot";
|
|
16318
16350
|
}
|
|
@@ -16611,7 +16643,7 @@ const tokenizer = new Tokenizer(stack, {
|
|
|
16611
16643
|
ondirarg(start, end) {
|
|
16612
16644
|
if (start === end) return;
|
|
16613
16645
|
const arg = getSlice(start, end);
|
|
16614
|
-
if (inVPre) {
|
|
16646
|
+
if (inVPre && !isVPre(currentProp)) {
|
|
16615
16647
|
currentProp.name += arg;
|
|
16616
16648
|
setLocEnd(currentProp.nameLoc, end);
|
|
16617
16649
|
} else {
|
|
@@ -16626,7 +16658,7 @@ const tokenizer = new Tokenizer(stack, {
|
|
|
16626
16658
|
},
|
|
16627
16659
|
ondirmodifier(start, end) {
|
|
16628
16660
|
const mod = getSlice(start, end);
|
|
16629
|
-
if (inVPre) {
|
|
16661
|
+
if (inVPre && !isVPre(currentProp)) {
|
|
16630
16662
|
currentProp.name += "." + mod;
|
|
16631
16663
|
setLocEnd(currentProp.nameLoc, end);
|
|
16632
16664
|
} else if (currentProp.name === "slot") {
|
|
@@ -17273,6 +17305,11 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
|
|
|
17273
17305
|
} else if (child.type === 12) {
|
|
17274
17306
|
const constantType = doNotHoistNode ? 0 : getConstantType(child, context);
|
|
17275
17307
|
if (constantType >= 2) {
|
|
17308
|
+
if (child.codegenNode.type === 14 && child.codegenNode.arguments.length > 0) {
|
|
17309
|
+
child.codegenNode.arguments.push(
|
|
17310
|
+
-1 + (` /* ${PatchFlagNames[-1]} */` )
|
|
17311
|
+
);
|
|
17312
|
+
}
|
|
17276
17313
|
toCache.push(child);
|
|
17277
17314
|
continue;
|
|
17278
17315
|
}
|
|
@@ -19113,7 +19150,7 @@ const transformBind = (dir, _node, context) => {
|
|
|
19113
19150
|
arg.children.unshift(`(`);
|
|
19114
19151
|
arg.children.push(`) || ""`);
|
|
19115
19152
|
} else if (!arg.isStatic) {
|
|
19116
|
-
arg.content = `${arg.content} || ""`;
|
|
19153
|
+
arg.content = arg.content ? `${arg.content} || ""` : `""`;
|
|
19117
19154
|
}
|
|
19118
19155
|
if (modifiers.some((mod) => mod.content === "camel")) {
|
|
19119
19156
|
if (arg.type === 4) {
|
package/dist/vue.cjs.prod.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.18
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -4092,10 +4092,15 @@ function defineAsyncComponent(source) {
|
|
|
4092
4092
|
name: "AsyncComponentWrapper",
|
|
4093
4093
|
__asyncLoader: load,
|
|
4094
4094
|
__asyncHydrate(el, instance, hydrate) {
|
|
4095
|
+
let patched = false;
|
|
4096
|
+
(instance.bu || (instance.bu = [])).push(() => patched = true);
|
|
4097
|
+
const performHydrate = () => {
|
|
4098
|
+
if (patched) {
|
|
4099
|
+
return;
|
|
4100
|
+
}
|
|
4101
|
+
hydrate();
|
|
4102
|
+
};
|
|
4095
4103
|
const doHydrate = hydrateStrategy ? () => {
|
|
4096
|
-
const performHydrate = () => {
|
|
4097
|
-
hydrate();
|
|
4098
|
-
};
|
|
4099
4104
|
const teardown = hydrateStrategy(
|
|
4100
4105
|
performHydrate,
|
|
4101
4106
|
(cb) => forEachElement(el, cb)
|
|
@@ -4103,8 +4108,7 @@ function defineAsyncComponent(source) {
|
|
|
4103
4108
|
if (teardown) {
|
|
4104
4109
|
(instance.bum || (instance.bum = [])).push(teardown);
|
|
4105
4110
|
}
|
|
4106
|
-
|
|
4107
|
-
} : hydrate;
|
|
4111
|
+
} : performHydrate;
|
|
4108
4112
|
if (resolvedComp) {
|
|
4109
4113
|
doHydrate();
|
|
4110
4114
|
} else {
|
|
@@ -5353,7 +5357,7 @@ function useSlots() {
|
|
|
5353
5357
|
function useAttrs() {
|
|
5354
5358
|
return getContext().attrs;
|
|
5355
5359
|
}
|
|
5356
|
-
function getContext() {
|
|
5360
|
+
function getContext(calledFunctionName) {
|
|
5357
5361
|
const i = getCurrentInstance();
|
|
5358
5362
|
return i.setupContext || (i.setupContext = createSetupContext(i));
|
|
5359
5363
|
}
|
|
@@ -5540,7 +5544,8 @@ function applyOptions(instance) {
|
|
|
5540
5544
|
expose.forEach((key) => {
|
|
5541
5545
|
Object.defineProperty(exposed, key, {
|
|
5542
5546
|
get: () => publicThis[key],
|
|
5543
|
-
set: (val) => publicThis[key] = val
|
|
5547
|
+
set: (val) => publicThis[key] = val,
|
|
5548
|
+
enumerable: true
|
|
5544
5549
|
});
|
|
5545
5550
|
});
|
|
5546
5551
|
} else if (!instance.exposed) {
|
|
@@ -5827,7 +5832,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
5827
5832
|
return vm;
|
|
5828
5833
|
}
|
|
5829
5834
|
}
|
|
5830
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
5835
|
+
Vue.version = `2.6.14-compat:${"3.5.18"}`;
|
|
5831
5836
|
Vue.config = singletonApp.config;
|
|
5832
5837
|
Vue.use = (plugin, ...options) => {
|
|
5833
5838
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -6305,7 +6310,7 @@ function provide(key, value) {
|
|
|
6305
6310
|
}
|
|
6306
6311
|
}
|
|
6307
6312
|
function inject(key, defaultValue, treatDefaultAsFactory = false) {
|
|
6308
|
-
const instance =
|
|
6313
|
+
const instance = getCurrentInstance();
|
|
6309
6314
|
if (instance || currentApp) {
|
|
6310
6315
|
let provides = currentApp ? currentApp._context.provides : instance ? instance.parent == null || instance.ce ? instance.vnode.appContext && instance.vnode.appContext.provides : instance.parent.provides : void 0;
|
|
6311
6316
|
if (provides && key in provides) {
|
|
@@ -6316,7 +6321,7 @@ function inject(key, defaultValue, treatDefaultAsFactory = false) {
|
|
|
6316
6321
|
}
|
|
6317
6322
|
}
|
|
6318
6323
|
function hasInjectionContext() {
|
|
6319
|
-
return !!(
|
|
6324
|
+
return !!(getCurrentInstance() || currentApp);
|
|
6320
6325
|
}
|
|
6321
6326
|
|
|
6322
6327
|
function createPropsDefaultThis(instance, rawProps, propKey) {
|
|
@@ -6666,7 +6671,7 @@ function validatePropName(key) {
|
|
|
6666
6671
|
return false;
|
|
6667
6672
|
}
|
|
6668
6673
|
|
|
6669
|
-
const isInternalKey = (key) => key
|
|
6674
|
+
const isInternalKey = (key) => key === "_" || key === "__" || key === "_ctx" || key === "$stable";
|
|
6670
6675
|
const normalizeSlotValue = (value) => isArray(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
|
|
6671
6676
|
const normalizeSlot = (key, rawSlot, ctx) => {
|
|
6672
6677
|
if (rawSlot._n) {
|
|
@@ -7301,6 +7306,7 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
7301
7306
|
if (!initialVNode.el) {
|
|
7302
7307
|
const placeholder = instance.subTree = createVNode(Comment);
|
|
7303
7308
|
processCommentNode(null, placeholder, container, anchor);
|
|
7309
|
+
initialVNode.placeholder = placeholder.el;
|
|
7304
7310
|
}
|
|
7305
7311
|
} else {
|
|
7306
7312
|
setupRenderEffect(
|
|
@@ -7757,7 +7763,11 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
7757
7763
|
for (i = toBePatched - 1; i >= 0; i--) {
|
|
7758
7764
|
const nextIndex = s2 + i;
|
|
7759
7765
|
const nextChild = c2[nextIndex];
|
|
7760
|
-
const
|
|
7766
|
+
const anchorVNode = c2[nextIndex + 1];
|
|
7767
|
+
const anchor = nextIndex + 1 < l2 ? (
|
|
7768
|
+
// #13559, fallback to el placeholder for unresolved async component
|
|
7769
|
+
anchorVNode.el || anchorVNode.placeholder
|
|
7770
|
+
) : parentAnchor;
|
|
7761
7771
|
if (newIndexToOldIndexMap[i] === 0) {
|
|
7762
7772
|
patch(
|
|
7763
7773
|
null,
|
|
@@ -9511,6 +9521,7 @@ function cloneVNode(vnode, extraProps, mergeRef = false, cloneTransition = false
|
|
|
9511
9521
|
suspense: vnode.suspense,
|
|
9512
9522
|
ssContent: vnode.ssContent && cloneVNode(vnode.ssContent),
|
|
9513
9523
|
ssFallback: vnode.ssFallback && cloneVNode(vnode.ssFallback),
|
|
9524
|
+
placeholder: vnode.placeholder,
|
|
9514
9525
|
el: vnode.el,
|
|
9515
9526
|
anchor: vnode.anchor,
|
|
9516
9527
|
ctx: vnode.ctx,
|
|
@@ -9988,7 +9999,7 @@ function isMemoSame(cached, memo) {
|
|
|
9988
9999
|
return true;
|
|
9989
10000
|
}
|
|
9990
10001
|
|
|
9991
|
-
const version = "3.5.
|
|
10002
|
+
const version = "3.5.18";
|
|
9992
10003
|
const warn$1 = NOOP;
|
|
9993
10004
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
9994
10005
|
const devtools = void 0;
|
|
@@ -13255,14 +13266,15 @@ function isReferencedIdentifier(id, parent, parentStack) {
|
|
|
13255
13266
|
if (id.name === "arguments") {
|
|
13256
13267
|
return false;
|
|
13257
13268
|
}
|
|
13258
|
-
if (isReferenced(id, parent)) {
|
|
13269
|
+
if (isReferenced(id, parent, parentStack[parentStack.length - 2])) {
|
|
13259
13270
|
return true;
|
|
13260
13271
|
}
|
|
13261
13272
|
switch (parent.type) {
|
|
13262
13273
|
case "AssignmentExpression":
|
|
13263
13274
|
case "AssignmentPattern":
|
|
13264
13275
|
return true;
|
|
13265
|
-
case "
|
|
13276
|
+
case "ObjectProperty":
|
|
13277
|
+
return parent.key !== id && isInDestructureAssignment(parent, parentStack);
|
|
13266
13278
|
case "ArrayPattern":
|
|
13267
13279
|
return isInDestructureAssignment(parent, parentStack);
|
|
13268
13280
|
}
|
|
@@ -13431,7 +13443,7 @@ function isReferenced(node, parent, grandparent) {
|
|
|
13431
13443
|
if (parent.key === node) {
|
|
13432
13444
|
return !!parent.computed;
|
|
13433
13445
|
}
|
|
13434
|
-
return
|
|
13446
|
+
return !grandparent || grandparent.type !== "ObjectPattern";
|
|
13435
13447
|
// no: class { NODE = value; }
|
|
13436
13448
|
// yes: class { [NODE] = value; }
|
|
13437
13449
|
// yes: class { key = NODE; }
|
|
@@ -13481,6 +13493,9 @@ function isReferenced(node, parent, grandparent) {
|
|
|
13481
13493
|
// yes: export { NODE as foo };
|
|
13482
13494
|
// no: export { NODE as foo } from "foo";
|
|
13483
13495
|
case "ExportSpecifier":
|
|
13496
|
+
if (grandparent == null ? void 0 : grandparent.source) {
|
|
13497
|
+
return false;
|
|
13498
|
+
}
|
|
13484
13499
|
return parent.local === node;
|
|
13485
13500
|
// no: import NODE from "foo";
|
|
13486
13501
|
// no: import * as NODE from "foo";
|
|
@@ -13561,7 +13576,7 @@ function isCoreComponent(tag) {
|
|
|
13561
13576
|
return BASE_TRANSITION;
|
|
13562
13577
|
}
|
|
13563
13578
|
}
|
|
13564
|
-
const nonIdentifierRE =
|
|
13579
|
+
const nonIdentifierRE = /^$|^\d|[^\$\w\xA0-\uFFFF]/;
|
|
13565
13580
|
const isSimpleIdentifier = (name) => !nonIdentifierRE.test(name);
|
|
13566
13581
|
const getExpSource = (exp) => exp.type === 4 ? exp.content : exp.loc.source;
|
|
13567
13582
|
const isMemberExpressionNode = (exp, context) => {
|
|
@@ -13654,6 +13669,9 @@ function hasDynamicKeyVBind(node) {
|
|
|
13654
13669
|
function isText$1(node) {
|
|
13655
13670
|
return node.type === 5 || node.type === 2;
|
|
13656
13671
|
}
|
|
13672
|
+
function isVPre(p) {
|
|
13673
|
+
return p.type === 7 && p.name === "pre";
|
|
13674
|
+
}
|
|
13657
13675
|
function isVSlot(p) {
|
|
13658
13676
|
return p.type === 7 && p.name === "slot";
|
|
13659
13677
|
}
|
|
@@ -13952,7 +13970,7 @@ const tokenizer = new Tokenizer(stack, {
|
|
|
13952
13970
|
ondirarg(start, end) {
|
|
13953
13971
|
if (start === end) return;
|
|
13954
13972
|
const arg = getSlice(start, end);
|
|
13955
|
-
if (inVPre) {
|
|
13973
|
+
if (inVPre && !isVPre(currentProp)) {
|
|
13956
13974
|
currentProp.name += arg;
|
|
13957
13975
|
setLocEnd(currentProp.nameLoc, end);
|
|
13958
13976
|
} else {
|
|
@@ -13967,7 +13985,7 @@ const tokenizer = new Tokenizer(stack, {
|
|
|
13967
13985
|
},
|
|
13968
13986
|
ondirmodifier(start, end) {
|
|
13969
13987
|
const mod = getSlice(start, end);
|
|
13970
|
-
if (inVPre) {
|
|
13988
|
+
if (inVPre && !isVPre(currentProp)) {
|
|
13971
13989
|
currentProp.name += "." + mod;
|
|
13972
13990
|
setLocEnd(currentProp.nameLoc, end);
|
|
13973
13991
|
} else if (currentProp.name === "slot") {
|
|
@@ -14577,6 +14595,11 @@ function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
|
|
|
14577
14595
|
} else if (child.type === 12) {
|
|
14578
14596
|
const constantType = doNotHoistNode ? 0 : getConstantType(child, context);
|
|
14579
14597
|
if (constantType >= 2) {
|
|
14598
|
+
if (child.codegenNode.type === 14 && child.codegenNode.arguments.length > 0) {
|
|
14599
|
+
child.codegenNode.arguments.push(
|
|
14600
|
+
-1 + (``)
|
|
14601
|
+
);
|
|
14602
|
+
}
|
|
14580
14603
|
toCache.push(child);
|
|
14581
14604
|
continue;
|
|
14582
14605
|
}
|
|
@@ -16373,7 +16396,7 @@ const transformBind = (dir, _node, context) => {
|
|
|
16373
16396
|
arg.children.unshift(`(`);
|
|
16374
16397
|
arg.children.push(`) || ""`);
|
|
16375
16398
|
} else if (!arg.isStatic) {
|
|
16376
|
-
arg.content = `${arg.content} || ""`;
|
|
16399
|
+
arg.content = arg.content ? `${arg.content} || ""` : `""`;
|
|
16377
16400
|
}
|
|
16378
16401
|
if (modifiers.some((mod) => mod.content === "camel")) {
|
|
16379
16402
|
if (arg.type === 4) {
|