diff options
author | Blaž Hrastnik | 2022-02-13 09:31:51 +0000 |
---|---|---|
committer | Blaž Hrastnik | 2022-02-13 09:31:51 +0000 |
commit | bd549d8a20cce98e24c8653a4a86107c786cbaa3 (patch) | |
tree | 0780b58d41b6181e69023265cdb54517e2953778 /runtime/queries/elm/highlights.scm | |
parent | 7ad8eaaef0b292f4be6c66298cea40d2b928e172 (diff) | |
parent | 7083b98a388b30e0b61caac9bf6ccc1d79eadf81 (diff) |
Merge remote-tracking branch 'origin/master' into debug
Diffstat (limited to 'runtime/queries/elm/highlights.scm')
-rw-r--r-- | runtime/queries/elm/highlights.scm | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/runtime/queries/elm/highlights.scm b/runtime/queries/elm/highlights.scm new file mode 100644 index 00000000..3c8fd12d --- /dev/null +++ b/runtime/queries/elm/highlights.scm @@ -0,0 +1,83 @@ +; Keywords +[ + "if" + "then" + "else" + "let" + "in" + ] @keyword.control +(case) @keyword.control +(of) @keyword.control + +(colon) @keyword.operator +(backslash) @keyword +(as) @keyword +(port) @keyword +(exposing) @keyword +(alias) @keyword +(infix) @keyword + +(arrow) @keyword.operator +(dot) @keyword.operator + +(port) @keyword + +(type_annotation(lower_case_identifier) @function) +(port_annotation(lower_case_identifier) @function) +(file (value_declaration (function_declaration_left(lower_case_identifier) @function))) + +(field name: (lower_case_identifier) @attribute) +(field_access_expr(lower_case_identifier) @attribute) + +(operator_identifier) @keyword.operator +(eq) @keyword.operator.assignment + +[ + "(" + ")" + "[" + "]" + "{" + "}" +] @punctuation.bracket + +"|" @keyword +"," @punctuation.delimiter + +[ + "|>" +] @keyword + + +(import) @keyword.contol.import +(module) @keyword.other + +(number_constant_expr) @constant.numeric + +(type) @type + +(type_declaration(upper_case_identifier) @type) +(type_ref) @type +(type_alias_declaration name: (upper_case_identifier) @type) + +(union_pattern constructor: (upper_case_qid (upper_case_identifier) @label (dot) (upper_case_identifier) @variable.other.member)) +(union_pattern constructor: (upper_case_qid (upper_case_identifier) @variable.other.member)) + +(union_variant(upper_case_identifier) @variable.other.member) +(value_expr name: (value_qid (upper_case_identifier) @label)) +(value_expr (upper_case_qid (upper_case_identifier) @label (dot) (upper_case_identifier) @variable.other.member)) +(value_expr(upper_case_qid(upper_case_identifier)) @variable.other.member) + +; comments +(line_comment) @comment +(block_comment) @comment + +; strings +(string_escape) @constant.character.escape + +(open_quote) @string +(close_quote) @string +(regular_string_part) @string + +(open_char) @constant.character +(close_char) @constant.character |