@adaptabletools/adaptable 11.2.4-canary.0 → 12.0.0-canary.0

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 (266) hide show
  1. package/base.css +22 -4
  2. package/bundle.cjs.js +111 -111
  3. package/index.css +26 -4
  4. package/package.json +1 -1
  5. package/publishTimestamp.d.ts +1 -1
  6. package/publishTimestamp.js +1 -1
  7. package/src/AdaptableInterfaces/IAdaptable.d.ts +6 -1
  8. package/src/AdaptableOptions/ActionOptions.d.ts +1 -0
  9. package/src/AdaptableOptions/{MasterDetailAgGridPluginOptions.js → ActionOptions.js} +0 -0
  10. package/src/AdaptableOptions/AdaptableFrameworkComponent.d.ts +5 -0
  11. package/src/AdaptableOptions/AdaptableOptions.d.ts +3 -3
  12. package/src/AdaptableOptions/AdaptableQLOptions.d.ts +5 -0
  13. package/src/AdaptableOptions/AlertOptions.d.ts +14 -1
  14. package/src/AdaptableOptions/ColumnOptions.d.ts +49 -0
  15. package/src/AdaptableOptions/{SmartEdit.js → ColumnOptions.js} +0 -0
  16. package/src/AdaptableOptions/DashboardOptions.d.ts +2 -7
  17. package/src/AdaptableOptions/DataChangeHistoryOptions.d.ts +19 -0
  18. package/src/AdaptableOptions/EditOptions.d.ts +92 -4
  19. package/src/AdaptableOptions/EntitlementOptions.d.ts +7 -1
  20. package/src/AdaptableOptions/ExportOptions.d.ts +5 -1
  21. package/src/AdaptableOptions/FilterOptions.d.ts +6 -1
  22. package/src/AdaptableOptions/FinancePluginOptions.d.ts +33 -3
  23. package/src/AdaptableOptions/GeneralOptions.d.ts +22 -23
  24. package/src/AdaptableOptions/{MasterDetailAgGridPluginOptions.d.ts → MasterDetailPluginOptions.d.ts} +2 -4
  25. package/src/{Api/DataSourceApi.js → AdaptableOptions/MasterDetailPluginOptions.js} +0 -0
  26. package/src/AdaptableOptions/SettingsPanelOptions.d.ts +3 -6
  27. package/src/AdaptableOptions/ToolPanelOptions.d.ts +2 -49
  28. package/src/AdaptableOptions/UserInterfaceOptions.d.ts +81 -54
  29. package/src/Api/AdaptableApi.d.ts +6 -3
  30. package/src/Api/ColumnApi.d.ts +6 -3
  31. package/src/Api/ConditionalStyleApi.d.ts +10 -0
  32. package/src/Api/ConfigApi.d.ts +0 -12
  33. package/src/Api/DashboardApi.d.ts +6 -19
  34. package/src/Api/DataSetApi.d.ts +40 -0
  35. package/src/{PredefinedConfig/DataSourceState.js → Api/DataSetApi.js} +0 -0
  36. package/src/Api/EventApi.d.ts +18 -1
  37. package/src/Api/Events/DataSetChanged.d.ts +5 -0
  38. package/src/{PredefinedConfig/FilterState.js → Api/Events/DataSetChanged.js} +0 -0
  39. package/src/Api/Events/RowFormSubmitted.d.ts +19 -0
  40. package/src/Api/Events/RowFormSubmitted.js +2 -0
  41. package/src/Api/Events/SearchChanged.d.ts +3 -4
  42. package/src/Api/FilterApi.d.ts +1 -77
  43. package/src/Api/FinanceApi.d.ts +3 -2
  44. package/src/Api/FormatColumnApi.d.ts +28 -1
  45. package/src/Api/GridApi.d.ts +15 -1
  46. package/src/Api/Implementation/AdaptableApiImpl.d.ts +2 -2
  47. package/src/Api/Implementation/AdaptableApiImpl.js +3 -3
  48. package/src/Api/Implementation/AlertApiImpl.js +5 -1
  49. package/src/Api/Implementation/ApiBase.d.ts +3 -0
  50. package/src/Api/Implementation/ApiBase.js +6 -0
  51. package/src/Api/Implementation/ColumnApiImpl.d.ts +2 -2
  52. package/src/Api/Implementation/ColumnApiImpl.js +6 -3
  53. package/src/Api/Implementation/ConditionalStyleApiImpl.d.ts +2 -0
  54. package/src/Api/Implementation/ConditionalStyleApiImpl.js +8 -0
  55. package/src/Api/Implementation/ConfigApiImpl.d.ts +0 -4
  56. package/src/Api/Implementation/ConfigApiImpl.js +2 -24
  57. package/src/Api/Implementation/DashboardApiImpl.d.ts +3 -6
  58. package/src/Api/Implementation/DashboardApiImpl.js +5 -29
  59. package/src/Api/Implementation/DataSetApiImpl.d.ts +12 -0
  60. package/src/Api/Implementation/DataSetApiImpl.js +42 -0
  61. package/src/Api/Implementation/EventApiImpl.js +1 -0
  62. package/src/Api/Implementation/FilterApiImpl.d.ts +1 -16
  63. package/src/Api/Implementation/FilterApiImpl.js +5 -164
  64. package/src/Api/Implementation/FormatColumnApiImpl.d.ts +6 -0
  65. package/src/Api/Implementation/FormatColumnApiImpl.js +34 -0
  66. package/src/Api/Implementation/GridApiImpl.d.ts +4 -1
  67. package/src/Api/Implementation/GridApiImpl.js +41 -1
  68. package/src/Api/Implementation/InternalApiImpl.d.ts +7 -2
  69. package/src/Api/Implementation/InternalApiImpl.js +51 -10
  70. package/src/Api/Implementation/LayoutApiImpl.d.ts +18 -1
  71. package/src/Api/Implementation/LayoutApiImpl.js +172 -0
  72. package/src/Api/Implementation/PredicateApiImpl.js +1 -1
  73. package/src/Api/Implementation/SmartEditApiImpl.d.ts +5 -2
  74. package/src/Api/Implementation/SmartEditApiImpl.js +9 -0
  75. package/src/Api/Implementation/TeamSharingApiImpl.d.ts +5 -3
  76. package/src/Api/Implementation/TeamSharingApiImpl.js +28 -10
  77. package/src/Api/Implementation/UserInterfaceApiImpl.d.ts +1 -1
  78. package/src/Api/Implementation/UserInterfaceApiImpl.js +7 -25
  79. package/src/Api/InternalApi.d.ts +6 -2
  80. package/src/Api/LayoutApi.d.ts +88 -1
  81. package/src/Api/SmartEditApi.d.ts +14 -3
  82. package/src/Api/TeamSharingApi.d.ts +18 -5
  83. package/src/Api/UserInterfaceApi.d.ts +4 -4
  84. package/src/PredefinedConfig/AdaptableState.d.ts +0 -4
  85. package/src/PredefinedConfig/CalculatedColumnState.d.ts +5 -0
  86. package/src/PredefinedConfig/Common/AdaptableButton.d.ts +3 -3
  87. package/src/PredefinedConfig/Common/AdaptableColumn.d.ts +5 -1
  88. package/src/PredefinedConfig/Common/AdaptableForm.d.ts +3 -2
  89. package/src/PredefinedConfig/Common/AdaptableFormat.d.ts +6 -3
  90. package/src/PredefinedConfig/Common/AdaptableObject.d.ts +2 -11
  91. package/src/PredefinedConfig/Common/AdaptablePredicate.js +35 -2
  92. package/src/PredefinedConfig/Common/BaseContext.d.ts +1 -1
  93. package/src/PredefinedConfig/{FilterState.d.ts → Common/ColumnFilter.d.ts} +2 -33
  94. package/src/PredefinedConfig/Common/ColumnFilter.js +2 -0
  95. package/src/PredefinedConfig/Common/Enums.d.ts +2 -2
  96. package/src/PredefinedConfig/Common/Enums.js +1 -1
  97. package/src/PredefinedConfig/Common/FDC3Context.d.ts +5 -1
  98. package/src/PredefinedConfig/Common/Types.d.ts +6 -5
  99. package/src/PredefinedConfig/Common/Types.js +2 -3
  100. package/src/PredefinedConfig/LayoutState.d.ts +5 -0
  101. package/src/PredefinedConfig/PredefinedConfig.d.ts +0 -10
  102. package/src/PredefinedConfig/StatusBarState.d.ts +1 -2
  103. package/src/PredefinedConfig/SystemState.d.ts +4 -2
  104. package/src/Redux/ActionsReducers/LayoutRedux.d.ts +47 -0
  105. package/src/Redux/ActionsReducers/LayoutRedux.js +135 -1
  106. package/src/Redux/ActionsReducers/SystemRedux.d.ts +23 -1
  107. package/src/Redux/ActionsReducers/SystemRedux.js +39 -1
  108. package/src/Redux/Store/AdaptableStore.js +37 -39
  109. package/src/Strategy/AlertModule.d.ts +11 -0
  110. package/src/Strategy/AlertModule.js +14 -0
  111. package/src/Strategy/CellSummaryModule.d.ts +3 -0
  112. package/src/Strategy/CellSummaryModule.js +28 -14
  113. package/src/Strategy/DataSetModule.d.ts +25 -0
  114. package/src/Strategy/DataSetModule.js +65 -0
  115. package/src/Strategy/ExportModule.js +6 -1
  116. package/src/Strategy/FilterModule.d.ts +7 -11
  117. package/src/Strategy/FilterModule.js +24 -15
  118. package/src/Strategy/FlashingCellModule.d.ts +1 -1
  119. package/src/Strategy/FlashingCellModule.js +2 -2
  120. package/src/Strategy/FormatColumnModule.js +1 -1
  121. package/src/Strategy/Interface/IModule.d.ts +3 -1
  122. package/src/Strategy/LayoutModule.js +24 -2
  123. package/src/Strategy/SmartEditModule.d.ts +1 -1
  124. package/src/Strategy/SmartEditModule.js +5 -6
  125. package/src/Strategy/StatusBarModule.js +1 -3
  126. package/src/Strategy/TeamSharingModule.js +1 -1
  127. package/src/Strategy/ToolPanelModule.js +1 -4
  128. package/src/Utilities/Constants/GeneralConstants.d.ts +6 -2
  129. package/src/Utilities/Constants/GeneralConstants.js +6 -2
  130. package/src/Utilities/Constants/ModuleConstants.d.ts +1 -1
  131. package/src/Utilities/Constants/ModuleConstants.js +2 -2
  132. package/src/Utilities/Defaults/DefaultAdaptableOptions.js +22 -13
  133. package/src/Utilities/Defaults/DefaultSettingsPanel.js +1 -1
  134. package/src/Utilities/ExpressionFunctions/booleanExpressionFunctions.js +2 -4
  135. package/src/Utilities/Helpers/AdaptableHelper.js +4 -1
  136. package/src/Utilities/ObjectFactory.d.ts +3 -6
  137. package/src/Utilities/ObjectFactory.js +3 -7
  138. package/src/Utilities/Services/EntitlementService.js +7 -1
  139. package/src/Utilities/Services/Interface/IRowEditService.d.ts +8 -0
  140. package/src/Utilities/Services/Interface/IRowEditService.js +2 -0
  141. package/src/Utilities/Services/ModuleService.js +1 -1
  142. package/src/Utilities/Services/ReportService.js +2 -3
  143. package/src/Utilities/Services/RowEditService.d.ts +25 -0
  144. package/src/Utilities/Services/RowEditService.js +165 -0
  145. package/src/Utilities/Services/TeamSharingService.js +4 -4
  146. package/src/View/AdaptablePopover/index.d.ts +1 -0
  147. package/src/View/AdaptablePopover/index.js +5 -6
  148. package/src/View/AdaptableView.js +1 -1
  149. package/src/View/AdaptableViewFactory.js +2 -2
  150. package/src/View/Alert/ActiveAlertsPanel.d.ts +2 -0
  151. package/src/View/Alert/ActiveAlertsPanel.js +15 -0
  152. package/src/View/Alert/AlertStatusSubPanel.js +3 -8
  153. package/src/View/Alert/AlertViewPanel.js +2 -2
  154. package/src/View/Alert/Wizard/AlertDisplayWizardSection.js +1 -1
  155. package/src/View/BulkUpdate/BulkUpdateViewPanel.js +1 -1
  156. package/src/View/CalculatedColumn/Wizard/CalculatedColumnExpressionWizardSection.js +1 -1
  157. package/src/View/CalculatedColumn/Wizard/CalculatedColumnSettingsWizardSection.js +9 -2
  158. package/src/View/CellSummary/CellSummaryDetails.js +2 -2
  159. package/src/View/CellSummary/CellSummaryPopover.d.ts +2 -4
  160. package/src/View/CellSummary/CellSummaryPopover.js +3 -6
  161. package/src/View/CellSummary/CellSummaryPopup.js +8 -0
  162. package/src/View/CellSummary/CellSummaryStatusBarSubPanelPopover.js +1 -1
  163. package/src/View/CellSummary/CellSummaryStatusPanel.js +2 -2
  164. package/src/View/CellSummary/CellSummaryViewPanel.js +1 -1
  165. package/src/View/Components/AdaptableObjectList/AdaptableObjectCompactList.js +18 -8
  166. package/src/View/Components/AdaptableObjectList/AdaptableObjectList.js +1 -2
  167. package/src/View/Components/ExternalRenderer.d.ts +3 -6
  168. package/src/View/Components/ExternalRenderer.js +5 -5
  169. package/src/View/Components/FilterForm/FilterForm.d.ts +5 -2
  170. package/src/View/Components/FilterForm/FilterForm.js +9 -7
  171. package/src/View/Components/FilterForm/ListBoxFilterForm.d.ts +4 -1
  172. package/src/View/Components/FilterForm/ListBoxFilterForm.js +7 -7
  173. package/src/View/Components/FilterForm/QuickFilterForm.d.ts +1 -1
  174. package/src/View/Components/FilterForm/QuickFilterForm.js +21 -7
  175. package/src/View/Components/FilterForm/getDefaultColumnFilterPredicate.d.ts +1 -1
  176. package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupDialog.js +2 -0
  177. package/src/View/Components/Popups/AdaptablePopupAlert.d.ts +0 -2
  178. package/src/View/Components/Popups/AdaptablePopupAlert.js +13 -11
  179. package/src/View/Components/Popups/AdaptableToaster.js +29 -9
  180. package/src/View/Components/Popups/FormPopups/FormPopups.js +2 -2
  181. package/src/View/Components/ToolPanel/AdaptableToolPanel.js +3 -2
  182. package/src/View/Components/ToolPanel/CustomToolPanelContent.js +11 -9
  183. package/src/View/Dashboard/CustomDashboardButton.d.ts +11 -0
  184. package/src/View/Dashboard/CustomDashboardButton.js +47 -0
  185. package/src/View/Dashboard/CustomToolbarWrapper.d.ts +1 -0
  186. package/src/View/Dashboard/CustomToolbarWrapper.js +30 -11
  187. package/src/View/Dashboard/Dashboard.d.ts +1 -0
  188. package/src/View/Dashboard/Dashboard.js +8 -34
  189. package/src/View/DataChangeHistory/DataChangeHistoryGrid.js +19 -36
  190. package/src/View/DataChangeHistory/buildActionColumnButton.d.ts +3 -0
  191. package/src/View/DataChangeHistory/buildActionColumnButton.js +70 -0
  192. package/src/View/DataSet/DataSetSelector.d.ts +7 -0
  193. package/src/View/DataSet/DataSetSelector.js +18 -0
  194. package/src/View/DataSet/DataSetStatusPanelPopover.d.ts +2 -0
  195. package/src/View/DataSet/DataSetStatusPanelPopover.js +19 -0
  196. package/src/View/DataSet/DataSetViewPanel.d.ts +19 -0
  197. package/src/View/DataSet/DataSetViewPanel.js +58 -0
  198. package/src/View/Filter/ActiveFiltersPanel.js +1 -1
  199. package/src/View/Filter/FilterSummary.d.ts +5 -5
  200. package/src/View/Filter/FilterSummary.js +6 -5
  201. package/src/View/Filter/FilterViewPanel.d.ts +4 -4
  202. package/src/View/Filter/FilterViewPanel.js +11 -14
  203. package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.d.ts +3 -2
  204. package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +51 -22
  205. package/src/View/FormatColumn/Wizard/FormatColumnWizard.js +1 -1
  206. package/src/View/GridInfo/GridInfoPopup.js +1 -1
  207. package/src/View/Layout/LayoutStatusBarSubPanelPopover.js +6 -24
  208. package/src/View/Layout/Wizard/LayoutEditor/index.js +1 -1
  209. package/src/View/Layout/Wizard/LayoutEditorWizard.d.ts +2 -1
  210. package/src/View/SmartEdit/SmartEditPopup.d.ts +1 -1
  211. package/src/View/SmartEdit/SmartEditPopup.js +3 -4
  212. package/src/View/SmartEdit/SmartEditViewPanel.d.ts +1 -1
  213. package/src/View/SmartEdit/SmartEditViewPanel.js +3 -4
  214. package/src/View/SpecialColumnSettingsWizardStep.js +1 -1
  215. package/src/View/StatusBar/AdaptableStatusBar.js +1 -1
  216. package/src/View/StatusBar/StatusBarPanel.d.ts +1 -0
  217. package/src/View/StatusBar/StatusBarPanel.js +5 -4
  218. package/src/View/Theme/ThemeStatusPanelPopover.js +5 -25
  219. package/src/View/UIHelper.d.ts +4 -4
  220. package/src/View/UIHelper.js +4 -4
  221. package/src/agGrid/ActionColumnRenderer.d.ts +6 -1
  222. package/src/agGrid/ActionColumnRenderer.js +9 -6
  223. package/src/agGrid/Adaptable.d.ts +7 -2
  224. package/src/agGrid/Adaptable.js +217 -87
  225. package/src/agGrid/FilterWrapper.js +1 -1
  226. package/src/agGrid/agGridHelper.d.ts +6 -6
  227. package/src/agGrid/agGridHelper.js +34 -56
  228. package/src/agGrid/agGridMenuHelper.js +4 -1
  229. package/src/agGrid/rowEditIcons.d.ts +4 -0
  230. package/src/agGrid/rowEditIcons.js +9 -0
  231. package/src/components/AdaptableFormComponent/AdaptableFormComponent.js +9 -18
  232. package/src/components/Dashboard/DashboardToolbar.js +2 -2
  233. package/src/components/Datepicker/index.js +19 -18
  234. package/src/components/SelectList.d.ts +10 -0
  235. package/src/components/SelectList.js +9 -0
  236. package/src/components/WindowModal/WindowModal.d.ts +2 -0
  237. package/src/components/WindowModal/WindowModal.js +1 -1
  238. package/src/components/icons/{data-source.d.ts → data-set.d.ts} +0 -0
  239. package/src/components/icons/{data-source.js → data-set.js} +0 -0
  240. package/src/components/icons/index.js +2 -2
  241. package/src/metamodel/adaptable.metamodel.d.ts +242 -70
  242. package/src/metamodel/adaptable.metamodel.js +620 -376
  243. package/src/types.d.ts +19 -15
  244. package/version.d.ts +1 -1
  245. package/version.js +1 -1
  246. package/src/AdaptableOptions/SmartEdit.d.ts +0 -34
  247. package/src/Api/DataSourceApi.d.ts +0 -58
  248. package/src/Api/Implementation/DataSourceApiImpl.d.ts +0 -15
  249. package/src/Api/Implementation/DataSourceApiImpl.js +0 -51
  250. package/src/PredefinedConfig/DataSourceState.d.ts +0 -34
  251. package/src/Redux/ActionsReducers/DataSourceRedux.d.ts +0 -42
  252. package/src/Redux/ActionsReducers/DataSourceRedux.js +0 -76
  253. package/src/Redux/ActionsReducers/FilterRedux.d.ts +0 -70
  254. package/src/Redux/ActionsReducers/FilterRedux.js +0 -126
  255. package/src/Strategy/DataSourceModule.d.ts +0 -20
  256. package/src/Strategy/DataSourceModule.js +0 -56
  257. package/src/View/Components/Forms/AdaptableForm.d.ts +0 -6
  258. package/src/View/Components/Forms/AdaptableForm.js +0 -21
  259. package/src/View/DataSource/DataSourceViewPanel.d.ts +0 -19
  260. package/src/View/DataSource/DataSourceViewPanel.js +0 -69
  261. package/src/View/DataSource/Wizard/DataSourceSettingsSummary.d.ts +0 -2
  262. package/src/View/DataSource/Wizard/DataSourceSettingsSummary.js +0 -17
  263. package/src/View/DataSource/Wizard/DataSourceSettingsWizard.d.ts +0 -8
  264. package/src/View/DataSource/Wizard/DataSourceSettingsWizard.js +0 -42
  265. package/src/View/DataSource/Wizard/DataSourceWizard.d.ts +0 -8
  266. package/src/View/DataSource/Wizard/DataSourceWizard.js +0 -53
