vscode-css-languageservice 4.3.0-next.3 → 4.3.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/CHANGELOG.md +1 -1
- package/lib/esm/parser/scssParser.js +14 -5
- package/lib/umd/parser/scssParser.js +14 -5
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
-
4.3.0 -
|
|
3
|
+
4.3.0 - 2020-06-26
|
|
4
4
|
===================
|
|
5
5
|
* module resolving in urls (`~foo/hello.html`) when using `LanguageService.findDocumentLinks2` and if `fileSystemProvider` is provided.
|
|
6
6
|
* new API `LanguageService.doComplete2`. Support path completion if `fileSystemProvider.readDirectory` is provided.
|
|
@@ -85,11 +85,17 @@ var SCSSParser = /** @class */ (function (_super) {
|
|
|
85
85
|
if (!node.setValue(this._parseExpr())) {
|
|
86
86
|
return this.finish(node, ParseError.VariableValueExpected, [], panic);
|
|
87
87
|
}
|
|
88
|
-
while (this.
|
|
89
|
-
if (
|
|
90
|
-
|
|
88
|
+
while (this.peek(TokenType.Exclamation)) {
|
|
89
|
+
if (node.addChild(this._tryParsePrio())) {
|
|
90
|
+
// !important
|
|
91
|
+
}
|
|
92
|
+
else {
|
|
93
|
+
this.consumeToken();
|
|
94
|
+
if (!this.peekRegExp(TokenType.Ident, /^(default|global)$/)) {
|
|
95
|
+
return this.finish(node, ParseError.UnknownKeyword);
|
|
96
|
+
}
|
|
97
|
+
this.consumeToken();
|
|
91
98
|
}
|
|
92
|
-
this.consumeToken();
|
|
93
99
|
}
|
|
94
100
|
if (this.peek(TokenType.SemiColon)) {
|
|
95
101
|
node.semicolonPosition = this.token.offset; // not part of the declaration, but useful information for code assist
|
|
@@ -170,7 +176,7 @@ var SCSSParser = /** @class */ (function (_super) {
|
|
|
170
176
|
return this._parseModuleMember() ||
|
|
171
177
|
this._parseVariable() ||
|
|
172
178
|
this._parseSelectorCombinator() ||
|
|
173
|
-
this._tryParsePrio() ||
|
|
179
|
+
//this._tryParsePrio() ||
|
|
174
180
|
_super.prototype._parseTermExpression.call(this);
|
|
175
181
|
};
|
|
176
182
|
SCSSParser.prototype._parseInterpolation = function () {
|
|
@@ -628,6 +634,9 @@ var SCSSParser = /** @class */ (function (_super) {
|
|
|
628
634
|
node.addChild(this._parsePrio()); // #9859
|
|
629
635
|
return this.finish(node);
|
|
630
636
|
}
|
|
637
|
+
else if (node.setValue(this._tryParsePrio())) {
|
|
638
|
+
return this.finish(node);
|
|
639
|
+
}
|
|
631
640
|
return null;
|
|
632
641
|
};
|
|
633
642
|
SCSSParser.prototype._parseURLArgument = function () {
|
|
@@ -95,11 +95,17 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
95
95
|
if (!node.setValue(this._parseExpr())) {
|
|
96
96
|
return this.finish(node, cssErrors_1.ParseError.VariableValueExpected, [], panic);
|
|
97
97
|
}
|
|
98
|
-
while (this.
|
|
99
|
-
if (
|
|
100
|
-
|
|
98
|
+
while (this.peek(cssScanner_1.TokenType.Exclamation)) {
|
|
99
|
+
if (node.addChild(this._tryParsePrio())) {
|
|
100
|
+
// !important
|
|
101
|
+
}
|
|
102
|
+
else {
|
|
103
|
+
this.consumeToken();
|
|
104
|
+
if (!this.peekRegExp(cssScanner_1.TokenType.Ident, /^(default|global)$/)) {
|
|
105
|
+
return this.finish(node, cssErrors_1.ParseError.UnknownKeyword);
|
|
106
|
+
}
|
|
107
|
+
this.consumeToken();
|
|
101
108
|
}
|
|
102
|
-
this.consumeToken();
|
|
103
109
|
}
|
|
104
110
|
if (this.peek(cssScanner_1.TokenType.SemiColon)) {
|
|
105
111
|
node.semicolonPosition = this.token.offset; // not part of the declaration, but useful information for code assist
|
|
@@ -180,7 +186,7 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
180
186
|
return this._parseModuleMember() ||
|
|
181
187
|
this._parseVariable() ||
|
|
182
188
|
this._parseSelectorCombinator() ||
|
|
183
|
-
this._tryParsePrio() ||
|
|
189
|
+
//this._tryParsePrio() ||
|
|
184
190
|
_super.prototype._parseTermExpression.call(this);
|
|
185
191
|
};
|
|
186
192
|
SCSSParser.prototype._parseInterpolation = function () {
|
|
@@ -638,6 +644,9 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
638
644
|
node.addChild(this._parsePrio()); // #9859
|
|
639
645
|
return this.finish(node);
|
|
640
646
|
}
|
|
647
|
+
else if (node.setValue(this._tryParsePrio())) {
|
|
648
|
+
return this.finish(node);
|
|
649
|
+
}
|
|
641
650
|
return null;
|
|
642
651
|
};
|
|
643
652
|
SCSSParser.prototype._parseURLArgument = function () {
|
package/package.json
CHANGED