@incodetech/web 0.0.0-dev-20260126-4504c5b
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/aligndevicelottie-DlQCRPfM.js +29 -0
- package/dist/backdevicelottie-B4NgyWmX.js +29 -0
- package/dist/base.css +1634 -0
- package/dist/baseTutorial-Be85FuyO.js +383 -0
- package/dist/blurdevicelottie-_BZRug1c.js +29 -0
- package/dist/browser-ponyfill-B6W6hHVY.js +344 -0
- package/dist/email/email.es.js +137 -0
- package/dist/email/styles.css +123 -0
- package/dist/flip-animation-COR596wy.js +29 -0
- package/dist/flow/flow.es.js +540 -0
- package/dist/flow/styles.css +3204 -0
- package/dist/frontdevicelottie-KhKxT5n9.js +29 -0
- package/dist/glaredevicelottie-DLuIStvb.js +29 -0
- package/dist/id/id.es.js +1497 -0
- package/dist/id/styles.css +1587 -0
- package/dist/id-laser-h-BBV3r3rz.js +29 -0
- package/dist/id-laser-v-BTHJaSfx.js +29 -0
- package/dist/id-tutorial-B-F5Q28m.js +29 -0
- package/dist/incodeModule-DR92HDjR.js +257 -0
- package/dist/index.es.js +6 -0
- package/dist/instance-B-q0ZREN.js +2140 -0
- package/dist/otpInput-Dm1LhnDm.js +151 -0
- package/dist/page-CITAo3qf.js +189 -0
- package/dist/passport-tutorial-CaYBFTqt.js +29 -0
- package/dist/phone/phone.es.js +3442 -0
- package/dist/phone/styles.css +305 -0
- package/dist/selfie/selfie.es.js +570 -0
- package/dist/selfie/styles.css +638 -0
- package/dist/selfieTutorial-Dm_p0ke9.js +29 -0
- package/dist/setup-BhetRn4n.js +20 -0
- package/dist/spinner-CQtj_FFo.js +65 -0
- package/dist/themes/dark.css +797 -0
- package/dist/themes/light.css +688 -0
- package/dist/types/base.d.ts +1 -0
- package/dist/types/dark.d.ts +1 -0
- package/dist/types/email.d.ts +57 -0
- package/dist/types/flow.d.ts +69 -0
- package/dist/types/id.d.ts +34 -0
- package/dist/types/index.d.ts +38 -0
- package/dist/types/light.d.ts +1 -0
- package/dist/types/phone.d.ts +58 -0
- package/dist/types/selfie.d.ts +31 -0
- package/dist/types/styles.d.ts +1 -0
- package/dist/types/themes/dark.d.ts +1 -0
- package/dist/types/themes/light.d.ts +1 -0
- package/dist/uiConfig-DEqynrWx.js +23 -0
- package/dist/vendor-preact-CjD4WiuC.js +593 -0
- package/package.json +100 -0
|
@@ -0,0 +1,344 @@
|
|
|
1
|
+
function z(c, y) {
|
|
2
|
+
for (var w = 0; w < y.length; w++) {
|
|
3
|
+
const p = y[w];
|
|
4
|
+
if (typeof p != "string" && !Array.isArray(p)) {
|
|
5
|
+
for (const l in p)
|
|
6
|
+
if (l !== "default" && !(l in c)) {
|
|
7
|
+
const b = Object.getOwnPropertyDescriptor(p, l);
|
|
8
|
+
b && Object.defineProperty(c, l, b.get ? b : {
|
|
9
|
+
enumerable: !0,
|
|
10
|
+
get: () => p[l]
|
|
11
|
+
});
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
return Object.freeze(Object.defineProperty(c, Symbol.toStringTag, { value: "Module" }));
|
|
16
|
+
}
|
|
17
|
+
var R = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
18
|
+
function X(c) {
|
|
19
|
+
return c && c.__esModule && Object.prototype.hasOwnProperty.call(c, "default") ? c.default : c;
|
|
20
|
+
}
|
|
21
|
+
var A = { exports: {} }, U;
|
|
22
|
+
function J() {
|
|
23
|
+
return U || (U = 1, (function(c, y) {
|
|
24
|
+
var w = typeof globalThis < "u" && globalThis || typeof self < "u" && self || typeof R < "u" && R, p = (function() {
|
|
25
|
+
function b() {
|
|
26
|
+
this.fetch = !1, this.DOMException = w.DOMException;
|
|
27
|
+
}
|
|
28
|
+
return b.prototype = w, new b();
|
|
29
|
+
})();
|
|
30
|
+
(function(b) {
|
|
31
|
+
(function(u) {
|
|
32
|
+
var a = typeof b < "u" && b || typeof self < "u" && self || typeof a < "u" && a, f = {
|
|
33
|
+
searchParams: "URLSearchParams" in a,
|
|
34
|
+
iterable: "Symbol" in a && "iterator" in Symbol,
|
|
35
|
+
blob: "FileReader" in a && "Blob" in a && (function() {
|
|
36
|
+
try {
|
|
37
|
+
return new Blob(), !0;
|
|
38
|
+
} catch {
|
|
39
|
+
return !1;
|
|
40
|
+
}
|
|
41
|
+
})(),
|
|
42
|
+
formData: "FormData" in a,
|
|
43
|
+
arrayBuffer: "ArrayBuffer" in a
|
|
44
|
+
};
|
|
45
|
+
function S(e) {
|
|
46
|
+
return e && DataView.prototype.isPrototypeOf(e);
|
|
47
|
+
}
|
|
48
|
+
if (f.arrayBuffer)
|
|
49
|
+
var F = [
|
|
50
|
+
"[object Int8Array]",
|
|
51
|
+
"[object Uint8Array]",
|
|
52
|
+
"[object Uint8ClampedArray]",
|
|
53
|
+
"[object Int16Array]",
|
|
54
|
+
"[object Uint16Array]",
|
|
55
|
+
"[object Int32Array]",
|
|
56
|
+
"[object Uint32Array]",
|
|
57
|
+
"[object Float32Array]",
|
|
58
|
+
"[object Float64Array]"
|
|
59
|
+
], M = ArrayBuffer.isView || function(e) {
|
|
60
|
+
return e && F.indexOf(Object.prototype.toString.call(e)) > -1;
|
|
61
|
+
};
|
|
62
|
+
function v(e) {
|
|
63
|
+
if (typeof e != "string" && (e = String(e)), /[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e) || e === "")
|
|
64
|
+
throw new TypeError('Invalid character in header field name: "' + e + '"');
|
|
65
|
+
return e.toLowerCase();
|
|
66
|
+
}
|
|
67
|
+
function E(e) {
|
|
68
|
+
return typeof e != "string" && (e = String(e)), e;
|
|
69
|
+
}
|
|
70
|
+
function T(e) {
|
|
71
|
+
var t = {
|
|
72
|
+
next: function() {
|
|
73
|
+
var r = e.shift();
|
|
74
|
+
return { done: r === void 0, value: r };
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
return f.iterable && (t[Symbol.iterator] = function() {
|
|
78
|
+
return t;
|
|
79
|
+
}), t;
|
|
80
|
+
}
|
|
81
|
+
function s(e) {
|
|
82
|
+
this.map = {}, e instanceof s ? e.forEach(function(t, r) {
|
|
83
|
+
this.append(r, t);
|
|
84
|
+
}, this) : Array.isArray(e) ? e.forEach(function(t) {
|
|
85
|
+
this.append(t[0], t[1]);
|
|
86
|
+
}, this) : e && Object.getOwnPropertyNames(e).forEach(function(t) {
|
|
87
|
+
this.append(t, e[t]);
|
|
88
|
+
}, this);
|
|
89
|
+
}
|
|
90
|
+
s.prototype.append = function(e, t) {
|
|
91
|
+
e = v(e), t = E(t);
|
|
92
|
+
var r = this.map[e];
|
|
93
|
+
this.map[e] = r ? r + ", " + t : t;
|
|
94
|
+
}, s.prototype.delete = function(e) {
|
|
95
|
+
delete this.map[v(e)];
|
|
96
|
+
}, s.prototype.get = function(e) {
|
|
97
|
+
return e = v(e), this.has(e) ? this.map[e] : null;
|
|
98
|
+
}, s.prototype.has = function(e) {
|
|
99
|
+
return this.map.hasOwnProperty(v(e));
|
|
100
|
+
}, s.prototype.set = function(e, t) {
|
|
101
|
+
this.map[v(e)] = E(t);
|
|
102
|
+
}, s.prototype.forEach = function(e, t) {
|
|
103
|
+
for (var r in this.map)
|
|
104
|
+
this.map.hasOwnProperty(r) && e.call(t, this.map[r], r, this);
|
|
105
|
+
}, s.prototype.keys = function() {
|
|
106
|
+
var e = [];
|
|
107
|
+
return this.forEach(function(t, r) {
|
|
108
|
+
e.push(r);
|
|
109
|
+
}), T(e);
|
|
110
|
+
}, s.prototype.values = function() {
|
|
111
|
+
var e = [];
|
|
112
|
+
return this.forEach(function(t) {
|
|
113
|
+
e.push(t);
|
|
114
|
+
}), T(e);
|
|
115
|
+
}, s.prototype.entries = function() {
|
|
116
|
+
var e = [];
|
|
117
|
+
return this.forEach(function(t, r) {
|
|
118
|
+
e.push([r, t]);
|
|
119
|
+
}), T(e);
|
|
120
|
+
}, f.iterable && (s.prototype[Symbol.iterator] = s.prototype.entries);
|
|
121
|
+
function B(e) {
|
|
122
|
+
if (e.bodyUsed)
|
|
123
|
+
return Promise.reject(new TypeError("Already read"));
|
|
124
|
+
e.bodyUsed = !0;
|
|
125
|
+
}
|
|
126
|
+
function P(e) {
|
|
127
|
+
return new Promise(function(t, r) {
|
|
128
|
+
e.onload = function() {
|
|
129
|
+
t(e.result);
|
|
130
|
+
}, e.onerror = function() {
|
|
131
|
+
r(e.error);
|
|
132
|
+
};
|
|
133
|
+
});
|
|
134
|
+
}
|
|
135
|
+
function I(e) {
|
|
136
|
+
var t = new FileReader(), r = P(t);
|
|
137
|
+
return t.readAsArrayBuffer(e), r;
|
|
138
|
+
}
|
|
139
|
+
function q(e) {
|
|
140
|
+
var t = new FileReader(), r = P(t);
|
|
141
|
+
return t.readAsText(e), r;
|
|
142
|
+
}
|
|
143
|
+
function H(e) {
|
|
144
|
+
for (var t = new Uint8Array(e), r = new Array(t.length), n = 0; n < t.length; n++)
|
|
145
|
+
r[n] = String.fromCharCode(t[n]);
|
|
146
|
+
return r.join("");
|
|
147
|
+
}
|
|
148
|
+
function D(e) {
|
|
149
|
+
if (e.slice)
|
|
150
|
+
return e.slice(0);
|
|
151
|
+
var t = new Uint8Array(e.byteLength);
|
|
152
|
+
return t.set(new Uint8Array(e)), t.buffer;
|
|
153
|
+
}
|
|
154
|
+
function x() {
|
|
155
|
+
return this.bodyUsed = !1, this._initBody = function(e) {
|
|
156
|
+
this.bodyUsed = this.bodyUsed, this._bodyInit = e, e ? typeof e == "string" ? this._bodyText = e : f.blob && Blob.prototype.isPrototypeOf(e) ? this._bodyBlob = e : f.formData && FormData.prototype.isPrototypeOf(e) ? this._bodyFormData = e : f.searchParams && URLSearchParams.prototype.isPrototypeOf(e) ? this._bodyText = e.toString() : f.arrayBuffer && f.blob && S(e) ? (this._bodyArrayBuffer = D(e.buffer), this._bodyInit = new Blob([this._bodyArrayBuffer])) : f.arrayBuffer && (ArrayBuffer.prototype.isPrototypeOf(e) || M(e)) ? this._bodyArrayBuffer = D(e) : this._bodyText = e = Object.prototype.toString.call(e) : this._bodyText = "", this.headers.get("content-type") || (typeof e == "string" ? this.headers.set("content-type", "text/plain;charset=UTF-8") : this._bodyBlob && this._bodyBlob.type ? this.headers.set("content-type", this._bodyBlob.type) : f.searchParams && URLSearchParams.prototype.isPrototypeOf(e) && this.headers.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8"));
|
|
157
|
+
}, f.blob && (this.blob = function() {
|
|
158
|
+
var e = B(this);
|
|
159
|
+
if (e)
|
|
160
|
+
return e;
|
|
161
|
+
if (this._bodyBlob)
|
|
162
|
+
return Promise.resolve(this._bodyBlob);
|
|
163
|
+
if (this._bodyArrayBuffer)
|
|
164
|
+
return Promise.resolve(new Blob([this._bodyArrayBuffer]));
|
|
165
|
+
if (this._bodyFormData)
|
|
166
|
+
throw new Error("could not read FormData body as blob");
|
|
167
|
+
return Promise.resolve(new Blob([this._bodyText]));
|
|
168
|
+
}, this.arrayBuffer = function() {
|
|
169
|
+
if (this._bodyArrayBuffer) {
|
|
170
|
+
var e = B(this);
|
|
171
|
+
return e || (ArrayBuffer.isView(this._bodyArrayBuffer) ? Promise.resolve(
|
|
172
|
+
this._bodyArrayBuffer.buffer.slice(
|
|
173
|
+
this._bodyArrayBuffer.byteOffset,
|
|
174
|
+
this._bodyArrayBuffer.byteOffset + this._bodyArrayBuffer.byteLength
|
|
175
|
+
)
|
|
176
|
+
) : Promise.resolve(this._bodyArrayBuffer));
|
|
177
|
+
} else
|
|
178
|
+
return this.blob().then(I);
|
|
179
|
+
}), this.text = function() {
|
|
180
|
+
var e = B(this);
|
|
181
|
+
if (e)
|
|
182
|
+
return e;
|
|
183
|
+
if (this._bodyBlob)
|
|
184
|
+
return q(this._bodyBlob);
|
|
185
|
+
if (this._bodyArrayBuffer)
|
|
186
|
+
return Promise.resolve(H(this._bodyArrayBuffer));
|
|
187
|
+
if (this._bodyFormData)
|
|
188
|
+
throw new Error("could not read FormData body as text");
|
|
189
|
+
return Promise.resolve(this._bodyText);
|
|
190
|
+
}, f.formData && (this.formData = function() {
|
|
191
|
+
return this.text().then(k);
|
|
192
|
+
}), this.json = function() {
|
|
193
|
+
return this.text().then(JSON.parse);
|
|
194
|
+
}, this;
|
|
195
|
+
}
|
|
196
|
+
var L = ["DELETE", "GET", "HEAD", "OPTIONS", "POST", "PUT"];
|
|
197
|
+
function C(e) {
|
|
198
|
+
var t = e.toUpperCase();
|
|
199
|
+
return L.indexOf(t) > -1 ? t : e;
|
|
200
|
+
}
|
|
201
|
+
function m(e, t) {
|
|
202
|
+
if (!(this instanceof m))
|
|
203
|
+
throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');
|
|
204
|
+
t = t || {};
|
|
205
|
+
var r = t.body;
|
|
206
|
+
if (e instanceof m) {
|
|
207
|
+
if (e.bodyUsed)
|
|
208
|
+
throw new TypeError("Already read");
|
|
209
|
+
this.url = e.url, this.credentials = e.credentials, t.headers || (this.headers = new s(e.headers)), this.method = e.method, this.mode = e.mode, this.signal = e.signal, !r && e._bodyInit != null && (r = e._bodyInit, e.bodyUsed = !0);
|
|
210
|
+
} else
|
|
211
|
+
this.url = String(e);
|
|
212
|
+
if (this.credentials = t.credentials || this.credentials || "same-origin", (t.headers || !this.headers) && (this.headers = new s(t.headers)), this.method = C(t.method || this.method || "GET"), this.mode = t.mode || this.mode || null, this.signal = t.signal || this.signal, this.referrer = null, (this.method === "GET" || this.method === "HEAD") && r)
|
|
213
|
+
throw new TypeError("Body not allowed for GET or HEAD requests");
|
|
214
|
+
if (this._initBody(r), (this.method === "GET" || this.method === "HEAD") && (t.cache === "no-store" || t.cache === "no-cache")) {
|
|
215
|
+
var n = /([?&])_=[^&]*/;
|
|
216
|
+
if (n.test(this.url))
|
|
217
|
+
this.url = this.url.replace(n, "$1_=" + (/* @__PURE__ */ new Date()).getTime());
|
|
218
|
+
else {
|
|
219
|
+
var i = /\?/;
|
|
220
|
+
this.url += (i.test(this.url) ? "&" : "?") + "_=" + (/* @__PURE__ */ new Date()).getTime();
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
m.prototype.clone = function() {
|
|
225
|
+
return new m(this, { body: this._bodyInit });
|
|
226
|
+
};
|
|
227
|
+
function k(e) {
|
|
228
|
+
var t = new FormData();
|
|
229
|
+
return e.trim().split("&").forEach(function(r) {
|
|
230
|
+
if (r) {
|
|
231
|
+
var n = r.split("="), i = n.shift().replace(/\+/g, " "), o = n.join("=").replace(/\+/g, " ");
|
|
232
|
+
t.append(decodeURIComponent(i), decodeURIComponent(o));
|
|
233
|
+
}
|
|
234
|
+
}), t;
|
|
235
|
+
}
|
|
236
|
+
function N(e) {
|
|
237
|
+
var t = new s(), r = e.replace(/\r?\n[\t ]+/g, " ");
|
|
238
|
+
return r.split("\r").map(function(n) {
|
|
239
|
+
return n.indexOf(`
|
|
240
|
+
`) === 0 ? n.substr(1, n.length) : n;
|
|
241
|
+
}).forEach(function(n) {
|
|
242
|
+
var i = n.split(":"), o = i.shift().trim();
|
|
243
|
+
if (o) {
|
|
244
|
+
var _ = i.join(":").trim();
|
|
245
|
+
t.append(o, _);
|
|
246
|
+
}
|
|
247
|
+
}), t;
|
|
248
|
+
}
|
|
249
|
+
x.call(m.prototype);
|
|
250
|
+
function d(e, t) {
|
|
251
|
+
if (!(this instanceof d))
|
|
252
|
+
throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');
|
|
253
|
+
t || (t = {}), this.type = "default", this.status = t.status === void 0 ? 200 : t.status, this.ok = this.status >= 200 && this.status < 300, this.statusText = t.statusText === void 0 ? "" : "" + t.statusText, this.headers = new s(t.headers), this.url = t.url || "", this._initBody(e);
|
|
254
|
+
}
|
|
255
|
+
x.call(d.prototype), d.prototype.clone = function() {
|
|
256
|
+
return new d(this._bodyInit, {
|
|
257
|
+
status: this.status,
|
|
258
|
+
statusText: this.statusText,
|
|
259
|
+
headers: new s(this.headers),
|
|
260
|
+
url: this.url
|
|
261
|
+
});
|
|
262
|
+
}, d.error = function() {
|
|
263
|
+
var e = new d(null, { status: 0, statusText: "" });
|
|
264
|
+
return e.type = "error", e;
|
|
265
|
+
};
|
|
266
|
+
var G = [301, 302, 303, 307, 308];
|
|
267
|
+
d.redirect = function(e, t) {
|
|
268
|
+
if (G.indexOf(t) === -1)
|
|
269
|
+
throw new RangeError("Invalid status code");
|
|
270
|
+
return new d(null, { status: t, headers: { location: e } });
|
|
271
|
+
}, u.DOMException = a.DOMException;
|
|
272
|
+
try {
|
|
273
|
+
new u.DOMException();
|
|
274
|
+
} catch {
|
|
275
|
+
u.DOMException = function(t, r) {
|
|
276
|
+
this.message = t, this.name = r;
|
|
277
|
+
var n = Error(t);
|
|
278
|
+
this.stack = n.stack;
|
|
279
|
+
}, u.DOMException.prototype = Object.create(Error.prototype), u.DOMException.prototype.constructor = u.DOMException;
|
|
280
|
+
}
|
|
281
|
+
function O(e, t) {
|
|
282
|
+
return new Promise(function(r, n) {
|
|
283
|
+
var i = new m(e, t);
|
|
284
|
+
if (i.signal && i.signal.aborted)
|
|
285
|
+
return n(new u.DOMException("Aborted", "AbortError"));
|
|
286
|
+
var o = new XMLHttpRequest();
|
|
287
|
+
function _() {
|
|
288
|
+
o.abort();
|
|
289
|
+
}
|
|
290
|
+
o.onload = function() {
|
|
291
|
+
var h = {
|
|
292
|
+
status: o.status,
|
|
293
|
+
statusText: o.statusText,
|
|
294
|
+
headers: N(o.getAllResponseHeaders() || "")
|
|
295
|
+
};
|
|
296
|
+
h.url = "responseURL" in o ? o.responseURL : h.headers.get("X-Request-URL");
|
|
297
|
+
var g = "response" in o ? o.response : o.responseText;
|
|
298
|
+
setTimeout(function() {
|
|
299
|
+
r(new d(g, h));
|
|
300
|
+
}, 0);
|
|
301
|
+
}, o.onerror = function() {
|
|
302
|
+
setTimeout(function() {
|
|
303
|
+
n(new TypeError("Network request failed"));
|
|
304
|
+
}, 0);
|
|
305
|
+
}, o.ontimeout = function() {
|
|
306
|
+
setTimeout(function() {
|
|
307
|
+
n(new TypeError("Network request failed"));
|
|
308
|
+
}, 0);
|
|
309
|
+
}, o.onabort = function() {
|
|
310
|
+
setTimeout(function() {
|
|
311
|
+
n(new u.DOMException("Aborted", "AbortError"));
|
|
312
|
+
}, 0);
|
|
313
|
+
};
|
|
314
|
+
function V(h) {
|
|
315
|
+
try {
|
|
316
|
+
return h === "" && a.location.href ? a.location.href : h;
|
|
317
|
+
} catch {
|
|
318
|
+
return h;
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
o.open(i.method, V(i.url), !0), i.credentials === "include" ? o.withCredentials = !0 : i.credentials === "omit" && (o.withCredentials = !1), "responseType" in o && (f.blob ? o.responseType = "blob" : f.arrayBuffer && i.headers.get("Content-Type") && i.headers.get("Content-Type").indexOf("application/octet-stream") !== -1 && (o.responseType = "arraybuffer")), t && typeof t.headers == "object" && !(t.headers instanceof s) ? Object.getOwnPropertyNames(t.headers).forEach(function(h) {
|
|
322
|
+
o.setRequestHeader(h, E(t.headers[h]));
|
|
323
|
+
}) : i.headers.forEach(function(h, g) {
|
|
324
|
+
o.setRequestHeader(g, h);
|
|
325
|
+
}), i.signal && (i.signal.addEventListener("abort", _), o.onreadystatechange = function() {
|
|
326
|
+
o.readyState === 4 && i.signal.removeEventListener("abort", _);
|
|
327
|
+
}), o.send(typeof i._bodyInit > "u" ? null : i._bodyInit);
|
|
328
|
+
});
|
|
329
|
+
}
|
|
330
|
+
return O.polyfill = !0, a.fetch || (a.fetch = O, a.Headers = s, a.Request = m, a.Response = d), u.Headers = s, u.Request = m, u.Response = d, u.fetch = O, u;
|
|
331
|
+
})({});
|
|
332
|
+
})(p), p.fetch.ponyfill = !0, delete p.fetch.polyfill;
|
|
333
|
+
var l = w.fetch ? w : p;
|
|
334
|
+
y = l.fetch, y.default = l.fetch, y.fetch = l.fetch, y.Headers = l.Headers, y.Request = l.Request, y.Response = l.Response, c.exports = y;
|
|
335
|
+
})(A, A.exports)), A.exports;
|
|
336
|
+
}
|
|
337
|
+
var j = J();
|
|
338
|
+
const K = /* @__PURE__ */ X(j), Q = /* @__PURE__ */ z({
|
|
339
|
+
__proto__: null,
|
|
340
|
+
default: K
|
|
341
|
+
}, [j]);
|
|
342
|
+
export {
|
|
343
|
+
Q as b
|
|
344
|
+
};
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import { u as e, S as g, r as b, a as h, B as v } from "../incodeModule-DR92HDjR.js";
|
|
2
|
+
import { createEmailManager as O } from "@incodetech/core/email";
|
|
3
|
+
import { d as f, y, k as V } from "../vendor-preact-CjD4WiuC.js";
|
|
4
|
+
import "@incodetech/core";
|
|
5
|
+
import { I as P, P as E } from "../page-CITAo3qf.js";
|
|
6
|
+
import { O as k } from "../otpInput-Dm1LhnDm.js";
|
|
7
|
+
const I = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, w = ({
|
|
8
|
+
prefilledEmail: i,
|
|
9
|
+
emailError: a,
|
|
10
|
+
disabled: r = !1,
|
|
11
|
+
onEmailChange: t
|
|
12
|
+
}) => {
|
|
13
|
+
const [n, o] = f("");
|
|
14
|
+
y(() => {
|
|
15
|
+
if (i) {
|
|
16
|
+
o(i);
|
|
17
|
+
const s = I.test(i.trim());
|
|
18
|
+
t(i.trim(), s);
|
|
19
|
+
}
|
|
20
|
+
}, [i, t]);
|
|
21
|
+
const m = (s) => {
|
|
22
|
+
const u = s.target.value;
|
|
23
|
+
o(u);
|
|
24
|
+
const l = u.trim(), c = l.length > 0 && I.test(l);
|
|
25
|
+
t(l, c);
|
|
26
|
+
}, p = a ? "email-error" : void 0;
|
|
27
|
+
return /* @__PURE__ */ e("div", { class: "IncodeEmailInput", children: /* @__PURE__ */ e("div", { class: "IncodeEmailInputContainer", children: [
|
|
28
|
+
/* @__PURE__ */ e(
|
|
29
|
+
"div",
|
|
30
|
+
{
|
|
31
|
+
class: `IncodeEmailInputWrapper ${a ? "IncodeEmailInputWrapperError" : ""} ${r ? "IncodeEmailInputWrapperDisabled" : ""}`,
|
|
32
|
+
children: [
|
|
33
|
+
/* @__PURE__ */ e("label", { for: "email-input", class: "IncodeEmailInputLabel", children: "Email" }),
|
|
34
|
+
/* @__PURE__ */ e(
|
|
35
|
+
"input",
|
|
36
|
+
{
|
|
37
|
+
id: "email-input",
|
|
38
|
+
type: "email",
|
|
39
|
+
value: n,
|
|
40
|
+
onInput: m,
|
|
41
|
+
placeholder: "Email",
|
|
42
|
+
disabled: r,
|
|
43
|
+
class: "IncodeEmailInputField",
|
|
44
|
+
"data-testid": "email-input",
|
|
45
|
+
"aria-label": "Email address",
|
|
46
|
+
"aria-invalid": a ? "true" : "false",
|
|
47
|
+
"aria-describedby": p,
|
|
48
|
+
autocomplete: "email"
|
|
49
|
+
}
|
|
50
|
+
)
|
|
51
|
+
]
|
|
52
|
+
}
|
|
53
|
+
),
|
|
54
|
+
a && /* @__PURE__ */ e(V, { children: [
|
|
55
|
+
/* @__PURE__ */ e(g, { size: 8 }),
|
|
56
|
+
/* @__PURE__ */ e(
|
|
57
|
+
"p",
|
|
58
|
+
{
|
|
59
|
+
id: p,
|
|
60
|
+
class: "IncodeEmailInputError",
|
|
61
|
+
"data-testid": "email-error",
|
|
62
|
+
role: "alert",
|
|
63
|
+
children: a
|
|
64
|
+
}
|
|
65
|
+
)
|
|
66
|
+
] })
|
|
67
|
+
] }) });
|
|
68
|
+
}, C = ({ config: i, onFinish: a, onError: r }) => {
|
|
69
|
+
const [t, n] = h(() => {
|
|
70
|
+
if (!i)
|
|
71
|
+
throw new Error("Email config is required");
|
|
72
|
+
return O({ config: i });
|
|
73
|
+
}), [o, m] = f(!1);
|
|
74
|
+
if (t.status === "idle" || t.status === "loadingPrefill" || t.status === "inputting" || t.status === "submitting" || t.status === "sendingOtp") {
|
|
75
|
+
const s = t.status === "idle" || t.status === "loadingPrefill" || t.status === "submitting" || t.status === "sendingOtp", d = t.status === "inputting" ? t.prefilledEmail : void 0, u = t.status === "inputting" ? t.emailError : void 0;
|
|
76
|
+
return /* @__PURE__ */ e(
|
|
77
|
+
E,
|
|
78
|
+
{
|
|
79
|
+
className: "IncodeEmailPage",
|
|
80
|
+
title: "Verify Email",
|
|
81
|
+
subtitle: i.otpVerification ? "We will send you a verification code" : void 0,
|
|
82
|
+
children: [
|
|
83
|
+
/* @__PURE__ */ e(
|
|
84
|
+
w,
|
|
85
|
+
{
|
|
86
|
+
prefilledEmail: d,
|
|
87
|
+
emailError: u,
|
|
88
|
+
disabled: s,
|
|
89
|
+
onEmailChange: (l, c) => {
|
|
90
|
+
n.setEmail(l, c), m(c);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
),
|
|
94
|
+
/* @__PURE__ */ e(g, {}),
|
|
95
|
+
/* @__PURE__ */ e(
|
|
96
|
+
v,
|
|
97
|
+
{
|
|
98
|
+
onClick: () => n.submit(),
|
|
99
|
+
disabled: !o,
|
|
100
|
+
isLoading: s,
|
|
101
|
+
"data-testid": "email-submit",
|
|
102
|
+
children: "Continue"
|
|
103
|
+
}
|
|
104
|
+
)
|
|
105
|
+
]
|
|
106
|
+
}
|
|
107
|
+
);
|
|
108
|
+
}
|
|
109
|
+
if (t.status === "awaitingOtp" || t.status === "verifyingOtp" || t.status === "otpError") {
|
|
110
|
+
const s = t.status === "verifyingOtp";
|
|
111
|
+
return /* @__PURE__ */ e(
|
|
112
|
+
E,
|
|
113
|
+
{
|
|
114
|
+
className: "IncodeEmailPage IncodeEmailOtpPage",
|
|
115
|
+
title: "Enter Verification Code",
|
|
116
|
+
children: /* @__PURE__ */ e(
|
|
117
|
+
k,
|
|
118
|
+
{
|
|
119
|
+
resendTimer: t.status === "awaitingOtp" ? t.resendTimer : 0,
|
|
120
|
+
canResend: t.status === "awaitingOtp" ? t.canResend : !1,
|
|
121
|
+
error: t.status === "otpError" ? t.error : void 0,
|
|
122
|
+
onSubmit: (d) => n.submitOtp(d),
|
|
123
|
+
onResend: () => n.resendOtp(),
|
|
124
|
+
onBack: () => n.back(),
|
|
125
|
+
backLinkText: "change email address",
|
|
126
|
+
isLoading: s
|
|
127
|
+
}
|
|
128
|
+
)
|
|
129
|
+
}
|
|
130
|
+
);
|
|
131
|
+
}
|
|
132
|
+
return t.status === "finished" ? (a?.(), null) : (t.status === "error" && r?.(t.error), null);
|
|
133
|
+
}, L = ({ config: i, onFinish: a, onError: r }) => /* @__PURE__ */ e(P, { children: i ? /* @__PURE__ */ e(C, { config: i, onFinish: a, onError: r }) : null });
|
|
134
|
+
b(L, "incode-email");
|
|
135
|
+
export {
|
|
136
|
+
L as Email
|
|
137
|
+
};
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
/*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */
|
|
2
|
+
@layer properties {
|
|
3
|
+
@supports (((-webkit-hyphens: none)) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color: rgb(from red r g b)))) {
|
|
4
|
+
*, :before, :after, ::backdrop {
|
|
5
|
+
--tw-border-style: solid;
|
|
6
|
+
--tw-duration: initial;
|
|
7
|
+
--tw-font-weight: initial;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.IncodeEmailPage .IncodePageContent {
|
|
13
|
+
padding-top: var(--spacing-32, var(--spacing-32, 32px));
|
|
14
|
+
padding-bottom: var(--spacing-16, var(--spacing-16, 16px));
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.IncodeEmailPage .IncodeEmailInput, .IncodeEmailPage .IncodeEmailInputContainer {
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
align-items: center;
|
|
20
|
+
width: 100%;
|
|
21
|
+
display: flex;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.IncodeEmailPage .IncodeEmailInputWrapper {
|
|
25
|
+
border-radius: var(--radius-small, var(--border-radius-small));
|
|
26
|
+
border-style: var(--tw-border-style);
|
|
27
|
+
border-width: 1px;
|
|
28
|
+
border-color: var(--color-input-border-default, var(--input-border-default));
|
|
29
|
+
background-color: var(--color-input-surface-default, var(--input-surface-default));
|
|
30
|
+
width: 100%;
|
|
31
|
+
max-width: 340px;
|
|
32
|
+
transition-property: color, background-color, border-color, outline-color, text-decoration-color, fill, stroke, --tw-gradient-from, --tw-gradient-via, --tw-gradient-to;
|
|
33
|
+
transition-timing-function: var(--tw-ease, var(--default-transition-timing-function, cubic-bezier(.4, 0, .2, 1)));
|
|
34
|
+
transition-duration: var(--tw-duration, var(--default-transition-duration, .15s));
|
|
35
|
+
--tw-duration: .2s;
|
|
36
|
+
flex-direction: column;
|
|
37
|
+
transition-duration: .2s;
|
|
38
|
+
display: flex;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.IncodeEmailPage .IncodeEmailInputWrapper:focus-within {
|
|
42
|
+
border-color: var(--color-input-border-active, var(--input-border-active));
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.IncodeEmailPage .IncodeEmailInputWrapper.IncodeEmailInputWrapperError {
|
|
46
|
+
border-color: var(--color-input-border-negative, var(--input-border-negative));
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.IncodeEmailPage .IncodeEmailInputWrapper.IncodeEmailInputWrapperDisabled {
|
|
50
|
+
border-color: var(--color-input-border-disabled, var(--input-border-disabled));
|
|
51
|
+
background-color: var(--color-input-surface-disabled, var(--input-surface-disabled));
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.IncodeEmailPage .IncodeEmailInputLabel {
|
|
55
|
+
clip-path: inset(50%);
|
|
56
|
+
white-space: nowrap;
|
|
57
|
+
border-width: 0;
|
|
58
|
+
width: 1px;
|
|
59
|
+
height: 1px;
|
|
60
|
+
margin: -1px;
|
|
61
|
+
padding: 0;
|
|
62
|
+
position: absolute;
|
|
63
|
+
overflow: hidden;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.IncodeEmailPage .IncodeEmailInputField {
|
|
67
|
+
border-style: var(--tw-border-style);
|
|
68
|
+
border-width: var(--border-width-none, var(--border-none));
|
|
69
|
+
--tw-border-style: none;
|
|
70
|
+
width: 100%;
|
|
71
|
+
padding-inline: var(--spacing-16, var(--spacing-16, 16px));
|
|
72
|
+
padding-block: var(--spacing-16, var(--spacing-16, 16px));
|
|
73
|
+
font-size: var(--text-18, var(--primitive-typography-size-18));
|
|
74
|
+
--tw-font-weight: var(--font-weight-medium, var(--primitive-typography-weight-medium));
|
|
75
|
+
font-weight: var(--font-weight-medium, var(--primitive-typography-weight-medium));
|
|
76
|
+
color: var(--color-input-text-field-default, var(--input-text-field-default));
|
|
77
|
+
--tw-outline-style: none;
|
|
78
|
+
border-radius: var(--radius-small, var(--border-radius-small));
|
|
79
|
+
background-color: #0000;
|
|
80
|
+
border-style: none;
|
|
81
|
+
outline-style: none;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.IncodeEmailPage .IncodeEmailInputField::placeholder {
|
|
85
|
+
--tw-font-weight: var(--font-weight-medium, var(--primitive-typography-weight-medium));
|
|
86
|
+
font-weight: var(--font-weight-medium, var(--primitive-typography-weight-medium));
|
|
87
|
+
color: var(--color-input-text-field-placeholder, var(--input-text-field-placeholder));
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.IncodeEmailPage .IncodeEmailInputField:disabled {
|
|
91
|
+
cursor: not-allowed;
|
|
92
|
+
color: var(--color-input-text-field-disabled, var(--input-text-field-disabled));
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.IncodeEmailPage .IncodeEmailInputField:focus {
|
|
96
|
+
--tw-outline-style: none;
|
|
97
|
+
outline-style: none;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.IncodeEmailPage .IncodeEmailInputError {
|
|
101
|
+
margin: var(--spacing-0, var(--spacing-none, 0px));
|
|
102
|
+
text-align: center;
|
|
103
|
+
font-size: var(--text-14, var(--primitive-typography-size-14));
|
|
104
|
+
--tw-font-weight: var(--font-weight-medium, var(--primitive-typography-weight-medium));
|
|
105
|
+
font-weight: var(--font-weight-medium, var(--primitive-typography-weight-medium));
|
|
106
|
+
color: var(--color-input-text-helper-negative, var(--input-text-helper-negative));
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
@property --tw-border-style {
|
|
110
|
+
syntax: "*";
|
|
111
|
+
inherits: false;
|
|
112
|
+
initial-value: solid;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
@property --tw-duration {
|
|
116
|
+
syntax: "*";
|
|
117
|
+
inherits: false
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
@property --tw-font-weight {
|
|
121
|
+
syntax: "*";
|
|
122
|
+
inherits: false
|
|
123
|
+
}
|