@adaptabletools/adaptable 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 (303) hide show
  1. package/index.css +42 -53
  2. package/package.json +1 -1
  3. package/src/{Utilities → AdaptableState/Aggregations}/weightedAverage.js +1 -1
  4. package/src/AdaptableState/Common/Enums.d.ts +0 -12
  5. package/src/AdaptableState/Common/Enums.js +0 -15
  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 +1 -1
  15. package/src/Api/Implementation/ExportApiImpl.js +1 -1
  16. package/src/Api/Implementation/LayoutHelpers.js +1 -1
  17. package/src/Api/Implementation/QuickSearchApiImpl.js +1 -1
  18. package/src/Api/Implementation/ThemeApiImpl.js +1 -1
  19. package/src/Api/Internal/ActionColumnInternalApi.js +1 -1
  20. package/src/Api/Internal/AlertInternalApi.js +1 -1
  21. package/src/Api/Internal/ChartingInternalApi.js +1 -1
  22. package/src/Api/Internal/ColumnInternalApi.js +1 -1
  23. package/src/Api/Internal/EventInternalApi.js +1 -1
  24. package/src/Api/Internal/ExportInternalApi.js +1 -1
  25. package/src/Api/Internal/FormatColumnInternalApi.js +1 -1
  26. package/src/Api/Internal/GridInternalApi.js +1 -1
  27. package/src/Api/Internal/StyledColumnInternalApi.js +1 -1
  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 +1 -1
  31. package/src/Redux/Store/AdaptableReduxMerger.js +2 -4
  32. package/src/Redux/Store/AdaptableStore.js +3 -3
  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 +1 -1
  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 +1 -1
  50. package/src/Strategy/NoteModule.d.ts +1 -1
  51. package/src/Strategy/PlusMinusModule.d.ts +1 -1
  52. package/src/Strategy/PlusMinusModule.js +1 -1
  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 +2 -2
  57. package/src/Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions.js +1 -1
  58. package/src/Utilities/ExpressionFunctions/expressionFunctionUtils.js +1 -1
  59. package/src/Utilities/ExpressionFunctions/observableExpressionFunctions.js +1 -1
  60. package/src/Utilities/Extensions/ArrayExtensions.d.ts +32 -0
  61. package/src/Utilities/Extensions/ArrayExtensions.js +49 -0
  62. package/src/Utilities/Extensions/NumberExtensions.d.ts +21 -0
  63. package/src/Utilities/Extensions/NumberExtensions.js +74 -0
  64. package/src/Utilities/Extensions/ObjectExtensions.d.ts +44 -0
  65. package/src/Utilities/Extensions/ObjectExtensions.js +271 -0
  66. package/src/Utilities/Extensions/StringExtensions.d.ts +26 -0
  67. package/src/Utilities/Extensions/StringExtensions.js +44 -1
  68. package/src/Utilities/Helpers/AdaptableHelper.js +2 -2
  69. package/src/Utilities/Helpers/{alertFormHelper.js → AlertHelper.js} +1 -1
  70. package/src/Utilities/Helpers/DateHelper.js +1 -1
  71. package/src/Utilities/Helpers/{FormatHelper.js → DisplayFormatHelper.js} +1 -1
  72. package/src/Utilities/Helpers/Helper.d.ts +0 -6
  73. package/src/Utilities/Helpers/Helper.js +0 -35
  74. package/src/Utilities/Helpers/{QuickSearchStyleHelper.js → QuickSearchHelper.js} +1 -1
  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} +14 -0
  87. package/src/Utilities/Helpers/StyledColumns/BarStylesHelper.d.ts +63 -0
  88. package/src/Utilities/Helpers/{barChartCellText.js → StyledColumns/BarStylesHelper.js} +33 -32
  89. package/src/Utilities/Helpers/{StyledColumnGradientHelper.d.ts → StyledColumns/GradientStyleHelper.d.ts} +4 -4
  90. package/src/Utilities/Helpers/{StyledColumnGradientHelper.js → StyledColumns/GradientStyleHelper.js} +3 -3
  91. package/src/Utilities/Helpers/{IconStylePresets.d.ts → StyledColumns/IconStyleHelper.d.ts} +6 -1
  92. package/src/Utilities/Helpers/{IconStylePresets.js → StyledColumns/IconStyleHelper.js} +15 -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} +7 -7
  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/{agGrid/cellRenderers/shouldRenderStyledColumnOnRow.js → Utilities/Helpers/StyledColumns/StyledColumnHelper.js} +64 -2
  98. package/src/Utilities/Helpers/TimingHelper.d.ts +34 -0
  99. package/src/Utilities/{utils/debounce.js → Helpers/TimingHelper.js} +23 -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 +114 -1
  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 +4 -4
  106. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ColumnsList.js +1 -1
  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 +1 -1
  112. package/src/View/Alert/Wizard/AlertNotificationWizardSection.js +2 -2
  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 +1 -1
  119. package/src/View/Charting/ChartingWizard/AgChargingWizard/SettingsSection.js +1 -1
  120. package/src/View/Charting/ChartingWizard/ExternalChartingWizard/SettingsSection.js +1 -1
  121. package/src/View/Comments/CommentsEditor.js +1 -1
  122. package/src/View/Comments/CommentsPopup.js +1 -1
  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 +1 -1
  128. package/src/View/Components/ColumnFilter/components/ColumnFilterInputList.js +1 -1
  129. package/src/View/Components/ColumnFilter/components/FloatingFilterInputList.js +1 -1
  130. package/src/View/Components/Forms/AdaptableFormControlTextClear.js +2 -1
  131. package/src/View/Components/Popups/AdaptablePopup/useMenuItems.js +1 -1
  132. package/src/View/Components/Popups/AdaptablePopupAlert.js +1 -1
  133. package/src/View/Components/Popups/Utilities.js +1 -1
  134. package/src/View/Components/RangesComponent.d.ts +3 -3
  135. package/src/View/Components/RangesComponent.js +3 -7
  136. package/src/View/Components/ToolPanel/AdaptableToolPanel.js +1 -1
  137. package/src/View/Components/ToolPanel/CustomToolPanelContent.js +1 -1
  138. package/src/View/Components/ToolPanel/ToolPanelPopupSections.js +5 -2
  139. package/src/View/Dashboard/CustomDashboardButton.js +1 -1
  140. package/src/View/Dashboard/Dashboard.js +1 -1
  141. package/src/View/DataChangeHistory/DataChangeHistoryPopup.js +1 -1
  142. package/src/View/DataChangeHistory/DataChangeHistoryTable.js +1 -1
  143. package/src/View/DataChangeHistory/DataChangeHistoryViewPanel.js +1 -1
  144. package/src/View/DataImport/DataImportWizard/sections/DataPreview.js +1 -1
  145. package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +3 -3
  146. package/src/View/FormatColumn/Wizard/FormatColumnPreview.js +1 -1
  147. package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.js +1 -1
  148. package/src/View/Layout/LayoutCloneButton.js +2 -1
  149. package/src/View/Layout/LayoutViewPanel.js +1 -1
  150. package/src/View/Layout/Wizard/sections/RowSummarySection.js +5 -5
  151. package/src/View/Note/NoteEditor.js +1 -1
  152. package/src/View/Note/NotePopup.js +1 -1
  153. package/src/View/PlusMinus/Wizard/PlusMinusSettingsWizardSection.js +1 -1
  154. package/src/View/QuickSearch/QuickSearchPopup.js +1 -1
  155. package/src/View/QuickSearch/useQuickSearchDebounced.js +1 -1
  156. package/src/View/Schedule/Wizard/ScheduleScheduleWizard.js +1 -1
  157. package/src/View/SpecialColumnSettingsWizardStep.js +1 -1
  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 +40 -11
  162. package/src/View/StyledColumn/Wizard/StyledColumnWizardBulletSection.js +17 -22
  163. package/src/View/StyledColumn/Wizard/StyledColumnWizardGradientSection.js +2 -3
  164. package/src/View/StyledColumn/Wizard/StyledColumnWizardIconSection.js +2 -3
  165. package/src/View/StyledColumn/Wizard/StyledColumnWizardRangeBarSection.js +14 -17
  166. package/src/View/StyledColumn/Wizard/StyledColumnWizardRatingSection.js +2 -2
  167. package/src/View/StyledColumn/Wizard/StyledColumnWizardScopeSection.js +2 -2
  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 +33 -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} +6 -6
  172. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/GradientSummaryPreview.d.ts +2 -2
  173. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/GradientSummaryPreview.js +2 -4
  174. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview.d.ts +0 -3
  175. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview.js +5 -5
  176. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBulletPreview.d.ts +0 -3
  177. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBulletPreview.js +7 -9
  178. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnGradientPreview.d.ts +0 -3
  179. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnGradientPreview.js +2 -4
  180. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnIconPreview.d.ts +0 -3
  181. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnIconPreview.js +1 -3
  182. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnPercentBarPreview.d.ts +0 -3
  183. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnPercentBarPreview.js +11 -11
  184. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRangeBarPreview.d.ts +0 -3
  185. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRangeBarPreview.js +7 -9
  186. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRatingPreview.d.ts +0 -3
  187. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnRatingPreview.js +3 -3
  188. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnSparklinePreview.d.ts +0 -3
  189. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnSparklinePreview.js +2 -4
  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 +1 -1
  195. package/src/View/Wizard/OnePageWizards.d.ts +8 -0
  196. package/src/View/Wizard/OnePageWizards.js +6 -4
  197. package/src/agGrid/AdaptableAgGrid.js +6 -6
  198. package/src/agGrid/AgGridColumnAdapter.js +16 -15
  199. package/src/agGrid/AgGridExportAdapter.js +1 -1
  200. package/src/agGrid/AgGridMenuAdapter.js +127 -2
  201. package/src/agGrid/cellRenderers/BadgeRenderer.js +1 -1
  202. package/src/agGrid/cellRenderers/BulletChartRenderer.js +6 -6
  203. package/src/agGrid/cellRenderers/IconRenderer.js +2 -3
  204. package/src/agGrid/cellRenderers/PercentBarRenderer.js +6 -6
  205. package/src/agGrid/cellRenderers/RangeBarRenderer.js +7 -8
  206. package/src/agGrid/cellRenderers/RatingRenderer.js +2 -2
  207. package/src/agGrid/editors/AdaptableDateEditor/index.js +1 -1
  208. package/src/components/ColorPicker/ColorPicker.js +1 -1
  209. package/src/components/Datepicker/index.js +1 -1
  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 +1 -1
  213. package/src/components/OverlayTrigger/index.js +1 -1
  214. package/src/env.js +2 -2
  215. package/src/layout-manager/src/isLayoutEqual.js +1 -1
  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.esm.tsbuildinfo +1 -1
  221. package/src/AdaptableState/StyledColumns/Common/BarChartCellText.js +0 -6
  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 -15
  227. package/src/Utilities/Helpers/resolveSettingsPanelNavigation.d.ts +0 -3
  228. package/src/Utilities/Helpers/resolveSettingsPanelNavigation.js +0 -15
  229. package/src/Utilities/Helpers/styledColumnRowKindSupport.d.ts +0 -25
  230. package/src/Utilities/Helpers/styledColumnRowKindSupport.js +0 -63
  231. package/src/Utilities/Services/CalculatedColumnSyntheticChange.d.ts +0 -4
  232. package/src/Utilities/Services/CalculatedColumnSyntheticChange.js +0 -115
  233. package/src/Utilities/utils/chunk.d.ts +0 -6
  234. package/src/Utilities/utils/chunk.js +0 -17
  235. package/src/Utilities/utils/clamp.d.ts +0 -5
  236. package/src/Utilities/utils/clamp.js +0 -7
  237. package/src/Utilities/utils/cloneDeepWith.d.ts +0 -9
  238. package/src/Utilities/utils/cloneDeepWith.js +0 -67
  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 -7
  242. package/src/Utilities/utils/flattenDeep.d.ts +0 -5
  243. package/src/Utilities/utils/flattenDeep.js +0 -7
  244. package/src/Utilities/utils/get.d.ts +0 -6
  245. package/src/Utilities/utils/get.js +0 -35
  246. package/src/Utilities/utils/index.d.ts +0 -22
  247. package/src/Utilities/utils/index.js +0 -22
  248. package/src/Utilities/utils/isArray.d.ts +0 -6
  249. package/src/Utilities/utils/isArray.js +0 -6
  250. package/src/Utilities/utils/isEqual.d.ts +0 -5
  251. package/src/Utilities/utils/isEqual.js +0 -124
  252. package/src/Utilities/utils/isObject.d.ts +0 -6
  253. package/src/Utilities/utils/isObject.js +0 -9
  254. package/src/Utilities/utils/isPlainObject.d.ts +0 -6
  255. package/src/Utilities/utils/isPlainObject.js +0 -17
  256. package/src/Utilities/utils/kebabCase.d.ts +0 -5
  257. package/src/Utilities/utils/kebabCase.js +0 -8
  258. package/src/Utilities/utils/merge.d.ts +0 -11
  259. package/src/Utilities/utils/merge.js +0 -40
  260. package/src/Utilities/utils/mergeWith.d.ts +0 -7
  261. package/src/Utilities/utils/mergeWith.js +0 -46
  262. package/src/Utilities/utils/orderBy.d.ts +0 -8
  263. package/src/Utilities/utils/orderBy.js +0 -30
  264. package/src/Utilities/utils/parseInt.d.ts +0 -6
  265. package/src/Utilities/utils/parseInt.js +0 -9
  266. package/src/Utilities/utils/sentenceCase.d.ts +0 -6
  267. package/src/Utilities/utils/sentenceCase.js +0 -15
  268. package/src/Utilities/utils/startCase.d.ts +0 -5
  269. package/src/Utilities/utils/startCase.js +0 -11
  270. package/src/Utilities/utils/throttle.d.ts +0 -17
  271. package/src/Utilities/utils/throttle.js +0 -19
  272. package/src/Utilities/utils/toNumber.d.ts +0 -5
  273. package/src/Utilities/utils/toNumber.js +0 -39
  274. package/src/Utilities/utils/uniq.d.ts +0 -7
  275. package/src/Utilities/utils/uniq.js +0 -9
  276. package/src/Utilities/utils/uniqBy.d.ts +0 -8
  277. package/src/Utilities/utils/uniqBy.js +0 -22
  278. package/src/Utilities/utils/words.d.ts +0 -7
  279. package/src/Utilities/utils/words.js +0 -10
  280. package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/BarChartCellTextLayoutEditor.js +0 -35
  281. package/src/agGrid/buildValueAggregationMenuItem.d.ts +0 -19
  282. package/src/agGrid/buildValueAggregationMenuItem.js +0 -111
  283. package/src/agGrid/cellRenderers/shouldRenderStyledColumnOnRow.d.ts +0 -30
  284. package/src/agGrid/createAgGridIcon.d.ts +0 -10
  285. package/src/agGrid/createAgGridIcon.js +0 -16
  286. /package/src/{Utilities → AdaptableState/Aggregations}/only.d.ts +0 -0
  287. /package/src/{Utilities → AdaptableState/Aggregations}/only.js +0 -0
  288. /package/src/{Utilities → AdaptableState/Aggregations}/weightedAverage.d.ts +0 -0
  289. /package/src/AdaptableState/StyledColumns/Common/{BarChartMarker.js → BarStyleProperties.js} +0 -0
  290. /package/src/Utilities/Helpers/{ActionColumnWidthHelper.d.ts → ActionColumnHelper.d.ts} +0 -0
  291. /package/src/Utilities/Helpers/{ActionColumnWidthHelper.js → ActionColumnHelper.js} +0 -0
  292. /package/src/Utilities/Helpers/{alertFormHelper.d.ts → AlertHelper.d.ts} +0 -0
  293. /package/src/Utilities/Helpers/{chartingHelper.d.ts → ChartHelper.d.ts} +0 -0
  294. /package/src/Utilities/Helpers/{chartingHelper.js → ChartHelper.js} +0 -0
  295. /package/src/Utilities/Helpers/{FormatHelper.d.ts → DisplayFormatHelper.d.ts} +0 -0
  296. /package/src/Utilities/Helpers/{plusMinusTriggerKeys.d.ts → PlusMinusHelper.d.ts} +0 -0
  297. /package/src/Utilities/Helpers/{plusMinusTriggerKeys.js → PlusMinusHelper.js} +0 -0
  298. /package/src/Utilities/Helpers/{QuickSearchStyleHelper.d.ts → QuickSearchHelper.d.ts} +0 -0
  299. /package/src/Utilities/Helpers/{ScheduleJobManager.js → Scheduling/ScheduleJobManager.js} +0 -0
  300. /package/src/Utilities/Helpers/{ScheduleJobRunner.js → Scheduling/ScheduleJobRunner.js} +0 -0
  301. /package/src/Utilities/Helpers/{SparklineOptionsHelper.d.ts → StyledColumns/SparklineStyleHelper.d.ts} +0 -0
  302. /package/src/Utilities/Helpers/{ThemeHelpers.d.ts → ThemeHelper.d.ts} +0 -0
  303. /package/src/Utilities/Helpers/{ThemeHelpers.js → ThemeHelper.js} +0 -0
