Data Table
The table you'll use most: sortable columns, row selection, paging and a compact mode for dense screens.
- Component
- Light and dark
- Updated 5 months ago
Paste this into your agent.
Add sort, select and page through rows to <the page you want it on>. Install it with: npx shadcn add @ollie/data-table Pass columns, rows and rowKey in as props. Handle onSort, onToggleRow and onPage yourself; don't fetch inside the component. Keep the ocean theme tokens.
Other takes
| Invoice | Client | Amount |
|---|---|---|
| INV-1003 | Globex | $3,120.00 |
| INV-1005 | Umbrella Co | $2,015.75 |
| INV-1001 | Northwind Traders | $1,240.00 |
| INV-1002 | Acme Corp | $880.50 |
| INV-1004 | Initech | $540.00 |
| Name | Role | Team | |
|---|---|---|---|
| Ava Reyes | Designer | Product | |
| Liam Chen | Engineer | Platform | |
| Maya Okoro | PM | Growth | |
| Noah Patel | Engineer | Platform | |
| Sofia Lind | Analyst | Data |
| Name | Role | Team |
|---|---|---|
| Ava Reyes | Designer | Product |
| Liam Chen | Engineer | Platform |
| Maya Okoro | PM | Growth |
| Noah Patel | Engineer | Platform |
| Sofia Lind | Analyst | Data |
1–5 of 24
| Invoice | Client | Status | Amount |
|---|---|---|---|
| INV-1001 | Northwind Traders | Paid | $1,240.00 |
| INV-1002 | Acme Corp | Pending | $880.50 |
| INV-1003 | Globex | Paid | $3,120.00 |
| INV-1004 | Initech | Overdue | $540.00 |
| INV-1005 | Umbrella Co | Pending | $2,015.75 |
| Invoice | Client | Status | Amount |
|---|---|---|---|
No records There’s nothing here yet. | |||
More components
- Stat CardOne number that matters, with how it's moving.
- Kpi RowA strip of key numbers across the top of a page.
- TreePick items from a nested list, with whole branches at once.
- GanttA project timeline with dependencies and the critical path.
- ChartHistograms, timelines, radars and more in the house style.
- Activity FeedWho did what, most recent first.
- TimelineEvents down a line, with icons and times.
- Confidence markHow sure something is, shown by shape as well as colour.
- Mini chartsTiny charts that fit inside a table cell or a card.
- Rich textShows saved rich text on a page, without loading the editor.