@vue/compat 3.4.29 → 3.4.30
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 +49 -48
- package/dist/vue.cjs.prod.js +23 -17
- package/dist/vue.esm-browser.js +49 -48
- package/dist/vue.esm-browser.prod.js +6 -9
- package/dist/vue.esm-bundler.js +49 -48
- package/dist/vue.global.js +49 -48
- package/dist/vue.global.prod.js +6 -9
- package/dist/vue.runtime.esm-browser.js +47 -43
- package/dist/vue.runtime.esm-browser.prod.js +2 -9
- package/dist/vue.runtime.esm-bundler.js +47 -43
- package/dist/vue.runtime.global.js +47 -43
- package/dist/vue.runtime.global.prod.js +2 -9
- package/package.json +2 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.4.
|
|
2
|
+
* @vue/compat v3.4.30
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -439,8 +439,10 @@ class ReactiveEffect {
|
|
|
439
439
|
for (let i = 0; i < this._depsLength; i++) {
|
|
440
440
|
const dep = this.deps[i];
|
|
441
441
|
if (dep.computed) {
|
|
442
|
-
if (dep.computed.effect._dirtyLevel === 2)
|
|
442
|
+
if (dep.computed.effect._dirtyLevel === 2) {
|
|
443
|
+
resetTracking();
|
|
443
444
|
return true;
|
|
445
|
+
}
|
|
444
446
|
triggerComputed(dep.computed);
|
|
445
447
|
if (this._dirtyLevel >= 5) {
|
|
446
448
|
break;
|
|
@@ -576,13 +578,13 @@ function triggerEffects(dep, dirtyLevel, debuggerEventExtraInfo) {
|
|
|
576
578
|
var _a;
|
|
577
579
|
pauseScheduling();
|
|
578
580
|
for (const effect2 of dep.keys()) {
|
|
581
|
+
let tracking;
|
|
579
582
|
if (!dep.computed && effect2.computed) {
|
|
580
|
-
if (dep.get(effect2) === effect2._trackId
|
|
583
|
+
if (effect2._runnings > 0 && (tracking != null ? tracking : tracking = dep.get(effect2) === effect2._trackId)) {
|
|
581
584
|
effect2._dirtyLevel = 2;
|
|
582
585
|
continue;
|
|
583
586
|
}
|
|
584
587
|
}
|
|
585
|
-
let tracking;
|
|
586
588
|
if (effect2._dirtyLevel < dirtyLevel && (tracking != null ? tracking : tracking = dep.get(effect2) === effect2._trackId)) {
|
|
587
589
|
effect2._shouldSchedule || (effect2._shouldSchedule = effect2._dirtyLevel === 0);
|
|
588
590
|
if (effect2.computed && effect2._dirtyLevel === 2) {
|
|
@@ -1299,8 +1301,11 @@ class ComputedRefImpl {
|
|
|
1299
1301
|
}
|
|
1300
1302
|
get value() {
|
|
1301
1303
|
const self = toRaw(this);
|
|
1304
|
+
const lastDirtyLevel = self.effect._dirtyLevel;
|
|
1302
1305
|
if ((!self._cacheable || self.effect.dirty) && hasChanged(self._value, self._value = self.effect.run())) {
|
|
1303
|
-
|
|
1306
|
+
if (lastDirtyLevel !== 3) {
|
|
1307
|
+
triggerRefValue(self, 5);
|
|
1308
|
+
}
|
|
1304
1309
|
}
|
|
1305
1310
|
trackRefValue(self);
|
|
1306
1311
|
if (self.effect._dirtyLevel >= 2) {
|
|
@@ -3267,7 +3272,6 @@ const SuspenseImpl = {
|
|
|
3267
3272
|
}
|
|
3268
3273
|
},
|
|
3269
3274
|
hydrate: hydrateSuspense,
|
|
3270
|
-
create: createSuspenseBoundary,
|
|
3271
3275
|
normalize: normalizeSuspenseChildren
|
|
3272
3276
|
};
|
|
3273
3277
|
const Suspense = SuspenseImpl ;
|
|
@@ -5623,7 +5627,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
5623
5627
|
return vm;
|
|
5624
5628
|
}
|
|
5625
5629
|
}
|
|
5626
|
-
Vue.version = `2.6.14-compat:${"3.4.
|
|
5630
|
+
Vue.version = `2.6.14-compat:${"3.4.30"}`;
|
|
5627
5631
|
Vue.config = singletonApp.config;
|
|
5628
5632
|
Vue.use = (plugin, ...options) => {
|
|
5629
5633
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -6932,18 +6936,8 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
6932
6936
|
let domType = node.nodeType;
|
|
6933
6937
|
vnode.el = node;
|
|
6934
6938
|
{
|
|
6935
|
-
|
|
6936
|
-
|
|
6937
|
-
value: vnode,
|
|
6938
|
-
enumerable: false
|
|
6939
|
-
});
|
|
6940
|
-
}
|
|
6941
|
-
if (!("__vueParentComponent" in node)) {
|
|
6942
|
-
Object.defineProperty(node, "__vueParentComponent", {
|
|
6943
|
-
value: parentComponent,
|
|
6944
|
-
enumerable: false
|
|
6945
|
-
});
|
|
6946
|
-
}
|
|
6939
|
+
def(node, "__vnode", vnode, true);
|
|
6940
|
+
def(node, "__vueParentComponent", parentComponent, true);
|
|
6947
6941
|
}
|
|
6948
6942
|
if (patchFlag === -2) {
|
|
6949
6943
|
optimized = false;
|
|
@@ -7166,7 +7160,9 @@ Server rendered element contains more child nodes than client vdom.`
|
|
|
7166
7160
|
if (props) {
|
|
7167
7161
|
{
|
|
7168
7162
|
for (const key in props) {
|
|
7169
|
-
if (
|
|
7163
|
+
if (// #11189 skip if this node has directives that have created hooks
|
|
7164
|
+
// as it could have mutated the DOM in any possible way
|
|
7165
|
+
!(dirs && dirs.some((d) => d.dir.created)) && propHasMismatch(el, key, props[key], vnode, parentComponent)) {
|
|
7170
7166
|
logMismatchError();
|
|
7171
7167
|
}
|
|
7172
7168
|
if (forcePatch && (key.endsWith("value") || key === "indeterminate") || isOn(key) && !isReservedProp(key) || // force hydrate v-bind with .prop modifiers
|
|
@@ -7341,7 +7337,6 @@ Server rendered element contains fewer child nodes than client vdom.`
|
|
|
7341
7337
|
return [hydrate, hydrateNode];
|
|
7342
7338
|
}
|
|
7343
7339
|
function propHasMismatch(el, key, clientValue, vnode, instance) {
|
|
7344
|
-
var _a;
|
|
7345
7340
|
let mismatchType;
|
|
7346
7341
|
let mismatchKey;
|
|
7347
7342
|
let actual;
|
|
@@ -7364,13 +7359,8 @@ function propHasMismatch(el, key, clientValue, vnode, instance) {
|
|
|
7364
7359
|
}
|
|
7365
7360
|
}
|
|
7366
7361
|
}
|
|
7367
|
-
|
|
7368
|
-
|
|
7369
|
-
(root == null ? void 0 : root.type) === Fragment && root.children.includes(vnode)) {
|
|
7370
|
-
const cssVars = (_a = instance == null ? void 0 : instance.getCssVars) == null ? void 0 : _a.call(instance);
|
|
7371
|
-
for (const key2 in cssVars) {
|
|
7372
|
-
expectedMap.set(`--${key2}`, String(cssVars[key2]));
|
|
7373
|
-
}
|
|
7362
|
+
if (instance) {
|
|
7363
|
+
resolveCssVars(instance, vnode, expectedMap);
|
|
7374
7364
|
}
|
|
7375
7365
|
if (!isMapEqual(actualMap, expectedMap)) {
|
|
7376
7366
|
mismatchType = mismatchKey = "style";
|
|
@@ -7430,8 +7420,8 @@ function toStyleMap(str) {
|
|
|
7430
7420
|
const styleMap = /* @__PURE__ */ new Map();
|
|
7431
7421
|
for (const item of str.split(";")) {
|
|
7432
7422
|
let [key, value] = item.split(":");
|
|
7433
|
-
key = key
|
|
7434
|
-
value = value
|
|
7423
|
+
key = key.trim();
|
|
7424
|
+
value = value && value.trim();
|
|
7435
7425
|
if (key && value) {
|
|
7436
7426
|
styleMap.set(key, value);
|
|
7437
7427
|
}
|
|
@@ -7449,6 +7439,18 @@ function isMapEqual(a, b) {
|
|
|
7449
7439
|
}
|
|
7450
7440
|
return true;
|
|
7451
7441
|
}
|
|
7442
|
+
function resolveCssVars(instance, vnode, expectedMap) {
|
|
7443
|
+
const root = instance.subTree;
|
|
7444
|
+
if (instance.getCssVars && (vnode === root || root && root.type === Fragment && root.children.includes(vnode))) {
|
|
7445
|
+
const cssVars = instance.getCssVars();
|
|
7446
|
+
for (const key in cssVars) {
|
|
7447
|
+
expectedMap.set(`--${key}`, String(cssVars[key]));
|
|
7448
|
+
}
|
|
7449
|
+
}
|
|
7450
|
+
if (vnode === root && instance.parent) {
|
|
7451
|
+
resolveCssVars(instance.parent, instance.vnode, expectedMap);
|
|
7452
|
+
}
|
|
7453
|
+
}
|
|
7452
7454
|
|
|
7453
7455
|
let supported;
|
|
7454
7456
|
let perf;
|
|
@@ -7766,14 +7768,8 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
7766
7768
|
}
|
|
7767
7769
|
}
|
|
7768
7770
|
{
|
|
7769
|
-
|
|
7770
|
-
|
|
7771
|
-
enumerable: false
|
|
7772
|
-
});
|
|
7773
|
-
Object.defineProperty(el, "__vueParentComponent", {
|
|
7774
|
-
value: parentComponent,
|
|
7775
|
-
enumerable: false
|
|
7776
|
-
});
|
|
7771
|
+
def(el, "__vnode", vnode, true);
|
|
7772
|
+
def(el, "__vueParentComponent", parentComponent, true);
|
|
7777
7773
|
}
|
|
7778
7774
|
if (dirs) {
|
|
7779
7775
|
invokeDirectiveHook(vnode, null, parentComponent, "beforeMount");
|
|
@@ -7835,6 +7831,9 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
7835
7831
|
};
|
|
7836
7832
|
const patchElement = (n1, n2, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
|
|
7837
7833
|
const el = n2.el = n1.el;
|
|
7834
|
+
{
|
|
7835
|
+
el.__vnode = n2;
|
|
7836
|
+
}
|
|
7838
7837
|
let { patchFlag, dynamicChildren, dirs } = n2;
|
|
7839
7838
|
patchFlag |= n1.patchFlag & 16;
|
|
7840
7839
|
const oldProps = n1.props || EMPTY_OBJ;
|
|
@@ -8754,6 +8753,9 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
8754
8753
|
dirs,
|
|
8755
8754
|
memoIndex
|
|
8756
8755
|
} = vnode;
|
|
8756
|
+
if (patchFlag === -2) {
|
|
8757
|
+
optimized = false;
|
|
8758
|
+
}
|
|
8757
8759
|
if (ref != null) {
|
|
8758
8760
|
setRef(ref, null, parentSuspense, vnode, true);
|
|
8759
8761
|
}
|
|
@@ -8785,7 +8787,6 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
8785
8787
|
vnode,
|
|
8786
8788
|
parentComponent,
|
|
8787
8789
|
parentSuspense,
|
|
8788
|
-
optimized,
|
|
8789
8790
|
internals,
|
|
8790
8791
|
doRemove
|
|
8791
8792
|
);
|
|
@@ -10086,7 +10087,7 @@ const TeleportImpl = {
|
|
|
10086
10087
|
}
|
|
10087
10088
|
updateCssVars(n2);
|
|
10088
10089
|
},
|
|
10089
|
-
remove(vnode, parentComponent, parentSuspense,
|
|
10090
|
+
remove(vnode, parentComponent, parentSuspense, { um: unmount, o: { remove: hostRemove } }, doRemove) {
|
|
10090
10091
|
const { shapeFlag, children, anchor, targetAnchor, target, props } = vnode;
|
|
10091
10092
|
if (target) {
|
|
10092
10093
|
hostRemove(targetAnchor);
|
|
@@ -11337,7 +11338,7 @@ function isMemoSame(cached, memo) {
|
|
|
11337
11338
|
return true;
|
|
11338
11339
|
}
|
|
11339
11340
|
|
|
11340
|
-
const version = "3.4.
|
|
11341
|
+
const version = "3.4.30";
|
|
11341
11342
|
const warn = warn$1 ;
|
|
11342
11343
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
11343
11344
|
const devtools = devtools$1 ;
|
|
@@ -11964,7 +11965,10 @@ function patchAttr(el, key, value, isSVG, instance, isBoolean = isSpecialBoolean
|
|
|
11964
11965
|
if (value == null || isBoolean && !includeBooleanAttr(value)) {
|
|
11965
11966
|
el.removeAttribute(key);
|
|
11966
11967
|
} else {
|
|
11967
|
-
el.setAttribute(
|
|
11968
|
+
el.setAttribute(
|
|
11969
|
+
key,
|
|
11970
|
+
isBoolean ? "" : isSymbol(value) ? String(value) : value
|
|
11971
|
+
);
|
|
11968
11972
|
}
|
|
11969
11973
|
}
|
|
11970
11974
|
}
|
|
@@ -12166,7 +12170,7 @@ const patchProp = (el, key, prevValue, nextValue, namespace, prevChildren, paren
|
|
|
12166
12170
|
parentSuspense,
|
|
12167
12171
|
unmountChildren
|
|
12168
12172
|
);
|
|
12169
|
-
if (key === "value" || key === "checked" || key === "selected") {
|
|
12173
|
+
if (!el.tagName.includes("-") && (key === "value" || key === "checked" || key === "selected")) {
|
|
12170
12174
|
patchAttr(el, key, nextValue, isSVG, parentComponent, key !== "value");
|
|
12171
12175
|
}
|
|
12172
12176
|
} else {
|