Skip to content

BlockSuite API Documentation / @blocksuite/block-std / UIEventStateContext

Class: UIEventStateContext

Constructors

new UIEventStateContext(undefined)

new UIEventStateContext(): UIEventStateContext

Returns

UIEventStateContext

Properties

_map

private _map: Record<string, UIEventState> = {}

Source

block-std/src/event/base.ts:15

Methods

add()

add<State>(state): void

Type parameters

State extends UIEventState = UIEventState

Parameters

state: State

Returns

void

Source

block-std/src/event/base.ts:25


get()

get<Type>(type): MatchEvent<Type>

Type parameters

Type extends keyof BlockSuiteUIEventState = keyof BlockSuiteUIEventState

Parameters

type: Type

Returns

MatchEvent<Type>

Source

block-std/src/event/base.ts:38


has()

has(type): boolean

Parameters

type: keyof BlockSuiteUIEventState

Returns

boolean

Source

block-std/src/event/base.ts:34


from()

static from(...states): UIEventStateContext

Parameters

• ...states: UIEventState[]

Returns

UIEventStateContext

Source

block-std/src/event/base.ts:17


Generated using TypeDoc and typedoc-plugin-markdown.