@incodetech/web 2.1.0-rc.3 → 2.1.0-rc.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.
package/dist/flow/flow.es.js
CHANGED
|
@@ -5,7 +5,8 @@ import { u as useManager } from "../hooks-CNu7o-v8.js";
|
|
|
5
5
|
import { t as IncodeComponent } from "../incodeComponent-CfzJGETt.js";
|
|
6
6
|
import { t as TransitionSpinner } from "../transitionSpinner-CuNCqHNi.js";
|
|
7
7
|
import { t as registerIncodeModuleElement } from "../incodeModule-B-4_3JrK.js";
|
|
8
|
-
import {
|
|
8
|
+
import { _ as warmupWasmIfNeeded, a as resolveApiKey, c as HEADLESS_FLOW_MODULE_KEYS, d as fetchTheme, f as initializeFlowManager, h as preloadRedirectToMobile, l as LAZY_UI_MODULES, m as preloadHomeScreen, n as useModulePreloader, o as extractIncodeStatus, p as preloadFirstModule, r as usePrefetchNextModule, s as UnsupportedModule, t as useModuleLoader, u as createFlowManager, y as TerminalErrorPage } from "../useModuleLoader-Bi26kJbg.js";
|
|
9
|
+
import { getDeviceClass } from "@incodetech/core/device";
|
|
9
10
|
import { getRequiredWasmPipelines } from "@incodetech/core/flow";
|
|
10
11
|
import { bootstrapSession, refreshQrUrlUuid } from "@incodetech/core/session";
|
|
11
12
|
//#region src/shared/processing/useDelayedFlag.ts
|
|
@@ -159,7 +160,7 @@ function maybePreloadHomeScreen(flowManager) {
|
|
|
159
160
|
if (flowManager.getState().presentation.shouldPrefetchHome) preloadHomeScreen();
|
|
160
161
|
}
|
|
161
162
|
function maybePreloadRedirectToMobile() {
|
|
162
|
-
if (
|
|
163
|
+
if (getDeviceClass() === "desktop") preloadRedirectToMobile();
|
|
163
164
|
}
|
|
164
165
|
function useFlowInitialization(options) {
|
|
165
166
|
const { lang, disableDashboardTheme, enableHome, onError, useCPF } = options;
|
package/dist/index.es.js
CHANGED
|
@@ -3,7 +3,7 @@ import { t as setUiConfig } from "./uiConfig-D2_wawvr.js";
|
|
|
3
3
|
import { DEFAULT_WASM_VERSION } from "@incodetech/core/wasm";
|
|
4
4
|
import { setup as setup$1 } from "@incodetech/core";
|
|
5
5
|
//#region src/setup.ts
|
|
6
|
-
async function setup({ apiURL, token, customHeaders, timeout, wasm, ipLookup, devMode, i18n, uiConfig }) {
|
|
6
|
+
async function setup({ apiURL, token, customHeaders, timeout, wasm, ipLookup, fingerprint, devMode, i18n, uiConfig }) {
|
|
7
7
|
if (uiConfig) setUiConfig(uiConfig);
|
|
8
8
|
await setup$1({
|
|
9
9
|
apiURL,
|
|
@@ -12,6 +12,7 @@ async function setup({ apiURL, token, customHeaders, timeout, wasm, ipLookup, de
|
|
|
12
12
|
timeout,
|
|
13
13
|
wasm,
|
|
14
14
|
ipLookup,
|
|
15
|
+
fingerprint,
|
|
15
16
|
devMode
|
|
16
17
|
});
|
|
17
18
|
setI18nInstance(createI18n(i18n));
|
package/dist/types/index.d.ts
CHANGED
|
@@ -22,7 +22,7 @@ export declare function setI18nInstance(instance: i18n): void;
|
|
|
22
22
|
*/
|
|
23
23
|
export declare function setUiConfig(next: UiConfig): void;
|
|
24
24
|
|
|
25
|
-
export declare function setup({ apiURL, token, customHeaders, timeout, wasm, ipLookup, devMode, i18n, uiConfig, }: SetupOptions): Promise<void>;
|
|
25
|
+
export declare function setup({ apiURL, token, customHeaders, timeout, wasm, ipLookup, fingerprint, devMode, i18n, uiConfig, }: SetupOptions): Promise<void>;
|
|
26
26
|
|
|
27
27
|
declare type SetupOptions = {
|
|
28
28
|
apiURL: string;
|
|
@@ -31,6 +31,13 @@ declare type SetupOptions = {
|
|
|
31
31
|
timeout?: number;
|
|
32
32
|
wasm?: WasmConfig | false;
|
|
33
33
|
ipLookup?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Disables client-side device-fingerprint submission. Forwarded to core
|
|
36
|
+
* `setup()` — see the core `SetupOptions.fingerprint` docs for the full
|
|
37
|
+
* behavior (transition flag; also affects the Deepsight metadata bundle
|
|
38
|
+
* and mandatory-consent auto-injection).
|
|
39
|
+
*/
|
|
40
|
+
fingerprint?: boolean;
|
|
34
41
|
/**
|
|
35
42
|
* Disables the browser devtools detector for local development. Forwarded to
|
|
36
43
|
* core `setup()`. Leave `false` (default) in production — see the core
|
|
@@ -5,7 +5,7 @@ import { t as Page } from "./page-DidH_RkX.js";
|
|
|
5
5
|
import { t as Button } from "./button-Dz6AsbmF.js";
|
|
6
6
|
import { t as ErrorIcon } from "./errorIcon-BA4T6iy-.js";
|
|
7
7
|
import { initializeWasmUtil, resolveWasmConfig, setWasmConfig, upgradeToWasmHttpClient, warmupWasm } from "@incodetech/core/wasm";
|
|
8
|
-
import { getDeviceClass
|
|
8
|
+
import { getDeviceClass } from "@incodetech/core/device";
|
|
9
9
|
import { createOrchestratedFlowManager, getFlow, getRequiredWasmPipelines } from "@incodetech/core/flow";
|
|
10
10
|
import { getFinishStatus, initializeSession } from "@incodetech/core/session";
|
|
11
11
|
import { api } from "@incodetech/core/http";
|
|
@@ -347,22 +347,9 @@ function preloadRedirectToMobile() {
|
|
|
347
347
|
redirectToMobilePreloadPromise = void 0;
|
|
348
348
|
});
|
|
349
349
|
}
|
|
350
|
-
/**
|
|
351
|
-
* Whether the current browser should be treated as a desktop for the
|
|
352
|
-
* desktop-to-mobile redirect decision.
|
|
353
|
-
*
|
|
354
|
-
* A desktop browser emulating a phone (Chrome DevTools device toolbar) spoofs
|
|
355
|
-
* the user agent, so `getDeviceClass()` alone would report mobile and skip the
|
|
356
|
-
* dashboard-configured redirect. Treating a detected emulation as desktop keeps
|
|
357
|
-
* the redirect from being bypassed that way. Shared by the flow + workflow init
|
|
358
|
-
* paths so the "treat as desktop" rule lives in one place.
|
|
359
|
-
*/
|
|
360
|
-
function isDesktopOrEmulated() {
|
|
361
|
-
return getDeviceClass() === "desktop" || isBrowserSimulated();
|
|
362
|
-
}
|
|
363
350
|
function createFlowManager(options = {}) {
|
|
364
351
|
const scopedLazyModules = {};
|
|
365
|
-
const isDesktop = options.isDesktop ??
|
|
352
|
+
const isDesktop = options.isDesktop ?? getDeviceClass() === "desktop";
|
|
366
353
|
const { enableHome, ...flowFetchOptions } = options;
|
|
367
354
|
let endScreen = {
|
|
368
355
|
endScreenTitle: null,
|
|
@@ -686,4 +673,4 @@ function usePrefetchNextModule(steps, currentStepIndex, modules, currentModuleLo
|
|
|
686
673
|
]);
|
|
687
674
|
}
|
|
688
675
|
//#endregion
|
|
689
|
-
export {
|
|
676
|
+
export { warmupWasmIfNeeded as _, resolveApiKey as a, HEADLESS_FLOW_MODULE_KEYS as c, fetchTheme as d, initializeFlowManager as f, setupSDK as g, preloadRedirectToMobile as h, HEADLESS_WORKFLOW_MODULE_KEYS as i, LAZY_UI_MODULES as l, preloadHomeScreen as m, useModulePreloader as n, extractIncodeStatus as o, preloadFirstModule as p, usePrefetchNextModule as r, UnsupportedModule as s, useModuleLoader as t, createFlowManager as u, fetchAndApplyTheme as v, TerminalErrorPage as y };
|
|
@@ -7,8 +7,9 @@ import { t as Page } from "../page-DidH_RkX.js";
|
|
|
7
7
|
import { t as TransitionSpinner } from "../transitionSpinner-CuNCqHNi.js";
|
|
8
8
|
import { t as AutoFocusTitle } from "../autoFocusTitle-CuRu2lPg.js";
|
|
9
9
|
import { t as registerIncodeModuleElement } from "../incodeModule-B-4_3JrK.js";
|
|
10
|
-
import {
|
|
10
|
+
import { a as resolveApiKey, g as setupSDK, i as HEADLESS_WORKFLOW_MODULE_KEYS, l as LAZY_UI_MODULES, o as extractIncodeStatus, s as UnsupportedModule, t as useModuleLoader, v as fetchAndApplyTheme, y as TerminalErrorPage } from "../useModuleLoader-Bi26kJbg.js";
|
|
11
11
|
import { resolveWasmConfig, upgradeToWasmHttpClient, warmupWasm } from "@incodetech/core/wasm";
|
|
12
|
+
import { getDeviceClass } from "@incodetech/core/device";
|
|
12
13
|
import { classifyScoreStatus } from "@incodetech/core/flow";
|
|
13
14
|
import { bootstrapSession, refreshQrUrlUuid } from "@incodetech/core/session";
|
|
14
15
|
import { createWorkflowManager } from "@incodetech/core/workflow";
|
|
@@ -148,7 +149,7 @@ function createWorkflowUIManager(options = {}) {
|
|
|
148
149
|
return createWorkflowManager({
|
|
149
150
|
customModuleCallback: options.customModuleCallback,
|
|
150
151
|
interviewId: options.interviewId,
|
|
151
|
-
isDesktop: options.isDesktop ??
|
|
152
|
+
isDesktop: options.isDesktop ?? getDeviceClass() === "desktop"
|
|
152
153
|
});
|
|
153
154
|
}
|
|
154
155
|
function warmupWorkflowWasm(wasmConfig) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@incodetech/web",
|
|
3
|
-
"version": "2.1.0-rc.
|
|
3
|
+
"version": "2.1.0-rc.5",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/IncodeTechnologies/incode-web-sdk.git"
|
|
@@ -291,7 +291,7 @@
|
|
|
291
291
|
"qrcode": "^1.5.4",
|
|
292
292
|
"signature_pad": "^5.1.3",
|
|
293
293
|
"tailwindcss": "^4.1.17",
|
|
294
|
-
"@incodetech/core": "2.1.0-rc.
|
|
294
|
+
"@incodetech/core": "2.1.0-rc.5"
|
|
295
295
|
},
|
|
296
296
|
"devDependencies": {
|
|
297
297
|
"@microsoft/api-extractor": "^7.53.3",
|