From a71358d170a91bece79c994dce07c1f163eecff3 Mon Sep 17 00:00:00 2001 From: ObserverOfTime Date: Sat, 22 Oct 2022 14:02:16 +0300 Subject: [PATCH] highlights(elm): use more specific groups --- queries/elm/highlights.scm | 28 ++++++++++++++++++---------- 1 file changed, 18 insertions(+), 10 deletions(-) diff --git a/queries/elm/highlights.scm b/queries/elm/highlights.scm index 4d644ac63..63514eb3e 100644 --- a/queries/elm/highlights.scm +++ b/queries/elm/highlights.scm @@ -36,11 +36,14 @@ "}" ] @punctuation.bracket -(type_annotation(lower_case_identifier) @function) -(port_annotation(lower_case_identifier) @function) -(function_declaration_left(lower_case_identifier) @function) -(function_call_expr target: - (value_expr) @function) +(type_annotation + (lower_case_identifier) @function) +(port_annotation + (lower_case_identifier) @function) +(function_declaration_left + (lower_case_identifier) @function) +(function_call_expr + target: (value_expr) @function) (value_qid (upper_case_identifier) @constructor) (value_qid ((dot) (lower_case_identifier) @field)) @@ -67,16 +70,21 @@ (type) @keyword -(module_declaration(upper_case_qid(upper_case_identifier)) @constructor) -(type_declaration(upper_case_identifier) @constructor) +(module_declaration + (upper_case_qid (upper_case_identifier)) @constructor) +(type_declaration + (upper_case_identifier) @constructor) (type_ref) @type -(type_alias_declaration name: (upper_case_identifier) @type) +(type_alias_declaration + name: (upper_case_identifier) @type.definition) (field_type name: (lower_case_identifier) @property) -(union_variant(upper_case_identifier) @symbol) +(union_variant + (upper_case_identifier) @symbol) (union_pattern) @symbol -(value_expr(upper_case_qid(upper_case_identifier)) @symbol) +(value_expr + (upper_case_qid (upper_case_identifier)) @symbol) ; strings (string_escape) @string