var QRCode=function(t){"use strict";function R(){return void 0!==a}var a,O=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706],Q=function(t){if(!t)throw new Error('"version" cannot be null or undefined');if(t<1||40>>=1;return e};function e(t,e){return t(e={exports:{}},e.exports),e.exports}var g=e(function(t,n){n.L={bit:1},n.M={bit:0},n.Q={bit:3},n.H={bit:2},n.isValid=function(t){return t&&void 0!==t.bit&&0<=t.bit&&t.bit<4},n.from=function(t,e){if(n.isValid(t))return t;try{var r=t;if("string"!=typeof r)throw new Error("Param is not a string");switch(r.toLowerCase()){case"l":case"low":return n.L;case"m":case"medium":return n.M;case"q":case"quartile":return n.Q;case"h":case"high":return n.H;default:throw new Error("Unknown EC Level: "+r)}return}catch(t){return e}}});function T(){this.buffer=[],this.length=0}g.L,g.M,g.Q,g.H,g.isValid,T.prototype={get:function(t){var e=Math.floor(t/8);return 1==(this.buffer[e]>>>7-t%8&1)},put:function(t,e){for(var r=0;r>>e-r-1&1))},getLengthInBits:function(){return this.length},putBit:function(t){var e=Math.floor(this.length/8);this.buffer.length<=e&&this.buffer.push(0),t&&(this.buffer[e]|=128>>>this.length%8),this.length++}};var W=T;function r(t){if(!t||t<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=t,this.data=new Uint8Array(t*t),this.reservedBit=new Uint8Array(t*t)}r.prototype.set=function(t,e,r,n){t=t*this.size+e;this.data[t]=r,n&&(this.reservedBit[t]=!0)},r.prototype.get=function(t,e){return this.data[t*this.size+e]},r.prototype.xor=function(t,e,r){this.data[t*this.size+e]^=r},r.prototype.isReserved=function(t,e){return this.reservedBit[t*this.size+e]};for(var G=r,V=e(function(t,i){var a=Q;i.getRowColCoords=function(t){if(1===t)return[];for(var e=Math.floor(t/7)+2,t=a(t),r=145===t?26:2*Math.ceil((t-13)/(2*e-2)),n=[t-7],o=1;o>6|192),e.push(63&a|128)):a<55296||57344<=a&&a<65536?(e.push(a>>12|224),e.push(a>>6&63|128),e.push(63&a|128)):65536<=a&&a<=1114111?(e.push(a>>18|240),e.push(a>>12&63|128),e.push(a>>6&63|128),e.push(63&a|128)):e.push(239,191,189)}return new Uint8Array(e).buffer}(t)),this.data=new Uint8Array(t)}N.getBitsLength=function(t){return 8*t},N.prototype.getLength=function(){return this.data.length},N.prototype.getBitsLength=function(){return N.getBitsLength(this.data.length)},N.prototype.write=function(t){for(var e=0,r=this.data.length;e>>8&255)+(255&r),13)}};var H=B,J=e(function(t){var d={single_source_shortest_paths:function(t,e,r){var n={},o={};o[e]=0;var a,i,u,s,h,f,c,g=d.PriorityQueue.make();for(g.push(e,0);!g.empty();)for(u in i=(a=g.pop()).value,s=a.cost,h=t[i]||{})h.hasOwnProperty(u)&&(f=s+h[u],c=o[u],(void 0===o[u]||f>i&1),i<6?t.set(i,8,n,!0):i<8?t.set(i+1,8,n,!0):t.set(o-15+i,8,n,!0),i<8?t.set(8,o-i-1,n,!0):i<9?t.set(8,15-i-1+1,n,!0):t.set(8,15-i-1,n,!0);t.set(o-8,8,1,!0)}function K(t,e,r,n){var o;if(Array.isArray(t))o=Z.fromArray(t);else{if("string"!=typeof t)throw new Error("Invalid data");var a=e;a||(i=Z.rawSplit(t),a=X.getBestVersionForData(i,r)),o=Z.fromString(t,a||40)}var i=X.getBestVersionForData(o,r);if(!i)throw new Error("The amount of data is too big to be stored in a QR Code");if(e){if(e>C&1),!0),N.set(_,B,z,!0)}for(var P=i,K=t,R=P.size,T=-1,L=R-1,b=7,U=0,x=R-1;0>>b&1)),P.set(L,x-F,k),-1==--b&&(U++,b=7));if((L+=T)<0||R<=L){L-=T,T=-T;break}}return isNaN(n)&&(n=q.getBestMask(i,nt.bind(null,i,r))),q.applyMask(n,i),nt(i,r,n),{modules:i,version:e,errorCorrectionLevel:r,maskPattern:n,segments:o}}Z.fromArray,Z.fromString,Z.rawSplit;function ot(t,e){if(void 0===t||""===t)throw new Error("No input text");var r,n,o=g.M;if(void 0!==e&&(o=g.from(e.errorCorrectionLevel,g.M),r=X.from(e.version),n=q.from(e.maskPattern),e.toSJISFunc)){if("function"!=typeof(e=e.toSJISFunc))throw new Error('"toSJISFunc" is not a valid function.');a=e}return K(t,r,o,n)}var C=e(function(t,d){function o(t){if("string"!=typeof(t="number"==typeof t?t.toString():t))throw new Error("Color should be defined as hex string");var e=t.slice().replace("#","").split("");if(e.length<3||5===e.length||8>24&255,g:t>>16&255,b:t>>8&255,a:255&t,hex:"#"+e.slice(0,6).join("")}}d.getOptions=function(t){(t=t||{}).color||(t.color={});var e=void 0===t.margin||null===t.margin||t.margin<0?4:t.margin,r=t.width&&21<=t.width?t.width:void 0,n=t.scale||4;return{width:r,scale:r?4:n,margin:e,color:{dark:o(t.color.dark||"#000000ff"),light:o(t.color.light||"#ffffffff")},type:t.type,rendererOpts:t.rendererOpts||{}}},d.getScale=function(t,e){return e.width&&e.width>=t+2*e.margin?e.width/(t+2*e.margin):e.scale},d.getImageWidth=function(t,e){var r=d.getScale(t,e);return Math.floor((t+2*e.margin)*r)},d.qrToImageData=function(t,e,r){for(var n=e.modules.size,o=e.modules.data,a=d.getScale(n,r),i=Math.floor((n+2*r.margin)*a),u=r.margin*a,s=[r.color.light,r.color.dark],h=0;h':"",t="',o=''+i+t+"\n","function"==typeof n&&n(null,o),o;var n,o,a,i}),y={create:w,toCanvas:m,toDataURL:v,toString:E};return t.create=w,t.default=y,t.toCanvas=m,t.toDataURL=v,t.toString=E,Object.defineProperty(t,"__esModule",{value:!0}),t}({});