@adaptabletools/adaptable-cjs 22.0.7 → 22.0.9
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/index.css +19 -1
- package/index.css.map +1 -1
- package/package.json +1 -1
- package/src/AdaptableOptions/FilterOptions.d.ts +23 -5
- package/src/AdaptableState/Common/CellDataChangedInfo.d.ts +4 -0
- package/src/AdaptableState/Common/ColumnScope.d.ts +4 -0
- package/src/AdaptableState/Common/ColumnScope.js +17 -0
- package/src/Api/Implementation/StateApiImpl.d.ts +1 -1
- package/src/Api/Implementation/StateApiImpl.js +12 -15
- package/src/Api/StateApi.d.ts +1 -1
- package/src/Redux/Store/AdaptableReduxMerger.js +4 -1
- package/src/Redux/Store/AdaptableStore.d.ts +2 -1
- package/src/Redux/Store/AdaptableStore.js +14 -9
- package/src/Redux/Store/Interface/IAdaptableStore.d.ts +1 -1
- package/src/Strategy/CalculatedColumnModule.js +1 -1
- package/src/Strategy/ColumnFilterModule.js +4 -2
- package/src/Strategy/DataChangeHistoryModule.js +3 -1
- package/src/Strategy/FlashingCellModule.js +1 -1
- package/src/Strategy/FreeTextColumnModule.js +1 -1
- package/src/Utilities/Services/DataService.js +6 -0
- package/src/View/Alert/Wizard/AlertScopeWizardSection.js +10 -3
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnDefinitionWizardSection.js +8 -8
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnTypeSection.js +1 -1
- package/src/View/CalculatedColumn/Wizard/CalculatedColumnWizard.js +4 -2
- package/src/View/Components/ColumnFilter/components/FloatingFilterValues.js +1 -0
- package/src/View/Components/ColumnGroupTag/index.d.ts +5 -0
- package/src/View/Components/ColumnGroupTag/index.js +14 -0
- package/src/View/Components/ColumnSelector/index.js +4 -1
- package/src/View/Components/FilterForm/ListBoxFilterForm.js +8 -1
- package/src/View/Components/NewScopeComponent.js +19 -37
- package/src/View/Components/ReorderDraggable/index.d.ts +1 -0
- package/src/View/Components/ReorderDraggable/index.js +2 -1
- package/src/View/CustomSort/Wizard/CustomSortColumnWizardSection.js +7 -1
- package/src/View/CustomSort/Wizard/CustomSortWizard.js +1 -1
- package/src/View/FlashingCell/Wizard/FlashingCellScopeWizardSection.js +10 -3
- package/src/View/FormatColumn/Wizard/FormatColumnColumnScopeWizardSection.js +14 -7
- package/src/View/FormatColumn/Wizard/FormatColumnRuleWizardSection.js +1 -3
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.d.ts +1 -1
- package/src/View/FreeTextColumn/Wizard/FreeTextColumnSettingsWizardSection.js +7 -7
- package/src/View/Layout/Wizard/LayoutWizard.js +2 -2
- package/src/View/Layout/Wizard/sections/AggregationsSection.js +2 -0
- package/src/View/Layout/Wizard/sections/ColumnsSection.js +149 -140
- package/src/View/Layout/Wizard/sections/FilterSection.js +8 -1
- package/src/View/Layout/Wizard/sections/PivotAggregationsSection.js +2 -0
- package/src/View/Layout/Wizard/sections/PivotRowGroupingSection.js +4 -1
- package/src/View/Layout/Wizard/sections/RowGroupingSection.js +4 -1
- package/src/View/Layout/Wizard/sections/RowSummarySection.js +8 -3
- package/src/View/Layout/Wizard/sections/SortSection.js +3 -1
- package/src/View/StyledColumn/Wizard/StyledColumnWizardColumnSection.js +7 -1
- package/src/View/Wizard/OnePageAdaptableWizard.d.ts +0 -1
- package/src/View/Wizard/OnePageAdaptableWizard.js +1 -1
- package/src/View/Wizard/OnePageWizards.d.ts +1 -0
- package/src/View/Wizard/OnePageWizards.js +11 -4
- package/src/agGrid/AdaptableAgGrid.js +18 -30
- package/src/agGrid/AgGridAdapter.d.ts +1 -0
- package/src/agGrid/AgGridAdapter.js +4 -0
- package/src/agGrid/AgGridColumnAdapter.js +3 -3
- package/src/agGrid/AgGridExportAdapter.js +1 -3
- package/src/components/Tree/TreeDropdown/index.d.ts +9 -0
- package/src/components/Tree/TreeDropdown/index.js +21 -1
- package/src/components/Tree/TreeList/index.d.ts +1 -1
- package/src/env.js +2 -2
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/tsconfig.cjs.tsbuildinfo +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AdaptableStore = exports.LoadState = exports.InitState = void 0;
|
|
3
|
+
exports.AdaptableStore = exports.LoadState = exports.InitState = exports.getPersistableState = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const Redux = tslib_1.__importStar(require("redux"));
|
|
6
6
|
const PluginsRedux = tslib_1.__importStar(require("../ActionsReducers/PluginsRedux"));
|
|
@@ -63,6 +63,13 @@ const NON_PERSISTENT_STORE_KEYS = [
|
|
|
63
63
|
'Comment',
|
|
64
64
|
'Plugins',
|
|
65
65
|
];
|
|
66
|
+
const getPersistableState = (state) => {
|
|
67
|
+
NON_PERSISTENT_STORE_KEYS.forEach((key) => {
|
|
68
|
+
delete state[key];
|
|
69
|
+
});
|
|
70
|
+
return state;
|
|
71
|
+
};
|
|
72
|
+
exports.getPersistableState = getPersistableState;
|
|
66
73
|
const InitState = () => ({
|
|
67
74
|
type: INIT_STATE,
|
|
68
75
|
});
|
|
@@ -204,10 +211,8 @@ class AdaptableStore {
|
|
|
204
211
|
!init &&
|
|
205
212
|
!this.loadStorageInProgress;
|
|
206
213
|
if (shouldPersist) {
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
delete storageState[key];
|
|
210
|
-
});
|
|
214
|
+
let storageState = { ...finalState };
|
|
215
|
+
storageState = (0, exports.getPersistableState)(storageState);
|
|
211
216
|
this.currentStorageState = storageState;
|
|
212
217
|
this.previousStorageState = { ...state };
|
|
213
218
|
NON_PERSISTENT_STORE_KEYS.forEach((key) => {
|
|
@@ -270,10 +275,10 @@ class AdaptableStore {
|
|
|
270
275
|
getPreviousStorageState() {
|
|
271
276
|
return this.previousStorageState;
|
|
272
277
|
}
|
|
273
|
-
saveStateNow(adaptable) {
|
|
274
|
-
const
|
|
275
|
-
if (
|
|
276
|
-
return this.storageEngine.saveNow(adaptable,
|
|
278
|
+
saveStateNow(adaptable, state) {
|
|
279
|
+
const newState = state ?? this.getCurrentStorageState();
|
|
280
|
+
if (newState) {
|
|
281
|
+
return this.storageEngine.saveNow(adaptable, newState, 'API_CALL_SAVE_STATE');
|
|
277
282
|
}
|
|
278
283
|
return Promise.resolve(true);
|
|
279
284
|
}
|
|
@@ -14,7 +14,7 @@ export interface IAdaptableStore {
|
|
|
14
14
|
loadStore: (config: LoadStoreConfig) => Promise<any>;
|
|
15
15
|
getCurrentStorageState: () => AdaptableState | void;
|
|
16
16
|
getPreviousStorageState: () => AdaptableState | void;
|
|
17
|
-
saveStateNow: (adaptable: IAdaptable) => Promise<any>;
|
|
17
|
+
saveStateNow: (adaptable: IAdaptable, state?: AdaptableState) => Promise<any>;
|
|
18
18
|
on: (eventName: string, callback: (data?: any) => any) => () => void;
|
|
19
19
|
onAny: (callback: (eventName: string, data?: any) => any) => () => void;
|
|
20
20
|
onBeforeAny: (callback: (eventName: string, data?: any) => any) => () => void;
|
|
@@ -36,7 +36,7 @@ class CalculatedColumnModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
36
36
|
this.api.internalApi
|
|
37
37
|
.getDataService()
|
|
38
38
|
.on('CellDataChanged', (cellDataChangedInfo) => {
|
|
39
|
-
if (cellDataChangedInfo.trigger !== 'aggChange') {
|
|
39
|
+
if (cellDataChangedInfo.trigger !== 'aggChange' && !cellDataChangedInfo.preventEdit) {
|
|
40
40
|
this.api.internalApi
|
|
41
41
|
.getCalculatedColumnExpressionService()
|
|
42
42
|
.listentoCellDataChange(cellDataChangedInfo);
|
|
@@ -28,8 +28,10 @@ class ColumnFilterModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
28
28
|
this.api.internalApi
|
|
29
29
|
.getDataService()
|
|
30
30
|
.on('CellDataChanged', (cellDataChangedInfo) => {
|
|
31
|
-
|
|
32
|
-
|
|
31
|
+
if (!cellDataChangedInfo.preventEdit) {
|
|
32
|
+
const changedColumnId = cellDataChangedInfo.column.columnId;
|
|
33
|
+
this.api.filterApi.columnFilterApi.resetFilterValues(changedColumnId);
|
|
34
|
+
}
|
|
33
35
|
});
|
|
34
36
|
// we reset the filter cache on sort change, because we might have columns
|
|
35
37
|
// with "In" filters, with custom values, which use `context.orderedValues`
|
|
@@ -33,7 +33,9 @@ class DataChangeHistoryModule extends AdaptableModuleBase_1.AdaptableModuleBase
|
|
|
33
33
|
this.api.internalApi
|
|
34
34
|
.getDataService()
|
|
35
35
|
.on('CellDataChanged', (cellDataChangedInfo) => {
|
|
36
|
-
if (this.isListeningToCellDataChanges &&
|
|
36
|
+
if (this.isListeningToCellDataChanges &&
|
|
37
|
+
this.isDataChangeLoggable(cellDataChangedInfo) &&
|
|
38
|
+
!cellDataChangedInfo.preventEdit) {
|
|
37
39
|
this.api.dataChangeHistoryApi.addDataChangeHistoryEntry(cellDataChangedInfo);
|
|
38
40
|
}
|
|
39
41
|
});
|
|
@@ -39,7 +39,7 @@ class FlashingCellModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
39
39
|
this.api.internalApi
|
|
40
40
|
.getDataService()
|
|
41
41
|
.on('CellDataChanged', (cellDataChangedInfo) => {
|
|
42
|
-
if (cellDataChangedInfo.trigger === 'undo') {
|
|
42
|
+
if (cellDataChangedInfo.trigger === 'undo' || cellDataChangedInfo.preventEdit) {
|
|
43
43
|
// do NOT handle reverted changes
|
|
44
44
|
return;
|
|
45
45
|
}
|
|
@@ -34,7 +34,7 @@ class FreeTextColumnModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
34
34
|
this.api.internalApi
|
|
35
35
|
.getDataService()
|
|
36
36
|
.on('CellDataChanged', (cellDataChangedInfo) => {
|
|
37
|
-
if (cellDataChangedInfo.trigger !== 'aggChange') {
|
|
37
|
+
if (cellDataChangedInfo.trigger !== 'aggChange' && !cellDataChangedInfo.preventEdit) {
|
|
38
38
|
this.api.freeTextColumnApi.internalApi.handleFreeTextColumnDataChange(cellDataChangedInfo);
|
|
39
39
|
}
|
|
40
40
|
});
|
|
@@ -45,6 +45,12 @@ class DataService {
|
|
|
45
45
|
emit = (eventName, data) => this.emitter.emit(eventName, data);
|
|
46
46
|
CreateCellDataChangedEvent(cellDataChangedInfo) {
|
|
47
47
|
if (cellDataChangedInfo.newValue != cellDataChangedInfo.oldValue) {
|
|
48
|
+
const validationRules = this.adaptable.api.internalApi
|
|
49
|
+
.getValidationService()
|
|
50
|
+
.getValidationRulesForDataChange(cellDataChangedInfo);
|
|
51
|
+
if (validationRules.length) {
|
|
52
|
+
cellDataChangedInfo.preventEdit = true;
|
|
53
|
+
}
|
|
48
54
|
this.emitter.emitSync('CellDataChanged', cellDataChangedInfo);
|
|
49
55
|
this.adaptable.api.eventApi.internalApi.fireCellChangedEvent(cellDataChangedInfo);
|
|
50
56
|
const dataChangeLogEntry = this.extractDataChangeLogEntry(cellDataChangedInfo);
|
|
@@ -6,6 +6,7 @@ const React = tslib_1.__importStar(require("react"));
|
|
|
6
6
|
const NewScopeComponent_1 = require("../../Components/NewScopeComponent");
|
|
7
7
|
const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
|
|
8
8
|
const Flex_1 = require("../../../components/Flex");
|
|
9
|
+
const ColumnScope_1 = require("../../../AdaptableState/Common/ColumnScope");
|
|
9
10
|
const AlertScopeWizardSection = (props) => {
|
|
10
11
|
const { data, api } = (0, OnePageAdaptableWizard_1.useOnePageAdaptableWizardContext)();
|
|
11
12
|
let disableDataTypes = true;
|
|
@@ -22,10 +23,16 @@ const AlertScopeWizardSection = (props) => {
|
|
|
22
23
|
}, scope: data.Scope, updateScope: (Scope) => {
|
|
23
24
|
const newData = { ...data, Scope };
|
|
24
25
|
if (newData.Rule.Predicates) {
|
|
25
|
-
|
|
26
|
-
// if it was set to a predicate before
|
|
26
|
+
const validPredicateIds = new Set(api.alertApi.internalApi.getAlertPredicateDefsForScope(Scope).map((def) => def.id));
|
|
27
27
|
newData.Rule = {
|
|
28
|
-
Predicates:
|
|
28
|
+
Predicates: newData.Rule.Predicates.filter((p) => validPredicateIds.has(p.PredicateId)).filter((predicate) => {
|
|
29
|
+
// if there are more than 1 column, then we must eliminate the IN/NotIn predicates
|
|
30
|
+
// TODO: this should NOT be required, but the ColumnValueSelector does NOT support creatable values right now
|
|
31
|
+
if ((0, ColumnScope_1.isScopeColumnIds)(Scope) && Scope.ColumnIds.length > 1) {
|
|
32
|
+
return predicate.PredicateId !== 'In' && predicate.PredicateId !== 'NotIn';
|
|
33
|
+
}
|
|
34
|
+
return true;
|
|
35
|
+
}),
|
|
29
36
|
};
|
|
30
37
|
}
|
|
31
38
|
if (newData.Rule.ObservableExpression !== undefined &&
|
|
@@ -26,11 +26,11 @@ exports.renderCalculatedColumnDefinitionSummary = renderCalculatedColumnDefiniti
|
|
|
26
26
|
const isValidCalculatedColumnDefinition = (data, api) => {
|
|
27
27
|
const columns = api.columnApi.getColumns();
|
|
28
28
|
if (!data.ColumnId) {
|
|
29
|
-
return 'A Column
|
|
29
|
+
return 'A Column Name is required';
|
|
30
30
|
}
|
|
31
31
|
const columnsWithSameIdCount = columns.filter((c) => c.columnId === data.ColumnId).length;
|
|
32
32
|
const hasAlreadyExistingId = data.Uuid ? columnsWithSameIdCount > 1 : columnsWithSameIdCount > 0;
|
|
33
|
-
return hasAlreadyExistingId ? 'A column with this
|
|
33
|
+
return hasAlreadyExistingId ? 'A column with this Name already exists' : true;
|
|
34
34
|
};
|
|
35
35
|
exports.isValidCalculatedColumnDefinition = isValidCalculatedColumnDefinition;
|
|
36
36
|
const CalculatedColumnDefinitionWizardSection = (props) => {
|
|
@@ -71,16 +71,16 @@ const CalculatedColumnDefinitionWizardSection = (props) => {
|
|
|
71
71
|
React.createElement(Tabs_1.Tabs.Content, null,
|
|
72
72
|
React.createElement(Flex_1.Flex, { flexDirection: "row" },
|
|
73
73
|
React.createElement(FormLayout_1.default, null,
|
|
74
|
-
React.createElement(FormLayout_1.FormRow, { label: "Column
|
|
75
|
-
React.createElement(Input_1.default, { "data-name": "column-id", value: data.ColumnId || '', width:
|
|
76
|
-
React.createElement(FormLayout_1.FormRow, { label: "
|
|
74
|
+
React.createElement(FormLayout_1.FormRow, { label: "Column Name" },
|
|
75
|
+
React.createElement(Input_1.default, { "data-name": "column-id", value: data.ColumnId || '', style: { width: '100%', maxWidth: 500 }, autoFocus: !inEdit, disabled: inEdit, type: "text", placeholder: "Enter a Column Name", onChange: handleColumnIdChange })),
|
|
76
|
+
React.createElement(FormLayout_1.FormRow, { label: "Column Header" },
|
|
77
77
|
React.createElement(Input_1.default, { "data-name": "column-name", autoFocus: inEdit, onFocus: () => {
|
|
78
78
|
setColumnNameFocused(true);
|
|
79
79
|
}, onBlur: () => {
|
|
80
80
|
setColumnNameFocused(false);
|
|
81
|
-
}, value: ColumnNameFocused ? ColumnName || '' : ColumnName || ColumnId || '', width:
|
|
82
|
-
React.createElement(FormLayout_1.FormRow, { label: "Header Tooltip" },
|
|
83
|
-
React.createElement(Input_1.default, { "data-name": "header-tooltip", type: "text", width:
|
|
81
|
+
}, value: ColumnNameFocused ? ColumnName || '' : ColumnName || ColumnId || '', style: { width: '100%', maxWidth: 500 }, type: "text", placeholder: "Enter a Column Header (optional)", onChange: handleColumnNameChange })),
|
|
82
|
+
React.createElement(FormLayout_1.FormRow, { label: "Column Header Tooltip" },
|
|
83
|
+
React.createElement(Input_1.default, { "data-name": "header-tooltip", type: "text", style: { width: '100%', maxWidth: 500 }, value: HeaderToolTip, onChange: (e) => handleSpecialColumnSettingsChange({
|
|
84
84
|
HeaderToolTip: e.target.value,
|
|
85
85
|
}) })),
|
|
86
86
|
React.createElement(FormLayout_1.FormRow, { label: "" },
|
|
@@ -8,7 +8,7 @@ const TypeRadio_1 = require("../../Wizard/TypeRadio");
|
|
|
8
8
|
const Flex_1 = require("../../../components/Flex");
|
|
9
9
|
const CalculatedColumnTypeWizardSection = (props) => {
|
|
10
10
|
return (React.createElement(Tabs_1.Tabs, null,
|
|
11
|
-
React.createElement(Tabs_1.Tabs.Tab, null, "Calculated Column
|
|
11
|
+
React.createElement(Tabs_1.Tabs.Tab, null, "Calculated Column Type"),
|
|
12
12
|
React.createElement(Tabs_1.Tabs.Content, null,
|
|
13
13
|
React.createElement(Flex_1.Flex, { flexDirection: "column" },
|
|
14
14
|
React.createElement(TypeRadio_1.TypeRadio, { text: 'Standard', description: "The calculated value is derived from other cells in the row", checked: props.type === 'ScalarExpression', onClick: () => props.onTypeChange('ScalarExpression') }),
|
|
@@ -71,6 +71,7 @@ const CalculatedColumnWizard = (props) => {
|
|
|
71
71
|
return (React.createElement(OnePageAdaptableWizard_1.OnePageAdaptableWizard, { defaultCurrentSectionName: props.defaultCurrentSectionName, moduleInfo: props.moduleInfo, data: calculatedColumn, onHide: props.onCloseWizard, onFinish: handleFinish, sections: [
|
|
72
72
|
{
|
|
73
73
|
title: 'Type',
|
|
74
|
+
details: 'Select Type of Calculated Column',
|
|
74
75
|
renderSummary: () => {
|
|
75
76
|
return (React.createElement(Flex_1.Box, { className: "twa:text-2" },
|
|
76
77
|
"Expression Type: ",
|
|
@@ -83,7 +84,7 @@ const CalculatedColumnWizard = (props) => {
|
|
|
83
84
|
},
|
|
84
85
|
{
|
|
85
86
|
title: 'Details',
|
|
86
|
-
details: '
|
|
87
|
+
details: 'Provide Calculated Column Details',
|
|
87
88
|
isValid: CalculatedColumnDefinitionWizardSection_1.isValidCalculatedColumnDefinition,
|
|
88
89
|
renderSummary: CalculatedColumnDefinitionWizardSection_1.renderCalculatedColumnDefinitionSummary,
|
|
89
90
|
render: () => {
|
|
@@ -103,7 +104,7 @@ const CalculatedColumnWizard = (props) => {
|
|
|
103
104
|
},
|
|
104
105
|
{
|
|
105
106
|
title: 'Settings',
|
|
106
|
-
details: 'Specify Column
|
|
107
|
+
details: 'Specify Calculated Column Properties',
|
|
107
108
|
isValid: CalculatedColumnSettingsWizardSection_1.isValidCalculatedColumnSettings,
|
|
108
109
|
renderSummary: CalculatedColumnSettingsWizardSection_1.renderCalculatedColumnSettingsSummary,
|
|
109
110
|
render: () => {
|
|
@@ -121,6 +122,7 @@ const CalculatedColumnWizard = (props) => {
|
|
|
121
122
|
},
|
|
122
123
|
'-',
|
|
123
124
|
{
|
|
125
|
+
details: 'Review the Calculated Column',
|
|
124
126
|
render: () => {
|
|
125
127
|
return (React.createElement(Flex_1.Box, { className: "twa:p-2" },
|
|
126
128
|
React.createElement(OnePageAdaptableWizard_1.OnePageWizardSummary, null)));
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ColumnGroupTag = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const React = tslib_1.__importStar(require("react"));
|
|
6
|
+
const Flex_1 = require("../../../components/Flex");
|
|
7
|
+
const ColumnGroupTag = ({ column }) => {
|
|
8
|
+
if (!column.columnGroup || column.columnGroup.groupCount <= 1)
|
|
9
|
+
return null;
|
|
10
|
+
return (React.createElement(Flex_1.Box, { className: "ab-Layout-Wizard__ColumnRow__Title twa:mx-2 twa:p-1 twa:flex twa:items-center" },
|
|
11
|
+
"Column Group: ",
|
|
12
|
+
column.columnGroup.friendlyName));
|
|
13
|
+
};
|
|
14
|
+
exports.ColumnGroupTag = ColumnGroupTag;
|
|
@@ -5,6 +5,7 @@ const tslib_1 = require("tslib");
|
|
|
5
5
|
const React = tslib_1.__importStar(require("react"));
|
|
6
6
|
const react_1 = require("react");
|
|
7
7
|
const ValueSelector_1 = require("../ValueSelector");
|
|
8
|
+
const ColumnGroupTag_1 = require("../ColumnGroupTag");
|
|
8
9
|
const NewColumnSelector = ({ allowReorder = true, ...props }) => {
|
|
9
10
|
const { columnFilterText, availableColumns, selected, onChange, singleSelect } = props;
|
|
10
11
|
const filterFn = (0, react_1.useMemo)(() => {
|
|
@@ -19,6 +20,8 @@ const NewColumnSelector = ({ allowReorder = true, ...props }) => {
|
|
|
19
20
|
else {
|
|
20
21
|
onChange(colIds);
|
|
21
22
|
}
|
|
22
|
-
}, toIdentifier: (c) => c.columnId, toLabel: (c) => c.friendlyName }
|
|
23
|
+
}, toIdentifier: (c) => c.columnId, toLabel: (c) => c.friendlyName, toListLabel: (c) => (React.createElement("div", { className: "twa:flex twa:flex-row twa:items-center" },
|
|
24
|
+
c.friendlyName,
|
|
25
|
+
React.createElement(ColumnGroupTag_1.ColumnGroupTag, { column: c }))) }));
|
|
23
26
|
};
|
|
24
27
|
exports.NewColumnSelector = NewColumnSelector;
|
|
@@ -97,13 +97,20 @@ const ColumnValuesSelect = (props) => {
|
|
|
97
97
|
minWidth: `var(--ab-cmp-select-column-menu-${column.columnId}__min-width, var(--ab-cmp-select-column-menu__min-width, 160px))`,
|
|
98
98
|
};
|
|
99
99
|
}, [column.columnId]);
|
|
100
|
+
const treeDropdownToDisplayValue = React.useMemo(() => {
|
|
101
|
+
if (column.dataType === 'date') {
|
|
102
|
+
return toDateDisplayValue;
|
|
103
|
+
}
|
|
104
|
+
return (paths) => (0, TreeDropdown_1.toDisplayValueFromOptionTree)(paths, optionsFromProps);
|
|
105
|
+
}, [column.dataType, optionsFromProps]);
|
|
100
106
|
const component = column.dataType === 'date' || column.columnId === GeneralConstants_1.AG_GRID_GROUPED_COLUMN ? (React.createElement(TreeDropdown_1.TreeDropdown, { style: {
|
|
101
107
|
width: '100%',
|
|
102
108
|
height: '100%',
|
|
103
109
|
...props.selectProps?.styles?.container,
|
|
104
|
-
}, toDisplayValue:
|
|
110
|
+
}, toDisplayValue: treeDropdownToDisplayValue, fieldStyle: {
|
|
105
111
|
boxShadow: 'none',
|
|
106
112
|
...props.selectProps?.styles?.control,
|
|
113
|
+
...props.selectProps?.styles?.valueContainer,
|
|
107
114
|
}, resizable: true, onChange: column.dataType === 'date'
|
|
108
115
|
? (value) => props.onChange(dateOnChangeParser(value))
|
|
109
116
|
: props.onChange, options: options,
|
|
@@ -77,47 +77,30 @@ const NewScopeComponent = (props) => {
|
|
|
77
77
|
}
|
|
78
78
|
return allColumns;
|
|
79
79
|
}, []);
|
|
80
|
-
const
|
|
80
|
+
const getTabFromScope = (scope) => {
|
|
81
81
|
if (!scope) {
|
|
82
82
|
return undefined;
|
|
83
83
|
}
|
|
84
84
|
if (scopeApi.scopeIsAll(scope)) {
|
|
85
|
-
return '
|
|
85
|
+
return 'Row';
|
|
86
86
|
}
|
|
87
|
-
if (scopeApi.scopeHasColumns(
|
|
87
|
+
if (scopeApi.scopeHasColumns(scope)) {
|
|
88
88
|
return 'Column';
|
|
89
89
|
}
|
|
90
|
-
if (scopeApi.scopeHasDataType(
|
|
90
|
+
if (scopeApi.scopeHasDataType(scope)) {
|
|
91
91
|
return 'DataType';
|
|
92
92
|
}
|
|
93
|
-
if (scopeApi.scopeHasColumnType(
|
|
93
|
+
if (scopeApi.scopeHasColumnType(scope)) {
|
|
94
94
|
return 'ColumnType';
|
|
95
95
|
}
|
|
96
96
|
return undefined;
|
|
97
97
|
};
|
|
98
|
-
const
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
};
|
|
98
|
+
const [activeTab, setActiveTab] = (0, react_1.useState)(() => getTabFromScope(props.scope));
|
|
99
|
+
const onTabChanged = (value) => {
|
|
100
|
+
setActiveTab(value);
|
|
101
|
+
if (value === 'Row') {
|
|
102
|
+
props.updateScope({ All: true });
|
|
104
103
|
}
|
|
105
|
-
else if (value == 'DataType') {
|
|
106
|
-
newScope = {
|
|
107
|
-
DataTypes: [],
|
|
108
|
-
};
|
|
109
|
-
}
|
|
110
|
-
else if (value == 'ColumnType') {
|
|
111
|
-
newScope = {
|
|
112
|
-
ColumnTypes: [],
|
|
113
|
-
};
|
|
114
|
-
}
|
|
115
|
-
else {
|
|
116
|
-
newScope = {
|
|
117
|
-
All: true,
|
|
118
|
-
};
|
|
119
|
-
}
|
|
120
|
-
props.updateScope(newScope);
|
|
121
104
|
};
|
|
122
105
|
const onColumnsSelectedChanged = (cols) => {
|
|
123
106
|
const newScope = {
|
|
@@ -126,7 +109,7 @@ const NewScopeComponent = (props) => {
|
|
|
126
109
|
props.updateScope(newScope);
|
|
127
110
|
};
|
|
128
111
|
const onCheckBoxDataTypeChecked = (checked, item) => {
|
|
129
|
-
let dataTypes = [].concat(scopeApi.getDataTypesInScope(props.scope));
|
|
112
|
+
let dataTypes = [].concat(scopeApi.getDataTypesInScope(props.scope) ?? []);
|
|
130
113
|
if (checked) {
|
|
131
114
|
dataTypes.push(item);
|
|
132
115
|
}
|
|
@@ -141,7 +124,6 @@ const NewScopeComponent = (props) => {
|
|
|
141
124
|
};
|
|
142
125
|
props.updateScope(newScope);
|
|
143
126
|
};
|
|
144
|
-
const scopeChoice = getScopeChoice(props.scope);
|
|
145
127
|
const dataTypesInScope = props.scope && 'DataTypes' in props.scope ? scopeApi.getDataTypesInScope(props.scope) : null;
|
|
146
128
|
let dataTypeOptions = DATA_TYPES_OPTIONS;
|
|
147
129
|
if (Array.isArray(props.availableDataTypes)) {
|
|
@@ -150,15 +132,15 @@ const NewScopeComponent = (props) => {
|
|
|
150
132
|
const hasColumnTypes = React.useMemo(() => {
|
|
151
133
|
return api.columnApi.getColumnTypes()?.length > 0;
|
|
152
134
|
}, []);
|
|
153
|
-
return (React.createElement(Tabs_1.Tabs, { "data-name": 'scope-component', className: "ab-ScopeComponent", value:
|
|
135
|
+
return (React.createElement(Tabs_1.Tabs, { "data-name": 'scope-component', className: "ab-ScopeComponent", value: activeTab, style: { height: '100%', ...props.style }, onValueChange: onTabChanged },
|
|
154
136
|
props.hideWholeRow ? null : (React.createElement(Tabs_1.Tabs.Tab, { value: "Row" },
|
|
155
|
-
React.createElement(Radio_1.default, { className: "twa:m-0", checked:
|
|
137
|
+
React.createElement(Radio_1.default, { className: "twa:m-0", checked: activeTab == 'Row', tabIndex: -1 }, "All Columns"))),
|
|
156
138
|
!props.disableColumns && (React.createElement(Tabs_1.Tabs.Tab, { value: "Column" },
|
|
157
|
-
React.createElement(Radio_1.default, { className: "twa:m-0", value: "Column", checked:
|
|
139
|
+
React.createElement(Radio_1.default, { className: "twa:m-0", value: "Column", checked: activeTab == 'Column', tabIndex: -1 }, "Selected Columns"))),
|
|
158
140
|
!props.disableDataTypes && (React.createElement(Tabs_1.Tabs.Tab, { value: "DataType" },
|
|
159
|
-
React.createElement(Radio_1.default, { className: "twa:m-0", value: "DataType", checked:
|
|
141
|
+
React.createElement(Radio_1.default, { className: "twa:m-0", value: "DataType", checked: activeTab == 'DataType', tabIndex: -1 }, "Data Types"))),
|
|
160
142
|
hasColumnTypes && (React.createElement(Tabs_1.Tabs.Tab, { value: "ColumnType" },
|
|
161
|
-
React.createElement(Radio_1.default, { className: "twa:m-0", value: "ColumnType", checked:
|
|
143
|
+
React.createElement(Radio_1.default, { className: "twa:m-0", value: "ColumnType", checked: activeTab == 'ColumnType', tabIndex: -1 }, "Column Types"))),
|
|
162
144
|
props.hideWholeRow ? null : (React.createElement(Tabs_1.Tabs.Content, { value: "Row", style: { flex: 'none' }, "data-name": "row-scope" },
|
|
163
145
|
React.createElement(Flex_1.Box, { className: "twa:p-2 twa:pl-0 twa:text-2" }, props.descriptions.rowScope))),
|
|
164
146
|
!props.disableColumns && (React.createElement(Tabs_1.Tabs.Content, { value: "Column", "data-name": "column-scope", className: "twa:p-0 twa:flex-1 twa:overflow-auto" },
|
|
@@ -167,15 +149,15 @@ const NewScopeComponent = (props) => {
|
|
|
167
149
|
React.createElement(Flex_1.Box, { className: "twa:flex-3" }),
|
|
168
150
|
React.createElement(AdaptableFormControlTextClear_1.AdaptableFormControlTextClear, { value: columnsSearchText, OnTextChange: setColumnsSearchText, placeholder: "Type to search columns", style: { flex: 1 } })),
|
|
169
151
|
React.createElement(Flex_1.Flex, { className: "twa:overflow-hidden twa:pl-2 twa:flex-1" },
|
|
170
|
-
React.createElement(ColumnSelector_1.NewColumnSelector, { columnFilterText: columnsSearchText, allowReorder: false, availableColumns: scopeColumns, selected: scopeApi.getColumnIdsInScope(props.scope), onChange: onColumnsSelectedChanged })))),
|
|
152
|
+
React.createElement(ColumnSelector_1.NewColumnSelector, { columnFilterText: columnsSearchText, allowReorder: false, availableColumns: scopeColumns, selected: scopeApi.getColumnIdsInScope(props.scope) ?? [], onChange: onColumnsSelectedChanged })))),
|
|
171
153
|
!props.disableDataTypes && (React.createElement(Tabs_1.Tabs.Content, { value: "DataType", style: { flex: 'none' }, "data-name": "datatype-scope" },
|
|
172
154
|
React.createElement(Flex_1.Box, null,
|
|
173
155
|
props.descriptions.dataTypeScope && (React.createElement(Flex_1.Box, { className: "twa:p-2 twa:pl-0 twa:mb-2 twa:text-2" }, props.descriptions.dataTypeScope)),
|
|
174
|
-
React.createElement(Flex_1.Flex, { flexDirection: "column" }, dataTypeOptions.map((dataTypeOption) => (React.createElement(CheckBox_1.CheckBox, { "data-name": "scope", "data-value": dataTypeOption.value, key: dataTypeOption.value, checked: dataTypesInScope && dataTypesInScope.includes(dataTypeOption.value), onChange: (checked) => onCheckBoxDataTypeChecked(checked, dataTypeOption.value) }, dataTypeOption.label))))))),
|
|
156
|
+
React.createElement(Flex_1.Flex, { flexDirection: "column" }, dataTypeOptions.map((dataTypeOption) => (React.createElement(CheckBox_1.CheckBox, { "data-name": "scope", "data-value": dataTypeOption.value, key: dataTypeOption.value, checked: !!dataTypesInScope && dataTypesInScope.includes(dataTypeOption.value), onChange: (checked) => onCheckBoxDataTypeChecked(checked, dataTypeOption.value) }, dataTypeOption.label))))))),
|
|
175
157
|
hasColumnTypes && (React.createElement(Tabs_1.Tabs.Content, { value: "ColumnType", className: "twa:flex-none", "data-name": "column-type-scope" },
|
|
176
158
|
React.createElement(Flex_1.Box, null,
|
|
177
159
|
React.createElement(Flex_1.Flex, { flexDirection: "column" }, api.columnApi.getColumnTypes()?.map?.((columnType) => (React.createElement(CheckBox_1.CheckBox, { "data-name": "scope", "data-value": columnType, key: columnType, checked: 'ColumnTypes' in props.scope && props.scope.ColumnTypes?.includes(columnType), onChange: (checked) => {
|
|
178
|
-
let columnTypes = [].concat(props.scope.ColumnTypes);
|
|
160
|
+
let columnTypes = [].concat('ColumnTypes' in props.scope ? props.scope.ColumnTypes : []);
|
|
179
161
|
if (checked) {
|
|
180
162
|
columnTypes.push(columnType);
|
|
181
163
|
}
|
|
@@ -10,5 +10,6 @@ export type ReorderDraggableProps<OPTION_TYPE, ID_TYPE extends number | string>
|
|
|
10
10
|
onOptionClick?: (option: OPTION_TYPE, event: React.MouseEvent<HTMLDivElement>) => void;
|
|
11
11
|
disabled?: boolean;
|
|
12
12
|
style?: React.CSSProperties;
|
|
13
|
+
className?: string;
|
|
13
14
|
};
|
|
14
15
|
export declare function ReorderDraggable<OPTION_TYPE, ID_TYPE extends number | string>(props: ReorderDraggableProps<OPTION_TYPE, ID_TYPE>): React.JSX.Element;
|
|
@@ -8,6 +8,7 @@ const icons_1 = require("../../../components/icons");
|
|
|
8
8
|
const ArrayExtensions_1 = tslib_1.__importDefault(require("../../../Utilities/Extensions/ArrayExtensions"));
|
|
9
9
|
const Flex_1 = require("../../../components/Flex");
|
|
10
10
|
const clsx_1 = tslib_1.__importDefault(require("clsx"));
|
|
11
|
+
const twMerge_1 = require("../../../twMerge");
|
|
11
12
|
function ReorderDraggable(props) {
|
|
12
13
|
const { onChange, order, toIdentifier, isOptionDraggable, disabled, } = props;
|
|
13
14
|
const baseClassName = 'ab-ReorderDraggable';
|
|
@@ -31,7 +32,7 @@ function ReorderDraggable(props) {
|
|
|
31
32
|
}, draggableProvided.dragHandleProps);
|
|
32
33
|
}));
|
|
33
34
|
};
|
|
34
|
-
return (React.createElement(Flex_1.Flex, { style: props.style, className: `${baseClassName} twa:flex-1`, flexDirection: "column" },
|
|
35
|
+
return (React.createElement(Flex_1.Flex, { style: props.style, className: (0, twMerge_1.twMerge)(`${baseClassName} twa:flex-1`, props.className), flexDirection: "column" },
|
|
35
36
|
React.createElement(dnd_1.DragDropContext, { onDragEnd: (result) => {
|
|
36
37
|
const { source, destination } = result;
|
|
37
38
|
const newOrder = ArrayExtensions_1.default.reorderArray(props.order, source.index, destination.index);
|
|
@@ -10,6 +10,7 @@ const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
|
|
|
10
10
|
const Flex_1 = require("../../../components/Flex");
|
|
11
11
|
const FormLayout_1 = tslib_1.__importStar(require("../../../components/FormLayout"));
|
|
12
12
|
const Input_1 = tslib_1.__importDefault(require("../../../components/Input"));
|
|
13
|
+
const AdaptableFormControlTextClear_1 = require("../../Components/Forms/AdaptableFormControlTextClear");
|
|
13
14
|
const renderCustomSortColumn = (data) => {
|
|
14
15
|
const { api } = (0, OnePageAdaptableWizard_1.useOnePageAdaptableWizardContext)();
|
|
15
16
|
return (React.createElement(Flex_1.Box, { className: "twa:text-2 twa:py-2 twa:pr-2" },
|
|
@@ -60,6 +61,7 @@ const CustomSortColumnWizardSection = (props) => {
|
|
|
60
61
|
});
|
|
61
62
|
});
|
|
62
63
|
}, []);
|
|
64
|
+
const [columnsSearchText, setColumnsSearchText] = React.useState('');
|
|
63
65
|
const onNameChange = (event) => {
|
|
64
66
|
props.onChange({
|
|
65
67
|
...data,
|
|
@@ -77,7 +79,11 @@ const CustomSortColumnWizardSection = (props) => {
|
|
|
77
79
|
React.createElement(Tabs_1.Tabs, { style: { flex: 1, minHeight: 0 } },
|
|
78
80
|
React.createElement(Tabs_1.Tabs.Tab, null, "Column"),
|
|
79
81
|
React.createElement(Tabs_1.Tabs.Content, null,
|
|
80
|
-
React.createElement(
|
|
82
|
+
React.createElement(Flex_1.Flex, { flexDirection: "row", alignItems: "center", className: "twa:p-2" },
|
|
83
|
+
React.createElement(Flex_1.Box, { className: "twa:text-2" }, "Columns"),
|
|
84
|
+
React.createElement(Flex_1.Box, { className: "twa:flex-3" }),
|
|
85
|
+
React.createElement(AdaptableFormControlTextClear_1.AdaptableFormControlTextClear, { value: columnsSearchText, OnTextChange: setColumnsSearchText, placeholder: "Type to search columns", style: { flex: 1 } })),
|
|
86
|
+
React.createElement(ColumnSelector_1.NewColumnSelector, { columnFilterText: columnsSearchText, availableColumns: sortableCols, selected: data.ColumnId ? [data.ColumnId] : [], singleSelect: true, onChange: (ids) => {
|
|
81
87
|
props.onChange({
|
|
82
88
|
...data,
|
|
83
89
|
SortedValues: [],
|
|
@@ -43,7 +43,7 @@ const CustomSortWizard = (props) => {
|
|
|
43
43
|
{
|
|
44
44
|
isValid: (data) => (0, CustomSortColumnWizardSection_1.isValidCustomSortColumn)(data, allCustomSorts),
|
|
45
45
|
renderSummary: CustomSortColumnWizardSection_1.renderCustomSortColumn,
|
|
46
|
-
details: 'Enter Name and select a Column
|
|
46
|
+
details: 'Enter Name and select a Column to Sort',
|
|
47
47
|
render: () => {
|
|
48
48
|
return (React.createElement(Flex_1.Box, { className: "twa:p-2 twa:h-full" },
|
|
49
49
|
React.createElement(CustomSortColumnWizardSection_1.CustomSortColumnWizardSection, { isNew: props.isNew, onChange: setCustomSort, allCustomSorts: allCustomSorts })));
|
|
@@ -6,6 +6,7 @@ const React = tslib_1.__importStar(require("react"));
|
|
|
6
6
|
const NewScopeComponent_1 = require("../../Components/NewScopeComponent");
|
|
7
7
|
const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
|
|
8
8
|
const Flex_1 = require("../../../components/Flex");
|
|
9
|
+
const ColumnScope_1 = require("../../../AdaptableState/Common/ColumnScope");
|
|
9
10
|
const FlashingAlertScopeWizardSection = (props) => {
|
|
10
11
|
const { data, api } = (0, OnePageAdaptableWizard_1.useOnePageAdaptableWizardContext)();
|
|
11
12
|
const availableColumns = React.useMemo(() => api.columnApi.getNonSpecialColumns(), []);
|
|
@@ -16,10 +17,16 @@ const FlashingAlertScopeWizardSection = (props) => {
|
|
|
16
17
|
}, scopeColumns: availableColumns, scope: data.Scope, updateScope: (Scope) => {
|
|
17
18
|
const newData = { ...data, Scope };
|
|
18
19
|
if (newData.Rule.Predicates) {
|
|
19
|
-
|
|
20
|
-
// if it was set to a predicate before
|
|
20
|
+
const validPredicateIds = new Set(api.flashingCellApi.getFlashingCellPredicateDefsForScope(Scope).map((def) => def.id));
|
|
21
21
|
newData.Rule = {
|
|
22
|
-
Predicates:
|
|
22
|
+
Predicates: newData.Rule.Predicates.filter((p) => validPredicateIds.has(p.PredicateId)).filter((predicate) => {
|
|
23
|
+
// if there are more than 1 column, then we must eliminate the IN/NotIn predicates
|
|
24
|
+
// TODO: this should NOT be required, but the ColumnValueSelector does NOT support creatable values right now
|
|
25
|
+
if ((0, ColumnScope_1.isScopeColumnIds)(Scope) && Scope.ColumnIds.length > 1) {
|
|
26
|
+
return predicate.PredicateId !== 'In' && predicate.PredicateId !== 'NotIn';
|
|
27
|
+
}
|
|
28
|
+
return true;
|
|
29
|
+
}),
|
|
23
30
|
};
|
|
24
31
|
}
|
|
25
32
|
props.onChange(newData);
|
|
@@ -5,7 +5,7 @@ const tslib_1 = require("tslib");
|
|
|
5
5
|
const React = tslib_1.__importStar(require("react"));
|
|
6
6
|
const NewScopeComponent_1 = require("../../Components/NewScopeComponent");
|
|
7
7
|
const OnePageAdaptableWizard_1 = require("../../Wizard/OnePageAdaptableWizard");
|
|
8
|
-
const
|
|
8
|
+
const ColumnScope_1 = require("../../../AdaptableState/Common/ColumnScope");
|
|
9
9
|
const renderFormatColumnScopeSummary = (data) => {
|
|
10
10
|
return (0, NewScopeComponent_1.renderScopeSummary)(data.Scope, {
|
|
11
11
|
scopeWholeRow: 'Matching rows will be formatted',
|
|
@@ -31,12 +31,19 @@ const FormatColumnScopeWizardSection = (props) => {
|
|
|
31
31
|
newData.Rule.BooleanExpression = '';
|
|
32
32
|
}
|
|
33
33
|
else {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
34
|
+
const validPredicateIds = new Set(api.formatColumnApi.internalApi
|
|
35
|
+
.getFormatColumnDefsForScope(Scope)
|
|
36
|
+
.map((def) => def.id));
|
|
37
|
+
newData.Rule = {
|
|
38
|
+
Predicates: newData.Rule.Predicates.filter((p) => validPredicateIds.has(p.PredicateId)).filter((predicate) => {
|
|
39
|
+
// if there are more than 1 column, then we must eliminate the IN/NotIn predicates
|
|
40
|
+
// TODO: this should NOT be required, but the ColumnValueSelector does NOT support creatable values right now
|
|
41
|
+
if ((0, ColumnScope_1.isScopeColumnIds)(Scope) && Scope.ColumnIds.length > 1) {
|
|
42
|
+
return predicate.PredicateId !== 'In' && predicate.PredicateId !== 'NotIn';
|
|
43
|
+
}
|
|
44
|
+
return true;
|
|
45
|
+
}),
|
|
46
|
+
};
|
|
40
47
|
}
|
|
41
48
|
}
|
|
42
49
|
props.onChange(newData);
|
|
@@ -11,9 +11,7 @@ function FormatColumnRuleWizardSection(props) {
|
|
|
11
11
|
if (data.Target && data.Target === 'columnHeader') {
|
|
12
12
|
return (React.createElement(HelpBlock_1.default, { className: "twa:mt-3" }, "Conditions cannot be applied if the Target of the Format Column is Column Header"));
|
|
13
13
|
}
|
|
14
|
-
return (React.createElement(EntityRulesEditor_1.EntityRulesEditor, { module: moduleInfo.ModuleName, defaultPredicateId: props.defaultPredicateId,
|
|
15
|
-
// TODO see what is this
|
|
16
|
-
predicateDefs: api.formatColumnApi.internalApi.getFormatColumnDefsForScope(data.Scope), getPredicateDefsForColId: (colId) => api.formatColumnApi.internalApi.getFormatColumnDefsForScope({ ColumnIds: [colId] }), showNoRule: true, showBoolean: true, showAggregation: false, showObservable: false, showQueryBuilder: true, showPredicate: !api.columnScopeApi.scopeIsAll(data.Scope), data: data, onChange: (formatColumn) => props.onChange(formatColumn), descriptions: {
|
|
14
|
+
return (React.createElement(EntityRulesEditor_1.EntityRulesEditor, { module: moduleInfo.ModuleName, defaultPredicateId: props.defaultPredicateId, predicateDefs: api.formatColumnApi.internalApi.getFormatColumnDefsForScope(data.Scope), getPredicateDefsForColId: (colId) => api.formatColumnApi.internalApi.getFormatColumnDefsForScope({ ColumnIds: [colId] }), showNoRule: true, showBoolean: true, showAggregation: false, showObservable: false, showQueryBuilder: true, showPredicate: !api.columnScopeApi.scopeIsAll(data.Scope), data: data, onChange: (formatColumn) => props.onChange(formatColumn), descriptions: {
|
|
17
15
|
selectPredicate: 'Create a Format Column Rule - to be applied when data changes',
|
|
18
16
|
useBooleanQuery: (React.createElement(React.Fragment, null,
|
|
19
17
|
"Use an BooleanQuery if ",
|
|
@@ -2,7 +2,7 @@ import * as React from 'react';
|
|
|
2
2
|
import { FreeTextColumn } from '../../../AdaptableState/FreeTextColumnState';
|
|
3
3
|
import { AdaptableApi } from '../../../Api/AdaptableApi';
|
|
4
4
|
export declare const renderFreeTextColumnSummary: (data: FreeTextColumn) => React.JSX.Element;
|
|
5
|
-
export declare const isValidFreeTextColumn: (data: FreeTextColumn, api: AdaptableApi) => true | "A Column
|
|
5
|
+
export declare const isValidFreeTextColumn: (data: FreeTextColumn, api: AdaptableApi) => true | "A Column Name is required" | "A column with this Name already exists" | "A data type is required for the column";
|
|
6
6
|
export type FreeTextColumnSettingsWizardSectionProps = {
|
|
7
7
|
onChange: (data: FreeTextColumn) => void;
|
|
8
8
|
isEdit: boolean;
|