Skip to main content

Class: GridSelection

lexical.GridSelection

Implements

Constructors

constructor

new GridSelection(gridKey, anchor, focus)

Parameters

NameType
gridKeystring
anchorPointType
focusPointType

Defined in

lexical/src/LexicalSelection.ts:385

Properties

_cachedNodes

_cachedNodes: null | LexicalNode[]

Defined in

lexical/src/LexicalSelection.ts:383


anchor

anchor: PointType

Defined in

lexical/src/LexicalSelection.ts:380


dirty

dirty: boolean

Implementation of

BaseSelection.dirty

Defined in

lexical/src/LexicalSelection.ts:382


focus

focus: PointType

Defined in

lexical/src/LexicalSelection.ts:381


gridKey

gridKey: string

Defined in

lexical/src/LexicalSelection.ts:379

Methods

clone

clone(): GridSelection

Returns

GridSelection

Implementation of

BaseSelection.clone

Defined in

lexical/src/LexicalSelection.ts:416


extract

extract(): LexicalNode[]

Returns

LexicalNode[]

Implementation of

BaseSelection.extract

Defined in

lexical/src/LexicalSelection.ts:432


getCharacterOffsets

getCharacterOffsets(): [number, number]

Returns

[number, number]

Defined in

lexical/src/LexicalSelection.ts:428


getNodes

getNodes(): LexicalNode[]

Returns

LexicalNode[]

Implementation of

BaseSelection.getNodes

Defined in

lexical/src/LexicalSelection.ts:481


getShape

getShape(): GridSelectionShape

Returns

GridSelectionShape

Defined in

lexical/src/LexicalSelection.ts:452


getTextContent

getTextContent(): string

Returns

string

Implementation of

BaseSelection.getTextContent

Defined in

lexical/src/LexicalSelection.ts:529


insertNodes

insertNodes(nodes, selectStart?): boolean

Parameters

NameType
nodesLexicalNode[]
selectStart?boolean

Returns

boolean

Defined in

lexical/src/LexicalSelection.ts:444


insertRawText

insertRawText(text): void

Parameters

NameType
textstring

Returns

void

Implementation of

BaseSelection.insertRawText

Defined in

lexical/src/LexicalSelection.ts:436


insertText

insertText(): void

Returns

void

Defined in

lexical/src/LexicalSelection.ts:440


is

is(selection): boolean

Parameters

NameType
selectionnull | RangeSelection | NodeSelection | GridSelection

Returns

boolean

Implementation of

BaseSelection.is

Defined in

lexical/src/LexicalSelection.ts:395


isBackward

isBackward(): boolean

Returns

boolean

Defined in

lexical/src/LexicalSelection.ts:424


isCollapsed

isCollapsed(): boolean

Returns

boolean

Defined in

lexical/src/LexicalSelection.ts:420


set

set(gridKey, anchorCellKey, focusCellKey): void

Parameters

NameType
gridKeystring
anchorCellKeystring
focusCellKeystring

Returns

void

Defined in

lexical/src/LexicalSelection.ts:408