"use client" import type { ReactNode } from "react" import type { Table } from "@tanstack/react-table" import { DataGrid, DataGridContainer, DataGridPagination, DataGridTable, type DataGridProps, } from "@/components/reui/data-grid" import { DATA_GRID_CONTAINER_CLASS, DEFAULT_DATA_GRID_CLASS_NAMES, DEFAULT_DATA_GRID_LAYOUT, } from "@/components/data-grids/shared/data-grid-layout" interface DataGridShellProps { table: Table recordCount: number children?: ReactNode pagination?: boolean isLoading?: boolean loadingMode?: DataGridProps["loadingMode"] emptyMessage?: ReactNode onRowClick?: DataGridProps["onRowClick"] tableLayout?: DataGridProps["tableLayout"] tableClassNames?: DataGridProps["tableClassNames"] } function DataGridShell({ table, recordCount, children, pagination = false, isLoading, loadingMode, emptyMessage, onRowClick, tableLayout = DEFAULT_DATA_GRID_LAYOUT, tableClassNames = DEFAULT_DATA_GRID_CLASS_NAMES, }: DataGridShellProps) { return ( {children ?? ( <> {pagination && recordCount > 0 && ( )} )} ) } export { DataGridShell, type DataGridShellProps }