Skip to content

Commit 8e8ea08

Browse files
committed
Fix syntax highlighting for @tailwind utilities source(…)
1 parent 2967129 commit 8e8ea08

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

packages/vscode-tailwindcss/syntaxes/at-rules.tmLanguage.json

+22
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@
2828
{
2929
"include": "source.css#escapes"
3030
},
31+
{
32+
"include": "#source-fn"
33+
},
3134
{
3235
"match": "[^\\s;]+?",
3336
"name": "variable.parameter.tailwind.tailwind"
@@ -446,6 +449,25 @@
446449
"name": "punctuation.terminator.rule.css"
447450
}
448451
]
452+
},
453+
"source-fn": {
454+
"patterns": [
455+
{
456+
"begin": "(?i)(source)[(](?=.*?[)])",
457+
"beginCaptures": {
458+
"1": {
459+
"name": "punctuation.definition.keyword.css"
460+
}
461+
},
462+
"name": "variable.parameter.tailwind.source",
463+
"end": "(?<=[)])(?!\\G)",
464+
"patterns": [
465+
{
466+
"include": "source.css#string"
467+
}
468+
]
469+
}
470+
]
449471
}
450472
}
451473
}

0 commit comments

Comments
 (0)