Skip to content
ProLifetime access for $199, paid once, every future release included
Truffle UI

Benchmark Table

ProNew

Models across, benchmarks down, with the featured model's column tinted and outlined, missing results marked, and a row and column that light under the pointer.

Installation

pnpm dlx shadcn@latest add @viewport/benchmark-table

First time? Add the @viewport registry to components.json. Setup takes one minute.

Usage

The code behind the preview above comes with Truffle Pro.

Props

PropTypeDefault
models*BenchmarkModel[]—
rows*BenchmarkRow[]—
caption*string

A caption for screen readers and search engines.

—
footnoteReact.ReactNode

Notes under the table, e.g. what an asterisk means.

—
highlightBestboolean

Set the best score in each row in bold.

false
accentstring

The featured column's color.

"oklch(0.7 0.12 235)"
surfacestring

The color behind the table. The benchmark column is painted with it, to cover what scrolls underneath.

"var(--background)"
format(value: number) => string(value) => value.toFixed(1)
classNamestring—

Accessibility

  • A real table with a caption, column headers and row headers.
  • A missing result is read as “No result”, not as a dash.
  • Scrolls sideways in a focusable, named region with the benchmark column held in view.
  • Featured scores differ in ink weight as well as tint.