Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed scss function arguments on different lines in maps #9128 #9184

13 changes: 13 additions & 0 deletions src/language-css/parser-postcss.js
Expand Up @@ -120,6 +120,19 @@ function parseValueNode(valueNode, options) {
parenGroupStack.pop();
parenGroup = parenGroupStack[parenGroupStack.length - 1];
} else if (node.type === "comma") {
if (commaGroup.groups.length > 1) {
for (const group of commaGroup.groups) {
// if css interpolation
if (group.value &&
typeof group.value === "string" &&
group.value.includes("#{")) {
commaGroup.groups = [stringifyNode({
groups: commaGroup.groups,
}).trim()];
break;
}
}
}
parenGroup.groups.push(commaGroup);
commaGroup = {
groups: [],
Expand Down