From cf74fc03e88f6b361361ce70feb2edc298df16c0 Mon Sep 17 00:00:00 2001 From: Anurag Roy Date: Mon, 12 Feb 2024 23:18:44 +0530 Subject: [PATCH] Move gradient to table cell instead of table row --- app/components/TableCard.tsx | 1 - app/components/ui/table.tsx | 28 +++++++++++++--------------- 2 files changed, 13 insertions(+), 16 deletions(-) diff --git a/app/components/TableCard.tsx b/app/components/TableCard.tsx index dd95c87c..9255b2dc 100644 --- a/app/components/TableCard.tsx +++ b/app/components/TableCard.tsx @@ -54,7 +54,6 @@ export default function TableCard({ & { - width?: string; - } + React.HTMLAttributes >(({ className, ...props }, ref) => ( )); @@ -93,14 +84,21 @@ TableHead.displayName = "TableHead"; const TableCell = React.forwardRef< HTMLTableCellElement, - React.TdHTMLAttributes ->(({ className, ...props }, ref) => ( + React.TdHTMLAttributes & { width?: string } +>(({ className, width, ...props }, ref) => ( )); @@ -120,11 +118,11 @@ TableCaption.displayName = "TableCaption"; export { Table, - TableHeader, TableBody, + TableCaption, + TableCell, TableFooter, TableHead, + TableHeader, TableRow, - TableCell, - TableCaption, };