UNPKG

@open-tender/store

Version:

A library of hooks, reducers, utility functions, and types for use with Open Tender applications that utilize our in-store POS API

24 lines (23 loc) 652 B
/// <reference types="react" /> export declare enum BarcodeScannerType { NONE = "NONE", MORPHSTICK = "MORPHSTICK", USB = "USB", CAMERA = "CAMERA" } export interface BarcodeScannerMethod { code: string | null; error: string | null; read: () => Promise<void>; cancel: () => Promise<void>; reset?: () => Promise<void>; camera?: () => React.ReactNode; showScanner?: boolean; close?: () => void; } export declare abstract class ScanListener { constructor(); abstract read(callback?: any): Promise<void>; abstract cancel(callback?: any): Promise<void>; scannerComponent(callback?: any): any; }