@regulaforensics/vp-frontend-face-components 8.1.1902-nightly → 8.1.1904-nightly

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/main.js CHANGED
@@ -2627,6 +2627,10 @@ const iA = "NotAllowedError", nA = "en", aA = ["ar", "he"], oA = 1, uA = 500, cA
2627
2627
  FULL_HD: {
2628
2628
  width: 1920,
2629
2629
  height: 1080
2630
+ },
2631
+ SQUARE: {
2632
+ width: 720,
2633
+ height: 720
2630
2634
  }
2631
2635
  }, IA = ["rear", "back", "rück", "arrière", "trasera", "trás", "traseira", "posteriore", "posterior", "后面", "後面", "背面", "后置", "後置", "背置", "задней", "الخلفية", "خلفية", "후", "arka", "achterzijde", "หลัง", "baksidan", "bagside", "sau", "bak", "tylny", "takakamera", "belakang", "אחורית", "πίσω", "spate", "hátsó", "zadní", "darrere", "zadná", "задня", "задна", "birou", "артқы", "stražnja", "belakang", "बैक"], sA = {
2632
2636
  "StreamStatus.UNKNOWN_ERROR": "CAMERA_UNKNOWN_ERROR",
@@ -5312,45 +5316,50 @@ function IE(e, r, t) {
5312
5316
  label: ""
5313
5317
  }
5314
5318
  };
5315
- if (navigator.mediaDevices) {
5316
- if (!r.deviceId && !r.facing)
5317
- return t ? (M.status = _e.INCORRECT_CAMERA_ID, M) : (M.status = _e.NO_CAMERA, M);
5318
- const i = {
5319
- height: {
5320
- ideal: e.height > vg ? DM.FULL_HD.height : e.height
5321
- },
5322
- width: {
5323
- ideal: e.width > vg ? DM.FULL_HD.width : e.width
5324
- },
5319
+ if (!navigator.mediaDevices)
5320
+ return M.status = _e.NOT_SUPPORTED, M;
5321
+ if (!r.deviceId && !r.facing)
5322
+ return t ? (M.status = _e.INCORRECT_CAMERA_ID, M) : (M.status = _e.NO_CAMERA, M);
5323
+ try {
5324
+ const i = e.height > vg ? DM.FULL_HD.width : e.width, n = e.height > vg ? DM.FULL_HD.height : e.height, a = {
5325
+ ideal: i
5326
+ }, o = {
5327
+ ideal: n
5328
+ };
5329
+ tr.isFirefox && tr.browserVersion >= "145" && (a.min = i, o.min = n);
5330
+ const s = {
5331
+ width: a,
5332
+ height: o,
5325
5333
  frameRate: {
5326
5334
  ideal: 30
5327
5335
  }
5328
5336
  };
5329
- r.deviceId ? i.deviceId = {
5337
+ r.deviceId ? s.deviceId = {
5330
5338
  exact: r.deviceId
5331
- } : i.facingMode = {
5339
+ } : s.facingMode = {
5332
5340
  ideal: r.facing
5333
5341
  };
5334
- const n = yield navigator.mediaDevices.getUserMedia({
5335
- video: i,
5342
+ const c = yield navigator.mediaDevices.getUserMedia({
5343
+ video: s,
5336
5344
  audio: !1
5337
- }), a = n.getVideoTracks()[0], {
5338
- deviceId: o,
5339
- groupId: s,
5340
- facingMode: c
5341
- } = a.getSettings(), j = {
5342
- deviceId: o || r.deviceId,
5343
- label: a.label || r.label,
5344
- groupId: s || r.groupId,
5345
- facing: c || r.facing
5345
+ }), j = c.getVideoTracks()[0], {
5346
+ deviceId: I,
5347
+ groupId: u,
5348
+ facingMode: g
5349
+ } = j.getSettings(), N = {
5350
+ deviceId: I || r.deviceId,
5351
+ label: j.label || r.label,
5352
+ groupId: u || r.groupId,
5353
+ facing: g || r.facing
5346
5354
  };
5347
5355
  return {
5348
5356
  status: _e.READY,
5349
- stream: n,
5350
- camera: j
5357
+ stream: c,
5358
+ camera: N
5351
5359
  };
5352
- } else
5353
- return M.status = _e.NOT_SUPPORTED, M;
5360
+ } catch (i) {
5361
+ return M.status = _e.UNKNOWN_ERROR, M;
5362
+ }
5354
5363
  });
5355
5364
  }
