mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-17 02:40:09 -04:00
chore: query formatting
This commit is contained in:
parent
79975d6557
commit
57a8acf0c4
674 changed files with 18466 additions and 12648 deletions
|
|
@ -1,56 +1,61 @@
|
|||
; Comments
|
||||
((comment) @injection.content
|
||||
(#set! injection.language "comment"))
|
||||
((comment) @injection.content
|
||||
(#set! injection.language "comment"))
|
||||
|
||||
; Documentation
|
||||
(unary_operator
|
||||
operator: "@"
|
||||
operand: (call
|
||||
target: ((identifier) @_identifier (#any-of? @_identifier "moduledoc" "typedoc" "shortdoc" "doc"))
|
||||
(arguments [
|
||||
(string (quoted_content) @injection.content)
|
||||
(sigil (quoted_content) @injection.content)
|
||||
])
|
||||
(#set! injection.language "markdown")))
|
||||
operand:
|
||||
(call
|
||||
target:
|
||||
((identifier) @_identifier
|
||||
(#any-of? @_identifier "moduledoc" "typedoc" "shortdoc" "doc"))
|
||||
(arguments
|
||||
[
|
||||
(string
|
||||
(quoted_content) @injection.content)
|
||||
(sigil
|
||||
(quoted_content) @injection.content)
|
||||
])
|
||||
(#set! injection.language "markdown")))
|
||||
|
||||
; HEEx
|
||||
(sigil
|
||||
(sigil_name) @_sigil_name
|
||||
(quoted_content) @injection.content
|
||||
(#eq? @_sigil_name "H")
|
||||
(#set! injection.language "heex"))
|
||||
(#eq? @_sigil_name "H")
|
||||
(#set! injection.language "heex"))
|
||||
|
||||
; Surface
|
||||
(sigil
|
||||
(sigil_name) @_sigil_name
|
||||
(quoted_content) @injection.content
|
||||
(#eq? @_sigil_name "F")
|
||||
(#set! injection.language "surface"))
|
||||
(#eq? @_sigil_name "F")
|
||||
(#set! injection.language "surface"))
|
||||
|
||||
; Zigler
|
||||
(sigil
|
||||
(sigil_name) @_sigil_name
|
||||
(quoted_content) @injection.content
|
||||
(#any-of? @_sigil_name "E" "L")
|
||||
(#set! injection.language "eex"))
|
||||
(#any-of? @_sigil_name "E" "L")
|
||||
(#set! injection.language "eex"))
|
||||
|
||||
(sigil
|
||||
(sigil_name) @_sigil_name
|
||||
(quoted_content) @injection.content
|
||||
(#any-of? @_sigil_name "z" "Z")
|
||||
(#set! injection.language "zig"))
|
||||
(#any-of? @_sigil_name "z" "Z")
|
||||
(#set! injection.language "zig"))
|
||||
|
||||
; Regex
|
||||
(sigil
|
||||
(sigil_name) @_sigil_name
|
||||
(quoted_content) @injection.content
|
||||
(#any-of? @_sigil_name "r" "R")
|
||||
(#set! injection.language "regex"))
|
||||
(#any-of? @_sigil_name "r" "R")
|
||||
(#set! injection.language "regex"))
|
||||
|
||||
; Json
|
||||
(sigil
|
||||
(sigil_name) @_sigil_name
|
||||
(quoted_content) @injection.content
|
||||
(#any-of? @_sigil_name "j" "J")
|
||||
(#set! injection.language "json"))
|
||||
|
||||
(#any-of? @_sigil_name "j" "J")
|
||||
(#set! injection.language "json"))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue