Skip to content

Commit ecce42b

Browse files
Highlight @theme contents as a rule list (#937)
* Highlight `@theme` contents as a rule list * Update changelog
1 parent cf97d7a commit ecce42b

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

Diff for: packages/vscode-tailwindcss/CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
- Add support for `<script type="text/babel">` (#932)
99
- Show pixel equivalents in completions and hovers of the theme() helper (#935)
1010
- Handle `style` exports condition when processing `@import`s (#934)
11+
- Highlight `@theme` contents as a rule list (#937)
1112

1213
## 0.10.5
1314

Diff for: packages/vscode-tailwindcss/syntaxes/at-rules.tmLanguage.json

+17
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,23 @@
124124
}
125125
]
126126
},
127+
{
128+
"begin": "(?i)((@)theme)(?=[\\s{]|/\\*|$)",
129+
"beginCaptures": {
130+
"1": {
131+
"name": "keyword.control.at-rule.theme.tailwind"
132+
},
133+
"2": {
134+
"name": "punctuation.definition.keyword.css"
135+
}
136+
},
137+
"end": "(?<=}|;)(?!\\G)",
138+
"patterns": [
139+
{
140+
"include": "source.css#rule-list"
141+
}
142+
]
143+
},
127144
{
128145
"begin": "(?i)((@)variants)(?=[\\s{]|/\\*|$)",
129146
"beginCaptures": {

0 commit comments

Comments
 (0)