@scandit/web-datacapture-id
Version:
Scandit Data Capture SDK for the Web
54 lines (53 loc) • 2.37 kB
TypeScript
import { INTERNAL_ACCESS } from "../../privateAccess.js";
import { PhysicalDocumentScanner, type PhysicalDocumentScannerJSON, PhysicalDocumentScannerType } from "./PhysicalDocumentScanner.js";
/**
* Runs a single ID recognizer in isolation. Hidden setting, no public API: "via" runs VIA only,
* "viz" runs Blink ID only, "none" keeps the default of running both for a visual inspection
* zone request.
*
* Deliberately not exported: index.ts re-exports this module wholesale, so an exported alias
* would land in the public .d.ts. The union is inlined below for the same reason, matching how
* IdCaptureScanner keeps allowCloudScanning out of the public surface.
*/
type SoloZone = "none" | "via" | "viz";
/** Additional, non-zone options of a SingleSideScanner. */
export interface SingleSideScannerOptions {
/**
* Experimental. Verdict-only mode: the document is localized on-device and its image is sent to
* the cloud document manipulation check; no data is extracted. Requires allowCloudScanning and
* all zones (barcode, MRZ, VIZ, free-form text) disabled.
*/
manipulationCheck?: boolean;
}
export interface SingleSideScannerJSON extends PhysicalDocumentScannerJSON {
options: {
barcode: boolean;
machineReadableZone: boolean;
visualInspectionZone: boolean;
freeFormText?: boolean;
manipulationCheck?: boolean;
soloZone?: "none" | "via" | "viz";
};
}
export declare class SingleSideScanner extends PhysicalDocumentScanner {
readonly type = PhysicalDocumentScannerType.SingleSide;
private _barcode;
private _machineReadableZone;
private _visualInspectionZone;
private _freeFormText;
private _manipulationCheck;
private _soloZone;
[INTERNAL_ACCESS]: {
setSoloZone: (soloZone: SoloZone) => void;
getSoloZone: () => SoloZone;
};
constructor(barcode: boolean, machineReadableZone: boolean, visualInspectionZone: boolean, freeFormText?: boolean, options?: SingleSideScannerOptions);
get barcode(): boolean;
get machineReadableZone(): boolean;
get visualInspectionZone(): boolean;
get freeFormText(): boolean;
/** Whether the scanner runs in the manipulation check mode (see SingleSideScannerOptions). */
get manipulationCheck(): boolean;
toJSONObject(): SingleSideScannerJSON;
}
export {};