@incodetech/web 2.1.0-rc.2 → 2.1.0-rc.4
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/ae-signature/ae-signature.es.js +2 -2
- package/dist/ae-signature/styles.css +59 -45
- package/dist/antifraud/antifraud.es.js +4 -4
- package/dist/authentication/authentication.es.js +5 -4
- package/dist/base.css +87 -59
- package/dist/{button-Ch5-QgHB.js → button-Dz6AsbmF.js} +2 -1
- package/dist/cameraView-DIEzM5ru.js +47 -0
- package/dist/{tutorial-Cap8qKvM.js → capture-CkGvdDNH.js} +18 -568
- package/dist/certificate-issuance/certificate-issuance.es.js +7 -7
- package/dist/consent/consent.es.js +8 -8
- package/dist/{countrySelector-B4WuNUya.js → countrySelector-SvUOyPo0.js} +1 -1
- package/dist/cpf-ocr/cpf-ocr.es.js +1 -1
- package/dist/cpfOcr-B79245-3.js +2 -0
- package/dist/{cpfOcr-liTE9e70.js → cpfOcr-BhxT-lRN.js} +5 -5
- package/dist/cross-document-data-match/cross-document-data-match.es.js +4 -4
- package/dist/curp-validation/curp-validation.es.js +7 -7
- package/dist/{customFields-BQ4scZfL.js → customFields-BDsXR7A-.js} +6 -6
- package/dist/{customWatchlist-7s0_wGtE.js → customWatchlist-CYoRNCim.js} +5 -5
- package/dist/document-capture/document-capture.es.js +1 -1
- package/dist/documentCapture-DXYYyxZl.js +2 -0
- package/dist/{documentCapture-CwoSD_Iq.js → documentCapture-DhbO-A-V.js} +11 -9
- package/dist/{dynamicForms-DvTU65bW.js → dynamicForms-BifGbC9F.js} +19 -8
- package/dist/ekyb/ekyb.es.js +1 -1
- package/dist/ekybModule-C6Nttked.js +2 -0
- package/dist/{ekybModule-CwZvxios.js → ekybModule-DGnTw5UV.js} +12 -12
- package/dist/ekyc/ekyc.es.js +1 -1
- package/dist/ekycModule-CDIEjI6V.js +2 -0
- package/dist/{ekycModule-jkXByPXe.js → ekycModule-Dxpdd0ns.js} +10 -10
- package/dist/electronic-signature/electronic-signature.es.js +1 -1
- package/dist/{electronic-signature-h1sAGg7l.js → electronic-signature-Ueoffasr.js} +37 -26
- package/dist/email/email.es.js +7 -7
- package/dist/{emailInput-BRMJMJV6.js → emailInput-DsLkDtER.js} +5 -5
- package/dist/{expiredId-D17oN5K2.js → expiredId-BZXLrLk-.js} +4 -4
- package/dist/{extensibility-CTmAsaji.js → extensibility-7sRIN0JC.js} +41 -76
- package/dist/extensibility.es.js +13 -11
- package/dist/face-match/face-match.es.js +1 -1
- package/dist/face-match/styles.css +4 -0
- package/dist/faceMatch-B_HvxLm_.js +2 -0
- package/dist/{faceMatch-Dez_bq3n.js → faceMatch-DyTBoMDm.js} +8 -8
- package/dist/field-comparison/field-comparison.es.js +1 -1
- package/dist/fieldComparison-DfNEuEE5.js +2 -0
- package/dist/{fieldComparison-BelzSC48.js → fieldComparison-L_knHqgw.js} +7 -7
- package/dist/fiscal-qr/fiscal-qr.es.js +8 -7
- package/dist/flow/flow.es.js +22 -9
- package/dist/flow/styles.css +4151 -3042
- package/dist/geolocation/geolocation.es.js +14 -9
- package/dist/{governmentValidation/governmentValidation.es.js → government-validation/government-validation.es.js} +10 -14
- package/dist/{homeScreen-BIdVm9KA.js → homeScreen-B6T0JVh8.js} +2 -2
- package/dist/{hooks-Da_yP_Dr.js → hooks-CNu7o-v8.js} +39 -2
- package/dist/{i18n-DoP1NB7u.js → i18n-CU4xq8qC.js} +1 -1
- package/dist/id/id.es.js +76 -46
- package/dist/id/styles.css +1 -9
- package/dist/id-ocr/styles.css +12 -2
- package/dist/id-verification/id-verification.es.js +5 -5
- package/dist/{idOcr-C4K2XVJr.js → idOcr-WFBvqy3b.js} +31 -13
- package/dist/identity-reuse/identity-reuse.es.js +6 -6
- package/dist/{incodeComponent-Cmi1rlWs.js → incodeComponent-CfzJGETt.js} +2 -2
- package/dist/{incodeModule-M8DszCee.js → incodeModule-B-4_3JrK.js} +1 -1
- package/dist/index.es.js +3 -2
- package/dist/{mandatoryConsent-DOQ0DKgM.js → mandatoryConsent-D0GTKu-H.js} +7 -7
- package/dist/{optionAccessibleLabel-_nvVCTSL.js → optionAccessibleLabel-gfF-58Mv.js} +3 -3
- package/dist/{otpInput-Q_kzSZeD.js → otpInput-CnDc6pQm.js} +12 -11
- package/dist/{pdf-BMUXKJuC.js → pdf-BqtJTlor.js} +1 -1
- package/dist/{pdfViewer-BewML6eg.js → pdfViewer-B97DmT9m.js} +57 -20
- package/dist/phone/phone.es.js +6 -6
- package/dist/{processing-Boki1Z8j.js → processing-BeUMfdJJ.js} +1 -1
- package/dist/qe-signature/qe-signature.es.js +2 -2
- package/dist/{radioGroupComposed-TuAWUAFK.js → radioGroupComposed-DuQxslB2.js} +1 -1
- package/dist/redirect-to-mobile/redirect-to-mobile.es.js +17 -18
- package/dist/redirect-to-mobile/styles.css +2 -2
- package/dist/{richText-DsTP4H3j.js → richText-CB1fmegc.js} +1 -1
- package/dist/selfie/selfie.es.js +8 -7
- package/dist/selfie/styles.css +133 -63
- package/dist/signature/signature.es.js +8 -8
- package/dist/spinner-BCDCoi9C.js +1 -0
- package/dist/{spinner-BRNNKqPN.js → spinner-BMeIEK1d.js} +12 -6
- package/dist/themes/dark.css +16 -0
- package/dist/themes/light.css +16 -0
- package/dist/{transitionSpinner-4rPkt-KM.js → transitionSpinner-CuNCqHNi.js} +9 -8
- package/dist/tutorial-CCfPuVKX.js +706 -0
- package/dist/types/ae-signature.d.ts +23 -1
- package/dist/types/antifraud.d.ts +23 -1
- package/dist/types/authentication.d.ts +23 -1
- package/dist/types/certificate-issuance.d.ts +23 -1
- package/dist/types/consent.d.ts +23 -1
- package/dist/types/cross-document-data-match.d.ts +23 -1
- package/dist/types/curp-validation.d.ts +23 -1
- package/dist/types/document-capture.d.ts +23 -1
- package/dist/types/ekyb.d.ts +23 -1
- package/dist/types/ekyc.d.ts +23 -1
- package/dist/types/electronic-signature.d.ts +23 -1
- package/dist/types/email.d.ts +23 -1
- package/dist/types/extensibility.d.ts +39 -2
- package/dist/types/face-match.d.ts +23 -1
- package/dist/types/field-comparison.d.ts +23 -1
- package/dist/types/fiscal-qr.d.ts +23 -1
- package/dist/types/flow.d.ts +23 -1
- package/dist/types/geolocation.d.ts +27 -2
- package/dist/types/{governmentValidation.d.ts → government-validation.d.ts} +23 -1
- package/dist/types/id-verification.d.ts +23 -1
- package/dist/types/id.d.ts +23 -1
- package/dist/types/identity-reuse.d.ts +23 -1
- package/dist/types/index.d.ts +8 -1
- package/dist/types/phone.d.ts +23 -1
- package/dist/types/qe-signature.d.ts +23 -1
- package/dist/types/selfie.d.ts +23 -1
- package/dist/types/signature.d.ts +23 -1
- package/dist/types/video-selfie.d.ts +72 -0
- package/dist/types/watchlist.d.ts +23 -1
- package/dist/types/workflow.d.ts +23 -1
- package/dist/{useModuleLoader-Kt78XfNR.js → useModuleLoader-Gvo9qscB.js} +38 -23
- package/dist/{verificationResult-B6PBXbp9.js → verificationResult-BWWkmeiA.js} +3 -3
- package/dist/video-selfie/styles.css +1644 -0
- package/dist/video-selfie/video-selfie.es.js +854 -0
- package/dist/watchlist/watchlist.es.js +5 -5
- package/dist/{watchlistForBusiness-DCKlKG81.js → watchlistForBusiness-D2Uo_TwF.js} +7 -7
- package/dist/workflow/styles.css +148 -76
- package/dist/workflow/workflow.es.js +23 -27
- package/package.json +29 -2
- package/dist/cpfOcr-BJOYoITy.js +0 -2
- package/dist/documentCapture-3RHCHepT.js +0 -2
- package/dist/ekybModule-BkVQBQvW.js +0 -2
- package/dist/ekycModule-BIbj7hr1.js +0 -2
- package/dist/faceMatch-C0-RPzrc.js +0 -2
- package/dist/fieldComparison-7FUznk_9.js +0 -2
- package/dist/spinner-zRaUjXtH.js +0 -1
- /package/dist/{aligndevicelottie-DMXPhIDs.js → aligndevicelottie-DFscByAI.js} +0 -0
- /package/dist/{back-horizontal-hint-DNIIDrEW.js → back-horizontal-hint-xTnSQbzn.js} +0 -0
- /package/dist/{back-tutorial-B8JJSJBB.js → back-tutorial-cI_4VHmE.js} +0 -0
- /package/dist/{back-vertical-hint-CW6ZS7bP.js → back-vertical-hint-BWWlHfX2.js} +0 -0
- /package/dist/{backdevicelottie-By75Bznp.js → backdevicelottie-COyhTrxM.js} +0 -0
- /package/dist/{blurdevicelottie-C_9VAHkM.js → blurdevicelottie-BLVeJHEG.js} +0 -0
- /package/dist/{browser-ponyfill-C_DpU0lQ.js → browser-ponyfill-Df13Th-G.js} +0 -0
- /package/dist/{defineProperty-CTu-cLWm.js → defineProperty-Qjefk7Uf.js} +0 -0
- /package/dist/{flip-animation-st9bra1p.js → flip-animation-CZYSUtMm.js} +0 -0
- /package/dist/{front-horizontal-hint-DvME-aVk.js → front-horizontal-hint-B84GgTO1.js} +0 -0
- /package/dist/{front-vertical-hint-BUG1VMsP.js → front-vertical-hint-Bs_avngq.js} +0 -0
- /package/dist/{frontdevicelottie-uObOEs8p.js → frontdevicelottie-B4tE2PYQ.js} +0 -0
- /package/dist/{glaredevicelottie-CsfIgqIc.js → glaredevicelottie-D1pR73sx.js} +0 -0
- /package/dist/{governmentValidation → government-validation}/styles.css +0 -0
- /package/dist/{id-laser-h-BvVSaLyU.js → id-laser-h-CzPegPMn.js} +0 -0
- /package/dist/{id-laser-v-Dj_RN_s9.js → id-laser-v-BiUXkM4x.js} +0 -0
- /package/dist/{id-tutorial-BOOsXlAJ.js → id-tutorial-DwO90SAm.js} +0 -0
- /package/dist/{lottie_light-BG-RL2Iu.js → lottie_light-C6B2ec41.js} +0 -0
- /package/dist/{numberedStep-Dc0BUU-j.js → numberedStep-CEb-lFJm.js} +0 -0
- /package/dist/{passport-horizontal-hint-BhpVt73n.js → passport-horizontal-hint-Bj0ZJY0g.js} +0 -0
- /package/dist/{passport-tutorial-CeSup6m9.js → passport-tutorial-D9JNsMsM.js} +0 -0
- /package/dist/{passport-vertical-hint-CVRBnZXS.js → passport-vertical-hint-Dfk77xUJ.js} +0 -0
- /package/dist/{registerIncodeElement-CdlNRRv5.js → registerIncodeElement-DaNjbAwZ.js} +0 -0
- /package/dist/{requiredLabelHint-DX3oVNtu.js → requiredLabelHint-D0RhuMed.js} +0 -0
- /package/dist/{selfieTutorial-CYa8bq6B.js → selfieTutorial-pB-N-fj5.js} +0 -0
- /package/dist/{snackbar-CGL6gp9u.js → snackbar-DS7Mv62v.js} +0 -0
- /package/dist/{statusPage-BUm5gtQY.js → statusPage-Bk8nJwXV.js} +0 -0
- /package/dist/{tabs-DUkWjBGk.js → tabs-C__chW-u.js} +0 -0
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { n as useTranslation, t as Trans } from "../i18n-
|
|
1
|
+
import { n as useTranslation, t as Trans } from "../i18n-CU4xq8qC.js";
|
|
2
2
|
import { v as u, x as k } from "../vendor-preact-DThS2ZQ_.js";
|
|
3
|
-
import { c as
|
|
4
|
-
import { t as IncodeComponent } from "../incodeComponent-
|
|
3
|
+
import { c as useModuleTerminalCallbacks, u as useManager } from "../hooks-CNu7o-v8.js";
|
|
4
|
+
import { t as IncodeComponent } from "../incodeComponent-CfzJGETt.js";
|
|
5
5
|
import { r as Spacer } from "../loadingIcon-B0ysgiNq.js";
|
|
6
6
|
import { t as Page } from "../page-DidH_RkX.js";
|
|
7
|
-
import { t as Button } from "../button-
|
|
8
|
-
import { t as NumberedStep } from "../numberedStep-
|
|
9
|
-
import { t as registerIncodeModuleElement } from "../incodeModule-
|
|
7
|
+
import { t as Button } from "../button-Dz6AsbmF.js";
|
|
8
|
+
import { t as NumberedStep } from "../numberedStep-CEb-lFJm.js";
|
|
9
|
+
import { t as registerIncodeModuleElement } from "../incodeModule-B-4_3JrK.js";
|
|
10
10
|
import { getBrowser, getDeviceClass } from "@incodetech/core/device";
|
|
11
11
|
import { createGeolocationManager } from "@incodetech/core/geolocation";
|
|
12
12
|
//#region src/modules/geolocation/LocationActiveIcon.tsx
|
|
@@ -733,11 +733,13 @@ var GeolocationPermissionDenied = ({ canSkip, onSkip, onRefresh }) => {
|
|
|
733
733
|
/* @__PURE__ */ u(Spacer, {}),
|
|
734
734
|
/* @__PURE__ */ u(Button, {
|
|
735
735
|
onClick: onRefresh,
|
|
736
|
+
"data-testid": "geolocation-refresh",
|
|
736
737
|
children: t("geolocationv2.refreshPage")
|
|
737
738
|
}),
|
|
738
739
|
canSkip ? /* @__PURE__ */ u(k, { children: [/* @__PURE__ */ u(Spacer, { size: 12 }), /* @__PURE__ */ u(Button, {
|
|
739
740
|
variant: "secondary",
|
|
740
741
|
onClick: onSkip,
|
|
742
|
+
"data-testid": "geolocation-skip",
|
|
741
743
|
children: t("geolocationv2.skip")
|
|
742
744
|
})] }) : null
|
|
743
745
|
]
|
|
@@ -761,17 +763,19 @@ var GeolocationPageLayout = ({ icon: Icon, title, subtitle, onContinue, isLoadin
|
|
|
761
763
|
onClick: onContinue,
|
|
762
764
|
"aria-label": isLoading ? t("geolocation.continue") : void 0,
|
|
763
765
|
"aria-busy": isLoading || void 0,
|
|
766
|
+
"data-testid": "geolocation-continue",
|
|
764
767
|
children: t("geolocation.continue")
|
|
765
768
|
})
|
|
766
769
|
})]
|
|
767
770
|
});
|
|
768
771
|
};
|
|
769
|
-
var GeolocationContent = ({ config, onFinish, onError: _onError }) => {
|
|
772
|
+
var GeolocationContent = ({ config, manager: externalManager, onFinish, onError: _onError }) => {
|
|
770
773
|
const { t } = useTranslation();
|
|
771
774
|
const [state, manager] = useManager(() => {
|
|
775
|
+
if (externalManager) return externalManager;
|
|
772
776
|
if (!config) throw new Error("Geolocation config is required");
|
|
773
777
|
return createGeolocationManager({ config });
|
|
774
|
-
});
|
|
778
|
+
}, { manageLifecycle: !externalManager });
|
|
775
779
|
useModuleTerminalCallbacks({
|
|
776
780
|
status: state.status === "finished" ? "finished" : "loading",
|
|
777
781
|
onFinish
|
|
@@ -797,8 +801,9 @@ var GeolocationContent = ({ config, onFinish, onError: _onError }) => {
|
|
|
797
801
|
if (state.status === "finished") return null;
|
|
798
802
|
return null;
|
|
799
803
|
};
|
|
800
|
-
var Geolocation = ({ config, onFinish, onError }) => /* @__PURE__ */ u(IncodeComponent, { children: config ? /* @__PURE__ */ u(GeolocationContent, {
|
|
804
|
+
var Geolocation = ({ config, manager, onFinish, onError }) => /* @__PURE__ */ u(IncodeComponent, { children: config ? /* @__PURE__ */ u(GeolocationContent, {
|
|
801
805
|
config,
|
|
806
|
+
manager,
|
|
802
807
|
onFinish,
|
|
803
808
|
onError
|
|
804
809
|
}) : null });
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { n as useTranslation } from "../i18n-
|
|
1
|
+
import { n as useTranslation } from "../i18n-CU4xq8qC.js";
|
|
2
2
|
import { v as u, x as k } from "../vendor-preact-DThS2ZQ_.js";
|
|
3
|
-
import { c as
|
|
4
|
-
import { t as IncodeComponent } from "../incodeComponent-
|
|
3
|
+
import { c as useModuleTerminalCallbacks, u as useManager } from "../hooks-CNu7o-v8.js";
|
|
4
|
+
import { t as IncodeComponent } from "../incodeComponent-CfzJGETt.js";
|
|
5
5
|
import { r as Spacer } from "../loadingIcon-B0ysgiNq.js";
|
|
6
6
|
import { t as Page } from "../page-DidH_RkX.js";
|
|
7
|
-
import "../extensibility-
|
|
7
|
+
import "../extensibility-7sRIN0JC.js";
|
|
8
8
|
import { t as AutoFocusTitle } from "../autoFocusTitle-CuRu2lPg.js";
|
|
9
|
-
import { t as VerificationResult } from "../verificationResult-
|
|
10
|
-
import { t as OtpInput } from "../otpInput-
|
|
11
|
-
import { t as registerIncodeModuleElement } from "../incodeModule-
|
|
9
|
+
import { t as VerificationResult } from "../verificationResult-BWWkmeiA.js";
|
|
10
|
+
import { t as OtpInput } from "../otpInput-CnDc6pQm.js";
|
|
11
|
+
import { t as registerIncodeModuleElement } from "../incodeModule-B-4_3JrK.js";
|
|
12
12
|
import { createGovernmentValidationManager } from "@incodetech/core/government-validation";
|
|
13
|
-
//#region src/modules/
|
|
13
|
+
//#region src/modules/government-validation/governmentIncodeLogo.tsx
|
|
14
14
|
var VerifiedByGovIncodeLogo = () => {
|
|
15
15
|
return /* @__PURE__ */ u("svg", {
|
|
16
16
|
width: "390",
|
|
@@ -84,7 +84,7 @@ var VerifiedByGovIncodeLogo = () => {
|
|
|
84
84
|
});
|
|
85
85
|
};
|
|
86
86
|
//#endregion
|
|
87
|
-
//#region src/modules/
|
|
87
|
+
//#region src/modules/government-validation/government-validation.tsx
|
|
88
88
|
var GovernmentVerificationResult = (props) => /* @__PURE__ */ u(VerificationResult, {
|
|
89
89
|
...props,
|
|
90
90
|
hideFooterBranding: false,
|
|
@@ -103,7 +103,7 @@ var GovernmentValidationContent = ({ config, onFinish }) => {
|
|
|
103
103
|
if (config.backgroundExecution || state.status === "finished") return null;
|
|
104
104
|
const isOtpStep = state.status === "awaitingOtp" || state.status === "verifyingOtp";
|
|
105
105
|
return /* @__PURE__ */ u(k, { children: [
|
|
106
|
-
(state.status === "idle" || state.status === "loading") && /* @__PURE__ */ u(GovernmentVerificationResult, {
|
|
106
|
+
(state.status === "idle" || state.status === "loading" || state.status === "processing") && /* @__PURE__ */ u(GovernmentVerificationResult, {
|
|
107
107
|
status: "submitting",
|
|
108
108
|
submittingTitle: t("common.holdOnASec"),
|
|
109
109
|
submittingSubtitle: t("ineCheck.checkingYourInformation")
|
|
@@ -112,10 +112,6 @@ var GovernmentValidationContent = ({ config, onFinish }) => {
|
|
|
112
112
|
status: "success",
|
|
113
113
|
successTitle: t("ineCheck.verified")
|
|
114
114
|
}),
|
|
115
|
-
state.status === "processing" && /* @__PURE__ */ u(GovernmentVerificationResult, {
|
|
116
|
-
status: "success",
|
|
117
|
-
successTitle: t("ineCheck.processing")
|
|
118
|
-
}),
|
|
119
115
|
isOtpStep && (() => {
|
|
120
116
|
const isVerifying = state.status === "verifyingOtp";
|
|
121
117
|
const otpError = state.status === "awaitingOtp" ? state.otpError : void 0;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { c as supportedLanguages, n as useTranslation, s as getLanguageEmoji } from "./i18n-
|
|
1
|
+
import { c as supportedLanguages, n as useTranslation, s as getLanguageEmoji } from "./i18n-CU4xq8qC.js";
|
|
2
2
|
import { _ as y, d as T, l as A, p as d, v as u } from "./vendor-preact-DThS2ZQ_.js";
|
|
3
3
|
import { n as useUiConfig } from "./uiConfig-D2_wawvr.js";
|
|
4
4
|
import { r as Spacer } from "./loadingIcon-B0ysgiNq.js";
|
|
5
5
|
import "./incode-logo-57XFniXU.js";
|
|
6
|
-
import { t as Button } from "./button-
|
|
6
|
+
import { t as Button } from "./button-Dz6AsbmF.js";
|
|
7
7
|
import { t as Modal } from "./modal-OxkFuuiR.js";
|
|
8
8
|
import { t as DropdownComposed } from "./dropdownComposed-CoU0enG6.js";
|
|
9
9
|
import "./dropdownComposed-BAoxIIsE.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as y, l as A, p as d, s as gn } from "./vendor-preact-DThS2ZQ_.js";
|
|
1
|
+
import { _ as y, d as T, h as q, l as A, p as d, s as gn } from "./vendor-preact-DThS2ZQ_.js";
|
|
2
2
|
import { ScreenOrientationProvider, createScreenOrientationObserver, getDeviceClass } from "@incodetech/core/device";
|
|
3
3
|
import "@incodetech/core/events";
|
|
4
4
|
//#region src/hooks/useManager.ts
|
|
@@ -146,4 +146,41 @@ function useResizeObserver(ref, onResize) {
|
|
|
146
146
|
}, [ref, onResize]);
|
|
147
147
|
}
|
|
148
148
|
//#endregion
|
|
149
|
-
|
|
149
|
+
//#region src/hooks/useTimeout.ts
|
|
150
|
+
/**
|
|
151
|
+
* Runs `callback` once after `delayMs` when `delayMs` is not null. Clears the
|
|
152
|
+
* timer on unmount or when `delayMs` / `callback` changes.
|
|
153
|
+
*/
|
|
154
|
+
function useTimeout(callback, delayMs) {
|
|
155
|
+
y(() => {
|
|
156
|
+
if (delayMs === null) return;
|
|
157
|
+
const timeoutId = window.setTimeout(callback, delayMs);
|
|
158
|
+
return () => {
|
|
159
|
+
window.clearTimeout(timeoutId);
|
|
160
|
+
};
|
|
161
|
+
}, [callback, delayMs]);
|
|
162
|
+
}
|
|
163
|
+
/**
|
|
164
|
+
* Imperative one-shot timeout handle for user-triggered delays. Clears any
|
|
165
|
+
* pending timer on unmount.
|
|
166
|
+
*/
|
|
167
|
+
function useTimeoutHandle() {
|
|
168
|
+
const timerRef = A();
|
|
169
|
+
const clear = q(() => {
|
|
170
|
+
if (timerRef.current !== void 0) {
|
|
171
|
+
window.clearTimeout(timerRef.current);
|
|
172
|
+
timerRef.current = void 0;
|
|
173
|
+
}
|
|
174
|
+
}, []);
|
|
175
|
+
const schedule = q((callback, delayMs) => {
|
|
176
|
+
clear();
|
|
177
|
+
timerRef.current = window.setTimeout(callback, delayMs);
|
|
178
|
+
}, [clear]);
|
|
179
|
+
y(() => clear, [clear]);
|
|
180
|
+
return T(() => ({
|
|
181
|
+
schedule,
|
|
182
|
+
clear
|
|
183
|
+
}), [schedule, clear]);
|
|
184
|
+
}
|
|
185
|
+
//#endregion
|
|
186
|
+
export { useIsMobileDeviceWidth as a, useModuleTerminalCallbacks as c, useEventListener as i, useScreenOrientation as l, useTimeoutHandle as n, useFormScrollable as o, useResizeObserver as r, isTerminalModuleState as s, useTimeout as t, useManager as u };
|
|
@@ -2360,7 +2360,7 @@ if (typeof ActiveXObject === "function") {
|
|
|
2360
2360
|
}
|
|
2361
2361
|
if (typeof fetchApi !== "function") fetchApi = void 0;
|
|
2362
2362
|
if (!fetchApi && !XmlHttpRequestApi && !ActiveXObjectApi) try {
|
|
2363
|
-
import("./browser-ponyfill-
|
|
2363
|
+
import("./browser-ponyfill-Df13Th-G.js").then((m) => /* @__PURE__ */ __toESM(m.default, 1)).then(function(mod) {
|
|
2364
2364
|
fetchApi = mod.default;
|
|
2365
2365
|
}).catch(function() {});
|
|
2366
2366
|
} catch (e) {}
|
package/dist/id/id.es.js
CHANGED
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
import { n as useTranslation } from "../i18n-
|
|
1
|
+
import { n as useTranslation } from "../i18n-CU4xq8qC.js";
|
|
2
2
|
import { _ as y, c as z, d as T, l as A, o as P, p as d, v as u, x as k } from "../vendor-preact-DThS2ZQ_.js";
|
|
3
|
-
import { c as
|
|
4
|
-
import { t as IncodeComponent } from "../incodeComponent-
|
|
3
|
+
import { c as useModuleTerminalCallbacks, u as useManager } from "../hooks-CNu7o-v8.js";
|
|
4
|
+
import { t as IncodeComponent } from "../incodeComponent-CfzJGETt.js";
|
|
5
5
|
import { n as cn } from "../loadingIcon-B0ysgiNq.js";
|
|
6
6
|
import { t as Page } from "../page-DidH_RkX.js";
|
|
7
|
-
import { a as IdNoAttempts, i as Capture, n as Chooser, o as IdExpired, r as Tutorial, s as IdError, t as FlipAnimation
|
|
8
|
-
import { t as Spinner } from "../spinner-
|
|
9
|
-
import "../spinner-
|
|
10
|
-
import { t as TransitionSpinner } from "../transitionSpinner-
|
|
11
|
-
import { t as Processing } from "../processing-
|
|
12
|
-
import { t as Button } from "../button-
|
|
7
|
+
import { _ as ProgressBar, a as IdNoAttempts, i as Capture, n as Chooser, o as IdExpired, r as Tutorial, s as IdError, t as FlipAnimation } from "../extensibility-7sRIN0JC.js";
|
|
8
|
+
import { t as Spinner } from "../spinner-BMeIEK1d.js";
|
|
9
|
+
import "../spinner-BCDCoi9C.js";
|
|
10
|
+
import { t as TransitionSpinner } from "../transitionSpinner-CuNCqHNi.js";
|
|
11
|
+
import { t as Processing } from "../processing-BeUMfdJJ.js";
|
|
12
|
+
import { t as Button } from "../button-Dz6AsbmF.js";
|
|
13
13
|
import { t as ErrorIcon } from "../errorIcon-BA4T6iy-.js";
|
|
14
14
|
import { s as ChevronRightIcon } from "../icons-CJJbIpBq.js";
|
|
15
15
|
import { t as SuccessIcon } from "../successIcon-B5mGvdx1.js";
|
|
16
|
-
import { a as
|
|
17
|
-
import {
|
|
18
|
-
import { t as
|
|
19
|
-
import { t as
|
|
20
|
-
import { t as
|
|
16
|
+
import { a as ErrorContent, i as Lottie } from "../tutorial-CCfPuVKX.js";
|
|
17
|
+
import { i as Permissions } from "../capture-CkGvdDNH.js";
|
|
18
|
+
import { t as PdfViewer } from "../pdfViewer-B97DmT9m.js";
|
|
19
|
+
import { t as registerIncodeModuleElement } from "../incodeModule-B-4_3JrK.js";
|
|
20
|
+
import { t as id_laser_v_default } from "../id-laser-v-BiUXkM4x.js";
|
|
21
|
+
import { t as Tabs } from "../tabs-C__chW-u.js";
|
|
21
22
|
import { createIdCaptureManager } from "@incodetech/core/id";
|
|
22
23
|
//#region src/shared/fonts/preloadDisplayFont.ts
|
|
23
24
|
function preloadDisplayFont() {
|
|
@@ -613,6 +614,24 @@ var DigitalIdUpload = ({ manager, state }) => {
|
|
|
613
614
|
return null;
|
|
614
615
|
};
|
|
615
616
|
//#endregion
|
|
617
|
+
//#region src/modules/id/manualUpload/manualUploadError.tsx
|
|
618
|
+
/**
|
|
619
|
+
* Inline validation message for the manual-upload flow. Rendered directly
|
|
620
|
+
* beneath the slot it refers to so the user can tell which document side was
|
|
621
|
+
* rejected — the side context comes from the placement, not the copy.
|
|
622
|
+
* `role="alert"` announces it once on insert (SC 4.1.3).
|
|
623
|
+
*/
|
|
624
|
+
var ManualUploadError = ({ errorKey, id }) => {
|
|
625
|
+
const { t } = useTranslation();
|
|
626
|
+
return /* @__PURE__ */ u("div", {
|
|
627
|
+
id,
|
|
628
|
+
class: "IncodeManualUploadError",
|
|
629
|
+
role: "alert",
|
|
630
|
+
"data-testid": "manual-upload-error",
|
|
631
|
+
children: [/* @__PURE__ */ u(ErrorIcon, { size: 16 }), /* @__PURE__ */ u("p", { children: t(errorKey) })]
|
|
632
|
+
});
|
|
633
|
+
};
|
|
634
|
+
//#endregion
|
|
616
635
|
//#region src/modules/id/manualUpload/uploadButton.tsx
|
|
617
636
|
/**
|
|
618
637
|
* Slot card for a single document side. The whole card is the clickable
|
|
@@ -763,11 +782,20 @@ var UploadTab = ({ mode, manager, state, errorMessageId }) => {
|
|
|
763
782
|
invalid: true,
|
|
764
783
|
describedById: errorMessageId
|
|
765
784
|
} : {};
|
|
785
|
+
/**
|
|
786
|
+
* Render the validation message directly beneath the slot it refers to so
|
|
787
|
+
* the error is unambiguously tied to the correct document side. Only the
|
|
788
|
+
* slot matching `errorSide` gets the message.
|
|
789
|
+
*/
|
|
790
|
+
const slotError = (slot) => state.errorKey && state.errorSide === slot ? /* @__PURE__ */ u(ManualUploadError, {
|
|
791
|
+
id: errorMessageId,
|
|
792
|
+
errorKey: state.errorKey
|
|
793
|
+
}) : null;
|
|
766
794
|
if (mode === "passport") {
|
|
767
795
|
const isUploading = state.uploadingSide === "passport";
|
|
768
796
|
return /* @__PURE__ */ u("div", {
|
|
769
797
|
class: "IncodeManualUploadTab",
|
|
770
|
-
children: /* @__PURE__ */ u(UploadButton, {
|
|
798
|
+
children: [/* @__PURE__ */ u(UploadButton, {
|
|
771
799
|
icon: /* @__PURE__ */ u(PassportSlotIcon, {}),
|
|
772
800
|
label: slotLabel("passport", isUploading, state.passportUploaded),
|
|
773
801
|
uploaded: state.passportUploaded,
|
|
@@ -775,30 +803,34 @@ var UploadTab = ({ mode, manager, state, errorMessageId }) => {
|
|
|
775
803
|
testId: "manual-upload-passport",
|
|
776
804
|
onFile: (file) => manager.manualUploadSelectFile("passport", file),
|
|
777
805
|
...slotErrorProps("passport")
|
|
778
|
-
})
|
|
806
|
+
}), slotError("passport")]
|
|
779
807
|
});
|
|
780
808
|
}
|
|
781
809
|
const isUploadingFront = state.uploadingSide === "front";
|
|
782
810
|
const isUploadingBack = state.uploadingSide === "back";
|
|
783
811
|
return /* @__PURE__ */ u("div", {
|
|
784
812
|
class: "IncodeManualUploadTab",
|
|
785
|
-
children: [
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
813
|
+
children: [
|
|
814
|
+
/* @__PURE__ */ u(UploadButton, {
|
|
815
|
+
icon: /* @__PURE__ */ u(IdFrontIcon, {}),
|
|
816
|
+
label: slotLabel("front", isUploadingFront, state.frontUploaded),
|
|
817
|
+
uploaded: state.frontUploaded,
|
|
818
|
+
uploading: isUploadingFront,
|
|
819
|
+
testId: "manual-upload-front",
|
|
820
|
+
onFile: (file) => manager.manualUploadSelectFile("front", file),
|
|
821
|
+
...slotErrorProps("front")
|
|
822
|
+
}),
|
|
823
|
+
slotError("front"),
|
|
824
|
+
state.showBackSlot && /* @__PURE__ */ u(k, { children: [/* @__PURE__ */ u(UploadButton, {
|
|
825
|
+
icon: /* @__PURE__ */ u(IdBackIcon, {}),
|
|
826
|
+
label: slotLabel("back", isUploadingBack, state.backUploaded),
|
|
827
|
+
uploaded: state.backUploaded,
|
|
828
|
+
uploading: isUploadingBack,
|
|
829
|
+
testId: "manual-upload-back",
|
|
830
|
+
onFile: (file) => manager.manualUploadSelectFile("back", file),
|
|
831
|
+
...slotErrorProps("back")
|
|
832
|
+
}), slotError("back")] })
|
|
833
|
+
]
|
|
802
834
|
});
|
|
803
835
|
};
|
|
804
836
|
//#endregion
|
|
@@ -879,13 +911,7 @@ var ManualUpload = ({ manager, state }) => {
|
|
|
879
911
|
manager,
|
|
880
912
|
state,
|
|
881
913
|
errorMessageId
|
|
882
|
-
}) : null, state.errorKey ? /* @__PURE__ */ u(
|
|
883
|
-
id: errorMessageId,
|
|
884
|
-
class: "IncodeManualUploadError",
|
|
885
|
-
role: "alert",
|
|
886
|
-
"data-testid": "manual-upload-error",
|
|
887
|
-
children: [/* @__PURE__ */ u(ErrorIcon, { size: 16 }), /* @__PURE__ */ u("p", { children: t(state.errorKey) })]
|
|
888
|
-
}) : null]
|
|
914
|
+
}) : null, state.errorKey && !state.errorSide ? /* @__PURE__ */ u(ManualUploadError, { errorKey: state.errorKey }) : null]
|
|
889
915
|
}), /* @__PURE__ */ u("div", {
|
|
890
916
|
class: "IncodeManualUploadFooter",
|
|
891
917
|
children: [/* @__PURE__ */ u("ul", {
|
|
@@ -907,13 +933,13 @@ var started = false;
|
|
|
907
933
|
function preloadIdTutorialAssets() {
|
|
908
934
|
if (started) return;
|
|
909
935
|
started = true;
|
|
910
|
-
import("../id-tutorial-
|
|
911
|
-
import("../back-tutorial-
|
|
912
|
-
import("../passport-tutorial-
|
|
936
|
+
import("../id-tutorial-DwO90SAm.js");
|
|
937
|
+
import("../back-tutorial-cI_4VHmE.js");
|
|
938
|
+
import("../passport-tutorial-D9JNsMsM.js");
|
|
913
939
|
}
|
|
914
940
|
//#endregion
|
|
915
941
|
//#region src/modules/id/id.tsx
|
|
916
|
-
var MandatoryConsent = z(() => import("../mandatoryConsent-
|
|
942
|
+
var MandatoryConsent = z(() => import("../mandatoryConsent-D0GTKu-H.js").then((module) => ({ default: module.MandatoryConsent })));
|
|
917
943
|
var IdContent = ({ config, manager: externalManager, onFinish, onError }) => {
|
|
918
944
|
usePreloadDisplayFont();
|
|
919
945
|
const { t } = useTranslation();
|
|
@@ -931,7 +957,10 @@ var IdContent = ({ config, manager: externalManager, onFinish, onError }) => {
|
|
|
931
957
|
onError
|
|
932
958
|
});
|
|
933
959
|
if (state.status === "idle") return /* @__PURE__ */ u(TransitionSpinner, { hideText: true });
|
|
934
|
-
if (state.status === "loading") return /* @__PURE__ */ u(TransitionSpinner, { spinnerConfig: {
|
|
960
|
+
if (state.status === "loading") return /* @__PURE__ */ u(TransitionSpinner, { spinnerConfig: {
|
|
961
|
+
title: t("loadingCircle.holdOn"),
|
|
962
|
+
subtitle: t("loadingCircle.preparingCamera")
|
|
963
|
+
} });
|
|
935
964
|
if (state.status === "chooser") return /* @__PURE__ */ u(Chooser, {
|
|
936
965
|
manager,
|
|
937
966
|
state
|
|
@@ -969,7 +998,8 @@ var IdContent = ({ config, manager: externalManager, onFinish, onError }) => {
|
|
|
969
998
|
if (state.status === "processing") return /* @__PURE__ */ u(Processing, {});
|
|
970
999
|
if (state.status === "expired") return /* @__PURE__ */ u(IdExpired, {
|
|
971
1000
|
manager,
|
|
972
|
-
attemptsRemaining: state.attemptsRemaining
|
|
1001
|
+
attemptsRemaining: state.attemptsRemaining,
|
|
1002
|
+
isBackSide: state.currentMode === "back"
|
|
973
1003
|
});
|
|
974
1004
|
if (state.status === "expiredExhausted") return /* @__PURE__ */ u(IdNoAttempts, { manager });
|
|
975
1005
|
if (state.status === "finished" || state.status === "closed") return null;
|
package/dist/id/styles.css
CHANGED
|
@@ -110,10 +110,6 @@
|
|
|
110
110
|
margin-inline: auto;
|
|
111
111
|
}
|
|
112
112
|
|
|
113
|
-
.IncodeIdTutorial {
|
|
114
|
-
--brand-color: var(--surface-brand-500);
|
|
115
|
-
}
|
|
116
|
-
|
|
117
113
|
.IncodeIdTutorial .IncodePageTitleContainer {
|
|
118
114
|
padding-block: var(--spacing-16, var(--spacing-16, 16px));
|
|
119
115
|
}
|
|
@@ -126,10 +122,6 @@
|
|
|
126
122
|
padding: var(--spacing-0, var(--spacing-none, 0px));
|
|
127
123
|
}
|
|
128
124
|
|
|
129
|
-
.IncodeIdTutorial.IncodeIdTutorialId .IncodeBaseTutorialAnimation svg > g > g > g:nth-child(2) > g:nth-child(5) > g > g > g:nth-child(3) > g > path, .IncodeIdTutorial.IncodeIdTutorialId .IncodeBaseTutorialAnimation svg > g > g > g:first-child > g > path, .IncodeIdTutorial.IncodeIdTutorialPassport .IncodeBaseTutorialAnimation svg > g > g:nth-child(2) > g:nth-child(2) > g:nth-child(2) > g:nth-child(2) > g > g > g > g:nth-child(4) > g > path, .IncodeIdTutorial.IncodeIdTutorialPassport .IncodeBaseTutorialAnimation svg > g > g:first-child > g > path {
|
|
130
|
-
fill: var(--brand-color);
|
|
131
|
-
}
|
|
132
|
-
|
|
133
125
|
.IncodeFlipAnimation {
|
|
134
126
|
background-color: var(--color-surface-neutral-0, var(--surface-neutral-0));
|
|
135
127
|
height: 100%;
|
|
@@ -269,7 +261,7 @@
|
|
|
269
261
|
}
|
|
270
262
|
|
|
271
263
|
.IncodeCaptureFrame.IncodeCaptureFrameCapturing, .IncodeCaptureFrame.IncodeCaptureFrameFocus {
|
|
272
|
-
--frame-border-color: var(--border-
|
|
264
|
+
--frame-border-color: var(--border-brand-500);
|
|
273
265
|
}
|
|
274
266
|
|
|
275
267
|
.IncodeCaptureFrame.IncodeCaptureFrameAnalyzing, .IncodeCaptureFrame.IncodeCaptureFrameSuccess {
|
package/dist/id-ocr/styles.css
CHANGED
|
@@ -25,20 +25,30 @@
|
|
|
25
25
|
.IncodeIdOcrPage .IncodeIdOcrForm {
|
|
26
26
|
margin-top: var(--spacing-32, var(--spacing-32, 32px));
|
|
27
27
|
height: 100%;
|
|
28
|
+
min-height: var(--spacing-0, var(--spacing-none, 0px));
|
|
29
|
+
flex-direction: column;
|
|
30
|
+
justify-content: flex-start;
|
|
31
|
+
align-items: center;
|
|
32
|
+
width: 100%;
|
|
33
|
+
display: flex;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.IncodeIdOcrPage .IncodeIdOcrFields {
|
|
28
37
|
min-height: var(--spacing-0, var(--spacing-none, 0px));
|
|
29
38
|
justify-content: flex-start;
|
|
30
39
|
align-items: center;
|
|
31
40
|
gap: var(--spacing-16, var(--spacing-16, 16px));
|
|
32
41
|
flex-direction: column;
|
|
42
|
+
flex: 1;
|
|
33
43
|
width: 100%;
|
|
34
44
|
display: flex;
|
|
35
45
|
overflow-y: auto;
|
|
36
46
|
}
|
|
37
47
|
|
|
38
48
|
.IncodeIdOcrPage .IncodeIdOcrButton {
|
|
39
|
-
bottom: var(--spacing-0, var(--spacing-none, 0px));
|
|
40
49
|
width: 100%;
|
|
41
|
-
|
|
50
|
+
padding-top: var(--spacing-16, var(--spacing-16, 16px));
|
|
51
|
+
flex-shrink: 0;
|
|
42
52
|
}
|
|
43
53
|
|
|
44
54
|
.IncodeIdOcrPage .IncodeIdOcrRadioGroup {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { v as u } from "../vendor-preact-DThS2ZQ_.js";
|
|
2
|
-
import { c as
|
|
3
|
-
import { t as IncodeComponent } from "../incodeComponent-
|
|
4
|
-
import { t as Spinner } from "../spinner-
|
|
5
|
-
import { t as ExpiredId } from "../expiredId-
|
|
6
|
-
import { t as registerIncodeModuleElement } from "../incodeModule-
|
|
2
|
+
import { c as useModuleTerminalCallbacks, u as useManager } from "../hooks-CNu7o-v8.js";
|
|
3
|
+
import { t as IncodeComponent } from "../incodeComponent-CfzJGETt.js";
|
|
4
|
+
import { t as Spinner } from "../spinner-BMeIEK1d.js";
|
|
5
|
+
import { t as ExpiredId } from "../expiredId-BZXLrLk-.js";
|
|
6
|
+
import { t as registerIncodeModuleElement } from "../incodeModule-B-4_3JrK.js";
|
|
7
7
|
import { createIdVerificationManager } from "@incodetech/core/id-verification";
|
|
8
8
|
//#region src/modules/id-verification/id-verification.tsx
|
|
9
9
|
var IdVerificationContent = ({ config, onFinish }) => {
|
|
@@ -1,22 +1,33 @@
|
|
|
1
|
-
import { n as useTranslation } from "./i18n-
|
|
1
|
+
import { n as useTranslation } from "./i18n-CU4xq8qC.js";
|
|
2
2
|
import { d as T, v as u } from "./vendor-preact-DThS2ZQ_.js";
|
|
3
|
-
import { c as
|
|
4
|
-
import { t as IncodeComponent } from "./incodeComponent-
|
|
3
|
+
import { c as useModuleTerminalCallbacks, u as useManager } from "./hooks-CNu7o-v8.js";
|
|
4
|
+
import { t as IncodeComponent } from "./incodeComponent-CfzJGETt.js";
|
|
5
5
|
import { t as Page } from "./page-DidH_RkX.js";
|
|
6
|
-
import "./extensibility-
|
|
7
|
-
import { t as Button } from "./button-
|
|
8
|
-
import { t as VerificationResult } from "./verificationResult-
|
|
6
|
+
import "./extensibility-7sRIN0JC.js";
|
|
7
|
+
import { t as Button } from "./button-Dz6AsbmF.js";
|
|
8
|
+
import { t as VerificationResult } from "./verificationResult-BWWkmeiA.js";
|
|
9
9
|
import { t as InputComposed } from "./inputComposed-C1R2LAa3.js";
|
|
10
|
-
import { t as RadioGroupComposed } from "./radioGroupComposed-
|
|
10
|
+
import { t as RadioGroupComposed } from "./radioGroupComposed-DuQxslB2.js";
|
|
11
11
|
import { t as DateInputComposed } from "./dateInputComposed-DuaofcBl.js";
|
|
12
|
-
import { t as registerIncodeModuleElement } from "./incodeModule-
|
|
13
|
-
import { n as getRequiredHintMode, t as getFieldHint } from "./requiredLabelHint-
|
|
12
|
+
import { t as registerIncodeModuleElement } from "./incodeModule-B-4_3JrK.js";
|
|
13
|
+
import { n as getRequiredHintMode, t as getFieldHint } from "./requiredLabelHint-D0RhuMed.js";
|
|
14
14
|
import { createIdOcrManager, getOcrFields } from "@incodetech/core/id-ocr";
|
|
15
15
|
//#region src/modules/id-ocr/idOcrForm.tsx
|
|
16
16
|
var TEXT_FIELD_COMPONENTS = {
|
|
17
17
|
text: InputComposed,
|
|
18
18
|
date: DateInputComposed
|
|
19
19
|
};
|
|
20
|
+
/**
|
|
21
|
+
* `autocomplete` tokens for personal-info fields (WCAG 2.2 SC 1.3.5 Identify
|
|
22
|
+
* Input Purpose). Fields without a standard token (e.g. document number, sex)
|
|
23
|
+
* are intentionally omitted.
|
|
24
|
+
*/
|
|
25
|
+
var AUTOCOMPLETE_TOKENS = {
|
|
26
|
+
name: "name",
|
|
27
|
+
birthDate: "bday",
|
|
28
|
+
issuingCountry: "country-name",
|
|
29
|
+
address: "street-address"
|
|
30
|
+
};
|
|
20
31
|
var IdOcrForm = ({ fields, data, validationErrors, isReadonly, onChange, onBlur, onContinue }) => {
|
|
21
32
|
const { t } = useTranslation();
|
|
22
33
|
const hasValidationErrors = validationErrors && Object.keys(validationErrors).length > 0;
|
|
@@ -56,6 +67,7 @@ var IdOcrForm = ({ fields, data, validationErrors, isReadonly, onChange, onBlur,
|
|
|
56
67
|
value,
|
|
57
68
|
disabled: isReadonly,
|
|
58
69
|
required: isFieldRequired,
|
|
70
|
+
autocomplete: AUTOCOMPLETE_TOKENS[field.key],
|
|
59
71
|
error: fieldError,
|
|
60
72
|
showErrorIcon: !!fieldError,
|
|
61
73
|
onInput: (e) => onChange(field.key, e.target.value),
|
|
@@ -65,11 +77,16 @@ var IdOcrForm = ({ fields, data, validationErrors, isReadonly, onChange, onBlur,
|
|
|
65
77
|
};
|
|
66
78
|
return /* @__PURE__ */ u("div", {
|
|
67
79
|
className: "IncodeIdOcrForm",
|
|
68
|
-
children: [
|
|
80
|
+
children: [/* @__PURE__ */ u("div", {
|
|
81
|
+
className: "IncodeIdOcrFields",
|
|
82
|
+
tabIndex: isReadonly ? 0 : void 0,
|
|
83
|
+
children: visibleFields.map(renderField)
|
|
84
|
+
}), /* @__PURE__ */ u("div", {
|
|
69
85
|
className: "IncodeIdOcrButton",
|
|
70
86
|
children: /* @__PURE__ */ u(Button, {
|
|
71
87
|
onClick: onContinue,
|
|
72
88
|
disabled: hasValidationErrors,
|
|
89
|
+
"data-testid": "id-ocr-continue",
|
|
73
90
|
children: t("common.continue")
|
|
74
91
|
})
|
|
75
92
|
})]
|
|
@@ -77,9 +94,9 @@ var IdOcrForm = ({ fields, data, validationErrors, isReadonly, onChange, onBlur,
|
|
|
77
94
|
};
|
|
78
95
|
//#endregion
|
|
79
96
|
//#region src/modules/id-ocr/idOcr.tsx
|
|
80
|
-
var IdOcrContent = ({ config, onFinish }) => {
|
|
97
|
+
var IdOcrContent = ({ config, manager: externalManager, onFinish }) => {
|
|
81
98
|
const { t } = useTranslation();
|
|
82
|
-
const [state, manager] = useManager(() => createIdOcrManager({ config }));
|
|
99
|
+
const [state, manager] = useManager(() => externalManager ?? createIdOcrManager({ config }), { manageLifecycle: !externalManager });
|
|
83
100
|
useModuleTerminalCallbacks({
|
|
84
101
|
status: state.status === "finished" ? "finished" : "loading",
|
|
85
102
|
onFinish
|
|
@@ -114,8 +131,9 @@ var IdOcrContent = ({ config, onFinish }) => {
|
|
|
114
131
|
});
|
|
115
132
|
return null;
|
|
116
133
|
};
|
|
117
|
-
var IdOcr = ({ config, onFinish }) => /* @__PURE__ */ u(IncodeComponent, { children: config ? /* @__PURE__ */ u(IdOcrContent, {
|
|
134
|
+
var IdOcr = ({ config, manager, onFinish }) => /* @__PURE__ */ u(IncodeComponent, { children: config ? /* @__PURE__ */ u(IdOcrContent, {
|
|
118
135
|
config,
|
|
136
|
+
manager,
|
|
119
137
|
onFinish
|
|
120
138
|
}) : null });
|
|
121
139
|
registerIncodeModuleElement(IdOcr, "incode-id-ocr");
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { n as useTranslation } from "../i18n-
|
|
1
|
+
import { n as useTranslation } from "../i18n-CU4xq8qC.js";
|
|
2
2
|
import { _ as y, v as u } from "../vendor-preact-DThS2ZQ_.js";
|
|
3
|
-
import { c as
|
|
4
|
-
import { t as IncodeComponent } from "../incodeComponent-
|
|
3
|
+
import { c as useModuleTerminalCallbacks, u as useManager } from "../hooks-CNu7o-v8.js";
|
|
4
|
+
import { t as IncodeComponent } from "../incodeComponent-CfzJGETt.js";
|
|
5
5
|
import { t as Page } from "../page-DidH_RkX.js";
|
|
6
|
-
import { t as Spinner } from "../spinner-
|
|
7
|
-
import { t as Button } from "../button-
|
|
8
|
-
import { t as registerIncodeModuleElement } from "../incodeModule-
|
|
6
|
+
import { t as Spinner } from "../spinner-BMeIEK1d.js";
|
|
7
|
+
import { t as Button } from "../button-Dz6AsbmF.js";
|
|
8
|
+
import { t as registerIncodeModuleElement } from "../incodeModule-B-4_3JrK.js";
|
|
9
9
|
import { SCAN_NEW_DOCUMENT, createIdentityReuseManager } from "@incodetech/core/identity-reuse";
|
|
10
10
|
//#region src/modules/identity-reuse/identity-reuse.tsx
|
|
11
11
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as useTranslation } from "./i18n-
|
|
1
|
+
import { n as useTranslation } from "./i18n-CU4xq8qC.js";
|
|
2
2
|
import { _ as y, l as A, p as d, r as $, v as u } from "./vendor-preact-DThS2ZQ_.js";
|
|
3
|
-
import {
|
|
3
|
+
import { l as useScreenOrientation } from "./hooks-CNu7o-v8.js";
|
|
4
4
|
import { isIPad } from "@incodetech/core/device";
|
|
5
5
|
//#region src/shared/icons/rotate-icon.svg
|
|
6
6
|
var rotate_icon_default = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='90'%20height='90'%20viewBox='0%200%2090%2090'%3e%3cg%20fill='%2320263D'%3e%3cpath%20d='M84.12%2027.54l-2.58-2.58L65.036%208.456l-2.58-2.58c-3.127-3.127-8.58-2.764-12.157.81L6.69%2050.306c-3.574%203.574-3.938%209.027-.81%2012.158l21.66%2021.66c3.128%203.127%208.58%202.764%2012.157-.81l43.617-43.616c3.574-3.578%203.937-9.03.806-12.158zm-5.524%208.617l-42.439%2042.44c-1.3%201.3-3.28%201.432-4.42.296l-20.63-20.63c-1.14-1.14-1.008-3.12.297-4.42l42.438-42.44c1.302-1.3%203.282-1.432%204.422-.296l1.031%201.032c1.14%201.14%201.009%203.12-.296%204.421-1.302%201.301-1.433%203.281-.297%204.421L69.02%2031.297c1.14%201.14%203.12%201.01%204.421-.296%201.301-1.301%203.281-1.432%204.421-.296l1.031%201.031c1.137%201.14%201.005%203.12-.296%204.421zM51.885%2090a3.135%203.135%200%2001-2.22-5.351l8.925-8.925a3.138%203.138%200%20014.646.233l3.308%204.046c10.114-5.374%2017.081-15.994%2017.178-28.14a3.136%203.136%200%20013.136-3.113h.026a3.14%203.14%200%20013.112%203.161C89.835%2072.746%2072.746%2089.835%2051.911%2090h-.026zM38.115%200a3.135%203.135%200%20012.22%205.351l-8.925%208.925a3.125%203.125%200%2001-2.378.915%203.138%203.138%200%2001-2.272-1.147l-3.308-4.046C13.34%2015.37%206.373%2025.99%206.274%2038.138a3.14%203.14%200%2001-3.139%203.112h-.026a3.139%203.139%200%2001-3.11-3.161C.166%2017.254%2017.255.165%2038.09%200h.026z'/%3e%3c/g%3e%3c/svg%3e";
|
package/dist/index.es.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { a as createI18n, i as setI18nInstance } from "./i18n-
|
|
1
|
+
import { a as createI18n, i as setI18nInstance } from "./i18n-CU4xq8qC.js";
|
|
2
2
|
import { t as setUiConfig } from "./uiConfig-D2_wawvr.js";
|
|
3
3
|
import { DEFAULT_WASM_VERSION } from "@incodetech/core/wasm";
|
|
4
4
|
import { setup as setup$1 } from "@incodetech/core";
|
|
5
5
|
//#region src/setup.ts
|
|
6
|
-
async function setup({ apiURL, token, customHeaders, timeout, wasm, ipLookup, devMode, i18n, uiConfig }) {
|
|
6
|
+
async function setup({ apiURL, token, customHeaders, timeout, wasm, ipLookup, fingerprint, devMode, i18n, uiConfig }) {
|
|
7
7
|
if (uiConfig) setUiConfig(uiConfig);
|
|
8
8
|
await setup$1({
|
|
9
9
|
apiURL,
|
|
@@ -12,6 +12,7 @@ async function setup({ apiURL, token, customHeaders, timeout, wasm, ipLookup, de
|
|
|
12
12
|
timeout,
|
|
13
13
|
wasm,
|
|
14
14
|
ipLookup,
|
|
15
|
+
fingerprint,
|
|
15
16
|
devMode
|
|
16
17
|
});
|
|
17
18
|
setI18nInstance(createI18n(i18n));
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { n as useTranslation } from "./i18n-
|
|
1
|
+
import { n as useTranslation } from "./i18n-CU4xq8qC.js";
|
|
2
2
|
import { _ as y, l as A, v as u } from "./vendor-preact-DThS2ZQ_.js";
|
|
3
|
-
import {
|
|
4
|
-
import { t as IncodeComponent } from "./incodeComponent-
|
|
3
|
+
import { c as useModuleTerminalCallbacks, s as isTerminalModuleState, u as useManager } from "./hooks-CNu7o-v8.js";
|
|
4
|
+
import { t as IncodeComponent } from "./incodeComponent-CfzJGETt.js";
|
|
5
5
|
import { t as Page } from "./page-DidH_RkX.js";
|
|
6
|
-
import { t as TransitionSpinner } from "./transitionSpinner-
|
|
7
|
-
import { t as Button } from "./button-
|
|
6
|
+
import { t as TransitionSpinner } from "./transitionSpinner-CuNCqHNi.js";
|
|
7
|
+
import { t as Button } from "./button-Dz6AsbmF.js";
|
|
8
8
|
import { t as Checkbox } from "./checkbox-1wUHSoaK.js";
|
|
9
|
-
import { t as registerIncodeModuleElement } from "./incodeModule-
|
|
10
|
-
import { t as RichText } from "./richText-
|
|
9
|
+
import { t as registerIncodeModuleElement } from "./incodeModule-B-4_3JrK.js";
|
|
10
|
+
import { t as RichText } from "./richText-CB1fmegc.js";
|
|
11
11
|
import { createMandatoryConsentManager } from "@incodetech/core/mandatory-consent";
|
|
12
12
|
//#region src/modules/mandatory-consent/mandatoryConsent.tsx
|
|
13
13
|
var stopLinkPropagation = (event) => {
|