• Public
  • Public/Protected
  • All

Class CellEditor

An abstract base class that provides the most of the functionality needed by a cell editor. All of the built-in cell editors for various cell types are derived from this base class. Custom cell editors can be easily implemented by extending this class. The namespace for the CellEditor class statics.




Type aliases

Static CellConfig

CellConfig: object

An object which holds the configuration data for a cell.

Type declaration




Private _disposed

_disposed: boolean = false

Whether the cell editor is disposed.

Private _gridWheelEventHandler

_gridWheelEventHandler: function | null = null

Grid wheel event handler.

Private _validInput

_validInput: boolean = true

Whether the value input is valid.

Protected cell

Cell configuration data for the cell being edited.

Protected editorContainer

editorContainer: HTMLDivElement

The div element used to contain and position editor widget.

Protected inputChanged

inputChanged: Signal<this, void> = new Signal<this, void>(this)

A signal emitted when input changes.

Protected Optional onCancel

onCancel: undefined | function

Callback method to call on cell edit cancel.

Protected Optional onCommit

onCommit: undefined | function

Callback method to call on cell edit commit.

Protected validator

validator: ICellInputValidator | undefined

Cell input validator to use for the cell being edited.

Protected validityNotification

validityNotification: Notification | null = null

Notification popup used to show validation error messages.

Protected viewportOccluder

viewportOccluder: HTMLDivElement

The div element used to prevent editor widget overflow beyond grid viewport.



  • get isDisposed(): boolean

Protected validInput

  • get validInput(): boolean


Private _addContainer

  • _addContainer(): void
  • Create container elements needed to prevent editor widget overflow beyond viewport and to position cell editor widget.

    Returns void

Private _closeValidityNotification

  • _closeValidityNotification(): void


  • cancel(): void

Protected commit

  • Commit the edited value.


    • Default value cursorMovement: CursorMoveDirection = "none"

      Cursor move direction based on keys pressed to end the edit.

    Returns boolean

    true on valid input, false otherwise.

Protected createValidatorBasedOnType


  • dispose(): void


Protected getCellInfo

  • getCellInfo(cell: CellConfig): Private.ICellInfo

Protected Abstract getInput

  • getInput(): any
  • Return the current input entered. This method throws exceptions if input is invalid. Error message in exception is shown as notification.

    Returns any

Protected setValidity

  • setValidity(valid: boolean, message?: string): void
  • Set validity flag.


    • valid: boolean

      Whether the input is valid.

    • Default value message: string = ""

      Notification message to show.

      If message is set to empty string (which is the default) existing notification popup is removed if any.

    Returns void

Protected Abstract startEditing

  • startEditing(): void

Protected updatePosition

  • updatePosition(): void

Protected validate

  • validate(): void

Generated using TypeDoc