@agilemotion/oui-react-js 1.6.0 → 1.6.2
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 +698 -421
- package/dist/BasicApp.js +5 -5
- package/dist/BasicAppHome.js +55 -26
- package/dist/DynamicJS.js +147 -65
- package/dist/InteractionPortalApp.css +1 -1
- package/dist/InteractionPortalApp.js +5 -5
- package/dist/InteractionPortalAppHome.js +65 -18
- package/dist/InteractionPortalApp_old.js +107 -61
- package/dist/RestUtils.js +339 -287
- package/dist/TypedValue.js +18 -15
- package/dist/Utils.js +375 -276
- package/dist/WithRouter.js +6 -6
- package/dist/assets/jss/components/authNavbarStyle.js +166 -164
- package/dist/assets/jss/components/buttonStyle.js +1 -1
- package/dist/assets/jss/components/cardAvatarStyle.js +1 -1
- package/dist/assets/jss/components/cardBodyStyle.js +1 -1
- package/dist/assets/jss/components/cardFooterStyle.js +1 -1
- package/dist/assets/jss/components/cardHeaderStyle.js +13 -13
- package/dist/assets/jss/components/cardIconStyle.js +1 -1
- package/dist/assets/jss/components/cardStyle.js +1 -1
- package/dist/assets/jss/components/cardTextStyle.js +1 -1
- package/dist/assets/jss/components/customDropdownStyle.js +168 -169
- package/dist/assets/jss/components/customInputStyle.js +9 -3
- package/dist/assets/jss/components/dropdownStyle.js +69 -69
- package/dist/assets/jss/components/footerStyle.js +19 -13
- package/dist/assets/jss/components/headerLinksStyle.js +45 -48
- package/dist/assets/jss/components/headerStyle.js +68 -65
- package/dist/assets/jss/components/navbarLinksStyle.js +66 -77
- package/dist/assets/jss/components/navbarStyle.js +79 -76
- package/dist/assets/jss/components/sidebarStyle.js +436 -436
- package/dist/assets/jss/components/typographyStyle.js +9 -3
- package/dist/assets/jss/rootStyle.js +96 -81
- package/dist/assets/jss/views/layoutStyle.js +44 -41
- package/dist/assets/jss/views/loginBasicStyle.js +1 -1
- package/dist/assets/jss/views/loginBusinessPortalStyle.js +1 -1
- package/dist/assets/jss/views/loginStyle.js +82 -77
- package/dist/components/AlertBar.js +50 -17
- package/dist/components/AlertItem.js +35 -12
- package/dist/components/AlertTemplate.js +30 -29
- package/dist/components/Button.js +62 -34
- package/dist/components/Calendar.js +140 -91
- package/dist/components/ConfirmationDialog.js +36 -11
- package/dist/components/DataGrid.js +512 -270
- package/dist/components/DataGridColumn.js +47 -22
- package/dist/components/DataGridFilter.js +186 -105
- package/dist/components/DataGridHeading.js +50 -32
- package/dist/components/Dialog.js +90 -35
- package/dist/components/DocumentTemplateDesigner.js +34 -16
- package/dist/components/DocumentTemplateDesignerComponent.css +0 -157
- package/dist/components/DocumentTemplateDesignerComponent.js +118 -62
- package/dist/components/DocumentTemplatePlaceholderDialog.js +52 -30
- package/dist/components/DocumentViewer.js +34 -18
- package/dist/components/DocumentViewerComponent.js +26 -9
- package/dist/components/ElementResizeHandler.js +229 -207
- package/dist/components/FileThumb.js +32 -10
- package/dist/components/Graph.js +153 -85
- package/dist/components/GraphNode.js +58 -38
- package/dist/components/HtmlPanel.js +67 -39
- package/dist/components/Icon.js +206 -166
- package/dist/components/LoadingIndicator.js +3 -3
- package/dist/components/LottieIcon.js +1 -1
- package/dist/components/PopupView.js +39 -19
- package/dist/components/Portlet.js +35 -19
- package/dist/components/RegularButton.js +28 -32
- package/dist/components/SignaturePanel.js +37 -17
- package/dist/components/SocketManager.js +178 -119
- package/dist/components/StepperTitleBar.js +62 -42
- package/dist/components/TabPage.js +30 -25
- package/dist/components/TabPanel.js +86 -33
- package/dist/components/TableCellContent.js +51 -32
- package/dist/components/TemplateDesigner.js +173 -121
- package/dist/components/TemplateItemEventHandler.js +335 -221
- package/dist/components/TemplateTable.js +183 -118
- package/dist/components/TitleBar.js +26 -11
- package/dist/components/Toolbar.js +67 -38
- package/dist/components/Tooltip.js +43 -35
- package/dist/components/Tree.js +85 -44
- package/dist/components/UseIsVisible.js +25 -4
- package/dist/components/card/Card.js +27 -33
- package/dist/components/card/CardAvatar.js +20 -19
- package/dist/components/card/CardBody.js +24 -27
- package/dist/components/card/CardFooter.js +23 -24
- package/dist/components/card/CardHeader.js +24 -27
- package/dist/components/card/CardIcon.js +17 -13
- package/dist/components/card/CardText.js +17 -13
- package/dist/components/customInput/CustomInput.js +22 -36
- package/dist/components/dashboard/{BasicBusinessAppDashboard.js → FoldingSideTabDashboard.js} +111 -63
- package/dist/components/dashboard/SideMenuModuleDashboard.css +60 -0
- package/dist/components/dashboard/SideMenuModuleDashboard.js +423 -0
- package/dist/components/dashboard/TopMenuModuleDashboard.js +138 -0
- package/dist/components/dashboard/components/Header.js +29 -12
- package/dist/components/dashboard/components/LeftDrawer.js +3 -5
- package/dist/components/dashboard/components/UserIdentity.js +2 -2
- package/dist/components/dashboard/components/blackDashboard/fixedPlugin/FixedPlugin.js +131 -87
- package/dist/components/dashboard/components/blackDashboard/sidebar/FoldingTabSidebar.js +488 -0
- package/dist/components/dashboard/components/blackDashboard/sidebar/ModuleMenu.js +64 -0
- package/dist/components/dashboard/components/blackDashboard/sidebar/ModuleMenuSidebar.css +65 -0
- package/dist/components/dashboard/components/blackDashboard/sidebar/ModuleMenuSidebar.js +556 -0
- package/dist/components/dashboard/components/portal/Timeline.js +1 -1
- package/dist/components/dashboard/components/portal/Workspace.js +5 -11
- package/dist/components/footer/Footer.js +31 -24
- package/dist/components/footer/HomeFooter.js +68 -34
- package/dist/components/form/AddressSearch.js +78 -42
- package/dist/components/form/AutoComplete.js +136 -55
- package/dist/components/form/BaseField.js +108 -56
- package/dist/components/form/Checkbox.js +10 -8
- package/dist/components/form/DatePicker.js +47 -25
- package/dist/components/form/FieldSet.js +217 -84
- package/dist/components/form/Form.js +334 -200
- package/dist/components/form/GridField.js +185 -82
- package/dist/components/form/IconField.js +9 -7
- package/dist/components/form/ImageEditor.js +141 -92
- package/dist/components/form/LabelField.js +12 -10
- package/dist/components/form/LookupField.js +54 -32
- package/dist/components/form/MultiFileUploadField.js +101 -67
- package/dist/components/form/RadioGroup.js +33 -16
- package/dist/components/form/Section.js +84 -34
- package/dist/components/form/SelectItem.js +55 -33
- package/dist/components/form/SignatureTemplateDesignerField.js +11 -9
- package/dist/components/form/Switch.js +10 -8
- package/dist/components/form/TextField.js +34 -16
- package/dist/components/form/TimePicker.js +19 -15
- package/dist/components/form/TransferList.js +153 -75
- package/dist/components/form/UploadField.js +183 -128
- package/dist/components/grid/GridContainer.js +12 -8
- package/dist/components/grid/GridItem.js +12 -8
- package/dist/components/layout/CollapsiblePanel.js +44 -18
- package/dist/components/layout/Layout.js +81 -40
- package/dist/components/layout/VC.css +1 -1
- package/dist/components/layout/View.js +136 -62
- package/dist/components/layout/ViewContainer.js +13 -11
- package/dist/components/layout/ViewPort.js +25 -10
- package/dist/components/layout/Window.js +87 -53
- package/dist/components/layout/WindowViewPort.js +38 -16
- package/dist/components/media/ClosablePanel.js +7 -7
- package/dist/components/media/LobbyWaitingList.js +7 -9
- package/dist/components/media/MediaSoupHelper.js +379 -187
- package/dist/components/media/SideBarContent.js +22 -14
- package/dist/components/media/SocketRequest.js +5 -1
- package/dist/components/media/SocketResponse.js +5 -1
- package/dist/components/media/Timer.js +35 -15
- package/dist/components/media/Toolbar.css +5 -0
- package/dist/components/media/Toolbar.js +220 -102
- package/dist/components/media/ToolbarButton.js +82 -33
- package/dist/components/media/Toolbar_bck.js +142 -70
- package/dist/components/media/Tracks.js +31 -28
- package/dist/components/media/TrainingRoom.js +284 -121
- package/dist/components/media/Transports.js +27 -24
- package/dist/components/media/VCEventManager.js +95 -31
- package/dist/components/media/VCEventType.js +5 -1
- package/dist/components/media/VCParticipantList.js +40 -14
- package/dist/components/media/VCParticipantListItem.js +92 -41
- package/dist/components/media/VCRoom.js +29 -11
- package/dist/components/media/VCRoomParticipant.js +488 -242
- package/dist/components/media/VCRoomRecorder.js +236 -175
- package/dist/components/media/VCRoomWorkspace.js +505 -245
- package/dist/components/media/Video.js +89 -25
- package/dist/components/media/VideoPlayer.js +56 -22
- package/dist/components/media/chat/ChatRoom.js +255 -132
- package/dist/components/media/chat/ChatRoomItem.js +35 -14
- package/dist/components/media/chat/ChatRoomList.js +43 -13
- package/dist/components/menu/CollapsibleMenu.js +39 -20
- package/dist/components/menu/MenuBars.js +81 -48
- package/dist/components/menu/MenuButton.js +95 -60
- package/dist/components/menu/MenuItem.js +28 -9
- package/dist/components/menu/MenuLink.js +12 -10
- package/dist/components/menu/PopupMenu.js +16 -12
- package/dist/components/navbars/AuthNavbar.js +27 -18
- package/dist/components/navbars/HomeNavbar.js +243 -194
- package/dist/components/navbars/PortalNavbar.js +50 -26
- package/dist/components/signatures/AgilitySignaturePanel.js +96 -39
- package/dist/components/signatures/AlertItem.js +36 -13
- package/dist/components/signatures/Card.js +4 -4
- package/dist/components/signatures/DocumentContainer.js +141 -57
- package/dist/components/signatures/ImageSignatureInput.js +90 -59
- package/dist/components/signatures/MenuButton.js +53 -33
- package/dist/components/signatures/Prompt.js +26 -5
- package/dist/components/signatures/ResponsiveTable.js +302 -197
- package/dist/components/signatures/SearchView.js +77 -36
- package/dist/components/signatures/SignatorySearch.js +30 -10
- package/dist/components/signatures/SignatorySearchForm.js +35 -18
- package/dist/components/signatures/SignatureInput.js +56 -26
- package/dist/components/signatures/SignatureInputProps.js +107 -55
- package/dist/components/signatures/SignatureTemplateDesigner.js +340 -235
- package/dist/components/signatures/Toolbar.js +135 -94
- package/dist/components/signatures/ViewUtils.js +273 -224
- package/dist/components/typography/Danger.js +3 -5
- package/dist/components/typography/Info.js +3 -5
- package/dist/components/typography/Link.js +3 -5
- package/dist/event/ActionHandlers.js +57 -43
- package/dist/event/Event.js +16 -13
- package/dist/event/EventListener.js +39 -36
- package/dist/event/EventType.js +5 -1
- package/dist/event/LoadDataActionHandler.js +20 -8
- package/dist/event/Observable.js +323 -142
- package/dist/event/RouteActionHandler.js +139 -125
- package/dist/event/ScriptActionHandler.js +20 -8
- package/dist/event/ServiceCallActionHandler.js +51 -39
- package/dist/event/SignalGraphActionHandler.js +19 -7
- package/dist/js/Addresses.js +38 -24
- package/dist/js/Calendar.js +168 -161
- package/dist/js/DynamicLib.js +14 -11
- package/dist/js/Media.js +213 -120
- package/dist/js/Validators.js +6 -5
- package/dist/js/Windows.js +48 -47
- package/dist/redux/store/ConfigureStore.js +17 -9
- package/dist/redux/store/DashboardStore.js +110 -43
- package/dist/redux/store/History.js +1 -1
- package/dist/redux/store/SecurityStore.js +59 -20
- package/dist/security/TokenManager.js +44 -30
- package/dist/theme-default.js +1 -1
- package/dist/view/Dashboard.js +230 -137
- package/dist/view/PortalDashboard.js +5 -5
- package/dist/view/Settings.js +4 -2
- package/dist/view/Views.js +27 -14
- package/dist/view/security/ChangePasswordBasic.js +97 -40
- package/dist/view/security/ForgotPassword.js +59 -22
- package/dist/view/security/ForgotPasswordBasic.js +62 -21
- package/dist/view/security/Login.js +64 -24
- package/dist/view/security/LoginBasic.js +65 -26
- package/dist/view/security/LoginInteractionPortal.js +62 -25
- package/dist/view/security/ResetPassword.js +65 -23
- package/dist/view/security/ResetPasswordBasic.js +91 -37
- package/dist/view/security/Security.js +12 -12
- package/package.json +1 -2
- package/dist/components/dashboard/BusinessPortalAppDashboard.js +0 -154
- package/dist/components/dashboard/components/blackDashboard/sidebar/Sidebar.js +0 -447
- /package/dist/components/dashboard/{BusinessPortalAppDashboard.css → TopMenuModuleDashboard.css} +0 -0
- /package/dist/components/dashboard/components/blackDashboard/sidebar/{Sidebar.css → FoldingTabSidebar.css} +0 -0
|
@@ -17,18 +17,38 @@ var _Observable = _interopRequireDefault(require("../event/Observable"));
|
|
|
17
17
|
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
19
|
|
|
20
|
-
|
|
21
|
-
const [message, setMessage] = _react.default.useState(props.config.message);
|
|
20
|
+
function _createForOfIteratorHelper(o, allowArrayLike) { var it; if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e2) { throw _e2; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e3) { didErr = true; err = _e3; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
|
|
22
21
|
|
|
23
|
-
|
|
22
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
24
23
|
|
|
25
|
-
|
|
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 () {
|
|
26
46
|
props.handle.api = api();
|
|
27
47
|
|
|
28
|
-
|
|
48
|
+
var parsedConfig = _Utils.default.parseConfig(props.config, props.viewId);
|
|
29
49
|
|
|
30
|
-
|
|
31
|
-
|
|
50
|
+
var eventHandlingConfig = _Utils.default.isNull(parsedConfig.eventHandlingConfig) ? {} : parsedConfig.eventHandlingConfig;
|
|
51
|
+
var defaultAction = {
|
|
32
52
|
actionType: 'script',
|
|
33
53
|
script: {
|
|
34
54
|
lines: ["@#{".concat(props.config.id, "}.message = $event.data.message"), "@#{".concat(props.config.id, "}.variant = $event.data.messageType === 'ERROR' ? 'danger' : $event.data.messageType === 'WARN' ? 'warning' : $event.data.messageType === 'SUCCESS' ? 'success' : 'info' ")]
|
|
@@ -38,28 +58,39 @@ const AlertBar = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_react.default.f
|
|
|
38
58
|
if (_Utils.default.isNull(eventHandlingConfig.subscriptions)) {
|
|
39
59
|
// Add default subscription
|
|
40
60
|
eventHandlingConfig.subscriptions = [];
|
|
41
|
-
|
|
61
|
+
var subscription = {
|
|
42
62
|
publisher: 'applicationManager',
|
|
43
63
|
eventType: _EventType.default.MESSAGE_ARRIVED,
|
|
44
64
|
actions: [defaultAction]
|
|
45
65
|
};
|
|
46
66
|
eventHandlingConfig.subscriptions.push(subscription);
|
|
47
67
|
} else {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
68
|
+
var _iterator = _createForOfIteratorHelper(eventHandlingConfig.subscriptions),
|
|
69
|
+
_step;
|
|
70
|
+
|
|
71
|
+
try {
|
|
72
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
73
|
+
var _subscription = _step.value;
|
|
74
|
+
|
|
75
|
+
if (_Utils.default.isNull(_subscription.actions)) {
|
|
76
|
+
_subscription.actions = [];
|
|
77
|
+
}
|
|
52
78
|
|
|
53
|
-
|
|
54
|
-
|
|
79
|
+
if (_subscription.actions.length === 0) {
|
|
80
|
+
_subscription.actions.push(defaultAction);
|
|
81
|
+
}
|
|
55
82
|
}
|
|
83
|
+
} catch (err) {
|
|
84
|
+
_iterator.e(err);
|
|
85
|
+
} finally {
|
|
86
|
+
_iterator.f();
|
|
56
87
|
}
|
|
57
88
|
}
|
|
58
89
|
|
|
59
90
|
_Observable.default.addSubscriptions(eventHandlingConfig, props.handle, props.viewId);
|
|
60
91
|
}, []);
|
|
61
92
|
|
|
62
|
-
|
|
93
|
+
var api = function api() {
|
|
63
94
|
return {
|
|
64
95
|
get id() {
|
|
65
96
|
return props.config.id;
|
|
@@ -69,7 +100,7 @@ const AlertBar = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_react.default.f
|
|
|
69
100
|
setMessage(message);
|
|
70
101
|
},
|
|
71
102
|
|
|
72
|
-
getChildren: ()
|
|
103
|
+
getChildren: function getChildren() {
|
|
73
104
|
return [];
|
|
74
105
|
},
|
|
75
106
|
|
|
@@ -88,7 +119,9 @@ const AlertBar = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_react.default.f
|
|
|
88
119
|
}, /*#__PURE__*/_react.default.createElement(_Alert.default, {
|
|
89
120
|
variant: variant,
|
|
90
121
|
show: !_Utils.default.isNull(message),
|
|
91
|
-
onClose: ()
|
|
122
|
+
onClose: function onClose() {
|
|
123
|
+
return setMessage(null);
|
|
124
|
+
},
|
|
92
125
|
dismissible: true,
|
|
93
126
|
style: {
|
|
94
127
|
with: '100%'
|
|
@@ -17,25 +17,48 @@ var _Utils = _interopRequireDefault(require("../Utils"));
|
|
|
17
17
|
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
19
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
20
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
21
|
+
|
|
22
|
+
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."); }
|
|
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
|
+
}
|
|
25
39
|
}
|
|
26
|
-
}
|
|
27
|
-
})
|
|
40
|
+
};
|
|
41
|
+
});
|
|
28
42
|
|
|
29
43
|
function AlertItem(props) {
|
|
30
|
-
|
|
44
|
+
var classes = useStyles();
|
|
31
45
|
|
|
32
|
-
|
|
46
|
+
var _React$useState = _react.default.useState(props.message),
|
|
47
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
48
|
+
message = _React$useState2[0],
|
|
49
|
+
setMessage = _React$useState2[1];
|
|
33
50
|
|
|
34
|
-
|
|
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];
|
|
35
55
|
|
|
36
|
-
|
|
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];
|
|
37
60
|
|
|
38
|
-
_react.default.useEffect(()
|
|
61
|
+
_react.default.useEffect(function () {
|
|
39
62
|
setMessage(props.message);
|
|
40
63
|
setAlertStyle(props.alertStyle);
|
|
41
64
|
setTitle(props.alertTitle);
|
|
@@ -9,7 +9,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
9
9
|
|
|
10
10
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
var AlertStyle = {
|
|
13
13
|
backgroundColor: '#dc3545',
|
|
14
14
|
color: 'white',
|
|
15
15
|
padding: '10px',
|
|
@@ -25,14 +25,14 @@ const AlertStyle = {
|
|
|
25
25
|
margin: '30px'
|
|
26
26
|
};
|
|
27
27
|
exports.AlertStyle = AlertStyle;
|
|
28
|
-
|
|
28
|
+
var alertButtonStyle = {
|
|
29
29
|
marginLeft: '20px',
|
|
30
30
|
border: 'none',
|
|
31
31
|
backgroundColor: 'transparent',
|
|
32
32
|
cursor: 'pointer',
|
|
33
33
|
color: 'rgb(255, 255, 255)'
|
|
34
34
|
};
|
|
35
|
-
|
|
35
|
+
var options = {
|
|
36
36
|
position: 'top center',
|
|
37
37
|
timeout: 0,
|
|
38
38
|
offset: '30px',
|
|
@@ -43,32 +43,33 @@ const options = {
|
|
|
43
43
|
};
|
|
44
44
|
exports.options = options;
|
|
45
45
|
|
|
46
|
-
|
|
47
|
-
options,
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
53
|
-
|
|
54
|
-
}), /*#__PURE__*/_react.default.createElement("svg", {
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
}), options.type === 'info' && '', options.type === 'success' && '', options.type === 'error' && '', message, /*#__PURE__*/_react.default.createElement("button", {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
}, "X"));
|
|
46
|
+
var AlertTemplate = function AlertTemplate(_ref) {
|
|
47
|
+
var options = _ref.options,
|
|
48
|
+
message = _ref.message,
|
|
49
|
+
close = _ref.close;
|
|
50
|
+
return /*#__PURE__*/_react.default.createElement("div", {
|
|
51
|
+
style: AlertStyle
|
|
52
|
+
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
53
|
+
className: "fa fa-exclamation-circle fa-2x"
|
|
54
|
+
}), /*#__PURE__*/_react.default.createElement("svg", {
|
|
55
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
56
|
+
width: "24",
|
|
57
|
+
height: "24",
|
|
58
|
+
viewBox: "0 0 24 24",
|
|
59
|
+
fill: "none",
|
|
60
|
+
stroke: "#FF0040",
|
|
61
|
+
"stroke-width": "2",
|
|
62
|
+
"stroke-linecap": "round",
|
|
63
|
+
"stroke-linejoin": "round",
|
|
64
|
+
style: {
|
|
65
|
+
marginRight: '20px',
|
|
66
|
+
minWidth: '24px'
|
|
67
|
+
}
|
|
68
|
+
}), options.type === 'info' && '', options.type === 'success' && '', options.type === 'error' && '', message, /*#__PURE__*/_react.default.createElement("button", {
|
|
69
|
+
style: alertButtonStyle,
|
|
70
|
+
onClick: close
|
|
71
|
+
}, "X"));
|
|
72
|
+
};
|
|
72
73
|
|
|
73
74
|
exports.AlertTemplate = AlertTemplate;
|
|
74
75
|
var _default = AlertTemplate;
|
|
@@ -27,48 +27,77 @@ var _ApplicationManager = _interopRequireDefault(require("../ApplicationManager"
|
|
|
27
27
|
|
|
28
28
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
29
29
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
30
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
|
31
|
+
|
|
32
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
33
|
+
|
|
34
|
+
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; }
|
|
35
|
+
|
|
36
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
37
|
+
|
|
38
|
+
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."); }
|
|
39
|
+
|
|
40
|
+
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); }
|
|
41
|
+
|
|
42
|
+
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; }
|
|
43
|
+
|
|
44
|
+
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; }
|
|
45
|
+
|
|
46
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
47
|
+
|
|
48
|
+
var useStyles = (0, _styles.makeStyles)(function (theme) {
|
|
49
|
+
return {
|
|
50
|
+
root: {
|
|
51
|
+
display: 'flex'
|
|
52
|
+
},
|
|
53
|
+
paper: {
|
|
54
|
+
marginRight: theme.spacing(2)
|
|
55
|
+
},
|
|
56
|
+
wrapper: {
|
|
57
|
+
zIndex: 2
|
|
58
|
+
}
|
|
59
|
+
};
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
var Button = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
43
63
|
var _props$attributes, _props$attributes$sty, _props$config$attribu, _props$config$attribu2, _props$config$attribu3, _props$config$attribu4, _props$config$attribu5, _props$config$attribu6, _props$config$attribu7;
|
|
44
64
|
|
|
45
|
-
|
|
65
|
+
var classes = useStyles();
|
|
46
66
|
|
|
47
|
-
|
|
67
|
+
var _React$useState = _react.default.useState(false),
|
|
68
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
69
|
+
disabled = _React$useState2[0],
|
|
70
|
+
setDisabled = _React$useState2[1];
|
|
48
71
|
|
|
49
|
-
|
|
72
|
+
var _React$useState3 = _react.default.useState(true),
|
|
73
|
+
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
|
74
|
+
visible = _React$useState4[0],
|
|
75
|
+
setVisible = _React$useState4[1];
|
|
50
76
|
|
|
51
|
-
|
|
77
|
+
var _React$useState5 = _react.default.useState(null),
|
|
78
|
+
_React$useState6 = _slicedToArray(_React$useState5, 2),
|
|
79
|
+
config = _React$useState6[0],
|
|
80
|
+
setConfig = _React$useState6[1];
|
|
52
81
|
|
|
53
|
-
|
|
82
|
+
var color = _Utils.default.getComponentAttribute(props.config, 'color', 'default');
|
|
54
83
|
|
|
55
|
-
|
|
84
|
+
var label = _Utils.default.getComponentAttribute(props.config, 'label', null);
|
|
56
85
|
|
|
57
|
-
_react.default.useEffect(()
|
|
86
|
+
_react.default.useEffect(function () {
|
|
58
87
|
props.handle.api = api();
|
|
59
88
|
});
|
|
60
89
|
|
|
61
|
-
_react.default.useEffect(()
|
|
62
|
-
return ()
|
|
90
|
+
_react.default.useEffect(function () {
|
|
91
|
+
return function () {
|
|
63
92
|
props.handle.api = null;
|
|
64
93
|
};
|
|
65
94
|
}, []);
|
|
66
95
|
|
|
67
|
-
_react.default.useEffect(()
|
|
96
|
+
_react.default.useEffect(function () {
|
|
68
97
|
if (config) {
|
|
69
98
|
props.handle.api = api();
|
|
70
99
|
|
|
71
|
-
|
|
100
|
+
var parsedConfig = _Utils.default.parseConfig(config, props.viewId);
|
|
72
101
|
|
|
73
102
|
_Observable.default.addSubscriptions(parsedConfig.eventHandlingConfig, props.handle, props.viewId);
|
|
74
103
|
|
|
@@ -78,23 +107,23 @@ const Button = /*#__PURE__*/_react.default.forwardRef((props, ref) => {
|
|
|
78
107
|
}
|
|
79
108
|
}, [config]);
|
|
80
109
|
|
|
81
|
-
_react.default.useEffect(()
|
|
110
|
+
_react.default.useEffect(function () {
|
|
82
111
|
var _props$tableRow$id;
|
|
83
112
|
|
|
84
|
-
setConfig(props.tableRow ? {
|
|
113
|
+
setConfig(props.tableRow ? _objectSpread(_objectSpread({}, props.config), {}, {
|
|
85
114
|
id: props.config.id + '_' + ((_props$tableRow$id = props.tableRow.id) === null || _props$tableRow$id === void 0 ? void 0 : _props$tableRow$id.replaceAll('-', ''))
|
|
86
|
-
} : props.config);
|
|
115
|
+
}) : props.config);
|
|
87
116
|
}, []);
|
|
88
117
|
|
|
89
|
-
|
|
118
|
+
var handleClick = function handleClick(e) {
|
|
90
119
|
_ApplicationManager.default.enableFormMarkers(true);
|
|
91
120
|
|
|
92
|
-
|
|
121
|
+
var event = new _Event.default(props.handle, props.viewId);
|
|
93
122
|
|
|
94
123
|
_Observable.default.fireEvent(_EventType.default.CLICK, event);
|
|
95
124
|
};
|
|
96
125
|
|
|
97
|
-
|
|
126
|
+
var api = function api() {
|
|
98
127
|
return {
|
|
99
128
|
get id() {
|
|
100
129
|
return config ? config.id : props.config.id;
|
|
@@ -104,7 +133,7 @@ const Button = /*#__PURE__*/_react.default.forwardRef((props, ref) => {
|
|
|
104
133
|
return props.tableRow;
|
|
105
134
|
},
|
|
106
135
|
|
|
107
|
-
getChildren: ()
|
|
136
|
+
getChildren: function getChildren() {
|
|
108
137
|
return [];
|
|
109
138
|
},
|
|
110
139
|
|
|
@@ -116,13 +145,12 @@ const Button = /*#__PURE__*/_react.default.forwardRef((props, ref) => {
|
|
|
116
145
|
setVisible(visible);
|
|
117
146
|
},
|
|
118
147
|
|
|
119
|
-
refresh() {
|
|
120
|
-
|
|
148
|
+
refresh: function refresh() {
|
|
149
|
+
var parsedConfig = _Utils.default.parseConfig(config ? config : props.config, props.viewId);
|
|
121
150
|
|
|
122
151
|
setDisabled(_Utils.default.evaluateBooleanExpression(parsedConfig.disabled, parsedConfig.id));
|
|
123
152
|
setVisible(_Utils.default.isNull(parsedConfig.visible) || _Utils.default.evaluateBooleanExpression(parsedConfig.visible, parsedConfig.id));
|
|
124
153
|
}
|
|
125
|
-
|
|
126
154
|
};
|
|
127
155
|
};
|
|
128
156
|
|