* feat: add separator support to data table * chore: remove unnecessary comments * chore: move files to more appropriate places * fix: border bottom
12 lines
334 B
TypeScript
12 lines
334 B
TypeScript
export type SeparatorRow = {
|
|
type: "separator";
|
|
label: string;
|
|
className?: string;
|
|
};
|
|
|
|
export type DataTableRow<TData> = TData | SeparatorRow;
|
|
|
|
export function isSeparatorRow<TData>(row: DataTableRow<TData>): row is SeparatorRow {
|
|
return typeof row === "object" && row !== null && "type" in row && row.type === "separator";
|
|
}
|