@adaptabletools/adaptable-cjs 22.0.0-canary.4 → 22.0.0-canary.5

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.
Files changed (77) hide show
  1. package/index.css +46 -26
  2. package/index.css.map +1 -1
  3. package/package.json +1 -1
  4. package/src/AdaptableState/Common/AdaptableStyle.d.ts +1 -1
  5. package/src/AdaptableState/LayoutState.d.ts +1 -1
  6. package/src/Api/Implementation/LayoutHelpers.js +4 -4
  7. package/src/View/Components/StyleComponent.d.ts +1 -0
  8. package/src/View/Components/StyleComponent.js +84 -33
  9. package/src/View/GridFilter/GridFilterExpressionEditor.js +6 -1
  10. package/src/View/GridFilter/GridFilterViewPanel.js +33 -70
  11. package/src/View/Layout/Wizard/sections/PivotColumnsSection.js +2 -2
  12. package/src/components/ColorPicker/ColorPicker.js +5 -4
  13. package/src/components/ExpressionEditor/ExpressionFunctionDocumentation.js +1 -1
  14. package/src/env.js +2 -2
  15. package/src/layout-manager/src/LayoutManagerModel.d.ts +1 -1
  16. package/src/layout-manager/src/index.js +5 -5
  17. package/src/layout-manager/src/normalizeLayoutModel.js +2 -2
  18. package/src/metamodel/adaptable.metamodel.js +1 -1
  19. package/tsconfig.cjs.tsbuildinfo +1 -1
  20. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.d.ts +0 -1
  21. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.js +0 -633
  22. package/src/View/Alert/AlertEntityRow.d.ts +0 -11
  23. package/src/View/Alert/AlertEntityRow.js +0 -33
  24. package/src/View/CalculatedColumn/CalculatedColumnSummary.d.ts +0 -21
  25. package/src/View/CalculatedColumn/CalculatedColumnSummary.js +0 -63
  26. package/src/View/Components/Buttons/ButtonFunction.d.ts +0 -7
  27. package/src/View/Components/Buttons/ButtonFunction.js +0 -13
  28. package/src/View/Components/Buttons/ButtonGeneral.d.ts +0 -5
  29. package/src/View/Components/Buttons/ButtonGeneral.js +0 -12
  30. package/src/View/Components/Buttons/ButtonPreviewDelete.d.ts +0 -4
  31. package/src/View/Components/Buttons/ButtonPreviewDelete.js +0 -8
  32. package/src/View/Components/Buttons/ButtonShow.d.ts +0 -5
  33. package/src/View/Components/Buttons/ButtonShow.js +0 -12
  34. package/src/View/Components/Buttons/ButtonShowChart.d.ts +0 -5
  35. package/src/View/Components/Buttons/ButtonShowChart.js +0 -12
  36. package/src/View/Components/Buttons/ButtonUndo.d.ts +0 -5
  37. package/src/View/Components/Buttons/ButtonUndo.js +0 -12
  38. package/src/View/Components/ExpressionWizard.d.ts +0 -24
  39. package/src/View/Components/ExpressionWizard.js +0 -82
  40. package/src/View/Components/FilterForm/Waiting.d.ts +0 -10
  41. package/src/View/Components/FilterForm/Waiting.js +0 -19
  42. package/src/View/Components/Panels/PanelFooter.d.ts +0 -10
  43. package/src/View/Components/Panels/PanelFooter.js +0 -14
  44. package/src/View/Components/Panels/PanelWithTwoButtons.d.ts +0 -12
  45. package/src/View/Components/Panels/PanelWithTwoButtons.js +0 -20
  46. package/src/View/Components/Panels/ToolPanelSettingsPanel.d.ts +0 -8
  47. package/src/View/Components/Panels/ToolPanelSettingsPanel.js +0 -31
  48. package/src/View/Components/Selectors/ColumnSelectorOld.d.ts +0 -18
  49. package/src/View/Components/Selectors/ColumnSelectorOld.js +0 -50
  50. package/src/View/Components/SharedProps/WizardScopeState.d.ts +0 -4
  51. package/src/View/Components/SharedProps/WizardScopeState.js +0 -2
  52. package/src/View/Components/WizardSummaryRow.d.ts +0 -9
  53. package/src/View/Components/WizardSummaryRow.js +0 -16
  54. package/src/View/CustomSort/CustomSortSummary.d.ts +0 -23
  55. package/src/View/CustomSort/CustomSortSummary.js +0 -110
  56. package/src/View/DataImport/DataImportWizard/sections/ImportSection.d.ts +0 -9
  57. package/src/View/DataImport/DataImportWizard/sections/ImportSection.js +0 -24
  58. package/src/View/Export/Wizard/ReportColumnTypeWizard.d.ts +0 -19
  59. package/src/View/Export/Wizard/ReportColumnTypeWizard.js +0 -73
  60. package/src/View/Export/Wizard/ReportRowTypeWizard.d.ts +0 -19
  61. package/src/View/Export/Wizard/ReportRowTypeWizard.js +0 -73
  62. package/src/View/Export/Wizard/ReportSettingsWizard.d.ts +0 -21
  63. package/src/View/Export/Wizard/ReportSettingsWizard.js +0 -61
  64. package/src/View/Export/Wizard/ReportSummaryWizard.d.ts +0 -15
  65. package/src/View/Export/Wizard/ReportSummaryWizard.js +0 -40
  66. package/src/View/Filter/FilterSummary.d.ts +0 -18
  67. package/src/View/Filter/FilterSummary.js +0 -53
  68. package/src/View/FormatColumn/FormatColumnSummary.d.ts +0 -22
  69. package/src/View/FormatColumn/FormatColumnSummary.js +0 -95
  70. package/src/View/FreeTextColumn/FreeTextColumnSummary.d.ts +0 -22
  71. package/src/View/FreeTextColumn/FreeTextColumnSummary.js +0 -93
  72. package/src/View/GridInfo/GridInfoPopup/AdaptableOptionsComponent.d.ts +0 -7
  73. package/src/View/GridInfo/GridInfoPopup/AdaptableOptionsComponent.js +0 -99
  74. package/src/View/PlusMinus/PlusMinusSummary.d.ts +0 -22
  75. package/src/View/PlusMinus/PlusMinusSummary.js +0 -100
  76. package/src/View/Wizard/WizardLegend.d.ts +0 -12
  77. package/src/View/Wizard/WizardLegend.js +0 -28
