| 5 | import { cn } from "../lib/utils"; |
| 6 | |
| 7 | function Table({ className, ...props }: React.ComponentProps<"table">) { |
| 8 | return ( |
| 9 | <div data-slot="table-container" className="relative w-full overflow-x-auto"> |
| 10 | {/* oxlint-disable-next-line react/forbid-elements */} |
| 11 | <table |
| 12 | data-slot="table" |
| 13 | className={cn("w-full caption-bottom text-sm", className)} |
| 14 | {...props} |
| 15 | /> |
| 16 | </div> |
| 17 | ); |
| 18 | } |
| 19 | |
| 20 | function TableHeader({ className, ...props }: React.ComponentProps<"thead">) { |
| 21 | return <thead data-slot="table-header" className={cn("[&_tr]:border-b", className)} {...props} />; |