@adaptabletools/adaptable 23.0.0-canary.3 → 23.0.0-canary.5

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 (277) hide show
  1. package/index.css +116 -61
  2. package/package.json +9 -4
  3. package/src/AdaptableOptions/DefaultAdaptableOptions.js +0 -4
  4. package/src/AdaptableOptions/EditOptions.d.ts +2 -2
  5. package/src/AdaptableOptions/FilterOptions.d.ts +0 -7
  6. package/src/AdaptableState/Common/AdaptableForm.d.ts +18 -1
  7. package/src/AdaptableState/Common/AdaptableForm.js +31 -0
  8. package/src/AdaptableState/Common/AggregationColumns.d.ts +14 -6
  9. package/src/AdaptableState/Common/AggregationColumns.js +27 -2
  10. package/src/AdaptableState/Common/CellDataChangedInfo.d.ts +3 -2
  11. package/src/AdaptableState/Common/ColumnScope.d.ts +4 -0
  12. package/src/AdaptableState/Common/Enums.d.ts +5 -10
  13. package/src/AdaptableState/Common/Enums.js +4 -10
  14. package/src/AdaptableState/PlusMinusState.d.ts +3 -3
  15. package/src/AdaptableState/ShortcutState.d.ts +2 -6
  16. package/src/AdaptableState/StyledColumnState.d.ts +3 -5
  17. package/src/AdaptableState/ThemeState.d.ts +33 -28
  18. package/src/Api/EventApi.d.ts +14 -1
  19. package/src/Api/Events/ThemeChanged.d.ts +6 -0
  20. package/src/Api/Events/ThemeSelected.d.ts +11 -0
  21. package/src/Api/Events/ThemeSelected.js +1 -0
  22. package/src/Api/Implementation/EventApiImpl.js +4 -0
  23. package/src/Api/Implementation/LayoutApiImpl.d.ts +0 -2
  24. package/src/Api/Implementation/LayoutApiImpl.js +0 -14
  25. package/src/Api/Implementation/LayoutHelpers.d.ts +2 -0
  26. package/src/Api/Implementation/LayoutHelpers.js +29 -7
  27. package/src/Api/Implementation/ThemeApiImpl.d.ts +3 -2
  28. package/src/Api/Implementation/ThemeApiImpl.js +19 -15
  29. package/src/Api/Internal/EventInternalApi.d.ts +2 -0
  30. package/src/Api/Internal/EventInternalApi.js +8 -1
  31. package/src/Api/Internal/StyledColumnInternalApi.d.ts +4 -4
  32. package/src/Api/Internal/StyledColumnInternalApi.js +4 -4
  33. package/src/Api/Internal/ThemeInternalApi.d.ts +0 -1
  34. package/src/Api/Internal/ThemeInternalApi.js +0 -10
  35. package/src/Api/LayoutApi.d.ts +1 -8
  36. package/src/Api/ThemeApi.d.ts +6 -2
  37. package/src/Redux/ActionsReducers/ThemeRedux.d.ts +3 -3
  38. package/src/Strategy/CalculatedColumnModule.js +3 -1
  39. package/src/Strategy/FormatColumnModule.js +14 -7
  40. package/src/Strategy/LayoutModule.js +13 -8
  41. package/src/Strategy/StyledColumnModule.js +64 -36
  42. package/src/Utilities/Constants/ReduxConstants.d.ts +2 -2
  43. package/src/Utilities/Constants/ReduxConstants.js +1 -14
  44. package/src/Utilities/Helpers/FormatHelper.js +20 -1
  45. package/src/Utilities/Helpers/SparklineOptionsHelper.d.ts +7 -0
  46. package/src/Utilities/Helpers/SparklineOptionsHelper.js +65 -0
  47. package/src/Utilities/Helpers/StyledColumnGradientHelper.d.ts +23 -1
  48. package/src/Utilities/Helpers/StyledColumnGradientHelper.js +204 -0
  49. package/src/Utilities/Helpers/ThemeHelpers.d.ts +5 -0
  50. package/src/Utilities/Helpers/ThemeHelpers.js +38 -0
  51. package/src/Utilities/Helpers/percentBarPreviewHelper.d.ts +19 -0
  52. package/src/Utilities/Helpers/percentBarPreviewHelper.js +143 -0
  53. package/src/Utilities/ObjectFactory.d.ts +1 -3
  54. package/src/Utilities/ObjectFactory.js +0 -8
  55. package/src/Utilities/Services/CalculatedColumnExpressionService.d.ts +1 -0
  56. package/src/Utilities/Services/CalculatedColumnExpressionService.js +7 -0
  57. package/src/Utilities/Services/CalculatedColumnSyntheticChange.d.ts +4 -0
  58. package/src/Utilities/Services/CalculatedColumnSyntheticChange.js +115 -0
  59. package/src/Utilities/Services/Interface/ICalculatedColumnExpressionService.d.ts +1 -0
  60. package/src/Utilities/Services/ThemeService.js +1 -1
  61. package/src/View/Alert/Wizard/AlertBehaviourWizardSection.js +17 -16
  62. package/src/View/Alert/Wizard/AlertButtonsEditor.js +114 -103
  63. package/src/View/Alert/Wizard/AlertMessageWizardSection.js +13 -14
  64. package/src/View/Alert/Wizard/AlertNotificationWizardSection.js +55 -55
  65. package/src/View/Alert/Wizard/AlertRulesWizardSection.js +3 -2
  66. package/src/View/Alert/Wizard/AlertScheduledWizardSection.js +2 -2
  67. package/src/View/Alert/Wizard/AlertScopeWizardSection.js +31 -39
  68. package/src/View/Alert/Wizard/AlertTypeWizardSection.js +3 -4
  69. package/src/View/CalculatedColumn/Wizard/CalculatedColumnDefinitionWizardSection.js +9 -13
  70. package/src/View/CalculatedColumn/Wizard/CalculatedColumnExpressionWizardSection.js +30 -17
  71. package/src/View/CalculatedColumn/Wizard/CalculatedColumnSettingsWizardSection.js +7 -9
  72. package/src/View/CalculatedColumn/Wizard/CalculatedColumnTypeSection.js +3 -3
  73. package/src/View/CellSummary/CellSummaryViewPanel.js +1 -1
  74. package/src/View/Charting/ChartingWizard/AgChargingWizard/AgChargingWizard.js +3 -10
  75. package/src/View/Charting/ChartingWizard/AgChargingWizard/PreviewChartSection.js +1 -1
  76. package/src/View/Charting/ChartingWizard/AgChargingWizard/SettingsSection.js +35 -52
  77. package/src/View/Charting/ChartingWizard/ExternalChartingWizard/ExternalChartingWizard.js +4 -31
  78. package/src/View/Charting/ChartingWizard/ExternalChartingWizard/PreviewChartSection.d.ts +5 -0
  79. package/src/View/Charting/ChartingWizard/ExternalChartingWizard/PreviewChartSection.js +21 -0
  80. package/src/View/Charting/ChartingWizard/ExternalChartingWizard/SettingsSection.d.ts +1 -0
  81. package/src/View/Charting/ChartingWizard/ExternalChartingWizard/SettingsSection.js +10 -7
  82. package/src/View/Comments/CommentsEditor.js +1 -1
  83. package/src/View/Components/ColumnFilter/ColumnFilterWindow.js +1 -1
  84. package/src/View/Components/ModuleProfile.js +1 -1
  85. package/src/View/Components/Popups/WindowPopups/windowFactory.d.ts +0 -1
  86. package/src/View/Components/Popups/WindowPopups/windowFactory.js +0 -1
  87. package/src/View/Components/RangesComponent.d.ts +7 -2
  88. package/src/View/Components/RangesComponent.js +94 -22
  89. package/src/View/Components/Selectors/ColumnSelector.js +5 -0
  90. package/src/View/Components/StyleComponent.d.ts +1 -0
  91. package/src/View/Components/StyleComponent.js +1 -1
  92. package/src/View/Components/ValueSelector/index.js +70 -57
  93. package/src/View/CustomSort/Wizard/CustomSortColumnWizardSection.js +8 -13
  94. package/src/View/CustomSort/Wizard/CustomSortValuesWizardSection.js +8 -8
  95. package/src/View/DataChangeHistory/DataChangeHistoryGrid.js +1 -1
  96. package/src/View/DataImport/DataImportWizard/sections/ColumnsSection.js +11 -12
  97. package/src/View/DataImport/DataImportWizard/sections/UploadSection/UploadSection.js +6 -4
  98. package/src/View/DataImport/DataImportWizard/sections/UploadSection/UploadTextSection.js +3 -2
  99. package/src/View/DataImport/DataImportWizard/sections/ValidationSection.js +5 -15
  100. package/src/View/Export/Wizard/ReportColumnsWizardSection.js +24 -26
  101. package/src/View/Export/Wizard/ReportNameWizardSection.js +10 -13
  102. package/src/View/Export/Wizard/ReportRowsWizardSection.js +20 -22
  103. package/src/View/Export/Wizard/ScheduledReportSettings.d.ts +2 -0
  104. package/src/View/Export/Wizard/ScheduledReportSettings.js +13 -13
  105. package/src/View/Export/Wizard/ScheduledReportWizard.js +4 -5
  106. package/src/View/FlashingCell/Wizard/FlashingCellRulesWizardSection.js +8 -6
  107. package/src/View/FlashingCell/Wizard/FlashingCellScopeWizardSection.js +24 -23
  108. package/src/View/FlashingCell/Wizard/FlashingCellSettingsWizardSection.js +20 -11
  109. package/src/View/FlashingCell/Wizard/FlashingCellStyleWizardSection.js +21 -5
  110. package/src/View/FlashingCell/Wizard/FlashingCellWizard.js +4 -4
  111. package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.d.ts +7 -0
  112. package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +117 -12
  113. package/src/View/FormatColumn/Wizard/FormatColumnPreview.d.ts +15 -0
  114. package/src/View/FormatColumn/Wizard/FormatColumnPreview.js +66 -0
  115. package/src/View/FormatColumn/Wizard/FormatColumnRuleWizardSection.d.ts +4 -0
  116. package/src/View/FormatColumn/Wizard/FormatColumnRuleWizardSection.js +30 -0
  117. package/src/View/FormatColumn/Wizard/FormatColumnScopeWizardSection.js +13 -8
  118. package/src/View/FormatColumn/Wizard/FormatColumnSettingsWizardSection.js +1 -1
  119. package/src/View/FormatColumn/Wizard/FormatColumnStyleWizardSection.d.ts +3 -1
  120. package/src/View/FormatColumn/Wizard/FormatColumnStyleWizardSection.js +62 -13
  121. package/src/View/FormatColumn/Wizard/FormatColumnWizard.js +5 -3
  122. package/src/View/FreeTextColumn/Utilities/getFreeTextColumnSettingsTags.d.ts +2 -0
  123. package/src/View/FreeTextColumn/Utilities/getFreeTextColumnSettingsTags.js +15 -0
  124. package/src/View/FreeTextColumn/Wizard/FreeTextColumnDefinitionWizardSection.d.ts +10 -0
  125. package/src/View/FreeTextColumn/Wizard/FreeTextColumnDefinitionWizardSection.js +53 -0
  126. package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.d.ts +2 -3
  127. package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.js +33 -68
  128. package/src/View/FreeTextColumn/Wizard/FreeTextColumnWizard.js +15 -11
  129. package/src/View/Layout/LayoutViewPanel.js +23 -21
  130. package/src/View/Layout/TransposedPopup.js +2 -2
  131. package/src/View/Layout/Wizard/LayoutWizard.js +3 -3
  132. package/src/View/Layout/Wizard/sections/AggregationsSection.d.ts +2 -3
  133. package/src/View/Layout/Wizard/sections/AggregationsSection.js +115 -26
  134. package/src/View/Layout/Wizard/sections/ColumnsSection.js +79 -79
  135. package/src/View/Layout/Wizard/sections/FilterSection.js +31 -32
  136. package/src/View/Layout/Wizard/sections/GridFilterSection.js +11 -11
  137. package/src/View/Layout/Wizard/sections/PivotAggregationsSection.d.ts +1 -2
  138. package/src/View/Layout/Wizard/sections/PivotAggregationsSection.js +101 -52
  139. package/src/View/Layout/Wizard/sections/PivotColumnsSection.js +9 -8
  140. package/src/View/Layout/Wizard/sections/PivotRowGroupingSection.js +4 -4
  141. package/src/View/Layout/Wizard/sections/RowGroupingSection.js +36 -33
  142. package/src/View/Layout/Wizard/sections/RowSelectionSection.js +2 -2
  143. package/src/View/Layout/Wizard/sections/RowSummarySection.js +95 -73
  144. package/src/View/Layout/Wizard/sections/SettingsSection.js +4 -5
  145. package/src/View/Layout/Wizard/sections/SortSection.js +2 -2
  146. package/src/View/NamedQuery/Wizard/NamedQueryExpressionWizardSection.js +1 -1
  147. package/src/View/NamedQuery/Wizard/NamedQuerySettingsWizardSection.js +9 -14
  148. package/src/View/NamedQuery/Wizard/NamedQueryWizard.js +1 -3
  149. package/src/View/PlusMinus/Wizard/PlusMinusRuleWizardSection.d.ts +4 -0
  150. package/src/View/PlusMinus/Wizard/PlusMinusRuleWizardSection.js +43 -13
  151. package/src/View/PlusMinus/Wizard/PlusMinusScopeWizardSection.js +11 -18
  152. package/src/View/PlusMinus/Wizard/PlusMinusSettingsWizardSection.d.ts +2 -6
  153. package/src/View/PlusMinus/Wizard/PlusMinusSettingsWizardSection.js +6 -22
  154. package/src/View/PlusMinus/Wizard/PlusMinusWizard.js +15 -21
  155. package/src/View/Schedule/Wizard/ScheduleScheduleWizard.js +2 -2
  156. package/src/View/Shortcut/Wizard/ShortcutScopeWizardSection.js +11 -18
  157. package/src/View/Shortcut/Wizard/ShortcutSettingsWizard.js +17 -6
  158. package/src/View/Shortcut/Wizard/ShortcutWizard.js +3 -3
  159. package/src/View/Shortcut/shortcutOperations.d.ts +3 -0
  160. package/src/View/Shortcut/shortcutOperations.js +28 -0
  161. package/src/View/SpecialColumnSettingsWizardStep.js +9 -8
  162. package/src/View/StyledColumn/Wizard/BadgePillStyleEditor.d.ts +5 -0
  163. package/src/View/StyledColumn/Wizard/BadgePillStyleEditor.js +24 -15
  164. package/src/View/StyledColumn/Wizard/StyledColumnBadgeSection.d.ts +10 -2
  165. package/src/View/StyledColumn/Wizard/StyledColumnBadgeSection.js +96 -16
  166. package/src/View/StyledColumn/Wizard/StyledColumnSliceStyleEditors.d.ts +14 -0
  167. package/src/View/StyledColumn/Wizard/StyledColumnSliceStyleEditors.js +45 -24
  168. package/src/View/StyledColumn/Wizard/StyledColumnSparklineSettingsSection.d.ts +2 -3
  169. package/src/View/StyledColumn/Wizard/StyledColumnSparklineSettingsSection.js +108 -33
  170. package/src/View/StyledColumn/Wizard/StyledColumnWizard.js +21 -13
  171. package/src/View/StyledColumn/Wizard/StyledColumnWizardBulletSection.d.ts +5 -0
  172. package/src/View/StyledColumn/Wizard/StyledColumnWizardBulletSection.js +121 -23
  173. package/src/View/StyledColumn/Wizard/StyledColumnWizardGradientSection.d.ts +1 -0
  174. package/src/View/StyledColumn/Wizard/StyledColumnWizardGradientSection.js +34 -11
  175. package/src/View/StyledColumn/Wizard/StyledColumnWizardIconSection.d.ts +5 -0
  176. package/src/View/StyledColumn/Wizard/StyledColumnWizardIconSection.js +86 -12
  177. package/src/View/StyledColumn/Wizard/StyledColumnWizardRangeBarSection.d.ts +5 -0
  178. package/src/View/StyledColumn/Wizard/StyledColumnWizardRangeBarSection.js +121 -34
  179. package/src/View/StyledColumn/Wizard/StyledColumnWizardRatingSection.d.ts +1 -0
  180. package/src/View/StyledColumn/Wizard/StyledColumnWizardRatingSection.js +55 -75
  181. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/BulletRangesSummaryPreview.d.ts +5 -0
  182. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/BulletRangesSummaryPreview.js +16 -0
  183. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/GradientSummaryPreview.js +7 -13
  184. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/PercentBarColumnComparisonPreview.js +5 -5
  185. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/PercentBarRangesPreview.js +4 -3
  186. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/PercentBarStylePreview.d.ts +5 -4
  187. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/PercentBarStylePreview.js +12 -14
  188. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/RangeBarRangesSummaryPreview.d.ts +5 -0
  189. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/RangeBarRangesSummaryPreview.js +16 -0
  190. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview.d.ts +3 -0
  191. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview.js +31 -3
  192. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBulletPreview.d.ts +9 -0
  193. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBulletPreview.js +58 -0
  194. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnGradientPreview.d.ts +10 -0
  195. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnGradientPreview.js +30 -0
  196. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnIconPreview.d.ts +10 -0
  197. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnIconPreview.js +91 -0
  198. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnPercentBarPreview.d.ts +8 -0
  199. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnPercentBarPreview.js +52 -0
  200. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRangeBarPreview.d.ts +8 -0
  201. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRangeBarPreview.js +53 -0
  202. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRatingPreview.d.ts +18 -0
  203. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRatingPreview.js +58 -0
  204. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnSparklinePreview.d.ts +10 -0
  205. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnSparklinePreview.js +126 -0
  206. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/StyledColumnWizardRangesSection.js +12 -5
  207. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/StyledColumnWizardStyleSection.d.ts +1 -5
  208. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/StyledColumnWizardStyleSection.js +52 -29
  209. package/src/View/SystemStatus/Utilities/getStatusItemStyle.js +1 -1
  210. package/src/View/Theme/ThemePopup.d.ts +2 -14
  211. package/src/View/Theme/ThemePopup.js +1 -36
  212. package/src/View/UIHelper.js +1 -1
  213. package/src/View/Wizard/OnePageAdaptableWizard.js +7 -21
  214. package/src/View/renderWithAdaptableContext.js +2 -3
  215. package/src/agGrid/AdaptableAgGrid.d.ts +1 -1
  216. package/src/agGrid/AdaptableAgGrid.js +38 -43
  217. package/src/agGrid/AgGridAdapter.d.ts +1 -1
  218. package/src/agGrid/AgGridAdapter.js +27 -17
  219. package/src/agGrid/AgGridColumnAdapter.js +10 -19
  220. package/src/agGrid/AgGridMenuAdapter.d.ts +0 -1
  221. package/src/agGrid/AgGridMenuAdapter.js +20 -37
  222. package/src/agGrid/buildValueAggregationMenuItem.d.ts +19 -0
  223. package/src/agGrid/buildValueAggregationMenuItem.js +111 -0
  224. package/src/agGrid/cellRenderers/IconRenderer.d.ts +6 -0
  225. package/src/agGrid/cellRenderers/IconRenderer.js +43 -15
  226. package/src/agGrid/createAgGridIcon.d.ts +10 -0
  227. package/src/agGrid/createAgGridIcon.js +16 -0
  228. package/src/components/AdaptableFormComponent/AdaptableFormComponent.js +11 -6
  229. package/src/components/Combobox/VirtualizedList.js +5 -5
  230. package/src/components/Combobox/comboboxUtils.d.ts +4 -1
  231. package/src/components/Combobox/comboboxUtils.js +2 -0
  232. package/src/components/Combobox/index.d.ts +1 -0
  233. package/src/components/Combobox/index.js +35 -15
  234. package/src/components/DragAndDropContext/UnusedPanel.js +1 -1
  235. package/src/components/ExpressionEditor/BaseEditorInput.js +1 -1
  236. package/src/components/ExpressionEditor/ExpressionFunctionDocumentation.js +1 -1
  237. package/src/components/Input/NumberInput.js +1 -1
  238. package/src/components/Panel/index.js +1 -1
  239. package/src/components/SimpleButton/index.js +4 -4
  240. package/src/components/Toggle/Toggle.js +1 -1
  241. package/src/components/Toggle/ToggleGroup.js +1 -1
  242. package/src/components/Tree/TreeDropdown/index.js +2 -6
  243. package/src/env.js +2 -2
  244. package/src/layout-manager/src/LayoutManagerModel.d.ts +5 -1
  245. package/src/layout-manager/src/index.js +2 -9
  246. package/src/metamodel/adaptable.metamodel.d.ts +39 -46
  247. package/src/metamodel/adaptable.metamodel.js +1 -1
  248. package/src/types.d.ts +5 -5
  249. package/themes/dark.css +1 -68
  250. package/themes/light.css +1 -5
  251. package/tsconfig.esm.tsbuildinfo +1 -1
  252. package/src/AdaptableState/Common/FilterActionOnDataChange.d.ts +0 -17
  253. package/src/AdaptableState/Common/FilterActionOnDataChange.js +0 -4
  254. package/src/Aggregation/ParameterizedAggregationRegistry.d.ts +0 -35
  255. package/src/Aggregation/ParameterizedAggregationRegistry.js +0 -63
  256. package/src/Aggregation/definitions/weightedAverageAggregationDefinition.d.ts +0 -3
  257. package/src/Aggregation/definitions/weightedAverageAggregationDefinition.js +0 -55
  258. package/src/Aggregation/parameterizedAggregationColumnMenu.d.ts +0 -8
  259. package/src/Aggregation/parameterizedAggregationColumnMenu.js +0 -137
  260. package/src/Aggregation/parameterizedAggregationHeader.d.ts +0 -13
  261. package/src/Aggregation/parameterizedAggregationHeader.js +0 -60
  262. package/src/Aggregation/parameterizedAggregationHelpers.d.ts +0 -23
  263. package/src/Aggregation/parameterizedAggregationHelpers.js +0 -111
  264. package/src/Aggregation/parameterizedAggregationWizardHelpers.d.ts +0 -9
  265. package/src/Aggregation/parameterizedAggregationWizardHelpers.js +0 -66
  266. package/src/Aggregation/validateParameterizedAggregations.d.ts +0 -4
  267. package/src/Aggregation/validateParameterizedAggregations.js +0 -20
  268. package/src/View/AdaptableComputedCSSVarsContext.d.ts +0 -12
  269. package/src/View/AdaptableComputedCSSVarsContext.js +0 -29
  270. package/src/View/Layout/Wizard/sections/ParameterizedAggFuncPicker.d.ts +0 -12
  271. package/src/View/Layout/Wizard/sections/ParameterizedAggFuncPicker.js +0 -43
  272. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgeSettings.d.ts +0 -5
  273. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgeSettings.js +0 -28
  274. package/src/View/Theme/VariantSelector.d.ts +0 -8
  275. package/src/View/Theme/VariantSelector.js +0 -20
  276. package/src/components/Select/CSSNumericVariableWatch.d.ts +0 -11
  277. package/src/components/Select/CSSNumericVariableWatch.js +0 -45
