everest-npm-features 0.0.47 → 0.0.49
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/{PlayArrow-Cm8tJN8W.js → PlayArrow-C3uVNo4F.js} +1 -1
- package/dist/assets/styles.css +1 -1
- package/dist/assets/styles2.css +1 -1
- package/dist/assets/styles3.css +1 -1
- package/dist/assets/styles4.css +1 -0
- package/dist/{auth-D0r8wtCH.js → auth-ClBgT--j.js} +1 -1
- package/dist/{bank-BmV_keEr.js → bank-Dz5km1qK.js} +3 -3
- package/dist/components/RocketRamp/MinimalKyc/form.js +14 -13
- package/dist/components/RocketRamp/Player/Buy/cardPayment.js +3 -3
- package/dist/components/RocketRamp/Player/Buy/confirmTransaction.js +3 -3
- package/dist/components/RocketRamp/Player/Buy/form.js +4 -4
- package/dist/components/RocketRamp/Player/Buy/index.js +12 -11
- package/dist/components/RocketRamp/Player/Dashboard/index.js +25 -24
- package/dist/components/RocketRamp/Player/Sell/confirmTransaction.js +3 -3
- package/dist/components/RocketRamp/Player/Sell/form.js +4 -4
- package/dist/components/RocketRamp/Player/Sell/index.js +12 -11
- package/dist/components/RocketRamp/Player/SignIn/index.js +20 -19
- package/dist/components/RocketRamp/Player/SignIn/loginForm.js +2 -2
- package/dist/components/RocketRamp/Player/SignIn/otpForm.js +2 -2
- package/dist/components/RocketRamp/Player/SignUp/email.js +2 -2
- package/dist/components/RocketRamp/Player/SignUp/index.js +39 -38
- package/dist/components/RocketRamp/Player/SignUp/personalInfo.js +2 -2
- package/dist/components/RocketRamp/ResetPassword/index.js +21 -20
- package/dist/components/RocketRamp/Store/SignUp/index.js +48 -47
- package/dist/components/RocketRamp/Store/SignUp/personalInfo.js +2 -2
- package/dist/components/RocketRamp/Store/SignUp/storeInfo.js +2 -2
- package/dist/components/RocketRamp/Transactions/index.js +14 -13
- package/dist/components/Shared/FullKyc/edd.js +41 -41
- package/dist/components/Shared/FullKyc/index.js +11 -10
- package/dist/components/Shared/FullKyc/pep.js +1 -1
- package/dist/components/Shared/FullKyc/personalDetails.js +2 -2
- package/dist/components/Shared/FullKyc/userInfo.js +4 -4
- package/dist/components/Shared/MinimalKyc/index.js +31 -30
- package/dist/components/Wallet/Account/createIban.d.ts +2 -0
- package/dist/components/Wallet/Account/createIban.js +70 -62
- package/dist/components/Wallet/Account/eWallet.d.ts +20 -0
- package/dist/components/Wallet/Account/eWallet.js +96 -0
- package/dist/components/Wallet/Account/iban.d.ts +2 -0
- package/dist/components/Wallet/Account/iban.js +38 -32
- package/dist/components/Wallet/Account/ibanItem.d.ts +5 -2
- package/dist/components/Wallet/Account/ibanItem.js +233 -76
- package/dist/components/Wallet/Account/index.d.ts +2 -0
- package/dist/components/Wallet/Account/index.js +164 -143
- package/dist/components/Wallet/Account/sendIban.js +3 -3
- package/dist/components/Wallet/Buy/confirmTransaction.js +6 -6
- package/dist/components/Wallet/Buy/form.js +6 -6
- package/dist/components/Wallet/Buy/index.js +14 -13
- package/dist/components/Wallet/Deposit/index.js +1 -1
- package/dist/components/Wallet/EnterpriseKyc/edd.js +9 -9
- package/dist/components/Wallet/EnterpriseKyc/index.js +23 -22
- package/dist/components/Wallet/EnterpriseKyc/orgDetails.js +24 -24
- package/dist/components/Wallet/EnterpriseKyc/orgInfo.js +1 -1
- package/dist/components/Wallet/EnterpriseKyc/verify.js +1 -1
- package/dist/components/Wallet/History/index.js +25 -24
- package/dist/components/Wallet/MoveToEthereumOrEverChain/index.js +49 -48
- package/dist/components/Wallet/Portfolio/index.js +34 -33
- package/dist/components/Wallet/Profile/documents.js +527 -28
- package/dist/components/Wallet/Profile/index.js +179 -149
- package/dist/components/Wallet/Profile/storage.d.ts +11 -0
- package/dist/components/Wallet/Profile/storage.js +267 -0
- package/dist/components/Wallet/Receive/index.js +22 -21
- package/dist/components/Wallet/Sell/confirmTransaction.js +5 -5
- package/dist/components/Wallet/Sell/form.js +6 -6
- package/dist/components/Wallet/Sell/index.js +13 -12
- package/dist/components/Wallet/Send/index.js +44 -43
- package/dist/components/Wallet/Shared/Auth/otpForm.js +2 -2
- package/dist/components/Wallet/Shared/BankSelect/index.js +36 -35
- package/dist/components/Wallet/Shared/CardCorp/index.d.ts +1 -1
- package/dist/components/Wallet/Shared/CardCorp/index.js +16 -16
- package/dist/components/Wallet/Shared/addBank.js +39 -38
- package/dist/components/Wallet/Shared/connectPlaidBank.js +19 -18
- package/dist/components/Wallet/Shared/manualSend.js +7 -6
- package/dist/components/Wallet/Shared/pin.js +1 -1
- package/dist/components/Wallet/SignIn/index.js +24 -23
- package/dist/components/Wallet/SignUp/index.js +22 -21
- package/dist/components/Wallet/Stake/gems/index.js +1 -1
- package/dist/components/Wallet/Stake/id/index.js +1 -1
- package/dist/components/Wallet/Stake/index.js +31 -30
- package/dist/components/Wallet/Swap/form.js +9 -8
- package/dist/components/Wallet/Swap/index.js +11 -10
- package/dist/components/Wallet/Withdraw/bankSelect.js +28 -27
- package/dist/components/Wallet/Withdraw/confirmTransaction.js +5 -5
- package/dist/components/Wallet/Withdraw/form.js +5 -5
- package/dist/components/Wallet/Withdraw/index.js +12 -11
- package/dist/{constants-BJhUp96H.js → constants-t7n9qCW3.js} +559 -553
- package/dist/{cryptoAssets-Q_UWeuzR.js → cryptoAssets-shEFU26O.js} +1 -1
- package/dist/hooks/useDialog/index.js +1 -1
- package/dist/hooks/useEverestDispatch.d.ts +6 -0
- package/dist/hooks/useEverestDispatch.js +5 -0
- package/dist/{index-Dkjl8hIv.js → index-B6MSTmAM.js} +112 -111
- package/dist/{index-MUaN67Ei.js → index-C2EjFXaz.js} +88 -87
- package/dist/{index-pCrOsXNC.js → index-Cs7bSfT3.js} +29 -28
- package/dist/{index-DegQ9bTI.js → index-DFRU-R-5.js} +39 -38
- package/dist/{index-BRnTzw1Z.js → index-Da0r8FX2.js} +11 -10
- package/dist/{index-Dq5wTY4S.js → index-RDV0mQbt.js} +36 -35
- package/dist/{index-B2wXmFh5.js → index-j0zehpzg.js} +41 -40
- package/dist/{kyc-DLaLS7sp.js → kyc-D9xahfH9.js} +1 -1
- package/dist/main.js +7 -7
- package/dist/{order-fWKVFTau.js → order-jqH948WM.js} +29 -25
- package/dist/{react-redux-B4BZippc.js → react-redux-C7I9-1M6.js} +2 -2
- package/dist/{stake-CQLutF0z.js → stake-Dcq6QpaA.js} +3 -3
- package/dist/{styles.module-O5VVND5e.js → styles.module-C1sNeKjL.js} +1 -1
- package/dist/styles.module-CHPRGltL.js +28 -0
- package/dist/{styles.module-CHEBh2ID.js → styles.module-DMd29SPQ.js} +1 -1
- package/dist/{styles.module-CUA1zLEJ.js → styles.module-verVx4pE.js} +1 -1
- package/dist/util/constants.d.ts +5 -0
- package/dist/util/constants.js +86 -81
- package/dist/util/functions.js +36 -36
- package/dist/{wallet-CuQDBP6a.js → wallet-DpkUmmq0.js} +1 -1
- package/package.json +3 -2
- package/dist/assets/documents.css +0 -1
- package/dist/documents-RjwlADn2.js +0 -552
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { U as a, p as e, F as t, q as E, r as T, s as A, t as _, u as o, v as S, w as l } from "./constants-
|
|
1
|
+
import { U as a, p as e, F as t, q as E, r as T, s as A, t as _, u as o, v as S, w as l } from "./constants-t7n9qCW3.js";
|
|
2
2
|
const L = () => ({
|
|
3
3
|
type: a
|
|
4
4
|
}), d = () => ({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "everest-npm-features",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.49",
|
|
4
4
|
"description": "Everest frontend features library.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/main.js",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"@mui/icons-material": "^7.2.0",
|
|
33
33
|
"@mui/material": "^7.2.0",
|
|
34
34
|
"@walletconnect/ethereum-provider": "^2.17.1",
|
|
35
|
-
"everest-npm-api": "^0.0.
|
|
35
|
+
"everest-npm-api": "^0.0.37",
|
|
36
36
|
"frames-react": "^1.2.2",
|
|
37
37
|
"moment": "^2.30.1",
|
|
38
38
|
"mui-one-time-password-input": "^5.0.0",
|
|
@@ -45,6 +45,7 @@
|
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@eslint/js": "^9.8.0",
|
|
48
|
+
"@reduxjs/toolkit": "^2.10.1",
|
|
48
49
|
"@types/node": "^22.2.0",
|
|
49
50
|
"@types/uuid": "^10.0.0",
|
|
50
51
|
"@vitejs/plugin-react": "^4.3.1",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
._container_2oghf_1{display:flex;align-items:center;margin-top:130px}._inner-container_2oghf_13{background:#fff;width:100%;border-radius:4px;filter:drop-shadow(0px 2px 15px rgba(0,0,0,.05))}._heading_2oghf_27{overflow:hidden;text-overflow:ellipsis;margin-top:5px;color:#16359d}._profile-feat-btn_2oghf_41{background:linear-gradient(358deg,#c8d4ff -49.02%,#fff 85.25%);border-radius:100px;color:#000;font-weight:700;padding:5px 12px}._ref-btn_2oghf_57{background:linear-gradient(180deg,#fff -34.21%,#44dcb7 342.37%);border-radius:100px;color:#000;font-weight:700;padding:10px 12px}._sBtn_2oghf_73{padding:10px 12px;border-radius:100px;background:#fff;border:3px solid #000000;color:#000;font-size:14px;text-transform:none;box-shadow:none}._sBtn_2oghf_73:disabled{border:3px solid #a6a6a6;color:#a6a6a6}._sBtn_2oghf_73:hover{border:3px solid #000000;background:#000;color:#fff}._doc-video-box_2oghf_117{position:relative}._doc-video-box_2oghf_117:before,._doc-video-box_2oghf_117:after,._doc-video-box_2oghf_117>:first-child:before,._doc-video-box_2oghf_117>:first-child:after{position:absolute;content:" ";width:80px;height:80px;border:4px solid#16359D}._doc-video-box_2oghf_117:before{top:-20px;left:-20px;border-width:4px 0 0 4px;border-top-left-radius:30px}._doc-video-box_2oghf_117:after{top:-20px;right:-20px;border-width:4px 4px 0 0;border-top-right-radius:30px}._doc-video-box_2oghf_117>:first-child:before{bottom:-15px;right:-20px;border-width:0 4px 4px 0;border-bottom-right-radius:30px}._doc-video-box_2oghf_117>:first-child:after{bottom:-15px;left:-20px;border-width:0 0 4px 4px;border-bottom-left-radius:30px}._image-corner-color_2oghf_193:before,._image-corner-color_2oghf_193:after,._image-corner-color_2oghf_193>:first-child:before,._image-corner-color_2oghf_193>:first-child:after{border-color:#00b171}._video-box-inner-content_2oghf_207{max-width:100%;height:auto}._menu-item_2oghf_217{padding:8px 20px;margin-top:19px;border-radius:8px;border:.5px solid #d0d0d0;cursor:pointer}._remove-icon_2oghf_233{position:absolute;top:-20px;right:-20px;color:#f44336}._delete-disable_2oghf_247{background:#16359d;border-radius:100px;color:#fff;font-weight:700;padding:10px 12px}._confirm-edit_2oghf_263{background:linear-gradient(180deg,#fff -34.21%,#44dcb7 342.37%);border-radius:100px;color:#000;font-weight:700;padding:10px 12px}._asset-header_2oghf_279{display:flex;height:68px;justify-content:flex-start;align-items:center;flex-shrink:0;background:linear-gradient(89.98deg,#35e0f41a .02%,#33d7f01a 6.97%,#2ebde41a 18.55%,#2594d01a 33.31%,#195bb61a 50.5%,#1132a31a 61.64%,#1132a31a 99.98%);box-shadow:0 2px 3px #00000026}._asset-close-btn_2oghf_317{position:absolute;right:8px;top:12px;color:#000}._dialog-container_2oghf_331{display:flex;flex-direction:column;align-items:center;text-align:center}._confirm-dialog_2oghf_345{background:linear-gradient(180deg,#fff -34.21%,#44dcb7 342.37%)}._confirm-dialog-title_2oghf_353{color:#16359d;font-weight:700;font-size:28px}._tweet-text-parent_2oghf_365{padding:2px;border:1px solid #ccc;min-width:300px;max-width:450px;max-height:250px;min-height:200px;overflow:auto;outline:none;resize:both;background:#fff}._tweet-disable-text_2oghf_391{background-color:#e8e8e8;width:fit-content;padding-left:10px;padding-right:10px;border-radius:10px;height:fit-content}._tweet-text-area_2oghf_409{width:100%;border:0px solid;outline:none;resize:none;font-size:16px;height:100px}._twitterCancelBtn_2oghf_427{padding:10px 12px;border-radius:100px;background:#fff;border:3px solid #16359d;color:#16359d;font-size:14px;text-transform:none;box-shadow:none}._twitterCancelBtn_2oghf_427:disabled{border:3px solid #a6a6a6;color:#a6a6a6}._twitterCancelBtn_2oghf_427:hover{border:3px solid #16359d;background:#16359d;color:#fff}._kyc-approved_2oghf_471{padding:6px 12px!important;border-radius:100px!important;background:#fff!important;border:3px solid #28a745!important;color:#28a745!important;font-size:14px!important;text-transform:none!important;box-shadow:none!important}
|
|
@@ -1,552 +0,0 @@
|
|
|
1
|
-
import { jsx as e, jsxs as t, Fragment as C } from "react/jsx-runtime";
|
|
2
|
-
import { useState as f, useEffect as A, useRef as Y } from "react";
|
|
3
|
-
import { C as F } from "./Close-CNwiMz_O.js";
|
|
4
|
-
import { D as oe } from "./Delete-jpMstGIF.js";
|
|
5
|
-
import { C as re } from "./Cancel-4lT7GZUA.js";
|
|
6
|
-
import ie from "./components/Wallet/Shared/inputField.js";
|
|
7
|
-
import j from "./components/Wallet/Shared/step.js";
|
|
8
|
-
import { W as ce } from "./react-webcam-B3cXh1XT.js";
|
|
9
|
-
import { c as ae } from "./createSvgIcon-Cuzqm90l.js";
|
|
10
|
-
import se from "./components/Shared/transition.js";
|
|
11
|
-
import { getDocName as le } from "./util/functions.js";
|
|
12
|
-
import { u as de, a as me } from "./react-redux-B4BZippc.js";
|
|
13
|
-
import { ar as he, as as ue, at as pe, au as fe, av as ge, aw as _e } from "./constants-BJhUp96H.js";
|
|
14
|
-
import { e as xe } from "./index-BQNs1mvn.js";
|
|
15
|
-
import { RIGHT_ARROW as M, DELETE_ICON as De } from "./util/constants.js";
|
|
16
|
-
import { useDialog as be } from "./hooks/useDialog/index.js";
|
|
17
|
-
import g from "./components/Wallet/Shared/appButton.js";
|
|
18
|
-
import { B as Ce } from "./Backdrop-CioURPVG.js";
|
|
19
|
-
import { C as T } from "./CircularProgress-xZA3lvba.js";
|
|
20
|
-
import { T as a } from "./Typography-pAaje37G.js";
|
|
21
|
-
import { B as ve } from "./Button-Df4vgU24.js";
|
|
22
|
-
import { B as c } from "./Box-B0YSYLco.js";
|
|
23
|
-
import { D as L, a as z } from "./DialogContent-BMwlOnbW.js";
|
|
24
|
-
import { D as $ } from "./DialogTitle-CfS0bb2K.js";
|
|
25
|
-
import { I as k } from "./IconButton-DHm-hucF.js";
|
|
26
|
-
import { D as V } from "./Divider-BShhMFf4.js";
|
|
27
|
-
import { G as h } from "./Grid-CFe3amXO.js";
|
|
28
|
-
import './assets/documents.css';const ye = () => ({
|
|
29
|
-
type: ue
|
|
30
|
-
}), Ne = (o) => ({
|
|
31
|
-
type: fe,
|
|
32
|
-
payload: o
|
|
33
|
-
}), Ee = (o) => ({
|
|
34
|
-
type: ge,
|
|
35
|
-
payload: o
|
|
36
|
-
}), J = () => ({
|
|
37
|
-
type: he
|
|
38
|
-
}), Se = (o) => ({
|
|
39
|
-
type: _e,
|
|
40
|
-
payload: o
|
|
41
|
-
}), ke = (o) => ({
|
|
42
|
-
type: pe,
|
|
43
|
-
payload: o
|
|
44
|
-
}), we = "_container_2oghf_1", Ie = "_heading_2oghf_27", Te = "_sBtn_2oghf_73", Re = "_twitterCancelBtn_2oghf_427", i = {
|
|
45
|
-
container: we,
|
|
46
|
-
"inner-container": "_inner-container_2oghf_13",
|
|
47
|
-
heading: Ie,
|
|
48
|
-
"profile-feat-btn": "_profile-feat-btn_2oghf_41",
|
|
49
|
-
"ref-btn": "_ref-btn_2oghf_57",
|
|
50
|
-
sBtn: Te,
|
|
51
|
-
"doc-video-box": "_doc-video-box_2oghf_117",
|
|
52
|
-
"image-corner-color": "_image-corner-color_2oghf_193",
|
|
53
|
-
"video-box-inner-content": "_video-box-inner-content_2oghf_207",
|
|
54
|
-
"menu-item": "_menu-item_2oghf_217",
|
|
55
|
-
"remove-icon": "_remove-icon_2oghf_233",
|
|
56
|
-
"delete-disable": "_delete-disable_2oghf_247",
|
|
57
|
-
"confirm-edit": "_confirm-edit_2oghf_263",
|
|
58
|
-
"asset-header": "_asset-header_2oghf_279",
|
|
59
|
-
"asset-close-btn": "_asset-close-btn_2oghf_317",
|
|
60
|
-
"dialog-container": "_dialog-container_2oghf_331",
|
|
61
|
-
"confirm-dialog": "_confirm-dialog_2oghf_345",
|
|
62
|
-
"confirm-dialog-title": "_confirm-dialog-title_2oghf_353",
|
|
63
|
-
"tweet-text-parent": "_tweet-text-parent_2oghf_365",
|
|
64
|
-
"tweet-disable-text": "_tweet-disable-text_2oghf_391",
|
|
65
|
-
"tweet-text-area": "_tweet-text-area_2oghf_409",
|
|
66
|
-
twitterCancelBtn: Re,
|
|
67
|
-
"kyc-approved": "_kyc-approved_2oghf_471"
|
|
68
|
-
}, Be = ae(/* @__PURE__ */ e("path", {
|
|
69
|
-
d: "M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20z"
|
|
70
|
-
}), "ArrowBack"), We = ({
|
|
71
|
-
showAlertMessage: o,
|
|
72
|
-
documentName: m,
|
|
73
|
-
setDocumentName: _,
|
|
74
|
-
setDocumentScreen: u
|
|
75
|
-
}) => /* @__PURE__ */ t(c, { className: "text-center", children: [
|
|
76
|
-
/* @__PURE__ */ e(j, { totalSteps: 2, currentStep: 1 }),
|
|
77
|
-
/* @__PURE__ */ e(a, { className: "secondary-text-color", variant: "h5", children: /* @__PURE__ */ e("strong", { children: "Name your document" }) }),
|
|
78
|
-
/* @__PURE__ */ e(
|
|
79
|
-
ie,
|
|
80
|
-
{
|
|
81
|
-
label: "Document Name",
|
|
82
|
-
value: m,
|
|
83
|
-
onChangeHandler: (r) => _(r)
|
|
84
|
-
}
|
|
85
|
-
),
|
|
86
|
-
/* @__PURE__ */ e(
|
|
87
|
-
g,
|
|
88
|
-
{
|
|
89
|
-
sx: { mt: 4, mb: 4 },
|
|
90
|
-
onClick: () => {
|
|
91
|
-
if (!m)
|
|
92
|
-
return o({ message: "Please provide the document name" }), !1;
|
|
93
|
-
u(2);
|
|
94
|
-
},
|
|
95
|
-
disabled: !m,
|
|
96
|
-
fullWidth: !0,
|
|
97
|
-
children: /* @__PURE__ */ e("strong", { children: "Next" })
|
|
98
|
-
}
|
|
99
|
-
)
|
|
100
|
-
] }), Pe = ({
|
|
101
|
-
showAlertMessage: o,
|
|
102
|
-
uploadLoader: m,
|
|
103
|
-
uploadDocument: _,
|
|
104
|
-
documentFile: u,
|
|
105
|
-
setDocumentFile: s,
|
|
106
|
-
setDocumentScreen: r
|
|
107
|
-
}) => {
|
|
108
|
-
const l = Y(null), [x, p] = f("Choose File");
|
|
109
|
-
return /* @__PURE__ */ t(c, { className: "text-center", children: [
|
|
110
|
-
/* @__PURE__ */ e(j, { totalSteps: 2, currentStep: 2 }),
|
|
111
|
-
/* @__PURE__ */ e(a, { className: "fw500", variant: "h6", children: "Uploaded files must be image format (PDF, PNG or JPEG/JPG)" }),
|
|
112
|
-
/* @__PURE__ */ t(h, { mt: 2, container: !0, spacing: 2, children: [
|
|
113
|
-
/* @__PURE__ */ e(h, { size: 6, children: /* @__PURE__ */ e(
|
|
114
|
-
g,
|
|
115
|
-
{
|
|
116
|
-
variantType: "secondary",
|
|
117
|
-
onClick: () => r(3),
|
|
118
|
-
fullWidth: !0,
|
|
119
|
-
children: "Use Camera"
|
|
120
|
-
}
|
|
121
|
-
) }),
|
|
122
|
-
/* @__PURE__ */ e(h, { size: 6, children: /* @__PURE__ */ e(
|
|
123
|
-
g,
|
|
124
|
-
{
|
|
125
|
-
variantType: "secondary",
|
|
126
|
-
onClick: () => l.current && l.current.click(),
|
|
127
|
-
sx: { overflow: "hidden" },
|
|
128
|
-
fullWidth: !0,
|
|
129
|
-
children: x
|
|
130
|
-
}
|
|
131
|
-
) })
|
|
132
|
-
] }),
|
|
133
|
-
/* @__PURE__ */ e(
|
|
134
|
-
"input",
|
|
135
|
-
{
|
|
136
|
-
ref: l,
|
|
137
|
-
onChange: (d) => {
|
|
138
|
-
if (d.target.files && !d.target.files[0].name.match(/.(jpg|jpeg|png)$/i))
|
|
139
|
-
o({ message: "Please provide a valid file" });
|
|
140
|
-
else if (d.target.files && d.target.files[0]) {
|
|
141
|
-
p(d.target.files[0].name);
|
|
142
|
-
let b = new FileReader();
|
|
143
|
-
b.onload = (w) => {
|
|
144
|
-
var N;
|
|
145
|
-
const y = (N = w.target) == null ? void 0 : N.result;
|
|
146
|
-
if (typeof y == "string") {
|
|
147
|
-
const R = y.split(/[,]/);
|
|
148
|
-
s(R[1]);
|
|
149
|
-
}
|
|
150
|
-
}, b.readAsDataURL(d.target.files[0]);
|
|
151
|
-
}
|
|
152
|
-
},
|
|
153
|
-
accept: ".jpg,.jpeg,.png,.pdf,",
|
|
154
|
-
type: "file",
|
|
155
|
-
hidden: !0
|
|
156
|
-
}
|
|
157
|
-
),
|
|
158
|
-
m ? /* @__PURE__ */ t(c, { mt: 4, sx: { color: "#00B171", textAlign: "center" }, children: [
|
|
159
|
-
/* @__PURE__ */ e(T, { size: 30, color: "inherit" }),
|
|
160
|
-
/* @__PURE__ */ t(a, { variant: "h5", sx: { fontWeight: "bold" }, children: [
|
|
161
|
-
"Processing...",
|
|
162
|
-
/* @__PURE__ */ e("br", {}),
|
|
163
|
-
"one moment please"
|
|
164
|
-
] })
|
|
165
|
-
] }) : /* @__PURE__ */ e(
|
|
166
|
-
g,
|
|
167
|
-
{
|
|
168
|
-
sx: { mt: 4, mb: 4 },
|
|
169
|
-
onClick: () => {
|
|
170
|
-
if (!u)
|
|
171
|
-
return o({ message: "Please provide the document" }), !1;
|
|
172
|
-
_();
|
|
173
|
-
},
|
|
174
|
-
disabled: !u,
|
|
175
|
-
fullWidth: !0,
|
|
176
|
-
children: /* @__PURE__ */ e("strong", { children: "Submit" })
|
|
177
|
-
}
|
|
178
|
-
)
|
|
179
|
-
] });
|
|
180
|
-
}, Ue = ({
|
|
181
|
-
showAlertMessage: o,
|
|
182
|
-
documentFile: m,
|
|
183
|
-
setDocumentFile: _,
|
|
184
|
-
uploadDocument: u,
|
|
185
|
-
uploadLoader: s
|
|
186
|
-
}) => {
|
|
187
|
-
const r = Y(null), l = {
|
|
188
|
-
audio: !1,
|
|
189
|
-
height: {
|
|
190
|
-
min: 720
|
|
191
|
-
},
|
|
192
|
-
width: {
|
|
193
|
-
ideal: 1280
|
|
194
|
-
},
|
|
195
|
-
aspectRatio: 1.333,
|
|
196
|
-
// 4:3
|
|
197
|
-
facingMode: "user",
|
|
198
|
-
frameRate: {
|
|
199
|
-
ideal: 30,
|
|
200
|
-
max: 30
|
|
201
|
-
}
|
|
202
|
-
}, [x, p] = f(""), D = () => {
|
|
203
|
-
if (r.current) {
|
|
204
|
-
const d = r.current.getScreenshot(), b = d.split(/[,]/);
|
|
205
|
-
_(b[1]), p(d);
|
|
206
|
-
}
|
|
207
|
-
}, v = () => {
|
|
208
|
-
if (!x)
|
|
209
|
-
return o({
|
|
210
|
-
message: "Please take the photo of the document"
|
|
211
|
-
}), !1;
|
|
212
|
-
u();
|
|
213
|
-
};
|
|
214
|
-
return /* @__PURE__ */ t(c, { className: "text-center", children: [
|
|
215
|
-
/* @__PURE__ */ e(j, { totalSteps: 2, currentStep: 2 }),
|
|
216
|
-
x ? /* @__PURE__ */ t(C, { children: [
|
|
217
|
-
/* @__PURE__ */ t(
|
|
218
|
-
c,
|
|
219
|
-
{
|
|
220
|
-
className: `${i["doc-video-box"]} ${i["image-corner-color"]}`,
|
|
221
|
-
children: [
|
|
222
|
-
/* @__PURE__ */ e("span", {}),
|
|
223
|
-
/* @__PURE__ */ e(
|
|
224
|
-
"img",
|
|
225
|
-
{
|
|
226
|
-
className: i["video-box-inner-content"],
|
|
227
|
-
src: x,
|
|
228
|
-
alt: "doc"
|
|
229
|
-
}
|
|
230
|
-
)
|
|
231
|
-
]
|
|
232
|
-
}
|
|
233
|
-
),
|
|
234
|
-
s ? /* @__PURE__ */ t(c, { mt: 4, sx: { color: "#00B171", textAlign: "center" }, children: [
|
|
235
|
-
/* @__PURE__ */ e(T, { size: 30, color: "inherit" }),
|
|
236
|
-
/* @__PURE__ */ t(a, { variant: "h5", sx: { fontWeight: "bold" }, children: [
|
|
237
|
-
"Processing...",
|
|
238
|
-
/* @__PURE__ */ e("br", {}),
|
|
239
|
-
"one moment please"
|
|
240
|
-
] })
|
|
241
|
-
] }) : /* @__PURE__ */ t(C, { children: [
|
|
242
|
-
/* @__PURE__ */ e(
|
|
243
|
-
g,
|
|
244
|
-
{
|
|
245
|
-
onClick: v,
|
|
246
|
-
sx: { mt: 6 },
|
|
247
|
-
disabled: !m,
|
|
248
|
-
fullWidth: !0,
|
|
249
|
-
children: /* @__PURE__ */ e("strong", { children: "Submit" })
|
|
250
|
-
}
|
|
251
|
-
),
|
|
252
|
-
/* @__PURE__ */ e(
|
|
253
|
-
g,
|
|
254
|
-
{
|
|
255
|
-
variantType: "secondary",
|
|
256
|
-
onClick: () => p(""),
|
|
257
|
-
sx: { mt: 2 },
|
|
258
|
-
fullWidth: !0,
|
|
259
|
-
children: /* @__PURE__ */ e("strong", { children: "Retake Photo" })
|
|
260
|
-
}
|
|
261
|
-
)
|
|
262
|
-
] })
|
|
263
|
-
] }) : /* @__PURE__ */ t(C, { children: [
|
|
264
|
-
/* @__PURE__ */ t(c, { className: i["doc-video-box"], children: [
|
|
265
|
-
/* @__PURE__ */ e("span", {}),
|
|
266
|
-
/* @__PURE__ */ e(
|
|
267
|
-
ce,
|
|
268
|
-
{
|
|
269
|
-
className: i["video-box-inner-content"],
|
|
270
|
-
audio: !1,
|
|
271
|
-
ref: r,
|
|
272
|
-
screenshotFormat: "image/jpeg",
|
|
273
|
-
videoConstraints: l,
|
|
274
|
-
minScreenshotHeight: l.height.min,
|
|
275
|
-
minScreenshotWidth: l.width.ideal,
|
|
276
|
-
screenshotQuality: 1
|
|
277
|
-
}
|
|
278
|
-
)
|
|
279
|
-
] }),
|
|
280
|
-
/* @__PURE__ */ e(g, { onClick: D, sx: { mt: 8 }, fullWidth: !0, children: /* @__PURE__ */ e("strong", { children: "Take Photo" }) })
|
|
281
|
-
] })
|
|
282
|
-
] });
|
|
283
|
-
}, lt = ({ showAlertMessage: o, identityDocs: m }) => {
|
|
284
|
-
const { openDialog: _, ConfirmDialog: u } = be(), s = de(), r = me(xe), l = r.data, x = r.loader, p = r.message, D = r.error, v = r.preview.front, d = r.preview.back, b = r.preview.loader, w = r.uploadLoader, [y, N] = f(!1), [R, O] = f(!1), [B, E] = f(1), [K, G] = f(!1), [W, Q] = f(""), [I, P] = f("");
|
|
285
|
-
A(() => {
|
|
286
|
-
D && o({ message: D });
|
|
287
|
-
}, [D]), A(() => {
|
|
288
|
-
p && (o({ message: p, type: "success" }), N(!1), U());
|
|
289
|
-
}, [p]);
|
|
290
|
-
const q = () => {
|
|
291
|
-
if (!W)
|
|
292
|
-
return o({ message: "Please provide the document name" }), !1;
|
|
293
|
-
if (!I)
|
|
294
|
-
return o({ message: "Please provide the document" }), !1;
|
|
295
|
-
s(
|
|
296
|
-
ke({
|
|
297
|
-
filename: W.trim(),
|
|
298
|
-
content: I
|
|
299
|
-
})
|
|
300
|
-
);
|
|
301
|
-
}, X = () => {
|
|
302
|
-
s(ye());
|
|
303
|
-
};
|
|
304
|
-
A(() => {
|
|
305
|
-
X();
|
|
306
|
-
}, []);
|
|
307
|
-
const Z = (n) => {
|
|
308
|
-
s(Ne(n));
|
|
309
|
-
}, ee = (n) => {
|
|
310
|
-
s(Ee(n));
|
|
311
|
-
}, te = (n) => {
|
|
312
|
-
_({
|
|
313
|
-
icon: De,
|
|
314
|
-
height: "450px",
|
|
315
|
-
title: "Are you sure you want to delete?",
|
|
316
|
-
message: "This action cannot be undone.",
|
|
317
|
-
onConfirm: () => {
|
|
318
|
-
ne(n);
|
|
319
|
-
},
|
|
320
|
-
cancelButtonShow: !0
|
|
321
|
-
});
|
|
322
|
-
}, ne = (n) => {
|
|
323
|
-
s(Se(n));
|
|
324
|
-
}, H = ({ data: n, type: S }) => S === "identity" ? /* @__PURE__ */ e(
|
|
325
|
-
c,
|
|
326
|
-
{
|
|
327
|
-
className: i["menu-item"],
|
|
328
|
-
onClick: () => n.documentId && Z(n.documentId),
|
|
329
|
-
children: /* @__PURE__ */ t(h, { container: !0, sx: { width: "100%" }, children: [
|
|
330
|
-
/* @__PURE__ */ e(h, { size: 10, className: "content-center", children: /* @__PURE__ */ e(c, { sx: { textAlign: "left" }, children: /* @__PURE__ */ e(a, { color: "primary", children: /* @__PURE__ */ e("strong", { children: n.documentType && le(n.documentType) }) }) }) }),
|
|
331
|
-
/* @__PURE__ */ e(h, { size: 2, children: /* @__PURE__ */ e(a, { sx: { textAlign: "right" }, children: /* @__PURE__ */ e("img", { src: M, alt: "arrow" }) }) })
|
|
332
|
-
] })
|
|
333
|
-
}
|
|
334
|
-
) : /* @__PURE__ */ t(c, { sx: { position: "relative" }, className: i["menu-item"], children: [
|
|
335
|
-
y && /* @__PURE__ */ e(
|
|
336
|
-
k,
|
|
337
|
-
{
|
|
338
|
-
className: i["remove-icon"],
|
|
339
|
-
onClick: () => te(n.filename),
|
|
340
|
-
children: /* @__PURE__ */ e(re, {})
|
|
341
|
-
}
|
|
342
|
-
),
|
|
343
|
-
/* @__PURE__ */ t(
|
|
344
|
-
h,
|
|
345
|
-
{
|
|
346
|
-
onClick: () => ee(n.filename),
|
|
347
|
-
container: !0,
|
|
348
|
-
sx: { width: "100%" },
|
|
349
|
-
children: [
|
|
350
|
-
/* @__PURE__ */ e(h, { size: 10, className: "content-center", children: /* @__PURE__ */ e(c, { sx: { textAlign: "left" }, children: /* @__PURE__ */ e(a, { color: "primary", children: /* @__PURE__ */ e("strong", { children: n.filename }) }) }) }),
|
|
351
|
-
/* @__PURE__ */ e(h, { size: 2, children: /* @__PURE__ */ e(a, { sx: { textAlign: "right" }, children: /* @__PURE__ */ e("img", { src: M, alt: "arrow" }) }) })
|
|
352
|
-
]
|
|
353
|
-
}
|
|
354
|
-
)
|
|
355
|
-
] }), U = () => {
|
|
356
|
-
Q(""), P(""), E(1), G(!1);
|
|
357
|
-
};
|
|
358
|
-
return /* @__PURE__ */ t(C, { children: [
|
|
359
|
-
/* @__PURE__ */ e(u, {}),
|
|
360
|
-
/* @__PURE__ */ e(
|
|
361
|
-
Ce,
|
|
362
|
-
{
|
|
363
|
-
sx: {
|
|
364
|
-
color: "#fff",
|
|
365
|
-
zIndex: (n) => n.zIndex.drawer + 1e3
|
|
366
|
-
},
|
|
367
|
-
open: b,
|
|
368
|
-
children: /* @__PURE__ */ e(T, { color: "inherit" })
|
|
369
|
-
}
|
|
370
|
-
),
|
|
371
|
-
/* @__PURE__ */ e(a, { className: i.heading, variant: "h6", children: /* @__PURE__ */ e("strong", { children: "My Documents" }) }),
|
|
372
|
-
l.length > 0 && /* @__PURE__ */ t(
|
|
373
|
-
ve,
|
|
374
|
-
{
|
|
375
|
-
className: `${y ? i["delete-disable"] : i["confirm-edit"]} normal-text`,
|
|
376
|
-
sx: { mt: 3, mb: 3 },
|
|
377
|
-
variant: "contained",
|
|
378
|
-
onClick: () => N((n) => !n),
|
|
379
|
-
children: [
|
|
380
|
-
/* @__PURE__ */ e(oe, {}),
|
|
381
|
-
"Delete"
|
|
382
|
-
]
|
|
383
|
-
}
|
|
384
|
-
),
|
|
385
|
-
x ? /* @__PURE__ */ e(c, { className: "text-center", mt: 8, children: /* @__PURE__ */ e(T, {}) }) : /* @__PURE__ */ t(C, { children: [
|
|
386
|
-
m && m.map((n, S) => /* @__PURE__ */ e(H, { data: n, type: "identity" }, S)),
|
|
387
|
-
l && l.map((n, S) => /* @__PURE__ */ e(H, { data: n, type: "normal" }, S)),
|
|
388
|
-
!m && l.length === 0 && /* @__PURE__ */ e(a, { mt: 4, className: "text-center", variant: "h4", children: "No Documents" })
|
|
389
|
-
] }),
|
|
390
|
-
/* @__PURE__ */ e(
|
|
391
|
-
g,
|
|
392
|
-
{
|
|
393
|
-
sx: { mt: 4 },
|
|
394
|
-
onClick: () => G(!0),
|
|
395
|
-
fullWidth: !0,
|
|
396
|
-
children: /* @__PURE__ */ e("strong", { children: "Add new document" })
|
|
397
|
-
}
|
|
398
|
-
),
|
|
399
|
-
/* @__PURE__ */ t(
|
|
400
|
-
L,
|
|
401
|
-
{
|
|
402
|
-
open: R,
|
|
403
|
-
fullWidth: !0,
|
|
404
|
-
onClose: () => O(!1),
|
|
405
|
-
children: [
|
|
406
|
-
/* @__PURE__ */ e($, { sx: { mt: 1, p: 2, color: "#16359D" }, children: /* @__PURE__ */ e(
|
|
407
|
-
k,
|
|
408
|
-
{
|
|
409
|
-
"aria-label": "close",
|
|
410
|
-
onClick: () => O(!1),
|
|
411
|
-
sx: {
|
|
412
|
-
position: "absolute",
|
|
413
|
-
right: 8,
|
|
414
|
-
top: 8,
|
|
415
|
-
color: "#16359D"
|
|
416
|
-
},
|
|
417
|
-
children: /* @__PURE__ */ e(F, {})
|
|
418
|
-
}
|
|
419
|
-
) }),
|
|
420
|
-
/* @__PURE__ */ e(V, { sx: { mt: 2 } }),
|
|
421
|
-
/* @__PURE__ */ e(z, { children: /* @__PURE__ */ e(c, { children: "Add Document Modal" }) })
|
|
422
|
-
]
|
|
423
|
-
}
|
|
424
|
-
),
|
|
425
|
-
/* @__PURE__ */ t(
|
|
426
|
-
L,
|
|
427
|
-
{
|
|
428
|
-
open: !!v,
|
|
429
|
-
fullWidth: !0,
|
|
430
|
-
onClose: () => s(J()),
|
|
431
|
-
children: [
|
|
432
|
-
/* @__PURE__ */ e($, { sx: { mt: 1, p: 2, color: "#16359D" }, children: /* @__PURE__ */ e(
|
|
433
|
-
k,
|
|
434
|
-
{
|
|
435
|
-
"aria-label": "close",
|
|
436
|
-
onClick: () => s(J()),
|
|
437
|
-
sx: {
|
|
438
|
-
position: "absolute",
|
|
439
|
-
right: 8,
|
|
440
|
-
top: 8,
|
|
441
|
-
color: "#16359D"
|
|
442
|
-
},
|
|
443
|
-
children: /* @__PURE__ */ e(F, {})
|
|
444
|
-
}
|
|
445
|
-
) }),
|
|
446
|
-
/* @__PURE__ */ e(V, { sx: { mt: 2 } }),
|
|
447
|
-
/* @__PURE__ */ e(z, { children: /* @__PURE__ */ t(c, { children: [
|
|
448
|
-
/* @__PURE__ */ e(a, { variant: "h5", mb: 3, children: "Front Image" }),
|
|
449
|
-
/* @__PURE__ */ e(
|
|
450
|
-
"img",
|
|
451
|
-
{
|
|
452
|
-
className: i["video-box-inner-content"],
|
|
453
|
-
src: "data:image/jpeg;base64," + v,
|
|
454
|
-
alt: "Front"
|
|
455
|
-
}
|
|
456
|
-
),
|
|
457
|
-
d && /* @__PURE__ */ t(C, { children: [
|
|
458
|
-
/* @__PURE__ */ e(a, { variant: "h5", mt: 2, mb: 3, children: "Back Image" }),
|
|
459
|
-
/* @__PURE__ */ e(
|
|
460
|
-
"img",
|
|
461
|
-
{
|
|
462
|
-
className: i["video-box-inner-content"],
|
|
463
|
-
src: "data:image/jpeg;base64," + d,
|
|
464
|
-
alt: "Back"
|
|
465
|
-
}
|
|
466
|
-
)
|
|
467
|
-
] })
|
|
468
|
-
] }) })
|
|
469
|
-
]
|
|
470
|
-
}
|
|
471
|
-
),
|
|
472
|
-
/* @__PURE__ */ t(
|
|
473
|
-
L,
|
|
474
|
-
{
|
|
475
|
-
fullWidth: !0,
|
|
476
|
-
open: K,
|
|
477
|
-
onClose: U,
|
|
478
|
-
TransitionComponent: se,
|
|
479
|
-
children: [
|
|
480
|
-
/* @__PURE__ */ t(c, { className: i["asset-header"], children: [
|
|
481
|
-
/* @__PURE__ */ e(
|
|
482
|
-
k,
|
|
483
|
-
{
|
|
484
|
-
"aria-label": "close",
|
|
485
|
-
onClick: () => E(
|
|
486
|
-
B - 1 <= 0 ? 1 : B - 1
|
|
487
|
-
),
|
|
488
|
-
sx: { color: "#16359d", ml: "20px" },
|
|
489
|
-
children: /* @__PURE__ */ e(Be, {})
|
|
490
|
-
}
|
|
491
|
-
),
|
|
492
|
-
/* @__PURE__ */ e(
|
|
493
|
-
a,
|
|
494
|
-
{
|
|
495
|
-
className: "secondary-text-color",
|
|
496
|
-
variant: "subtitle1",
|
|
497
|
-
component: "p",
|
|
498
|
-
children: /* @__PURE__ */ e("strong", { children: "Add new document" })
|
|
499
|
-
}
|
|
500
|
-
),
|
|
501
|
-
/* @__PURE__ */ e(
|
|
502
|
-
k,
|
|
503
|
-
{
|
|
504
|
-
"aria-label": "close",
|
|
505
|
-
onClick: U,
|
|
506
|
-
className: i["asset-close-btn"],
|
|
507
|
-
children: /* @__PURE__ */ e(F, {})
|
|
508
|
-
}
|
|
509
|
-
)
|
|
510
|
-
] }),
|
|
511
|
-
/* @__PURE__ */ e(z, { sx: { padding: "20px 45px" }, dividers: !0, children: {
|
|
512
|
-
1: /* @__PURE__ */ e(
|
|
513
|
-
We,
|
|
514
|
-
{
|
|
515
|
-
showAlertMessage: o,
|
|
516
|
-
documentName: W,
|
|
517
|
-
setDocumentName: Q,
|
|
518
|
-
setDocumentScreen: E
|
|
519
|
-
}
|
|
520
|
-
),
|
|
521
|
-
2: /* @__PURE__ */ e(
|
|
522
|
-
Pe,
|
|
523
|
-
{
|
|
524
|
-
showAlertMessage: o,
|
|
525
|
-
setDocumentScreen: E,
|
|
526
|
-
documentFile: I,
|
|
527
|
-
setDocumentFile: P,
|
|
528
|
-
uploadDocument: q,
|
|
529
|
-
uploadLoader: w
|
|
530
|
-
}
|
|
531
|
-
),
|
|
532
|
-
3: /* @__PURE__ */ e(
|
|
533
|
-
Ue,
|
|
534
|
-
{
|
|
535
|
-
showAlertMessage: o,
|
|
536
|
-
setDocumentScreen: E,
|
|
537
|
-
documentFile: I,
|
|
538
|
-
setDocumentFile: P,
|
|
539
|
-
uploadDocument: q,
|
|
540
|
-
uploadLoader: w
|
|
541
|
-
}
|
|
542
|
-
)
|
|
543
|
-
}[B] })
|
|
544
|
-
]
|
|
545
|
-
}
|
|
546
|
-
)
|
|
547
|
-
] });
|
|
548
|
-
};
|
|
549
|
-
export {
|
|
550
|
-
lt as D,
|
|
551
|
-
i as s
|
|
552
|
-
};
|