@vue/compiler-sfc 3.5.24 → 3.5.25
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/compiler-sfc.cjs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compiler-sfc v3.5.
|
|
2
|
+
* @vue/compiler-sfc v3.5.25
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -25083,7 +25083,7 @@ function mergeSourceMaps(scriptMap, templateMap, templateLineOffset) {
|
|
|
25083
25083
|
return generator.toJSON();
|
|
25084
25084
|
}
|
|
25085
25085
|
|
|
25086
|
-
const version = "3.5.
|
|
25086
|
+
const version = "3.5.25";
|
|
25087
25087
|
const parseCache = parseCache$1;
|
|
25088
25088
|
const errorMessages = {
|
|
25089
25089
|
...CompilerDOM.errorMessages,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compiler-sfc v3.5.
|
|
2
|
+
* @vue/compiler-sfc v3.5.25
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -18025,6 +18025,20 @@ function getMemoedVNodeCall(node) {
|
|
|
18025
18025
|
}
|
|
18026
18026
|
}
|
|
18027
18027
|
const forAliasRE = /([\s\S]*?)\s+(?:in|of)\s+(\S[\s\S]*)/;
|
|
18028
|
+
function isAllWhitespace(str) {
|
|
18029
|
+
for (let i = 0; i < str.length; i++) {
|
|
18030
|
+
if (!isWhitespace(str.charCodeAt(i))) {
|
|
18031
|
+
return false;
|
|
18032
|
+
}
|
|
18033
|
+
}
|
|
18034
|
+
return true;
|
|
18035
|
+
}
|
|
18036
|
+
function isWhitespaceText(node) {
|
|
18037
|
+
return node.type === 2 && isAllWhitespace(node.content) || node.type === 12 && isWhitespaceText(node.content);
|
|
18038
|
+
}
|
|
18039
|
+
function isCommentOrWhitespace(node) {
|
|
18040
|
+
return node.type === 3 || isWhitespaceText(node);
|
|
18041
|
+
}
|
|
18028
18042
|
|
|
18029
18043
|
const defaultParserOptions = {
|
|
18030
18044
|
parseMode: "base",
|
|
@@ -18561,14 +18575,6 @@ function condenseWhitespace(nodes) {
|
|
|
18561
18575
|
}
|
|
18562
18576
|
return removedWhitespace ? nodes.filter(Boolean) : nodes;
|
|
18563
18577
|
}
|
|
18564
|
-
function isAllWhitespace(str) {
|
|
18565
|
-
for (let i = 0; i < str.length; i++) {
|
|
18566
|
-
if (!isWhitespace(str.charCodeAt(i))) {
|
|
18567
|
-
return false;
|
|
18568
|
-
}
|
|
18569
|
-
}
|
|
18570
|
-
return true;
|
|
18571
|
-
}
|
|
18572
18578
|
function hasNewlineChar(str) {
|
|
18573
18579
|
for (let i = 0; i < str.length; i++) {
|
|
18574
18580
|
const c = str.charCodeAt(i);
|
|
@@ -23800,13 +23806,11 @@ function processIf(node, dir, context, processCodegen) {
|
|
|
23800
23806
|
let i = siblings.indexOf(node);
|
|
23801
23807
|
while (i-- >= -1) {
|
|
23802
23808
|
const sibling = siblings[i];
|
|
23803
|
-
if (sibling && sibling
|
|
23804
|
-
context.removeNode(sibling);
|
|
23805
|
-
comments.unshift(sibling);
|
|
23806
|
-
continue;
|
|
23807
|
-
}
|
|
23808
|
-
if (sibling && sibling.type === 2 && !sibling.content.trim().length) {
|
|
23809
|
+
if (sibling && isCommentOrWhitespace(sibling)) {
|
|
23809
23810
|
context.removeNode(sibling);
|
|
23811
|
+
if (sibling.type === 3) {
|
|
23812
|
+
comments.unshift(sibling);
|
|
23813
|
+
}
|
|
23810
23814
|
continue;
|
|
23811
23815
|
}
|
|
23812
23816
|
if (sibling && sibling.type === 9) {
|
|
@@ -24324,7 +24328,7 @@ function buildSlots(node, context, buildSlotFn = buildClientSlotFn) {
|
|
|
24324
24328
|
let prev;
|
|
24325
24329
|
while (j--) {
|
|
24326
24330
|
prev = children[j];
|
|
24327
|
-
if (
|
|
24331
|
+
if (!isCommentOrWhitespace(prev)) {
|
|
24328
24332
|
break;
|
|
24329
24333
|
}
|
|
24330
24334
|
}
|
|
@@ -24399,7 +24403,7 @@ function buildSlots(node, context, buildSlotFn = buildClientSlotFn) {
|
|
|
24399
24403
|
} else if (implicitDefaultChildren.length && // #3766
|
|
24400
24404
|
// with whitespace: 'preserve', whitespaces between slots will end up in
|
|
24401
24405
|
// implicitDefaultChildren. Ignore if all implicit children are whitespaces.
|
|
24402
|
-
implicitDefaultChildren.
|
|
24406
|
+
!implicitDefaultChildren.every(isWhitespaceText)) {
|
|
24403
24407
|
if (hasNamedDefaultSlot) {
|
|
24404
24408
|
context.onError(
|
|
24405
24409
|
createCompilerError(
|
|
@@ -24472,11 +24476,6 @@ function hasForwardedSlots(children) {
|
|
|
24472
24476
|
}
|
|
24473
24477
|
return false;
|
|
24474
24478
|
}
|
|
24475
|
-
function isNonWhitespaceContent(node) {
|
|
24476
|
-
if (node.type !== 2 && node.type !== 12)
|
|
24477
|
-
return true;
|
|
24478
|
-
return node.type === 2 ? !!node.content.trim() : isNonWhitespaceContent(node.content);
|
|
24479
|
-
}
|
|
24480
24479
|
|
|
24481
24480
|
const directiveImportMap = /* @__PURE__ */ new WeakMap();
|
|
24482
24481
|
const transformElement = (node, context) => {
|
|
@@ -26043,7 +26042,7 @@ const transformTransition = (node, context) => {
|
|
|
26043
26042
|
};
|
|
26044
26043
|
function hasMultipleChildren(node) {
|
|
26045
26044
|
const children = node.children = node.children.filter(
|
|
26046
|
-
(c) =>
|
|
26045
|
+
(c) => !isCommentOrWhitespace(c)
|
|
26047
26046
|
);
|
|
26048
26047
|
const child = children[0];
|
|
26049
26048
|
return children.length !== 1 || child.type === 11 || child.type === 9 && child.branches.some(hasMultipleChildren);
|
|
@@ -26622,6 +26621,8 @@ var CompilerDOM = /*#__PURE__*/Object.freeze({
|
|
|
26622
26621
|
hasScopeRef: hasScopeRef,
|
|
26623
26622
|
helperNameMap: helperNameMap,
|
|
26624
26623
|
injectProp: injectProp,
|
|
26624
|
+
isAllWhitespace: isAllWhitespace,
|
|
26625
|
+
isCommentOrWhitespace: isCommentOrWhitespace,
|
|
26625
26626
|
isCoreComponent: isCoreComponent,
|
|
26626
26627
|
isFnExpression: isFnExpression,
|
|
26627
26628
|
isFnExpressionBrowser: isFnExpressionBrowser,
|
|
@@ -26643,6 +26644,7 @@ var CompilerDOM = /*#__PURE__*/Object.freeze({
|
|
|
26643
26644
|
isText: isText$1,
|
|
26644
26645
|
isVPre: isVPre,
|
|
26645
26646
|
isVSlot: isVSlot,
|
|
26647
|
+
isWhitespaceText: isWhitespaceText,
|
|
26646
26648
|
locStub: locStub,
|
|
26647
26649
|
noopDirectiveTransform: noopDirectiveTransform,
|
|
26648
26650
|
parse: parse$3,
|
|
@@ -33046,11 +33048,11 @@ const ssrTransformModel = (dir, node, context) => {
|
|
|
33046
33048
|
}
|
|
33047
33049
|
if (node.tagType === 0) {
|
|
33048
33050
|
const res = { props: [] };
|
|
33049
|
-
const defaultProps = [
|
|
33050
|
-
// default value binding for text type inputs
|
|
33051
|
-
createObjectProperty(`value`, model)
|
|
33052
|
-
];
|
|
33053
33051
|
if (node.tag === "input") {
|
|
33052
|
+
const defaultProps = [
|
|
33053
|
+
// default value binding for text type inputs
|
|
33054
|
+
createObjectProperty(`value`, model)
|
|
33055
|
+
];
|
|
33054
33056
|
const type = findProp(node, "type");
|
|
33055
33057
|
if (type) {
|
|
33056
33058
|
const value = findValueBinding(node);
|
|
@@ -50630,7 +50632,7 @@ var __spreadValues = (a, b) => {
|
|
|
50630
50632
|
}
|
|
50631
50633
|
return a;
|
|
50632
50634
|
};
|
|
50633
|
-
const version = "3.5.
|
|
50635
|
+
const version = "3.5.25";
|
|
50634
50636
|
const parseCache = parseCache$1;
|
|
50635
50637
|
const errorMessages = __spreadValues(__spreadValues({}, errorMessages$1), DOMErrorMessages);
|
|
50636
50638
|
const walk = walk$2;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vue/compiler-sfc",
|
|
3
|
-
"version": "3.5.
|
|
3
|
+
"version": "3.5.25",
|
|
4
4
|
"description": "@vue/compiler-sfc",
|
|
5
5
|
"main": "dist/compiler-sfc.cjs.js",
|
|
6
6
|
"module": "dist/compiler-sfc.esm-browser.js",
|
|
@@ -47,10 +47,10 @@
|
|
|
47
47
|
"magic-string": "^0.30.21",
|
|
48
48
|
"postcss": "^8.5.6",
|
|
49
49
|
"source-map-js": "^1.2.1",
|
|
50
|
-
"@vue/compiler-core": "3.5.
|
|
51
|
-
"@vue/compiler-
|
|
52
|
-
"@vue/compiler-
|
|
53
|
-
"@vue/shared": "3.5.
|
|
50
|
+
"@vue/compiler-core": "3.5.25",
|
|
51
|
+
"@vue/compiler-ssr": "3.5.25",
|
|
52
|
+
"@vue/compiler-dom": "3.5.25",
|
|
53
|
+
"@vue/shared": "3.5.25"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"@babel/types": "^7.28.5",
|