SelectionSettings

Configures selection behavior in the Data Grid component. Defines settings for enabling selection, specifying selection mode, and controlling selection type. Manages how to interact with row selection in the grid.

Props

The following table outlines the props for the SelectionSettings:

NameTypeDefaultDescription
autoSelectMode
AutoSelectMode.Default

Controls the header checkbox click behavior for remote data sources. Defines how the header checkbox behaves when selecting data in the grid, either across all data or only the currently loaded data. Options:

  • Default: Header checkbox toggles between checked and unchecked (two‑state). In this mode, all data in the grid is selected or deselected. This is the default mode.
  • Intermediate: Header checkbox cycles through checked, unchecked, and intermediate (tri‑state). In this mode, selection applies only to currently loaded or visited pages. Full grid selection becomes available only after all pages have been loaded.
cellSelectionType
'Flow'

Specifies the cell selection type for range selection behavior. Only applies when type is 'Cell'. Determines how cells are selected when creating rectangular ranges. Options:

  • Flow - Selects all cells between start/end including all rows (Excel-like).
  • Box - Selects only cells within column range boundaries.
  • BoxWithBorder - Box mode with visible selection border.
checkboxOnly
boolean
false

When checkboxOnly is set to true, row selection is possible only through the checkbox. Clicking other row or cell elements does not trigger selection.

enableToggle
boolean
false

Specifies whether row selection can be toggled. When set to true, clicking a selected row will deselect it, and clicking a deselected row will reselect it. When set to false, the selection state remains fixed once applied and cannot be toggled.

enabled
boolean
true

Determines whether row selection is enabled in the grid by default. When set to false, all selection functionality is disabled. This property directly affects the grid’s interactivity for row-based operations.

mode
string | SelectionMode
'Single' | SelectionMode.Single

Specifies the selection mode for the grid, controlling how many rows can be selected. Supports Single for selecting one row at a time or Multiple for selecting multiple rows using CTRL or SHIFT keys.

persistSelection
boolean
false

Specifies whether row selection is persisted across grid operations such as sorting, filtering, searching, paging, or refreshing. Selection persistence requires a primary key, so define at least one unique value column with the isPrimaryKey property in the column definition. When the checkbox selection feature is enabled, selection persistence is automatically set to true. Set enablePersistence to false to disable selection persistence.

type
string | SelectionType
'Row' | SelectionType.Row

Defines the type of selection target in the grid. Determines whether selection applies to rows or cells. Options:

  • Row - Only row selection is enabled (default, backward compatible).
  • Cell - Only cell selection is enabled (individual cells can be selected).