Excel-style editing (TableOptionsIf.editing): one editor element above the edited cell (not inside it – the cells are rebuilt on every render pass, the editor survives scrolling and repaints), typing to edit, Enter/Tab/arrow keys commit and move, Escape cancels, a click elsewhere commits. Created by TableScope only with the option (tableScope.cellEditorService).

Since

1.1.99

Hierarchy

  • CellEditorService

Constructors

Properties

Methods

  • Writes the editor's value (through editInputPipe and validate; batch edit: marks it) and moves on. An invalid value keeps the editor open (aria-invalid, the message is announced and the title).

    Parameters

    • Optional move: EditMove = "none"

      where the active cell goes afterwards

    • Optional opts: {
          deferRepaint?: boolean;
          fillSelection?: boolean;
          tab?: boolean;
      } = {}

      Ctrl/⌘+Enter: into all selected cells; a mouse click: repaint after the click (a repaint between mousedown and click loses the click)

      • Optional deferRepaint?: boolean
      • Optional fillSelection?: boolean
      • Optional tab?: boolean

    Returns boolean

    true if the editor closed

  • The id of the editor element (and of the formula popups) if (rowIndex, columnIndex) is the edited cell – the cell gets aria-owns with it (screen readers find the editor in the cell, not as a stray child of the grid).

    Parameters

    • rowIndex: number

      display row index

    • columnIndex: number

      model column index

    Returns undefined | string

    the id

  • True if this service edits the column (otherwise the column's own getEditRenderer – or an own tableOptions.getEditRenderer of the app – edits inside the cell, as before 1.1.99).

    Parameters

    • columnIndex: number

      model column index

    Returns boolean

    true for the editor above the cell

  • Opens the editor on a body cell.

    Parameters

    • rowIndex: number

      display row index

    • columnIndex: number

      model column index

    • Optional opts: {
          imeStart?: boolean;
          mode?: CellEditMode;
          textSelection?: "all" | "end";
          typedText?: string;
      } = {}

      "enter" with the typed character, or "edit" (F2: caret at the end)

      • Optional imeStart?: boolean
      • Optional mode?: CellEditMode
      • Optional textSelection?: "all" | "end"
      • Optional typedText?: string

    Returns boolean

    true if the editor is open