@adaptabletools/adaptable 13.0.0-canary.1 → 13.0.0-canary.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (179) hide show
  1. package/agGrid.d.ts +23 -1
  2. package/agGrid.js +23 -1
  3. package/base.css +1 -0
  4. package/bundle.cjs.js +169 -169
  5. package/index.css +1 -0
  6. package/package.json +3 -3
  7. package/publishTimestamp.d.ts +1 -1
  8. package/publishTimestamp.js +1 -1
  9. package/src/AdaptableInterfaces/IAdaptable.d.ts +8 -3
  10. package/src/AdaptableOptions/AdaptableOptions.d.ts +0 -2
  11. package/src/AdaptableOptions/AdaptableQLOptions.d.ts +118 -26
  12. package/src/AdaptableOptions/FinsemblePluginOptions.d.ts +32 -0
  13. package/src/AdaptableOptions/FinsemblePluginOptions.js +2 -0
  14. package/src/AdaptableOptions/GeneralOptions.d.ts +5 -0
  15. package/src/Api/ConditionalStyleApi.d.ts +20 -42
  16. package/src/Api/ConfigApi.d.ts +1 -2
  17. package/src/Api/FinsembleApi.d.ts +10 -0
  18. package/src/Api/FinsembleApi.js +2 -0
  19. package/src/Api/FormatColumnApi.d.ts +47 -3
  20. package/src/Api/Implementation/ColumnApiImpl.js +5 -7
  21. package/src/Api/Implementation/DashboardApiImpl.js +2 -3
  22. package/src/Api/Implementation/FormatColumnApiImpl.d.ts +18 -1
  23. package/src/Api/Implementation/FormatColumnApiImpl.js +98 -15
  24. package/src/Api/Implementation/InternalApiImpl.d.ts +1 -0
  25. package/src/Api/Implementation/InternalApiImpl.js +4 -0
  26. package/src/Api/Implementation/PluginsApiImpl.d.ts +2 -0
  27. package/src/Api/Implementation/PluginsApiImpl.js +6 -0
  28. package/src/Api/Implementation/QueryLanguageApiImpl.d.ts +2 -3
  29. package/src/Api/Implementation/QueryLanguageApiImpl.js +9 -18
  30. package/src/Api/Implementation/SystemStatusApiImpl.js +1 -2
  31. package/src/Api/Implementation/ToolPanelApiImpl.d.ts +3 -1
  32. package/src/Api/Implementation/ToolPanelApiImpl.js +8 -0
  33. package/src/Api/InternalApi.d.ts +1 -0
  34. package/src/Api/PluginsApi.d.ts +5 -0
  35. package/src/Api/QueryLanguageApi.d.ts +3 -7
  36. package/src/Api/ToolPanelApi.d.ts +10 -1
  37. package/src/PredefinedConfig/Common/AdaptablePredicate.d.ts +1 -1
  38. package/src/PredefinedConfig/Common/AdaptablePredicate.js +37 -37
  39. package/src/PredefinedConfig/ConditionalStyleState.d.ts +10 -19
  40. package/src/PredefinedConfig/FormatColumnState.d.ts +19 -6
  41. package/src/PredefinedConfig/PredefinedConfig.d.ts +1 -0
  42. package/src/Redux/ActionsReducers/FormatColumnRedux.d.ts +14 -0
  43. package/src/Redux/ActionsReducers/FormatColumnRedux.js +43 -1
  44. package/src/Redux/Store/AdaptableStore.js +2 -0
  45. package/src/Strategy/ConditionalStyleModule.d.ts +2 -0
  46. package/src/Strategy/ConditionalStyleModule.js +6 -0
  47. package/src/Strategy/DataChangeHistoryModule.d.ts +1 -0
  48. package/src/Strategy/DataChangeHistoryModule.js +12 -0
  49. package/src/Strategy/FormatColumnModule.d.ts +4 -9
  50. package/src/Strategy/FormatColumnModule.js +52 -2
  51. package/src/Strategy/Interface/IModule.d.ts +11 -10
  52. package/src/Strategy/Utilities/Alert/getAlertBehaviourViewItems.d.ts +2 -2
  53. package/src/Strategy/Utilities/FormatColumn/getFormatColumnSettingsViewItems.d.ts +1 -1
  54. package/src/Strategy/Utilities/FormatColumn/getFormatColumnSettingsViewItems.js +3 -4
  55. package/src/Utilities/Defaults/DefaultAdaptableOptions.js +6 -11
  56. package/src/Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions.d.ts +3 -2
  57. package/src/Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions.js +3 -1
  58. package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.d.ts +1 -0
  59. package/src/Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions.js +3 -1
  60. package/src/Utilities/ExpressionFunctions/booleanExpressionFunctions.d.ts +1 -0
  61. package/src/Utilities/ExpressionFunctions/booleanExpressionFunctions.js +3 -1
  62. package/src/Utilities/ExpressionFunctions/observableExpressionFunctions.d.ts +1 -0
  63. package/src/Utilities/ExpressionFunctions/observableExpressionFunctions.js +3 -1
  64. package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.d.ts +1 -0
  65. package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.js +3 -1
  66. package/src/Utilities/Extensions/TypeExtensions.d.ts +1 -0
  67. package/src/Utilities/Extensions/TypeExtensions.js +5 -0
  68. package/src/Utilities/ObjectFactory.js +0 -1
  69. package/src/Utilities/Services/Interface/IQueryLanguageService.d.ts +14 -4
  70. package/src/Utilities/Services/{LicenseService.d.ts → LicenseService/index.d.ts} +3 -3
  71. package/src/Utilities/Services/LicenseService/index.js +1 -0
  72. package/src/Utilities/Services/LicenseService/shouldLogThankYouMessage.d.ts +1 -0
  73. package/src/Utilities/Services/LicenseService/shouldLogThankYouMessage.js +15 -0
  74. package/src/Utilities/Services/QueryLanguageService.d.ts +3 -3
  75. package/src/Utilities/Services/QueryLanguageService.js +88 -39
  76. package/src/Utilities/license/LicenseDetails.d.ts +1 -1
  77. package/src/Utilities/license/decode.d.ts +1 -0
  78. package/src/Utilities/license/decode.js +1 -1
  79. package/src/View/AdaptablePopover/index.d.ts +2 -2
  80. package/src/View/AdaptableView.d.ts +3 -3
  81. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/Components/FormBox.d.ts +1 -1
  82. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.d.ts +1 -1
  83. package/src/View/AdaptableWizardView/index.d.ts +1 -1
  84. package/src/View/Alert/Wizard/BaseAlertRulesWizardSection.js +3 -3
  85. package/src/View/Alert/Wizard/BaseAlertScopeWizardSection.js +3 -3
  86. package/src/View/ColorPicker.d.ts +1 -5
  87. package/src/View/Components/AdaptableDateInput/index.d.ts +1 -1
  88. package/src/View/Components/Buttons/ButtonEdit.d.ts +1 -1
  89. package/src/View/Components/EntityRulesEditor/index.d.ts +2 -1
  90. package/src/View/Components/EntityRulesEditor/index.js +29 -19
  91. package/src/View/Components/NewScopeComponent.js +2 -2
  92. package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupBody.d.ts +1 -1
  93. package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupDialog.d.ts +2 -2
  94. package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupModuleView.d.ts +1 -1
  95. package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupModuleView.js +1 -0
  96. package/src/View/Components/Popups/AdaptablePopup/Navigation.d.ts +1 -1
  97. package/src/View/Components/Popups/AdaptablePopup/PopupPanel.d.ts +1 -1
  98. package/src/View/Components/Popups/AdaptablePopup/TopBar.d.ts +1 -1
  99. package/src/View/Components/Popups/AdaptablePopupPrompt.d.ts +1 -1
  100. package/src/View/Components/RangesComponent.d.ts +6 -0
  101. package/src/View/Components/RangesComponent.js +54 -18
  102. package/src/View/Components/ScopeComponent.js +2 -2
  103. package/src/View/Components/ToolPanel/AdaptableToolPanel.d.ts +4 -0
  104. package/src/View/Components/ToolPanel/AdaptableToolPanel.js +5 -2
  105. package/src/View/ConditionalStyle/ConditionalStylePopupHeader.d.ts +2 -0
  106. package/src/View/ConditionalStyle/ConditionalStylePopupHeader.js +18 -0
  107. package/src/View/ConditionalStyle/Wizard/ConditionalStyleRuleWizardSection.js +3 -3
  108. package/src/View/FlashingCell/Wizard/FlashingCellRulesWizardSection.js +3 -3
  109. package/src/View/FormatColumn/MoveFormatColumn.d.ts +7 -0
  110. package/src/View/FormatColumn/MoveFormatColumn.js +27 -0
  111. package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +2 -2
  112. package/src/View/FormatColumn/Wizard/FormatColumnRuleWizardSection.d.ts +8 -0
  113. package/src/View/FormatColumn/Wizard/FormatColumnRuleWizardSection.js +29 -0
  114. package/src/View/FormatColumn/Wizard/FormatColumnScopeWizardSection.js +21 -3
  115. package/src/View/FormatColumn/Wizard/FormatColumnSettingsWizardSection.js +0 -22
  116. package/src/View/FormatColumn/Wizard/FormatColumnStyleWizardSection.js +18 -4
  117. package/src/View/FormatColumn/Wizard/FormatColumnWizard.js +15 -2
  118. package/src/View/FormatColumn/Wizard/constants.d.ts +1 -0
  119. package/src/View/FormatColumn/Wizard/constants.js +4 -0
  120. package/src/View/Layout/Wizard/sections/AggregationsSection.js +1 -1
  121. package/src/View/Layout/Wizard/sections/SettingsSection.d.ts +2 -2
  122. package/src/View/License/LicenseWatermark.d.ts +1 -1
  123. package/src/View/PlusMinus/Wizard/PlusMinusRuleWizardSection.js +1 -1
  124. package/src/View/StateManagement/components/ClearButton.d.ts +1 -1
  125. package/src/View/StateManagement/components/LoadButton.d.ts +1 -1
  126. package/src/View/StatusBar/StatusBarPanel.d.ts +4 -4
  127. package/src/View/Wizard/OnePageAdaptableWizard.d.ts +3 -3
  128. package/src/View/Wizard/OnePageAdaptableWizard.js +2 -2
  129. package/src/View/Wizard/OnePageWizards.d.ts +3 -3
  130. package/src/View/Wizard/OnePageWizards.js +2 -2
  131. package/src/agGrid/ActionColumnRenderer.d.ts +1 -0
  132. package/src/agGrid/ActionColumnRenderer.js +5 -5
  133. package/src/agGrid/Adaptable.d.ts +16 -2
  134. package/src/agGrid/Adaptable.js +167 -85
  135. package/src/agGrid/FilterWrapper.js +5 -5
  136. package/src/agGrid/FloatingFilterWrapper.js +3 -4
  137. package/src/agGrid/agGridHelper.js +12 -13
  138. package/src/agGrid/createAgStatusPanelComponent.d.ts +1 -0
  139. package/src/agGrid/createAgStatusPanelComponent.js +3 -3
  140. package/src/agGrid/editors/AdaptableDateEditor/index.d.ts +1 -0
  141. package/src/agGrid/editors/AdaptableDateEditor/index.js +3 -3
  142. package/src/agGrid/editors/AdaptableNumberEditor/index.d.ts +1 -0
  143. package/src/agGrid/editors/AdaptableNumberEditor/index.js +3 -3
  144. package/src/components/CheckBox/index.d.ts +1 -1
  145. package/src/components/Datepicker/index.d.ts +1 -1
  146. package/src/components/Dialog/index.d.ts +4 -2
  147. package/src/components/Dialog/index.js +2 -2
  148. package/src/components/DropdownButton/index.d.ts +21 -4
  149. package/src/components/DropdownButton/index.js +5 -6
  150. package/src/components/ExpressionEditor/BaseEditorInput.d.ts +1 -1
  151. package/src/components/ExpressionEditor/EditorInput.js +1 -1
  152. package/src/components/ExpressionEditor/EditorInputWithWhereClause.js +1 -1
  153. package/src/components/Input/index.d.ts +1 -1
  154. package/src/components/List/ListGroupItem/index.d.ts +4 -2
  155. package/src/components/Loader/Loader.d.ts +2 -2
  156. package/src/components/Logo/index.d.ts +1 -1
  157. package/src/components/Modal/index.d.ts +1 -1
  158. package/src/components/PopupWithFooter.d.ts +2 -2
  159. package/src/components/ProgressIndicator/ProgressIndicator.d.ts +1 -1
  160. package/src/components/SelectList.d.ts +1 -1
  161. package/src/components/SimpleButton/index.d.ts +4 -5
  162. package/src/components/SimpleButton/index.js +3 -2
  163. package/src/components/StylePreview.d.ts +1 -1
  164. package/src/components/Tag/Tag.d.ts +1 -1
  165. package/src/components/Textarea/index.d.ts +6 -4
  166. package/src/components/ToggleButton/index.d.ts +1 -1
  167. package/src/components/WindowModal/WindowModal.d.ts +1 -1
  168. package/src/components/icons/index.d.ts +3 -2
  169. package/src/components/icons/layout.d.ts +2 -1
  170. package/src/components/utils/useContainerScrollObserver/index.d.ts +1 -1
  171. package/src/metamodel/adaptable.metamodel.d.ts +112 -64
  172. package/src/metamodel/adaptable.metamodel.js +1 -1
  173. package/src/parser/src/types.d.ts +6 -3
  174. package/src/renderReactRoot.d.ts +3 -0
  175. package/src/renderReactRoot.js +54 -0
  176. package/src/types.d.ts +4 -2
  177. package/version.d.ts +1 -1
  178. package/version.js +1 -1
  179. package/src/Utilities/Services/LicenseService.js +0 -1
