aboutsummaryrefslogtreecommitdiffstats
path: root/runtime/queries/chatito
diff options
context:
space:
mode:
authorChristian Clason <c.clason@uni-graz.at>2023-06-12 09:54:30 -0600
committerChristian Clason <c.clason@uni-graz.at>2025-05-12 18:43:40 +0200
commit692b051b09935653befdb8f7ba8afdb640adf17b (patch)
tree167162b6b129ae04f68c5735078521a72917c742 /runtime/queries/chatito
parentfeat(c-family): inherit injections (diff)
downloadnvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.gz
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.bz2
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.lz
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.xz
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.tar.zst
nvim-treesitter-692b051b09935653befdb8f7ba8afdb640adf17b.zip
feat!: drop modules, general refactor and cleanup
Diffstat (limited to 'runtime/queries/chatito')
-rw-r--r--runtime/queries/chatito/folds.scm5
-rw-r--r--runtime/queries/chatito/highlights.scm54
-rw-r--r--runtime/queries/chatito/indents.scm8
-rw-r--r--runtime/queries/chatito/injections.scm2
-rw-r--r--runtime/queries/chatito/locals.scm16
5 files changed, 85 insertions, 0 deletions
diff --git a/runtime/queries/chatito/folds.scm b/runtime/queries/chatito/folds.scm
new file mode 100644
index 000000000..052dd2064
--- /dev/null
+++ b/runtime/queries/chatito/folds.scm
@@ -0,0 +1,5 @@
+[
+ (intent_def)
+ (slot_def)
+ (alias_def)
+] @fold
diff --git a/runtime/queries/chatito/highlights.scm b/runtime/queries/chatito/highlights.scm
new file mode 100644
index 000000000..47113f2cf
--- /dev/null
+++ b/runtime/queries/chatito/highlights.scm
@@ -0,0 +1,54 @@
+; Punctuation
+[
+ "%["
+ "@["
+ "~["
+ "*["
+ "]"
+ "("
+ ")"
+] @punctuation.bracket
+
+"," @punctuation.delimiter
+
+(eq) @operator
+
+([
+ "\""
+ "'"
+] @punctuation.special
+ (#set! conceal ""))
+
+[
+ "%"
+ "?"
+ "#"
+] @character.special
+
+; Entities
+(intent) @module
+
+(slot) @type
+
+(variation) @attribute
+
+(alias) @keyword.directive
+
+(number) @number
+
+(argument
+ key: (string) @property
+ value: (string) @string)
+
+(escape) @string.escape
+
+; Import
+"import" @keyword.import
+
+(file) @string.special.path
+
+; Text
+(word) @spell
+
+; Comment
+(comment) @comment @spell
diff --git a/runtime/queries/chatito/indents.scm b/runtime/queries/chatito/indents.scm
new file mode 100644
index 000000000..dc9e13d78
--- /dev/null
+++ b/runtime/queries/chatito/indents.scm
@@ -0,0 +1,8 @@
+[
+ (intent_def)
+ (slot_def)
+ (alias_def)
+] @indent.begin
+
+(ERROR
+ "]") @indent.begin
diff --git a/runtime/queries/chatito/injections.scm b/runtime/queries/chatito/injections.scm
new file mode 100644
index 000000000..2f0e58eb6
--- /dev/null
+++ b/runtime/queries/chatito/injections.scm
@@ -0,0 +1,2 @@
+((comment) @injection.content
+ (#set! injection.language "comment"))
diff --git a/runtime/queries/chatito/locals.scm b/runtime/queries/chatito/locals.scm
new file mode 100644
index 000000000..827447f57
--- /dev/null
+++ b/runtime/queries/chatito/locals.scm
@@ -0,0 +1,16 @@
+; Definitions
+(intent_def
+ (intent) @local.definition)
+
+(slot_def
+ (slot) @local.definition)
+
+(alias_def
+ (alias) @local.definition)
+
+; References
+(slot_ref
+ (slot) @local.reference)
+
+(alias_ref
+ (alias) @local.reference)