sag_components 1.0.316 → 1.0.317
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.
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "sag_components",
|
|
3
|
+
"version": "1.0.317",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"start": "react-scripts start",
|
|
8
|
+
"lint": "eslint .",
|
|
9
|
+
"build": "cross-env BABEL_ENV=production babel src -d dist ",
|
|
10
|
+
"storybook": "storybook dev -p 6006",
|
|
11
|
+
"build-storybook": "storybook build"
|
|
12
|
+
},
|
|
13
|
+
"keywords": [],
|
|
14
|
+
"author": "SAG",
|
|
15
|
+
"license": "ISC",
|
|
16
|
+
"devDependencies": {
|
|
17
|
+
"@babel/cli": "^7.23.0",
|
|
18
|
+
"@babel/preset-env": "^7.23.3",
|
|
19
|
+
"@babel/preset-react": "^7.23.3",
|
|
20
|
+
"@babel/preset-typescript": "^7.23.3",
|
|
21
|
+
"@storybook/addon-a11y": "^7.4.6",
|
|
22
|
+
"@storybook/addon-essentials": "^7.4.6",
|
|
23
|
+
"@storybook/addon-interactions": "^7.4.6",
|
|
24
|
+
"@storybook/addon-links": "^7.4.6",
|
|
25
|
+
"@storybook/addon-storysource": "^7.4.6",
|
|
26
|
+
"@storybook/blocks": "^7.4.6",
|
|
27
|
+
"@storybook/preset-scss": "^1.0.3",
|
|
28
|
+
"@storybook/react": "^7.4.6",
|
|
29
|
+
"@storybook/react-webpack5": "^7.4.6",
|
|
30
|
+
"@storybook/testing-library": "^0.2.2",
|
|
31
|
+
"cross-env": "^7.0.3",
|
|
32
|
+
"css-loader": "^6.8.1",
|
|
33
|
+
"eslint": "^8.53.0",
|
|
34
|
+
"eslint-config-airbnb": "^19.0.4",
|
|
35
|
+
"eslint-plugin-import": "^2.29.0",
|
|
36
|
+
"eslint-plugin-jsx-a11y": "^6.8.0",
|
|
37
|
+
"eslint-plugin-react": "^7.33.2",
|
|
38
|
+
"eslint-plugin-react-hooks": "^4.6.0",
|
|
39
|
+
"react-dom": "^18.2.0",
|
|
40
|
+
"sass": "^1.69.5",
|
|
41
|
+
"sass-loader": "^13.3.2",
|
|
42
|
+
"style-loader": "^3.3.3"
|
|
43
|
+
},
|
|
44
|
+
"dependencies": {
|
|
45
|
+
"@dnd-kit/core": "^6.0.8",
|
|
46
|
+
"@emotion/react": "^11.11.1",
|
|
47
|
+
"@emotion/styled": "^11.11.0",
|
|
48
|
+
"@fontsource/roboto": "^5.0.8",
|
|
49
|
+
"@fortawesome/fontawesome-svg-core": "^6.4.2",
|
|
50
|
+
"@fortawesome/free-solid-svg-icons": "^6.4.2",
|
|
51
|
+
"@fortawesome/react-fontawesome": "^0.2.0",
|
|
52
|
+
"@mui/icons-material": "^5.14.16",
|
|
53
|
+
"@mui/material": "^5.14.17",
|
|
54
|
+
"@mui/styled-engine-sc": "^5.14.12",
|
|
55
|
+
"@mui/x-date-pickers": "^6.18.1",
|
|
56
|
+
"@storybook/addon-designs": "^7.0.5",
|
|
57
|
+
"babel-plugin-react-css-modules": "^5.2.6",
|
|
58
|
+
"classnames": "^2.3.2",
|
|
59
|
+
"dayjs": "^1.11.10",
|
|
60
|
+
"hoopy": "^0.1.4",
|
|
61
|
+
"prop-types": "^15.8.1",
|
|
62
|
+
"react": "^18.2.0",
|
|
63
|
+
"react-css-modules": "^4.7.11",
|
|
64
|
+
"react-loading-skeleton": "^3.3.1",
|
|
65
|
+
"react-scripts": "5.0.1",
|
|
66
|
+
"recharts": "^2.9.3",
|
|
67
|
+
"storybook": "^7.4.6",
|
|
68
|
+
"styled-components": "^5.3.1"
|
|
69
|
+
},
|
|
70
|
+
"browserslist": {
|
|
71
|
+
"production": [
|
|
72
|
+
">0.2%",
|
|
73
|
+
"not dead",
|
|
74
|
+
"not op_mini all"
|
|
75
|
+
],
|
|
76
|
+
"development": [
|
|
77
|
+
"last 1 chrome version",
|
|
78
|
+
"last 1 firefox version",
|
|
79
|
+
"last 1 safari version"
|
|
80
|
+
]
|
|
81
|
+
}
|
|
82
|
+
}
|
|
@@ -10,30 +10,30 @@ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/
|
|
|
10
10
|
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/slicedToArray"));
|
|
11
11
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectWithoutProperties"));
|
|
12
12
|
var _react = _interopRequireWildcard(require("react"));
|
|
13
|
-
var _CheckBoxButton = require("./CheckBoxButton
|
|
14
|
-
var
|
|
13
|
+
var _CheckBoxButton = require("./CheckBoxButton");
|
|
14
|
+
var _ListBox = require("./ListBox.style");
|
|
15
15
|
var _excluded = ["data", "width", "height", "borderColor", "buttonsIconColor", "buttonsBorderColor", "buttonsTextColorChecked", "buttonsTextColorUnchecked", "buttonsBackgroundColorChecked", "buttonsBackgroundColorUnchecked", "onClick"];
|
|
16
|
-
/*ListBox*/
|
|
16
|
+
/* ListBox */
|
|
17
17
|
var ListBox = exports.ListBox = function ListBox(_ref) {
|
|
18
18
|
var data = _ref.data,
|
|
19
19
|
_ref$width = _ref.width,
|
|
20
|
-
width = _ref$width === void 0 ?
|
|
20
|
+
width = _ref$width === void 0 ? '100%' : _ref$width,
|
|
21
21
|
_ref$height = _ref.height,
|
|
22
|
-
height = _ref$height === void 0 ?
|
|
22
|
+
height = _ref$height === void 0 ? '100%' : _ref$height,
|
|
23
23
|
_ref$borderColor = _ref.borderColor,
|
|
24
|
-
borderColor = _ref$borderColor === void 0 ?
|
|
24
|
+
borderColor = _ref$borderColor === void 0 ? '#B1B1B1' : _ref$borderColor,
|
|
25
25
|
_ref$buttonsIconColor = _ref.buttonsIconColor,
|
|
26
|
-
buttonsIconColor = _ref$buttonsIconColor === void 0 ?
|
|
26
|
+
buttonsIconColor = _ref$buttonsIconColor === void 0 ? '#1B30AA' : _ref$buttonsIconColor,
|
|
27
27
|
_ref$buttonsBorderCol = _ref.buttonsBorderColor,
|
|
28
|
-
buttonsBorderColor = _ref$buttonsBorderCol === void 0 ?
|
|
28
|
+
buttonsBorderColor = _ref$buttonsBorderCol === void 0 ? '#1B30AA' : _ref$buttonsBorderCol,
|
|
29
29
|
_ref$buttonsTextColor = _ref.buttonsTextColorChecked,
|
|
30
|
-
buttonsTextColorChecked = _ref$buttonsTextColor === void 0 ?
|
|
30
|
+
buttonsTextColorChecked = _ref$buttonsTextColor === void 0 ? '#212121' : _ref$buttonsTextColor,
|
|
31
31
|
_ref$buttonsTextColor2 = _ref.buttonsTextColorUnchecked,
|
|
32
|
-
buttonsTextColorUnchecked = _ref$buttonsTextColor2 === void 0 ?
|
|
32
|
+
buttonsTextColorUnchecked = _ref$buttonsTextColor2 === void 0 ? '#212121' : _ref$buttonsTextColor2,
|
|
33
33
|
_ref$buttonsBackgroun = _ref.buttonsBackgroundColorChecked,
|
|
34
|
-
buttonsBackgroundColorChecked = _ref$buttonsBackgroun === void 0 ?
|
|
34
|
+
buttonsBackgroundColorChecked = _ref$buttonsBackgroun === void 0 ? '#1B30AA' : _ref$buttonsBackgroun,
|
|
35
35
|
_ref$buttonsBackgroun2 = _ref.buttonsBackgroundColorUnchecked,
|
|
36
|
-
buttonsBackgroundColorUnchecked = _ref$buttonsBackgroun2 === void 0 ?
|
|
36
|
+
buttonsBackgroundColorUnchecked = _ref$buttonsBackgroun2 === void 0 ? '#FFF' : _ref$buttonsBackgroun2,
|
|
37
37
|
onClick = _ref.onClick,
|
|
38
38
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
39
39
|
var _useState = (0, _react.useState)(data),
|
|
@@ -50,14 +50,14 @@ var ListBox = exports.ListBox = function ListBox(_ref) {
|
|
|
50
50
|
});
|
|
51
51
|
}, [dataState]);
|
|
52
52
|
var dispalyButtons = function dispalyButtons(data, height) {
|
|
53
|
-
var paddingBottom = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] :
|
|
53
|
+
var paddingBottom = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '5px';
|
|
54
54
|
if (data && data.length > 0) {
|
|
55
|
-
return /*#__PURE__*/_react.default.createElement(
|
|
55
|
+
return /*#__PURE__*/_react.default.createElement(_ListBox.ButtonsContainer, {
|
|
56
56
|
id: "ButtonsContainer",
|
|
57
57
|
height: height,
|
|
58
58
|
paddingBottom: paddingBottom
|
|
59
59
|
}, data === null || data === void 0 ? void 0 : data.map(function (item) {
|
|
60
|
-
return /*#__PURE__*/_react.default.createElement(
|
|
60
|
+
return /*#__PURE__*/_react.default.createElement(_ListBox.ButtonContainer, {
|
|
61
61
|
id: "ButtonContainer"
|
|
62
62
|
}, /*#__PURE__*/_react.default.createElement(_CheckBoxButton.CheckBoxButton, {
|
|
63
63
|
backgroundColorChecked: buttonsBackgroundColorChecked,
|
|
@@ -87,13 +87,13 @@ var ListBox = exports.ListBox = function ListBox(_ref) {
|
|
|
87
87
|
}));
|
|
88
88
|
}
|
|
89
89
|
};
|
|
90
|
-
return /*#__PURE__*/_react.default.createElement(
|
|
90
|
+
return /*#__PURE__*/_react.default.createElement(_ListBox.MainContainer, {
|
|
91
91
|
id: "MainContainer",
|
|
92
92
|
height: height,
|
|
93
93
|
width: width
|
|
94
|
-
}, /*#__PURE__*/_react.default.createElement(
|
|
94
|
+
}, /*#__PURE__*/_react.default.createElement(_ListBox.PanelContainer, {
|
|
95
95
|
id: "PanelContainer",
|
|
96
96
|
borderColor: borderColor
|
|
97
|
-
}, dispalyButtons(dataState, height =
|
|
97
|
+
}, dispalyButtons(dataState, height = '50px', '0')));
|
|
98
98
|
};
|
|
99
99
|
var _default = exports.default = ListBox;
|