@vue/runtime-dom 3.5.0-beta.3 → 3.5.0-rc.1
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 +7 -3
- package/dist/runtime-dom.cjs.prod.js +7 -3
- package/dist/runtime-dom.esm-browser.js +32 -22
- package/dist/runtime-dom.esm-browser.prod.js +2 -2
- package/dist/runtime-dom.esm-bundler.js +7 -3
- package/dist/runtime-dom.global.js +32 -22
- 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.0-
|
|
2
|
+
* @vue/runtime-dom v3.5.0-rc.1
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -551,8 +551,9 @@ function patchAttr(el, key, value, isSVG, instance, isBoolean = shared.isSpecial
|
|
|
551
551
|
|
|
552
552
|
function patchDOMProp(el, key, value, parentComponent) {
|
|
553
553
|
if (key === "innerHTML" || key === "textContent") {
|
|
554
|
-
if (value
|
|
555
|
-
|
|
554
|
+
if (value != null) {
|
|
555
|
+
el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
|
|
556
|
+
}
|
|
556
557
|
return;
|
|
557
558
|
}
|
|
558
559
|
const tag = el.tagName;
|
|
@@ -979,6 +980,9 @@ class VueElement extends BaseClass {
|
|
|
979
980
|
delete this._props[key];
|
|
980
981
|
} else {
|
|
981
982
|
this._props[key] = val;
|
|
983
|
+
if (key === "key" && this._app) {
|
|
984
|
+
this._app._ceVNode.key = val;
|
|
985
|
+
}
|
|
982
986
|
}
|
|
983
987
|
if (shouldUpdate && this._instance) {
|
|
984
988
|
this._update();
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/runtime-dom v3.5.0-
|
|
2
|
+
* @vue/runtime-dom v3.5.0-rc.1
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -536,8 +536,9 @@ function patchAttr(el, key, value, isSVG, instance, isBoolean = shared.isSpecial
|
|
|
536
536
|
|
|
537
537
|
function patchDOMProp(el, key, value, parentComponent) {
|
|
538
538
|
if (key === "innerHTML" || key === "textContent") {
|
|
539
|
-
if (value
|
|
540
|
-
|
|
539
|
+
if (value != null) {
|
|
540
|
+
el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
|
|
541
|
+
}
|
|
541
542
|
return;
|
|
542
543
|
}
|
|
543
544
|
const tag = el.tagName;
|
|
@@ -934,6 +935,9 @@ class VueElement extends BaseClass {
|
|
|
934
935
|
delete this._props[key];
|
|
935
936
|
} else {
|
|
936
937
|
this._props[key] = val;
|
|
938
|
+
if (key === "key" && this._app) {
|
|
939
|
+
this._app._ceVNode.key = val;
|
|
940
|
+
}
|
|
937
941
|
}
|
|
938
942
|
if (shouldUpdate && this._instance) {
|
|
939
943
|
this._update();
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/runtime-dom v3.5.0-
|
|
2
|
+
* @vue/runtime-dom v3.5.0-rc.1
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -337,12 +337,13 @@ class EffectScope {
|
|
|
337
337
|
pause() {
|
|
338
338
|
if (this._active) {
|
|
339
339
|
this._isPaused = true;
|
|
340
|
+
let i, l;
|
|
340
341
|
if (this.scopes) {
|
|
341
|
-
for (
|
|
342
|
+
for (i = 0, l = this.scopes.length; i < l; i++) {
|
|
342
343
|
this.scopes[i].pause();
|
|
343
344
|
}
|
|
344
345
|
}
|
|
345
|
-
for (
|
|
346
|
+
for (i = 0, l = this.effects.length; i < l; i++) {
|
|
346
347
|
this.effects[i].pause();
|
|
347
348
|
}
|
|
348
349
|
}
|
|
@@ -354,12 +355,13 @@ class EffectScope {
|
|
|
354
355
|
if (this._active) {
|
|
355
356
|
if (this._isPaused) {
|
|
356
357
|
this._isPaused = false;
|
|
358
|
+
let i, l;
|
|
357
359
|
if (this.scopes) {
|
|
358
|
-
for (
|
|
360
|
+
for (i = 0, l = this.scopes.length; i < l; i++) {
|
|
359
361
|
this.scopes[i].resume();
|
|
360
362
|
}
|
|
361
363
|
}
|
|
362
|
-
for (
|
|
364
|
+
for (i = 0, l = this.effects.length; i < l; i++) {
|
|
363
365
|
this.effects[i].resume();
|
|
364
366
|
}
|
|
365
367
|
}
|
|
@@ -552,11 +554,9 @@ function startBatch() {
|
|
|
552
554
|
batchDepth++;
|
|
553
555
|
}
|
|
554
556
|
function endBatch() {
|
|
555
|
-
if (batchDepth >
|
|
556
|
-
batchDepth--;
|
|
557
|
+
if (--batchDepth > 0) {
|
|
557
558
|
return;
|
|
558
559
|
}
|
|
559
|
-
batchDepth--;
|
|
560
560
|
let error;
|
|
561
561
|
while (batchedEffect) {
|
|
562
562
|
let e = batchedEffect;
|
|
@@ -1215,7 +1215,12 @@ class MutableReactiveHandler extends BaseReactiveHandler {
|
|
|
1215
1215
|
}
|
|
1216
1216
|
}
|
|
1217
1217
|
const hadKey = isArray(target) && isIntegerKey(key) ? Number(key) < target.length : hasOwn(target, key);
|
|
1218
|
-
const result = Reflect.set(
|
|
1218
|
+
const result = Reflect.set(
|
|
1219
|
+
target,
|
|
1220
|
+
key,
|
|
1221
|
+
value,
|
|
1222
|
+
isRef(target) ? target : receiver
|
|
1223
|
+
);
|
|
1219
1224
|
if (target === toRaw(receiver)) {
|
|
1220
1225
|
if (!hadKey) {
|
|
1221
1226
|
trigger(target, "add", key, value);
|
|
@@ -2028,18 +2033,25 @@ function watch$1(source, cb, options = EMPTY_OBJ) {
|
|
|
2028
2033
|
const depth = deep === true ? Infinity : deep;
|
|
2029
2034
|
getter = () => traverse(baseGetter(), depth);
|
|
2030
2035
|
}
|
|
2036
|
+
const scope = getCurrentScope();
|
|
2037
|
+
const watchHandle = () => {
|
|
2038
|
+
effect.stop();
|
|
2039
|
+
if (scope) {
|
|
2040
|
+
remove(scope.effects, effect);
|
|
2041
|
+
}
|
|
2042
|
+
};
|
|
2031
2043
|
if (once) {
|
|
2032
2044
|
if (cb) {
|
|
2033
2045
|
const _cb = cb;
|
|
2034
2046
|
cb = (...args) => {
|
|
2035
2047
|
_cb(...args);
|
|
2036
|
-
|
|
2048
|
+
watchHandle();
|
|
2037
2049
|
};
|
|
2038
2050
|
} else {
|
|
2039
2051
|
const _getter = getter;
|
|
2040
2052
|
getter = () => {
|
|
2041
2053
|
_getter();
|
|
2042
|
-
|
|
2054
|
+
watchHandle();
|
|
2043
2055
|
};
|
|
2044
2056
|
}
|
|
2045
2057
|
}
|
|
@@ -2108,13 +2120,6 @@ function watch$1(source, cb, options = EMPTY_OBJ) {
|
|
|
2108
2120
|
} else {
|
|
2109
2121
|
effect.run();
|
|
2110
2122
|
}
|
|
2111
|
-
const scope = getCurrentScope();
|
|
2112
|
-
const watchHandle = () => {
|
|
2113
|
-
effect.stop();
|
|
2114
|
-
if (scope) {
|
|
2115
|
-
remove(scope.effects, effect);
|
|
2116
|
-
}
|
|
2117
|
-
};
|
|
2118
2123
|
watchHandle.pause = effect.pause.bind(effect);
|
|
2119
2124
|
watchHandle.resume = effect.resume.bind(effect);
|
|
2120
2125
|
watchHandle.stop = watchHandle;
|
|
@@ -3563,7 +3568,7 @@ function getTransitionRawChildren(children, keepComment = false, parentKey) {
|
|
|
3563
3568
|
// @__NO_SIDE_EFFECTS__
|
|
3564
3569
|
function defineComponent(options, extraOptions) {
|
|
3565
3570
|
return isFunction(options) ? (
|
|
3566
|
-
// #
|
|
3571
|
+
// #8236: extend call and options.name access are considered side-effects
|
|
3567
3572
|
// by Rollup, so we have to wrap it in a pure-annotated IIFE.
|
|
3568
3573
|
/* @__PURE__ */ (() => extend({ name: options.name }, extraOptions, { setup: options }))()
|
|
3569
3574
|
) : options;
|
|
@@ -4690,6 +4695,7 @@ const KeepAliveImpl = {
|
|
|
4690
4695
|
);
|
|
4691
4696
|
const { include, exclude, max } = props;
|
|
4692
4697
|
if (include && (!name || !matches(include, name)) || exclude && name && matches(exclude, name)) {
|
|
4698
|
+
vnode.shapeFlag &= ~256;
|
|
4693
4699
|
current = vnode;
|
|
4694
4700
|
return rawVNode;
|
|
4695
4701
|
}
|
|
@@ -10344,7 +10350,7 @@ function isMemoSame(cached, memo) {
|
|
|
10344
10350
|
return true;
|
|
10345
10351
|
}
|
|
10346
10352
|
|
|
10347
|
-
const version = "3.5.0-
|
|
10353
|
+
const version = "3.5.0-rc.1";
|
|
10348
10354
|
const warn = warn$1 ;
|
|
10349
10355
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
10350
10356
|
const devtools = devtools$1 ;
|
|
@@ -10971,8 +10977,9 @@ function patchAttr(el, key, value, isSVG, instance, isBoolean = isSpecialBoolean
|
|
|
10971
10977
|
|
|
10972
10978
|
function patchDOMProp(el, key, value, parentComponent) {
|
|
10973
10979
|
if (key === "innerHTML" || key === "textContent") {
|
|
10974
|
-
if (value
|
|
10975
|
-
|
|
10980
|
+
if (value != null) {
|
|
10981
|
+
el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
|
|
10982
|
+
}
|
|
10976
10983
|
return;
|
|
10977
10984
|
}
|
|
10978
10985
|
const tag = el.tagName;
|
|
@@ -11399,6 +11406,9 @@ class VueElement extends BaseClass {
|
|
|
11399
11406
|
delete this._props[key];
|
|
11400
11407
|
} else {
|
|
11401
11408
|
this._props[key] = val;
|
|
11409
|
+
if (key === "key" && this._app) {
|
|
11410
|
+
this._app._ceVNode.key = val;
|
|
11411
|
+
}
|
|
11402
11412
|
}
|
|
11403
11413
|
if (shouldUpdate && this._instance) {
|
|
11404
11414
|
this._update();
|