@vue/compat 3.4.34 → 3.4.36
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 -46
- package/dist/vue.cjs.prod.js +79 -58
- package/dist/vue.esm-browser.js +53 -36
- package/dist/vue.esm-browser.prod.js +6 -6
- package/dist/vue.esm-bundler.js +53 -36
- package/dist/vue.global.js +53 -36
- package/dist/vue.global.prod.js +6 -6
- package/dist/vue.runtime.esm-browser.js +53 -36
- package/dist/vue.runtime.esm-browser.prod.js +2 -2
- package/dist/vue.runtime.esm-bundler.js +53 -36
- package/dist/vue.runtime.global.js +53 -36
- package/dist/vue.runtime.global.prod.js +2 -2
- package/package.json +2 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.4.
|
|
2
|
+
* @vue/compat v3.4.36
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -5179,7 +5179,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
5179
5179
|
return vm;
|
|
5180
5180
|
}
|
|
5181
5181
|
}
|
|
5182
|
-
Vue.version = `2.6.14-compat:${"3.4.
|
|
5182
|
+
Vue.version = `2.6.14-compat:${"3.4.36"}`;
|
|
5183
5183
|
Vue.config = singletonApp.config;
|
|
5184
5184
|
Vue.use = (plugin, ...options) => {
|
|
5185
5185
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -6096,14 +6096,27 @@ function normalizePropsOptions(comp, appContext, asMixin = false) {
|
|
|
6096
6096
|
if (validatePropName(normalizedKey)) {
|
|
6097
6097
|
const opt = raw[key];
|
|
6098
6098
|
const prop = normalized[normalizedKey] = isArray(opt) || isFunction(opt) ? { type: opt } : extend({}, opt);
|
|
6099
|
-
|
|
6100
|
-
|
|
6101
|
-
|
|
6102
|
-
|
|
6103
|
-
|
|
6104
|
-
|
|
6105
|
-
|
|
6099
|
+
const propType = prop.type;
|
|
6100
|
+
let shouldCast = false;
|
|
6101
|
+
let shouldCastTrue = true;
|
|
6102
|
+
if (isArray(propType)) {
|
|
6103
|
+
for (let index = 0; index < propType.length; ++index) {
|
|
6104
|
+
const type = propType[index];
|
|
6105
|
+
const typeName = isFunction(type) && type.name;
|
|
6106
|
+
if (typeName === "Boolean") {
|
|
6107
|
+
shouldCast = true;
|
|
6108
|
+
break;
|
|
6109
|
+
} else if (typeName === "String") {
|
|
6110
|
+
shouldCastTrue = false;
|
|
6111
|
+
}
|
|
6106
6112
|
}
|
|
6113
|
+
} else {
|
|
6114
|
+
shouldCast = isFunction(propType) && propType.name === "Boolean";
|
|
6115
|
+
}
|
|
6116
|
+
prop[0 /* shouldCast */] = shouldCast;
|
|
6117
|
+
prop[1 /* shouldCastTrue */] = shouldCastTrue;
|
|
6118
|
+
if (shouldCast || hasOwn(prop, "default")) {
|
|
6119
|
+
needCastKeys.push(normalizedKey);
|
|
6107
6120
|
}
|
|
6108
6121
|
}
|
|
6109
6122
|
}
|
|
@@ -6134,17 +6147,6 @@ function getType(ctor) {
|
|
|
6134
6147
|
}
|
|
6135
6148
|
return "";
|
|
6136
6149
|
}
|
|
6137
|
-
function isSameType(a, b) {
|
|
6138
|
-
return getType(a) === getType(b);
|
|
6139
|
-
}
|
|
6140
|
-
function getTypeIndex(type, expectedTypes) {
|
|
6141
|
-
if (isArray(expectedTypes)) {
|
|
6142
|
-
return expectedTypes.findIndex((t) => isSameType(t, type));
|
|
6143
|
-
} else if (isFunction(expectedTypes)) {
|
|
6144
|
-
return isSameType(expectedTypes, type) ? 0 : -1;
|
|
6145
|
-
}
|
|
6146
|
-
return -1;
|
|
6147
|
-
}
|
|
6148
6150
|
function validateProps(rawProps, props, instance) {
|
|
6149
6151
|
const resolvedValues = toRaw(props);
|
|
6150
6152
|
const options = instance.propsOptions[0];
|
|
@@ -6484,15 +6486,11 @@ const TeleportImpl = {
|
|
|
6484
6486
|
if (n1 == null) {
|
|
6485
6487
|
const placeholder = n2.el = createComment("teleport start") ;
|
|
6486
6488
|
const mainAnchor = n2.anchor = createComment("teleport end") ;
|
|
6487
|
-
const target = n2.target = resolveTarget(n2.props, querySelector);
|
|
6488
|
-
const targetStart = n2.targetStart = createText("");
|
|
6489
|
-
const targetAnchor = n2.targetAnchor = createText("");
|
|
6490
6489
|
insert(placeholder, container, anchor);
|
|
6491
6490
|
insert(mainAnchor, container, anchor);
|
|
6492
|
-
|
|
6491
|
+
const target = n2.target = resolveTarget(n2.props, querySelector);
|
|
6492
|
+
const targetAnchor = prepareAnchor(target, n2, createText, insert);
|
|
6493
6493
|
if (target) {
|
|
6494
|
-
insert(targetStart, target);
|
|
6495
|
-
insert(targetAnchor, target);
|
|
6496
6494
|
if (namespace === "svg" || isTargetSVG(target)) {
|
|
6497
6495
|
namespace = "svg";
|
|
6498
6496
|
} else if (namespace === "mathml" || isTargetMathML(target)) {
|
|
@@ -6664,7 +6662,7 @@ function moveTeleport(vnode, container, parentAnchor, { o: { insert }, m: move }
|
|
|
6664
6662
|
}
|
|
6665
6663
|
}
|
|
6666
6664
|
function hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, {
|
|
6667
|
-
o: { nextSibling, parentNode, querySelector }
|
|
6665
|
+
o: { nextSibling, parentNode, querySelector, insert, createText }
|
|
6668
6666
|
}, hydrateChildren) {
|
|
6669
6667
|
const target = vnode.target = resolveTarget(
|
|
6670
6668
|
vnode.props,
|
|
@@ -6683,20 +6681,28 @@ function hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScope
|
|
|
6683
6681
|
slotScopeIds,
|
|
6684
6682
|
optimized
|
|
6685
6683
|
);
|
|
6686
|
-
vnode.
|
|
6684
|
+
vnode.targetStart = targetNode;
|
|
6685
|
+
vnode.targetAnchor = targetNode && nextSibling(targetNode);
|
|
6687
6686
|
} else {
|
|
6688
6687
|
vnode.anchor = nextSibling(node);
|
|
6689
6688
|
let targetAnchor = targetNode;
|
|
6690
6689
|
while (targetAnchor) {
|
|
6691
|
-
targetAnchor
|
|
6692
|
-
|
|
6693
|
-
|
|
6694
|
-
|
|
6695
|
-
|
|
6690
|
+
if (targetAnchor && targetAnchor.nodeType === 8) {
|
|
6691
|
+
if (targetAnchor.data === "teleport start anchor") {
|
|
6692
|
+
vnode.targetStart = targetAnchor;
|
|
6693
|
+
} else if (targetAnchor.data === "teleport anchor") {
|
|
6694
|
+
vnode.targetAnchor = targetAnchor;
|
|
6695
|
+
target._lpa = vnode.targetAnchor && nextSibling(vnode.targetAnchor);
|
|
6696
|
+
break;
|
|
6697
|
+
}
|
|
6696
6698
|
}
|
|
6699
|
+
targetAnchor = nextSibling(targetAnchor);
|
|
6700
|
+
}
|
|
6701
|
+
if (!vnode.targetAnchor) {
|
|
6702
|
+
prepareAnchor(target, vnode, createText, insert);
|
|
6697
6703
|
}
|
|
6698
6704
|
hydrateChildren(
|
|
6699
|
-
targetNode,
|
|
6705
|
+
targetNode && nextSibling(targetNode),
|
|
6700
6706
|
vnode,
|
|
6701
6707
|
target,
|
|
6702
6708
|
parentComponent,
|
|
@@ -6722,6 +6728,16 @@ function updateCssVars(vnode) {
|
|
|
6722
6728
|
ctx.ut();
|
|
6723
6729
|
}
|
|
6724
6730
|
}
|
|
6731
|
+
function prepareAnchor(target, vnode, createText, insert) {
|
|
6732
|
+
const targetStart = vnode.targetStart = createText("");
|
|
6733
|
+
const targetAnchor = vnode.targetAnchor = createText("");
|
|
6734
|
+
targetStart[TeleportEndKey] = targetAnchor;
|
|
6735
|
+
if (target) {
|
|
6736
|
+
insert(targetStart, target);
|
|
6737
|
+
insert(targetAnchor, target);
|
|
6738
|
+
}
|
|
6739
|
+
return targetAnchor;
|
|
6740
|
+
}
|
|
6725
6741
|
|
|
6726
6742
|
let hasLoggedMismatchError = false;
|
|
6727
6743
|
const logMismatchError = () => {
|
|
@@ -7005,6 +7021,7 @@ Server rendered element contains more child nodes than client vdom.`
|
|
|
7005
7021
|
}
|
|
7006
7022
|
if (props) {
|
|
7007
7023
|
{
|
|
7024
|
+
const isCustomElement = el.tagName.includes("-");
|
|
7008
7025
|
for (const key in props) {
|
|
7009
7026
|
if (// #11189 skip if this node has directives that have created hooks
|
|
7010
7027
|
// as it could have mutated the DOM in any possible way
|
|
@@ -7012,7 +7029,7 @@ Server rendered element contains more child nodes than client vdom.`
|
|
|
7012
7029
|
logMismatchError();
|
|
7013
7030
|
}
|
|
7014
7031
|
if (forcePatch && (key.endsWith("value") || key === "indeterminate") || isOn(key) && !isReservedProp(key) || // force hydrate v-bind with .prop modifiers
|
|
7015
|
-
key[0] === ".") {
|
|
7032
|
+
key[0] === "." || isCustomElement) {
|
|
7016
7033
|
patchProp(el, key, null, props[key], void 0, parentComponent);
|
|
7017
7034
|
}
|
|
7018
7035
|
}
|
|
@@ -11350,7 +11367,7 @@ function isMemoSame(cached, memo) {
|
|
|
11350
11367
|
return true;
|
|
11351
11368
|
}
|
|
11352
11369
|
|
|
11353
|
-
const version = "3.4.
|
|
11370
|
+
const version = "3.4.36";
|
|
11354
11371
|
const warn = warn$1 ;
|
|
11355
11372
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
11356
11373
|
const devtools = devtools$1 ;
|