@adaptabletools/adaptable-cjs 23.0.0-canary.8 → 23.0.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 (304) hide show
  1. package/index.css +42 -53
  2. package/package.json +1 -1
  3. package/src/{Utilities → AdaptableState/Aggregations}/weightedAverage.js +2 -3
  4. package/src/AdaptableState/Common/Enums.d.ts +0 -12
  5. package/src/AdaptableState/Common/Enums.js +1 -16
  6. package/src/{Utilities → AdaptableState/Common}/MenuItem.d.ts +4 -4
  7. package/src/{Utilities → AdaptableState/Common}/MenuItem.js +1 -1
  8. package/src/AdaptableState/StyledColumns/BulletChartStyle.d.ts +5 -5
  9. package/src/AdaptableState/StyledColumns/Common/{BarChartCellText.d.ts → BarStyleProperties.d.ts} +34 -10
  10. package/src/AdaptableState/StyledColumns/GradientStyle.d.ts +2 -2
  11. package/src/AdaptableState/StyledColumns/PercentBarStyle.d.ts +2 -2
  12. package/src/AdaptableState/StyledColumns/RangeBarStyle.d.ts +5 -5
  13. package/src/Api/Implementation/AlertApiImpl.js +1 -1
  14. package/src/Api/Implementation/ChartingApiImpl.js +5 -5
  15. package/src/Api/Implementation/ExportApiImpl.js +1 -1
  16. package/src/Api/Implementation/LayoutHelpers.js +2 -3
  17. package/src/Api/Implementation/QuickSearchApiImpl.js +4 -4
  18. package/src/Api/Implementation/ThemeApiImpl.js +2 -2
  19. package/src/Api/Internal/ActionColumnInternalApi.js +2 -2
  20. package/src/Api/Internal/AlertInternalApi.js +1 -1
  21. package/src/Api/Internal/ChartingInternalApi.js +2 -2
  22. package/src/Api/Internal/ColumnInternalApi.js +2 -2
  23. package/src/Api/Internal/EventInternalApi.js +3 -4
  24. package/src/Api/Internal/ExportInternalApi.js +2 -2
  25. package/src/Api/Internal/FormatColumnInternalApi.js +4 -4
  26. package/src/Api/Internal/GridInternalApi.js +1 -1
  27. package/src/Api/Internal/StyledColumnInternalApi.js +6 -6
  28. package/src/Redux/ActionsReducers/ExportRedux.js +1 -1
  29. package/src/Redux/ActionsReducers/InternalRedux.js +1 -1
  30. package/src/Redux/Store/AdaptableReduxLocalStorageEngine.js +2 -3
  31. package/src/Redux/Store/AdaptableReduxMerger.js +7 -9
  32. package/src/Redux/Store/AdaptableStore.js +5 -5
  33. package/src/Strategy/AdaptableModuleBase.d.ts +1 -1
  34. package/src/Strategy/AdaptableModuleBase.js +1 -1
  35. package/src/Strategy/AlertModule.d.ts +1 -1
  36. package/src/Strategy/AlertModule.js +2 -2
  37. package/src/Strategy/BulkUpdateModule.d.ts +1 -1
  38. package/src/Strategy/CalculatedColumnModule.d.ts +2 -2
  39. package/src/Strategy/CellSummaryModule.d.ts +2 -2
  40. package/src/Strategy/ChartingModule.d.ts +1 -1
  41. package/src/Strategy/ChartingModule.js +4 -4
  42. package/src/Strategy/ColumnInfoModule.d.ts +2 -2
  43. package/src/Strategy/CommentModule.d.ts +1 -1
  44. package/src/Strategy/CustomSortModule.d.ts +1 -1
  45. package/src/Strategy/ExportModule.js +2 -2
  46. package/src/Strategy/FlashingCellModule.d.ts +1 -1
  47. package/src/Strategy/FreeTextColumnModule.d.ts +1 -1
  48. package/src/Strategy/GridInfoModule.d.ts +2 -2
  49. package/src/Strategy/LayoutModule.js +2 -2
  50. package/src/Strategy/NoteModule.d.ts +1 -1
  51. package/src/Strategy/PlusMinusModule.d.ts +1 -1
  52. package/src/Strategy/PlusMinusModule.js +8 -8
  53. package/src/Strategy/SettingsPanelModule.d.ts +2 -2
  54. package/src/Strategy/SmartEditModule.d.ts +1 -1
  55. package/src/Strategy/SystemStatusModule.d.ts +2 -2
  56. package/src/Strategy/TeamSharingModule.js +4 -4
  57. package/src/Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions.js +2 -3
  58. package/src/Utilities/ExpressionFunctions/expressionFunctionUtils.js +2 -2
  59. package/src/Utilities/ExpressionFunctions/observableExpressionFunctions.js +2 -3
  60. package/src/Utilities/Extensions/ArrayExtensions.d.ts +32 -0
  61. package/src/Utilities/Extensions/ArrayExtensions.js +54 -1
  62. package/src/Utilities/Extensions/NumberExtensions.d.ts +21 -0
  63. package/src/Utilities/Extensions/NumberExtensions.js +78 -0
  64. package/src/Utilities/Extensions/ObjectExtensions.d.ts +44 -0
  65. package/src/Utilities/Extensions/ObjectExtensions.js +277 -0
  66. package/src/Utilities/Extensions/StringExtensions.d.ts +26 -0
  67. package/src/Utilities/Extensions/StringExtensions.js +49 -3
  68. package/src/Utilities/Helpers/AdaptableHelper.js +7 -7
  69. package/src/Utilities/Helpers/{alertFormHelper.js → AlertHelper.js} +1 -1
  70. package/src/Utilities/Helpers/DateHelper.js +2 -2
  71. package/src/Utilities/Helpers/{FormatHelper.js → DisplayFormatHelper.js} +5 -5
  72. package/src/Utilities/Helpers/Helper.d.ts +0 -6
  73. package/src/Utilities/Helpers/Helper.js +0 -38
  74. package/src/Utilities/Helpers/{QuickSearchStyleHelper.js → QuickSearchHelper.js} +2 -3
  75. package/src/Utilities/Helpers/{ScheduleHelper.d.ts → Scheduling/ScheduleHelper.d.ts} +1 -1
  76. package/src/Utilities/Helpers/{ScheduleHelper.js → Scheduling/ScheduleHelper.js} +1 -1
  77. package/src/Utilities/Helpers/{ScheduleJobManager.d.ts → Scheduling/ScheduleJobManager.d.ts} +1 -1
  78. package/src/Utilities/Helpers/{ScheduleJobRunner.d.ts → Scheduling/ScheduleJobRunner.d.ts} +1 -1
  79. package/src/Utilities/Helpers/{ScheduledAlertHelper.d.ts → Scheduling/ScheduledAlertHelper.d.ts} +1 -1
  80. package/src/Utilities/Helpers/{ScheduledAlertHelper.js → Scheduling/ScheduledAlertHelper.js} +4 -4
  81. package/src/Utilities/Helpers/{ScheduledJobsMiddlewareHelper.d.ts → Scheduling/ScheduledJobsMiddlewareHelper.d.ts} +1 -1
  82. package/src/Utilities/Helpers/{ScheduledJobsMiddlewareHelper.js → Scheduling/ScheduledJobsMiddlewareHelper.js} +1 -1
  83. package/src/Utilities/Helpers/{ScheduledReportHelper.d.ts → Scheduling/ScheduledReportHelper.d.ts} +1 -1
  84. package/src/Utilities/Helpers/{ScheduledReportHelper.js → Scheduling/ScheduledReportHelper.js} +1 -1
  85. package/src/Utilities/Helpers/SettingsPanelHelper.d.ts +5 -0
  86. package/src/Utilities/{Defaults/DefaultSettingsPanel.js → Helpers/SettingsPanelHelper.js} +16 -1
  87. package/src/Utilities/Helpers/StyledColumns/BarStylesHelper.d.ts +63 -0
  88. package/src/Utilities/Helpers/{barChartCellText.js → StyledColumns/BarStylesHelper.js} +48 -47
  89. package/src/Utilities/Helpers/{StyledColumnGradientHelper.d.ts → StyledColumns/GradientStyleHelper.d.ts} +4 -4
  90. package/src/Utilities/Helpers/{StyledColumnGradientHelper.js → StyledColumns/GradientStyleHelper.js} +9 -9
  91. package/src/Utilities/Helpers/{IconStylePresets.d.ts → StyledColumns/IconStyleHelper.d.ts} +6 -1
  92. package/src/Utilities/Helpers/{IconStylePresets.js → StyledColumns/IconStyleHelper.js} +16 -0
  93. package/src/Utilities/Helpers/{percentBarPreviewHelper.d.ts → StyledColumns/PercentBarStyleHelper.d.ts} +2 -2
  94. package/src/Utilities/Helpers/{percentBarPreviewHelper.js → StyledColumns/PercentBarStyleHelper.js} +11 -12
  95. package/src/Utilities/Helpers/{SparklineOptionsHelper.js → StyledColumns/SparklineStyleHelper.js} +1 -1
  96. package/src/Utilities/Helpers/StyledColumns/StyledColumnHelper.d.ts +52 -0
  97. package/src/Utilities/Helpers/StyledColumns/StyledColumnHelper.js +124 -0
  98. package/src/Utilities/Helpers/TimingHelper.d.ts +34 -0
  99. package/src/Utilities/{utils/debounce.js → Helpers/TimingHelper.js} +25 -9
  100. package/src/Utilities/ObjectFactory.js +1 -1
  101. package/src/Utilities/Services/CalculatedColumnExpressionService.d.ts +2 -0
  102. package/src/Utilities/Services/CalculatedColumnExpressionService.js +118 -2
  103. package/src/Utilities/Services/LicenseService/index.js +1 -1
  104. package/src/Utilities/Services/RowSummaryService.d.ts +1 -1
  105. package/src/Utilities/Services/RowSummaryService.js +6 -6
  106. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ColumnsList.js +2 -2
  107. package/src/View/Alert/Utilities/getAlertType.js +1 -1
  108. package/src/View/Alert/Utilities/getDefaultAlertDefinition.js +1 -1
  109. package/src/View/Alert/Utilities/mapAlertDefinition.js +1 -1
  110. package/src/View/Alert/Wizard/AlertBehaviourWizardSection.js +1 -1
  111. package/src/View/Alert/Wizard/AlertButtonsEditor.js +3 -3
  112. package/src/View/Alert/Wizard/AlertNotificationWizardSection.js +3 -3
  113. package/src/View/Alert/Wizard/AlertRulesWizardSection.js +1 -1
  114. package/src/View/Alert/Wizard/AlertScheduledWizardSection.js +1 -1
  115. package/src/View/Alert/Wizard/AlertScopeWizardSection.js +1 -1
  116. package/src/View/Alert/Wizard/AlertWizard.js +1 -1
  117. package/src/View/Alert/Wizard/isValidAlertRules.js +1 -1
  118. package/src/View/Charting/ChartingWizard/AgChargingWizard/PreviewChartSection.js +2 -2
  119. package/src/View/Charting/ChartingWizard/AgChargingWizard/SettingsSection.js +2 -2
  120. package/src/View/Charting/ChartingWizard/ExternalChartingWizard/SettingsSection.js +2 -2
  121. package/src/View/Comments/CommentsEditor.js +2 -2
  122. package/src/View/Comments/CommentsPopup.js +2 -2
  123. package/src/View/Components/AdaptableObjectList/AdaptableObjectList.js +4 -6
  124. package/src/View/Components/AdaptableObjectList/objectListActionButtonStyles.d.ts +1 -1
  125. package/src/View/Components/AdaptableObjectList/objectListActionButtonStyles.js +1 -1
  126. package/src/View/Components/Buttons/SuspendToggleButton/SuspendToggleButton.js +2 -2
  127. package/src/View/Components/ColumnFilter/components/ColumnFilterInput.js +2 -2
  128. package/src/View/Components/ColumnFilter/components/ColumnFilterInputList.js +2 -2
  129. package/src/View/Components/ColumnFilter/components/FloatingFilterInputList.js +2 -2
  130. package/src/View/Components/Forms/AdaptableFormControlTextClear.js +2 -1
  131. package/src/View/Components/Popups/AdaptablePopup/useMenuItems.js +2 -2
  132. package/src/View/Components/Popups/AdaptablePopupAlert.js +2 -2
  133. package/src/View/Components/Popups/Utilities.js +5 -5
  134. package/src/View/Components/RangesComponent.d.ts +3 -3
  135. package/src/View/Components/RangesComponent.js +5 -9
  136. package/src/View/Components/ToolPanel/AdaptableToolPanel.js +3 -3
  137. package/src/View/Components/ToolPanel/CustomToolPanelContent.js +2 -3
  138. package/src/View/Components/ToolPanel/ToolPanelPopupSections.js +5 -2
  139. package/src/View/Dashboard/CustomDashboardButton.js +2 -3
  140. package/src/View/Dashboard/Dashboard.js +2 -2
  141. package/src/View/DataChangeHistory/DataChangeHistoryPopup.js +2 -2
  142. package/src/View/DataChangeHistory/DataChangeHistoryTable.js +2 -2
  143. package/src/View/DataChangeHistory/DataChangeHistoryViewPanel.js +2 -2
  144. package/src/View/DataImport/DataImportWizard/sections/DataPreview.js +2 -2
  145. package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +13 -13
  146. package/src/View/FormatColumn/Wizard/FormatColumnPreview.js +4 -4
  147. package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.js +2 -2
  148. package/src/View/Layout/LayoutCloneButton.js +2 -1
  149. package/src/View/Layout/LayoutViewPanel.js +2 -2
  150. package/src/View/Layout/Wizard/sections/RowSummarySection.js +5 -5
  151. package/src/View/Note/NoteEditor.js +2 -2
  152. package/src/View/Note/NotePopup.js +2 -2
  153. package/src/View/PlusMinus/Wizard/PlusMinusSettingsWizardSection.js +7 -7
  154. package/src/View/QuickSearch/QuickSearchPopup.js +4 -4
  155. package/src/View/QuickSearch/useQuickSearchDebounced.js +2 -3
  156. package/src/View/Schedule/Wizard/ScheduleScheduleWizard.js +1 -1
  157. package/src/View/SpecialColumnSettingsWizardStep.js +2 -2
  158. package/src/View/StatusBar/StatusBarPopup.js +4 -0
  159. package/src/View/StyledColumn/Wizard/StyledColumnBadgeSection.js +2 -3
  160. package/src/View/StyledColumn/Wizard/StyledColumnSparklineSettingsSection.js +1 -2
  161. package/src/View/StyledColumn/Wizard/StyledColumnWizard.js +31 -2
  162. package/src/View/StyledColumn/Wizard/StyledColumnWizardBulletSection.js +17 -22
  163. package/src/View/StyledColumn/Wizard/StyledColumnWizardGradientSection.js +9 -10
  164. package/src/View/StyledColumn/Wizard/StyledColumnWizardIconSection.js +5 -6
  165. package/src/View/StyledColumn/Wizard/StyledColumnWizardRangeBarSection.js +14 -17
  166. package/src/View/StyledColumn/Wizard/StyledColumnWizardRatingSection.js +1 -1
  167. package/src/View/StyledColumn/Wizard/StyledColumnWizardScopeSection.js +14 -14
  168. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/{BarChartCellTextLayoutEditor.d.ts → BarStyleCellTextLayoutEditor.d.ts} +4 -4
  169. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/BarStyleCellTextLayoutEditor.js +37 -0
  170. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/{BarChartCellTextPreview.d.ts → BarStyleCellTextPreview.d.ts} +6 -6
  171. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/{BarChartCellTextPreview.js → BarStyleCellTextPreview.js} +9 -9
  172. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/GradientSummaryPreview.d.ts +2 -2
  173. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/GradientSummaryPreview.js +7 -9
  174. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview.d.ts +0 -3
  175. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview.js +5 -6
  176. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBulletPreview.d.ts +0 -3
  177. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBulletPreview.js +8 -11
  178. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnGradientPreview.d.ts +0 -3
  179. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnGradientPreview.js +5 -8
  180. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnIconPreview.d.ts +0 -3
  181. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnIconPreview.js +1 -4
  182. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnPercentBarPreview.d.ts +0 -3
  183. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnPercentBarPreview.js +20 -21
  184. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRangeBarPreview.d.ts +0 -3
  185. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRangeBarPreview.js +8 -11
  186. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRatingPreview.d.ts +0 -3
  187. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRatingPreview.js +4 -5
  188. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnSparklinePreview.d.ts +0 -3
  189. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnSparklinePreview.js +3 -6
  190. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/StyledColumnWizardStyleSection.js +12 -17
  191. package/src/View/UIHelper.js +1 -1
  192. package/src/View/Wizard/CollapsibleWizardCard.js +1 -1
  193. package/src/View/Wizard/OnePageAdaptableWizard.d.ts +7 -0
  194. package/src/View/Wizard/OnePageAdaptableWizard.js +2 -2
  195. package/src/View/Wizard/OnePageWizards.d.ts +8 -0
  196. package/src/View/Wizard/OnePageWizards.js +5 -3
  197. package/src/agGrid/AdaptableAgGrid.js +11 -11
  198. package/src/agGrid/AgGridColumnAdapter.js +30 -29
  199. package/src/agGrid/AgGridExportAdapter.js +3 -3
  200. package/src/agGrid/AgGridMenuAdapter.js +129 -4
  201. package/src/agGrid/cellRenderers/BadgeRenderer.js +2 -2
  202. package/src/agGrid/cellRenderers/BulletChartRenderer.js +8 -8
  203. package/src/agGrid/cellRenderers/IconRenderer.js +7 -8
  204. package/src/agGrid/cellRenderers/PercentBarRenderer.js +9 -9
  205. package/src/agGrid/cellRenderers/RangeBarRenderer.js +10 -11
  206. package/src/agGrid/cellRenderers/RatingRenderer.js +6 -6
  207. package/src/agGrid/editors/AdaptableDateEditor/index.js +3 -3
  208. package/src/components/ColorPicker/ColorPicker.js +2 -2
  209. package/src/components/Datepicker/index.js +2 -2
  210. package/src/components/DragAndDropContext/ModuleManager.js +5 -2
  211. package/src/components/DragAndDropContext/types.d.ts +7 -0
  212. package/src/components/FormLayout/index.js +2 -2
  213. package/src/components/OverlayTrigger/index.js +2 -2
  214. package/src/env.js +2 -2
  215. package/src/layout-manager/src/isLayoutEqual.js +4 -5
  216. package/src/metamodel/adaptable.metamodel.d.ts +41 -8
  217. package/src/metamodel/adaptable.metamodel.js +1 -1
  218. package/src/migration/VersionUpgrade23.js +2 -2
  219. package/src/types.d.ts +3 -3
  220. package/tsconfig.cjs.tsbuildinfo +1 -1
  221. package/src/AdaptableState/StyledColumns/Common/BarChartCellText.js +0 -7
  222. package/src/AdaptableState/StyledColumns/Common/BarChartMarker.d.ts +0 -24
  223. package/src/Utilities/Defaults/DefaultSettingsPanel.d.ts +0 -3
  224. package/src/Utilities/Helpers/barChartCellText.d.ts +0 -63
  225. package/src/Utilities/Helpers/iconStyledColumnColumnSupport.d.ts +0 -5
  226. package/src/Utilities/Helpers/iconStyledColumnColumnSupport.js +0 -18
  227. package/src/Utilities/Helpers/resolveSettingsPanelNavigation.d.ts +0 -3
  228. package/src/Utilities/Helpers/resolveSettingsPanelNavigation.js +0 -19
  229. package/src/Utilities/Helpers/styledColumnRowKindSupport.d.ts +0 -25
  230. package/src/Utilities/Helpers/styledColumnRowKindSupport.js +0 -70
  231. package/src/Utilities/Services/CalculatedColumnSyntheticChange.d.ts +0 -4
  232. package/src/Utilities/Services/CalculatedColumnSyntheticChange.js +0 -120
  233. package/src/Utilities/utils/chunk.d.ts +0 -6
  234. package/src/Utilities/utils/chunk.js +0 -20
  235. package/src/Utilities/utils/clamp.d.ts +0 -5
  236. package/src/Utilities/utils/clamp.js +0 -10
  237. package/src/Utilities/utils/cloneDeepWith.d.ts +0 -9
  238. package/src/Utilities/utils/cloneDeepWith.js +0 -70
  239. package/src/Utilities/utils/debounce.d.ts +0 -20
  240. package/src/Utilities/utils/flatten.d.ts +0 -5
  241. package/src/Utilities/utils/flatten.js +0 -10
  242. package/src/Utilities/utils/flattenDeep.d.ts +0 -5
  243. package/src/Utilities/utils/flattenDeep.js +0 -10
  244. package/src/Utilities/utils/get.d.ts +0 -6
  245. package/src/Utilities/utils/get.js +0 -38
  246. package/src/Utilities/utils/index.d.ts +0 -22
  247. package/src/Utilities/utils/index.js +0 -48
  248. package/src/Utilities/utils/isArray.d.ts +0 -6
  249. package/src/Utilities/utils/isArray.js +0 -8
  250. package/src/Utilities/utils/isEqual.d.ts +0 -5
  251. package/src/Utilities/utils/isEqual.js +0 -127
  252. package/src/Utilities/utils/isObject.d.ts +0 -6
  253. package/src/Utilities/utils/isObject.js +0 -12
  254. package/src/Utilities/utils/isPlainObject.d.ts +0 -6
  255. package/src/Utilities/utils/isPlainObject.js +0 -20
  256. package/src/Utilities/utils/kebabCase.d.ts +0 -5
  257. package/src/Utilities/utils/kebabCase.js +0 -12
  258. package/src/Utilities/utils/merge.d.ts +0 -11
  259. package/src/Utilities/utils/merge.js +0 -44
  260. package/src/Utilities/utils/mergeWith.d.ts +0 -7
  261. package/src/Utilities/utils/mergeWith.js +0 -50
  262. package/src/Utilities/utils/orderBy.d.ts +0 -8
  263. package/src/Utilities/utils/orderBy.js +0 -33
  264. package/src/Utilities/utils/parseInt.d.ts +0 -6
  265. package/src/Utilities/utils/parseInt.js +0 -12
  266. package/src/Utilities/utils/sentenceCase.d.ts +0 -6
  267. package/src/Utilities/utils/sentenceCase.js +0 -19
  268. package/src/Utilities/utils/startCase.d.ts +0 -5
  269. package/src/Utilities/utils/startCase.js +0 -15
  270. package/src/Utilities/utils/throttle.d.ts +0 -17
  271. package/src/Utilities/utils/throttle.js +0 -23
  272. package/src/Utilities/utils/toNumber.d.ts +0 -5
  273. package/src/Utilities/utils/toNumber.js +0 -42
  274. package/src/Utilities/utils/uniq.d.ts +0 -7
  275. package/src/Utilities/utils/uniq.js +0 -12
  276. package/src/Utilities/utils/uniqBy.d.ts +0 -8
  277. package/src/Utilities/utils/uniqBy.js +0 -25
  278. package/src/Utilities/utils/words.d.ts +0 -7
  279. package/src/Utilities/utils/words.js +0 -13
  280. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/BarChartCellTextLayoutEditor.js +0 -40
  281. package/src/agGrid/buildValueAggregationMenuItem.d.ts +0 -19
  282. package/src/agGrid/buildValueAggregationMenuItem.js +0 -114
  283. package/src/agGrid/cellRenderers/shouldRenderStyledColumnOnRow.d.ts +0 -30
  284. package/src/agGrid/cellRenderers/shouldRenderStyledColumnOnRow.js +0 -58
  285. package/src/agGrid/createAgGridIcon.d.ts +0 -10
  286. package/src/agGrid/createAgGridIcon.js +0 -19
  287. /package/src/{Utilities → AdaptableState/Aggregations}/only.d.ts +0 -0
  288. /package/src/{Utilities → AdaptableState/Aggregations}/only.js +0 -0
  289. /package/src/{Utilities → AdaptableState/Aggregations}/weightedAverage.d.ts +0 -0
  290. /package/src/AdaptableState/StyledColumns/Common/{BarChartMarker.js → BarStyleProperties.js} +0 -0
  291. /package/src/Utilities/Helpers/{ActionColumnWidthHelper.d.ts → ActionColumnHelper.d.ts} +0 -0
  292. /package/src/Utilities/Helpers/{ActionColumnWidthHelper.js → ActionColumnHelper.js} +0 -0
  293. /package/src/Utilities/Helpers/{alertFormHelper.d.ts → AlertHelper.d.ts} +0 -0
  294. /package/src/Utilities/Helpers/{chartingHelper.d.ts → ChartHelper.d.ts} +0 -0
  295. /package/src/Utilities/Helpers/{chartingHelper.js → ChartHelper.js} +0 -0
  296. /package/src/Utilities/Helpers/{FormatHelper.d.ts → DisplayFormatHelper.d.ts} +0 -0
  297. /package/src/Utilities/Helpers/{plusMinusTriggerKeys.d.ts → PlusMinusHelper.d.ts} +0 -0
  298. /package/src/Utilities/Helpers/{plusMinusTriggerKeys.js → PlusMinusHelper.js} +0 -0
  299. /package/src/Utilities/Helpers/{QuickSearchStyleHelper.d.ts → QuickSearchHelper.d.ts} +0 -0
  300. /package/src/Utilities/Helpers/{ScheduleJobManager.js → Scheduling/ScheduleJobManager.js} +0 -0
  301. /package/src/Utilities/Helpers/{ScheduleJobRunner.js → Scheduling/ScheduleJobRunner.js} +0 -0
  302. /package/src/Utilities/Helpers/{SparklineOptionsHelper.d.ts → StyledColumns/SparklineStyleHelper.d.ts} +0 -0
  303. /package/src/Utilities/Helpers/{ThemeHelpers.d.ts → ThemeHelper.d.ts} +0 -0
  304. /package/src/Utilities/Helpers/{ThemeHelpers.js → ThemeHelper.js} +0 -0
