smartcomply-web-sdk 1.0.78 → 1.0.79
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/client/Smartcomply.d.ts +10 -0
- package/dist/client/Smartcomply.d.ts.map +1 -1
- package/dist/client/Smartcomply.js +12 -0
- package/dist/client/Smartcomply.js.map +1 -1
- package/dist/esm/client/Smartcomply.d.ts +10 -0
- package/dist/esm/client/Smartcomply.d.ts.map +1 -1
- package/dist/esm/client/Smartcomply.js +12 -0
- package/dist/esm/client/Smartcomply.js.map +1 -1
- package/dist/esm/flow/SmartComplyFlow.d.ts +1 -0
- package/dist/esm/flow/SmartComplyFlow.d.ts.map +1 -1
- package/dist/esm/flow/SmartComplyFlow.js +22 -0
- package/dist/esm/flow/SmartComplyFlow.js.map +1 -1
- package/dist/esm/utils/logger.d.ts +7 -0
- package/dist/esm/utils/logger.d.ts.map +1 -1
- package/dist/esm/utils/logger.js +9 -0
- package/dist/esm/utils/logger.js.map +1 -1
- package/dist/flow/SmartComplyFlow.d.ts +1 -0
- package/dist/flow/SmartComplyFlow.d.ts.map +1 -1
- package/dist/flow/SmartComplyFlow.js +22 -0
- package/dist/flow/SmartComplyFlow.js.map +1 -1
- package/dist/smartcomply.browser.js +37 -1
- package/dist/smartcomply.browser.js.map +2 -2
- package/dist/utils/logger.d.ts +7 -0
- package/dist/utils/logger.d.ts.map +1 -1
- package/dist/utils/logger.js +9 -0
- package/dist/utils/logger.js.map +1 -1
- package/package.json +1 -1
|
@@ -12,6 +12,16 @@ import { SessionResponse, SDKInitConfig } from "../types/onboarding";
|
|
|
12
12
|
* // ... use sdk.onboarding and sdk.liveness modules
|
|
13
13
|
*/
|
|
14
14
|
export declare class SmartComply {
|
|
15
|
+
/**
|
|
16
|
+
* Package version, hardcoded to match package.json — bump this alongside
|
|
17
|
+
* every version bump there (same manual-sync convention already used for
|
|
18
|
+
* MEDIAPIPE_VERSION in camera/FaceDetector.ts). Exists so a client's
|
|
19
|
+
* running version can be confirmed directly (SmartComply.VERSION, or the
|
|
20
|
+
* console log on construction below) instead of trusting that whatever
|
|
21
|
+
* CDN tag they installed with (e.g. @1, which floats to the latest
|
|
22
|
+
* matching release) actually resolved to the version they expect.
|
|
23
|
+
*/
|
|
24
|
+
static readonly VERSION = "1.0.79";
|
|
15
25
|
private http;
|
|
16
26
|
private clientId;
|
|
17
27
|
private _sessionToken;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Smartcomply.d.ts","sourceRoot":"","sources":["../../src/client/Smartcomply.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAErC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"Smartcomply.d.ts","sourceRoot":"","sources":["../../src/client/Smartcomply.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAErC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAE9D,OAAO,EACL,eAAe,EACf,aAAa,EACd,MAAM,qBAAqB,CAAC;AAE7B;;;;;;;;GAQG;AACH,qBAAa,WAAW;IACtB;;;;;;;;OAQG;IACH,MAAM,CAAC,QAAQ,CAAC,OAAO,YAAY;IAEnC,OAAO,CAAC,IAAI,CAAa;IACzB,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,aAAa,CAAuB;IAC5C,OAAO,CAAC,iBAAiB,CAAuB;IAChD,OAAO,CAAC,UAAU,CAA8B;IAEzC,UAAU,EAAE,gBAAgB,CAAC;IAC7B,QAAQ,EAAE,cAAc,CAAC;gBAEpB,MAAM,EAAE,SAAS;IAiB7B,sDAAsD;IACtD,IAAI,YAAY,IAAI,MAAM,GAAG,IAAI,CAEhC;IAED,uCAAuC;IACvC,IAAI,gBAAgB,IAAI,MAAM,GAAG,IAAI,CAEpC;IAED,gFAAgF;IAChF,IAAI,SAAS,IAAI,aAAa,GAAG,IAAI,CAEpC;IAED;;;;;;;;OAQG;IACG,aAAa,IAAI,OAAO,CAAC,eAAe,CAAC;IAgB/C;;;;;;;;OAQG;IACG,gBAAgB,IAAI,OAAO,CAAC,aAAa,CAAC;CASjD"}
|
|
@@ -4,6 +4,7 @@ exports.SmartComply = void 0;
|
|
|
4
4
|
const HttpClient_1 = require("./HttpClient");
|
|
5
5
|
const onboarding_1 = require("../modules/onboarding/onboarding");
|
|
6
6
|
const liveness_1 = require("../modules/liveness/liveness");
|
|
7
|
+
const logger_1 = require("../utils/logger");
|
|
7
8
|
/**
|
|
8
9
|
* SmartComply SDK — main entry point.
|
|
9
10
|
*
|
|
@@ -28,6 +29,7 @@ class SmartComply {
|
|
|
28
29
|
this.http = new HttpClient_1.HttpClient(config);
|
|
29
30
|
this.onboarding = new onboarding_1.OnboardingModule(this.http);
|
|
30
31
|
this.liveness = new liveness_1.LivenessModule(this.http);
|
|
32
|
+
logger_1.SDKLogger.always(`v${SmartComply.VERSION}`);
|
|
31
33
|
}
|
|
32
34
|
/** Current session token (null if not created yet) */
|
|
33
35
|
get sessionToken() {
|
|
@@ -74,4 +76,14 @@ class SmartComply {
|
|
|
74
76
|
}
|
|
75
77
|
}
|
|
76
78
|
exports.SmartComply = SmartComply;
|
|
79
|
+
/**
|
|
80
|
+
* Package version, hardcoded to match package.json — bump this alongside
|
|
81
|
+
* every version bump there (same manual-sync convention already used for
|
|
82
|
+
* MEDIAPIPE_VERSION in camera/FaceDetector.ts). Exists so a client's
|
|
83
|
+
* running version can be confirmed directly (SmartComply.VERSION, or the
|
|
84
|
+
* console log on construction below) instead of trusting that whatever
|
|
85
|
+
* CDN tag they installed with (e.g. @1, which floats to the latest
|
|
86
|
+
* matching release) actually resolved to the version they expect.
|
|
87
|
+
*/
|
|
88
|
+
SmartComply.VERSION = "1.0.79";
|
|
77
89
|
//# sourceMappingURL=Smartcomply.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Smartcomply.js","sourceRoot":"","sources":["../../src/client/Smartcomply.ts"],"names":[],"mappings":";;;AACA,6CAA0C;AAC1C,iEAAoE;AACpE,2DAA8D;
|
|
1
|
+
{"version":3,"file":"Smartcomply.js","sourceRoot":"","sources":["../../src/client/Smartcomply.ts"],"names":[],"mappings":";;;AACA,6CAA0C;AAC1C,iEAAoE;AACpE,2DAA8D;AAC9D,4CAA4C;AAM5C;;;;;;;;GAQG;AACH,MAAa,WAAW;IAqBtB,YAAY,MAAiB;QAPrB,kBAAa,GAAkB,IAAI,CAAC;QACpC,sBAAiB,GAAkB,IAAI,CAAC;QACxC,eAAU,GAAyB,IAAI,CAAC;QAM9C,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC;YACnB,MAAM,IAAI,KAAK,CAAC,iCAAiC,CAAC,CAAC;QACrD,CAAC;QACD,IAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC;YACrB,MAAM,IAAI,KAAK,CAAC,+DAA+D,CAAC,CAAC;QACnF,CAAC;QAED,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC;QAChC,IAAI,CAAC,IAAI,GAAG,IAAI,uBAAU,CAAC,MAAM,CAAC,CAAC;QAEnC,IAAI,CAAC,UAAU,GAAG,IAAI,6BAAgB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAClD,IAAI,CAAC,QAAQ,GAAG,IAAI,yBAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAE9C,kBAAS,CAAC,MAAM,CAAC,IAAI,WAAW,CAAC,OAAO,EAAE,CAAC,CAAC;IAC9C,CAAC;IAED,sDAAsD;IACtD,IAAI,YAAY;QACd,OAAO,IAAI,CAAC,aAAa,CAAC;IAC5B,CAAC;IAED,uCAAuC;IACvC,IAAI,gBAAgB;QAClB,OAAO,IAAI,CAAC,iBAAiB,CAAC;IAChC,CAAC;IAED,gFAAgF;IAChF,IAAI,SAAS;QACX,OAAO,IAAI,CAAC,UAAU,CAAC;IACzB,CAAC;IAED;;;;;;;;OAQG;IACH,KAAK,CAAC,aAAa;QACjB,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,OAAO,CACtC,MAAM,EACN,qBAAqB,EACrB,EAAE,SAAS,EAAE,IAAI,CAAC,QAAQ,EAAE,CAC7B,CAAC;QAEF,IAAI,CAAC,aAAa,GAAG,QAAQ,CAAC,KAAK,CAAC;QACpC,IAAI,CAAC,iBAAiB,GAAG,QAAQ,CAAC,UAAU,CAAC;QAE7C,mEAAmE;QACnE,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;QAE1C,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED;;;;;;;;OAQG;IACH,KAAK,CAAC,gBAAgB;QACpB,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,cAAc,CAC3C,KAAK,EACL,iBAAiB,CAClB,CAAC;QAEF,IAAI,CAAC,UAAU,GAAG,MAAM,CAAC;QACzB,OAAO,MAAM,CAAC;IAChB,CAAC;;AA/FH,kCAgGC;AA/FC;;;;;;;;GAQG;AACa,mBAAO,GAAG,QAAQ,AAAX,CAAY"}
|
|
@@ -12,6 +12,16 @@ import { SessionResponse, SDKInitConfig } from "../types/onboarding";
|
|
|
12
12
|
* // ... use sdk.onboarding and sdk.liveness modules
|
|
13
13
|
*/
|
|
14
14
|
export declare class SmartComply {
|
|
15
|
+
/**
|
|
16
|
+
* Package version, hardcoded to match package.json — bump this alongside
|
|
17
|
+
* every version bump there (same manual-sync convention already used for
|
|
18
|
+
* MEDIAPIPE_VERSION in camera/FaceDetector.ts). Exists so a client's
|
|
19
|
+
* running version can be confirmed directly (SmartComply.VERSION, or the
|
|
20
|
+
* console log on construction below) instead of trusting that whatever
|
|
21
|
+
* CDN tag they installed with (e.g. @1, which floats to the latest
|
|
22
|
+
* matching release) actually resolved to the version they expect.
|
|
23
|
+
*/
|
|
24
|
+
static readonly VERSION = "1.0.79";
|
|
15
25
|
private http;
|
|
16
26
|
private clientId;
|
|
17
27
|
private _sessionToken;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Smartcomply.d.ts","sourceRoot":"","sources":["../../../src/client/Smartcomply.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAErC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"Smartcomply.d.ts","sourceRoot":"","sources":["../../../src/client/Smartcomply.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAErC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAE9D,OAAO,EACL,eAAe,EACf,aAAa,EACd,MAAM,qBAAqB,CAAC;AAE7B;;;;;;;;GAQG;AACH,qBAAa,WAAW;IACtB;;;;;;;;OAQG;IACH,MAAM,CAAC,QAAQ,CAAC,OAAO,YAAY;IAEnC,OAAO,CAAC,IAAI,CAAa;IACzB,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,aAAa,CAAuB;IAC5C,OAAO,CAAC,iBAAiB,CAAuB;IAChD,OAAO,CAAC,UAAU,CAA8B;IAEzC,UAAU,EAAE,gBAAgB,CAAC;IAC7B,QAAQ,EAAE,cAAc,CAAC;gBAEpB,MAAM,EAAE,SAAS;IAiB7B,sDAAsD;IACtD,IAAI,YAAY,IAAI,MAAM,GAAG,IAAI,CAEhC;IAED,uCAAuC;IACvC,IAAI,gBAAgB,IAAI,MAAM,GAAG,IAAI,CAEpC;IAED,gFAAgF;IAChF,IAAI,SAAS,IAAI,aAAa,GAAG,IAAI,CAEpC;IAED;;;;;;;;OAQG;IACG,aAAa,IAAI,OAAO,CAAC,eAAe,CAAC;IAgB/C;;;;;;;;OAQG;IACG,gBAAgB,IAAI,OAAO,CAAC,aAAa,CAAC;CASjD"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { HttpClient } from "./HttpClient";
|
|
2
2
|
import { OnboardingModule } from "../modules/onboarding/onboarding";
|
|
3
3
|
import { LivenessModule } from "../modules/liveness/liveness";
|
|
4
|
+
import { SDKLogger } from "../utils/logger";
|
|
4
5
|
/**
|
|
5
6
|
* SmartComply SDK — main entry point.
|
|
6
7
|
*
|
|
@@ -25,6 +26,7 @@ export class SmartComply {
|
|
|
25
26
|
this.http = new HttpClient(config);
|
|
26
27
|
this.onboarding = new OnboardingModule(this.http);
|
|
27
28
|
this.liveness = new LivenessModule(this.http);
|
|
29
|
+
SDKLogger.always(`v${SmartComply.VERSION}`);
|
|
28
30
|
}
|
|
29
31
|
/** Current session token (null if not created yet) */
|
|
30
32
|
get sessionToken() {
|
|
@@ -70,4 +72,14 @@ export class SmartComply {
|
|
|
70
72
|
return config;
|
|
71
73
|
}
|
|
72
74
|
}
|
|
75
|
+
/**
|
|
76
|
+
* Package version, hardcoded to match package.json — bump this alongside
|
|
77
|
+
* every version bump there (same manual-sync convention already used for
|
|
78
|
+
* MEDIAPIPE_VERSION in camera/FaceDetector.ts). Exists so a client's
|
|
79
|
+
* running version can be confirmed directly (SmartComply.VERSION, or the
|
|
80
|
+
* console log on construction below) instead of trusting that whatever
|
|
81
|
+
* CDN tag they installed with (e.g. @1, which floats to the latest
|
|
82
|
+
* matching release) actually resolved to the version they expect.
|
|
83
|
+
*/
|
|
84
|
+
SmartComply.VERSION = "1.0.79";
|
|
73
85
|
//# sourceMappingURL=Smartcomply.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Smartcomply.js","sourceRoot":"","sources":["../../../src/client/Smartcomply.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"Smartcomply.js","sourceRoot":"","sources":["../../../src/client/Smartcomply.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAM5C;;;;;;;;GAQG;AACH,MAAM,OAAO,WAAW;IAqBtB,YAAY,MAAiB;QAPrB,kBAAa,GAAkB,IAAI,CAAC;QACpC,sBAAiB,GAAkB,IAAI,CAAC;QACxC,eAAU,GAAyB,IAAI,CAAC;QAM9C,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC;YACnB,MAAM,IAAI,KAAK,CAAC,iCAAiC,CAAC,CAAC;QACrD,CAAC;QACD,IAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC;YACrB,MAAM,IAAI,KAAK,CAAC,+DAA+D,CAAC,CAAC;QACnF,CAAC;QAED,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC;QAChC,IAAI,CAAC,IAAI,GAAG,IAAI,UAAU,CAAC,MAAM,CAAC,CAAC;QAEnC,IAAI,CAAC,UAAU,GAAG,IAAI,gBAAgB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAClD,IAAI,CAAC,QAAQ,GAAG,IAAI,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAE9C,SAAS,CAAC,MAAM,CAAC,IAAI,WAAW,CAAC,OAAO,EAAE,CAAC,CAAC;IAC9C,C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AKG;IACH,OAAO,CAAC,cAAc;IAkBtB,OAAO,CAAC,cAAc;IAmFtB,OAAO,CAAC,UAAU;IAUlB,OAAO,CAAC,YAAY;CAiCrB"}
|
|
@@ -309,6 +309,11 @@ export class SmartComplyFlow {
|
|
|
309
309
|
this._keydownHandler = null;
|
|
310
310
|
this._visibilityHandler = null;
|
|
311
311
|
this._hiddenAtMs = null;
|
|
312
|
+
// Set just before a re-background restart re-renders the liveness step
|
|
313
|
+
// (see the visibilitychange handler below), read once by renderLiveness
|
|
314
|
+
// to show a "your scan was interrupted" notice instead of silently
|
|
315
|
+
// swapping back into a fresh scan with no explanation.
|
|
316
|
+
this._restartedAfterBackground = false;
|
|
312
317
|
this._popstateHandler = null;
|
|
313
318
|
this._historyGuardActive = false;
|
|
314
319
|
// Retry safety — max 3 confirmation rejections or liveness failures per session
|
|
@@ -552,6 +557,7 @@ export class SmartComplyFlow {
|
|
|
552
557
|
return;
|
|
553
558
|
const awayMs = Date.now() - hiddenAt;
|
|
554
559
|
if (awayMs >= REBACKGROUND_RESTART_MS && this.currentStep === "liveness") {
|
|
560
|
+
this._restartedAfterBackground = true;
|
|
555
561
|
this.showStep("liveness");
|
|
556
562
|
}
|
|
557
563
|
};
|
|
@@ -2039,6 +2045,10 @@ export class SmartComplyFlow {
|
|
|
2039
2045
|
// ── Liveness ────────────────────────────────────────────────────
|
|
2040
2046
|
renderLiveness(container) {
|
|
2041
2047
|
container.style.cssText += "display:flex;flex-direction:column;gap:14px;";
|
|
2048
|
+
// Consumed unconditionally (even on the retry-limit-reached exit below)
|
|
2049
|
+
// so it never leaks into a later, unrelated render of this step.
|
|
2050
|
+
const restartedAfterBackground = this._restartedAfterBackground;
|
|
2051
|
+
this._restartedAfterBackground = false;
|
|
2042
2052
|
// W13: Check retry limit before starting another liveness attempt
|
|
2043
2053
|
if (this._livenessFailures >= SmartComplyFlow.MAX_RETRIES) {
|
|
2044
2054
|
this._renderRetryLimitReached(container);
|
|
@@ -2049,6 +2059,18 @@ export class SmartComplyFlow {
|
|
|
2049
2059
|
// resolve/reject into the current one — see the visibilitychange
|
|
2050
2060
|
// handler in mount(), which re-renders this step on return-to-foreground.
|
|
2051
2061
|
const attemptId = ++this._livenessAttemptId;
|
|
2062
|
+
// Tell the user why the scan restarted instead of silently swapping
|
|
2063
|
+
// back into a fresh camera view with no explanation — a backgrounded
|
|
2064
|
+
// tab/app can leave the camera and detection loop in a stale state
|
|
2065
|
+
// (see the visibilitychange handler), so this restart is intentional,
|
|
2066
|
+
// but it must not look like the scan "just resumed" on its own.
|
|
2067
|
+
if (restartedAfterBackground) {
|
|
2068
|
+
const notice = document.createElement("div");
|
|
2069
|
+
notice.setAttribute("role", "status");
|
|
2070
|
+
notice.style.cssText = `width:100%;padding:10px 14px;border-radius:10px;background:${this.theme.warning}18;border:1px solid ${this.theme.warning}40;color:${this.theme.warning};font-size:12px;text-align:left;line-height:1.5;`;
|
|
2071
|
+
notice.textContent = "Your scan was interrupted when you left the page. Starting over — please stay on this screen until it's done.";
|
|
2072
|
+
container.appendChild(notice);
|
|
2073
|
+
}
|
|
2052
2074
|
const title = this.createStepTitle("Face verification");
|
|
2053
2075
|
container.appendChild(title);
|
|
2054
2076
|
const desc = document.createElement("div");
|