Fix double comments header in issue preview (#5007)

Signed-off-by: Kristina Fefelova <kristin.fefelova@gmail.com>
This commit is contained in:
Kristina 2024-03-18 15:06:28 +04:00 committed by GitHub
parent a028e83bb7
commit 5630af508c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -15,25 +15,23 @@
<script lang="ts"> <script lang="ts">
import attachment from '@hcengineering/attachment' import attachment from '@hcengineering/attachment'
import { AttachmentDocList } from '@hcengineering/attachment-resources' import { AttachmentDocList } from '@hcengineering/attachment-resources'
import chunter from '@hcengineering/chunter'
import { Ref } from '@hcengineering/core' import { Ref } from '@hcengineering/core'
import { IconForward, MessageViewer, createQuery, getClient } from '@hcengineering/presentation' import { IconForward, MessageViewer, createQuery, getClient } from '@hcengineering/presentation'
import { Issue, Project } from '@hcengineering/tracker' import { Issue } from '@hcengineering/tracker'
import { Label, Scroller, resizeObserver } from '@hcengineering/ui' import { Label, Scroller, resizeObserver } from '@hcengineering/ui'
import { ChatMessagePopup } from '@hcengineering/chunter-resources' import { ChatMessagePopup } from '@hcengineering/chunter-resources'
import tracker from '../../plugin' import tracker from '../../plugin'
import { activeProjects } from '../../utils'
import AssigneeEditor from './AssigneeEditor.svelte' import AssigneeEditor from './AssigneeEditor.svelte'
import IssueStatusActivity from './IssueStatusActivity.svelte' import IssueStatusActivity from './IssueStatusActivity.svelte'
import PriorityEditor from './PriorityEditor.svelte' import PriorityEditor from './PriorityEditor.svelte'
import StatusEditor from './StatusEditor.svelte' import StatusEditor from './StatusEditor.svelte'
export let object: Issue export let object: Issue
let issue: Issue | undefined let issue: Issue | undefined
const client = getClient() const client = getClient()
$: space = object.space
const issueQuery = createQuery() const issueQuery = createQuery()
$: issueQuery.query( $: issueQuery.query(
@ -58,7 +56,7 @@
} }
} }
$: getParent(issue?.attachedTo as Ref<Issue>) $: void getParent(issue?.attachedTo as Ref<Issue>)
</script> </script>
{#if issue} {#if issue}
@ -108,10 +106,9 @@
<AttachmentDocList value={issue} /> <AttachmentDocList value={issue} />
{/if} {/if}
{#if issue.comments} {#if issue.comments}
<div class="mt-6 mb-2 overflow-label fs-bold content-dark-color"> <div class="mt-6">
<Label label={chunter.string.Comments} />: <ChatMessagePopup objectId={issue._id} object={issue} />
</div> </div>
<ChatMessagePopup objectId={issue._id} object={issue} />
{/if} {/if}
<div class="h-3 flex-no-shrink" /> <div class="h-3 flex-no-shrink" />
</Scroller> </Scroller>