@@ -2,7 +2,6 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import * as React from 'react';
3
3
  import { columnFilter } from './Utilities';
4
4
  import { ColumnGroupTag } from '../../../Components/ColumnGroupTag';
5
- import { Tabs } from '../../../../components/Tabs';
6
5
  import { Tag } from '../../../../components/Tag';
7
6
  import { useAdaptable } from '../../../AdaptableContext';
8
7
  import { ValueSelector } from '../../../Components/ValueSelector';
@@ -11,11 +10,12 @@ import ArrayExtensions from '../../../../Utilities/Extensions/ArrayExtensions';
11
10
  import { normalizeLayout } from '../../../../Api/Implementation/LayoutHelpers';
12
11
  import { RowGroupBehaviorSection } from './RowGroupingSection';
13
12
  import { Box, Flex } from '../../../../components/Flex';
13
+ import { Card } from '../../../../components/Card';
14
14
  export const PivotRowGroupingSectionSummary = () => {
15
15
  const adaptable = useAdaptable();
16
16
  const { data: layout } = useOnePageAdaptableWizardContext();
17
17
  return (_jsx(Box, { children: layout.PivotGroupedColumns?.length ? (layout.PivotGroupedColumns.map((columnId) => {
18
- return (_jsx(Box, { className: "twa:mb-2", children: _jsx(Tag, { children: adaptable.api.columnApi.getFriendlyNameForColumnId(columnId) }, columnId) }));
18
+ return (_jsx(Box, { className: "twa:mb-2", children: _jsx(Tag, { children: adaptable.api.columnApi.getFriendlyNameForColumnId(columnId) }) }, columnId));
19
19
  })) : (_jsx(Tag, { children: "No Pivot Row Grouping" })) }));
20
20
  };
