Examples
Default
Interactive rows
Variant — lg (56px rows)
With scroll indicator
Fixed height (rows scroll under the header)
TableMobileRow — Default
TableMobileRow — Without Badge
TableMobileRow — Wrap
Props
Table
Semantic<table> element. Place inside TableScrollArea.
Takes no props of its own. Accepts all standard table attributes, including className.
TableBody
<tbody> wrapper. Removes the bottom border on cells in the final row to match the Figma V2 Table Final Row treatment.
Takes no props of its own. Accepts all standard thead/tbody/tfoot attributes, including className.
TableCard
Surface wrapper for data tables: 12px-radius container with a 0.5px hairline border and no inner padding, so the header, rows andTableCardPagination footer run edge to edge. Provides the size context for TableCell descendants. Compose with TableScrollArea, Table, TableHeader, TableBody, TableRow, TableHead, and TableCell.
Row density applied to
TableCell descendants: 40px rows for md, default and condensed, 48px for comfortable, 56px for lg.TableCardPagination
32px footer that closes aTableCard: previous, “1 of N”, next, then a rows-per-page menu, on surface-table-row. Place it after TableScrollArea inside the card.
Formats the page indicator.
Accessible name of the page navigation.
Accessible name of the rows-per-page menu trigger, followed by the current choice (e.g. “Rows per page, 10 rows”).
TableCell
Body cell: 40px rows (56px when the parentTableCard uses size="lg" or the row holds media), 12px type, transparent background and a 0.5px rule that TableBody drops on the final row. Long text wraps and the row grows; set nowrap on short columns to keep them on one line.
Padding preset for the cell. v2 uses identical padding across variants; values are kept for back-compat.
Alignment and typography preset for common cell types.
TableCellContent
Two-line content slot matching FigmaV2 Table Content — 12px primary line (semibold) over an optional 12px secondary line (regular, muted), so both fit a 40px row. Use inside TableCell for the common stacked-text pattern.
TableCellGroup
Horizontal group for icons, chips, and metadata inside aTableCell (Figma gap-[4px]).
Takes no props of its own. Accepts all standard div attributes, including className.
TableFooter
Takes no props of its own. Accepts all standardthead/tbody/tfoot attributes, including className.
TableHead
Header cell: 32px tall onsurface-table-row, 12px secondary text and a 0.5px bottom rule. Columns sit at least 40px apart, with 16px against the card edges.
TableHeader
<thead> wrapper. Its header cells stay pinned to the top while rows scroll beneath them. Row header cells in TableBody scroll with their rows.
Takes no props of its own. Accepts all standard thead/tbody/tfoot attributes, including className.
TableLineClamp
Clamps child text to a fixed number of lines inside aTableCell.
TableMediaThumbnail
Square photo that fills its frame, used insideTableCell for media columns. At the 40px and 48px sizes its row grows to 56px; the 32px size fits a regular 40px row.
Pixel size of the square thumbnail. At 40 or 48 its row grows to 56px; 32 fits a 40px row.
TableMediaTile
40px tile for aTableCell: a logo or icon (e.g. a social platform) centred on surface-table-row with a 0.5px border, or, with fill, custom media that fills it. Its row grows to 56px. For a plain image URL use TableMediaThumbnail.
Lets the child fill the tile edge to edge (e.g. a video preview) with no border or fill.
TableMobileRow
Stacked row that stands in for a table row on narrow screens (FigmaV2 Table Mobile): a badge and actions line, then a title with a description, closed by a divider.
Trailing controls on the badge line, such as a favourite toggle and a navigation
IconButton.When
true, the title and description wrap onto more lines instead of truncating.TablePillProgressLayout
Vertical layout for pill label +TableProgressTrack in a cell.
Takes no props of its own. Accepts all standard div attributes, including className.
TableProgressTrack
Thin progress track used with badges in table cells (Figma pill + progress). Renders withrole="progressbar" and a default aria-label of "Progress".
TableRow
Table row. A body row holding aTableMediaThumbnail or TableMediaTile grows from 40px to 56px to keep 8px around it. Set interactive on rows that open or expand so they respond to hover.
Marks a body row that opens or expands into more content. The row shows a pointer cursor and eases to
background-secondary while hovered, or while a control inside it has keyboard focus. The row itself is not focusable, so its action must also be on a button or link inside it. With a TableRowLink inside, a click anywhere on the row that is not on another control opens that link.TableRowButton
Action inside a table row (e.g. “Copy”, “View”): a 24px squared secondaryButton with 12px semibold type, so it fits a 40px row. Pass 16px filled icons; they take the secondary icon colour.
Forces the dark-surface treatment regardless of theme. Only honored on
primary, secondary, tertiary, and outline variants; ignored on all others. Use when placing the button on a dark background in a light theme (e.g. an inverted hero or modal)."link" | "text" | "brand" | "primary" | "secondary" | "tertiary" | "outline" | ...
default:"secondary"
Visual style variant of the button.Full type:
"link" | "text" | "brand" | "primary" | "secondary" | "tertiary" | "outline" | "destructive" | "secondaryDestructive" | "white" | "alwaysBlack" | "ai" | "tertiaryDestructive".TableRowLink
The link an interactiveTableRow opens, usually the row’s name. It is a real link, so the keyboard and “open in a new tab” work as on any link, and it is the row’s one tab stop. A click anywhere else on the row, except on another control, opens it too. A TableRowLink portalled out of the row, in a popover or dialog, is an ordinary link and does not take over the row’s click.
Takes no props of its own. Accepts all standard a attributes, including className.
TableScrollArea
Scroll container for the table. Wide tables scroll sideways. When itsTableCard has a bounded height (a flex child of a full-height page, or a set height), the rows scroll inside the card under a pinned header and the card’s footer stays in view. The area fills the card’s height, so in a card taller than its rows the footer sits at the bottom of the card.
No longer needed in v2 —
TableCard handles corner rounding via its own overflow-hidden rounded-3xl. Accepted for back-compat.Deprecated. v2 ignores this prop; safe to remove.Shows a slim horizontal scrollbar beneath the table when the content overflows (Figma
V2 Scroll Bar), with room reserved for it only while the table is wider than its card.TableSortLabel
Sortable column label. A sorted column reads primary with the Arrow Sort Up / Down chevrons; an unsorted one keeps the header colour.Visual indicator of the column’s sort state. When set to
"asc" or "desc", the label turns primary and the Arrow Sort Up / Down chevrons appear next to it, the active direction highlighted.TableStackedText
Two-line primary + secondary text block for “cell + info” patterns.TableStatusDot
Small status indicator dot for table cells (Figma status column). Takes no props of its own. Accepts all standarddiv attributes, including className.
TableToolbar
40px action bar above aTableCard: search on the left, every other control (menus, toggles, buttons) on the right, 24px apart. On phones TableToolbarAction controls go icon-only so the bar fits.
TableToolbarAction
Labelled control forTableToolbar: 12px label followed by a 16px icon. Its 8px side padding is offset by a negative margin, so the label lines up with text around it and the fill extends 8px past the label. It rests on secondary text, fills with Interaction/Hover on hover and while active, and with Neutral Alphas/100 while the menu or popover it triggers is open (data-state="open"). Below the md breakpoint only the icon shows, and the label stays as the accessible name, so a full bar still fits a phone. Works as a plain button or as a DropdownMenuTrigger or PopoverTrigger child.
TableToolbarButton
Call to action forTableToolbar (e.g. “Create New”): a 24px Button squared to the toolbar’s 8px radius with 12px semibold type, so it sits 8px from the bar’s edges. Elsewhere use Button.
Forces the dark-surface treatment regardless of theme. Only honored on
primary, secondary, tertiary, and outline variants; ignored on all others. Use when placing the button on a dark background in a light theme (e.g. an inverted hero or modal)."link" | "text" | "brand" | "primary" | "secondary" | "tertiary" | "outline" | ...
default:"secondary"
Visual style variant of the button.Full type:
"link" | "text" | "brand" | "primary" | "secondary" | "tertiary" | "outline" | "destructive" | "secondaryDestructive" | "white" | "alwaysBlack" | "ai" | "tertiaryDestructive".TableToolbarSearch
Borderless search field for the left slot ofTableToolbar: 16px search icon, 12px text and a clear button once there is a query.
Pass filters to show the applied filters before the input from the md breakpoint up, each with a × button, and onClearFilters for a “Clear all” action after it. The ones that do not fit collapse into a “+N” tag, so the toolbar never grows. Keep filters defined (an empty array when none apply) so the input is not remounted as filters come and go.
Applied filters, shown between the search icon and the input from the
md breakpoint up. Array order is the priority: the leading filters that fit are shown and the rest collapse into a “+N” tag. Keep it defined (an empty array when none apply) so the input is not remounted as filters come and go.Accessible text of the “+N” tag, e.g.
(count) => \${count} more filters`. Pass it whenever filters` is passed, so the hidden count is announced in words. Without it the tag is read as its visible text.Called when “Clear all” is pressed. It shows only with
clearFiltersLabel and an applied filter.TableTruncatedText
One-line text for aTableCell that ends in an ellipsis once it no longer fits, either past maxChars or in a narrower column. The tooltip and the tab stop appear only when the text is actually cut, measured on mount and on every resize, so short text stays plain and out of the tab order. It mounts its own TooltipProvider so it works in apps without one.
Exported types
Also exported from@fanvue/ui: TableBodyProps, TableCardPaginationProps, TableCardProps, TableCellContentProps, TableCellGroupProps, TableCellIntent, TableCellProps, TableCellVariant, TableFooterProps, TableHeaderProps, TableHeadIntent, TableHeadProps, TableLineClampProps, TableMediaThumbnailProps, TableMediaThumbnailSize, TableMediaTileProps, TableMobileRowProps, TablePillProgressLayoutProps, TableProgressTrackProps, TableProps, TableRowButtonProps, TableRowLinkProps, TableRowProps, TableScrollAreaProps, TableSize, TableSortDirection, TableSortLabelProps, TableStackedTextProps, TableStatusDotProps, TableToolbarActionProps, TableToolbarButtonProps, TableToolbarProps, TableToolbarSearchFilter, TableToolbarSearchProps, TableTruncatedTextProps.
Setup: Installation · Theming