@@ -12,13 +12,12 @@ import { useOnePageAdaptableWizardContext } from '../../Wizard/OnePageAdaptableW
12
12
  import AdaptableInput from '../../Components/AdaptableInput';
13
13
  import { Box, Flex } from '../../../components/Flex';
14
14
  import { BulletRangesSummaryPreview } from './StyledColumnWizardStyleSection/Components/BulletRangesSummaryPreview';
15
- import { StyledColumnBulletPreviewCard } from './StyledColumnWizardStyleSection/Components/StyledColumnBulletPreview';
16
15
  import { SingleSelect } from '../../../components/NewSelect';
17
16
  import { getCellFontStyleSummaryItems, StyledColumnFontStyleEditor, } from './StyledColumnSliceStyleEditors';
18
17
  import { Card } from '../../../components/Card';
19
18
  import { renderSummaryStringTags } from '../../Wizard/SummaryColorTag';
20
- import { formatBarChartCellTextLayoutSummary, getActiveBarChartCellTextTokens, hasBarChartCellTextConfigured, patchBarChartCellTextPlacement, resolveBarChartCellTextLayout, toggleBarChartCellTextToken, } from '../../../Utilities/Helpers/barChartCellText';
21
- import { BarChartCellTextLayoutEditor } from './StyledColumnWizardStyleSection/Components/BarChartCellTextLayoutEditor';
19
+ import { formatBarStyleCellTextLayoutSummary, getActiveBarStyleCellTextTokens, hasBarStyleCellTextConfigured, patchBarStyleCellTextPlacement, resolveBarStyleCellTextLayout, toggleBarStyleCellTextToken, } from '../../../Utilities/Helpers/StyledColumns/BarStylesHelper';
20
+ import { BarStyleCellTextLayoutEditor } from './StyledColumnWizardStyleSection/Components/BarStyleCellTextLayoutEditor';
22
21
  const BULLET_STYLE_FORM_SIZES = ['200px', '1fr'];
