table.tsx — ui Source File
Architecture documentation for table.tsx, a tsx file in the ui codebase. 2 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR a6c725f3_d1c3_14f5_f1cf_9423256f07e4["table.tsx"] 1d141819_425e_b5fd_4c8e_32f7c6a42cf2["react"] a6c725f3_d1c3_14f5_f1cf_9423256f07e4 --> 1d141819_425e_b5fd_4c8e_32f7c6a42cf2 3d9438e8_7604_787c_4898_907262aff28b["utils"] a6c725f3_d1c3_14f5_f1cf_9423256f07e4 --> 3d9438e8_7604_787c_4898_907262aff28b style a6c725f3_d1c3_14f5_f1cf_9423256f07e4 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
"use client"
import * as React from "react"
import { cn } from "@/examples/base/lib/utils"
function Table({ className, ...props }: React.ComponentProps<"table">) {
return (
<div
data-slot="table-container"
className="relative w-full overflow-x-auto"
>
<table
data-slot="table"
className={cn("w-full caption-bottom text-sm", className)}
{...props}
/>
</div>
)
}
function TableHeader({ className, ...props }: React.ComponentProps<"thead">) {
return (
<thead
data-slot="table-header"
className={cn("[&_tr]:border-b", className)}
{...props}
/>
)
}
function TableBody({ className, ...props }: React.ComponentProps<"tbody">) {
return (
<tbody
data-slot="table-body"
className={cn("[&_tr:last-child]:border-0", className)}
{...props}
/>
)
}
function TableFooter({ className, ...props }: React.ComponentProps<"tfoot">) {
return (
<tfoot
data-slot="table-footer"
className={cn(
"bg-muted/50 border-t font-medium [&>tr]:last:border-b-0",
className
)}
{...props}
/>
)
}
function TableRow({ className, ...props }: React.ComponentProps<"tr">) {
return (
<tr
data-slot="table-row"
className={cn(
"hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",
className
)}
{...props}
/>
)
}
function TableHead({ className, ...props }: React.ComponentProps<"th">) {
return (
<th
data-slot="table-head"
className={cn(
"text-foreground h-10 px-2 text-start align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pe-0",
className
)}
{...props}
/>
)
}
function TableCell({ className, ...props }: React.ComponentProps<"td">) {
return (
<td
data-slot="table-cell"
className={cn(
"p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pe-0",
className
)}
{...props}
/>
)
}
function TableCaption({
className,
...props
}: React.ComponentProps<"caption">) {
return (
<caption
data-slot="table-caption"
className={cn("text-muted-foreground mt-4 text-sm", className)}
{...props}
/>
)
}
export {
Table,
TableHeader,
TableBody,
TableFooter,
TableHead,
TableRow,
TableCell,
TableCaption,
}
Domain
Subdomains
Functions
Dependencies
- react
- utils
Source
Frequently Asked Questions
What does table.tsx do?
table.tsx is a source file in the ui codebase, written in tsx. It belongs to the DocumentationAtlas domain, ContentSourcing subdomain.
What functions are defined in table.tsx?
table.tsx defines 8 function(s): Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow.
What does table.tsx depend on?
table.tsx imports 2 module(s): react, utils.
Where is table.tsx in the architecture?
table.tsx is located at apps/v4/examples/base/ui-rtl/table.tsx (domain: DocumentationAtlas, subdomain: ContentSourcing, directory: apps/v4/examples/base/ui-rtl).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free