@agilemotion/oui-react-js 1.3.8 → 1.4.0

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.
Files changed (230) hide show
  1. package/README.TXT +1 -0
  2. package/dist/{ApplicationContext.js → ApplicationManager.js} +334 -335
  3. package/dist/BasicApp.js +67 -64
  4. package/dist/BasicAppHome.js +90 -110
  5. package/dist/BusinessPortalApp.js +1 -1
  6. package/dist/BusinessPortalAppHome.js +15 -50
  7. package/dist/DynamicJS.js +24 -52
  8. package/dist/RestUtils.js +90 -116
  9. package/dist/Utils.js +49 -37
  10. package/dist/WithRouter.js +34 -0
  11. package/dist/assets/jss/components/authNavbarStyle.js +34 -35
  12. package/dist/assets/jss/components/cardHeaderStyle.js +12 -12
  13. package/dist/assets/jss/components/customDropdownStyle.js +26 -26
  14. package/dist/assets/jss/components/customInputStyle.js +2 -8
  15. package/dist/assets/jss/components/dropdownStyle.js +10 -15
  16. package/dist/assets/jss/components/footerStyle.js +12 -18
  17. package/dist/assets/jss/components/headerLinksStyle.js +7 -13
  18. package/dist/assets/jss/components/headerStyle.js +24 -25
  19. package/dist/assets/jss/components/navbarLinksStyle.js +7 -13
  20. package/dist/assets/jss/components/navbarStyle.js +24 -25
  21. package/dist/assets/jss/components/sidebarStyle.js +41 -43
  22. package/dist/assets/jss/components/typographyStyle.js +2 -8
  23. package/dist/assets/jss/rootStyle.js +32 -47
  24. package/dist/assets/jss/views/layoutStyle.js +6 -11
  25. package/dist/assets/jss/views/loginStyle.js +4 -10
  26. package/dist/assets/lotties/call-loading.json +1 -0
  27. package/dist/assets/lotties/calling-2.json +1 -0
  28. package/dist/assets/lotties/calling.json +1 -0
  29. package/dist/assets/lotties/calling2.json +1 -0
  30. package/dist/assets/lotties/chat.json +1 -0
  31. package/dist/assets/lotties/join.json +1 -0
  32. package/dist/assets/lotties/loading.json +1 -0
  33. package/dist/assets/lotties/msg2.json +1 -0
  34. package/dist/assets/lotties/recording.json +1 -0
  35. package/dist/assets/lotties/waiting.json +1 -0
  36. package/dist/assets/scss/black-dashboard-react/bootstrap/_card.scss +5 -5
  37. package/dist/assets/scss/black-dashboard-react/bootstrap/_carousel.scss +2 -2
  38. package/dist/assets/scss/black-dashboard-react/bootstrap/_custom-forms.scss +3 -3
  39. package/dist/assets/scss/black-dashboard-react/bootstrap/_functions.scss +1 -1
  40. package/dist/assets/scss/black-dashboard-react/bootstrap/_images.scss +1 -1
  41. package/dist/assets/scss/black-dashboard-react/bootstrap/_jumbotron.scss +1 -1
  42. package/dist/assets/scss/black-dashboard-react/bootstrap/_popover.scss +7 -5
  43. package/dist/assets/scss/black-dashboard-react/bootstrap/_tooltip.scss +4 -4
  44. package/dist/assets/scss/black-dashboard-react/bootstrap/_variables.scss +5 -5
  45. package/dist/assets/scss/black-dashboard-react/bootstrap/mixins/_grid-framework.scss +2 -2
  46. package/dist/assets/scss/black-dashboard-react/bootstrap/mixins/_grid.scss +11 -9
  47. package/dist/assets/scss/black-dashboard-react/bootstrap/utilities/_embed.scss +6 -4
  48. package/dist/assets/scss/black-dashboard-react/custom/_sidebar-and-main-panel.scss +1 -1
  49. package/dist/assets/scss/black-dashboard-react/custom/_variables.scss +1 -1
  50. package/dist/components/AlertBar.js +39 -80
  51. package/dist/components/AlertItem.js +4 -26
  52. package/dist/components/Button.js +49 -52
  53. package/dist/components/Calendar.js +442 -0
  54. package/dist/components/Calender.css +244 -0
  55. package/dist/components/ConfirmationDialog.js +5 -29
  56. package/dist/components/DataGrid.js +207 -345
  57. package/dist/components/DataGridColumn.js +6 -29
  58. package/dist/components/DataGridFilter.js +48 -116
  59. package/dist/components/DataGridHeading.js +11 -19
  60. package/dist/components/Dialog.js +27 -121
  61. package/dist/components/DocumentViewer.js +12 -38
  62. package/dist/components/DocumentViewerComponent.js +2 -20
  63. package/dist/components/FileThumb.js +126 -0
  64. package/dist/components/Graph.js +33 -75
  65. package/dist/components/GraphNode.js +5 -22
  66. package/dist/components/HtmlPanel.js +68 -82
  67. package/dist/components/Icon.js +107 -1
  68. package/dist/components/LoadingIndicator.js +4 -4
  69. package/dist/components/LottieIcon.js +134 -0
  70. package/dist/components/PopupView.js +3 -21
  71. package/dist/components/Portlet.js +100 -0
  72. package/dist/components/RegularButton.js +15 -19
  73. package/dist/components/SignaturePanel.js +9 -40
  74. package/dist/components/SocketManager.js +170 -0
  75. package/dist/components/StepperTitleBar.js +33 -59
  76. package/dist/components/TabPage.js +6 -9
  77. package/dist/components/TabPanel.js +49 -98
  78. package/dist/components/TableCellContent.js +31 -39
  79. package/dist/components/TemplateDesigner.js +114 -158
  80. package/dist/components/TemplateItemEventHandler.js +33 -100
  81. package/dist/components/TemplateTable.js +6 -42
  82. package/dist/components/TitleBar.js +38 -54
  83. package/dist/components/Toolbar.js +67 -182
  84. package/dist/components/Tree.js +29 -66
  85. package/dist/components/card/Card.js +16 -20
  86. package/dist/components/card/CardAvatar.js +9 -13
  87. package/dist/components/card/CardBody.js +13 -17
  88. package/dist/components/card/CardFooter.js +12 -16
  89. package/dist/components/card/CardHeader.js +13 -17
  90. package/dist/components/card/CardIcon.js +6 -10
  91. package/dist/components/card/CardText.js +6 -10
  92. package/dist/components/customInput/CustomInput.js +12 -10
  93. package/dist/components/dashboard/BasicBusinessAppDashboard.js +85 -159
  94. package/dist/components/dashboard/BusinessPortalAppDashboard.js +30 -75
  95. package/dist/components/dashboard/components/Header.js +9 -26
  96. package/dist/components/dashboard/components/LeftDrawer.js +3 -1
  97. package/dist/components/dashboard/components/blackDashboard/fixedPlugin/FixedPlugin.js +1 -1
  98. package/dist/components/dashboard/components/blackDashboard/sidebar/Sidebar.css +7 -0
  99. package/dist/components/dashboard/components/blackDashboard/sidebar/Sidebar.js +189 -79
  100. package/dist/components/footer/Footer.js +6 -18
  101. package/dist/components/form/AddressSearch.js +32 -66
  102. package/dist/components/form/AutoComplete.js +161 -0
  103. package/dist/components/form/BaseField.js +89 -107
  104. package/dist/components/form/DatePicker.js +8 -23
  105. package/dist/components/form/FieldSet.js +161 -191
  106. package/dist/components/form/Form.css +1 -1
  107. package/dist/components/form/Form.js +153 -479
  108. package/dist/components/form/GridField.js +46 -146
  109. package/dist/components/form/IconField.js +35 -0
  110. package/dist/components/form/ImageEditor.js +22 -60
  111. package/dist/components/form/LookupField.js +8 -29
  112. package/dist/components/form/MultiFileUploadField.js +187 -0
  113. package/dist/components/form/RadioGroup.js +10 -26
  114. package/dist/components/form/Section.js +40 -91
  115. package/dist/components/form/SelectItem.js +14 -33
  116. package/dist/components/form/SignatureTemplateDesignerField.js +0 -1
  117. package/dist/components/form/Switch.js +53 -0
  118. package/dist/components/form/TextField.js +10 -17
  119. package/dist/components/form/TimePicker.js +8 -1
  120. package/dist/components/form/TransferList.css +2 -2
  121. package/dist/components/form/TransferList.js +67 -125
  122. package/dist/components/form/UploadField.js +132 -177
  123. package/dist/components/form/fieldset.css +8 -0
  124. package/dist/components/grid/GridContainer.js +5 -9
  125. package/dist/components/grid/GridItem.js +5 -9
  126. package/dist/components/layout/CollapsiblePanel.js +11 -33
  127. package/dist/components/layout/Layout.js +228 -290
  128. package/dist/components/layout/VC.css +17 -0
  129. package/dist/components/layout/View.css +18 -1
  130. package/dist/components/layout/View.js +80 -200
  131. package/dist/components/layout/ViewContainer.css +3 -0
  132. package/dist/components/layout/ViewContainer.js +59 -0
  133. package/dist/components/layout/ViewPort.js +50 -80
  134. package/dist/components/layout/Window.css +18 -0
  135. package/dist/components/layout/Window.js +287 -0
  136. package/dist/components/layout/WindowViewPort.js +71 -0
  137. package/dist/components/loader.css +1 -1
  138. package/dist/components/media/ClosablePanel.css +37 -0
  139. package/dist/components/media/ClosablePanel.js +53 -0
  140. package/dist/components/media/LobbyWaitingList.js +91 -0
  141. package/dist/components/media/MediaSoupHelper.js +223 -0
  142. package/dist/components/media/Recorder.js +235 -0
  143. package/dist/components/media/SideBarContent.css +54 -0
  144. package/dist/components/media/SideBarContent.js +46 -0
  145. package/dist/components/media/SocketRequest.js +20 -0
  146. package/dist/components/media/SocketResponse.js +16 -0
  147. package/dist/components/media/Timer.css +30 -0
  148. package/dist/components/media/Timer.js +88 -0
  149. package/dist/components/media/Toolbar.css +35 -0
  150. package/dist/components/media/Toolbar.js +494 -0
  151. package/dist/components/media/Tracks.js +39 -0
  152. package/dist/components/media/TrainingRoom.js +608 -0
  153. package/dist/components/media/Transports.js +35 -0
  154. package/dist/components/media/VCEventManager.js +74 -0
  155. package/dist/components/media/VCEventType.js +164 -0
  156. package/dist/components/media/VCParticipantList.css +72 -0
  157. package/dist/components/media/VCParticipantList.js +56 -0
  158. package/dist/components/media/VCParticipantListItem.css +73 -0
  159. package/dist/components/media/VCParticipantListItem.js +319 -0
  160. package/dist/components/media/VCRoom.css +42 -0
  161. package/dist/components/media/VCRoom.js +90 -0
  162. package/dist/components/media/VCRoomParticipant.css +25 -0
  163. package/dist/components/media/VCRoomParticipant.js +808 -0
  164. package/dist/components/media/VCRoomRecorder.js +223 -0
  165. package/dist/components/media/VCRoomWorkspace.css +86 -0
  166. package/dist/components/media/VCRoomWorkspace.js +666 -0
  167. package/dist/components/media/Video.css +4 -0
  168. package/dist/components/media/Video.js +131 -0
  169. package/dist/components/media/VideoPlayer.css +10 -0
  170. package/dist/components/media/VideoPlayer.js +86 -0
  171. package/dist/components/media/chat/ChatRoom.js +926 -0
  172. package/dist/components/media/chat/ChatRoomItem.js +83 -0
  173. package/dist/components/media/chat/ChatRoomList.js +78 -0
  174. package/dist/components/media/chat/ChatRooms.scss +567 -0
  175. package/dist/components/menu/CollapsibleMenu.js +2 -19
  176. package/dist/components/menu/MenuBars.js +6 -33
  177. package/dist/components/menu/MenuButton.js +27 -39
  178. package/dist/components/menu/MenuItem.js +3 -20
  179. package/dist/components/menu/MenuLink.js +22 -13
  180. package/dist/components/navbars/AuthNavbar.js +5 -18
  181. package/dist/components/navbars/HomeNavbar.js +5 -7
  182. package/dist/components/navbars/PortalNavbar.js +7 -25
  183. package/dist/components/signatures/AgilitySignaturePanel.js +38 -104
  184. package/dist/components/signatures/AlertItem.js +3 -24
  185. package/dist/components/signatures/DocumentContainer.js +47 -134
  186. package/dist/components/signatures/ImageSignatureInput.js +11 -38
  187. package/dist/components/signatures/MenuButton.js +1 -16
  188. package/dist/components/signatures/Prompt.js +3 -24
  189. package/dist/components/signatures/ResponsiveTable.js +42 -83
  190. package/dist/components/signatures/SearchView.js +13 -50
  191. package/dist/components/signatures/SignatorySearch.js +83 -99
  192. package/dist/components/signatures/SignatorySearchForm.js +11 -17
  193. package/dist/components/signatures/SignatureInput.js +18 -47
  194. package/dist/components/signatures/SignatureInputProps.js +18 -60
  195. package/dist/components/signatures/SignatureTemplateDesigner.js +151 -239
  196. package/dist/components/signatures/Toolbar.js +7 -34
  197. package/dist/components/signatures/ViewUtils.js +2 -6
  198. package/dist/components/typography/Danger.js +3 -1
  199. package/dist/components/typography/Info.js +3 -1
  200. package/dist/components/typography/Link.js +6 -2
  201. package/dist/event/ActionHandlers.js +6 -6
  202. package/dist/event/EventType.js +7 -1
  203. package/dist/event/LoadDataActionHandler.js +1 -1
  204. package/dist/event/Observable.js +80 -174
  205. package/dist/event/RouteActionHandler.js +74 -31
  206. package/dist/event/ServiceCallActionHandler.js +36 -24
  207. package/dist/event/SignalGraphActionHandler.js +2 -2
  208. package/dist/js/Addresses.js +10 -8
  209. package/dist/js/Calendar.js +220 -0
  210. package/dist/js/Media.js +157 -0
  211. package/dist/redux/store/ConfigureStore.js +3 -9
  212. package/dist/redux/store/DashboardStore.js +42 -94
  213. package/dist/redux/store/SecurityStore.js +15 -50
  214. package/dist/view/Dashboard.js +256 -171
  215. package/dist/view/Views.js +30 -0
  216. package/dist/view/security/ChangePasswordBasic.js +29 -80
  217. package/dist/view/security/ForgotPassword.js +13 -46
  218. package/dist/view/security/ForgotPasswordBasic.js +12 -45
  219. package/dist/view/security/Login.js +15 -51
  220. package/dist/view/security/LoginBasic.js +13 -46
  221. package/dist/view/security/LoginBusinessPortal.js +12 -45
  222. package/dist/view/security/ResetPassword.js +13 -51
  223. package/dist/view/security/ResetPasswordBasic.js +27 -75
  224. package/dist/view/security/Security.js +1 -0
  225. package/package.json +31 -25
  226. package/README.md +0 -1623
  227. package/dist/components/dashboard/BasicApp.js +0 -140
  228. package/dist/components/navbars/NavbarLinks.js +0 -212
  229. package/dist/components/signatures/OLD.js +0 -1138
  230. package/gulpfile.js +0 -77
