import type { SxProps } from "@mui/material";
import { ReactNode } from "react";
import type React from "react";
export type ColumnDef<T> = {
    id: string;
    header: string;
    width?: string | number;
    flex?: number;
    minWidth?: number;
    render: (row: T, index: number) => ReactNode;
};
export type MenuItem = {
    label: string;
    onClick?: () => void;
    href?: string;
    icon?: ReactNode;
};
export type DataTableProps<T> = {
    testId?: string;
    columns: ColumnDef<T>[];
    rows: T[];
    getRowId: (row: T) => string;
    rowCount?: number;
    isLoading?: boolean;
    skeletonRows?: number;
    emptyMessage?: string;
    rowActions?: (row: T) => MenuItem[];
    onRowClick?: (row: T, event: React.MouseEvent) => void;
    /** Retorna o href para cada row, habilitando right-click/Ctrl+Click "Abrir em nova aba" */
    getRowHref?: (row: T) => string;
    autoRowHeight?: boolean;
    sx?: SxProps;
    overrideAction?: (row: T) => ReactNode;
    overrideActionHeader?: ReactNode;
    /** When provided, enables expandable tree rows. Returns the children of a given row. */
    getSubRows?: (row: T) => T[];
};