@@ -16,13 +16,12 @@ const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
16
16
  const AdaptableInput_1 = tslib_1.__importDefault(require("../../Components/AdaptableInput"));
17
17
  const Flex_1 = require("../../../components/Flex");
18
18
  const BulletRangesSummaryPreview_1 = require("./StyledColumnWizardStyleSection/Components/BulletRangesSummaryPreview");
19
- const StyledColumnBulletPreview_1 = require("./StyledColumnWizardStyleSection/Components/StyledColumnBulletPreview");
20
19
  const NewSelect_1 = require("../../../components/NewSelect");
21
20
  const StyledColumnSliceStyleEditors_1 = require("./StyledColumnSliceStyleEditors");
22
21
  const Card_1 = require("../../../components/Card");
23
22
  const SummaryColorTag_1 = require("../../Wizard/SummaryColorTag");
24
- const barChartCellText_1 = require("../../../Utilities/Helpers/barChartCellText");
25
- const BarChartCellTextLayoutEditor_1 = require("./StyledColumnWizardStyleSection/Components/BarChartCellTextLayoutEditor");
23
+ const BarStylesHelper_1 = require("../../../Utilities/Helpers/StyledColumns/BarStylesHelper");
24
+ const BarStyleCellTextLayoutEditor_1 = require("./StyledColumnWizardStyleSection/Components/BarStyleCellTextLayoutEditor");
26
25
  const BULLET_STYLE_FORM_SIZES = ['200px', '1fr'];