23
22
  const getTargetSummary = (target) => {
24
23
  if (target == undefined) {
@@ -51,12 +50,8 @@ const formatBulletOriginLabel = (origin) => {
51
50
  }
52
51
  return origin;
53
52
  };
54
- const formatBulletCellTextSummary = (cellText) => cellText
55
- ?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value'))
56
- .join(' + ') ?? '';
57
- const formatBulletToolTipSummary = (toolTipText) => toolTipText
58
- ?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value'))
59
- .join(' + ') ?? '';
53
+ const formatBulletCellTextSummary = (cellText) => cellText?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value')).join(' + ') ?? '';
54
+ const formatBulletToolTipSummary = (toolTipText) => toolTipText?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value')).join(' + ') ?? '';
60
55
  export const getStyledColumnBulletRangesViewValues = (data) => {
61
56
  const bullet = data.BulletChartStyle;
62
57
  if (!bullet) {
@@ -100,10 +95,10 @@ const buildStyledColumnBulletStyleSummaryStrings = (bullet, options) => {
100
95
  if (bullet.BackColor) {
101
96
  items.push(`Back Colour: ${bullet.BackColor}`);
102
97
  }
103
- if (hasBarChartCellTextConfigured(bullet.CellTextProperties)) {
104
- const tokens = getActiveBarChartCellTextTokens(bullet.CellTextProperties);
98
+ if (hasBarStyleCellTextConfigured(bullet.CellTextProperties)) {
99
+ const tokens = getActiveBarStyleCellTextTokens(bullet.CellTextProperties);
105
100
  items.push(`Cell Text: ${formatBulletCellTextSummary(tokens)}`);
106
- const layoutSummary = formatBarChartCellTextLayoutSummary(resolveBarChartCellTextLayout(bullet.CellTextProperties));
101
+ const layoutSummary = formatBarStyleCellTextLayoutSummary(resolveBarStyleCellTextLayout(bullet.CellTextProperties));
107
102
  if (layoutSummary) {
108
103
  items.push(`Placement: ${layoutSummary}`);
109
104
  }
@@ -290,9 +285,7 @@ export const StyledColumnWizardBulletSection = (props) => {
290
285
  }
291
286
  if (mode === 'Column') {
292
287
  // Use the first available numeric column (excluding the styled column itself)
293
- const candidate = api.columnApi
294
- .getNumericColumns()
295
- .find((c) => c.columnId !== data.ColumnId);
288
+ const candidate = api.columnApi.getNumericColumns().find((c) => c.columnId !== data.ColumnId);
296
289
  setTarget(candidate?.columnId ?? '');
297
290
  return;
298
291
  }
@@ -324,11 +317,11 @@ export const StyledColumnWizardBulletSection = (props) => {
324
317
  };
325
318
  // -- Cell text -------------------------------------------------------------
326
319
  const toggleCellText = (token, show) => {
327
- update(toggleBarChartCellTextToken(bullet.CellTextProperties, token, show));
320
+ update(toggleBarStyleCellTextToken(bullet.CellTextProperties, token, show));
328
321
  };
329
322
  const onCellTextPlacementChange = (token, patch) => {
330
323
  update({
331
- CellTextProperties: patchBarChartCellTextPlacement(bullet.CellTextProperties, token, patch),
324
+ CellTextProperties: patchBarStyleCellTextPlacement(bullet.CellTextProperties, token, patch),
332
325
  });
333
326
  };
334
327
  const toggleToolTipText = (token, checked) => {
@@ -358,7 +351,9 @@ export const StyledColumnWizardBulletSection = (props) => {
358
351
  : typeof primaryTarget?.Value === 'number'
359
352
  ? primaryTarget.Value
360
353
  : undefined;
361
- const columnTargetValue = typeof primaryTarget === 'string' && primaryTarget !== 'Col-Avg' && primaryTarget !== 'Col-Median'
354
+ const columnTargetValue = typeof primaryTarget === 'string' &&
355
+ primaryTarget !== 'Col-Avg' &&
356
+ primaryTarget !== 'Col-Median'
362
357
  ? primaryTarget
363
358
  : typeof primaryTarget?.Value === 'string'
364
359
  ? primaryTarget.Value
@@ -370,7 +365,7 @@ export const StyledColumnWizardBulletSection = (props) => {
370
365
  Size: markerCfg?.Size ?? (markerCfg?.Shape === 'Line' ? 2 : 8),
371
366
  };
372
367
  const cellTextProperties = bullet.CellTextProperties;
373
- const cellTextDisabled = !hasBarChartCellTextConfigured(cellTextProperties) || disabled;
368
+ const cellTextDisabled = !hasBarStyleCellTextConfigured(cellTextProperties) || disabled;
374
369
  return (_jsxs(Box, { children: [_jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Target" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Select a target value for the bullet scale" })] }), _jsx(Card.Body, { children: _jsxs(FormLayout, { sizes: [...BULLET_STYLE_FORM_SIZES], children: [_jsx(FormRow, { label: "Target:", children: _jsx(Box, { className: "twa:max-w-[180px]", children: _jsx(SingleSelect, { className: "twa:w-full", value: currentMode, onValueChange: (v) => handleTargetModeChange(v), items: [
375
370
  { value: 'None', label: 'None' },
376
371
  { value: 'Number', label: 'Fixed Number' },
@@ -382,7 +377,7 @@ export const StyledColumnWizardBulletSection = (props) => {
382
377
  { value: 'Vertical', label: 'Vertical' },
383
378
  ] }) }) }), bullet.Orientation === 'Vertical' && (_jsx(FormRow, { label: "", children: _jsxs(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 ", _jsx("code", { children: "rowHeight" }), " on ", _jsx("code", { children: " gridOptions " }), " or use", ' ', _jsx("code", { children: "getRowHeight" }), "."] }) })), _jsx(FormRow, { label: "Bar Colour:", children: _jsx(ColorPicker, { disabled: disabled, api: api, value: bullet.Bar?.Color, onChange: (c) => updateBar({ Color: c }) }) }), _jsx(FormRow, { label: bullet.Orientation === 'Vertical' ? 'Bar Width (px):' : 'Bar Height (px):', children: _jsx(Box, { className: "twa:max-w-[100px]", children: _jsx(AdaptableInput, { type: "number", min: 1, value: bullet.Bar?.Height ?? '', onChange: (e) => updateBar({
384
379
  Height: e.target.value === '' ? undefined : Number(e.target.value),
385
- }), placeholder: "8" }) }) }), _jsx(FormRow, { label: "Origin:", children: _jsx(Box, { className: "twa:max-w-[160px]", children: _jsx(SingleSelect, { className: "twa:w-full", value: typeof bullet.Origin === 'number' ? 'Number' : (bullet.Origin ?? 'Auto'), onValueChange: (v) => {
380
+ }), placeholder: "8" }) }) }), _jsx(FormRow, { label: "Origin:", children: _jsx(Box, { className: "twa:max-w-[160px]", children: _jsx(SingleSelect, { className: "twa:w-full", value: typeof bullet.Origin === 'number' ? 'Number' : bullet.Origin ?? 'Auto', onValueChange: (v) => {
386
381
  if (v === 'Auto' || v === 'Zero') {
387
382
  update({ Origin: v });
388
383
  }
@@ -392,7 +387,7 @@ export const StyledColumnWizardBulletSection = (props) => {
392
387
  }, items: [
393
388
  { value: 'Auto', label: 'Auto' },
394
389
  { value: 'Zero', label: 'Zero' },
395
- ] }) }) })] }) })] }), _jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Cell Text" }), _jsx(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" })] }), _jsxs(Card.Body, { children: [_jsx(FormLayout, { sizes: [...BULLET_STYLE_FORM_SIZES], children: _jsx(FormRow, { label: "Cell Text Layout:", children: _jsx(BarChartCellTextLayoutEditor, { disabled: disabled, cellTextProperties: cellTextProperties, onToggle: toggleCellText, onPlacementChange: onCellTextPlacementChange }) }) }), _jsx(Box, { className: `twa:mt-3 twa:pt-3 twa:border-t twa:border-foreground/15 ${cellTextDisabled ? 'twa:opacity-50' : ''}`, children: _jsx(StyledColumnFontStyleEditor, { api: api, disabled: cellTextDisabled, value: bullet.Font, onChange: (next) => {
390
+ ] }) }) })] }) })] }), _jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Cell Text" }), _jsx(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" })] }), _jsxs(Card.Body, { children: [_jsx(FormLayout, { sizes: [...BULLET_STYLE_FORM_SIZES], children: _jsx(BarStyleCellTextLayoutEditor, { disabled: disabled, cellTextProperties: cellTextProperties, onToggle: toggleCellText, onPlacementChange: onCellTextPlacementChange }) }), _jsx(Box, { className: `twa:mt-3 twa:pt-3 twa:border-t twa:border-foreground/15 ${cellTextDisabled ? 'twa:opacity-50' : ''}`, children: _jsx(StyledColumnFontStyleEditor, { api: api, disabled: cellTextDisabled, value: bullet.Font, onChange: (next) => {
396
391
  if (next) {
397
392
  update({ Font: next });
398
393
  }
@@ -401,5 +396,5 @@ export const StyledColumnWizardBulletSection = (props) => {
401
396
  delete cleaned.Font;
402
397
  props.onChange({ ...data, BulletChartStyle: cleaned });
403
398
  }
404
- } }) })] })] }), _jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Tooltip" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether to display a tooltip" })] }), _jsx(Card.Body, { children: _jsx(FormLayout, { sizes: [...BULLET_STYLE_FORM_SIZES], children: _jsxs(FormRow, { label: "Tooltip Display:", children: [_jsx(CheckBox, { disabled: disabled, checked: bullet.ToolTipText?.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', _jsx(CheckBox, { disabled: disabled, className: "twa:ml-3", checked: bullet.ToolTipText?.includes('PercentageValue'), onChange: (checked) => toggleToolTipText('PercentageValue', checked), children: "Percent Value" })] }) }) })] }), _jsx(StyledColumnBulletPreviewCard, { data: data })] }));
399
+ } }) })] })] }), _jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Tooltip" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether to display a tooltip" })] }), _jsx(Card.Body, { children: _jsx(FormLayout, { sizes: [...BULLET_STYLE_FORM_SIZES], children: _jsxs(FormRow, { label: "Tooltip Display:", children: [_jsx(CheckBox, { disabled: disabled, checked: bullet.ToolTipText?.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', _jsx(CheckBox, { disabled: disabled, className: "twa:ml-3", checked: bullet.ToolTipText?.includes('PercentageValue'), onChange: (checked) => toggleToolTipText('PercentageValue', checked), children: "Percent Value" })] }) }) })] })] }));
405
400
  };
@@ -7,11 +7,10 @@ import { Tag } from '../../../components/Tag';
7
7
  import { useOnePageAdaptableWizardContext } from '../../Wizard/OnePageAdaptableWizard';
8
8
  import { Box, Flex } from '../../../components/Flex';
9
9
  import { NumberInput } from '../../../components/Input/NumberInput';
10
- import { DEFAULT_GRADIENT_MAX_ALPHA, DEFAULT_GRADIENT_MIN_ALPHA, } from '../../../Utilities/Helpers/StyledColumnGradientHelper';
10
+ import { DEFAULT_GRADIENT_MAX_ALPHA, DEFAULT_GRADIENT_MIN_ALPHA, } from '../../../Utilities/Helpers/StyledColumns/GradientStyleHelper';
11
11
  import { getCellFontStyleSummaryItems, StyledColumnFontStyleEditor, } from './StyledColumnSliceStyleEditors';
12
12
  import { Card } from '../../../components/Card';
13
13
  import { renderSummaryStringTags } from '../../Wizard/SummaryColorTag';
14
- import { StyledColumnGradientPreviewCard } from './StyledColumnWizardStyleSection/Components/StyledColumnGradientPreview';
15
14
  const STYLE_FORM_SIZES = ['200px', '1fr'];
16
15
  function formatGradientToolTipSummary(opts) {
17
16
  return opts
@@ -110,5 +109,5 @@ export const StyledColumnWizardGradientSection = (props) => {
110
109
  else {
111
110
  patchGradient({ AutoContrastText: true });
112
111
  }
113
- }, children: "Make text readable on tinted backgrounds" }) })] }), _jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Tooltip" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[600px]", children: "Set Tooltip properties" })] }), _jsx(Card.Body, { children: _jsx(FormLayout, { sizes: [...STYLE_FORM_SIZES], children: _jsx(FormRow, { label: "Tooltip:", children: _jsxs(Box, { className: "twa:ml-2", children: [_jsx(CheckBox, { disabled: disabled, checked: gs.ToolTipText?.includes('CellValue'), onChange: (checked) => onToolTipTextChanged('CellValue', checked), children: "Cell Value" }), ' ', _jsx(CheckBox, { disabled: disabled, className: "twa:ml-3", checked: gs.ToolTipText?.includes('PercentageValue'), onChange: (checked) => onToolTipTextChanged('PercentageValue', checked), children: "Percent along scale" })] }) }) }) })] }), _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Font" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[480px]", children: "Optional font properties (takes precedence over Format Column)" })] }), _jsx(Card.Body, { children: _jsx(StyledColumnFontStyleEditor, { api: api, disabled: disabled, value: gs.Font, onChange: onFontChange }) })] }), _jsx(StyledColumnGradientPreviewCard, { data: data }), !data.ColumnId && (_jsx(ErrorBox, { className: "twa:mt-2", children: "Select a column before changing Gradient style." }))] }));
112
+ }, children: "Make text readable on tinted backgrounds" }) })] }), _jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Tooltip" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[600px]", children: "Set Tooltip properties" })] }), _jsx(Card.Body, { children: _jsx(FormLayout, { sizes: [...STYLE_FORM_SIZES], children: _jsx(FormRow, { label: "Tooltip:", children: _jsxs(Box, { className: "twa:ml-2", children: [_jsx(CheckBox, { disabled: disabled, checked: gs.ToolTipText?.includes('CellValue'), onChange: (checked) => onToolTipTextChanged('CellValue', checked), children: "Cell Value" }), ' ', _jsx(CheckBox, { disabled: disabled, className: "twa:ml-3", checked: gs.ToolTipText?.includes('PercentageValue'), onChange: (checked) => onToolTipTextChanged('PercentageValue', checked), children: "Percent along scale" })] }) }) }) })] }), _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Font" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[480px]", children: "Optional font properties (takes precedence over Format Column)" })] }), _jsx(Card.Body, { children: _jsx(StyledColumnFontStyleEditor, { api: api, disabled: disabled, value: gs.Font, onChange: onFontChange }) })] }), !data.ColumnId && (_jsx(ErrorBox, { className: "twa:mt-2", children: "Select a column before changing Gradient style." }))] }));
114
113
  };
