UNPKG

@clive-cudi/geist-ui

Version:

Modern and minimalist React UI library.

27 lines (26 loc) 1.3 kB
import React from 'react'; import { TableDataItemBase, TableOnCellClick, TableOnChange, TableOnRowClick, TableRowClassNameHandler } from "./table-types"; import { ScaleProps } from "../use-scale"; interface Props<TableDataItem extends TableDataItemBase> { data?: Array<TableDataItem>; initialData?: Array<TableDataItem>; emptyText?: string; hover?: boolean; onRow?: TableOnRowClick<TableDataItem>; onCell?: TableOnCellClick<TableDataItem>; onChange?: TableOnChange<TableDataItem>; className?: string; rowClassName?: TableRowClassNameHandler<TableDataItem>; } declare type NativeAttrs = Omit<React.TableHTMLAttributes<any>, keyof Props<any>>; export declare type TableProps<TableDataItem extends TableDataItemBase> = Props<TableDataItem> & NativeAttrs; declare function TableComponent<TableDataItem extends TableDataItemBase>(tableProps: React.PropsWithChildren<TableProps<TableDataItem>>): JSX.Element; declare namespace TableComponent { var displayName: string; var Column: { <TableDataItem extends TableDataItemBase>(columnProps: React.PropsWithChildren<import("./table-column").TableColumnProps<TableDataItem>>): null; displayName: string; }; } declare const _default: typeof TableComponent & ScaleProps; export default _default;