blob: b12da6f190d0a2a4e8da7aa0374c4e89868748a3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
include ../mixins/comment
include ../mixins/header
include ../mixins/head
include ../utils
doctype html
html
+head("more comments")
body
main#content
+header()
div.comments-container
a(href=`/comments/${parent_id}`)
| ← back to parent thread
if comments.length == 0
div
p nothing to see here, this thread was shadow-banned?
else
each comment, index in comments
- var next_idx = index + 1
- var prev_idx = index - 1
- var next_com = next_idx < total ? comments[next_idx] : null
- var prev_com = prev_idx >= 0 ? comments[prev_idx] : null
- var next_id = next_com ? next_com.data.id : null
- var prev_id = prev_com ? prev_com.data.id : null
+comment(comment, true, parent_id, next_idx, prev_idx)
|