@incodetech/web 0.0.0-dev-20260303-3dab9f2 → 0.0.0-dev-20260304-fb1914c

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.
@@ -3336,6 +3336,10 @@
3336
3336
  position: absolute;
3337
3337
  }
3338
3338
 
3339
+ .IncodeIdCapturePage .IncodeCapture .IncodeCaptureVideo.IncodeCaptureVideoLoading {
3340
+ opacity: 0;
3341
+ }
3342
+
3339
3343
  .IncodeIdCapturePage .IncodeCapture .IncodeCaptureVideo .IncodeCaptureVideoElement {
3340
3344
  inset: var(--spacing-0, var(--spacing-none, 0px));
3341
3345
  object-fit: cover;
package/dist/id/id.es.js CHANGED
@@ -1,14 +1,14 @@
1
- import { u as e, S as C, B as I, c as f, r as A, a as R } from "../incodeModule-_kfNnq5z.js";
2
- import { createIdCaptureManager as z } from "@incodetech/core/id";
3
- import { d as L, y as m, k as U, D as N, A as Z } from "../vendor-preact-BDue3y7V.js";
1
+ import { u as e, S as C, B as m, c as v, r as U, a as N } from "../incodeModule-_kfNnq5z.js";
2
+ import { createIdCaptureManager as O } from "@incodetech/core/id";
3
+ import { d as g, y as w, k as _, D as G, A as E } from "../vendor-preact-BDue3y7V.js";
4
4
  import "@incodetech/core";
5
- import { L as b, B as O, P as G } from "../baseTutorial-Bbadb04i.js";
6
- import { P as x, I as $ } from "../incodeComponent-DSqGVqSo.js";
7
- import { P as K } from "../processing-BuaxyhmY.js";
5
+ import { L as Z, B as $, P as K } from "../baseTutorial-Bbadb04i.js";
6
+ import { P as x, I as Q } from "../incodeComponent-DSqGVqSo.js";
7
+ import { P as j } from "../processing-BuaxyhmY.js";
8
8
  import "../instance-B-q0ZREN.js";
9
- import { u as c } from "../useTranslation-B1jrtqlW.js";
10
- import { T as _, S as Q } from "../spinner-Ogo-u91P.js";
11
- const j = ({ className: n }) => /* @__PURE__ */ e(
9
+ import { u as d } from "../useTranslation-B1jrtqlW.js";
10
+ import { T as k, S as F } from "../spinner-Ogo-u91P.js";
11
+ const q = ({ className: n }) => /* @__PURE__ */ e(
12
12
  "svg",
13
13
  {
14
14
  width: "24",
@@ -56,7 +56,7 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
56
56
  )
57
57
  ]
58
58
  }
59
- ), q = ({ className: n }) => /* @__PURE__ */ e(
59
+ ), J = ({ className: n }) => /* @__PURE__ */ e(
60
60
  "svg",
61
61
  {
62
62
  width: "24",
@@ -74,7 +74,7 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
74
74
  }
75
75
  )
76
76
  }
77
- ), J = ({ className: n }) => /* @__PURE__ */ e(
77
+ ), W = ({ className: n }) => /* @__PURE__ */ e(
78
78
  "svg",
79
79
  {
80
80
  width: "24",
@@ -115,7 +115,7 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
115
115
  )
116
116
  ]
117
117
  }
118
- ), W = ({
118
+ ), X = ({
119
119
  className: n
120
120
  }) => /* @__PURE__ */ e(
121
121
  "svg",
@@ -166,7 +166,7 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
166
166
  )
167
167
  ]
168
168
  }
169
- ), X = ({ className: n }) => /* @__PURE__ */ e(
169
+ ), Y = ({ className: n }) => /* @__PURE__ */ e(
170
170
  "svg",
171
171
  {
172
172
  width: "64",
@@ -187,12 +187,12 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
187
187
  )
188
188
  ]
189
189
  }
190
- ), Y = ({
190
+ ), e1 = ({
191
191
  onClose: n,
192
- onTakeManually: i
192
+ onTakeManually: t
193
193
  }) => {
194
- const { t } = c(), r = () => {
195
- i(), n();
194
+ const { t: i } = d(), r = () => {
195
+ t(), n();
196
196
  };
197
197
  return /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesModal", children: /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesModalContent", children: [
198
198
  /* @__PURE__ */ e("header", { class: "IncodeCommonIssuesHeader", children: /* @__PURE__ */ e(
@@ -201,53 +201,53 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
201
201
  type: "button",
202
202
  class: "IncodeCommonIssuesCloseButton",
203
203
  onClick: n,
204
- "aria-label": t("commonIssues.close"),
205
- children: /* @__PURE__ */ e(q, {})
204
+ "aria-label": i("commonIssues.close"),
205
+ children: /* @__PURE__ */ e(J, {})
206
206
  }
207
207
  ) }),
208
208
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesContent", children: [
209
- /* @__PURE__ */ e(X, { className: "IncodeCommonIssuesQuestionIcon" }),
209
+ /* @__PURE__ */ e(Y, { className: "IncodeCommonIssuesQuestionIcon" }),
210
210
  /* @__PURE__ */ e(C, { size: 12 }),
211
- /* @__PURE__ */ e("h2", { class: "IncodeCommonIssuesTitle", children: t("commonIssues.commonIssues") }),
211
+ /* @__PURE__ */ e("h2", { class: "IncodeCommonIssuesTitle", children: i("commonIssues.commonIssues") }),
212
212
  /* @__PURE__ */ e(C, { size: 24 }),
213
213
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCards", children: [
214
214
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCard", children: [
215
- /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardIcon", children: /* @__PURE__ */ e(J, {}) }),
215
+ /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardIcon", children: /* @__PURE__ */ e(W, {}) }),
216
216
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardText", children: [
217
- /* @__PURE__ */ e("h5", { class: "IncodeCommonIssuesCardTitle", children: t("commonIssues.glarePresent") }),
218
- /* @__PURE__ */ e("p", { class: "IncodeCommonIssuesCardBody", children: t("commonIssues.glarePresentDescription") })
217
+ /* @__PURE__ */ e("h5", { class: "IncodeCommonIssuesCardTitle", children: i("commonIssues.glarePresent") }),
218
+ /* @__PURE__ */ e("p", { class: "IncodeCommonIssuesCardBody", children: i("commonIssues.glarePresentDescription") })
219
219
  ] })
220
220
  ] }),
221
221
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCard", children: [
222
- /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardIcon", children: /* @__PURE__ */ e(j, {}) }),
222
+ /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardIcon", children: /* @__PURE__ */ e(q, {}) }),
223
223
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardText", children: [
224
- /* @__PURE__ */ e("h3", { class: "IncodeCommonIssuesCardTitle", children: t("commonIssues.blurPresent") }),
225
- /* @__PURE__ */ e("p", { class: "IncodeCommonIssuesCardBody", children: t("commonIssues.blurPresentDescription") })
224
+ /* @__PURE__ */ e("h3", { class: "IncodeCommonIssuesCardTitle", children: i("commonIssues.blurPresent") }),
225
+ /* @__PURE__ */ e("p", { class: "IncodeCommonIssuesCardBody", children: i("commonIssues.blurPresentDescription") })
226
226
  ] })
227
227
  ] }),
228
228
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCard", children: [
229
- /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardIcon", children: /* @__PURE__ */ e(W, {}) }),
229
+ /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardIcon", children: /* @__PURE__ */ e(X, {}) }),
230
230
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesCardText", children: [
231
- /* @__PURE__ */ e("h3", { class: "IncodeCommonIssuesCardTitle", children: t("commonIssues.notReadable") }),
232
- /* @__PURE__ */ e("p", { class: "IncodeCommonIssuesCardBody", children: t("commonIssues.notReadableDescription") })
231
+ /* @__PURE__ */ e("h3", { class: "IncodeCommonIssuesCardTitle", children: i("commonIssues.notReadable") }),
232
+ /* @__PURE__ */ e("p", { class: "IncodeCommonIssuesCardBody", children: i("commonIssues.notReadableDescription") })
233
233
  ] })
