Skip to content

Filters

Data Grid reuses Niko Table filters. There is no separate grid/filters layer.

The Data Grid does not ship its own grid/filters/ directory. Sort, filter, and faceted UIs come from Niko Table and stay correct because focus/edits are id-addressed (not display index).

  1. Build columns and toolbar filters as you would for any Niko Table.
  2. Pass grid.rows into DataTableRoot as data.
  3. Wrap the table in <DataGrid>: keyboard nav and selection read display order after filter/sort.
  4. Cell editors keep using { rowId, columnId }, so filtered-out rows retain state.
<DataTableRoot data={grid.rows} columns={columns} getRowId={(r) => r.id}>
<DataTableToolbarSection>
<DataTableSearchFilter />
<DataTableFacetedFilter columnId="status" title="Status" />
</DataTableToolbarSection>
<DataGrid grid={grid}>
<DataTable>…</DataTable>
</DataGrid>
</DataTableRoot>
Topic Link
Filter primitives (Table*) Filters overview
Context-aware filter UIs Components overview
Faceted example Faceted Filter Table
Advanced filter example Advanced Table
Full grid demo with filters Introduction