Unverified Commit f760e485 authored by Tobias Koppers's avatar Tobias Koppers Committed by GitHub

pr-status: Show all participants in review thread overview (#92730)

Co-authored-by: 's avatarTobias Koppers <sokra@users.noreply.github.com>
Co-authored-by: 's avatarClaude <noreply@anthropic.com>
parent 8a2c5e01
......@@ -819,18 +819,23 @@ function generateIndexMd(
'',
`## Inline Review Comments (${reviewThreads.length} threads)`,
'',
'| File | Line | Author | Replies | Status | Details |',
'|------|------|--------|---------|--------|---------|'
'| File | Line | Participants | Replies | Status | Details |',
'|------|------|--------------|---------|--------|---------|'
)
for (let i = 0; i < reviewThreads.length; i++) {
const thread = reviewThreads[i]
const line = thread.line || thread.startLine || 'N/A'
const author = thread.comments.nodes[0]?.author?.login || 'Unknown'
const participants = new Set()
for (const comment of thread.comments.nodes) {
if (comment.author?.login) participants.add(comment.author.login)
}
const participantsStr =
participants.size > 0 ? [...participants].join(', ') : 'Unknown'
const replyCount = Math.max(0, thread.comments.nodes.length - 1)
const status = thread.isResolved ? 'Resolved' : 'Open'
lines.push(
`| ${escapeMarkdownTableCell(thread.path)} | ${line} | ${author} | ${replyCount} | ${status} | [View](thread-${i + 1}.md) |`
`| ${escapeMarkdownTableCell(thread.path)} | ${line} | ${participantsStr} | ${replyCount} | ${status} | [View](thread-${i + 1}.md) |`
)
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment