andoncloud-sdk 1.7.31 → 1.7.33
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/index.d.ts +5 -16
- package/dist/index.js +745 -1096
- package/dist/index.js.map +1 -1
- package/package.json +4 -3
package/dist/index.js
CHANGED
|
@@ -7,7 +7,6 @@ import HourglassEmptyIcon from "@mui/icons-material/HourglassEmpty";
|
|
|
7
7
|
import LockIcon from "@mui/icons-material/Lock";
|
|
8
8
|
import ShoppingCartIcon from "@mui/icons-material/ShoppingCart";
|
|
9
9
|
import { Alert, Box, Button, Card, CardContent, Checkbox as Checkbox$1, Collapse, Container as Container$1, Dialog, DialogContent, DialogTitle, Drawer, FormControl, IconButton, Link, List, ListItem, ListItemButton, ListItemIcon, ListItemText, Radio as Radio$1, RadioGroup as RadioGroup$1, Stack, Step, StepLabel, Stepper, TextField, Tooltip, Typography, styled, useScrollTrigger } from "@mui/material";
|
|
10
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
11
10
|
import { action, computed, flow, makeAutoObservable, makeObservable, observable, reaction, toJS } from "mobx";
|
|
12
11
|
import TagManager from "react-gtm-module";
|
|
13
12
|
import { BrowserRouter, Link as Link$1, Navigate, Route, Routes, createRoutesFromChildren, matchRoutes, useLocation, useNavigate, useNavigationType, useSearchParams } from "react-router-dom";
|
|
@@ -53,7 +52,7 @@ const ACCESS_STATE_COLORS = {
|
|
|
53
52
|
expired: "error.main",
|
|
54
53
|
not_purchased: "primary.main"
|
|
55
54
|
};
|
|
56
|
-
const makeStyles$1 = (accessState) => {
|
|
55
|
+
const makeStyles$1 = (accessState, backgroundImage) => {
|
|
57
56
|
const accentColor = ACCESS_STATE_COLORS[accessState] || "primary.main";
|
|
58
57
|
return {
|
|
59
58
|
container: {
|
|
@@ -67,15 +66,25 @@ const makeStyles$1 = (accessState) => {
|
|
|
67
66
|
height: "100%",
|
|
68
67
|
padding: 4,
|
|
69
68
|
textAlign: "center",
|
|
70
|
-
background: (theme) => theme.palette.gradient.dark.main
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
69
|
+
background: (theme) => theme.palette.gradient.dark.main,
|
|
70
|
+
...backgroundImage && {
|
|
71
|
+
"&::before": {
|
|
72
|
+
content: "\"\"",
|
|
73
|
+
position: "absolute",
|
|
74
|
+
inset: 0,
|
|
75
|
+
backgroundImage: `url(${backgroundImage})`,
|
|
76
|
+
backgroundSize: "cover",
|
|
77
|
+
backgroundPosition: "center",
|
|
78
|
+
backgroundRepeat: "no-repeat",
|
|
79
|
+
filter: "blur(12px) brightness(0.35) saturate(0.7)",
|
|
80
|
+
pointerEvents: "none",
|
|
81
|
+
zIndex: 0
|
|
82
|
+
},
|
|
83
|
+
"& > *": {
|
|
84
|
+
position: "relative",
|
|
85
|
+
zIndex: 1
|
|
86
|
+
}
|
|
87
|
+
}
|
|
79
88
|
},
|
|
80
89
|
icon: {
|
|
81
90
|
fontSize: 48,
|
|
@@ -169,60 +178,43 @@ const AccessRequestModal = ({ open, requestType, onSubmitRequest, onClose }) =>
|
|
|
169
178
|
const { translationKey, steps, showDisclaimer } = REQUEST_TYPE_CONFIG[requestType] || REQUEST_TYPE_CONFIG.feature_access;
|
|
170
179
|
const renderStepper = () => {
|
|
171
180
|
if (steps.length === 0) return null;
|
|
172
|
-
return /* @__PURE__ */
|
|
181
|
+
return /* @__PURE__ */ React.createElement(Stepper, {
|
|
173
182
|
orientation: "vertical",
|
|
174
|
-
sx: styles$1.stepper
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
});
|
|
183
|
+
sx: styles$1.stepper
|
|
184
|
+
}, steps.map((step) => /* @__PURE__ */ React.createElement(Step, {
|
|
185
|
+
key: step,
|
|
186
|
+
active: true
|
|
187
|
+
}, /* @__PURE__ */ React.createElement(StepLabel, null, t(`access.modal.${translationKey}.${step}`)))));
|
|
180
188
|
};
|
|
181
189
|
const renderContent = () => {
|
|
182
|
-
if (requestType === "start_trial") return /* @__PURE__ */
|
|
190
|
+
if (requestType === "start_trial") return /* @__PURE__ */ React.createElement(Typography, {
|
|
183
191
|
variant: "body1",
|
|
184
|
-
sx: styles$1.content
|
|
185
|
-
|
|
186
|
-
});
|
|
192
|
+
sx: styles$1.content
|
|
193
|
+
}, t("access.modal.startTrial.content"));
|
|
187
194
|
return renderStepper();
|
|
188
195
|
};
|
|
189
|
-
return /* @__PURE__ */
|
|
196
|
+
return /* @__PURE__ */ React.createElement(Dialog, {
|
|
190
197
|
open,
|
|
191
198
|
onClose,
|
|
192
199
|
sx: styles$1.dialog,
|
|
193
|
-
"data-testid": "sdk.access-modal"
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
variant: "contained",
|
|
212
|
-
onClick: onSubmitRequest,
|
|
213
|
-
"data-testid": "sdk.access-modal.action",
|
|
214
|
-
children: t(`access.modal.${translationKey}.button`)
|
|
215
|
-
}), /* @__PURE__ */ jsx(Button, {
|
|
216
|
-
variant: "outlined",
|
|
217
|
-
onClick: onClose,
|
|
218
|
-
"data-testid": "sdk.access-modal.cancel",
|
|
219
|
-
children: t("access.modal.cancel")
|
|
220
|
-
})]
|
|
221
|
-
})
|
|
222
|
-
]
|
|
223
|
-
})
|
|
224
|
-
})]
|
|
225
|
-
});
|
|
200
|
+
"data-testid": "sdk.access-modal"
|
|
201
|
+
}, /* @__PURE__ */ React.createElement(DialogTitle, null, t(`access.modal.${translationKey}.header`)), /* @__PURE__ */ React.createElement(DialogContent, { sx: styles$1.dialogContent }, /* @__PURE__ */ React.createElement(Box, { sx: styles$1.container }, renderContent(), showDisclaimer && /* @__PURE__ */ React.createElement(Alert, {
|
|
202
|
+
severity: "warning",
|
|
203
|
+
variant: "outlined",
|
|
204
|
+
sx: styles$1.disclaimer
|
|
205
|
+
}, t("access.modal.disclaimer")), /* @__PURE__ */ React.createElement(Stack, {
|
|
206
|
+
direction: "row",
|
|
207
|
+
spacing: 2,
|
|
208
|
+
sx: styles$1.actions
|
|
209
|
+
}, /* @__PURE__ */ React.createElement(Button, {
|
|
210
|
+
variant: "contained",
|
|
211
|
+
onClick: onSubmitRequest,
|
|
212
|
+
"data-testid": "sdk.access-modal.action"
|
|
213
|
+
}, t(`access.modal.${translationKey}.button`)), /* @__PURE__ */ React.createElement(Button, {
|
|
214
|
+
variant: "outlined",
|
|
215
|
+
onClick: onClose,
|
|
216
|
+
"data-testid": "sdk.access-modal.cancel"
|
|
217
|
+
}, t("access.modal.cancel"))))));
|
|
226
218
|
};
|
|
227
219
|
//#endregion
|
|
228
220
|
//#region src/components/access/CooldownModal.styles.js
|
|
@@ -251,30 +243,18 @@ const styles = {
|
|
|
251
243
|
//#region src/components/access/CooldownModal.js
|
|
252
244
|
const CooldownModal = ({ open, daysRemaining, onClose }) => {
|
|
253
245
|
const { t } = useTranslation();
|
|
254
|
-
return /* @__PURE__ */
|
|
246
|
+
return /* @__PURE__ */ React.createElement(Dialog, {
|
|
255
247
|
open,
|
|
256
248
|
onClose,
|
|
257
|
-
sx: styles.dialog
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
}), /* @__PURE__ */ jsx(Box, {
|
|
267
|
-
sx: styles.actions,
|
|
268
|
-
children: /* @__PURE__ */ jsx(Button, {
|
|
269
|
-
variant: "contained",
|
|
270
|
-
onClick: onClose,
|
|
271
|
-
"data-testid": "sdk.access-cooldown.button",
|
|
272
|
-
children: t("access.cooldown.button")
|
|
273
|
-
})
|
|
274
|
-
})]
|
|
275
|
-
})
|
|
276
|
-
})]
|
|
277
|
-
});
|
|
249
|
+
sx: styles.dialog
|
|
250
|
+
}, /* @__PURE__ */ React.createElement(DialogTitle, null, t("access.cooldown.header")), /* @__PURE__ */ React.createElement(DialogContent, { sx: styles.dialogContent }, /* @__PURE__ */ React.createElement(Box, { sx: styles.container }, /* @__PURE__ */ React.createElement(Typography, {
|
|
251
|
+
variant: "body1",
|
|
252
|
+
sx: styles.content
|
|
253
|
+
}, t("access.cooldown.message", { days: daysRemaining })), /* @__PURE__ */ React.createElement(Box, { sx: styles.actions }, /* @__PURE__ */ React.createElement(Button, {
|
|
254
|
+
variant: "contained",
|
|
255
|
+
onClick: onClose,
|
|
256
|
+
"data-testid": "sdk.access-cooldown.button"
|
|
257
|
+
}, t("access.cooldown.button"))))));
|
|
278
258
|
};
|
|
279
259
|
//#endregion
|
|
280
260
|
//#region src/components/access/AccessBlocker.js
|
|
@@ -283,13 +263,13 @@ const ICONS = {
|
|
|
283
263
|
expired: HourglassEmptyIcon,
|
|
284
264
|
not_purchased: ShoppingCartIcon
|
|
285
265
|
};
|
|
286
|
-
const AccessBlocker = ({ accessState, buttons = [], daysSinceExpiry, featureKey, workplaceId, cooldownInfo = {}, onTrialRequest, onFeatureRequest
|
|
266
|
+
const AccessBlocker = ({ accessState, buttons = [], daysSinceExpiry, featureKey, workplaceId, backgroundImage, cooldownInfo = {}, onTrialRequest, onFeatureRequest }) => {
|
|
287
267
|
const { t } = useTranslation();
|
|
288
268
|
const [modalOpen, setModalOpen] = useState(false);
|
|
289
269
|
const [cooldownModalOpen, setCooldownModalOpen] = useState(false);
|
|
290
270
|
const [cooldownDays, setCooldownDays] = useState(0);
|
|
291
271
|
const [pendingAction, setPendingAction] = useState(null);
|
|
292
|
-
const styles = makeStyles$1(accessState);
|
|
272
|
+
const styles = makeStyles$1(accessState, backgroundImage);
|
|
293
273
|
const Icon = ICONS[accessState] || LockIcon;
|
|
294
274
|
const handleOpenModal = (button) => {
|
|
295
275
|
if (button.requestType && cooldownInfo[button.requestType]?.isInCooldown) {
|
|
@@ -358,62 +338,37 @@ const AccessBlocker = ({ accessState, buttons = [], daysSinceExpiry, featureKey,
|
|
|
358
338
|
};
|
|
359
339
|
const renderButton = (button) => {
|
|
360
340
|
const label = getButtonLabel(button.action);
|
|
361
|
-
if (button.variant === "link") return /* @__PURE__ */
|
|
341
|
+
if (button.variant === "link") return /* @__PURE__ */ React.createElement(Link, {
|
|
342
|
+
key: button.action,
|
|
362
343
|
component: "button",
|
|
363
344
|
variant: "body2",
|
|
364
345
|
sx: styles.linkButton,
|
|
365
346
|
onClick: () => handleOpenModal(button),
|
|
366
|
-
"data-testid": `sdk.access-blocker.${button.action}
|
|
367
|
-
|
|
368
|
-
}, button.action);
|
|
347
|
+
"data-testid": `sdk.access-blocker.${button.action}`
|
|
348
|
+
}, label);
|
|
369
349
|
const isContained = button.variant === "primary";
|
|
370
|
-
return /* @__PURE__ */
|
|
350
|
+
return /* @__PURE__ */ React.createElement(Button, {
|
|
351
|
+
key: button.action,
|
|
371
352
|
variant: isContained ? "contained" : "outlined",
|
|
372
353
|
sx: isContained ? styles.primaryButton : styles.secondaryButton,
|
|
373
354
|
onClick: () => handleOpenModal(button),
|
|
374
|
-
"data-testid": `sdk.access-blocker.${button.action}
|
|
375
|
-
|
|
376
|
-
}, button.action);
|
|
355
|
+
"data-testid": `sdk.access-blocker.${button.action}`
|
|
356
|
+
}, label);
|
|
377
357
|
};
|
|
378
358
|
const renderButtons = () => {
|
|
379
359
|
if (buttons.length === 0) return null;
|
|
380
|
-
return /* @__PURE__ */
|
|
381
|
-
sx: styles.buttonsContainer,
|
|
382
|
-
children: buttons.map(renderButton)
|
|
383
|
-
});
|
|
360
|
+
return /* @__PURE__ */ React.createElement(Box, { sx: styles.buttonsContainer }, buttons.map(renderButton));
|
|
384
361
|
};
|
|
385
|
-
return /* @__PURE__ */
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
title: getTooltipText(),
|
|
396
|
-
children: /* @__PURE__ */ jsx(Icon, { sx: styles.icon })
|
|
397
|
-
}),
|
|
398
|
-
/* @__PURE__ */ jsx(Typography, {
|
|
399
|
-
variant: "body1",
|
|
400
|
-
children: getMessage()
|
|
401
|
-
}),
|
|
402
|
-
renderButtons()
|
|
403
|
-
]
|
|
404
|
-
}),
|
|
405
|
-
/* @__PURE__ */ jsx(AccessRequestModal, {
|
|
406
|
-
open: modalOpen,
|
|
407
|
-
requestType: pendingAction?.action === "start_trial" ? "start_trial" : pendingAction?.requestType,
|
|
408
|
-
onSubmitRequest: handleSubmitRequest,
|
|
409
|
-
onClose: handleCloseModal
|
|
410
|
-
}),
|
|
411
|
-
/* @__PURE__ */ jsx(CooldownModal, {
|
|
412
|
-
open: cooldownModalOpen,
|
|
413
|
-
daysRemaining: cooldownDays,
|
|
414
|
-
onClose: handleCloseCooldownModal
|
|
415
|
-
})
|
|
416
|
-
] });
|
|
362
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Box, { sx: styles.container }, /* @__PURE__ */ React.createElement(Tooltip, { title: getTooltipText() }, /* @__PURE__ */ React.createElement(Icon, { sx: styles.icon })), /* @__PURE__ */ React.createElement(Typography, { variant: "body1" }, getMessage()), renderButtons()), /* @__PURE__ */ React.createElement(AccessRequestModal, {
|
|
363
|
+
open: modalOpen,
|
|
364
|
+
requestType: pendingAction?.action === "start_trial" ? "start_trial" : pendingAction?.requestType,
|
|
365
|
+
onSubmitRequest: handleSubmitRequest,
|
|
366
|
+
onClose: handleCloseModal
|
|
367
|
+
}), /* @__PURE__ */ React.createElement(CooldownModal, {
|
|
368
|
+
open: cooldownModalOpen,
|
|
369
|
+
daysRemaining: cooldownDays,
|
|
370
|
+
onClose: handleCloseCooldownModal
|
|
371
|
+
}));
|
|
417
372
|
};
|
|
418
373
|
//#endregion
|
|
419
374
|
//#region src/utils/stores.ts
|
|
@@ -750,23 +705,25 @@ const useAccess = (features = [], options = {}) => {
|
|
|
750
705
|
};
|
|
751
706
|
//#endregion
|
|
752
707
|
//#region src/components/access/AccessGuard.js
|
|
753
|
-
const AccessGuard = ({ features: featuresProp = [], extraPermissions = [], workplaceId, onTrialRequest, onFeatureRequest,
|
|
708
|
+
const AccessGuard = ({ features: featuresProp = [], extraPermissions = [], workplaceId, backgroundImage, onTrialRequest, onFeatureRequest, children }) => {
|
|
754
709
|
const { hasAccess, accessState, buttons, cooldownInfo, features } = useAccess(featuresProp, {
|
|
755
710
|
extraPermissions,
|
|
756
711
|
workplaceId
|
|
757
712
|
});
|
|
758
713
|
if (hasAccess) return children;
|
|
759
714
|
const mostRestrictiveFeature = features.find((feat) => feat.accessState === accessState);
|
|
760
|
-
|
|
715
|
+
const daysSinceExpiry = mostRestrictiveFeature?.daysSinceExpiry || null;
|
|
716
|
+
const featureKey = mostRestrictiveFeature?.featureKey || featuresProp[0];
|
|
717
|
+
return /* @__PURE__ */ React.createElement(AccessBlocker, {
|
|
761
718
|
accessState,
|
|
762
719
|
buttons,
|
|
763
|
-
daysSinceExpiry
|
|
764
|
-
featureKey
|
|
720
|
+
daysSinceExpiry,
|
|
721
|
+
featureKey,
|
|
765
722
|
workplaceId,
|
|
723
|
+
backgroundImage,
|
|
766
724
|
cooldownInfo,
|
|
767
725
|
onTrialRequest,
|
|
768
|
-
onFeatureRequest
|
|
769
|
-
backgroundImage
|
|
726
|
+
onFeatureRequest
|
|
770
727
|
});
|
|
771
728
|
};
|
|
772
729
|
//#endregion
|
|
@@ -783,13 +740,13 @@ const withAccessGuard = (featuresProp = [], options = {}) => {
|
|
|
783
740
|
const mostRestrictiveFeature = features.find((feat) => feat.accessState === accessState);
|
|
784
741
|
const daysSinceExpiry = mostRestrictiveFeature?.daysSinceExpiry || null;
|
|
785
742
|
const featureKey = mostRestrictiveFeature?.featureKey || featuresProp[0];
|
|
786
|
-
if (hasAccess) return /* @__PURE__ */
|
|
743
|
+
if (hasAccess) return /* @__PURE__ */ React.createElement(WrappedComponent, {
|
|
787
744
|
...restProps,
|
|
788
745
|
accessState,
|
|
789
746
|
hasAccess,
|
|
790
747
|
missingPermissions
|
|
791
748
|
});
|
|
792
|
-
return /* @__PURE__ */
|
|
749
|
+
return /* @__PURE__ */ React.createElement(AccessBlocker, {
|
|
793
750
|
accessState,
|
|
794
751
|
buttons,
|
|
795
752
|
daysSinceExpiry,
|
|
@@ -879,6 +836,7 @@ const CHANNEL_NAME = "auth-events";
|
|
|
879
836
|
const PROACTIVE_REFRESH_RATIO = .8;
|
|
880
837
|
const MAX_RETRIES = 3;
|
|
881
838
|
const BACKOFF_BASE_MS = 1e3;
|
|
839
|
+
const MAX_SETTIMEOUT_MS = 2e9;
|
|
882
840
|
var TokenCoordinator = class {
|
|
883
841
|
constructor() {
|
|
884
842
|
this.refreshPromise = null;
|
|
@@ -940,6 +898,7 @@ var TokenCoordinator = class {
|
|
|
940
898
|
if (document.visibilityState !== "visible") return;
|
|
941
899
|
if (!this.store?.session) return;
|
|
942
900
|
const { createdAt, expiresIn } = this.store.session;
|
|
901
|
+
if (!(expiresIn > 0)) return;
|
|
943
902
|
const now = Math.round(Date.now() / 1e3);
|
|
944
903
|
if (createdAt + expiresIn < now) this.refresh();
|
|
945
904
|
});
|
|
@@ -1060,7 +1019,8 @@ var TokenCoordinator = class {
|
|
|
1060
1019
|
this.clearRefreshTimer();
|
|
1061
1020
|
if (!this.store?.session) return;
|
|
1062
1021
|
const { expiresIn } = this.store.session;
|
|
1063
|
-
|
|
1022
|
+
if (!(expiresIn > 0)) return;
|
|
1023
|
+
const delayMs = Math.min(expiresIn * PROACTIVE_REFRESH_RATIO * 1e3, MAX_SETTIMEOUT_MS);
|
|
1064
1024
|
this.refreshTimer = setTimeout(() => {
|
|
1065
1025
|
if (!this.refreshPromise) this.refresh();
|
|
1066
1026
|
}, delayMs);
|
|
@@ -1287,7 +1247,7 @@ function createSessionStore() {
|
|
|
1287
1247
|
};
|
|
1288
1248
|
const { createdAt, expiresIn } = this.session;
|
|
1289
1249
|
const now = Math.round(Date.now() / 1e3);
|
|
1290
|
-
if (createdAt + expiresIn < now) {
|
|
1250
|
+
if (expiresIn > 0 && createdAt + expiresIn < now) {
|
|
1291
1251
|
if (!(yield tokenCoordinator.refresh())) {
|
|
1292
1252
|
this.removeSession();
|
|
1293
1253
|
this.setNotAuthorizedLoginStatus();
|
|
@@ -1404,17 +1364,15 @@ const ModalProvider = ({ children }) => {
|
|
|
1404
1364
|
showModal,
|
|
1405
1365
|
modalsConfig
|
|
1406
1366
|
]);
|
|
1407
|
-
return /* @__PURE__ */
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
})]
|
|
1417
|
-
});
|
|
1367
|
+
return /* @__PURE__ */ React.createElement(ModalContext.Provider, { value: contextValue }, children, Object.keys(modalsConfig).map((modalKey) => {
|
|
1368
|
+
const { component: Component, isOpen, data } = modalsConfig[modalKey];
|
|
1369
|
+
return isOpen && /* @__PURE__ */ React.createElement(Component, {
|
|
1370
|
+
onClose: () => hideModal(modalKey),
|
|
1371
|
+
key: modalKey,
|
|
1372
|
+
isOpen,
|
|
1373
|
+
...data
|
|
1374
|
+
});
|
|
1375
|
+
}));
|
|
1418
1376
|
};
|
|
1419
1377
|
//#endregion
|
|
1420
1378
|
//#region src/hooks/useModalHook/useModal.js
|
|
@@ -1790,80 +1748,55 @@ const Footer = ({ appVersion, apiVersion }) => {
|
|
|
1790
1748
|
const renderAppVersion = () => {
|
|
1791
1749
|
if (appVersion) {
|
|
1792
1750
|
const versionText = appVersion.startsWith("v") ? appVersion : `v${appVersion}`;
|
|
1793
|
-
return /* @__PURE__ */
|
|
1794
|
-
/* @__PURE__ */ jsx("span", { children: t("Version") }),
|
|
1795
|
-
" ",
|
|
1796
|
-
versionText
|
|
1797
|
-
] });
|
|
1751
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement("span", null, t("Version")), " ", versionText);
|
|
1798
1752
|
}
|
|
1799
1753
|
};
|
|
1800
1754
|
const renderApiVersion = () => {
|
|
1801
1755
|
if (apiVersion) {
|
|
1802
1756
|
const versionText = apiVersion.startsWith("v") ? apiVersion : `v${apiVersion}`;
|
|
1803
|
-
return /* @__PURE__ */
|
|
1804
|
-
/* @__PURE__ */ jsx("span", { children: "API" }),
|
|
1805
|
-
" ",
|
|
1806
|
-
versionText
|
|
1807
|
-
] });
|
|
1757
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement("span", null, "API"), " ", versionText);
|
|
1808
1758
|
}
|
|
1809
1759
|
};
|
|
1810
|
-
return /* @__PURE__ */
|
|
1760
|
+
return /* @__PURE__ */ React.createElement(Overlay, null, renderAppVersion(), renderApiVersion());
|
|
1811
1761
|
};
|
|
1812
1762
|
//#endregion
|
|
1813
1763
|
//#region src/pages/ErrorPage.js
|
|
1814
1764
|
const ErrorPage = ({ error, appVersion, apiVersion }) => {
|
|
1815
1765
|
const { t } = useTranslation();
|
|
1816
1766
|
const containerStyles = makeStyles({ isEmbeddedMode: getDisplayMode() === "iframe" });
|
|
1817
|
-
return /* @__PURE__ */
|
|
1767
|
+
return /* @__PURE__ */ React.createElement(Container$1, {
|
|
1818
1768
|
maxWidth: false,
|
|
1819
1769
|
disableGutters: true,
|
|
1820
|
-
sx: containerStyles.root
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
fontSize: "inherit"
|
|
1851
|
-
} })
|
|
1852
|
-
})]
|
|
1853
|
-
}), /* @__PURE__ */ jsx(Button, {
|
|
1854
|
-
onClick: () => window.location.reload(),
|
|
1855
|
-
children: t("networkErrorButtonText")
|
|
1856
|
-
})]
|
|
1857
|
-
})
|
|
1858
|
-
})
|
|
1859
|
-
}),
|
|
1860
|
-
/* @__PURE__ */ jsx(Box, { sx: containerStyles.overlay }),
|
|
1861
|
-
/* @__PURE__ */ jsx(Footer, {
|
|
1862
|
-
appVersion,
|
|
1863
|
-
apiVersion
|
|
1864
|
-
})
|
|
1865
|
-
]
|
|
1866
|
-
});
|
|
1770
|
+
sx: containerStyles.root
|
|
1771
|
+
}, /* @__PURE__ */ React.createElement(Card, { style: {
|
|
1772
|
+
background: "linear-gradient(180deg, #393939 0%, #4A4A4A 100%)",
|
|
1773
|
+
maxWidth: "650px",
|
|
1774
|
+
margin: "200px auto",
|
|
1775
|
+
borderRadius: "20px"
|
|
1776
|
+
} }, /* @__PURE__ */ React.createElement(CardContent, { style: { minHeight: "unset" } }, /* @__PURE__ */ React.createElement(Box, {
|
|
1777
|
+
display: "flex",
|
|
1778
|
+
flexDirection: "column",
|
|
1779
|
+
alignItems: "center",
|
|
1780
|
+
justifyContent: "center",
|
|
1781
|
+
m: "125px 80px"
|
|
1782
|
+
}, /* @__PURE__ */ React.createElement(Typography, {
|
|
1783
|
+
variant: "h4",
|
|
1784
|
+
sx: {
|
|
1785
|
+
display: "flex",
|
|
1786
|
+
alignItems: "center",
|
|
1787
|
+
marginBottom: "40px",
|
|
1788
|
+
color: "rgba(255, 255, 255, 0.6)"
|
|
1789
|
+
}
|
|
1790
|
+
}, t("somethingWentWrongMessage"), /* @__PURE__ */ React.createElement(Tooltip, {
|
|
1791
|
+
title: error.toString(),
|
|
1792
|
+
arrow: true
|
|
1793
|
+
}, /* @__PURE__ */ React.createElement(HelpOutlineIcon, { sx: {
|
|
1794
|
+
marginLeft: "1em",
|
|
1795
|
+
fontSize: "inherit"
|
|
1796
|
+
} }))), /* @__PURE__ */ React.createElement(Button, { onClick: () => window.location.reload() }, t("networkErrorButtonText"))))), /* @__PURE__ */ React.createElement(Box, { sx: containerStyles.overlay }), /* @__PURE__ */ React.createElement(Footer, {
|
|
1797
|
+
appVersion,
|
|
1798
|
+
apiVersion
|
|
1799
|
+
}));
|
|
1867
1800
|
};
|
|
1868
1801
|
ErrorPage.propTypes = {
|
|
1869
1802
|
error: PropTypes.any,
|
|
@@ -1876,19 +1809,18 @@ var loader_default = "data:image/svg+xml,<?xml version=\"1.0\" encoding=\"utf-8\
|
|
|
1876
1809
|
//#endregion
|
|
1877
1810
|
//#region src/components/loader.js
|
|
1878
1811
|
const Loader = ({ width, "data-testid": dataTestId }) => {
|
|
1879
|
-
return /* @__PURE__ */
|
|
1812
|
+
return /* @__PURE__ */ React.createElement(Box, {
|
|
1880
1813
|
display: "flex",
|
|
1881
1814
|
alignItems: "center",
|
|
1882
1815
|
justifyContent: "center",
|
|
1883
1816
|
width: "100%",
|
|
1884
|
-
height: "100%"
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
});
|
|
1817
|
+
height: "100%"
|
|
1818
|
+
}, /* @__PURE__ */ React.createElement("img", {
|
|
1819
|
+
"data-testid": dataTestId,
|
|
1820
|
+
alt: "loader",
|
|
1821
|
+
width,
|
|
1822
|
+
src: loader_default
|
|
1823
|
+
}));
|
|
1892
1824
|
};
|
|
1893
1825
|
//#endregion
|
|
1894
1826
|
//#region src/providers/display.js
|
|
@@ -1897,17 +1829,14 @@ const DisplayProvider = ({ children }) => {
|
|
|
1897
1829
|
const [iframeMounted, setIframeMounted] = useState(false);
|
|
1898
1830
|
const [iframeNavigationItems, setIframeNavigationItems] = useState([]);
|
|
1899
1831
|
const mode = getDisplayMode();
|
|
1900
|
-
return /* @__PURE__ */
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
},
|
|
1909
|
-
children
|
|
1910
|
-
});
|
|
1832
|
+
return /* @__PURE__ */ React.createElement(DisplayContext.Provider, { value: {
|
|
1833
|
+
mode,
|
|
1834
|
+
isEmbeddedMode: mode === "iframe",
|
|
1835
|
+
iframeMounted,
|
|
1836
|
+
setIframeMounted,
|
|
1837
|
+
iframeNavigationItems,
|
|
1838
|
+
setIframeNavigationItems
|
|
1839
|
+
} }, children);
|
|
1911
1840
|
};
|
|
1912
1841
|
const useDisplay = () => {
|
|
1913
1842
|
return useContext(DisplayContext);
|
|
@@ -1917,15 +1846,14 @@ const useDisplay = () => {
|
|
|
1917
1846
|
const LoaderPage = () => {
|
|
1918
1847
|
const { isEmbeddedMode } = useDisplay();
|
|
1919
1848
|
const containerStyles = makeStyles({ isEmbeddedMode });
|
|
1920
|
-
return /* @__PURE__ */
|
|
1849
|
+
return /* @__PURE__ */ React.createElement(Container$1, {
|
|
1921
1850
|
maxWidth: false,
|
|
1922
1851
|
disableGutters: true,
|
|
1923
|
-
sx: containerStyles.root
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
});
|
|
1852
|
+
sx: containerStyles.root
|
|
1853
|
+
}, /* @__PURE__ */ React.createElement(Loader, {
|
|
1854
|
+
"data-testid": "sdk.app-loading",
|
|
1855
|
+
width: "500px"
|
|
1856
|
+
}), /* @__PURE__ */ React.createElement(Box, { sx: containerStyles.overlay }));
|
|
1929
1857
|
};
|
|
1930
1858
|
LoaderPage.propTypes = {};
|
|
1931
1859
|
LoaderPage.defaultProps = {};
|
|
@@ -1933,10 +1861,7 @@ LoaderPage.defaultProps = {};
|
|
|
1933
1861
|
//#region src/providers/authConfig.js
|
|
1934
1862
|
const AuthConfigContext = createContext();
|
|
1935
1863
|
const AuthConfigProvider = ({ children, config }) => {
|
|
1936
|
-
return /* @__PURE__ */
|
|
1937
|
-
value: config,
|
|
1938
|
-
children
|
|
1939
|
-
});
|
|
1864
|
+
return /* @__PURE__ */ React.createElement(AuthConfigContext.Provider, { value: config }, children);
|
|
1940
1865
|
};
|
|
1941
1866
|
const useAuthConfig = () => {
|
|
1942
1867
|
return useContext(AuthConfigContext);
|
|
@@ -1945,10 +1870,7 @@ const useAuthConfig = () => {
|
|
|
1945
1870
|
//#region src/providers/metaInfo.js
|
|
1946
1871
|
const MetaInfoContext = createContext();
|
|
1947
1872
|
const MetaInfoProvider = ({ children, info }) => {
|
|
1948
|
-
return /* @__PURE__ */
|
|
1949
|
-
value: info,
|
|
1950
|
-
children
|
|
1951
|
-
});
|
|
1873
|
+
return /* @__PURE__ */ React.createElement(MetaInfoContext.Provider, { value: info }, children);
|
|
1952
1874
|
};
|
|
1953
1875
|
const useMetaInfo = () => {
|
|
1954
1876
|
return useContext(MetaInfoContext);
|
|
@@ -1958,10 +1880,7 @@ const useMetaInfo = () => {
|
|
|
1958
1880
|
const rootStore = { sessionStore };
|
|
1959
1881
|
const StoreContext = createContext(rootStore);
|
|
1960
1882
|
const StoreProvider = observer(({ children }) => {
|
|
1961
|
-
return /* @__PURE__ */
|
|
1962
|
-
value: rootStore,
|
|
1963
|
-
children
|
|
1964
|
-
});
|
|
1883
|
+
return /* @__PURE__ */ React.createElement(StoreContext.Provider, { value: rootStore }, children);
|
|
1965
1884
|
});
|
|
1966
1885
|
const useStore = () => {
|
|
1967
1886
|
return useContext(StoreContext);
|
|
@@ -2281,58 +2200,35 @@ const NetworkError = ({ error }) => {
|
|
|
2281
2200
|
const { isEmbeddedMode } = useDisplay();
|
|
2282
2201
|
const { t } = useTranslation();
|
|
2283
2202
|
const containerStyles = makeStyles({ isEmbeddedMode });
|
|
2284
|
-
return /* @__PURE__ */
|
|
2203
|
+
return /* @__PURE__ */ React.createElement(Container$1, {
|
|
2285
2204
|
maxWidth: false,
|
|
2286
2205
|
disableGutters: true,
|
|
2287
|
-
sx: containerStyles.root
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
|
|
2311
|
-
|
|
2312
|
-
|
|
2313
|
-
display: "inline-flex",
|
|
2314
|
-
textAlign: "center",
|
|
2315
|
-
color: "rgba(255, 255, 255, 0.6)"
|
|
2316
|
-
},
|
|
2317
|
-
children: [/* @__PURE__ */ jsx(Typography, {
|
|
2318
|
-
mr: 2,
|
|
2319
|
-
children: error.title
|
|
2320
|
-
}), /* @__PURE__ */ jsx(Tooltip, {
|
|
2321
|
-
title: error.details,
|
|
2322
|
-
arrow: true,
|
|
2323
|
-
children: /* @__PURE__ */ jsx(HelpOutlineIcon, {})
|
|
2324
|
-
})]
|
|
2325
|
-
}),
|
|
2326
|
-
/* @__PURE__ */ jsx(Button, {
|
|
2327
|
-
onClick: () => window.location.reload(),
|
|
2328
|
-
"data-testid": "sdk.network-error.reload",
|
|
2329
|
-
children: t("networkErrorButtonText")
|
|
2330
|
-
})
|
|
2331
|
-
]
|
|
2332
|
-
})
|
|
2333
|
-
})
|
|
2334
|
-
}), /* @__PURE__ */ jsx(Box, { sx: containerStyles.overlay })]
|
|
2335
|
-
});
|
|
2206
|
+
sx: containerStyles.root
|
|
2207
|
+
}, /* @__PURE__ */ React.createElement(Card, { style: {
|
|
2208
|
+
background: "linear-gradient(180deg, #393939 0%, #4A4A4A 100%)",
|
|
2209
|
+
maxWidth: "600px",
|
|
2210
|
+
margin: "200px auto",
|
|
2211
|
+
borderRadius: "20px"
|
|
2212
|
+
} }, /* @__PURE__ */ React.createElement(CardContent, { style: { minHeight: "unset" } }, /* @__PURE__ */ React.createElement(Box, {
|
|
2213
|
+
display: "flex",
|
|
2214
|
+
flexDirection: "column",
|
|
2215
|
+
alignItems: "center",
|
|
2216
|
+
justifyContent: "center",
|
|
2217
|
+
m: "125px 80px"
|
|
2218
|
+
}, /* @__PURE__ */ React.createElement("h1", { style: {
|
|
2219
|
+
textAlign: "center",
|
|
2220
|
+
color: "rgba(255, 255, 255, 0.6)"
|
|
2221
|
+
} }, t("networkErrorHeader")), /* @__PURE__ */ React.createElement("p", { style: {
|
|
2222
|
+
display: "inline-flex",
|
|
2223
|
+
textAlign: "center",
|
|
2224
|
+
color: "rgba(255, 255, 255, 0.6)"
|
|
2225
|
+
} }, /* @__PURE__ */ React.createElement(Typography, { mr: 2 }, error.title), /* @__PURE__ */ React.createElement(Tooltip, {
|
|
2226
|
+
title: error.details,
|
|
2227
|
+
arrow: true
|
|
2228
|
+
}, /* @__PURE__ */ React.createElement(HelpOutlineIcon, null))), /* @__PURE__ */ React.createElement(Button, {
|
|
2229
|
+
onClick: () => window.location.reload(),
|
|
2230
|
+
"data-testid": "sdk.network-error.reload"
|
|
2231
|
+
}, t("networkErrorButtonText"))))), /* @__PURE__ */ React.createElement(Box, { sx: containerStyles.overlay }));
|
|
2336
2232
|
};
|
|
2337
2233
|
//#endregion
|
|
2338
2234
|
//#region src/hooks/useQueryParams.js
|
|
@@ -2370,7 +2266,7 @@ const AuthRedirect = () => {
|
|
|
2370
2266
|
sessionStore.authorize({ code });
|
|
2371
2267
|
}
|
|
2372
2268
|
}, [queryParams]);
|
|
2373
|
-
if (sessionStore.isLoggedIn) return /* @__PURE__ */
|
|
2269
|
+
if (sessionStore.isLoggedIn) return /* @__PURE__ */ React.createElement(Navigate, { to: nextPath });
|
|
2374
2270
|
return null;
|
|
2375
2271
|
};
|
|
2376
2272
|
//#endregion
|
|
@@ -2482,144 +2378,98 @@ const LoginForm = ({ scope, redirectPath, onSuccess, onFailure, onCancel, storeS
|
|
|
2482
2378
|
setPassword(event.target.value);
|
|
2483
2379
|
if (passwordError) setPasswordError(null);
|
|
2484
2380
|
};
|
|
2485
|
-
return /* @__PURE__ */
|
|
2381
|
+
return /* @__PURE__ */ React.createElement("form", {
|
|
2486
2382
|
onSubmit: handleSubmit,
|
|
2487
|
-
"data-testid": dataTestID || "sdk.login-form"
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2541
|
-
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
|
|
2547
|
-
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
|
|
2552
|
-
|
|
2553
|
-
|
|
2554
|
-
|
|
2555
|
-
|
|
2556
|
-
|
|
2557
|
-
|
|
2558
|
-
|
|
2559
|
-
|
|
2560
|
-
|
|
2561
|
-
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
|
|
2565
|
-
|
|
2566
|
-
|
|
2567
|
-
|
|
2568
|
-
|
|
2569
|
-
|
|
2570
|
-
|
|
2571
|
-
|
|
2572
|
-
|
|
2573
|
-
|
|
2574
|
-
|
|
2575
|
-
|
|
2576
|
-
|
|
2577
|
-
loading: sessionStore.loading,
|
|
2578
|
-
"data-testid": "sdk.login-form-submit-button",
|
|
2579
|
-
children: t("loginCardSubmitButton")
|
|
2580
|
-
}),
|
|
2581
|
-
/* @__PURE__ */ jsx(Button, {
|
|
2582
|
-
id: "cancel-button",
|
|
2583
|
-
type: "button",
|
|
2584
|
-
variant: "outlined",
|
|
2585
|
-
size: "large",
|
|
2586
|
-
color: "secondary",
|
|
2587
|
-
onClick: handleCancel,
|
|
2588
|
-
"data-testid": "sdk.login-form-cancel-button",
|
|
2589
|
-
children: t("loginCardCancelButton")
|
|
2590
|
-
})
|
|
2591
|
-
]
|
|
2592
|
-
}),
|
|
2593
|
-
/* @__PURE__ */ jsx(Box, {
|
|
2594
|
-
m: "30px 0 40px 0",
|
|
2595
|
-
color: "rgba(255, 255, 255, 0.6)",
|
|
2596
|
-
children: /* @__PURE__ */ jsx(Typography, {
|
|
2597
|
-
align: "center",
|
|
2598
|
-
color: "inherit",
|
|
2599
|
-
children: "or scan"
|
|
2600
|
-
})
|
|
2601
|
-
}),
|
|
2602
|
-
/* @__PURE__ */ jsxs(Box, {
|
|
2603
|
-
display: "grid",
|
|
2604
|
-
gridTemplateColumns: "1fr 1fr 1fr",
|
|
2605
|
-
alignItems: "center",
|
|
2606
|
-
justifyItems: "center",
|
|
2607
|
-
marginBottom: "30px",
|
|
2608
|
-
children: [
|
|
2609
|
-
/* @__PURE__ */ jsx(Box, {
|
|
2610
|
-
style: { filter: "brightness(0.5)" },
|
|
2611
|
-
children: /* @__PURE__ */ jsx(QRCodeSVG, {})
|
|
2612
|
-
}),
|
|
2613
|
-
/* @__PURE__ */ jsx(BarcodeSVG, {}),
|
|
2614
|
-
/* @__PURE__ */ jsx(Box, {
|
|
2615
|
-
style: { filter: "brightness(0.5)" },
|
|
2616
|
-
children: /* @__PURE__ */ jsx(RFIDCardSVG, {})
|
|
2617
|
-
})
|
|
2618
|
-
]
|
|
2619
|
-
})
|
|
2620
|
-
]
|
|
2621
|
-
})
|
|
2622
|
-
});
|
|
2383
|
+
"data-testid": dataTestID || "sdk.login-form"
|
|
2384
|
+
}, /* @__PURE__ */ React.createElement(Box, { m: "0 80px" }, /* @__PURE__ */ React.createElement(Box, {
|
|
2385
|
+
display: "flex",
|
|
2386
|
+
flexDirection: "column",
|
|
2387
|
+
alignItems: "center",
|
|
2388
|
+
justifyContent: "center",
|
|
2389
|
+
gap: 2,
|
|
2390
|
+
m: "100px 0"
|
|
2391
|
+
}, /* @__PURE__ */ React.createElement(AcLogoSVG, null), releaseVersion && /* @__PURE__ */ React.createElement(Link, {
|
|
2392
|
+
href: releasePageLink,
|
|
2393
|
+
target: "_blank",
|
|
2394
|
+
fontSize: "14px",
|
|
2395
|
+
sx: {
|
|
2396
|
+
display: "flex",
|
|
2397
|
+
alignItems: "center",
|
|
2398
|
+
gap: .5,
|
|
2399
|
+
textDecoration: "none",
|
|
2400
|
+
"&:hover": {
|
|
2401
|
+
cursor: "pointer",
|
|
2402
|
+
opacity: .8
|
|
2403
|
+
}
|
|
2404
|
+
}
|
|
2405
|
+
}, /* @__PURE__ */ React.createElement("img", {
|
|
2406
|
+
src: info_icon_default,
|
|
2407
|
+
alt: "info",
|
|
2408
|
+
width: "14px",
|
|
2409
|
+
height: "14px"
|
|
2410
|
+
}), t("release"), " ", releaseVersion)), /* @__PURE__ */ React.createElement(Box, {
|
|
2411
|
+
m: "0 0 30px 0",
|
|
2412
|
+
color: "rgba(255, 255, 255, 0.6)"
|
|
2413
|
+
}, /* @__PURE__ */ React.createElement(Typography, {
|
|
2414
|
+
align: "center",
|
|
2415
|
+
color: "inherit"
|
|
2416
|
+
}, title)), /* @__PURE__ */ React.createElement(Box, {
|
|
2417
|
+
m: "0",
|
|
2418
|
+
display: "grid",
|
|
2419
|
+
sx: { gridGap: "18px" },
|
|
2420
|
+
gridTemplateColumns: "1fr"
|
|
2421
|
+
}, /* @__PURE__ */ React.createElement(FormControl, { fullWidth: true }, /* @__PURE__ */ React.createElement(TextField, {
|
|
2422
|
+
autoFocus: true,
|
|
2423
|
+
fullWidth: true,
|
|
2424
|
+
variant: "outlined",
|
|
2425
|
+
label: t("loginCardUsernameHint"),
|
|
2426
|
+
onChange: handleChangeForUsername,
|
|
2427
|
+
value: username,
|
|
2428
|
+
error: Boolean(usernameError),
|
|
2429
|
+
helperText: usernameError,
|
|
2430
|
+
id: "login-input",
|
|
2431
|
+
inputProps: { "data-testid": "sdk.login-form-username-input" }
|
|
2432
|
+
})), /* @__PURE__ */ React.createElement(FormControl, { fullWidth: true }, /* @__PURE__ */ React.createElement(TextField, {
|
|
2433
|
+
fullWidth: true,
|
|
2434
|
+
variant: "outlined",
|
|
2435
|
+
label: t("loginCardPasswordHint"),
|
|
2436
|
+
onChange: handleChangeForPassword,
|
|
2437
|
+
value: password,
|
|
2438
|
+
error: Boolean(passwordError),
|
|
2439
|
+
helperText: passwordError,
|
|
2440
|
+
type: "password",
|
|
2441
|
+
id: "password-input",
|
|
2442
|
+
inputProps: { "data-testid": "sdk.login-form-password-input" }
|
|
2443
|
+
})), /* @__PURE__ */ React.createElement(LoadingButton, {
|
|
2444
|
+
id: "login-button",
|
|
2445
|
+
type: "submit",
|
|
2446
|
+
variant: "contained",
|
|
2447
|
+
size: "large",
|
|
2448
|
+
color: "primary",
|
|
2449
|
+
onClick: handleSubmit,
|
|
2450
|
+
loading: sessionStore.loading,
|
|
2451
|
+
"data-testid": "sdk.login-form-submit-button"
|
|
2452
|
+
}, t("loginCardSubmitButton")), /* @__PURE__ */ React.createElement(Button, {
|
|
2453
|
+
id: "cancel-button",
|
|
2454
|
+
type: "button",
|
|
2455
|
+
variant: "outlined",
|
|
2456
|
+
size: "large",
|
|
2457
|
+
color: "secondary",
|
|
2458
|
+
onClick: handleCancel,
|
|
2459
|
+
"data-testid": "sdk.login-form-cancel-button"
|
|
2460
|
+
}, t("loginCardCancelButton"))), /* @__PURE__ */ React.createElement(Box, {
|
|
2461
|
+
m: "30px 0 40px 0",
|
|
2462
|
+
color: "rgba(255, 255, 255, 0.6)"
|
|
2463
|
+
}, /* @__PURE__ */ React.createElement(Typography, {
|
|
2464
|
+
align: "center",
|
|
2465
|
+
color: "inherit"
|
|
2466
|
+
}, "or scan")), /* @__PURE__ */ React.createElement(Box, {
|
|
2467
|
+
display: "grid",
|
|
2468
|
+
gridTemplateColumns: "1fr 1fr 1fr",
|
|
2469
|
+
alignItems: "center",
|
|
2470
|
+
justifyItems: "center",
|
|
2471
|
+
marginBottom: "30px"
|
|
2472
|
+
}, /* @__PURE__ */ React.createElement(Box, { style: { filter: "brightness(0.5)" } }, /* @__PURE__ */ React.createElement(QRCodeSVG, null)), /* @__PURE__ */ React.createElement(BarcodeSVG, null), /* @__PURE__ */ React.createElement(Box, { style: { filter: "brightness(0.5)" } }, /* @__PURE__ */ React.createElement(RFIDCardSVG, null)))));
|
|
2623
2473
|
};
|
|
2624
2474
|
LoginForm.propTypes = {
|
|
2625
2475
|
scope: PropTypes.string,
|
|
@@ -2635,361 +2485,269 @@ LoginForm.defaultProps = {
|
|
|
2635
2485
|
};
|
|
2636
2486
|
var loginForm_default = observer(LoginForm);
|
|
2637
2487
|
const QRCodeSVG = () => {
|
|
2638
|
-
return /* @__PURE__ */
|
|
2488
|
+
return /* @__PURE__ */ React.createElement("svg", {
|
|
2639
2489
|
width: "51",
|
|
2640
2490
|
height: "53",
|
|
2641
2491
|
viewBox: "0 0 51 53",
|
|
2642
2492
|
fill: "none",
|
|
2643
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
2644
|
-
|
|
2645
|
-
|
|
2646
|
-
|
|
2647
|
-
|
|
2648
|
-
|
|
2649
|
-
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
|
|
2655
|
-
|
|
2656
|
-
|
|
2657
|
-
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
|
|
2668
|
-
|
|
2669
|
-
|
|
2670
|
-
|
|
2671
|
-
|
|
2672
|
-
|
|
2673
|
-
|
|
2674
|
-
|
|
2675
|
-
|
|
2676
|
-
|
|
2677
|
-
|
|
2678
|
-
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
|
|
2709
|
-
|
|
2710
|
-
|
|
2711
|
-
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
fill: "white",
|
|
2731
|
-
fillOpacity: "0.35"
|
|
2732
|
-
}),
|
|
2733
|
-
/* @__PURE__ */ jsx("path", {
|
|
2734
|
-
d: "M12.6408 1.63985H16.7391V0.00012207H11.0234V5.73188H12.6627L12.6408 1.63985Z",
|
|
2735
|
-
fill: "white",
|
|
2736
|
-
fillOpacity: "0.35"
|
|
2737
|
-
}),
|
|
2738
|
-
/* @__PURE__ */ jsx("path", {
|
|
2739
|
-
d: "M37.3678 26.3603H33.2695V28.0001H39.0071V22.261H37.3678V26.3603Z",
|
|
2740
|
-
fill: "white",
|
|
2741
|
-
fillOpacity: "0.35"
|
|
2742
|
-
}),
|
|
2743
|
-
/* @__PURE__ */ jsx("path", {
|
|
2744
|
-
d: "M12.6408 22.261H11.0234V28.0001H16.761V26.3603H12.6627L12.6408 22.261Z",
|
|
2745
|
-
fill: "white",
|
|
2746
|
-
fillOpacity: "0.35"
|
|
2747
|
-
})
|
|
2748
|
-
]
|
|
2749
|
-
}),
|
|
2750
|
-
/* @__PURE__ */ jsx("defs", { children: /* @__PURE__ */ jsx("clipPath", {
|
|
2751
|
-
id: "clip0_2183_35009",
|
|
2752
|
-
children: /* @__PURE__ */ jsx("rect", {
|
|
2753
|
-
width: "28",
|
|
2754
|
-
height: "28",
|
|
2755
|
-
fill: "white",
|
|
2756
|
-
transform: "translate(11 0.00012207)"
|
|
2757
|
-
})
|
|
2758
|
-
}) })
|
|
2759
|
-
]
|
|
2760
|
-
});
|
|
2493
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
2494
|
+
}, /* @__PURE__ */ React.createElement("path", {
|
|
2495
|
+
d: "M8.66868 45.6365C8.66868 42.8453 6.99822 41.1535 4.7397 41.1535C2.47266 41.1535 0.806463 42.8453 0.806463 45.6365C0.806463 48.4234 2.47266 50.1194 4.7397 50.1194C5.3022 50.1194 5.82635 50.0172 6.2951 49.8169L7.04084 50.7842H8.38743L7.21129 49.2501C8.1147 48.4873 8.66868 47.243 8.66868 45.6365ZM4.29652 47.1706L5.53658 48.7984C5.28942 48.8794 5.02095 48.9177 4.7397 48.9177C3.23544 48.9177 2.1147 47.7629 2.1147 45.6365C2.1147 43.5101 3.23544 42.3552 4.7397 42.3552C6.2397 42.3552 7.3647 43.5101 7.3647 45.6365C7.3647 46.8297 7.01101 47.7203 6.43146 48.2657L5.59197 47.1706H4.29652ZM10.3104 50.0001H11.6271V46.6976H13.4169C13.4467 46.6976 13.4723 46.6976 13.5021 46.6976L15.2749 50.0001H16.7749L14.8402 46.4675C15.9098 46.0711 16.4425 45.1805 16.4425 44.0086C16.4425 42.4021 15.4453 41.2728 13.4212 41.2728H10.3104V50.0001ZM11.6271 45.564V42.4021H13.2805C14.5803 42.4021 15.1172 43.02 15.1172 44.0086C15.1172 44.993 14.5803 45.564 13.2976 45.564H11.6271ZM28.4691 44.1109C28.1708 42.2444 26.7092 41.1535 24.864 41.1535C22.6055 41.1535 20.9393 42.8453 20.9393 45.6365C20.9393 48.4277 22.5969 50.1194 24.864 50.1194C26.7816 50.1194 28.1836 48.9177 28.4691 47.1919L27.1396 47.1876C26.9137 48.3041 25.9762 48.9177 24.8725 48.9177C23.3768 48.9177 22.2475 47.7714 22.2475 45.6365C22.2475 43.5186 23.3725 42.3552 24.8768 42.3552C25.989 42.3552 26.9222 42.9817 27.1396 44.1109H28.4691ZM32.6996 50.1322C34.5447 50.1322 35.7507 48.7814 35.7507 46.7572C35.7507 44.7203 34.5447 43.3694 32.6996 43.3694C30.8544 43.3694 29.6484 44.7203 29.6484 46.7572C29.6484 48.7814 30.8544 50.1322 32.6996 50.1322ZM32.7038 49.0626C31.4979 49.0626 30.9354 48.0101 30.9354 46.753C30.9354 45.5001 31.4979 44.4348 32.7038 44.4348C33.9013 44.4348 34.4638 45.5001 34.4638 46.753C34.4638 48.0101 33.9013 49.0626 32.7038 49.0626ZM39.6232 50.128C40.8164 50.128 41.2852 49.3993 41.5153 48.9817H41.6218V50.0001H42.8661V41.2728H41.592V44.5157H41.5153C41.2852 44.1109 40.8505 43.3694 39.6317 43.3694C38.0508 43.3694 36.8874 44.618 36.8874 46.7402C36.8874 48.8581 38.0337 50.128 39.6232 50.128ZM39.9045 49.0413C38.7667 49.0413 38.1744 48.0399 38.1744 46.7274C38.1744 45.4277 38.7539 44.4518 39.9045 44.4518C41.0167 44.4518 41.6133 45.3595 41.6133 46.7274C41.6133 48.1038 41.0039 49.0413 39.9045 49.0413ZM47.5057 50.1322C48.9332 50.1322 49.9432 49.4291 50.233 48.3638L49.027 48.1464C48.7969 48.7643 48.2429 49.0797 47.5185 49.0797C46.4276 49.0797 45.6946 48.3723 45.6605 47.1109H50.3139V46.6592C50.3139 44.2942 48.8991 43.3694 47.4162 43.3694C45.5923 43.3694 44.3906 44.7586 44.3906 46.77C44.3906 48.8027 45.5753 50.1322 47.5057 50.1322ZM45.6648 46.1564C45.7159 45.2274 46.3892 44.422 47.4247 44.422C48.4134 44.422 49.0611 45.155 49.0653 46.1564H45.6648Z",
|
|
2496
|
+
fill: "white",
|
|
2497
|
+
fillOpacity: "0.35"
|
|
2498
|
+
}), /* @__PURE__ */ React.createElement("g", { clipPath: "url(#clip0_2183_35009)" }, /* @__PURE__ */ React.createElement("path", {
|
|
2499
|
+
d: "M22.3002 3.27948H14.25V11.3318H22.3002V3.27948ZM20.6609 9.66275H15.9186V4.91923H20.6609V9.66275Z",
|
|
2500
|
+
fill: "white",
|
|
2501
|
+
fillOpacity: "0.35"
|
|
2502
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2503
|
+
d: "M19.1081 6.47128H17.4688V8.11102H19.1081V6.47128Z",
|
|
2504
|
+
fill: "white",
|
|
2505
|
+
fillOpacity: "0.35"
|
|
2506
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2507
|
+
d: "M14.2773 24.7206H22.3275V16.7122H14.2773V24.7206ZM15.9166 18.3373H20.6589V23.0809H15.9166V18.3373Z",
|
|
2508
|
+
fill: "white",
|
|
2509
|
+
fillOpacity: "0.35"
|
|
2510
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2511
|
+
d: "M35.7147 17.5176H34.0754V23.081H32.4653V21.8366H30.826V23.0591H28.8281V24.6988H35.7147V17.5176Z",
|
|
2512
|
+
fill: "white",
|
|
2513
|
+
fillOpacity: "0.35"
|
|
2514
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2515
|
+
d: "M19.1081 19.8893H17.4688V21.529H19.1081V19.8893Z",
|
|
2516
|
+
fill: "white",
|
|
2517
|
+
fillOpacity: "0.35"
|
|
2518
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2519
|
+
d: "M35.7142 3.27948H27.6641V11.3318H35.7142V3.27948ZM34.0749 9.66275H29.318V4.91923H34.0603L34.0749 9.66275Z",
|
|
2520
|
+
fill: "white",
|
|
2521
|
+
fillOpacity: "0.35"
|
|
2522
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2523
|
+
d: "M32.5221 6.47128H30.8828V8.11102H32.5221V6.47128Z",
|
|
2524
|
+
fill: "white",
|
|
2525
|
+
fillOpacity: "0.35"
|
|
2526
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2527
|
+
d: "M22.3014 13.184H17.5664V14.8237H22.3014V13.184Z",
|
|
2528
|
+
fill: "white",
|
|
2529
|
+
fillOpacity: "0.35"
|
|
2530
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2531
|
+
d: "M15.9167 13.184H14.2773V14.8237H15.9167V13.184Z",
|
|
2532
|
+
fill: "white",
|
|
2533
|
+
fillOpacity: "0.35"
|
|
2534
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2535
|
+
d: "M30.041 13.184H23.9375V14.8237H30.041V13.184Z",
|
|
2536
|
+
fill: "white",
|
|
2537
|
+
fillOpacity: "0.35"
|
|
2538
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2539
|
+
d: "M35.7121 15.8778V13.1766H31.6797V14.8237H34.0728V15.8778H35.7121Z",
|
|
2540
|
+
fill: "white",
|
|
2541
|
+
fillOpacity: "0.35"
|
|
2542
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2543
|
+
d: "M25.819 6.56622H24.1797V11.3024H25.819V6.56622Z",
|
|
2544
|
+
fill: "white",
|
|
2545
|
+
fillOpacity: "0.35"
|
|
2546
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2547
|
+
d: "M25.819 3.27948H24.1797V4.91922H25.819V3.27948Z",
|
|
2548
|
+
fill: "white",
|
|
2549
|
+
fillOpacity: "0.35"
|
|
2550
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2551
|
+
d: "M25.82 21.4338H27.0348V19.7941H25.82V16.7122H24.1953V24.7645H27.1958V23.0809H25.8346L25.82 21.4338Z",
|
|
2552
|
+
fill: "white",
|
|
2553
|
+
fillOpacity: "0.35"
|
|
2554
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2555
|
+
d: "M29.1874 19.5598H30.8267V18.3373H32.1587V16.7122H27.8555V18.352H29.1874V19.5598Z",
|
|
2556
|
+
fill: "white",
|
|
2557
|
+
fillOpacity: "0.35"
|
|
2558
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2559
|
+
d: "M33.2539 6.42268e-05V1.6398H37.3668V5.73182H39.0061V-0.00726318L33.2539 6.42268e-05Z",
|
|
2560
|
+
fill: "white",
|
|
2561
|
+
fillOpacity: "0.35"
|
|
2562
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2563
|
+
d: "M12.6408 1.63985H16.7391V0.00012207H11.0234V5.73188H12.6627L12.6408 1.63985Z",
|
|
2564
|
+
fill: "white",
|
|
2565
|
+
fillOpacity: "0.35"
|
|
2566
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2567
|
+
d: "M37.3678 26.3603H33.2695V28.0001H39.0071V22.261H37.3678V26.3603Z",
|
|
2568
|
+
fill: "white",
|
|
2569
|
+
fillOpacity: "0.35"
|
|
2570
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2571
|
+
d: "M12.6408 22.261H11.0234V28.0001H16.761V26.3603H12.6627L12.6408 22.261Z",
|
|
2572
|
+
fill: "white",
|
|
2573
|
+
fillOpacity: "0.35"
|
|
2574
|
+
})), /* @__PURE__ */ React.createElement("defs", null, /* @__PURE__ */ React.createElement("clipPath", { id: "clip0_2183_35009" }, /* @__PURE__ */ React.createElement("rect", {
|
|
2575
|
+
width: "28",
|
|
2576
|
+
height: "28",
|
|
2577
|
+
fill: "white",
|
|
2578
|
+
transform: "translate(11 0.00012207)"
|
|
2579
|
+
}))));
|
|
2761
2580
|
};
|
|
2762
2581
|
const BarcodeSVG = () => {
|
|
2763
|
-
return /* @__PURE__ */
|
|
2582
|
+
return /* @__PURE__ */ React.createElement("svg", {
|
|
2764
2583
|
width: "52",
|
|
2765
2584
|
height: "49",
|
|
2766
2585
|
viewBox: "0 0 52 49",
|
|
2767
2586
|
fill: "none",
|
|
2768
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2799
|
-
|
|
2800
|
-
|
|
2801
|
-
|
|
2802
|
-
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2808
|
-
|
|
2809
|
-
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
|
|
2813
|
-
|
|
2814
|
-
|
|
2815
|
-
|
|
2816
|
-
|
|
2817
|
-
|
|
2818
|
-
|
|
2819
|
-
|
|
2820
|
-
|
|
2821
|
-
|
|
2822
|
-
|
|
2823
|
-
|
|
2824
|
-
|
|
2825
|
-
|
|
2826
|
-
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
|
|
2833
|
-
|
|
2834
|
-
|
|
2835
|
-
|
|
2836
|
-
|
|
2837
|
-
|
|
2838
|
-
|
|
2839
|
-
|
|
2840
|
-
|
|
2841
|
-
|
|
2842
|
-
|
|
2843
|
-
|
|
2844
|
-
|
|
2845
|
-
|
|
2846
|
-
|
|
2847
|
-
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
|
|
2853
|
-
|
|
2854
|
-
|
|
2855
|
-
|
|
2856
|
-
|
|
2857
|
-
|
|
2858
|
-
|
|
2859
|
-
|
|
2860
|
-
|
|
2861
|
-
|
|
2862
|
-
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
|
|
2866
|
-
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
fillOpacity: "0.35"
|
|
2872
|
-
}),
|
|
2873
|
-
/* @__PURE__ */ jsx("path", {
|
|
2874
|
-
d: "M15 12.0001H14V19.0001H15V12.0001Z",
|
|
2875
|
-
fill: "white",
|
|
2876
|
-
fillOpacity: "0.35"
|
|
2877
|
-
}),
|
|
2878
|
-
/* @__PURE__ */ jsx("path", {
|
|
2879
|
-
d: "M15 0.00012207H14V7.00012H15V0.00012207Z",
|
|
2880
|
-
fill: "white",
|
|
2881
|
-
fillOpacity: "0.35"
|
|
2882
|
-
}),
|
|
2883
|
-
/* @__PURE__ */ jsx("path", {
|
|
2884
|
-
d: "M13 0.00012207H10V7.00012H13V0.00012207Z",
|
|
2885
|
-
fill: "white",
|
|
2886
|
-
fillOpacity: "0.35"
|
|
2887
|
-
}),
|
|
2888
|
-
/* @__PURE__ */ jsx("path", {
|
|
2889
|
-
d: "M13 12.0001H10V19.0001H13V12.0001Z",
|
|
2890
|
-
fill: "white",
|
|
2891
|
-
fillOpacity: "0.35"
|
|
2892
|
-
})
|
|
2893
|
-
]
|
|
2894
|
-
}),
|
|
2895
|
-
/* @__PURE__ */ jsx("defs", { children: /* @__PURE__ */ jsx("clipPath", {
|
|
2896
|
-
id: "clip0_2183_35008",
|
|
2897
|
-
children: /* @__PURE__ */ jsx("rect", {
|
|
2898
|
-
width: "40",
|
|
2899
|
-
height: "20",
|
|
2900
|
-
fill: "white",
|
|
2901
|
-
transform: "translate(7 0.00012207)"
|
|
2902
|
-
})
|
|
2903
|
-
}) })
|
|
2904
|
-
]
|
|
2905
|
-
});
|
|
2587
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
2588
|
+
}, /* @__PURE__ */ React.createElement("path", {
|
|
2589
|
+
d: "M1.42951 46.0001H4.77468C6.80309 46.0001 7.71928 44.9902 7.71928 43.6521C7.71928 42.3013 6.77326 41.5385 5.9082 41.4916V41.4064C6.70934 41.2018 7.37837 40.6564 7.37837 39.5655C7.37837 38.2743 6.48349 37.2728 4.62553 37.2728H1.42951V46.0001ZM2.74627 44.8709V42.0754H4.69371C5.75053 42.0754 6.41104 42.7572 6.41104 43.5882C6.41104 44.3211 5.91246 44.8709 4.64684 44.8709H2.74627ZM2.74627 41.0484V38.3936H4.54457C5.5886 38.3936 6.08718 38.9433 6.08718 39.6677C6.08718 40.5115 5.39684 41.0484 4.51048 41.0484H2.74627ZM11.0836 46.145C12.166 46.145 12.7754 45.5953 13.0183 45.1052H13.0694V46.0001H14.3137V41.6535C14.3137 39.7487 12.8137 39.3694 11.774 39.3694C10.5893 39.3694 9.4984 39.8467 9.07227 41.0399L10.2697 41.3126C10.4572 40.8481 10.9345 40.4007 11.791 40.4007C12.6135 40.4007 13.0353 40.8311 13.0353 41.5726V41.6024C13.0353 42.0669 12.5581 42.0584 11.3819 42.1947C10.1419 42.3396 8.87198 42.6635 8.87198 44.1507C8.87198 45.4376 9.83931 46.145 11.0836 46.145ZM11.3606 45.1223C10.6404 45.1223 10.1206 44.7984 10.1206 44.1677C10.1206 43.4859 10.7257 43.243 11.4629 43.145C11.8762 43.0896 12.8564 42.9788 13.0396 42.7956V43.6393C13.0396 44.4149 12.4217 45.1223 11.3606 45.1223ZM16.0108 46.0001H17.285V42.003C17.285 41.1464 17.9455 40.5285 18.8489 40.5285C19.1131 40.5285 19.4114 40.5754 19.5137 40.6052V39.3865C19.3858 39.3694 19.1344 39.3567 18.9725 39.3567C18.2054 39.3567 17.5492 39.7913 17.3105 40.4944H17.2424V39.4547H16.0108V46.0001ZM26.5492 46.1322C28.0961 46.1322 29.0975 45.2032 29.2381 43.9291H27.998C27.8361 44.6365 27.2864 45.0541 26.5577 45.0541C25.4796 45.0541 24.785 44.155 24.785 42.7274C24.785 41.3254 25.4924 40.4433 26.5577 40.4433C27.3674 40.4433 27.8617 40.9547 27.998 41.5683H29.2381C29.1017 40.2473 28.0236 39.3694 26.5364 39.3694C24.6912 39.3694 23.498 40.7586 23.498 42.7572C23.498 44.7302 24.6486 46.1322 26.5492 46.1322ZM33.3578 46.1322C35.2029 46.1322 36.4089 44.7814 36.4089 42.7572C36.4089 40.7203 35.2029 39.3694 33.3578 39.3694C31.5126 39.3694 30.3066 40.7203 30.3066 42.7572C30.3066 44.7814 31.5126 46.1322 33.3578 46.1322ZM33.362 45.0626C32.1561 45.0626 31.5936 44.0101 31.5936 42.753C31.5936 41.5001 32.1561 40.4348 33.362 40.4348C34.5595 40.4348 35.122 41.5001 35.122 42.753C35.122 44.0101 34.5595 45.0626 33.362 45.0626ZM40.2814 46.128C41.4746 46.128 41.9434 45.3993 42.1735 44.9817H42.28V46.0001H43.5243V37.2728H42.2502V40.5157H42.1735C41.9434 40.1109 41.5087 39.3694 40.29 39.3694C38.709 39.3694 37.5456 40.618 37.5456 42.7402C37.5456 44.8581 38.6919 46.128 40.2814 46.128ZM40.5627 45.0413C39.4249 45.0413 38.8326 44.0399 38.8326 42.7274C38.8326 41.4277 39.4121 40.4518 40.5627 40.4518C41.6749 40.4518 42.2715 41.3595 42.2715 42.7274C42.2715 44.1038 41.6621 45.0413 40.5627 45.0413ZM48.1639 46.1322C49.5914 46.1322 50.6014 45.4291 50.8912 44.3638L49.6852 44.1464C49.4551 44.7643 48.9011 45.0797 48.1767 45.0797C47.0858 45.0797 46.3528 44.3723 46.3187 43.1109H50.9721V42.6592C50.9721 40.2942 49.5574 39.3694 48.0744 39.3694C46.2505 39.3694 45.0488 40.7586 45.0488 42.77C45.0488 44.8027 46.2335 46.1322 48.1639 46.1322ZM46.323 42.1564C46.3741 41.2274 47.0474 40.422 48.0829 40.422C49.0716 40.422 49.7193 41.155 49.7235 42.1564H46.323Z",
|
|
2590
|
+
fill: "white",
|
|
2591
|
+
fillOpacity: "0.35"
|
|
2592
|
+
}), /* @__PURE__ */ React.createElement("g", { clipPath: "url(#clip0_2183_35008)" }, /* @__PURE__ */ React.createElement("path", {
|
|
2593
|
+
d: "M47 9.00012H7V10.0001H47V9.00012Z",
|
|
2594
|
+
fill: "white",
|
|
2595
|
+
fillOpacity: "0.35"
|
|
2596
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2597
|
+
d: "M43 0.00012207H42V7.00012H43V0.00012207Z",
|
|
2598
|
+
fill: "white",
|
|
2599
|
+
fillOpacity: "0.35"
|
|
2600
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2601
|
+
d: "M43 12.0001H42V19.0001H43V12.0001Z",
|
|
2602
|
+
fill: "white",
|
|
2603
|
+
fillOpacity: "0.35"
|
|
2604
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2605
|
+
d: "M41 12.0001H39V19.0001H41V12.0001Z",
|
|
2606
|
+
fill: "white",
|
|
2607
|
+
fillOpacity: "0.35"
|
|
2608
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2609
|
+
d: "M41 0.00012207H39V7.00012H41V0.00012207Z",
|
|
2610
|
+
fill: "white",
|
|
2611
|
+
fillOpacity: "0.35"
|
|
2612
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2613
|
+
d: "M38 0.00012207H35V7.00012H38V0.00012207Z",
|
|
2614
|
+
fill: "white",
|
|
2615
|
+
fillOpacity: "0.35"
|
|
2616
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2617
|
+
d: "M38 12.0001H35V19.0001H38V12.0001Z",
|
|
2618
|
+
fill: "white",
|
|
2619
|
+
fillOpacity: "0.35"
|
|
2620
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2621
|
+
d: "M33 12.0001H31V19.0001H33V12.0001Z",
|
|
2622
|
+
fill: "white",
|
|
2623
|
+
fillOpacity: "0.35"
|
|
2624
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2625
|
+
d: "M33 0.00012207H31V7.00012H33V0.00012207Z",
|
|
2626
|
+
fill: "white",
|
|
2627
|
+
fillOpacity: "0.35"
|
|
2628
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2629
|
+
d: "M30 0.00012207H28V7.00012H30V0.00012207Z",
|
|
2630
|
+
fill: "white",
|
|
2631
|
+
fillOpacity: "0.35"
|
|
2632
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2633
|
+
d: "M30 12.0001H28V19.0001H30V12.0001Z",
|
|
2634
|
+
fill: "white",
|
|
2635
|
+
fillOpacity: "0.35"
|
|
2636
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2637
|
+
d: "M27 0.00012207H26V7.00012H27V0.00012207Z",
|
|
2638
|
+
fill: "white",
|
|
2639
|
+
fillOpacity: "0.35"
|
|
2640
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2641
|
+
d: "M27 12.0001H26V19.0001H27V12.0001Z",
|
|
2642
|
+
fill: "white",
|
|
2643
|
+
fillOpacity: "0.35"
|
|
2644
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2645
|
+
d: "M25 0.00012207H24V7.00012H25V0.00012207Z",
|
|
2646
|
+
fill: "white",
|
|
2647
|
+
fillOpacity: "0.35"
|
|
2648
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2649
|
+
d: "M25 12.0001H24V19.0001H25V12.0001Z",
|
|
2650
|
+
fill: "white",
|
|
2651
|
+
fillOpacity: "0.35"
|
|
2652
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2653
|
+
d: "M23 0.00012207H20V7.00012H23V0.00012207Z",
|
|
2654
|
+
fill: "white",
|
|
2655
|
+
fillOpacity: "0.35"
|
|
2656
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2657
|
+
d: "M23 12.0001H20V19.0001H23V12.0001Z",
|
|
2658
|
+
fill: "white",
|
|
2659
|
+
fillOpacity: "0.35"
|
|
2660
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2661
|
+
d: "M18 0.00012207H16V7.00012H18V0.00012207Z",
|
|
2662
|
+
fill: "white",
|
|
2663
|
+
fillOpacity: "0.35"
|
|
2664
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2665
|
+
d: "M18 12.0001H16V19.0001H18V12.0001Z",
|
|
2666
|
+
fill: "white",
|
|
2667
|
+
fillOpacity: "0.35"
|
|
2668
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2669
|
+
d: "M15 12.0001H14V19.0001H15V12.0001Z",
|
|
2670
|
+
fill: "white",
|
|
2671
|
+
fillOpacity: "0.35"
|
|
2672
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2673
|
+
d: "M15 0.00012207H14V7.00012H15V0.00012207Z",
|
|
2674
|
+
fill: "white",
|
|
2675
|
+
fillOpacity: "0.35"
|
|
2676
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2677
|
+
d: "M13 0.00012207H10V7.00012H13V0.00012207Z",
|
|
2678
|
+
fill: "white",
|
|
2679
|
+
fillOpacity: "0.35"
|
|
2680
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2681
|
+
d: "M13 12.0001H10V19.0001H13V12.0001Z",
|
|
2682
|
+
fill: "white",
|
|
2683
|
+
fillOpacity: "0.35"
|
|
2684
|
+
})), /* @__PURE__ */ React.createElement("defs", null, /* @__PURE__ */ React.createElement("clipPath", { id: "clip0_2183_35008" }, /* @__PURE__ */ React.createElement("rect", {
|
|
2685
|
+
width: "40",
|
|
2686
|
+
height: "20",
|
|
2687
|
+
fill: "white",
|
|
2688
|
+
transform: "translate(7 0.00012207)"
|
|
2689
|
+
}))));
|
|
2906
2690
|
};
|
|
2907
2691
|
const RFIDCardSVG = () => {
|
|
2908
|
-
return /* @__PURE__ */
|
|
2692
|
+
return /* @__PURE__ */ React.createElement("svg", {
|
|
2909
2693
|
width: "58",
|
|
2910
2694
|
height: "49",
|
|
2911
2695
|
viewBox: "0 0 58 49",
|
|
2912
2696
|
fill: "none",
|
|
2913
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
2914
|
-
|
|
2915
|
-
|
|
2916
|
-
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
|
|
2920
|
-
|
|
2921
|
-
|
|
2922
|
-
|
|
2923
|
-
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
|
|
2927
|
-
|
|
2928
|
-
/* @__PURE__ */ jsx("defs", { children: /* @__PURE__ */ jsx("clipPath", {
|
|
2929
|
-
id: "clip0_2183_35036",
|
|
2930
|
-
children: /* @__PURE__ */ jsx("rect", {
|
|
2931
|
-
width: "26",
|
|
2932
|
-
height: "20",
|
|
2933
|
-
fill: "white",
|
|
2934
|
-
transform: "translate(16 0.00012207)"
|
|
2935
|
-
})
|
|
2936
|
-
}) })
|
|
2937
|
-
]
|
|
2938
|
-
});
|
|
2697
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
2698
|
+
}, /* @__PURE__ */ React.createElement("path", {
|
|
2699
|
+
d: "M1.27131 46.0001H2.58807V42.6976H4.37784C4.40767 42.6976 4.43324 42.6976 4.46307 42.6976L6.2358 46.0001H7.7358L5.80114 42.4675C6.87074 42.0711 7.40341 41.1805 7.40341 40.0086C7.40341 38.4021 6.40625 37.2728 4.3821 37.2728H1.27131V46.0001ZM2.58807 41.564V38.4021H4.24148C5.54119 38.4021 6.07812 39.02 6.07812 40.0086C6.07812 40.993 5.54119 41.564 4.25852 41.564H2.58807ZM10.3224 37.2728H9.00568V46.0001H10.3224V37.2728ZM12.2401 46.0001H13.5568V42.1947H17.2642V41.0655H13.5568V38.4064H17.652V37.2728H12.2401V46.0001ZM22.0966 46.0001C24.7557 46.0001 26.294 44.351 26.294 41.6237C26.294 38.9092 24.7557 37.2728 22.1861 37.2728H19.2713V46.0001H22.0966ZM20.5881 44.8496V38.4234H22.1051C24.0142 38.4234 24.9986 39.5655 24.9986 41.6237C24.9986 43.6905 24.0142 44.8496 22.0241 44.8496H20.5881ZM38.3558 40.1109C38.0575 38.2444 36.5959 37.1535 34.7507 37.1535C32.4922 37.1535 30.826 38.8453 30.826 41.6365C30.826 44.4277 32.4837 46.1194 34.7507 46.1194C36.6683 46.1194 38.0703 44.9177 38.3558 43.1919L37.0263 43.1876C36.8004 44.3041 35.8629 44.9177 34.7592 44.9177C33.2635 44.9177 32.1342 43.7714 32.1342 41.6365C32.1342 39.5186 33.2592 38.3552 34.7635 38.3552C35.8757 38.3552 36.8089 38.9817 37.0263 40.1109H38.3558ZM41.734 46.145C42.8164 46.145 43.4258 45.5953 43.6687 45.1052H43.7198V46.0001H44.9641V41.6535C44.9641 39.7487 43.4641 39.3694 42.4244 39.3694C41.2397 39.3694 40.1488 39.8467 39.7227 41.0399L40.9201 41.3126C41.1076 40.8481 41.5849 40.4007 42.4414 40.4007C43.2638 40.4007 43.6857 40.8311 43.6857 41.5726V41.6024C43.6857 42.0669 43.2085 42.0584 42.0323 42.1947C40.7923 42.3396 39.5224 42.6635 39.5224 44.1507C39.5224 45.4376 40.4897 46.145 41.734 46.145ZM42.011 45.1223C41.2908 45.1223 40.771 44.7984 40.771 44.1677C40.771 43.4859 41.3761 43.243 42.1133 43.145C42.5266 43.0896 43.5067 42.9788 43.69 42.7956V43.6393C43.69 44.4149 43.0721 45.1223 42.011 45.1223ZM46.6612 46.0001H47.9354V42.003C47.9354 41.1464 48.5959 40.5285 49.4993 40.5285C49.7635 40.5285 50.0618 40.5754 50.1641 40.6052V39.3865C50.0362 39.3694 49.7848 39.3567 49.6229 39.3567C48.8558 39.3567 48.1996 39.7913 47.9609 40.4944H47.8928V39.4547H46.6612V46.0001ZM53.4826 46.128C54.6758 46.128 55.1445 45.3993 55.3746 44.9817H55.4812V46.0001H56.7255V37.2728H55.4513V40.5157H55.3746C55.1445 40.1109 54.7099 39.3694 53.4911 39.3694C51.9102 39.3694 50.7468 40.618 50.7468 42.7402C50.7468 44.8581 51.8931 46.128 53.4826 46.128ZM53.7638 45.0413C52.6261 45.0413 52.0337 44.0399 52.0337 42.7274C52.0337 41.4277 52.6133 40.4518 53.7638 40.4518C54.8761 40.4518 55.4727 41.3595 55.4727 42.7274C55.4727 44.1038 54.8633 45.0413 53.7638 45.0413Z",
|
|
2700
|
+
fill: "white",
|
|
2701
|
+
fillOpacity: "0.35"
|
|
2702
|
+
}), /* @__PURE__ */ React.createElement("g", { clipPath: "url(#clip0_2183_35036)" }, /* @__PURE__ */ React.createElement("path", {
|
|
2703
|
+
d: "M19.5998 19.9927H38.3927C40.7673 19.9927 41.9924 18.8037 41.9924 16.5215V3.47133C41.9924 1.1892 40.7673 0.00012207 38.3927 0.00012207H19.5998C17.2251 0.00012207 16 1.17443 16 3.47133V16.5215C16 18.8037 17.2251 19.9927 19.5998 19.9927ZM19.7283 17.8953C19.5129 17.9222 19.294 17.9003 19.0886 17.8313C18.8832 17.7623 18.6969 17.648 18.544 17.4973C18.3911 17.3466 18.2759 17.1635 18.2072 16.9623C18.1385 16.761 18.1181 16.547 18.1478 16.3369V3.64857C18.1197 3.43872 18.1411 3.22539 18.2104 3.02486C18.2796 2.82432 18.3949 2.6419 18.5474 2.49154C18.6999 2.34118 18.8856 2.22684 19.0903 2.15729C19.295 2.08774 19.5132 2.06481 19.7283 2.09024H38.2641C38.4792 2.06481 38.6975 2.08774 38.9022 2.15729C39.1068 2.22684 39.2925 2.34118 39.445 2.49154C39.5975 2.6419 39.7128 2.82432 39.7821 3.02486C39.8513 3.22539 39.8728 3.43872 39.8447 3.64857V16.3369C39.8728 16.5468 39.8513 16.7601 39.7821 16.9606C39.7128 17.1612 39.5975 17.3436 39.445 17.494C39.2925 17.6443 39.1068 17.7586 38.9022 17.8282C38.6975 17.8977 38.4792 17.9207 38.2641 17.8953H19.7283ZM24.5759 9.93366C24.9027 9.92527 25.2245 9.85291 25.5221 9.72085C25.8197 9.58879 26.0872 9.39974 26.3086 9.16488C26.5301 8.93003 26.701 8.65415 26.8112 8.3536C26.9215 8.05305 26.9689 7.73395 26.9505 7.41519C26.9123 6.96482 26.7407 6.53505 26.4565 6.1784C26.1723 5.82175 25.7879 5.55367 25.3502 5.40689C24.9125 5.26012 24.4405 5.24101 23.9919 5.3519C23.5433 5.46279 23.1375 5.69889 22.8241 6.03133C22.5106 6.36378 22.3031 6.77819 22.2269 7.22393C22.1506 7.66967 22.2089 8.12746 22.3947 8.54135C22.5805 8.95524 22.8858 9.3073 23.2731 9.55456C23.6605 9.80182 24.1132 9.93355 24.5759 9.93366ZM31.6091 6.54371H37.3112C37.4038 6.54577 37.4958 6.52936 37.5817 6.49548C37.6676 6.46159 37.7455 6.41095 37.8106 6.34665C37.8757 6.28235 37.9268 6.20575 37.9605 6.12153C37.9943 6.03731 38.0101 5.94725 38.007 5.85686C38.008 5.76802 37.9907 5.67989 37.9559 5.5978C37.9211 5.51571 37.8697 5.44134 37.8047 5.37922C37.7396 5.31709 37.6624 5.2685 37.5776 5.23634C37.4927 5.20419 37.4021 5.18914 37.3112 5.19214H31.6469C31.556 5.18914 31.4654 5.20419 31.3806 5.23634C31.2958 5.2685 31.2185 5.31709 31.1535 5.37922C31.0885 5.44134 31.037 5.51571 31.0022 5.5978C30.9674 5.67989 30.9501 5.76802 30.9511 5.85686C30.948 5.94725 30.9638 6.03731 30.9976 6.12153C31.0313 6.20575 31.0824 6.28235 31.1475 6.34665C31.2126 6.41095 31.2905 6.46159 31.3764 6.49548C31.4623 6.52936 31.5543 6.54577 31.6469 6.54371H31.6091ZM31.6091 10.6796H37.3112C37.4957 10.6796 37.6727 10.608 37.8032 10.4806C37.9337 10.3532 38.007 10.1803 38.007 10.0001C38.007 9.81992 37.9337 9.64709 37.8032 9.51967C37.6727 9.39224 37.4957 9.32065 37.3112 9.32065H31.6469C31.4624 9.32065 31.2854 9.39224 31.1549 9.51967C31.0245 9.64709 30.9511 9.81992 30.9511 10.0001C30.9511 10.1803 31.0245 10.3532 31.1549 10.4806C31.2854 10.608 31.4624 10.6796 31.6469 10.6796H31.6091ZM20.4392 14.8081H28.7126C28.796 14.8129 28.8794 14.7998 28.9571 14.7699C29.0347 14.74 29.1048 14.6939 29.1624 14.6349C29.22 14.5758 29.2637 14.5052 29.2905 14.428C29.3173 14.3508 29.3265 14.2688 29.3176 14.1877C29.3176 13.1907 27.8051 10.6501 24.5759 10.6501C21.3467 10.6501 19.8494 13.1907 19.8494 14.1877C19.8394 14.2678 19.8473 14.3489 19.8728 14.4256C19.8983 14.5023 19.9406 14.5726 19.9967 14.6317C20.0529 14.6908 20.1216 14.7372 20.198 14.7677C20.2745 14.7981 20.3567 14.8119 20.4392 14.8081ZM31.6091 14.8081H37.3112C37.4021 14.8111 37.4927 14.7961 37.5776 14.7639C37.6624 14.7318 37.7396 14.6832 37.8047 14.621C37.8697 14.5589 37.9211 14.4846 37.9559 14.4025C37.9907 14.3204 38.008 14.2322 38.007 14.1434C38.009 14.0529 37.9925 13.963 37.9584 13.8789C37.9243 13.7947 37.8734 13.718 37.8086 13.6534C37.7438 13.5887 37.6664 13.5373 37.581 13.5023C37.4956 13.4672 37.4039 13.4492 37.3112 13.4492H31.6469C31.5542 13.4492 31.4625 13.4672 31.3771 13.5023C31.2917 13.5373 31.2143 13.5887 31.1495 13.6534C31.0847 13.718 31.0338 13.7947 30.9997 13.8789C30.9656 13.963 30.9491 14.0529 30.9511 14.1434C30.9501 14.2322 30.9674 14.3204 31.0022 14.4025C31.037 14.4846 31.0885 14.5589 31.1535 14.621C31.2185 14.6832 31.2958 14.7318 31.3806 14.7639C31.4654 14.7961 31.556 14.8111 31.6469 14.8081H31.6091Z",
|
|
2704
|
+
fill: "white",
|
|
2705
|
+
fillOpacity: "0.35"
|
|
2706
|
+
})), /* @__PURE__ */ React.createElement("defs", null, /* @__PURE__ */ React.createElement("clipPath", { id: "clip0_2183_35036" }, /* @__PURE__ */ React.createElement("rect", {
|
|
2707
|
+
width: "26",
|
|
2708
|
+
height: "20",
|
|
2709
|
+
fill: "white",
|
|
2710
|
+
transform: "translate(16 0.00012207)"
|
|
2711
|
+
}))));
|
|
2939
2712
|
};
|
|
2940
2713
|
const AcLogoSVG = () => {
|
|
2941
|
-
return /* @__PURE__ */
|
|
2714
|
+
return /* @__PURE__ */ React.createElement("svg", {
|
|
2942
2715
|
width: "98",
|
|
2943
2716
|
height: "50",
|
|
2944
2717
|
viewBox: "0 0 98 50",
|
|
2945
2718
|
fill: "none",
|
|
2946
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
2947
|
-
|
|
2948
|
-
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2959
|
-
|
|
2960
|
-
|
|
2961
|
-
|
|
2962
|
-
|
|
2963
|
-
|
|
2964
|
-
|
|
2965
|
-
|
|
2966
|
-
|
|
2967
|
-
|
|
2968
|
-
|
|
2969
|
-
|
|
2970
|
-
|
|
2971
|
-
|
|
2972
|
-
|
|
2973
|
-
|
|
2974
|
-
|
|
2975
|
-
|
|
2976
|
-
|
|
2977
|
-
|
|
2978
|
-
/* @__PURE__ */ jsx("path", {
|
|
2979
|
-
d: "M70.4451 49.0776C68.2325 49.0776 66.3992 47.2963 66.3359 45.0061V31.6463H68.8647V45.0061C68.8647 45.3878 68.9911 45.7695 69.3072 46.0876C69.5601 46.342 69.9394 46.5329 70.3819 46.5329C71.2037 46.5329 71.8359 45.8967 71.8359 45.0697V31.7099H74.5543V45.0697C74.5543 46.1512 74.1118 47.2327 73.3531 47.9961C72.5945 48.6959 71.583 49.1412 70.4451 49.0776Z",
|
|
2980
|
-
fill: "white"
|
|
2981
|
-
}),
|
|
2982
|
-
/* @__PURE__ */ jsx("path", {
|
|
2983
|
-
d: "M97.0021 44.7516C97.0021 45.8331 96.5595 46.9146 95.8009 47.678C95.0423 48.4414 94.0308 48.8867 92.9561 48.8867H88.9102V31.6463H92.9561C94.0308 31.6463 95.1055 32.0916 95.8009 32.855C96.5595 33.6185 97.0021 34.7 97.0021 35.7815V44.7516ZM91.5021 46.342H93.0826C93.4619 46.342 93.8412 46.2148 94.094 45.8967C94.3469 45.6422 94.5366 45.2605 94.5366 44.8152V35.7815C94.5366 35.3998 94.4101 35.018 94.094 34.7C93.8412 34.4455 93.4619 34.2546 93.0826 34.2546H91.5021V46.342Z",
|
|
2984
|
-
fill: "white"
|
|
2985
|
-
}),
|
|
2986
|
-
/* @__PURE__ */ jsx("path", {
|
|
2987
|
-
d: "M87.2555 1.49487L92.7555 20.0713V1.49487H96.9279V29.1686H92.5027L86.813 11.4193V29.1686H82.6406V1.49487H87.2555Z",
|
|
2988
|
-
fill: "white"
|
|
2989
|
-
})
|
|
2990
|
-
]
|
|
2991
|
-
})
|
|
2992
|
-
});
|
|
2719
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
2720
|
+
}, /* @__PURE__ */ React.createElement("g", { opacity: "0.25" }, /* @__PURE__ */ React.createElement("path", {
|
|
2721
|
+
d: "M66.8428 0.85791C66.2106 2.00303 65.7681 3.21177 65.3888 4.48413C64.883 4.54775 64.4405 4.61136 63.998 4.67498C63.5555 4.80222 63.0497 4.92945 62.6072 5.05669C61.8486 4.0388 61.0267 3.08453 60.0784 2.19388C59.4463 2.51197 58.8141 2.83006 58.1819 3.27539C58.3716 4.54774 58.6876 5.8201 59.1302 7.09246C58.7509 7.41055 58.4348 7.72864 58.1187 8.11034C57.8026 8.49205 57.4865 8.81014 57.2336 9.25547C56.0325 8.87376 54.7681 8.55567 53.5038 8.42843C53.1245 9.06461 52.8716 9.76441 52.6187 10.4006C53.5038 11.3549 54.5153 12.1819 55.59 12.8817C55.3371 13.8359 55.2107 14.7902 55.2739 15.7445C54.0727 16.1262 52.8716 16.6351 51.7969 17.2713C51.8601 17.9711 51.9865 18.7345 52.2394 19.4343C53.5038 19.6888 54.8313 19.7524 56.0957 19.6888C56.2854 20.1341 56.475 20.5794 56.7279 20.9611C56.9808 21.4065 57.2336 21.7882 57.4865 22.1699C56.7279 23.1878 56.0957 24.3329 55.5267 25.478C56.0325 25.987 56.5382 26.4959 57.1072 26.9412C58.2451 26.3687 59.383 25.6689 60.3945 24.8418C60.7738 25.0963 61.2164 25.3508 61.6589 25.5416C62.1014 25.7325 62.544 25.9233 62.9865 26.0506C62.9865 27.3229 63.1129 28.5953 63.3658 29.8676C64.0612 29.9949 64.8198 30.1221 65.5152 30.1221C66.1474 28.977 66.5899 27.7683 66.9692 26.4959C67.475 26.4323 67.9175 26.3687 68.36 26.305C68.8026 26.1778 69.3083 26.0506 69.7508 25.9233C70.5094 26.9412 71.3313 27.8955 72.2796 28.7861C72.9117 28.4681 73.5439 28.15 74.1761 27.7046C73.9864 26.4323 73.6704 25.1599 73.2278 23.8876C73.6071 23.5695 73.9232 23.2514 74.2393 22.8697C74.5554 22.488 74.8715 22.1699 75.1244 21.7246C76.3255 22.1063 77.5899 22.4244 78.8543 22.5516C79.2336 21.9154 79.4864 21.2156 79.7393 20.5794C78.8542 19.6252 77.8428 18.7981 76.7681 18.0983C77.0209 17.1441 77.1474 16.1898 77.0841 15.2355C78.2853 14.8538 79.4864 14.3449 80.5611 13.7087C80.4979 13.0089 80.3715 12.2455 80.1186 11.5457C78.8543 11.2912 77.5267 11.2276 76.2623 11.2912C76.0727 10.8459 75.883 10.4006 75.6301 10.0189C75.3773 9.57355 75.1244 9.19185 74.8715 8.81014C75.6301 7.79225 76.2623 6.64713 76.8313 5.50201C76.3255 4.99307 75.8198 4.48413 75.2508 4.0388C74.1129 4.61136 72.975 5.31116 71.9635 6.13819C71.5842 5.88372 71.1416 5.62925 70.6991 5.4384C70.2566 5.24754 69.8141 5.05669 69.3715 4.92945C69.3715 3.6571 69.2451 2.38474 68.9922 1.11238C68.2336 0.985147 67.5382 0.85791 66.8428 0.85791ZM68.929 9.25547C72.3428 10.8459 73.7968 14.8538 72.2796 18.2256C71.3945 20.1977 69.6244 21.5973 67.5382 22.0427C66.1474 22.2971 64.6934 22.1699 63.429 21.5973C60.0152 20.0069 58.5612 15.999 60.0784 12.6272C60.9635 10.6551 62.7336 9.25546 64.8198 8.81014C66.2106 8.49205 67.6646 8.6829 68.929 9.25547Z",
|
|
2722
|
+
fill: "white"
|
|
2723
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2724
|
+
d: "M6.03298 22.8689L5.02149 29.2307H0.722656L5.4008 1.55695H11.0904L15.7054 29.2307H11.3433L10.395 22.8689H6.03298ZM8.1824 7.85511L6.66517 18.7974H9.76286L8.1824 7.85511Z",
|
|
2725
|
+
fill: "white"
|
|
2726
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2727
|
+
d: "M23.861 1.49487L29.361 20.0713V1.49487H33.5334V29.1686H29.1081L23.4185 11.4193V29.1686H19.2461V1.49487H23.861Z",
|
|
2728
|
+
fill: "white"
|
|
2729
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2730
|
+
d: "M50.2261 22.5524C50.2261 24.3337 49.5307 25.9878 48.3295 27.1965C47.1284 28.4688 45.4847 29.1686 43.7146 29.1686H37.2031V1.49487H43.7146C45.4847 1.49487 47.1284 2.19467 48.3295 3.46703C49.5939 4.67577 50.2261 6.39345 50.2261 8.11113V22.5524ZM41.3123 25.0971H43.7778C44.41 25.0971 45.0422 24.8426 45.4215 24.3973C45.864 23.952 46.1169 23.3158 46.1169 22.6796V8.17475C46.1169 7.53857 45.864 6.90239 45.4215 6.45707C44.979 6.01174 44.41 5.75727 43.7778 5.75727H41.3123V25.0971Z",
|
|
2731
|
+
fill: "white"
|
|
2732
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2733
|
+
d: "M4.83183 49.0815C2.55598 49.0815 0.722656 47.2366 0.722656 45.01C0.722656 45.01 0.722656 45.01 0.722656 44.9464V35.5309C0.722656 33.2407 2.49276 31.3958 4.76862 31.3322C7.04447 31.2685 8.8778 33.1135 8.94101 35.4037C8.94101 35.4673 8.94101 35.4673 8.94101 35.5309V37.5031H6.28585V35.4673C6.28585 34.6403 5.59045 33.9405 4.76862 33.9405C4.38931 33.9405 4.01 34.0677 3.69391 34.3858C3.44104 34.6403 3.25138 35.022 3.25138 35.4673V44.9464C3.25138 45.7734 3.88356 46.4096 4.7054 46.4096C5.08471 46.4096 5.46402 46.2824 5.78011 45.9643C6.0962 45.7098 6.22263 45.3281 6.22263 44.8828V42.5289H8.94101V44.9464C8.94101 47.2366 7.10769 49.0815 4.83183 49.0815Z",
|
|
2734
|
+
fill: "white"
|
|
2735
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2736
|
+
d: "M30.1227 48.8867H23.1055V31.6463H25.6974V46.342H30.1859L30.1227 48.8867Z",
|
|
2737
|
+
fill: "white"
|
|
2738
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2739
|
+
d: "M48.0115 31.4559C50.2874 31.4559 52.1207 33.3009 52.1207 35.5911V45.0065C52.1207 47.2968 50.2874 49.1417 48.0115 49.1417C46.9368 49.1417 45.8621 48.6964 45.1035 47.933C44.3449 47.1696 43.9023 46.088 43.9023 45.0065V35.5911C43.9023 33.3009 45.7357 31.4559 48.0115 31.4559ZM49.4023 35.5275C49.4023 34.7004 48.7701 34.0643 47.9483 34.0643C47.569 34.0643 47.1897 34.1915 46.8736 34.5096C46.5575 34.7641 46.4311 35.1458 46.4311 35.5911V45.0065C46.4311 45.3883 46.5575 45.77 46.8736 46.0244C47.1265 46.2789 47.5058 46.4698 47.9483 46.4698C48.7701 46.4698 49.4023 45.8336 49.4023 45.0065V35.5275Z",
|
|
2740
|
+
fill: "white"
|
|
2741
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2742
|
+
d: "M70.4451 49.0776C68.2325 49.0776 66.3992 47.2963 66.3359 45.0061V31.6463H68.8647V45.0061C68.8647 45.3878 68.9911 45.7695 69.3072 46.0876C69.5601 46.342 69.9394 46.5329 70.3819 46.5329C71.2037 46.5329 71.8359 45.8967 71.8359 45.0697V31.7099H74.5543V45.0697C74.5543 46.1512 74.1118 47.2327 73.3531 47.9961C72.5945 48.6959 71.583 49.1412 70.4451 49.0776Z",
|
|
2743
|
+
fill: "white"
|
|
2744
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2745
|
+
d: "M97.0021 44.7516C97.0021 45.8331 96.5595 46.9146 95.8009 47.678C95.0423 48.4414 94.0308 48.8867 92.9561 48.8867H88.9102V31.6463H92.9561C94.0308 31.6463 95.1055 32.0916 95.8009 32.855C96.5595 33.6185 97.0021 34.7 97.0021 35.7815V44.7516ZM91.5021 46.342H93.0826C93.4619 46.342 93.8412 46.2148 94.094 45.8967C94.3469 45.6422 94.5366 45.2605 94.5366 44.8152V35.7815C94.5366 35.3998 94.4101 35.018 94.094 34.7C93.8412 34.4455 93.4619 34.2546 93.0826 34.2546H91.5021V46.342Z",
|
|
2746
|
+
fill: "white"
|
|
2747
|
+
}), /* @__PURE__ */ React.createElement("path", {
|
|
2748
|
+
d: "M87.2555 1.49487L92.7555 20.0713V1.49487H96.9279V29.1686H92.5027L86.813 11.4193V29.1686H82.6406V1.49487H87.2555Z",
|
|
2749
|
+
fill: "white"
|
|
2750
|
+
})));
|
|
2993
2751
|
};
|
|
2994
2752
|
//#endregion
|
|
2995
2753
|
//#region src/components/loginModal.tsx
|
|
@@ -2998,23 +2756,22 @@ const LoginModal$1 = ({ open, subtitle, scope, redirectPath = "/", onSuccess, on
|
|
|
2998
2756
|
const getTitle = () => {
|
|
2999
2757
|
return subtitle !== void 0 ? subtitle : t("loginFormText");
|
|
3000
2758
|
};
|
|
3001
|
-
return /* @__PURE__ */
|
|
2759
|
+
return /* @__PURE__ */ React.createElement(Dialog$1, {
|
|
3002
2760
|
open,
|
|
3003
2761
|
onClose: onCancel,
|
|
3004
2762
|
disableEscapeKeyDown: true,
|
|
3005
2763
|
sx: { ".MuiPaper-root": { borderRadius: "20px" } },
|
|
3006
|
-
"data-testid": dataTestID || "sdk.login-modal"
|
|
3007
|
-
|
|
3008
|
-
|
|
3009
|
-
|
|
3010
|
-
|
|
3011
|
-
|
|
3012
|
-
|
|
3013
|
-
|
|
3014
|
-
|
|
3015
|
-
|
|
3016
|
-
|
|
3017
|
-
});
|
|
2764
|
+
"data-testid": dataTestID || "sdk.login-modal"
|
|
2765
|
+
}, /* @__PURE__ */ React.createElement(DialogContent$1, null, /* @__PURE__ */ React.createElement(loginForm_default, {
|
|
2766
|
+
title: getTitle(),
|
|
2767
|
+
scope,
|
|
2768
|
+
redirectPath,
|
|
2769
|
+
onSuccess,
|
|
2770
|
+
onFailure,
|
|
2771
|
+
onCancel,
|
|
2772
|
+
storeSession,
|
|
2773
|
+
"data-testid": dataTestID || "sdk.login-form"
|
|
2774
|
+
})));
|
|
3018
2775
|
};
|
|
3019
2776
|
var loginModal_default = observer(LoginModal$1);
|
|
3020
2777
|
//#endregion
|
|
@@ -3032,7 +2789,7 @@ const LoginModal = ({ isOpen, title, subtitle, scope, redirectPath, onSuccess, o
|
|
|
3032
2789
|
if (onCancel && typeof onCancel === "function") onCancel();
|
|
3033
2790
|
setOpen(false);
|
|
3034
2791
|
};
|
|
3035
|
-
return /* @__PURE__ */
|
|
2792
|
+
return /* @__PURE__ */ React.createElement(loginModal_default, {
|
|
3036
2793
|
open,
|
|
3037
2794
|
title,
|
|
3038
2795
|
subtitle,
|
|
@@ -3077,7 +2834,7 @@ const ExternalContent = ({ src }) => {
|
|
|
3077
2834
|
setIframeMounted(true);
|
|
3078
2835
|
return () => setIframeMounted(false);
|
|
3079
2836
|
}, [setIframeMounted]);
|
|
3080
|
-
return /* @__PURE__ */
|
|
2837
|
+
return /* @__PURE__ */ React.createElement(Iframe, {
|
|
3081
2838
|
id: "external-content-iframe",
|
|
3082
2839
|
src,
|
|
3083
2840
|
width: "100%",
|
|
@@ -3220,7 +2977,7 @@ const Header = observer(({ position, scrolled, showAcLogo, leadingText, title, t
|
|
|
3220
2977
|
setCurrentTime(/* @__PURE__ */ new Date());
|
|
3221
2978
|
}, 1e3);
|
|
3222
2979
|
return () => clearInterval(interval);
|
|
3223
|
-
}
|
|
2980
|
+
});
|
|
3224
2981
|
useEffect(() => {
|
|
3225
2982
|
setHeaderLeadingText(leadingText);
|
|
3226
2983
|
}, [leadingText]);
|
|
@@ -3303,8 +3060,9 @@ const Header = observer(({ position, scrolled, showAcLogo, leadingText, title, t
|
|
|
3303
3060
|
handleMenuClose();
|
|
3304
3061
|
};
|
|
3305
3062
|
const renderUserCompanyLogo = () => {
|
|
3306
|
-
|
|
3307
|
-
|
|
3063
|
+
const logoUrl = companyLogoUrl();
|
|
3064
|
+
return /* @__PURE__ */ React.createElement("img", {
|
|
3065
|
+
src: logoUrl,
|
|
3308
3066
|
alt: ""
|
|
3309
3067
|
});
|
|
3310
3068
|
};
|
|
@@ -3319,91 +3077,68 @@ const Header = observer(({ position, scrolled, showAcLogo, leadingText, title, t
|
|
|
3319
3077
|
};
|
|
3320
3078
|
const renderUserAvatar = () => {
|
|
3321
3079
|
const currentUser = userStore_default.currentUser;
|
|
3322
|
-
return /* @__PURE__ */
|
|
3080
|
+
return /* @__PURE__ */ React.createElement(Box$2, {
|
|
3323
3081
|
display: "inline-block",
|
|
3324
|
-
sx: headerStyles.userInfo
|
|
3325
|
-
|
|
3326
|
-
});
|
|
3082
|
+
sx: headerStyles.userInfo
|
|
3083
|
+
}, currentUser && `(${currentUser.name})`);
|
|
3327
3084
|
};
|
|
3328
3085
|
const renderContent = () => {
|
|
3329
3086
|
if (iframeContent && contentComponents) {
|
|
3330
3087
|
const Component = contentComponents[iframeContent.component];
|
|
3331
|
-
if (Component) return /* @__PURE__ */
|
|
3332
|
-
|
|
3333
|
-
|
|
3334
|
-
|
|
3335
|
-
onContentEvent
|
|
3336
|
-
})
|
|
3337
|
-
});
|
|
3088
|
+
if (Component) return /* @__PURE__ */ React.createElement(Box$2, { sx: headerStyles.content }, /* @__PURE__ */ React.createElement(Component, {
|
|
3089
|
+
...iframeContent.props,
|
|
3090
|
+
onContentEvent
|
|
3091
|
+
}));
|
|
3338
3092
|
}
|
|
3339
|
-
if (content) return /* @__PURE__ */
|
|
3340
|
-
|
|
3341
|
-
children: content
|
|
3342
|
-
});
|
|
3343
|
-
return /* @__PURE__ */ jsx(Typography$1, {
|
|
3093
|
+
if (content) return /* @__PURE__ */ React.createElement(Box$2, { sx: headerStyles.content }, content);
|
|
3094
|
+
return /* @__PURE__ */ React.createElement(Typography$1, {
|
|
3344
3095
|
variant: "subtitle1",
|
|
3345
3096
|
align: "center",
|
|
3346
|
-
sx: headerStyles.title
|
|
3347
|
-
|
|
3348
|
-
});
|
|
3097
|
+
sx: headerStyles.title
|
|
3098
|
+
}, headerTitle);
|
|
3349
3099
|
};
|
|
3350
3100
|
const renderNav = () => {
|
|
3351
|
-
return navItems && /* @__PURE__ */
|
|
3101
|
+
return navItems && /* @__PURE__ */ React.createElement(Box$2, {
|
|
3352
3102
|
display: "flex",
|
|
3353
|
-
sx: headerStyles.nav
|
|
3354
|
-
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
|
|
3358
|
-
|
|
3359
|
-
|
|
3360
|
-
});
|
|
3103
|
+
sx: headerStyles.nav
|
|
3104
|
+
}, navItems.map((item) => /* @__PURE__ */ React.createElement(Button$1, {
|
|
3105
|
+
key: item.label,
|
|
3106
|
+
onClick: () => handleItemClick(item),
|
|
3107
|
+
endIcon: item.icon,
|
|
3108
|
+
sx: headerStyles.button
|
|
3109
|
+
}, item.label)));
|
|
3361
3110
|
};
|
|
3362
3111
|
const renderUser = () => {
|
|
3363
3112
|
const currentUser = userStore_default.getCurrentUserJS;
|
|
3364
|
-
return /* @__PURE__ */
|
|
3113
|
+
return /* @__PURE__ */ React.createElement(Box$2, {
|
|
3365
3114
|
display: "flex",
|
|
3366
|
-
sx: headerStyles.user
|
|
3367
|
-
|
|
3368
|
-
|
|
3369
|
-
onClick: handleLogout,
|
|
3370
|
-
sx: {
|
|
3371
|
-
...headerStyles.button,
|
|
3372
|
-
...headerStyles.logoutButton
|
|
3373
|
-
},
|
|
3374
|
-
"data-testid": "sdk.header-logout-button",
|
|
3375
|
-
children: [
|
|
3376
|
-
t("headerLogoutButton"),
|
|
3377
|
-
showCompanyLogo && renderUserCompanyLogo(),
|
|
3378
|
-
renderUserAvatar()
|
|
3379
|
-
]
|
|
3380
|
-
}) : /* @__PURE__ */ jsx(Button$1, {
|
|
3381
|
-
id: "login-button",
|
|
3382
|
-
onClick: () => navigate("/login"),
|
|
3383
|
-
sx: {
|
|
3384
|
-
...headerStyles.button,
|
|
3385
|
-
...headerStyles.loginButton
|
|
3386
|
-
},
|
|
3387
|
-
"data-testid": "sdk.header-login-button",
|
|
3388
|
-
children: t("headerLoginButton")
|
|
3389
|
-
})
|
|
3390
|
-
});
|
|
3391
|
-
};
|
|
3392
|
-
const renderAuthMenuItem = () => {
|
|
3393
|
-
if (!matchesMD) return userStore_default.getCurrentUserJS ? /* @__PURE__ */ jsx(MenuItem, {
|
|
3115
|
+
sx: headerStyles.user
|
|
3116
|
+
}, currentUser ? /* @__PURE__ */ React.createElement(Button$1, {
|
|
3117
|
+
id: "logout-button",
|
|
3394
3118
|
onClick: handleLogout,
|
|
3395
|
-
|
|
3396
|
-
|
|
3119
|
+
sx: {
|
|
3120
|
+
...headerStyles.button,
|
|
3121
|
+
...headerStyles.logoutButton
|
|
3122
|
+
},
|
|
3123
|
+
"data-testid": "sdk.header-logout-button"
|
|
3124
|
+
}, t("headerLogoutButton"), showCompanyLogo && renderUserCompanyLogo(), renderUserAvatar()) : /* @__PURE__ */ React.createElement(Button$1, {
|
|
3125
|
+
id: "login-button",
|
|
3397
3126
|
onClick: () => navigate("/login"),
|
|
3398
|
-
|
|
3399
|
-
|
|
3127
|
+
sx: {
|
|
3128
|
+
...headerStyles.button,
|
|
3129
|
+
...headerStyles.loginButton
|
|
3130
|
+
},
|
|
3131
|
+
"data-testid": "sdk.header-login-button"
|
|
3132
|
+
}, t("headerLoginButton")));
|
|
3133
|
+
};
|
|
3134
|
+
const renderAuthMenuItem = () => {
|
|
3135
|
+
if (!matchesMD) return userStore_default.getCurrentUserJS ? /* @__PURE__ */ React.createElement(MenuItem, { onClick: handleLogout }, t("headerLogoutButton")) : /* @__PURE__ */ React.createElement(MenuItem, { onClick: () => navigate("/login") }, t("headerLoginButton"));
|
|
3400
3136
|
};
|
|
3401
3137
|
const renderMenu = () => {
|
|
3402
|
-
return menuItems && /* @__PURE__ */
|
|
3138
|
+
return menuItems && /* @__PURE__ */ React.createElement(Box$2, null, /* @__PURE__ */ React.createElement(IconButton$1, {
|
|
3403
3139
|
onClick: handleMenuOpen,
|
|
3404
|
-
"data-testid": "sdk.header.menu-toggle"
|
|
3405
|
-
|
|
3406
|
-
}), /* @__PURE__ */ jsxs(Menu, {
|
|
3140
|
+
"data-testid": "sdk.header.menu-toggle"
|
|
3141
|
+
}, /* @__PURE__ */ React.createElement(MenuIcon, { style: menuButtonColor ? { color: menuButtonColor } : {} })), /* @__PURE__ */ React.createElement(Menu, {
|
|
3407
3142
|
id: "menu-appbar",
|
|
3408
3143
|
marginThreshold: 0,
|
|
3409
3144
|
anchorEl: menuAnchorEl,
|
|
@@ -3418,15 +3153,14 @@ const Header = observer(({ position, scrolled, showAcLogo, leadingText, title, t
|
|
|
3418
3153
|
},
|
|
3419
3154
|
open: Boolean(menuAnchorEl),
|
|
3420
3155
|
onClose: handleMenuClose,
|
|
3421
|
-
sx: headerStyles.menu
|
|
3422
|
-
|
|
3423
|
-
|
|
3424
|
-
|
|
3425
|
-
|
|
3426
|
-
})] });
|
|
3156
|
+
sx: headerStyles.menu
|
|
3157
|
+
}, menuItems.map((item) => /* @__PURE__ */ React.createElement(MenuItem, {
|
|
3158
|
+
key: item.label,
|
|
3159
|
+
onClick: () => handleItemClick(item)
|
|
3160
|
+
}, item.label)), renderAuthMenuItem()));
|
|
3427
3161
|
};
|
|
3428
3162
|
const scrolledBackground = typeof styles?.background === "string" ? styles.background : typeof headerStylesOverrides.root?.background === "string" ? headerStylesOverrides.root.background : "#1B2027";
|
|
3429
|
-
return /* @__PURE__ */
|
|
3163
|
+
return /* @__PURE__ */ React.createElement(AppBar, {
|
|
3430
3164
|
position,
|
|
3431
3165
|
elevation: 0,
|
|
3432
3166
|
sx: {
|
|
@@ -3434,61 +3168,43 @@ const Header = observer(({ position, scrolled, showAcLogo, leadingText, title, t
|
|
|
3434
3168
|
...position === "static" ? { marginTop: "-70px" } : {},
|
|
3435
3169
|
...scrolled || sidebarOpen ? { background: scrolledBackground } : {}
|
|
3436
3170
|
},
|
|
3437
|
-
"data-testid": dataTestID || "sdk.header"
|
|
3438
|
-
|
|
3439
|
-
|
|
3440
|
-
|
|
3441
|
-
|
|
3442
|
-
|
|
3443
|
-
|
|
3444
|
-
|
|
3445
|
-
|
|
3446
|
-
|
|
3447
|
-
|
|
3448
|
-
|
|
3449
|
-
|
|
3450
|
-
|
|
3451
|
-
|
|
3452
|
-
|
|
3453
|
-
|
|
3454
|
-
|
|
3455
|
-
|
|
3456
|
-
|
|
3457
|
-
|
|
3458
|
-
|
|
3459
|
-
|
|
3460
|
-
|
|
3461
|
-
|
|
3462
|
-
|
|
3463
|
-
|
|
3464
|
-
|
|
3465
|
-
|
|
3466
|
-
|
|
3467
|
-
|
|
3468
|
-
|
|
3469
|
-
|
|
3470
|
-
|
|
3471
|
-
|
|
3472
|
-
|
|
3473
|
-
|
|
3474
|
-
}),
|
|
3475
|
-
renderContent(),
|
|
3476
|
-
renderNav(),
|
|
3477
|
-
showUserSection && matchesMD && renderUser(),
|
|
3478
|
-
/* @__PURE__ */ jsx(AccessTimeIcon, {}),
|
|
3479
|
-
/* @__PURE__ */ jsx(Typography$1, {
|
|
3480
|
-
variant: "body1",
|
|
3481
|
-
align: "center",
|
|
3482
|
-
style: {
|
|
3483
|
-
width: "5rem",
|
|
3484
|
-
padding: "0 5px"
|
|
3485
|
-
},
|
|
3486
|
-
children: currentTime.toLocaleTimeString()
|
|
3487
|
-
}),
|
|
3488
|
-
renderMenu()
|
|
3489
|
-
]
|
|
3490
|
-
})
|
|
3491
|
-
});
|
|
3171
|
+
"data-testid": dataTestID || "sdk.header"
|
|
3172
|
+
}, /* @__PURE__ */ React.createElement(Toolbar, { variant: "dense" }, sidebarEnabled && /* @__PURE__ */ React.createElement(IconButton$1, {
|
|
3173
|
+
size: "large",
|
|
3174
|
+
sx: {
|
|
3175
|
+
color: "rgba(255,255,255,0.85)",
|
|
3176
|
+
borderRight: "1px solid rgba(255,255,255,0.5)",
|
|
3177
|
+
...sidebarOpen && {
|
|
3178
|
+
color: "rgba(255,255,255,0.5)",
|
|
3179
|
+
borderTop: "1px solid rgba(255,255,255,0.5)",
|
|
3180
|
+
borderRightColor: "transparent"
|
|
3181
|
+
},
|
|
3182
|
+
"> svg": { transform: "rotate(180deg)" }
|
|
3183
|
+
},
|
|
3184
|
+
onClick: onSidebarToggle,
|
|
3185
|
+
"data-testid": "sdk.header.sidebar-toggle"
|
|
3186
|
+
}, /* @__PURE__ */ React.createElement(ViewSidebarRounded, null)), showAcLogo && /* @__PURE__ */ React.createElement(Link$1, {
|
|
3187
|
+
to: "/",
|
|
3188
|
+
"data-testid": "sdk.header.logo"
|
|
3189
|
+
}, /* @__PURE__ */ React.createElement("img", {
|
|
3190
|
+
src: logo_default,
|
|
3191
|
+
alt: "AndonCloud",
|
|
3192
|
+
style: {
|
|
3193
|
+
display: "block",
|
|
3194
|
+
height: "50px",
|
|
3195
|
+
margin: "0 8px"
|
|
3196
|
+
}
|
|
3197
|
+
})), headerLeadingText && /* @__PURE__ */ React.createElement(Typography$1, {
|
|
3198
|
+
variant: "subtitle1",
|
|
3199
|
+
sx: headerStyles.leadingText
|
|
3200
|
+
}, headerLeadingText), renderContent(), renderNav(), showUserSection && matchesMD && renderUser(), /* @__PURE__ */ React.createElement(AccessTimeIcon, null), /* @__PURE__ */ React.createElement(Typography$1, {
|
|
3201
|
+
variant: "body1",
|
|
3202
|
+
align: "center",
|
|
3203
|
+
style: {
|
|
3204
|
+
width: "5rem",
|
|
3205
|
+
padding: "0 5px"
|
|
3206
|
+
}
|
|
3207
|
+
}, currentTime.toLocaleTimeString()), renderMenu()));
|
|
3492
3208
|
});
|
|
3493
3209
|
//#endregion
|
|
3494
3210
|
//#region src/components/sidebarMenu.styles.js
|
|
@@ -3544,71 +3260,52 @@ const SidebarMenu = ({ open, items, width, styles, listStyles, itemStyles, subit
|
|
|
3544
3260
|
else window.location.href = url;
|
|
3545
3261
|
};
|
|
3546
3262
|
const renderSubitems = (items) => {
|
|
3547
|
-
return /* @__PURE__ */
|
|
3263
|
+
return /* @__PURE__ */ React.createElement(List, {
|
|
3548
3264
|
component: "div",
|
|
3549
3265
|
disablePadding: true,
|
|
3550
|
-
sx: sidebarMenuStyles.subList
|
|
3551
|
-
|
|
3552
|
-
|
|
3553
|
-
|
|
3554
|
-
|
|
3555
|
-
|
|
3556
|
-
|
|
3557
|
-
|
|
3558
|
-
|
|
3559
|
-
|
|
3560
|
-
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
sx: sidebarMenuStyles.subitemText
|
|
3564
|
-
})]
|
|
3565
|
-
})
|
|
3566
|
-
}, label))
|
|
3567
|
-
});
|
|
3266
|
+
sx: sidebarMenuStyles.subList
|
|
3267
|
+
}, items.map(({ action, url, redirect, icon, label }) => /* @__PURE__ */ React.createElement(ListItem, {
|
|
3268
|
+
key: label,
|
|
3269
|
+
sx: sidebarMenuStyles.subitem,
|
|
3270
|
+
disablePadding: true
|
|
3271
|
+
}, /* @__PURE__ */ React.createElement(ListItemButton, {
|
|
3272
|
+
sx: sidebarMenuStyles.subitemButton,
|
|
3273
|
+
onClick: () => handleItemClick(action, url, redirect),
|
|
3274
|
+
"data-testid": `sdk.sidebar.subitem-${label}`
|
|
3275
|
+
}, icon && /* @__PURE__ */ React.createElement(ListItemIcon, { sx: sidebarMenuStyles.itemIcon }, icon), /* @__PURE__ */ React.createElement(ListItemText, {
|
|
3276
|
+
primary: label,
|
|
3277
|
+
sx: sidebarMenuStyles.subitemText
|
|
3278
|
+
})))));
|
|
3568
3279
|
};
|
|
3569
3280
|
const renderItems = () => {
|
|
3570
|
-
return items.map(({ action, url, redirect, icon, label, items }, i) => /* @__PURE__ */
|
|
3281
|
+
return items.map(({ action, url, redirect, icon, label, items }, i) => /* @__PURE__ */ React.createElement(React.Fragment, { key: label }, /* @__PURE__ */ React.createElement(ListItem, {
|
|
3571
3282
|
sx: sidebarMenuStyles.item,
|
|
3572
|
-
disablePadding: true
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
|
|
3583
|
-
|
|
3584
|
-
|
|
3585
|
-
|
|
3586
|
-
}),
|
|
3587
|
-
/* @__PURE__ */ jsx(ListItemText, {
|
|
3588
|
-
primary: label,
|
|
3589
|
-
sx: sidebarMenuStyles.itemText
|
|
3590
|
-
}),
|
|
3591
|
-
!!items?.length && (openedItems[i] ? /* @__PURE__ */ jsx(ExpandLess, {}) : /* @__PURE__ */ jsx(ExpandMore, {}))
|
|
3592
|
-
]
|
|
3593
|
-
})
|
|
3594
|
-
}), !!items?.length && /* @__PURE__ */ jsx(Collapse, {
|
|
3283
|
+
disablePadding: true
|
|
3284
|
+
}, /* @__PURE__ */ React.createElement(ListItemButton, {
|
|
3285
|
+
onClick: () => {
|
|
3286
|
+
if (items?.length) setOpenedItems((current) => {
|
|
3287
|
+
current[i] = !current[i];
|
|
3288
|
+
return { ...current };
|
|
3289
|
+
});
|
|
3290
|
+
else handleItemClick(action, url, redirect);
|
|
3291
|
+
},
|
|
3292
|
+
"data-testid": `sdk.sidebar.item-${label}`
|
|
3293
|
+
}, icon && /* @__PURE__ */ React.createElement(ListItemIcon, { sx: sidebarMenuStyles.itemIcon }, icon), /* @__PURE__ */ React.createElement(ListItemText, {
|
|
3294
|
+
primary: label,
|
|
3295
|
+
sx: sidebarMenuStyles.itemText
|
|
3296
|
+
}), !!items?.length && (openedItems[i] ? /* @__PURE__ */ React.createElement(ExpandLess, null) : /* @__PURE__ */ React.createElement(ExpandMore, null)))), !!items?.length && /* @__PURE__ */ React.createElement(Collapse, {
|
|
3595
3297
|
in: openedItems[i],
|
|
3596
3298
|
timeout: "auto",
|
|
3597
|
-
unmountOnExit: true
|
|
3598
|
-
|
|
3599
|
-
})] }, label));
|
|
3299
|
+
unmountOnExit: true
|
|
3300
|
+
}, renderSubitems(items))));
|
|
3600
3301
|
};
|
|
3601
|
-
return /* @__PURE__ */
|
|
3302
|
+
return /* @__PURE__ */ React.createElement(Drawer, {
|
|
3602
3303
|
sx: sidebarMenuStyles.root,
|
|
3603
3304
|
variant: "persistent",
|
|
3604
3305
|
anchor: "left",
|
|
3605
3306
|
open,
|
|
3606
|
-
"data-testid": "sdk.sidebar.drawer"
|
|
3607
|
-
|
|
3608
|
-
sx: sidebarMenuStyles.list,
|
|
3609
|
-
children: renderItems()
|
|
3610
|
-
})
|
|
3611
|
-
});
|
|
3307
|
+
"data-testid": "sdk.sidebar.drawer"
|
|
3308
|
+
}, /* @__PURE__ */ React.createElement(List, { sx: sidebarMenuStyles.list }, renderItems()));
|
|
3612
3309
|
};
|
|
3613
3310
|
SidebarMenu.propTypes = {
|
|
3614
3311
|
open: PropTypes.bool,
|
|
@@ -3687,38 +3384,25 @@ const SidePanel = ({ open, onClose, title, mainContent, asideContent, width, mai
|
|
|
3687
3384
|
mainContentStyles,
|
|
3688
3385
|
asideContentStyles
|
|
3689
3386
|
});
|
|
3690
|
-
return /* @__PURE__ */
|
|
3387
|
+
return /* @__PURE__ */ React.createElement(Drawer, {
|
|
3691
3388
|
sx: sidePanelStyles.root,
|
|
3692
3389
|
variant: "persistent",
|
|
3693
3390
|
anchor: "right",
|
|
3694
3391
|
open,
|
|
3695
|
-
"data-testid": "sdk.side-panel"
|
|
3696
|
-
|
|
3697
|
-
|
|
3698
|
-
|
|
3699
|
-
|
|
3700
|
-
|
|
3701
|
-
|
|
3702
|
-
|
|
3703
|
-
|
|
3704
|
-
|
|
3705
|
-
|
|
3706
|
-
|
|
3707
|
-
|
|
3708
|
-
|
|
3709
|
-
children: /* @__PURE__ */ jsx(CloseIcon, {})
|
|
3710
|
-
})]
|
|
3711
|
-
}), /* @__PURE__ */ jsxs(Box, {
|
|
3712
|
-
sx: sidePanelStyles.contentWrapper,
|
|
3713
|
-
children: [/* @__PURE__ */ jsx(Box, {
|
|
3714
|
-
sx: sidePanelStyles.mainContent,
|
|
3715
|
-
children: mainContent
|
|
3716
|
-
}), asideContent && /* @__PURE__ */ jsx(Box, {
|
|
3717
|
-
sx: sidePanelStyles.asideContent,
|
|
3718
|
-
children: asideContent
|
|
3719
|
-
})]
|
|
3720
|
-
})]
|
|
3721
|
-
});
|
|
3392
|
+
"data-testid": "sdk.side-panel"
|
|
3393
|
+
}, /* @__PURE__ */ React.createElement(Stack, {
|
|
3394
|
+
direction: "row",
|
|
3395
|
+
justifyContent: "space-between",
|
|
3396
|
+
alignItems: "center",
|
|
3397
|
+
sx: sidePanelStyles.header
|
|
3398
|
+
}, /* @__PURE__ */ React.createElement(Typography, {
|
|
3399
|
+
variant: "h6",
|
|
3400
|
+
fontSize: 18
|
|
3401
|
+
}, title), /* @__PURE__ */ React.createElement(IconButton, {
|
|
3402
|
+
color: "secondary",
|
|
3403
|
+
onClick: onClose,
|
|
3404
|
+
"data-testid": "sdk.side-panel.close"
|
|
3405
|
+
}, /* @__PURE__ */ React.createElement(CloseIcon, null))), /* @__PURE__ */ React.createElement(Box, { sx: sidePanelStyles.contentWrapper }, /* @__PURE__ */ React.createElement(Box, { sx: sidePanelStyles.mainContent }, mainContent), asideContent && /* @__PURE__ */ React.createElement(Box, { sx: sidePanelStyles.asideContent }, asideContent)));
|
|
3722
3406
|
};
|
|
3723
3407
|
SidePanel.propTypes = {
|
|
3724
3408
|
enabled: PropTypes.bool,
|
|
@@ -3806,7 +3490,7 @@ const Container = ({ children, headerProps, sidebarMenuProps, sidePanelProps, st
|
|
|
3806
3490
|
sidebarMenuProps?.enabled,
|
|
3807
3491
|
sidebarOpen
|
|
3808
3492
|
]);
|
|
3809
|
-
return /* @__PURE__ */
|
|
3493
|
+
return /* @__PURE__ */ React.createElement(BaseContainer, {
|
|
3810
3494
|
ref: (node) => {
|
|
3811
3495
|
if (node) setScrollTarget(node);
|
|
3812
3496
|
},
|
|
@@ -3816,34 +3500,27 @@ const Container = ({ children, headerProps, sidebarMenuProps, sidePanelProps, st
|
|
|
3816
3500
|
...baseStyles.root,
|
|
3817
3501
|
...styles
|
|
3818
3502
|
},
|
|
3819
|
-
"data-testid": dataTestID || "sdk.container"
|
|
3820
|
-
|
|
3821
|
-
|
|
3822
|
-
|
|
3823
|
-
|
|
3824
|
-
|
|
3825
|
-
|
|
3826
|
-
|
|
3827
|
-
|
|
3828
|
-
|
|
3829
|
-
|
|
3830
|
-
|
|
3831
|
-
|
|
3832
|
-
|
|
3833
|
-
|
|
3834
|
-
|
|
3835
|
-
|
|
3836
|
-
|
|
3837
|
-
|
|
3838
|
-
|
|
3839
|
-
|
|
3840
|
-
width: sidePanelWidth,
|
|
3841
|
-
mainContentWidth: sidePanelMainContentWidth,
|
|
3842
|
-
asideContentWidth: sidePanelAsideContentWidth
|
|
3843
|
-
}),
|
|
3844
|
-
!isEmbeddedMode && /* @__PURE__ */ jsx(Box, { sx: baseStyles.overlay })
|
|
3845
|
-
]
|
|
3846
|
-
});
|
|
3503
|
+
"data-testid": dataTestID || "sdk.container"
|
|
3504
|
+
}, !isEmbeddedMode && /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Header, {
|
|
3505
|
+
scrolled,
|
|
3506
|
+
showAcLogo: true,
|
|
3507
|
+
sidebarEnabled: sidebarMenuProps?.enabled,
|
|
3508
|
+
sidebarOpen,
|
|
3509
|
+
onSidebarToggle: () => setSidebarOpen((current) => !current),
|
|
3510
|
+
...headerProps
|
|
3511
|
+
}), sidebarMenuProps?.enabled && /* @__PURE__ */ React.createElement(SidebarMenu, {
|
|
3512
|
+
open: sidebarOpen,
|
|
3513
|
+
items: sidebarMenuProps.items,
|
|
3514
|
+
width: sidebarWidth
|
|
3515
|
+
})), /* @__PURE__ */ React.createElement(Main, {
|
|
3516
|
+
open: sidebarOpen,
|
|
3517
|
+
sidebarWidth
|
|
3518
|
+
}, externalUrl ? /* @__PURE__ */ React.createElement(ExternalContent, { src: externalUrl }) : children), sidePanelProps?.enabled && /* @__PURE__ */ React.createElement(SidePanel, {
|
|
3519
|
+
...sidePanelProps,
|
|
3520
|
+
width: sidePanelWidth,
|
|
3521
|
+
mainContentWidth: sidePanelMainContentWidth,
|
|
3522
|
+
asideContentWidth: sidePanelAsideContentWidth
|
|
3523
|
+
}), !isEmbeddedMode && /* @__PURE__ */ React.createElement(Box, { sx: baseStyles.overlay }));
|
|
3847
3524
|
};
|
|
3848
3525
|
Container.propTypes = {
|
|
3849
3526
|
children: PropTypes.any,
|
|
@@ -3910,7 +3587,7 @@ const LoginPage = ({ redirectPath }) => {
|
|
|
3910
3587
|
const toggleLocale = () => {
|
|
3911
3588
|
i18n.changeLanguage(i18n.language === "pl" ? "en" : "pl");
|
|
3912
3589
|
};
|
|
3913
|
-
return /* @__PURE__ */
|
|
3590
|
+
return /* @__PURE__ */ React.createElement(Container, {
|
|
3914
3591
|
headerProps: {
|
|
3915
3592
|
position: "fixed",
|
|
3916
3593
|
leadingText: "AndonCloud Software",
|
|
@@ -3923,21 +3600,16 @@ const LoginPage = ({ redirectPath }) => {
|
|
|
3923
3600
|
buttonColor: "white"
|
|
3924
3601
|
}
|
|
3925
3602
|
},
|
|
3926
|
-
styles: { overflowY: "auto" }
|
|
3927
|
-
|
|
3928
|
-
|
|
3929
|
-
|
|
3930
|
-
|
|
3931
|
-
|
|
3932
|
-
|
|
3933
|
-
|
|
3934
|
-
|
|
3935
|
-
|
|
3936
|
-
redirectPath
|
|
3937
|
-
}) })
|
|
3938
|
-
})
|
|
3939
|
-
})
|
|
3940
|
-
});
|
|
3603
|
+
styles: { overflowY: "auto" }
|
|
3604
|
+
}, /* @__PURE__ */ React.createElement(Box$2, {
|
|
3605
|
+
display: "flex",
|
|
3606
|
+
height: "100%",
|
|
3607
|
+
alignItems: "center",
|
|
3608
|
+
justifyContent: "center"
|
|
3609
|
+
}, /* @__PURE__ */ React.createElement(Card$1, { sx: { borderRadius: "20px" } }, /* @__PURE__ */ React.createElement(CardContent$1, null, /* @__PURE__ */ React.createElement(loginForm_default, {
|
|
3610
|
+
title: t("loginFormText"),
|
|
3611
|
+
redirectPath
|
|
3612
|
+
})))));
|
|
3941
3613
|
};
|
|
3942
3614
|
LoginPage.propTypes = { redirectPath: PropTypes.string };
|
|
3943
3615
|
LoginPage.defaultProps = { redirectPath: "/" };
|
|
@@ -3948,7 +3620,7 @@ const LoginRedirect = () => {
|
|
|
3948
3620
|
const { grantType, redirectPath } = useAuthConfig();
|
|
3949
3621
|
const login = useLogin("read write");
|
|
3950
3622
|
const navigate = useNavigate();
|
|
3951
|
-
if (grantType === "password") return /* @__PURE__ */
|
|
3623
|
+
if (grantType === "password") return /* @__PURE__ */ React.createElement(LoginPage_default, { redirectPath });
|
|
3952
3624
|
navigate("/");
|
|
3953
3625
|
login();
|
|
3954
3626
|
return null;
|
|
@@ -3957,18 +3629,14 @@ const LoginRedirect = () => {
|
|
|
3957
3629
|
//#region src/components/router.js
|
|
3958
3630
|
const SentryRoutes = Sentry.withSentryReactRouterV6Routing(Routes);
|
|
3959
3631
|
const Router = ({ children }) => {
|
|
3960
|
-
return /* @__PURE__ */
|
|
3961
|
-
|
|
3962
|
-
|
|
3963
|
-
|
|
3964
|
-
|
|
3965
|
-
|
|
3966
|
-
|
|
3967
|
-
|
|
3968
|
-
path: "/oauth2/redirect",
|
|
3969
|
-
element: /* @__PURE__ */ jsx(AuthRedirect, {})
|
|
3970
|
-
})
|
|
3971
|
-
] })] });
|
|
3632
|
+
return /* @__PURE__ */ React.createElement(BrowserRouter, null, /* @__PURE__ */ React.createElement(IframeNavigation, null), /* @__PURE__ */ React.createElement(SentryRoutes, null, children, /* @__PURE__ */ React.createElement(Route, {
|
|
3633
|
+
exact: true,
|
|
3634
|
+
path: "/login",
|
|
3635
|
+
element: /* @__PURE__ */ React.createElement(LoginRedirect, null)
|
|
3636
|
+
}), /* @__PURE__ */ React.createElement(Route, {
|
|
3637
|
+
path: "/oauth2/redirect",
|
|
3638
|
+
element: /* @__PURE__ */ React.createElement(AuthRedirect, null)
|
|
3639
|
+
})));
|
|
3972
3640
|
};
|
|
3973
3641
|
//#endregion
|
|
3974
3642
|
//#region src/components/app.js
|
|
@@ -4021,46 +3689,27 @@ const App = observer(({ children, baseUrl, authProps, gtmProps, i18nProps, sentr
|
|
|
4021
3689
|
useEffect(() => {
|
|
4022
3690
|
if (authEnabled && status !== "unknown") appStore_default.setAppReady();
|
|
4023
3691
|
}, [authEnabled, status]);
|
|
4024
|
-
return /* @__PURE__ */
|
|
4025
|
-
|
|
4026
|
-
|
|
4027
|
-
|
|
4028
|
-
|
|
4029
|
-
|
|
4030
|
-
|
|
4031
|
-
|
|
4032
|
-
|
|
4033
|
-
|
|
4034
|
-
|
|
4035
|
-
|
|
4036
|
-
|
|
4037
|
-
|
|
4038
|
-
|
|
4039
|
-
|
|
4040
|
-
|
|
4041
|
-
|
|
4042
|
-
|
|
4043
|
-
|
|
4044
|
-
|
|
4045
|
-
...authProps
|
|
4046
|
-
},
|
|
4047
|
-
children: /* @__PURE__ */ jsx(StoreProvider, { children: /* @__PURE__ */ jsx(I18nextProvider, {
|
|
4048
|
-
i18n: i18n_default,
|
|
4049
|
-
children: /* @__PURE__ */ jsx(MetaInfoProvider, {
|
|
4050
|
-
info: metaProps,
|
|
4051
|
-
children: /* @__PURE__ */ jsxs(DisplayProvider, { children: [sessionStore.networkError ? /* @__PURE__ */ jsx(NetworkError, { error: sessionStore.networkError }) : appStore_default.appReady ? /* @__PURE__ */ jsx(React.Fragment, { children: /* @__PURE__ */ jsx(Router, { children: /* @__PURE__ */ jsx(Route, {
|
|
4052
|
-
path: "*",
|
|
4053
|
-
element: /* @__PURE__ */ jsx(ModalProvider, { children })
|
|
4054
|
-
}) }) }) : /* @__PURE__ */ jsx(LoaderPage, {}), /* @__PURE__ */ jsx(Footer, {
|
|
4055
|
-
appVersion: metaProps.appVersion,
|
|
4056
|
-
apiVersion: metaProps.apiVersion
|
|
4057
|
-
})] })
|
|
4058
|
-
})
|
|
4059
|
-
}) })
|
|
4060
|
-
})]
|
|
4061
|
-
})
|
|
4062
|
-
]
|
|
4063
|
-
});
|
|
3692
|
+
return /* @__PURE__ */ React.createElement(ThemeProvider, { theme: muiTheme }, /* @__PURE__ */ React.createElement(CssBaseline, null), /* @__PURE__ */ React.createElement(GlobalStyles, { styles: {
|
|
3693
|
+
"::-webkit-scrollbar": { width: "6px" },
|
|
3694
|
+
"::-webkit-scrollbar-track": { backgroundColor: "transparent" },
|
|
3695
|
+
"::-webkit-scrollbar-thumb": {
|
|
3696
|
+
borderRadius: "3px",
|
|
3697
|
+
backgroundColor: "rgba(255, 255, 255, 0.25)"
|
|
3698
|
+
}
|
|
3699
|
+
} }), /* @__PURE__ */ React.createElement(Sentry.ErrorBoundary, { fallback: (props) => /* @__PURE__ */ React.createElement(ErrorPage, {
|
|
3700
|
+
appVersion: metaProps.appVersion,
|
|
3701
|
+
apiVersion: metaProps.apiVersion,
|
|
3702
|
+
...props
|
|
3703
|
+
}) }, /* @__PURE__ */ React.createElement(Toaster, null), /* @__PURE__ */ React.createElement(AuthConfigProvider, { config: {
|
|
3704
|
+
baseUrl,
|
|
3705
|
+
...authProps
|
|
3706
|
+
} }, /* @__PURE__ */ React.createElement(StoreProvider, null, /* @__PURE__ */ React.createElement(I18nextProvider, { i18n: i18n_default }, /* @__PURE__ */ React.createElement(MetaInfoProvider, { info: metaProps }, /* @__PURE__ */ React.createElement(DisplayProvider, null, sessionStore.networkError ? /* @__PURE__ */ React.createElement(NetworkError, { error: sessionStore.networkError }) : appStore_default.appReady ? /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Router, null, /* @__PURE__ */ React.createElement(Route, {
|
|
3707
|
+
path: "*",
|
|
3708
|
+
element: /* @__PURE__ */ React.createElement(ModalProvider, null, children)
|
|
3709
|
+
}))) : /* @__PURE__ */ React.createElement(LoaderPage, null), /* @__PURE__ */ React.createElement(Footer, {
|
|
3710
|
+
appVersion: metaProps.appVersion,
|
|
3711
|
+
apiVersion: metaProps.apiVersion
|
|
3712
|
+
}))))))));
|
|
4064
3713
|
});
|
|
4065
3714
|
App.propTypes = {
|
|
4066
3715
|
children: PropTypes.any.isRequired,
|
|
@@ -4132,9 +3781,9 @@ const StyledCheckbox = styled$1(Checkbox$1)(({ theme }) => ({
|
|
|
4132
3781
|
//#endregion
|
|
4133
3782
|
//#region src/core/ui/Checkbox/Checkbox.tsx
|
|
4134
3783
|
const Checkbox = (props) => {
|
|
4135
|
-
return /* @__PURE__ */
|
|
4136
|
-
icon: /* @__PURE__ */
|
|
4137
|
-
checkedIcon: /* @__PURE__ */
|
|
3784
|
+
return /* @__PURE__ */ React.createElement(StyledCheckbox, {
|
|
3785
|
+
icon: /* @__PURE__ */ React.createElement(UncheckedIcon$1, null),
|
|
3786
|
+
checkedIcon: /* @__PURE__ */ React.createElement(CheckedIcon$1, null),
|
|
4138
3787
|
...props
|
|
4139
3788
|
});
|
|
4140
3789
|
};
|
|
@@ -4170,9 +3819,9 @@ const StyledRadio = styled$1(Radio$1)(({ theme }) => ({
|
|
|
4170
3819
|
//#endregion
|
|
4171
3820
|
//#region src/core/ui/Radio/Radio.tsx
|
|
4172
3821
|
const Radio = (props) => {
|
|
4173
|
-
return /* @__PURE__ */
|
|
4174
|
-
icon: /* @__PURE__ */
|
|
4175
|
-
checkedIcon: /* @__PURE__ */
|
|
3822
|
+
return /* @__PURE__ */ React.createElement(StyledRadio, {
|
|
3823
|
+
icon: /* @__PURE__ */ React.createElement(UncheckedIcon, null),
|
|
3824
|
+
checkedIcon: /* @__PURE__ */ React.createElement(CheckedIcon, null),
|
|
4176
3825
|
...props
|
|
4177
3826
|
});
|
|
4178
3827
|
};
|
|
@@ -4190,7 +3839,7 @@ const StyledRadioGroup = styled$1(RadioGroup$1)(({ theme }) => ({
|
|
|
4190
3839
|
//#endregion
|
|
4191
3840
|
//#region src/core/ui/RadioGroup/RadioGroup.tsx
|
|
4192
3841
|
const RadioGroup = (props) => {
|
|
4193
|
-
return /* @__PURE__ */
|
|
3842
|
+
return /* @__PURE__ */ React.createElement(StyledRadioGroup, props);
|
|
4194
3843
|
};
|
|
4195
3844
|
//#endregion
|
|
4196
3845
|
//#region src/hooks/useHeaderContentEvent.ts
|
|
@@ -4226,7 +3875,7 @@ tokenCoordinator.setAuthFetch((url, opts) => authFetch(url, opts));
|
|
|
4226
3875
|
async function authFetch(url, options = {}) {
|
|
4227
3876
|
if (sessionStore.isLoggedIn && sessionStore.session && !options.refresh) {
|
|
4228
3877
|
const { createdAt, expiresIn } = sessionStore.session;
|
|
4229
|
-
if (createdAt + expiresIn - 5 < Math.round(+/* @__PURE__ */ new Date() / 1e3)) if (sessionStore.refreshTokenPromise) await sessionStore.refreshTokenPromise;
|
|
3878
|
+
if (expiresIn > 0 && createdAt + expiresIn - 5 < Math.round(+/* @__PURE__ */ new Date() / 1e3)) if (sessionStore.refreshTokenPromise) await sessionStore.refreshTokenPromise;
|
|
4230
3879
|
else await sessionStore.refresh();
|
|
4231
3880
|
}
|
|
4232
3881
|
const headers = sessionStore.requestHeaders;
|