vscode-css-languageservice 5.2.0 → 5.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 CHANGED
@@ -1,4 +1,8 @@
1
1
 
2
+ 5.3.0 / 2022-03-23
3
+ ==================
4
+ * renamed `CSSFormatConfiguration.selectorSeparatorNewline` to `CSSFormatConfiguration.newlineBetweenSelectors`
5
+
2
6
  5.2.0 / 2022-03-17
3
7
  ==================
4
8
  * new API `LanguageService.format`, based on the the css formatter from JS Beautifier (https://github.com/beautify-web/js-beautify)
@@ -217,10 +217,12 @@ export interface CSSFormatConfiguration {
217
217
  insertSpaces?: boolean;
218
218
  /** end with a newline: Default: false */
219
219
  insertFinalNewline?: boolean;
220
- /** separate selectors with newline or not (e.g. "a,\nbr" or "a, br"): Default: true */
221
- selectorSeparatorNewline?: boolean;
220
+ /** separate selectors with newline (e.g. "a,\nbr" or "a, br"): Default: true */
221
+ newlineBetweenSelectors?: boolean;
222
222
  /** add a new line after every css rule: Default: true */
223
223
  newlineBetweenRules?: boolean;
224
224
  /** ensure space around selector separators: '>', '+', '~' (e.g. "a>b" -> "a > b"): Default: false */
225
225
  spaceAroundSelectorSeparator?: boolean;
226
+ /** @deprecated Use newlineBetweenSelectors instead*/
227
+ selectorSeparatorNewline?: boolean;
226
228
  }
@@ -61,7 +61,7 @@ export function format(document, range, options) {
61
61
  indent_size: tabSize,
62
62
  indent_char: options.insertSpaces ? ' ' : '\t',
63
63
  end_with_newline: includesEnd && getFormatOption(options, 'insertFinalNewline', false),
64
- selector_separator_newline: getFormatOption(options, 'selectorSeparatorNewline', true),
64
+ selector_separator_newline: getFormatOption(options, 'newlineBetweenSelectors', true),
65
65
  newline_between_rules: getFormatOption(options, 'newlineBetweenRules', true),
66
66
  space_around_selector_separator: getFormatOption(options, 'spaceAroundSelectorSeparator', false)
67
67
  };
@@ -217,10 +217,12 @@ export interface CSSFormatConfiguration {
217
217
  insertSpaces?: boolean;
218
218
  /** end with a newline: Default: false */
219
219
  insertFinalNewline?: boolean;
220
- /** separate selectors with newline or not (e.g. "a,\nbr" or "a, br"): Default: true */
221
- selectorSeparatorNewline?: boolean;
220
+ /** separate selectors with newline (e.g. "a,\nbr" or "a, br"): Default: true */
221
+ newlineBetweenSelectors?: boolean;
222
222
  /** add a new line after every css rule: Default: true */
223
223
  newlineBetweenRules?: boolean;
224
224
  /** ensure space around selector separators: '>', '+', '~' (e.g. "a>b" -> "a > b"): Default: false */
225
225
  spaceAroundSelectorSeparator?: boolean;
226
+ /** @deprecated Use newlineBetweenSelectors instead*/
227
+ selectorSeparatorNewline?: boolean;
226
228
  }
@@ -73,7 +73,7 @@
73
73
  indent_size: tabSize,
74
74
  indent_char: options.insertSpaces ? ' ' : '\t',
75
75
  end_with_newline: includesEnd && getFormatOption(options, 'insertFinalNewline', false),
76
- selector_separator_newline: getFormatOption(options, 'selectorSeparatorNewline', true),
76
+ selector_separator_newline: getFormatOption(options, 'newlineBetweenSelectors', true),
77
77
  newline_between_rules: getFormatOption(options, 'newlineBetweenRules', true),
78
78
  space_around_selector_separator: getFormatOption(options, 'spaceAroundSelectorSeparator', false)
79
79
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vscode-css-languageservice",
3
- "version": "5.2.0",
3
+ "version": "5.3.0",
4
4
  "description": "Language service for CSS, LESS and SCSS",
5
5
  "main": "./lib/umd/cssLanguageService.js",
6
6
  "typings": "./lib/umd/cssLanguageService",