diff options
Diffstat (limited to 'queries/gsp')
-rw-r--r-- | queries/gsp/folds.scm | 3 | ||||
-rw-r--r-- | queries/gsp/highlights.scm | 13 | ||||
-rw-r--r-- | queries/gsp/textobjects.scm | 3 |
3 files changed, 10 insertions, 9 deletions
diff --git a/queries/gsp/folds.scm b/queries/gsp/folds.scm index e15d359..c70d5dc 100644 --- a/queries/gsp/folds.scm +++ b/queries/gsp/folds.scm @@ -1,4 +1,5 @@ [ + (comment) (node) - (attribute_list) + (attr_list) ] @fold diff --git a/queries/gsp/highlights.scm b/queries/gsp/highlights.scm index 92e61f6..bc81edb 100644 --- a/queries/gsp/highlights.scm +++ b/queries/gsp/highlights.scm @@ -1,12 +1,9 @@ -[">" "-" "=" "@"] @operator +["-" "=" "@"] @operator ["{" "}"] @tag.delimiter -(node_name) @tag -[ - (attribute_name) - (class_shorthand) - (id_shorthand) -] @tag.attribute -(attribute_value) @string +(node name: (ident) @tag) +[(id_attr) (class_attr)] @tag.attribute +(attr name: (ident) @tag.attribute) +(string) @string (comment) @comment ([_] @comment (#has-ancestor? @comment comment)) diff --git a/queries/gsp/textobjects.scm b/queries/gsp/textobjects.scm index 53db443..4f735ce 100644 --- a/queries/gsp/textobjects.scm +++ b/queries/gsp/textobjects.scm @@ -1,3 +1,6 @@ (node) @node.outer (node_body) @node.inner (text) @text.outer +(comment) @comment.outer +(comment (_+) @comment.inner) +[(id_attr) (class_attr) (attr)] @attribute.outer |