Skip to content

BlockSuite API Documentation / @blocksuite/blocks / DataViewBlockModel

Class: DataViewBlockModel

Extends

Constructors

new DataViewBlockModel()

new DataViewBlockModel(): DataViewBlockModel

Returns

DataViewBlockModel

Overrides

BlockModel<Props>.constructor

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:19

Properties

[modelLabel]

[modelLabel]: Props

Inherited from

BlockModel.[modelLabel]

Defined in

packages/framework/store/dist/schema/base.d.ts:120


cells

cells: Record<string, Record<string, unknown>>

Inherited from

BlockModel.cells

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:15


cells$

cells$: Signal<Record<string, Record<string, unknown>>>

Inherited from

BlockModel.cells$


childMap

childMap: ReadonlySignal<Map<string, number>>

Inherited from

BlockModel.childMap

Defined in

packages/framework/store/dist/schema/base.d.ts:113


columns

columns: Column<Record<string, unknown>>[]

Inherited from

BlockModel.columns

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:14


columns$

columns$: Signal<Column<Record<string, unknown>>[]>

Inherited from

BlockModel.columns$


created

created: Slot<void>

Inherited from

BlockModel.created

Defined in

packages/framework/store/dist/schema/base.d.ts:114


deleted

deleted: Slot<void>

Inherited from

BlockModel.deleted

Defined in

packages/framework/store/dist/schema/base.d.ts:115


flavour

flavour: string

Inherited from

BlockModel.flavour

Defined in

packages/framework/store/dist/schema/base.d.ts:116


id

id: string

Inherited from

BlockModel.id

Defined in

packages/framework/store/dist/schema/base.d.ts:117


isEmpty

isEmpty: ReadonlySignal<boolean>

Inherited from

BlockModel.isEmpty

Defined in

packages/framework/store/dist/schema/base.d.ts:118


keys

keys: string[]

Inherited from

BlockModel.keys

Defined in

packages/framework/store/dist/schema/base.d.ts:119


page

page: Doc

Deprecated

use doc instead

Inherited from

BlockModel.page

Defined in

packages/framework/store/dist/schema/base.d.ts:109


pop()

pop: (prop) => void

Parameters

prop: "title" | "views" | "cells" | "columns"

Returns

void

Inherited from

BlockModel.pop

Defined in

packages/framework/store/dist/schema/base.d.ts:121


propsUpdated

propsUpdated: Slot<object>

Type declaration

key

key: string

Inherited from

BlockModel.propsUpdated

Defined in

packages/framework/store/dist/schema/base.d.ts:122


role

role: "root" | "hub" | "content"

Inherited from

BlockModel.role

Defined in

packages/framework/store/dist/schema/base.d.ts:125


stash()

stash: (prop) => void

Parameters

prop: "title" | "views" | "cells" | "columns"

Returns

void

Inherited from

BlockModel.stash

Defined in

packages/framework/store/dist/schema/base.d.ts:126


text?

optional text: Text

Inherited from

BlockModel.text

Defined in

packages/framework/store/dist/schema/base.d.ts:127


title

title: string

Inherited from

BlockModel.title

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:12


title$

title$: Signal<string>

Inherited from

BlockModel.title$


version

version: number

Inherited from

BlockModel.version

Defined in

packages/framework/store/dist/schema/base.d.ts:128


views

views: DefaultViewDataType[]

Inherited from

BlockModel.views

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:13


views$

views$: Signal<DefaultViewDataType[]>

Inherited from

BlockModel.views$


yBlock

yBlock: YBlock

Inherited from

BlockModel.yBlock

Defined in

packages/framework/store/dist/schema/base.d.ts:129

Accessors

children

get children(): BlockModel<object, SignaledProps<object>>[]

Returns

BlockModel<object, SignaledProps<object>>[]

Inherited from

BlockModel.children

Defined in

packages/framework/store/dist/schema/base.d.ts:130


doc

get doc(): Doc

set doc(doc): void

Parameters

doc: Doc

Returns

Doc

Inherited from

BlockModel.doc

Defined in

packages/framework/store/dist/schema/base.d.ts:131


parent

get parent(): null | BlockModel<object, SignaledProps<object>>

Returns

null | BlockModel<object, SignaledProps<object>>

Inherited from

BlockModel.parent

Defined in

packages/framework/store/dist/schema/base.d.ts:133

Methods

[dispose]()

[dispose](): void

Returns

void

Inherited from

BlockModel.[dispose]

Defined in

packages/framework/store/dist/schema/base.d.ts:138


applyViewsUpdate()

applyViewsUpdate(): void

Returns

void

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:23


deleteView()

deleteView(id): void

Parameters

id: string

Returns

void

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:29


dispose()

dispose(): void

Returns

void

Inherited from

BlockModel.dispose

Defined in

packages/framework/store/dist/schema/base.d.ts:135


duplicateView()

duplicateView(id): string

Parameters

id: string

Returns

string

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:36


firstChild()

firstChild(): null | BlockModel<object, SignaledProps<object>>

Returns

null | BlockModel<object, SignaledProps<object>>

Inherited from

BlockModel.firstChild

Defined in

packages/framework/store/dist/schema/base.d.ts:136


lastChild()

lastChild(): null | BlockModel<object, SignaledProps<object>>

Returns

null | BlockModel<object, SignaledProps<object>>

Inherited from

BlockModel.lastChild

Defined in

packages/framework/store/dist/schema/base.d.ts:137


moveViewTo()

moveViewTo(id, position): void

Parameters

id: string

position: InsertToPosition

Returns

void

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:52


updateView()

updateView(id, update): void

Parameters

id: string

update

Returns

void

Defined in

packages/blocks/src/data-view-block/data-view-model.ts:63