27
26
  const getTargetSummary = (target) => {
28
27
  if (target == undefined) {
@@ -55,12 +54,8 @@ const formatBulletOriginLabel = (origin) => {
55
54
  }
56
55
  return origin;
57
56
  };
58
- const formatBulletCellTextSummary = (cellText) => cellText
59
- ?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value'))
60
- .join(' + ') ?? '';
61
- const formatBulletToolTipSummary = (toolTipText) => toolTipText
62
- ?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value'))
63
- .join(' + ') ?? '';
57
+ const formatBulletCellTextSummary = (cellText) => cellText?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value')).join(' + ') ?? '';
58
+ const formatBulletToolTipSummary = (toolTipText) => toolTipText?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value')).join(' + ') ?? '';
64
59
  const getStyledColumnBulletRangesViewValues = (data) => {
65
60
  const bullet = data.BulletChartStyle;
66
61
  if (!bullet) {
@@ -105,10 +100,10 @@ const buildStyledColumnBulletStyleSummaryStrings = (bullet, options) => {
105
100
  if (bullet.BackColor) {
106
101
  items.push(`Back Colour: ${bullet.BackColor}`);
107
102
  }
108
- if ((0, barChartCellText_1.hasBarChartCellTextConfigured)(bullet.CellTextProperties)) {
109
- const tokens = (0, barChartCellText_1.getActiveBarChartCellTextTokens)(bullet.CellTextProperties);
103
+ if ((0, BarStylesHelper_1.hasBarStyleCellTextConfigured)(bullet.CellTextProperties)) {
104
+ const tokens = (0, BarStylesHelper_1.getActiveBarStyleCellTextTokens)(bullet.CellTextProperties);
110
105
  items.push(`Cell Text: ${formatBulletCellTextSummary(tokens)}`);
111
- const layoutSummary = (0, barChartCellText_1.formatBarChartCellTextLayoutSummary)((0, barChartCellText_1.resolveBarChartCellTextLayout)(bullet.CellTextProperties));
106
+ const layoutSummary = (0, BarStylesHelper_1.formatBarStyleCellTextLayoutSummary)((0, BarStylesHelper_1.resolveBarStyleCellTextLayout)(bullet.CellTextProperties));
112
107
  if (layoutSummary) {
113
108
  items.push(`Placement: ${layoutSummary}`);
114
109
  }
@@ -300,9 +295,7 @@ const StyledColumnWizardBulletSection = (props) => {
300
295
  }
301
296
  if (mode === 'Column') {
302
297
  // Use the first available numeric column (excluding the styled column itself)
303
- const candidate = api.columnApi
304
- .getNumericColumns()
305
- .find((c) => c.columnId !== data.ColumnId);
298
+ const candidate = api.columnApi.getNumericColumns().find((c) => c.columnId !== data.ColumnId);
306
299
  setTarget(candidate?.columnId ?? '');
307
300
  return;
308
301
  }
@@ -334,11 +327,11 @@ const StyledColumnWizardBulletSection = (props) => {
334
327
  };
335
328
  // -- Cell text -------------------------------------------------------------
336
329
  const toggleCellText = (token, show) => {
337
- update((0, barChartCellText_1.toggleBarChartCellTextToken)(bullet.CellTextProperties, token, show));
330
+ update((0, BarStylesHelper_1.toggleBarStyleCellTextToken)(bullet.CellTextProperties, token, show));
338
331
  };
339
332
  const onCellTextPlacementChange = (token, patch) => {
340
333
  update({
341
- CellTextProperties: (0, barChartCellText_1.patchBarChartCellTextPlacement)(bullet.CellTextProperties, token, patch),
334
+ CellTextProperties: (0, BarStylesHelper_1.patchBarStyleCellTextPlacement)(bullet.CellTextProperties, token, patch),
342
335
  });
343
336
  };
344
337
  const toggleToolTipText = (token, checked) => {
@@ -368,7 +361,9 @@ const StyledColumnWizardBulletSection = (props) => {
368
361
  : typeof primaryTarget?.Value === 'number'
369
362
  ? primaryTarget.Value
370
363
  : undefined;
371
- const columnTargetValue = typeof primaryTarget === 'string' && primaryTarget !== 'Col-Avg' && primaryTarget !== 'Col-Median'
364
+ const columnTargetValue = typeof primaryTarget === 'string' &&
365
+ primaryTarget !== 'Col-Avg' &&
366
+ primaryTarget !== 'Col-Median'
372
367
  ? primaryTarget
373
368
  : typeof primaryTarget?.Value === 'string'
374
369
  ? primaryTarget.Value
@@ -380,7 +375,7 @@ const StyledColumnWizardBulletSection = (props) => {
380
375
  Size: markerCfg?.Size ?? (markerCfg?.Shape === 'Line' ? 2 : 8),
381
376
  };
382
377
  const cellTextProperties = bullet.CellTextProperties;
383
- const cellTextDisabled = !(0, barChartCellText_1.hasBarChartCellTextConfigured)(cellTextProperties) || disabled;
378
+ const cellTextDisabled = !(0, BarStylesHelper_1.hasBarStyleCellTextConfigured)(cellTextProperties) || disabled;
384
379
  return ((0, jsx_runtime_1.jsxs)(Flex_1.Box, { children: [(0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Target" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Select a target value for the bullet scale" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsxs)(FormLayout_1.default, { sizes: [...BULLET_STYLE_FORM_SIZES], children: [(0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Target:", children: (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:max-w-[180px]", children: (0, jsx_runtime_1.jsx)(NewSelect_1.SingleSelect, { className: "twa:w-full", value: currentMode, onValueChange: (v) => handleTargetModeChange(v), items: [
385
380
  { value: 'None', label: 'None' },
386
381
  { value: 'Number', label: 'Fixed Number' },
@@ -392,7 +387,7 @@ const StyledColumnWizardBulletSection = (props) => {
392
387
  { value: 'Vertical', label: 'Vertical' },
393
388
  ] }) }) }), bullet.Orientation === 'Vertical' && ((0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "", children: (0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:text-xs twa:text-neutral-500", children: ["Tip: vertical bullet charts need a tall row height to be readable (we recommend at least 60px). Set ", (0, jsx_runtime_1.jsx)("code", { children: "rowHeight" }), " on ", (0, jsx_runtime_1.jsx)("code", { children: " gridOptions " }), " or use", ' ', (0, jsx_runtime_1.jsx)("code", { children: "getRowHeight" }), "."] }) })), (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Bar Colour:", children: (0, jsx_runtime_1.jsx)(ColorPicker_1.ColorPicker, { disabled: disabled, api: api, value: bullet.Bar?.Color, onChange: (c) => updateBar({ Color: c }) }) }), (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: bullet.Orientation === 'Vertical' ? 'Bar Width (px):' : 'Bar Height (px):', children: (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:max-w-[100px]", children: (0, jsx_runtime_1.jsx)(AdaptableInput_1.default, { type: "number", min: 1, value: bullet.Bar?.Height ?? '', onChange: (e) => updateBar({
394
389
  Height: e.target.value === '' ? undefined : Number(e.target.value),
395
- }), placeholder: "8" }) }) }), (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Origin:", children: (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:max-w-[160px]", children: (0, jsx_runtime_1.jsx)(NewSelect_1.SingleSelect, { className: "twa:w-full", value: typeof bullet.Origin === 'number' ? 'Number' : (bullet.Origin ?? 'Auto'), onValueChange: (v) => {
390
+ }), placeholder: "8" }) }) }), (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Origin:", children: (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:max-w-[160px]", children: (0, jsx_runtime_1.jsx)(NewSelect_1.SingleSelect, { className: "twa:w-full", value: typeof bullet.Origin === 'number' ? 'Number' : bullet.Origin ?? 'Auto', onValueChange: (v) => {
396
391
  if (v === 'Auto' || v === 'Zero') {
397
392
  update({ Origin: v });
398
393
  }
@@ -402,7 +397,7 @@ const StyledColumnWizardBulletSection = (props) => {
402
397
  }, items: [
403
398
  { value: 'Auto', label: 'Auto' },
404
399
  { value: 'Zero', label: 'Zero' },
405
- ] }) }) })] }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Cell Text" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Pick which values to display and where each one sits around the bar" })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card.Body, { children: [(0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...BULLET_STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Cell Text Layout:", children: (0, jsx_runtime_1.jsx)(BarChartCellTextLayoutEditor_1.BarChartCellTextLayoutEditor, { disabled: disabled, cellTextProperties: cellTextProperties, onToggle: toggleCellText, onPlacementChange: onCellTextPlacementChange }) }) }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: `twa:mt-3 twa:pt-3 twa:border-t twa:border-foreground/15 ${cellTextDisabled ? 'twa:opacity-50' : ''}`, children: (0, jsx_runtime_1.jsx)(StyledColumnSliceStyleEditors_1.StyledColumnFontStyleEditor, { api: api, disabled: cellTextDisabled, value: bullet.Font, onChange: (next) => {
400
+ ] }) }) })] }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Cell Text" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Pick which values to display and where each one sits around the bar" })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card.Body, { children: [(0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...BULLET_STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsx)(BarStyleCellTextLayoutEditor_1.BarStyleCellTextLayoutEditor, { disabled: disabled, cellTextProperties: cellTextProperties, onToggle: toggleCellText, onPlacementChange: onCellTextPlacementChange }) }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: `twa:mt-3 twa:pt-3 twa:border-t twa:border-foreground/15 ${cellTextDisabled ? 'twa:opacity-50' : ''}`, children: (0, jsx_runtime_1.jsx)(StyledColumnSliceStyleEditors_1.StyledColumnFontStyleEditor, { api: api, disabled: cellTextDisabled, value: bullet.Font, onChange: (next) => {
406
401
  if (next) {
407
402
  update({ Font: next });
408
403
  }
@@ -411,6 +406,6 @@ const StyledColumnWizardBulletSection = (props) => {
411
406
  delete cleaned.Font;
412
407
  props.onChange({ ...data, BulletChartStyle: cleaned });
413
408
  }
414
- } }) })] })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Tooltip" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether to display a tooltip" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...BULLET_STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsxs)(FormLayout_1.FormRow, { label: "Tooltip Display:", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, checked: bullet.ToolTipText?.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', (0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, className: "twa:ml-3", checked: bullet.ToolTipText?.includes('PercentageValue'), onChange: (checked) => toggleToolTipText('PercentageValue', checked), children: "Percent Value" })] }) }) })] }), (0, jsx_runtime_1.jsx)(StyledColumnBulletPreview_1.StyledColumnBulletPreviewCard, { data: data })] }));
409
+ } }) })] })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Tooltip" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether to display a tooltip" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...BULLET_STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsxs)(FormLayout_1.FormRow, { label: "Tooltip Display:", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, checked: bullet.ToolTipText?.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', (0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, className: "twa:ml-3", checked: bullet.ToolTipText?.includes('PercentageValue'), onChange: (checked) => toggleToolTipText('PercentageValue', checked), children: "Percent Value" })] }) }) })] })] }));
415
410
  };
416
411
  exports.StyledColumnWizardBulletSection = StyledColumnWizardBulletSection;
@@ -11,11 +11,10 @@ const Tag_1 = require("../../../components/Tag");
11
11
  const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
12
12
  const Flex_1 = require("../../../components/Flex");
13
13
  const NumberInput_1 = require("../../../components/Input/NumberInput");
14
- const StyledColumnGradientHelper_1 = require("../../../Utilities/Helpers/StyledColumnGradientHelper");
14
+ const GradientStyleHelper_1 = require("../../../Utilities/Helpers/StyledColumns/GradientStyleHelper");
15
15
  const StyledColumnSliceStyleEditors_1 = require("./StyledColumnSliceStyleEditors");
16
16
  const Card_1 = require("../../../components/Card");
17
17
  const SummaryColorTag_1 = require("../../Wizard/SummaryColorTag");
18
- const StyledColumnGradientPreview_1 = require("./StyledColumnWizardStyleSection/Components/StyledColumnGradientPreview");
19
18
  const STYLE_FORM_SIZES = ['200px', '1fr'];
20
19
  function formatGradientToolTipSummary(opts) {
21
20
  return opts
@@ -23,8 +22,8 @@ function formatGradientToolTipSummary(opts) {
23
22
  .join(' + ');
24
23
  }
25
24
  const buildStyledColumnGradientStyleSummaryStrings = (gs, options) => {
26
- const minA = gs.MinAlpha ?? StyledColumnGradientHelper_1.DEFAULT_GRADIENT_MIN_ALPHA;
27
- const maxA = gs.MaxAlpha ?? StyledColumnGradientHelper_1.DEFAULT_GRADIENT_MAX_ALPHA;
25
+ const minA = gs.MinAlpha ?? GradientStyleHelper_1.DEFAULT_GRADIENT_MIN_ALPHA;
26
+ const maxA = gs.MaxAlpha ?? GradientStyleHelper_1.DEFAULT_GRADIENT_MAX_ALPHA;
28
27
  const items = [`Alpha: ${minA} → ${maxA}`];
29
28
  if (gs.AutoContrastText) {
30
29
  items.push('Auto Contrast: On');
@@ -90,10 +89,10 @@ const StyledColumnWizardGradientSection = (props) => {
90
89
  patchGradient({ ToolTipText: next });
91
90
  }
92
91
  };
93
- const minAlphaDisplay = gs.MinAlpha ?? StyledColumnGradientHelper_1.DEFAULT_GRADIENT_MIN_ALPHA;
94
- const maxAlphaDisplay = gs.MaxAlpha ?? StyledColumnGradientHelper_1.DEFAULT_GRADIENT_MAX_ALPHA;
95
- return ((0, jsx_runtime_1.jsxs)(Flex_1.Box, { children: [(0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Transparency" }), (0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[480px]", children: ["Used at low and high ends of range; defaults are ", StyledColumnGradientHelper_1.DEFAULT_GRADIENT_MIN_ALPHA, " &", ' ', StyledColumnGradientHelper_1.DEFAULT_GRADIENT_MAX_ALPHA, " (Min 0 fades out lowest values)"] })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Alpha range:", children: (0, jsx_runtime_1.jsxs)(Flex_1.Flex, { alignItems: "center", className: "twa:ml-2 twa:flex-wrap twa:gap-3", children: [(0, jsx_runtime_1.jsxs)(Flex_1.Flex, { alignItems: "center", className: "twa:gap-1", children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-sm", children: "Min" }), (0, jsx_runtime_1.jsx)(NumberInput_1.NumberInput, { disabled: disabled, className: "twa:w-20", value: minAlphaDisplay, min: 0, max: 1, step: 0.05, onChange: (v) => {
96
- if (v === StyledColumnGradientHelper_1.DEFAULT_GRADIENT_MIN_ALPHA) {
92
+ const minAlphaDisplay = gs.MinAlpha ?? GradientStyleHelper_1.DEFAULT_GRADIENT_MIN_ALPHA;
93
+ const maxAlphaDisplay = gs.MaxAlpha ?? GradientStyleHelper_1.DEFAULT_GRADIENT_MAX_ALPHA;
94
+ return ((0, jsx_runtime_1.jsxs)(Flex_1.Box, { children: [(0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Transparency" }), (0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[480px]", children: ["Used at low and high ends of range; defaults are ", GradientStyleHelper_1.DEFAULT_GRADIENT_MIN_ALPHA, " &", ' ', GradientStyleHelper_1.DEFAULT_GRADIENT_MAX_ALPHA, " (Min 0 fades out lowest values)"] })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Alpha range:", children: (0, jsx_runtime_1.jsxs)(Flex_1.Flex, { alignItems: "center", className: "twa:ml-2 twa:flex-wrap twa:gap-3", children: [(0, jsx_runtime_1.jsxs)(Flex_1.Flex, { alignItems: "center", className: "twa:gap-1", children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-sm", children: "Min" }), (0, jsx_runtime_1.jsx)(NumberInput_1.NumberInput, { disabled: disabled, className: "twa:w-20", value: minAlphaDisplay, min: 0, max: 1, step: 0.05, onChange: (v) => {
95
+ if (v === GradientStyleHelper_1.DEFAULT_GRADIENT_MIN_ALPHA) {
97
96
  const { MinAlpha: _m, ...rest } = gs;
98
97
  props.onChange({ ...data, GradientStyle: rest });
99
98
  }
@@ -101,7 +100,7 @@ const StyledColumnWizardGradientSection = (props) => {
101
100
  patchGradient({ MinAlpha: v });
102
101
  }
103
102
  } })] }), (0, jsx_runtime_1.jsxs)(Flex_1.Flex, { alignItems: "center", className: "twa:gap-1", children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-sm", children: "Max" }), (0, jsx_runtime_1.jsx)(NumberInput_1.NumberInput, { disabled: disabled, className: "twa:w-20", value: maxAlphaDisplay, min: 0, max: 1, step: 0.05, onChange: (v) => {
104
- if (v === StyledColumnGradientHelper_1.DEFAULT_GRADIENT_MAX_ALPHA) {
103
+ if (v === GradientStyleHelper_1.DEFAULT_GRADIENT_MAX_ALPHA) {
105
104
  const { MaxAlpha: _m, ...rest } = gs;
106
105
  props.onChange({ ...data, GradientStyle: rest });
107
106
  }
@@ -116,6 +115,6 @@ const StyledColumnWizardGradientSection = (props) => {
116
115
  else {
117
116
  patchGradient({ AutoContrastText: true });
118
117
  }
119
- }, children: "Make text readable on tinted backgrounds" }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Tooltip" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[600px]", children: "Set Tooltip properties" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Tooltip:", children: (0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:ml-2", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, checked: gs.ToolTipText?.includes('CellValue'), onChange: (checked) => onToolTipTextChanged('CellValue', checked), children: "Cell Value" }), ' ', (0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, className: "twa:ml-3", checked: gs.ToolTipText?.includes('PercentageValue'), onChange: (checked) => onToolTipTextChanged('PercentageValue', checked), children: "Percent along scale" })] }) }) }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Font" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[480px]", children: "Optional font properties (takes precedence over Format Column)" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(StyledColumnSliceStyleEditors_1.StyledColumnFontStyleEditor, { api: api, disabled: disabled, value: gs.Font, onChange: onFontChange }) })] }), (0, jsx_runtime_1.jsx)(StyledColumnGradientPreview_1.StyledColumnGradientPreviewCard, { data: data }), !data.ColumnId && ((0, jsx_runtime_1.jsx)(ErrorBox_1.default, { className: "twa:mt-2", children: "Select a column before changing Gradient style." }))] }));
118
+ }, children: "Make text readable on tinted backgrounds" }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Tooltip" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[600px]", children: "Set Tooltip properties" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Tooltip:", children: (0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:ml-2", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, checked: gs.ToolTipText?.includes('CellValue'), onChange: (checked) => onToolTipTextChanged('CellValue', checked), children: "Cell Value" }), ' ', (0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, className: "twa:ml-3", checked: gs.ToolTipText?.includes('PercentageValue'), onChange: (checked) => onToolTipTextChanged('PercentageValue', checked), children: "Percent along scale" })] }) }) }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Font" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[480px]", children: "Optional font properties (takes precedence over Format Column)" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(StyledColumnSliceStyleEditors_1.StyledColumnFontStyleEditor, { api: api, disabled: disabled, value: gs.Font, onChange: onFontChange }) })] }), !data.ColumnId && ((0, jsx_runtime_1.jsx)(ErrorBox_1.default, { className: "twa:mt-2", children: "Select a column before changing Gradient style." }))] }));
120
119
  };
