platform/models/server-document/src/index.ts
Alexander Onnikov 58d39f0cd6
UBERF-5642 Opensource wiki (#4818)
Signed-off-by: Alexander Onnikov <Alexander.Onnikov@xored.com>
2024-02-29 15:32:39 +07:00

35 lines
1.1 KiB
TypeScript

//
// Copyright © 2023 Hardcore Engineering Inc.
//
//
import { type Builder } from '@hcengineering/model'
import core from '@hcengineering/core'
import document from '@hcengineering/document'
import serverCore from '@hcengineering/server-core'
import serverDocument from '@hcengineering/server-document'
import serverNotification from '@hcengineering/server-notification'
export { serverDocumentId } from '@hcengineering/server-document'
export function createModel (builder: Builder): void {
builder.mixin(document.class.Document, core.class.Class, serverNotification.mixin.HTMLPresenter, {
presenter: serverDocument.function.DocumentHTMLPresenter
})
builder.mixin(document.class.Document, core.class.Class, serverNotification.mixin.TextPresenter, {
presenter: serverDocument.function.DocumentTextPresenter
})
builder.mixin(document.class.Document, core.class.Class, serverCore.mixin.SearchPresenter, {
searchConfig: {
iconConfig: {
component: document.component.DocumentSearchIcon,
props: ['icon', 'color']
},
title: 'name'
}
})
}