@incodetech/web 0.0.0-dev-20260318-deddf15 → 0.0.0-dev-20260318-ce9c1ed

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,4 +1,4 @@
1
- import { M as g, b as et, i as j, v as zt, d as Jt, w as Zt, m as Qt } from "./countries-C9bhJe4u.js";
1
+ import { M as g, d as et, i as j, v as zt, e as Jt, w as Zt, m as Qt } from "./countries-CM1cm_kP.js";
2
2
  function U(t, r, e) {
3
3
  return te(t, r, void 0, e);
4
4
  }
@@ -2602,5 +2602,6 @@ tt.prototype = Object.create(Kt.prototype, {});
2602
2602
  tt.prototype.constructor = tt;
2603
2603
  export {
2604
2604
  tt as A,
2605
+ Gt as P,
2605
2606
  si as p
2606
2607
  };
@@ -603,10 +603,11 @@ function x($) {
603
603
  }
604
604
  export {
605
605
  F as M,
606
- x as a,
607
- A as b,
606
+ b as a,
607
+ x as b,
608
608
  g as c,
609
- k as d,
609
+ A as d,
610
+ k as e,
610
611
  B as g,
611
612
  s as i,
612
613
  C as m,
@@ -1,6 +1,6 @@
1
- import { b as C, u as e, S as u, B as h, d as D, I as E, a as T } from "./button-Ca1tRSTI.js";
1
+ import { b as u, u as e, S as s, B as m, d as D, I as E, a as T } from "./button-Ca1tRSTI.js";
2
2
  import { createDocumentCaptureManager as N } from "@incodetech/core/document-capture";
3
- import { A as b, q as Z, k as f, _ as o, d as _, y as k } from "./vendor-preact-BXf0bkEs.js";
3
+ import { A as b, q as Z, k as h, _ as o, d as _, y as k } from "./vendor-preact-BXf0bkEs.js";
4
4
  import "@incodetech/core";
5
5
  import { P as H } from "./page-BVHG3h0V.js";
6
6
  import { S as M } from "./spinner-Cx3FPUCD.js";
@@ -10,7 +10,7 @@ import "./uiConfig-Z6RT23Sl.js";
10
10
  import { M as q, C as J, F as Q } from "./fileIcon-DOyMcRWU.js";
11
11
  import { E as X } from "./errorContent-yUAdbZ5o.js";
12
12
  import { S as Y } from "./successIcon-BybULRRU.js";
13
- function ee(t) {
13
+ function e1(t) {
14
14
  if (t.readyState < 2 || t.videoWidth === 0 || t.videoHeight === 0)
15
15
  return null;
16
16
  const r = document.createElement("canvas");
@@ -18,27 +18,27 @@ function ee(t) {
18
18
  const i = r.getContext("2d");
19
19
  return i ? (i.drawImage(t, 0, 0), r.toDataURL("image/jpeg", 0.92).split(",")[1] ?? null) : null;
20
20
  }
21
- const te = ({
21
+ const t1 = ({
22
22
  stream: t,
23
23
  manager: r,
24
24
  onOpenHelp: i
25
25
  }) => {
26
- const { t: n } = C(), a = b(null), p = Z(() => {
27
- const l = a.current;
26
+ const { t: n } = u(), c = b(null), C = Z(() => {
27
+ const l = c.current;
28
28
  if (!l) return;
29
- const c = ee(l);
30
- if (!c) return;
31
- const d = new Blob(
32
- [Uint8Array.from(atob(c), (g) => g.charCodeAt(0))],
29
+ const a = e1(l);
30
+ if (!a) return;
31
+ const f = new Blob(
32
+ [Uint8Array.from(atob(a), (g) => g.charCodeAt(0))],
33
33
  { type: "image/jpeg" }
34
- ), v = new File([d], "document.jpg", { type: "image/jpeg" });
35
- r.setFile(v, `data:image/jpeg;base64,${c}`);
34
+ ), v = new File([f], "document.jpg", { type: "image/jpeg" });
35
+ r.setFile(v, `data:image/jpeg;base64,${a}`);
36
36
  }, [r]);
37
37
  return /* @__PURE__ */ e(
38
38
  G,
39
39
  {
40
40
  stream: t,
41
- videoRef: a,
41
+ videoRef: c,
42
42
  "data-testid": "document-capture-camera",
43
43
  children: /* @__PURE__ */ e(U, { children: [
44
44
  /* @__PURE__ */ e(
@@ -48,13 +48,13 @@ const te = ({
48
48
  subtitle: n("documentCapture.camera.subtitle")
49
49
  }
50
50
  ),
51
- /* @__PURE__ */ e(u, { size: 16 }),
51
+ /* @__PURE__ */ e(s, { size: 16 }),
52
52
  /* @__PURE__ */ e(K, { variant: "fill" }),
53
53
  /* @__PURE__ */ e(
54
54
  j,
55
55
  {
56
56
  onOpenHelp: i,
57
- onCapture: p,
57
+ onCapture: C,
58
58
  isManualCapture: !0,
59
59
  captureAriaLabel: n("manualCapture.ariaLabel"),
60
60
  helpAriaLabel: n("documentCapture.needHelp.open"),
@@ -64,7 +64,7 @@ const te = ({
64
64
  ] })
65
65
  }
66
66
  );
67
- }, ne = () => /* @__PURE__ */ e("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": !0, children: [
67
+ }, n1 = () => /* @__PURE__ */ e("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": !0, children: [
68
68
  /* @__PURE__ */ e(
69
69
  "path",
70
70
  {
@@ -110,7 +110,7 @@ const te = ({
110
110
  fill: "currentColor"
111
111
  }
112
112
  )
113
- ] }), oe = () => /* @__PURE__ */ e("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": !0, children: [
113
+ ] }), o1 = () => /* @__PURE__ */ e("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": !0, children: [
114
114
  /* @__PURE__ */ e(
115
115
  "path",
116
116
  {
@@ -165,7 +165,7 @@ const te = ({
165
165
  fill: "currentColor"
166
166
  }
167
167
  )
168
- ] }), re = () => /* @__PURE__ */ e("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": !0, children: [
168
+ ] }), r1 = () => /* @__PURE__ */ e("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": !0, children: [
169
169
  /* @__PURE__ */ e(
170
170
  "path",
171
171
  {
@@ -184,7 +184,7 @@ const te = ({
184
184
  fill: "currentColor"
185
185
  }
186
186
  )
187
- ] }), ie = () => /* @__PURE__ */ e("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": !0, children: /* @__PURE__ */ e(
187
+ ] }), i1 = () => /* @__PURE__ */ e("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", "aria-hidden": !0, children: /* @__PURE__ */ e(
188
188
  "path",
189
189
  {
190
190
  "fill-rule": "evenodd",
@@ -192,31 +192,31 @@ const te = ({
192
192
  d: "M14.314 13.9858C14.607 14.2671 14.607 14.7231 14.314 15.0043C14.168 15.1445 13.976 15.2146 13.784 15.2146C13.592 15.2146 13.4 15.1445 13.253 15.0043L12 13.8005L10.744 15.0063C10.597 15.1474 10.405 15.2175 10.213 15.2175C10.022 15.2175 9.83 15.1474 9.683 15.0063C9.39 14.7259 9.39 14.269 9.683 13.9887L10.939 12.7829L9.683 11.5771C9.39 11.2959 9.39 10.8408 9.683 10.5595C9.976 10.2783 10.451 10.2783 10.744 10.5595L12 11.7653L13.253 10.5624C13.546 10.2811 14.021 10.2811 14.314 10.5624C14.607 10.8437 14.607 11.2997 14.314 11.581L13.061 12.7829L14.314 13.9858ZM17.957 6.57747C17.594 6.56403 17.255 6.41811 17.013 6.17427C16.968 6.12723 16.791 5.91507 16.376 5.16819C15.898 4.31187 14.974 3.78003 13.964 3.78003H10.053C9.058 3.78003 8.142 4.29939 7.661 5.13459C7.224 5.89395 7.043 6.11763 6.995 6.16947C6.744 6.42195 6.405 6.56787 6.062 6.58227C4.1 6.58227 2.502 8.11443 2.5 9.99795V15.4143C2.5 17.8527 4.566 19.837 7.106 19.837H16.894C19.433 19.837 21.5 17.8527 21.5 15.4143V9.99603C21.5 8.11059 19.902 6.57747 17.957 6.57747Z",
193
193
  fill: "currentColor"
194
194
  }
195
- ) }), ae = [
195
+ ) }), a1 = [
196
196
  {
197
197
  titleKey: "documentCapture.commonIssues.farPresent",
198
198
  bodyKey: "documentCapture.commonIssues.farPresentDescription",
199
- Icon: ne
199
+ Icon: n1
200
200
  },
201
201
  {
202
202
  titleKey: "documentCapture.commonIssues.foldedIdPresent",
203
203
  bodyKey: "documentCapture.commonIssues.foldedIdPresentDescription",
204
- Icon: oe
204
+ Icon: o1
205
205
  },
206
206
  {
207
207
  titleKey: "documentCapture.commonIssues.shadowPresent",
208
208
  bodyKey: "documentCapture.commonIssues.shadowPresentDescription",
209
- Icon: re
209
+ Icon: r1
210
210
  },
211
211
  {
212
212
  titleKey: "documentCapture.commonIssues.dirtyPresent",
213
213
  bodyKey: "documentCapture.commonIssues.dirtyPresentDescription",
214
- Icon: ie
214
+ Icon: i1
215
215
  }
216
- ], ce = ({
216
+ ], c1 = ({
217
217
  onClose: t
218
218
  }) => {
219
- const { t: r } = C();
219
+ const { t: r } = u();
220
220
  return /* @__PURE__ */ e(q, { "aria-labelledby": "document-common-issues-title", children: [
221
221
  /* @__PURE__ */ e(
222
222
  "h2",
@@ -226,94 +226,87 @@ const te = ({
226
226
  children: r("commonIssues.commonIssues")
227
227
  }
228
228
  ),
229
- /* @__PURE__ */ e(u, { size: 32 }),
230
- /* @__PURE__ */ e("div", { class: "IncodeDocumentCommonIssuesCards", children: ae.map((i) => /* @__PURE__ */ e("div", { class: "IncodeDocumentCommonIssuesCard", children: [
229
+ /* @__PURE__ */ e(s, { size: 32 }),
230
+ /* @__PURE__ */ e("div", { class: "IncodeDocumentCommonIssuesCards", children: a1.map((i) => /* @__PURE__ */ e("div", { class: "IncodeDocumentCommonIssuesCard", children: [
231
231
  /* @__PURE__ */ e("div", { class: "IncodeDocumentCommonIssuesCardIcon", children: /* @__PURE__ */ e(i.Icon, {}) }),
232
232
  /* @__PURE__ */ e("div", { class: "IncodeDocumentCommonIssuesCardText", children: [
233
233
  /* @__PURE__ */ e("h5", { class: "IncodeDocumentCommonIssuesCardTitle", children: r(i.titleKey) }),
234
234
  /* @__PURE__ */ e("p", { class: "IncodeDocumentCommonIssuesCardBody", children: r(i.bodyKey) })
235
235
  ] })
236
236
  ] }, i.titleKey)) }),
237
- /* @__PURE__ */ e("div", { class: "IncodeDocumentCommonIssuesButtons", children: /* @__PURE__ */ e(h, { onClick: t, children: r("commonIssues.tryAgain") }) })
237
+ /* @__PURE__ */ e("div", { class: "IncodeDocumentCommonIssuesButtons", children: /* @__PURE__ */ e(m, { onClick: t, children: r("commonIssues.tryAgain") }) })
238
238
  ] });
239
- }, le = ({
240
- manager: t,
241
- captureMode: r
242
- }) => {
243
- const { t: i } = C(), n = i(r === "file" ? "documentCapture.review.replace" : "documentCapture.review.retake");
239
+ }, l1 = ({ manager: t }) => {
240
+ const { t: r } = u();
244
241
  return /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureActionRow", children: [
245
242
  /* @__PURE__ */ e(
246
- h,
243
+ m,
247
244
  {
248
245
  variant: "secondary",
249
246
  onClick: () => t.retake(),
250
247
  "data-testid": "document-capture-retake-button",
251
- children: n
248
+ children: r("documentCapture.review.replace")
252
249
  }
253
250
  ),
254
251
  /* @__PURE__ */ e(
255
- h,
252
+ m,
256
253
  {
257
254
  onClick: () => t.accept(),
258
255
  "data-testid": "document-capture-accept-button",
259
- children: i("documentCapture.review.continue")
256
+ children: r("documentCapture.review.continue")
260
257
  }
261
258
  )
262
259
  ] });
263
- }, de = ({ isFilePdf: t }) => {
264
- const { t: r } = C();
265
- return /* @__PURE__ */ e(f, { children: [
260
+ }, d1 = ({ isFilePdf: t }) => {
261
+ const { t: r } = u();
262
+ return /* @__PURE__ */ e(h, { children: [
266
263
  /* @__PURE__ */ e("h2", { class: "IncodeDocumentCaptureReviewTitle", children: r(t ? "documentCapture.review.titlePdfUpload" : "documentCapture.review.titleCaptured") }),
267
- /* @__PURE__ */ e(u, { size: 12 }),
264
+ /* @__PURE__ */ e(s, { size: 12 }),
268
265
  /* @__PURE__ */ e("p", { class: "IncodeDocumentCaptureReviewSubtitle", children: r(t ? "documentCapture.review.subtitlePdfUpload" : "documentCapture.review.subtitleCaptured") })
269
266
  ] });
270
- }, se = ({
267
+ }, s1 = ({
271
268
  manager: t,
272
269
  pendingNextPage: r
273
270
  }) => {
274
- const { t: i } = C();
271
+ const { t: i } = u();
275
272
  return /* @__PURE__ */ e(
276
- h,
273
+ m,
277
274
  {
278
275
  onClick: () => t.continue(),
279
276
  "data-testid": "document-capture-continue-button",
280
277
  children: i(r ? "documentCapture.review.addNextPage" : "documentCapture.review.continue")
281
278
  }
282
279
  );
283
- }, ue = () => {
284
- const { t } = C();
285
- return /* @__PURE__ */ e(f, { children: [
280
+ }, u1 = () => {
281
+ const { t } = u();
282
+ return /* @__PURE__ */ e(h, { children: [
286
283
  /* @__PURE__ */ e(Y, { size: 30 }),
287
- /* @__PURE__ */ e(u, { size: 16 }),
284
+ /* @__PURE__ */ e(s, { size: 16 }),
288
285
  /* @__PURE__ */ e("h2", { class: "IncodeDocumentCaptureReviewTitle", children: t("documentCapture.review.successTitle") })
289
286
  ] });
290
- }, Ce = ({
287
+ }, C1 = ({
291
288
  progress: t,
292
289
  isFilePdf: r
293
290
  }) => {
294
- const { t: i } = C(), n = i(r ? "documentCapture.review.uploading" : "documentCapture.review.analyzing");
295
- return /* @__PURE__ */ e(f, { children: [
296
- /* @__PURE__ */ e(u, { size: 8 }),
291
+ const { t: i } = u(), n = i(r ? "documentCapture.review.uploading" : "documentCapture.review.analyzing");
292
+ return /* @__PURE__ */ e(h, { children: [
293
+ /* @__PURE__ */ e(s, { size: 8 }),
297
294
  /* @__PURE__ */ e(W, { progress: t, label: n })
298
295
  ] });
299
- }, pe = ({
300
- state: t,
301
- manager: r,
302
- captureMode: i
303
- }) => {
304
- const { t: n } = C();
296
+ }, p1 = ({ state: t, manager: r }) => {
297
+ const { t: i } = u();
305
298
  if (t.status === "failure")
306
299
  return /* @__PURE__ */ e(
307
300
  X,
308
301
  {
309
302
  "data-testid": "document-capture-error",
310
- title: n("documentCapture.review.error.title"),
311
- description: t.attemptsRemaining <= 0 ? n("notifications.noTries") : n("documentCapture.review.error.description"),
303
+ title: i("documentCapture.review.error.title"),
304
+ description: t.attemptsRemaining <= 0 ? i("notifications.noTries") : i("documentCapture.review.error.description"),
312
305
  attemptsRemaining: t.attemptsRemaining,
313
306
  onButtonClick: () => r.retry()
314
307
  }
315
308
  );
316
- const a = t.fileType === "application/pdf" || t.imageBase64.startsWith("data:application/pdf"), { fileName: p } = t, l = t.status === "preview", c = t.status === "uploading", d = t.status === "success";
309
+ const n = t.fileType === "application/pdf" || t.imageBase64.startsWith("data:application/pdf"), { fileName: c } = t, C = t.status === "preview", l = t.status === "uploading", a = t.status === "success";
317
310
  return /* @__PURE__ */ e(
318
311
  H,
319
312
  {
@@ -323,19 +316,19 @@ const te = ({
323
316
  "data-testid": "document-capture-review",
324
317
  children: /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureReviewLayout", children: [
325
318
  /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureReviewHeader", children: [
326
- l ? /* @__PURE__ */ e(de, { isFilePdf: a }) : null,
327
- c ? /* @__PURE__ */ e(Ce, { progress: t.progress, isFilePdf: a }) : null,
328
- d ? /* @__PURE__ */ e(ue, {}) : null
319
+ C ? /* @__PURE__ */ e(d1, { isFilePdf: n }) : null,
320
+ l ? /* @__PURE__ */ e(C1, { progress: t.progress, isFilePdf: n }) : null,
321
+ a ? /* @__PURE__ */ e(u1, {}) : null
329
322
  ] }),
330
323
  /* @__PURE__ */ e(
331
324
  "div",
332
325
  {
333
326
  class: D(
334
327
  "IncodeDocumentCaptureReviewPreview",
335
- a && "IncodeDocumentCaptureReviewPreviewPdf"
328
+ n && "IncodeDocumentCaptureReviewPreviewPdf"
336
329
  ),
337
330
  children: [
338
- a ? /* @__PURE__ */ e(f, { children: [
331
+ n ? /* @__PURE__ */ e(h, { children: [
339
332
  /* @__PURE__ */ e("div", { class: "IncodeDocumentCapturePdfCard", children: [
340
333
  /* @__PURE__ */ e("div", { class: "ImageDocumentCapturePdfPreviewContainer", children: /* @__PURE__ */ e(
341
334
  "object",
@@ -345,9 +338,9 @@ const te = ({
345
338
  class: "ImageDocumentCapturePdfPreview"
346
339
  }
347
340
  ) }),
348
- /* @__PURE__ */ e("p", { class: "IncodeDocumentCapturePdfFileName", children: p })
341
+ /* @__PURE__ */ e("p", { class: "IncodeDocumentCapturePdfFileName", children: c })
349
342
  ] }),
350
- /* @__PURE__ */ e(u, { size: 16 })
343
+ /* @__PURE__ */ e(s, { size: 16 })
351
344
  ] }) : t.imageBase64 ? /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureReviewImageContainer", children: /* @__PURE__ */ e(
352
345
  "img",
353
346
  {
@@ -355,35 +348,35 @@ const te = ({
355
348
  alt: "",
356
349
  class: D(
357
350
  "IncodeDocumentCaptureReviewImage",
358
- d && "IncodeDocumentCaptureSuccessBorder"
351
+ a && "IncodeDocumentCaptureSuccessBorder"
359
352
  ),
360
353
  "data-testid": "document-capture-review-image"
361
354
  }
362
355
  ) }) : null,
363
- /* @__PURE__ */ e(u, { size: 8 }),
356
+ /* @__PURE__ */ e(s, { size: 8 }),
364
357
  /* @__PURE__ */ e("div", { class: "IncodeCaptureEncryptionLabel", children: [
365
358
  /* @__PURE__ */ e($, { className: "IncodeCaptureEncryptionIcon" }),
366
359
  /* @__PURE__ */ e("span", { children: [
367
360
  " ",
368
- n("encryptionLabel.encryptedPhotos")
361
+ i("encryptionLabel.encryptedPhotos")
369
362
  ] })
370
363
  ] }),
371
- /* @__PURE__ */ e(u, { size: 8 })
364
+ /* @__PURE__ */ e(s, { size: 8 })
372
365
  ]
373
366
  }
374
367
  ),
375
- /* @__PURE__ */ e(u, { size: 24 }),
368
+ /* @__PURE__ */ e(s, { size: 24 }),
376
369
  /* @__PURE__ */ e(
377
370
  "div",
378
371
  {
379
372
  class: D(
380
373
  "IncodeDocumentCaptureReviewFooter",
381
- c && "IncodeDocumentCaptureReviewFooterEmpty"
374
+ l && "IncodeDocumentCaptureReviewFooterEmpty"
382
375
  ),
383
376
  children: [
384
- l ? /* @__PURE__ */ e(le, { manager: r, captureMode: i }) : null,
385
- d ? /* @__PURE__ */ e(
386
- se,
377
+ C ? /* @__PURE__ */ e(l1, { manager: r }) : null,
378
+ a ? /* @__PURE__ */ e(
379
+ s1,
387
380
  {
388
381
  manager: r,
389
382
  pendingNextPage: t.status === "success" && t.pendingNextPage
@@ -395,8 +388,8 @@ const te = ({
395
388
  ] })
396
389
  }
397
390
  );
398
- }, me = (t) => /* @__PURE__ */ o("svg", { viewBox: "0 0 292 305", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ o("circle", { cx: 145.743, cy: 152.074, r: 139.295, fill: "#E5F0FF" }), /* @__PURE__ */ o("g", { filter: "url(#filter0_d_4533_6792)" }, /* @__PURE__ */ o("path", { d: "M58.6299 32.6143C58.6299 29.8528 60.8685 27.6143 63.6299 27.6143H227.017C229.779 27.6143 232.017 29.8528 232.017 32.6143V248.24C232.017 251.002 229.779 253.24 227.017 253.24H63.6299C60.8685 253.24 58.6299 251.002 58.6299 248.24V32.6143Z", fill: "white" }), /* @__PURE__ */ o("path", { d: "M58.6299 32.6143C58.6299 29.8528 60.8685 27.6143 63.6299 27.6143H227.017C229.779 27.6143 232.017 29.8528 232.017 32.6143V248.24C232.017 251.002 229.779 253.24 227.017 253.24H63.6299C60.8685 253.24 58.6299 251.002 58.6299 248.24V32.6143Z", fill: "black", fillOpacity: 0.01 })), /* @__PURE__ */ o("g", { opacity: 0.5 }, /* @__PURE__ */ o("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M73.4139 60.0905C73.4139 59.62 73.7953 59.2385 74.2658 59.2385H216.865C217.336 59.2385 217.717 59.62 217.717 60.0905V62.7331C217.717 63.2036 217.336 63.585 216.865 63.585H74.2658C73.7953 63.585 73.4139 63.2036 73.4139 62.7331V60.0905Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M73.4139 220.911C73.4139 220.44 73.7953 220.059 74.2658 220.059H216.865C217.336 220.059 217.717 220.44 217.717 220.911V223.553C217.717 224.024 217.336 224.405 216.865 224.405H74.2658C73.7953 224.405 73.4139 224.024 73.4139 223.553V220.911Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.4139 83.5619C73.4139 83.0914 73.7953 82.7099 74.2658 82.7099H130.805C131.275 82.7099 131.657 83.0914 131.657 83.5619V91.4202C131.657 91.8907 131.275 92.2722 130.805 92.2722H74.2658C73.7953 92.2722 73.4139 91.8907 73.4139 91.4202L73.4139 83.5619Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.4138 101.817C73.4138 101.347 73.7953 100.965 74.2658 100.965H130.805C131.275 100.965 131.657 101.347 131.657 101.817V109.676C131.657 110.146 131.275 110.528 130.805 110.528H74.2658C73.7953 110.528 73.4138 110.146 73.4138 109.676L73.4138 101.817Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.399 120.072C73.4072 119.601 73.7952 119.227 74.2657 119.235L154.263 120.631C154.734 120.639 155.109 121.028 155.1 121.498L154.963 129.355C154.955 129.826 154.567 130.2 154.097 130.192L74.0988 128.796C73.6284 128.787 73.2536 128.399 73.2619 127.929L73.399 120.072Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.399 138.327C73.4072 137.857 73.7952 137.482 74.2657 137.49L97.7678 137.9C98.2383 137.909 98.613 138.297 98.6048 138.767L98.498 144.886C98.4897 145.356 98.1017 145.731 97.6313 145.723L74.1292 145.313C73.6587 145.304 73.284 144.916 73.2922 144.446L73.399 138.327Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.4139 38.3582C73.4139 37.8877 73.7953 37.5063 74.2658 37.5063H180.355C180.825 37.5063 181.207 37.8877 181.207 38.3582V47.0859C181.207 47.5564 180.825 47.9378 180.355 47.9378H74.2658C73.7953 47.9378 73.4139 47.5564 73.4139 47.0859V38.3582Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M195.985 37.4887C195.985 37.0182 196.366 36.6367 196.837 36.6367H216.865C217.336 36.6367 217.717 37.0182 217.717 37.4887V46.2163C217.717 46.6868 217.336 47.0683 216.865 47.0683H196.837C196.366 47.0683 195.985 46.6868 195.985 46.2163V37.4887Z", fill: "#C6C8D2" })), /* @__PURE__ */ o("mask", { id: "path-4-inside-1_4533_6792", fill: "white" }, /* @__PURE__ */ o("path", { d: "M63.8701 255.593C60.0041 255.593 56.8701 252.459 56.8701 248.593L56.8701 32.5516C56.8701 28.6856 60.0041 25.5516 63.8701 25.5516L227.68 25.5516C231.546 25.5516 234.68 28.6856 234.68 32.5516V248.593C234.68 252.459 231.546 255.593 227.68 255.593L63.8701 255.593Z" })), /* @__PURE__ */ o("g", { clipPath: "url(#paint0_diamond_4533_6792_clip_path)", "data-figma-skip-parse": "true", mask: "url(#path-4-inside-1_4533_6792)" }, /* @__PURE__ */ o("g", { transform: "matrix(0.0908399 -0.0986632 0.220271 0.965929 54.935 239.235)" }, /* @__PURE__ */ o("rect", { x: 0, y: 0, width: 2037.51, height: 179.024, fill: "url(#paint0_diamond_4533_6792)", opacity: 1, shapeRendering: "crispEdges" }), /* @__PURE__ */ o("rect", { x: 0, y: 0, width: 2037.51, height: 179.024, transform: "scale(1 -1)", fill: "url(#paint0_diamond_4533_6792)", opacity: 1, shapeRendering: "crispEdges" }), /* @__PURE__ */ o("rect", { x: 0, y: 0, width: 2037.51, height: 179.024, transform: "scale(-1 1)", fill: "url(#paint0_diamond_4533_6792)", opacity: 1, shapeRendering: "crispEdges" }), /* @__PURE__ */ o("rect", { x: 0, y: 0, width: 2037.51, height: 179.024, transform: "scale(-1)", fill: "url(#paint0_diamond_4533_6792)", opacity: 1, shapeRendering: "crispEdges" }))), /* @__PURE__ */ o("path", { d: "M56.8701 248.593H58.8701L58.8701 32.5516H56.8701H54.8701L54.8701 248.593H56.8701ZM63.8701 25.5516V27.5516L227.68 27.5516V25.5516L227.68 23.5516L63.8701 23.5516V25.5516ZM234.68 32.5516H232.68V248.593H234.68H236.68V32.5516H234.68ZM227.68 255.593V253.593L63.8701 253.593V255.593V257.593H227.68V255.593ZM234.68 248.593H232.68C232.68 251.354 230.441 253.593 227.68 253.593V255.593V257.593C232.65 257.593 236.68 253.563 236.68 248.593H234.68ZM227.68 25.5516V27.5516C230.441 27.5516 232.68 29.7901 232.68 32.5516H234.68H236.68C236.68 27.581 232.65 23.5516 227.68 23.5516L227.68 25.5516ZM56.8701 32.5516H58.8701C58.8701 29.7902 61.1087 27.5516 63.8701 27.5516V25.5516V23.5516C58.8996 23.5516 54.8701 27.581 54.8701 32.5516H56.8701ZM56.8701 248.593H54.8701C54.8701 253.563 58.8996 257.593 63.8701 257.593V255.593V253.593C61.1087 253.593 58.8701 251.354 58.8701 248.593H56.8701Z", "data-figma-gradient-fill": '{"type":"GRADIENT_DIAMOND","stops":[{"color":{"r":1.0,"g":1.0,"b":1.0,"a":1.0},"position":0.0},{"color":{"r":1.0,"g":1.0,"b":1.0,"a":0.0},"position":1.0},{"color":{"r":1.0,"g":1.0,"b":1.0,"a":0.54000002145767212},"position":1.0}],"stopsVar":[],"transform":{"m00":181.67984008789062,"m01":440.54235839843750,"m02":-256.17605590820312,"m10":-197.32632446289062,"m11":1931.8571777343750,"m12":-628.03063964843750},"opacity":1.0,"blendMode":"NORMAL","visible":true}', mask: "url(#path-4-inside-1_4533_6792)" }), /* @__PURE__ */ o("path", { d: "M56.8701 248.593H58.8701L58.8701 32.5516H56.8701H54.8701L54.8701 248.593H56.8701ZM63.8701 25.5516V27.5516L227.68 27.5516V25.5516L227.68 23.5516L63.8701 23.5516V25.5516ZM234.68 32.5516H232.68V248.593H234.68H236.68V32.5516H234.68ZM227.68 255.593V253.593L63.8701 253.593V255.593V257.593H227.68V255.593ZM234.68 248.593H232.68C232.68 251.354 230.441 253.593 227.68 253.593V255.593V257.593C232.65 257.593 236.68 253.563 236.68 248.593H234.68ZM227.68 25.5516V27.5516C230.441 27.5516 232.68 29.7901 232.68 32.5516H234.68H236.68C236.68 27.581 232.65 23.5516 227.68 23.5516L227.68 25.5516ZM56.8701 32.5516H58.8701C58.8701 29.7902 61.1087 27.5516 63.8701 27.5516V25.5516V23.5516C58.8996 23.5516 54.8701 27.581 54.8701 32.5516H56.8701ZM56.8701 248.593H54.8701C54.8701 253.563 58.8996 257.593 63.8701 257.593V255.593V253.593C61.1087 253.593 58.8701 251.354 58.8701 248.593H56.8701Z", fill: "white", fillOpacity: 0.5, mask: "url(#path-4-inside-1_4533_6792)" }), /* @__PURE__ */ o("defs", null, /* @__PURE__ */ o("filter", { id: "filter0_d_4533_6792", x: 34.6299, y: 6.61426, width: 221.387, height: 273.626, filterUnits: "userSpaceOnUse", colorInterpolationFilters: "sRGB" }, /* @__PURE__ */ o("feFlood", { floodOpacity: 0, result: "BackgroundImageFix" }), /* @__PURE__ */ o("feColorMatrix", { in: "SourceAlpha", type: "matrix", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0", result: "hardAlpha" }), /* @__PURE__ */ o("feOffset", { dy: 3 }), /* @__PURE__ */ o("feGaussianBlur", { stdDeviation: 12 }), /* @__PURE__ */ o("feColorMatrix", { type: "matrix", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0" }), /* @__PURE__ */ o("feBlend", { mode: "normal", in2: "BackgroundImageFix", result: "effect1_dropShadow_4533_6792" }), /* @__PURE__ */ o("feBlend", { mode: "normal", in: "SourceGraphic", in2: "effect1_dropShadow_4533_6792", result: "shape" })), /* @__PURE__ */ o("clipPath", { id: "paint0_diamond_4533_6792_clip_path" }, /* @__PURE__ */ o("path", { d: "M56.8701 248.593H58.8701L58.8701 32.5516H56.8701H54.8701L54.8701 248.593H56.8701ZM63.8701 25.5516V27.5516L227.68 27.5516V25.5516L227.68 23.5516L63.8701 23.5516V25.5516ZM234.68 32.5516H232.68V248.593H234.68H236.68V32.5516H234.68ZM227.68 255.593V253.593L63.8701 253.593V255.593V257.593H227.68V255.593ZM234.68 248.593H232.68C232.68 251.354 230.441 253.593 227.68 253.593V255.593V257.593C232.65 257.593 236.68 253.563 236.68 248.593H234.68ZM227.68 25.5516V27.5516C230.441 27.5516 232.68 29.7901 232.68 32.5516H234.68H236.68C236.68 27.581 232.65 23.5516 227.68 23.5516L227.68 25.5516ZM56.8701 32.5516H58.8701C58.8701 29.7902 61.1087 27.5516 63.8701 27.5516V25.5516V23.5516C58.8996 23.5516 54.8701 27.581 54.8701 32.5516H56.8701ZM56.8701 248.593H54.8701C54.8701 253.563 58.8996 257.593 63.8701 257.593V255.593V253.593C61.1087 253.593 58.8701 251.354 58.8701 248.593H56.8701Z", mask: "url(#path-4-inside-1_4533_6792)" })), /* @__PURE__ */ o("linearGradient", { id: "paint0_diamond_4533_6792", x1: 0, y1: 0, x2: 500, y2: 500, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ o("stop", { stopColor: "white" }), /* @__PURE__ */ o("stop", { offset: 1, stopColor: "white", stopOpacity: 0 }), /* @__PURE__ */ o("stop", { offset: 1, stopColor: "white", stopOpacity: 0.54 }))));
399
- function he(t) {
391
+ }, m1 = (t) => /* @__PURE__ */ o("svg", { viewBox: "0 0 292 305", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ o("circle", { cx: 145.743, cy: 152.074, r: 139.295, fill: "#E5F0FF" }), /* @__PURE__ */ o("g", { filter: "url(#filter0_d_4533_6792)" }, /* @__PURE__ */ o("path", { d: "M58.6299 32.6143C58.6299 29.8528 60.8685 27.6143 63.6299 27.6143H227.017C229.779 27.6143 232.017 29.8528 232.017 32.6143V248.24C232.017 251.002 229.779 253.24 227.017 253.24H63.6299C60.8685 253.24 58.6299 251.002 58.6299 248.24V32.6143Z", fill: "white" }), /* @__PURE__ */ o("path", { d: "M58.6299 32.6143C58.6299 29.8528 60.8685 27.6143 63.6299 27.6143H227.017C229.779 27.6143 232.017 29.8528 232.017 32.6143V248.24C232.017 251.002 229.779 253.24 227.017 253.24H63.6299C60.8685 253.24 58.6299 251.002 58.6299 248.24V32.6143Z", fill: "black", fillOpacity: 0.01 })), /* @__PURE__ */ o("g", { opacity: 0.5 }, /* @__PURE__ */ o("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M73.4139 60.0905C73.4139 59.62 73.7953 59.2385 74.2658 59.2385H216.865C217.336 59.2385 217.717 59.62 217.717 60.0905V62.7331C217.717 63.2036 217.336 63.585 216.865 63.585H74.2658C73.7953 63.585 73.4139 63.2036 73.4139 62.7331V60.0905Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M73.4139 220.911C73.4139 220.44 73.7953 220.059 74.2658 220.059H216.865C217.336 220.059 217.717 220.44 217.717 220.911V223.553C217.717 224.024 217.336 224.405 216.865 224.405H74.2658C73.7953 224.405 73.4139 224.024 73.4139 223.553V220.911Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.4139 83.5619C73.4139 83.0914 73.7953 82.7099 74.2658 82.7099H130.805C131.275 82.7099 131.657 83.0914 131.657 83.5619V91.4202C131.657 91.8907 131.275 92.2722 130.805 92.2722H74.2658C73.7953 92.2722 73.4139 91.8907 73.4139 91.4202L73.4139 83.5619Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.4138 101.817C73.4138 101.347 73.7953 100.965 74.2658 100.965H130.805C131.275 100.965 131.657 101.347 131.657 101.817V109.676C131.657 110.146 131.275 110.528 130.805 110.528H74.2658C73.7953 110.528 73.4138 110.146 73.4138 109.676L73.4138 101.817Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.399 120.072C73.4072 119.601 73.7952 119.227 74.2657 119.235L154.263 120.631C154.734 120.639 155.109 121.028 155.1 121.498L154.963 129.355C154.955 129.826 154.567 130.2 154.097 130.192L74.0988 128.796C73.6284 128.787 73.2536 128.399 73.2619 127.929L73.399 120.072Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.399 138.327C73.4072 137.857 73.7952 137.482 74.2657 137.49L97.7678 137.9C98.2383 137.909 98.613 138.297 98.6048 138.767L98.498 144.886C98.4897 145.356 98.1017 145.731 97.6313 145.723L74.1292 145.313C73.6587 145.304 73.284 144.916 73.2922 144.446L73.399 138.327Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M73.4139 38.3582C73.4139 37.8877 73.7953 37.5063 74.2658 37.5063H180.355C180.825 37.5063 181.207 37.8877 181.207 38.3582V47.0859C181.207 47.5564 180.825 47.9378 180.355 47.9378H74.2658C73.7953 47.9378 73.4139 47.5564 73.4139 47.0859V38.3582Z", fill: "#C6C8D2" }), /* @__PURE__ */ o("path", { d: "M195.985 37.4887C195.985 37.0182 196.366 36.6367 196.837 36.6367H216.865C217.336 36.6367 217.717 37.0182 217.717 37.4887V46.2163C217.717 46.6868 217.336 47.0683 216.865 47.0683H196.837C196.366 47.0683 195.985 46.6868 195.985 46.2163V37.4887Z", fill: "#C6C8D2" })), /* @__PURE__ */ o("mask", { id: "path-4-inside-1_4533_6792", fill: "white" }, /* @__PURE__ */ o("path", { d: "M63.8701 255.593C60.0041 255.593 56.8701 252.459 56.8701 248.593L56.8701 32.5516C56.8701 28.6856 60.0041 25.5516 63.8701 25.5516L227.68 25.5516C231.546 25.5516 234.68 28.6856 234.68 32.5516V248.593C234.68 252.459 231.546 255.593 227.68 255.593L63.8701 255.593Z" })), /* @__PURE__ */ o("g", { clipPath: "url(#paint0_diamond_4533_6792_clip_path)", "data-figma-skip-parse": "true", mask: "url(#path-4-inside-1_4533_6792)" }, /* @__PURE__ */ o("g", { transform: "matrix(0.0908399 -0.0986632 0.220271 0.965929 54.935 239.235)" }, /* @__PURE__ */ o("rect", { x: 0, y: 0, width: 2037.51, height: 179.024, fill: "url(#paint0_diamond_4533_6792)", opacity: 1, shapeRendering: "crispEdges" }), /* @__PURE__ */ o("rect", { x: 0, y: 0, width: 2037.51, height: 179.024, transform: "scale(1 -1)", fill: "url(#paint0_diamond_4533_6792)", opacity: 1, shapeRendering: "crispEdges" }), /* @__PURE__ */ o("rect", { x: 0, y: 0, width: 2037.51, height: 179.024, transform: "scale(-1 1)", fill: "url(#paint0_diamond_4533_6792)", opacity: 1, shapeRendering: "crispEdges" }), /* @__PURE__ */ o("rect", { x: 0, y: 0, width: 2037.51, height: 179.024, transform: "scale(-1)", fill: "url(#paint0_diamond_4533_6792)", opacity: 1, shapeRendering: "crispEdges" }))), /* @__PURE__ */ o("path", { d: "M56.8701 248.593H58.8701L58.8701 32.5516H56.8701H54.8701L54.8701 248.593H56.8701ZM63.8701 25.5516V27.5516L227.68 27.5516V25.5516L227.68 23.5516L63.8701 23.5516V25.5516ZM234.68 32.5516H232.68V248.593H234.68H236.68V32.5516H234.68ZM227.68 255.593V253.593L63.8701 253.593V255.593V257.593H227.68V255.593ZM234.68 248.593H232.68C232.68 251.354 230.441 253.593 227.68 253.593V255.593V257.593C232.65 257.593 236.68 253.563 236.68 248.593H234.68ZM227.68 25.5516V27.5516C230.441 27.5516 232.68 29.7901 232.68 32.5516H234.68H236.68C236.68 27.581 232.65 23.5516 227.68 23.5516L227.68 25.5516ZM56.8701 32.5516H58.8701C58.8701 29.7902 61.1087 27.5516 63.8701 27.5516V25.5516V23.5516C58.8996 23.5516 54.8701 27.581 54.8701 32.5516H56.8701ZM56.8701 248.593H54.8701C54.8701 253.563 58.8996 257.593 63.8701 257.593V255.593V253.593C61.1087 253.593 58.8701 251.354 58.8701 248.593H56.8701Z", "data-figma-gradient-fill": '{"type":"GRADIENT_DIAMOND","stops":[{"color":{"r":1.0,"g":1.0,"b":1.0,"a":1.0},"position":0.0},{"color":{"r":1.0,"g":1.0,"b":1.0,"a":0.0},"position":1.0},{"color":{"r":1.0,"g":1.0,"b":1.0,"a":0.54000002145767212},"position":1.0}],"stopsVar":[],"transform":{"m00":181.67984008789062,"m01":440.54235839843750,"m02":-256.17605590820312,"m10":-197.32632446289062,"m11":1931.8571777343750,"m12":-628.03063964843750},"opacity":1.0,"blendMode":"NORMAL","visible":true}', mask: "url(#path-4-inside-1_4533_6792)" }), /* @__PURE__ */ o("path", { d: "M56.8701 248.593H58.8701L58.8701 32.5516H56.8701H54.8701L54.8701 248.593H56.8701ZM63.8701 25.5516V27.5516L227.68 27.5516V25.5516L227.68 23.5516L63.8701 23.5516V25.5516ZM234.68 32.5516H232.68V248.593H234.68H236.68V32.5516H234.68ZM227.68 255.593V253.593L63.8701 253.593V255.593V257.593H227.68V255.593ZM234.68 248.593H232.68C232.68 251.354 230.441 253.593 227.68 253.593V255.593V257.593C232.65 257.593 236.68 253.563 236.68 248.593H234.68ZM227.68 25.5516V27.5516C230.441 27.5516 232.68 29.7901 232.68 32.5516H234.68H236.68C236.68 27.581 232.65 23.5516 227.68 23.5516L227.68 25.5516ZM56.8701 32.5516H58.8701C58.8701 29.7902 61.1087 27.5516 63.8701 27.5516V25.5516V23.5516C58.8996 23.5516 54.8701 27.581 54.8701 32.5516H56.8701ZM56.8701 248.593H54.8701C54.8701 253.563 58.8996 257.593 63.8701 257.593V255.593V253.593C61.1087 253.593 58.8701 251.354 58.8701 248.593H56.8701Z", fill: "white", fillOpacity: 0.5, mask: "url(#path-4-inside-1_4533_6792)" }), /* @__PURE__ */ o("defs", null, /* @__PURE__ */ o("filter", { id: "filter0_d_4533_6792", x: 34.6299, y: 6.61426, width: 221.387, height: 273.626, filterUnits: "userSpaceOnUse", colorInterpolationFilters: "sRGB" }, /* @__PURE__ */ o("feFlood", { floodOpacity: 0, result: "BackgroundImageFix" }), /* @__PURE__ */ o("feColorMatrix", { in: "SourceAlpha", type: "matrix", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0", result: "hardAlpha" }), /* @__PURE__ */ o("feOffset", { dy: 3 }), /* @__PURE__ */ o("feGaussianBlur", { stdDeviation: 12 }), /* @__PURE__ */ o("feColorMatrix", { type: "matrix", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0" }), /* @__PURE__ */ o("feBlend", { mode: "normal", in2: "BackgroundImageFix", result: "effect1_dropShadow_4533_6792" }), /* @__PURE__ */ o("feBlend", { mode: "normal", in: "SourceGraphic", in2: "effect1_dropShadow_4533_6792", result: "shape" })), /* @__PURE__ */ o("clipPath", { id: "paint0_diamond_4533_6792_clip_path" }, /* @__PURE__ */ o("path", { d: "M56.8701 248.593H58.8701L58.8701 32.5516H56.8701H54.8701L54.8701 248.593H56.8701ZM63.8701 25.5516V27.5516L227.68 27.5516V25.5516L227.68 23.5516L63.8701 23.5516V25.5516ZM234.68 32.5516H232.68V248.593H234.68H236.68V32.5516H234.68ZM227.68 255.593V253.593L63.8701 253.593V255.593V257.593H227.68V255.593ZM234.68 248.593H232.68C232.68 251.354 230.441 253.593 227.68 253.593V255.593V257.593C232.65 257.593 236.68 253.563 236.68 248.593H234.68ZM227.68 25.5516V27.5516C230.441 27.5516 232.68 29.7901 232.68 32.5516H234.68H236.68C236.68 27.581 232.65 23.5516 227.68 23.5516L227.68 25.5516ZM56.8701 32.5516H58.8701C58.8701 29.7902 61.1087 27.5516 63.8701 27.5516V25.5516V23.5516C58.8996 23.5516 54.8701 27.581 54.8701 32.5516H56.8701ZM56.8701 248.593H54.8701C54.8701 253.563 58.8996 257.593 63.8701 257.593V255.593V253.593C61.1087 253.593 58.8701 251.354 58.8701 248.593H56.8701Z", mask: "url(#path-4-inside-1_4533_6792)" })), /* @__PURE__ */ o("linearGradient", { id: "paint0_diamond_4533_6792", x1: 0, y1: 0, x2: 500, y2: 500, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ o("stop", { stopColor: "white" }), /* @__PURE__ */ o("stop", { offset: 1, stopColor: "white", stopOpacity: 0 }), /* @__PURE__ */ o("stop", { offset: 1, stopColor: "white", stopOpacity: 0.54 }))));
392
+ function h1(t) {
400
393
  return new Promise((r, i) => {
401
394
  const n = new FileReader();
402
395
  n.onload = () => r(n.result), n.onerror = i, n.readAsDataURL(t);
@@ -407,35 +400,35 @@ const L = ({
407
400
  title: r,
408
401
  text: i,
409
402
  allowSkipDocumentCapture: n,
410
- captureMode: a,
411
- error: p,
403
+ captureMode: c,
404
+ error: C,
412
405
  pageNumber: l
413
406
  }) => {
414
- const { t: c } = C(), d = b(null), [v, g] = _(!1), V = l > 1 ? "documentCapture.tutorial.multiPageDocument" : "documentCapture.tutorial", P = r?.trim() ? r : c(`${V}.title`), B = i?.trim() ? i : c(`${V}.subtitle`), w = a === "camera", m = Z(() => g(!1), []), S = () => {
415
- w ? g(!0) : d.current?.click();
407
+ const { t: a } = u(), f = b(null), [v, g] = _(!1), V = l > 1 ? "documentCapture.tutorial.multiPageDocument" : "documentCapture.tutorial", P = r?.trim() ? r : a(`${V}.title`), B = i?.trim() ? i : a(`${V}.subtitle`), w = c === "camera", p = Z(() => g(!1), []), S = () => {
408
+ w ? g(!0) : f.current?.click();
416
409
  };
417
410
  k(() => {
418
411
  if (!v) return;
419
- const s = (I) => {
420
- I.key === "Escape" && m();
412
+ const d = (I) => {
413
+ I.key === "Escape" && p();
421
414
  };
422
- return document.addEventListener("keydown", s), document.body.style.overflow = "hidden", () => {
423
- document.removeEventListener("keydown", s), document.body.style.overflow = "";
415
+ return document.addEventListener("keydown", d), document.body.style.overflow = "hidden", () => {
416
+ document.removeEventListener("keydown", d), document.body.style.overflow = "";
424
417
  };
425
- }, [v, m]);
426
- const x = async (s) => {
427
- const I = s.target, y = I.files?.[0];
418
+ }, [v, p]);
419
+ const x = async (d) => {
420
+ const I = d.target, y = I.files?.[0];
428
421
  if (y) {
429
- const O = await he(y);
430
- t.setFile(y, O), w && m();
422
+ const O = await h1(y);
423
+ t.setFile(y, O), w && p();
431
424
  }
432
425
  I.value = "";
433
426
  }, R = () => {
434
- m(), t.capture();
427
+ p(), t.capture();
435
428
  }, F = () => {
436
- d.current?.click();
429
+ f.current?.click();
437
430
  };
438
- return /* @__PURE__ */ e(f, { children: [
431
+ return /* @__PURE__ */ e(h, { children: [
439
432
  /* @__PURE__ */ e(
440
433
  H,
441
434
  {
@@ -447,7 +440,7 @@ const L = ({
447
440
  /* @__PURE__ */ e(
448
441
  "input",
449
442
  {
450
- ref: d,
443
+ ref: f,
451
444
  type: "file",
452
445
  accept: "image/*,application/pdf",
453
446
  onChange: x,
@@ -456,24 +449,24 @@ const L = ({
456
449
  class: "IncodeDocumentCaptureFileInput"
457
450
  }
458
451
  ),
459
- /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureTutorialContent", children: /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureTutorialIllustration", "aria-hidden": !0, children: /* @__PURE__ */ e(me, { class: "IncodeDocumentCaptureTutorialImage" }) }) }),
460
- p ? /* @__PURE__ */ e("p", { class: "IncodeDocumentCaptureError", role: "alert", children: c("nativeCamera.maximumSize") }) : null,
452
+ /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureTutorialContent", children: /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureTutorialIllustration", "aria-hidden": !0, children: /* @__PURE__ */ e(m1, { class: "IncodeDocumentCaptureTutorialImage" }) }) }),
453
+ C ? /* @__PURE__ */ e("p", { class: "IncodeDocumentCaptureError", role: "alert", children: a("nativeCamera.maximumSize") }) : null,
461
454
  /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureActions", children: [
462
455
  /* @__PURE__ */ e(
463
- h,
456
+ m,
464
457
  {
465
458
  onClick: S,
466
459
  "data-testid": "document-capture-continue-button",
467
- children: c("documentCapture.tutorial.continue")
460
+ children: a("documentCapture.tutorial.continue")
468
461
  }
469
462
  ),
470
463
  n ? /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureSkipWrapper", children: /* @__PURE__ */ e(
471
- h,
464
+ m,
472
465
  {
473
466
  variant: "link",
474
467
  onClick: () => t.skip(),
475
468
  "data-testid": "document-capture-skip-button",
476
- children: c("documentCapture.tutorial.skipButton")
469
+ children: a("documentCapture.tutorial.skipButton")
477
470
  }
478
471
  ) }) : null
479
472
  ] })
@@ -487,19 +480,19 @@ const L = ({
487
480
  role: "dialog",
488
481
  "aria-modal": !0,
489
482
  "aria-labelledby": "document-capture-choice-heading",
490
- onClick: (s) => {
491
- s.target === s.currentTarget && m();
483
+ onClick: (d) => {
484
+ d.target === d.currentTarget && p();
492
485
  },
493
486
  children: /* @__PURE__ */ e(
494
487
  "div",
495
488
  {
496
489
  class: "IncodeDocumentCaptureBottomSheetContainer",
497
- onClick: m,
490
+ onClick: p,
498
491
  children: /* @__PURE__ */ e(
499
492
  "div",
500
493
  {
501
494
  class: "IncodeDocumentCaptureBottomSheet",
502
- onClick: (s) => s.stopPropagation(),
495
+ onClick: (d) => d.stopPropagation(),
503
496
  children: [
504
497
  /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureBottomSheetHandle", "aria-hidden": !0 }),
505
498
  /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureBottomSheetOptions", children: [
@@ -512,7 +505,7 @@ const L = ({
512
505
  "data-testid": "document-capture-camera-option",
513
506
  children: [
514
507
  /* @__PURE__ */ e(J, {}),
515
- /* @__PURE__ */ e("span", { children: c("documentCapture.tutorial.takePhoto") })
508
+ /* @__PURE__ */ e("span", { children: a("documentCapture.tutorial.takePhoto") })
516
509
  ]
517
510
  }
518
511
  ),
@@ -525,7 +518,7 @@ const L = ({
525
518
  "data-testid": "document-capture-file-option",
526
519
  children: [
527
520
  /* @__PURE__ */ e(Q, {}),
528
- /* @__PURE__ */ e("span", { children: c("documentCapture.tutorial.uploadDocument") })
521
+ /* @__PURE__ */ e("span", { children: a("documentCapture.tutorial.uploadDocument") })
529
522
  ]
530
523
  }
531
524
  )
@@ -538,20 +531,20 @@ const L = ({
538
531
  }
539
532
  ) : null
540
533
  ] });
541
- }, fe = ({
534
+ }, f1 = ({
542
535
  config: t,
543
536
  onFinish: r,
544
537
  onError: i
545
538
  }) => {
546
- const [n, a] = T(
539
+ const [n, c] = T(
547
540
  () => N({ config: t })
548
- ), [p, l] = _(!1);
541
+ ), [C, l] = _(!1);
549
542
  return k(() => {
550
543
  n.status === "finished" && r?.(), n.status === "closed" && i?.(void 0);
551
544
  }, [n.status, r, i]), n.status === "tutorial" ? /* @__PURE__ */ e(
552
545
  L,
553
546
  {
554
- manager: a,
547
+ manager: c,
555
548
  title: n.title,
556
549
  text: n.text,
557
550
  allowSkipDocumentCapture: n.allowSkipDocumentCapture,
@@ -562,7 +555,7 @@ const L = ({
562
555
  ) : n.status === "capturing" && n.captureMode === "file" ? /* @__PURE__ */ e(
563
556
  L,
564
557
  {
565
- manager: a,
558
+ manager: c,
566
559
  title: t.title,
567
560
  text: t.text,
568
561
  allowSkipDocumentCapture: !1,
@@ -570,16 +563,16 @@ const L = ({
570
563
  error: n.error,
571
564
  pageNumber: n.pageNumber
572
565
  }
573
- ) : n.status === "initializingCamera" ? /* @__PURE__ */ e(H, { hideHeader: !0, hideFooterBranding: !0, className: "IncodeDocumentCapturePage", children: /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureCentered", children: /* @__PURE__ */ e(M, { size: "large" }) }) }) : n.status === "capturing" && n.captureMode === "camera" ? n.stream ? /* @__PURE__ */ e(f, { children: [
566
+ ) : n.status === "initializingCamera" ? /* @__PURE__ */ e(H, { hideHeader: !0, hideFooterBranding: !0, className: "IncodeDocumentCapturePage", children: /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureCentered", children: /* @__PURE__ */ e(M, { size: "large" }) }) }) : n.status === "capturing" && n.captureMode === "camera" ? n.stream ? /* @__PURE__ */ e(h, { children: [
574
567
  /* @__PURE__ */ e(
575
- te,
568
+ t1,
576
569
  {
577
570
  stream: n.stream,
578
- manager: a,
571
+ manager: c,
579
572
  onOpenHelp: () => l(!0)
580
573
  }
581
574
  ),
582
- p ? /* @__PURE__ */ e(ce, { onClose: () => l(!1) }) : null
575
+ C ? /* @__PURE__ */ e(c1, { onClose: () => l(!1) }) : null
583
576
  ] }) : /* @__PURE__ */ e(
584
577
  H,
585
578
  {
@@ -588,27 +581,20 @@ const L = ({
588
581
  className: "IncodeDocumentCapturePage",
589
582
  children: /* @__PURE__ */ e("div", { class: "IncodeDocumentCaptureCentered", children: /* @__PURE__ */ e(M, { size: "large" }) })
590
583
  }
591
- ) : n.status === "preview" || n.status === "uploading" || n.status === "success" || n.status === "failure" ? /* @__PURE__ */ e(
592
- pe,
593
- {
594
- state: n,
595
- manager: a,
596
- captureMode: t.captureMode ?? "camera"
597
- }
598
- ) : null;
599
- }, ve = ({
584
+ ) : n.status === "preview" || n.status === "uploading" || n.status === "success" || n.status === "failure" ? /* @__PURE__ */ e(p1, { state: n, manager: c }) : null;
585
+ }, v1 = ({
600
586
  config: t,
601
587
  onFinish: r,
602
588
  onError: i
603
589
  }) => /* @__PURE__ */ e(E, { children: t ? /* @__PURE__ */ e(
604
- fe,
590
+ f1,
605
591
  {
606
592
  config: t,
607
593
  onFinish: r,
608
594
  onError: i
609
595
  }
610
596
  ) : null });
611
- z(ve, "incode-document-capture");
597
+ z(v1, "incode-document-capture");
612
598
  export {
613
- ve as DocumentCapture
599
+ v1 as DocumentCapture
614
600
  };
@@ -10,7 +10,7 @@ import { D as ee } from "./dropdownComposed-B5ZuQS8C.js";
10
10
  import { P as T } from "./page-BVHG3h0V.js";
11
11
  import { S as re } from "./spinner-Cx3FPUCD.js";
12
12
  import { r as oe } from "./incodeModule-aE-LkKwM.js";
13
- import { P as te } from "./phoneInputComposed-CwtJKvGh.js";
13
+ import { P as te } from "./phoneInputComposed-BG1BANDW.js";
14
14
  const ae = ({ config: p, onFinish: s }) => {
15
15
  const { t: l } = $(), [a, d] = G(() => z({ config: p }));
16
16
  return q(() => {
@@ -12,14 +12,14 @@ import { a as Oe, I as je } from "./inputComposed-BHi-MSpP.js";
12
12
  import { O as qe } from "./otpInput-DdkvlvCS.js";
13
13
  import { D as f, d as W, A as $, y as R, q as O } from "./vendor-preact-BXf0bkEs.js";
14
14
  import { E as w } from "./errorIcon-BL647nVh.js";
15
- import { P as Ne } from "./phoneInputComposed-CwtJKvGh.js";
15
+ import { P as Ne } from "./phoneInputComposed-BG1BANDW.js";
16
16
  import { D as Ge, S as Je } from "./dropdownComposed-B5ZuQS8C.js";
17
17
  import { C as Qe, D as Xe } from "./dateInputComposed-CvFmQpJ0.js";
18
18
  import { S as j } from "./successIcon-BybULRRU.js";
19
19
  import { B as _e, L as ea, P as aa } from "./permissions-BDElyTL4.js";
20
20
  import { C as oa } from "./chevronDown-BUaOuf9J.js";
21
21
  import { C as ta } from "./closeIcon-BM7WLbKp.js";
22
- import { c as ca, a as da, g as ia } from "./countries-C9bhJe4u.js";
22
+ import { c as ca, b as da, g as ia } from "./countries-CM1cm_kP.js";
23
23
  import { C as pa, T as ha } from "./tutorial-D8y4KZtv.js";
24
24
  import { a as ua, C as ma, b as xa, I as Ia, F as ba, T as fa } from "./flipAnimation-CSNIRlbv.js";
25
25
  const U = ({ size: a = 28 }) => /* @__PURE__ */ e(
@@ -7,7 +7,7 @@ import { r as Tt } from "../incodeModule-aE-LkKwM.js";
7
7
  import { S as x } from "../spinner-Cx3FPUCD.js";
8
8
  import { createRedirectToMobileManager as Jt } from "@incodetech/core/redirect-to-mobile";
9
9
  import { S as Mt } from "../successIcon-BybULRRU.js";
10
- import { a as xt } from "../countries-C9bhJe4u.js";
10
+ import { b as xt } from "../countries-CM1cm_kP.js";
11
11
  import { T as Qt } from "../Trans-CA9a3vKp.js";
12
12
  import { ekybMachine as Wt } from "@incodetech/core/ekyb";
13
13
  import { ekycMachine as Xt } from "@incodetech/core/ekyc";
@@ -1672,7 +1672,7 @@ const _n = ({
1672
1672
  ) })
1673
1673
  ] });
1674
1674
  }, Vn = jt(
1675
- () => import("../phoneInput-Duuochsh.js").then((e) => ({ default: e.PhoneInput }))
1675
+ () => import("../phoneInput-D4yirBZy.js").then((e) => ({ default: e.PhoneInput }))
1676
1676
  ), zn = ({
1677
1677
  countryCode: e,
1678
1678
  phonePrefix: t,
@@ -2000,12 +2000,12 @@ const Pe = () => import("../id/id.es.js").then((e) => e.Id), ke = {
2000
2000
  (e) => e.GovernmentValidation
2001
2001
  ),
2002
2002
  GEOLOCATION: () => import("../geolocation/geolocation.es.js").then((e) => e.Geolocation),
2003
- EXTERNAL_VERIFICATION: () => import("../ekycModule-CzPxqzT6.js").then((e) => e.EkycModule),
2003
+ EXTERNAL_VERIFICATION: () => import("../ekycModule-DBCar_-Z.js").then((e) => e.EkycModule),
2004
2004
  EKYB: () => import("../ekybModule-9m8cnkfH.js").then((e) => e.EkybModule),
2005
- DOCUMENT_CAPTURE: () => import("../documentCapture-PdKA2frR.js").then(
2005
+ DOCUMENT_CAPTURE: () => import("../documentCapture-D83yNhHB.js").then(
2006
2006
  (e) => e.DocumentCapture
2007
2007
  ),
2008
- ADDRESS: () => import("../documentCapture-PdKA2frR.js").then(
2008
+ ADDRESS: () => import("../documentCapture-D83yNhHB.js").then(
2009
2009
  (e) => e.DocumentCapture
2010
2010
  )
2011
2011
  };
@@ -6,7 +6,7 @@ import "@incodetech/core";
6
6
  import { O as y } from "../otpInput-DdkvlvCS.js";
7
7
  import { P as m } from "../page-BVHG3h0V.js";
8
8
  import { r as w } from "../incodeModule-aE-LkKwM.js";
9
- import { PhoneInput as k } from "../phoneInput-Duuochsh.js";
9
+ import { PhoneInput as k } from "../phoneInput-D4yirBZy.js";
10
10
  const B = ({
11
11
  config: n,
12
12
  manager: r,
@@ -1,8 +1,8 @@
1
1
  import { u as n, S } from "./button-Ca1tRSTI.js";
2
2
  import { d as p, A as D, y as u, k as $ } from "./vendor-preact-BXf0bkEs.js";
3
- import { g as b, c as g } from "./countries-C9bhJe4u.js";
3
+ import { g as b, c as g } from "./countries-CM1cm_kP.js";
4
4
  import { C as z } from "./chevronDown-BUaOuf9J.js";
5
- import { p as k, A } from "./AsYouType-CpH-Rmtj.js";
5
+ import { p as k, A } from "./AsYouType-DoYUSTc1.js";
6
6
  const M = ({
7
7
  countryCode: P,
8
8
  prefilledPhone: a,
@@ -0,0 +1,184 @@
1
+ import { u as t } from "./button-Ca1tRSTI.js";
2
+ import { D as J, d as b, A as x, T as f, y as Q, q as A } from "./vendor-preact-BXf0bkEs.js";
3
+ import { w as X, g as C, c as j, a as z } from "./countries-CM1cm_kP.js";
4
+ import { D as k } from "./dropdownComposed-B5ZuQS8C.js";
5
+ import { E as q } from "./errorIcon-BL647nVh.js";
6
+ import { S as _ } from "./successIcon-BybULRRU.js";
7
+ import { I as e2 } from "./inputComposed-BHi-MSpP.js";
8
+ import { P as o2, p as L, A as y } from "./AsYouType-DoYUSTc1.js";
9
+ function n2(n, r, s) {
10
+ if (r[n])
11
+ return new o2(n, r[n], s);
12
+ }
13
+ function t2() {
14
+ return X(n2, arguments);
15
+ }
16
+ const r2 = { AC: "40123", AD: "312345", AE: "501234567", AF: "701234567", AG: "2684641234", AI: "2642351234", AL: "672123456", AM: "77123456", AO: "923123456", AR: "91123456789", AS: "6847331234", AT: "664123456", AU: "412345678", AW: "5601234", AX: "412345678", AZ: "401234567", BA: "61123456", BB: "2462501234", BD: "1812345678", BE: "470123456", BF: "70123456", BG: "43012345", BH: "36001234", BI: "79561234", BJ: "0195123456", BL: "690001234", BM: "4413701234", BN: "7123456", BO: "71234567", BQ: "3181234", BR: "11961234567", BS: "2423591234", BT: "17123456", BW: "71123456", BY: "294911911", BZ: "6221234", CA: "5062345678", CC: "412345678", CD: "991234567", CF: "70012345", CG: "061234567", CH: "781234567", CI: "0123456789", CK: "71234", CL: "221234567", CM: "671234567", CN: "13123456789", CO: "3211234567", CR: "83123456", CU: "51234567", CV: "9911234", CW: "95181234", CX: "412345678", CY: "96123456", CZ: "601123456", DE: "15123456789", DJ: "77831001", DK: "34412345", DM: "7672251234", DO: "8092345678", DZ: "551234567", EC: "991234567", EE: "51234567", EG: "1001234567", EH: "650123456", ER: "7123456", ES: "612345678", ET: "911234567", FI: "412345678", FJ: "7012345", FK: "51234", FM: "3501234", FO: "211234", FR: "612345678", GA: "06031234", GB: "7400123456", GD: "4734031234", GE: "555123456", GF: "694201234", GG: "7781123456", GH: "231234567", GI: "57123456", GL: "221234", GM: "3012345", GN: "601123456", GP: "690001234", GQ: "222123456", GR: "6912345678", GT: "51234567", GU: "6713001234", GW: "955012345", GY: "6091234", HK: "51234567", HN: "91234567", HR: "921234567", HT: "34101234", HU: "201234567", ID: "812345678", IE: "850123456", IL: "502345678", IM: "7924123456", IN: "8123456789", IO: "3801234", IQ: "7912345678", IR: "9123456789", IS: "6111234", IT: "3123456789", JE: "7797712345", JM: "8762101234", JO: "790123456", JP: "9012345678", KE: "712123456", KG: "700123456", KH: "91234567", KI: "72001234", KM: "3212345", KN: "8697652917", KP: "1921234567", KR: "1020000000", KW: "50012345", KY: "3453231234", KZ: "7710009998", LA: "2023123456", LB: "71123456", LC: "7582845678", LI: "660234567", LK: "712345678", LR: "770123456", LS: "50123456", LT: "61234567", LU: "628123456", LV: "21234567", LY: "912345678", MA: "650123456", MC: "612345678", MD: "62112345", ME: "60123456", MF: "690001234", MG: "321234567", MH: "2351234", MK: "72345678", ML: "65012345", MM: "92123456", MN: "88123456", MO: "66123456", MP: "6702345678", MQ: "696201234", MR: "22123456", MS: "6644923456", MT: "96961234", MU: "52512345", MV: "7712345", MW: "991234567", MX: "2221234567", MY: "123456789", MZ: "821234567", NA: "811234567", NC: "751234", NE: "93123456", NF: "381234", NG: "8021234567", NI: "81234567", NL: "612345678", NO: "40612345", NP: "9841234567", NR: "5551234", NU: "8884012", NZ: "211234567", OM: "92123456", PA: "61234567", PE: "912345678", PF: "87123456", PG: "70123456", PH: "9051234567", PK: "3012345678", PL: "512345678", PM: "551234", PR: "7872345678", PS: "599123456", PT: "912345678", PW: "6201234", PY: "961456789", QA: "33123456", RE: "692123456", RO: "712034567", RS: "601234567", RU: "9123456789", RW: "720123456", SA: "512345678", SB: "7421234", SC: "2510123", SD: "911231234", SE: "701234567", SG: "81234567", SH: "51234", SI: "31234567", SJ: "41234567", SK: "912123456", SL: "25123456", SM: "66661212", SN: "701234567", SO: "71123456", SR: "7412345", SS: "977123456", ST: "9812345", SV: "70123456", SX: "7215205678", SY: "944567890", SZ: "76123456", TA: "8999", TC: "6492311234", TD: "63012345", TG: "90112345", TH: "812345678", TJ: "917123456", TK: "7290", TL: "77212345", TM: "66123456", TN: "20123456", TO: "7715123", TR: "5012345678", TT: "8682911234", TV: "901234", TW: "912345678", TZ: "621234567", UA: "501234567", UG: "712345678", US: "2015550123", UY: "94231234", UZ: "912345678", VA: "3123456789", VC: "7844301234", VE: "4121234567", VG: "2843001234", VI: "3406421234", VN: "912345678", VU: "5912345", WF: "821234", WS: "7212345", XK: "43201234", YE: "712345678", YT: "639012345", ZA: "711234567", ZM: "955123456", ZW: "712345678" };
17
+ function K(n, r, s) {
18
+ return new y(s).input(`${r}${n}`).replace(r, "").trimStart();
19
+ }
20
+ function s2(n) {
21
+ const r = t2(n, r2);
22
+ if (!r) return "";
23
+ const s = `+${z(n)}`;
24
+ return K(r.nationalNumber, s, n);
25
+ }
26
+ const a2 = J(
27
+ ({
28
+ id: n,
29
+ label: r,
30
+ countryCode: s = "US",
31
+ value: l,
32
+ placeholder: I,
33
+ error: i,
34
+ helper: h,
35
+ showErrorIcon: R,
36
+ showHelperIcon: D,
37
+ disabled: N = !1,
38
+ disableCountrySelector: $ = !1,
39
+ required: P,
40
+ onChange: M,
41
+ "aria-labelledby": g,
42
+ "data-testid": W,
43
+ ...F
44
+ }, H) => {
45
+ const [a, G] = b(s), [p, S] = b(""), T = x(!1), U = f(
46
+ () => j.map((o) => ({
47
+ value: o.code,
48
+ label: `${o.emoji} ${o.callingCode} ${o.name}`
49
+ })),
50
+ []
51
+ ), c = f(
52
+ () => C(a) ?? C("US"),
53
+ [a]
54
+ ), O = f(
55
+ () => I ?? s2(a),
56
+ [I, a]
57
+ );
58
+ Q(() => {
59
+ if (T.current || !l || !c) return;
60
+ T.current = !0;
61
+ const o = l.startsWith("+") ? l : `+${l}`, e = L(o);
62
+ if (e?.isValid() && e.country) {
63
+ e.country !== a && G(e.country);
64
+ const d = new y(e.country);
65
+ S(d.input(e.nationalNumber));
66
+ }
67
+ }, [l, c, a]);
68
+ const u = A(
69
+ (o, e) => {
70
+ const d = `${e.callingCode}${o.replace(/\D/g, "")}`;
71
+ try {
72
+ const Y = L(d, e.code);
73
+ M?.(d, Y?.isValid() ?? !1);
74
+ } catch {
75
+ M?.(d, !1);
76
+ }
77
+ },
78
+ [M]
79
+ ), V = A(
80
+ (o) => {
81
+ G(o);
82
+ const e = C(o);
83
+ e && p && u(p, e);
84
+ },
85
+ [p, u]
86
+ ), Z = A(
87
+ (o) => {
88
+ const e = o.target.value;
89
+ if (!c) {
90
+ S(e);
91
+ return;
92
+ }
93
+ const d = K(
94
+ e,
95
+ c.callingCode,
96
+ c.code
97
+ );
98
+ S(d), u(e, c);
99
+ },
100
+ [c, u]
101
+ ), v = `${n}-country`, m = `${n}-phone`, E = `${m}-helper`, B = `${m}-error`, w = [h ? E : null, i ? B : null].filter(Boolean).join(" ");
102
+ return /* @__PURE__ */ t("div", { class: "IncodePhoneInputComposed", children: [
103
+ r && /* @__PURE__ */ t(
104
+ "label",
105
+ {
106
+ class: "IncodePhoneInputComposedLabel",
107
+ htmlFor: m,
108
+ "data-testid": `${n}-label`,
109
+ children: [
110
+ r,
111
+ P && /* @__PURE__ */ t("span", { class: "IncodePhoneInputComposedRequired", children: " *" })
112
+ ]
113
+ }
114
+ ),
115
+ /* @__PURE__ */ t(
116
+ k,
117
+ {
118
+ id: v,
119
+ options: U,
120
+ value: a,
121
+ onChange: V,
122
+ disabled: N || $,
123
+ required: P,
124
+ searchable: !0,
125
+ searchPlaceholder: "Search countries...",
126
+ suppressMessages: !0,
127
+ "aria-label": "Select country code",
128
+ renderSelectedLabel: (o) => {
129
+ const e = C(o.value);
130
+ return e ? `${e.emoji} ${e.callingCode}` : o.label;
131
+ },
132
+ class: "IncodePhoneInputComposedDropdown",
133
+ siblingElement: /* @__PURE__ */ t(
134
+ e2,
135
+ {
136
+ id: m,
137
+ ref: H,
138
+ type: "tel",
139
+ value: p,
140
+ onInput: Z,
141
+ placeholder: O,
142
+ error: i,
143
+ disabled: N,
144
+ required: P,
145
+ suppressMessages: !0,
146
+ "aria-label": r ? void 0 : "Phone number",
147
+ "aria-labelledby": g,
148
+ "aria-describedby": w || void 0,
149
+ "aria-invalid": i ? "true" : void 0,
150
+ "data-testid": W,
151
+ ...F
152
+ }
153
+ )
154
+ }
155
+ ),
156
+ i && /* @__PURE__ */ t(
157
+ "div",
158
+ {
159
+ class: "IncodePhoneInputComposedErrorWrapper",
160
+ "data-testid": `${n}-error-wrapper`,
161
+ children: [
162
+ R && /* @__PURE__ */ t("div", { class: "IncodePhoneInputComposedIconWrapper", children: /* @__PURE__ */ t(q, { size: 16 }) }),
163
+ /* @__PURE__ */ t("p", { id: B, class: "IncodePhoneInputComposedError", children: i })
164
+ ]
165
+ }
166
+ ),
167
+ h && !i && /* @__PURE__ */ t(
168
+ "div",
169
+ {
170
+ class: "IncodePhoneInputComposedHelperWrapper",
171
+ "data-testid": `${n}-helper-wrapper`,
172
+ children: [
173
+ D && /* @__PURE__ */ t("div", { class: "IncodePhoneInputComposedIconWrapper", children: /* @__PURE__ */ t(_, { size: 16 }) }),
174
+ /* @__PURE__ */ t("p", { id: E, class: "IncodePhoneInputComposedHelper", children: h })
175
+ ]
176
+ }
177
+ )
178
+ ] });
179
+ }
180
+ );
181
+ a2.displayName = "PhoneInputComposed";
182
+ export {
183
+ a2 as P
184
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@incodetech/web",
3
- "version": "0.0.0-dev-20260318-deddf15",
3
+ "version": "0.0.0-dev-20260318-ce9c1ed",
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-20260318-deddf15"
122
+ "@incodetech/core": "0.0.0-dev-20260318-ce9c1ed"
123
123
  },
124
124
  "devDependencies": {
125
125
  "@microsoft/api-extractor": "^7.53.3",
@@ -1,160 +0,0 @@
1
- import { u as n } from "./button-Ca1tRSTI.js";
2
- import { D as Y, d as S, A as k, T as D, y as q, q as y } from "./vendor-preact-BXf0bkEs.js";
3
- import { g as u, c as G } from "./countries-C9bhJe4u.js";
4
- import { D as J } from "./dropdownComposed-B5ZuQS8C.js";
5
- import { E as K } from "./errorIcon-BL647nVh.js";
6
- import { S as Q } from "./successIcon-BybULRRU.js";
7
- import { I as X } from "./inputComposed-BHi-MSpP.js";
8
- import { A as E, p as W } from "./AsYouType-CpH-Rmtj.js";
9
- const Z = Y(
10
- ({
11
- id: a,
12
- label: m,
13
- countryCode: A = "US",
14
- value: c,
15
- placeholder: N = "(123) 123-6789",
16
- error: r,
17
- helper: h,
18
- showErrorIcon: j,
19
- showHelperIcon: B,
20
- disabled: P = !1,
21
- disableCountrySelector: L = !1,
22
- required: I,
23
- onChange: f,
24
- "aria-labelledby": T,
25
- "data-testid": x,
26
- ...z
27
- }, F) => {
28
- const [d, b] = S(A), [l, C] = S(""), $ = k(!1), H = D(
29
- () => G.map((o) => ({
30
- value: o.code,
31
- label: `${o.emoji} ${o.callingCode} ${o.name}`
32
- })),
33
- []
34
- ), t = D(
35
- () => u(d) ?? u("US"),
36
- [d]
37
- );
38
- q(() => {
39
- if ($.current || !c || !t) return;
40
- $.current = !0;
41
- const o = c.startsWith("+") ? c : `+${c}`, e = W(o);
42
- if (e?.isValid() && e.country) {
43
- e.country !== d && b(e.country);
44
- const s = new E(e.country);
45
- C(s.input(e.nationalNumber));
46
- }
47
- }, [c, t, d]);
48
- const p = y(
49
- (o, e) => {
50
- const s = `${e.callingCode}${o.replace(/\D/g, "")}`;
51
- try {
52
- const w = W(s, e.code);
53
- f?.(s, w?.isValid() ?? !1);
54
- } catch {
55
- f?.(s, !1);
56
- }
57
- },
58
- [f]
59
- ), M = y(
60
- (o) => {
61
- b(o);
62
- const e = u(o);
63
- e && l && p(l, e);
64
- },
65
- [l, p]
66
- ), U = y(
67
- (o) => {
68
- const e = o.target.value;
69
- if (!t) {
70
- C(e);
71
- return;
72
- }
73
- const s = `${t.callingCode}${e}`, R = new E(t.code).input(s).replace(t.callingCode, "").trimStart();
74
- C(R), p(e, t);
75
- },
76
- [t, p]
77
- ), V = `${a}-country`, i = `${a}-phone`, g = `${i}-helper`, v = `${i}-error`, O = [h ? g : null, r ? v : null].filter(Boolean).join(" ");
78
- return /* @__PURE__ */ n("div", { class: "IncodePhoneInputComposed", children: [
79
- m && /* @__PURE__ */ n(
80
- "label",
81
- {
82
- class: "IncodePhoneInputComposedLabel",
83
- htmlFor: i,
84
- "data-testid": `${a}-label`,
85
- children: [
86
- m,
87
- I && /* @__PURE__ */ n("span", { class: "IncodePhoneInputComposedRequired", children: " *" })
88
- ]
89
- }
90
- ),
91
- /* @__PURE__ */ n(
92
- J,
93
- {
94
- id: V,
95
- options: H,
96
- value: d,
97
- onChange: M,
98
- disabled: P || L,
99
- required: I,
100
- searchable: !0,
101
- searchPlaceholder: "Search countries...",
102
- suppressMessages: !0,
103
- "aria-label": "Select country code",
104
- renderSelectedLabel: (o) => {
105
- const e = u(o.value);
106
- return e ? `${e.emoji} ${e.callingCode}` : o.label;
107
- },
108
- class: "IncodePhoneInputComposedDropdown",
109
- siblingElement: /* @__PURE__ */ n(
110
- X,
111
- {
112
- id: i,
113
- ref: F,
114
- type: "tel",
115
- value: l,
116
- onInput: U,
117
- placeholder: N,
118
- error: r,
119
- disabled: P,
120
- required: I,
121
- suppressMessages: !0,
122
- "aria-label": m ? void 0 : "Phone number",
123
- "aria-labelledby": T,
124
- "aria-describedby": O || void 0,
125
- "aria-invalid": r ? "true" : void 0,
126
- "data-testid": x,
127
- ...z
128
- }
129
- )
130
- }
131
- ),
132
- r && /* @__PURE__ */ n(
133
- "div",
134
- {
135
- class: "IncodePhoneInputComposedErrorWrapper",
136
- "data-testid": `${a}-error-wrapper`,
137
- children: [
138
- j && /* @__PURE__ */ n("div", { class: "IncodePhoneInputComposedIconWrapper", children: /* @__PURE__ */ n(K, { size: 16 }) }),
139
- /* @__PURE__ */ n("p", { id: v, class: "IncodePhoneInputComposedError", children: r })
140
- ]
141
- }
142
- ),
143
- h && !r && /* @__PURE__ */ n(
144
- "div",
145
- {
146
- class: "IncodePhoneInputComposedHelperWrapper",
147
- "data-testid": `${a}-helper-wrapper`,
148
- children: [
149
- B && /* @__PURE__ */ n("div", { class: "IncodePhoneInputComposedIconWrapper", children: /* @__PURE__ */ n(Q, { size: 16 }) }),
150
- /* @__PURE__ */ n("p", { id: g, class: "IncodePhoneInputComposedHelper", children: h })
151
- ]
152
- }
153
- )
154
- ] });
155
- }
156
- );
157
- Z.displayName = "PhoneInputComposed";
158
- export {
159
- Z as P
160
- };