21
21
  export const PivotRowGroupingSection = (props) => {
@@ -34,6 +34,6 @@ export const PivotRowGroupingSection = (props) => {
34
34
  PivotGroupedColumns: columnIds,
35
35
  });
36
36
  };
37
- const rowGroupsText = 'Row Group ' + adaptable.api.internalApi.getCorrectEnglishVariant('Behaviour');
38
- return (_jsxs(Tabs, { style: { height: '100%' }, children: [_jsx(Tabs.Tab, { children: "Row Grouped Columns" }), _jsx(Tabs.Tab, { children: rowGroupsText }), _jsx(Tabs.Content, { children: _jsx(ValueSelector, { showFilterInput: true, filter: columnFilter, toIdentifier: (option) => `${option.columnId}`, toLabel: (option) => option.friendlyName ?? option.columnId, toListLabel: (option) => (_jsxs(Flex, { alignItems: "center", children: [option.friendlyName ?? option.columnId, _jsx(ColumnGroupTag, { column: option })] })), options: sortedGroupableColumns, value: layout.PivotGroupedColumns ?? [], allowReorder: true, onChange: handleColumnsChange }) }), _jsx(Tabs.Content, { children: _jsx(RowGroupBehaviorSection, { layout: layout, onChange: onChange }) })] }));
37
+ const rowGroupsText = 'Grouped Rows ' + adaptable.api.internalApi.getCorrectEnglishVariant('Behaviour');
38
+ return (_jsxs(Box, { className: "twa:h-full twa:min-h-0 twa:p-2 twa:gap-2 twa:overflow-hidden twa:grid twa:grid-cols-2", children: [_jsxs(Card, { shadow: false, className: "twa:h-full twa:overflow-hidden twa:flex twa:flex-col", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Row Grouped Columns" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Select and order Columns used in grouping" })] }), _jsx(Card.Body, { className: "twa:flex-1 twa:min-h-0 twa:overflow-hidden twa:p-1", children: _jsx(ValueSelector, { style: { minHeight: 0 }, showFilterInput: true, filter: columnFilter, toIdentifier: (option) => `${option.columnId}`, toLabel: (option) => option.friendlyName ?? option.columnId, toListLabel: (option) => (_jsxs(Flex, { alignItems: "center", children: [option.friendlyName ?? option.columnId, _jsx(ColumnGroupTag, { column: option })] })), options: sortedGroupableColumns, value: layout.PivotGroupedColumns ?? [], allowReorder: true, onChange: handleColumnsChange }) })] }), _jsx(Box, { className: "twa:h-full twa:min-h-0 twa:overflow-y-auto twa:flex twa:flex-col twa:gap-2", children: _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: rowGroupsText }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Set what happens when Layout opens" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsx(RowGroupBehaviorSection, { layout: layout, onChange: onChange }) })] }) })] }));
39
39
  };
