mirror of
https://github.com/overleaf/overleaf.git
synced 2025-04-22 19:37:38 +00:00
Merge pull request #23998 from overleaf/td-resolved-thread-count
Fix for resolved thread count display GitOrigin-RevId: c4f6848ed2e952981d20f157466db6dded99c3c9
This commit is contained in:
parent
1f339b37bd
commit
cd644320f4
1 changed files with 5 additions and 5 deletions
|
@ -50,18 +50,18 @@ export const ReviewPanelResolvedThreadsMenu: FC = () => {
|
|||
return []
|
||||
}
|
||||
|
||||
const resolvedThreads = []
|
||||
const allResolvedThreads = []
|
||||
for (const [id, thread] of Object.entries(threads)) {
|
||||
if (thread.resolved) {
|
||||
resolvedThreads.push({ thread, id })
|
||||
allResolvedThreads.push({ thread, id })
|
||||
}
|
||||
}
|
||||
resolvedThreads.sort((a, b) => {
|
||||
allResolvedThreads.sort((a, b) => {
|
||||
return Date.parse(b.thread.resolved_at) - Date.parse(a.thread.resolved_at)
|
||||
})
|
||||
|
||||
return resolvedThreads
|
||||
}, [threads])
|
||||
return allResolvedThreads.filter(thread => allComments.has(thread.id))
|
||||
}, [threads, allComments])
|
||||
|
||||
if (loading) {
|
||||
return <LoadingSpinner className="ms-auto me-auto" />
|
||||
|
|
Loading…
Add table
Reference in a new issue