@@ -1,110 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.CustomSortSummary = exports.CustomSortSummaryComponent = void 0;
4
- const tslib_1 = require("tslib");
5
- const React = tslib_1.__importStar(require("react"));
6
- const EditableConfigEntityState_1 = require("../Components/SharedProps/EditableConfigEntityState");
7
- const react_redux_1 = require("react-redux");
8
- const Helper_1 = require("../../Utilities/Helpers/Helper");
9
- const CustomSortRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/CustomSortRedux"));
10
- const ObjectFactory_1 = require("../../Utilities/ObjectFactory");
11
- const ModuleConstants = tslib_1.__importStar(require("../../Utilities/Constants/ModuleConstants"));
12
- const ModuleHeader_1 = require("../Components/ModuleSummary/ModuleHeader");
13
- const ModuleDetail_1 = require("../Components/ModuleSummary/ModuleDetail");
14
- const ModuleProfile_1 = require("../Components/ModuleProfile");
15
- const TeamSharingRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/TeamSharingRedux"));
16
- const UIHelper_1 = require("../UIHelper");
17
- const StringExtensions_1 = require("../../Utilities/Extensions/StringExtensions");
18
- const ArrayExtensions_1 = require("../../Utilities/Extensions/ArrayExtensions");
19
- const CustomSortWizard_1 = require("./Wizard/CustomSortWizard");
20
- class CustomSortSummaryComponent extends React.Component {
21
- constructor(props) {
22
- super(props);
23
- this.state = UIHelper_1.UIHelper.getEmptyConfigState();
24
- }
25
- render() {
26
- const customSort = this.props.CustomSorts.find((c) => c.ColumnId == this.props.summarisedColumn.columnId);
27
- const columnSortComparer = this.props.api.customSortApi.internalApi.getCustomSortComparer(this.props.summarisedColumn.columnId);
28
- let noCustomSort = customSort == null && columnSortComparer == null;
29
- let customSortRow;
30
- if (!this.props.summarisedColumn.sortable) {
31
- customSortRow = (React.createElement(ModuleHeader_1.ModuleHeader, { key: this.props.moduleInfo.FriendlyName, moduleInfo: this.props.moduleInfo, moduleSummary: 'Column is not sortable', newButtonDisabled: true, onNew: () => this.onNew(), newButtonTooltip: this.props.moduleInfo.FriendlyName, accessLevel: this.props.accessLevel }));
32
- }
33
- else if (noCustomSort) {
34
- // title row
35
- customSortRow = (React.createElement(ModuleHeader_1.ModuleHeader, { key: this.props.moduleInfo.FriendlyName, moduleInfo: this.props.moduleInfo, moduleSummary: 'No Custom Sort Set', onNew: () => this.onNew(), accessLevel: this.props.accessLevel, newButtonTooltip: this.props.moduleInfo.FriendlyName }));
36
- }
37
- else if (columnSortComparer != null) {
38
- customSortRow = (React.createElement(ModuleHeader_1.ModuleHeader, { key: this.props.moduleInfo.FriendlyName, moduleInfo: this.props.moduleInfo, moduleSummary: 'Using a Custom Sort Comparer Function', onNew: () => this.onNew(), accessLevel: this.props.accessLevel, newButtonTooltip: this.props.moduleInfo.FriendlyName }));
39
- }
40
- else {
41
- customSortRow = (React.createElement(ModuleDetail_1.ModuleDetail, { key: this.props.moduleInfo.FriendlyName, item1: React.createElement(ModuleProfile_1.ModuleProfile, { moduleInfo: this.props.moduleInfo }), item2: this.getCustomSortedValues(customSort), configEnity: customSort, moduleInfo: this.props.moduleInfo, onEdit: () => this.onEdit(customSort), showEdit: customSort != undefined, onShare: (config) => this.props.onShare(customSort, config), showShare: this.props.teamSharingActivated, onDelete: CustomSortRedux.CustomSortDelete(customSort), showBold: true, accessLevel: this.props.accessLevel }));
42
- }
43
- return (React.createElement(React.Fragment, null,
44
- customSortRow,
45
- this.state.editedAdaptableObject && (React.createElement(CustomSortWizard_1.CustomSortWizard, { isNew: this.state.wizardStatus === EditableConfigEntityState_1.WizardStatus.New, moduleInfo: this.props.moduleInfo, data: this.state.editedAdaptableObject, configEntities: this.props.CustomSorts, onCloseWizard: () => this.onCloseWizard(), onFinishWizard: this.onFinishWizard }))));
46
- }
47
- onNew() {
48
- let configEntity = ObjectFactory_1.ObjectFactory.CreateEmptyCustomSort();
49
- configEntity.ColumnId = this.props.summarisedColumn.columnId;
50
- this.setState({
51
- editedAdaptableObject: configEntity,
52
- wizardStartIndex: 1,
53
- wizardStatus: EditableConfigEntityState_1.WizardStatus.New,
54
- });
55
- }
56
- onEdit(customSort) {
57
- this.setState({
58
- editedAdaptableObject: Helper_1.Helper.cloneObject(customSort),
59
- wizardStartIndex: 1,
60
- wizardStatus: EditableConfigEntityState_1.WizardStatus.Edit,
61
- });
62
- }
63
- onCloseWizard() {
64
- this.setState({
65
- editedAdaptableObject: null,
66
- wizardStartIndex: 0,
67
- wizardStatus: EditableConfigEntityState_1.WizardStatus.None,
68
- });
69
- }
70
- onFinishWizard = (customSort) => {
71
- if (this.props.CustomSorts.find((x) => x.ColumnId == customSort.ColumnId)) {
72
- this.props.onEditCustomSort(customSort);
73
- }
74
- else {
75
- this.props.onAddCustomSort(customSort);
76
- }
77
- this.setState({
78
- editedAdaptableObject: null,
79
- wizardStartIndex: 0,
80
- wizardStatus: EditableConfigEntityState_1.WizardStatus.None,
81
- });
82
- };
83
- canFinishWizard() {
84
- let customSort = this.state.editedAdaptableObject;
85
- return (StringExtensions_1.StringExtensions.IsNotNullOrEmpty(customSort.ColumnId) &&
86
- ArrayExtensions_1.ArrayExtensions.IsNotNullOrEmpty(customSort.SortedValues));
87
- }
88
- getCustomSortedValues(customSort) {
89
- if (ArrayExtensions_1.ArrayExtensions.IsNotNullOrEmpty(customSort.SortedValues)) {
90
- return customSort.SortedValues.join(', ');
91
- }
92
- else {
93
- return '[Has bespoke Custom Sort implementing using bespoke function]';
94
- }
95
- }
96
- }
97
- exports.CustomSortSummaryComponent = CustomSortSummaryComponent;
98
- function mapStateToProps(state, ownProps) {
99
- return {
100
- CustomSorts: state.CustomSort.CustomSorts,
101
- };
102
- }
103
- function mapDispatchToProps(dispatch) {
104
- return {
105
- onAddCustomSort: (customSort) => dispatch(CustomSortRedux.CustomSortAdd(customSort)),
106
- onEditCustomSort: (customSort) => dispatch(CustomSortRedux.CustomSortEdit(customSort)),
107
- onShare: (entity, config) => dispatch(TeamSharingRedux.TeamSharingShare(entity, ModuleConstants.CustomSortModuleId, config)),
108
- };
109
- }
110
- exports.CustomSortSummary = (0, react_redux_1.connect)(mapStateToProps, mapDispatchToProps)(CustomSortSummaryComponent);
@@ -1,9 +0,0 @@
1
- import * as React from 'react';
2
- import { ValidationErrorsMap } from '../DataImportWizard';
3
- interface ImportSectionProps {
4
- data?: Record<string, unknown>[];
5
- onDataChange?: (data: Record<string, unknown>[]) => void;
6
- errors: ValidationErrorsMap | null;
7
- }
8
- export declare const ImportSection: React.FunctionComponent<ImportSectionProps>;
9
- export {};
@@ -1,24 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ImportSection = void 0;
4
- const tslib_1 = require("tslib");
5
- const React = tslib_1.__importStar(require("react"));
6
- const FormLayout_1 = tslib_1.__importStar(require("../../../../components/FormLayout"));
7
- const check_box_1 = tslib_1.__importDefault(require("../../../../components/icons/check-box"));
8
- const Tabs_1 = require("../../../../components/Tabs");
9
- const DataPreview_1 = require("./DataPreview");
10
- const Flex_1 = require("../../../../components/Flex");
11
- const ImportSection = (props) => {
12
- return (React.createElement(Flex_1.Flex, { flexDirection: "column", className: "twa:p-2 twa:h-full" },
13
- React.createElement(Tabs_1.Tabs, { className: "twa:mb-2" },
14
- React.createElement(Tabs_1.Tabs.Tab, null, "Import Options"),
15
- React.createElement(Tabs_1.Tabs.Content, null,
16
- React.createElement(FormLayout_1.default, null,
17
- React.createElement(FormLayout_1.FormRow, { label: "Exclude Invalid Rows" },
18
- React.createElement(check_box_1.default, null))))),
19
- React.createElement(Tabs_1.Tabs, { className: "twa:flex-1" },
20
- React.createElement(Tabs_1.Tabs.Tab, null, "Preview"),
21
- React.createElement(Tabs_1.Tabs.Content, null,
22
- React.createElement(DataPreview_1.DataPreview, { onDataChange: props.onDataChange, data: props.data, errors: props.errors, editable: false })))));
23
- };
24
- exports.ImportSection = ImportSection;
@@ -1,19 +0,0 @@
1
- import { Report, ReportColumnScope } from '../../../AdaptableState/ExportState';
2
- import * as React from 'react';
3
- import { AdaptableWizardStep, AdaptableWizardStepProps } from '../../Wizard/Interface/IAdaptableWizard';
4
- export interface ReportColumnTypeWizardProps extends AdaptableWizardStepProps<Report> {
5
- }
6
- export interface ReportColumnsWizardState {
7
- ReportColumnScope: ReportColumnScope;
8
- }
9
- export declare class ReportColumnTypeWizard extends React.Component<ReportColumnTypeWizardProps, ReportColumnsWizardState> implements AdaptableWizardStep {
10
- constructor(props: ReportColumnTypeWizardProps);
11
- render(): React.JSX.Element;
12
- private onScopeSelectChanged;
13
- canNext(): boolean;
14
- canBack(): boolean;
15
- next(): void;
16
- back(): void;
17
- getIndexStepIncrement(): 1 | 2;
18
- getIndexStepDecrement(): number;
19
- }
@@ -1,73 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ReportColumnTypeWizard = void 0;
4
- const tslib_1 = require("tslib");
5
- const React = tslib_1.__importStar(require("react"));
6
- const WizardPanel_1 = tslib_1.__importDefault(require("../../../components/WizardPanel"));
7
- const Radio_1 = tslib_1.__importDefault(require("../../../components/Radio"));
8
- const HelpBlock_1 = tslib_1.__importDefault(require("../../../components/HelpBlock"));
9
- const Flex_1 = require("../../../components/Flex");
10
- class ReportColumnTypeWizard extends React.Component {
11
- constructor(props) {
12
- super(props);
13
- this.state = {
14
- ReportColumnScope: this.props.data.ReportColumnScope,
15
- };
16
- }
17
- render() {
18
- return (React.createElement("div", { "data-name": 'report-select-columns' },
19
- React.createElement(WizardPanel_1.default, null,
20
- React.createElement(Flex_1.Flex, { flexDirection: "column", className: "twa:p-2" },
21
- React.createElement(HelpBlock_1.default, { className: "twa:mb-1" }, "All columns in the datasource will be included in the Report, whether visible or not at time of export"),
22
- React.createElement(Radio_1.default, { value: "All", checked: this.state.ReportColumnScope == 'AllColumns', onChange: (_, e) => this.onScopeSelectChanged(e), className: "twa:mr-3" }, "All Columns"),
23
- ' ',
24
- React.createElement(HelpBlock_1.default, { className: "twa:mb-1" }, "Only columns that are visible at the time the Report is exported will be included"),
25
- React.createElement(Radio_1.default, { value: "Visible", checked: this.state.ReportColumnScope == 'VisibleColumns', onChange: (_, e) => this.onScopeSelectChanged(e), className: "twa:mr-3" }, "Visible Columns Only"),
26
- ' ',
27
- React.createElement(HelpBlock_1.default, { className: "twa:mb-1" }, "Only selected columns (which you will choose in the next step) will be exported - whether visible or not"),
28
- React.createElement(Radio_1.default, { value: "Bespoke", className: "twa:mr-3", checked: this.state.ReportColumnScope == 'ScopeColumns', onChange: (_, e) => this.onScopeSelectChanged(e) }, "Bespoke Columns"),
29
- ' '))));
30
- }
31
- onScopeSelectChanged(event) {
32
- let e = event.target;
33
- if (e.value == 'All') {
34
- this.setState({
35
- ReportColumnScope: 'AllColumns',
36
- SelectedColumnValues: [],
37
- }, () => this.props.updateGoBackState());
38
- }
39
- else if (e.value == 'Visible') {
40
- this.setState({
41
- ReportColumnScope: 'VisibleColumns',
42
- SelectedColumnValues: [],
43
- }, () => this.props.updateGoBackState());
44
- }
45
- else {
46
- this.setState({
47
- ReportColumnScope: 'ScopeColumns',
48
- }, () => this.props.updateGoBackState());
49
- }
50
- }
51
- canNext() {
52
- return (this.state.ReportColumnScope == 'AllColumns' ||
53
- this.state.ReportColumnScope == 'VisibleColumns' ||
54
- this.state.ReportColumnScope == 'ScopeColumns');
55
- }
56
- canBack() {
57
- return true;
58
- }
59
- next() {
60
- this.props.data.ReportColumnScope = this.state.ReportColumnScope;
61
- if (this.state.ReportColumnScope != 'ScopeColumns') {
62
- this.props.data.Scope = undefined;
63
- }
64
- }
65
- back() { }
66
- getIndexStepIncrement() {
67
- return this.state.ReportColumnScope == 'ScopeColumns' ? 1 : 2;
68
- }
69
- getIndexStepDecrement() {
70
- return 1;
71
- }
72
- }
73
- exports.ReportColumnTypeWizard = ReportColumnTypeWizard;
@@ -1,19 +0,0 @@
1
- import { Report, ReportRowScope } from '../../../AdaptableState/ExportState';
2
- import * as React from 'react';
3
- import { AdaptableWizardStep, AdaptableWizardStepProps } from '../../Wizard/Interface/IAdaptableWizard';
4
- export interface ReportRowTypeWizardProps extends AdaptableWizardStepProps<Report> {
5
- }
6
- export interface ReportRowsWizardState {
7
- ReportRowScope: ReportRowScope;
8
- }
9
- export declare class ReportRowTypeWizard extends React.Component<ReportRowTypeWizardProps, ReportRowsWizardState> implements AdaptableWizardStep {
10
- constructor(props: ReportRowTypeWizardProps);
11
- render(): React.JSX.Element;
12
- private onScopeSelectChanged;
13
- canNext(): boolean;
14
- canBack(): boolean;
15
- next(): void;
16
- back(): void;
17
- getIndexStepIncrement(): 1 | 2;
18
- getIndexStepDecrement(): 1 | 2;
19
- }
@@ -1,73 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ReportRowTypeWizard = void 0;
4
- const tslib_1 = require("tslib");
5
- const React = tslib_1.__importStar(require("react"));
6
- const WizardPanel_1 = tslib_1.__importDefault(require("../../../components/WizardPanel"));
7
- const Radio_1 = tslib_1.__importDefault(require("../../../components/Radio"));
8
- const HelpBlock_1 = tslib_1.__importDefault(require("../../../components/HelpBlock"));
9
- const Flex_1 = require("../../../components/Flex");
10
- class ReportRowTypeWizard extends React.Component {
11
- constructor(props) {
12
- super(props);
13
- this.state = {
14
- ReportRowScope: this.props.data.ReportRowScope,
15
- };
16
- }
17
- render() {
18
- return (React.createElement("div", { "data-name": 'report-select-rows' },
19
- React.createElement(WizardPanel_1.default, null,
20
- React.createElement(Flex_1.Flex, { flexDirection: "column", className: "twa:p-2" },
21
- React.createElement(HelpBlock_1.default, { className: "twa:mb-1" }, "All rows in the datasource will be included in the report, whether visible or not at time of export."),
22
- React.createElement(Radio_1.default, { value: "All", checked: this.state.ReportRowScope == 'AllRows', onChange: (_, e) => this.onScopeSelectChanged(e), className: "twa:mr-3" }, "All Rows"),
23
- ' ',
24
- React.createElement(HelpBlock_1.default, { className: "twa:mb-1" }, "Only rows that are visible at the time the Report is exported will be included in the Export"),
25
- React.createElement(Radio_1.default, { value: "Visible", checked: this.state.ReportRowScope == 'VisibleRows', onChange: (_, e) => this.onScopeSelectChanged(e), className: "twa:mr-3" }, "Visible Rows Only"),
26
- ' ',
27
- React.createElement(HelpBlock_1.default, { className: "twa:mb-1" }, "Only the rows which match the Query (built in next step) will be exported - whether visible or not."),
28
- React.createElement(Radio_1.default, { value: "Expression", checked: this.state.ReportRowScope == 'ExpressionRows', onChange: (_, e) => this.onScopeSelectChanged(e), className: "twa:mr-3" }, "By Query - built by you in next step"),
29
- ' '))));
30
- }
31
- onScopeSelectChanged(event) {
32
- let e = event.target;
33
- if (e.value == 'All') {
34
- this.setState({
35
- ReportRowScope: 'AllRows',
36
- SelectedColumnValues: [],
37
- }, () => this.props.updateGoBackState());
38
- }
39
- else if (e.value == 'Visible') {
40
- this.setState({
41
- ReportRowScope: 'VisibleRows',
42
- SelectedColumnValues: [],
43
- }, () => this.props.updateGoBackState());
44
- }
45
- else {
46
- this.setState({
47
- ReportRowScope: 'ExpressionRows',
48
- }, () => this.props.updateGoBackState());
49
- }
50
- }
51
- canNext() {
52
- return (this.state.ReportRowScope == 'AllRows' ||
53
- this.state.ReportRowScope == 'VisibleRows' ||
54
- this.state.ReportRowScope == 'ExpressionRows');
55
- }
56
- canBack() {
57
- return true;
58
- }
59
- next() {
60
- this.props.data.ReportRowScope = this.state.ReportRowScope;
61
- if (this.props.data.Query && this.state.ReportRowScope != 'ExpressionRows') {
62
- this.props.data.Query = undefined;
63
- }
64
- }
65
- back() { }
66
- getIndexStepIncrement() {
67
- return this.state.ReportRowScope == 'ExpressionRows' ? 1 : 2;
68
- }
69
- getIndexStepDecrement() {
70
- return this.props.data.ReportColumnScope == 'ScopeColumns' ? 1 : 2;
71
- }
72
- }
73
- exports.ReportRowTypeWizard = ReportRowTypeWizard;
@@ -1,21 +0,0 @@
1
- import { Report } from '../../../AdaptableState/ExportState';
2
- import * as React from 'react';
3
- import { AdaptableWizardStep, AdaptableWizardStepProps } from '../../Wizard/Interface/IAdaptableWizard';
4
- export interface ReportSettingsWizardProps extends AdaptableWizardStepProps<Report> {
5
- Reports: Report[];
6
- }
7
- export interface ReportSettingsWizardState {
8
- ReportName: string;
9
- ErrorMessage: string;
10
- }
11
- export declare class ReportSettingsWizard extends React.Component<ReportSettingsWizardProps, ReportSettingsWizardState> implements AdaptableWizardStep {
12
- constructor(props: ReportSettingsWizardProps);
13
- render(): any;
14
- private onReportNameChanged;
15
- canNext(): boolean;
16
- canBack(): boolean;
17
- next(): void;
18
- back(): void;
19
- getIndexStepIncrement(): number;
20
- getIndexStepDecrement(): 1 | 2;
21
- }
@@ -1,61 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ReportSettingsWizard = void 0;
4
- const tslib_1 = require("tslib");
5
- const React = tslib_1.__importStar(require("react"));
6
- const StringExtensions_1 = require("../../../Utilities/Extensions/StringExtensions");
7
- const WizardPanel_1 = tslib_1.__importDefault(require("../../../components/WizardPanel"));
8
- const Input_1 = tslib_1.__importDefault(require("../../../components/Input"));
9
- const ErrorBox_1 = tslib_1.__importDefault(require("../../../components/ErrorBox"));
10
- const FormLayout_1 = tslib_1.__importStar(require("../../../components/FormLayout"));
11
- const Flex_1 = require("../../../components/Flex");
12
- class ReportSettingsWizard extends React.Component {
13
- constructor(props) {
14
- super(props);
15
- this.state = {
16
- ReportName: this.props.data.Name,
17
- ErrorMessage: null,
18
- };
19
- }
20
- render() {
21
- let validationState = StringExtensions_1.StringExtensions.IsNullOrEmpty(this.state.ErrorMessage)
22
- ? null
23
- : 'error';
24
- return (React.createElement("div", { "data-name": 'report-settings' },
25
- React.createElement(WizardPanel_1.default, null,
26
- React.createElement(FormLayout_1.default, { columns: [1, 2] },
27
- React.createElement(FormLayout_1.FormRow, null,
28
- React.createElement(Flex_1.Box, { className: "twa:mr-2" }, "Enter Report Name:"),
29
- React.createElement(Input_1.default, { className: "twa:w-full", type: "text", placeholder: "Name", value: this.state.ReportName, onChange: (e) => this.onReportNameChanged(e) })),
30
- React.createElement(FormLayout_1.FormRow, null,
31
- React.createElement(React.Fragment, null),
32
- this.state.ErrorMessage ? React.createElement(ErrorBox_1.default, null, this.state.ErrorMessage) : null)))));
33
- }
34
- onReportNameChanged(event) {
35
- let e = event.target;
36
- this.setState({
37
- ReportName: e.value,
38
- ErrorMessage: this.props.Reports.findIndex((x) => x.Name == e.value) > -1
39
- ? 'A Report already exists with that name'
40
- : null,
41
- }, () => this.props.updateGoBackState());
42
- }
43
- canNext() {
44
- return (StringExtensions_1.StringExtensions.IsNotNullOrEmpty(this.state.ReportName) &&
45
- StringExtensions_1.StringExtensions.IsNullOrEmpty(this.state.ErrorMessage));
46
- }
47
- canBack() {
48
- return true;
49
- }
50
- next() {
51
- this.props.data.Name = this.state.ReportName;
52
- }
53
- back() { }
54
- getIndexStepIncrement() {
55
- return 1;
56
- }
57
- getIndexStepDecrement() {
58
- return this.props.data.ReportRowScope == 'ExpressionRows' ? 1 : 2;
59
- }
60
- }
61
- exports.ReportSettingsWizard = ReportSettingsWizard;
@@ -1,15 +0,0 @@
1
- import { Report } from '../../../AdaptableState/ExportState';
2
- import * as React from 'react';
3
- import { AdaptableWizardStep, AdaptableWizardStepProps } from '../../Wizard/Interface/IAdaptableWizard';
4
- export interface ReportSummaryWizardProps extends AdaptableWizardStepProps<Report> {
5
- }
6
- export declare class ReportSummaryWizard extends React.Component<ReportSummaryWizardProps, {}> implements AdaptableWizardStep {
7
- constructor(props: ReportSummaryWizardProps);
8
- render(): any;
9
- canNext(): boolean;
10
- canBack(): boolean;
11
- next(): void;
12
- back(): void;
13
- getIndexStepIncrement(): number;
14
- getIndexStepDecrement(): number;
15
- }
@@ -1,40 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ReportSummaryWizard = void 0;
4
- const tslib_1 = require("tslib");
5
- const React = tslib_1.__importStar(require("react"));
6
- const WizardSummaryPage_1 = require("../../Components/WizardSummaryPage");
7
- class ReportSummaryWizard extends React.Component {
8
- constructor(props) {
9
- super(props);
10
- }
11
- render() {
12
- let keyValuePairs = [
13
- { Key: 'Name', Value: this.props.data.Name },
14
- {
15
- Key: 'Column Scope',
16
- Value: this.props.api.exportApi.internalApi.getReportColumnScopeLongDescription(this.props.data),
17
- },
18
- {
19
- Key: 'Row Scope',
20
- Value: this.props.api.exportApi.internalApi.getReportExpressionDescription(this.props.data, this.props.api.columnApi.getColumns()),
21
- },
22
- ];
23
- return (React.createElement(WizardSummaryPage_1.WizardSummaryPage, { KeyValuePairs: keyValuePairs, header: this.props.moduleInfo.FriendlyName }));
24
- }
25
- canNext() {
26
- return true;
27
- }
28
- canBack() {
29
- return true;
30
- }
31
- next() { }
32
- back() { }
33
- getIndexStepIncrement() {
34
- return 1;
35
- }
36
- getIndexStepDecrement() {
37
- return 1;
38
- }
39
- }
40
- exports.ReportSummaryWizard = ReportSummaryWizard;
@@ -1,18 +0,0 @@
1
- import * as React from 'react';
2
- import { ModuleSummaryProps } from '../Components/SharedProps/ModuleSummaryProps';
3
- import { EditableConfigEntityState } from '../Components/SharedProps/EditableConfigEntityState';
4
- import * as LayoutRedux from '../../Redux/ActionsReducers/LayoutRedux';
5
- import { ColumnFilter } from '../../types';
6
- export interface FilterSummaryProps extends Omit<ModuleSummaryProps<FilterSummaryComponent>, 'onClosePopup' | 'modalContainer'> {
7
- ColumnFilters: ColumnFilter[];
8
- onClearFilter: (columnFilter: ColumnFilter) => LayoutRedux.LayoutColumnFilterClearAction;
9
- }
10
- export declare class FilterSummaryComponent extends React.Component<FilterSummaryProps, EditableConfigEntityState> {
11
- constructor(props: FilterSummaryProps);
12
- render(): any;
13
- getDescription(columnFilter: ColumnFilter): string;
14
- }
15
- export declare let FilterSummary: import("react-redux").ConnectedComponent<typeof FilterSummaryComponent, {
16
- context?: React.Context<import("react-redux").ReactReduxContextValue<any, import("redux").UnknownAction>>;
17
- store?: import("redux").Store;
18
- }>;
@@ -1,53 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FilterSummary = exports.FilterSummaryComponent = void 0;
4
- const tslib_1 = require("tslib");
5
- const React = tslib_1.__importStar(require("react"));
6
- const react_redux_1 = require("react-redux");
7
- const ModuleConstants = tslib_1.__importStar(require("../../Utilities/Constants/ModuleConstants"));
8
- const PopupRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/PopupRedux"));
9
- const TeamSharingRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/TeamSharingRedux"));
10
- const LayoutRedux = tslib_1.__importStar(require("../../Redux/ActionsReducers/LayoutRedux"));
11
- const SummaryRowItem_1 = require("../Components/ModuleSummary/SummaryRowItem");
12
- const ModuleProfile_1 = require("../Components/ModuleProfile");
13
- const ButtonClear_1 = require("../Components/Buttons/ButtonClear");
14
- const UIHelper_1 = require("../UIHelper");
15
- const LayoutRedux_1 = require("../../Redux/ActionsReducers/LayoutRedux");
16
- class FilterSummaryComponent extends React.Component {
17
- constructor(props) {
18
- super(props);
19
- this.state = UIHelper_1.UIHelper.getEmptyConfigState();
20
- }
21
- render() {
22
- let columnFilter = this.props.ColumnFilters.find((c) => c.ColumnId == this.props.summarisedColumn.columnId);
23
- let description = this.getDescription(columnFilter);
24
- let summaryItems = [];
25
- summaryItems.push(React.createElement("b", null, React.createElement(ModuleProfile_1.ModuleProfile, { moduleInfo: this.props.moduleInfo })));
26
- summaryItems.push(description);
27
- summaryItems.push(React.createElement(ButtonClear_1.ButtonClear, { className: "twa:ml-1", onClick: () => this.props.onClearFilter(columnFilter), tooltip: "Clear Filter", disabled: columnFilter == null, accessLevel: this.props.accessLevel }));
28
- return React.createElement(SummaryRowItem_1.SummaryRowItem, { SummaryItems: summaryItems });
29
- }
30
- getDescription(columnFilter) {
31
- if (this.props.summarisedColumn && !this.props.summarisedColumn.filterable) {
32
- return 'Column is not filterable';
33
- }
34
- if (columnFilter == null) {
35
- return 'No Column Filter Active';
36
- }
37
- return this.props.api.filterApi.columnFilterApi.columnFilterToString(columnFilter);
38
- }
39
- }
40
- exports.FilterSummaryComponent = FilterSummaryComponent;
41
- function mapStateToProps(state) {
42
- return {
43
- ColumnFilters: (0, LayoutRedux_1.getColumnFiltersSelector)(state),
44
- };
45
- }
46
- function mapDispatchToProps(dispatch) {
47
- return {
48
- onClearFilter: (columnFilter) => dispatch(LayoutRedux.LayoutColumnFilterClear(columnFilter.ColumnId)),
49
- onClearPopupParams: () => dispatch(PopupRedux.PopupClearParam()),
50
- onShare: (entity, config) => dispatch(TeamSharingRedux.TeamSharingShare(entity, ModuleConstants.ColumnFilterModuleId, config)),
51
- };
52
- }
53
- exports.FilterSummary = (0, react_redux_1.connect)(mapStateToProps, mapDispatchToProps)(FilterSummaryComponent);
@@ -1,22 +0,0 @@
1
- import * as React from 'react';
2
- import { ModuleSummaryProps } from '../Components/SharedProps/ModuleSummaryProps';
3
- import { EditableConfigEntityState } from '../Components/SharedProps/EditableConfigEntityState';
4
- import * as FormatColumnRedux from '../../Redux/ActionsReducers/FormatColumnRedux';
5
- import { FormatColumn } from '../../AdaptableState/FormatColumnState';
6
- export interface FormatColumnSummaryProps extends ModuleSummaryProps<FormatColumnSummaryComponent> {
7
- FormatColumns: FormatColumn[];
8
- onAddFormatColumn: (FormatColumn: FormatColumn) => FormatColumnRedux.FormatColumnAddAction;
9
- onEditFormatColumn: (FormatColumn: FormatColumn) => FormatColumnRedux.FormatColumnEditAction;
10
- }
11
- export declare class FormatColumnSummaryComponent extends React.Component<FormatColumnSummaryProps, EditableConfigEntityState> {
12
- constructor(props: FormatColumnSummaryProps);
13
- render(): any;
14
- onNew(): void;
15
- onEdit(formatColumn: FormatColumn): void;
16
- onCloseWizard(): void;
17
- onFinishWizard: (formatColumn: FormatColumn) => void;
18
- canFinishWizard(): boolean;
19
- }
20
- export declare let FormatColumnSummary: import("react-redux").ConnectedComponent<typeof FormatColumnSummaryComponent, {
21
- [x: string]: any;
22
- }>;