@incodetech/web 0.0.0-dev-20260423-427a341 → 0.0.0-dev-20260423-2678250

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.
@@ -1,52 +1,59 @@
1
1
  import { n as e } from "../i18n-BnVa5Y-_.js";
2
- import { v as t } from "../vendor-preact-D6SntenC.js";
3
- import { o as n, t as r } from "../incodeComponent-DEt7nOim.js";
4
- import { t as i } from "../page-D5Mt-0zn.js";
5
- import { t as a } from "../transitionSpinner-DLUM_WN2.js";
6
- import { t as o } from "../button-4-ToV5B_.js";
7
- import { t as s } from "../checkbox-DbHg0n25.js";
8
- import { t as c } from "../incodeModule-DcwjDRyJ.js";
9
- import { t as l } from "../richText-DPdexfgN.js";
10
- import { createConsentManager as u } from "@incodetech/core/consent";
2
+ import { _ as t, l as n, v as r } from "../vendor-preact-D6SntenC.js";
3
+ import { o as i, t as a } from "../incodeComponent-DEt7nOim.js";
4
+ import { t as o } from "../page-D5Mt-0zn.js";
5
+ import { n as s } from "../typography-B7nxauEL.js";
6
+ import { t as c } from "../transitionSpinner-DLUM_WN2.js";
7
+ import { t as l } from "../button-4-ToV5B_.js";
8
+ import { t as u } from "../checkbox-DbHg0n25.js";
9
+ import { t as d } from "../incodeModule-DcwjDRyJ.js";
10
+ import { t as f } from "../richText-DPdexfgN.js";
11
+ import { createConsentManager as p } from "@incodetech/core/consent";
11
12
  //#region src/modules/consent/consent.tsx
