Component packs › Tabula › Sort Table
Sort any column and every row slides to its new place on a spring, in a wave from the top, while the header arrow turns.
Sort Table is a sortable table from Tabula, a component pack with 8 components: Data table components where rows move to their new places. Price: $2 for the whole pack.
Built with: travelling rows, aria-sort, announced order.
Code: React and Next.js (TypeScript), Vue 3, plain HTML/CSS/JS, Tailwind CSS v4 and Motion (motion.dev). No npm packages needed. Keyboard accessible, with a reduced-motion version, in dark and light.
| Prop | Type | Default | Description |
|---|---|---|---|
rows | TabulaRow[] | ||
onSort | (key: string, dir: 'ascending' | 'descending') => void | ||
theme | 'dark' | 'light' | ||
autoplay | boolean | Showcase mode: sorts by different columns until touched. |
sort(key: keyof TabulaRow, dir?: 'ascending' | 'descending'): voiddestroy(): voidimport SortTable from './SortTable';
<SortTable />The Vue, HTML, Next.js, Tailwind and Motion versions take the same options.
Good for: Data tables.