Table
Terminal-style table, alternating rows and compact mode.
Table
Design lines
| Name | Role | Status |
|---|---|---|
| Alice Chen | Developer | Active |
| Bob Martinez | Designer | Active |
| Charlie Kim | DevOps | Away |
| Diana Ross | QA Lead | Active |
| Eve Wilson | PM | Active |
| Frank Lee | Tech Lead | Away |
vue
1<Tabs defaultValue="tuix">2 <TabsList>3 <Tab value="tuix">TUIX</Tab>45 <Tab value="rubik">Rubik</Tab>6 </TabsList>78 <TabPanel value="tuix">9 <Table10 :columns="[11 { key: 'name', label: 'Name' },12 { key: 'role', label: 'Role' },13 { key: 'status', label: 'Status' },14 ]"15 :rows="[16 { name: 'Alice Chen', role: 'Developer', status: 'Active' },17 { name: 'Bob Martinez', role: 'Designer', status: 'Active' },18 { name: 'Charlie Kim', role: 'DevOps', status: 'Away' },19 { name: 'Diana Ross', role: 'QA Lead', status: 'Active' },20 { name: 'Eve Wilson', role: 'PM', status: 'Active' },21 { name: 'Frank Lee', role: 'Tech Lead', status: 'Away' },22 ]"23 color="primary"24 striped25 compact26 design="tuix"27 />28 </TabPanel>2930 <TabPanel value="rubik">31 <Table32 :columns="[33 { key: 'name', label: 'Name' },34 { key: 'role', label: 'Role' },35 { key: 'status', label: 'Status' },36 ]"37 :rows="[38 { name: 'Alice Chen', role: 'Developer', status: 'Active' },39 { name: 'Bob Martinez', role: 'Designer', status: 'Active' },40 { name: 'Charlie Kim', role: 'DevOps', status: 'Away' },41 { name: 'Diana Ross', role: 'QA Lead', status: 'Active' },42 { name: 'Eve Wilson', role: 'PM', status: 'Active' },43 { name: 'Frank Lee', role: 'Tech Lead', status: 'Away' },44 ]"45 color="primary"46 striped47 compact48 design="rubik"49 />50 </TabPanel>51</Tabs>Demo
Basic (default)
Tabla simple sin props adicionales.
| Name | Role |
|---|---|
| Alice | Developer |
| Bob | Designer |
vue
1<Table2 :columns="[3 { key: 'name', label: 'Name' },4 { key: 'role', label: 'Role' },5 ]"6 :rows="[7 { name: 'Alice', role: 'Developer' },8 { name: 'Bob', role: 'Designer' },9 ]"10/>Striped rows (striped)
Mejora la legibilidad en tablas con muchas filas.
| # | Task | Owner |
|---|---|---|
| 1 | Design system | Alice |
| 2 | API integration | Bob |
| 3 | E2E tests | Charlie |
| 4 | Documentation | Diana |
| 5 | Deploy to prod | Eve |
| # | Task | Owner |
|---|---|---|
| 1 | Design system | Alice |
| 2 | API integration | Bob |
| 3 | E2E tests | Charlie |
| 4 | Documentation | Diana |
| 5 | Deploy to prod | Eve |
vue
1<Table2 :columns="[{ key: 'n', label: '#' }, { key: 'task', label: 'Task' }, { key: 'owner', label: 'Owner' }]"3 :rows="[4 { n: '1', task: 'Design system', owner: 'Alice' },5 { n: '2', task: 'API integration', owner: 'Bob' },6 { n: '3', task: 'E2E tests', owner: 'Charlie' },7 { n: '4', task: 'Documentation', owner: 'Diana' },8 { n: '5', task: 'Deploy to prod', owner: 'Eve' },9 ]"10 striped11/>Compact (compact)
Reduce el padding para vistas densas.
| Name | Role | Team |
|---|---|---|
| Alice Chen | Senior Dev | Frontend |
| Bob Martinez | Designer | Design |
| Charlie Kim | DevOps | Platform |
| Diana Ross | QA Lead | Quality |
| Eve Wilson | PM | Product |
| Frank Lee | Tech Lead | Backend |
| Name | Role | Team |
|---|---|---|
| Alice Chen | Senior Dev | Frontend |
| Bob Martinez | Designer | Design |
| Charlie Kim | DevOps | Platform |
| Diana Ross | QA Lead | Quality |
| Eve Wilson | PM | Product |
| Frank Lee | Tech Lead | Backend |
vue
1<Table2 :columns="[{ key: 'name', label: 'Name' }, { key: 'role', label: 'Role' }, { key: 'team', label: 'Team' }]"3 :rows="[4 { name: 'Alice Chen', role: 'Senior Dev', team: 'Frontend' },5 { name: 'Bob Martinez', role: 'Designer', team: 'Design' },6 { name: 'Charlie Kim', role: 'DevOps', team: 'Platform' },7 { name: 'Diana Ross', role: 'QA Lead', team: 'Quality' },8 { name: 'Eve Wilson', role: 'PM', team: 'Product' },9 { name: 'Frank Lee', role: 'Tech Lead', team: 'Backend' },10 ]"11 compact12/>Numbered index (indexed)
Añade columna # / 01 al inicio.
| # | Name | Role |
|---|---|---|
| 01 | Alice Chen | Developer |
| 02 | Bob Martinez | Designer |
| 03 | Charlie Kim | DevOps |
vue
1<Table2 :columns="[{ key: 'name', label: 'Name' }, { key: 'role', label: 'Role' }]"3 :rows="[4 { name: 'Alice Chen', role: 'Developer' },5 { name: 'Bob Martinez', role: 'Designer' },6 { name: 'Charlie Kim', role: 'DevOps' },7 ]"8 indexed9/>Header color (color)
Color de acento de la cabecera.
| Name | Role |
|---|---|
| Alice Chen | Developer |
| Bob Martinez | Designer |
| Name | Role |
|---|---|
| Alice Chen | Developer |
| Bob Martinez | Designer |
| Name | Role |
|---|---|
| Alice Chen | Developer |
| Bob Martinez | Designer |
vue
1<Table :columns="..." :rows="..." color="success" />2<Table :columns="..." :rows="..." color="danger" />3<Table :columns="..." :rows="..." color="warning" />Combined (all props)
Todos los props juntos en una tabla densa.
| # | ID | Service | Status | Region |
|---|---|---|---|---|
| 01 | 1 | api-gateway | Running | us-east-1 |
| 02 | 2 | auth-service | Running | us-east-1 |
| 03 | 3 | user-service | Running | eu-west-1 |
| 04 | 4 | notification | Pending | ap-southeast-1 |
| 05 | 5 | analytics | Stopped | us-west-2 |
| 06 | 6 | billing | Running | eu-central-1 |
vue
1<Table2 :columns="[...]"3 :rows="[...]"4 striped5 compact6 indexed7 color="primary"8/>API
| Prop | Type | Default | Description |
|---|---|---|---|
columns | Array<{key: string, label: string}> | [] | Column definitions with key and label |
rows | Record<string, string>[] | [] | Row data keyed by column keys |
color | 'primary' | 'secondary' | 'tertiary' | 'success' | 'warning' | 'danger' | 'light' | 'medium' | 'dark' | 'primary' | Header border color |
striped | boolean | false | Alternating row background |
compact | boolean | false | Reduced cell padding |
indexed | boolean | false | Numbered index column in both lines |
design | 'tuix' | 'rubik' | — (inherits from data-design) | Design line (or inherit from data-design). |
columns — each column has this shape:
| Field | Type | Required | Description |
|---|---|---|---|
key | string | ✅ | Column identifier |
label | string | ✅ | Visible header |
CSS Custom Properties
| Token | Default | Description |
|---|---|---|
--font-mono | "JetBrains Mono", ui-monospace, monospace | Monospace font stack for code-like content (key labels, log lines, chips). |
--accent | from theme (--ctp-latte-mauve / --ctp-mocha-mauve) | Accent color, mapped from the active semantic color. |
--bg | from theme (--ctp-latte-base / --ctp-mocha-base) | Base background of the surface. |
--bg-alt | from theme (--ctp-latte-mantle / --ctp-mocha-mantle) | Alternate background (the next layer down from the base). |
--bg-elevated | from theme (--ctp-latte-surface0 / --ctp-mocha-surface0) | Background of floating surfaces (modals, dropdowns, popovers). |
--bg-panel | from theme (--ctp-latte-surface1 / --ctp-mocha-surface1) | Background of panel-like raised surfaces (cards, accordions). |
--border | from theme (--ctp-latte-surface0 / --ctp-mocha-surface0) | Outline and divider color for surfaces. |
--text | from theme (--ctp-latte-text / --ctp-mocha-text) | Primary text color used inside the component. |
--text-muted | from theme (--ctp-latte-subtext1 / --ctp-mocha-subtext1) | Secondary text for hints, annotations and disabled state. |
--color-primary | from theme (--ctp-latte-mauve / --ctp-mocha-mauve) | Primary semantic color (mauve in Catppuccin). |
--color-secondary | from theme (--ctp-latte-lavender / --ctp-mocha-lavender) | Secondary semantic color (lavender in Catppuccin). |
--color-tertiary | from theme (--ctp-latte-blue / --ctp-mocha-blue) | Tertiary semantic color (blue in Catppuccin). |
--color-success | from theme (--ctp-latte-green / --ctp-mocha-green) | Success semantic color (green in Catppuccin). |
--color-warning | from theme (--ctp-latte-yellow / --ctp-mocha-yellow) | Warning semantic color (yellow in Catppuccin). |
--color-danger | from theme (--ctp-latte-red / --ctp-mocha-red) | Danger semantic color (red in Catppuccin). |
--color-light | from theme (--ctp-latte-surface1 / --ctp-mocha-rosewater) | Light semantic color (lighter contrast tone). |
--color-medium | from theme (--ctp-latte-overlay0 / --ctp-mocha-overlay2) | Medium semantic color (mid-tone). |
--color-dark | from theme (--ctp-latte-text / --ctp-mocha-subtext1) | Dark semantic color (high contrast text). |
--cp-ease | cubic-bezier(.4, 0, .2, 1) | Default easing curve for transitions. |
Ver Theming para la convención completa.