@react-md/table
Version:
Create responsive data tables and accessible fixed tables
36 lines (35 loc) • 1.32 kB
TypeScript
import type { CSSProperties } from "react";
import type { TextIconSpacingProps } from "@react-md/icon";
import type { TableCellHorizontalAlignment } from "./config";
export declare type SortOrder = "ascending" | "descending" | "none" | "other";
export interface TableCellContentProps extends TextIconSpacingProps {
/**
* An optional id for the sort order button.
*/
id?: string;
/**
* An optional style for the sort order button.
*/
style?: CSSProperties;
/**
* The current sort order for this cell. Setting this to `null` will prevent
* the button from being rendered.
*/
sortOrder?: SortOrder;
/**
* Boolean if the icon should be rotated.
*/
rotated?: boolean;
/**
* @remarks \@since 4.0.3
* @see {@link TableCellHorizontalAlignment}
*/
hAlign?: TableCellHorizontalAlignment;
}
/**
* This is mostly an internal component since it is automatically used within
* the `TableCell` component but this will conditionally wrap the `children`
* within an `UnstyledButton` to make a clickable cell. This is really to help
* with sort behavior within headers.
*/
export declare const TableCellContent: import("react").ForwardRefExoticComponent<TableCellContentProps & import("react").RefAttributes<HTMLButtonElement>>;