mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-01 11:06:54 -04:00
Add TSTag and TSTagDelimiter groups
These groups will be added for use with xml-like tags such as html and jsx.
This commit is contained in:
parent
b4abf6b07d
commit
c366a041c8
3 changed files with 15 additions and 2 deletions
|
|
@ -164,6 +164,15 @@ Mainly for markup languages.
|
|||
@text.uri
|
||||
```
|
||||
|
||||
#### Tags
|
||||
|
||||
Used for xml-like tags
|
||||
|
||||
```
|
||||
@tag
|
||||
@tag.delimiter
|
||||
```
|
||||
|
||||
### Locals
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -68,6 +68,10 @@ hlmap["text.title"] = "TSTitle"
|
|||
hlmap["text.literal"] = "TSLiteral"
|
||||
hlmap["text.uri"] = "TSURI"
|
||||
|
||||
-- Tags
|
||||
hlmap["tag"] = "TSTag"
|
||||
hlmap["tag.delimiter"] = "TSTagDelimiter"
|
||||
|
||||
hlmap["none"] = "TSNone"
|
||||
|
||||
function M.attach(bufnr, lang)
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
(tag_name) @type
|
||||
(tag_name) @tag
|
||||
(erroneous_end_tag_name) @error
|
||||
(doctype) @constant
|
||||
(attribute_name) @property
|
||||
|
|
@ -13,4 +13,4 @@
|
|||
">"
|
||||
"</"
|
||||
"/>"
|
||||
] @punctuation.bracket
|
||||
] @tag.delimiter
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue