onfido-sdk-ui 14.10.0-rc.0 → 14.13.0-rc.0

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/Onfido.iife.js CHANGED
@@ -1 +1 @@
1
- var a=Object.defineProperty;var v=(h,s,d)=>s in h?a(h,s,{enumerable:!0,configurable:!0,writable:!0,value:d}):h[s]=d;var o=(h,s,d)=>(v(h,typeof s!="symbol"?s+"":s,d),d);(function(h){"use strict";class s{constructor(){this.eventListener={}}addEventListener(n,e){return this.eventListener[n]=this.eventListener[n]||[],this.eventListener[n].push(e),this}removeEventListener(n,e){const t=this.eventListener[n];if(t){let i;for(;(i=t.indexOf(e))!==-1;)t.splice(i,1)}}trigger(n,e){e.type=n,(this.eventListener[n]||[]).forEach(t=>{t(e)})}}const d="v14";class l extends s{constructor(){super(...arguments);o(this,"_handle");o(this,"_handleSetCallbacks",[])}_setHandle(e){this._handle=e,this._handleSetCallbacks.forEach(t=>t(e)),this._handleSetCallbacks=[],Object.entries(this.eventListener).forEach(([t,i])=>{e.addEventListener(t,i)}),this.eventListener={}}addEventListener(e,t){return this._handle?(this._handle.addEventListener(e,t),this):super.addEventListener(e,t)}removeEventListener(e,t){if(this._handle)return this._handle.removeEventListener(e,t),this;super.removeEventListener(e,t)}tearDown(){var e;this._handle?(e=this._handle)==null||e.tearDown():this._handleSetCallbacks.push(()=>{this.tearDown()})}}const c={init(r){const n=new l;return import(r.sdkUrl||`https://sdk.onfido.com/${r.version||d}/Onfido.js`).then(t=>{const{Onfido:i}=t;n._setHandle(i.init(r))}).catch(t=>{var i;n.trigger("error",{error:t}),(i=r.onError)==null||i.call(r,t)}),n}};h.Onfido=c,Object.defineProperty(h,Symbol.toStringTag,{value:"Module"})})(this.window=this.window||{});
1
+ var v=Object.defineProperty;var L=(i,r,d)=>r in i?v(i,r,{enumerable:!0,configurable:!0,writable:!0,value:d}):i[r]=d;var o=(i,r,d)=>(L(i,typeof r!="symbol"?r+"":r,d),d);(function(i){"use strict";class r{constructor(){this.eventListener={}}addEventListener(n,e){return this.eventListener[n]=this.eventListener[n]||[],this.eventListener[n].push(e),this}removeEventListener(n,e){const t=this.eventListener[n];if(t){let h;for(;(h=t.indexOf(e))!==-1;)t.splice(h,1)}}trigger(n,e){e.type=n,(this.eventListener[n]||[]).forEach(t=>{t(e)})}}const d="v14";class c extends r{constructor(){super(...arguments);o(this,"_handle");o(this,"_handleSetCallbacks",[])}_setHandle(e){this._handle=e,this._handleSetCallbacks.forEach(t=>t(e)),this._handleSetCallbacks=[],Object.entries(this.eventListener).forEach(([t,h])=>{e.addEventListener(t,h)}),this.eventListener={}}addEventListener(e,t){return this._handle?(this._handle.addEventListener(e,t),this):super.addEventListener(e,t)}removeEventListener(e,t){if(this._handle)return this._handle.removeEventListener(e,t),this;super.removeEventListener(e,t)}tearDown(){var e;this._handle?(e=this._handle)==null||e.tearDown():this._handleSetCallbacks.push(()=>{this.tearDown()})}}const l=s=>`v${(s||d).replace(/^v/,"")}`,a={init(s){const n=new c;return import(s.sdkUrl||`https://sdk.onfido.com/${l(s.version)}/Onfido.js`).then(t=>{const{Onfido:h}=t;n._setHandle(h.init(s))}).catch(t=>{var h;n.trigger("error",{error:t}),(h=s.onError)==null||h.call(s,t)}),n}};i.Onfido=a,i.prefixVersion=l,Object.defineProperty(i,Symbol.toStringTag,{value:"Module"})})(this.window=this.window||{});
package/Onfido.js CHANGED
@@ -1,6 +1,6 @@
1
- var r = Object.defineProperty;
2
- var d = (s, t, e) => t in s ? r(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e;
3
- var h = (s, t, e) => (d(s, typeof t != "symbol" ? t + "" : t, e), e);
1
+ var h = Object.defineProperty;
2
+ var d = (s, t, e) => t in s ? h(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e;
3
+ var r = (s, t, e) => (d(s, typeof t != "symbol" ? t + "" : t, e), e);
4
4
  class o {
5
5
  constructor() {
6
6
  this.eventListener = {};
@@ -26,8 +26,8 @@ const l = "v14";
26
26
  class c extends o {
27
27
  constructor() {
28
28
  super(...arguments);
29
- h(this, "_handle");
30
- h(this, "_handleSetCallbacks", []);
29
+ r(this, "_handle");
30
+ r(this, "_handleSetCallbacks", []);
31
31
  }
32
32
  _setHandle(e) {
33
33
  this._handle = e, this._handleSetCallbacks.forEach((n) => n(e)), this._handleSetCallbacks = [], Object.entries(this.eventListener).forEach(([n, i]) => {
@@ -49,10 +49,10 @@ class c extends o {
49
49
  });
50
50
  }
51
51
  }
52
- const v = {
52
+ const v = (s) => `v${(s || l).replace(/^v/, "")}`, L = {
53
53
  init(s) {
54
54
  const t = new c();
55
- return import(s.sdkUrl || `https://sdk.onfido.com/${s.version || l}/Onfido.js`).then((n) => {
55
+ return import(s.sdkUrl || `https://sdk.onfido.com/${v(s.version)}/Onfido.js`).then((n) => {
56
56
  const { Onfido: i } = n;
57
57
  t._setHandle(i.init(s));
58
58
  }).catch((n) => {
@@ -62,5 +62,6 @@ const v = {
62
62
  }
63
63
  };
64
64
  export {
65
- v as Onfido
65
+ L as Onfido,
66
+ v as prefixVersion
66
67
  };
package/Onfido.umd.cjs CHANGED
@@ -1 +1 @@
1
- (function(n,s){typeof exports=="object"&&typeof module<"u"?s(exports):typeof define=="function"&&define.amd?define(["exports"],s):(n=typeof globalThis<"u"?globalThis:n||self,s(n.window=n.window||{}))})(this,function(n){"use strict";var f=Object.defineProperty;var v=(n,s,h)=>s in n?f(n,s,{enumerable:!0,configurable:!0,writable:!0,value:h}):n[s]=h;var r=(n,s,h)=>(v(n,typeof s!="symbol"?s+"":s,h),h);class s{constructor(){this.eventListener={}}addEventListener(i,e){return this.eventListener[i]=this.eventListener[i]||[],this.eventListener[i].push(e),this}removeEventListener(i,e){const t=this.eventListener[i];if(t){let d;for(;(d=t.indexOf(e))!==-1;)t.splice(d,1)}}trigger(i,e){e.type=i,(this.eventListener[i]||[]).forEach(t=>{t(e)})}}const h="v14";class l extends s{constructor(){super(...arguments);r(this,"_handle");r(this,"_handleSetCallbacks",[])}_setHandle(e){this._handle=e,this._handleSetCallbacks.forEach(t=>t(e)),this._handleSetCallbacks=[],Object.entries(this.eventListener).forEach(([t,d])=>{e.addEventListener(t,d)}),this.eventListener={}}addEventListener(e,t){return this._handle?(this._handle.addEventListener(e,t),this):super.addEventListener(e,t)}removeEventListener(e,t){if(this._handle)return this._handle.removeEventListener(e,t),this;super.removeEventListener(e,t)}tearDown(){var e;this._handle?(e=this._handle)==null||e.tearDown():this._handleSetCallbacks.push(()=>{this.tearDown()})}}const c={init(o){const i=new l;return import(o.sdkUrl||`https://sdk.onfido.com/${o.version||h}/Onfido.js`).then(t=>{const{Onfido:d}=t;i._setHandle(d.init(o))}).catch(t=>{var d;i.trigger("error",{error:t}),(d=o.onError)==null||d.call(o,t)}),i}};n.Onfido=c,Object.defineProperty(n,Symbol.toStringTag,{value:"Module"})});
1
+ (function(n,i){typeof exports=="object"&&typeof module<"u"?i(exports):typeof define=="function"&&define.amd?define(["exports"],i):(n=typeof globalThis<"u"?globalThis:n||self,i(n.window=n.window||{}))})(this,function(n){"use strict";var v=Object.defineProperty;var a=(n,i,o)=>i in n?v(n,i,{enumerable:!0,configurable:!0,writable:!0,value:o}):n[i]=o;var h=(n,i,o)=>(a(n,typeof i!="symbol"?i+"":i,o),o);class i{constructor(){this.eventListener={}}addEventListener(s,e){return this.eventListener[s]=this.eventListener[s]||[],this.eventListener[s].push(e),this}removeEventListener(s,e){const t=this.eventListener[s];if(t){let r;for(;(r=t.indexOf(e))!==-1;)t.splice(r,1)}}trigger(s,e){e.type=s,(this.eventListener[s]||[]).forEach(t=>{t(e)})}}const o="v14";class c extends i{constructor(){super(...arguments);h(this,"_handle");h(this,"_handleSetCallbacks",[])}_setHandle(e){this._handle=e,this._handleSetCallbacks.forEach(t=>t(e)),this._handleSetCallbacks=[],Object.entries(this.eventListener).forEach(([t,r])=>{e.addEventListener(t,r)}),this.eventListener={}}addEventListener(e,t){return this._handle?(this._handle.addEventListener(e,t),this):super.addEventListener(e,t)}removeEventListener(e,t){if(this._handle)return this._handle.removeEventListener(e,t),this;super.removeEventListener(e,t)}tearDown(){var e;this._handle?(e=this._handle)==null||e.tearDown():this._handleSetCallbacks.push(()=>{this.tearDown()})}}const l=d=>`v${(d||o).replace(/^v/,"")}`,f={init(d){const s=new c;return import(d.sdkUrl||`https://sdk.onfido.com/${l(d.version)}/Onfido.js`).then(t=>{const{Onfido:r}=t;s._setHandle(r.init(d))}).catch(t=>{var r;s.trigger("error",{error:t}),(r=d.onError)==null||r.call(d,t)}),s}};n.Onfido=f,n.prefixVersion=l,Object.defineProperty(n,Symbol.toStringTag,{value:"Module"})});
package/license CHANGED
@@ -1,17 +1,17 @@
1
1
  Please see the terms of your Onfido Services Agreement which you are bound by with respect to your use of the Onfido
2
2
  SDK. To the extent the Onfido SDK includes copies or substantial portions of software licenced under third party terms
3
- and conditions this will be set out at https://sdk.onfido.com/capture/core/14.10.0/license.
3
+ and conditions this will be set out at https://sdk.onfido.com/capture/core/14.13.0/license.
4
4
 
5
5
  In the event of any inconsistency between the Onfido Services Agreement and any third party terms and conditions, the
6
6
  third party terms and conditions shall take precedence over the rights and
7
7
  restrictions granted in the Onfido Services Agreement solely in respect of such third party dependencies set out
8
- at https://sdk.onfido.com/capture/core/14.10.0/license.
8
+ at https://sdk.onfido.com/capture/core/14.13.0/license.
9
9
 
10
10
  3rd party licenses
11
11
  ------------------
12
12
 
13
13
  Name: @onfido/capture-shared
14
- Version: 1.17.1
14
+ Version: 1.20.0
15
15
  License: null
16
16
  Private: false
17
17
  Description: A shared library to use in various capture packages
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "onfido-sdk-ui",
3
- "version": "14.10.0-rc.0",
3
+ "version": "14.13.0-rc.0",
4
4
  "description": "JavaScript SDK view layer for Onfido identity verification",
5
5
  "author": "Web SDK Customer Support <web-sdk@onfido.com> (https://github.com/onfido)",
6
6
  "repository": {
package/types/Types.d.ts CHANGED
@@ -1,19 +1,8 @@
1
- import type { CaptureModule, CrossDevicePolicy, EnterpriseFeatures, LocaleDirection, Theme, ThemeConfig, Translations } from './shared/Types';
1
+ import type { LegacyStepDefinition, LegacyStepType, CrossDevicePolicy, EnterpriseFeatures, LocaleDirection, Theme, ThemeConfig, Translations } from './shared/Types';
2
2
  import type { CrossDeviceMethod } from './shared/CrossDeviceConnect.types';
3
3
  import type { EnterpriseFeatureCallback } from './shared/Enterprise';
4
- export type LegacyStepType = 'welcome' | 'complete' | 'face' | 'consent' | 'document' | 'poa';
5
4
  export declare const legacySteps: LegacyStepType[];
6
5
  export declare const isLegacyStepType: (step: LegacyStepDefinition) => step is LegacyStepType;
7
- export type LegacyStepDefinition = LegacyStepType | StepDefinition;
8
- export type StepDefinition = {
9
- type: LegacyStepType | string;
10
- options?: Record<string, unknown>;
11
- module?: CaptureModule;
12
- /**
13
- * the key used to serialize the output for onComplete
14
- */
15
- key?: string;
16
- };
17
6
  export type CompleteData = Record<string, unknown>;
18
7
  export type ErrorType = any;
19
8
  export type EnterpriseFeatureParameter = EnterpriseFeatures & EnterpriseFeatureCallback;
@@ -73,6 +73,7 @@ export type ClientConfiguration = {
73
73
  anonymousUuid: string;
74
74
  sessionUuid: string;
75
75
  workflowRunId: string | undefined;
76
+ steps: LegacyStepDefinition[];
76
77
  };
77
78
  enterpriseFeatures?: EnterpriseFeatures;
78
79
  crossDeviceClientIntroProductName?: string;
@@ -159,7 +160,7 @@ export type TrackedEnvironmentData = {
159
160
  };
160
161
  export type CrossDeviceInitialState = unknown;
161
162
  export type CrossDeviceInput = {
162
- backAvailable: boolean;
163
+ backActionType?: 'module' | 'cross-module';
163
164
  };
164
165
  export declare enum CaptureModuleType {
165
166
  HOSTED = "hosted",
@@ -177,4 +178,15 @@ export type ExternalModule = {
177
178
  } & ModuleType<CaptureModuleType.EXTERNAL>;
178
179
  export type CaptureModule = HostedModule | ExternalModule;
179
180
  export type CrossDevicePolicy = 'enable' | 'force' | 'disable';
181
+ export type LegacyStepType = 'welcome' | 'complete' | 'face' | 'consent' | 'document' | 'poa';
182
+ export type LegacyStepDefinition = LegacyStepType | StepDefinition;
183
+ export type StepDefinition = {
184
+ type: LegacyStepType | string;
185
+ options?: Record<string, unknown>;
186
+ module?: CaptureModule;
187
+ /**
188
+ * the key used to serialize the output for onComplete
189
+ */
190
+ key?: string;
191
+ };
180
192
  export {};