@adaptabletools/adaptable 21.2.2-canary.0 → 22.0.0-canary.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/icons/inspector.svg +1 -0
- package/index.css +6464 -5488
- package/index.css.map +1 -1
- package/package.json +5 -6
- package/src/AdaptableInterfaces/IAdaptable.d.ts +0 -1
- package/src/AdaptableState/ChartingState.d.ts +1 -1
- package/src/AdaptableState/Common/AdaptableAlert.d.ts +2 -2
- package/src/AdaptableState/Common/AdaptableIcon.d.ts +1 -1
- package/src/AdaptableState/Common/AdaptablePredicate.js +7 -3
- package/src/AdaptableState/Common/AggregationColumns.d.ts +3 -3
- package/src/AdaptableState/Common/DataUpdateConfig.d.ts +4 -4
- package/src/AdaptableState/TeamSharingState.d.ts +1 -1
- package/src/Api/CustomSortApi.d.ts +6 -1
- package/src/Api/Implementation/ColumnApiImpl.d.ts +3 -0
- package/src/Api/Implementation/ColumnApiImpl.js +12 -3
- package/src/Api/Implementation/CustomSortApiImpl.d.ts +2 -1
- package/src/Api/Implementation/CustomSortApiImpl.js +5 -1
- package/src/Api/Implementation/LayoutApiImpl.d.ts +1 -0
- package/src/Api/Implementation/LayoutApiImpl.js +85 -2
- package/src/Api/Implementation/LayoutHelpers.d.ts +2 -2
- package/src/Api/Implementation/ScheduleApiImpl.d.ts +1 -0
- package/src/Api/Implementation/ScheduleApiImpl.js +12 -0
- package/src/Api/Implementation/ShortcutApiImpl.d.ts +1 -0
- package/src/Api/Implementation/ShortcutApiImpl.js +4 -0
- package/src/Api/Implementation/StyledColumnApiImpl.d.ts +1 -0
- package/src/Api/Implementation/StyledColumnApiImpl.js +4 -0
- package/src/Api/Internal/AdaptableInternalApi.d.ts +0 -1
- package/src/Api/Internal/AdaptableInternalApi.js +3 -3
- package/src/Api/Internal/ColumnFilterInternalApi.js +1 -1
- package/src/Api/Internal/LayoutInternalApi.d.ts +5 -0
- package/src/Api/Internal/LayoutInternalApi.js +25 -0
- package/src/Api/LayoutApi.d.ts +7 -1
- package/src/Api/ScheduleApi.d.ts +5 -0
- package/src/Api/ShortcutApi.d.ts +5 -0
- package/src/Api/StyledColumnApi.d.ts +5 -0
- package/src/Redux/ActionsReducers/CommentsRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/DashboardRedux.d.ts +1 -1
- package/src/Redux/ActionsReducers/InternalRedux.d.ts +6 -6
- package/src/Redux/ActionsReducers/LayoutRedux.d.ts +3 -9
- package/src/Redux/ActionsReducers/StyledColumnRedux.d.ts +6 -6
- package/src/Redux/ActionsReducers/StyledColumnRedux.js +16 -16
- package/src/Redux/Store/AdaptableReduxLocalStorageEngine.js +3 -0
- package/src/Strategy/FormatColumnModule.js +2 -2
- package/src/Strategy/Utilities/Alert/getAlertPreviewViewItems.js +1 -1
- package/src/Strategy/Utilities/FormatColumn/getFormatColumnSettingsViewItems.js +2 -1
- package/src/Strategy/Utilities/Layout/getLayoutFilterViewItems.js +4 -3
- package/src/Utilities/ExpressionFunctions/expressionFunctionUtils.d.ts +4 -4
- package/src/Utilities/Extensions/StringExtensions.d.ts +1 -1
- package/src/Utilities/Helpers/StyleHelper.d.ts +1 -1
- package/src/Utilities/Services/Interface/IAlertService.d.ts +2 -2
- package/src/Utilities/createAgStatusPanelComponent.d.ts +1 -1
- package/src/Utilities/getObjectTagsViewItems.js +1 -1
- package/src/Utilities/runIfNotResolvedIn.d.ts +1 -1
- package/src/View/AdaptableComputedCSSVarsContext.js +6 -1
- package/src/View/AdaptablePopover/index.d.ts +1 -1
- package/src/View/AdaptablePopover/index.js +3 -3
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/AdaptableOptionsForm.js +7 -8
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ColumnsList.js +7 -6
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/Components/FormBox.d.ts +4 -2
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/Components/FormBox.js +3 -3
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/EntitlementsForm.js +9 -9
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/GridOptionsForm.js +3 -3
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/UIOptions/UIOptionsSidebarForm.js +4 -4
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/UIOptions/UIOptionsStatusbarForm.js +4 -4
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/UIOptions/UiOptionsForm.js +2 -2
- package/src/View/AdaptableWizardView/Wizard.js +1 -1
- package/src/View/AdaptableWizardView/index.js +1 -4
- package/src/View/Alert/ActiveAlertsPanelItemLabel.js +2 -2
- package/src/View/Alert/AlertStatusSubPanel.js +1 -1
- package/src/View/Alert/AlertViewPanel.js +2 -2
- package/src/View/Alert/Utilities/getDefaultAlertDefinition.d.ts +3 -20
- package/src/View/Alert/Wizard/AlertBehaviourWizardSection.js +15 -13
- package/src/View/Alert/Wizard/AlertButtonsEditor.js +25 -22
- package/src/View/Alert/Wizard/AlertMessageWizardSection.js +12 -16
- package/src/View/Alert/Wizard/AlertNotificationWizardSection.d.ts +3 -1
- package/src/View/Alert/Wizard/AlertNotificationWizardSection.js +7 -7
- package/src/View/Alert/Wizard/AlertRulesWizardSection.js +2 -2
- package/src/View/Alert/Wizard/AlertScopeWizardSection.js +2 -2
- package/src/View/Alert/Wizard/AlertTypeWizardSection.js +1 -1
- package/src/View/Alert/Wizard/AlertWizard.js +8 -8
- package/src/View/Alert/Wizard/BaseAlertScopeWizardSection.js +11 -8
- package/src/View/BulkUpdate/BulkUpdatePopup.js +11 -11
- package/src/View/BulkUpdate/BulkUpdateViewPanel.js +4 -4
- package/src/View/CalculatedColumn/CalculatedColumnSummary.d.ts +1 -1
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnDefinitionWizardSection.js +8 -8
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnExpressionWizardSection.d.ts +1 -1
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnExpressionWizardSection.js +4 -4
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnSettingsWizardSection.js +4 -5
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnTypeSection.d.ts +1 -1
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnTypeSection.js +1 -1
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnWizard.d.ts +0 -2
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnWizard.js +8 -14
- package/src/View/CalculatedColumn/Wizard/calculatedColumnTypes.d.ts +2 -0
- package/src/View/CalculatedColumn/Wizard/calculatedColumnTypes.js +6 -0
- package/src/View/CellSummary/CellSummaryPopup.js +1 -1
- package/src/View/CellSummary/CellSummaryViewPanel.js +5 -5
- package/src/View/Charting/ChartingStatusBarPopover.js +4 -4
- package/src/View/Charting/ChartingViewPanel.js +7 -7
- package/src/View/Charting/ChartingWizard/AgChargingWizard/AgChargingWizard.js +4 -4
- package/src/View/Charting/ChartingWizard/ExternalChartingWizard/ExternalChartingWizard.js +3 -3
- package/src/View/Charting/useChartingElements.d.ts +1 -1
- package/src/View/Charting/useChartingElements.js +1 -1
- package/src/View/ColumnInfo/ColumnInfo.js +14 -19
- package/src/View/ColumnInfo/ColumnInfoPopup.js +2 -2
- package/src/View/Comments/CommentsEditor.js +14 -17
- package/src/View/Comments/CommentsPopup.js +6 -6
- package/src/View/Components/AdaptableDateInput/index.js +1 -1
- package/src/View/Components/AdaptableInput/index.js +3 -2
- package/src/View/Components/AdaptableObjectCollection/index.d.ts +2 -2
- package/src/View/Components/AdaptableObjectCollection/index.js +9 -5
- package/src/View/Components/AdaptableObjectList/AdaptableObjectCompactList.js +10 -10
- package/src/View/Components/AdaptableObjectList/AdaptableObjectList.d.ts +2 -0
- package/src/View/Components/AdaptableObjectList/AdaptableObjectList.js +20 -18
- package/src/View/Components/AdaptableObjectRow/index.d.ts +1 -0
- package/src/View/Components/AdaptableObjectRow/index.js +4 -5
- package/src/View/Components/Buttons/ButtonBase/index.d.ts +1 -2
- package/src/View/Components/Buttons/ButtonBase/index.js +5 -4
- package/src/View/Components/Buttons/ButtonClear.js +2 -1
- package/src/View/Components/Buttons/ButtonFunction.js +2 -1
- package/src/View/Components/Buttons/ButtonNew.d.ts +11 -1
- package/src/View/Components/Buttons/ButtonNew.js +2 -1
- package/src/View/Components/Buttons/EntityListActionButtons.d.ts +1 -1
- package/src/View/Components/Buttons/EntityListActionButtons.js +14 -43
- package/src/View/Components/Buttons/SuspendToggleButton/SuspendToggleButton.d.ts +1 -0
- package/src/View/Components/Buttons/SuspendToggleButton/SuspendToggleButton.js +3 -2
- package/src/View/Components/CellPopup/index.d.ts +1 -1
- package/src/View/Components/ColumnFilter/AdaptableColumnFilter.d.ts +4 -3
- package/src/View/Components/ColumnFilter/ColumnFilter.d.ts +4 -2
- package/src/View/Components/ColumnFilter/ColumnFilter.js +26 -23
- package/src/View/Components/ColumnFilter/ColumnFilterWindow.js +6 -6
- package/src/View/Components/ColumnFilter/FloatingFilter.js +6 -6
- package/src/View/Components/ColumnFilter/components/ColumnFilterInput.d.ts +1 -1
- package/src/View/Components/ColumnFilter/components/ColumnFilterInput.js +2 -2
- package/src/View/Components/ColumnFilter/components/ColumnFilterInputList.js +1 -1
- package/src/View/Components/ColumnFilter/components/ColumnFilterMenu.js +6 -6
- package/src/View/Components/ColumnFilter/useAdaptableFilterWrapper.d.ts +1 -1
- package/src/View/Components/ColumnFilter/useAdaptableFilterWrapper.js +9 -1
- package/src/View/Components/ColumnSelector/index.js +1 -3
- package/src/View/Components/EntityRulesEditor/EntityRulePredicatesEditor/EntityRulePredicateEditor.js +10 -10
- package/src/View/Components/EntityRulesEditor/EntityRulePredicatesEditor/EntityRulePredicatesEditor.js +11 -15
- package/src/View/Components/EntityRulesEditor/index.d.ts +5 -2
- package/src/View/Components/EntityRulesEditor/index.js +11 -10
- package/src/View/Components/ExpressionWizard.js +4 -4
- package/src/View/Components/FilterForm/Waiting.d.ts +4 -2
- package/src/View/Components/FilterForm/Waiting.js +3 -2
- package/src/View/Components/Forms/AdaptableFormControlTextClear.d.ts +1 -0
- package/src/View/Components/Forms/AdaptableFormControlTextClear.js +4 -8
- package/src/View/Components/ModuleValueSelector/index.js +2 -2
- package/src/View/Components/NewScopeComponent.js +20 -20
- package/src/View/Components/Panels/PanelFooter.js +5 -5
- package/src/View/Components/Panels/PanelToolPanel/index.d.ts +1 -1
- package/src/View/Components/Panels/PanelToolPanel/index.js +9 -11
- package/src/View/Components/Panels/PanelWithButton.d.ts +3 -5
- package/src/View/Components/Panels/PanelWithButton.js +7 -6
- package/src/View/Components/Panels/PanelWithImage.d.ts +2 -3
- package/src/View/Components/Panels/PanelWithImage.js +10 -12
- package/src/View/Components/Panels/PanelWithRow.d.ts +0 -1
- package/src/View/Components/Panels/PanelWithRow.js +3 -3
- package/src/View/Components/Panels/PanelWithTwoButtons.d.ts +1 -1
- package/src/View/Components/Panels/PanelWithTwoButtons.js +3 -3
- package/src/View/Components/Popups/AdaptableLoadingScreen.js +3 -5
- package/src/View/Components/Popups/AdaptablePopup/AdaptablePopup.js +4 -3
- package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupDialog.js +3 -2
- package/src/View/Components/Popups/AdaptablePopup/AdaptablePopupModuleView.js +4 -4
- package/src/View/Components/Popups/AdaptablePopup/Navigation.js +63 -31
- package/src/View/Components/Popups/AdaptablePopup/PopupPanel.d.ts +2 -0
- package/src/View/Components/Popups/AdaptablePopup/PopupPanel.js +8 -9
- package/src/View/Components/Popups/AdaptablePopup/TopBar.js +5 -4
- package/src/View/Components/Popups/AdaptablePopup/useMenuItems.d.ts +1 -1
- package/src/View/Components/Popups/AdaptablePopupAlert.js +6 -11
- package/src/View/Components/Popups/AdaptablePopupConfirmation.js +6 -6
- package/src/View/Components/Popups/AdaptablePopupPrompt.js +7 -7
- package/src/View/Components/Popups/AdaptablePopupTeamSharing.js +9 -11
- package/src/View/Components/Popups/FormPopups/FormPopups.js +3 -3
- package/src/View/Components/Popups/GridCellPopup/GridCellPopup.js +1 -1
- package/src/View/Components/Popups/WindowPopups/WindowPopups.js +3 -3
- package/src/View/Components/Popups/WindowPopups/windowFactory.d.ts +0 -1
- package/src/View/Components/PredicateEditor/PredicateEditor.js +7 -7
- package/src/View/Components/PreviewResultsPanel.d.ts +1 -0
- package/src/View/Components/PreviewResultsPanel.js +6 -13
- package/src/View/Components/RangesComponent.js +19 -19
- package/src/View/Components/ReorderDraggable/index.d.ts +2 -0
- package/src/View/Components/ReorderDraggable/index.js +8 -7
- package/src/View/Components/Selectors/BulkUpdateValueSelector.js +4 -7
- package/src/View/Components/Selectors/ColumnSelector.js +1 -1
- package/src/View/Components/Selectors/ColumnSelectorOld.js +1 -1
- package/src/View/Components/StyleComponent.d.ts +2 -26
- package/src/View/Components/StyleComponent.js +186 -190
- package/src/View/Components/TagValueSelector/index.d.ts +1 -1
- package/src/View/Components/TagValueSelector/index.js +4 -3
- package/src/View/Components/ToolPanel/AdaptableToolPanel.d.ts +1 -1
- package/src/View/Components/ToolPanel/AdaptableToolPanel.js +13 -12
- package/src/View/Components/ToolPanel/ToolPanelPopup.d.ts +1 -1
- package/src/View/Components/ToolPanel/ToolPanelPopup.js +13 -10
- package/src/View/Components/ToolPanel/ToolPanelWrapper.js +2 -2
- package/src/View/Components/ValueSelector/index.d.ts +9 -33
- package/src/View/Components/ValueSelector/index.js +38 -61
- package/src/View/Components/WizardSummaryPage.js +1 -1
- package/src/View/CustomSort/Wizard/CustomSortColumnWizardSection.js +2 -2
- package/src/View/CustomSort/Wizard/CustomSortValuesWizardSection.js +4 -7
- package/src/View/CustomSort/Wizard/CustomSortWizard.js +5 -5
- package/src/View/Dashboard/Dashboard.js +3 -3
- package/src/View/Dashboard/DashboardPopup.js +27 -23
- package/src/View/Dashboard/DashboardViewPanel.js +4 -4
- package/src/View/Dashboard/PinnedDashboard.js +3 -3
- package/src/View/Dashboard/PinnedToolbarsSelector.js +3 -2
- package/src/View/DataChangeHistory/DataChangeHistoryPopup.js +10 -10
- package/src/View/DataChangeHistory/DataChangeHistoryViewPanel.js +7 -7
- package/src/View/DataImport/DataImportPopup.js +2 -2
- package/src/View/DataImport/DataImportWizard/DataImportWizard.js +2 -2
- package/src/View/DataImport/DataImportWizard/sections/ColumnsSection.js +6 -6
- package/src/View/DataImport/DataImportWizard/sections/ImportSection.js +4 -4
- package/src/View/DataImport/DataImportWizard/sections/UploadSection/UploadFileSection.js +1 -1
- package/src/View/DataImport/DataImportWizard/sections/UploadSection/UploadSection.js +4 -4
- package/src/View/DataImport/DataImportWizard/sections/UploadSection/UploadTextSection.js +1 -1
- package/src/View/DataImport/DataImportWizard/sections/ValidationSection.js +4 -4
- package/src/View/DataSet/DataSetViewPanel.d.ts +2 -2
- package/src/View/DataSet/DataSetViewPanel.js +2 -2
- package/src/View/Export/ExportDestinationPicker.js +2 -1
- package/src/View/Export/ExportViewPanel.js +4 -4
- package/src/View/Export/ReportFormatSelector.js +3 -3
- package/src/View/Export/ReportListItem.js +1 -1
- package/src/View/Export/ReportNameSelector.js +3 -3
- package/src/View/Export/Wizard/NewReportWizard.js +4 -4
- package/src/View/Export/Wizard/ReportColumnTypeWizard.js +8 -8
- package/src/View/Export/Wizard/ReportColumnsWizardSection.js +11 -11
- package/src/View/Export/Wizard/ReportNameWizardSection.js +4 -4
- package/src/View/Export/Wizard/ReportRowTypeWizard.js +8 -8
- package/src/View/Export/Wizard/ReportRowsWizardSection.js +9 -9
- package/src/View/Export/Wizard/ReportSettingsWizard.js +3 -3
- package/src/View/Filter/FilterSummary.d.ts +1 -1
- package/src/View/Filter/FilterSummary.js +1 -1
- package/src/View/Filter/FilterViewPanel.d.ts +2 -2
- package/src/View/Filter/FilterViewPanel.js +4 -4
- package/src/View/FlashingCell/FlashingCellStyle.d.ts +2 -2
- package/src/View/FlashingCell/FlashingCellStyle.js +4 -4
- package/src/View/FlashingCell/Wizard/FlashingCellScopeWizardSection.js +2 -2
- package/src/View/FlashingCell/Wizard/FlashingCellSettingsWizardSection.js +11 -11
- package/src/View/FlashingCell/Wizard/FlashingCellStyleWizardSection.d.ts +2 -2
- package/src/View/FlashingCell/Wizard/FlashingCellStyleWizardSection.js +4 -4
- package/src/View/FlashingCell/Wizard/FlashingCellWizard.js +5 -5
- package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.d.ts +1 -1
- package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +59 -64
- package/src/View/FormatColumn/Wizard/FormatColumnRuleWizardSection.js +1 -1
- package/src/View/FormatColumn/Wizard/FormatColumnScopeWizardSection.js +0 -4
- package/src/View/FormatColumn/Wizard/FormatColumnSettingsWizardSection.js +28 -28
- package/src/View/FormatColumn/Wizard/FormatColumnStyleWizardSection.js +2 -2
- package/src/View/FormatColumn/Wizard/FormatColumnTargetWizardSection.js +2 -2
- package/src/View/FormatColumn/Wizard/FormatColumnWizard.js +8 -8
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.js +11 -11
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnWizard.js +4 -4
- package/src/View/GridFilter/GridFilterExpressionEditor.js +6 -6
- package/src/View/GridFilter/GridFilterPopup.js +31 -40
- package/src/View/GridFilter/GridFilterPopupUI/index.d.ts +68 -0
- package/src/View/GridFilter/GridFilterPopupUI/index.js +42 -0
- package/src/View/GridFilter/GridFilterViewPanel.js +14 -21
- package/src/View/GridFilter/NamedQuerySelector.js +7 -7
- package/src/View/GridFilter/useGridFilterExpressionEditor.d.ts +5 -1
- package/src/View/GridFilter/useGridFilterExpressionEditor.js +2 -1
- package/src/View/GridInfo/GridInfoPopup/AdaptableObjectsSummary.d.ts +3 -1
- package/src/View/GridInfo/GridInfoPopup/AdaptableObjectsSummary.js +4 -3
- package/src/View/GridInfo/GridInfoPopup/AdaptableOptionsComponent.js +5 -9
- package/src/View/GridInfo/GridInfoPopup/GridInfoPopup.js +7 -7
- package/src/View/KeyHint.d.ts +5 -2
- package/src/View/KeyHint.js +4 -2
- package/src/View/Layout/EditCurrentLayoutButton.js +1 -1
- package/src/View/Layout/LayoutStatusBarSubPanelPopover.js +1 -1
- package/src/View/Layout/LayoutViewPanel.d.ts +3 -3
- package/src/View/Layout/LayoutViewPanel.js +2 -2
- package/src/View/Layout/TransposedPopup.js +4 -4
- package/src/View/Layout/Wizard/LayoutWizard.js +18 -18
- package/src/View/Layout/Wizard/sections/AggregationsSection.js +6 -8
- package/src/View/Layout/Wizard/sections/ColumnsSection.js +213 -138
- package/src/View/Layout/Wizard/sections/FilterSection.js +6 -7
- package/src/View/Layout/Wizard/sections/GridFilterSection.js +2 -2
- package/src/View/Layout/Wizard/sections/PivotAggregationsSection.js +15 -18
- package/src/View/Layout/Wizard/sections/PivotColumnsSection.js +4 -6
- package/src/View/Layout/Wizard/sections/PivotRowGroupingSection.js +3 -5
- package/src/View/Layout/Wizard/sections/RowGroupingSection.js +8 -10
- package/src/View/Layout/Wizard/sections/RowSummarySection.js +15 -17
- package/src/View/Layout/Wizard/sections/SettingsSection.js +8 -8
- package/src/View/Layout/Wizard/sections/SortSection.js +5 -7
- package/src/View/License/LicenseWatermark.js +1 -1
- package/src/View/NamedQuery/Wizard/NamedQueryExpressionWizardSection.js +2 -2
- package/src/View/NamedQuery/Wizard/NamedQuerySettingsWizardSection.js +3 -3
- package/src/View/NamedQuery/Wizard/NamedQueryWizard.js +3 -3
- package/src/View/Note/NoteEditor.js +5 -1
- package/src/View/PlusMinus/Wizard/PlusMinusSettingsWizardSection.js +5 -5
- package/src/View/PlusMinus/Wizard/PlusMinusWizard.js +4 -4
- package/src/View/QuickSearch/FloatingQuickSearch/FloatingQuickSearch.js +2 -2
- package/src/View/QuickSearch/QuickSearchInput.d.ts +1 -0
- package/src/View/QuickSearch/QuickSearchInput.js +5 -5
- package/src/View/QuickSearch/QuickSearchPopup.js +17 -16
- package/src/View/QuickSearch/QuickSearchViewPanel.js +1 -1
- package/src/View/Schedule/Wizard/ScheduleScheduleWizard.js +4 -4
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsIPushPull.js +5 -5
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsOpenFin.js +2 -2
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsReminder.js +4 -4
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsReport.js +5 -5
- package/src/View/Schedule/Wizard/ScheduleWizard.js +5 -5
- package/src/View/Shortcut/Wizard/ShortcutSettingsWizard.js +5 -8
- package/src/View/Shortcut/Wizard/ShortcutWizard.js +5 -5
- package/src/View/SmartEdit/SmartEditPopup.d.ts +1 -1
- package/src/View/SmartEdit/SmartEditPopup.js +8 -8
- package/src/View/SmartEdit/SmartEditViewPanel.js +1 -1
- package/src/View/SpecialColumnSettingsWizardStep.js +4 -4
- package/src/View/StateManagement/StateManagementPopup.js +12 -12
- package/src/View/StateManagement/StateManagementViewPanel.js +1 -1
- package/src/View/StateManagement/handleExportState.d.ts +1 -1
- package/src/View/StatusBar/AdaptableStatusBar.js +1 -1
- package/src/View/StatusBar/StatusBarPanel.d.ts +2 -2
- package/src/View/StatusBar/StatusBarPanel.js +5 -4
- package/src/View/StyledColumn/Wizard/StyledColumnBadgeSection.js +9 -9
- package/src/View/StyledColumn/Wizard/StyledColumnSparklineSettingsSection.js +51 -48
- package/src/View/StyledColumn/Wizard/StyledColumnWizard.js +8 -8
- package/src/View/StyledColumn/Wizard/StyledColumnWizardColumnSection.js +2 -2
- package/src/View/StyledColumn/Wizard/StyledColumnWizardSettingsSection.js +18 -18
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/PercentBarColumnComparisonPreview.js +3 -3
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/PercentBarRangesPreview.js +4 -5
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/PercentBarStylePreview.js +5 -5
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview.js +2 -2
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgeSettings.js +4 -6
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/StyledColumnWizardStyleSection.js +14 -15
- package/src/View/StyledColumn/Wizard/StyledColumnWizardTypeSection.js +4 -4
- package/src/View/SystemStatus/SystemStatusEntityRow.js +3 -3
- package/src/View/SystemStatus/SystemStatusPopup.js +2 -2
- package/src/View/SystemStatus/SystemStatusStatusBarContent.js +2 -2
- package/src/View/SystemStatus/SystemStatusViewPanel.d.ts +2 -2
- package/src/View/SystemStatus/SystemStatusViewPanel.js +2 -2
- package/src/View/TeamSharing/SharedEntityDependencies.js +4 -4
- package/src/View/TeamSharing/SharedEntityObjectView.js +8 -8
- package/src/View/Theme/ThemeEditor.js +6 -31
- package/src/View/Theme/ThemeEditorWindow.js +2 -2
- package/src/View/Theme/ThemeField.js +1 -2
- package/src/View/Theme/ThemePopup.d.ts +1 -1
- package/src/View/Theme/ThemePopup.js +4 -4
- package/src/View/Theme/ThemeStatusbar.js +1 -1
- package/src/View/Theme/VariantSelector.js +1 -1
- package/src/View/UIHelper.d.ts +1 -1
- package/src/View/Wizard/Interface/IAdaptableWizard.d.ts +1 -1
- package/src/View/Wizard/ObjectTagsWizardSection.js +2 -4
- package/src/View/Wizard/OnePageAdaptableWizard.d.ts +10 -4
- package/src/View/Wizard/OnePageAdaptableWizard.js +14 -16
- package/src/View/Wizard/OnePageWizards.d.ts +10 -4
- package/src/View/Wizard/OnePageWizards.js +50 -64
- package/src/View/Wizard/TypeRadio.js +3 -3
- package/src/View/Wizard/WizardLegend.js +3 -4
- package/src/View/Wizard/useKeyboardNavigation.d.ts +1 -1
- package/src/View/Wizard/useKeyboardNavigation.js +7 -4
- package/src/View/renderWithAdaptableContext.js +2 -5
- package/src/agGrid/AdaptableAgGrid.d.ts +2 -3
- package/src/agGrid/AdaptableAgGrid.js +92 -14
- package/src/agGrid/AdaptableFilterHandler.d.ts +5 -7
- package/src/agGrid/AdaptableFilterHandler.js +12 -28
- package/src/agGrid/AgGridColumnAdapter.d.ts +6 -1
- package/src/agGrid/AgGridColumnAdapter.js +26 -5
- package/src/agGrid/AgGridFilterAdapter.js +1 -1
- package/src/agGrid/AgGridFloatingFilterAdapter.js +1 -21
- package/src/agGrid/editors/AdaptableNumberEditor/InternalAdaptableNumberEditor.js +1 -5
- package/src/agGrid/editors/AdaptablePercentageEditor/InternalAdaptablePercentageEditor.js +1 -5
- package/src/components/AdaptableFormComponent/AdaptableFormComponent.js +9 -8
- package/src/components/Card/index.d.ts +25 -0
- package/src/components/Card/index.js +45 -0
- package/src/components/CheckBox/index.d.ts +3 -4
- package/src/components/CheckBox/index.js +7 -9
- package/src/components/CodeBlock/index.d.ts +6 -2
- package/src/components/CodeBlock/index.js +3 -3
- package/src/components/ColorPicker/ColorPicker.d.ts +1 -1
- package/src/components/ColorPicker/ColorPicker.js +10 -9
- package/src/components/Dashboard/Dashboard.js +1 -1
- package/src/components/Dashboard/DashboardToolbar.js +5 -6
- package/src/components/Datepicker/index.d.ts +2 -2
- package/src/components/Datepicker/index.js +9 -8
- package/src/components/Dialog/index.d.ts +8 -2
- package/src/components/Dialog/index.js +7 -7
- package/src/components/DragAndDropContext/DragAndDropContext.d.ts +1 -1
- package/src/components/DragAndDropContext/ModuleManager.d.ts +1 -0
- package/src/components/DragAndDropContext/ModuleManager.js +9 -6
- package/src/components/DragAndDropContext/TabList.d.ts +2 -1
- package/src/components/DragAndDropContext/TabList.js +44 -24
- package/src/components/DragAndDropContext/UnusedPanel.js +7 -15
- package/src/components/Dropdown/index.d.ts +2 -2
- package/src/components/Dropdown/index.js +5 -6
- package/src/components/DropdownButton/index.d.ts +2 -22
- package/src/components/DropdownButton/index.js +7 -4
- package/src/components/EmptyContent/index.d.ts +2 -2
- package/src/components/EmptyContent/index.js +4 -4
- package/src/components/ErrorBox/index.d.ts +2 -2
- package/src/components/ErrorBox/index.js +3 -3
- package/src/components/ExpressionEditor/BaseEditorInput.js +65 -48
- package/src/components/ExpressionEditor/DataTableEditor.js +6 -10
- package/src/components/ExpressionEditor/EditorButton.js +0 -2
- package/src/components/ExpressionEditor/EditorContext.d.ts +0 -1
- package/src/components/ExpressionEditor/EditorInputWithWhereClause.js +5 -5
- package/src/components/ExpressionEditor/ExpressionFunctionDocumentation.js +9 -11
- package/src/components/ExpressionEditor/NamedQueryContext.d.ts +0 -1
- package/src/components/ExpressionEditor/NamedQueryEditor.js +6 -16
- package/src/components/ExpressionEditor/QueryBuilder/QueryBuilder.d.ts +2 -10
- package/src/components/ExpressionEditor/QueryBuilder/QueryBuilder.js +6 -6
- package/src/components/ExpressionEditor/QueryBuilder/QueryBuilderInputs.d.ts +1 -1
- package/src/components/ExpressionEditor/QueryBuilder/QueryBuilderInputs.js +7 -7
- package/src/components/ExpressionEditor/QueryBuilder/QueryPredicateBuilder.js +9 -14
- package/src/components/ExpressionEditor/index.d.ts +1 -0
- package/src/components/ExpressionEditor/index.js +29 -34
- package/src/components/FieldWrap/index.d.ts +9 -2
- package/src/components/FieldWrap/index.js +3 -8
- package/src/components/FileDroppable/FileDroppableState.d.ts +0 -1
- package/src/components/FileDroppable/index.d.ts +3 -2
- package/src/components/FileDroppable/index.js +3 -3
- package/src/components/Flex.d.ts +15 -1
- package/src/components/Flex.js +40 -1
- package/src/components/FlexWithFooter.d.ts +3 -2
- package/src/components/FlexWithFooter.js +4 -4
- package/src/components/FormLayout/index.d.ts +5 -1
- package/src/components/FormLayout/index.js +1 -1
- package/src/components/HelpBlock/index.d.ts +2 -2
- package/src/components/HelpBlock/index.js +4 -3
- package/src/components/IconSelector/IconSelector.js +8 -8
- package/src/components/Input/index.d.ts +1 -2
- package/src/components/Input/index.js +6 -3
- package/src/components/Modal/Backdrop.js +1 -1
- package/src/components/Modal/index.d.ts +3 -2
- package/src/components/Modal/index.js +3 -3
- package/src/components/OverlayTrigger/index.js +3 -0
- package/src/components/Panel/index.d.ts +22 -6
- package/src/components/Panel/index.js +54 -15
- package/src/components/PopupWithFooter.js +3 -4
- package/src/components/ProgressIndicator/ProgressIndicator.js +3 -3
- package/src/components/Radio/index.d.ts +25 -3
- package/src/components/Radio/index.js +18 -20
- package/src/components/Select/Select.js +33 -21
- package/src/components/SelectList.js +1 -1
- package/src/components/SelectableList/index.d.ts +1 -1
- package/src/components/SimpleButton/index.d.ts +4 -6
- package/src/components/SimpleButton/index.js +55 -23
- package/src/components/SizedContainer/index.d.ts +3 -1
- package/src/components/SizedContainer/index.js +1 -1
- package/src/components/StylePreview.d.ts +3 -1
- package/src/components/StylePreview.js +4 -3
- package/src/components/Tabs/index.d.ts +3 -3
- package/src/components/Tabs/index.js +26 -9
- package/src/components/Tag/Tag.d.ts +14 -2
- package/src/components/Tag/Tag.js +10 -3
- package/src/components/Tag/index.d.ts +1 -1
- package/src/components/Tag/index.js +1 -1
- package/src/components/Textarea/index.d.ts +5 -1
- package/src/components/Textarea/index.js +4 -3
- package/src/components/Toggle/Toggle.js +48 -3
- package/src/components/Toggle/ToggleGroup.d.ts +7 -0
- package/src/components/Toggle/ToggleGroup.js +57 -2
- package/src/components/ToggleButton/index.d.ts +2 -2
- package/src/components/ToggleButton/index.js +25 -7
- package/src/components/Tree/TreeDropdown/index.js +10 -15
- package/src/components/Tree/TreeList/index.js +5 -9
- package/src/components/WarningBox/index.d.ts +6 -2
- package/src/components/WarningBox/index.js +3 -3
- package/src/components/WizardPanel/index.d.ts +6 -1
- package/src/components/WizardPanel/index.js +2 -2
- package/src/components/icons/DefaultIcon.d.ts +1 -0
- package/src/components/icons/index.d.ts +1 -1
- package/src/components/icons/index.js +2 -0
- package/src/components/icons/inspector.d.ts +3 -0
- package/src/components/icons/inspector.js +5 -0
- package/src/components/twUtils.d.ts +7 -0
- package/src/components/twUtils.js +13 -0
- package/src/components/utils/useDraggable.d.ts +0 -1
- package/src/devTools/index.d.ts +23 -23
- package/src/env.js +2 -2
- package/src/layout-manager/src/LMEmitter.d.ts +1 -0
- package/src/layout-manager/src/LMEmitter.js +1 -0
- package/src/layout-manager/src/index.js +2 -2
- package/src/migration/VersionUpgrade20.js +6 -5
- package/src/twMerge.d.ts +1 -0
- package/src/twMerge.js +11 -0
- package/themes/dark.css +35 -9
- package/themes/light.css +0 -2
- package/tsconfig.esm.tsbuildinfo +1 -1
- package/base.css +0 -5602
- package/base.css.map +0 -1
- package/src/Strategy/Utilities/FormatColumn/getFormatColumnStyleViewItems.d.ts +0 -3
- package/src/Strategy/Utilities/FormatColumn/getFormatColumnStyleViewItems.js +0 -6
- package/src/View/Alert/AlertsPanel.d.ts +0 -14
- package/src/View/Alert/AlertsPanel.js +0 -38
- package/src/View/Alert/Wizard/AlertSelectQueryWizard.d.ts +0 -19
- package/src/View/Alert/Wizard/AlertSelectQueryWizard.js +0 -54
- package/src/View/Components/FilterForm/ListBoxMenu.d.ts +0 -14
- package/src/View/Components/FilterForm/ListBoxMenu.js +0 -28
- package/src/View/Components/ListBox/DualListBoxEditor.d.ts +0 -22
- package/src/View/Components/ListBox/DualListBoxEditor.js +0 -515
- package/src/View/Components/ListBox/ListBoxFilterSortComponent.d.ts +0 -13
- package/src/View/Components/ListBox/ListBoxFilterSortComponent.js +0 -26
- package/src/View/CustomSort/Wizard/CustomSortSummaryWizard.d.ts +0 -15
- package/src/View/CustomSort/Wizard/CustomSortSummaryWizard.js +0 -31
- package/src/View/Layout/Wizard/Components/ColumnLabels.d.ts +0 -9
- package/src/View/Layout/Wizard/Components/ColumnLabels.js +0 -52
- package/src/View/Wizard/AdaptableWizard.d.ts +0 -56
- package/src/View/Wizard/AdaptableWizard.js +0 -168
- package/src/components/ContainerProps.d.ts +0 -30
- package/src/components/ContainerProps.js +0 -1
- package/src/components/EllipsisContainer/index.d.ts +0 -13
- package/src/components/EllipsisContainer/index.js +0 -100
- package/src/components/List/GridList/index.d.ts +0 -10
- package/src/components/List/GridList/index.js +0 -23
- package/src/components/List/ListGroup/index.d.ts +0 -6
- package/src/components/List/ListGroup/index.js +0 -9
- package/src/components/List/ListGroupItem/index.d.ts +0 -11
- package/src/components/List/ListGroupItem/index.js +0 -16
- package/src/components/utils/useTheme.d.ts +0 -32
- package/src/components/utils/useTheme.js +0 -2
- package/src/theme.d.ts +0 -32
- package/src/theme.js +0 -49
- package/themes/dark.css.map +0 -1
- package/themes/light.css.map +0 -1
|
@@ -1,515 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { useState, useRef, useEffect } from 'react';
|
|
3
|
-
import { SortOrder } from '../../../AdaptableState/Common/Enums';
|
|
4
|
-
import { ListBoxFilterSortComponent } from './ListBoxFilterSortComponent';
|
|
5
|
-
import { ArrayExtensions } from '../../../Utilities/Extensions/ArrayExtensions';
|
|
6
|
-
import ListGroupItem from '../../../components/List/ListGroupItem';
|
|
7
|
-
import SimpleButton from '../../../components/SimpleButton';
|
|
8
|
-
import { Flex } from 'rebass';
|
|
9
|
-
import Panel from '../../../components/Panel';
|
|
10
|
-
import ListGroup from '../../../components/List/ListGroup';
|
|
11
|
-
import SelectableList from '../../../components/SelectableList';
|
|
12
|
-
import { useLatest } from '../../../components/utils/useLatest';
|
|
13
|
-
const listGroupStyle = {
|
|
14
|
-
overflowY: 'auto',
|
|
15
|
-
marginBottom: '0px',
|
|
16
|
-
};
|
|
17
|
-
const listGroupItemStyle = {
|
|
18
|
-
fontSize: 'small',
|
|
19
|
-
padding: 'var(--ab-space-1)',
|
|
20
|
-
};
|
|
21
|
-
const ButtonDirection = (props) => (React.createElement(SimpleButton, { ...props, style: { whiteSpace: 'nowrap', justifyContent: 'center', ...props.style } }));
|
|
22
|
-
export const DualListBoxEditor = (props) => {
|
|
23
|
-
const [placeholder] = useState(() => {
|
|
24
|
-
let placeholder = document.createElement('button');
|
|
25
|
-
placeholder.className = 'placeholder';
|
|
26
|
-
placeholder.classList.add('list-group-item');
|
|
27
|
-
placeholder.type = 'button';
|
|
28
|
-
return placeholder;
|
|
29
|
-
});
|
|
30
|
-
const refDraggedHTMLElement = useRef(null);
|
|
31
|
-
const refDraggedElement = useRef(null);
|
|
32
|
-
const refOverHTMLElement = useRef(null);
|
|
33
|
-
const refFirstSelected = useRef(null);
|
|
34
|
-
const createAvailableValuesList = (availableValues, sortOrder) => {
|
|
35
|
-
return ArrayExtensions.sortArray(availableValues, sortOrder);
|
|
36
|
-
};
|
|
37
|
-
const [state, updateState] = useState(() => {
|
|
38
|
-
let availableValues = new Array();
|
|
39
|
-
props.AvailableValues.forEach((x) => {
|
|
40
|
-
if (props.SelectedValues.indexOf(x) < 0) {
|
|
41
|
-
availableValues.push(x);
|
|
42
|
-
}
|
|
43
|
-
});
|
|
44
|
-
return {
|
|
45
|
-
SelectedValues: props.SelectedValues,
|
|
46
|
-
AvailableValues: createAvailableValuesList(availableValues, SortOrder.Asc),
|
|
47
|
-
UiSelectedSelectedValues: [],
|
|
48
|
-
UiSelectedAvailableValues: [],
|
|
49
|
-
FilterValue: '',
|
|
50
|
-
SelectedValuesFilterValue: '',
|
|
51
|
-
SortOrder: SortOrder.Asc,
|
|
52
|
-
SelectedValuesSortOrder: SortOrder.Asc,
|
|
53
|
-
AllValues: props.AvailableValues,
|
|
54
|
-
};
|
|
55
|
-
});
|
|
56
|
-
const callbackRefs = useRef([]);
|
|
57
|
-
const getProps = useLatest(props);
|
|
58
|
-
const setState = (newState, callback) => {
|
|
59
|
-
updateState({ ...state, ...newState });
|
|
60
|
-
if (newState.SelectedValues && props.SelectedValues !== newState.SelectedValues) {
|
|
61
|
-
getProps().onChange(newState.SelectedValues);
|
|
62
|
-
}
|
|
63
|
-
if (callback) {
|
|
64
|
-
callbackRefs.current.push(callback);
|
|
65
|
-
}
|
|
66
|
-
};
|
|
67
|
-
useEffect(() => {
|
|
68
|
-
const callbacks = [...callbackRefs.current];
|
|
69
|
-
callbacks.forEach((fn) => fn());
|
|
70
|
-
callbackRefs.current = [];
|
|
71
|
-
});
|
|
72
|
-
useEffect(() => {
|
|
73
|
-
const availableValues = [];
|
|
74
|
-
props.AvailableValues.forEach((x) => {
|
|
75
|
-
if (props.SelectedValues.indexOf(x) < 0) {
|
|
76
|
-
availableValues.push(x);
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
setState({
|
|
80
|
-
SelectedValues: props.SelectedValues,
|
|
81
|
-
AvailableValues: createAvailableValuesList(availableValues, state.SortOrder),
|
|
82
|
-
});
|
|
83
|
-
}, [props.SelectedValues, props.AvailableValues]);
|
|
84
|
-
const isValueFilteredOut = (item, FilterValue = state.FilterValue) => {
|
|
85
|
-
return (FilterValue != '' && item.toLocaleLowerCase().indexOf(FilterValue.toLocaleLowerCase()) < 0);
|
|
86
|
-
};
|
|
87
|
-
const canGoTopOrUp = () => {
|
|
88
|
-
return (state.UiSelectedSelectedValues.length != 0 &&
|
|
89
|
-
state.UiSelectedSelectedValues.every((x) => state.SelectedValues.indexOf(x) > 0));
|
|
90
|
-
};
|
|
91
|
-
const canGoDownOrBottom = () => {
|
|
92
|
-
return (state.UiSelectedSelectedValues.length != 0 &&
|
|
93
|
-
state.UiSelectedSelectedValues.every((x) => state.SelectedValues.indexOf(x) < state.SelectedValues.length - 1));
|
|
94
|
-
};
|
|
95
|
-
const ensureFirstSelectedItemVisible = (top) => {
|
|
96
|
-
var itemComponentDOMNode = refFirstSelected.current;
|
|
97
|
-
if (itemComponentDOMNode) {
|
|
98
|
-
itemComponentDOMNode.scrollIntoView(top);
|
|
99
|
-
}
|
|
100
|
-
};
|
|
101
|
-
const Top = () => {
|
|
102
|
-
let newSelectedValues = [].concat(state.UiSelectedSelectedValues, state.SelectedValues.filter((x) => state.UiSelectedSelectedValues.indexOf(x) < 0));
|
|
103
|
-
setState({
|
|
104
|
-
SelectedValues: newSelectedValues,
|
|
105
|
-
UiSelectedSelectedValues: [],
|
|
106
|
-
}, () => {
|
|
107
|
-
ensureFirstSelectedItemVisible(true);
|
|
108
|
-
});
|
|
109
|
-
};
|
|
110
|
-
const Up = () => {
|
|
111
|
-
let newSelectedValues = [...state.SelectedValues];
|
|
112
|
-
for (let selElement of state.UiSelectedSelectedValues) {
|
|
113
|
-
let index = newSelectedValues.indexOf(selElement);
|
|
114
|
-
ArrayExtensions.moveArray(newSelectedValues, index, index - 1);
|
|
115
|
-
}
|
|
116
|
-
setState({
|
|
117
|
-
SelectedValues: newSelectedValues,
|
|
118
|
-
}, () => {
|
|
119
|
-
ensureFirstSelectedItemVisible(false);
|
|
120
|
-
});
|
|
121
|
-
};
|
|
122
|
-
const Bottom = () => {
|
|
123
|
-
let newSelectedValues = [].concat(state.SelectedValues.filter((x) => state.UiSelectedSelectedValues.indexOf(x) < 0), state.UiSelectedSelectedValues);
|
|
124
|
-
setState({
|
|
125
|
-
SelectedValues: newSelectedValues,
|
|
126
|
-
UiSelectedSelectedValues: [],
|
|
127
|
-
}, () => {
|
|
128
|
-
ensureFirstSelectedItemVisible(true);
|
|
129
|
-
});
|
|
130
|
-
};
|
|
131
|
-
const Down = () => {
|
|
132
|
-
let newSelectedValues = [...state.SelectedValues];
|
|
133
|
-
for (var index = state.UiSelectedSelectedValues.length - 1; index >= 0; index--) {
|
|
134
|
-
let indexglob = newSelectedValues.indexOf(state.UiSelectedSelectedValues[index]);
|
|
135
|
-
ArrayExtensions.moveArray(newSelectedValues, indexglob, indexglob + 1);
|
|
136
|
-
}
|
|
137
|
-
setState({
|
|
138
|
-
SelectedValues: newSelectedValues,
|
|
139
|
-
}, () => {
|
|
140
|
-
ensureFirstSelectedItemVisible(false);
|
|
141
|
-
});
|
|
142
|
-
};
|
|
143
|
-
const Add = () => {
|
|
144
|
-
let newSelectedValues = [...state.SelectedValues];
|
|
145
|
-
let newAvailableValues = [...state.AvailableValues];
|
|
146
|
-
let valuesToAdd = state.UiSelectedAvailableValues;
|
|
147
|
-
valuesToAdd.forEach((x) => {
|
|
148
|
-
let index = newAvailableValues.indexOf(x);
|
|
149
|
-
newAvailableValues.splice(index, 1);
|
|
150
|
-
newSelectedValues.push(x);
|
|
151
|
-
});
|
|
152
|
-
newAvailableValues = createAvailableValuesList(newAvailableValues, state.SortOrder);
|
|
153
|
-
setState({
|
|
154
|
-
UiSelectedAvailableValues: [],
|
|
155
|
-
SelectedValues: newSelectedValues,
|
|
156
|
-
AvailableValues: newAvailableValues,
|
|
157
|
-
});
|
|
158
|
-
};
|
|
159
|
-
const AddAll = () => {
|
|
160
|
-
let newSelectedValues = [].concat(state.SelectedValues);
|
|
161
|
-
let valuesToAdd = state.AvailableValues;
|
|
162
|
-
valuesToAdd.forEach((x) => {
|
|
163
|
-
newSelectedValues.push(x);
|
|
164
|
-
});
|
|
165
|
-
setState({
|
|
166
|
-
UiSelectedSelectedValues: [],
|
|
167
|
-
UiSelectedAvailableValues: [],
|
|
168
|
-
SelectedValues: newSelectedValues,
|
|
169
|
-
AvailableValues: [],
|
|
170
|
-
});
|
|
171
|
-
};
|
|
172
|
-
const RemoveAll = () => {
|
|
173
|
-
let newSelectedValues = [];
|
|
174
|
-
let newAvailableValues = [].concat(state.AllValues);
|
|
175
|
-
newAvailableValues = createAvailableValuesList(newAvailableValues, state.SortOrder);
|
|
176
|
-
setState({
|
|
177
|
-
UiSelectedSelectedValues: [],
|
|
178
|
-
UiSelectedAvailableValues: [],
|
|
179
|
-
SelectedValues: newSelectedValues,
|
|
180
|
-
AvailableValues: newAvailableValues,
|
|
181
|
-
});
|
|
182
|
-
};
|
|
183
|
-
const Remove = () => {
|
|
184
|
-
let newSelectedValues = [...state.SelectedValues];
|
|
185
|
-
let newAvailableValues = [...state.AvailableValues];
|
|
186
|
-
state.UiSelectedSelectedValues.forEach((x) => {
|
|
187
|
-
let index = newSelectedValues.indexOf(x);
|
|
188
|
-
newSelectedValues.splice(index, 1);
|
|
189
|
-
let originalItem = state.AllValues.find((y) => y == x);
|
|
190
|
-
if (originalItem) {
|
|
191
|
-
newAvailableValues.push(originalItem);
|
|
192
|
-
}
|
|
193
|
-
});
|
|
194
|
-
newAvailableValues = createAvailableValuesList(newAvailableValues, state.SortOrder);
|
|
195
|
-
setState({
|
|
196
|
-
UiSelectedSelectedValues: [],
|
|
197
|
-
SelectedValues: newSelectedValues,
|
|
198
|
-
AvailableValues: newAvailableValues,
|
|
199
|
-
});
|
|
200
|
-
};
|
|
201
|
-
const DragSelectedStart = (e, listElement) => {
|
|
202
|
-
refDraggedHTMLElement.current = e.currentTarget;
|
|
203
|
-
refDraggedElement.current = listElement;
|
|
204
|
-
};
|
|
205
|
-
const DragSelectedEnd = () => {
|
|
206
|
-
if (refOverHTMLElement.current && refDraggedElement.current) {
|
|
207
|
-
//now we need to check in which drop area we dropped the selected item
|
|
208
|
-
let to;
|
|
209
|
-
let from = state.SelectedValues.indexOf(refDraggedElement.current);
|
|
210
|
-
let newSelectedArray;
|
|
211
|
-
let newAvailableValues;
|
|
212
|
-
if (refOverHTMLElement.current.classList.contains('Available')) {
|
|
213
|
-
to = state.AvailableValues.indexOf(refOverHTMLElement.current.innerText);
|
|
214
|
-
newSelectedArray = [...state.SelectedValues];
|
|
215
|
-
newSelectedArray.splice(from, 1);
|
|
216
|
-
newAvailableValues = [...state.AvailableValues];
|
|
217
|
-
let originalItem = state.AllValues.find((y) => y == refDraggedElement.current);
|
|
218
|
-
if (originalItem) {
|
|
219
|
-
let checkForExistig = newAvailableValues.find((x) => x == originalItem);
|
|
220
|
-
if (!checkForExistig) {
|
|
221
|
-
newAvailableValues.splice(to, 0, originalItem);
|
|
222
|
-
}
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
else if (refOverHTMLElement.current.classList.contains('ab-AvailableDropZone')) {
|
|
226
|
-
newSelectedArray = [...state.SelectedValues];
|
|
227
|
-
newSelectedArray.splice(from, 1);
|
|
228
|
-
newAvailableValues = [...state.AvailableValues];
|
|
229
|
-
let originalItem = state.AllValues.find((y) => y == refDraggedElement.current);
|
|
230
|
-
if (originalItem) {
|
|
231
|
-
let checkForExistig = newAvailableValues.find((x) => x == originalItem);
|
|
232
|
-
if (!checkForExistig) {
|
|
233
|
-
newAvailableValues.push(originalItem);
|
|
234
|
-
}
|
|
235
|
-
}
|
|
236
|
-
}
|
|
237
|
-
else if (refOverHTMLElement.current.classList.contains('Selected')) {
|
|
238
|
-
to = state.SelectedValues.indexOf(refOverHTMLElement.current.innerText);
|
|
239
|
-
newSelectedArray = [...state.SelectedValues];
|
|
240
|
-
newSelectedArray.splice(from, 1);
|
|
241
|
-
newSelectedArray.splice(to, 0, refDraggedElement.current);
|
|
242
|
-
newAvailableValues = [...state.AvailableValues];
|
|
243
|
-
}
|
|
244
|
-
else if (refOverHTMLElement.current.classList.contains('ab-SelectedDropZone')) {
|
|
245
|
-
newSelectedArray = [...state.SelectedValues];
|
|
246
|
-
newSelectedArray.splice(from, 1);
|
|
247
|
-
newSelectedArray.push(refDraggedElement.current);
|
|
248
|
-
newAvailableValues = [...state.AvailableValues];
|
|
249
|
-
}
|
|
250
|
-
//We remove our awesome placeholder
|
|
251
|
-
if (refOverHTMLElement.current.classList.contains('ab-SelectedDropZone') ||
|
|
252
|
-
refOverHTMLElement.current.classList.contains('ab-AvailableDropZone')) {
|
|
253
|
-
refOverHTMLElement.current.removeChild(placeholder);
|
|
254
|
-
}
|
|
255
|
-
else {
|
|
256
|
-
refOverHTMLElement.current.parentNode.removeChild(placeholder);
|
|
257
|
-
}
|
|
258
|
-
refOverHTMLElement.current = null;
|
|
259
|
-
refDraggedHTMLElement.current = null;
|
|
260
|
-
refDraggedElement.current = null;
|
|
261
|
-
// Update state
|
|
262
|
-
newAvailableValues = createAvailableValuesList(newAvailableValues, state.SortOrder);
|
|
263
|
-
setState({
|
|
264
|
-
SelectedValues: newSelectedArray,
|
|
265
|
-
AvailableValues: newAvailableValues,
|
|
266
|
-
UiSelectedSelectedValues: [],
|
|
267
|
-
UiSelectedAvailableValues: [],
|
|
268
|
-
});
|
|
269
|
-
}
|
|
270
|
-
};
|
|
271
|
-
const DragAvailableStart = (e, listElement) => {
|
|
272
|
-
refDraggedHTMLElement.current = e.currentTarget;
|
|
273
|
-
refDraggedElement.current = listElement;
|
|
274
|
-
};
|
|
275
|
-
const DragAvailableEnd = () => {
|
|
276
|
-
if (refOverHTMLElement.current && refDraggedElement.current) {
|
|
277
|
-
let to;
|
|
278
|
-
let from = state.AvailableValues.indexOf(refDraggedElement.current);
|
|
279
|
-
let newSelectedArray;
|
|
280
|
-
let newAvailableValues;
|
|
281
|
-
if (refOverHTMLElement.current.classList.contains('Selected')) {
|
|
282
|
-
from = state.AvailableValues.indexOf(refDraggedElement.current);
|
|
283
|
-
to = state.SelectedValues.indexOf(refOverHTMLElement.current.innerText);
|
|
284
|
-
newSelectedArray = [...state.SelectedValues];
|
|
285
|
-
newSelectedArray.splice(to, 0, refDraggedElement.current);
|
|
286
|
-
newAvailableValues = [...state.AvailableValues];
|
|
287
|
-
newAvailableValues.splice(from, 1);
|
|
288
|
-
}
|
|
289
|
-
else if (refOverHTMLElement.current.classList.contains('ab-SelectedDropZone')) {
|
|
290
|
-
newSelectedArray = [...state.SelectedValues];
|
|
291
|
-
newSelectedArray.push(refDraggedElement.current);
|
|
292
|
-
newAvailableValues = [...state.AvailableValues];
|
|
293
|
-
newAvailableValues.splice(from, 1);
|
|
294
|
-
}
|
|
295
|
-
//We remove our awesome placeholder
|
|
296
|
-
if (refOverHTMLElement.current.classList.contains('ab-SelectedDropZone')) {
|
|
297
|
-
refOverHTMLElement.current.removeChild(placeholder);
|
|
298
|
-
}
|
|
299
|
-
else {
|
|
300
|
-
refOverHTMLElement.current.parentNode.removeChild(placeholder);
|
|
301
|
-
}
|
|
302
|
-
refOverHTMLElement.current = null;
|
|
303
|
-
refDraggedHTMLElement.current = null;
|
|
304
|
-
refDraggedElement.current = null;
|
|
305
|
-
// Update state
|
|
306
|
-
setState({
|
|
307
|
-
SelectedValues: newSelectedArray,
|
|
308
|
-
AvailableValues: newAvailableValues,
|
|
309
|
-
UiSelectedSelectedValues: [],
|
|
310
|
-
UiSelectedAvailableValues: [],
|
|
311
|
-
});
|
|
312
|
-
}
|
|
313
|
-
};
|
|
314
|
-
const DragEnterAvailable = (e) => {
|
|
315
|
-
e.preventDefault();
|
|
316
|
-
e.stopPropagation();
|
|
317
|
-
};
|
|
318
|
-
const DragOverAvailable = (e) => {
|
|
319
|
-
e.preventDefault();
|
|
320
|
-
e.stopPropagation();
|
|
321
|
-
//we can only drop selected data into available
|
|
322
|
-
if (!refDraggedHTMLElement.current.classList.contains('Selected')) {
|
|
323
|
-
e.dataTransfer.dropEffect = 'none';
|
|
324
|
-
return;
|
|
325
|
-
}
|
|
326
|
-
let targetElement = e.target;
|
|
327
|
-
//we want to keep the reference of the last intem we were over to
|
|
328
|
-
if (targetElement.classList.contains('placeholder')) {
|
|
329
|
-
return;
|
|
330
|
-
}
|
|
331
|
-
refOverHTMLElement.current = targetElement;
|
|
332
|
-
if (refOverHTMLElement.current.classList.contains('ab-AvailableDropZone')) {
|
|
333
|
-
targetElement.appendChild(placeholder);
|
|
334
|
-
}
|
|
335
|
-
else {
|
|
336
|
-
targetElement.parentNode.insertBefore(placeholder, targetElement);
|
|
337
|
-
}
|
|
338
|
-
};
|
|
339
|
-
const DragLeaveAvailable = (e) => {
|
|
340
|
-
e.preventDefault();
|
|
341
|
-
e.stopPropagation();
|
|
342
|
-
let targetElement = e.target;
|
|
343
|
-
if (targetElement.classList.contains('ab-AvailableDropZone') ||
|
|
344
|
-
targetElement.classList.contains('placeholder')) {
|
|
345
|
-
if (refOverHTMLElement.current) {
|
|
346
|
-
if (refOverHTMLElement.current.classList.contains('ab-AvailableDropZone')) {
|
|
347
|
-
refOverHTMLElement.current.removeChild(placeholder);
|
|
348
|
-
}
|
|
349
|
-
else {
|
|
350
|
-
refOverHTMLElement.current.parentNode.removeChild(placeholder);
|
|
351
|
-
}
|
|
352
|
-
refOverHTMLElement.current = null;
|
|
353
|
-
}
|
|
354
|
-
}
|
|
355
|
-
};
|
|
356
|
-
const DragEnterSelected = (e) => {
|
|
357
|
-
e.preventDefault();
|
|
358
|
-
e.stopPropagation();
|
|
359
|
-
};
|
|
360
|
-
const DragOverSelected = (e) => {
|
|
361
|
-
e.preventDefault();
|
|
362
|
-
e.stopPropagation();
|
|
363
|
-
let targetElement = e.target;
|
|
364
|
-
//we want to keep the reference of the last intem we were over to
|
|
365
|
-
if (targetElement.classList.contains('placeholder')) {
|
|
366
|
-
return;
|
|
367
|
-
}
|
|
368
|
-
refOverHTMLElement.current = targetElement;
|
|
369
|
-
if (refOverHTMLElement.current.classList.contains('ab-SelectedDropZone')) {
|
|
370
|
-
targetElement.appendChild(placeholder);
|
|
371
|
-
}
|
|
372
|
-
else {
|
|
373
|
-
targetElement.parentNode.insertBefore(placeholder, targetElement);
|
|
374
|
-
}
|
|
375
|
-
};
|
|
376
|
-
const DragLeaveSelected = (e) => {
|
|
377
|
-
e.preventDefault();
|
|
378
|
-
e.stopPropagation();
|
|
379
|
-
let targetElement = e.target;
|
|
380
|
-
if (targetElement.classList.contains('ab-SelectedDropZone') ||
|
|
381
|
-
targetElement.classList.contains('placeholder')) {
|
|
382
|
-
if (refOverHTMLElement.current) {
|
|
383
|
-
if (refOverHTMLElement.current.classList.contains('ab-SelectedDropZone')) {
|
|
384
|
-
refOverHTMLElement.current.removeChild(placeholder);
|
|
385
|
-
}
|
|
386
|
-
else {
|
|
387
|
-
refOverHTMLElement.current.parentNode.removeChild(placeholder);
|
|
388
|
-
}
|
|
389
|
-
refOverHTMLElement.current = null;
|
|
390
|
-
}
|
|
391
|
-
}
|
|
392
|
-
};
|
|
393
|
-
const handleChangeFilterValue = (x) => {
|
|
394
|
-
setState({
|
|
395
|
-
FilterValue: x,
|
|
396
|
-
});
|
|
397
|
-
};
|
|
398
|
-
const handleChangeSelectedValuesFilterValue = (x) => {
|
|
399
|
-
setState({
|
|
400
|
-
SelectedValuesFilterValue: x,
|
|
401
|
-
});
|
|
402
|
-
};
|
|
403
|
-
const sortColumnValues = () => {
|
|
404
|
-
if (state.SortOrder == SortOrder.Asc) {
|
|
405
|
-
setState({
|
|
406
|
-
AvailableValues: ArrayExtensions.sortArray(state.AvailableValues, SortOrder.Desc),
|
|
407
|
-
SortOrder: SortOrder.Desc,
|
|
408
|
-
});
|
|
409
|
-
}
|
|
410
|
-
else {
|
|
411
|
-
setState({
|
|
412
|
-
AvailableValues: ArrayExtensions.sortArray(state.AvailableValues, SortOrder.Asc),
|
|
413
|
-
SortOrder: SortOrder.Asc,
|
|
414
|
-
});
|
|
415
|
-
}
|
|
416
|
-
};
|
|
417
|
-
const sortSelectedColumnValues = () => {
|
|
418
|
-
if (state.SelectedValuesSortOrder == SortOrder.Asc) {
|
|
419
|
-
setState({
|
|
420
|
-
SelectedValues: ArrayExtensions.sortArray(state.SelectedValues, SortOrder.Desc),
|
|
421
|
-
SelectedValuesSortOrder: SortOrder.Desc,
|
|
422
|
-
});
|
|
423
|
-
}
|
|
424
|
-
else {
|
|
425
|
-
setState({
|
|
426
|
-
SelectedValues: ArrayExtensions.sortArray(state.SelectedValues, SortOrder.Asc),
|
|
427
|
-
SelectedValuesSortOrder: SortOrder.Asc,
|
|
428
|
-
});
|
|
429
|
-
}
|
|
430
|
-
};
|
|
431
|
-
const getSelectedItemId = (index) => {
|
|
432
|
-
const item = state.SelectedValues[index];
|
|
433
|
-
if (!item) {
|
|
434
|
-
return -1;
|
|
435
|
-
}
|
|
436
|
-
let display = item;
|
|
437
|
-
if (isValueFilteredOut(display, state.SelectedValuesFilterValue)) {
|
|
438
|
-
return -1;
|
|
439
|
-
}
|
|
440
|
-
return item;
|
|
441
|
-
};
|
|
442
|
-
const onSelectedListSelectionChange = (selection) => {
|
|
443
|
-
const UiSelectedSelectedValues = Object.keys(selection);
|
|
444
|
-
UiSelectedSelectedValues.sort((a, b) => state.SelectedValues.indexOf(a) - state.SelectedValues.indexOf(b));
|
|
445
|
-
setState({ UiSelectedSelectedValues });
|
|
446
|
-
};
|
|
447
|
-
const getAvailableItemId = (index) => {
|
|
448
|
-
const item = state.AvailableValues[index];
|
|
449
|
-
if (!item) {
|
|
450
|
-
return -1;
|
|
451
|
-
}
|
|
452
|
-
let display = item;
|
|
453
|
-
let value = item;
|
|
454
|
-
if (isValueFilteredOut(display)) {
|
|
455
|
-
return -1;
|
|
456
|
-
}
|
|
457
|
-
return value;
|
|
458
|
-
};
|
|
459
|
-
/**
|
|
460
|
-
* @param selection - is a map, values being item keys (their textual representation), while values being true
|
|
461
|
-
*/
|
|
462
|
-
const onAvailableListSelectionChange = (selection) => {
|
|
463
|
-
const UiSelectedAvailableValues = Object.keys(selection);
|
|
464
|
-
const availableValues = state.AvailableValues;
|
|
465
|
-
UiSelectedAvailableValues.sort((a, b) => availableValues.indexOf(a) - availableValues.indexOf(b));
|
|
466
|
-
setState({ UiSelectedAvailableValues });
|
|
467
|
-
};
|
|
468
|
-
let setRefFirstSelectedSelected = true;
|
|
469
|
-
// build selected elements
|
|
470
|
-
const selectedElements = state.SelectedValues.map((x, index) => {
|
|
471
|
-
let isActive = state.UiSelectedSelectedValues.indexOf(x) >= 0;
|
|
472
|
-
if (isValueFilteredOut(x, state.SelectedValuesFilterValue)) {
|
|
473
|
-
return null;
|
|
474
|
-
}
|
|
475
|
-
const result = (React.createElement(ListGroupItem, { key: `${x}-1`, index: index, className: "Selected", draggable: true, style: listGroupItemStyle, active: isActive, ref: isActive && setRefFirstSelectedSelected ? refFirstSelected : null, onDragStart: (event) => DragSelectedStart(event, x), onDragEnd: () => DragSelectedEnd(), value: x }, x));
|
|
476
|
-
if (isActive && setRefFirstSelectedSelected) {
|
|
477
|
-
setRefFirstSelectedSelected = false;
|
|
478
|
-
}
|
|
479
|
-
return result;
|
|
480
|
-
});
|
|
481
|
-
// build available elements
|
|
482
|
-
const availableElements = state.AvailableValues.map((x, index) => {
|
|
483
|
-
let isActive = state.UiSelectedAvailableValues.indexOf(x) >= 0;
|
|
484
|
-
let value = x;
|
|
485
|
-
if (isValueFilteredOut(x)) {
|
|
486
|
-
return null;
|
|
487
|
-
}
|
|
488
|
-
else {
|
|
489
|
-
return (React.createElement(ListGroupItem, { className: "Available", style: listGroupItemStyle, active: isActive, index: index, draggable: true, key: `${value}-item`, onDragStart: (event) => DragAvailableStart(event, x), onDragEnd: () => DragAvailableEnd(), value: value }, x));
|
|
490
|
-
}
|
|
491
|
-
});
|
|
492
|
-
const headerFirstListBox = (React.createElement(ListBoxFilterSortComponent, { FilterValue: state.FilterValue, sortColumnValues: sortColumnValues, SortOrder: state.SortOrder, handleChangeFilterValue: handleChangeFilterValue }));
|
|
493
|
-
const headerSecondListBox = (React.createElement(ListBoxFilterSortComponent, { FilterValue: state.SelectedValuesFilterValue, sortColumnValues: sortSelectedColumnValues, SortOrder: state.SelectedValuesSortOrder, handleChangeFilterValue: handleChangeSelectedValuesFilterValue }));
|
|
494
|
-
return (React.createElement(Flex, { alignItems: "stretch", flexDirection: "row", className: "ab-DualListBoxEditor", style: { ...props.style, maxHeight: '100%', width: '100%' } },
|
|
495
|
-
React.createElement(Panel, { header: props.HeaderAvailable, className: "ab-DualListBoxEditor__source", bodyProps: { padding: 0 }, marginRight: 2, style: { flex: '4 0 0%' }, bodyScroll: true },
|
|
496
|
-
headerFirstListBox,
|
|
497
|
-
React.createElement(SelectableList, { getItemId: getAvailableItemId, onSelectedChange: onAvailableListSelectionChange },
|
|
498
|
-
React.createElement(ListGroup, { className: "ab-AvailableDropZone", style: listGroupStyle, onDragEnter: (event) => DragEnterAvailable(event), onDragOver: (event) => DragOverAvailable(event), onDragLeave: (event) => DragLeaveAvailable(event) }, availableElements))),
|
|
499
|
-
React.createElement(Flex, { flexDirection: "column", justifyContent: "center", className: "ab-DualListBoxEditor__action-buttons" },
|
|
500
|
-
React.createElement(ButtonDirection, { "data-name": "add-all", marginBottom: 2, icon: "fast-forward", iconPosition: "end", disabled: state.AvailableValues.length == 0, onClick: () => AddAll() }, "Add All"),
|
|
501
|
-
React.createElement(ButtonDirection, { "data-name": "add", iconPosition: "end", icon: 'arrow-right', marginBottom: 3, disabled: state.UiSelectedAvailableValues.length == 0, onClick: () => Add() }, "Add"),
|
|
502
|
-
React.createElement(ButtonDirection, { "data-name": "remove", icon: 'arrow-left', marginBottom: 2, iconPosition: "start", disabled: state.UiSelectedSelectedValues.length == 0, onClick: () => Remove() }, "Remove"),
|
|
503
|
-
React.createElement(ButtonDirection, { "data-name": "remove-all", marginBottom: 2, icon: "fast-backward", iconPosition: "start", disabled: state.SelectedValues.length == 0, onClick: () => RemoveAll() }, "Remove All")),
|
|
504
|
-
React.createElement(Panel, { header: props.HeaderSelected, className: "ab-DualListBoxEditor__destination", bodyScroll: true, bodyProps: {
|
|
505
|
-
padding: 0,
|
|
506
|
-
}, style: { flex: '4 0 0%' }, marginLeft: 2, marginRight: 2 },
|
|
507
|
-
headerSecondListBox,
|
|
508
|
-
React.createElement(SelectableList, { getItemId: getSelectedItemId, onSelectedChange: onSelectedListSelectionChange },
|
|
509
|
-
React.createElement(ListGroup, { style: listGroupStyle, className: "ab-SelectedDropZone", onDragEnter: (event) => DragEnterSelected(event), onDragOver: (event) => DragOverSelected(event), onDragLeave: (event) => DragLeaveSelected(event) }, selectedElements))),
|
|
510
|
-
React.createElement(Flex, { flexDirection: "column", justifyContent: "center", className: "ab-DualListBoxEditor__order-buttons" },
|
|
511
|
-
React.createElement(ButtonDirection, { "data-name": "top", marginBottom: 2, iconPosition: "start", icon: "triangle-up", disabled: !canGoTopOrUp(), onClick: () => Top() }, "Top"),
|
|
512
|
-
React.createElement(ButtonDirection, { "data-name": "up", marginBottom: 2, iconPosition: "start", icon: "arrow-up", disabled: !canGoTopOrUp(), onClick: () => Up() }, "Up"),
|
|
513
|
-
React.createElement(ButtonDirection, { "data-name": "down", marginBottom: 2, icon: "arrow-down", iconPosition: "start", disabled: !canGoDownOrBottom(), onClick: () => Down() }, "Down"),
|
|
514
|
-
React.createElement(ButtonDirection, { "data-name": "bottom", marginBottom: 2, icon: "triangle-down", iconPosition: "start", disabled: !canGoDownOrBottom(), onClick: () => Bottom() }, "Bottom"))));
|
|
515
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { SortOrder } from '../../../AdaptableState/Common/Enums';
|
|
3
|
-
export interface ListBoxFilterSortComponentProps extends React.ClassAttributes<ListBoxFilterSortComponent> {
|
|
4
|
-
FilterValue: string;
|
|
5
|
-
SortOrder: SortOrder;
|
|
6
|
-
handleChangeFilterValue: (value: string) => void;
|
|
7
|
-
sortColumnValues: () => void;
|
|
8
|
-
}
|
|
9
|
-
export declare class ListBoxFilterSortComponent extends React.Component<ListBoxFilterSortComponentProps, {}> {
|
|
10
|
-
render(): React.JSX.Element;
|
|
11
|
-
handleChangeFilterValue(x: React.FormEvent<any>): void;
|
|
12
|
-
clearFilter(): void;
|
|
13
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { SortOrder } from '../../../AdaptableState/Common/Enums';
|
|
3
|
-
import SimpleButton from '../../../components/SimpleButton';
|
|
4
|
-
import Input from '../../../components/Input';
|
|
5
|
-
import FieldWrap from '../../../components/FieldWrap';
|
|
6
|
-
export class ListBoxFilterSortComponent extends React.Component {
|
|
7
|
-
render() {
|
|
8
|
-
return (React.createElement(FieldWrap, { className: "ab-SingleListBoxFilter", style: {
|
|
9
|
-
borderTop: 0,
|
|
10
|
-
borderRight: 0,
|
|
11
|
-
borderLeft: 0,
|
|
12
|
-
borderRadius: 0,
|
|
13
|
-
padding: 2 /* here just for the focus box-shadow to be visible*/,
|
|
14
|
-
} },
|
|
15
|
-
React.createElement(Input, { value: this.props.FilterValue, placeholder: "Search", onChange: (e) => this.handleChangeFilterValue(e), style: { width: 0 } }),
|
|
16
|
-
React.createElement(SimpleButton, { disabled: !this.props.FilterValue, onClick: () => this.clearFilter(), icon: "close", variant: "text" }),
|
|
17
|
-
this.props.SortOrder == SortOrder.Asc ? (React.createElement(SimpleButton, { onClick: () => this.props.sortColumnValues(), icon: "sort-asc", variant: "text" })) : (React.createElement(SimpleButton, { onClick: () => this.props.sortColumnValues(), icon: "sort-desc", variant: "text" }))));
|
|
18
|
-
}
|
|
19
|
-
handleChangeFilterValue(x) {
|
|
20
|
-
let e = x.target;
|
|
21
|
-
this.props.handleChangeFilterValue(e.value);
|
|
22
|
-
}
|
|
23
|
-
clearFilter() {
|
|
24
|
-
this.props.handleChangeFilterValue('');
|
|
25
|
-
}
|
|
26
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { AdaptableWizardStep, AdaptableWizardStepProps } from '../../Wizard/Interface/IAdaptableWizard';
|
|
3
|
-
import { CustomSort } from '../../../AdaptableState/CustomSortState';
|
|
4
|
-
export interface CustomSortSummaryWizardProps extends AdaptableWizardStepProps<CustomSort> {
|
|
5
|
-
}
|
|
6
|
-
export declare class CustomSortSummaryWizard extends React.Component<CustomSortSummaryWizardProps, {}> implements AdaptableWizardStep {
|
|
7
|
-
constructor(props: CustomSortSummaryWizardProps);
|
|
8
|
-
render(): any;
|
|
9
|
-
canNext(): boolean;
|
|
10
|
-
canBack(): boolean;
|
|
11
|
-
next(): void;
|
|
12
|
-
back(): void;
|
|
13
|
-
getIndexStepIncrement(): number;
|
|
14
|
-
getIndexStepDecrement(): number;
|
|
15
|
-
}
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { WizardSummaryPage } from '../../Components/WizardSummaryPage';
|
|
3
|
-
export class CustomSortSummaryWizard extends React.Component {
|
|
4
|
-
constructor(props) {
|
|
5
|
-
super(props);
|
|
6
|
-
}
|
|
7
|
-
render() {
|
|
8
|
-
let keyValuePairs = [
|
|
9
|
-
{
|
|
10
|
-
Key: 'Column',
|
|
11
|
-
Value: this.props.api.columnApi.getFriendlyNameForColumnId(this.props.data.ColumnId),
|
|
12
|
-
},
|
|
13
|
-
{ Key: 'In', Value: this.props.data.SortedValues.join(', ') },
|
|
14
|
-
];
|
|
15
|
-
return (React.createElement(WizardSummaryPage, { KeyValuePairs: keyValuePairs, header: this.props.moduleInfo.FriendlyName }));
|
|
16
|
-
}
|
|
17
|
-
canNext() {
|
|
18
|
-
return true;
|
|
19
|
-
}
|
|
20
|
-
canBack() {
|
|
21
|
-
return true;
|
|
22
|
-
}
|
|
23
|
-
next() { }
|
|
24
|
-
back() { }
|
|
25
|
-
getIndexStepIncrement() {
|
|
26
|
-
return 1;
|
|
27
|
-
}
|
|
28
|
-
getIndexStepDecrement() {
|
|
29
|
-
return 1;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { AdaptableColumnProperties } from '../../../../AdaptableState/Common/AdaptableColumn';
|
|
3
|
-
export declare const ColumnLabels: (props: AdaptableColumnProperties & {
|
|
4
|
-
children?: React.ReactNode;
|
|
5
|
-
labels?: Record<string, React.ReactNode>;
|
|
6
|
-
flexDirection?: 'row' | 'column';
|
|
7
|
-
showBoth?: boolean;
|
|
8
|
-
showTitle?: boolean;
|
|
9
|
-
}) => React.JSX.Element;
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Flex, Text } from 'rebass';
|
|
3
|
-
import { useAdaptable } from '../../../AdaptableContext';
|
|
4
|
-
export const ColumnLabels = (props) => {
|
|
5
|
-
const { children, showBoth, showTitle, flexDirection = 'row', labels: labelsProp, ...columnProperties } = props;
|
|
6
|
-
const labelNames = [
|
|
7
|
-
'Aggregatable',
|
|
8
|
-
'Filterable',
|
|
9
|
-
'Groupable',
|
|
10
|
-
'Moveable',
|
|
11
|
-
'Pivotable',
|
|
12
|
-
'Sortable',
|
|
13
|
-
];
|
|
14
|
-
const labels = labelNames.map((name) => columnProperties[name.toLocaleLowerCase()] ? name.charAt(0) : '');
|
|
15
|
-
const flexProps = {
|
|
16
|
-
[flexDirection === 'row' ? 'alignItems' : 'justifyContent']: 'center',
|
|
17
|
-
};
|
|
18
|
-
return (React.createElement(Flex, { className: "ab-LayoutEditor__Legend", flexDirection: flexDirection, ...flexProps, width: "100%" },
|
|
19
|
-
showTitle ? (React.createElement(Text, { mr: 2 }, useAdaptable().api.internalApi.getCorrectEnglishVariant('Behaviours:'))) : null,
|
|
20
|
-
labels.map((l, index) => {
|
|
21
|
-
const enabled = !!l;
|
|
22
|
-
const labelName = labelNames[index];
|
|
23
|
-
const letter = labelName.charAt(0);
|
|
24
|
-
const renderBox = (enabled, key) => {
|
|
25
|
-
return (React.createElement(Flex, { className: "ab-LayoutEditor__LegendLetter", width: '20px', height: '20px', alignItems: "center", justifyContent: "center", fontSize: 2, ml: 2, backgroundColor: "defaultbackground", title: enabled ? labelName : `Not ${labelName}`, style: {
|
|
26
|
-
overflow: 'hidden',
|
|
27
|
-
cursor: 'auto',
|
|
28
|
-
position: 'relative',
|
|
29
|
-
fontWeight: 600,
|
|
30
|
-
lineHeight: 0,
|
|
31
|
-
border: `1px solid var(--ab-color-${enabled ? 'accent' : 'inputborder'})`,
|
|
32
|
-
borderRadius: 'var(--ab__border-radius)',
|
|
33
|
-
opacity: enabled ? 1 : 0.5,
|
|
34
|
-
}, key: `${letter}${key ? key : ''}` },
|
|
35
|
-
!enabled ? (React.createElement("div", { style: {
|
|
36
|
-
background: 'currentColor',
|
|
37
|
-
position: 'absolute',
|
|
38
|
-
bottom: '-100%',
|
|
39
|
-
right: 0,
|
|
40
|
-
width: 2,
|
|
41
|
-
height: '200%',
|
|
42
|
-
transform: 'skewX(45deg)',
|
|
43
|
-
} })) : null,
|
|
44
|
-
letter));
|
|
45
|
-
};
|
|
46
|
-
return (React.createElement(Flex, { key: letter, mt: flexDirection === 'row' ? 0 : 2, flexDirection: "row", alignItems: "center" },
|
|
47
|
-
renderBox(enabled),
|
|
48
|
-
showBoth ? renderBox(!enabled, 'label') : null,
|
|
49
|
-
labelsProp ? (React.createElement(Flex, { key: "labelProps", flex: 1, ml: 2, className: "ab-LayoutEditor__LegendLetterDescription" }, labelsProp[labelName])) : null));
|
|
50
|
-
}),
|
|
51
|
-
children));
|
|
52
|
-
};
|