import React from 'react'; import { View } from 'react-native'; import { SpacingProps } from '../../core/utils'; export interface TableData { head?: React.ReactNode[]; body?: React.ReactNode[][]; foot?: React.ReactNode[]; caption?: React.ReactNode; } export interface TableProps extends SpacingProps { children?: React.ReactNode; /** Table data for automatic generation of rows */ data?: TableData; /** Horizontal spacing between cells */ horizontalSpacing?: 'xs' | 'sm' | 'md' | 'lg' | 'xl' | number; /** Vertical spacing between cells */ verticalSpacing?: 'xs' | 'sm' | 'md' | 'lg' | 'xl' | number; /** Add striped styling to rows */ striped?: boolean; /** Highlight rows on hover/press */ highlightOnHover?: boolean; /** Add borders around table */ withTableBorder?: boolean; /** Add borders between columns */ withColumnBorders?: boolean; /** Add borders between rows */ withRowBorders?: boolean; /** Caption position */ captionSide?: 'top' | 'bottom'; /** Table layout mode */ layout?: 'auto' | 'fixed'; /** Variant of table layout */ variant?: 'default' | 'vertical'; /** Enable tabular numbers for better number alignment */ tabularNums?: boolean; /** Make table take full width of container */ fullWidth?: boolean; /** Column width configuration for auto-sizing */ columns?: Array<{ /** Column key for identification */ key?: string; /** Column width strategy */ width?: number | string | 'auto' | 'min-content' | 'max-content'; /** Minimum column width */ minWidth?: number; /** Maximum column width */ maxWidth?: number; /** Flex grow factor */ flex?: number; }>; /** Additional styles */ style?: any; } export interface TableScrollContainerProps extends SpacingProps { children?: React.ReactNode; /** Minimum width before scrolling kicks in */ minW?: number; /** Maximum height before vertical scrolling */ maxH?: number; /** Scroll type for web */ type?: 'native' | 'custom'; style?: any; [key: string]: any; } export interface TableSectionProps extends SpacingProps { children?: React.ReactNode; style?: any; [key: string]: any; } export interface TableRowProps extends SpacingProps { children?: React.ReactNode; /** Background color override */ bg?: string; /** Row selection state */ selected?: boolean; /** Press handler */ onPress?: () => void; style?: any; [key: string]: any; } export interface TableCellProps extends SpacingProps { children?: React.ReactNode; /** Cell width (useful for fixed layout) */ w?: number | string; /** Text alignment */ align?: 'left' | 'center' | 'right'; /** Minimum width for auto-sizing */ minW?: number; /** Maximum width for auto-sizing */ maxW?: number; /** Flex grow factor for flexible sizing */ flex?: number; /** Width strategy for responsive behavior */ widthStrategy?: 'auto' | 'min-content' | 'max-content' | 'fixed'; style?: any; [key: string]: any; } export declare const TableTh: React.ForwardRefExoticComponent & React.RefAttributes>; export declare const TableTd: React.ForwardRefExoticComponent & React.RefAttributes>; export declare const TableTr: React.ForwardRefExoticComponent & React.RefAttributes>; export declare const TableThead: React.ForwardRefExoticComponent & React.RefAttributes>; export declare const TableTbody: React.ForwardRefExoticComponent & React.RefAttributes>; export declare const TableTfoot: React.ForwardRefExoticComponent & React.RefAttributes>; export declare const TableCaption: React.ForwardRefExoticComponent & React.RefAttributes>; export declare const TableScrollContainer: React.ForwardRefExoticComponent & React.RefAttributes>; export declare const Table: React.ForwardRefExoticComponent> & { Th: typeof TableTh; Td: typeof TableTd; Tr: typeof TableTr; Thead: typeof TableThead; Tbody: typeof TableTbody; Tfoot: typeof TableTfoot; Caption: typeof TableCaption; ScrollContainer: typeof TableScrollContainer; }; export default Table;