@adaptabletools/adaptable-cjs 20.2.11 → 20.3.0-canary.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/agGrid.d.ts +4 -0
- package/agGrid.js +4 -0
- package/base.css +6 -6
- package/base.css.map +1 -1
- package/index.css +6 -6
- package/index.css.map +1 -1
- package/package.json +1 -1
- package/src/AdaptableInterfaces/IAdaptable.d.ts +1 -0
- package/src/AdaptableOptions/ColumnOptions.d.ts +3 -2
- package/src/AdaptableOptions/DefaultAdaptableOptions.js +1 -0
- package/src/AdaptableOptions/PredicateOptions.d.ts +2 -1
- package/src/AdaptableState/Common/AdaptableColumn.d.ts +5 -3
- package/src/AdaptableState/Common/AdaptableColumn.js +8 -1
- package/src/AdaptableState/Common/AdaptableFormat.d.ts +4 -0
- package/src/AdaptableState/Common/AdaptableObject.d.ts +3 -3
- package/src/AdaptableState/Common/AdaptablePredicate.d.ts +4 -0
- package/src/AdaptableState/Common/AdaptablePredicate.js +32 -3
- package/src/AdaptableState/Common/ColumnScope.d.ts +1 -1
- package/src/AdaptableState/Common/CustomWindowConfig.d.ts +40 -0
- package/src/AdaptableState/Common/ProgressIndicatorConfig.d.ts +8 -1
- package/src/AdaptableState/Common/RowScope.d.ts +4 -0
- package/src/AdaptableState/FormatColumnState.d.ts +10 -0
- package/src/AdaptableState/StyledColumnState.d.ts +4 -0
- package/src/Api/ColumnApi.d.ts +6 -0
- package/src/Api/GridApi.d.ts +8 -3
- package/src/Api/Implementation/ColumnApiImpl.d.ts +2 -1
- package/src/Api/Implementation/ColumnApiImpl.js +17 -0
- package/src/Api/Implementation/GridApiImpl.d.ts +1 -0
- package/src/Api/Implementation/GridApiImpl.js +3 -0
- package/src/Api/Implementation/PredicateApiImpl.d.ts +1 -1
- package/src/Api/Implementation/PredicateApiImpl.js +25 -1
- package/src/Api/Implementation/UserInterfaceApiImpl.d.ts +3 -1
- package/src/Api/Implementation/UserInterfaceApiImpl.js +6 -0
- package/src/Api/Internal/ColumnInternalApi.d.ts +3 -1
- package/src/Api/Internal/ColumnInternalApi.js +7 -0
- package/src/Api/Internal/FormatColumnInternalApi.d.ts +13 -4
- package/src/Api/Internal/FormatColumnInternalApi.js +33 -6
- package/src/Api/UserInterfaceApi.d.ts +16 -4
- package/src/Redux/ActionsReducers/LayoutRedux.d.ts +7 -3
- package/src/Redux/ActionsReducers/PopupRedux.js +1 -0
- package/src/Strategy/StyledColumnModule.js +8 -3
- package/src/Strategy/Utilities/FormatColumn/getFormatColumnSettingsViewItems.js +6 -0
- package/src/Utilities/Constants/GeneralConstants.d.ts +1 -0
- package/src/Utilities/Constants/GeneralConstants.js +3 -2
- package/src/Utilities/Helpers/FormatHelper.js +3 -0
- package/src/Utilities/Services/ModuleService.js +2 -2
- package/src/Utilities/getScopeViewItems.js +1 -1
- package/src/View/Components/ColumnFilter/utils.js +9 -4
- package/src/View/Components/Popups/AdaptablePopupConfirmation.js +3 -4
- package/src/View/Components/Popups/AdaptablePopupPrompt.js +3 -4
- package/src/View/Components/Popups/WindowPopups/WindowPopups.js +1 -5
- package/src/View/DataChangeHistory/DataChangeHistoryGrid.js +1 -0
- package/src/View/Export/Wizard/ReportColumnsWizardSection.js +1 -1
- package/src/View/FormatColumn/Wizard/FormatColumnFormatWizardSection.js +16 -1
- package/src/View/FormatColumn/Wizard/FormatColumnScopeWizardSection.js +67 -23
- package/src/View/FormatColumn/Wizard/FormatColumnSettingsWizardSection.js +34 -2
- package/src/View/FormatColumn/Wizard/FormatColumnWizard.js +1 -1
- package/src/View/Layout/Wizard/sections/ColumnsSection.js +2 -1
- package/src/View/StyledColumn/Wizard/StyledColumnBadgeSection.js +18 -21
- package/src/View/StyledColumn/Wizard/StyledColumnWizard.js +1 -1
- package/src/View/StyledColumn/Wizard/StyledColumnWizardSettingsSection.js +22 -2
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview.js +6 -13
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgeSettings.d.ts +5 -0
- package/src/View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgeSettings.js +34 -0
- package/src/agGrid/AdaptableAgGrid.d.ts +1 -0
- package/src/agGrid/AdaptableAgGrid.js +28 -1
- package/src/agGrid/AgGridAdapter.js +2 -6
- package/src/agGrid/AgGridColumnAdapter.d.ts +4 -1
- package/src/agGrid/AgGridColumnAdapter.js +111 -10
- package/src/agGrid/cellRenderers/ActionColumnRenderer.js +14 -2
- package/src/agGrid/cellRenderers/BadgeRenderer.js +27 -13
- package/src/components/ProgressIndicator/ProgressIndicator.js +18 -4
- package/src/env.js +2 -2
- package/src/layout-manager/src/index.js +2 -2
- package/src/metamodel/adaptable.metamodel.d.ts +43 -0
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/types.d.ts +2 -2
- package/tsconfig.cjs.tsbuildinfo +1 -1
|
@@ -25,6 +25,12 @@ export interface FormatColumn extends SuspendableObject {
|
|
|
25
25
|
* Where Format will be applied: whole Row, some Columns, or Columns of DataType
|
|
26
26
|
*/
|
|
27
27
|
Scope: ColumnScope;
|
|
28
|
+
/**
|
|
29
|
+
* Which part of the Column to apply Format to: `cell`, `column header`
|
|
30
|
+
*
|
|
31
|
+
* @defaultValue ['cell']
|
|
32
|
+
*/
|
|
33
|
+
Target?: FormatColumnTarget[];
|
|
28
34
|
/**
|
|
29
35
|
* Rule to decide whether to apply Format; if undefined Format is always applied
|
|
30
36
|
*/
|
|
@@ -51,6 +57,10 @@ export interface FormatColumn extends SuspendableObject {
|
|
|
51
57
|
*/
|
|
52
58
|
ColumnGroupScope?: ColumnGroupScope;
|
|
53
59
|
}
|
|
60
|
+
/**
|
|
61
|
+
* Target for Format Column: Specifies which visual elements of the column receive formatting
|
|
62
|
+
*/
|
|
63
|
+
export type FormatColumnTarget = 'cell' | 'columnHeader';
|
|
54
64
|
/**
|
|
55
65
|
* Defines Column Group Scope
|
|
56
66
|
*/
|
|
@@ -178,6 +178,10 @@ export interface BadgeStyleDefinition {
|
|
|
178
178
|
* Position of Icon in the Badge - 'Start' or 'End'
|
|
179
179
|
*/
|
|
180
180
|
IconPosition?: 'Start' | 'End';
|
|
181
|
+
/**
|
|
182
|
+
* Only show an Icon and no Cell text
|
|
183
|
+
*/
|
|
184
|
+
IconOnly?: boolean;
|
|
181
185
|
}
|
|
182
186
|
/**
|
|
183
187
|
* Collection of Badge Style Definitions to display in a Badge Styled Column
|
package/src/Api/ColumnApi.d.ts
CHANGED
|
@@ -323,4 +323,10 @@ export interface ColumnApi {
|
|
|
323
323
|
* @param columnId Column to use
|
|
324
324
|
*/
|
|
325
325
|
getAGGridColumnForColumnId(columnId: string): Column;
|
|
326
|
+
/**
|
|
327
|
+
* Checks if the Column with given Column Identifier (columnId or ColDef) has a specific Column Type
|
|
328
|
+
* @param columnIdentifier - ColumnId or ColDef to check
|
|
329
|
+
* @param columnType - Column Type to check for
|
|
330
|
+
*/
|
|
331
|
+
hasColumnType(columnIdentifier: string | ColDef, columnType: string): boolean;
|
|
326
332
|
}
|
package/src/Api/GridApi.d.ts
CHANGED
|
@@ -382,9 +382,14 @@ export interface GridApi {
|
|
|
382
382
|
*/
|
|
383
383
|
isGroupRowNode(rowNode: IRowNode): boolean;
|
|
384
384
|
/**
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
385
|
+
* Whether given Row Node is a Grand Total Row
|
|
386
|
+
* @param rowNode Node to check
|
|
387
|
+
*/
|
|
388
|
+
isGrandTotalRowNode(rowNode: IRowNode): boolean;
|
|
389
|
+
/**
|
|
390
|
+
* Whether given Row Node is visible
|
|
391
|
+
* @param rowNode Node to check
|
|
392
|
+
*/
|
|
388
393
|
isVisibleRowNode(rowNode: IRowNode): boolean;
|
|
389
394
|
/**
|
|
390
395
|
* Whether given Row Node is in a Summary Row
|
|
@@ -78,10 +78,11 @@ export declare class ColumnApiImpl extends ApiBase implements ColumnApi {
|
|
|
78
78
|
getPrimaryKeyColumn(): AdaptableColumn<any>;
|
|
79
79
|
getDefaultAggFunc(columnId: string): string;
|
|
80
80
|
openColumnInfoSettingsPanel(): void;
|
|
81
|
-
getColumnTypes(): string[];
|
|
81
|
+
getColumnTypes(): import("../../AdaptableState/Common/Types").TypeHint<string, import("../../types").AdaptableColumnType>[];
|
|
82
82
|
getColumnsByColumnType(columnType: string): AdaptableColumn[];
|
|
83
83
|
getRowGroupedColumns(): AdaptableColumn[];
|
|
84
84
|
setColumnCaption(columnId: string, caption: string): void;
|
|
85
85
|
getAGGridColDefForColumnId(columnId: string): ColDef | ColGroupDef;
|
|
86
86
|
getAGGridColumnForColumnId(columnId: string): Column;
|
|
87
|
+
hasColumnType(columnIdentifier: string | ColDef, columnType: string): boolean;
|
|
87
88
|
}
|
|
@@ -510,5 +510,22 @@ class ColumnApiImpl extends ApiBase_1.ApiBase {
|
|
|
510
510
|
getAGGridColumnForColumnId(columnId) {
|
|
511
511
|
return this.getAgGridApi().getColumn(columnId);
|
|
512
512
|
}
|
|
513
|
+
hasColumnType(columnIdentifier, columnType) {
|
|
514
|
+
if (!columnIdentifier) {
|
|
515
|
+
return false;
|
|
516
|
+
}
|
|
517
|
+
const colDef = typeof columnIdentifier === 'string'
|
|
518
|
+
? this.getAgGridApi().getColumnDef(columnIdentifier)
|
|
519
|
+
: columnIdentifier;
|
|
520
|
+
if (!colDef?.type) {
|
|
521
|
+
return false;
|
|
522
|
+
}
|
|
523
|
+
if (Array.isArray(colDef.type)) {
|
|
524
|
+
return colDef.type.includes(columnType);
|
|
525
|
+
}
|
|
526
|
+
else {
|
|
527
|
+
return colDef.type === columnType;
|
|
528
|
+
}
|
|
529
|
+
}
|
|
513
530
|
}
|
|
514
531
|
exports.ColumnApiImpl = ColumnApiImpl;
|
|
@@ -99,6 +99,7 @@ export declare class GridApiImpl extends ApiBase implements GridApi {
|
|
|
99
99
|
isMasterDetailGrid(): boolean;
|
|
100
100
|
isTreeDataGrid(): boolean;
|
|
101
101
|
isGroupRowNode(rowNode: IRowNode): boolean;
|
|
102
|
+
isGrandTotalRowNode(rowNode: IRowNode): boolean;
|
|
102
103
|
isVisibleRowNode(rowNode: IRowNode): boolean;
|
|
103
104
|
isSummaryNode(rowNode: IRowNode): boolean;
|
|
104
105
|
isQuickFilterAvailable(): boolean;
|
|
@@ -386,6 +386,9 @@ class GridApiImpl extends ApiBase_1.ApiBase {
|
|
|
386
386
|
isGroupRowNode(rowNode) {
|
|
387
387
|
return this._adaptable.isGroupRowNode(rowNode);
|
|
388
388
|
}
|
|
389
|
+
isGrandTotalRowNode(rowNode) {
|
|
390
|
+
return this._adaptable.isGrandTotalRowNode(rowNode);
|
|
391
|
+
}
|
|
389
392
|
isVisibleRowNode(rowNode) {
|
|
390
393
|
return this._adaptable.isRowNodeVisible(rowNode);
|
|
391
394
|
}
|
|
@@ -9,7 +9,7 @@ export declare class PredicateApiImpl extends ApiBase implements PredicateApi {
|
|
|
9
9
|
getPredicateDefs(): AdaptablePredicateDef<string>[];
|
|
10
10
|
getSystemPredicateDefs(): AdaptablePredicateDef<string>[];
|
|
11
11
|
getSystemPredicateDefsByModuleScope<PREDICATE_TYPE extends string = string>(moduleScope: PredicateModuleScope): AdaptablePredicateDef<PREDICATE_TYPE>[];
|
|
12
|
-
getCustomPredicateDefs(): AdaptablePredicateDef
|
|
12
|
+
getCustomPredicateDefs(): AdaptablePredicateDef[];
|
|
13
13
|
getPredicateDefsByModuleScope(moduleScope: PredicateModuleScope): AdaptablePredicateDef[];
|
|
14
14
|
getPredicateDefById(predicateId: string): AdaptablePredicateDef;
|
|
15
15
|
getSystemPredicateDefById(predicateId: string): AdaptablePredicateDef;
|
|
@@ -22,7 +22,31 @@ class PredicateApiImpl extends ApiBase_1.ApiBase {
|
|
|
22
22
|
return AdaptablePredicate_1.SystemPredicateDefs.filter((p) => p.moduleScope.includes(moduleScope));
|
|
23
23
|
}
|
|
24
24
|
getCustomPredicateDefs() {
|
|
25
|
-
|
|
25
|
+
const predicateDefsMap = new Map(this.getSystemPredicateDefs().map((p) => [p.id, p]));
|
|
26
|
+
const customPredicateDefs = this.getPredicateOptions().customPredicateDefs || [];
|
|
27
|
+
return customPredicateDefs
|
|
28
|
+
.map((p) => {
|
|
29
|
+
if ('extends' in p) {
|
|
30
|
+
const foundPredicateDef = predicateDefsMap.get(p.extends);
|
|
31
|
+
if (!foundPredicateDef) {
|
|
32
|
+
this.logWarn(`Custom predicate with ID '${p.id}' references a missing 'extends' target '${p.extends}'. No such system or custom predicate found.`);
|
|
33
|
+
return null;
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
const { extends: _, ...rest } = p;
|
|
37
|
+
const result = {
|
|
38
|
+
...foundPredicateDef,
|
|
39
|
+
...rest,
|
|
40
|
+
id: rest.id,
|
|
41
|
+
};
|
|
42
|
+
predicateDefsMap.set(result.id, result);
|
|
43
|
+
return result;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
predicateDefsMap.set(p.id, p);
|
|
47
|
+
return p;
|
|
48
|
+
})
|
|
49
|
+
.filter((p) => p !== null);
|
|
26
50
|
}
|
|
27
51
|
getPredicateDefsByModuleScope(moduleScope) {
|
|
28
52
|
return this.getPredicateDefs().filter((p) => p.moduleScope.includes(moduleScope));
|
|
@@ -17,7 +17,9 @@ export declare class UserInterfaceApiImpl extends ApiBase implements UserInterfa
|
|
|
17
17
|
getAdaptableObjectTags(): AdaptableObjectTag[] | undefined;
|
|
18
18
|
getAdaptableObjectsWithTag(tag: AdaptableObjectTag, adaptableModule?: AdaptableModule): AdaptableObject[] | undefined;
|
|
19
19
|
getCustomIconDefinition(iconName: string): import("../../types").AdaptableIcon | import("../../types").CustomIcon;
|
|
20
|
-
showProgressIndicator(config: ProgressIndicatorConfig):
|
|
20
|
+
showProgressIndicator(config: ProgressIndicatorConfig): {
|
|
21
|
+
close: () => void;
|
|
22
|
+
};
|
|
21
23
|
hideProgressIndicator(): void;
|
|
22
24
|
openCustomWindowPopup(config: CustomWindowConfig): {
|
|
23
25
|
close: () => void;
|
|
@@ -87,6 +87,9 @@ class UserInterfaceApiImpl extends ApiBase_1.ApiBase {
|
|
|
87
87
|
return customIcon;
|
|
88
88
|
}
|
|
89
89
|
showProgressIndicator(config) {
|
|
90
|
+
const close = () => {
|
|
91
|
+
this.hideProgressIndicator();
|
|
92
|
+
};
|
|
90
93
|
if (config.delay) {
|
|
91
94
|
this.showProgressIndicatorTimeout = setTimeout(() => {
|
|
92
95
|
this.dispatchAction((0, PopupRedux_1.ProgressIndicatorShow)(config));
|
|
@@ -95,6 +98,7 @@ class UserInterfaceApiImpl extends ApiBase_1.ApiBase {
|
|
|
95
98
|
else {
|
|
96
99
|
this.dispatchAction((0, PopupRedux_1.ProgressIndicatorShow)(config));
|
|
97
100
|
}
|
|
101
|
+
return { close };
|
|
98
102
|
}
|
|
99
103
|
hideProgressIndicator() {
|
|
100
104
|
if (this.showProgressIndicatorTimeout) {
|
|
@@ -115,6 +119,8 @@ class UserInterfaceApiImpl extends ApiBase_1.ApiBase {
|
|
|
115
119
|
render: config.render,
|
|
116
120
|
frameworkComponent: config.frameworkComponent,
|
|
117
121
|
onFrameworkComponentDestroyed: config.onFrameworkComponentDestroyed,
|
|
122
|
+
size: config.size,
|
|
123
|
+
position: config.position,
|
|
118
124
|
},
|
|
119
125
|
Icon: config.icon,
|
|
120
126
|
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
2
|
-
import { Column, HeaderValueGetterParams, IRowNode } from 'ag-grid-enterprise';
|
|
2
|
+
import { ColDef, Column, HeaderValueGetterParams, IRowNode } from 'ag-grid-enterprise';
|
|
3
3
|
import { CustomSort } from '../../AdaptableState/CustomSortState';
|
|
4
4
|
import { ColumnValuesComparer } from '../../AdaptableOptions/CustomSortOptions';
|
|
5
5
|
import { AdaptableColumn } from '../../types';
|
|
@@ -33,5 +33,7 @@ export declare class ColumnInternalApi extends ApiBase {
|
|
|
33
33
|
isSpecialColumn(columnId: string, column?: AdaptableColumn): boolean;
|
|
34
34
|
getColumnHeaderName(params: HeaderValueGetterParams): string;
|
|
35
35
|
private buildColumnHeaderContext;
|
|
36
|
+
hasArrayDataType(column: AdaptableColumn): boolean;
|
|
36
37
|
getQueryableColumnsForUIEditor(): AdaptableColumn[];
|
|
38
|
+
isAlwaysHiddenColumn(columnIdentifier: string | ColDef): boolean;
|
|
37
39
|
}
|
|
@@ -10,6 +10,7 @@ const ColumnApiImpl_1 = require("../Implementation/ColumnApiImpl");
|
|
|
10
10
|
const destructurePivotColumnId_1 = require("../../layout-manager/src/destructurePivotColumnId");
|
|
11
11
|
const isPivotColumnTotal_1 = require("../../layout-manager/src/isPivotColumnTotal");
|
|
12
12
|
const isPivotAggTotalColumn_1 = require("../../layout-manager/src/isPivotAggTotalColumn");
|
|
13
|
+
const AdaptableColumn_1 = require("../../AdaptableState/Common/AdaptableColumn");
|
|
13
14
|
function getAutoRowGroupColumnIdFor(columnId) {
|
|
14
15
|
return `${GeneralConstants_1.AG_GRID_GROUPED_COLUMN}-${columnId}`;
|
|
15
16
|
}
|
|
@@ -287,10 +288,16 @@ class ColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
287
288
|
// if nothing matched, we skip this column[group]
|
|
288
289
|
return 'skip';
|
|
289
290
|
}
|
|
291
|
+
hasArrayDataType(column) {
|
|
292
|
+
return ['textArray', 'numberArray', 'tupleArray', 'objectArray'].includes(column.dataType);
|
|
293
|
+
}
|
|
290
294
|
getQueryableColumnsForUIEditor() {
|
|
291
295
|
return this.getColumnApi()
|
|
292
296
|
.getQueryableColumns()
|
|
293
297
|
.filter((column) => !column.isGeneratedPivotResultColumn && !column.isGeneratedRowGroupColumn);
|
|
294
298
|
}
|
|
299
|
+
isAlwaysHiddenColumn(columnIdentifier) {
|
|
300
|
+
return this.getColumnApi().hasColumnType(columnIdentifier, AdaptableColumn_1.HIDDEN_COLUMN_TYPE);
|
|
301
|
+
}
|
|
295
302
|
}
|
|
296
303
|
exports.ColumnInternalApi = ColumnInternalApi;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IRowNode } from 'ag-grid-enterprise';
|
|
2
|
-
import { AdaptableColumn, AdaptableFormat, AdaptablePredicateDef, ColumnScope, FormatColumn, StringFormatterOptions } from '../../types';
|
|
2
|
+
import { AdaptableColumn, AdaptableFormat, AdaptablePredicateDef, ColumnScope, FormatColumn, FormatColumnTarget, StringFormatterOptions } from '../../types';
|
|
3
3
|
import { ApiBase } from '../Implementation/ApiBase';
|
|
4
4
|
export declare class FormatColumnInternalApi extends ApiBase {
|
|
5
5
|
/**
|
|
@@ -28,7 +28,8 @@ export declare class FormatColumnInternalApi extends ApiBase {
|
|
|
28
28
|
* @param config
|
|
29
29
|
* @returns list of FormatColumn
|
|
30
30
|
*/
|
|
31
|
-
getFormatColumnsWithStyleForColumn(column: AdaptableColumn, config
|
|
31
|
+
getFormatColumnsWithStyleForColumn(column: AdaptableColumn, config: {
|
|
32
|
+
target: FormatColumnTarget;
|
|
32
33
|
includeSuspended?: boolean;
|
|
33
34
|
}): FormatColumn[];
|
|
34
35
|
/**
|
|
@@ -36,8 +37,9 @@ export declare class FormatColumnInternalApi extends ApiBase {
|
|
|
36
37
|
* @param column The Column for which to retrieve the Format Column
|
|
37
38
|
* @returns format columns
|
|
38
39
|
*/
|
|
39
|
-
getFormatColumnWithStyleClassNameForColumn(column: AdaptableColumn, config
|
|
40
|
+
getFormatColumnWithStyleClassNameForColumn(column: AdaptableColumn, config: {
|
|
40
41
|
includeSuspended?: boolean;
|
|
42
|
+
target: FormatColumnTarget;
|
|
41
43
|
}): FormatColumn[];
|
|
42
44
|
getFormatColumnWithColumnInScope(formatColumns: FormatColumn[], column: AdaptableColumn): FormatColumn[];
|
|
43
45
|
private getFormatColumnInColumnScope;
|
|
@@ -85,7 +87,14 @@ export declare class FormatColumnInternalApi extends ApiBase {
|
|
|
85
87
|
* @param column
|
|
86
88
|
* @param params
|
|
87
89
|
*/
|
|
88
|
-
|
|
90
|
+
formatColumnShouldRenderInCell(formatColumn: FormatColumn, column: AdaptableColumn, rowNode: IRowNode, cellValue: any): boolean;
|
|
91
|
+
/**
|
|
92
|
+
* Checks if format column is relevant for a given Column Header
|
|
93
|
+
*
|
|
94
|
+
* @param formatColumn
|
|
95
|
+
* @param column
|
|
96
|
+
*/
|
|
97
|
+
formatColumnShouldRenderInHeader(formatColumn: FormatColumn, column: AdaptableColumn): boolean;
|
|
89
98
|
private evaluatePredicate;
|
|
90
99
|
private evaluateExpression;
|
|
91
100
|
/**
|
|
@@ -79,7 +79,13 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
79
79
|
* @returns list of FormatColumn
|
|
80
80
|
*/
|
|
81
81
|
getFormatColumnsWithStyleForColumn(column, config) {
|
|
82
|
-
const formatColumns = this.getAllFormatColumnWithStyleAndCellAlignment()
|
|
82
|
+
const formatColumns = this.getAllFormatColumnWithStyleAndCellAlignment()
|
|
83
|
+
.filter((formatColumn) => {
|
|
84
|
+
// FormatColumn default target is 'cell', so if no target is specified, we assume 'cell'
|
|
85
|
+
const fcTarget = formatColumn.Target ?? ['cell'];
|
|
86
|
+
return fcTarget.includes(config.target);
|
|
87
|
+
})
|
|
88
|
+
.filter((formatColumn) => config?.includeSuspended || !formatColumn.IsSuspended);
|
|
83
89
|
return this.getFormatColumnWithColumnInScope(formatColumns, column);
|
|
84
90
|
}
|
|
85
91
|
/**
|
|
@@ -214,15 +220,20 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
214
220
|
* @param column
|
|
215
221
|
* @param params
|
|
216
222
|
*/
|
|
217
|
-
|
|
223
|
+
formatColumnShouldRenderInCell(formatColumn, column, rowNode, cellValue) {
|
|
218
224
|
// suspended is important to be first
|
|
219
225
|
if (formatColumn.IsSuspended) {
|
|
220
226
|
return false;
|
|
221
227
|
}
|
|
222
228
|
const isSummaryNode = this.getGridApi().isSummaryNode(rowNode);
|
|
223
229
|
const isGroupedRowNode = this.getGridApi().isGroupRowNode(rowNode);
|
|
224
|
-
|
|
225
|
-
if (
|
|
230
|
+
const isGrandTotalRowNode = this.getGridApi().isGrandTotalRowNode(rowNode);
|
|
231
|
+
if (isGrandTotalRowNode) {
|
|
232
|
+
if (formatColumn.RowScope?.ExcludeTotalRows) {
|
|
233
|
+
return false;
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
else if (isSummaryNode) {
|
|
226
237
|
if (formatColumn.RowScope?.ExcludeSummaryRows) {
|
|
227
238
|
return false;
|
|
228
239
|
}
|
|
@@ -262,6 +273,22 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
262
273
|
// nothing has passed then return false
|
|
263
274
|
return false;
|
|
264
275
|
}
|
|
276
|
+
/**
|
|
277
|
+
* Checks if format column is relevant for a given Column Header
|
|
278
|
+
*
|
|
279
|
+
* @param formatColumn
|
|
280
|
+
* @param column
|
|
281
|
+
*/
|
|
282
|
+
formatColumnShouldRenderInHeader(formatColumn, column) {
|
|
283
|
+
if (formatColumn.IsSuspended) {
|
|
284
|
+
return false;
|
|
285
|
+
}
|
|
286
|
+
if (formatColumn.ColumnGroupScope &&
|
|
287
|
+
!this.getFormatColumnApi().internalApi.formatColumnWithColumnGroupScopeShouldRender(formatColumn, column)) {
|
|
288
|
+
return false;
|
|
289
|
+
}
|
|
290
|
+
return true;
|
|
291
|
+
}
|
|
265
292
|
evaluatePredicate(formatColumn, predicateDefHandlerContext) {
|
|
266
293
|
return this.getPredicateApi().handleColumnPredicates(formatColumn.Rule?.Predicates, predicateDefHandlerContext, false);
|
|
267
294
|
}
|
|
@@ -286,7 +313,7 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
286
313
|
* @param params
|
|
287
314
|
*/
|
|
288
315
|
getFormatColumnsRelevantForColumn(formatColumns, column, params) {
|
|
289
|
-
return formatColumns.filter((formatColumn) => this.
|
|
316
|
+
return formatColumns.filter((formatColumn) => this.formatColumnShouldRenderInCell(formatColumn, column, params.node, params.value));
|
|
290
317
|
}
|
|
291
318
|
/**
|
|
292
319
|
* Extract from the given FormatColumns the one which is the most relevant for a given cell (intersection of given AdaptableColumn and RowNode)
|
|
@@ -296,7 +323,7 @@ class FormatColumnInternalApi extends ApiBase_1.ApiBase {
|
|
|
296
323
|
* @param params
|
|
297
324
|
*/
|
|
298
325
|
getMostRelevantFormatColumnForColumn(formatColumns, column, params) {
|
|
299
|
-
return formatColumns.find((formatColumn) => this.
|
|
326
|
+
return formatColumns.find((formatColumn) => this.formatColumnShouldRenderInCell(formatColumn, column, params.node, params.value));
|
|
300
327
|
}
|
|
301
328
|
/**
|
|
302
329
|
* Retrieves all Format Columns which have an Expression
|
|
@@ -46,17 +46,29 @@ export interface UserInterfaceApi {
|
|
|
46
46
|
* Displays a progress indicator
|
|
47
47
|
* @param config.progressText - text to display in the progress indicator
|
|
48
48
|
* @param config.render - render function for a custom progress indicator (if not using a framework component)
|
|
49
|
-
* @param config.frameworkComponent - the framework (React/Angular) component to render as progress indicator
|
|
49
|
+
* @param config.frameworkComponent - the framework (React/Angular/Vue) component to render as progress indicator
|
|
50
|
+
* @param config.renderMode - how to render the custom component ('content' or 'dialog'). Applies to both render and frameworkComponent.
|
|
50
51
|
* @param config.delay - delay before showing the progress indicator (in milliseconds)
|
|
52
|
+
* @returns An object with a close method to close the window
|
|
51
53
|
*/
|
|
52
|
-
showProgressIndicator(config: ProgressIndicatorConfig):
|
|
54
|
+
showProgressIndicator(config: ProgressIndicatorConfig): {
|
|
55
|
+
close: () => void;
|
|
56
|
+
};
|
|
53
57
|
/**
|
|
54
58
|
* Hides the progress indicator
|
|
55
59
|
*/
|
|
56
60
|
hideProgressIndicator(): void;
|
|
57
61
|
/**
|
|
58
|
-
* Opens
|
|
59
|
-
* @param config
|
|
62
|
+
* Opens a custom window popup
|
|
63
|
+
* @param config - The configuration for the custom window
|
|
64
|
+
* @param config.id - Unique identifier for the custom window
|
|
65
|
+
* @param config.title - Title of the custom window
|
|
66
|
+
* @param config.icon - Icon to display in the custom window heading
|
|
67
|
+
* @param config.render - Render function to display custom content in the window (if not using a framework component)
|
|
68
|
+
* @param config.frameworkComponent - A React, Angular or Vue Framework component to use for the custom window content
|
|
69
|
+
* @param config.onFrameworkComponentDestroyed - Callback function to be called when the framework component is destroyed
|
|
70
|
+
* @param config.renderMode - How to render the custom component ('content' or 'dialog'). Applies to both render and frameworkComponent.
|
|
71
|
+
* @returns An object with a close method to close the window
|
|
60
72
|
*/
|
|
61
73
|
openCustomWindowPopup(config: CustomWindowConfig): {
|
|
62
74
|
close: () => void;
|
|
@@ -169,12 +169,16 @@ export declare const getColumnFilterSelector: (state: AdaptableState, columnId:
|
|
|
169
169
|
PredicatesOperator?: import("../../types").PredicatesOperator;
|
|
170
170
|
IsSuspended?: boolean;
|
|
171
171
|
Uuid?: string;
|
|
172
|
+
/**
|
|
173
|
+
* @ReduxAction Layout Module is ready
|
|
174
|
+
*/
|
|
172
175
|
Source?: "InitialState" | "User";
|
|
176
|
+
/**
|
|
177
|
+
* @ReduxAction A Layout has been edited
|
|
178
|
+
*/
|
|
173
179
|
AdaptableVersion?: `${string}.${string}.${string}`;
|
|
174
180
|
IsReadOnly?: boolean;
|
|
175
181
|
Tags?: string[];
|
|
176
|
-
Metadata?: any;
|
|
177
|
-
* @ReduxAction A Column Filter has been edited
|
|
178
|
-
*/
|
|
182
|
+
Metadata?: any;
|
|
179
183
|
};
|
|
180
184
|
export declare const LayoutReducer: Redux.Reducer<LayoutState>;
|
|
@@ -337,6 +337,7 @@ const PopupReducer = (state = initialState, action) => {
|
|
|
337
337
|
text: actionTypedAdd.progressIndicatorConfig.text,
|
|
338
338
|
render: actionTypedAdd.progressIndicatorConfig.render,
|
|
339
339
|
frameworkComponent: actionTypedAdd.progressIndicatorConfig.frameworkComponent,
|
|
340
|
+
renderMode: actionTypedAdd.progressIndicatorConfig.renderMode,
|
|
340
341
|
},
|
|
341
342
|
};
|
|
342
343
|
return Object.assign({}, state, updatedState);
|
|
@@ -10,6 +10,7 @@ const StyledColumnWizardStyleSection_1 = require("../View/StyledColumn/Wizard/St
|
|
|
10
10
|
const ObjectFactory_1 = tslib_1.__importDefault(require("../Utilities/ObjectFactory"));
|
|
11
11
|
const StyledColumnBadgePreview_1 = require("../View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgePreview");
|
|
12
12
|
const getObjectTagsViewItems_1 = require("../Utilities/getObjectTagsViewItems");
|
|
13
|
+
const StyledColumnBadgeSettings_1 = require("../View/StyledColumn/Wizard/StyledColumnWizardStyleSection/Components/StyledColumnBadgeSettings");
|
|
13
14
|
class StyledColumnModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
14
15
|
constructor(api) {
|
|
15
16
|
super(ModuleConstants.StyledColumnModuleId, ModuleConstants.StyledColumnFriendlyName, 'brush', 'StyledColumnPopup', // to change
|
|
@@ -147,9 +148,8 @@ class StyledColumnModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
147
148
|
returnColumnMenuItems.push(...[newGrandientButton, newPercentBarButton, newBadgeButton]);
|
|
148
149
|
break;
|
|
149
150
|
case 'text':
|
|
150
|
-
returnColumnMenuItems.push(newBadgeButton);
|
|
151
|
-
break;
|
|
152
151
|
case 'textArray':
|
|
152
|
+
case 'numberArray':
|
|
153
153
|
returnColumnMenuItems.push(newBadgeButton);
|
|
154
154
|
break;
|
|
155
155
|
}
|
|
@@ -192,15 +192,20 @@ class StyledColumnModule extends AdaptableModuleBase_1.AdaptableModuleBase {
|
|
|
192
192
|
}
|
|
193
193
|
if (styledColumn.BadgeStyle) {
|
|
194
194
|
specificTypeItems.push({
|
|
195
|
-
name: '
|
|
195
|
+
name: 'Rows',
|
|
196
196
|
values: [
|
|
197
197
|
`Data Rows: ${styledColumn.BadgeStyle?.RowScope?.ExcludeDataRows ? 'No' : 'Yes'}`,
|
|
198
198
|
`Group Rows: ${styledColumn.BadgeStyle?.RowScope?.ExcludeGroupRows ? 'No' : 'Yes'}`,
|
|
199
199
|
`Summary Rows: ${styledColumn.BadgeStyle?.RowScope?.ExcludeSummaryRows ? 'No' : 'Yes'}`,
|
|
200
|
+
`Total Rows: ${styledColumn.BadgeStyle?.RowScope?.ExcludeTotalRows ? 'No' : 'Yes'}`,
|
|
200
201
|
],
|
|
201
202
|
});
|
|
202
203
|
}
|
|
203
204
|
if (styledColumn.BadgeStyle) {
|
|
205
|
+
specificTypeItems.push({
|
|
206
|
+
name: 'Settings',
|
|
207
|
+
view: StyledColumnBadgeSettings_1.StyledColumnBadgeSettings,
|
|
208
|
+
});
|
|
204
209
|
specificTypeItems.push({
|
|
205
210
|
name: 'Preview',
|
|
206
211
|
view: StyledColumnBadgePreview_1.StyledColumnBadgePreview,
|
|
@@ -16,6 +16,12 @@ const getFormatColumnSettingsViewItems = (formatColumn) => {
|
|
|
16
16
|
if (formatColumn.RowScope.ExcludeSummaryRows) {
|
|
17
17
|
values.push('Exclude Summary Rows');
|
|
18
18
|
}
|
|
19
|
+
if (formatColumn.RowScope.ExcludeTotalRows) {
|
|
20
|
+
values.push('Exclude Total Rows');
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
if (formatColumn.ColumnGroupScope) {
|
|
24
|
+
values.push(`Column Groups: ${formatColumn.ColumnGroupScope === 'Both' ? 'Always' : formatColumn.ColumnGroupScope}`);
|
|
19
25
|
}
|
|
20
26
|
return {
|
|
21
27
|
name: 'Settings',
|
|
@@ -26,6 +26,7 @@ export declare const AG_GRID_SELECTION_COLUMN: string;
|
|
|
26
26
|
export declare const AG_GRID_PIVOT_COLUMN: string;
|
|
27
27
|
export declare const AG_GRID_PIVOT_GRAND_TOTAL_COLUMN: string;
|
|
28
28
|
export declare const AG_GRID_CHART_WINDOW = "AG Grid Window";
|
|
29
|
+
export declare const AG_GRID_GRAND_TOTAL_ROW_ID = "rowGroupFooter_ROOT_NODE_ID";
|
|
29
30
|
export declare const ADAPTABLE_FDC3_ACTION_COLUMN_FRIENDLY_NAME = "(FDC3ActionColumn)";
|
|
30
31
|
export declare const DEFAULT_DATE_FORMAT_PATTERN = "dd-MM-yyyy";
|
|
31
32
|
export declare const DEFAULT_DATE_FORMAT_PATTERN_WITH_TIME = "dd-MM-yyyy HH:mm:ss";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.OBSERVABLE_EXPRESSION_ROW_REMOVED = exports.OBSERVABLE_EXPRESSION_ROW_ADDED = exports.STANDALONE_MODULE_POPUPS = exports.LAYOUT_DELETE_TOOLTIP = exports.LAYOUT_CLONE_TOOLTIP = exports.LAYOUT_EDIT_TOOLTIP = exports.LAYOUT_SAVE_TOOLTIP = exports.LAYOUT_NEW_TABLE_OR_PIVOT_TOOLTIP = exports.LAYOUT_NEW_PIVOT_TOOLTIP = void 0;
|
|
3
|
+
exports.THEME_STYLE = exports.SYSTEM_EXPORT_DESTINATIONS = exports.CLIPBOARD_EXPORT_DESTINATION = exports.DOWNLOAD_EXPORT_DESTINATION = exports.SELECT_REPORT_FORMAT_STRING = exports.SELECT_REPORT_STRING = exports.SYSTEM_REPORT_FORMATS = exports.JSON_FORMAT_REPORT = exports.CSV_FORMAT_REPORT = exports.VISUAL_EXCEL_FORMAT_REPORT = exports.EXCEL_FORMAT_REPORT = exports.SYSTEM_REPORT_NAMES = exports.SELECTED_DATA_REPORT = exports.CURRENT_LAYOUT_REPORT = exports.ALL_DATA_REPORT = exports.SERVER_VALIDATION_MESSAGE_TYPE = exports.SERVER_VALIDATION_HEADER = exports.DEFAULT_LIVE_REPORT_THROTTLE_TIME = exports.MENU_SEPARATOR = exports.QUICK_SEARCH_DEBOUNCE_TIME = exports.DEFAULT_DOUBLE_DISPLAY_VALUE = exports.DEFAULT_INTEGER_DISPLAY_VALUE = exports.DEFAULT_STRING_DISPLAY_VALUE = exports.DEFAULT_DATE_FORMAT_PATTERN_WITH_TIME = exports.DEFAULT_DATE_FORMAT_PATTERN = exports.ADAPTABLE_FDC3_ACTION_COLUMN_FRIENDLY_NAME = exports.AG_GRID_GRAND_TOTAL_ROW_ID = exports.AG_GRID_CHART_WINDOW = exports.AG_GRID_PIVOT_GRAND_TOTAL_COLUMN = exports.AG_GRID_PIVOT_COLUMN = exports.AG_GRID_SELECTION_COLUMN = exports.AG_GRID_GROUPED_COLUMN = exports.GROUP_PATH_SEPARATOR = exports.QUARTER_SECOND = exports.HALF_SECOND = exports.EMPTY_ARRAY = exports.EMPTY_STRING = exports.READ_ONLY_STYLE = exports.AGGRID_TOOLPANEL_COLUMNS = exports.AGGRID_TOOLPANEL_FILTERS = exports.ADAPTABLE_TOOLPANEL_COMPONENT = exports.ADAPTABLE_TOOLPANEL_ID = exports.ADAPTABLE_ID = exports.ADAPTABLE = exports.ERROR_LAYOUT = exports.OS_THEME = exports.DARK_THEME = exports.LIGHT_THEME = exports.MISSING_COLUMN = exports.AUTOGENERATED_PK_COLUMN = void 0;
|
|
4
|
+
exports.OBSERVABLE_EXPRESSION_ROW_REMOVED = exports.OBSERVABLE_EXPRESSION_ROW_ADDED = exports.STANDALONE_MODULE_POPUPS = exports.LAYOUT_DELETE_TOOLTIP = exports.LAYOUT_CLONE_TOOLTIP = exports.LAYOUT_EDIT_TOOLTIP = exports.LAYOUT_SAVE_TOOLTIP = exports.LAYOUT_NEW_TABLE_OR_PIVOT_TOOLTIP = exports.LAYOUT_NEW_PIVOT_TOOLTIP = exports.LAYOUT_NEW_TABLE_TOOLTIP = void 0;
|
|
5
5
|
const normalizeLayoutModel_1 = require("../../layout-manager/src/normalizeLayoutModel");
|
|
6
6
|
exports.AUTOGENERATED_PK_COLUMN = '__ADAPTABLE_PK__';
|
|
7
7
|
exports.MISSING_COLUMN = ' [MISSING]';
|
|
@@ -30,6 +30,7 @@ exports.AG_GRID_SELECTION_COLUMN = 'ag-Grid-SelectionColumn';
|
|
|
30
30
|
exports.AG_GRID_PIVOT_COLUMN = 'pivot_';
|
|
31
31
|
exports.AG_GRID_PIVOT_GRAND_TOTAL_COLUMN = 'PivotRowTotal_pivot_';
|
|
32
32
|
exports.AG_GRID_CHART_WINDOW = 'AG Grid Window';
|
|
33
|
+
exports.AG_GRID_GRAND_TOTAL_ROW_ID = 'rowGroupFooter_ROOT_NODE_ID';
|
|
33
34
|
exports.ADAPTABLE_FDC3_ACTION_COLUMN_FRIENDLY_NAME = '(FDC3ActionColumn)';
|
|
34
35
|
// FIXME AFL - load this from DateInputOptions
|
|
35
36
|
exports.DEFAULT_DATE_FORMAT_PATTERN = 'dd-MM-yyyy';
|
|
@@ -64,6 +64,9 @@ function NumberFormatter(input, options = {}, rowNode, column, api) {
|
|
|
64
64
|
if (options.Floor) {
|
|
65
65
|
n = Math.floor(n);
|
|
66
66
|
}
|
|
67
|
+
if (options.Empty) {
|
|
68
|
+
return ' ';
|
|
69
|
+
}
|
|
67
70
|
let s;
|
|
68
71
|
let digitsToUse;
|
|
69
72
|
if (options.Truncate || options.Ceiling || options.Round || options.Floor) {
|
|
@@ -107,7 +107,7 @@ class ModuleService {
|
|
|
107
107
|
case 'ColumnFilter':
|
|
108
108
|
return learnUrl + 'handbook-column-filter';
|
|
109
109
|
case 'ColumnInfo':
|
|
110
|
-
return learnUrl + 'dev-guide-
|
|
110
|
+
return learnUrl + 'dev-guide-column-grid-column-info';
|
|
111
111
|
case 'Comment':
|
|
112
112
|
return learnUrl + 'handbook-comments';
|
|
113
113
|
case 'CustomSort':
|
|
@@ -133,7 +133,7 @@ class ModuleService {
|
|
|
133
133
|
case 'GridFilter':
|
|
134
134
|
return learnUrl + 'handbook-grid-filter';
|
|
135
135
|
case 'GridInfo':
|
|
136
|
-
return learnUrl + 'dev-guide-
|
|
136
|
+
return learnUrl + 'dev-guide-column-grid-column-info';
|
|
137
137
|
case 'Layout':
|
|
138
138
|
return learnUrl + 'handbook-layouts';
|
|
139
139
|
case 'NamedQuery':
|
|
@@ -18,10 +18,15 @@ dataType) => {
|
|
|
18
18
|
const inputs = (adaptablePredicateDef?.inputs ?? [])?.map((input) => {
|
|
19
19
|
return input.type;
|
|
20
20
|
});
|
|
21
|
-
if (
|
|
22
|
-
['text', 'number', 'date'].includes(dataType)) {
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
if (adaptablePredicateDef.id === 'In' || adaptablePredicateDef.id === 'NotIn') {
|
|
22
|
+
if (['text', 'number', 'date'].includes(dataType)) {
|
|
23
|
+
// add array type
|
|
24
|
+
inputs.push(`${dataType}[]`);
|
|
25
|
+
}
|
|
26
|
+
if (['text[]', 'number[]'].includes(dataType)) {
|
|
27
|
+
// add array type
|
|
28
|
+
inputs.push(dataType);
|
|
29
|
+
}
|
|
25
30
|
}
|
|
26
31
|
const qlPredicateDef = {
|
|
27
32
|
operator: adaptablePredicateDef.id,
|
|
@@ -57,9 +57,8 @@ const AdaptablePopupConfirmation = (props) => {
|
|
|
57
57
|
props.showInputBox && (React.createElement(rebass_1.Box, { padding: 2, "data-name": "body" },
|
|
58
58
|
React.createElement("p", null, "Please enter a comment to confirm"),
|
|
59
59
|
React.createElement(Input_1.default, { marginTop: 2, width: '100%', value: promptText, type: "string", placeholder: "Enter text", onChange: (e) => changeContent(e) }))),
|
|
60
|
-
React.createElement(rebass_1.Flex, { marginTop: 3, padding: 2, "data-name": "footer" },
|
|
61
|
-
React.createElement(SimpleButton_1.default, {
|
|
62
|
-
React.createElement("
|
|
63
|
-
props.cancelButtonText != null ? (React.createElement(SimpleButton_1.default, { "data-name": "cancel", tone: "neutral", variant: "raised", onClick: () => onCancelForm() }, props.cancelButtonText)) : null)))));
|
|
60
|
+
React.createElement(rebass_1.Flex, { marginTop: 3, padding: 2, "data-name": "footer", justifyContent: "space-between" },
|
|
61
|
+
props.cancelButtonText != null ? (React.createElement(SimpleButton_1.default, { "data-name": "cancel", tone: "neutral", variant: "raised", onClick: () => onCancelForm() }, props.cancelButtonText)) : (React.createElement("div", null)),
|
|
62
|
+
React.createElement(SimpleButton_1.default, { tone: "error", "data-name": "delete", variant: "raised", disabled: !canConfirm(), onClick: () => onConfirmmForm() }, props.confirmButtonText))))));
|
|
64
63
|
};
|
|
65
64
|
exports.AdaptablePopupConfirmation = AdaptablePopupConfirmation;
|
|
@@ -40,9 +40,8 @@ const AdaptablePopupPrompt = (props) => {
|
|
|
40
40
|
})))),
|
|
41
41
|
React.createElement(Input_1.default, { autoFocus: true, marginTop: 3, mx: 3, value: promptText, type: "string", placeholder: "Enter text", onChange: (e) => changeContent(e) }),
|
|
42
42
|
React.createElement(rebass_1.Box, { marginTop: 3 },
|
|
43
|
-
React.createElement(rebass_1.Flex, { padding: 2 },
|
|
44
|
-
React.createElement(SimpleButton_1.default, { tone: "
|
|
45
|
-
React.createElement("
|
|
46
|
-
React.createElement(SimpleButton_1.default, { tone: "neutral", variant: "raised", onClick: () => onCloseForm(), "data-name": "cancel" }, "Cancel"))))));
|
|
43
|
+
React.createElement(rebass_1.Flex, { padding: 2, "data-name": "footer", justifyContent: "space-between" },
|
|
44
|
+
React.createElement(SimpleButton_1.default, { tone: "neutral", variant: "raised", onClick: () => onCloseForm(), "data-name": "cancel" }, "Cancel"),
|
|
45
|
+
React.createElement(SimpleButton_1.default, { tone: "accent", "data-name": "ok", variant: "raised", disabled: StringExtensions_1.StringExtensions.IsNullOrEmpty(promptText), onClick: () => onConfirmForm() }, "OK"))))));
|
|
47
46
|
};
|
|
48
47
|
exports.AdaptablePopupPrompt = AdaptablePopupPrompt;
|