@@ -14,12 +14,11 @@ import { IconSelectorPanel } from '../../../components/IconSelector';
14
14
  import { useOnePageAdaptableWizardContext } from '../../Wizard/OnePageAdaptableWizard';
15
15
  import { useAdaptable } from '../../AdaptableContext';
16
16
  import { AdaptableIconComponent } from '../../Components/AdaptableIconComponent';
17
- import { ICON_STYLE_PRESET_DESCRIPTIONS, ICON_STYLE_PRESET_LABELS, getIconStylePresetMappings, } from '../../../Utilities/Helpers/IconStylePresets';
17
+ import { ICON_STYLE_PRESET_DESCRIPTIONS, ICON_STYLE_PRESET_LABELS, getIconStylePresetMappings, } from '../../../Utilities/Helpers/StyledColumns/IconStyleHelper';
18
18
  import { resolveEffectiveIconStyleMappings, resolveIconStyleMappingsForSummaryPreview } from '../../../agGrid/cellRenderers/IconRenderer';
19
19
  import { Card } from '../../../components/Card';
20
20
  import { renderSummaryStringTags } from '../../Wizard/SummaryColorTag';
21
21
  import { getCellBoxStyleSummaryItems, getCellFontStyleSummaryItems, StyledColumnCellStyleEditor, StyledColumnFontStyleEditor, } from './StyledColumnSliceStyleEditors';
22
- import { StyledColumnIconPreviewCard } from './StyledColumnWizardStyleSection/Components/StyledColumnIconPreview';
23
22
  import { wizardSelectionSimpleButtonProps } from '../../../Utilities/wizardSelection';
24
23
  const STYLE_FORM_SIZES = ['200px', '1fr'];
