/*! * * SpreadJS Library 13.1.0 * * Copyright(c) GrapeCity, Inc. All rights reserved. * * Licensed under the SpreadJS Commercial License. * us.sales@grapecity.com * http://www.grapecity.com/en/licensing/grapecity/ * * */ !function(a){"object"==typeof module&&"object"==typeof module.exports?module.exports=a(require("@grapecity/spread-sheets")):"function"==typeof define&&define.amd?define(["@grapecity/spread-sheets"],a):"object"==typeof exports?exports.Spread=a(require("@grapecity/spread-sheets")):a(GC)}(function(a){a="object"==typeof a?a:{},a.Spread=a.Spread||{},a.Spread.Sheets=a.Spread.Sheets||{},a.Spread.Sheets.Barcode=function(a){var b={};function c(d){if(b[d])return b[d].exports;var e=b[d]={i:d,l:!1,exports:{}};return a[d].call(e.exports,e,e.exports,c),e.l=!0,e.exports}return c.m=a,c.c=b,c.d=function(a,b,d){c.o(a,b)||Object.defineProperty(a,b,{enumerable:!0,get:d})},c.r=function(a){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(a,"__esModule",{value:!0})},c.t=function(a,b){var d,e;if(1&b&&(a=c(a)),8&b)return a;if(4&b&&"object"==typeof a&&a&&a.__esModule)return a;if(d=Object.create(null),c.r(d),Object.defineProperty(d,"default",{enumerable:!0,value:a}),2&b&&"string"!=typeof a)for(e in a)c.d(d,e,function(b){return a[b]}.bind(null,e));return d},c.n=function(a){var b=a&&a.__esModule?function b(){return a.default}:function b(){return a};return c.d(b,"a",b),b},c.o=function(a,b){return Object.prototype.hasOwnProperty.call(a,b)},c.p="/assets/",c(c.s="./dist/plugins/barcode/barcodeSparkline.entry.js")}({"./dist/plugins/barcode/barcodeSparkline.entry.js":function(a,b,c){"use strict";Object.defineProperty(b,"__esModule",{value:!0});var d=c("./dist/plugins/barcode/barcodeSparkline.js");b.BarcodeBase=d.BarcodeBase,b.Codabar=d.Codabar,b.Code128=d.Code128,b.Code39=d.Code39,b.Code49=d.Code49,b.Code93=d.Code93,b.DataMatrix=d.DataMatrix,b.EAN13=d.EAN13,b.EAN8=d.EAN8,b.GS1_128=d.GS1_128,b.PDF417=d.PDF417,b.QRCode=d.QRCode},"./dist/plugins/barcode/barcodeSparkline.js":function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D=this&&this.__extends||function(){var a=function(b,c){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,b){a.__proto__=b}||function(a,b){for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c])})(b,c)};return function(b,c){a(b,c);function d(){this.constructor=b}b.prototype=null===c?Object.create(c):(d.prototype=c.prototype,new d)}}();Object.defineProperty(b,"__esModule",{value:!0}),d=c("Core"),e=c("CalcEngine"),f=c("Common"),g=c("Sparkline"),h=c("./dist/plugins/barcode/lib/barcode.all.js"),i=d.GC$,j=i.isEmptyObject,k=e.Functions.Function,l=f.Common.j.Fa,m=f.Common.j.C4,n=e.Convert,o=n.Ca,p=e.Errors.Value;function E(a,b){var c=b,d={},e={},f={};return c.forEach(function(b,c){var g=a[c];if(!l(g))if(b.indexOf("quietZone")!==-1)switch(b){case"quietZoneLeft":e.left=g;break;case"quietZoneRight":e.right=g;break;case"quietZoneTop":e.top=g;break;case"quietZoneBottom":e.bottom=g}else if(b.indexOf("font")!==-1)switch(b){case"fontFontFamily":f.fontFamily=g;break;case"fontFontStyle":f.fontStyle=g;break;case"fontFontWeight":f.fontWeight=g;break;case"fontTextDecoration":f.textDecoration=g;break;case"fontTextAlign":f.textAlign=g;break;case"fontFontSize":f.fontSize=g}else d[b]=g}),j(e)||(d.quietZone=e),j(f)||(d.font=f),d}function F(a,b,c,d,e){return{plotX:a+e,plotY:b+e,plotWidth:c-2*e,plotHeight:d-2*e}}function G(a,b,c,d,e,f,g){var i,j,k,l,n,o,p,q,r,s=2,t=F(c,d,e,f,s),u=m(b),v=t.plotX,w=t.plotY,x=t.plotWidth,y=t.plotHeight;u.desiredSize={width:x,height:y,forceRounding:!1};try{i=new h(null,u)}catch(a){return}j=i.getSize(),k=parseInt(i.option.font.fontSize,10),k=isNaN(k)?12:k,l=window.screen,n=l.deviceXDPI,o=window.devicePixelRatio||(n?n/l.logicalXDPI:1),i.destroy(),u.desiredSize.width=x*o,u.desiredSize.height=y*o,u.font=u.font||{},u.font.fontSize=k*o*g.zoomFactor+"px",p=h.getDataUrl(u),q=g.sheet.bt,q&&(q.ko(p)?(r=q.lo(p),a.save(),a.rect(c,d,e,f),a.clip(),a.drawImage(r,0,0,r.width,r.height,v,w,j.width,j.height),a.restore()):q.fo(p))}q=["text","color","backgroundColor"],r=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return null},b.prototype.createFunction=function(){var a,b,c=this,d=this.getBarcodeInfo();if(d)return a=new k(d.fnName,d.minimum,d.maxmum),b=d.acceptsArrayArgIndex,a.acceptsArray=function(a){return a===b},a.evaluate=function(a){var e,f;a[b]=o(a[b])?a[b].array[0]:a[b],e=c.y_a(a,d.properties),e.type=d.type;try{f=m(e),new h(null,f)}catch(a){return p}return e},a},b.prototype.paint=function(a,b,c,d,e,f,g){G(a,b,c,d,e,f,g)},b.prototype.y_a=function(a,b){return E(a,b)},b}(g.SparklineEx),b.BarcodeBase=r,s=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_QRCODE",minimum:1,maxmum:16,type:"QRCode",acceptsArrayArgIndex:9,properties:q.concat(["errorCorrectionLevel","model","version","mask","connection","connectionNo","charCode","charset","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom","quietZoneAddOn"])}},b}(r),b.QRCode=s,t=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_EAN13",minimum:1,maxmum:18,type:"EAN13",properties:q.concat(["showLabel","labelPosition","addOn","addOnLabelPosition","fontFontFamily","fontFontStyle","fontFontWeight","fontTextDecoration","fontTextAlign","fontFontSize","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.EAN13=t,u=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_EAN8",minimum:1,maxmum:15,type:"EAN8",properties:q.concat(["showLabel","labelPosition","fontFontFamily","fontFontStyle","fontFontWeight","fontTextDecoration","fontTextAlign","fontFontSize","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.EAN8=u,v=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_CODABAR",minimum:1,maxmum:17,type:"Codabar",properties:q.concat(["showLabel","labelPosition","checkDigit","nwRatio","fontFontFamily","fontFontStyle","fontFontWeight","fontTextDecoration","fontTextAlign","fontFontSize","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.Codabar=v,w=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_CODE39",minimum:1,maxmum:19,type:"Code39",properties:q.concat(["showLabel","labelPosition","labelWithStartAndStopCharacter","checkDigit","nwRatio","fullASCII","fontFontFamily","fontFontStyle","fontFontWeight","fontTextDecoration","fontTextAlign","fontFontSize","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.Code39=w,x=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_CODE93",minimum:1,maxmum:17,type:"Code93",properties:q.concat(["showLabel","labelPosition","checkDigit","fullASCII","fontFontFamily","fontFontStyle","fontFontWeight","fontTextDecoration","fontTextAlign","fontFontSize","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.Code93=x,y=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_CODE128",minimum:1,maxmum:16,type:"Code128",properties:q.concat(["showLabel","labelPosition","codeSet","fontFontFamily","fontFontStyle","fontFontWeight","fontTextDecoration","fontTextAlign","fontFontSize","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.Code128=y,z=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_GS1_128",minimum:1,maxmum:16,type:"GS1_128",properties:q.concat(["showLabel","labelPosition","fontFontFamily","fontFontStyle","fontFontWeight","fontTextDecoration","fontTextAlign","fontFontSize","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.GS1_128=z,A=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_CODE49",minimum:1,maxmum:17,type:"Code49",properties:q.concat(["showLabel","labelPosition","grouping","groupNo","fontFontFamily","fontFontStyle","fontFontWeight","fontTextDecoration","fontTextAlign","fontFontSize","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.Code49=A,B=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_PDF417",minimum:1,maxmum:11,type:"PDF417",properties:q.concat(["errorCorrectionLevel","rows","columns","compact","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.PDF417=B,C=function(a){D(b,a);function b(){return a.call(this)||this}return b.prototype.getBarcodeInfo=function(){return{fnName:"BC_DATAMATRIX",minimum:1,maxmum:14,type:"DataMatrix",properties:q.concat(["eccMode","ecc200SymbolSize","ecc200EncodingMode","ecc00_140SymbolSize","structuredAppend","structureNumber","fileIdentifier","quietZoneLeft","quietZoneRight","quietZoneTop","quietZoneBottom"])}},b}(r),b.DataMatrix=C;function H(a){a&&(g.w_a[a.name()]=a)}k&&(H(new s),H(new t),H(new u),H(new v),H(new w),H(new x),H(new y),H(new z),H(new A),H(new B),H(new C))},"./dist/plugins/barcode/lib/barcode.all.js":function(a,b,c){!function b(c,d){a.exports=d()}("undefined"!=typeof self?self:this,function(){return function(a){var b={};function c(d){if(b[d])return b[d].exports;var e=b[d]={i:d,l:!1,exports:{}};return a[d].call(e.exports,e,e.exports,c),e.l=!0,e.exports}return c.m=a,c.c=b,c.d=function(a,b,d){c.o(a,b)||Object.defineProperty(a,b,{configurable:!1,enumerable:!0,get:d})},c.n=function(a){var b=a&&a.__esModule?function b(){return a.default}:function b(){return a};return c.d(b,"a",b),b},c.o=function(a,b){return Object.prototype.hasOwnProperty.call(a,b)},c.p="",c(c.s=20)}([function(a,b,c){"use strict";var d,e;Object.defineProperty(b,"__esModule",{value:!0}),d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},b.isFunction=f,b.isWindow=g,b.isDefined=h,b.isNaN=i,b.isNumberLike=j,b.sliceString=k,b.sliceArray=l,b.str2Array=m,b.combineTruthy=n,b.convertRadix=o,b.isEven=p,b.isOdd=q,b.toNumber=r,b.getUnit=s,b.getMaxValue=t,b.assign=u,b.deepMerge=v,b.strRepeat=w,b.isInteger=x,b.fillArray=y,b.strPadStart=z,b.registerPlugin=A,b.measureText=D,b.convertUnit=G,b.fixSize2PixelDefault=H,b.getQuietZoneRelativeValue=I,b.getQuietZonePixelValue=J;function f(a){return"function"==typeof a}function g(a){return!!a&&a===a.window}function h(a){return void 0!==a}function i(a){return f(Number.isNaN)?Number.isNaN(a):a!==a}function j(a){return!i(+a)}function k(){for(var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",b=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,c=arguments[2],d=0,e=a.length;d0&&void 0!==arguments[0]?arguments[0]:[],b=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,c=arguments[2],d=0,e=a.length;d0&&void 0!==arguments[0]?arguments[0]:"";return f(Array.from)?Array.from(a):Array.prototype.slice.call(a)}function n(){var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",b=m(a),c=[];return b.forEach(function(a){if("0"===a)c.push(0);else if(c[c.length-1]&&0!==c[c.length]){var b=c.pop();c.push(++b)}else c.push(1)}),c}function o(a){var b=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2;return a=+a,a.toString(b)}function p(a){return a%2===0}function q(a){return a%2===1}function r(){var a,b=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return"number"==typeof b?b:(a=parseFloat(b),i(a)?c:a)}function s(){var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",b=/[a-zA-Z]+/.exec(a);return b?b[0]:"px"}function t(a){var b=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"length",c=0;return a.forEach(function(a){a[b]>c&&(c=a[b])}),c}function u(a){var b,c,d,e,g,h,i;for(b=arguments.length,c=Array(b>1?b-1:0),d=1;d1?b-1:0),e=1;e=1<<28)throw new RangeError("repeat count must not overflow maximum string size");for(d="",e=0;e>=0,c=(void 0!==c?c:" ")+"",a.length>b?a:(b-=a.length,b>c.length&&(c+=w(c,b/c.length)),c.slice(0,b)+(a+"")))}e={};function A(a,b){e[a]=b}function B(a,b){var c=r(b.fontSize,12);return 1.4*c}function C(a,b){return e.measureText(a,b)}function D(a,c){return f(e.measureText)?(b.measureText=D=C,D(a,c)):B(a,c)}function E(a){var b=r(a,12);return b}function F(a){return j(a)?r(a,12):e.convertUnit(a)}function G(a){return f(e.convertUnit)?(b.convertUnit=G=F,G(a)):E(a)}function H(a){return j(a)?a+"px":a}function I(a){return a.originIsAbsoluteValue?0:a.relativeValue}function J(a){return a.originIsAbsoluteValue?a.pixelValue:0}},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n,o,p;Object.defineProperty(b,"__esModule",{value:!0});function q(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function r(a,b){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!b||"object"!=typeof b&&"function"!=typeof b?a:b}function s(a,b){if("function"!=typeof b&&null!==b)throw new TypeError("Super expression must either be null or a function, not "+typeof b);a.prototype=Object.create(b&&b.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(a,b):a.__proto__=b)}d=b.BadArgumentsException=function(a){s(b,a);function b(a){var c,d,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return q(this,b),c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this)),c.name="BadArgumentsException",d=JSON.stringify(a),c.message=d+" is not a valid argument. "+e,c}return b}(Error),e=b.TypeNotSupportException=function(a){s(b,a);function b(a){q(this,b);var c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return c.name="TypeNotSupportException",c.message=a+" is not support!",c}return b}(Error),f=b.NotAValidBarcodeEncoderException=function(a){s(b,a);function b(a){q(this,b);var c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return c.name="NotAValidBarcodeEncoderException",c.message=a+" is not support!",c}return b}(Error),g=b.SubclassNotImplementException=function(a){s(b,a);function b(){q(this,b);var a=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return a.name="SubclassNotImplementException",a.message="must implement by subclass!",a}return b}(Error),h=b.UnrecognizedRenderException=function(a){s(b,a);function b(a){q(this,b);var c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return c.name="UnrecognizedRenderException",c.message=a+" is not support!",c}return b}(Error),i=b.MethodNotImplementException=function(a){s(b,a);function b(a){q(this,b);var c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return c.name="MethodNotImplementException",c.message=a+" doesn't have this method!",c}return b}(Error),j=b.InvalidTextException=function(a){s(b,a);function b(){var a,c=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Empty text",d=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return q(this,b),a=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this)),a.name="InvalidTextException",a.message=c+" is invalid. "+d,a}return b}(Error),k=b.InvalidCharException=function(a){s(b,a);function b(a){q(this,b);var c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return c.name="InvalidCharException",c.message=a+" is invalid.",c}return b}(Error),l=b.TextTooLargeException=function(a){s(b,a);function b(){q(this,b);var a=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return a.name="TextTooLargeException",a.message="Text is too larget to encode",a}return b}(Error),m=b.ConnectionOverflowException=function(a){s(b,a);function b(a){q(this,b);var c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return c.name="ConnectionOverflowException",c.message="Max Connection Number is "+(a-1),c}return b}(Error),n=b.GroupOverflowException=function(a){s(b,a);function b(a){q(this,b);var c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return c.name="GroupOverflowException",c.message="Max Group Number is "+(a-1),c}return b}(Error),o=b.GroupSizeException=function(a){s(b,a);function b(a){q(this,b);var c=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return c.name="GroupSizeException",c.message="Group size is "+a+". The max group size is 9.",c}return b}(Error),p=b.InvalidStructureNumberException=function(a){s(b,a);function b(){q(this,b);var a=r(this,(b.__proto__||Object.getPrototypeOf(b)).call(this));return a.name="InvalidStructureNumberException",a.message="InvalidStructureNumberException.",a}return b}(Error)},function(a,b,c){"use strict";(function(a){var d,e,f,g,h,i,j,k,l,m,n;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c0&&void 0!==arguments[0]?arguments[0]:{},d=new a(c);return d.getImageData()}},{key:"getDataUrl",value:function b(){var c=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},d=new a(c);return d.getDataUrl()}},{key:"setDefaultOptions",value:function a(){var b=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};l=(0,e.deepMerge)({},b)}},{key:"registerEncoder",value:function b(c,d){m[c]=d,a.supportType.push(c)}},{key:"registerPlugin",value:function a(b,c){(0,e.registerPlugin)(b,c)}}]);function a(){var b,c,d,g,h,i;for(p(this,a),b=void 0,c=void 0,d=void 0,g=arguments.length,h=Array(g),i=0;i=3)b=h[0],c=h[1],d=h[2];else if(2===h.length)(0,e.isFunction)(h[1])?(c=h[0],d=h[1]):(b=h[0],c=h[1]);else{if(1!==h.length)throw new f.BadArgumentsException(h);c=h[0]}"string"==typeof b?this.dom=document.querySelector(b):this.dom=b,this.callback=d&&d.bind(this),this.setOption(c)}return d(a,[{key:"mergeOption",value:function a(b){return this.option=(0,e.deepMerge)({},this.option,b),this.update(),this}},{key:"setOption",value:function a(b){return this.option=(0,e.deepMerge)({},k,l,b),this.update(),this}},{key:"update",value:function a(){var b=this.option,c=m[b.type];if(!c)throw new f.TypeNotSupportException(b.type);this.encoder=new c(b),this.render&&(this.render.destroy(),this.render=null),this.render=new h.default(this.dom,this.encoder),this.render.render(),(0,e.isFunction)(this.callback)&&this.callback()}},{key:"getImageData",value:function a(){return this.render.getImageData()}},{key:"getDataUrl",value:function a(){return this.render.getDataUrl()}},{key:"getSize",value:function a(){return this.render.size}},{key:"destroy",value:function a(){this.render&&this.render.destroy()}}]),a}(),b.default=n,n.supportType=[],n.constants=j.default,(0,e.isWindow)(a)&&(a.Barcode=n)}).call(b,c(22))},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t;Object.defineProperty(b,"__esModule",{value:!0}),d=c(1),e=c(0),f=c(13),g=u(f);function u(a){return a&&a.__esModule?a:{default:a}}h={version:"auto",errorCorrectionLevel:"L",model:2,mask:"auto",connection:!1,connectionNo:0,charCode:void 0,charset:"UTF-8",quietZone:{top:4,left:4,right:4,bottom:4}},i={ECI:7,Numeric:1,Alphanumeric:2,"8BitByte":4,Kanji:8,StructuredAppend:3,FNC1First:5,FNC2Second:9,Terminator:0},j={L:1,M:0,Q:3,H:2};function v(a){return a>=48&&a<=57}function w(a){var b=" $%*+-./:";return b.indexOf(String.fromCharCode(a))>-1||(a>=48&&a<=57||a>=65&&a<=90)}function x(a){return a>=0&&a<=255}function y(a){return a>=33087&&a<=64587}k={Numeric:v,Alphanumeric:w,"8BitByte":x,Kanji:y};function z(a,b){var c=k[a];return 1===b.length?c(b):b.every(function(a){return c(a)})}function A(a){var b=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"UTF-8";return v(a)?"Numeric":w(a)?"Alphanumeric":"Shift_JIS"===b&&y(a)?"Kanji":"8BitByte"}l=function a(b){return 4*b+17};function B(a){return a>=1&&a<=9?{Numeric:10,Alphanumeric:9,"8BitByte":8,Kanji:8}:a>=10&&a<=26?{Numeric:12,Alphanumeric:11,"8BitByte":16,Kanji:10}:{Numeric:14,Alphanumeric:13,"8BitByte":16,Kanji:12}}m={" ":36,$:37,"%":38,"*":39,"+":40,"-":41,".":42,"/":43,":":44};function C(a){if(a>=48&&a<=57)return+String.fromCharCode(a);if(a>=65&&a<=90)return a-65+10;var b=m[String.fromCharCode(a)];if(b)return b;throw new d.InvalidTextException(String.fromCharCode(a))}function D(a){var b,c=[];for(b=0;b2&&void 0!==arguments[2]?arguments[2]:2,k=void 0;switch(b){case 1:k=0;break;case 0:k=1;break;case 3:k=2;break;case 2:k=3}for(c=2===j?r:s,d=c[4*(a-1)+k],e=[],f=d.length/3,g=0;g5&&(t+=3+d-5)}for(h=0;h0;f--)h=n>>f-1&1,f>9?(j[8][15-f]=h,j[i-1-15+f][8]=h):f>8?(j[8][15-f+1]=h,j[i-1-15+f][8]=h):f>6?(j[f][8]=h,j[8][i-f]=h):(j[f-1][8]=h,j[8][i-f]=h);return j}function K(a,b,c){var e,f,g,h,i=0,j=0,k=0,l=0;for(b.forEach(function(a){v(a)?i++:w(a)?j++:y(a)?l++:x(a)&&k++}),e=Math.ceil((5*j+3*i+13*l+8*k)/8),f=1;f<=40;f++)if(g=F(f,a,c),h=g.reduce(function(a,b){return a+=b.data},0),e<=h)return f;throw new d.TextTooLargeException}t={Alphanumeric:[[6,11],[7,15],[8,16]],Numeric:[[4,6,6,13],[4,7,8,15],[5,8,9,17]]};function L(a,b){var c=t[a];return b<=9?c[0]:b<=26?c[1]:c[2]}function M(a){var b,c,d,e=[];for(b=0,c=a.length;b>6,128|63&d):d<55296||d>=57344?e.push(224|d>>12,128|d>>6&63,128|63&d):(b++,d=65536+((1023&d)<<10|1023&a[b]),e.push(240|d>>18,128|d>>12&63,128|d>>6&63,128|63&d));return e}function N(a){var b,c,d=M(a),e=d[0];for(b=1,c=d.length;b","?","@","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","[","\\","]","^","_","\0","\x01","\x02","\x03","\x04","\x05","\x06","\x07","\b","\t","\n","\v","\f","\r","\x0e","\x0f","\x10","\x11","\x12","\x13","\x14","\x15","\x16","\x17","\x18","\x19","\x1a","\x1b","\x1c","\x1d","\x1e","\x1f"," "," "," "," "," "," "," "," "," "," "],i=[" ","!",'"',"#","$","%","&","'","(",")","*","+",",","-",".","/","0","1","2","3","4","5","6","7","8","9",":",";","<","=",">","?","@","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","[","\\","]","^","_","`","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","{","|","}","~","\x7f"," "," "," "," "," "," "," "," "," "," "],j=["212222","222122","222221","121223","121322","131222","122213","122312","132212","221213","221312","231212","112232","122132","122231","113222","123122","123221","223211","221132","221231","213212","223112","312131","311222","321122","321221","312212","322112","322211","212123","212321","232121","111323","131123","131321","112313","132113","132311","211313","231113","231311","112133","112331","132131","113123","113321","133121","313121","211331","231131","213113","213311","213131","311123","311321","331121","312113","312311","332111","314111","221411","431111","111224","111422","121124","121421","141122","141221","112214","112412","122114","122411","142112","142211","241211","221114","413111","241112","134111","111242","121142","121241","114212","124112","124211","411212","421112","421211","212141","214121","412121","111143","111341","131141","114113","114311","411113","411311","113141","114131","311141","411131","211412","211214","211232"],k="2331112",l={CodeC:99,CodeB:100,CodeA:101,FNC1:102,FNC2:97,FNC3:96,StartA:103,StartB:104,StartC:105},m={CodeC:String.fromCharCode(204),CodeB:String.fromCharCode(205),CodeA:String.fromCharCode(206),FNC1:g.default.FNC1,FNC2:g.default.FNC2,FNC3:g.default.FNC3,StartA:String.fromCharCode(208),StartB:String.fromCharCode(209),StartC:String.fromCharCode(210)};function p(a,b){if(a===m.FNC1)return l.FNC1;if(a===m.FNC2)return l.FNC2;if(a===m.FNC3)return l.FNC3;var c=void 0;switch(b){case"A":return c=h.indexOf(a);case"B":return c=i.indexOf(a);case"C":return+a}}function q(a,b){var c=j[p(a,b)];if(!c)throw new d.InvalidCharException(a);return c}function r(a){return j[a]}n={height:60,showLabel:!0,codeSet:"auto",quietZone:{top:0,right:10,bottom:0,left:10},labelPosition:"bottom"};function s(a){var b="";return(0,e.str2Array)(a).forEach(function(a,c){b+=(0,e.isEven)(c)?(0,e.strRepeat)("1",+a):(0,e.strRepeat)("0",+a)}),b}b.default={getCharValue:p,getCharPattern:q,getPatternByIndex:r,Code128Sym:l,stopPattern:k,defaultConfig:n,Code128Char:m,encode:s}},function(a,b,c){"use strict";var d,e,f,g,h,i;Object.defineProperty(b,"__esModule",{value:!0}),d="\xcf",e="\xca",f="\xc9",g="\u2000",h="\u2004",i="\u2005",b.default={FNC1:d,FNC2:e,FNC3:f,DataMatrixFNC1:g,DataMatrixMacro05:h,DataMatrixMacro06:i}},function(a,b,c){"use strict";var d,e,f,g,h;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c=b)return v(i.keys[c]);throw new e.TextTooLargeException}function x(a){var b=void 0,c=void 0;switch(a){case 1:case 2:b=1;break;case 4:b=2;break;case 16:b=4;break;case 36:b=6}return c=~~(a/b),{rowOfRegion:b,colOfRegion:c}}function y(a,b){var c,e;for(b||(b=a),c=[],e=0;el?a==h.FNC1Input?"FNC1":"ExtendedASCII":a>=o&&a<=p?"Numeric":a>=q&&a<=r?"LowerCasedLetter":a>=s&&a<=t?"UpperCasedLetter":"ASCIIOther"}function A(a){var b=z(a);switch(b){case"Numeric":return a-44;case"UpperCasedLetter":return a-51;default:switch(a){case 13:return 0;case 42:return 1;case 62:return 2;case 32:return 3}}return h.InvalidTripletValue}function B(a,b){if("X12"==a)return A(b);if(b<32)return b;if(32==b)return 3;if(b<48)return b-33;if(b<58)return b-44;if(b<65)return b-43;if(b<91)return"C40"==a?b-51:b-64;if(b<96)return b-69;if(96==b)return 0;if(b<123)return"C40"==a?b-96:b-83;if(b<128)return b-96;if(b==k||b==j)return b-128;throw new e.InvalidCharException(String.fromCharCode(b))}function C(a){return a>=o&&a<=p}function D(a,b){return"X12"===a?0:b<32?1:32==b?0:b<48?2:b<58?0:b<65?2:b<91?"C40"==a?0:3:b<96?2:96==b?3:b<123?"C40"===a?3:0:b==h.TripletFNC1||b==h.TripletUppershift?2:3}function E(a,b){var c,d=[];if(b==h.FNC1Input){if("X12"==a)throw new e.InvalidCharException("FNC1");b=h.TripletFNC1}else if(b>l){if("C40"!=a&&"Text"!=a)throw new e.InvalidCharException(String.fromCharCode(b));d.push(h.TripletShifts[2]),d.push(B(a,h.TripletUppershift)),b-=m}return c=D(a,b),c>0&&d.push(h.TripletShifts[c]),d.push(B(a,b)),d}function F(a){return a<32||a>94?h.InvalidTripletValue:a&h.EDIFACTMask}function G(a,b,c){var d=a+h.PseudoRandomSeed*b%c+1;return d>c+1?d-c-1:d}function H(a){var b,c,e=[];if(a.length>0){for(b=a[0],c=1;c0&&e.push((0,d.assign)({},b)),b.charSet=a[c].charSet,b.start=a[c].start,b.length=a[c].length):b.length+=a[c].length;b.length>0&&e.push(b)}return e}b.default={getSymbolInfo:v,getInfoOfRegions:x,createModules:y,CONSTANTS:h,getTripletCharValue:B,getRandomizedValue:G,getCharType:z,getSuitableSymbolSize:w,isDigit:C,getTripletCharSetChannel:D,getX12Value:A,getEDIFACTValue:F,getTripletEncodeValues:E,mergeUnits:H,TripletUppershift:j,TripletFNC1:k,ASCIIMax:l,ExtendedASCIIMin:m,Space:n,NumericMin:o,NumericMax:p,LowerCasedLetterMin:q,LowerCasedLetterMax:r,UpperCasedLetterMin:s,UpperCasedLetterMax:t,setRegionData:J,setFinder:I};function I(a,b,c,e){var f,g,h,i,j,k=b.regionColumns,l=b.regionRows;for(l+=2,k+=2,c*=l,e*=k,f=a[c],g=e;g1&&void 0!==arguments[1]?arguments[1]:{};h(this,a),this.config=(0,f.deepMerge)({},w,b),c=this.config,d=c.text,e=c.quietZone,g=c.unitSize,i=c.height,j=c.backgroundColor,k=c.color,l=c.renderType,m=c.labelPosition,n=c.desiredSize,o=c.showLabel,p=c.font,(0,f.isDefined)(d)&&(this.config.text+=""),(0,f.isDefined)(m)&&(this.isLabelBottom="top"!==m),g=(0,f.fixSize2PixelDefault)(g),p.fontSize=(0,f.fixSize2PixelDefault)(p.fontSize),q=(0,f.convertUnit)(g),r=(0,f.measureText)(d,p),this.fontHeight=r,s=o?r/q:0,this.style=(0,f.assign)({},p,{backgroundColor:j,color:k,fontSizeInUnit:s,unitValue:q,renderType:l,fontHeight:r}),e=(0,f.assign)({},e);for(t in e)e.hasOwnProperty(t)&&(u=e[t],(0,f.isNumberLike)(u)?e[t]={relativeValue:+u,originIsAbsoluteValue:!1}:(v=(0,f.convertUnit)(u),e[t]={relativeValue:v/q,originIsAbsoluteValue:!0,pixelValue:v}));this.quietZone=e,(0,f.isDefined)(i)&&((0,f.isNumberLike)(i)?this.height=+i-s-e.top.relativeValue-e.bottom.relativeValue:this.height=(0,f.convertUnit)(i)/q-s-e.top.relativeValue-e.bottom.relativeValue),n&&(this.containerWidth=(0,f.convertUnit)((0,f.fixSize2PixelDefault)(n.width)),this.containerHeight=(0,f.convertUnit)((0,f.fixSize2PixelDefault)(n.height))),this.shapes=[],this.size={width:0,height:0},this.validate()}return d(a,[{key:"validate",value:function a(){throw new e.SubclassNotImplementException}},{key:"adjustDesiredSize",value:function a(){throw new e.SubclassNotImplementException}},{key:"convertToShape",value:function a(){throw new e.SubclassNotImplementException}}]),a}(),b.default=g},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c1&&void 0!==arguments[1]&&arguments[1];return u(this,b),c=v(this,(b.__proto__||Object.getPrototypeOf(b)).call(this,a,j.default.defaultConfig)),d=c.config.text,c.isUccEan128=f,f&&d[0]!==j.default.Code128Char.FNC1&&(d=j.default.Code128Char.FNC1+d),c.text=d,c.label=d.replace(/[^\x20-\x7E]/g,""),e=c.calculateData(),c.adjustDesiredSize(e),c.convertToShape(e),c}return d(b,[{key:"validate",value:function a(){}},{key:"calculateData",value:function a(){var b=this.config,c=this.text,d=this.isUccEan128,e=void 0;if(d)e=new r.default(c);else switch(b.codeSet){case"A":e=new l.default(c);break;case"B":e=new n.default(c);break;case"C":e=new p.default(c);break;default:e=new r.default(c)}return e.getData()}}]),b}(h.default),b.default=s,f.default.registerEncoder("Code128",s)},function(a,b,c){"use strict";var d,e,f,g,h,i,j;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c1&&void 0!==arguments[1]&&arguments[1],d=(0,g.str2Array)(b),e=c?g.isOdd:g.isEven,f=d.reduce(function(a,b,c){return b=+b,a+=e(c)?b:3*b},0),h=f%10;return 0===h?0:10-h}},{key:"convertToShape",value:function a(b){var c,d,e,f,h,i,j,k,l,m,n=this.isTextGroup,o=this.isLabelBottom,p=this.addOnHeight,q=this.isAddOnLabelBottom,r=this.height,s=this.quietZone,t=this.config.showLabel,u=this.style,v=u.fontSizeInUnit,w=u.textAlign;t||(v=0),p=p||0,c=[],d=void 0,e=s.left.relativeValue,f=s.top.relativeValue,h=void 0,i=void 0,j=void 0,k=void 0,l=void 0,m=void 0,o?(d=r+5,h=f+r,i=t?r+v:d,q?(j=f,l="auto"===p?t?r:d:p,k=j+l):(k=f,j=f+v,l="auto"===p?d-v:p)):(d=r,r-=5,h=f,f+=v,i=t?d+v:d,q?(j=s.top.relativeValue,l="auto"===p?t?r:d:p,k=j+l):(k=s.top.relativeValue,j=s.top.relativeValue+v,l="auto"===p?d:p)),m=t?l+v:l,b.forEach(function(a){var b,i=f,m=r,o=h,p=n?"center":w,q=void 0,u=e;switch(a.role){case"GUARD":m=d,q=a.binary.length;break;case"ADDON":i=j,m=l,o=k,q=a.binary.length;break;case"LEFT_QUIET_ZONE":p="left",q=s.left.relativeValue,u=0;break;case"RIGHT_QUIET_ZONE":case"NO_ADDON_RIGHT_QUIET_ZONE":p="right",q=s.right.relativeValue;break;case"ADDON_QUIET_ZONE":q=s.addOn.relativeValue;break;case"ADDON_RIGHT_QUIET_ZONE":p="right",o=k,q=s.right.relativeValue;break;default:q=a.binary.length}if(t&&a.text){switch(p){case"center":u+=q/2;break;case"right":u+=q}b={type:"text",x:u,y:o,text:a.text,textAlign:p,maxWidth:q},"NO_ADDON_RIGHT_QUIET_ZONE"!==a.role&&"ADDON_RIGHT_QUIET_ZONE"!==a.role||(b.fontStyle="normal",b.fontWeight="normal",b.textDecoration="none"),c.push(b)}a.binary?(0,g.combineTruthy)(a.binary).forEach(function(a){0!==a?(c.push({type:"rect",x:e,y:i,width:a,height:m}),e+=a):e++}):"ADDON_QUIET_ZONE"===a.role&&(e+=q)}),this.size={width:e+s.right.relativeValue,height:Math.max(i,m)+s.top.relativeValue+s.bottom.relativeValue},this.shapes=c}},{key:"adjustDesiredSize",value:function a(b){var c,d,e,f=this.config,h=f.desiredSize,i=f.showLabel,j=f.addOn,k=f.addOnHeight,l=this.fontHeight,m=this.containerWidth,n=this.containerHeight,o=this.addOnHeightInPiexl,p=this.quietZone;h&&(c=b.reduce(function(a,b){return b.binary&&(a+=b.binary.length),a},0),c=c+(0,g.getQuietZoneRelativeValue)(p.left)+(0,g.getQuietZoneRelativeValue)(p.right),j&&(c+=(0,g.getQuietZoneRelativeValue)(p.addOn),m-=(0,g.getQuietZonePixelValue)(p.addOn)),m=m-(0,g.getQuietZonePixelValue)(p.left)-(0,g.getQuietZonePixelValue)(p.right),d=void 0,e=void 0,h.forceRounding?(d=~~(m/c),e=d<1?1:d):d=e=m/c,this.style.unitValue=e,this.style.fontSizeInUnit=l/e,n=i?n-l:n,n=n-(0,g.getQuietZonePixelValue)(p.top)-(0,g.getQuietZonePixelValue)(p.bottom),this.height=n/e-(0,g.getQuietZoneRelativeValue)(p.top)-(0,g.getQuietZoneRelativeValue)(p.bottom),Object.keys(p).forEach(function(a){p[a].originIsAbsoluteValue&&(p[a].relativeValue=p[a].pixelValue/e)}),(0,g.isDefined)(j)&&"auto"!==k&&(k=(0,g.isNumberLike)(k)?+k:o/e,k>this.height?this.addOnHeight=this.height:this.addOnHeight=k))}}]),b}(f.default),b.default=j},function(a,b,c){"use strict";var d,e,f,g;Object.defineProperty(b,"__esModule",{value:!0}),d=1335,e=7973,f=21522,g=10277;function h(a){for(var b=0;0!=a;)b+=1,a>>>=1;return b}function i(a,b){for(var c=2===b?f:g,e=a<<10;h(e)-h(d)>=0;)e^=d<=0;)b^=e<g?(k.push(l),i=j-1):j===h&&k.push(b),l=b,j++;return k}},{key:"processConnection",value:function a(b){var c,d,e,f,g,h=this.totalDataBits,j=this.config,k=j.connection,l=j.connectionNo;if(l=+l,k){if(c=Math.ceil(b.length/(h-20)),l>c-1)throw new i.ConnectionOverflowException(c);return d=this.getConnections(),e=d[l],f=this.analysisData(e),g=this.encodeData(f,{connectionNo:l,connectionCnt:c})}if(b.length>h)throw new i.TextTooLargeException;return b}},{key:"padBuffer",value:function a(b){var c=this.totalDataBits;for(b.length+4<=c&&b.put(f.default.MODE_INDICATOR.Terminator,4);b.length%8!=0;)b.putBit(!1);for(;;){if(b.length>=c)break;if(b.put(f.default.padCodewords0,8),b.length>=c)break;b.put(f.default.padCodewords1,8)}}},{key:"getAutoVersion",value:function a(){var b,c,d,e=this.errorCorrectionLevel,g=this.charCode,h=this.model,j=f.default.getEstimatedVersion(e,g,h);for(b=j;b<40;b++)if(this.version=b,this.modulesCount=f.default.getSizeByVersion(this.version),this.charCountIndicatorBitsNumber=f.default.getCharacterCountIndicatorbitsNumber(this.version),this.errorCorrectionCharacteristics=f.default.getErrorCorrectionCharacteristics(this.version,e),this.totalDataCount=this.errorCorrectionCharacteristics.reduce(function(a,b){return a+=b.data},0),this.totalDataBits=8*this.totalDataCount,c=this.analysisData(g),d=this.encodeData(c),!(d.length>this.totalDataBits))return b;throw new i.TextTooLargeException}},{key:"analysisData",value:function a(b){var c,d,e,g,h,i,j,k=this.version,l=this.config.charset,m=f.default.getCharMode(b[0],l);switch(m){case"Alphanumeric":c=f.default.getModeCheckInfo(m,k),d=b.slice(1,1+c[0]),f.default.isMode("8BitByte",d)&&(m="8BitByte");break;case"Numeric":e=f.default.getModeCheckInfo(m,k),g=b.slice(1,1+e[0]),h=b.slice(1,1+e[1]),f.default.isMode("8BitByte",g)?m="8BitByte":f.default.isMode("Alphanumeric",h)&&(m="Alphanumeric")}return i={mode:m,code:[]},j=[i],b.forEach(function(a,c){var d,e,g,h=f.default.getCharMode(a,l);i.mode===h?i.code.push(a):"8BitByte"===i.mode?"Kanji"===h?(i={mode:h,code:[a]},j.push(i)):"Numeric"===h?(d=f.default.getModeCheckInfo(h,k),f.default.isMode(h,b.slice(c,c+d[2]))?(i={mode:h,code:[a]},j.push(i)):i.code.push(a)):"Alphanumeric"===h?(e=f.default.getModeCheckInfo(h,k),f.default.isMode(h,b.slice(c,c+e[1]))?(i={mode:h,code:[a]},j.push(i)):i.code.push(a)):i.code.push(a):"Alphanumeric"===i.mode?"Kanji"===h||"8BitByte"===h?(i={mode:h,code:[a]},j.push(i)):"Numeric"===h?(g=f.default.getModeCheckInfo(h,k),f.default.isMode(h,b.slice(c,c+g[2]))?(i={mode:h,code:[a]},j.push(i)):i.code.push(a)):i.code.push(a):(i={mode:h,code:[a]},j.push(i))}),j}},{key:"encodeData",value:function a(){throw new i.SubclassNotImplementException}},{key:"generateErrorCorrectionCode",value:function a(b){var c=this.errorCorrectionCharacteristics,d=[],e=0;return c.forEach(function(a){var c=b.getBuffer().slice(e,e+a.data);d.push({data:c,ec:(0,h.default)(c,a.ec,a.data)}),e+=a.data}),d}},{key:"getFinalMessage",value:function a(){throw new i.SubclassNotImplementException}},{key:"setModules",value:function a(){throw new i.SubclassNotImplementException}},{key:"maskModules",value:function a(){throw new i.SubclassNotImplementException}},{key:"autoMask",value:function a(){throw new i.SubclassNotImplementException}},{key:"addRectModule",value:function a(b,c,d,e){for(var f,g=arguments.length>4&&void 0!==arguments[4]&&arguments[4],h=this.modules,i=e+c,j=d+b;c33088&&a<40956?(a-=33088,c=a>>>8,d=255&a,g=192*c+d):a>57408&&a<60351&&(a-=49472,e=a>>>8,f=255&a,g=192*e+f),b.put(g,13)})}}]),a}(),b.default=g},function(a,b,c){"use strict";var d,e;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c0&&void 0!==arguments[0]?arguments[0]:[];f(this,a),this.buffer=b,this.length=8*b.length,this.index=0}return d(a,[{key:"putBit",value:function a(b){var c=Math.floor(this.length/8);this.buffer.length<=c&&this.buffer.push(0),b&&(this.buffer[c]|=128>>>this.length%8),this.length+=1}},{key:"put",value:function a(b,c){for(var d=0;d>>c-d-1&1))}},{key:"getAt",value:function a(b){var c=Math.floor(b/8);return 1==(this.buffer[c]>>>7-b%8&1)}},{key:"getBuffer",value:function a(){return this.buffer}},{key:"next",value:function a(){return this.index++,this.getAt(this.index-1)}}]), a}(),b.default=e},function(a,b,c){c(21),c(11),c(31),c(33),c(35),c(37),c(45),c(48),c(49),c(53),c(57),c(58),a.exports=c(2)},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c9?d-9:d):a+=e,a},0)%10;return 0!==a&&(a=10-a),a}}]),b}(f.default),b.default=n,h.default.registerEncoder("Codabar",n)},function(a,b){var c;c=function(){return this}();try{c=c||Function("return this")()||(0,eval)("this")}catch(a){"object"==typeof window&&(c=window)}a.exports=c},function(a,b,c){"use strict";var d,e,f,g,h,i,j;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;cg?(d=Math.floor(g/h.width*f.length),b.text.substr(0,d)):f}},{key:"clear",value:function a(){var b=this.dom;b.removeChild(this.g),this.addGroup()}},{key:"meatureText",value:function a(b){return b.setAttribute("x",0),b.setAttribute("y",0),this.dom.appendChild(b),b.getBBox()}},{key:"getDataUrl",value:function a(){return"data:image/svg+xml;base64,"+btoa(this.dom.outerHTML)}}]),a}(),b.default=f},function(a,b,c){"use strict";var d,e;Object.defineProperty(b,"__esModule",{value:!0}),d={height:60,showLabel:!0,labelPosition:"bottom",checkDigit:!1,quietZone:{top:0,right:10,bottom:0,left:10},nwRatio:3},e={0:"0000011",1:"0000110",2:"0001001",3:"1100000",4:"0010010",5:"1000010",6:"0100001",7:"0100100",8:"0110000",9:"1001000","-":"0001100",$:"0011000",":":"1000101","/":"1010001",".":"1010100","+":"0010101",A:"0011010",B:"0101001",C:"0001011",D:"0001110"},b.default={defaultConfig:d,TABLE:e}},function(a,b,c){"use strict";var d,e,f,g,h,i;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c1&&void 0!==arguments[1]&&arguments[1];n(this,a),this.text=b,this.isUccEan128=c,this.validate()}return d(a,[{key:"validate",value:function a(){var b=this.text,c=/^[\x00-\x7F\xC8-\xD3]+$/;if(!c.test(b))throw new h.InvalidTextException(b)}},{key:"calculateGroup",value:function a(){var b,c,d,e,h=this.text,l=this.isUccEan128,m={code:l?k:j,text:""},n=[];for(n.push(m),b=0,c=h.length;b81)throw new l.TextTooLargeException}},{key:"getModes",value:function a(){var b,c,d,e,f,g,h=this.text,i=this.config,k=i.grouping,m=i.groupNo;if(k&&(b=j.default.getTextGroup(h),b.length>1)){if(b.length>9)throw new l.GroupSizeException(b.length);if(m>b.length-1)throw new l.GroupOverflowException(b.length);this.groupCount=b.length,this.mode=3,h=b[m]}for(c=[],d=0,e=0,f=h.length;d"9");)e++;e-d>=5?(c.push({mode:"number",text:h.substring(d,e)}),d=e):(g=c[c.length-1],g&&"alpha"===g.mode?g.text+=h.substring(d,e+1):c.push({mode:"alpha",text:h.substring(d,e+1)}),d=++e)}this.modes=c}},{key:"encodeNumeric",value:function a(b){var c=void 0,d=void 0;switch(b.length){case 3:return c=+b,[~~(c/48),c%48];case 4:return c=+b+1e5,[~~(c/2304),~~(c%2304/48),c%48];case 5:return c=+b,[~~(c/2304),~~(c%2304/48),c%48];case 6:return c=b.substr(0,5),this.encodeNumeric(c).concat([+b[5]]);case 7:return c=b.substr(0,4),d=b.substr(4,3),this.encodeNumeric(c).concat(this.encodeNumeric(d));case 8:return c=b.substr(0,5),d=b.substr(5,3),this.encodeNumeric(c).concat(this.encodeNumeric(d));case 9:return c=b.substr(0,5),d=b.substr(5,4),this.encodeNumeric(c).concat(this.encodeNumeric(d));default:return c=b.substr(0,5),d=b.substr(5,b.length),this.encodeNumeric(c).concat(this.encodeNumeric(d))}}},{key:"encodeAlpha",value:function a(b){return(0,k.str2Array)(b).reduce(function(a,b){return a=a.concat(j.default.getCharValue(b))},[])}},{key:"calculateData",value:function a(){var b,c,d,e,f,g,h,i,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G=this,H=this.modes,I=this.mode,J=this.groupCount,K=this.config.groupNo,L=H.reduce(function(a,b,c){return"number"===b.mode?(0===c&&2!==I&&a.push(j.default.CODE_NS),a=a.concat(G.encodeNumeric(b.text))):a=a.concat(G.encodeAlpha(b.text)),a.push(j.default.CODE_NS),a},[]);for(L.pop(),3===I&&L.unshift(j.default.getGroupInfo(K,J)),b=L.length%7;L.length%7!==0;)L.push(j.default.CODE_NS);if(c=[],(0,k.sliceArray)(L,7,function(a){var b=a.reduce(function(a,b){return a+=b},0);a.push(b%49),c=c.concat(a)}),d=L.length/7,(d%8>=6||b>2||0==b||d%8===1)&&(c=c.concat((0,k.fillArray)(Array(8),j.default.CODE_NS)),d++),d>8)throw new l.TextTooLargeException;if(e=7*(d-2)+I,c[c.length-2]=e,f=j.default.getWeight(0,0),g=e*f.z,h=e*f.y,i=e*f.x,m=8*(d-1)/2,d>6){for(n=0,o=0;n-1?[d]:(b=a.charCodeAt(0),c=m[b],(0,f.str2Array)(c).map(function(a){return l.indexOf(a)}))}function t(a,b){var c=j[a][b];return{x:c[0],y:c[1],z:c[2]}}function u(a,b,c,d){var e=b===d-1,f=void 0,g=void 0;return f=!e&&k[b][c],g=f?h[a]:i[a],g.toString(2)}function v(a,b){for(var c=2,d=1;c-1?a++:a+=2,a},0)}function x(a){for(var b,c=0,d=1,e=a.length,f=[];d48&&(f.push(a.substring(c,d-1)),c=d-1),d++;return f.push(a.substring(c,d)),f}b.default={defaultConfig:g,isNumericOnly:r,getCharValue:s,CODE_NS:n,getWeight:t,getParityPattern:u,START_PATTERN:o,STOP_PATTERN:p,getGroupInfo:v,getTextGroup:x}},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c20&&(c=1),a+=c*d,c++,a},0);return k.default.getCharByValue(d%47)}}]),b}(f.default),b.default=m,h.default.registerEncoder("Code93",m)},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k;Object.defineProperty(b,"__esModule",{value:!0}),d=c(1),e=c(0),f=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","-","."," ","$","/","+","%","[","]","{","}","*"],g=["131112","111213","111312","111411","121113","121212","121311","111114","131211","141111","211113","211212","211311","221112","221211","231111","112113","112212","112311","122112","132111","111123","111222","111321","121122","131121","212112","212211","211122","211221","221121","222111","112122","112221","122121","123111","121131","311112","311211","321111","112131","113121","211131","121221","312111","311121","122211","111141"],h=["]U","[A","[B","[C","[D","[E","[F","[G","[H","[I","[J","[K","[L","[M","[N","[O","[P","[Q","[R","[S","[T","[U","[V","[W","[X","[Y","[Z","]A","]B","]C","]D","]E"," ","{A","{B","{C","{D","{E","{F","{G","{H","{I","{J","{K","{L","{M","{N","{O","0","1","2","3","4","5","6","7","8","9","{Z","]F","]G","]H","]I","]J","]V","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","]K","]L","]M","]N","]O","]W","}A","}B","}C","}D","}E","}F","}G","}H","}I","}J","}K","}L","}M","}N","}O","}P","}Q","}R","}S","}T","}U","}V","}W","}X","}Y","}Z","]P","]Q","]R","]S","]T"];function l(a){var b=f.indexOf(a);if(b===-1)throw new d.InvalidCharException(a);return g[b]}function m(a){var b=f.indexOf(a);if(b===-1)throw new d.InvalidCharException(a);return b}function n(a){return f[a]}i={height:60,showLabel:!0,checkDigit:!1,fullASCII:!1,quietZone:{top:0,right:10,bottom:0,left:10},labelPosition:"bottom"},j="*",k="1";function o(a){var b="";return(0,e.sliceString)(a,1,function(c){var e=h[c.charCodeAt(0)];if(!e)throw new d.InvalidTextException(a);b+=e}),b}b.default={getCode93Code:l,START_STOP_CHARACTERS:j,defaultConfig:i,TERMINATION:k,getCode93Value:m,getCharByValue:n,getFullASCIIChar:o}},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n,o,p,q;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;cg.default.CONSTANTS.Base256SmallBlockSize?2:1)}return f}},{key:"getMaxProperLength",value:function a(b,c){for(var d=this.m_symbol,e=this.encodingMode,f=b+1,g=d.length,h=~~((f+g)/2),i=0,j=0;fc?g=h-1:f=h+1;return f>b&&(hc?h-b:f-b):(h=Math.min(h,f),j=this.getEncodingLength(e,this.getCodeWordLength(e,b,h-b),b,h-b),i=j<0||j>c?h-b-1:h-b)),Math.max(0,i)}},{key:"getCodeWordLength",value:function a(b,c,d){var e,f,h=this.m_symbol,i=0;for(e=c;eg.default.ASCIIMax&&f!=g.default.CONSTANTS.FNC1Input?2:1,eg.default.ASCIIMax&&(i+=2,f-=128),i+=0==g.default.getTripletCharSetChannel(b,f)?1:2;break;case"X12":g.default.getX12Value(f)==g.default.CONSTANTS.InvalidTripletValue?i=-1:i+=1;break;case"EDIFACT":g.default.getEDIFACTValue(f)==g.default.CONSTANTS.InvalidTripletValue?i=-1:i+=1;break;case"Base256":i+=1}if(i<0)return i}return i}},{key:"getCodeLength",value:function a(b){return this.getEncodingLength(b.charSet,this.getCodeWordLength(b.charSet,b.start,b.length),b.start,b.length)}},{key:"getEncodingUnitsInfomative",value:function a(b,c,d){var e,f,h,i,j,k,l,m,n,o,p,q,r,s=this.m_symbol;for(d=0,e=[],f={charSet:"ASCII",start:b,length:0,codeWords:0,encodingLength:0},h=0,i=b,j=!1,k=s.length;i0){if(f.codeWords+=l>>1,i+=l,h+~~(l/2)>=c)break;continue}break;case"C40":case"Text":case"X12":do s[i]>g.default.ASCIIMax&&(f.codeWords+=2),g.default.getTripletCharSetChannel(f.charSet,s[i])>0&&++f.codeWords,++f.codeWords,++i;while(f.codeWords%3!=0&&i0&&this.getEncodingLength(p,this.getCodeWordLength(p,i,m),i,m)>n);if(o<=0)break;if(f.charSet!=p&&(f.length=i-f.start,f.length>0&&(e.push(f),h+=this.getEncodingLength(f.charSet,f.codeWords,f.start,f.length)),f={charSet:p,start:i,length:0,codeWords:0,encodingLength:0},j=!0),r=c-1,"EDIFACT"==f.charSet&&--r,"Base256"==f.charSet&&++r,h+this.getEncodingLength(f.charSet,f.codeWords,f.start,f.length)>=r)break;j||"ASCII"!=f.charSet||(++f.codeWords,++i)}for(f.length=i-f.start,f.length>0&&(e.push(f),h+=this.getEncodingLength(f.charSet,f.codeWords,f.start,f.length)),f={charSet:"ASCII",start:i,length:0,codeWords:0,encodingLength:0};hg.default.ASCIIMax&&s[i]!=g.default.CONSTANTS.FNC1Input){if(!(hf.start&&(f.length=i-f.start,e.push(f)),d=i-b,{s_taken:d,units:g.default.mergeUnits(e)}}},{key:"getEncodingUnits",value:function a(b,c){var d,e,f=this,g=this.encodingMode,h=this.m_symbol,i=void 0,j=0,k=0;return b>8),f[b++]=q(e),b}},{key:"generateFileIdentifier",value:function a(b,c){var d=this.m_symbol,e=this.fileIdentifier,f=c%g.default.CONSTANTS.FileIdentifierMax+1,h=0==e?d.length%g.default.CONSTANTS.FileIdentifierMax+1:e;return f<<8|h}},{key:"encode",value:function a(b,c){switch(b.charSet){case"ASCII":return this.encodeASCII(b.start,b.length,c);case"C40":return this.encodeC40(b.start,b.length,c);case"Text":return this.encodeText(b.start,b.length,c);case"X12":return this.encodeX12(b.start,b.length,c);case"EDIFACT":return this.encodeEDIFACT(b.start,b.length,c);case"Base256":return this.encodeBase256(b.start,b.length,c)}}},{key:"encodeASCII",value:function a(b,c,d){var e,f,h,i,j=this.m_code,k=this.m_symbol;for(e=b,f=b+c;e=3;){for(p=0,q=0;q<3;++q)p*=40,p+=s.length>0?s.shift():0;++p,m[e++]=p>>8,m[e++]=255&p}if(f=!0,s.length>0){if(h=o.symbolDataCapacity-e,i=c+d-s.length,k=s.length,0===h||s.length>3||s.length>=2&&h<2||"X12"===b&&this.getEncodingLength("ASCII",this.getCodeWordLength("ASCII",i,k),i,k)>(1==h?1:h-1))throw new j.TextTooLargeException;if(f=!1,h>=2)if("X12"==b)m[e++]=g.default.CONSTANTS.TripletUnlatch,e=this.encodeASCII(t-s.length,s.length,e);else{for(f=!0,q=0,p=0;q<3;++q)p*=40, p+=s.length>0?s.shift():0;++p,m[e++]=p>>8,m[e++]=255&p}else l=n[t-1],"X12"===b?e=this.encodeASCII(t-1,1,e):(l>g.default.ASCIIMax&&(m[e-2]=g.default.CONSTANTS.TripletUnlatch,--e),e=this.encodeASCII(t-1,1,e))}return f&&e2;){for(e=0,f=0;e<4;){if(++e,k=0,h>4),l[d++]=q(f<<4);break;case 3:l[d++]=q(f>>10),l[d++]=q(f>>2),l[d++]=q(f<<6);break;case 4:l[d++]=q(f>>16),l[d++]=q(f>>8),l[d++]=q(f)}}return hg.default.CONSTANTS.Base256SmallBlockSize&&(f[d++]=g.default.getRandomizedValue(g.default.CONSTANTS.Base256SmallBlockSize+c/g.default.CONSTANTS.Base256SmallBlockSize,d,g.default.CONSTANTS.Base256RandomBase)),f[d++]=g.default.getRandomizedValue(c%(g.default.CONSTANTS.Base256SmallBlockSize+1),d,g.default.CONSTANTS.Base256RandomBase),e=b;eg.default.ASCIIMax,j.forEach(function(a,c){switch(c){case t.ASCII:l&&!d?j[c]=r(j[c])+2:g.default.isDigit(b)?j[c]+=.5:j[c]+=1;break;case t.C40:case t.Text:d?j[c]+=4/3:l?j[c]+=8/3:j[c]+=0==g.default.getTripletCharSetChannel(u[c],b)?2/3:4/3;break;case t.X12:l?j[c]+=13/3:g.default.getX12Value(b)!=g.default.CONSTANTS.InvalidTripletValue?j[c]+=2/3:j[c]+=10/3;break;case t.EDIFACT:l?j[c]+=4.25:g.default.getEDIFACTValue(b)!=g.default.CONSTANTS.InvalidTripletValue?j[c]+=.75:j[c]+=3.25;break;case t.Base256:j[c]+=1}}),m=[t.ASCII,t.Base256,t.EDIFACT,t.Text,t.X12,t.C40],f>3)for(n=0;n=e)return h=!0,"break"};a:for(;c=g.default.CONSTANTS.MaxLookAheadOffset||h){for(n=0,o=0;o3116*(B?16:1))throw new j.TextTooLargeException;if(b=0,c=0,d=0,e=0,f=0,"squareAuto"!==A&&"rectangularAuto"!==A?D=g.default.getSymbolInfo(A):"rectangularAuto"===A&&(D=g.default.getSymbolInfo("rectangular16x48")),this.symbolInfo=D,B||(h=this.preEncode(b,c),b=h.s_pos,c=h.c_pos),i=D.symbolDataCapacity,B?(i-=4,d=4):(i-=c,d=c),!this.checkValue(b))throw new j.InvalidTextException(y);for(k=void 0;e<(B?g.default.CONSTANTS.MaxStructures:1)&&b0;--h)i[h]=n(o(g,j[h]),i[h-1]);i[0]=o(j[0],g)}return i.reverse(),i}},function(a,b,c){"use strict";var d,e,f,g;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c=0&&null===d[e][f]&&this.utah(e,f,g++),e-=2,f+=2;while(e>=0&&f=0&&f=0);e+=3,f+=1}while(e569)throw new g.TextTooLargeException;if(b=f.default.chooseEncodationScheme(n),c="ECC000"===p?7:19,d=this.calculateDataBits(b),e=this.calculateTotalBits(b,c,d),h=this.sLa=f.default.getProperSymbolSize(o,e),e>f.default.getSymbolSizeInfo(h))throw new g.TextTooLargeException;return d+=30,i=[],k=new j.default(i),k.putBitsMSF(f.default.Constants.getFormatID(b)<<27,5),l=this.crcProcess(b),k.putBitsLSF(l,16),k.putBitsLSF(n.length,9),this.encode(b,k),m=new j.default(q),m.putBitsLSF(f.default.getECC(p).headerBits,c),k.offset=0,this.eccProcess(m,k,d),this.randomizeBits(),this.placeModule()}},{key:"eccProcess",value:function a(b,c,d){var e,g,h,i,j,k,l,m,n=this.eccMode;if("ECC000"!==n){e=f.default.getECC(n).eccInfo,g=[e.inputBits],h=!1;do{for(h=!1,i=0;i>=1,g[i]=f.default.setBit(g[i],e.registerBits[i],c.fetchBit());for(j=!1,k=0;k=d){for(m=0;m>=1,0!=(j[d]&1<=48&&a<=57||32==a?h.Base11:a>=65&&a<=90?h.Base27:a>=44&&a<=47?h.Base41:a<=i?h.ASCII:h.Byte}function o(a){var b,c,d=h.Base11;for(b=0,c=a.length;bc&&(c=b);break;case h.Base27:b==h.Base11?c=h.Base37:b>c&&(c=b);break;case h.Base37:case h.Base41:b>c&&(c=b)}return c}function q(a){return a%256}function r(a,b){if(a==h.Byte)return b;if(a==h.ASCII)return q(127&b);var c=0;if(32==b)return c;if(b>=48&&b<=57&&(c=q(b-47)),a==h.Base11)return c;if(c+=26,b>=65&&b<=90&&(c=q(b-64)),a!=h.Base41)return c;switch(b){case 44:return 38;case 45:return 39;case 46:return 37;case 47:return 40}return c}function s(a,b,c){var d=1<=this.bitLength)&&0!=(this.aT[~~(b/8)]&128>>b%8)}},{key:"setBit",value:function a(b,c){var d=~~(b/8),e=(128>>b%8)%256;this.aT[d]&=(this.aT[d]&~e)%256,c&&(this.aT[d]|=e)}},{key:"putBit",value:function a(b){this.setBit(this.offset,b),this.offset++}},{key:"putBitsMSF",value:function a(b,c,d){var e,f,g=!!d;for(g||(d=this.offset),e=2147483648,f=0;f",role:"RIGHT_QUIET_ZONE"}),g}}]),b}(f.default),b.default=k},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c",role:"NO_ADDON_RIGHT_QUIET_ZONE"}),k}},{key:"addon",value:function a(b){var c,d,e,f,g,k=this,l=this.addOn,m=this.isTextGroup;if(2===l.length)c=void 0,d=void 0,e=void 0,c=h.default.get2DigitAddOnTable(l),d=this.encodeChar(l[0],c.leftStructure,0),e=this.encodeChar(l[1],c.rightStructure,0),m?(b.push({binary:h.default.ADD_ON_GUARD,role:"ADDON"}),b.push({binary:d,text:l[0],role:"ADDON"}),b.push({binary:h.default.ADD_ON_DELINEATOR,role:"ADDON"}),b.push({binary:e,text:l[1],role:"ADDON"})):b.push({binary:h.default.ADD_ON_GUARD+d+h.default.ADD_ON_DELINEATOR+e,text:l,role:"ADDON"});else{if(5!==l.length)throw new i.BadArgumentsException(l);f=h.default.get5DigitAddOnTable(l),m?(b.push({binary:h.default.ADD_ON_GUARD,role:"ADDON"}),(0,j.str2Array)(l).forEach(function(a,c){b.push({binary:k.encodeFor5DigitAddOn(a,c,f),text:a,role:"ADDON"}),c",role:"ADDON_RIGHT_QUIET_ZONE"})}},{key:"encodeFor5DigitAddOn",value:function a(b,c,d){var e=h.default.TABLE[d[c]];return e[b]}}]),b}(f.default),b.default=k},function(a,b,c){"use strict";var d,e,f,g,h;Object.defineProperty(b,"__esModule",{value:!0}),d=c(2),e=i(d),f=c(11),g=i(f);function i(a){return a&&a.__esModule?a:{default:a}}function j(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function k(a,b){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!b||"object"!=typeof b&&"function"!=typeof b?a:b}function l(a,b){if("function"!=typeof b&&null!==b)throw new TypeError("Super expression must either be null or a function, not "+typeof b);a.prototype=Object.create(b&&b.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(a,b):a.__proto__=b)}h=function(a){l(b,a);function b(a){return j(this,b),k(this,(b.__proto__||Object.getPrototypeOf(b)).call(this,a,!0))}return b}(g.default),b.default=h,e.default.registerEncoder("GS1_128",h)},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n,o,p,q;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c8))throw new p.BadArgumentsException({errorCorrectionLevel:d},"ErrorCorrectionLevel is from 0 - 8.");if((0,k.isNumberLike)(e)&&(e<3||e>90))throw new p.BadArgumentsException({rows:e},"Rows is from 3 - 90.");if((0,k.isNumberLike)(f)&&(f<1||f>30))throw new p.BadArgumentsException({columns:f},"Columns is from 1 - 30.")}},{key:"encodeNC",value:function a(b){var c=b.text,d=[];return(0,k.sliceString)(c,44,function(a){for(var b,c=new o.default("1"+a),e=[];;)if(b=c.modulo(900),c=c.dividedToIntegerBy((0,o.default)(900)),e.unshift(+(""+b)),c.lessThan(1))break;d=d.concat(e)}),d.unshift(j.default.MODE_NC),d}},{key:"encodeBC",value:function a(b){var c=b.text,d=[];return(0,k.sliceString)(c,6,function(a){var b,c,e,f;if(6===a.length){b=5,c=0,(0,k.sliceString)(a,1,function(a){c+=a.charCodeAt(0)*Math.pow(256,b--)}),e=0,f=Math.floor(c/Math.pow(900,e))%900;do d.unshift(f),f=Math.floor(c/Math.pow(900,++e))%900;while(f>0)}else(0,k.sliceString)(a,1,function(a){d.push(a.charCodeAt(0))})}),d.unshift(b.mode),d}},{key:"encodeTC",value:function a(b){var c,d=[],e="al";return b.subModes.forEach(function(a){e!==a.mode&&(d=d.concat(j.default.getTCSubModeValue(a.mode,e))),(0,k.sliceString)(a.text,1,function(b){d.push(j.default.getTCValue(b,a.mode))}),"ps"!==a.mode&&"as"!==a.mode&&(e=a.mode)}),c=[j.default.MODE_TC],(0,k.sliceArray)(d,2,function(a){2===a.length?c.push(30*a[0]+a[1]):c.push(30*a[0]+29)}),c}},{key:"encode",value:function a(b){var c=this,d=[];b.forEach(function(a){switch(a.mode){case j.default.MODE_TC:d=d.concat(c.encodeTC(a));break;case j.default.MODE_BC:case j.default.MODE_BC6:case j.default.MODE_BC_SHIFT:d=d.concat(c.encodeBC(a));break;case j.default.MODE_NC:d=d.concat(c.encodeNC(a))}}),d[0]===j.default.MODE_TC&&d.shift(),this.data=d}},{key:"genEcc",value:function a(){var b,c,d,e,f,g,h=this.data,i=this.ecl,k=this.columns,l=this.rows;if("auto"===i&&(this.ecl=i=j.default.getAutoECL(h)),b=Math.pow(2,i+1),c=h.length+1+b,"auto"===l&&"auto"===k)d=j.default.getAutoRowAndCol(c),e=d.col,f=d.row,this.columns=k=e,this.rows=l=f;else if("auto"===l){if(l=Math.ceil(c/k),l>90)throw new p.BadArgumentsException({columns:k},"Columns is not large enough");l=l<3?3:l,this.rows=l}else if("auto"===k){if(k=Math.ceil(c/l),k>30)throw new p.BadArgumentsException({rows:l},"Rows is not large enough");this.columns=k}if(g=k*l-b,h.unshift(g),h.length>j.default.MAX_DATA_NUM||h.length>g)throw new p.TextTooLargeException;for(;h.length@[\\]_`~!\r\t,:\n-.$/\"|*()?{}'"+m],s={errorCorrectionLevel:"auto",columns:"auto",rows:"auto",compact:!1,height:60,quietZone:{top:2,left:2,right:2,bottom:2}},t=900,u=901,v=902,w=924,x=913;function z(a){return r[0].indexOf(a)>-1}function A(a){return r[1].indexOf(a)>-1}function B(a){return r[2].indexOf(a)>-1}function C(a){return r[3].indexOf(a)>-1}function D(a){return z(a)||A(a)||B(a)||C(a)}function E(a,b){for(var c=b,d=a.length,e=0;c="0"&&a[c]<="9"?e++:e=0,D(a[c]));){if(e>=13){c-=--e;break}c++}return a.substring(b,c)}function F(a,b){for(var c=b,d=a.length;c"9");)c++;return a.substring(b,c)}function G(a,b){for(var c=b,d=a.length,e=0,f=0;c"9"?e++:e=0,D(a[c])?f++:e=0,f>=5){c-=--f;break}if(e>=13){c-=--e;break}c++}return a.substring(b,c)}function H(a){for(var b,c,d,e=0,f=a.length,g={mode:t,text:""},h=[];e=13?(g={mode:v,text:b},h.push(g),e+=b.length):(c=E(a,e),c.length>=5?(g={mode:t,text:c},h.push(g),e+=c.length):(d=G(a,e),1===d.length&&g.mode==t?(g={mode:x,text:d},h.push(g)):(g=d.length%6===0?{mode:w,text:d}:{mode:u,text:d},h.push(g)),e+=d.length));return h.forEach(function(a){var b,c,d,e,f,g,h;if(a.mode==t)for(b={mode:"al",text:""},c=[b],a.subModes=c,d=0,e=a.text.length;d-1?[c]:y[b][a]}function M(a,b){var c,e=[];for(c=0;c0;--b)e=d*c[b]%929,h=929-e,g[b]=(g[b-1]+h)%929;e=d*c[0]%929,h=929-e,g[0]=h%929}),g.forEach(function(a,b){0!=a&&(g[b]=929-a)}),g.reverse()}},function(a,b,c){var d;!function(e){"use strict";var f,g=/^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,h=Math.ceil,i=Math.floor,j=" not a boolean or binary digit",k="rounding mode",l="number type has more than 15 significant digits",m="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_",n=1e14,o=14,p=9007199254740991,q=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],r=1e7,s=1e9;function t(a){var b,c,d=0,e=P.prototype,f=new P(1),D=20,E=4,F=-7,G=21,H=-1e7,I=1e7,J=!0,K=T,L=!1,M=1,N=0,O={decimalSeparator:".",groupSeparator:",",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:"\xa0",fractionGroupSize:0};function P(a,b){var e,f,h,j,k,n,q=this;if(!(q instanceof P))return new P(a,b);if(null!=b&&K(b,2,64,d,"base")){if(b=0|b,n=a+"",10==b)return q=new P(a instanceof P?a:n),W(q,D+q.e+1,E);if((j="number"==typeof a)&&0*a!=0||!RegExp("^-?"+(e="["+m.slice(0,b)+"]+")+"(?:\\."+e+")?$",b<37?"i":"").test(n))return c(q,n,j,b);j?(q.s=1/a<0?(n=n.slice(1),-1):1,J&&n.replace(/^0\.0*|\./,"").length>15&&V(d,l,a),j=!1):q.s=45===n.charCodeAt(0)?(n=n.slice(1),-1):1,n=Q(n,10,b,q.s)}else{if(a instanceof P)return q.s=a.s,q.e=a.e,q.c=(a=a.c)?a.slice():a,void(d=0);if((j="number"==typeof a)&&0*a==0){if(q.s=1/a<0?(a=-a,-1):1,a===~~a){for(f=0,h=a;h>=10;h/=10,f++);return q.e=f,q.c=[a],void(d=0)}n=a+""}else{if(!g.test(n=a+""))return c(q,n,j);q.s=45===n.charCodeAt(0)?(n=n.slice(1),-1):1}}for((f=n.indexOf("."))>-1&&(n=n.replace(".","")),(h=n.search(/e/i))>0?(f<0&&(f=h),f+=+n.slice(h+1),n=n.substring(0,h)):f<0&&(f=n.length),h=0;48===n.charCodeAt(h);h++);for(k=n.length;48===n.charCodeAt(--k););if(n=n.slice(h,k+1))if(k=n.length,j&&J&&k>15&&(a>p||a!==i(a))&&V(d,l,q.s*a),f=f-h-1,f>I)q.c=q.e=null;else if(fc)return null!=(a=f[c++])};return h(b="DECIMAL_PLACES")&&K(a,0,s,2,b)&&(D=0|a),e[b]=D,h(b="ROUNDING_MODE")&&K(a,0,8,2,b)&&(E=0|a),e[b]=E,h(b="EXPONENTIAL_AT")&&(y(a)?K(a[0],-s,0,2,b)&&K(a[1],0,s,2,b)&&(F=0|a[0],G=0|a[1]):K(a,-s,s,2,b)&&(F=-(G=0|(a<0?-a:a)))),e[b]=[F,G],h(b="RANGE")&&(y(a)?K(a[0],-s,-1,2,b)&&K(a[1],1,s,2,b)&&(H=0|a[0],I=0|a[1]):K(a,-s,s,2,b)&&(0|a?H=-(I=0|(a<0?-a:a)):J&&V(2,b+" cannot be zero",a))),e[b]=[H,I],h(b="ERRORS")&&(a===!!a||1===a||0===a?(d=0,K=(J=!!a)?T:x):J&&V(2,b+j,a)),e[b]=J,h(b="CRYPTO")&&(a===!0||a===!1||1===a||0===a?a?(a="undefined"==typeof crypto,!a&&crypto&&(crypto.getRandomValues||crypto.randomBytes)?L=!0:J?V(2,"crypto unavailable",a?void 0:crypto):L=!1):L=!1:J&&V(2,b+j,a)),e[b]=L,h(b="MODULO_MODE")&&K(a,0,9,2,b)&&(M=0|a),e[b]=M,h(b="POW_PRECISION")&&K(a,0,s,2,b)&&(N=0|a),e[b]=N,h(b="FORMAT")&&("object"==typeof a?O=a:J&&V(2,b+" not an object",a)),e[b]=O,e},P.max=function(){return S(arguments,e.lt)},P.min=function(){return S(arguments,e.gt)},P.random=function(){var a=9007199254740992,b=Math.random()*a&2097151?function(){return i(Math.random()*a)}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(a){var c,d,e,g,j,k=0,l=[],m=new P(f);if(a=null!=a&&K(a,0,s,14)?0|a:D,g=h(a/o),L)if(crypto.getRandomValues){for(c=crypto.getRandomValues(new Uint32Array(g*=2));k>>11),j>=9e15?(d=crypto.getRandomValues(new Uint32Array(2)),c[k]=d[0],c[k+1]=d[1]):(l.push(j%1e14),k+=2);k=g/2}else if(crypto.randomBytes){for(c=crypto.randomBytes(g*=7);k=9e15?crypto.randomBytes(7).copy(c,k):(l.push(j%1e14),k+=7);k=g/7}else L=!1,J&&V(14,"crypto unavailable",crypto);if(!L)for(;k=10;j/=10,k++);k=0&&(h=N,N=0,a=a.replace(".",""),l=new P(d),j=l.pow(a.length-n),N=h,l.c=z(B(v(j.c),j.e),10,c),l.e=l.c.length),k=z(a,d,c),g=h=k.length;0==k[--h];k.pop());if(!k[0])return"0";if(n<0?--g:(j.c=k,j.e=g,j.s=e,j=b(j,l,o,p,c),k=j.c,i=j.r,g=j.e),f=g+o+1,n=k[f],h=c/2,i=i||f<0||null!=k[f+1],i=p<4?(null!=n||i)&&(0==p||p==(j.s<0?3:2)):n>h||n==h&&(4==p||i||6==p&&1&k[f-1]||p==(j.s<0?8:7)),f<1||!k[0])a=i?B("1",-o):"0";else{if(k.length=f,i)for(--c;++k[--f]>c;)k[f]=0,f||(++g,k=[1].concat(k));for(h=k.length;!k[--h];);for(n=0,a="";n<=h;a+=m.charAt(k[n++]));a=B(a,g)}return a}b=function(){function a(a,b,c){var d,e,f,g,h=0,i=a.length,j=b%r,k=b/r|0;for(a=a.slice();i--;)f=a[i]%r,g=a[i]/r|0,d=k*f+g*j,e=j*f+d%r*r+h,h=(e/c|0)+(d/r|0)+k*g,a[i]=e%c;return h&&(a=[h].concat(a)),a}function b(a,b,c,d){var e,f;if(c!=d)f=c>d?1:-1;else for(e=f=0;eb[e]?1:-1;break}return f}function c(a,b,c,d){for(var e=0;c--;)a[c]-=e,e=a[c]1;a.splice(0,1));}return function(d,e,f,g,h){var j,k,l,m,p,q,r,s,t,v,w,x,y,z,A,B,C,D=d.s==e.s?1:-1,E=d.c,F=e.c;if(!(E&&E[0]&&F&&F[0]))return new P(d.s&&e.s&&(E?!F||E[0]!=F[0]:F)?E&&0==E[0]||!F?0*D:D/0:NaN);for(s=new P(D),t=s.c=[],k=d.e-e.e,D=f+k+1,h||(h=n,k=u(d.e/o)-u(e.e/o),D=D/o|0),l=0;F[l]==(E[l]||0);l++);if(F[l]>(E[l]||0)&&k--,D<0)t.push(1),m=!0;else{for(z=E.length,B=F.length,l=0,D+=2,p=i(h/(F[0]+1)),p>1&&(F=a(F,p,h),E=a(E,p,h),B=F.length,z=E.length),y=B,v=E.slice(0,B),w=v.length;w=h/2&&A++;do{if(p=0,j=b(F,v,B,w),j<0){if(x=v[0],B!=w&&(x=x*h+(v[1]||0)),p=i(x/A),p>1)for(p>=h&&(p=h-1),q=a(F,p,h),r=q.length,w=v.length;1==b(q,v,r,w);)p--,c(q,B=10;D/=10,l++);W(s,f+(s.e=l+k*o-1)+1,g,m)}else s.e=k,s.r=+m;return s}}();function R(a,b,c,d){var e,f,g,h,i;if(c=null!=c&&K(c,0,8,d,k)?0|c:E,!a.c)return""+a;if(e=a.c[0],g=a.e,null==b)i=v(a.c),i=19==d||24==d&&g<=F?A(i,g):B(i,g);else if(a=W(new P(a),b,c),f=a.e,i=v(a.c),h=i.length,19==d||24==d&&(b<=f||f<=F)){for(;hh){if(--b>0)for(i+=".";b--;i+="0");}else if(b+=f-h,b>0)for(f+1==h&&(i+=".");b--;i+="0");return a.s<0&&e?"-"+i:i}function S(a,b){var c,d,e=0;for(y(a[0])&&(a=a[0]),c=new P(a[0]);++ec||a!=C(a))&&V(d,(e||"decimal places")+(ac?" out of range":" not an integer"),a),!0}function U(a,b,c){for(var d=1,e=b.length;!b[--e];b.pop());for(e=b[0];e>=10;e/=10,d++);return(c=d+c*o-1)>I?a.c=a.e=null:c=10;j/=10,e++);if(f=b-e,f<0)f+=o,g=b,k=p[l=0],m=k/r[e-g-1]%10|0;else if(l=h((f+1)/o),l>=p.length){if(!d)break a;for(;p.length<=l;p.push(0));k=m=0,e=1,f%=o,g=f-o+1}else{for(k=j=p[l],e=1;j>=10;j/=10,e++);f%=o,g=f-o+e,m=g<0?0:k/r[e-g-1]%10|0}if(d=d||b<0||null!=p[l+1]||(g<0?k:k%r[e-g-1]),d=c<4?(m||d)&&(0==c||c==(a.s<0?3:2)):m>5||5==m&&(4==c||d||6==c&&(f>0?g>0?k/r[e-g]:0:p[l-1])%10&1||c==(a.s<0?8:7)),b<1||!p[0])return p.length=0,d?(b-=a.e+1,p[0]=r[(o-b%o)%o],a.e=-b||0):p[0]=a.e=0,a;if(0==f?(p.length=l,j=1,l--):(p.length=l+1,j=r[o-f],p[l]=g>0?i(k/r[e-g]%r[g])*j:0),d)for(;;){if(0==l){for(f=1,g=p[0];g>=10;g/=10,f++);for(g=p[0]+=j,j=1;g>=10;g/=10,j++);f!=j&&(a.e++,p[0]==n&&(p[0]=1));break}if(p[l]+=j,p[l]!=n)break;p[l--]=0,j=1}for(f=p.length;0===p[--f];p.pop());}a.e>I?a.c=a.e=null:a.e0},e.greaterThanOrEqualTo=e.gte=function(a,b){return d=7,1===(b=w(this,new P(a,b)))||0===b},e.isFinite=function(){return!!this.c},e.isInteger=e.isInt=function(){return!!this.c&&u(this.e/o)>this.c.length-2},e.isNaN=function(){return!this.s},e.isNegative=e.isNeg=function(){return this.s<0},e.isZero=function(){return!!this.c&&0==this.c[0]},e.lessThan=e.lt=function(a,b){return d=8,w(this,new P(a,b))<0},e.lessThanOrEqualTo=e.lte=function(a,b){return d=9,(b=w(this,new P(a,b)))===-1||0===b},e.minus=e.sub=function(a,b){var c,e,f,g,h,i,j,k,l=this,m=l.s;if(d=10,a=new P(a,b),b=a.s,!m||!b)return new P(NaN);if(m!=b)return a.s=-b,l.plus(a);if(h=l.e/o,i=a.e/o,j=l.c,k=a.c,!h||!i){if(!j||!k)return j?(a.s=-b,a):new P(k?l:NaN);if(!j[0]||!k[0])return k[0]?(a.s=-b,a):new P(j[0]?l:3==E?-0:0)}if(h=u(h),i=u(i),j=j.slice(),m=h-i){for((g=m<0)?(m=-m,f=j):(i=h,f=k),f.reverse(),b=m;b--;f.push(0));f.reverse()}else for(e=(g=(m=j.length)<(b=k.length))?m:b,m=b=0;b0)for(;b--;j[c++]=0);for(b=n-1;e>m;){if(j[--e]0?(f=e,c=h):(j=-j,c=g),c.reverse();j--;c.push(0));c.reverse()}for(j=g.length,b=h.length,j-b<0&&(c=h,h=g,g=c,b=j),j=0;b;)j=(g[--b]=g[b]+h[b]+j)/n|0,g[b]=n===g[b]?0:g[b]%n;return j&&(g=[j].concat(g),++f),U(a,g,f)},e.precision=e.sd=function(a){var b,c,d=this,e=d.c;if(null!=a&&a!==!!a&&1!==a&&0!==a&&(J&&V(13,"argument"+j,a),a!=!!a&&(a=null)),!e)return null;if(c=e.length-1,b=c*o+1,c=e[c]){for(;c%10==0;c/=10,b--);for(c=e[0];c>=10;c/=10,b++);}return a&&d.e+1>b&&(b=d.e+1),b},e.round=function(a,b){var c=new P(this);return(null==a||K(a,0,s,15))&&W(c,~~a+this.e+1,null!=b&&K(b,0,8,15,k)?0|b:E),c},e.shift=function(a){var b=this;return K(a,-p,p,16,"argument")?b.times("1e"+C(a)):new P(b.c&&b.c[0]&&(a<-p||a>p)?b.s*(a<0?0:1/0):b)},e.squareRoot=e.sqrt=function(){var a,c,d,e,f,g=this,h=g.c,i=g.s,j=g.e,k=D+4,l=new P("0.5");if(1!==i||!h||!h[0])return new P(!i||i<0&&(!h||h[0])?NaN:h?g:1/0);if(i=Math.sqrt(+g),0==i||i==1/0?(c=v(h),(c.length+j)%2==0&&(c+="0"),i=Math.sqrt(c),j=u((j+1)/2)-(j<0||j%2),i==1/0?c="1e"+j:(c=i.toExponential(),c=c.slice(0,c.indexOf("e")+1)+j),d=new P(c)):d=new P(i+""),d.c[0])for(j=d.e,i=j+k,i<3&&(i=0);;)if(f=d,d=l.times(f.plus(b(g,f,k,1))),v(f.c).slice(0,i)===(c=v(d.c)).slice(0,i)){if(d.e=0;){for(c=0,p=y[f]%v,q=y[f]/v|0,h=j,g=f+h;g>f;)k=x[--h]%v,l=x[h]/v|0,i=q*k+l*p,k=p*k+i%v*v+s[g]+c,c=(k/t|0)+(i/v|0)+q*l,s[g--]=k%t;s[g]=c}return c?++e:s.splice(0,1),U(a,s,e)},e.toDigits=function(a,b){var c=new P(this);return a=null!=a&&K(a,1,s,18,"precision")?0|a:null,b=null!=b&&K(b,0,8,18,k)?0|b:E,a?W(c,a,b):c},e.toExponential=function(a,b){return R(this,null!=a&&K(a,0,s,19)?~~a+1:null,b,19)},e.toFixed=function(a,b){return R(this,null!=a&&K(a,0,s,20)?~~a+this.e+1:null,b,20)},e.toFormat=function(a,b){var c,d,e,f,g,h,i,j,k,l,m=R(this,null!=a&&K(a,0,s,21)?~~a+this.e+1:null,b,21);if(this.c){if(d=m.split("."),e=+O.groupSize,f=+O.secondaryGroupSize,g=O.groupSeparator,h=d[0],i=d[1],j=this.s<0,k=j?h.slice(1):h,l=k.length,f&&(c=e,e=f,f=c,l-=c),e>0&&l>0){for(c=l%e||e,h=k.substr(0,c);c0&&(h+=g+k.slice(c)),j&&(h="-"+h)}m=i?h+O.decimalSeparator+((f=+O.fractionGroupSize)?i.replace(RegExp("\\d{"+f+"}\\B","g"),"$&"+O.fractionGroupSeparator):i):h}return m},e.toFraction=function(a){var c,d,e,g,h,i,j,k,l,m=J,n=this,p=n.c,r=new P(f),s=d=new P(f),t=j=new P(f);if(null!=a&&(J=!1,i=new P(a),J=m,(m=i.isInt())&&!i.lt(f)||(J&&V(22,"max denominator "+(m?"out of range":"not an integer"),a),a=!m&&i.c&&W(i,i.e+1,1).gte(f)?i:null)),!p)return""+n;for(l=v(p),g=r.e=l.length-n.e-1,r.c[0]=q[(h=g%o)<0?o+h:h],a=!a||i.cmp(r)>0?g>0?r:s:i,h=I,I=1/0,i=new P(l),j.c[0]=0;k=b(i,r,0,1),e=d.plus(k.times(t)),1!=e.cmp(a);)d=t,t=e,s=j.plus(k.times(e=s)),j=e,r=i.minus(k.times(e=r)),i=e;return e=b(a.minus(d),t,0,1),j=j.plus(e.times(s)),d=d.plus(e.times(t)),j.s=s.s=n.s,g*=2,c=b(s,t,g,E).minus(n).abs().cmp(b(j,d,g,E).minus(n).abs())<1?[""+s,""+t]:[""+j,""+d],I=h,c},e.toNumber=function(){return+this},e.toPower=e.pow=function(a,b){var c,e,g,j=i(a<0?-a:+a),k=this;if(null!=b&&(d=23,b=new P(b)),!K(a,-p,p,23,"exponent")&&(!isFinite(a)||j>p&&(a/=0)||parseFloat(a)!=a&&!(a=NaN))||0==a)return c=Math.pow(+k,a),new P(b?c%b:c);for(b?a>1&&k.gt(f)&&k.isInt()&&b.gt(f)&&b.isInt()?k=k.mod(b):(g=b,b=null):N&&(c=h(N/o+2)),e=new P(f);;){if(j%2){if(e=e.times(k),!e.c)break;c?e.c.length>c&&(e.c.length=c):b&&(e=e.mod(b))}if(j=i(j/2),!j)break;k=k.times(k),c?k.c&&k.c.length>c&&(k.c.length=c):b&&(k=k.mod(b))}return b?e:(a<0&&(e=f.div(e)),g?e.mod(g):c?W(e,N,E):e)},e.toPrecision=function(a,b){return R(this,null!=a&&K(a,1,s,24,"precision")?0|a:null,b,24)},e.toString=function(a){var b,c=this,d=c.s,e=c.e;return null===e?d?(b="Infinity",d<0&&(b="-"+b)):b="NaN":(b=v(c.c),b=null!=a&&K(a,2,64,25,"base")?Q(B(b,e),0|a,10,d):e<=F||e>=G?A(b,e):B(b,e),d<0&&c.c[0]&&(b="-"+b)),b},e.truncated=e.trunc=function(){return W(new P(this),this.e+1,1)},e.valueOf=e.toJSON=function(){var a,b=this,c=b.e;return null===c?""+b:(a=v(b.c),a=c<=F||c>=G?A(a,c):B(a,c),b.s<0?"-"+a:a)},e.isBigNumber=!0,null!=a&&P.config(a),P}function u(a){var b=0|a;return a>0||a===b?b:b-1}function v(a){for(var b,c,d=1,e=a.length,f=a[0]+"";dj^c?1:-1;for(h=(i=e.length)<(j=f.length)?i:j,g=0;gf[g]^c?1:-1;return i==j?0:i>j^c?1:-1}function x(a,b,c){return(a=C(a))>=b&&a<=c}function y(a){return"[object Array]"==Object.prototype.toString.call(a)}function z(a,b,c){for(var d,e=[0],f,g=0,h=a.length;gc-1&&(null==e[d+1]&&(e[d+1]=0),e[d+1]+=e[d]/c|0,e[d]%=c)}return e.reverse()}function A(a,b){return(a.length>1?a.charAt(0)+"."+a.slice(1):a)+(b<0?"e":"e+")+b}function B(a,b){var c,d;if(b<0){for(d="0.";++b;d+="0");a=d+a}else if(c=a.length,++b>c){for(d="0",b-=c;--b;d+="0");a+=d}else b14))throw new o.BadArgumentsException({version:c},"Model 1 only support version 1 - 14.");if("2"==d&&(0,p.isNumberLike)(c)&&(c<1||c>40))throw new o.BadArgumentsException({version:c},"Model 2 only support version 1 - 40.");if(h>15||h<0)throw new o.BadArgumentsException({connectionNo:h},"ConnectionNo is in range 0 - 15.")}}]),b}(f.default),b.default=q,h.default.registerEncoder("QRCode",q)},function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t;Object.defineProperty(b,"__esModule",{value:!0}),d=function(){function a(a,b){var c,d;for(c=0;c=0;){if(j==i-5)e=4;else if(8==j)e=2;else if(6==j){j--;continue}for(;k>=0;)if(null===b[k][j]){for(g=0;g=255;)j-=255;m[h]=d[j]}for(k=0;k<=n.length-1;k++)o[k]=o[k]^m[k]}for(l=1;l6&&this.addVersionInformation(),this.maskModules(b)}},{key:"maskModules",value:function a(b){var c,d,e=this.modules,f=this.errorCorrectionLevel,h=this.model,i=this.config.mask;"auto"===i?this.autoMask(b):(c=g.default.getMaskFunc(i),this.maskPattern=i,d=g.default.addFormatInformation(e,i,f,h),this.modules=this.fillDataModules(d,b,c))}},{key:"autoMask",value:function a(b){var c=this,d=this.modules,e=this.errorCorrectionLevel,f=this.model,h=void 0,i=void 0,j=void 0;g.default.maskFuncs.forEach(function(a,k){var l=g.default.addFormatInformation(d,k,e,f),m=c.fillDataModules(l,b,a),n=g.default.getMaskScore(m);(!i||n>b&1,e[Math.floor(b/3)][b%3+d-8-3]=c,e[b%3+d-8-3][Math.floor(b/3)]=c}},{key:"fillDataModules",value:function a(b,c,d){var e,f,g,h=b.length,i=-1,j=h-1,k=7,l=0;for(e=h-1;e>0;e-=2)for(6==e&&(e-=1);;){for(f=0;f<2;f+=1)null==b[j][e-f]&&(g=!1,l>>k&1)),d(j,e-f)&&(g=!g),b[j][e-f]=+g,k-=1,k==-1&&(l+=1,k=7));if(j+=i,j<0||h<=j){j-=i,i=-i;break}}return b}},{key:"getMatrix",value:function a(){var b,c,d=this.charCode,e=this.analysisData(d),f=this.encodeData(e),g=this.processConnection(f);return this.padBuffer(g),b=this.generateErrorCorrectionCode(g),c=this.getFinalMessage(b),this.setModules(c),this.modules}}]),b}(k.default),b.default=v},function(a,b,c){"use strict";var d=c(2),e=f(d);function f(a){return a&&a.__esModule?a:{default:a}}function g(a){var b,c=document.createElement("div");return c.style.visibility="hidden",c.style.absolute="hidden",c.style.padding="0",c.style.border="0",c.style.width=a,document.body.appendChild(c),b=c.getBoundingClientRect(),document.body.removeChild(c),b.width}e.default.registerPlugin("convertUnit",g)},function(a,b,c){"use strict";var d=c(2),e=f(d);function f(a){return a&&a.__esModule?a:{default:a}}function g(a,b){var c,d=document.createElement("span");return d.style.visibility="hidden",d.style.absolute="hidden",d.style.lineHeight="1",d.textContent=a,Object.keys(b).forEach(function(a){d.style[a]=b[a]}),document.body.appendChild(d),c=d.getBoundingClientRect(),document.body.removeChild(d),c.height}e.default.registerPlugin("measureText",g)}]).default})},CalcEngine:function(b,c){b.exports=a.Spread.CalcEngine},Common:function(b,c){b.exports=a.Spread},Core:function(b,c){b.exports=a.Spread.Sheets},Sparkline:function(b,c){b.exports=a.Spread.Sheets.Sparklines}})});