To access the api see: Grid API.
ClipboardSee Clipboard for more information.
Column Display setColumnsVisibleCopy LinkFunction
Sets the visibility of columns. Key can be the column ID or Column
object.
Function
Returns the display name for a column. Useful if you are doing your own header rendering and want the grid to work out if headerValueGetter
is used, or if you are doing your own column management GUI, to know what to show as the column name.
Function
Returns the column to the right of the provided column, taking into consideration open / closed column groups and visible columns. This is useful if you need to know what column is beside yours e.g. if implementing your own cell navigation.
ColumnApiModule getDisplayedColBeforeCopy LinkFunction
Same as getVisibleColAfter
except gives column to the left.
Function
Same as getAllGridColumns()
, except only returns rendered columns, i.e. columns that are not within the viewport and therefore not rendered, due to column virtualisation, are not displayed.
Function
Returns all columns currently displayed (e.g. are visible and if in a group, the group is showing the columns) for the pinned left, centre and pinned right portions of the grid.
ColumnApiModule getDisplayedCenterColumnsCopy LinkFunction
Same as getAllDisplayedColumns
but just for the center portion of the grid.
Function
Same as getAllDisplayedColumns
but just for the pinned left portion of the grid.
Function
Same as getAllDisplayedColumns
but just for the pinned right portion of the grid.
See Column Groups
getColumnGroupCopy LinkFunction
Returns the column group with the given name.
Column Groups getProvidedColumnGroupCopy LinkFunction
Returns the provided column group with the given name.
setColumnGroupOpenedCopy LinkFunction
Call this if you want to open or close a column group.
getDisplayNameForColumnGroupCopy LinkFunction
Returns the display name for a column group (when grouping columns).
getAllDisplayedColumnGroupsCopy LinkFunction
Returns all 'root' column headers. If you are not grouping columns, these return the columns. If you are grouping, these return the top level groups - you can navigate down through each one to get the other lower level headers and finally the columns at the bottom.
getCenterDisplayedColumnGroupsCopy LinkFunction
Same as getAllDisplayedColumnGroups
but just for the center portion of the grid.
Function
Same as getAllDisplayedColumnGroups
but just for the pinned left portion of the grid.
Function
Same as getAllDisplayedColumnGroups
but just for the pinned right portion of the grid.
See Column Moving
moveColumnsCopy LinkFunction
Moves columns to toIndex
. The columns are first removed, then added at the toIndex
location, thus index locations will change to the right of the column after the removal.
Function
Moves the column at fromIdex
to toIndex
. The column is first removed, then added at the toIndex
location, thus index locations will change to the right of the column after the removal.
See Column Sizing
setColumnWidthsCopy LinkFunction
Sets the column widths of the columns provided. The finished flag gets included in the resulting event and not used internally by the grid. The finished flag is intended for dragging, where a dragging action will produce many columnWidth
events, so the consumer of events knows when it receives the last event in a stream. The finished parameter is optional, and defaults to true
.
Function
Adjusts the size of columns to fit the available horizontal space. Note: it is not recommended to call this method rapidly e.g. in response to window resize events or as the container size is animated. This can cause the scrollbar to flicker. Use column flex for smoother results. If inferring cell data types with custom column types and row data is initially empty or yet to be set, the column sizing will happen asynchronously when row data is added. To always perform this synchronously, set cellDataType = false
on the default column definition.
Function
Auto-sizes columns based on their contents. If inferring cell data types with custom column types and row data is initially empty or yet to be set, the column sizing will happen asynchronously when row data is added. To always perform this synchronously, set cellDataType = false
on the default column definition.
Function
Auto-sizes columns based on their contents. If inferring cell data types with custom column types and row data is initially empty or yet to be set, the column sizing will happen asynchronously when row data is added. To always perform this synchronously, set cellDataType = false
on the default column definition.
Function
Add an event listener for the specified eventType
. Listener will receive the event
as a single parameter. Listeners will be automatically removed when the grid is destroyed.
Function
Remove an event listener.
EventApiModuleFunction
Add an event listener for all event types coming from the grid. Listener will receive eventType
and event
as parameters. Listeners will be automatically removed when the grid is destroyed. If handling multiple event types it is recommended to use event.type
to enable TypeScript to infer the event parameters.
Function
Remove a global event listener.
EventApiModuleFunction
Registers a callback to a virtual row. A virtual row is a row that is visually rendered on the screen (rows that are not visible because of the scroll position are not rendered). Unlike normal events, you do not need to unregister rendered row listeners. When the rendered row is removed from the grid, all associated rendered row listeners will also be removed. listen for this event if your cellRenderer
needs to do cleanup when the row no longer exists.
See Export for more information.
FilteringSee Filtering for more information.
Function
Only supported for Client-Side Row Model. Get the current Quick Filter text from the grid, or undefined
if none is set.
Function
Only supported for Client-Side Row Model. Reset the Quick Filter cache text on every rowNode.
Reset Cache Text QuickFilterModuleFunction
Only supported for Client-Side Row Model. Returns true
if the Quick Filter is set, otherwise false
.
Function
Returns true
if any column filter is set, otherwise false
.
Function
Returns true
if any filter is set. This includes quick filter, column filter, external filter or advanced filter.
Function
Returns the filter component instance for a column. For getting/setting models for individual column filters, use getColumnFilterModel
and setColumnFilterModel
instead of this. key
can be a column ID or a Column
object.
Function
Returns the filter handler instance for a column. Used when enableFilterHandlers = true
, or when using a grid-provided filter. If using a SimpleColumnFilter
, this will be an object containing the provided doesFilterPass
callback. key
can be a column ID or a Column
object.
Function
Gets the current state of all the column filters. Used for saving filter state.
Get / Set All Filter Models TextFilterModule+5 Available in any of TextFilterModule NumberFilterModule DateFilterModule SetFilterModule MultiFilterModule CustomFilterModuleFunction
Sets the state of all the column filters. Provide it with what you get from getFilterModel()
to restore filter state. If inferring cell data types, and row data is initially empty or yet to be set, the filter model will be applied asynchronously after row data is added. To always perform this synchronously, set cellDataType = false
on the default column definition, or provide cell data types for every column.
Function
Gets the current filter model for the specified column. Will return null
if no active filter. useUnapplied
: If enableFilterHandlers = true
and value is true
, will return the unapplied filter model.
Function
Sets the filter model for the specified column. Setting a model
of null
will reset the filter (make inactive). Must wait on the response before calling api.onFilterChanged()
.
FilterChangedEventSourceType
Informs the grid that a filter has changed. This is typically called after a filter change through one of the filter APIs. source
: The source of the filter change event. If not specified defaults to 'api'
.
Function
Destroys a filter. Useful to force a particular filter to be created from scratch again.
TextFilterModule+5 Available in any of TextFilterModule NumberFilterModule DateFilterModule SetFilterModule MultiFilterModule CustomFilterModuleFunction
Perform the provided filter action for the column specified, or all columns. Requires enableFilterHandlers = true
.
Function
Get the state of the Advanced Filter. Used for saving Advanced Filter state
Advanced Filter AdvancedFilterModuleFunction
Set the state of the Advanced Filter. Used for restoring Advanced Filter state
Advanced Filter AdvancedFilterModuleFunction
Open the Advanced Filter Builder dialog (if enabled).
Advanced Filter AdvancedFilterModuleFunction
Closes the Advanced Filter Builder dialog (if enabled). Un-applied changes are discarded.
Advanced Filter AdvancedFilterModule FindSee Find for more information.
Function
Go to the next match.
Find FindModuleFunction
Go to the previous match.
Find FindModuleFunction
Get the total number of matches.
Find FindModuleFunction
Go to the provided match (first match is 1
). By default, if the provided match is already active, this will do nothing. If force
is set to true
, this will instead reset the active match to that provided (e.g. scroll the grid).
Function
Clear the active match.
Find FindModuleFunction
Get the active match, or undefined
if no active match.
Function
Get the number of matches within the provided cell.
Using Find with Cell Components FindModuleFunction
Get the parts of a cell value, including matches and active match. Used for custom cell components.
Using Find with Cell Components FindModuleFunction
This will re-run the search with the current value. This is normally done automatically. This should only be called in situations where data is mutated outside of the grid, and api.refreshCells()
or api.redrawRows()
are being used (api.findRefresh()
should be called after these).
Function
Returns the grid option value for a provided key.
GridOptionsFunction
Updates a single gridOption to the new value provided. (Cannot be used on Initial
properties.) If updating multiple options, it is recommended to instead use api.updateGridOptions()
which batches update logic.
Function
Updates the provided subset of gridOptions with the provided values. (Cannot be used on Initial
properties.)
See Grid State for more information.
Function
Get the current state of the grid. Can be used in conjunction with the initialState
grid option or api.setState()
to save and restore grid state.
Function
Set the current state of the grid. Can be used in conjunction with api.getState()
or onStateUpdated
to save and restore grid state. This method should only be used to restore state; it should not be called on every state update (the grid does not support being used as a controlled component). propertiesToIgnore
: If supplied, the existing state of the provided properties will be maintained.
See Keyboard Navigation for more information.
Function
Returns the focused cell (or the last focused cell if the grid lost focus).
Function
Sets the focus to the specified cell. rowPinned
can be either 'top', 'bottom' or null (for not pinned).
Function
Clears the focused cell.
Function
Navigates the grid focus to the next cell, as if tabbing.
Custom NavigationFunction
Navigates the grid focus to the previous cell, as if shift-tabbing.
Custom NavigationFunction
Sets the focus to the specified header. If floatingFilter
is true, the Column's floatingFilter element will be focused.
Function
Gets the cell value for the given column and rowNode
(row). Will return the cell value or the formatted value depending on the value of params.useFormatter
.
Function
Expire the value cache.
Value Cache ValueCacheModuleFunction
Will destroy the grid and release resources. If you are using a framework you do not need to call this, as the grid links in with the framework lifecycle. However if you are using Web Components or native JavaScript, you do need to call this, to avoid a memory leak in your application.
Function
Returns true
if the grid has been destroyed.
Function
Sets an ARIA property in the grid panel (element with
role="grid"
), and removes an ARIA property when the value is null.
Example:
api.setGridAriaProperty('label', 'my grid')
will set
aria-label="my grid"
.
api.setGridAriaProperty('label', null)
will remove the
aria-label
attribute from the grid element.
ARIA Attributes RenderApiModuleFunction
Returns the gridId
for the current grid as specified via the gridOptions property gridId
or the auto assigned grid id if none was provided.
Function
Check if a Module is registered with the current grid instance via its equivalent string name.
Function
Returns true
when there are no more animation frames left to process.
See Overlays for more information.
Function
Show the no-rows overlay. If suppressNoRowsOverlay
is set, or if loading
is true, this will not do anything.
Function
Hide the no-rows overlay if it is showing.
See Row Pagination for more information.
Function
Returns
true
when the last page is known; this will always be the case if you are using the Client-Side Row Model for pagination. Returns
false
when the last page is not known; this only happens when using
Infinite Row Model.
PaginationModuleFunction
Returns how many rows are being shown per page.
PaginationModuleFunction
Returns the 0-based index of the page which is showing.
PaginationModuleFunction
Returns the total number of pages.
PaginationModuleFunction
Returns the total number of pageable rows, as impacted by gridOptions.paginateChildRows: true
. It is recommended to instead use gridApi.getDisplayedRowCount()
if not using pagination, or if gridOption.paginateChildRows=true
.
Function
Goes to the specified page. If the page requested doesn't exist, it will go to the last page.
PaginationModuleFunction
Navigates to the next page.
PaginationModuleFunction
Navigates to the previous page.
PaginationModuleFunction
Navigates to the first page.
PaginationModuleFunction
Navigates to the last page.
PaginationModule RenderingFunction
Retrieve rendered nodes. Due to virtualisation this will contain only the current visible rows and those in the buffer.
RowApiModuleFunction
Returns the list of active cell renderer instances.
Cell Renderer Instances RenderApiModuleFunction
Gets the sizes that various UI elements will be rendered at with the current theme. If you override the row or header height using gridOptions
, the override value you provided will be returned.
Function
Tells the grid a row height has changed. To be used after calling rowNode.setRowHeight(newHeight)
.
See Row Grouping or Tree Data for more information
expandAllCopy LinkFunction
Expand all groups.
Function
Collapse all groups.
setRowNodeExpandedCopy LinkFunction
Expand or collapse a specific row node, optionally expanding/collapsing all of its parent nodes. By default rows are expanded asynchronously for best performance. Set forceSync: true
if you need to interact with the expanded row immediately after this function.
Function
Informs the grid that row group expanded state has changed and it needs to rerender the group nodes. Typically called after updating the row node expanded state explicitly, i.e rowNode.expanded = false
, across multiple groups and you want to update the grid view in a single rerender instead of on every group change.
Function
Returns the row node with the given ID. The row node ID is the one you provide from the callback getRowId(params)
, otherwise the ID is a number (cast as string) auto-generated by the grid when the row data is set.
Function
Iterates through each node (row) in the grid and calls the callback for each node. This works similar to the forEach
method on a JavaScript array. This is called for every node, ignoring any filtering or sorting applied within the grid. It is not called on any pinned row nodes. If using the Infinite Row Model, then this gets called for each page loaded in the page cache.
Function
Similar to forEachNode
, except skips any filtered out data.
Function
Similar to forEachNodeAfterFilter
, except the callbacks are called in the order the rows are displayed in the grid.
Function
Similar to forEachNode
, except lists all the leaf nodes. This effectively goes through all the data that you provided to the grid before the grid performed any grouping. If using tree data, goes through all the nodes for the data you provided, including nodes that have children, but excluding groups the grid created where gaps were missing in the hierarchy.
See Pivot for more information
Function
Returns whether pivot mode is currently active.
PivotModule getPivotColumnsCopy LinkFunction
Get the columns which the grid is pivoting on.
PivotModule setPivotColumnsCopy LinkFunction
Set the columns for the grid to pivot on.
PivotModule addPivotColumnsCopy LinkFunction
Add columns for the grid to pivot on.
PivotModule removePivotColumnsCopy LinkFunction
Stops the grid from pivoting on the provided columns.
PivotModule getPivotResultColumnCopy LinkFunction
Returns the pivot result column for the given pivotKeys
and valueColId
.
Function
Set explicit pivot column definitions yourself. Used for advanced use cases only.
PivotModule getPivotResultColumnsCopy LinkFunction
Returns the grid's pivot result columns.
PivotModuleSee Infinite Row Model for more information.
Function
Marks all the currently loaded blocks in the cache for reload. If you have 10 blocks in the cache, all 10 will be marked for reload. The old data will continue to be displayed until the new data is loaded.
InfiniteRowModelModuleFunction
Purges the cache. The grid is then told to refresh. Only the blocks required to display the current data on screen are fetched (typically no more than 2). The grid will display nothing while the new blocks are loaded. Use this to immediately remove the old data from the user.
InfiniteRowModelModuleFunction
Returns false
if grid allows for scrolling past the last row to load more rows, thus providing infinite scroll.
Function
Sets the rowCount
and maxRowFound
properties. The second parameter, maxRowFound
, is optional and if left out, only rowCount
is set. Set rowCount
to adjust the height of the vertical scroll. Set maxRowFound
to enable / disable searching for more rows. Use this method if you add or remove rows into the dataset and need to reset the number of rows or instruct the grid that the entire row count is no longer known.
Function
Returns an object representing the state of the cache. This is useful for debugging and understanding how the cache is working.
InfiniteRowModelModule+1 Available in any of InfiniteRowModelModule ServerSideRowModelApiModule RowModel: Server-SideSee Server-Side Row Model for more information.
Function
Sets the rowCount
and maxRowFound
properties. The second parameter, maxRowFound
, is optional and if left out, only rowCount
is set. Set rowCount
to adjust the height of the vertical scroll. Set maxRowFound
to enable / disable searching for more rows. Use this method if you add or remove rows into the dataset and need to reset the number of rows or instruct the grid that the entire row count is no longer known.
Function
Refresh a server-side store level. If you pass no parameters, then the top level store is refreshed. To refresh a child level, pass in the string of keys to get to the desired level. Once the store refresh is complete, the storeRefreshed event is fired.
Purging Groups ServerSideRowModelApiModuleFunction
Returns info on all server side group levels.
ServerSideRowModelApiModuleFunction
Gets all failed server side loads to retry.
Retry Loads ServerSideRowModelApiModuleFunction
Apply transactions to the server side row model.
Transactions ServerSideRowModelApiModuleFunction
Batch apply transactions to the server side row model.
Transactions ServerSideRowModelApiModuleFunction
Applies row data to a server side store. New rows will overwrite rows at the same index in the same way as if provided by a datasource success callback.
Providing Additional Data ServerSideRowModelApiModuleFunction
Returns an object containing rules matching the selected rows in the SSRM. If rowSelection.groupSelects
is 'self'
the returned object will be flat, and will conform to IServerSideSelectionState
. If rowSelection.groupSelects
is 'descendants'
or 'filteredDescendants'
the returned object will be hierarchical, and will conform to IServerSideGroupSelectionState
.
Function
Set the rules matching the selected rows in the SSRM. If rowSelection.groupSelects
is 'self'
the param will be flat, and should conform to IServerSideSelectionState
. If rowSelection.groupSelects
is 'descendants'
or 'filteredDescendants'
the param will be hierarchical, and should conform to IServerSideGroupSelectionState
.
Function
Returns an object representing the state of the cache. This is useful for debugging and understanding how the cache is working.
Cache Block State InfiniteRowModelModule+1 Available in any of InfiniteRowModelModule ServerSideRowModelApiModuleFunction
Returns false
if grid allows for scrolling past the last row to load more rows, thus providing infinite scroll.
Function
Vertically scrolls the grid until the provided row index is inside the visible viewport. If a position is provided, the grid will attempt to scroll until the row is at the given position within the viewport. This will have no effect before the firstDataRendered event has fired.
firstDataRendered event ScrollApiModuleFunction
Vertically scrolls the grid until the provided row (or a row matching the provided comparator) is inside the visible viewport. If a position is provided, the grid will attempt to scroll until the row is at the given position within the viewport. This will have no effect before the firstDataRendered event has fired.
firstDataRendered event ScrollApiModule ensureColumnVisibleCopy LinkFunction
Ensures the column is visible by scrolling the table if needed. This will have no effect before the firstDataRendered event has fired. key
: - The column to ensure visibleposition
: - Where the column will be positioned. Defaults to auto
Function
Returns an object with two properties:
left
: The left pixel position of the current scroll in the gridright
: The right pixel position of the current scroll in the gridFunction
Returns an object with two properties:
top
: The top pixel position of the current scroll in the gridbottom
: The bottom pixel position of the current scroll in the gridFunction
Select all rows. By default this ignores filtering, expansion and pagination settings. Pass the appropriate select all mode as an argument in order to select only rows that satisfy the filter, or those rows on the current page. mode
: SelectAll mode to use. See SelectAllMode
source
: Source property that will appear in the selectionChanged
event, defaults to 'apiSelectAll'
Function
Clear all row selections. By default this ignores filtering, expansion and pagination settings. Pass the appropriate select all mode as an argument in order to select only rows that satisfy the filter, or those rows on the current page. mode
: SelectAll mode to use. See SelectAllMode
source
: Source property that will appear in the selectionChanged
event, defaults to 'apiSelectAll'
Function
Returns an unsorted list of selected nodes. Getting the underlying node (rather than the data) is useful when working with tree / aggregated data, as the node can be traversed.
RowSelectionModuleFunction
Returns an unsorted list of selected rows (i.e. row data that you provided).
RowSelectionModuleFunction
Set all of the provided nodes selection state to the provided value.
RowSelectionModuleFunction
Returns a list of all selected nodes at 'best cost', a feature to be used with groups / trees. If a group has all its children selected, then the group appears in the result, but not the children. Designed for use with 'children'
as the group selection type, where groups don't actually appear in the selection normally.
Function
Returns the list of selected cell ranges. The start is the first cell the user clicked on and the end is the cell where the user stopped dragging. Do not assume that the start cell's index is numerically before the end cell, as the user could have dragged up.
getCellRanges CellSelectionModuleFunction
Adds the provided cell range to the selected ranges. This keeps any previous ranges. If you wish to only have the new range selected, then call clearCellSelection()
first.
Function
Clears the selected cell ranges.
clearCellSelection CellSelectionModule SortingSee Row Sorting for more information.
Gets the grid to act as if the sort was changed. Useful if you update some values and want to get the grid to reorder them according to the new values.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4