25
24
  const detectIconKind = (spec) => {
@@ -339,7 +338,7 @@ export const StyledColumnWizardIconSection = (props) => {
339
338
  { value: 'After', label: 'After' },
340
339
  { value: 'Above', label: 'Above' },
341
340
  { value: 'Below', label: 'Below' },
342
- ] }) }) })] }), _jsx(Box, { className: `twa:mt-3 twa:pt-3 twa:border-t twa:border-foreground/15 ${cellTextDisabled ? 'twa:opacity-50' : ''}`, children: _jsx(StyledColumnFontStyleEditor, { api: api, disabled: disabled || cellTextDisabled, value: iconStyle.Font, onChange: onFontChange }) })] })] }), _jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Tooltip" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether and how to display a tooltip" })] }), _jsx(Card.Body, { children: _jsx(FormLayout, { sizes: [...STYLE_FORM_SIZES], children: _jsxs(FormRow, { label: "Tooltip Display:", children: [_jsx(CheckBox, { checked: toolTipText.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', _jsx(CheckBox, { className: "twa:ml-3", checked: toolTipText.includes('IconDescription'), onChange: (checked) => toggleToolTipText('IconDescription', checked), children: "Description" })] }) }) })] }), _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Cell" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Optional cell box styling (overrides Format Column properties)" })] }), _jsx(Card.Body, { children: _jsx(StyledColumnCellStyleEditor, { api: api, disabled: disabled, value: iconStyle.Cell, onChange: onCellChange }) })] }), _jsx(StyledColumnIconPreviewCard, { data: data })] }));
341
+ ] }) }) })] }), _jsx(Box, { className: `twa:mt-3 twa:pt-3 twa:border-t twa:border-foreground/15 ${cellTextDisabled ? 'twa:opacity-50' : ''}`, children: _jsx(StyledColumnFontStyleEditor, { api: api, disabled: disabled || cellTextDisabled, value: iconStyle.Font, onChange: onFontChange }) })] })] }), _jsxs(Card, { shadow: false, className: "twa:mb-3", children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Tooltip" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Choose whether and how to display a tooltip" })] }), _jsx(Card.Body, { children: _jsx(FormLayout, { sizes: [...STYLE_FORM_SIZES], children: _jsxs(FormRow, { label: "Tooltip Display:", children: [_jsx(CheckBox, { checked: toolTipText.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', _jsx(CheckBox, { className: "twa:ml-3", checked: toolTipText.includes('IconDescription'), onChange: (checked) => toggleToolTipText('IconDescription', checked), children: "Description" })] }) }) })] }), _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Cell" }), _jsx(Box, { className: "twa:text-xs twa:opacity-70 twa:font-normal twa:max-w-[520px]", children: "Optional cell box styling (overrides Format Column properties)" })] }), _jsx(Card.Body, { children: _jsx(StyledColumnCellStyleEditor, { api: api, disabled: disabled, value: iconStyle.Cell, onChange: onCellChange }) })] })] }));
343
342
  };
344
343
  // ---------------------------------------------------------------------------
345
344
  // Icon picker — click-to-open popover (closes on outside click or system pick)
@@ -14,11 +14,10 @@ import AdaptableInput from '../../Components/AdaptableInput';
14
14
  import { Box, Flex } from '../../../components/Flex';
15
15
  import { SingleSelect } from '../../../components/NewSelect';
16
16
  import { RangeBarRangesSummaryPreview } from './StyledColumnWizardStyleSection/Components/RangeBarRangesSummaryPreview';
17
- import { StyledColumnRangeBarPreviewCard } from './StyledColumnWizardStyleSection/Components/StyledColumnRangeBarPreview';
18
17
  import { Card } from '../../../components/Card';
19
18
  import { renderSummaryStringTags } from '../../Wizard/SummaryColorTag';
20
- import { formatBarChartCellTextLayoutSummary, getActiveBarChartCellTextTokens, hasBarChartCellTextConfigured, patchBarChartCellTextPlacement, resolveBarChartCellTextLayout, toggleBarChartCellTextToken, } from '../../../Utilities/Helpers/barChartCellText';
21
- import { BarChartCellTextLayoutEditor } from './StyledColumnWizardStyleSection/Components/BarChartCellTextLayoutEditor';
19
+ import { formatBarStyleCellTextLayoutSummary, getActiveBarStyleCellTextTokens, hasBarStyleCellTextConfigured, patchBarStyleCellTextPlacement, resolveBarStyleCellTextLayout, toggleBarStyleCellTextToken, } from '../../../Utilities/Helpers/StyledColumns/BarStylesHelper';
20
+ import { BarStyleCellTextLayoutEditor } from './StyledColumnWizardStyleSection/Components/BarStyleCellTextLayoutEditor';
22
21
  const RANGE_STYLE_FORM_SIZES = ['200px', '1fr'];
23
22
  const BOUND_MODE_LABELS = {
24
23
  Number: 'Fixed Number',
@@ -106,14 +105,10 @@ const RangeBarBoundInput = ({ api, value, optional, fallbackNumber, excludeColum
106
105
  'twa:[&_.ab-Input]:w-full twa:[&_.ab-Input]:rounded-l-none!',
107
106
  'twa:[&_[data-slot=input-group]]:w-full! twa:[&_[data-slot=input-group]]:rounded-l-none!',
108
107
  ].join(' ');
109
- return (_jsxs(InputGroup, { Component: Flex, className: "twa:items-stretch twa:max-w-[22rem]", children: [_jsx(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 && _jsx(Box, { className: editorWrapperClassName, children: editor })] }));
108
+ return (_jsxs(InputGroup, { Component: Flex, className: "twa:items-stretch twa:max-w-[22rem]", children: [_jsx(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 && _jsx(Box, { className: editorWrapperClassName, children: editor })] }));
110
109
  };
111
- const formatRangeBarCellTextSummary = (cellText) => cellText
112
- ?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value'))
113
- .join(' + ') ?? '';
114
- const formatRangeBarToolTipSummary = (toolTipText) => toolTipText
115
- ?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value'))
116
- .join(' + ') ?? '';
110
+ const formatRangeBarCellTextSummary = (cellText) => cellText?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value')).join(' + ') ?? '';
111
+ const formatRangeBarToolTipSummary = (toolTipText) => toolTipText?.map((t) => (t === 'CellValue' ? 'Cell Value' : 'Percent Value')).join(' + ') ?? '';
117
112
  export const getStyledColumnRangeBarRangeViewValues = (data) => {
118
113
  const range = data.RangeBarStyle;
119
114
  if (!range) {
@@ -177,10 +172,10 @@ const buildStyledColumnRangeBarDisplaySummaryStrings = (range, options) => {
177
172
  if (range.BackColor) {
178
173
  items.push(`Back Colour: ${range.BackColor}`);
179
174
  }
180
- if (hasBarChartCellTextConfigured(range.CellTextProperties)) {
181
- const tokens = getActiveBarChartCellTextTokens(range.CellTextProperties);
175
+ if (hasBarStyleCellTextConfigured(range.CellTextProperties)) {
176
+ const tokens = getActiveBarStyleCellTextTokens(range.CellTextProperties);
182
177
  items.push(`Cell Text: ${formatRangeBarCellTextSummary(tokens)}`);
183
- const layoutSummary = formatBarChartCellTextLayoutSummary(resolveBarChartCellTextLayout(range.CellTextProperties));
178
+ const layoutSummary = formatBarStyleCellTextLayoutSummary(resolveBarStyleCellTextLayout(range.CellTextProperties));
184
179
  if (layoutSummary) {
185
180
  items.push(`Placement: ${layoutSummary}`);
186
181
  }
@@ -370,7 +365,9 @@ export const StyledColumnWizardRangeBarSection = (props) => {
370
365
  const resolvedBoundValues = {
371
366
  'Col-Min': minMaxRangeValues?.min,
372
367
  'Col-Max': minMaxRangeValues?.max,
373
- 'Col-Avg': column ? api.styledColumnApi.internalApi.getAvgValueForNumericColumn(column) : undefined,
368
+ 'Col-Avg': column
369
+ ? api.styledColumnApi.internalApi.getAvgValueForNumericColumn(column)
370
+ : undefined,
374
371
  'Col-Median': column
375
372
  ? api.styledColumnApi.internalApi.getMedianValueForNumericColumn(column)
376
373
  : undefined,
@@ -437,11 +434,11 @@ export const StyledColumnWizardRangeBarSection = (props) => {
437
434
  };
438
435
  // -- Cell text -------------------------------------------------------------
439
436
  const toggleCellText = (token, show) => {
440
- update(toggleBarChartCellTextToken(range.CellTextProperties, token, show));
437
+ update(toggleBarStyleCellTextToken(range.CellTextProperties, token, show));
441
438
  };
442
439
  const onCellTextPlacementChange = (token, patch) => {
443
440
  update({
444
- CellTextProperties: patchBarChartCellTextPlacement(range.CellTextProperties, token, patch),
441
+ CellTextProperties: patchBarStyleCellTextPlacement(range.CellTextProperties, token, patch),
445
442
  });
446
443
  };
447
444
  const toggleToolTipText = (token, checked) => {
@@ -490,5 +487,5 @@ export const StyledColumnWizardRangeBarSection = (props) => {
490
487
  { value: 'Clamp', label: 'Clamp to edge' },
491
488
  { value: 'Overflow', label: 'Show outside' },
492
489
  { value: 'Hide', label: 'Hide marker' },
493
- ] }) }) }), outOfRangeMode === 'Clamp' && (_jsx(FormRow, { label: `Out-of-range ${api.internalApi.getCorrectEnglishVariant('Colour')}:`, children: _jsx(OptionalColorPicker, { disabled: disabled, api: api, value: range.OutOfRange?.Color, defaultColor: "crimson", onChange: (c) => updateOutOfRangeProperties({ Color: c }) }) }))] }) })] }), _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Text & Tooltip" }), _jsx(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." })] }), _jsx(Card.Body, { children: _jsxs(FormLayout, { sizes: [...RANGE_STYLE_FORM_SIZES], children: [_jsx(FormRow, { label: "Cell Text Layout:", children: _jsx(BarChartCellTextLayoutEditor, { disabled: disabled, cellTextProperties: range.CellTextProperties, onToggle: toggleCellText, onPlacementChange: onCellTextPlacementChange }) }), _jsxs(FormRow, { label: "Tooltip Display:", children: [_jsx(CheckBox, { disabled: disabled, checked: range.ToolTipText?.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', _jsx(CheckBox, { disabled: disabled, className: "twa:ml-3", checked: range.ToolTipText?.includes('PercentageValue'), onChange: (checked) => toggleToolTipText('PercentageValue', checked), children: "Percent Value" })] })] }) })] }), _jsx(StyledColumnRangeBarPreviewCard, { data: data })] }))] }));
490
+ ] }) }) }), outOfRangeMode === 'Clamp' && (_jsx(FormRow, { label: `Out-of-range ${api.internalApi.getCorrectEnglishVariant('Colour')}:`, children: _jsx(OptionalColorPicker, { disabled: disabled, api: api, value: range.OutOfRange?.Color, defaultColor: "crimson", onChange: (c) => updateOutOfRangeProperties({ Color: c }) }) }))] }) })] }), _jsxs(Card, { shadow: false, children: [_jsxs(Card.Title, { children: [_jsx(Box, { className: "twa:font-medium", children: "Text & Tooltip" }), _jsx(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." })] }), _jsx(Card.Body, { children: _jsxs(FormLayout, { sizes: [...RANGE_STYLE_FORM_SIZES], children: [_jsx(BarStyleCellTextLayoutEditor, { disabled: disabled, cellTextProperties: range.CellTextProperties, onToggle: toggleCellText, onPlacementChange: onCellTextPlacementChange }), _jsxs(FormRow, { label: "Tooltip Display:", children: [_jsx(CheckBox, { disabled: disabled, checked: range.ToolTipText?.includes('CellValue'), onChange: (checked) => toggleToolTipText('CellValue', checked), children: "Cell Value" }), ' ', _jsx(CheckBox, { disabled: disabled, className: "twa:ml-3", checked: range.ToolTipText?.includes('PercentageValue'), onChange: (checked) => toggleToolTipText('PercentageValue', checked), children: "Percent Value" })] })] }) })] })] }))] }));
494
491
  };
@@ -11,7 +11,7 @@ import Input from '../../../components/Input';
11
11
  import { getCellBoxStyleSummaryItems, StyledColumnCellStyleEditor, } from './StyledColumnSliceStyleEditors';
12
12
  import { Card } from '../../../components/Card';
13
13
  import { renderSummaryStringTags } from '../../Wizard/SummaryColorTag';
14
- import { DEFAULT_RATING_GAP, DEFAULT_RATING_ICON, DEFAULT_RATING_MAX, DEFAULT_RATING_SIZE, StyledColumnRatingPreviewCard, } from './StyledColumnWizardStyleSection/Components/StyledColumnRatingPreview';
14
+ import { DEFAULT_RATING_GAP, DEFAULT_RATING_ICON, DEFAULT_RATING_MAX, DEFAULT_RATING_SIZE, } from './StyledColumnWizardStyleSection/Components/StyledColumnRatingPreview';
15
15
  const STYLE_FORM_SIZES = ['200px', '1fr'];
16
16
  const ICON_CHOICES = [
17
17
  { value: 'Star', label: 'Star' },
@@ -188,5 +188,5 @@ export const StyledColumnWizardRatingSection = (props) => {
188
188
  delete cleaned.Cell;
189
189
  props.onChange({ ...data, RatingStyle: cleaned });
190
190
  }
191
- } }) })] }), _jsx(StyledColumnRatingPreviewCard, { data: data })] }));
191
+ } }) })] })] }));
192
192
  };
