doct-ui-auth-kit 1.0.6 → 1.0.8
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/adapters/http-auth-adapter.d.ts +1 -5
- package/dist/auth/index.d.ts +2 -2
- package/dist/components/form/rhf-doct-phone-input.d.ts +2 -1
- package/dist/components/form/rhf-input-field.d.ts +2 -1
- package/dist/components/form/rhf-otp-input-field.d.ts +2 -1
- package/dist/components/layout/auth-layout-preset.d.ts +7 -2
- package/dist/components/layout/auth-layout-public.d.ts +8 -12
- package/dist/components/layout/auth-layout-wrapper.d.ts +39 -3
- package/dist/components/layout/auth-layout.d.ts +1 -1
- package/dist/components/layout/image-slider.d.ts +2 -2
- package/dist/components/layout/index.d.ts +1 -1
- package/dist/components/layout/main-layout.d.ts +2 -2
- package/dist/constants/layout-presets.d.ts +1 -5
- package/dist/core/auth-api-adapter.d.ts +1 -1
- package/dist/core/auth-context.d.ts +5 -5
- package/dist/core/auth-flow.d.ts +2 -2
- package/dist/core/auth-provider.d.ts +5 -3
- package/dist/core/auth-types.d.ts +1 -1
- package/dist/core/device-detection.d.ts +2 -6
- package/dist/core/sso-session.d.ts +2 -6
- package/dist/core/use-auth-flow.d.ts +2 -6
- package/dist/doct-ui-auth-kit.css +1 -1
- package/dist/hooks/use-login-entry-form.d.ts +8 -4
- package/dist/hooks/use-main-auth-page-handlers.d.ts +6 -5
- package/dist/hooks/use-otp-verification.d.ts +7 -4
- package/dist/hooks/use-repeat-login.d.ts +6 -4
- package/dist/hooks/use-signup-form.d.ts +8 -3
- package/dist/index.d.ts +11 -36
- package/dist/index.js +28 -27
- package/dist/pages/index.d.ts +4 -1
- package/dist/pages/login-entry/index.d.ts +3 -0
- package/dist/pages/login-entry/login-entry-page.d.ts +21 -0
- package/dist/pages/login-entry/login-entry.d.ts +21 -0
- package/dist/pages/main-login/index.d.ts +3 -0
- package/dist/pages/main-login/main-login-page.d.ts +16 -0
- package/dist/pages/main-login/main-login.d.ts +25 -0
- package/dist/pages/otp-verification/index.d.ts +3 -0
- package/dist/pages/otp-verification/otp-verification-page.d.ts +23 -0
- package/dist/pages/otp-verification/otp-verification.d.ts +22 -0
- package/dist/pages/repeat-login/index.d.ts +3 -0
- package/dist/pages/repeat-login/repeat-login-page.d.ts +24 -0
- package/dist/pages/repeat-login/repeat-login.d.ts +25 -0
- package/dist/pages/signup/index.d.ts +3 -0
- package/dist/pages/signup/signup-page.d.ts +6 -0
- package/dist/pages/signup/signup.d.ts +7 -0
- package/dist/pages.js +1 -1
- package/dist/signup-page-DBRzdhNj.js +1546 -0
- package/dist/types/{auth-api-adapter.d.ts → auth/auth-api-adapter.d.ts} +1 -5
- package/dist/types/{auth-provider.d.ts → auth/auth-provider.d.ts} +7 -4
- package/dist/types/auth/device-detection.d.ts +10 -0
- package/dist/types/{flow.d.ts → auth/flow.d.ts} +1 -4
- package/dist/types/auth/index.d.ts +9 -0
- package/dist/types/{auth-layout-types.d.ts → components/auth-layout-types.d.ts} +1 -1
- package/dist/types/components/forms.d.ts +68 -0
- package/dist/types/components/index.d.ts +7 -0
- package/dist/types/{layout-presets.d.ts → components/layout-presets.d.ts} +1 -6
- package/dist/types/{layout.d.ts → components/layout.d.ts} +1 -1
- package/dist/types/index.d.ts +4 -17
- package/dist/types/pages/index.d.ts +9 -0
- package/dist/types/{login-form.d.ts → pages/login-form.d.ts} +13 -6
- package/dist/types/{main-login.d.ts → pages/main-login.d.ts} +11 -0
- package/dist/types/{otp-verification.d.ts → pages/otp-verification.d.ts} +16 -6
- package/dist/types/{pages.d.ts → pages/pages.d.ts} +32 -35
- package/dist/types/{repeat-login.d.ts → pages/repeat-login.d.ts} +7 -6
- package/dist/types/{signup-form.d.ts → pages/signup-form.d.ts} +14 -7
- package/dist/utils/set-form-errors-from-zod.d.ts +1 -1
- package/dist/validations/schemas.d.ts +0 -4
- package/package.json +2 -2
- package/dist/pages/login-entry.d.ts +0 -42
- package/dist/pages/main-login.d.ts +0 -32
- package/dist/pages/otp-verification.d.ts +0 -45
- package/dist/pages/repeat-login.d.ts +0 -49
- package/dist/pages/signup.d.ts +0 -4
- package/dist/signup-DeeuWsoF.js +0 -1718
- package/dist/types/device-detection.d.ts +0 -7
- package/dist/types/forms.d.ts +0 -42
- /package/dist/{stories/components → components/common}/default-footer.d.ts +0 -0
- /package/dist/{stories/components → components/common}/enterprise-header.d.ts +0 -0
- /package/dist/{stories/components → components/common}/index.d.ts +0 -0
- /package/dist/types/{auth-types.d.ts → auth/auth-types.d.ts} +0 -0
- /package/dist/types/{sso-session.d.ts → auth/sso-session.d.ts} +0 -0
|
@@ -0,0 +1,1546 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as L, jsx as d, Fragment as Ve } from "react/jsx-runtime";
|
|
3
|
+
import { DoctTypography as T, DoctButton as M, DoctPhoneInput as qe, DoctLabeledInput as Ye, DoctOtpInput as Ke } from "docthub-core-components";
|
|
4
|
+
import G, { createContext as Xe, useContext as Ze, useState as q, useEffect as te, useRef as le } from "react";
|
|
5
|
+
import { useFormContext as ne, Controller as be, useForm as ve, FormProvider as ye } from "react-hook-form";
|
|
6
|
+
import { z as W } from "zod";
|
|
7
|
+
var ae = { exports: {} }, he = {};
|
|
8
|
+
var Ee;
|
|
9
|
+
function Je() {
|
|
10
|
+
if (Ee) return he;
|
|
11
|
+
Ee = 1;
|
|
12
|
+
var n = G.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
|
|
13
|
+
return he.c = function(e) {
|
|
14
|
+
return n.H.useMemoCache(e);
|
|
15
|
+
}, he;
|
|
16
|
+
}
|
|
17
|
+
var ge = {};
|
|
18
|
+
var Pe;
|
|
19
|
+
function Qe() {
|
|
20
|
+
return Pe || (Pe = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
21
|
+
var n = G.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
|
|
22
|
+
ge.c = function(e) {
|
|
23
|
+
var t = n.H;
|
|
24
|
+
return t === null && console.error(
|
|
25
|
+
`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:
|
|
26
|
+
1. You might have mismatching versions of React and the renderer (such as React DOM)
|
|
27
|
+
2. You might be breaking the Rules of Hooks
|
|
28
|
+
3. You might have more than one copy of React in the same app
|
|
29
|
+
See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`
|
|
30
|
+
), t.useMemoCache(e);
|
|
31
|
+
};
|
|
32
|
+
})()), ge;
|
|
33
|
+
}
|
|
34
|
+
var Oe;
|
|
35
|
+
function et() {
|
|
36
|
+
return Oe || (Oe = 1, process.env.NODE_ENV === "production" ? ae.exports = Je() : ae.exports = Qe()), ae.exports;
|
|
37
|
+
}
|
|
38
|
+
var _ = et(), Me = {
|
|
39
|
+
color: void 0,
|
|
40
|
+
size: void 0,
|
|
41
|
+
className: void 0,
|
|
42
|
+
style: void 0,
|
|
43
|
+
attr: void 0
|
|
44
|
+
}, Ae = G.createContext && /* @__PURE__ */ G.createContext(Me), tt = ["attr", "size", "title"];
|
|
45
|
+
function nt(n, e) {
|
|
46
|
+
if (n == null) return {};
|
|
47
|
+
var t = lt(n, e), l, o;
|
|
48
|
+
if (Object.getOwnPropertySymbols) {
|
|
49
|
+
var r = Object.getOwnPropertySymbols(n);
|
|
50
|
+
for (o = 0; o < r.length; o++)
|
|
51
|
+
l = r[o], !(e.indexOf(l) >= 0) && Object.prototype.propertyIsEnumerable.call(n, l) && (t[l] = n[l]);
|
|
52
|
+
}
|
|
53
|
+
return t;
|
|
54
|
+
}
|
|
55
|
+
function lt(n, e) {
|
|
56
|
+
if (n == null) return {};
|
|
57
|
+
var t = {};
|
|
58
|
+
for (var l in n)
|
|
59
|
+
if (Object.prototype.hasOwnProperty.call(n, l)) {
|
|
60
|
+
if (e.indexOf(l) >= 0) continue;
|
|
61
|
+
t[l] = n[l];
|
|
62
|
+
}
|
|
63
|
+
return t;
|
|
64
|
+
}
|
|
65
|
+
function ue() {
|
|
66
|
+
return ue = Object.assign ? Object.assign.bind() : function(n) {
|
|
67
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
68
|
+
var t = arguments[e];
|
|
69
|
+
for (var l in t)
|
|
70
|
+
Object.prototype.hasOwnProperty.call(t, l) && (n[l] = t[l]);
|
|
71
|
+
}
|
|
72
|
+
return n;
|
|
73
|
+
}, ue.apply(this, arguments);
|
|
74
|
+
}
|
|
75
|
+
function Te(n, e) {
|
|
76
|
+
var t = Object.keys(n);
|
|
77
|
+
if (Object.getOwnPropertySymbols) {
|
|
78
|
+
var l = Object.getOwnPropertySymbols(n);
|
|
79
|
+
e && (l = l.filter(function(o) {
|
|
80
|
+
return Object.getOwnPropertyDescriptor(n, o).enumerable;
|
|
81
|
+
})), t.push.apply(t, l);
|
|
82
|
+
}
|
|
83
|
+
return t;
|
|
84
|
+
}
|
|
85
|
+
function de(n) {
|
|
86
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
87
|
+
var t = arguments[e] != null ? arguments[e] : {};
|
|
88
|
+
e % 2 ? Te(Object(t), !0).forEach(function(l) {
|
|
89
|
+
it(n, l, t[l]);
|
|
90
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : Te(Object(t)).forEach(function(l) {
|
|
91
|
+
Object.defineProperty(n, l, Object.getOwnPropertyDescriptor(t, l));
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
return n;
|
|
95
|
+
}
|
|
96
|
+
function it(n, e, t) {
|
|
97
|
+
return e = ot(e), e in n ? Object.defineProperty(n, e, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : n[e] = t, n;
|
|
98
|
+
}
|
|
99
|
+
function ot(n) {
|
|
100
|
+
var e = rt(n, "string");
|
|
101
|
+
return typeof e == "symbol" ? e : e + "";
|
|
102
|
+
}
|
|
103
|
+
function rt(n, e) {
|
|
104
|
+
if (typeof n != "object" || !n) return n;
|
|
105
|
+
var t = n[Symbol.toPrimitive];
|
|
106
|
+
if (t !== void 0) {
|
|
107
|
+
var l = t.call(n, e);
|
|
108
|
+
if (typeof l != "object") return l;
|
|
109
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
110
|
+
}
|
|
111
|
+
return (e === "string" ? String : Number)(n);
|
|
112
|
+
}
|
|
113
|
+
function ke(n) {
|
|
114
|
+
return n && n.map((e, t) => /* @__PURE__ */ G.createElement(e.tag, de({
|
|
115
|
+
key: t
|
|
116
|
+
}, e.attr), ke(e.child)));
|
|
117
|
+
}
|
|
118
|
+
function me(n) {
|
|
119
|
+
return (e) => /* @__PURE__ */ G.createElement(st, ue({
|
|
120
|
+
attr: de({}, n.attr)
|
|
121
|
+
}, e), ke(n.child));
|
|
122
|
+
}
|
|
123
|
+
function st(n) {
|
|
124
|
+
var e = (t) => {
|
|
125
|
+
var {
|
|
126
|
+
attr: l,
|
|
127
|
+
size: o,
|
|
128
|
+
title: r
|
|
129
|
+
} = n, i = nt(n, tt), a = o || t.size || "1em", s;
|
|
130
|
+
return t.className && (s = t.className), n.className && (s = (s ? s + " " : "") + n.className), /* @__PURE__ */ G.createElement("svg", ue({
|
|
131
|
+
stroke: "currentColor",
|
|
132
|
+
fill: "currentColor",
|
|
133
|
+
strokeWidth: "0"
|
|
134
|
+
}, t.attr, l, i, {
|
|
135
|
+
className: s,
|
|
136
|
+
style: de(de({
|
|
137
|
+
color: n.color || t.color
|
|
138
|
+
}, t.style), n.style),
|
|
139
|
+
height: a,
|
|
140
|
+
width: a,
|
|
141
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
142
|
+
}), r && /* @__PURE__ */ G.createElement("title", null, r), n.children);
|
|
143
|
+
};
|
|
144
|
+
return Ae !== void 0 ? /* @__PURE__ */ G.createElement(Ae.Consumer, null, (t) => e(t)) : e(Me);
|
|
145
|
+
}
|
|
146
|
+
function Se(n) {
|
|
147
|
+
return me({ attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" }, child: [] }] })(n);
|
|
148
|
+
}
|
|
149
|
+
function at(n) {
|
|
150
|
+
return me({ attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z" }, child: [] }] })(n);
|
|
151
|
+
}
|
|
152
|
+
const De = ["/slider/slide-1.png", "/slider/slide-2.png", "/slider/slide-3.png", "/slider/slide-4.png", "/slider/slide-5.png"], ct = 5e3;
|
|
153
|
+
function We(n) {
|
|
154
|
+
var e, t, l = "";
|
|
155
|
+
if (typeof n == "string" || typeof n == "number") l += n;
|
|
156
|
+
else if (typeof n == "object") if (Array.isArray(n)) {
|
|
157
|
+
var o = n.length;
|
|
158
|
+
for (e = 0; e < o; e++) n[e] && (t = We(n[e])) && (l && (l += " "), l += t);
|
|
159
|
+
} else for (t in n) n[t] && (l && (l += " "), l += t);
|
|
160
|
+
return l;
|
|
161
|
+
}
|
|
162
|
+
function I() {
|
|
163
|
+
for (var n, e, t = 0, l = "", o = arguments.length; t < o; t++) (n = arguments[t]) && (e = We(n)) && (l && (l += " "), l += e);
|
|
164
|
+
return l;
|
|
165
|
+
}
|
|
166
|
+
const $e = Xe(null);
|
|
167
|
+
function xe() {
|
|
168
|
+
const n = Ze($e);
|
|
169
|
+
if (!n)
|
|
170
|
+
throw new Error("AuthLayout compound components must be used within AuthLayout.Root");
|
|
171
|
+
return n;
|
|
172
|
+
}
|
|
173
|
+
function ut(n, e) {
|
|
174
|
+
return e === "md" ? "max-w-md" : e === "lg" ? "max-w-lg" : n === "desktop" ? "max-w-[320px]" : "max-w-[360px]";
|
|
175
|
+
}
|
|
176
|
+
function we(n = "center") {
|
|
177
|
+
switch (n) {
|
|
178
|
+
case "left":
|
|
179
|
+
return {
|
|
180
|
+
flex: "justify-start",
|
|
181
|
+
text: "text-left"
|
|
182
|
+
};
|
|
183
|
+
case "right":
|
|
184
|
+
return {
|
|
185
|
+
flex: "justify-end",
|
|
186
|
+
text: "text-right"
|
|
187
|
+
};
|
|
188
|
+
default:
|
|
189
|
+
return {
|
|
190
|
+
flex: "justify-center",
|
|
191
|
+
text: "text-center"
|
|
192
|
+
};
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
function dt(n) {
|
|
196
|
+
const e = _.c(18), {
|
|
197
|
+
children: t,
|
|
198
|
+
variant: l,
|
|
199
|
+
maxWidth: o,
|
|
200
|
+
className: r,
|
|
201
|
+
contentClassName: i
|
|
202
|
+
} = n, a = l === void 0 ? "mobile" : l, s = o === void 0 ? "sm" : o;
|
|
203
|
+
let c;
|
|
204
|
+
e[0] !== s || e[1] !== a ? (c = ut(a, s), e[0] = s, e[1] = a, e[2] = c) : c = e[2];
|
|
205
|
+
const m = c;
|
|
206
|
+
let h;
|
|
207
|
+
e[3] !== s || e[4] !== m || e[5] !== a ? (h = {
|
|
208
|
+
variant: a,
|
|
209
|
+
maxWidth: s,
|
|
210
|
+
maxWidthClass: m
|
|
211
|
+
}, e[3] = s, e[4] = m, e[5] = a, e[6] = h) : h = e[6];
|
|
212
|
+
const u = h;
|
|
213
|
+
let f;
|
|
214
|
+
e[7] !== r ? (f = I("min-h-svh w-full bg-white flex flex-col", r), e[7] = r, e[8] = f) : f = e[8];
|
|
215
|
+
let b;
|
|
216
|
+
e[9] !== t || e[10] !== f ? (b = /* @__PURE__ */ d("div", { className: f, children: t }), e[9] = t, e[10] = f, e[11] = b) : b = e[11];
|
|
217
|
+
let g;
|
|
218
|
+
e[12] !== i ? (g = /* @__PURE__ */ d("div", { className: "hidden", children: i }), e[12] = i, e[13] = g) : g = e[13];
|
|
219
|
+
let p;
|
|
220
|
+
return e[14] !== u || e[15] !== b || e[16] !== g ? (p = /* @__PURE__ */ L($e.Provider, { value: u, children: [
|
|
221
|
+
b,
|
|
222
|
+
g
|
|
223
|
+
] }), e[14] = u, e[15] = b, e[16] = g, e[17] = p) : p = e[17], p;
|
|
224
|
+
}
|
|
225
|
+
function ft(n) {
|
|
226
|
+
const e = _.c(12), {
|
|
227
|
+
children: t,
|
|
228
|
+
className: l
|
|
229
|
+
} = n, {
|
|
230
|
+
variant: o
|
|
231
|
+
} = xe();
|
|
232
|
+
if (o === "desktop") {
|
|
233
|
+
let a;
|
|
234
|
+
e[0] !== l ? (a = I("flex justify-end px-5 pt-5 md:px-[20px] md:pt-[20px]", l), e[0] = l, e[1] = a) : a = e[1];
|
|
235
|
+
let s;
|
|
236
|
+
e[2] !== t ? (s = /* @__PURE__ */ d("div", { className: "w-auto", children: t }), e[2] = t, e[3] = s) : s = e[3];
|
|
237
|
+
let c;
|
|
238
|
+
return e[4] !== a || e[5] !== s ? (c = /* @__PURE__ */ d("div", { className: a, children: s }), e[4] = a, e[5] = s, e[6] = c) : c = e[6], c;
|
|
239
|
+
}
|
|
240
|
+
let r;
|
|
241
|
+
e[7] !== l ? (r = I("mb-4 w-full md:mb-6", l), e[7] = l, e[8] = r) : r = e[8];
|
|
242
|
+
let i;
|
|
243
|
+
return e[9] !== t || e[10] !== r ? (i = /* @__PURE__ */ d("div", { className: r, children: t }), e[9] = t, e[10] = r, e[11] = i) : i = e[11], i;
|
|
244
|
+
}
|
|
245
|
+
function mt(n) {
|
|
246
|
+
const e = _.c(6), {
|
|
247
|
+
children: t,
|
|
248
|
+
align: l,
|
|
249
|
+
className: o
|
|
250
|
+
} = n, r = l === void 0 ? "center" : l;
|
|
251
|
+
let i;
|
|
252
|
+
if (e[0] !== r || e[1] !== o) {
|
|
253
|
+
const {
|
|
254
|
+
flex: s
|
|
255
|
+
} = we(r);
|
|
256
|
+
i = I("flex w-full mb-4 md:mb-6", s, o), e[0] = r, e[1] = o, e[2] = i;
|
|
257
|
+
} else
|
|
258
|
+
i = e[2];
|
|
259
|
+
let a;
|
|
260
|
+
return e[3] !== t || e[4] !== i ? (a = /* @__PURE__ */ d("div", { className: i, children: t }), e[3] = t, e[4] = i, e[5] = a) : a = e[5], a;
|
|
261
|
+
}
|
|
262
|
+
function ht(n) {
|
|
263
|
+
const e = _.c(6), {
|
|
264
|
+
children: t,
|
|
265
|
+
align: l,
|
|
266
|
+
className: o
|
|
267
|
+
} = n, r = l === void 0 ? "center" : l;
|
|
268
|
+
let i;
|
|
269
|
+
if (e[0] !== r || e[1] !== o) {
|
|
270
|
+
const {
|
|
271
|
+
flex: s,
|
|
272
|
+
text: c
|
|
273
|
+
} = we(r);
|
|
274
|
+
i = I("flex w-full mb-4 md:mb-6", s, c, o), e[0] = r, e[1] = o, e[2] = i;
|
|
275
|
+
} else
|
|
276
|
+
i = e[2];
|
|
277
|
+
let a;
|
|
278
|
+
return e[3] !== t || e[4] !== i ? (a = /* @__PURE__ */ d("div", { className: i, children: t }), e[3] = t, e[4] = i, e[5] = a) : a = e[5], a;
|
|
279
|
+
}
|
|
280
|
+
function gt(n) {
|
|
281
|
+
const e = _.c(6), {
|
|
282
|
+
children: t,
|
|
283
|
+
align: l,
|
|
284
|
+
className: o
|
|
285
|
+
} = n, r = l === void 0 ? "center" : l;
|
|
286
|
+
let i;
|
|
287
|
+
if (e[0] !== r || e[1] !== o) {
|
|
288
|
+
const {
|
|
289
|
+
flex: s,
|
|
290
|
+
text: c
|
|
291
|
+
} = we(r);
|
|
292
|
+
i = I("flex w-full mb-4 md:mb-6", s, c, o), e[0] = r, e[1] = o, e[2] = i;
|
|
293
|
+
} else
|
|
294
|
+
i = e[2];
|
|
295
|
+
let a;
|
|
296
|
+
return e[3] !== t || e[4] !== i ? (a = /* @__PURE__ */ d("div", { className: i, children: t }), e[3] = t, e[4] = i, e[5] = a) : a = e[5], a;
|
|
297
|
+
}
|
|
298
|
+
function pt(n) {
|
|
299
|
+
const e = _.c(5), {
|
|
300
|
+
children: t,
|
|
301
|
+
className: l
|
|
302
|
+
} = n;
|
|
303
|
+
let o;
|
|
304
|
+
e[0] !== l ? (o = I("w-full flex flex-col space-y-4 mb-4 md:mb-6", l), e[0] = l, e[1] = o) : o = e[1];
|
|
305
|
+
let r;
|
|
306
|
+
return e[2] !== t || e[3] !== o ? (r = /* @__PURE__ */ d("div", { className: o, children: t }), e[2] = t, e[3] = o, e[4] = r) : r = e[4], r;
|
|
307
|
+
}
|
|
308
|
+
function bt(n) {
|
|
309
|
+
const e = _.c(10), {
|
|
310
|
+
children: t,
|
|
311
|
+
sm: l,
|
|
312
|
+
className: o
|
|
313
|
+
} = n, {
|
|
314
|
+
maxWidthClass: r
|
|
315
|
+
} = xe();
|
|
316
|
+
let i;
|
|
317
|
+
e[0] !== o ? (i = I("flex-1 flex flex-col items-center justify-center", "px-5 py-8 md:py-12", "w-full", o), e[0] = o, e[1] = i) : i = e[1];
|
|
318
|
+
const a = l ? "max-w-[320px]" : r;
|
|
319
|
+
let s;
|
|
320
|
+
e[2] !== a ? (s = I("w-full flex flex-col items-center", a), e[2] = a, e[3] = s) : s = e[3];
|
|
321
|
+
let c;
|
|
322
|
+
e[4] !== t || e[5] !== s ? (c = /* @__PURE__ */ d("div", { className: s, children: t }), e[4] = t, e[5] = s, e[6] = c) : c = e[6];
|
|
323
|
+
let m;
|
|
324
|
+
return e[7] !== i || e[8] !== c ? (m = /* @__PURE__ */ d("main", { className: i, children: c }), e[7] = i, e[8] = c, e[9] = m) : m = e[9], m;
|
|
325
|
+
}
|
|
326
|
+
function vt(n) {
|
|
327
|
+
const e = _.c(10), {
|
|
328
|
+
children: t,
|
|
329
|
+
className: l
|
|
330
|
+
} = n, {
|
|
331
|
+
maxWidthClass: o
|
|
332
|
+
} = xe();
|
|
333
|
+
let r;
|
|
334
|
+
e[0] !== l ? (r = I("px-5 py-6 md:py-8 w-full flex justify-center", l), e[0] = l, e[1] = r) : r = e[1];
|
|
335
|
+
let i;
|
|
336
|
+
e[2] !== o ? (i = I("w-full text-center", o), e[2] = o, e[3] = i) : i = e[3];
|
|
337
|
+
let a;
|
|
338
|
+
e[4] !== t || e[5] !== i ? (a = /* @__PURE__ */ d("div", { className: i, children: t }), e[4] = t, e[5] = i, e[6] = a) : a = e[6];
|
|
339
|
+
let s;
|
|
340
|
+
return e[7] !== r || e[8] !== a ? (s = /* @__PURE__ */ d("footer", { className: r, children: a }), e[7] = r, e[8] = a, e[9] = s) : s = e[9], s;
|
|
341
|
+
}
|
|
342
|
+
const H = {
|
|
343
|
+
Root: dt,
|
|
344
|
+
Header: ft,
|
|
345
|
+
Main: bt,
|
|
346
|
+
Logo: mt,
|
|
347
|
+
Title: ht,
|
|
348
|
+
Description: gt,
|
|
349
|
+
Body: pt,
|
|
350
|
+
Footer: vt
|
|
351
|
+
};
|
|
352
|
+
function yt(n) {
|
|
353
|
+
const e = _.c(38), {
|
|
354
|
+
images: t,
|
|
355
|
+
autoPlayInterval: l,
|
|
356
|
+
className: o,
|
|
357
|
+
hideIndicators: r,
|
|
358
|
+
onSlideChange: i,
|
|
359
|
+
activeIndex: a,
|
|
360
|
+
onNavigate: s
|
|
361
|
+
} = n, c = l === void 0 ? 5e3 : l, [m, h] = q(0), u = a !== void 0, f = u ? a : m;
|
|
362
|
+
let b, g;
|
|
363
|
+
e[0] !== c || e[1] !== f || e[2] !== t.length || e[3] !== u || e[4] !== i ? (b = () => {
|
|
364
|
+
if (c > 0 && t.length > 1) {
|
|
365
|
+
const E = setInterval(() => {
|
|
366
|
+
const A = (f + 1) % t.length;
|
|
367
|
+
u || h(A), i?.(A);
|
|
368
|
+
}, c);
|
|
369
|
+
return () => clearInterval(E);
|
|
370
|
+
}
|
|
371
|
+
}, g = [c, t.length, f, u, i], e[0] = c, e[1] = f, e[2] = t.length, e[3] = u, e[4] = i, e[5] = b, e[6] = g) : (b = e[5], g = e[6]), te(b, g);
|
|
372
|
+
let p, v;
|
|
373
|
+
e[7] !== t.length || e[8] !== u || e[9] !== i ? (p = () => {
|
|
374
|
+
!u && t.length > 0 && i?.(0);
|
|
375
|
+
}, v = [t.length, u, i], e[7] = t.length, e[8] = u, e[9] = i, e[10] = p, e[11] = v) : (p = e[10], v = e[11]), te(p, v);
|
|
376
|
+
let y;
|
|
377
|
+
e[12] !== u || e[13] !== s || e[14] !== i ? (y = (E) => {
|
|
378
|
+
u ? (s?.(E), i?.(E)) : (h(E), i?.(E));
|
|
379
|
+
}, e[12] = u, e[13] = s, e[14] = i, e[15] = y) : y = e[15];
|
|
380
|
+
const S = y;
|
|
381
|
+
if (t.length === 0)
|
|
382
|
+
return null;
|
|
383
|
+
const w = t.length;
|
|
384
|
+
let x;
|
|
385
|
+
e[16] !== o ? (x = I("relative w-full h-full min-h-0", o), e[16] = o, e[17] = x) : x = e[17];
|
|
386
|
+
const C = `${w * 100}%`, P = `translateX(-${f * 100 / w}%)`;
|
|
387
|
+
let N;
|
|
388
|
+
e[18] !== C || e[19] !== P ? (N = {
|
|
389
|
+
width: C,
|
|
390
|
+
transform: P
|
|
391
|
+
}, e[18] = C, e[19] = P, e[20] = N) : N = e[20];
|
|
392
|
+
let R;
|
|
393
|
+
if (e[21] !== t || e[22] !== w) {
|
|
394
|
+
let E;
|
|
395
|
+
e[24] !== w ? (E = (A, D) => /* @__PURE__ */ d("div", { className: "relative flex-shrink-0 h-full", style: {
|
|
396
|
+
width: `${100 / w}%`
|
|
397
|
+
}, children: /* @__PURE__ */ d("img", { src: A, alt: `Slide ${D + 1}`, className: "h-full w-full object-cover object-center" }) }, `${A}-${D}`), e[24] = w, e[25] = E) : E = e[25], R = t.map(E), e[21] = t, e[22] = w, e[23] = R;
|
|
398
|
+
} else
|
|
399
|
+
R = e[23];
|
|
400
|
+
let O;
|
|
401
|
+
e[26] !== N || e[27] !== R ? (O = /* @__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: N, children: R }) }), e[26] = N, e[27] = R, e[28] = O) : O = e[28];
|
|
402
|
+
let F;
|
|
403
|
+
e[29] !== f || e[30] !== S || e[31] !== r || e[32] !== t ? (F = 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((E, A) => /* @__PURE__ */ d("button", { type: "button", onClick: () => S(A), className: I("h-1 rounded-[3px] transition-all duration-300", A === f ? "w-8 bg-white" : "w-2 bg-white/40"), "aria-label": `Go to slide ${A + 1}` }, `indicator-${E}-${A}`)) }), e[29] = f, e[30] = S, e[31] = r, e[32] = t, e[33] = F) : F = e[33];
|
|
404
|
+
let k;
|
|
405
|
+
return e[34] !== O || e[35] !== F || e[36] !== x ? (k = /* @__PURE__ */ L("div", { className: x, children: [
|
|
406
|
+
O,
|
|
407
|
+
F
|
|
408
|
+
] }), e[34] = O, e[35] = F, e[36] = x, e[37] = k) : k = e[37], k;
|
|
409
|
+
}
|
|
410
|
+
function St(n) {
|
|
411
|
+
const e = _.c(20), {
|
|
412
|
+
sliderImages: t,
|
|
413
|
+
sliderAutoPlayInterval: l,
|
|
414
|
+
activeSlideIndex: o,
|
|
415
|
+
onSlideChange: r,
|
|
416
|
+
ctaText: i,
|
|
417
|
+
sliderTitles: a,
|
|
418
|
+
className: s
|
|
419
|
+
} = n, c = a?.[o];
|
|
420
|
+
let m = i ?? null;
|
|
421
|
+
if (c != null) {
|
|
422
|
+
let p;
|
|
423
|
+
e[0] !== c ? (p = typeof c == "string" ? /* @__PURE__ */ d(T, { variant: "h6", weight: "medium", align: "center", color: "#1e595a", className: "whitespace-pre-line", children: c }) : c, e[0] = c, e[1] = p) : p = e[1], m = p;
|
|
424
|
+
}
|
|
425
|
+
let h;
|
|
426
|
+
e[2] !== s ? (h = I("relative w-full h-[100dvh] transition-colors duration-500", s), e[2] = s, e[3] = h) : h = e[3];
|
|
427
|
+
let u;
|
|
428
|
+
e[4] !== o || e[5] !== r || e[6] !== t ? (u = t.length > 1 && /* @__PURE__ */ d("div", { className: "absolute top-2.5 left-1/2 z-20 flex w-full max-w-[400px] -translate-x-1/2 gap-1.5 px-4", children: t.map((p, v) => /* @__PURE__ */ d("button", { type: "button", onClick: () => r(v), "aria-label": `Go to slide ${v + 1}`, "aria-current": v === o ? "true" : void 0, className: I("h-1 flex-1 rounded-[3px] cursor-pointer transition-all duration-300", v === o ? "bg-white" : "bg-white/40 hover:bg-white/60") }, `indicator-${p}-${v}`)) }), e[4] = o, e[5] = r, e[6] = t, e[7] = u) : u = e[7];
|
|
429
|
+
let f;
|
|
430
|
+
e[8] !== m ? (f = m != null && /* @__PURE__ */ d("div", { className: I("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: m }), e[8] = m, e[9] = f) : f = e[9];
|
|
431
|
+
let b;
|
|
432
|
+
e[10] !== o || e[11] !== r || e[12] !== l || e[13] !== t ? (b = /* @__PURE__ */ d("div", { className: "absolute inset-0", children: t.length > 0 ? /* @__PURE__ */ d(yt, { images: t, autoPlayInterval: l, className: "h-full w-full", hideIndicators: !0, activeIndex: o, onSlideChange: r, onNavigate: r }) : /* @__PURE__ */ d("div", { className: "flex h-full w-full items-center justify-center bg-white/50 p-8", children: /* @__PURE__ */ d(T, { variant: "h6", weight: "medium", align: "center", className: "opacity-40 text-[#1e595a]", children: "No slides configured" }) }) }), e[10] = o, e[11] = r, e[12] = l, e[13] = t, e[14] = b) : b = e[14];
|
|
433
|
+
let g;
|
|
434
|
+
return e[15] !== h || e[16] !== u || e[17] !== f || e[18] !== b ? (g = /* @__PURE__ */ L("div", { className: h, children: [
|
|
435
|
+
u,
|
|
436
|
+
f,
|
|
437
|
+
b
|
|
438
|
+
] }), e[15] = h, e[16] = u, e[17] = f, e[18] = b, e[19] = g) : g = e[19], g;
|
|
439
|
+
}
|
|
440
|
+
function xt(n) {
|
|
441
|
+
const e = _.c(23), {
|
|
442
|
+
sliderImages: t,
|
|
443
|
+
sliderAutoPlayInterval: l,
|
|
444
|
+
ctaText: o,
|
|
445
|
+
sliderTitles: r,
|
|
446
|
+
className: i,
|
|
447
|
+
marketingClassName: a,
|
|
448
|
+
contentClassName: s,
|
|
449
|
+
children: c
|
|
450
|
+
} = n, m = l === void 0 ? 5e3 : l, [h, u] = q(0), f = t ?? De;
|
|
451
|
+
let b;
|
|
452
|
+
e[0] !== i ? (b = I("min-h-svh w-full flex flex-1 flex-col transition-colors duration-500", i), e[0] = i, e[1] = b) : b = e[1];
|
|
453
|
+
let g;
|
|
454
|
+
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (g = {
|
|
455
|
+
backgroundColor: "#ffffff"
|
|
456
|
+
}, e[2] = g) : g = e[2];
|
|
457
|
+
let p;
|
|
458
|
+
e[3] !== a ? (p = a && {
|
|
459
|
+
className: a
|
|
460
|
+
}, e[3] = a, e[4] = p) : p = e[4];
|
|
461
|
+
let v;
|
|
462
|
+
e[5] !== h || e[6] !== o || e[7] !== f || e[8] !== m || e[9] !== r || e[10] !== p ? (v = /* @__PURE__ */ d("div", { className: "hidden lg:block lg:w-[432px] lg:h-[100dvh] lg:flex-shrink-0 lg:flex-grow-0", children: /* @__PURE__ */ d(St, { sliderImages: f, sliderAutoPlayInterval: m, activeSlideIndex: h, onSlideChange: u, ctaText: o, sliderTitles: r, ...p }) }), e[5] = h, e[6] = o, e[7] = f, e[8] = m, e[9] = r, e[10] = p, e[11] = v) : v = e[11];
|
|
463
|
+
let y;
|
|
464
|
+
e[12] !== s ? (y = I("flex-1 min-w-0 flex flex-col overflow-x-hidden", s), e[12] = s, e[13] = y) : y = e[13];
|
|
465
|
+
let S;
|
|
466
|
+
e[14] !== c || e[15] !== y ? (S = /* @__PURE__ */ d("div", { className: y, children: c }), e[14] = c, e[15] = y, e[16] = S) : S = e[16];
|
|
467
|
+
let w;
|
|
468
|
+
e[17] !== v || e[18] !== S ? (w = /* @__PURE__ */ L("div", { className: "flex w-full h-full min-h-svh flex-col lg:flex-row", children: [
|
|
469
|
+
v,
|
|
470
|
+
S
|
|
471
|
+
] }), e[17] = v, e[18] = S, e[19] = w) : w = e[19];
|
|
472
|
+
let x;
|
|
473
|
+
return e[20] !== b || e[21] !== w ? (x = /* @__PURE__ */ d("div", { className: b, style: g, children: w }), e[20] = b, e[21] = w, e[22] = x) : x = e[22], x;
|
|
474
|
+
}
|
|
475
|
+
function ie(n) {
|
|
476
|
+
const e = _.c(58), {
|
|
477
|
+
children: t,
|
|
478
|
+
layoutType: l,
|
|
479
|
+
logo: o,
|
|
480
|
+
title: r,
|
|
481
|
+
description: i,
|
|
482
|
+
footer: a,
|
|
483
|
+
header: s,
|
|
484
|
+
onBack: c,
|
|
485
|
+
backButton: m,
|
|
486
|
+
sliderImages: h,
|
|
487
|
+
sliderAutoPlayInterval: u,
|
|
488
|
+
sliderTitles: f,
|
|
489
|
+
variant: b,
|
|
490
|
+
maxWidth: g,
|
|
491
|
+
contentWidth: p,
|
|
492
|
+
align: v,
|
|
493
|
+
className: y
|
|
494
|
+
} = n, S = l === void 0 ? "withSlider" : l, w = h === void 0 ? De : h, x = u === void 0 ? ct : u, C = g === void 0 ? "sm" : g, P = p === void 0 ? "default" : p, N = v === void 0 ? "center" : v, R = P === "sm", O = b ?? (S === "withSlider" ? "desktop" : "mobile");
|
|
495
|
+
let F;
|
|
496
|
+
e[0] !== m || e[1] !== o || e[2] !== c ? (F = () => m ?? (c != null ? /* @__PURE__ */ d(M, { icon: /* @__PURE__ */ d(Se, {}), iconOnly: !0, onClick: c, size: "medium", variant: "outline", "aria-label": "Go back", className: "h-10 w-10" }) : o ? typeof o == "string" ? /* @__PURE__ */ d("div", { className: "h-[30px] w-[140px]", children: /* @__PURE__ */ d("img", { src: o, alt: "Docthub", className: "block h-full w-full object-cover" }) }) : o : null), e[0] = m, e[1] = o, e[2] = c, e[3] = F) : F = e[3];
|
|
497
|
+
const k = F;
|
|
498
|
+
let E;
|
|
499
|
+
e[4] !== N || e[5] !== r ? (E = () => r ? typeof r == "string" ? /* @__PURE__ */ d(T, { variant: "h5", weight: "extraBold", align: N, className: "text-black", children: r }) : r : null, e[4] = N, e[5] = r, e[6] = E) : E = e[6];
|
|
500
|
+
const A = E;
|
|
501
|
+
let D;
|
|
502
|
+
e[7] !== N || e[8] !== i ? (D = () => i ? typeof i == "string" ? /* @__PURE__ */ d(T, { variant: "title2", align: N, className: "text-black/80", children: i }) : i : null, e[7] = N, e[8] = i, e[9] = D) : D = e[9];
|
|
503
|
+
const V = D;
|
|
504
|
+
let $;
|
|
505
|
+
e[10] !== s ? ($ = s && /* @__PURE__ */ d(H.Header, { children: s }), e[10] = s, e[11] = $) : $ = e[11];
|
|
506
|
+
let j;
|
|
507
|
+
e[12] !== k ? (j = k(), e[12] = k, e[13] = j) : j = e[13];
|
|
508
|
+
let U;
|
|
509
|
+
e[14] !== N || e[15] !== j ? (U = /* @__PURE__ */ d(H.Logo, { align: N, children: j }), e[14] = N, e[15] = j, e[16] = U) : U = e[16];
|
|
510
|
+
let B;
|
|
511
|
+
e[17] !== N || e[18] !== A || e[19] !== r ? (B = r && /* @__PURE__ */ d(H.Title, { align: N, children: A() }), e[17] = N, e[18] = A, e[19] = r, e[20] = B) : B = e[20];
|
|
512
|
+
let z;
|
|
513
|
+
e[21] !== N || e[22] !== i || e[23] !== V ? (z = i && /* @__PURE__ */ d(H.Description, { align: N, children: V() }), e[21] = N, e[22] = i, e[23] = V, e[24] = z) : z = e[24];
|
|
514
|
+
let Y;
|
|
515
|
+
e[25] !== t ? (Y = /* @__PURE__ */ d(H.Body, { children: t }), e[25] = t, e[26] = Y) : Y = e[26];
|
|
516
|
+
let K;
|
|
517
|
+
e[27] !== U || e[28] !== B || e[29] !== z || e[30] !== Y || e[31] !== R ? (K = /* @__PURE__ */ L(H.Main, { sm: R, children: [
|
|
518
|
+
U,
|
|
519
|
+
B,
|
|
520
|
+
z,
|
|
521
|
+
Y
|
|
522
|
+
] }), e[27] = U, e[28] = B, e[29] = z, e[30] = Y, e[31] = R, e[32] = K) : K = e[32];
|
|
523
|
+
let X;
|
|
524
|
+
e[33] !== a ? (X = a && /* @__PURE__ */ d(H.Footer, { children: a }), e[33] = a, e[34] = X) : X = e[34];
|
|
525
|
+
let oe;
|
|
526
|
+
e[35] !== $ || e[36] !== K || e[37] !== X ? (oe = /* @__PURE__ */ L(Ve, { children: [
|
|
527
|
+
$,
|
|
528
|
+
K,
|
|
529
|
+
X
|
|
530
|
+
] }), e[35] = $, e[36] = K, e[37] = X, e[38] = oe) : oe = e[38];
|
|
531
|
+
const Z = oe;
|
|
532
|
+
if (S === "withSlider") {
|
|
533
|
+
let Q;
|
|
534
|
+
e[39] !== y ? (Q = y && {
|
|
535
|
+
className: y
|
|
536
|
+
}, e[39] = y, e[40] = Q) : Q = e[40];
|
|
537
|
+
let ee;
|
|
538
|
+
e[41] !== Z || e[42] !== C || e[43] !== O ? (ee = /* @__PURE__ */ d(H.Root, { variant: O, maxWidth: C, className: "bg-transparent", children: Z }), e[41] = Z, e[42] = C, e[43] = O, e[44] = ee) : ee = e[44];
|
|
539
|
+
let se;
|
|
540
|
+
return e[45] !== x || e[46] !== w || e[47] !== f || e[48] !== Q || e[49] !== ee ? (se = /* @__PURE__ */ d(xt, { sliderImages: w, sliderAutoPlayInterval: x, sliderTitles: f, ...Q, children: ee }), e[45] = x, e[46] = w, e[47] = f, e[48] = Q, e[49] = ee, e[50] = se) : se = e[50], se;
|
|
541
|
+
}
|
|
542
|
+
let J;
|
|
543
|
+
e[51] !== y ? (J = y && {
|
|
544
|
+
className: y
|
|
545
|
+
}, e[51] = y, e[52] = J) : J = e[52];
|
|
546
|
+
let re;
|
|
547
|
+
return e[53] !== Z || e[54] !== C || e[55] !== O || e[56] !== J ? (re = /* @__PURE__ */ d(H.Root, { variant: O, maxWidth: C, ...J, children: Z }), e[53] = Z, e[54] = C, e[55] = O, e[56] = J, e[57] = re) : re = e[57], re;
|
|
548
|
+
}
|
|
549
|
+
const Ie = "https://accounts.google.com/gsi/client";
|
|
550
|
+
function wt() {
|
|
551
|
+
return typeof window > "u" ? Promise.reject(new Error("GSI requires browser")) : window.google?.accounts?.id ? Promise.resolve() : new Promise((n, e) => {
|
|
552
|
+
if (document.querySelector(`script[src="${Ie}"]`)) {
|
|
553
|
+
const o = () => window.google?.accounts?.id ? n() : setTimeout(o, 50);
|
|
554
|
+
o();
|
|
555
|
+
return;
|
|
556
|
+
}
|
|
557
|
+
const l = document.createElement("script");
|
|
558
|
+
l.src = Ie, 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);
|
|
559
|
+
});
|
|
560
|
+
}
|
|
561
|
+
const Ct = "openid email profile", Re = 2e3;
|
|
562
|
+
function Nt(n) {
|
|
563
|
+
const e = _.c(18), {
|
|
564
|
+
clientId: t,
|
|
565
|
+
onCredential: l,
|
|
566
|
+
enableOneTap: o
|
|
567
|
+
} = n, r = o === void 0 ? !1 : o, i = le(!1), a = le(null), s = le(l), c = le(0), m = le(!1);
|
|
568
|
+
let h, u;
|
|
569
|
+
e[0] !== l ? (h = () => {
|
|
570
|
+
s.current = l;
|
|
571
|
+
}, u = [l], e[0] = l, e[1] = h, e[2] = u) : (h = e[1], u = e[2]), te(h, u);
|
|
572
|
+
let f;
|
|
573
|
+
e[3] !== t ? (f = async () => {
|
|
574
|
+
t && (await wt(), !(!window.google?.accounts?.id || !window.google?.accounts?.oauth2) && (i.current || (window.google.accounts.id.initialize({
|
|
575
|
+
client_id: t,
|
|
576
|
+
callback: (C) => {
|
|
577
|
+
s.current(C.credential);
|
|
578
|
+
},
|
|
579
|
+
auto_select: !1
|
|
580
|
+
}), a.current = window.google.accounts.oauth2.initCodeClient({
|
|
581
|
+
client_id: t,
|
|
582
|
+
scope: Ct,
|
|
583
|
+
ux_mode: "popup",
|
|
584
|
+
callback: (C) => {
|
|
585
|
+
s.current(C.code);
|
|
586
|
+
},
|
|
587
|
+
error_callback: _t
|
|
588
|
+
}), i.current = !0)));
|
|
589
|
+
}, e[3] = t, e[4] = f) : f = e[4];
|
|
590
|
+
const b = f;
|
|
591
|
+
let g;
|
|
592
|
+
e[5] !== t ? (g = async () => {
|
|
593
|
+
if (!t)
|
|
594
|
+
return;
|
|
595
|
+
const C = Date.now();
|
|
596
|
+
C - c.current < Re || (c.current = C, a.current?.requestCode());
|
|
597
|
+
}, e[5] = t, e[6] = g) : g = e[6];
|
|
598
|
+
const p = g;
|
|
599
|
+
let v, y;
|
|
600
|
+
e[7] !== t || e[8] !== b ? (v = () => {
|
|
601
|
+
t && b();
|
|
602
|
+
}, y = [t, b], e[7] = t, e[8] = b, e[9] = v, e[10] = y) : (v = e[9], y = e[10]), te(v, y);
|
|
603
|
+
let S, w;
|
|
604
|
+
e[11] !== t || e[12] !== r || e[13] !== b ? (S = () => {
|
|
605
|
+
!r || !t || m.current || (m.current = !0, b().then(() => {
|
|
606
|
+
if (!window.google?.accounts?.id)
|
|
607
|
+
return;
|
|
608
|
+
const C = Date.now();
|
|
609
|
+
C - c.current < Re || (c.current = C, window.google.accounts.id.prompt());
|
|
610
|
+
}));
|
|
611
|
+
}, w = [r, t, b], e[11] = t, e[12] = r, e[13] = b, e[14] = S, e[15] = w) : (S = e[14], w = e[15]), te(S, w);
|
|
612
|
+
let x;
|
|
613
|
+
return e[16] !== p ? (x = {
|
|
614
|
+
loginWithGoogle: p
|
|
615
|
+
}, e[16] = p, e[17] = x) : x = e[17], x;
|
|
616
|
+
}
|
|
617
|
+
function _t() {
|
|
618
|
+
}
|
|
619
|
+
function je(n) {
|
|
620
|
+
const e = _.c(14), {
|
|
621
|
+
name: t,
|
|
622
|
+
label: l,
|
|
623
|
+
placeholder: o,
|
|
624
|
+
helperText: r,
|
|
625
|
+
defaultCountry: i,
|
|
626
|
+
variant: a,
|
|
627
|
+
required: s,
|
|
628
|
+
disabled: c,
|
|
629
|
+
control: m,
|
|
630
|
+
error: h,
|
|
631
|
+
autoFocus: u
|
|
632
|
+
} = n, f = o === void 0 ? "Enter phone number" : o, b = i === void 0 ? "IN" : i, g = a === void 0 ? "default" : a, p = ne(), v = m ?? p.control;
|
|
633
|
+
let y;
|
|
634
|
+
e[0] !== u || e[1] !== b || e[2] !== c || e[3] !== h || e[4] !== r || e[5] !== l || e[6] !== f || e[7] !== s || e[8] !== g ? (y = (w) => {
|
|
635
|
+
const {
|
|
636
|
+
field: x,
|
|
637
|
+
fieldState: C
|
|
638
|
+
} = w, P = h ?? C.error?.message;
|
|
639
|
+
return /* @__PURE__ */ d(qe, { placeholder: f, value: x.value ?? "", onValueChange: (N) => x.onChange(N ?? ""), defaultCountry: b, variant: g ?? "default", required: s ?? !1, disabled: c ?? !1, ...l != null && {
|
|
640
|
+
label: l
|
|
641
|
+
}, ...r != null && {
|
|
642
|
+
helperText: r
|
|
643
|
+
}, ...P !== void 0 && {
|
|
644
|
+
error: P
|
|
645
|
+
}, ...u !== void 0 && {
|
|
646
|
+
autoFocus: u
|
|
647
|
+
} });
|
|
648
|
+
}, e[0] = u, e[1] = b, e[2] = c, e[3] = h, e[4] = r, e[5] = l, e[6] = f, e[7] = s, e[8] = g, e[9] = y) : y = e[9];
|
|
649
|
+
let S;
|
|
650
|
+
return e[10] !== t || e[11] !== v || e[12] !== y ? (S = /* @__PURE__ */ d(be, { name: t, control: v, render: y }), e[10] = t, e[11] = v, e[12] = y, e[13] = S) : S = e[13], S;
|
|
651
|
+
}
|
|
652
|
+
function pe(n) {
|
|
653
|
+
const e = _.c(15), {
|
|
654
|
+
name: t,
|
|
655
|
+
label: l,
|
|
656
|
+
placeholder: o,
|
|
657
|
+
className: r,
|
|
658
|
+
control: i,
|
|
659
|
+
required: a,
|
|
660
|
+
type: s,
|
|
661
|
+
disabled: c,
|
|
662
|
+
onKeyDown: m,
|
|
663
|
+
maxLength: h,
|
|
664
|
+
numericOnly: u,
|
|
665
|
+
autoFocus: f
|
|
666
|
+
} = n, b = ne(), g = i || b.control;
|
|
667
|
+
let p;
|
|
668
|
+
e[0] !== f || e[1] !== r || e[2] !== c || e[3] !== l || e[4] !== h || e[5] !== u || e[6] !== m || e[7] !== o || e[8] !== a || e[9] !== s ? (p = (y) => {
|
|
669
|
+
const {
|
|
670
|
+
field: S,
|
|
671
|
+
fieldState: w
|
|
672
|
+
} = y;
|
|
673
|
+
return /* @__PURE__ */ d(Ye, { ...S, ...f !== void 0 && {
|
|
674
|
+
autoFocus: f
|
|
675
|
+
}, value: S.value ?? "", ...l !== void 0 && {
|
|
676
|
+
label: l
|
|
677
|
+
}, ...o !== void 0 && {
|
|
678
|
+
placeholder: o
|
|
679
|
+
}, ...w.error?.message !== void 0 && {
|
|
680
|
+
error: w.error?.message
|
|
681
|
+
}, ...r !== void 0 && {
|
|
682
|
+
className: r
|
|
683
|
+
}, ...a !== void 0 && {
|
|
684
|
+
required: a
|
|
685
|
+
}, type: s, ...c !== void 0 && {
|
|
686
|
+
disabled: c
|
|
687
|
+
}, onKeyDown: u ? (x) => {
|
|
688
|
+
!/[0-9]/.test(x.key) && !["Backspace", "Tab", "Delete", "ArrowLeft", "ArrowRight", "Home", "End"].includes(x.key) && x.preventDefault(), m?.(x);
|
|
689
|
+
} : m, ...h !== void 0 && {
|
|
690
|
+
maxLength: h
|
|
691
|
+
}, onChange: (x) => {
|
|
692
|
+
const C = x.target?.value;
|
|
693
|
+
if (typeof C == "string") {
|
|
694
|
+
S.onChange(C.replace(/^\s+/, ""));
|
|
695
|
+
let P = C.replace(/^\s+/, "");
|
|
696
|
+
u && (P = P.replace(/\D/g, "")), S.onChange(P);
|
|
697
|
+
} else
|
|
698
|
+
S.onChange(C);
|
|
699
|
+
}, onBlur: () => {
|
|
700
|
+
const x = S.value;
|
|
701
|
+
if (typeof x == "string") {
|
|
702
|
+
const C = x.trim();
|
|
703
|
+
C !== x && S.onChange(C);
|
|
704
|
+
}
|
|
705
|
+
S.onBlur();
|
|
706
|
+
} });
|
|
707
|
+
}, e[0] = f, e[1] = r, e[2] = c, e[3] = l, e[4] = h, e[5] = u, e[6] = m, e[7] = o, e[8] = a, e[9] = s, e[10] = p) : p = e[10];
|
|
708
|
+
let v;
|
|
709
|
+
return e[11] !== t || e[12] !== g || e[13] !== p ? (v = /* @__PURE__ */ d(be, { name: t, control: g, render: p }), e[11] = t, e[12] = g, e[13] = p, e[14] = v) : v = e[14], v;
|
|
710
|
+
}
|
|
711
|
+
function Ue(n, e) {
|
|
712
|
+
for (const t of n.issues) {
|
|
713
|
+
const l = t.path[0];
|
|
714
|
+
typeof l == "string" && e(l, {
|
|
715
|
+
message: t.message
|
|
716
|
+
});
|
|
717
|
+
}
|
|
718
|
+
}
|
|
719
|
+
function Et(n) {
|
|
720
|
+
return n.trim().replace(/\b\w/g, (e) => e.toUpperCase());
|
|
721
|
+
}
|
|
722
|
+
const Ce = W.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(Et), Ne = W.string().trim().min(1, "Phone number is required").refine((n) => {
|
|
723
|
+
if (n == null || n.length === 0) return !0;
|
|
724
|
+
const [, e = ""] = n.split("-"), t = e.replaceAll(/\D/g, "");
|
|
725
|
+
return t.length >= 7 && t.length <= 15;
|
|
726
|
+
}, "Phone number must be between 7 and 15 digits"), _e = W.string().trim().min(1, "Email is required").refine((n) => n == null || n.length === 0 ? !0 : W.string().email().safeParse(n).success, "Enter a valid email address").transform((n) => n.toLowerCase()), Pt = W.object({
|
|
727
|
+
fullName: Ce,
|
|
728
|
+
phone: Ne
|
|
729
|
+
}), Ot = W.object({
|
|
730
|
+
fullName: Ce,
|
|
731
|
+
email: _e
|
|
732
|
+
}), At = W.object({
|
|
733
|
+
fullName: Ce,
|
|
734
|
+
email: _e,
|
|
735
|
+
phone: Ne
|
|
736
|
+
}), Le = {
|
|
737
|
+
phone: Pt,
|
|
738
|
+
email: Ot,
|
|
739
|
+
foreign: At
|
|
740
|
+
}, Tt = W.object({
|
|
741
|
+
phone: Ne
|
|
742
|
+
}), It = W.object({
|
|
743
|
+
email: _e
|
|
744
|
+
}), Fe = {
|
|
745
|
+
phone: Tt,
|
|
746
|
+
email: It
|
|
747
|
+
}, fe = 6, Rt = 60, Lt = 120;
|
|
748
|
+
function Ft(n) {
|
|
749
|
+
return n === "phone" ? Rt : Lt;
|
|
750
|
+
}
|
|
751
|
+
const ze = W.object({
|
|
752
|
+
otp: W.array(W.string()).length(fe, "Enter all 6 digits").refine((n) => n.every((e) => /^\d$/.test(e)) && n.join("").length === fe, "Invalid OTP! Please use correct code and submit again.")
|
|
753
|
+
});
|
|
754
|
+
function Mt(n) {
|
|
755
|
+
const e = _.c(19), {
|
|
756
|
+
mode: t,
|
|
757
|
+
onSubmit: l,
|
|
758
|
+
submitApi: o,
|
|
759
|
+
onSuccess: r,
|
|
760
|
+
onError: i
|
|
761
|
+
} = n, [a, s] = q(!1), c = t === "phone";
|
|
762
|
+
let m;
|
|
763
|
+
e[0] !== c ? (m = c ? {
|
|
764
|
+
phone: ""
|
|
765
|
+
} : {
|
|
766
|
+
email: ""
|
|
767
|
+
}, e[0] = c, e[1] = m) : m = e[1];
|
|
768
|
+
const h = m;
|
|
769
|
+
let u;
|
|
770
|
+
e[2] !== h ? (u = {
|
|
771
|
+
defaultValues: h,
|
|
772
|
+
mode: "onChange"
|
|
773
|
+
}, e[2] = h, e[3] = u) : u = e[3];
|
|
774
|
+
const f = ve(u);
|
|
775
|
+
let b;
|
|
776
|
+
e[4] !== f || e[5] !== t || e[6] !== i || e[7] !== l || e[8] !== r || e[9] !== o ? (b = (S) => {
|
|
777
|
+
const x = Fe[t].safeParse(S);
|
|
778
|
+
if (!x.success) {
|
|
779
|
+
Ue(x.error, (P, N) => f.setError(P, N));
|
|
780
|
+
return;
|
|
781
|
+
}
|
|
782
|
+
const C = x.data;
|
|
783
|
+
if (o) {
|
|
784
|
+
s(!0);
|
|
785
|
+
const P = C.phone ?? C.email ?? "", N = {
|
|
786
|
+
mode: t,
|
|
787
|
+
recipient: P
|
|
788
|
+
};
|
|
789
|
+
o(C).then(() => {
|
|
790
|
+
r?.(N);
|
|
791
|
+
}).catch((R) => {
|
|
792
|
+
i?.(R);
|
|
793
|
+
}).finally(() => {
|
|
794
|
+
s(!1);
|
|
795
|
+
});
|
|
796
|
+
return;
|
|
797
|
+
}
|
|
798
|
+
l?.(C);
|
|
799
|
+
}, e[4] = f, e[5] = t, e[6] = i, e[7] = l, e[8] = r, e[9] = o, e[10] = b) : b = e[10];
|
|
800
|
+
const g = b;
|
|
801
|
+
let p;
|
|
802
|
+
e[11] !== t ? (p = (S) => Fe[t].safeParse(S).success, e[11] = t, e[12] = p) : p = e[12];
|
|
803
|
+
const v = p;
|
|
804
|
+
let y;
|
|
805
|
+
return e[13] !== g || e[14] !== v || e[15] !== c || e[16] !== a || e[17] !== f ? (y = {
|
|
806
|
+
methods: f,
|
|
807
|
+
handleSubmit: g,
|
|
808
|
+
isPhone: c,
|
|
809
|
+
isFormValid: v,
|
|
810
|
+
isSubmitting: a
|
|
811
|
+
}, e[13] = g, e[14] = v, e[15] = c, e[16] = a, e[17] = f, e[18] = y) : y = e[18], y;
|
|
812
|
+
}
|
|
813
|
+
function kt(n) {
|
|
814
|
+
const e = _.c(12), {
|
|
815
|
+
isPhone: t,
|
|
816
|
+
handleSubmit: l,
|
|
817
|
+
isSubmitting: o
|
|
818
|
+
} = n, r = ne();
|
|
819
|
+
let i;
|
|
820
|
+
e[0] !== l || e[1] !== r ? (i = r.handleSubmit(l), e[0] = l, e[1] = r, e[2] = i) : i = e[2];
|
|
821
|
+
let a;
|
|
822
|
+
e[3] !== t ? (a = /* @__PURE__ */ d("div", { className: "mb-6 flex w-full flex-col gap-[12px]", children: t ? /* @__PURE__ */ d(je, { name: "phone", label: "Phone number", placeholder: "Phone number", defaultCountry: "IN", autoFocus: !0 }) : /* @__PURE__ */ d(pe, { name: "email", label: "Email address", placeholder: "Enter email address", type: "email", autoFocus: !0 }) }), e[3] = t, e[4] = a) : a = e[4];
|
|
823
|
+
const s = o ? "Sending…" : "Continue";
|
|
824
|
+
let c;
|
|
825
|
+
e[5] !== o || e[6] !== s ? (c = /* @__PURE__ */ d(M, { type: "submit", variant: "primary", size: "large", fullWidth: !0, disabled: o, children: s }), e[5] = o, e[6] = s, e[7] = c) : c = e[7];
|
|
826
|
+
let m;
|
|
827
|
+
return e[8] !== i || e[9] !== a || e[10] !== c ? (m = /* @__PURE__ */ L("form", { onSubmit: i, className: "w-full flex flex-col", children: [
|
|
828
|
+
a,
|
|
829
|
+
c
|
|
830
|
+
] }), e[8] = i, e[9] = a, e[10] = c, e[11] = m) : m = e[11], m;
|
|
831
|
+
}
|
|
832
|
+
function Dt(n) {
|
|
833
|
+
const e = _.c(13), {
|
|
834
|
+
mode: t,
|
|
835
|
+
onSubmit: l,
|
|
836
|
+
submitApi: o,
|
|
837
|
+
onSuccess: r,
|
|
838
|
+
onError: i
|
|
839
|
+
} = n;
|
|
840
|
+
let a;
|
|
841
|
+
e[0] !== t || e[1] !== i || e[2] !== l || e[3] !== r || e[4] !== o ? (a = {
|
|
842
|
+
mode: t,
|
|
843
|
+
onSubmit: l,
|
|
844
|
+
submitApi: o,
|
|
845
|
+
onSuccess: r,
|
|
846
|
+
onError: i
|
|
847
|
+
}, e[0] = t, e[1] = i, e[2] = l, e[3] = r, e[4] = o, e[5] = a) : a = e[5];
|
|
848
|
+
const {
|
|
849
|
+
methods: s,
|
|
850
|
+
handleSubmit: c,
|
|
851
|
+
isPhone: m,
|
|
852
|
+
isSubmitting: h
|
|
853
|
+
} = Mt(a);
|
|
854
|
+
let u;
|
|
855
|
+
e[6] !== c || e[7] !== m || e[8] !== h ? (u = /* @__PURE__ */ d(kt, { isPhone: m, handleSubmit: c, isSubmitting: h }), e[6] = c, e[7] = m, e[8] = h, e[9] = u) : u = e[9];
|
|
856
|
+
let f;
|
|
857
|
+
return e[10] !== s || e[11] !== u ? (f = /* @__PURE__ */ d(ye, { ...s, children: u }), e[10] = s, e[11] = u, e[12] = f) : f = e[12], f;
|
|
858
|
+
}
|
|
859
|
+
const Wt = {
|
|
860
|
+
phone: "Enter Phone Number",
|
|
861
|
+
email: "Enter Email Address"
|
|
862
|
+
}, $t = {
|
|
863
|
+
phone: "We will send you 6 digit OTP on the given Phone Number.",
|
|
864
|
+
email: "We will send you 6 digit OTP on the given Email Address."
|
|
865
|
+
};
|
|
866
|
+
function bn(n) {
|
|
867
|
+
const e = _.c(15), {
|
|
868
|
+
mode: t,
|
|
869
|
+
title: l,
|
|
870
|
+
subtitle: o,
|
|
871
|
+
onBack: r,
|
|
872
|
+
onSubmit: i,
|
|
873
|
+
submitApi: a,
|
|
874
|
+
onSuccess: s,
|
|
875
|
+
onError: c,
|
|
876
|
+
layoutType: m,
|
|
877
|
+
variant: h
|
|
878
|
+
} = n, u = m === void 0 ? "withSlider" : m, f = h === void 0 ? "desktop" : h, b = l ?? Wt[t], g = o ?? $t[t];
|
|
879
|
+
let p;
|
|
880
|
+
e[0] !== r ? (p = r != null ? /* @__PURE__ */ d(M, { icon: /* @__PURE__ */ d(Se, {}), iconOnly: !0, onClick: r, size: "medium", variant: "outline", "aria-label": "Go back", className: "mb-6 h-10 w-10" }) : void 0, e[0] = r, e[1] = p) : p = e[1];
|
|
881
|
+
let v;
|
|
882
|
+
e[2] !== t || e[3] !== c || e[4] !== i || e[5] !== s || e[6] !== a ? (v = /* @__PURE__ */ d(Dt, { mode: t, onSubmit: i, submitApi: a, onSuccess: s, onError: c }), e[2] = t, e[3] = c, e[4] = i, e[5] = s, e[6] = a, e[7] = v) : v = e[7];
|
|
883
|
+
let y;
|
|
884
|
+
return e[8] !== u || e[9] !== g || e[10] !== b || e[11] !== p || e[12] !== v || e[13] !== f ? (y = /* @__PURE__ */ d(ie, { layoutType: u, variant: f, contentWidth: "sm", align: "left", backButton: p, title: b, description: g, children: v }), e[8] = u, e[9] = g, e[10] = b, e[11] = p, e[12] = v, e[13] = f, e[14] = y) : y = e[14], y;
|
|
885
|
+
}
|
|
886
|
+
function jt(n) {
|
|
887
|
+
return {
|
|
888
|
+
triggerSignIn() {
|
|
889
|
+
}
|
|
890
|
+
};
|
|
891
|
+
}
|
|
892
|
+
function Be(n) {
|
|
893
|
+
const e = _.c(23);
|
|
894
|
+
let t;
|
|
895
|
+
e[0] !== n ? (t = n === void 0 ? {} : n, e[0] = n, e[1] = t) : t = e[1];
|
|
896
|
+
const l = t, o = Vt, r = Gt, i = Ht, a = Bt, s = l.providers?.google?.clientId ?? "";
|
|
897
|
+
let c;
|
|
898
|
+
e[2] !== l.providers?.google?.onCredential ? (c = l.providers?.google?.onCredential ?? zt, e[2] = l.providers?.google?.onCredential, e[3] = c) : c = e[3];
|
|
899
|
+
const m = l.providers?.google?.enableOneTap ?? !1;
|
|
900
|
+
let h;
|
|
901
|
+
e[4] !== s || e[5] !== c || e[6] !== m ? (h = {
|
|
902
|
+
clientId: s,
|
|
903
|
+
onCredential: c,
|
|
904
|
+
enableOneTap: m
|
|
905
|
+
}, e[4] = s, e[5] = c, e[6] = m, e[7] = h) : h = e[7];
|
|
906
|
+
const {
|
|
907
|
+
loginWithGoogle: u
|
|
908
|
+
} = Nt(h), f = l.providers?.apple?.clientId ?? "", b = l.providers?.apple?.redirectUri ?? "";
|
|
909
|
+
let g;
|
|
910
|
+
e[8] !== l.providers?.apple?.onCredential ? (g = l.providers?.apple?.onCredential ?? Ut, e[8] = l.providers?.apple?.onCredential, e[9] = g) : g = e[9];
|
|
911
|
+
let p;
|
|
912
|
+
e[10] !== f || e[11] !== b || e[12] !== g ? (p = {
|
|
913
|
+
clientId: f,
|
|
914
|
+
redirectUri: b,
|
|
915
|
+
onCredential: g
|
|
916
|
+
}, e[10] = f, e[11] = b, e[12] = g, e[13] = p) : p = e[13];
|
|
917
|
+
const {
|
|
918
|
+
triggerSignIn: v
|
|
919
|
+
} = jt(), y = l.onContinueWithMobile ?? o, S = l.onContinueWithEmail ?? r;
|
|
920
|
+
let w;
|
|
921
|
+
e[14] !== u || e[15] !== l.onContinueWithGoogle || e[16] !== l.providers?.google?.clientId ? (w = l.onContinueWithGoogle ?? (l.providers?.google?.clientId ? () => {
|
|
922
|
+
u();
|
|
923
|
+
} : i), e[14] = u, e[15] = l.onContinueWithGoogle, e[16] = l.providers?.google?.clientId, e[17] = w) : w = e[17];
|
|
924
|
+
const x = l.onContinueWithApple ?? (l.providers?.apple?.clientId ? v : a);
|
|
925
|
+
let C;
|
|
926
|
+
return e[18] !== y || e[19] !== S || e[20] !== w || e[21] !== x ? (C = {
|
|
927
|
+
onContinueWithMobile: y,
|
|
928
|
+
onContinueWithEmail: S,
|
|
929
|
+
onContinueWithGoogle: w,
|
|
930
|
+
onContinueWithApple: x
|
|
931
|
+
}, e[18] = y, e[19] = S, e[20] = w, e[21] = x, e[22] = C) : C = e[22], C;
|
|
932
|
+
}
|
|
933
|
+
function Ut() {
|
|
934
|
+
}
|
|
935
|
+
function zt() {
|
|
936
|
+
}
|
|
937
|
+
function Bt() {
|
|
938
|
+
}
|
|
939
|
+
function Ht() {
|
|
940
|
+
}
|
|
941
|
+
function Gt() {
|
|
942
|
+
}
|
|
943
|
+
function Vt() {
|
|
944
|
+
}
|
|
945
|
+
const qt = {
|
|
946
|
+
phone: "Kindly check your Mobile.",
|
|
947
|
+
email: "Kindly check your Email Inbox."
|
|
948
|
+
}, Yt = {
|
|
949
|
+
phone: "6 digit OTP has been sent to your Mobile",
|
|
950
|
+
email: "6 digit OTP has been sent to your Email"
|
|
951
|
+
};
|
|
952
|
+
function Kt(n) {
|
|
953
|
+
const e = _.c(29), {
|
|
954
|
+
mode: t,
|
|
955
|
+
onSubmit: l,
|
|
956
|
+
onResendCode: o,
|
|
957
|
+
submitApi: r,
|
|
958
|
+
onSuccess: i,
|
|
959
|
+
onError: a
|
|
960
|
+
} = n, [s, c] = q(!1);
|
|
961
|
+
let m;
|
|
962
|
+
e[0] !== t ? (m = Ft(t), e[0] = t, e[1] = m) : m = e[1];
|
|
963
|
+
const h = m, [u, f] = q(h), b = u <= 0;
|
|
964
|
+
let g;
|
|
965
|
+
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (g = Array.from({
|
|
966
|
+
length: fe
|
|
967
|
+
}, Jt), e[2] = g) : g = e[2];
|
|
968
|
+
const p = g;
|
|
969
|
+
let v;
|
|
970
|
+
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (v = {
|
|
971
|
+
defaultValues: {
|
|
972
|
+
otp: p
|
|
973
|
+
},
|
|
974
|
+
mode: "onChange"
|
|
975
|
+
}, e[3] = v) : v = e[3];
|
|
976
|
+
const y = ve(v);
|
|
977
|
+
let S, w;
|
|
978
|
+
e[4] !== u ? (S = () => {
|
|
979
|
+
if (u <= 0)
|
|
980
|
+
return;
|
|
981
|
+
const j = setInterval(() => {
|
|
982
|
+
f(Zt);
|
|
983
|
+
}, 1e3);
|
|
984
|
+
return () => clearInterval(j);
|
|
985
|
+
}, w = [u], e[4] = u, e[5] = S, e[6] = w) : (S = e[5], w = e[6]), te(S, w);
|
|
986
|
+
let x;
|
|
987
|
+
e[7] !== y || e[8] !== a || e[9] !== l || e[10] !== i || e[11] !== r ? (x = (j) => {
|
|
988
|
+
const U = ze.safeParse(j);
|
|
989
|
+
if (!U.success) {
|
|
990
|
+
const z = U.error.issues[0]?.message ?? "Invalid OTP";
|
|
991
|
+
y.setError("otp", {
|
|
992
|
+
message: z
|
|
993
|
+
});
|
|
994
|
+
return;
|
|
995
|
+
}
|
|
996
|
+
const B = U.data.otp.join("");
|
|
997
|
+
if (r) {
|
|
998
|
+
c(!0), r(B).then(() => {
|
|
999
|
+
i?.();
|
|
1000
|
+
}).catch((z) => {
|
|
1001
|
+
a?.(z);
|
|
1002
|
+
}).finally(() => {
|
|
1003
|
+
c(!1);
|
|
1004
|
+
});
|
|
1005
|
+
return;
|
|
1006
|
+
}
|
|
1007
|
+
l?.(B);
|
|
1008
|
+
}, e[7] = y, e[8] = a, e[9] = l, e[10] = i, e[11] = r, e[12] = x) : x = e[12];
|
|
1009
|
+
const C = x;
|
|
1010
|
+
let P;
|
|
1011
|
+
e[13] !== b || e[14] !== h || e[15] !== o ? (P = () => {
|
|
1012
|
+
b && (o?.(), f(h));
|
|
1013
|
+
}, e[13] = b, e[14] = h, e[15] = o, e[16] = P) : P = e[16];
|
|
1014
|
+
const N = P, R = Xt, O = Math.floor(u / 60), F = u % 60, k = String(O);
|
|
1015
|
+
let E;
|
|
1016
|
+
e[17] !== k ? (E = k.padStart(2, "0"), e[17] = k, e[18] = E) : E = e[18];
|
|
1017
|
+
const A = String(F);
|
|
1018
|
+
let D;
|
|
1019
|
+
e[19] !== A ? (D = A.padStart(2, "0"), e[19] = A, e[20] = D) : D = e[20];
|
|
1020
|
+
const V = `Resend code in: ${E}:${D}`;
|
|
1021
|
+
let $;
|
|
1022
|
+
return e[21] !== b || e[22] !== N || e[23] !== C || e[24] !== s || e[25] !== y || e[26] !== u || e[27] !== V ? ($ = {
|
|
1023
|
+
methods: y,
|
|
1024
|
+
handleSubmit: C,
|
|
1025
|
+
isFormValid: R,
|
|
1026
|
+
handleResend: N,
|
|
1027
|
+
resendSecondsLeft: u,
|
|
1028
|
+
canResend: b,
|
|
1029
|
+
timerText: V,
|
|
1030
|
+
isSubmitting: s
|
|
1031
|
+
}, e[21] = b, e[22] = N, e[23] = C, e[24] = s, e[25] = y, e[26] = u, e[27] = V, e[28] = $) : $ = e[28], $;
|
|
1032
|
+
}
|
|
1033
|
+
function Xt(n) {
|
|
1034
|
+
return ze.safeParse(n).success;
|
|
1035
|
+
}
|
|
1036
|
+
function Zt(n) {
|
|
1037
|
+
return n <= 1 ? 0 : n - 1;
|
|
1038
|
+
}
|
|
1039
|
+
function Jt() {
|
|
1040
|
+
return "";
|
|
1041
|
+
}
|
|
1042
|
+
const Qt = "Mobile";
|
|
1043
|
+
function en(n) {
|
|
1044
|
+
const e = _.c(11);
|
|
1045
|
+
let t;
|
|
1046
|
+
e[0] !== n ? (t = n === void 0 ? {} : n, e[0] = n, e[1] = t) : t = e[1];
|
|
1047
|
+
const l = t, [o, r] = q(!1), {
|
|
1048
|
+
lastUsedMethod: i,
|
|
1049
|
+
onContinueWithLastMethod: a,
|
|
1050
|
+
continueApi: s,
|
|
1051
|
+
onSuccess: c,
|
|
1052
|
+
onError: m
|
|
1053
|
+
} = l, h = i === void 0 ? Qt : i;
|
|
1054
|
+
let u;
|
|
1055
|
+
e[2] !== s || e[3] !== a || e[4] !== m || e[5] !== c ? (u = () => {
|
|
1056
|
+
if (s) {
|
|
1057
|
+
r(!0), s().then(() => {
|
|
1058
|
+
c?.();
|
|
1059
|
+
}).catch((g) => {
|
|
1060
|
+
m?.(g);
|
|
1061
|
+
}).finally(() => {
|
|
1062
|
+
r(!1);
|
|
1063
|
+
});
|
|
1064
|
+
return;
|
|
1065
|
+
}
|
|
1066
|
+
a?.();
|
|
1067
|
+
}, e[2] = s, e[3] = a, e[4] = m, e[5] = c, e[6] = u) : u = e[6];
|
|
1068
|
+
const f = u;
|
|
1069
|
+
let b;
|
|
1070
|
+
return e[7] !== f || e[8] !== o || e[9] !== h ? (b = {
|
|
1071
|
+
handleContinue: f,
|
|
1072
|
+
isSubmitting: o,
|
|
1073
|
+
lastUsedMethod: h
|
|
1074
|
+
}, e[7] = f, e[8] = o, e[9] = h, e[10] = b) : b = e[10], b;
|
|
1075
|
+
}
|
|
1076
|
+
function tn(n) {
|
|
1077
|
+
const e = _.c(22), {
|
|
1078
|
+
mode: t,
|
|
1079
|
+
defaultPhone: l,
|
|
1080
|
+
onSubmit: o,
|
|
1081
|
+
submitApi: r,
|
|
1082
|
+
onSuccess: i,
|
|
1083
|
+
onError: a
|
|
1084
|
+
} = n, s = l === void 0 ? "" : l, [c, m] = q(!1), h = t === "phone", u = t === "foreign";
|
|
1085
|
+
let f;
|
|
1086
|
+
e[0] !== s || e[1] !== u || e[2] !== h ? (f = u ? {
|
|
1087
|
+
fullName: "",
|
|
1088
|
+
email: "",
|
|
1089
|
+
phone: s
|
|
1090
|
+
} : h ? {
|
|
1091
|
+
fullName: "",
|
|
1092
|
+
phone: ""
|
|
1093
|
+
} : {
|
|
1094
|
+
fullName: "",
|
|
1095
|
+
email: ""
|
|
1096
|
+
}, e[0] = s, e[1] = u, e[2] = h, e[3] = f) : f = e[3];
|
|
1097
|
+
const b = f;
|
|
1098
|
+
let g;
|
|
1099
|
+
e[4] !== b ? (g = {
|
|
1100
|
+
defaultValues: b,
|
|
1101
|
+
mode: "onChange"
|
|
1102
|
+
}, e[4] = b, e[5] = g) : g = e[5];
|
|
1103
|
+
const p = ve(g);
|
|
1104
|
+
let v;
|
|
1105
|
+
e[6] !== p || e[7] !== t || e[8] !== a || e[9] !== o || e[10] !== i || e[11] !== r ? (v = (C) => {
|
|
1106
|
+
const N = Le[t].safeParse(C);
|
|
1107
|
+
if (!N.success) {
|
|
1108
|
+
Ue(N.error, (O, F) => p.setError(O, F));
|
|
1109
|
+
return;
|
|
1110
|
+
}
|
|
1111
|
+
const R = {
|
|
1112
|
+
fullName: N.data.fullName,
|
|
1113
|
+
..."phone" in N.data && N.data.phone && {
|
|
1114
|
+
phone: N.data.phone
|
|
1115
|
+
},
|
|
1116
|
+
..."email" in N.data && N.data.email && {
|
|
1117
|
+
email: N.data.email
|
|
1118
|
+
}
|
|
1119
|
+
};
|
|
1120
|
+
if (r) {
|
|
1121
|
+
m(!0), r(R).then(() => {
|
|
1122
|
+
i?.();
|
|
1123
|
+
}).catch((O) => {
|
|
1124
|
+
a?.(O);
|
|
1125
|
+
}).finally(() => {
|
|
1126
|
+
m(!1);
|
|
1127
|
+
});
|
|
1128
|
+
return;
|
|
1129
|
+
}
|
|
1130
|
+
o?.(R);
|
|
1131
|
+
}, e[6] = p, e[7] = t, e[8] = a, e[9] = o, e[10] = i, e[11] = r, e[12] = v) : v = e[12];
|
|
1132
|
+
const y = v;
|
|
1133
|
+
let S;
|
|
1134
|
+
e[13] !== t ? (S = (C) => Le[t].safeParse(C).success, e[13] = t, e[14] = S) : S = e[14];
|
|
1135
|
+
const w = S;
|
|
1136
|
+
let x;
|
|
1137
|
+
return e[15] !== y || e[16] !== u || e[17] !== w || e[18] !== h || e[19] !== c || e[20] !== p ? (x = {
|
|
1138
|
+
methods: p,
|
|
1139
|
+
handleSubmit: y,
|
|
1140
|
+
isPhone: h,
|
|
1141
|
+
isForeign: u,
|
|
1142
|
+
isFormValid: w,
|
|
1143
|
+
isSubmitting: c
|
|
1144
|
+
}, e[15] = y, e[16] = u, e[17] = w, e[18] = h, e[19] = c, e[20] = p, e[21] = x) : x = e[21], x;
|
|
1145
|
+
}
|
|
1146
|
+
function He() {
|
|
1147
|
+
const n = _.c(3);
|
|
1148
|
+
let e, t;
|
|
1149
|
+
n[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ d("br", {}), t = /* @__PURE__ */ d("a", { href: "/terms", className: "font-semibold text-black underline", children: "Terms of Use" }), n[0] = e, n[1] = t) : (e = n[0], t = n[1]);
|
|
1150
|
+
let l;
|
|
1151
|
+
return n[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */ L(T, { variant: "body3", align: "center", className: "opacity-60 text-black", children: [
|
|
1152
|
+
"by continuing you agree to Docthub's",
|
|
1153
|
+
e,
|
|
1154
|
+
t,
|
|
1155
|
+
" ",
|
|
1156
|
+
"and",
|
|
1157
|
+
" ",
|
|
1158
|
+
/* @__PURE__ */ d("a", { href: "/privacy", className: "font-semibold text-black underline", children: "Privacy Policy." })
|
|
1159
|
+
] }), n[2] = l) : l = n[2], l;
|
|
1160
|
+
}
|
|
1161
|
+
function nn() {
|
|
1162
|
+
const n = _.c(1);
|
|
1163
|
+
let e;
|
|
1164
|
+
return n[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (e = /* @__PURE__ */ d(M, { icon: /* @__PURE__ */ d("div", { className: "flex items-center justify-center p-2 bg-[#002830] rounded-[10px]", children: /* @__PURE__ */ d(at, { color: "white", className: "h-5 w-5" }) }), iconPosition: "right", size: "large", variant: "outline", "aria-label": "Go to Enterprise Login", className: "hidden sm:flex items-center gap-4 border border-[rgba(0,0,0,0.12)] px-[22px] py-[14px]", children: "Enterprise Login" }), n[0] = e) : e = n[0], e;
|
|
1165
|
+
}
|
|
1166
|
+
function ln(n) {
|
|
1167
|
+
return me({ 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);
|
|
1168
|
+
}
|
|
1169
|
+
function on(n) {
|
|
1170
|
+
return me({ 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
|
|
1171
|
+
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
|
|
1172
|
+
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
|
|
1173
|
+
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
|
|
1174
|
+
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
|
|
1175
|
+
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);
|
|
1176
|
+
}
|
|
1177
|
+
const Ge = (n) => {
|
|
1178
|
+
const e = _.c(19), {
|
|
1179
|
+
handlers: t
|
|
1180
|
+
} = n, {
|
|
1181
|
+
onContinueWithMobile: l,
|
|
1182
|
+
onContinueWithEmail: o,
|
|
1183
|
+
onContinueWithGoogle: r,
|
|
1184
|
+
onContinueWithApple: i
|
|
1185
|
+
} = t;
|
|
1186
|
+
let a;
|
|
1187
|
+
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ d(ce, { children: "Continue with Mobile" }), e[0] = a) : a = e[0];
|
|
1188
|
+
let s;
|
|
1189
|
+
e[1] !== l ? (s = /* @__PURE__ */ d(M, { variant: "outline", size: "large", fullWidth: !0, onClick: l, children: a }), e[1] = l, e[2] = s) : s = e[2];
|
|
1190
|
+
let c;
|
|
1191
|
+
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (c = /* @__PURE__ */ d(ce, { children: "Continue with Email" }), e[3] = c) : c = e[3];
|
|
1192
|
+
let m;
|
|
1193
|
+
e[4] !== o ? (m = /* @__PURE__ */ d(M, { variant: "outline", size: "large", fullWidth: !0, onClick: o, children: c }), e[4] = o, e[5] = m) : m = e[5];
|
|
1194
|
+
let h;
|
|
1195
|
+
e[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ d(on, { "aria-hidden": !0 }), e[6] = h) : h = e[6];
|
|
1196
|
+
let u;
|
|
1197
|
+
e[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (u = /* @__PURE__ */ d(ce, { children: "Continue with Google" }), e[7] = u) : u = e[7];
|
|
1198
|
+
let f;
|
|
1199
|
+
e[8] !== r ? (f = /* @__PURE__ */ d(M, { variant: "outline", size: "large", fullWidth: !0, icon: h, iconPosition: "left", onClick: r, children: u }), e[8] = r, e[9] = f) : f = e[9];
|
|
1200
|
+
let b;
|
|
1201
|
+
e[10] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (b = /* @__PURE__ */ d(ln, { "aria-hidden": !0 }), e[10] = b) : b = e[10];
|
|
1202
|
+
let g;
|
|
1203
|
+
e[11] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (g = /* @__PURE__ */ d(ce, { children: "Continue with Apple" }), e[11] = g) : g = e[11];
|
|
1204
|
+
let p;
|
|
1205
|
+
e[12] !== i ? (p = /* @__PURE__ */ d(M, { variant: "outline", size: "large", fullWidth: !0, icon: b, iconPosition: "left", onClick: i, children: g }), e[12] = i, e[13] = p) : p = e[13];
|
|
1206
|
+
let v;
|
|
1207
|
+
return e[14] !== p || e[15] !== s || e[16] !== m || e[17] !== f ? (v = /* @__PURE__ */ L("div", { className: "w-full flex flex-col gap-3", children: [
|
|
1208
|
+
s,
|
|
1209
|
+
m,
|
|
1210
|
+
f,
|
|
1211
|
+
p
|
|
1212
|
+
] }), e[14] = p, e[15] = s, e[16] = m, e[17] = f, e[18] = v) : v = e[18], v;
|
|
1213
|
+
}, ce = (n) => {
|
|
1214
|
+
const e = _.c(2), {
|
|
1215
|
+
children: t
|
|
1216
|
+
} = n;
|
|
1217
|
+
let l;
|
|
1218
|
+
return e[0] !== t ? (l = /* @__PURE__ */ d(T, { variant: "textLabel1", weight: "semiBold", align: "center", className: "opacity-80", children: t }), e[0] = t, e[1] = l) : l = e[1], l;
|
|
1219
|
+
};
|
|
1220
|
+
function vn(n) {
|
|
1221
|
+
const e = _.c(2), t = Be(n);
|
|
1222
|
+
let l;
|
|
1223
|
+
return e[0] !== t ? (l = /* @__PURE__ */ d(Ge, { handlers: t }), e[0] = t, e[1] = l) : l = e[1], l;
|
|
1224
|
+
}
|
|
1225
|
+
const yn = (n) => {
|
|
1226
|
+
const e = _.c(5), t = Be(n);
|
|
1227
|
+
let l;
|
|
1228
|
+
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (l = /* @__PURE__ */ d(nn, {}), e[0] = l) : l = e[0];
|
|
1229
|
+
let o;
|
|
1230
|
+
e[1] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (o = /* @__PURE__ */ d(T, { variant: "title1", weight: "bold", align: "center", children: "Healthcare Career App" }), e[1] = o) : o = e[1];
|
|
1231
|
+
let r;
|
|
1232
|
+
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (r = /* @__PURE__ */ d(He, {}), e[2] = r) : r = e[2];
|
|
1233
|
+
let i;
|
|
1234
|
+
return e[3] !== t ? (i = /* @__PURE__ */ d(ie, { layoutType: "withSlider", variant: "desktop", header: l, logo: "/main-logo.svg", align: "center", title: o, description: "Welcome to the Healthcare Career App. Please sign in to continue.", footer: r, children: /* @__PURE__ */ d(Ge, { handlers: t }) }), e[3] = t, e[4] = i) : i = e[4], i;
|
|
1235
|
+
};
|
|
1236
|
+
function rn(n) {
|
|
1237
|
+
const e = _.c(10), {
|
|
1238
|
+
name: t,
|
|
1239
|
+
label: l,
|
|
1240
|
+
className: o,
|
|
1241
|
+
control: r,
|
|
1242
|
+
length: i,
|
|
1243
|
+
inputClassName: a,
|
|
1244
|
+
autoFocus: s
|
|
1245
|
+
} = n, c = i === void 0 ? 6 : i, m = ne(), h = r || m.control;
|
|
1246
|
+
let u;
|
|
1247
|
+
e[0] !== s || e[1] !== o || e[2] !== a || e[3] !== l || e[4] !== c ? (u = (b) => {
|
|
1248
|
+
const {
|
|
1249
|
+
field: g,
|
|
1250
|
+
fieldState: p
|
|
1251
|
+
} = b;
|
|
1252
|
+
return /* @__PURE__ */ L("div", { children: [
|
|
1253
|
+
l && /* @__PURE__ */ d("label", { className: "block mb-1", children: l }),
|
|
1254
|
+
/* @__PURE__ */ d(Ke, { length: c, value: g.value || [], onChange: g.onChange, ...s !== void 0 && {
|
|
1255
|
+
autoFocus: s
|
|
1256
|
+
}, ...o && {
|
|
1257
|
+
className: o
|
|
1258
|
+
}, ...a && {
|
|
1259
|
+
inputClassName: a
|
|
1260
|
+
}, ...p.error?.message !== void 0 && p.error?.message !== "" && {
|
|
1261
|
+
error: p.error.message
|
|
1262
|
+
} })
|
|
1263
|
+
] });
|
|
1264
|
+
}, e[0] = s, e[1] = o, e[2] = a, e[3] = l, e[4] = c, e[5] = u) : u = e[5];
|
|
1265
|
+
let f;
|
|
1266
|
+
return e[6] !== t || e[7] !== h || e[8] !== u ? (f = /* @__PURE__ */ d(be, { name: t, control: h, render: u }), e[6] = t, e[7] = h, e[8] = u, e[9] = f) : f = e[9], f;
|
|
1267
|
+
}
|
|
1268
|
+
function sn(n) {
|
|
1269
|
+
const e = _.c(26), {
|
|
1270
|
+
mode: t,
|
|
1271
|
+
title: l,
|
|
1272
|
+
recipientDisplay: o,
|
|
1273
|
+
isForeignUser: r,
|
|
1274
|
+
handleSubmit: i,
|
|
1275
|
+
handleResend: a,
|
|
1276
|
+
canResend: s,
|
|
1277
|
+
timerText: c,
|
|
1278
|
+
isSubmitting: m
|
|
1279
|
+
} = n, h = ne();
|
|
1280
|
+
let u;
|
|
1281
|
+
e[0] !== i || e[1] !== h ? (u = h.handleSubmit(i), e[0] = i, e[1] = h, e[2] = u) : u = e[2];
|
|
1282
|
+
let f;
|
|
1283
|
+
e[3] !== l ? (f = /* @__PURE__ */ d(T, { variant: "h5", weight: "extraBold", align: "left", className: "mb-2 text-black", children: l }), e[3] = l, e[4] = f) : f = e[4];
|
|
1284
|
+
const b = r ? "mb-2 text-black/80" : "mb-6 text-black/80";
|
|
1285
|
+
let g;
|
|
1286
|
+
e[5] !== o || e[6] !== b ? (g = /* @__PURE__ */ d(T, { variant: "title2", align: "left", className: b, children: o }), e[5] = o, e[6] = b, e[7] = g) : g = e[7];
|
|
1287
|
+
let p;
|
|
1288
|
+
e[8] !== r || e[9] !== t ? (p = r && /* @__PURE__ */ d(T, { variant: "body2", align: "left", className: "mb-6 text-black/80", children: qt[t] }), e[8] = r, e[9] = t, e[10] = p) : p = e[10];
|
|
1289
|
+
let v;
|
|
1290
|
+
e[11] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (v = /* @__PURE__ */ d("div", { className: "mb-4 flex w-full flex-col gap-[12px]", children: /* @__PURE__ */ d(rn, { name: "otp", length: fe, autoFocus: !0 }) }), e[11] = v) : v = e[11];
|
|
1291
|
+
let y;
|
|
1292
|
+
e[12] !== s || e[13] !== a || e[14] !== c ? (y = /* @__PURE__ */ d("div", { className: "mb-6 flex items-center gap-2", children: s ? /* @__PURE__ */ d(M, { type: "button", variant: "outline", size: "small", onClick: a, children: "Resend Code" }) : /* @__PURE__ */ d(T, { variant: "body2", align: "left", className: "text-black/80", children: c }) }), e[12] = s, e[13] = a, e[14] = c, e[15] = y) : y = e[15];
|
|
1293
|
+
const S = m ? "Verifying…" : "Submit";
|
|
1294
|
+
let w;
|
|
1295
|
+
e[16] !== m || e[17] !== S ? (w = /* @__PURE__ */ d(M, { type: "submit", variant: "primary", size: "large", fullWidth: !0, disabled: m, children: S }), e[16] = m, e[17] = S, e[18] = w) : w = e[18];
|
|
1296
|
+
let x;
|
|
1297
|
+
return e[19] !== u || e[20] !== f || e[21] !== g || e[22] !== p || e[23] !== y || e[24] !== w ? (x = /* @__PURE__ */ L("form", { onSubmit: u, className: "flex w-full flex-col", children: [
|
|
1298
|
+
f,
|
|
1299
|
+
g,
|
|
1300
|
+
p,
|
|
1301
|
+
v,
|
|
1302
|
+
y,
|
|
1303
|
+
w
|
|
1304
|
+
] }), e[19] = u, e[20] = f, e[21] = g, e[22] = p, e[23] = y, e[24] = w, e[25] = x) : x = e[25], x;
|
|
1305
|
+
}
|
|
1306
|
+
function an(n) {
|
|
1307
|
+
const e = _.c(20), {
|
|
1308
|
+
mode: t,
|
|
1309
|
+
title: l,
|
|
1310
|
+
recipientDisplay: o,
|
|
1311
|
+
isForeignUser: r,
|
|
1312
|
+
onSubmit: i,
|
|
1313
|
+
onResendCode: a,
|
|
1314
|
+
submitApi: s,
|
|
1315
|
+
onSuccess: c,
|
|
1316
|
+
onError: m
|
|
1317
|
+
} = n, h = r === void 0 ? !1 : r;
|
|
1318
|
+
let u;
|
|
1319
|
+
e[0] !== t || e[1] !== m || e[2] !== a || e[3] !== i || e[4] !== c || e[5] !== s ? (u = {
|
|
1320
|
+
mode: t,
|
|
1321
|
+
onSubmit: i,
|
|
1322
|
+
onResendCode: a,
|
|
1323
|
+
submitApi: s,
|
|
1324
|
+
onSuccess: c,
|
|
1325
|
+
onError: m
|
|
1326
|
+
}, e[0] = t, e[1] = m, e[2] = a, e[3] = i, e[4] = c, e[5] = s, e[6] = u) : u = e[6];
|
|
1327
|
+
const {
|
|
1328
|
+
methods: f,
|
|
1329
|
+
handleSubmit: b,
|
|
1330
|
+
handleResend: g,
|
|
1331
|
+
canResend: p,
|
|
1332
|
+
timerText: v,
|
|
1333
|
+
isSubmitting: y
|
|
1334
|
+
} = Kt(u), S = l ?? Yt[t];
|
|
1335
|
+
let w;
|
|
1336
|
+
e[7] !== p || e[8] !== S || e[9] !== g || e[10] !== b || e[11] !== h || e[12] !== y || e[13] !== t || e[14] !== o || e[15] !== v ? (w = /* @__PURE__ */ d(sn, { mode: t, title: S, recipientDisplay: o, isForeignUser: h, handleSubmit: b, handleResend: g, canResend: p, timerText: v, isSubmitting: y }), e[7] = p, e[8] = S, e[9] = g, e[10] = b, e[11] = h, e[12] = y, e[13] = t, e[14] = o, e[15] = v, e[16] = w) : w = e[16];
|
|
1337
|
+
let x;
|
|
1338
|
+
return e[17] !== f || e[18] !== w ? (x = /* @__PURE__ */ d(ye, { ...f, children: w }), e[17] = f, e[18] = w, e[19] = x) : x = e[19], x;
|
|
1339
|
+
}
|
|
1340
|
+
function Sn(n) {
|
|
1341
|
+
const e = _.c(23);
|
|
1342
|
+
let t, l, o, r;
|
|
1343
|
+
e[0] !== n ? ({
|
|
1344
|
+
layoutType: o,
|
|
1345
|
+
variant: r,
|
|
1346
|
+
onBack: l,
|
|
1347
|
+
...t
|
|
1348
|
+
} = n, e[0] = n, e[1] = t, e[2] = l, e[3] = o, e[4] = r) : (t = e[1], l = e[2], o = e[3], r = e[4]);
|
|
1349
|
+
const i = o === void 0 ? "withSlider" : o;
|
|
1350
|
+
let a;
|
|
1351
|
+
e[5] !== l ? (a = l != null ? /* @__PURE__ */ d(M, { icon: /* @__PURE__ */ d(Se, {}), iconOnly: !0, onClick: l, size: "medium", variant: "outline", "aria-label": "Go back", className: "mb-6 h-10 w-10" }) : void 0, e[5] = l, e[6] = a) : a = e[6];
|
|
1352
|
+
let s;
|
|
1353
|
+
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] !== l ? (s = /* @__PURE__ */ d(an, { 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 }), 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] = l, e[17] = s) : s = e[17];
|
|
1354
|
+
let c;
|
|
1355
|
+
return e[18] !== i || e[19] !== a || e[20] !== s || e[21] !== r ? (c = /* @__PURE__ */ d(ie, { layoutType: i, variant: r, contentWidth: "sm", align: "left", backButton: a, children: s }), e[18] = i, e[19] = a, e[20] = s, e[21] = r, e[22] = c) : c = e[22], c;
|
|
1356
|
+
}
|
|
1357
|
+
function cn(n) {
|
|
1358
|
+
const e = _.c(21);
|
|
1359
|
+
let t, l;
|
|
1360
|
+
e[0] !== n ? ({
|
|
1361
|
+
onUseAnotherMethod: l,
|
|
1362
|
+
...t
|
|
1363
|
+
} = n, e[0] = n, e[1] = t, e[2] = l) : (t = e[1], l = e[2]);
|
|
1364
|
+
let o;
|
|
1365
|
+
e[3] !== t.continueApi || e[4] !== t.lastUsedMethod || e[5] !== t.onContinueWithLastMethod || e[6] !== t.onError || e[7] !== t.onSuccess ? (o = {
|
|
1366
|
+
lastUsedMethod: t.lastUsedMethod,
|
|
1367
|
+
onContinueWithLastMethod: t.onContinueWithLastMethod,
|
|
1368
|
+
continueApi: t.continueApi,
|
|
1369
|
+
onSuccess: t.onSuccess,
|
|
1370
|
+
onError: t.onError
|
|
1371
|
+
}, e[3] = t.continueApi, e[4] = t.lastUsedMethod, e[5] = t.onContinueWithLastMethod, e[6] = t.onError, e[7] = t.onSuccess, e[8] = o) : o = e[8];
|
|
1372
|
+
const {
|
|
1373
|
+
handleContinue: r,
|
|
1374
|
+
isSubmitting: i,
|
|
1375
|
+
lastUsedMethod: a
|
|
1376
|
+
} = en(o), s = i ? "Continuing…" : `Continue with ${a}`;
|
|
1377
|
+
let c;
|
|
1378
|
+
e[9] !== s ? (c = /* @__PURE__ */ d(T, { variant: "textLabel1", weight: "semiBold", align: "center", className: "text-white", children: s }), e[9] = s, e[10] = c) : c = e[10];
|
|
1379
|
+
let m;
|
|
1380
|
+
e[11] !== r || e[12] !== i || e[13] !== c ? (m = /* @__PURE__ */ d(M, { variant: "primary", size: "large", fullWidth: !0, onClick: r, disabled: i, children: c }), e[11] = r, e[12] = i, e[13] = c, e[14] = m) : m = e[14];
|
|
1381
|
+
let h;
|
|
1382
|
+
e[15] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (h = /* @__PURE__ */ d(T, { variant: "textLabel1", weight: "semiBold", align: "center", className: "opacity-80", children: "Use another method" }), e[15] = h) : h = e[15];
|
|
1383
|
+
let u;
|
|
1384
|
+
e[16] !== l ? (u = /* @__PURE__ */ d(M, { variant: "outline", size: "large", fullWidth: !0, onClick: l, children: h }), e[16] = l, e[17] = u) : u = e[17];
|
|
1385
|
+
let f;
|
|
1386
|
+
return e[18] !== m || e[19] !== u ? (f = /* @__PURE__ */ L("div", { className: "w-full flex flex-col gap-[12px]", children: [
|
|
1387
|
+
m,
|
|
1388
|
+
u
|
|
1389
|
+
] }), e[18] = m, e[19] = u, e[20] = f) : f = e[20], f;
|
|
1390
|
+
}
|
|
1391
|
+
function xn(n) {
|
|
1392
|
+
const e = _.c(19), {
|
|
1393
|
+
lastUsedMethod: t,
|
|
1394
|
+
onContinueWithLastMethod: l,
|
|
1395
|
+
onUseAnotherMethod: o,
|
|
1396
|
+
continueApi: r,
|
|
1397
|
+
onSuccess: i,
|
|
1398
|
+
onError: a,
|
|
1399
|
+
layoutType: s,
|
|
1400
|
+
variant: c
|
|
1401
|
+
} = n, m = t === void 0 ? "Mobile" : t, h = s === void 0 ? "withSlider" : s, u = c === "mobile" || h === "standalone";
|
|
1402
|
+
let f;
|
|
1403
|
+
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ d("div", { className: "h-[30px] w-[140px]", children: /* @__PURE__ */ d("img", { src: "/main-logo.svg", alt: "Docthub", className: "block h-full w-full object-cover" }) }), e[0] = f) : f = e[0];
|
|
1404
|
+
const b = f;
|
|
1405
|
+
let g;
|
|
1406
|
+
e[1] !== u ? (g = u ? /* @__PURE__ */ d(T, { variant: "title1", weight: "bold", align: "center", className: "text-[#002830]", children: "Welcome Back!" }) : /* @__PURE__ */ L(T, { variant: "h6", weight: "extraBold", align: "left", className: "text-black", children: [
|
|
1407
|
+
" ",
|
|
1408
|
+
"Welcome Back!",
|
|
1409
|
+
" "
|
|
1410
|
+
] }), e[1] = u, e[2] = g) : g = e[2];
|
|
1411
|
+
let p;
|
|
1412
|
+
e[3] !== m ? (p = /* @__PURE__ */ L(T, { variant: "body1", align: "center", color: "black", children: [
|
|
1413
|
+
"Last time you used ",
|
|
1414
|
+
m,
|
|
1415
|
+
" to log in."
|
|
1416
|
+
] }), e[3] = m, e[4] = p) : p = e[4];
|
|
1417
|
+
let v;
|
|
1418
|
+
e[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (v = /* @__PURE__ */ d(He, {}), e[5] = v) : v = e[5];
|
|
1419
|
+
let y;
|
|
1420
|
+
e[6] !== r || e[7] !== m || e[8] !== l || e[9] !== a || e[10] !== i || e[11] !== o ? (y = /* @__PURE__ */ d(cn, { lastUsedMethod: m, onContinueWithLastMethod: l, onUseAnotherMethod: o, continueApi: r, onSuccess: i, onError: a }), e[6] = r, e[7] = m, e[8] = l, e[9] = a, e[10] = i, e[11] = o, e[12] = y) : y = e[12];
|
|
1421
|
+
let S;
|
|
1422
|
+
return e[13] !== h || e[14] !== g || e[15] !== p || e[16] !== y || e[17] !== c ? (S = /* @__PURE__ */ d(ie, { layoutType: h, variant: c, logo: b, title: g, description: p, footer: v, children: y }), e[13] = h, e[14] = g, e[15] = p, e[16] = y, e[17] = c, e[18] = S) : S = e[18], S;
|
|
1423
|
+
}
|
|
1424
|
+
function un(n) {
|
|
1425
|
+
const e = _.c(13), {
|
|
1426
|
+
isPhone: t,
|
|
1427
|
+
handleSubmit: l,
|
|
1428
|
+
isSubmitting: o
|
|
1429
|
+
} = n, r = ne();
|
|
1430
|
+
let i;
|
|
1431
|
+
e[0] !== l || e[1] !== r ? (i = r.handleSubmit(l), e[0] = l, e[1] = r, e[2] = i) : i = e[2];
|
|
1432
|
+
let a;
|
|
1433
|
+
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (a = /* @__PURE__ */ d(pe, { name: "fullName", label: "Full name", placeholder: "Full name", type: "text", className: "w-full", autoFocus: !0 }), e[3] = a) : a = e[3];
|
|
1434
|
+
let s;
|
|
1435
|
+
e[4] !== t ? (s = /* @__PURE__ */ L("div", { className: "mb-6 flex w-full flex-col gap-[12px]", children: [
|
|
1436
|
+
a,
|
|
1437
|
+
t ? /* @__PURE__ */ d(je, { name: "phone", label: "Phone number", placeholder: "Phone number", defaultCountry: "IN" }) : /* @__PURE__ */ d(pe, { name: "email", label: "Email address", placeholder: "Email address", type: "email", className: "w-full" })
|
|
1438
|
+
] }), e[4] = t, e[5] = s) : s = e[5];
|
|
1439
|
+
const c = o ? "Continuing…" : "Continue";
|
|
1440
|
+
let m;
|
|
1441
|
+
e[6] !== o || e[7] !== c ? (m = /* @__PURE__ */ d(M, { type: "submit", variant: "primary", size: "large", fullWidth: !0, disabled: o, children: c }), e[6] = o, e[7] = c, e[8] = m) : m = e[8];
|
|
1442
|
+
let h;
|
|
1443
|
+
return e[9] !== i || e[10] !== s || e[11] !== m ? (h = /* @__PURE__ */ L("form", { onSubmit: i, className: "w-full flex flex-col items-center", children: [
|
|
1444
|
+
s,
|
|
1445
|
+
m
|
|
1446
|
+
] }), e[9] = i, e[10] = s, e[11] = m, e[12] = h) : h = e[12], h;
|
|
1447
|
+
}
|
|
1448
|
+
function dn(n) {
|
|
1449
|
+
const e = _.c(14), {
|
|
1450
|
+
loginMethod: t,
|
|
1451
|
+
pendingPhone: l,
|
|
1452
|
+
onSubmit: o,
|
|
1453
|
+
submitApi: r,
|
|
1454
|
+
onSuccess: i,
|
|
1455
|
+
onError: a
|
|
1456
|
+
} = n, s = l === void 0 ? "" : l, c = t === "phone" ? "email" : "phone";
|
|
1457
|
+
let m;
|
|
1458
|
+
e[0] !== c || e[1] !== a || e[2] !== o || e[3] !== i || e[4] !== s || e[5] !== r ? (m = {
|
|
1459
|
+
mode: c,
|
|
1460
|
+
defaultPhone: s,
|
|
1461
|
+
onSubmit: o,
|
|
1462
|
+
submitApi: r,
|
|
1463
|
+
onSuccess: i,
|
|
1464
|
+
onError: a
|
|
1465
|
+
}, e[0] = c, e[1] = a, e[2] = o, e[3] = i, e[4] = s, e[5] = r, e[6] = m) : m = e[6];
|
|
1466
|
+
const {
|
|
1467
|
+
methods: h,
|
|
1468
|
+
handleSubmit: u,
|
|
1469
|
+
isPhone: f,
|
|
1470
|
+
isSubmitting: b
|
|
1471
|
+
} = tn(m);
|
|
1472
|
+
let g;
|
|
1473
|
+
e[7] !== u || e[8] !== f || e[9] !== b ? (g = /* @__PURE__ */ d(un, { isPhone: f, handleSubmit: u, isSubmitting: b }), e[7] = u, e[8] = f, e[9] = b, e[10] = g) : g = e[10];
|
|
1474
|
+
let p;
|
|
1475
|
+
return e[11] !== h || e[12] !== g ? (p = /* @__PURE__ */ d(ye, { ...h, children: g }), e[11] = h, e[12] = g, e[13] = p) : p = e[13], p;
|
|
1476
|
+
}
|
|
1477
|
+
function wn(n) {
|
|
1478
|
+
const e = _.c(21), {
|
|
1479
|
+
layoutType: t,
|
|
1480
|
+
variant: l
|
|
1481
|
+
} = n, o = t === void 0 ? "standalone" : t, r = l === void 0 ? "mobile" : l;
|
|
1482
|
+
let i;
|
|
1483
|
+
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 ? (i = {
|
|
1484
|
+
userType: n.userType,
|
|
1485
|
+
loginMethod: n.loginMethod,
|
|
1486
|
+
signupCollectField: n.signupCollectField,
|
|
1487
|
+
pendingPhone: n.pendingPhone,
|
|
1488
|
+
onSubmit: n.onSubmit,
|
|
1489
|
+
submitApi: n.submitApi,
|
|
1490
|
+
onSuccess: n.onSuccess,
|
|
1491
|
+
onError: n.onError
|
|
1492
|
+
}, 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] = i) : i = e[8];
|
|
1493
|
+
const a = i;
|
|
1494
|
+
let s;
|
|
1495
|
+
e[9] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (s = /* @__PURE__ */ d("img", { src: "/docthub.svg", alt: "Docthub Logo", width: 46, height: 46 }), e[9] = s) : s = e[9];
|
|
1496
|
+
const c = s;
|
|
1497
|
+
let m;
|
|
1498
|
+
e[10] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */ d(T, { variant: "h5", weight: "extraBold", align: "center", className: "text-black", children: "Welcome to Docthub" }), e[10] = m) : m = e[10];
|
|
1499
|
+
const h = m, u = n.loginMethod === "phone" ? "email" : "phone";
|
|
1500
|
+
let f;
|
|
1501
|
+
e[11] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (f = /* @__PURE__ */ d("span", { className: "font-bold", children: "Full Name" }), e[11] = f) : f = e[11];
|
|
1502
|
+
const b = u === "phone" ? "Phone Number" : "Email Address";
|
|
1503
|
+
let g;
|
|
1504
|
+
e[12] !== b ? (g = /* @__PURE__ */ L(T, { variant: "title2", align: "center", children: [
|
|
1505
|
+
"Please tell us your ",
|
|
1506
|
+
f,
|
|
1507
|
+
" and",
|
|
1508
|
+
" ",
|
|
1509
|
+
/* @__PURE__ */ d("span", { className: "font-bold", children: b }),
|
|
1510
|
+
" ",
|
|
1511
|
+
"for extended security of your account."
|
|
1512
|
+
] }), e[12] = b, e[13] = g) : g = e[13];
|
|
1513
|
+
const p = g;
|
|
1514
|
+
let v;
|
|
1515
|
+
e[14] !== a ? (v = /* @__PURE__ */ d(dn, { ...a }), e[14] = a, e[15] = v) : v = e[15];
|
|
1516
|
+
let y;
|
|
1517
|
+
return e[16] !== p || e[17] !== o || e[18] !== v || e[19] !== r ? (y = /* @__PURE__ */ d(ie, { layoutType: o, variant: r, contentWidth: "sm", logo: c, title: h, description: p, children: v }), e[16] = p, e[17] = o, e[18] = v, e[19] = r, e[20] = y) : y = e[20], y;
|
|
1518
|
+
}
|
|
1519
|
+
export {
|
|
1520
|
+
ie as A,
|
|
1521
|
+
Yt as D,
|
|
1522
|
+
yt as I,
|
|
1523
|
+
Dt as L,
|
|
1524
|
+
vn as M,
|
|
1525
|
+
an as O,
|
|
1526
|
+
cn as R,
|
|
1527
|
+
dn as S,
|
|
1528
|
+
bn as a,
|
|
1529
|
+
yn as b,
|
|
1530
|
+
Sn as c,
|
|
1531
|
+
xn as d,
|
|
1532
|
+
wn as e,
|
|
1533
|
+
_ as f,
|
|
1534
|
+
H as g,
|
|
1535
|
+
xt as h,
|
|
1536
|
+
fe as i,
|
|
1537
|
+
Lt as j,
|
|
1538
|
+
Rt as k,
|
|
1539
|
+
jt as l,
|
|
1540
|
+
Mt as m,
|
|
1541
|
+
Be as n,
|
|
1542
|
+
Kt as o,
|
|
1543
|
+
en as p,
|
|
1544
|
+
tn as q,
|
|
1545
|
+
Nt as u
|
|
1546
|
+
};
|