Skip to content

Commit cb29e3c

Browse files
JessicaJHeedatho7561
authored andcommitted
Syntax coloration for operator in #case section
Signed-off-by: Jessica He <[email protected]>
1 parent 69e6afa commit cb29e3c

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

language-support/qute/qute.tmLanguage.json

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@
2626
{
2727
"include": "#section_start_for_tag"
2828
},
29+
{
30+
"include": "#section_start_case_is_tag"
31+
},
2932
{
3033
"include": "#section_start_default_tag"
3134
},
@@ -245,6 +248,35 @@
245248
}
246249
]
247250
},
251+
"section_start_case_is_tag": {
252+
"begin": "({)(#)((case|is)\\b)",
253+
"end": "(})",
254+
"beginCaptures": {
255+
"1": {
256+
"name": "support.constant.qute"
257+
},
258+
"2": {
259+
"name": "keyword.control"
260+
},
261+
"3": {
262+
"name": "keyword.control"
263+
}
264+
},
265+
"endCaptures": {
266+
"1": {
267+
"name": "support.constant.qute"
268+
}
269+
},
270+
"patterns": [
271+
{
272+
"match": "(?<={(#case|#is)\\s+)(gt|ge|lt|le|not|ne|in|ni|!in|>|>=|<|<=|!=)(?=\\s+\\w+)",
273+
"name": "keyword.operator.qute"
274+
},
275+
{
276+
"include": "#code"
277+
}
278+
]
279+
},
248280
"section_start_user_tag": {
249281
"begin": "({)(#)(\\w+(\\.\\w+)*)",
250282
"end": "(\\/)?((?<![\\\\])})",

0 commit comments

Comments
 (0)