121
120
  exports.StyledColumnWizardGradientSection = StyledColumnWizardGradientSection;
@@ -18,12 +18,11 @@ const IconSelector_1 = require("../../../components/IconSelector");
18
18
  const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
19
19
  const AdaptableContext_1 = require("../../AdaptableContext");
20
20
  const AdaptableIconComponent_1 = require("../../Components/AdaptableIconComponent");
21
- const IconStylePresets_1 = require("../../../Utilities/Helpers/IconStylePresets");
21
+ const IconStyleHelper_1 = require("../../../Utilities/Helpers/StyledColumns/IconStyleHelper");
22
22
  const IconRenderer_1 = require("../../../agGrid/cellRenderers/IconRenderer");
23
23
  const Card_1 = require("../../../components/Card");
24
24
  const SummaryColorTag_1 = require("../../Wizard/SummaryColorTag");
25
25
  const StyledColumnSliceStyleEditors_1 = require("./StyledColumnSliceStyleEditors");
26
- const StyledColumnIconPreview_1 = require("./StyledColumnWizardStyleSection/Components/StyledColumnIconPreview");
27
26
  const wizardSelection_1 = require("../../../Utilities/wizardSelection");
28
27
  const STYLE_FORM_SIZES = ['200px', '1fr'];
29
28
  const detectIconKind = (spec) => {
@@ -73,7 +72,7 @@ const getStyledColumnIconMappingsViewValues = (data) => {
73
72
  const effectiveMappings = (0, IconRenderer_1.resolveEffectiveIconStyleMappings)(ic);
74
73
  const items = [`Mappings: ${effectiveMappings.length}`];
75
74
  if (ic.Preset) {
76
- items.push(`Preset: ${IconStylePresets_1.ICON_STYLE_PRESET_LABELS[ic.Preset]}`);
75
+ items.push(`Preset: ${IconStyleHelper_1.ICON_STYLE_PRESET_LABELS[ic.Preset]}`);
77
76
  }
78
77
  const customCount = ic.Mappings?.length ?? 0;
79
78
  if (customCount > 0) {
@@ -308,9 +307,9 @@ const StyledColumnWizardIconSection = (props) => {
308
307
  // -----------------------------------------------------------------------
309
308
  if (props.variant === 'mappings') {
310
309
  const presetMappingsPreview = iconStyle.Preset
311
- ? (0, IconStylePresets_1.getIconStylePresetMappings)(iconStyle.Preset)
310
+ ? (0, IconStyleHelper_1.getIconStylePresetMappings)(iconStyle.Preset)
312
311
  : [];
313
- return ((0, jsx_runtime_1.jsxs)(Flex_1.Box, { children: [(0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Presets" }), (0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: ["Contains most commonly used values; add anything missing in", ' ', (0, jsx_runtime_1.jsx)("strong", { children: "Custom mappings" }), " below"] })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsxs)(FormLayout_1.default, { children: [(0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Select Preset:", children: (0, jsx_runtime_1.jsxs)(Flex_1.Flex, { alignItems: "center", className: "twa:gap-2 twa:flex-wrap", children: [['Flags', 'Currencies', 'Trend', 'Status'].map((p) => ((0, jsx_runtime_1.jsx)(SimpleButton_1.default, { ...(0, wizardSelection_1.wizardSelectionSimpleButtonProps)(iconStyle.Preset === p), onClick: () => applyPreset(p), children: IconStylePresets_1.ICON_STYLE_PRESET_LABELS[p] }, p))), iconStyle.Preset && ((0, jsx_runtime_1.jsx)(SimpleButton_1.default, { variant: "text", icon: "undo", tooltip: "Stop using this preset (custom mappings are kept)", onClick: clearPreset, children: "Clear preset" }))] }) }), iconStyle.Preset && ((0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Active:", children: (0, jsx_runtime_1.jsxs)(Flex_1.Flex, { flexDirection: "column", className: "twa:gap-1 twa:max-w-[640px]", children: [(0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70", children: [IconStylePresets_1.ICON_STYLE_PRESET_DESCRIPTIONS[iconStyle.Preset], " \u2014", ' ', presetMappingsPreview.length, " mappings shipped with the preset."] }), renderMappingsPreview(presetMappingsPreview)] }) }))] }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Custom Mappings" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: iconStyle.Preset
312
+ return ((0, jsx_runtime_1.jsxs)(Flex_1.Box, { children: [(0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Presets" }), (0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: ["Contains most commonly used values; add anything missing in", ' ', (0, jsx_runtime_1.jsx)("strong", { children: "Custom mappings" }), " below"] })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsxs)(FormLayout_1.default, { children: [(0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Select Preset:", children: (0, jsx_runtime_1.jsxs)(Flex_1.Flex, { alignItems: "center", className: "twa:gap-2 twa:flex-wrap", children: [['Flags', 'Currencies', 'Trend', 'Status'].map((p) => ((0, jsx_runtime_1.jsx)(SimpleButton_1.default, { ...(0, wizardSelection_1.wizardSelectionSimpleButtonProps)(iconStyle.Preset === p), onClick: () => applyPreset(p), children: IconStyleHelper_1.ICON_STYLE_PRESET_LABELS[p] }, p))), iconStyle.Preset && ((0, jsx_runtime_1.jsx)(SimpleButton_1.default, { variant: "text", icon: "undo", tooltip: "Stop using this preset (custom mappings are kept)", onClick: clearPreset, children: "Clear preset" }))] }) }), iconStyle.Preset && ((0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Active:", children: (0, jsx_runtime_1.jsxs)(Flex_1.Flex, { flexDirection: "column", className: "twa:gap-1 twa:max-w-[640px]", children: [(0, jsx_runtime_1.jsxs)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70", children: [IconStyleHelper_1.ICON_STYLE_PRESET_DESCRIPTIONS[iconStyle.Preset], " \u2014", ' ', presetMappingsPreview.length, " mappings shipped with the preset."] }), renderMappingsPreview(presetMappingsPreview)] }) }))] }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Custom Mappings" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: iconStyle.Preset
314
313
  ? 'Add any mappings that are not present in the selected preset'
