@vue/runtime-dom 3.5.8 → 3.5.10
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/runtime-dom.cjs.js +11 -12
- package/dist/runtime-dom.cjs.prod.js +11 -12
- package/dist/runtime-dom.esm-browser.js +62 -47
- package/dist/runtime-dom.esm-browser.prod.js +2 -2
- package/dist/runtime-dom.esm-bundler.js +12 -13
- package/dist/runtime-dom.global.js +62 -47
- package/dist/runtime-dom.global.prod.js +2 -2
- package/package.json +4 -4
package/dist/runtime-dom.cjs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/runtime-dom v3.5.
|
|
2
|
+
* @vue/runtime-dom v3.5.10
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -709,6 +709,11 @@ const patchProp = (el, key, prevValue, nextValue, namespace, parentComponent) =>
|
|
|
709
709
|
if (!el.tagName.includes("-") && (key === "value" || key === "checked" || key === "selected")) {
|
|
710
710
|
patchAttr(el, key, nextValue, isSVG, parentComponent, key !== "value");
|
|
711
711
|
}
|
|
712
|
+
} else if (
|
|
713
|
+
// #11081 force set props for possible async custom element
|
|
714
|
+
el._isVueCE && (/[A-Z]/.test(key) || !shared.isString(nextValue))
|
|
715
|
+
) {
|
|
716
|
+
patchDOMProp(el, shared.camelize(key), nextValue);
|
|
712
717
|
} else {
|
|
713
718
|
if (key === "true-value") {
|
|
714
719
|
el._trueValue = nextValue;
|
|
@@ -749,13 +754,7 @@ function shouldSetAsProp(el, key, value, isSVG) {
|
|
|
749
754
|
if (isNativeOn(key) && shared.isString(value)) {
|
|
750
755
|
return false;
|
|
751
756
|
}
|
|
752
|
-
|
|
753
|
-
return true;
|
|
754
|
-
}
|
|
755
|
-
if (el._isVueCE && (/[A-Z]/.test(key) || !shared.isString(value))) {
|
|
756
|
-
return true;
|
|
757
|
-
}
|
|
758
|
-
return false;
|
|
757
|
+
return key in el;
|
|
759
758
|
}
|
|
760
759
|
|
|
761
760
|
const REMOVAL = {};
|
|
@@ -1432,7 +1431,7 @@ const vModelCheckbox = {
|
|
|
1432
1431
|
setChecked(el, binding, vnode);
|
|
1433
1432
|
}
|
|
1434
1433
|
};
|
|
1435
|
-
function setChecked(el, { value
|
|
1434
|
+
function setChecked(el, { value }, vnode) {
|
|
1436
1435
|
el._modelValue = value;
|
|
1437
1436
|
let checked;
|
|
1438
1437
|
if (shared.isArray(value)) {
|
|
@@ -1482,19 +1481,19 @@ const vModelSelect = {
|
|
|
1482
1481
|
},
|
|
1483
1482
|
// set value in mounted & updated because <select> relies on its children
|
|
1484
1483
|
// <option>s.
|
|
1485
|
-
mounted(el, { value
|
|
1484
|
+
mounted(el, { value }) {
|
|
1486
1485
|
setSelected(el, value);
|
|
1487
1486
|
},
|
|
1488
1487
|
beforeUpdate(el, _binding, vnode) {
|
|
1489
1488
|
el[assignKey] = getModelAssigner(vnode);
|
|
1490
1489
|
},
|
|
1491
|
-
updated(el, { value
|
|
1490
|
+
updated(el, { value }) {
|
|
1492
1491
|
if (!el._assigning) {
|
|
1493
1492
|
setSelected(el, value);
|
|
1494
1493
|
}
|
|
1495
1494
|
}
|
|
1496
1495
|
};
|
|
1497
|
-
function setSelected(el, value
|
|
1496
|
+
function setSelected(el, value) {
|
|
1498
1497
|
const isMultiple = el.multiple;
|
|
1499
1498
|
const isArrayValue = shared.isArray(value);
|
|
1500
1499
|
if (isMultiple && !isArrayValue && !shared.isSet(value)) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/runtime-dom v3.5.
|
|
2
|
+
* @vue/runtime-dom v3.5.10
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -678,6 +678,11 @@ const patchProp = (el, key, prevValue, nextValue, namespace, parentComponent) =>
|
|
|
678
678
|
if (!el.tagName.includes("-") && (key === "value" || key === "checked" || key === "selected")) {
|
|
679
679
|
patchAttr(el, key, nextValue, isSVG, parentComponent, key !== "value");
|
|
680
680
|
}
|
|
681
|
+
} else if (
|
|
682
|
+
// #11081 force set props for possible async custom element
|
|
683
|
+
el._isVueCE && (/[A-Z]/.test(key) || !shared.isString(nextValue))
|
|
684
|
+
) {
|
|
685
|
+
patchDOMProp(el, shared.camelize(key), nextValue);
|
|
681
686
|
} else {
|
|
682
687
|
if (key === "true-value") {
|
|
683
688
|
el._trueValue = nextValue;
|
|
@@ -718,13 +723,7 @@ function shouldSetAsProp(el, key, value, isSVG) {
|
|
|
718
723
|
if (isNativeOn(key) && shared.isString(value)) {
|
|
719
724
|
return false;
|
|
720
725
|
}
|
|
721
|
-
|
|
722
|
-
return true;
|
|
723
|
-
}
|
|
724
|
-
if (el._isVueCE && (/[A-Z]/.test(key) || !shared.isString(value))) {
|
|
725
|
-
return true;
|
|
726
|
-
}
|
|
727
|
-
return false;
|
|
726
|
+
return key in el;
|
|
728
727
|
}
|
|
729
728
|
|
|
730
729
|
const REMOVAL = {};
|
|
@@ -1337,7 +1336,7 @@ const vModelCheckbox = {
|
|
|
1337
1336
|
setChecked(el, binding, vnode);
|
|
1338
1337
|
}
|
|
1339
1338
|
};
|
|
1340
|
-
function setChecked(el, { value
|
|
1339
|
+
function setChecked(el, { value }, vnode) {
|
|
1341
1340
|
el._modelValue = value;
|
|
1342
1341
|
let checked;
|
|
1343
1342
|
if (shared.isArray(value)) {
|
|
@@ -1387,19 +1386,19 @@ const vModelSelect = {
|
|
|
1387
1386
|
},
|
|
1388
1387
|
// set value in mounted & updated because <select> relies on its children
|
|
1389
1388
|
// <option>s.
|
|
1390
|
-
mounted(el, { value
|
|
1389
|
+
mounted(el, { value }) {
|
|
1391
1390
|
setSelected(el, value);
|
|
1392
1391
|
},
|
|
1393
1392
|
beforeUpdate(el, _binding, vnode) {
|
|
1394
1393
|
el[assignKey] = getModelAssigner(vnode);
|
|
1395
1394
|
},
|
|
1396
|
-
updated(el, { value
|
|
1395
|
+
updated(el, { value }) {
|
|
1397
1396
|
if (!el._assigning) {
|
|
1398
1397
|
setSelected(el, value);
|
|
1399
1398
|
}
|
|
1400
1399
|
}
|
|
1401
1400
|
};
|
|
1402
|
-
function setSelected(el, value
|
|
1401
|
+
function setSelected(el, value) {
|
|
1403
1402
|
const isMultiple = el.multiple;
|
|
1404
1403
|
const isArrayValue = shared.isArray(value);
|
|
1405
1404
|
if (isMultiple && !isArrayValue && !shared.isSet(value)) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/runtime-dom v3.5.
|
|
2
|
+
* @vue/runtime-dom v3.5.10
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -572,9 +572,17 @@ function endBatch() {
|
|
|
572
572
|
let error;
|
|
573
573
|
while (batchedSub) {
|
|
574
574
|
let e = batchedSub;
|
|
575
|
+
let next;
|
|
576
|
+
while (e) {
|
|
577
|
+
if (!(e.flags & 1)) {
|
|
578
|
+
e.flags &= ~8;
|
|
579
|
+
}
|
|
580
|
+
e = e.next;
|
|
581
|
+
}
|
|
582
|
+
e = batchedSub;
|
|
575
583
|
batchedSub = void 0;
|
|
576
584
|
while (e) {
|
|
577
|
-
|
|
585
|
+
next = e.next;
|
|
578
586
|
e.next = void 0;
|
|
579
587
|
e.flags &= ~8;
|
|
580
588
|
if (e.flags & 1) {
|
|
@@ -597,7 +605,7 @@ function prepareDeps(sub) {
|
|
|
597
605
|
link.dep.activeLink = link;
|
|
598
606
|
}
|
|
599
607
|
}
|
|
600
|
-
function cleanupDeps(sub
|
|
608
|
+
function cleanupDeps(sub) {
|
|
601
609
|
let head;
|
|
602
610
|
let tail = sub.depsTail;
|
|
603
611
|
let link = tail;
|
|
@@ -605,7 +613,7 @@ function cleanupDeps(sub, fromComputed = false) {
|
|
|
605
613
|
const prev = link.prevDep;
|
|
606
614
|
if (link.version === -1) {
|
|
607
615
|
if (link === tail) tail = prev;
|
|
608
|
-
removeSub(link
|
|
616
|
+
removeSub(link);
|
|
609
617
|
removeDep(link);
|
|
610
618
|
} else {
|
|
611
619
|
head = link;
|
|
@@ -660,11 +668,11 @@ function refreshComputed(computed) {
|
|
|
660
668
|
} finally {
|
|
661
669
|
activeSub = prevSub;
|
|
662
670
|
shouldTrack = prevShouldTrack;
|
|
663
|
-
cleanupDeps(computed
|
|
671
|
+
cleanupDeps(computed);
|
|
664
672
|
computed.flags &= ~2;
|
|
665
673
|
}
|
|
666
674
|
}
|
|
667
|
-
function removeSub(link,
|
|
675
|
+
function removeSub(link, soft = false) {
|
|
668
676
|
const { dep, prevSub, nextSub } = link;
|
|
669
677
|
if (prevSub) {
|
|
670
678
|
prevSub.nextSub = nextSub;
|
|
@@ -680,17 +688,15 @@ function removeSub(link, fromComputed = false) {
|
|
|
680
688
|
if (dep.subsHead === link) {
|
|
681
689
|
dep.subsHead = nextSub;
|
|
682
690
|
}
|
|
683
|
-
if (!dep.subs) {
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
removeSub(l, true);
|
|
688
|
-
}
|
|
689
|
-
} else if (dep.map && !fromComputed) {
|
|
690
|
-
dep.map.delete(dep.key);
|
|
691
|
-
if (!dep.map.size) targetMap.delete(dep.target);
|
|
691
|
+
if (!dep.subs && dep.computed) {
|
|
692
|
+
dep.computed.flags &= ~4;
|
|
693
|
+
for (let l = dep.computed.deps; l; l = l.nextDep) {
|
|
694
|
+
removeSub(l, true);
|
|
692
695
|
}
|
|
693
696
|
}
|
|
697
|
+
if (!soft && !--dep.sc && dep.map) {
|
|
698
|
+
dep.map.delete(dep.key);
|
|
699
|
+
}
|
|
694
700
|
}
|
|
695
701
|
function removeDep(link) {
|
|
696
702
|
const { prevDep, nextDep } = link;
|
|
@@ -775,6 +781,10 @@ class Dep {
|
|
|
775
781
|
this.target = void 0;
|
|
776
782
|
this.map = void 0;
|
|
777
783
|
this.key = void 0;
|
|
784
|
+
/**
|
|
785
|
+
* Subscriber counter
|
|
786
|
+
*/
|
|
787
|
+
this.sc = 0;
|
|
778
788
|
{
|
|
779
789
|
this.subsHead = void 0;
|
|
780
790
|
}
|
|
@@ -793,9 +803,7 @@ class Dep {
|
|
|
793
803
|
activeSub.depsTail.nextDep = link;
|
|
794
804
|
activeSub.depsTail = link;
|
|
795
805
|
}
|
|
796
|
-
|
|
797
|
-
addSub(link);
|
|
798
|
-
}
|
|
806
|
+
addSub(link);
|
|
799
807
|
} else if (link.version === -1) {
|
|
800
808
|
link.version = this.version;
|
|
801
809
|
if (link.nextDep) {
|
|
@@ -859,22 +867,25 @@ class Dep {
|
|
|
859
867
|
}
|
|
860
868
|
}
|
|
861
869
|
function addSub(link) {
|
|
862
|
-
|
|
863
|
-
if (
|
|
864
|
-
computed
|
|
865
|
-
|
|
866
|
-
|
|
870
|
+
link.dep.sc++;
|
|
871
|
+
if (link.sub.flags & 4) {
|
|
872
|
+
const computed = link.dep.computed;
|
|
873
|
+
if (computed && !link.dep.subs) {
|
|
874
|
+
computed.flags |= 4 | 16;
|
|
875
|
+
for (let l = computed.deps; l; l = l.nextDep) {
|
|
876
|
+
addSub(l);
|
|
877
|
+
}
|
|
867
878
|
}
|
|
879
|
+
const currentTail = link.dep.subs;
|
|
880
|
+
if (currentTail !== link) {
|
|
881
|
+
link.prevSub = currentTail;
|
|
882
|
+
if (currentTail) currentTail.nextSub = link;
|
|
883
|
+
}
|
|
884
|
+
if (link.dep.subsHead === void 0) {
|
|
885
|
+
link.dep.subsHead = link;
|
|
886
|
+
}
|
|
887
|
+
link.dep.subs = link;
|
|
868
888
|
}
|
|
869
|
-
const currentTail = link.dep.subs;
|
|
870
|
-
if (currentTail !== link) {
|
|
871
|
-
link.prevSub = currentTail;
|
|
872
|
-
if (currentTail) currentTail.nextSub = link;
|
|
873
|
-
}
|
|
874
|
-
if (link.dep.subsHead === void 0) {
|
|
875
|
-
link.dep.subsHead = link;
|
|
876
|
-
}
|
|
877
|
-
link.dep.subs = link;
|
|
878
889
|
}
|
|
879
890
|
const targetMap = /* @__PURE__ */ new WeakMap();
|
|
880
891
|
const ITERATE_KEY = Symbol(
|
|
@@ -978,8 +989,8 @@ function trigger(target, type, key, newValue, oldValue, oldTarget) {
|
|
|
978
989
|
endBatch();
|
|
979
990
|
}
|
|
980
991
|
function getDepFromReactive(object, key) {
|
|
981
|
-
|
|
982
|
-
return
|
|
992
|
+
const depMap = targetMap.get(object);
|
|
993
|
+
return depMap && depMap.get(key);
|
|
983
994
|
}
|
|
984
995
|
|
|
985
996
|
function reactiveReadArray(array) {
|
|
@@ -1915,6 +1926,10 @@ class ComputedRefImpl {
|
|
|
1915
1926
|
* @internal
|
|
1916
1927
|
*/
|
|
1917
1928
|
this.globalVersion = globalVersion - 1;
|
|
1929
|
+
/**
|
|
1930
|
+
* @internal
|
|
1931
|
+
*/
|
|
1932
|
+
this.next = void 0;
|
|
1918
1933
|
// for backwards compat
|
|
1919
1934
|
this.effect = this;
|
|
1920
1935
|
this["__v_isReadonly"] = !setter;
|
|
@@ -3631,6 +3646,7 @@ function useId() {
|
|
|
3631
3646
|
`useId() is called when there is no active component instance to be associated with.`
|
|
3632
3647
|
);
|
|
3633
3648
|
}
|
|
3649
|
+
return "";
|
|
3634
3650
|
}
|
|
3635
3651
|
function markAsyncBoundary(instance) {
|
|
3636
3652
|
instance.ids = [instance.ids[0] + instance.ids[2]++ + "-", 0, 0];
|
|
@@ -9691,7 +9707,7 @@ function normalizeVNode(child) {
|
|
|
9691
9707
|
// #3666, avoid reference pollution when reusing vnode
|
|
9692
9708
|
child.slice()
|
|
9693
9709
|
);
|
|
9694
|
-
} else if (
|
|
9710
|
+
} else if (isVNode(child)) {
|
|
9695
9711
|
return cloneIfMounted(child);
|
|
9696
9712
|
} else {
|
|
9697
9713
|
return createVNode(Text, null, String(child));
|
|
@@ -10436,7 +10452,7 @@ function isMemoSame(cached, memo) {
|
|
|
10436
10452
|
return true;
|
|
10437
10453
|
}
|
|
10438
10454
|
|
|
10439
|
-
const version = "3.5.
|
|
10455
|
+
const version = "3.5.10";
|
|
10440
10456
|
const warn = warn$1 ;
|
|
10441
10457
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
10442
10458
|
const devtools = devtools$1 ;
|
|
@@ -11223,6 +11239,11 @@ const patchProp = (el, key, prevValue, nextValue, namespace, parentComponent) =>
|
|
|
11223
11239
|
if (!el.tagName.includes("-") && (key === "value" || key === "checked" || key === "selected")) {
|
|
11224
11240
|
patchAttr(el, key, nextValue, isSVG, parentComponent, key !== "value");
|
|
11225
11241
|
}
|
|
11242
|
+
} else if (
|
|
11243
|
+
// #11081 force set props for possible async custom element
|
|
11244
|
+
el._isVueCE && (/[A-Z]/.test(key) || !isString(nextValue))
|
|
11245
|
+
) {
|
|
11246
|
+
patchDOMProp(el, camelize(key), nextValue);
|
|
11226
11247
|
} else {
|
|
11227
11248
|
if (key === "true-value") {
|
|
11228
11249
|
el._trueValue = nextValue;
|
|
@@ -11263,13 +11284,7 @@ function shouldSetAsProp(el, key, value, isSVG) {
|
|
|
11263
11284
|
if (isNativeOn(key) && isString(value)) {
|
|
11264
11285
|
return false;
|
|
11265
11286
|
}
|
|
11266
|
-
|
|
11267
|
-
return true;
|
|
11268
|
-
}
|
|
11269
|
-
if (el._isVueCE && (/[A-Z]/.test(key) || !isString(value))) {
|
|
11270
|
-
return true;
|
|
11271
|
-
}
|
|
11272
|
-
return false;
|
|
11287
|
+
return key in el;
|
|
11273
11288
|
}
|
|
11274
11289
|
|
|
11275
11290
|
const REMOVAL = {};
|
|
@@ -11946,7 +11961,7 @@ const vModelCheckbox = {
|
|
|
11946
11961
|
setChecked(el, binding, vnode);
|
|
11947
11962
|
}
|
|
11948
11963
|
};
|
|
11949
|
-
function setChecked(el, { value
|
|
11964
|
+
function setChecked(el, { value }, vnode) {
|
|
11950
11965
|
el._modelValue = value;
|
|
11951
11966
|
let checked;
|
|
11952
11967
|
if (isArray(value)) {
|
|
@@ -11996,19 +12011,19 @@ const vModelSelect = {
|
|
|
11996
12011
|
},
|
|
11997
12012
|
// set value in mounted & updated because <select> relies on its children
|
|
11998
12013
|
// <option>s.
|
|
11999
|
-
mounted(el, { value
|
|
12014
|
+
mounted(el, { value }) {
|
|
12000
12015
|
setSelected(el, value);
|
|
12001
12016
|
},
|
|
12002
12017
|
beforeUpdate(el, _binding, vnode) {
|
|
12003
12018
|
el[assignKey] = getModelAssigner(vnode);
|
|
12004
12019
|
},
|
|
12005
|
-
updated(el, { value
|
|
12020
|
+
updated(el, { value }) {
|
|
12006
12021
|
if (!el._assigning) {
|
|
12007
12022
|
setSelected(el, value);
|
|
12008
12023
|
}
|
|
12009
12024
|
}
|
|
12010
12025
|
};
|
|
12011
|
-
function setSelected(el, value
|
|
12026
|
+
function setSelected(el, value) {
|
|
12012
12027
|
const isMultiple = el.multiple;
|
|
12013
12028
|
const isArrayValue = isArray(value);
|
|
12014
12029
|
if (isMultiple && !isArrayValue && !isSet(value)) {
|