Merge branch 'feat/inda-383-daily-stat' into 'main'
[ProtonMail-WebClient.git] / packages / docs-core / lib / AuthenticatedDocController / AuthenticatedDocControllerInterface.ts
blobd818a8e1326833e24503d2321987ce74c67a68c5
1 import type { YjsState } from '@proton/docs-shared'
2 import type { NativeVersionHistory } from '../VersionHistory'
3 import type { TranslatedResult } from '@proton/docs-shared'
4 import type { Result } from '@proton/docs-shared'
6 export interface AuthenticatedDocControllerInterface {
7   didTrashDocInCurrentSession: boolean
9   createInitialCommit(content: Uint8Array): Promise<Result<unknown>>
10   createNewDocument(): Promise<void>
11   debugSendCommitCommandToRTS(): Promise<void>
12   deinit(): void
13   destroy(): void
14   duplicateDocument(editorYjsState: Uint8Array): Promise<void>
15   getVersionHistory(): NativeVersionHistory | undefined
16   openDocumentSharingModal(): void
17   restoreRevisionAsCopy(yjsContent: YjsState): Promise<void>
18   renameDocument(newName: string): Promise<TranslatedResult<void>>
19   restoreDocument(): Promise<void>
20   squashDocument(): Promise<void>
21   trashDocument(): Promise<void>