@incodetech/web 0.0.0-dev-20260813-ad5ea9e1 → 0.0.0-dev-20260813-c65eff54
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/{customFields-Om1nY5wK.js → customFields-BrWlGrZ9.js} +41 -8
- package/dist/flow/flow.es.js +1 -1
- package/dist/id/id.es.js +1 -1
- package/dist/{mandatoryConsent-pblMVUjs.js → mandatoryConsent-B7KFPn4W.js} +2 -0
- package/dist/{useModuleLoader-Bj_qdihU.js → useModuleLoader-Bl4AhWD8.js} +3 -3
- package/dist/workflow/workflow.es.js +1 -1
- package/package.json +2 -2
|
@@ -4,6 +4,7 @@ import { K as InputComposed, P as DateInputComposed, V as Checkbox, X as StatusP
|
|
|
4
4
|
import { n as LoadingIcon, t as Spacer } from "./spacer-Bev-wMBC.js";
|
|
5
5
|
import { k as Button, u as SuccessIcon } from "./dropdownComposed-CH8FoLKA.js";
|
|
6
6
|
import { t as registerIncodeModuleElement } from "./incodeModule-CPafHixS.js";
|
|
7
|
+
import { n as getRequiredHintMode, t as getFieldHint } from "./requiredLabelHint-BWCuo0he.js";
|
|
7
8
|
import { createCustomFieldsManager } from "@incodetech/core/custom-fields";
|
|
8
9
|
//#region src/modules/custom-fields/customFields.tsx
|
|
9
10
|
var INPUT_TYPE_MAP = {
|
|
@@ -12,14 +13,20 @@ var INPUT_TYPE_MAP = {
|
|
|
12
13
|
STRING: "text"
|
|
13
14
|
};
|
|
14
15
|
var INPUT_STEP_MAP = { DOUBLE: "any" };
|
|
15
|
-
var DateFieldInput = ({ field, isDisabled, onChange }) => {
|
|
16
|
+
var DateFieldInput = ({ error, field, isDisabled, labelHint, required, onChange }) => {
|
|
16
17
|
const [dateValue, setDateValue] = d("");
|
|
18
|
+
const id = `custom-field-${field.name}`;
|
|
17
19
|
return /* @__PURE__ */ u("div", {
|
|
18
20
|
class: "IncodeCustomFieldsField",
|
|
19
21
|
children: /* @__PURE__ */ u(DateInputComposed, {
|
|
20
|
-
id
|
|
22
|
+
id,
|
|
21
23
|
name: field.name,
|
|
22
24
|
label: field.label,
|
|
25
|
+
labelHint,
|
|
26
|
+
"data-testid": id,
|
|
27
|
+
error,
|
|
28
|
+
showErrorIcon: !!error,
|
|
29
|
+
required,
|
|
23
30
|
disabled: isDisabled,
|
|
24
31
|
value: dateValue,
|
|
25
32
|
onInput: (e) => {
|
|
@@ -30,7 +37,7 @@ var DateFieldInput = ({ field, isDisabled, onChange }) => {
|
|
|
30
37
|
})
|
|
31
38
|
});
|
|
32
39
|
};
|
|
33
|
-
var CustomFieldInput = ({ field, isDisabled, onChange }) => {
|
|
40
|
+
var CustomFieldInput = ({ error, field, isDisabled, labelHint, required, onChange }) => {
|
|
34
41
|
const id = `custom-field-${field.name}`;
|
|
35
42
|
if (field.type === "BOOLEAN") return /* @__PURE__ */ u("div", {
|
|
36
43
|
class: "IncodeCustomFieldsField",
|
|
@@ -38,13 +45,20 @@ var CustomFieldInput = ({ field, isDisabled, onChange }) => {
|
|
|
38
45
|
id,
|
|
39
46
|
name: field.name,
|
|
40
47
|
label: field.label,
|
|
48
|
+
labelHint,
|
|
49
|
+
"data-testid": id,
|
|
50
|
+
error,
|
|
51
|
+
required,
|
|
41
52
|
disabled: isDisabled,
|
|
42
53
|
onChange: (e) => onChange(field.name, e.target.checked)
|
|
43
54
|
})
|
|
44
55
|
});
|
|
45
56
|
if (field.type === "DATE") return /* @__PURE__ */ u(DateFieldInput, {
|
|
57
|
+
error,
|
|
46
58
|
field,
|
|
47
59
|
isDisabled,
|
|
60
|
+
labelHint,
|
|
61
|
+
required,
|
|
48
62
|
onChange
|
|
49
63
|
});
|
|
50
64
|
return /* @__PURE__ */ u("div", {
|
|
@@ -53,8 +67,13 @@ var CustomFieldInput = ({ field, isDisabled, onChange }) => {
|
|
|
53
67
|
id,
|
|
54
68
|
name: field.name,
|
|
55
69
|
label: field.label,
|
|
70
|
+
labelHint,
|
|
71
|
+
"data-testid": id,
|
|
72
|
+
error,
|
|
73
|
+
showErrorIcon: !!error,
|
|
56
74
|
type: INPUT_TYPE_MAP[field.type] ?? "text",
|
|
57
75
|
step: INPUT_STEP_MAP[field.type],
|
|
76
|
+
required,
|
|
58
77
|
disabled: isDisabled,
|
|
59
78
|
onInput: (e) => onChange(field.name, e.target.value)
|
|
60
79
|
})
|
|
@@ -74,6 +93,7 @@ var CustomFieldsContent = ({ config, manager: externalManager, onFinish, onError
|
|
|
74
93
|
status: state.status === "finished" ? "finished" : "loading",
|
|
75
94
|
onFinish
|
|
76
95
|
});
|
|
96
|
+
if (state.status === "idle") return null;
|
|
77
97
|
if (state.status === "success") return /* @__PURE__ */ u(StatusPage, {
|
|
78
98
|
variant: "success",
|
|
79
99
|
icon: /* @__PURE__ */ u(SuccessIcon, { size: 64 }),
|
|
@@ -90,6 +110,7 @@ var CustomFieldsContent = ({ config, manager: externalManager, onFinish, onError
|
|
|
90
110
|
});
|
|
91
111
|
const canSubmit = state.status === "inputting" ? state.canSubmit : false;
|
|
92
112
|
const customFields = state.status === "inputting" ? state.customFields : [];
|
|
113
|
+
const requiredHintMode = getRequiredHintMode(customFields.map((field) => field.type !== "BOOLEAN"));
|
|
93
114
|
const handleChange = (name, value) => {
|
|
94
115
|
manager.setField(name, value);
|
|
95
116
|
};
|
|
@@ -97,23 +118,35 @@ var CustomFieldsContent = ({ config, manager: externalManager, onFinish, onError
|
|
|
97
118
|
className: "IncodeCustomFieldsPage",
|
|
98
119
|
title,
|
|
99
120
|
hideFooterBranding: true,
|
|
121
|
+
"data-testid": "custom-fields-page",
|
|
100
122
|
children: /* @__PURE__ */ u("form", {
|
|
101
123
|
class: "IncodeCustomFieldsForm",
|
|
124
|
+
"data-testid": "custom-fields-form",
|
|
125
|
+
noValidate: true,
|
|
102
126
|
onSubmit: (e) => {
|
|
103
127
|
e.preventDefault();
|
|
104
128
|
manager.submit();
|
|
105
129
|
},
|
|
106
130
|
autoComplete: "off",
|
|
107
131
|
children: [
|
|
108
|
-
customFields.map((field) =>
|
|
109
|
-
field
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
132
|
+
customFields.map((field) => {
|
|
133
|
+
const required = field.type !== "BOOLEAN";
|
|
134
|
+
const hint = getFieldHint(requiredHintMode, required);
|
|
135
|
+
const errorKey = state.validationErrors?.[field.name];
|
|
136
|
+
return /* @__PURE__ */ u(CustomFieldInput, {
|
|
137
|
+
error: errorKey ? t(errorKey, { fieldName: field.label }) : void 0,
|
|
138
|
+
field,
|
|
139
|
+
isDisabled: false,
|
|
140
|
+
labelHint: hint ? t(`forms.label.${hint}`) : void 0,
|
|
141
|
+
required,
|
|
142
|
+
onChange: handleChange
|
|
143
|
+
}, field.name);
|
|
144
|
+
}),
|
|
113
145
|
/* @__PURE__ */ u(Spacer, {}),
|
|
114
146
|
/* @__PURE__ */ u(Button, {
|
|
115
147
|
type: "submit",
|
|
116
148
|
disabled: !canSubmit,
|
|
149
|
+
"data-testid": "custom-fields-submit",
|
|
117
150
|
children: t("customFields.continue")
|
|
118
151
|
})
|
|
119
152
|
]
|
package/dist/flow/flow.es.js
CHANGED
|
@@ -3,7 +3,7 @@ import { _ as y, c as z, d as T, l as A, o as P, p as d, v as u } from "../vendo
|
|
|
3
3
|
import { X as StatusPage, dt as TransitionSpinner, ot as ResolvedConfigProvider, st as TerminalErrorPage, tt as IncodeComponent, yt as useManager } from "../extensibility-li3u8bJP.js";
|
|
4
4
|
import { O as ErrorIcon } from "../dropdownComposed-CH8FoLKA.js";
|
|
5
5
|
import { t as registerIncodeModuleElement } from "../incodeModule-CPafHixS.js";
|
|
6
|
-
import { _ as warmupWasmIfNeeded, a as resolveApiKey, c as HEADLESS_FLOW_MODULE_KEYS, d as fetchTheme, f as initializeFlowManager, h as preloadRedirectToMobile, l as LAZY_UI_MODULES, m as preloadHomeScreen, n as useModulePreloader, o as extractIncodeStatus, p as preloadFirstModule, r as usePrefetchNextModule, s as UnsupportedModule, t as useModuleLoader, u as createFlowManager, v as isDesktopOrEmulated } from "../useModuleLoader-
|
|
6
|
+
import { _ as warmupWasmIfNeeded, a as resolveApiKey, c as HEADLESS_FLOW_MODULE_KEYS, d as fetchTheme, f as initializeFlowManager, h as preloadRedirectToMobile, l as LAZY_UI_MODULES, m as preloadHomeScreen, n as useModulePreloader, o as extractIncodeStatus, p as preloadFirstModule, r as usePrefetchNextModule, s as UnsupportedModule, t as useModuleLoader, u as createFlowManager, v as isDesktopOrEmulated } from "../useModuleLoader-Bl4AhWD8.js";
|
|
7
7
|
import { getRequiredWasmPipelines } from "@incodetech/core/flow";
|
|
8
8
|
import { bootstrapSession, refreshQrUrlUuid } from "@incodetech/core/session";
|
|
9
9
|
//#region src/shared/processing/useDelayedFlag.ts
|
package/dist/id/id.es.js
CHANGED
|
@@ -1103,7 +1103,7 @@ function preloadIdTutorialAssets() {
|
|
|
1103
1103
|
}
|
|
1104
1104
|
//#endregion
|
|
1105
1105
|
//#region src/modules/id/id.tsx
|
|
1106
|
-
var MandatoryConsent = z(() => import("../mandatoryConsent-
|
|
1106
|
+
var MandatoryConsent = z(() => import("../mandatoryConsent-B7KFPn4W.js").then((module) => ({ default: module.MandatoryConsent })));
|
|
1107
1107
|
var IdContent = ({ config, manager: externalManager, onFinish, onError }) => {
|
|
1108
1108
|
usePreloadDisplayFont();
|
|
1109
1109
|
const { t } = useTranslation();
|
|
@@ -48,6 +48,7 @@ var MandatoryConsentContent = ({ config, manager: externalManager, onFinish, onE
|
|
|
48
48
|
class: "IncodeConsentCheckboxList",
|
|
49
49
|
children: /* @__PURE__ */ u(Checkbox, {
|
|
50
50
|
id: "mandatory-consent-checkbox",
|
|
51
|
+
"data-testid": "mandatory-consent-checkbox",
|
|
51
52
|
class: "IncodeConsentCheckbox",
|
|
52
53
|
checked: state.isSigned,
|
|
53
54
|
required: true,
|
|
@@ -82,6 +83,7 @@ var MandatoryConsentContent = ({ config, manager: externalManager, onFinish, onE
|
|
|
82
83
|
children: t("biometricConsent.button.continue")
|
|
83
84
|
}), isMandatoryConsent && /* @__PURE__ */ u(Button, {
|
|
84
85
|
variant: "link",
|
|
86
|
+
"data-testid": "mandatory-consent-cancel",
|
|
85
87
|
onClick: () => manager.cancel(),
|
|
86
88
|
children: t("biometricConsent.button.cancel")
|
|
87
89
|
})]
|
|
@@ -88,12 +88,12 @@ var LAZY_UI_MODULES = {
|
|
|
88
88
|
DOCUMENT_CAPTURE: () => import("./documentCapture-otFa-W4b.js").then((m) => m.DocumentCapture),
|
|
89
89
|
ADDRESS: () => import("./documentCapture-otFa-W4b.js").then((m) => m.DocumentCapture),
|
|
90
90
|
COMBINED_CONSENT: () => import("./consent/consent.es.js").then((m) => m.Consent),
|
|
91
|
-
MANDATORY_CONSENT: () => import("./mandatoryConsent-
|
|
92
|
-
ML_CONSENT: () => import("./mandatoryConsent-
|
|
91
|
+
MANDATORY_CONSENT: () => import("./mandatoryConsent-B7KFPn4W.js").then((m) => m.MandatoryConsent),
|
|
92
|
+
ML_CONSENT: () => import("./mandatoryConsent-B7KFPn4W.js").then((m) => m.MandatoryConsent),
|
|
93
93
|
SIGNATURE: () => import("./signature/signature.es.js").then((m) => m.Signature),
|
|
94
94
|
ID_OCR: () => import("./idOcr-BLQhHZbS.js").then((m) => m.IdOcr),
|
|
95
95
|
ANTIFRAUD: () => import("./antifraud/antifraud.es.js").then((m) => m.Antifraud),
|
|
96
|
-
CUSTOM_FIELDS: () => import("./customFields-
|
|
96
|
+
CUSTOM_FIELDS: () => import("./customFields-BrWlGrZ9.js").then((m) => m.CustomFields),
|
|
97
97
|
WATCHLIST: () => import("./watchlist/watchlist.es.js").then((m) => m.Watchlist),
|
|
98
98
|
WATCHLIST_BUSINESS: () => import("./watchlistForBusiness-CqVbOd4P.js").then((m) => m.WatchlistForBusiness),
|
|
99
99
|
INCODE_WATCHLIST: () => import("./customWatchlist-Dh3A_Nmm.js").then((m) => m.CustomWatchlist),
|
|
@@ -3,7 +3,7 @@ import { _ as y, c as z, l as A, o as P, p as d, v as u } from "../vendor-preact
|
|
|
3
3
|
import { i as fetchAndApplyTheme } from "../dashboardTheme-C87VA-Zf.js";
|
|
4
4
|
import { ct as Page, dt as TransitionSpinner, ot as ResolvedConfigProvider, rt as AutoFocusTitle, st as TerminalErrorPage, tt as IncodeComponent, yt as useManager } from "../extensibility-li3u8bJP.js";
|
|
5
5
|
import { t as registerIncodeModuleElement } from "../incodeModule-CPafHixS.js";
|
|
6
|
-
import { a as resolveApiKey, g as setupSDK, i as HEADLESS_WORKFLOW_MODULE_KEYS, l as LAZY_UI_MODULES, o as extractIncodeStatus, s as UnsupportedModule, t as useModuleLoader, v as isDesktopOrEmulated } from "../useModuleLoader-
|
|
6
|
+
import { a as resolveApiKey, g as setupSDK, i as HEADLESS_WORKFLOW_MODULE_KEYS, l as LAZY_UI_MODULES, o as extractIncodeStatus, s as UnsupportedModule, t as useModuleLoader, v as isDesktopOrEmulated } from "../useModuleLoader-Bl4AhWD8.js";
|
|
7
7
|
import { resolveWasmConfig, upgradeToWasmHttpClient, warmupWasm } from "@incodetech/core/wasm";
|
|
8
8
|
import { classifyScoreStatus } from "@incodetech/core/flow";
|
|
9
9
|
import { bootstrapSession, refreshQrUrlUuid } from "@incodetech/core/session";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@incodetech/web",
|
|
3
|
-
"version": "0.0.0-dev-20260813-
|
|
3
|
+
"version": "0.0.0-dev-20260813-c65eff54",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -292,7 +292,7 @@
|
|
|
292
292
|
"qrcode": "^1.5.4",
|
|
293
293
|
"signature_pad": "^5.1.3",
|
|
294
294
|
"tailwindcss": "^4.1.17",
|
|
295
|
-
"@incodetech/core": "0.0.0-dev-20260813-
|
|
295
|
+
"@incodetech/core": "0.0.0-dev-20260813-c65eff54"
|
|
296
296
|
},
|
|
297
297
|
"devDependencies": {
|
|
298
298
|
"@microsoft/api-extractor": "^7.53.3",
|