/
HTML-grit.sublime-syntax
45 lines (41 loc) · 1.06 KB
/
HTML-grit.sublime-syntax
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
%YAML 1.2
---
name: HTML (+Grit)
file_extensions:
- html
- htm
- shtml
- xhtml
- inc
- tmpl
- tpl
first_line_match: (?i)<(!DOCTYPE\s*)?html
scope: text.html.basic.grit
contexts:
main:
- match: ''
push: Packages/HTML/HTML.sublime-syntax
with_prototype:
- include: disabled-preprocessor-block
- include: enabled-preprocessor-block
disabled-preprocessor-block:
- match: <if expr="False">
scope: keyword.control.preprocessor.disabled
push:
- clear_scopes: true
- meta_content_scope: comment.block.preprocessor.disabled
- include: nested-within-disabled-preprocessor-block
- match: </if>
scope: keyword.control.preprocessor.disabled
pop: true
nested-within-disabled-preprocessor-block:
- match: <if[^>]*>
push:
- include: nested-within-disabled-preprocessor-block
- match: </if>
pop: true
enabled-preprocessor-block:
- match: <if[^>]*>
scope: keyword.control.preprocessor
- match: </if>
scope: keyword.control.preprocessor