@ahmed_hani/dot-document-auto-capture 7.4.0 → 7.6.1

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.
Binary file
package/events.mjs CHANGED
@@ -1,48 +1,51 @@
1
1
  const u = {};
2
2
  u.CONTINUE_DETECTION = "continue-detection", u.SWITCH_CAMERA = "switch-camera", u.TOGGLE_MIRROR = "toggle-mirror";
3
- const D = u, s = {};
3
+ const l = u, s = {};
4
4
  s.FIRST_FRAME = "first-frame", s.FIRST_VALID_FRAME = "first-valid-frame";
5
- const l = s, N = {};
5
+ const G = s, N = {};
6
6
  N.REQUEST_CAPTURE = "dot-custom-event:request-capture";
7
- const _ = N;
8
- var i = ((t) => (t.CAMERA_PROPS_CHANGED = "document-auto-capture:camera-props-changed", t.CONTROL = "document-auto-capture:control", t.DETECTED_DOCUMENT_CHANGED = "document-auto-capture:detected-document-changed", t.DOCUMENT_DETECTION = "document-auto-capture:document-detection", t.INSTRUCTION_CHANGED = "document-auto-capture:instruction-changed", t.INSTRUCTION_ESCALATED = "document-auto-capture:instruction-escalated", t.STATE_CHANGED = "document-auto-capture:state-changed", t.VIDEO_ELEMENT_SIZE = "document-auto-capture:video-element-size", t))(i || {}), A = ((t) => (t.CAMERA_PROPS_CHANGED = "face-auto-capture:camera-props-changed", t.CONTROL = "face-auto-capture:control", t.DETECTED_FACE_CHANGED = "face-auto-capture:detected-face-changed", t.FACE_DETECTION = "face-auto-capture:face-detection", t.INSTRUCTION_CHANGED = "face-auto-capture:instruction-changed", t.STATE_CHANGED = "face-auto-capture:state-changed", t.VIDEO_ELEMENT_SIZE = "face-auto-capture:video-element-size", t))(A || {}), R = ((t) => (t.ANIMATION_END = "magnifeye-auto-capture:animation-end", t.CONTROL = "magnifeye-auto-capture:control", t.STATUS_CHANGED = "magnifeye-auto-capture:status-changed", t))(R || {}), p = ((t) => (t.CONTROL = "smile-auto-capture:control", t.INSTRUCTION_ESCALATED = "smile:instruction-escalated", t.STATUS_CHANGED = "smile-auto-capture:status-changed", t))(p || {}), m = ((t) => (t.CAMERA_PROPS_CHANGED = "palm-capture:camera-props-changed", t.CONTROL = "palm-capture:control", t.DETECTED_PALM_CHANGED = "palm-capture:detected-palm-changed", t.INSTRUCTION_CHANGED = "palm-capture:instruction-changed", t.STATE_CHANGED = "palm-capture:state-changed", t.VIDEO_ELEMENT_SIZE = "palm-capture:video-element-size", t))(m || {}), S = ((t) => (t.CONTROL = "eye-gaze-auto-capture:control", t.STATUS_CHANGED = "eye-gaze-auto-capture:status-changed", t))(S || {});
9
- const O = (t, c) => {
7
+ const i = N;
8
+ var R = ((t) => (t.CAMERA_PROPS_CHANGED = "document-auto-capture:camera-props-changed", t.CONTROL = "document-auto-capture:control", t.DETECTED_DOCUMENT_CHANGED = "document-auto-capture:detected-document-changed", t.DOCUMENT_DETECTION = "document-auto-capture:document-detection", t.INSTRUCTION_CHANGED = "document-auto-capture:instruction-changed", t.INSTRUCTION_ESCALATED = "document-auto-capture:instruction-escalated", t.STATE_CHANGED = "document-auto-capture:state-changed", t.VIDEO_ELEMENT_SIZE = "document-auto-capture:video-element-size", t))(R || {}), p = ((t) => (t.CAMERA_PROPS_CHANGED = "face-auto-capture:camera-props-changed", t.CONTROL = "face-auto-capture:control", t.DETECTED_FACE_CHANGED = "face-auto-capture:detected-face-changed", t.FACE_DETECTION = "face-auto-capture:face-detection", t.INSTRUCTION_CHANGED = "face-auto-capture:instruction-changed", t.STATE_CHANGED = "face-auto-capture:state-changed", t.VIDEO_ELEMENT_SIZE = "face-auto-capture:video-element-size", t))(p || {}), A = ((t) => (t.ANIMATION_END = "magnifeye-auto-capture:animation-end", t.CONTROL = "magnifeye-auto-capture:control", t.STATUS_CHANGED = "magnifeye-auto-capture:status-changed", t))(A || {}), S = ((t) => (t.CONTROL = "smile-auto-capture:control", t.INSTRUCTION_ESCALATED = "smile:instruction-escalated", t.STATUS_CHANGED = "smile-auto-capture:status-changed", t))(S || {}), d = ((t) => (t.CAMERA_PROPS_CHANGED = "palm-capture:camera-props-changed", t.CONTROL = "palm-capture:control", t.DETECTED_PALM_CHANGED = "palm-capture:detected-palm-changed", t.INSTRUCTION_CHANGED = "palm-capture:instruction-changed", t.STATE_CHANGED = "palm-capture:state-changed", t.VIDEO_ELEMENT_SIZE = "palm-capture:video-element-size", t))(d || {}), m = ((t) => (t.CONTROL = "eye-gaze-auto-capture:control", t.STATUS_CHANGED = "eye-gaze-auto-capture:status-changed", t))(m || {});
9
+ const O = (t, E) => {
10
10
  const n = {};
11
- n.detail = c, document.dispatchEvent(new CustomEvent(t, n));
12
- }, G = (t, c) => {
11
+ n.detail = E, document.dispatchEvent(new CustomEvent(t, n));
12
+ }, g = (t, E) => {
13
13
  const n = {};
14
- n.instruction = c, O(t, n);
14
+ n.instruction = E, O(t, n);
15
15
  };
16
- function g(t) {
17
- const c = {};
18
- c.instruction = t;
19
- const n = c;
20
- O(_.REQUEST_CAPTURE, n);
16
+ function h(t) {
17
+ const E = {};
18
+ E.instruction = t;
19
+ const n = E;
20
+ O(i.REQUEST_CAPTURE, n);
21
21
  }
22
22
  const T = {};
23
23
  T.FRONT = "user", T.REAR = "environment";
24
- const h = T, r = {};
24
+ const H = T, r = {};
25
25
  r.AUTO_CAPTURE = "AUTO_CAPTURE", r.WAIT_FOR_REQUEST = "WAIT_FOR_REQUEST";
26
- const H = r, E = {};
27
- E.LOADING = "LOADING", E.ERROR = "ERROR", E.WAITING = "WAITING", E.RUNNING = "RUNNING";
28
- const d = E, C = { ...d };
26
+ const U = r, c = {};
27
+ c.LOADING = "LOADING", c.ERROR = "ERROR", c.WAITING = "WAITING", c.RUNNING = "RUNNING", c.COMPLETE = "COMPLETE";
28
+ const I = c, C = { ...I };
29
29
  C.DONE = "DONE";
30
- const U = C, e = {};
30
+ const v = C, _ = {};
31
+ _.EYE_NOT_PRESENT = "eye_not_present";
32
+ const M = _, e = {};
31
33
  e.CANDIDATE_SELECTION = "candidate_selection", e.DOCUMENT_CENTERING = "document_centering", e.DOCUMENT_NOT_PRESENT = "document_not_present", e.DOCUMENT_TOO_FAR = "document_too_far", e.SHARPNESS_TOO_LOW = "sharpness_too_low", e.BRIGHTNESS_TOO_LOW = "brightness_too_low", e.BRIGHTNESS_TOO_HIGH = "brightness_too_high", e.HOTSPOTS_PRESENT = "hotspots_present";
32
34
  const a = e, o = {};
33
35
  o.isPresent = a.DOCUMENT_NOT_PRESENT, o.isNotSmall = a.DOCUMENT_TOO_FAR, o.isNotOutOfBounds = a.DOCUMENT_CENTERING, o.isSharp = a.SHARPNESS_TOO_LOW, o.isNotDim = a.BRIGHTNESS_TOO_LOW, o.isNotBright = a.BRIGHTNESS_TOO_HIGH, o.noHotspots = a.HOTSPOTS_PRESENT;
34
- const f = o;
36
+ const L = o;
35
37
  export {
36
- d as AppStateValues,
37
- H as CaptureMode,
38
- _ as ComponentCustomEvent,
39
- D as ControlEventInstruction,
40
- f as DocumentCheckToInstructionCodeMap,
41
- i as DocumentCustomEvent,
38
+ I as AppStateValues,
39
+ U as CaptureMode,
40
+ i as ComponentCustomEvent,
41
+ l as ControlEventInstruction,
42
+ L as DocumentCheckToInstructionCodeMap,
43
+ R as DocumentCustomEvent,
42
44
  a as DocumentInstructionCodeValues,
43
- h as FacingMode,
44
- U as LivenessStateValues,
45
- l as RequestCaptureInstruction,
46
- g as dispatchCaptureEvent,
47
- G as dispatchControlEvent
45
+ M as EyeInstructionCodeValues,
46
+ H as FacingMode,
47
+ v as LivenessStateValues,
48
+ G as RequestCaptureInstruction,
49
+ h as dispatchCaptureEvent,
50
+ g as dispatchControlEvent
48
51
  };
package/events.umd.js CHANGED
@@ -1 +1 @@
1
- (function(e,o){typeof exports=="object"&&typeof module<"u"?o(exports):typeof define=="function"&&define.amd?define(["exports"],o):(e=typeof globalThis<"u"?globalThis:e||self,o(e["@innovatrics/dot-events-auto-capture"]={}))})(this,function(e){"use strict";const o={};o.CONTINUE_DETECTION="continue-detection",o.SWITCH_CAMERA="switch-camera",o.TOGGLE_MIRROR="toggle-mirror";const p=o,T={};T.FIRST_FRAME="first-frame",T.FIRST_VALID_FRAME="first-valid-frame";const A=T,C={};C.REQUEST_CAPTURE="dot-custom-event:request-capture";const N=C;var O=(t=>(t.CAMERA_PROPS_CHANGED="document-auto-capture:camera-props-changed",t.CONTROL="document-auto-capture:control",t.DETECTED_DOCUMENT_CHANGED="document-auto-capture:detected-document-changed",t.DOCUMENT_DETECTION="document-auto-capture:document-detection",t.INSTRUCTION_CHANGED="document-auto-capture:instruction-changed",t.INSTRUCTION_ESCALATED="document-auto-capture:instruction-escalated",t.STATE_CHANGED="document-auto-capture:state-changed",t.VIDEO_ELEMENT_SIZE="document-auto-capture:video-element-size",t))(O||{}),R=(t=>(t.CAMERA_PROPS_CHANGED="face-auto-capture:camera-props-changed",t.CONTROL="face-auto-capture:control",t.DETECTED_FACE_CHANGED="face-auto-capture:detected-face-changed",t.FACE_DETECTION="face-auto-capture:face-detection",t.INSTRUCTION_CHANGED="face-auto-capture:instruction-changed",t.STATE_CHANGED="face-auto-capture:state-changed",t.VIDEO_ELEMENT_SIZE="face-auto-capture:video-element-size",t))(R||{}),S=(t=>(t.ANIMATION_END="magnifeye-auto-capture:animation-end",t.CONTROL="magnifeye-auto-capture:control",t.STATUS_CHANGED="magnifeye-auto-capture:status-changed",t))(S||{}),I=(t=>(t.CONTROL="smile-auto-capture:control",t.INSTRUCTION_ESCALATED="smile:instruction-escalated",t.STATUS_CHANGED="smile-auto-capture:status-changed",t))(I||{}),D=(t=>(t.CAMERA_PROPS_CHANGED="palm-capture:camera-props-changed",t.CONTROL="palm-capture:control",t.DETECTED_PALM_CHANGED="palm-capture:detected-palm-changed",t.INSTRUCTION_CHANGED="palm-capture:instruction-changed",t.STATE_CHANGED="palm-capture:state-changed",t.VIDEO_ELEMENT_SIZE="palm-capture:video-element-size",t))(D||{}),l=(t=>(t.CONTROL="eye-gaze-auto-capture:control",t.STATUS_CHANGED="eye-gaze-auto-capture:status-changed",t))(l||{});const d=(t,E)=>{const u={};u.detail=E,document.dispatchEvent(new CustomEvent(t,u))},f=(t,E)=>{const u={};u.instruction=E,d(t,u)};function h(t){const E={};E.instruction=t;const u=E;d(N.REQUEST_CAPTURE,u)}const r={};r.FRONT="user",r.REAR="environment";const v=r,i={};i.AUTO_CAPTURE="AUTO_CAPTURE",i.WAIT_FOR_REQUEST="WAIT_FOR_REQUEST";const g=i,s={};s.LOADING="LOADING",s.ERROR="ERROR",s.WAITING="WAITING",s.RUNNING="RUNNING";const _=s,m={..._};m.DONE="DONE";const G=m,n={};n.CANDIDATE_SELECTION="candidate_selection",n.DOCUMENT_CENTERING="document_centering",n.DOCUMENT_NOT_PRESENT="document_not_present",n.DOCUMENT_TOO_FAR="document_too_far",n.SHARPNESS_TOO_LOW="sharpness_too_low",n.BRIGHTNESS_TOO_LOW="brightness_too_low",n.BRIGHTNESS_TOO_HIGH="brightness_too_high",n.HOTSPOTS_PRESENT="hotspots_present";const a=n,c={};c.isPresent=a.DOCUMENT_NOT_PRESENT,c.isNotSmall=a.DOCUMENT_TOO_FAR,c.isNotOutOfBounds=a.DOCUMENT_CENTERING,c.isSharp=a.SHARPNESS_TOO_LOW,c.isNotDim=a.BRIGHTNESS_TOO_LOW,c.isNotBright=a.BRIGHTNESS_TOO_HIGH,c.noHotspots=a.HOTSPOTS_PRESENT;const H=c;e.AppStateValues=_,e.CaptureMode=g,e.ComponentCustomEvent=N,e.ControlEventInstruction=p,e.DocumentCheckToInstructionCodeMap=H,e.DocumentCustomEvent=O,e.DocumentInstructionCodeValues=a,e.FacingMode=v,e.LivenessStateValues=G,e.RequestCaptureInstruction=A,e.dispatchCaptureEvent=h,e.dispatchControlEvent=f,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})});
1
+ (function(e,o){typeof exports=="object"&&typeof module<"u"?o(exports):typeof define=="function"&&define.amd?define(["exports"],o):(e=typeof globalThis<"u"?globalThis:e||self,o(e["@innovatrics/dot-events-auto-capture"]={}))})(this,function(e){"use strict";const o={};o.CONTINUE_DETECTION="continue-detection",o.SWITCH_CAMERA="switch-camera",o.TOGGLE_MIRROR="toggle-mirror";const R=o,T={};T.FIRST_FRAME="first-frame",T.FIRST_VALID_FRAME="first-valid-frame";const A=T,C={};C.REQUEST_CAPTURE="dot-custom-event:request-capture";const N=C;var O=(t=>(t.CAMERA_PROPS_CHANGED="document-auto-capture:camera-props-changed",t.CONTROL="document-auto-capture:control",t.DETECTED_DOCUMENT_CHANGED="document-auto-capture:detected-document-changed",t.DOCUMENT_DETECTION="document-auto-capture:document-detection",t.INSTRUCTION_CHANGED="document-auto-capture:instruction-changed",t.INSTRUCTION_ESCALATED="document-auto-capture:instruction-escalated",t.STATE_CHANGED="document-auto-capture:state-changed",t.VIDEO_ELEMENT_SIZE="document-auto-capture:video-element-size",t))(O||{}),S=(t=>(t.CAMERA_PROPS_CHANGED="face-auto-capture:camera-props-changed",t.CONTROL="face-auto-capture:control",t.DETECTED_FACE_CHANGED="face-auto-capture:detected-face-changed",t.FACE_DETECTION="face-auto-capture:face-detection",t.INSTRUCTION_CHANGED="face-auto-capture:instruction-changed",t.STATE_CHANGED="face-auto-capture:state-changed",t.VIDEO_ELEMENT_SIZE="face-auto-capture:video-element-size",t))(S||{}),I=(t=>(t.ANIMATION_END="magnifeye-auto-capture:animation-end",t.CONTROL="magnifeye-auto-capture:control",t.STATUS_CHANGED="magnifeye-auto-capture:status-changed",t))(I||{}),D=(t=>(t.CONTROL="smile-auto-capture:control",t.INSTRUCTION_ESCALATED="smile:instruction-escalated",t.STATUS_CHANGED="smile-auto-capture:status-changed",t))(D||{}),l=(t=>(t.CAMERA_PROPS_CHANGED="palm-capture:camera-props-changed",t.CONTROL="palm-capture:control",t.DETECTED_PALM_CHANGED="palm-capture:detected-palm-changed",t.INSTRUCTION_CHANGED="palm-capture:instruction-changed",t.STATE_CHANGED="palm-capture:state-changed",t.VIDEO_ELEMENT_SIZE="palm-capture:video-element-size",t))(l||{}),h=(t=>(t.CONTROL="eye-gaze-auto-capture:control",t.STATUS_CHANGED="eye-gaze-auto-capture:status-changed",t))(h||{});const d=(t,s)=>{const u={};u.detail=s,document.dispatchEvent(new CustomEvent(t,u))},v=(t,s)=>{const u={};u.instruction=s,d(t,u)};function g(t){const s={};s.instruction=t;const u=s;d(N.REQUEST_CAPTURE,u)}const r={};r.FRONT="user",r.REAR="environment";const G=r,i={};i.AUTO_CAPTURE="AUTO_CAPTURE",i.WAIT_FOR_REQUEST="WAIT_FOR_REQUEST";const M=i,E={};E.LOADING="LOADING",E.ERROR="ERROR",E.WAITING="WAITING",E.RUNNING="RUNNING",E.COMPLETE="COMPLETE";const _=E,m={..._};m.DONE="DONE";const H=m,p={};p.EYE_NOT_PRESENT="eye_not_present";const U=p,n={};n.CANDIDATE_SELECTION="candidate_selection",n.DOCUMENT_CENTERING="document_centering",n.DOCUMENT_NOT_PRESENT="document_not_present",n.DOCUMENT_TOO_FAR="document_too_far",n.SHARPNESS_TOO_LOW="sharpness_too_low",n.BRIGHTNESS_TOO_LOW="brightness_too_low",n.BRIGHTNESS_TOO_HIGH="brightness_too_high",n.HOTSPOTS_PRESENT="hotspots_present";const a=n,c={};c.isPresent=a.DOCUMENT_NOT_PRESENT,c.isNotSmall=a.DOCUMENT_TOO_FAR,c.isNotOutOfBounds=a.DOCUMENT_CENTERING,c.isSharp=a.SHARPNESS_TOO_LOW,c.isNotDim=a.BRIGHTNESS_TOO_LOW,c.isNotBright=a.BRIGHTNESS_TOO_HIGH,c.noHotspots=a.HOTSPOTS_PRESENT;const L=c;e.AppStateValues=_,e.CaptureMode=M,e.ComponentCustomEvent=N,e.ControlEventInstruction=R,e.DocumentCheckToInstructionCodeMap=L,e.DocumentCustomEvent=O,e.DocumentInstructionCodeValues=a,e.EyeInstructionCodeValues=U,e.FacingMode=G,e.LivenessStateValues=H,e.RequestCaptureInstruction=A,e.dispatchCaptureEvent=g,e.dispatchControlEvent=v,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})});