@sis-cc/dotstatsuite-visions 6.6.0 → 6.6.4
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/es/Alert/Alert.js +135 -66
- package/es/Alert/index.js +1 -0
- package/es/ApiQueries/ApiQueries.js +79 -45
- package/es/ApiQueries/Query.js +105 -65
- package/es/ApiQueries/index.js +1 -0
- package/es/AuthDialog/index.js +103 -62
- package/es/Breadcrumbs/Breadcrumbs.js +38 -21
- package/es/Breadcrumbs/index.js +1 -0
- package/es/Button/Button.js +28 -11
- package/es/Button/index.js +1 -0
- package/es/ChartsConfig/Axis.js +76 -72
- package/es/ChartsConfig/ButtonGroup.js +51 -29
- package/es/ChartsConfig/ChartsConfig.js +187 -87
- package/es/ChartsConfig/ContainerTitle.js +36 -15
- package/es/ChartsConfig/Focus.js +48 -37
- package/es/ChartsConfig/Frequency.js +36 -24
- package/es/ChartsConfig/Series.js +43 -28
- package/es/ChartsConfig/Size.js +50 -36
- package/es/ChartsConfig/index.js +1 -0
- package/es/ChartsConfig/styles.js +4 -4
- package/es/ChartsConfig/utils.js +5 -1
- package/es/Chips/Chips.js +154 -99
- package/es/Chips/index.js +1 -0
- package/es/CollapseButtons/CollapseButtons.js +101 -61
- package/es/CollapseButtons/Item.js +70 -45
- package/es/CollapseButtons/Paper.js +21 -7
- package/es/CollapseButtons/index.js +1 -0
- package/es/DataEdit/DataEdit.js +124 -67
- package/es/DataEdit/Input.js +58 -27
- package/es/DataEdit/index.js +1 -0
- package/es/DataFooter/DataFooter.js +115 -68
- package/es/DataFooter/index.js +1 -0
- package/es/DataHeader/DataHeader.js +113 -75
- package/es/DataHeader/Flags.js +21 -8
- package/es/DataHeader/Title.js +15 -2
- package/es/DataHeader/TooltipHeader.js +63 -33
- package/es/DataHeader/index.js +1 -0
- package/es/DataHeader/utils.js +8 -8
- package/es/Dataflow/Dataflow.js +226 -132
- package/es/Dataflow/index.js +1 -0
- package/es/ExpansionPanel/ExpansionPanel.js +79 -42
- package/es/ExpansionPanel/index.js +1 -0
- package/es/ExpansionPanel/styles.js +5 -3
- package/es/Icons/AccessibilityFilled.js +8 -6
- package/es/Icons/AccessibilityOutlined.js +8 -6
- package/es/Icons/AccountFilled.js +8 -6
- package/es/Icons/AccountOutlined.js +8 -6
- package/es/Icons/Api.js +8 -6
- package/es/Icons/Asterisk.js +8 -6
- package/es/Icons/Bar.js +8 -6
- package/es/Icons/CopyContent.js +8 -6
- package/es/Icons/Cross.js +8 -6
- package/es/Icons/HSymbol.js +8 -6
- package/es/Icons/Row.js +8 -6
- package/es/Icons/Scatter.js +8 -6
- package/es/Icons/StackedBar.js +8 -6
- package/es/Icons/StackedRow.js +8 -6
- package/es/Icons/Timeline.js +8 -6
- package/es/Icons/VSymbol.js +8 -6
- package/es/Icons/Warning.js +14 -11
- package/es/Icons/index.js +1 -0
- package/es/Input/Input.js +56 -26
- package/es/Input/index.js +1 -0
- package/es/Input/with-input.js +25 -30
- package/es/InputNumber/InputNumber.js +51 -31
- package/es/InputNumber/index.js +1 -0
- package/es/LabelDivider/LabelDivider.js +18 -7
- package/es/LabelDivider/index.js +1 -0
- package/es/Loading/Loading.js +18 -9
- package/es/Loading/index.js +1 -0
- package/es/Logo/Logo.js +17 -11
- package/es/Logo/index.js +1 -0
- package/es/NoData/NoData.js +25 -17
- package/es/NoData/index.js +1 -0
- package/es/Pagination/Pagination.js +114 -70
- package/es/Pagination/index.js +1 -0
- package/es/PeriodPicker/PeriodPicker.js +124 -101
- package/es/PeriodPicker/constants.js +13 -78
- package/es/PeriodPicker/index.js +1 -0
- package/es/PeriodPicker/lib.js +23 -37
- package/es/PeriodPicker/styles.js +1 -0
- package/es/ScopeList/Header.js +60 -41
- package/es/ScopeList/Item.js +144 -98
- package/es/ScopeList/ScopeList.js +184 -132
- package/es/ScopeList/Selection.js +93 -51
- package/es/ScopeList/index.js +1 -0
- package/es/ScopeList/styles.js +3 -2
- package/es/ScopeList/with-scope-list.js +88 -151
- package/es/Select/Select.js +60 -44
- package/es/Select/index.js +1 -0
- package/es/Share/Form.js +88 -58
- package/es/Share/Mode.js +98 -36
- package/es/Share/Share.js +64 -41
- package/es/Share/index.js +10 -1
- package/es/SisccFooter/SisccFooter.js +36 -29
- package/es/SisccFooter/index.js +1 -0
- package/es/Spotlight/Fields.js +71 -37
- package/es/Spotlight/Spotlight.js +92 -51
- package/es/Spotlight/index.js +1 -0
- package/es/Spotlight/useSpotlight.js +13 -33
- package/es/Spotlight/useStyles.js +4 -2
- package/es/Table/Table.js +71 -50
- package/es/Table/header.js +50 -36
- package/es/Table/index.js +1 -0
- package/es/Table/itemCell.js +25 -13
- package/es/Table/row-header.js +50 -31
- package/es/Table/section-header.js +55 -30
- package/es/Table/section-rows.js +62 -38
- package/es/Table/styles.js +8 -2
- package/es/Table/tableCell.js +17 -7
- package/es/Table/tooltip.js +41 -21
- package/es/Table/useStyles.js +3 -2
- package/es/Table/valueCell.js +41 -26
- package/es/TableFooter/TableFooter.js +70 -42
- package/es/TableFooter/index.js +1 -0
- package/es/TableHeader/TableHeader.js +36 -18
- package/es/TableHeader/index.js +1 -0
- package/es/TableHtml5/TableHtml5.js +72 -60
- package/es/TableHtml5/cell.js +55 -35
- package/es/TableHtml5/flags.js +58 -29
- package/es/TableHtml5/header.js +85 -53
- package/es/TableHtml5/index.js +1 -0
- package/es/TableHtml5/section.js +131 -86
- package/es/TableHtml5/sectionHeader.js +72 -45
- package/es/TableHtml5/subHeader.js +70 -47
- package/es/TableLayout/Box.js +66 -33
- package/es/TableLayout/DnDItem.js +68 -37
- package/es/TableLayout/TableLayout.js +177 -105
- package/es/TableLayout/constants.js +2 -0
- package/es/TableLayout/index.js +1 -0
- package/es/TableLayout/lib.js +3 -1
- package/es/TablePreview/TablePreview.js +176 -99
- package/es/TablePreview/index.js +1 -0
- package/es/TablePreview/lib.js +4 -5
- package/es/TablePreview/styles.js +1 -0
- package/es/Tag/Tag.js +21 -5
- package/es/Tag/index.js +1 -0
- package/es/ToggleButton/ToggleButton.js +29 -17
- package/es/ToggleButton/index.js +1 -0
- package/es/Tooltip/Tooltip.js +32 -20
- package/es/Tooltip/index.js +1 -0
- package/es/VerticalButton/VerticalButton.js +22 -17
- package/es/VerticalButton/index.js +1 -0
- package/es/index.js +4 -2
- package/es/theme.js +14 -22
- package/es/utils.js +14 -16
- package/lib/Alert/Alert.js +168 -87
- package/lib/Alert/index.js +12 -7
- package/lib/ApiQueries/ApiQueries.js +105 -61
- package/lib/ApiQueries/Query.js +132 -85
- package/lib/ApiQueries/index.js +12 -7
- package/lib/AuthDialog/index.js +137 -82
- package/lib/Breadcrumbs/Breadcrumbs.js +68 -39
- package/lib/Breadcrumbs/index.js +12 -7
- package/lib/Button/Button.js +47 -28
- package/lib/Button/index.js +12 -7
- package/lib/ChartsConfig/Axis.js +100 -88
- package/lib/ChartsConfig/ButtonGroup.js +74 -43
- package/lib/ChartsConfig/ChartsConfig.js +236 -113
- package/lib/ChartsConfig/ContainerTitle.js +59 -30
- package/lib/ChartsConfig/Focus.js +71 -53
- package/lib/ChartsConfig/Frequency.js +59 -39
- package/lib/ChartsConfig/Series.js +70 -45
- package/lib/ChartsConfig/Size.js +77 -53
- package/lib/ChartsConfig/index.js +12 -7
- package/lib/ChartsConfig/styles.js +11 -16
- package/lib/ChartsConfig/utils.js +13 -14
- package/lib/Chips/Chips.js +192 -122
- package/lib/Chips/index.js +12 -7
- package/lib/CollapseButtons/CollapseButtons.js +134 -84
- package/lib/CollapseButtons/Item.js +98 -64
- package/lib/CollapseButtons/Paper.js +41 -19
- package/lib/CollapseButtons/index.js +12 -7
- package/lib/DataEdit/DataEdit.js +156 -88
- package/lib/DataEdit/Input.js +82 -42
- package/lib/DataEdit/index.js +12 -7
- package/lib/DataFooter/DataFooter.js +144 -88
- package/lib/DataFooter/index.js +12 -7
- package/lib/DataHeader/DataHeader.js +158 -106
- package/lib/DataHeader/Flags.js +34 -18
- package/lib/DataHeader/Title.js +27 -11
- package/lib/DataHeader/TooltipHeader.js +79 -48
- package/lib/DataHeader/index.js +12 -7
- package/lib/DataHeader/utils.js +10 -16
- package/lib/Dataflow/Dataflow.js +277 -159
- package/lib/Dataflow/index.js +12 -7
- package/lib/ExpansionPanel/ExpansionPanel.js +116 -63
- package/lib/ExpansionPanel/index.js +12 -7
- package/lib/ExpansionPanel/styles.js +12 -15
- package/lib/Icons/AccessibilityFilled.js +17 -15
- package/lib/Icons/AccessibilityOutlined.js +17 -15
- package/lib/Icons/AccountFilled.js +17 -15
- package/lib/Icons/AccountOutlined.js +17 -15
- package/lib/Icons/Api.js +17 -15
- package/lib/Icons/Asterisk.js +17 -15
- package/lib/Icons/Bar.js +17 -15
- package/lib/Icons/CopyContent.js +17 -15
- package/lib/Icons/Cross.js +17 -15
- package/lib/Icons/HSymbol.js +17 -15
- package/lib/Icons/Row.js +17 -15
- package/lib/Icons/Scatter.js +17 -15
- package/lib/Icons/StackedBar.js +17 -15
- package/lib/Icons/StackedRow.js +17 -15
- package/lib/Icons/Timeline.js +17 -15
- package/lib/Icons/VSymbol.js +17 -15
- package/lib/Icons/Warning.js +31 -27
- package/lib/Icons/index.js +152 -68
- package/lib/Input/Input.js +85 -47
- package/lib/Input/index.js +12 -7
- package/lib/Input/with-input.js +35 -38
- package/lib/InputNumber/InputNumber.js +80 -50
- package/lib/InputNumber/index.js +12 -7
- package/lib/LabelDivider/LabelDivider.js +37 -23
- package/lib/LabelDivider/index.js +12 -7
- package/lib/Loading/Loading.js +35 -20
- package/lib/Loading/index.js +12 -7
- package/lib/Logo/Logo.js +28 -20
- package/lib/Logo/index.js +12 -7
- package/lib/NoData/NoData.js +42 -28
- package/lib/NoData/index.js +12 -7
- package/lib/Pagination/Pagination.js +150 -91
- package/lib/Pagination/index.js +12 -7
- package/lib/PeriodPicker/PeriodPicker.js +150 -121
- package/lib/PeriodPicker/constants.js +37 -126
- package/lib/PeriodPicker/index.js +12 -7
- package/lib/PeriodPicker/lib.js +61 -99
- package/lib/PeriodPicker/styles.js +4 -7
- package/lib/ScopeList/Header.js +88 -58
- package/lib/ScopeList/Item.js +177 -116
- package/lib/ScopeList/ScopeList.js +234 -160
- package/lib/ScopeList/Selection.js +131 -70
- package/lib/ScopeList/index.js +12 -7
- package/lib/ScopeList/styles.js +9 -10
- package/lib/ScopeList/with-scope-list.js +108 -199
- package/lib/Select/Select.js +80 -59
- package/lib/Select/index.js +12 -7
- package/lib/Share/Form.js +119 -77
- package/lib/Share/Mode.js +130 -54
- package/lib/Share/Share.js +91 -59
- package/lib/Share/index.js +12 -7
- package/lib/SisccFooter/SisccFooter.js +63 -44
- package/lib/SisccFooter/index.js +12 -7
- package/lib/Spotlight/Fields.js +100 -54
- package/lib/Spotlight/Spotlight.js +136 -75
- package/lib/Spotlight/index.js +12 -7
- package/lib/Spotlight/useSpotlight.js +20 -44
- package/lib/Spotlight/useStyles.js +12 -15
- package/lib/Table/Table.js +102 -69
- package/lib/Table/header.js +70 -51
- package/lib/Table/index.js +12 -7
- package/lib/Table/itemCell.js +41 -25
- package/lib/Table/row-header.js +75 -49
- package/lib/Table/section-header.js +82 -50
- package/lib/Table/section-rows.js +94 -60
- package/lib/Table/styles.js +25 -23
- package/lib/Table/tableCell.js +37 -19
- package/lib/Table/tooltip.js +54 -36
- package/lib/Table/useStyles.js +8 -11
- package/lib/Table/valueCell.js +59 -39
- package/lib/TableFooter/TableFooter.js +93 -57
- package/lib/TableFooter/index.js +12 -7
- package/lib/TableHeader/TableHeader.js +56 -32
- package/lib/TableHeader/index.js +12 -7
- package/lib/TableHtml5/TableHtml5.js +100 -78
- package/lib/TableHtml5/cell.js +84 -52
- package/lib/TableHtml5/flags.js +82 -48
- package/lib/TableHtml5/header.js +115 -70
- package/lib/TableHtml5/index.js +17 -8
- package/lib/TableHtml5/section.js +171 -109
- package/lib/TableHtml5/sectionHeader.js +102 -64
- package/lib/TableHtml5/subHeader.js +98 -65
- package/lib/TableLayout/Box.js +97 -54
- package/lib/TableLayout/DnDItem.js +98 -58
- package/lib/TableLayout/TableLayout.js +232 -140
- package/lib/TableLayout/constants.js +6 -8
- package/lib/TableLayout/index.js +12 -7
- package/lib/TableLayout/lib.js +9 -14
- package/lib/TablePreview/TablePreview.js +205 -118
- package/lib/TablePreview/index.js +12 -7
- package/lib/TablePreview/lib.js +19 -30
- package/lib/TablePreview/styles.js +6 -7
- package/lib/Tag/Tag.js +38 -19
- package/lib/Tag/index.js +12 -7
- package/lib/ToggleButton/ToggleButton.js +55 -33
- package/lib/ToggleButton/index.js +12 -7
- package/lib/Tooltip/Tooltip.js +50 -34
- package/lib/Tooltip/index.js +12 -7
- package/lib/VerticalButton/VerticalButton.js +46 -40
- package/lib/VerticalButton/index.js +12 -7
- package/lib/index.js +304 -137
- package/lib/theme.js +17 -31
- package/lib/utils.js +31 -46
- package/package.json +10 -2
package/es/ChartsConfig/Axis.js
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
|
2
|
+
|
|
2
3
|
import React from 'react';
|
|
4
|
+
import PropTypes from 'prop-types';
|
|
3
5
|
import * as R from 'ramda';
|
|
4
6
|
import Grid from '@material-ui/core/Grid';
|
|
5
7
|
import Input from '../DataEdit/Input';
|
|
@@ -15,78 +17,80 @@ var AxisConfig = function AxisConfig(_ref) {
|
|
|
15
17
|
min = _ref.min,
|
|
16
18
|
pivot = _ref.pivot,
|
|
17
19
|
step = _ref.step;
|
|
20
|
+
|
|
18
21
|
var classes = useStyles();
|
|
19
|
-
return
|
|
20
|
-
|
|
21
|
-
icon: icon,
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
lg: 3,
|
|
80
|
-
className: classes.axis
|
|
81
|
-
}, /*#__PURE__*/React.createElement(Input, _extends({}, step, {
|
|
82
|
-
value: R.when(R.isNil, R.always(''))(step.value),
|
|
83
|
-
type: "number",
|
|
84
|
-
label: R.prop('step', labels),
|
|
85
|
-
fullWidth: true,
|
|
86
|
-
InputProps: {
|
|
87
|
-
endAdornment: null
|
|
88
|
-
}
|
|
89
|
-
})))));
|
|
22
|
+
return React.createElement(
|
|
23
|
+
ContainerTitle,
|
|
24
|
+
{ variant: 'grey', icon: icon, label: label, gridItemProps: { xs: 12 } },
|
|
25
|
+
React.createElement(
|
|
26
|
+
Grid,
|
|
27
|
+
{ container: true, spacing: 1 },
|
|
28
|
+
isActive(min) && React.createElement(
|
|
29
|
+
Grid,
|
|
30
|
+
{ item: true, xs: 12, sm: 12, md: 6, lg: 3, className: classes.axis },
|
|
31
|
+
React.createElement(Input, _extends({}, min, {
|
|
32
|
+
value: R.when(R.isNil, R.always(''))(min.value),
|
|
33
|
+
type: 'number',
|
|
34
|
+
label: R.prop('min', labels),
|
|
35
|
+
fullWidth: true,
|
|
36
|
+
InputProps: {
|
|
37
|
+
endAdornment: null
|
|
38
|
+
}
|
|
39
|
+
}))
|
|
40
|
+
),
|
|
41
|
+
isActive(max) && React.createElement(
|
|
42
|
+
Grid,
|
|
43
|
+
{ item: true, xs: 12, sm: 12, md: 6, lg: 3, className: classes.axis },
|
|
44
|
+
React.createElement(Input, _extends({}, max, {
|
|
45
|
+
value: R.when(R.isNil, R.always(''))(max.value),
|
|
46
|
+
type: 'number',
|
|
47
|
+
label: R.prop('max', labels),
|
|
48
|
+
fullWidth: true,
|
|
49
|
+
InputProps: {
|
|
50
|
+
endAdornment: null
|
|
51
|
+
}
|
|
52
|
+
}))
|
|
53
|
+
),
|
|
54
|
+
isActive(pivot) && React.createElement(
|
|
55
|
+
Grid,
|
|
56
|
+
{ item: true, xs: 12, sm: 12, md: 6, lg: 3, className: classes.axis },
|
|
57
|
+
React.createElement(Input, _extends({}, pivot, {
|
|
58
|
+
value: R.when(R.isNil, R.always(''))(pivot.value),
|
|
59
|
+
type: 'number',
|
|
60
|
+
label: R.prop('pivot', labels),
|
|
61
|
+
fullWidth: true,
|
|
62
|
+
InputProps: {
|
|
63
|
+
endAdornment: null
|
|
64
|
+
}
|
|
65
|
+
}))
|
|
66
|
+
),
|
|
67
|
+
isActive(step) && React.createElement(
|
|
68
|
+
Grid,
|
|
69
|
+
{ item: true, xs: 12, sm: 12, md: 6, lg: 3, className: classes.axis },
|
|
70
|
+
React.createElement(Input, _extends({}, step, {
|
|
71
|
+
value: R.when(R.isNil, R.always(''))(step.value),
|
|
72
|
+
type: 'number',
|
|
73
|
+
label: R.prop('step', labels),
|
|
74
|
+
fullWidth: true,
|
|
75
|
+
InputProps: {
|
|
76
|
+
endAdornment: null
|
|
77
|
+
}
|
|
78
|
+
}))
|
|
79
|
+
)
|
|
80
|
+
)
|
|
81
|
+
);
|
|
90
82
|
};
|
|
91
83
|
|
|
84
|
+
AxisConfig.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
85
|
+
icon: PropTypes.node,
|
|
86
|
+
label: PropTypes.string,
|
|
87
|
+
labels: PropTypes.object,
|
|
88
|
+
max: PropTypes.object,
|
|
89
|
+
min: PropTypes.object,
|
|
90
|
+
pivot: PropTypes.object,
|
|
91
|
+
step: PropTypes.object,
|
|
92
|
+
hasOnSubmit: PropTypes.bool,
|
|
93
|
+
onChange: PropTypes.func
|
|
94
|
+
} : {};
|
|
95
|
+
|
|
92
96
|
export default AxisConfig;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import PropTypes from 'prop-types';
|
|
2
3
|
import * as R from 'ramda';
|
|
3
4
|
import Grid from '@material-ui/core/Grid';
|
|
4
5
|
import Typography from '@material-ui/core/Typography';
|
|
@@ -10,35 +11,56 @@ var ButtonGroup = function ButtonGroup(_ref) {
|
|
|
10
11
|
onChange = _ref.onChange,
|
|
11
12
|
options = _ref.options,
|
|
12
13
|
value = _ref.value;
|
|
13
|
-
return
|
|
14
|
-
|
|
15
|
-
alignItems:
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
14
|
+
return React.createElement(
|
|
15
|
+
Grid,
|
|
16
|
+
{ container: true, alignItems: 'center' },
|
|
17
|
+
React.createElement(
|
|
18
|
+
Grid,
|
|
19
|
+
{ item: true, xs: 6 },
|
|
20
|
+
React.createElement(
|
|
21
|
+
Typography,
|
|
22
|
+
{ variant: 'body2' },
|
|
23
|
+
label
|
|
24
|
+
)
|
|
25
|
+
),
|
|
26
|
+
React.createElement(
|
|
27
|
+
Grid,
|
|
28
|
+
{ item: true, xs: 6 },
|
|
29
|
+
React.createElement(
|
|
30
|
+
Grid,
|
|
31
|
+
{ container: true, spacing: 1, justifyContent: 'flex-end' },
|
|
32
|
+
R.map(function (option) {
|
|
33
|
+
return React.createElement(
|
|
34
|
+
Grid,
|
|
35
|
+
{ item: true, key: option.value },
|
|
36
|
+
React.createElement(
|
|
37
|
+
Button,
|
|
38
|
+
{
|
|
39
|
+
variant: option.value === value ? 'contained' : 'outlined',
|
|
40
|
+
onClick: function onClick() {
|
|
41
|
+
return onChange(option.value);
|
|
42
|
+
},
|
|
43
|
+
color: 'primary'
|
|
44
|
+
},
|
|
45
|
+
React.createElement(
|
|
46
|
+
Typography,
|
|
47
|
+
{ variant: 'body2' },
|
|
48
|
+
R.prop(option.value, labels)
|
|
49
|
+
)
|
|
50
|
+
)
|
|
51
|
+
);
|
|
52
|
+
})(options)
|
|
53
|
+
)
|
|
54
|
+
)
|
|
55
|
+
);
|
|
42
56
|
};
|
|
43
57
|
|
|
58
|
+
ButtonGroup.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
59
|
+
label: PropTypes.string,
|
|
60
|
+
labels: PropTypes.object,
|
|
61
|
+
onChange: PropTypes.func,
|
|
62
|
+
options: PropTypes.array,
|
|
63
|
+
value: PropTypes.string
|
|
64
|
+
} : {};
|
|
65
|
+
|
|
44
66
|
export default ButtonGroup;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
|
2
|
+
|
|
2
3
|
import React, { Fragment } from 'react';
|
|
4
|
+
import PropTypes from 'prop-types';
|
|
3
5
|
import * as R from 'ramda';
|
|
4
6
|
import Grid from '@material-ui/core/Grid';
|
|
5
7
|
import Divider from '@material-ui/core/Divider';
|
|
@@ -19,98 +21,196 @@ import { withBlank } from '../utils';
|
|
|
19
21
|
var ChartsConfig = function ChartsConfig(_ref) {
|
|
20
22
|
var labels = _ref.labels,
|
|
21
23
|
properties = _ref.properties;
|
|
24
|
+
|
|
22
25
|
var classes = useStyles();
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
container: true,
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
26
|
+
|
|
27
|
+
return React.createElement(
|
|
28
|
+
Grid,
|
|
29
|
+
{ 'data-testid': 'charts-config-test-id', spacing: 2, container: true, className: classes.root },
|
|
30
|
+
isActivePanel(seriesProperties, properties) && React.createElement(
|
|
31
|
+
Grid,
|
|
32
|
+
{
|
|
33
|
+
item: true,
|
|
34
|
+
xs: 12,
|
|
35
|
+
sm: 12,
|
|
36
|
+
md: 12,
|
|
37
|
+
lg: isActivePanel(['highlight', 'baseline', 'width', 'height'], properties) ? 6 : 12
|
|
38
|
+
},
|
|
39
|
+
React.createElement(SeriesConfig, { labels: labels, properties: R.pick(seriesProperties, properties) })
|
|
40
|
+
),
|
|
41
|
+
isActivePanel(['highlight', 'baseline', 'width', 'height'], properties) && React.createElement(
|
|
42
|
+
Grid,
|
|
43
|
+
{
|
|
44
|
+
item: true,
|
|
45
|
+
xs: 12,
|
|
46
|
+
sm: 12,
|
|
47
|
+
md: 12,
|
|
48
|
+
lg: isActivePanel(seriesProperties, properties) ? 6 : 12
|
|
49
|
+
},
|
|
50
|
+
React.createElement(
|
|
51
|
+
Grid,
|
|
52
|
+
{ container: true, spacing: 2 },
|
|
53
|
+
isActivePanel(['highlight', 'baseline'], properties) && React.createElement(FocusConfig, {
|
|
54
|
+
baseline: R.prop('baseline', properties),
|
|
55
|
+
highlight: R.prop('highlight', properties),
|
|
56
|
+
labels: labels
|
|
57
|
+
}),
|
|
58
|
+
isActivePanel(['width', 'height'], properties) && React.createElement(SizeConfig, {
|
|
59
|
+
height: R.prop('height', properties),
|
|
60
|
+
labels: labels,
|
|
61
|
+
width: R.prop('width', properties)
|
|
62
|
+
})
|
|
63
|
+
)
|
|
64
|
+
),
|
|
65
|
+
React.createElement(
|
|
66
|
+
Grid,
|
|
67
|
+
{ container: true, spacing: 2 },
|
|
68
|
+
isActivePanel(['maxX', 'minX', 'pivotX', 'stepX'], properties) && React.createElement(
|
|
69
|
+
Grid,
|
|
70
|
+
{
|
|
71
|
+
item: true,
|
|
72
|
+
xs: 12,
|
|
73
|
+
sm: 12,
|
|
74
|
+
md: 12,
|
|
75
|
+
lg: isActivePanel(['maxY', 'minY', 'pivotY', 'stepY'], properties) ? 6 : 12
|
|
76
|
+
},
|
|
77
|
+
React.createElement(AxisConfig, {
|
|
78
|
+
icon: React.createElement(ArrowForwardIcon, null),
|
|
79
|
+
label: R.prop('axisX', labels),
|
|
80
|
+
labels: labels,
|
|
81
|
+
max: R.prop('maxX', properties),
|
|
82
|
+
min: R.prop('minX', properties),
|
|
83
|
+
pivot: R.prop('pivotX', properties),
|
|
84
|
+
step: R.prop('stepX', properties)
|
|
85
|
+
})
|
|
86
|
+
),
|
|
87
|
+
isActivePanel(['freqStep'], properties) && React.createElement(
|
|
88
|
+
Grid,
|
|
89
|
+
{
|
|
90
|
+
item: true,
|
|
91
|
+
xs: 12,
|
|
92
|
+
sm: 12,
|
|
93
|
+
md: 12,
|
|
94
|
+
lg: isActivePanel(['maxY', 'minY', 'pivotY', 'stepY'], properties) ? 6 : 12
|
|
95
|
+
},
|
|
96
|
+
React.createElement(FrequencyConfig, {
|
|
97
|
+
freqStep: R.prop('freqStep', properties),
|
|
98
|
+
icon: React.createElement(ArrowForwardIcon, null),
|
|
99
|
+
labels: labels
|
|
100
|
+
})
|
|
101
|
+
),
|
|
102
|
+
isActivePanel(['maxY', 'minY', 'pivotY', 'stepY'], properties) && React.createElement(
|
|
103
|
+
Grid,
|
|
104
|
+
{
|
|
105
|
+
item: true,
|
|
106
|
+
xs: 12,
|
|
107
|
+
sm: 12,
|
|
108
|
+
md: 12,
|
|
109
|
+
lg: isActivePanel(['maxX', 'minX', 'pivotX', 'stepX', 'freqStep'], properties) ? 6 : 12
|
|
110
|
+
},
|
|
111
|
+
React.createElement(AxisConfig, {
|
|
112
|
+
icon: React.createElement(ArrowUpwardIcon, null),
|
|
113
|
+
label: R.prop('axisY', labels),
|
|
114
|
+
labels: labels,
|
|
115
|
+
max: R.prop('maxY', properties),
|
|
116
|
+
min: R.prop('minY', properties),
|
|
117
|
+
pivot: R.prop('pivotY', properties),
|
|
118
|
+
step: R.prop('stepY', properties)
|
|
119
|
+
})
|
|
120
|
+
),
|
|
121
|
+
isActive(R.prop('display', properties)) && React.createElement(
|
|
122
|
+
Grid,
|
|
123
|
+
{ item: true, xs: 12, className: classes.gridItemSpace },
|
|
124
|
+
React.createElement(ButtonGroup, _extends({}, R.prop('display', properties), {
|
|
125
|
+
label: R.prop('display', labels),
|
|
126
|
+
labels: R.prop('displayOptions', labels)
|
|
127
|
+
}))
|
|
128
|
+
)
|
|
129
|
+
),
|
|
130
|
+
isActivePanel(['title', 'subtitle', 'source', 'logo', 'copyright'], properties) && React.createElement(
|
|
131
|
+
Fragment,
|
|
132
|
+
null,
|
|
133
|
+
React.createElement(Divider, { className: classes.divider }),
|
|
134
|
+
React.createElement(DataEdit, { labels: labels, properties: properties })
|
|
135
|
+
)
|
|
136
|
+
);
|
|
108
137
|
};
|
|
109
138
|
|
|
139
|
+
var submitableInputProptypes = PropTypes.shape({
|
|
140
|
+
id: PropTypes.string,
|
|
141
|
+
isActive: PropTypes.bool,
|
|
142
|
+
onSubmit: PropTypes.func,
|
|
143
|
+
value: PropTypes.oneOfType([PropTypes.number, PropTypes.string])
|
|
144
|
+
});
|
|
145
|
+
|
|
146
|
+
var selectableInputProptypes = PropTypes.shape({
|
|
147
|
+
id: PropTypes.string,
|
|
148
|
+
isActive: PropTypes.bool,
|
|
149
|
+
onChange: PropTypes.func,
|
|
150
|
+
options: PropTypes.arrayOf(PropTypes.shape({
|
|
151
|
+
value: PropTypes.string,
|
|
152
|
+
label: PropTypes.string
|
|
153
|
+
})),
|
|
154
|
+
value: PropTypes.shape({
|
|
155
|
+
value: PropTypes.string,
|
|
156
|
+
label: PropTypes.string
|
|
157
|
+
})
|
|
158
|
+
});
|
|
159
|
+
|
|
160
|
+
var multiSelectableInputProptypes = PropTypes.shape({
|
|
161
|
+
id: PropTypes.string,
|
|
162
|
+
isActive: PropTypes.bool,
|
|
163
|
+
onChange: PropTypes.func,
|
|
164
|
+
options: PropTypes.arrayOf(PropTypes.shape({
|
|
165
|
+
value: PropTypes.string,
|
|
166
|
+
label: PropTypes.string
|
|
167
|
+
})),
|
|
168
|
+
value: PropTypes.arrayOf(PropTypes.shape({
|
|
169
|
+
value: PropTypes.string,
|
|
170
|
+
label: PropTypes.string
|
|
171
|
+
}))
|
|
172
|
+
});
|
|
173
|
+
|
|
174
|
+
ChartsConfig.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
175
|
+
labels: PropTypes.object,
|
|
176
|
+
properties: PropTypes.shape({
|
|
177
|
+
highlight: multiSelectableInputProptypes,
|
|
178
|
+
baseline: multiSelectableInputProptypes,
|
|
179
|
+
width: submitableInputProptypes,
|
|
180
|
+
height: submitableInputProptypes,
|
|
181
|
+
scatterDimension: selectableInputProptypes,
|
|
182
|
+
scatterX: selectableInputProptypes,
|
|
183
|
+
scatterY: selectableInputProptypes,
|
|
184
|
+
symbolDimension: selectableInputProptypes,
|
|
185
|
+
stackedDimension: selectableInputProptypes,
|
|
186
|
+
stackedMode: PropTypes.shape({
|
|
187
|
+
id: PropTypes.string,
|
|
188
|
+
isActive: PropTypes.bool,
|
|
189
|
+
onChange: PropTypes.func,
|
|
190
|
+
options: PropTypes.arrayOf(PropTypes.shape({
|
|
191
|
+
value: PropTypes.string
|
|
192
|
+
})),
|
|
193
|
+
value: PropTypes.string
|
|
194
|
+
}),
|
|
195
|
+
freqStep: submitableInputProptypes,
|
|
196
|
+
maxX: submitableInputProptypes,
|
|
197
|
+
minX: submitableInputProptypes,
|
|
198
|
+
pivotX: submitableInputProptypes,
|
|
199
|
+
stepX: submitableInputProptypes,
|
|
200
|
+
maxY: submitableInputProptypes,
|
|
201
|
+
minY: submitableInputProptypes,
|
|
202
|
+
pivotY: submitableInputProptypes,
|
|
203
|
+
stepY: submitableInputProptypes,
|
|
204
|
+
title: submitableInputProptypes,
|
|
205
|
+
subtitle: submitableInputProptypes,
|
|
206
|
+
source: submitableInputProptypes
|
|
207
|
+
})
|
|
208
|
+
} : {};
|
|
209
|
+
|
|
110
210
|
export default withBlank(function (_ref2) {
|
|
111
211
|
var isBlank = _ref2.isBlank,
|
|
112
212
|
_ref2$properties = _ref2.properties,
|
|
113
|
-
properties = _ref2$properties ===
|
|
213
|
+
properties = _ref2$properties === undefined ? {} : _ref2$properties;
|
|
114
214
|
return {
|
|
115
215
|
isBlank: R.or(isBlank, R.isEmpty(properties))
|
|
116
216
|
};
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
|
2
|
+
|
|
2
3
|
import React from 'react';
|
|
4
|
+
import PropTypes from 'prop-types';
|
|
3
5
|
import * as R from 'ramda';
|
|
4
6
|
import cx from 'classnames';
|
|
5
7
|
import Grid from '@material-ui/core/Grid';
|
|
@@ -14,21 +16,40 @@ var ContainerTitle = function ContainerTitle(_ref) {
|
|
|
14
16
|
icon = _ref.icon,
|
|
15
17
|
label = _ref.label,
|
|
16
18
|
gridItemProps = _ref.gridItemProps;
|
|
19
|
+
|
|
17
20
|
var classes = useStyles();
|
|
18
|
-
return
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
21
|
+
return React.createElement(
|
|
22
|
+
Grid,
|
|
23
|
+
_extends({
|
|
24
|
+
item: true
|
|
25
|
+
}, gridItemProps, {
|
|
26
|
+
className: cx((_cx = {}, _cx[classes.greyVariant] = R.equals(variant, 'grey'), _cx))
|
|
27
|
+
}),
|
|
28
|
+
React.createElement(
|
|
29
|
+
Grid,
|
|
30
|
+
{ container: true },
|
|
31
|
+
React.createElement(
|
|
32
|
+
Grid,
|
|
33
|
+
{ item: true, xs: 12, className: cx(classes.gridItemSpace, classes.containerTitle) },
|
|
34
|
+
R.not(R.isNil(icon)) && icon,
|
|
35
|
+
React.createElement(
|
|
36
|
+
Typography,
|
|
37
|
+
{ variant: 'h6', className: classes.title },
|
|
38
|
+
label
|
|
39
|
+
)
|
|
40
|
+
)
|
|
41
|
+
),
|
|
42
|
+
children
|
|
43
|
+
);
|
|
32
44
|
};
|
|
33
45
|
|
|
46
|
+
ContainerTitle.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
47
|
+
label: PropTypes.string,
|
|
48
|
+
variant: PropTypes.string,
|
|
49
|
+
icon: PropTypes.node,
|
|
50
|
+
gridItemProps: PropTypes.object,
|
|
51
|
+
onSubmit: PropTypes.func,
|
|
52
|
+
children: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.node), PropTypes.node])
|
|
53
|
+
} : {};
|
|
54
|
+
|
|
34
55
|
export default ContainerTitle;
|