@incodetech/web 0.0.0-dev-20260320-96b0018 → 0.0.0-dev-20260320-c9bdba0
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/base.css
CHANGED
|
@@ -334,6 +334,7 @@
|
|
|
334
334
|
border-style: var(--tw-border-style);
|
|
335
335
|
border-width: 1.5px;
|
|
336
336
|
border-color: var(--color-button-secondary-border-default, var(--button-secondary-border-default));
|
|
337
|
+
background-color: #0000;
|
|
337
338
|
}
|
|
338
339
|
.IncodeButton.IncodeButtonSecondary:active {
|
|
339
340
|
border-color: var(--color-button-secondary-border-pressed, var(--button-secondary-border-pressed));
|
package/dist/extensibility.es.js
CHANGED
|
@@ -10,7 +10,7 @@ import { F as J, V as K } from "./formField-hlgxOSE6.js";
|
|
|
10
10
|
import { a as Q, C as X, c as Y, b as Z, e as _, d as $, H as aa, L as ea, P as ra } from "./captureFooter-SNtyUXrI.js";
|
|
11
11
|
import { I as ta, a as sa } from "./inputComposed-CyGtRLzv.js";
|
|
12
12
|
import { O as pa } from "./otpInput-B3iNW8b5.js";
|
|
13
|
-
import { C as ia, g as ua, h as la, b as da, d as ma, I as Ca, e as fa, F as Ia, c as xa, S as ha, T as ga, a as ya, f as Ta, V as Sa } from "./flipAnimation-
|
|
13
|
+
import { C as ia, g as ua, h as la, b as da, d as ma, I as Ca, e as fa, F as Ia, c as xa, S as ha, T as ga, a as ya, f as Ta, V as Sa } from "./flipAnimation-CnXEIDH1.js";
|
|
14
14
|
import { P as Ba } from "./phoneInputComposed-DNfU__MR.js";
|
|
15
15
|
import { D as Pa, S as La } from "./dropdownComposed-Cg6lQD2C.js";
|
|
16
16
|
import { C as Ha, D as Ma } from "./dateInputComposed-C8WTSu9L.js";
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { u as e, d as x, b as
|
|
2
|
-
import { _ as V, D as H, d as
|
|
1
|
+
import { u as e, d as x, b as g, S as Z, B as k } from "./button-zCdeDeEB.js";
|
|
2
|
+
import { _ as V, D as H, d as b, A as m, y as I, k as $, q as U, T as W } from "./vendor-preact-BXf0bkEs.js";
|
|
3
3
|
import "./uiConfig-Z6RT23Sl.js";
|
|
4
4
|
import { P as D } from "./page-Dv0s0RPn.js";
|
|
5
|
-
import { T as P, S as
|
|
5
|
+
import { T as P, S as j } from "./spinner-BbVGMG-G.js";
|
|
6
6
|
import { L as n1, P as r1, c as l1, a as o1, d as a1, C as s1, b as c1 } from "./captureFooter-SNtyUXrI.js";
|
|
7
7
|
import { L as A, B as d1 } from "./manualCaptureButton-iYqQECzn.js";
|
|
8
8
|
import "@incodetech/core";
|
|
9
9
|
import "./inputComposed-CyGtRLzv.js";
|
|
10
|
-
import { E as
|
|
10
|
+
import { E as K } from "./errorIcon-bIXk9nAy.js";
|
|
11
11
|
import "./phoneInputComposed-DNfU__MR.js";
|
|
12
12
|
import "./dateInputComposed-C8WTSu9L.js";
|
|
13
13
|
import { S as C1 } from "./successIcon-DN8LMqE2.js";
|
|
@@ -96,18 +96,18 @@ const p1 = ({ size: i = 28 }) => /* @__PURE__ */ e(
|
|
|
96
96
|
onChange: c,
|
|
97
97
|
error: h,
|
|
98
98
|
helper: C,
|
|
99
|
-
showErrorIcon:
|
|
99
|
+
showErrorIcon: v = !0,
|
|
100
100
|
class: u,
|
|
101
|
-
"aria-label":
|
|
102
|
-
"aria-labelledby":
|
|
101
|
+
"aria-label": L,
|
|
102
|
+
"aria-labelledby": y,
|
|
103
103
|
"aria-describedby": _,
|
|
104
104
|
"aria-invalid": p,
|
|
105
|
-
...
|
|
105
|
+
...w
|
|
106
106
|
}, f) => {
|
|
107
|
-
const [
|
|
108
|
-
|
|
109
|
-
}, S = C ? `${i}-helper` : void 0, z = h ? `${i}-error` : void 0,
|
|
110
|
-
return /* @__PURE__ */ e("div", { class: x("IncodeCheckbox",
|
|
107
|
+
const [E, F] = b(!!l), B = r !== void 0, O = B ? !!r : E, R = !!o, Y = !!s, e1 = typeof u == "string" ? u : void 0, t1 = (N) => {
|
|
108
|
+
B || F(N.target.checked), c?.(N);
|
|
109
|
+
}, S = C ? `${i}-helper` : void 0, z = h ? `${i}-error` : void 0, i1 = [_, z, S].filter(Boolean).join(" ") || void 0;
|
|
110
|
+
return /* @__PURE__ */ e("div", { class: x("IncodeCheckbox", e1), children: [
|
|
111
111
|
/* @__PURE__ */ e(
|
|
112
112
|
"label",
|
|
113
113
|
{
|
|
@@ -126,16 +126,16 @@ const p1 = ({ size: i = 28 }) => /* @__PURE__ */ e(
|
|
|
126
126
|
id: i,
|
|
127
127
|
name: a,
|
|
128
128
|
value: d,
|
|
129
|
-
...
|
|
129
|
+
...B ? { checked: r } : { defaultChecked: l },
|
|
130
130
|
disabled: o,
|
|
131
131
|
required: s,
|
|
132
|
-
onChange:
|
|
133
|
-
"aria-label":
|
|
134
|
-
"aria-labelledby":
|
|
135
|
-
"aria-describedby":
|
|
132
|
+
onChange: t1,
|
|
133
|
+
"aria-label": L,
|
|
134
|
+
"aria-labelledby": y,
|
|
135
|
+
"aria-describedby": i1,
|
|
136
136
|
"aria-invalid": p || !!h,
|
|
137
|
-
"aria-required":
|
|
138
|
-
...
|
|
137
|
+
"aria-required": Y,
|
|
138
|
+
...w
|
|
139
139
|
}
|
|
140
140
|
),
|
|
141
141
|
/* @__PURE__ */ e(
|
|
@@ -158,7 +158,7 @@ const p1 = ({ size: i = 28 }) => /* @__PURE__ */ e(
|
|
|
158
158
|
IncodeCheckboxTextM: n === "m",
|
|
159
159
|
IncodeCheckboxTextDisabled: R
|
|
160
160
|
}),
|
|
161
|
-
"aria-hidden":
|
|
161
|
+
"aria-hidden": y ? "true" : void 0,
|
|
162
162
|
children: [
|
|
163
163
|
t,
|
|
164
164
|
s && /* @__PURE__ */ e("span", { class: "IncodeCheckboxRequired", "aria-hidden": "true", children: "*" })
|
|
@@ -174,7 +174,7 @@ const p1 = ({ size: i = 28 }) => /* @__PURE__ */ e(
|
|
|
174
174
|
class: "IncodeCheckboxMessageWrapper",
|
|
175
175
|
"data-testid": `${i}-error-wrapper`,
|
|
176
176
|
children: [
|
|
177
|
-
|
|
177
|
+
v && /* @__PURE__ */ e("div", { class: "IncodeCheckboxIconWrapper", children: /* @__PURE__ */ e(K, { size: 17 }) }),
|
|
178
178
|
/* @__PURE__ */ e("p", { id: z, class: "IncodeCheckboxErrorText", children: h })
|
|
179
179
|
]
|
|
180
180
|
}
|
|
@@ -216,7 +216,7 @@ const p1 = ({ size: i = 28 }) => /* @__PURE__ */ e(
|
|
|
216
216
|
class: c,
|
|
217
217
|
...h
|
|
218
218
|
}, C) => {
|
|
219
|
-
const
|
|
219
|
+
const v = `${i}-helper`, u = `${i}-error`, L = [o ? v : null, r ? u : null].filter(Boolean).join(" ");
|
|
220
220
|
return /* @__PURE__ */ e("div", { class: x("IncodeTextAreaComposed", c), children: [
|
|
221
221
|
t && /* @__PURE__ */ e(
|
|
222
222
|
"label",
|
|
@@ -239,7 +239,7 @@ const p1 = ({ size: i = 28 }) => /* @__PURE__ */ e(
|
|
|
239
239
|
ref: C,
|
|
240
240
|
required: a,
|
|
241
241
|
...!t && n ? { "aria-label": n } : {},
|
|
242
|
-
"aria-describedby":
|
|
242
|
+
"aria-describedby": L || void 0,
|
|
243
243
|
"aria-required": a ? "true" : void 0,
|
|
244
244
|
"aria-invalid": r ? "true" : void 0
|
|
245
245
|
}
|
|
@@ -250,7 +250,7 @@ const p1 = ({ size: i = 28 }) => /* @__PURE__ */ e(
|
|
|
250
250
|
class: "IncodeTextAreaComposedErrorWrapper",
|
|
251
251
|
"data-testid": `${i}-error-wrapper`,
|
|
252
252
|
children: [
|
|
253
|
-
l && /* @__PURE__ */ e("div", { class: "IncodeTextAreaComposedIconWrapper", children: /* @__PURE__ */ e(
|
|
253
|
+
l && /* @__PURE__ */ e("div", { class: "IncodeTextAreaComposedIconWrapper", children: /* @__PURE__ */ e(K, { size: 17 }) }),
|
|
254
254
|
/* @__PURE__ */ e("p", { id: u, class: "IncodeTextAreaComposedError", children: r })
|
|
255
255
|
]
|
|
256
256
|
}
|
|
@@ -262,7 +262,7 @@ const p1 = ({ size: i = 28 }) => /* @__PURE__ */ e(
|
|
|
262
262
|
"data-testid": `${i}-helper-wrapper`,
|
|
263
263
|
children: [
|
|
264
264
|
s && /* @__PURE__ */ e("div", { class: "IncodeTextAreaComposedIconWrapper", children: /* @__PURE__ */ e(C1, { size: 17 }) }),
|
|
265
|
-
/* @__PURE__ */ e("p", { id:
|
|
265
|
+
/* @__PURE__ */ e("p", { id: v, class: "IncodeTextAreaComposedHelper", children: o })
|
|
266
266
|
]
|
|
267
267
|
}
|
|
268
268
|
)
|
|
@@ -514,7 +514,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
514
514
|
onClose: i,
|
|
515
515
|
onTakeManually: t
|
|
516
516
|
}) => {
|
|
517
|
-
const { t: n } =
|
|
517
|
+
const { t: n } = g(), r = m(null), l = () => {
|
|
518
518
|
t(), i();
|
|
519
519
|
};
|
|
520
520
|
return I(() => {
|
|
@@ -545,7 +545,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
545
545
|
"aria-hidden": "true"
|
|
546
546
|
}
|
|
547
547
|
),
|
|
548
|
-
/* @__PURE__ */ e(
|
|
548
|
+
/* @__PURE__ */ e(Z, { size: 12 }),
|
|
549
549
|
/* @__PURE__ */ e(
|
|
550
550
|
"h2",
|
|
551
551
|
{
|
|
@@ -556,7 +556,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
556
556
|
children: n("commonIssues.commonIssues")
|
|
557
557
|
}
|
|
558
558
|
),
|
|
559
|
-
/* @__PURE__ */ e(
|
|
559
|
+
/* @__PURE__ */ e(Z, { size: 24 }),
|
|
560
560
|
/* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCards", children: [
|
|
561
561
|
/* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCard", children: [
|
|
562
562
|
/* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardIcon", "aria-hidden": "true", children: /* @__PURE__ */ e(L1, {}) }),
|
|
@@ -619,7 +619,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
619
619
|
children: r
|
|
620
620
|
}
|
|
621
621
|
);
|
|
622
|
-
},
|
|
622
|
+
}, q = ({
|
|
623
623
|
imageUrl: i,
|
|
624
624
|
orientation: t,
|
|
625
625
|
mode: n,
|
|
@@ -628,7 +628,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
628
628
|
bottomContent: o,
|
|
629
629
|
overlayContent: s
|
|
630
630
|
}) => {
|
|
631
|
-
const { t: a } =
|
|
631
|
+
const { t: a } = g();
|
|
632
632
|
return /* @__PURE__ */ e(D, { hideHeader: !0, hideFooterBranding: !0, children: /* @__PURE__ */ e("div", { class: "IncodeIdProcessingLayout", children: /* @__PURE__ */ e("div", { class: "IncodeIdProcessingLayoutContent", children: [
|
|
633
633
|
l && /* @__PURE__ */ e("div", { class: "IncodeIdProcessingTopArea", children: l }),
|
|
634
634
|
/* @__PURE__ */ e(
|
|
@@ -665,7 +665,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
665
665
|
orientation: n,
|
|
666
666
|
mode: r
|
|
667
667
|
}) => {
|
|
668
|
-
const { t: l } =
|
|
668
|
+
const { t: l } = g(), o = m(null), s = n !== "vertical" || r === "passport", [a, d] = b(null);
|
|
669
669
|
return I(() => {
|
|
670
670
|
o.current?.focus();
|
|
671
671
|
}, []), I(() => {
|
|
@@ -675,7 +675,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
675
675
|
d(c.default);
|
|
676
676
|
});
|
|
677
677
|
}, [s]), /* @__PURE__ */ e(
|
|
678
|
-
|
|
678
|
+
q,
|
|
679
679
|
{
|
|
680
680
|
imageUrl: i,
|
|
681
681
|
orientation: n,
|
|
@@ -723,7 +723,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
723
723
|
}
|
|
724
724
|
)
|
|
725
725
|
}
|
|
726
|
-
),
|
|
726
|
+
), Q = ({ className: i, ...t }) => /* @__PURE__ */ e(
|
|
727
727
|
"svg",
|
|
728
728
|
{
|
|
729
729
|
class: i,
|
|
@@ -742,7 +742,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
742
742
|
}
|
|
743
743
|
)
|
|
744
744
|
}
|
|
745
|
-
),
|
|
745
|
+
), J = ({
|
|
746
746
|
variant: i,
|
|
747
747
|
imageUrl: t,
|
|
748
748
|
orientation: n,
|
|
@@ -753,19 +753,19 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
753
753
|
onButtonClick: a,
|
|
754
754
|
attemptsRemaining: d
|
|
755
755
|
}) => {
|
|
756
|
-
const { t: c } =
|
|
756
|
+
const { t: c } = g(), h = m(null);
|
|
757
757
|
return I(() => {
|
|
758
758
|
h.current?.focus();
|
|
759
759
|
}, []), /* @__PURE__ */ e(
|
|
760
|
-
|
|
760
|
+
q,
|
|
761
761
|
{
|
|
762
762
|
imageUrl: t,
|
|
763
763
|
orientation: n,
|
|
764
764
|
mode: r,
|
|
765
765
|
borderState: i,
|
|
766
766
|
topContent: /* @__PURE__ */ e("div", { class: "IncodeIdProcessingResultContent", role: "status", children: [
|
|
767
|
-
i === "success" ? /* @__PURE__ */ e(Z1, { className: "IncodeIdProcessingResultIcon" }) : /* @__PURE__ */ e(
|
|
768
|
-
/* @__PURE__ */ e(
|
|
767
|
+
i === "success" ? /* @__PURE__ */ e(Z1, { className: "IncodeIdProcessingResultIcon" }) : /* @__PURE__ */ e(Q, { className: "IncodeIdProcessingResultIcon" }),
|
|
768
|
+
/* @__PURE__ */ e(Z, { size: 16 }),
|
|
769
769
|
l && /* @__PURE__ */ e(
|
|
770
770
|
P,
|
|
771
771
|
{
|
|
@@ -776,7 +776,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
776
776
|
}
|
|
777
777
|
),
|
|
778
778
|
o && /* @__PURE__ */ e($, { children: [
|
|
779
|
-
/* @__PURE__ */ e(
|
|
779
|
+
/* @__PURE__ */ e(Z, { size: 12 }),
|
|
780
780
|
/* @__PURE__ */ e("p", { class: "IncodeIdProcessingResultSubtitle", children: o })
|
|
781
781
|
] })
|
|
782
782
|
] }),
|
|
@@ -789,12 +789,12 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
789
789
|
}
|
|
790
790
|
);
|
|
791
791
|
}, E1 = ({ manager: i, state: t }) => {
|
|
792
|
-
const { t: n } =
|
|
792
|
+
const { t: n } = g();
|
|
793
793
|
if (!t.previewImageUrl)
|
|
794
794
|
return null;
|
|
795
795
|
const r = t.currentMode === "passport" ? "passport" : "id", l = () => t.needsBackCapture ? n("v2.idSuccess.subtitle") : t.needsFrontCapture ? n("idv2.capture.processing.successBackSubtitleScanFront") : n("v2.idSuccess.subtitleBack"), o = () => t.needsBackCapture ? n("idv2.capture.processing.scanBack") : t.needsFrontCapture ? n("idv2.capture.processing.scanFront") : n("idv2.capturePreview.continue");
|
|
796
796
|
return /* @__PURE__ */ e(
|
|
797
|
-
|
|
797
|
+
J,
|
|
798
798
|
{
|
|
799
799
|
variant: "success",
|
|
800
800
|
imageUrl: t.previewImageUrl,
|
|
@@ -807,7 +807,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
807
807
|
}
|
|
808
808
|
);
|
|
809
809
|
}, V1 = ({ manager: i, state: t, ...n }) => {
|
|
810
|
-
const { t: r } =
|
|
810
|
+
const { t: r } = g();
|
|
811
811
|
if (t.status === "error")
|
|
812
812
|
return /* @__PURE__ */ e("div", { class: "IncodeIdError", role: "alert", children: [
|
|
813
813
|
/* @__PURE__ */ e("div", { class: "IncodeIdErrorMessage", children: t.error }),
|
|
@@ -815,7 +815,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
815
815
|
] });
|
|
816
816
|
const l = t.currentMode === "passport" ? "passport" : "id";
|
|
817
817
|
return t.previewImageUrl ? /* @__PURE__ */ e(
|
|
818
|
-
|
|
818
|
+
J,
|
|
819
819
|
{
|
|
820
820
|
variant: "error",
|
|
821
821
|
imageUrl: t.previewImageUrl,
|
|
@@ -829,7 +829,7 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
829
829
|
}
|
|
830
830
|
) : null;
|
|
831
831
|
}, l2 = ({ manager: i }) => {
|
|
832
|
-
const { t } =
|
|
832
|
+
const { t } = g(), n = m(null);
|
|
833
833
|
I(() => {
|
|
834
834
|
n.current?.focus();
|
|
835
835
|
}, []);
|
|
@@ -838,15 +838,15 @@ const w1 = ({ className: i }) => /* @__PURE__ */ e(
|
|
|
838
838
|
};
|
|
839
839
|
return /* @__PURE__ */ e(D, { hideHeader: !0, hideFooterBranding: !0, className: "IncodeIdExpiredPage", children: [
|
|
840
840
|
/* @__PURE__ */ e("div", { class: "IncodeIdExpiredContent", role: "alert", children: [
|
|
841
|
-
/* @__PURE__ */ e(
|
|
841
|
+
/* @__PURE__ */ e(Q, { className: "IncodeIdExpiredIcon" }),
|
|
842
842
|
/* @__PURE__ */ e(P, { ref: n, tabIndex: -1, className: "IncodeIdExpiredTitle", children: t("idv2.capture.notifications.expiredId") }),
|
|
843
|
-
/* @__PURE__ */ e(
|
|
843
|
+
/* @__PURE__ */ e(Z, { size: 12 }),
|
|
844
844
|
/* @__PURE__ */ e("p", { class: "IncodeIdExpiredSubtitle", children: t("idv2.capture.notifications.useDifferent") }),
|
|
845
|
-
/* @__PURE__ */ e(
|
|
845
|
+
/* @__PURE__ */ e(Z, { size: 80 })
|
|
846
846
|
] }),
|
|
847
847
|
/* @__PURE__ */ e("div", { class: "IncodeIdExpiredButtonContainer", children: /* @__PURE__ */ e(k, { variant: "primary", onClick: r, children: t("idv2.unacceptedId.tryAgain") }) })
|
|
848
848
|
] });
|
|
849
|
-
},
|
|
849
|
+
}, M = /* @__PURE__ */ new Map();
|
|
850
850
|
let G = !1;
|
|
851
851
|
const T = {
|
|
852
852
|
blur: () => import("./blurdevicelottie-_BZRug1c.js"),
|
|
@@ -855,7 +855,7 @@ const T = {
|
|
|
855
855
|
front: () => import("./frontdevicelottie-KhKxT5n9.js"),
|
|
856
856
|
back: () => import("./backdevicelottie-B4NgyWmX.js")
|
|
857
857
|
};
|
|
858
|
-
function
|
|
858
|
+
function X(i) {
|
|
859
859
|
G || (G = !0, Promise.all([
|
|
860
860
|
T.blur(),
|
|
861
861
|
T.glare(),
|
|
@@ -863,12 +863,12 @@ function J(i) {
|
|
|
863
863
|
T.front(),
|
|
864
864
|
T.back()
|
|
865
865
|
]).then(([t, n, r, l, o]) => {
|
|
866
|
-
|
|
866
|
+
M.set("blur", t.default), M.set("glare", n.default), M.set("align", r.default), M.set("front", l.default), M.set("back", o.default), i?.();
|
|
867
867
|
}).catch(() => {
|
|
868
868
|
}));
|
|
869
869
|
}
|
|
870
870
|
function T1() {
|
|
871
|
-
|
|
871
|
+
X();
|
|
872
872
|
}
|
|
873
873
|
function k1() {
|
|
874
874
|
I(() => {
|
|
@@ -876,33 +876,33 @@ function k1() {
|
|
|
876
876
|
}, []);
|
|
877
877
|
}
|
|
878
878
|
function D1(i, t) {
|
|
879
|
-
const { t: n } =
|
|
879
|
+
const { t: n } = g(), [, r] = b(0);
|
|
880
880
|
if (I(() => {
|
|
881
|
-
|
|
881
|
+
X(() => r((l) => l + 1));
|
|
882
882
|
}, []), i === "blur")
|
|
883
883
|
return {
|
|
884
884
|
title: n("idv2.capture.notifications.blur.title"),
|
|
885
885
|
description: n("idv2.capture.notifications.blur.description"),
|
|
886
|
-
animationData:
|
|
886
|
+
animationData: M.get("blur") ?? null
|
|
887
887
|
};
|
|
888
888
|
if (i === "glare")
|
|
889
889
|
return {
|
|
890
890
|
title: n("idv2.capture.notifications.glare.title"),
|
|
891
891
|
description: n("idv2.capture.notifications.glare.description"),
|
|
892
|
-
animationData:
|
|
892
|
+
animationData: M.get("glare") ?? null
|
|
893
893
|
};
|
|
894
894
|
if (i === "farAway")
|
|
895
895
|
return {
|
|
896
896
|
title: n("idv2.capture.notifications.notAligned.title"),
|
|
897
897
|
description: n("idv2.capture.notifications.notAligned.description"),
|
|
898
|
-
animationData:
|
|
898
|
+
animationData: M.get("align") ?? null
|
|
899
899
|
};
|
|
900
900
|
if (i === "wrongSide") {
|
|
901
901
|
const l = t === "back";
|
|
902
902
|
return {
|
|
903
903
|
title: n(l ? "idv2.capture.notifications.showBack.title" : "idv2.capture.notifications.showFront.title"),
|
|
904
904
|
description: n(l ? "idv2.capture.notifications.showBack.description" : "idv2.capture.notifications.showFront.description"),
|
|
905
|
-
animationData:
|
|
905
|
+
animationData: M.get(l ? "back" : "front") ?? null
|
|
906
906
|
};
|
|
907
907
|
}
|
|
908
908
|
return null;
|
|
@@ -912,45 +912,45 @@ const F1 = ({
|
|
|
912
912
|
mode: t,
|
|
913
913
|
isCapturing: n
|
|
914
914
|
}) => {
|
|
915
|
-
const { t: r } =
|
|
915
|
+
const { t: r } = g(), l = D1(i, t), o = m(null), s = m({
|
|
916
916
|
message: "",
|
|
917
917
|
at: 0
|
|
918
|
-
}), a =
|
|
919
|
-
const
|
|
920
|
-
if (f === F.message &&
|
|
921
|
-
s.current = { message: f, at:
|
|
922
|
-
const
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
918
|
+
}), a = m(i), d = m(!1), c = m(), h = m(), C = i === "detecting" || i === "idNotDetected" || i === "manualCapture", v = i === "manualCapture", u = i === "wrongSide", L = i === "farAway", y = i === "glare", _ = i === "blur", p = U((f) => {
|
|
919
|
+
const E = Date.now(), F = s.current;
|
|
920
|
+
if (f === F.message && E - F.at < 200) return;
|
|
921
|
+
s.current = { message: f, at: E };
|
|
922
|
+
const B = o.current;
|
|
923
|
+
B && (clearTimeout(c.current), B.textContent = "", h.current = setTimeout(() => {
|
|
924
|
+
B.textContent = f, c.current = setTimeout(() => {
|
|
925
|
+
B.textContent = "";
|
|
926
926
|
}, 3e3);
|
|
927
927
|
}, 50));
|
|
928
|
-
}, []),
|
|
928
|
+
}, []), w = U(() => r(t === "passport" ? "idv2.capture.fillFramePassport" : t === "back" ? "idv2.capture.v2.fillFrameBack" : "idv2.capture.v2.fillFrameFront"), [t, r]);
|
|
929
929
|
return I(() => {
|
|
930
|
-
if (
|
|
930
|
+
if (v) {
|
|
931
931
|
d.current = !1;
|
|
932
932
|
return;
|
|
933
933
|
}
|
|
934
934
|
if (d.current || !C) return;
|
|
935
935
|
const f = setTimeout(() => {
|
|
936
|
-
d.current = !0, p(
|
|
936
|
+
d.current = !0, p(w());
|
|
937
937
|
}, 500);
|
|
938
938
|
return () => clearTimeout(f);
|
|
939
|
-
}, [C,
|
|
939
|
+
}, [C, v, p, w]), I(() => {
|
|
940
940
|
const f = a.current;
|
|
941
|
-
a.current = i, f !== "manualCapture" &&
|
|
942
|
-
}, [p, i,
|
|
941
|
+
a.current = i, f !== "manualCapture" && v && p(r("idv2.capture.manualCapture.modeSwitchAriaAnnouncement"));
|
|
942
|
+
}, [p, i, v, r]), I(() => {
|
|
943
943
|
if (!n) {
|
|
944
944
|
if (u) {
|
|
945
|
-
const
|
|
946
|
-
p(`${r(`${
|
|
945
|
+
const E = t === "front" || t === "passport" ? "idv2.capture.notifications.showFront" : "idv2.capture.notifications.showBack";
|
|
946
|
+
p(`${r(`${E}.title`)}. ${r(`${E}.description`)}`);
|
|
947
947
|
return;
|
|
948
948
|
}
|
|
949
|
-
if (
|
|
949
|
+
if (L) {
|
|
950
950
|
p(`${r("idv2.capture.notifications.notAligned.title")}.`);
|
|
951
951
|
return;
|
|
952
952
|
}
|
|
953
|
-
if (
|
|
953
|
+
if (y) {
|
|
954
954
|
p(`${r("idv2.capture.notifications.glare.title")}.`);
|
|
955
955
|
return;
|
|
956
956
|
}
|
|
@@ -958,19 +958,19 @@ const F1 = ({
|
|
|
958
958
|
p(`${r("idv2.capture.notifications.blur.title")}.`);
|
|
959
959
|
return;
|
|
960
960
|
}
|
|
961
|
-
C && d.current && p(
|
|
961
|
+
C && d.current && p(w());
|
|
962
962
|
}
|
|
963
963
|
}, [
|
|
964
964
|
p,
|
|
965
965
|
_,
|
|
966
966
|
n,
|
|
967
|
+
L,
|
|
967
968
|
y,
|
|
968
|
-
M,
|
|
969
969
|
C,
|
|
970
970
|
u,
|
|
971
971
|
t,
|
|
972
972
|
r,
|
|
973
|
-
|
|
973
|
+
w
|
|
974
974
|
]), I(() => () => {
|
|
975
975
|
clearTimeout(h.current), clearTimeout(c.current);
|
|
976
976
|
}, []), /* @__PURE__ */ e($, { children: [
|
|
@@ -988,7 +988,7 @@ const F1 = ({
|
|
|
988
988
|
/* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationTitle", children: l.title }),
|
|
989
989
|
l.description && /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationDescription", children: l.description })
|
|
990
990
|
] }),
|
|
991
|
-
/* @__PURE__ */ e(
|
|
991
|
+
/* @__PURE__ */ e(Z, { size: 16, direction: "horizontal" }),
|
|
992
992
|
l.animationData && /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationAnimation", children: /* @__PURE__ */ e(A, { animationData: l.animationData, loop: !0 }) })
|
|
993
993
|
] }) }) : null
|
|
994
994
|
] });
|
|
@@ -1005,37 +1005,37 @@ const F1 = ({
|
|
|
1005
1005
|
helpButtonRef: d,
|
|
1006
1006
|
captureButtonRef: c
|
|
1007
1007
|
}, h) => {
|
|
1008
|
-
const { t: C } =
|
|
1008
|
+
const { t: C } = g();
|
|
1009
1009
|
k1(), I(() => {
|
|
1010
1010
|
o && c && c.current?.focus();
|
|
1011
1011
|
}, [o, c]);
|
|
1012
|
-
const
|
|
1012
|
+
const v = () => l || n === "capturing" ? "capturing" : n === "blur" || n === "glare" || n === "wrongSide" || n === "farAway" ? "error" : "idle", u = W(() => {
|
|
1013
1013
|
if (l || n === "capturing")
|
|
1014
1014
|
return {
|
|
1015
1015
|
title: C("idv2.capture.takingPhoto"),
|
|
1016
1016
|
subtitle: C("idv2.capture.dontMove")
|
|
1017
1017
|
};
|
|
1018
|
-
if (
|
|
1019
|
-
const
|
|
1018
|
+
if (n === "detecting" || n === "idNotDetected" || n === "manualCapture") {
|
|
1019
|
+
const f = n === "manualCapture";
|
|
1020
1020
|
return i === "passport" ? {
|
|
1021
1021
|
title: C("idv2.capture.fillFramePassport"),
|
|
1022
|
-
subtitle:
|
|
1022
|
+
subtitle: f ? "" : C("idv2.capture.v2.autoCapture")
|
|
1023
1023
|
} : i === "back" ? {
|
|
1024
1024
|
title: C("idv2.capture.v2.fillFrameBack"),
|
|
1025
|
-
subtitle:
|
|
1025
|
+
subtitle: f ? "" : C("idv2.capture.v2.autoCapture")
|
|
1026
1026
|
} : {
|
|
1027
1027
|
title: C("idv2.capture.v2.fillFrameFront"),
|
|
1028
|
-
subtitle:
|
|
1028
|
+
subtitle: f ? "" : C("idv2.capture.v2.autoCapture")
|
|
1029
1029
|
};
|
|
1030
1030
|
}
|
|
1031
1031
|
return null;
|
|
1032
|
-
},
|
|
1032
|
+
}, [l, n, i, C]), L = v(), y = i === "passport", _ = t !== "vertical" || y, p = _ ? "horizontal" : "vertical";
|
|
1033
1033
|
return /* @__PURE__ */ e(
|
|
1034
1034
|
s1,
|
|
1035
1035
|
{
|
|
1036
1036
|
className: x(
|
|
1037
1037
|
"IncodeCaptureOverlayId",
|
|
1038
|
-
!
|
|
1038
|
+
!_ && "IncodeCaptureOverlayVertical"
|
|
1039
1039
|
),
|
|
1040
1040
|
children: [
|
|
1041
1041
|
/* @__PURE__ */ e("div", { class: "IncodeCaptureTopSection", children: [
|
|
@@ -1050,9 +1050,9 @@ const F1 = ({
|
|
|
1050
1050
|
/* @__PURE__ */ e(
|
|
1051
1051
|
l1,
|
|
1052
1052
|
{
|
|
1053
|
-
title:
|
|
1054
|
-
subtitle:
|
|
1055
|
-
visible:
|
|
1053
|
+
title: u?.title ?? "",
|
|
1054
|
+
subtitle: u?.subtitle,
|
|
1055
|
+
visible: u !== null,
|
|
1056
1056
|
titleId: "id-capture-heading"
|
|
1057
1057
|
}
|
|
1058
1058
|
)
|
|
@@ -1062,15 +1062,13 @@ const F1 = ({
|
|
|
1062
1062
|
{
|
|
1063
1063
|
ref: h,
|
|
1064
1064
|
variant: "locked",
|
|
1065
|
-
orientation:
|
|
1066
|
-
frameState:
|
|
1067
|
-
className: x(
|
|
1068
|
-
children:
|
|
1069
|
-
l && r > 0 && /* @__PURE__ */ e("div", { class: "IncodeCaptureCounter", "aria-hidden": "true", children: r }),
|
|
1070
|
-
/* @__PURE__ */ e("div", { class: "IncodeSrOnly", "aria-live": "polite", "aria-atomic": "true", children: l && r > 0 ? r : "" })
|
|
1071
|
-
]
|
|
1065
|
+
orientation: p,
|
|
1066
|
+
frameState: L,
|
|
1067
|
+
className: x(y && "IncodeCaptureFramePassport"),
|
|
1068
|
+
children: l && r > 0 && /* @__PURE__ */ e("div", { class: "IncodeCaptureCounter", children: r })
|
|
1072
1069
|
}
|
|
1073
1070
|
),
|
|
1071
|
+
/* @__PURE__ */ e("div", { class: "IncodeSrOnly", "aria-live": "polite", "aria-atomic": "true", children: l && r > 0 ? r : "" }),
|
|
1074
1072
|
/* @__PURE__ */ e(
|
|
1075
1073
|
a1,
|
|
1076
1074
|
{
|
|
@@ -1099,9 +1097,9 @@ const F1 = ({
|
|
|
1099
1097
|
);
|
|
1100
1098
|
}
|
|
1101
1099
|
), o2 = ({ manager: i, state: t }) => {
|
|
1102
|
-
const { t: n } =
|
|
1100
|
+
const { t: n } = g();
|
|
1103
1101
|
if (t.captureStatus === "initializing")
|
|
1104
|
-
return /* @__PURE__ */ e(D, { hideHeader: !0, hideFooterBranding: !0, className: "IncodeIdCapturePage", children: /* @__PURE__ */ e(
|
|
1102
|
+
return /* @__PURE__ */ e(D, { hideHeader: !0, hideFooterBranding: !0, className: "IncodeIdCapturePage", children: /* @__PURE__ */ e(j, { size: "large", title: `${n("webcam.loading")}...` }) });
|
|
1105
1103
|
if (t.captureStatus === "uploading" && t.previewImageUrl) {
|
|
1106
1104
|
const r = t.currentMode === "passport" ? "passport" : "id";
|
|
1107
1105
|
return /* @__PURE__ */ e(
|
|
@@ -1116,7 +1114,7 @@ const F1 = ({
|
|
|
1116
1114
|
}
|
|
1117
1115
|
return t.captureStatus === "success" && t.previewImageUrl ? /* @__PURE__ */ e(E1, { manager: i, state: t }) : t.captureStatus === "uploadError" && t.previewImageUrl ? /* @__PURE__ */ e(V1, { manager: i, state: t }) : /* @__PURE__ */ e(P1, { manager: i, state: t });
|
|
1118
1116
|
}, P1 = ({ manager: i, state: t }) => {
|
|
1119
|
-
const n =
|
|
1117
|
+
const n = m(null), r = m(null), l = m(null), o = m(null), [s, a] = b(!1), [d, c] = b(!1);
|
|
1120
1118
|
I(() => {
|
|
1121
1119
|
const p = n.current;
|
|
1122
1120
|
if (!p || !t.stream) {
|
|
@@ -1124,15 +1122,15 @@ const F1 = ({
|
|
|
1124
1122
|
return;
|
|
1125
1123
|
}
|
|
1126
1124
|
c(!1);
|
|
1127
|
-
const
|
|
1128
|
-
return p.addEventListener("playing",
|
|
1129
|
-
}), () => p.removeEventListener("playing",
|
|
1125
|
+
const w = () => c(!0);
|
|
1126
|
+
return p.addEventListener("playing", w), p.srcObject = t.stream, p.play().catch(() => {
|
|
1127
|
+
}), () => p.removeEventListener("playing", w);
|
|
1130
1128
|
}, [t.stream]), I(() => {
|
|
1131
1129
|
const p = () => {
|
|
1132
|
-
const
|
|
1133
|
-
if (!
|
|
1130
|
+
const w = r.current;
|
|
1131
|
+
if (!w)
|
|
1134
1132
|
return;
|
|
1135
|
-
const f =
|
|
1133
|
+
const f = w.getBoundingClientRect();
|
|
1136
1134
|
i.updateDetectionArea({
|
|
1137
1135
|
x: f.left,
|
|
1138
1136
|
y: f.top,
|
|
@@ -1142,13 +1140,13 @@ const F1 = ({
|
|
|
1142
1140
|
};
|
|
1143
1141
|
return p(), window.addEventListener("resize", p), () => window.removeEventListener("resize", p);
|
|
1144
1142
|
}, [i, t.orientation, d]);
|
|
1145
|
-
const h = t.captureStatus === "capturing" || t.detectionStatus === "capturing", C = t.detectionStatus,
|
|
1143
|
+
const h = t.captureStatus === "capturing" || t.detectionStatus === "capturing", C = t.detectionStatus, v = C === "manualCapture" || t.showCaptureButtonInAuto && t.captureStatus === "detecting" && C !== "capturing", u = () => {
|
|
1146
1144
|
a(!0);
|
|
1147
|
-
},
|
|
1145
|
+
}, L = () => {
|
|
1148
1146
|
a(!1), requestAnimationFrame(() => {
|
|
1149
1147
|
o.current ? o.current.focus() : l.current?.focus();
|
|
1150
1148
|
});
|
|
1151
|
-
},
|
|
1149
|
+
}, y = () => {
|
|
1152
1150
|
a(!1), i.switchToManualCapture();
|
|
1153
1151
|
}, _ = () => {
|
|
1154
1152
|
i.capture();
|
|
@@ -1163,7 +1161,7 @@ const F1 = ({
|
|
|
1163
1161
|
detectionStatus: t.detectionStatus,
|
|
1164
1162
|
counterValue: t.counterValue,
|
|
1165
1163
|
isCapturing: h,
|
|
1166
|
-
showManualCapture:
|
|
1164
|
+
showManualCapture: v,
|
|
1167
1165
|
onCapture: _,
|
|
1168
1166
|
onOpenHelp: u,
|
|
1169
1167
|
helpButtonRef: l,
|
|
@@ -1173,13 +1171,13 @@ const F1 = ({
|
|
|
1173
1171
|
s && /* @__PURE__ */ e(
|
|
1174
1172
|
M1,
|
|
1175
1173
|
{
|
|
1176
|
-
onClose:
|
|
1177
|
-
onTakeManually:
|
|
1174
|
+
onClose: L,
|
|
1175
|
+
onTakeManually: y
|
|
1178
1176
|
}
|
|
1179
1177
|
)
|
|
1180
1178
|
] });
|
|
1181
1179
|
}, a2 = ({ manager: i, state: t }) => {
|
|
1182
|
-
const { t: n } =
|
|
1180
|
+
const { t: n } = g(), [r, l] = b(!1), [o, s] = b(null), a = t.selectedDocumentType === "passport", d = t.currentMode === "back";
|
|
1183
1181
|
if (I(() => {
|
|
1184
1182
|
a ? import("./passport-tutorial-CaYBFTqt.js").then((u) => {
|
|
1185
1183
|
s(u.default);
|
|
@@ -2479,7 +2477,7 @@ function N1(i) {
|
|
|
2479
2477
|
return i.reduce(t, []).sort((n, r) => n.weight - r.weight);
|
|
2480
2478
|
}
|
|
2481
2479
|
const s2 = ({ manager: i, state: t }) => {
|
|
2482
|
-
const { t: n } =
|
|
2480
|
+
const { t: n } = g(), r = W(
|
|
2483
2481
|
() => N1(t.availableDocumentTypes),
|
|
2484
2482
|
[t.availableDocumentTypes]
|
|
2485
2483
|
), l = (o) => {
|
|
@@ -2508,7 +2506,7 @@ const s2 = ({ manager: i, state: t }) => {
|
|
|
2508
2506
|
manager: i,
|
|
2509
2507
|
direction: t
|
|
2510
2508
|
}) => {
|
|
2511
|
-
const [n, r] =
|
|
2509
|
+
const [n, r] = b(null), [l, o] = b(!1), { t: s } = g();
|
|
2512
2510
|
I(() => {
|
|
2513
2511
|
import("./flip-animation-COR596wy.js").then((c) => {
|
|
2514
2512
|
r(c.default);
|
|
@@ -2517,9 +2515,9 @@ const s2 = ({ manager: i, state: t }) => {
|
|
|
2517
2515
|
const a = U(async () => {
|
|
2518
2516
|
await new Promise((c) => setTimeout(c, 1e3)), t === "toBack" ? i.continueToBack() : i.continueToFront(), o(!0);
|
|
2519
2517
|
}, [t, i]);
|
|
2520
|
-
return l ? /* @__PURE__ */ e(
|
|
2518
|
+
return l ? /* @__PURE__ */ e(j, { size: "large" }) : n ? /* @__PURE__ */ e("div", { class: "IncodeFlipAnimation", children: [
|
|
2521
2519
|
/* @__PURE__ */ e(P, { role: "status", className: "IncodeFlipAnimationTitle", children: s(t === "toBack" ? "idv2.flipAnimation.title" : "idv2.flipAnimation.titleToFront") }),
|
|
2522
|
-
/* @__PURE__ */ e(
|
|
2520
|
+
/* @__PURE__ */ e(Z, { size: 32 }),
|
|
2523
2521
|
/* @__PURE__ */ e(
|
|
2524
2522
|
A,
|
|
2525
2523
|
{
|
package/dist/id/id.es.js
CHANGED
|
@@ -5,7 +5,7 @@ import "@incodetech/core";
|
|
|
5
5
|
import { P as c } from "../manualCaptureButton-iYqQECzn.js";
|
|
6
6
|
import { r as p } from "../incodeModule-aE-LkKwM.js";
|
|
7
7
|
import { P as l } from "../processing-BhY0-0xy.js";
|
|
8
|
-
import { d as f, c as I, F as a, b as g, e as h, I as C } from "../flipAnimation-
|
|
8
|
+
import { d as f, c as I, F as a, b as g, e as h, I as C } from "../flipAnimation-CnXEIDH1.js";
|
|
9
9
|
import "../uiConfig-Z6RT23Sl.js";
|
|
10
10
|
import "../spinner-BbVGMG-G.js";
|
|
11
11
|
const F = ({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@incodetech/web",
|
|
3
|
-
"version": "0.0.0-dev-20260320-
|
|
3
|
+
"version": "0.0.0-dev-20260320-c9bdba0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.es.js",
|
|
6
6
|
"types": "./dist/types/index.d.ts",
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
"preact-custom-element": "^4.6.0",
|
|
120
120
|
"qrcode": "^1.5.4",
|
|
121
121
|
"tailwindcss": "^4.1.17",
|
|
122
|
-
"@incodetech/core": "0.0.0-dev-20260320-
|
|
122
|
+
"@incodetech/core": "0.0.0-dev-20260320-c9bdba0"
|
|
123
123
|
},
|
|
124
124
|
"devDependencies": {
|
|
125
125
|
"@microsoft/api-extractor": "^7.53.3",
|