!function(e,n){if("object"==typeof exports&&"object"==typeof module)module.exports=n();else if("function"==typeof define&&define.amd)define([],n);else{var t=n();for(var i in t)("object"==typeof exports?exports:e)[i]=t[i]}}(self,(()=>(()=>{"use strict";var e={d:(n,t)=>{for(var i in t)e.o(t,i)&&!e.o(n,i)&&Object.defineProperty(n,i,{enumerable:!0,get:t[i]})},o:(e,n)=>Object.prototype.hasOwnProperty.call(e,n),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},n={};e.r(n),e.d(n,{ShortCrypt:()=>J});var t=null;try{t=new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch(e){}function i(e,n,t){this.low=0|e,this.high=0|n,this.unsigned=!!t}function r(e){return!0===(e&&e.__isLong__)}function o(e){var n=Math.clz32(e&-e);return e?31-n:n}i.prototype.__isLong__,Object.defineProperty(i.prototype,"__isLong__",{value:!0}),i.isLong=r;var s={},h={};function u(e,n){var t,i,r;return n?(r=0<=(e>>>=0)&&e<256)&&(i=h[e])?i:(t=w(e,0,!0),r&&(h[e]=t),t):(r=-128<=(e|=0)&&e<128)&&(i=s[e])?i:(t=w(e,e<0?-1:0,!1),r&&(s[e]=t),t)}function a(e,n){if(isNaN(e))return n?b:m;if(n){if(e<0)return b;if(e>=d)return S}else{if(e<=-y)return T;if(e+1>=y)return N}return e<0?a(-e,n).neg():w(e%l|0,e/l|0,n)}function w(e,n,t){return new i(e,n,t)}i.fromInt=u,i.fromNumber=a,i.fromBits=w;var f=Math.pow;function c(e,n,t){if(0===e.length)throw Error("empty string");if("number"==typeof n?(t=n,n=!1):n=!!n,"NaN"===e||"Infinity"===e||"+Infinity"===e||"-Infinity"===e)return n?b:m;if((t=t||10)<2||360)throw Error("interior hyphen");if(0===i)return c(e.substring(1),n,t).neg();for(var r=a(f(t,8)),o=m,s=0;s>>0:this.low},O.toNumber=function(){return this.unsigned?(this.high>>>0)*l+(this.low>>>0):this.high*l+(this.low>>>0)},O.toString=function(e){if((e=e||10)<2||36>>0).toString(e);if((o=h).isZero())return u+s;for(;u.length<6;)u="0"+u;s=""+u+s}},O.getHighBits=function(){return this.high},O.getHighBitsUnsigned=function(){return this.high>>>0},O.getLowBits=function(){return this.low},O.getLowBitsUnsigned=function(){return this.low>>>0},O.getNumBitsAbs=function(){if(this.isNegative())return this.eq(T)?64:this.neg().getNumBitsAbs();for(var e=0!=this.high?this.high:this.low,n=31;n>0&&!(e&1<=0},O.isOdd=function(){return!(1&~this.low)},O.isEven=function(){return!(1&this.low)},O.equals=function(e){return r(e)||(e=g(e)),(this.unsigned===e.unsigned||this.high>>>31!=1||e.high>>>31!=1)&&(this.high===e.high&&this.low===e.low)},O.eq=O.equals,O.notEquals=function(e){return!this.eq(e)},O.neq=O.notEquals,O.ne=O.notEquals,O.lessThan=function(e){return this.comp(e)<0},O.lt=O.lessThan,O.lessThanOrEqual=function(e){return this.comp(e)<=0},O.lte=O.lessThanOrEqual,O.le=O.lessThanOrEqual,O.greaterThan=function(e){return this.comp(e)>0},O.gt=O.greaterThan,O.greaterThanOrEqual=function(e){return this.comp(e)>=0},O.gte=O.greaterThanOrEqual,O.ge=O.greaterThanOrEqual,O.compare=function(e){if(r(e)||(e=g(e)),this.eq(e))return 0;var n=this.isNegative(),t=e.isNegative();return n&&!t?-1:!n&&t?1:this.unsigned?e.high>>>0>this.high>>>0||e.high===this.high&&e.low>>>0>this.low>>>0?-1:1:this.sub(e).isNegative()?-1:1},O.comp=O.compare,O.negate=function(){return!this.unsigned&&this.eq(T)?T:this.not().add(p)},O.neg=O.negate,O.add=function(e){r(e)||(e=g(e));var n=this.high>>>16,t=65535&this.high,i=this.low>>>16,o=65535&this.low,s=e.high>>>16,h=65535&e.high,u=e.low>>>16,a=0,f=0,c=0,l=0;return c+=(l+=o+(65535&e.low))>>>16,f+=(c+=i+u)>>>16,a+=(f+=t+h)>>>16,a+=n+s,w((c&=65535)<<16|(l&=65535),(a&=65535)<<16|(f&=65535),this.unsigned)},O.subtract=function(e){return r(e)||(e=g(e)),this.add(e.neg())},O.sub=O.subtract,O.multiply=function(e){if(this.isZero())return this;if(r(e)||(e=g(e)),t)return w(t.mul(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned);if(e.isZero())return this.unsigned?b:m;if(this.eq(T))return e.isOdd()?T:m;if(e.eq(T))return this.isOdd()?T:m;if(this.isNegative())return e.isNegative()?this.neg().mul(e.neg()):this.neg().mul(e).neg();if(e.isNegative())return this.mul(e.neg()).neg();if(this.lt(v)&&e.lt(v))return a(this.toNumber()*e.toNumber(),this.unsigned);var n=this.high>>>16,i=65535&this.high,o=this.low>>>16,s=65535&this.low,h=e.high>>>16,u=65535&e.high,f=e.low>>>16,c=65535&e.low,l=0,d=0,y=0,p=0;return y+=(p+=s*c)>>>16,d+=(y+=o*c)>>>16,y&=65535,d+=(y+=s*f)>>>16,l+=(d+=i*c)>>>16,d&=65535,l+=(d+=o*f)>>>16,d&=65535,l+=(d+=s*u)>>>16,l+=n*c+i*f+o*u+s*h,w((y&=65535)<<16|(p&=65535),(l&=65535)<<16|(d&=65535),this.unsigned)},O.mul=O.multiply,O.divide=function(e){if(r(e)||(e=g(e)),e.isZero())throw Error("division by zero");var n,i,o;if(t)return this.unsigned||-2147483648!==this.high||-1!==e.low||-1!==e.high?w((this.unsigned?t.div_u:t.div_s)(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned):this;if(this.isZero())return this.unsigned?b:m;if(this.unsigned){if(e.unsigned||(e=e.toUnsigned()),e.gt(this))return b;if(e.gt(this.shru(1)))return E;o=b}else{if(this.eq(T))return e.eq(p)||e.eq(A)?T:e.eq(T)?p:(n=this.shr(1).div(e).shl(1)).eq(m)?e.isNegative()?p:A:(i=this.sub(e.mul(n)),o=n.add(i.div(e)));if(e.eq(T))return this.unsigned?b:m;if(this.isNegative())return e.isNegative()?this.neg().div(e.neg()):this.neg().div(e).neg();if(e.isNegative())return this.div(e.neg()).neg();o=m}for(i=this;i.gte(e);){n=Math.max(1,Math.floor(i.toNumber()/e.toNumber()));for(var s=Math.ceil(Math.log(n)/Math.LN2),h=s<=48?1:f(2,s-48),u=a(n),c=u.mul(e);c.isNegative()||c.gt(i);)c=(u=a(n-=h,this.unsigned)).mul(e);u.isZero()&&(u=p),o=o.add(u),i=i.sub(c)}return o},O.div=O.divide,O.modulo=function(e){return r(e)||(e=g(e)),t?w((this.unsigned?t.rem_u:t.rem_s)(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned):this.sub(this.div(e).mul(e))},O.mod=O.modulo,O.rem=O.modulo,O.not=function(){return w(~this.low,~this.high,this.unsigned)},O.countLeadingZeros=function(){return this.high?Math.clz32(this.high):Math.clz32(this.low)+32},O.clz=O.countLeadingZeros,O.countTrailingZeros=function(){return this.low?o(this.low):o(this.high)+32},O.ctz=O.countTrailingZeros,O.and=function(e){return r(e)||(e=g(e)),w(this.low&e.low,this.high&e.high,this.unsigned)},O.or=function(e){return r(e)||(e=g(e)),w(this.low|e.low,this.high|e.high,this.unsigned)},O.xor=function(e){return r(e)||(e=g(e)),w(this.low^e.low,this.high^e.high,this.unsigned)},O.shiftLeft=function(e){return r(e)&&(e=e.toInt()),0==(e&=63)?this:e<32?w(this.low<>>32-e,this.unsigned):w(0,this.low<>>e|this.high<<32-e,this.high>>e,this.unsigned):w(this.high>>e-32,this.high>=0?0:-1,this.unsigned)},O.shr=O.shiftRight,O.shiftRightUnsigned=function(e){return r(e)&&(e=e.toInt()),0==(e&=63)?this:e<32?w(this.low>>>e|this.high<<32-e,this.high>>>e,this.unsigned):w(32===e?this.high:this.high>>>e-32,0,this.unsigned)},O.shru=O.shiftRightUnsigned,O.shr_u=O.shiftRightUnsigned,O.rotateLeft=function(e){var n;return r(e)&&(e=e.toInt()),0==(e&=63)?this:32===e?w(this.high,this.low,this.unsigned):e<32?(n=32-e,w(this.low<>>n,this.high<>>n,this.unsigned)):(n=32-(e-=32),w(this.high<>>n,this.low<>>n,this.unsigned))},O.rotl=O.rotateLeft,O.rotateRight=function(e){var n;return r(e)&&(e=e.toInt()),0==(e&=63)?this:32===e?w(this.high,this.low,this.unsigned):e<32?(n=32-e,w(this.high<>>e,this.low<>>e,this.unsigned)):(n=32-(e-=32),w(this.low<>>e,this.high<>>e,this.unsigned))},O.rotr=O.rotateRight,O.toSigned=function(){return this.unsigned?w(this.low,this.high,!1):this},O.toUnsigned=function(){return this.unsigned?this:w(this.low,this.high,!0)},O.toBytes=function(e){return e?this.toBytesLE():this.toBytesBE()},O.toBytesLE=function(){var e=this.high,n=this.low;return[255&n,n>>>8&255,n>>>16&255,n>>>24,255&e,e>>>8&255,e>>>16&255,e>>>24]},O.toBytesBE=function(){var e=this.high,n=this.low;return[e>>>24,e>>>16&255,e>>>8&255,255&e,n>>>24,n>>>16&255,n>>>8&255,255&n]},i.fromBytes=function(e,n,t){return t?i.fromBytesLE(e,n):i.fromBytesBE(e,n)},i.fromBytesLE=function(e,n){return new i(e[0]|e[1]<<8|e[2]<<16|e[3]<<24,e[4]|e[5]<<8|e[6]<<16|e[7]<<24,n)},i.fromBytesBE=function(e,n){return new i(e[4]<<24|e[5]<<16|e[6]<<8|e[7],e[0]<<24|e[1]<<16|e[2]<<8|e[3],n)};const C=i;function B(e,n,t){var i;if(void 0===t&&(t={}),!n.codes){n.codes={};for(var r=0;r=8&&(h-=8,s[a++]=255&u>>h)}if(h>=n.bits||255&u<<8-h)throw new SyntaxError("Unexpected end of data");return s}function L(e,n,t){void 0===t&&(t={});for(var i=t.pad,r=void 0===i||i,o=(1<n.bits;)h-=n.bits,s+=n.chars[o&u>>h];if(h&&(s+=n.chars[o&u<e.length)&&(n=e.length);for(var t=0,i=Array(n);t31)return!1;var r=n,o=r.length,s=new Uint8Array(o),h=t,u=C.fromNumber(t,!0);r.forEach((function(e){h^=e,u=u.add(C.fromNumber(e,!0))}));var a=new M;a.digest(new Uint8Array([h].concat(Q(u.toBytesBE()))));for(var w=a.getByteArray(),f=[],c=0;c=10&&n<36?n-10+"A".charCodeAt(0):n>=36&&n<62?n-36+"a".charCodeAt(0):62===n?"-".charCodeAt(0):"_".charCodeAt(0),r=t.body,o=String.fromCharCode(i),s=j(r,{pad:!1}),h=(new TextEncoder).encode(s),u=h.length,a=C.fromNumber(i);h.forEach((function(e){a=a.add(C.fromNumber(e,!0))}));var w=this.keySumRev.xor(a).mod(u+1).toNumber();return s.substring(0,w)+o+s.substring(w,u)}},{key:"decryptURLComponent",value:function(e){var n=(new TextEncoder).encode(e),t=n.length;if(t<1)return!1;var i=C.UZERO;n.forEach((function(e){i=i.add(C.fromNumber(e,!0))}));var r,o=this.keySumRev.xor(i).mod(t).toNumber(),s=(r=n[o])>="0".charCodeAt(0)&&r<="9".charCodeAt(0)?r-"0".charCodeAt(0):r>="A".charCodeAt(0)&&r<="Z".charCodeAt(0)?r+10-"A".charCodeAt(0):r>="a".charCodeAt(0)&&r<="z".charCodeAt(0)?r+36-"a".charCodeAt(0):r==="-".charCodeAt(0)?62:63;if(s<0||s>31)return!1;var h=e.slice(0,o)+e.slice(o+1,t);try{var u=q(h,{out:Uint8Array,loose:!0});return this.decrypt(s,u)}catch(e){return!1}}},{key:"encryptToQRCodeAlphanumeric",value:function(e){"string"==typeof e&&(e=(new TextEncoder).encode(e));var n,t=this.encrypt(e),i=(n=t.base)<10?n+"0".charCodeAt(0):n-10+"A".charCodeAt(0),r=t.body,o=String.fromCharCode(i),s=_(r,{pad:!1}),h=(new TextEncoder).encode(s),u=h.length,a=C.fromNumber(i,!0);h.forEach((function(e){a=a.add(C.fromNumber(e,!0))}));var w=this.keySumRev.xor(a).mod(u+1).toNumber();return s.substring(0,w)+o+s.substring(w,u)}},{key:"decryptQRCodeAlphanumeric",value:function(e){var n=(new TextEncoder).encode(e),t=n.length;if(t<1)return!1;var i=C.UZERO;n.forEach((function(e){i=i.add(C.fromNumber(e,!0))}));var r,o=this.keySumRev.xor(i).mod(t).toNumber(),s=(r=n[o])>="0".charCodeAt(0)&&r<="9".charCodeAt(0)?r-"0".charCodeAt(0):r+10-"A".charCodeAt(0);if(s<0||s>31)return!1;var h=e.slice(0,o)+e.slice(o+1,t);try{var u=U(h,{out:Uint8Array,loose:!0});return this.decrypt(s,u)}catch(e){return!1}}}],n&&D(e.prototype,n),t&&D(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n,t}();return n})()));