@@ -6,8 +6,8 @@ import { useOnePageAdaptableWizardContext } from '../../Wizard/OnePageAdaptableW
6
6
  import { Box, Flex } from '../../../components/Flex';
7
7
  import { CheckBox } from '../../../components/CheckBox';
8
8
  import { cn } from '../../../lib/utils';
9
- import { getStyledColumnRowKindDisabledReason, isStyledColumnRowKindSupported, sanitizeStyledColumnRowScope, STYLED_COLUMN_ROW_KIND_EXCLUDE_KEY, STYLED_COLUMN_ROW_KINDS, } from '../../../Utilities/Helpers/styledColumnRowKindSupport';
10
- import { isUnsupportedColumnDataTypeForIconStyle } from '../../../Utilities/Helpers/iconStyledColumnColumnSupport';
9
+ import { getStyledColumnRowKindDisabledReason, isStyledColumnRowKindSupported, sanitizeStyledColumnRowScope, STYLED_COLUMN_ROW_KIND_EXCLUDE_KEY, STYLED_COLUMN_ROW_KINDS, } from '../../../Utilities/Helpers/StyledColumns/StyledColumnHelper';
10
+ import { isUnsupportedColumnDataTypeForIconStyle } from '../../../Utilities/Helpers/StyledColumns/IconStyleHelper';
11
11
  import { CollapsibleWizardCard, CollapsibleWizardValueSummary, getWizardAccordionSectionClassName, renderCompactColumnTags, useWizardCardAccordion, } from '../../Wizard/CollapsibleWizardCard';
12
12
  // ---------------------------------------------------------------------------
13
13
  // Row-kind helpers
@@ -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,33 @@
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
+ import { resolveBarStyleCellTextLayout } from '../../../../../Utilities/Helpers/StyledColumns/BarStylesHelper';
3
+ import { CheckBox } from '../../../../../components/CheckBox';
4
+ import { Box, Flex } from '../../../../../components/Flex';
5
+ import { FormRow } from '../../../../../components/FormLayout';
6
+ import { SingleSelect } from '../../../../../components/NewSelect';
7
+ const HORIZONTAL_CHOICES = [
8
+ { value: 'Left', label: 'Left' },
9
+ { value: 'Center', label: 'Center' },
10
+ { value: 'Right', label: 'Right' },
11
+ ];
12
+ const VERTICAL_CHOICES = [
13
+ { value: 'Above', label: 'Above Bar' },
14
+ { value: 'Below', label: 'Below Bar' },
15
+ { value: 'Merged', label: 'Merged' },
16
+ ];
17
+ const ROWS = [
18
+ { token: 'CellValue', label: 'Cell Value:', key: 'CellValue' },
19
+ { token: 'PercentageValue', label: 'Percent Value:', key: 'PercentValue' },
20
+ ];
21
+ export const BarStyleCellTextLayoutEditor = ({ disabled, cellTextProperties, onToggle, onPlacementChange }) => {
22
+ const layout = resolveBarStyleCellTextLayout(cellTextProperties);
23
+ return (_jsx(_Fragment, { children: ROWS.map(({ token, label, key }) => {
24
+ const placement = layout[key];
25
+ const isShown = Boolean(placement);
26
+ const rowDisabled = disabled || !isShown;
27
+ return (_jsx(FormRow, { label: label, children: _jsxs(Flex, { alignItems: "center", className: "twa:gap-3", children: [_jsx(CheckBox, { disabled: disabled, checked: isShown, onChange: (checked) => onToggle(token, checked) }), _jsx(Box, { className: "twa:w-[140px]", children: _jsx(SingleSelect, { className: "twa:w-full", disabled: rowDisabled, value: placement?.Horizontal ?? 'Left', onValueChange: (v) => onPlacementChange(token, {
28
+ Horizontal: v,
29
+ }), items: HORIZONTAL_CHOICES }) }), _jsx(Box, { className: "twa:w-[140px]", children: _jsx(SingleSelect, { className: "twa:w-full", disabled: rowDisabled, value: placement?.Vertical ?? 'Below', onValueChange: (v) => onPlacementChange(token, {
30
+ Vertical: v,
31
+ }), items: VERTICAL_CHOICES }) })] }) }, token));
32
+ }) }));
33
+ };
@@ -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,5 +1,5 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
- import { getBarChartCellTextSlotPresence, hasBarChartCellTextConfigured, resolveBarChartCellTextSlots, } from '../../../../../Utilities/Helpers/barChartCellText';
2
+ import { getBarStyleCellTextSlotPresence, hasBarStyleCellTextConfigured, resolveBarStyleCellTextSlots, } from '../../../../../Utilities/Helpers/StyledColumns/BarStylesHelper';
3
3
  import { Box, Flex } from '../../../../../components/Flex';
4
4
  const HORIZONTAL_ORDER = ['Left', 'Center', 'Right'];
