Skip to content

Commit df89295

Browse files
authored
Add HEEx indents and outline (#79)
These queries should match those used by HTML
1 parent d91862a commit df89295

2 files changed

Lines changed: 33 additions & 0 deletions

File tree

languages/heex/indents.scm

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
[
2+
(start_tag ">" @end)
3+
(self_closing_tag "/>" @end)
4+
(start_slot ">" @end)
5+
(self_closing_slot "/>" @end)
6+
(start_component ">" @end)
7+
(self_closing_component "/>" @end)
8+
] @indent
9+
10+
[
11+
(tag
12+
(start_tag) @start
13+
(end_tag)? @end)
14+
(slot
15+
(start_slot) @start
16+
(end_slot)? @end)
17+
(component
18+
(start_component) @start
19+
(end_component)? @end)
20+
] @indent

languages/heex/outline.scm

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
(comment) @annotation
2+
3+
[
4+
(tag
5+
(start_tag
6+
(tag_name) @name))
7+
(slot
8+
(start_slot
9+
(slot_name) @name))
10+
(component
11+
(start_component
12+
(component_name) @name))
13+
] @item

0 commit comments

Comments
 (0)