@adaptabletools/adaptable 10.0.4-canary.1 → 10.0.4-canary.2
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/LICENSE.md +1 -1
- package/README.md +1 -1
- package/base.css +16 -6
- package/bundle.cjs.js +350 -0
- package/index.css +20 -6
- package/package.json +1 -5
- package/publishTimestamp.d.ts +1 -1
- package/publishTimestamp.js +1 -1
- package/src/AdaptableInterfaces/AdaptableNoCodeWizard.d.ts +1 -1
- package/src/AdaptableInterfaces/IAdaptable.d.ts +14 -12
- package/src/AdaptableOptions/AdaptableOptions.d.ts +3 -3
- package/src/AdaptableOptions/ContainerOptions.d.ts +4 -5
- package/src/AdaptableOptions/DataChangeHistoryOptions.d.ts +1 -1
- package/src/AdaptableOptions/DateInputOptions.d.ts +5 -1
- package/src/AdaptableOptions/EditOptions.d.ts +2 -3
- package/src/AdaptableOptions/FilterOptions.d.ts +8 -8
- package/src/AdaptableOptions/GeneralOptions.d.ts +3 -2
- package/src/AdaptableOptions/MenuOptions.d.ts +11 -11
- package/src/AdaptableOptions/NotificationsOptions.d.ts +8 -0
- package/src/AdaptableOptions/ToolPanelOptions.d.ts +2 -2
- package/src/AdaptableOptions/UserInterfaceOptions.d.ts +3 -3
- package/src/Api/AdaptableApi.d.ts +12 -12
- package/src/Api/ColumnApi.d.ts +10 -5
- package/src/Api/EventApi.d.ts +1 -1
- package/src/Api/Events/AdaptableReady.d.ts +3 -2
- package/src/Api/GridApi.d.ts +10 -10
- package/src/Api/Implementation/ColumnApiImpl.d.ts +4 -3
- package/src/Api/Implementation/ColumnApiImpl.js +11 -9
- package/src/Api/Implementation/ConfigApiImpl.js +0 -24
- package/src/Api/Implementation/GridApiImpl.d.ts +2 -2
- package/src/Api/Implementation/GridApiImpl.js +3 -4
- package/src/Api/Implementation/InternalApiImpl.d.ts +1 -1
- package/src/Api/Implementation/InternalApiImpl.js +2 -2
- package/src/Api/Implementation/LayoutApiImpl.d.ts +2 -0
- package/src/Api/Implementation/LayoutApiImpl.js +15 -0
- package/src/Api/Implementation/PluginsApiImpl.d.ts +2 -2
- package/src/Api/Implementation/PluginsApiImpl.js +1 -1
- package/src/Api/Implementation/ScheduleApiImpl.js +6 -6
- package/src/Api/Implementation/ToolPanelApiImpl.js +1 -1
- package/src/Api/Implementation/UserInterfaceApiImpl.d.ts +3 -3
- package/src/Api/Implementation/UserInterfaceApiImpl.js +4 -4
- package/src/Api/InternalApi.d.ts +1 -1
- package/src/Api/LayoutApi.d.ts +7 -0
- package/src/Api/PluginsApi.d.ts +1 -7
- package/src/Api/TeamSharingApi.d.ts +1 -1
- package/src/Api/ThemeApi.d.ts +2 -2
- package/src/Api/UserInterfaceApi.d.ts +3 -3
- package/src/PredefinedConfig/AdaptableState.d.ts +2 -10
- package/src/PredefinedConfig/AlertState.d.ts +1 -1
- package/src/PredefinedConfig/ApplicationState.d.ts +1 -1
- package/src/PredefinedConfig/CalculatedColumnState.d.ts +1 -1
- package/src/PredefinedConfig/Common/AdaptableColumn.d.ts +3 -3
- package/src/PredefinedConfig/Common/AdaptablePredicate.d.ts +4 -4
- package/src/PredefinedConfig/Common/AdaptableStyle.d.ts +7 -7
- package/src/PredefinedConfig/Common/DataChangedInfo.d.ts +1 -1
- package/src/PredefinedConfig/Common/Menu.d.ts +40 -17
- package/src/PredefinedConfig/Common/SpecialColumnSettings.d.ts +1 -1
- package/src/PredefinedConfig/Common/Types.d.ts +5 -5
- package/src/PredefinedConfig/Common/Types.js +9 -7
- package/src/PredefinedConfig/ConditionalStyleState.d.ts +1 -1
- package/src/PredefinedConfig/CustomSortState.d.ts +1 -1
- package/src/PredefinedConfig/DataSourceState.d.ts +1 -1
- package/src/PredefinedConfig/ExportState.d.ts +3 -3
- package/src/PredefinedConfig/FilterState.d.ts +2 -2
- package/src/PredefinedConfig/FormatColumnState.d.ts +1 -1
- package/src/PredefinedConfig/FreeTextColumnState.d.ts +1 -1
- package/src/PredefinedConfig/LayoutState.d.ts +1 -1
- package/src/PredefinedConfig/PredefinedConfig.d.ts +0 -40
- package/src/PredefinedConfig/QuickSearchState.d.ts +3 -3
- package/src/PredefinedConfig/ScheduleState.d.ts +1 -1
- package/src/PredefinedConfig/ThemeState.d.ts +5 -1
- package/src/Redux/ActionsReducers/DashboardRedux.js +2 -1
- package/src/Redux/ActionsReducers/GridRedux.d.ts +3 -2
- package/src/Redux/ActionsReducers/GridRedux.js +2 -2
- package/src/Redux/ActionsReducers/LayoutRedux.d.ts +12 -2
- package/src/Redux/ActionsReducers/LayoutRedux.js +24 -1
- package/src/Redux/DeadRedux.d.ts +4 -8
- package/src/Redux/Store/AdaptableReduxLocalStorageEngine.js +6 -1
- package/src/Redux/Store/AdaptableStore.d.ts +3 -3
- package/src/Redux/Store/AdaptableStore.js +18 -13
- package/src/Strategy/AdaptableModuleBase.d.ts +2 -2
- package/src/Strategy/AlertModule.d.ts +2 -2
- package/src/Strategy/AlertModule.js +1 -94
- package/src/Strategy/BulkUpdateModule.d.ts +2 -2
- package/src/Strategy/BulkUpdateModule.js +4 -4
- package/src/Strategy/CellSummaryModule.d.ts +2 -2
- package/src/Strategy/DashboardModule.d.ts +2 -2
- package/src/Strategy/DataChangeHistoryModule.js +2 -2
- package/src/Strategy/ExportModule.d.ts +2 -2
- package/src/Strategy/FilterModule.d.ts +2 -2
- package/src/Strategy/FormatColumnModule.js +1 -1
- package/src/Strategy/GridInfoModule.d.ts +2 -2
- package/src/Strategy/Interface/IModule.d.ts +2 -2
- package/src/Strategy/LayoutModule.d.ts +2 -2
- package/src/Strategy/LayoutModule.js +21 -8
- package/src/Strategy/SmartEditModule.d.ts +2 -2
- package/src/Strategy/SmartEditModule.js +3 -4
- package/src/Strategy/SystemStatusModule.d.ts +2 -2
- package/src/Utilities/Constants/GeneralConstants.d.ts +1 -0
- package/src/Utilities/Constants/GeneralConstants.js +2 -1
- package/src/Utilities/Constants/ModuleConstants.d.ts +6 -6
- package/src/Utilities/Constants/ModuleConstants.js +7 -7
- package/src/Utilities/Defaults/DefaultAdaptableOptions.js +8 -7
- package/src/Utilities/Helpers/PreviewHelper.js +2 -2
- package/src/Utilities/Interface/Preview.d.ts +2 -1
- package/src/Utilities/Services/LicenseService.js +16 -2
- package/src/Utilities/Services/ValidationService.js +1 -1
- package/src/View/AdaptableViewFactory.d.ts +2 -1
- package/src/View/AdaptableViewFactory.js +2 -0
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ConfigurationForm.js +7 -7
- package/src/View/CellSummary/CellSummaryViewPanel.js +2 -2
- package/src/View/Components/FilterForm/FilterForm.js +5 -7
- package/src/View/Components/FilterForm/ListBoxFilterForm.d.ts +1 -1
- package/src/View/Components/FilterForm/ListBoxFilterForm.js +7 -7
- package/src/View/Components/FilterForm/QuickFilterForm.js +3 -5
- package/src/View/Components/Panels/FilterFormPanel.d.ts +1 -1
- package/src/View/Components/Panels/PanelWithImage.d.ts +423 -1
- package/src/View/Components/Popups/AdaptablePopupAlert.js +22 -9
- package/src/View/Components/ToolPanel/AdaptableToolPanel.js +3 -4
- package/src/View/Components/ToolPanel/ToolPanelPopup.js +2 -3
- package/src/View/CustomSort/CustomSortEntityRow.d.ts +3 -1
- package/src/View/CustomSort/CustomSortEntityRow.js +3 -3
- package/src/View/CustomSort/CustomSortPopup.js +1 -1
- package/src/View/CustomSort/Wizard/CustomSortColumnWizardSection.js +1 -1
- package/src/View/Dashboard/Dashboard.js +3 -3
- package/src/View/DataChangeHistory/DataChangeHistoryGrid.d.ts +1 -1
- package/src/View/DataChangeHistory/DataChangeHistoryGrid.js +6 -5
- package/src/View/DataChangeHistory/DataChangeHistoryPopup.js +6 -6
- package/src/View/Export/ExportViewPanel.js +6 -6
- package/src/View/GridInfo/GridOptionsComponent.js +1 -1
- package/src/View/Layout/LayoutViewPanel.js +2 -2
- package/src/View/Query/QueryViewPanel.js +1 -1
- package/src/View/QuickSearch/useQuickSearchDebounced.js +2 -3
- package/src/View/Schedule/SchedulePopup.js +3 -3
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsWizard.js +1 -1
- package/src/View/SmartEdit/SmartEditPopup.js +1 -1
- package/src/View/StateManagement/StateManagementPopup.d.ts +2 -12
- package/src/View/StateManagement/StateManagementPopup.js +21 -114
- package/src/View/StateManagement/StateManagementViewPanel.d.ts +5 -0
- package/src/View/StateManagement/StateManagementViewPanel.js +22 -0
- package/src/View/StateManagement/components/ClearButton.d.ts +6 -0
- package/src/View/StateManagement/components/ClearButton.js +9 -0
- package/src/View/StateManagement/components/ExportDropdown.d.ts +8 -0
- package/src/View/StateManagement/components/ExportDropdown.js +43 -0
- package/src/View/StateManagement/components/LoadButton.d.ts +7 -0
- package/src/View/StateManagement/components/LoadButton.js +38 -0
- package/src/View/StateManagement/handleExportState.d.ts +1 -0
- package/src/View/StateManagement/handleExportState.js +22 -0
- package/src/View/Theme/ThemeViewPanel.js +1 -1
- package/src/agGrid/Adaptable.d.ts +9 -8
- package/src/agGrid/Adaptable.js +99 -78
- package/src/agGrid/agGridHelper.d.ts +4 -4
- package/src/agGrid/agGridHelper.js +15 -16
- package/src/agGrid/agGridMenuHelper.d.ts +15 -13
- package/src/agGrid/agGridMenuHelper.js +53 -45
- package/src/agGrid/editors/AdaptableDateEditor/InternalAdaptableDateEditor.d.ts +1 -1
- package/src/agGrid/editors/AdaptableDateEditor/InternalAdaptableDateEditor.js +11 -6
- package/src/agGrid/editors/AdaptableDateEditor/index.d.ts +3 -2
- package/src/agGrid/editors/AdaptableDateEditor/index.js +16 -6
- package/src/agGrid/editors/AdaptableNumberEditor/index.d.ts +1 -0
- package/src/agGrid/editors/AdaptableNumberEditor/index.js +7 -2
- package/src/components/Datepicker/DatepickerContext.d.ts +2 -2
- package/src/components/Datepicker/index.js +9 -5
- package/src/components/Modal/index.d.ts +1 -1
- package/src/components/OverlayTrigger/index.js +3 -3
- package/src/components/OverlayTrigger/useAgGridClassName.d.ts +2 -0
- package/src/components/OverlayTrigger/{useVendorClassName.js → useAgGridClassName.js} +3 -3
- package/src/components/ProgressIndicator/ProgressIndicator.js +1 -1
- package/src/components/icons/index.js +2 -0
- package/src/components/icons/upload.d.ts +3 -0
- package/src/components/icons/upload.js +8 -0
- package/src/metamodel/adaptable.metamodel.d.ts +52 -37
- package/src/metamodel/adaptable.metamodel.js +261 -265
- package/src/types.d.ts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/src/PredefinedConfig/DeprecatedState.d.ts +0 -82
- package/src/PredefinedConfig/DeprecatedState.js +0 -5
- package/src/components/OverlayTrigger/useVendorClassName.d.ts +0 -2
|
@@ -109,12 +109,11 @@ class SmartEditModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
109
109
|
BuildPreviewValues(smartEditValue, smartEditOperation) {
|
|
110
110
|
let selectedCellInfo = this.api.gridApi.getSelectedCellInfo();
|
|
111
111
|
let previewResults = [];
|
|
112
|
-
let
|
|
112
|
+
let column;
|
|
113
113
|
if (!this.api.internalApi.isGridInPivotMode()) {
|
|
114
114
|
if (ArrayExtensions_1.default.IsNotNullOrEmpty(selectedCellInfo.columns)) {
|
|
115
|
-
|
|
115
|
+
column = this.api.columnApi.getColumnFromId(selectedCellInfo.columns[0].columnId);
|
|
116
116
|
if (column) {
|
|
117
|
-
columnId = column.columnId;
|
|
118
117
|
selectedCellInfo.gridCells.forEach((selectedCell) => {
|
|
119
118
|
let newValue;
|
|
120
119
|
switch (smartEditOperation) {
|
|
@@ -159,7 +158,7 @@ class SmartEditModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
159
158
|
}
|
|
160
159
|
}
|
|
161
160
|
return {
|
|
162
|
-
|
|
161
|
+
column: column,
|
|
163
162
|
previewResults: previewResults,
|
|
164
163
|
previewValidationSummary: PreviewHelper_1.PreviewHelper.GetPreviewValidationSummary(previewResults),
|
|
165
164
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { AdaptableModuleBase } from './AdaptableModuleBase';
|
|
2
|
-
import { AdaptableMenuItem,
|
|
2
|
+
import { AdaptableMenuItem, ContextMenuContext } from '../PredefinedConfig/Common/Menu';
|
|
3
3
|
import { AdaptableColumn } from '../PredefinedConfig/Common/AdaptableColumn';
|
|
4
4
|
import { IModule } from './Interface/IModule';
|
|
5
5
|
import { AdaptableApi } from '../Api/AdaptableApi';
|
|
6
6
|
export declare class SystemStatusModule extends AdaptableModuleBase implements IModule {
|
|
7
7
|
constructor(api: AdaptableApi);
|
|
8
8
|
addColumnMenuItems(column: AdaptableColumn): AdaptableMenuItem[] | undefined;
|
|
9
|
-
addContextMenuItems(menuContext:
|
|
9
|
+
addContextMenuItems(menuContext: ContextMenuContext): AdaptableMenuItem[] | undefined;
|
|
10
10
|
}
|
|
@@ -25,6 +25,7 @@ export declare const SYSTEM_STATUS_DEFAULT_MAX_MESSAGES_IN_STORE: number;
|
|
|
25
25
|
export declare const CHART_DEFAULT_REFRESH_RATE: number;
|
|
26
26
|
export declare const QUICK_SEARCH_DEFAULT_BACK_COLOR: string;
|
|
27
27
|
export declare const QUICK_SEARCH_DEFAULT_FORE_COLOR: string;
|
|
28
|
+
export declare const QUICK_SEARCH_DEBOUNCE_TIME: number;
|
|
28
29
|
export declare const CELL_SUMMARY_DEFAULT_OPERATION: SummaryOperation | string;
|
|
29
30
|
export declare const SYSTEM_DEFAULT_CHART_VISIBILITY: ChartVisibility;
|
|
30
31
|
export declare const SYSTEM_DEFAULT_SYSTEM_STATUS_TYPE: AdaptableMessageType;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.THEME_STYLE = exports.SELECTED_ROWS_REPORT = exports.SELECTED_CELLS_REPORT = exports.CURRENT_DATA_REPORT = exports.ALL_DATA_REPORT = exports.VISUAL_DATA_REPORT = exports.SYSTEM_THEMES = exports.SMART_EDIT_MATH_OPERATION_STATE_PROPERTY = exports.SMART_EDIT_VALUE_STATE_PROPERTY = exports.QUICK_SEARCH_STYLE_STATE_PROPERTY = exports.QUICK_SEARCH_TEXT_STATE_PROPERTY = exports.CURRENT_THEME_STATE_PROPERTY = exports.FLASHING_CELL_DEFAULT_DURATION_STATE_PROPERTY = exports.FLASHING_CELL_DEFAULT_DOWN_COLOR_STATE_PROPERTY = exports.FLASHING_CELL_DEFAULT_UP_COLOR_STATE_PROPERTY = exports.CURRENT_REPORT_STATE_PROPERTY = exports.CURRENT_DATA_SOURCE_STATE_PROPERTY = exports.CURRENT_LAYOUT_STATE_PROPERTY = exports.SUMMARY_OPERATION_STATE_PROPERTY = exports.CURRENT_CHART_NAME_STATE_PROPERTY = exports.ALERT_DEFAULT_LOG_TO_CONSOLE = exports.ALERT_DEFAULT_HIGHLIGHT_ROW = exports.ALERT_DEFAULT_HIGHLIGHT_CELL = exports.ALERT_DEFAULT_SHOW_POPUP = exports.ALERT_DEFAULT_MESSAGE_TYPE = exports.ALERT_DEFAULT_RANGE_OPERAND_TYPE = exports.PLUS_MINUS_DEFAULT_NUDGE_VALUE = exports.CHART_DEFAULT_YAXIS_TOTAL = exports.DEFAULT_LIVE_REPORT_THROTTLE_TIME = exports.THEME_DEFAULT_CURRENT_THEME = exports.SYSTEM_DEFAULT_SYSTEM_STATUS_TYPE = exports.SYSTEM_DEFAULT_CHART_VISIBILITY = exports.CELL_SUMMARY_DEFAULT_OPERATION = exports.QUICK_SEARCH_DEFAULT_FORE_COLOR = exports.QUICK_SEARCH_DEFAULT_BACK_COLOR = exports.CHART_DEFAULT_REFRESH_RATE = exports.SYSTEM_STATUS_DEFAULT_MAX_MESSAGES_IN_STORE = exports.AG_GRID_GROUPED_COLUMN = exports.HALF_SECOND = exports.AB_SPECIAL_COLUMN = exports.EMPTY_ARRAY = exports.EMPTY_STRING = exports.FILTER_THROTTLE = exports.FILTER_NEVER = exports.FILTER_ALWAYS = exports.ALL_COLUMN_VALUES = exports.READ_ONLY_STYLE = exports.MENU_PREFIX = exports.ADAPTABLE = exports.ADAPTABLE_ID = exports.USER_NAME = exports.DARK_THEME = exports.LIGHT_THEME = exports.DEFAULT_LAYOUT = exports.MISSING_COLUMN = exports.AUTOGENERATED_PK_COLUMN = void 0;
|
|
3
|
+
exports.THEME_STYLE = exports.SELECTED_ROWS_REPORT = exports.SELECTED_CELLS_REPORT = exports.CURRENT_DATA_REPORT = exports.ALL_DATA_REPORT = exports.VISUAL_DATA_REPORT = exports.SYSTEM_THEMES = exports.SMART_EDIT_MATH_OPERATION_STATE_PROPERTY = exports.SMART_EDIT_VALUE_STATE_PROPERTY = exports.QUICK_SEARCH_STYLE_STATE_PROPERTY = exports.QUICK_SEARCH_TEXT_STATE_PROPERTY = exports.CURRENT_THEME_STATE_PROPERTY = exports.FLASHING_CELL_DEFAULT_DURATION_STATE_PROPERTY = exports.FLASHING_CELL_DEFAULT_DOWN_COLOR_STATE_PROPERTY = exports.FLASHING_CELL_DEFAULT_UP_COLOR_STATE_PROPERTY = exports.CURRENT_REPORT_STATE_PROPERTY = exports.CURRENT_DATA_SOURCE_STATE_PROPERTY = exports.CURRENT_LAYOUT_STATE_PROPERTY = exports.SUMMARY_OPERATION_STATE_PROPERTY = exports.CURRENT_CHART_NAME_STATE_PROPERTY = exports.ALERT_DEFAULT_LOG_TO_CONSOLE = exports.ALERT_DEFAULT_HIGHLIGHT_ROW = exports.ALERT_DEFAULT_HIGHLIGHT_CELL = exports.ALERT_DEFAULT_SHOW_POPUP = exports.ALERT_DEFAULT_MESSAGE_TYPE = exports.ALERT_DEFAULT_RANGE_OPERAND_TYPE = exports.PLUS_MINUS_DEFAULT_NUDGE_VALUE = exports.CHART_DEFAULT_YAXIS_TOTAL = exports.DEFAULT_LIVE_REPORT_THROTTLE_TIME = exports.THEME_DEFAULT_CURRENT_THEME = exports.SYSTEM_DEFAULT_SYSTEM_STATUS_TYPE = exports.SYSTEM_DEFAULT_CHART_VISIBILITY = exports.CELL_SUMMARY_DEFAULT_OPERATION = exports.QUICK_SEARCH_DEBOUNCE_TIME = exports.QUICK_SEARCH_DEFAULT_FORE_COLOR = exports.QUICK_SEARCH_DEFAULT_BACK_COLOR = exports.CHART_DEFAULT_REFRESH_RATE = exports.SYSTEM_STATUS_DEFAULT_MAX_MESSAGES_IN_STORE = exports.AG_GRID_GROUPED_COLUMN = exports.HALF_SECOND = exports.AB_SPECIAL_COLUMN = exports.EMPTY_ARRAY = exports.EMPTY_STRING = exports.FILTER_THROTTLE = exports.FILTER_NEVER = exports.FILTER_ALWAYS = exports.ALL_COLUMN_VALUES = exports.READ_ONLY_STYLE = exports.MENU_PREFIX = exports.ADAPTABLE = exports.ADAPTABLE_ID = exports.USER_NAME = exports.DARK_THEME = exports.LIGHT_THEME = exports.DEFAULT_LAYOUT = exports.MISSING_COLUMN = exports.AUTOGENERATED_PK_COLUMN = void 0;
|
|
4
4
|
const Enums_1 = require("../../PredefinedConfig/Common/Enums");
|
|
5
5
|
const ChartEnums_1 = require("../../PredefinedConfig/Common/ChartEnums");
|
|
6
6
|
const UIHelper_1 = require("../../View/UIHelper");
|
|
@@ -35,6 +35,7 @@ exports.CHART_DEFAULT_REFRESH_RATE = 3; // refresh the chart every 3 seconds if
|
|
|
35
35
|
// Quick Search
|
|
36
36
|
exports.QUICK_SEARCH_DEFAULT_BACK_COLOR = UIHelper_1.getHexForName(UIHelper_1.LIGHT_YELLOW);
|
|
37
37
|
exports.QUICK_SEARCH_DEFAULT_FORE_COLOR = UIHelper_1.getHexForName(UIHelper_1.BLACK);
|
|
38
|
+
exports.QUICK_SEARCH_DEBOUNCE_TIME = 350;
|
|
38
39
|
// Cells Summary
|
|
39
40
|
exports.CELL_SUMMARY_DEFAULT_OPERATION = Enums_1.SummaryOperation.Sum;
|
|
40
41
|
// system
|
|
@@ -4,29 +4,29 @@ export declare const BulkUpdateModuleId: ModuleConstants;
|
|
|
4
4
|
export declare const CalculatedColumnModuleId: ModuleConstants;
|
|
5
5
|
export declare const CellSummaryModuleId: ModuleConstants;
|
|
6
6
|
export declare const ChartModuleId: ModuleConstants;
|
|
7
|
-
export declare const FilterModuleId: ModuleConstants;
|
|
8
7
|
export declare const ConditionalStyleModuleId: ModuleConstants;
|
|
9
8
|
export declare const CustomSortModuleId: ModuleConstants;
|
|
10
9
|
export declare const DashboardModuleId: ModuleConstants;
|
|
10
|
+
export declare const DataChangeHistoryModuleId: ModuleConstants;
|
|
11
11
|
export declare const DataSourceModuleId: ModuleConstants;
|
|
12
12
|
export declare const ExportModuleId: ModuleConstants;
|
|
13
|
+
export declare const FilterModuleId: ModuleConstants;
|
|
13
14
|
export declare const FormatColumnModuleId: ModuleConstants;
|
|
14
15
|
export declare const FreeTextColumnModuleId: ModuleConstants;
|
|
15
|
-
export declare const OpenFinModuleId: ModuleConstants;
|
|
16
16
|
export declare const Glue42ModuleId: ModuleConstants;
|
|
17
|
+
export declare const GridInfoModuleId: ModuleConstants;
|
|
17
18
|
export declare const IPushPullModuleId: ModuleConstants;
|
|
18
19
|
export declare const LayoutModuleId: ModuleConstants;
|
|
19
|
-
export declare const
|
|
20
|
-
export declare const SparklineColumnModuleId: ModuleConstants;
|
|
20
|
+
export declare const OpenFinModuleId: ModuleConstants;
|
|
21
21
|
export declare const PlusMinusModuleId: ModuleConstants;
|
|
22
|
+
export declare const QueryModuleId: ModuleConstants;
|
|
22
23
|
export declare const QuickSearchModuleId: ModuleConstants;
|
|
23
24
|
export declare const ScheduleModuleId: ModuleConstants;
|
|
24
25
|
export declare const ShortcutModuleId: ModuleConstants;
|
|
25
26
|
export declare const SmartEditModuleId: ModuleConstants;
|
|
27
|
+
export declare const SparklineColumnModuleId: ModuleConstants;
|
|
26
28
|
export declare const StateManagementModuleId: ModuleConstants;
|
|
27
29
|
export declare const SystemStatusModuleId: ModuleConstants;
|
|
28
30
|
export declare const TeamSharingModuleId: ModuleConstants;
|
|
29
31
|
export declare const ThemeModuleId: ModuleConstants;
|
|
30
32
|
export declare const ToolPanelModuleId: ModuleConstants;
|
|
31
|
-
export declare const QueryModuleId: ModuleConstants;
|
|
32
|
-
export declare const DataChangeHistoryModuleId: ModuleConstants;
|
|
@@ -1,34 +1,34 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.ToolPanelModuleId = exports.ThemeModuleId = exports.TeamSharingModuleId = exports.SystemStatusModuleId = exports.StateManagementModuleId = exports.SparklineColumnModuleId = exports.SmartEditModuleId = exports.ShortcutModuleId = exports.ScheduleModuleId = exports.QuickSearchModuleId = exports.QueryModuleId = exports.PlusMinusModuleId = exports.OpenFinModuleId = exports.LayoutModuleId = exports.IPushPullModuleId = exports.GridInfoModuleId = exports.Glue42ModuleId = exports.FreeTextColumnModuleId = exports.FormatColumnModuleId = exports.FilterModuleId = exports.ExportModuleId = exports.DataSourceModuleId = exports.DataChangeHistoryModuleId = exports.DashboardModuleId = exports.CustomSortModuleId = exports.ConditionalStyleModuleId = exports.ChartModuleId = exports.CellSummaryModuleId = exports.CalculatedColumnModuleId = exports.BulkUpdateModuleId = exports.AlertModuleId = void 0;
|
|
4
4
|
exports.AlertModuleId = 'Alert';
|
|
5
5
|
exports.BulkUpdateModuleId = 'BulkUpdate';
|
|
6
6
|
exports.CalculatedColumnModuleId = 'CalculatedColumn';
|
|
7
7
|
exports.CellSummaryModuleId = 'CellSummary';
|
|
8
8
|
exports.ChartModuleId = 'Chart';
|
|
9
|
-
exports.FilterModuleId = 'Filter';
|
|
10
9
|
exports.ConditionalStyleModuleId = 'ConditionalStyle';
|
|
11
10
|
exports.CustomSortModuleId = 'CustomSort';
|
|
12
11
|
exports.DashboardModuleId = 'Dashboard';
|
|
12
|
+
exports.DataChangeHistoryModuleId = 'DataChangeHistory';
|
|
13
13
|
exports.DataSourceModuleId = 'DataSource';
|
|
14
14
|
exports.ExportModuleId = 'Export';
|
|
15
|
+
exports.FilterModuleId = 'Filter';
|
|
15
16
|
exports.FormatColumnModuleId = 'FormatColumn';
|
|
16
17
|
exports.FreeTextColumnModuleId = 'FreeTextColumn';
|
|
17
|
-
exports.OpenFinModuleId = 'OpenFin';
|
|
18
18
|
exports.Glue42ModuleId = 'Glue42';
|
|
19
|
+
exports.GridInfoModuleId = 'GridInfo';
|
|
19
20
|
exports.IPushPullModuleId = 'IPushPull';
|
|
20
21
|
exports.LayoutModuleId = 'Layout';
|
|
21
|
-
exports.
|
|
22
|
-
exports.SparklineColumnModuleId = 'SparklineColumn';
|
|
22
|
+
exports.OpenFinModuleId = 'OpenFin';
|
|
23
23
|
exports.PlusMinusModuleId = 'PlusMinus';
|
|
24
|
+
exports.QueryModuleId = 'Query';
|
|
24
25
|
exports.QuickSearchModuleId = 'QuickSearch';
|
|
25
26
|
exports.ScheduleModuleId = 'Schedule';
|
|
26
27
|
exports.ShortcutModuleId = 'Shortcut';
|
|
27
28
|
exports.SmartEditModuleId = 'SmartEdit';
|
|
29
|
+
exports.SparklineColumnModuleId = 'SparklineColumn';
|
|
28
30
|
exports.StateManagementModuleId = 'StateManagement';
|
|
29
31
|
exports.SystemStatusModuleId = 'SystemStatus';
|
|
30
32
|
exports.TeamSharingModuleId = 'TeamSharing';
|
|
31
33
|
exports.ThemeModuleId = 'Theme';
|
|
32
34
|
exports.ToolPanelModuleId = 'ToolPanel';
|
|
33
|
-
exports.QueryModuleId = 'Query';
|
|
34
|
-
exports.DataChangeHistoryModuleId = 'DataChangeHistory';
|
|
@@ -33,6 +33,7 @@ exports.DefaultAdaptableOptions = {
|
|
|
33
33
|
isDraggable: false,
|
|
34
34
|
transition: 'Slide',
|
|
35
35
|
actionHandlers: undefined,
|
|
36
|
+
showApplicationIcon: false,
|
|
36
37
|
flashingAlertDefaultProperties: {
|
|
37
38
|
FlashDuration: 500,
|
|
38
39
|
DownChangeStyle: {
|
|
@@ -50,8 +51,8 @@ exports.DefaultAdaptableOptions = {
|
|
|
50
51
|
},
|
|
51
52
|
containerOptions: {
|
|
52
53
|
adaptableContainer: 'adaptable',
|
|
53
|
-
|
|
54
|
-
|
|
54
|
+
agGridContainer: 'grid',
|
|
55
|
+
agGridContainerWaitTimeout: 60000,
|
|
55
56
|
modalContainer: undefined,
|
|
56
57
|
chartContainer: undefined,
|
|
57
58
|
systemStatusContainer: undefined,
|
|
@@ -117,8 +118,8 @@ exports.DefaultAdaptableOptions = {
|
|
|
117
118
|
showAdaptableContextMenu: true,
|
|
118
119
|
showAdaptableColumnMenu: true,
|
|
119
120
|
showUngroupColumnMenuItem: true,
|
|
120
|
-
columnMenuOrder: ['
|
|
121
|
-
contextMenuOrder: ['
|
|
121
|
+
columnMenuOrder: ['aggrid', 'adaptable', 'user'],
|
|
122
|
+
contextMenuOrder: ['aggrid', 'adaptable', 'user'],
|
|
122
123
|
columnMenuItems: undefined,
|
|
123
124
|
contextMenuItems: undefined,
|
|
124
125
|
},
|
|
@@ -127,7 +128,7 @@ exports.DefaultAdaptableOptions = {
|
|
|
127
128
|
hideQuickFilterInput: undefined,
|
|
128
129
|
indicateFilteredColumns: true,
|
|
129
130
|
useAdaptableFilterForm: true,
|
|
130
|
-
|
|
131
|
+
useAgGridFilterFormStyle: true,
|
|
131
132
|
useAdaptableQuickFilter: true,
|
|
132
133
|
clearFiltersOnStartUp: false,
|
|
133
134
|
quickFilterTrigger: 'mouseenter',
|
|
@@ -203,7 +204,7 @@ exports.DefaultAdaptableOptions = {
|
|
|
203
204
|
width: UIHelper_1.default.getAdaptableToolPanelWidth(),
|
|
204
205
|
minWidth: UIHelper_1.default.getAdaptableToolPanelWidth(),
|
|
205
206
|
maxWidth: undefined,
|
|
206
|
-
toolPanelOrder: ['filters', 'columns', '
|
|
207
|
+
toolPanelOrder: ['filters', 'columns', 'adaptable'],
|
|
207
208
|
},
|
|
208
209
|
queryLanguageOptions: {
|
|
209
210
|
defaultBooleanFunctions: booleanExpressionFunctions_1.booleanExpressionFunctions,
|
|
@@ -217,7 +218,7 @@ exports.DefaultAdaptableOptions = {
|
|
|
217
218
|
},
|
|
218
219
|
dataChangeHistoryOptions: {
|
|
219
220
|
activeByDefault: false,
|
|
220
|
-
|
|
221
|
+
showDataChange: undefined,
|
|
221
222
|
},
|
|
222
223
|
customPredicateDefs: [],
|
|
223
224
|
};
|
|
@@ -43,7 +43,7 @@ function GetCellInfosFromPreview(previewInfo, bypassValidationWarnings) {
|
|
|
43
43
|
displayValue: previewResult.computedValue,
|
|
44
44
|
normalisedValue: previewResult.computedValue,
|
|
45
45
|
rowNode: previewResult.rowNode,
|
|
46
|
-
column:
|
|
46
|
+
column: previewInfo.column,
|
|
47
47
|
});
|
|
48
48
|
}
|
|
49
49
|
}
|
|
@@ -54,7 +54,7 @@ function GetCellInfosFromPreview(previewInfo, bypassValidationWarnings) {
|
|
|
54
54
|
.forEach((pr) => {
|
|
55
55
|
newValues.push({
|
|
56
56
|
primaryKeyValue: pr.id,
|
|
57
|
-
column:
|
|
57
|
+
column: previewInfo.column,
|
|
58
58
|
rawValue: pr.computedValue,
|
|
59
59
|
displayValue: pr.computedValue,
|
|
60
60
|
normalisedValue: pr.computedValue,
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { AlertDefinition } from '../../PredefinedConfig/AlertState';
|
|
2
2
|
import { RowNode } from '@ag-grid-community/all-modules';
|
|
3
|
+
import { AdaptableColumn } from '../../../types';
|
|
3
4
|
export interface PreviewInfo {
|
|
4
|
-
|
|
5
|
+
column: AdaptableColumn;
|
|
5
6
|
previewResults: PreviewResult[];
|
|
6
7
|
previewValidationSummary: PreviewValidationSummary;
|
|
7
8
|
}
|
|
@@ -23,19 +23,33 @@ var LicenseValidityType;
|
|
|
23
23
|
LicenseValidityType["COMMERCIAL_EXPIRED_IN_SCOPE"] = "COMMERCIAL_EXPIRED_IN_SCOPE";
|
|
24
24
|
LicenseValidityType["COMMERCIAL_EXPIRED_OUT_OF_SCOPE"] = "COMMERCIAL_EXPIRED_OUT_OF_SCOPE";
|
|
25
25
|
})(LicenseValidityType = exports.LicenseValidityType || (exports.LicenseValidityType = {}));
|
|
26
|
+
const SANDPACK_REGEX = /(https):\/\/\d+\-\d+\-\d\-(sandpack\.codesandbox\.io)/g;
|
|
27
|
+
const SANDBOX_REGEX = /(https):\/\/\S+(\.csb\.app\/)/g;
|
|
28
|
+
const origin = typeof window !== 'undefined' ? window.location.origin : '';
|
|
29
|
+
const isInsideSandpack = () => {
|
|
30
|
+
const [_fullUrl, protocol, sandpackUrl] = Array.from(SANDPACK_REGEX.exec(origin) || []);
|
|
31
|
+
return protocol === 'https' && sandpackUrl === 'sandpack.codesandbox.io';
|
|
32
|
+
};
|
|
33
|
+
const isInsideSandbox = () => {
|
|
34
|
+
const [_fullUrl, protocol, sandboxUrl] = Array.from(SANDBOX_REGEX.exec(origin) || []);
|
|
35
|
+
return protocol === 'https' && sandboxUrl === '.csb.app/';
|
|
36
|
+
};
|
|
26
37
|
class LicenseService {
|
|
27
38
|
constructor(adaptable, licenseKey, packageDetails) {
|
|
28
39
|
this.adaptable = adaptable;
|
|
29
40
|
this.adaptable = adaptable;
|
|
30
41
|
let details = null;
|
|
31
|
-
if (licenseKey)
|
|
42
|
+
if (licenseKey) {
|
|
32
43
|
try {
|
|
33
44
|
details = decode_1.decode(licenseKey);
|
|
34
45
|
}
|
|
35
46
|
catch (error) {
|
|
36
47
|
details = error;
|
|
37
48
|
}
|
|
38
|
-
|
|
49
|
+
}
|
|
50
|
+
if (!isInsideSandpack() && !isInsideSandbox()) {
|
|
51
|
+
this.handleLicenseValidation(details, this.getValidityType(details, packageDetails));
|
|
52
|
+
}
|
|
39
53
|
}
|
|
40
54
|
getValidityType(details, packageDetails) {
|
|
41
55
|
if (!details) {
|
|
@@ -81,7 +81,7 @@ class ValidationService {
|
|
|
81
81
|
if (!row) {
|
|
82
82
|
return;
|
|
83
83
|
}
|
|
84
|
-
row[(_b = this.adaptable.api.columnApi.
|
|
84
|
+
row[(_b = this.adaptable.api.columnApi.getAgGridColumnFieldForAdaptableColumn(dataChangedInfo.column.columnId)) !== null && _b !== void 0 ? _b : dataChangedInfo.column.columnId] = validationResult.NewValue;
|
|
85
85
|
this.adaptable.api.gridApi.updateGridData([row]);
|
|
86
86
|
if (StringExtensions_1.default.IsNotNullOrEmpty(validationResult.ValidationMessage) &&
|
|
87
87
|
this.adaptable.adaptableOptions.editOptions.displayServerValidationMessages) {
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
1
2
|
import { ConnectedComponent } from 'react-redux';
|
|
2
3
|
import { AdaptableModule } from '../PredefinedConfig/Common/Types';
|
|
3
4
|
export declare const AdaptableViewFactory: IAdaptableViewFactory;
|
|
4
|
-
export declare const AdaptableViewPanelFactory: Map<AdaptableModule, ConnectedComponent<any, any>>;
|
|
5
|
+
export declare const AdaptableViewPanelFactory: Map<AdaptableModule, React.FunctionComponent<any> | ConnectedComponent<any, any>>;
|
|
5
6
|
export interface IAdaptableViewFactory {
|
|
6
7
|
[key: string]: any;
|
|
7
8
|
}
|
|
@@ -44,6 +44,7 @@ const ThemeViewPanel_1 = require("./Theme/ThemeViewPanel");
|
|
|
44
44
|
const DataSourceViewPanel_1 = require("./DataSource/DataSourceViewPanel");
|
|
45
45
|
const DataChangeHistoryPopup_1 = require("./DataChangeHistory/DataChangeHistoryPopup");
|
|
46
46
|
const DataChangeHistoryViewPanel_1 = require("./DataChangeHistory/DataChangeHistoryViewPanel");
|
|
47
|
+
const StateManagementViewPanel_1 = require("./StateManagement/StateManagementViewPanel");
|
|
47
48
|
exports.AdaptableViewFactory = {
|
|
48
49
|
ExpandedQueryPopup: ExpandedQueryPopup_1.ExpandedQueryPopup,
|
|
49
50
|
AlertPopup: AlertPopup_1.AlertPopup,
|
|
@@ -88,4 +89,5 @@ exports.AdaptableViewPanelFactory = new Map([
|
|
|
88
89
|
[ModuleConstants.ThemeModuleId, ThemeViewPanel_1.ThemeViewPanelControl],
|
|
89
90
|
[ModuleConstants.DataSourceModuleId, DataSourceViewPanel_1.DataSourceViewPanelControl],
|
|
90
91
|
[ModuleConstants.DataChangeHistoryModuleId, DataChangeHistoryViewPanel_1.DataChangeHistoryViewPanelControl],
|
|
92
|
+
[ModuleConstants.StateManagementModuleId, StateManagementViewPanel_1.StateManagementViewPanel],
|
|
91
93
|
]);
|
|
@@ -16,7 +16,7 @@ const ConfigurationForm = (props) => {
|
|
|
16
16
|
const searchOptions = Object.assign(Object.assign({}, DefaultAdaptableOptions_1.DefaultAdaptableOptions.searchOptions), abOptions.searchOptions);
|
|
17
17
|
const filterOptions = Object.assign(Object.assign({}, DefaultAdaptableOptions_1.DefaultAdaptableOptions.filterOptions), abOptions.filterOptions);
|
|
18
18
|
// we are 'hard-coding' this to use AG Grid but so does helper so ok for now and we can refactor when Adaptable Grid is ready
|
|
19
|
-
const
|
|
19
|
+
const gridOptions = Object.assign(Object.assign({}, DefaultAdaptableOptions_1.DefaultAdaptableOptions.vendorGrid), abOptions.vendorGrid);
|
|
20
20
|
return (React.createElement(React.Fragment, null,
|
|
21
21
|
React.createElement(HelpBlock_1.default, null, "General Options"),
|
|
22
22
|
React.createElement(FormLayout_1.default, { margin: 2, columns: [{ name: 'children' }, { name: 'label', style: { textAlign: 'start' } }] },
|
|
@@ -30,28 +30,28 @@ const ConfigurationForm = (props) => {
|
|
|
30
30
|
React.createElement(HelpBlock_1.default, null, "Grid Options"),
|
|
31
31
|
React.createElement(FormLayout_1.default, { margin: 2, columns: [{ name: 'children' }, { name: 'label', style: { textAlign: 'start' } }] },
|
|
32
32
|
React.createElement(FormLayout_1.FormRow, { label: "Enable Range Selection" },
|
|
33
|
-
React.createElement(CheckBox_1.CheckBox, { checked:
|
|
33
|
+
React.createElement(CheckBox_1.CheckBox, { checked: gridOptions.enableRangeSelection, onChange: (enableRangeSelection) => {
|
|
34
34
|
abOptions = Object.assign({}, abOptions);
|
|
35
35
|
abOptions.vendorGrid = Object.assign({}, abOptions.vendorGrid);
|
|
36
36
|
abOptions.vendorGrid.enableRangeSelection = enableRangeSelection;
|
|
37
37
|
props.onChangeadaptableOptions(abOptions);
|
|
38
38
|
} })),
|
|
39
39
|
React.createElement(FormLayout_1.FormRow, { label: "Show Quick Filter" },
|
|
40
|
-
React.createElement(CheckBox_1.CheckBox, { checked:
|
|
40
|
+
React.createElement(CheckBox_1.CheckBox, { checked: gridOptions.floatingFilter, onChange: (floatingFilter) => {
|
|
41
41
|
abOptions = Object.assign({}, abOptions);
|
|
42
42
|
abOptions.vendorGrid = Object.assign({}, abOptions.vendorGrid);
|
|
43
43
|
abOptions.vendorGrid.floatingFilter = floatingFilter;
|
|
44
44
|
props.onChangeadaptableOptions(abOptions);
|
|
45
45
|
} })),
|
|
46
46
|
React.createElement(FormLayout_1.FormRow, { label: "Suppress Column Virtualisation" },
|
|
47
|
-
React.createElement(CheckBox_1.CheckBox, { checked:
|
|
47
|
+
React.createElement(CheckBox_1.CheckBox, { checked: gridOptions.suppressColumnVirtualisation, onChange: (suppressColumnVirtualisation) => {
|
|
48
48
|
abOptions = Object.assign({}, abOptions);
|
|
49
49
|
abOptions.vendorGrid = Object.assign({}, abOptions.vendorGrid);
|
|
50
50
|
abOptions.vendorGrid.suppressColumnVirtualisation = suppressColumnVirtualisation;
|
|
51
51
|
props.onChangeadaptableOptions(abOptions);
|
|
52
52
|
} })),
|
|
53
53
|
React.createElement(FormLayout_1.FormRow, { label: "Show Column Menu Button" },
|
|
54
|
-
React.createElement(CheckBox_1.CheckBox, { checked:
|
|
54
|
+
React.createElement(CheckBox_1.CheckBox, { checked: gridOptions.suppressMenuHide, onChange: (suppressMenuHide) => {
|
|
55
55
|
abOptions = Object.assign({}, abOptions);
|
|
56
56
|
abOptions.vendorGrid = Object.assign({}, abOptions.vendorGrid);
|
|
57
57
|
abOptions.vendorGrid.suppressMenuHide = suppressMenuHide;
|
|
@@ -76,10 +76,10 @@ const ConfigurationForm = (props) => {
|
|
|
76
76
|
props.onChangeadaptableOptions(abOptions);
|
|
77
77
|
} })),
|
|
78
78
|
React.createElement(FormLayout_1.FormRow, { label: "Use Vendor Filter Form Style" },
|
|
79
|
-
React.createElement(CheckBox_1.CheckBox, { checked: filterOptions.
|
|
79
|
+
React.createElement(CheckBox_1.CheckBox, { checked: filterOptions.useAgGridFilterFormStyle, onChange: (useAgGridFilterFormStyle) => {
|
|
80
80
|
abOptions = Object.assign({}, abOptions);
|
|
81
81
|
abOptions.filterOptions = Object.assign({}, abOptions.filterOptions);
|
|
82
|
-
abOptions.filterOptions.
|
|
82
|
+
abOptions.filterOptions.useAgGridFilterFormStyle = useAgGridFilterFormStyle;
|
|
83
83
|
props.onChangeadaptableOptions(abOptions);
|
|
84
84
|
} })),
|
|
85
85
|
React.createElement(FormLayout_1.FormRow, { label: "Use Adaptable Quick Filter" },
|
|
@@ -64,8 +64,8 @@ class CellSummaryViewPanelComponent extends React.Component {
|
|
|
64
64
|
};
|
|
65
65
|
const elementType = this.props.viewType === 'Toolbar' ? 'DashboardToolbar' : 'ToolPanel';
|
|
66
66
|
return (React.createElement(rebass_1.Flex, { flexDirection: "row", className: shouldDisable ? GeneralConstants.READ_ONLY_STYLE : `ab-${elementType}__CellSummary__wrap`, flexWrap: this.props.viewType === 'ToolPanel' ? 'wrap' : 'nowrap' },
|
|
67
|
-
React.createElement(rebass_1.Flex,
|
|
68
|
-
React.createElement(DropdownButton_1.default, { style: { fontSize: 'small' }, marginRight: 2, columns: ['label'], className: `ab-${elementType}__CellSummary__select`, items: [...operationMenuItems, ...operationDefinitions], disabled: shouldDisable, variant: "outlined", tone: 'neutral' }, this.props.CellSummaryOperation)),
|
|
67
|
+
React.createElement(rebass_1.Flex, { flex: 1 },
|
|
68
|
+
React.createElement(DropdownButton_1.default, { style: { fontSize: 'small', width: '100%' }, marginRight: 2, columns: ['label'], className: `ab-${elementType}__CellSummary__select`, items: [...operationMenuItems, ...operationDefinitions], disabled: shouldDisable, variant: "outlined", tone: 'neutral' }, this.props.CellSummaryOperation)),
|
|
69
69
|
React.createElement(rebass_1.Flex, { alignItems: "center" }, React.createElement(React.Fragment, null,
|
|
70
70
|
renderOperationValue(),
|
|
71
71
|
this.props.CellSummary != null && this.props.CellSummary.Count > 0 && (React.createElement(AdaptablePopover_1.AdaptablePopover, { className: "ab-ToolPanel__CellSummary__info", bodyText: [cellSummaryPopover], useButton: true, showEvent: 'focus', hideEvent: "blur" }))))));
|
|
@@ -52,8 +52,7 @@ class FilterFormComponent extends React.Component {
|
|
|
52
52
|
static createColumnFilterFromProps(props) {
|
|
53
53
|
let existingColumnFilter = props.columnFilters.find((cf) => cf.ColumnId == props.currentColumn.columnId);
|
|
54
54
|
if (!existingColumnFilter) {
|
|
55
|
-
const filterOptions = props.api.internalApi.getAdaptableOptions()
|
|
56
|
-
.filterOptions;
|
|
55
|
+
const filterOptions = props.api.internalApi.getAdaptableOptions().filterOptions;
|
|
57
56
|
if (filterOptions.defaultFilterFormTab == 'Values') {
|
|
58
57
|
return ObjectFactory_1.ObjectFactory.CreateColumnFilter(props.currentColumn.columnId, 'Values', []);
|
|
59
58
|
}
|
|
@@ -120,8 +119,7 @@ class FilterFormComponent extends React.Component {
|
|
|
120
119
|
render() {
|
|
121
120
|
var _a, _b;
|
|
122
121
|
let isFilterable = this.isFilterable();
|
|
123
|
-
const filterOptions = this.props.api.internalApi.getAdaptableOptions()
|
|
124
|
-
.filterOptions;
|
|
122
|
+
const filterOptions = this.props.api.internalApi.getAdaptableOptions().filterOptions;
|
|
125
123
|
const predicateDefs = this.props.api.filterApi
|
|
126
124
|
.getFilterPredicateDefsForColumn(this.props.currentColumn)
|
|
127
125
|
.filter((predicate) => !predicate.onlyQuickFilter);
|
|
@@ -133,15 +131,15 @@ class FilterFormComponent extends React.Component {
|
|
|
133
131
|
Helper_1.default.objectNotExists(this.state.editedColumnFilter.Predicate.PredicateId);
|
|
134
132
|
let closeButton = (React.createElement(ButtonClose_1.ButtonClose, { onClick: () => this.onCloseForm(), tooltip: null, accessLevel: 'Full' }));
|
|
135
133
|
let clearFilterButton = (React.createElement(ButtonClear_1.ButtonClear, { onClick: () => this.onClearFilter(), disabled: isEmptyFilter, tooltip: null, accessLevel: 'Full', showText: true, showIcon: false }));
|
|
136
|
-
const
|
|
137
|
-
return (React.createElement("div", { "data-name": "filter-form" }, StringExtensions_1.StringExtensions.IsNullOrEmpty(isFilterable) ? (React.createElement(FilterFormPanel_1.FilterFormPanel, { style: panelStyle, ColumnMenuTab: this.state.selectedTab, ColumnMenuTabChanged: (e) => this.onSelectTab(e), IsAlwaysFilter: this.props.embedColumnMenu, clearFilterButton: clearFilterButton, closeButton: closeButton, showCloseButton: this.props.showCloseButton, autoApplyFilter: filterOptions.autoApplyFilter ? true : false,
|
|
134
|
+
const useAgGridStyle = !!filterOptions.useAgGridFilterFormStyle;
|
|
135
|
+
return (React.createElement("div", { "data-name": "filter-form" }, StringExtensions_1.StringExtensions.IsNullOrEmpty(isFilterable) ? (React.createElement(FilterFormPanel_1.FilterFormPanel, { style: panelStyle, ColumnMenuTab: this.state.selectedTab, ColumnMenuTabChanged: (e) => this.onSelectTab(e), IsAlwaysFilter: this.props.embedColumnMenu, clearFilterButton: clearFilterButton, closeButton: closeButton, showCloseButton: this.props.showCloseButton, autoApplyFilter: filterOptions.autoApplyFilter ? true : false, useAgGridStyle: useAgGridStyle, applyFilterButtonDisabled: isEmptyFilter, onFilterApplied: () => this.onFilterApplied() }, this.state.selectedTab == Enums_1.ColumnMenuTab.Menu ? (React.createElement(ListBoxMenu_1.ListBoxMenu, { MenuItems: this.props.api.internalApi.buildStandaloneColumnHeader(this.props.currentColumn), onMenuItemClick: (menuItem) => this.onMenuItemClick(menuItem) })) : (React.createElement("div", null,
|
|
138
136
|
this.state.showTab && (React.createElement("div", null,
|
|
139
137
|
React.createElement(Radio_1.default, { marginLeft: 1, flex: 1, checked: this.state.currentTab == 'values', onChange: () => this.setState({ currentTab: 'values' }) },
|
|
140
138
|
React.createElement(rebass_1.Flex, { fontSize: 'var( --ab-font-size-2)' }, "Column Values")),
|
|
141
139
|
React.createElement(Radio_1.default, { marginLeft: 2, flex: 1, checked: this.state.currentTab == 'predicates', onChange: () => this.setState({ currentTab: 'predicates' }) },
|
|
142
140
|
React.createElement(rebass_1.Flex, { fontSize: 'var( --ab-font-size-2)' }, "Filters")))),
|
|
143
141
|
this.state.currentTab === 'values' && (React.createElement("div", null,
|
|
144
|
-
React.createElement(ListBoxFilterForm_1.ListBoxFilterForm, { suppressClientSideFilter: this.state.suppressClientSideFilter, isLoading: this.state.isDistinctColumnValuesLoading, onFilterChange: this.handleFilterChange, currentColumn: this.props.currentColumn, columns: this.props.columns, columnDistinctValues: this.state.distinctColumnValues, dataType: this.props.currentColumn.dataType, uiSelectedColumnValues: uiSelectedColumnValues,
|
|
142
|
+
React.createElement(ListBoxFilterForm_1.ListBoxFilterForm, { suppressClientSideFilter: this.state.suppressClientSideFilter, isLoading: this.state.isDistinctColumnValuesLoading, onFilterChange: this.handleFilterChange, currentColumn: this.props.currentColumn, columns: this.props.columns, columnDistinctValues: this.state.distinctColumnValues, dataType: this.props.currentColumn.dataType, uiSelectedColumnValues: uiSelectedColumnValues, useAgGridStyle: useAgGridStyle, onColumnValueSelectedChange: (list) => this.onColumnValuesChange(list) }))),
|
|
145
143
|
this.state.currentTab === 'predicates' && (React.createElement("div", null,
|
|
146
144
|
' ',
|
|
147
145
|
this.state.showTab && React.createElement("hr", null),
|
|
@@ -4,7 +4,7 @@ import { ListGroupProps } from '../../../components/List/ListGroup';
|
|
|
4
4
|
export interface ListBoxFilterFormProps extends ListGroupProps {
|
|
5
5
|
currentColumn: AdaptableColumn;
|
|
6
6
|
columns: AdaptableColumn[];
|
|
7
|
-
|
|
7
|
+
useAgGridStyle?: boolean;
|
|
8
8
|
columnDistinctValues: any[];
|
|
9
9
|
uiSelectedColumnValues: Array<string>;
|
|
10
10
|
onColumnValueSelectedChange: (SelectedValues: Array<any>) => void;
|
|
@@ -26,7 +26,7 @@ exports.ListBoxFilterForm = (props) => {
|
|
|
26
26
|
react_1.useEffect(() => {
|
|
27
27
|
internalUpdateUISelectedColumnValues(props.uiSelectedColumnValues);
|
|
28
28
|
}, [props.uiSelectedColumnValues]);
|
|
29
|
-
const
|
|
29
|
+
const renderItemForAgGridStyle = (props) => {
|
|
30
30
|
return (React.createElement(CheckBox_1.CheckBox, Object.assign({}, props, { variant: "agGrid", fontSize: 2, marginTop: 1, marginBottom: 1, marginLeft: 1, marginRight: 1 })));
|
|
31
31
|
};
|
|
32
32
|
const onClickItemColumnValue = (item) => {
|
|
@@ -51,15 +51,15 @@ exports.ListBoxFilterForm = (props) => {
|
|
|
51
51
|
columnValue.toLocaleLowerCase().indexOf(FilterValue.toLocaleLowerCase()) < 0) {
|
|
52
52
|
return null;
|
|
53
53
|
}
|
|
54
|
-
if (props.
|
|
55
|
-
return
|
|
54
|
+
if (props.useAgGridStyle) {
|
|
55
|
+
return renderItemForAgGridStyle({
|
|
56
56
|
key: 'columnValue' + y,
|
|
57
57
|
children: columnValue,
|
|
58
58
|
checked: isActive,
|
|
59
59
|
onChange: () => onClickItemColumnValue(x),
|
|
60
60
|
});
|
|
61
61
|
}
|
|
62
|
-
return (React.createElement(ListGroupItem_1.default, { noZebra: props.
|
|
62
|
+
return (React.createElement(ListGroupItem_1.default, { noZebra: props.useAgGridStyle, key: 'columnValue' + y, onClick: () => onClickItemColumnValue(x), active: isActive, value: columnValue }, columnValue));
|
|
63
63
|
});
|
|
64
64
|
const textClear = (React.createElement(AdaptableFormControlTextClear_1.AdaptableFormControlTextClear, { autoFocus: true, type: "text", placeholder: "Search Column Values", value: FilterValue, style: {
|
|
65
65
|
paddingTop: 'var(--ab-space-1)',
|
|
@@ -68,10 +68,10 @@ exports.ListBoxFilterForm = (props) => {
|
|
|
68
68
|
borderRadius: 'var(--ab__border-radius)',
|
|
69
69
|
}, OnTextChange: handleFilterValueChange }));
|
|
70
70
|
const baseClassName = 'ab-ListBoxFilterForm';
|
|
71
|
-
return (React.createElement("div", { className: join_1.default(baseClassName, props.
|
|
71
|
+
return (React.createElement("div", { className: join_1.default(baseClassName, props.useAgGridStyle ? `${baseClassName}--aggrid-style` : null, props.isLoading && `${baseClassName}--loading`) },
|
|
72
72
|
React.createElement(rebass_1.Box, { px: 2 },
|
|
73
|
-
React.createElement(rebass_1.Box, { mx: props.
|
|
73
|
+
React.createElement(rebass_1.Box, { mx: props.useAgGridStyle ? 0 : '2px', marginBottom: 2 },
|
|
74
74
|
textClear,
|
|
75
75
|
props.isLoading && React.createElement(Loader_1.Loader, null, "Loading"))),
|
|
76
|
-
!props.isLoading && (React.createElement(GridList_1.default, { showZebraRows: false, className: !props.
|
|
76
|
+
!props.isLoading && (React.createElement(GridList_1.default, { showZebraRows: false, className: !props.useAgGridStyle ? 'ab-padding-horizontal-0' : '' }, columnValuesItemsElements))));
|
|
77
77
|
};
|
|
@@ -106,14 +106,12 @@ class QuickFilterFormComponent extends React.Component {
|
|
|
106
106
|
hideEvent = 'blur';
|
|
107
107
|
}
|
|
108
108
|
let showQuickFilterDropdown = true;
|
|
109
|
-
let hideQuickFilterDropdownFunction = this.props.api.internalApi.getAdaptableOptions()
|
|
110
|
-
.filterOptions.hideQuickFilterDropdown;
|
|
109
|
+
let hideQuickFilterDropdownFunction = this.props.api.internalApi.getAdaptableOptions().filterOptions.hideQuickFilterDropdown;
|
|
111
110
|
if (hideQuickFilterDropdownFunction) {
|
|
112
111
|
showQuickFilterDropdown = !hideQuickFilterDropdownFunction(this.props.currentColumn);
|
|
113
112
|
}
|
|
114
113
|
let showQuickFilterInput = true;
|
|
115
|
-
let hideQuickFilterInputFunction = this.props.api.internalApi.getAdaptableOptions()
|
|
116
|
-
.filterOptions.hideQuickFilterInput;
|
|
114
|
+
let hideQuickFilterInputFunction = this.props.api.internalApi.getAdaptableOptions().filterOptions.hideQuickFilterInput;
|
|
117
115
|
if (hideQuickFilterInputFunction) {
|
|
118
116
|
showQuickFilterInput = !hideQuickFilterInputFunction(this.props.currentColumn);
|
|
119
117
|
}
|
|
@@ -234,7 +232,7 @@ class QuickFilterFormComponent extends React.Component {
|
|
|
234
232
|
React.createElement(SimpleButton_1.default, { onClick: () => this.clearFilter() }, "Clear Filter"),
|
|
235
233
|
((_a = this.props.api.internalApi.getAdaptableOptions().filterOptions) === null || _a === void 0 ? void 0 : _a.autoApplyFilter) ==
|
|
236
234
|
false && (React.createElement(SimpleButton_1.default, { ml: 2, onClick: () => this.updateFilter(this.state.filter) }, "Apply Filter"))),
|
|
237
|
-
React.createElement(ListBoxFilterForm_1.ListBoxFilterForm, { suppressClientSideFilter: this.state.suppressClientSideFilter, isLoading: this.state.isDistinctColumnValuesLoading, onFilterChange: this.handleFilterChange, currentColumn: this.props.currentColumn, columns: [], columnDistinctValues: this.state.distinctColumnValues, dataType: this.props.currentColumn.dataType, uiSelectedColumnValues: this.state.filter.Predicate.Inputs,
|
|
235
|
+
React.createElement(ListBoxFilterForm_1.ListBoxFilterForm, { suppressClientSideFilter: this.state.suppressClientSideFilter, isLoading: this.state.isDistinctColumnValuesLoading, onFilterChange: this.handleFilterChange, currentColumn: this.props.currentColumn, columns: [], columnDistinctValues: this.state.distinctColumnValues, dataType: this.props.currentColumn.dataType, uiSelectedColumnValues: this.state.filter.Predicate.Inputs, useAgGridStyle: true, onColumnValueSelectedChange: (list) => this.onColumnValuesChange(list) })));
|
|
238
236
|
} },
|
|
239
237
|
React.createElement(SimpleButton_1.default, { style: {
|
|
240
238
|
flex: 1,
|
|
@@ -10,7 +10,7 @@ export interface FilterFormPanelProps extends PanelProps {
|
|
|
10
10
|
onFilterApplied: () => void;
|
|
11
11
|
IsAlwaysFilter: boolean;
|
|
12
12
|
showCloseButton: boolean;
|
|
13
|
-
|
|
13
|
+
useAgGridStyle: boolean;
|
|
14
14
|
applyFilterButtonDisabled: boolean;
|
|
15
15
|
autoApplyFilter: boolean;
|
|
16
16
|
}
|