@@ -321,5 +321,177 @@ class LayoutApiImpl extends ApiBase_1.ApiBase {
321
321
  ? true
322
322
  : (_a = adaptableObject.Tags) === null || _a === void 0 ? void 0 : _a.map((tag) => tag).includes(this.getCurrentLayoutName());
323
323
  }
324
+ getAllColumnFilter() {
325
+ var _a;
326
+ const currentLayout = this.getCurrentLayout();
327
+ return (_a = currentLayout.ColumnFilters) !== null && _a !== void 0 ? _a : [];
328
+ }
329
+ getColumnFilterById(id) {
330
+ var _a;
331
+ return (_a = this.getAllColumnFilter()) === null || _a === void 0 ? void 0 : _a.find((columnFilter) => columnFilter.Uuid === id);
332
+ }
333
+ setColumnFilter(columnFilters) {
334
+ columnFilters.forEach((columnFilter) => {
335
+ if (!columnFilter.Predicate) {
336
+ LoggingHelper_1.LogAdaptableWarning('Column Filter has no Predicate', columnFilter);
337
+ }
338
+ else {
339
+ const isValidPredicate = this.adaptable.api.predicateApi.isValidPredicate(columnFilter.Predicate);
340
+ if (!isValidPredicate) {
341
+ LoggingHelper_1.LogAdaptableWarning('Column Filter Predicate is not valid', columnFilter);
342
+ }
343
+ else {
344
+ this.addUidToAdaptableObject(columnFilter);
345
+ if (this.getAllColumnFilter().find((cf) => cf.ColumnId == columnFilter.ColumnId)) {
346
+ this.dispatchAction(LayoutRedux.LayoutColumnFilterSet(columnFilter));
347
+ }
348
+ else {
349
+ this.dispatchAction(LayoutRedux.LayoutColumnFilterAdd(columnFilter));
350
+ }
351
+ }
352
+ return columnFilters === null || columnFilters === void 0 ? void 0 : columnFilters.map((columnFilter) => this.getColumnFilterById(columnFilter.Uuid));
353
+ }
354
+ });
355
+ return null;
356
+ }
357
+ clearColumnFilter(columnFilter) {
358
+ this.dispatchAction(LayoutRedux.LayoutColumnFilterClear(columnFilter));
359
+ }
360
+ clearColumnFilterByColumns(columns) {
361
+ columns.forEach((c) => {
362
+ this.clearColumnFilterByColumn(c);
363
+ });
364
+ }
365
+ clearColumnFilterByColumn(column) {
366
+ let columnFiltersForColumn = this.getAllColumnFilterForColumn(column);
367
+ if (columnFiltersForColumn) {
368
+ columnFiltersForColumn.forEach((cf) => {
369
+ this.dispatchAction(LayoutRedux.LayoutColumnFilterClear(cf));
370
+ });
371
+ this.adaptable.clearColumnFiltering([column]);
372
+ }
373
+ }
374
+ clearAllColumnFilter() {
375
+ this.dispatchAction(LayoutRedux.LayoutColumnFilterClearAll());
376
+ this.adaptable.clearGridFiltering();
377
+ }
378
+ clearAndSetColumnFilter(columnFilters) {
379
+ this.clearAllColumnFilter();
380
+ columnFilters.forEach((columnFilter) => {
381
+ if (this.getAllColumnFilter().find((cf) => cf.ColumnId == columnFilter.ColumnId)) {
382
+ this.dispatchAction(LayoutRedux.LayoutColumnFilterSet(columnFilter));
383
+ }
384
+ else {
385
+ this.dispatchAction(LayoutRedux.LayoutColumnFilterAdd(columnFilter));
386
+ }
387
+ });
388
+ }
389
+ getAllColumnFilterForColumn(column) {
390
+ let columnFilters = this.getAllColumnFilter();
391
+ if (columnFilters) {
392
+ return columnFilters.filter((cf) => cf.ColumnId == column);
393
+ }
394
+ else {
395
+ return [];
396
+ }
397
+ }
398
+ createColumnFilterForCell(columnId, primarykeyValues) {
399
+ let cellValues = [];
400
+ let predicateId;
401
+ if (primarykeyValues.length == 1) {
402
+ const normalisedValue = this.adaptable.api.gridApi.getCellNormalisedValue(primarykeyValues[0], columnId);
403
+ if (normalisedValue) {
404
+ cellValues.push(normalisedValue);
405
+ const dataType = this.adaptable.api.columnApi.getColumnDataTypeFromColumnId(columnId);
406
+ if (dataType) {
407
+ if (dataType == 'Number') {
408
+ predicateId = 'Equals';
409
+ }
410
+ else if (dataType == 'Date') {
411
+ predicateId = 'On';
412
+ }
413
+ else if (dataType == 'String') {
414
+ predicateId = 'Is';
415
+ }
416
+ else {
417
+ predicateId = 'Equals';
418
+ }
419
+ }
420
+ }
421
+ }
422
+ else {
423
+ primarykeyValues.forEach((pk) => {
424
+ const displayValue = this.adaptable.api.gridApi.getCellDisplayValue(pk, columnId);
425
+ if (displayValue && !cellValues.includes(displayValue)) {
426
+ cellValues.push(displayValue);
427
+ }
428
+ });
429
+ predicateId = 'Values';
430
+ }
431
+ const filter = {
432
+ ColumnId: columnId,
433
+ Predicate: {
434
+ PredicateId: predicateId,
435
+ Inputs: [...new Set(cellValues)],
436
+ },
437
+ };
438
+ const [savedFilter] = this.setColumnFilter([filter]) || [null];
439
+ return savedFilter;
440
+ }
441
+ columnFilterToString(columnFilter) {
442
+ const friendlyName = this.adaptable.api.columnApi.getFriendlyNameFromColumnId(columnFilter.ColumnId);
443
+ return ('[' +
444
+ friendlyName +
445
+ '] ' +
446
+ this.adaptable.api.predicateApi.predicateToString(columnFilter.Predicate));
447
+ }
448
+ columnFiltersToString(columnFilters) {
449
+ return columnFilters.map((cf) => this.columnFilterToString(cf)).join(', ');
450
+ }
451
+ evaluateColumnFilter(columnFilter, node) {
452
+ var _a;
453
+ if (!columnFilter.Predicate) {
454
+ return true;
455
+ }
456
+ if ((_a = columnFilter.Predicate.Inputs) === null || _a === void 0 ? void 0 : _a.some((input) => StringExtensions_1.default.IsNullOrEmpty(input))) {
457
+ return true;
458
+ }
459
+ const column = this.adaptable.api.columnApi.getColumnFromId(columnFilter.ColumnId);
460
+ if (!column) {
461
+ return true;
462
+ }
463
+ const gridCell = this.adaptable.api.gridApi.getGridCellFromRowNode(node, columnFilter.ColumnId);
464
+ if (!gridCell) {
465
+ return true;
466
+ }
467
+ let value = gridCell.normalisedValue;
468
+ return this.adaptable.api.predicateApi.handlePredicate(columnFilter.Predicate, {
469
+ value: value,
470
+ oldValue: null,
471
+ displayValue: gridCell.displayValue,
472
+ node,
473
+ column,
474
+ }, true);
475
+ }
476
+ removeColumnFromCurrentLayout(columnId) {
477
+ this.removeColumnFromLayout(columnId, this.getCurrentLayoutName());
478
+ }
479
+ removeColumnFromAllLayouts(columnId) {
480
+ this.getAllLayout().forEach((layout) => {
481
+ this.removeColumnFromLayout(columnId, layout.Name);
482
+ });
483
+ }
484
+ removeColumnFromLayout(columnId, layoutName) {
485
+ const column = this.getAdaptableApi().columnApi.getColumnFromId(columnId);
486
+ if (column) {
487
+ const layout = this.getLayoutByName(layoutName);
488
+ if (layout) {
489
+ if (layout.Columns.includes(columnId)) {
490
+ this.dispatchAction(LayoutRedux.LayouRemoveColumn(layoutName, columnId));
491
+ this.getAdaptableApi().columnApi.hideColumn(columnId);
492
+ }
493
+ }
494
+ }
495
+ }
324
496
  }
