import { TableProps } from '../table/Table'; import { TableSorting } from '../table/useTable'; import { TdHTMLAttributes } from 'react'; export interface TableCellSortableLabels { ascending?: string; descending?: string; neutral?: string; } export interface TableCellSortable { /** If provided, sets direction state on the sort button */ direction?: 'asc' | 'desc'; /** If provided, overrides 'Sortable' | 'Ascending' | 'Descending' labels on the sorting button */ labels?: TableCellSortableLabels; /** If provided, intercepts sorting click and is run before default sorting */ onClick?: (direction?: TableCellSortable['direction']) => void; /** If provided, will sort the table on the string returned from this function. Null disengages default sorting */ sortBy?: ((props: any) => string) | null; } export interface TableCellProps extends TdHTMLAttributes { as?: 'td' | 'th'; compact: TableProps['feCompact']; index: number; scope?: 'col' | 'colgroup' | 'row' | 'rowgroup'; sortable?: TableCellSortable; sorting?: TableSorting; } /** * Renders a table cell () */ declare const TableCell: { ({ children, compact, index, sortable, sorting, ...rest }: TableCellProps): import("react/jsx-runtime").JSX.Element; displayName: string; }; export default TableCell;