234
234
  ] })
235
235
  ] }),
236
236
  /* @__PURE__ */ e("div", { class: "IncodeCommonIssuesButtons", children: [
237
237
  /* @__PURE__ */ e(
238
- I,
238
+ m,
239
239
  {
240
240
  variant: "link",
241
241
  onClick: r,
242
242
  class: "IncodeCommonIssuesTakeManually",
243
- children: t("commonIssues.takeManually")
243
+ children: i("commonIssues.takeManually")
244
244
  }
245
245
  ),
246
- /* @__PURE__ */ e(I, { onClick: n, class: "IncodeCommonIssuesTryAgain", children: t("commonIssues.tryAgain") })
246
+ /* @__PURE__ */ e(m, { onClick: n, class: "IncodeCommonIssuesTryAgain", children: i("commonIssues.tryAgain") })
247
247
  ] })
248
248
  ] })
249
249
  ] }) });
250
- }, P = ({ className: n }) => /* @__PURE__ */ e(
250
+ }, V = ({ className: n }) => /* @__PURE__ */ e(
251
251
  "svg",
252
252
  {
253
253
  width: "16",
@@ -265,44 +265,44 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
265
265
  }
266
266
  )
267
267
  }
268
- ), e1 = ({
268
+ ), t1 = ({
269
269
  orientation: n,
270
- mode: i,
271
- state: t,
270
+ mode: t,
271
+ state: i,
272
272
  children: r,
273
273
  className: o
274
274
  }) => {
275
- const l = n !== "vertical" || i === "passport", a = i === "passport", s = `IncodeCaptureFrame${t.charAt(0).toUpperCase() + t.slice(1)}`;
275
+ const s = n !== "vertical" || t === "passport", a = t === "passport", l = `IncodeCaptureFrame${i.charAt(0).toUpperCase() + i.slice(1)}`;
276
276
  return /* @__PURE__ */ e(
277
277
  "div",
278
278
  {
279
- class: f(
279
+ class: v(
280
280
  "IncodeCaptureFrame",
281
- l ? "IncodeCaptureFrameHorizontal" : "IncodeCaptureFrameVertical",
282
- s,
281
+ s ? "IncodeCaptureFrameHorizontal" : "IncodeCaptureFrameVertical",
282
+ l,
283
283
  a && "IncodeCaptureFramePassport",
284
284
  o
285
285
  ),
286
286
  children: r
287
287
  }
288
288
  );
289
- }, k = ({
289
+ }, D = ({
290
290
  imageUrl: n,
291
- orientation: i,
292
- mode: t,
291
+ orientation: t,
292
+ mode: i,
293
293
  borderState: r,
294
294
  topContent: o,
295
- bottomContent: l,
295
+ bottomContent: s,
296
296
  overlayContent: a
297
297
  }) => {
298
- const { t: s } = c();
298
+ const { t: l } = d();
299
299
  return /* @__PURE__ */ e(x, { hideHeader: !0, hideFooterBranding: !0, children: /* @__PURE__ */ e("div", { class: "IncodeIdProcessingLayout", children: /* @__PURE__ */ e("div", { class: "IncodeIdProcessingLayoutContent", children: [
300
300
  o && /* @__PURE__ */ e("div", { class: "IncodeIdProcessingTopArea", children: o }),
301
301
  /* @__PURE__ */ e(
302
- e1,
302
+ t1,
303
303
  {
304
- orientation: i,
305
- mode: t === "id" ? "front" : t,
304
+ orientation: t,
305
+ mode: i === "id" ? "front" : i,
306
306
  state: r,
307
307
  children: [
308
308
  /* @__PURE__ */ e(
@@ -319,30 +319,30 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
319
319
  ),
320
320
  /* @__PURE__ */ e("div", { class: "IncodeIdProcessingBottomArea", children: [
321
321
  /* @__PURE__ */ e("div", { class: "IncodeCaptureEncryptionLabel", children: [
322
- /* @__PURE__ */ e(P, { className: "IncodeCaptureEncryptionIcon" }),
323
- /* @__PURE__ */ e("span", { children: s("v2.capture.label") })
322
+ /* @__PURE__ */ e(V, { className: "IncodeCaptureEncryptionIcon" }),
323
+ /* @__PURE__ */ e("span", { children: l("v2.capture.label") })
324
324
  ] }),
325
- l
325
+ s
326
326
  ] })
327
327
  ] }) }) });
328
- }, t1 = ({
328
+ }, i1 = ({
329
329
  imageUrl: n,
330
- progress: i,
331
- orientation: t,
330
+ progress: t,
331
+ orientation: i,
332
332
  mode: r
333
333
  }) => {
334
- const { t: o } = c(), l = t !== "vertical" || r === "passport", [a, s] = L(null);
335
- return m(() => {
336
- l ? import("../id-laser-h-BBV3r3rz.js").then((d) => {
337
- s(d.default);
338
- }) : import("../id-laser-v-BTHJaSfx.js").then((d) => {
339
- s(d.default);
334
+ const { t: o } = d(), s = i !== "vertical" || r === "passport", [a, l] = g(null);
335
+ return w(() => {
336
+ s ? import("../id-laser-h-BBV3r3rz.js").then((c) => {
337
+ l(c.default);
338
+ }) : import("../id-laser-v-BTHJaSfx.js").then((c) => {
339
+ l(c.default);
340
340
  });
341
- }, [l]), /* @__PURE__ */ e(
342
- k,
341
+ }, [s]), /* @__PURE__ */ e(
342
+ D,
343
343
  {
344
344
  imageUrl: n,
345
- orientation: t,
345
+ orientation: i,
346
346
  mode: r,
347
347
  borderState: "analyzing",
348
348
  topContent: /* @__PURE__ */ e("div", { class: "IncodeAnalyzingContent", children: [
@@ -350,13 +350,13 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
350
350
  "div",
351
351
  {
352
352
  class: "IncodeAnalyzingProgressFill",
353
- style: { width: `${i}%` }
353
+ style: { width: `${t}%` }
354
354
  }
355
355
  ) }),
356
356
  /* @__PURE__ */ e("h2", { class: "IncodeAnalyzingTitle", children: o("idv2.capture.processing.analyzing") })
357
357
  ] }),
358
358
  overlayContent: a ? /* @__PURE__ */ e(
359
- b,
359
+ Z,
360
360
  {
361
361
  animationData: a,
362
362
  loop: !0,
@@ -365,7 +365,7 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
365
365
  ) : null
366
366
  }
367
367
  );
368
- }, i1 = ({ className: n }) => /* @__PURE__ */ e(
368
+ }, n1 = ({ className: n }) => /* @__PURE__ */ e(
369
369
  "svg",
370
370
  {
371
371
  class: n,
@@ -382,7 +382,7 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
382
382
  }
383
383
  )
384
384
  }
385
- ), F = ({ className: n }) => /* @__PURE__ */ e(
385
+ ), R = ({ className: n }) => /* @__PURE__ */ e(
386
386
  "svg",
387
387
  {
388
388
  class: n,
@@ -399,97 +399,97 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
399
399
  }
400
400
  )
401
401
  }
402
- ), V = ({
402
+ ), S = ({
403
403
  variant: n,
404
- imageUrl: i,
405
- orientation: t,
404
+ imageUrl: t,
405
+ orientation: i,
406
406
  mode: r,
407
407
  title: o,
408
- subtitle: l,
408
+ subtitle: s,
409
409
  buttonText: a,
410
- onButtonClick: s,
411
- attemptsRemaining: d
410
+ onButtonClick: l,
411
+ attemptsRemaining: c
412
412
  }) => {
413
- const { t: u } = c();
413
+ const { t: f } = d();
414
414
  return /* @__PURE__ */ e(
415
- k,
415
+ D,
416
416
  {
417
- imageUrl: i,
418
- orientation: t,
417
+ imageUrl: t,
418
+ orientation: i,
419
419
  mode: r,
420
420
  borderState: n,
421
421
  topContent: /* @__PURE__ */ e("div", { class: "IncodeIdProcessingResultContent", children: [
422
- n === "success" ? /* @__PURE__ */ e(i1, { className: "IncodeIdProcessingResultIcon" }) : /* @__PURE__ */ e(F, { className: "IncodeIdProcessingResultIcon" }),
422
+ n === "success" ? /* @__PURE__ */ e(n1, { className: "IncodeIdProcessingResultIcon" }) : /* @__PURE__ */ e(R, { className: "IncodeIdProcessingResultIcon" }),
423
423
  /* @__PURE__ */ e(C, { size: 16 }),
424
424
  o && /* @__PURE__ */ e("h2", { class: "IncodeIdProcessingResultTitle", children: o }),
425
- l && /* @__PURE__ */ e(U, { children: [
425
+ s && /* @__PURE__ */ e(_, { children: [
426
426
  /* @__PURE__ */ e(C, { size: 12 }),
427
- /* @__PURE__ */ e("p", { class: "IncodeIdProcessingResultSubtitle", children: l })
427
+ /* @__PURE__ */ e("p", { class: "IncodeIdProcessingResultSubtitle", children: s })
428
428
  ] })
429
429
  ] }),
430
430
  bottomContent: /* @__PURE__ */ e("div", { class: "IncodeIdProcessingResultButtonContainer", children: [
431
- d !== void 0 && d > 0 && /* @__PURE__ */ e("p", { class: "IncodeIdProcessingResultAttempts", children: u("v2.idError.attemptsLeft", {
432
- count: d
431
+ c !== void 0 && c > 0 && /* @__PURE__ */ e("p", { class: "IncodeIdProcessingResultAttempts", children: f("v2.idError.attemptsLeft", {
432
+ count: c
433
433
  }) }),
434
- /* @__PURE__ */ e(I, { onClick: s, "data-testid": "retry-button", children: a })
434
+ /* @__PURE__ */ e(m, { onClick: l, "data-testid": "retry-button", children: a })
435
435
  ] })
436
436
  }
437
437
  );
438
- }, n1 = ({ manager: n, state: i }) => {
439
- const { t } = c();
440
- if (!i.previewImageUrl)
438
+ }, r1 = ({ manager: n, state: t }) => {
439
+ const { t: i } = d();
440
+ if (!t.previewImageUrl)
441
441
  return null;
442
- const r = i.currentMode === "passport" ? "passport" : "id", o = () => i.needsBackCapture ? t("v2.idSuccess.subtitle") : i.needsFrontCapture ? t("idv2.capture.processing.successBackSubtitleScanFront") : t("v2.idSuccess.subtitleBack"), l = () => i.needsBackCapture ? t("idv2.capture.processing.scanBack") : i.needsFrontCapture ? t("idv2.capture.processing.scanFront") : t("idv2.capturePreview.continue");
442
+ const r = t.currentMode === "passport" ? "passport" : "id", o = () => t.needsBackCapture ? i("v2.idSuccess.subtitle") : t.needsFrontCapture ? i("idv2.capture.processing.successBackSubtitleScanFront") : i("v2.idSuccess.subtitleBack"), s = () => t.needsBackCapture ? i("idv2.capture.processing.scanBack") : t.needsFrontCapture ? i("idv2.capture.processing.scanFront") : i("idv2.capturePreview.continue");
443
443
  return /* @__PURE__ */ e(
444
- V,
444
+ S,
445
445
  {
446
446
  variant: "success",
447
- imageUrl: i.previewImageUrl,
448
- orientation: i.orientation,
447
+ imageUrl: t.previewImageUrl,
448
+ orientation: t.orientation,
449
449
  mode: r,
450
- title: t("v2.idSuccess.title"),
450
+ title: i("v2.idSuccess.title"),
451
451
  subtitle: o(),
452
- buttonText: l(),
452
+ buttonText: s(),
453
453
  onButtonClick: () => n.nextStep()
454
454
  }
455
455
  );
456
- }, D = ({ manager: n, state: i, ...t }) => {
457
- const { t: r } = c();
458
- if (i.status === "error")
456
+ }, A = ({ manager: n, state: t, ...i }) => {
457
+ const { t: r } = d();
458
+ if (t.status === "error")
459
459
  return /* @__PURE__ */ e("div", { class: "IncodeIdError", children: [
460
- /* @__PURE__ */ e("div", { class: "IncodeIdErrorMessage", children: i.error }),
461
- /* @__PURE__ */ e(I, { onClick: () => n.reset(), "data-testid": "retry-button", children: r("idv2.capturePreview.retry") })
460
+ /* @__PURE__ */ e("div", { class: "IncodeIdErrorMessage", children: t.error }),
461
+ /* @__PURE__ */ e(m, { onClick: () => n.reset(), "data-testid": "retry-button", children: r("idv2.capturePreview.retry") })
462
462
  ] });
463
- const o = i.currentMode === "passport" ? "passport" : "id";
464
- return i.previewImageUrl ? /* @__PURE__ */ e(
465
- V,
463
+ const o = t.currentMode === "passport" ? "passport" : "id";
464
+ return t.previewImageUrl ? /* @__PURE__ */ e(
465
+ S,
466
466
  {
467
467
  variant: "error",
468
- imageUrl: i.previewImageUrl,
469
- orientation: i.orientation,
468
+ imageUrl: t.previewImageUrl,
469
+ orientation: t.orientation,
470
470
  mode: o,
471
- title: i.uploadErrorMessage,
472
- subtitle: i.uploadErrorDescription,
473
- buttonText: i.canRetry ? r("idv2.capturePreview.tryAgain") : r("idv2.capturePreview.continue"),
471
+ title: t.uploadErrorMessage,
472
+ subtitle: t.uploadErrorDescription,
473
+ buttonText: t.canRetry ? r("idv2.capturePreview.tryAgain") : r("idv2.capturePreview.continue"),
474
474
  onButtonClick: () => n.continueFromError(),
475
- attemptsRemaining: i.attemptsRemaining
475
+ attemptsRemaining: t.attemptsRemaining
476
476
  }
477
477
  ) : null;
478
- }, r1 = ({ manager: n }) => {
479
- const { t: i } = c(), t = () => {
478
+ }, o1 = ({ manager: n }) => {
479
+ const { t } = d(), i = () => {
480
480
  n.retryCapture();
481
481
  };
482
482
  return /* @__PURE__ */ e(x, { hideHeader: !0, hideFooterBranding: !0, className: "IncodeIdExpiredPage", children: [
483
483
  /* @__PURE__ */ e("div", { class: "IncodeIdExpiredContent", children: [
484
- /* @__PURE__ */ e(F, { className: "IncodeIdExpiredIcon" }),
485
- /* @__PURE__ */ e(_, { className: "IncodeIdExpiredTitle", children: i("idv2.capture.notifications.expiredId") }),
484
+ /* @__PURE__ */ e(R, { className: "IncodeIdExpiredIcon" }),
485
+ /* @__PURE__ */ e(k, { className: "IncodeIdExpiredTitle", children: t("idv2.capture.notifications.expiredId") }),
486
486
  /* @__PURE__ */ e(C, { size: 12 }),
487
- /* @__PURE__ */ e("p", { class: "IncodeIdExpiredSubtitle", children: i("idv2.capture.notifications.useDifferent") }),
487
+ /* @__PURE__ */ e("p", { class: "IncodeIdExpiredSubtitle", children: t("idv2.capture.notifications.useDifferent") }),
488
488
  /* @__PURE__ */ e(C, { size: 80 })
489
489
  ] }),
490
- /* @__PURE__ */ e("div", { class: "IncodeIdExpiredButtonContainer", children: /* @__PURE__ */ e(I, { variant: "primary", onClick: t, children: i("idv2.unacceptedId.tryAgain") }) })
490
+ /* @__PURE__ */ e("div", { class: "IncodeIdExpiredButtonContainer", children: /* @__PURE__ */ e(m, { variant: "primary", onClick: i, children: t("idv2.unacceptedId.tryAgain") }) })
491
491
  ] });
492
- }, o1 = ({ className: n }) => /* @__PURE__ */ e(
492
+ }, l1 = ({ className: n }) => /* @__PURE__ */ e(
493
493
  "svg",
494
494
  {
495
495
  width: "30",
@@ -520,180 +520,180 @@ const j = ({ className: n }) => /* @__PURE__ */ e(
520
520
  )
521
521
  ]
522
522
  }
523
- ), p = /* @__PURE__ */ new Map();
523
+ ), I = /* @__PURE__ */ new Map();
524
524
  let T = !1;
525
- const w = {
525
+ const y = {
526
526
  blur: () => import("../blurdevicelottie-_BZRug1c.js"),
527
527
  glare: () => import("../glaredevicelottie-DLuIStvb.js"),
528
528
  align: () => import("../aligndevicelottie-DlQCRPfM.js"),
529
529
  front: () => import("../frontdevicelottie-KhKxT5n9.js"),
530
530
  back: () => import("../backdevicelottie-B4NgyWmX.js")
531
531
  };
532
- function S(n) {
532
+ function z(n) {
533
533
  T || (T = !0, Promise.all([
534
- w.blur(),
535
- w.glare(),
536
- w.align(),
537
- w.front(),
538
- w.back()
539
- ]).then(([i, t, r, o, l]) => {
540
- p.set("blur", i.default), p.set("glare", t.default), p.set("align", r.default), p.set("front", o.default), p.set("back", l.default), n?.();
534
+ y.blur(),
535
+ y.glare(),
536
+ y.align(),
537
+ y.front(),
538
+ y.back()
539
+ ]).then(([t, i, r, o, s]) => {
540
+ I.set("blur", t.default), I.set("glare", i.default), I.set("align", r.default), I.set("front", o.default), I.set("back", s.default), n?.();
541
541
  }).catch(() => {
542
542
  }));
543
543
  }
544
- function l1() {
545
- S();
546
- }
547
544
  function s1() {
548
- m(() => {
549
- l1();
545
+ z();
546
+ }
547
+ function a1() {
548
+ w(() => {
549
+ s1();
550
550
  }, []);
551
551
  }
552
- function a1(n, i) {
553
- const { t } = c(), [, r] = L(0);
554
- if (m(() => {
555
- S(() => r((o) => o + 1));
552
+ function c1(n, t) {
553
+ const { t: i } = d(), [, r] = g(0);
554
+ if (w(() => {
555
+ z(() => r((o) => o + 1));
556
556
  }, []), n === "blur")
557
557
  return {
558
- title: t("idv2.capture.notifications.blur.title"),
559
- description: t("idv2.capture.notifications.blur.description"),
560
- animationData: p.get("blur") ?? null
558
+ title: i("idv2.capture.notifications.blur.title"),
559
+ description: i("idv2.capture.notifications.blur.description"),
560
+ animationData: I.get("blur") ?? null
561
561
  };
562
562
  if (n === "glare")
563
563
  return {
564
- title: t("idv2.capture.notifications.glare.title"),
565
- description: t("idv2.capture.notifications.glare.description"),
566
- animationData: p.get("glare") ?? null
564
+ title: i("idv2.capture.notifications.glare.title"),
565
+ description: i("idv2.capture.notifications.glare.description"),
566
+ animationData: I.get("glare") ?? null
567
567
  };
568
568
  if (n === "farAway")
569
569
  return {
570
- title: t("idv2.capture.notifications.notAligned.title"),
571
- description: t("idv2.capture.notifications.notAligned.description"),
572
- animationData: p.get("align") ?? null
570
+ title: i("idv2.capture.notifications.notAligned.title"),
571
+ description: i("idv2.capture.notifications.notAligned.description"),
572
+ animationData: I.get("align") ?? null
573
573
  };
574
574
  if (n === "wrongSide") {
575
- const o = i === "back";
575
+ const o = t === "back";
576
576
  return {
577
- title: t(o ? "idv2.capture.notifications.showBack.title" : "idv2.capture.notifications.showFront.title"),
578
- description: t(o ? "idv2.capture.notifications.showBack.description" : "idv2.capture.notifications.showFront.description"),
579
- animationData: p.get(o ? "back" : "front") ?? null
577
+ title: i(o ? "idv2.capture.notifications.showBack.title" : "idv2.capture.notifications.showFront.title"),
578
+ description: i(o ? "idv2.capture.notifications.showBack.description" : "idv2.capture.notifications.showFront.description"),
579
+ animationData: I.get(o ? "back" : "front") ?? null
580
580
  };
581
581
  }
582
582
  return null;
583
583
  }
584
- const c1 = ({
584
+ const d1 = ({
585
585
  detectionStatus: n,
586
- mode: i
586
+ mode: t
587
587
  }) => {
588
- const t = a1(n, i);
589
- return t ? /* @__PURE__ */ e("div", { class: f("IncodeIdCaptureNotification"), children: /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationContent", children: [
590
- /* @__PURE__ */ e("div", { class: f("IncodeIdCaptureNotificationText"), children: [
591
- /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationTitle", children: t.title }),
592
- t.description && /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationDescription", children: t.description })
588
+ const i = c1(n, t);
589
+ return i ? /* @__PURE__ */ e("div", { class: v("IncodeIdCaptureNotification"), children: /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationContent", children: [
590
+ /* @__PURE__ */ e("div", { class: v("IncodeIdCaptureNotificationText"), children: [
591
+ /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationTitle", children: i.title }),
592
+ i.description && /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationDescription", children: i.description })
593
593
  ] }),
594
594
  /* @__PURE__ */ e(C, { size: 16, direction: "horizontal" }),
595
- t.animationData && /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationAnimation", children: /* @__PURE__ */ e(b, { animationData: t.animationData, loop: !0 }) })
595
+ i.animationData && /* @__PURE__ */ e("div", { class: "IncodeIdCaptureNotificationAnimation", children: /* @__PURE__ */ e(Z, { animationData: i.animationData, loop: !0 }) })
596
596
  ] }) }) : null;
597
- }, d1 = N(
597
+ }, u1 = G(
598
598
  ({
599
599
  mode: n,
600
- orientation: i,
601
- detectionStatus: t,
600
+ orientation: t,
601
+ detectionStatus: i,
602
602
  counterValue: r,
603
603
  isCapturing: o,
604
- onOpenHelp: l
604
+ onOpenHelp: s
605
605
  }, a) => {
606
- const { t: s } = c();
607
- s1();
608
- const d = t === "detecting" || t === "idNotDetected" || t === "manualCapture", u = () => o || t === "capturing" ? "Capturing" : t === "blur" || t === "glare" || t === "wrongSide" || t === "farAway" ? "Error" : "Idle", y = () => {
609
- if (o || t === "capturing")
606
+ const { t: l } = d();
607
+ a1();
608
+ const c = i === "detecting" || i === "idNotDetected" || i === "manualCapture", f = () => o || i === "capturing" ? "Capturing" : i === "blur" || i === "glare" || i === "wrongSide" || i === "farAway" ? "Error" : "Idle", L = () => {
609
+ if (o || i === "capturing")
610
610
  return {
611
- title: s("idv2.capture.takingPhoto"),
612
- subtitle: s("idv2.capture.dontMove")
611
+ title: l("idv2.capture.takingPhoto"),
612
+ subtitle: l("idv2.capture.dontMove")
613
613
  };
614
- if (d) {
615
- const M = t === "manualCapture";
614
+ if (c) {
615
+ const h = i === "manualCapture";
616
616
  return n === "passport" ? {
617
- title: s("idv2.capture.fillFramePassport"),
618
- subtitle: M ? "" : s("idv2.capture.v2.autoCapture")
617
+ title: l("idv2.capture.fillFramePassport"),
618
+ subtitle: h ? "" : l("idv2.capture.v2.autoCapture")
619
619
  } : n === "back" ? {
620
- title: s("idv2.capture.v2.fillFrameBack"),
621
- subtitle: M ? "" : s("idv2.capture.v2.autoCapture")
620
+ title: l("idv2.capture.v2.fillFrameBack"),
621
+ subtitle: h ? "" : l("idv2.capture.v2.autoCapture")
622
622
  } : {
623
- title: s("idv2.capture.v2.fillFrameFront"),
624
- subtitle: M ? "" : s("idv2.capture.v2.autoCapture")
623
+ title: l("idv2.capture.v2.fillFrameFront"),
624
+ subtitle: h ? "" : l("idv2.capture.v2.autoCapture")
625
625
  };
626
626
  }
627
627
  return null;
628
- }, B = u(), v = y(), g = n === "passport", h = i !== "vertical" || g;
628
+ }, B = f(), p = L(), M = n === "passport", u = t !== "vertical" || M;
629
629
  return /* @__PURE__ */ e(
630
630
  "div",
631
631
  {
632
- class: f(
632
+ class: v(
633
633
  "IncodeCaptureOverlay",
634
- !h && "IncodeCaptureOverlayVertical"
634
+ !u && "IncodeCaptureOverlayVertical"
635
635
  ),
636
636
  children: [
637
637
  /* @__PURE__ */ e(
638
- u1,
638
+ C1,
639
639
  {
640
- detectionStatus: t,
640
+ detectionStatus: i,
641
641
  mode: n,
642
- topContent: v
642
+ topContent: p
643
643
  }
644
644
  ),
645
645
  /* @__PURE__ */ e(
646
646
  "div",
647
647
  {
648
648
  ref: a,
649
- class: f(
649
+ class: v(
650
650
  "IncodeCaptureFrame",
651
- h ? "IncodeCaptureFrameHorizontal" : "IncodeCaptureFrameVertical",
651
+ u ? "IncodeCaptureFrameHorizontal" : "IncodeCaptureFrameVertical",
652
652
  `IncodeCaptureFrame${B}`,
653
- g && "IncodeCaptureFramePassport"
653
+ M && "IncodeCaptureFramePassport"
654
654
  ),
655
655
  children: o && r > 0 && /* @__PURE__ */ e("div", { class: "IncodeCaptureCounter", children: r })
656
656
  }
657
657
  ),
658
- /* @__PURE__ */ e(C1, { onOpenHelp: l })
658
+ /* @__PURE__ */ e(p1, { onOpenHelp: s })
659
659
  ]
660
660
  }
661
661
  );
662
662
  }
663
- ), u1 = ({ detectionStatus: n, mode: i, topContent: t }) => /* @__PURE__ */ e("div", { class: "IncodeCaptureTopSection", children: [
664
- /* @__PURE__ */ e(c1, { detectionStatus: n, mode: i }),
663
+ ), C1 = ({ detectionStatus: n, mode: t, topContent: i }) => /* @__PURE__ */ e("div", { class: "IncodeCaptureTopSection", children: [
664
+ /* @__PURE__ */ e(d1, { detectionStatus: n, mode: t }),
665
665
  /* @__PURE__ */ e(
666
666
  "div",
667
667
  {
668
- class: f(
668
+ class: v(
669
669
  "IncodeCaptureTopText",
670
- !t && "IncodeCaptureTopTextHidden"
670
+ !i && "IncodeCaptureTopTextHidden"
671
671
  ),
672
672
  children: [
673
- /* @__PURE__ */ e("div", { class: "IncodeCaptureTopTextTitle", children: t?.title || " " }),
674
- /* @__PURE__ */ e("div", { class: "IncodeCaptureTopTextSubtitle", children: t?.subtitle || " " })
673
+ /* @__PURE__ */ e("div", { class: "IncodeCaptureTopTextTitle", children: i?.title || " " }),
674
+ /* @__PURE__ */ e("div", { class: "IncodeCaptureTopTextSubtitle", children: i?.subtitle || " " })
675
675
  ]
676
676
  }
677
677
  )
678
- ] }), C1 = ({ onOpenHelp: n }) => {
679
- const { t: i } = c();
678
+ ] }), p1 = ({ onOpenHelp: n }) => {
679
+ const { t } = d();
680
680
  return /* @__PURE__ */ e("div", { class: "IncodeCaptureBottomSection", children: [
681
681
  /* @__PURE__ */ e("div", { class: "IncodeCaptureEncryptionLabel", children: [
682
- /* @__PURE__ */ e(P, { className: "IncodeCaptureEncryptionIcon" }),
683
- /* @__PURE__ */ e("span", { children: i("v2.capture.label") })
682
+ /* @__PURE__ */ e(V, { className: "IncodeCaptureEncryptionIcon" }),
683
+ /* @__PURE__ */ e("span", { children: t("v2.capture.label") })
684
684
  ] }),
685
685
  /* @__PURE__ */ e("div", { class: "IncodeCaptureHelpButton", children: /* @__PURE__ */ e(
686
- I,
686
+ m,
687
687
  {
688
688
  variant: "link",
689
689
  onClick: n,
690
- "aria-label": i("idv2.needHelp.open"),
690
+ "aria-label": t("idv2.needHelp.open"),
691
691
  class: "IncodeCaptureHelpButtonInner",
692
- children: /* @__PURE__ */ e(o1, {})
692
+ children: /* @__PURE__ */ e(l1, {})
693
693
  }
694
694
  ) })
695
695
  ] });
696
- }, p1 = ({
696
+ }, h1 = ({
697
697
  className: n
698
698
  }) => /* @__PURE__ */ e(
699
699
  "svg",
@@ -718,11 +718,11 @@ const c1 = ({
718
718
  /* @__PURE__ */ e("circle", { cx: "33.5926", cy: "33.9996", r: "25.4187", fill: "white" })
719
719
  ]
720
720
  }
721
- ), h1 = ({
721
+ ), I1 = ({
722
722
  onClick: n,
723
- disabled: i
723
+ disabled: t
724
724
  }) => {
725
- const { t } = c();
725
+ const { t: i } = d();
726
726
  return /* @__PURE__ */ e(
727
727
  "div",
728
728
  {
@@ -730,104 +730,119 @@ const c1 = ({
730
730
  "data-testid": "manual-capture-button",
731
731
  children: [
732
732
  /* @__PURE__ */ e("div", { class: "IncodeIdManualCaptureTooltipContainer", children: /* @__PURE__ */ e("div", { class: "IncodeIdManualCaptureTooltip", children: /* @__PURE__ */ e("ol", { class: "IncodeIdManualCaptureTooltipList", children: [
733
- /* @__PURE__ */ e("li", { children: t("idv2.commonIssues.firstStep") }),
734
- /* @__PURE__ */ e("li", { children: t("idv2.commonIssues.secondStep") })
733
+ /* @__PURE__ */ e("li", { children: i("idv2.commonIssues.firstStep") }),
734
+ /* @__PURE__ */ e("li", { children: i("idv2.commonIssues.secondStep") })
735
735
  ] }) }) }),
736
736
  /* @__PURE__ */ e("div", { class: "IncodeIdManualCaptureButtonContent", children: /* @__PURE__ */ e(
737
- I,
737
+ m,
738
738
  {
739
739
  variant: "link",
740
740
  onClick: n,
741
- disabled: i,
741
+ disabled: t,
742
742
  class: "IncodeIdManualCaptureButtonButton",
743
- "aria-label": t("idv2.capture.manualCapture.ariaLabel"),
744
- children: /* @__PURE__ */ e(p1, {})
743
+ "aria-label": i("idv2.capture.manualCapture.ariaLabel"),
744
+ children: /* @__PURE__ */ e(h1, {})
745
745
  }
746
746
  ) })
747
747
  ]
748
748
  }
749
749
  );
750
- }, I1 = ({ manager: n, state: i }) => {
751
- const { t } = c();
752
- if (i.captureStatus === "initializing")
750
+ }, f1 = ({ manager: n, state: t }) => {
751
+ const { t: i } = d();
752
+ if (t.captureStatus === "initializing")
753
753
  return /* @__PURE__ */ e(x, { hideHeader: !0, hideFooterBranding: !0, className: "IncodeIdCapturePage", children: /* @__PURE__ */ e("div", { class: "IncodeCaptureInitializing", children: [
754
- /* @__PURE__ */ e(Q, { size: "large" }),
755
- /* @__PURE__ */ e("p", { class: "IncodeCaptureInitializingText", children: t("idv2.capture.initializing") })
754
+ /* @__PURE__ */ e(F, { size: "large" }),
755
+ /* @__PURE__ */ e("p", { class: "IncodeCaptureInitializingText", children: i("idv2.capture.initializing") })
756
756
  ] }) });
757
- if (i.captureStatus === "uploading" && i.previewImageUrl) {
758
- const r = i.currentMode === "passport" ? "passport" : "id";
757
+ if (t.captureStatus === "uploading" && t.previewImageUrl) {
758
+ const r = t.currentMode === "passport" ? "passport" : "id";
759
759
  return /* @__PURE__ */ e(
760
- t1,
760
+ i1,
761
761
  {
762
- imageUrl: i.previewImageUrl,
763
- progress: i.uploadProgress ?? 0,
764
- orientation: i.orientation,
762
+ imageUrl: t.previewImageUrl,
763
+ progress: t.uploadProgress ?? 0,
764
+ orientation: t.orientation,
765
765
  mode: r
766
766
  }
767
767
  );
768
768
  }
769
- return i.captureStatus === "success" && i.previewImageUrl ? /* @__PURE__ */ e(n1, { manager: n, state: i }) : i.captureStatus === "uploadError" && i.previewImageUrl ? /* @__PURE__ */ e(D, { manager: n, state: i }) : /* @__PURE__ */ e(f1, { manager: n, state: i });
770
- }, f1 = ({ manager: n, state: i }) => {
771
- const t = Z(null), r = Z(null), [o, l] = L(!1);
772
- m(() => {
773
- t.current && i.stream && (t.current.srcObject = i.stream, t.current.play().catch(() => {
774
- }));
775
- }, [i.stream]), m(() => {
776
- const v = () => {
777
- const g = r.current;
778
- if (!g)
769
+ return t.captureStatus === "success" && t.previewImageUrl ? /* @__PURE__ */ e(r1, { manager: n, state: t }) : t.captureStatus === "uploadError" && t.previewImageUrl ? /* @__PURE__ */ e(A, { manager: n, state: t }) : /* @__PURE__ */ e(m1, { manager: n, state: t });
770
+ }, m1 = ({ manager: n, state: t }) => {
771
+ const i = E(null), r = E(null), [o, s] = g(!1), [a, l] = g(!1);
772
+ w(() => {
773
+ const u = i.current;
774
+ if (!u || !t.stream) {
775
+ l(!1);
776
+ return;
777
+ }
778
+ l(!1);
779
+ const h = () => l(!0);
780
+ return u.addEventListener("playing", h), u.srcObject = t.stream, u.play().catch(() => {
781
+ }), () => u.removeEventListener("playing", h);
782
+ }, [t.stream]), w(() => {
783
+ const u = () => {
784
+ const h = r.current;
785
+ if (!h)
779
786
  return;
780
- const h = g.getBoundingClientRect();
787
+ const b = h.getBoundingClientRect();
781
788
  n.updateDetectionArea({
782
- x: h.left,
783
- y: h.top,
784
- width: h.width,
785
- height: h.height
789
+ x: b.left,
790
+ y: b.top,
791
+ width: b.width,
792
+ height: b.height
786
793
  });
787
794
  };
788
- return v(), window.addEventListener("resize", v), () => window.removeEventListener("resize", v);
789
- }, [n, i.orientation]);
790
- const a = i.captureStatus === "capturing" || i.detectionStatus === "capturing", s = i.detectionStatus, d = s === "manualCapture" || i.showCaptureButtonInAuto && i.captureStatus === "detecting" && s !== "capturing", u = () => {
791
- l(!0);
792
- }, y = () => {
793
- l(!1);
794
- }, B = () => {
795
- l(!1), n.switchToManualCapture();
795
+ return u(), window.addEventListener("resize", u), () => window.removeEventListener("resize", u);
796
+ }, [n, t.orientation, a]);
797
+ const c = t.captureStatus === "capturing" || t.detectionStatus === "capturing", f = t.detectionStatus, L = f === "manualCapture" || t.showCaptureButtonInAuto && t.captureStatus === "detecting" && f !== "capturing", B = () => {
798
+ s(!0);
799
+ }, p = () => {
800
+ s(!1);
801
+ }, M = () => {
802
+ s(!1), n.switchToManualCapture();
796
803
  };
797
804
  return /* @__PURE__ */ e(x, { hideHeader: !0, hideFooterBranding: !0, className: "IncodeIdCapturePage", children: /* @__PURE__ */ e("div", { class: "IncodeCapture", children: [
798
- /* @__PURE__ */ e("div", { class: "IncodeCaptureVideo", children: /* @__PURE__ */ e(
799
- "video",
800
- {
801
- ref: t,
802
- autoplay: !0,
803
- playsInline: !0,
804
- class: "IncodeCaptureVideoElement",
805
- "aria-label": "Camera stream for ID capture",
806
- muted: !0
807
- }
808
- ) }),
809
805
  /* @__PURE__ */ e(
810
- d1,
806
+ "div",
811
807
  {
812
- ref: r,
813
- mode: i.currentMode,
814
- orientation: i.orientation,
815
- detectionStatus: i.detectionStatus,
816
- counterValue: i.counterValue,
817
- isCapturing: a,
818
- onOpenHelp: u
808
+ class: `IncodeCaptureVideo${a ? "" : "IncodeCaptureVideoLoading"}`,
809
+ children: /* @__PURE__ */ e(
810
+ "video",
811
+ {
812
+ ref: i,
813
+ autoplay: !0,
814
+ playsInline: !0,
815
+ class: "IncodeCaptureVideoElement",
816
+ "aria-label": "Camera stream for ID capture",
817
+ muted: !0
818
+ }
819
+ )
819
820
  }
820
821
  ),
821
- d && /* @__PURE__ */ e(h1, { onClick: () => n.capture() }),
822
- o && /* @__PURE__ */ e(
823
- Y,
824
- {
825
- onClose: y,
826
- onTakeManually: B
827
- }
828
- )
822
+ a ? /* @__PURE__ */ e(_, { children: [
823
+ /* @__PURE__ */ e(
824
+ u1,
825
+ {
826
+ ref: r,
827
+ mode: t.currentMode,
828
+ orientation: t.orientation,
829
+ detectionStatus: t.detectionStatus,
830
+ counterValue: t.counterValue,
831
+ isCapturing: c,
832
+ onOpenHelp: B
833
+ }
834
+ ),
835
+ L && /* @__PURE__ */ e(I1, { onClick: () => n.capture() }),
836
+ o && /* @__PURE__ */ e(
837
+ e1,
838
+ {
839
+ onClose: p,
840
+ onTakeManually: M
841
+ }
842
+ )
843
+ ] }) : /* @__PURE__ */ e("div", { class: "IncodeCaptureInitializing", children: /* @__PURE__ */ e(F, { size: "large" }) })
829
844
  ] }) });
830
- }, m1 = () => /* @__PURE__ */ e(
845
+ }, v1 = () => /* @__PURE__ */ e(
831
846
  "svg",
832
847
  {
833
848
  width: "119",
@@ -1021,7 +1036,7 @@ const c1 = ({
1021
1036
  ] })
1022
1037
  ]
1023
1038
  }
1024
- ), v1 = () => /* @__PURE__ */ e(
1039
+ ), g1 = () => /* @__PURE__ */ e(
1025
1040
  "svg",
1026
1041
  {
1027
1042
  width: "118",
@@ -1326,7 +1341,7 @@ const c1 = ({
1326
1341
  ] })
1327
1342
  ]
1328
1343
  }
1329
- ), g1 = ({ className: n }) => /* @__PURE__ */ e(
1344
+ ), w1 = ({ className: n }) => /* @__PURE__ */ e(
1330
1345
  "svg",
1331
1346
  {
1332
1347
  width: "46",
@@ -1359,34 +1374,34 @@ const c1 = ({
1359
1374
  )
1360
1375
  ]
1361
1376
  }
1362
- ), E = ({
1377
+ ), H = ({
1363
1378
  icon: n,
1364
- title: i,
1365
- description: t,
1379
+ title: t,
1380
+ description: i,
1366
1381
  ariaLabel: r,
1367
1382
  testId: o,
1368
- onClick: l
1383
+ onClick: s
1369
1384
  }) => /* @__PURE__ */ e(
1370
1385
  "button",
1371
1386
  {
1372
1387
  type: "button",
1373
1388
  class: "IncodeChooserButton",
1374
- onClick: l,
1389
+ onClick: s,
1375
1390
  "aria-label": r,
1376
1391
  "data-testid": o,
1377
1392
  children: [
1378
1393
  /* @__PURE__ */ e("div", { class: "IncodeChooserButtonIcon", children: /* @__PURE__ */ e(n, {}) }),
1379
1394
  /* @__PURE__ */ e("div", { class: "IncodeChooserButtonContent", children: [
1380
- /* @__PURE__ */ e("span", { class: "IncodeChooserButtonTitle", children: i }),
1395
+ /* @__PURE__ */ e("span", { class: "IncodeChooserButtonTitle", children: t }),
1381
1396
  /* @__PURE__ */ e(C, { size: 4 }),
1382
- /* @__PURE__ */ e("span", { class: "IncodeChooserButtonDescription", children: t }),
1397
+ /* @__PURE__ */ e("span", { class: "IncodeChooserButtonDescription", children: i }),
1383
1398
  /* @__PURE__ */ e(C, { size: 8 }),
1384
- /* @__PURE__ */ e("div", { class: "IncodeChooserButtonArrow", children: /* @__PURE__ */ e(g1, {}) })
1399
+ /* @__PURE__ */ e("div", { class: "IncodeChooserButtonArrow", children: /* @__PURE__ */ e(w1, {}) })
1385
1400
  ] })
1386
1401
  ]
1387
1402
  }
1388
- ), w1 = ({ manager: n }) => {
1389
- const { t: i } = c(), t = () => {
1403
+ ), L1 = ({ manager: n }) => {
1404
+ const { t } = d(), i = () => {
1390
1405
  n.selectDocument("id");
1391
1406
  }, r = () => {
1392
1407
  n.selectDocument("passport");
@@ -1394,28 +1409,28 @@ const c1 = ({
1394
1409
  return /* @__PURE__ */ e(
1395
1410
  x,
1396
1411
  {
1397
- title: i("idv2.chooser.title"),
1412
+ title: t("idv2.chooser.title"),
1398
1413
  "data-testid": "document-chooser-page",
1399
1414
  className: "IncodeChooserPage",
1400
1415
  children: /* @__PURE__ */ e("div", { class: "IncodeChooserContainer", children: /* @__PURE__ */ e("div", { class: "IncodeChooserButtons", children: [
1401
1416
  /* @__PURE__ */ e(
1402
- E,
1417
+ H,
1403
1418
  {
1404
- icon: m1,
1405
- title: i("idv2.chooser.idButtonTitle"),
1406
- description: i("idv2.chooser.idButtonDescription"),
1407
- ariaLabel: i("idv2.chooser.idButtonTitle"),
1419
+ icon: v1,
1420
+ title: t("idv2.chooser.idButtonTitle"),
1421
+ description: t("idv2.chooser.idButtonDescription"),
1422
+ ariaLabel: t("idv2.chooser.idButtonTitle"),
1408
1423
  testId: "chooser-button-id",
1409
- onClick: t
1424
+ onClick: i
1410
1425
  }
1411
1426
  ),
1412
1427
  /* @__PURE__ */ e(
1413
- E,
1428
+ H,
1414
1429
  {
1415
- icon: v1,
1416
- title: i("idv2.chooser.passportButtonTitle"),
1417
- description: i("idv2.chooser.passportButtonDescription"),
1418
- ariaLabel: i("idv2.chooser.passportButtonTitle"),
1430
+ icon: g1,
1431
+ title: t("idv2.chooser.passportButtonTitle"),
1432
+ description: t("idv2.chooser.passportButtonDescription"),
1433
+ ariaLabel: t("idv2.chooser.passportButtonTitle"),
1419
1434
  testId: "chooser-button-passport",
1420
1435
  onClick: r
1421
1436
  }
@@ -1423,70 +1438,73 @@ const c1 = ({
1423
1438
  ] }) })
1424
1439
  }
1425
1440
  );
1426
- }, H = ({
1441
+ }, P = ({
1427
1442
  manager: n,
1428
- direction: i
1443
+ direction: t
1429
1444
  }) => {
1430
- const [t, r] = L(null), { t: o } = c();
1431
- m(() => {
1432
- import("../flip-animation-COR596wy.js").then((s) => {
1433
- r(s.default);
1445
+ const [i, r] = g(null), { t: o } = d();
1446
+ w(() => {
1447
+ import("../flip-animation-COR596wy.js").then((l) => {
1448
+ r(l.default);
1434
1449
  });
1435
1450
  }, []);
1436
- const l = async () => {
1437
- await new Promise((s) => setTimeout(s, 1e3)), i === "toBack" ? n.continueToBack() : n.continueToFront();
1451
+ const s = async () => {
1452
+ await new Promise((l) => setTimeout(l, 1e3)), t === "toBack" ? n.continueToBack() : n.continueToFront();
1438
1453
  };
1439
- return t ? /* @__PURE__ */ e("div", { class: "IncodeFlipAnimation", children: [
1440
- /* @__PURE__ */ e(_, { className: "IncodeFlipAnimationTitle", children: o(i === "toBack" ? "idv2.flipAnimation.title" : "idv2.flipAnimation.titleToFront") }),
1454
+ return i ? /* @__PURE__ */ e("div", { class: "IncodeFlipAnimation", children: [
1455
+ /* @__PURE__ */ e(k, { className: "IncodeFlipAnimationTitle", children: o(t === "toBack" ? "idv2.flipAnimation.title" : "idv2.flipAnimation.titleToFront") }),
1441
1456
  /* @__PURE__ */ e(C, { size: 32 }),
1442
1457
  /* @__PURE__ */ e(
1443
- b,
1458
+ Z,
1444
1459
  {
1445
- animationData: t,
1460
+ animationData: i,
1446
1461
  loop: !1,
1447
- onComplete: l
1462
+ onComplete: s
1448
1463
  }
1449
1464
  )
1450
1465
  ] }) : null;
1451
- }, L1 = ({ manager: n, state: i }) => {
1452
- const { t } = c(), [r, o] = L(null), l = i.selectedDocumentType === "passport", a = i.currentMode === "back";
1453
- if (m(() => {
1454
- l ? import("../passport-tutorial-CaYBFTqt.js").then((u) => {
1455
- o(u.default);
1456
- }) : a ? import("../id-tutorial-B-F5Q28m.js").then((u) => {
1457
- o(u.default);
1458
- }) : import("../id-tutorial-B-F5Q28m.js").then((u) => {
1459
- o(u.default);
1466
+ }, y1 = ({ manager: n, state: t }) => {
1467
+ const { t: i } = d(), [r, o] = g(!1), [s, a] = g(null), l = t.selectedDocumentType === "passport", c = t.currentMode === "back";
1468
+ if (w(() => {
1469
+ l ? import("../passport-tutorial-CaYBFTqt.js").then((p) => {
1470
+ a(p.default);
1471
+ }) : c ? import("../id-tutorial-B-F5Q28m.js").then((p) => {
1472
+ a(p.default);
1473
+ }) : import("../id-tutorial-B-F5Q28m.js").then((p) => {
1474
+ a(p.default);
1460
1475
  });
1461
- }, [l, a]), !r)
1476
+ }, [l, c]), !s)
1462
1477
  return null;
1463
- const s = t(l ? "idv2.capture.passport.title" : a ? "idv2.tutorial.v2.titleBack" : "idv2.tutorial.v2.title"), d = t(l ? "idv2.capture.passport.subtitle" : a ? "idv2.tutorial.subtitleBack" : "idv2.tutorial.subtitle");
1478
+ const f = i(l ? "idv2.capture.passport.title" : c ? "idv2.tutorial.v2.titleBack" : "idv2.tutorial.v2.title"), L = i(l ? "idv2.capture.passport.subtitle" : c ? "idv2.tutorial.subtitleBack" : "idv2.tutorial.subtitle");
1464
1479
  return /* @__PURE__ */ e(
1465
- O,
1480
+ $,
1466
1481
  {
1467
- animationData: r,
1468
- title: s,
1469
- subtitle: d,
1470
- onContinue: () => n.nextStep(),
1471
- buttonText: t("idv2.tutorial.startScan"),
1472
- disclaimerText: t("idv2.tutorial.v2.autocapture"),
1473
- className: f(
1482
+ animationData: s,
1483
+ title: f,
1484
+ subtitle: L,
1485
+ onContinue: () => {
1486
+ o(!0), n.nextStep();
1487
+ },
1488
+ buttonText: i("idv2.tutorial.startScan"),
1489
+ disclaimerText: i("idv2.tutorial.v2.autocapture"),
1490
+ isLoading: r,
1491
+ className: v(
1474
1492
  "IncodeIdTutorial",
1475
1493
  l ? "IncodeIdTutorialPassport" : "IncodeIdTutorialId"
1476
1494
  )
1477
1495
  }
1478
1496
  );
1479
- }, x1 = ({ config: n, onFinish: i, onError: t }) => {
1480
- const [r, o] = R(() => z({ config: n }));
1481
- return r.status === "idle" || r.status === "loading" ? null : r.status === "chooser" ? /* @__PURE__ */ e(w1, { manager: o }) : r.status === "tutorial" ? /* @__PURE__ */ e(L1, { manager: o, state: r }) : r.status === "permissions" ? /* @__PURE__ */ e(
1482
- G,
1497
+ }, x1 = ({ config: n, onFinish: t, onError: i }) => {
1498
+ const [r, o] = N(() => O({ config: n }));
1499
+ return r.status === "idle" || r.status === "loading" ? null : r.status === "chooser" ? /* @__PURE__ */ e(L1, { manager: o }) : r.status === "tutorial" ? /* @__PURE__ */ e(y1, { manager: o, state: r }) : r.status === "permissions" ? /* @__PURE__ */ e(
1500
+ K,
1483
1501
  {
1484
1502
  manager: o,
1485
1503
  permissionStatus: r.permissionStatus
1486
1504
  }
1487
- ) : r.status === "frontFinished" ? /* @__PURE__ */ e(H, { manager: o, direction: "toBack" }) : r.status === "backFinished" ? /* @__PURE__ */ e(H, { manager: o, direction: "toFront" }) : r.status === "capture" ? /* @__PURE__ */ e(I1, { manager: o, state: r, onFinish: () => i?.() }) : r.status === "processing" ? /* @__PURE__ */ e(K, {}) : r.status === "expired" ? /* @__PURE__ */ e(r1, { manager: o }) : r.status === "finished" ? (i?.(), null) : r.status === "closed" ? (t?.(void 0), null) : r.status === "error" ? /* @__PURE__ */ e(D, { manager: o, state: r, onError: t }) : null;
1488
- }, y1 = ({ config: n, onFinish: i, onError: t }) => /* @__PURE__ */ e($, { children: n ? /* @__PURE__ */ e(x1, { config: n, onFinish: i, onError: t }) : null });
1489
- A(y1, "incode-id");
1505
+ ) : r.status === "frontFinished" ? /* @__PURE__ */ e(P, { manager: o, direction: "toBack" }) : r.status === "backFinished" ? /* @__PURE__ */ e(P, { manager: o, direction: "toFront" }) : r.status === "capture" ? /* @__PURE__ */ e(f1, { manager: o, state: r, onFinish: () => t?.() }) : r.status === "processing" ? /* @__PURE__ */ e(j, {}) : r.status === "expired" ? /* @__PURE__ */ e(o1, { manager: o }) : r.status === "finished" ? (t?.(), null) : r.status === "closed" ? (i?.(void 0), null) : r.status === "error" ? /* @__PURE__ */ e(A, { manager: o, state: r, onError: i }) : null;
1506
+ }, B1 = ({ config: n, onFinish: t, onError: i }) => /* @__PURE__ */ e(Q, { children: n ? /* @__PURE__ */ e(x1, { config: n, onFinish: t, onError: i }) : null });
1507
+ U(B1, "incode-id");
1490
1508
  export {
1491
- y1 as Id
1509
+ B1 as Id
1492
1510
  };
@@ -936,6 +936,10 @@
936
936
  position: absolute;
937
937
  }
938
938
 
939
+ .IncodeIdCapturePage .IncodeCapture .IncodeCaptureVideo.IncodeCaptureVideoLoading {
940
+ opacity: 0;
941
+ }
942
+
939
943
  .IncodeIdCapturePage .IncodeCapture .IncodeCaptureVideo .IncodeCaptureVideoElement {
940
944
  inset: var(--spacing-0, var(--spacing-none, 0px));
941
945
  object-fit: cover;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@incodetech/web",
3
- "version": "0.0.0-dev-20260303-3dab9f2",
3
+ "version": "0.0.0-dev-20260304-fb1914c",
4
4
  "type": "module",
5
5
  "main": "./dist/index.es.js",
6
6
  "types": "./dist/types/index.d.ts",
@@ -100,7 +100,7 @@
100
100
  "libphonenumber-js": "^1.11.0",
101
101
  "preact-custom-element": "^4.6.0",
102
102
  "tailwindcss": "^4.1.17",
103
- "@incodetech/core": "0.0.0-dev-20260303-3dab9f2"
103
+ "@incodetech/core": "0.0.0-dev-20260304-fb1914c"
104
104
  },
105
105
  "devDependencies": {
106
106
  "@microsoft/api-extractor": "^7.53.3",