@@ -1,10 +1,8 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import * as React from 'react';
3
- import FormLayout from '../../../../components/FormLayout';
4
3
  import { columnFilter } from './Utilities';
5
4
  import { ColumnGroupTag } from '../../../Components/ColumnGroupTag';
6
5
  import { RadioGroup } from '../../../../components/Radio';
7
- import { Tabs } from '../../../../components/Tabs';
8
6
  import { Tag } from '../../../../components/Tag';
9
7
  import { useAdaptable } from '../../../AdaptableContext';
10
8
  import { ValueSelector } from '../../../Components/ValueSelector';
@@ -13,6 +11,7 @@ import ArrayExtensions from '../../../../Utilities/Extensions/ArrayExtensions';
13
11
  import { normalizeLayout } from '../../../../Api/Implementation/LayoutHelpers';
14
12
  import { TypeRadio } from '../../../Wizard/TypeRadio';
15
13
  import { Box, Flex } from '../../../../components/Flex';
14
+ import { Card } from '../../../../components/Card';
16
15
  export const RowGroupingSectionSummary = () => {
17
16
  const adaptable = useAdaptable();
18
17
  const { data: layout } = useOnePageAdaptableWizardContext();
@@ -25,19 +24,39 @@ export const RowGroupingSectionSummary = () => {
25
24
  };
26
25
  export const RowGroupBehaviorSection = (props) => {
27
26
  const { layout, onChange } = props;
28
- return (_jsx(FormLayout, { children: _jsxs(RadioGroup, { orientation: "vertical", value: layout.RowGroupValues?.RowGroupDefaultBehavior ?? 'always-collapsed', onRadioChange: (RowGroupDefaultBehavior) => {
29
- const newLayout = {
30
- ...layout,
31
- RowGroupValues: {
32
- RowGroupDefaultBehavior,
33
- },
34
- };
35
- if (newLayout.RowGroupValues.RowGroupDefaultBehavior === 'collapsed' ||
36
- newLayout.RowGroupValues.RowGroupDefaultBehavior === 'expanded') {
37
- newLayout.RowGroupValues.ExceptionGroupKeys = [];
38
- }
39
- onChange(newLayout);
40
- }, children: [_jsx(TypeRadio, { value: "always-collapsed", text: "All Collapsed", description: "Layout opens with all Grouped Rows always collapsed" }), _jsx(TypeRadio, { value: "always-expanded", text: "All Expanded", description: "Layout opens with all Grouped Rows always expanded" }), _jsx(TypeRadio, { value: "expanded", text: "Mostly Expanded", description: "Layout opens with all Grouped rows expanded, other than those collapsed when Layout last displayed" }), _jsx(TypeRadio, { value: "collapsed", text: "Mostly Collapsed", description: "Layout opens with all Grouped rows collapsed, other than those expanded when Layout last displayed" })] }) }));
27
+ return (_jsxs(RadioGroup, { orientation: "vertical", value: layout.RowGroupValues?.RowGroupDefaultBehavior ?? 'always-collapsed', onRadioChange: (RowGroupDefaultBehavior) => {
28
+ const newLayout = {
29
+ ...layout,
30
+ RowGroupValues: {
31
+ RowGroupDefaultBehavior,
32
+ },
33
+ };
34
+ if (newLayout.RowGroupValues.RowGroupDefaultBehavior === 'collapsed' ||
35
+ newLayout.RowGroupValues.RowGroupDefaultBehavior === 'expanded') {
36
+ newLayout.RowGroupValues.ExceptionGroupKeys = [];
37
+ }
38
+ onChange(newLayout);
39
+ }, children: [_jsx(TypeRadio, { value: "always-collapsed", text: "All Collapsed", description: "All Grouped Rows are always collapsed" }), _jsx(TypeRadio, { value: "always-expanded", text: "All Expanded", description: "All Grouped Rows are always expanded" }), _jsx(TypeRadio, { value: "expanded", text: "Mostly Expanded", description: "All expanded, other than those collapsed when Layout last displayed" }), _jsx(TypeRadio, { value: "collapsed", text: "Mostly Collapsed", description: "All collapsed, other than those expanded when Layout last displayed" })] }));
40
+ };
41
+ const RowGroupDisplayTypeSection = ({ layout, onChange }) => {
42
+ const adaptable = useAdaptable();
43
+ return (_jsxs(RadioGroup, { orientation: "vertical", value: layout.RowGroupDisplayType ?? 'single', onRadioChange: (RowGroupDisplayType) => {
44
+ let newLayout = {
45
+ ...layout,
46
+ RowGroupDisplayType,
47
+ };
48
+ if (RowGroupDisplayType === 'single') {
49
+ newLayout.TableColumns = (newLayout.TableColumns || []).filter((colId) => !adaptable.api.columnApi.isAutoRowGroupColumnForMulti(colId));
50
+ }
51
+ else if (RowGroupDisplayType === 'multi') {
52
+ newLayout.TableColumns = (newLayout.TableColumns || []).filter((colId) => !adaptable.api.columnApi.isAutoRowGroupColumnForSingle(colId));
53
+ }
54
+ else {
55
+ newLayout.TableColumns = (newLayout.TableColumns || []).filter((colId) => !adaptable.api.columnApi.isAutoRowGroupColumnForSingle(colId) &&
56
+ !adaptable.api.columnApi.isAutoRowGroupColumnForMulti(colId));
57
+ }
58
+ onChange(newLayout);
59
+ }, children: [_jsx(TypeRadio, { value: "single", text: "Single Column", description: "All Row Grouped Columns display in one hierarchical Column" }), _jsx(TypeRadio, { value: "multi", text: "Multiple Columns", description: "Each Row Grouped Column displays in its own, separate, Column" }), _jsx(TypeRadio, { value: "groupRows", text: "Full Width Group Rows", description: "Row groups display as full-width rows (no group column and no aggregations)" })] }));
41
60
  };
42
61
  export const RowGroupingSection = (props) => {
43
62
  const adaptable = useAdaptable();
@@ -45,7 +64,7 @@ export const RowGroupingSection = (props) => {
45
64
  return (_jsx(Flex, { flexDirection: "row", children: _jsx(Tag, { children: "Row Grouping is not available in Tree Grids" }) }));
46
65
  }
47
66
  const { data: layout } = useOnePageAdaptableWizardContext();
48
- const rowGroupsText = 'Row Group ' + adaptable.api.internalApi.getCorrectEnglishVariant('Behaviour');
67
+ const rowGroupsText = 'Grouped Rows ' + adaptable.api.internalApi.getCorrectEnglishVariant('Behaviour');
49
68
  const allGroupableColumns = adaptable.api.columnApi.getGroupableColumns();
50
69
  const sortedGroupableColumns = React.useMemo(() => {
51
70
  return ArrayExtensions.sortArrayWithOrder(allGroupableColumns.map((col) => col.columnId), layout.RowGroupedColumns ?? [], { sortUnorderedItems: false }).map((colId) => adaptable.api.columnApi.getColumnWithColumnId(colId));
@@ -65,21 +84,5 @@ export const RowGroupingSection = (props) => {
65
84
  }
66
85
  onChange(newLayout);
67
86
  };
68
- return (_jsxs(Box, { className: "twa:h-full", children: [_jsxs(Tabs, { children: [_jsx(Tabs.Tab, { children: "Group Display Type" }), _jsx(Tabs.Content, { children: _jsx(FormLayout, { children: _jsxs(RadioGroup, { orientation: "vertical", value: layout.RowGroupDisplayType ?? 'single', onRadioChange: (RowGroupDisplayType) => {
69
- let newLayout = {
70
- ...layout,
71
- RowGroupDisplayType,
72
- };
73
- if (RowGroupDisplayType === 'single') {
74
- newLayout.TableColumns = (newLayout.TableColumns || []).filter((colId) => !adaptable.api.columnApi.isAutoRowGroupColumnForMulti(colId));
75
- }
76
- else if (RowGroupDisplayType === 'multi') {
77
- newLayout.TableColumns = (newLayout.TableColumns || []).filter((colId) => !adaptable.api.columnApi.isAutoRowGroupColumnForSingle(colId));
78
- }
79
- else {
80
- newLayout.TableColumns = (newLayout.TableColumns || []).filter((colId) => !adaptable.api.columnApi.isAutoRowGroupColumnForSingle(colId) &&
81
- !adaptable.api.columnApi.isAutoRowGroupColumnForMulti(colId));
82
- }
83
- onChange(newLayout);
84
- }, children: [_jsx(TypeRadio, { value: "single", text: "Single Column", description: "All Row Grouped Columns display in one hierarchical Column" }), _jsx(TypeRadio, { value: "multi", text: "Multiple Columns", description: "Each Row Grouped Column displays in its own, separate, Column" }), _jsx(TypeRadio, { value: "groupRows", text: "Full Width Group Rows", description: "Row groups display as full-width rows (no group column and no aggregations)" })] }) }) })] }), _jsxs(Tabs, { className: "twa:mt-2", children: [_jsx(Tabs.Tab, { children: "Row Grouped Columns" }), _jsx(Tabs.Tab, { children: rowGroupsText }), _jsx(Tabs.Content, { children: _jsx(ValueSelector, { showFilterInput: true, filter: columnFilter, toIdentifier: (option) => `${option.columnId}`, toLabel: (option) => option.friendlyName ?? option.columnId, toListLabel: (option) => (_jsxs(Flex, { alignItems: "center", children: [option.friendlyName ?? option.columnId, _jsx(ColumnGroupTag, { column: option })] })), options: sortedGroupableColumns, value: layout.RowGroupedColumns ?? [], allowReorder: true, onChange: handleColumnsChange }) }), _jsx(Tabs.Content, { children: _jsx(RowGroupBehaviorSection, { layout: layout, onChange: onChange }) })] })] }));
87
+ return (_jsxs(Box, { className: "twa:h-full twa:min-h-0 twa:p-2 twa:gap-2 twa:overflow-hidden twa:grid twa:grid-cols-2", children: [_jsxs(Card, { shadow: false, className: "twa:h-full twa:overflow-hidden twa:flex twa:flex-col", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Row Grouped Columns" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Select and order Columns used in grouping" })] }), _jsx(Card.Body, { className: "twa:flex-1 twa:min-h-0 twa:overflow-hidden twa:p-1", children: _jsx(ValueSelector, { style: { minHeight: 0 }, showFilterInput: true, filter: columnFilter, toIdentifier: (option) => `${option.columnId}`, toLabel: (option) => option.friendlyName ?? option.columnId, toListLabel: (option) => (_jsxs(Flex, { alignItems: "center", children: [option.friendlyName ?? option.columnId, _jsx(ColumnGroupTag, { column: option })] })), options: sortedGroupableColumns, value: layout.RowGroupedColumns ?? [], allowReorder: true, onChange: handleColumnsChange }) })] }), _jsxs(Box, { className: "twa:h-full twa:min-h-0 twa:overflow-y-auto twa:flex twa:flex-col twa:gap-2", children: [_jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Group Display Type" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose how grouped rows display in the grid" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsx(RowGroupDisplayTypeSection, { layout: layout, onChange: onChange }) })] }), _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: rowGroupsText }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Set what happens when Layout opens" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsx(RowGroupBehaviorSection, { layout: layout, onChange: onChange }) })] })] })] }));
85
88
  };
