Interface EditingOptionsIf

Excel-style editing (TableOptionsIf.editing): what typing, Enter, Tab, the arrow keys and Delete do. editing: true uses the defaults of EditingOptions; an object overrides single values.

Example

const tableOptions: TableOptionsIf = {
...new TableOptions(),
getSelectionModel: () => selectionModel, // new SelectionModel("range", "multi")
editing: { enterKey: "moveDown", textSelection: "end" }, // Enter moves down like Excel
};

Since

1.1.99

Hierarchy

  • EditingOptionsIf

Implemented by

Properties

arrowKeysCommit: boolean

In "enter" mode (opened by typing) the arrow keys commit and move; in "edit" mode they move the caret. Default true.

clearKeys: boolean

Delete clears the selected cells, Backspace clears one cell and opens the editor. Default true.

collapseSelectionOnNavigate: boolean

Arrow keys, Tab, Enter and clicks select the active cell (Excel); Shift+arrows extend from it. Default true.

ctrlEnterFillsSelection: boolean

Ctrl/⌘+Enter in the editor writes the input into all selected cells. Default true.

defaultEditable: boolean

true: columns without an own editable are editable (row numbers, checkbox and group columns, calculated columns without valueSetter stay read only). Default false.

emptyValue: unknown

The value of a cleared cell (a column can have its own: ColumnDefIf.emptyValue). Default "".

enterKey: "edit" | "moveDown"

Enter on a cell without editor: "edit" opens the editor (Google Sheets, default), "moveDown" moves down (Excel). Checkbox, tree, group and detail cells keep their own Enter action.

enterMoves: "none" | "right" | "down"

Where Enter in the editor goes after committing (Shift+Enter: the opposite). Default "down".

maxClearCells: number

At most this many cells are cleared at once (Delete). Default 1 000 000.

startOnType: boolean

A printable key on a focused editable cell opens the editor with that character ("enter" mode). Default true.

tabMoves: boolean

Tab/Shift+Tab commit and move to the next/previous shown column. In the last (first) column Tab is not used: the browser focus leaves the table (no keyboard trap). Default true.

textSelection: "all" | "end"

Enter and double click select the text of the editor ("all", default) or put the caret at the end; F2 always at the end.