vue 3.5.12 → 3.5.13
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/README.md +1 -1
- package/dist/vue.cjs.js +1 -1
- package/dist/vue.cjs.prod.js +1 -1
- package/dist/vue.esm-browser.js +88 -31
- package/dist/vue.esm-browser.prod.js +6 -6
- package/dist/vue.esm-bundler.js +1 -1
- package/dist/vue.global.js +88 -31
- package/dist/vue.global.prod.js +3 -3
- package/dist/vue.runtime.esm-browser.js +73 -23
- 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 +73 -23
- package/dist/vue.runtime.global.prod.js +2 -2
- package/package.json +6 -6
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* vue v3.5.
|
|
2
|
+
* vue v3.5.13
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -141,10 +141,9 @@ function parseStringStyle(cssText) {
|
|
|
141
141
|
return ret;
|
|
142
142
|
}
|
|
143
143
|
function stringifyStyle(styles) {
|
|
144
|
+
if (!styles) return "";
|
|
145
|
+
if (isString(styles)) return styles;
|
|
144
146
|
let ret = "";
|
|
145
|
-
if (!styles || isString(styles)) {
|
|
146
|
-
return ret;
|
|
147
|
-
}
|
|
148
147
|
for (const key in styles) {
|
|
149
148
|
const value = styles[key];
|
|
150
149
|
if (isString(value) || typeof value === "number") {
|
|
@@ -405,17 +404,21 @@ class EffectScope {
|
|
|
405
404
|
}
|
|
406
405
|
stop(fromParent) {
|
|
407
406
|
if (this._active) {
|
|
407
|
+
this._active = false;
|
|
408
408
|
let i, l;
|
|
409
409
|
for (i = 0, l = this.effects.length; i < l; i++) {
|
|
410
410
|
this.effects[i].stop();
|
|
411
411
|
}
|
|
412
|
+
this.effects.length = 0;
|
|
412
413
|
for (i = 0, l = this.cleanups.length; i < l; i++) {
|
|
413
414
|
this.cleanups[i]();
|
|
414
415
|
}
|
|
416
|
+
this.cleanups.length = 0;
|
|
415
417
|
if (this.scopes) {
|
|
416
418
|
for (i = 0, l = this.scopes.length; i < l; i++) {
|
|
417
419
|
this.scopes[i].stop(true);
|
|
418
420
|
}
|
|
421
|
+
this.scopes.length = 0;
|
|
419
422
|
}
|
|
420
423
|
if (!this.detached && this.parent && !fromParent) {
|
|
421
424
|
const last = this.parent.scopes.pop();
|
|
@@ -425,7 +428,6 @@ class EffectScope {
|
|
|
425
428
|
}
|
|
426
429
|
}
|
|
427
430
|
this.parent = void 0;
|
|
428
|
-
this._active = false;
|
|
429
431
|
}
|
|
430
432
|
}
|
|
431
433
|
}
|
|
@@ -1191,6 +1193,7 @@ class BaseReactiveHandler {
|
|
|
1191
1193
|
this._isShallow = _isShallow;
|
|
1192
1194
|
}
|
|
1193
1195
|
get(target, key, receiver) {
|
|
1196
|
+
if (key === "__v_skip") return target["__v_skip"];
|
|
1194
1197
|
const isReadonly2 = this._isReadonly, isShallow2 = this._isShallow;
|
|
1195
1198
|
if (key === "__v_isReactive") {
|
|
1196
1199
|
return !isReadonly2;
|
|
@@ -2027,7 +2030,7 @@ function watch$1(source, cb, options = EMPTY_OBJ) {
|
|
|
2027
2030
|
const scope = getCurrentScope();
|
|
2028
2031
|
const watchHandle = () => {
|
|
2029
2032
|
effect.stop();
|
|
2030
|
-
if (scope) {
|
|
2033
|
+
if (scope && scope.active) {
|
|
2031
2034
|
remove(scope.effects, effect);
|
|
2032
2035
|
}
|
|
2033
2036
|
};
|
|
@@ -2987,11 +2990,32 @@ const TeleportImpl = {
|
|
|
2987
2990
|
updateCssVars(n2, true);
|
|
2988
2991
|
}
|
|
2989
2992
|
if (isTeleportDeferred(n2.props)) {
|
|
2990
|
-
queuePostRenderEffect(
|
|
2993
|
+
queuePostRenderEffect(() => {
|
|
2994
|
+
mountToTarget();
|
|
2995
|
+
n2.el.__isMounted = true;
|
|
2996
|
+
}, parentSuspense);
|
|
2991
2997
|
} else {
|
|
2992
2998
|
mountToTarget();
|
|
2993
2999
|
}
|
|
2994
3000
|
} else {
|
|
3001
|
+
if (isTeleportDeferred(n2.props) && !n1.el.__isMounted) {
|
|
3002
|
+
queuePostRenderEffect(() => {
|
|
3003
|
+
TeleportImpl.process(
|
|
3004
|
+
n1,
|
|
3005
|
+
n2,
|
|
3006
|
+
container,
|
|
3007
|
+
anchor,
|
|
3008
|
+
parentComponent,
|
|
3009
|
+
parentSuspense,
|
|
3010
|
+
namespace,
|
|
3011
|
+
slotScopeIds,
|
|
3012
|
+
optimized,
|
|
3013
|
+
internals
|
|
3014
|
+
);
|
|
3015
|
+
delete n1.el.__isMounted;
|
|
3016
|
+
}, parentSuspense);
|
|
3017
|
+
return;
|
|
3018
|
+
}
|
|
2995
3019
|
n2.el = n1.el;
|
|
2996
3020
|
n2.targetStart = n1.targetStart;
|
|
2997
3021
|
const mainAnchor = n2.anchor = n1.anchor;
|
|
@@ -3297,10 +3321,9 @@ const BaseTransitionImpl = {
|
|
|
3297
3321
|
if (innerChild.type !== Comment) {
|
|
3298
3322
|
setTransitionHooks(innerChild, enterHooks);
|
|
3299
3323
|
}
|
|
3300
|
-
|
|
3301
|
-
const oldInnerChild = oldChild && getInnerChild$1(oldChild);
|
|
3324
|
+
let oldInnerChild = instance.subTree && getInnerChild$1(instance.subTree);
|
|
3302
3325
|
if (oldInnerChild && oldInnerChild.type !== Comment && !isSameVNodeType(innerChild, oldInnerChild) && recursiveGetSubtree(instance).type !== Comment) {
|
|
3303
|
-
|
|
3326
|
+
let leavingHooks = resolveTransitionHooks(
|
|
3304
3327
|
oldInnerChild,
|
|
3305
3328
|
rawProps,
|
|
3306
3329
|
state,
|
|
@@ -3315,6 +3338,7 @@ const BaseTransitionImpl = {
|
|
|
3315
3338
|
instance.update();
|
|
3316
3339
|
}
|
|
3317
3340
|
delete leavingHooks.afterLeave;
|
|
3341
|
+
oldInnerChild = void 0;
|
|
3318
3342
|
};
|
|
3319
3343
|
return emptyPlaceholder(child);
|
|
3320
3344
|
} else if (mode === "in-out" && innerChild.type !== Comment) {
|
|
@@ -3328,10 +3352,19 @@ const BaseTransitionImpl = {
|
|
|
3328
3352
|
earlyRemove();
|
|
3329
3353
|
el[leaveCbKey] = void 0;
|
|
3330
3354
|
delete enterHooks.delayedLeave;
|
|
3355
|
+
oldInnerChild = void 0;
|
|
3356
|
+
};
|
|
3357
|
+
enterHooks.delayedLeave = () => {
|
|
3358
|
+
delayedLeave();
|
|
3359
|
+
delete enterHooks.delayedLeave;
|
|
3360
|
+
oldInnerChild = void 0;
|
|
3331
3361
|
};
|
|
3332
|
-
enterHooks.delayedLeave = delayedLeave;
|
|
3333
3362
|
};
|
|
3363
|
+
} else {
|
|
3364
|
+
oldInnerChild = void 0;
|
|
3334
3365
|
}
|
|
3366
|
+
} else if (oldInnerChild) {
|
|
3367
|
+
oldInnerChild = void 0;
|
|
3335
3368
|
}
|
|
3336
3369
|
return child;
|
|
3337
3370
|
};
|
|
@@ -3636,6 +3669,9 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
|
3636
3669
|
return;
|
|
3637
3670
|
}
|
|
3638
3671
|
if (isAsyncWrapper(vnode) && !isUnmount) {
|
|
3672
|
+
if (vnode.shapeFlag & 512 && vnode.type.__asyncResolved && vnode.component.subTree.component) {
|
|
3673
|
+
setRef(rawRef, oldRawRef, parentSuspense, vnode.component.subTree);
|
|
3674
|
+
}
|
|
3639
3675
|
return;
|
|
3640
3676
|
}
|
|
3641
3677
|
const refValue = vnode.shapeFlag & 4 ? getComponentPublicInstance(vnode.component) : vnode.el;
|
|
@@ -3900,7 +3936,7 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
3900
3936
|
getContainerType(container),
|
|
3901
3937
|
optimized
|
|
3902
3938
|
);
|
|
3903
|
-
if (isAsyncWrapper(vnode)) {
|
|
3939
|
+
if (isAsyncWrapper(vnode) && !vnode.type.__asyncResolved) {
|
|
3904
3940
|
let subTree;
|
|
3905
3941
|
if (isFragmentStart) {
|
|
3906
3942
|
subTree = createVNode(Fragment);
|
|
@@ -4169,6 +4205,10 @@ Server rendered element contains fewer child nodes than client vdom.`
|
|
|
4169
4205
|
getContainerType(container),
|
|
4170
4206
|
slotScopeIds
|
|
4171
4207
|
);
|
|
4208
|
+
if (parentComponent) {
|
|
4209
|
+
parentComponent.vnode.el = vnode.el;
|
|
4210
|
+
updateHOCHostEl(parentComponent, vnode.el);
|
|
4211
|
+
}
|
|
4172
4212
|
return next;
|
|
4173
4213
|
};
|
|
4174
4214
|
const locateClosingAnchor = (node, open = "[", close = "]") => {
|
|
@@ -8608,7 +8648,7 @@ function renderComponentRoot(instance) {
|
|
|
8608
8648
|
}
|
|
8609
8649
|
if (extraAttrs.length) {
|
|
8610
8650
|
warn$1(
|
|
8611
|
-
`Extraneous non-props attributes (${extraAttrs.join(", ")}) were passed to component but could not be automatically inherited because component renders fragment or text root nodes.`
|
|
8651
|
+
`Extraneous non-props attributes (${extraAttrs.join(", ")}) were passed to component but could not be automatically inherited because component renders fragment or text or teleport root nodes.`
|
|
8612
8652
|
);
|
|
8613
8653
|
}
|
|
8614
8654
|
if (eventAttrs.length) {
|
|
@@ -9391,9 +9431,9 @@ function closeBlock() {
|
|
|
9391
9431
|
currentBlock = blockStack[blockStack.length - 1] || null;
|
|
9392
9432
|
}
|
|
9393
9433
|
let isBlockTreeEnabled = 1;
|
|
9394
|
-
function setBlockTracking(value) {
|
|
9434
|
+
function setBlockTracking(value, inVOnce = false) {
|
|
9395
9435
|
isBlockTreeEnabled += value;
|
|
9396
|
-
if (value < 0 && currentBlock) {
|
|
9436
|
+
if (value < 0 && currentBlock && inVOnce) {
|
|
9397
9437
|
currentBlock.hasOnce = true;
|
|
9398
9438
|
}
|
|
9399
9439
|
}
|
|
@@ -10417,7 +10457,7 @@ function isMemoSame(cached, memo) {
|
|
|
10417
10457
|
return true;
|
|
10418
10458
|
}
|
|
10419
10459
|
|
|
10420
|
-
const version = "3.5.
|
|
10460
|
+
const version = "3.5.13";
|
|
10421
10461
|
const warn = warn$1 ;
|
|
10422
10462
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
10423
10463
|
const devtools = devtools$1 ;
|
|
@@ -10601,7 +10641,8 @@ function resolveTransitionProps(rawProps) {
|
|
|
10601
10641
|
onAppear = onEnter,
|
|
10602
10642
|
onAppearCancelled = onEnterCancelled
|
|
10603
10643
|
} = baseProps;
|
|
10604
|
-
const finishEnter = (el, isAppear, done) => {
|
|
10644
|
+
const finishEnter = (el, isAppear, done, isCancelled) => {
|
|
10645
|
+
el._enterCancelled = isCancelled;
|
|
10605
10646
|
removeTransitionClass(el, isAppear ? appearToClass : enterToClass);
|
|
10606
10647
|
removeTransitionClass(el, isAppear ? appearActiveClass : enterActiveClass);
|
|
10607
10648
|
done && done();
|
|
@@ -10644,8 +10685,13 @@ function resolveTransitionProps(rawProps) {
|
|
|
10644
10685
|
el._isLeaving = true;
|
|
10645
10686
|
const resolve = () => finishLeave(el, done);
|
|
10646
10687
|
addTransitionClass(el, leaveFromClass);
|
|
10647
|
-
|
|
10648
|
-
|
|
10688
|
+
if (!el._enterCancelled) {
|
|
10689
|
+
forceReflow();
|
|
10690
|
+
addTransitionClass(el, leaveActiveClass);
|
|
10691
|
+
} else {
|
|
10692
|
+
addTransitionClass(el, leaveActiveClass);
|
|
10693
|
+
forceReflow();
|
|
10694
|
+
}
|
|
10649
10695
|
nextFrame(() => {
|
|
10650
10696
|
if (!el._isLeaving) {
|
|
10651
10697
|
return;
|
|
@@ -10659,11 +10705,11 @@ function resolveTransitionProps(rawProps) {
|
|
|
10659
10705
|
callHook(onLeave, [el, resolve]);
|
|
10660
10706
|
},
|
|
10661
10707
|
onEnterCancelled(el) {
|
|
10662
|
-
finishEnter(el, false);
|
|
10708
|
+
finishEnter(el, false, void 0, true);
|
|
10663
10709
|
callHook(onEnterCancelled, [el]);
|
|
10664
10710
|
},
|
|
10665
10711
|
onAppearCancelled(el) {
|
|
10666
|
-
finishEnter(el, true);
|
|
10712
|
+
finishEnter(el, true, void 0, true);
|
|
10667
10713
|
callHook(onAppearCancelled, [el]);
|
|
10668
10714
|
},
|
|
10669
10715
|
onLeaveCancelled(el) {
|
|
@@ -10883,10 +10929,11 @@ function useCssVars(getter) {
|
|
|
10883
10929
|
}
|
|
10884
10930
|
updateTeleports(vars);
|
|
10885
10931
|
};
|
|
10886
|
-
|
|
10887
|
-
|
|
10932
|
+
onBeforeUpdate(() => {
|
|
10933
|
+
queuePostFlushCb(setVars);
|
|
10888
10934
|
});
|
|
10889
10935
|
onMounted(() => {
|
|
10936
|
+
watch(setVars, NOOP, { flush: "post" });
|
|
10890
10937
|
const ob = new MutationObserver(setVars);
|
|
10891
10938
|
ob.observe(instance.subTree.el.parentNode, { childList: true });
|
|
10892
10939
|
onUnmounted(() => ob.disconnect());
|
|
@@ -11493,6 +11540,8 @@ class VueElement extends BaseClass {
|
|
|
11493
11540
|
this._update();
|
|
11494
11541
|
}
|
|
11495
11542
|
if (shouldReflect) {
|
|
11543
|
+
const ob = this._ob;
|
|
11544
|
+
ob && ob.disconnect();
|
|
11496
11545
|
if (val === true) {
|
|
11497
11546
|
this.setAttribute(hyphenate(key), "");
|
|
11498
11547
|
} else if (typeof val === "string" || typeof val === "number") {
|
|
@@ -11500,6 +11549,7 @@ class VueElement extends BaseClass {
|
|
|
11500
11549
|
} else if (!val) {
|
|
11501
11550
|
this.removeAttribute(hyphenate(key));
|
|
11502
11551
|
}
|
|
11552
|
+
ob && ob.observe(this, { attributes: true });
|
|
11503
11553
|
}
|
|
11504
11554
|
}
|
|
11505
11555
|
}
|