@vue/compat 3.2.41 → 3.2.43
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 +196 -164
- package/dist/vue.cjs.prod.js +200 -298
- package/dist/vue.esm-browser.js +106 -73
- package/dist/vue.esm-browser.prod.js +1 -1
- package/dist/vue.esm-bundler.js +123 -78
- package/dist/vue.global.js +105 -72
- package/dist/vue.global.prod.js +1 -1
- package/dist/vue.runtime.esm-browser.js +80 -58
- package/dist/vue.runtime.esm-browser.prod.js +1 -1
- package/dist/vue.runtime.esm-bundler.js +95 -61
- package/dist/vue.runtime.global.js +79 -57
- package/dist/vue.runtime.global.prod.js +1 -1
- package/package.json +2 -2
|
@@ -19,27 +19,6 @@ const GLOBALS_WHITE_LISTED = 'Infinity,undefined,NaN,isFinite,isNaN,parseFloat,p
|
|
|
19
19
|
'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';
|
|
20
20
|
const isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);
|
|
21
21
|
|
|
22
|
-
/**
|
|
23
|
-
* On the client we only need to offer special cases for boolean attributes that
|
|
24
|
-
* have different names from their corresponding dom properties:
|
|
25
|
-
* - itemscope -> N/A
|
|
26
|
-
* - allowfullscreen -> allowFullscreen
|
|
27
|
-
* - formnovalidate -> formNoValidate
|
|
28
|
-
* - ismap -> isMap
|
|
29
|
-
* - nomodule -> noModule
|
|
30
|
-
* - novalidate -> noValidate
|
|
31
|
-
* - readonly -> readOnly
|
|
32
|
-
*/
|
|
33
|
-
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
|
34
|
-
const isSpecialBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs);
|
|
35
|
-
/**
|
|
36
|
-
* Boolean attributes should be included if the value is truthy or ''.
|
|
37
|
-
* e.g. `<select multiple>` compiles to `{ multiple: '' }`
|
|
38
|
-
*/
|
|
39
|
-
function includeBooleanAttr(value) {
|
|
40
|
-
return !!value || value === '';
|
|
41
|
-
}
|
|
42
|
-
|
|
43
22
|
function normalizeStyle(value) {
|
|
44
23
|
if (isArray(value)) {
|
|
45
24
|
const res = {};
|
|
@@ -64,10 +43,14 @@ function normalizeStyle(value) {
|
|
|
64
43
|
}
|
|
65
44
|
}
|
|
66
45
|
const listDelimiterRE = /;(?![^(]*\))/g;
|
|
67
|
-
const propertyDelimiterRE = /:(
|
|
46
|
+
const propertyDelimiterRE = /:([^]+)/;
|
|
47
|
+
const styleCommentRE = /\/\*.*?\*\//gs;
|
|
68
48
|
function parseStringStyle(cssText) {
|
|
69
49
|
const ret = {};
|
|
70
|
-
cssText
|
|
50
|
+
cssText
|
|
51
|
+
.replace(styleCommentRE, '')
|
|
52
|
+
.split(listDelimiterRE)
|
|
53
|
+
.forEach(item => {
|
|
71
54
|
if (item) {
|
|
72
55
|
const tmp = item.split(propertyDelimiterRE);
|
|
73
56
|
tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
|
|
@@ -143,6 +126,27 @@ const isHTMLTag = /*#__PURE__*/ makeMap(HTML_TAGS);
|
|
|
143
126
|
*/
|
|
144
127
|
const isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);
|
|
145
128
|
|
|
129
|
+
/**
|
|
130
|
+
* On the client we only need to offer special cases for boolean attributes that
|
|
131
|
+
* have different names from their corresponding dom properties:
|
|
132
|
+
* - itemscope -> N/A
|
|
133
|
+
* - allowfullscreen -> allowFullscreen
|
|
134
|
+
* - formnovalidate -> formNoValidate
|
|
135
|
+
* - ismap -> isMap
|
|
136
|
+
* - nomodule -> noModule
|
|
137
|
+
* - novalidate -> noValidate
|
|
138
|
+
* - readonly -> readOnly
|
|
139
|
+
*/
|
|
140
|
+
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
|
141
|
+
const isSpecialBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs);
|
|
142
|
+
/**
|
|
143
|
+
* Boolean attributes should be included if the value is truthy or ''.
|
|
144
|
+
* e.g. `<select multiple>` compiles to `{ multiple: '' }`
|
|
145
|
+
*/
|
|
146
|
+
function includeBooleanAttr(value) {
|
|
147
|
+
return !!value || value === '';
|
|
148
|
+
}
|
|
149
|
+
|
|
146
150
|
function looseCompareArrays(a, b) {
|
|
147
151
|
if (a.length !== b.length)
|
|
148
152
|
return false;
|
|
@@ -648,8 +652,9 @@ function trigger(target, type, key, newValue, oldValue, oldTarget) {
|
|
|
648
652
|
deps = [...depsMap.values()];
|
|
649
653
|
}
|
|
650
654
|
else if (key === 'length' && isArray(target)) {
|
|
655
|
+
const newLength = toNumber(newValue);
|
|
651
656
|
depsMap.forEach((dep, key) => {
|
|
652
|
-
if (key === 'length' || key >=
|
|
657
|
+
if (key === 'length' || key >= newLength) {
|
|
653
658
|
deps.push(dep);
|
|
654
659
|
}
|
|
655
660
|
});
|
|
@@ -1530,6 +1535,8 @@ function popWarningContext() {
|
|
|
1530
1535
|
stack.pop();
|
|
1531
1536
|
}
|
|
1532
1537
|
function warn$1(msg, ...args) {
|
|
1538
|
+
if (!(process.env.NODE_ENV !== 'production'))
|
|
1539
|
+
return;
|
|
1533
1540
|
// avoid props formatting or warn handler tracking deps that might be mutated
|
|
1534
1541
|
// during patch, leading to infinite recursion.
|
|
1535
1542
|
pauseTracking();
|
|
@@ -2727,7 +2734,7 @@ function emit$2(instance, event, ...rawArgs) {
|
|
|
2727
2734
|
const modifiersKey = `${modelArg === 'modelValue' ? 'model' : modelArg}Modifiers`;
|
|
2728
2735
|
const { number, trim } = props[modifiersKey] || EMPTY_OBJ;
|
|
2729
2736
|
if (trim) {
|
|
2730
|
-
args = rawArgs.map(a => a.trim());
|
|
2737
|
+
args = rawArgs.map(a => (isString(a) ? a.trim() : a));
|
|
2731
2738
|
}
|
|
2732
2739
|
if (number) {
|
|
2733
2740
|
args = rawArgs.map(toNumber);
|
|
@@ -3834,7 +3841,8 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM
|
|
|
3834
3841
|
};
|
|
3835
3842
|
};
|
|
3836
3843
|
// in SSR there is no need to setup an actual effect, and it should be noop
|
|
3837
|
-
// unless it's eager
|
|
3844
|
+
// unless it's eager or sync flush
|
|
3845
|
+
let ssrCleanup;
|
|
3838
3846
|
if (isInSSRComponentSetup) {
|
|
3839
3847
|
// we will also not call the invalidate callback (+ runner is not set up)
|
|
3840
3848
|
onCleanup = NOOP;
|
|
@@ -3848,9 +3856,17 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM
|
|
|
3848
3856
|
onCleanup
|
|
3849
3857
|
]);
|
|
3850
3858
|
}
|
|
3851
|
-
|
|
3859
|
+
if (flush === 'sync') {
|
|
3860
|
+
const ctx = useSSRContext();
|
|
3861
|
+
ssrCleanup = ctx.__watcherHandles || (ctx.__watcherHandles = []);
|
|
3862
|
+
}
|
|
3863
|
+
else {
|
|
3864
|
+
return NOOP;
|
|
3865
|
+
}
|
|
3852
3866
|
}
|
|
3853
|
-
let oldValue = isMultiSource
|
|
3867
|
+
let oldValue = isMultiSource
|
|
3868
|
+
? new Array(source.length).fill(INITIAL_WATCHER_VALUE)
|
|
3869
|
+
: INITIAL_WATCHER_VALUE;
|
|
3854
3870
|
const job = () => {
|
|
3855
3871
|
if (!effect.active) {
|
|
3856
3872
|
return;
|
|
@@ -3872,7 +3888,10 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM
|
|
|
3872
3888
|
callWithAsyncErrorHandling(cb, instance, 3 /* ErrorCodes.WATCH_CALLBACK */, [
|
|
3873
3889
|
newValue,
|
|
3874
3890
|
// pass undefined as the old value when it's changed for the first time
|
|
3875
|
-
oldValue === INITIAL_WATCHER_VALUE
|
|
3891
|
+
oldValue === INITIAL_WATCHER_VALUE ||
|
|
3892
|
+
(isMultiSource && oldValue[0] === INITIAL_WATCHER_VALUE)
|
|
3893
|
+
? []
|
|
3894
|
+
: oldValue,
|
|
3876
3895
|
onCleanup
|
|
3877
3896
|
]);
|
|
3878
3897
|
oldValue = newValue;
|
|
@@ -3920,12 +3939,15 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM
|
|
|
3920
3939
|
else {
|
|
3921
3940
|
effect.run();
|
|
3922
3941
|
}
|
|
3923
|
-
|
|
3942
|
+
const unwatch = () => {
|
|
3924
3943
|
effect.stop();
|
|
3925
3944
|
if (instance && instance.scope) {
|
|
3926
3945
|
remove(instance.scope.effects, effect);
|
|
3927
3946
|
}
|
|
3928
3947
|
};
|
|
3948
|
+
if (ssrCleanup)
|
|
3949
|
+
ssrCleanup.push(unwatch);
|
|
3950
|
+
return unwatch;
|
|
3929
3951
|
}
|
|
3930
3952
|
// this.$watch
|
|
3931
3953
|
function instanceWatch(source, value, options) {
|
|
@@ -4110,7 +4132,11 @@ const BaseTransitionImpl = {
|
|
|
4110
4132
|
// return placeholder node and queue update when leave finishes
|
|
4111
4133
|
leavingHooks.afterLeave = () => {
|
|
4112
4134
|
state.isLeaving = false;
|
|
4113
|
-
|
|
4135
|
+
// #6835
|
|
4136
|
+
// it also needs to be updated when active is undefined
|
|
4137
|
+
if (instance.update.active !== false) {
|
|
4138
|
+
instance.update();
|
|
4139
|
+
}
|
|
4114
4140
|
};
|
|
4115
4141
|
return emptyPlaceholder(child);
|
|
4116
4142
|
}
|
|
@@ -4639,7 +4665,8 @@ const KeepAliveImpl = {
|
|
|
4639
4665
|
: comp);
|
|
4640
4666
|
const { include, exclude, max } = props;
|
|
4641
4667
|
if ((include && (!name || !matches(include, name))) ||
|
|
4642
|
-
(exclude && name && matches(exclude, name))
|
|
4668
|
+
(exclude && name && matches(exclude, name)) ||
|
|
4669
|
+
((process.env.NODE_ENV !== 'production') && hmrDirtyComponents.has(comp))) {
|
|
4643
4670
|
current = vnode;
|
|
4644
4671
|
return rawVNode;
|
|
4645
4672
|
}
|
|
@@ -4919,23 +4946,25 @@ function withDirectives(vnode, directives) {
|
|
|
4919
4946
|
const bindings = vnode.dirs || (vnode.dirs = []);
|
|
4920
4947
|
for (let i = 0; i < directives.length; i++) {
|
|
4921
4948
|
let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];
|
|
4922
|
-
if (
|
|
4923
|
-
dir
|
|
4924
|
-
|
|
4925
|
-
|
|
4926
|
-
|
|
4927
|
-
|
|
4928
|
-
|
|
4929
|
-
|
|
4949
|
+
if (dir) {
|
|
4950
|
+
if (isFunction(dir)) {
|
|
4951
|
+
dir = {
|
|
4952
|
+
mounted: dir,
|
|
4953
|
+
updated: dir
|
|
4954
|
+
};
|
|
4955
|
+
}
|
|
4956
|
+
if (dir.deep) {
|
|
4957
|
+
traverse(value);
|
|
4958
|
+
}
|
|
4959
|
+
bindings.push({
|
|
4960
|
+
dir,
|
|
4961
|
+
instance,
|
|
4962
|
+
value,
|
|
4963
|
+
oldValue: void 0,
|
|
4964
|
+
arg,
|
|
4965
|
+
modifiers
|
|
4966
|
+
});
|
|
4930
4967
|
}
|
|
4931
|
-
bindings.push({
|
|
4932
|
-
dir,
|
|
4933
|
-
instance,
|
|
4934
|
-
value,
|
|
4935
|
-
oldValue: void 0,
|
|
4936
|
-
arg,
|
|
4937
|
-
modifiers
|
|
4938
|
-
});
|
|
4939
4968
|
}
|
|
4940
4969
|
return vnode;
|
|
4941
4970
|
}
|
|
@@ -6772,7 +6801,7 @@ function normalizePropsOptions(comp, appContext, asMixin = false) {
|
|
|
6772
6801
|
if (validatePropName(normalizedKey)) {
|
|
6773
6802
|
const opt = raw[key];
|
|
6774
6803
|
const prop = (normalized[normalizedKey] =
|
|
6775
|
-
isArray(opt) || isFunction(opt) ? { type: opt } : opt);
|
|
6804
|
+
isArray(opt) || isFunction(opt) ? { type: opt } : Object.assign({}, opt));
|
|
6776
6805
|
if (prop) {
|
|
6777
6806
|
const booleanIndex = getTypeIndex(Boolean, prop.type);
|
|
6778
6807
|
const stringIndex = getTypeIndex(String, prop.type);
|
|
@@ -7144,7 +7173,7 @@ function createCompatVue(createApp, createSingletonApp) {
|
|
|
7144
7173
|
return vm;
|
|
7145
7174
|
}
|
|
7146
7175
|
}
|
|
7147
|
-
Vue.version = `2.6.14-compat:${"3.2.
|
|
7176
|
+
Vue.version = `2.6.14-compat:${"3.2.43"}`;
|
|
7148
7177
|
Vue.config = singletonApp.config;
|
|
7149
7178
|
Vue.use = (p, ...options) => {
|
|
7150
7179
|
if (p && isFunction(p.install)) {
|
|
@@ -10772,6 +10801,9 @@ function getExposeProxy(instance) {
|
|
|
10772
10801
|
else if (key in publicPropertiesMap) {
|
|
10773
10802
|
return publicPropertiesMap[key](instance);
|
|
10774
10803
|
}
|
|
10804
|
+
},
|
|
10805
|
+
has(target, key) {
|
|
10806
|
+
return key in target || key in publicPropertiesMap;
|
|
10775
10807
|
}
|
|
10776
10808
|
})));
|
|
10777
10809
|
}
|
|
@@ -11001,8 +11033,9 @@ const useSSRContext = () => {
|
|
|
11001
11033
|
{
|
|
11002
11034
|
const ctx = inject(ssrContextKey);
|
|
11003
11035
|
if (!ctx) {
|
|
11004
|
-
|
|
11005
|
-
`
|
|
11036
|
+
(process.env.NODE_ENV !== 'production') &&
|
|
11037
|
+
warn$1(`Server rendering context not provided. Make sure to only call ` +
|
|
11038
|
+
`useSSRContext() conditionally in the server build.`);
|
|
11006
11039
|
}
|
|
11007
11040
|
return ctx;
|
|
11008
11041
|
}
|
|
@@ -11225,7 +11258,7 @@ function isMemoSame(cached, memo) {
|
|
|
11225
11258
|
}
|
|
11226
11259
|
|
|
11227
11260
|
// Core API ------------------------------------------------------------------
|
|
11228
|
-
const version = "3.2.
|
|
11261
|
+
const version = "3.2.43";
|
|
11229
11262
|
const _ssrUtils = {
|
|
11230
11263
|
createComponentInstance,
|
|
11231
11264
|
setupComponent,
|
|
@@ -11798,7 +11831,7 @@ class VueElement extends BaseClass {
|
|
|
11798
11831
|
}
|
|
11799
11832
|
}).observe(this, { attributes: true });
|
|
11800
11833
|
const resolve = (def) => {
|
|
11801
|
-
const { props, styles } = def;
|
|
11834
|
+
const { props = {}, styles } = def;
|
|
11802
11835
|
const hasOptions = !isArray(props);
|
|
11803
11836
|
const rawKeys = props ? (hasOptions ? Object.keys(props) : props) : [];
|
|
11804
11837
|
// cast Number-type props set before resolve
|
|
@@ -11845,10 +11878,11 @@ class VueElement extends BaseClass {
|
|
|
11845
11878
|
}
|
|
11846
11879
|
_setAttr(key) {
|
|
11847
11880
|
let value = this.getAttribute(key);
|
|
11848
|
-
|
|
11881
|
+
const camelKey = camelize(key);
|
|
11882
|
+
if (this._numberProps && this._numberProps[camelKey]) {
|
|
11849
11883
|
value = toNumber(value);
|
|
11850
11884
|
}
|
|
11851
|
-
this._setProp(
|
|
11885
|
+
this._setProp(camelKey, value, false);
|
|
11852
11886
|
}
|
|
11853
11887
|
/**
|
|
11854
11888
|
* @internal
|
|
@@ -12279,11 +12313,11 @@ function getTransitionInfo(el, expectedType) {
|
|
|
12279
12313
|
const styles = window.getComputedStyle(el);
|
|
12280
12314
|
// JSDOM may return undefined for transition properties
|
|
12281
12315
|
const getStyleProperties = (key) => (styles[key] || '').split(', ');
|
|
12282
|
-
const transitionDelays = getStyleProperties(TRANSITION
|
|
12283
|
-
const transitionDurations = getStyleProperties(TRANSITION
|
|
12316
|
+
const transitionDelays = getStyleProperties(`${TRANSITION}Delay`);
|
|
12317
|
+
const transitionDurations = getStyleProperties(`${TRANSITION}Duration`);
|
|
12284
12318
|
const transitionTimeout = getTimeout(transitionDelays, transitionDurations);
|
|
12285
|
-
const animationDelays = getStyleProperties(ANIMATION
|
|
12286
|
-
const animationDurations = getStyleProperties(ANIMATION
|
|
12319
|
+
const animationDelays = getStyleProperties(`${ANIMATION}Delay`);
|
|
12320
|
+
const animationDurations = getStyleProperties(`${ANIMATION}Duration`);
|
|
12287
12321
|
const animationTimeout = getTimeout(animationDelays, animationDurations);
|
|
12288
12322
|
let type = null;
|
|
12289
12323
|
let timeout = 0;
|
|
@@ -12318,7 +12352,7 @@ function getTransitionInfo(el, expectedType) {
|
|
|
12318
12352
|
: 0;
|
|
12319
12353
|
}
|
|
12320
12354
|
const hasTransform = type === TRANSITION &&
|
|
12321
|
-
/\b(transform|all)(,|$)/.test(
|
|
12355
|
+
/\b(transform|all)(,|$)/.test(getStyleProperties(`${TRANSITION}Property`).toString());
|
|
12322
12356
|
return {
|
|
12323
12357
|
type,
|
|
12324
12358
|
timeout,
|
|
@@ -22,27 +22,6 @@ var Vue = (function () {
|
|
|
22
22
|
'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';
|
|
23
23
|
const isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);
|
|
24
24
|
|
|
25
|
-
/**
|
|
26
|
-
* On the client we only need to offer special cases for boolean attributes that
|
|
27
|
-
* have different names from their corresponding dom properties:
|
|
28
|
-
* - itemscope -> N/A
|
|
29
|
-
* - allowfullscreen -> allowFullscreen
|
|
30
|
-
* - formnovalidate -> formNoValidate
|
|
31
|
-
* - ismap -> isMap
|
|
32
|
-
* - nomodule -> noModule
|
|
33
|
-
* - novalidate -> noValidate
|
|
34
|
-
* - readonly -> readOnly
|
|
35
|
-
*/
|
|
36
|
-
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
|
37
|
-
const isSpecialBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs);
|
|
38
|
-
/**
|
|
39
|
-
* Boolean attributes should be included if the value is truthy or ''.
|
|
40
|
-
* e.g. `<select multiple>` compiles to `{ multiple: '' }`
|
|
41
|
-
*/
|
|
42
|
-
function includeBooleanAttr(value) {
|
|
43
|
-
return !!value || value === '';
|
|
44
|
-
}
|
|
45
|
-
|
|
46
25
|
function normalizeStyle(value) {
|
|
47
26
|
if (isArray(value)) {
|
|
48
27
|
const res = {};
|
|
@@ -67,10 +46,14 @@ var Vue = (function () {
|
|
|
67
46
|
}
|
|
68
47
|
}
|
|
69
48
|
const listDelimiterRE = /;(?![^(]*\))/g;
|
|
70
|
-
const propertyDelimiterRE = /:(
|
|
49
|
+
const propertyDelimiterRE = /:([^]+)/;
|
|
50
|
+
const styleCommentRE = /\/\*.*?\*\//gs;
|
|
71
51
|
function parseStringStyle(cssText) {
|
|
72
52
|
const ret = {};
|
|
73
|
-
cssText
|
|
53
|
+
cssText
|
|
54
|
+
.replace(styleCommentRE, '')
|
|
55
|
+
.split(listDelimiterRE)
|
|
56
|
+
.forEach(item => {
|
|
74
57
|
if (item) {
|
|
75
58
|
const tmp = item.split(propertyDelimiterRE);
|
|
76
59
|
tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
|
|
@@ -146,6 +129,27 @@ var Vue = (function () {
|
|
|
146
129
|
*/
|
|
147
130
|
const isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);
|
|
148
131
|
|
|
132
|
+
/**
|
|
133
|
+
* On the client we only need to offer special cases for boolean attributes that
|
|
134
|
+
* have different names from their corresponding dom properties:
|
|
135
|
+
* - itemscope -> N/A
|
|
136
|
+
* - allowfullscreen -> allowFullscreen
|
|
137
|
+
* - formnovalidate -> formNoValidate
|
|
138
|
+
* - ismap -> isMap
|
|
139
|
+
* - nomodule -> noModule
|
|
140
|
+
* - novalidate -> noValidate
|
|
141
|
+
* - readonly -> readOnly
|
|
142
|
+
*/
|
|
143
|
+
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
|
144
|
+
const isSpecialBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs);
|
|
145
|
+
/**
|
|
146
|
+
* Boolean attributes should be included if the value is truthy or ''.
|
|
147
|
+
* e.g. `<select multiple>` compiles to `{ multiple: '' }`
|
|
148
|
+
*/
|
|
149
|
+
function includeBooleanAttr(value) {
|
|
150
|
+
return !!value || value === '';
|
|
151
|
+
}
|
|
152
|
+
|
|
149
153
|
function looseCompareArrays(a, b) {
|
|
150
154
|
if (a.length !== b.length)
|
|
151
155
|
return false;
|
|
@@ -649,8 +653,9 @@ var Vue = (function () {
|
|
|
649
653
|
deps = [...depsMap.values()];
|
|
650
654
|
}
|
|
651
655
|
else if (key === 'length' && isArray(target)) {
|
|
656
|
+
const newLength = toNumber(newValue);
|
|
652
657
|
depsMap.forEach((dep, key) => {
|
|
653
|
-
if (key === 'length' || key >=
|
|
658
|
+
if (key === 'length' || key >= newLength) {
|
|
654
659
|
deps.push(dep);
|
|
655
660
|
}
|
|
656
661
|
});
|
|
@@ -2704,7 +2709,7 @@ var Vue = (function () {
|
|
|
2704
2709
|
const modifiersKey = `${modelArg === 'modelValue' ? 'model' : modelArg}Modifiers`;
|
|
2705
2710
|
const { number, trim } = props[modifiersKey] || EMPTY_OBJ;
|
|
2706
2711
|
if (trim) {
|
|
2707
|
-
args = rawArgs.map(a => a.trim());
|
|
2712
|
+
args = rawArgs.map(a => (isString(a) ? a.trim() : a));
|
|
2708
2713
|
}
|
|
2709
2714
|
if (number) {
|
|
2710
2715
|
args = rawArgs.map(toNumber);
|
|
@@ -3807,7 +3812,9 @@ var Vue = (function () {
|
|
|
3807
3812
|
callWithErrorHandling(fn, instance, 4 /* ErrorCodes.WATCH_CLEANUP */);
|
|
3808
3813
|
};
|
|
3809
3814
|
};
|
|
3810
|
-
let oldValue = isMultiSource
|
|
3815
|
+
let oldValue = isMultiSource
|
|
3816
|
+
? new Array(source.length).fill(INITIAL_WATCHER_VALUE)
|
|
3817
|
+
: INITIAL_WATCHER_VALUE;
|
|
3811
3818
|
const job = () => {
|
|
3812
3819
|
if (!effect.active) {
|
|
3813
3820
|
return;
|
|
@@ -3829,7 +3836,10 @@ var Vue = (function () {
|
|
|
3829
3836
|
callWithAsyncErrorHandling(cb, instance, 3 /* ErrorCodes.WATCH_CALLBACK */, [
|
|
3830
3837
|
newValue,
|
|
3831
3838
|
// pass undefined as the old value when it's changed for the first time
|
|
3832
|
-
oldValue === INITIAL_WATCHER_VALUE
|
|
3839
|
+
oldValue === INITIAL_WATCHER_VALUE ||
|
|
3840
|
+
(isMultiSource && oldValue[0] === INITIAL_WATCHER_VALUE)
|
|
3841
|
+
? []
|
|
3842
|
+
: oldValue,
|
|
3833
3843
|
onCleanup
|
|
3834
3844
|
]);
|
|
3835
3845
|
oldValue = newValue;
|
|
@@ -3877,12 +3887,13 @@ var Vue = (function () {
|
|
|
3877
3887
|
else {
|
|
3878
3888
|
effect.run();
|
|
3879
3889
|
}
|
|
3880
|
-
|
|
3890
|
+
const unwatch = () => {
|
|
3881
3891
|
effect.stop();
|
|
3882
3892
|
if (instance && instance.scope) {
|
|
3883
3893
|
remove(instance.scope.effects, effect);
|
|
3884
3894
|
}
|
|
3885
3895
|
};
|
|
3896
|
+
return unwatch;
|
|
3886
3897
|
}
|
|
3887
3898
|
// this.$watch
|
|
3888
3899
|
function instanceWatch(source, value, options) {
|
|
@@ -4064,7 +4075,11 @@ var Vue = (function () {
|
|
|
4064
4075
|
// return placeholder node and queue update when leave finishes
|
|
4065
4076
|
leavingHooks.afterLeave = () => {
|
|
4066
4077
|
state.isLeaving = false;
|
|
4067
|
-
|
|
4078
|
+
// #6835
|
|
4079
|
+
// it also needs to be updated when active is undefined
|
|
4080
|
+
if (instance.update.active !== false) {
|
|
4081
|
+
instance.update();
|
|
4082
|
+
}
|
|
4068
4083
|
};
|
|
4069
4084
|
return emptyPlaceholder(child);
|
|
4070
4085
|
}
|
|
@@ -4585,7 +4600,8 @@ var Vue = (function () {
|
|
|
4585
4600
|
: comp);
|
|
4586
4601
|
const { include, exclude, max } = props;
|
|
4587
4602
|
if ((include && (!name || !matches(include, name))) ||
|
|
4588
|
-
(exclude && name && matches(exclude, name))
|
|
4603
|
+
(exclude && name && matches(exclude, name)) ||
|
|
4604
|
+
(hmrDirtyComponents.has(comp))) {
|
|
4589
4605
|
current = vnode;
|
|
4590
4606
|
return rawVNode;
|
|
4591
4607
|
}
|
|
@@ -4865,23 +4881,25 @@ var Vue = (function () {
|
|
|
4865
4881
|
const bindings = vnode.dirs || (vnode.dirs = []);
|
|
4866
4882
|
for (let i = 0; i < directives.length; i++) {
|
|
4867
4883
|
let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];
|
|
4868
|
-
if (
|
|
4869
|
-
dir
|
|
4870
|
-
|
|
4871
|
-
|
|
4872
|
-
|
|
4873
|
-
|
|
4874
|
-
|
|
4875
|
-
|
|
4884
|
+
if (dir) {
|
|
4885
|
+
if (isFunction(dir)) {
|
|
4886
|
+
dir = {
|
|
4887
|
+
mounted: dir,
|
|
4888
|
+
updated: dir
|
|
4889
|
+
};
|
|
4890
|
+
}
|
|
4891
|
+
if (dir.deep) {
|
|
4892
|
+
traverse(value);
|
|
4893
|
+
}
|
|
4894
|
+
bindings.push({
|
|
4895
|
+
dir,
|
|
4896
|
+
instance,
|
|
4897
|
+
value,
|
|
4898
|
+
oldValue: void 0,
|
|
4899
|
+
arg,
|
|
4900
|
+
modifiers
|
|
4901
|
+
});
|
|
4876
4902
|
}
|
|
4877
|
-
bindings.push({
|
|
4878
|
-
dir,
|
|
4879
|
-
instance,
|
|
4880
|
-
value,
|
|
4881
|
-
oldValue: void 0,
|
|
4882
|
-
arg,
|
|
4883
|
-
modifiers
|
|
4884
|
-
});
|
|
4885
4903
|
}
|
|
4886
4904
|
return vnode;
|
|
4887
4905
|
}
|
|
@@ -6708,7 +6726,7 @@ var Vue = (function () {
|
|
|
6708
6726
|
if (validatePropName(normalizedKey)) {
|
|
6709
6727
|
const opt = raw[key];
|
|
6710
6728
|
const prop = (normalized[normalizedKey] =
|
|
6711
|
-
isArray(opt) || isFunction(opt) ? { type: opt } : opt);
|
|
6729
|
+
isArray(opt) || isFunction(opt) ? { type: opt } : Object.assign({}, opt));
|
|
6712
6730
|
if (prop) {
|
|
6713
6731
|
const booleanIndex = getTypeIndex(Boolean, prop.type);
|
|
6714
6732
|
const stringIndex = getTypeIndex(String, prop.type);
|
|
@@ -7078,7 +7096,7 @@ var Vue = (function () {
|
|
|
7078
7096
|
return vm;
|
|
7079
7097
|
}
|
|
7080
7098
|
}
|
|
7081
|
-
Vue.version = `2.6.14-compat:${"3.2.
|
|
7099
|
+
Vue.version = `2.6.14-compat:${"3.2.43"}`;
|
|
7082
7100
|
Vue.config = singletonApp.config;
|
|
7083
7101
|
Vue.use = (p, ...options) => {
|
|
7084
7102
|
if (p && isFunction(p.install)) {
|
|
@@ -10634,6 +10652,9 @@ var Vue = (function () {
|
|
|
10634
10652
|
else if (key in publicPropertiesMap) {
|
|
10635
10653
|
return publicPropertiesMap[key](instance);
|
|
10636
10654
|
}
|
|
10655
|
+
},
|
|
10656
|
+
has(target, key) {
|
|
10657
|
+
return key in target || key in publicPropertiesMap;
|
|
10637
10658
|
}
|
|
10638
10659
|
})));
|
|
10639
10660
|
}
|
|
@@ -11082,7 +11103,7 @@ var Vue = (function () {
|
|
|
11082
11103
|
}
|
|
11083
11104
|
|
|
11084
11105
|
// Core API ------------------------------------------------------------------
|
|
11085
|
-
const version = "3.2.
|
|
11106
|
+
const version = "3.2.43";
|
|
11086
11107
|
/**
|
|
11087
11108
|
* SSR utils for \@vue/server-renderer. Only exposed in ssr-possible builds.
|
|
11088
11109
|
* @internal
|
|
@@ -11646,7 +11667,7 @@ var Vue = (function () {
|
|
|
11646
11667
|
}
|
|
11647
11668
|
}).observe(this, { attributes: true });
|
|
11648
11669
|
const resolve = (def) => {
|
|
11649
|
-
const { props, styles } = def;
|
|
11670
|
+
const { props = {}, styles } = def;
|
|
11650
11671
|
const hasOptions = !isArray(props);
|
|
11651
11672
|
const rawKeys = props ? (hasOptions ? Object.keys(props) : props) : [];
|
|
11652
11673
|
// cast Number-type props set before resolve
|
|
@@ -11693,10 +11714,11 @@ var Vue = (function () {
|
|
|
11693
11714
|
}
|
|
11694
11715
|
_setAttr(key) {
|
|
11695
11716
|
let value = this.getAttribute(key);
|
|
11696
|
-
|
|
11717
|
+
const camelKey = camelize(key);
|
|
11718
|
+
if (this._numberProps && this._numberProps[camelKey]) {
|
|
11697
11719
|
value = toNumber(value);
|
|
11698
11720
|
}
|
|
11699
|
-
this._setProp(
|
|
11721
|
+
this._setProp(camelKey, value, false);
|
|
11700
11722
|
}
|
|
11701
11723
|
/**
|
|
11702
11724
|
* @internal
|
|
@@ -12112,11 +12134,11 @@ var Vue = (function () {
|
|
|
12112
12134
|
const styles = window.getComputedStyle(el);
|
|
12113
12135
|
// JSDOM may return undefined for transition properties
|
|
12114
12136
|
const getStyleProperties = (key) => (styles[key] || '').split(', ');
|
|
12115
|
-
const transitionDelays = getStyleProperties(TRANSITION
|
|
12116
|
-
const transitionDurations = getStyleProperties(TRANSITION
|
|
12137
|
+
const transitionDelays = getStyleProperties(`${TRANSITION}Delay`);
|
|
12138
|
+
const transitionDurations = getStyleProperties(`${TRANSITION}Duration`);
|
|
12117
12139
|
const transitionTimeout = getTimeout(transitionDelays, transitionDurations);
|
|
12118
|
-
const animationDelays = getStyleProperties(ANIMATION
|
|
12119
|
-
const animationDurations = getStyleProperties(ANIMATION
|
|
12140
|
+
const animationDelays = getStyleProperties(`${ANIMATION}Delay`);
|
|
12141
|
+
const animationDurations = getStyleProperties(`${ANIMATION}Duration`);
|
|
12120
12142
|
const animationTimeout = getTimeout(animationDelays, animationDurations);
|
|
12121
12143
|
let type = null;
|
|
12122
12144
|
let timeout = 0;
|
|
@@ -12151,7 +12173,7 @@ var Vue = (function () {
|
|
|
12151
12173
|
: 0;
|
|
12152
12174
|
}
|
|
12153
12175
|
const hasTransform = type === TRANSITION &&
|
|
12154
|
-
/\b(transform|all)(,|$)/.test(
|
|
12176
|
+
/\b(transform|all)(,|$)/.test(getStyleProperties(`${TRANSITION}Property`).toString());
|
|
12155
12177
|
return {
|
|
12156
12178
|
type,
|
|
12157
12179
|
timeout,
|