Skip to content

Commit 1f40ffb

Browse files
committed
Fix (and also simplify) broken grammar
1 parent 50e2c9c commit 1f40ffb

File tree

1 file changed

+8
-21
lines changed

1 file changed

+8
-21
lines changed

syntaxes/ng.inline.tmLanguage.json

Lines changed: 8 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -5,30 +5,17 @@
55
"injectionSelector": "L:source -string -comment",
66
"patterns": [
77
{
8-
"include": "#component"
8+
"include": "#template"
9+
},
10+
{
11+
"include": "#styles"
912
}
1013
],
1114
"repository": {
12-
"component": {
13-
"name": "meta.component.decoration",
14-
"begin": "@\\s*Component\\s*\\(\\s*\\{",
15-
"end": "\\}\\s*\\)",
16-
"patterns": [
17-
{
18-
"include": "#template"
19-
},
20-
{
21-
"include": "#styles"
22-
},
23-
{
24-
"include": "source.ts"
25-
}
26-
]
27-
},
2815
"template": {
2916
"name": "meta.template.property",
30-
"begin": "(?<=template)\\s*:\\s*`",
31-
"end": "`\\s*",
17+
"begin": "(?<=template:)\\s*`",
18+
"end": "`",
3219
"patterns": [
3320
{
3421
"name": "meta.inline.template",
@@ -52,15 +39,15 @@
5239
},
5340
"styles": {
5441
"name": "meta.styles.property",
55-
"begin": "(?<=styles)\\s*:\\s*\\[",
42+
"begin": "(?<=styles:)\\s*\\[",
5643
"end": "\\]",
5744
"patterns": [
5845
{
59-
"name": "meta.inline.style",
6046
"begin": "`",
6147
"end": "`",
6248
"patterns": [
6349
{
50+
"name": "meta.inline.style",
6451
"include": "source.css"
6552
}
6653
]

0 commit comments

Comments
 (0)