@@ -2,7 +2,6 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
2
2
  import { CheckBox } from '../../../../components/CheckBox';
3
3
  import Radio, { radioGroupStyling } from '../../../../components/Radio';
4
4
  import { RadioGroup } from '../../../../components/Radio';
5
- import { Tabs } from '../../../../components/Tabs';
6
5
  import { Tag } from '../../../../components/Tag';
7
6
  import { useOnePageAdaptableWizardContext } from '../../../Wizard/OnePageAdaptableWizard';
8
7
  import { Box, Flex } from '../../../../components/Flex';
@@ -10,6 +9,7 @@ import { twMerge } from '../../../../twMerge';
10
9
  import HelpBlock from '../../../../components/HelpBlock';
11
10
  import { isPivotLayout } from '../../../../Utilities/isPivotLayout';
12
11
  import { AG_GRID_SELECTION_COLUMN } from '../../../../Utilities/Constants/GeneralConstants';
12
+ import { Card } from '../../../../components/Card';
13
13
  export const RowSelectionSectionSummary = () => {
14
14
  const { data: layout } = useOnePageAdaptableWizardContext();
15
15
  if (layout.RowSelection === false) {
@@ -69,5 +69,5 @@ export const RowSelectionSection = (props) => {
69
69
  }
70
70
  props.onChange(newLayout);
71
71
  };
72
- return (_jsxs(_Fragment, { children: [_jsxs(Tabs, { children: [_jsx(Tabs.Tab, { children: "Row Selection Mode" }), _jsx(Tabs.Content, { children: _jsx(Flex, { flexDirection: "column", children: _jsxs(RadioGroup, { orientation: "horizontal", variant: "text-only", className: twMerge(radioGroupStyling.horizontalTextOnly, 'twa:gap-2 twa:max-w-[500px] twa:bg-background twa:p-2'), value: mode, name: "rowSelectionMode", onRadioChange: handleModeChange, children: [_jsx(Radio, { value: false, children: "Disabled" }), _jsx(Radio, { value: "singleRow", children: "Single Row" }), _jsx(Radio, { value: "multiRow", children: "Multi Row" })] }) }) })] }), !rowSelection && _jsx(HelpBlock, { children: "There is no Row Selection configured for this Layout" }), rowSelection && (_jsxs(_Fragment, { children: [_jsxs(Tabs, { className: "twa:mt-2", children: [_jsx(Tabs.Tab, { children: "Row Selection Column Checkboxes" }), _jsx(Tabs.Content, { children: _jsxs(Flex, { flexDirection: "row", className: "twa:gap-6", children: [_jsx(CheckBox, { className: "twa:flex-1", checked: rowSelection.Checkboxes ?? true, onChange: (checked) => updateRowSelection({ Checkboxes: checked }), children: "Checkboxes in Column Cells" }), mode === 'multiRow' && (_jsx(CheckBox, { className: "twa:flex-1", checked: rowSelection.HeaderCheckbox ?? true, onChange: (checked) => updateRowSelection({ HeaderCheckbox: checked }), children: "Checkbox in Column Header (to enable Select All)" }))] }) })] }), (rowSelection.Checkboxes ?? true) && (_jsxs(Tabs, { className: "twa:mt-2", children: [_jsx(Tabs.Tab, { children: "Row Grouping Selection Checkboxes" }), _jsx(Tabs.Content, { children: _jsxs(RadioGroup, { orientation: "vertical", value: rowSelection.CheckboxInGroupColumn ?? false, name: "checkboxLocation", onRadioChange: (value) => updateRowSelection({ CheckboxInGroupColumn: value }), children: [_jsx(Radio, { value: false, children: "Display in dedicated Selection Column" }), _jsx(Radio, { value: true, children: "Display in Row Grouped Column" })] }) })] })), _jsxs(Tabs, { className: "twa:mt-2", children: [_jsx(Tabs.Tab, { children: "Row Click Selection (when user clicks on Row outside of Selection Checkbox)" }), _jsx(Tabs.Content, { children: _jsxs(RadioGroup, { orientation: "vertical", value: rowSelection.EnableClickSelection ?? false, name: "clickSelection", onRadioChange: (value) => updateRowSelection({ EnableClickSelection: value }), children: [_jsx(Radio, { value: false, children: "Disabled (Cannot select or deselect by clicking in Row)" }), _jsx(Radio, { value: true, children: "Full (Enable selection by clicking in Row and deselection by Ctrl+clicking in Row)" }), _jsx(Radio, { value: 'enableSelection', children: "Selection Only (Enable selection by clicking in Row)" }), _jsx(Radio, { value: 'enableDeselection', children: "Deselection Only (Enable deselection by Ctrl+clicking in Row)" })] }) })] }), mode === 'multiRow' && !isPivot && (_jsxs(Tabs, { className: "twa:mt-2", children: [_jsx(Tabs.Tab, { children: "Grouped Row Selection Behaviour" }), _jsx(Tabs.Content, { children: _jsxs(RadioGroup, { orientation: "vertical", value: rowSelection.GroupSelectMode ?? 'self', name: "groupSelectMode", onRadioChange: (value) => updateRowSelection({ GroupSelectMode: value }), children: [_jsx(Radio, { value: 'self', children: "Select Grouped Row Only (no cascade)" }), _jsx(Radio, { value: 'descendants', children: "Select Grouped Row and all descendants" }), _jsx(Radio, { value: 'filteredDescendants', children: "Select Grouped Row and only filtered descendants" })] }) })] })), mode === 'multiRow' && (_jsxs(Tabs, { className: "twa:mt-2", children: [_jsx(Tabs.Tab, { children: "Select All (in Header) Behaviour" }), _jsx(Tabs.Content, { children: _jsxs(RadioGroup, { orientation: "vertical", value: rowSelection.SelectAllMode ?? 'all', name: "selectAllMode", onRadioChange: (value) => updateRowSelection({ SelectAllMode: value }), children: [_jsx(Radio, { value: 'all', children: "All rows" }), _jsx(Radio, { value: 'filtered', children: "Filtered rows only" }), _jsx(Radio, { value: 'currentPage', children: "Current page only" })] }) })] }))] }))] }));
72
+ return (_jsxs(Flex, { flexDirection: "column", className: "twa:gap-3 twa:p-3", children: [_jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Row Selection Mode" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether row selection is disabled, single row, or multi row" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsxs(RadioGroup, { orientation: "horizontal", variant: "text-only", className: twMerge(radioGroupStyling.horizontalTextOnly, 'twa:gap-2 twa:max-w-[500px] twa:bg-background twa:p-2'), value: mode, name: "rowSelectionMode", onRadioChange: handleModeChange, children: [_jsx(Radio, { value: false, children: "Disabled" }), _jsx(Radio, { value: "singleRow", children: "Single Row" }), _jsx(Radio, { value: "multiRow", children: "Multi Row" })] }) })] }), !rowSelection && _jsx(HelpBlock, { children: "There is no Row Selection configured for this Layout" }), rowSelection && (_jsxs(_Fragment, { children: [_jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Row Selection Column Checkboxes" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Configure checkboxes in the selection column cells and header" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsxs(Flex, { flexDirection: "row", className: "twa:gap-6", children: [_jsx(CheckBox, { className: "twa:flex-1", checked: rowSelection.Checkboxes ?? true, onChange: (checked) => updateRowSelection({ Checkboxes: checked }), children: "Checkboxes in Column Cells" }), mode === 'multiRow' && (_jsx(CheckBox, { className: "twa:flex-1", checked: rowSelection.HeaderCheckbox ?? true, onChange: (checked) => updateRowSelection({ HeaderCheckbox: checked }), children: "Checkbox in Column Header (to enable Select All)" }))] }) })] }), (rowSelection.Checkboxes ?? true) && (_jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Row Grouping Selection Checkboxes" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose where selection checkboxes appear when row grouping is enabled" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsxs(RadioGroup, { orientation: "vertical", value: rowSelection.CheckboxInGroupColumn ?? false, name: "checkboxLocation", onRadioChange: (value) => updateRowSelection({ CheckboxInGroupColumn: value }), children: [_jsx(Radio, { value: false, children: "Display in dedicated Selection Column" }), _jsx(Radio, { value: true, children: "Display in Row Grouped Column" })] }) })] })), _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Row Click Selection" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Configure whether users can select or deselect rows by clicking outside the checkbox" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsxs(RadioGroup, { orientation: "vertical", value: rowSelection.EnableClickSelection ?? false, name: "clickSelection", onRadioChange: (value) => updateRowSelection({ EnableClickSelection: value }), children: [_jsx(Radio, { value: false, children: "Disabled (Cannot select or deselect by clicking in Row)" }), _jsx(Radio, { value: true, children: "Full (Enable selection by clicking in Row and deselection by Ctrl+clicking in Row)" }), _jsx(Radio, { value: 'enableSelection', children: "Selection Only (Enable selection by clicking in Row)" }), _jsx(Radio, { value: 'enableDeselection', children: "Deselection Only (Enable deselection by Ctrl+clicking in Row)" })] }) })] }), mode === 'multiRow' && !isPivot && (_jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Grouped Row Selection Behaviour" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose how selection cascades when a grouped row is selected" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsxs(RadioGroup, { orientation: "vertical", value: rowSelection.GroupSelectMode ?? 'self', name: "groupSelectMode", onRadioChange: (value) => updateRowSelection({ GroupSelectMode: value }), children: [_jsx(Radio, { value: 'self', children: "Select Grouped Row Only (no cascade)" }), _jsx(Radio, { value: 'descendants', children: "Select Grouped Row and all descendants" }), _jsx(Radio, { value: 'filteredDescendants', children: "Select Grouped Row and only filtered descendants" })] }) })] })), mode === 'multiRow' && (_jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Select All Behaviour" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose which rows are selected when the header Select All checkbox is used" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsxs(RadioGroup, { orientation: "vertical", value: rowSelection.SelectAllMode ?? 'all', name: "selectAllMode", onRadioChange: (value) => updateRowSelection({ SelectAllMode: value }), children: [_jsx(Radio, { value: 'all', children: "All rows" }), _jsx(Radio, { value: 'filtered', children: "Filtered rows only" }), _jsx(Radio, { value: 'currentPage', children: "Current page only" })] }) })] }))] }))] }));
73
73
  };
