mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-11-15 11:20:36 +08:00
Show comments that are thread replies to the issue body
Previously treated the issue body as a comment and people could post a thread reply to that first comment. Now we treat the first comment as the issue body and disallow replying to it via a thread. There are still some old replies, we show them as regular comments. Signed-off-by: Rūdolfs Ošiņš <rudolfs@osins.org>
This commit is contained in:
@@ -146,10 +146,15 @@
|
||||
}
|
||||
}
|
||||
|
||||
const issueDescription = issue.discussion[0];
|
||||
|
||||
$: selectedItem = issue.state.status === "closed" ? items[0] : items[1];
|
||||
$: threads = issue.discussion
|
||||
.slice(1) // Skip the first comment, which is the issue description
|
||||
.filter(comment => !comment.replyTo)
|
||||
.filter(
|
||||
comment =>
|
||||
(comment.id !== issueDescription.id && !comment.replyTo) ||
|
||||
comment.replyTo === issueDescription.id,
|
||||
)
|
||||
.map(thread => {
|
||||
return {
|
||||
root: thread,
|
||||
|
||||
Reference in New Issue
Block a user