mirror of https://github.com/helix-editor/helix
Merge branch 'master' into force_move
commit
84ff01ed48
@ -0,0 +1 @@
|
||||
; inherits: yaml
|
@ -0,0 +1,4 @@
|
||||
(comment) @comment.inside
|
||||
|
||||
(comment)+ @comment.around
|
||||
|
@ -0,0 +1,6 @@
|
||||
(comment) @comment.inside
|
||||
|
||||
(comment)+ @comment.around
|
||||
|
||||
(variable_assignment
|
||||
(_) @entry.inside) @entry.around
|
@ -0,0 +1,8 @@
|
||||
([
|
||||
(line_comment)
|
||||
(block_comment_content)
|
||||
] @injection.content
|
||||
(#set! injection.language "comment"))
|
||||
|
||||
((xml_doc (xml_doc_content) @injection.content)
|
||||
(#set! injection.language "xml"))
|
@ -1,25 +1,32 @@
|
||||
; Scopes
|
||||
;-------
|
||||
(identifier) @local.reference
|
||||
|
||||
[
|
||||
(ce_expression)
|
||||
(module_defn)
|
||||
(for_expression)
|
||||
(do_expression)
|
||||
(fun_expression)
|
||||
(function_expression)
|
||||
(try_expression)
|
||||
(match_expression)
|
||||
(elif_expression)
|
||||
(if_expression)
|
||||
(namespace)
|
||||
(named_module)
|
||||
(function_or_value_defn)
|
||||
] @local.scope
|
||||
|
||||
; Definitions
|
||||
;------------
|
||||
|
||||
(function_or_value_defn) @local.definition
|
||||
|
||||
; References
|
||||
;-----------
|
||||
(value_declaration_left
|
||||
.
|
||||
[
|
||||
(_ (identifier) @local.definition)
|
||||
(_ (_ (identifier) @local.definition))
|
||||
(_ (_ (_ (identifier) @local.definition)))
|
||||
(_ (_ (_ (_ (identifier) @local.definition))))
|
||||
(_ (_ (_ (_ (_ (identifier) @local.definition)))))
|
||||
(_ (_ (_ (_ (_ (_ (identifier) @local.definition))))))
|
||||
])
|
||||
|
||||
(identifier) @local.reference
|
||||
(function_declaration_left
|
||||
.
|
||||
((_) @local.definition)
|
||||
((argument_patterns
|
||||
[
|
||||
(_ (identifier) @local.definition)
|
||||
(_ (_ (identifier) @local.definition))
|
||||
(_ (_ (_ (identifier) @local.definition)))
|
||||
(_ (_ (_ (_ (identifier) @local.definition))))
|
||||
(_ (_ (_ (_ (_ (identifier) @local.definition)))))
|
||||
(_ (_ (_ (_ (_ (_ (identifier) @local.definition))))))
|
||||
])
|
||||
))
|
||||
|
@ -0,0 +1,17 @@
|
||||
[
|
||||
(feature_keyword)
|
||||
(rule_keyword)
|
||||
(background_keyword)
|
||||
(scenario_keyword)
|
||||
(given_keyword)
|
||||
(when_keyword)
|
||||
(then_keyword)
|
||||
(and_keyword)
|
||||
(but_keyword)
|
||||
(asterisk_keyword)
|
||||
] @keyword
|
||||
|
||||
(tag) @function
|
||||
(doc_string) @string
|
||||
(data_table) @special
|
||||
(comment) @comment
|
@ -0,0 +1,6 @@
|
||||
(comment) @comment.inside
|
||||
|
||||
(comment)+ @comment.around
|
||||
|
||||
(variable
|
||||
(_) @entry.inside) @entry.around
|
@ -0,0 +1,10 @@
|
||||
(comment) @comment.inside
|
||||
|
||||
(comment)+ @comment.around
|
||||
|
||||
(pair
|
||||
(_) @entry.inside) @entry.around
|
||||
|
||||
(array
|
||||
(_) @entry.around)
|
||||
|
@ -0,0 +1,160 @@
|
||||
;; From nvim-treesitter, contributed by @ObserverOfTime et al.
|
||||
|
||||
; Variables
|
||||
(variable) @variable
|
||||
|
||||
((variable) @constant.builtin
|
||||
(#eq? @constant.builtin "$ENV"))
|
||||
|
||||
((variable) @constant.builtin
|
||||
(#eq? @constant.builtin "$__loc__"))
|
||||
|
||||
; Properties
|
||||
(index
|
||||
(identifier) @variable.other.member)
|
||||
|
||||
; Labels
|
||||
(query
|
||||
label: (variable) @label)
|
||||
|
||||
(query
|
||||
break_statement: (variable) @label)
|
||||
|
||||
; Literals
|
||||
(number) @constant.numeric
|
||||
|
||||
(string) @string
|
||||
|
||||
[
|
||||
"true"
|
||||
"false"
|
||||
] @constant.builtin.boolean
|
||||
|
||||
"null" @type.builtin
|
||||
|
||||
; Interpolation
|
||||
[
|
||||
"\\("
|
||||
")"
|
||||
] @special
|
||||
|
||||
; Format
|
||||
(format) @attribute
|
||||
|
||||
; Functions
|
||||
(funcdef
|
||||
(identifier) @function)
|
||||
|
||||
(funcdefargs
|
||||
(identifier) @variable.parameter)
|
||||
|
||||
[
|
||||
"reduce"
|
||||
"foreach"
|
||||
] @function.builtin
|
||||
|
||||
((funcname) @function
|
||||
.
|
||||
"(")
|
||||
|
||||
; jq -n 'builtins | map(split("/")[0]) | unique | .[]'
|
||||
((funcname) @function.builtin
|
||||
(#any-of? @function.builtin
|
||||
"IN" "INDEX" "JOIN" "abs" "acos" "acosh" "add" "all" "any" "arrays" "ascii_downcase"
|
||||
"ascii_upcase" "asin" "asinh" "atan" "atan2" "atanh" "booleans" "bsearch" "builtins" "capture"
|
||||
"cbrt" "ceil" "combinations" "contains" "copysign" "cos" "cosh" "debug" "del" "delpaths" "drem"
|
||||
"empty" "endswith" "env" "erf" "erfc" "error" "exp" "exp10" "exp2" "explode" "expm1" "fabs"
|
||||
"fdim" "finites" "first" "flatten" "floor" "fma" "fmax" "fmin" "fmod" "format" "frexp"
|
||||
"from_entries" "fromdate" "fromdateiso8601" "fromjson" "fromstream" "gamma" "get_jq_origin"
|
||||
"get_prog_origin" "get_search_list" "getpath" "gmtime" "group_by" "gsub" "halt" "halt_error"
|
||||
"has" "hypot" "implode" "in" "index" "indices" "infinite" "input" "input_filename"
|
||||
"input_line_number" "inputs" "inside" "isempty" "isfinite" "isinfinite" "isnan" "isnormal"
|
||||
"iterables" "j0" "j1" "jn" "join" "keys" "keys_unsorted" "last" "ldexp" "length" "lgamma"
|
||||
"lgamma_r" "limit" "localtime" "log" "log10" "log1p" "log2" "logb" "ltrimstr" "map" "map_values"
|
||||
"match" "max" "max_by" "min" "min_by" "mktime" "modf" "modulemeta" "nan" "nearbyint" "nextafter"
|
||||
"nexttoward" "normals" "not" "now" "nth" "nulls" "numbers" "objects" "path" "paths" "pick" "pow"
|
||||
"pow10" "range" "recurse" "remainder" "repeat" "reverse" "rindex" "rint" "round" "rtrimstr"
|
||||
"scalars" "scalb" "scalbln" "scan" "select" "setpath" "significand" "sin" "sinh" "sort"
|
||||
"sort_by" "split" "splits" "sqrt" "startswith" "stderr" "strflocaltime" "strftime" "strings"
|
||||
"strptime" "sub" "tan" "tanh" "test" "tgamma" "to_entries" "todate" "todateiso8601" "tojson"
|
||||
"tonumber" "tostream" "tostring" "transpose" "trunc" "truncate_stream" "type" "unique"
|
||||
"unique_by" "until" "utf8bytelength" "values" "walk" "while" "with_entries" "y0" "y1" "yn"))
|
||||
|
||||
; Keywords
|
||||
[
|
||||
"def"
|
||||
"as"
|
||||
"label"
|
||||
"module"
|
||||
"break"
|
||||
] @keyword
|
||||
|
||||
[
|
||||
"import"
|
||||
"include"
|
||||
] @keyword.control.import
|
||||
|
||||
[
|
||||
"if"
|
||||
"then"
|
||||
"elif"
|
||||
"else"
|
||||
"end"
|
||||
] @keyword.control.conditional
|
||||
|
||||
[
|
||||
"try"
|
||||
"catch"
|
||||
] @keyword.control.exception
|
||||
|
||||
[
|
||||
"or"
|
||||
"and"
|
||||
] @keyword.operator
|
||||
|
||||
; Operators
|
||||
[
|
||||
"."
|
||||
"=="
|
||||
"!="
|
||||
">"
|
||||
">="
|
||||
"<="
|
||||
"<"
|
||||
"="
|
||||
"+"
|
||||
"-"
|
||||
"*"
|
||||
"/"
|
||||
"%"
|
||||
"+="
|
||||
"-="
|
||||
"*="
|
||||
"/="
|
||||
"%="
|
||||
"//="
|
||||
"|"
|
||||
"?"
|
||||
"//"
|
||||
"?//"
|
||||
(recurse) ; ".."
|
||||
] @operator
|
||||
|
||||
; Punctuation
|
||||
[
|
||||
";"
|
||||
","
|
||||
":"
|
||||
] @punctuation.delimiter
|
||||
|
||||
[
|
||||
"["
|
||||
"]"
|
||||
"{"
|
||||
"}"
|
||||
"("
|
||||
")"
|
||||
] @punctuation.bracket
|
||||
|
||||
; Comments
|
||||
(comment) @comment.line
|
@ -0,0 +1,25 @@
|
||||
;; From nvim-treesitter, contributed by @ObserverOfTime et al.
|
||||
|
||||
((comment) @injection.content
|
||||
(#set! injection.language "comment"))
|
||||
|
||||
; test(val)
|
||||
(query
|
||||
((funcname) @_function
|
||||
(#any-of? @_function "test" "match" "capture" "scan" "split" "splits" "sub" "gsub"))
|
||||
(args
|
||||
.
|
||||
(query
|
||||
(string) @injection.content
|
||||
(#set! injection.language "regex"))))
|
||||
|
||||
; test(regex; flags)
|
||||
(query
|
||||
((funcname) @_function
|
||||
(#any-of? @_function "test" "match" "capture" "scan" "split" "splits" "sub" "gsub"))
|
||||
(args
|
||||
.
|
||||
(args
|
||||
(query
|
||||
(string) @injection.content
|
||||
(#set! injection.language "regex")))))
|
@ -0,0 +1,12 @@
|
||||
;; From nvim-treesitter, contributed by @ObserverOfTime et al.
|
||||
|
||||
(funcdef
|
||||
(identifier) @local.definition)
|
||||
|
||||
(funcdefargs
|
||||
(identifier) @local.definition)
|
||||
|
||||
(funcname) @local.reference
|
||||
|
||||
(index
|
||||
(identifier) @local.reference)
|
@ -0,0 +1,8 @@
|
||||
(comment) @comment.inside
|
||||
(comment)+ @comment.around
|
||||
|
||||
(funcdef
|
||||
(query) @function.inside) @function.around
|
||||
|
||||
(objectkeyval
|
||||
(_) @entry.inside) @entry.around
|
@ -1,18 +1,19 @@
|
||||
; From <https://github.com/IndianBoy42/tree-sitter-just/blob/6c2f018ab1d90946c0ce029bb2f7d57f56895dff/queries-flavored/helix/textobjects.scm>
|
||||
;
|
||||
; Specify how to navigate around logical blocks in code
|
||||
|
||||
(assert_parameters
|
||||
((_) @parameter.inside . ","? @parameter.around)) @parameter.around
|
||||
|
||||
(recipe
|
||||
(recipe_body) @function.inside) @function.around
|
||||
|
||||
(parameters
|
||||
(recipe_parameters
|
||||
((_) @parameter.inside . ","? @parameter.around)) @parameter.around
|
||||
|
||||
(dependency_expression
|
||||
(recipe_dependency
|
||||
(_) @parameter.inside) @parameter.around
|
||||
|
||||
(function_call
|
||||
arguments: (sequence
|
||||
(expression) @parameter.inside) @parameter.around) @function.around
|
||||
(function_parameters
|
||||
((_) @parameter.inside . ","? @parameter.around)) @parameter.around) @function.around
|
||||
|
||||
(comment) @comment.around
|
||||
|
@ -0,0 +1,17 @@
|
||||
(model_declaration
|
||||
((statement_block) @class.inside)) @class.around
|
||||
|
||||
(call_expression
|
||||
(arguments (_) @parameter.inside . ","? @parameter.around) @parameter.around)
|
||||
|
||||
(column_declaration) @entry.around
|
||||
|
||||
(array (_) @entry.around)
|
||||
|
||||
(assignment_expression
|
||||
(_) @entry.inside) @entry.around
|
||||
|
||||
(developer_comment) @comment.inside
|
||||
|
||||
(developer_comment)+ @comment.around
|
||||
|
@ -0,0 +1,4 @@
|
||||
(comment) @comment.inside
|
||||
|
||||
(comment)+ @comment.around
|
||||
|
@ -0,0 +1,12 @@
|
||||
[
|
||||
(annotation_definition)
|
||||
(enum_definition)
|
||||
(exception_definition)
|
||||
(function_definition)
|
||||
(senum_definition)
|
||||
(service_definition)
|
||||
(struct_definition)
|
||||
(union_definition)
|
||||
|
||||
(comment)
|
||||
] @fold
|
@ -0,0 +1,211 @@
|
||||
; Variables
|
||||
|
||||
((identifier) @variable)
|
||||
|
||||
; Includes
|
||||
|
||||
[
|
||||
"include"
|
||||
"cpp_include"
|
||||
] @keyword
|
||||
|
||||
; Function
|
||||
|
||||
(function_definition
|
||||
(identifier) @function)
|
||||
|
||||
; Fields
|
||||
|
||||
(field (identifier) @variable.other.member)
|
||||
|
||||
; Parameters
|
||||
|
||||
(function_definition
|
||||
(parameters
|
||||
(parameter (identifier) @variable.parameter)))
|
||||
|
||||
(throws
|
||||
(parameters
|
||||
(parameter (identifier) @keyword.control.exception)))
|
||||
|
||||
; Types
|
||||
|
||||
(typedef_identifier) @type
|
||||
(struct_definition
|
||||
"struct" (identifier) @type)
|
||||
|
||||
(union_definition
|
||||
"union" (identifier) @type)
|
||||
|
||||
(exception_definition
|
||||
"exception" (identifier) @type)
|
||||
|
||||
(service_definition
|
||||
"service" (identifier) @type)
|
||||
|
||||
(interaction_definition
|
||||
"interaction" (identifier) @type)
|
||||
|
||||
(type
|
||||
type: (identifier) @type)
|
||||
|
||||
(definition_type
|
||||
type: (identifier) @type)
|
||||
|
||||
; Constants
|
||||
|
||||
(const_definition (identifier) @constant)
|
||||
|
||||
(enum_definition "enum"
|
||||
. (identifier) @type
|
||||
"{" (identifier) @constant "}")
|
||||
|
||||
; Builtin Types
|
||||
|
||||
(primitive) @type.builtin
|
||||
|
||||
[
|
||||
"list"
|
||||
"map"
|
||||
"set"
|
||||
"sink"
|
||||
"stream"
|
||||
"void"
|
||||
] @type.builtin
|
||||
|
||||
; Namespace
|
||||
|
||||
(namespace_declaration
|
||||
(namespace_scope) @tag
|
||||
[(namespace) @namespace (_ (identifier) @namespace)])
|
||||
|
||||
; Attributes
|
||||
|
||||
(annotation_definition
|
||||
(annotation_identifier (identifier) @attribute))
|
||||
(fb_annotation_definition
|
||||
"@" @attribute (annotation_identifier (identifier) @attribute)
|
||||
(identifier)? @attribute)
|
||||
(namespace_uri (string) @attribute)
|
||||
|
||||
; Operators
|
||||
|
||||
[
|
||||
"="
|
||||
"&"
|
||||
] @operator
|
||||
|
||||
; Exceptions
|
||||
|
||||
[
|
||||
"throws"
|
||||
] @keyword.control.exception
|
||||
|
||||
; Keywords
|
||||
|
||||
[
|
||||
"enum"
|
||||
"exception"
|
||||
"extends"
|
||||
"interaction"
|
||||
"namespace"
|
||||
"senum"
|
||||
"service"
|
||||
"struct"
|
||||
"typedef"
|
||||
"union"
|
||||
"uri"
|
||||
] @keyword
|
||||
|
||||
; Deprecated Keywords
|
||||
|
||||
[
|
||||
"cocoa_prefix"
|
||||
"cpp_namespace"
|
||||
"csharp_namespace"
|
||||
"delphi_namespace"
|
||||
"java_package"
|
||||
"perl_package"
|
||||
"php_namespace"
|
||||
"py_module"
|
||||
"ruby_namespace"
|
||||
"smalltalk_category"
|
||||
"smalltalk_prefix"
|
||||
"xsd_all"
|
||||
"xsd_attrs"
|
||||
"xsd_namespace"
|
||||
"xsd_nillable"
|
||||
"xsd_optional"
|
||||
] @keyword
|
||||
|
||||
; Extended Kewords
|
||||
[
|
||||
"package"
|
||||
"performs"
|
||||
] @keyword
|
||||
|
||||
[
|
||||
"async"
|
||||
"oneway"
|
||||
] @keyword
|
||||
|
||||
; Qualifiers
|
||||
|
||||
[
|
||||
"client"
|
||||
"const"
|
||||
"idempotent"
|
||||
"optional"
|
||||
"permanent"
|
||||
"readonly"
|
||||
"required"
|
||||
"safe"
|
||||
"server"
|
||||
"stateful"
|
||||
"transient"
|
||||
] @type.directive
|
||||
|
||||
; Literals
|
||||
|
||||
(string) @string
|
||||
|
||||
(escape_sequence) @constant.character.escape
|
||||
|
||||
(namespace_uri
|
||||
(string) @string.special)
|
||||
|
||||
(number) @constant.numeric.integer
|
||||
|
||||
(double) @constant.numeric.float
|
||||
|
||||
(boolean) @constant.builtin.boolean
|
||||
|
||||
; Typedefs
|
||||
|
||||
(typedef_identifier) @type.definition
|
||||
|
||||
; Punctuation
|
||||
|
||||
[
|
||||
"*"
|
||||
] @punctuation.special
|
||||
|
||||
["{" "}"] @punctuation.bracket
|
||||
|
||||
["(" ")"] @punctuation.bracket
|
||||
|
||||
["[" "]"] @punctuation.bracket
|
||||
|
||||
["<" ">"] @punctuation.bracket
|
||||
|
||||
[
|
||||
"."
|
||||
","
|
||||
";"
|
||||
":"
|
||||
] @punctuation.delimiter
|
||||
|
||||
; Comments
|
||||
|
||||
(comment) @comment
|
||||
|
@ -0,0 +1,2 @@
|
||||
((comment) @injection.content
|
||||
(#set! injection.language "comment"))
|
@ -0,0 +1,51 @@
|
||||
; Scopes
|
||||
|
||||
[
|
||||
(document)
|
||||
(definition)
|
||||
] @local.scope
|
||||
|
||||
; References
|
||||
|
||||
(identifier) @local.reference
|
||||
|
||||
; Definitions
|
||||
|
||||
(annotation_identifier) @local.definition
|
||||
|
||||
; (const_definition (identifier) @definition.constant)
|
||||
|
||||
; (enum_definition "enum"
|
||||
; . (identifier) @definition.enum
|
||||
; "{" (identifier) @definition.constant "}")
|
||||
|
||||
; (senum_definition "senum"
|
||||
; . (identifier) @definition.enum)
|
||||
|
||||
; (field (identifier) @definition.field)
|
||||
|
||||
; (function_definition (identifier) @definition.function)
|
||||
|
||||
; (namespace_declaration
|
||||
; "namespace" (namespace_scope)
|
||||
; . (_) @definition.namespace
|
||||
; (namespace_uri)?)
|
||||
|
||||
; (parameter (identifier) @definition.parameter)
|
||||
|
||||
; (struct_definition
|
||||
; "struct" . (identifier) @definition.type)
|
||||
|
||||
; (union_definition
|
||||
; "union" . (identifier) @definition.type)
|
||||
|
||||
; (exception_definition
|
||||
; "exception" . (identifier) @definition.type)
|
||||
|
||||
; (service_definition
|
||||
; "service" . (identifier) @definition.type)
|
||||
|
||||
; (interaction_definition
|
||||
; "interaction" . (identifier) @definition.type)
|
||||
|
||||
; (typedef_identifier) @definition.type
|
@ -0,0 +1,177 @@
|
||||
; Keywords
|
||||
|
||||
[
|
||||
"is"
|
||||
"extends"
|
||||
"valueof"
|
||||
] @keyword.operator
|
||||
|
||||
[
|
||||
"namespace"
|
||||
"scalar"
|
||||
"interface"
|
||||
"alias"
|
||||
] @keyword
|
||||
|
||||
[
|
||||
"model"
|
||||
"enum"
|
||||
"union"
|
||||
] @keyword.storage.type
|
||||
|
||||
[
|
||||
"op"
|
||||
"fn"
|
||||
"dec"
|
||||
] @keyword.function
|
||||
|
||||
"extern" @keyword.storage.modifier
|
||||
|
||||
[
|
||||
"import"
|
||||
"using"
|
||||
] @keyword.control.import
|
||||
|
||||
[
|
||||
"("
|
||||
")"
|
||||
"{"
|
||||
"}"
|
||||
"<"
|
||||
">"
|
||||
"["
|
||||
"]"
|
||||
] @punctuation.bracket
|
||||
|
||||
[
|
||||
","
|
||||
";"
|
||||
"."
|
||||
":"
|
||||
] @punctuation.delimiter
|
||||
|
||||
[
|
||||
"|"
|
||||
"&"
|
||||
"="
|
||||
"..."
|
||||
] @operator
|
||||
|
||||
"?" @punctuation.special
|
||||
|
||||
; Imports
|
||||
|
||||
(import_statement
|
||||
(quoted_string_literal) @string.special.path)
|
||||
|
||||
; Namespaces
|
||||
|
||||
(using_statement
|
||||
module: (identifier_or_member_expression) @namespace)
|
||||
|
||||
(namespace_statement
|
||||
name: (identifier_or_member_expression) @namespace)
|
||||
|
||||
; Comments
|
||||
|
||||
[
|
||||
(single_line_comment)
|
||||
] @comment.line
|
||||
|
||||
[
|
||||
(multi_line_comment)
|
||||
] @comment.block
|
||||
|
||||
; Decorators
|
||||
|
||||
(decorator
|
||||
"@" @attribute
|
||||
name: (identifier_or_member_expression) @attribute)
|
||||
|
||||
(augment_decorator_statement
|
||||
name: (identifier_or_member_expression) @attribute)
|
||||
|
||||
(decorator
|
||||
(decorator_arguments) @variable.parameter)
|
||||
|
||||
; Scalars
|
||||
|
||||
(scalar_statement
|
||||
name: (identifier) @type)
|
||||
|
||||
; Models
|
||||
|
||||
(model_statement
|
||||
name: (identifier) @type)
|
||||
|
||||
(model_property
|
||||
name: (identifier) @variable.other.member)
|
||||
|
||||
; Operations
|
||||
|
||||
(operation_statement
|
||||
name: (identifier) @function.method)
|
||||
|
||||
(operation_arguments
|
||||
(model_property
|
||||
name: (identifier) @variable.parameter))
|
||||
|
||||
(template_parameter
|
||||
name: (identifier) @type.parameter)
|
||||
|
||||
(function_parameter
|
||||
name: (identifier) @variable.parameter)
|
||||
|
||||
; Interfaces
|
||||
|
||||
(interface_statement
|
||||
name: (identifier) @type)
|
||||
|
||||
(interface_statement
|
||||
(interface_body
|
||||
(interface_member
|
||||
(identifier) @function.method)))
|
||||
|
||||
; Enums
|
||||
|
||||
(enum_statement
|
||||
name: (identifier) @type.enum)
|
||||
|
||||
(enum_member
|
||||
name: (identifier) @constant)
|
||||
|
||||
; Unions
|
||||
|
||||
(union_statement
|
||||
name: (identifier) @type)
|
||||
|
||||
(union_variant
|
||||
name: (identifier) @type.enum.variant)
|
||||
|
||||
; Aliases
|
||||
|
||||
(alias_statement
|
||||
name: (identifier) @type)
|
||||
|
||||
; Built-in types
|
||||
|
||||
[
|
||||
(quoted_string_literal)
|
||||
(triple_quoted_string_literal)
|
||||
] @string
|
||||
|
||||
(escape_sequence) @constant.character.escape
|
||||
|
||||
(boolean_literal) @constant.builtin.boolean
|
||||
|
||||
[
|
||||
(decimal_literal)
|
||||
(hex_integer_literal)
|
||||
(binary_integer_literal)
|
||||
] @constant.numeric.integer
|
||||
|
||||
(builtin_type) @type.builtin
|
||||
|
||||
; Identifiers
|
||||
|
||||
(identifier_or_member_expression) @type
|
@ -0,0 +1,18 @@
|
||||
[
|
||||
(model_expression)
|
||||
(tuple_expression)
|
||||
(namespace_body)
|
||||
(interface_body)
|
||||
(union_body)
|
||||
(enum_body)
|
||||
(template_arguments)
|
||||
(template_parameters)
|
||||
(operation_arguments)
|
||||
] @indent.begin
|
||||
|
||||
[
|
||||
"}"
|
||||
")"
|
||||
">"
|
||||
"]"
|
||||
] @indent.end
|
@ -0,0 +1,5 @@
|
||||
([
|
||||
(single_line_comment)
|
||||
(multi_line_comment)
|
||||
] @injection.content
|
||||
(#set! injection.language "comment"))
|
@ -0,0 +1,51 @@
|
||||
; Classes
|
||||
|
||||
(enum_statement
|
||||
(enum_body) @class.inside) @class.around
|
||||
|
||||
(model_statement
|
||||
(model_expression) @class.inside) @class.around
|
||||
|
||||
(union_statement
|
||||
(union_body) @class.inside) @class.around
|
||||
|
||||
; Interfaces
|
||||
|
||||
(interface_statement
|
||||
(interface_body
|
||||
(interface_member) @function.around) @class.inside) @class.around
|
||||
|
||||
; Comments
|
||||
|
||||
[
|
||||
(single_line_comment)
|
||||
(multi_line_comment)
|
||||
] @comment.inside
|
||||
|
||||
[
|
||||
(single_line_comment)
|
||||
(multi_line_comment)
|
||||
]+ @comment.around
|
||||
|
||||
; Functions
|
||||
|
||||
[
|
||||
(decorator)
|
||||
(decorator_declaration_statement)
|
||||
(function_declaration_statement)
|
||||
(operation_statement)
|
||||
] @function.around
|
||||
|
||||
(function_parameter_list
|
||||
(function_parameter)? @parameter.inside)* @function.inside
|
||||
|
||||
(decorator_arguments
|
||||
(expression_list
|
||||
(_) @parameter.inside)*) @function.inside
|
||||
|
||||
(operation_arguments
|
||||
(model_property)? @parameter.inside)* @function.inside
|
||||
|
||||
(template_parameters
|
||||
(template_parameter_list
|
||||
(template_parameter) @parameter.inside)) @function.inside
|
@ -0,0 +1,7 @@
|
||||
(comment) @comment.inside
|
||||
|
||||
(comment)+ @comment.around
|
||||
|
||||
(block_mapping_pair
|
||||
(_) @entry.inside) @entry.around
|
||||
|
@ -0,0 +1,128 @@
|
||||
# Author : Chromo-residuum-opec <development.0extl@simplelogin.com>
|
||||
|
||||
"attribute" = { fg = "green" }
|
||||
"boolean" = { fg = "purple" }
|
||||
"character" = { fg = "purple" }
|
||||
"comment" = { fg = "comment_fg" }
|
||||
"conditional" = { fg = "blue" }
|
||||
"constant" = { fg = "purple" }
|
||||
"constructor" = { fg = "blue" }
|
||||
"diagnostic.deprecated" = { modifiers = ["crossed_out"] }
|
||||
"diagnostic.error" = { underline = { style = "curl", color = "red" } }
|
||||
"diagnostic.hint" = { underline = { style = "curl", color = "comment_fg" } }
|
||||
"diagnostic.info" = { underline = { style = "curl", color = "cyan" } }
|
||||
"diagnostic.unnecessary" = { modifiers = ["dim"] }
|
||||
"diagnostic.warning" = { underline = { style = "curl", color = "orange" } }
|
||||
"diff.delta" = { fg = "blue" }
|
||||
"diff.delta.gutter" = { fg = "cyan", bg = "linenr_bg" }
|
||||
"diff.minus" = { fg = "red" }
|
||||
"diff.minus.gutter" = { fg = "red", bg = "linenr_bg" }
|
||||
"diff.plus" = { fg = "green" }
|
||||
"diff.plus.gutter" = { fg = "green", bg = "linenr_bg" }
|
||||
"error" = { fg = "red" }
|
||||
"exception" = { fg = "blue" }
|
||||
"field" = { fg = "background_fg" }
|
||||
"float" = { fg = "purple" }
|
||||
"function" = { fg = "pale" }
|
||||
"function.macro" = { fg = "green" }
|
||||
"hint" = { fg = "comment_fg" }
|
||||
"identifier" = { fg = "blue" }
|
||||
"info" = { fg = "cyan" }
|
||||
"keyword" = { fg = "blue" }
|
||||
"keyword.directive" = { fg = "green" }
|
||||
"keyword.import" = { fg = "pale" }
|
||||
"label" = { fg = "green" }
|
||||
"markup.bold" = { modifiers = ["bold"] }
|
||||
"markup.heading" = { fg = "blue", modifiers = ["bold"] }
|
||||
"markup.italic" = { modifiers = ["italic"] }
|
||||
"markup.link" = { fg = "blue", underline = { style = "line" } }
|
||||
"markup.link.label" = { fg = "cyan" }
|
||||
"markup.link.text" = { fg = "cyan" }
|
||||
"markup.link.url" = { underline = { style = "line" } }
|
||||
"markup.list" = { fg = "orange", modifiers = ["bold"] }
|
||||
"markup.raw" = { fg = "cyan" }
|
||||
"markup.raw.inline" = { bg = "black", fg = "blue" }
|
||||
"markup.strikethrough" = { modifiers = ["crossed_out"] }
|
||||
"method" = { fg = "pale" }
|
||||
"namespace" = { fg = "blue" }
|
||||
"number" = { fg = "purple" }
|
||||
"operator" = { fg = "blue" }
|
||||
"parameter" = { fg = "background_fg" }
|
||||
"property" = { fg = "background_fg" }
|
||||
"punctuation.bracket" = { fg = "background_fg" }
|
||||
"punctuation.delimiter" = { fg = "background_fg" }
|
||||
"punctuation.special" = { fg = "green" }
|
||||
"repeat" = { fg = "blue" }
|
||||
"special" = { fg = "green" }
|
||||
"string" = { fg = "cyan" }
|
||||
"string.escape" = { fg = "green" }
|
||||
"string.special" = { fg = "green" }
|
||||
"tag" = { fg = "blue" }
|
||||
"tag.attribute" = { fg = "purple" }
|
||||
"text" = { fg = "background_fg" }
|
||||
"type" = { fg = "blue" }
|
||||
"ui.background" = { fg = "background_fg", bg = "background_bg" }
|
||||
"ui.background.separator" = { fg = "comment_fg" }
|
||||
"ui.bufferline.active" = { fg = "pale" }
|
||||
"ui.cursor.match" = { fg = "background_fg", bg = "matchparen_bg" }
|
||||
"ui.cursor.normal" = { bg = "gray" }
|
||||
"ui.cursor.primary" = { modifiers = ["reversed"] }
|
||||
"ui.cursor.select" = { bg = "gray" }
|
||||
"ui.gutter" = { fg = "linenr_fg", bg = "linenr_bg" }
|
||||
"ui.help" = { fg = "background_fg", bg = "cursorlinenr_bg" }
|
||||
"ui.linenr" = { fg = "linenr_fg", bg = "linenr_bg" }
|
||||
"ui.menu" = { fg = "background_fg", bg = "cursorlinenr_bg" }
|
||||
"ui.menu.border" = { fg = "comment_fg" }
|
||||
"ui.menu.selected" = { fg = "menusel_fg", bg = "menusel_bg" }
|
||||
"ui.popup" = { fg = "background_fg", bg = "cursorlinenr_bg" }
|
||||
"ui.popup.info" = { fg = "blue" }
|
||||
"ui.selection" = { bg = "sel_bg" }
|
||||
"ui.statusline" = { bg = "statusline_bg", fg = "statusline_fg" }
|
||||
"ui.statusline.insert" = { fg = "black", bg = "blue" }
|
||||
"ui.statusline.select" = { fg = "black", bg = "green" }
|
||||
"ui.text.focus" = { fg = "orange" }
|
||||
"ui.virtual" = { fg = "linenr_fg" }
|
||||
"ui.virtual.indent-guide" = { fg = "linenr_fg" }
|
||||
"ui.virtual.jump-label" = { fg = "orange", modifiers = ["bold"] }
|
||||
"ui.virtual.ruler" = { bg = "linenr_bg" }
|
||||
"ui.virtual.whitespace" = { fg = "sel_bg" }
|
||||
"ui.window" = { fg = "comment_fg", modifiers = ["bold"] }
|
||||
"variable" = { fg = "background_fg" }
|
||||
"variable.builtin" = { fg = "blue" }
|
||||
"warning" = { fg = "orange" }
|
||||
|
||||
[palette]
|
||||
|
||||
orange = "#e2a578"
|
||||
pale = "#a4aecc"
|
||||
purple = "#a093c8"
|
||||
|
||||
black = "#1e2132"
|
||||
gray = "#6b7089"
|
||||
red = "#e27878"
|
||||
light-red = "#e98989"
|
||||
green = "#b5bf82"
|
||||
light-green = "#c0ca8e"
|
||||
yellow = "#e2a478"
|
||||
light-yellow = "#e9b189"
|
||||
blue = "#85a0c7"
|
||||
light-blue = "#91acd1"
|
||||
magenta = "#a093c7"
|
||||
light-magenta = "#ada0d3"
|
||||
cyan = "#89b9c2"
|
||||
light-cyan = "#95c4ce"
|
||||
white = "#c6c8d1"
|
||||
light-gray = "#d2d4de"
|
||||
|
||||
background_bg = "#161822"
|
||||
background_fg = "#c7c9d1"
|
||||
comment_fg = "#6c7189"
|
||||
cursorlinenr_bg = "#3d425c"
|
||||
linenr_bg = "#1f2233"
|
||||
linenr_fg = "#454d73"
|
||||
matchparen_bg = "#3f455f"
|
||||
menusel_bg = "#5c638a"
|
||||
menusel_fg = "#f0f1f5"
|
||||
sel_bg = "#282d43"
|
||||
statusline_bg = "#0f1117"
|
||||
statusline_fg = "#828597"
|
@ -0,0 +1,39 @@
|
||||
# Author : Chromo-residuum-opec <development.0extl@simplelogin.com>
|
||||
|
||||
inherits = "iceberg-dark"
|
||||
"ui.menu.selected" = { fg = "background_fg", bg = "menusel_bg" }
|
||||
|
||||
[palette]
|
||||
|
||||
orange = "#c67439"
|
||||
pale = "#505695"
|
||||
purple = "#785ab5"
|
||||
|
||||
black = "#dcdfe7"
|
||||
gray = "#8389a3"
|
||||
red = "#cd517a"
|
||||
light-red = "#cc3768"
|
||||
green = "#668f3d"
|
||||
light-green = "#598030"
|
||||
yellow = "#c57339"
|
||||
light-yellow = "#b6662d"
|
||||
blue = "#2e539e"
|
||||
light-blue = "#22478e"
|
||||
magenta = "#7759b4"
|
||||
light-magenta = "#6845ad"
|
||||
cyan = "#3f84a6"
|
||||
light-cyan = "#327698"
|
||||
white = "#33374c"
|
||||
light-gray = "#262a3f"
|
||||
|
||||
background_bg = "#e9e9ed"
|
||||
background_fg = "#33374d"
|
||||
comment_fg = "#8489a4"
|
||||
cursorlinenr_bg = "#cccfe0"
|
||||
linenr_bg = "#dddfe9"
|
||||
linenr_fg = "#a0a5c0"
|
||||
matchparen_bg = "#bec0ca"
|
||||
menusel_bg = "#a9afd1"
|
||||
sel_bg = "#cacdd8"
|
||||
statusline_bg = "#cad0de"
|
||||
statusline_fg = "#757da3"
|
Loading…
Reference in New Issue