@@ -4,7 +4,7 @@ import { CheckBox } from '../../../../components/CheckBox';
4
4
  import FormLayout, { FormRow } from '../../../../components/FormLayout';
5
5
  import Panel from '../../../../components/Panel';
6
6
  import SimpleButton from '../../../../components/SimpleButton';
7
- import { Tabs } from '../../../../components/Tabs';
7
+ import { Card } from '../../../../components/Card';
8
8
  import { Tag } from '../../../../components/Tag';
9
9
  import { summarySupportedExpressions, WEIGHTED_AVERAGE_AGGREGATED_FUNCTION, } from '../../../../AdaptableState/Common/RowSummary';
10
10
  import { mapColumnDataTypeToExpressionFunctionType } from '../../../../Utilities/adaptableQlUtils';
@@ -73,6 +73,33 @@ const getAvailableExpressionsForColumnType = (columnType, availableScalarExpress
73
73
  availableExpressionsForColumnTypeCache.set(key, expressions);
74
74
  return expressions;
75
75
  };
76
+ const buildRowSummaryExpressionOptions = (column, availableScalarExpressions, layout) => {
77
+ const expressionOptions = getAvailableExpressionsForColumnType(column.dataType, availableScalarExpressions).map((expression) => ({
78
+ label: expression,
79
+ value: expression,
80
+ }));
81
+ const aggregation = layout.TableAggregationColumns?.find((agg) => agg.ColumnId === column.columnId)?.AggFunc;
82
+ if (aggregation &&
83
+ typeof aggregation === 'object' &&
84
+ aggregation.weightedColumnId) {
85
+ expressionOptions.push({
86
+ label: 'WEIGHTERD_AVG',
87
+ value: WEIGHTED_AVERAGE_AGGREGATED_FUNCTION,
88
+ });
89
+ }
90
+ return expressionOptions;
91
+ };
92
+ const getDefaultRowSummaryExpression = (column, availableScalarExpressions, layout) => {
93
+ const optionValues = buildRowSummaryExpressionOptions(column, availableScalarExpressions, layout).map((option) => option.value);
94
+ if (optionValues.includes('sum')) {
95
+ return 'sum';
96
+ }
97
+ const sumExpression = optionValues.find((value) => value.toLowerCase() === 'sum');
98
+ if (sumExpression) {
99
+ return sumExpression;
100
+ }
101
+ return optionValues[0] ?? null;
102
+ };
76
103
  export const RowSummarySectionSummary = () => {
77
104
  const adaptable = useAdaptable();
78
105
  const { data: layout } = useOnePageAdaptableWizardContext();
@@ -100,76 +127,71 @@ const RowSummaryEditor = React.memo(({ rowSummary, onChange, availableScalarExpr
100
127
  sortUnorderedItems: false,
101
128
  }).map((colId) => adaptable.api.columnApi.getColumnWithColumnId(colId));
102
129
  }, [rowSummary.ColumnsMap]);
