@sis-cc/dotstatsuite-visions 6.5.2 → 6.6.0
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 +66 -135
- package/es/Alert/index.js +0 -1
- package/es/ApiQueries/ApiQueries.js +45 -79
- package/es/ApiQueries/Query.js +65 -105
- package/es/ApiQueries/index.js +0 -1
- package/es/AuthDialog/index.js +62 -103
- package/es/Breadcrumbs/Breadcrumbs.js +21 -38
- package/es/Breadcrumbs/index.js +0 -1
- package/es/Button/Button.js +11 -28
- package/es/Button/index.js +0 -1
- package/es/ChartsConfig/Axis.js +72 -76
- package/es/ChartsConfig/ButtonGroup.js +29 -51
- package/es/ChartsConfig/ChartsConfig.js +87 -187
- package/es/ChartsConfig/ContainerTitle.js +15 -36
- package/es/ChartsConfig/Focus.js +37 -48
- package/es/ChartsConfig/Frequency.js +24 -36
- package/es/ChartsConfig/Series.js +28 -43
- package/es/ChartsConfig/Size.js +36 -50
- package/es/ChartsConfig/index.js +0 -1
- package/es/ChartsConfig/styles.js +4 -4
- package/es/ChartsConfig/utils.js +1 -5
- package/es/Chips/Chips.js +99 -154
- package/es/Chips/index.js +0 -1
- package/es/CollapseButtons/CollapseButtons.js +61 -101
- package/es/CollapseButtons/Item.js +45 -70
- package/es/CollapseButtons/Paper.js +7 -21
- package/es/CollapseButtons/index.js +0 -1
- package/es/DataEdit/DataEdit.js +67 -124
- package/es/DataEdit/Input.js +27 -58
- package/es/DataEdit/index.js +0 -1
- package/es/DataFooter/DataFooter.js +68 -115
- package/es/DataFooter/index.js +0 -1
- package/es/DataHeader/DataHeader.js +75 -113
- package/es/DataHeader/Flags.js +8 -21
- package/es/DataHeader/Title.js +2 -15
- package/es/DataHeader/TooltipHeader.js +33 -63
- package/es/DataHeader/index.js +0 -1
- package/es/DataHeader/utils.js +8 -8
- package/es/Dataflow/Dataflow.js +132 -226
- package/es/Dataflow/index.js +0 -1
- package/es/ExpansionPanel/ExpansionPanel.js +42 -79
- package/es/ExpansionPanel/index.js +0 -1
- package/es/ExpansionPanel/styles.js +3 -5
- package/es/Icons/AccessibilityFilled.js +6 -8
- package/es/Icons/AccessibilityOutlined.js +6 -8
- package/es/Icons/AccountFilled.js +6 -8
- package/es/Icons/AccountOutlined.js +6 -8
- package/es/Icons/Api.js +6 -8
- package/es/Icons/Asterisk.js +6 -8
- package/es/Icons/Bar.js +6 -8
- package/es/Icons/CopyContent.js +6 -8
- package/es/Icons/Cross.js +6 -8
- package/es/Icons/HSymbol.js +6 -8
- package/es/Icons/Row.js +6 -8
- package/es/Icons/Scatter.js +6 -8
- package/es/Icons/StackedBar.js +6 -8
- package/es/Icons/StackedRow.js +6 -8
- package/es/Icons/Timeline.js +6 -8
- package/es/Icons/VSymbol.js +6 -8
- package/es/Icons/Warning.js +11 -14
- package/es/Icons/index.js +0 -1
- package/es/Input/Input.js +26 -56
- package/es/Input/index.js +0 -1
- package/es/Input/with-input.js +30 -25
- package/es/InputNumber/InputNumber.js +31 -51
- package/es/InputNumber/index.js +0 -1
- package/es/LabelDivider/LabelDivider.js +7 -18
- package/es/LabelDivider/index.js +0 -1
- package/es/Loading/Loading.js +9 -18
- package/es/Loading/index.js +0 -1
- package/es/Logo/Logo.js +11 -17
- package/es/Logo/index.js +0 -1
- package/es/NoData/NoData.js +17 -25
- package/es/NoData/index.js +0 -1
- package/es/Pagination/Pagination.js +70 -114
- package/es/Pagination/index.js +0 -1
- package/es/PeriodPicker/PeriodPicker.js +101 -124
- package/es/PeriodPicker/constants.js +78 -13
- package/es/PeriodPicker/index.js +0 -1
- package/es/PeriodPicker/lib.js +37 -23
- package/es/PeriodPicker/styles.js +0 -1
- package/es/ScopeList/Header.js +41 -60
- package/es/ScopeList/Item.js +98 -144
- package/es/ScopeList/ScopeList.js +132 -184
- package/es/ScopeList/Selection.js +51 -93
- package/es/ScopeList/index.js +0 -1
- package/es/ScopeList/styles.js +2 -3
- package/es/ScopeList/with-scope-list.js +151 -88
- package/es/Select/Select.js +44 -60
- package/es/Select/index.js +0 -1
- package/es/Share/Form.js +58 -88
- package/es/Share/Mode.js +30 -46
- package/es/Share/Share.js +41 -64
- package/es/Share/index.js +0 -1
- package/es/SisccFooter/SisccFooter.js +29 -36
- package/es/SisccFooter/index.js +0 -1
- package/es/Spotlight/Fields.js +37 -71
- package/es/Spotlight/Spotlight.js +51 -92
- package/es/Spotlight/index.js +0 -1
- package/es/Spotlight/useSpotlight.js +33 -13
- package/es/Spotlight/useStyles.js +2 -4
- package/es/Table/Table.js +50 -71
- package/es/Table/header.js +36 -50
- package/es/Table/index.js +0 -1
- package/es/Table/itemCell.js +13 -25
- package/es/Table/row-header.js +31 -50
- package/es/Table/section-header.js +30 -55
- package/es/Table/section-rows.js +38 -62
- package/es/Table/styles.js +2 -8
- package/es/Table/tableCell.js +7 -17
- package/es/Table/tooltip.js +21 -41
- package/es/Table/useStyles.js +2 -3
- package/es/Table/valueCell.js +26 -41
- package/es/TableFooter/TableFooter.js +42 -70
- package/es/TableFooter/index.js +0 -1
- package/es/TableHeader/TableHeader.js +18 -36
- package/es/TableHeader/index.js +0 -1
- package/es/TableHtml5/TableHtml5.js +71 -68
- package/es/TableHtml5/cell.js +35 -55
- package/es/TableHtml5/flags.js +29 -58
- package/es/TableHtml5/header.js +48 -66
- package/es/TableHtml5/index.js +0 -1
- package/es/TableHtml5/section.js +86 -120
- package/es/TableHtml5/sectionHeader.js +45 -72
- package/es/TableHtml5/subHeader.js +48 -58
- package/es/TableLayout/Box.js +33 -66
- package/es/TableLayout/DnDItem.js +37 -68
- package/es/TableLayout/TableLayout.js +105 -177
- package/es/TableLayout/constants.js +0 -2
- package/es/TableLayout/index.js +0 -1
- package/es/TableLayout/lib.js +1 -3
- package/es/TablePreview/TablePreview.js +99 -176
- package/es/TablePreview/index.js +0 -1
- package/es/TablePreview/lib.js +5 -4
- package/es/TablePreview/styles.js +0 -1
- package/es/Tag/Tag.js +5 -21
- package/es/Tag/index.js +0 -1
- package/es/ToggleButton/ToggleButton.js +17 -29
- package/es/ToggleButton/index.js +0 -1
- package/es/Tooltip/Tooltip.js +20 -32
- package/es/Tooltip/index.js +0 -1
- package/es/VerticalButton/VerticalButton.js +17 -22
- package/es/VerticalButton/index.js +0 -1
- package/es/index.js +2 -4
- package/es/theme.js +22 -14
- package/es/utils.js +16 -14
- package/lib/Alert/Alert.js +87 -168
- package/lib/Alert/index.js +7 -12
- package/lib/ApiQueries/ApiQueries.js +61 -105
- package/lib/ApiQueries/Query.js +85 -132
- package/lib/ApiQueries/index.js +7 -12
- package/lib/AuthDialog/index.js +82 -137
- package/lib/Breadcrumbs/Breadcrumbs.js +39 -68
- package/lib/Breadcrumbs/index.js +7 -12
- package/lib/Button/Button.js +28 -47
- package/lib/Button/index.js +7 -12
- package/lib/ChartsConfig/Axis.js +88 -100
- package/lib/ChartsConfig/ButtonGroup.js +43 -74
- package/lib/ChartsConfig/ChartsConfig.js +113 -236
- package/lib/ChartsConfig/ContainerTitle.js +30 -59
- package/lib/ChartsConfig/Focus.js +53 -71
- package/lib/ChartsConfig/Frequency.js +39 -59
- package/lib/ChartsConfig/Series.js +45 -70
- package/lib/ChartsConfig/Size.js +53 -77
- package/lib/ChartsConfig/index.js +7 -12
- package/lib/ChartsConfig/styles.js +16 -11
- package/lib/ChartsConfig/utils.js +14 -13
- package/lib/Chips/Chips.js +122 -192
- package/lib/Chips/index.js +7 -12
- package/lib/CollapseButtons/CollapseButtons.js +84 -134
- package/lib/CollapseButtons/Item.js +64 -98
- package/lib/CollapseButtons/Paper.js +19 -41
- package/lib/CollapseButtons/index.js +7 -12
- package/lib/DataEdit/DataEdit.js +88 -156
- package/lib/DataEdit/Input.js +42 -82
- package/lib/DataEdit/index.js +7 -12
- package/lib/DataFooter/DataFooter.js +88 -144
- package/lib/DataFooter/index.js +7 -12
- package/lib/DataHeader/DataHeader.js +106 -158
- package/lib/DataHeader/Flags.js +18 -34
- package/lib/DataHeader/Title.js +11 -27
- package/lib/DataHeader/TooltipHeader.js +48 -79
- package/lib/DataHeader/index.js +7 -12
- package/lib/DataHeader/utils.js +16 -10
- package/lib/Dataflow/Dataflow.js +159 -277
- package/lib/Dataflow/index.js +7 -12
- package/lib/ExpansionPanel/ExpansionPanel.js +63 -116
- package/lib/ExpansionPanel/index.js +7 -12
- package/lib/ExpansionPanel/styles.js +15 -12
- package/lib/Icons/AccessibilityFilled.js +15 -17
- package/lib/Icons/AccessibilityOutlined.js +15 -17
- package/lib/Icons/AccountFilled.js +15 -17
- package/lib/Icons/AccountOutlined.js +15 -17
- package/lib/Icons/Api.js +15 -17
- package/lib/Icons/Asterisk.js +15 -17
- package/lib/Icons/Bar.js +15 -17
- package/lib/Icons/CopyContent.js +15 -17
- package/lib/Icons/Cross.js +15 -17
- package/lib/Icons/HSymbol.js +15 -17
- package/lib/Icons/Row.js +15 -17
- package/lib/Icons/Scatter.js +15 -17
- package/lib/Icons/StackedBar.js +15 -17
- package/lib/Icons/StackedRow.js +15 -17
- package/lib/Icons/Timeline.js +15 -17
- package/lib/Icons/VSymbol.js +15 -17
- package/lib/Icons/Warning.js +27 -31
- package/lib/Icons/index.js +68 -152
- package/lib/Input/Input.js +47 -85
- package/lib/Input/index.js +7 -12
- package/lib/Input/with-input.js +38 -35
- package/lib/InputNumber/InputNumber.js +50 -80
- package/lib/InputNumber/index.js +7 -12
- package/lib/LabelDivider/LabelDivider.js +23 -37
- package/lib/LabelDivider/index.js +7 -12
- package/lib/Loading/Loading.js +20 -35
- package/lib/Loading/index.js +7 -12
- package/lib/Logo/Logo.js +20 -28
- package/lib/Logo/index.js +7 -12
- package/lib/NoData/NoData.js +28 -42
- package/lib/NoData/index.js +7 -12
- package/lib/Pagination/Pagination.js +91 -150
- package/lib/Pagination/index.js +7 -12
- package/lib/PeriodPicker/PeriodPicker.js +121 -150
- package/lib/PeriodPicker/constants.js +126 -37
- package/lib/PeriodPicker/index.js +7 -12
- package/lib/PeriodPicker/lib.js +99 -61
- package/lib/PeriodPicker/styles.js +7 -4
- package/lib/ScopeList/Header.js +58 -88
- package/lib/ScopeList/Item.js +116 -177
- package/lib/ScopeList/ScopeList.js +160 -234
- package/lib/ScopeList/Selection.js +70 -131
- package/lib/ScopeList/index.js +7 -12
- package/lib/ScopeList/styles.js +10 -9
- package/lib/ScopeList/with-scope-list.js +199 -108
- package/lib/Select/Select.js +59 -80
- package/lib/Select/index.js +7 -12
- package/lib/Share/Form.js +77 -119
- package/lib/Share/Mode.js +49 -78
- package/lib/Share/Share.js +59 -91
- package/lib/Share/index.js +7 -12
- package/lib/SisccFooter/SisccFooter.js +44 -63
- package/lib/SisccFooter/index.js +7 -12
- package/lib/Spotlight/Fields.js +54 -100
- package/lib/Spotlight/Spotlight.js +75 -136
- package/lib/Spotlight/index.js +7 -12
- package/lib/Spotlight/useSpotlight.js +44 -20
- package/lib/Spotlight/useStyles.js +15 -12
- package/lib/Table/Table.js +69 -102
- package/lib/Table/header.js +51 -70
- package/lib/Table/index.js +7 -12
- package/lib/Table/itemCell.js +25 -41
- package/lib/Table/row-header.js +49 -75
- package/lib/Table/section-header.js +50 -82
- package/lib/Table/section-rows.js +60 -94
- package/lib/Table/styles.js +23 -25
- package/lib/Table/tableCell.js +19 -37
- package/lib/Table/tooltip.js +36 -54
- package/lib/Table/useStyles.js +11 -8
- package/lib/Table/valueCell.js +39 -59
- package/lib/TableFooter/TableFooter.js +57 -93
- package/lib/TableFooter/index.js +7 -12
- package/lib/TableHeader/TableHeader.js +32 -56
- package/lib/TableHeader/index.js +7 -12
- package/lib/TableHtml5/TableHtml5.js +90 -97
- package/lib/TableHtml5/cell.js +52 -84
- package/lib/TableHtml5/flags.js +48 -82
- package/lib/TableHtml5/header.js +66 -96
- package/lib/TableHtml5/index.js +8 -17
- package/lib/TableHtml5/section.js +111 -162
- package/lib/TableHtml5/sectionHeader.js +64 -102
- package/lib/TableHtml5/subHeader.js +68 -88
- package/lib/TableLayout/Box.js +54 -97
- package/lib/TableLayout/DnDItem.js +58 -98
- package/lib/TableLayout/TableLayout.js +140 -232
- package/lib/TableLayout/constants.js +8 -6
- package/lib/TableLayout/index.js +7 -12
- package/lib/TableLayout/lib.js +14 -9
- package/lib/TablePreview/TablePreview.js +118 -205
- package/lib/TablePreview/index.js +7 -12
- package/lib/TablePreview/lib.js +30 -19
- package/lib/TablePreview/styles.js +7 -6
- package/lib/Tag/Tag.js +19 -38
- package/lib/Tag/index.js +7 -12
- package/lib/ToggleButton/ToggleButton.js +33 -55
- package/lib/ToggleButton/index.js +7 -12
- package/lib/Tooltip/Tooltip.js +34 -50
- package/lib/Tooltip/index.js +7 -12
- package/lib/VerticalButton/VerticalButton.js +40 -46
- package/lib/VerticalButton/index.js +7 -12
- package/lib/index.js +137 -304
- package/lib/theme.js +31 -17
- package/lib/utils.js +46 -31
- package/package.json +2 -10
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import PropTypes from 'prop-types';
|
|
3
2
|
import { makeStyles } from '@material-ui/core/styles';
|
|
4
3
|
import Paper from '@material-ui/core/Paper';
|
|
5
4
|
import Grid from '@material-ui/core/Grid';
|
|
6
5
|
import cx from 'classnames';
|
|
7
|
-
|
|
8
6
|
var useStyles = makeStyles(function (theme) {
|
|
9
7
|
return {
|
|
10
8
|
paper: {
|
|
@@ -25,26 +23,14 @@ var CustomPaper = function CustomPaper(_ref) {
|
|
|
25
23
|
|
|
26
24
|
var isMobileView = _ref.isMobileView,
|
|
27
25
|
children = _ref.children;
|
|
28
|
-
|
|
29
26
|
var classes = useStyles();
|
|
30
|
-
return React.createElement(
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
React.createElement(
|
|
38
|
-
Grid,
|
|
39
|
-
{ container: true },
|
|
40
|
-
children
|
|
41
|
-
)
|
|
42
|
-
);
|
|
27
|
+
return /*#__PURE__*/React.createElement(Paper, {
|
|
28
|
+
classes: {
|
|
29
|
+
root: cx(classes.paper, (_cx = {}, _cx[classes.mobileView] = isMobileView, _cx))
|
|
30
|
+
}
|
|
31
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
32
|
+
container: true
|
|
33
|
+
}, children));
|
|
43
34
|
};
|
|
44
35
|
|
|
45
|
-
CustomPaper.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
46
|
-
isMobileView: PropTypes.bool,
|
|
47
|
-
children: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.node), PropTypes.node])
|
|
48
|
-
} : {};
|
|
49
|
-
|
|
50
36
|
export default CustomPaper;
|
package/es/DataEdit/DataEdit.js
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import _extends from "/builds/sis-cc/.stat-suite/dotstatsuite-visions/node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/extends";
|
|
3
2
|
import React from 'react';
|
|
4
|
-
import PropTypes from 'prop-types';
|
|
5
3
|
import * as R from 'ramda';
|
|
6
4
|
import Grid from '@material-ui/core/Grid';
|
|
7
5
|
import Typography from '@material-ui/core/Typography';
|
|
@@ -11,7 +9,6 @@ import { makeStyles } from '@material-ui/styles';
|
|
|
11
9
|
import FormControlLabel from '@material-ui/core/FormControlLabel';
|
|
12
10
|
import Input from './Input';
|
|
13
11
|
import { withBlank } from '../utils';
|
|
14
|
-
|
|
15
12
|
var useStyles = makeStyles(function (theme) {
|
|
16
13
|
return {
|
|
17
14
|
root: _extends({
|
|
@@ -31,139 +28,85 @@ var useStyles = makeStyles(function (theme) {
|
|
|
31
28
|
var DataEdit = function DataEdit(_ref) {
|
|
32
29
|
var labels = _ref.labels,
|
|
33
30
|
properties = _ref.properties;
|
|
34
|
-
|
|
35
31
|
var classes = useStyles();
|
|
36
32
|
var _properties$title = properties.title,
|
|
37
|
-
title = _properties$title ===
|
|
33
|
+
title = _properties$title === void 0 ? {} : _properties$title,
|
|
38
34
|
_properties$subtitle = properties.subtitle,
|
|
39
|
-
subtitle = _properties$subtitle ===
|
|
35
|
+
subtitle = _properties$subtitle === void 0 ? {} : _properties$subtitle,
|
|
40
36
|
_properties$source = properties.source,
|
|
41
|
-
source = _properties$source ===
|
|
37
|
+
source = _properties$source === void 0 ? {} : _properties$source,
|
|
42
38
|
_properties$logo = properties.logo,
|
|
43
|
-
logo = _properties$logo ===
|
|
39
|
+
logo = _properties$logo === void 0 ? {} : _properties$logo,
|
|
44
40
|
_properties$copyright = properties.copyright,
|
|
45
|
-
copyright = _properties$copyright ===
|
|
46
|
-
|
|
41
|
+
copyright = _properties$copyright === void 0 ? {} : _properties$copyright;
|
|
47
42
|
var resetLabel = R.prop('reset', labels);
|
|
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
|
-
|
|
108
|
-
)
|
|
109
|
-
)
|
|
110
|
-
)
|
|
111
|
-
)
|
|
112
|
-
);
|
|
43
|
+
return /*#__PURE__*/React.createElement(Grid, {
|
|
44
|
+
"data-testid": "data-edit-test-id",
|
|
45
|
+
spacing: 2,
|
|
46
|
+
container: true,
|
|
47
|
+
className: classes.root
|
|
48
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
49
|
+
item: true,
|
|
50
|
+
xs: 12
|
|
51
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
52
|
+
container: true
|
|
53
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
54
|
+
item: true,
|
|
55
|
+
xs: 12
|
|
56
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
57
|
+
variant: "h6",
|
|
58
|
+
className: classes.title
|
|
59
|
+
}, 'Information'))), /*#__PURE__*/React.createElement(Grid, {
|
|
60
|
+
spacing: 2,
|
|
61
|
+
container: true
|
|
62
|
+
}, R.or(R.prop('isActive')(title), R.prop('isActive')(subtitle)) && /*#__PURE__*/React.createElement(Grid, {
|
|
63
|
+
item: true,
|
|
64
|
+
xs: 12,
|
|
65
|
+
sm: 12,
|
|
66
|
+
md: 12,
|
|
67
|
+
lg: 6
|
|
68
|
+
}, R.prop('isActive')(title) && /*#__PURE__*/React.createElement(Input, _extends({
|
|
69
|
+
fullWidth: true,
|
|
70
|
+
label: R.prop('title', labels),
|
|
71
|
+
resetLabel: resetLabel
|
|
72
|
+
}, R.dissoc('isDefault', title))), R.prop('isActive')(subtitle) && /*#__PURE__*/React.createElement(Input, _extends({
|
|
73
|
+
fullWidth: true,
|
|
74
|
+
label: R.prop('subtitle', labels),
|
|
75
|
+
resetLabel: resetLabel
|
|
76
|
+
}, R.dissoc('isDefault', subtitle)))), /*#__PURE__*/React.createElement(Grid, {
|
|
77
|
+
item: true,
|
|
78
|
+
xs: 12,
|
|
79
|
+
sm: 12,
|
|
80
|
+
md: 12,
|
|
81
|
+
lg: 6
|
|
82
|
+
}, R.prop('isActive')(source) && /*#__PURE__*/React.createElement(Input, _extends({
|
|
83
|
+
fullWidth: true,
|
|
84
|
+
label: R.prop('source', labels),
|
|
85
|
+
resetLabel: resetLabel
|
|
86
|
+
}, R.dissoc('isDefault', source))), /*#__PURE__*/React.createElement(Container, {
|
|
87
|
+
disableGutters: true,
|
|
88
|
+
className: classes.checkboxes
|
|
89
|
+
}, R.map(function (item) {
|
|
90
|
+
if (R.pipe(R.prop('isActive'), R.not)(item)) return;
|
|
91
|
+
var id = R.prop('id')(item);
|
|
92
|
+
return /*#__PURE__*/React.createElement(FormControlLabel, {
|
|
93
|
+
key: id,
|
|
94
|
+
control: /*#__PURE__*/React.createElement(Checkbox, _extends({
|
|
95
|
+
color: "primary",
|
|
96
|
+
inputProps: {
|
|
97
|
+
'aria-label': R.prop(id)(labels)
|
|
98
|
+
}
|
|
99
|
+
}, R.omit(['isActive'])(item))),
|
|
100
|
+
label: R.prop(id)(labels)
|
|
101
|
+
});
|
|
102
|
+
})([logo, copyright]))))));
|
|
113
103
|
};
|
|
114
104
|
|
|
115
|
-
DataEdit.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
116
|
-
labels: PropTypes.shape({
|
|
117
|
-
title: PropTypes.string,
|
|
118
|
-
subtitle: PropTypes.string,
|
|
119
|
-
source: PropTypes.string,
|
|
120
|
-
logo: PropTypes.string,
|
|
121
|
-
copyright: PropTypes.string,
|
|
122
|
-
reset: PropTypes.string
|
|
123
|
-
}),
|
|
124
|
-
properties: PropTypes.shape({
|
|
125
|
-
title: PropTypes.shape({
|
|
126
|
-
id: PropTypes.string,
|
|
127
|
-
isActive: PropTypes.bool,
|
|
128
|
-
onSubmit: PropTypes.func,
|
|
129
|
-
onReset: PropTypes.func,
|
|
130
|
-
value: PropTypes.string
|
|
131
|
-
}),
|
|
132
|
-
subtitle: PropTypes.shape({
|
|
133
|
-
id: PropTypes.string,
|
|
134
|
-
isActive: PropTypes.bool,
|
|
135
|
-
onSubmit: PropTypes.func,
|
|
136
|
-
onReset: PropTypes.func,
|
|
137
|
-
value: PropTypes.string
|
|
138
|
-
}),
|
|
139
|
-
source: PropTypes.shape({
|
|
140
|
-
id: PropTypes.string,
|
|
141
|
-
isActive: PropTypes.bool,
|
|
142
|
-
onSubmit: PropTypes.func,
|
|
143
|
-
onReset: PropTypes.func,
|
|
144
|
-
value: PropTypes.string
|
|
145
|
-
}),
|
|
146
|
-
logo: PropTypes.shape({
|
|
147
|
-
id: PropTypes.string,
|
|
148
|
-
isActive: PropTypes.bool,
|
|
149
|
-
onChange: PropTypes.func,
|
|
150
|
-
checked: PropTypes.bool
|
|
151
|
-
}),
|
|
152
|
-
copyright: PropTypes.shape({
|
|
153
|
-
id: PropTypes.string,
|
|
154
|
-
isActive: PropTypes.bool,
|
|
155
|
-
onChange: PropTypes.func,
|
|
156
|
-
checked: PropTypes.bool
|
|
157
|
-
})
|
|
158
|
-
})
|
|
159
|
-
} : {};
|
|
160
|
-
|
|
161
105
|
var isAllInactive = R.pipe(R.pluck('isActive'), R.all(R.identity), R.not);
|
|
162
|
-
|
|
163
106
|
export default withBlank(function (_ref2) {
|
|
164
107
|
var isBlank = _ref2.isBlank,
|
|
165
108
|
_ref2$properties = _ref2.properties,
|
|
166
|
-
properties = _ref2$properties ===
|
|
109
|
+
properties = _ref2$properties === void 0 ? {} : _ref2$properties;
|
|
167
110
|
return {
|
|
168
111
|
isBlank: R.any(R.identity)([isBlank, R.isEmpty(properties), isAllInactive(properties)])
|
|
169
112
|
};
|
package/es/DataEdit/Input.js
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import _extends from "/builds/sis-cc/.stat-suite/dotstatsuite-visions/node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/extends";
|
|
2
|
+
import _objectWithoutPropertiesLoose from "/builds/sis-cc/.stat-suite/dotstatsuite-visions/node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
|
+
var _excluded = ["id", "value", "onSubmit", "onReset", "resetLabel", "placeholder"];
|
|
5
4
|
import React, { useEffect, useState } from 'react';
|
|
6
|
-
import PropTypes from 'prop-types';
|
|
7
5
|
import * as R from 'ramda';
|
|
8
6
|
import { makeStyles } from '@material-ui/core/styles';
|
|
9
7
|
import TextField from '@material-ui/core/TextField';
|
|
@@ -11,7 +9,6 @@ import InputAdornment from '@material-ui/core/InputAdornment';
|
|
|
11
9
|
import IconButton from '@material-ui/core/IconButton';
|
|
12
10
|
import Done from '@material-ui/icons/Done';
|
|
13
11
|
import RotateLeftIcon from '@material-ui/icons/RotateLeft';
|
|
14
|
-
|
|
15
12
|
var useStyles = makeStyles(function (theme) {
|
|
16
13
|
return {
|
|
17
14
|
visibility: {
|
|
@@ -31,40 +28,29 @@ var useStyles = makeStyles(function (theme) {
|
|
|
31
28
|
|
|
32
29
|
var LefttIcon = function LefttIcon(_ref) {
|
|
33
30
|
var Icon = _ref.Icon;
|
|
34
|
-
return React.createElement(Icon, null);
|
|
31
|
+
return /*#__PURE__*/React.createElement(Icon, null);
|
|
35
32
|
};
|
|
36
33
|
|
|
37
|
-
LefttIcon.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
38
|
-
Icon: PropTypes.object
|
|
39
|
-
} : {};
|
|
40
|
-
|
|
41
34
|
var RightIcon = function RightIcon(_ref2) {
|
|
42
35
|
var onSubmit = _ref2.onSubmit,
|
|
43
36
|
_ref2$Icon = _ref2.Icon,
|
|
44
|
-
Icon = _ref2$Icon ===
|
|
45
|
-
return React.createElement(
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
);
|
|
37
|
+
Icon = _ref2$Icon === void 0 ? Done : _ref2$Icon;
|
|
38
|
+
return /*#__PURE__*/React.createElement(IconButton, {
|
|
39
|
+
color: "primary",
|
|
40
|
+
onClick: function onClick() {
|
|
41
|
+
return onSubmit();
|
|
42
|
+
}
|
|
43
|
+
}, /*#__PURE__*/React.createElement(Icon, null));
|
|
52
44
|
};
|
|
53
45
|
|
|
54
|
-
|
|
55
|
-
Icon: PropTypes.object,
|
|
56
|
-
onSubmit: PropTypes.func,
|
|
57
|
-
classes: PropTypes.object
|
|
58
|
-
} : {};
|
|
59
|
-
|
|
60
|
-
var MyInput = function MyInput(_ref3) {
|
|
46
|
+
export var MyInput = function MyInput(_ref3) {
|
|
61
47
|
var id = _ref3.id,
|
|
62
48
|
value = _ref3.value,
|
|
63
49
|
onSubmit = _ref3.onSubmit,
|
|
64
50
|
onReset = _ref3.onReset,
|
|
65
51
|
resetLabel = _ref3.resetLabel,
|
|
66
52
|
placeholder = _ref3.placeholder,
|
|
67
|
-
props =
|
|
53
|
+
props = _objectWithoutPropertiesLoose(_ref3, _excluded);
|
|
68
54
|
|
|
69
55
|
var classes = useStyles();
|
|
70
56
|
|
|
@@ -75,8 +61,7 @@ var MyInput = function MyInput(_ref3) {
|
|
|
75
61
|
useEffect(function () {
|
|
76
62
|
setInputValue(value);
|
|
77
63
|
}, [value]);
|
|
78
|
-
|
|
79
|
-
var resetId = 'reset-' + id;
|
|
64
|
+
var resetId = "reset-" + id;
|
|
80
65
|
|
|
81
66
|
var handleBlur = function handleBlur(event) {
|
|
82
67
|
if (R.is(Function, onSubmit) && inputValue !== value) {
|
|
@@ -104,28 +89,23 @@ var MyInput = function MyInput(_ref3) {
|
|
|
104
89
|
setInputValue(event.target.value);
|
|
105
90
|
};
|
|
106
91
|
|
|
107
|
-
var endAdornment = R.is(Function, onReset) || inputValue !== value ? React.createElement(
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
React.createElement(RotateLeftIcon, { fontSize: 'small' })
|
|
119
|
-
)
|
|
120
|
-
) : null;
|
|
121
|
-
|
|
122
|
-
return React.createElement(TextField, _extends({
|
|
92
|
+
var endAdornment = R.is(Function, onReset) || inputValue !== value ? /*#__PURE__*/React.createElement(InputAdornment, {
|
|
93
|
+
position: "end"
|
|
94
|
+
}, /*#__PURE__*/React.createElement(IconButton, {
|
|
95
|
+
id: resetId,
|
|
96
|
+
"aria-label": resetLabel,
|
|
97
|
+
onKeyPress: onEnterLabel,
|
|
98
|
+
onClick: handleReset
|
|
99
|
+
}, /*#__PURE__*/React.createElement(RotateLeftIcon, {
|
|
100
|
+
fontSize: "small"
|
|
101
|
+
}))) : null;
|
|
102
|
+
return /*#__PURE__*/React.createElement(TextField, _extends({
|
|
123
103
|
inputProps: {
|
|
124
104
|
className: classes.input
|
|
125
105
|
},
|
|
126
106
|
onBlur: handleBlur,
|
|
127
|
-
margin:
|
|
128
|
-
variant:
|
|
107
|
+
margin: "dense",
|
|
108
|
+
variant: "outlined",
|
|
129
109
|
onKeyPress: onEnterLabel,
|
|
130
110
|
onChange: handleChange,
|
|
131
111
|
id: id,
|
|
@@ -136,15 +116,4 @@ var MyInput = function MyInput(_ref3) {
|
|
|
136
116
|
placeholder: R.is(Number)(placeholder) ? R.toString(placeholder) : placeholder
|
|
137
117
|
}, R.omit(['isActive'])(props)));
|
|
138
118
|
};
|
|
139
|
-
|
|
140
|
-
export { MyInput };
|
|
141
|
-
MyInput.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
142
|
-
id: PropTypes.string,
|
|
143
|
-
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
|
|
144
|
-
onSubmit: PropTypes.func,
|
|
145
|
-
onReset: PropTypes.func,
|
|
146
|
-
resetLabel: PropTypes.string,
|
|
147
|
-
placeholder: PropTypes.oneOfType([PropTypes.string, PropTypes.number])
|
|
148
|
-
} : {};
|
|
149
|
-
|
|
150
119
|
export default MyInput;
|
package/es/DataEdit/index.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import React, { Fragment } from 'react';
|
|
2
|
-
import PropTypes from 'prop-types';
|
|
3
2
|
import * as R from 'ramda';
|
|
4
3
|
import useSize from '@react-hook/size';
|
|
5
4
|
import Grid from '@material-ui/core/Grid';
|
|
@@ -8,9 +7,7 @@ import Link from '@material-ui/core/Link';
|
|
|
8
7
|
import { makeStyles } from '@material-ui/core/styles';
|
|
9
8
|
import { Tooltip } from '../';
|
|
10
9
|
import { T4_BREAKPOINTS } from '../theme';
|
|
11
|
-
|
|
12
10
|
var HEIGHT = 42;
|
|
13
|
-
|
|
14
11
|
var useStyles = makeStyles(function (theme) {
|
|
15
12
|
return {
|
|
16
13
|
footer: {
|
|
@@ -23,7 +20,6 @@ var useStyles = makeStyles(function (theme) {
|
|
|
23
20
|
padding: function padding(_ref) {
|
|
24
21
|
var isWidthUp = _ref.isWidthUp,
|
|
25
22
|
isSourced = _ref.isSourced;
|
|
26
|
-
|
|
27
23
|
if (isWidthUp(T4_BREAKPOINTS.sm) && isSourced) return 0;
|
|
28
24
|
return theme.spacing(0, 1, 0, 1);
|
|
29
25
|
}
|
|
@@ -34,7 +30,6 @@ var useStyles = makeStyles(function (theme) {
|
|
|
34
30
|
typo: {
|
|
35
31
|
fontSize: function fontSize(_ref2) {
|
|
36
32
|
var isWidthUp = _ref2.isWidthUp;
|
|
37
|
-
|
|
38
33
|
if (isWidthUp(T4_BREAKPOINTS.lg)) return 14;
|
|
39
34
|
return 12;
|
|
40
35
|
}
|
|
@@ -51,7 +46,6 @@ var DataFooter = function DataFooter(_ref3) {
|
|
|
51
46
|
source = _ref3.source,
|
|
52
47
|
copyright = _ref3.copyright,
|
|
53
48
|
legend = _ref3.legend;
|
|
54
|
-
|
|
55
49
|
var target = React.useRef(null);
|
|
56
50
|
|
|
57
51
|
var _useSize = useSize(target),
|
|
@@ -60,115 +54,74 @@ var DataFooter = function DataFooter(_ref3) {
|
|
|
60
54
|
var isWidthUp = R.gt(width);
|
|
61
55
|
var isSourced = source && source.label && source.link;
|
|
62
56
|
var isCopyrighted = copyright && copyright.label && copyright.content;
|
|
63
|
-
var classes = useStyles({
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
return React.createElement(
|
|
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
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
)
|
|
132
|
-
),
|
|
133
|
-
isWidthUp(T4_BREAKPOINTS.sm) && isSourced && React.createElement(
|
|
134
|
-
Grid,
|
|
135
|
-
{ item: true, className: classes.source },
|
|
136
|
-
React.createElement(
|
|
137
|
-
Typography,
|
|
138
|
-
{ variant: 'body2', className: classes.typo },
|
|
139
|
-
React.createElement(
|
|
140
|
-
Link,
|
|
141
|
-
{
|
|
142
|
-
href: source.link,
|
|
143
|
-
rel: 'noopener noreferrer',
|
|
144
|
-
target: '_blank',
|
|
145
|
-
variant: 'body2'
|
|
146
|
-
},
|
|
147
|
-
source.label
|
|
148
|
-
)
|
|
149
|
-
)
|
|
150
|
-
),
|
|
151
|
-
isWidthUp(T4_BREAKPOINTS.xs) && logo && React.createElement(
|
|
152
|
-
Grid,
|
|
153
|
-
{ item: true },
|
|
154
|
-
React.createElement('img', { src: logo, alt: 'logo', className: classes.logo })
|
|
155
|
-
)
|
|
156
|
-
)
|
|
157
|
-
)
|
|
158
|
-
);
|
|
57
|
+
var classes = useStyles({
|
|
58
|
+
isWidthUp: isWidthUp,
|
|
59
|
+
isSourced: isSourced
|
|
60
|
+
});
|
|
61
|
+
if (!isWidthUp(T4_BREAKPOINTS.xs)) return /*#__PURE__*/React.createElement(Grid, {
|
|
62
|
+
ref: target
|
|
63
|
+
});
|
|
64
|
+
return /*#__PURE__*/React.createElement(Grid, {
|
|
65
|
+
ref: target,
|
|
66
|
+
container: true,
|
|
67
|
+
className: classes.footer,
|
|
68
|
+
direction: "row",
|
|
69
|
+
justifyContent: "flex-end",
|
|
70
|
+
alignItems: "center"
|
|
71
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
72
|
+
item: true,
|
|
73
|
+
className: classes.legend
|
|
74
|
+
}, isWidthUp(T4_BREAKPOINTS.sm) && legend), /*#__PURE__*/React.createElement(Grid, {
|
|
75
|
+
item: true,
|
|
76
|
+
style: {
|
|
77
|
+
alignSelf: 'flex-end'
|
|
78
|
+
}
|
|
79
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
80
|
+
container: true,
|
|
81
|
+
justifyContent: "flex-end",
|
|
82
|
+
alignItems: "center",
|
|
83
|
+
className: classes.footer,
|
|
84
|
+
spacing: 0
|
|
85
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
86
|
+
item: true,
|
|
87
|
+
className: classes.copyright
|
|
88
|
+
}, isCopyrighted && /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(Tooltip, {
|
|
89
|
+
title: /*#__PURE__*/React.createElement(Typography, {
|
|
90
|
+
variant: "body2"
|
|
91
|
+
}, copyright.content),
|
|
92
|
+
variant: "light",
|
|
93
|
+
tabIndex: 0,
|
|
94
|
+
"aria-hidden": false,
|
|
95
|
+
placement: "top",
|
|
96
|
+
enterNextDelay: 100,
|
|
97
|
+
interactive: true,
|
|
98
|
+
arrow: true
|
|
99
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
100
|
+
variant: "body2",
|
|
101
|
+
className: classes.typo,
|
|
102
|
+
style: {
|
|
103
|
+
cursor: 'pointer'
|
|
104
|
+
}
|
|
105
|
+
}, copyright.label)), /*#__PURE__*/React.createElement(Typography, {
|
|
106
|
+
variant: "srOnly"
|
|
107
|
+
}, copyright.content))), isWidthUp(T4_BREAKPOINTS.sm) && isSourced && /*#__PURE__*/React.createElement(Grid, {
|
|
108
|
+
item: true,
|
|
109
|
+
className: classes.source
|
|
110
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
111
|
+
variant: "body2",
|
|
112
|
+
className: classes.typo
|
|
113
|
+
}, /*#__PURE__*/React.createElement(Link, {
|
|
114
|
+
href: source.link,
|
|
115
|
+
rel: "noopener noreferrer",
|
|
116
|
+
target: "_blank",
|
|
117
|
+
variant: "body2"
|
|
118
|
+
}, source.label))), isWidthUp(T4_BREAKPOINTS.xs) && logo && /*#__PURE__*/React.createElement(Grid, {
|
|
119
|
+
item: true
|
|
120
|
+
}, /*#__PURE__*/React.createElement("img", {
|
|
121
|
+
src: logo,
|
|
122
|
+
alt: "logo",
|
|
123
|
+
className: classes.logo
|
|
124
|
+
})))));
|
|
159
125
|
};
|
|
160
126
|
|
|
161
|
-
DataFooter.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
162
|
-
logo: PropTypes.string,
|
|
163
|
-
source: PropTypes.shape({
|
|
164
|
-
label: PropTypes.oneOfType([PropTypes.string, PropTypes.element]),
|
|
165
|
-
link: PropTypes.string
|
|
166
|
-
}),
|
|
167
|
-
copyright: PropTypes.shape({
|
|
168
|
-
label: PropTypes.oneOfType([PropTypes.string, PropTypes.element]),
|
|
169
|
-
content: PropTypes.oneOfType([PropTypes.string, PropTypes.element])
|
|
170
|
-
}),
|
|
171
|
-
legend: PropTypes.element
|
|
172
|
-
} : {};
|
|
173
|
-
|
|
174
127
|
export default DataFooter;
|