mirror of
https://github.com/hex248/sprint.git
synced 2026-02-08 02:33:01 +00:00
hoverEffect configuration on TableRow
This commit is contained in:
@@ -11,9 +11,9 @@ export function IssuesTable({
|
||||
return (
|
||||
<Table>
|
||||
<TableHeader>
|
||||
<TableRow>
|
||||
<TableRow hoverEffect={false}>
|
||||
{(columns.id == null || columns.id === true) && (
|
||||
<TableHead className="w-[0px] border-r">ID</TableHead>
|
||||
<TableHead className="w-[1px] border-r">ID</TableHead>
|
||||
)}
|
||||
{(columns.title == null || columns.title === true) && <TableHead>Title</TableHead>}
|
||||
{(columns.description == null || columns.description === true) && (
|
||||
|
||||
@@ -30,12 +30,17 @@ function TableFooter({ className, ...props }: React.ComponentProps<"tfoot">) {
|
||||
);
|
||||
}
|
||||
|
||||
function TableRow({ className, ...props }: React.ComponentProps<"tr">) {
|
||||
function TableRow({
|
||||
className,
|
||||
hoverEffect = true,
|
||||
...props
|
||||
}: React.ComponentProps<"tr"> & { hoverEffect?: boolean }) {
|
||||
return (
|
||||
<tr
|
||||
data-slot="table-row"
|
||||
className={cn(
|
||||
"hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",
|
||||
"data-[state=selected]:bg-muted border-b transition-colors",
|
||||
hoverEffect && "hover:bg-muted/40",
|
||||
className,
|
||||
)}
|
||||
{...props}
|
||||
|
||||
Reference in New Issue
Block a user