103
- return (_jsxs(Panel, { header: _jsxs(Flex, { className: "twa:w-full", children: [_jsx(Flex, { className: "twa:flex-1", alignItems: "center", children: "Row Summary" }), _jsx(Box, { className: "twa:mr-2", children: _jsx(SuspendToggleButton, { onSuspend: () => {
104
- onChange({
105
- ...rowSummary,
106
- IsSuspended: true,
107
- });
108
- }, onUnSuspend: () => {
109
- onChange({
110
- ...rowSummary,
111
- IsSuspended: false,
112
- });
113
- }, suspendableObject: rowSummary }) }), _jsx(SimpleButton, { icon: "delete", onClick: () => {
114
- onDelete();
115
- } })] }), className: "twa:p-2", children: [_jsxs(FormLayout, { children: [_jsx(FormRow, { label: "Position", children: _jsx(SingleSelect, { items: [
116
- {
117
- label: 'Top',
118
- value: 'Top',
119
- },
120
- {
121
- label: 'Bottom',
122
- value: 'Bottom',
123
- },
124
- ], value: rowSummary.Position, onValueChange: (position) => {
125
- onChange({
126
- ...rowSummary,
127
- Position: position,
128
- });
129
- } }) }), _jsx(FormRow, { label: "", children: _jsx(CheckBox, { checked: rowSummary.IncludeOnlyFilteredRows ?? true, onChange: (IncludeOnlyFilteredRows) => {
130
- onChange({
131
- ...rowSummary,
132
- IncludeOnlyFilteredRows,
133
- });
134
- }, children: "Include Only Filtered Rows" }) })] }), _jsxs(Flex, { flexDirection: "column", className: "twa:mt-2 twa:mb-1", children: [_jsx(Flex, { alignItems: "center", className: "twa:flex-1 twa:mb-2", children: "Column Aggregations" }), _jsx(Panel, { bodyProps: { className: 'twa:max-h-full twa:bg-primarylight ' }, className: "twa:h-[360px]", children: _jsx(ValueSelector, { style: { maxHeight: '100%' }, showFilterInput: true, filter: columnFilter, toIdentifier: (column) => column.columnId, toLabel: (option) => option.friendlyName ?? option.columnId, options: columns, toListLabel: (column) => {
135
- const label = column.friendlyName ?? column.columnId;
136
- if (!(column.columnId in (rowSummary.ColumnsMap ?? {}))) {
137
- return (_jsxs(Flex, { alignItems: "center", children: [label, _jsx(ColumnGroupTag, { column: column })] }));
138
- }
139
- const expressionOptions = getAvailableExpressionsForColumnType(column.dataType, availableScalarExpressions).map((expression) => ({
140
- label: expression,
141
- value: expression,
142
- }));
143
- // check out if this layout has a aggregation with weighted column
144
- const aggregation = layout.TableAggregationColumns?.find((agg) => agg.ColumnId === column.columnId)?.AggFunc;
145
- if (aggregation &&
146
- typeof aggregation === 'object' &&
147
- aggregation.weightedColumnId) {
148
- expressionOptions.push({
149
- label: 'WEIGHTERD_AVG',
150
- value: WEIGHTED_AVERAGE_AGGREGATED_FUNCTION,
151
- });
152
- }
153
- const expression = rowSummary.ColumnsMap[column.columnId];
154
- return (_jsxs(Flex, { children: [_jsxs(Flex, { className: "twa:mr-2", alignItems: 'center', children: [label, _jsx(ColumnGroupTag, { column: column })] }), _jsx(SingleSelect, { value: expression, items: expressionOptions, onValueChange: (expression) => {
155
- onChange({
156
- ...rowSummary,
157
- ColumnsMap: {
158
- ...rowSummary.ColumnsMap,
159
- [column.columnId]: expression,
160
- },
161
- });
162
- } })] }));
163
- }, value: Object.keys(rowSummary.ColumnsMap), onChange: (colIds) => {
164
- const newColumnsMap = {};
165
- colIds.forEach((colId) => {
166
- newColumnsMap[colId] = rowSummary.ColumnsMap[colId] ?? null;
167
- });
168
- onChange({
169
- ...rowSummary,
170
- ColumnsMap: newColumnsMap,
171
- });
172
- } }) })] })] }));
130
+ return (_jsx(Panel, { className: "twa:mb-3", bodyProps: { className: 'twa:p-2' }, children: _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { className: "twa:w-full", children: [_jsx(Box, { className: "twa:font-medium twa:flex-1", children: "Row Summary" }), _jsxs(Flex, { alignItems: "center", className: "twa:gap-2 twa:shrink-0", children: [_jsx(SuspendToggleButton, { onSuspend: () => {
131
+ onChange({
132
+ ...rowSummary,
133
+ IsSuspended: true,
134
+ });
135
+ }, onUnSuspend: () => {
136
+ onChange({
137
+ ...rowSummary,
138
+ IsSuspended: false,
139
+ });
140
+ }, suspendableObject: rowSummary }), _jsx(SimpleButton, { icon: "delete", onClick: () => {
141
+ onDelete();
142
+ } })] })] }), _jsxs(Card.Body, { className: "twa:p-1 twa:gap-3", children: [_jsxs(FormLayout, { children: [_jsx(FormRow, { label: "Position", children: _jsx(SingleSelect, { items: [
143
+ {
144
+ label: 'Top',
145
+ value: 'Top',
146
+ },
147
+ {
148
+ label: 'Bottom',
149
+ value: 'Bottom',
150
+ },
151
+ ], value: rowSummary.Position, onValueChange: (position) => {
152
+ onChange({
153
+ ...rowSummary,
154
+ Position: position,
155
+ });
156
+ } }) }), _jsx(FormRow, { label: "", children: _jsx(CheckBox, { checked: rowSummary.IncludeOnlyFilteredRows ?? true, onChange: (IncludeOnlyFilteredRows) => {
157
+ onChange({
158
+ ...rowSummary,
159
+ IncludeOnlyFilteredRows,
160
+ });
161
+ }, children: "Include Only Filtered Rows" }) })] }), _jsxs(Card, { shadow: false, className: "twa:h-[360px] twa:overflow-hidden twa:flex twa:flex-col", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Column Aggregations" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Select columns and choose an aggregation function for each" })] }), _jsx(Card.Body, { className: "twa:flex-1 twa:min-h-0 twa:overflow-hidden twa:p-1", children: _jsx(ValueSelector, { style: { minHeight: 0, maxHeight: '100%' }, showFilterInput: true, filter: columnFilter, toIdentifier: (column) => column.columnId, toLabel: (option) => option.friendlyName ?? option.columnId, options: columns, toListLabel: (column) => {
162
+ const label = column.friendlyName ?? column.columnId;
163
+ if (!(column.columnId in (rowSummary.ColumnsMap ?? {}))) {
164
+ return (_jsxs(Flex, { alignItems: "center", children: [label, _jsx(ColumnGroupTag, { column: column })] }));
165
+ }
166
+ const expressionOptions = buildRowSummaryExpressionOptions(column, availableScalarExpressions, layout);
167
+ const expression = rowSummary.ColumnsMap[column.columnId];
168
+ return (_jsxs(Flex, { children: [_jsxs(Flex, { className: "twa:mr-2", alignItems: 'center', children: [label, _jsx(ColumnGroupTag, { column: column })] }), _jsx(SingleSelect, { className: "twa:min-w-[140px]", value: expression, items: expressionOptions, onValueChange: (expression) => {
169
+ onChange({
170
+ ...rowSummary,
171
+ ColumnsMap: {
172
+ ...rowSummary.ColumnsMap,
173
+ [column.columnId]: expression,
174
+ },
175
+ });
176
+ } })] }));
177
+ }, value: Object.keys(rowSummary.ColumnsMap), onChange: (colIds) => {
178
+ const newColumnsMap = {};
179
+ colIds.forEach((colId) => {
180
+ const existing = rowSummary.ColumnsMap[colId];
181
+ if (existing) {
182
+ newColumnsMap[colId] = existing;
183
+ return;
184
+ }
185
+ const column = adaptable.api.columnApi.getColumnWithColumnId(colId);
186
+ newColumnsMap[colId] = column
187
+ ? getDefaultRowSummaryExpression(column, availableScalarExpressions, layout)
188
+ : null;
189
+ });
190
+ onChange({
191
+ ...rowSummary,
192
+ ColumnsMap: newColumnsMap,
193
+ });
194
+ } }) })] })] })] }) }));
173
195
  });
174
196
  export const RowSummarySection = (props) => {
175
197
  const adaptable = useAdaptable();
@@ -180,7 +202,7 @@ export const RowSummarySection = (props) => {
180
202
  .getModuleExpressionFunctionsMap(LayoutModuleId).aggregatedScalarFunctions;
181
203
  return sytemExpressions;
182
204
  }, []);
183
- return (_jsxs(Tabs, { style: { height: '100%' }, children: [_jsx(Tabs.Tab, { children: "Row Summaries" }), _jsx(Tabs.Content, { children: _jsxs("div", { children: [_jsxs(Flex, { className: "twa:mb-1", children: [_jsx(Flex, { className: "twa:flex-1" }), _jsx(SimpleButton, { onClick: () => {
205
+ return (_jsx(Flex, { flexDirection: "column", className: "twa:gap-3 twa:p-3 twa:h-full", children: _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Row Summaries" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Add summary rows at the top or bottom of the grid with aggregated column values" })] }), _jsxs(Card.Body, { className: "twa:p-1", children: [_jsxs(Flex, { className: "twa:mb-2", children: [_jsx(Flex, { className: "twa:flex-1" }), _jsx(SimpleButton, { onClick: () => {
184
206
  props.onChange({
185
207
  ...layout,
186
208
  RowSummaries: [
@@ -208,5 +230,5 @@ export const RowSummarySection = (props) => {
208
230
  RowSummaries: newSummaries,
209
231
  });
210
232
  } }, index));
211
- })] }) })] }));
233
+ })] })] }) }));
212
234
  };
@@ -1,12 +1,11 @@
1
- import { jsxs as _jsxs, jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
2
- import FormLayout, { FormRow } from '../../../../components/FormLayout';
1
+ import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
3
2
  import Input from '../../../../components/Input';
4
- import Radio from '../../../../components/Radio';
5
- import { Tabs } from '../../../../components/Tabs';
6
3
  import { Tag } from '../../../../components/Tag';
4
+ import { TypeRadio } from '../../../Wizard/TypeRadio';
7
5
  import { useOnePageAdaptableWizardContext } from '../../../Wizard/OnePageAdaptableWizard';
8
6
  import { isPivotLayout } from '../../../../Utilities/isPivotLayout';
9
7
  import { Box, Flex } from '../../../../components/Flex';
8
+ import { Card } from '../../../../components/Card';
10
9
  export const SettingsSectionSummary = () => {
11
10
  const { data: layout } = useOnePageAdaptableWizardContext();
12
11
  const isPivot = isPivotLayout(layout);
@@ -20,5 +19,5 @@ export const SettingsSection = (props) => {
20
19
  Name: event.target.value,
21
20
  });
22
21
  };
