UNPKG

@navinc/base-react-components

Version:
36 lines (32 loc) 1.14 kB
type AlignType = 'right' | 'center' | 'left'; export type HeaderType = { label: string; field: string; align?: AlignType; width?: string; }; type RowType = Record<string, any>; export type TableProps = { /** Required for accessibility, to label the table */ name: string; headers: HeaderType[]; rows?: RowType[]; /** Makes the table headers sticky when table height is limited. */ stickyHeader?: boolean; /** Limits the table height. Takes a string px value. */ maxHeight?: string; }; /** Table component based on MUI Table. Only meant for displaying data, not interacting with it. ``` type HeaderType = { label: string field: string align?: 'right' | 'center' | 'left' width?: string } type RowType = Record<string, any> ``` */ export declare const Table: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<TableProps, never>> & string & Omit<({ name, headers, rows, stickyHeader, maxHeight, ...rest }: TableProps) => import("react/jsx-runtime").JSX.Element | null, keyof import("react").Component<any, {}, any>>; export {};