vue 3.5.3 → 3.5.4
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 +1 -1
- package/dist/vue.cjs.prod.js +1 -1
- package/dist/vue.esm-browser.js +52 -63
- package/dist/vue.esm-browser.prod.js +3 -3
- package/dist/vue.esm-bundler.js +1 -1
- package/dist/vue.global.js +52 -63
- package/dist/vue.global.prod.js +4 -4
- package/dist/vue.runtime.esm-browser.js +49 -53
- package/dist/vue.runtime.esm-browser.prod.js +2 -2
- package/dist/vue.runtime.esm-bundler.js +1 -1
- package/dist/vue.runtime.global.js +49 -53
- package/dist/vue.runtime.global.prod.js +2 -2
- package/package.json +6 -6
package/dist/vue.esm-bundler.js
CHANGED
package/dist/vue.global.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* vue v3.5.
|
|
2
|
+
* vue v3.5.4
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -8,9 +8,10 @@ var Vue = (function (exports) {
|
|
|
8
8
|
|
|
9
9
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
10
10
|
// @__NO_SIDE_EFFECTS__
|
|
11
|
-
function makeMap(str
|
|
12
|
-
const
|
|
13
|
-
|
|
11
|
+
function makeMap(str) {
|
|
12
|
+
const map = /* @__PURE__ */ Object.create(null);
|
|
13
|
+
for (const key of str.split(",")) map[key] = 1;
|
|
14
|
+
return (val) => val in map;
|
|
14
15
|
}
|
|
15
16
|
|
|
16
17
|
const EMPTY_OBJ = Object.freeze({}) ;
|
|
@@ -681,7 +682,7 @@ var Vue = (function (exports) {
|
|
|
681
682
|
}
|
|
682
683
|
function isDirty(sub) {
|
|
683
684
|
for (let link = sub.deps; link; link = link.nextDep) {
|
|
684
|
-
if (link.dep.version !== link.version || link.dep.computed && refreshComputed(link.dep.computed)
|
|
685
|
+
if (link.dep.version !== link.version || link.dep.computed && refreshComputed(link.dep.computed) || link.dep.version !== link.version) {
|
|
685
686
|
return true;
|
|
686
687
|
}
|
|
687
688
|
}
|
|
@@ -691,9 +692,6 @@ var Vue = (function (exports) {
|
|
|
691
692
|
return false;
|
|
692
693
|
}
|
|
693
694
|
function refreshComputed(computed) {
|
|
694
|
-
if (computed.flags & 2) {
|
|
695
|
-
return false;
|
|
696
|
-
}
|
|
697
695
|
if (computed.flags & 4 && !(computed.flags & 16)) {
|
|
698
696
|
return;
|
|
699
697
|
}
|
|
@@ -960,9 +958,23 @@ var Vue = (function (exports) {
|
|
|
960
958
|
globalVersion++;
|
|
961
959
|
return;
|
|
962
960
|
}
|
|
963
|
-
|
|
961
|
+
const run = (dep) => {
|
|
962
|
+
if (dep) {
|
|
963
|
+
{
|
|
964
|
+
dep.trigger({
|
|
965
|
+
target,
|
|
966
|
+
type,
|
|
967
|
+
key,
|
|
968
|
+
newValue,
|
|
969
|
+
oldValue,
|
|
970
|
+
oldTarget
|
|
971
|
+
});
|
|
972
|
+
}
|
|
973
|
+
}
|
|
974
|
+
};
|
|
975
|
+
startBatch();
|
|
964
976
|
if (type === "clear") {
|
|
965
|
-
|
|
977
|
+
depsMap.forEach(run);
|
|
966
978
|
} else {
|
|
967
979
|
const targetIsArray = isArray(target);
|
|
968
980
|
const isArrayIndex = targetIsArray && isIntegerKey(key);
|
|
@@ -970,57 +982,43 @@ var Vue = (function (exports) {
|
|
|
970
982
|
const newLength = Number(newValue);
|
|
971
983
|
depsMap.forEach((dep, key2) => {
|
|
972
984
|
if (key2 === "length" || key2 === ARRAY_ITERATE_KEY || !isSymbol(key2) && key2 >= newLength) {
|
|
973
|
-
|
|
985
|
+
run(dep);
|
|
974
986
|
}
|
|
975
987
|
});
|
|
976
988
|
} else {
|
|
977
|
-
const push = (dep) => dep && deps.push(dep);
|
|
978
989
|
if (key !== void 0) {
|
|
979
|
-
|
|
990
|
+
run(depsMap.get(key));
|
|
980
991
|
}
|
|
981
992
|
if (isArrayIndex) {
|
|
982
|
-
|
|
993
|
+
run(depsMap.get(ARRAY_ITERATE_KEY));
|
|
983
994
|
}
|
|
984
995
|
switch (type) {
|
|
985
996
|
case "add":
|
|
986
997
|
if (!targetIsArray) {
|
|
987
|
-
|
|
998
|
+
run(depsMap.get(ITERATE_KEY));
|
|
988
999
|
if (isMap(target)) {
|
|
989
|
-
|
|
1000
|
+
run(depsMap.get(MAP_KEY_ITERATE_KEY));
|
|
990
1001
|
}
|
|
991
1002
|
} else if (isArrayIndex) {
|
|
992
|
-
|
|
1003
|
+
run(depsMap.get("length"));
|
|
993
1004
|
}
|
|
994
1005
|
break;
|
|
995
1006
|
case "delete":
|
|
996
1007
|
if (!targetIsArray) {
|
|
997
|
-
|
|
1008
|
+
run(depsMap.get(ITERATE_KEY));
|
|
998
1009
|
if (isMap(target)) {
|
|
999
|
-
|
|
1010
|
+
run(depsMap.get(MAP_KEY_ITERATE_KEY));
|
|
1000
1011
|
}
|
|
1001
1012
|
}
|
|
1002
1013
|
break;
|
|
1003
1014
|
case "set":
|
|
1004
1015
|
if (isMap(target)) {
|
|
1005
|
-
|
|
1016
|
+
run(depsMap.get(ITERATE_KEY));
|
|
1006
1017
|
}
|
|
1007
1018
|
break;
|
|
1008
1019
|
}
|
|
1009
1020
|
}
|
|
1010
1021
|
}
|
|
1011
|
-
startBatch();
|
|
1012
|
-
for (const dep of deps) {
|
|
1013
|
-
{
|
|
1014
|
-
dep.trigger({
|
|
1015
|
-
target,
|
|
1016
|
-
type,
|
|
1017
|
-
key,
|
|
1018
|
-
newValue,
|
|
1019
|
-
oldValue,
|
|
1020
|
-
oldTarget
|
|
1021
|
-
});
|
|
1022
|
-
}
|
|
1023
|
-
}
|
|
1024
1022
|
endBatch();
|
|
1025
1023
|
}
|
|
1026
1024
|
function getDepFromReactive(object, key) {
|
|
@@ -1758,7 +1756,7 @@ var Vue = (function (exports) {
|
|
|
1758
1756
|
return raw ? toRaw(raw) : observed;
|
|
1759
1757
|
}
|
|
1760
1758
|
function markRaw(value) {
|
|
1761
|
-
if (Object.isExtensible(value)) {
|
|
1759
|
+
if (!hasOwn(value, "__v_skip") && Object.isExtensible(value)) {
|
|
1762
1760
|
def(value, "__v_skip", true);
|
|
1763
1761
|
}
|
|
1764
1762
|
return value;
|
|
@@ -1968,8 +1966,8 @@ var Vue = (function (exports) {
|
|
|
1968
1966
|
* @internal
|
|
1969
1967
|
*/
|
|
1970
1968
|
notify() {
|
|
1969
|
+
this.flags |= 16;
|
|
1971
1970
|
if (activeSub !== this) {
|
|
1972
|
-
this.flags |= 16;
|
|
1973
1971
|
this.dep.notify();
|
|
1974
1972
|
}
|
|
1975
1973
|
}
|
|
@@ -2657,23 +2655,19 @@ var Vue = (function (exports) {
|
|
|
2657
2655
|
}
|
|
2658
2656
|
}
|
|
2659
2657
|
function checkRecursiveUpdates(seen, fn) {
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
const
|
|
2664
|
-
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
|
|
2668
|
-
|
|
2669
|
-
|
|
2670
|
-
10
|
|
2671
|
-
);
|
|
2672
|
-
return true;
|
|
2673
|
-
} else {
|
|
2674
|
-
seen.set(fn, count + 1);
|
|
2675
|
-
}
|
|
2658
|
+
const count = seen.get(fn) || 0;
|
|
2659
|
+
if (count > RECURSION_LIMIT) {
|
|
2660
|
+
const instance = fn.i;
|
|
2661
|
+
const componentName = instance && getComponentName(instance.type);
|
|
2662
|
+
handleError(
|
|
2663
|
+
`Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`,
|
|
2664
|
+
null,
|
|
2665
|
+
10
|
|
2666
|
+
);
|
|
2667
|
+
return true;
|
|
2676
2668
|
}
|
|
2669
|
+
seen.set(fn, count + 1);
|
|
2670
|
+
return false;
|
|
2677
2671
|
}
|
|
2678
2672
|
|
|
2679
2673
|
let isHmrUpdating = false;
|
|
@@ -5021,13 +5015,15 @@ If this is a native custom element, make sure to exclude it from component resol
|
|
|
5021
5015
|
const sourceIsArray = isArray(source);
|
|
5022
5016
|
if (sourceIsArray || isString(source)) {
|
|
5023
5017
|
const sourceIsReactiveArray = sourceIsArray && isReactive(source);
|
|
5018
|
+
let needsWrap = false;
|
|
5024
5019
|
if (sourceIsReactiveArray) {
|
|
5020
|
+
needsWrap = !isShallow(source);
|
|
5025
5021
|
source = shallowReadArray(source);
|
|
5026
5022
|
}
|
|
5027
5023
|
ret = new Array(source.length);
|
|
5028
5024
|
for (let i = 0, l = source.length; i < l; i++) {
|
|
5029
5025
|
ret[i] = renderItem(
|
|
5030
|
-
|
|
5026
|
+
needsWrap ? toReactive(source[i]) : source[i],
|
|
5031
5027
|
i,
|
|
5032
5028
|
void 0,
|
|
5033
5029
|
cached && cached[i]
|
|
@@ -10412,7 +10408,7 @@ Component that was made reactive: `,
|
|
|
10412
10408
|
return true;
|
|
10413
10409
|
}
|
|
10414
10410
|
|
|
10415
|
-
const version = "3.5.
|
|
10411
|
+
const version = "3.5.4";
|
|
10416
10412
|
const warn = warn$1 ;
|
|
10417
10413
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
10418
10414
|
const devtools = devtools$1 ;
|
|
@@ -14729,10 +14725,8 @@ Use a v-bind binding combined with a v-on listener that emits update:x event ins
|
|
|
14729
14725
|
}
|
|
14730
14726
|
} else if (children.length > 1) {
|
|
14731
14727
|
let patchFlag = 64;
|
|
14732
|
-
let patchFlagText = PatchFlagNames[64];
|
|
14733
14728
|
if (children.filter((c) => c.type !== 3).length === 1) {
|
|
14734
14729
|
patchFlag |= 2048;
|
|
14735
|
-
patchFlagText += `, ${PatchFlagNames[2048]}`;
|
|
14736
14730
|
}
|
|
14737
14731
|
root.codegenNode = createVNodeCall(
|
|
14738
14732
|
context,
|
|
@@ -15632,10 +15626,8 @@ Use a v-bind binding combined with a v-on listener that emits update:x event ins
|
|
|
15632
15626
|
return vnodeCall;
|
|
15633
15627
|
} else {
|
|
15634
15628
|
let patchFlag = 64;
|
|
15635
|
-
let patchFlagText = PatchFlagNames[64];
|
|
15636
15629
|
if (!branch.isTemplateIf && children.filter((c) => c.type !== 3).length === 1) {
|
|
15637
15630
|
patchFlag |= 2048;
|
|
15638
|
-
patchFlagText += `, ${PatchFlagNames[2048]}`;
|
|
15639
15631
|
}
|
|
15640
15632
|
return createVNodeCall(
|
|
15641
15633
|
context,
|
|
@@ -17419,10 +17411,7 @@ Use a v-bind binding combined with a v-on listener that emits update:x event ins
|
|
|
17419
17411
|
`stop,prevent,self,ctrl,shift,alt,meta,exact,middle`
|
|
17420
17412
|
);
|
|
17421
17413
|
const maybeKeyModifier = /* @__PURE__ */ makeMap("left,right");
|
|
17422
|
-
const isKeyboardEvent = /* @__PURE__ */ makeMap(
|
|
17423
|
-
`onkeyup,onkeydown,onkeypress`,
|
|
17424
|
-
true
|
|
17425
|
-
);
|
|
17414
|
+
const isKeyboardEvent = /* @__PURE__ */ makeMap(`onkeyup,onkeydown,onkeypress`);
|
|
17426
17415
|
const resolveModifiers = (key, modifiers, context, loc) => {
|
|
17427
17416
|
const keyModifiers = [];
|
|
17428
17417
|
const nonKeyModifiers = [];
|
|
@@ -17434,7 +17423,7 @@ Use a v-bind binding combined with a v-on listener that emits update:x event ins
|
|
|
17434
17423
|
} else {
|
|
17435
17424
|
if (maybeKeyModifier(modifier)) {
|
|
17436
17425
|
if (isStaticExp(key)) {
|
|
17437
|
-
if (isKeyboardEvent(key.content)) {
|
|
17426
|
+
if (isKeyboardEvent(key.content.toLowerCase())) {
|
|
17438
17427
|
keyModifiers.push(modifier);
|
|
17439
17428
|
} else {
|
|
17440
17429
|
nonKeyModifiers.push(modifier);
|
|
@@ -17487,7 +17476,7 @@ Use a v-bind binding combined with a v-on listener that emits update:x event ins
|
|
|
17487
17476
|
]);
|
|
17488
17477
|
}
|
|
17489
17478
|
if (keyModifiers.length && // if event name is dynamic, always wrap with keys guard
|
|
17490
|
-
(!isStaticExp(key) || isKeyboardEvent(key.content))) {
|
|
17479
|
+
(!isStaticExp(key) || isKeyboardEvent(key.content.toLowerCase()))) {
|
|
17491
17480
|
handlerExp = createCallExpression(context.helper(V_ON_WITH_KEYS), [
|
|
17492
17481
|
handlerExp,
|
|
17493
17482
|
JSON.stringify(keyModifiers)
|