23
- return (_jsxs(_Fragment, { children: [_jsxs(Tabs, { className: "twa:mb-2", children: [_jsx(Tabs.Tab, { children: "Settings" }), _jsx(Tabs.Content, { children: _jsx(Flex, { flexDirection: "row", children: _jsx(FormLayout, { className: "twa:max-w-[300px] twa:w-full", children: _jsx(FormRow, { label: "Name", children: _jsx(Input, { className: "twa:w-full", "data-name": "layout-name", onChange: onNameChange, value: layout?.Name ?? '' }) }) }) }) })] }), _jsxs(Tabs, { className: "twa:mb-2", children: [_jsx(Tabs.Tab, { children: "Grid Type" }), _jsx(Tabs.Content, { children: _jsxs(Flex, { flexDirection: "column", children: [_jsx(Radio, { "data-name": "layout-type-table", disabled: true, checked: !isPivotLayout(layout), children: "Table" }), _jsx(Radio, { "data-name": "layout-type-pivot", disabled: true, checked: isPivotLayout(layout), children: "Pivot" })] }) })] })] }));
22
+ return (_jsxs(Flex, { flexDirection: "column", className: "twa:gap-3 twa:p-3", children: [_jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Name" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Provide a unique name for this Layout" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsx(Input, { className: "twa:max-w-[300px] twa:w-full", "data-name": "layout-name", onChange: onNameChange, value: layout?.Name ?? '' }) })] }), _jsxs(Card, { shadow: false, children: [_jsx(Card.Title, { children: _jsx(Box, { className: "twa:font-medium", children: "Grid Type" }) }), _jsx(Card.Body, { className: "twa:p-1", children: _jsxs(Flex, { flexDirection: "column", className: "twa:gap-2", children: [_jsx(Box, { "data-name": "layout-type-table", children: _jsx(TypeRadio, { disabled: true, checked: !isPivotLayout(layout), text: "Table", description: "A flat layout \u2014 data is shown in standard rows and columns, one row per record" }) }), _jsx(Box, { "data-name": "layout-type-pivot", children: _jsx(TypeRadio, { disabled: true, checked: isPivotLayout(layout), text: "Pivot", description: "An aggregated layout \u2014 data is grouped and summarized by pivot columns" }) })] }) })] })] }));
24
23
  };
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import * as React from 'react';
3
3
  import SimpleButton from '../../../../components/SimpleButton';
4
- import { Tabs } from '../../../../components/Tabs';
4
+ import { Card } from '../../../../components/Card';
5
5
  import { Tag } from '../../../../components/Tag';
6
6
  import { getLayoutSortViewItems } from '../../../../Strategy/Utilities/Layout/getLayoutSortViewItems';
7
7
  import { useAdaptable } from '../../../AdaptableContext';
@@ -55,5 +55,5 @@ export const SortSection = (props) => {
55
55
  }),
56
56
  });
57
57
  }, [layout]);
58
- return (_jsxs(Tabs, { className: "twa:h-full", children: [_jsx(Tabs.Tab, { children: "Column Sorts" }), _jsx(Tabs.Content, { children: _jsx(ValueSelector, { showFilterInput: true, filter: columnFilter, toIdentifier: (option) => `${option.columnId}`, toLabel: (option) => option.friendlyName ?? option.columnId, toListLabel: (column) => (_jsx(ColumnRow, { onSortChange: handleSortChange, layout: layout, column: column })), options: sortedSortColumns, value: (layout.ColumnSorts ?? []).map((sort) => sort.ColumnId), allowReorder: () => true, onChange: handleColumnsSelectionChange }) })] }));
58
+ return (_jsx(Flex, { flexDirection: "column", className: "twa:gap-3 twa:p-3 twa:h-full", children: _jsxs(Card, { shadow: false, className: "twa:flex-1 twa:min-h-0", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Column Sorts" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Select columns to sort and set their sort order. Drag to change sort priority." })] }), _jsx(Card.Body, { className: "twa:p-1 twa:min-h-[200px]", children: _jsx(ValueSelector, { showFilterInput: true, filter: columnFilter, toIdentifier: (option) => `${option.columnId}`, toLabel: (option) => option.friendlyName ?? option.columnId, toListLabel: (column) => (_jsx(ColumnRow, { onSortChange: handleSortChange, layout: layout, column: column })), options: sortedSortColumns, value: (layout.ColumnSorts ?? []).map((sort) => sort.ColumnId), allowReorder: () => true, onChange: handleColumnsSelectionChange }) })] }) }));
59
59
  };
@@ -7,7 +7,7 @@ import { useOnePageAdaptableWizardContext } from '../../Wizard/OnePageAdaptableW
7
7
  import { Box } from '../../../components/Flex';
8
8
  export const isValidNamedQueryExpression = (data, api) => {
9
9
  if (!data.BooleanExpression) {
10
- return 'An expression is required.';
10
+ return 'An expression is required';
11
11
  }
12
12
  const valid = api.expressionApi.isValidBooleanExpression(data.BooleanExpression, NamedQueryModuleId);
13
13
  if (!valid) {
@@ -1,11 +1,9 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import WizardPanel from '../../../components/WizardPanel';
3
- import FormLayout, { FormRow } from '../../../components/FormLayout';
4
- import ErrorBox from '../../../components/ErrorBox';
5
- import { useOnePageAdaptableWizardContext } from '../../Wizard/OnePageAdaptableWizard';
6
- import AdaptableInput from '../../Components/AdaptableInput';
2
+ import { useOnePageAdaptableWizardContext, SummaryText } from '../../Wizard/OnePageAdaptableWizard';
7
3
  import { Tag } from '../../../components/Tag';
8
- import { Box } from '../../../components/Flex';
4
+ import { Box, Flex } from '../../../components/Flex';
5
+ import { Card } from '../../../components/Card';
6
+ import Input from '../../../components/Input';
9
7
  export const isValidNamedQuerySettings = (data, api) => {
10
8
  const validationResult = api.namedQueryApi.isValidNamedQuery(data);
11
9
  const ErrorMessage = !validationResult.valid ? validationResult.message : null;
@@ -15,18 +13,15 @@ export const isValidNamedQuerySettings = (data, api) => {
15
13
  return ErrorMessage;
16
14
  };
17
15
  export const renderNamedQuerySettingsSummary = (data) => {
18
- return (_jsxs(Box, { className: "twa:text-2", children: ["Name: ", _jsx(Tag, { children: data.Name })] }));
16
+ return (_jsxs(SummaryText, { children: ["Name ", _jsx(Tag, { children: data.Name || 'Not specified' })] }));
19
17
  };
20
18
  export const NamedQuerySettingsWizardSection = (props) => {
21
- const { data, api } = useOnePageAdaptableWizardContext();
22
- const valid = isValidNamedQuerySettings(data, api);
23
- const errorMessage = valid === true ? null : valid;
24
- const handleColumnNameChange = (event) => {
25
- let e = event.target;
19
+ const { data } = useOnePageAdaptableWizardContext();
20
+ const handleNameChange = (event) => {
26
21
  props.onChange({
27
22
  ...data,
28
- Name: e.value,
23
+ Name: event.target.value,
29
24
  });
30
25
  };
31
- return (_jsx(WizardPanel, { "data-name": 'named-query-settings', children: _jsxs(FormLayout, { children: [_jsx(FormRow, { label: "Name", children: _jsx(AdaptableInput, { "data-name": "query-name", value: data.Name, autoFocus: true, className: "twa:w-[300px]", type: "text", placeholder: "Enter Named Query Name", onChange: (e) => handleColumnNameChange(e) }) }), ' ', errorMessage ? (_jsx(FormRow, { label: "", children: _jsx(ErrorBox, { children: errorMessage }) })) : null] }) }));
26
+ return (_jsx(Box, { "data-name": "named-query-settings", children: _jsx(Flex, { flexDirection: "column", className: "twa:gap-3 twa:p-3", children: _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Name" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Provide a unique name for the Named Query" })] }), _jsx(Card.Body, { className: "twa:p-1", children: _jsx(Input, { "data-name": "query-name", value: data.Name ?? '', autoFocus: true, className: "twa:max-w-[300px] twa:w-full", type: "text", placeholder: "Enter name for Named Query", onChange: handleNameChange }) })] }) }) }));
32
27
  };
@@ -39,9 +39,7 @@ export function NamedQueryWizard(props) {
39
39
  details: 'Specify a unique Name for the Named Query',
40
40
  renderSummary: renderNamedQuerySettingsSummary,
41
41
  isValid: isValidNamedQuerySettings,
42
- render: () => {
43
- return _jsx(NamedQuerySettingsWizardSection, { onChange: setNamedQuery });
44
- },
42
+ render: () => _jsx(NamedQuerySettingsWizardSection, { onChange: setNamedQuery }),
45
43
  },
46
44
  {
47
45
  details: 'Select Named Query Tags',
@@ -1,6 +1,10 @@
1
1
  import * as React from 'react';
2
2
  import { PlusMinusNudge } from '../../../types';
3
+ import { OnePageAdaptableWizardContextType } from '../../Wizard/OnePageAdaptableWizard';
4
+ import { AdaptableApi } from '../../../Api/AdaptableApi';
3
5
  export declare function PlusMinusRuleSummary(): React.JSX.Element;
6
+ export declare const PlusMinusRuleStepSummary: React.FunctionComponent;
7
+ export declare const isRuleValid: (data: PlusMinusNudge, api: AdaptableApi, context: OnePageAdaptableWizardContextType<PlusMinusNudge>) => string | true;
4
8
  interface PlusMinusRuleWizardSectionProps {
5
9
  onChange: (data: PlusMinusNudge) => void;
6
10
  defaultPredicateId: string;