From 1aa0fc4cea2b631483cdad989dc8f56d58869783 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=87=E5=A4=A9?= Date: Sun, 16 Dec 2018 16:45:28 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=AF=E6=8C=81html=E6=A8=A1=E6=9D=BF?= =?UTF-8?q?=E4=B8=ADmvvm=E6=8C=87=E4=BB=A4=E9=AB=98=E4=BA=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 3 +++ package.json | 2 +- src/html.js | 20 ++++++++++++++++++++ themes/color-theme.json | 14 ++++++++++++++ 4 files changed, 38 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3334860..beeada3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # 更新日志 +## [1.3.3] 2018-12-16 +- 支持html模板中mvvm指令高亮 + ## [1.3.2] 2018-12-12 - 移除ts的异常语法高亮 diff --git a/package.json b/package.json index 1a7420b..f2f1bce 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "displayName": "米白色主题", "description": "🔥 米白色主题", "icon": "logo.png", - "version": "1.3.2", + "version": "1.3.3", "publisher": "yutent", "author": "Yutent [@yutent]", "engines": { diff --git a/src/html.js b/src/html.js index 9937f9c..9074003 100644 --- a/src/html.js +++ b/src/html.js @@ -1,3 +1,5 @@ +const vars = require('./var') + module.exports = [ { name: 'HTML Attributes', @@ -25,5 +27,23 @@ module.exports = [ settings: { foreground: '#6182B8' } + }, + { + name: 'directive', + scope: [ + 'text.html.derivative meta.attribute.unrecognized entity.other.attribute-name.html' + ], + settings: { + foreground: vars.yellow1 + } + }, + { + name: "directive's value", + scope: [ + 'text.html.derivative meta.attribute.unrecognized string.quoted.double.html' + ], + settings: { + foreground: vars.magenta1 + } } ] diff --git a/themes/color-theme.json b/themes/color-theme.json index 4888aa4..b818e1a 100644 --- a/themes/color-theme.json +++ b/themes/color-theme.json @@ -482,6 +482,20 @@ "foreground": "#6182B8" } }, + { + "name": "directive", + "scope": "text.html.derivative meta.attribute.unrecognized entity.other.attribute-name.html", + "settings": { + "foreground": "#f39c12" + } + }, + { + "name": "directive's value", + "scope": "text.html.derivative meta.attribute.unrecognized string.quoted.double.html", + "settings": { + "foreground": "#be7ee7" + } + }, { "name": "Class extends, build-in, dom", "scope": "support.type.object.console.js, support.type.object.module.js, support.type.object.dom.js, support.constant.math, meta.class.extends.js variable.other.readwrite.js, meta.function-call.static.without-arguments.js variable.other.class.js, meta.function-call.static.with-arguments.js variable.other.class.js, meta.property.class.js variable.other.class.js",