This commit is contained in:
2025-11-26 15:14:29 -03:00
parent 0d3d9ac7d3
commit d3ccfb4775
32 changed files with 496 additions and 474 deletions

View File

@@ -271,7 +271,10 @@ export function DataTable<TData, TValue>({
<TableRow
key={row.id}
data-state={isSelected && 'selected'}
className="group has-data-[state=open]:bg-muted transition-none hover:bg-muted relative z-5"
className="group has-data-[state=open]:bg-muted
data-[state=selected]:bg-gray-50
dark:data-[state=selected]:bg-neutral-900
transition-none hover:bg-muted relative z-5"
>
{row.getVisibleCells().map((cell) => {
const isPinned = cell.column.getIsPinned()
@@ -281,8 +284,13 @@ export function DataTable<TData, TValue>({
key={cell.id}
className={cn(
isPinned &&
'lg:sticky z-1 bg-card group-hover:bg-muted group-has-data-[state=open]:bg-muted',
isPinned && isSelected && 'bg-muted',
'lg:sticky z-1 bg-card group-has-data-[state=open]:bg-muted',
isPinned &&
!isSelected &&
'group-hover:bg-muted',
isPinned &&
isSelected &&
'bg-gray-50 dark:bg-neutral-900',
isPinned === 'left' && 'left-0',
isPinned === 'right' && 'right-0',
// Override the shadcn class

View File

@@ -4,8 +4,7 @@ export type User = {
id: string
name: string
email: string
cpf?: string
cnpj?: string
cpf: string
}
export const headers = {