@vue/compat 3.5.0-rc.1 → 3.5.0
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 +29 -12
- package/dist/vue.cjs.prod.js +18 -11
- package/dist/vue.esm-browser.js +30 -12
- package/dist/vue.esm-browser.prod.js +2 -2
- package/dist/vue.esm-bundler.js +30 -12
- package/dist/vue.global.js +30 -12
- package/dist/vue.global.prod.js +2 -2
- package/dist/vue.runtime.esm-browser.js +30 -12
- package/dist/vue.runtime.esm-browser.prod.js +2 -2
- package/dist/vue.runtime.esm-bundler.js +30 -12
- package/dist/vue.runtime.global.js +30 -12
- package/dist/vue.runtime.global.prod.js +2 -2
- package/package.json +2 -2
package/dist/vue.esm-bundler.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.0
|
|
2
|
+
* @vue/compat v3.5.0
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -281,6 +281,14 @@ function isRenderableAttrValue(value) {
|
|
|
281
281
|
return type === "string" || type === "number" || type === "boolean";
|
|
282
282
|
}
|
|
283
283
|
|
|
284
|
+
const cssVarNameEscapeSymbolsRE = /[ !"#$%&'()*+,./:;<=>?@[\\\]^`{|}~]/g;
|
|
285
|
+
function getEscapedCssVarName(key, doubleEscape) {
|
|
286
|
+
return key.replace(
|
|
287
|
+
cssVarNameEscapeSymbolsRE,
|
|
288
|
+
(s) => `\\${s}`
|
|
289
|
+
);
|
|
290
|
+
}
|
|
291
|
+
|
|
284
292
|
function looseCompareArrays(a, b) {
|
|
285
293
|
if (a.length !== b.length) return false;
|
|
286
294
|
let equal = true;
|
|
@@ -1144,7 +1152,7 @@ function apply(self, method, fn, thisArg, wrappedRetFn, args) {
|
|
|
1144
1152
|
const needsWrap = arr !== self && !isShallow(self);
|
|
1145
1153
|
const methodFn = arr[method];
|
|
1146
1154
|
if (methodFn !== arrayProto[method]) {
|
|
1147
|
-
const result2 = methodFn.apply(
|
|
1155
|
+
const result2 = methodFn.apply(self, args);
|
|
1148
1156
|
return needsWrap ? toReactive(result2) : result2;
|
|
1149
1157
|
}
|
|
1150
1158
|
let wrappedFn = fn;
|
|
@@ -4632,8 +4640,7 @@ Server rendered element contains more child nodes than client vdom.`
|
|
|
4632
4640
|
const isText = vnode.type === Text;
|
|
4633
4641
|
if (node) {
|
|
4634
4642
|
if (isText && !optimized) {
|
|
4635
|
-
|
|
4636
|
-
if (next && (next = normalizeVNode(next)).type === Text) {
|
|
4643
|
+
if (i + 1 < l && normalizeVNode(children[i + 1]).type === Text) {
|
|
4637
4644
|
insert(
|
|
4638
4645
|
createText(
|
|
4639
4646
|
node.data.slice(vnode.children.length)
|
|
@@ -4889,7 +4896,10 @@ function resolveCssVars(instance, vnode, expectedMap) {
|
|
|
4889
4896
|
if (instance.getCssVars && (vnode === root || root && root.type === Fragment && root.children.includes(vnode))) {
|
|
4890
4897
|
const cssVars = instance.getCssVars();
|
|
4891
4898
|
for (const key in cssVars) {
|
|
4892
|
-
expectedMap.set(
|
|
4899
|
+
expectedMap.set(
|
|
4900
|
+
`--${getEscapedCssVarName(key)}`,
|
|
4901
|
+
String(cssVars[key])
|
|
4902
|
+
);
|
|
4893
4903
|
}
|
|
4894
4904
|
}
|
|
4895
4905
|
if (vnode === root && instance.parent) {
|
|
@@ -7074,7 +7084,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7074
7084
|
return vm;
|
|
7075
7085
|
}
|
|
7076
7086
|
}
|
|
7077
|
-
Vue.version = `2.6.14-compat:${"3.5.0
|
|
7087
|
+
Vue.version = `2.6.14-compat:${"3.5.0"}`;
|
|
7078
7088
|
Vue.config = singletonApp.config;
|
|
7079
7089
|
Vue.use = (plugin, ...options) => {
|
|
7080
7090
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -12264,7 +12274,7 @@ function isMemoSame(cached, memo) {
|
|
|
12264
12274
|
return true;
|
|
12265
12275
|
}
|
|
12266
12276
|
|
|
12267
|
-
const version = "3.5.0
|
|
12277
|
+
const version = "3.5.0";
|
|
12268
12278
|
const warn = !!(process.env.NODE_ENV !== "production") ? warn$1 : NOOP;
|
|
12269
12279
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12270
12280
|
const devtools = !!(process.env.NODE_ENV !== "production") || true ? devtools$1 : void 0;
|
|
@@ -12972,7 +12982,11 @@ function patchDOMProp(el, key, value, parentComponent) {
|
|
|
12972
12982
|
if (key === "value" && tag !== "PROGRESS" && // custom elements may use _value internally
|
|
12973
12983
|
!tag.includes("-")) {
|
|
12974
12984
|
const oldValue = tag === "OPTION" ? el.getAttribute("value") || "" : el.value;
|
|
12975
|
-
const newValue = value == null ?
|
|
12985
|
+
const newValue = value == null ? (
|
|
12986
|
+
// #11647: value should be set as empty string for null and undefined,
|
|
12987
|
+
// but <input type="checkbox"> should be set as 'on'.
|
|
12988
|
+
el.type === "checkbox" ? "on" : ""
|
|
12989
|
+
) : String(value);
|
|
12976
12990
|
if (oldValue !== newValue || !("_value" in el)) {
|
|
12977
12991
|
el.value = newValue;
|
|
12978
12992
|
}
|
|
@@ -13858,12 +13872,16 @@ const vModelCheckbox = {
|
|
|
13858
13872
|
};
|
|
13859
13873
|
function setChecked(el, { value, oldValue }, vnode) {
|
|
13860
13874
|
el._modelValue = value;
|
|
13875
|
+
let checked;
|
|
13861
13876
|
if (isArray(value)) {
|
|
13862
|
-
|
|
13877
|
+
checked = looseIndexOf(value, vnode.props.value) > -1;
|
|
13863
13878
|
} else if (isSet(value)) {
|
|
13864
|
-
|
|
13865
|
-
} else
|
|
13866
|
-
|
|
13879
|
+
checked = value.has(vnode.props.value);
|
|
13880
|
+
} else {
|
|
13881
|
+
checked = looseEqual(value, getCheckboxValue(el, true));
|
|
13882
|
+
}
|
|
13883
|
+
if (el.checked !== checked) {
|
|
13884
|
+
el.checked = checked;
|
|
13867
13885
|
}
|
|
13868
13886
|
}
|
|
13869
13887
|
const vModelRadio = {
|
package/dist/vue.global.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.0
|
|
2
|
+
* @vue/compat v3.5.0
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -284,6 +284,14 @@ var Vue = (function () {
|
|
|
284
284
|
return type === "string" || type === "number" || type === "boolean";
|
|
285
285
|
}
|
|
286
286
|
|
|
287
|
+
const cssVarNameEscapeSymbolsRE = /[ !"#$%&'()*+,./:;<=>?@[\\\]^`{|}~]/g;
|
|
288
|
+
function getEscapedCssVarName(key, doubleEscape) {
|
|
289
|
+
return key.replace(
|
|
290
|
+
cssVarNameEscapeSymbolsRE,
|
|
291
|
+
(s) => `\\${s}`
|
|
292
|
+
);
|
|
293
|
+
}
|
|
294
|
+
|
|
287
295
|
function looseCompareArrays(a, b) {
|
|
288
296
|
if (a.length !== b.length) return false;
|
|
289
297
|
let equal = true;
|
|
@@ -1143,7 +1151,7 @@ var Vue = (function () {
|
|
|
1143
1151
|
const needsWrap = arr !== self && !isShallow(self);
|
|
1144
1152
|
const methodFn = arr[method];
|
|
1145
1153
|
if (methodFn !== arrayProto[method]) {
|
|
1146
|
-
const result2 = methodFn.apply(
|
|
1154
|
+
const result2 = methodFn.apply(self, args);
|
|
1147
1155
|
return needsWrap ? toReactive(result2) : result2;
|
|
1148
1156
|
}
|
|
1149
1157
|
let wrappedFn = fn;
|
|
@@ -4605,8 +4613,7 @@ Server rendered element contains more child nodes than client vdom.`
|
|
|
4605
4613
|
const isText = vnode.type === Text;
|
|
4606
4614
|
if (node) {
|
|
4607
4615
|
if (isText && !optimized) {
|
|
4608
|
-
|
|
4609
|
-
if (next && (next = normalizeVNode(next)).type === Text) {
|
|
4616
|
+
if (i + 1 < l && normalizeVNode(children[i + 1]).type === Text) {
|
|
4610
4617
|
insert(
|
|
4611
4618
|
createText(
|
|
4612
4619
|
node.data.slice(vnode.children.length)
|
|
@@ -4862,7 +4869,10 @@ Server rendered element contains fewer child nodes than client vdom.`
|
|
|
4862
4869
|
if (instance.getCssVars && (vnode === root || root && root.type === Fragment && root.children.includes(vnode))) {
|
|
4863
4870
|
const cssVars = instance.getCssVars();
|
|
4864
4871
|
for (const key in cssVars) {
|
|
4865
|
-
expectedMap.set(
|
|
4872
|
+
expectedMap.set(
|
|
4873
|
+
`--${getEscapedCssVarName(key)}`,
|
|
4874
|
+
String(cssVars[key])
|
|
4875
|
+
);
|
|
4866
4876
|
}
|
|
4867
4877
|
}
|
|
4868
4878
|
if (vnode === root && instance.parent) {
|
|
@@ -7036,7 +7046,7 @@ If this is a native custom element, make sure to exclude it from component resol
|
|
|
7036
7046
|
return vm;
|
|
7037
7047
|
}
|
|
7038
7048
|
}
|
|
7039
|
-
Vue.version = `2.6.14-compat:${"3.5.0
|
|
7049
|
+
Vue.version = `2.6.14-compat:${"3.5.0"}`;
|
|
7040
7050
|
Vue.config = singletonApp.config;
|
|
7041
7051
|
Vue.use = (plugin, ...options) => {
|
|
7042
7052
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -12136,7 +12146,7 @@ Component that was made reactive: `,
|
|
|
12136
12146
|
return true;
|
|
12137
12147
|
}
|
|
12138
12148
|
|
|
12139
|
-
const version = "3.5.0
|
|
12149
|
+
const version = "3.5.0";
|
|
12140
12150
|
const warn = warn$1 ;
|
|
12141
12151
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12142
12152
|
const devtools = devtools$1 ;
|
|
@@ -12827,7 +12837,11 @@ Component that was made reactive: `,
|
|
|
12827
12837
|
if (key === "value" && tag !== "PROGRESS" && // custom elements may use _value internally
|
|
12828
12838
|
!tag.includes("-")) {
|
|
12829
12839
|
const oldValue = tag === "OPTION" ? el.getAttribute("value") || "" : el.value;
|
|
12830
|
-
const newValue = value == null ?
|
|
12840
|
+
const newValue = value == null ? (
|
|
12841
|
+
// #11647: value should be set as empty string for null and undefined,
|
|
12842
|
+
// but <input type="checkbox"> should be set as 'on'.
|
|
12843
|
+
el.type === "checkbox" ? "on" : ""
|
|
12844
|
+
) : String(value);
|
|
12831
12845
|
if (oldValue !== newValue || !("_value" in el)) {
|
|
12832
12846
|
el.value = newValue;
|
|
12833
12847
|
}
|
|
@@ -13701,12 +13715,16 @@ Expected function or array of functions, received type ${typeof value}.`
|
|
|
13701
13715
|
};
|
|
13702
13716
|
function setChecked(el, { value, oldValue }, vnode) {
|
|
13703
13717
|
el._modelValue = value;
|
|
13718
|
+
let checked;
|
|
13704
13719
|
if (isArray(value)) {
|
|
13705
|
-
|
|
13720
|
+
checked = looseIndexOf(value, vnode.props.value) > -1;
|
|
13706
13721
|
} else if (isSet(value)) {
|
|
13707
|
-
|
|
13708
|
-
} else
|
|
13709
|
-
|
|
13722
|
+
checked = value.has(vnode.props.value);
|
|
13723
|
+
} else {
|
|
13724
|
+
checked = looseEqual(value, getCheckboxValue(el, true));
|
|
13725
|
+
}
|
|
13726
|
+
if (el.checked !== checked) {
|
|
13727
|
+
el.checked = checked;
|
|
13710
13728
|
}
|
|
13711
13729
|
}
|
|
13712
13730
|
const vModelRadio = {
|