315
314
  : 'Add custom mappings entries (icon, key and description)' })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card.Body, { children: [mappings.length === 0 ? ((0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-60 twa:max-w-[520px] twa:mb-2", children: iconStyle.Preset
316
315
  ? 'No custom mappings — the preset above is being used as-is'
@@ -350,7 +349,7 @@ const StyledColumnWizardIconSection = (props) => {
350
349
  { value: 'After', label: 'After' },
351
350
  { value: 'Above', label: 'Above' },
352
351
  { value: 'Below', label: 'Below' },
353
- ] }) }) })] }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: `twa:mt-3 twa:pt-3 twa:border-t twa:border-foreground/15 ${cellTextDisabled ? 'twa:opacity-50' : ''}`, children: (0, jsx_runtime_1.jsx)(StyledColumnSliceStyleEditors_1.StyledColumnFontStyleEditor, { api: api, disabled: disabled || cellTextDisabled, value: iconStyle.Font, onChange: onFontChange }) })] })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Tooltip" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether and how to display a tooltip" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsxs)(FormLayout_1.FormRow, { label: "Tooltip Display:", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { checked: toolTipText.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', (0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { className: "twa:ml-3", checked: toolTipText.includes('IconDescription'), onChange: (checked) => toggleToolTipText('IconDescription', checked), children: "Description" })] }) }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Cell" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Optional cell box styling (overrides Format Column properties)" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(StyledColumnSliceStyleEditors_1.StyledColumnCellStyleEditor, { api: api, disabled: disabled, value: iconStyle.Cell, onChange: onCellChange }) })] }), (0, jsx_runtime_1.jsx)(StyledColumnIconPreview_1.StyledColumnIconPreviewCard, { data: data })] }));
352
+ ] }) }) })] }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: `twa:mt-3 twa:pt-3 twa:border-t twa:border-foreground/15 ${cellTextDisabled ? 'twa:opacity-50' : ''}`, children: (0, jsx_runtime_1.jsx)(StyledColumnSliceStyleEditors_1.StyledColumnFontStyleEditor, { api: api, disabled: disabled || cellTextDisabled, value: iconStyle.Font, onChange: onFontChange }) })] })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, className: "twa:mb-3", children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Tooltip" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether and how to display a tooltip" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(FormLayout_1.default, { sizes: [...STYLE_FORM_SIZES], children: (0, jsx_runtime_1.jsxs)(FormLayout_1.FormRow, { label: "Tooltip Display:", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { checked: toolTipText.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', (0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { className: "twa:ml-3", checked: toolTipText.includes('IconDescription'), onChange: (checked) => toggleToolTipText('IconDescription', checked), children: "Description" })] }) }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Cell" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Optional cell box styling (overrides Format Column properties)" })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsx)(StyledColumnSliceStyleEditors_1.StyledColumnCellStyleEditor, { api: api, disabled: disabled, value: iconStyle.Cell, onChange: onCellChange }) })] })] }));
354
353
  };
355
354
  exports.StyledColumnWizardIconSection = StyledColumnWizardIconSection;
356
355
  // ---------------------------------------------------------------------------
@@ -18,11 +18,10 @@ const AdaptableInput_1 = tslib_1.__importDefault(require("../../Components/Adapt
18
18
  const Flex_1 = require("../../../components/Flex");
19
19
  const NewSelect_1 = require("../../../components/NewSelect");
20
20
  const RangeBarRangesSummaryPreview_1 = require("./StyledColumnWizardStyleSection/Components/RangeBarRangesSummaryPreview");
21
- const StyledColumnRangeBarPreview_1 = require("./StyledColumnWizardStyleSection/Components/StyledColumnRangeBarPreview");
22
21
  const Card_1 = require("../../../components/Card");
23
22
  const SummaryColorTag_1 = require("../../Wizard/SummaryColorTag");
24
- const barChartCellText_1 = require("../../../Utilities/Helpers/barChartCellText");
25
- const BarChartCellTextLayoutEditor_1 = require("./StyledColumnWizardStyleSection/Components/BarChartCellTextLayoutEditor");
23
+ const BarStylesHelper_1 = require("../../../Utilities/Helpers/StyledColumns/BarStylesHelper");
24
+ const BarStyleCellTextLayoutEditor_1 = require("./StyledColumnWizardStyleSection/Components/BarStyleCellTextLayoutEditor");
26
25
  const RANGE_STYLE_FORM_SIZES = ['200px', '1fr'];
27
26
  const BOUND_MODE_LABELS = {
28
27
  Number: 'Fixed Number',
@@ -110,14 +109,10 @@ const RangeBarBoundInput = ({ api, value, optional, fallbackNumber, excludeColum
110
109
  'twa:[&_.ab-Input]:w-full twa:[&_.ab-Input]:rounded-l-none!',
111
110
  'twa:[&_[data-slot=input-group]]:w-full! twa:[&_[data-slot=input-group]]:rounded-l-none!',
112
111
  ].join(' ');
113
- return ((0, jsx_runtime_1.jsxs)(InputGroup_1.InputGroup, { Component: Flex_1.Flex, className: "twa:items-stretch twa:max-w-[22rem]", children: [(0, jsx_runtime_1.jsx)(NewSelect_1.SingleSelect, { className: `twa:w-[150px] twa:max-w-none twa:shrink-0 twa:box-border${hasEditor ? ' twa:rounded-r-none!' : ''}`, disabled: disabled, value: mode, items: items, onValueChange: (v) => handleModeChange(v) }), hasEditor && (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: editorWrapperClassName, children: editor })] }));
112
+ return ((0, jsx_runtime_1.jsxs)(InputGroup_1.InputGroup, { Component: Flex_1.Flex, className: "twa:items-stretch twa:max-w-[22rem]", children: [(0, jsx_runtime_1.jsx)(NewSelect_1.SingleSelect, { className: `twa:w-[150px] twa:max-w-none twa:shrink-0 twa:box-border${hasEditor ? 'twa:rounded-r-none!' : ''}`, disabled: disabled, value: mode, items: items, onValueChange: (v) => handleModeChange(v) }), hasEditor && (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: editorWrapperClassName, children: editor })] }));
114
113
  };
115
- const formatRangeBarCellTextSummary = (cellText) => cellText
116
- ?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value'))
117
- .join(' + ') ?? '';
118
- const formatRangeBarToolTipSummary = (toolTipText) => toolTipText
119
- ?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value'))
120
- .join(' + ') ?? '';
114
+ const formatRangeBarCellTextSummary = (cellText) => cellText?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value')).join(' + ') ?? '';
115
+ const formatRangeBarToolTipSummary = (toolTipText) => toolTipText?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value')).join(' + ') ?? '';
121
116
  const getStyledColumnRangeBarRangeViewValues = (data) => {
122
117
  const range = data.RangeBarStyle;
123
118
  if (!range) {
@@ -182,10 +177,10 @@ const buildStyledColumnRangeBarDisplaySummaryStrings = (range, options) => {
182
177
  if (range.BackColor) {
183
178
  items.push(`Back Colour: ${range.BackColor}`);
184
179
  }
185
- if ((0, barChartCellText_1.hasBarChartCellTextConfigured)(range.CellTextProperties)) {
186
- const tokens = (0, barChartCellText_1.getActiveBarChartCellTextTokens)(range.CellTextProperties);
180
+ if ((0, BarStylesHelper_1.hasBarStyleCellTextConfigured)(range.CellTextProperties)) {
181
+ const tokens = (0, BarStylesHelper_1.getActiveBarStyleCellTextTokens)(range.CellTextProperties);
187
182
  items.push(`Cell Text: ${formatRangeBarCellTextSummary(tokens)}`);
188
- const layoutSummary = (0, barChartCellText_1.formatBarChartCellTextLayoutSummary)((0, barChartCellText_1.resolveBarChartCellTextLayout)(range.CellTextProperties));
183
+ const layoutSummary = (0, BarStylesHelper_1.formatBarStyleCellTextLayoutSummary)((0, BarStylesHelper_1.resolveBarStyleCellTextLayout)(range.CellTextProperties));
189
184
  if (layoutSummary) {
190
185
  items.push(`Placement: ${layoutSummary}`);
191
186
  }
@@ -381,7 +376,9 @@ const StyledColumnWizardRangeBarSection = (props) => {
381
376
  const resolvedBoundValues = {
382
377
  'Col-Min': minMaxRangeValues?.min,
383
378
  'Col-Max': minMaxRangeValues?.max,
384
- 'Col-Avg': column ? api.styledColumnApi.internalApi.getAvgValueForNumericColumn(column) : undefined,
379
+ 'Col-Avg': column
380
+ ? api.styledColumnApi.internalApi.getAvgValueForNumericColumn(column)
381
+ : undefined,
385
382
  'Col-Median': column
386
383
  ? api.styledColumnApi.internalApi.getMedianValueForNumericColumn(column)
387
384
  : undefined,
@@ -448,11 +445,11 @@ const StyledColumnWizardRangeBarSection = (props) => {
448
445
  };
449
446
  // -- Cell text -------------------------------------------------------------
450
447
  const toggleCellText = (token, show) => {
451
- update((0, barChartCellText_1.toggleBarChartCellTextToken)(range.CellTextProperties, token, show));
448
+ update((0, BarStylesHelper_1.toggleBarStyleCellTextToken)(range.CellTextProperties, token, show));
452
449
  };
453
450
  const onCellTextPlacementChange = (token, patch) => {
454
451
  update({
455
- CellTextProperties: (0, barChartCellText_1.patchBarChartCellTextPlacement)(range.CellTextProperties, token, patch),
452
+ CellTextProperties: (0, BarStylesHelper_1.patchBarStyleCellTextPlacement)(range.CellTextProperties, token, patch),
456
453
  });
457
454
  };
458
455
  const toggleToolTipText = (token, checked) => {
@@ -501,6 +498,6 @@ const StyledColumnWizardRangeBarSection = (props) => {
501
498
  { value: 'Clamp', label: 'Clamp to edge' },
502
499
  { value: 'Overflow', label: 'Show outside' },
503
500
  { value: 'Hide', label: 'Hide marker' },
504
- ] }) }) }), outOfRangeMode === 'Clamp' && ((0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: `Out-of-range ${api.internalApi.getCorrectEnglishVariant('Colour')}:`, children: (0, jsx_runtime_1.jsx)(ColorPicker_1.OptionalColorPicker, { disabled: disabled, api: api, value: range.OutOfRange?.Color, defaultColor: "crimson", onChange: (c) => updateOutOfRangeProperties({ Color: c }) }) }))] }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Text & Tooltip" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Optional cell-text overlay and AG Grid tooltip content." })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsxs)(FormLayout_1.default, { sizes: [...RANGE_STYLE_FORM_SIZES], children: [(0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: "Cell Text Layout:", children: (0, jsx_runtime_1.jsx)(BarChartCellTextLayoutEditor_1.BarChartCellTextLayoutEditor, { disabled: disabled, cellTextProperties: range.CellTextProperties, onToggle: toggleCellText, onPlacementChange: onCellTextPlacementChange }) }), (0, jsx_runtime_1.jsxs)(FormLayout_1.FormRow, { label: "Tooltip Display:", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, checked: range.ToolTipText?.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', (0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, className: "twa:ml-3", checked: range.ToolTipText?.includes('PercentageValue'), onChange: (checked) => toggleToolTipText('PercentageValue', checked), children: "Percent Value" })] })] }) })] }), (0, jsx_runtime_1.jsx)(StyledColumnRangeBarPreview_1.StyledColumnRangeBarPreviewCard, { data: data })] }))] }));
501
+ ] }) }) }), outOfRangeMode === 'Clamp' && ((0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: `Out-of-range ${api.internalApi.getCorrectEnglishVariant('Colour')}:`, children: (0, jsx_runtime_1.jsx)(ColorPicker_1.OptionalColorPicker, { disabled: disabled, api: api, value: range.OutOfRange?.Color, defaultColor: "crimson", onChange: (c) => updateOutOfRangeProperties({ Color: c }) }) }))] }) })] }), (0, jsx_runtime_1.jsxs)(Card_1.Card, { shadow: false, children: [(0, jsx_runtime_1.jsxs)(Card_1.Card.Title, { children: [(0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:font-medium", children: "Text & Tooltip" }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Optional cell-text overlay and AG Grid tooltip content." })] }), (0, jsx_runtime_1.jsx)(Card_1.Card.Body, { children: (0, jsx_runtime_1.jsxs)(FormLayout_1.default, { sizes: [...RANGE_STYLE_FORM_SIZES], children: [(0, jsx_runtime_1.jsx)(BarStyleCellTextLayoutEditor_1.BarStyleCellTextLayoutEditor, { disabled: disabled, cellTextProperties: range.CellTextProperties, onToggle: toggleCellText, onPlacementChange: onCellTextPlacementChange }), (0, jsx_runtime_1.jsxs)(FormLayout_1.FormRow, { label: "Tooltip Display:", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, checked: range.ToolTipText?.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', (0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, className: "twa:ml-3", checked: range.ToolTipText?.includes('PercentageValue'), onChange: (checked) => toggleToolTipText('PercentageValue', checked), children: "Percent Value" })] })] }) })] })] }))] }));
505
502
  };
506
503
  exports.StyledColumnWizardRangeBarSection = StyledColumnWizardRangeBarSection;
@@ -195,6 +195,6 @@ const StyledColumnWizardRatingSection = (props) => {
195
195
  delete cleaned.Cell;
196
196
  props.onChange({ ...data, RatingStyle: cleaned });
197
197
  }
198
- } }) })] }), (0, jsx_runtime_1.jsx)(StyledColumnRatingPreview_1.StyledColumnRatingPreviewCard, { data: data })] }));
198
+ } }) })] })] }));
199
199
  };
