@agilemotion/oui-react-js 1.6.3 → 1.6.5
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/ApplicationManager.js +675 -1044
- package/dist/BasicApp.js +7 -27
- package/dist/BasicAppHome.js +27 -101
- package/dist/DynamicJS.js +109 -197
- package/dist/InteractionPortalApp.js +7 -27
- package/dist/InteractionPortalAppHome.js +21 -87
- package/dist/InteractionPortalApp_old.js +60 -122
- package/dist/RestUtils.js +269 -410
- package/dist/TypedValue.js +20 -26
- package/dist/Utils.js +295 -481
- package/dist/WithRouter.js +9 -17
- package/dist/assets/jss/components/authNavbarStyle.js +168 -171
- package/dist/assets/jss/components/buttonStyle.js +2 -5
- package/dist/assets/jss/components/cardAvatarStyle.js +2 -5
- package/dist/assets/jss/components/cardBodyStyle.js +2 -5
- package/dist/assets/jss/components/cardFooterStyle.js +2 -5
- package/dist/assets/jss/components/cardHeaderStyle.js +20 -17
- package/dist/assets/jss/components/cardIconStyle.js +2 -5
- package/dist/assets/jss/components/cardStyle.js +2 -5
- package/dist/assets/jss/components/cardTextStyle.js +2 -5
- package/dist/assets/jss/components/customDropdownStyle.js +171 -173
- package/dist/assets/jss/components/customInputStyle.js +5 -13
- package/dist/assets/jss/components/dropdownStyle.js +71 -74
- package/dist/assets/jss/components/footerStyle.js +14 -23
- package/dist/assets/jss/components/headerLinksStyle.js +52 -53
- package/dist/assets/jss/components/headerStyle.js +68 -73
- package/dist/assets/jss/components/navbarLinksStyle.js +81 -74
- package/dist/assets/jss/components/navbarStyle.js +79 -84
- package/dist/assets/jss/components/sidebarStyle.js +438 -441
- package/dist/assets/jss/components/typographyStyle.js +5 -13
- package/dist/assets/jss/rootStyle.js +85 -151
- package/dist/assets/jss/views/layoutStyle.js +45 -51
- package/dist/assets/jss/views/loginBasicStyle.js +2 -5
- package/dist/assets/jss/views/loginBusinessPortalStyle.js +2 -5
- package/dist/assets/jss/views/loginStyle.js +80 -87
- package/dist/components/AlertBar.js +20 -75
- package/dist/components/AlertItem.js +13 -49
- package/dist/components/AlertTemplate.js +12 -18
- package/dist/components/Button.js +41 -112
- package/dist/components/Calendar.js +99 -208
- package/dist/components/ConfirmationDialog.js +13 -54
- package/dist/components/DataGrid.js +271 -695
- package/dist/components/DataGridColumn.js +24 -74
- package/dist/components/DataGridFilter.js +107 -245
- package/dist/components/DataGridHeading.js +34 -78
- package/dist/components/Dialog.js +37 -130
- package/dist/components/DocumentTemplateDesigner.js +16 -57
- package/dist/components/DocumentTemplateDesignerComponent.js +47 -141
- package/dist/components/DocumentTemplatePlaceholderDialog.js +34 -67
- package/dist/components/DocumentViewer.js +25 -65
- package/dist/components/DocumentViewerComponent.js +13 -44
- package/dist/components/ElementResizeHandler.js +148 -200
- package/dist/components/FileThumb.js +15 -56
- package/dist/components/Graph.js +98 -203
- package/dist/components/GraphNode.js +20 -61
- package/dist/components/HtmlPanel.js +38 -105
- package/dist/components/Icon.js +174 -253
- package/dist/components/LoadingIndicator.js +4 -11
- package/dist/components/LottieIcon.js +63 -60
- package/dist/components/PopupView.js +21 -60
- package/dist/components/Portlet.js +18 -60
- package/dist/components/RegularButton.js +34 -42
- package/dist/components/SignaturePanel.js +19 -67
- package/dist/components/SocketManager.js +133 -228
- package/dist/components/StepperTitleBar.js +48 -99
- package/dist/components/TabPage.js +30 -47
- package/dist/components/TabPanel.js +35 -122
- package/dist/components/TableCellContent.js +34 -98
- package/dist/components/TemplateDesigner.js +115 -230
- package/dist/components/TemplateItemEventHandler.js +298 -481
- package/dist/components/TemplateTable.js +117 -218
- package/dist/components/TitleBar.js +15 -53
- package/dist/components/Toolbar.js +44 -110
- package/dist/components/Tooltip.js +37 -56
- package/dist/components/Tree.js +50 -143
- package/dist/components/UseIsVisible.js +5 -25
- package/dist/components/card/Card.js +35 -39
- package/dist/components/card/CardAvatar.js +21 -32
- package/dist/components/card/CardBody.js +29 -36
- package/dist/components/card/CardFooter.js +26 -35
- package/dist/components/card/CardHeader.js +29 -36
- package/dist/components/card/CardIcon.js +15 -29
- package/dist/components/card/CardText.js +15 -29
- package/dist/components/customInput/CustomInput.js +38 -40
- package/dist/components/dashboard/FoldingSideTabDashboard.js +65 -184
- package/dist/components/dashboard/SideMenuModuleDashboard.js +67 -185
- package/dist/components/dashboard/TopMenuModuleDashboard.js +22 -63
- package/dist/components/dashboard/components/Header.js +15 -52
- package/dist/components/dashboard/components/LeftDrawer.js +9 -23
- package/dist/components/dashboard/components/UserIdentity.js +4 -12
- package/dist/components/dashboard/components/blackDashboard/fixedPlugin/FixedPlugin.js +115 -155
- package/dist/components/dashboard/components/blackDashboard/sidebar/FoldingTabSidebar.js +344 -419
- package/dist/components/dashboard/components/blackDashboard/sidebar/ModuleMenu.js +15 -29
- package/dist/components/dashboard/components/blackDashboard/sidebar/ModuleMenuSidebar.js +405 -485
- package/dist/components/dashboard/components/portal/Timeline.js +3 -8
- package/dist/components/dashboard/components/portal/Workspace.js +4 -13
- package/dist/components/footer/Footer.js +23 -45
- package/dist/components/footer/HomeFooter.js +38 -78
- package/dist/components/form/AddressSearch.js +26 -76
- package/dist/components/form/AutoComplete.js +54 -168
- package/dist/components/form/BaseField.js +59 -189
- package/dist/components/form/Checkbox.js +11 -24
- package/dist/components/form/DatePicker.js +28 -82
- package/dist/components/form/FieldSet.js +84 -300
- package/dist/components/form/Form.js +206 -501
- package/dist/components/form/GridField.js +83 -243
- package/dist/components/form/IconField.js +10 -21
- package/dist/components/form/ImageEditor.js +98 -208
- package/dist/components/form/LabelField.js +13 -28
- package/dist/components/form/LookupField.js +36 -102
- package/dist/components/form/MultiFileUploadField.js +67 -134
- package/dist/components/form/RadioGroup.js +20 -57
- package/dist/components/form/Section.js +33 -118
- package/dist/components/form/SelectItem.js +36 -83
- package/dist/components/form/SignatureTemplateDesignerField.js +12 -26
- package/dist/components/form/Switch.js +11 -24
- package/dist/components/form/TextField.js +19 -55
- package/dist/components/form/TimePicker.js +18 -43
- package/dist/components/form/TransferList.js +76 -200
- package/dist/components/form/UploadField.js +134 -256
- package/dist/components/grid/GridContainer.js +10 -23
- package/dist/components/grid/GridItem.js +10 -23
- package/dist/components/layout/CollapsiblePanel.js +20 -59
- package/dist/components/layout/Layout.js +40 -149
- package/dist/components/layout/View.js +65 -195
- package/dist/components/layout/ViewContainer.js +13 -33
- package/dist/components/layout/ViewPort.js +14 -48
- package/dist/components/layout/Window.js +62 -135
- package/dist/components/layout/WindowViewPort.js +18 -63
- package/dist/components/media/ClosablePanel.js +9 -18
- package/dist/components/media/LobbyWaitingList.js +11 -17
- package/dist/components/media/MediaSoupHelper.js +173 -401
- package/dist/components/media/SideBarContent.js +17 -34
- package/dist/components/media/SocketRequest.js +7 -18
- package/dist/components/media/SocketResponse.js +5 -14
- package/dist/components/media/Timer.js +18 -54
- package/dist/components/media/Toolbar.js +97 -254
- package/dist/components/media/ToolbarButton.js +34 -95
- package/dist/components/media/Toolbar_bck.js +70 -186
- package/dist/components/media/Tracks.js +19 -33
- package/dist/components/media/TrainingRoom.js +121 -374
- package/dist/components/media/Transports.js +17 -29
- package/dist/components/media/VCEventManager.js +45 -116
- package/dist/components/media/VCEventType.js +82 -168
- package/dist/components/media/VCParticipantList.js +16 -51
- package/dist/components/media/VCParticipantListItem.js +44 -141
- package/dist/components/media/VCRoom.js +14 -58
- package/dist/components/media/VCRoomParticipant.js +235 -556
- package/dist/components/media/VCRoomRecorder.js +106 -204
- package/dist/components/media/VCRoomWorkspace.js +248 -584
- package/dist/components/media/Video.js +27 -112
- package/dist/components/media/VideoPlayer.js +23 -91
- package/dist/components/media/chat/ChatRoom.js +143 -361
- package/dist/components/media/chat/ChatRoomItem.js +17 -58
- package/dist/components/media/chat/ChatRoomList.js +15 -60
- package/dist/components/menu/CollapsibleMenu.js +22 -52
- package/dist/components/menu/MenuBars.js +50 -116
- package/dist/components/menu/MenuButton.js +53 -130
- package/dist/components/menu/MenuItem.js +11 -51
- package/dist/components/menu/MenuLink.js +13 -41
- package/dist/components/menu/PopupMenu.js +13 -25
- package/dist/components/navbars/AuthNavbar.js +21 -56
- package/dist/components/navbars/HomeNavbar.js +213 -290
- package/dist/components/navbars/PortalNavbar.js +26 -81
- package/dist/components/signatures/AgilitySignaturePanel.js +41 -135
- package/dist/components/signatures/AlertItem.js +14 -50
- package/dist/components/signatures/Card.js +6 -16
- package/dist/components/signatures/DocumentContainer.js +57 -165
- package/dist/components/signatures/ImageSignatureInput.js +64 -124
- package/dist/components/signatures/MenuButton.js +28 -63
- package/dist/components/signatures/Prompt.js +6 -41
- package/dist/components/signatures/ResponsiveTable.js +181 -370
- package/dist/components/signatures/SearchView.js +34 -112
- package/dist/components/signatures/SignatorySearch.js +11 -44
- package/dist/components/signatures/SignatorySearchForm.js +19 -50
- package/dist/components/signatures/SignatureInput.js +28 -91
- package/dist/components/signatures/SignatureInputProps.js +49 -144
- package/dist/components/signatures/SignatureTemplateDesigner.js +230 -430
- package/dist/components/signatures/Toolbar.js +99 -173
- package/dist/components/signatures/ViewUtils.js +207 -313
- package/dist/components/typography/Danger.js +6 -11
- package/dist/components/typography/Info.js +7 -11
- package/dist/components/typography/Link.js +6 -12
- package/dist/event/ActionHandlers.js +48 -87
- package/dist/event/Event.js +21 -25
- package/dist/event/EventListener.js +54 -48
- package/dist/event/EventType.js +18 -40
- package/dist/event/LoadDataActionHandler.js +10 -31
- package/dist/event/Observable.js +204 -396
- package/dist/event/RouteActionHandler.js +119 -171
- package/dist/event/ScriptActionHandler.js +10 -32
- package/dist/event/ServiceCallActionHandler.js +37 -64
- package/dist/event/SignalGraphActionHandler.js +9 -31
- package/dist/js/Addresses.js +23 -42
- package/dist/js/Calendar.js +41 -89
- package/dist/js/DynamicLib.js +11 -23
- package/dist/js/Media.js +80 -174
- package/dist/js/Validators.js +6 -12
- package/dist/js/Windows.js +22 -40
- package/dist/redux/store/ConfigureStore.js +12 -29
- package/dist/redux/store/DashboardStore.js +47 -120
- package/dist/redux/store/History.js +2 -5
- package/dist/redux/store/SecurityStore.js +22 -65
- package/dist/security/TokenManager.js +29 -53
- package/dist/theme-default.js +3 -8
- package/dist/view/Dashboard.js +140 -308
- package/dist/view/PortalDashboard.js +6 -13
- package/dist/view/Settings.js +3 -11
- package/dist/view/Views.js +15 -35
- package/dist/view/security/ChangePasswordBasic.js +41 -147
- package/dist/view/security/ForgotPassword.js +26 -106
- package/dist/view/security/ForgotPasswordBasic.js +22 -96
- package/dist/view/security/Login.js +29 -117
- package/dist/view/security/LoginBasic.js +28 -108
- package/dist/view/security/LoginInteractionPortal.js +28 -106
- package/dist/view/security/ResetPassword.js +25 -110
- package/dist/view/security/ResetPasswordBasic.js +39 -142
- package/dist/view/security/Security.js +14 -26
- package/package.json +26 -21
|
@@ -4,97 +4,92 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
-
|
|
8
7
|
var _rootStyle = require("../rootStyle");
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
15
|
-
|
|
16
|
-
var loginStyle = function loginStyle(theme) {
|
|
17
|
-
var _fullPage;
|
|
18
|
-
|
|
19
|
-
return {
|
|
20
|
-
container: _objectSpread(_objectSpread({}, _rootStyle.container), {}, _defineProperty({
|
|
21
|
-
zIndex: "4"
|
|
22
|
-
}, theme.breakpoints.down("sm"), {
|
|
8
|
+
const loginStyle = theme => ({
|
|
9
|
+
container: {
|
|
10
|
+
..._rootStyle.container,
|
|
11
|
+
zIndex: "4",
|
|
12
|
+
[theme.breakpoints.down("sm")]: {
|
|
23
13
|
paddingBottom: "100px"
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
right: {
|
|
17
|
+
margin: "0",
|
|
18
|
+
fontSize: "12px",
|
|
19
|
+
float: "right!important",
|
|
20
|
+
color: "#d32f2f"
|
|
21
|
+
},
|
|
22
|
+
cardTitle: {
|
|
23
|
+
..._rootStyle.cardTitle,
|
|
24
|
+
color: _rootStyle.whiteColor
|
|
25
|
+
},
|
|
26
|
+
loader: {
|
|
27
|
+
width: "100%",
|
|
28
|
+
height: "100",
|
|
29
|
+
display: "flex",
|
|
30
|
+
justifyContent: "center",
|
|
31
|
+
alignItems: "center"
|
|
32
|
+
},
|
|
33
|
+
textCenter: {
|
|
34
|
+
textAlign: "center"
|
|
35
|
+
},
|
|
36
|
+
justifyContentCenter: {
|
|
37
|
+
justifyContent: "center !important"
|
|
38
|
+
},
|
|
39
|
+
customButtonClass: {
|
|
40
|
+
"&,&:focus,&:hover": {
|
|
32
41
|
color: _rootStyle.whiteColor
|
|
33
|
-
}),
|
|
34
|
-
loader: {
|
|
35
|
-
width: "100%",
|
|
36
|
-
height: "100",
|
|
37
|
-
display: "flex",
|
|
38
|
-
justifyContent: "center",
|
|
39
|
-
alignItems: "center"
|
|
40
|
-
},
|
|
41
|
-
textCenter: {
|
|
42
|
-
textAlign: "center"
|
|
43
|
-
},
|
|
44
|
-
justifyContentCenter: {
|
|
45
|
-
justifyContent: "center !important"
|
|
46
|
-
},
|
|
47
|
-
customButtonClass: {
|
|
48
|
-
"&,&:focus,&:hover": {
|
|
49
|
-
color: _rootStyle.whiteColor
|
|
50
|
-
},
|
|
51
|
-
marginLeft: "5px",
|
|
52
|
-
marginRight: "5px"
|
|
53
42
|
},
|
|
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
|
-
|
|
43
|
+
marginLeft: "5px",
|
|
44
|
+
marginRight: "5px"
|
|
45
|
+
},
|
|
46
|
+
inputAdornment: {
|
|
47
|
+
marginRight: "18px"
|
|
48
|
+
},
|
|
49
|
+
inputAdornmentIcon: {
|
|
50
|
+
color: _rootStyle.grayColor[6]
|
|
51
|
+
},
|
|
52
|
+
cardHidden: {
|
|
53
|
+
opacity: "0",
|
|
54
|
+
transform: "translate3d(0, -60px, 0)"
|
|
55
|
+
},
|
|
56
|
+
cardHeader: {
|
|
57
|
+
marginBottom: "20px"
|
|
58
|
+
},
|
|
59
|
+
socialLine: {
|
|
60
|
+
padding: "0.9375rem 0"
|
|
61
|
+
},
|
|
62
|
+
wrapper: {
|
|
63
|
+
height: "auto",
|
|
64
|
+
minHeight: "100vh",
|
|
65
|
+
position: "relative",
|
|
66
|
+
top: "0"
|
|
67
|
+
},
|
|
68
|
+
fullPage: {
|
|
69
|
+
padding: "120px 0",
|
|
70
|
+
position: "relative",
|
|
71
|
+
minHeight: "100vh",
|
|
72
|
+
display: "flex!important",
|
|
73
|
+
margin: "0",
|
|
74
|
+
border: "0",
|
|
75
|
+
color: _rootStyle.whiteColor,
|
|
76
|
+
alignItems: "center",
|
|
77
|
+
backgroundSize: "cover",
|
|
78
|
+
backgroundPosition: "center center",
|
|
79
|
+
height: "100%",
|
|
80
|
+
[theme.breakpoints.down("sm")]: {
|
|
89
81
|
minHeight: "700px!important"
|
|
90
|
-
}
|
|
82
|
+
},
|
|
83
|
+
"& footer": {
|
|
91
84
|
position: "absolute",
|
|
92
85
|
bottom: "0",
|
|
93
86
|
width: "100%",
|
|
94
87
|
border: "none !important"
|
|
95
|
-
}
|
|
88
|
+
},
|
|
89
|
+
"&:before": {
|
|
96
90
|
backgroundColor: "rgba(" + (0, _rootStyle.hexToRgb)(_rootStyle.blackColor) + ", 0.65)"
|
|
97
|
-
}
|
|
91
|
+
},
|
|
92
|
+
"&:before,&:after": {
|
|
98
93
|
display: "block",
|
|
99
94
|
content: '""',
|
|
100
95
|
position: "absolute",
|
|
@@ -103,9 +98,7 @@ var loginStyle = function loginStyle(theme) {
|
|
|
103
98
|
top: "0",
|
|
104
99
|
left: "0",
|
|
105
100
|
zIndex: "2"
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
};
|
|
109
|
-
|
|
110
|
-
var _default = loginStyle;
|
|
111
|
-
exports.default = _default;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
});
|
|
104
|
+
var _default = exports.default = loginStyle;
|
|
@@ -4,113 +4,62 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
-
|
|
8
7
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
-
|
|
10
8
|
var _Utils = _interopRequireDefault(require("../Utils"));
|
|
11
|
-
|
|
12
9
|
var _Alert = _interopRequireDefault(require("react-bootstrap/Alert"));
|
|
13
|
-
|
|
14
10
|
var _EventType = _interopRequireDefault(require("../event/EventType"));
|
|
15
|
-
|
|
16
11
|
var _Observable = _interopRequireDefault(require("../event/Observable"));
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
23
|
-
|
|
24
|
-
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."); }
|
|
25
|
-
|
|
26
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
27
|
-
|
|
28
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
29
|
-
|
|
30
|
-
function _iterableToArrayLimit(arr, i) { if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
31
|
-
|
|
32
|
-
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
33
|
-
|
|
34
|
-
var AlertBar = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
35
|
-
var _React$useState = _react.default.useState(props.config.message),
|
|
36
|
-
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
37
|
-
message = _React$useState2[0],
|
|
38
|
-
setMessage = _React$useState2[1];
|
|
39
|
-
|
|
40
|
-
var _React$useState3 = _react.default.useState(props.config.variant ? props.config.variant : 'info'),
|
|
41
|
-
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
|
42
|
-
variant = _React$useState4[0],
|
|
43
|
-
setVariant = _React$useState4[1];
|
|
44
|
-
|
|
45
|
-
_react.default.useEffect(function () {
|
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
|
+
const AlertBar = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_react.default.forwardRef((props, ref) => {
|
|
14
|
+
const [message, setMessage] = _react.default.useState(props.config.message);
|
|
15
|
+
const [variant, setVariant] = _react.default.useState(props.config.variant ? props.config.variant : 'info');
|
|
16
|
+
_react.default.useEffect(() => {
|
|
46
17
|
props.handle.api = api();
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
var eventHandlingConfig = _Utils.default.isNull(parsedConfig.eventHandlingConfig) ? {} : parsedConfig.eventHandlingConfig;
|
|
51
|
-
var defaultAction = {
|
|
18
|
+
let parsedConfig = _Utils.default.parseConfig(props.config, props.viewId);
|
|
19
|
+
let eventHandlingConfig = _Utils.default.isNull(parsedConfig.eventHandlingConfig) ? {} : parsedConfig.eventHandlingConfig;
|
|
20
|
+
let defaultAction = {
|
|
52
21
|
actionType: 'script',
|
|
53
22
|
script: {
|
|
54
|
-
lines: [
|
|
23
|
+
lines: [`@#{${props.config.id}}.message = $event.data.message`, `@#{${props.config.id}}.variant = $event.data.messageType === 'ERROR' ? 'danger' : $event.data.messageType === 'WARN' ? 'warning' : $event.data.messageType === 'SUCCESS' ? 'success' : 'info' `]
|
|
55
24
|
}
|
|
56
25
|
};
|
|
57
|
-
|
|
58
26
|
if (_Utils.default.isNull(eventHandlingConfig.subscriptions)) {
|
|
59
27
|
// Add default subscription
|
|
60
28
|
eventHandlingConfig.subscriptions = [];
|
|
61
|
-
|
|
29
|
+
let subscription = {
|
|
62
30
|
publisher: 'applicationManager',
|
|
63
31
|
eventType: _EventType.default.MESSAGE_ARRIVED,
|
|
64
32
|
actions: [defaultAction]
|
|
65
33
|
};
|
|
66
34
|
eventHandlingConfig.subscriptions.push(subscription);
|
|
67
35
|
} else {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
if (_Utils.default.isNull(_subscription.actions)) {
|
|
76
|
-
_subscription.actions = [];
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
if (_subscription.actions.length === 0) {
|
|
80
|
-
_subscription.actions.push(defaultAction);
|
|
81
|
-
}
|
|
36
|
+
for (const subscription of eventHandlingConfig.subscriptions) {
|
|
37
|
+
if (_Utils.default.isNull(subscription.actions)) {
|
|
38
|
+
subscription.actions = [];
|
|
39
|
+
}
|
|
40
|
+
if (subscription.actions.length === 0) {
|
|
41
|
+
subscription.actions.push(defaultAction);
|
|
82
42
|
}
|
|
83
|
-
} catch (err) {
|
|
84
|
-
_iterator.e(err);
|
|
85
|
-
} finally {
|
|
86
|
-
_iterator.f();
|
|
87
43
|
}
|
|
88
44
|
}
|
|
89
|
-
|
|
90
45
|
_Observable.default.addSubscriptions(eventHandlingConfig, props.handle, props.viewId);
|
|
91
46
|
}, []);
|
|
92
|
-
|
|
93
|
-
var api = function api() {
|
|
47
|
+
const api = () => {
|
|
94
48
|
return {
|
|
95
49
|
get id() {
|
|
96
50
|
return props.config.id;
|
|
97
51
|
},
|
|
98
|
-
|
|
99
52
|
set message(message) {
|
|
100
53
|
setMessage(message);
|
|
101
54
|
},
|
|
102
|
-
|
|
103
|
-
getChildren: function getChildren() {
|
|
55
|
+
getChildren: () => {
|
|
104
56
|
return [];
|
|
105
57
|
},
|
|
106
|
-
|
|
107
58
|
set variant(variant) {
|
|
108
59
|
setVariant(variant);
|
|
109
60
|
}
|
|
110
|
-
|
|
111
61
|
};
|
|
112
62
|
};
|
|
113
|
-
|
|
114
63
|
return !_Utils.default.isNull(props.config) ? /*#__PURE__*/_react.default.createElement("div", {
|
|
115
64
|
style: _Utils.default.mergeStyles({
|
|
116
65
|
padding: '0 32px 0 32px',
|
|
@@ -119,9 +68,7 @@ var AlertBar = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_react.default.for
|
|
|
119
68
|
}, /*#__PURE__*/_react.default.createElement(_Alert.default, {
|
|
120
69
|
variant: variant,
|
|
121
70
|
show: !_Utils.default.isNull(message),
|
|
122
|
-
onClose:
|
|
123
|
-
return setMessage(null);
|
|
124
|
-
},
|
|
71
|
+
onClose: () => setMessage(null),
|
|
125
72
|
dismissible: true,
|
|
126
73
|
style: {
|
|
127
74
|
with: '100%'
|
|
@@ -132,6 +79,4 @@ var AlertBar = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_react.default.for
|
|
|
132
79
|
}
|
|
133
80
|
}, message))) : null;
|
|
134
81
|
}));
|
|
135
|
-
|
|
136
|
-
var _default = AlertBar;
|
|
137
|
-
exports.default = _default;
|
|
82
|
+
var _default = exports.default = AlertBar;
|
|
@@ -4,66 +4,30 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = AlertItem;
|
|
7
|
-
|
|
8
7
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
-
|
|
10
8
|
var _Alert = _interopRequireDefault(require("@material-ui/lab/Alert"));
|
|
11
|
-
|
|
12
9
|
var _AlertTitle = _interopRequireDefault(require("@material-ui/lab/AlertTitle"));
|
|
13
|
-
|
|
14
10
|
var _styles = require("@material-ui/core/styles");
|
|
15
|
-
|
|
16
11
|
var _Utils = _interopRequireDefault(require("../Utils"));
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
25
|
-
|
|
26
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
27
|
-
|
|
28
|
-
function _iterableToArrayLimit(arr, i) { if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
29
|
-
|
|
30
|
-
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
31
|
-
|
|
32
|
-
var useStyles = (0, _styles.makeStyles)(function (theme) {
|
|
33
|
-
return {
|
|
34
|
-
root: {
|
|
35
|
-
width: '100%',
|
|
36
|
-
'& > * + *': {
|
|
37
|
-
marginTop: theme.spacing(2)
|
|
38
|
-
}
|
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
|
+
const useStyles = (0, _styles.makeStyles)(theme => ({
|
|
14
|
+
root: {
|
|
15
|
+
width: '100%',
|
|
16
|
+
'& > * + *': {
|
|
17
|
+
marginTop: theme.spacing(2)
|
|
39
18
|
}
|
|
40
|
-
}
|
|
41
|
-
});
|
|
42
|
-
|
|
19
|
+
}
|
|
20
|
+
}));
|
|
43
21
|
function AlertItem(props) {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
setMessage = _React$useState2[1];
|
|
50
|
-
|
|
51
|
-
var _React$useState3 = _react.default.useState(props.alertStyle),
|
|
52
|
-
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
|
53
|
-
alertStyle = _React$useState4[0],
|
|
54
|
-
setAlertStyle = _React$useState4[1];
|
|
55
|
-
|
|
56
|
-
var _React$useState5 = _react.default.useState(props.alertTitle),
|
|
57
|
-
_React$useState6 = _slicedToArray(_React$useState5, 2),
|
|
58
|
-
title = _React$useState6[0],
|
|
59
|
-
setTitle = _React$useState6[1];
|
|
60
|
-
|
|
61
|
-
_react.default.useEffect(function () {
|
|
22
|
+
const classes = useStyles();
|
|
23
|
+
const [message, setMessage] = _react.default.useState(props.message);
|
|
24
|
+
const [alertStyle, setAlertStyle] = _react.default.useState(props.alertStyle);
|
|
25
|
+
const [title, setTitle] = _react.default.useState(props.alertTitle);
|
|
26
|
+
_react.default.useEffect(() => {
|
|
62
27
|
setMessage(props.message);
|
|
63
28
|
setAlertStyle(props.alertStyle);
|
|
64
29
|
setTitle(props.alertTitle);
|
|
65
30
|
}, [props.message, props.alertStyle, props.alertTitle]);
|
|
66
|
-
|
|
67
31
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
68
32
|
className: classes.root
|
|
69
33
|
}, !_Utils.default.isNull(message) && message.trim().length > 0 ? /*#__PURE__*/_react.default.createElement(_Alert.default, {
|
|
@@ -3,13 +3,10 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.
|
|
7
|
-
|
|
6
|
+
exports.options = exports.default = exports.AlertTemplate = exports.AlertStyle = void 0;
|
|
8
7
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
var AlertStyle = {
|
|
8
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
9
|
+
const AlertStyle = exports.AlertStyle = {
|
|
13
10
|
backgroundColor: '#dc3545',
|
|
14
11
|
color: 'white',
|
|
15
12
|
padding: '10px',
|
|
@@ -24,15 +21,14 @@ var AlertStyle = {
|
|
|
24
21
|
boxSizing: 'border-box',
|
|
25
22
|
margin: '30px'
|
|
26
23
|
};
|
|
27
|
-
|
|
28
|
-
var alertButtonStyle = {
|
|
24
|
+
const alertButtonStyle = {
|
|
29
25
|
marginLeft: '20px',
|
|
30
26
|
border: 'none',
|
|
31
27
|
backgroundColor: 'transparent',
|
|
32
28
|
cursor: 'pointer',
|
|
33
29
|
color: 'rgb(255, 255, 255)'
|
|
34
30
|
};
|
|
35
|
-
|
|
31
|
+
const options = exports.options = {
|
|
36
32
|
position: 'top center',
|
|
37
33
|
timeout: 0,
|
|
38
34
|
offset: '30px',
|
|
@@ -41,12 +37,12 @@ var options = {
|
|
|
41
37
|
marginTop: '260px'
|
|
42
38
|
}
|
|
43
39
|
};
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
40
|
+
const AlertTemplate = _ref => {
|
|
41
|
+
let {
|
|
42
|
+
options,
|
|
43
|
+
message,
|
|
44
|
+
close
|
|
45
|
+
} = _ref;
|
|
50
46
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
51
47
|
style: AlertStyle
|
|
52
48
|
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
@@ -70,7 +66,5 @@ var AlertTemplate = function AlertTemplate(_ref) {
|
|
|
70
66
|
onClick: close
|
|
71
67
|
}, "X"));
|
|
72
68
|
};
|
|
73
|
-
|
|
74
69
|
exports.AlertTemplate = AlertTemplate;
|
|
75
|
-
var _default = AlertTemplate;
|
|
76
|
-
exports.default = _default;
|
|
70
|
+
var _default = exports.default = AlertTemplate;
|