Skip to content

Type Editor


Type Editor / @type-editor/tables / commands/delete-cell-selection / deleteCellSelection

Function: deleteCellSelection()

ts
function deleteCellSelection(state, dispatch?): boolean;

Defined in: tables/src/commands/delete-cell-selection.ts:19

Deletes the content of selected cells while preserving the cell structure.

Only applies when there is a CellSelection. Replaces each cell's content with the default empty content for a cell.

Parameters

ParameterTypeDescription
statePmEditorStateThe current editor state
dispatch?DispatchFunctionOptional dispatch function to execute the command

Returns

boolean

True if the selection is a CellSelection, false otherwise