nvim/after/queries/html/highlights.scm

21 lines
723 B
Scheme

;extends
; HTML class attribute values - should match CSS .class-name color
; Priority: Must override default @string capture (priority 99)
(attribute
(attribute_name) @ClassNameAttribute (#eq? @ClassNameAttribute "class")
(quoted_attribute_value
(attribute_value) @CssClassName (#set! priority 200)))
; HTML id attribute values - should match CSS #id-name color
(attribute
(attribute_name) @IdAttribute (#eq? @IdAttribute "id")
(quoted_attribute_value
(attribute_value) @CssIdentifier (#set! priority 200)))
; HTML data-* attributes
(attribute
(attribute_name) @DataAttribute (#match? @DataAttribute "^data-")
(quoted_attribute_value
(attribute_value) @DataAttributeValue (#set! priority 200)))