Skip to content

Commit ba48f5c

Browse files
committed
Update to match new enum
1 parent c5d3ad0 commit ba48f5c

File tree

3 files changed

+8
-13
lines changed

3 files changed

+8
-13
lines changed

extensions/html-language-features/package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,16 +42,16 @@
4242
"type": "string",
4343
"scope": "resource",
4444
"enum": [
45-
"doubleQuotes",
46-
"singleQuotes",
45+
"doublequotes",
46+
"singlequotes",
4747
"empty"
4848
],
4949
"enumDescriptions": [
50-
"%html.completion.attributeDefaultValue.doubleQuotes%",
51-
"%html.completion.attributeDefaultValue.singleQuotes%",
50+
"%html.completion.attributeDefaultValue.doublequotes%",
51+
"%html.completion.attributeDefaultValue.singlequotes%",
5252
"%html.completion.attributeDefaultValue.empty%"
5353
],
54-
"default": "doubleQuotes",
54+
"default": "doublequotes",
5555
"description": "%html.completion.attributeDefaultValue%"
5656
},
5757
"html.customData": {

extensions/html-language-features/package.nls.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@
2929
"html.validate.styles": "Controls whether the built-in HTML language support validates embedded styles.",
3030
"html.autoClosingTags": "Enable/disable autoclosing of HTML tags.",
3131
"html.completion.attributeDefaultValue": "Controls the default value for attributes when completion is accepted.",
32-
"html.completion.attributeDefaultValue.doubleQuotes": "Attribute value is set to \"\".",
33-
"html.completion.attributeDefaultValue.singleQuotes": "Attribute value is set to ''.",
32+
"html.completion.attributeDefaultValue.doublequotes": "Attribute value is set to \"\".",
33+
"html.completion.attributeDefaultValue.singlequotes": "Attribute value is set to ''.",
3434
"html.completion.attributeDefaultValue.empty": "Attribute value is not set.",
3535
"html.mirrorCursorOnMatchingTag": "Enable/disable mirroring cursor on matching HTML tag.",
3636
"html.mirrorCursorOnMatchingTagDeprecationMessage": "Deprecated in favor of `editor.linkedEditing`",

extensions/html-language-features/server/src/modes/htmlMode.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,7 @@ export function getHTMLMode(htmlLanguageService: HTMLLanguageService, workspace:
2626
if (doAutoComplete) {
2727
options.hideAutoCompleteProposals = true;
2828
}
29-
let attributeDefaultValue = settings && settings.html && settings.html.completion.attributeDefaultValue;
30-
if (attributeDefaultValue === 'empty') {
31-
options.useEmptyAttrValue = true;
32-
} else if (attributeDefaultValue === 'singleQuotes') {
33-
options.useSingleQuotesForAttrs = true;
34-
}
29+
options.attributeDefaultValue = settings.html.completion.attributeDefaultValue ?? 'doublequotes';
3530

3631
const htmlDocument = htmlDocuments.get(document);
3732
let completionList = htmlLanguageService.doComplete2(document, position, htmlDocument, documentContext, options);

0 commit comments

Comments
 (0)