Add chat q-fixes (#9173)

Signed-off-by: Kristina Fefelova <kristin.fefelova@gmail.com>
This commit is contained in:
Kristina 2025-06-05 09:03:28 +04:00 committed by GitHub
parent f21996252b
commit 27a35e2c93
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 9 additions and 10 deletions

View File

@ -1 +1 @@
"0.7.110"
"0.7.136"

View File

@ -2,7 +2,7 @@ import { getPersonBySocialId, formatName } from '@hcengineering/contact'
import { Ref, TxOperations } from '@hcengineering/core'
import notification, { DocNotifyContext, CommonInboxNotification, ActivityInboxNotification, InboxNotification } from '@hcengineering/notification'
import { IntlString, addEventListener, translate } from '@hcengineering/platform'
import { getClient, createNotificationsQuery } from '@hcengineering/presentation'
import { getClient } from '@hcengineering/presentation'
import { location } from '@hcengineering/ui'
import workbench, { workbenchId } from '@hcengineering/workbench'
import desktopPreferences, { defaultNotificationPreference } from '@hcengineering/desktop-preferences'
@ -13,8 +13,6 @@ import { IPCMainExposed } from './types'
let client: TxOperations
const notificationsQuery = createNotificationsQuery()
async function hydrateNotificationAsYouCan (lastNotification: InboxNotification): Promise<{ title: string, body: string } | undefined> {
// Let's try to do our best and figure out from who we have an notification
@ -116,7 +114,7 @@ export function configureNotifications (): void {
// because we generate them on a client
let initTimestamp = 0
const notificationHistory = new Map<string, number>()
let newUnreadNotifications = 0
const newUnreadNotifications = 0
addEventListener(workbench.event.NotifyConnection, async () => {
client = getClient()
@ -124,10 +122,11 @@ export function configureNotifications (): void {
const inboxClient = InboxNotificationsClientImpl.getClient()
notificationsQuery.query({ read: false, limit: 1000 }, res => {
newUnreadNotifications = res.getResult().length
electronAPI.setBadge(prevUnViewdNotificationsCount + newUnreadNotifications)
})
// TODO: FIX ME
// notificationsQuery.query({ read: false, limit: 1000 }, res => {
// newUnreadNotifications = res.getResult().length
// electronAPI.setBadge(prevUnViewdNotificationsCount + newUnreadNotifications)
// })
async function handleNotifications (notificationsByContext: Map<Ref<DocNotifyContext>, InboxNotification[]>): Promise<void> {
const inboxData = await getDisplayInboxData(notificationsByContext)

View File

@ -83,6 +83,7 @@
$: clazz = hierarchy.getClass(card._class) as Class<Card> & { color?: number }
function getCardTitle (card: Card): string {
if ((card?.parentInfo?.length ?? 0) === 0) return card.title
const parent = card.parentInfo[card.parentInfo.length - 1]
if (parent != null) {
return `${card.title} (${parent.title})`

View File

@ -131,7 +131,6 @@
items={contexts}
highlightIndex={contexts.findIndex((it) => it.card === card?._id)}
noScroll
minHeight="5.625rem"
kind="full-size"
colorsSchema="lumia"
lazy={true}