chore: query formatting

This commit is contained in:
Pham Huy Hoang 2024-01-06 15:05:50 +09:00 committed by Christian Clason
parent 79975d6557
commit 57a8acf0c4
674 changed files with 18466 additions and 12648 deletions

View file

@ -1,5 +1,4 @@
; Folds
[
(node)
(node_children)

View file

@ -1,58 +1,70 @@
; Types
(node (identifier) @type)
(node
(identifier) @type)
(type) @type
(annotation_type) @type.builtin
; Properties
(prop (identifier) @property)
(prop
(identifier) @property)
; Variables
(identifier) @variable
; Operators
[
"="
"+"
"-"
"="
"+"
"-"
] @operator
; Literals
(string) @string
(escape) @string.escape
(number) @number
(number (decimal) @number.float)
(number (exponent) @number.float)
(number
(decimal) @number.float)
(number
(exponent) @number.float)
(boolean) @boolean
"null" @constant.builtin
; Punctuation
["{" "}"] @punctuation.bracket
["(" ")"] @punctuation.bracket
[
"{"
"}"
] @punctuation.bracket
[
";"
] @punctuation.delimiter
"("
")"
] @punctuation.bracket
";" @punctuation.delimiter
; Comments
[
(single_line_comment)
(multi_line_comment)
] @comment @spell
(node (node_comment) (#set! "priority" 105)) @comment
(node (node_field (node_field_comment) (#set! "priority" 105)) @comment)
(node_children (node_children_comment) (#set! "priority" 105)) @comment
(node
(node_comment)
(#set! "priority" 105)) @comment
(node
(node_field
(node_field_comment)
(#set! "priority" 105)) @comment)
(node_children
(node_children_comment)
(#set! "priority" 105)) @comment

View file

@ -1,7 +1,14 @@
(node (node_children) @indent.begin)
(node
(node_children) @indent.begin)
"}" @indent.end
[ "{" "}" ] @indent.branch
[
"{"
"}"
] @indent.branch
[ "(" ")" ] @indent.branch
[
"("
")"
] @indent.branch

View file

@ -1,5 +1,5 @@
([
(single_line_comment)
(multi_line_comment)
] @injection.content
(#set! injection.language "comment"))
] @injection.content
(#set! injection.language "comment"))

View file

@ -1,10 +1,16 @@
(document) @local.scope
(node (node_children) @local.scope)
(node_children (node) @local.scope)
(node
(node_children) @local.scope)
(node_children
(node) @local.scope)
(identifier) @local.reference
(node_field) @local.definition.field
(node (identifier) @local.definition.type)
(node
(identifier) @local.definition.type)
(type) @local.definition.type