idmission-web-sdk 2.3.113 → 2.3.114

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.
@@ -211,7 +211,7 @@
211
211
  return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
212
212
  };
213
213
 
214
- var webSdkVersion = '2.3.113';
214
+ var webSdkVersion = '2.3.114';
215
215
 
216
216
  function getPlatform() {
217
217
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
@@ -24363,7 +24363,7 @@
24363
24363
  _a.sent();
24364
24364
  signatureRecorder.onstop = function () {
24365
24365
  return __awaiter(_this, void 0, void 0, function () {
24366
- var recordingStoppedAt, mimeType, blob, _a, onSignatureVideoCaptured, recordingStartRequestedAt, recordingStartedAt, firstChunkReceivedAt, signatureStartedAt, signatureEndedAt, recordingStopRequestedAt, lastChunkReceivedAt, supportsRequestVideoFrameCallback, supportsRoundRect;
24366
+ var recordingStoppedAt, mimeType, blob, _a, onSignatureVideoCaptured, recordingStartRequestedAt, recordingStartedAt, firstChunkReceivedAt, signatureStartedAt, signatureEndedAt, acceptClickedAt, recordingStopRequestedAt, lastChunkReceivedAt, supportsRequestVideoFrameCallback, supportsRoundRect;
24367
24367
  return __generator(this, function (_b) {
24368
24368
  recordingStoppedAt = performance.now();
24369
24369
  set({
@@ -24375,7 +24375,7 @@
24375
24375
  });
24376
24376
  signatureChunks = [];
24377
24377
  signatureRecorder = null;
24378
- _a = get(), onSignatureVideoCaptured = _a.onSignatureVideoCaptured, recordingStartRequestedAt = _a.recordingStartRequestedAt, recordingStartedAt = _a.recordingStartedAt, firstChunkReceivedAt = _a.firstChunkReceivedAt, signatureStartedAt = _a.signatureStartedAt, signatureEndedAt = _a.signatureEndedAt, recordingStopRequestedAt = _a.recordingStopRequestedAt, lastChunkReceivedAt = _a.lastChunkReceivedAt, supportsRequestVideoFrameCallback = _a.supportsRequestVideoFrameCallback, supportsRoundRect = _a.supportsRoundRect;
24378
+ _a = get(), onSignatureVideoCaptured = _a.onSignatureVideoCaptured, recordingStartRequestedAt = _a.recordingStartRequestedAt, recordingStartedAt = _a.recordingStartedAt, firstChunkReceivedAt = _a.firstChunkReceivedAt, signatureStartedAt = _a.signatureStartedAt, signatureEndedAt = _a.signatureEndedAt, acceptClickedAt = _a.acceptClickedAt, recordingStopRequestedAt = _a.recordingStopRequestedAt, lastChunkReceivedAt = _a.lastChunkReceivedAt, supportsRequestVideoFrameCallback = _a.supportsRequestVideoFrameCallback, supportsRoundRect = _a.supportsRoundRect;
24379
24379
  onSignatureVideoCaptured(blob, signatureData !== null && signatureData !== void 0 ? signatureData : null, imageUrl !== null && imageUrl !== void 0 ? imageUrl : null, {
24380
24380
  mimeType: mimeType,
24381
24381
  browserFeatures: {
@@ -24388,6 +24388,7 @@
24388
24388
  firstChunkReceivedAt: firstChunkReceivedAt ? Math.ceil(firstChunkReceivedAt) : 0,
24389
24389
  signatureStartedAt: signatureStartedAt ? Math.ceil(signatureStartedAt) : 0,
24390
24390
  signatureEndedAt: signatureEndedAt ? Math.ceil(signatureEndedAt) : 0,
24391
+ acceptClickedAt: acceptClickedAt ? Math.ceil(acceptClickedAt) : 0,
24391
24392
  recordingStopRequestedAt: recordingStopRequestedAt ? Math.ceil(recordingStopRequestedAt) : 0,
24392
24393
  recordingStoppedAt: Math.ceil(recordingStoppedAt),
24393
24394
  lastChunkReceivedAt: lastChunkReceivedAt ? Math.ceil(lastChunkReceivedAt) : 0
@@ -24418,6 +24419,7 @@
24418
24419
  signatureValid: false,
24419
24420
  signatureStartedAt: undefined,
24420
24421
  signatureEndedAt: undefined,
24422
+ acceptClickedAt: undefined,
24421
24423
  supportsRequestVideoFrameCallback: undefined,
24422
24424
  supportsRoundRect: undefined
24423
24425
  });
@@ -24725,12 +24727,15 @@
24725
24727
  React.useEffect(function () {
24726
24728
  if (guideToDisplay) setMode(guideToDisplay);
24727
24729
  }, [guideToDisplay]);
24728
- var firstChunkReceivedAt = useVideoSignatureStore(useShallow(function (state) {
24729
- return {
24730
- firstChunkReceivedAt: state.firstChunkReceivedAt
24731
- };
24732
- })).firstChunkReceivedAt;
24733
- var signaturePadDisabled = requestedAction !== 'CAPTURE_SIGNATURE' || !firstChunkReceivedAt;
24730
+ var _h = useVideoSignatureStore(useShallow(function (state) {
24731
+ return {
24732
+ firstChunkReceivedAt: state.firstChunkReceivedAt,
24733
+ acceptClickedAt: state.acceptClickedAt
24734
+ };
24735
+ })),
24736
+ firstChunkReceivedAt = _h.firstChunkReceivedAt,
24737
+ acceptClickedAt = _h.acceptClickedAt;
24738
+ var signaturePadDisabled = requestedAction !== 'CAPTURE_SIGNATURE' || !firstChunkReceivedAt || !!acceptClickedAt;
24734
24739
  return /*#__PURE__*/React.createElement(Container$3, {
24735
24740
  className: classNames.container
24736
24741
  }, /*#__PURE__*/React.createElement(Inner$1, {
@@ -25480,6 +25485,9 @@
25480
25485
  props = __rest(_a, ["status", "restartVideoOnSignaturePadCleared", "captureAudio", "component", "showFaceGuideThenSignaturePad"]);
25481
25486
  var Component = component !== null && component !== void 0 ? component : VideoSignatureGuides;
25482
25487
  var onAcceptBtnClicked = React.useCallback(function () {
25488
+ useVideoSignatureStore.setState({
25489
+ acceptClickedAt: performance.now()
25490
+ });
25483
25491
  var signaturePad = useVideoSignatureStore.getState().signaturePad;
25484
25492
  if (!signaturePad.current) throw new Error('Signature pad not found');
25485
25493
  var signatureData = buildSignatureData(signaturePad.current);