@vue/compat 3.5.41 → 3.5.42
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 +107 -21
- package/dist/vue.cjs.prod.js +77 -20
- package/dist/vue.esm-browser.js +107 -21
- package/dist/vue.esm-browser.prod.js +9 -9
- package/dist/vue.esm-bundler.js +107 -21
- package/dist/vue.global.js +107 -21
- package/dist/vue.global.prod.js +9 -9
- package/dist/vue.runtime.esm-browser.js +107 -21
- package/dist/vue.runtime.esm-browser.prod.js +4 -4
- package/dist/vue.runtime.esm-bundler.js +107 -21
- package/dist/vue.runtime.global.js +107 -21
- package/dist/vue.runtime.global.prod.js +4 -4
- package/package.json +2 -2
package/dist/vue.cjs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.42
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -355,6 +355,23 @@ function looseCompareArrays(a, b) {
|
|
|
355
355
|
}
|
|
356
356
|
return equal;
|
|
357
357
|
}
|
|
358
|
+
function looseCompareCollections(a, b) {
|
|
359
|
+
if (a.size !== b.size) return false;
|
|
360
|
+
const candidates = Array.from(b);
|
|
361
|
+
const matched = new Uint8Array(candidates.length);
|
|
362
|
+
for (const item of a) {
|
|
363
|
+
let index = -1;
|
|
364
|
+
for (let i = 0; i < candidates.length; i++) {
|
|
365
|
+
if (!matched[i] && looseEqual(item, candidates[i])) {
|
|
366
|
+
index = i;
|
|
367
|
+
break;
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
if (index < 0) return false;
|
|
371
|
+
matched[index] = 1;
|
|
372
|
+
}
|
|
373
|
+
return true;
|
|
374
|
+
}
|
|
358
375
|
function looseEqual(a, b) {
|
|
359
376
|
if (a === b) return true;
|
|
360
377
|
let aValidType = isDate(a);
|
|
@@ -378,6 +395,16 @@ function looseEqual(a, b) {
|
|
|
378
395
|
if (!aValidType || !bValidType) {
|
|
379
396
|
return false;
|
|
380
397
|
}
|
|
398
|
+
aValidType = isMap(a);
|
|
399
|
+
bValidType = isMap(b);
|
|
400
|
+
if (aValidType || bValidType) {
|
|
401
|
+
return aValidType && bValidType ? looseCompareCollections(a, b) : false;
|
|
402
|
+
}
|
|
403
|
+
aValidType = isSet(a);
|
|
404
|
+
bValidType = isSet(b);
|
|
405
|
+
if (aValidType || bValidType) {
|
|
406
|
+
return aValidType && bValidType ? looseCompareCollections(a, b) : false;
|
|
407
|
+
}
|
|
381
408
|
const aKeysCount = Object.keys(a).length;
|
|
382
409
|
const bKeysCount = Object.keys(b).length;
|
|
383
410
|
if (aKeysCount !== bKeysCount) {
|
|
@@ -4931,10 +4958,10 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
4931
4958
|
getContainerType(container),
|
|
4932
4959
|
optimized
|
|
4933
4960
|
);
|
|
4934
|
-
if (isAsyncWrapper(vnode) && !vnode.
|
|
4961
|
+
if (isAsyncWrapper(vnode) && !vnode.component.subTree) {
|
|
4935
4962
|
let subTree;
|
|
4936
4963
|
if (isFragmentStart) {
|
|
4937
|
-
subTree = createVNode(
|
|
4964
|
+
subTree = createVNode(Static);
|
|
4938
4965
|
subTree.anchor = nextNode ? nextNode.previousSibling : container.lastChild;
|
|
4939
4966
|
} else {
|
|
4940
4967
|
subTree = node.nodeType === 3 ? createTextVNode("") : createVNode("div");
|
|
@@ -5840,7 +5867,10 @@ const KeepAliveImpl = {
|
|
|
5840
5867
|
if (pendingCacheKey != null) {
|
|
5841
5868
|
if (isSuspense(instance.subTree.type)) {
|
|
5842
5869
|
queuePostRenderEffect(() => {
|
|
5843
|
-
|
|
5870
|
+
const vnode = getInnerChild(instance.subTree);
|
|
5871
|
+
if (vnode.component) {
|
|
5872
|
+
cache.set(pendingCacheKey, vnode);
|
|
5873
|
+
}
|
|
5844
5874
|
}, instance.subTree.suspense);
|
|
5845
5875
|
} else {
|
|
5846
5876
|
cache.set(pendingCacheKey, getInnerChild(instance.subTree));
|
|
@@ -6761,12 +6791,41 @@ const getPublicInstance = (i) => {
|
|
|
6761
6791
|
if (isStatefulComponent(i)) return getComponentPublicInstance(i);
|
|
6762
6792
|
return getPublicInstance(i.parent);
|
|
6763
6793
|
};
|
|
6794
|
+
const resolveDevRootEl = (vnode) => {
|
|
6795
|
+
let found = false;
|
|
6796
|
+
while (true) {
|
|
6797
|
+
if (vnode.patchFlag > 0 && vnode.patchFlag & 2048) {
|
|
6798
|
+
const root = filterSingleRoot(vnode.children);
|
|
6799
|
+
if (!root) {
|
|
6800
|
+
return;
|
|
6801
|
+
}
|
|
6802
|
+
vnode = root;
|
|
6803
|
+
found = true;
|
|
6804
|
+
continue;
|
|
6805
|
+
}
|
|
6806
|
+
const component = vnode.component;
|
|
6807
|
+
if (component && component.subTree) {
|
|
6808
|
+
vnode = component.subTree;
|
|
6809
|
+
continue;
|
|
6810
|
+
}
|
|
6811
|
+
const suspense = vnode.suspense;
|
|
6812
|
+
if (suspense && suspense.activeBranch) {
|
|
6813
|
+
vnode = suspense.activeBranch;
|
|
6814
|
+
continue;
|
|
6815
|
+
}
|
|
6816
|
+
return found ? vnode.el : void 0;
|
|
6817
|
+
}
|
|
6818
|
+
};
|
|
6819
|
+
const getDevRootFragmentEl = (i) => {
|
|
6820
|
+
const el = i.subTree && resolveDevRootEl(i.subTree);
|
|
6821
|
+
return el === void 0 ? i.vnode.el : el;
|
|
6822
|
+
};
|
|
6764
6823
|
const publicPropertiesMap = (
|
|
6765
6824
|
// Move PURE marker to new line to workaround compiler discarding it
|
|
6766
6825
|
// due to type annotation
|
|
6767
6826
|
/* @__PURE__ */ extend(/* @__PURE__ */ Object.create(null), {
|
|
6768
6827
|
$: (i) => i,
|
|
6769
|
-
$el: (i) => i
|
|
6828
|
+
$el: (i) => getDevRootFragmentEl(i) ,
|
|
6770
6829
|
$data: (i) => i.data,
|
|
6771
6830
|
$props: (i) => shallowReadonly(i.props) ,
|
|
6772
6831
|
$attrs: (i) => shallowReadonly(i.attrs) ,
|
|
@@ -7680,7 +7739,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7680
7739
|
return vm;
|
|
7681
7740
|
}
|
|
7682
7741
|
}
|
|
7683
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7742
|
+
Vue.version = `2.6.14-compat:${"3.5.42"}`;
|
|
7684
7743
|
Vue.config = singletonApp.config;
|
|
7685
7744
|
Vue.use = (plugin, ...options) => {
|
|
7686
7745
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -8437,7 +8496,7 @@ function emit(instance, event, ...rawArgs) {
|
|
|
8437
8496
|
args = rawArgs.map((a) => isString(a) ? a.trim() : a);
|
|
8438
8497
|
}
|
|
8439
8498
|
if (modifiers.number) {
|
|
8440
|
-
args =
|
|
8499
|
+
args = args.map(looseToNumber);
|
|
8441
8500
|
}
|
|
8442
8501
|
}
|
|
8443
8502
|
{
|
|
@@ -11214,7 +11273,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, sl
|
|
|
11214
11273
|
if (suspense.deps <= 0) {
|
|
11215
11274
|
suspense.resolve();
|
|
11216
11275
|
} else if (isInFallback) {
|
|
11217
|
-
if (!isHydrating) {
|
|
11276
|
+
if (!isHydrating && !suspense.isFallbackMountPending) {
|
|
11218
11277
|
patch(
|
|
11219
11278
|
activeBranch,
|
|
11220
11279
|
newFallback,
|
|
@@ -11255,7 +11314,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, sl
|
|
|
11255
11314
|
);
|
|
11256
11315
|
if (suspense.deps <= 0) {
|
|
11257
11316
|
suspense.resolve();
|
|
11258
|
-
} else {
|
|
11317
|
+
} else if (!suspense.isFallbackMountPending) {
|
|
11259
11318
|
patch(
|
|
11260
11319
|
activeBranch,
|
|
11261
11320
|
newFallback,
|
|
@@ -11496,9 +11555,10 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11496
11555
|
if (!suspense.isInFallback) {
|
|
11497
11556
|
return;
|
|
11498
11557
|
}
|
|
11558
|
+
const latestFallback = suspense.vnode.ssFallback;
|
|
11499
11559
|
patch(
|
|
11500
11560
|
null,
|
|
11501
|
-
|
|
11561
|
+
latestFallback,
|
|
11502
11562
|
container2,
|
|
11503
11563
|
anchor2,
|
|
11504
11564
|
parentComponent2,
|
|
@@ -11508,7 +11568,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11508
11568
|
slotScopeIds,
|
|
11509
11569
|
optimized
|
|
11510
11570
|
);
|
|
11511
|
-
setActiveBranch(suspense,
|
|
11571
|
+
setActiveBranch(suspense, latestFallback);
|
|
11512
11572
|
};
|
|
11513
11573
|
const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === "out-in";
|
|
11514
11574
|
if (delayEnter) {
|
|
@@ -12853,7 +12913,7 @@ function isMemoSame(cached, memo) {
|
|
|
12853
12913
|
return true;
|
|
12854
12914
|
}
|
|
12855
12915
|
|
|
12856
|
-
const version = "3.5.
|
|
12916
|
+
const version = "3.5.42";
|
|
12857
12917
|
const warn = warn$1 ;
|
|
12858
12918
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12859
12919
|
const devtools = devtools$1 ;
|
|
@@ -13426,7 +13486,11 @@ function setStyle(style, name, val) {
|
|
|
13426
13486
|
}
|
|
13427
13487
|
}
|
|
13428
13488
|
if (name.startsWith("--")) {
|
|
13429
|
-
|
|
13489
|
+
if (importantRE.test(val)) {
|
|
13490
|
+
style.setProperty(name, val.replace(importantRE, ""), "important");
|
|
13491
|
+
} else {
|
|
13492
|
+
style.setProperty(name, val);
|
|
13493
|
+
}
|
|
13430
13494
|
} else {
|
|
13431
13495
|
const prefixed = autoPrefix(style, name);
|
|
13432
13496
|
if (importantRE.test(val)) {
|
|
@@ -14613,13 +14677,21 @@ const vModelSelect = {
|
|
|
14613
14677
|
const selectedVal = Array.prototype.filter.call(el.options, (o) => o.selected).map(
|
|
14614
14678
|
(o) => number ? looseToNumber(getValue(o)) : getValue(o)
|
|
14615
14679
|
);
|
|
14616
|
-
el
|
|
14617
|
-
|
|
14618
|
-
|
|
14619
|
-
|
|
14620
|
-
|
|
14621
|
-
|
|
14622
|
-
|
|
14680
|
+
const multiple = el.multiple;
|
|
14681
|
+
const assignedValue = multiple ? isSet(el._modelValue) ? new Set(selectedVal) : selectedVal : selectedVal[0];
|
|
14682
|
+
const pending = el._pendingValue = [
|
|
14683
|
+
multiple,
|
|
14684
|
+
multiple ? isArray(assignedValue) ? selectedVal.slice() : selectedVal : assignedValue
|
|
14685
|
+
];
|
|
14686
|
+
try {
|
|
14687
|
+
el[assignKey](assignedValue);
|
|
14688
|
+
} finally {
|
|
14689
|
+
nextTick(() => {
|
|
14690
|
+
if (el._pendingValue === pending) {
|
|
14691
|
+
el._pendingValue = void 0;
|
|
14692
|
+
}
|
|
14693
|
+
});
|
|
14694
|
+
}
|
|
14623
14695
|
});
|
|
14624
14696
|
el[assignKey] = getModelAssigner(vnode);
|
|
14625
14697
|
},
|
|
@@ -14633,11 +14705,25 @@ const vModelSelect = {
|
|
|
14633
14705
|
el[assignKey] = getModelAssigner(vnode);
|
|
14634
14706
|
},
|
|
14635
14707
|
updated(el, { value }) {
|
|
14636
|
-
|
|
14708
|
+
const pending = el._pendingValue;
|
|
14709
|
+
el._pendingValue = void 0;
|
|
14710
|
+
if (!pending || pending[0] !== el.multiple || !isSameSelectValue(value, pending[1], pending[0])) {
|
|
14637
14711
|
setSelected(el, value);
|
|
14638
14712
|
}
|
|
14639
14713
|
}
|
|
14640
14714
|
};
|
|
14715
|
+
function isSameSelectValue(value, assignedValue, multiple) {
|
|
14716
|
+
if (!multiple) return looseEqual(value, assignedValue);
|
|
14717
|
+
if (isArray(value)) return looseEqual(value, assignedValue);
|
|
14718
|
+
if (isSet(value)) {
|
|
14719
|
+
if (value.size !== assignedValue.length) return false;
|
|
14720
|
+
for (const item of assignedValue) {
|
|
14721
|
+
if (!value.has(item)) return false;
|
|
14722
|
+
}
|
|
14723
|
+
return true;
|
|
14724
|
+
}
|
|
14725
|
+
return false;
|
|
14726
|
+
}
|
|
14641
14727
|
function setSelected(el, value) {
|
|
14642
14728
|
const isMultiple = el.multiple;
|
|
14643
14729
|
const isArrayValue = isArray(value);
|
package/dist/vue.cjs.prod.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.42
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -276,6 +276,23 @@ function looseCompareArrays(a, b) {
|
|
|
276
276
|
}
|
|
277
277
|
return equal;
|
|
278
278
|
}
|
|
279
|
+
function looseCompareCollections(a, b) {
|
|
280
|
+
if (a.size !== b.size) return false;
|
|
281
|
+
const candidates = Array.from(b);
|
|
282
|
+
const matched = new Uint8Array(candidates.length);
|
|
283
|
+
for (const item of a) {
|
|
284
|
+
let index = -1;
|
|
285
|
+
for (let i = 0; i < candidates.length; i++) {
|
|
286
|
+
if (!matched[i] && looseEqual(item, candidates[i])) {
|
|
287
|
+
index = i;
|
|
288
|
+
break;
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
if (index < 0) return false;
|
|
292
|
+
matched[index] = 1;
|
|
293
|
+
}
|
|
294
|
+
return true;
|
|
295
|
+
}
|
|
279
296
|
function looseEqual(a, b) {
|
|
280
297
|
if (a === b) return true;
|
|
281
298
|
let aValidType = isDate(a);
|
|
@@ -299,6 +316,16 @@ function looseEqual(a, b) {
|
|
|
299
316
|
if (!aValidType || !bValidType) {
|
|
300
317
|
return false;
|
|
301
318
|
}
|
|
319
|
+
aValidType = isMap(a);
|
|
320
|
+
bValidType = isMap(b);
|
|
321
|
+
if (aValidType || bValidType) {
|
|
322
|
+
return aValidType && bValidType ? looseCompareCollections(a, b) : false;
|
|
323
|
+
}
|
|
324
|
+
aValidType = isSet(a);
|
|
325
|
+
bValidType = isSet(b);
|
|
326
|
+
if (aValidType || bValidType) {
|
|
327
|
+
return aValidType && bValidType ? looseCompareCollections(a, b) : false;
|
|
328
|
+
}
|
|
302
329
|
const aKeysCount = Object.keys(a).length;
|
|
303
330
|
const bKeysCount = Object.keys(b).length;
|
|
304
331
|
if (aKeysCount !== bKeysCount) {
|
|
@@ -3900,10 +3927,10 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
3900
3927
|
getContainerType(container),
|
|
3901
3928
|
optimized
|
|
3902
3929
|
);
|
|
3903
|
-
if (isAsyncWrapper(vnode) && !vnode.
|
|
3930
|
+
if (isAsyncWrapper(vnode) && !vnode.component.subTree) {
|
|
3904
3931
|
let subTree;
|
|
3905
3932
|
if (isFragmentStart) {
|
|
3906
|
-
subTree = createVNode(
|
|
3933
|
+
subTree = createVNode(Static);
|
|
3907
3934
|
subTree.anchor = nextNode ? nextNode.previousSibling : container.lastChild;
|
|
3908
3935
|
} else {
|
|
3909
3936
|
subTree = node.nodeType === 3 ? createTextVNode("") : createVNode("div");
|
|
@@ -4629,7 +4656,10 @@ const KeepAliveImpl = {
|
|
|
4629
4656
|
if (pendingCacheKey != null) {
|
|
4630
4657
|
if (isSuspense(instance.subTree.type)) {
|
|
4631
4658
|
queuePostRenderEffect(() => {
|
|
4632
|
-
|
|
4659
|
+
const vnode = getInnerChild(instance.subTree);
|
|
4660
|
+
if (vnode.component) {
|
|
4661
|
+
cache.set(pendingCacheKey, vnode);
|
|
4662
|
+
}
|
|
4633
4663
|
}, instance.subTree.suspense);
|
|
4634
4664
|
} else {
|
|
4635
4665
|
cache.set(pendingCacheKey, getInnerChild(instance.subTree));
|
|
@@ -6188,7 +6218,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
6188
6218
|
return vm;
|
|
6189
6219
|
}
|
|
6190
6220
|
}
|
|
6191
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
6221
|
+
Vue.version = `2.6.14-compat:${"3.5.42"}`;
|
|
6192
6222
|
Vue.config = singletonApp.config;
|
|
6193
6223
|
Vue.use = (plugin, ...options) => {
|
|
6194
6224
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -6785,7 +6815,7 @@ function emit(instance, event, ...rawArgs) {
|
|
|
6785
6815
|
args = rawArgs.map((a) => isString(a) ? a.trim() : a);
|
|
6786
6816
|
}
|
|
6787
6817
|
if (modifiers.number) {
|
|
6788
|
-
args =
|
|
6818
|
+
args = args.map(looseToNumber);
|
|
6789
6819
|
}
|
|
6790
6820
|
}
|
|
6791
6821
|
let handlerName;
|
|
@@ -9127,7 +9157,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, sl
|
|
|
9127
9157
|
if (suspense.deps <= 0) {
|
|
9128
9158
|
suspense.resolve();
|
|
9129
9159
|
} else if (isInFallback) {
|
|
9130
|
-
if (!isHydrating) {
|
|
9160
|
+
if (!isHydrating && !suspense.isFallbackMountPending) {
|
|
9131
9161
|
patch(
|
|
9132
9162
|
activeBranch,
|
|
9133
9163
|
newFallback,
|
|
@@ -9168,7 +9198,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, sl
|
|
|
9168
9198
|
);
|
|
9169
9199
|
if (suspense.deps <= 0) {
|
|
9170
9200
|
suspense.resolve();
|
|
9171
|
-
} else {
|
|
9201
|
+
} else if (!suspense.isFallbackMountPending) {
|
|
9172
9202
|
patch(
|
|
9173
9203
|
activeBranch,
|
|
9174
9204
|
newFallback,
|
|
@@ -9387,9 +9417,10 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
9387
9417
|
if (!suspense.isInFallback) {
|
|
9388
9418
|
return;
|
|
9389
9419
|
}
|
|
9420
|
+
const latestFallback = suspense.vnode.ssFallback;
|
|
9390
9421
|
patch(
|
|
9391
9422
|
null,
|
|
9392
|
-
|
|
9423
|
+
latestFallback,
|
|
9393
9424
|
container2,
|
|
9394
9425
|
anchor2,
|
|
9395
9426
|
parentComponent2,
|
|
@@ -9399,7 +9430,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
9399
9430
|
slotScopeIds,
|
|
9400
9431
|
optimized
|
|
9401
9432
|
);
|
|
9402
|
-
setActiveBranch(suspense,
|
|
9433
|
+
setActiveBranch(suspense, latestFallback);
|
|
9403
9434
|
};
|
|
9404
9435
|
const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === "out-in";
|
|
9405
9436
|
if (delayEnter) {
|
|
@@ -10364,7 +10395,7 @@ function isMemoSame(cached, memo) {
|
|
|
10364
10395
|
return true;
|
|
10365
10396
|
}
|
|
10366
10397
|
|
|
10367
|
-
const version = "3.5.
|
|
10398
|
+
const version = "3.5.42";
|
|
10368
10399
|
const warn$1 = NOOP;
|
|
10369
10400
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
10370
10401
|
const devtools = void 0;
|
|
@@ -10925,7 +10956,11 @@ function setStyle(style, name, val) {
|
|
|
10925
10956
|
} else {
|
|
10926
10957
|
if (val == null) val = "";
|
|
10927
10958
|
if (name.startsWith("--")) {
|
|
10928
|
-
|
|
10959
|
+
if (importantRE.test(val)) {
|
|
10960
|
+
style.setProperty(name, val.replace(importantRE, ""), "important");
|
|
10961
|
+
} else {
|
|
10962
|
+
style.setProperty(name, val);
|
|
10963
|
+
}
|
|
10929
10964
|
} else {
|
|
10930
10965
|
const prefixed = autoPrefix(style, name);
|
|
10931
10966
|
if (importantRE.test(val)) {
|
|
@@ -12020,13 +12055,21 @@ const vModelSelect = {
|
|
|
12020
12055
|
const selectedVal = Array.prototype.filter.call(el.options, (o) => o.selected).map(
|
|
12021
12056
|
(o) => number ? looseToNumber(getValue(o)) : getValue(o)
|
|
12022
12057
|
);
|
|
12023
|
-
el
|
|
12024
|
-
|
|
12025
|
-
|
|
12026
|
-
|
|
12027
|
-
|
|
12028
|
-
|
|
12029
|
-
|
|
12058
|
+
const multiple = el.multiple;
|
|
12059
|
+
const assignedValue = multiple ? isSet(el._modelValue) ? new Set(selectedVal) : selectedVal : selectedVal[0];
|
|
12060
|
+
const pending = el._pendingValue = [
|
|
12061
|
+
multiple,
|
|
12062
|
+
multiple ? isArray(assignedValue) ? selectedVal.slice() : selectedVal : assignedValue
|
|
12063
|
+
];
|
|
12064
|
+
try {
|
|
12065
|
+
el[assignKey](assignedValue);
|
|
12066
|
+
} finally {
|
|
12067
|
+
nextTick(() => {
|
|
12068
|
+
if (el._pendingValue === pending) {
|
|
12069
|
+
el._pendingValue = void 0;
|
|
12070
|
+
}
|
|
12071
|
+
});
|
|
12072
|
+
}
|
|
12030
12073
|
});
|
|
12031
12074
|
el[assignKey] = getModelAssigner(vnode);
|
|
12032
12075
|
},
|
|
@@ -12040,11 +12083,25 @@ const vModelSelect = {
|
|
|
12040
12083
|
el[assignKey] = getModelAssigner(vnode);
|
|
12041
12084
|
},
|
|
12042
12085
|
updated(el, { value }) {
|
|
12043
|
-
|
|
12086
|
+
const pending = el._pendingValue;
|
|
12087
|
+
el._pendingValue = void 0;
|
|
12088
|
+
if (!pending || pending[0] !== el.multiple || !isSameSelectValue(value, pending[1], pending[0])) {
|
|
12044
12089
|
setSelected(el, value);
|
|
12045
12090
|
}
|
|
12046
12091
|
}
|
|
12047
12092
|
};
|
|
12093
|
+
function isSameSelectValue(value, assignedValue, multiple) {
|
|
12094
|
+
if (!multiple) return looseEqual(value, assignedValue);
|
|
12095
|
+
if (isArray(value)) return looseEqual(value, assignedValue);
|
|
12096
|
+
if (isSet(value)) {
|
|
12097
|
+
if (value.size !== assignedValue.length) return false;
|
|
12098
|
+
for (const item of assignedValue) {
|
|
12099
|
+
if (!value.has(item)) return false;
|
|
12100
|
+
}
|
|
12101
|
+
return true;
|
|
12102
|
+
}
|
|
12103
|
+
return false;
|
|
12104
|
+
}
|
|
12048
12105
|
function setSelected(el, value) {
|
|
12049
12106
|
const isMultiple = el.multiple;
|
|
12050
12107
|
const isArrayValue = isArray(value);
|
package/dist/vue.esm-browser.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.42
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -302,6 +302,23 @@ function looseCompareArrays(a, b) {
|
|
|
302
302
|
}
|
|
303
303
|
return equal;
|
|
304
304
|
}
|
|
305
|
+
function looseCompareCollections(a, b) {
|
|
306
|
+
if (a.size !== b.size) return false;
|
|
307
|
+
const candidates = Array.from(b);
|
|
308
|
+
const matched = new Uint8Array(candidates.length);
|
|
309
|
+
for (const item of a) {
|
|
310
|
+
let index = -1;
|
|
311
|
+
for (let i = 0; i < candidates.length; i++) {
|
|
312
|
+
if (!matched[i] && looseEqual(item, candidates[i])) {
|
|
313
|
+
index = i;
|
|
314
|
+
break;
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
if (index < 0) return false;
|
|
318
|
+
matched[index] = 1;
|
|
319
|
+
}
|
|
320
|
+
return true;
|
|
321
|
+
}
|
|
305
322
|
function looseEqual(a, b) {
|
|
306
323
|
if (a === b) return true;
|
|
307
324
|
let aValidType = isDate(a);
|
|
@@ -325,6 +342,16 @@ function looseEqual(a, b) {
|
|
|
325
342
|
if (!aValidType || !bValidType) {
|
|
326
343
|
return false;
|
|
327
344
|
}
|
|
345
|
+
aValidType = isMap(a);
|
|
346
|
+
bValidType = isMap(b);
|
|
347
|
+
if (aValidType || bValidType) {
|
|
348
|
+
return aValidType && bValidType ? looseCompareCollections(a, b) : false;
|
|
349
|
+
}
|
|
350
|
+
aValidType = isSet(a);
|
|
351
|
+
bValidType = isSet(b);
|
|
352
|
+
if (aValidType || bValidType) {
|
|
353
|
+
return aValidType && bValidType ? looseCompareCollections(a, b) : false;
|
|
354
|
+
}
|
|
328
355
|
const aKeysCount = Object.keys(a).length;
|
|
329
356
|
const bKeysCount = Object.keys(b).length;
|
|
330
357
|
if (aKeysCount !== bKeysCount) {
|
|
@@ -4878,10 +4905,10 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
4878
4905
|
getContainerType(container),
|
|
4879
4906
|
optimized
|
|
4880
4907
|
);
|
|
4881
|
-
if (isAsyncWrapper(vnode) && !vnode.
|
|
4908
|
+
if (isAsyncWrapper(vnode) && !vnode.component.subTree) {
|
|
4882
4909
|
let subTree;
|
|
4883
4910
|
if (isFragmentStart) {
|
|
4884
|
-
subTree = createVNode(
|
|
4911
|
+
subTree = createVNode(Static);
|
|
4885
4912
|
subTree.anchor = nextNode ? nextNode.previousSibling : container.lastChild;
|
|
4886
4913
|
} else {
|
|
4887
4914
|
subTree = node.nodeType === 3 ? createTextVNode("") : createVNode("div");
|
|
@@ -5790,7 +5817,10 @@ const KeepAliveImpl = {
|
|
|
5790
5817
|
if (pendingCacheKey != null) {
|
|
5791
5818
|
if (isSuspense(instance.subTree.type)) {
|
|
5792
5819
|
queuePostRenderEffect(() => {
|
|
5793
|
-
|
|
5820
|
+
const vnode = getInnerChild(instance.subTree);
|
|
5821
|
+
if (vnode.component) {
|
|
5822
|
+
cache.set(pendingCacheKey, vnode);
|
|
5823
|
+
}
|
|
5794
5824
|
}, instance.subTree.suspense);
|
|
5795
5825
|
} else {
|
|
5796
5826
|
cache.set(pendingCacheKey, getInnerChild(instance.subTree));
|
|
@@ -6711,12 +6741,41 @@ const getPublicInstance = (i) => {
|
|
|
6711
6741
|
if (isStatefulComponent(i)) return getComponentPublicInstance(i);
|
|
6712
6742
|
return getPublicInstance(i.parent);
|
|
6713
6743
|
};
|
|
6744
|
+
const resolveDevRootEl = (vnode) => {
|
|
6745
|
+
let found = false;
|
|
6746
|
+
while (true) {
|
|
6747
|
+
if (vnode.patchFlag > 0 && vnode.patchFlag & 2048) {
|
|
6748
|
+
const root = filterSingleRoot(vnode.children);
|
|
6749
|
+
if (!root) {
|
|
6750
|
+
return;
|
|
6751
|
+
}
|
|
6752
|
+
vnode = root;
|
|
6753
|
+
found = true;
|
|
6754
|
+
continue;
|
|
6755
|
+
}
|
|
6756
|
+
const component = vnode.component;
|
|
6757
|
+
if (component && component.subTree) {
|
|
6758
|
+
vnode = component.subTree;
|
|
6759
|
+
continue;
|
|
6760
|
+
}
|
|
6761
|
+
const suspense = vnode.suspense;
|
|
6762
|
+
if (suspense && suspense.activeBranch) {
|
|
6763
|
+
vnode = suspense.activeBranch;
|
|
6764
|
+
continue;
|
|
6765
|
+
}
|
|
6766
|
+
return found ? vnode.el : void 0;
|
|
6767
|
+
}
|
|
6768
|
+
};
|
|
6769
|
+
const getDevRootFragmentEl = (i) => {
|
|
6770
|
+
const el = i.subTree && resolveDevRootEl(i.subTree);
|
|
6771
|
+
return el === void 0 ? i.vnode.el : el;
|
|
6772
|
+
};
|
|
6714
6773
|
const publicPropertiesMap = (
|
|
6715
6774
|
// Move PURE marker to new line to workaround compiler discarding it
|
|
6716
6775
|
// due to type annotation
|
|
6717
6776
|
/* @__PURE__ */ extend(/* @__PURE__ */ Object.create(null), {
|
|
6718
6777
|
$: (i) => i,
|
|
6719
|
-
$el: (i) => i
|
|
6778
|
+
$el: (i) => getDevRootFragmentEl(i) ,
|
|
6720
6779
|
$data: (i) => i.data,
|
|
6721
6780
|
$props: (i) => shallowReadonly(i.props) ,
|
|
6722
6781
|
$attrs: (i) => shallowReadonly(i.attrs) ,
|
|
@@ -7630,7 +7689,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7630
7689
|
return vm;
|
|
7631
7690
|
}
|
|
7632
7691
|
}
|
|
7633
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7692
|
+
Vue.version = `2.6.14-compat:${"3.5.42"}`;
|
|
7634
7693
|
Vue.config = singletonApp.config;
|
|
7635
7694
|
Vue.use = (plugin, ...options) => {
|
|
7636
7695
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -8387,7 +8446,7 @@ function emit(instance, event, ...rawArgs) {
|
|
|
8387
8446
|
args = rawArgs.map((a) => isString(a) ? a.trim() : a);
|
|
8388
8447
|
}
|
|
8389
8448
|
if (modifiers.number) {
|
|
8390
|
-
args =
|
|
8449
|
+
args = args.map(looseToNumber);
|
|
8391
8450
|
}
|
|
8392
8451
|
}
|
|
8393
8452
|
{
|
|
@@ -11164,7 +11223,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, sl
|
|
|
11164
11223
|
if (suspense.deps <= 0) {
|
|
11165
11224
|
suspense.resolve();
|
|
11166
11225
|
} else if (isInFallback) {
|
|
11167
|
-
if (!isHydrating) {
|
|
11226
|
+
if (!isHydrating && !suspense.isFallbackMountPending) {
|
|
11168
11227
|
patch(
|
|
11169
11228
|
activeBranch,
|
|
11170
11229
|
newFallback,
|
|
@@ -11205,7 +11264,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, sl
|
|
|
11205
11264
|
);
|
|
11206
11265
|
if (suspense.deps <= 0) {
|
|
11207
11266
|
suspense.resolve();
|
|
11208
|
-
} else {
|
|
11267
|
+
} else if (!suspense.isFallbackMountPending) {
|
|
11209
11268
|
patch(
|
|
11210
11269
|
activeBranch,
|
|
11211
11270
|
newFallback,
|
|
@@ -11446,9 +11505,10 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11446
11505
|
if (!suspense.isInFallback) {
|
|
11447
11506
|
return;
|
|
11448
11507
|
}
|
|
11508
|
+
const latestFallback = suspense.vnode.ssFallback;
|
|
11449
11509
|
patch(
|
|
11450
11510
|
null,
|
|
11451
|
-
|
|
11511
|
+
latestFallback,
|
|
11452
11512
|
container2,
|
|
11453
11513
|
anchor2,
|
|
11454
11514
|
parentComponent2,
|
|
@@ -11458,7 +11518,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
|
|
|
11458
11518
|
slotScopeIds,
|
|
11459
11519
|
optimized
|
|
11460
11520
|
);
|
|
11461
|
-
setActiveBranch(suspense,
|
|
11521
|
+
setActiveBranch(suspense, latestFallback);
|
|
11462
11522
|
};
|
|
11463
11523
|
const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === "out-in";
|
|
11464
11524
|
if (delayEnter) {
|
|
@@ -12803,7 +12863,7 @@ function isMemoSame(cached, memo) {
|
|
|
12803
12863
|
return true;
|
|
12804
12864
|
}
|
|
12805
12865
|
|
|
12806
|
-
const version = "3.5.
|
|
12866
|
+
const version = "3.5.42";
|
|
12807
12867
|
const warn = warn$1 ;
|
|
12808
12868
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12809
12869
|
const devtools = devtools$1 ;
|
|
@@ -13444,7 +13504,11 @@ function setStyle(style, name, val) {
|
|
|
13444
13504
|
}
|
|
13445
13505
|
}
|
|
13446
13506
|
if (name.startsWith("--")) {
|
|
13447
|
-
|
|
13507
|
+
if (importantRE.test(val)) {
|
|
13508
|
+
style.setProperty(name, val.replace(importantRE, ""), "important");
|
|
13509
|
+
} else {
|
|
13510
|
+
style.setProperty(name, val);
|
|
13511
|
+
}
|
|
13448
13512
|
} else {
|
|
13449
13513
|
const prefixed = autoPrefix(style, name);
|
|
13450
13514
|
if (importantRE.test(val)) {
|
|
@@ -14631,13 +14695,21 @@ const vModelSelect = {
|
|
|
14631
14695
|
const selectedVal = Array.prototype.filter.call(el.options, (o) => o.selected).map(
|
|
14632
14696
|
(o) => number ? looseToNumber(getValue(o)) : getValue(o)
|
|
14633
14697
|
);
|
|
14634
|
-
el
|
|
14635
|
-
|
|
14636
|
-
|
|
14637
|
-
|
|
14638
|
-
|
|
14639
|
-
|
|
14640
|
-
|
|
14698
|
+
const multiple = el.multiple;
|
|
14699
|
+
const assignedValue = multiple ? isSet(el._modelValue) ? new Set(selectedVal) : selectedVal : selectedVal[0];
|
|
14700
|
+
const pending = el._pendingValue = [
|
|
14701
|
+
multiple,
|
|
14702
|
+
multiple ? isArray(assignedValue) ? selectedVal.slice() : selectedVal : assignedValue
|
|
14703
|
+
];
|
|
14704
|
+
try {
|
|
14705
|
+
el[assignKey](assignedValue);
|
|
14706
|
+
} finally {
|
|
14707
|
+
nextTick(() => {
|
|
14708
|
+
if (el._pendingValue === pending) {
|
|
14709
|
+
el._pendingValue = void 0;
|
|
14710
|
+
}
|
|
14711
|
+
});
|
|
14712
|
+
}
|
|
14641
14713
|
});
|
|
14642
14714
|
el[assignKey] = getModelAssigner(vnode);
|
|
14643
14715
|
},
|
|
@@ -14651,11 +14723,25 @@ const vModelSelect = {
|
|
|
14651
14723
|
el[assignKey] = getModelAssigner(vnode);
|
|
14652
14724
|
},
|
|
14653
14725
|
updated(el, { value }) {
|
|
14654
|
-
|
|
14726
|
+
const pending = el._pendingValue;
|
|
14727
|
+
el._pendingValue = void 0;
|
|
14728
|
+
if (!pending || pending[0] !== el.multiple || !isSameSelectValue(value, pending[1], pending[0])) {
|
|
14655
14729
|
setSelected(el, value);
|
|
14656
14730
|
}
|
|
14657
14731
|
}
|
|
14658
14732
|
};
|
|
14733
|
+
function isSameSelectValue(value, assignedValue, multiple) {
|
|
14734
|
+
if (!multiple) return looseEqual(value, assignedValue);
|
|
14735
|
+
if (isArray(value)) return looseEqual(value, assignedValue);
|
|
14736
|
+
if (isSet(value)) {
|
|
14737
|
+
if (value.size !== assignedValue.length) return false;
|
|
14738
|
+
for (const item of assignedValue) {
|
|
14739
|
+
if (!value.has(item)) return false;
|
|
14740
|
+
}
|
|
14741
|
+
return true;
|
|
14742
|
+
}
|
|
14743
|
+
return false;
|
|
14744
|
+
}
|
|
14659
14745
|
function setSelected(el, value) {
|
|
14660
14746
|
const isMultiple = el.multiple;
|
|
14661
14747
|
const isArrayValue = isArray(value);
|