Skip to content

BlockSuite API Documentation / @blocksuite/blocks / ImageSelection

Class: ImageSelection

Extends

Constructors

new ImageSelection()

new ImageSelection(__namedParameters): ImageSelection

Parameters

__namedParameters: BaseSelectionOptions

Returns

ImageSelection

Inherited from

BaseSelection.constructor

Source

packages/framework/block-std/dist/selection/base.d.ts:8

Properties

blockId

readonly blockId: string

Inherited from

BaseSelection.blockId

Source

packages/framework/block-std/dist/selection/base.d.ts:7


group

static group: string = 'note'

Overrides

BaseSelection.group

Source

packages/blocks/src/image-block/image-selection.ts:10


type

static type: string = 'image'

Overrides

BaseSelection.type

Source

packages/blocks/src/image-block/image-selection.ts:9

Accessors

group

get group(): string

Returns

string

Source

packages/framework/block-std/dist/selection/base.d.ts:11


type

get type(): keyof Selection

Returns

keyof Selection

Source

packages/framework/block-std/dist/selection/base.d.ts:10

Methods

equals()

equals(other): boolean

Parameters

other: BaseSelection

Returns

boolean

Overrides

BaseSelection.equals

Source

packages/blocks/src/image-block/image-selection.ts:12


is()

is<T>(type): this is SelectionInstance[T]

Type parameters

T extends keyof Selection

Parameters

type: T

Returns

this is SelectionInstance[T]

Inherited from

BaseSelection.is

Source

packages/framework/block-std/dist/selection/base.d.ts:9


toJSON()

toJSON(): Record<string, unknown>

Returns

Record<string, unknown>

Overrides

BaseSelection.toJSON

Source

packages/blocks/src/image-block/image-selection.ts:19


fromJSON()

static fromJSON(json): ImageSelection

Parameters

json: Record<string, unknown>

Returns

ImageSelection

Overrides

BaseSelection.fromJSON

Source

packages/blocks/src/image-block/image-selection.ts:26