5
5
  const HORIZONTAL_JUSTIFY = {
@@ -33,11 +33,11 @@ const CellTextRow = ({ className, style, slots }) => (_jsx(Flex, { className: cl
33
33
  * stable. When `vertical` is provided, only the band matching that value is
34
34
  * rendered (used by the preview cards to position bands around the bar).
35
35
  */
36
- export const BarChartCellTextPreview = ({ className, style, cellTextProperties, labels, mergedOverlayClassName, vertical }) => {
36
+ export const BarStyleCellTextPreview = ({ className, style, cellTextProperties, labels, mergedOverlayClassName, vertical }) => {
37
37
  if (!labels.cellValue && !labels.percentage) {
38
38
  return null;
39
39
  }
40
- const slots = resolveBarChartCellTextSlots(cellTextProperties, labels);
40
+ const slots = resolveBarStyleCellTextSlots(cellTextProperties, labels);
41
41
  if (!slots.length) {
42
42
  return null;
43
43
  }
@@ -48,10 +48,10 @@ export const BarChartCellTextPreview = ({ className, style, cellTextProperties,
48
48
  const usedClassName = vertical === 'Merged' ? mergedOverlayClassName ?? className : className;
49
49
  return (_jsx(CellTextRow, { className: usedClassName, style: style, slots: bandSlots.map((s) => ({ horizontal: s.horizontal, text: s.text })) }));
50
50
  };
51
- export const shouldShowBarChartCellTextOutsideBar = (cellTextProperties, hasCellText) => {
52
- if (!hasCellText || !hasBarChartCellTextConfigured(cellTextProperties)) {
51
+ export const shouldShowBarStyleCellTextOutsideBar = (cellTextProperties, hasCellText) => {
52
+ if (!hasCellText || !hasBarStyleCellTextConfigured(cellTextProperties)) {
53
53
  return false;
54
54
  }
55
- const { hasAbove, hasBelow } = getBarChartCellTextSlotPresence(cellTextProperties);
55
+ const { hasAbove, hasBelow } = getBarStyleCellTextSlotPresence(cellTextProperties);
56
56
  return hasAbove || hasBelow;
57
57
  };
@@ -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
  }
@@ -3,7 +3,7 @@ import tinycolor from 'tinycolor2';
3
3
  import { Box, Flex } from '../../../../../components/Flex';
4
4
  import { Tag } from '../../../../../components/Tag';
5
5
  import { getVariableColor } from '../../../../../Utilities/Helpers/StyleHelper';
6
- import { DEFAULT_GRADIENT_MAX_ALPHA, DEFAULT_GRADIENT_MIN_ALPHA, isDivergingZeroCellRanges, } from '../../../../../Utilities/Helpers/StyledColumnGradientHelper';
6
+ import { DEFAULT_GRADIENT_MAX_ALPHA, DEFAULT_GRADIENT_MIN_ALPHA, isDivergingZeroCellRanges, } from '../../../../../Utilities/Helpers/StyledColumns/GradientStyleHelper';
7
7
  function clamp01(n) {
8
8
  if (Number.isNaN(n)) {
9
9
  return 0;
@@ -56,9 +56,7 @@ export const GradientRangesSummaryPreview = (props) => {
56
56
  export const GradientColumnComparisonSummaryPreview = (props) => {
57
57
  const minA = props.gradientStyle?.MinAlpha ?? DEFAULT_GRADIENT_MIN_ALPHA;
58
58
  const maxA = props.gradientStyle?.MaxAlpha ?? DEFAULT_GRADIENT_MAX_ALPHA;
59
- const fmt = (v) => isNaN(Number(v))
60
- ? `[${props.api.columnApi.getFriendlyNameForColumnId(String(v))}]`
61
- : v;
59
+ const fmt = (v) => isNaN(Number(v)) ? `[${props.api.columnApi.getFriendlyNameForColumnId(String(v))}]` : v;
62
60
  return (_jsxs(Flex, { flexDirection: "column", className: "twa:gap-2", children: [_jsxs(Tag, { children: ["Min: ", fmt(props.columnComparison.MinValue), " \u2014 Max: ", fmt(props.columnComparison.MaxValue)] }), _jsx(Box, { className: `${stripClassName} twa:w-[200px]`, style: {
63
61
  background: gradientRangeStripCss(props.columnComparison.Color, false, minA, maxA),
64
62
  } })] }));
@@ -8,6 +8,3 @@ import { StyledColumn } from '../../../../../types';
8
8
  export declare const StyledColumnBadgePreview: React.FunctionComponent<React.PropsWithChildren<{
9
9
  data: StyledColumn;
10
10
  }>>;
11
- export declare const StyledColumnBadgePreviewCard: React.FunctionComponent<React.PropsWithChildren<{
12
- data: StyledColumn;
13
- }>>;
@@ -1,17 +1,16 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { DEFAULT_INTEGER_DISPLAY_VALUE, DEFAULT_STRING_DISPLAY_VALUE, } from '../../../../../Utilities/Constants/GeneralConstants';
3
3
  import { convertAdaptableStyleToCSS } from '../../../../../Utilities/Helpers/StyleHelper';
4
4
  import { useAdaptable } from '../../../../AdaptableContext';
5
5
  import { Badge } from '../../../../Components/Badge';
6
6
  import { Box } from '../../../../../components/Flex';
7
- import { Card } from '../../../../../components/Card';
8
7
  import { Tag } from '../../../../../components/Tag';
9
8
  const OVERFLOW_CLASS = {
10
9
  Truncate: 'ab-Badge__wrapper--truncate',
11
10
  Wrap: 'ab-Badge__wrapper--wrap',
12
11
  Scroll: 'ab-Badge__wrapper--scroll',
13
12
  };
14
- const PREVIEW_CELL_CLASS = 'ab-BadgePreviewCell twa:min-w-[140px] twa:min-h-[32px] twa:px-2 twa:py-1 twa:rounded-standard twa:border twa:border-[color-mix(in_srgb,var(--ab-color-foreground)_15%,transparent)]';
13
+ const PREVIEW_CELL_CLASS = 'ab-BadgePreviewCell twa:bg-background twa:text-foreground twa:min-w-[140px] twa:min-h-[32px] twa:px-2 twa:py-1 twa:rounded-standard twa:border twa:border-[color-mix(in_srgb,var(--ab-color-foreground)_15%,transparent)]';
15
14
  const resolveBadgeRowJustify = (alignment) => {
16
15
  switch (alignment) {
17
16
  case 'Center':
@@ -42,7 +41,9 @@ export const StyledColumnBadgePreview = ({ data }) => {
42
41
  const cellStyle = badgeStyle.Cell ? convertAdaptableStyleToCSS(badgeStyle.Cell) : undefined;
43
42
  const dataType = adaptable.api.columnApi.getColumnDataTypeForColumnId(data.ColumnId);
44
43
  const wrapperStyle = {
45
- ...(spacing != null ? { ['--ab-cmp-badge__spacing']: `${spacing}px` } : {}),
44
+ ...(spacing != null
45
+ ? { ['--ab-cmp-badge__spacing']: `${spacing}px` }
46
+ : {}),
46
47
  ...(rowJustify
47
48
  ? {
48
49
  justifyContent: rowJustify,
@@ -60,4 +61,3 @@ export const StyledColumnBadgePreview = ({ data }) => {
60
61
  return (_jsx(Badge, { icon: iconProps?.Icon, pillStyle: badge.PillStyle, iconPosition: iconProps?.Position, shape: badge.Shape, density: badgeStyle.Density ?? 'Normal', iconGap: iconProps?.Gap, children: badgeValue }, index));
61
62
  }) }) }));
62
63
  };
63
- export const StyledColumnBadgePreviewCard = ({ data }) => (_jsxs(Card, { shadow: false, children: [_jsx(Card.Title, { children: _jsx(Box, { className: "twa:font-medium", children: "Preview" }) }), _jsx(Card.Body, { className: "twa:p-1", children: _jsx(StyledColumnBadgePreview, { data: data }) })] }));
@@ -4,7 +4,4 @@ import { BulletChartStyle } from '../../../../../AdaptableState/StyledColumns/Bu
4
4
  export declare const StyledColumnBulletPreview: React.FunctionComponent<React.PropsWithChildren<{
5
5
  data: StyledColumn;
6
6
  }>>;
7
- export declare const StyledColumnBulletPreviewCard: React.FunctionComponent<React.PropsWithChildren<{
8
- data: StyledColumn;
9
- }>>;
10
7
  export declare const hasBulletChartRangesConfigured: (bullet: BulletChartStyle | undefined) => boolean;
@@ -1,11 +1,10 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { convertAdaptableStyleToCSS } from '../../../../../Utilities/Helpers/StyleHelper';
3
- import { buildBarChartCellTextLabels, getBarChartCellTextSlotPresence, hasBarChartCellTextConfigured, } from '../../../../../Utilities/Helpers/barChartCellText';
3
+ import { buildBarStyleCellTextLabels, getBarStyleCellTextSlotPresence, hasBarStyleCellTextConfigured, } from '../../../../../Utilities/Helpers/StyledColumns/BarStylesHelper';
4
4
  import { Box, Flex } from '../../../../../components/Flex';
5
- import { Card } from '../../../../../components/Card';
6
5
  import { Tag } from '../../../../../components/Tag';
7
6
  import { StyledColumnBulletChartListPreview } from './StyledColumnChartListPreviews';
8
- import { BarChartCellTextPreview } from './BarChartCellTextPreview';
7
+ import { BarStyleCellTextPreview } from './BarStyleCellTextPreview';
9
8
  const PREVIEW_CELL_CLASS = 'ab-BulletPreviewCell twa:inline-flex twa:items-center twa:min-w-[180px] twa:min-h-[36px] twa:px-2 twa:py-1 twa:rounded-standard twa:border twa:border-[color-mix(in_srgb,var(--ab-color-foreground)_15%,transparent)]';
10
9
  const getBulletPreviewSample = (bullet) => {
11
10
  const ranges = bullet.CellRanges ?? [];
@@ -28,10 +27,10 @@ const getBulletPreviewSample = (bullet) => {
28
27
  const BulletChartPreviewContent = ({ bullet, }) => {
29
28
  const { sampleValue, valueFraction } = getBulletPreviewSample(bullet);
30
29
  const cellTextProperties = bullet.CellTextProperties;
31
- const labels = buildBarChartCellTextLabels(cellTextProperties, Number.isInteger(sampleValue) ? String(sampleValue) : sampleValue.toFixed(1), `${(valueFraction * 100).toFixed(0)}%`);
32
- const hasCellText = hasBarChartCellTextConfigured(cellTextProperties) &&
30
+ const labels = buildBarStyleCellTextLabels(cellTextProperties, Number.isInteger(sampleValue) ? String(sampleValue) : sampleValue.toFixed(1), `${(valueFraction * 100).toFixed(0)}%`);
31
+ const hasCellText = hasBarStyleCellTextConfigured(cellTextProperties) &&
33
32
  Boolean(labels.cellValue || labels.percentage);
34
- const presence = getBarChartCellTextSlotPresence(cellTextProperties);
33
+ const presence = getBarStyleCellTextSlotPresence(cellTextProperties);
35
34
  const fontStyle = bullet.Font ? convertAdaptableStyleToCSS(bullet.Font) : undefined;
36
35
  const isVertical = bullet.Orientation === 'Vertical';
37
36
  const cellTextClassName = 'ab-BulletChart__text twa:text-2 twa:leading-tight twa:truncate twa:max-w-full';
@@ -39,9 +38,9 @@ const BulletChartPreviewContent = ({ bullet, }) => {
39
38
  // Merged-only with no outside bands → relative container so the overlay sits
40
39
  // on top of the chart, matching the runtime renderer's behaviour.
41
40
  if (hasCellText && presence.hasMerged && !presence.hasAbove && !presence.hasBelow) {
42
- return (_jsxs(Box, { className: "ab-BulletChart__wrapper twa:relative twa:inline-flex", children: [chartEl, _jsx(BarChartCellTextPreview, { mergedOverlayClassName: "ab-BulletChart__text twa:absolute twa:inset-x-0 twa:top-1/2 twa:-translate-y-1/2 twa:px-1 twa:text-2 twa:truncate twa:pointer-events-none", style: fontStyle, cellTextProperties: cellTextProperties, labels: labels, vertical: "Merged" })] }));
41
+ return (_jsxs(Box, { className: "ab-BulletChart__wrapper twa:relative twa:inline-flex", children: [chartEl, _jsx(BarStyleCellTextPreview, { mergedOverlayClassName: "ab-BulletChart__text twa:absolute twa:inset-x-0 twa:top-1/2 twa:-translate-y-1/2 twa:px-1 twa:text-2 twa:truncate twa:pointer-events-none", style: fontStyle, cellTextProperties: cellTextProperties, labels: labels, vertical: "Merged" })] }));
43
42
  }
44
- return (_jsxs(Flex, { className: "ab-BulletChart__wrapper twa:relative", flexDirection: "column", alignItems: isVertical ? 'center' : 'stretch', style: { justifyContent: 'center', gap: hasCellText ? 2 : 0 }, children: [hasCellText && presence.hasAbove && (_jsx(BarChartCellTextPreview, { className: cellTextClassName, style: fontStyle, cellTextProperties: cellTextProperties, labels: labels, vertical: "Above" })), _jsxs(Box, { className: "twa:relative twa:w-full", style: { display: 'inline-flex' }, children: [chartEl, hasCellText && presence.hasMerged && (_jsx(BarChartCellTextPreview, { mergedOverlayClassName: "ab-BulletChart__text twa:absolute twa:inset-x-0 twa:top-1/2 twa:-translate-y-1/2 twa:px-1 twa:text-2 twa:truncate twa:pointer-events-none", style: fontStyle, cellTextProperties: cellTextProperties, labels: labels, vertical: "Merged" }))] }), hasCellText && presence.hasBelow && (_jsx(BarChartCellTextPreview, { className: cellTextClassName, style: fontStyle, cellTextProperties: cellTextProperties, labels: labels, vertical: "Below" }))] }));
43
+ return (_jsxs(Flex, { className: "ab-BulletChart__wrapper twa:relative", flexDirection: "column", alignItems: isVertical ? 'center' : 'stretch', style: { justifyContent: 'center', gap: hasCellText ? 2 : 0 }, children: [hasCellText && presence.hasAbove && (_jsx(BarStyleCellTextPreview, { className: cellTextClassName, style: fontStyle, cellTextProperties: cellTextProperties, labels: labels, vertical: "Above" })), _jsxs(Box, { className: "twa:relative twa:w-full", style: { display: 'inline-flex' }, children: [chartEl, hasCellText && presence.hasMerged && (_jsx(BarStyleCellTextPreview, { mergedOverlayClassName: "ab-BulletChart__text twa:absolute twa:inset-x-0 twa:top-1/2 twa:-translate-y-1/2 twa:px-1 twa:text-2 twa:truncate twa:pointer-events-none", style: fontStyle, cellTextProperties: cellTextProperties, labels: labels, vertical: "Merged" }))] }), hasCellText && presence.hasBelow && (_jsx(BarStyleCellTextPreview, { className: cellTextClassName, style: fontStyle, cellTextProperties: cellTextProperties, labels: labels, vertical: "Below" }))] }));
45
44
  };
46
45
  export const StyledColumnBulletPreview = ({ data }) => {
47
46
  const bullet = data.BulletChartStyle;
@@ -50,5 +49,4 @@ export const StyledColumnBulletPreview = ({ data }) => {
50
49
  }
51
50
  return (_jsx(Box, { className: PREVIEW_CELL_CLASS, children: _jsx(BulletChartPreviewContent, { bullet: bullet }) }));
52
51
  };
53
- export const StyledColumnBulletPreviewCard = ({ data }) => (_jsxs(Card, { shadow: false, children: [_jsx(Card.Title, { children: _jsx(Box, { className: "twa:font-medium", children: "Preview" }) }), _jsx(Card.Body, { className: "twa:p-1", children: _jsx(StyledColumnBulletPreview, { data: data }) })] }));
54
52
  export const hasBulletChartRangesConfigured = (bullet) => Boolean(bullet?.CellRanges?.length);
@@ -5,6 +5,3 @@ export declare const StyledColumnGradientPreview: React.FunctionComponent<React.
5
5
  data: StyledColumn;
6
6
  api?: AdaptableApi;
7
7
  }>>;
8
- export declare const StyledColumnGradientPreviewCard: React.FunctionComponent<React.PropsWithChildren<{
9
- data: StyledColumn;
10
- }>>;
@@ -1,9 +1,8 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { Box, Flex } from '../../../../../components/Flex';
3
- import { Card } from '../../../../../components/Card';
4
3
  import { Tag } from '../../../../../components/Tag';
5
4
  import { useAdaptable } from '../../../../AdaptableContext';
6
- import { getGradientPreviewCellStyle, getGradientPreviewSampleValues, hasGradientRangesConfigured, } from '../../../../../Utilities/Helpers/StyledColumnGradientHelper';
5
+ import { getGradientPreviewCellStyle, getGradientPreviewSampleValues, hasGradientRangesConfigured, } from '../../../../../Utilities/Helpers/StyledColumns/GradientStyleHelper';
7
6
  const formatPreviewValue = (value) => {
8
7
  if (Number.isInteger(value)) {
9
8
  return value.toLocaleString();
@@ -27,4 +26,3 @@ export const StyledColumnGradientPreview = ({ data, api: apiProp }) => {
27
26
  const rowNode = api.gridApi?.getRowNodeForIndex(0) ?? null;
28
27
  return (_jsx(Flex, { alignItems: "stretch", className: "twa:flex-wrap twa:gap-2", children: sampleValues.map((value) => (_jsx(Box, { className: "ab-GradientPreviewCell twa:px-2 twa:py-1 twa:min-w-[56px] twa:text-2 twa:text-center twa:rounded-standard twa:border twa:border-[color-mix(in_srgb,var(--ab-color-foreground)_15%,transparent)]", style: getGradientPreviewCellStyle(value, data, api, rowNode), children: formatPreviewValue(value) }, value))) }));
29
28
  };
30
- export const StyledColumnGradientPreviewCard = ({ data }) => (_jsxs(Card, { shadow: false, children: [_jsx(Card.Title, { children: _jsx(Box, { className: "twa:font-medium", children: "Preview" }) }), _jsx(Card.Body, { className: "twa:p-1", children: _jsx(StyledColumnGradientPreview, { data: data }) })] }));
@@ -5,6 +5,3 @@ export declare const DEFAULT_ICON_STYLE_GAP = 4;
5
5
  export declare const StyledColumnIconPreview: React.FunctionComponent<React.PropsWithChildren<{
6
6
  data: StyledColumn;
7
7
  }>>;
8
- export declare const StyledColumnIconPreviewCard: React.FunctionComponent<React.PropsWithChildren<{
9
- data: StyledColumn;
10
- }>>;