From 6098527e1f314fb223f72e72fee61ffb174f89c8 Mon Sep 17 00:00:00 2001 From: roydukkey Date: Tue, 6 Sep 2022 09:26:00 -0400 Subject: [PATCH] feat: uniquely scope attribute shorthands --- .../syntaxes/vue.tmLanguage.json | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/extensions/vscode-vue-language-features/syntaxes/vue.tmLanguage.json b/extensions/vscode-vue-language-features/syntaxes/vue.tmLanguage.json index eae4ddb72..9a34c9c72 100644 --- a/extensions/vscode-vue-language-features/syntaxes/vue.tmLanguage.json +++ b/extensions/vscode-vue-language-features/syntaxes/vue.tmLanguage.json @@ -885,19 +885,19 @@ ] }, "vue-directives-original": { - "begin": "(?:\\b(v-)|(:|@|#))(\\[?)([\\w\\-]*)(\\]?)(?:\\.([\\w\\-]*))*", + "begin": "(?:\\b(v-)|(:)|(@)|(#))(\\[?)([\\w\\-]*)(\\]?)(?:\\.([\\w\\-]*))*", "beginCaptures": { "1": { "name": "entity.other.attribute-name.html.vue" }, "2": { - "name": "punctuation.separator.key-value.html.vue" + "name": "punctuation.attribute-shorthand.bind.html.vue" }, "3": { - "name": "punctuation.separator.key-value.html.vue" + "name": "punctuation.attribute-shorthand.event.html.vue" }, "4": { - "name": "entity.other.attribute-name.html.vue" + "name": "punctuation.attribute-shorthand.slot.html.vue" }, "5": { "name": "punctuation.separator.key-value.html.vue" @@ -907,6 +907,12 @@ }, "7": { "name": "punctuation.separator.key-value.html.vue" + }, + "8": { + "name": "entity.other.attribute-name.html.vue" + }, + "9": { + "name": "punctuation.separator.key-value.html.vue" } }, "end": "(?=\\s*+[^=\\s])",