@adaptabletools/adaptable-cjs 17.0.0-canary.4 → 18.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 (285) hide show
  1. package/base.css +62 -14
  2. package/base.css.map +1 -1
  3. package/index.css +267 -165
  4. package/index.css.map +1 -1
  5. package/package.json +5 -4
  6. package/src/AdaptableInterfaces/IAdaptable.d.ts +3 -0
  7. package/src/AdaptableOptions/AdaptableOptions.d.ts +5 -0
  8. package/src/AdaptableOptions/AlertOptions.d.ts +7 -7
  9. package/src/AdaptableOptions/ColumnFilterOptions.d.ts +9 -9
  10. package/src/AdaptableOptions/CommentsOptions.d.ts +28 -0
  11. package/src/AdaptableOptions/EditOptions.d.ts +6 -6
  12. package/src/AdaptableOptions/GridFilterOptions.d.ts +13 -8
  13. package/src/AdaptableOptions/GroupingOptions.d.ts +9 -9
  14. package/src/AdaptableOptions/InteropioPluginOptions.d.ts +10 -0
  15. package/src/AdaptableOptions/MenuOptions.d.ts +18 -4
  16. package/src/AdaptableOptions/MenuOptions.js +14 -6
  17. package/src/AdaptableOptions/NotesOptions.d.ts +2 -9
  18. package/src/Api/AdaptableApi.d.ts +6 -1
  19. package/src/Api/CommentApi.d.ts +58 -0
  20. package/src/Api/EventApi.d.ts +48 -12
  21. package/src/Api/Events/CalculatedColumnChanged.d.ts +19 -0
  22. package/src/Api/Events/CellSelectionChanged.d.ts +11 -0
  23. package/src/Api/Events/CommentsChangedInfo.d.ts +5 -0
  24. package/src/Api/Events/LiveDataChanged.d.ts +3 -3
  25. package/src/Api/Events/RowSelectionChanged.d.ts +11 -0
  26. package/src/Api/GridApi.d.ts +0 -6
  27. package/src/Api/GridFilterApi.d.ts +2 -2
  28. package/src/Api/Implementation/AdaptableApiImpl.d.ts +6 -6
  29. package/src/Api/Implementation/AdaptableApiImpl.js +2 -0
  30. package/src/Api/Implementation/CommentsApiImpl.d.ts +15 -0
  31. package/src/Api/Implementation/CommentsApiImpl.js +46 -0
  32. package/src/Api/Implementation/ExpressionApiImpl.d.ts +1 -1
  33. package/src/Api/Implementation/ExpressionApiImpl.js +3 -4
  34. package/src/Api/Implementation/GridApiImpl.d.ts +0 -1
  35. package/src/Api/Implementation/GridApiImpl.js +0 -4
  36. package/src/Api/Implementation/GridFilterApiImpl.d.ts +1 -1
  37. package/src/Api/Implementation/GridFilterApiImpl.js +1 -1
  38. package/src/Api/Implementation/NotesApiImpl.d.ts +2 -6
  39. package/src/Api/Implementation/NotesApiImpl.js +1 -15
  40. package/src/Api/Implementation/OptionsApiImpl.d.ts +2 -0
  41. package/src/Api/Implementation/OptionsApiImpl.js +3 -0
  42. package/src/Api/Implementation/PluginsApiImpl.d.ts +2 -6
  43. package/src/Api/Implementation/PluginsApiImpl.js +3 -15
  44. package/src/Api/Implementation/ScheduleApiImpl.d.ts +1 -12
  45. package/src/Api/Implementation/ScheduleApiImpl.js +0 -36
  46. package/src/Api/Implementation/ThemeApiImpl.d.ts +1 -0
  47. package/src/Api/Implementation/ThemeApiImpl.js +3 -0
  48. package/src/Api/Internal/ActionRowInternalApi.js +1 -1
  49. package/src/Api/Internal/AdaptableInternalApi.d.ts +2 -0
  50. package/src/Api/Internal/AdaptableInternalApi.js +3 -0
  51. package/src/Api/Internal/CalculatedColumnInternalApi.d.ts +2 -0
  52. package/src/Api/Internal/CalculatedColumnInternalApi.js +16 -0
  53. package/src/Api/Internal/DashboardInternalApi.d.ts +1 -0
  54. package/src/Api/Internal/DashboardInternalApi.js +5 -0
  55. package/src/Api/Internal/DataImportInternalApi.js +2 -0
  56. package/src/Api/Internal/DataSetInternalApi.js +2 -1
  57. package/src/Api/Internal/GridInternalApi.d.ts +3 -1
  58. package/src/Api/Internal/GridInternalApi.js +32 -9
  59. package/src/Api/Internal/LayoutInternalApi.d.ts +2 -2
  60. package/src/Api/Internal/LayoutInternalApi.js +11 -11
  61. package/src/Api/InteropioPluginApi.d.ts +10 -0
  62. package/src/Api/{NotesAPi.d.ts → NotesApi.d.ts} +19 -21
  63. package/src/Api/OptionsApi.d.ts +5 -0
  64. package/src/Api/PluginsApi.d.ts +3 -13
  65. package/src/Api/ScheduleApi.d.ts +1 -48
  66. package/src/Api/ThemeApi.d.ts +5 -0
  67. package/src/PredefinedConfig/AdaptableState.d.ts +4 -2
  68. package/src/PredefinedConfig/CellAddress.d.ts +13 -0
  69. package/src/PredefinedConfig/CellAddress.js +5 -0
  70. package/src/PredefinedConfig/CommentState.d.ts +48 -0
  71. package/src/PredefinedConfig/CommentState.js +2 -0
  72. package/src/PredefinedConfig/Common/AdaptableIcon.d.ts +1 -1
  73. package/src/PredefinedConfig/Common/AdaptablePredicate.js +2 -1
  74. package/src/PredefinedConfig/Common/Enums.d.ts +0 -1
  75. package/src/PredefinedConfig/Common/Enums.js +0 -1
  76. package/src/PredefinedConfig/Common/Schedule.d.ts +1 -1
  77. package/src/PredefinedConfig/Common/Types.d.ts +5 -5
  78. package/src/PredefinedConfig/Common/Types.js +0 -2
  79. package/src/PredefinedConfig/NotesState.d.ts +0 -13
  80. package/src/PredefinedConfig/PredefinedConfig.d.ts +3 -0
  81. package/src/PredefinedConfig/ScheduleState.d.ts +0 -5
  82. package/src/PredefinedConfig/SystemState.d.ts +5 -6
  83. package/src/PredefinedConfig/ThemeState.d.ts +1 -1
  84. package/src/Redux/ActionsReducers/CommentsRedux.d.ts +79 -0
  85. package/src/Redux/ActionsReducers/CommentsRedux.js +189 -0
  86. package/src/Redux/ActionsReducers/NotesRedux.js +1 -2
  87. package/src/Redux/ActionsReducers/PluginsRedux.d.ts +0 -48
  88. package/src/Redux/ActionsReducers/PluginsRedux.js +1 -49
  89. package/src/Redux/ActionsReducers/PlusMinusRedux.d.ts +16 -0
  90. package/src/Redux/ActionsReducers/PlusMinusRedux.js +47 -1
  91. package/src/Redux/ActionsReducers/ScheduleRedux.d.ts +0 -53
  92. package/src/Redux/ActionsReducers/ScheduleRedux.js +2 -90
  93. package/src/Redux/ActionsReducers/SystemRedux.d.ts +23 -12
  94. package/src/Redux/ActionsReducers/SystemRedux.js +55 -23
  95. package/src/Redux/Store/AdaptableStore.d.ts +2 -2
  96. package/src/Redux/Store/AdaptableStore.js +107 -46
  97. package/src/Strategy/CommentsModule.d.ts +16 -0
  98. package/src/Strategy/CommentsModule.js +82 -0
  99. package/src/Strategy/LayoutModule.d.ts +12 -4
  100. package/src/Strategy/LayoutModule.js +19 -14
  101. package/src/Strategy/NotesModule.d.ts +0 -13
  102. package/src/Strategy/NotesModule.js +9 -88
  103. package/src/Strategy/PlusMinusModule.js +2 -0
  104. package/src/Strategy/ScheduleModule.js +0 -23
  105. package/src/Strategy/Utilities/Export/getExportRowsViewItems.d.ts +2 -1
  106. package/src/Strategy/Utilities/Export/getExportRowsViewItems.js +14 -5
  107. package/src/Strategy/Utilities/getExpressionViewItems.js +8 -2
  108. package/src/Utilities/Constants/ConfigConstants.d.ts +1 -0
  109. package/src/Utilities/Constants/ConfigConstants.js +2 -1
  110. package/src/Utilities/Constants/GeneralConstants.d.ts +1 -0
  111. package/src/Utilities/Constants/GeneralConstants.js +8 -3
  112. package/src/Utilities/Constants/ModuleConstants.d.ts +3 -3
  113. package/src/Utilities/Constants/ModuleConstants.js +4 -4
  114. package/src/Utilities/Defaults/DefaultAdaptableOptions.js +3 -3
  115. package/src/Utilities/Defaults/DefaultSettingsPanel.js +1 -0
  116. package/src/Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions.js +7 -1
  117. package/src/Utilities/ExpressionFunctions/booleanExpressionFunctions.js +6 -0
  118. package/src/Utilities/ExpressionFunctions/dateUtils.d.ts +1 -0
  119. package/src/Utilities/ExpressionFunctions/dateUtils.js +18 -1
  120. package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.d.ts +1 -1
  121. package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.js +12 -12
  122. package/src/Utilities/Extensions/ArrayExtensions.d.ts +2 -0
  123. package/src/Utilities/Extensions/ArrayExtensions.js +8 -1
  124. package/src/Utilities/Helpers/PreviewHelper.js +5 -2
  125. package/src/Utilities/ObjectFactory.d.ts +19 -22
  126. package/src/Utilities/ObjectFactory.js +51 -60
  127. package/src/Utilities/Services/CellPopupService.d.ts +23 -0
  128. package/src/Utilities/Services/CellPopupService.js +138 -0
  129. package/src/Utilities/Services/Interface/IReportService.d.ts +1 -1
  130. package/src/Utilities/Services/Interface/IThemeService.d.ts +8 -0
  131. package/src/Utilities/Services/ModuleService.js +1 -3
  132. package/src/Utilities/Services/ReportService.d.ts +1 -1
  133. package/src/Utilities/Services/ThemeService.d.ts +3 -0
  134. package/src/Utilities/Services/ThemeService.js +33 -1
  135. package/src/Utilities/Services/ValidationService.js +11 -11
  136. package/src/View/AdaptableView.js +3 -3
  137. package/src/View/AdaptableViewFactory.js +4 -2
  138. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ColumnsList.js +2 -2
  139. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/EntitlementsForm.js +1 -1
  140. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.js +1 -1
  141. package/src/View/Alert/Wizard/AlertButtonsEditor.js +2 -2
  142. package/src/View/Alert/Wizard/AlertRulesWizardSection.d.ts +1 -1
  143. package/src/View/Alert/Wizard/AlertRulesWizardSection.js +4 -3
  144. package/src/View/CalculatedColumn/Wizard/CalculatedColumnExpressionWizardSection.js +1 -1
  145. package/src/View/CalculatedColumn/Wizard/CalculatedColumnWizard.js +1 -1
  146. package/src/View/Charting/useChartingElements.js +8 -3
  147. package/src/View/Comments/CommentsEditor.d.ts +7 -0
  148. package/src/View/Comments/CommentsEditor.js +100 -0
  149. package/src/View/Comments/CommentsPopup.d.ts +2 -0
  150. package/src/View/Comments/CommentsPopup.js +87 -0
  151. package/src/View/Components/AdaptableObjectList/AdaptableObjectList.js +2 -1
  152. package/src/View/Components/CellPopup/index.js +1 -1
  153. package/src/View/Components/FilterForm/FilterForm.js +8 -2
  154. package/src/View/Components/FilterForm/ListBoxFilterForm.js +1 -3
  155. package/src/View/Components/FilterForm/QuickFilterForm.js +5 -4
  156. package/src/View/Components/FilterForm/QuickFilterValues.d.ts +2 -2
  157. package/src/View/Components/FilterForm/QuickFilterValues.js +4 -3
  158. package/src/View/Components/Popups/GridCellPopup/GridCellPopup.d.ts +5 -0
  159. package/src/View/Components/Popups/GridCellPopup/GridCellPopup.js +67 -0
  160. package/src/View/Components/Popups/GridCellPopup/index.d.ts +1 -0
  161. package/src/View/Components/Popups/GridCellPopup/index.js +5 -0
  162. package/src/View/Components/Selectors/ColumnSelector.d.ts +1 -0
  163. package/src/View/Components/Selectors/ColumnSelector.js +2 -1
  164. package/src/View/Components/Selectors/PermittedValuesSelector.d.ts +5 -4
  165. package/src/View/Components/Selectors/PermittedValuesSelector.js +25 -3
  166. package/src/View/Components/ToolPanel/ToolPanelWrapper.js +1 -4
  167. package/src/View/Dashboard/ModuleToolbarWrapper.js +1 -1
  168. package/src/View/Dashboard/PinnedDashboard.js +2 -1
  169. package/src/View/DataImport/DataImportWizard/sections/DataPreview.js +2 -2
  170. package/src/View/Export/Wizard/ReportRowsWizardSection.js +3 -1
  171. package/src/View/GridFilter/GridFilterExpressionEditor.js +1 -1
  172. package/src/View/GridFilter/GridFilterPopup.js +10 -8
  173. package/src/View/GridFilter/GridFilterViewPanel.js +14 -11
  174. package/src/View/GridFilter/NamedQuerySelector.js +1 -1
  175. package/src/View/GridFilter/useGridFilterExpressionEditor.d.ts +3 -0
  176. package/src/View/GridFilter/useGridFilterExpressionEditor.js +17 -6
  177. package/src/View/GridFilter/useGridFilterOptionsForExpressionEditor.js +5 -23
  178. package/src/View/GridInfo/GridInfoPopup/GridInfoPopup.js +3 -2
  179. package/src/View/Layout/Wizard/getGridFilterPreview.d.ts +6 -0
  180. package/src/View/Layout/Wizard/getGridFilterPreview.js +16 -0
  181. package/src/View/Layout/Wizard/sections/FilterSection.js +1 -1
  182. package/src/View/Layout/Wizard/sections/GridFilterSection.js +4 -4
  183. package/src/View/NamedQuery/EditCurrentQueryButton.js +1 -1
  184. package/src/View/NamedQuery/Wizard/NamedQueryExpressionWizardSection.js +1 -1
  185. package/src/View/Notes/NoteEditor.d.ts +8 -0
  186. package/src/View/Notes/NoteEditor.js +33 -0
  187. package/src/View/Notes/NotesPopup.d.ts +2 -2
  188. package/src/View/Notes/NotesPopup.js +78 -55
  189. package/src/View/PlusMinus/MovePlusMinus.d.ts +7 -0
  190. package/src/View/PlusMinus/MovePlusMinus.js +27 -0
  191. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsSummary.js +0 -9
  192. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsWizard.js +0 -4
  193. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/isSettingsValid.js +2 -8
  194. package/src/View/Schedule/Wizard/ScheduleWizard.js +0 -8
  195. package/src/View/StyledColumn/Wizard/StyledColumnBadgeSection.js +3 -1
  196. package/src/View/StyledColumn/Wizard/StyledColumnWizard.js +1 -2
  197. package/src/agGrid/Adaptable.d.ts +7 -0
  198. package/src/agGrid/Adaptable.js +49 -35
  199. package/src/agGrid/BadgeRenderer.js +9 -5
  200. package/src/agGrid/agGridHelper.d.ts +2 -1
  201. package/src/agGrid/agGridHelper.js +15 -3
  202. package/src/agGrid/agGridMenuHelper.d.ts +2 -0
  203. package/src/agGrid/agGridMenuHelper.js +73 -25
  204. package/src/components/Datepicker/index.js +4 -4
  205. package/src/components/ExpressionEditor/ExpressionPreview.d.ts +7 -0
  206. package/src/components/ExpressionEditor/ExpressionPreview.js +25 -0
  207. package/src/components/ExpressionEditor/QueryBuilder/QueryBuilder.js +2 -2
  208. package/src/components/ExpressionEditor/QueryBuilder/QueryBuilderInputs.d.ts +6 -0
  209. package/src/components/ExpressionEditor/QueryBuilder/QueryBuilderInputs.js +40 -11
  210. package/src/components/ExpressionEditor/QueryBuilder/QueryPredicateBuilder.js +14 -2
  211. package/src/components/ExpressionEditor/QueryBuilder/booleanExpressions.js +1 -0
  212. package/src/components/ExpressionEditor/QueryBuilder/utils.js +1 -1
  213. package/src/components/ExpressionEditor/index.js +4 -7
  214. package/src/components/InputGroup/InputGroup.d.ts +7 -0
  215. package/src/components/InputGroup/InputGroup.js +12 -0
  216. package/src/components/InputGroup/index.d.ts +1 -0
  217. package/src/components/InputGroup/index.js +4 -0
  218. package/src/components/OverlayTrigger/index.js +7 -2
  219. package/src/components/Select/Select.d.ts +1 -2
  220. package/src/components/Select/Select.js +63 -23
  221. package/src/components/Toastify/index.d.ts +2 -2
  222. package/src/components/Toastify/index.js +1 -1
  223. package/src/components/icons/comments.d.ts +3 -0
  224. package/src/components/icons/comments.js +7 -0
  225. package/src/components/icons/index.js +3 -1
  226. package/src/env.d.ts +3 -1
  227. package/src/env.js +3 -1
  228. package/src/metamodel/adaptable.metamodel.d.ts +72 -158
  229. package/src/metamodel/adaptable.metamodel.js +128 -260
  230. package/src/parser/src/parser.d.ts +2 -0
  231. package/src/parser/src/parser.js +1880 -705
  232. package/src/parser/src/predicate/mapQlPredicateToExpression.js +5 -2
  233. package/src/parser/src/predicate/types.d.ts +1 -1
  234. package/src/parser/src/types.d.ts +1 -1
  235. package/src/renderReactRoot.js +15 -0
  236. package/src/themes/index.js +4 -0
  237. package/src/types.d.ts +10 -13
  238. package/themes/dark.css +3 -3
  239. package/tsconfig.cjs.tsbuildinfo +1 -1
  240. package/src/AdaptableOptions/FinsemblePluginOptions.d.ts +0 -35
  241. package/src/AdaptableOptions/Glue42PluginOptions.d.ts +0 -25
  242. package/src/AdaptableOptions/Glue42WebPluginOptions.d.ts +0 -10
  243. package/src/Api/Events/SelectionChanged.d.ts +0 -16
  244. package/src/Api/FinsembleApi.d.ts +0 -10
  245. package/src/Api/Glue42Api.d.ts +0 -75
  246. package/src/Api/Glue42WebApi.d.ts +0 -10
  247. package/src/PredefinedConfig/Glue42State.d.ts +0 -46
  248. package/src/View/Notes/NotesListing.d.ts +0 -2
  249. package/src/View/Notes/NotesListing.js +0 -88
  250. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsGlue42.d.ts +0 -9
  251. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsGlue42.js +0 -25
  252. package/src/bundle-dependencies/bundles/react-toastify/components/CloseButton.d.ts +0 -9
  253. package/src/bundle-dependencies/bundles/react-toastify/components/Icons.d.ts +0 -24
  254. package/src/bundle-dependencies/bundles/react-toastify/components/ProgressBar.d.ts +0 -59
  255. package/src/bundle-dependencies/bundles/react-toastify/components/Toast.d.ts +0 -3
  256. package/src/bundle-dependencies/bundles/react-toastify/components/ToastContainer.d.ts +0 -3
  257. package/src/bundle-dependencies/bundles/react-toastify/components/Transitions.d.ts +0 -6
  258. package/src/bundle-dependencies/bundles/react-toastify/components/index.d.ts +0 -6
  259. package/src/bundle-dependencies/bundles/react-toastify/core/eventManager.d.ts +0 -39
  260. package/src/bundle-dependencies/bundles/react-toastify/core/index.d.ts +0 -2
  261. package/src/bundle-dependencies/bundles/react-toastify/core/toast.d.ts +0 -41
  262. package/src/bundle-dependencies/bundles/react-toastify/hooks/index.d.ts +0 -2
  263. package/src/bundle-dependencies/bundles/react-toastify/hooks/useToast.d.ts +0 -10
  264. package/src/bundle-dependencies/bundles/react-toastify/hooks/useToastContainer.d.ts +0 -23
  265. package/src/bundle-dependencies/bundles/react-toastify/index.d.ts +0 -5
  266. package/src/bundle-dependencies/bundles/react-toastify/index.js +0 -1
  267. package/src/bundle-dependencies/bundles/react-toastify/inject-style.d.ts +0 -8
  268. package/src/bundle-dependencies/bundles/react-toastify/types/index.d.ts +0 -269
  269. package/src/bundle-dependencies/bundles/react-toastify/utils/collapseToast.d.ts +0 -5
  270. package/src/bundle-dependencies/bundles/react-toastify/utils/constant.d.ts +0 -23
  271. package/src/bundle-dependencies/bundles/react-toastify/utils/cssTransition.d.ts +0 -43
  272. package/src/bundle-dependencies/bundles/react-toastify/utils/index.d.ts +0 -5
  273. package/src/bundle-dependencies/bundles/react-toastify/utils/mapper.d.ts +0 -2
  274. package/src/bundle-dependencies/bundles/react-toastify/utils/propValidator.d.ts +0 -9
  275. /package/src/AdaptableOptions/{FinsemblePluginOptions.js → CommentsOptions.js} +0 -0
  276. /package/src/AdaptableOptions/{Glue42PluginOptions.js → InteropioPluginOptions.js} +0 -0
  277. /package/src/{AdaptableOptions/Glue42WebPluginOptions.js → Api/CommentApi.js} +0 -0
  278. /package/src/Api/Events/{SelectionChanged.js → CalculatedColumnChanged.js} +0 -0
  279. /package/src/Api/{FinsembleApi.js → Events/CellSelectionChanged.js} +0 -0
  280. /package/src/Api/{Glue42Api.js → Events/CommentsChangedInfo.js} +0 -0
  281. /package/src/Api/{Glue42WebApi.js → Events/RowSelectionChanged.js} +0 -0
  282. /package/src/Api/Internal/{ExpressionnternalApi.d.ts → ExpressionInternalApi.d.ts} +0 -0
  283. /package/src/Api/Internal/{ExpressionnternalApi.js → ExpressionInternalApi.js} +0 -0
  284. /package/src/Api/{NotesAPi.js → InteropioPluginApi.js} +0 -0
  285. /package/src/{PredefinedConfig/Glue42State.js → Api/NotesApi.js} +0 -0
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DEFAULT_ADAPTABLE_COLUMN_MENU_ORDER = exports.DEFAULT_ADAPTABLE_CONTEXT_MENU_ORDER = void 0;
3
+ exports.DEFAULT_ADAPTABLE_COLUMN_MENU_ORDER = exports.DEFAULT_ADAPTABLE_CONTEXT_MENU_STRUCTURE = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const ModuleConstants = tslib_1.__importStar(require("../Utilities/Constants/ModuleConstants"));
6
- exports.DEFAULT_ADAPTABLE_CONTEXT_MENU_ORDER = [
6
+ exports.DEFAULT_ADAPTABLE_CONTEXT_MENU_STRUCTURE = [
7
7
  ModuleConstants.SettingsPanelModuleId,
8
8
  ModuleConstants.DashboardModuleId,
9
9
  ModuleConstants.ToolPanelModuleId,
@@ -21,8 +21,13 @@ exports.DEFAULT_ADAPTABLE_CONTEXT_MENU_ORDER = [
21
21
  ModuleConstants.CalculatedColumnModuleId,
22
22
  ModuleConstants.ExportModuleId,
23
23
  ModuleConstants.ColumnFilterModuleId,
24
- ModuleConstants.SmartEditModuleId,
25
- ModuleConstants.BulkUpdateModuleId,
24
+ {
25
+ title: 'Edit',
26
+ icon: {
27
+ name: 'edit',
28
+ },
29
+ modules: [ModuleConstants.SmartEditModuleId, ModuleConstants.BulkUpdateModuleId],
30
+ },
26
31
  ModuleConstants.TeamSharingModuleId,
27
32
  ModuleConstants.DataChangeHistoryModuleId,
28
33
  ModuleConstants.DataSetModuleId,
@@ -47,6 +52,7 @@ exports.DEFAULT_ADAPTABLE_CONTEXT_MENU_ORDER = [
47
52
  ModuleConstants.ThemeModuleId,
48
53
  ModuleConstants.ChartingModuleId,
49
54
  ModuleConstants.NotesModuleId,
55
+ ModuleConstants.CommentsModuleId,
50
56
  ];
51
57
  exports.DEFAULT_ADAPTABLE_COLUMN_MENU_ORDER = [
52
58
  ModuleConstants.SettingsPanelModuleId,
@@ -66,8 +72,10 @@ exports.DEFAULT_ADAPTABLE_COLUMN_MENU_ORDER = [
66
72
  ModuleConstants.CalculatedColumnModuleId,
67
73
  ModuleConstants.ExportModuleId,
68
74
  ModuleConstants.ColumnFilterModuleId,
69
- ModuleConstants.SmartEditModuleId,
70
- ModuleConstants.BulkUpdateModuleId,
75
+ {
76
+ title: 'Edit',
77
+ modules: [ModuleConstants.SmartEditModuleId, ModuleConstants.BulkUpdateModuleId],
78
+ },
71
79
  ModuleConstants.TeamSharingModuleId,
72
80
  ModuleConstants.DataChangeHistoryModuleId,
73
81
  ModuleConstants.DataSetModuleId,
@@ -1,4 +1,4 @@
1
- import { BaseContext } from '../../types';
1
+ import { BaseContext, CellAddress } from '../../types';
2
2
  /**
3
3
  * Options for managing AdapTable Notes
4
4
  */
@@ -12,12 +12,5 @@ export interface NotesOptions<TData = any> {
12
12
  * Context used when determining if a Note can be added to a Cell
13
13
  */
14
14
  export interface NotableCellContext extends BaseContext {
15
- /**
16
- * Value in Primary Key Column
17
- */
18
- primaryKeyValue: string;
19
- /**
20
- * Column where Note will be displayed
21
- */
22
- columnId: string;
15
+ address: CellAddress;
23
16
  }
@@ -39,12 +39,13 @@ import { StyledColumnApi } from './StyledColumnApi';
39
39
  import { OptionsApi } from './OptionsApi';
40
40
  import { ActionColumnApi } from './ActionColumnApi';
41
41
  import { ActionRowApi } from './ActionRowApi';
42
- import { NotesApi } from './NotesAPi';
42
+ import { NotesApi } from './NotesApi';
43
43
  import { Fdc3Api } from './Fdc3Api';
44
44
  import { DataImportApi } from './DataImportApi';
45
45
  import { GridFilterApi } from './GridFilterApi';
46
46
  import { NamedQueryApi } from './NamedQueryApi';
47
47
  import { ColumnFilterApi } from './ColumnFilterApi';
48
+ import { CommentApi } from './CommentApi';
48
49
  /**
49
50
  *
50
51
  * The `AdaptableApi` provides developers with run-time access to AdapTable.
@@ -228,6 +229,10 @@ export interface AdaptableApi {
228
229
  * Provides access to the Notes Module
229
230
  */
230
231
  notesApi: NotesApi;
232
+ /**
233
+ * Provides access to the Comments Module
234
+ */
235
+ commentApi: CommentApi;
231
236
  /**
232
237
  * Provides access to the Data Import Module
233
238
  */
@@ -0,0 +1,58 @@
1
+ import { CommentThread } from '../PredefinedConfig/CommentState';
2
+ import { CellAddress } from '../PredefinedConfig/CellAddress';
3
+ import { AdaptableComment } from '../types';
4
+ /**
5
+ * Provides run-time access to Notes Module and related State
6
+ */
7
+ export interface CommentApi {
8
+ /**
9
+ * Add comment to comment thread
10
+ *
11
+ * @param comment comment
12
+ * @param address where the comment should be added
13
+ */
14
+ addComment(commentText: string, address: CellAddress): void;
15
+ /**
16
+ * Edit comment
17
+ *
18
+ * @param comment Comment to edit
19
+ * @param cellAddress Location of the comment, if not provided all comments will be traversed to find the comment
20
+ */
21
+ editComment(comment: AdaptableComment, cellAddress?: CellAddress): void;
22
+ /**
23
+ * Delete a comment
24
+ * @param address Location of the comment, if not provided all comments will be traversed to find the comment
25
+ */
26
+ deleteComment(comment: AdaptableComment, cellAddress: CellAddress): void;
27
+ /**
28
+ * Gets comments on a particular cell
29
+ * @param CellAddress
30
+ */
31
+ getComments(cellAddress: CellAddress): AdaptableComment[];
32
+ /**
33
+ * Delete all comments on a particular cell
34
+ * @param cellAddress
35
+ */
36
+ deleteCommentThread(cellAddress: CellAddress): void;
37
+ /**
38
+ * Returns cell comments at the given address
39
+ * @param cellAddress
40
+ */
41
+ getCommentThread(cellAddress: CellAddress): CommentThread | undefined;
42
+ /**
43
+ * Returns all comment threads
44
+ */
45
+ getCommentThreads(): CommentThread[];
46
+ /**
47
+ * Called to add a new comment thread
48
+ *
49
+ * @param commentThread
50
+ */
51
+ addCommentThread(commentThread: CommentThread): void;
52
+ /**
53
+ * Called to set all cell comments
54
+ *
55
+ * @param commentThreads new cell comments
56
+ */
57
+ loadCommentThreads(commentThreads: CommentThread[]): void;
58
+ }
@@ -1,4 +1,6 @@
1
- import { SelectionChangedInfo, LiveDataChangedInfo, DashboardChangedInfo, ThemeChangedInfo, AlertFiredInfo, LayoutChangedInfo, AdaptableReadyInfo, CustomToolbarConfiguredInfo, CellChangedInfo, SystemStatusMessageDisplayedInfo, AdaptableStateChangedInfo, FlashingCellDisplayedInfo, GridDataChangedInfo, TeamSharingEntityChangedInfo, ActionRowSubmittedInfo, DataSetSelectedInfo, AdaptableStateReloadedInfo, GridSortedInfo, ScheduleTriggeredInfo, ChartChangedInfo, ThemeEditedInfo, Fdc3MessageInfo, DataImportedInfo, ColumnFilterAppliedInfo, GridFilterAppliedInfo } from '../types';
1
+ import { ActionRowSubmittedInfo, AdaptableReadyInfo, AdaptableStateChangedInfo, AdaptableStateReloadedInfo, AlertFiredInfo, CellChangedInfo, CellSelectionChangedInfo, ChartChangedInfo, ColumnFilterAppliedInfo, CustomToolbarConfiguredInfo, DashboardChangedInfo, DataImportedInfo, DataSetSelectedInfo, Fdc3MessageInfo, FlashingCellDisplayedInfo, GridDataChangedInfo, GridFilterAppliedInfo, GridSortedInfo, LayoutChangedInfo, LiveDataChangedInfo, RowSelectionChangedInfo, ScheduleTriggeredInfo, SystemStatusMessageDisplayedInfo, TeamSharingEntityChangedInfo, ThemeChangedInfo, ThemeEditedInfo } from '../types';
2
+ import { CalculatedColumnChangedInfo } from './Events/CalculatedColumnChanged';
3
+ import { CommentsChangedInfo } from './Events/CommentsChangedInfo';
2
4
  /**
3
5
  * Responsible for publishing the many Events that AdapTable fires
4
6
  */
@@ -89,16 +91,27 @@ export interface EventApi {
89
91
  */
90
92
  off(eventName: 'GridDataChanged', callback: (gridDataChangedInfo: GridDataChangedInfo) => void): void;
91
93
  /**
92
- * Event fired whenever the Cell or Row **Selection in AdapTable changes**.
93
- * @param eventName SelectionChanged
94
- * @param callback SelectionChangedInfo which contains information of any cells or rows that are selected.
94
+ * Event fired whenever the Cell **Selection in AdapTable changes**.
95
+ * @param eventName CellSelectionChanged
96
+ * @param callback CellSelectionChangedInfo which contains information of any cells that are selected.
95
97
  * @returns the unsubscribe function
96
98
  */
97
- on(eventName: 'SelectionChanged', callback: (selectionChangedInfo: SelectionChangedInfo) => void): VoidFunction;
99
+ on(eventName: 'CellSelectionChanged', callback: (cellSelectionChangedInfo: CellSelectionChangedInfo) => void): VoidFunction;
98
100
  /**
99
- * Unsubscribe from SelectionChanged
101
+ * Unsubscribe from CellSelectionChanged
100
102
  */
101
- off(eventName: 'SelectionChanged', callback: (selectionChangedInfo: SelectionChangedInfo) => void): void;
103
+ off(eventName: 'CellSelectionChanged', callback: (cellSelectionChangedInfo: CellSelectionChangedInfo) => void): void;
104
+ /**
105
+ * Event fired whenever the Row **Selection in AdapTable changes**.
106
+ * @param eventName RowSelectionChanged
107
+ * @param callback RowSelectionChangedInfo which contains information of any rows that are selected.
108
+ * @returns the unsubscribe function
109
+ */
110
+ on(eventName: 'RowSelectionChanged', callback: (rowSelectionChangedInfo: RowSelectionChangedInfo) => void): VoidFunction;
111
+ /**
112
+ * Unsubscribe from RowSelectionChanged
113
+ */
114
+ off(eventName: 'RowSelectionChanged', callback: (rowSelectionChangedInfo: RowSelectionChangedInfo) => void): void;
102
115
  /**
103
116
  * Event fired whenever the selected theme of AdapTable is changed
104
117
  * @param eventName ThemeChanged
@@ -171,14 +184,25 @@ export interface EventApi {
171
184
  * @param callback LayoutChanged which includes just the name of the currently selected Layout.
172
185
  * @returns the unsubscribe function
173
186
  */
174
- on(eventName: 'LayoutChanged', callback: (LayoutChangedInfo: LayoutChangedInfo) => void): VoidFunction;
187
+ on(eventName: 'LayoutChanged', callback: (layoutChangedInfo: LayoutChangedInfo) => void): VoidFunction;
175
188
  /**
176
189
  * Unsubscribe from LayoutChanged
177
190
  */
178
- off(eventName: 'LayoutChanged', callback: (LayoutChangedInfo: LayoutChangedInfo) => void): void;
191
+ off(eventName: 'LayoutChanged', callback: (layoutChangedInfo: LayoutChangedInfo) => void): void;
192
+ /**
193
+ * Event fired whenever a Calculated Columns is created / updated / deleted in AdapTable
194
+ * @param eventName CalculatedColumnChanged
195
+ * @param callback CalculatedColumnChanged which includes the action and details of the Calculated Column
196
+ * @returns the unsubscribe function
197
+ */
198
+ on(eventName: 'CalculatedColumnChanged', callback: (calculatedColumnChangedInfo: CalculatedColumnChangedInfo) => void): VoidFunction;
199
+ /**
200
+ * Unsubscribe from CalculatedColumnChanged
201
+ */
202
+ off(eventName: 'CalculatedColumnChanged', callback: (calculatedColumnChangedInfo: CalculatedColumnChangedInfo) => void): void;
179
203
  /**
180
204
  * Event fired whenever **Configure Button is clicked in a Custom Toolbar**
181
- * @param eventName DashboardChanged
205
+ * @param eventName CustomToolbarConfigured
182
206
  * @param callback CustomToolbarConfiguredInfo which contains the Custom Toolbar
183
207
  * @returns the unsubscribe function
184
208
  */
@@ -223,7 +247,7 @@ export interface EventApi {
223
247
  off(eventName: 'AdaptableStateReloaded', callback: (adaptableStateReloadedInfo: AdaptableStateReloadedInfo) => void): void;
224
248
  /**
225
249
  * Event fired whenever **a change occurs relating to live reports / data**
226
- * Used in conjunction with AdapTable's partners OpenFin, ipushpull or Glue42
250
+ * Used in conjunction with AdapTable's partners OpenFin or ipushpull
227
251
  * @param eventName LiveDataChanged
228
252
  * @param callback LiveDataChangedInfo which includes details of what triggered the event and the live report which is affected.
229
253
  * @returns the unsubscribe function
@@ -272,6 +296,18 @@ export interface EventApi {
272
296
  * @param callbackChartChangedInfo
273
297
  */
274
298
  off(eventName: 'ChartChanged', callback: (chartChangedInfo: ChartChangedInfo) => void): void;
299
+ /**
300
+ * Event fired when Comments are Changed
301
+ * @param eventName CommentsChanged
302
+ * @param callback
303
+ */
304
+ on(eventName: 'CommentsChanged', callback: (commentsChangedInfo: CommentsChangedInfo) => void): () => void;
305
+ /**
306
+ * Unsubscribe from CommentsChanged
307
+ * @param eventName
308
+ * @param callback
309
+ */
310
+ off(eventName: 'CommentsChanged', callback: (commentsChangedInfo: CommentsChangedInfo) => void): void;
275
311
  /**
276
312
  * Fired when Adaptable is up and running - has no arguments.
277
313
  * @param eventName - AdaptableReady
@@ -316,6 +352,6 @@ export interface EventApi {
316
352
  emitSync(eventName: 'DashboardChanged', data?: any): any[];
317
353
  emitSync(eventName: 'FlashingCellDisplayed', data?: any): any[];
318
354
  emitSync(eventName: 'AdaptableDestroy'): any[];
319
- emit(eventName: 'ActionRowSubmitted' | 'AdaptableReady' | 'AlertFired' | 'AdaptableStateChanged' | 'AdaptableStateReloaded' | 'CellChanged' | 'ChartChanged' | 'CheckboxColumnClicked' | 'CustomToolbarConfigured' | 'DashboardChanged' | 'DataImported' | 'DataSetSelected' | 'ColumnFilterApplied' | 'Fdc3Message' | 'GridDataChanged' | 'GridSorted' | 'LayoutChanged' | 'LiveDataChanged' | 'ScheduleTriggered' | 'SearchChanged' | 'SelectionChanged' | 'SystemStatusMessageDisplayed' | 'TeamSharingEntityChanged' | 'ThemeChanged' | 'ThemeEdited' | 'GridFilterApplied', data?: any): Promise<any>;
355
+ emit(eventName: 'ActionRowSubmitted' | 'AdaptableReady' | 'AlertFired' | 'AdaptableStateChanged' | 'AdaptableStateReloaded' | 'CellChanged' | 'ChartChanged' | 'CheckboxColumnClicked' | 'CustomToolbarConfigured' | 'DashboardChanged' | 'DataImported' | 'DataSetSelected' | 'ColumnFilterApplied' | 'Fdc3Message' | 'GridDataChanged' | 'GridSorted' | 'LayoutChanged' | 'CalculatedColumnChanged' | 'LiveDataChanged' | 'ScheduleTriggered' | 'SearchChanged' | 'CellSelectionChanged' | 'RowSelectionChanged' | 'SystemStatusMessageDisplayed' | 'TeamSharingEntityChanged' | 'ThemeChanged' | 'ThemeEdited' | 'GridFilterApplied' | 'CommentsChanged', data?: any): Promise<any>;
320
356
  destroy(): void;
321
357
  }
@@ -0,0 +1,19 @@
1
+ import { CalculatedColumn } from '../../PredefinedConfig/CalculatedColumnState';
2
+ import { BaseEventInfo } from './BaseEventInfo';
3
+ /**
4
+ * EventInfo returned by CalculatedColumnChanged event
5
+ */
6
+ export interface CalculatedColumnChangedInfo extends BaseEventInfo {
7
+ /**
8
+ * What caused CalculatedColumn State to change (i.e. Add, Edit, Delete)
9
+ */
10
+ actionName: string;
11
+ /**
12
+ * Calculated Column that has been added, edited or deleted
13
+ */
14
+ calculatedColumn: CalculatedColumn;
15
+ /**
16
+ * AST for Current Calculated Column Expression
17
+ */
18
+ calculatedColumnExpressionAST: any;
19
+ }
@@ -0,0 +1,11 @@
1
+ import { SelectedCellInfo } from '../../PredefinedConfig/Selection/SelectedCellInfo';
2
+ import { BaseEventInfo } from './BaseEventInfo';
3
+ /**
4
+ * Event Info published by CellSelectionChanged event
5
+ */
6
+ export interface CellSelectionChangedInfo extends BaseEventInfo {
7
+ /**
8
+ * Details of Cells currently selected in the Grid
9
+ */
10
+ selectedCellInfo: SelectedCellInfo;
11
+ }
@@ -0,0 +1,5 @@
1
+ import { CommentThread } from '../../types';
2
+ import { BaseEventInfo } from './BaseEventInfo';
3
+ export interface CommentsChangedInfo extends BaseEventInfo {
4
+ gridCellComments: CommentThread[];
5
+ }
@@ -7,7 +7,7 @@ export interface LiveDataChangedInfo extends BaseEventInfo {
7
7
  /**
8
8
  * Which Adaptable partner is the export destination for the live data
9
9
  */
10
- reportDestination: 'OpenFin' | 'ipushpull' | 'Glue42';
10
+ reportDestination: 'OpenFin' | 'ipushpull';
11
11
  /**
12
12
  * What triggered the event to fire
13
13
  */
@@ -22,7 +22,7 @@ export interface LiveDataChangedInfo extends BaseEventInfo {
22
22
  */
23
23
  export interface LiveReport {
24
24
  /**
25
- * For OpenFin this is the workbook name; for iPushpull the page name; for Glue42 the Spreadsheet name
25
+ * For OpenFin this is the workbook name; for iPushpull the page name;
26
26
  */
27
27
  pageName: string;
28
28
  /**
@@ -32,5 +32,5 @@ export interface LiveReport {
32
32
  /**
33
33
  * Where the live data is being sent
34
34
  */
35
- reportDestination: 'OpenfinExcel' | 'ipushpull' | 'Glue42';
35
+ reportDestination: 'OpenfinExcel' | 'ipushpull';
36
36
  }
@@ -0,0 +1,11 @@
1
+ import { SelectedRowInfo } from '../../PredefinedConfig/Selection/SelectedRowInfo';
2
+ import { BaseEventInfo } from './BaseEventInfo';
3
+ /**
4
+ * Event Info published by RowSelectionChanged event
5
+ */
6
+ export interface RowSelectionChangedInfo extends BaseEventInfo {
7
+ /**
8
+ * Details of Rows currently selected in the Grid
9
+ */
10
+ selectedRowInfo: SelectedRowInfo;
11
+ }
@@ -301,12 +301,6 @@ export interface GridApi {
301
301
  * @param displayValue Display Value to use
302
302
  */
303
303
  getGridCellsForDisplayValue(columnId: string, displayValue: any): GridCell[] | undefined;
304
- /**
305
- * Gets the count of the cells in a Column that have the given Display Value
306
- * @param columnId ColumnId to lookup
307
- * @param displayValue Display Value to use
308
- */
309
- getCellDisplayValueCount(columnId: string, displayValue: any): number;
310
304
  /**
311
305
  * Retrieves Formatted Value for a given Raw Value in given Column
312
306
  * @param columnId ColumnId to lookup
@@ -23,11 +23,11 @@ export interface GridFilterApi {
23
23
  */
24
24
  clearGridFilter(): void;
25
25
  /**
26
- * Opens the Expression Editor
26
+ * Opens the AdapTableQL UI Components (Expression Editor & Query Builder)
27
27
  *
28
28
  * @param expression current Grid Filter expression
29
29
  */
30
- openExpressionEditorForGridFilter(expression?: string): void;
30
+ openUIEditorForGridFilter(expression?: string): void;
31
31
  /**
32
32
  * Suspends the Grid Filter
33
33
  */
@@ -1,6 +1,6 @@
1
1
  import { IAdaptable } from '../../AdaptableInterfaces/IAdaptable';
2
2
  import { AdaptableInternalApi } from '../Internal/AdaptableInternalApi';
3
- import { AdaptableApi, OptionsApi, SettingsPanelApi } from '../../types';
3
+ import { AdaptableApi, DataImportApi, NamedQueryApi, OptionsApi, SettingsPanelApi } from '../../types';
4
4
  import { AlertApi } from '../AlertApi';
5
5
  import { BulkUpdateApi } from '../BulkUpdateApi';
6
6
  import { CalendarApi } from '../CalendarApi';
@@ -40,12 +40,11 @@ import { StatusBarApi } from '../StatusBarApi';
40
40
  import { StyledColumnApi } from '../StyledColumnApi';
41
41
  import { ActionColumnApi } from '../ActionColumnApi';
42
42
  import { ActionRowApi } from '../ActionRowApi';
43
- import { NotesApi } from '../NotesAPi';
43
+ import { NotesApi } from '../NotesApi';
44
44
  import { Fdc3Api } from '../Fdc3Api';
45
- import { DataImportApiImpl } from './DataImportApiImpl';
46
45
  import { GridFilterApi } from '../GridFilterApi';
47
- import { NamedQueryApiImpl } from './NamedQueryApiImpl';
48
46
  import { ColumnFilterApi } from '../ColumnFilterApi';
47
+ import { CommentApi } from '../CommentApi';
49
48
  export declare class AdaptableApiImpl implements AdaptableApi {
50
49
  protected adaptable: IAdaptable;
51
50
  internalApi: AdaptableInternalApi;
@@ -93,9 +92,10 @@ export declare class AdaptableApiImpl implements AdaptableApi {
93
92
  statusBarApi: StatusBarApi;
94
93
  notesApi: NotesApi;
95
94
  fdc3Api: Fdc3Api;
96
- dataImportApi: DataImportApiImpl;
95
+ dataImportApi: DataImportApi;
97
96
  gridFilterApi: GridFilterApi;
98
- namedQueryApi: NamedQueryApiImpl;
97
+ namedQueryApi: NamedQueryApi;
98
+ commentApi: CommentApi;
99
99
  private destroyed;
100
100
  constructor(adaptable: IAdaptable);
101
101
  /**
@@ -49,6 +49,7 @@ const DataImportApiImpl_1 = require("./DataImportApiImpl");
49
49
  const GridFilterApiImpl_1 = require("./GridFilterApiImpl");
50
50
  const NamedQueryApiImpl_1 = require("./NamedQueryApiImpl");
51
51
  const ColumnFilterApiImpl_1 = require("./ColumnFilterApiImpl");
52
+ const CommentsApiImpl_1 = require("./CommentsApiImpl");
52
53
  class AdaptableApiImpl {
53
54
  constructor(adaptable) {
54
55
  this.adaptable = adaptable;
@@ -101,6 +102,7 @@ class AdaptableApiImpl {
101
102
  this.dataImportApi = new DataImportApiImpl_1.DataImportApiImpl(adaptable);
102
103
  this.gridFilterApi = new GridFilterApiImpl_1.GridFilterApiImpl(adaptable);
103
104
  this.columnFilterApi = new ColumnFilterApiImpl_1.ColumnFilterApiImpl(adaptable);
105
+ this.commentApi = new CommentsApiImpl_1.CommentsApiImpl(adaptable);
104
106
  // adaptable internal api
105
107
  this.internalApi = new AdaptableInternalApi_1.AdaptableInternalApi(adaptable);
106
108
  }
@@ -0,0 +1,15 @@
1
+ import { ApiBase } from './ApiBase';
2
+ import { CellAddress } from '../../PredefinedConfig/CellAddress';
3
+ import { CommentThread, AdaptableComment } from '../../types';
4
+ import { CommentApi } from '../CommentApi';
5
+ export declare class CommentsApiImpl extends ApiBase implements CommentApi {
6
+ getComments(address: CellAddress): AdaptableComment[];
7
+ getCommentThread(address: CellAddress): CommentThread | undefined;
8
+ getCommentThreads(): CommentThread[];
9
+ editComment(comment: AdaptableComment, address: CellAddress): void;
10
+ deleteComment(comment: AdaptableComment, address: CellAddress): void;
11
+ addComment(commentText: AdaptableComment['Value'], address: CellAddress): void;
12
+ addCommentThread(commentThread: CommentThread): void;
13
+ deleteCommentThread(cellAddress: CellAddress): void;
14
+ loadCommentThreads(cellComments: CommentThread[]): void;
15
+ }
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CommentsApiImpl = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const CommentRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/CommentsRedux"));
6
+ const ApiBase_1 = require("./ApiBase");
7
+ const ObjectFactory_1 = tslib_1.__importDefault(require("../../Utilities/ObjectFactory"));
8
+ const AdaptableHelper_1 = tslib_1.__importDefault(require("../../Utilities/Helpers/AdaptableHelper"));
9
+ class CommentsApiImpl extends ApiBase_1.ApiBase {
10
+ getComments(address) {
11
+ return CommentRedux.GetCommentsSelector(this.getAdaptableState().Comment, address);
12
+ }
13
+ getCommentThread(address) {
14
+ return CommentRedux.GetCellCommentSelector(this.getAdaptableState().Comment, address);
15
+ }
16
+ getCommentThreads() {
17
+ return this.getAdaptableState().Comment.CommentThreads;
18
+ }
19
+ editComment(comment, address) {
20
+ this.dispatchAction(CommentRedux.CommentsEdit({ comment, cellAddress: address }));
21
+ }
22
+ deleteComment(comment, address) {
23
+ this.dispatchAction(CommentRedux.CommentsDelete({ commentUuid: comment.Uuid, cellAddress: address }));
24
+ }
25
+ addComment(commentText, address) {
26
+ this.dispatchAction(CommentRedux.CommentsAdd({
27
+ comment: commentText
28
+ ? ObjectFactory_1.default.CreateAdaptableComment(commentText, this.adaptable.api)
29
+ : null,
30
+ cellAddress: address,
31
+ }));
32
+ }
33
+ addCommentThread(commentThread) {
34
+ if (!commentThread.Uuid) {
35
+ AdaptableHelper_1.default.addUuidAndSource(commentThread);
36
+ }
37
+ this.dispatchAction(CommentRedux.CommentsCellAdd({ commentThread: commentThread }));
38
+ }
39
+ deleteCommentThread(cellAddress) {
40
+ this.dispatchAction(CommentRedux.CommentsCellDelete({ cellAddress }));
41
+ }
42
+ loadCommentThreads(cellComments) {
43
+ this.dispatchAction(CommentRedux.CommentsSet({ commentThread: cellComments }));
44
+ }
45
+ }
46
+ exports.CommentsApiImpl = CommentsApiImpl;
@@ -4,7 +4,7 @@ import { ExpressionApi } from '../ExpressionApi';
4
4
  import { AdaptableQuery } from '../../PredefinedConfig/Common/AdaptableQuery';
5
5
  import { AdaptableColumnBase } from '../../PredefinedConfig/Common/AdaptableColumn';
6
6
  import { IAdaptable } from '../../AdaptableInterfaces/IAdaptable';
7
- import { ExpressionInternalApi } from '../Internal/ExpressionnternalApi';
7
+ import { ExpressionInternalApi } from '../Internal/ExpressionInternalApi';
8
8
  export declare class ExpressionApiImpl extends ApiBase implements ExpressionApi {
9
9
  internalApi: ExpressionInternalApi;
10
10
  constructor(adaptable: IAdaptable);
@@ -4,11 +4,11 @@ exports.ExpressionApiImpl = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const ApiBase_1 = require("./ApiBase");
6
6
  const parser = tslib_1.__importStar(require("../../parser/src"));
7
- const ExpressionnternalApi_1 = require("../Internal/ExpressionnternalApi");
7
+ const ExpressionInternalApi_1 = require("../Internal/ExpressionInternalApi");
8
8
  class ExpressionApiImpl extends ApiBase_1.ApiBase {
9
9
  constructor(adaptable) {
10
10
  super(adaptable);
11
- this.internalApi = new ExpressionnternalApi_1.ExpressionInternalApi(adaptable);
11
+ this.internalApi = new ExpressionInternalApi_1.ExpressionInternalApi(adaptable);
12
12
  }
13
13
  isValidBooleanExpression(query, module, validationErrorMessage) {
14
14
  const { isValid, errorMessage } = this.adaptable.api.internalApi
@@ -93,8 +93,7 @@ class ExpressionApiImpl extends ApiBase_1.ApiBase {
93
93
  .getExpressionWithColumnFriendlyNames(this.getAdaptableQueryExpression(query));
94
94
  }
95
95
  useCaseSensitivity() {
96
- return this.adaptable.adaptableOptions.expressionOptions
97
- .caseSensitiveExpressions;
96
+ return this.adaptable.adaptableOptions.expressionOptions.caseSensitiveExpressions;
98
97
  }
99
98
  }
100
99
  exports.ExpressionApiImpl = ExpressionApiImpl;
@@ -99,7 +99,6 @@ export declare class GridApiImpl extends ApiBase implements GridApi {
99
99
  getGridCellsForRawValue(columnId: string, rawValue: any): GridCell[] | undefined;
100
100
  getCellRawValueCount(columnId: string, rawValue: any): number;
101
101
  getGridCellsForDisplayValue(columnId: string, displayValue: any): GridCell[] | undefined;
102
- getCellDisplayValueCount(columnId: string, displayValue: any): number;
103
102
  jumpToRow(primaryKeyValue: any): void;
104
103
  jumpToColumn(columnId: string): void;
105
104
  jumpToCell(primaryKeyValue: any, columnId: string): void;
@@ -385,10 +385,6 @@ class GridApiImpl extends ApiBase_1.ApiBase {
385
385
  });
386
386
  return returnGridCells;
387
387
  }
388
- getCellDisplayValueCount(columnId, displayValue) {
389
- const gridCells = this.getGridCellsForDisplayValue(columnId, displayValue);
390
- return gridCells === null || gridCells === void 0 ? void 0 : gridCells.length;
391
- }
392
388
  jumpToRow(primaryKeyValue) {
393
389
  const node = this.adaptable.getRowNodeForPrimaryKey(primaryKeyValue);
394
390
  this.adaptable.jumpToRow(node);
@@ -10,7 +10,7 @@ export declare class GridFilterApiImpl extends ApiBase implements GridFilterApi
10
10
  getCurrentGridFilterExpression(): string | undefined;
11
11
  setGridFilterExpression(filter: string): void;
12
12
  clearGridFilter(): void;
13
- openExpressionEditorForGridFilter(expression?: string): void;
13
+ openUIEditorForGridFilter(expression?: string): void;
14
14
  suspendGridFilter(): void;
15
15
  unSuspendGridFilter(): void;
16
16
  }
@@ -26,7 +26,7 @@ class GridFilterApiImpl extends ApiBase_1.ApiBase {
26
26
  clearGridFilter() {
27
27
  this.dispatchAction(LayoutRedux.LayoutGridFilterClear());
28
28
  }
29
- openExpressionEditorForGridFilter(expression) {
29
+ openUIEditorForGridFilter(expression) {
30
30
  const preparedQuery = expression !== null && expression !== void 0 ? expression : this.getCurrentGridFilterExpression();
31
31
  this.getAdaptableApi().internalApi.showPopupWindow({
32
32
  id: windowFactory_1.WINDOW_GRID_FILTER_EDITOR,
@@ -1,6 +1,6 @@
1
1
  import { ApiBase } from './ApiBase';
2
- import { NotesApi } from '../NotesAPi';
3
- import { AdaptableNote, AdaptableNotes, NoteGridCell, NotesState } from '../../PredefinedConfig/NotesState';
2
+ import { NotesApi } from '../NotesApi';
3
+ import { AdaptableNote, AdaptableNotes, NotesState } from '../../PredefinedConfig/NotesState';
4
4
  export declare class NotesApiImpl extends ApiBase implements NotesApi {
5
5
  addNote(noteStr: string, primaryKeyValue: any, columnId: string): void;
6
6
  editNote(note: AdaptableNote): void;
@@ -13,8 +13,4 @@ export declare class NotesApiImpl extends ApiBase implements NotesApi {
13
13
  ColumnId: string;
14
14
  }): AdaptableNotes;
15
15
  getNoteByUuid(uuid: string): AdaptableNote | undefined;
16
- showNotes(noteGridCell: NoteGridCell, editMode?: boolean): void;
17
- hideNote(): void;
18
- getOpenNoteGridCell(): NoteGridCell | undefined;
19
- getNotePopupEditMode(): boolean;
20
16
  }
@@ -4,7 +4,6 @@ exports.NotesApiImpl = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const ApiBase_1 = require("./ApiBase");
6
6
  const NotesRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/NotesRedux"));
7
- const SystemRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/SystemRedux"));
8
7
  class NotesApiImpl extends ApiBase_1.ApiBase {
9
8
  addNote(noteStr, primaryKeyValue, columnId) {
10
9
  const note = {
@@ -24,8 +23,7 @@ class NotesApiImpl extends ApiBase_1.ApiBase {
24
23
  this.dispatchAction(NotesRedux.NotesEdit(note));
25
24
  }
26
25
  updateNoteText(noteStr, note) {
27
- note.Value = noteStr;
28
- this.editNote(note);
26
+ this.editNote(Object.assign(Object.assign({}, note), { Value: noteStr }));
29
27
  }
30
28
  deleteNote(note) {
31
29
  this.dispatchAction(NotesRedux.NotesDelete(note));
@@ -42,17 +40,5 @@ class NotesApiImpl extends ApiBase_1.ApiBase {
42
40
  getNoteByUuid(uuid) {
43
41
  return this.getAllNotes().find((note) => note.Uuid === uuid);
44
42
  }
45
- showNotes(noteGridCell, editMode) {
46
- this.dispatchAction(SystemRedux.SystemNotesShow(noteGridCell, editMode));
47
- }
48
- hideNote() {
49
- this.dispatchAction(SystemRedux.SystemNoteHide());
50
- }
51
- getOpenNoteGridCell() {
52
- return SystemRedux.SystemNotesSelector(this.getAdaptableState().System);
53
- }
54
- getNotePopupEditMode() {
55
- return SystemRedux.SystemNotesEditModeSelector(this.getAdaptableState().System);
56
- }
57
43
  }
58
44
  exports.NotesApiImpl = NotesApiImpl;
@@ -5,6 +5,7 @@ import { CustomSortOptions } from '../../AdaptableOptions/CustomSortOptions';
5
5
  import { Fdc3Options } from '../../AdaptableOptions/Fdc3Options';
6
6
  import { ExpressionOptions } from '../../AdaptableOptions/ExpressionOptions';
7
7
  import { ColumnFilterOptions } from '../../AdaptableOptions/ColumnFilterOptions';
8
+ import { CommentsOptions } from '../../AdaptableOptions/CommentsOptions';
8
9
  export declare class OptionsApiImpl extends ApiBase implements OptionsApi {
9
10
  getAdaptableId(): string;
10
11
  getAdaptableStateKey(): string;
@@ -19,6 +20,7 @@ export declare class OptionsApiImpl extends ApiBase implements OptionsApi {
19
20
  getCalendarOptions(): CalendarOptions;
20
21
  getColumnOptions(): ColumnOptions;
21
22
  getNotesOptions(): NotesOptions;
23
+ getCommentsOptions(): Readonly<CommentsOptions<any>>;
22
24
  getCustomSortOptions(): CustomSortOptions;
23
25
  getContainerOptions(): ContainerOptions;
24
26
  getDataSetOptions(): DataSetOptions;
@@ -42,6 +42,9 @@ class OptionsApiImpl extends ApiBase_1.ApiBase {
42
42
  getNotesOptions() {
43
43
  return this.getOptions().notesOptions;
44
44
  }
45
+ getCommentsOptions() {
46
+ return this.getOptions().commentsOptions;
47
+ }
45
48
  getCustomSortOptions() {
46
49
  return this.getOptions().customSortOptions;
47
50
  }