Tree table
A table with expandable nested rows.
| Name | Type |
|---|---|
| src | folder |
| app.ts | file |
| main.ts | file |
| package.json | file |
Copy as markdown tree
Set [copyable]="true" for a button that copies the hierarchy as an ASCII tree (├── / └──), ready to paste into a README.
| Name | Type |
|---|---|
| src | folder |
| app.ts | file |
| main.ts | file |
| package.json | file |
API reference
Inputs
| Prop | Type | Default | Description |
|---|---|---|---|
columns | readonly TreeTableColumn[] | [] | Column definitions in display order. |
rows | readonly TreeTableRow[] | [] | Top-level rows, each able to nest children via `children`. |
toggleLabel | string | — | Accessible label for the expand/collapse toggle button. |
copyable | boolean | false | Show a button that copies the full hierarchy as a markdown ASCII tree. |
copyLabel | string | — | Label override for the copy button (idle state). |
copiedLabel | string | — | Label override for the copy button after copying. |
Types
TreeTableColumn
| Field | Type | Description |
|---|---|---|
key | string | Row data key whose value fills this column's cells. |
label | string | Column header text. |
align? | "center" | "left" | "right" | Horizontal text alignment for the column's cells. |
TreeTableRow
| Field | Type | Description |
|---|---|---|
children? | TreeTableRow[] | Nested child rows shown when this row is expanded. |
expanded? | false | true | Whether the row starts expanded. |
Every ng-blatui component also accepts a class input to merge extra Tailwind classes onto the host.