# ColumnSnapshot (@salmonui/data-grid/engine)

> The ColumnSnapshot interface of @salmonui/data-grid/engine.

Canonical: https://salmonui.dev/docs/reference/data-grid/engine/ColumnSnapshot

```ts
import type { ColumnSnapshot } from '@salmonui/data-grid/engine';
```

Entry index: https://salmonui.dev/docs/reference/data-grid/engine (Markdown with every symbol of the entry: https://salmonui.dev/docs/reference/data-grid/engine.md).

## Reference

Kind: interface

```ts
interface ColumnSnapshot<Row> {
    readonly tree: readonly CompiledColumn<Row>[];
    readonly leaves: readonly CompiledColumn<Row>[];
    readonly zones: ReadonlyMap<ColumnId, 'left' | 'center' | 'right'>;
    readonly visible: readonly CompiledColumn<Row>[];
    readonly left: readonly CompiledColumn<Row>[];
    readonly center: readonly CompiledColumn<Row>[];
    readonly right: readonly CompiledColumn<Row>[];
    readonly fixed: readonly CompiledColumn<Row>[];
    readonly byId: ReadonlyMap<ColumnId, CompiledColumn<Row>>;
    readonly headerRowCount: number;
}
```

Members (10):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `tree` | `readonly tree: readonly CompiledColumn<Row>[];` |  | Every node of the header tree, depth-first, groups before their children. |
| `leaves` | `readonly leaves: readonly CompiledColumn<Row>[];` |  | Leaf (data) columns in definition order, including hidden ones (identity is stable across reorder). |
| `zones` | `readonly zones: ReadonlyMap<ColumnId, 'left' \| 'center' \| 'right'>;` |  | Runtime freeze zone of every visible leaf (definition `pinned`, runtime pin/unpin, and `frozenColumns` counts). |
| `visible` | `readonly visible: readonly CompiledColumn<Row>[];` |  | Visible leaves in runtime order: left zone, center, right zone. |
| `left` | `readonly left: readonly CompiledColumn<Row>[];` |  |  |
| `center` | `readonly center: readonly CompiledColumn<Row>[];` |  |  |
| `right` | `readonly right: readonly CompiledColumn<Row>[];` |  |  |
| `fixed` | `readonly fixed: readonly CompiledColumn<Row>[];` |  | Center leaves in the fixed zone (`pinned: 'center'`), in runtime order: a subset of `center`, so `visible` order, keyboard order and `aria-colindex` stay the visual order. Empty (a shared frozen array) when no column is fixed. |
| `byId` | `readonly byId: ReadonlyMap<ColumnId, CompiledColumn<Row>>;` |  |  |
| `headerRowCount` | `readonly headerRowCount: number;` |  | Number of header rows (tree depth). |
