@vue/compat 3.5.30 → 3.5.32
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 +120 -84
- package/dist/vue.cjs.prod.js +106 -77
- package/dist/vue.esm-browser.js +120 -84
- package/dist/vue.esm-browser.prod.js +8 -8
- package/dist/vue.esm-bundler.js +120 -84
- package/dist/vue.global.js +120 -84
- package/dist/vue.global.prod.js +8 -8
- package/dist/vue.runtime.esm-browser.js +119 -83
- package/dist/vue.runtime.esm-browser.prod.js +3 -3
- package/dist/vue.runtime.esm-bundler.js +119 -83
- package/dist/vue.runtime.global.js +119 -83
- package/dist/vue.runtime.global.prod.js +3 -3
- package/package.json +3 -3
package/dist/vue.cjs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.32
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -2005,16 +2005,16 @@ function toRefs(object) {
|
|
|
2005
2005
|
return ret;
|
|
2006
2006
|
}
|
|
2007
2007
|
class ObjectRefImpl {
|
|
2008
|
-
constructor(_object,
|
|
2008
|
+
constructor(_object, key, _defaultValue) {
|
|
2009
2009
|
this._object = _object;
|
|
2010
|
-
this._key = _key;
|
|
2011
2010
|
this._defaultValue = _defaultValue;
|
|
2012
2011
|
this["__v_isRef"] = true;
|
|
2013
2012
|
this._value = void 0;
|
|
2013
|
+
this._key = isSymbol(key) ? key : String(key);
|
|
2014
2014
|
this._raw = toRaw(_object);
|
|
2015
2015
|
let shallow = true;
|
|
2016
2016
|
let obj = _object;
|
|
2017
|
-
if (!isArray(_object) || !isIntegerKey(
|
|
2017
|
+
if (!isArray(_object) || isSymbol(this._key) || !isIntegerKey(this._key)) {
|
|
2018
2018
|
do {
|
|
2019
2019
|
shallow = !isProxy(obj) || isShallow(obj);
|
|
2020
2020
|
} while (shallow && (obj = obj["__v_raw"]));
|
|
@@ -2814,6 +2814,13 @@ function checkRecursiveUpdates(seen, fn) {
|
|
|
2814
2814
|
}
|
|
2815
2815
|
|
|
2816
2816
|
let isHmrUpdating = false;
|
|
2817
|
+
const setHmrUpdating = (v) => {
|
|
2818
|
+
try {
|
|
2819
|
+
return isHmrUpdating;
|
|
2820
|
+
} finally {
|
|
2821
|
+
isHmrUpdating = v;
|
|
2822
|
+
}
|
|
2823
|
+
};
|
|
2817
2824
|
const hmrDirtyComponents = /* @__PURE__ */ new Map();
|
|
2818
2825
|
{
|
|
2819
2826
|
getGlobalThis().__VUE_HMR_RUNTIME__ = {
|
|
@@ -3776,6 +3783,7 @@ function createPathGetter(ctx, path) {
|
|
|
3776
3783
|
};
|
|
3777
3784
|
}
|
|
3778
3785
|
|
|
3786
|
+
const pendingMounts = /* @__PURE__ */ new WeakMap();
|
|
3779
3787
|
const TeleportEndKey = /* @__PURE__ */ Symbol("_vte");
|
|
3780
3788
|
const isTeleport = (type) => type.__isTeleport;
|
|
3781
3789
|
const isTeleportDisabled = (props) => props && (props.disabled || props.disabled === "");
|
|
@@ -3817,88 +3825,84 @@ const TeleportImpl = {
|
|
|
3817
3825
|
o: { insert, querySelector, createText, createComment }
|
|
3818
3826
|
} = internals;
|
|
3819
3827
|
const disabled = isTeleportDisabled(n2.props);
|
|
3820
|
-
let {
|
|
3828
|
+
let { dynamicChildren } = n2;
|
|
3821
3829
|
if (isHmrUpdating) {
|
|
3822
3830
|
optimized = false;
|
|
3823
3831
|
dynamicChildren = null;
|
|
3824
3832
|
}
|
|
3833
|
+
const mount = (vnode, container2, anchor2) => {
|
|
3834
|
+
if (vnode.shapeFlag & 16) {
|
|
3835
|
+
mountChildren(
|
|
3836
|
+
vnode.children,
|
|
3837
|
+
container2,
|
|
3838
|
+
anchor2,
|
|
3839
|
+
parentComponent,
|
|
3840
|
+
parentSuspense,
|
|
3841
|
+
namespace,
|
|
3842
|
+
slotScopeIds,
|
|
3843
|
+
optimized
|
|
3844
|
+
);
|
|
3845
|
+
}
|
|
3846
|
+
};
|
|
3847
|
+
const mountToTarget = (vnode = n2) => {
|
|
3848
|
+
const disabled2 = isTeleportDisabled(vnode.props);
|
|
3849
|
+
const target = vnode.target = resolveTarget(vnode.props, querySelector);
|
|
3850
|
+
const targetAnchor = prepareAnchor(target, vnode, createText, insert);
|
|
3851
|
+
if (target) {
|
|
3852
|
+
if (namespace !== "svg" && isTargetSVG(target)) {
|
|
3853
|
+
namespace = "svg";
|
|
3854
|
+
} else if (namespace !== "mathml" && isTargetMathML(target)) {
|
|
3855
|
+
namespace = "mathml";
|
|
3856
|
+
}
|
|
3857
|
+
if (parentComponent && parentComponent.isCE) {
|
|
3858
|
+
(parentComponent.ce._teleportTargets || (parentComponent.ce._teleportTargets = /* @__PURE__ */ new Set())).add(target);
|
|
3859
|
+
}
|
|
3860
|
+
if (!disabled2) {
|
|
3861
|
+
mount(vnode, target, targetAnchor);
|
|
3862
|
+
updateCssVars(vnode, false);
|
|
3863
|
+
}
|
|
3864
|
+
} else if (!disabled2) {
|
|
3865
|
+
warn$1("Invalid Teleport target on mount:", target, `(${typeof target})`);
|
|
3866
|
+
}
|
|
3867
|
+
};
|
|
3868
|
+
const queuePendingMount = (vnode) => {
|
|
3869
|
+
const mountJob = () => {
|
|
3870
|
+
if (pendingMounts.get(vnode) !== mountJob) return;
|
|
3871
|
+
pendingMounts.delete(vnode);
|
|
3872
|
+
if (isTeleportDisabled(vnode.props)) {
|
|
3873
|
+
mount(vnode, container, vnode.anchor);
|
|
3874
|
+
updateCssVars(vnode, true);
|
|
3875
|
+
}
|
|
3876
|
+
mountToTarget(vnode);
|
|
3877
|
+
};
|
|
3878
|
+
pendingMounts.set(vnode, mountJob);
|
|
3879
|
+
queuePostRenderEffect(mountJob, parentSuspense);
|
|
3880
|
+
};
|
|
3825
3881
|
if (n1 == null) {
|
|
3826
3882
|
const placeholder = n2.el = createComment("teleport start") ;
|
|
3827
3883
|
const mainAnchor = n2.anchor = createComment("teleport end") ;
|
|
3828
3884
|
insert(placeholder, container, anchor);
|
|
3829
3885
|
insert(mainAnchor, container, anchor);
|
|
3830
|
-
|
|
3831
|
-
|
|
3832
|
-
|
|
3833
|
-
|
|
3834
|
-
container2,
|
|
3835
|
-
anchor2,
|
|
3836
|
-
parentComponent,
|
|
3837
|
-
parentSuspense,
|
|
3838
|
-
namespace,
|
|
3839
|
-
slotScopeIds,
|
|
3840
|
-
optimized
|
|
3841
|
-
);
|
|
3842
|
-
}
|
|
3843
|
-
};
|
|
3844
|
-
const mountToTarget = () => {
|
|
3845
|
-
const target = n2.target = resolveTarget(n2.props, querySelector);
|
|
3846
|
-
const targetAnchor = prepareAnchor(target, n2, createText, insert);
|
|
3847
|
-
if (target) {
|
|
3848
|
-
if (namespace !== "svg" && isTargetSVG(target)) {
|
|
3849
|
-
namespace = "svg";
|
|
3850
|
-
} else if (namespace !== "mathml" && isTargetMathML(target)) {
|
|
3851
|
-
namespace = "mathml";
|
|
3852
|
-
}
|
|
3853
|
-
if (parentComponent && parentComponent.isCE) {
|
|
3854
|
-
(parentComponent.ce._teleportTargets || (parentComponent.ce._teleportTargets = /* @__PURE__ */ new Set())).add(target);
|
|
3855
|
-
}
|
|
3856
|
-
if (!disabled) {
|
|
3857
|
-
mount(target, targetAnchor);
|
|
3858
|
-
updateCssVars(n2, false);
|
|
3859
|
-
}
|
|
3860
|
-
} else if (!disabled) {
|
|
3861
|
-
warn$1(
|
|
3862
|
-
"Invalid Teleport target on mount:",
|
|
3863
|
-
target,
|
|
3864
|
-
`(${typeof target})`
|
|
3865
|
-
);
|
|
3866
|
-
}
|
|
3867
|
-
};
|
|
3886
|
+
if (isTeleportDeferred(n2.props) || parentSuspense && parentSuspense.pendingBranch) {
|
|
3887
|
+
queuePendingMount(n2);
|
|
3888
|
+
return;
|
|
3889
|
+
}
|
|
3868
3890
|
if (disabled) {
|
|
3869
|
-
mount(container, mainAnchor);
|
|
3891
|
+
mount(n2, container, mainAnchor);
|
|
3870
3892
|
updateCssVars(n2, true);
|
|
3871
3893
|
}
|
|
3872
|
-
|
|
3873
|
-
n2.el.__isMounted = false;
|
|
3874
|
-
queuePostRenderEffect(() => {
|
|
3875
|
-
mountToTarget();
|
|
3876
|
-
delete n2.el.__isMounted;
|
|
3877
|
-
}, parentSuspense);
|
|
3878
|
-
} else {
|
|
3879
|
-
mountToTarget();
|
|
3880
|
-
}
|
|
3894
|
+
mountToTarget();
|
|
3881
3895
|
} else {
|
|
3882
|
-
|
|
3883
|
-
|
|
3884
|
-
|
|
3885
|
-
|
|
3886
|
-
|
|
3887
|
-
|
|
3888
|
-
|
|
3889
|
-
parentComponent,
|
|
3890
|
-
parentSuspense,
|
|
3891
|
-
namespace,
|
|
3892
|
-
slotScopeIds,
|
|
3893
|
-
optimized,
|
|
3894
|
-
internals
|
|
3895
|
-
);
|
|
3896
|
-
}, parentSuspense);
|
|
3896
|
+
n2.el = n1.el;
|
|
3897
|
+
const mainAnchor = n2.anchor = n1.anchor;
|
|
3898
|
+
const pendingMount = pendingMounts.get(n1);
|
|
3899
|
+
if (pendingMount) {
|
|
3900
|
+
pendingMount.flags |= 8;
|
|
3901
|
+
pendingMounts.delete(n1);
|
|
3902
|
+
queuePendingMount(n2);
|
|
3897
3903
|
return;
|
|
3898
3904
|
}
|
|
3899
|
-
n2.el = n1.el;
|
|
3900
3905
|
n2.targetStart = n1.targetStart;
|
|
3901
|
-
const mainAnchor = n2.anchor = n1.anchor;
|
|
3902
3906
|
const target = n2.target = n1.target;
|
|
3903
3907
|
const targetAnchor = n2.targetAnchor = n1.targetAnchor;
|
|
3904
3908
|
const wasDisabled = isTeleportDisabled(n1.props);
|
|
@@ -3991,13 +3995,19 @@ const TeleportImpl = {
|
|
|
3991
3995
|
target,
|
|
3992
3996
|
props
|
|
3993
3997
|
} = vnode;
|
|
3998
|
+
let shouldRemove = doRemove || !isTeleportDisabled(props);
|
|
3999
|
+
const pendingMount = pendingMounts.get(vnode);
|
|
4000
|
+
if (pendingMount) {
|
|
4001
|
+
pendingMount.flags |= 8;
|
|
4002
|
+
pendingMounts.delete(vnode);
|
|
4003
|
+
shouldRemove = false;
|
|
4004
|
+
}
|
|
3994
4005
|
if (target) {
|
|
3995
4006
|
hostRemove(targetStart);
|
|
3996
4007
|
hostRemove(targetAnchor);
|
|
3997
4008
|
}
|
|
3998
4009
|
doRemove && hostRemove(anchor);
|
|
3999
4010
|
if (shapeFlag & 16) {
|
|
4000
|
-
const shouldRemove = doRemove || !isTeleportDisabled(props);
|
|
4001
4011
|
for (let i = 0; i < children.length; i++) {
|
|
4002
4012
|
const child = children[i];
|
|
4003
4013
|
unmount(
|
|
@@ -4366,7 +4376,7 @@ function resolveTransitionHooks(vnode, props, state, instance, postClone) {
|
|
|
4366
4376
|
callHook(hook, [el]);
|
|
4367
4377
|
},
|
|
4368
4378
|
enter(el) {
|
|
4369
|
-
if (leavingVNodesCache[key] === vnode) return;
|
|
4379
|
+
if (!isHmrUpdating && leavingVNodesCache[key] === vnode) return;
|
|
4370
4380
|
let hook = onEnter;
|
|
4371
4381
|
let afterHook = onAfterEnter;
|
|
4372
4382
|
let cancelHook = onEnterCancelled;
|
|
@@ -7561,7 +7571,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7561
7571
|
return vm;
|
|
7562
7572
|
}
|
|
7563
7573
|
}
|
|
7564
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7574
|
+
Vue.version = `2.6.14-compat:${"3.5.32"}`;
|
|
7565
7575
|
Vue.config = singletonApp.config;
|
|
7566
7576
|
Vue.use = (plugin, ...options) => {
|
|
7567
7577
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -8720,11 +8730,12 @@ function hasPropValueChanged(nextProps, prevProps, key) {
|
|
|
8720
8730
|
}
|
|
8721
8731
|
return nextProp !== prevProp;
|
|
8722
8732
|
}
|
|
8723
|
-
function updateHOCHostEl({ vnode, parent }, el) {
|
|
8733
|
+
function updateHOCHostEl({ vnode, parent, suspense }, el) {
|
|
8724
8734
|
while (parent) {
|
|
8725
8735
|
const root = parent.subTree;
|
|
8726
8736
|
if (root.suspense && root.suspense.activeBranch === vnode) {
|
|
8727
|
-
root.el =
|
|
8737
|
+
root.suspense.vnode.el = root.el = el;
|
|
8738
|
+
vnode = root;
|
|
8728
8739
|
}
|
|
8729
8740
|
if (root === vnode) {
|
|
8730
8741
|
(vnode = parent.vnode).el = el;
|
|
@@ -8733,6 +8744,9 @@ function updateHOCHostEl({ vnode, parent }, el) {
|
|
|
8733
8744
|
break;
|
|
8734
8745
|
}
|
|
8735
8746
|
}
|
|
8747
|
+
if (suspense && suspense.activeBranch === vnode) {
|
|
8748
|
+
suspense.vnode.el = el;
|
|
8749
|
+
}
|
|
8736
8750
|
}
|
|
8737
8751
|
|
|
8738
8752
|
function createPropsDefaultThis(instance, rawProps, propKey) {
|
|
@@ -9646,10 +9660,17 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
9646
9660
|
}
|
|
9647
9661
|
hostInsert(el, container, anchor);
|
|
9648
9662
|
if ((vnodeHook = props && props.onVnodeMounted) || needCallTransitionHooks || dirs) {
|
|
9663
|
+
const isHmr = isHmrUpdating;
|
|
9649
9664
|
queuePostRenderEffect(() => {
|
|
9650
|
-
|
|
9651
|
-
|
|
9652
|
-
|
|
9665
|
+
let prev;
|
|
9666
|
+
prev = setHmrUpdating(isHmr);
|
|
9667
|
+
try {
|
|
9668
|
+
vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);
|
|
9669
|
+
needCallTransitionHooks && transition.enter(el);
|
|
9670
|
+
dirs && invokeDirectiveHook(vnode, null, parentComponent, "mounted");
|
|
9671
|
+
} finally {
|
|
9672
|
+
setHmrUpdating(prev);
|
|
9673
|
+
}
|
|
9653
9674
|
}, parentSuspense);
|
|
9654
9675
|
}
|
|
9655
9676
|
};
|
|
@@ -10595,7 +10616,8 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
10595
10616
|
shapeFlag,
|
|
10596
10617
|
patchFlag,
|
|
10597
10618
|
dirs,
|
|
10598
|
-
cacheIndex
|
|
10619
|
+
cacheIndex,
|
|
10620
|
+
memo
|
|
10599
10621
|
} = vnode;
|
|
10600
10622
|
if (patchFlag === -2) {
|
|
10601
10623
|
optimized = false;
|
|
@@ -10657,10 +10679,14 @@ function baseCreateRenderer(options, createHydrationFns) {
|
|
|
10657
10679
|
remove(vnode);
|
|
10658
10680
|
}
|
|
10659
10681
|
}
|
|
10660
|
-
|
|
10682
|
+
const shouldInvalidateMemo = memo != null && cacheIndex == null;
|
|
10683
|
+
if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeUnmounted) || shouldInvokeDirs || shouldInvalidateMemo) {
|
|
10661
10684
|
queuePostRenderEffect(() => {
|
|
10662
10685
|
vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);
|
|
10663
10686
|
shouldInvokeDirs && invokeDirectiveHook(vnode, null, parentComponent, "unmounted");
|
|
10687
|
+
if (shouldInvalidateMemo) {
|
|
10688
|
+
vnode.el = null;
|
|
10689
|
+
}
|
|
10664
10690
|
}, parentSuspense);
|
|
10665
10691
|
}
|
|
10666
10692
|
};
|
|
@@ -11223,6 +11249,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11223
11249
|
pendingId: suspenseId++,
|
|
11224
11250
|
timeout: typeof timeout === "number" ? timeout : -1,
|
|
11225
11251
|
activeBranch: null,
|
|
11252
|
+
isFallbackMountPending: false,
|
|
11226
11253
|
pendingBranch: null,
|
|
11227
11254
|
isInFallback: !isHydrating,
|
|
11228
11255
|
isHydrating,
|
|
@@ -11272,7 +11299,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11272
11299
|
}
|
|
11273
11300
|
};
|
|
11274
11301
|
}
|
|
11275
|
-
if (activeBranch) {
|
|
11302
|
+
if (activeBranch && !suspense.isFallbackMountPending) {
|
|
11276
11303
|
if (parentNode(activeBranch.el) === container2) {
|
|
11277
11304
|
anchor = next(activeBranch);
|
|
11278
11305
|
}
|
|
@@ -11285,6 +11312,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11285
11312
|
move(pendingBranch, container2, anchor, 0);
|
|
11286
11313
|
}
|
|
11287
11314
|
}
|
|
11315
|
+
suspense.isFallbackMountPending = false;
|
|
11288
11316
|
setActiveBranch(suspense, pendingBranch);
|
|
11289
11317
|
suspense.pendingBranch = null;
|
|
11290
11318
|
suspense.isInFallback = false;
|
|
@@ -11320,6 +11348,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11320
11348
|
triggerEvent(vnode2, "onFallback");
|
|
11321
11349
|
const anchor2 = next(activeBranch);
|
|
11322
11350
|
const mountFallback = () => {
|
|
11351
|
+
suspense.isFallbackMountPending = false;
|
|
11323
11352
|
if (!suspense.isInFallback) {
|
|
11324
11353
|
return;
|
|
11325
11354
|
}
|
|
@@ -11339,6 +11368,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11339
11368
|
};
|
|
11340
11369
|
const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === "out-in";
|
|
11341
11370
|
if (delayEnter) {
|
|
11371
|
+
suspense.isFallbackMountPending = true;
|
|
11342
11372
|
activeBranch.transition.afterLeave = mountFallback;
|
|
11343
11373
|
}
|
|
11344
11374
|
suspense.isInFallback = true;
|
|
@@ -11373,6 +11403,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11373
11403
|
if (instance.isUnmounted || suspense.isUnmounted || suspense.pendingId !== instance.suspenseId) {
|
|
11374
11404
|
return;
|
|
11375
11405
|
}
|
|
11406
|
+
unsetCurrentInstance();
|
|
11376
11407
|
instance.asyncResolved = true;
|
|
11377
11408
|
const { vnode: vnode2 } = instance;
|
|
11378
11409
|
{
|
|
@@ -11956,6 +11987,10 @@ function mergeProps(...args) {
|
|
|
11956
11987
|
const incoming = toMerge[key];
|
|
11957
11988
|
if (incoming && existing !== incoming && !(isArray(existing) && existing.includes(incoming))) {
|
|
11958
11989
|
ret[key] = existing ? [].concat(existing, incoming) : incoming;
|
|
11990
|
+
} else if (incoming == null && existing == null && // mergeProps({ 'onUpdate:modelValue': undefined }) should not retain
|
|
11991
|
+
// the model listener.
|
|
11992
|
+
!isModelListener(key)) {
|
|
11993
|
+
ret[key] = incoming;
|
|
11959
11994
|
}
|
|
11960
11995
|
} else if (key !== "") {
|
|
11961
11996
|
ret[key] = toMerge[key];
|
|
@@ -12652,7 +12687,7 @@ function isMemoSame(cached, memo) {
|
|
|
12652
12687
|
return true;
|
|
12653
12688
|
}
|
|
12654
12689
|
|
|
12655
|
-
const version = "3.5.
|
|
12690
|
+
const version = "3.5.32";
|
|
12656
12691
|
const warn = warn$1 ;
|
|
12657
12692
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12658
12693
|
const devtools = devtools$1 ;
|
|
@@ -14272,7 +14307,8 @@ const vModelText = {
|
|
|
14272
14307
|
if (elValue === newValue) {
|
|
14273
14308
|
return;
|
|
14274
14309
|
}
|
|
14275
|
-
|
|
14310
|
+
const rootNode = el.getRootNode();
|
|
14311
|
+
if ((rootNode instanceof Document || rootNode instanceof ShadowRoot) && rootNode.activeElement === el && el.type !== "range") {
|
|
14276
14312
|
if (lazy && value === oldValue) {
|
|
14277
14313
|
return;
|
|
14278
14314
|
}
|
|
@@ -19604,7 +19640,7 @@ const transformFor = createStructuralDirectiveTransform(
|
|
|
19604
19640
|
loop.body = createBlockStatement([
|
|
19605
19641
|
createCompoundExpression([`const _memo = (`, memo.exp, `)`]),
|
|
19606
19642
|
createCompoundExpression([
|
|
19607
|
-
`if (_cached`,
|
|
19643
|
+
`if (_cached && _cached.el`,
|
|
19608
19644
|
...keyExp ? [` && _cached.key === `, keyExp] : [],
|
|
19609
19645
|
` && ${context.helperString(
|
|
19610
19646
|
IS_MEMO_SAME
|