import { Color } from '@ionic/core'; import { TemplateRef } from '@angular/core'; /** * Column definition for the data table. */ export interface DataTableColumn { /** Unique identifier for the column */ key: string; /** Header label */ label: string; /** Property path in the data object (supports dot notation) */ field?: string; /** Column width (CSS value) */ width?: string; /** Minimum width */ minWidth?: string; /** Maximum width */ maxWidth?: string; /** Text alignment */ align?: 'left' | 'center' | 'right'; /** Whether the column is sortable */ sortable?: boolean; /** Custom sort function */ sortFn?: (a: T, b: T) => number; /** Whether the column is visible */ visible?: boolean; /** Custom cell template */ cellTemplate?: TemplateRef; /** Custom header template */ headerTemplate?: TemplateRef; /** Format function for cell value */ format?: (value: any, row: T) => string; /** CSS class for the column */ cssClass?: string; /** Whether this is a sticky column */ sticky?: 'start' | 'end'; } /** * Sort configuration. */ export interface DataTableSort { /** Column key to sort by */ column: string; /** Sort direction */ direction: 'asc' | 'desc'; } /** * Pagination configuration. */ export interface DataTablePagination { /** Current page (0-indexed) */ page: number; /** Items per page */ pageSize: number; /** Total number of items */ total: number; /** Available page size options */ pageSizeOptions?: number[]; } /** * Selection configuration. */ export interface DataTableSelection { /** Selection mode */ mode: 'none' | 'single' | 'multiple'; /** Currently selected items */ selected: T[]; /** Function to get unique ID from row */ trackBy?: (row: T) => any; } /** * Row click event. */ export interface DataTableRowClickEvent { /** The row data */ row: T; /** Row index */ index: number; /** Original mouse event */ event: MouseEvent; } /** * Selection change event. */ export interface DataTableSelectionChangeEvent { /** Selected rows */ selected: T[]; /** Row that was changed (if single change) */ changedRow?: T; /** Action performed */ action: 'select' | 'deselect' | 'selectAll' | 'deselectAll'; } /** * Sort change event. */ export interface DataTableSortChangeEvent { /** Column key */ column: string; /** Sort direction */ direction: 'asc' | 'desc' | null; } /** * Page change event. */ export interface DataTablePageChangeEvent { /** New page number */ page: number; /** Page size */ pageSize: number; /** Previous page */ previousPage: number; } /** * Empty state configuration. */ export interface DataTableEmptyState { /** Icon to display */ icon?: string; /** Title text */ title?: string; /** Description text */ description?: string; /** Custom template */ template?: TemplateRef; } /** * Loading state configuration. */ export interface DataTableLoadingState { /** Whether data is loading */ loading: boolean; /** Number of skeleton rows to show */ skeletonRows?: number; /** Loading message */ message?: string; } /** * Metadata for the data table component. */ export interface DataTableMetadata { /** Column definitions */ columns: DataTableColumn[]; /** Data rows */ data: T[]; /** Current sort configuration */ sort?: DataTableSort; /** Enable client-side sorting */ clientSort?: boolean; /** Pagination configuration */ pagination?: DataTablePagination; /** Enable client-side pagination */ clientPagination?: boolean; /** Show pagination controls */ showPagination?: boolean; /** Selection configuration */ selection?: DataTableSelection; /** Show selection column */ showSelectionColumn?: boolean; /** Table size variant */ size?: 'small' | 'medium' | 'large'; /** Show borders */ bordered?: boolean; /** Striped rows */ striped?: boolean; /** Hoverable rows */ hoverable?: boolean; /** Fixed header */ stickyHeader?: boolean; /** Table max height (enables scrolling) */ maxHeight?: string; /** Show row numbers */ showRowNumbers?: boolean; /** Row number start */ rowNumberStart?: number; /** Empty state configuration */ emptyState?: DataTableEmptyState; /** Loading state */ loadingState?: DataTableLoadingState; /** Custom CSS class */ cssClass?: string; /** Header color */ headerColor?: Color; /** Row click enabled */ rowClickable?: boolean; /** Elevation level for box shadow */ elevation?: 'none' | 'low' | 'medium' | 'high'; /** Show gradient accent on top border */ headerGradient?: boolean; /** Checkbox style variant */ checkboxStyle?: 'default' | 'circular'; /** Row selection highlight style */ rowHighlightStyle?: 'background' | 'border-left' | 'both'; /** Row actions template */ actionsTemplate?: TemplateRef; /** Actions column width */ actionsWidth?: string; /** Actions column label */ actionsLabel?: string; /** Table caption for screen readers */ caption?: string; /** ARIA label */ ariaLabel?: string; /** Content class for reactive content */ contentClass?: string; /** Responsive mode: 'scroll' (default) or 'cards' for mobile card view */ responsiveMode?: 'scroll' | 'cards'; /** Breakpoint for card view in pixels. Default: 768 */ responsiveBreakpoint?: number; /** Custom template for mobile card view */ mobileCardTemplate?: TemplateRef; } /** * Default pagination options. */ export declare const DEFAULT_PAGE_SIZE_OPTIONS: number[]; /** * Default empty state. */ export declare const DEFAULT_EMPTY_STATE: DataTableEmptyState;