UNPKG

scanbot-web-sdk

Version:

Scanbot Web Document and Barcode Scanner SDK

33 lines (32 loc) 1.51 kB
import React from "react"; import { ScanbotCameraProps, ScanbotCameraState, ScannerView } from "./scanner-view"; import { IFinderScannerHandle } from "./interfaces/base/i-finder-scanner-handle"; import ViewFinder from "./view/view-finder"; import { ViewFinderScannerConfiguration } from "./model/configuration/view-finder-scanner-configuration"; import { type DeepPartial } from "./core-types"; export declare class FinderScannerProps extends ScanbotCameraProps { } export declare class FinderScannerState extends ScanbotCameraState { } export default class FinderScannerView<P extends FinderScannerProps, S extends FinderScannerState> extends ScannerView<P, S> implements IFinderScannerHandle { finder?: ViewFinder; constructor(props: P); componentDidMount(): void; componentWillUnmount(): void; /** * You should use this variable in your 'detect' method override to check if the detection is paused. * @internal */ paused: boolean; resumeDetection(): void; pauseDetection(): void; isDetectionPaused(): boolean; /** * Start of the detection loop. This needs to be overridden and should contain your infinite detection loop. * Internally it is called by 'componentDidMount' and stopped only when the component is disposed. * @internal */ detect(): Promise<void>; updateConfiguration(configuration: DeepPartial<ViewFinderScannerConfiguration>): void; renderView(configuration: ViewFinderScannerConfiguration): React.ReactNode; }