ag-grid-vue3
Version:
AG Grid Vue 3 Component
900 lines • 97 kB
TypeScript
import type { AlignedGrid, CellPosition, CellSelectionOptions, ChartRefParams, ChartToolPanelsDef, ColDef, ColGroupDef, ColTypeDef, Column, CsvExportParams, DataTypeDefinition, DefaultChartMenuItem, DomLayoutType, ExcelExportParams, ExcelStyle, FillOperationParams, FindOptions, FocusGridInnerElementParams, GetChartMenuItems, GetChartToolbarItems, GetContextMenuItems, GetDataPath, GetGroupRowAggParams, GetLocaleTextParams, GetMainMenuItems, GetRowIdFunc, GetServerSideGroupKey, GetServerSideGroupLevelParamsParams, GridState, HeaderPosition, IAdvancedFilterBuilderParams, IAggFunc, IDatasource, IRowDragItem, IRowNode, IServerSideDatasource, IViewportDatasource, InitialGroupOrderComparatorParams, IsApplyServerSideTransaction, IsExternalFilterPresentParams, IsFullWidthRowParams, IsGroupOpenByDefaultParams, IsRowFilterable, IsRowMaster, IsRowSelectable, IsServerSideGroup, IsServerSideGroupOpenByDefaultParams, LoadingCellRendererSelectorFunc, MenuItemDef, NavigateToNextCellParams, NavigateToNextHeaderParams, PaginationNumberFormatterParams, PostProcessPopupParams, PostSortRowsParams, ProcessCellForExportParams, ProcessDataFromClipboardParams, ProcessGroupHeaderForExportParams, ProcessHeaderForExportParams, ProcessRowParams, ProcessUnpinnedColumnsParams, RowClassParams, RowClassRules, RowGroupingDisplayType, RowHeightParams, RowModelType, RowNumbersOptions, RowSelectionOptions, RowStyle, SelectionColumnDef, SendToClipboardParams, ServerSideGroupLevelParams, SideBarDef, SizeColumnsToContentStrategy, SizeColumnsToFitGridStrategy, SizeColumnsToFitProvidedWidthStrategy, SortDirection, StatusPanelDef, TabToNextCellParams, TabToNextHeaderParams, Theme, TreeDataDisplayType, UseGroupTotalRow } from 'ag-grid-community';
import type { AdvancedFilterBuilderVisibleChangedEvent, AsyncTransactionsFlushedEvent, BodyScrollEndEvent, BodyScrollEvent, CellClickedEvent, CellContextMenuEvent, CellDoubleClickedEvent, CellEditRequestEvent, CellEditingStartedEvent, CellEditingStoppedEvent, CellFocusedEvent, CellKeyDownEvent, CellMouseDownEvent, CellMouseOutEvent, CellMouseOverEvent, CellSelectionChangedEvent, CellSelectionDeleteEndEvent, CellSelectionDeleteStartEvent, CellValueChangedEvent, ChartCreatedEvent, ChartDestroyedEvent, ChartOptionsChangedEvent, ChartRangeSelectionChangedEvent, ColumnEverythingChangedEvent, ColumnGroupOpenedEvent, ColumnHeaderClickedEvent, ColumnHeaderContextMenuEvent, ColumnHeaderMouseLeaveEvent, ColumnHeaderMouseOverEvent, ColumnMenuVisibleChangedEvent, ColumnMovedEvent, ColumnPinnedEvent, ColumnPivotChangedEvent, ColumnPivotModeChangedEvent, ColumnResizedEvent, ColumnRowGroupChangedEvent, ColumnValueChangedEvent, ColumnVisibleEvent, ComponentStateChangedEvent, ContextMenuVisibleChangedEvent, CutEndEvent, CutStartEvent, DisplayedColumnsChangedEvent, DragCancelledEvent, DragStartedEvent, DragStoppedEvent, ExpandOrCollapseAllEvent, FillEndEvent, FillStartEvent, FilterChangedEvent, FilterModifiedEvent, FilterOpenedEvent, FindChangedEvent, FirstDataRenderedEvent, FullWidthCellKeyDownEvent, GridColumnsChangedEvent, GridPreDestroyedEvent, GridReadyEvent, GridSizeChangedEvent, HeaderFocusedEvent, ModelUpdatedEvent, NewColumnsLoadedEvent, PaginationChangedEvent, PasteEndEvent, PasteStartEvent, PinnedRowDataChangedEvent, PivotMaxColumnsExceededEvent, RangeDeleteEndEvent, RangeDeleteStartEvent, RangeSelectionChangedEvent, RedoEndedEvent, RedoStartedEvent, RowClickedEvent, RowDataUpdatedEvent, RowDoubleClickedEvent, RowDragCancelEvent, RowDragEndEvent, RowDragEnterEvent, RowDragLeaveEvent, RowDragMoveEvent, RowEditingStartedEvent, RowEditingStoppedEvent, RowGroupOpenedEvent, RowSelectedEvent, RowValueChangedEvent, SelectionChangedEvent, SortChangedEvent, StateUpdatedEvent, StoreRefreshedEvent, ToolPanelSizeChangedEvent, ToolPanelVisibleChangedEvent, TooltipHideEvent, TooltipShowEvent, UndoEndedEvent, UndoStartedEvent, ViewportChangedEvent, VirtualColumnsChangedEvent, VirtualRowRemovedEvent } from 'ag-grid-community';
import type { GridOptions, Module } from 'ag-grid-community';
import type { AgChartTheme, AgChartThemeOverrides } from 'ag-charts-types';
export interface Properties {
[propertyName: string]: any;
}
export interface Props<TData> {
/** Provided an initial gridOptions configuration to the component. If a property is specified in both gridOptions and via component binding the component binding takes precedence. */
gridOptions?: GridOptions<TData> | undefined;
/**
* Used to register AG Grid Modules directly with this instance of the grid.
* See [Providing Modules To Individual Grids](https://www.ag-grid.com/vue-data-grid/modules/#providing-modules-to-individual-grids) for more information.
*/
modules?: Module[] | undefined;
/** Specifies the status bar components to use in the status bar.
*/
statusBar?: {
statusPanels: StatusPanelDef[];
} | undefined;
/** Specifies the side bar components.
*/
sideBar?: SideBarDef | string | string[] | boolean | null | undefined;
/** Set to `true` to not show the context menu. Use if you don't want to use the default 'right click' context menu.
* @default false
*/
suppressContextMenu?: boolean | undefined;
/** When using `suppressContextMenu`, you can use the `onCellContextMenu` function to provide your own code to handle cell `contextmenu` events.
* This flag is useful to prevent the browser from showing its default context menu.
* @default false
*/
preventDefaultOnContextMenu?: boolean | undefined;
/** Allows context menu to show, even when `Ctrl` key is held down.
* @default false
*/
allowContextMenuWithControlKey?: boolean | undefined;
/** Changes the display type of the column menu.
* `'new'` just displays the main list of menu items. `'legacy'` displays a tabbed menu.
* @default 'new'
* @initial
*/
columnMenu?: 'legacy' | 'new' | undefined;
/** Only recommended for use if `columnMenu = 'legacy'`.
* When `true`, the column menu button will always be shown.
* When `false`, the column menu button will only show when the mouse is over the column header.
* When using `columnMenu = 'legacy'`, this will default to `false` instead of `true`.
* @default true
*/
suppressMenuHide?: boolean | undefined;
/** Set to `true` to use the browser's default tooltip instead of using the grid's Tooltip Component.
* @default false
* @initial
*/
enableBrowserTooltips?: boolean | undefined;
/** The trigger that will cause tooltips to show and hide.
* - `hover` - The tooltip will show/hide when a cell/header is hovered.
* - `focus` - The tooltip will show/hide when a cell/header is focused.
* @default 'hover'
* @initial
*/
tooltipTrigger?: 'hover' | 'focus' | undefined;
/** The delay in milliseconds that it takes for tooltips to show up once an element is hovered over.
* **Note:** This property does not work if `enableBrowserTooltips` is `true`.
* @default 2000
*/
tooltipShowDelay?: number | undefined;
/** The delay in milliseconds that it takes for tooltips to hide once they have been displayed.
* **Note:** This property does not work if `enableBrowserTooltips` is `true` and `tooltipHideTriggers` includes `timeout`.
* @default 10000
*/
tooltipHideDelay?: number | undefined;
/** Set to `true` to have tooltips follow the cursor once they are displayed.
* @default false
* @initial
*/
tooltipMouseTrack?: boolean | undefined;
/** This defines when tooltip will show up for Cells, Headers and SetFilter Items.
* - `standard` - The tooltip always shows up when the items configured with Tooltips are hovered.
* - `whenTruncated` - The tooltip will only be displayed when the items hovered have truncated (showing ellipsis) values. This property does not work when `enableBrowserTooltips={true}`.
* @default `standard`
*/
tooltipShowMode?: 'standard' | 'whenTruncated' | undefined;
/** Set to `true` to enable tooltip interaction. When this option is enabled, the tooltip will not hide while the
* tooltip itself it being hovered or has focus.
* @default false
* @initial
*/
tooltipInteraction?: boolean | undefined;
/** DOM element to use as the popup parent for grid popups (context menu, column menu etc).
*/
popupParent?: HTMLElement | null | undefined;
/** Set to `true` to also include headers when copying to clipboard using `Ctrl + C` clipboard.
* @default false
*/
copyHeadersToClipboard?: boolean | undefined;
/** Set to `true` to also include group headers when copying to clipboard using `Ctrl + C` clipboard.
* @default false
*/
copyGroupHeadersToClipboard?: boolean | undefined;
/** Specify the delimiter to use when copying to clipboard.
* @default '\t'
*/
clipboardDelimiter?: string | undefined;
/** Set to `true` to copy the cell range or focused cell to the clipboard and never the selected rows.
* @default false
* @deprecated v32.2 Use `rowSelection.copySelectedRows` instead.
*/
suppressCopyRowsToClipboard?: boolean | undefined;
/** Set to `true` to copy rows instead of ranges when a range with only a single cell is selected.
* @default false
* @deprecated v32.2 Use `rowSelection.copySelectedRows` instead.
*/
suppressCopySingleCellRanges?: boolean | undefined;
/** Set to `true` to work around a bug with Excel (Windows) that adds an extra empty line at the end of ranges copied to the clipboard.
* @default false
*/
suppressLastEmptyLineOnPaste?: boolean | undefined;
/** Set to `true` to turn off paste operations within the grid.
* @default false
*/
suppressClipboardPaste?: boolean | undefined;
/** Set to `true` to stop the grid trying to use the Clipboard API, if it is blocked, and immediately fallback to the workaround.
* @default false
*/
suppressClipboardApi?: boolean | undefined;
/** Set to `true` to block **cut** operations within the grid.
* @default false
*/
suppressCutToClipboard?: boolean | undefined;
/** Array of Column / Column Group definitions.
*/
columnDefs?: (ColDef | ColGroupDef<TData>)[] | null | undefined;
/** A default column definition. Items defined in the actual column definitions get precedence.
*/
defaultColDef?: ColDef | undefined;
/** A default column group definition. All column group definitions will use these properties. Items defined in the actual column group definition get precedence.
* @initial
*/
defaultColGroupDef?: Partial<ColGroupDef<TData>> | undefined;
/** An object map of custom column types which contain groups of properties that column definitions can reuse by referencing in their `type` property.
*/
columnTypes?: {
[key: string]: ColTypeDef<TData>;
} | undefined;
/** An object map of cell data types to their definitions.
* Cell data types can either override/update the pre-defined data types
* (`'text'`, `'number'`, `'boolean'`, `'date'`, `'dateString'` or `'object'`),
* or can be custom data types.
*/
dataTypeDefinitions?: {
[cellDataType: string]: DataTypeDefinition<TData>;
} | undefined;
/** Keeps the order of Columns maintained after new Column Definitions are updated.
*
* @default false
*/
maintainColumnOrder?: boolean | undefined;
/** Resets pivot column order when impacted by filters, data or configuration changes
*
* @default false
*/
enableStrictPivotColumnOrder?: boolean | undefined;
/** If `true`, then dots in field names (e.g. `'address.firstLine'`) are not treated as deep references. Allows you to use dots in your field name if you prefer.
* @default false
*/
suppressFieldDotNotation?: boolean | undefined;
/** The height in pixels for the row containing the column label header. If not specified, it uses the theme value of `header-height`.
*/
headerHeight?: number | undefined;
/** The height in pixels for the rows containing header column groups. If not specified, it uses `headerHeight`.
*/
groupHeaderHeight?: number | undefined;
/** The height in pixels for the row containing the floating filters. If not specified, it uses the theme value of `header-height`.
*/
floatingFiltersHeight?: number | undefined;
/** The height in pixels for the row containing the columns when in pivot mode. If not specified, it uses `headerHeight`.
*/
pivotHeaderHeight?: number | undefined;
/** The height in pixels for the row containing header column groups when in pivot mode. If not specified, it uses `groupHeaderHeight`.
*/
pivotGroupHeaderHeight?: number | undefined;
/** Allow reordering and pinning columns by dragging columns from the Columns Tool Panel to the grid.
* @default false
*/
allowDragFromColumnsToolPanel?: boolean | undefined;
/** Set to `true` to suppress column moving, i.e. to make the columns fixed position.
* @default false
*/
suppressMovableColumns?: boolean | undefined;
/** If `true`, the `ag-column-moving` class is not added to the grid while columns are moving. In the default themes, this results in no animation when moving columns.
* @default false
*/
suppressColumnMoveAnimation?: boolean | undefined;
/** Set to `true` to suppress moving columns while dragging the Column Header. This option highlights the position where the column will be placed and it will only move it on mouse up.
* @default false
*/
suppressMoveWhenColumnDragging?: boolean | undefined;
/** If `true`, when you drag a column out of the grid (e.g. to the group zone) the column is not hidden.
* @default false
*/
suppressDragLeaveHidesColumns?: boolean | undefined;
/** Enable to prevent column visibility changing when grouped columns are changed.
* @default false
*/
suppressGroupChangesColumnVisibility?: boolean | 'suppressHideOnGroup' | 'suppressShowOnUngroup' | undefined;
/** By default, when a column is un-grouped, i.e. using the Row Group Panel, it is made visible in the grid. This property stops the column becoming visible again when un-grouping.
* @default false
* @deprecated v33.0.0 - Use `suppressGroupChangesColumnVisibility: 'suppressShowOnUngroup'` instead.
*/
suppressMakeColumnVisibleAfterUnGroup?: boolean | undefined;
/** If `true`, when you drag a column into a row group panel the column is not hidden.
* @default false
* @deprecated v33.0.0 - Use `suppressGroupChangesColumnVisibility: 'suppressHideOnGroup'` instead.
*/
suppressRowGroupHidesColumns?: boolean | undefined;
/** Set to `'shift'` to have shift-resize as the default resize operation (same as user holding down `Shift` while resizing).
*/
colResizeDefault?: 'shift' | undefined;
/** Suppresses auto-sizing columns for columns. In other words, double clicking a column's header's edge will not auto-size.
* @default false
* @initial
*/
suppressAutoSize?: boolean | undefined;
/** Number of pixels to add to a column width after the [auto-sizing](./column-sizing/#auto-size-columns-to-fit-cell-contents) calculation.
* Set this if you want to add extra room to accommodate (for example) sort icons, or some other dynamic nature of the header.
* @default 20
*/
autoSizePadding?: number | undefined;
/** Set this to `true` to skip the `headerName` when `autoSize` is called by default.
* @default false
* @initial
*/
skipHeaderOnAutoSize?: boolean | undefined;
/** Auto-size the columns when the grid is loaded. Can size to fit the grid width, fit a provided width, or fit the cell contents.
* @initial
*/
autoSizeStrategy?: SizeColumnsToFitGridStrategy | SizeColumnsToFitProvidedWidthStrategy | SizeColumnsToContentStrategy | undefined;
/** A map of component names to components.
* @initial
*/
components?: {
[p: string]: any;
} | undefined;
/** Set to `'fullRow'` to enable Full Row Editing. Otherwise leave blank to edit one cell at a time.
*/
editType?: 'fullRow' | undefined;
/** Set to `true` to enable Single Click Editing for cells, to start editing with a single click.
* @default false
*/
singleClickEdit?: boolean | undefined;
/** Set to `true` so that neither single nor double click starts editing.
* @default false
*/
suppressClickEdit?: boolean | undefined;
/** Set to `true` to stop the grid updating data after `Edit`, `Clipboard` and `Fill Handle` operations. When this is set, it is intended the application will update the data, eg in an external immutable store, and then pass the new dataset to the grid. <br />**Note:** `rowNode.setDataValue()` does not update the value of the cell when this is `True`, it fires `onCellEditRequest` instead.
* @default false
*/
readOnlyEdit?: boolean | undefined;
/** Set this to `true` to stop cell editing when grid loses focus.
* The default is that the grid stays editing until focus goes onto another cell.
* @default false
* @initial
*/
stopEditingWhenCellsLoseFocus?: boolean | undefined;
/** Set to `true` along with `enterNavigatesVerticallyAfterEdit` to have Excel-style behaviour for the `Enter` key.
* i.e. pressing the `Enter` key will move down to the cell beneath and `Shift+Enter` will move up to the cell above.
* @default false
*/
enterNavigatesVertically?: boolean | undefined;
/** Set to `true` along with `enterNavigatesVertically` to have Excel-style behaviour for the 'Enter' key.
* i.e. pressing the Enter key will move down to the cell beneath and Shift+Enter key will move up to the cell above.
* @default false
*/
enterNavigatesVerticallyAfterEdit?: boolean | undefined;
/** Forces Cell Editing to start when backspace is pressed. This is only relevant for MacOS users.
*/
enableCellEditingOnBackspace?: boolean | undefined;
/** Set to `true` to enable Undo / Redo while editing.
* @initial
*/
undoRedoCellEditing?: boolean | undefined;
/** Set the size of the undo / redo stack.
* @default 10
* @initial
*/
undoRedoCellEditingLimit?: number | undefined;
/** A default configuration object used to export to CSV.
*/
defaultCsvExportParams?: CsvExportParams | undefined;
/** Prevents the user from exporting the grid to CSV.
* @default false
*/
suppressCsvExport?: boolean | undefined;
/** A default configuration object used to export to Excel.
*/
defaultExcelExportParams?: ExcelExportParams | undefined;
/** Prevents the user from exporting the grid to Excel.
* @default false
*/
suppressExcelExport?: boolean | undefined;
/** A list (array) of Excel styles to be used when exporting to Excel with styles.
* @initial
*/
excelStyles?: ExcelStyle[] | undefined;
/** Text to find within the grid.
*/
findSearchValue?: string | undefined;
/** Options for the Find feature.
*/
findOptions?: FindOptions | undefined;
/** Rows are filtered using this text as a Quick Filter.
* Only supported for Client-Side Row Model.
*/
quickFilterText?: string | undefined;
/** Set to `true` to turn on the Quick Filter cache, used to improve performance when using the Quick Filter.
* @default false
* @initial
*/
cacheQuickFilter?: boolean | undefined;
/** Hidden columns are excluded from the Quick Filter by default.
* To include hidden columns, set to `true`.
* @default false
*/
includeHiddenColumnsInQuickFilter?: boolean | undefined;
/** Changes how the Quick Filter splits the Quick Filter text into search terms.
*/
quickFilterParser?: ((quickFilter: string) => string[]) | undefined;
/** Changes the matching logic for whether a row passes the Quick Filter.
*/
quickFilterMatcher?: ((quickFilterParts: string[], rowQuickFilterAggregateText: string) => boolean) | undefined;
/** When pivoting, Quick Filter is only applied on the pivoted data
* (or aggregated data if `groupAggFiltering = true`).
* Set to `true` to apply Quick Filter before pivoting (/aggregating) instead.
* @default false
*/
applyQuickFilterBeforePivotOrAgg?: boolean | undefined;
/** Set to `true` to override the default tree data filtering behaviour to instead exclude child nodes from filter results.
* @default false
*/
excludeChildrenWhenTreeDataFiltering?: boolean | undefined;
/** Set to true to enable the Advanced Filter.
* @default false
*/
enableAdvancedFilter?: boolean | undefined;
/** Allows rows to always be displayed, even if they don't match the applied filtering.
* Return `true` for the provided row to always be displayed.
* Only works with the Client-Side Row Model.
*/
alwaysPassFilter?: ((rowNode: IRowNode<TData>) => boolean) | undefined;
/** Hidden columns are excluded from the Advanced Filter by default.
* To include hidden columns, set to `true`.
* @default false
*/
includeHiddenColumnsInAdvancedFilter?: boolean | undefined;
/** DOM element to use as the parent for the Advanced Filter to allow it to appear outside of the grid.
* Set to `null` or `undefined` to appear inside the grid.
*/
advancedFilterParent?: HTMLElement | null | undefined;
/** Customise the parameters passed to the Advanced Filter Builder.
*/
advancedFilterBuilderParams?: IAdvancedFilterBuilderParams | undefined;
/** By default, Advanced Filter sanitises user input and passes it to `new Function()` to provide the best performance.
* Set to `true` to prevent this and use defined functions instead.
* This will result in slower filtering, but it enables Advanced Filter to work when `unsafe-eval` is disabled.
* @default false
*/
suppressAdvancedFilterEval?: boolean | undefined;
/** When using AG Grid Enterprise, the Set Filter is used by default when `filter: true` is set on column definitions.
* Set to `true` to prevent this and instead use the Text Filter, Number Filter or Date Filter based on the cell data type,
* the same as when using AG Grid Community.
* @default false
* @initial
*/
suppressSetFilterByDefault?: boolean | undefined;
/** Set to `true` to Enable Charts.
* @default false
*/
enableCharts?: boolean | undefined;
/** The list of chart themes that a user can choose from in the chart panel.
* @default ['ag-default', 'ag-material', 'ag-sheets', 'ag-polychroma', 'ag-vivid'];
* @initial
*/
chartThemes?: string[] | undefined;
/** A map containing custom chart themes.
* @initial
*/
customChartThemes?: {
[name: string]: AgChartTheme;
} | undefined;
/** Chart theme overrides applied to all themes.
* @initial
*/
chartThemeOverrides?: AgChartThemeOverrides | undefined;
/** Allows customisation of the Chart Tool Panels, such as changing the tool panels visibility and order, as well as choosing which charts should be displayed in the chart panel.
* @initial
*/
chartToolPanelsDef?: ChartToolPanelsDef | undefined;
/** Get chart menu items. Only applies when using AG Charts Enterprise.
*/
chartMenuItems?: (DefaultChartMenuItem | MenuItemDef)[] | GetChartMenuItems<TData> | undefined;
/** Provide your own loading cell renderer to use when data is loading via a DataSource.
* See [Loading Cell Renderer](https://www.ag-grid.com/javascript-data-grid/component-loading-cell-renderer/) for framework specific implementation details.
*/
loadingCellRenderer?: any;
/** Params to be passed to the `loadingCellRenderer` component.
*/
loadingCellRendererParams?: any;
/** Callback to select which loading cell renderer to be used when data is loading via a DataSource.
* @initial
*/
loadingCellRendererSelector?: LoadingCellRendererSelectorFunc<TData> | undefined;
/** A map of key->value pairs for localising text within the grid.
* @initial
*/
localeText?: {
[key: string]: string;
} | undefined;
/** Set to `true` to enable Master Detail.
* @default false
*/
masterDetail?: boolean | undefined;
/** Set to `true` to keep detail rows for when they are displayed again.
* @default false
* @initial
*/
keepDetailRows?: boolean | undefined;
/** Sets the number of details rows to keep.
* @default 10
* @initial
*/
keepDetailRowsCount?: number | undefined;
/** Provide a custom `detailCellRenderer` to use when a master row is expanded.
* See [Detail Cell Renderer](https://www.ag-grid.com/javascript-data-grid/master-detail-custom-detail/) for framework specific implementation details.
*/
detailCellRenderer?: any;
/** Specifies the params to be used by the Detail Cell Renderer. Can also be a function that provides the params to enable dynamic definitions of the params.
*/
detailCellRendererParams?: any;
/** Set fixed height in pixels for each detail row.
* @initial
*/
detailRowHeight?: number | undefined;
/** Set to `true` to have the detail grid dynamically change it's height to fit it's rows.
* @initial
*/
detailRowAutoHeight?: boolean | undefined;
/** Provides a context object that is provided to different callbacks the grid uses. Used for passing additional information to the callbacks used by your application.
* @initial
*/
context?: any;
/** Provide a custom drag and drop image component.
* @initial
*/
dragAndDropImageComponent?: any;
/** Customise the parameters provided to the Drag and Drop Image Component.
*/
dragAndDropImageComponentParams?: any;
/**
* A list of grids to treat as Aligned Grids.
* Provide a list if the grids / apis already exist or return via a callback to allow the aligned grids to be retrieved asynchronously.
* If grids are aligned then the columns and horizontal scrolling will be kept in sync.
*/
alignedGrids?: (AlignedGrid[] | (() => AlignedGrid[])) | undefined;
/** Change this value to set the tabIndex order of the Grid within your application.
* @default 0
* @initial
*/
tabIndex?: number | undefined;
/** The number of rows rendered outside the viewable area the grid renders.
* Having a buffer means the grid will have rows ready to show as the user slowly scrolls vertically.
* @default 10
*/
rowBuffer?: number | undefined;
/** Set to `true` to turn on the value cache.
* @default false
* @initial
*/
valueCache?: boolean | undefined;
/** Set to `true` to configure the value cache to not expire after data updates.
* @default false
* @initial
*/
valueCacheNeverExpires?: boolean | undefined;
/** Set to `true` to allow cell expressions.
* @default false
* @initial
*/
enableCellExpressions?: boolean | undefined;
/** Disables touch support (but does not remove the browser's efforts to simulate mouse events on touch).
* @default false
* @initial
*/
suppressTouch?: boolean | undefined;
/** Set to `true` to not set focus back on the grid after a refresh. This can avoid issues where you want to keep the focus on another part of the browser.
* @default false
*/
suppressFocusAfterRefresh?: boolean | undefined;
/** @deprecated As of v32.2 the grid always uses the browser's ResizeObserver, this grid option has no effect
* @default false
* @initial
*/
suppressBrowserResizeObserver?: boolean | undefined;
/** @deprecated As of v33 `gridOptions` and `columnDefs` both have a `context` property that should be used for arbitrary user data. This means that column definitions and gridOptions should only contain valid properties making this property redundant.
* @default false
* @initial
*/
suppressPropertyNamesCheck?: boolean | undefined;
/** Disables change detection.
* @default false
*/
suppressChangeDetection?: boolean | undefined;
/** Set this to `true` to enable debug information from the grid and related components. Will result in additional logging being output, but very useful when investigating problems.
* @default false
* @initial
*/
debug?: boolean | undefined;
/** Show or hide the loading overlay.
*/
loading?: boolean | undefined;
/** Provide a HTML string to override the default loading overlay. Supports non-empty plain text or HTML with a single root element.
*/
overlayLoadingTemplate?: string | undefined;
/** Provide a custom loading overlay component.
* @initial
*/
loadingOverlayComponent?: any;
/** Customise the parameters provided to the loading overlay component.
*/
loadingOverlayComponentParams?: any;
/** Disables the 'loading' overlay.
* @deprecated v32 - Deprecated. Use `loading=false` instead.
* @default false
* @initial
*/
suppressLoadingOverlay?: boolean | undefined;
/** Provide a HTML string to override the default no-rows overlay. Supports non-empty plain text or HTML with a single root element.
*/
overlayNoRowsTemplate?: string | undefined;
/** Provide a custom no-rows overlay component.
* @initial
*/
noRowsOverlayComponent?: any;
/** Customise the parameters provided to the no-rows overlay component.
*/
noRowsOverlayComponentParams?: any;
/** Set to `true` to prevent the no-rows overlay being shown when there is no row data.
* @default false
* @initial
*/
suppressNoRowsOverlay?: boolean | undefined;
/** Set whether pagination is enabled.
* @default false
*/
pagination?: boolean | undefined;
/** How many rows to load per page. If `paginationAutoPageSize` is specified, this property is ignored.
* @default 100
*/
paginationPageSize?: number | undefined;
/** Determines if the page size selector is shown in the pagination panel or not.
* Set to an array of values to show the page size selector with custom list of possible page sizes.
* Set to `true` to show the page size selector with the default page sizes `[20, 50, 100]`.
* Set to `false` to hide the page size selector.
* @default true
* @initial
*/
paginationPageSizeSelector?: number[] | boolean | undefined;
/** Set to `true` so that the number of rows to load per page is automatically adjusted by the grid so each page shows enough rows to just fill the area designated for the grid. If `false`, `paginationPageSize` is used.
* @default false
*/
paginationAutoPageSize?: boolean | undefined;
/** Set to `true` to have pages split children of groups when using Row Grouping or detail rows with Master Detail.
* @default false
* @initial
*/
paginateChildRows?: boolean | undefined;
/** If `true`, the default grid controls for navigation are hidden.
* This is useful if `pagination=true` and you want to provide your own pagination controls.
* Otherwise, when `pagination=true` the grid automatically shows the necessary controls at the bottom so that the user can navigate through the different pages.
* @default false
*/
suppressPaginationPanel?: boolean | undefined;
/** Set to `true` to enable pivot mode.
* @default false
*/
pivotMode?: boolean | undefined;
/** When to show the 'pivot panel' (where you drag rows to pivot) at the top. Note that the pivot panel will never show if `pivotMode` is off.
* @default 'never'
* @initial
*/
pivotPanelShow?: 'always' | 'onlyWhenPivoting' | 'never' | undefined;
/** The maximum number of generated columns before the grid halts execution. Upon reaching this number, the grid halts generation of columns
* and triggers a `pivotMaxColumnsExceeded` event. `-1` for no limit.
* @default -1
*/
pivotMaxGeneratedColumns?: number | undefined;
/** If pivoting, set to the number of column group levels to expand by default, e.g. `0` for none, `1` for first level only, etc. Set to `-1` to expand everything.
* @default 0
*/
pivotDefaultExpanded?: number | undefined;
/** When set and the grid is in pivot mode, automatically calculated totals will appear within the Pivot Column Groups, in the position specified.
*/
pivotColumnGroupTotals?: 'before' | 'after' | undefined;
/** When set and the grid is in pivot mode, automatically calculated totals will appear for each value column in the position specified.
*/
pivotRowTotals?: 'before' | 'after' | undefined;
/** If `true`, the grid will not swap in the grouping column when pivoting. Useful if pivoting using Server Side Row Model or Viewport Row Model and you want full control of all columns including the group column.
* @default false
* @initial
*/
pivotSuppressAutoColumn?: boolean | undefined;
/** When enabled, pivot column groups will appear 'fixed', without the ability to expand and collapse the column groups.
* @default false
* @initial
*/
suppressExpandablePivotGroups?: boolean | undefined;
/** If `true`, then row group, pivot and value aggregation will be read-only from the GUI. The grid will display what values are used for each, but will not allow the user to change the selection.
* @default false
*/
functionsReadOnly?: boolean | undefined;
/** A map of 'function name' to 'function' for custom aggregation functions.
* @initial
*/
aggFuncs?: {
[key: string]: IAggFunc<TData>;
} | undefined;
/** When `true`, column headers won't include the `aggFunc` name, e.g. `'sum(Bank Balance)`' will just be `'Bank Balance'`.
* @default false
*/
suppressAggFuncInHeader?: boolean | undefined;
/** When using aggregations, the grid will always calculate the root level aggregation value.
* @default false
*/
alwaysAggregateAtRootLevel?: boolean | undefined;
/** When using change detection, only the updated column will be re-aggregated.
* @default false
*/
aggregateOnlyChangedColumns?: boolean | undefined;
/** Set to `true` so that aggregations are not impacted by filtering.
* @default false
*/
suppressAggFilteredOnly?: boolean | undefined;
/** Set to `true` to omit the value Column header when there is only a single value column.
* @default false
*/
removePivotHeaderRowWhenSingleValueColumn?: boolean | undefined;
/** Set to `false` to disable Row Animation which is enabled by default.
* @default true
*/
animateRows?: boolean | undefined;
/** Sets the duration in milliseconds of how long a cell should remain in its "flashed" state.
* If `0`, the cell will not flash.
* @default 500
*/
cellFlashDuration?: number | undefined;
/** Sets the duration in milliseconds of how long the "flashed" state animation takes to fade away after the timer set by `cellFlashDuration` has completed.
* @default 1000
*/
cellFadeDuration?: number | undefined;
/** Set to `true` to have cells flash after data changes even when the change is due to filtering.
* @default false
* @initial
*/
allowShowChangeAfterFilter?: boolean | undefined;
/** Switch between layout options: `normal`, `autoHeight`, `print`.
* @default 'normal'
*/
domLayout?: DomLayoutType | undefined;
/** When `true`, the order of rows and columns in the DOM are consistent with what is on screen.
* Disables row animations.
* @default false
* @initial
*/
ensureDomOrder?: boolean | undefined;
/** When `true`, enables the cell span feature allowing for the use of the `colDef.spanRows` property.
* @default false
* @initial
*/
enableCellSpan?: boolean | undefined;
/** Set to `true` to operate the grid in RTL (Right to Left) mode.
* @default false
* @initial
*/
enableRtl?: boolean | undefined;
/** Set to `true` so that the grid doesn't virtualise the columns. For example, if you have 100 columns, but only 10 visible due to scrolling, all 100 will always be rendered.
* @default false
* @initial
*/
suppressColumnVirtualisation?: boolean | undefined;
/** By default the grid has a limit of rendering a maximum of 500 rows at once (remember the grid only renders rows you can see, so unless your display shows more than 500 rows without vertically scrolling this will never be an issue).
* <br />**This is only relevant if you are manually setting `rowBuffer` to a high value (rendering more rows than can be seen), or `suppressRowVirtualisation` is true, or if your grid height is able to display more than 500 rows at once.**
* @default false
* @initial
*/
suppressMaxRenderedRowRestriction?: boolean | undefined;
/** Set to `true` so that the grid doesn't virtualise the rows. For example, if you have 100 rows, but only 10 visible due to scrolling, all 100 will always be rendered.
* @default false
* @initial
*/
suppressRowVirtualisation?: boolean | undefined;
/** Set to `true` to enable Managed Row Dragging.
* @default false
*/
rowDragManaged?: boolean | undefined;
/** Set to `true` to suppress row dragging.
* @default false
*/
suppressRowDrag?: boolean | undefined;
/** Set to `true` to suppress moving rows while dragging the `rowDrag` waffle. This option highlights the position where the row will be placed and it will only move the row on mouse up.
* @default false
*/
suppressMoveWhenRowDragging?: boolean | undefined;
/** Set to `true` to enable clicking and dragging anywhere on the row without the need for a drag handle.
* @default false
*/
rowDragEntireRow?: boolean | undefined;
/** Set to `true` to enable dragging multiple rows at the same time.
* @default false
*/
rowDragMultiRow?: boolean | undefined;
/** A callback that should return a string to be displayed by the `rowDragComp` while dragging a row.
* If this callback is not set, the current cell value will be used.
* If the `rowDragText` callback is set in the ColDef it will take precedence over this, except when
* `rowDragEntireRow=true`.
* @initial
*/
rowDragText?: ((params: IRowDragItem, dragItemCount: number) => string) | undefined;
/** Provide your own cell renderer component to use for full width rows.
* See [Full Width Rows](https://www.ag-grid.com/javascript-data-grid/full-width-rows/) for framework specific implementation details.
*/
fullWidthCellRenderer?: any;
/** Customise the parameters provided to the `fullWidthCellRenderer` component.
*/
fullWidthCellRendererParams?: any;
/** Set to `true` to have the Full Width Rows embedded in grid's main container so they can be scrolled horizontally.
*/
embedFullWidthRows?: boolean | undefined;
/** Specifies how the results of row grouping should be displayed.
*
* The options are:
*
* - `'singleColumn'`: single group column automatically added by the grid.
* - `'multipleColumns'`: a group column per row group is added automatically.
* - `'groupRows'`: group rows are automatically added instead of group columns.
* - `'custom'`: informs the grid that group columns will be provided.
*/
groupDisplayType?: RowGroupingDisplayType | undefined;
/** If grouping, set to the number of levels to expand by default, e.g. `0` for none, `1` for first level only, etc. Set to `-1` to expand everything.
* @default 0
*/
groupDefaultExpanded?: number | undefined;
/** Allows specifying the group 'auto column' if you are not happy with the default. If grouping, this column definition is included as the first column in the grid. If not grouping, this column is not included.
*/
autoGroupColumnDef?: ColDef<TData> | undefined;
/** When `true`, preserves the current group order when sorting on non-group columns.
* @default false
*/
groupMaintainOrder?: boolean | undefined;
/** When `true`, if you select a group, the children of the group will also be selected.
* @default false
* @deprecated v32.2 Use `rowSelection.groupSelects` instead
*/
groupSelectsChildren?: boolean | undefined;
/** If grouping, locks the group settings of a number of columns, e.g. `0` for no group locking. `1` for first group column locked, `-1` for all group columns locked.
* @default 0
* @initial
*/
groupLockGroupColumns?: number | undefined;
/** Set to determine whether filters should be applied on aggregated group values.
* @default false
*/
groupAggFiltering?: boolean | IsRowFilterable<TData> | undefined;
/** When provided, an extra row group total row will be inserted into row groups at the specified position, to display
* when the group is expanded. This row will contain the aggregate values for the group. If a callback function is
* provided, it can be used to selectively determine which groups will have a total row added.
*/
groupTotalRow?: 'top' | 'bottom' | UseGroupTotalRow<TData> | undefined;
/** When provided, an extra grand total row will be inserted into the grid at the specified position.
* This row displays the aggregate totals of all rows in the grid.
*/
grandTotalRow?: 'top' | 'bottom' | undefined;
/** Suppress the sticky behaviour of the total rows, can be suppressed individually by passing `'grand'` or `'group'`.
*/
suppressStickyTotalRow?: boolean | 'grand' | 'group' | undefined;
/** If `true`, and showing footer, aggregate data will always be displayed at both the header and footer levels. This stops the possibly undesirable behaviour of the header details 'jumping' to the footer on expand.
* @default false
*/
groupSuppressBlankHeader?: boolean | undefined;
/** If using `groupSelectsChildren`, then only the children that pass the current filter will get selected.
* @default false
* @deprecated v32.2 Use `rowSelection.groupSelects` instead
*/
groupSelectsFiltered?: boolean | undefined;
/** Shows the open group in the group column for non-group rows.
* @default false
*/
showOpenedGroup?: boolean | undefined;
/** Enable to display the child row in place of the group row when the group only has a single child.
* @default false
*/
groupHideParentOfSingleChild?: boolean | 'leafGroupsOnly' | undefined;
/** Set to `true` to collapse groups that only have one child.
* @default false
* @deprecated v33.0.0 - use `groupHideParentOfSingleChild` instead.
*/
groupRemoveSingleChildren?: boolean | undefined;
/** Set to `true` to collapse lowest level groups that only have one child.
* @default false
* @deprecated v33.0.0 - use `groupHideParentOfSingleChild: 'leafGroupsOnly'` instead.
*/
groupRemoveLowestSingleChildren?: boolean | undefined;
/** Set to `true` to hide parents that are open. When used with multiple columns for showing groups, it can give a more pleasing user experience.
* @default false
*/
groupHideOpenParents?: boolean | undefined;
/** Set to `true` to prevent the grid from creating a '(Blanks)' group for nodes which do not belong to a group, and display the unbalanced nodes alongside group nodes.
* @default false
*/
groupAllowUnbalanced?: boolean | undefined;
/** When to show the 'row group panel' (where you drag rows to group) at the top.
* @default 'never'
*/
rowGroupPanelShow?: 'always' | 'onlyWhenGrouping' | 'never' | undefined;
/** Provide the Cell Renderer to use when `groupDisplayType = 'groupRows'`.
* See [Group Row Cell Renderer](https://www.ag-grid.com/javascript-data-grid/grouping-group-rows/#providing-cell-renderer) for framework specific implementation details.
*/
groupRowRenderer?: any;
/** Customise the parameters provided to the `groupRowRenderer` component.
*/
groupRowRendererParams?: any;
/** Set to `true` to enable the Grid to work with Tree Data.
* You must also implement the `getDataPath(data)` callback.
* @default false
*/
treeData?: boolean | undefined;
/** The name of the field to use in a data item to retrieve the array of children nodes of a node when while using treeData=true.
* It supports accessing nested fields using the dot notation.
*/
treeDataChildrenField?: string | undefined;
/** The name of the field to use in a data item to find the parent node of a node when using treeData=true.
* The tree will be constructed via relationships between nodes using this field.
* getRowId callback need to be provided as well for this to work.
* It supports accessing nested fields using the dot notation.
*/
treeDataParentIdField?: string | undefined;
/** Set to `true` to suppress sort indicators and actions from the row group panel.
* @default false
*/
rowGroupPanelSuppressSort?: boolean | undefined;
/** Set to `true` prevent Group Rows from sticking to the top of the grid.
* @default false
* @initial
*/
suppressGroupRowsSticky?: boolean | undefined;
/** Data to be displayed as pinned top rows in the grid.
*/
pinnedTopRowData?: any[] | undefined;
/** Data to be displayed as pinned bottom rows in the grid.
*/
pinnedBottomRowData?: any[] | undefined;
/** Sets the row model type.
* @default 'clientSide'
* @initial
*/
rowModelType?: RowModelType | undefined;
/** Set the data to be displayed as rows in the grid.
*/
rowData?: TData[] | null | undefined;
/** How many milliseconds to wait before executing a batch of async transactions.
*/
asyncTransactionWaitMillis?: number | undefined;
/** Prevents Transactions changing sort, filter, group or pivot state when transaction only contains updates.
* @default false
*/
suppressModelUpdateAfterUpdateTransaction?: boolean | undefined;
/** Provide the datasource for infinite scrolling.
*/
datasource?: IDatasource | undefined;
/** How many extra blank rows to display to the user at the end of the dataset, which sets the vertical scroll and then allows the grid to request viewing more rows of data.
* @default 1
* @initial
*/
cacheOverflowSize?: number | undefined;
/** How many extra blank rows to display to the user at the end of the dataset, which sets the vertical scroll and then allows the grid to request viewing more rows of data.
* @default 1
* @initial
*/
infiniteInitialRowCount?: number | undefined;
/** Set how many loading rows to display to the user for the root level group.
* @default 1
* @initial
*/
serverSideInitialRowCount?: number | undefined;
/** When `true`, the Server-side Row Model will not use a full width loading renderer, instead using the colDef `loadingCellRenderer` if present.
*/
suppressServerSideFullWidthLoadingRow?: boolean | undefined;
/** How many rows for each block in the store, i.e. how many rows returned from the server at a time.
* @default 100
*/
cacheBlockSize?: number | undefined;
/** How many blocks to keep in the stor