package/index.css CHANGED
@@ -3733,6 +3733,7 @@ input[type='number'].ab-Input:hover::-webkit-inner-spin-button:active {
3733
3733
  display: table-cell; }
3734
3734
 
3735
3735
  .ab-ToggleButton {
3736
+ user-select: none;
3736
3737
  position: relative;
3737
3738
  display: inline-block;
3738
3739
  min-width: 40px;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adaptabletools/adaptable",
3
- "version": "13.0.0-canary.1",
3
+ "version": "13.0.0-canary.11",
4
4
  "description": "Powerful data-agnostic HTML5 datagrid add-on that sits on top of an underlying grid component and provides all the rich functionality that advanced users expect from their DataGrids and Data Tables",
5
5
  "keywords": [
6
6
  "web-components",
@@ -39,10 +39,10 @@
39
39
  "normalize.css": "^8.0.1",
40
40
  "prop-types": "^15.6.2",
41
41
  "re-resizable": "^6.9.1",
42
- "react": "^16.8.0 || ^17.0.0",
42
+ "react": "^16.8.0 || ^17.0.0 || ^18.0.0",
43
43
  "react-beautiful-dnd": "13.1.0",
44
44
  "react-day-picker": "8.0.6",
45
- "react-dom": "^16.8.0 || ^17.0.0",
45
+ "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0",
46
46
  "react-redux": "7.2.4",
47
47
  "react-remove-scroll": "2.4.2",
48
48
  "react-toastify": "9.0.7",
@@ -1,2 +1,2 @@
1
- declare const _default: 1663145371326;
1
+ declare const _default: 1663671135839;
2
2
  export default _default;
@@ -1,3 +1,3 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.default = 1663145371326;
3
+ exports.default = 1663671135839;
@@ -1,4 +1,4 @@
1
- import { ChartModel, ChartRef, Column, GridOptions, RowNode } from '@ag-grid-community/core';
1
+ import { ChartModel, ChartRef, Column, GridOptions, ModuleNames, RowNode } from '@ag-grid-community/core';
2
2
  import { AdaptableApi } from '../Api/AdaptableApi';
3
3
  import { AdaptableColumn } from '../PredefinedConfig/Common/AdaptableColumn';
4
4
  import { ColumnSort } from '../PredefinedConfig/Common/ColumnSort';
@@ -27,6 +27,7 @@ import { AdaptableFrameworkComponent } from '../AdaptableOptions/AdaptableFramew
27
27
  import { IMetamodelService } from '../Utilities/Services/Interface/IMetamodelService';
28
28
  import { ColumnValuesComparer } from '../AdaptableOptions/GeneralOptions';
29
29
  import { IRowEditService } from '../Utilities/Services/Interface/IRowEditService';
30
+ import { RenderReactRootFn } from '../renderReactRoot';
30
31
  /**
31
32
  * The only interface for Adaptable
32
33
  *
@@ -35,6 +36,8 @@ import { IRowEditService } from '../Utilities/Services/Interface/IRowEditService
35
36
  * Should only be used internally as all external access is via the Api
36
37
  */
37
38
  export interface IAdaptable {
39
+ supressReact18RenderWarning: boolean;
40
+ renderReactRoot: RenderReactRootFn;
38
41
  api: AdaptableApi;
39
42
  adaptableOptions: AdaptableOptions;
40
43
  adaptableStore: IAdaptableStore;
@@ -213,6 +216,8 @@ export interface IAdaptable {
213
216
  exportVisualDataToExcel(): void;
214
217
  canGenerateCharts(): boolean;
215
218
  canHaveSparklines(): boolean;
219
+ showCharts(charts: ChartModel[]): ChartRef[];
220
+ getChartModels(): ChartModel[];
216
221
  getCurrentIPPStyle(): IPPStyle;
217
222
  getDefaultIPPStyle(): IPPStyle;
218
223
  getRowCount(): number;
@@ -252,6 +257,6 @@ export interface IAdaptable {
252
257
  skipSetupColumns?: boolean;
253
258
  }): void;
254
259
  getAgGridColumnForColumnId(columnId: string): Column;
255
- showCharts(charts: ChartModel[]): ChartRef[];
256
- getChartModels(): ChartModel[];
260
+ isAgGridModulePresent(moduleName: ModuleNames): boolean;
261
+ getMinMaxCachedValueForColumn(column: AdaptableColumn, minMax: 'min' | 'max'): number | undefined;
257
262
  }
@@ -50,8 +50,6 @@ export interface AdaptableOptions {
50
50
  autogeneratePrimaryKey?: boolean;
51
51
  /**
52
52
  * The AG Grid object which AdapTable interacts with. Note: if using AdapTable React or AdapTable Angular, no need to populate this property as AdapTable wires it up differently
53
- *
54
- * @defaultValue n/a (Mandatory)
55
53
  */
56
54
  gridOptions?: GridOptions;
57
55
  /**
@@ -1,8 +1,13 @@
1
- import { ExpressionFunctionMap } from '../parser/src/types';
1
+ import { ExpressionFunction } from '../parser/src/types';
2
2
  import { AdaptablePredicateDef } from '../PredefinedConfig/Common/AdaptablePredicate';
3
3
  import { AdaptableModule, AdaptableQLModule, AdaptableQLModules } from '../PredefinedConfig/Common/Types';
4
4
  import { BaseContext } from '../PredefinedConfig/Common/BaseContext';
5
- import { AdaptableColumn } from '../PredefinedConfig/Common/AdaptableColumn';
5
+ import { AdaptableColumn, AdaptableColumnBase } from '../PredefinedConfig/Common/AdaptableColumn';
6
+ import { BooleanFunctionName } from '../Utilities/ExpressionFunctions/booleanExpressionFunctions';
7
+ import { ScalarFunctionName } from '../Utilities/ExpressionFunctions/scalarExpressionFunctions';
8
+ import { ObservableFunctionName } from '../Utilities/ExpressionFunctions/observableExpressionFunctions';
9
+ import { AggregatedBooleanFunctionName } from '../Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions';
10
+ import { AggregatedScalarFunctionName } from '../Utilities/ExpressionFunctions/aggregatedScalarExpressionFunctions';
6
11
  /**
7
12
  * Options for managing AdaptableQL - the Adaptable Query Language which evaluates Predicates and Expressions
8
13
  */
@@ -36,7 +41,7 @@ export interface AdaptableQLOptions {
36
41
  */
37
42
  customPredicateDefs?: AdaptablePredicateDef[];
38
43
  /**
39
- * Reference a Column's Header (Friendlyname) in all Expression overviews (instead of ColumnId)
44
+ * Reference a Column's Header (FriendlyName) in all Expression overviews (instead of ColumnId)
40
45
  *
41
46
  * @defaultValue true
42
47
  */
@@ -47,56 +52,66 @@ export interface AdaptableQLOptions {
47
52
  */
48
53
  export interface ExpressionOptions {
49
54
  /**
50
- * Boolean Expression Functions available in AdaptableQL
55
+ * System (built-in) Boolean Expression Functions available in AdaptableQL
51
56
  *
52
57
  * @defaultValue null (sets all)
53
58
  * @gridInfoItem
54
59
  */
55
- defaultBooleanFunctions?: ExpressionFunctionMap;
60
+ systemBooleanFunctions?: BooleanFunctionName[] | ((context: GlobalExpressionFunctionsContext<BooleanFunctionName>) => BooleanFunctionName[]);
56
61
  /**
57
- * Scalar Expression Functions available in AdaptableQL
62
+ * Custom (user defined) Boolean Expression Functions available in AdaptableQL
58
63
  *
59
- * @defaultValue null (sets all)
64
+ * @defaultValue null (none)
60
65
  * @gridInfoItem
61
66
  */
62
- defaultScalarFunctions?: ExpressionFunctionMap;
67
+ customBooleanFunctions?: Record<string, ExpressionFunction> | ((context: GlobalExpressionFunctionsContext<BooleanFunctionName>) => Record<string, ExpressionFunction>);
63
68
  /**
64
- * Observable Expression Functions available in AdaptableQL
69
+ * System (built-in) Scalar Expression Functions available in AdaptableQL
65
70
  *
66
71
  * @defaultValue null (sets all)
67
72
  * @gridInfoItem
68
73
  */
69
- defaultObservableFunctions?: ExpressionFunctionMap;
74
+ systemScalarFunctions?: ScalarFunctionName[] | ((context: GlobalExpressionFunctionsContext<ScalarFunctionName>) => ScalarFunctionName[]);
70
75
  /**
71
- * Aggregated Boolean Expression Functions available in AdaptableQL
76
+ * Custom (user defined) Scalar Expression Functions available in AdaptableQL
77
+ *
78
+ * @defaultValue null (none)
79
+ * @gridInfoItem
80
+ */
81
+ customScalarFunctions?: Record<string, ExpressionFunction> | ((context: GlobalExpressionFunctionsContext<ScalarFunctionName>) => Record<string, ExpressionFunction>);
82
+ /**
83
+ * System (built-in) Observable Expression Functions available in AdaptableQL
72
84
  *
73
85
  * @defaultValue null (sets all)
74
86
  * @gridInfoItem
75
87
  */
76
- defaultAggregatedBooleanFunctions?: ExpressionFunctionMap;
88
+ systemObservableFunctions?: ObservableFunctionName[] | ((context: GlobalExpressionFunctionsContext<ObservableFunctionName>) => ObservableFunctionName[]);
77
89
  /**
78
- * Aggregated Scalar Expression Functions available in AdaptableQL
90
+ * System (built-in) AggregatedBoolean Expression Functions available in AdaptableQL
79
91
  *
80
92
  * @defaultValue null (sets all)
81
93
  * @gridInfoItem
82
94
  */
83
- defaultAggregatedScalarFunctions?: ExpressionFunctionMap;
95
+ systemAggregatedBooleanFunctions?: AggregatedBooleanFunctionName[] | ((context: GlobalExpressionFunctionsContext<AggregatedBooleanFunctionName>) => AggregatedBooleanFunctionName[]);
84
96
  /**
85
- * Module specific ExpressionFunctions; if not defined, it falls back to the defined default values
97
+ * System (built-in) AggregatedScalar Expression Functions available in AdaptableQL
86
98
  *
87
- * @defaultValue undefined (defaults to default values)
99
+ * @defaultValue undefined (sets all)
88
100
  * @gridInfoItem
89
101
  */
90
- moduleExpressionFunctions?: {
91
- [module in AdaptableModule]?: ModuleExpressionFunctions;
92
- };
102
+ systemAggregatedScalarFunctions?: AggregatedScalarFunctionName[] | ((context: GlobalExpressionFunctionsContext<AggregatedScalarFunctionName>) => AggregatedScalarFunctionName[]);
93
103
  /**
94
- * Columns that can be included in AdaptableQL Expressions; leave unset to include **ALL**, provide empty array to set **NONE**
104
+ * Module specific ExpressionFunctions; if not defined, it falls back to the generally defined system and custom values
95
105
  *
96
- * @defaultValue undefined
106
+ * @defaultValue undefined (defaults to available system & custom values)
97
107
  * @gridInfoItem
98
108
  */
109
+ moduleExpressionFunctions?: ModuleExpressionFunctionsMap | ((context: ModuleExpressionFunctionsContext) => ModuleExpressionFunctions | undefined);
110
+ /**
111
+ * Deprecated use `isColumnQueryable` instead
112
+ */
99
113
  queryableColumns?: string[] | (() => string[]);
114
+ isColumnQueryable?: (queryableColumnContext: QueryableColumnContext) => boolean;
100
115
  /**
101
116
  * Validate Expressions before they can be run or saved
102
117
  *
@@ -119,12 +134,80 @@ export interface ExpressionOptions {
119
134
  /**
120
135
  * Module specific Expression Functions
121
136
  */
137
+ export declare type ModuleExpressionFunctionsMap = Partial<Record<AdaptableModule, ModuleExpressionFunctions>>;
138
+ /**
139
+ * Type specific Expression Functions
140
+ */
122
141
  export interface ModuleExpressionFunctions {
123
- booleanFunctions?: ExpressionFunctionMap;
124
- scalarFunctions?: ExpressionFunctionMap;
125
- observableFunctions?: ExpressionFunctionMap;
126
- aggregatedBooleanFunctions?: ExpressionFunctionMap;
127
- aggregatedScalarFunctions?: ExpressionFunctionMap;
142
+ /**
143
+ * System (built-in) Boolean Expression Functions available in AdaptableQL
144
+ *
145
+ * @defaultValue null (sets all)
146
+ * @gridInfoItem
147
+ */
148
+ systemBooleanFunctions?: BooleanFunctionName[] | ((context: GlobalExpressionFunctionsContext<BooleanFunctionName>) => BooleanFunctionName[]);
149
+ /**
150
+ * Custom (user defined) Boolean Expression Functions available in AdaptableQL
151
+ *
152
+ * @defaultValue null (none)
153
+ * @gridInfoItem
154
+ */
155
+ customBooleanFunctions?: Record<string, ExpressionFunction> | ((context: GlobalExpressionFunctionsContext<BooleanFunctionName>) => Record<string, ExpressionFunction>);
156
+ /**
157
+ * System (built-in) Scalar Expression Functions available in AdaptableQL
158
+ *
159
+ * @defaultValue null (sets all)
160
+ * @gridInfoItem
161
+ */
162
+ systemScalarFunctions?: ScalarFunctionName[] | ((context: GlobalExpressionFunctionsContext<ScalarFunctionName>) => ScalarFunctionName[]);
163
+ /**
164
+ * Custom (user defined) Scalar Expression Functions available in AdaptableQL
165
+ *
166
+ * @defaultValue null (none)
167
+ * @gridInfoItem
168
+ */
169
+ customScalarFunctions?: Record<string, ExpressionFunction> | ((context: GlobalExpressionFunctionsContext<ScalarFunctionName>) => Record<string, ExpressionFunction>);
170
+ /**
171
+ * System (built-in) Observable Expression Functions available in AdaptableQL
172
+ *
173
+ * @defaultValue null (sets all)
174
+ * @gridInfoItem
175
+ */
176
+ systemObservableFunctions?: ObservableFunctionName[] | ((context: GlobalExpressionFunctionsContext<ObservableFunctionName>) => ObservableFunctionName[]);
177
+ /**
178
+ * System (built-in) AggregatedBoolean Expression Functions available in AdaptableQL
179
+ *
180
+ * @defaultValue null (sets all)
181
+ * @gridInfoItem
182
+ */
183
+ systemAggregatedBooleanFunctions?: AggregatedBooleanFunctionName[] | ((context: GlobalExpressionFunctionsContext<AggregatedBooleanFunctionName>) => AggregatedBooleanFunctionName[]);
184
+ /**
185
+ * System (built-in) AggregatedScalar Expression Functions available in AdaptableQL
186
+ *
187
+ * @defaultValue null (sets all)
188
+ * @gridInfoItem
189
+ */
190
+ systemAggregatedScalarFunctions?: AggregatedScalarFunctionName[] | ((context: GlobalExpressionFunctionsContext<AggregatedScalarFunctionName>) => AggregatedScalarFunctionName[]);
191
+ }
192
+ /**
193
+ * Context provided to global expression functions properties property callback
194
+ */
195
+ export interface GlobalExpressionFunctionsContext<T> extends BaseContext {
196
+ /**
197
+ * The names of all expression functions available in this context
198
+ */
199
+ availableExpressionFunctionNames: T[];
200
+ }
201
+ /**
202
+ * Context provided to ExpressionOptions.moduleExpressionFunctions property callback
203
+ */
204
+ export interface ModuleExpressionFunctionsContext extends BaseContext {
205
+ module: AdaptableModule;
206
+ availableBooleanFunctionNames: BooleanFunctionName[];
207
+ availableScalarFunctionNames: ScalarFunctionName[];
208
+ availableObservableFunctionNames: ObservableFunctionName[];
209
+ availableAggregatedBooleanFunctionNames: AggregatedBooleanFunctionName[];
210
+ availableAggregatedScalarFunctionNames: AggregatedScalarFunctionName[];
128
211
  }
129
212
  /**
130
213
  * Context passed when evaluating `ExpressionOptions.customQueryVariables`
@@ -152,3 +235,12 @@ export interface EvaluateExpressionExternallyContext extends BaseContext {
152
235
  */
153
236
  referencedColumns?: AdaptableColumn[];
154
237
  }
238
+ /**
239
+ * Context passed when evaluating Queryable Columns
240
+ */
241
+ export interface QueryableColumnContext extends BaseContext {
242
+ /**
243
+ * Column - just Id, DataType and FriendlyName
244
+ */
245
+ adaptableColumn: AdaptableColumnBase;
246
+ }
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Options required for when using the Finsemble plugin
3
+ */
4
+ export interface FinsemblePluginOptions {
5
+ /**
6
+ * Application name - used to identify the application in Finsemble console
7
+ */
8
+ applicationName?: string;
9
+ /**
10
+ * Options for managing Adaptable State with Finsemble State
11
+ */
12
+ stateOptions?: FinsemblePluginStateOptions;
13
+ /**
14
+ * Should Adaptable's Alerts appear as Finsemble Notifications
15
+ * @defaultValue true
16
+ */
17
+ showAdaptableAlertsAsNotifications?: boolean;
18
+ }
19
+ export interface FinsemblePluginStateOptions {
20
+ /**
21
+ * Whether to persist AdapTable State inside Finsemble
22
+ */
23
+ persistInFinsemble: boolean;
24
+ /**
25
+ * Key used to persist/load AdapTable State in Finsemble
26
+ */
27
+ key: string;
28
+ /**
29
+ * Topic used to persist/load AdapTable State in Finsemble
30
+ */
31
+ topic: string;
32
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -65,6 +65,11 @@ export interface GeneralOptions {
65
65
  * Value to use for 'Unbalanced Groups' (string columns)
66
66
  */
67
67
  unbalancedGroupsKey?: string | ((context: UnbalancedGroupsKeyContext) => string);
68
+ /**
69
+ * Specifies whether Conditional Styles (deprecated in v13) will be auto-merged into Format Columns
70
+ * @defaultValue false
71
+ */
72
+ keepDeprecatedConditionalStyles?: boolean;
68
73
  }
69
74
  /**
70
75
  * Comparer object for Column Values - used for custom sorting
@@ -2,107 +2,85 @@ import { ConditionalStyleState, ConditionalStyle } from '../PredefinedConfig/Con
2
2
  import { AdaptableColumn, AdaptableScope } from '../types';
3
3
  import { AdaptablePredicateDef } from '../PredefinedConfig/Common/AdaptablePredicate';
4
4
  /**
5
- * Provides run-time access to Conditional Style Module and state
5
+ * Deprecated API section - use `FormatColumnAPI` instead
6
6
  */
7
7
  export interface ConditionalStyleApi {
8
8
  /**
9
- * Retrieves Conditional Style section from Adaptable State
9
+ * @deprecated use `FormatColumnָAPI` instead
10
10
  */
11
11
  getConditionalStyleState(): ConditionalStyleState;
12
12
  /**
13
- * Gets all Conditional Styles in Adaptable State
13
+ * @deprecated use `FormatColumnָAPI` instead
14
14
  */
15
15
  getAllConditionalStyle(config?: {
16
16
  includeLayoutNotAssociatedObjects?: boolean;
17
17
  }): ConditionalStyle[];
18
18
  /**
19
- * Get conditional style by id
20
- * @param id conditional style id
21
- * @returns conditional style
19
+ * @deprecated use `FormatColumnָAPI` instead
22
20
  */
23
21
  getConditionalStyleById(id: ConditionalStyle['Uuid']): ConditionalStyle;
24
22
  /**
25
- * Gets all Conditional Styles that are active (not-suspended) in Adaptable State
26
- * @returns conditional styles
23
+ * @deprecated use `FormatColumnָAPI` instead
27
24
  */
28
25
  getAllActiveConditionalStyle(): ConditionalStyle[];
29
26
  /**
30
- * Gets all Conditional Styles that are suspended in Adaptable State
31
- * @returns conditional styles
27
+ * @deprecated use `FormatColumnָAPI` instead
32
28
  */
33
29
  getAllSuspendedConditionalStyle(): ConditionalStyle[];
34
30
  /**
35
- * Opens Settings Panel with Conditional Style section selected and visible
31
+ * @deprecated use `FormatColumnָAPI` instead
36
32
  */
37
33
  showConditionalStylePopup(): void;
38
34
  /**
39
- * Retrieves all Conditional Styles that style whole row
40
- * @returns conditional styles
35
+ * @deprecated use `FormatColumnָAPI` instead
41
36
  */
42
37
  getRowConditionalStyles(): ConditionalStyle[] | undefined;
43
38
  /**
44
- * Retrieves all Conditional Styles which have an Expression
45
- * @returns conditional styles
39
+ * @deprecated use `FormatColumnָAPI` instead
46
40
  */
47
41
  getConditionalStylesWithExpression(): ConditionalStyle[] | undefined;
48
42
  /**
49
- * Gets all Conditional Styles that style a given Column
50
- * @param column Column to check
51
- * @returns conditional styles
43
+ * @deprecated use `FormatColumnָAPI` instead
52
44
  */
53
45
  getConditionalStylesForColumn(column: AdaptableColumn): ConditionalStyle[] | undefined;
54
46
  /**
55
- * Returns all Predicates usable in Conditional Styles
47
+ * @deprecated use `FormatColumnָAPI` instead
56
48
  */
57
49
  getConditionalStylePredicateDefs(): AdaptablePredicateDef[];
58
50
  /**
59
- * Returns all Predicates appropriate for the given Scope
60
- * @param scope Scope to check
51
+ * @deprecated use `FormatColumnָAPI` instead
61
52
  */
62
53
  getCondStylePredicateDefsForScope(scope: AdaptableScope): AdaptablePredicateDef[];
63
54
  /**
64
- * Retrieves all Conditional Styles ordered by Column then Row
65
- * @returns conditional style
55
+ * @deprecated use `FormatColumnָAPI` instead
66
56
  */
67
57
  getOrderedConditionalStyles(): ConditionalStyle[] | undefined;
68
58
  /**
69
- * Replaces Conditional Style in State with given one
70
- * @param conditionalStyle Conditional Style to edit
71
- * @returns conditional style
59
+ * @deprecated use `FormatColumnָAPI` instead
72
60
  */
73
61
  editConditionalStyle(conditionalStyle: ConditionalStyle): ConditionalStyle;
74
62
  /**
75
- * Replaces Conditional Styles in State with given ones
76
- * @param conditionalStyles Conditional Styles to edit
77
- * @returns conditional styles
63
+ * @deprecated use `FormatColumnָAPI` instead
78
64
  */
79
65
  editConditionalStyles(conditionalStyles: ConditionalStyle[]): ConditionalStyle[];
80
66
  /**
81
- * Deletes a Conditional Style
82
- * @param conditionalStyle Conditional Style to delete
67
+ * @deprecated use `FormatColumnָAPI` instead
83
68
  */
84
69
  deleteConditionalStyle(conditionalStyle: ConditionalStyle): void;
85
70
  /**
86
- * Deletes Conditional Styles
87
- * @param conditionalStyles Conditional Styles to delete
71
+ * @deprecated use `FormatColumnָAPI` instead
88
72
  */
89
73
  deleteConditionalStyles(conditionalStyles: ConditionalStyle[]): void;
90
74
  /**
91
- * Adds new Conditional Style to State
92
- * @param conditionalStyle Conditional Style to add
93
- * @returns conditional style
75
+ * @deprecated use `FormatColumnָAPI` instead
94
76
  */
95
77
  addConditionalStyle(conditionalStyle: ConditionalStyle): ConditionalStyle;
96
78
  /**
97
- * Suspends conditional style, a readonly object cannot be suspended
98
- * @param conditionalStyle Conditional Style to suspend
99
- * @returns conditional style
79
+ * @deprecated use `FormatColumnָAPI` instead
100
80
  */
101
81
  suspendConditionalStyle(conditionalStyle: ConditionalStyle): ConditionalStyle;
102
82
  /**
103
- * Un-suspends or activates a suspended conditional style
104
- * @param conditionalStyle Conditional Style to suspend
105
- * @returns conditional style
83
+ * @deprecated use `FormatColumnָAPI` instead
106
84
  */
107
85
  unSuspendConditionalStyle(conditionalStyle: ConditionalStyle): ConditionalStyle;
108
86
  }
@@ -116,8 +116,7 @@ export interface ConfigApi {
116
116
  */
117
117
  getCalculatedColumnState(returnJson: boolean): CalculatedColumnState;
118
118
  /**
119
- * Returns Conditional Style section of Adaptable State
120
- * @param returnJson return as JSON rather than object
119
+ * @deprecated use `getFormatColumnState` instead
121
120
  */
122
121
  getConditionalStyleState(returnJson: boolean): ConditionalStyleState;
123
122
  /**
@@ -0,0 +1,10 @@
1
+ import { FinsemblePluginOptions } from '../AdaptableOptions/FinsemblePluginOptions';
2
+ /**
3
+ * Provides run-time access to the Finsemble Plugin
4
+ */
5
+ export interface FinsembleApi {
6
+ /**
7
+ * Retrieves the FinsemblePlugOptions provided in Finsemble Plugin
8
+ */
9
+ getPluginOptions(): FinsemblePluginOptions;
10
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,5 +1,5 @@
1
1
  import { FormatColumnState, FormatColumn, ColumnStyle, ColumnComparison, CellColorRange } from '../PredefinedConfig/FormatColumnState';
2
- import { AdaptableColumn, AdaptableFormat } from '../types';
2
+ import { AdaptableColumn, AdaptableFormat, AdaptablePredicateDef, AdaptableScope } from '../types';
3
3
  import { RowNode } from '@ag-grid-community/core';
4
4
  /**
5
5
  * Provides run-time access to the Format Column Module and associated state
@@ -134,12 +134,22 @@ export interface FormatColumnApi {
134
134
  * @returns format column
135
135
  */
136
136
  getFormatColumnWithStyleForColumn(column: AdaptableColumn): FormatColumn | undefined;
137
+ /**
138
+ * Retrieves all format columns with style for a column
139
+ * @param column The Column for which to retrieve the Format Column
140
+ */
141
+ getColumnFormatColumnsWithStyle(column: AdaptableColumn): FormatColumn[];
142
+ /**
143
+ * Retrieves all Format Columns with style for the whole row
144
+ * @returns format columns
145
+ */
146
+ getRowFormatColumnsWithStyle(): FormatColumn[];
137
147
  /**
138
148
  * Gets Format Column if any for given Column which includes Style element with ClassName
139
149
  * @param column The Column for which to retrieve the Format Column
140
- * @returns format column
150
+ * @returns format columns
141
151
  */
142
- getFormatColumnWithStyleClassNameForColumn(column: AdaptableColumn): FormatColumn | undefined;
152
+ getFormatColumnWithStyleClassNameForColumn(column: AdaptableColumn): FormatColumn[];
143
153
  /**
144
154
  * Will get the most appropriate one i.e. first named Column, then DataType, then All
145
155
  * @param column
@@ -206,4 +216,38 @@ export interface FormatColumnApi {
206
216
  * @param formatColumn Format Column
207
217
  */
208
218
  hasCustomDisplayFormatter(formatColumn: FormatColumn): boolean;
219
+ /**
220
+ * Returns all Predicates usable in Format Columns
221
+ */
222
+ getFormatColumnPredicateDefs(): AdaptablePredicateDef[];
223
+ /**
224
+ * Returns all Predicates appropriate for the given Scope
225
+ * @param scope Scope to check
226
+ */
227
+ getFormatColumnDefsForScope(scope: AdaptableScope): AdaptablePredicateDef[];
228
+ /**
229
+ * Checks if format column is active for a given row
230
+ *
231
+ * @param formatColumn
232
+ * @param params
233
+ */
234
+ isFormatColumnActiveForRow(formatColumn: FormatColumn, params: {
235
+ node: RowNode;
236
+ }): boolean;
237
+ /**
238
+ * Checks if format column is active for a given cell
239
+ *
240
+ * @param formatColumn
241
+ * @param column
242
+ * @param params
243
+ */
244
+ isFormatColumnActiveForColumn(formatColumn: FormatColumn, column: AdaptableColumn, params: {
245
+ node: RowNode;
246
+ value: any;
247
+ }): boolean;
248
+ /**
249
+ * Retrieves all Format Columns which have an Expression
250
+ * @returns Format Columns with Expression
251
+ */
252
+ getFormatColumnsWithExpression(): FormatColumn[] | undefined;
209
253
  }
@@ -89,13 +89,13 @@ class ColumnApiImpl extends ApiBase_1.ApiBase {
89
89
  return false;
90
90
  }
91
91
  isNumericColumn(column) {
92
- return column.dataType == 'Number';
92
+ return (column === null || column === void 0 ? void 0 : column.dataType) == 'Number';
93
93
  }
94
94
  isBooleanColumn(column) {
95
- return column.dataType == 'Boolean';
95
+ return (column === null || column === void 0 ? void 0 : column.dataType) == 'Boolean';
96
96
  }
97
97
  isDateColumn(column) {
98
- return column.dataType == 'Date';
98
+ return (column === null || column === void 0 ? void 0 : column.dataType) == 'Date';
99
99
  }
100
100
  getColumnDataTypeFromColumnId(columnId) {
101
101
  const column = this.getColumnFromId(columnId); // this.getColumns().find(c => c.ColumnId == columnId);
@@ -424,15 +424,13 @@ class ColumnApiImpl extends ApiBase_1.ApiBase {
424
424
  if (column.dataType !== 'Number') {
425
425
  return undefined;
426
426
  }
427
- // can we cache this in some way?
428
- return Math.min(...this.getDistinctRawValuesForColumn(column.columnId));
427
+ return this.adaptable.getMinMaxCachedValueForColumn(column, 'min');
429
428
  }
430
429
  getMaxValueForNumericColumn(column) {
431
430
  if (column.dataType !== 'Number') {
432
431
  return undefined;
433
432
  }
434
- // can we cache this in some way?
435
- return Math.max(...this.getDistinctRawValuesForColumn(column.columnId));
433
+ return this.adaptable.getMinMaxCachedValueForColumn(column, 'max');
436
434
  }
437
435
  getTypesForColumn(columnId) {
438
436
  var _a;
@@ -6,8 +6,7 @@ const DashboardRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers
6
6
  const ApiBase_1 = require("./ApiBase");
7
7
  const ModuleConstants = tslib_1.__importStar(require("../../Utilities/Constants/ModuleConstants"));
8
8
  const isEqual_1 = tslib_1.__importDefault(require("lodash/isEqual"));
9
- const react_dom_1 = tslib_1.__importDefault(require("react-dom"));
10
- const react_1 = tslib_1.__importDefault(require("react"));
9
+ const React = tslib_1.__importStar(require("react"));
11
10
  const SystemRedux_1 = require("../../Redux/ActionsReducers/SystemRedux");
12
11
  class DashboardApiImpl extends ApiBase_1.ApiBase {
13
12
  constructor() {
@@ -63,7 +62,7 @@ class DashboardApiImpl extends ApiBase_1.ApiBase {
63
62
  setCustomToolbarContents(customToolbarName, contents) {
64
63
  let contentsDiv = this.getCustomToolbarContentsDiv(customToolbarName);
65
64
  if (contentsDiv) {
66
- react_dom_1.default.render(react_1.default.createElement("div", { dangerouslySetInnerHTML: { __html: contents } }), contentsDiv);
65
+ this.adaptable.renderReactRoot(React.createElement("div", { dangerouslySetInnerHTML: { __html: contents } }), contentsDiv);
67
66
  }
68
67
  }
69
68
  getCustomToolbarByName(customToolbarName) {