interface SheetProps {
    columnHeaderProps?: Partial<SheetHeadersProps<IColumnHeader, ColumnHeaderJSON, ColumnHeaderUpdate>>;
    editStateAndCoords?: EditorStateAndCoords<ICellModel, string>;
    getCellEditor?: ((props, coords) => ReactElement<CellEditorProps<ICellModel, string> & CellEditorRefAttribute, string | JSXElementConstructor<any>>);
    gridProps: GridProps;
    gridStyle?: GridStyle;
    model: ISheetModel;
    notifier?: Notifier;
    onCommandsChange?: ((commands) => void);
    onEditStateAndCoordsChange?: ((editStateAndCoords) => void);
    onGoto?: ((location) => Promise<IWorkbookRange>);
    onRepeatCommandChange?: ((command) => void);
    onSelectionDrag?: ((selection) => void);
    onSheetContextMenu?: ((location) => void);
    onViewportChange?: ((view) => void);
    overlays?: ((view) => ReactNode)[];
    renderDrawing?: ((props) => ReactElement<any, string | JSXElementConstructor<any>>);
    rowHeaderProps?: Partial<SheetHeadersProps<IRowHeader, RowHeaderJSON, RowHeaderUpdate>>;
    scrollPaneProps?: ScrollPaneProps;
    showColumnHeaders?: boolean;
    showRowHeaders?: boolean;
    showScrollbars?: boolean;
    viewportComponent?: ReactNode;
    onCloseTooltip?(): void;
    onElementLoad?(): void;
    onMoveCell?(from, to, cell?): CellUpdate;
    onShowColumnTooltip?(properties): void;
    onShowRowTooltip?(properties): void;
    onShowTooltip?(properties): void;
}

Hierarchy (view full)

Properties

columnHeaderProps?: Partial<SheetHeadersProps<IColumnHeader, ColumnHeaderJSON, ColumnHeaderUpdate>>
editStateAndCoords?: EditorStateAndCoords<ICellModel, string>
getCellEditor?: ((props, coords) => ReactElement<CellEditorProps<ICellModel, string> & CellEditorRefAttribute, string | JSXElementConstructor<any>>)

Inject custom editors based on a cell. This should not return null but rather can canEdit. This is called during placement after scrolling and other bookkeeping has occurred

Type declaration

gridProps: GridProps

Customize the grid.

Remarks

Not all props are passed through.

gridStyle?: GridStyle
notifier?: Notifier
onCommandsChange?: ((commands) => void)

Notify that there is a new map of commands

Type declaration

    • (commands): void
    • Parameters

      Returns void

onEditStateAndCoordsChange?: ((editStateAndCoords) => void)

Type declaration

onGoto?: ((location) => Promise<IWorkbookRange>)

Type declaration

onRepeatCommandChange?: ((command) => void)

Notify that there is a new repeatable command

Type declaration

    • (command): void
    • Parameters

      Returns void

onSelectionDrag?: ((selection) => void)

When selection is being dragged this will be fired. At selectionDragend this will be fired with a null selection

Type declaration

onSheetContextMenu?: ((location) => void)

Fire when a contentMenu is requested

Type declaration

onViewportChange?: ((view) => void)

Fired when the view port changes. This is in pixel coordinates and slightly different then viewable cells because off screen location bounds could change

Type declaration

overlays?: ((view) => ReactNode)[]

Render an element directly onto a gridView.

Type declaration

renderDrawing?: ((props) => ReactElement<any, string | JSXElementConstructor<any>>)

Render components for drawing elements. If not provided drawings will not be rendered.

Type declaration

    • (props): ReactElement<any, string | JSXElementConstructor<any>>
    • Parameters

      Returns ReactElement<any, string | JSXElementConstructor<any>>

Returns

rowHeaderProps?: Partial<SheetHeadersProps<IRowHeader, RowHeaderJSON, RowHeaderUpdate>>
scrollPaneProps?: ScrollPaneProps

Allow for customizations of scrollbar

showColumnHeaders?: boolean

Show the column headers

showRowHeaders?: boolean

Show the row headers

showScrollbars?: boolean

Show the scrollbars

viewportComponent?: ReactNode

Methods

  • Returns void

  • Called when the sheet has been loaded

    Returns void