summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClay2022-07-26 01:14:45 +0000
committerGitHub2022-07-26 01:14:45 +0000
commitb55573dc1d1a15c53e91608b02ba22bf86cb5092 (patch)
tree961f504c133574d0f8d67b4c650741a44cb6af96
parent255c1734cfc46964e8faa21756ede2badd7b3813 (diff)
Add elixir & heex comment textobjects (#3179)
-rw-r--r--book/src/generated/lang-support.md2
-rw-r--r--runtime/queries/elixir/textobjects.scm2
-rw-r--r--runtime/queries/heex/textobjects.scm1
3 files changed, 4 insertions, 1 deletions
diff --git a/book/src/generated/lang-support.md b/book/src/generated/lang-support.md
index 21371c93..a5d286d7 100644
--- a/book/src/generated/lang-support.md
+++ b/book/src/generated/lang-support.md
@@ -39,7 +39,7 @@
| hare | ✓ | | ✓ | |
| haskell | ✓ | | | `haskell-language-server-wrapper` |
| hcl | ✓ | | ✓ | `terraform-ls` |
-| heex | ✓ | | | |
+| heex | ✓ | ✓ | | |
| html | ✓ | | | `vscode-html-language-server` |
| idris | | | | `idris2-lsp` |
| iex | ✓ | | | |
diff --git a/runtime/queries/elixir/textobjects.scm b/runtime/queries/elixir/textobjects.scm
index 227a52f4..cc1bee99 100644
--- a/runtime/queries/elixir/textobjects.scm
+++ b/runtime/queries/elixir/textobjects.scm
@@ -31,3 +31,5 @@
(arguments ((string) . (_)?))
(do_block (_)* @test.inside)?)
(#match? @_keyword "^(test|describe)$")) @test.around
+
+(comment) @comment.around @comment.inside
diff --git a/runtime/queries/heex/textobjects.scm b/runtime/queries/heex/textobjects.scm
new file mode 100644
index 00000000..439f61c0
--- /dev/null
+++ b/runtime/queries/heex/textobjects.scm
@@ -0,0 +1 @@
+(comment) @comment.around @comment.inside