325
497
  exports.LayoutApiImpl = LayoutApiImpl;
@@ -15,7 +15,7 @@ class PredicateApiImpl extends ApiBase_1.ApiBase {
15
15
  return AdaptablePredicate_1.SystemPredicateDefs;
16
16
  }
17
17
  getCustomPredicateDefs() {
18
- return this.adaptable.adaptableOptions.customPredicateDefs;
18
+ return this.getAdaptableQLOptions().customPredicateDefs;
19
19
  }
20
20
  getPredicateDefsByModuleScope(moduleScope) {
21
21
  return this.getPredicateDefs().filter((p) => p.moduleScope.includes(moduleScope));
@@ -1,12 +1,15 @@
1
1
  import { ApiBase } from './ApiBase';
2
+ import { MathOperation } from '../../PredefinedConfig/Common/Enums';
2
3
  import { SmartEditApi } from '../SmartEditApi';
3
4
  import { GridCell } from '../../PredefinedConfig/Selection/GridCell';
4
- import { SmartEditOperation } from '../../AdaptableOptions/SmartEdit';
5
+ import { SmartEditCustomOperation, SmartEditOperation } from '../../AdaptableOptions/EditOptions';
5
6
  export declare class SmartEditApiImpl extends ApiBase implements SmartEditApi {
6
- setSmartEditOperation(mathOperation: SmartEditOperation): void;
7
+ setSmartEditOperation(mathOperation: MathOperation): void;
7
8
  getSmartEditOperation(): SmartEditOperation;
8
9
  setSmartEditValue(smartEditValue: number): void;
9
10
  getSmartEditValue(): number;
10
11
  showSmartEditPopup(): void;
11
12
  applySmartEdit(gridCells: GridCell[]): void;
13
+ getSmartEditCustomOperations(): SmartEditCustomOperation[] | undefined;
14
+ setCustomSmartEditOperation(customOperationName: string): void;
12
15
  }
@@ -25,5 +25,14 @@ class SmartEditApiImpl extends ApiBase_1.ApiBase {
25
25
  applySmartEdit(gridCells) {
26
26
  this.dispatchAction(SmartEditRedux.SmartEditApply(gridCells));
27
27
  }
28
+ getSmartEditCustomOperations() {
29
+ return this.getEditOptions().smartEditCustomOperations;
30
+ }
31
+ setCustomSmartEditOperation(customOperationName) {
32
+ const customOperation = this.getSmartEditCustomOperations().find((so) => so.name == customOperationName);
33
+ if (customOperation) {
34
+ this.dispatchAction(SystemRedux.SmartEditChangeOperation(customOperation));
35
+ }
36
+ }
28
37
  }
29
38
  exports.SmartEditApiImpl = SmartEditApiImpl;
@@ -1,13 +1,15 @@
1
1
  import { ApiBase } from './ApiBase';
2
2
  import { TeamSharingApi } from '../TeamSharingApi';
3
- import { TeamSharingState, SharedEntity, AdaptableModule, AdaptableObject, SharedEntityConfig } from '../../types';
3
+ import { SharedEntity, AdaptableModule, AdaptableObject, SharedEntityConfig } from '../../types';
4
4
  export declare class TeamSharingApiImpl extends ApiBase implements TeamSharingApi {
5
- getTeamSharingState(): TeamSharingState;
6
- getSharedEntities(): SharedEntity[];
5
+ getSharedEntities(): Promise<SharedEntity[]>;
6
+ setSharedEntities(sharedEntities: SharedEntity[]): Promise<boolean>;
7
+ isTeamSharingAvailable(): boolean;
7
8
  isTeamSharingActivated(): boolean;
8
9
  hasTeamSharingFullRights(): boolean;
9
10
  checkForUpdates(): void;
10
11
  showTeamSharingPopup(): void;
11
12
  fireTeamSharingEntityChangedEvent(sharedEntity: SharedEntity): void;
12
13
  shareEntity(entity: AdaptableObject, module: AdaptableModule, sharedEntityConfig: SharedEntityConfig): void;
14
+ unshareEntity(entityId: string): void;
13
15
  }
@@ -8,20 +8,31 @@ const TeamSharingRedux_1 = require("../../Redux/ActionsReducers/TeamSharingRedux
8
8
  const TeamSharingRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/TeamSharingRedux"));
9
9
  const LoggingHelper_1 = require("../../Utilities/Helpers/LoggingHelper");
10
10
  class TeamSharingApiImpl extends ApiBase_1.ApiBase {
11
- getTeamSharingState() {
12
- return this.getAdaptableState().TeamSharing;
11
+ async getSharedEntities() {
12
+ if (!this.isTeamSharingActivated()) {
13
+ LoggingHelper_1.ConsoleLogWarning('Team Sharing is not Activated so Entities cannot be loaded');
14
+ return [];
15
+ }
16
+ return this.adaptable.adaptableOptions.teamSharingOptions.getSharedEntities(this.adaptable.adaptableOptions.adaptableId);
13
17
  }
14
- getSharedEntities() {
15
- return this.getAdaptableState().TeamSharing.SharedEntities;
18
+ async setSharedEntities(sharedEntities) {
19
+ if (!this.isTeamSharingActivated()) {
20
+ LoggingHelper_1.ConsoleLogWarning('Team Sharing is not Activated so Entities cannot be shared');
21
+ return false;
22
+ }
23
+ await this.adaptable.adaptableOptions.teamSharingOptions.setSharedEntities(this.adaptable.adaptableOptions.adaptableId, sharedEntities);
24
+ return true;
16
25
  }
17
- isTeamSharingActivated() {
26
+ isTeamSharingAvailable() {
27
+ var _a, _b, _c;
18
28
  return (!this.getAdaptableApi()
19
29
  .internalApi.getEntitlementService()
20
- .isModuleHiddenEntitlement(ModuleConstants.TeamSharingModuleId) &&
21
- this.adaptable.adaptableOptions.teamSharingOptions &&
22
- this.adaptable.adaptableOptions.teamSharingOptions.enableTeamSharing &&
23
- !!this.adaptable.adaptableOptions.teamSharingOptions.getSharedEntities &&
24
- !!this.adaptable.adaptableOptions.teamSharingOptions.setSharedEntities);
30
+ .isModuleHiddenEntitlement(ModuleConstants.TeamSharingModuleId) && ((_a = this.adaptable.adaptableOptions.teamSharingOptions) === null || _a === void 0 ? void 0 : _a.enableTeamSharing) &&
31
+ !!((_b = this.adaptable.adaptableOptions.teamSharingOptions) === null || _b === void 0 ? void 0 : _b.getSharedEntities) &&
32
+ !!((_c = this.adaptable.adaptableOptions.teamSharingOptions) === null || _c === void 0 ? void 0 : _c.setSharedEntities));
33
+ }
34
+ isTeamSharingActivated() {
35
+ return this.isTeamSharingAvailable();
25
36
  }
26
37
  hasTeamSharingFullRights() {
27
38
  return this.adaptable.api.internalApi
@@ -50,5 +61,12 @@ class TeamSharingApiImpl extends ApiBase_1.ApiBase {
50
61
  }
51
62
  this.dispatchAction(TeamSharingRedux.TeamSharingShare(entity, module, sharedEntityConfig));
52
63
  }
64
+ unshareEntity(entityId) {
65
+ if (!this.isTeamSharingActivated()) {
66
+ LoggingHelper_1.ConsoleLogWarning('Team Sharing is not Activated so Entities cannot be unshared');
67
+ return;
68
+ }
69
+ this.dispatchAction(TeamSharingRedux.TeamSharingRemoveItem(entityId));
70
+ }
53
71
  }
54
72
  exports.TeamSharingApiImpl = TeamSharingApiImpl;
@@ -24,6 +24,6 @@ export declare class UserInterfaceApiImpl extends ApiBase implements UserInterfa
24
24
  addContextMenuItem(userMenuItem: UserMenuItem<ContextMenuContext>): void;
25
25
  getEditableCellStyle(): AdaptableStyle | undefined;
26
26
  getReadOnlyCellStyle(): AdaptableStyle | undefined;
27
- getAllActionColumn(): ActionColumn[];
28
27
  getAdaptableObjectTags(): AdaptableObjectTag[] | undefined;
28
+ getAllActionColumn(): ActionColumn[];
29
29
  }
@@ -134,25 +134,7 @@ class UserInterfaceApiImpl extends ApiBase_1.ApiBase {
134
134
  if (!editLookUpItem || !gridCell || !gridCell.column) {
135
135
  return undefined;
136
136
  }
137
- let editLookUpValues = editLookUpItem.values;
138
- // first do the function then get hardcoded items
139
- if (editLookUpValues != null && typeof editLookUpValues === 'function') {
140
- const editLookUpContext = {
141
- adaptableApi: this.adaptable.api,
142
- column: gridCell.column,
143
- gridCell: gridCell,
144
- };
145
- return editLookUpValues(editLookUpContext);
146
- }
147
- else {
148
- let arr = editLookUpValues;
149
- if (arr && ArrayExtensions_1.ArrayExtensions.IsNotNullOrEmpty(arr)) {
150
- return arr;
151
- }
152
- }
153
- // if no hard-coded values or function provided then just get the distinct values for the column
154
- // this will use the columnapi method that first looks for permitted values and then distinct values
155
- return this.adaptable.api.columnApi.getDistinctDisplayValuesForColumn(gridCell.column.columnId);
137
+ return this.adaptable.api.internalApi.getEditLookUpValuesForColumn(editLookUpItem, gridCell.column, gridCell);
156
138
  }
157
139
  addColumnMenuItem(userMenuItem) {
158
140
  var _a;
@@ -168,14 +150,10 @@ class UserInterfaceApiImpl extends ApiBase_1.ApiBase {
168
150
  getReadOnlyCellStyle() {
169
151
  return this.getUserInterfaceOptions().readOnlyCellStyle;
170
152
  }
171
- getAllActionColumn() {
172
- var _a;
173
- return (_a = this.getUserInterfaceOptions().actionColumns) !== null && _a !== void 0 ? _a : [];
174
- }
175
153
  getAdaptableObjectTags() {
176
- let objectTags = this.getUserInterfaceOptions().objectTags;
154
+ const objectTags = this.getUserInterfaceOptions().objectTags;
177
155
  if (objectTags != null && typeof objectTags === 'function') {
178
- return objectTags(this.getAdaptableApi());
156
+ return objectTags({ adaptableApi: this.adaptable.api });
179
157
  }
180
158
  else {
181
159
  let arr = objectTags;
@@ -184,5 +162,9 @@ class UserInterfaceApiImpl extends ApiBase_1.ApiBase {
184
162
  }
185
163
  }
186
164
  }
165
+ getAllActionColumn() {
166
+ var _a, _b;
167
+ return (_b = (_a = this.getUserInterfaceOptions().actionOptions) === null || _a === void 0 ? void 0 : _a.actionColumns) !== null && _b !== void 0 ? _b : [];
168
+ }
187
169
  }
188
170
  exports.UserInterfaceApiImpl = UserInterfaceApiImpl;
@@ -17,7 +17,7 @@ import { AdaptableOptions } from '../AdaptableOptions/AdaptableOptions';
17
17
  import { Layout } from '../PredefinedConfig/LayoutState';
18
18
  import { AdaptableAlert, AdaptableCellChangedAlert, AdaptableRowChangedAlert } from '../PredefinedConfig/Common/AdaptableAlert';
19
19
  import { IDataService } from '../Utilities/Services/Interface/IDataService';
20
- import { AdaptableMessageType, AlertDefinition, BaseContext, CellDataChangedInfo, LayoutAssociatedObject, SystemStatusMessageInfo } from '../types';
20
+ import { AdaptableIcon, AdaptableMessageType, AlertDefinition, BaseContext, CellDataChangedInfo, EditLookUpPermittedValues, LayoutAssociatedObject, SharedEntity, SystemStatusMessageInfo } from '../types';
21
21
  import { IEntitlementService } from '../Utilities/Services/Interface/IEntitlementService';
22
22
  import { AdaptableFlashingCell } from '../PredefinedConfig/Common/AdaptableFlashingCell';
23
23
  import { IQueryLanguageService } from '../Utilities/Services/Interface/IQueryLanguageService';
@@ -34,6 +34,7 @@ import { IMetamodelService } from '../Utilities/Services/Interface/IMetamodelSer
34
34
  import { RowNode } from '@ag-grid-community/all-modules';
35
35
  import { IModuleCollection } from '../Strategy/Interface/IModule';
36
36
  import { AdaptableObjectTag } from '../PredefinedConfig/Common/AdaptableObject';
37
+ import { IRowEditService } from '../Utilities/Services/Interface/IRowEditService';
37
38
  /**
38
39
  * This set of api methods is designed for **internal use of Adaptable** only.
39
40
  *
@@ -101,6 +102,7 @@ export interface InternalApi {
101
102
  getAlertService(): IAlertService;
102
103
  getTeamSharingService(): ITeamSharingService;
103
104
  getMetamodelService(): IMetamodelService;
105
+ getRowEditService(): IRowEditService;
104
106
  getModules(): IModuleCollection;
105
107
  getModuleFriendlyName(adaptableModule: AdaptableModule): string;
106
108
  runModuleInAdaptableQL(adaptableQLModule: AdaptableQLModule): boolean;
@@ -115,9 +117,10 @@ export interface InternalApi {
115
117
  getLabelForButton(button: AdaptableButton<BaseContext>, context: BaseContext): string | undefined;
116
118
  getTooltipForButton(button: AdaptableButton<BaseContext>, context: BaseContext): string | undefined;
117
119
  getStyleForButton(button: AdaptableButton<BaseContext>, context: BaseContext): ButtonStyle | undefined;
120
+ getIconForButton(button: AdaptableButton<BaseContext>, context: BaseContext): AdaptableIcon | undefined;
118
121
  dispatchReduxAction(action: Action): void;
119
122
  waitForTeamSharingImportEnd(): Promise<boolean>;
120
- getUserDefinedHeaderName(columnId: string): string;
123
+ getLocalTeamSharingEntities(): SharedEntity[];
121
124
  createFrameworkComponent(containerDomNode: HTMLElement, frameworkComponent: AdaptableFrameworkComponent, componentType: 'toolPanel' | 'toolbar' | string): void;
122
125
  destroyFrameworkComponent(containerDomNode: HTMLElement, frameworkComponent: AdaptableFrameworkComponent, componentType: 'toolPanel' | 'toolbar' | string): void;
123
126
  initializeDataChangeHistory(): void;
@@ -133,4 +136,5 @@ export interface InternalApi {
133
136
  showSettingsPanel(module: AdaptableModule, moduleParams?: ModuleParams): void;
134
137
  getLabelForTag(adaptableObjectTag: AdaptableObjectTag): string;
135
138
  getValueForTag(adaptableObjectTag: AdaptableObjectTag): string | number;
139
+ getEditLookUpValuesForColumn(editLookUpItem: EditLookUpPermittedValues, column: AdaptableColumn, gridCell?: GridCell): any[] | undefined;
136
140
  }
@@ -1,4 +1,5 @@
1
- import { AdaptableColumn, ColumnSort, LayoutAssociatedObject } from '../../types';
1
+ import { RowNode } from '@ag-grid-community/all-modules';
2
+ import { AdaptableColumn, ColumnFilter, ColumnSort, LayoutAssociatedObject } from '../../types';
2
3
  import { LayoutState, Layout } from '../PredefinedConfig/LayoutState';
3
4
  /**
4
5
  * Provides run-time access to the Layout Module and associated state
@@ -187,4 +188,90 @@ export interface LayoutApi {
187
188
  * @param adaptableObject object to check
188
189
  */
189
190
  isObjectAvailableInCurrentLayout(adaptableObject: LayoutAssociatedObject): boolean;
191
+ /**
192
+ * Retrieves all the Column Filters in the Column Filter State (of Predefined Config)
193
+ * @returns column filters
194
+ */
195
+ getAllColumnFilter(): ColumnFilter[];
196
+ /**
197
+ * Retrieves ColumnFilter by Id
198
+ * @param id column filter id
199
+ * @returns column filter
200
+ */
201
+ getColumnFilterById(id: ColumnFilter['Uuid']): ColumnFilter;
202
+ /**
203
+ * Sets Column Filters - will replace filters for existing column and leave other column filters in place
204
+ * @param columnFilters Column Filters to set
205
+ * @returns column filters
206
+ */
207
+ setColumnFilter(columnFilters: ColumnFilter[]): ColumnFilter[] | null;
208
+ /**
209
+ * Clears given Column Filter
210
+ * @param columnFilter Column Filter to clear
211
+ */
212
+ clearColumnFilter(columnFilter: ColumnFilter): void;
213
+ /**
214
+ * Clears Column Filter for given Column
215
+ * @param columnId Column for which Column Filter should be cleared
216
+ */
217
+ clearColumnFilterByColumn(columnId: string): void;
218
+ /**
219
+ * Clears Column Filters for given set of Columns
220
+ * @param columns Columns for which Column Filte should be cleared
221
+ */
222
+ clearColumnFilterByColumns(columns: string[]): void;
223
+ /**
224
+ * Clears all Column Filters in State
225
+ */
226
+ clearAllColumnFilter(): void;
227
+ /**
228
+ * Clears existing Column Filters and then sets the new ones
229
+ * @param columnFilters Column Filters to set
230
+ */
231
+ clearAndSetColumnFilter(columnFilters: ColumnFilter[]): void;
232
+ /**
233
+ * Retrieves all Column Filters for given Column
234
+ * @param columnId column to retrieve Column Filters for
235
+ * @returns column filters
236
+ */
237
+ getAllColumnFilterForColumn(columnId: string): ColumnFilter[];
238
+ /**
239
+ * Creates new Column Filter on given Column using Primary Key values
240
+ * @param columnId ColumnId to use
241
+ * @param primarykeyValues Primary Key Values to use
242
+ * @returns column filter
243
+ */
244
+ createColumnFilterForCell(columnId: string, primarykeyValues: any[]): ColumnFilter | null;
245
+ /**
246
+ * Retrieves description of given Column Filter
247
+ * @param columnFilter Column Filter to use
248
+ */
249
+ columnFilterToString(columnFilter: ColumnFilter): string;
250
+ /**
251
+ * Retrieves descriptions of given Column Filters
252
+ * @param columnFilters Column Filters to use
253
+ */
254
+ columnFiltersToString(columnFilters: ColumnFilter[]): string;
255
+ /**
256
+ * Calls AdapTableQL to evaluate Filter for given Row
257
+ * @param columnFilter Column Filter to use
258
+ * @param node Row Node to evaluate
259
+ */
260
+ evaluateColumnFilter(columnFilter: ColumnFilter, node: RowNode): boolean;
261
+ /**
262
+ * Removes a Column from the Current Layout
263
+ * @param columnId Column to remove
264
+ */
265
+ removeColumnFromCurrentLayout(columnId: string): void;
266
+ /**
267
+ * Removes a Column from all Layouts
268
+ * @param columnId Column to remove
269
+ */
270
+ removeColumnFromAllLayouts(columnId: string): void;
271
+ /**
272
+ * Removes a Column from a given Layout
273
+ * @param columnId Column to remove
274
+ * @param layoutName layout from which to remove Column
275
+ */
276
+ removeColumnFromLayout(columnId: string, layoutName: string): void;
190
277
  }
@@ -1,14 +1,21 @@
1
- import { SmartEditOperation } from '../AdaptableOptions/SmartEdit';
1
+ import { SmartEditOperation } from '../AdaptableOptions/EditOptions';
2
+ import { MathOperation } from '../PredefinedConfig/Common/Enums';
2
3
  import { GridCell } from '../PredefinedConfig/Selection/GridCell';
4
+ import { SmartEditCustomOperation } from '../types';
3
5
  /**
4
6
  * Provides run-time access to the Smart Edit Module
5
7
  **/
6
8
  export interface SmartEditApi {
7
9
  /**
8
- * Sets Smart Edit operation: ('Add','Subtract','Multiply','Divide'
10
+ * Sets (shipped) Smart Edit Operation: 'Add','Subtract','Multiply','Divide'
9
11
  * @param operation operation to run
10
12
  */
11
- setSmartEditOperation(operation: SmartEditOperation): void;
13
+ setSmartEditOperation(operation: MathOperation): void;
14
+ /**
15
+ * Sets current Smart Edit Operation to a Custom Operation
16
+ * @param customOperationName name of Custom Smart Edit Operation
17
+ */
18
+ setCustomSmartEditOperation(customOperationName: string): void;
12
19
  /**
13
20
  * Gets current Smart Edit Operation
14
21
  */
@@ -31,4 +38,8 @@ export interface SmartEditApi {
31
38
  * @param gridCells Cells to apply the Smart Edit
32
39
  */
33
40
  applySmartEdit(gridCells: GridCell[]): void;
41
+ /**
42
+ * Retrieves an Smart Edit Custom Operations (provided in Edit Options)
43
+ */
44
+ getSmartEditCustomOperations(): SmartEditCustomOperation[] | undefined;
34
45
  }
@@ -1,22 +1,30 @@
1
1
  import { AdaptableObject } from '../PredefinedConfig/Common/AdaptableObject';
2
2
  import { SharedEntity } from '../PredefinedConfig/TeamSharingState';
3
- import { AdaptableModule, SharedEntityConfig, TeamSharingState } from '../types';
3
+ import { AdaptableModule, SharedEntityConfig } from '../types';
4
4
  /**
5
5
  * Provides run-time access to Team Sharing Module and associated state
6
6
  */
7
7
  export interface TeamSharingApi {
8
8
  /**
9
- * Retrieves Team Sharing section of State
9
+ * Retrieves all shared entities which are currently shared. It is an asynchronous operation as it leverages the `TeamSharingOptions.getSharedEntities(...)` method.
10
10
  */
11
- getTeamSharingState(): TeamSharingState;
11
+ getSharedEntities(): Promise<SharedEntity[]>;
12
12
  /**
13
- * Retrieves all Shared Entities in Team Sharing State
13
+ * Sets the shared entities which are currently shared. It is an asynchronous operation as it leverages the `TeamSharingOptions.setSharedEntities(...)` method.
14
+ * @param sharedEntities the shared entities
15
+ * @return either TRUE if the shared entities were successfully set or FALSE if the shared entities were not set
14
16
  */
15
- getSharedEntities(): SharedEntity[];
17
+ setSharedEntities(sharedEntities: SharedEntity[]): Promise<boolean>;
16
18
  /**
17
19
  * Whether Team Sharing is Activated
20
+ *
21
+ * @deprecated use `Adaptable.isTeamSharingAvailable()` instead
18
22
  */
19
23
  isTeamSharingActivated(): boolean;
24
+ /**
25
+ * Whether Team Sharing is Available to use
26
+ */
27
+ isTeamSharingAvailable(): boolean;
20
28
  /**
21
29
  * Whether current user has full Team Sharing rights (for creating & updating shared items)
22
30
  */
@@ -41,4 +49,9 @@ export interface TeamSharingApi {
41
49
  * @param sharedEntityConfig Config info about the Sharing Actions
42
50
  */
43
51
  shareEntity(entity: AdaptableObject, module: AdaptableModule, sharedEntityConfig: SharedEntityConfig): void;
52
+ /**
53
+ * Removes an Adaptable Object from the Team Share.
54
+ * @param entityId the ID of the AdaptableObject to be removed from Team Share
55
+ */
56
+ unshareEntity(entityId: string): void;
44
57
  }
@@ -70,12 +70,12 @@ export interface UserInterfaceApi {
70
70
  * Returns Style set for ReadOnly cells
71
71
  */
72
72
  getReadOnlyCellStyle(): AdaptableStyle | undefined;
73
- /**
74
- * Retrieves any Action Columns (provided in User Interface Options)
75
- */
76
- getAllActionColumn(): ActionColumn[];
77
73
  /**
78
74
  * Retrieves any Object Tags (provided in User Interface Options)
79
75
  */
80
76
  getAdaptableObjectTags(): AdaptableObjectTag[] | undefined;
77
+ /**
78
+ * Retrieves any Action Columns (provided in User Interface Options)
79
+ */
80
+ getAllActionColumn(): ActionColumn[];
81
81
  }
@@ -6,7 +6,6 @@ import { CalculatedColumnState } from './CalculatedColumnState';
6
6
  import { ConditionalStyleState } from './ConditionalStyleState';
7
7
  import { CustomSortState } from './CustomSortState';
8
8
  import { DashboardState } from './DashboardState';
9
- import { DataSourceState } from './DataSourceState';
10
9
  import { ExportState } from './ExportState';
11
10
  import { FormatColumnState } from './FormatColumnState';
12
11
  import { FreeTextColumnState } from './FreeTextColumnState';
@@ -18,7 +17,6 @@ import { ShortcutState } from './ShortcutState';
18
17
  import { TeamSharingState } from './TeamSharingState';
19
18
  import { ThemeState } from './ThemeState';
20
19
  import { ConfigState } from './ConfigState';
21
- import { FilterState } from './FilterState';
22
20
  import { ApplicationState } from './ApplicationState';
23
21
  import { ToolPanelState } from './ToolPanelState';
24
22
  import { QueryState } from './QueryState';
@@ -41,9 +39,7 @@ export interface AdaptablePersistentState {
41
39
  ConditionalStyle: ConditionalStyleState;
42
40
  CustomSort: CustomSortState;
43
41
  Dashboard: DashboardState;
44
- DataSource: DataSourceState;
45
42
  Export: ExportState;
46
- Filter: FilterState;
47
43
  FormatColumn: FormatColumnState;
48
44
  FreeTextColumn: FreeTextColumnState;
49
45
  Layout: LayoutState;
@@ -46,6 +46,11 @@ export interface CalculatedColumnSettings extends SpecialColumnSettings {
46
46
  * @defaultValue false
47
47
  */
48
48
  ShowToolTip?: boolean;
49
+ /**
50
+ * If true, the Calculated Column Expression will NOT be evaluated and the value is loaded from the row data property with the same name as the ColumnId
51
+ * @defaultValue false
52
+ */
53
+ ExternallyEvaluatedExpression?: boolean;
49
54
  }
50
55
  /**
51
56
  * Calculated Column Query which may be a Scalar or an AggregatedScalar Expression
@@ -11,13 +11,13 @@ export interface AdaptableButton<CONTEXT_TYPE extends BaseContext> extends Adapt
11
11
  */
12
12
  label?: string | ((button: AdaptableButton<CONTEXT_TYPE>, context: CONTEXT_TYPE) => string);
13
13
  /**
14
- * Style for Button - can be object or function thats provides a `Style` object
14
+ * Style for Button - can be object or function that provides a `ButtonStyle` object
15
15
  */
16
16
  buttonStyle?: ButtonStyle | ((button: AdaptableButton<CONTEXT_TYPE>, context: CONTEXT_TYPE) => ButtonStyle);
17
17
  /**
18
- * Icon to display, requires string for URL, other props are optional
18
+ * Icon for Button - can be object or function that provides a `AdaptableIcon` object
19
19
  */
20
- icon?: AdaptableIcon;
20
+ icon?: AdaptableIcon | ((button: AdaptableButton<CONTEXT_TYPE>, context: CONTEXT_TYPE) => AdaptableIcon);
21
21
  /**
22
22
  * Tooltip for Button - can be string or function that provides string
23
23
  */