(hideDiscussion = !hideDiscussion)}>
Discussion {sum( commentThreads.map(t => { return t.replies.length + 1; }), )}
{ if (hideDiscussion) { hideDiscussion = false; } else { if (commentThreads.length === 0) { hideDiscussion = true; } } await toggleReply(); }}> Comment
{#each commentThreads as thread} delegate.did), )} {editComment} createReply={createComment} {reactOnComment} />
{/each}
{ if (commentThreads.length === 0) { hideDiscussion = !hideDiscussion; } topLevelReplyOpen = false; } : undefined} placeholder="Leave a comment" submit={createComment} />