/**
 * Skipped minification because the original files appears to be already minified.
 * Original file: /npm/lidta-drp@1.0.0/dist/lidta-drp.umd.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
(function(t,n){typeof exports=="object"&&typeof module<"u"?n(exports):typeof define=="function"&&define.amd?define(["exports"],n):(t=typeof globalThis<"u"?globalThis:t||self,n(t.LidtaDrp={}))})(this,function(t){"use strict";function n(){return window.postMessage({type:"get_lidta_printers"}),JSON.parse(localStorage.getItem("availablePrinters")||"[]")}function o(e){window.postMessage({source:"lidta-page",type:"CONFIGURE_PRINTER",printerName:e})}function s(e,i){if(typeof e!="string"||e.trim()===""){console.error("[LIDTA] Invalid htmlData: must be a non-empty string of HTML.");return}if(!Array.isArray(i)||i.length===0){console.error("[LIDTA] Invalid printers: must be a non-empty array.");return}if(i.find(r=>typeof r!="string"&&typeof r!="object")){console.error("[LIDTA] Invalid printer format: each printer should be a string or object.");return}const d={htmlData:e,printers:i};window.postMessage({type:"lidta_print_data",message:d},"*")}function a(){window.addEventListener("message",e=>{e.source===window&&e.data&&e.data.type==="lidta_print_status"&&console.log("Received print response:",e.data)})}t.configurePrinter=o,t.debug=a,t.getPrinters=n,t.printHtml=s,Object.defineProperty(t,Symbol.toStringTag,{value:"Module"})});
