@adaptabletools/adaptable 20.0.0-canary.0 → 20.0.0-canary.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/base.css +317 -866
- package/base.css.map +1 -1
- package/index.css +317 -866
- package/index.css.map +1 -1
- package/package.json +3 -3
- package/src/AdaptableInterfaces/IAdaptable.d.ts +2 -1
- package/src/AdaptableOptions/ActionColumnOptions.d.ts +2 -2
- package/src/AdaptableOptions/CellSummaryOptions.d.ts +1 -1
- package/src/AdaptableOptions/ContainerOptions.d.ts +0 -7
- package/src/AdaptableOptions/DefaultAdaptableOptions.js +2 -2
- package/src/AdaptableOptions/EditOptions.d.ts +14 -3
- package/src/AdaptableOptions/ExportOptions.d.ts +11 -20
- package/src/AdaptableOptions/FilterOptions.d.ts +2 -2
- package/src/AdaptableOptions/PredicateOptions.d.ts +4 -4
- package/src/AdaptableOptions/UserInterfaceOptions.d.ts +7 -0
- package/src/Api/ColumnScopeApi.d.ts +2 -2
- package/src/Api/ExportApi.d.ts +1 -6
- package/src/Api/Fdc3Api.d.ts +5 -3
- package/src/Api/Implementation/AdaptableApiImpl.js +1 -0
- package/src/Api/Implementation/ColumnScopeApiImpl.d.ts +1 -1
- package/src/Api/Implementation/ColumnScopeApiImpl.js +1 -1
- package/src/Api/Implementation/ExportApiImpl.d.ts +1 -2
- package/src/Api/Implementation/ExportApiImpl.js +17 -10
- package/src/Api/Implementation/Fdc3ApiImpl.d.ts +3 -3
- package/src/Api/Implementation/Fdc3ApiImpl.js +4 -4
- package/src/Api/Implementation/LayoutHelpers.js +8 -27
- package/src/Api/Implementation/ScheduleApiImpl.js +1 -1
- package/src/Api/Implementation/StyledColumnApiImpl.js +1 -1
- package/src/Api/Implementation/ThemeApiImpl.js +3 -1
- package/src/Api/Internal/ActionColumnInternalApi.js +16 -19
- package/src/Api/Internal/AdaptableInternalApi.js +1 -1
- package/src/Api/Internal/EventInternalApi.js +6 -1
- package/src/Api/Internal/ExportInternalApi.d.ts +10 -6
- package/src/Api/Internal/ExportInternalApi.js +105 -136
- package/src/Api/Internal/RowFormInternalApi.js +1 -1
- package/src/Api/ThemeApi.d.ts +2 -0
- package/src/PredefinedConfig/AlertState.d.ts +1 -1
- package/src/PredefinedConfig/Common/AdaptableColumn.d.ts +5 -5
- package/src/PredefinedConfig/Common/AdaptableColumnContext.d.ts +1 -1
- package/src/PredefinedConfig/Common/AdaptablePredicate.js +0 -16
- package/src/PredefinedConfig/Common/RowSummary.d.ts +1 -1
- package/src/PredefinedConfig/Common/RowSummary.js +2 -2
- package/src/PredefinedConfig/ExportState.d.ts +10 -17
- package/src/PredefinedConfig/FlashingCellState.d.ts +1 -1
- package/src/PredefinedConfig/LayoutState.d.ts +20 -16
- package/src/PredefinedConfig/StyledColumnState.d.ts +1 -1
- package/src/Redux/Store/AdaptableStore.js +1 -1
- package/src/Strategy/StyledColumnModule.js +6 -6
- package/src/Utilities/Helpers/AdaptableHelper.d.ts +2 -0
- package/src/Utilities/Helpers/AdaptableHelper.js +10 -0
- package/src/Utilities/ObjectFactory.js +1 -0
- package/src/Utilities/Services/Fdc3Service.d.ts +2 -2
- package/src/Utilities/Services/Fdc3Service.js +7 -2
- package/src/Utilities/Services/RowSummaryService.js +2 -2
- package/src/Utilities/Services/ThemeService.d.ts +1 -1
- package/src/Utilities/Services/ThemeService.js +5 -5
- package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ConfigurationWizard.js +41 -0
- package/src/View/Components/ColumnFilter/utils.js +2 -2
- package/src/View/Components/FilterForm/ListBoxFilterForm.js +1 -1
- package/src/View/DataChangeHistory/DataChangeHistoryPopup.js +4 -1
- package/src/View/GridInfo/GridInfoPopup/GridInfoPopup.js +7 -2
- package/src/View/Layout/Wizard/LayoutWizard.js +2 -2
- package/src/View/Layout/Wizard/sections/RowSummarySection.js +2 -2
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsReport.d.ts +2 -0
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsReport.js +18 -2
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsSummary.js +4 -0
- package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsWizard.js +2 -1
- package/src/View/StyledColumn/Wizard/StyledColumnSparklineSettingsSection.d.ts +3 -4
- package/src/View/StyledColumn/Wizard/StyledColumnSparklineSettingsSection.js +348 -191
- package/src/View/StyledColumn/Wizard/StyledColumnWizard.js +2 -2
- package/src/View/StyledColumn/Wizard/StyledColumnWizardColumnSection.js +1 -1
- package/src/View/StyledColumn/Wizard/StyledColumnWizardTypeSection.js +4 -4
- package/src/agGrid/AdaptableAgGrid.d.ts +3 -8
- package/src/agGrid/AdaptableAgGrid.js +41 -118
- package/src/agGrid/AgGridAdapter.d.ts +1 -1
- package/src/agGrid/AgGridAdapter.js +7 -8
- package/src/agGrid/AgGridColumnAdapter.js +6 -11
- package/src/agGrid/AgGridExportAdapter.d.ts +24 -1
- package/src/agGrid/AgGridExportAdapter.js +24 -25
- package/src/agGrid/AgGridThemeAdapter.d.ts +19 -0
- package/src/agGrid/AgGridThemeAdapter.js +122 -0
- package/src/agGrid/cellRenderers/BadgeRenderer.js +2 -1
- package/src/components/ColorPicker/ColorPicker.js +2 -2
- package/src/components/OverlayTrigger/useAgGridClassName.js +1 -1
- package/src/components/Select/Select.d.ts +1 -0
- package/src/components/Select/Select.js +29 -6
- package/src/env.js +2 -2
- package/src/metamodel/adaptable.metamodel.d.ts +26 -20
- package/src/metamodel/adaptable.metamodel.js +1 -1
- package/src/migration/VersionUpgrade20.d.ts +1 -0
- package/src/migration/VersionUpgrade20.js +103 -3
- package/src/types.d.ts +3 -3
- package/tsconfig.esm.tsbuildinfo +1 -1
|
@@ -2,8 +2,8 @@ import { VersionUpgrade } from './VersionUpgrade';
|
|
|
2
2
|
import { ALL_ADAPTABLE_DATA_TYPES } from '../agGrid/agGridDataTypeDefinitions';
|
|
3
3
|
function transition_pre_20(layout) {
|
|
4
4
|
const l = layout;
|
|
5
|
-
if (l.
|
|
6
|
-
const oldAggs = l.
|
|
5
|
+
if (l.AggregationColumns && !Array.isArray(l.AggregationColumns)) {
|
|
6
|
+
const oldAggs = l.AggregationColumns || {};
|
|
7
7
|
const newAggs = Object.entries(oldAggs).map(([colId, aggFunc]) => ({
|
|
8
8
|
ColumnId: colId,
|
|
9
9
|
AggFunc: aggFunc,
|
|
@@ -28,10 +28,41 @@ function transition_pre_20(layout) {
|
|
|
28
28
|
}
|
|
29
29
|
if (l.EnablePivot) {
|
|
30
30
|
layout.PivotColumns = l.PivotColumns || [];
|
|
31
|
-
if (l.
|
|
31
|
+
if (l.AggregationColumns) {
|
|
32
32
|
layout.PivotAggregationColumns = layout.TableAggregationColumns;
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
|
+
if (l.ColumnFilters) {
|
|
36
|
+
layout.ColumnFilters = l.ColumnFilters.map((columnFilter) => {
|
|
37
|
+
const filter = {
|
|
38
|
+
...columnFilter,
|
|
39
|
+
};
|
|
40
|
+
// version 19 had a single predicate
|
|
41
|
+
// while version 20 has an array of predicates
|
|
42
|
+
// @ts-ignore
|
|
43
|
+
if (filter.Predicate) {
|
|
44
|
+
// @ts-ignore
|
|
45
|
+
delete filter.Predicate;
|
|
46
|
+
// @ts-ignore
|
|
47
|
+
filter.Predicates = [filter.Predicate];
|
|
48
|
+
}
|
|
49
|
+
filter.Predicates = filter.Predicates.map((p) => {
|
|
50
|
+
// the following predicate ids were renamed:
|
|
51
|
+
// Values -> In
|
|
52
|
+
if (p.PredicateId === 'Values') {
|
|
53
|
+
p = { ...p };
|
|
54
|
+
p.PredicateId = 'In';
|
|
55
|
+
}
|
|
56
|
+
// ExcludeValues -> NotIn
|
|
57
|
+
if (p.PredicateId === 'ExcludeValues') {
|
|
58
|
+
p = { ...p };
|
|
59
|
+
p.PredicateId = 'NotIn';
|
|
60
|
+
}
|
|
61
|
+
return p;
|
|
62
|
+
});
|
|
63
|
+
return filter;
|
|
64
|
+
});
|
|
65
|
+
}
|
|
35
66
|
return layout;
|
|
36
67
|
}
|
|
37
68
|
function hasUpToDateDataType(dataType) {
|
|
@@ -77,6 +108,7 @@ export class VersionUpgrade20 extends VersionUpgrade {
|
|
|
77
108
|
migrateState(state) {
|
|
78
109
|
this.migrateLayoutState(state);
|
|
79
110
|
this.migrateColTypeToDataType(state);
|
|
111
|
+
this.migrateSparklineState(state);
|
|
80
112
|
return state;
|
|
81
113
|
}
|
|
82
114
|
migrateLayoutState(state) {
|
|
@@ -127,4 +159,72 @@ export class VersionUpgrade20 extends VersionUpgrade {
|
|
|
127
159
|
});
|
|
128
160
|
}
|
|
129
161
|
}
|
|
162
|
+
migrateSparklineState(state) {
|
|
163
|
+
this.logger.info(`Migration of Sparkline State`);
|
|
164
|
+
const sparklineState = state.StyledColumn;
|
|
165
|
+
if (sparklineState && sparklineState.StyledColumns) {
|
|
166
|
+
sparklineState.StyledColumns.forEach((styledColumn) => {
|
|
167
|
+
// @ts-ignore renamed 'SparkLineStyle' to 'SparklineStyle'
|
|
168
|
+
if (styledColumn.SparkLineStyle == undefined) {
|
|
169
|
+
return;
|
|
170
|
+
}
|
|
171
|
+
// @ts-ignore renamed 'SparkLineStyle' to 'SparklineStyle'
|
|
172
|
+
// @ts-ignore
|
|
173
|
+
styledColumn.SparklineStyle = styledColumn.SparkLineStyle;
|
|
174
|
+
// @ts-ignore
|
|
175
|
+
delete styledColumn.SparkLineStyle;
|
|
176
|
+
// @ts-ignore the previous type was "column"
|
|
177
|
+
if (styledColumn.SparklineStyle?.options?.type === 'column') {
|
|
178
|
+
// @ts-ignore the previous type was "column"
|
|
179
|
+
styledColumn.SparklineStyle.options.type = 'bar';
|
|
180
|
+
styledColumn.SparklineStyle.options.direction = 'vertical';
|
|
181
|
+
}
|
|
182
|
+
if (styledColumn.SparklineStyle?.options?.type === 'bar') {
|
|
183
|
+
styledColumn.SparklineStyle.options.direction = 'horizontal';
|
|
184
|
+
}
|
|
185
|
+
if (styledColumn.SparklineStyle?.options?.line) {
|
|
186
|
+
const previousLineOpts = (styledColumn.SparklineStyle?.options).line;
|
|
187
|
+
styledColumn.SparklineStyle.options.stroke = previousLineOpts.stroke;
|
|
188
|
+
styledColumn.SparklineStyle.options.strokeWidth = previousLineOpts.strokeWidth;
|
|
189
|
+
delete styledColumn.SparklineStyle.options.line;
|
|
190
|
+
}
|
|
191
|
+
if (styledColumn.SparklineStyle?.options?.axis &&
|
|
192
|
+
styledColumn.SparklineStyle?.options?.axis?.type == undefined) {
|
|
193
|
+
styledColumn.SparklineStyle.options.axis.type = 'category';
|
|
194
|
+
}
|
|
195
|
+
if (styledColumn.SparklineStyle?.options?.highlightStyle) {
|
|
196
|
+
const obsoleteKeys = ['fill', 'stroke', 'strokeWidth'];
|
|
197
|
+
obsoleteKeys.forEach((obsoleteKey) => {
|
|
198
|
+
if (
|
|
199
|
+
// @ts-ignore
|
|
200
|
+
styledColumn.SparklineStyle?.options?.highlightStyle?.[obsoleteKey] != undefined) {
|
|
201
|
+
const itemHighlightStyle = styledColumn.SparklineStyle.options.highlightStyle.item ?? {};
|
|
202
|
+
// @ts-ignore
|
|
203
|
+
itemHighlightStyle[obsoleteKey] = styledColumn.SparklineStyle?.options
|
|
204
|
+
?.highlightStyle?.[obsoleteKey];
|
|
205
|
+
// @ts-ignore
|
|
206
|
+
delete styledColumn.SparklineStyle.options.highlightStyle[obsoleteKey];
|
|
207
|
+
}
|
|
208
|
+
});
|
|
209
|
+
}
|
|
210
|
+
if ((styledColumn.SparklineStyle?.options).paddingInner != undefined) {
|
|
211
|
+
const axisOpts = (styledColumn.SparklineStyle.options.axis ?? {
|
|
212
|
+
type: 'category',
|
|
213
|
+
});
|
|
214
|
+
axisOpts.paddingInner = (styledColumn.SparklineStyle?.options).paddingInner;
|
|
215
|
+
delete (styledColumn.SparklineStyle?.options).paddingInner;
|
|
216
|
+
}
|
|
217
|
+
if ((styledColumn.SparklineStyle?.options).paddingOuter != undefined) {
|
|
218
|
+
const axisOpts = (styledColumn.SparklineStyle.options.axis ?? {
|
|
219
|
+
type: 'category',
|
|
220
|
+
});
|
|
221
|
+
axisOpts.paddingOuter = (styledColumn.SparklineStyle?.options).paddingOuter;
|
|
222
|
+
delete (styledColumn.SparklineStyle?.options).paddingOuter;
|
|
223
|
+
}
|
|
224
|
+
if ((styledColumn.SparklineStyle?.options).marker != undefined) {
|
|
225
|
+
(styledColumn.SparklineStyle?.options).marker.enabled = true;
|
|
226
|
+
}
|
|
227
|
+
});
|
|
228
|
+
}
|
|
229
|
+
}
|
|
130
230
|
}
|
package/src/types.d.ts
CHANGED
|
@@ -20,7 +20,7 @@ export type { SetPrimaryKeyValueContext, RowFormOptions, RowFormContext, CreateR
|
|
|
20
20
|
export type { AdaptableNumberCellEditorParams } from './agGrid/editors/AdaptableNumberEditor';
|
|
21
21
|
export type { AdaptableDateEditorParams } from './agGrid/editors/AdaptableDateEditor';
|
|
22
22
|
export type { AdaptablePercentageCellEditorParams } from './agGrid/editors/AdaptablePercentageEditor';
|
|
23
|
-
export type { ExportOptions, SystemExportDestination, CustomDestination, ExternalReport, PreProcessExportContext, DataFormatType, ExportFormContext, ReportContext,
|
|
23
|
+
export type { ExportOptions, SystemExportDestination, CustomDestination, ExternalReport, PreProcessExportContext, DataFormatType, ExportFormContext, ReportContext, ReportFileNameContext, DataFormatDataType, ExportDestinationType, GetDetailRowsContext, BaseExportContext, ExportResultData, } from './AdaptableOptions/ExportOptions';
|
|
24
24
|
export type { DataImportValidationError, DataImportOptions, DataImportFileHandler, HandleImportedDataContext, DataImportValidateContext, GetPrimaryKeyValueContext, PreprocessRowDataContext, HandleImportedDataResolution, } from './AdaptableOptions/DataImportOptions';
|
|
25
25
|
export type { DataSetOptions, DataSet, DataSetFormContext, } from './AdaptableOptions/DataSetOptions';
|
|
26
26
|
export type { CellSummaryOptions } from './AdaptableOptions/CellSummaryOptions';
|
|
@@ -150,7 +150,7 @@ export type { CellSummmaryInfo, CustomCellSummaryOperation, CustomCellSummaryOpe
|
|
|
150
150
|
export type { FlashingCellDefinition, FlashingCellState, SystemFlashingCellPredicateId, SystemFlashingCellPredicateIds, } from './PredefinedConfig/FlashingCellState';
|
|
151
151
|
export type { AdaptableAlert, AdaptableAlertType, AdaptableGenericAlert, AdaptableCellChangedAlert, AdaptableRowChangedAlert, AdaptableAlertBase, } from './PredefinedConfig/Common/AdaptableAlert';
|
|
152
152
|
export type { AdaptableFlashingCell } from './PredefinedConfig/Common/AdaptableFlashingCell';
|
|
153
|
-
export type { AdaptableColumn, AdaptableColumnBase,
|
|
153
|
+
export type { AdaptableColumn, AdaptableColumnBase, AdaptableSpecialColumnType, AdaptableColumnDataType, AdaptableColumnGroup, } from './PredefinedConfig/Common/AdaptableColumn';
|
|
154
154
|
export type { AdaptableField } from './PredefinedConfig/Common/AdaptableField';
|
|
155
155
|
export type { AdaptableComparerFunction } from './PredefinedConfig/Common/AdaptableComparerFunction';
|
|
156
156
|
export type { SystemStatusMessageInfo } from './PredefinedConfig/Common/SystemStatusMessageInfo';
|
|
@@ -185,7 +185,7 @@ export type { AdaptableModule, AdaptableToolPanel, AdaptableQLModule, AdaptableS
|
|
|
185
185
|
export type { ChartDefinition, ChartingState, ChartingAggFunc, } from './PredefinedConfig/ChartingState';
|
|
186
186
|
export type { CustomSort, CustomSortState } from './PredefinedConfig/CustomSortState';
|
|
187
187
|
export type { DashboardState, DashboardTab, AdaptableCoordinate, } from './PredefinedConfig/DashboardState';
|
|
188
|
-
export type { ExportState, Report, ReportData, ReportSchedule, SystemReportName, SystemReportNames, SystemReportFormat, ReportRowScope, ReportColumnScope, ReportNameType, ReportFormatType, } from './PredefinedConfig/ExportState';
|
|
188
|
+
export type { ExportState, Report, ReportData, ReportColumn, ReportSchedule, SystemReportName, SystemReportNames, SystemReportFormat, ReportRowScope, ReportColumnScope, ReportNameType, ReportFormatType, } from './PredefinedConfig/ExportState';
|
|
189
189
|
export type { ColumnFilter, ColumnFilterPredicate, SystemFilterPredicateIds, SystemFilterPredicateId, } from './PredefinedConfig/Common/ColumnFilter';
|
|
190
190
|
export type { GridFilter } from './PredefinedConfig/Common/GridFilter';
|
|
191
191
|
export type { FormatColumn, FormatColumnState, FormatColumnRule, FormatColumnPredicate, SystemFormatColumnPredicateId, SystemFormatColumnPredicateIds, } from './PredefinedConfig/FormatColumnState';
|