@serenity-is/corelib / GridSelectAllButtonHelper / define
Function: define()
define(
getGrid,getId,getSelected,setSelected,text?,onClick?):ToolButton
Defined in: src/ui/helpers/gridselectallbuttonhelper.tsx:38
Defines a select-all toolbar button that selects or deselects all items.
Parameters
getGrid
() => IDataGrid
A function that returns the data grid.
getId
(p1) => any
A function that returns the id of an item.
getSelected
(p1) => boolean
A function that returns whether an item is selected.
setSelected
(p1, p2) => void
A function that sets the selected state of an item.
text?
string
Optional button title text. Defaults to the "Select All" text.
onClick?
() => void
Optional callback invoked after the selection is updated.
Returns
The toolbar button definition.