UNPKG

1.39 kBTypeScriptView Raw
1import * as React from 'react';
2import { SxProps } from '@mui/system';
3import { Theme } from '..';
4import { OverridableComponent, OverrideProps } from '../OverridableComponent';
5import { TableContainerClasses } from './tableContainerClasses';
6
7export interface TableContainerOwnProps {
8 /**
9 * The content of the component, normally `Table`.
10 */
11 children?: React.ReactNode;
12 /**
13 * Override or extend the styles applied to the component.
14 */
15 classes?: Partial<TableContainerClasses>;
16 /**
17 * The system prop that allows defining system overrides as well as additional CSS styles.
18 */
19 sx?: SxProps<Theme>;
20}
21
22export interface TableContainerTypeMap<
23 AdditionalProps = {},
24 RootComponent extends React.ElementType = 'div',
25> {
26 props: AdditionalProps & TableContainerOwnProps;
27 defaultComponent: RootComponent;
28}
29/**
30 *
31 * Demos:
32 *
33 * - [Table](https://mui.com/material-ui/react-table/)
34 *
35 * API:
36 *
37 * - [TableContainer API](https://mui.com/material-ui/api/table-container/)
38 */
39declare const TableContainer: OverridableComponent<TableContainerTypeMap>;
40
41export type TableContainerProps<
42 RootComponent extends React.ElementType = TableContainerTypeMap['defaultComponent'],
43 AdditionalProps = {},
44> = OverrideProps<TableContainerTypeMap<AdditionalProps, RootComponent>, RootComponent> & {
45 component?: React.ElementType;
46};
47
48export default TableContainer;