12
- var d = ({ config: r, manager: c, onFinish: d, onError: f }) => {
13
- let { t: p } = e(), [m, h] = n(() => {
14
- if (c) return c;
15
- if (!r) throw Error("Consent config is required");
16
- return u({ config: r });
17
- }, { manageLifecycle: !c });
18
- return m.status === "finished" ? (d?.(), null) : m.status === "error" ? (f?.(m.error), null) : m.status === "idle" || m.status === "loading" ? /* @__PURE__ */ t(a, { hideText: !0 }) : /* @__PURE__ */ t(i, {
13
+ var m = ({ config: a, manager: d, onFinish: m, onError: h }) => {
14
+ let { t: g } = e(), _ = n(null), [v, y] = i(() => {
15
+ if (d) return d;
16
+ if (!a) throw Error("Consent config is required");
17
+ return p({ config: a });
18
+ }, { manageLifecycle: !d });
19
+ return t(() => {
20
+ v.status === "display" && _.current?.focus();
21
+ }, [v.status]), v.status === "finished" ? (m?.(), null) : v.status === "error" ? (h?.(v.error), null) : v.status === "idle" || v.status === "loading" ? /* @__PURE__ */ r(c, { hideText: !0 }) : /* @__PURE__ */ r(o, {
19
22
  className: "IncodeConsentPage",
20
23
  hideFooterBranding: !0,
21
24
  hideHeader: !0,
22
- children: /* @__PURE__ */ t("div", {
25
+ children: /* @__PURE__ */ r("div", {
23
26
  class: "IncodeConsentContent",
24
- children: [/* @__PURE__ */ t("div", {
27
+ children: [/* @__PURE__ */ r("div", {
25
28
  class: "IncodeConsentBody",
26
29
  children: [
27
- /* @__PURE__ */ t("h1", {
28
- class: "IncodeConsentTitle",
29
- children: m.title
30
+ /* @__PURE__ */ r(s, {
31
+ ref: _,
32
+ className: "IncodeConsentTitle",
33
+ tabIndex: -1,
34
+ children: v.title
30
35
  }),
31
- /* @__PURE__ */ t(l, {
32
- content: m.richText,
36
+ /* @__PURE__ */ r(f, {
37
+ content: v.richText,
33
38
  class: "IncodeRichText"
34
39
  }),
35
- /* @__PURE__ */ t("div", {
40
+ /* @__PURE__ */ r("div", {
36
41
  class: "IncodeConsentCheckboxList",
37
- children: m.checkboxes.map((e) => /* @__PURE__ */ t(s, {
42
+ role: "group",
43
+ "aria-label": g("biometricConsent.consentOptions"),
44
+ children: v.checkboxes.map((e) => /* @__PURE__ */ r(u, {
38
45
  id: `consent-checkbox-${e.id}`,
39
46
  class: "IncodeConsentCheckbox",
40
47
  size: "s",
41
48
  checked: e.checked,
42
49
  required: e.required,
43
- onChange: () => h.toggleCheckbox(e.id),
44
- label: /* @__PURE__ */ t("span", {
50
+ onChange: () => y.toggleCheckbox(e.id),
51
+ label: /* @__PURE__ */ r("span", {
45
52
  class: "IncodeConsentCheckboxLabel",
46
53
  onClick: (e) => {
47
54
  e.target.closest("a") && e.stopPropagation();
48
55
  },
49
- children: /* @__PURE__ */ t(l, {
56
+ children: /* @__PURE__ */ r(f, {
50
57
  content: e.label,
51
58
  class: "IncodeRichText",
52
59
  disallowedTags: ["img"]
@@ -55,21 +62,21 @@ var d = ({ config: r, manager: c, onFinish: d, onError: f }) => {
55
62
  }, e.id))
56
63
  })
57
64
  ]
58
- }), /* @__PURE__ */ t(o, {
65
+ }), /* @__PURE__ */ r(l, {
59
66
  "data-testid": "consent-submit",
60
- onClick: () => h.submit(),
61
- disabled: !m.canSubmit,
62
- isLoading: m.status === "submitting",
63
- children: p("biometricConsent.button.continue")
67
+ onClick: () => y.submit(),
68
+ disabled: !v.canSubmit,
69
+ isLoading: v.status === "submitting",
70
+ children: g("biometricConsent.button.continue")
64
71
  })]
65
72
  })
66
- });
67
- }, f = ({ config: e, manager: n, onFinish: i, onError: a }) => /* @__PURE__ */ t(r, { children: e ? /* @__PURE__ */ t(d, {
73
+ }, "ready");
74
+ }, h = ({ config: e, manager: t, onFinish: n, onError: i }) => /* @__PURE__ */ r(a, { children: e ? /* @__PURE__ */ r(m, {
68
75
  config: e,
69
- manager: n,
70
- onFinish: i,
71
- onError: a
76
+ manager: t,
77
+ onFinish: n,
78
+ onError: i
72
79
  }) : null });
73
- c(f, "incode-consent");
80
+ d(h, "incode-consent");
74
81
  //#endregion
75
- export { f as Consent };
82
+ export { h as Consent };
@@ -99,6 +99,10 @@
99
99
  display: inline;
100
100
  }
101
101
 
102
+ .IncodeConsentPage .IncodeConsentCheckboxLabel .IncodeRichText .markup a, .IncodeConsentPage .IncodeConsentCheckboxLabel .IncodeRichText a {
103
+ color: var(--color-surface-brand-600, var(--surface-brand-600-static));
104
+ }
105
+
102
106
  .IncodeConsentPage .IncodeCheckboxRequired {
103
107
  margin-left: var(--spacing-0, var(--spacing-none, 0px));
104
108
  color: var(--color-text-body-primary, var(--text-body-800-primary));
@@ -4,7 +4,7 @@ import { t as s } from "../uiConfig-CwpQ-IM6.js";
4
4
  import { o as c, t as l } from "../incodeComponent-DEt7nOim.js";
5
5
  import { t as u } from "../transitionSpinner-DLUM_WN2.js";
6
6
  import { t as d } from "../incodeModule-DcwjDRyJ.js";
7
- import { a as f, c as p, d as m, i as h, l as g, n as _, o as v, p as y, r as b, s as x, t as S, u as C } from "../useModuleLoader-orDv3Be3.js";
7
+ import { a as f, c as p, d as m, i as h, l as g, n as _, o as v, p as y, r as b, s as x, t as S, u as C } from "../useModuleLoader-L4CQt8SX.js";
8
8
  import { getDeviceClass as w } from "@incodetech/core/device";
9
9
  import { getRequiredWasmPipelines as T } from "@incodetech/core/flow";
10
10
  import { createSession as E, validateQrUuid as D } from "@incodetech/core/session";
@@ -7080,6 +7080,10 @@
7080
7080
  display: inline;
7081
7081
  }
7082
7082
 
7083
+ .IncodeConsentPage .IncodeConsentCheckboxLabel .IncodeRichText .markup a, .IncodeConsentPage .IncodeConsentCheckboxLabel .IncodeRichText a {
7084
+ color: var(--color-surface-brand-600, var(--surface-brand-600-static));
7085
+ }
7086
+
7083
7087
  .IncodeConsentPage .IncodeCheckboxRequired {
7084
7088
  margin-left: var(--spacing-0, var(--spacing-none, 0px));
7085
7089
  color: var(--color-text-body-primary, var(--text-body-800-primary));
package/dist/id/id.es.js CHANGED
@@ -219,7 +219,7 @@ function B() {
219
219
  }
220
220
  //#endregion
221
221
  //#region src/modules/id/id.tsx
222
- var V = n(() => import("../mandatoryConsent-DkPINnNR.js").then((e) => ({ default: e.MandatoryConsent }))), H = ({ config: n, manager: r, onFinish: s, onError: c }) => {
222
+ var V = n(() => import("../mandatoryConsent-CBH0-kUV.js").then((e) => ({ default: e.MandatoryConsent }))), H = ({ config: n, manager: r, onFinish: s, onError: c }) => {
223
223
  A();
224
224
  let { t: h } = e();
225
225
  t(() => {
@@ -0,0 +1,99 @@
1
+ import { n as e } from "./i18n-BnVa5Y-_.js";
2
+ import { _ as t, l as n, v as r } from "./vendor-preact-D6SntenC.js";
3
+ import { o as i, t as a } from "./incodeComponent-DEt7nOim.js";
4
+ import { t as o } from "./page-D5Mt-0zn.js";
5
+ import { n as s } from "./typography-B7nxauEL.js";
6
+ import { t as c } from "./transitionSpinner-DLUM_WN2.js";
7
+ import { t as l } from "./button-4-ToV5B_.js";
8
+ import { t as u } from "./checkbox-DbHg0n25.js";
9
+ import { t as d } from "./incodeModule-DcwjDRyJ.js";
10
+ import { t as f } from "./richText-DPdexfgN.js";
11
+ import { createMandatoryConsentManager as p } from "@incodetech/core/mandatory-consent";
12
+ //#region src/modules/mandatory-consent/mandatoryConsent.tsx
13
+ var m = ({ config: a, manager: d, onFinish: m, onError: h }) => {
14
+ let { t: g } = e(), _ = n(null), [v, y] = i(() => d ?? p({ config: a }), { manageLifecycle: !d });
15
+ if (t(() => {
16
+ v.status === "display" && _.current?.focus();
17
+ }, [v.status]), t(() => {
18
+ if (v.status === "finished") {
19
+ m?.();
20
+ return;
21
+ }
22
+ if (v.status === "closed") {
23
+ h?.(void 0);
24
+ return;
25
+ }
26
+ v.status === "error" && h?.(v.error);
27
+ }, [
28
+ v,
29
+ m,
30
+ h
31
+ ]), v.status === "finished" || v.status === "closed" || v.status === "error") return null;
32
+ if (v.status === "idle" || v.status === "loading") return /* @__PURE__ */ r(c, { hideText: !0 });
33
+ let b = v.text.split("\n").filter((e) => e.trim().length > 0).join(" ");
34
+ return /* @__PURE__ */ r(o, {
35
+ className: "IncodeConsentPage",
36
+ hideFooterBranding: !0,
37
+ hideHeader: !0,
38
+ children: /* @__PURE__ */ r("div", {
39
+ class: "IncodeConsentContent",
40
+ children: [/* @__PURE__ */ r("div", {
41
+ class: "IncodeConsentBody",
42
+ children: [
43
+ /* @__PURE__ */ r(s, {
44
+ ref: _,
45
+ className: "IncodeConsentTitle",
46
+ tabIndex: -1,
47
+ children: v.title
48
+ }),
49
+ /* @__PURE__ */ r("p", {
50
+ class: "IncodeConsentSubtitle",
51
+ children: g("biometricConsent.subtitle")
52
+ }),
53
+ /* @__PURE__ */ r("div", {
54
+ class: "IncodeConsentCheckboxList",
55
+ children: /* @__PURE__ */ r(u, {
56
+ id: "mandatory-consent-checkbox",
57
+ class: "IncodeConsentCheckbox",
58
+ checked: v.isSigned,
59
+ required: !0,
60
+ onChange: () => y.toggle(),
61
+ label: /* @__PURE__ */ r("span", {
62
+ class: "IncodeConsentCheckboxLabel",
63
+ onClick: (e) => {
64
+ e.target.closest("a") && e.stopPropagation();
65
+ },
66
+ children: /* @__PURE__ */ r(f, {
67
+ content: b,
68
+ class: "IncodeRichText"
69
+ })
70
+ })
71
+ })
72
+ })
73
+ ]
74
+ }), /* @__PURE__ */ r("div", {
75
+ class: "IncodeConsentActions",
76
+ children: [/* @__PURE__ */ r(l, {
77
+ "data-testid": "mandatory-consent-submit",
78
+ class: "IncodeConsentButton",
79
+ onClick: () => y.submit(),
80
+ disabled: !v.canSubmit,
81
+ isLoading: v.status === "submitting",
82
+ children: g("biometricConsent.button.continue")
83
+ }), /* @__PURE__ */ r(l, {
84
+ variant: "link",
85
+ onClick: () => y.cancel(),
86
+ children: g("biometricConsent.button.cancel")
87
+ })]
88
+ })]
89
+ })
90
+ }, "ready");
91
+ }, h = ({ config: e, manager: t, onFinish: n, onError: i }) => /* @__PURE__ */ r(a, { children: e ? /* @__PURE__ */ r(m, {
92
+ config: e,
93
+ manager: t,
94
+ onFinish: n,
95
+ onError: i
96
+ }) : null });
97
+ d(h, "incode-mandatory-consent");
98
+ //#endregion
99
+ export { h as MandatoryConsent };
@@ -172,7 +172,7 @@ var A = {
172
172
  DOCUMENT_CAPTURE: () => import("./documentCapture-BDiV75I-.js").then((e) => e.DocumentCapture),
173
173
  ADDRESS: () => import("./documentCapture-BDiV75I-.js").then((e) => e.DocumentCapture),
174
174
  COMBINED_CONSENT: () => import("./consent/consent.es.js").then((e) => e.Consent),
175
- MANDATORY_CONSENT: () => import("./mandatoryConsent-DkPINnNR.js").then((e) => e.MandatoryConsent),
175
+ MANDATORY_CONSENT: () => import("./mandatoryConsent-CBH0-kUV.js").then((e) => e.MandatoryConsent),
176
176
  SIGNATURE: () => import("./signature/signature.es.js").then((e) => e.Signature),
177
177
  ANTIFRAUD: () => import("./antifraud/antifraud.es.js").then((e) => e.Antifraud),
178
178
  CUSTOM_FIELDS: () => import("./customFields-D7JzF2v_.js").then((e) => e.CustomFields),
@@ -6326,6 +6326,10 @@
6326
6326
  display: inline;
6327
6327
  }
6328
6328
 
6329
+ .IncodeConsentPage .IncodeConsentCheckboxLabel .IncodeRichText .markup a, .IncodeConsentPage .IncodeConsentCheckboxLabel .IncodeRichText a {
6330
+ color: var(--color-surface-brand-600, var(--surface-brand-600-static));
6331
+ }
6332
+
6329
6333
  .IncodeConsentPage .IncodeCheckboxRequired {
6330
6334
  margin-left: var(--spacing-0, var(--spacing-none, 0px));
6331
6335
  color: var(--color-text-body-primary, var(--text-body-800-primary));
@@ -5,7 +5,7 @@ import { o, t as s } from "../incodeComponent-DEt7nOim.js";
5
5
  import "../spinner-BmFWJNHp.js";
6
6
  import { t as c } from "../transitionSpinner-DLUM_WN2.js";
7
7
  import { t as l } from "../incodeModule-DcwjDRyJ.js";
8
- import { a as u, f as d, i as f, m as p, t as m } from "../useModuleLoader-orDv3Be3.js";
8
+ import { a as u, f as d, i as f, m as p, t as m } from "../useModuleLoader-L4CQt8SX.js";
9
9
  import { resolveWasmConfig as h, warmupWasm as g } from "@incodetech/core/wasm";
10
10
  import { createWorkflowManager as _ } from "@incodetech/core/workflow";
11
11
  //#region src/modules/workflow/workflowInit.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@incodetech/web",
3
- "version": "0.0.0-dev-20260423-427a341",
3
+ "version": "0.0.0-dev-20260423-2678250",
4
4
  "type": "module",
5
5
  "main": "./dist/index.es.js",
6
6
  "types": "./dist/types/index.d.ts",
@@ -229,7 +229,7 @@
229
229
  "qrcode": "^1.5.4",
230
230
  "signature_pad": "^5.1.3",
231
231
  "tailwindcss": "^4.1.17",
232
- "@incodetech/core": "0.0.0-dev-20260423-427a341"
232
+ "@incodetech/core": "0.0.0-dev-20260423-2678250"
233
233
  },
234
234
  "devDependencies": {
235
235
  "@microsoft/api-extractor": "^7.53.3",
@@ -1,94 +0,0 @@
1
- import { n as e } from "./i18n-BnVa5Y-_.js";
2
- import { _ as t, v as n } from "./vendor-preact-D6SntenC.js";
3
- import { o as r, t as i } from "./incodeComponent-DEt7nOim.js";
4
- import { t as a } from "./page-D5Mt-0zn.js";
5
- import { t as o } from "./transitionSpinner-DLUM_WN2.js";
6
- import { t as s } from "./button-4-ToV5B_.js";
7
- import { t as c } from "./checkbox-DbHg0n25.js";
8
- import { t as l } from "./incodeModule-DcwjDRyJ.js";
9
- import { t as u } from "./richText-DPdexfgN.js";
10
- import { createMandatoryConsentManager as d } from "@incodetech/core/mandatory-consent";
11
- //#region src/modules/mandatory-consent/mandatoryConsent.tsx
12
- var f = ({ config: i, manager: l, onFinish: f, onError: p }) => {
13
- let { t: m } = e(), [h, g] = r(() => l ?? d({ config: i }), { manageLifecycle: !l });
14
- if (t(() => {
15
- if (h.status === "finished") {
16
- f?.();
17
- return;
18
- }
19
- if (h.status === "closed") {
20
- p?.(void 0);
21
- return;
22
- }
23
- h.status === "error" && p?.(h.error);
24
- }, [
25
- h,
26
- f,
27
- p
28
- ]), h.status === "finished" || h.status === "closed" || h.status === "error") return null;
29
- if (h.status === "idle" || h.status === "loading") return /* @__PURE__ */ n(o, { hideText: !0 });
30
- let _ = h.text.split("\n").filter((e) => e.trim().length > 0).join(" ");
31
- return /* @__PURE__ */ n(a, {
32
- className: "IncodeConsentPage",
33
- hideFooterBranding: !0,
34
- hideHeader: !0,
35
- children: /* @__PURE__ */ n("div", {
36
- class: "IncodeConsentContent",
37
- children: [/* @__PURE__ */ n("div", {
38
- class: "IncodeConsentBody",
39
- children: [
40
- /* @__PURE__ */ n("h1", {
41
- id: "mandatory-consent-title",
42
- class: "IncodeConsentTitle",
43
- children: h.title
44
- }),
45
- /* @__PURE__ */ n("p", {
46
- class: "IncodeConsentSubtitle",
47
- children: m("biometricConsent.subtitle")
48
- }),
49
- /* @__PURE__ */ n("div", {
50
- class: "IncodeConsentCheckboxList",
51
- children: /* @__PURE__ */ n(c, {
52
- id: "mandatory-consent-checkbox",
53
- class: "IncodeConsentCheckbox",
54
- checked: h.isSigned,
55
- onChange: () => g.toggle(),
56
- label: /* @__PURE__ */ n("span", {
57
- class: "IncodeConsentCheckboxLabel",
58
- onClick: (e) => {
59
- e.target.closest("a") && e.stopPropagation();
60
- },
61
- children: /* @__PURE__ */ n(u, {
62
- content: _,
63
- class: "IncodeRichText"
64
- })
65
- })
66
- })
67
- })
68
- ]
69
- }), /* @__PURE__ */ n("div", {
70
- class: "IncodeConsentActions",
71
- children: [/* @__PURE__ */ n(s, {
72
- "data-testid": "mandatory-consent-submit",
73
- class: "IncodeConsentButton",
74
- onClick: () => g.submit(),
75
- disabled: !h.canSubmit,
76
- isLoading: h.status === "submitting",
77
- children: m("biometricConsent.button.continue")
78
- }), /* @__PURE__ */ n(s, {
79
- variant: "link",
80
- onClick: () => g.cancel(),
81
- children: m("biometricConsent.button.cancel")
82
- })]
83
- })]
84
- })
85
- });
86
- }, p = ({ config: e, manager: t, onFinish: r, onError: a }) => /* @__PURE__ */ n(i, { children: e ? /* @__PURE__ */ n(f, {
87
- config: e,
88
- manager: t,
89
- onFinish: r,
90
- onError: a
91
- }) : null });
92
- l(p, "incode-mandatory-consent");
93
- //#endregion
94
- export { p as MandatoryConsent };