AdaptableOptions
Design-time configuration for one AdapTable instance.
These options are fixed by the application. Objects the user can change and that are persisted (Layouts, Alerts, Format Columns, Calculated Columns and the other module objects) belong in , not here.
primaryKey and initialState are required. Every *Options property is optional: omit it to keep that module's defaults.
export interface AdaptableOptions<TData = any, TContext = Record<string,Properties
| Property | Type | Description | Default |
|---|---|---|---|
| actionColumnOptions | ActionColumnOptions<TData> | Action Columns: columns of buttons, menus, toggles and other controls that run an action on the row. The columns themselves are supplied here. They are not part of Initial State. | |
| adaptableContext | TContext | Values from the host application, passed into every callback and event as adaptableContext.Use it for things the grid should see but not store, such as the current user, permissions or a service. It is not persisted. | |
| adaptableId | string | Identifies this grid when more than one AdapTable is on the page. Also the default key under which state is stored, unless is set. A generated id ( adaptable_id_ plus a random number) is used when this is omitted, so state will not survive a reload. | 'adaptable_id_$random_number' |
| adaptableStateKey | string | Key under which this grid's state is stored, instead of . Set it when several grids should share one state, or when the storage key should change without changing adaptableId. is applied only when nothing is already stored under this key. | adaptableId value |
| alertOptions | AlertOptions<TData> | How fired alerts behave: how many are kept, how long a cell or row stays highlighted, and the text shown when an alert fires. The Alert Definitions themselves (the rules) belong in Initial State. | |
| autogeneratePrimaryKey | boolean | Invents a primary key when the data has no unique column. Use it only as a last resort. Notes, comments, data-change history and row identity then cannot follow a real business key, and some of those features are limited. | false |
| calculatedColumnOptions | CalculatedColumnOptions | Calculated Columns whose values come from an AdapTableQL expression: formula trace, and how often aggregated columns recompute after row changes. The column definitions belong in Initial State. | |
| calendarOptions | CalendarOptions | Which days are working days. Weekend days and holidays are excluded from working-day expression functions. | |
| cellSummaryOptions | CellSummaryOptions<TData> | Extra summary operations for the selected cells, beyond the ones AdapTable ships (sum, average and the rest), and how the result is formatted. | |
| chartingOptions | ChartingOptions | Saving and reopening AG Grid charts, which containers they open in, and external (non-AG Grid) charts. Chart definitions the user saves are stored in state. These options control that behaviour. | |
| columnMenuOptions | ColumnMenuOptions<TData> | Replaces or extends the menu opened from a column header. The callback receives AdapTable's default items. | |
| columnOptions | ColumnOptions | Column captions and friendly names, column types used by Column Scope, and whether a missing column is logged. | |
| commentOptions | CommentOptions<TData> | Comments on cells: which cells can be commented, and how threads are loaded and saved. Comments are not part of AdapTable State. The application loads and persists them through these callbacks. | |
| containerOptions | ContainerOptions | DOM elements that host the grid, the AG Grid instance, the Settings Panel, alerts, system status and the transposed view. Set these when AdapTable is not mounted into the default divs. | |
| contextMenuOptions | ContextMenuOptions<TData> | Replaces or extends the right-click menu. The callback receives AdapTable's default items. | |
| customSortOptions | CustomSortOptions | Comparer functions for a Custom Sort, used when the sort order is not a simple list of values. The Custom Sort objects (the ordered values) belong in Initial State. | |
| dashboardOptions | DashboardOptions | The Dashboard above the grid: whether it can float, custom toolbars and buttons, and where the module buttons sit. Which toolbars are on each tab is stored in Dashboard state. | |
| dataChangeHistoryOptions | DataChangeHistoryOptions<TData> | The log of cell value changes: whether it starts active, which changes are recorded, and the undo button. | |
| dataImportOptions | DataImportOptions | The import wizard: how a file or pasted text becomes rows, how those rows are validated, and how they are written into the grid. | |
| dataSetOptions | DataSetOptions<TData> | Named sets of rows the user can switch between. Each set supplies its own data. | |
| editOptions | EditOptions<TData> | Cell editing: which cells can be edited, server-side validation, the values offered in a dropdown editor, Plus Minus nudges and Smart Edit. | |
| entitlementOptions | EntitlementOptions | Which modules a user may see or change. Full, ReadOnly or Hidden, per module or as a default.A module that defaults to hidden (such as State) stays hidden until moduleEntitlements allows it. | |
| exportOptions | ExportOptions<TData> | Reports: which system reports, formats and destinations are offered, custom destinations, and whether a column is included. Report definitions the user creates are stored in Export state. | |
| expressionOptions | ExpressionOptions<TData> | AdapTableQL: custom functions, which columns and fields an expression may use, case sensitivity, and how the expression editor is presented. Expressions saved on objects (a filter, an alert rule, a calculated column) live on those objects. These options change how every expression is evaluated and edited. | |
| fdc3Options | Fdc3Options | FDC3: which intents and contexts this grid raises, listens for and broadcasts, and how a row's columns map onto an FDC3 context. | |
| filterOptions | FilterOptions<TData> | Column Filters and the Grid Filter: whether AdapTable's filters are used instead of AG Grid's, the quick filter bar, and the default operator for each data type. The filters the user creates are stored in the Layout. | |
| flashingCellOptions | FlashingCellOptions | Defaults for a flashing cell when a Flashing Cell definition does not set them: up, down and neutral styles, whether the cell or the row flashes, and for how long. The definitions themselves belong in Initial State. | |
| formatColumnOptions | FormatColumnOptions | Display formatters beyond the ones AdapTable ships, used by Format Columns. The Format Column objects (which column, which style and format) belong in Initial State. | |
| initialState | InitialState | Objects shipped with the grid for its first run: at least one Layout, plus any Alerts, Format Columns, Calculated Columns and other module objects. Applied only when no state is already stored for this grid. After that, the stored state is used and later edits to initialState are ignored until that stored state is cleared or the state key changes. | undefined |
| layoutOptions | LayoutOptions<TData> | How Layouts are created and shown: a layout built from the AG Grid column definitions, defaults for a new Table or Pivot Layout, and whether layout extensions are offered in the UI. The Layout objects belong in Initial State. A grid needs at least one. | |
| licenseKey | string | Commercial licence key. Without a current licence, AdapTable shows licence notices and limits some functionality. | |
| noteOptions | NoteOptions | Notes on cells: which cells can hold a note, the note type applied on creation, and how the timestamp is formatted. The notes themselves are stored in Note state. | |
| notificationsOptions | NotificationsOptions | Toasts: where they appear, how long they stay, and how many system status messages are kept. | |
| plugins | AdaptablePlugin[] | Plugins constructed by the application and handed to AdapTable: OpenFin, ipushpull, interop.io and Master-Detail. Each plugin is created with its own options. This array registers them. | |
| primaryKey | string | Column whose values uniquely identify a row. Required. AdapTable uses it to find a row for edits, notes, comments, alerts, history and row forms. The values must be unique. | n/a (Mandatory) |
| quickSearchOptions | QuickSearchOptions<TData> | Quick Search: which cells are searched, whether matching rows are filtered, and whether the search is case sensitive. | |
| rowFormOptions | RowFormOptions<TData> | Create, clone and edit forms for a row: which columns appear, how the primary key of a new row is set, and whether AdapTable writes the result into the grid. | |
| settingsPanelOptions | SettingsPanelOptions | The Settings Panel: its title and icon, which modules appear and in which groups, and whether it opens as a modal or a movable window. | |
| stateOptions | StateOptions | Where state is loaded from and saved to. The default is localStorage.Replace loadState and persistState to keep state on a server. saveState and applyState change the object just before it is stored or applied. | |
| teamSharingOptions | TeamSharingOptions | Sharing Adaptable Objects with other users. The application loads and saves the shared objects; AdapTable does not ship a server. Turn it on with enableTeamSharing, then provide loadSharedEntities and persistSharedEntities. | |
| toolPanelOptions | ToolPanelOptions | The tool panel beside the grid: custom panels, custom buttons, and whether the panel dropdown is shown. | |
| userInterfaceOptions | UserInterfaceOptions<TData> | Shared UI: the application icon, custom icons, editable and read-only cell styles, the colour picker, date inputs, the loading screen, and the names shown for modules. | |
| userName | string | Name of the person using this grid. Stamped on Notes and Comments when the author is not supplied, and shown where Team Sharing records who shared an object. | 'anonymous' |
| wizardOptions | WizardOptions | Wizards and the other action popups (Bulk Update, Smart Edit, Cell Summary): modal or window, and the window's position and size. Independent of the Settings Panel. Ignored when containerOptions.modalContainer places every popup in one element. |
Property Details
actionColumnOptions
Action Columns: columns of buttons, menus, toggles and other controls that run an action on the row.
The columns themselves are supplied here. They are not part of Initial State.
actionColumnOptions?: ActionColumnOptions<TData>;Property Value
ActionColumnOptions<TData>
adaptableContext
Values from the host application, passed into every callback and event as adaptableContext.
Use it for things the grid should see but not store, such as the current user, permissions or a service. It is not persisted.
adaptableContext?: TContext;Default Value
Property Value
TContext
adaptableId
Identifies this grid when more than one AdapTable is on the page.
Also the default key under which state is stored, unless is set. A generated id (adaptable_id_ plus a random number) is used when this is omitted, so state will not survive a reload.
adaptableId?: string;Default Value
'adaptable_id_$random_number'
Property Value
string
adaptableStateKey
Key under which this grid's state is stored, instead of .
Set it when several grids should share one state, or when the storage key should change without changing adaptableId. is applied only when nothing is already stored under this key.
adaptableStateKey?: string;Default Value
adaptableId value
Property Value
string
alertOptions
How fired alerts behave: how many are kept, how long a cell or row stays highlighted, and the text shown when an alert fires.
The Alert Definitions themselves (the rules) belong in Initial State.
alertOptions?: AlertOptions<TData>;Property Value
AlertOptions<TData>
autogeneratePrimaryKey
Invents a primary key when the data has no unique column.
Use it only as a last resort. Notes, comments, data-change history and row identity then cannot follow a real business key, and some of those features are limited.
autogeneratePrimaryKey?: boolean;Default Value
false
Property Value
boolean
calculatedColumnOptions
Calculated Columns whose values come from an AdapTableQL expression: formula trace, and how often aggregated columns recompute after row changes.
The column definitions belong in Initial State.
calculatedColumnOptions?: CalculatedColumnOptions;Property Value
calendarOptions
Which days are working days. Weekend days and holidays are excluded from working-day expression functions.
calendarOptions?: CalendarOptions;Property Value
cellSummaryOptions
Extra summary operations for the selected cells, beyond the ones AdapTable ships (sum, average and the rest), and how the result is formatted.
cellSummaryOptions?: CellSummaryOptions<TData>;Property Value
CellSummaryOptions<TData>
chartingOptions
Saving and reopening AG Grid charts, which containers they open in, and external (non-AG Grid) charts.
Chart definitions the user saves are stored in state. These options control that behaviour.
chartingOptions?: ChartingOptions;Property Value
columnMenuOptions
Replaces or extends the menu opened from a column header. The callback receives AdapTable's default items.
columnMenuOptions?: ColumnMenuOptions<TData>;Property Value
ColumnMenuOptions<TData>
columnOptions
Column captions and friendly names, column types used by Column Scope, and whether a missing column is logged.
columnOptions?: ColumnOptions;Property Value
commentOptions
Comments on cells: which cells can be commented, and how threads are loaded and saved.
Comments are not part of AdapTable State. The application loads and persists them through these callbacks.
commentOptions?: CommentOptions<TData>;Property Value
CommentOptions<TData>
containerOptions
DOM elements that host the grid, the AG Grid instance, the Settings Panel, alerts, system status and the transposed view.
Set these when AdapTable is not mounted into the default divs.
containerOptions?: ContainerOptions;Property Value
contextMenuOptions
Replaces or extends the right-click menu. The callback receives AdapTable's default items.
contextMenuOptions?: ContextMenuOptions<TData>;Property Value
ContextMenuOptions<TData>
customSortOptions
Comparer functions for a Custom Sort, used when the sort order is not a simple list of values.
The Custom Sort objects (the ordered values) belong in Initial State.
customSortOptions?: CustomSortOptions;Property Value
dashboardOptions
The Dashboard above the grid: whether it can float, custom toolbars and buttons, and where the module buttons sit.
Which toolbars are on each tab is stored in Dashboard state.
dashboardOptions?: DashboardOptions;Property Value
dataChangeHistoryOptions
The log of cell value changes: whether it starts active, which changes are recorded, and the undo button.
dataChangeHistoryOptions?: DataChangeHistoryOptions<TData>;Property Value
DataChangeHistoryOptions<TData>
dataImportOptions
The import wizard: how a file or pasted text becomes rows, how those rows are validated, and how they are written into the grid.
dataImportOptions?: DataImportOptions;Property Value
dataSetOptions
Named sets of rows the user can switch between. Each set supplies its own data.
dataSetOptions?: DataSetOptions<TData>;Property Value
DataSetOptions<TData>
editOptions
Cell editing: which cells can be edited, server-side validation, the values offered in a dropdown editor, Plus Minus nudges and Smart Edit.
editOptions?: EditOptions<TData>;Property Value
EditOptions<TData>
entitlementOptions
Which modules a user may see or change. Full, ReadOnly or Hidden, per module or as a default.
A module that defaults to hidden (such as State) stays hidden until moduleEntitlements allows it.
entitlementOptions?: EntitlementOptions;Property Value
exportOptions
Reports: which system reports, formats and destinations are offered, custom destinations, and whether a column is included.
Report definitions the user creates are stored in Export state.
exportOptions?: ExportOptions<TData>;Property Value
ExportOptions<TData>
expressionOptions
AdapTableQL: custom functions, which columns and fields an expression may use, case sensitivity, and how the expression editor is presented.
Expressions saved on objects (a filter, an alert rule, a calculated column) live on those objects. These options change how every expression is evaluated and edited.
expressionOptions?: ExpressionOptions<TData>;Property Value
ExpressionOptions<TData>
fdc3Options
FDC3: which intents and contexts this grid raises, listens for and broadcasts, and how a row's columns map onto an FDC3 context.
fdc3Options?: Fdc3Options;Property Value
filterOptions
Column Filters and the Grid Filter: whether AdapTable's filters are used instead of AG Grid's, the quick filter bar, and the default operator for each data type.
The filters the user creates are stored in the Layout.
filterOptions?: FilterOptions<TData>;Property Value
FilterOptions<TData>
flashingCellOptions
Defaults for a flashing cell when a Flashing Cell definition does not set them: up, down and neutral styles, whether the cell or the row flashes, and for how long.
The definitions themselves belong in Initial State.
flashingCellOptions?: FlashingCellOptions;Property Value
formatColumnOptions
Display formatters beyond the ones AdapTable ships, used by Format Columns.
The Format Column objects (which column, which style and format) belong in Initial State.
formatColumnOptions?: FormatColumnOptions;Property Value
initialState
Objects shipped with the grid for its first run: at least one Layout, plus any Alerts, Format Columns, Calculated Columns and other module objects.
Applied only when no state is already stored for this grid. After that, the stored state is used and later edits to initialState are ignored until that stored state is cleared or the state key changes.
initialState: InitialState;Default Value
undefined
Property Value
layoutOptions
How Layouts are created and shown: a layout built from the AG Grid column definitions, defaults for a new Table or Pivot Layout, and whether layout extensions are offered in the UI.
The Layout objects belong in Initial State. A grid needs at least one.
layoutOptions?: LayoutOptions<TData>;Property Value
LayoutOptions<TData>
licenseKey
Commercial licence key.
Without a current licence, AdapTable shows licence notices and limits some functionality.
licenseKey?: string;Property Value
string
noteOptions
Notes on cells: which cells can hold a note, the note type applied on creation, and how the timestamp is formatted.
The notes themselves are stored in Note state.
noteOptions?: NoteOptions;Property Value
notificationsOptions
Toasts: where they appear, how long they stay, and how many system status messages are kept.
notificationsOptions?: NotificationsOptions;Property Value
plugins
Plugins constructed by the application and handed to AdapTable: OpenFin, ipushpull, interop.io and Master-Detail.
Each plugin is created with its own options. This array registers them.
plugins?: AdaptablePlugin[];Property Value
primaryKey
Column whose values uniquely identify a row. Required.
AdapTable uses it to find a row for edits, notes, comments, alerts, history and row forms. The values must be unique.
primaryKey: string;Default Value
n/a (Mandatory)
Property Value
string
quickSearchOptions
Quick Search: which cells are searched, whether matching rows are filtered, and whether the search is case sensitive.
quickSearchOptions?: QuickSearchOptions<TData>;Property Value
QuickSearchOptions<TData>
rowFormOptions
Create, clone and edit forms for a row: which columns appear, how the primary key of a new row is set, and whether AdapTable writes the result into the grid.
rowFormOptions?: RowFormOptions<TData>;Property Value
RowFormOptions<TData>
settingsPanelOptions
The Settings Panel: its title and icon, which modules appear and in which groups, and whether it opens as a modal or a movable window.
settingsPanelOptions?: SettingsPanelOptions;Property Value
stateOptions
Where state is loaded from and saved to. The default is localStorage.
Replace loadState and persistState to keep state on a server. saveState and applyState change the object just before it is stored or applied.
stateOptions?: StateOptions;Property Value
teamSharingOptions
Sharing Adaptable Objects with other users. The application loads and saves the shared objects; AdapTable does not ship a server.
Turn it on with enableTeamSharing, then provide loadSharedEntities and persistSharedEntities.
teamSharingOptions?: TeamSharingOptions;Property Value
toolPanelOptions
The tool panel beside the grid: custom panels, custom buttons, and whether the panel dropdown is shown.
toolPanelOptions?: ToolPanelOptions;Property Value
userInterfaceOptions
Shared UI: the application icon, custom icons, editable and read-only cell styles, the colour picker, date inputs, the loading screen, and the names shown for modules.
userInterfaceOptions?: UserInterfaceOptions<TData>;Property Value
UserInterfaceOptions<TData>
userName
Name of the person using this grid.
Stamped on Notes and Comments when the author is not supplied, and shown where Team Sharing records who shared an object.
userName?: string;Default Value
'anonymous'
Property Value
string
wizardOptions
Wizards and the other action popups (Bulk Update, Smart Edit, Cell Summary): modal or window, and the window's position and size.
Independent of the Settings Panel. Ignored when containerOptions.modalContainer places every popup in one element.
wizardOptions?: WizardOptions;