feat!: drop modules, general refactor and cleanup

This commit is contained in:
Christian Clason 2023-06-12 09:54:30 -06:00
parent 310f0925ec
commit 692b051b09
1247 changed files with 6096 additions and 9074 deletions

View file

@ -0,0 +1,6 @@
; Surface folds similar to HTML and includes blocks
[
(tag)
(component)
(block)
] @fold

View file

@ -0,0 +1,44 @@
; Surface text is not highlighted
(text) @none
; Surface has two types of comments, both are highlighted as such
(comment) @comment @spell
; Surface attributes are highlighted as HTML attributes
(attribute_name) @tag.attribute
; Attributes are highlighted as strings
(quoted_attribute_value) @string
; Surface blocks are highlighted as keywords
[
(start_block)
(end_block)
(subblock)
] @keyword
; Surface supports HTML tags and are highlighted as such
[
"<"
">"
"</"
"/>"
"{"
"}"
"<!--"
"-->"
"{!--"
"--}"
] @tag.delimiter
; Surface tags are highlighted as HTML
(tag_name) @tag
; Surface components are highlighted as types (Elixir modules)
(component_name) @type
; Surface directives are highlighted as keywords
(directive_name) @keyword
; Surface operators
"=" @operator

View file

@ -0,0 +1,14 @@
; Surface indents like HTML, with the addition of blocks
[
(component)
(tag)
(block)
] @indent.begin
; Dedent at the end of each tag, as well as a subblock
[
(end_tag)
(end_component)
(end_block)
(subblock)
] @indent.branch

View file

@ -0,0 +1,10 @@
; Surface expressions and components are Elixir code
([
(expression_value)
(component_name)
] @injection.content
(#set! injection.language "elixir"))
; Surface comments are nvim-treesitter comments
((comment) @injection.content
(#set! injection.language "comment"))