@fixefy/fixefy-ui-components 0.3.108 → 0.3.110
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/dist/FxAsyncDropdown/FxAsyncDropdown.js +3 -3
- package/dist/FxDatesProgress/styles/progress.styles.js +1 -1
- package/dist/FxUserImage/FxUserImage.js +2 -2
- package/dist/fixefy-ui-components/src/FxActionsTray/FxActionsTray.js +111 -0
- package/dist/fixefy-ui-components/src/FxActionsTray/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxActionsTray/styles/actionsTray.style.js +114 -0
- package/dist/fixefy-ui-components/src/FxAggregationsBar/FxAggregations.js +41 -0
- package/dist/fixefy-ui-components/src/FxAggregationsBar/helpers/structureReader.js +80 -0
- package/dist/fixefy-ui-components/src/FxAggregationsBar/index.js +22 -0
- package/dist/fixefy-ui-components/src/FxAggregationsBar/operations/query.js +73 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/FxAsyncDropdown.js +500 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/components/CheckboxIcon.js +44 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/components/ChipOption.js +35 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/components/ChosenIcon.js +45 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/components/DeleteButton.js +37 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/components/LogoOption.js +101 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/components/TextOption.js +74 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/components/index.js +36 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/helpers/helpers.js +233 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/styles/dropdown.styles.js +211 -0
- package/dist/fixefy-ui-components/src/FxAsyncDropdown/types.js +4 -0
- package/dist/fixefy-ui-components/src/FxAvatar/FxAvatar.js +145 -0
- package/dist/fixefy-ui-components/src/FxAvatar/helpers/stringToColor.js +23 -0
- package/dist/fixefy-ui-components/src/FxAvatar/index.js +22 -0
- package/dist/fixefy-ui-components/src/FxAvatar/styles/avatar.styles.js +233 -0
- package/dist/fixefy-ui-components/src/FxButton/FxButton.js +106 -0
- package/dist/fixefy-ui-components/src/FxButton/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxButton/styles/button.styles.js +28 -0
- package/dist/fixefy-ui-components/src/FxButtonModalWithComponent/FxButtonModalWithComponent.js +118 -0
- package/dist/fixefy-ui-components/src/FxButtonModalWithComponent/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxButtonModalWithMenu/FxButtonModalWithMenu.js +126 -0
- package/dist/fixefy-ui-components/src/FxButtonModalWithMenu/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxChip/FxChip.js +75 -0
- package/dist/fixefy-ui-components/src/FxChip/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxChip/styles/chip.styles.js +147 -0
- package/dist/fixefy-ui-components/src/FxDatesProgress/FxDatesProgress.js +126 -0
- package/dist/fixefy-ui-components/src/FxDatesProgress/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxDatesProgress/styles/progress.styles.js +24 -0
- package/dist/fixefy-ui-components/src/FxGeneralModal/FxGeneralModal.js +107 -0
- package/dist/fixefy-ui-components/src/FxGeneralModal/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxGridEmptyState/FxGridEmptyState.js +86 -0
- package/dist/fixefy-ui-components/src/FxGridEmptyState/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxGridError/FxGridError.js +91 -0
- package/dist/fixefy-ui-components/src/FxGridError/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxIcon/FxIcon.js +118 -0
- package/dist/fixefy-ui-components/src/FxIcon/content/dynamic_icon.js +20 -0
- package/dist/fixefy-ui-components/src/FxIcon/content/index.js +20 -0
- package/dist/fixefy-ui-components/src/FxIcon/content/lazy_icon.js +87 -0
- package/dist/fixefy-ui-components/src/FxIcon/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxMenuItemWithIcon/FxMenuItemWithIcon.js +84 -0
- package/dist/fixefy-ui-components/src/FxMenuItemWithIcon/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxModal/FxModal.js +171 -0
- package/dist/fixefy-ui-components/src/FxModal/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxModal/styles/modal.style.js +66 -0
- package/dist/fixefy-ui-components/src/FxNotes/FxNotes.js +216 -0
- package/dist/fixefy-ui-components/src/FxNotes/helpers/stringToColor.js +26 -0
- package/dist/fixefy-ui-components/src/FxNotes/index.js +22 -0
- package/dist/fixefy-ui-components/src/FxNotes/operations/queries.js +35 -0
- package/dist/fixefy-ui-components/src/FxNotes/styles/notes.styles.js +168 -0
- package/dist/fixefy-ui-components/src/FxNumberField/FxNumberField.js +108 -0
- package/dist/fixefy-ui-components/src/FxNumberField/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxNumberField/styles/number_field.styles.js +99 -0
- package/dist/fixefy-ui-components/src/FxObjStaticDropdown/FxObjStaticDropdown.js +548 -0
- package/dist/fixefy-ui-components/src/FxObjStaticDropdown/index.js +25 -0
- package/dist/fixefy-ui-components/src/FxObjStaticDropdown/styles/dropdown.styles.js +211 -0
- package/dist/fixefy-ui-components/src/FxPopper/Popper.js +139 -0
- package/dist/fixefy-ui-components/src/FxPopper/PopperWithOutside.js +116 -0
- package/dist/fixefy-ui-components/src/FxPopper/content/PopperHeader.js +36 -0
- package/dist/fixefy-ui-components/src/FxPopper/content/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxPopper/index.js +24 -0
- package/dist/fixefy-ui-components/src/FxPopper/styles/popper.styles.js +138 -0
- package/dist/fixefy-ui-components/src/FxProgressCircle/FxProgressCircle.js +65 -0
- package/dist/fixefy-ui-components/src/FxProgressCircle/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxProgressCircle/styles/progress_circle.styles.js +106 -0
- package/dist/fixefy-ui-components/src/FxProgressCounter/ProgressCounter.js +168 -0
- package/dist/fixefy-ui-components/src/FxProgressCounter/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxProgressCounter/styles/progress_counter.styles.js +66 -0
- package/dist/fixefy-ui-components/src/FxScore/FxScore.js +215 -0
- package/dist/fixefy-ui-components/src/FxScore/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxScore/styles/score.styles.js +102 -0
- package/dist/fixefy-ui-components/src/FxShowMore/FxShowMore.js +80 -0
- package/dist/fixefy-ui-components/src/FxShowMore/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxShowMore/styles/show_more.styles.js +143 -0
- package/dist/fixefy-ui-components/src/FxSlider/FxSlider.js +49 -0
- package/dist/fixefy-ui-components/src/FxSlider/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxStatisticsBar/FxStatisticsBar.js +198 -0
- package/dist/fixefy-ui-components/src/FxStatisticsBar/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxStatisticsBar/styles/statistics.styles.js +103 -0
- package/dist/fixefy-ui-components/src/FxStatusBar/FxStatusBar.js +149 -0
- package/dist/fixefy-ui-components/src/FxStatusBar/helpers/constants.js +22 -0
- package/dist/fixefy-ui-components/src/FxStatusBar/index.js +22 -0
- package/dist/fixefy-ui-components/src/FxStatusBar/styles/statusBar.styles.js +138 -0
- package/dist/fixefy-ui-components/src/FxStrStaticDropdown/FxStrStaticDropdown.js +382 -0
- package/dist/fixefy-ui-components/src/FxStrStaticDropdown/helpers/helpers.js +22 -0
- package/dist/fixefy-ui-components/src/FxStrStaticDropdown/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxStrStaticDropdown/styles/dropdown.styles.js +190 -0
- package/dist/fixefy-ui-components/src/FxStyledButton/FxStyledButton.js +57 -0
- package/dist/fixefy-ui-components/src/FxStyledButton/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxStyledComponents/index.js +319 -0
- package/dist/fixefy-ui-components/src/FxSwitch/FxSwitch.js +106 -0
- package/dist/fixefy-ui-components/src/FxSwitch/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxSwitch/styles/switch.styles.js +42 -0
- package/dist/fixefy-ui-components/src/FxTabs/FxTabs.js +79 -0
- package/dist/fixefy-ui-components/src/FxTabs/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxTag/FxTag.js +50 -0
- package/dist/fixefy-ui-components/src/FxTag/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxTag/styles/tag.styles.js +106 -0
- package/dist/fixefy-ui-components/src/FxTextField/FxTextField.js +211 -0
- package/dist/fixefy-ui-components/src/FxTextField/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxTodo/FxTodo.js +95 -0
- package/dist/fixefy-ui-components/src/FxTodo/index.js +22 -0
- package/dist/fixefy-ui-components/src/FxTodo/styles/todo.styles.js +183 -0
- package/dist/fixefy-ui-components/src/FxToggleButtons/FxToggleButtons.js +69 -0
- package/dist/fixefy-ui-components/src/FxToggleButtons/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxUserImage/FxUserImage.js +236 -0
- package/dist/fixefy-ui-components/src/FxUserImage/index.js +11 -0
- package/dist/fixefy-ui-components/src/FxWizard/FxWizard.js +50 -0
- package/dist/fixefy-ui-components/src/FxWizard/index.js +19 -0
- package/dist/fixefy-ui-components/src/FxWizard/steps launcher/StepsLauncher.js +52 -0
- package/dist/fixefy-ui-components/src/FxWizard/steps launcher/index.js +18 -0
- package/dist/fixefy-ui-components/src/index.js +277 -0
- package/package.json +4 -5
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "FxButtonModalWithComponent", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _FxButtonModalWithComponent.FxButtonModalWithComponent;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _FxButtonModalWithComponent = require("./FxButtonModalWithComponent");
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "FxButtonModalWithMenu", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return FxButtonModalWithMenu;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
|
|
13
|
+
const _Fade = /*#__PURE__*/ _interop_require_default(require("@mui/material/Fade"));
|
|
14
|
+
const _Menu = /*#__PURE__*/ _interop_require_default(require("@mui/material/Menu"));
|
|
15
|
+
const _Box = /*#__PURE__*/ _interop_require_default(require("@mui/material/Box"));
|
|
16
|
+
const _FxMenuItemWithIcon = require("../FxMenuItemWithIcon");
|
|
17
|
+
const _FxStyledButton = require("../FxStyledButton");
|
|
18
|
+
function _interop_require_default(obj) {
|
|
19
|
+
return obj && obj.__esModule ? obj : {
|
|
20
|
+
default: obj
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
function _getRequireWildcardCache(nodeInterop) {
|
|
24
|
+
if (typeof WeakMap !== "function") return null;
|
|
25
|
+
var cacheBabelInterop = new WeakMap();
|
|
26
|
+
var cacheNodeInterop = new WeakMap();
|
|
27
|
+
return (_getRequireWildcardCache = function(nodeInterop) {
|
|
28
|
+
return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
|
|
29
|
+
})(nodeInterop);
|
|
30
|
+
}
|
|
31
|
+
function _interop_require_wildcard(obj, nodeInterop) {
|
|
32
|
+
if (!nodeInterop && obj && obj.__esModule) {
|
|
33
|
+
return obj;
|
|
34
|
+
}
|
|
35
|
+
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
36
|
+
return {
|
|
37
|
+
default: obj
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
var cache = _getRequireWildcardCache(nodeInterop);
|
|
41
|
+
if (cache && cache.has(obj)) {
|
|
42
|
+
return cache.get(obj);
|
|
43
|
+
}
|
|
44
|
+
var newObj = {
|
|
45
|
+
__proto__: null
|
|
46
|
+
};
|
|
47
|
+
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
48
|
+
for(var key in obj){
|
|
49
|
+
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
50
|
+
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
51
|
+
if (desc && (desc.get || desc.set)) {
|
|
52
|
+
Object.defineProperty(newObj, key, desc);
|
|
53
|
+
} else {
|
|
54
|
+
newObj[key] = obj[key];
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
newObj.default = obj;
|
|
59
|
+
if (cache) {
|
|
60
|
+
cache.set(obj, newObj);
|
|
61
|
+
}
|
|
62
|
+
return newObj;
|
|
63
|
+
}
|
|
64
|
+
const FxButtonModalWithMenu = ({ assetUrl, btnType = 'text', btnValue, modalData, onClick, disabled, startIcon, endIcon, shouldShowModal = true, buttonSx, menuItemSx, iconSize })=>{
|
|
65
|
+
const [isOpen, setIsOpen] = (0, _react.useState)(false);
|
|
66
|
+
const [AnchorEl, setAnchorEl] = (0, _react.useState)(null);
|
|
67
|
+
const handleClick = (e)=>{
|
|
68
|
+
if (onClick) {
|
|
69
|
+
onClick();
|
|
70
|
+
setIsOpen((prev)=>!prev);
|
|
71
|
+
setAnchorEl(e.currentTarget);
|
|
72
|
+
} else {
|
|
73
|
+
setIsOpen((prev)=>!prev);
|
|
74
|
+
setAnchorEl(e.currentTarget);
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
const handleClose = ()=>{
|
|
78
|
+
setIsOpen(false);
|
|
79
|
+
setAnchorEl(null);
|
|
80
|
+
};
|
|
81
|
+
(0, _react.useEffect)(()=>{
|
|
82
|
+
setIsOpen(false);
|
|
83
|
+
}, [
|
|
84
|
+
btnValue
|
|
85
|
+
]);
|
|
86
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
87
|
+
children: [
|
|
88
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_FxStyledButton.FxStyledButton, {
|
|
89
|
+
assetUrl: assetUrl,
|
|
90
|
+
sx: buttonSx,
|
|
91
|
+
btnType: btnType,
|
|
92
|
+
btnValue: btnValue,
|
|
93
|
+
onClick: handleClick,
|
|
94
|
+
startIcon: startIcon,
|
|
95
|
+
endIcon: endIcon,
|
|
96
|
+
iconSize: iconSize || 20,
|
|
97
|
+
disabled: disabled
|
|
98
|
+
}),
|
|
99
|
+
shouldShowModal && /*#__PURE__*/ (0, _jsxruntime.jsx)(_Menu.default, {
|
|
100
|
+
id: "fade-menu",
|
|
101
|
+
MenuListProps: {
|
|
102
|
+
'aria-labelledby': 'fade-button',
|
|
103
|
+
sx: {
|
|
104
|
+
padding: 0
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
anchorEl: AnchorEl,
|
|
108
|
+
open: isOpen,
|
|
109
|
+
onClose: handleClose,
|
|
110
|
+
TransitionComponent: _Fade.default,
|
|
111
|
+
children: isOpen && (modalData === null || modalData === void 0 ? void 0 : modalData.map((item, i)=>{
|
|
112
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_FxMenuItemWithIcon.FxMenuItemWithIcon, {
|
|
113
|
+
assetUrl: assetUrl,
|
|
114
|
+
icon: item.icon,
|
|
115
|
+
title: item.title,
|
|
116
|
+
onClick: ()=>{
|
|
117
|
+
handleClose();
|
|
118
|
+
item.onClick();
|
|
119
|
+
},
|
|
120
|
+
sx: menuItemSx
|
|
121
|
+
}, i);
|
|
122
|
+
}))
|
|
123
|
+
})
|
|
124
|
+
]
|
|
125
|
+
});
|
|
126
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "FxButtonModalWithMenu", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _FxButtonModalWithMenu.FxButtonModalWithMenu;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _FxButtonModalWithMenu = require("./FxButtonModalWithMenu");
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "FxChip", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return FxChip;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
13
|
+
const _fixefyuiutils = require("@fixefy/fixefy-ui-utils");
|
|
14
|
+
const _CloseRounded = /*#__PURE__*/ _interop_require_default(require("@mui/icons-material/CloseRounded"));
|
|
15
|
+
const _chipstyles = require("./styles/chip.styles");
|
|
16
|
+
const _FxIcon = require("../FxIcon");
|
|
17
|
+
function _interop_require_default(obj) {
|
|
18
|
+
return obj && obj.__esModule ? obj : {
|
|
19
|
+
default: obj
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
const FxChip = (props)=>{
|
|
23
|
+
const { assetUrl, status, label, type = 'status', scoreValue = 0, minimized = false, variant = 'outlined', onClick, onDelete, icon } = props;
|
|
24
|
+
const newStatus = status ? status.split(' ').join('_') : status;
|
|
25
|
+
const value = typeof label === 'number' ? label.toFixed(2) : label;
|
|
26
|
+
switch(type){
|
|
27
|
+
case 'reco':
|
|
28
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_chipstyles.RecoChipStyled, {
|
|
29
|
+
status: newStatus,
|
|
30
|
+
label: (0, _fixefyuiutils.titleCase)(value),
|
|
31
|
+
variant: variant
|
|
32
|
+
});
|
|
33
|
+
case 'status':
|
|
34
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_chipstyles.StatusChipStyled, {
|
|
35
|
+
status: newStatus,
|
|
36
|
+
label: (0, _fixefyuiutils.titleCase)(value),
|
|
37
|
+
variant: variant,
|
|
38
|
+
onClick: onClick,
|
|
39
|
+
onDelete: onDelete,
|
|
40
|
+
deleteIcon: onDelete ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_CloseRounded.default, {
|
|
41
|
+
sx: {
|
|
42
|
+
width: 11,
|
|
43
|
+
height: 11
|
|
44
|
+
}
|
|
45
|
+
}) : null
|
|
46
|
+
});
|
|
47
|
+
case 'priority':
|
|
48
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_chipstyles.PriorityChipStyled, {
|
|
49
|
+
status: newStatus,
|
|
50
|
+
label: (0, _fixefyuiutils.titleCase)(value),
|
|
51
|
+
variant: variant
|
|
52
|
+
});
|
|
53
|
+
case 'dimension':
|
|
54
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_chipstyles.DimensionChipStyled, {
|
|
55
|
+
label: (0, _fixefyuiutils.titleCase)(value),
|
|
56
|
+
minimized: minimized,
|
|
57
|
+
variant: variant,
|
|
58
|
+
icon: /*#__PURE__*/ (0, _jsxruntime.jsx)(_FxIcon.FxIcon, {
|
|
59
|
+
icon: `${icon}.svg`,
|
|
60
|
+
width: 15,
|
|
61
|
+
height: 15,
|
|
62
|
+
assetUrl: assetUrl
|
|
63
|
+
})
|
|
64
|
+
});
|
|
65
|
+
default:
|
|
66
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_chipstyles.ScoreChipStyled, {
|
|
67
|
+
score: scoreValue,
|
|
68
|
+
scoreLabel: (0, _fixefyuiutils.getScoreColor)(scoreValue),
|
|
69
|
+
label: (0, _fixefyuiutils.titleCase)(value),
|
|
70
|
+
minimized: minimized,
|
|
71
|
+
variant: variant,
|
|
72
|
+
onClick: onClick
|
|
73
|
+
});
|
|
74
|
+
}
|
|
75
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
function _export(target, all) {
|
|
6
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: all[name]
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
_export(exports, {
|
|
12
|
+
ChipPropsType: function() {
|
|
13
|
+
return _FxChip.ChipPropsType;
|
|
14
|
+
},
|
|
15
|
+
FxChip: function() {
|
|
16
|
+
return _FxChip.FxChip;
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
const _FxChip = require("./FxChip");
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
function _export(target, all) {
|
|
6
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: all[name]
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
_export(exports, {
|
|
12
|
+
DimensionChipStyled: function() {
|
|
13
|
+
return DimensionChipStyled;
|
|
14
|
+
},
|
|
15
|
+
PriorityChipStyled: function() {
|
|
16
|
+
return PriorityChipStyled;
|
|
17
|
+
},
|
|
18
|
+
RecoChipStyled: function() {
|
|
19
|
+
return RecoChipStyled;
|
|
20
|
+
},
|
|
21
|
+
ScoreChipStyled: function() {
|
|
22
|
+
return ScoreChipStyled;
|
|
23
|
+
},
|
|
24
|
+
StatusChipStyled: function() {
|
|
25
|
+
return StatusChipStyled;
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
const _Chip = /*#__PURE__*/ _interop_require_default(require("@mui/material/Chip"));
|
|
29
|
+
const _styles = require("@mui/material/styles");
|
|
30
|
+
function _interop_require_default(obj) {
|
|
31
|
+
return obj && obj.__esModule ? obj : {
|
|
32
|
+
default: obj
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
const ScoreChipStyled = (0, _styles.styled)(_Chip.default)(({ theme, scoreLabel, minimized })=>{
|
|
36
|
+
const color = theme.palette.score[scoreLabel];
|
|
37
|
+
return {
|
|
38
|
+
height: 20,
|
|
39
|
+
minWidth: minimized ? 35 : 80,
|
|
40
|
+
maxWidth: 120,
|
|
41
|
+
backgroundColor: color,
|
|
42
|
+
['& .MuiChip-label']: {
|
|
43
|
+
color: theme.palette.common.white,
|
|
44
|
+
fontSize: 9,
|
|
45
|
+
fontWeight: 600,
|
|
46
|
+
paddingLeft: minimized ? 0 : 'inherit',
|
|
47
|
+
paddingRight: minimized ? 0 : 'inherit'
|
|
48
|
+
}
|
|
49
|
+
};
|
|
50
|
+
});
|
|
51
|
+
const StatusChipStyled = (0, _styles.styled)(_Chip.default)(({ theme, status, variant })=>{
|
|
52
|
+
let backgroundColor, border, labelColor;
|
|
53
|
+
if (theme.palette.status[status]) {
|
|
54
|
+
if (variant === 'filled') {
|
|
55
|
+
backgroundColor = theme.palette.status[status]['border'];
|
|
56
|
+
labelColor = theme.palette.common.white;
|
|
57
|
+
} else {
|
|
58
|
+
backgroundColor = theme.palette.status[status]['background'];
|
|
59
|
+
}
|
|
60
|
+
border = theme.palette.status[status]['border'];
|
|
61
|
+
}
|
|
62
|
+
return {
|
|
63
|
+
height: 24,
|
|
64
|
+
minWidth: 96,
|
|
65
|
+
maxWidth: 120,
|
|
66
|
+
boxSizing: 'border-box',
|
|
67
|
+
paddingLeft: '9.6px',
|
|
68
|
+
paddingRight: '9.6px',
|
|
69
|
+
paddingTop: '6px',
|
|
70
|
+
paddingBottom: '6px',
|
|
71
|
+
borderRadius: '60px',
|
|
72
|
+
['& .MuiChip-label']: {
|
|
73
|
+
fontSize: 10.8,
|
|
74
|
+
fontWeight: 600,
|
|
75
|
+
lineHeight: 'normal',
|
|
76
|
+
letterSpacing: '0.24px',
|
|
77
|
+
textTransform: 'capitalize',
|
|
78
|
+
fontFamily: 'Open Sans',
|
|
79
|
+
wordWrap: 'break-word',
|
|
80
|
+
padding: 0,
|
|
81
|
+
color: labelColor ? labelColor : '#5C6467'
|
|
82
|
+
},
|
|
83
|
+
backgroundColor,
|
|
84
|
+
border: `1.2px solid ${border}`
|
|
85
|
+
};
|
|
86
|
+
});
|
|
87
|
+
const PriorityChipStyled = (0, _styles.styled)(_Chip.default)(({ theme, status })=>{
|
|
88
|
+
var _theme_palette_chipPriority_status, _theme_palette_chipPriority, _theme_palette, _theme_palette_chipPriority_status1, _theme_palette_chipPriority1, _theme_palette1, _theme_palette_chipPriority_status2, _theme_palette_chipPriority2, _theme_palette2;
|
|
89
|
+
var _theme_palette_chipPriority_status_background;
|
|
90
|
+
const backgroundColor = (_theme_palette_chipPriority_status_background = theme === null || theme === void 0 ? void 0 : (_theme_palette = theme.palette) === null || _theme_palette === void 0 ? void 0 : (_theme_palette_chipPriority = _theme_palette.chipPriority) === null || _theme_palette_chipPriority === void 0 ? void 0 : (_theme_palette_chipPriority_status = _theme_palette_chipPriority[status]) === null || _theme_palette_chipPriority_status === void 0 ? void 0 : _theme_palette_chipPriority_status.background) !== null && _theme_palette_chipPriority_status_background !== void 0 ? _theme_palette_chipPriority_status_background : '#F6F9FA';
|
|
91
|
+
var _theme_palette_chipPriority_status_label;
|
|
92
|
+
const labelColor = (_theme_palette_chipPriority_status_label = theme === null || theme === void 0 ? void 0 : (_theme_palette1 = theme.palette) === null || _theme_palette1 === void 0 ? void 0 : (_theme_palette_chipPriority1 = _theme_palette1.chipPriority) === null || _theme_palette_chipPriority1 === void 0 ? void 0 : (_theme_palette_chipPriority_status1 = _theme_palette_chipPriority1[status]) === null || _theme_palette_chipPriority_status1 === void 0 ? void 0 : _theme_palette_chipPriority_status1.label) !== null && _theme_palette_chipPriority_status_label !== void 0 ? _theme_palette_chipPriority_status_label : '#8B9092';
|
|
93
|
+
var _theme_palette_chipPriority_status_border;
|
|
94
|
+
const border = (_theme_palette_chipPriority_status_border = theme === null || theme === void 0 ? void 0 : (_theme_palette2 = theme.palette) === null || _theme_palette2 === void 0 ? void 0 : (_theme_palette_chipPriority2 = _theme_palette2.chipPriority) === null || _theme_palette_chipPriority2 === void 0 ? void 0 : (_theme_palette_chipPriority_status2 = _theme_palette_chipPriority2[status]) === null || _theme_palette_chipPriority_status2 === void 0 ? void 0 : _theme_palette_chipPriority_status2.border) !== null && _theme_palette_chipPriority_status_border !== void 0 ? _theme_palette_chipPriority_status_border : '#8B9092';
|
|
95
|
+
return {
|
|
96
|
+
height: 20,
|
|
97
|
+
minWidth: 80,
|
|
98
|
+
maxWidth: 120,
|
|
99
|
+
['& .MuiChip-label']: {
|
|
100
|
+
fontSize: 9,
|
|
101
|
+
fontWeight: 600,
|
|
102
|
+
lineHeight: '12px',
|
|
103
|
+
color: labelColor ? labelColor : theme.palette.statistics.label
|
|
104
|
+
},
|
|
105
|
+
backgroundColor,
|
|
106
|
+
border: `1px solid ${border}`
|
|
107
|
+
};
|
|
108
|
+
});
|
|
109
|
+
const RecoChipStyled = (0, _styles.styled)(_Chip.default)(({ theme, status })=>{
|
|
110
|
+
var _theme_palette_recoState_status, _theme_palette_recoState, _theme_palette, _theme_palette_recoState_status1, _theme_palette_recoState1, _theme_palette1, _theme_palette_recoState_status2, _theme_palette_recoState2, _theme_palette2;
|
|
111
|
+
var _theme_palette_recoState_status_background;
|
|
112
|
+
const backgroundColor = (_theme_palette_recoState_status_background = theme === null || theme === void 0 ? void 0 : (_theme_palette = theme.palette) === null || _theme_palette === void 0 ? void 0 : (_theme_palette_recoState = _theme_palette.recoState) === null || _theme_palette_recoState === void 0 ? void 0 : (_theme_palette_recoState_status = _theme_palette_recoState[status]) === null || _theme_palette_recoState_status === void 0 ? void 0 : _theme_palette_recoState_status.background) !== null && _theme_palette_recoState_status_background !== void 0 ? _theme_palette_recoState_status_background : '#8B9092';
|
|
113
|
+
var _theme_palette_recoState_status_label;
|
|
114
|
+
const labelColor = (_theme_palette_recoState_status_label = theme === null || theme === void 0 ? void 0 : (_theme_palette1 = theme.palette) === null || _theme_palette1 === void 0 ? void 0 : (_theme_palette_recoState1 = _theme_palette1.recoState) === null || _theme_palette_recoState1 === void 0 ? void 0 : (_theme_palette_recoState_status1 = _theme_palette_recoState1[status]) === null || _theme_palette_recoState_status1 === void 0 ? void 0 : _theme_palette_recoState_status1.label) !== null && _theme_palette_recoState_status_label !== void 0 ? _theme_palette_recoState_status_label : '#F6F9FA';
|
|
115
|
+
var _theme_palette_recoState_status_border;
|
|
116
|
+
const border = (_theme_palette_recoState_status_border = theme === null || theme === void 0 ? void 0 : (_theme_palette2 = theme.palette) === null || _theme_palette2 === void 0 ? void 0 : (_theme_palette_recoState2 = _theme_palette2.recoState) === null || _theme_palette_recoState2 === void 0 ? void 0 : (_theme_palette_recoState_status2 = _theme_palette_recoState2[status]) === null || _theme_palette_recoState_status2 === void 0 ? void 0 : _theme_palette_recoState_status2.border) !== null && _theme_palette_recoState_status_border !== void 0 ? _theme_palette_recoState_status_border : '#8B9092';
|
|
117
|
+
return {
|
|
118
|
+
height: 20,
|
|
119
|
+
minWidth: 80,
|
|
120
|
+
maxWidth: 120,
|
|
121
|
+
['& .MuiChip-label']: {
|
|
122
|
+
fontSize: 9,
|
|
123
|
+
fontWeight: 600,
|
|
124
|
+
lineHeight: '12px',
|
|
125
|
+
color: labelColor ? labelColor : theme.palette.statistics.label
|
|
126
|
+
},
|
|
127
|
+
backgroundColor,
|
|
128
|
+
border: `1px solid ${border}`
|
|
129
|
+
};
|
|
130
|
+
});
|
|
131
|
+
const DimensionChipStyled = (0, _styles.styled)(_Chip.default)(({ minimized })=>{
|
|
132
|
+
return {
|
|
133
|
+
height: '36px',
|
|
134
|
+
minWidth: minimized ? 35 : 80,
|
|
135
|
+
maxWidth: 120,
|
|
136
|
+
backgroundColor: '#F6F9FA',
|
|
137
|
+
borderColor: '#C6DDE2',
|
|
138
|
+
['& .MuiChip-label']: {
|
|
139
|
+
color: '#172326',
|
|
140
|
+
fontSize: 14
|
|
141
|
+
},
|
|
142
|
+
'& .MuiChip-icon': {
|
|
143
|
+
width: 11,
|
|
144
|
+
height: 11
|
|
145
|
+
}
|
|
146
|
+
};
|
|
147
|
+
});
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "FxDatesProgress", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return FxDatesProgress;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
13
|
+
const _FxStyledComponents = require("../FxStyledComponents");
|
|
14
|
+
const _progressstyles = require("./styles/progress.styles");
|
|
15
|
+
const _fixefyuiutils = require("@fixefy/fixefy-ui-utils");
|
|
16
|
+
const _Box = /*#__PURE__*/ _interop_require_default(require("@mui/material/Box"));
|
|
17
|
+
const _Typography = /*#__PURE__*/ _interop_require_default(require("@mui/material/Typography"));
|
|
18
|
+
function _interop_require_default(obj) {
|
|
19
|
+
return obj && obj.__esModule ? obj : {
|
|
20
|
+
default: obj
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
const FxDatesProgress = ({ start, end, progressValue, width, height, oneLine })=>{
|
|
24
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
25
|
+
sx: {
|
|
26
|
+
width: width || '199px',
|
|
27
|
+
height: height || '44px'
|
|
28
|
+
},
|
|
29
|
+
children: [
|
|
30
|
+
oneLine ? /*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
31
|
+
sx: {
|
|
32
|
+
display: 'flex',
|
|
33
|
+
justifyContent: 'space-between',
|
|
34
|
+
mb: 1,
|
|
35
|
+
gap: 1
|
|
36
|
+
},
|
|
37
|
+
children: [
|
|
38
|
+
/*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
39
|
+
sx: {
|
|
40
|
+
display: 'flex',
|
|
41
|
+
gap: 0.5,
|
|
42
|
+
alignItems: 'center'
|
|
43
|
+
},
|
|
44
|
+
children: [
|
|
45
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_FxStyledComponents.Label, {
|
|
46
|
+
children: (0, _fixefyuiutils.titleCase)(start.label)
|
|
47
|
+
}),
|
|
48
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Typography.default, {
|
|
49
|
+
children: start.value || (0, _fixefyuiutils.titleCase)(start.placeholder)
|
|
50
|
+
})
|
|
51
|
+
]
|
|
52
|
+
}),
|
|
53
|
+
/*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
54
|
+
sx: {
|
|
55
|
+
display: 'flex',
|
|
56
|
+
gap: 0.5,
|
|
57
|
+
alignItems: 'center'
|
|
58
|
+
},
|
|
59
|
+
children: [
|
|
60
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_FxStyledComponents.Label, {
|
|
61
|
+
style: {
|
|
62
|
+
textAlign: 'right',
|
|
63
|
+
display: 'block'
|
|
64
|
+
},
|
|
65
|
+
children: (0, _fixefyuiutils.titleCase)(end.label)
|
|
66
|
+
}),
|
|
67
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Typography.default, {
|
|
68
|
+
style: {
|
|
69
|
+
textAlign: 'right',
|
|
70
|
+
display: 'block'
|
|
71
|
+
},
|
|
72
|
+
children: end.value || (0, _fixefyuiutils.titleCase)(end.placeholder)
|
|
73
|
+
})
|
|
74
|
+
]
|
|
75
|
+
})
|
|
76
|
+
]
|
|
77
|
+
}) : /*#__PURE__*/ (0, _jsxruntime.jsx)(_Box.default, {
|
|
78
|
+
sx: {
|
|
79
|
+
width: width || '199px',
|
|
80
|
+
height: height || '44px'
|
|
81
|
+
},
|
|
82
|
+
children: /*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
83
|
+
sx: {
|
|
84
|
+
display: 'flex',
|
|
85
|
+
justifyContent: 'space-between',
|
|
86
|
+
mb: 1
|
|
87
|
+
},
|
|
88
|
+
children: [
|
|
89
|
+
/*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
90
|
+
children: [
|
|
91
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_FxStyledComponents.Label, {
|
|
92
|
+
children: (0, _fixefyuiutils.titleCase)(start.label)
|
|
93
|
+
}),
|
|
94
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Typography.default, {
|
|
95
|
+
children: start.value || (0, _fixefyuiutils.titleCase)(start.placeholder)
|
|
96
|
+
})
|
|
97
|
+
]
|
|
98
|
+
}),
|
|
99
|
+
/*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
100
|
+
children: [
|
|
101
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_FxStyledComponents.Label, {
|
|
102
|
+
style: {
|
|
103
|
+
textAlign: 'right',
|
|
104
|
+
display: 'block'
|
|
105
|
+
},
|
|
106
|
+
children: (0, _fixefyuiutils.titleCase)(end.label)
|
|
107
|
+
}),
|
|
108
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Typography.default, {
|
|
109
|
+
style: {
|
|
110
|
+
textAlign: 'right',
|
|
111
|
+
display: 'block'
|
|
112
|
+
},
|
|
113
|
+
children: end.value || (0, _fixefyuiutils.titleCase)(end.placeholder)
|
|
114
|
+
})
|
|
115
|
+
]
|
|
116
|
+
})
|
|
117
|
+
]
|
|
118
|
+
})
|
|
119
|
+
}),
|
|
120
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_progressstyles.Progress, {
|
|
121
|
+
value: progressValue,
|
|
122
|
+
variant: "determinate"
|
|
123
|
+
})
|
|
124
|
+
]
|
|
125
|
+
});
|
|
126
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "FxDatesProgress", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _FxDatesProgress.FxDatesProgress;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _FxDatesProgress = require("./FxDatesProgress");
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "Progress", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return Progress;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _LinearProgress = /*#__PURE__*/ _interop_require_default(require("@mui/material/LinearProgress"));
|
|
12
|
+
const _styles = require("@mui/material/styles");
|
|
13
|
+
function _interop_require_default(obj) {
|
|
14
|
+
return obj && obj.__esModule ? obj : {
|
|
15
|
+
default: obj
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
const Progress = (0, _styles.styled)(_LinearProgress.default)(({ theme })=>({
|
|
19
|
+
borderRadius: '20px',
|
|
20
|
+
backgroundColor: '#E7EEF0',
|
|
21
|
+
'& .MuiLinearProgress-barColorPrimary': {
|
|
22
|
+
backgroundColor: theme.palette.primary['300']
|
|
23
|
+
}
|
|
24
|
+
}));
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "FxGeneralModal", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return FxGeneralModal;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _jsxruntime = require("react/jsx-runtime");
|
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
|
|
13
|
+
const _Fade = /*#__PURE__*/ _interop_require_default(require("@mui/material/Fade"));
|
|
14
|
+
const _Menu = /*#__PURE__*/ _interop_require_default(require("@mui/material/Menu"));
|
|
15
|
+
const _Box = /*#__PURE__*/ _interop_require_default(require("@mui/material/Box"));
|
|
16
|
+
function _interop_require_default(obj) {
|
|
17
|
+
return obj && obj.__esModule ? obj : {
|
|
18
|
+
default: obj
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
function _getRequireWildcardCache(nodeInterop) {
|
|
22
|
+
if (typeof WeakMap !== "function") return null;
|
|
23
|
+
var cacheBabelInterop = new WeakMap();
|
|
24
|
+
var cacheNodeInterop = new WeakMap();
|
|
25
|
+
return (_getRequireWildcardCache = function(nodeInterop) {
|
|
26
|
+
return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
|
|
27
|
+
})(nodeInterop);
|
|
28
|
+
}
|
|
29
|
+
function _interop_require_wildcard(obj, nodeInterop) {
|
|
30
|
+
if (!nodeInterop && obj && obj.__esModule) {
|
|
31
|
+
return obj;
|
|
32
|
+
}
|
|
33
|
+
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
34
|
+
return {
|
|
35
|
+
default: obj
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
var cache = _getRequireWildcardCache(nodeInterop);
|
|
39
|
+
if (cache && cache.has(obj)) {
|
|
40
|
+
return cache.get(obj);
|
|
41
|
+
}
|
|
42
|
+
var newObj = {
|
|
43
|
+
__proto__: null
|
|
44
|
+
};
|
|
45
|
+
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
46
|
+
for(var key in obj){
|
|
47
|
+
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
48
|
+
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
49
|
+
if (desc && (desc.get || desc.set)) {
|
|
50
|
+
Object.defineProperty(newObj, key, desc);
|
|
51
|
+
} else {
|
|
52
|
+
newObj[key] = obj[key];
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
newObj.default = obj;
|
|
57
|
+
if (cache) {
|
|
58
|
+
cache.set(obj, newObj);
|
|
59
|
+
}
|
|
60
|
+
return newObj;
|
|
61
|
+
}
|
|
62
|
+
const FxGeneralModal = ({ buttonComponent, modalComponent, onClick, closeOnButtonChange = true })=>{
|
|
63
|
+
const [isOpen, setIsOpen] = (0, _react.useState)(false);
|
|
64
|
+
const [AnchorEl, setAnchorEl] = (0, _react.useState)(null);
|
|
65
|
+
const handleClick = (e)=>{
|
|
66
|
+
if (onClick) {
|
|
67
|
+
e.stopPropagation();
|
|
68
|
+
onClick();
|
|
69
|
+
setIsOpen((prev)=>!prev);
|
|
70
|
+
setAnchorEl(e.currentTarget);
|
|
71
|
+
} else {
|
|
72
|
+
e.stopPropagation();
|
|
73
|
+
setIsOpen((prev)=>!prev);
|
|
74
|
+
setAnchorEl(e.currentTarget);
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
const handleClose = ()=>{
|
|
78
|
+
setIsOpen(false);
|
|
79
|
+
setAnchorEl(null);
|
|
80
|
+
};
|
|
81
|
+
(0, _react.useEffect)(()=>{
|
|
82
|
+
if (closeOnButtonChange) {
|
|
83
|
+
setIsOpen(false);
|
|
84
|
+
}
|
|
85
|
+
}, [
|
|
86
|
+
buttonComponent
|
|
87
|
+
]);
|
|
88
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(_Box.default, {
|
|
89
|
+
children: [
|
|
90
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Box.default, {
|
|
91
|
+
onClick: handleClick,
|
|
92
|
+
children: buttonComponent
|
|
93
|
+
}),
|
|
94
|
+
/*#__PURE__*/ (0, _jsxruntime.jsx)(_Menu.default, {
|
|
95
|
+
id: "fade-menu",
|
|
96
|
+
MenuListProps: {
|
|
97
|
+
'aria-labelledby': 'fade-button'
|
|
98
|
+
},
|
|
99
|
+
anchorEl: AnchorEl,
|
|
100
|
+
open: isOpen,
|
|
101
|
+
onClose: handleClose,
|
|
102
|
+
TransitionComponent: _Fade.default,
|
|
103
|
+
children: isOpen && modalComponent
|
|
104
|
+
})
|
|
105
|
+
]
|
|
106
|
+
});
|
|
107
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
Object.defineProperty(exports, "FxGeneralModal", {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function() {
|
|
8
|
+
return _FxGeneralModal.FxGeneralModal;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
const _FxGeneralModal = require("./FxGeneralModal");
|