@@ -25,26 +25,12 @@ var _htmlToImage = require("html-to-image");
25
25
 
26
26
  var _DocumentContainer = _interopRequireDefault(require("./DocumentContainer"));
27
27
 
28
- var _ApplicationContext = _interopRequireDefault(require("../../ApplicationContext"));
28
+ var _ApplicationManager = _interopRequireDefault(require("../../ApplicationManager"));
29
29
 
30
30
  var _reactPromiseTracker = require("react-promise-tracker");
31
31
 
32
32
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
33
33
 
34
- 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; } } }; }
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
34
  const status = response => {
49
35
  if (response.ok) {
50
36
  return Promise.resolve(response);
@@ -59,95 +45,44 @@ const json = response => {
59
45
  return response.text();
60
46
  };
61
47
 
62
- const location = window.location.protocol + "//" + window.location.hostname;
48
+ const location = window.location.protocol + '//' + window.location.hostname;
63
49
 
64
50
  const AgilitySignaturePanel = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_react.default.forwardRef((props, ref) => {
65
- const _React$useState = _react.default.useState(null),
66
- _React$useState2 = _slicedToArray(_React$useState, 2),
67
- inputMode = _React$useState2[0],
68
- setInputMode = _React$useState2[1];
69
-
70
- const _React$useState3 = _react.default.useState(false),
71
- _React$useState4 = _slicedToArray(_React$useState3, 2),
72
- open = _React$useState4[0],
73
- setOpen = _React$useState4[1];
74
-
75
- const _React$useState5 = _react.default.useState(false),
76
- _React$useState6 = _slicedToArray(_React$useState5, 2),
77
- imagesFetched = _React$useState6[0],
78
- setImagesFetched = _React$useState6[1];
79
-
80
- const _React$useState7 = _react.default.useState(false),
81
- _React$useState8 = _slicedToArray(_React$useState7, 2),
82
- signing = _React$useState8[0],
83
- setSigning = _React$useState8[1];
84
-
85
- const _React$useState9 = _react.default.useState(null),
86
- _React$useState10 = _slicedToArray(_React$useState9, 2),
87
- signatureImage = _React$useState10[0],
88
- setSignatureImage = _React$useState10[1];
89
-
90
- const _React$useState11 = _react.default.useState(null),
91
- _React$useState12 = _slicedToArray(_React$useState11, 2),
92
- initialImage = _React$useState12[0],
93
- setInitialImage = _React$useState12[1];
94
-
95
- const _React$useState13 = _react.default.useState(null),
96
- _React$useState14 = _slicedToArray(_React$useState13, 2),
97
- systemSignatures = _React$useState14[0],
98
- setSystemSignatures = _React$useState14[1];
99
-
100
- const username = sessionStorage.getItem("username");
51
+ const [inputMode, setInputMode] = _react.default.useState(null);
52
+
53
+ const [open, setOpen] = _react.default.useState(false);
54
+
55
+ const [signing, setSigning] = _react.default.useState(false);
56
+
57
+ const [signatureImage, setSignatureImage] = _react.default.useState(null);
58
+
59
+ const [initialImage, setInitialImage] = _react.default.useState(null);
60
+
61
+ const [systemSignatures, setSystemSignatures] = _react.default.useState(null);
101
62
 
102
63
  _react.default.useEffect(() => {
103
- if (!imagesFetched) {
104
- fetchImages();
105
- }
106
- });
64
+ fetchImages();
65
+ }, []);
107
66
 
108
67
  _react.default.useEffect(() => {
109
- if (imagesFetched) {
110
- if (!_Utils.default.isNull(initialImage) && !_Utils.default.isNull(signatureImage)) {
111
- let signers = props.config.documents[0].signers;
112
-
113
- var _iterator = _createForOfIteratorHelper(signers),
114
- _step;
115
-
116
- try {
117
- for (_iterator.s(); !(_step = _iterator.n()).done;) {
118
- const signer = _step.value;
119
-
120
- if (signer.email === username) {
121
- let signingInputs = signer.signatureInputs;
122
-
123
- var _iterator2 = _createForOfIteratorHelper(signingInputs),
124
- _step2;
125
-
126
- try {
127
- for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
128
- const signingInput = _step2.value;
129
-
130
- if ("SIGN" === signingInput.inputType) {
131
- signingInput.value = signatureImage;
132
- } else if ("INITIAL" === signingInput.inputType) {
133
- signingInput.value = initialImage;
134
- }
135
- }
136
- } catch (err) {
137
- _iterator2.e(err);
138
- } finally {
139
- _iterator2.f();
140
- }
68
+ if (!_Utils.default.isNull(initialImage) && !_Utils.default.isNull(signatureImage)) {
69
+ let signers = props.config.documents[0].signers;
70
+
71
+ for (const signer of signers) {
72
+ if (signer.email === props.config.signatoryId) {
73
+ let signingInputs = signer.signatureInputs;
74
+
75
+ for (const signingInput of signingInputs) {
76
+ if ('SIGN' === signingInput.inputType) {
77
+ signingInput.value = signatureImage;
78
+ } else if ('INITIAL' === signingInput.inputType) {
79
+ signingInput.value = initialImage;
141
80
  }
142
81
  }
143
- } catch (err) {
144
- _iterator.e(err);
145
- } finally {
146
- _iterator.f();
147
82
  }
148
-
149
- props.valueChangeHandler(signers);
150
83
  }
84
+
85
+ props.valueChangeHandler(signers);
151
86
  }
152
87
  }, [initialImage, signatureImage]);
153
88
 
@@ -172,7 +107,7 @@ const AgilitySignaturePanel = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_re
172
107
  setSigning(true);
173
108
 
174
109
  if (method === 'type') {
175
- let node = document.getElementById("template");
110
+ let node = document.getElementById('template');
176
111
  node.innerText = data;
177
112
  (0, _htmlToImage.toPng)(node).then(function (dataUrl) {
178
113
  doSign(dataUrl);
@@ -185,8 +120,8 @@ const AgilitySignaturePanel = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_re
185
120
  };
186
121
 
187
122
  function getFetchConfig() {
188
- const accessToken = sessionStorage.getItem("accessToken");
189
- const idToken = sessionStorage.getItem("idToken");
123
+ const accessToken = sessionStorage.getItem('accessToken');
124
+ const idToken = sessionStorage.getItem('idToken');
190
125
  return {
191
126
  method: 'GET',
192
127
  headers: {
@@ -199,8 +134,7 @@ const AgilitySignaturePanel = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_re
199
134
 
200
135
  function fetchImages() {
201
136
  let fetchConfig = getFetchConfig();
202
- let url = location + _ApplicationContext.default.getBaseApiUrl() + props.signatureImageUrl + "/find";
203
- setImagesFetched(true);
137
+ let url = location + _ApplicationManager.default.getContextRoot() + props.signatureImageUrl + '/find';
204
138
  (0, _reactPromiseTracker.trackPromise)(fetch(encodeURI(url), fetchConfig).then(status).then(json).then(data => {
205
139
  if (data && data.length > 0) {
206
140
  let images = JSON.parse(data);
@@ -208,9 +142,9 @@ const AgilitySignaturePanel = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_re
208
142
  }
209
143
  }).catch(e => {
210
144
  if (e.code === 401) {
211
- _ApplicationContext.default.clear();
145
+ _ApplicationManager.default.clear();
212
146
 
213
- _ApplicationContext.default.getApplicationHistory().push('/login');
147
+ _ApplicationManager.default.getApplicationHistory().push('/login');
214
148
  }
215
149
  }));
216
150
  }
@@ -218,7 +152,7 @@ const AgilitySignaturePanel = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_re
218
152
  return /*#__PURE__*/_react.default.createElement("div", {
219
153
  ref: ref,
220
154
  style: {
221
- padding: "4px 32px"
155
+ padding: '4px 32px'
222
156
  }
223
157
  }, /*#__PURE__*/_react.default.createElement("div", {
224
158
  style: {
@@ -234,7 +168,7 @@ const AgilitySignaturePanel = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_re
234
168
  }
235
169
  })), /*#__PURE__*/_react.default.createElement(_Dialog.default, {
236
170
  open: open,
237
- maxWidth: "xl",
171
+ maxWidth: 'xl',
238
172
  "aria-labelledby": "alert-dialog-title",
239
173
  "aria-describedby": "alert-dialog-description"
240
174
  }, /*#__PURE__*/_react.default.createElement(_DialogTitle.default, {
@@ -265,7 +199,7 @@ const AgilitySignaturePanel = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_re
265
199
  }, /*#__PURE__*/_react.default.createElement("div", {
266
200
  className: 'row',
267
201
  style: {
268
- padding: "4px 32px"
202
+ padding: '4px 32px'
269
203
  }
270
204
  }, /*#__PURE__*/_react.default.createElement("div", {
271
205
  className: 'col-*-*'
@@ -17,18 +17,6 @@ var _ViewUtils = _interopRequireDefault(require("./ViewUtils"));
17
17
 
18
18
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
19
 
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
20
  const utils = new _ViewUtils.default();
33
21
  const useStyles = (0, _styles.makeStyles)(theme => ({
34
22
  root: {
@@ -42,20 +30,11 @@ const useStyles = (0, _styles.makeStyles)(theme => ({
42
30
  function AlertItem(props) {
43
31
  const classes = useStyles();
44
32
 
45
- const _React$useState = _react.default.useState(props.message),
46
- _React$useState2 = _slicedToArray(_React$useState, 2),
47
- message = _React$useState2[0],
48
- setMessage = _React$useState2[1];
33
+ const [message, setMessage] = _react.default.useState(props.message);
49
34
 
50
- const _React$useState3 = _react.default.useState(props.alertStyle),
51
- _React$useState4 = _slicedToArray(_React$useState3, 2),
52
- alertStyle = _React$useState4[0],
53
- setAlertStyle = _React$useState4[1];
35
+ const [alertStyle, setAlertStyle] = _react.default.useState(props.alertStyle);
54
36
 
55
- const _React$useState5 = _react.default.useState(props.alertTitle),
56
- _React$useState6 = _slicedToArray(_React$useState5, 2),
57
- title = _React$useState6[0],
58
- setTitle = _React$useState6[1];
37
+ const [title, setTitle] = _react.default.useState(props.alertTitle);
59
38
 
60
39
  _react.default.useEffect(() => {
61
40
  setMessage(props.message);
@@ -11,51 +11,16 @@ require("./DocumentContainer.css");
11
11
 
12
12
  var _reactHtmlRenderer = _interopRequireDefault(require("react-html-renderer"));
13
13
 
14
- var _reactConfirmAlert = require("react-confirm-alert");
15
-
16
- require("react-confirm-alert/src/react-confirm-alert.css");
17
-
18
- var _Utils = _interopRequireDefault(require("../../Utils"));
19
-
20
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
21
15
 
22
- 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; } } }; }
23
-
24
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
25
-
26
- 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."); }
27
-
28
- 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); }
29
-
30
- 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; }
31
-
32
- 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; }
33
-
34
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
35
-
36
- // Import css
37
16
  const DocumentContainer = props => {
38
- const _React$useState = _react.default.useState(null),
39
- _React$useState2 = _slicedToArray(_React$useState, 2),
40
- documentContent = _React$useState2[0],
41
- setDocumentContent = _React$useState2[1];
42
-
43
- const _React$useState3 = _react.default.useState(null),
44
- _React$useState4 = _slicedToArray(_React$useState3, 2),
45
- signatureImage = _React$useState4[0],
46
- setSignatureImage = _React$useState4[1];
17
+ const [documentContent, setDocumentContent] = _react.default.useState(null);
47
18
 
48
- const _React$useState5 = _react.default.useState(null),
49
- _React$useState6 = _slicedToArray(_React$useState5, 2),
50
- initialImage = _React$useState6[0],
51
- setInitialImage = _React$useState6[1];
19
+ const [signatureImage, setSignatureImage] = _react.default.useState(null);
52
20
 
53
- const _React$useState7 = _react.default.useState(null),
54
- _React$useState8 = _slicedToArray(_React$useState7, 2),
55
- htmlRendererProps = _React$useState8[0],
56
- setHtmlRendererProps = _React$useState8[1];
21
+ const [initialImage, setInitialImage] = _react.default.useState(null);
57
22
 
58
- const username = sessionStorage.getItem("username");
23
+ const [htmlRendererProps, setHtmlRendererProps] = _react.default.useState(null);
59
24
 
60
25
  _react.default.useEffect(() => {
61
26
  if (signatureImage !== props.signatureImage) {
@@ -80,113 +45,61 @@ const DocumentContainer = props => {
80
45
  let total = 0;
81
46
  let rendererProps = {};
82
47
 
83
- var _iterator = _createForOfIteratorHelper(signers),
84
- _step;
48
+ for (const signer of signers) {
49
+ total += signer.signatureInputs.length;
50
+ }
51
+
52
+ for (const signer of signers) {
53
+ if (signer.email === props.config.signatoryId) {
54
+ let signingInputs = signer.signatureInputs;
85
55
 
86
- try {
87
- for (_iterator.s(); !(_step = _iterator.n()).done;) {
88
- const signer = _step.value;
89
- total += signer.signatureInputs.length;
56
+ for (const signingInput of signingInputs) {
57
+ signingInput.isFirst = count === 0;
58
+ signingInput.isLast = count === total - 1;
59
+ count++;
60
+ }
90
61
  }
91
- } catch (err) {
92
- _iterator.e(err);
93
- } finally {
94
- _iterator.f();
95
62
  }
96
63
 
97
- var _iterator2 = _createForOfIteratorHelper(signers),
98
- _step2;
64
+ for (const signer of signers) {
65
+ if (signer.email === props.config.signatoryId) {
66
+ let signingInputs = signer.signatureInputs;
99
67
 
100
- try {
101
- for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
102
- const signer = _step2.value;
68
+ for (const signingInput of signingInputs) {
69
+ let color = 'transparent';
103
70
 
104
- if (signer.email === username) {
105
- let signingInputs = signer.signatureInputs;
71
+ if ("SIGN" === signingInput.inputType && signatureImage === null || "INITIAL" === signingInput.inputType && initialImage === null) {
72
+ color = 'red';
73
+ }
106
74
 
107
- var _iterator4 = _createForOfIteratorHelper(signingInputs),
108
- _step4;
75
+ console.log(signingInput.tagName + " - " + signingInput.index + " - " + initialImage);
76
+ console.log(signingInput);
77
+ template = template.replace(signingInput.tagName, "<sgvp".concat(signingInput.index, " />"));
109
78
 
110
- try {
111
- for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
112
- const signingInput = _step4.value;
113
- signingInput.isFirst = count === 0;
114
- signingInput.isLast = count === total - 1;
115
- count++;
79
+ rendererProps["sgvp".concat(signingInput.index)] = props => /*#__PURE__*/_react.default.createElement("div", {
80
+ style: {
81
+ borderRadius: '4px',
82
+ position: 'absolute',
83
+ width: '100px',
84
+ height: '60px'
116
85
  }
117
- } catch (err) {
118
- _iterator4.e(err);
119
- } finally {
120
- _iterator4.f();
121
- }
122
- }
123
- }
124
- } catch (err) {
125
- _iterator2.e(err);
126
- } finally {
127
- _iterator2.f();
128
- }
129
-
130
- var _iterator3 = _createForOfIteratorHelper(signers),
131
- _step3;
132
-
133
- try {
134
- for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
135
- const signer = _step3.value;
136
-
137
- if (signer.email === username) {
138
- let signingInputs = signer.signatureInputs;
139
-
140
- var _iterator5 = _createForOfIteratorHelper(signingInputs),
141
- _step5;
142
-
143
- try {
144
- for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
145
- const signingInput = _step5.value;
146
- let color = 'transparent';
147
-
148
- if ("SIGN" === signingInput.inputType && signatureImage === null || "INITIAL" === signingInput.inputType && initialImage === null) {
149
- color = 'red';
150
- }
151
-
152
- console.log(signingInput.tagName + " - " + signingInput.index + " - " + initialImage);
153
- console.log(signingInput);
154
- template = template.replace(signingInput.tagName, "<sgvp".concat(signingInput.index, " />"));
155
-
156
- rendererProps["sgvp".concat(signingInput.index)] = props => /*#__PURE__*/_react.default.createElement("div", {
157
- style: {
158
- borderRadius: '4px',
159
- position: 'absolute',
160
- width: '100px',
161
- height: '60px'
162
- }
163
- }, "SIGN" === signingInput.inputType && signatureImage !== null ? /*#__PURE__*/_react.default.createElement("img", {
164
- src: signatureImage,
165
- alt: '',
166
- style: {
167
- maxHeight: '100%',
168
- maxWidth: '100%'
169
- }
170
- }) : "INITIAL" === signingInput.inputType && initialImage !== null ? /*#__PURE__*/_react.default.createElement("img", {
171
- src: initialImage,
172
- alt: '',
173
- style: {
174
- maxHeight: '100%',
175
- maxWidth: '100%'
176
- }
177
- }) : null);
86
+ }, "SIGN" === signingInput.inputType && signatureImage !== null ? /*#__PURE__*/_react.default.createElement("img", {
87
+ src: signatureImage,
88
+ alt: '',
89
+ style: {
90
+ maxHeight: '100%',
91
+ maxWidth: '100%'
178
92
  }
179
- } catch (err) {
180
- _iterator5.e(err);
181
- } finally {
182
- _iterator5.f();
183
- }
93
+ }) : "INITIAL" === signingInput.inputType && initialImage !== null ? /*#__PURE__*/_react.default.createElement("img", {
94
+ src: initialImage,
95
+ alt: '',
96
+ style: {
97
+ maxHeight: '100%',
98
+ maxWidth: '100%'
99
+ }
100
+ }) : null);
184
101
  }
185
102
  }
186
- } catch (err) {
187
- _iterator3.e(err);
188
- } finally {
189
- _iterator3.f();
190
103
  }
191
104
 
192
105
  setHtmlRendererProps(rendererProps);
@@ -13,7 +13,7 @@ var _styles = require("@material-ui/core/styles");
13
13
 
14
14
  var _Utils = _interopRequireDefault(require("../../Utils"));
15
15
 
16
- var _ApplicationContext = _interopRequireDefault(require("./../../ApplicationContext"));
16
+ var _ApplicationManager = _interopRequireDefault(require("../../ApplicationManager"));
17
17
 
18
18
  var _Icon = _interopRequireDefault(require("../Icon"));
19
19
 
@@ -25,24 +25,6 @@ var _Checkbox = _interopRequireDefault(require("@material-ui/core/Checkbox"));
25
25
 
26
26
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
27
27
 
28
- 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; }
29
-
30
- 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; }
31
-
32
- 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; }
33
-
34
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
35
-
36
- 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."); }
37
-
38
- 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); }
39
-
40
- 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; }
41
-
42
- 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; }
43
-
44
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
45
-
46
28
  const useStyles = (0, _styles.makeStyles)(theme => ({
47
29
  button: {
48
30
  margin: theme.spacing(1)
@@ -76,20 +58,11 @@ const ImageSignatureInput = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_reac
76
58
  const width = '320px';
77
59
  const height = '320px';
78
60
 
79
- const _React$useState = _react.default.useState(null),
80
- _React$useState2 = _slicedToArray(_React$useState, 2),
81
- value = _React$useState2[0],
82
- setValue = _React$useState2[1];
61
+ const [value, setValue] = _react.default.useState(null);
83
62
 
84
- const _React$useState3 = _react.default.useState(false),
85
- _React$useState4 = _slicedToArray(_React$useState3, 2),
86
- uploaded = _React$useState4[0],
87
- setUploaded = _React$useState4[1];
63
+ const [uploaded, setUploaded] = _react.default.useState(false);
88
64
 
89
- const _React$useState5 = _react.default.useState(false),
90
- _React$useState6 = _slicedToArray(_React$useState5, 2),
91
- saveAsSystemImage = _React$useState6[0],
92
- setSaveAsSystemImage = _React$useState6[1];
65
+ const [saveAsSystemImage, setSaveAsSystemImage] = _react.default.useState(false);
93
66
 
94
67
  _react.default.useEffect(() => {
95
68
  if (value !== props.value) {
@@ -117,14 +90,14 @@ const ImageSignatureInput = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_reac
117
90
 
118
91
  function process(callback, data, action) {
119
92
  let fetchConfig = getFetchConfig(data);
120
- let url = location + _ApplicationContext.default.getBaseApiUrl() + props.imageProcessingUrl + "/" + action;
93
+ let url = location + _ApplicationManager.default.getContextRoot() + props.imageProcessingUrl + "/" + action + "/TEXT";
121
94
  (0, _reactPromiseTracker.trackPromise)(fetch(encodeURI(url), fetchConfig).then(status).then(json).then(data => {
122
95
  callback(data);
123
96
  }).catch(e => {
124
97
  if (e.code === 401) {
125
- _ApplicationContext.default.clear();
98
+ _ApplicationManager.default.clear();
126
99
 
127
- _ApplicationContext.default.getApplicationHistory().push('/login');
100
+ _ApplicationManager.default.getApplicationHistory().push('/login');
128
101
  }
129
102
  }));
130
103
  }
@@ -194,9 +167,9 @@ const ImageSignatureInput = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_reac
194
167
  },
195
168
  onClick: () => {
196
169
  process(data => {
197
- setValue(_objectSpread(_objectSpread({}, value), {}, {
170
+ setValue({ ...value,
198
171
  url: data
199
- }));
172
+ });
200
173
  }, value.url, 'rotateLeft');
201
174
  },
202
175
  startIcon: /*#__PURE__*/_react.default.createElement(_Icon.default, {
@@ -216,9 +189,9 @@ const ImageSignatureInput = /*#__PURE__*/_react.default.memo( /*#__PURE__*/_reac
216
189
  },
217
190
  onClick: () => {
218
191
  process(data => {
219
- setValue(_objectSpread(_objectSpread({}, value), {}, {
192
+ setValue({ ...value,
220
193
  url: data
221
- }));
194
+ });
222
195
  }, value.url, 'rotateRight');
223
196
  },
224
197
  startIcon: /*#__PURE__*/_react.default.createElement(_Icon.default, {
@@ -23,18 +23,6 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
23
23
 
24
24
  function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
25
25
 
26
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
27
-
28
- 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."); }
29
-
30
- 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); }
31
-
32
- 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; }
33
-
34
- 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; }
35
-
36
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
37
-
38
26
  const useStyles = (0, _styles.makeStyles)(theme => ({
39
27
  root: {
40
28
  display: 'flex'
@@ -53,10 +41,7 @@ const useStyles = (0, _styles.makeStyles)(theme => ({
53
41
  function MenuButton(props) {
54
42
  const classes = useStyles();
55
43
 
56
- const _React$useState = _react.default.useState(false),
57
- _React$useState2 = _slicedToArray(_React$useState, 2),
58
- open = _React$useState2[0],
59
- setOpen = _React$useState2[1];
44
+ const [open, setOpen] = _react.default.useState(false);
60
45
 
61
46
  const anchorRef = _react.default.useRef(null);
62
47
 
@@ -21,33 +21,12 @@ var _DialogTitle = _interopRequireDefault(require("@material-ui/core/DialogTitle
21
21
 
22
22
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
23
23
 
24
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
25
-
26
- 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."); }
27
-
28
- 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); }
29
-
30
- 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; }
31
-
32
- 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; }
33
-
34
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
35
-
36
24
  function Prompt(props) {
37
- const _React$useState = _react.default.useState(false),
38
- _React$useState2 = _slicedToArray(_React$useState, 2),
39
- open = _React$useState2[0],
40
- setOpen = _React$useState2[1];
25
+ const [open, setOpen] = _react.default.useState(false);
41
26
 
42
- const _React$useState3 = _react.default.useState(props.promptContent),
43
- _React$useState4 = _slicedToArray(_React$useState3, 2),
44
- content = _React$useState4[0],
45
- setContent = _React$useState4[1];
27
+ const [content, setContent] = _react.default.useState(props.promptContent);
46
28
 
47
- const _React$useState5 = _react.default.useState(props.promptTitle),
48
- _React$useState6 = _slicedToArray(_React$useState5, 2),
49
- title = _React$useState6[0],
50
- setTitle = _React$useState6[1];
29
+ const [title, setTitle] = _react.default.useState(props.promptTitle);
51
30
 
52
31
  const handleNo = () => {
53
32
  setOpen(false);