diff options
Diffstat (limited to 'runtime/queries/_jsx/highlights.scm')
-rw-r--r-- | runtime/queries/_jsx/highlights.scm | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/runtime/queries/_jsx/highlights.scm b/runtime/queries/_jsx/highlights.scm index 00641cde..853254e5 100644 --- a/runtime/queries/_jsx/highlights.scm +++ b/runtime/queries/_jsx/highlights.scm @@ -4,9 +4,6 @@ (jsx_opening_element ((identifier) @constructor (#match? @constructor "^[A-Z]"))) -; Handle the dot operator effectively - <My.Component> -(jsx_opening_element ((nested_identifier (identifier) @tag (identifier) @constructor))) - (jsx_opening_element (identifier) @tag) ; Closing elements @@ -15,9 +12,6 @@ (jsx_closing_element ((identifier) @constructor (#match? @constructor "^[A-Z]"))) -; Handle the dot operator effectively - </My.Component> -(jsx_closing_element ((nested_identifier (identifier) @tag (identifier) @constructor))) - (jsx_closing_element (identifier) @tag) ; Self-closing elements @@ -26,9 +20,6 @@ (jsx_self_closing_element ((identifier) @constructor (#match? @constructor "^[A-Z]"))) -; Handle the dot operator effectively - <My.Component /> -(jsx_self_closing_element ((nested_identifier (identifier) @tag (identifier) @constructor))) - (jsx_self_closing_element (identifier) @tag) ; Attributes @@ -39,17 +30,14 @@ ; Punctuation ; ----------- -; Handle attribute delimiter +; Handle attribute delimiter (<Component color="red"/>) (jsx_attribute "=" @punctuation.delimiter) ; <Component> (jsx_opening_element ["<" ">"] @punctuation.bracket) ; </Component> -(jsx_closing_element ["<" "/" ">"] @punctuation.bracket) +(jsx_closing_element ["</" ">"] @punctuation.bracket) ; <Component /> -(jsx_self_closing_element ["<" "/" ">"] @punctuation.bracket) - -; <> ... </> -(jsx_fragment ["<" "/" ">"] @punctuation.bracket) +(jsx_self_closing_element ["<" "/>"] @punctuation.braket) |