Options
All
  • Public
  • Public/Protected
  • All
Menu

Properties of the ReactDataSheet component.

Type parameters

  • T: Cell<T, V>

  • V

Hierarchy

  • DataSheetProps

Index

Properties

Optional attributesRenderer

attributesRenderer: AttributesRenderer<T, V>

Optional function to add attributes to the rendered cell element. It should return an object with properties corresponding to the name and vales of the attributes you wish to add.

Optional cellRenderer

cellRenderer: CellRenderer<T, V>

Optional function or React Component to render each cell element. The default renders a td element.

Optional className

className: undefined | string

data

data: T[][]

Array of rows and each row should contain the cell objects to display.

Optional dataEditor

dataEditor: DataEditor<T, V>

Optional function or React Component to render a custom editor. Affects every cell in the sheet. Affects every cell in the sheet. See cell options to override individual cells.

Optional dataRenderer

dataRenderer: DataRenderer<T, V>

Method to render the underlying value of the cell function(cell, i, j). This data is visible once in edit mode.

Optional keyFn

keyFn: undefined | function

Optional. Function to set row key.

Optional onCellsChanged

onCellsChanged: CellsChangedHandler<T, V>

onCellsChanged handler: function(arrayOfChanges[, arrayOfAdditions]) {}, where changes is an array of objects of the shape {cell, row, col, value}.

Optional onContextMenu

onContextMenu: ContextMenuHandler<T, V>

Context menu handler : function(event, cell, i, j).

Optional onSelect

onSelect: undefined | function

Optional. Calls the function whenever the user changes selection

Optional overflow

overflow: "wrap" | "nowrap" | "clip"

Grid default for how to render overflow text in cells.

Optional parsePaste

parsePaste: PasteParser

If set, the function will be called with the raw clipboard data. It should return an array of arrays of strings. This is useful for when the clipboard may have data with irregular field or line delimiters. If not set, rows will be split with line breaks and cells with tabs.

Optional rowRenderer

rowRenderer: RowRenderer<T, V>

Optional function or React Component to render each row element. The default renders a element.

Optional selected

selected: Selection | null

Optional. Passing a selection format will make the selection controlled, pass a null for usual behaviour

Optional sheetRenderer

sheetRenderer: SheetRenderer<T, V>

Optional function or React Component to render the main sheet element. The default renders a table element.

valueRenderer

valueRenderer: ValueRenderer<T, V>

Method to render the value of the cell function(cell, i, j). This is visible by default.

Optional valueViewer

valueViewer: ValueViewer<T, V>

Optional function or React Component to customize the way the value for each cell in the sheet is displayed. Affects every cell in the sheet. See cell options to override individual cells.

Generated using TypeDoc