@univerjs-proedit-history-viewerclassesHistorymanagerservice

@univerjs-pro/edit-history-viewer v0.5.4


Class: HistoryManagerService

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:22

Extends

Constructors

new HistoryManagerService()

new HistoryManagerService(
   _messageService, 
   _confirmService, 
   _localeService, 
   _historyFetchService): HistoryManagerService

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:54

Parameters

ParameterType
_messageServiceIMessageService
_confirmServiceIConfirmService
_localeServiceLocaleService
_historyFetchServiceHistoryFetchService

Returns

HistoryManagerService

Overrides

Disposable.constructor

Properties

PropertyModifierTypeDefault valueInherited fromDefined in
_disposedprotectedbooleanfalseDisposable._disposedsubmodules/univer/packages/core/src/shared/lifecycle.ts:96
currentVersion$readonlyObservable<string>undefined-packages/edit-history-viewer/src/services/history-manager.service.tsx:27
loadingState$readonlyObservable<LoadingState>undefined-packages/edit-history-viewer/src/services/history-manager.service.tsx:41
revertRevision$readonlyObservable<number>undefined-packages/edit-history-viewer/src/services/history-manager.service.tsx:33
status$readonlyObservable<HistoryModeStatus>undefined-packages/edit-history-viewer/src/services/history-manager.service.tsx:30
unitId$readonlyObservable<null | string>undefined-packages/edit-history-viewer/src/services/history-manager.service.tsx:36
versions$readonlyObservable<IHistoryVersion[]>undefined-packages/edit-history-viewer/src/services/history-manager.service.tsx:24

Accessors

canRevert

Get Signature

get canRevert(): boolean

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:224

Returns

boolean


currentVersion

Get Signature

get currentVersion(): string

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:212

Returns

string

Set Signature

set currentVersion(value): void

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:206

Parameters
ParameterType
valuestring
Returns

void


loadingState

Get Signature

get loadingState(): LoadingState

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:228

Returns

LoadingState


status

Set Signature

set status(value): void

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:202

Parameters
ParameterType
valueHistoryModeStatus
Returns

void


unitId

Get Signature

get unitId(): null | string

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:220

Returns

null | string

Set Signature

set unitId(value): void

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:216

Parameters
ParameterType
valuenull | string
Returns

void

Methods

dispose()

dispose(): void

Defined in: submodules/univer/packages/core/src/shared/lifecycle.ts:109

Returns

void

Inherited from

Disposable.dispose


disposeWithMe()

disposeWithMe(disposable): IDisposable

Defined in: submodules/univer/packages/core/src/shared/lifecycle.ts:99

Parameters

ParameterType
disposableDisposableLike

Returns

IDisposable

Inherited from

Disposable.disposeWithMe


ensureNotDisposed()

protected ensureNotDisposed(): void

Defined in: submodules/univer/packages/core/src/shared/lifecycle.ts:103

Returns

void

Inherited from

Disposable.ensureNotDisposed


getCurrentVersion()

getCurrentVersion(): undefined | IHistoryVersion

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:151

Returns

undefined | IHistoryVersion


getMember()

getMember(id): undefined | IUser

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:159

Parameters

ParameterType
idstring

Returns

undefined | IUser


getVersion()

getVersion(id): undefined | IHistoryVersion

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:155

Parameters

ParameterType
idstring

Returns

undefined | IHistoryVersion


hideMask()

hideMask(): void

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:198

Returns

void


loadMoreVersions()

loadMoreVersions(): Promise<boolean>

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:93

Returns

Promise<boolean>


showMask()

showMask(): void

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:189

Returns

void


triggerLoadSheet()

triggerLoadSheet(versionId): Promise<void>

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:113

Parameters

ParameterType
versionIdstring

Returns

Promise<void>


triggerLoadVersions()

triggerLoadVersions(
   unitId, 
   containerId, 
canRevert): Promise<void>

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:63

Parameters

ParameterType
unitIdstring
containerIdstring
canRevertboolean

Returns

Promise<void>


triggerRevert()

triggerRevert(id?): Promise<void>

Defined in: packages/edit-history-viewer/src/services/history-manager.service.tsx:125

Parameters

ParameterType
id?string

Returns

Promise<void>