Class: SlideDataModel
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:25
The base class for all units.
Extends
Constructors
new SlideDataModel()
new SlideDataModel(snapshot): SlideDataModel
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:52
Parameters
Parameter | Type |
---|---|
snapshot | Partial <ISlideData > |
Returns
Overrides
Properties
Property | Modifier | Type | Default value | Overrides | Inherited from | Defined in |
---|---|---|---|---|---|---|
_disposed | protected | boolean | false | - | UnitModel ._disposed | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/shared/lifecycle.ts:96 |
activePage$ | readonly | Observable <Nullable <ISlidePage >> | undefined | - | - | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:43 |
name$ | public | Observable <string > | undefined | UnitModel .name$ | - | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:46 |
type | public | UNIVER_SLIDE | UniverInstanceType.UNIVER_SLIDE | UnitModel .type | - | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:26 |
Methods
appendPage()
appendPage(page): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:145
Parameters
Parameter | Type |
---|---|
page | ISlidePage |
Returns
void
dispose()
dispose(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/shared/lifecycle.ts:109
Returns
void
Inherited from
disposeWithMe()
disposeWithMe(disposable): IDisposable
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/shared/lifecycle.ts:99
Parameters
Parameter | Type |
---|---|
disposable | DisposableLike |
Returns
Inherited from
ensureNotDisposed()
protected ensureNotDisposed(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/shared/lifecycle.ts:103
Returns
void
Inherited from
getActivePage()
getActivePage(): Nullable<ISlidePage>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:135
Returns
getBlankPage()
getBlankPage(): {
description: string;
id: string;
pageBackgroundFill: {
rgb: string;
};
pageElements: {};
pageType: PageType;
title: string;
zIndex: number;
}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:113
Returns
{
description: string;
id: string;
pageBackgroundFill: {
rgb: string;
};
pageElements: {};
pageType: PageType;
title: string;
zIndex: number;
}
Name | Type | Default value | Defined in |
---|---|---|---|
description | string | ” | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:121 |
id | string | - | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:117 |
pageBackgroundFill | { rgb : string ; } | - | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:122 |
pageBackgroundFill.rgb | string | ’rgb(255,255,255)‘ | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:123 |
pageElements | {} | {} | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:125 |
pageType | PageType | PageType.SLIDE | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:118 |
title | string | id | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:120 |
zIndex | number | 10 | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:119 |
getElement()
getElement(pageId, elementId): undefined | IPageElement
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:105
Parameters
Parameter | Type |
---|---|
pageId | string |
elementId | string |
Returns
undefined
| IPageElement
getElementsByPage()
getElementsByPage(pageId): undefined | {}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:101
Parameters
Parameter | Type |
---|---|
pageId | string |
Returns
undefined
| {}
getPage()
getPage(pageId): undefined | ISlidePage
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:96
Parameters
Parameter | Type |
---|---|
pageId | string |
Returns
undefined
| ISlidePage
getPageOrder()
getPageOrder(): undefined | string[]
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:92
Returns
undefined
| string
[]
getPages()
getPages(): undefined | {}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:88
Returns
undefined
| {}
getPageSize()
getPageSize(): ISize
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:109
Returns
getRev()
getRev(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:68
Get revision of the unit’s snapshot. Note that revision should start from 1.
Returns
number
Overrides
getSnapshot()
getSnapshot(): ISlideData
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:80
Returns
Overrides
getUnitId()
getUnitId(): string
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:84
Returns
string
Overrides
incrementRev()
incrementRev(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:72
Increment the current revision.
Returns
void
Overrides
setActivePage()
setActivePage(page): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:131
Parameters
Parameter | Type |
---|---|
page | Nullable <ISlidePage > |
Returns
void
setName()
setName(name): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:62
Parameters
Parameter | Type |
---|---|
name | string |
Returns
void
Overrides
setRev()
setRev(_rev): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:76
Set revision of the current snapshot.
Parameters
Parameter | Type |
---|---|
_rev | number |
Returns
void
Overrides
updatePage()
updatePage(pageId, page): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/slides/slide-model.ts:139
Parameters
Parameter | Type |
---|---|
pageId | string |
page | ISlidePage |
Returns
void