@adaptabletools/adaptable-cjs 22.0.0-canary.1 → 22.0.0-canary.10
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.
- package/agGrid.d.ts +9 -9
- package/agGrid.js +1 -0
- package/index.css +1280 -1400
- package/index.css.map +1 -1
- package/index.d.ts +66 -0
- package/index.js +85 -0
- package/package.json +3 -3
- package/src/AdaptableInterfaces/IAdaptable.d.ts +6 -6
- package/src/AdaptableOptions/ActionColumnOptions.d.ts +2 -2
- package/src/AdaptableOptions/AdaptablePlugin.js +6 -1
- package/src/AdaptableOptions/ColumnOptions.d.ts +2 -2
- package/src/AdaptableOptions/ContainerOptions.d.ts +55 -15
- package/src/AdaptableOptions/CustomSortOptions.d.ts +4 -0
- package/src/AdaptableOptions/DashboardOptions.d.ts +1 -2
- package/src/AdaptableOptions/ExportOptions.d.ts +1 -2
- package/src/AdaptableOptions/FilterOptions.d.ts +3 -0
- package/src/AdaptableOptions/ToolPanelOptions.d.ts +1 -2
- package/src/AdaptableState/AdaptableState.d.ts +2 -0
- package/src/AdaptableState/AlertState.d.ts +5 -2
- package/src/AdaptableState/ChartingState.d.ts +2 -2
- package/src/AdaptableState/Common/AdaptableAlert.d.ts +2 -2
- package/src/AdaptableState/Common/AdaptableButton.d.ts +2 -2
- package/src/AdaptableState/Common/AdaptableColumn.d.ts +16 -10
- package/src/AdaptableState/Common/AdaptableColumnContext.d.ts +9 -0
- package/src/AdaptableState/Common/AdaptableFlashingCell.d.ts +2 -2
- package/src/AdaptableState/Common/AdaptableObject.d.ts +20 -2
- package/src/AdaptableState/Common/AdaptableRowContext.d.ts +11 -0
- package/src/AdaptableState/Common/AdaptableStyle.d.ts +8 -0
- package/src/AdaptableState/Common/BaseContext.d.ts +2 -0
- package/src/AdaptableState/Common/ColumnHighlightInfo.d.ts +18 -0
- package/src/AdaptableState/Common/ColumnHighlightInfo.js +2 -0
- package/src/AdaptableState/Common/DataUpdateConfig.d.ts +17 -0
- package/src/AdaptableState/Common/NamedObject.d.ts +10 -0
- package/src/AdaptableState/Common/NamedObject.js +2 -0
- package/src/AdaptableState/Common/RowDataChangedInfo.d.ts +3 -0
- package/src/AdaptableState/Common/RowSummary.d.ts +1 -1
- package/src/AdaptableState/Common/Schedule.d.ts +8 -5
- package/src/AdaptableState/Common/SystemStatusMessageInfo.d.ts +2 -2
- package/src/AdaptableState/Common/TransposeConfig.d.ts +12 -10
- package/src/AdaptableState/CustomSortState.d.ts +5 -1
- package/src/AdaptableState/DashboardState.d.ts +1 -1
- package/src/AdaptableState/ExportState.d.ts +1 -1
- package/src/AdaptableState/FlashingCellState.d.ts +6 -2
- package/src/AdaptableState/FormatColumnState.d.ts +5 -9
- package/src/AdaptableState/InitialState.d.ts +10 -1
- package/src/AdaptableState/InternalState.d.ts +2 -0
- package/src/AdaptableState/LayoutState.d.ts +7 -3
- package/src/AdaptableState/NamedQueryState.d.ts +1 -1
- package/src/AdaptableState/PlusMinusState.d.ts +5 -1
- package/src/AdaptableState/Selection/GridCell.d.ts +9 -0
- package/src/AdaptableState/ShortcutState.d.ts +5 -1
- package/src/AdaptableState/StyledColumnState.d.ts +1 -1
- package/src/AdaptableState/ThemeState.d.ts +1 -1
- package/src/AdaptableState/UserInterfaceState.d.ts +14 -0
- package/src/AdaptableState/UserInterfaceState.js +2 -0
- package/src/Api/AlertApi.d.ts +6 -0
- package/src/Api/CustomSortApi.d.ts +12 -3
- package/src/Api/DataSetApi.d.ts +1 -1
- package/src/Api/FlashingCellApi.d.ts +6 -0
- package/src/Api/FormatColumnApi.d.ts +10 -4
- package/src/Api/GridApi.d.ts +23 -12
- package/src/Api/Implementation/ActionColumnApiImpl.js +1 -0
- package/src/Api/Implementation/AdaptableApiImpl.js +52 -0
- package/src/Api/Implementation/AlertApiImpl.d.ts +1 -0
- package/src/Api/Implementation/AlertApiImpl.js +6 -6
- package/src/Api/Implementation/ApiBase.d.ts +1 -1
- package/src/Api/Implementation/ApiBase.js +2 -1
- package/src/Api/Implementation/CalculatedColumnApiImpl.js +1 -0
- package/src/Api/Implementation/ChartingApiImpl.js +6 -2
- package/src/Api/Implementation/ColumnApiImpl.d.ts +1 -1
- package/src/Api/Implementation/ColumnApiImpl.js +1 -0
- package/src/Api/Implementation/ColumnFilterApiImpl.js +1 -0
- package/src/Api/Implementation/CommentsApiImpl.js +1 -0
- package/src/Api/Implementation/CustomSortApiImpl.d.ts +6 -1
- package/src/Api/Implementation/CustomSortApiImpl.js +6 -2
- package/src/Api/Implementation/DashboardApiImpl.js +1 -0
- package/src/Api/Implementation/DataChangeHistoryApiImpl.js +12 -15
- package/src/Api/Implementation/DataImportApiImpl.js +1 -0
- package/src/Api/Implementation/DataSetApiImpl.js +1 -0
- package/src/Api/Implementation/EntitlementApiImpl.js +1 -0
- package/src/Api/Implementation/EventApiImpl.js +16 -14
- package/src/Api/Implementation/ExportApiImpl.js +1 -0
- package/src/Api/Implementation/ExpressionApiImpl.js +1 -0
- package/src/Api/Implementation/Fdc3ApiImpl.js +1 -0
- package/src/Api/Implementation/FilterApiImpl.js +3 -0
- package/src/Api/Implementation/FlashingCellApiImpl.d.ts +1 -0
- package/src/Api/Implementation/FlashingCellApiImpl.js +4 -0
- package/src/Api/Implementation/FormatColumnApiImpl.d.ts +6 -5
- package/src/Api/Implementation/FormatColumnApiImpl.js +7 -5
- package/src/Api/Implementation/FreeTextColumnApiImpl.js +1 -0
- package/src/Api/Implementation/GridApiImpl.d.ts +10 -10
- package/src/Api/Implementation/GridApiImpl.js +35 -20
- package/src/Api/Implementation/GridFilterApiImpl.js +1 -0
- package/src/Api/Implementation/LayoutApiImpl.d.ts +1 -0
- package/src/Api/Implementation/LayoutApiImpl.js +5 -1
- package/src/Api/Implementation/LayoutHelpers.js +7 -0
- package/src/Api/Implementation/NamedQueryApiImpl.js +3 -2
- package/src/Api/Implementation/NoteApiImpl.js +1 -0
- package/src/Api/Implementation/PlusMinusApiImpl.d.ts +1 -0
- package/src/Api/Implementation/PlusMinusApiImpl.js +3 -0
- package/src/Api/Implementation/PredicateApiImpl.js +1 -0
- package/src/Api/Implementation/RowFormApiImpl.js +1 -0
- package/src/Api/Implementation/ScheduleApiImpl.d.ts +1 -0
- package/src/Api/Implementation/ScheduleApiImpl.js +4 -0
- package/src/Api/Implementation/ShortcutApiImpl.d.ts +1 -0
- package/src/Api/Implementation/ShortcutApiImpl.js +3 -0
- package/src/Api/Implementation/StyledColumnApiImpl.js +1 -0
- package/src/Api/Implementation/SystemStatusApiImpl.js +8 -9
- package/src/Api/Implementation/TeamSharingApiImpl.js +1 -0
- package/src/Api/Implementation/ThemeApiImpl.js +1 -0
- package/src/Api/Implementation/UserInterfaceApiImpl.d.ts +5 -0
- package/src/Api/Implementation/UserInterfaceApiImpl.js +15 -1
- package/src/Api/Internal/CalculatedColumnInternalApi.js +2 -2
- package/src/Api/Internal/ColumnInternalApi.js +1 -1
- package/src/Api/Internal/FormatColumnInternalApi.d.ts +0 -10
- package/src/Api/Internal/FormatColumnInternalApi.js +1 -19
- package/src/Api/Internal/FreeTextColumnInternalApi.js +2 -2
- package/src/Api/Internal/LayoutInternalApi.js +1 -1
- package/src/Api/Internal/NamedQueryInternalApi.js +4 -4
- package/src/Api/LayoutApi.d.ts +6 -0
- package/src/Api/PlusMinusApi.d.ts +6 -0
- package/src/Api/ScheduleApi.d.ts +6 -0
- package/src/Api/ShortcutApi.d.ts +6 -0
- package/src/Api/UserInterfaceApi.d.ts +17 -0
- package/src/Redux/ActionsReducers/FormatColumnRedux.d.ts +8 -0
- package/src/Redux/ActionsReducers/FormatColumnRedux.js +17 -1
- package/src/Redux/ActionsReducers/InternalRedux.d.ts +15 -0
- package/src/Redux/ActionsReducers/InternalRedux.js +42 -3
- package/src/Redux/ActionsReducers/LayoutRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/NoteRedux.js +1 -1
- package/src/Redux/ActionsReducers/UserInterfaceRedux.d.ts +11 -0
- package/src/Redux/ActionsReducers/UserInterfaceRedux.js +26 -0
- package/src/Redux/Store/AdaptableReduxLocalStorageEngine.js +6 -0
- package/src/Redux/Store/AdaptableStore.js +113 -57
- package/src/Strategy/AdaptableModuleBase.js +4 -0
- package/src/Strategy/AlertModule.js +5 -0
- package/src/Strategy/BulkUpdateModule.js +8 -8
- package/src/Strategy/CalculatedColumnModule.js +1 -0
- package/src/Strategy/CellSummaryModule.js +1 -1
- package/src/Strategy/CustomSortModule.js +4 -0
- package/src/Strategy/DataChangeHistoryModule.js +1 -0
- package/src/Strategy/FlashingCellModule.js +6 -0
- package/src/Strategy/FormatColumnModule.js +4 -0
- package/src/Strategy/FreeTextColumnModule.js +1 -0
- package/src/Strategy/LayoutModule.js +6 -5
- package/src/Strategy/PlusMinusModule.js +7 -1
- package/src/Strategy/QuickSearchModule.js +1 -1
- package/src/Strategy/ScheduleModule.js +5 -0
- package/src/Strategy/SettingsPanelModule.js +11 -7
- package/src/Strategy/ShortcutModule.js +6 -0
- package/src/Strategy/SmartEditModule.js +10 -10
- package/src/Strategy/TeamSharingModule.js +10 -10
- package/src/Strategy/Utilities/FormatColumn/getFormatColumnSettingsViewItems.js +0 -3
- package/src/Utilities/Constants/DocumentationLinkConstants.d.ts +3 -3
- package/src/Utilities/Constants/DocumentationLinkConstants.js +3 -3
- package/src/Utilities/ExpressionFunctions/deepMap.js +31 -31
- package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.js +3 -3
- package/src/Utilities/Extensions/StringExtensions.d.ts +2 -0
- package/src/Utilities/Extensions/StringExtensions.js +17 -0
- package/src/Utilities/Helpers/FormatHelper.js +9 -2
- package/src/Utilities/Helpers/StyleHelper.js +14 -0
- package/src/Utilities/MenuItem.js +18 -0
- package/src/Utilities/ObjectFactory.js +16 -3
- package/src/Utilities/Services/AggregatedScalarLiveValue.js +8 -0
- package/src/Utilities/Services/AlertService.js +6 -4
- package/src/Utilities/Services/AnnotationsService.js +4 -1
- package/src/Utilities/Services/CalculatedColumnExpressionService.js +2 -1
- package/src/Utilities/Services/ChartingService.js +1 -0
- package/src/Utilities/Services/DataService.js +11 -3
- package/src/Utilities/Services/Fdc3Service.js +9 -7
- package/src/Utilities/Services/FlashingCellService.js +5 -0
- package/src/Utilities/Services/LicenseService/index.js +1 -1
- package/src/Utilities/Services/MetamodelService.js +2 -2
- package/src/Utilities/Services/ModuleService.js +5 -6
- package/src/Utilities/Services/QueryLanguageService.js +6 -5
- package/src/Utilities/Services/RowFormService.js +1 -0
- package/src/Utilities/Services/RowSummaryService.js +10 -7
- package/src/Utilities/Services/TeamSharingService.js +3 -1
- package/src/Utilities/Services/ThemeService.js +13 -15
- package/src/Utilities/Services/ValidationService.js +2 -1
- package/src/Utilities/createAgStatusPanelComponent.js +3 -0
- package/src/Utilities/logDeprecation.js +3 -4
- package/src/Utilities/resolveContainerElement.d.ts +23 -0
- package/src/Utilities/resolveContainerElement.js +47 -0
- package/src/View/AdaptablePopover/index.d.ts +1 -0
- package/src/View/AdaptablePopover/index.js +1 -1
- package/src/View/Alert/ActiveAlertsPanel.js +8 -0
- package/src/View/Alert/AlertViewPanel.js +13 -9
- package/src/View/Alert/Utilities/getAlertButtonStyle.d.ts +1 -0
- package/src/View/Alert/Utilities/getAlertButtonStyle.js +8 -0
- package/src/View/Alert/Utilities/getDefaultAlertDefinition.d.ts +1 -0
- package/src/View/Alert/Wizard/AlertTypeWizardSection.d.ts +5 -2
- package/src/View/Alert/Wizard/AlertTypeWizardSection.js +48 -12
- package/src/View/Alert/Wizard/AlertWizard.js +12 -8
- package/src/View/Alert/Wizard/isValidAlertRules.js +1 -1
- package/src/View/BulkUpdate/BulkUpdateViewPanel.js +24 -11
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnDefinitionWizardSection.js +2 -2
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnExpressionWizardSection.js +2 -2
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnSettingsWizardSection.js +1 -1
- package/src/View/CellSummary/CellSummaryViewPanel.js +16 -17
- package/src/View/Charting/ChartingWizard/AgChargingWizard/SettingsSection.js +2 -2
- package/src/View/Charting/ChartingWizard/ExternalChartingWizard/SettingsSection.js +2 -2
- package/src/View/Components/AdaptableDateInput/index.js +1 -1
- package/src/View/Components/Buttons/ButtonApply.js +1 -1
- package/src/View/Components/Buttons/ButtonBase/index.js +9 -9
- package/src/View/Components/Buttons/ButtonClear.d.ts +1 -0
- package/src/View/Components/Buttons/EntityListActionButtons.d.ts +1 -2
- package/src/View/Components/Buttons/EntityListActionButtons.js +18 -18
- package/src/View/Components/Buttons/SuspendToggleButton/SuspendToggleButton.d.ts +1 -2
- package/src/View/Components/CellPopup/index.js +1 -1
- package/src/View/Components/ColumnFilter/FloatingFilter.js +41 -3
- package/src/View/Components/ColumnFilter/components/ColumnFilterInput.js +1 -1
- package/src/View/Components/ColumnFilter/components/ColumnFilterMenu.js +54 -2
- package/src/View/Components/ColumnFilter/components/FloatingFilterValues.js +1 -1
- package/src/View/Components/EntityRulesEditor/Utilities.js +5 -5
- package/src/View/Components/NewScopeComponent.js +3 -3
- package/src/View/Components/Panels/PanelDashboard/index.js +8 -8
- package/src/View/Components/Panels/PanelToolPanel/index.js +7 -7
- package/src/View/Components/Popups/AdaptablePopup/AdaptablePopup.js +2 -1
- package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupBody.js +1 -1
- package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupDialog.d.ts +1 -1
- package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupDialog.js +1 -8
- package/src/View/Components/Popups/AdaptablePopupConfirmation.js +1 -1
- package/src/View/Components/Popups/WindowPopups/WindowPopups.js +35 -0
- package/src/View/Components/Selectors/BulkUpdateValueSelector.js +18 -17
- package/src/View/Components/StyleComponent.d.ts +1 -0
- package/src/View/Components/StyleComponent.js +94 -24
- package/src/View/Components/ToolPanel/AdaptableToolPanel.js +2 -0
- package/src/View/Components/WizardSummaryPage.js +1 -1
- package/src/View/CustomSort/Wizard/CustomSortColumnWizardSection.d.ts +2 -1
- package/src/View/CustomSort/Wizard/CustomSortColumnWizardSection.js +40 -14
- package/src/View/CustomSort/Wizard/CustomSortValuesWizardSection.js +1 -1
- package/src/View/CustomSort/Wizard/CustomSortWizard.js +4 -4
- package/src/View/Dashboard/CustomToolbar.js +1 -1
- package/src/View/Dashboard/DashboardPopup.js +4 -5
- package/src/View/DataChangeHistory/DataChangeHistoryGrid.js +1 -0
- package/src/View/DataChangeHistory/DataChangeHistoryViewPanel.js +1 -1
- package/src/View/Export/ExportDestinationPicker.js +1 -1
- package/src/View/Export/ExportStatusBar.js +4 -2
- package/src/View/Export/ExportViewPanel.js +25 -18
- package/src/View/FlashingCell/Wizard/FlashingCellSettingsWizardSection.d.ts +2 -1
- package/src/View/FlashingCell/Wizard/FlashingCellSettingsWizardSection.js +36 -15
- package/src/View/FlashingCell/Wizard/FlashingCellWizard.js +13 -9
- package/src/View/FlashingCell/Wizard/isValidFlashingCellRules.js +1 -1
- package/src/View/FormatColumn/Wizard/FormatColumnSettingsWizardSection.js +46 -51
- package/src/View/FormatColumn/Wizard/FormatColumnStyleWizardSection.js +2 -2
- package/src/View/FormatColumn/Wizard/FormatColumnWizard.js +22 -11
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.d.ts +1 -1
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.js +3 -3
- package/src/View/GridFilter/GridFilterExpressionEditor.js +6 -1
- package/src/View/GridFilter/GridFilterViewPanel.js +33 -70
- package/src/View/GridInfo/GridInfoPopup/GridInfoPopup.js +57 -65
- package/src/View/Layout/LayoutViewPanel.js +1 -1
- package/src/View/Layout/TransposedPopup.js +144 -138
- package/src/View/Layout/Wizard/sections/AggregationsSection.js +1 -1
- package/src/View/Layout/Wizard/sections/FilterSection.js +1 -1
- package/src/View/Layout/Wizard/sections/GridFilterSection.js +1 -1
- package/src/View/Layout/Wizard/sections/PivotAggregationsSection.js +3 -3
- package/src/View/Layout/Wizard/sections/PivotColumnsSection.js +8 -0
- package/src/View/Layout/Wizard/sections/RowSummarySection.js +1 -1
- package/src/View/NamedQuery/Wizard/NamedQueryExpressionWizardSection.js +2 -2
- package/src/View/PlusMinus/Wizard/PlusMinusSettingsWizardSection.js +35 -12
- package/src/View/PlusMinus/Wizard/PlusMinusWizard.js +20 -15
- package/src/View/QuickSearch/QuickSearchPopup.js +4 -1
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsIPushPull.js +12 -1
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsOpenFin.js +12 -1
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsReminder.js +14 -4
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsReport.js +12 -1
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/isSettingsValid.d.ts +2 -1
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/isSettingsValid.js +19 -10
- package/src/View/Shortcut/Wizard/ShortcutSettingsWizard.d.ts +2 -1
- package/src/View/Shortcut/Wizard/ShortcutSettingsWizard.js +25 -4
- package/src/View/Shortcut/Wizard/ShortcutWizard.js +18 -14
- package/src/View/SmartEdit/SmartEditViewPanel.js +1 -0
- package/src/View/StateManagement/handleExportState.js +1 -1
- package/src/View/StyledColumn/Wizard/StyledColumnWizardColumnSection.js +1 -1
- package/src/View/Theme/ThemePopup.js +13 -16
- package/src/View/UIHelper.d.ts +4 -1
- package/src/View/UIHelper.js +24 -14
- package/src/agGrid/Adaptable.js +15 -11
- package/src/agGrid/AdaptableAgGrid.d.ts +12 -8
- package/src/agGrid/AdaptableAgGrid.js +257 -111
- package/src/agGrid/AdaptableFilterHandler.js +4 -0
- package/src/agGrid/AdaptableLogger.d.ts +3 -0
- package/src/agGrid/AdaptableLogger.js +10 -0
- package/src/agGrid/AgGridAdapter.js +19 -9
- package/src/agGrid/AgGridColumnAdapter.d.ts +1 -0
- package/src/agGrid/AgGridColumnAdapter.js +20 -22
- package/src/agGrid/AgGridExportAdapter.js +15 -14
- package/src/agGrid/AgGridFilterAdapter.js +4 -0
- package/src/agGrid/AgGridFloatingFilterAdapter.js +4 -1
- package/src/agGrid/AgGridMenuAdapter.js +10 -1
- package/src/agGrid/AgGridModulesAdapter.js +2 -1
- package/src/agGrid/AgGridOptionsService.js +3 -0
- package/src/agGrid/AgGridThemeAdapter.js +4 -2
- package/src/agGrid/cellRenderers/ActionColumnRenderer.js +5 -0
- package/src/agGrid/cellRenderers/BadgeRenderer.js +2 -0
- package/src/agGrid/cellRenderers/PercentBarRenderer.js +1 -0
- package/src/agGrid/editors/AdaptableDateEditor/index.js +6 -3
- package/src/agGrid/editors/AdaptableNumberEditor/index.js +16 -12
- package/src/agGrid/editors/AdaptablePercentageEditor/index.js +17 -13
- package/src/agGrid/index.d.ts +6 -0
- package/src/agGrid/index.js +6 -0
- package/src/components/CheckBox/index.js +1 -1
- package/src/components/ColorPicker/ColorPicker.js +5 -4
- package/src/components/Dashboard/DashboardToolbar.js +1 -1
- package/src/components/Datepicker/index.js +1 -1
- package/src/components/Dropdown/Arrows.js +1 -1
- package/src/components/ExpressionEditor/DataTableEditor.js +3 -3
- package/src/components/ExpressionEditor/EditorInput.js +19 -3
- package/src/components/ExpressionEditor/ExpressionFunctionDocumentation.js +1 -1
- package/src/components/FormLayout/index.js +1 -1
- package/src/components/OverlayTrigger/index.js +1 -1
- package/src/components/Select/Select.js +78 -15
- package/src/components/Tree/TreeDropdown/index.js +2 -2
- package/src/components/overlayBaseZIndex.js +1 -1
- package/src/components/utils/useContainerScrollObserver/index.js +17 -14
- package/src/devTools/index.js +54 -53
- package/src/env.js +2 -2
- package/src/layout-manager/src/LMEmitter.js +11 -11
- package/src/layout-manager/src/LMLogger.js +7 -0
- package/src/layout-manager/src/LayoutManagerModel.d.ts +1 -0
- package/src/layout-manager/src/index.js +81 -58
- package/src/layout-manager/src/normalizeLayoutModel.js +3 -0
- package/src/metamodel/adaptable.metamodel.d.ts +177 -8
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/migration/AdaptableUpgradeHelper.js +8 -3
- package/src/migration/VersionUpgrade.js +1 -0
- package/src/migration/VersionUpgrade17.js +5 -6
- package/src/migration/VersionUpgrade20.js +4 -4
- package/src/migration/VersionUpgrade22.d.ts +21 -0
- package/src/migration/VersionUpgrade22.js +191 -0
- package/src/parser/src/ExpressionEvaluationError.js +1 -0
- package/src/types.d.ts +9 -7
- package/themes/dark.css +30 -30
- package/themes/light.css +4 -2
- package/tsconfig.cjs.tsbuildinfo +1 -1
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.d.ts +0 -1
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.js +0 -633
- package/src/View/Alert/AlertEntityRow.d.ts +0 -11
- package/src/View/Alert/AlertEntityRow.js +0 -33
- package/src/View/CalculatedColumn/CalculatedColumnSummary.d.ts +0 -21
- package/src/View/CalculatedColumn/CalculatedColumnSummary.js +0 -63
- package/src/View/Components/Buttons/ButtonFunction.d.ts +0 -7
- package/src/View/Components/Buttons/ButtonFunction.js +0 -13
- package/src/View/Components/Buttons/ButtonGeneral.d.ts +0 -5
- package/src/View/Components/Buttons/ButtonGeneral.js +0 -12
- package/src/View/Components/Buttons/ButtonPreviewDelete.d.ts +0 -4
- package/src/View/Components/Buttons/ButtonPreviewDelete.js +0 -8
- package/src/View/Components/Buttons/ButtonShow.d.ts +0 -5
- package/src/View/Components/Buttons/ButtonShow.js +0 -12
- package/src/View/Components/Buttons/ButtonShowChart.d.ts +0 -5
- package/src/View/Components/Buttons/ButtonShowChart.js +0 -12
- package/src/View/Components/Buttons/ButtonUndo.d.ts +0 -5
- package/src/View/Components/Buttons/ButtonUndo.js +0 -12
- package/src/View/Components/ExpressionWizard.d.ts +0 -24
- package/src/View/Components/ExpressionWizard.js +0 -82
- package/src/View/Components/FilterForm/Waiting.d.ts +0 -10
- package/src/View/Components/FilterForm/Waiting.js +0 -19
- package/src/View/Components/Panels/PanelFooter.d.ts +0 -10
- package/src/View/Components/Panels/PanelFooter.js +0 -14
- package/src/View/Components/Panels/PanelWithTwoButtons.d.ts +0 -12
- package/src/View/Components/Panels/PanelWithTwoButtons.js +0 -20
- package/src/View/Components/Panels/ToolPanelSettingsPanel.d.ts +0 -8
- package/src/View/Components/Panels/ToolPanelSettingsPanel.js +0 -31
- package/src/View/Components/Selectors/ColumnSelectorOld.d.ts +0 -18
- package/src/View/Components/Selectors/ColumnSelectorOld.js +0 -50
- package/src/View/Components/SharedProps/WizardScopeState.d.ts +0 -4
- package/src/View/Components/WizardSummaryRow.d.ts +0 -9
- package/src/View/Components/WizardSummaryRow.js +0 -16
- package/src/View/CustomSort/CustomSortSummary.d.ts +0 -23
- package/src/View/CustomSort/CustomSortSummary.js +0 -110
- package/src/View/DataImport/DataImportWizard/sections/ImportSection.d.ts +0 -9
- package/src/View/DataImport/DataImportWizard/sections/ImportSection.js +0 -24
- package/src/View/Export/Wizard/ReportColumnTypeWizard.d.ts +0 -19
- package/src/View/Export/Wizard/ReportColumnTypeWizard.js +0 -73
- package/src/View/Export/Wizard/ReportRowTypeWizard.d.ts +0 -19
- package/src/View/Export/Wizard/ReportRowTypeWizard.js +0 -73
- package/src/View/Export/Wizard/ReportSettingsWizard.d.ts +0 -21
- package/src/View/Export/Wizard/ReportSettingsWizard.js +0 -61
- package/src/View/Export/Wizard/ReportSummaryWizard.d.ts +0 -15
- package/src/View/Export/Wizard/ReportSummaryWizard.js +0 -40
- package/src/View/Filter/FilterSummary.d.ts +0 -18
- package/src/View/Filter/FilterSummary.js +0 -53
- package/src/View/FormatColumn/FormatColumnSummary.d.ts +0 -22
- package/src/View/FormatColumn/FormatColumnSummary.js +0 -95
- package/src/View/FreeTextColumn/FreeTextColumnSummary.d.ts +0 -22
- package/src/View/FreeTextColumn/FreeTextColumnSummary.js +0 -93
- package/src/View/GridInfo/GridInfoPopup/AdaptableOptionsComponent.d.ts +0 -7
- package/src/View/GridInfo/GridInfoPopup/AdaptableOptionsComponent.js +0 -99
- package/src/View/PlusMinus/PlusMinusSummary.d.ts +0 -22
- package/src/View/PlusMinus/PlusMinusSummary.js +0 -100
- package/src/View/Wizard/WizardLegend.d.ts +0 -12
- package/src/View/Wizard/WizardLegend.js +0 -28
- /package/src/{View/Components/SharedProps/WizardScopeState.js → AdaptableState/Common/AdaptableRowContext.js} +0 -0
|
@@ -4,11 +4,13 @@ exports.Fdc3Service = void 0;
|
|
|
4
4
|
const Fdc3Context_1 = require("../../AdaptableState/Common/Fdc3Context");
|
|
5
5
|
const Fdc3Intent_1 = require("../../AdaptableState/Common/Fdc3Intent");
|
|
6
6
|
class Fdc3Service {
|
|
7
|
+
adaptableApi;
|
|
8
|
+
contextHandlerSubscriptions = [];
|
|
9
|
+
intentHandlerSubscriptions = [];
|
|
10
|
+
loggedAgentError = false;
|
|
11
|
+
uiControlsDefaultConfiguration;
|
|
7
12
|
constructor(adaptableApi) {
|
|
8
13
|
this.adaptableApi = adaptableApi;
|
|
9
|
-
this.contextHandlerSubscriptions = [];
|
|
10
|
-
this.intentHandlerSubscriptions = [];
|
|
11
|
-
this.loggedAgentError = false;
|
|
12
14
|
// 1. Subscribe to FDC3 events
|
|
13
15
|
const adaptableHandleIntentFn = this.getFdc3Options().intents?.handleIntent;
|
|
14
16
|
const listenForIntents = this.getFdc3Options().intents?.listensFor ?? [];
|
|
@@ -79,7 +81,7 @@ class Fdc3Service {
|
|
|
79
81
|
getDesktopAgent() {
|
|
80
82
|
if (globalThis.fdc3 == null && !this.loggedAgentError) {
|
|
81
83
|
this.loggedAgentError = true;
|
|
82
|
-
this.adaptableApi.consoleError('FDC3 Desktop Agent not found.
|
|
84
|
+
this.adaptableApi.consoleError('FDC3 Desktop Agent not found. The host application must provide the FDC3 agent on globalThis.fdc3.');
|
|
83
85
|
}
|
|
84
86
|
return globalThis.fdc3;
|
|
85
87
|
}
|
|
@@ -162,11 +164,11 @@ class Fdc3Service {
|
|
|
162
164
|
if (!this.getFdc3Options().enableLogging) {
|
|
163
165
|
return;
|
|
164
166
|
}
|
|
165
|
-
this.adaptableApi.consoleLog(`FDC3
|
|
167
|
+
this.adaptableApi.consoleLog(`FDC3 ${type}: ${params.join(' : ')}`);
|
|
166
168
|
}
|
|
167
169
|
logFdc3Error(error) {
|
|
168
|
-
this.adaptableApi.consoleError(
|
|
169
|
-
this.adaptableApi.alertApi.showAlertError('FDC3
|
|
170
|
+
this.adaptableApi.consoleError('FDC3 operation failed.', error);
|
|
171
|
+
this.adaptableApi.alertApi.showAlertError('FDC3', 'An error occurred. See the browser console for details.');
|
|
170
172
|
}
|
|
171
173
|
getFdc3Api() {
|
|
172
174
|
return this.adaptableApi.fdc3Api;
|
|
@@ -6,6 +6,11 @@ exports.FLASHING_CELL_ROW_KEY = '__ROW';
|
|
|
6
6
|
* This service manages Flashing Cells
|
|
7
7
|
*/
|
|
8
8
|
class FlashingCellService {
|
|
9
|
+
api;
|
|
10
|
+
// map of rowPrimaryKey -> ColIdOrRowId -> FlashingCellUuid
|
|
11
|
+
gridCellsCurrentlyFlashing;
|
|
12
|
+
// map of FlashingCellUuid -> FlashingCell
|
|
13
|
+
flashingCellsMapping;
|
|
9
14
|
constructor(api) {
|
|
10
15
|
this.api = api;
|
|
11
16
|
this.gridCellsCurrentlyFlashing = {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.LicenseService=exports.LicenseValidityType=void 0;const e=require("tslib"),a=require("../../../Redux/ActionsReducers/InternalRedux"),t=require("../../../Redux/ActionsReducers/PopupRedux"),s=e.__importDefault(require("../../ObjectFactory")),i=e.__importDefault(require("lodash/clamp")),o=require("../../Constants/DocumentationLinkConstants"),n=require("../../license/decode"),r=require("./shouldLogThankYouMessage"),l="sales@adaptabletools.com",c=10,d=864e5;var p;!function(e){e.INVALID_LICENSE="INVALID_LICENSE",e.NO_LICENSE="NO_LICENSE",e.NON_PRODUCTION_VALID="NON_PRODUCTION_VALID",e.NON_PRODUCTION_EXPIRED_IN_SCOPE="NON_PRODUCTION_EXPIRED_IN_SCOPE",e.NON_PRODUCTION_EXPIRED_OUT_OF_SCOPE="NON_PRODUCTION_EXPIRED_OUT_OF_SCOPE",e.COMMERCIAL_VALID="COMMERCIAL_VALID",e.COMMERCIAL_EXPIRED_IN_SCOPE="COMMERCIAL_EXPIRED_IN_SCOPE",e.COMMERCIAL_EXPIRED_OUT_OF_SCOPE="COMMERCIAL_EXPIRED_OUT_OF_SCOPE"}(p||(exports.LicenseValidityType=p={}));const h=()=>"undefined"!=typeof window?window.location.origin:"",E=()=>{const e=h(),[a,t,s]=Array.from(/(https):\/\/\d+\-\d+\-\d+\-(sandpack\.codesandbox\.io)/g.exec(e)||[]);return"https"===t&&"sandpack.codesandbox.io"===s},_=()=>{const e=h(),[a,t,s]=Array.from(/(https):\/\/\S+(\.csb\.app)/g.exec(e)||[]);return"https"===t&&".csb.app"===s},I=()=>{const e=h(),[a,t,s]=Array.from(/(https):\/\/\S+(\.adaptabletools\.com)/g.exec(e)||[]);return"https"===t&&".adaptabletools.com"===s};class O{constructor(e,a,t){this.adaptable=e,this.licenseKey=a,this.packageDetails=t,this.adaptable=e,this.adaptable.api.eventApi.on("AdaptableReady",()=>{requestAnimationFrame(()=>{this.adaptable.isDestroyed||this.init()})})}init(){let e=null;if(this.licenseKey)try{e=(0,n.decode)(this.licenseKey)}catch(a){e=a}E()||_()||I()||this.handleLicenseValidation(e,this.getValidityType(e,this.packageDetails))}getValidityType(e,a){if(!e)return p.NO_LICENSE;if(e instanceof Error)return p.INVALID_LICENSE;const t=new Date(a.publishedAt),s=new Date(e.end),i=s<new Date,o=e.trial;let n=null;return n=i?s>t?o?p.NON_PRODUCTION_EXPIRED_IN_SCOPE:p.COMMERCIAL_EXPIRED_IN_SCOPE:o?p.NON_PRODUCTION_EXPIRED_OUT_OF_SCOPE:p.COMMERCIAL_EXPIRED_OUT_OF_SCOPE:o?p.NON_PRODUCTION_VALID:p.COMMERCIAL_VALID,n}handleLicenseValidation(e,a){const t=new Date;t.setHours(0,0,0,0);let s=0;e instanceof Error||!e?.end||(s=Math.floor((e?.end?.getTime()-t.getTime())/d),s=(0,i.default)(s,0,1/0));let p="",h="";!e||e instanceof Error||!e.appName||e.appName==n.GENERIC_APP_NAME||(p=e.appName,h=" for application [APP_NAME]");const E=(e,a=o.LicenseDocsLink,t=l,i=s,n=p)=>e.replace("[LINK]",a).replace("[EMAIL]",t).replace("[APP_NAME]",n).replace("[DAYS]",`${i}`);switch(a){case"NO_LICENSE":case"NON_PRODUCTION_EXPIRED_OUT_OF_SCOPE":this.adaptable.logger.consoleLogByMessageType(E("This instance of AdapTable does not have a license, and some functionality has therefore been removed. In order to use a fully-featured version of AdapTable, please contact [EMAIL]. You can learn more about the different AdapTable license options at [LINK]."),"Error"),this.showNotification("No AdapTable License found."),this.showWatermark("This instance of AdapTable does not have a license, and some functionality has therefore been removed."),this.disableStatePersistence();break;case"INVALID_LICENSE":this.adaptable.logger.consoleLogByMessageType(E("This instance of AdapTable seems to use a corrupted License, and some functionality has therefore been removed. In order to use a fully-featured version of AdapTable, please contact [EMAIL]. You can learn more about the different AdapTable license options at [LINK]."),"Error"),this.showNotification("Corrupted AdapTable License found."),this.showWatermark("This instance of AdapTable has a corrupted License, and some functionality has therefore been removed."),this.disableStatePersistence();break;case"NON_PRODUCTION_VALID":this.adaptable.logger.consoleLogByMessageType(E("This AdapTable trial license expires in [DAYS] days. Please contact [EMAIL] to upgrade to a commercial version of AdapTable. You can learn more about the different AdapTable license options at [LINK]."),"Info");break;case"NON_PRODUCTION_EXPIRED_IN_SCOPE":this.adaptable.logger.consoleLogByMessageType(E("This AdapTable trial license has now expired. Please contact [EMAIL] to upgrade to a commercial version of AdapTable. You can learn more about the different AdapTable license options at [LINK]."),"Warning"),this.showWatermark("AdapTable License has expired");break;case"COMMERCIAL_VALID":if(s<=c)this.adaptable.logger.consoleLogByMessageType(E(`This AdapTable license${h} expires in [DAYS] days. Please contact [EMAIL] to renew (giving you access to Support and Updates)`),"Info");else try{(0,r.shouldLogThankYouMessage)()&&this.adaptable.logger.consoleLogByMessageType(E(`Thank you for using a valid AdapTable license${h}. Your license will expire in [DAYS] days.`),"Info")}catch(e){}break;case"COMMERCIAL_EXPIRED_IN_SCOPE":this.adaptable.logger.consoleLogByMessageType(E(`This AdapTable license${h} has expired. Please contact [EMAIL] if you wish to renew (giving you access to Support and Updates)`),"Warning");break;case"COMMERCIAL_EXPIRED_OUT_OF_SCOPE":this.adaptable.logger.consoleLogByMessageType(E(`This AdapTable license${h} has expired. Adaptable version was published after the license expired. Please contact [EMAIL] if you wish to renew your license.`),"Error"),this.showNotification("Adaptable License has expired"),this.showWatermark("Adaptable License has expired")}}showNotification(e){this.adaptable.api.internalApi.dispatchReduxAction((0,t.PopupShowAlert)({alertType:"generic",header:"License Error",message:e,alertDefinition:s.default.CreateInternalAlertDefinitionForMessages("Error")}))}showWatermark(e){this.adaptable.api.internalApi.dispatchReduxAction((0,a.LicenseShowWatermark)(e))}disableStatePersistence(){this.adaptable.api.internalApi.dispatchReduxAction((0,a.LicenseDisablePersistence)())}destroy(){}}exports.LicenseService=O;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.LicenseService=exports.LicenseValidityType=void 0;const e=require("tslib"),a=require("../../../Redux/ActionsReducers/InternalRedux"),t=require("../../../Redux/ActionsReducers/PopupRedux"),s=e.__importDefault(require("../../ObjectFactory")),i=e.__importDefault(require("lodash/clamp")),o=require("../../Constants/DocumentationLinkConstants"),n=require("../../license/decode"),r=require("./shouldLogThankYouMessage"),l="sales@adaptabletools.com",c=10,d=864e5;var p;!function(e){e.INVALID_LICENSE="INVALID_LICENSE",e.NO_LICENSE="NO_LICENSE",e.NON_PRODUCTION_VALID="NON_PRODUCTION_VALID",e.NON_PRODUCTION_EXPIRED_IN_SCOPE="NON_PRODUCTION_EXPIRED_IN_SCOPE",e.NON_PRODUCTION_EXPIRED_OUT_OF_SCOPE="NON_PRODUCTION_EXPIRED_OUT_OF_SCOPE",e.COMMERCIAL_VALID="COMMERCIAL_VALID",e.COMMERCIAL_EXPIRED_IN_SCOPE="COMMERCIAL_EXPIRED_IN_SCOPE",e.COMMERCIAL_EXPIRED_OUT_OF_SCOPE="COMMERCIAL_EXPIRED_OUT_OF_SCOPE"}(p||(exports.LicenseValidityType=p={}));const h=()=>"undefined"!=typeof window?window.location.origin:"",E=()=>{const e=h(),[a,t,s]=Array.from(/(https):\/\/\d+\-\d+\-\d+\-(sandpack\.codesandbox\.io)/g.exec(e)||[]);return"https"===t&&"sandpack.codesandbox.io"===s},_=()=>{const e=h(),[a,t,s]=Array.from(/(https):\/\/\S+(\.csb\.app)/g.exec(e)||[]);return"https"===t&&".csb.app"===s},I=()=>{const e=h(),[a,t,s]=Array.from(/(https):\/\/\S+(\.adaptabletools\.com)/g.exec(e)||[]);return"https"===t&&".adaptabletools.com"===s};class O{adaptable;licenseKey;packageDetails;constructor(e,a,t){this.adaptable=e,this.licenseKey=a,this.packageDetails=t,this.adaptable=e,this.adaptable.api.eventApi.on("AdaptableReady",()=>{requestAnimationFrame(()=>{this.adaptable.isDestroyed||this.init()})})}init(){let e=null;if(this.licenseKey)try{e=(0,n.decode)(this.licenseKey)}catch(a){e=a}E()||_()||I()||this.handleLicenseValidation(e,this.getValidityType(e,this.packageDetails))}getValidityType(e,a){if(!e)return p.NO_LICENSE;if(e instanceof Error)return p.INVALID_LICENSE;const t=new Date(a.publishedAt),s=new Date(e.end),i=s<new Date,o=e.trial;let n=null;return n=i?s>t?o?p.NON_PRODUCTION_EXPIRED_IN_SCOPE:p.COMMERCIAL_EXPIRED_IN_SCOPE:o?p.NON_PRODUCTION_EXPIRED_OUT_OF_SCOPE:p.COMMERCIAL_EXPIRED_OUT_OF_SCOPE:o?p.NON_PRODUCTION_VALID:p.COMMERCIAL_VALID,n}handleLicenseValidation(e,a){const t=new Date;t.setHours(0,0,0,0);let s=0;e instanceof Error||!e?.end||(s=Math.floor((e?.end?.getTime()-t.getTime())/d),s=(0,i.default)(s,0,1/0));let p="",h="";!e||e instanceof Error||!e.appName||e.appName==n.GENERIC_APP_NAME||(p=e.appName,h=" for application [APP_NAME]");const E=(e,a=o.LicenseDocsLink,t=l,i=s,n=p)=>e.replace("[LINK]",a).replace("[EMAIL]",t).replace("[APP_NAME]",n).replace("[DAYS]",`${i}`);switch(a){case"NO_LICENSE":case"NON_PRODUCTION_EXPIRED_OUT_OF_SCOPE":this.adaptable.logger.consoleLogByMessageType(E("This instance of AdapTable does not have a license, and some functionality has therefore been removed. In order to use a fully-featured version of AdapTable, please contact [EMAIL]. You can learn more about the different AdapTable license options at [LINK]."),"Error"),this.showNotification("No AdapTable License found."),this.showWatermark("This instance of AdapTable does not have a license, and some functionality has therefore been removed."),this.disableStatePersistence();break;case"INVALID_LICENSE":this.adaptable.logger.consoleLogByMessageType(E("This instance of AdapTable seems to use a corrupted License, and some functionality has therefore been removed. In order to use a fully-featured version of AdapTable, please contact [EMAIL]. You can learn more about the different AdapTable license options at [LINK]."),"Error"),this.showNotification("Corrupted AdapTable License found."),this.showWatermark("This instance of AdapTable has a corrupted License, and some functionality has therefore been removed."),this.disableStatePersistence();break;case"NON_PRODUCTION_VALID":this.adaptable.logger.consoleLogByMessageType(E("This AdapTable trial license expires in [DAYS] days. Please contact [EMAIL] to upgrade to a commercial version of AdapTable. You can learn more about the different AdapTable license options at [LINK]."),"Info");break;case"NON_PRODUCTION_EXPIRED_IN_SCOPE":this.adaptable.logger.consoleLogByMessageType(E("This AdapTable trial license has now expired. Please contact [EMAIL] to upgrade to a commercial version of AdapTable. You can learn more about the different AdapTable license options at [LINK]."),"Warning"),this.showWatermark("AdapTable License has expired");break;case"COMMERCIAL_VALID":if(s<=c)this.adaptable.logger.consoleLogByMessageType(E(`This AdapTable license${h} expires in [DAYS] days. Please contact [EMAIL] to renew (giving you access to Support and Updates)`),"Info");else try{(0,r.shouldLogThankYouMessage)()&&this.adaptable.logger.consoleLogByMessageType(E(`Thank you for using a valid AdapTable license${h}. Your license will expire in [DAYS] days.`),"Info")}catch(e){}break;case"COMMERCIAL_EXPIRED_IN_SCOPE":this.adaptable.logger.consoleLogByMessageType(E(`This AdapTable license${h} has expired. Please contact [EMAIL] if you wish to renew (giving you access to Support and Updates)`),"Warning");break;case"COMMERCIAL_EXPIRED_OUT_OF_SCOPE":this.adaptable.logger.consoleLogByMessageType(E(`This AdapTable license${h} has expired. Adaptable version was published after the license expired. Please contact [EMAIL] if you wish to renew your license.`),"Error"),this.showNotification("Adaptable License has expired"),this.showWatermark("Adaptable License has expired")}}showNotification(e){this.adaptable.api.internalApi.dispatchReduxAction((0,t.PopupShowAlert)({alertType:"generic",header:"License Error",message:e,alertDefinition:s.default.CreateInternalAlertDefinitionForMessages("Error")}))}showWatermark(e){this.adaptable.api.internalApi.dispatchReduxAction((0,a.LicenseShowWatermark)(e))}disableStatePersistence(){this.adaptable.api.internalApi.dispatchReduxAction((0,a.LicenseDisablePersistence)())}destroy(){}}exports.LicenseService=O;
|
|
@@ -9,9 +9,9 @@ const AdaptableLogger_1 = require("../../agGrid/AdaptableLogger");
|
|
|
9
9
|
const DefaultAdaptableOptions_1 = require("../../AdaptableOptions/DefaultAdaptableOptions");
|
|
10
10
|
const supportedMetamodelTypes = ['s', 'n', 'b', 'a', 'f', 'R'];
|
|
11
11
|
class MetamodelService {
|
|
12
|
+
gridInfoOptions = new Map();
|
|
13
|
+
getAdaptableOptions = () => null;
|
|
12
14
|
constructor(getAdaptableOptions, validateOptions) {
|
|
13
|
-
this.gridInfoOptions = new Map();
|
|
14
|
-
this.getAdaptableOptions = () => null;
|
|
15
15
|
this.getAdaptableOptions = getAdaptableOptions;
|
|
16
16
|
this.gridInfoOptions = this.buildGridInfoOptions();
|
|
17
17
|
if (validateOptions) {
|
|
@@ -5,6 +5,7 @@ const tslib_1 = require("tslib");
|
|
|
5
5
|
const Helper_1 = tslib_1.__importDefault(require("../Helpers/Helper"));
|
|
6
6
|
const DocumentationLinkConstants_1 = require("../Constants/DocumentationLinkConstants");
|
|
7
7
|
class ModuleService {
|
|
8
|
+
adaptableApi;
|
|
8
9
|
constructor(adaptableApi) {
|
|
9
10
|
this.adaptableApi = adaptableApi;
|
|
10
11
|
this.adaptableApi = adaptableApi;
|
|
@@ -35,9 +36,7 @@ class ModuleService {
|
|
|
35
36
|
const registeredAgGridModuleNames = agGridModulesAdapter.getAgGridRegisteredModuleNames();
|
|
36
37
|
const missingAgGridModuleNames = mandatoryAgGridModuleNames.filter((moduleName) => !registeredAgGridModuleNames.includes(moduleName));
|
|
37
38
|
if (missingAgGridModuleNames.length) {
|
|
38
|
-
this.adaptableApi.consoleError(`
|
|
39
|
-
|
|
40
|
-
See for more information: ${DocumentationLinkConstants_1.AgGridRequiredModulesDocsLink}`);
|
|
39
|
+
this.adaptableApi.consoleError(`Adaptable requires these AG Grid modules: ${missingAgGridModuleNames.join(', ')}. Please register them. See: ${DocumentationLinkConstants_1.AgGridRequiredModulesDocsLink}`);
|
|
41
40
|
}
|
|
42
41
|
// log optional missing AG Grid dependencies for all modules
|
|
43
42
|
this.getModuleCollection().forEach((adaptableModule) => {
|
|
@@ -117,13 +116,13 @@ class ModuleService {
|
|
|
117
116
|
case 'CalculatedColumn':
|
|
118
117
|
return url + 'handbook-calculated-column';
|
|
119
118
|
case 'CellSummary':
|
|
120
|
-
return url + 'handbook-summarising';
|
|
119
|
+
return url + 'handbook-summarising-cells';
|
|
121
120
|
case 'Charting':
|
|
122
121
|
return url + 'handbook-charts';
|
|
123
122
|
case 'ColumnFilter':
|
|
124
123
|
return url + 'handbook-column-filter';
|
|
125
124
|
case 'ColumnInfo':
|
|
126
|
-
return url + 'dev-guide-
|
|
125
|
+
return url + 'dev-guide-columns-column-info';
|
|
127
126
|
case 'Comment':
|
|
128
127
|
return url + 'handbook-comments';
|
|
129
128
|
case 'CustomSort':
|
|
@@ -149,7 +148,7 @@ class ModuleService {
|
|
|
149
148
|
case 'GridFilter':
|
|
150
149
|
return url + 'handbook-grid-filter';
|
|
151
150
|
case 'GridInfo':
|
|
152
|
-
return url + 'dev-guide-
|
|
151
|
+
return url + 'dev-guide-support-monitoring';
|
|
153
152
|
case 'Layout':
|
|
154
153
|
return url + 'handbook-layouts';
|
|
155
154
|
case 'NamedQuery':
|
|
@@ -13,13 +13,14 @@ const scalarExpressionFunctions_1 = require("../ExpressionFunctions/scalarExpres
|
|
|
13
13
|
const TypeExtensions_1 = require("../Extensions/TypeExtensions");
|
|
14
14
|
const AggregatedScalarLiveValue_1 = require("./AggregatedScalarLiveValue");
|
|
15
15
|
class QueryLanguageService {
|
|
16
|
+
adaptableApi;
|
|
17
|
+
cacheBooleanValidation = new Map();
|
|
18
|
+
cacheObservableValidation = new Map();
|
|
19
|
+
cacheAggregatedBooleanValidation = new Map();
|
|
20
|
+
cacheAggregatedScalarValidation = new Map();
|
|
21
|
+
cacheModuleSpecificExpressionFunctions = new Map();
|
|
16
22
|
constructor(adaptableApi) {
|
|
17
23
|
this.adaptableApi = adaptableApi;
|
|
18
|
-
this.cacheBooleanValidation = new Map();
|
|
19
|
-
this.cacheObservableValidation = new Map();
|
|
20
|
-
this.cacheAggregatedBooleanValidation = new Map();
|
|
21
|
-
this.cacheAggregatedScalarValidation = new Map();
|
|
22
|
-
this.cacheModuleSpecificExpressionFunctions = new Map();
|
|
23
24
|
}
|
|
24
25
|
evaluateBooleanExpression(expression, module, rowNode, evalContext) {
|
|
25
26
|
if (expression == undefined) {
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.RowFormService = void 0;
|
|
4
4
|
class RowFormService {
|
|
5
|
+
adaptableApi;
|
|
5
6
|
constructor(adaptableApi) {
|
|
6
7
|
this.adaptableApi = adaptableApi;
|
|
7
8
|
if (adaptableApi.optionsApi.getRowFormOptions().autoHandle) {
|
|
@@ -14,15 +14,12 @@ const isEqual_1 = tslib_1.__importDefault(require("lodash/isEqual"));
|
|
|
14
14
|
* The logic is extracted here to make it easier to follow
|
|
15
15
|
*/
|
|
16
16
|
class RowSummaryService {
|
|
17
|
+
api;
|
|
18
|
+
cachedCellSummary = new Map();
|
|
19
|
+
previousRowSummaries;
|
|
20
|
+
previousLayout;
|
|
17
21
|
constructor(api) {
|
|
18
22
|
this.api = api;
|
|
19
|
-
this.cachedCellSummary = new Map();
|
|
20
|
-
this._throttleAcumulatedColumnsThatChanged = new Set();
|
|
21
|
-
/**
|
|
22
|
-
*
|
|
23
|
-
* @param colId optional to evaluate only one column
|
|
24
|
-
*/
|
|
25
|
-
this._throttledEvaluateRowSummary = (0, throttle_1.default)(this.evaluateRowSummary, 300);
|
|
26
23
|
}
|
|
27
24
|
onAdaptableReady() {
|
|
28
25
|
this.rowSummariesSubscriptions();
|
|
@@ -70,12 +67,18 @@ class RowSummaryService {
|
|
|
70
67
|
this.throttledEvaluateRowSummary();
|
|
71
68
|
});
|
|
72
69
|
}
|
|
70
|
+
_throttleAcumulatedColumnsThatChanged = new Set();
|
|
73
71
|
throttledEvaluateRowSummary(reason) {
|
|
74
72
|
if (reason) {
|
|
75
73
|
reason.columnIds.forEach((col) => this._throttleAcumulatedColumnsThatChanged.add(col));
|
|
76
74
|
}
|
|
77
75
|
this._throttledEvaluateRowSummary(reason);
|
|
78
76
|
}
|
|
77
|
+
/**
|
|
78
|
+
*
|
|
79
|
+
* @param colId optional to evaluate only one column
|
|
80
|
+
*/
|
|
81
|
+
_throttledEvaluateRowSummary = (0, throttle_1.default)(this.evaluateRowSummary, 300);
|
|
79
82
|
evaluateRowSummary(reason) {
|
|
80
83
|
if (this._throttleAcumulatedColumnsThatChanged.size > 0) {
|
|
81
84
|
const columnIds = Array.from(this._throttleAcumulatedColumnsThatChanged.values());
|
|
@@ -5,9 +5,11 @@ const tslib_1 = require("tslib");
|
|
|
5
5
|
const Uuid_1 = require("../../AdaptableState/Uuid");
|
|
6
6
|
const ObjectFactory_1 = tslib_1.__importDefault(require("../ObjectFactory"));
|
|
7
7
|
class TeamSharingService {
|
|
8
|
+
adaptableApi;
|
|
9
|
+
dismissedNotifications = [];
|
|
10
|
+
updateCheckTimerId;
|
|
8
11
|
constructor(adaptableApi) {
|
|
9
12
|
this.adaptableApi = adaptableApi;
|
|
10
|
-
this.dismissedNotifications = [];
|
|
11
13
|
const teamSharingOptions = adaptableApi.optionsApi.getTeamSharingOptions();
|
|
12
14
|
if (teamSharingOptions.updateInterval > 0) {
|
|
13
15
|
// convert minutes to millis
|
|
@@ -2,16 +2,10 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ThemeService = void 0;
|
|
4
4
|
class ThemeService {
|
|
5
|
+
api;
|
|
6
|
+
unsubscribe = () => { };
|
|
7
|
+
styleSheetObject;
|
|
5
8
|
constructor(api) {
|
|
6
|
-
this.unsubscribe = () => { };
|
|
7
|
-
this.onThemeChanged = () => {
|
|
8
|
-
let currentTheme = this.api.themeApi.getCurrentThemeObject();
|
|
9
|
-
currentTheme = this.mapOsTheme(currentTheme);
|
|
10
|
-
this.applyNewThemeVariables(currentTheme);
|
|
11
|
-
// this needs to be called after variables are set
|
|
12
|
-
// as it may show the warning for a custom/runtime theme
|
|
13
|
-
this.showMissingThemeFiles(currentTheme);
|
|
14
|
-
};
|
|
15
9
|
this.api = api;
|
|
16
10
|
this.subscribe();
|
|
17
11
|
if (!this.styleSheetObject) {
|
|
@@ -36,6 +30,14 @@ class ThemeService {
|
|
|
36
30
|
prefferedColorSchemeUnsubscribe();
|
|
37
31
|
};
|
|
38
32
|
}
|
|
33
|
+
onThemeChanged = () => {
|
|
34
|
+
let currentTheme = this.api.themeApi.getCurrentThemeObject();
|
|
35
|
+
currentTheme = this.mapOsTheme(currentTheme);
|
|
36
|
+
this.applyNewThemeVariables(currentTheme);
|
|
37
|
+
// this needs to be called after variables are set
|
|
38
|
+
// as it may show the warning for a custom/runtime theme
|
|
39
|
+
this.showMissingThemeFiles(currentTheme);
|
|
40
|
+
};
|
|
39
41
|
applyNewThemeVariables(theme) {
|
|
40
42
|
const variables = theme.CSSVariables;
|
|
41
43
|
if (!variables || Object.keys(variables).length === 0) {
|
|
@@ -71,15 +73,11 @@ class ThemeService {
|
|
|
71
73
|
return val;
|
|
72
74
|
});
|
|
73
75
|
if (abLoaded !== '777') {
|
|
74
|
-
logger.consoleError('
|
|
76
|
+
logger.consoleError('Adaptable styles not detected. Please import "@adaptabletools/adaptable/index.css".');
|
|
75
77
|
}
|
|
76
78
|
const isCustomUserTheme = !this.api.themeApi.internalApi.isSystemTheme(themeName);
|
|
77
79
|
if (!isCustomUserTheme && abThemeLoaded !== themeName) {
|
|
78
|
-
logger.consoleWarn(`Theme "${themeName}"
|
|
79
|
-
|
|
80
|
-
If it's an AdapTable system theme, try
|
|
81
|
-
|
|
82
|
-
import "@adaptabletools/adaptable/themes/${themeName}.css"`);
|
|
80
|
+
logger.consoleWarn(`Theme "${themeName}" does not appear to be loaded. Ensure the CSS file is imported, e.g.: import "@adaptabletools/adaptable/themes/${themeName}.css".`);
|
|
83
81
|
}
|
|
84
82
|
}
|
|
85
83
|
// prefers-color-scheme
|
|
@@ -8,6 +8,7 @@ const ModuleConstants_1 = require("../Constants/ModuleConstants");
|
|
|
8
8
|
const GeneralConstants_1 = require("../Constants/GeneralConstants");
|
|
9
9
|
const AdaptableLogger_1 = require("../../agGrid/AdaptableLogger");
|
|
10
10
|
class ValidationService {
|
|
11
|
+
adaptableApi;
|
|
11
12
|
constructor(adaptableApi) {
|
|
12
13
|
this.adaptableApi = adaptableApi;
|
|
13
14
|
this.adaptableApi = adaptableApi;
|
|
@@ -56,7 +57,7 @@ class ValidationService {
|
|
|
56
57
|
let alert = {
|
|
57
58
|
alertType: 'cellChanged',
|
|
58
59
|
header: 'Alert',
|
|
59
|
-
message: '
|
|
60
|
+
message: 'A validation rule was triggered for this edit.',
|
|
60
61
|
alertDefinition: failedRules[0],
|
|
61
62
|
cellDataChangedInfo: cellDataChangedInfo,
|
|
62
63
|
};
|
|
@@ -14,16 +14,15 @@ const doOnce = (func, key) => {
|
|
|
14
14
|
};
|
|
15
15
|
const logDeprecation = (logger, typeName, oldProp, newProp, message) => {
|
|
16
16
|
const newPropMsg = newProp ? `Please use '${typeName}.${newProp}()' instead. ` : '';
|
|
17
|
-
doOnce(() => logger.consoleWarn(
|
|
17
|
+
doOnce(() => logger.consoleWarn(`${typeName}.${oldProp}() is deprecated. ${newPropMsg}${message ?? ''}`), `Deprecated_${oldProp}`);
|
|
18
18
|
};
|
|
19
19
|
exports.logDeprecation = logDeprecation;
|
|
20
20
|
const logDeprecationExternal = (logger, oldTypeName, oldProp, newTypeName, newProp, message) => {
|
|
21
21
|
const newPropMsg = newProp ? `Please use '${newTypeName}.${newProp}()' instead. ` : '';
|
|
22
|
-
doOnce(() => logger.consoleWarn(
|
|
22
|
+
doOnce(() => logger.consoleWarn(`${oldTypeName}.${oldProp}() is deprecated. ${newPropMsg}${message ?? ''}`), `Deprecated_${oldProp}`);
|
|
23
23
|
};
|
|
24
24
|
exports.logDeprecationExternal = logDeprecationExternal;
|
|
25
25
|
const logDeprecationInternal = (logger, typeName, oldProp) => {
|
|
26
|
-
doOnce(() => logger.consoleWarn(
|
|
27
|
-
Please contact support if you need the missing functionality.`), `Deprecated_${oldProp}`);
|
|
26
|
+
doOnce(() => logger.consoleWarn(`${typeName}.${oldProp}() is deprecated and will be removed in the next major release. Contact support if you need this functionality.`), `Deprecated_${oldProp}`);
|
|
28
27
|
};
|
|
29
28
|
exports.logDeprecationInternal = logDeprecationInternal;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { AdaptableContainerValue, ContainerContext, InitContainerContext } from '../AdaptableOptions/ContainerOptions';
|
|
2
|
+
/**
|
|
3
|
+
* The union type representing any container option value (static or function).
|
|
4
|
+
*/
|
|
5
|
+
type AnyContainerOption = AdaptableContainerValue | ((context: any) => AdaptableContainerValue);
|
|
6
|
+
/**
|
|
7
|
+
* Resolves a container option value to an `HTMLElement`.
|
|
8
|
+
*
|
|
9
|
+
* Resolution order:
|
|
10
|
+
* 1. If `container` is `null`/`undefined`, returns `null`.
|
|
11
|
+
* 2. If `container` is a function, it is called with the provided `context` and the result is resolved.
|
|
12
|
+
* 3. If the value is an `HTMLElement`, it is returned directly.
|
|
13
|
+
* 4. If the value is an `AdaptableCSSSelector` (`{ selector: string }`), `document.querySelectorAll` is used.
|
|
14
|
+
* If multiple elements match, the first is returned and a console warning is logged.
|
|
15
|
+
* 5. If the value is a `string`, it is treated as an element ID and `document.getElementById` is used.
|
|
16
|
+
*
|
|
17
|
+
* @param container - The container reference to resolve.
|
|
18
|
+
* @param context - Optional context passed to the function form of the container.
|
|
19
|
+
* @param doc - The document to query against (defaults to `globalThis.document`).
|
|
20
|
+
* @returns The resolved `HTMLElement`, or `null` if not found.
|
|
21
|
+
*/
|
|
22
|
+
export declare function resolveContainerElement(container: AnyContainerOption | undefined | null, context?: ContainerContext | InitContainerContext, doc?: Document): HTMLElement | null;
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.resolveContainerElement = resolveContainerElement;
|
|
4
|
+
/**
|
|
5
|
+
* Resolves a container option value to an `HTMLElement`.
|
|
6
|
+
*
|
|
7
|
+
* Resolution order:
|
|
8
|
+
* 1. If `container` is `null`/`undefined`, returns `null`.
|
|
9
|
+
* 2. If `container` is a function, it is called with the provided `context` and the result is resolved.
|
|
10
|
+
* 3. If the value is an `HTMLElement`, it is returned directly.
|
|
11
|
+
* 4. If the value is an `AdaptableCSSSelector` (`{ selector: string }`), `document.querySelectorAll` is used.
|
|
12
|
+
* If multiple elements match, the first is returned and a console warning is logged.
|
|
13
|
+
* 5. If the value is a `string`, it is treated as an element ID and `document.getElementById` is used.
|
|
14
|
+
*
|
|
15
|
+
* @param container - The container reference to resolve.
|
|
16
|
+
* @param context - Optional context passed to the function form of the container.
|
|
17
|
+
* @param doc - The document to query against (defaults to `globalThis.document`).
|
|
18
|
+
* @returns The resolved `HTMLElement`, or `null` if not found.
|
|
19
|
+
*/
|
|
20
|
+
function resolveContainerElement(container, context, doc = globalThis.document) {
|
|
21
|
+
if (container == null) {
|
|
22
|
+
return null;
|
|
23
|
+
}
|
|
24
|
+
// Unwrap function form — pass context if the container is a function
|
|
25
|
+
const value = typeof container === 'function' ? container(context) : container;
|
|
26
|
+
// Guard against null/undefined returned by a callback (e.g. document.getElementById(...))
|
|
27
|
+
if (value == null) {
|
|
28
|
+
return null;
|
|
29
|
+
}
|
|
30
|
+
// Direct HTMLElement reference
|
|
31
|
+
if (value instanceof HTMLElement) {
|
|
32
|
+
return value;
|
|
33
|
+
}
|
|
34
|
+
// CSS Selector object
|
|
35
|
+
if (typeof value === 'object' && 'selector' in value) {
|
|
36
|
+
const matches = doc.querySelectorAll(value.selector);
|
|
37
|
+
if (matches.length > 1) {
|
|
38
|
+
console.warn(`[AdapTable] CSS selector "${value.selector}" matched ${matches.length} elements. Using the first match. Consider using a more specific selector.`);
|
|
39
|
+
}
|
|
40
|
+
return matches[0] ?? null;
|
|
41
|
+
}
|
|
42
|
+
// String element ID
|
|
43
|
+
if (typeof value === 'string') {
|
|
44
|
+
return doc.getElementById(value);
|
|
45
|
+
}
|
|
46
|
+
return null;
|
|
47
|
+
}
|
|
@@ -17,6 +17,7 @@ export interface AdaptablePopoverProps extends React.ClassAttributes<React.Props
|
|
|
17
17
|
popupPadding?: 0 | 2;
|
|
18
18
|
alignPosition?: OverlayShowParams['alignPosition'];
|
|
19
19
|
visible?: boolean;
|
|
20
|
+
disabled?: boolean;
|
|
20
21
|
}
|
|
21
22
|
export declare class AdaptablePopover extends React.Component<React.PropsWithChildren<AdaptablePopoverProps>, {}> {
|
|
22
23
|
render(): React.JSX.Element;
|
|
@@ -39,7 +39,7 @@ class AdaptablePopover extends React.Component {
|
|
|
39
39
|
// showTriangle
|
|
40
40
|
visible: this.props.visible, render: () => popoverClickRootClose, showEvent: (this.props.showEvent || 'mouseenter'), hideEvent: (this.props.hideEvent || 'mouseleave'), style: {
|
|
41
41
|
overflow: 'visible',
|
|
42
|
-
}, alignPosition: this.props.alignPosition }, useButton ? (React.createElement(ButtonInfo_1.ButtonInfo, { style: iconStyle, variant: "text", onClick: () => null, icon: showIcon && icon, tooltip: this.props.tooltipText }, this.props.children)) : (React.createElement("div", { title: this.props.tooltipText, tabIndex: 0, style: { cursor: 'pointer', display: 'inline-block' } },
|
|
42
|
+
}, alignPosition: this.props.alignPosition }, useButton ? (React.createElement(ButtonInfo_1.ButtonInfo, { style: iconStyle, variant: "text", onClick: () => null, icon: showIcon && icon, tooltip: this.props.tooltipText, disabled: this.props.disabled }, this.props.children)) : (React.createElement("div", { title: this.props.tooltipText, tabIndex: 0, style: { cursor: 'pointer', display: 'inline-block' } },
|
|
43
43
|
this.props.children,
|
|
44
44
|
showIcon && React.createElement(icons_1.Icon, { name: icon, style: iconStyle }))))));
|
|
45
45
|
}
|
|
@@ -11,6 +11,14 @@ const ActiveAlertsPanel = () => {
|
|
|
11
11
|
const adaptable = (0, AdaptableContext_1.useAdaptable)();
|
|
12
12
|
const filterModule = adaptable.ModuleService.getModuleById(ModuleConstants.AlertModuleId);
|
|
13
13
|
const alerts = (0, react_redux_1.useSelector)((state) => state.Internal.AdaptableAlerts);
|
|
14
|
+
// map the suspended property from the underlying AlertDefinitions
|
|
15
|
+
alerts.forEach((alert) => {
|
|
16
|
+
const liveAlertDef = adaptable.api.alertApi.getAlertDefinitionById(alert.alertDefinition.Uuid);
|
|
17
|
+
if (liveAlertDef) {
|
|
18
|
+
// @ts-ignore theoretically AdaptableAlert is not Suspendable; practically <AdaptableObjectCompactList> expects it
|
|
19
|
+
alert.IsSuspended = liveAlertDef.IsSuspended;
|
|
20
|
+
}
|
|
21
|
+
});
|
|
14
22
|
return React.createElement(AdaptableObjectCompactList_1.AdaptableObjectCompactList, { abObjects: alerts, module: filterModule });
|
|
15
23
|
};
|
|
16
24
|
exports.ActiveAlertsPanel = ActiveAlertsPanel;
|
|
@@ -6,10 +6,11 @@ const React = tslib_1.__importStar(require("react"));
|
|
|
6
6
|
const react_redux_1 = require("react-redux");
|
|
7
7
|
const InternalRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/InternalRedux"));
|
|
8
8
|
const AdaptablePopover_1 = require("../AdaptablePopover");
|
|
9
|
-
const UIHelper_1 = tslib_1.__importDefault(require("../UIHelper"));
|
|
10
9
|
const getAlertButtonStyle_1 = require("./Utilities/getAlertButtonStyle");
|
|
11
10
|
const ActiveAlertsPanel_1 = require("./ActiveAlertsPanel");
|
|
12
11
|
const Flex_1 = require("../../components/Flex");
|
|
12
|
+
const ButtonClear_1 = require("../Components/Buttons/ButtonClear");
|
|
13
|
+
const clsx_1 = tslib_1.__importDefault(require("clsx"));
|
|
13
14
|
class AlertViewPanelComponent extends React.Component {
|
|
14
15
|
constructor(props) {
|
|
15
16
|
super(props);
|
|
@@ -24,7 +25,6 @@ class AlertViewPanelComponent extends React.Component {
|
|
|
24
25
|
}
|
|
25
26
|
}
|
|
26
27
|
render() {
|
|
27
|
-
const messageType = UIHelper_1.default.getMessageTypeFromAdaptableAlerts(this.props.AdaptableAlerts);
|
|
28
28
|
const { color: buttonTextColor, background: buttonBackground } = (0, getAlertButtonStyle_1.getAlertButtonStyle)(this.props.AdaptableAlerts);
|
|
29
29
|
const collapsedText = this.props.AdaptableAlerts.length == 0
|
|
30
30
|
? '0 Alerts'
|
|
@@ -32,13 +32,17 @@ class AlertViewPanelComponent extends React.Component {
|
|
|
32
32
|
? '1 Alert'
|
|
33
33
|
: this.props.AdaptableAlerts.length + ' Alerts';
|
|
34
34
|
const alertsPanel = React.createElement(ActiveAlertsPanel_1.ActiveAlertsPanel, null);
|
|
35
|
-
const
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
35
|
+
const isToolbar = this.props.viewType === 'Toolbar';
|
|
36
|
+
const elementType = isToolbar ? 'DashboardToolbar' : 'ToolPanel';
|
|
37
|
+
return (React.createElement(Flex_1.Flex, { alignItems: "stretch", className: (0, clsx_1.default)(`ab-${elementType}__Alert__wrap twa:gap-1`, {
|
|
38
|
+
'twa:min-w-[140px] twa:w-[140px]': isToolbar,
|
|
39
|
+
[`twa:flex-1`]: !isToolbar,
|
|
40
|
+
}) },
|
|
41
|
+
React.createElement(Flex_1.Flex, { key: `${buttonTextColor}_${buttonBackground}_${collapsedText}`, className: `ab-${elementType}__Alert__text twa:flex-1 twa:rounded-standard twa:p-2 text-2 twa:items-center twa:justify-center twa:min-h-input`, style: { color: buttonTextColor, backgroundColor: buttonBackground } }, collapsedText),
|
|
42
|
+
this.props.AdaptableAlerts.length > 0 && (React.createElement(Flex_1.Flex, { className: 'twa:gap-1' },
|
|
43
|
+
React.createElement(Flex_1.Flex, { className: "twa:flex twa:box-border" },
|
|
44
|
+
React.createElement(ButtonClear_1.ButtonClear, { "aria-label": 'Clear All Alerts', variant: 'outlined', className: `ab-${elementType}__Alert__clear`, onClick: () => this.props.onDeleteAllAlert(this.state.Alerts), tooltip: "Clear All Alerts", showText: this.props.viewType === 'ToolPanel' }, 'Clear Alerts')),
|
|
45
|
+
React.createElement(AdaptablePopover_1.AdaptablePopover, { className: `ab-${elementType}__Alert__info`, headerText: "Alerts Details", bodyText: [alertsPanel], MessageType: 'Info', useButton: true, showEvent: 'focus', hideEvent: "blur", popoverMinWidth: 400 })))));
|
|
42
46
|
}
|
|
43
47
|
}
|
|
44
48
|
function mapStateToProps(state, ownProps) {
|
|
@@ -8,9 +8,17 @@ const getAlertButtonStyle = (alerts) => {
|
|
|
8
8
|
const messageTypeColor = UIHelper_1.default.getColorByMessageType(messageType);
|
|
9
9
|
const buttonBackground = UIHelper_1.default.getButtonColourForAdaptableAlerts(alerts, messageTypeColor);
|
|
10
10
|
const buttonTextColor = UIHelper_1.default.getButtonTextColourForArrayandMessageType(alerts, messageType);
|
|
11
|
+
let cssClasses = '';
|
|
12
|
+
if (alerts?.length) {
|
|
13
|
+
const cssMessageType = UIHelper_1.default.getCSSColorByMessageType(messageType);
|
|
14
|
+
cssClasses = cssMessageType
|
|
15
|
+
? `twa:bg-${cssMessageType} twa:text-text-on-${cssMessageType}`
|
|
16
|
+
: '';
|
|
17
|
+
}
|
|
11
18
|
return {
|
|
12
19
|
color: buttonTextColor,
|
|
13
20
|
background: buttonBackground,
|
|
21
|
+
cssClasses,
|
|
14
22
|
};
|
|
15
23
|
};
|
|
16
24
|
exports.getAlertButtonStyle = getAlertButtonStyle;
|
|
@@ -6,6 +6,7 @@ import { AlertType } from './getAlertType';
|
|
|
6
6
|
*/
|
|
7
7
|
export declare const getDefaultAlertDefinition: (alertDefinition: AlertDefinition, type: AlertType) => {
|
|
8
8
|
Uuid: string;
|
|
9
|
+
Name: string;
|
|
9
10
|
Scope: import("../../../types").ColumnScope;
|
|
10
11
|
Rule: import("../../../types").AlertRule;
|
|
11
12
|
MessageType: import("../../../types").AdaptableMessageType;
|
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { AlertType } from '../Utilities/getAlertType';
|
|
3
|
+
import { AdaptableApi, AlertDefinition } from '../../../types';
|
|
4
|
+
export declare const isSettingsValid: (data: AlertDefinition, api: AdaptableApi) => true | "Name is required" | "An Alert already exists with that name";
|
|
3
5
|
export declare const renderAlertTypeSummary: (alertType: AlertType) => React.JSX.Element;
|
|
4
|
-
type
|
|
6
|
+
type AlertTypeWizardSectionProps = {
|
|
5
7
|
onAlertTypeChange: (alertType: AlertType) => void;
|
|
6
8
|
alertType: AlertType | null;
|
|
9
|
+
onChange: (data: AlertDefinition) => void;
|
|
7
10
|
};
|
|
8
|
-
export declare const AlertTypeWizardSection: (props:
|
|
11
|
+
export declare const AlertTypeWizardSection: (props: AlertTypeWizardSectionProps) => React.JSX.Element;
|
|
9
12
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AlertTypeWizardSection = exports.renderAlertTypeSummary = void 0;
|
|
3
|
+
exports.AlertTypeWizardSection = exports.renderAlertTypeSummary = exports.isSettingsValid = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const React = tslib_1.__importStar(require("react"));
|
|
6
6
|
const Tabs_1 = require("../../../components/Tabs");
|
|
@@ -8,21 +8,57 @@ const getAlertType_1 = require("../Utilities/getAlertType");
|
|
|
8
8
|
const TypeRadio_1 = require("../../Wizard/TypeRadio");
|
|
9
9
|
const Tag_1 = require("../../../components/Tag");
|
|
10
10
|
const Flex_1 = require("../../../components/Flex");
|
|
11
|
+
const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
|
|
12
|
+
const FormLayout_1 = tslib_1.__importStar(require("../../../components/FormLayout"));
|
|
13
|
+
const Input_1 = tslib_1.__importDefault(require("../../../components/Input"));
|
|
14
|
+
const OnePageAdaptableWizard_2 = require("../../Wizard/OnePageAdaptableWizard");
|
|
15
|
+
const isSettingsValid = (data, api) => {
|
|
16
|
+
if (!data.Name?.trim()) {
|
|
17
|
+
return 'Name is required';
|
|
18
|
+
}
|
|
19
|
+
const allAlerts = api.alertApi.getAlertDefinitions();
|
|
20
|
+
const isDuplicateName = allAlerts.some((a) => a.Name === data.Name && a.Uuid !== data.Uuid);
|
|
21
|
+
if (isDuplicateName) {
|
|
22
|
+
return 'An Alert already exists with that name';
|
|
23
|
+
}
|
|
24
|
+
return true;
|
|
25
|
+
};
|
|
26
|
+
exports.isSettingsValid = isSettingsValid;
|
|
11
27
|
const renderAlertTypeSummary = (alertType) => {
|
|
28
|
+
const { data } = (0, OnePageAdaptableWizard_1.useOnePageAdaptableWizardContext)();
|
|
12
29
|
const text = (0, getAlertType_1.getAlertTypeText)(alertType);
|
|
13
|
-
return (React.createElement(
|
|
14
|
-
React.createElement(
|
|
30
|
+
return (React.createElement(React.Fragment, null,
|
|
31
|
+
React.createElement(OnePageAdaptableWizard_2.SummaryText, null,
|
|
32
|
+
"Name ",
|
|
33
|
+
React.createElement(Tag_1.Tag, null, data.Name || 'Not specified')),
|
|
34
|
+
React.createElement(OnePageAdaptableWizard_2.SummaryText, null,
|
|
35
|
+
"Type ",
|
|
36
|
+
React.createElement(Tag_1.Tag, null, text))));
|
|
15
37
|
};
|
|
16
38
|
exports.renderAlertTypeSummary = renderAlertTypeSummary;
|
|
17
39
|
const AlertTypeWizardSection = (props) => {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
40
|
+
const { data } = (0, OnePageAdaptableWizard_1.useOnePageAdaptableWizardContext)();
|
|
41
|
+
const handleNameChange = (event) => {
|
|
42
|
+
props.onChange({
|
|
43
|
+
...data,
|
|
44
|
+
Name: event.target.value,
|
|
45
|
+
});
|
|
46
|
+
};
|
|
47
|
+
return (React.createElement(Flex_1.Flex, { flexDirection: "column" },
|
|
48
|
+
React.createElement(Tabs_1.Tabs, null,
|
|
49
|
+
React.createElement(Tabs_1.Tabs.Tab, null, "Settings"),
|
|
50
|
+
React.createElement(Tabs_1.Tabs.Content, null,
|
|
51
|
+
React.createElement(FormLayout_1.default, null,
|
|
52
|
+
React.createElement(FormLayout_1.FormRow, { label: "Name" },
|
|
53
|
+
React.createElement(Input_1.default, { "data-name": "alert-name", className: "twa:flex-1 twa:max-w-[200px] twa:mr-3", onChange: handleNameChange, placeholder: "Enter Name", value: data.Name ?? '' }))))),
|
|
54
|
+
React.createElement(Tabs_1.Tabs, { className: "twa:mt-2" },
|
|
55
|
+
React.createElement(Tabs_1.Tabs.Tab, null, "Alert Type"),
|
|
56
|
+
React.createElement(Tabs_1.Tabs.Content, null,
|
|
57
|
+
React.createElement(Flex_1.Flex, { flexDirection: "column" },
|
|
58
|
+
React.createElement(TypeRadio_1.TypeRadio, { text: (0, getAlertType_1.getAlertTypeText)(getAlertType_1.AlertType.DataChange), description: "A change has been made to the Grid's underlying data", checked: props.alertType === getAlertType_1.AlertType.DataChange, onClick: () => props.onAlertTypeChange(getAlertType_1.AlertType.DataChange) }),
|
|
59
|
+
React.createElement(TypeRadio_1.TypeRadio, { text: (0, getAlertType_1.getAlertTypeText)(getAlertType_1.AlertType.RowChange), description: "A Row was added or removed from the data source", checked: props.alertType === getAlertType_1.AlertType.RowChange, onClick: () => props.onAlertTypeChange(getAlertType_1.AlertType.RowChange) }),
|
|
60
|
+
React.createElement(TypeRadio_1.TypeRadio, { text: (0, getAlertType_1.getAlertTypeText)(getAlertType_1.AlertType.Aggregation), description: "A change has been made to aggregated data (i.e. from multiple Rows)", onClick: () => props.onAlertTypeChange(getAlertType_1.AlertType.Aggregation), checked: props.alertType === getAlertType_1.AlertType.Aggregation }),
|
|
61
|
+
React.createElement(TypeRadio_1.TypeRadio, { text: (0, getAlertType_1.getAlertTypeText)(getAlertType_1.AlertType.Observable), description: "A specified change (or lack of change) over time has been observed in the Grid", onClick: () => props.onAlertTypeChange(getAlertType_1.AlertType.Observable), checked: props.alertType === getAlertType_1.AlertType.Observable }),
|
|
62
|
+
React.createElement(TypeRadio_1.TypeRadio, { text: (0, getAlertType_1.getAlertTypeText)(getAlertType_1.AlertType.Validation), description: "A change has broken a data validation rule", checked: props.alertType === getAlertType_1.AlertType.Validation, onClick: () => props.onAlertTypeChange(getAlertType_1.AlertType.Validation) }))))));
|
|
27
63
|
};
|
|
28
64
|
exports.AlertTypeWizardSection = AlertTypeWizardSection;
|