mirror of
https://github.com/hcengineering/platform.git
synced 2025-05-28 19:08:01 +00:00
UBERF-7067: Make chat group labels translations reactive (#5688)
Signed-off-by: Kristina Fefelova <kristin.fefelova@gmail.com>
This commit is contained in:
parent
4c7c9e2951
commit
fd25c6961d
@ -17,7 +17,7 @@
|
||||
import notification, { DocNotifyContext } from '@hcengineering/notification'
|
||||
import { createQuery, getClient, LiveQuery } from '@hcengineering/presentation'
|
||||
import activity from '@hcengineering/activity'
|
||||
import { translate } from '@hcengineering/platform'
|
||||
import { IntlString } from '@hcengineering/platform'
|
||||
import { Action } from '@hcengineering/ui'
|
||||
import { InboxNotificationsClientImpl } from '@hcengineering/notification-resources'
|
||||
|
||||
@ -32,7 +32,7 @@
|
||||
interface Section {
|
||||
id: string
|
||||
_class?: Ref<Class<Doc>>
|
||||
label: string
|
||||
label: IntlString
|
||||
objects: Doc[]
|
||||
}
|
||||
|
||||
@ -124,7 +124,7 @@
|
||||
result.push({
|
||||
id: model.id,
|
||||
objects: Array.from(objectsByClass.values()).flat(),
|
||||
label: await translate(model.label ?? chunter.string.Channels, {})
|
||||
label: model.label ?? chunter.string.Channels
|
||||
})
|
||||
|
||||
return result
|
||||
@ -153,7 +153,7 @@
|
||||
id: _class,
|
||||
_class,
|
||||
objects: sectionObjects,
|
||||
label: await translate(clazz.pluralLabel ?? clazz.label, {})
|
||||
label: clazz.pluralLabel ?? clazz.label
|
||||
})
|
||||
}
|
||||
|
||||
@ -164,7 +164,7 @@
|
||||
id: object._id,
|
||||
_class: object._class,
|
||||
objects: [object],
|
||||
label: await translate(clazz.pluralLabel ?? clazz.label, {})
|
||||
label: clazz.pluralLabel ?? clazz.label
|
||||
})
|
||||
}
|
||||
|
||||
|
@ -19,7 +19,7 @@
|
||||
import ui, { Action, AnySvelteComponent, IconSize, ModernButton, NavGroup } from '@hcengineering/ui'
|
||||
import { getDocTitle } from '@hcengineering/view-resources'
|
||||
import contact from '@hcengineering/contact'
|
||||
import { getResource, translate } from '@hcengineering/platform'
|
||||
import { getResource, IntlString, translate } from '@hcengineering/platform'
|
||||
import view from '@hcengineering/view'
|
||||
import { personAccountByIdStore, statusByUserStore } from '@hcengineering/contact-resources'
|
||||
|
||||
@ -30,7 +30,7 @@
|
||||
import { navigatorStateStore, toggleSections } from '../utils'
|
||||
|
||||
export let id: string
|
||||
export let header: string
|
||||
export let header: IntlString
|
||||
export let objects: Doc[]
|
||||
export let contexts: DocNotifyContext[]
|
||||
export let actions: Action[] = []
|
||||
@ -141,7 +141,7 @@
|
||||
|
||||
{#if visibleItems.length > 0 && contexts.length > 0}
|
||||
<NavGroup
|
||||
title={header}
|
||||
label={header}
|
||||
categoryName={id}
|
||||
{actions}
|
||||
isOpen={!isCollapsed}
|
||||
|
Loading…
Reference in New Issue
Block a user