import { CardBackgroundProps } from '../CardBackground/CardBackground'; import { IconComponent } from '../../Icons/types'; export type { InteractionConfig, InteractionStateConfig, RowCellInteraction, } from '../CardBackground/CardBackground'; export interface TableProps { columns: string[]; maxHeight?: string; className?: string; children?: React.ReactNode; ref?: React.Ref; } export interface TableHeaderProps { cardBackground?: CardBackgroundProps; className?: string; children: React.ReactNode; } export interface HeadRowProps { className?: string; children: React.ReactNode; ref?: React.Ref; } export interface HeaderCellProps { label: string; leadingIcon?: IconComponent; showLeadingIcon?: boolean; sort?: 'none' | 'asc' | 'desc'; onSort?: () => void; cardBackground?: CardBackgroundProps; disabled?: boolean; forced?: 'default' | 'hover' | 'pressed'; className?: string; } export interface TableRowProps { selected?: boolean; disabled?: boolean; forced?: 'default' | 'hover' | 'pressed'; onClick?: (e: React.MouseEvent & { disabled: boolean; selected: boolean; }) => void; className?: string; children: React.ReactNode; showDivider?: boolean; ref?: React.Ref; } interface RowCellBase { disabled?: boolean; forced?: 'default' | 'hover' | 'pressed'; cardBackground?: CardBackgroundProps; className?: string; showDivider?: boolean; } export interface RowCellTitle extends RowCellBase { variant: 'title'; title: string; badgeSlot?: React.ReactNode; truncate?: boolean; } export interface RowCellText extends RowCellBase { variant: 'text'; label: string; description?: string; textAlign?: 'left' | 'center' | 'right'; truncate?: boolean; } export interface RowCellContent extends RowCellBase { variant: 'content'; children: React.ReactNode; } export type RowCellProps = RowCellTitle | RowCellText | RowCellContent; export interface TableFooterProps { cardBackground?: CardBackgroundProps; totalResults?: string; showPageSize?: boolean; pageSize?: number; pageSizeOptions?: number[]; onPageSizeChange?: (size: number) => void; showPagination?: boolean; currentPage?: number; totalPages?: number; onPageChange?: (page: number) => void; showJumpToPage?: boolean; className?: string; children?: React.ReactNode; ref?: React.Ref; } export interface RowContextValue { disabled?: boolean; showDivider?: boolean; }