UNPKG

react-native-esc-pos-printer

Version:

An unofficial React Native library for printing on an EPSON TM printer with the Epson ePOS SDK for iOS and Epson ePOS SDK for Android

93 lines (92 loc) 8.55 kB
"use strict"; import { EscPosPrinter } from "../../../specs/index.js"; const EscPosPrinterConstants = EscPosPrinter.getConstants(); export let CommonParams = function (CommonParams) { CommonParams[CommonParams["PARAM_DEFAULT"] = EscPosPrinterConstants.PARAM_DEFAULT] = "PARAM_DEFAULT"; CommonParams[CommonParams["PARAM_UNSPECIFIED"] = EscPosPrinterConstants.PARAM_UNSPECIFIED] = "PARAM_UNSPECIFIED"; CommonParams[CommonParams["TRUE"] = EscPosPrinterConstants.PRINTER_TRUE] = "TRUE"; CommonParams[CommonParams["FALSE"] = EscPosPrinterConstants.PRINTER_FALSE] = "FALSE"; CommonParams[CommonParams["UNKNOWN"] = EscPosPrinterConstants.UNKNOWN] = "UNKNOWN"; return CommonParams; }({}); export let ColorType = function (ColorType) { ColorType[ColorType["COLOR_NONE"] = EscPosPrinterConstants.COLOR_NONE] = "COLOR_NONE"; ColorType[ColorType["COLOR_1"] = EscPosPrinterConstants.COLOR_1] = "COLOR_1"; ColorType[ColorType["COLOR_2"] = EscPosPrinterConstants.COLOR_2] = "COLOR_2"; ColorType[ColorType["COLOR_3"] = EscPosPrinterConstants.COLOR_3] = "COLOR_3"; ColorType[ColorType["COLOR_4"] = EscPosPrinterConstants.COLOR_4] = "COLOR_4"; return ColorType; }({}); export let TextLangType = function (TextLangType) { TextLangType[TextLangType["LANG_EN"] = EscPosPrinterConstants.LANG_EN] = "LANG_EN"; TextLangType[TextLangType["LANG_JA"] = EscPosPrinterConstants.LANG_JA] = "LANG_JA"; TextLangType[TextLangType["LANG_ZH_CN"] = EscPosPrinterConstants.LANG_ZH_CN] = "LANG_ZH_CN"; TextLangType[TextLangType["LANG_ZH_TW"] = EscPosPrinterConstants.LANG_ZH_TW] = "LANG_ZH_TW"; TextLangType[TextLangType["LANG_KO"] = EscPosPrinterConstants.LANG_KO] = "LANG_KO"; TextLangType[TextLangType["LANG_TH"] = EscPosPrinterConstants.LANG_TH] = "LANG_TH"; TextLangType[TextLangType["LANG_VI"] = EscPosPrinterConstants.LANG_VI] = "LANG_VI"; TextLangType[TextLangType["LANG_MULTI"] = EscPosPrinterConstants.LANG_MULTI] = "LANG_MULTI"; return TextLangType; }({}); export let PrinterModelLang = function (PrinterModelLang) { PrinterModelLang[PrinterModelLang["MODEL_ANK"] = EscPosPrinterConstants.MODEL_ANK] = "MODEL_ANK"; PrinterModelLang[PrinterModelLang["MODEL_CHINESE"] = EscPosPrinterConstants.MODEL_CHINESE] = "MODEL_CHINESE"; PrinterModelLang[PrinterModelLang["MODEL_TAIWAN"] = EscPosPrinterConstants.MODEL_TAIWAN] = "MODEL_TAIWAN"; PrinterModelLang[PrinterModelLang["MODEL_KOREAN"] = EscPosPrinterConstants.MODEL_KOREAN] = "MODEL_KOREAN"; PrinterModelLang[PrinterModelLang["MODEL_THAI"] = EscPosPrinterConstants.MODEL_THAI] = "MODEL_THAI"; PrinterModelLang[PrinterModelLang["MODEL_SOUTHASIA"] = EscPosPrinterConstants.MODEL_SOUTHASIA] = "MODEL_SOUTHASIA"; return PrinterModelLang; }({}); export let PrinterAddCutType = function (PrinterAddCutType) { PrinterAddCutType[PrinterAddCutType["CUT_FEED"] = EscPosPrinterConstants.CUT_FEED] = "CUT_FEED"; PrinterAddCutType[PrinterAddCutType["CUT_NO_FEED"] = EscPosPrinterConstants.CUT_NO_FEED] = "CUT_NO_FEED"; PrinterAddCutType[PrinterAddCutType["CUT_RESERVE"] = EscPosPrinterConstants.CUT_RESERVE] = "CUT_RESERVE"; PrinterAddCutType[PrinterAddCutType["FULL_CUT_FEED"] = EscPosPrinterConstants.FULL_CUT_FEED] = "FULL_CUT_FEED"; PrinterAddCutType[PrinterAddCutType["FULL_CUT_NO_FEED"] = EscPosPrinterConstants.FULL_CUT_NO_FEED] = "FULL_CUT_NO_FEED"; PrinterAddCutType[PrinterAddCutType["FULL_CUT_RESERVE"] = EscPosPrinterConstants.FULL_CUT_RESERVE] = "FULL_CUT_RESERVE"; return PrinterAddCutType; }({}); export let PrinterErrorResult = function (PrinterErrorResult) { PrinterErrorResult[PrinterErrorResult["ERR_PARAM"] = EscPosPrinterConstants.ERR_PARAM] = "ERR_PARAM"; PrinterErrorResult[PrinterErrorResult["ERR_MEMORY"] = EscPosPrinterConstants.ERR_MEMORY] = "ERR_MEMORY"; PrinterErrorResult[PrinterErrorResult["ERR_UNSUPPORTED"] = EscPosPrinterConstants.ERR_UNSUPPORTED] = "ERR_UNSUPPORTED"; PrinterErrorResult[PrinterErrorResult["ERR_FAILURE"] = EscPosPrinterConstants.ERR_FAILURE] = "ERR_FAILURE"; PrinterErrorResult[PrinterErrorResult["ERR_PROCESSING"] = EscPosPrinterConstants.ERR_PROCESSING] = "ERR_PROCESSING"; PrinterErrorResult[PrinterErrorResult["ERR_CONNECT"] = EscPosPrinterConstants.ERR_CONNECT] = "ERR_CONNECT"; PrinterErrorResult[PrinterErrorResult["ERR_TIMEOUT"] = EscPosPrinterConstants.ERR_TIMEOUT] = "ERR_TIMEOUT"; PrinterErrorResult[PrinterErrorResult["ERR_ILLEGAL"] = EscPosPrinterConstants.ERR_ILLEGAL] = "ERR_ILLEGAL"; PrinterErrorResult[PrinterErrorResult["ERR_NOT_FOUND"] = EscPosPrinterConstants.ERR_NOT_FOUND] = "ERR_NOT_FOUND"; PrinterErrorResult[PrinterErrorResult["ERR_IN_USE"] = EscPosPrinterConstants.ERR_IN_USE] = "ERR_IN_USE"; PrinterErrorResult[PrinterErrorResult["ERR_TYPE_INVALID"] = EscPosPrinterConstants.ERR_TYPE_INVALID] = "ERR_TYPE_INVALID"; PrinterErrorResult[PrinterErrorResult["ERR_RECOVERY_FAILURE"] = EscPosPrinterConstants.ERR_RECOVERY_FAILURE] = "ERR_RECOVERY_FAILURE"; PrinterErrorResult[PrinterErrorResult["ERR_DISCONNECT"] = EscPosPrinterConstants.ERR_DISCONNECT] = "ERR_DISCONNECT"; PrinterErrorResult[PrinterErrorResult["ERR_INIT"] = EscPosPrinterConstants.ERR_INIT] = "ERR_INIT"; return PrinterErrorResult; }({}); export let PrinterErrorCodeResult = function (PrinterErrorCodeResult) { PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_AUTORECOVER"] = EscPosPrinterConstants.CODE_ERR_AUTORECOVER] = "CODE_ERR_AUTORECOVER"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_COVER_OPEN"] = EscPosPrinterConstants.CODE_ERR_COVER_OPEN] = "CODE_ERR_COVER_OPEN"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_CUTTER"] = EscPosPrinterConstants.CODE_ERR_CUTTER] = "CODE_ERR_CUTTER"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_MECHANICAL"] = EscPosPrinterConstants.CODE_ERR_MECHANICAL] = "CODE_ERR_MECHANICAL"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_EMPTY"] = EscPosPrinterConstants.CODE_ERR_EMPTY] = "CODE_ERR_EMPTY"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_UNRECOVERABLE"] = EscPosPrinterConstants.CODE_ERR_UNRECOVERABLE] = "CODE_ERR_UNRECOVERABLE"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_FAILURE"] = EscPosPrinterConstants.CODE_ERR_FAILURE] = "CODE_ERR_FAILURE"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_NOT_FOUND"] = EscPosPrinterConstants.CODE_ERR_NOT_FOUND] = "CODE_ERR_NOT_FOUND"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_SYSTEM"] = EscPosPrinterConstants.CODE_ERR_SYSTEM] = "CODE_ERR_SYSTEM"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_PORT"] = EscPosPrinterConstants.CODE_ERR_PORT] = "CODE_ERR_PORT"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_TIMEOUT"] = EscPosPrinterConstants.CODE_ERR_TIMEOUT] = "CODE_ERR_TIMEOUT"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_JOB_NOT_FOUND"] = EscPosPrinterConstants.CODE_ERR_JOB_NOT_FOUND] = "CODE_ERR_JOB_NOT_FOUND"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_SPOOLER"] = EscPosPrinterConstants.CODE_ERR_SPOOLER] = "CODE_ERR_SPOOLER"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_BATTERY_LOW"] = EscPosPrinterConstants.CODE_ERR_BATTERY_LOW] = "CODE_ERR_BATTERY_LOW"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_TOO_MANY_REQUESTS"] = EscPosPrinterConstants.CODE_ERR_TOO_MANY_REQUESTS] = "CODE_ERR_TOO_MANY_REQUESTS"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_REQUEST_ENTITY_TOO_LARGE"] = EscPosPrinterConstants.CODE_ERR_REQUEST_ENTITY_TOO_LARGE] = "CODE_ERR_REQUEST_ENTITY_TOO_LARGE"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_WAIT_REMOVAL"] = EscPosPrinterConstants.CODE_ERR_WAIT_REMOVAL] = "CODE_ERR_WAIT_REMOVAL"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_PRINTING"] = EscPosPrinterConstants.CODE_PRINTING] = "CODE_PRINTING"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_PARAM"] = EscPosPrinterConstants.CODE_ERR_PARAM] = "CODE_ERR_PARAM"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_MEMORY"] = EscPosPrinterConstants.CODE_ERR_MEMORY] = "CODE_ERR_MEMORY"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_PROCESSING"] = EscPosPrinterConstants.CODE_ERR_PROCESSING] = "CODE_ERR_PROCESSING"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_ILLEGAL"] = EscPosPrinterConstants.CODE_ERR_ILLEGAL] = "CODE_ERR_ILLEGAL"; PrinterErrorCodeResult[PrinterErrorCodeResult["CODE_ERR_DEVICE_BUSY"] = EscPosPrinterConstants.CODE_ERR_DEVICE_BUSY] = "CODE_ERR_DEVICE_BUSY"; return PrinterErrorCodeResult; }({}); //# sourceMappingURL=common.js.map