From ffab1251e2fd0dfbf67a27e2a6e1610881bb2f73 Mon Sep 17 00:00:00 2001 From: Erik Lieben Date: Sun, 9 Oct 2016 20:03:18 +0200 Subject: [PATCH] feat(syntax): tokenize replace-part with replace-part.attribute.html.au --- syntaxes/html.json | 13 +- test/syntax.html/replace-part.test.ts | 188 ++++++++++++++++++++++++++ 2 files changed, 200 insertions(+), 1 deletion(-) create mode 100644 test/syntax.html/replace-part.test.ts diff --git a/syntaxes/html.json b/syntaxes/html.json index 370342b0..58870822 100644 --- a/syntaxes/html.json +++ b/syntaxes/html.json @@ -181,6 +181,9 @@ { "include": "#tag-aurelia-containerless-attribute" }, + { + "include": "#tag-aurelia-replace-part-attribute" + }, { "include": "#tag-aurelia-bindable-attribute" }, @@ -384,9 +387,17 @@ "name": "ref.attribute.html.au" }, "tag-aurelia-attribute": { - "match": "[^=-]\\b(as-element|replace-part)", + "match": "[^=-]\\b(as-element)", "name": "attribute.html.au" }, + "tag-aurelia-replace-part-attribute": { + "match": "(? { + + it(`must tokenize (replace-part)="item-template" attribute with scope "replace-part.attribute.html.au"`, () => { + + // arrange + let scope = 'replace-part.attribute.html.au'; + + // act + let lineToken = tokenizeLine('