idmission-web-sdk 2.2.18 → 2.2.19

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/sdk2.esm.js CHANGED
@@ -201,7 +201,7 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
201
201
  return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
202
202
  };
203
203
 
204
- var webSdkVersion = '2.2.18';
204
+ var webSdkVersion = '2.2.19';
205
205
 
206
206
  function getPlatform() {
207
207
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
@@ -2488,7 +2488,7 @@ var CameraProvider = function CameraProvider(_a) {
2488
2488
  }, children);
2489
2489
  };
2490
2490
 
2491
- var visionTasksBasePath = "https://cdn.jsdelivr.net/npm/@mediapipe/tasks-vision@0.10.7/wasm";
2491
+ var visionTasksBasePath = "https://cdn.jsdelivr.net/npm/@mediapipe/tasks-vision@0.10.17/wasm";
2492
2492
  var visionRuntimePreloading = false;
2493
2493
  function preloadVisionRuntime() {
2494
2494
  return __awaiter(this, void 0, void 0, function () {
@@ -2784,9 +2784,12 @@ var defaultFocusThresholds = {
2784
2784
  }
2785
2785
  };
2786
2786
  var models = {};
2787
- function loadFocusModel(modelAssetPath) {
2788
- return __awaiter(this, void 0, void 0, function () {
2787
+ function loadFocusModel() {
2788
+ return __awaiter(this, arguments, void 0, function (modelAssetPath) {
2789
2789
  var id, _a, _b, _c, _d;
2790
+ if (modelAssetPath === void 0) {
2791
+ modelAssetPath = defaultFocusModelPath;
2792
+ }
2790
2793
  return __generator(this, function (_e) {
2791
2794
  switch (_e.label) {
2792
2795
  case 0:
@@ -2808,6 +2811,7 @@ function loadFocusModel(modelAssetPath) {
2808
2811
  modelAssetPath: modelAssetPath,
2809
2812
  delegate: modelCapabilities.delegate
2810
2813
  },
2814
+ canvas: document.createElement('canvas'),
2811
2815
  runningMode: 'VIDEO'
2812
2816
  }])];
2813
2817
  case 3:
@@ -2940,6 +2944,7 @@ function loadFaceDetector() {
2940
2944
  return [4 /*yield*/, FilesetResolver.forVisionTasks(visionTasksBasePath)];
2941
2945
  case 2:
2942
2946
  return [4 /*yield*/, _b.apply(_a, [_c.sent(), {
2947
+ canvas: document.createElement('canvas'),
2943
2948
  baseOptions: {
2944
2949
  modelAssetPath: defaultFaceDetectorModelPath,
2945
2950
  delegate: modelCapabilities.delegate
@@ -3412,6 +3417,7 @@ function loadDocumentDetector() {
3412
3417
  modelAssetPath: modelAssetPath,
3413
3418
  delegate: modelCapabilities.delegate
3414
3419
  },
3420
+ canvas: document.createElement('canvas'),
3415
3421
  scoreThreshold: scoreThreshold,
3416
3422
  runningMode: 'VIDEO'
3417
3423
  }])];