tenjin-ui-kit 0.3.70 → 0.3.72-dev
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/common/hooks/apiHooks.js +155 -0
- package/common/hooks/newApiHook.js +188 -0
- package/{dist/common → common}/utils/security/index.js +2 -2
- package/{dist/common → common}/utils/security/securityConfig.js +1 -2
- package/components/Canvas.js +330 -0
- package/components/DragBox/index.js +40 -0
- package/components/InputWithChip/index.js +294 -0
- package/{dist/components → components}/RightContext/index.js +19 -28
- package/components/WorkFlow.js +42 -0
- package/components/WorkFlowBuilder.js +115 -0
- package/components/alert/Style.js +20 -0
- package/components/alert/index.js +67 -0
- package/{dist/components → components}/attachment/index.js +21 -28
- package/{dist/components → components}/authenticationProvider/AuthError.js +3 -4
- package/{dist/components → components}/authenticationProvider/AuthLoader.js +3 -4
- package/components/authenticationProvider/index.js +110 -0
- package/{dist/components → components}/avatar/index.js +13 -14
- package/components/avatar/styles.js +91 -0
- package/components/breadCrumbs/index.js +169 -0
- package/{dist/components → components}/breadCrumbs/style.js +1 -4
- package/{dist/components → components}/browsingTestCaseLayout/DetailsViewLayout/DetailsViewContent/index.js +5 -6
- package/{dist/components → components}/browsingTestCaseLayout/DetailsViewLayout/DetailsViewContent/style.js +5 -8
- package/{dist/components → components}/browsingTestCaseLayout/DetailsViewLayout/DetailsViewHeader/index.js +4 -5
- package/{dist/components → components}/browsingTestCaseLayout/TreeViewLayout/TreeViewContent/Index.js +4 -5
- package/{dist/components → components}/browsingTestCaseLayout/TreeViewLayout/TreeViewHeader/Index.js +5 -6
- package/components/browsingTestCaseLayout/TreeViewLayout/TreeViewHeader/style.js +23 -0
- package/{dist/components → components}/browsingTestCaseLayout/index.js +25 -30
- package/components/button/index.js +133 -0
- package/{dist/components → components}/chatBotModal/index.js +36 -45
- package/components/checkBox/index.js +29 -0
- package/{dist/components → components}/combobox/index.js +51 -72
- package/components/divider/index.js +37 -0
- package/{dist/components → components}/editableField/index.js +19 -28
- package/{dist/components → components}/error/index.js +6 -12
- package/components/errorBoundary/index.js +140 -0
- package/components/fileUploader/index.js +151 -0
- package/components/fileUploader/style.js +57 -0
- package/components/filter/ValueSelector.js +333 -0
- package/{dist/components → components}/filter/index.js +26 -33
- package/{dist/components → components}/iconButton/index.js +3 -4
- package/components/input/index.js +167 -0
- package/components/layout/index.js +94 -0
- package/components/layout/main/index.js +24 -0
- package/components/layout/main/style.js +19 -0
- package/{dist/components → components}/layout/pageContent/index.js +6 -7
- package/components/layout/sidebar/FlatMenu.js +64 -0
- package/components/layout/sidebar/GroupedIconMenu.js +233 -0
- package/components/layout/sidebar/GroupedMenu.js +57 -0
- package/components/layout/sidebar/ProjectMenu.js +223 -0
- package/components/layout/sidebar/index.js +88 -0
- package/components/layout/sidebar/style.js +149 -0
- package/components/layout/topBar/ProjectTopbar.js +388 -0
- package/components/layout/topBar/UserAvatar.js +138 -0
- package/components/layout/topBar/index.js +121 -0
- package/{dist/components → components}/loader/index.js +9 -12
- package/components/menu/index.js +71 -0
- package/{dist/components → components}/modal/Modal.js +5 -6
- package/components/modal/index.js +88 -0
- package/components/modal/style.js +65 -0
- package/components/optionMenu/index.js +105 -0
- package/components/pagination/index.js +114 -0
- package/components/pagination/style.js +33 -0
- package/components/paginationUpdated/index.js +74 -0
- package/components/paper/index.js +43 -0
- package/components/paper/style.js +31 -0
- package/components/reactSelect/index.js +195 -0
- package/components/reactSelect/style.js +130 -0
- package/components/richTextEditor/index.js +64 -0
- package/components/select/GroupedSelect.js +167 -0
- package/components/select/SimpleSelect.js +184 -0
- package/{dist/components → components}/select/index.js +38 -54
- package/components/simpleSelect/index.js +53 -0
- package/{dist/components → components}/sort/index.js +19 -22
- package/{dist/components → components}/switch/index.js +10 -11
- package/components/switch/style.js +39 -0
- package/{dist/components → components}/switch/switch.js +17 -23
- package/components/table/ReactTable.js +101 -0
- package/components/table/SimpleTable.js +117 -0
- package/components/table/index.js +381 -0
- package/components/text/index.js +65 -0
- package/{dist/components → components}/timeStamp/index.js +4 -6
- package/components/timeStamp/style.js +20 -0
- package/components/topBar/index.js +169 -0
- package/{dist/components → components}/tree/index.js +29 -47
- package/components/tree/style.js +29 -0
- package/components/valuePicker/ValueSelector.js +205 -0
- package/{dist/components → components}/valuePicker/index.js +19 -26
- package/{dist/components → components}/wrapperLayout/layout/index.js +4 -5
- package/{dist/components → components}/wrapperLayout/main/index.js +4 -5
- package/{dist/components → components}/wrapperLayout/main/pageContainer/index.js +4 -5
- package/components/wrapperLayout/main/sideBar/index.js +272 -0
- package/components/wrapperLayout/main/sideBar/style.js +190 -0
- package/{dist/components → components}/wrapperLayout/topBar/UserAvatar.js +4 -5
- package/components/wrapperLayout/topBar/avatar.js +55 -0
- package/components/wrapperLayout/topBar/index.js +196 -0
- package/{dist/components → components}/wrapperLayout/topBar/menuIcon.js +4 -5
- package/components/wrapperLayout/topBar/style.js +74 -0
- package/http/index.js +133 -0
- package/{dist/index.js → index.js} +53 -55
- package/package.json +5 -3
- package/{dist/templates → templates}/listPage/index.js +36 -57
- package/{dist/themes → themes}/default.js +5 -7
- package/{dist/themes → themes}/defaultSmall.js +2 -3
- package/{dist/themes → themes}/responsiveTheme.js +6 -8
- package/.dockerignore +0 -6
- package/.storybook/main.js +0 -16
- package/.storybook/preview.js +0 -11
- package/Dockerfile +0 -17
- package/Jenkinsfile +0 -66
- package/build/asset-manifest.json +0 -16
- package/build/favicon.ico +0 -0
- package/build/index.html +0 -1
- package/build/logo192.png +0 -0
- package/build/logo512.png +0 -0
- package/build/manifest.json +0 -25
- package/build/robots.txt +0 -3
- package/build/static/css/main.522396f6.css +0 -2
- package/build/static/css/main.522396f6.css.map +0 -1
- package/build/static/js/787.18cf14d0.chunk.js +0 -2
- package/build/static/js/787.18cf14d0.chunk.js.map +0 -1
- package/build/static/js/main.d71fecac.js +0 -3
- package/build/static/js/main.d71fecac.js.LICENSE.txt +0 -50
- package/build/static/js/main.d71fecac.js.map +0 -1
- package/build/static/media/logo.6ce24c58023cc2f8fd88fe9d219db6c6.svg +0 -1
- package/build/tenjinLogo.png +0 -0
- package/dist/common/hooks/apiHooks.js +0 -223
- package/dist/common/hooks/newApiHook.js +0 -270
- package/dist/components/Canvas.js +0 -254
- package/dist/components/DragBox/index.js +0 -45
- package/dist/components/InputWithChip/index.js +0 -187
- package/dist/components/WorkFlow.js +0 -47
- package/dist/components/WorkFlowBuilder.js +0 -130
- package/dist/components/alert/Style.js +0 -23
- package/dist/components/alert/index.js +0 -69
- package/dist/components/authenticationProvider/index.js +0 -166
- package/dist/components/avatar/styles.js +0 -94
- package/dist/components/breadCrumbs/index.js +0 -180
- package/dist/components/browsingTestCaseLayout/TreeViewLayout/TreeViewHeader/style.js +0 -26
- package/dist/components/button/index.js +0 -140
- package/dist/components/checkBox/index.js +0 -30
- package/dist/components/divider/index.js +0 -41
- package/dist/components/errorBoundary/index.js +0 -160
- package/dist/components/fileUploader/index.js +0 -156
- package/dist/components/fileUploader/style.js +0 -60
- package/dist/components/filter/ValueSelector.js +0 -405
- package/dist/components/input/index.js +0 -174
- package/dist/components/layout/index.js +0 -98
- package/dist/components/layout/main/index.js +0 -27
- package/dist/components/layout/main/style.js +0 -22
- package/dist/components/layout/sidebar/FlatMenu.js +0 -64
- package/dist/components/layout/sidebar/GroupedIconMenu.js +0 -246
- package/dist/components/layout/sidebar/GroupedMenu.js +0 -67
- package/dist/components/layout/sidebar/ProjectMenu.js +0 -230
- package/dist/components/layout/sidebar/index.js +0 -91
- package/dist/components/layout/sidebar/style.js +0 -154
- package/dist/components/layout/topBar/ProjectTopbar.js +0 -338
- package/dist/components/layout/topBar/UserAvatar.js +0 -145
- package/dist/components/layout/topBar/index.js +0 -132
- package/dist/components/menu/index.js +0 -80
- package/dist/components/modal/index.js +0 -91
- package/dist/components/modal/style.js +0 -68
- package/dist/components/optionMenu/index.js +0 -112
- package/dist/components/pagination/index.js +0 -129
- package/dist/components/pagination/style.js +0 -36
- package/dist/components/paginationUpdated/index.js +0 -75
- package/dist/components/paper/index.js +0 -44
- package/dist/components/paper/style.js +0 -34
- package/dist/components/reactSelect/index.js +0 -212
- package/dist/components/reactSelect/style.js +0 -163
- package/dist/components/richTextEditor/index.js +0 -83
- package/dist/components/select/GroupedSelect.js +0 -183
- package/dist/components/select/SimpleSelect.js +0 -212
- package/dist/components/simpleSelect/index.js +0 -56
- package/dist/components/switch/style.js +0 -42
- package/dist/components/table/ReactTable.js +0 -118
- package/dist/components/table/SimpleTable.js +0 -136
- package/dist/components/table/index.js +0 -256
- package/dist/components/text/index.js +0 -67
- package/dist/components/timeStamp/style.js +0 -23
- package/dist/components/topBar/index.js +0 -176
- package/dist/components/tree/style.js +0 -32
- package/dist/components/valuePicker/ValueSelector.js +0 -273
- package/dist/components/wrapperLayout/main/sideBar/index.js +0 -262
- package/dist/components/wrapperLayout/main/sideBar/style.js +0 -196
- package/dist/components/wrapperLayout/topBar/avatar.js +0 -57
- package/dist/components/wrapperLayout/topBar/index.js +0 -182
- package/dist/components/wrapperLayout/topBar/style.js +0 -77
- package/dist/http/index.js +0 -226
- package/public/favicon.ico +0 -0
- package/public/index.html +0 -43
- package/public/logo192.png +0 -0
- package/public/logo512.png +0 -0
- package/public/manifest.json +0 -25
- package/public/robots.txt +0 -3
- package/public/tenjinLogo.png +0 -0
- /package/{dist/assets → assets}/images/MicrosoftTeams-image (1).png +0 -0
- /package/{dist/assets → assets}/images/tenjin-4.0-logo.png +0 -0
- /package/{dist/components → components}/RightContext/index.css +0 -0
- /package/{dist/components → components}/browsingTestCaseLayout/style.css +0 -0
- /package/{dist/components → components}/errorBoundary/Error.jpg +0 -0
- /package/{dist/components → components}/iconButton/style.js +0 -0
- /package/{dist/components → components}/richTextEditor/style.js +0 -0
- /package/{dist/components → components}/wrapperLayout/layout/style.js +0 -0
|
@@ -9,29 +9,25 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
9
9
|
var _material = require("@mui/material");
|
|
10
10
|
var _styles = require("@mui/material/styles");
|
|
11
11
|
var _KeyboardArrowDown = _interopRequireDefault(require("@mui/icons-material/KeyboardArrowDown"));
|
|
12
|
-
function _interopRequireDefault(
|
|
13
|
-
function
|
|
14
|
-
function
|
|
15
|
-
function
|
|
16
|
-
function
|
|
17
|
-
function
|
|
18
|
-
function
|
|
19
|
-
function
|
|
20
|
-
function
|
|
21
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
22
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
14
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
15
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
16
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
17
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
18
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
19
|
+
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
20
|
+
function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
|
|
23
21
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
24
|
-
function _unsupportedIterableToArray(
|
|
25
|
-
function _arrayLikeToArray(
|
|
26
|
-
function _iterableToArrayLimit(
|
|
27
|
-
function _arrayWithHoles(
|
|
22
|
+
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
23
|
+
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
24
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
25
|
+
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
28
26
|
// Styled components to match the Tailwind design
|
|
29
|
-
|
|
30
|
-
shouldForwardProp:
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
})(function (_ref) {
|
|
34
|
-
var theme = _ref.theme,
|
|
27
|
+
const StyledTextField = (0, _styles.styled)(_material.TextField, {
|
|
28
|
+
shouldForwardProp: prop => prop !== "error" && prop !== "loading"
|
|
29
|
+
})(_ref => {
|
|
30
|
+
let theme = _ref.theme,
|
|
35
31
|
error = _ref.error,
|
|
36
32
|
loading = _ref.loading;
|
|
37
33
|
return {
|
|
@@ -70,8 +66,8 @@ var StyledTextField = (0, _styles.styled)(_material.TextField, {
|
|
|
70
66
|
}
|
|
71
67
|
};
|
|
72
68
|
});
|
|
73
|
-
|
|
74
|
-
|
|
69
|
+
const StyledPaper = (0, _styles.styled)(_material.Paper)(_ref2 => {
|
|
70
|
+
let theme = _ref2.theme;
|
|
75
71
|
return {
|
|
76
72
|
marginTop: "4px",
|
|
77
73
|
maxHeight: "240px",
|
|
@@ -105,12 +101,10 @@ var StyledPaper = (0, _styles.styled)(_material.Paper)(function (_ref2) {
|
|
|
105
101
|
}
|
|
106
102
|
};
|
|
107
103
|
});
|
|
108
|
-
|
|
109
|
-
shouldForwardProp:
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
})(function (_ref3) {
|
|
113
|
-
var isRequired = _ref3.isRequired;
|
|
104
|
+
const Label = (0, _styles.styled)(_material.Typography, {
|
|
105
|
+
shouldForwardProp: prop => prop !== "isRequired"
|
|
106
|
+
})(_ref3 => {
|
|
107
|
+
let isRequired = _ref3.isRequired;
|
|
114
108
|
return {
|
|
115
109
|
display: "block",
|
|
116
110
|
fontSize: "0.875rem",
|
|
@@ -125,12 +119,10 @@ var Label = (0, _styles.styled)(_material.Typography, {
|
|
|
125
119
|
} : {}
|
|
126
120
|
};
|
|
127
121
|
});
|
|
128
|
-
|
|
129
|
-
shouldForwardProp:
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
})(function (_ref4) {
|
|
133
|
-
var error = _ref4.error;
|
|
122
|
+
const HelperText = (0, _styles.styled)(_material.Typography, {
|
|
123
|
+
shouldForwardProp: prop => prop !== "error"
|
|
124
|
+
})(_ref4 => {
|
|
125
|
+
let error = _ref4.error;
|
|
134
126
|
return {
|
|
135
127
|
marginTop: "8px",
|
|
136
128
|
fontSize: "0.875rem",
|
|
@@ -138,8 +130,8 @@ var HelperText = (0, _styles.styled)(_material.Typography, {
|
|
|
138
130
|
color: error ? "#dc2626" : "#4b5563"
|
|
139
131
|
};
|
|
140
132
|
});
|
|
141
|
-
|
|
142
|
-
|
|
133
|
+
const Combobox = _ref5 => {
|
|
134
|
+
let _ref5$options = _ref5.options,
|
|
143
135
|
options = _ref5$options === void 0 ? [] : _ref5$options,
|
|
144
136
|
selected = _ref5.selected,
|
|
145
137
|
defaultValue = _ref5.defaultValue,
|
|
@@ -155,31 +147,29 @@ var Combobox = function Combobox(_ref5) {
|
|
|
155
147
|
by = _ref5$by === void 0 ? "id" : _ref5$by,
|
|
156
148
|
_ref5$labelKey = _ref5.labelKey,
|
|
157
149
|
labelKey = _ref5$labelKey === void 0 ? "label" : _ref5$labelKey;
|
|
158
|
-
|
|
150
|
+
const _useState = (0, _react.useState)(null),
|
|
159
151
|
_useState2 = _slicedToArray(_useState, 2),
|
|
160
152
|
internalSelected = _useState2[0],
|
|
161
153
|
setInternalSelected = _useState2[1];
|
|
162
|
-
|
|
154
|
+
const _useState3 = (0, _react.useState)(false),
|
|
163
155
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
164
156
|
hasSetDefault = _useState4[0],
|
|
165
157
|
setHasSetDefault = _useState4[1];
|
|
166
|
-
|
|
158
|
+
const _useState5 = (0, _react.useState)(false),
|
|
167
159
|
_useState6 = _slicedToArray(_useState5, 2),
|
|
168
160
|
open = _useState6[0],
|
|
169
161
|
setOpen = _useState6[1];
|
|
170
162
|
|
|
171
163
|
// Handle defaultValue - accepts both object and primitive (ID)
|
|
172
|
-
(0, _react.useEffect)(
|
|
164
|
+
(0, _react.useEffect)(() => {
|
|
173
165
|
if (defaultValue && options.length > 0 && !hasSetDefault) {
|
|
174
|
-
|
|
175
|
-
if (
|
|
166
|
+
let defaultOption;
|
|
167
|
+
if (typeof defaultValue === "object" && defaultValue !== null) {
|
|
176
168
|
// defaultValue is already a full object
|
|
177
169
|
defaultOption = defaultValue;
|
|
178
170
|
} else {
|
|
179
171
|
// defaultValue is a primitive (ID), find the matching option
|
|
180
|
-
defaultOption = options.find(
|
|
181
|
-
return opt[by] === defaultValue;
|
|
182
|
-
});
|
|
172
|
+
defaultOption = options.find(opt => opt[by] === defaultValue);
|
|
183
173
|
}
|
|
184
174
|
if (defaultOption) {
|
|
185
175
|
setInternalSelected(defaultOption);
|
|
@@ -189,8 +179,8 @@ var Combobox = function Combobox(_ref5) {
|
|
|
189
179
|
}, [defaultValue, options, by, hasSetDefault]);
|
|
190
180
|
|
|
191
181
|
// Use selected prop if provided, otherwise use internal state
|
|
192
|
-
|
|
193
|
-
|
|
182
|
+
const currentValue = selected || internalSelected;
|
|
183
|
+
const handleChange = (event, value) => {
|
|
194
184
|
setInternalSelected(value);
|
|
195
185
|
if (onChange) {
|
|
196
186
|
// Pass the full object to onChange (industry standard)
|
|
@@ -209,21 +199,13 @@ var Combobox = function Combobox(_ref5) {
|
|
|
209
199
|
value: currentValue,
|
|
210
200
|
onChange: handleChange,
|
|
211
201
|
options: options,
|
|
212
|
-
getOptionLabel:
|
|
213
|
-
|
|
214
|
-
},
|
|
215
|
-
isOptionEqualToValue: function isOptionEqualToValue(option, value) {
|
|
216
|
-
return (option === null || option === void 0 ? void 0 : option[by]) === (value === null || value === void 0 ? void 0 : value[by]);
|
|
217
|
-
},
|
|
202
|
+
getOptionLabel: option => (option === null || option === void 0 ? void 0 : option[labelKey]) || "",
|
|
203
|
+
isOptionEqualToValue: (option, value) => (option === null || option === void 0 ? void 0 : option[by]) === (value === null || value === void 0 ? void 0 : value[by]),
|
|
218
204
|
loading: loading,
|
|
219
205
|
disabled: loading,
|
|
220
206
|
open: open && !loading,
|
|
221
|
-
onOpen:
|
|
222
|
-
|
|
223
|
-
},
|
|
224
|
-
onClose: function onClose() {
|
|
225
|
-
return setOpen(false);
|
|
226
|
-
},
|
|
207
|
+
onOpen: () => setOpen(true),
|
|
208
|
+
onClose: () => setOpen(false),
|
|
227
209
|
disableClearable: false,
|
|
228
210
|
PaperComponent: StyledPaper,
|
|
229
211
|
popupIcon: loading ? /*#__PURE__*/_react.default.createElement(_material.CircularProgress, {
|
|
@@ -237,16 +219,14 @@ var Combobox = function Combobox(_ref5) {
|
|
|
237
219
|
}
|
|
238
220
|
}),
|
|
239
221
|
noOptionsText: "No results found",
|
|
240
|
-
renderInput:
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
}));
|
|
249
|
-
}
|
|
222
|
+
renderInput: params => /*#__PURE__*/_react.default.createElement(StyledTextField, _extends({}, params, {
|
|
223
|
+
error: error,
|
|
224
|
+
loading: loading,
|
|
225
|
+
placeholder: loading ? "Loading..." : "",
|
|
226
|
+
InputProps: _objectSpread(_objectSpread({}, params.InputProps), {}, {
|
|
227
|
+
endAdornment: /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, params.InputProps.endAdornment)
|
|
228
|
+
})
|
|
229
|
+
}))
|
|
250
230
|
}), helperText && /*#__PURE__*/_react.default.createElement(HelperText, {
|
|
251
231
|
error: error
|
|
252
232
|
}, helperText));
|
|
@@ -407,5 +387,4 @@ Combobox.defaultProps = {
|
|
|
407
387
|
by: "id",
|
|
408
388
|
labelKey: "label"
|
|
409
389
|
};
|
|
410
|
-
var _default = Combobox;
|
|
411
|
-
exports.default = _default;
|
|
390
|
+
var _default = exports.default = Combobox;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = Divider;
|
|
7
|
+
var React = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _styles = require("@mui/material/styles");
|
|
9
|
+
var _material = require("@mui/material");
|
|
10
|
+
var _Chip = _interopRequireDefault(require("@mui/material/Chip"));
|
|
11
|
+
var _text = _interopRequireDefault(require("../text"));
|
|
12
|
+
var _responsiveTheme = _interopRequireDefault(require("../../themes/responsiveTheme"));
|
|
13
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
14
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
15
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
16
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
17
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
18
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
19
|
+
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
20
|
+
const Root = (0, _styles.styled)("div")(() => _objectSpread(_objectSpread({
|
|
21
|
+
width: "100%"
|
|
22
|
+
}, _responsiveTheme.default.typography.body2), {}, {
|
|
23
|
+
"& > :not(style) + :not(style)": {
|
|
24
|
+
marginTop: _responsiveTheme.default.spacing(2)
|
|
25
|
+
}
|
|
26
|
+
}));
|
|
27
|
+
function Divider(props) {
|
|
28
|
+
return /*#__PURE__*/React.createElement(Root, null, props.type && props.type === "Chip" ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(_material.Divider, {
|
|
29
|
+
textAlign: props.textAlign && props.textAlign
|
|
30
|
+
}, /*#__PURE__*/React.createElement(_Chip.default, {
|
|
31
|
+
label: props.title && props.title
|
|
32
|
+
})), /*#__PURE__*/React.createElement(_text.default, null, props.children)) : props.title && props.title ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(_material.Divider, {
|
|
33
|
+
textAlign: props.textAlign && props.textAlign
|
|
34
|
+
}, /*#__PURE__*/React.createElement(_text.default, null, props.title && props.title)), props.children) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(_material.Divider, {
|
|
35
|
+
textAlign: props.textAlign && props.textAlign
|
|
36
|
+
}), props.children));
|
|
37
|
+
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
@@ -9,31 +8,30 @@ var _material = require("@mui/material");
|
|
|
9
8
|
var _react = _interopRequireWildcard(require("react"));
|
|
10
9
|
var _Edit = _interopRequireDefault(require("@mui/icons-material/Edit"));
|
|
11
10
|
var _text = _interopRequireDefault(require("../text"));
|
|
12
|
-
function _interopRequireDefault(
|
|
13
|
-
function
|
|
14
|
-
function
|
|
15
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
13
|
+
function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
|
|
16
14
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
17
|
-
function _unsupportedIterableToArray(
|
|
18
|
-
function _arrayLikeToArray(
|
|
19
|
-
function _iterableToArrayLimit(
|
|
20
|
-
function _arrayWithHoles(
|
|
15
|
+
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
16
|
+
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
17
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
18
|
+
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
21
19
|
// import Select from "../select";
|
|
22
20
|
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
const EditableField = props => {
|
|
22
|
+
const _useState = (0, _react.useState)(props.editableData || "N/A"),
|
|
25
23
|
_useState2 = _slicedToArray(_useState, 2),
|
|
26
24
|
name = _useState2[0],
|
|
27
25
|
setName = _useState2[1];
|
|
28
|
-
|
|
26
|
+
const _useState3 = (0, _react.useState)(false),
|
|
29
27
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
30
28
|
isNameFocused = _useState4[0],
|
|
31
29
|
setIsNameFocused = _useState4[1];
|
|
32
|
-
|
|
30
|
+
const _useState5 = (0, _react.useState)(false),
|
|
33
31
|
_useState6 = _slicedToArray(_useState5, 2),
|
|
34
32
|
show = _useState6[0],
|
|
35
33
|
isShow = _useState6[1];
|
|
36
|
-
|
|
34
|
+
const handleKeyDown = event => {
|
|
37
35
|
// if (name?.length > 0 || typeof name === "number") {
|
|
38
36
|
// if (event.key === "Enter") {
|
|
39
37
|
// setIsNameFocused(false);
|
|
@@ -54,7 +52,7 @@ var EditableField = function EditableField(props) {
|
|
|
54
52
|
}
|
|
55
53
|
}
|
|
56
54
|
};
|
|
57
|
-
|
|
55
|
+
const onBLurHandeler = () => {
|
|
58
56
|
if ((name === null || name === void 0 ? void 0 : name.length) > 0 || typeof name === "number") {
|
|
59
57
|
setIsNameFocused(false);
|
|
60
58
|
isShow(false);
|
|
@@ -68,7 +66,7 @@ var EditableField = function EditableField(props) {
|
|
|
68
66
|
};
|
|
69
67
|
|
|
70
68
|
//Select Type
|
|
71
|
-
|
|
69
|
+
const onSelectBLurHandeler = () => {
|
|
72
70
|
if (props.value === null) {
|
|
73
71
|
var _props$value;
|
|
74
72
|
window.alert("Sorry, data should be selected");
|
|
@@ -93,15 +91,9 @@ var EditableField = function EditableField(props) {
|
|
|
93
91
|
cursor: "pointer"
|
|
94
92
|
} : {}
|
|
95
93
|
}, /*#__PURE__*/_react.default.createElement(_text.default, {
|
|
96
|
-
onClick:
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
onMouseEnter: function onMouseEnter() {
|
|
100
|
-
return isShow(true);
|
|
101
|
-
},
|
|
102
|
-
onMouseLeave: function onMouseLeave() {
|
|
103
|
-
return isShow(false);
|
|
104
|
-
},
|
|
94
|
+
onClick: () => setIsNameFocused(true),
|
|
95
|
+
onMouseEnter: () => isShow(true),
|
|
96
|
+
onMouseLeave: () => isShow(false),
|
|
105
97
|
style: {
|
|
106
98
|
display: "flex",
|
|
107
99
|
alignItems: "center",
|
|
@@ -113,7 +105,7 @@ var EditableField = function EditableField(props) {
|
|
|
113
105
|
variant: "standard",
|
|
114
106
|
autoFocus: true,
|
|
115
107
|
value: name,
|
|
116
|
-
onChange:
|
|
108
|
+
onChange: e => {
|
|
117
109
|
setName(e.target.value);
|
|
118
110
|
props.onChange(e.target.value);
|
|
119
111
|
},
|
|
@@ -131,5 +123,4 @@ var EditableField = function EditableField(props) {
|
|
|
131
123
|
}
|
|
132
124
|
})));
|
|
133
125
|
};
|
|
134
|
-
var _default = EditableField;
|
|
135
|
-
exports.default = _default;
|
|
126
|
+
var _default = exports.default = EditableField;
|
|
@@ -7,17 +7,16 @@ exports.default = void 0;
|
|
|
7
7
|
var _material = require("@mui/material");
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _text = _interopRequireDefault(require("../text"));
|
|
10
|
-
function _interopRequireDefault(
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
11
|
/* eslint-disable jsx-a11y/anchor-is-valid */
|
|
12
12
|
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
const Error = () => {
|
|
14
|
+
const handleGoBack = () => {
|
|
15
15
|
window.history.back();
|
|
16
16
|
// window.setTimeout(() => {
|
|
17
17
|
// window.location.reload();
|
|
18
18
|
// }, 10);
|
|
19
19
|
};
|
|
20
|
-
|
|
21
20
|
return /*#__PURE__*/_react.default.createElement(_material.Grid, {
|
|
22
21
|
container: true
|
|
23
22
|
}, /*#__PURE__*/_react.default.createElement(_material.Grid, {
|
|
@@ -39,18 +38,13 @@ var Error = function Error() {
|
|
|
39
38
|
cursor: "pointer",
|
|
40
39
|
color: "blue"
|
|
41
40
|
},
|
|
42
|
-
onClick:
|
|
43
|
-
return window.location.reload();
|
|
44
|
-
}
|
|
41
|
+
onClick: () => window.location.reload()
|
|
45
42
|
}, "Reloading", " "), "the page OR", /*#__PURE__*/_react.default.createElement("a", {
|
|
46
43
|
style: {
|
|
47
44
|
cursor: "pointer",
|
|
48
45
|
color: "blue"
|
|
49
46
|
},
|
|
50
|
-
onClick:
|
|
51
|
-
return handleGoBack();
|
|
52
|
-
}
|
|
47
|
+
onClick: () => handleGoBack()
|
|
53
48
|
}, " ", "Go Back")))));
|
|
54
49
|
};
|
|
55
|
-
var _default = Error;
|
|
56
|
-
exports.default = _default;
|
|
50
|
+
var _default = exports.default = Error;
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _material = require("@mui/material");
|
|
8
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
9
|
+
var _Error = _interopRequireDefault(require("./Error.jpg"));
|
|
10
|
+
var _text = _interopRequireDefault(require("../text"));
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
13
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
14
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
15
|
+
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
16
|
+
// const ErrorBoundary = (props) => {
|
|
17
|
+
// const { homePage } = props;
|
|
18
|
+
// const [hasError, setHasError] = useState(false);
|
|
19
|
+
|
|
20
|
+
// useEffect(() => {
|
|
21
|
+
// const handleError = (error) => {
|
|
22
|
+
// window.alert("coming");
|
|
23
|
+
// // console.error(error);
|
|
24
|
+
// setHasError(true);
|
|
25
|
+
// };
|
|
26
|
+
|
|
27
|
+
// window.addEventListener("error", handleError);
|
|
28
|
+
// return () => {
|
|
29
|
+
// window.removeEventListener("error", handleError);
|
|
30
|
+
// };
|
|
31
|
+
// }, []);
|
|
32
|
+
|
|
33
|
+
// if (hasError) {
|
|
34
|
+
// return (
|
|
35
|
+
// <Grid container>
|
|
36
|
+
// <Grid item xs={6} margin="auto">
|
|
37
|
+
// <Grid container justifyContent="center">
|
|
38
|
+
// <h1>Oops! Something went wrong.</h1>
|
|
39
|
+
// </Grid>
|
|
40
|
+
|
|
41
|
+
// <Grid container justifyContent="center">
|
|
42
|
+
// <Stack direction="row" spacing={2}>
|
|
43
|
+
// <Button
|
|
44
|
+
// variant="outlined"
|
|
45
|
+
// onClick={() => window.location.reload()}
|
|
46
|
+
// >
|
|
47
|
+
// Reload
|
|
48
|
+
// </Button>
|
|
49
|
+
// <Button variant="outlined">
|
|
50
|
+
// <a href={homePage ?? "/"}> Bak to Home</a>
|
|
51
|
+
// </Button>
|
|
52
|
+
// </Stack>
|
|
53
|
+
// </Grid>
|
|
54
|
+
// </Grid>
|
|
55
|
+
// <Grid item xs={6}>
|
|
56
|
+
// <img
|
|
57
|
+
// style={{ height: "100vh", width: "100%", overflow: "hidden" }}
|
|
58
|
+
// src={error_image}
|
|
59
|
+
// />
|
|
60
|
+
// </Grid>
|
|
61
|
+
// </Grid>
|
|
62
|
+
// );
|
|
63
|
+
// } else {
|
|
64
|
+
// return <>{props.children}</>;
|
|
65
|
+
// }
|
|
66
|
+
// };
|
|
67
|
+
|
|
68
|
+
// export default ErrorBoundary;
|
|
69
|
+
|
|
70
|
+
class ErrorBoundary extends _react.Component {
|
|
71
|
+
constructor(props) {
|
|
72
|
+
super(props);
|
|
73
|
+
_defineProperty(this, "handleGoBack", () => {
|
|
74
|
+
window.history.back();
|
|
75
|
+
window.setTimeout(() => {
|
|
76
|
+
window.location.reload();
|
|
77
|
+
}, 10);
|
|
78
|
+
});
|
|
79
|
+
this.state = {
|
|
80
|
+
hasError: false
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
componentDidCatch(error, errorInfo) {
|
|
84
|
+
this.setState({
|
|
85
|
+
hasError: true
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
render() {
|
|
89
|
+
if (this.state.hasError) {
|
|
90
|
+
var _this$props$homePage;
|
|
91
|
+
return /*#__PURE__*/_react.default.createElement(_material.Grid, {
|
|
92
|
+
container: true
|
|
93
|
+
}, /*#__PURE__*/_react.default.createElement(_material.Grid, {
|
|
94
|
+
item: true,
|
|
95
|
+
xs: 6,
|
|
96
|
+
margin: "auto"
|
|
97
|
+
}, /*#__PURE__*/_react.default.createElement(_material.Grid, {
|
|
98
|
+
container: true,
|
|
99
|
+
justifyContent: "center",
|
|
100
|
+
textAlign: "center"
|
|
101
|
+
}, /*#__PURE__*/_react.default.createElement(_text.default, {
|
|
102
|
+
variant: "title",
|
|
103
|
+
bold: true
|
|
104
|
+
}, "Oops! Something went wrong."), /*#__PURE__*/_react.default.createElement(_text.default, {
|
|
105
|
+
variant: "body1"
|
|
106
|
+
}, "Please Reload the page or Refresh the page or return Home to try again.")), /*#__PURE__*/_react.default.createElement(_material.Grid, {
|
|
107
|
+
container: true,
|
|
108
|
+
justifyContent: "center"
|
|
109
|
+
}, /*#__PURE__*/_react.default.createElement(_material.Stack, {
|
|
110
|
+
direction: "row",
|
|
111
|
+
spacing: 2
|
|
112
|
+
}, /*#__PURE__*/_react.default.createElement(_material.Button, {
|
|
113
|
+
variant: "contained",
|
|
114
|
+
onClick: () => window.location.reload()
|
|
115
|
+
}, "Reload"), /*#__PURE__*/_react.default.createElement(_material.Button, {
|
|
116
|
+
variant: "contained",
|
|
117
|
+
onClick: this.handleGoBack
|
|
118
|
+
}, "Go Back"), /*#__PURE__*/_react.default.createElement(_material.Button, {
|
|
119
|
+
variant: "outlined"
|
|
120
|
+
}, /*#__PURE__*/_react.default.createElement("a", {
|
|
121
|
+
style: {
|
|
122
|
+
textDecoration: "none"
|
|
123
|
+
},
|
|
124
|
+
href: (_this$props$homePage = this.props.homePage) !== null && _this$props$homePage !== void 0 ? _this$props$homePage : "/"
|
|
125
|
+
}, " ", "Go Home"))))), /*#__PURE__*/_react.default.createElement(_material.Grid, {
|
|
126
|
+
item: true,
|
|
127
|
+
xs: 6
|
|
128
|
+
}, /*#__PURE__*/_react.default.createElement("img", {
|
|
129
|
+
style: {
|
|
130
|
+
height: "100vh",
|
|
131
|
+
width: "100%",
|
|
132
|
+
overflow: "hidden"
|
|
133
|
+
},
|
|
134
|
+
src: _Error.default
|
|
135
|
+
})));
|
|
136
|
+
}
|
|
137
|
+
return this.props.children;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
var _default = exports.default = ErrorBoundary;
|