{#snippet repliesSnippet()}
{#each replies as reply}
1 ? reply.edits.at(-1) : undefined} id={reply.id} author={reply.author} caption="replied" reactions={reply.reactions} timestamp={reply.edits[0].timestamp} body={reply.edits.slice(-1)[0].body} editComment={canModifyComment(reply.author.did) && editComment?.bind(null, reply.id)} reactOnComment={reactOnComment?.bind(null, reply.id)} deleteComment={canModifyComment(reply.author.did) ? deleteComment?.bind(null, reply.id) : undefined} />
{/each} {#if createReply && showReplyForm}
(showReplyForm = false)} submit={async ({ comment, embeds }) => { try { submitInProgress = true; await createReply(comment, Array.from(embeds.values()), root.id); } finally { showReplyForm = false; submitInProgress = false; } }} />
{/if}
{/snippet}
1 ? root.edits.at(-1) : undefined} author={root.author} reactions={root.reactions} timestamp={root.edits.slice(-1)[0].timestamp} body={root.edits.slice(-1)[0].body} editComment={canModifyComment(root.author.did) && editComment?.bind(null, root.id)} reactOnComment={reactOnComment?.bind(null, root.id)} deleteComment={canModifyComment(root.author.did) ? deleteComment?.bind(null, root.id) : undefined}> {#snippet actions()} {#if changeCommentStatus && canResolve}
changeCommentStatus(root.id, !root.resolved)} />
{/if} {#if createReply}
{/if} {/snippet}
{#if replies.length > 0 || (createReply && showReplyForm)}
{@render repliesSnippet()}
{/if}