fix: Some recently discovered type errors breaking build (not sure why undetected before) (#18432)

This commit is contained in:
Alex van Andel authored and GitHub committed 2024-12-31 13:50:43 +00:00
1 parent 557bd8bf25
commit 890fc92148
10 files changed
+19 -21

No files matched your search

@@ -14,7 +14,7 @@ import { Icon, TableNew, TableBody, TableCell, TableHead, TableHeader, TableRow
import { usePersistentColumnResizing } from "../lib/resizing";
export interface DataTableProps<TData, TValue> {
export type DataTableProps<TData, TValue> = {
table: ReactTableType<TData>;
tableContainerRef: React.RefObject<HTMLDivElement>;
isPending?: boolean;
@@ -26,7 +26,7 @@ export interface DataTableProps<TData, TValue> {
children?: React.ReactNode;
identifier?: string;
enableColumnResizing?: boolean;
}
};
export function DataTable<TData, TValue>({
table,
@@ -89,7 +89,8 @@ export function DataTable<TData, TValue>({
usePersistentColumnResizing({
enabled: Boolean(enableColumnResizing),
table,
identifier,
// TODO: Figure out why 'identifier' somehow types to string | null
identifier: identifier || undefined,
});
return (