everest-npm-features 0.0.38 → 0.0.39
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.
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { jsx as a, jsxs as l, Fragment as P } from "react/jsx-runtime";
|
|
2
2
|
import { useState as v, useRef as U } from "react";
|
|
3
|
-
import { a as
|
|
4
|
-
import { DIALOG_ERROR_ICON as
|
|
5
|
-
import { C as
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import { a as M, ac as O, c as
|
|
3
|
+
import { a as C } from "../../../react-redux-B4BZippc.js";
|
|
4
|
+
import { DIALOG_ERROR_ICON as c, DIALOG_SUCCESS_ICON as V } from "../../../util/constants.js";
|
|
5
|
+
import { C as _ } from "../../../Close-CNwiMz_O.js";
|
|
6
|
+
import k from "../../Shared/transition.js";
|
|
7
|
+
import D from "../Shared/CardPayment/index.js";
|
|
8
|
+
import { a as M, ac as O, c as G, K } from "../../../constants-9grj4Du1.js";
|
|
9
9
|
import "../Shared/appButton.js";
|
|
10
10
|
import "../../../hoc/withThemeProvider.js";
|
|
11
11
|
import "../Shared/Auth/otpForm.js";
|
|
12
|
-
import { useSnackBarContext as
|
|
12
|
+
import { useSnackBarContext as F } from "../../../context/snackBarContext.js";
|
|
13
13
|
import "../../../util/conversions.js";
|
|
14
14
|
import "../../../index-CAoLi5Qq.js";
|
|
15
15
|
import "../../../react-webcam-B3cXh1XT.js";
|
|
@@ -23,12 +23,12 @@ import "../../../context/dialogContext.js";
|
|
|
23
23
|
import "../../../index-ceeCtFuh.js";
|
|
24
24
|
import { B as S } from "../../../Box-B0YSYLco.js";
|
|
25
25
|
import { C as b } from "../../../CircularProgress-xZA3lvba.js";
|
|
26
|
-
import { T as
|
|
26
|
+
import { T as h } from "../../../Typography-pAaje37G.js";
|
|
27
27
|
import { D as Y, a as H } from "../../../DialogContent-BMwlOnbW.js";
|
|
28
28
|
import { D as W } from "../../../DialogTitle-CfS0bb2K.js";
|
|
29
29
|
import { I as z } from "../../../IconButton-DHm-hucF.js";
|
|
30
30
|
import { S as j } from "../../../Select-CB5yWmyn.js";
|
|
31
|
-
import { M as
|
|
31
|
+
import { M as u } from "../../../MenuItem-DUdYOJr4.js";
|
|
32
32
|
const Z = [
|
|
33
33
|
{
|
|
34
34
|
alpha3: "AUT",
|
|
@@ -189,22 +189,27 @@ const Z = [
|
|
|
189
189
|
alpha3: "CHE",
|
|
190
190
|
alpha2: "CH",
|
|
191
191
|
name: "Switzerland"
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
alpha3: "GBR",
|
|
195
|
+
alpha2: "GB",
|
|
196
|
+
name: "United Kingdom"
|
|
192
197
|
}
|
|
193
|
-
],
|
|
194
|
-
openDialog:
|
|
198
|
+
], La = ({
|
|
199
|
+
openDialog: t,
|
|
195
200
|
checkoutSdkKey: y,
|
|
196
|
-
paymentRequest:
|
|
197
|
-
iban:
|
|
198
|
-
navigate:
|
|
199
|
-
currency:
|
|
200
|
-
setIbanCurrency:
|
|
201
|
+
paymentRequest: B,
|
|
202
|
+
iban: g,
|
|
203
|
+
navigate: T,
|
|
204
|
+
currency: r,
|
|
205
|
+
setIbanCurrency: d
|
|
201
206
|
}) => {
|
|
202
|
-
const { showAlertMessage:
|
|
203
|
-
if (!
|
|
204
|
-
|
|
207
|
+
const { showAlertMessage: f } = F(), s = C((e) => e.user), i = s.profile, I = C((e) => e.order), x = i.loader, N = s.kyc.loader, p = s.kyc.status, E = i.email, [L, m] = v(!1), n = U(!1), w = () => {
|
|
208
|
+
if (!E) {
|
|
209
|
+
t({
|
|
205
210
|
title: "No Email",
|
|
206
211
|
message: "Please contact support to update your email address.",
|
|
207
|
-
icon:
|
|
212
|
+
icon: c,
|
|
208
213
|
width: "575px",
|
|
209
214
|
confirmButtonText: "Contact Suuport",
|
|
210
215
|
cancelButtonShow: !0,
|
|
@@ -214,8 +219,8 @@ const Z = [
|
|
|
214
219
|
});
|
|
215
220
|
return;
|
|
216
221
|
}
|
|
217
|
-
if (
|
|
218
|
-
|
|
222
|
+
if (p === M || p === O) {
|
|
223
|
+
t({
|
|
219
224
|
title: "Under Review",
|
|
220
225
|
message: "Your profile is currently being reviewed. If approved, you will have additional capabilities on the Everest platform.",
|
|
221
226
|
width: "550px",
|
|
@@ -225,25 +230,37 @@ const Z = [
|
|
|
225
230
|
});
|
|
226
231
|
return;
|
|
227
232
|
}
|
|
228
|
-
if (
|
|
229
|
-
|
|
233
|
+
if (p !== G && p !== K) {
|
|
234
|
+
t({
|
|
230
235
|
title: "Verifying",
|
|
231
236
|
message: "We are gathering information, and will provision your Virtual IBAN shortly.",
|
|
232
237
|
width: "575px",
|
|
233
238
|
height: "400px",
|
|
234
239
|
confirmButtonText: "Continue",
|
|
235
240
|
cancelButtonText: "Cancel",
|
|
236
|
-
onConfirm: () =>
|
|
241
|
+
onConfirm: () => T("/kyc")
|
|
237
242
|
});
|
|
238
243
|
return;
|
|
239
244
|
}
|
|
240
245
|
if (!Z.find(
|
|
241
|
-
(
|
|
246
|
+
(o) => o.alpha3 === i.residentialAddress.country
|
|
242
247
|
)) {
|
|
243
|
-
|
|
248
|
+
t({
|
|
244
249
|
title: "Not Allowed",
|
|
245
250
|
message: "Currently we are not supporting your country for Virtual IBAN.",
|
|
246
|
-
icon:
|
|
251
|
+
icon: c,
|
|
252
|
+
width: "575px",
|
|
253
|
+
height: "450px",
|
|
254
|
+
confirmButtonText: "Continue",
|
|
255
|
+
cancelButtonShow: !1
|
|
256
|
+
});
|
|
257
|
+
return;
|
|
258
|
+
}
|
|
259
|
+
if (i.memberType !== "individual") {
|
|
260
|
+
t({
|
|
261
|
+
title: "Not Allowed",
|
|
262
|
+
message: "Currently we are not supporting organizational wallet(KYB) for Virtual IBAN.",
|
|
263
|
+
icon: c,
|
|
247
264
|
width: "575px",
|
|
248
265
|
height: "450px",
|
|
249
266
|
confirmButtonText: "Continue",
|
|
@@ -251,59 +268,59 @@ const Z = [
|
|
|
251
268
|
});
|
|
252
269
|
return;
|
|
253
270
|
}
|
|
254
|
-
|
|
271
|
+
t({
|
|
255
272
|
title: "Payment",
|
|
256
273
|
message: /* @__PURE__ */ l(S, { children: [
|
|
257
|
-
/* @__PURE__ */ a(
|
|
274
|
+
/* @__PURE__ */ a(h, { children: "You will be charged $12 per annum for creating an Virtual IBAN. Please select currency for the Virtual IBAN and proceed." }),
|
|
258
275
|
/* @__PURE__ */ l(
|
|
259
276
|
j,
|
|
260
277
|
{
|
|
261
278
|
defaultValue: "",
|
|
262
|
-
onChange: (
|
|
263
|
-
|
|
279
|
+
onChange: (o) => {
|
|
280
|
+
r.current = o.target.value, d(o.target.value);
|
|
264
281
|
},
|
|
265
282
|
style: { marginTop: "10px" },
|
|
266
283
|
displayEmpty: !0,
|
|
267
284
|
fullWidth: !0,
|
|
268
285
|
children: [
|
|
269
|
-
/* @__PURE__ */ a(
|
|
270
|
-
/* @__PURE__ */ a(
|
|
271
|
-
/* @__PURE__ */ a(
|
|
286
|
+
/* @__PURE__ */ a(u, { value: "", children: "Select currency" }),
|
|
287
|
+
/* @__PURE__ */ a(u, { value: "EUR", children: "EUR" }),
|
|
288
|
+
/* @__PURE__ */ a(u, { value: "GBP", children: "GBP" })
|
|
272
289
|
]
|
|
273
290
|
}
|
|
274
291
|
)
|
|
275
292
|
] }),
|
|
276
|
-
icon:
|
|
293
|
+
icon: V,
|
|
277
294
|
width: "575px",
|
|
278
295
|
confirmButtonText: "Make Payment",
|
|
279
296
|
cancelButtonShow: !0,
|
|
280
297
|
cancelButtonText: "Cancel",
|
|
281
|
-
closeModalConfirm:
|
|
282
|
-
onConfirm:
|
|
298
|
+
closeModalConfirm: R,
|
|
299
|
+
onConfirm: A,
|
|
283
300
|
onCancel: () => {
|
|
284
|
-
|
|
301
|
+
r.current = "", d(""), n.current = !1;
|
|
285
302
|
},
|
|
286
303
|
onClose: () => {
|
|
287
|
-
|
|
304
|
+
r.current = "", n.current = !1;
|
|
288
305
|
}
|
|
289
306
|
});
|
|
290
|
-
},
|
|
291
|
-
if (
|
|
292
|
-
return
|
|
307
|
+
}, R = () => !n.current, A = () => {
|
|
308
|
+
if (n.current = !1, !r.current)
|
|
309
|
+
return n.current = !0, f({
|
|
293
310
|
message: "Please select currency for Virtual IBAN."
|
|
294
311
|
}), !1;
|
|
295
|
-
const e =
|
|
312
|
+
const e = g.data.find((o) => o.currency === r.current);
|
|
296
313
|
if (e != null && e.id)
|
|
297
|
-
return
|
|
298
|
-
message: `You already have the ${
|
|
314
|
+
return n.current = !0, f({
|
|
315
|
+
message: `You already have the ${r.current} Virtual IBAN.`
|
|
299
316
|
}), !1;
|
|
300
|
-
|
|
317
|
+
m(!0);
|
|
301
318
|
};
|
|
302
|
-
return
|
|
319
|
+
return x || N ? /* @__PURE__ */ a(S, { mt: 4, className: "flex-center", children: /* @__PURE__ */ a(b, { color: "primary", size: 50 }) }) : /* @__PURE__ */ l(P, { children: [
|
|
303
320
|
/* @__PURE__ */ a(
|
|
304
|
-
|
|
321
|
+
h,
|
|
305
322
|
{
|
|
306
|
-
onClick:
|
|
323
|
+
onClick: w,
|
|
307
324
|
component: "span",
|
|
308
325
|
color: "primary",
|
|
309
326
|
sx: { cursor: "pointer" },
|
|
@@ -313,20 +330,20 @@ const Z = [
|
|
|
313
330
|
/* @__PURE__ */ l(
|
|
314
331
|
Y,
|
|
315
332
|
{
|
|
316
|
-
open:
|
|
333
|
+
open: L,
|
|
317
334
|
fullWidth: !0,
|
|
318
|
-
onClose: () =>
|
|
319
|
-
TransitionComponent:
|
|
335
|
+
onClose: () => m(!1),
|
|
336
|
+
TransitionComponent: k,
|
|
320
337
|
children: [
|
|
321
338
|
/* @__PURE__ */ l(W, { className: "buy-modal-text-color", children: [
|
|
322
|
-
/* @__PURE__ */ a(
|
|
339
|
+
/* @__PURE__ */ a(h, { variant: "subtitle1", component: "p", children: /* @__PURE__ */ a("strong", { children: "Payment" }) }),
|
|
323
340
|
/* @__PURE__ */ a(
|
|
324
341
|
z,
|
|
325
342
|
{
|
|
326
343
|
"aria-label": "close",
|
|
327
|
-
onClick: () =>
|
|
344
|
+
onClick: () => m(!1),
|
|
328
345
|
className: "menu-buttons",
|
|
329
|
-
children: /* @__PURE__ */ a(
|
|
346
|
+
children: /* @__PURE__ */ a(_, {})
|
|
330
347
|
}
|
|
331
348
|
)
|
|
332
349
|
] }),
|
|
@@ -337,12 +354,12 @@ const Z = [
|
|
|
337
354
|
sx: { padding: "50px" },
|
|
338
355
|
dividers: !0,
|
|
339
356
|
children: /* @__PURE__ */ a(
|
|
340
|
-
|
|
357
|
+
D,
|
|
341
358
|
{
|
|
342
359
|
checkoutKey: y,
|
|
343
|
-
orderData:
|
|
344
|
-
initPaymentRequest:
|
|
345
|
-
backBtnFunc: () =>
|
|
360
|
+
orderData: I,
|
|
361
|
+
initPaymentRequest: B,
|
|
362
|
+
backBtnFunc: () => m(!1)
|
|
346
363
|
}
|
|
347
364
|
)
|
|
348
365
|
}
|
|
@@ -353,5 +370,5 @@ const Z = [
|
|
|
353
370
|
] });
|
|
354
371
|
};
|
|
355
372
|
export {
|
|
356
|
-
|
|
373
|
+
La as default
|
|
357
374
|
};
|
|
@@ -3,17 +3,17 @@ import { useRef as S, useState as g, useEffect as A } from "react";
|
|
|
3
3
|
import { I as B } from "../../../Info-BVeUSPyk.js";
|
|
4
4
|
import { DIALOG_SUCCESS_ICON as N } from "../../../util/constants.js";
|
|
5
5
|
import "../../../constants-9grj4Du1.js";
|
|
6
|
-
import { a as
|
|
7
|
-
import { M as
|
|
6
|
+
import { a as D } from "../../../order-Cs5_3wOs.js";
|
|
7
|
+
import { M as b } from "../../../tooltip-3UvETWtS.js";
|
|
8
8
|
import q from "../Shared/noData.js";
|
|
9
9
|
import w from "./createIban.js";
|
|
10
10
|
import { AuthInnerContainer as P } from "../Shared/Container/index.js";
|
|
11
11
|
import R from "./ibanItem.js";
|
|
12
12
|
import { B as a } from "../../../Box-B0YSYLco.js";
|
|
13
13
|
import { G as s } from "../../../Grid-CFe3amXO.js";
|
|
14
|
-
import { T as
|
|
15
|
-
import { I as
|
|
16
|
-
import { C as
|
|
14
|
+
import { T as v } from "../../../Typography-pAaje37G.js";
|
|
15
|
+
import { I as T } from "../../../IconButton-DHm-hucF.js";
|
|
16
|
+
import { C as _ } from "../../../CircularProgress-xZA3lvba.js";
|
|
17
17
|
const Q = ({
|
|
18
18
|
dispatch: c,
|
|
19
19
|
openDialog: i,
|
|
@@ -22,9 +22,9 @@ const Q = ({
|
|
|
22
22
|
appKey: u,
|
|
23
23
|
iban: r,
|
|
24
24
|
navigate: d,
|
|
25
|
-
AccountItem:
|
|
25
|
+
AccountItem: y
|
|
26
26
|
}) => {
|
|
27
|
-
const p = r.data,
|
|
27
|
+
const p = r.data, h = r.loader, I = S(""), [x, C] = g("");
|
|
28
28
|
return A(() => {
|
|
29
29
|
new URLSearchParams(window.location.search).get("paymentStatus") === "success" && i({
|
|
30
30
|
title: "Payment Success",
|
|
@@ -36,13 +36,13 @@ const Q = ({
|
|
|
36
36
|
}, []), /* @__PURE__ */ e(P, { children: /* @__PURE__ */ o(a, { p: 3, children: [
|
|
37
37
|
/* @__PURE__ */ o(s, { spacing: 2, container: !0, alignItems: "center", children: [
|
|
38
38
|
/* @__PURE__ */ o(s, { size: 8, children: [
|
|
39
|
-
/* @__PURE__ */ e(
|
|
39
|
+
/* @__PURE__ */ e(v, { color: "primary", variant: "h6", component: "span", children: /* @__PURE__ */ e("strong", { children: "Everest Accounts (Virtual IBAN)" }) }),
|
|
40
40
|
/* @__PURE__ */ e(
|
|
41
|
-
|
|
41
|
+
b,
|
|
42
42
|
{
|
|
43
43
|
title: /* @__PURE__ */ e(a, { sx: { whiteSpace: "pre-line" }, children: "Create a Virtual IBAN of EUR currency. This requires KYC and an annual payment" }),
|
|
44
44
|
placement: "bottom",
|
|
45
|
-
children: /* @__PURE__ */ e(
|
|
45
|
+
children: /* @__PURE__ */ e(T, { className: "info-fee-icon", children: /* @__PURE__ */ e(B, { sx: { fontSize: "26px", color: "#D9D9D9" } }) })
|
|
46
46
|
}
|
|
47
47
|
)
|
|
48
48
|
] }),
|
|
@@ -53,15 +53,17 @@ const Q = ({
|
|
|
53
53
|
checkoutSdkKey: f,
|
|
54
54
|
paymentRequest: (t) => {
|
|
55
55
|
const n = {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
56
|
+
payment: {
|
|
57
|
+
token: t,
|
|
58
|
+
amount: 12,
|
|
59
|
+
currency: "USD",
|
|
60
|
+
app_key: u,
|
|
61
|
+
success_url: `${m}/accounts?payment=success`,
|
|
62
|
+
fail_url: `${m}/dashboard?payment=failed`
|
|
63
|
+
},
|
|
64
|
+
currency: x
|
|
63
65
|
};
|
|
64
|
-
c(
|
|
66
|
+
c(D(n));
|
|
65
67
|
},
|
|
66
68
|
iban: r,
|
|
67
69
|
navigate: d,
|
|
@@ -70,11 +72,11 @@ const Q = ({
|
|
|
70
72
|
}
|
|
71
73
|
) }) })
|
|
72
74
|
] }),
|
|
73
|
-
|
|
75
|
+
h ? /* @__PURE__ */ e(a, { mt: 4, className: "flex-center", children: /* @__PURE__ */ e(_, { color: "primary", size: 50 }) }) : /* @__PURE__ */ e(l, { children: p.length > 0 ? /* @__PURE__ */ e(l, { children: p.map((t, n) => /* @__PURE__ */ e(
|
|
74
76
|
R,
|
|
75
77
|
{
|
|
76
78
|
data: t,
|
|
77
|
-
AccountItem:
|
|
79
|
+
AccountItem: y,
|
|
78
80
|
dispatch: c,
|
|
79
81
|
appKey: u,
|
|
80
82
|
iban: r
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "everest-npm-features",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.39",
|
|
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.29",
|
|
36
36
|
"frames-react": "^1.2.2",
|
|
37
37
|
"moment": "^2.30.1",
|
|
38
38
|
"mui-one-time-password-input": "^5.0.0",
|