200
200
  exports.StyledColumnWizardRatingSection = StyledColumnWizardRatingSection;
@@ -10,8 +10,8 @@ const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
10
10
  const Flex_1 = require("../../../components/Flex");
11
11
  const CheckBox_1 = require("../../../components/CheckBox");
12
12
  const utils_1 = require("../../../lib/utils");
13
- const styledColumnRowKindSupport_1 = require("../../../Utilities/Helpers/styledColumnRowKindSupport");
14
- const iconStyledColumnColumnSupport_1 = require("../../../Utilities/Helpers/iconStyledColumnColumnSupport");
13
+ const StyledColumnHelper_1 = require("../../../Utilities/Helpers/StyledColumns/StyledColumnHelper");
14
+ const IconStyleHelper_1 = require("../../../Utilities/Helpers/StyledColumns/IconStyleHelper");
15
15
  const CollapsibleWizardCard_1 = require("../../Wizard/CollapsibleWizardCard");
16
16
  // ---------------------------------------------------------------------------
17
17
  // Row-kind helpers
@@ -37,23 +37,23 @@ const defaultRowKindIncluded = (styledColumn, kind) => {
37
37
  if (styledColumn.BadgeStyle) {
38
38
  return true;
39
39
  }
40
- if (!(0, styledColumnRowKindSupport_1.isStyledColumnRowKindSupported)(styledColumn, kind)) {
40
+ if (!(0, StyledColumnHelper_1.isStyledColumnRowKindSupported)(styledColumn, kind)) {
41
41
  return false;
42
42
  }
43
43
  return kind !== 'Group';
44
44
  };
45
45
  const isRowKindIncluded = (styledColumn, kind) => {
46
- if (!(0, styledColumnRowKindSupport_1.isStyledColumnRowKindSupported)(styledColumn, kind)) {
46
+ if (!(0, StyledColumnHelper_1.isStyledColumnRowKindSupported)(styledColumn, kind)) {
47
47
  return false;
48
48
  }
49
49
  const scope = styledColumn.RowScope;
50
50
  if (scope) {
51
- return !scope[styledColumnRowKindSupport_1.STYLED_COLUMN_ROW_KIND_EXCLUDE_KEY[kind]];
51
+ return !scope[StyledColumnHelper_1.STYLED_COLUMN_ROW_KIND_EXCLUDE_KEY[kind]];
52
52
  }
53
53
  return defaultRowKindIncluded(styledColumn, kind);
54
54
  };
55
55
  const collectIncludedRowKinds = (styledColumn) => {
56
- return styledColumnRowKindSupport_1.STYLED_COLUMN_ROW_KINDS.filter((k) => isRowKindIncluded(styledColumn, k));
56
+ return StyledColumnHelper_1.STYLED_COLUMN_ROW_KINDS.filter((k) => isRowKindIncluded(styledColumn, k));
57
57
  };
58
58
  // ---------------------------------------------------------------------------
59
59
  // Summary
@@ -86,7 +86,7 @@ const isValidStyledColumnScope = (data, api) => {
86
86
  return 'Please select a column for the Styled Column.';
87
87
  }
88
88
  if (data.IconStyle &&
89
- (0, iconStyledColumnColumnSupport_1.isUnsupportedColumnDataTypeForIconStyle)(api.columnApi.getColumnDataTypeForColumnId(data.ColumnId))) {
89
+ (0, IconStyleHelper_1.isUnsupportedColumnDataTypeForIconStyle)(api.columnApi.getColumnDataTypeForColumnId(data.ColumnId))) {
90
90
  return 'Icon Style applies to scalar cell values only. Choose a numeric or plain text column, or use Badge Style for array columns.';
91
91
  }
92
92
  if (collectIncludedRowKinds(data).length === 0) {
@@ -95,15 +95,15 @@ const isValidStyledColumnScope = (data, api) => {
95
95
  return true;
96
96
  };
97
97
  exports.isValidStyledColumnScope = isValidStyledColumnScope;
98
- const StyledColumnRowScopePanel = ({ data, onRowKindChange, }) => ((0, jsx_runtime_1.jsx)(Flex_1.Flex, { flexDirection: "column", className: "twa:items-start twa:px-1 twa:py-1", style: { rowGap: 'calc(var(--ab-base-space) * 2)' }, children: styledColumnRowKindSupport_1.STYLED_COLUMN_ROW_KINDS.map((kind) => {
99
- const supported = (0, styledColumnRowKindSupport_1.isStyledColumnRowKindSupported)(data, kind);
100
- const disabledReason = (0, styledColumnRowKindSupport_1.getStyledColumnRowKindDisabledReason)(data, kind);
98
+ const StyledColumnRowScopePanel = ({ data, onRowKindChange, }) => ((0, jsx_runtime_1.jsx)(Flex_1.Flex, { flexDirection: "column", className: "twa:items-start twa:px-1 twa:py-1", style: { rowGap: 'calc(var(--ab-base-space) * 2)' }, children: StyledColumnHelper_1.STYLED_COLUMN_ROW_KINDS.map((kind) => {
99
+ const supported = (0, StyledColumnHelper_1.isStyledColumnRowKindSupported)(data, kind);
100
+ const disabledReason = (0, StyledColumnHelper_1.getStyledColumnRowKindDisabledReason)(data, kind);
101
101
  return ((0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { "data-name": `include-${kind.toLowerCase()}-rows-checkbox`, disabled: !supported, title: disabledReason, checked: isRowKindIncluded(data, kind), onChange: (checked) => onRowKindChange(kind, checked), children: ROW_KIND_LABELS[kind] }, kind));
102
102
  }) }));
103
103
  const StyledColumnWizardScopeSection = (props) => {
104
104
  const { data, api } = (0, OnePageAdaptableWizard_1.useOnePageAdaptableWizardContext)();
105
105
  React.useEffect(() => {
106
- const next = (0, styledColumnRowKindSupport_1.sanitizeStyledColumnRowScope)(data);
106
+ const next = (0, StyledColumnHelper_1.sanitizeStyledColumnRowScope)(data);
107
107
  if (!next) {
108
108
  return;
109
109
  }
@@ -131,7 +131,7 @@ const StyledColumnWizardScopeSection = (props) => {
131
131
  return;
132
132
  }
133
133
  const dt = api.columnApi.getColumnDataTypeForColumnId(data.ColumnId);
134
- if ((0, iconStyledColumnColumnSupport_1.isUnsupportedColumnDataTypeForIconStyle)(dt)) {
134
+ if ((0, IconStyleHelper_1.isUnsupportedColumnDataTypeForIconStyle)(dt)) {
135
135
  props.onChange({
136
136
  ...data,
137
137
  ColumnId: undefined,
@@ -201,7 +201,7 @@ const StyledColumnWizardScopeSection = (props) => {
201
201
  props.onChange(newStyledColumn);
202
202
  };
203
203
  const handleRowKindChange = (kind, include) => {
204
- if (!(0, styledColumnRowKindSupport_1.isStyledColumnRowKindSupported)(data, kind)) {
204
+ if (!(0, StyledColumnHelper_1.isStyledColumnRowKindSupported)(data, kind)) {
205
205
  return;
206
206
  }
207
207
  const baseScope = data.RowScope ?? {
@@ -212,7 +212,7 @@ const StyledColumnWizardScopeSection = (props) => {
212
212
  };
213
213
  const nextScope = {
214
214
  ...baseScope,
215
- [styledColumnRowKindSupport_1.STYLED_COLUMN_ROW_KIND_EXCLUDE_KEY[kind]]: !include,
215
+ [StyledColumnHelper_1.STYLED_COLUMN_ROW_KIND_EXCLUDE_KEY[kind]]: !include,
216
216
  };
217
217
  props.onChange({
218
218
  ...data,
@@ -1,9 +1,9 @@
1
1
  import * as React from 'react';
2
- import { BarChartCellTextPlacement, BarChartCellTextProperties } from '../../../../../AdaptableState/StyledColumns/Common/BarChartCellText';
2
+ import { BarStyleCellTextPlacement, BarStyleCellTextProperties } from '../../../../../AdaptableState/StyledColumns/Common/BarStyleProperties';
3
3
  import { CellTextOption } from '../../../../../AdaptableState/StyledColumns/Common/CellTextOptions';
4
- export declare const BarChartCellTextLayoutEditor: React.FunctionComponent<{
4
+ export declare const BarStyleCellTextLayoutEditor: React.FunctionComponent<{
5
5
  disabled?: boolean;
6
- cellTextProperties?: BarChartCellTextProperties;
6
+ cellTextProperties?: BarStyleCellTextProperties;
7
7
  onToggle: (token: CellTextOption, show: boolean) => void;
8
- onPlacementChange: (token: CellTextOption, patch: Partial<BarChartCellTextPlacement>) => void;
8
+ onPlacementChange: (token: CellTextOption, patch: Partial<BarStyleCellTextPlacement>) => void;
9
9
  }>;
@@ -0,0 +1,37 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.BarStyleCellTextLayoutEditor = void 0;
4
+ const jsx_runtime_1 = require("react/jsx-runtime");
5
+ const BarStylesHelper_1 = require("../../../../../Utilities/Helpers/StyledColumns/BarStylesHelper");
6
+ const CheckBox_1 = require("../../../../../components/CheckBox");
7
+ const Flex_1 = require("../../../../../components/Flex");
8
+ const FormLayout_1 = require("../../../../../components/FormLayout");
9
+ const NewSelect_1 = require("../../../../../components/NewSelect");
10
+ const HORIZONTAL_CHOICES = [
11
+ { value: 'Left', label: 'Left' },
12
+ { value: 'Center', label: 'Center' },
13
+ { value: 'Right', label: 'Right' },
14
+ ];
15
+ const VERTICAL_CHOICES = [
16
+ { value: 'Above', label: 'Above Bar' },
17
+ { value: 'Below', label: 'Below Bar' },
18
+ { value: 'Merged', label: 'Merged' },
19
+ ];
20
+ const ROWS = [
21
+ { token: 'CellValue', label: 'Cell Value:', key: 'CellValue' },
22
+ { token: 'PercentageValue', label: 'Percent Value:', key: 'PercentValue' },
23
+ ];
24
+ const BarStyleCellTextLayoutEditor = ({ disabled, cellTextProperties, onToggle, onPlacementChange }) => {
25
+ const layout = (0, BarStylesHelper_1.resolveBarStyleCellTextLayout)(cellTextProperties);
26
+ return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: ROWS.map(({ token, label, key }) => {
27
+ const placement = layout[key];
28
+ const isShown = Boolean(placement);
29
+ const rowDisabled = disabled || !isShown;
30
+ return ((0, jsx_runtime_1.jsx)(FormLayout_1.FormRow, { label: label, children: (0, jsx_runtime_1.jsxs)(Flex_1.Flex, { alignItems: "center", className: "twa:gap-3", children: [(0, jsx_runtime_1.jsx)(CheckBox_1.CheckBox, { disabled: disabled, checked: isShown, onChange: (checked) => onToggle(token, checked) }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:w-[140px]", children: (0, jsx_runtime_1.jsx)(NewSelect_1.SingleSelect, { className: "twa:w-full", disabled: rowDisabled, value: placement?.Horizontal ?? 'Left', onValueChange: (v) => onPlacementChange(token, {
31
+ Horizontal: v,
32
+ }), items: HORIZONTAL_CHOICES }) }), (0, jsx_runtime_1.jsx)(Flex_1.Box, { className: "twa:w-[140px]", children: (0, jsx_runtime_1.jsx)(NewSelect_1.SingleSelect, { className: "twa:w-full", disabled: rowDisabled, value: placement?.Vertical ?? 'Below', onValueChange: (v) => onPlacementChange(token, {
33
+ Vertical: v,
34
+ }), items: VERTICAL_CHOICES }) })] }) }, token));
35
+ }) }));
36
+ };
37
+ exports.BarStyleCellTextLayoutEditor = BarStyleCellTextLayoutEditor;
@@ -1,6 +1,6 @@
1
1
  import * as React from 'react';
2
- import { BarChartCellTextProperties } from '../../../../../AdaptableState/StyledColumns/Common/BarChartCellText';
3
- import { BarChartCellTextLabels } from '../../../../../Utilities/Helpers/barChartCellText';
2
+ import { BarStyleCellTextProperties } from '../../../../../AdaptableState/StyledColumns/Common/BarStyleProperties';
3
+ import { BarStyleCellTextLabels } from '../../../../../Utilities/Helpers/StyledColumns/BarStylesHelper';
4
4
  /**
5
5
  * Preview of the per-value cell-text layout. Renders three potential bands:
6
6
  * - `Above` slots (above the bar)
@@ -11,13 +11,13 @@ import { BarChartCellTextLabels } from '../../../../../Utilities/Helpers/barChar
11
11
  * stable. When `vertical` is provided, only the band matching that value is
12
12
  * rendered (used by the preview cards to position bands around the bar).
13
13
  */
14
- export declare const BarChartCellTextPreview: React.FunctionComponent<{
14
+ export declare const BarStyleCellTextPreview: React.FunctionComponent<{
15
15
  className?: string;
16
16
  style?: React.CSSProperties;
17
- cellTextProperties?: BarChartCellTextProperties;
18
- labels: BarChartCellTextLabels;
17
+ cellTextProperties?: BarStyleCellTextProperties;
18
+ labels: BarStyleCellTextLabels;
19
19
  mergedOverlayClassName?: string;
20
20
  /** Render only the band matching this vertical position. */
21
21
  vertical?: 'Above' | 'Below' | 'Merged';
22
22
  }>;
23
- export declare const shouldShowBarChartCellTextOutsideBar: (cellTextProperties: BarChartCellTextProperties | undefined, hasCellText: boolean) => boolean;
23
+ export declare const shouldShowBarStyleCellTextOutsideBar: (cellTextProperties: BarStyleCellTextProperties | undefined, hasCellText: boolean) => boolean;
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.shouldShowBarChartCellTextOutsideBar = exports.BarChartCellTextPreview = void 0;
3
+ exports.shouldShowBarStyleCellTextOutsideBar = exports.BarStyleCellTextPreview = void 0;
4
4
  const jsx_runtime_1 = require("react/jsx-runtime");
5
- const barChartCellText_1 = require("../../../../../Utilities/Helpers/barChartCellText");
5
+ const BarStylesHelper_1 = require("../../../../../Utilities/Helpers/StyledColumns/BarStylesHelper");
6
6
  const Flex_1 = require("../../../../../components/Flex");
7
7
  const HORIZONTAL_ORDER = ['Left', 'Center', 'Right'];
8
8
  const HORIZONTAL_JUSTIFY = {
@@ -36,11 +36,11 @@ const CellTextRow = ({ className, style, slots }) => ((0, jsx_runtime_1.jsx)(Fle
36
36
  * stable. When `vertical` is provided, only the band matching that value is
37
37
  * rendered (used by the preview cards to position bands around the bar).
38
38
  */
39
- const BarChartCellTextPreview = ({ className, style, cellTextProperties, labels, mergedOverlayClassName, vertical }) => {
39
+ const BarStyleCellTextPreview = ({ className, style, cellTextProperties, labels, mergedOverlayClassName, vertical }) => {
40
40
  if (!labels.cellValue && !labels.percentage) {
41
41
  return null;
42
42
  }
43
- const slots = (0, barChartCellText_1.resolveBarChartCellTextSlots)(cellTextProperties, labels);
43
+ const slots = (0, BarStylesHelper_1.resolveBarStyleCellTextSlots)(cellTextProperties, labels);
44
44
  if (!slots.length) {
45
45
  return null;
46
46
  }
@@ -51,12 +51,12 @@ const BarChartCellTextPreview = ({ className, style, cellTextProperties, labels,
51
51
  const usedClassName = vertical === 'Merged' ? mergedOverlayClassName ?? className : className;
52
52
  return ((0, jsx_runtime_1.jsx)(CellTextRow, { className: usedClassName, style: style, slots: bandSlots.map((s) => ({ horizontal: s.horizontal, text: s.text })) }));
53
53
  };
54
- exports.BarChartCellTextPreview = BarChartCellTextPreview;
55
- const shouldShowBarChartCellTextOutsideBar = (cellTextProperties, hasCellText) => {
56
- if (!hasCellText || !(0, barChartCellText_1.hasBarChartCellTextConfigured)(cellTextProperties)) {
54
+ exports.BarStyleCellTextPreview = BarStyleCellTextPreview;
55
+ const shouldShowBarStyleCellTextOutsideBar = (cellTextProperties, hasCellText) => {
56
+ if (!hasCellText || !(0, BarStylesHelper_1.hasBarStyleCellTextConfigured)(cellTextProperties)) {
57
57
  return false;
58
58
  }
59
- const { hasAbove, hasBelow } = (0, barChartCellText_1.getBarChartCellTextSlotPresence)(cellTextProperties);
59
+ const { hasAbove, hasBelow } = (0, BarStylesHelper_1.getBarStyleCellTextSlotPresence)(cellTextProperties);
60
60
  return hasAbove || hasBelow;
61
61
  };
62
- exports.shouldShowBarChartCellTextOutsideBar = shouldShowBarChartCellTextOutsideBar;
62
+ exports.shouldShowBarStyleCellTextOutsideBar = shouldShowBarStyleCellTextOutsideBar;
@@ -1,11 +1,11 @@
1
1
  import * as React from 'react';
2
2
  import { CellColorRange, ColumnComparison, NumericStyledColumn } from '../../../../../AdaptableState/StyledColumns/Common/NumericStyledColumn';
3
- import { GradientStyle, GradientZeroCentredColors } from '../../../../../AdaptableState/StyledColumns/GradientStyle';
3
+ import { GradientStyle, ZeroCentredColors } from '../../../../../AdaptableState/StyledColumns/GradientStyle';
4
4
  import { AdaptableApi } from '../../../../../types';
5
5
  export declare function gradientRangeStripCss(color: string, reverseGradient: boolean, minAlpha: number, maxAlpha: number): string;
6
6
  export interface GradientRangesSummaryPreviewProps {
7
7
  ranges?: CellColorRange[];
8
- zeroCentred?: GradientZeroCentredColors;
8
+ zeroCentred?: ZeroCentredColors;
9
9
  rangeValueType: NumericStyledColumn['RangeValueType'];
10
10
  gradientStyle?: Pick<GradientStyle, 'MinAlpha' | 'MaxAlpha'>;
11
11
  }