doct-ui-auth-kit 1.0.26 → 1.0.28
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/doct-ui-auth-kit.css +1 -1
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/use-media-query.d.ts +4 -0
- package/dist/hooks/use-welcome-signup-form.d.ts +2 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1314 -1252
- package/dist/pages/index.d.ts +1 -0
- package/dist/pages/welcome-signup/edit-name-sheet.d.ts +7 -0
- package/dist/pages/welcome-signup/index.d.ts +4 -0
- package/dist/pages/welcome-signup/welcome-signup-page.d.ts +6 -0
- package/dist/pages/welcome-signup/welcome-signup.d.ts +6 -0
- package/dist/pages.js +17 -12
- package/dist/types/auth/auth-types.d.ts +4 -0
- package/dist/types/auth/flow.d.ts +10 -0
- package/dist/types/pages/index.d.ts +1 -0
- package/dist/types/pages/pages.d.ts +27 -0
- package/dist/types/pages/welcome-signup-form.d.ts +23 -0
- package/dist/validations/index.d.ts +1 -1
- package/dist/validations/schemas.d.ts +6 -0
- package/dist/welcome-signup-page-W45qOCrO.js +2228 -0
- package/package.json +1 -1
- package/dist/signup-page-CZ6M5DkH.js +0 -1919
|
@@ -0,0 +1,2228 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as d, jsxs as k, Fragment as _e } from "react/jsx-runtime";
|
|
3
|
+
import { DoctButton as U, DoctTypography as F, DoctOtpInput as rt, DoctCircularProgress as re, DoctPhoneInput as st, DoctLabeledInput as He } from "docthub-core-components";
|
|
4
|
+
import { MdArrowBack as at, MdChevronRight as ct } from "react-icons/md";
|
|
5
|
+
import J, { createContext as ut, useContext as dt, useState as z, useEffect as q, useRef as ie, useId as ft } from "react";
|
|
6
|
+
import { useFormContext as Q, Controller as me, useForm as ye, FormProvider as ve } from "react-hook-form";
|
|
7
|
+
import { z as V } from "zod";
|
|
8
|
+
var ue = { exports: {} }, we = {};
|
|
9
|
+
var De;
|
|
10
|
+
function mt() {
|
|
11
|
+
if (De) return we;
|
|
12
|
+
De = 1;
|
|
13
|
+
var n = J.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
|
|
14
|
+
return we.c = function(e) {
|
|
15
|
+
return n.H.useMemoCache(e);
|
|
16
|
+
}, we;
|
|
17
|
+
}
|
|
18
|
+
var Ee = {};
|
|
19
|
+
var $e;
|
|
20
|
+
function ht() {
|
|
21
|
+
return $e || ($e = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
22
|
+
var n = J.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
|
|
23
|
+
Ee.c = function(e) {
|
|
24
|
+
var t = n.H;
|
|
25
|
+
return t === null && console.error(
|
|
26
|
+
`Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
|
|
27
|
+
1. You might have mismatching versions of React and the renderer (such as React DOM)
|
|
28
|
+
2. You might be breaking the Rules of Hooks
|
|
29
|
+
3. You might have more than one copy of React in the same app
|
|
30
|
+
See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`
|
|
31
|
+
), t.useMemoCache(e);
|
|
32
|
+
};
|
|
33
|
+
})()), Ee;
|
|
34
|
+
}
|
|
35
|
+
var We;
|
|
36
|
+
function gt() {
|
|
37
|
+
return We || (We = 1, process.env.NODE_ENV === "production" ? ue.exports = mt() : ue.exports = ht()), ue.exports;
|
|
38
|
+
}
|
|
39
|
+
var E = gt();
|
|
40
|
+
const qe = "/main-logo.svg", ke = "/docthub.svg", Ke = ["/slider/slide-1.svg", "/slider/slide-2.svg", "/slider/slide-3.svg", "/slider/slide-4.svg", "/slider/slide-5.svg"], pt = 5e3, xe = "[&_main]:!justify-start [&_main]:!pt-5 md:[&_main]:!pt-[104px]";
|
|
41
|
+
function Ne(n) {
|
|
42
|
+
const e = E.c(4), {
|
|
43
|
+
onClick: t,
|
|
44
|
+
ariaLabel: l
|
|
45
|
+
} = n, i = l === void 0 ? "Go back" : l;
|
|
46
|
+
let r;
|
|
47
|
+
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (r = /* @__PURE__ */ d(at, { className: "h-5 w-5 text-neutral-black" }), e[0] = r) : r = e[0];
|
|
48
|
+
let o;
|
|
49
|
+
return e[1] !== i || e[2] !== t ? (o = /* @__PURE__ */ d(U, { icon: r, iconOnly: !0, onClick: t, size: "medium", variant: "outline", "aria-label": i, className: "mb-4 md:mb-6 h-10 w-10" }), e[1] = i, e[2] = t, e[3] = o) : o = e[3], o;
|
|
50
|
+
}
|
|
51
|
+
function bt() {
|
|
52
|
+
const n = typeof window < "u" ? window.location.hostname : "";
|
|
53
|
+
return n.endsWith(".com") || n.includes(".com:") ? "https://www.dochub.com" : "https://dev.dochub.in/";
|
|
54
|
+
}
|
|
55
|
+
function Ye() {
|
|
56
|
+
const n = E.c(4);
|
|
57
|
+
let e;
|
|
58
|
+
n[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (e = bt(), n[0] = e) : e = n[0];
|
|
59
|
+
const t = e;
|
|
60
|
+
let l, i;
|
|
61
|
+
n[1] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */ d("br", {}), i = /* @__PURE__ */ d("a", { href: `${t}/terms-conditions`, className: "font-semibold text-neutral-black underline", children: "Terms of Use" }), n[1] = l, n[2] = i) : (l = n[1], i = n[2]);
|
|
62
|
+
let r;
|
|
63
|
+
return n[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (r = /* @__PURE__ */ k(F, { variant: "body3", align: "center", className: "opacity-60 text-neutral-black", children: [
|
|
64
|
+
"by continuing you agree to Docthub's",
|
|
65
|
+
l,
|
|
66
|
+
i,
|
|
67
|
+
" ",
|
|
68
|
+
"and",
|
|
69
|
+
" ",
|
|
70
|
+
/* @__PURE__ */ d("a", { href: `${t}/privacy-policy`, className: "font-semibold text-neutral-black underline", children: "Privacy Policy." })
|
|
71
|
+
] }), n[3] = r) : r = n[3], r;
|
|
72
|
+
}
|
|
73
|
+
const yt = "https://docthub.com/";
|
|
74
|
+
function vt(n) {
|
|
75
|
+
const e = E.c(8);
|
|
76
|
+
let t;
|
|
77
|
+
e[0] !== n ? (t = n === void 0 ? {} : n, e[0] = n, e[1] = t) : t = e[1];
|
|
78
|
+
const {
|
|
79
|
+
onClick: l,
|
|
80
|
+
href: i
|
|
81
|
+
} = t, r = i === void 0 ? yt : i;
|
|
82
|
+
let o;
|
|
83
|
+
e[2] !== r || e[3] !== l ? (o = () => {
|
|
84
|
+
if (l) {
|
|
85
|
+
l();
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
typeof window < "u" && window.location.assign(r);
|
|
89
|
+
}, e[2] = r, e[3] = l, e[4] = o) : o = e[4];
|
|
90
|
+
const s = o;
|
|
91
|
+
let a;
|
|
92
|
+
e[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ d("div", { className: "flex items-center justify-center p-2 bg-primary rounded-[10px]", children: /* @__PURE__ */ d(ct, { color: "white", className: "h-5 w-5" }) }), e[5] = a) : a = e[5];
|
|
93
|
+
let c;
|
|
94
|
+
return e[6] !== s ? (c = /* @__PURE__ */ d(U, { icon: a, iconPosition: "right", size: "large", variant: "outline", "aria-label": "Go to Enterprise Login", className: "hidden sm:flex items-center gap-4 border border-neutral-12 px-[22px] py-[14px]", onClick: s, children: "Enterprise Login" }), e[6] = s, e[7] = c) : c = e[7], c;
|
|
95
|
+
}
|
|
96
|
+
function Je(n) {
|
|
97
|
+
var e, t, l = "";
|
|
98
|
+
if (typeof n == "string" || typeof n == "number") l += n;
|
|
99
|
+
else if (typeof n == "object") if (Array.isArray(n)) {
|
|
100
|
+
var i = n.length;
|
|
101
|
+
for (e = 0; e < i; e++) n[e] && (t = Je(n[e])) && (l && (l += " "), l += t);
|
|
102
|
+
} else for (t in n) n[t] && (l && (l += " "), l += t);
|
|
103
|
+
return l;
|
|
104
|
+
}
|
|
105
|
+
function M() {
|
|
106
|
+
for (var n, e, t = 0, l = "", i = arguments.length; t < i; t++) (n = arguments[t]) && (e = Je(n)) && (l && (l += " "), l += e);
|
|
107
|
+
return l;
|
|
108
|
+
}
|
|
109
|
+
const Qe = ut(null);
|
|
110
|
+
function Pe() {
|
|
111
|
+
const n = dt(Qe);
|
|
112
|
+
if (!n)
|
|
113
|
+
throw new Error("AuthLayout compound components must be used within AuthLayout.Root");
|
|
114
|
+
return n;
|
|
115
|
+
}
|
|
116
|
+
function xt(n, e) {
|
|
117
|
+
return e === "md" ? "max-w-md" : e === "lg" ? "max-w-lg" : n === "desktop" ? "max-w-[320px]" : "max-w-[360px]";
|
|
118
|
+
}
|
|
119
|
+
function Oe(n = "center") {
|
|
120
|
+
switch (n) {
|
|
121
|
+
case "left":
|
|
122
|
+
return {
|
|
123
|
+
flex: "justify-start",
|
|
124
|
+
text: "text-left"
|
|
125
|
+
};
|
|
126
|
+
case "right":
|
|
127
|
+
return {
|
|
128
|
+
flex: "justify-end",
|
|
129
|
+
text: "text-right"
|
|
130
|
+
};
|
|
131
|
+
default:
|
|
132
|
+
return {
|
|
133
|
+
flex: "justify-center",
|
|
134
|
+
text: "text-center"
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
const Ae = "flex w-full mb-4 md:mb-4";
|
|
139
|
+
function Nt(n) {
|
|
140
|
+
const e = E.c(15), {
|
|
141
|
+
children: t,
|
|
142
|
+
variant: l,
|
|
143
|
+
maxWidth: i,
|
|
144
|
+
className: r
|
|
145
|
+
} = n, o = l === void 0 ? "mobile" : l, s = i === void 0 ? "sm" : i;
|
|
146
|
+
let a;
|
|
147
|
+
e[0] !== s || e[1] !== o ? (a = xt(o, s), e[0] = s, e[1] = o, e[2] = a) : a = e[2];
|
|
148
|
+
const c = a;
|
|
149
|
+
let u;
|
|
150
|
+
e[3] !== s || e[4] !== c || e[5] !== o ? (u = {
|
|
151
|
+
variant: o,
|
|
152
|
+
maxWidth: s,
|
|
153
|
+
maxWidthClass: c
|
|
154
|
+
}, e[3] = s, e[4] = c, e[5] = o, e[6] = u) : u = e[6];
|
|
155
|
+
const h = u;
|
|
156
|
+
let f;
|
|
157
|
+
e[7] !== r ? (f = M("min-h-svh w-full bg-neutral-white flex flex-col", r), e[7] = r, e[8] = f) : f = e[8];
|
|
158
|
+
let m;
|
|
159
|
+
e[9] !== t || e[10] !== f ? (m = /* @__PURE__ */ d("div", { className: f, children: t }), e[9] = t, e[10] = f, e[11] = m) : m = e[11];
|
|
160
|
+
let g;
|
|
161
|
+
return e[12] !== h || e[13] !== m ? (g = /* @__PURE__ */ d(Qe.Provider, { value: h, children: m }), e[12] = h, e[13] = m, e[14] = g) : g = e[14], g;
|
|
162
|
+
}
|
|
163
|
+
function St(n) {
|
|
164
|
+
const e = E.c(12), {
|
|
165
|
+
children: t,
|
|
166
|
+
className: l
|
|
167
|
+
} = n, {
|
|
168
|
+
variant: i
|
|
169
|
+
} = Pe();
|
|
170
|
+
if (i === "desktop") {
|
|
171
|
+
let s;
|
|
172
|
+
e[0] !== l ? (s = M("flex justify-end px-5 pt-5", l), e[0] = l, e[1] = s) : s = e[1];
|
|
173
|
+
let a;
|
|
174
|
+
e[2] !== t ? (a = /* @__PURE__ */ d("div", { className: "w-auto", children: t }), e[2] = t, e[3] = a) : a = e[3];
|
|
175
|
+
let c;
|
|
176
|
+
return e[4] !== s || e[5] !== a ? (c = /* @__PURE__ */ d("div", { className: s, children: a }), e[4] = s, e[5] = a, e[6] = c) : c = e[6], c;
|
|
177
|
+
}
|
|
178
|
+
let r;
|
|
179
|
+
e[7] !== l ? (r = M("mb-4 w-full md:mb-6", l), e[7] = l, e[8] = r) : r = e[8];
|
|
180
|
+
let o;
|
|
181
|
+
return e[9] !== t || e[10] !== r ? (o = /* @__PURE__ */ d("div", { className: r, children: t }), e[9] = t, e[10] = r, e[11] = o) : o = e[11], o;
|
|
182
|
+
}
|
|
183
|
+
function Ct(n) {
|
|
184
|
+
const e = E.c(6), {
|
|
185
|
+
children: t,
|
|
186
|
+
align: l,
|
|
187
|
+
className: i
|
|
188
|
+
} = n, r = l === void 0 ? "center" : l;
|
|
189
|
+
let o;
|
|
190
|
+
if (e[0] !== r || e[1] !== i) {
|
|
191
|
+
const {
|
|
192
|
+
flex: a
|
|
193
|
+
} = Oe(r);
|
|
194
|
+
o = M(Ae, a, i), e[0] = r, e[1] = i, e[2] = o;
|
|
195
|
+
} else
|
|
196
|
+
o = e[2];
|
|
197
|
+
let s;
|
|
198
|
+
return e[3] !== t || e[4] !== o ? (s = /* @__PURE__ */ d("div", { className: o, children: t }), e[3] = t, e[4] = o, e[5] = s) : s = e[5], s;
|
|
199
|
+
}
|
|
200
|
+
function wt(n) {
|
|
201
|
+
const e = E.c(6), {
|
|
202
|
+
children: t,
|
|
203
|
+
align: l,
|
|
204
|
+
className: i
|
|
205
|
+
} = n, r = l === void 0 ? "center" : l;
|
|
206
|
+
let o;
|
|
207
|
+
if (e[0] !== r || e[1] !== i) {
|
|
208
|
+
const {
|
|
209
|
+
flex: a,
|
|
210
|
+
text: c
|
|
211
|
+
} = Oe(r);
|
|
212
|
+
o = M(Ae, a, c, i), e[0] = r, e[1] = i, e[2] = o;
|
|
213
|
+
} else
|
|
214
|
+
o = e[2];
|
|
215
|
+
let s;
|
|
216
|
+
return e[3] !== t || e[4] !== o ? (s = /* @__PURE__ */ d("div", { className: o, children: t }), e[3] = t, e[4] = o, e[5] = s) : s = e[5], s;
|
|
217
|
+
}
|
|
218
|
+
function Et(n) {
|
|
219
|
+
const e = E.c(6), {
|
|
220
|
+
children: t,
|
|
221
|
+
align: l,
|
|
222
|
+
className: i
|
|
223
|
+
} = n, r = l === void 0 ? "center" : l;
|
|
224
|
+
let o;
|
|
225
|
+
if (e[0] !== r || e[1] !== i) {
|
|
226
|
+
const {
|
|
227
|
+
flex: a,
|
|
228
|
+
text: c
|
|
229
|
+
} = Oe(r);
|
|
230
|
+
o = M(Ae, a, c, i), e[0] = r, e[1] = i, e[2] = o;
|
|
231
|
+
} else
|
|
232
|
+
o = e[2];
|
|
233
|
+
let s;
|
|
234
|
+
return e[3] !== t || e[4] !== o ? (s = /* @__PURE__ */ d("div", { className: o, children: t }), e[3] = t, e[4] = o, e[5] = s) : s = e[5], s;
|
|
235
|
+
}
|
|
236
|
+
function _t(n) {
|
|
237
|
+
const e = E.c(5), {
|
|
238
|
+
children: t,
|
|
239
|
+
className: l
|
|
240
|
+
} = n;
|
|
241
|
+
let i;
|
|
242
|
+
e[0] !== l ? (i = M("w-full flex flex-col space-y-4 mb-4 md:mb-6", l), e[0] = l, e[1] = i) : i = e[1];
|
|
243
|
+
let r;
|
|
244
|
+
return e[2] !== t || e[3] !== i ? (r = /* @__PURE__ */ d("div", { className: i, children: t }), e[2] = t, e[3] = i, e[4] = r) : r = e[4], r;
|
|
245
|
+
}
|
|
246
|
+
function kt(n) {
|
|
247
|
+
const e = E.c(10), {
|
|
248
|
+
children: t,
|
|
249
|
+
sm: l,
|
|
250
|
+
className: i
|
|
251
|
+
} = n, {
|
|
252
|
+
maxWidthClass: r
|
|
253
|
+
} = Pe();
|
|
254
|
+
let o;
|
|
255
|
+
e[0] !== i ? (o = M("flex-1 flex flex-col items-center justify-center", "px-5 py-8 md:py-12", "w-full", i), e[0] = i, e[1] = o) : o = e[1];
|
|
256
|
+
const s = l ? "max-w-[320px]" : r;
|
|
257
|
+
let a;
|
|
258
|
+
e[2] !== s ? (a = M("w-full flex flex-col items-center", s), e[2] = s, e[3] = a) : a = e[3];
|
|
259
|
+
let c;
|
|
260
|
+
e[4] !== t || e[5] !== a ? (c = /* @__PURE__ */ d("div", { className: a, children: t }), e[4] = t, e[5] = a, e[6] = c) : c = e[6];
|
|
261
|
+
let u;
|
|
262
|
+
return e[7] !== o || e[8] !== c ? (u = /* @__PURE__ */ d("main", { className: o, children: c }), e[7] = o, e[8] = c, e[9] = u) : u = e[9], u;
|
|
263
|
+
}
|
|
264
|
+
function Pt(n) {
|
|
265
|
+
const e = E.c(10), {
|
|
266
|
+
children: t,
|
|
267
|
+
className: l
|
|
268
|
+
} = n, {
|
|
269
|
+
maxWidthClass: i
|
|
270
|
+
} = Pe();
|
|
271
|
+
let r;
|
|
272
|
+
e[0] !== l ? (r = M("px-5 py-6 md:py-8 w-full flex justify-center", l), e[0] = l, e[1] = r) : r = e[1];
|
|
273
|
+
let o;
|
|
274
|
+
e[2] !== i ? (o = M("w-full text-center", i), e[2] = i, e[3] = o) : o = e[3];
|
|
275
|
+
let s;
|
|
276
|
+
e[4] !== t || e[5] !== o ? (s = /* @__PURE__ */ d("div", { className: o, children: t }), e[4] = t, e[5] = o, e[6] = s) : s = e[6];
|
|
277
|
+
let a;
|
|
278
|
+
return e[7] !== r || e[8] !== s ? (a = /* @__PURE__ */ d("footer", { className: r, children: s }), e[7] = r, e[8] = s, e[9] = a) : a = e[9], a;
|
|
279
|
+
}
|
|
280
|
+
const Y = {
|
|
281
|
+
Root: Nt,
|
|
282
|
+
Header: St,
|
|
283
|
+
Main: kt,
|
|
284
|
+
Logo: Ct,
|
|
285
|
+
Title: wt,
|
|
286
|
+
Description: Et,
|
|
287
|
+
Body: _t,
|
|
288
|
+
Footer: Pt
|
|
289
|
+
};
|
|
290
|
+
function Ot(n) {
|
|
291
|
+
const e = E.c(38), {
|
|
292
|
+
images: t,
|
|
293
|
+
autoPlayInterval: l,
|
|
294
|
+
className: i,
|
|
295
|
+
hideIndicators: r,
|
|
296
|
+
onSlideChange: o,
|
|
297
|
+
activeIndex: s,
|
|
298
|
+
onNavigate: a
|
|
299
|
+
} = n, c = l === void 0 ? 5e3 : l, [u, h] = z(0), f = s !== void 0, m = f ? s : u;
|
|
300
|
+
let g, b;
|
|
301
|
+
e[0] !== c || e[1] !== m || e[2] !== t.length || e[3] !== f || e[4] !== o ? (g = () => {
|
|
302
|
+
if (c > 0 && t.length > 1) {
|
|
303
|
+
const O = setInterval(() => {
|
|
304
|
+
const L = (m + 1) % t.length;
|
|
305
|
+
f || h(L), o?.(L);
|
|
306
|
+
}, c);
|
|
307
|
+
return () => clearInterval(O);
|
|
308
|
+
}
|
|
309
|
+
}, b = [c, t.length, m, f, o], e[0] = c, e[1] = m, e[2] = t.length, e[3] = f, e[4] = o, e[5] = g, e[6] = b) : (g = e[5], b = e[6]), q(g, b);
|
|
310
|
+
let p, y;
|
|
311
|
+
e[7] !== t.length || e[8] !== f || e[9] !== o ? (p = () => {
|
|
312
|
+
!f && t.length > 0 && o?.(0);
|
|
313
|
+
}, y = [t.length, f, o], e[7] = t.length, e[8] = f, e[9] = o, e[10] = p, e[11] = y) : (p = e[10], y = e[11]), q(p, y);
|
|
314
|
+
let x;
|
|
315
|
+
e[12] !== f || e[13] !== a || e[14] !== o ? (x = (O) => {
|
|
316
|
+
f ? (a?.(O), o?.(O)) : (h(O), o?.(O));
|
|
317
|
+
}, e[12] = f, e[13] = a, e[14] = o, e[15] = x) : x = e[15];
|
|
318
|
+
const v = x;
|
|
319
|
+
if (t.length === 0)
|
|
320
|
+
return null;
|
|
321
|
+
const C = t.length;
|
|
322
|
+
let N;
|
|
323
|
+
e[16] !== i ? (N = M("relative w-full h-full min-h-0", i), e[16] = i, e[17] = N) : N = e[17];
|
|
324
|
+
const S = `${C * 100}%`, _ = `translateX(-${m * 100 / C}%)`;
|
|
325
|
+
let w;
|
|
326
|
+
e[18] !== S || e[19] !== _ ? (w = {
|
|
327
|
+
width: S,
|
|
328
|
+
transform: _
|
|
329
|
+
}, e[18] = S, e[19] = _, e[20] = w) : w = e[20];
|
|
330
|
+
let P;
|
|
331
|
+
if (e[21] !== t || e[22] !== C) {
|
|
332
|
+
let O;
|
|
333
|
+
e[24] !== C ? (O = (L, R) => /* @__PURE__ */ d("div", { className: "relative flex-shrink-0 h-full", style: {
|
|
334
|
+
width: `${100 / C}%`
|
|
335
|
+
}, children: /* @__PURE__ */ d("img", { src: L, alt: `Slide ${R + 1}`, className: "h-full w-full object-cover object-center" }) }, `${L}-${R}`), e[24] = C, e[25] = O) : O = e[25], P = t.map(O), e[21] = t, e[22] = C, e[23] = P;
|
|
336
|
+
} else
|
|
337
|
+
P = e[23];
|
|
338
|
+
let A;
|
|
339
|
+
e[26] !== w || e[27] !== P ? (A = /* @__PURE__ */ d("div", { className: "relative w-full h-full overflow-hidden", children: /* @__PURE__ */ d("div", { className: "flex h-full transition-transform duration-500 ease-in-out", style: w, children: P }) }), e[26] = w, e[27] = P, e[28] = A) : A = e[28];
|
|
340
|
+
let I;
|
|
341
|
+
e[29] !== m || e[30] !== v || e[31] !== r || e[32] !== t ? (I = t.length > 1 && !r && /* @__PURE__ */ d("div", { className: "absolute -top-10 left-1/2 flex -translate-x-1/2 gap-2 z-20", children: t.map((O, L) => /* @__PURE__ */ d("button", { type: "button", onClick: () => v(L), className: M("h-1 rounded-[3px] transition-all duration-300", L === m ? "w-8 bg-neutral-white" : "w-2 bg-neutral-white/40"), "aria-label": `Go to slide ${L + 1}` }, `indicator-${O}-${L}`)) }), e[29] = m, e[30] = v, e[31] = r, e[32] = t, e[33] = I) : I = e[33];
|
|
342
|
+
let $;
|
|
343
|
+
return e[34] !== A || e[35] !== I || e[36] !== N ? ($ = /* @__PURE__ */ k("div", { className: N, children: [
|
|
344
|
+
A,
|
|
345
|
+
I
|
|
346
|
+
] }), e[34] = A, e[35] = I, e[36] = N, e[37] = $) : $ = e[37], $;
|
|
347
|
+
}
|
|
348
|
+
function At(n) {
|
|
349
|
+
const e = E.c(15), {
|
|
350
|
+
sliderImages: t,
|
|
351
|
+
sliderAutoPlayInterval: l,
|
|
352
|
+
activeSlideIndex: i,
|
|
353
|
+
onSlideChange: r,
|
|
354
|
+
ctaText: o,
|
|
355
|
+
sliderTitles: s,
|
|
356
|
+
className: a
|
|
357
|
+
} = n, c = s?.[i];
|
|
358
|
+
let u = o ?? null;
|
|
359
|
+
if (c != null) {
|
|
360
|
+
let b;
|
|
361
|
+
e[0] !== c ? (b = typeof c == "string" ? /* @__PURE__ */ d(F, { variant: "h6", weight: "medium", align: "center", className: "whitespace-pre-line text-primary-170", children: c }) : c, e[0] = c, e[1] = b) : b = e[1], u = b;
|
|
362
|
+
}
|
|
363
|
+
let h;
|
|
364
|
+
e[2] !== a ? (h = M("relative w-full h-[100dvh] transition-colors duration-500", a), e[2] = a, e[3] = h) : h = e[3];
|
|
365
|
+
let f;
|
|
366
|
+
e[4] !== u ? (f = u != null && /* @__PURE__ */ d("div", { className: M("absolute left-1/2 top-[152.5px] z-10 flex w-[328px] -translate-x-1/2 items-center justify-center text-center transition-opacity duration-300"), children: u }), e[4] = u, e[5] = f) : f = e[5];
|
|
367
|
+
let m;
|
|
368
|
+
e[6] !== i || e[7] !== r || e[8] !== l || e[9] !== t ? (m = /* @__PURE__ */ d("div", { className: "absolute inset-0", children: t.length > 0 ? /* @__PURE__ */ d(Ot, { images: t, autoPlayInterval: l, className: "h-full w-full", hideIndicators: !0, activeIndex: i, onSlideChange: r, onNavigate: r }) : /* @__PURE__ */ d("div", { className: "flex h-full w-full items-center justify-center bg-neutral-white/50 p-8", children: /* @__PURE__ */ d(F, { variant: "h6", weight: "medium", align: "center", className: "opacity-40 text-primary-170", children: "No slides configured" }) }) }), e[6] = i, e[7] = r, e[8] = l, e[9] = t, e[10] = m) : m = e[10];
|
|
369
|
+
let g;
|
|
370
|
+
return e[11] !== h || e[12] !== f || e[13] !== m ? (g = /* @__PURE__ */ k("div", { className: h, children: [
|
|
371
|
+
f,
|
|
372
|
+
m
|
|
373
|
+
] }), e[11] = h, e[12] = f, e[13] = m, e[14] = g) : g = e[14], g;
|
|
374
|
+
}
|
|
375
|
+
function Lt(n) {
|
|
376
|
+
const e = E.c(23), {
|
|
377
|
+
sliderImages: t,
|
|
378
|
+
sliderAutoPlayInterval: l,
|
|
379
|
+
ctaText: i,
|
|
380
|
+
sliderTitles: r,
|
|
381
|
+
className: o,
|
|
382
|
+
marketingClassName: s,
|
|
383
|
+
contentClassName: a,
|
|
384
|
+
children: c
|
|
385
|
+
} = n, u = l === void 0 ? 5e3 : l, [h, f] = z(0), m = t ?? Ke;
|
|
386
|
+
let g;
|
|
387
|
+
e[0] !== o ? (g = M("min-h-svh w-full flex flex-1 flex-col bg-neutral-white transition-colors duration-500", o), e[0] = o, e[1] = g) : g = e[1];
|
|
388
|
+
let b;
|
|
389
|
+
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (b = {
|
|
390
|
+
width: "calc(100dvh * 432 / 731)"
|
|
391
|
+
}, e[2] = b) : b = e[2];
|
|
392
|
+
let p;
|
|
393
|
+
e[3] !== s ? (p = s && {
|
|
394
|
+
className: s
|
|
395
|
+
}, e[3] = s, e[4] = p) : p = e[4];
|
|
396
|
+
let y;
|
|
397
|
+
e[5] !== h || e[6] !== i || e[7] !== m || e[8] !== u || e[9] !== r || e[10] !== p ? (y = /* @__PURE__ */ d("div", { className: "hidden lg:block lg:h-[100dvh] lg:flex-shrink-0 lg:flex-grow-0", style: b, children: /* @__PURE__ */ d(At, { sliderImages: m, sliderAutoPlayInterval: u, activeSlideIndex: h, onSlideChange: f, ctaText: i, sliderTitles: r, ...p }) }), e[5] = h, e[6] = i, e[7] = m, e[8] = u, e[9] = r, e[10] = p, e[11] = y) : y = e[11];
|
|
398
|
+
let x;
|
|
399
|
+
e[12] !== a ? (x = M("flex-1 min-w-0 flex flex-col overflow-x-hidden", a), e[12] = a, e[13] = x) : x = e[13];
|
|
400
|
+
let v;
|
|
401
|
+
e[14] !== c || e[15] !== x ? (v = /* @__PURE__ */ d("div", { className: x, children: c }), e[14] = c, e[15] = x, e[16] = v) : v = e[16];
|
|
402
|
+
let C;
|
|
403
|
+
e[17] !== y || e[18] !== v ? (C = /* @__PURE__ */ k("div", { className: "flex w-full h-full min-h-svh flex-col lg:flex-row", children: [
|
|
404
|
+
y,
|
|
405
|
+
v
|
|
406
|
+
] }), e[17] = y, e[18] = v, e[19] = C) : C = e[19];
|
|
407
|
+
let N;
|
|
408
|
+
return e[20] !== g || e[21] !== C ? (N = /* @__PURE__ */ d("div", { className: g, children: C }), e[20] = g, e[21] = C, e[22] = N) : N = e[22], N;
|
|
409
|
+
}
|
|
410
|
+
function X(n) {
|
|
411
|
+
const e = E.c(58), {
|
|
412
|
+
children: t,
|
|
413
|
+
layoutType: l,
|
|
414
|
+
logo: i,
|
|
415
|
+
title: r,
|
|
416
|
+
description: o,
|
|
417
|
+
footer: s,
|
|
418
|
+
header: a,
|
|
419
|
+
onBack: c,
|
|
420
|
+
backButton: u,
|
|
421
|
+
sliderImages: h,
|
|
422
|
+
sliderAutoPlayInterval: f,
|
|
423
|
+
sliderTitles: m,
|
|
424
|
+
variant: g,
|
|
425
|
+
maxWidth: b,
|
|
426
|
+
contentWidth: p,
|
|
427
|
+
align: y,
|
|
428
|
+
className: x
|
|
429
|
+
} = n, v = l === void 0 ? "withSlider" : l, C = h === void 0 ? Ke : h, N = f === void 0 ? pt : f, S = b === void 0 ? "sm" : b, _ = p === void 0 ? "default" : p, w = y === void 0 ? "center" : y, P = _ === "sm", A = g ?? (v === "withSlider" ? "desktop" : "mobile");
|
|
430
|
+
let I;
|
|
431
|
+
e[0] !== u || e[1] !== i || e[2] !== c ? (I = () => u ?? (c != null ? /* @__PURE__ */ d(Ne, { onClick: c }) : i ? typeof i == "string" ? /* @__PURE__ */ d("div", { className: "h-[30px] w-[140px]", children: /* @__PURE__ */ d("img", { src: i, alt: "Docthub", className: "block h-full w-full object-cover" }) }) : i : null), e[0] = u, e[1] = i, e[2] = c, e[3] = I) : I = e[3];
|
|
432
|
+
const $ = I;
|
|
433
|
+
let O;
|
|
434
|
+
e[4] !== w || e[5] !== r ? (O = () => r ? typeof r == "string" ? /* @__PURE__ */ d(F, { variant: "h5", weight: "extraBold", align: w, className: "text-neutral-black", children: r }) : r : null, e[4] = w, e[5] = r, e[6] = O) : O = e[6];
|
|
435
|
+
const L = O;
|
|
436
|
+
let R;
|
|
437
|
+
e[7] !== w || e[8] !== o ? (R = () => o ? typeof o == "string" ? /* @__PURE__ */ d(F, { variant: "body1", align: w, className: "text-neutral-black", children: o }) : o : null, e[7] = w, e[8] = o, e[9] = R) : R = e[9];
|
|
438
|
+
const W = R;
|
|
439
|
+
let T;
|
|
440
|
+
e[10] !== a ? (T = a && /* @__PURE__ */ d(Y.Header, { children: a }), e[10] = a, e[11] = T) : T = e[11];
|
|
441
|
+
let D;
|
|
442
|
+
e[12] !== $ ? (D = $(), e[12] = $, e[13] = D) : D = e[13];
|
|
443
|
+
let B;
|
|
444
|
+
e[14] !== w || e[15] !== D ? (B = /* @__PURE__ */ d(Y.Logo, { align: w, children: D }), e[14] = w, e[15] = D, e[16] = B) : B = e[16];
|
|
445
|
+
let G;
|
|
446
|
+
e[17] !== w || e[18] !== L || e[19] !== r ? (G = r && /* @__PURE__ */ d(Y.Title, { align: w, children: L() }), e[17] = w, e[18] = L, e[19] = r, e[20] = G) : G = e[20];
|
|
447
|
+
let K;
|
|
448
|
+
e[21] !== w || e[22] !== o || e[23] !== W ? (K = o && /* @__PURE__ */ d(Y.Description, { align: w, children: W() }), e[21] = w, e[22] = o, e[23] = W, e[24] = K) : K = e[24];
|
|
449
|
+
let j;
|
|
450
|
+
e[25] !== t ? (j = /* @__PURE__ */ d(Y.Body, { children: t }), e[25] = t, e[26] = j) : j = e[26];
|
|
451
|
+
let H;
|
|
452
|
+
e[27] !== B || e[28] !== G || e[29] !== K || e[30] !== j || e[31] !== P ? (H = /* @__PURE__ */ k(Y.Main, { sm: P, children: [
|
|
453
|
+
B,
|
|
454
|
+
G,
|
|
455
|
+
K,
|
|
456
|
+
j
|
|
457
|
+
] }), e[27] = B, e[28] = G, e[29] = K, e[30] = j, e[31] = P, e[32] = H) : H = e[32];
|
|
458
|
+
let Z;
|
|
459
|
+
e[33] !== s ? (Z = s && /* @__PURE__ */ d(Y.Footer, { children: s }), e[33] = s, e[34] = Z) : Z = e[34];
|
|
460
|
+
let se;
|
|
461
|
+
e[35] !== T || e[36] !== H || e[37] !== Z ? (se = /* @__PURE__ */ k(_e, { children: [
|
|
462
|
+
T,
|
|
463
|
+
H,
|
|
464
|
+
Z
|
|
465
|
+
] }), e[35] = T, e[36] = H, e[37] = Z, e[38] = se) : se = e[38];
|
|
466
|
+
const ee = se;
|
|
467
|
+
if (v === "withSlider") {
|
|
468
|
+
let ne;
|
|
469
|
+
e[39] !== x ? (ne = x && {
|
|
470
|
+
className: x
|
|
471
|
+
}, e[39] = x, e[40] = ne) : ne = e[40];
|
|
472
|
+
let le;
|
|
473
|
+
e[41] !== ee || e[42] !== S || e[43] !== A ? (le = /* @__PURE__ */ d(Y.Root, { variant: A, maxWidth: S, className: "bg-transparent", children: ee }), e[41] = ee, e[42] = S, e[43] = A, e[44] = le) : le = e[44];
|
|
474
|
+
let ce;
|
|
475
|
+
return e[45] !== N || e[46] !== C || e[47] !== m || e[48] !== ne || e[49] !== le ? (ce = /* @__PURE__ */ d(Lt, { sliderImages: C, sliderAutoPlayInterval: N, sliderTitles: m, ...ne, children: le }), e[45] = N, e[46] = C, e[47] = m, e[48] = ne, e[49] = le, e[50] = ce) : ce = e[50], ce;
|
|
476
|
+
}
|
|
477
|
+
let te;
|
|
478
|
+
e[51] !== x ? (te = x && {
|
|
479
|
+
className: x
|
|
480
|
+
}, e[51] = x, e[52] = te) : te = e[52];
|
|
481
|
+
let ae;
|
|
482
|
+
return e[53] !== ee || e[54] !== S || e[55] !== A || e[56] !== te ? (ae = /* @__PURE__ */ d(Y.Root, { variant: A, maxWidth: S, ...te, children: ee }), e[53] = ee, e[54] = S, e[55] = A, e[56] = te, e[57] = ae) : ae = e[57], ae;
|
|
483
|
+
}
|
|
484
|
+
function Tt(n) {
|
|
485
|
+
return {
|
|
486
|
+
triggerSignIn() {
|
|
487
|
+
}
|
|
488
|
+
};
|
|
489
|
+
}
|
|
490
|
+
const Me = "https://accounts.google.com/gsi/client";
|
|
491
|
+
function Ft() {
|
|
492
|
+
return typeof window > "u" ? Promise.reject(new Error("GSI requires browser")) : window.google?.accounts?.id ? Promise.resolve() : new Promise((n, e) => {
|
|
493
|
+
if (document.querySelector(`script[src="${Me}"]`)) {
|
|
494
|
+
const i = () => window.google?.accounts?.id ? n() : setTimeout(i, 50);
|
|
495
|
+
i();
|
|
496
|
+
return;
|
|
497
|
+
}
|
|
498
|
+
const l = document.createElement("script");
|
|
499
|
+
l.src = Me, l.async = !0, l.defer = !0, l.onload = () => n(), l.onerror = () => e(new Error("Failed to load Google Identity Services script")), document.body.appendChild(l);
|
|
500
|
+
});
|
|
501
|
+
}
|
|
502
|
+
const It = "openid email profile", je = 2e3;
|
|
503
|
+
function Rt(n) {
|
|
504
|
+
const e = E.c(18), {
|
|
505
|
+
clientId: t,
|
|
506
|
+
onCredential: l,
|
|
507
|
+
enableOneTap: i
|
|
508
|
+
} = n, r = i === void 0 ? !1 : i, o = ie(!1), s = ie(null), a = ie(l), c = ie(0), u = ie(!1);
|
|
509
|
+
let h, f;
|
|
510
|
+
e[0] !== l ? (h = () => {
|
|
511
|
+
a.current = l;
|
|
512
|
+
}, f = [l], e[0] = l, e[1] = h, e[2] = f) : (h = e[1], f = e[2]), q(h, f);
|
|
513
|
+
let m;
|
|
514
|
+
e[3] !== t ? (m = async () => {
|
|
515
|
+
t && (await Ft(), !(!window.google?.accounts?.id || !window.google?.accounts?.oauth2) && (o.current || (window.google.accounts.id.initialize({
|
|
516
|
+
client_id: t,
|
|
517
|
+
callback: (S) => {
|
|
518
|
+
a.current(S.credential);
|
|
519
|
+
},
|
|
520
|
+
auto_select: !1
|
|
521
|
+
}), s.current = window.google.accounts.oauth2.initCodeClient({
|
|
522
|
+
client_id: t,
|
|
523
|
+
scope: It,
|
|
524
|
+
ux_mode: "popup",
|
|
525
|
+
callback: (S) => {
|
|
526
|
+
a.current(S.code);
|
|
527
|
+
},
|
|
528
|
+
error_callback: Dt
|
|
529
|
+
}), o.current = !0)));
|
|
530
|
+
}, e[3] = t, e[4] = m) : m = e[4];
|
|
531
|
+
const g = m;
|
|
532
|
+
let b;
|
|
533
|
+
e[5] !== t ? (b = async () => {
|
|
534
|
+
if (!t)
|
|
535
|
+
return;
|
|
536
|
+
const S = Date.now();
|
|
537
|
+
S - c.current < je || (c.current = S, s.current?.requestCode());
|
|
538
|
+
}, e[5] = t, e[6] = b) : b = e[6];
|
|
539
|
+
const p = b;
|
|
540
|
+
let y, x;
|
|
541
|
+
e[7] !== t || e[8] !== g ? (y = () => {
|
|
542
|
+
t && g();
|
|
543
|
+
}, x = [t, g], e[7] = t, e[8] = g, e[9] = y, e[10] = x) : (y = e[9], x = e[10]), q(y, x);
|
|
544
|
+
let v, C;
|
|
545
|
+
e[11] !== t || e[12] !== r || e[13] !== g ? (v = () => {
|
|
546
|
+
!r || !t || u.current || (u.current = !0, g().then(() => {
|
|
547
|
+
if (!window.google?.accounts?.id)
|
|
548
|
+
return;
|
|
549
|
+
const S = Date.now();
|
|
550
|
+
S - c.current < je || (c.current = S, window.google.accounts.id.prompt());
|
|
551
|
+
}));
|
|
552
|
+
}, C = [r, t, g], e[11] = t, e[12] = r, e[13] = g, e[14] = v, e[15] = C) : (v = e[14], C = e[15]), q(v, C);
|
|
553
|
+
let N;
|
|
554
|
+
return e[16] !== p ? (N = {
|
|
555
|
+
loginWithGoogle: p
|
|
556
|
+
}, e[16] = p, e[17] = N) : N = e[17], N;
|
|
557
|
+
}
|
|
558
|
+
function Dt() {
|
|
559
|
+
}
|
|
560
|
+
function $t(n) {
|
|
561
|
+
const e = E.c(10), {
|
|
562
|
+
name: t,
|
|
563
|
+
label: l,
|
|
564
|
+
className: i,
|
|
565
|
+
control: r,
|
|
566
|
+
length: o,
|
|
567
|
+
inputClassName: s,
|
|
568
|
+
autoFocus: a
|
|
569
|
+
} = n, c = o === void 0 ? 6 : o, u = Q(), h = r || u.control;
|
|
570
|
+
let f;
|
|
571
|
+
e[0] !== a || e[1] !== i || e[2] !== s || e[3] !== l || e[4] !== c ? (f = (g) => {
|
|
572
|
+
const {
|
|
573
|
+
field: b,
|
|
574
|
+
fieldState: p
|
|
575
|
+
} = g;
|
|
576
|
+
return /* @__PURE__ */ k("div", { children: [
|
|
577
|
+
l && /* @__PURE__ */ d("label", { className: "block mb-1", children: l }),
|
|
578
|
+
/* @__PURE__ */ d(rt, { length: c, value: b.value || [], onChange: b.onChange, ...a !== void 0 && {
|
|
579
|
+
autoFocus: a
|
|
580
|
+
}, ...i && {
|
|
581
|
+
className: i
|
|
582
|
+
}, ...s && {
|
|
583
|
+
inputClassName: s
|
|
584
|
+
}, ...p.error?.message !== void 0 && p.error?.message !== "" && {
|
|
585
|
+
error: p.error.message
|
|
586
|
+
} })
|
|
587
|
+
] });
|
|
588
|
+
}, e[0] = a, e[1] = i, e[2] = s, e[3] = l, e[4] = c, e[5] = f) : f = e[5];
|
|
589
|
+
let m;
|
|
590
|
+
return e[6] !== t || e[7] !== h || e[8] !== f ? (m = /* @__PURE__ */ d(me, { name: t, control: h, render: f }), e[6] = t, e[7] = h, e[8] = f, e[9] = m) : m = e[9], m;
|
|
591
|
+
}
|
|
592
|
+
function Wt(n) {
|
|
593
|
+
return n.trim().replace(/\b\w/g, (e) => e.toUpperCase());
|
|
594
|
+
}
|
|
595
|
+
const oe = V.string().trim().min(1, "Full name is required").refine((n) => n == null || n.length === 0 ? !0 : n.length >= 3, "Full name must be at least 3 characters").transform(Wt), Se = V.string().trim().min(1, "Phone number is required").refine((n) => {
|
|
596
|
+
if (n == null || n.length === 0) return !0;
|
|
597
|
+
const [, e] = n.split("-"), l = (e ?? n).replaceAll(/\D/g, "");
|
|
598
|
+
return l.length >= 7 && l.length <= 15;
|
|
599
|
+
}, "Phone number must be between 7 and 15 digits"), Ce = V.string().trim().transform((n) => n.replaceAll(/\D/g, "")).optional(), Le = V.string().trim().min(1, "Email is required").refine((n) => n == null || n.length === 0 ? !0 : V.string().email().safeParse(n).success, "Enter a valid email address").transform((n) => n.toLowerCase()), Mt = V.object({
|
|
600
|
+
fullName: oe,
|
|
601
|
+
phone: Se,
|
|
602
|
+
countryCode: Ce
|
|
603
|
+
}), jt = V.object({
|
|
604
|
+
fullName: oe,
|
|
605
|
+
email: Le
|
|
606
|
+
}), Ut = V.object({
|
|
607
|
+
fullName: oe,
|
|
608
|
+
email: Le,
|
|
609
|
+
phone: Se,
|
|
610
|
+
countryCode: Ce
|
|
611
|
+
}), Ue = {
|
|
612
|
+
phone: Mt,
|
|
613
|
+
email: jt,
|
|
614
|
+
foreign: Ut
|
|
615
|
+
}, zt = V.object({
|
|
616
|
+
fullName: oe,
|
|
617
|
+
phone: Se,
|
|
618
|
+
countryCode: Ce
|
|
619
|
+
}), Bt = V.object({
|
|
620
|
+
phone: Se,
|
|
621
|
+
countryCode: Ce
|
|
622
|
+
}), Vt = V.object({
|
|
623
|
+
email: Le
|
|
624
|
+
}), ze = {
|
|
625
|
+
phone: Bt,
|
|
626
|
+
email: Vt
|
|
627
|
+
}, he = 6, Gt = 60, Ht = 120;
|
|
628
|
+
function qt(n) {
|
|
629
|
+
return n === "phone" ? Gt : Ht;
|
|
630
|
+
}
|
|
631
|
+
const Xe = V.object({
|
|
632
|
+
otp: V.array(V.string()).length(he, "Enter all 6 digits").refine((n) => n.every((e) => /^\d$/.test(e)) && n.join("").length === he, "Invalid OTP! Please use correct code and submit again.")
|
|
633
|
+
}), Kt = {
|
|
634
|
+
phone: "Kindly check your Mobile.",
|
|
635
|
+
email: "Kindly check your Email Inbox."
|
|
636
|
+
}, Yt = {
|
|
637
|
+
phone: "6 digit OTP has been sent to your Mobile",
|
|
638
|
+
email: "6 digit OTP has been sent to your Email"
|
|
639
|
+
};
|
|
640
|
+
function Jt(n) {
|
|
641
|
+
const e = E.c(30), {
|
|
642
|
+
mode: t,
|
|
643
|
+
onSubmit: l,
|
|
644
|
+
onResendCode: i,
|
|
645
|
+
submitApi: r,
|
|
646
|
+
onSuccess: o,
|
|
647
|
+
onError: s,
|
|
648
|
+
validate: a
|
|
649
|
+
} = n, [c, u] = z(!1);
|
|
650
|
+
let h;
|
|
651
|
+
e[0] !== t ? (h = qt(t), e[0] = t, e[1] = h) : h = e[1];
|
|
652
|
+
const f = h, [m, g] = z(f), b = m <= 0;
|
|
653
|
+
let p;
|
|
654
|
+
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (p = Array.from({
|
|
655
|
+
length: he
|
|
656
|
+
}, Zt), e[2] = p) : p = e[2];
|
|
657
|
+
const y = p;
|
|
658
|
+
let x;
|
|
659
|
+
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (x = {
|
|
660
|
+
defaultValues: {
|
|
661
|
+
otp: y
|
|
662
|
+
},
|
|
663
|
+
mode: "onChange"
|
|
664
|
+
}, e[3] = x) : x = e[3];
|
|
665
|
+
const v = ye(x);
|
|
666
|
+
let C, N;
|
|
667
|
+
e[4] !== m ? (C = () => {
|
|
668
|
+
if (m <= 0)
|
|
669
|
+
return;
|
|
670
|
+
const B = setInterval(() => {
|
|
671
|
+
g(Xt);
|
|
672
|
+
}, 1e3);
|
|
673
|
+
return () => clearInterval(B);
|
|
674
|
+
}, N = [m], e[4] = m, e[5] = C, e[6] = N) : (C = e[5], N = e[6]), q(C, N);
|
|
675
|
+
let S;
|
|
676
|
+
e[7] !== v || e[8] !== s || e[9] !== l || e[10] !== o || e[11] !== r || e[12] !== a ? (S = async (B) => {
|
|
677
|
+
v.clearErrors("otp");
|
|
678
|
+
const G = Xe.safeParse(B);
|
|
679
|
+
if (!G.success) {
|
|
680
|
+
const j = G.error.issues[0]?.message ?? "Invalid OTP";
|
|
681
|
+
v.setError("otp", {
|
|
682
|
+
message: j
|
|
683
|
+
});
|
|
684
|
+
return;
|
|
685
|
+
}
|
|
686
|
+
const K = G.data.otp.join("");
|
|
687
|
+
if (a) {
|
|
688
|
+
u(!0);
|
|
689
|
+
try {
|
|
690
|
+
const j = await a(K);
|
|
691
|
+
if (j !== !0) {
|
|
692
|
+
v.setError("otp", {
|
|
693
|
+
type: "validate",
|
|
694
|
+
message: j
|
|
695
|
+
}), u(!1);
|
|
696
|
+
return;
|
|
697
|
+
}
|
|
698
|
+
} catch (j) {
|
|
699
|
+
s?.(j), u(!1);
|
|
700
|
+
return;
|
|
701
|
+
}
|
|
702
|
+
r || u(!1);
|
|
703
|
+
}
|
|
704
|
+
if (r) {
|
|
705
|
+
u(!0), r(K).then(() => {
|
|
706
|
+
o?.();
|
|
707
|
+
}).catch((j) => {
|
|
708
|
+
const H = j?.message;
|
|
709
|
+
v.setError("otp", {
|
|
710
|
+
type: "submit",
|
|
711
|
+
message: typeof H == "string" && H.length > 0 ? H : "OTP verification failed"
|
|
712
|
+
}), s?.(j);
|
|
713
|
+
}).finally(() => {
|
|
714
|
+
u(!1);
|
|
715
|
+
});
|
|
716
|
+
return;
|
|
717
|
+
}
|
|
718
|
+
l?.(K);
|
|
719
|
+
}, e[7] = v, e[8] = s, e[9] = l, e[10] = o, e[11] = r, e[12] = a, e[13] = S) : S = e[13];
|
|
720
|
+
const _ = S;
|
|
721
|
+
let w;
|
|
722
|
+
e[14] !== b || e[15] !== f || e[16] !== i ? (w = () => {
|
|
723
|
+
b && (i?.(), g(f));
|
|
724
|
+
}, e[14] = b, e[15] = f, e[16] = i, e[17] = w) : w = e[17];
|
|
725
|
+
const P = w, A = Qt, I = Math.floor(m / 60), $ = m % 60, O = String(I);
|
|
726
|
+
let L;
|
|
727
|
+
e[18] !== O ? (L = O.padStart(2, "0"), e[18] = O, e[19] = L) : L = e[19];
|
|
728
|
+
const R = String($);
|
|
729
|
+
let W;
|
|
730
|
+
e[20] !== R ? (W = R.padStart(2, "0"), e[20] = R, e[21] = W) : W = e[21];
|
|
731
|
+
const T = `Resend code in: ${L}:${W}`;
|
|
732
|
+
let D;
|
|
733
|
+
return e[22] !== b || e[23] !== P || e[24] !== _ || e[25] !== c || e[26] !== v || e[27] !== m || e[28] !== T ? (D = {
|
|
734
|
+
methods: v,
|
|
735
|
+
handleSubmit: _,
|
|
736
|
+
isFormValid: A,
|
|
737
|
+
handleResend: P,
|
|
738
|
+
resendSecondsLeft: m,
|
|
739
|
+
canResend: b,
|
|
740
|
+
timerText: T,
|
|
741
|
+
isSubmitting: c
|
|
742
|
+
}, e[22] = b, e[23] = P, e[24] = _, e[25] = c, e[26] = v, e[27] = m, e[28] = T, e[29] = D) : D = e[29], D;
|
|
743
|
+
}
|
|
744
|
+
function Qt(n) {
|
|
745
|
+
return Xe.safeParse(n).success;
|
|
746
|
+
}
|
|
747
|
+
function Xt(n) {
|
|
748
|
+
return n <= 1 ? 0 : n - 1;
|
|
749
|
+
}
|
|
750
|
+
function Zt() {
|
|
751
|
+
return "";
|
|
752
|
+
}
|
|
753
|
+
function en(n) {
|
|
754
|
+
const e = E.c(28), {
|
|
755
|
+
mode: t,
|
|
756
|
+
title: l,
|
|
757
|
+
recipientDisplay: i,
|
|
758
|
+
isForeignUser: r,
|
|
759
|
+
handleSubmit: o,
|
|
760
|
+
handleResend: s,
|
|
761
|
+
canResend: a,
|
|
762
|
+
timerText: c,
|
|
763
|
+
isSubmitting: u
|
|
764
|
+
} = n, h = Q();
|
|
765
|
+
let f;
|
|
766
|
+
e[0] !== o || e[1] !== h ? (f = h.handleSubmit(o), e[0] = o, e[1] = h, e[2] = f) : f = e[2];
|
|
767
|
+
let m;
|
|
768
|
+
e[3] !== l ? (m = /* @__PURE__ */ d(F, { variant: "h5", weight: "extraBold", align: "left", className: "mb-2 text-neutral-black", children: l }), e[3] = l, e[4] = m) : m = e[4];
|
|
769
|
+
const g = r ? "mb-2 text-neutral-black" : "mb-6 text-neutral-black";
|
|
770
|
+
let b;
|
|
771
|
+
e[5] !== i || e[6] !== g ? (b = /* @__PURE__ */ d(F, { variant: "title2", align: "left", className: g, children: i }), e[5] = i, e[6] = g, e[7] = b) : b = e[7];
|
|
772
|
+
let p;
|
|
773
|
+
e[8] !== r || e[9] !== t ? (p = r && /* @__PURE__ */ d(F, { variant: "textLabel1", weight: "semiBold", align: "left", className: "mb-6 text-neutral-black", children: Kt[t] }), e[8] = r, e[9] = t, e[10] = p) : p = e[10];
|
|
774
|
+
let y;
|
|
775
|
+
e[11] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (y = /* @__PURE__ */ d("div", { className: "mb-4 flex w-full flex-col gap-[12px]", children: /* @__PURE__ */ d($t, { name: "otp", length: he, autoFocus: !0, inputClassName: "!h-[44px] !w-[44px]" }) }), e[11] = y) : y = e[11];
|
|
776
|
+
let x;
|
|
777
|
+
e[12] !== a || e[13] !== s || e[14] !== c ? (x = /* @__PURE__ */ d("div", { className: "mb-6 font-medium flex items-center gap-2", children: a ? /* @__PURE__ */ d(U, { type: "button", variant: "outline", size: "small", onClick: s, className: "!h-[28px]", children: "Resend Code" }) : /* @__PURE__ */ d(F, { variant: "textLabel3", align: "left", className: "text-neutral-black", children: c }) }), e[12] = a, e[13] = s, e[14] = c, e[15] = x) : x = e[15];
|
|
778
|
+
let v;
|
|
779
|
+
e[16] !== u ? (v = u ? /* @__PURE__ */ d(re, { size: 32, strokeWidth: 2 }) : "Submit", e[16] = u, e[17] = v) : v = e[17];
|
|
780
|
+
let C;
|
|
781
|
+
e[18] !== u || e[19] !== v ? (C = /* @__PURE__ */ d(U, { type: "submit", variant: "primary", size: "large", fullWidth: !0, disabled: u, children: v }), e[18] = u, e[19] = v, e[20] = C) : C = e[20];
|
|
782
|
+
let N;
|
|
783
|
+
return e[21] !== f || e[22] !== m || e[23] !== b || e[24] !== p || e[25] !== x || e[26] !== C ? (N = /* @__PURE__ */ k("form", { onSubmit: f, className: "flex w-full flex-col", noValidate: !0, children: [
|
|
784
|
+
m,
|
|
785
|
+
b,
|
|
786
|
+
p,
|
|
787
|
+
y,
|
|
788
|
+
x,
|
|
789
|
+
C
|
|
790
|
+
] }), e[21] = f, e[22] = m, e[23] = b, e[24] = p, e[25] = x, e[26] = C, e[27] = N) : N = e[27], N;
|
|
791
|
+
}
|
|
792
|
+
function Ze(n) {
|
|
793
|
+
const e = E.c(21), {
|
|
794
|
+
mode: t,
|
|
795
|
+
title: l,
|
|
796
|
+
recipientDisplay: i,
|
|
797
|
+
isForeignUser: r,
|
|
798
|
+
onSubmit: o,
|
|
799
|
+
onResendCode: s,
|
|
800
|
+
submitApi: a,
|
|
801
|
+
onSuccess: c,
|
|
802
|
+
onError: u,
|
|
803
|
+
validate: h
|
|
804
|
+
} = n, f = r === void 0 ? !1 : r;
|
|
805
|
+
let m;
|
|
806
|
+
e[0] !== t || e[1] !== u || e[2] !== s || e[3] !== o || e[4] !== c || e[5] !== a || e[6] !== h ? (m = {
|
|
807
|
+
mode: t,
|
|
808
|
+
onSubmit: o,
|
|
809
|
+
onResendCode: s,
|
|
810
|
+
submitApi: a,
|
|
811
|
+
onSuccess: c,
|
|
812
|
+
onError: u,
|
|
813
|
+
validate: h
|
|
814
|
+
}, e[0] = t, e[1] = u, e[2] = s, e[3] = o, e[4] = c, e[5] = a, e[6] = h, e[7] = m) : m = e[7];
|
|
815
|
+
const {
|
|
816
|
+
methods: g,
|
|
817
|
+
handleSubmit: b,
|
|
818
|
+
handleResend: p,
|
|
819
|
+
canResend: y,
|
|
820
|
+
timerText: x,
|
|
821
|
+
isSubmitting: v
|
|
822
|
+
} = Jt(m), C = l ?? Yt[t];
|
|
823
|
+
let N;
|
|
824
|
+
e[8] !== y || e[9] !== C || e[10] !== p || e[11] !== b || e[12] !== f || e[13] !== v || e[14] !== t || e[15] !== i || e[16] !== x ? (N = /* @__PURE__ */ d(en, { mode: t, title: C, recipientDisplay: i, isForeignUser: f, handleSubmit: b, handleResend: p, canResend: y, timerText: x, isSubmitting: v }), e[8] = y, e[9] = C, e[10] = p, e[11] = b, e[12] = f, e[13] = v, e[14] = t, e[15] = i, e[16] = x, e[17] = N) : N = e[17];
|
|
825
|
+
let S;
|
|
826
|
+
return e[18] !== g || e[19] !== N ? (S = /* @__PURE__ */ d(ve, { ...g, children: N }), e[18] = g, e[19] = N, e[20] = S) : S = e[20], S;
|
|
827
|
+
}
|
|
828
|
+
function Jn(n) {
|
|
829
|
+
const e = E.c(24);
|
|
830
|
+
let t, l, i, r;
|
|
831
|
+
e[0] !== n ? ({
|
|
832
|
+
layoutType: i,
|
|
833
|
+
variant: r,
|
|
834
|
+
onBack: l,
|
|
835
|
+
...t
|
|
836
|
+
} = n, e[0] = n, e[1] = t, e[2] = l, e[3] = i, e[4] = r) : (t = e[1], l = e[2], i = e[3], r = e[4]);
|
|
837
|
+
const o = i === void 0 ? "withSlider" : i;
|
|
838
|
+
let s;
|
|
839
|
+
e[5] !== l ? (s = l != null ? /* @__PURE__ */ d(Ne, { onClick: l }) : void 0, e[5] = l, e[6] = s) : s = e[6];
|
|
840
|
+
let a;
|
|
841
|
+
e[7] !== t.isForeignUser || e[8] !== t.mode || e[9] !== t.onError || e[10] !== t.onResendCode || e[11] !== t.onSubmit || e[12] !== t.onSuccess || e[13] !== t.recipientDisplay || e[14] !== t.submitApi || e[15] !== t.title || e[16] !== t.validate || e[17] !== l ? (a = /* @__PURE__ */ d(Ze, { mode: t.mode, recipientDisplay: t.recipientDisplay, title: t.title, isForeignUser: t.isForeignUser, onBack: l, onSubmit: t.onSubmit, onResendCode: t.onResendCode, submitApi: t.submitApi, onSuccess: t.onSuccess, onError: t.onError, validate: t.validate }), e[7] = t.isForeignUser, e[8] = t.mode, e[9] = t.onError, e[10] = t.onResendCode, e[11] = t.onSubmit, e[12] = t.onSuccess, e[13] = t.recipientDisplay, e[14] = t.submitApi, e[15] = t.title, e[16] = t.validate, e[17] = l, e[18] = a) : a = e[18];
|
|
842
|
+
let c;
|
|
843
|
+
return e[19] !== o || e[20] !== s || e[21] !== a || e[22] !== r ? (c = /* @__PURE__ */ d(X, { layoutType: o, variant: r, contentWidth: "sm", align: "left", backButton: s, className: xe, children: a }), e[19] = o, e[20] = s, e[21] = a, e[22] = r, e[23] = c) : c = e[23], c;
|
|
844
|
+
}
|
|
845
|
+
function et(n, e) {
|
|
846
|
+
if (e)
|
|
847
|
+
return `${n ? `+${n} ` : ""}${e}`;
|
|
848
|
+
}
|
|
849
|
+
function tn(n) {
|
|
850
|
+
return n.conflictField === "phone" ? n.existingEmail : et(n.existingCountryCode, n.existingPhone);
|
|
851
|
+
}
|
|
852
|
+
function nn(n) {
|
|
853
|
+
return n.conflictField === "phone" ? `Login with '${et(n.newCountryCode, n.newPhone) ?? ""}'` : `Login with '${n.newEmail}'`;
|
|
854
|
+
}
|
|
855
|
+
function Be(n) {
|
|
856
|
+
const e = tn(n);
|
|
857
|
+
return n.conflictField === "phone" ? e ? `This number is already linked to a Docthub account (${e})` : "This number is already linked to a Docthub account" : e ? `This email is already linked to a Docthub account (${e})` : "This email is already linked to a Docthub account";
|
|
858
|
+
}
|
|
859
|
+
function ln(n) {
|
|
860
|
+
return /* @__PURE__ */ k(F, { variant: "body1", align: "center", className: "mb-4 text-[16px] font-normal leading-6 text-black md:mb-6", children: [
|
|
861
|
+
"Please tell us your ",
|
|
862
|
+
/* @__PURE__ */ d("span", { className: "font-bold", children: "Full Name" }),
|
|
863
|
+
" and",
|
|
864
|
+
" ",
|
|
865
|
+
/* @__PURE__ */ d("span", { className: "font-bold", children: n.conflictField === "phone" ? "Mobile Number" : "Email Address" }),
|
|
866
|
+
" ",
|
|
867
|
+
"for extended security of your account."
|
|
868
|
+
] });
|
|
869
|
+
}
|
|
870
|
+
function on(n) {
|
|
871
|
+
const e = E.c(7), {
|
|
872
|
+
label: t,
|
|
873
|
+
value: l
|
|
874
|
+
} = n;
|
|
875
|
+
let i;
|
|
876
|
+
e[0] !== t ? (i = /* @__PURE__ */ d("span", { className: "text-[8px] leading-[11px] text-black/60", children: t }), e[0] = t, e[1] = i) : i = e[1];
|
|
877
|
+
let r;
|
|
878
|
+
e[2] !== l ? (r = /* @__PURE__ */ d("span", { className: "truncate text-[14px] leading-5 text-black", children: l }), e[2] = l, e[3] = r) : r = e[3];
|
|
879
|
+
let o;
|
|
880
|
+
return e[4] !== i || e[5] !== r ? (o = /* @__PURE__ */ k("div", { className: "flex h-[44px] w-full flex-col justify-center gap-[6px] overflow-hidden rounded-lg border border-black/10 bg-white px-3 pb-3 pt-[9px]", children: [
|
|
881
|
+
i,
|
|
882
|
+
r
|
|
883
|
+
] }), e[4] = i, e[5] = r, e[6] = o) : o = e[6], o;
|
|
884
|
+
}
|
|
885
|
+
function rn(n) {
|
|
886
|
+
const e = E.c(13), {
|
|
887
|
+
countryCode: t,
|
|
888
|
+
value: l,
|
|
889
|
+
error: i
|
|
890
|
+
} = n, r = t ?? "";
|
|
891
|
+
let o;
|
|
892
|
+
e[0] !== r ? (o = /* @__PURE__ */ k("span", { className: "w-[42px] shrink-0 text-center text-[14px] leading-5 text-black", children: [
|
|
893
|
+
"+",
|
|
894
|
+
r
|
|
895
|
+
] }), e[0] = r, e[1] = o) : o = e[1];
|
|
896
|
+
let s;
|
|
897
|
+
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ d("div", { className: "h-[42px] w-px shrink-0 bg-black/10" }), e[2] = s) : s = e[2];
|
|
898
|
+
let a;
|
|
899
|
+
e[3] !== l ? (a = /* @__PURE__ */ d("span", { className: "truncate text-[14px] leading-5 text-black", children: l }), e[3] = l, e[4] = a) : a = e[4];
|
|
900
|
+
let c;
|
|
901
|
+
e[5] !== o || e[6] !== a ? (c = /* @__PURE__ */ k("div", { className: "flex w-full items-center gap-3 overflow-hidden rounded-lg border border-black/10 bg-white px-3 py-px", children: [
|
|
902
|
+
o,
|
|
903
|
+
s,
|
|
904
|
+
a
|
|
905
|
+
] }), e[5] = o, e[6] = a, e[7] = c) : c = e[7];
|
|
906
|
+
let u;
|
|
907
|
+
e[8] !== i ? (u = i ? /* @__PURE__ */ d("p", { className: "text-[11px] font-medium leading-4 text-[#EA4335]", children: i }) : null, e[8] = i, e[9] = u) : u = e[9];
|
|
908
|
+
let h;
|
|
909
|
+
return e[10] !== c || e[11] !== u ? (h = /* @__PURE__ */ k("div", { className: "flex w-full flex-col gap-[6px]", children: [
|
|
910
|
+
c,
|
|
911
|
+
u
|
|
912
|
+
] }), e[10] = c, e[11] = u, e[12] = h) : h = e[12], h;
|
|
913
|
+
}
|
|
914
|
+
function sn(n) {
|
|
915
|
+
const e = E.c(12), {
|
|
916
|
+
label: t,
|
|
917
|
+
value: l,
|
|
918
|
+
error: i
|
|
919
|
+
} = n;
|
|
920
|
+
let r;
|
|
921
|
+
e[0] !== t ? (r = /* @__PURE__ */ d("span", { className: "text-[8px] leading-[11px] text-black/60", children: t }), e[0] = t, e[1] = r) : r = e[1];
|
|
922
|
+
let o;
|
|
923
|
+
e[2] !== l ? (o = /* @__PURE__ */ d("span", { className: "truncate text-[14px] leading-5 text-black", children: l }), e[2] = l, e[3] = o) : o = e[3];
|
|
924
|
+
let s;
|
|
925
|
+
e[4] !== r || e[5] !== o ? (s = /* @__PURE__ */ k("div", { className: "flex h-[44px] w-full flex-col justify-center gap-[6px] overflow-hidden rounded-lg border border-black/10 bg-white px-3 pb-3 pt-[9px]", children: [
|
|
926
|
+
r,
|
|
927
|
+
o
|
|
928
|
+
] }), e[4] = r, e[5] = o, e[6] = s) : s = e[6];
|
|
929
|
+
let a;
|
|
930
|
+
e[7] !== i ? (a = i ? /* @__PURE__ */ d("p", { className: "text-[11px] font-medium leading-4 text-[#EA4335]", children: i }) : null, e[7] = i, e[8] = a) : a = e[8];
|
|
931
|
+
let c;
|
|
932
|
+
return e[9] !== s || e[10] !== a ? (c = /* @__PURE__ */ k("div", { className: "flex w-full flex-col gap-[6px]", children: [
|
|
933
|
+
s,
|
|
934
|
+
a
|
|
935
|
+
] }), e[9] = s, e[10] = a, e[11] = c) : c = e[11], c;
|
|
936
|
+
}
|
|
937
|
+
function an(n) {
|
|
938
|
+
const e = E.c(10), {
|
|
939
|
+
ctaLabel: t,
|
|
940
|
+
isSubmitting: l,
|
|
941
|
+
onContinue: i
|
|
942
|
+
} = n;
|
|
943
|
+
let r;
|
|
944
|
+
e[0] !== t || e[1] !== l ? (r = l ? /* @__PURE__ */ d(re, { size: 32, strokeWidth: 2 }) : t, e[0] = t, e[1] = l, e[2] = r) : r = e[2];
|
|
945
|
+
let o;
|
|
946
|
+
e[3] !== l || e[4] !== i || e[5] !== r ? (o = /* @__PURE__ */ d(U, { type: "button", variant: "outline", size: "large", fullWidth: !0, disabled: l, onClick: i, className: "!rounded-[10px] !border-2 !border-black/10 !bg-transparent !px-4 !py-[13px] !text-[14px] !font-semibold !leading-5 !text-black/80 hover:!bg-transparent", children: r }), e[3] = l, e[4] = i, e[5] = r, e[6] = o) : o = e[6];
|
|
947
|
+
let s;
|
|
948
|
+
e[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ d(F, { variant: "textLabel3", align: "center", className: "w-full text-center text-[8px] font-normal leading-[11px] text-black/45", children: "your accounts will be unified on login" }), e[7] = s) : s = e[7];
|
|
949
|
+
let a;
|
|
950
|
+
return e[8] !== o ? (a = /* @__PURE__ */ k("div", { className: "flex w-full flex-col gap-[6px] rounded-xl bg-black/[0.04] p-3", children: [
|
|
951
|
+
o,
|
|
952
|
+
s
|
|
953
|
+
] }), e[8] = o, e[9] = a) : a = e[9], a;
|
|
954
|
+
}
|
|
955
|
+
function cn(n) {
|
|
956
|
+
const e = E.c(20), {
|
|
957
|
+
details: t,
|
|
958
|
+
isSubmitting: l,
|
|
959
|
+
errorMessage: i,
|
|
960
|
+
onContinue: r
|
|
961
|
+
} = n;
|
|
962
|
+
let o;
|
|
963
|
+
e[0] !== t.name ? (o = /* @__PURE__ */ d(on, { label: "Full Name", value: t.name }), e[0] = t.name, e[1] = o) : o = e[1];
|
|
964
|
+
let s;
|
|
965
|
+
e[2] !== t ? (s = t.conflictField === "phone" ? /* @__PURE__ */ d(rn, { countryCode: t.newCountryCode, value: t.newPhone ?? "", error: Be(t) }) : /* @__PURE__ */ d(sn, { label: "Email address", value: t.newEmail, error: Be(t) }), e[2] = t, e[3] = s) : s = e[3];
|
|
966
|
+
let a;
|
|
967
|
+
e[4] !== o || e[5] !== s ? (a = /* @__PURE__ */ k("div", { className: "flex w-full flex-col gap-3", children: [
|
|
968
|
+
o,
|
|
969
|
+
s
|
|
970
|
+
] }), e[4] = o, e[5] = s, e[6] = a) : a = e[6];
|
|
971
|
+
let c;
|
|
972
|
+
e[7] !== t ? (c = nn(t), e[7] = t, e[8] = c) : c = e[8];
|
|
973
|
+
let u;
|
|
974
|
+
e[9] !== l || e[10] !== r || e[11] !== c ? (u = /* @__PURE__ */ d(an, { ctaLabel: c, isSubmitting: l, onContinue: r }), e[9] = l, e[10] = r, e[11] = c, e[12] = u) : u = e[12];
|
|
975
|
+
let h;
|
|
976
|
+
e[13] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ d("div", { "aria-disabled": "true", className: "flex w-full items-center justify-center rounded-xl bg-black/[0.06] px-5 py-4 text-base font-semibold leading-[22px] text-black/20", children: "Continue" }), e[13] = h) : h = e[13];
|
|
977
|
+
let f;
|
|
978
|
+
e[14] !== i ? (f = i ? /* @__PURE__ */ d(F, { variant: "body5", align: "center", className: "mt-4 text-[11px] font-medium leading-4 text-[#EA4335]", children: i }) : null, e[14] = i, e[15] = f) : f = e[15];
|
|
979
|
+
let m;
|
|
980
|
+
return e[16] !== a || e[17] !== u || e[18] !== f ? (m = /* @__PURE__ */ k("div", { className: "flex w-full flex-col gap-4", children: [
|
|
981
|
+
a,
|
|
982
|
+
u,
|
|
983
|
+
h,
|
|
984
|
+
f
|
|
985
|
+
] }), e[16] = a, e[17] = u, e[18] = f, e[19] = m) : m = e[19], m;
|
|
986
|
+
}
|
|
987
|
+
function un(n) {
|
|
988
|
+
return n.otpTarget?.type === "email" ? "6 digit OTP has been sent to your old Email" : "6 digit OTP has been sent to your old Mobile";
|
|
989
|
+
}
|
|
990
|
+
function dn(n) {
|
|
991
|
+
const e = n.otpTarget;
|
|
992
|
+
return e ? e.maskedValue ?? e.value : "";
|
|
993
|
+
}
|
|
994
|
+
function Qn(n) {
|
|
995
|
+
const {
|
|
996
|
+
details: e,
|
|
997
|
+
onBack: t,
|
|
998
|
+
onContinue: l,
|
|
999
|
+
onVerify: i,
|
|
1000
|
+
onResendCode: r
|
|
1001
|
+
} = n, [o, s] = z(!1), [a, c] = z(""), u = e.stage === "otp", h = async () => {
|
|
1002
|
+
c(""), s(!0);
|
|
1003
|
+
try {
|
|
1004
|
+
await l();
|
|
1005
|
+
} catch (f) {
|
|
1006
|
+
c(f?.message ?? "Unable to continue right now");
|
|
1007
|
+
} finally {
|
|
1008
|
+
s(!1);
|
|
1009
|
+
}
|
|
1010
|
+
};
|
|
1011
|
+
return /* @__PURE__ */ d(X, { layoutType: "standalone", variant: "mobile", contentWidth: "sm", backButton: u && t != null ? /* @__PURE__ */ d(Ne, { onClick: t }) : void 0, logo: u ? void 0 : /* @__PURE__ */ d("img", { src: ke, alt: "Docthub Logo", width: 46, height: 46 }), title: u ? void 0 : /* @__PURE__ */ d(F, { variant: "h5", weight: "bold", align: "center", className: "text-[14px] leading-[21px] text-black mt-4 md:mt-6", children: "Welcome to Docthub" }), description: u ? void 0 : ln(e), className: xe, children: u ? /* @__PURE__ */ d(Ze, { mode: e.otpTarget?.type ?? e.conflictField, title: un(e), recipientDisplay: dn(e), submitApi: i, onResendCode: r }) : /* @__PURE__ */ d(cn, { details: e, isSubmitting: o, errorMessage: a, onContinue: () => {
|
|
1012
|
+
h();
|
|
1013
|
+
} }) });
|
|
1014
|
+
}
|
|
1015
|
+
function ge(n) {
|
|
1016
|
+
const e = E.c(43);
|
|
1017
|
+
let t, l, i, r, o, s, a, c, u, h, f, m, g, b, p, y, x, v;
|
|
1018
|
+
e[0] !== n ? ({
|
|
1019
|
+
name: u,
|
|
1020
|
+
label: y,
|
|
1021
|
+
countryCode: x,
|
|
1022
|
+
countryCodeName: r,
|
|
1023
|
+
phoneArrayName: g,
|
|
1024
|
+
selectedCountryName: p,
|
|
1025
|
+
countries: i,
|
|
1026
|
+
defaultCountry: o,
|
|
1027
|
+
onValuesChange: m,
|
|
1028
|
+
onCountryChange: h,
|
|
1029
|
+
onCountryCodeChange: f,
|
|
1030
|
+
placeholder: v,
|
|
1031
|
+
disabled: s,
|
|
1032
|
+
required: b,
|
|
1033
|
+
className: t,
|
|
1034
|
+
helperText: c,
|
|
1035
|
+
control: l,
|
|
1036
|
+
...a
|
|
1037
|
+
} = n, e[0] = n, e[1] = t, e[2] = l, e[3] = i, e[4] = r, e[5] = o, e[6] = s, e[7] = a, e[8] = c, e[9] = u, e[10] = h, e[11] = f, e[12] = m, e[13] = g, e[14] = b, e[15] = p, e[16] = y, e[17] = x, e[18] = v) : (t = e[1], l = e[2], i = e[3], r = e[4], o = e[5], s = e[6], a = e[7], c = e[8], u = e[9], h = e[10], f = e[11], m = e[12], g = e[13], b = e[14], p = e[15], y = e[16], x = e[17], v = e[18]);
|
|
1038
|
+
const C = y === void 0 ? "Phone Number" : y, N = x === void 0 ? "91" : x, S = v === void 0 ? "Enter phone number" : v, _ = Q(), w = l || _.control;
|
|
1039
|
+
let P;
|
|
1040
|
+
e[19] !== t || e[20] !== i || e[21] !== N || e[22] !== r || e[23] !== o || e[24] !== s || e[25] !== a || e[26] !== c || e[27] !== C || e[28] !== _ || e[29] !== u || e[30] !== h || e[31] !== f || e[32] !== m || e[33] !== g || e[34] !== S || e[35] !== b || e[36] !== w || e[37] !== p ? (P = (I) => {
|
|
1041
|
+
const {
|
|
1042
|
+
field: $,
|
|
1043
|
+
fieldState: O
|
|
1044
|
+
} = I, L = (R, W) => /* @__PURE__ */ d(st, { ...a, id: u, value: String($.value ?? ""), ...C !== void 0 && {
|
|
1045
|
+
label: C
|
|
1046
|
+
}, ...R ? {
|
|
1047
|
+
countryCode: R
|
|
1048
|
+
} : {}, ...S !== void 0 && {
|
|
1049
|
+
placeholder: S
|
|
1050
|
+
}, ...s !== void 0 && {
|
|
1051
|
+
disabled: s
|
|
1052
|
+
}, ...b !== void 0 && {
|
|
1053
|
+
required: b
|
|
1054
|
+
}, ...i !== void 0 && {
|
|
1055
|
+
countries: i
|
|
1056
|
+
}, ...o !== void 0 && {
|
|
1057
|
+
defaultCountry: o
|
|
1058
|
+
}, ...t !== void 0 && {
|
|
1059
|
+
className: t
|
|
1060
|
+
}, ...O.error?.message !== void 0 && {
|
|
1061
|
+
error: O.error?.message
|
|
1062
|
+
}, ...O.error === void 0 && c !== void 0 && {
|
|
1063
|
+
helperText: c
|
|
1064
|
+
}, onPhoneChange: (T) => {
|
|
1065
|
+
$.onChange(T.replaceAll(/\D/g, ""));
|
|
1066
|
+
}, onCountryCodeChange: (T) => {
|
|
1067
|
+
const D = String(T || "").replaceAll(/\D/g, "");
|
|
1068
|
+
W?.(D), f?.(T);
|
|
1069
|
+
}, onValuesChange: (T) => {
|
|
1070
|
+
g && _.setValue(g, T, {
|
|
1071
|
+
shouldDirty: !0
|
|
1072
|
+
}), m?.(T);
|
|
1073
|
+
}, onCountryChange: (T) => {
|
|
1074
|
+
p && _.setValue(p, JSON.stringify(T), {
|
|
1075
|
+
shouldDirty: !0
|
|
1076
|
+
}), h?.(T);
|
|
1077
|
+
}, onBlur: $.onBlur });
|
|
1078
|
+
if (!r) {
|
|
1079
|
+
const R = String(N || "").replaceAll(/\D/g, "");
|
|
1080
|
+
return L(R);
|
|
1081
|
+
}
|
|
1082
|
+
return /* @__PURE__ */ d(me, { name: r, control: w, render: (R) => {
|
|
1083
|
+
const {
|
|
1084
|
+
field: W
|
|
1085
|
+
} = R, T = String(W.value ?? N ?? "").replaceAll(/\D/g, "");
|
|
1086
|
+
return L(T, W.onChange);
|
|
1087
|
+
} });
|
|
1088
|
+
}, e[19] = t, e[20] = i, e[21] = N, e[22] = r, e[23] = o, e[24] = s, e[25] = a, e[26] = c, e[27] = C, e[28] = _, e[29] = u, e[30] = h, e[31] = f, e[32] = m, e[33] = g, e[34] = S, e[35] = b, e[36] = w, e[37] = p, e[38] = P) : P = e[38];
|
|
1089
|
+
let A;
|
|
1090
|
+
return e[39] !== u || e[40] !== w || e[41] !== P ? (A = /* @__PURE__ */ d(me, { name: u, control: w, render: P }), e[39] = u, e[40] = w, e[41] = P, e[42] = A) : A = e[42], A;
|
|
1091
|
+
}
|
|
1092
|
+
function fe(n) {
|
|
1093
|
+
const e = E.c(15), {
|
|
1094
|
+
name: t,
|
|
1095
|
+
label: l,
|
|
1096
|
+
placeholder: i,
|
|
1097
|
+
className: r,
|
|
1098
|
+
control: o,
|
|
1099
|
+
required: s,
|
|
1100
|
+
type: a,
|
|
1101
|
+
disabled: c,
|
|
1102
|
+
onKeyDown: u,
|
|
1103
|
+
maxLength: h,
|
|
1104
|
+
numericOnly: f,
|
|
1105
|
+
autoFocus: m
|
|
1106
|
+
} = n, g = Q(), b = o || g.control;
|
|
1107
|
+
let p;
|
|
1108
|
+
e[0] !== m || e[1] !== r || e[2] !== c || e[3] !== l || e[4] !== h || e[5] !== f || e[6] !== u || e[7] !== i || e[8] !== s || e[9] !== a ? (p = (x) => {
|
|
1109
|
+
const {
|
|
1110
|
+
field: v,
|
|
1111
|
+
fieldState: C
|
|
1112
|
+
} = x;
|
|
1113
|
+
return /* @__PURE__ */ d(He, { ...v, value: v.value ?? "", ...m !== void 0 && {
|
|
1114
|
+
autoFocus: m
|
|
1115
|
+
}, ...l !== void 0 && {
|
|
1116
|
+
label: l
|
|
1117
|
+
}, ...i !== void 0 && {
|
|
1118
|
+
placeholder: i
|
|
1119
|
+
}, ...C.error?.message !== void 0 && {
|
|
1120
|
+
error: C.error.message
|
|
1121
|
+
}, ...r !== void 0 && {
|
|
1122
|
+
className: r
|
|
1123
|
+
}, ...s !== void 0 && {
|
|
1124
|
+
required: s
|
|
1125
|
+
}, type: a, ...c !== void 0 && {
|
|
1126
|
+
disabled: c
|
|
1127
|
+
}, onKeyDown: f ? (N) => {
|
|
1128
|
+
!/[0-9]/.test(N.key) && !["Backspace", "Tab", "Delete", "ArrowLeft", "ArrowRight", "Home", "End"].includes(N.key) && N.preventDefault(), u?.(N);
|
|
1129
|
+
} : u, ...h !== void 0 && {
|
|
1130
|
+
maxLength: h
|
|
1131
|
+
}, onChange: (N) => {
|
|
1132
|
+
const S = N?.target?.value;
|
|
1133
|
+
if (typeof S == "string") {
|
|
1134
|
+
let _ = S.replace(/^\s+/, "");
|
|
1135
|
+
f && (_ = _.replace(/\D/g, "")), v.onChange(_);
|
|
1136
|
+
} else
|
|
1137
|
+
v.onChange(S);
|
|
1138
|
+
}, onBlur: () => {
|
|
1139
|
+
const N = v.value;
|
|
1140
|
+
if (typeof N == "string") {
|
|
1141
|
+
const S = N.trim();
|
|
1142
|
+
S !== N && v.onChange(S);
|
|
1143
|
+
}
|
|
1144
|
+
v.onBlur();
|
|
1145
|
+
} });
|
|
1146
|
+
}, e[0] = m, e[1] = r, e[2] = c, e[3] = l, e[4] = h, e[5] = f, e[6] = u, e[7] = i, e[8] = s, e[9] = a, e[10] = p) : p = e[10];
|
|
1147
|
+
let y;
|
|
1148
|
+
return e[11] !== t || e[12] !== b || e[13] !== p ? (y = /* @__PURE__ */ d(me, { name: t, control: b, render: p }), e[11] = t, e[12] = b, e[13] = p, e[14] = y) : y = e[14], y;
|
|
1149
|
+
}
|
|
1150
|
+
function fn(n, e) {
|
|
1151
|
+
const t = (n ?? "").trim();
|
|
1152
|
+
if (t.length === 0) return "";
|
|
1153
|
+
if (t.startsWith("+")) return t;
|
|
1154
|
+
const l = (e ?? "").replaceAll(/\D/g, "");
|
|
1155
|
+
return l.length > 0 ? `+${l}${t}` : t;
|
|
1156
|
+
}
|
|
1157
|
+
const Te = "doct-auth-kit:form:";
|
|
1158
|
+
function Fe() {
|
|
1159
|
+
if (typeof window > "u") return null;
|
|
1160
|
+
try {
|
|
1161
|
+
return window.sessionStorage;
|
|
1162
|
+
} catch {
|
|
1163
|
+
return null;
|
|
1164
|
+
}
|
|
1165
|
+
}
|
|
1166
|
+
function mn(n) {
|
|
1167
|
+
const e = Fe();
|
|
1168
|
+
if (!e) return null;
|
|
1169
|
+
try {
|
|
1170
|
+
const t = e.getItem(Te + n);
|
|
1171
|
+
return t ? JSON.parse(t) : null;
|
|
1172
|
+
} catch {
|
|
1173
|
+
return null;
|
|
1174
|
+
}
|
|
1175
|
+
}
|
|
1176
|
+
function hn(n, e) {
|
|
1177
|
+
const t = Fe();
|
|
1178
|
+
if (t)
|
|
1179
|
+
try {
|
|
1180
|
+
t.setItem(Te + n, JSON.stringify(e));
|
|
1181
|
+
} catch {
|
|
1182
|
+
}
|
|
1183
|
+
}
|
|
1184
|
+
function Xn() {
|
|
1185
|
+
const n = Fe();
|
|
1186
|
+
if (n)
|
|
1187
|
+
try {
|
|
1188
|
+
const e = [];
|
|
1189
|
+
for (let t = 0; t < n.length; t++) {
|
|
1190
|
+
const l = n.key(t);
|
|
1191
|
+
l && l.startsWith(Te) && e.push(l);
|
|
1192
|
+
}
|
|
1193
|
+
e.forEach((t) => n.removeItem(t));
|
|
1194
|
+
} catch {
|
|
1195
|
+
}
|
|
1196
|
+
}
|
|
1197
|
+
function Ie(n, e) {
|
|
1198
|
+
for (const t of n.issues) {
|
|
1199
|
+
const l = t.path[0];
|
|
1200
|
+
typeof l == "string" && e(l, {
|
|
1201
|
+
message: t.message
|
|
1202
|
+
});
|
|
1203
|
+
}
|
|
1204
|
+
}
|
|
1205
|
+
function Re(n, e) {
|
|
1206
|
+
const t = ie(null);
|
|
1207
|
+
q(() => {
|
|
1208
|
+
if (t.current === n) return;
|
|
1209
|
+
t.current = n;
|
|
1210
|
+
const l = mn(n);
|
|
1211
|
+
l && e.reset(l);
|
|
1212
|
+
}, [n]), q(() => {
|
|
1213
|
+
const l = e.watch((i) => {
|
|
1214
|
+
hn(n, i);
|
|
1215
|
+
});
|
|
1216
|
+
return () => l.unsubscribe();
|
|
1217
|
+
}, [e, n]);
|
|
1218
|
+
}
|
|
1219
|
+
function gn(n) {
|
|
1220
|
+
const e = E.c(19), {
|
|
1221
|
+
mode: t,
|
|
1222
|
+
onSubmit: l,
|
|
1223
|
+
submitApi: i,
|
|
1224
|
+
onSuccess: r,
|
|
1225
|
+
onError: o
|
|
1226
|
+
} = n, [s, a] = z(!1), c = t === "phone";
|
|
1227
|
+
let u;
|
|
1228
|
+
e[0] !== c ? (u = c ? {
|
|
1229
|
+
phone: "",
|
|
1230
|
+
countryCode: "91"
|
|
1231
|
+
} : {
|
|
1232
|
+
email: ""
|
|
1233
|
+
}, e[0] = c, e[1] = u) : u = e[1];
|
|
1234
|
+
const h = u;
|
|
1235
|
+
let f;
|
|
1236
|
+
e[2] !== h ? (f = {
|
|
1237
|
+
defaultValues: h,
|
|
1238
|
+
mode: "onChange"
|
|
1239
|
+
}, e[2] = h, e[3] = f) : f = e[3];
|
|
1240
|
+
const m = ye(f);
|
|
1241
|
+
Re(`login-entry:${t}`, m);
|
|
1242
|
+
let g;
|
|
1243
|
+
e[4] !== m || e[5] !== t || e[6] !== o || e[7] !== l || e[8] !== r || e[9] !== i ? (g = (v) => {
|
|
1244
|
+
const N = ze[t].safeParse(v);
|
|
1245
|
+
if (!N.success) {
|
|
1246
|
+
Ie(N.error, (_, w) => m.setError(_, w));
|
|
1247
|
+
return;
|
|
1248
|
+
}
|
|
1249
|
+
const S = N.data;
|
|
1250
|
+
if (i) {
|
|
1251
|
+
a(!0);
|
|
1252
|
+
const _ = S.phone ? fn(S.phone, S.countryCode) : S.email ?? "", w = {
|
|
1253
|
+
mode: t,
|
|
1254
|
+
recipient: _
|
|
1255
|
+
};
|
|
1256
|
+
i(S).then(() => {
|
|
1257
|
+
r?.(w);
|
|
1258
|
+
}).catch((P) => {
|
|
1259
|
+
o?.(P);
|
|
1260
|
+
}).finally(() => {
|
|
1261
|
+
a(!1);
|
|
1262
|
+
});
|
|
1263
|
+
return;
|
|
1264
|
+
}
|
|
1265
|
+
l?.(S);
|
|
1266
|
+
}, e[4] = m, e[5] = t, e[6] = o, e[7] = l, e[8] = r, e[9] = i, e[10] = g) : g = e[10];
|
|
1267
|
+
const b = g;
|
|
1268
|
+
let p;
|
|
1269
|
+
e[11] !== t ? (p = (v) => ze[t].safeParse(v).success, e[11] = t, e[12] = p) : p = e[12];
|
|
1270
|
+
const y = p;
|
|
1271
|
+
let x;
|
|
1272
|
+
return e[13] !== b || e[14] !== y || e[15] !== c || e[16] !== s || e[17] !== m ? (x = {
|
|
1273
|
+
methods: m,
|
|
1274
|
+
handleSubmit: b,
|
|
1275
|
+
isPhone: c,
|
|
1276
|
+
isFormValid: y,
|
|
1277
|
+
isSubmitting: s
|
|
1278
|
+
}, e[13] = b, e[14] = y, e[15] = c, e[16] = s, e[17] = m, e[18] = x) : x = e[18], x;
|
|
1279
|
+
}
|
|
1280
|
+
function pn(n) {
|
|
1281
|
+
const e = E.c(14), {
|
|
1282
|
+
isPhone: t,
|
|
1283
|
+
handleSubmit: l,
|
|
1284
|
+
isSubmitting: i
|
|
1285
|
+
} = n, r = Q();
|
|
1286
|
+
let o;
|
|
1287
|
+
e[0] !== l || e[1] !== r ? (o = r.handleSubmit(l), e[0] = l, e[1] = r, e[2] = o) : o = e[2];
|
|
1288
|
+
let s;
|
|
1289
|
+
e[3] !== t ? (s = /* @__PURE__ */ d("div", { className: "mb-6 flex w-full flex-col gap-[12px]", children: t ? /* @__PURE__ */ d(ge, { name: "phone", label: "", placeholder: "Phone number", countryCode: "+91", countryCodeName: "countryCode", defaultCountry: "IN", className: "[&_button]:!h-[44px] [&_input]:!h-[44px]", autoFocus: !0 }) : /* @__PURE__ */ d(fe, { name: "email", placeholder: "Enter email address", type: "email", className: "[&_input]:!h-[44px]", autoFocus: !0 }) }), e[3] = t, e[4] = s) : s = e[4];
|
|
1290
|
+
let a;
|
|
1291
|
+
e[5] !== i ? (a = i ? /* @__PURE__ */ d(re, { size: 32, strokeWidth: 2 }) : "Continue", e[5] = i, e[6] = a) : a = e[6];
|
|
1292
|
+
let c;
|
|
1293
|
+
e[7] !== i || e[8] !== a ? (c = /* @__PURE__ */ d(U, { type: "submit", variant: "primary", size: "large", fullWidth: !0, disabled: i, children: a }), e[7] = i, e[8] = a, e[9] = c) : c = e[9];
|
|
1294
|
+
let u;
|
|
1295
|
+
return e[10] !== o || e[11] !== s || e[12] !== c ? (u = /* @__PURE__ */ k("form", { onSubmit: o, className: "w-full flex flex-col", noValidate: !0, children: [
|
|
1296
|
+
s,
|
|
1297
|
+
c
|
|
1298
|
+
] }), e[10] = o, e[11] = s, e[12] = c, e[13] = u) : u = e[13], u;
|
|
1299
|
+
}
|
|
1300
|
+
function bn(n) {
|
|
1301
|
+
const e = E.c(13), {
|
|
1302
|
+
mode: t,
|
|
1303
|
+
onSubmit: l,
|
|
1304
|
+
submitApi: i,
|
|
1305
|
+
onSuccess: r,
|
|
1306
|
+
onError: o
|
|
1307
|
+
} = n;
|
|
1308
|
+
let s;
|
|
1309
|
+
e[0] !== t || e[1] !== o || e[2] !== l || e[3] !== r || e[4] !== i ? (s = {
|
|
1310
|
+
mode: t,
|
|
1311
|
+
onSubmit: l,
|
|
1312
|
+
submitApi: i,
|
|
1313
|
+
onSuccess: r,
|
|
1314
|
+
onError: o
|
|
1315
|
+
}, e[0] = t, e[1] = o, e[2] = l, e[3] = r, e[4] = i, e[5] = s) : s = e[5];
|
|
1316
|
+
const {
|
|
1317
|
+
methods: a,
|
|
1318
|
+
handleSubmit: c,
|
|
1319
|
+
isPhone: u,
|
|
1320
|
+
isSubmitting: h
|
|
1321
|
+
} = gn(s);
|
|
1322
|
+
let f;
|
|
1323
|
+
e[6] !== c || e[7] !== u || e[8] !== h ? (f = /* @__PURE__ */ d(pn, { isPhone: u, handleSubmit: c, isSubmitting: h }), e[6] = c, e[7] = u, e[8] = h, e[9] = f) : f = e[9];
|
|
1324
|
+
let m;
|
|
1325
|
+
return e[10] !== a || e[11] !== f ? (m = /* @__PURE__ */ d(ve, { ...a, children: f }), e[10] = a, e[11] = f, e[12] = m) : m = e[12], m;
|
|
1326
|
+
}
|
|
1327
|
+
const yn = {
|
|
1328
|
+
phone: "Enter Phone Number",
|
|
1329
|
+
email: "Enter Email Address"
|
|
1330
|
+
}, vn = {
|
|
1331
|
+
phone: "We will send you 6 digit OTP on the given Phone Number.",
|
|
1332
|
+
email: "We will send you 6 digit OTP on the given Email Address."
|
|
1333
|
+
};
|
|
1334
|
+
function Zn(n) {
|
|
1335
|
+
const e = E.c(27), {
|
|
1336
|
+
mode: t,
|
|
1337
|
+
title: l,
|
|
1338
|
+
subtitle: i,
|
|
1339
|
+
onBack: r,
|
|
1340
|
+
onSubmit: o,
|
|
1341
|
+
submitApi: s,
|
|
1342
|
+
onSuccess: a,
|
|
1343
|
+
onError: c,
|
|
1344
|
+
layoutType: u,
|
|
1345
|
+
variant: h
|
|
1346
|
+
} = n, f = u === void 0 ? "withSlider" : u, m = h === void 0 ? "desktop" : h, g = l ?? yn[t], b = i ?? vn[t];
|
|
1347
|
+
let p;
|
|
1348
|
+
e[0] !== r ? (p = r != null ? /* @__PURE__ */ d(Ne, { onClick: r }) : void 0, e[0] = r, e[1] = p) : p = e[1];
|
|
1349
|
+
let y;
|
|
1350
|
+
e[2] !== g ? (y = /* @__PURE__ */ d(F, { variant: "h5", weight: "extraBold", align: "left", className: "-mb-1.5", children: g }), e[2] = g, e[3] = y) : y = e[3];
|
|
1351
|
+
let x;
|
|
1352
|
+
e[4] !== b ? (x = /* @__PURE__ */ d(F, { variant: "body1", align: "left", className: "mb-4 md:mb-4", children: b }), e[4] = b, e[5] = x) : x = e[5];
|
|
1353
|
+
let v;
|
|
1354
|
+
e[6] !== o ? (v = o && {
|
|
1355
|
+
onSubmit: o
|
|
1356
|
+
}, e[6] = o, e[7] = v) : v = e[7];
|
|
1357
|
+
let C;
|
|
1358
|
+
e[8] !== s ? (C = s && {
|
|
1359
|
+
submitApi: s
|
|
1360
|
+
}, e[8] = s, e[9] = C) : C = e[9];
|
|
1361
|
+
let N;
|
|
1362
|
+
e[10] !== a ? (N = a && {
|
|
1363
|
+
onSuccess: a
|
|
1364
|
+
}, e[10] = a, e[11] = N) : N = e[11];
|
|
1365
|
+
let S;
|
|
1366
|
+
e[12] !== c ? (S = c && {
|
|
1367
|
+
onError: c
|
|
1368
|
+
}, e[12] = c, e[13] = S) : S = e[13];
|
|
1369
|
+
let _;
|
|
1370
|
+
e[14] !== t || e[15] !== v || e[16] !== C || e[17] !== N || e[18] !== S ? (_ = /* @__PURE__ */ d(bn, { mode: t, ...v, ...C, ...N, ...S }), e[14] = t, e[15] = v, e[16] = C, e[17] = N, e[18] = S, e[19] = _) : _ = e[19];
|
|
1371
|
+
let w;
|
|
1372
|
+
return e[20] !== f || e[21] !== p || e[22] !== y || e[23] !== x || e[24] !== _ || e[25] !== m ? (w = /* @__PURE__ */ d(X, { layoutType: f, variant: m, contentWidth: "sm", align: "left", backButton: p, title: y, description: x, className: xe, children: _ }), e[20] = f, e[21] = p, e[22] = y, e[23] = x, e[24] = _, e[25] = m, e[26] = w) : w = e[26], w;
|
|
1373
|
+
}
|
|
1374
|
+
var tt = {
|
|
1375
|
+
color: void 0,
|
|
1376
|
+
size: void 0,
|
|
1377
|
+
className: void 0,
|
|
1378
|
+
style: void 0,
|
|
1379
|
+
attr: void 0
|
|
1380
|
+
}, Ve = J.createContext && /* @__PURE__ */ J.createContext(tt), xn = ["attr", "size", "title"];
|
|
1381
|
+
function Nn(n, e) {
|
|
1382
|
+
if (n == null) return {};
|
|
1383
|
+
var t = Sn(n, e), l, i;
|
|
1384
|
+
if (Object.getOwnPropertySymbols) {
|
|
1385
|
+
var r = Object.getOwnPropertySymbols(n);
|
|
1386
|
+
for (i = 0; i < r.length; i++)
|
|
1387
|
+
l = r[i], !(e.indexOf(l) >= 0) && Object.prototype.propertyIsEnumerable.call(n, l) && (t[l] = n[l]);
|
|
1388
|
+
}
|
|
1389
|
+
return t;
|
|
1390
|
+
}
|
|
1391
|
+
function Sn(n, e) {
|
|
1392
|
+
if (n == null) return {};
|
|
1393
|
+
var t = {};
|
|
1394
|
+
for (var l in n)
|
|
1395
|
+
if (Object.prototype.hasOwnProperty.call(n, l)) {
|
|
1396
|
+
if (e.indexOf(l) >= 0) continue;
|
|
1397
|
+
t[l] = n[l];
|
|
1398
|
+
}
|
|
1399
|
+
return t;
|
|
1400
|
+
}
|
|
1401
|
+
function pe() {
|
|
1402
|
+
return pe = Object.assign ? Object.assign.bind() : function(n) {
|
|
1403
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
1404
|
+
var t = arguments[e];
|
|
1405
|
+
for (var l in t)
|
|
1406
|
+
Object.prototype.hasOwnProperty.call(t, l) && (n[l] = t[l]);
|
|
1407
|
+
}
|
|
1408
|
+
return n;
|
|
1409
|
+
}, pe.apply(this, arguments);
|
|
1410
|
+
}
|
|
1411
|
+
function Ge(n, e) {
|
|
1412
|
+
var t = Object.keys(n);
|
|
1413
|
+
if (Object.getOwnPropertySymbols) {
|
|
1414
|
+
var l = Object.getOwnPropertySymbols(n);
|
|
1415
|
+
e && (l = l.filter(function(i) {
|
|
1416
|
+
return Object.getOwnPropertyDescriptor(n, i).enumerable;
|
|
1417
|
+
})), t.push.apply(t, l);
|
|
1418
|
+
}
|
|
1419
|
+
return t;
|
|
1420
|
+
}
|
|
1421
|
+
function be(n) {
|
|
1422
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
1423
|
+
var t = arguments[e] != null ? arguments[e] : {};
|
|
1424
|
+
e % 2 ? Ge(Object(t), !0).forEach(function(l) {
|
|
1425
|
+
Cn(n, l, t[l]);
|
|
1426
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : Ge(Object(t)).forEach(function(l) {
|
|
1427
|
+
Object.defineProperty(n, l, Object.getOwnPropertyDescriptor(t, l));
|
|
1428
|
+
});
|
|
1429
|
+
}
|
|
1430
|
+
return n;
|
|
1431
|
+
}
|
|
1432
|
+
function Cn(n, e, t) {
|
|
1433
|
+
return e = wn(e), e in n ? Object.defineProperty(n, e, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : n[e] = t, n;
|
|
1434
|
+
}
|
|
1435
|
+
function wn(n) {
|
|
1436
|
+
var e = En(n, "string");
|
|
1437
|
+
return typeof e == "symbol" ? e : e + "";
|
|
1438
|
+
}
|
|
1439
|
+
function En(n, e) {
|
|
1440
|
+
if (typeof n != "object" || !n) return n;
|
|
1441
|
+
var t = n[Symbol.toPrimitive];
|
|
1442
|
+
if (t !== void 0) {
|
|
1443
|
+
var l = t.call(n, e);
|
|
1444
|
+
if (typeof l != "object") return l;
|
|
1445
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
1446
|
+
}
|
|
1447
|
+
return (e === "string" ? String : Number)(n);
|
|
1448
|
+
}
|
|
1449
|
+
function nt(n) {
|
|
1450
|
+
return n && n.map((e, t) => /* @__PURE__ */ J.createElement(e.tag, be({
|
|
1451
|
+
key: t
|
|
1452
|
+
}, e.attr), nt(e.child)));
|
|
1453
|
+
}
|
|
1454
|
+
function lt(n) {
|
|
1455
|
+
return (e) => /* @__PURE__ */ J.createElement(_n, pe({
|
|
1456
|
+
attr: be({}, n.attr)
|
|
1457
|
+
}, e), nt(n.child));
|
|
1458
|
+
}
|
|
1459
|
+
function _n(n) {
|
|
1460
|
+
var e = (t) => {
|
|
1461
|
+
var {
|
|
1462
|
+
attr: l,
|
|
1463
|
+
size: i,
|
|
1464
|
+
title: r
|
|
1465
|
+
} = n, o = Nn(n, xn), s = i || t.size || "1em", a;
|
|
1466
|
+
return t.className && (a = t.className), n.className && (a = (a ? a + " " : "") + n.className), /* @__PURE__ */ J.createElement("svg", pe({
|
|
1467
|
+
stroke: "currentColor",
|
|
1468
|
+
fill: "currentColor",
|
|
1469
|
+
strokeWidth: "0"
|
|
1470
|
+
}, t.attr, l, o, {
|
|
1471
|
+
className: a,
|
|
1472
|
+
style: be(be({
|
|
1473
|
+
color: n.color || t.color
|
|
1474
|
+
}, t.style), n.style),
|
|
1475
|
+
height: s,
|
|
1476
|
+
width: s,
|
|
1477
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
1478
|
+
}), r && /* @__PURE__ */ J.createElement("title", null, r), n.children);
|
|
1479
|
+
};
|
|
1480
|
+
return Ve !== void 0 ? /* @__PURE__ */ J.createElement(Ve.Consumer, null, (t) => e(t)) : e(tt);
|
|
1481
|
+
}
|
|
1482
|
+
function kn(n) {
|
|
1483
|
+
return lt({ attr: { viewBox: "0 0 384 512" }, child: [{ tag: "path", attr: { d: "M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z" }, child: [] }] })(n);
|
|
1484
|
+
}
|
|
1485
|
+
function Pn(n) {
|
|
1486
|
+
return lt({ attr: { version: "1.1", x: "0px", y: "0px", viewBox: "0 0 48 48", enableBackground: "new 0 0 48 48" }, child: [{ tag: "path", attr: { fill: "#FFC107", d: `M43.611,20.083H42V20H24v8h11.303c-1.649,4.657-6.08,8-11.303,8c-6.627,0-12-5.373-12-12\r
|
|
1487
|
+
c0-6.627,5.373-12,12-12c3.059,0,5.842,1.154,7.961,3.039l5.657-5.657C34.046,6.053,29.268,4,24,4C12.955,4,4,12.955,4,24\r
|
|
1488
|
+
c0,11.045,8.955,20,20,20c11.045,0,20-8.955,20-20C44,22.659,43.862,21.35,43.611,20.083z` }, child: [] }, { tag: "path", attr: { fill: "#FF3D00", d: `M6.306,14.691l6.571,4.819C14.655,15.108,18.961,12,24,12c3.059,0,5.842,1.154,7.961,3.039l5.657-5.657\r
|
|
1489
|
+
C34.046,6.053,29.268,4,24,4C16.318,4,9.656,8.337,6.306,14.691z` }, child: [] }, { tag: "path", attr: { fill: "#4CAF50", d: `M24,44c5.166,0,9.86-1.977,13.409-5.192l-6.19-5.238C29.211,35.091,26.715,36,24,36\r
|
|
1490
|
+
c-5.202,0-9.619-3.317-11.283-7.946l-6.522,5.025C9.505,39.556,16.227,44,24,44z` }, child: [] }, { tag: "path", attr: { fill: "#1976D2", d: `M43.611,20.083H42V20H24v8h11.303c-0.792,2.237-2.231,4.166-4.087,5.571\r
|
|
1491
|
+
c0.001-0.001,0.002-0.001,0.003-0.002l6.19,5.238C36.971,39.205,44,34,44,24C44,22.659,43.862,21.35,43.611,20.083z` }, child: [] }] })(n);
|
|
1492
|
+
}
|
|
1493
|
+
function it(n) {
|
|
1494
|
+
const e = E.c(23);
|
|
1495
|
+
let t;
|
|
1496
|
+
e[0] !== n ? (t = n === void 0 ? {} : n, e[0] = n, e[1] = t) : t = e[1];
|
|
1497
|
+
const l = t, i = Ln, r = l.providers?.google?.clientId ?? "";
|
|
1498
|
+
let o;
|
|
1499
|
+
e[2] !== l.providers?.google?.onCredential ? (o = l.providers?.google?.onCredential ?? An, e[2] = l.providers?.google?.onCredential, e[3] = o) : o = e[3];
|
|
1500
|
+
const s = l.providers?.google?.enableOneTap ?? !1;
|
|
1501
|
+
let a;
|
|
1502
|
+
e[4] !== r || e[5] !== o || e[6] !== s ? (a = {
|
|
1503
|
+
clientId: r,
|
|
1504
|
+
onCredential: o,
|
|
1505
|
+
enableOneTap: s
|
|
1506
|
+
}, e[4] = r, e[5] = o, e[6] = s, e[7] = a) : a = e[7];
|
|
1507
|
+
const {
|
|
1508
|
+
loginWithGoogle: c
|
|
1509
|
+
} = Rt(a), u = l.providers?.apple?.clientId ?? "", h = l.providers?.apple?.redirectUri ?? "";
|
|
1510
|
+
let f;
|
|
1511
|
+
e[8] !== l.providers?.apple?.onCredential ? (f = l.providers?.apple?.onCredential ?? On, e[8] = l.providers?.apple?.onCredential, e[9] = f) : f = e[9];
|
|
1512
|
+
let m;
|
|
1513
|
+
e[10] !== u || e[11] !== h || e[12] !== f ? (m = {
|
|
1514
|
+
clientId: u,
|
|
1515
|
+
redirectUri: h,
|
|
1516
|
+
onCredential: f
|
|
1517
|
+
}, e[10] = u, e[11] = h, e[12] = f, e[13] = m) : m = e[13];
|
|
1518
|
+
const {
|
|
1519
|
+
triggerSignIn: g
|
|
1520
|
+
} = Tt(), b = l.onContinueWithMobile ?? i, p = l.onContinueWithEmail ?? i;
|
|
1521
|
+
let y;
|
|
1522
|
+
e[14] !== c || e[15] !== l.onContinueWithGoogle || e[16] !== l.providers?.google?.clientId ? (y = l.onContinueWithGoogle ?? (l.providers?.google?.clientId ? () => {
|
|
1523
|
+
c();
|
|
1524
|
+
} : i), e[14] = c, e[15] = l.onContinueWithGoogle, e[16] = l.providers?.google?.clientId, e[17] = y) : y = e[17];
|
|
1525
|
+
const x = l.onContinueWithApple ?? (l.providers?.apple?.clientId ? g : i);
|
|
1526
|
+
let v;
|
|
1527
|
+
return e[18] !== b || e[19] !== p || e[20] !== y || e[21] !== x ? (v = {
|
|
1528
|
+
onContinueWithMobile: b,
|
|
1529
|
+
onContinueWithEmail: p,
|
|
1530
|
+
onContinueWithGoogle: y,
|
|
1531
|
+
onContinueWithApple: x
|
|
1532
|
+
}, e[18] = b, e[19] = p, e[20] = y, e[21] = x, e[22] = v) : v = e[22], v;
|
|
1533
|
+
}
|
|
1534
|
+
function On() {
|
|
1535
|
+
}
|
|
1536
|
+
function An() {
|
|
1537
|
+
}
|
|
1538
|
+
function Ln() {
|
|
1539
|
+
}
|
|
1540
|
+
function Tn(n) {
|
|
1541
|
+
const e = E.c(5);
|
|
1542
|
+
let t;
|
|
1543
|
+
e[0] !== n ? (t = () => typeof window > "u" ? !1 : window.matchMedia(n).matches, e[0] = n, e[1] = t) : t = e[1];
|
|
1544
|
+
const [l, i] = z(t);
|
|
1545
|
+
let r, o;
|
|
1546
|
+
return e[2] !== n ? (r = () => {
|
|
1547
|
+
const s = window.matchMedia(n), a = (c) => {
|
|
1548
|
+
i(c.matches);
|
|
1549
|
+
};
|
|
1550
|
+
return i(s.matches), s.addEventListener("change", a), () => {
|
|
1551
|
+
s.removeEventListener("change", a);
|
|
1552
|
+
};
|
|
1553
|
+
}, o = [n], e[2] = n, e[3] = r, e[4] = o) : (r = e[3], o = e[4]), q(r, o), l;
|
|
1554
|
+
}
|
|
1555
|
+
const Fn = "Mobile";
|
|
1556
|
+
function In(n) {
|
|
1557
|
+
const e = E.c(11);
|
|
1558
|
+
let t;
|
|
1559
|
+
e[0] !== n ? (t = n === void 0 ? {} : n, e[0] = n, e[1] = t) : t = e[1];
|
|
1560
|
+
const l = t, [i, r] = z(!1), {
|
|
1561
|
+
lastUsedMethod: o,
|
|
1562
|
+
onContinueWithLastMethod: s,
|
|
1563
|
+
continueApi: a,
|
|
1564
|
+
onSuccess: c,
|
|
1565
|
+
onError: u
|
|
1566
|
+
} = l, h = o === void 0 ? Fn : o;
|
|
1567
|
+
let f;
|
|
1568
|
+
e[2] !== a || e[3] !== s || e[4] !== u || e[5] !== c ? (f = () => {
|
|
1569
|
+
if (a) {
|
|
1570
|
+
r(!0), a().then(() => {
|
|
1571
|
+
c?.();
|
|
1572
|
+
}).catch((b) => {
|
|
1573
|
+
u?.(b);
|
|
1574
|
+
}).finally(() => {
|
|
1575
|
+
r(!1);
|
|
1576
|
+
});
|
|
1577
|
+
return;
|
|
1578
|
+
}
|
|
1579
|
+
s?.();
|
|
1580
|
+
}, e[2] = a, e[3] = s, e[4] = u, e[5] = c, e[6] = f) : f = e[6];
|
|
1581
|
+
const m = f;
|
|
1582
|
+
let g;
|
|
1583
|
+
return e[7] !== m || e[8] !== i || e[9] !== h ? (g = {
|
|
1584
|
+
handleContinue: m,
|
|
1585
|
+
isSubmitting: i,
|
|
1586
|
+
lastUsedMethod: h
|
|
1587
|
+
}, e[7] = m, e[8] = i, e[9] = h, e[10] = g) : g = e[10], g;
|
|
1588
|
+
}
|
|
1589
|
+
function Rn(n) {
|
|
1590
|
+
const e = E.c(22), {
|
|
1591
|
+
mode: t,
|
|
1592
|
+
defaultPhone: l,
|
|
1593
|
+
onSubmit: i,
|
|
1594
|
+
submitApi: r,
|
|
1595
|
+
onSuccess: o,
|
|
1596
|
+
onError: s
|
|
1597
|
+
} = n, a = l === void 0 ? "" : l, [c, u] = z(!1), h = t === "phone", f = t === "foreign";
|
|
1598
|
+
let m;
|
|
1599
|
+
e[0] !== a || e[1] !== f || e[2] !== h ? (m = f ? {
|
|
1600
|
+
fullName: "",
|
|
1601
|
+
email: "",
|
|
1602
|
+
phone: a,
|
|
1603
|
+
countryCode: "91"
|
|
1604
|
+
} : h ? {
|
|
1605
|
+
fullName: "",
|
|
1606
|
+
phone: "",
|
|
1607
|
+
countryCode: "91"
|
|
1608
|
+
} : {
|
|
1609
|
+
fullName: "",
|
|
1610
|
+
email: ""
|
|
1611
|
+
}, e[0] = a, e[1] = f, e[2] = h, e[3] = m) : m = e[3];
|
|
1612
|
+
const g = m;
|
|
1613
|
+
let b;
|
|
1614
|
+
e[4] !== g ? (b = {
|
|
1615
|
+
defaultValues: g,
|
|
1616
|
+
mode: "onChange"
|
|
1617
|
+
}, e[4] = g, e[5] = b) : b = e[5];
|
|
1618
|
+
const p = ye(b);
|
|
1619
|
+
Re(`signup:${t}`, p);
|
|
1620
|
+
let y;
|
|
1621
|
+
e[6] !== p || e[7] !== t || e[8] !== s || e[9] !== i || e[10] !== o || e[11] !== r ? (y = (S) => {
|
|
1622
|
+
const w = Ue[t].safeParse(S);
|
|
1623
|
+
if (!w.success) {
|
|
1624
|
+
Ie(w.error, (A, I) => p.setError(A, I));
|
|
1625
|
+
return;
|
|
1626
|
+
}
|
|
1627
|
+
const P = {
|
|
1628
|
+
fullName: w.data.fullName,
|
|
1629
|
+
..."phone" in w.data && w.data.phone && {
|
|
1630
|
+
phone: w.data.phone
|
|
1631
|
+
},
|
|
1632
|
+
..."countryCode" in w.data && w.data.countryCode && {
|
|
1633
|
+
countryCode: w.data.countryCode
|
|
1634
|
+
},
|
|
1635
|
+
..."email" in w.data && w.data.email && {
|
|
1636
|
+
email: w.data.email
|
|
1637
|
+
}
|
|
1638
|
+
};
|
|
1639
|
+
if (r) {
|
|
1640
|
+
u(!0), r(P).then(() => {
|
|
1641
|
+
o?.();
|
|
1642
|
+
}).catch((A) => {
|
|
1643
|
+
s?.(A);
|
|
1644
|
+
}).finally(() => {
|
|
1645
|
+
u(!1);
|
|
1646
|
+
});
|
|
1647
|
+
return;
|
|
1648
|
+
}
|
|
1649
|
+
i?.(P);
|
|
1650
|
+
}, e[6] = p, e[7] = t, e[8] = s, e[9] = i, e[10] = o, e[11] = r, e[12] = y) : y = e[12];
|
|
1651
|
+
const x = y;
|
|
1652
|
+
let v;
|
|
1653
|
+
e[13] !== t ? (v = (S) => Ue[t].safeParse(S).success, e[13] = t, e[14] = v) : v = e[14];
|
|
1654
|
+
const C = v;
|
|
1655
|
+
let N;
|
|
1656
|
+
return e[15] !== x || e[16] !== f || e[17] !== C || e[18] !== h || e[19] !== c || e[20] !== p ? (N = {
|
|
1657
|
+
methods: p,
|
|
1658
|
+
handleSubmit: x,
|
|
1659
|
+
isPhone: h,
|
|
1660
|
+
isForeign: f,
|
|
1661
|
+
isFormValid: C,
|
|
1662
|
+
isSubmitting: c
|
|
1663
|
+
}, e[15] = x, e[16] = f, e[17] = C, e[18] = h, e[19] = c, e[20] = p, e[21] = N) : N = e[21], N;
|
|
1664
|
+
}
|
|
1665
|
+
function Dn(n) {
|
|
1666
|
+
const e = E.c(17), {
|
|
1667
|
+
initialFullName: t,
|
|
1668
|
+
onSubmit: l,
|
|
1669
|
+
submitApi: i,
|
|
1670
|
+
onSuccess: r,
|
|
1671
|
+
onError: o
|
|
1672
|
+
} = n, s = t === void 0 ? "" : t, [a, c] = z(!1), [u, h] = z(s);
|
|
1673
|
+
let f;
|
|
1674
|
+
e[0] !== s ? (f = {
|
|
1675
|
+
defaultValues: {
|
|
1676
|
+
fullName: s,
|
|
1677
|
+
phone: "",
|
|
1678
|
+
countryCode: "91"
|
|
1679
|
+
},
|
|
1680
|
+
mode: "onChange"
|
|
1681
|
+
}, e[0] = s, e[1] = f) : f = e[1];
|
|
1682
|
+
const m = ye(f);
|
|
1683
|
+
Re("welcome-signup:phone", m);
|
|
1684
|
+
let g;
|
|
1685
|
+
e[2] !== u || e[3] !== m || e[4] !== o || e[5] !== l || e[6] !== r || e[7] !== i ? (g = (x) => {
|
|
1686
|
+
const v = zt.safeParse({
|
|
1687
|
+
...x,
|
|
1688
|
+
fullName: u.trim()
|
|
1689
|
+
});
|
|
1690
|
+
if (!v.success) {
|
|
1691
|
+
Ie(v.error, (N, S) => m.setError(N, S));
|
|
1692
|
+
return;
|
|
1693
|
+
}
|
|
1694
|
+
const C = {
|
|
1695
|
+
fullName: v.data.fullName,
|
|
1696
|
+
phone: v.data.phone,
|
|
1697
|
+
...v.data.countryCode != null && {
|
|
1698
|
+
countryCode: v.data.countryCode
|
|
1699
|
+
}
|
|
1700
|
+
};
|
|
1701
|
+
if (i) {
|
|
1702
|
+
c(!0), i(C).then(() => {
|
|
1703
|
+
r?.();
|
|
1704
|
+
}).catch((N) => {
|
|
1705
|
+
o?.(N);
|
|
1706
|
+
}).finally(() => {
|
|
1707
|
+
c(!1);
|
|
1708
|
+
});
|
|
1709
|
+
return;
|
|
1710
|
+
}
|
|
1711
|
+
l?.(C);
|
|
1712
|
+
}, e[2] = u, e[3] = m, e[4] = o, e[5] = l, e[6] = r, e[7] = i, e[8] = g) : g = e[8];
|
|
1713
|
+
const b = g;
|
|
1714
|
+
let p;
|
|
1715
|
+
e[9] !== m ? (p = (x) => {
|
|
1716
|
+
h(x), m.setValue("fullName", x, {
|
|
1717
|
+
shouldDirty: !0,
|
|
1718
|
+
shouldValidate: !0
|
|
1719
|
+
});
|
|
1720
|
+
}, e[9] = m, e[10] = p) : p = e[10];
|
|
1721
|
+
let y;
|
|
1722
|
+
return e[11] !== u || e[12] !== b || e[13] !== a || e[14] !== m || e[15] !== p ? (y = {
|
|
1723
|
+
methods: m,
|
|
1724
|
+
handleSubmit: b,
|
|
1725
|
+
isSubmitting: a,
|
|
1726
|
+
fullName: u,
|
|
1727
|
+
setFullName: p
|
|
1728
|
+
}, e[11] = u, e[12] = b, e[13] = a, e[14] = m, e[15] = p, e[16] = y) : y = e[16], y;
|
|
1729
|
+
}
|
|
1730
|
+
const ot = (n) => {
|
|
1731
|
+
const e = E.c(19), {
|
|
1732
|
+
handlers: t
|
|
1733
|
+
} = n, {
|
|
1734
|
+
onContinueWithMobile: l,
|
|
1735
|
+
onContinueWithEmail: i,
|
|
1736
|
+
onContinueWithGoogle: r,
|
|
1737
|
+
onContinueWithApple: o
|
|
1738
|
+
} = t;
|
|
1739
|
+
let s;
|
|
1740
|
+
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ d(de, { children: "Continue with Mobile" }), e[0] = s) : s = e[0];
|
|
1741
|
+
let a;
|
|
1742
|
+
e[1] !== l ? (a = /* @__PURE__ */ d(U, { variant: "outline", size: "large", fullWidth: !0, onClick: l, children: s }), e[1] = l, e[2] = a) : a = e[2];
|
|
1743
|
+
let c;
|
|
1744
|
+
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (c = /* @__PURE__ */ d(de, { children: "Continue with Email" }), e[3] = c) : c = e[3];
|
|
1745
|
+
let u;
|
|
1746
|
+
e[4] !== i ? (u = /* @__PURE__ */ d(U, { variant: "outline", size: "large", fullWidth: !0, onClick: i, children: c }), e[4] = i, e[5] = u) : u = e[5];
|
|
1747
|
+
let h;
|
|
1748
|
+
e[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ d(Pn, { "aria-hidden": !0 }), e[6] = h) : h = e[6];
|
|
1749
|
+
let f;
|
|
1750
|
+
e[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ d(de, { children: "Continue with Google" }), e[7] = f) : f = e[7];
|
|
1751
|
+
let m;
|
|
1752
|
+
e[8] !== r ? (m = /* @__PURE__ */ d(U, { variant: "outline", size: "large", fullWidth: !0, icon: h, iconPosition: "left", onClick: r, children: f }), e[8] = r, e[9] = m) : m = e[9];
|
|
1753
|
+
let g;
|
|
1754
|
+
e[10] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (g = /* @__PURE__ */ d(kn, { "aria-hidden": !0 }), e[10] = g) : g = e[10];
|
|
1755
|
+
let b;
|
|
1756
|
+
e[11] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (b = /* @__PURE__ */ d(de, { children: "Continue with Apple" }), e[11] = b) : b = e[11];
|
|
1757
|
+
let p;
|
|
1758
|
+
e[12] !== o ? (p = /* @__PURE__ */ d(U, { variant: "outline", size: "large", fullWidth: !0, icon: g, iconPosition: "left", onClick: o, children: b }), e[12] = o, e[13] = p) : p = e[13];
|
|
1759
|
+
let y;
|
|
1760
|
+
return e[14] !== p || e[15] !== a || e[16] !== u || e[17] !== m ? (y = /* @__PURE__ */ k("div", { className: "w-full flex flex-col gap-2", children: [
|
|
1761
|
+
a,
|
|
1762
|
+
u,
|
|
1763
|
+
m,
|
|
1764
|
+
p
|
|
1765
|
+
] }), e[14] = p, e[15] = a, e[16] = u, e[17] = m, e[18] = y) : y = e[18], y;
|
|
1766
|
+
}, de = (n) => {
|
|
1767
|
+
const e = E.c(2), {
|
|
1768
|
+
children: t
|
|
1769
|
+
} = n;
|
|
1770
|
+
let l;
|
|
1771
|
+
return e[0] !== t ? (l = /* @__PURE__ */ d(F, { variant: "textLabel1", weight: "semiBold", align: "center", className: "opacity-80", children: t }), e[0] = t, e[1] = l) : l = e[1], l;
|
|
1772
|
+
};
|
|
1773
|
+
function el(n) {
|
|
1774
|
+
const e = E.c(2), t = it(n);
|
|
1775
|
+
let l;
|
|
1776
|
+
return e[0] !== t ? (l = /* @__PURE__ */ d(ot, { handlers: t }), e[0] = t, e[1] = l) : l = e[1], l;
|
|
1777
|
+
}
|
|
1778
|
+
const tl = (n) => {
|
|
1779
|
+
const e = E.c(17), t = it(n);
|
|
1780
|
+
let l;
|
|
1781
|
+
e[0] !== n.onEnterpriseLogin ? (l = n.onEnterpriseLogin != null && {
|
|
1782
|
+
onClick: n.onEnterpriseLogin
|
|
1783
|
+
}, e[0] = n.onEnterpriseLogin, e[1] = l) : l = e[1];
|
|
1784
|
+
let i;
|
|
1785
|
+
e[2] !== n.enterpriseLoginUrl ? (i = n.enterpriseLoginUrl != null && {
|
|
1786
|
+
href: n.enterpriseLoginUrl
|
|
1787
|
+
}, e[2] = n.enterpriseLoginUrl, e[3] = i) : i = e[3];
|
|
1788
|
+
let r;
|
|
1789
|
+
e[4] !== l || e[5] !== i ? (r = {
|
|
1790
|
+
...l,
|
|
1791
|
+
...i
|
|
1792
|
+
}, e[4] = l, e[5] = i, e[6] = r) : r = e[6];
|
|
1793
|
+
const o = r;
|
|
1794
|
+
let s;
|
|
1795
|
+
e[7] !== o ? (s = /* @__PURE__ */ d(vt, { ...o }), e[7] = o, e[8] = s) : s = e[8];
|
|
1796
|
+
let a, c, u;
|
|
1797
|
+
e[9] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ d(F, { variant: "title1", weight: "bold", align: "center", className: "max-w-[250px] mx-auto mb-0 md:mb-2", children: "The Healthcare Career App" }), c = /* @__PURE__ */ d(F, { variant: "body1", align: "center", className: "mb-0 md:mb-2", children: "Continue to Signup, If you already have an account we'll log you in." }), u = /* @__PURE__ */ d(Ye, {}), e[9] = a, e[10] = c, e[11] = u) : (a = e[9], c = e[10], u = e[11]);
|
|
1798
|
+
let h;
|
|
1799
|
+
e[12] !== t ? (h = /* @__PURE__ */ d(ot, { handlers: t }), e[12] = t, e[13] = h) : h = e[13];
|
|
1800
|
+
let f;
|
|
1801
|
+
return e[14] !== s || e[15] !== h ? (f = /* @__PURE__ */ d(X, { layoutType: "withSlider", variant: "desktop", header: s, logo: qe, align: "center", title: a, description: c, footer: u, children: h }), e[14] = s, e[15] = h, e[16] = f) : f = e[16], f;
|
|
1802
|
+
};
|
|
1803
|
+
function $n(n) {
|
|
1804
|
+
const e = E.c(21);
|
|
1805
|
+
let t, l;
|
|
1806
|
+
e[0] !== n ? ({
|
|
1807
|
+
onUseAnotherMethod: l,
|
|
1808
|
+
...t
|
|
1809
|
+
} = n, e[0] = n, e[1] = t, e[2] = l) : (t = e[1], l = e[2]);
|
|
1810
|
+
let i;
|
|
1811
|
+
e[3] !== t.continueApi || e[4] !== t.lastUsedMethod || e[5] !== t.onContinueWithLastMethod || e[6] !== t.onError || e[7] !== t.onSuccess ? (i = {
|
|
1812
|
+
lastUsedMethod: t.lastUsedMethod,
|
|
1813
|
+
onContinueWithLastMethod: t.onContinueWithLastMethod,
|
|
1814
|
+
continueApi: t.continueApi,
|
|
1815
|
+
onSuccess: t.onSuccess,
|
|
1816
|
+
onError: t.onError
|
|
1817
|
+
}, e[3] = t.continueApi, e[4] = t.lastUsedMethod, e[5] = t.onContinueWithLastMethod, e[6] = t.onError, e[7] = t.onSuccess, e[8] = i) : i = e[8];
|
|
1818
|
+
const {
|
|
1819
|
+
handleContinue: r,
|
|
1820
|
+
isSubmitting: o,
|
|
1821
|
+
lastUsedMethod: s
|
|
1822
|
+
} = In(i), a = o ? "Continuing…" : `Continue with ${s}`;
|
|
1823
|
+
let c;
|
|
1824
|
+
e[9] !== a ? (c = /* @__PURE__ */ d(F, { variant: "textLabel1", weight: "semiBold", align: "center", className: "text-neutral-white", children: a }), e[9] = a, e[10] = c) : c = e[10];
|
|
1825
|
+
let u;
|
|
1826
|
+
e[11] !== r || e[12] !== o || e[13] !== c ? (u = /* @__PURE__ */ d(U, { variant: "primary", size: "large", fullWidth: !0, onClick: r, disabled: o, children: c }), e[11] = r, e[12] = o, e[13] = c, e[14] = u) : u = e[14];
|
|
1827
|
+
let h;
|
|
1828
|
+
e[15] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ d(F, { variant: "textLabel1", weight: "semiBold", align: "center", className: "opacity-80", children: "Use another method" }), e[15] = h) : h = e[15];
|
|
1829
|
+
let f;
|
|
1830
|
+
e[16] !== l ? (f = /* @__PURE__ */ d(U, { variant: "outline", size: "large", fullWidth: !0, onClick: l, children: h }), e[16] = l, e[17] = f) : f = e[17];
|
|
1831
|
+
let m;
|
|
1832
|
+
return e[18] !== u || e[19] !== f ? (m = /* @__PURE__ */ k("div", { className: "w-full flex flex-col gap-[12px]", children: [
|
|
1833
|
+
u,
|
|
1834
|
+
f
|
|
1835
|
+
] }), e[18] = u, e[19] = f, e[20] = m) : m = e[20], m;
|
|
1836
|
+
}
|
|
1837
|
+
function nl(n) {
|
|
1838
|
+
const e = E.c(18), {
|
|
1839
|
+
lastUsedMethod: t,
|
|
1840
|
+
onContinueWithLastMethod: l,
|
|
1841
|
+
onUseAnotherMethod: i,
|
|
1842
|
+
continueApi: r,
|
|
1843
|
+
onSuccess: o,
|
|
1844
|
+
onError: s,
|
|
1845
|
+
layoutType: a,
|
|
1846
|
+
variant: c
|
|
1847
|
+
} = n, u = t === void 0 ? "Mobile" : t, h = a === void 0 ? "withSlider" : a, f = c === "mobile" || h === "standalone";
|
|
1848
|
+
let m;
|
|
1849
|
+
e[0] !== f ? (m = f ? /* @__PURE__ */ d(F, { variant: "h5", weight: "bold", align: "center", className: "text-primary -mb-2 mt-4", children: "Welcome Back!" }) : /* @__PURE__ */ k(F, { variant: "h6", weight: "extraBold", align: "left", className: "text-neutral-black -mb-2 mt-4", children: [
|
|
1850
|
+
" ",
|
|
1851
|
+
"Welcome Back!",
|
|
1852
|
+
" "
|
|
1853
|
+
] }), e[0] = f, e[1] = m) : m = e[1];
|
|
1854
|
+
let g;
|
|
1855
|
+
e[2] !== u ? (g = /* @__PURE__ */ k(F, { variant: "body1", align: "center", className: "text-neutral-black mb-4 md:mb-4", children: [
|
|
1856
|
+
"Last time you used ",
|
|
1857
|
+
u,
|
|
1858
|
+
" to log in."
|
|
1859
|
+
] }), e[2] = u, e[3] = g) : g = e[3];
|
|
1860
|
+
let b;
|
|
1861
|
+
e[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (b = /* @__PURE__ */ d(Ye, {}), e[4] = b) : b = e[4];
|
|
1862
|
+
let p;
|
|
1863
|
+
e[5] !== r || e[6] !== u || e[7] !== l || e[8] !== s || e[9] !== o || e[10] !== i ? (p = /* @__PURE__ */ d($n, { lastUsedMethod: u, onContinueWithLastMethod: l, onUseAnotherMethod: i, continueApi: r, onSuccess: o, onError: s }), e[5] = r, e[6] = u, e[7] = l, e[8] = s, e[9] = o, e[10] = i, e[11] = p) : p = e[11];
|
|
1864
|
+
let y;
|
|
1865
|
+
return e[12] !== h || e[13] !== m || e[14] !== g || e[15] !== p || e[16] !== c ? (y = /* @__PURE__ */ d(X, { layoutType: h, variant: c, logo: qe, title: m, description: g, footer: b, children: p }), e[12] = h, e[13] = m, e[14] = g, e[15] = p, e[16] = c, e[17] = y) : y = e[17], y;
|
|
1866
|
+
}
|
|
1867
|
+
function Wn(n) {
|
|
1868
|
+
const e = E.c(16), {
|
|
1869
|
+
isPhone: t,
|
|
1870
|
+
isForeign: l,
|
|
1871
|
+
handleSubmit: i,
|
|
1872
|
+
isSubmitting: r
|
|
1873
|
+
} = n, o = Q();
|
|
1874
|
+
let s;
|
|
1875
|
+
e[0] !== i || e[1] !== o ? (s = o.handleSubmit(i), e[0] = i, e[1] = o, e[2] = s) : s = e[2];
|
|
1876
|
+
let a;
|
|
1877
|
+
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ d(fe, { name: "fullName", placeholder: "Full name", type: "text", className: "w-full", autoFocus: !0 }), e[3] = a) : a = e[3];
|
|
1878
|
+
let c;
|
|
1879
|
+
e[4] !== l || e[5] !== t ? (c = /* @__PURE__ */ k("div", { className: "mb-6 flex w-full flex-col gap-[12px]", children: [
|
|
1880
|
+
a,
|
|
1881
|
+
l ? /* @__PURE__ */ k(_e, { children: [
|
|
1882
|
+
/* @__PURE__ */ d(fe, { name: "email", placeholder: "Email address", type: "email", className: "w-full" }),
|
|
1883
|
+
/* @__PURE__ */ d(ge, { name: "phone", label: "", placeholder: "Phone number", countryCode: "+91", countryCodeName: "countryCode", defaultCountry: "IN" })
|
|
1884
|
+
] }) : t ? /* @__PURE__ */ d(ge, { name: "phone", label: "", placeholder: "Phone number", countryCode: "+91", countryCodeName: "countryCode", defaultCountry: "IN" }) : /* @__PURE__ */ d(fe, { name: "email", placeholder: "Email address", type: "email", className: "w-full" })
|
|
1885
|
+
] }), e[4] = l, e[5] = t, e[6] = c) : c = e[6];
|
|
1886
|
+
let u;
|
|
1887
|
+
e[7] !== r ? (u = r ? /* @__PURE__ */ d(re, { size: 32, strokeWidth: 2 }) : "Continue", e[7] = r, e[8] = u) : u = e[8];
|
|
1888
|
+
let h;
|
|
1889
|
+
e[9] !== r || e[10] !== u ? (h = /* @__PURE__ */ d(U, { type: "submit", variant: "primary", size: "large", fullWidth: !0, disabled: r, children: u }), e[9] = r, e[10] = u, e[11] = h) : h = e[11];
|
|
1890
|
+
let f;
|
|
1891
|
+
return e[12] !== s || e[13] !== c || e[14] !== h ? (f = /* @__PURE__ */ k("form", { onSubmit: s, className: "w-full flex flex-col items-center", noValidate: !0, children: [
|
|
1892
|
+
c,
|
|
1893
|
+
h
|
|
1894
|
+
] }), e[12] = s, e[13] = c, e[14] = h, e[15] = f) : f = e[15], f;
|
|
1895
|
+
}
|
|
1896
|
+
function Mn(n) {
|
|
1897
|
+
const e = E.c(15), {
|
|
1898
|
+
userType: t,
|
|
1899
|
+
signupCollectField: l,
|
|
1900
|
+
pendingPhone: i,
|
|
1901
|
+
onSubmit: r,
|
|
1902
|
+
submitApi: o,
|
|
1903
|
+
onSuccess: s,
|
|
1904
|
+
onError: a
|
|
1905
|
+
} = n, c = i === void 0 ? "" : i, u = t === "FOREIGN" ? "foreign" : l === "phone" ? "phone" : "email";
|
|
1906
|
+
let h;
|
|
1907
|
+
e[0] !== u || e[1] !== a || e[2] !== r || e[3] !== s || e[4] !== c || e[5] !== o ? (h = {
|
|
1908
|
+
mode: u,
|
|
1909
|
+
defaultPhone: c,
|
|
1910
|
+
onSubmit: r,
|
|
1911
|
+
submitApi: o,
|
|
1912
|
+
onSuccess: s,
|
|
1913
|
+
onError: a
|
|
1914
|
+
}, e[0] = u, e[1] = a, e[2] = r, e[3] = s, e[4] = c, e[5] = o, e[6] = h) : h = e[6];
|
|
1915
|
+
const {
|
|
1916
|
+
methods: f,
|
|
1917
|
+
handleSubmit: m,
|
|
1918
|
+
isPhone: g,
|
|
1919
|
+
isForeign: b,
|
|
1920
|
+
isSubmitting: p
|
|
1921
|
+
} = Rn(h);
|
|
1922
|
+
let y;
|
|
1923
|
+
e[7] !== m || e[8] !== b || e[9] !== g || e[10] !== p ? (y = /* @__PURE__ */ d(Wn, { isPhone: g, isForeign: b, handleSubmit: m, isSubmitting: p }), e[7] = m, e[8] = b, e[9] = g, e[10] = p, e[11] = y) : y = e[11];
|
|
1924
|
+
let x;
|
|
1925
|
+
return e[12] !== f || e[13] !== y ? (x = /* @__PURE__ */ d(ve, { ...f, children: y }), e[12] = f, e[13] = y, e[14] = x) : x = e[14], x;
|
|
1926
|
+
}
|
|
1927
|
+
function ll(n) {
|
|
1928
|
+
const e = E.c(21), {
|
|
1929
|
+
layoutType: t,
|
|
1930
|
+
variant: l
|
|
1931
|
+
} = n, i = t === void 0 ? "standalone" : t, r = l === void 0 ? "mobile" : l;
|
|
1932
|
+
let o;
|
|
1933
|
+
e[0] !== n.loginMethod || e[1] !== n.onError || e[2] !== n.onSubmit || e[3] !== n.onSuccess || e[4] !== n.pendingPhone || e[5] !== n.signupCollectField || e[6] !== n.submitApi || e[7] !== n.userType ? (o = {
|
|
1934
|
+
userType: n.userType,
|
|
1935
|
+
loginMethod: n.loginMethod,
|
|
1936
|
+
signupCollectField: n.signupCollectField,
|
|
1937
|
+
pendingPhone: n.pendingPhone,
|
|
1938
|
+
onSubmit: n.onSubmit,
|
|
1939
|
+
submitApi: n.submitApi,
|
|
1940
|
+
onSuccess: n.onSuccess,
|
|
1941
|
+
onError: n.onError
|
|
1942
|
+
}, e[0] = n.loginMethod, e[1] = n.onError, e[2] = n.onSubmit, e[3] = n.onSuccess, e[4] = n.pendingPhone, e[5] = n.signupCollectField, e[6] = n.submitApi, e[7] = n.userType, e[8] = o) : o = e[8];
|
|
1943
|
+
const s = o;
|
|
1944
|
+
let a;
|
|
1945
|
+
e[9] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ d("img", { src: ke, alt: "Docthub Logo", width: 46, height: 46 }), e[9] = a) : a = e[9];
|
|
1946
|
+
const c = a;
|
|
1947
|
+
let u;
|
|
1948
|
+
e[10] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (u = /* @__PURE__ */ d(F, { variant: "h5", weight: "extraBold", align: "center", className: "text-neutral-black mt-4 md:mt-6 -mb-1", children: "Welcome to Docthub" }), e[10] = u) : u = e[10];
|
|
1949
|
+
const h = u, f = n.userType === "FOREIGN" ? "email" : n.signupCollectField;
|
|
1950
|
+
let m;
|
|
1951
|
+
e[11] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */ d("span", { className: "font-bold", children: "Full Name" }), e[11] = m) : m = e[11];
|
|
1952
|
+
const g = f === "phone" ? "Phone Number" : "Email Address";
|
|
1953
|
+
let b;
|
|
1954
|
+
e[12] !== g ? (b = /* @__PURE__ */ k(F, { variant: "title2", align: "center", className: "mb-4 md:mb-6", children: [
|
|
1955
|
+
"Please tell us your ",
|
|
1956
|
+
m,
|
|
1957
|
+
" and",
|
|
1958
|
+
" ",
|
|
1959
|
+
/* @__PURE__ */ d("span", { className: "font-bold", children: g }),
|
|
1960
|
+
" ",
|
|
1961
|
+
"for extended security of your account."
|
|
1962
|
+
] }), e[12] = g, e[13] = b) : b = e[13];
|
|
1963
|
+
const p = b;
|
|
1964
|
+
let y;
|
|
1965
|
+
e[14] !== s ? (y = /* @__PURE__ */ d(Mn, { ...s }), e[14] = s, e[15] = y) : y = e[15];
|
|
1966
|
+
let x;
|
|
1967
|
+
return e[16] !== p || e[17] !== i || e[18] !== y || e[19] !== r ? (x = /* @__PURE__ */ d(X, { layoutType: i, variant: r, contentWidth: "sm", logo: c, title: h, description: p, children: y }), e[16] = p, e[17] = i, e[18] = y, e[19] = r, e[20] = x) : x = e[20], x;
|
|
1968
|
+
}
|
|
1969
|
+
function jn() {
|
|
1970
|
+
const n = E.c(1);
|
|
1971
|
+
let e;
|
|
1972
|
+
return n[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ d("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ d("path", { d: "M6 6L18 18M18 6L6 18", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" }) }), n[0] = e) : e = n[0], e;
|
|
1973
|
+
}
|
|
1974
|
+
function Un(n) {
|
|
1975
|
+
const e = E.c(47), {
|
|
1976
|
+
open: t,
|
|
1977
|
+
value: l,
|
|
1978
|
+
onOpenChange: i,
|
|
1979
|
+
onSave: r
|
|
1980
|
+
} = n, o = ft(), s = Tn("(max-width: 767px)"), [a, c] = z(l), [u, h] = z("");
|
|
1981
|
+
let f, m;
|
|
1982
|
+
e[0] !== t || e[1] !== l ? (f = () => {
|
|
1983
|
+
t && (c(l), h(""));
|
|
1984
|
+
}, m = [t, l], e[0] = t, e[1] = l, e[2] = f, e[3] = m) : (f = e[2], m = e[3]), q(f, m);
|
|
1985
|
+
let g, b;
|
|
1986
|
+
if (e[4] !== i || e[5] !== t ? (g = () => {
|
|
1987
|
+
if (!t)
|
|
1988
|
+
return;
|
|
1989
|
+
const D = (G) => {
|
|
1990
|
+
G.key === "Escape" && i(!1);
|
|
1991
|
+
};
|
|
1992
|
+
document.addEventListener("keydown", D);
|
|
1993
|
+
const B = document.body.style.overflow;
|
|
1994
|
+
return document.body.style.overflow = "hidden", () => {
|
|
1995
|
+
document.removeEventListener("keydown", D), document.body.style.overflow = B;
|
|
1996
|
+
};
|
|
1997
|
+
}, b = [t, i], e[4] = i, e[5] = t, e[6] = g, e[7] = b) : (g = e[6], b = e[7]), q(g, b), !t)
|
|
1998
|
+
return null;
|
|
1999
|
+
let p;
|
|
2000
|
+
e[8] !== a || e[9] !== i || e[10] !== r ? (p = () => {
|
|
2001
|
+
const D = oe.safeParse(a);
|
|
2002
|
+
if (!D.success) {
|
|
2003
|
+
h(D.error.issues[0]?.message ?? "Enter a valid full name");
|
|
2004
|
+
return;
|
|
2005
|
+
}
|
|
2006
|
+
r(D.data), i(!1);
|
|
2007
|
+
}, e[8] = a, e[9] = i, e[10] = r, e[11] = p) : p = e[11];
|
|
2008
|
+
const y = p, x = s ? "fixed inset-x-0 bottom-0 z-50 flex max-h-[90vh] w-full flex-col overflow-hidden rounded-t-2xl border border-black/10 bg-white" : "relative z-50 flex w-full max-w-[480px] flex-col overflow-hidden rounded-2xl border border-black/10 bg-white shadow-lg";
|
|
2009
|
+
let v;
|
|
2010
|
+
e[12] !== o ? (v = /* @__PURE__ */ d("div", { className: "flex flex-1 items-center py-[18px]", children: /* @__PURE__ */ d("h2", { id: o, className: "text-[16px] font-semibold leading-[22px] text-black/80", children: "Edit Name" }) }), e[12] = o, e[13] = v) : v = e[13];
|
|
2011
|
+
let C;
|
|
2012
|
+
e[14] !== i ? (C = () => {
|
|
2013
|
+
i(!1);
|
|
2014
|
+
}, e[14] = i, e[15] = C) : C = e[15];
|
|
2015
|
+
let N;
|
|
2016
|
+
e[16] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (N = /* @__PURE__ */ d(jn, {}), e[16] = N) : N = e[16];
|
|
2017
|
+
let S;
|
|
2018
|
+
e[17] !== C ? (S = /* @__PURE__ */ d("button", { type: "button", "aria-label": "Close", className: "flex size-12 shrink-0 items-center justify-center text-black/80", onClick: C, children: N }), e[17] = C, e[18] = S) : S = e[18];
|
|
2019
|
+
let _;
|
|
2020
|
+
e[19] !== S || e[20] !== v ? (_ = /* @__PURE__ */ k("div", { className: "flex items-start justify-between border-b border-black/10 pl-4", children: [
|
|
2021
|
+
v,
|
|
2022
|
+
S
|
|
2023
|
+
] }), e[19] = S, e[20] = v, e[21] = _) : _ = e[21];
|
|
2024
|
+
let w, P;
|
|
2025
|
+
e[22] !== u ? (w = (D) => {
|
|
2026
|
+
const B = D.target?.value;
|
|
2027
|
+
c(B ?? ""), u && h("");
|
|
2028
|
+
}, P = u ? {
|
|
2029
|
+
error: u
|
|
2030
|
+
} : {}, e[22] = u, e[23] = w, e[24] = P) : (w = e[23], P = e[24]);
|
|
2031
|
+
let A;
|
|
2032
|
+
e[25] !== a || e[26] !== w || e[27] !== P ? (A = /* @__PURE__ */ d("div", { className: "flex w-full flex-col px-4 py-5", children: /* @__PURE__ */ d(He, { label: "Full Name", value: a, autoFocus: !0, onChange: w, ...P, className: "w-full" }) }), e[25] = a, e[26] = w, e[27] = P, e[28] = A) : A = e[28];
|
|
2033
|
+
let I;
|
|
2034
|
+
e[29] !== i ? (I = /* @__PURE__ */ d(U, { type: "button", variant: "outline", size: "large", fullWidth: !0, onClick: () => {
|
|
2035
|
+
i(!1);
|
|
2036
|
+
}, className: "!rounded-xl !border-0 !bg-black/10 !text-[16px] !font-semibold !leading-[22px] !text-black/80 hover:!bg-black/10", children: "Cancel" }), e[29] = i, e[30] = I) : I = e[30];
|
|
2037
|
+
let $;
|
|
2038
|
+
e[31] !== y ? ($ = /* @__PURE__ */ d(U, { type: "button", variant: "primary", size: "large", fullWidth: !0, onClick: y, className: "!rounded-xl !text-[16px] !font-semibold !leading-[22px]", children: "Save" }), e[31] = y, e[32] = $) : $ = e[32];
|
|
2039
|
+
let O;
|
|
2040
|
+
e[33] !== I || e[34] !== $ ? (O = /* @__PURE__ */ k("div", { className: "flex gap-2 border-t border-black/10 bg-[#fafafa] p-4", children: [
|
|
2041
|
+
I,
|
|
2042
|
+
$
|
|
2043
|
+
] }), e[33] = I, e[34] = $, e[35] = O) : O = e[35];
|
|
2044
|
+
let L;
|
|
2045
|
+
e[36] !== _ || e[37] !== A || e[38] !== O || e[39] !== x || e[40] !== o ? (L = /* @__PURE__ */ k("div", { role: "dialog", "aria-modal": "true", "aria-labelledby": o, className: x, children: [
|
|
2046
|
+
_,
|
|
2047
|
+
A,
|
|
2048
|
+
O
|
|
2049
|
+
] }), e[36] = _, e[37] = A, e[38] = O, e[39] = x, e[40] = o, e[41] = L) : L = e[41];
|
|
2050
|
+
const R = L;
|
|
2051
|
+
let W;
|
|
2052
|
+
e[42] !== i ? (W = /* @__PURE__ */ d("button", { type: "button", "aria-label": "Close edit name dialog", className: "absolute inset-0 bg-black/40", onClick: () => {
|
|
2053
|
+
i(!1);
|
|
2054
|
+
} }), e[42] = i, e[43] = W) : W = e[43];
|
|
2055
|
+
let T;
|
|
2056
|
+
return e[44] !== R || e[45] !== W ? (T = /* @__PURE__ */ k("div", { className: "fixed inset-0 z-50 flex items-end justify-center md:items-center md:p-4", children: [
|
|
2057
|
+
W,
|
|
2058
|
+
R
|
|
2059
|
+
] }), e[44] = R, e[45] = W, e[46] = T) : T = e[46], T;
|
|
2060
|
+
}
|
|
2061
|
+
function zn(n) {
|
|
2062
|
+
const e = E.c(34), {
|
|
2063
|
+
fullName: t,
|
|
2064
|
+
collectField: l,
|
|
2065
|
+
isSubmitting: i,
|
|
2066
|
+
onEditName: r,
|
|
2067
|
+
onSkip: o,
|
|
2068
|
+
handleSubmit: s
|
|
2069
|
+
} = n, a = Q(), c = l === "phone" ? "mobile number" : "email address";
|
|
2070
|
+
let u;
|
|
2071
|
+
e[0] !== t || e[1] !== r || e[2] !== o ? (u = () => {
|
|
2072
|
+
const w = oe.safeParse(t);
|
|
2073
|
+
if (!w.success) {
|
|
2074
|
+
r();
|
|
2075
|
+
return;
|
|
2076
|
+
}
|
|
2077
|
+
o?.({
|
|
2078
|
+
fullName: w.data
|
|
2079
|
+
});
|
|
2080
|
+
}, e[0] = t, e[1] = r, e[2] = o, e[3] = u) : u = e[3];
|
|
2081
|
+
const h = u;
|
|
2082
|
+
let f;
|
|
2083
|
+
e[4] !== s || e[5] !== a ? (f = a.handleSubmit(s), e[4] = s, e[5] = a, e[6] = f) : f = e[6];
|
|
2084
|
+
const m = t || "Your name";
|
|
2085
|
+
let g;
|
|
2086
|
+
e[7] !== m ? (g = /* @__PURE__ */ d(F, { variant: "h5", weight: "extraBold", align: "center", className: "text-[28px] leading-9 text-black", children: m }), e[7] = m, e[8] = g) : g = e[8];
|
|
2087
|
+
let b;
|
|
2088
|
+
e[9] !== r ? (b = /* @__PURE__ */ d("button", { type: "button", onClick: r, className: "rounded-[14px] px-1 py-2 text-[12px] font-semibold leading-4 text-[#4389ff]", children: "Edit name" }), e[9] = r, e[10] = b) : b = e[10];
|
|
2089
|
+
let p;
|
|
2090
|
+
e[11] !== g || e[12] !== b ? (p = /* @__PURE__ */ k("div", { className: "mb-5 flex w-full flex-col items-center gap-1.5", children: [
|
|
2091
|
+
g,
|
|
2092
|
+
b
|
|
2093
|
+
] }), e[11] = g, e[12] = b, e[13] = p) : p = e[13];
|
|
2094
|
+
let y;
|
|
2095
|
+
e[14] !== c ? (y = /* @__PURE__ */ k(F, { variant: "body1", align: "center", className: "mb-4 w-full text-[16px] font-normal leading-6 text-black", children: [
|
|
2096
|
+
"Add your ",
|
|
2097
|
+
/* @__PURE__ */ d("span", { className: "font-bold", children: c }),
|
|
2098
|
+
" for extended security of your account."
|
|
2099
|
+
] }), e[14] = c, e[15] = y) : y = e[15];
|
|
2100
|
+
let x;
|
|
2101
|
+
e[16] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (x = /* @__PURE__ */ d(ge, { name: "phone", label: "", placeholder: "Enter number", countryCode: "+91", countryCodeName: "countryCode", defaultCountry: "IN" }), e[16] = x) : x = e[16];
|
|
2102
|
+
let v;
|
|
2103
|
+
e[17] !== i ? (v = i ? /* @__PURE__ */ d(re, { size: 32, strokeWidth: 2 }) : "Continue", e[17] = i, e[18] = v) : v = e[18];
|
|
2104
|
+
let C;
|
|
2105
|
+
e[19] !== i || e[20] !== v ? (C = /* @__PURE__ */ d(U, { type: "submit", variant: "primary", size: "large", fullWidth: !0, disabled: i, className: "!rounded-xl", children: v }), e[19] = i, e[20] = v, e[21] = C) : C = e[21];
|
|
2106
|
+
let N;
|
|
2107
|
+
e[22] !== h || e[23] !== i || e[24] !== o ? (N = o ? /* @__PURE__ */ d("button", { type: "button", onClick: h, disabled: i, className: "mx-auto rounded-[14px] px-1 py-2 text-[12px] font-semibold leading-4 text-black/80 disabled:opacity-50", children: "Skip" }) : null, e[22] = h, e[23] = i, e[24] = o, e[25] = N) : N = e[25];
|
|
2108
|
+
let S;
|
|
2109
|
+
e[26] !== C || e[27] !== N ? (S = /* @__PURE__ */ k("div", { className: "flex w-full flex-col gap-4", children: [
|
|
2110
|
+
x,
|
|
2111
|
+
C,
|
|
2112
|
+
N
|
|
2113
|
+
] }), e[26] = C, e[27] = N, e[28] = S) : S = e[28];
|
|
2114
|
+
let _;
|
|
2115
|
+
return e[29] !== S || e[30] !== f || e[31] !== p || e[32] !== y ? (_ = /* @__PURE__ */ k("form", { onSubmit: f, className: "flex w-full flex-col items-center", noValidate: !0, children: [
|
|
2116
|
+
p,
|
|
2117
|
+
y,
|
|
2118
|
+
S
|
|
2119
|
+
] }), e[29] = S, e[30] = f, e[31] = p, e[32] = y, e[33] = _) : _ = e[33], _;
|
|
2120
|
+
}
|
|
2121
|
+
function Bn(n) {
|
|
2122
|
+
const e = E.c(23), {
|
|
2123
|
+
fullName: t,
|
|
2124
|
+
collectField: l,
|
|
2125
|
+
onSubmit: i,
|
|
2126
|
+
submitApi: r,
|
|
2127
|
+
onSuccess: o,
|
|
2128
|
+
onError: s,
|
|
2129
|
+
onSkip: a
|
|
2130
|
+
} = n, c = t === void 0 ? "" : t, u = l === void 0 ? "phone" : l, [h, f] = z(!1);
|
|
2131
|
+
let m;
|
|
2132
|
+
e[0] !== c || e[1] !== s || e[2] !== i || e[3] !== o || e[4] !== r ? (m = {
|
|
2133
|
+
initialFullName: c,
|
|
2134
|
+
onSubmit: i,
|
|
2135
|
+
submitApi: r,
|
|
2136
|
+
onSuccess: o,
|
|
2137
|
+
onError: s
|
|
2138
|
+
}, e[0] = c, e[1] = s, e[2] = i, e[3] = o, e[4] = r, e[5] = m) : m = e[5];
|
|
2139
|
+
const {
|
|
2140
|
+
methods: g,
|
|
2141
|
+
handleSubmit: b,
|
|
2142
|
+
isSubmitting: p,
|
|
2143
|
+
fullName: y,
|
|
2144
|
+
setFullName: x
|
|
2145
|
+
} = Dn(m);
|
|
2146
|
+
let v;
|
|
2147
|
+
e[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (v = () => {
|
|
2148
|
+
f(!0);
|
|
2149
|
+
}, e[6] = v) : v = e[6];
|
|
2150
|
+
let C;
|
|
2151
|
+
e[7] !== u || e[8] !== y || e[9] !== b || e[10] !== p || e[11] !== a ? (C = /* @__PURE__ */ d(zn, { fullName: y, collectField: u, isSubmitting: p, onEditName: v, onSkip: a, handleSubmit: b }), e[7] = u, e[8] = y, e[9] = b, e[10] = p, e[11] = a, e[12] = C) : C = e[12];
|
|
2152
|
+
let N;
|
|
2153
|
+
e[13] !== g || e[14] !== C ? (N = /* @__PURE__ */ d(ve, { ...g, children: C }), e[13] = g, e[14] = C, e[15] = N) : N = e[15];
|
|
2154
|
+
let S;
|
|
2155
|
+
e[16] !== y || e[17] !== h || e[18] !== x ? (S = /* @__PURE__ */ d(Un, { open: h, value: y, onOpenChange: f, onSave: x }), e[16] = y, e[17] = h, e[18] = x, e[19] = S) : S = e[19];
|
|
2156
|
+
let _;
|
|
2157
|
+
return e[20] !== N || e[21] !== S ? (_ = /* @__PURE__ */ k(_e, { children: [
|
|
2158
|
+
N,
|
|
2159
|
+
S
|
|
2160
|
+
] }), e[20] = N, e[21] = S, e[22] = _) : _ = e[22], _;
|
|
2161
|
+
}
|
|
2162
|
+
function il(n) {
|
|
2163
|
+
const e = E.c(16), {
|
|
2164
|
+
layoutType: t,
|
|
2165
|
+
variant: l,
|
|
2166
|
+
collectField: i
|
|
2167
|
+
} = n, r = t === void 0 ? "standalone" : t, o = l === void 0 ? "mobile" : l, s = i === void 0 ? "phone" : i;
|
|
2168
|
+
let a;
|
|
2169
|
+
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ d("img", { src: ke, alt: "Docthub Logo", width: 48, height: 48 }), e[0] = a) : a = e[0];
|
|
2170
|
+
const c = a;
|
|
2171
|
+
let u;
|
|
2172
|
+
e[1] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (u = /* @__PURE__ */ d(F, { variant: "h5", weight: "bold", align: "center", className: "mt-6 text-[14px] leading-[21px] text-black", children: "Welcome to Docthub" }), e[1] = u) : u = e[1];
|
|
2173
|
+
const h = u;
|
|
2174
|
+
let f;
|
|
2175
|
+
e[2] !== s || e[3] !== n.fullName || e[4] !== n.onError || e[5] !== n.onSkip || e[6] !== n.onSubmit || e[7] !== n.onSuccess || e[8] !== n.submitApi ? (f = {
|
|
2176
|
+
fullName: n.fullName,
|
|
2177
|
+
collectField: s,
|
|
2178
|
+
onSubmit: n.onSubmit,
|
|
2179
|
+
submitApi: n.submitApi,
|
|
2180
|
+
onSuccess: n.onSuccess,
|
|
2181
|
+
onError: n.onError,
|
|
2182
|
+
onSkip: n.onSkip
|
|
2183
|
+
}, e[2] = s, e[3] = n.fullName, e[4] = n.onError, e[5] = n.onSkip, e[6] = n.onSubmit, e[7] = n.onSuccess, e[8] = n.submitApi, e[9] = f) : f = e[9];
|
|
2184
|
+
const m = f;
|
|
2185
|
+
let g;
|
|
2186
|
+
e[10] !== m ? (g = /* @__PURE__ */ d(Bn, { ...m }), e[10] = m, e[11] = g) : g = e[11];
|
|
2187
|
+
let b;
|
|
2188
|
+
return e[12] !== r || e[13] !== g || e[14] !== o ? (b = /* @__PURE__ */ d(X, { layoutType: r, variant: o, contentWidth: "sm", logo: c, title: h, className: xe, children: g }), e[12] = r, e[13] = g, e[14] = o, e[15] = b) : b = e[15], b;
|
|
2189
|
+
}
|
|
2190
|
+
export {
|
|
2191
|
+
X as A,
|
|
2192
|
+
Ne as B,
|
|
2193
|
+
Yt as D,
|
|
2194
|
+
vt as E,
|
|
2195
|
+
Ot as I,
|
|
2196
|
+
Qn as L,
|
|
2197
|
+
el as M,
|
|
2198
|
+
Ze as O,
|
|
2199
|
+
$n as R,
|
|
2200
|
+
Mn as S,
|
|
2201
|
+
Bn as W,
|
|
2202
|
+
bn as a,
|
|
2203
|
+
Zn as b,
|
|
2204
|
+
tl as c,
|
|
2205
|
+
Jn as d,
|
|
2206
|
+
nl as e,
|
|
2207
|
+
ll as f,
|
|
2208
|
+
il as g,
|
|
2209
|
+
E as h,
|
|
2210
|
+
Y as i,
|
|
2211
|
+
Tt as j,
|
|
2212
|
+
Xn as k,
|
|
2213
|
+
fn as l,
|
|
2214
|
+
Ye as m,
|
|
2215
|
+
Lt as n,
|
|
2216
|
+
he as o,
|
|
2217
|
+
Ht as p,
|
|
2218
|
+
Gt as q,
|
|
2219
|
+
Re as r,
|
|
2220
|
+
gn as s,
|
|
2221
|
+
it as t,
|
|
2222
|
+
Rt as u,
|
|
2223
|
+
Tn as v,
|
|
2224
|
+
Jt as w,
|
|
2225
|
+
In as x,
|
|
2226
|
+
Rn as y,
|
|
2227
|
+
Dn as z
|
|
2228
|
+
};
|