UNPKG

@mmote/niimblue-node

Version:

Headless clients for niimbluelib. Command line interface, simple REST server are also included.

43 lines (42 loc) 1.55 kB
import { LabelType, PrintDirection, PrintTaskName } from "@mmote/niimbluelib"; import { TransportType } from "../utils"; export type SharpImageFit = "contain" | "cover" | "fill" | "inside" | "outside"; export type SharpImagePosition = "left" | "top" | "centre" | "right top" | "right" | "right bottom" | "bottom" | "left bottom" | "left top"; export interface TransportOptions { transport: TransportType; address: string; } export interface ScanOptions { transport: TransportType; timeout: number; } export interface InfoOptions { transport: TransportType; address: string; debug: boolean; } export interface FirmwareOptions { transport: TransportType; address: string; file: string; newVersion: string; debug: boolean; } export interface PrintOptions { printTask?: PrintTaskName; printDirection?: PrintDirection; quantity: number; labelType: LabelType; density: number; threshold: number; labelWidth?: number; labelHeight?: number; imageFit?: SharpImageFit; imagePosition?: SharpImagePosition; debug: boolean; } export declare const cliConnectAndPrintImageFile: (path: string, options: PrintOptions & TransportOptions) => Promise<never>; export declare const cliScan: (options: ScanOptions) => Promise<never>; export declare const cliPrinterInfo: (options: InfoOptions) => Promise<never>; export declare const cliPrinterRfidInfo: (options: InfoOptions) => Promise<never>; export declare const cliFlashFirmware: (options: FirmwareOptions) => Promise<never>;