everest-npm-features 0.0.9 → 0.0.10
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/components/RocketRamp/Player/Buy/cardPayment.js +1 -1
- package/dist/components/RocketRamp/Player/Buy/confirmTransaction.js +1 -1
- package/dist/components/RocketRamp/Player/Buy/form.js +1 -1
- package/dist/components/RocketRamp/Player/Buy/index.js +1 -1
- package/dist/components/RocketRamp/Player/Buy/types.d.ts +1 -0
- package/dist/components/RocketRamp/Player/SignUp/personalInfo.js +80 -75
- package/dist/components/RocketRamp/Player/SignUp/validateEmail.js +14 -14
- package/dist/components/RocketRamp/Shared/Input/index.d.ts +6 -0
- package/dist/components/RocketRamp/Shared/Input/index.js +64 -25
- package/dist/components/RocketRamp/Store/SignUp/personalInfo.js +60 -59
- package/dist/components/RocketRamp/Store/SignUp/storeInfo.js +54 -46
- package/dist/{index-BMhrzXlc.js → index-DNVjDI72.js} +255 -250
- package/dist/main.js +1 -1
- package/dist/util/constants.d.ts +2 -0
- package/dist/util/constants.js +27 -25
- package/dist/util/functions.js +1 -1
- package/dist/util/regex.d.ts +3 -0
- package/dist/util/regex.js +5 -2
- package/package.json +1 -1
|
@@ -1,79 +1,80 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as s, Fragment as S, jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { useState as b } from "react";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
3
|
+
import T from "../../Shared/Button/index.js";
|
|
4
|
+
import i from "../../Shared/Input/index.js";
|
|
5
5
|
import "../../../../constants-74hrsFxy.js";
|
|
6
|
-
import { f as
|
|
6
|
+
import { f as y } from "../../../../auth-CD4Ih2jU.js";
|
|
7
7
|
import { generateRandomString as B, isValidEmail as L } from "../../../../util/functions.js";
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import { F as q
|
|
14
|
-
import {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
8
|
+
import { userNameRegex as W } from "../../../../util/regex.js";
|
|
9
|
+
import { T as v } from "../../../../Typography-Du8mj1kr.js";
|
|
10
|
+
import { B as j } from "../../../../Box-Bt8cGqC7.js";
|
|
11
|
+
import { S as F } from "../../../../Stack-Ce-OQAtj.js";
|
|
12
|
+
import { I as E } from "../../../../InputAdornment-HG4f5A6g.js";
|
|
13
|
+
import { F as q } from "../../../../FormControl-C_Aq5EJK.js";
|
|
14
|
+
import { F as D, C as V } from "../../../../FormControlLabel-DzW2M9Zf.js";
|
|
15
|
+
import { L as _ } from "../../../../Link-0ytX5jId.js";
|
|
16
|
+
const I = ({
|
|
17
|
+
showAlertMessage: t,
|
|
18
|
+
loader: h,
|
|
18
19
|
registerInfo: e,
|
|
19
20
|
setRegisterInfo: N,
|
|
20
21
|
setCurrentStep: P,
|
|
21
|
-
dispatch:
|
|
22
|
-
validationError:
|
|
22
|
+
dispatch: f,
|
|
23
|
+
validationError: o,
|
|
23
24
|
validationField: m
|
|
24
25
|
}) => {
|
|
25
|
-
const d = B(), [p,
|
|
26
|
+
const d = B(), [p, x] = b(!1), [l, C] = b({
|
|
26
27
|
firstName: !1,
|
|
27
28
|
lastName: !1,
|
|
28
29
|
phone: !1,
|
|
29
30
|
email: !1
|
|
30
|
-
}), n = (a,
|
|
31
|
-
a === "phone" && !/^\d*$/.test(
|
|
32
|
-
...
|
|
33
|
-
[a]:
|
|
34
|
-
})),
|
|
35
|
-
...
|
|
31
|
+
}), n = (a, u) => {
|
|
32
|
+
a === "phone" && !/^\d*$/.test(u) || a === "username" && !W.test(u) || (N((c) => ({
|
|
33
|
+
...c,
|
|
34
|
+
[a]: u
|
|
35
|
+
})), C((c) => ({
|
|
36
|
+
...c,
|
|
36
37
|
[a]: !0
|
|
37
38
|
})));
|
|
38
|
-
},
|
|
39
|
+
}, k = (a) => {
|
|
39
40
|
if (a.preventDefault(), !e.firstName)
|
|
40
|
-
return
|
|
41
|
+
return t({ message: "Please provide your name." }), !1;
|
|
41
42
|
if (!e.lastName)
|
|
42
|
-
return
|
|
43
|
+
return t({ message: "Please provide your surname." }), !1;
|
|
43
44
|
if (!e.phone)
|
|
44
|
-
return
|
|
45
|
+
return t({ message: "Please provide your mobile number." }), !1;
|
|
45
46
|
if (!e.email)
|
|
46
|
-
return
|
|
47
|
+
return t({ message: "Please provide email address." }), !1;
|
|
47
48
|
if (!L(e.email))
|
|
48
|
-
return
|
|
49
|
+
return t({ message: "Please provide valid email address." }), !1;
|
|
49
50
|
if (!p)
|
|
50
|
-
return
|
|
51
|
+
return t({ message: "Please accept the privacy terms." }), !1;
|
|
51
52
|
P(2);
|
|
52
53
|
}, R = () => {
|
|
53
|
-
e.phone &&
|
|
54
|
-
|
|
54
|
+
e.phone && f(
|
|
55
|
+
y({
|
|
55
56
|
phone: "+1" + e.phone,
|
|
56
57
|
storename: d
|
|
57
58
|
})
|
|
58
59
|
);
|
|
59
|
-
},
|
|
60
|
-
e.email &&
|
|
61
|
-
|
|
60
|
+
}, g = () => {
|
|
61
|
+
e.email && f(
|
|
62
|
+
y({
|
|
62
63
|
email: e.email,
|
|
63
64
|
storename: d
|
|
64
65
|
})
|
|
65
66
|
);
|
|
66
67
|
};
|
|
67
|
-
return /* @__PURE__ */
|
|
68
|
-
/* @__PURE__ */
|
|
68
|
+
return /* @__PURE__ */ s(S, { children: [
|
|
69
|
+
/* @__PURE__ */ s(v, { variant: "3xl", fontWeight: "bold", children: [
|
|
69
70
|
"Ready to join us?",
|
|
70
71
|
/* @__PURE__ */ r("br", {}),
|
|
71
72
|
"Tell us about yourself"
|
|
72
73
|
] }),
|
|
73
|
-
/* @__PURE__ */ r(
|
|
74
|
-
/* @__PURE__ */ r(
|
|
74
|
+
/* @__PURE__ */ r(v, { variant: "sm", children: "Please, provide the following information:" }),
|
|
75
|
+
/* @__PURE__ */ r(j, { component: "form", onSubmit: k, width: "100%", children: /* @__PURE__ */ s(F, { direction: "column", gap: 2, children: [
|
|
75
76
|
/* @__PURE__ */ r(
|
|
76
|
-
|
|
77
|
+
i,
|
|
77
78
|
{
|
|
78
79
|
value: e.firstName,
|
|
79
80
|
label: "First name",
|
|
@@ -84,7 +85,7 @@ const A = ({
|
|
|
84
85
|
}
|
|
85
86
|
),
|
|
86
87
|
/* @__PURE__ */ r(
|
|
87
|
-
|
|
88
|
+
i,
|
|
88
89
|
{
|
|
89
90
|
value: e.lastName,
|
|
90
91
|
label: "Last name",
|
|
@@ -95,50 +96,50 @@ const A = ({
|
|
|
95
96
|
}
|
|
96
97
|
),
|
|
97
98
|
/* @__PURE__ */ r(
|
|
98
|
-
|
|
99
|
+
i,
|
|
99
100
|
{
|
|
100
101
|
value: e.phone,
|
|
101
102
|
label: "Mobile number",
|
|
102
103
|
placeholder: "Enter your mobile number",
|
|
103
104
|
onChange: (a) => n("phone", a.target.value),
|
|
104
105
|
onBlur: R,
|
|
105
|
-
error: l.phone && !e.phone || m === "phone" && !!
|
|
106
|
-
errorText: m === "phone" ?
|
|
106
|
+
error: l.phone && !e.phone || m === "phone" && !!o,
|
|
107
|
+
errorText: m === "phone" ? o : "",
|
|
107
108
|
slotProps: {
|
|
108
109
|
input: {
|
|
109
|
-
startAdornment: /* @__PURE__ */ r(
|
|
110
|
+
startAdornment: /* @__PURE__ */ r(E, { position: "start", children: "+1" })
|
|
110
111
|
}
|
|
111
112
|
}
|
|
112
113
|
}
|
|
113
114
|
),
|
|
114
115
|
/* @__PURE__ */ r(
|
|
115
|
-
|
|
116
|
+
i,
|
|
116
117
|
{
|
|
117
118
|
value: e.email,
|
|
118
119
|
label: "E-mail address",
|
|
119
120
|
onChange: (a) => n("email", a.target.value),
|
|
120
|
-
onBlur:
|
|
121
|
-
error: l.email && !e.email || m === "email" && !!
|
|
122
|
-
errorText: m === "email" ?
|
|
121
|
+
onBlur: g,
|
|
122
|
+
error: l.email && !e.email || m === "email" && !!o,
|
|
123
|
+
errorText: m === "email" ? o : "",
|
|
123
124
|
fullWidth: !0
|
|
124
125
|
}
|
|
125
126
|
),
|
|
126
|
-
/* @__PURE__ */ r(
|
|
127
|
-
|
|
127
|
+
/* @__PURE__ */ r(q, { error: !p, component: "fieldset", children: /* @__PURE__ */ r(
|
|
128
|
+
D,
|
|
128
129
|
{
|
|
129
130
|
control: /* @__PURE__ */ r(
|
|
130
|
-
|
|
131
|
+
V,
|
|
131
132
|
{
|
|
132
133
|
checked: p,
|
|
133
|
-
onChange: () =>
|
|
134
|
+
onChange: () => x((a) => !a),
|
|
134
135
|
color: "primary"
|
|
135
136
|
}
|
|
136
137
|
),
|
|
137
|
-
label: /* @__PURE__ */
|
|
138
|
+
label: /* @__PURE__ */ s("span", { children: [
|
|
138
139
|
"I accept the",
|
|
139
140
|
" ",
|
|
140
141
|
/* @__PURE__ */ r(
|
|
141
|
-
|
|
142
|
+
_,
|
|
142
143
|
{
|
|
143
144
|
href: "https://www.rocket-ramp.com/page/privacy",
|
|
144
145
|
target: "_blank",
|
|
@@ -151,12 +152,12 @@ const A = ({
|
|
|
151
152
|
}
|
|
152
153
|
) }),
|
|
153
154
|
/* @__PURE__ */ r(
|
|
154
|
-
|
|
155
|
+
T,
|
|
155
156
|
{
|
|
156
157
|
type: "submit",
|
|
157
158
|
fullWidth: !0,
|
|
158
|
-
disabled: !!
|
|
159
|
-
isLoading:
|
|
159
|
+
disabled: !!o || h,
|
|
160
|
+
isLoading: h,
|
|
160
161
|
children: "Next"
|
|
161
162
|
}
|
|
162
163
|
)
|
|
@@ -164,5 +165,5 @@ const A = ({
|
|
|
164
165
|
] });
|
|
165
166
|
};
|
|
166
167
|
export {
|
|
167
|
-
|
|
168
|
+
I as default
|
|
168
169
|
};
|
|
@@ -1,24 +1,26 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { useState as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
1
|
+
import { jsxs as d, Fragment as y, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { useState as c } from "react";
|
|
3
|
+
import p from "../../Shared/Button/index.js";
|
|
4
|
+
import u, { UserNameInputField as C } from "../../Shared/Input/index.js";
|
|
5
5
|
import "../../../../constants-74hrsFxy.js";
|
|
6
|
-
import { f as
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
|
|
6
|
+
import { f as k } from "../../../../auth-CD4Ih2jU.js";
|
|
7
|
+
import { USERNAME_SUFFIX as w, USERNAME_TOOLTIP as T } from "../../../../util/constants.js";
|
|
8
|
+
import { storeNameOnChangeRegex as P, storeNameRegex as U } from "../../../../util/regex.js";
|
|
9
|
+
import { T as f } from "../../../../Typography-Du8mj1kr.js";
|
|
10
|
+
import { A } from "../../../../Alert-D1uo0xUN.js";
|
|
11
|
+
import { B as L } from "../../../../Box-Bt8cGqC7.js";
|
|
12
|
+
import { S as h } from "../../../../Stack-Ce-OQAtj.js";
|
|
13
|
+
import { I as x } from "../../../../InputAdornment-HG4f5A6g.js";
|
|
14
|
+
const Y = ({
|
|
13
15
|
showAlertMessage: a,
|
|
14
16
|
loader: m,
|
|
15
|
-
validationError:
|
|
17
|
+
validationError: n,
|
|
16
18
|
registerInfo: t,
|
|
17
|
-
setRegisterInfo:
|
|
18
|
-
dispatch:
|
|
19
|
-
setCurrentStep:
|
|
19
|
+
setRegisterInfo: N,
|
|
20
|
+
dispatch: S,
|
|
21
|
+
setCurrentStep: i
|
|
20
22
|
}) => {
|
|
21
|
-
const [o,
|
|
23
|
+
const [o, g] = c(""), [s, l] = c(""), b = (r) => {
|
|
22
24
|
if (r.preventDefault(), !t.storeName)
|
|
23
25
|
return a({ message: "Please provide store name." }), !1;
|
|
24
26
|
if (!o)
|
|
@@ -27,39 +29,45 @@ const z = ({
|
|
|
27
29
|
return a({
|
|
28
30
|
message: "Store Name & Confirm Store Name doesn't match."
|
|
29
31
|
}), !1;
|
|
30
|
-
|
|
31
|
-
},
|
|
32
|
-
t.storeName &&
|
|
33
|
-
|
|
32
|
+
i(3);
|
|
33
|
+
}, v = () => {
|
|
34
|
+
l(""), t.storeName && U.test(t.storeName) ? S(
|
|
35
|
+
k({
|
|
34
36
|
storename: t.storeName
|
|
35
37
|
})
|
|
38
|
+
) : l(
|
|
39
|
+
"Store name may contain only lowercase letters, numbers, and underscores"
|
|
36
40
|
);
|
|
37
41
|
};
|
|
38
|
-
return /* @__PURE__ */
|
|
39
|
-
/* @__PURE__ */ e(
|
|
40
|
-
/* @__PURE__ */ e(
|
|
41
|
-
/* @__PURE__ */ e(
|
|
42
|
-
/* @__PURE__ */ e(
|
|
42
|
+
return /* @__PURE__ */ d(y, { children: [
|
|
43
|
+
/* @__PURE__ */ e(f, { variant: "lg", fontWeight: "bold", children: "Create a name for your store to activate it." }),
|
|
44
|
+
/* @__PURE__ */ e(f, { variant: "sm", children: "You need to create your Store name, which will be visible to your customers and will appear in the URL link of your e-commerce." }),
|
|
45
|
+
/* @__PURE__ */ e(A, { severity: "info", children: "Please note that you won't be able to change your store name." }),
|
|
46
|
+
/* @__PURE__ */ e(L, { component: "form", onSubmit: b, width: "100%", children: /* @__PURE__ */ d(h, { direction: "column", gap: 2, children: [
|
|
43
47
|
/* @__PURE__ */ e(
|
|
44
|
-
|
|
48
|
+
C,
|
|
45
49
|
{
|
|
50
|
+
suffix: w,
|
|
51
|
+
showInfoIcon: !0,
|
|
52
|
+
tooltipText: T,
|
|
46
53
|
value: t.storeName,
|
|
47
54
|
label: "Store Name",
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
55
|
+
onBlur: v,
|
|
56
|
+
onChange: (r) => {
|
|
57
|
+
P.test(r.target.value) && N((R) => ({
|
|
58
|
+
...R,
|
|
59
|
+
storeName: r.target.value
|
|
60
|
+
}));
|
|
61
|
+
},
|
|
62
|
+
error: !!n || !!s,
|
|
63
|
+
errorText: n || s,
|
|
56
64
|
fullWidth: !0
|
|
57
65
|
}
|
|
58
66
|
),
|
|
59
67
|
/* @__PURE__ */ e(
|
|
60
|
-
|
|
68
|
+
u,
|
|
61
69
|
{
|
|
62
|
-
value: t.storeName,
|
|
70
|
+
value: t.storeName.toLowerCase(),
|
|
63
71
|
label: "Store URL Preview",
|
|
64
72
|
slotProps: {
|
|
65
73
|
input: {
|
|
@@ -67,7 +75,7 @@ const z = ({
|
|
|
67
75
|
padding: 0
|
|
68
76
|
},
|
|
69
77
|
startAdornment: /* @__PURE__ */ e(
|
|
70
|
-
|
|
78
|
+
x,
|
|
71
79
|
{
|
|
72
80
|
sx: {
|
|
73
81
|
backgroundColor: "#f0f0f0",
|
|
@@ -80,7 +88,7 @@ const z = ({
|
|
|
80
88
|
}
|
|
81
89
|
),
|
|
82
90
|
endAdornment: /* @__PURE__ */ e(
|
|
83
|
-
|
|
91
|
+
x,
|
|
84
92
|
{
|
|
85
93
|
sx: {
|
|
86
94
|
backgroundColor: "#f0f0f0",
|
|
@@ -100,29 +108,29 @@ const z = ({
|
|
|
100
108
|
}
|
|
101
109
|
),
|
|
102
110
|
/* @__PURE__ */ e(
|
|
103
|
-
|
|
111
|
+
u,
|
|
104
112
|
{
|
|
105
113
|
value: o,
|
|
106
114
|
label: "Confirm Store Name",
|
|
107
115
|
placeholder: "Confirm Store Name",
|
|
108
|
-
onChange: (r) =>
|
|
116
|
+
onChange: (r) => g(r.target.value),
|
|
109
117
|
fullWidth: !0
|
|
110
118
|
}
|
|
111
119
|
),
|
|
112
120
|
/* @__PURE__ */ e(
|
|
113
|
-
|
|
121
|
+
p,
|
|
114
122
|
{
|
|
115
123
|
type: "submit",
|
|
116
|
-
disabled: !t.storeName || !o || !!
|
|
124
|
+
disabled: !t.storeName || !o || !!n || m,
|
|
117
125
|
isLoading: m,
|
|
118
126
|
children: "Next"
|
|
119
127
|
}
|
|
120
128
|
),
|
|
121
|
-
/* @__PURE__ */ e(
|
|
122
|
-
|
|
129
|
+
/* @__PURE__ */ e(h, { direction: "row", alignItems: "flex-start", children: /* @__PURE__ */ e(
|
|
130
|
+
p,
|
|
123
131
|
{
|
|
124
132
|
isText: !0,
|
|
125
|
-
onClick: () =>
|
|
133
|
+
onClick: () => i(1),
|
|
126
134
|
sx: { fontWeight: 500, padding: 0 },
|
|
127
135
|
customSize: "small",
|
|
128
136
|
children: "Go back and edit"
|
|
@@ -132,5 +140,5 @@ const z = ({
|
|
|
132
140
|
] });
|
|
133
141
|
};
|
|
134
142
|
export {
|
|
135
|
-
|
|
143
|
+
Y as default
|
|
136
144
|
};
|