UNPKG

react-pdf-builder

Version:
43 lines (42 loc) 2.29 kB
import React from 'react'; import { SwatchColor } from '../../themes/ColorScheme'; import { Style } from '../Style'; import { BoxProps } from '../layout/Box'; export interface TableProps extends BoxProps { /** Optional. When `true`, odd rows of table will be striped. */ striped?: boolean; /** Optional. Styles used for the striped rows. */ stripeStyle?: Style; /** Optional. When `true`, even rows of table will be striped. */ inverseStriped?: boolean; /** Optional. Opacity of the background for striped rows with a swatch. */ stripeOpacity?: number; /** Optional. Styles used for each row. Use this to customize the table further. */ rowStyle?: Style; /** Optional. Styles used for each cell. Use this to customize the table further. */ cellStyle?: Style; /** Optional. When `true`, all rows and cells will have a border on all edges. */ bordered?: boolean; /** Optional. When `true`, the outside edges of the table will have a border. */ borderedOutside?: boolean; /** Optional. When `true`, borders will be used on edges inside the table and not facing the outside. */ borderedInside?: boolean; /** Optional. When `true`, vertical edges will have borders. */ borderedVertical?: boolean; /** Optional. When `true`, horizontal edges will have borders. */ borderedHorizontal?: boolean; /** Optional. Specify the color for the borders. */ borderColor?: string; /** Optional. Specify the border style. Default `solid`. */ borderStyle?: 'dashed' | 'dotted' | 'solid'; /** Optional. Specify the width for the borders. */ borderWidth?: string | number; /** Optional. Specify widths for the columns in the table. By default, all columns will be divided evenly. */ colWidths?: (string | number)[]; /** Optional. One of the [swatch color names](https://justinmahar.github.io/react-pdf-builder/?path=/docs/documentation-themes--docs#swatch-colors) from the theme, as a string. */ swatch?: SwatchColor; } /** * Read the [full documentation for Table](https://justinmahar.github.io/react-pdf-builder/?path=/docs/documentation-components-tables-table--docs) */ export declare const Table: ({ children, className, style, ...props }: TableProps) => React.JSX.Element;