@ekyc_qoobiss/qbs-ect-cmp 3.6.3 → 3.6.5

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.
@@ -5236,7 +5236,7 @@ class Stream {
5236
5236
  setVerificationFinished(fun) {
5237
5237
  this.verificationFinished = fun;
5238
5238
  }
5239
- constructor(_modelPath) {
5239
+ constructor() {
5240
5240
  this.streamPaused = false;
5241
5241
  this.recordedChunks = [];
5242
5242
  this.videoSize = { width: 0, height: 0 };
@@ -5250,9 +5250,9 @@ class Stream {
5250
5250
  this.idML5Detector = IDML5Detector.getInstance(this, state.device.isMobile);
5251
5251
  this.faceML5Detector = FaceML5Detector.getInstance(this, state.device.isMobile);
5252
5252
  }
5253
- static getInstance(modelPath) {
5253
+ static getInstance() {
5254
5254
  if (!Stream.instance) {
5255
- Stream.instance = new Stream(modelPath);
5255
+ Stream.instance = new Stream();
5256
5256
  }
5257
5257
  return Stream.instance;
5258
5258
  }
@@ -5302,6 +5302,7 @@ class Stream {
5302
5302
  async initStream(stream) {
5303
5303
  this.startStream(stream);
5304
5304
  this.recordStream();
5305
+ console.log('Stream initialized');
5305
5306
  }
5306
5307
  async resumeStream() {
5307
5308
  this.streamPaused = false;
@@ -5311,6 +5312,8 @@ class Stream {
5311
5312
  // if (this.faceDetection) await Detector.getInstance().startDetector();
5312
5313
  }
5313
5314
  recordStream() {
5315
+ if (this.mediaRecorder && this.mediaRecorder.state == 'recording')
5316
+ return;
5314
5317
  var options = { mimeType: Stream.webmMimeType.mime, videoBitsPerSecond: 1500000 };
5315
5318
  if (!MediaRecorder.isTypeSupported(options.mimeType)) {
5316
5319
  if (state.device.mobileOS == MobileOS.iOS || state.device.browser == Browser.Safari)
@@ -5477,8 +5480,6 @@ const Camera = class {
5477
5480
  return (index.h("div", { class: "camera" }, index.h("video", { id: "video", loop: true, autoplay: true, playsinline: true, muted: true, class: cameraVideoClass, ref: el => (this.cameraVideo = el) }), index.h("canvas", { id: "output", class: cameraCanvasClass, ref: el => (this.cameraCanvas = el) })));
5478
5481
  }
5479
5482
  startStream() {
5480
- if (!Stream.instance)
5481
- Stream.getInstance(this.modelPath);
5482
5483
  const stream = Stream.getInstance();
5483
5484
  stream.updateHtmlElements(this.cameraVideo, this.cameraCanvas, this.component);
5484
5485
  if (this.captureMode == 'selfie') {
@@ -5564,7 +5565,6 @@ const CaptureError = class {
5564
5565
  index.registerInstance(this, hostRef);
5565
5566
  this.eventCaptureErrorDone = index.createEvent(this, "captureErrorDone", 7);
5566
5567
  this.type = undefined;
5567
- this.message = undefined;
5568
5568
  this.buttonEnabled = undefined;
5569
5569
  this.buttonText = undefined;
5570
5570
  }
@@ -5596,7 +5596,7 @@ const CaptureError = class {
5596
5596
  this.eventCaptureErrorDone.emit();
5597
5597
  }
5598
5598
  render() {
5599
- return (index.h("div", { class: "container" }, index.h("div", { class: "row" }, index.h("h1", { class: "color-red" }, this.titleR1), index.h("h1", { class: "color-red" }, this.titleR2), index.h("div", null, index.h("p", { class: "color-red font-weight-bold font-size-25 mt-5" }, this.descriptionR1), index.h("p", { class: "color-red font-weight-bold font-size-25 mt-5" }, this.descriptionR2), index.h("p", { class: "color-red font-weight-bold font-size-18 mt-5" }, this.message)), index.h("div", { class: "pos-relative show-bottom" }, index.h("div", { class: "btn-buletin" }, index.h("button", { class: "main-button", type: "button", disabled: !this.buttonEnabled, onClick: () => this.buttonClick() }, this.buttonText), index.h("p", { class: "main-text font-size-18 text-right mb-0" }, IdCaptureValues.FooterText))))));
5599
+ return (index.h("div", { class: "container" }, index.h("div", { class: "row" }, index.h("h1", { class: "color-red" }, this.titleR1), index.h("h1", { class: "color-red" }, this.titleR2), index.h("div", null, index.h("p", { class: "color-red font-weight-bold font-size-25 mt-5" }, this.descriptionR1), index.h("p", { class: "color-red font-weight-bold font-size-25 mt-5" }, this.descriptionR2)), index.h("div", { class: "pos-relative show-bottom" }, index.h("div", { class: "btn-buletin" }, index.h("button", { class: "main-button", type: "button", disabled: !this.buttonEnabled, onClick: () => this.buttonClick() }, this.buttonText), index.h("p", { class: "main-text font-size-18 text-right mb-0" }, IdCaptureValues.FooterText))))));
5600
5600
  }
5601
5601
  };
5602
5602
  CaptureError.style = captureErrorCss;
@@ -5683,7 +5683,8 @@ class Cameras {
5683
5683
  const devices = await navigator.mediaDevices.enumerateDevices();
5684
5684
  const videoDevices = devices.filter(device => device.kind === 'videoinput');
5685
5685
  for (const device of videoDevices) {
5686
- const updatedConstraints = deviceInfo.isAppleDevice ? this.GetConstraintsIOs(deviceInfo) : this.GetConstraints(device.deviceId, deviceInfo);
5686
+ //const updatedConstraints = deviceInfo.isAppleDevice ? this.GetConstraintsIOs(deviceInfo) : this.GetConstraints(device.deviceId, deviceInfo);
5687
+ const updatedConstraints = this.GetConstraints(device.deviceId, deviceInfo);
5687
5688
  const stream = await navigator.mediaDevices.getUserMedia(updatedConstraints);
5688
5689
  stream.getVideoTracks().forEach(track => {
5689
5690
  var _a, _b;
@@ -5771,29 +5772,27 @@ class Cameras {
5771
5772
  constraints.video = mediaTrack;
5772
5773
  return constraints;
5773
5774
  }
5774
- GetConstraintsIOs(device, portrait = false) {
5775
- let constraints = {
5776
- audio: false,
5777
- };
5778
- let mediaTrack = {};
5779
- if (device.isDesktop) {
5780
- mediaTrack.width = 1280;
5781
- }
5782
- else {
5783
- if (portrait) {
5784
- mediaTrack.facingMode = 'user';
5785
- mediaTrack.width = 1280;
5786
- mediaTrack.height = 720;
5787
- }
5788
- else {
5789
- mediaTrack.facingMode = 'environment';
5790
- mediaTrack.width = 1280;
5791
- mediaTrack.height = 720;
5792
- }
5793
- }
5794
- constraints.video = mediaTrack;
5795
- return constraints;
5796
- }
5775
+ // public GetConstraintsIOs(device: DeviceState, portrait: boolean = false): MediaStreamConstraints | any {
5776
+ // let constraints: MediaStreamConstraints = {
5777
+ // audio: false,
5778
+ // };
5779
+ // let mediaTrack: MediaTrackConstraints = {};
5780
+ // if (device.isDesktop) {
5781
+ // mediaTrack.width = 1280;
5782
+ // } else {
5783
+ // if (portrait) {
5784
+ // mediaTrack.facingMode = 'user';
5785
+ // mediaTrack.width = 1280;
5786
+ // mediaTrack.height = 720;
5787
+ // } else {
5788
+ // mediaTrack.facingMode = 'environment';
5789
+ // mediaTrack.width = 1280;
5790
+ // mediaTrack.height = 720;
5791
+ // }
5792
+ // }
5793
+ // constraints.video = mediaTrack;
5794
+ // return constraints;
5795
+ // }
5797
5796
  GetRecommendedCamera(cameras) {
5798
5797
  if (cameras && cameras.length > 0) {
5799
5798
  var recommDevice = cameras.find(c => c.recommended);
@@ -5883,7 +5882,7 @@ const IdBackCapture = class {
5883
5882
  }
5884
5883
  async openCamera() {
5885
5884
  await this.baseComponent.logStep(FlowSteps.CiBackCapture, FlowMoments.Initialized);
5886
- const constraints = state.device.isAppleDevice ? this.cameras.GetConstraintsIOs(state.device) : this.cameras.GetConstraints(state.cameraId, state.device);
5885
+ const constraints = this.cameras.GetConstraints(state.cameraId, state.device);
5887
5886
  setTimeout(() => {
5888
5887
  navigator.mediaDevices
5889
5888
  .getUserMedia(constraints)
@@ -6000,7 +5999,8 @@ const IdCapture = class {
6000
5999
  }
6001
6000
  async openCamera() {
6002
6001
  await this.baseComponent.logStep(FlowSteps.CiFrontCapture, FlowMoments.Initialized);
6003
- const constraints = state.device.isAppleDevice ? this.cameras.GetConstraintsIOs(state.device) : this.cameras.GetConstraints(state.cameraId, state.device);
6002
+ //const constraints = store.device.isAppleDevice ? this.cameras.GetConstraintsIOs(store.device) : this.cameras.GetConstraints(store.cameraId, store.device);
6003
+ const constraints = this.cameras.GetConstraints(state.cameraId, state.device);
6004
6004
  setTimeout(() => {
6005
6005
  navigator.mediaDevices
6006
6006
  .getUserMedia(constraints)
@@ -6123,7 +6123,7 @@ const IdDoubleSide = class {
6123
6123
  }
6124
6124
  async captureIdImage(event) {
6125
6125
  let idPhoto = event.detail;
6126
- if (idPhoto.length == 0 || idPhoto.size == 0) {
6126
+ if (idPhoto.size == 0) {
6127
6127
  await this.baseComponent.apiCall.AddLog({ message: 'Empty id photo', blobData: idPhoto }, getLogMessage());
6128
6128
  this.triggerErrorFlow();
6129
6129
  return;
@@ -6138,7 +6138,7 @@ const IdDoubleSide = class {
6138
6138
  }
6139
6139
  async captureIdBackImage(event) {
6140
6140
  let idPhoto = event.detail;
6141
- if (idPhoto.length == 0 || idPhoto.size == 0) {
6141
+ if (idPhoto.size == 0) {
6142
6142
  await this.baseComponent.apiCall.AddLog({ message: 'Empty id photo', blobData: idPhoto }, getLogMessage());
6143
6143
  this.triggerErrorFlow();
6144
6144
  return;
@@ -6153,7 +6153,7 @@ const IdDoubleSide = class {
6153
6153
  }
6154
6154
  async capturedIdRecording(event) {
6155
6155
  let idRecording = event.detail;
6156
- if (idRecording.length == 0 || idRecording.size == 0) {
6156
+ if (idRecording.size == 0) {
6157
6157
  await this.baseComponent.apiCall.AddLog({ message: 'Empty recording', blobData: idRecording }, getLogMessage());
6158
6158
  this.triggerErrorFlow();
6159
6159
  return;
@@ -6283,22 +6283,17 @@ const IdSingleSide = class {
6283
6283
  this.idFlow.photoFile = null;
6284
6284
  this.idFlow.recordingFile = null;
6285
6285
  this.showTimeout = false;
6286
- this.errorMessage = '';
6287
6286
  }
6288
6287
  howToDone() {
6289
6288
  this.showHowTo = false;
6290
6289
  }
6291
6290
  timeElapsed() {
6292
6291
  this.showTimeout = true;
6293
- this.errorMessage = 'timeout';
6294
6292
  }
6295
6293
  async captureIdImage(event) {
6296
- console.log('photoIdCapture');
6297
- console.log(event);
6298
6294
  let idPhoto = event.detail;
6299
- if (idPhoto.length == 0 || idPhoto.size == 0) {
6295
+ if (idPhoto.size == 0) {
6300
6296
  await this.baseComponent.apiCall.AddLog({ message: 'Empty id photo', blobData: idPhoto }, getLogMessage());
6301
- this.errorMessage = 'Empty id photo';
6302
6297
  this.showTimeout = true;
6303
6298
  return;
6304
6299
  }
@@ -6315,12 +6310,9 @@ const IdSingleSide = class {
6315
6310
  await this.endFlow();
6316
6311
  }
6317
6312
  async capturedIdRecording(event) {
6318
- console.log('recordingIdCapture');
6319
- console.log(event);
6320
6313
  let idRecording = event.detail;
6321
- if (idRecording.length == 0 || idRecording.size == 0) {
6314
+ if (idRecording.size == 0) {
6322
6315
  await this.baseComponent.apiCall.AddLog({ message: 'Empty ID recording', blobData: idRecording }, getLogMessage());
6323
- this.errorMessage = 'Empty id recording';
6324
6316
  this.showTimeout = true;
6325
6317
  return;
6326
6318
  }
@@ -6350,7 +6342,6 @@ const IdSingleSide = class {
6350
6342
  this.idFlow.photoFile = null;
6351
6343
  this.idFlow.recordingFile = null;
6352
6344
  this.switchCamera();
6353
- this.errorMessage = 'Upload photo not successful';
6354
6345
  this.showTimeout = true;
6355
6346
  }
6356
6347
  }
@@ -6365,7 +6356,6 @@ const IdSingleSide = class {
6365
6356
  else {
6366
6357
  this.idFlow.photoFile = null;
6367
6358
  this.idFlow.recordingFile = null;
6368
- this.errorMessage = 'Upload recording not successful';
6369
6359
  this.showTimeout = true;
6370
6360
  }
6371
6361
  }
@@ -6395,7 +6385,7 @@ const IdSingleSide = class {
6395
6385
  }
6396
6386
  }
6397
6387
  render() {
6398
- let error = index.h("capture-error", { type: "ID", message: this.errorMessage });
6388
+ let error = index.h("capture-error", { type: "ID" });
6399
6389
  let capture = index.h("id-capture", { id: "idFront" });
6400
6390
  let howToInfo = index.h("how-to-info", { idSide: "front" });
6401
6391
  return this.showHowTo ? howToInfo : this.showTimeout ? error : capture;
@@ -6469,7 +6459,7 @@ function v4(options, buf, offset) {
6469
6459
  }
6470
6460
 
6471
6461
  const name = "@ekyc_qoobiss/qbs-ect-cmp";
6472
- const version$1 = "3.6.3";
6462
+ const version$1 = "3.6.5";
6473
6463
  const description = "Person Identification Component";
6474
6464
  const main = "./dist/index.cjs.js";
6475
6465
  const module$1 = "./dist/index.js";
@@ -9944,7 +9934,7 @@ const SelfieCapture = class {
9944
9934
  }
9945
9935
  async openCamera() {
9946
9936
  await this.baseComponent.logStep(FlowSteps.SelfieCapture, FlowMoments.Initialized);
9947
- const constraints = state.device.isAppleDevice ? this.cameras.GetConstraintsIOs(state.device, true) : this.cameras.GetConstraints('', state.device, true);
9937
+ const constraints = this.cameras.GetConstraints('', state.device, true);
9948
9938
  setTimeout(() => {
9949
9939
  navigator.mediaDevices
9950
9940
  .getUserMedia(constraints)
@@ -10147,7 +10137,7 @@ const UserLiveness = class {
10147
10137
  }
10148
10138
  async captureSelfieImage(event) {
10149
10139
  let selfiePhoto = event.detail;
10150
- if (selfiePhoto.length == 0 || selfiePhoto.size == 0) {
10140
+ if (selfiePhoto.size == 0) {
10151
10141
  await this.baseComponent.apiCall.AddLog({ message: 'Empty selfie', blobData: selfiePhoto }, getLogMessage());
10152
10142
  this.triggerErrorFlow();
10153
10143
  return;
@@ -10162,7 +10152,7 @@ const UserLiveness = class {
10162
10152
  }
10163
10153
  async capturedSelfieRecording(event) {
10164
10154
  let selfieRecording = event.detail;
10165
- if (selfieRecording.length == 0 || selfieRecording.size == 0) {
10155
+ if (selfieRecording.size == 0) {
10166
10156
  await this.baseComponent.apiCall.AddLog({ message: 'Empty recording', blobData: selfieRecording }, getLogMessage());
10167
10157
  this.triggerErrorFlow();
10168
10158
  return;
@@ -14,7 +14,7 @@ const patchEsm = () => {
14
14
  const defineCustomElements = (win, options) => {
15
15
  if (typeof window === 'undefined') return Promise.resolve();
16
16
  return patchEsm().then(() => {
17
- return index.bootstrapLazy([["loader-dots.cjs",[[1,"loader-dots"]]],["agreement-check_18.cjs",[[1,"identification-component",{"token":[1537],"order_id":[1537],"api_url":[1537],"env":[1537],"redirect_id":[1537],"phone_number":[1537],"idSide":[32],"errorMessage":[32],"errorTitle":[32]},[[0,"agreementAcceptance","agreementAcceptanceEmitted"],[0,"apiError","apiErrorEmitter"]]],[0,"id-double-side",{"showTimeout":[32],"showInvalid":[32],"showHowTo":[32],"front":[32],"flow":[32]},[[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"captureErrorDone","captureErrorDone"],[0,"photoIdCapture","captureIdImage"],[0,"photoIdBackCapture","captureIdBackImage"],[0,"recordingIdCapture","capturedIdRecording"],[0,"verificationFinished","verificationFinished"]]],[0,"id-single-side",{"showTimeout":[32],"showHowTo":[32],"idFlow":[32]},[[0,"captureErrorDone","captureErrorDone"],[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"photoIdCapture","captureIdImage"],[0,"verificationFinished","verificationFinished"],[0,"recordingIdCapture","capturedIdRecording"]]],[0,"user-liveness",{"showError":[32],"showHowTo":[32],"selfieFlow":[32]},[[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"captureErrorDone","captureErrorDone"],[0,"photoSelfieCapture","captureSelfieImage"],[0,"recordingSelfieCapture","capturedSelfieRecording"],[0,"verificationFinished","verificationFinished"]]],[0,"agreement-info",{"agreementsChecked":[32],"termsChecked":[32],"openAgreements":[32],"openTerms":[32]},[[0,"agreementAcceptance","agreementAcceptanceEmitted"]]],[0,"camera-error",{"title":[32],"description":[32],"buttonDisabled":[32],"demoVideo":[32]}],[0,"end-redirect"],[0,"error-end",{"message":[1],"errorTitle":[1,"error-title"]}],[0,"landing-validation",{"warningText":[32],"buttonDisabled":[32]}],[0,"mobile-redirect",{"infoTextTop":[32],"infoTextBottom":[32],"contact":[32],"invalidValue":[32],"waitingMobile":[32],"orderStatus":[32],"redirectLink":[32],"qrCode":[32],"prefilledPhone":[32]}],[0,"sms-code-validation",{"title":[32],"details":[32],"buttonText":[32],"phoneNumber":[32],"code":[32],"prefilledPhone":[32],"canSend":[32]}],[0,"id-back-capture",{"videoStarted":[32],"cameraSize":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"showDemo":[32],"demoVideo":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"verificationFinished","verificationFinished"],[0,"takePhoto","takePhoto"]]],[0,"selfie-capture",{"videoStarted":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"demoEnded":[32],"demoVideo":[32],"uploadingLink":[32],"captureHeight":[32],"captureWidth":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"takePhoto","takePhoto"],[0,"verificationFinished","verificationFinished"]]],[0,"agreement-check",{"agreementType":[1,"agreement-type"],"htmlContent":[32],"buttonEnabled":[32]}],[0,"id-capture",{"videoStarted":[32],"cameraSize":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"showDemo":[32],"demoVideo":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"takePhoto","takePhoto"],[0,"verificationFinished","verificationFinished"]]],[0,"capture-error",{"type":[1],"message":[1],"buttonEnabled":[32],"buttonText":[32]}],[0,"how-to-info",{"idSide":[1,"id-side"],"topTitle":[32],"subTitle":[32],"imagePath":[32],"buttonText":[32],"buttonEnabled":[32]}],[0,"camera-comp",{"modelPath":[1,"model-path"],"probabilityThreshold":[2,"probability-threshold"],"captureMode":[1,"capture-mode"]}]]]], options);
17
+ return index.bootstrapLazy([["loader-dots.cjs",[[1,"loader-dots"]]],["agreement-check_18.cjs",[[1,"identification-component",{"token":[1537],"order_id":[1537],"api_url":[1537],"env":[1537],"redirect_id":[1537],"phone_number":[1537],"idSide":[32],"errorMessage":[32],"errorTitle":[32]},[[0,"agreementAcceptance","agreementAcceptanceEmitted"],[0,"apiError","apiErrorEmitter"]]],[0,"id-double-side",{"showTimeout":[32],"showInvalid":[32],"showHowTo":[32],"front":[32],"flow":[32]},[[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"captureErrorDone","captureErrorDone"],[0,"photoIdCapture","captureIdImage"],[0,"photoIdBackCapture","captureIdBackImage"],[0,"recordingIdCapture","capturedIdRecording"],[0,"verificationFinished","verificationFinished"]]],[0,"id-single-side",{"showTimeout":[32],"showHowTo":[32],"idFlow":[32]},[[0,"captureErrorDone","captureErrorDone"],[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"photoIdCapture","captureIdImage"],[0,"verificationFinished","verificationFinished"],[0,"recordingIdCapture","capturedIdRecording"]]],[0,"user-liveness",{"showError":[32],"showHowTo":[32],"selfieFlow":[32]},[[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"captureErrorDone","captureErrorDone"],[0,"photoSelfieCapture","captureSelfieImage"],[0,"recordingSelfieCapture","capturedSelfieRecording"],[0,"verificationFinished","verificationFinished"]]],[0,"agreement-info",{"agreementsChecked":[32],"termsChecked":[32],"openAgreements":[32],"openTerms":[32]},[[0,"agreementAcceptance","agreementAcceptanceEmitted"]]],[0,"camera-error",{"title":[32],"description":[32],"buttonDisabled":[32],"demoVideo":[32]}],[0,"end-redirect"],[0,"error-end",{"message":[1],"errorTitle":[1,"error-title"]}],[0,"landing-validation",{"warningText":[32],"buttonDisabled":[32]}],[0,"mobile-redirect",{"infoTextTop":[32],"infoTextBottom":[32],"contact":[32],"invalidValue":[32],"waitingMobile":[32],"orderStatus":[32],"redirectLink":[32],"qrCode":[32],"prefilledPhone":[32]}],[0,"sms-code-validation",{"title":[32],"details":[32],"buttonText":[32],"phoneNumber":[32],"code":[32],"prefilledPhone":[32],"canSend":[32]}],[0,"id-back-capture",{"videoStarted":[32],"cameraSize":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"showDemo":[32],"demoVideo":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"verificationFinished","verificationFinished"],[0,"takePhoto","takePhoto"]]],[0,"selfie-capture",{"videoStarted":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"demoEnded":[32],"demoVideo":[32],"uploadingLink":[32],"captureHeight":[32],"captureWidth":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"takePhoto","takePhoto"],[0,"verificationFinished","verificationFinished"]]],[0,"agreement-check",{"agreementType":[1,"agreement-type"],"htmlContent":[32],"buttonEnabled":[32]}],[0,"id-capture",{"videoStarted":[32],"cameraSize":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"showDemo":[32],"demoVideo":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"takePhoto","takePhoto"],[0,"verificationFinished","verificationFinished"]]],[0,"capture-error",{"type":[1],"buttonEnabled":[32],"buttonText":[32]}],[0,"how-to-info",{"idSide":[1,"id-side"],"topTitle":[32],"subTitle":[32],"imagePath":[32],"buttonText":[32],"buttonEnabled":[32]}],[0,"camera-comp",{"modelPath":[1,"model-path"],"probabilityThreshold":[2,"probability-threshold"],"captureMode":[1,"capture-mode"]}]]]], options);
18
18
  });
19
19
  };
20
20
 
@@ -17,7 +17,7 @@ const patchBrowser = () => {
17
17
  };
18
18
 
19
19
  patchBrowser().then(options => {
20
- return index.bootstrapLazy([["loader-dots.cjs",[[1,"loader-dots"]]],["agreement-check_18.cjs",[[1,"identification-component",{"token":[1537],"order_id":[1537],"api_url":[1537],"env":[1537],"redirect_id":[1537],"phone_number":[1537],"idSide":[32],"errorMessage":[32],"errorTitle":[32]},[[0,"agreementAcceptance","agreementAcceptanceEmitted"],[0,"apiError","apiErrorEmitter"]]],[0,"id-double-side",{"showTimeout":[32],"showInvalid":[32],"showHowTo":[32],"front":[32],"flow":[32]},[[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"captureErrorDone","captureErrorDone"],[0,"photoIdCapture","captureIdImage"],[0,"photoIdBackCapture","captureIdBackImage"],[0,"recordingIdCapture","capturedIdRecording"],[0,"verificationFinished","verificationFinished"]]],[0,"id-single-side",{"showTimeout":[32],"showHowTo":[32],"idFlow":[32]},[[0,"captureErrorDone","captureErrorDone"],[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"photoIdCapture","captureIdImage"],[0,"verificationFinished","verificationFinished"],[0,"recordingIdCapture","capturedIdRecording"]]],[0,"user-liveness",{"showError":[32],"showHowTo":[32],"selfieFlow":[32]},[[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"captureErrorDone","captureErrorDone"],[0,"photoSelfieCapture","captureSelfieImage"],[0,"recordingSelfieCapture","capturedSelfieRecording"],[0,"verificationFinished","verificationFinished"]]],[0,"agreement-info",{"agreementsChecked":[32],"termsChecked":[32],"openAgreements":[32],"openTerms":[32]},[[0,"agreementAcceptance","agreementAcceptanceEmitted"]]],[0,"camera-error",{"title":[32],"description":[32],"buttonDisabled":[32],"demoVideo":[32]}],[0,"end-redirect"],[0,"error-end",{"message":[1],"errorTitle":[1,"error-title"]}],[0,"landing-validation",{"warningText":[32],"buttonDisabled":[32]}],[0,"mobile-redirect",{"infoTextTop":[32],"infoTextBottom":[32],"contact":[32],"invalidValue":[32],"waitingMobile":[32],"orderStatus":[32],"redirectLink":[32],"qrCode":[32],"prefilledPhone":[32]}],[0,"sms-code-validation",{"title":[32],"details":[32],"buttonText":[32],"phoneNumber":[32],"code":[32],"prefilledPhone":[32],"canSend":[32]}],[0,"id-back-capture",{"videoStarted":[32],"cameraSize":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"showDemo":[32],"demoVideo":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"verificationFinished","verificationFinished"],[0,"takePhoto","takePhoto"]]],[0,"selfie-capture",{"videoStarted":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"demoEnded":[32],"demoVideo":[32],"uploadingLink":[32],"captureHeight":[32],"captureWidth":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"takePhoto","takePhoto"],[0,"verificationFinished","verificationFinished"]]],[0,"agreement-check",{"agreementType":[1,"agreement-type"],"htmlContent":[32],"buttonEnabled":[32]}],[0,"id-capture",{"videoStarted":[32],"cameraSize":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"showDemo":[32],"demoVideo":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"takePhoto","takePhoto"],[0,"verificationFinished","verificationFinished"]]],[0,"capture-error",{"type":[1],"message":[1],"buttonEnabled":[32],"buttonText":[32]}],[0,"how-to-info",{"idSide":[1,"id-side"],"topTitle":[32],"subTitle":[32],"imagePath":[32],"buttonText":[32],"buttonEnabled":[32]}],[0,"camera-comp",{"modelPath":[1,"model-path"],"probabilityThreshold":[2,"probability-threshold"],"captureMode":[1,"capture-mode"]}]]]], options);
20
+ return index.bootstrapLazy([["loader-dots.cjs",[[1,"loader-dots"]]],["agreement-check_18.cjs",[[1,"identification-component",{"token":[1537],"order_id":[1537],"api_url":[1537],"env":[1537],"redirect_id":[1537],"phone_number":[1537],"idSide":[32],"errorMessage":[32],"errorTitle":[32]},[[0,"agreementAcceptance","agreementAcceptanceEmitted"],[0,"apiError","apiErrorEmitter"]]],[0,"id-double-side",{"showTimeout":[32],"showInvalid":[32],"showHowTo":[32],"front":[32],"flow":[32]},[[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"captureErrorDone","captureErrorDone"],[0,"photoIdCapture","captureIdImage"],[0,"photoIdBackCapture","captureIdBackImage"],[0,"recordingIdCapture","capturedIdRecording"],[0,"verificationFinished","verificationFinished"]]],[0,"id-single-side",{"showTimeout":[32],"showHowTo":[32],"idFlow":[32]},[[0,"captureErrorDone","captureErrorDone"],[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"photoIdCapture","captureIdImage"],[0,"verificationFinished","verificationFinished"],[0,"recordingIdCapture","capturedIdRecording"]]],[0,"user-liveness",{"showError":[32],"showHowTo":[32],"selfieFlow":[32]},[[0,"howToInfoDone","howToDone"],[0,"timeElapsed","timeElapsed"],[0,"captureErrorDone","captureErrorDone"],[0,"photoSelfieCapture","captureSelfieImage"],[0,"recordingSelfieCapture","capturedSelfieRecording"],[0,"verificationFinished","verificationFinished"]]],[0,"agreement-info",{"agreementsChecked":[32],"termsChecked":[32],"openAgreements":[32],"openTerms":[32]},[[0,"agreementAcceptance","agreementAcceptanceEmitted"]]],[0,"camera-error",{"title":[32],"description":[32],"buttonDisabled":[32],"demoVideo":[32]}],[0,"end-redirect"],[0,"error-end",{"message":[1],"errorTitle":[1,"error-title"]}],[0,"landing-validation",{"warningText":[32],"buttonDisabled":[32]}],[0,"mobile-redirect",{"infoTextTop":[32],"infoTextBottom":[32],"contact":[32],"invalidValue":[32],"waitingMobile":[32],"orderStatus":[32],"redirectLink":[32],"qrCode":[32],"prefilledPhone":[32]}],[0,"sms-code-validation",{"title":[32],"details":[32],"buttonText":[32],"phoneNumber":[32],"code":[32],"prefilledPhone":[32],"canSend":[32]}],[0,"id-back-capture",{"videoStarted":[32],"cameraSize":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"showDemo":[32],"demoVideo":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"verificationFinished","verificationFinished"],[0,"takePhoto","takePhoto"]]],[0,"selfie-capture",{"videoStarted":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"demoEnded":[32],"demoVideo":[32],"uploadingLink":[32],"captureHeight":[32],"captureWidth":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"takePhoto","takePhoto"],[0,"verificationFinished","verificationFinished"]]],[0,"agreement-check",{"agreementType":[1,"agreement-type"],"htmlContent":[32],"buttonEnabled":[32]}],[0,"id-capture",{"videoStarted":[32],"cameraSize":[32],"captureTaken":[32],"verified":[32],"titleMesage":[32],"showDemo":[32],"demoVideo":[32]},[[0,"changeTitle","eventChangeTitle"],[0,"videoStarted","eventVideoStarted"],[0,"takePhoto","takePhoto"],[0,"verificationFinished","verificationFinished"]]],[0,"capture-error",{"type":[1],"buttonEnabled":[32],"buttonText":[32]}],[0,"how-to-info",{"idSide":[1,"id-side"],"topTitle":[32],"subTitle":[32],"imagePath":[32],"buttonText":[32],"buttonEnabled":[32]}],[0,"camera-comp",{"modelPath":[1,"model-path"],"probabilityThreshold":[2,"probability-threshold"],"captureMode":[1,"capture-mode"]}]]]], options);
21
21
  });
22
22
 
23
23
  exports.setNonce = index.setNonce;
@@ -4,7 +4,6 @@ import { delay } from '../../../utils/utils';
4
4
  export class CaptureError {
5
5
  constructor() {
6
6
  this.type = undefined;
7
- this.message = undefined;
8
7
  this.buttonEnabled = undefined;
9
8
  this.buttonText = undefined;
10
9
  }
@@ -36,7 +35,7 @@ export class CaptureError {
36
35
  this.eventCaptureErrorDone.emit();
37
36
  }
38
37
  render() {
39
- return (h("div", { class: "container" }, h("div", { class: "row" }, h("h1", { class: "color-red" }, this.titleR1), h("h1", { class: "color-red" }, this.titleR2), h("div", null, h("p", { class: "color-red font-weight-bold font-size-25 mt-5" }, this.descriptionR1), h("p", { class: "color-red font-weight-bold font-size-25 mt-5" }, this.descriptionR2), h("p", { class: "color-red font-weight-bold font-size-18 mt-5" }, this.message)), h("div", { class: "pos-relative show-bottom" }, h("div", { class: "btn-buletin" }, h("button", { class: "main-button", type: "button", disabled: !this.buttonEnabled, onClick: () => this.buttonClick() }, this.buttonText), h("p", { class: "main-text font-size-18 text-right mb-0" }, IdCaptureValues.FooterText))))));
38
+ return (h("div", { class: "container" }, h("div", { class: "row" }, h("h1", { class: "color-red" }, this.titleR1), h("h1", { class: "color-red" }, this.titleR2), h("div", null, h("p", { class: "color-red font-weight-bold font-size-25 mt-5" }, this.descriptionR1), h("p", { class: "color-red font-weight-bold font-size-25 mt-5" }, this.descriptionR2)), h("div", { class: "pos-relative show-bottom" }, h("div", { class: "btn-buletin" }, h("button", { class: "main-button", type: "button", disabled: !this.buttonEnabled, onClick: () => this.buttonClick() }, this.buttonText), h("p", { class: "main-text font-size-18 text-right mb-0" }, IdCaptureValues.FooterText))))));
40
39
  }
41
40
  static get is() { return "capture-error"; }
42
41
  static get originalStyleUrls() {
@@ -67,23 +66,6 @@ export class CaptureError {
67
66
  },
68
67
  "attribute": "type",
69
68
  "reflect": false
70
- },
71
- "message": {
72
- "type": "string",
73
- "mutable": false,
74
- "complexType": {
75
- "original": "string",
76
- "resolved": "string",
77
- "references": {}
78
- },
79
- "required": false,
80
- "optional": false,
81
- "docs": {
82
- "tags": [],
83
- "text": ""
84
- },
85
- "attribute": "message",
86
- "reflect": false
87
69
  }
88
70
  };
89
71
  }
@@ -66,7 +66,7 @@ export class IdBackCapture {
66
66
  }
67
67
  async openCamera() {
68
68
  await this.baseComponent.logStep(FlowSteps.CiBackCapture, FlowMoments.Initialized);
69
- const constraints = store.device.isAppleDevice ? this.cameras.GetConstraintsIOs(store.device) : this.cameras.GetConstraints(store.cameraId, store.device);
69
+ const constraints = this.cameras.GetConstraints(store.cameraId, store.device);
70
70
  setTimeout(() => {
71
71
  navigator.mediaDevices
72
72
  .getUserMedia(constraints)
@@ -62,7 +62,8 @@ export class IdCapture {
62
62
  }
63
63
  async openCamera() {
64
64
  await this.baseComponent.logStep(FlowSteps.CiFrontCapture, FlowMoments.Initialized);
65
- const constraints = store.device.isAppleDevice ? this.cameras.GetConstraintsIOs(store.device) : this.cameras.GetConstraints(store.cameraId, store.device);
65
+ //const constraints = store.device.isAppleDevice ? this.cameras.GetConstraintsIOs(store.device) : this.cameras.GetConstraints(store.cameraId, store.device);
66
+ const constraints = this.cameras.GetConstraints(store.cameraId, store.device);
66
67
  setTimeout(() => {
67
68
  navigator.mediaDevices
68
69
  .getUserMedia(constraints)
@@ -72,7 +72,7 @@ export class SelfieCapture {
72
72
  }
73
73
  async openCamera() {
74
74
  await this.baseComponent.logStep(FlowSteps.SelfieCapture, FlowMoments.Initialized);
75
- const constraints = store.device.isAppleDevice ? this.cameras.GetConstraintsIOs(store.device, true) : this.cameras.GetConstraints('', store.device, true);
75
+ const constraints = this.cameras.GetConstraints('', store.device, true);
76
76
  setTimeout(() => {
77
77
  navigator.mediaDevices
78
78
  .getUserMedia(constraints)
@@ -58,8 +58,6 @@ export class Camera {
58
58
  return (h("div", { class: "camera" }, h("video", { id: "video", loop: true, autoplay: true, playsinline: true, muted: true, class: cameraVideoClass, ref: el => (this.cameraVideo = el) }), h("canvas", { id: "output", class: cameraCanvasClass, ref: el => (this.cameraCanvas = el) })));
59
59
  }
60
60
  startStream() {
61
- if (!Stream.instance)
62
- Stream.getInstance(this.modelPath);
63
61
  const stream = Stream.getInstance();
64
62
  stream.updateHtmlElements(this.cameraVideo, this.cameraCanvas, this.component);
65
63
  if (this.captureMode == 'selfie') {
@@ -60,7 +60,7 @@ export class IdDoubleSide {
60
60
  }
61
61
  async captureIdImage(event) {
62
62
  let idPhoto = event.detail;
63
- if (idPhoto.length == 0 || idPhoto.size == 0) {
63
+ if (idPhoto.size == 0) {
64
64
  await this.baseComponent.apiCall.AddLog({ message: 'Empty id photo', blobData: idPhoto }, getLogMessage());
65
65
  this.triggerErrorFlow();
66
66
  return;
@@ -75,7 +75,7 @@ export class IdDoubleSide {
75
75
  }
76
76
  async captureIdBackImage(event) {
77
77
  let idPhoto = event.detail;
78
- if (idPhoto.length == 0 || idPhoto.size == 0) {
78
+ if (idPhoto.size == 0) {
79
79
  await this.baseComponent.apiCall.AddLog({ message: 'Empty id photo', blobData: idPhoto }, getLogMessage());
80
80
  this.triggerErrorFlow();
81
81
  return;
@@ -90,7 +90,7 @@ export class IdDoubleSide {
90
90
  }
91
91
  async capturedIdRecording(event) {
92
92
  let idRecording = event.detail;
93
- if (idRecording.length == 0 || idRecording.size == 0) {
93
+ if (idRecording.size == 0) {
94
94
  await this.baseComponent.apiCall.AddLog({ message: 'Empty recording', blobData: idRecording }, getLogMessage());
95
95
  this.triggerErrorFlow();
96
96
  return;
@@ -26,22 +26,17 @@ export class IdSingleSide {
26
26
  this.idFlow.photoFile = null;
27
27
  this.idFlow.recordingFile = null;
28
28
  this.showTimeout = false;
29
- this.errorMessage = '';
30
29
  }
31
30
  howToDone() {
32
31
  this.showHowTo = false;
33
32
  }
34
33
  timeElapsed() {
35
34
  this.showTimeout = true;
36
- this.errorMessage = 'timeout';
37
35
  }
38
36
  async captureIdImage(event) {
39
- console.log('photoIdCapture');
40
- console.log(event);
41
37
  let idPhoto = event.detail;
42
- if (idPhoto.length == 0 || idPhoto.size == 0) {
38
+ if (idPhoto.size == 0) {
43
39
  await this.baseComponent.apiCall.AddLog({ message: 'Empty id photo', blobData: idPhoto }, getLogMessage());
44
- this.errorMessage = 'Empty id photo';
45
40
  this.showTimeout = true;
46
41
  return;
47
42
  }
@@ -58,12 +53,9 @@ export class IdSingleSide {
58
53
  await this.endFlow();
59
54
  }
60
55
  async capturedIdRecording(event) {
61
- console.log('recordingIdCapture');
62
- console.log(event);
63
56
  let idRecording = event.detail;
64
- if (idRecording.length == 0 || idRecording.size == 0) {
57
+ if (idRecording.size == 0) {
65
58
  await this.baseComponent.apiCall.AddLog({ message: 'Empty ID recording', blobData: idRecording }, getLogMessage());
66
- this.errorMessage = 'Empty id recording';
67
59
  this.showTimeout = true;
68
60
  return;
69
61
  }
@@ -93,7 +85,6 @@ export class IdSingleSide {
93
85
  this.idFlow.photoFile = null;
94
86
  this.idFlow.recordingFile = null;
95
87
  this.switchCamera();
96
- this.errorMessage = 'Upload photo not successful';
97
88
  this.showTimeout = true;
98
89
  }
99
90
  }
@@ -108,7 +99,6 @@ export class IdSingleSide {
108
99
  else {
109
100
  this.idFlow.photoFile = null;
110
101
  this.idFlow.recordingFile = null;
111
- this.errorMessage = 'Upload recording not successful';
112
102
  this.showTimeout = true;
113
103
  }
114
104
  }
@@ -138,7 +128,7 @@ export class IdSingleSide {
138
128
  }
139
129
  }
140
130
  render() {
141
- let error = h("capture-error", { type: "ID", message: this.errorMessage });
131
+ let error = h("capture-error", { type: "ID" });
142
132
  let capture = h("id-capture", { id: "idFront" });
143
133
  let howToInfo = h("how-to-info", { idSide: "front" });
144
134
  return this.showHowTo ? howToInfo : this.showTimeout ? error : capture;
@@ -40,7 +40,7 @@ export class UserLiveness {
40
40
  }
41
41
  async captureSelfieImage(event) {
42
42
  let selfiePhoto = event.detail;
43
- if (selfiePhoto.length == 0 || selfiePhoto.size == 0) {
43
+ if (selfiePhoto.size == 0) {
44
44
  await this.baseComponent.apiCall.AddLog({ message: 'Empty selfie', blobData: selfiePhoto }, getLogMessage());
45
45
  this.triggerErrorFlow();
46
46
  return;
@@ -55,7 +55,7 @@ export class UserLiveness {
55
55
  }
56
56
  async capturedSelfieRecording(event) {
57
57
  let selfieRecording = event.detail;
58
- if (selfieRecording.length == 0 || selfieRecording.size == 0) {
58
+ if (selfieRecording.size == 0) {
59
59
  await this.baseComponent.apiCall.AddLog({ message: 'Empty recording', blobData: selfieRecording }, getLogMessage());
60
60
  this.triggerErrorFlow();
61
61
  return;
@@ -6,7 +6,8 @@ export class Cameras {
6
6
  const devices = await navigator.mediaDevices.enumerateDevices();
7
7
  const videoDevices = devices.filter(device => device.kind === 'videoinput');
8
8
  for (const device of videoDevices) {
9
- const updatedConstraints = deviceInfo.isAppleDevice ? this.GetConstraintsIOs(deviceInfo) : this.GetConstraints(device.deviceId, deviceInfo);
9
+ //const updatedConstraints = deviceInfo.isAppleDevice ? this.GetConstraintsIOs(deviceInfo) : this.GetConstraints(device.deviceId, deviceInfo);
10
+ const updatedConstraints = this.GetConstraints(device.deviceId, deviceInfo);
10
11
  const stream = await navigator.mediaDevices.getUserMedia(updatedConstraints);
11
12
  stream.getVideoTracks().forEach(track => {
12
13
  var _a, _b;
@@ -94,29 +95,27 @@ export class Cameras {
94
95
  constraints.video = mediaTrack;
95
96
  return constraints;
96
97
  }
97
- GetConstraintsIOs(device, portrait = false) {
98
- let constraints = {
99
- audio: false,
100
- };
101
- let mediaTrack = {};
102
- if (device.isDesktop) {
103
- mediaTrack.width = 1280;
104
- }
105
- else {
106
- if (portrait) {
107
- mediaTrack.facingMode = 'user';
108
- mediaTrack.width = 1280;
109
- mediaTrack.height = 720;
110
- }
111
- else {
112
- mediaTrack.facingMode = 'environment';
113
- mediaTrack.width = 1280;
114
- mediaTrack.height = 720;
115
- }
116
- }
117
- constraints.video = mediaTrack;
118
- return constraints;
119
- }
98
+ // public GetConstraintsIOs(device: DeviceState, portrait: boolean = false): MediaStreamConstraints | any {
99
+ // let constraints: MediaStreamConstraints = {
100
+ // audio: false,
101
+ // };
102
+ // let mediaTrack: MediaTrackConstraints = {};
103
+ // if (device.isDesktop) {
104
+ // mediaTrack.width = 1280;
105
+ // } else {
106
+ // if (portrait) {
107
+ // mediaTrack.facingMode = 'user';
108
+ // mediaTrack.width = 1280;
109
+ // mediaTrack.height = 720;
110
+ // } else {
111
+ // mediaTrack.facingMode = 'environment';
112
+ // mediaTrack.width = 1280;
113
+ // mediaTrack.height = 720;
114
+ // }
115
+ // }
116
+ // constraints.video = mediaTrack;
117
+ // return constraints;
118
+ // }
120
119
  GetRecommendedCamera(cameras) {
121
120
  if (cameras && cameras.length > 0) {
122
121
  var recommDevice = cameras.find(c => c.recommended);
@@ -46,7 +46,7 @@ export class Stream {
46
46
  setVerificationFinished(fun) {
47
47
  this.verificationFinished = fun;
48
48
  }
49
- constructor(_modelPath) {
49
+ constructor() {
50
50
  this.streamPaused = false;
51
51
  this.recordedChunks = [];
52
52
  this.videoSize = { width: 0, height: 0 };
@@ -60,9 +60,9 @@ export class Stream {
60
60
  this.idML5Detector = IDML5Detector.getInstance(this, store.device.isMobile);
61
61
  this.faceML5Detector = FaceML5Detector.getInstance(this, store.device.isMobile);
62
62
  }
63
- static getInstance(modelPath) {
63
+ static getInstance() {
64
64
  if (!Stream.instance) {
65
- Stream.instance = new Stream(modelPath);
65
+ Stream.instance = new Stream();
66
66
  }
67
67
  return Stream.instance;
68
68
  }
@@ -112,6 +112,7 @@ export class Stream {
112
112
  async initStream(stream) {
113
113
  this.startStream(stream);
114
114
  this.recordStream();
115
+ console.log('Stream initialized');
115
116
  }
116
117
  async resumeStream() {
117
118
  this.streamPaused = false;
@@ -121,6 +122,8 @@ export class Stream {
121
122
  // if (this.faceDetection) await Detector.getInstance().startDetector();
122
123
  }
123
124
  recordStream() {
125
+ if (this.mediaRecorder && this.mediaRecorder.state == 'recording')
126
+ return;
124
127
  var options = { mimeType: Stream.webmMimeType.mime, videoBitsPerSecond: 1500000 };
125
128
  if (!MediaRecorder.isTypeSupported(options.mimeType)) {
126
129
  if (store.device.mobileOS == MobileOS.iOS || store.device.browser == Browser.Safari)