@incodetech/web 0.0.0-dev-20260320-2b71e13 → 0.0.0-dev-20260323-f2d1480
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/{addressAutocomplete-D7g-naeA.js → addressAutocomplete-C69qGh5F.js} +2 -2
- package/dist/curp-validation/curp-validation.es.js +1 -1
- package/dist/{ekybModule-CmnlKxKS.js → ekybModule-HZYjE90U.js} +3 -3
- package/dist/{ekycModule-BggwsBOH.js → ekycModule-Dx6rX4_y.js} +3 -3
- package/dist/email/email.es.js +1 -1
- package/dist/extensibility.es.js +5 -5
- package/dist/{flipAnimation-CJfs4vnz.js → flipAnimation-C5DtSdAY.js} +2 -2
- package/dist/flow/flow.es.js +2 -2
- package/dist/flow/styles.css +2 -274
- package/dist/{formField-6BHE59Av.js → formField-DpLYKGUE.js} +1 -1
- package/dist/governmentValidation/governmentValidation.es.js +1 -1
- package/dist/id/id.es.js +19 -19
- package/dist/id/styles.css +0 -5
- package/dist/{inputComposed-n2VIh213.js → inputComposed-BOGdXswZ.js} +15 -14
- package/dist/otpInput-BfCYQ0Km.js +124 -0
- package/dist/phone/phone.es.js +50 -38
- package/dist/phone/styles.css +2 -296
- package/dist/{phoneInputComposed-C66n6e7L.js → phoneInputComposed-kkWl6RLT.js} +27 -26
- package/dist/selfie/selfie.es.js +10 -10
- package/dist/selfie/styles.css +0 -5
- package/package.json +2 -2
- package/dist/otpInput-2bT7uNnk.js +0 -107
|
@@ -4,7 +4,7 @@ import { w as X, g as I, c as j, b as k } from "./countries-DfLkrF0x.js";
|
|
|
4
4
|
import { D as z } from "./dropdownComposed-DLZ4R_VD.js";
|
|
5
5
|
import { E as q } from "./errorIcon-DOyZZgsP.js";
|
|
6
6
|
import { S as _ } from "./successIcon-CjkBWk8J.js";
|
|
7
|
-
import { a as e2 } from "./inputComposed-
|
|
7
|
+
import { a as e2 } from "./inputComposed-BOGdXswZ.js";
|
|
8
8
|
import { P as n2, p as b, A as g } from "./AsYouType-D1H_js4X.js";
|
|
9
9
|
function o2(e, o, a) {
|
|
10
10
|
if (o[e])
|
|
@@ -23,10 +23,10 @@ function s2(e, o) {
|
|
|
23
23
|
if (!a.endsWith(o)) return null;
|
|
24
24
|
const s = a.length - o.length;
|
|
25
25
|
if (s <= 0) return e;
|
|
26
|
-
let
|
|
27
|
-
for (let
|
|
28
|
-
if (/\d/.test(e[
|
|
29
|
-
return e.slice(
|
|
26
|
+
let c = 0;
|
|
27
|
+
for (let l = 0; l < e.length; l++)
|
|
28
|
+
if (/\d/.test(e[l]) && (c++, c === s))
|
|
29
|
+
return e.slice(l + 1).trimStart();
|
|
30
30
|
return e;
|
|
31
31
|
}
|
|
32
32
|
function a2(e) {
|
|
@@ -34,17 +34,17 @@ function a2(e) {
|
|
|
34
34
|
if (!o) return "";
|
|
35
35
|
const a = o.formatNational(), s = s2(a, o.nationalNumber);
|
|
36
36
|
if (s) return s;
|
|
37
|
-
const
|
|
38
|
-
return y(o.nationalNumber,
|
|
37
|
+
const c = `+${k(e)}`;
|
|
38
|
+
return y(o.nationalNumber, c, e);
|
|
39
39
|
}
|
|
40
|
-
const
|
|
40
|
+
const l2 = J(
|
|
41
41
|
({
|
|
42
42
|
id: e,
|
|
43
43
|
label: o,
|
|
44
44
|
countryCode: a = "US",
|
|
45
45
|
value: s,
|
|
46
|
-
placeholder:
|
|
47
|
-
error:
|
|
46
|
+
placeholder: c,
|
|
47
|
+
error: l,
|
|
48
48
|
helper: h,
|
|
49
49
|
showErrorIcon: D,
|
|
50
50
|
showHelperIcon: K,
|
|
@@ -56,29 +56,29 @@ const c2 = J(
|
|
|
56
56
|
"data-testid": W,
|
|
57
57
|
...F
|
|
58
58
|
}, H) => {
|
|
59
|
-
const [
|
|
59
|
+
const [i, T] = L(a), [u, f] = L(""), G = x(!1), U = M(
|
|
60
60
|
() => j.map((t) => ({
|
|
61
61
|
value: t.code,
|
|
62
62
|
label: `${t.emoji} ${t.callingCode} ${t.name}`
|
|
63
63
|
})),
|
|
64
64
|
[]
|
|
65
65
|
), d = M(
|
|
66
|
-
() => I(
|
|
67
|
-
[
|
|
66
|
+
() => I(i) ?? I("US"),
|
|
67
|
+
[i]
|
|
68
68
|
), O = M(
|
|
69
|
-
() =>
|
|
70
|
-
[
|
|
69
|
+
() => c ?? a2(i),
|
|
70
|
+
[c, i]
|
|
71
71
|
);
|
|
72
72
|
Q(() => {
|
|
73
73
|
if (G.current || !s || !d) return;
|
|
74
74
|
G.current = !0;
|
|
75
75
|
const t = s.startsWith("+") ? s : `+${s}`, n = b(t);
|
|
76
76
|
if (n?.isValid() && n.country) {
|
|
77
|
-
n.country !==
|
|
77
|
+
n.country !== i && T(n.country);
|
|
78
78
|
const p = new g(n.country);
|
|
79
79
|
f(p.input(n.nationalNumber));
|
|
80
80
|
}
|
|
81
|
-
}, [s, d,
|
|
81
|
+
}, [s, d, i]);
|
|
82
82
|
const C = A(
|
|
83
83
|
(t, n) => {
|
|
84
84
|
const p = `${n.callingCode}${t.replace(/\D/g, "")}`;
|
|
@@ -112,7 +112,7 @@ const c2 = J(
|
|
|
112
112
|
f(p), C(n, d);
|
|
113
113
|
},
|
|
114
114
|
[d, C]
|
|
115
|
-
), v = `${e}-country`, m = `${e}-phone`, E = `${m}-helper`, B = `${m}-error`, w = [h ? E : null,
|
|
115
|
+
), v = `${e}-country`, m = `${e}-phone`, E = `${m}-helper`, B = `${m}-error`, w = [h ? E : null, l ? B : null].filter(Boolean).join(" ");
|
|
116
116
|
return /* @__PURE__ */ r("div", { class: "IncodePhoneInputComposed", children: [
|
|
117
117
|
o && /* @__PURE__ */ r(
|
|
118
118
|
"label",
|
|
@@ -131,7 +131,7 @@ const c2 = J(
|
|
|
131
131
|
{
|
|
132
132
|
id: v,
|
|
133
133
|
options: U,
|
|
134
|
-
value:
|
|
134
|
+
value: i,
|
|
135
135
|
onChange: V,
|
|
136
136
|
disabled: N || R,
|
|
137
137
|
required: P,
|
|
@@ -153,32 +153,33 @@ const c2 = J(
|
|
|
153
153
|
value: u,
|
|
154
154
|
onInput: Z,
|
|
155
155
|
placeholder: O,
|
|
156
|
-
error:
|
|
156
|
+
error: l,
|
|
157
157
|
disabled: N,
|
|
158
158
|
required: P,
|
|
159
159
|
suppressMessages: !0,
|
|
160
160
|
"aria-label": o ? void 0 : "Phone number",
|
|
161
161
|
"aria-labelledby": $,
|
|
162
162
|
"aria-describedby": w || void 0,
|
|
163
|
-
"aria-invalid":
|
|
163
|
+
"aria-invalid": l ? "true" : void 0,
|
|
164
164
|
"data-testid": W,
|
|
165
165
|
...F
|
|
166
166
|
}
|
|
167
167
|
)
|
|
168
168
|
}
|
|
169
169
|
),
|
|
170
|
-
|
|
170
|
+
l && /* @__PURE__ */ r(
|
|
171
171
|
"div",
|
|
172
172
|
{
|
|
173
173
|
class: "IncodePhoneInputComposedErrorWrapper",
|
|
174
|
+
role: "alert",
|
|
174
175
|
"data-testid": `${e}-error-wrapper`,
|
|
175
176
|
children: [
|
|
176
177
|
D && /* @__PURE__ */ r("div", { class: "IncodePhoneInputComposedIconWrapper", children: /* @__PURE__ */ r(q, { size: 16 }) }),
|
|
177
|
-
/* @__PURE__ */ r("p", { id: B, class: "IncodePhoneInputComposedError", children:
|
|
178
|
+
/* @__PURE__ */ r("p", { id: B, class: "IncodePhoneInputComposedError", children: l })
|
|
178
179
|
]
|
|
179
180
|
}
|
|
180
181
|
),
|
|
181
|
-
h && !
|
|
182
|
+
h && !l && /* @__PURE__ */ r(
|
|
182
183
|
"div",
|
|
183
184
|
{
|
|
184
185
|
class: "IncodePhoneInputComposedHelperWrapper",
|
|
@@ -192,7 +193,7 @@ const c2 = J(
|
|
|
192
193
|
] });
|
|
193
194
|
}
|
|
194
195
|
);
|
|
195
|
-
|
|
196
|
+
l2.displayName = "PhoneInputComposed";
|
|
196
197
|
export {
|
|
197
|
-
|
|
198
|
+
l2 as P
|
|
198
199
|
};
|
package/dist/selfie/selfie.es.js
CHANGED
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
import { u as
|
|
1
|
+
import { u as r, I as u, a } from "../button-Yr39X4SE.js";
|
|
2
2
|
import { createSelfieManager as l } from "@incodetech/core/selfie";
|
|
3
3
|
import "../vendor-preact--mDTxXnt.js";
|
|
4
4
|
import "@incodetech/core";
|
|
5
5
|
import { P as m } from "../manualCaptureButton-CtHbJjgz.js";
|
|
6
6
|
import { r as f } from "../incodeModule-Bxzkb7nW.js";
|
|
7
|
-
import { P as
|
|
8
|
-
import { T as
|
|
7
|
+
import { P as p } from "../processing-BGKugkCh.js";
|
|
8
|
+
import { T as c, C as d } from "../tutorial-Dptz5zyj.js";
|
|
9
9
|
const g = ({
|
|
10
10
|
config: e,
|
|
11
11
|
manager: s,
|
|
12
12
|
onFinish: n,
|
|
13
13
|
onError: i
|
|
14
14
|
}) => {
|
|
15
|
-
const [
|
|
15
|
+
const [t, o] = a(
|
|
16
16
|
() => s ?? l({ config: e }),
|
|
17
17
|
{ manageLifecycle: !s }
|
|
18
18
|
);
|
|
19
|
-
return
|
|
19
|
+
return t.status === "idle" || t.status === "loading" ? null : t.status === "tutorial" ? /* @__PURE__ */ r(c, { manager: o }) : t.status === "permissions" ? /* @__PURE__ */ r(
|
|
20
20
|
m,
|
|
21
21
|
{
|
|
22
|
-
manager:
|
|
23
|
-
permissionStatus:
|
|
22
|
+
manager: o,
|
|
23
|
+
permissionStatus: t.permissionStatus
|
|
24
24
|
}
|
|
25
|
-
) :
|
|
25
|
+
) : t.status === "capture" ? /* @__PURE__ */ r(d, { manager: o, state: t }) : t.status === "processing" ? /* @__PURE__ */ r(p, {}) : t.status === "finished" ? (n?.(), null) : t.status === "closed" ? (i?.(void 0), null) : (t.status === "error" && i?.(t.error), null);
|
|
26
26
|
}, S = ({
|
|
27
27
|
config: e,
|
|
28
28
|
manager: s,
|
|
29
29
|
onFinish: n,
|
|
30
30
|
onError: i
|
|
31
|
-
}) => /* @__PURE__ */
|
|
31
|
+
}) => /* @__PURE__ */ r(u, { children: e ? /* @__PURE__ */ r(
|
|
32
32
|
g,
|
|
33
33
|
{
|
|
34
34
|
config: e,
|
|
@@ -36,7 +36,7 @@ const g = ({
|
|
|
36
36
|
onFinish: n,
|
|
37
37
|
onError: i
|
|
38
38
|
}
|
|
39
|
-
) : null })
|
|
39
|
+
) : null });
|
|
40
40
|
f(S, "incode-selfie");
|
|
41
41
|
export {
|
|
42
42
|
S as Selfie
|
package/dist/selfie/styles.css
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@incodetech/web",
|
|
3
|
-
"version": "0.0.0-dev-
|
|
3
|
+
"version": "0.0.0-dev-20260323-f2d1480",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.es.js",
|
|
6
6
|
"types": "./dist/types/index.d.ts",
|
|
@@ -129,7 +129,7 @@
|
|
|
129
129
|
"preact-markup": "^2.1.1",
|
|
130
130
|
"qrcode": "^1.5.4",
|
|
131
131
|
"tailwindcss": "^4.1.17",
|
|
132
|
-
"@incodetech/core": "0.0.0-dev-
|
|
132
|
+
"@incodetech/core": "0.0.0-dev-20260323-f2d1480"
|
|
133
133
|
},
|
|
134
134
|
"devDependencies": {
|
|
135
135
|
"@microsoft/api-extractor": "^7.53.3",
|
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
import { b as P, u as e, S as O, B as b } from "./button-Yr39X4SE.js";
|
|
2
|
-
import { d as D, A as g, y as m } from "./vendor-preact--mDTxXnt.js";
|
|
3
|
-
import { a as M } from "./inputComposed-n2VIh213.js";
|
|
4
|
-
import "./uiConfig-CKJmKRCo.js";
|
|
5
|
-
const s = 6, N = (r) => {
|
|
6
|
-
const u = Math.floor(r / 60), a = r % 60;
|
|
7
|
-
return `${u}:${a.toString().padStart(2, "0")}`;
|
|
8
|
-
}, v = (r) => r.replace(/[^a-zA-Z0-9]/g, "").toUpperCase().slice(0, s), E = ({
|
|
9
|
-
resendTimer: r,
|
|
10
|
-
canResend: u,
|
|
11
|
-
error: a,
|
|
12
|
-
onSubmit: p,
|
|
13
|
-
onResend: x,
|
|
14
|
-
onBack: k,
|
|
15
|
-
backLinkText: f = "otp.changePhoneNumber",
|
|
16
|
-
disabled: i = !1,
|
|
17
|
-
isLoading: t = !1
|
|
18
|
-
}) => {
|
|
19
|
-
const { t: c } = P(), [n, I] = D(""), d = g(null), C = g(0);
|
|
20
|
-
m(() => {
|
|
21
|
-
d.current && d.current.focus();
|
|
22
|
-
}, []), m(() => {
|
|
23
|
-
a && setTimeout(() => {
|
|
24
|
-
d.current?.focus();
|
|
25
|
-
}, 0);
|
|
26
|
-
}, [a]), m(() => {
|
|
27
|
-
if (!n) return;
|
|
28
|
-
const o = n.length === s && C.current < s;
|
|
29
|
-
C.current = n.length, o && !t && p(n);
|
|
30
|
-
}, [n, t, p]);
|
|
31
|
-
const T = (o) => {
|
|
32
|
-
o.target.select();
|
|
33
|
-
}, y = (o) => {
|
|
34
|
-
const h = o.target;
|
|
35
|
-
I(v(h.value));
|
|
36
|
-
}, z = (o) => {
|
|
37
|
-
o.preventDefault();
|
|
38
|
-
const h = o.clipboardData?.getData("text") || "", l = v(h);
|
|
39
|
-
l && (I(l), l.length === s && !t && p(l));
|
|
40
|
-
}, A = () => /* @__PURE__ */ e("div", { class: "IncodeOtpInputActions", children: u && !t ? /* @__PURE__ */ e("p", { class: "IncodeOtpInputResendText", "data-testid": "otp-resend-section", children: [
|
|
41
|
-
c("otp.didYouNotGetIt"),
|
|
42
|
-
/* @__PURE__ */ e(
|
|
43
|
-
"button",
|
|
44
|
-
{
|
|
45
|
-
type: "button",
|
|
46
|
-
class: "IncodeOtpInputLink",
|
|
47
|
-
onClick: x,
|
|
48
|
-
disabled: i || t,
|
|
49
|
-
"data-testid": "otp-resend",
|
|
50
|
-
children: c("otp.resendCode")
|
|
51
|
-
}
|
|
52
|
-
),
|
|
53
|
-
` ${c("otp.or")} `,
|
|
54
|
-
/* @__PURE__ */ e(
|
|
55
|
-
"button",
|
|
56
|
-
{
|
|
57
|
-
type: "button",
|
|
58
|
-
class: "IncodeOtpInputLink",
|
|
59
|
-
onClick: k,
|
|
60
|
-
disabled: i || t,
|
|
61
|
-
"data-testid": "otp-back",
|
|
62
|
-
children: c(f)
|
|
63
|
-
}
|
|
64
|
-
)
|
|
65
|
-
] }) : t ? null : /* @__PURE__ */ e(b, { variant: "link", disabled: !0, "data-testid": "otp-timer", children: c("otp.resendCountdown", { time: N(r) }) }) });
|
|
66
|
-
return /* @__PURE__ */ e("div", { class: "IncodeOtpInput IncodeOtpInputComposed", children: [
|
|
67
|
-
/* @__PURE__ */ e(
|
|
68
|
-
M,
|
|
69
|
-
{
|
|
70
|
-
id: "otp-code",
|
|
71
|
-
type: "text",
|
|
72
|
-
inputMode: "text",
|
|
73
|
-
ref: d,
|
|
74
|
-
maxLength: s,
|
|
75
|
-
value: n,
|
|
76
|
-
error: a,
|
|
77
|
-
onInput: y,
|
|
78
|
-
onPaste: z,
|
|
79
|
-
onFocus: T,
|
|
80
|
-
disabled: i || t,
|
|
81
|
-
autocomplete: "one-time-code",
|
|
82
|
-
"data-testid": "otp-input-0",
|
|
83
|
-
"aria-label": c(f),
|
|
84
|
-
class: "IncodeOtpSingleInput",
|
|
85
|
-
showErrorIcon: !0
|
|
86
|
-
}
|
|
87
|
-
),
|
|
88
|
-
/* @__PURE__ */ e(O, {}),
|
|
89
|
-
/* @__PURE__ */ e(
|
|
90
|
-
b,
|
|
91
|
-
{
|
|
92
|
-
onClick: () => {
|
|
93
|
-
n.length === s && p(n);
|
|
94
|
-
},
|
|
95
|
-
disabled: n.length < s || t,
|
|
96
|
-
isLoading: t,
|
|
97
|
-
"data-testid": "otp-submit",
|
|
98
|
-
children: c("common.continue")
|
|
99
|
-
}
|
|
100
|
-
),
|
|
101
|
-
/* @__PURE__ */ e(O, { size: 12 }),
|
|
102
|
-
A()
|
|
103
|
-
] });
|
|
104
|
-
};
|
|
105
|
-
export {
|
|
106
|
-
E as O
|
|
107
|
-
};
|