5356
5365
  function sE(e, r) {
@@ -6162,7 +6171,7 @@ const lx = Vr.create("main"), XN = {
6162
6171
  livenessType: NM.ACTIVE,
6163
6172
  holdStillDuration: void 0,
6164
6173
  timeoutInterval: void 0,
6165
- workerPath: "https://wasm-development.regulaforensics.com/face/nightly/8.1/2ff6bbf4-85e01ed3",
6174
+ workerPath: "https://wasm-development.regulaforensics.com/face/nightly/8.1/51b88457-016b0dbd",
6166
6175
  detectOcclusion: !0,
6167
6176
  captureButton: !1
6168
6177
  }, Ax = (e) => No(No({}, XN), {}, {
@@ -9269,7 +9278,7 @@ class nO {
9269
9278
  }
9270
9279
  prepare(r) {
9271
9280
  return Er(this, null, function* () {
9272
- const t = "Liveness.worker.js", M = ne.getState().workerPath, i = tO(M), n = ne.getState().workerPath === "https://wasm-development.regulaforensics.com/face/nightly/8.1/2ff6bbf4-85e01ed3";
9281
+ const t = "Liveness.worker.js", M = ne.getState().workerPath, i = tO(M), n = ne.getState().workerPath === "https://wasm-development.regulaforensics.com/face/nightly/8.1/51b88457-016b0dbd";
9273
9282
  try {
9274
9283
  let o = yield (yield fetch(i + "/" + t)).text();
9275
9284
  n || (o = UE(o, i));
@@ -9287,7 +9296,7 @@ class nO {
9287
9296
  }), this.worker.postMessage({
9288
9297
  target: "worker-init",
9289
9298
  URL: document.URL,
9290
- currentScriptUrl: "https://wasm-development.regulaforensics.com/face/nightly/8.1/2ff6bbf4-85e01ed3",
9299
+ currentScriptUrl: "https://wasm-development.regulaforensics.com/face/nightly/8.1/51b88457-016b0dbd",
9291
9300
  preMain: !0
9292
9301
  }));
9293
9302
  });
@@ -9659,7 +9668,7 @@ const TO = 1500, XD = (e) => e * 1e3, ou = Vr.create("main"), lO = (e) => e ===
9659
9668
  metadata: {
9660
9669
  serviceUrl: c || Ht,
9661
9670
  hostAppId: vT(),
9662
- sdkVersion: PN("8.1.1902-nightly"),
9671
+ sdkVersion: PN("8.1.1904-nightly"),
9663
9672
  deviceModel: "".concat(tr.osName, "/").concat(tr.osVersion, " ").concat(tr.browserName, "/").concat(tr.fullBrowserVersion),
9664
9673
  camera: D.camera
9665
9674
  }
@@ -9669,7 +9678,7 @@ const TO = 1500, XD = (e) => e * 1e3, ou = Vr.create("main"), lO = (e) => e ===
9669
9678
  data: null
9670
9679
  }), ou("Service initialized");
9671
9680
  } else {
9672
- const v = TE([...D.sortedDevices.frontCameras, ...D.sortedDevices.backCameras], D.camera.deviceId, PN("8.1.1902-nightly"), c || Ht, z);
9681
+ const v = TE([...D.sortedDevices.frontCameras, ...D.sortedDevices.backCameras], D.camera.deviceId, PN("8.1.1904-nightly"), c || Ht, z);
9673
9682
  wt.getInitializingData({
9674
9683
  deviceMetadata: v,
9675
9684
  tag: j,
@@ -12229,7 +12238,7 @@ class n6 extends HTMLElement {
12229
12238
  this.dispatchEvent(t), i6("Component event: ".concat(JSON.stringify(t.detail)));
12230
12239
  }
12231
12240
  get version() {
12232
- return "".concat("8.1.1902-nightly".trim());
12241
+ return "".concat("8.1.1904-nightly".trim());
12233
12242
  }
12234
12243
  set translations(r) {
12235
12244
  this._translations = r, this._mounted && this.render();
@@ -12665,7 +12674,7 @@ class E6 extends HTMLElement {
12665
12674
  });
12666
12675
  }
12667
12676
  get version() {
12668
- return "".concat("8.1.1902-nightly".trim());
12677
+ return "".concat("8.1.1904-nightly".trim());
12669
12678
  }
12670
12679
  set translations(r) {
12671
12680
  this._translations = r, this._mounted && this.render();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@regulaforensics/vp-frontend-face-components",
3
- "version": "8.1.1902-nightly",
3
+ "version": "8.1.1904-nightly",
4
4
  "description": "Regula framework agnostic web components to work with webcamera",
5
5
  "types": "./dist/index.d.ts",
6
6
  "main": "./dist/main.iife.js",