js-dos 7.3.6 → 7.3.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/js-dos.js CHANGED
@@ -1,4 +1,4 @@
1
- !function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(i)return i(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i="function"==typeof require&&require,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(e,t,n){"use strict";var r=e("./utils");function o(){var e={},t=0,n=0,r=0;return{add:function(o,i){i||(i=o,o=0),o>n?n=o:o<r&&(r=o),e[o]||(e[o]=[]),e[o].push(i),t++},process:function(){for(var t=r;t<=n;t++)for(var o=e[t],i=0;i<o.length;i++)(0,o[i])()},size:function(){return t}}}t.exports=function(e){var t=(e=e||{}).reporter,n=r.getOption(e,"async",!0),i=r.getOption(e,"auto",!0);i&&!n&&(t&&t.warn("Invalid options combination. auto=true and async=false is invalid. Setting async=true."),n=!0);var s,a=o(),l=!1;function c(){for(l=!0;a.size();){var e=a;a=o(),e.process()}l=!1}function u(){s=setTimeout(c,0)}return{add:function(e,t){!l&&i&&n&&0===a.size()&&u(),a.add(e,t)},force:function(e){l||(void 0===e&&(e=n),s&&(clearTimeout(s),s=null),e?u():c())}}}},{"./utils":2}],2:[function(e,t,n){"use strict";(t.exports={}).getOption=function(e,t,n){var r=e[t];return null==r&&void 0!==n?n:r}},{}],3:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/try-to-string"),s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not a function")}},{"../internals/global":48,"../internals/is-callable":60,"../internals/try-to-string":106}],4:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-constructor"),i=e("../internals/try-to-string"),s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not a constructor")}},{"../internals/global":48,"../internals/is-constructor":61,"../internals/try-to-string":106}],5:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=r.String,s=r.TypeError;t.exports=function(e){if("object"==typeof e||o(e))return e;throw s("Can't set "+i(e)+" as a prototype")}},{"../internals/global":48,"../internals/is-callable":60}],6:[function(e,t,n){var r=e("../internals/well-known-symbol"),o=e("../internals/object-create"),i=e("../internals/object-define-property"),s=r("unscopables"),a=Array.prototype;null==a[s]&&i.f(a,s,{configurable:!0,value:o(null)}),t.exports=function(e){a[s][e]=!0}},{"../internals/object-create":72,"../internals/object-define-property":74,"../internals/well-known-symbol":112}],7:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/object-is-prototype-of"),i=r.TypeError;t.exports=function(e,t){if(o(t,e))return e;throw i("Incorrect invocation")}},{"../internals/global":48,"../internals/object-is-prototype-of":79}],8:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-object"),i=r.String,s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not an object")}},{"../internals/global":48,"../internals/is-object":64}],9:[function(e,t,n){t.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},{}],10:[function(e,t,n){"use strict";var r,o,i,s=e("../internals/array-buffer-native"),a=e("../internals/descriptors"),l=e("../internals/global"),c=e("../internals/is-callable"),u=e("../internals/is-object"),d=e("../internals/has-own-property"),f=e("../internals/classof"),p=e("../internals/try-to-string"),h=e("../internals/create-non-enumerable-property"),m=e("../internals/redefine"),y=e("../internals/object-define-property").f,v=e("../internals/object-is-prototype-of"),g=e("../internals/object-get-prototype-of"),b=e("../internals/object-set-prototype-of"),_=e("../internals/well-known-symbol"),w=e("../internals/uid"),x=l.Int8Array,k=x&&x.prototype,j=l.Uint8ClampedArray,C=j&&j.prototype,D=x&&g(x),E=k&&g(k),S=Object.prototype,O=l.TypeError,P=_("toStringTag"),B=w("TYPED_ARRAY_TAG"),M=w("TYPED_ARRAY_CONSTRUCTOR"),T=s&&!!b&&"Opera"!==f(l.opera),A=!1,I={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},K={BigInt64Array:8,BigUint64Array:8},L=function(e){if(!u(e))return!1;var t=f(e);return d(I,t)||d(K,t)};for(r in I)(i=(o=l[r])&&o.prototype)?h(i,M,o):T=!1;for(r in K)(i=(o=l[r])&&o.prototype)&&h(i,M,o);if((!T||!c(D)||D===Function.prototype)&&(D=function(){throw O("Incorrect invocation")},T))for(r in I)l[r]&&b(l[r],D);if((!T||!E||E===S)&&(E=D.prototype,T))for(r in I)l[r]&&b(l[r].prototype,E);if(T&&g(C)!==E&&b(C,E),a&&!d(E,P))for(r in A=!0,y(E,P,{get:function(){return u(this)?this[B]:void 0}}),I)l[r]&&h(l[r],B,r);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:T,TYPED_ARRAY_CONSTRUCTOR:M,TYPED_ARRAY_TAG:A&&B,aTypedArray:function(e){if(L(e))return e;throw O("Target is not a typed array")},aTypedArrayConstructor:function(e){if(c(e)&&(!b||v(D,e)))return e;throw O(p(e)+" is not a typed array constructor")},exportTypedArrayMethod:function(e,t,n){if(a){if(n)for(var r in I){var o=l[r];if(o&&d(o.prototype,e))try{delete o.prototype[e]}catch(e){}}E[e]&&!n||m(E,e,n?t:T&&k[e]||t)}},exportTypedArrayStaticMethod:function(e,t,n){var r,o;if(a){if(b){if(n)for(r in I)if((o=l[r])&&d(o,e))try{delete o[e]}catch(e){}if(D[e]&&!n)return;try{return m(D,e,n?t:T&&D[e]||t)}catch(e){}}for(r in I)!(o=l[r])||o[e]&&!n||m(o,e,t)}},isView:function(e){if(!u(e))return!1;var t=f(e);return"DataView"===t||d(I,t)||d(K,t)},isTypedArray:L,TypedArray:D,TypedArrayPrototype:E}},{"../internals/array-buffer-native":9,"../internals/classof":21,"../internals/create-non-enumerable-property":25,"../internals/descriptors":28,"../internals/global":48,"../internals/has-own-property":49,"../internals/is-callable":60,"../internals/is-object":64,"../internals/object-define-property":74,"../internals/object-get-prototype-of":78,"../internals/object-is-prototype-of":79,"../internals/object-set-prototype-of":83,"../internals/redefine":87,"../internals/try-to-string":106,"../internals/uid":110,"../internals/well-known-symbol":112}],11:[function(e,t,n){"use strict";var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=e("../internals/descriptors"),s=e("../internals/array-buffer-native"),a=e("../internals/function-name"),l=e("../internals/create-non-enumerable-property"),c=e("../internals/redefine-all"),u=e("../internals/fails"),d=e("../internals/an-instance"),f=e("../internals/to-integer-or-infinity"),p=e("../internals/to-length"),h=e("../internals/to-index"),m=e("../internals/ieee754"),y=e("../internals/object-get-prototype-of"),v=e("../internals/object-set-prototype-of"),g=e("../internals/object-get-own-property-names").f,b=e("../internals/object-define-property").f,_=e("../internals/array-fill"),w=e("../internals/array-slice"),x=e("../internals/set-to-string-tag"),k=e("../internals/internal-state"),j=a.PROPER,C=a.CONFIGURABLE,D=k.get,E=k.set,S="ArrayBuffer",O="Wrong index",P=r.ArrayBuffer,B=P,M=B&&B.prototype,T=r.DataView,A=T&&T.prototype,I=Object.prototype,K=r.Array,L=r.RangeError,R=o(_),N=o([].reverse),F=m.pack,U=m.unpack,z=function(e){return[255&e]},H=function(e){return[255&e,e>>8&255]},W=function(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]},q=function(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]},V=function(e){return F(e,23,4)},G=function(e){return F(e,52,8)},Y=function(e,t){b(e.prototype,t,{get:function(){return D(this)[t]}})},X=function(e,t,n,r){var o=h(n),i=D(e);if(o+t>i.byteLength)throw L(O);var s=D(i.buffer).bytes,a=o+i.byteOffset,l=w(s,a,a+t);return r?l:N(l)},$=function(e,t,n,r,o,i){var s=h(n),a=D(e);if(s+t>a.byteLength)throw L(O);for(var l=D(a.buffer).bytes,c=s+a.byteOffset,u=r(+o),d=0;d<t;d++)l[c+d]=u[i?d:t-d-1]};if(s){var J=j&&P.name!==S;if(u((function(){P(1)}))&&u((function(){new P(-1)}))&&!u((function(){return new P,new P(1.5),new P(NaN),J&&!C})))J&&C&&l(P,"name",S);else{(B=function(e){return d(this,M),new P(h(e))}).prototype=M;for(var Q,Z=g(P),ee=0;Z.length>ee;)(Q=Z[ee++])in B||l(B,Q,P[Q]);M.constructor=B}v&&y(A)!==I&&v(A,I);var te=new T(new B(2)),ne=o(A.setInt8);te.setInt8(0,2147483648),te.setInt8(1,2147483649),!te.getInt8(0)&&te.getInt8(1)||c(A,{setInt8:function(e,t){ne(this,e,t<<24>>24)},setUint8:function(e,t){ne(this,e,t<<24>>24)}},{unsafe:!0})}else M=(B=function(e){d(this,M);var t=h(e);E(this,{bytes:R(K(t),0),byteLength:t}),i||(this.byteLength=t)}).prototype,A=(T=function(e,t,n){d(this,A),d(e,M);var r=D(e).byteLength,o=f(t);if(o<0||o>r)throw L("Wrong offset");if(o+(n=void 0===n?r-o:p(n))>r)throw L("Wrong length");E(this,{buffer:e,byteLength:n,byteOffset:o}),i||(this.buffer=e,this.byteLength=n,this.byteOffset=o)}).prototype,i&&(Y(B,"byteLength"),Y(T,"buffer"),Y(T,"byteLength"),Y(T,"byteOffset")),c(A,{getInt8:function(e){return X(this,1,e)[0]<<24>>24},getUint8:function(e){return X(this,1,e)[0]},getInt16:function(e){var t=X(this,2,e,arguments.length>1?arguments[1]:void 0);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=X(this,2,e,arguments.length>1?arguments[1]:void 0);return t[1]<<8|t[0]},getInt32:function(e){return q(X(this,4,e,arguments.length>1?arguments[1]:void 0))},getUint32:function(e){return q(X(this,4,e,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(e){return U(X(this,4,e,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(e){return U(X(this,8,e,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(e,t){$(this,1,e,z,t)},setUint8:function(e,t){$(this,1,e,z,t)},setInt16:function(e,t){$(this,2,e,H,t,arguments.length>2?arguments[2]:void 0)},setUint16:function(e,t){$(this,2,e,H,t,arguments.length>2?arguments[2]:void 0)},setInt32:function(e,t){$(this,4,e,W,t,arguments.length>2?arguments[2]:void 0)},setUint32:function(e,t){$(this,4,e,W,t,arguments.length>2?arguments[2]:void 0)},setFloat32:function(e,t){$(this,4,e,V,t,arguments.length>2?arguments[2]:void 0)},setFloat64:function(e,t){$(this,8,e,G,t,arguments.length>2?arguments[2]:void 0)}});x(B,S),x(T,"DataView"),t.exports={ArrayBuffer:B,DataView:T}},{"../internals/an-instance":7,"../internals/array-buffer-native":9,"../internals/array-fill":12,"../internals/array-slice":15,"../internals/create-non-enumerable-property":25,"../internals/descriptors":28,"../internals/fails":39,"../internals/function-name":42,"../internals/function-uncurry-this":43,"../internals/global":48,"../internals/ieee754":53,"../internals/internal-state":57,"../internals/object-define-property":74,"../internals/object-get-own-property-names":76,"../internals/object-get-prototype-of":78,"../internals/object-set-prototype-of":83,"../internals/redefine-all":86,"../internals/set-to-string-tag":91,"../internals/to-index":96,"../internals/to-integer-or-infinity":98,"../internals/to-length":99}],12:[function(e,t,n){"use strict";var r=e("../internals/to-object"),o=e("../internals/to-absolute-index"),i=e("../internals/length-of-array-like");t.exports=function(e){for(var t=r(this),n=i(t),s=arguments.length,a=o(s>1?arguments[1]:void 0,n),l=s>2?arguments[2]:void 0,c=void 0===l?n:o(l,n);c>a;)t[a++]=e;return t}},{"../internals/length-of-array-like":69,"../internals/to-absolute-index":95,"../internals/to-object":100}],13:[function(e,t,n){var r=e("../internals/to-indexed-object"),o=e("../internals/to-absolute-index"),i=e("../internals/length-of-array-like"),s=function(e){return function(t,n,s){var a,l=r(t),c=i(l),u=o(s,c);if(e&&n!=n){for(;c>u;)if((a=l[u++])!=a)return!0}else for(;c>u;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},{"../internals/length-of-array-like":69,"../internals/to-absolute-index":95,"../internals/to-indexed-object":97}],14:[function(e,t,n){var r=e("../internals/function-bind-context"),o=e("../internals/function-uncurry-this"),i=e("../internals/indexed-object"),s=e("../internals/to-object"),a=e("../internals/length-of-array-like"),l=e("../internals/array-species-create"),c=o([].push),u=function(e){var t=1==e,n=2==e,o=3==e,u=4==e,d=6==e,f=7==e,p=5==e||d;return function(h,m,y,v){for(var g,b,_=s(h),w=i(_),x=r(m,y),k=a(w),j=0,C=v||l,D=t?C(h,k):n||f?C(h,0):void 0;k>j;j++)if((p||j in w)&&(b=x(g=w[j],j,_),e))if(t)D[j]=b;else if(b)switch(e){case 3:return!0;case 5:return g;case 6:return j;case 2:c(D,g)}else switch(e){case 4:return!1;case 7:c(D,g)}return d?-1:o||u?u:D}};t.exports={forEach:u(0),map:u(1),filter:u(2),some:u(3),every:u(4),find:u(5),findIndex:u(6),filterReject:u(7)}},{"../internals/array-species-create":18,"../internals/function-bind-context":40,"../internals/function-uncurry-this":43,"../internals/indexed-object":54,"../internals/length-of-array-like":69,"../internals/to-object":100}],15:[function(e,t,n){var r=e("../internals/function-uncurry-this");t.exports=r([].slice)},{"../internals/function-uncurry-this":43}],16:[function(e,t,n){var r=e("../internals/array-slice"),o=Math.floor,i=function(e,t){var n=e.length,l=o(n/2);return n<8?s(e,t):a(e,i(r(e,0,l),t),i(r(e,l),t),t)},s=function(e,t){for(var n,r,o=e.length,i=1;i<o;){for(r=i,n=e[i];r&&t(e[r-1],n)>0;)e[r]=e[--r];r!==i++&&(e[r]=n)}return e},a=function(e,t,n,r){for(var o=t.length,i=n.length,s=0,a=0;s<o||a<i;)e[s+a]=s<o&&a<i?r(t[s],n[a])<=0?t[s++]:n[a++]:s<o?t[s++]:n[a++];return e};t.exports=i},{"../internals/array-slice":15}],17:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-array"),i=e("../internals/is-constructor"),s=e("../internals/is-object"),a=e("../internals/well-known-symbol")("species"),l=r.Array;t.exports=function(e){var t;return o(e)&&(t=e.constructor,(i(t)&&(t===l||o(t.prototype))||s(t)&&null===(t=t[a]))&&(t=void 0)),void 0===t?l:t}},{"../internals/global":48,"../internals/is-array":59,"../internals/is-constructor":61,"../internals/is-object":64,"../internals/well-known-symbol":112}],18:[function(e,t,n){var r=e("../internals/array-species-constructor");t.exports=function(e,t){return new(r(e))(0===t?0:t)}},{"../internals/array-species-constructor":17}],19:[function(e,t,n){var r=e("../internals/well-known-symbol")("iterator"),o=!1;try{var i=0,s={next:function(){return{done:!!i++}},return:function(){o=!0}};s[r]=function(){return this},Array.from(s,(function(){throw 2}))}catch(e){}t.exports=function(e,t){if(!t&&!o)return!1;var n=!1;try{var i={};i[r]=function(){return{next:function(){return{done:n=!0}}}},e(i)}catch(e){}return n}},{"../internals/well-known-symbol":112}],20:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=r({}.toString),i=r("".slice);t.exports=function(e){return i(o(e),8,-1)}},{"../internals/function-uncurry-this":43}],21:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-string-tag-support"),i=e("../internals/is-callable"),s=e("../internals/classof-raw"),a=e("../internals/well-known-symbol")("toStringTag"),l=r.Object,c="Arguments"==s(function(){return arguments}());t.exports=o?s:function(e){var t,n,r;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=l(e),a))?n:c?s(t):"Object"==(r=s(t))&&i(t.callee)?"Arguments":r}},{"../internals/classof-raw":20,"../internals/global":48,"../internals/is-callable":60,"../internals/to-string-tag-support":105,"../internals/well-known-symbol":112}],22:[function(e,t,n){var r=e("../internals/has-own-property"),o=e("../internals/own-keys"),i=e("../internals/object-get-own-property-descriptor"),s=e("../internals/object-define-property");t.exports=function(e,t){for(var n=o(t),a=s.f,l=i.f,c=0;c<n.length;c++){var u=n[c];r(e,u)||a(e,u,l(t,u))}}},{"../internals/has-own-property":49,"../internals/object-define-property":74,"../internals/object-get-own-property-descriptor":75,"../internals/own-keys":85}],23:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},{"../internals/fails":39}],24:[function(e,t,n){"use strict";var r=e("../internals/iterators-core").IteratorPrototype,o=e("../internals/object-create"),i=e("../internals/create-property-descriptor"),s=e("../internals/set-to-string-tag"),a=e("../internals/iterators"),l=function(){return this};t.exports=function(e,t,n){var c=t+" Iterator";return e.prototype=o(r,{next:i(1,n)}),s(e,c,!1,!0),a[c]=l,e}},{"../internals/create-property-descriptor":26,"../internals/iterators":68,"../internals/iterators-core":67,"../internals/object-create":72,"../internals/set-to-string-tag":91}],25:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/object-define-property"),i=e("../internals/create-property-descriptor");t.exports=r?function(e,t,n){return o.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},{"../internals/create-property-descriptor":26,"../internals/descriptors":28,"../internals/object-define-property":74}],26:[function(e,t,n){t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},{}],27:[function(e,t,n){"use strict";var r=e("../internals/export"),o=e("../internals/function-call"),i=e("../internals/is-pure"),s=e("../internals/function-name"),a=e("../internals/is-callable"),l=e("../internals/create-iterator-constructor"),c=e("../internals/object-get-prototype-of"),u=e("../internals/object-set-prototype-of"),d=e("../internals/set-to-string-tag"),f=e("../internals/create-non-enumerable-property"),p=e("../internals/redefine"),h=e("../internals/well-known-symbol"),m=e("../internals/iterators"),y=e("../internals/iterators-core"),v=s.PROPER,g=s.CONFIGURABLE,b=y.IteratorPrototype,_=y.BUGGY_SAFARI_ITERATORS,w=h("iterator"),x="keys",k="values",j="entries",C=function(){return this};t.exports=function(e,t,n,s,h,y,D){l(n,t,s);var E,S,O,P=function(e){if(e===h&&I)return I;if(!_&&e in T)return T[e];switch(e){case x:case k:case j:return function(){return new n(this,e)}}return function(){return new n(this)}},B=t+" Iterator",M=!1,T=e.prototype,A=T[w]||T["@@iterator"]||h&&T[h],I=!_&&A||P(h),K="Array"==t&&T.entries||A;if(K&&(E=c(K.call(new e)))!==Object.prototype&&E.next&&(i||c(E)===b||(u?u(E,b):a(E[w])||p(E,w,C)),d(E,B,!0,!0),i&&(m[B]=C)),v&&h==k&&A&&A.name!==k&&(!i&&g?f(T,"name",k):(M=!0,I=function(){return o(A,this)})),h)if(S={values:P(k),keys:y?I:P(x),entries:P(j)},D)for(O in S)(_||M||!(O in T))&&p(T,O,S[O]);else r({target:t,proto:!0,forced:_||M},S);return i&&!D||T[w]===I||p(T,w,I,{name:h}),m[t]=I,S}},{"../internals/create-iterator-constructor":24,"../internals/create-non-enumerable-property":25,"../internals/export":38,"../internals/function-call":41,"../internals/function-name":42,"../internals/is-callable":60,"../internals/is-pure":65,"../internals/iterators":68,"../internals/iterators-core":67,"../internals/object-get-prototype-of":78,"../internals/object-set-prototype-of":83,"../internals/redefine":87,"../internals/set-to-string-tag":91,"../internals/well-known-symbol":112}],28:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},{"../internals/fails":39}],29:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-object"),i=r.document,s=o(i)&&o(i.createElement);t.exports=function(e){return s?i.createElement(e):{}}},{"../internals/global":48,"../internals/is-object":64}],30:[function(e,t,n){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},{}],31:[function(e,t,n){var r=e("../internals/document-create-element")("span").classList,o=r&&r.constructor&&r.constructor.prototype;t.exports=o===Object.prototype?void 0:o},{"../internals/document-create-element":29}],32:[function(e,t,n){var r=e("../internals/engine-user-agent").match(/firefox\/(\d+)/i);t.exports=!!r&&+r[1]},{"../internals/engine-user-agent":34}],33:[function(e,t,n){var r=e("../internals/engine-user-agent");t.exports=/MSIE|Trident/.test(r)},{"../internals/engine-user-agent":34}],34:[function(e,t,n){var r=e("../internals/get-built-in");t.exports=r("navigator","userAgent")||""},{"../internals/get-built-in":44}],35:[function(e,t,n){var r,o,i=e("../internals/global"),s=e("../internals/engine-user-agent"),a=i.process,l=i.Deno,c=a&&a.versions||l&&l.version,u=c&&c.v8;u&&(o=(r=u.split("."))[0]>0&&r[0]<4?1:+(r[0]+r[1])),!o&&s&&(!(r=s.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/))&&(o=+r[1]),t.exports=o},{"../internals/engine-user-agent":34,"../internals/global":48}],36:[function(e,t,n){var r=e("../internals/engine-user-agent").match(/AppleWebKit\/(\d+)\./);t.exports=!!r&&+r[1]},{"../internals/engine-user-agent":34}],37:[function(e,t,n){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},{}],38:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/object-get-own-property-descriptor").f,i=e("../internals/create-non-enumerable-property"),s=e("../internals/redefine"),a=e("../internals/set-global"),l=e("../internals/copy-constructor-properties"),c=e("../internals/is-forced");t.exports=function(e,t){var n,u,d,f,p,h=e.target,m=e.global,y=e.stat;if(n=m?r:y?r[h]||a(h,{}):(r[h]||{}).prototype)for(u in t){if(f=t[u],d=e.noTargetGet?(p=o(n,u))&&p.value:n[u],!c(m?u:h+(y?".":"#")+u,e.forced)&&void 0!==d){if(typeof f==typeof d)continue;l(f,d)}(e.sham||d&&d.sham)&&i(f,"sham",!0),s(n,u,f,e)}}},{"../internals/copy-constructor-properties":22,"../internals/create-non-enumerable-property":25,"../internals/global":48,"../internals/is-forced":62,"../internals/object-get-own-property-descriptor":75,"../internals/redefine":87,"../internals/set-global":89}],39:[function(e,t,n){t.exports=function(e){try{return!!e()}catch(e){return!0}}},{}],40:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/a-callable"),i=r(r.bind);t.exports=function(e,t){return o(e),void 0===t?e:i?i(e,t):function(){return e.apply(t,arguments)}}},{"../internals/a-callable":3,"../internals/function-uncurry-this":43}],41:[function(e,t,n){var r=Function.prototype.call;t.exports=r.bind?r.bind(r):function(){return r.apply(r,arguments)}},{}],42:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/has-own-property"),i=Function.prototype,s=r&&Object.getOwnPropertyDescriptor,a=o(i,"name"),l=a&&"something"===function(){}.name,c=a&&(!r||r&&s(i,"name").configurable);t.exports={EXISTS:a,PROPER:l,CONFIGURABLE:c}},{"../internals/descriptors":28,"../internals/has-own-property":49}],43:[function(e,t,n){var r=Function.prototype,o=r.bind,i=r.call,s=o&&o.bind(i);t.exports=o?function(e){return e&&s(i,e)}:function(e){return e&&function(){return i.apply(e,arguments)}}},{}],44:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=function(e){return o(e)?e:void 0};t.exports=function(e,t){return arguments.length<2?i(r[e]):r[e]&&r[e][t]}},{"../internals/global":48,"../internals/is-callable":60}],45:[function(e,t,n){var r=e("../internals/classof"),o=e("../internals/get-method"),i=e("../internals/iterators"),s=e("../internals/well-known-symbol")("iterator");t.exports=function(e){if(null!=e)return o(e,s)||o(e,"@@iterator")||i[r(e)]}},{"../internals/classof":21,"../internals/get-method":47,"../internals/iterators":68,"../internals/well-known-symbol":112}],46:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/a-callable"),s=e("../internals/an-object"),a=e("../internals/try-to-string"),l=e("../internals/get-iterator-method"),c=r.TypeError;t.exports=function(e,t){var n=arguments.length<2?l(e):t;if(i(n))return s(o(n,e));throw c(a(e)+" is not iterable")}},{"../internals/a-callable":3,"../internals/an-object":8,"../internals/function-call":41,"../internals/get-iterator-method":45,"../internals/global":48,"../internals/try-to-string":106}],47:[function(e,t,n){var r=e("../internals/a-callable");t.exports=function(e,t){var n=e[t];return null==n?void 0:r(n)}},{"../internals/a-callable":3}],48:[function(e,t,n){(function(e){(function(){var n=function(e){return e&&e.Math==Math&&e};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||function(){return this}()||Function("return this")()}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],49:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/to-object"),i=r({}.hasOwnProperty);t.exports=Object.hasOwn||function(e,t){return i(o(e),t)}},{"../internals/function-uncurry-this":43,"../internals/to-object":100}],50:[function(e,t,n){t.exports={}},{}],51:[function(e,t,n){var r=e("../internals/get-built-in");t.exports=r("document","documentElement")},{"../internals/get-built-in":44}],52:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/fails"),i=e("../internals/document-create-element");t.exports=!r&&!o((function(){return 7!=Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},{"../internals/descriptors":28,"../internals/document-create-element":29,"../internals/fails":39}],53:[function(e,t,n){var r=e("../internals/global").Array,o=Math.abs,i=Math.pow,s=Math.floor,a=Math.log,l=Math.LN2;t.exports={pack:function(e,t,n){var c,u,d,f=r(n),p=8*n-t-1,h=(1<<p)-1,m=h>>1,y=23===t?i(2,-24)-i(2,-77):0,v=e<0||0===e&&1/e<0?1:0,g=0;for((e=o(e))!=e||e===1/0?(u=e!=e?1:0,c=h):(c=s(a(e)/l),e*(d=i(2,-c))<1&&(c--,d*=2),(e+=c+m>=1?y/d:y*i(2,1-m))*d>=2&&(c++,d/=2),c+m>=h?(u=0,c=h):c+m>=1?(u=(e*d-1)*i(2,t),c+=m):(u=e*i(2,m-1)*i(2,t),c=0));t>=8;f[g++]=255&u,u/=256,t-=8);for(c=c<<t|u,p+=t;p>0;f[g++]=255&c,c/=256,p-=8);return f[--g]|=128*v,f},unpack:function(e,t){var n,r=e.length,o=8*r-t-1,s=(1<<o)-1,a=s>>1,l=o-7,c=r-1,u=e[c--],d=127&u;for(u>>=7;l>0;d=256*d+e[c],c--,l-=8);for(n=d&(1<<-l)-1,d>>=-l,l+=t;l>0;n=256*n+e[c],c--,l-=8);if(0===d)d=1-a;else{if(d===s)return n?NaN:u?-1/0:1/0;n+=i(2,t),d-=a}return(u?-1:1)*n*i(2,d-t)}}},{"../internals/global":48}],54:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=e("../internals/fails"),s=e("../internals/classof-raw"),a=r.Object,l=o("".split);t.exports=i((function(){return!a("z").propertyIsEnumerable(0)}))?function(e){return"String"==s(e)?l(e,""):a(e)}:a},{"../internals/classof-raw":20,"../internals/fails":39,"../internals/function-uncurry-this":43,"../internals/global":48}],55:[function(e,t,n){var r=e("../internals/is-callable"),o=e("../internals/is-object"),i=e("../internals/object-set-prototype-of");t.exports=function(e,t,n){var s,a;return i&&r(s=t.constructor)&&s!==n&&o(a=s.prototype)&&a!==n.prototype&&i(e,a),e}},{"../internals/is-callable":60,"../internals/is-object":64,"../internals/object-set-prototype-of":83}],56:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/is-callable"),i=e("../internals/shared-store"),s=r(Function.toString);o(i.inspectSource)||(i.inspectSource=function(e){return s(e)}),t.exports=i.inspectSource},{"../internals/function-uncurry-this":43,"../internals/is-callable":60,"../internals/shared-store":93}],57:[function(e,t,n){var r,o,i,s=e("../internals/native-weak-map"),a=e("../internals/global"),l=e("../internals/function-uncurry-this"),c=e("../internals/is-object"),u=e("../internals/create-non-enumerable-property"),d=e("../internals/has-own-property"),f=e("../internals/shared-store"),p=e("../internals/shared-key"),h=e("../internals/hidden-keys"),m="Object already initialized",y=a.TypeError,v=a.WeakMap;if(s||f.state){var g=f.state||(f.state=new v),b=l(g.get),_=l(g.has),w=l(g.set);r=function(e,t){if(_(g,e))throw new y(m);return t.facade=e,w(g,e,t),t},o=function(e){return b(g,e)||{}},i=function(e){return _(g,e)}}else{var x=p("state");h[x]=!0,r=function(e,t){if(d(e,x))throw new y(m);return t.facade=e,u(e,x,t),t},o=function(e){return d(e,x)?e[x]:{}},i=function(e){return d(e,x)}}t.exports={set:r,get:o,has:i,enforce:function(e){return i(e)?o(e):r(e,{})},getterFor:function(e){return function(t){var n;if(!c(t)||(n=o(t)).type!==e)throw y("Incompatible receiver, "+e+" required");return n}}}},{"../internals/create-non-enumerable-property":25,"../internals/function-uncurry-this":43,"../internals/global":48,"../internals/has-own-property":49,"../internals/hidden-keys":50,"../internals/is-object":64,"../internals/native-weak-map":71,"../internals/shared-key":92,"../internals/shared-store":93}],58:[function(e,t,n){var r=e("../internals/well-known-symbol"),o=e("../internals/iterators"),i=r("iterator"),s=Array.prototype;t.exports=function(e){return void 0!==e&&(o.Array===e||s[i]===e)}},{"../internals/iterators":68,"../internals/well-known-symbol":112}],59:[function(e,t,n){var r=e("../internals/classof-raw");t.exports=Array.isArray||function(e){return"Array"==r(e)}},{"../internals/classof-raw":20}],60:[function(e,t,n){t.exports=function(e){return"function"==typeof e}},{}],61:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/fails"),i=e("../internals/is-callable"),s=e("../internals/classof"),a=e("../internals/get-built-in"),l=e("../internals/inspect-source"),c=function(){},u=[],d=a("Reflect","construct"),f=/^\s*(?:class|function)\b/,p=r(f.exec),h=!f.exec(c),m=function(e){if(!i(e))return!1;try{return d(c,u,e),!0}catch(e){return!1}};t.exports=!d||o((function(){var e;return m(m.call)||!m(Object)||!m((function(){e=!0}))||e}))?function(e){if(!i(e))return!1;switch(s(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}return h||!!p(f,l(e))}:m},{"../internals/classof":21,"../internals/fails":39,"../internals/function-uncurry-this":43,"../internals/get-built-in":44,"../internals/inspect-source":56,"../internals/is-callable":60}],62:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/is-callable"),i=/#|\.prototype\./,s=function(e,t){var n=l[a(e)];return n==u||n!=c&&(o(t)?r(t):!!t)},a=s.normalize=function(e){return String(e).replace(i,".").toLowerCase()},l=s.data={},c=s.NATIVE="N",u=s.POLYFILL="P";t.exports=s},{"../internals/fails":39,"../internals/is-callable":60}],63:[function(e,t,n){var r=e("../internals/is-object"),o=Math.floor;t.exports=Number.isInteger||function(e){return!r(e)&&isFinite(e)&&o(e)===e}},{"../internals/is-object":64}],64:[function(e,t,n){var r=e("../internals/is-callable");t.exports=function(e){return"object"==typeof e?null!==e:r(e)}},{"../internals/is-callable":60}],65:[function(e,t,n){t.exports=!1},{}],66:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/get-built-in"),i=e("../internals/is-callable"),s=e("../internals/object-is-prototype-of"),a=e("../internals/use-symbol-as-uid"),l=r.Object;t.exports=a?function(e){return"symbol"==typeof e}:function(e){var t=o("Symbol");return i(t)&&s(t.prototype,l(e))}},{"../internals/get-built-in":44,"../internals/global":48,"../internals/is-callable":60,"../internals/object-is-prototype-of":79,"../internals/use-symbol-as-uid":111}],67:[function(e,t,n){"use strict";var r,o,i,s=e("../internals/fails"),a=e("../internals/is-callable"),l=e("../internals/object-create"),c=e("../internals/object-get-prototype-of"),u=e("../internals/redefine"),d=e("../internals/well-known-symbol"),f=e("../internals/is-pure"),p=d("iterator"),h=!1;[].keys&&("next"in(i=[].keys())?(o=c(c(i)))!==Object.prototype&&(r=o):h=!0),null==r||s((function(){var e={};return r[p].call(e)!==e}))?r={}:f&&(r=l(r)),a(r[p])||u(r,p,(function(){return this})),t.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:h}},{"../internals/fails":39,"../internals/is-callable":60,"../internals/is-pure":65,"../internals/object-create":72,"../internals/object-get-prototype-of":78,"../internals/redefine":87,"../internals/well-known-symbol":112}],68:[function(e,t,n){arguments[4][50][0].apply(n,arguments)},{dup:50}],69:[function(e,t,n){var r=e("../internals/to-length");t.exports=function(e){return r(e.length)}},{"../internals/to-length":99}],70:[function(e,t,n){var r=e("../internals/engine-v8-version"),o=e("../internals/fails");t.exports=!!Object.getOwnPropertySymbols&&!o((function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},{"../internals/engine-v8-version":35,"../internals/fails":39}],71:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/inspect-source"),s=r.WeakMap;t.exports=o(s)&&/native code/.test(i(s))},{"../internals/global":48,"../internals/inspect-source":56,"../internals/is-callable":60}],72:[function(e,t,n){var r,o=e("../internals/an-object"),i=e("../internals/object-define-properties"),s=e("../internals/enum-bug-keys"),a=e("../internals/hidden-keys"),l=e("../internals/html"),c=e("../internals/document-create-element"),u=e("../internals/shared-key")("IE_PROTO"),d=function(){},f=function(e){return"<script>"+e+"<\/script>"},p=function(e){e.write(f("")),e.close();var t=e.parentWindow.Object;return e=null,t},h=function(){try{r=new ActiveXObject("htmlfile")}catch(e){}var e,t;h="undefined"!=typeof document?document.domain&&r?p(r):((t=c("iframe")).style.display="none",l.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(f("document.F=Object")),e.close(),e.F):p(r);for(var n=s.length;n--;)delete h.prototype[s[n]];return h()};a[u]=!0,t.exports=Object.create||function(e,t){var n;return null!==e?(d.prototype=o(e),n=new d,d.prototype=null,n[u]=e):n=h(),void 0===t?n:i(n,t)}},{"../internals/an-object":8,"../internals/document-create-element":29,"../internals/enum-bug-keys":37,"../internals/hidden-keys":50,"../internals/html":51,"../internals/object-define-properties":73,"../internals/shared-key":92}],73:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/object-define-property"),i=e("../internals/an-object"),s=e("../internals/to-indexed-object"),a=e("../internals/object-keys");t.exports=r?Object.defineProperties:function(e,t){i(e);for(var n,r=s(t),l=a(t),c=l.length,u=0;c>u;)o.f(e,n=l[u++],r[n]);return e}},{"../internals/an-object":8,"../internals/descriptors":28,"../internals/object-define-property":74,"../internals/object-keys":81,"../internals/to-indexed-object":97}],74:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/descriptors"),i=e("../internals/ie8-dom-define"),s=e("../internals/an-object"),a=e("../internals/to-property-key"),l=r.TypeError,c=Object.defineProperty;n.f=o?c:function(e,t,n){if(s(e),t=a(t),s(n),i)try{return c(e,t,n)}catch(e){}if("get"in n||"set"in n)throw l("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},{"../internals/an-object":8,"../internals/descriptors":28,"../internals/global":48,"../internals/ie8-dom-define":52,"../internals/to-property-key":104}],75:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/function-call"),i=e("../internals/object-property-is-enumerable"),s=e("../internals/create-property-descriptor"),a=e("../internals/to-indexed-object"),l=e("../internals/to-property-key"),c=e("../internals/has-own-property"),u=e("../internals/ie8-dom-define"),d=Object.getOwnPropertyDescriptor;n.f=r?d:function(e,t){if(e=a(e),t=l(t),u)try{return d(e,t)}catch(e){}if(c(e,t))return s(!o(i.f,e,t),e[t])}},{"../internals/create-property-descriptor":26,"../internals/descriptors":28,"../internals/function-call":41,"../internals/has-own-property":49,"../internals/ie8-dom-define":52,"../internals/object-property-is-enumerable":82,"../internals/to-indexed-object":97,"../internals/to-property-key":104}],76:[function(e,t,n){var r=e("../internals/object-keys-internal"),o=e("../internals/enum-bug-keys").concat("length","prototype");n.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},{"../internals/enum-bug-keys":37,"../internals/object-keys-internal":80}],77:[function(e,t,n){n.f=Object.getOwnPropertySymbols},{}],78:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/has-own-property"),i=e("../internals/is-callable"),s=e("../internals/to-object"),a=e("../internals/shared-key"),l=e("../internals/correct-prototype-getter"),c=a("IE_PROTO"),u=r.Object,d=u.prototype;t.exports=l?u.getPrototypeOf:function(e){var t=s(e);if(o(t,c))return t[c];var n=t.constructor;return i(n)&&t instanceof n?n.prototype:t instanceof u?d:null}},{"../internals/correct-prototype-getter":23,"../internals/global":48,"../internals/has-own-property":49,"../internals/is-callable":60,"../internals/shared-key":92,"../internals/to-object":100}],79:[function(e,t,n){var r=e("../internals/function-uncurry-this");t.exports=r({}.isPrototypeOf)},{"../internals/function-uncurry-this":43}],80:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/has-own-property"),i=e("../internals/to-indexed-object"),s=e("../internals/array-includes").indexOf,a=e("../internals/hidden-keys"),l=r([].push);t.exports=function(e,t){var n,r=i(e),c=0,u=[];for(n in r)!o(a,n)&&o(r,n)&&l(u,n);for(;t.length>c;)o(r,n=t[c++])&&(~s(u,n)||l(u,n));return u}},{"../internals/array-includes":13,"../internals/function-uncurry-this":43,"../internals/has-own-property":49,"../internals/hidden-keys":50,"../internals/to-indexed-object":97}],81:[function(e,t,n){var r=e("../internals/object-keys-internal"),o=e("../internals/enum-bug-keys");t.exports=Object.keys||function(e){return r(e,o)}},{"../internals/enum-bug-keys":37,"../internals/object-keys-internal":80}],82:[function(e,t,n){"use strict";var r={}.propertyIsEnumerable,o=Object.getOwnPropertyDescriptor,i=o&&!r.call({1:2},1);n.f=i?function(e){var t=o(this,e);return!!t&&t.enumerable}:r},{}],83:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/an-object"),i=e("../internals/a-possible-prototype");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{(e=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),t=n instanceof Array}catch(e){}return function(n,r){return o(n),i(r),t?e(n,r):n.__proto__=r,n}}():void 0)},{"../internals/a-possible-prototype":5,"../internals/an-object":8,"../internals/function-uncurry-this":43}],84:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/is-callable"),s=e("../internals/is-object"),a=r.TypeError;t.exports=function(e,t){var n,r;if("string"===t&&i(n=e.toString)&&!s(r=o(n,e)))return r;if(i(n=e.valueOf)&&!s(r=o(n,e)))return r;if("string"!==t&&i(n=e.toString)&&!s(r=o(n,e)))return r;throw a("Can't convert object to primitive value")}},{"../internals/function-call":41,"../internals/global":48,"../internals/is-callable":60,"../internals/is-object":64}],85:[function(e,t,n){var r=e("../internals/get-built-in"),o=e("../internals/function-uncurry-this"),i=e("../internals/object-get-own-property-names"),s=e("../internals/object-get-own-property-symbols"),a=e("../internals/an-object"),l=o([].concat);t.exports=r("Reflect","ownKeys")||function(e){var t=i.f(a(e)),n=s.f;return n?l(t,n(e)):t}},{"../internals/an-object":8,"../internals/function-uncurry-this":43,"../internals/get-built-in":44,"../internals/object-get-own-property-names":76,"../internals/object-get-own-property-symbols":77}],86:[function(e,t,n){var r=e("../internals/redefine");t.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},{"../internals/redefine":87}],87:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/has-own-property"),s=e("../internals/create-non-enumerable-property"),a=e("../internals/set-global"),l=e("../internals/inspect-source"),c=e("../internals/internal-state"),u=e("../internals/function-name").CONFIGURABLE,d=c.get,f=c.enforce,p=String(String).split("String");(t.exports=function(e,t,n,l){var c,d=!!l&&!!l.unsafe,h=!!l&&!!l.enumerable,m=!!l&&!!l.noTargetGet,y=l&&void 0!==l.name?l.name:t;o(n)&&("Symbol("===String(y).slice(0,7)&&(y="["+String(y).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!i(n,"name")||u&&n.name!==y)&&s(n,"name",y),(c=f(n)).source||(c.source=p.join("string"==typeof y?y:""))),e!==r?(d?!m&&e[t]&&(h=!0):delete e[t],h?e[t]=n:s(e,t,n)):h?e[t]=n:a(t,n)})(Function.prototype,"toString",(function(){return o(this)&&d(this).source||l(this)}))},{"../internals/create-non-enumerable-property":25,"../internals/function-name":42,"../internals/global":48,"../internals/has-own-property":49,"../internals/inspect-source":56,"../internals/internal-state":57,"../internals/is-callable":60,"../internals/set-global":89}],88:[function(e,t,n){var r=e("../internals/global").TypeError;t.exports=function(e){if(null==e)throw r("Can't call method on "+e);return e}},{"../internals/global":48}],89:[function(e,t,n){var r=e("../internals/global"),o=Object.defineProperty;t.exports=function(e,t){try{o(r,e,{value:t,configurable:!0,writable:!0})}catch(n){r[e]=t}return t}},{"../internals/global":48}],90:[function(e,t,n){"use strict";var r=e("../internals/get-built-in"),o=e("../internals/object-define-property"),i=e("../internals/well-known-symbol"),s=e("../internals/descriptors"),a=i("species");t.exports=function(e){var t=r(e),n=o.f;s&&t&&!t[a]&&n(t,a,{configurable:!0,get:function(){return this}})}},{"../internals/descriptors":28,"../internals/get-built-in":44,"../internals/object-define-property":74,"../internals/well-known-symbol":112}],91:[function(e,t,n){var r=e("../internals/object-define-property").f,o=e("../internals/has-own-property"),i=e("../internals/well-known-symbol")("toStringTag");t.exports=function(e,t,n){e&&!o(e=n?e:e.prototype,i)&&r(e,i,{configurable:!0,value:t})}},{"../internals/has-own-property":49,"../internals/object-define-property":74,"../internals/well-known-symbol":112}],92:[function(e,t,n){var r=e("../internals/shared"),o=e("../internals/uid"),i=r("keys");t.exports=function(e){return i[e]||(i[e]=o(e))}},{"../internals/shared":94,"../internals/uid":110}],93:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/set-global"),i="__core-js_shared__",s=r[i]||o(i,{});t.exports=s},{"../internals/global":48,"../internals/set-global":89}],94:[function(e,t,n){var r=e("../internals/is-pure"),o=e("../internals/shared-store");(t.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.19.1",mode:r?"pure":"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"})},{"../internals/is-pure":65,"../internals/shared-store":93}],95:[function(e,t,n){var r=e("../internals/to-integer-or-infinity"),o=Math.max,i=Math.min;t.exports=function(e,t){var n=r(e);return n<0?o(n+t,0):i(n,t)}},{"../internals/to-integer-or-infinity":98}],96:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-integer-or-infinity"),i=e("../internals/to-length"),s=r.RangeError;t.exports=function(e){if(void 0===e)return 0;var t=o(e),n=i(t);if(t!==n)throw s("Wrong length or index");return n}},{"../internals/global":48,"../internals/to-integer-or-infinity":98,"../internals/to-length":99}],97:[function(e,t,n){var r=e("../internals/indexed-object"),o=e("../internals/require-object-coercible");t.exports=function(e){return r(o(e))}},{"../internals/indexed-object":54,"../internals/require-object-coercible":88}],98:[function(e,t,n){var r=Math.ceil,o=Math.floor;t.exports=function(e){var t=+e;return t!=t||0===t?0:(t>0?o:r)(t)}},{}],99:[function(e,t,n){var r=e("../internals/to-integer-or-infinity"),o=Math.min;t.exports=function(e){return e>0?o(r(e),9007199254740991):0}},{"../internals/to-integer-or-infinity":98}],100:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/require-object-coercible"),i=r.Object;t.exports=function(e){return i(o(e))}},{"../internals/global":48,"../internals/require-object-coercible":88}],101:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-positive-integer"),i=r.RangeError;t.exports=function(e,t){var n=o(e);if(n%t)throw i("Wrong offset");return n}},{"../internals/global":48,"../internals/to-positive-integer":102}],102:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-integer-or-infinity"),i=r.RangeError;t.exports=function(e){var t=o(e);if(t<0)throw i("The argument can't be less than 0");return t}},{"../internals/global":48,"../internals/to-integer-or-infinity":98}],103:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/is-object"),s=e("../internals/is-symbol"),a=e("../internals/get-method"),l=e("../internals/ordinary-to-primitive"),c=e("../internals/well-known-symbol"),u=r.TypeError,d=c("toPrimitive");t.exports=function(e,t){if(!i(e)||s(e))return e;var n,r=a(e,d);if(r){if(void 0===t&&(t="default"),n=o(r,e,t),!i(n)||s(n))return n;throw u("Can't convert object to primitive value")}return void 0===t&&(t="number"),l(e,t)}},{"../internals/function-call":41,"../internals/get-method":47,"../internals/global":48,"../internals/is-object":64,"../internals/is-symbol":66,"../internals/ordinary-to-primitive":84,"../internals/well-known-symbol":112}],104:[function(e,t,n){var r=e("../internals/to-primitive"),o=e("../internals/is-symbol");t.exports=function(e){var t=r(e,"string");return o(t)?t:t+""}},{"../internals/is-symbol":66,"../internals/to-primitive":103}],105:[function(e,t,n){var r={};r[e("../internals/well-known-symbol")("toStringTag")]="z",t.exports="[object z]"===String(r)},{"../internals/well-known-symbol":112}],106:[function(e,t,n){var r=e("../internals/global").String;t.exports=function(e){try{return r(e)}catch(e){return"Object"}}},{"../internals/global":48}],107:[function(e,t,n){"use strict";var r=e("../internals/export"),o=e("../internals/global"),i=e("../internals/function-call"),s=e("../internals/descriptors"),a=e("../internals/typed-array-constructors-require-wrappers"),l=e("../internals/array-buffer-view-core"),c=e("../internals/array-buffer"),u=e("../internals/an-instance"),d=e("../internals/create-property-descriptor"),f=e("../internals/create-non-enumerable-property"),p=e("../internals/is-integral-number"),h=e("../internals/to-length"),m=e("../internals/to-index"),y=e("../internals/to-offset"),v=e("../internals/to-property-key"),g=e("../internals/has-own-property"),b=e("../internals/classof"),_=e("../internals/is-object"),w=e("../internals/is-symbol"),x=e("../internals/object-create"),k=e("../internals/object-is-prototype-of"),j=e("../internals/object-set-prototype-of"),C=e("../internals/object-get-own-property-names").f,D=e("../internals/typed-array-from"),E=e("../internals/array-iteration").forEach,S=e("../internals/set-species"),O=e("../internals/object-define-property"),P=e("../internals/object-get-own-property-descriptor"),B=e("../internals/internal-state"),M=e("../internals/inherit-if-required"),T=B.get,A=B.set,I=O.f,K=P.f,L=Math.round,R=o.RangeError,N=c.ArrayBuffer,F=N.prototype,U=c.DataView,z=l.NATIVE_ARRAY_BUFFER_VIEWS,H=l.TYPED_ARRAY_CONSTRUCTOR,W=l.TYPED_ARRAY_TAG,q=l.TypedArray,V=l.TypedArrayPrototype,G=l.aTypedArrayConstructor,Y=l.isTypedArray,X="BYTES_PER_ELEMENT",$="Wrong length",J=function(e,t){G(e);for(var n=0,r=t.length,o=new e(r);r>n;)o[n]=t[n++];return o},Q=function(e,t){I(e,t,{get:function(){return T(this)[t]}})},Z=function(e){var t;return k(F,e)||"ArrayBuffer"==(t=b(e))||"SharedArrayBuffer"==t},ee=function(e,t){return Y(e)&&!w(t)&&t in e&&p(+t)&&t>=0},te=function(e,t){return t=v(t),ee(e,t)?d(2,e[t]):K(e,t)},ne=function(e,t,n){return t=v(t),!(ee(e,t)&&_(n)&&g(n,"value"))||g(n,"get")||g(n,"set")||n.configurable||g(n,"writable")&&!n.writable||g(n,"enumerable")&&!n.enumerable?I(e,t,n):(e[t]=n.value,e)};s?(z||(P.f=te,O.f=ne,Q(V,"buffer"),Q(V,"byteOffset"),Q(V,"byteLength"),Q(V,"length")),r({target:"Object",stat:!0,forced:!z},{getOwnPropertyDescriptor:te,defineProperty:ne}),t.exports=function(e,t,n){var s=e.match(/\d+$/)[0]/8,l=e+(n?"Clamped":"")+"Array",c="get"+e,d="set"+e,p=o[l],v=p,g=v&&v.prototype,b={},w=function(e,t){I(e,t,{get:function(){return function(e,t){var n=T(e);return n.view[c](t*s+n.byteOffset,!0)}(this,t)},set:function(e){return function(e,t,r){var o=T(e);n&&(r=(r=L(r))<0?0:r>255?255:255&r),o.view[d](t*s+o.byteOffset,r,!0)}(this,t,e)},enumerable:!0})};z?a&&(v=t((function(e,t,n,r){return u(e,g),M(_(t)?Z(t)?void 0!==r?new p(t,y(n,s),r):void 0!==n?new p(t,y(n,s)):new p(t):Y(t)?J(v,t):i(D,v,t):new p(m(t)),e,v)})),j&&j(v,q),E(C(p),(function(e){e in v||f(v,e,p[e])})),v.prototype=g):(v=t((function(e,t,n,r){u(e,g);var o,a,l,c=0,d=0;if(_(t)){if(!Z(t))return Y(t)?J(v,t):i(D,v,t);o=t,d=y(n,s);var f=t.byteLength;if(void 0===r){if(f%s)throw R($);if((a=f-d)<0)throw R($)}else if((a=h(r)*s)+d>f)throw R($);l=a/s}else l=m(t),o=new N(a=l*s);for(A(e,{buffer:o,byteOffset:d,byteLength:a,length:l,view:new U(o)});c<l;)w(e,c++)})),j&&j(v,q),g=v.prototype=x(V)),g.constructor!==v&&f(g,"constructor",v),f(g,H,v),W&&f(g,W,l),b[l]=v,r({global:!0,forced:v!=p,sham:!z},b),X in v||f(v,X,s),X in g||f(g,X,s),S(l)}):t.exports=function(){}},{"../internals/an-instance":7,"../internals/array-buffer":11,"../internals/array-buffer-view-core":10,"../internals/array-iteration":14,"../internals/classof":21,"../internals/create-non-enumerable-property":25,"../internals/create-property-descriptor":26,"../internals/descriptors":28,"../internals/export":38,"../internals/function-call":41,"../internals/global":48,"../internals/has-own-property":49,"../internals/inherit-if-required":55,"../internals/internal-state":57,"../internals/is-integral-number":63,"../internals/is-object":64,"../internals/is-symbol":66,"../internals/object-create":72,"../internals/object-define-property":74,"../internals/object-get-own-property-descriptor":75,"../internals/object-get-own-property-names":76,"../internals/object-is-prototype-of":79,"../internals/object-set-prototype-of":83,"../internals/set-species":90,"../internals/to-index":96,"../internals/to-length":99,"../internals/to-offset":101,"../internals/to-property-key":104,"../internals/typed-array-constructors-require-wrappers":108,"../internals/typed-array-from":109}],108:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/fails"),i=e("../internals/check-correctness-of-iteration"),s=e("../internals/array-buffer-view-core").NATIVE_ARRAY_BUFFER_VIEWS,a=r.ArrayBuffer,l=r.Int8Array;t.exports=!s||!o((function(){l(1)}))||!o((function(){new l(-1)}))||!i((function(e){new l,new l(null),new l(1.5),new l(e)}),!0)||o((function(){return 1!==new l(new a(2),1,void 0).length}))},{"../internals/array-buffer-view-core":10,"../internals/check-correctness-of-iteration":19,"../internals/fails":39,"../internals/global":48}],109:[function(e,t,n){var r=e("../internals/function-bind-context"),o=e("../internals/function-call"),i=e("../internals/a-constructor"),s=e("../internals/to-object"),a=e("../internals/length-of-array-like"),l=e("../internals/get-iterator"),c=e("../internals/get-iterator-method"),u=e("../internals/is-array-iterator-method"),d=e("../internals/array-buffer-view-core").aTypedArrayConstructor;t.exports=function(e){var t,n,f,p,h,m,y=i(this),v=s(e),g=arguments.length,b=g>1?arguments[1]:void 0,_=void 0!==b,w=c(v);if(w&&!u(w))for(m=(h=l(v,w)).next,v=[];!(p=o(m,h)).done;)v.push(p.value);for(_&&g>2&&(b=r(b,arguments[2])),n=a(v),f=new(d(y))(n),t=0;n>t;t++)f[t]=_?b(v[t],t):v[t];return f}},{"../internals/a-constructor":4,"../internals/array-buffer-view-core":10,"../internals/function-bind-context":40,"../internals/function-call":41,"../internals/get-iterator":46,"../internals/get-iterator-method":45,"../internals/is-array-iterator-method":58,"../internals/length-of-array-like":69,"../internals/to-object":100}],110:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=0,i=Math.random(),s=r(1..toString);t.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+s(++o+i,36)}},{"../internals/function-uncurry-this":43}],111:[function(e,t,n){var r=e("../internals/native-symbol");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},{"../internals/native-symbol":70}],112:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/shared"),i=e("../internals/has-own-property"),s=e("../internals/uid"),a=e("../internals/native-symbol"),l=e("../internals/use-symbol-as-uid"),c=o("wks"),u=r.Symbol,d=u&&u.for,f=l?u:u&&u.withoutSetter||s;t.exports=function(e){if(!i(c,e)||!a&&"string"!=typeof c[e]){var t="Symbol."+e;a&&i(u,e)?c[e]=u[e]:c[e]=l&&d?d(t):f(t)}return c[e]}},{"../internals/global":48,"../internals/has-own-property":49,"../internals/native-symbol":70,"../internals/shared":94,"../internals/uid":110,"../internals/use-symbol-as-uid":111}],113:[function(e,t,n){"use strict";var r=e("../internals/to-indexed-object"),o=e("../internals/add-to-unscopables"),i=e("../internals/iterators"),s=e("../internals/internal-state"),a=e("../internals/define-iterator"),l="Array Iterator",c=s.set,u=s.getterFor(l);t.exports=a(Array,"Array",(function(e,t){c(this,{type:l,target:r(e),index:0,kind:t})}),(function(){var e=u(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}}),"values"),i.Arguments=i.Array,o("keys"),o("values"),o("entries")},{"../internals/add-to-unscopables":6,"../internals/define-iterator":27,"../internals/internal-state":57,"../internals/iterators":68,"../internals/to-indexed-object":97}],114:[function(e,t,n){e("../internals/typed-array-constructor")("Float32",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},{"../internals/typed-array-constructor":107}],115:[function(e,t,n){"use strict";var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=e("../internals/fails"),s=e("../internals/a-callable"),a=e("../internals/array-sort"),l=e("../internals/array-buffer-view-core"),c=e("../internals/engine-ff-version"),u=e("../internals/engine-is-ie-or-edge"),d=e("../internals/engine-v8-version"),f=e("../internals/engine-webkit-version"),p=r.Array,h=l.aTypedArray,m=l.exportTypedArrayMethod,y=r.Uint16Array,v=y&&o(y.prototype.sort),g=!(!v||i((function(){v(new y(2),null)}))&&i((function(){v(new y(2),{})}))),b=!!v&&!i((function(){if(d)return d<74;if(c)return c<67;if(u)return!0;if(f)return f<602;var e,t,n=new y(516),r=p(516);for(e=0;e<516;e++)t=e%4,n[e]=515-e,r[e]=e-2*t+3;for(v(n,(function(e,t){return(e/4|0)-(t/4|0)})),e=0;e<516;e++)if(n[e]!==r[e])return!0}));m("sort",(function(e){return void 0!==e&&s(e),b?v(this,e):a(h(this),function(e){return function(t,n){return void 0!==e?+e(t,n)||0:n!=n?-1:t!=t?1:0===t&&0===n?1/t>0&&1/n<0?1:-1:t>n}}(e))}),!b||g)},{"../internals/a-callable":3,"../internals/array-buffer-view-core":10,"../internals/array-sort":16,"../internals/engine-ff-version":32,"../internals/engine-is-ie-or-edge":33,"../internals/engine-v8-version":35,"../internals/engine-webkit-version":36,"../internals/fails":39,"../internals/function-uncurry-this":43,"../internals/global":48}],116:[function(e,t,n){e("../internals/typed-array-constructor")("Uint8",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},{"../internals/typed-array-constructor":107}],117:[function(e,t,n){e("../internals/typed-array-constructor")("Uint8",(function(e){return function(t,n,r){return e(this,t,n,r)}}),!0)},{"../internals/typed-array-constructor":107}],118:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/dom-iterables"),i=e("../internals/dom-token-list-prototype"),s=e("../modules/es.array.iterator"),a=e("../internals/create-non-enumerable-property"),l=e("../internals/well-known-symbol"),c=l("iterator"),u=l("toStringTag"),d=s.values,f=function(e,t){if(e){if(e[c]!==d)try{a(e,c,d)}catch(t){e[c]=d}if(e[u]||a(e,u,t),o[t])for(var n in s)if(e[n]!==s[n])try{a(e,n,s[n])}catch(t){e[n]=s[n]}}};for(var p in o)f(r[p]&&r[p].prototype,p);f(i,"DOMTokenList")},{"../internals/create-non-enumerable-property":25,"../internals/dom-iterables":30,"../internals/dom-token-list-prototype":31,"../internals/global":48,"../internals/well-known-symbol":112,"../modules/es.array.iterator":113}],119:[function(e,t,n){"use strict";var r=t.exports={};r.isIE=function(e){return!(-1===(t=navigator.userAgent.toLowerCase()).indexOf("msie")&&-1===t.indexOf("trident")&&-1===t.indexOf(" edge/")||e&&e!==function(){var e=3,t=document.createElement("div"),n=t.getElementsByTagName("i");do{t.innerHTML="\x3c!--[if gt IE "+ ++e+"]><i></i><![endif]--\x3e"}while(n[0]);return e>4?e:void 0}());var t},r.isLegacyOpera=function(){return!!window.opera}},{}],120:[function(e,t,n){"use strict";(t.exports={}).forEach=function(e,t){for(var n=0;n<e.length;n++){var r=t(e[n]);if(r)return r}}},{}],121:[function(e,t,n){"use strict";var r=e("../browser-detector");t.exports=function(e){var t=(e=e||{}).reporter,n=e.batchProcessor,o=e.stateHandler.getState;if(!t)throw new Error("Missing required dependency: reporter.");function i(t){var n=e.important?" !important; ":"; ";return(t.join(n)+n).trim()}function s(e){return o(e).object}return{makeDetectable:function(e,s,a){a||(a=s,s=e,e=null),(e=e||{}).debug,r.isIE(8)?a(s):function(s,a){var l=i(["display: block","position: absolute","top: 0","left: 0","width: 100%","height: 100%","border: none","padding: 0","margin: 0","opacity: 0","z-index: -1000","pointer-events: none"]),c=!1,u=window.getComputedStyle(s),d=s.offsetWidth,f=s.offsetHeight;function p(){function n(){if("static"===u.position){s.style.setProperty("position","relative",e.important?"important":"");var n=function(t,n,r,o){var i=r[o];"auto"!==i&&"0"!==function(e){return e.replace(/[^-\d\.]/g,"")}(i)&&(t.warn("An element that is positioned static has style."+o+"="+i+" which is ignored due to the static positioning. The element will need to be positioned relative, so the style."+o+" will be set to 0. Element: ",n),n.style.setProperty(o,"0",e.important?"important":""))};n(t,s,u,"top"),n(t,s,u,"right"),n(t,s,u,"bottom"),n(t,s,u,"left")}}""!==u.position&&(n(),c=!0);var i=document.createElement("object");i.style.cssText=l,i.tabIndex=-1,i.type="text/html",i.setAttribute("aria-hidden","true"),i.onload=function(){c||n(),function e(t,n){if(!t.contentDocument){var r=o(t);return r.checkForObjectDocumentTimeoutId&&window.clearTimeout(r.checkForObjectDocumentTimeoutId),void(r.checkForObjectDocumentTimeoutId=setTimeout((function(){r.checkForObjectDocumentTimeoutId=0,e(t,n)}),100))}n(t.contentDocument)}(this,(function(e){a(s)}))},r.isIE()||(i.data="about:blank"),o(s)&&(s.appendChild(i),o(s).object=i,r.isIE()&&(i.data="about:blank"))}o(s).startSize={width:d,height:f},n?n.add(p):p()}(s,a)},addListener:function(e,t){function n(){t(e)}if(r.isIE(8))o(e).object={proxy:n},e.attachEvent("onresize",n);else{var i=s(e);if(!i)throw new Error("Element is not detectable by this strategy.");i.contentDocument.defaultView.addEventListener("resize",n)}},uninstall:function(e){if(o(e)){var t=s(e);t&&(r.isIE(8)?e.detachEvent("onresize",t.proxy):e.removeChild(t),o(e).checkForObjectDocumentTimeoutId&&window.clearTimeout(o(e).checkForObjectDocumentTimeoutId),delete o(e).object)}}}}},{"../browser-detector":119}],122:[function(e,t,n){"use strict";var r=e("../collection-utils").forEach;t.exports=function(e){var t=(e=e||{}).reporter,n=e.batchProcessor,o=e.stateHandler.getState,i=(e.stateHandler.hasState,e.idHandler);if(!n)throw new Error("Missing required dependency: batchProcessor");if(!t)throw new Error("Missing required dependency: reporter.");var s=function(){var e=document.createElement("div");e.style.cssText=c(["position: absolute","width: 1000px","height: 1000px","visibility: hidden","margin: 0","padding: 0"]);var t=document.createElement("div");t.style.cssText=c(["position: absolute","width: 500px","height: 500px","overflow: scroll","visibility: none","top: -1500px","left: -1500px","visibility: hidden","margin: 0","padding: 0"]),t.appendChild(e),document.body.insertBefore(t,document.body.firstChild);var n=500-t.clientWidth,r=500-t.clientHeight;return document.body.removeChild(t),{width:n,height:r}}(),a="erd_scroll_detection_container";function l(e){!function(e,t,n){if(!e.getElementById(t)){var r=n+"_animation",o="/* Created by the element-resize-detector library. */\n";o+="."+n+" > div::-webkit-scrollbar { "+c(["display: none"])+" }\n\n",o+=".erd_scroll_detection_container_animation_active { "+c(["-webkit-animation-duration: 0.1s","animation-duration: 0.1s","-webkit-animation-name: "+r,"animation-name: "+r])+" }\n",o+="@-webkit-keyframes "+r+" { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } }\n",function(n,r){r=r||function(t){e.head.appendChild(t)};var o=e.createElement("style");o.innerHTML=n,o.id=t,r(o)}(o+="@keyframes "+r+" { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } }")}}(e,"erd_scroll_detection_scrollbar_style",a)}function c(t){var n=e.important?" !important; ":"; ";return(t.join(n)+n).trim()}function u(e,n,r){if(e.addEventListener)e.addEventListener(n,r);else{if(!e.attachEvent)return t.error("[scroll] Don't know how to add event listeners.");e.attachEvent("on"+n,r)}}function d(e,n,r){if(e.removeEventListener)e.removeEventListener(n,r);else{if(!e.detachEvent)return t.error("[scroll] Don't know how to remove event listeners.");e.detachEvent("on"+n,r)}}function f(e){return o(e).container.childNodes[0].childNodes[0].childNodes[0]}function p(e){return o(e).container.childNodes[0].childNodes[0].childNodes[1]}return l(window.document),{makeDetectable:function(e,l,d){function h(){if(e.debug){var n=Array.prototype.slice.call(arguments);if(n.unshift(i.get(l),"Scroll: "),t.log.apply)t.log.apply(null,n);else for(var r=0;r<n.length;r++)t.log(n[r])}}function m(e){var t=o(e).container.childNodes[0],n=window.getComputedStyle(t);return!n.width||-1===n.width.indexOf("px")}function y(){var e=window.getComputedStyle(l),t={};return t.position=e.position,t.width=l.offsetWidth,t.height=l.offsetHeight,t.top=e.top,t.right=e.right,t.bottom=e.bottom,t.left=e.left,t.widthCSS=e.width,t.heightCSS=e.height,t}function v(){if(h("storeStyle invoked."),o(l)){var e=y();o(l).style=e}else h("Aborting because element has been uninstalled")}function g(e,t,n){o(e).lastWidth=t,o(e).lastHeight=n}function b(){return 2*s.width+1}function _(){return 2*s.height+1}function w(e){return e+10+b()}function x(e){return e+10+_()}function k(e,t,n){var r=f(e),o=p(e),i=w(t),s=x(n),a=function(e){return 2*e+b()}(t),l=function(e){return 2*e+_()}(n);r.scrollLeft=i,r.scrollTop=s,o.scrollLeft=a,o.scrollTop=l}function j(){var e=o(l).container;if(!e){(e=document.createElement("div")).className=a,e.style.cssText=c(["visibility: hidden","display: inline","width: 0px","height: 0px","z-index: -1","overflow: hidden","margin: 0","padding: 0"]),o(l).container=e,function(e){e.className+=" "+a+"_animation_active"}(e),l.appendChild(e);var t=function(){o(l).onRendered&&o(l).onRendered()};u(e,"animationstart",t),o(l).onAnimationStart=t}return e}function C(){if(h("Injecting elements"),o(l)){!function(){var n=o(l).style;if("static"===n.position){l.style.setProperty("position","relative",e.important?"important":"");var r=function(e,t,n,r){var o=n[r];"auto"!==o&&"0"!==function(e){return e.replace(/[^-\d\.]/g,"")}(o)&&(e.warn("An element that is positioned static has style."+r+"="+o+" which is ignored due to the static positioning. The element will need to be positioned relative, so the style."+r+" will be set to 0. Element: ",t),t.style[r]=0)};r(t,l,n,"top"),r(t,l,n,"right"),r(t,l,n,"bottom"),r(t,l,n,"left")}}();var n=o(l).container;n||(n=j());var r,i,d,f,p=s.width,m=s.height,y=c(["position: absolute","flex: none","overflow: hidden","z-index: -1","visibility: hidden","width: 100%","height: 100%","left: 0px","top: 0px"]),v=c(["position: absolute","flex: none","overflow: hidden","z-index: -1","visibility: hidden"].concat(["left: "+(r=(r=-(1+p))?r+"px":"0"),"top: "+(i=(i=-(1+m))?i+"px":"0"),"right: "+(f=(f=-p)?f+"px":"0"),"bottom: "+(d=(d=-m)?d+"px":"0")])),g=c(["position: absolute","flex: none","overflow: scroll","z-index: -1","visibility: hidden","width: 100%","height: 100%"]),b=c(["position: absolute","flex: none","overflow: scroll","z-index: -1","visibility: hidden","width: 100%","height: 100%"]),_=c(["position: absolute","left: 0","top: 0"]),w=c(["position: absolute","width: 200%","height: 200%"]),x=document.createElement("div"),k=document.createElement("div"),C=document.createElement("div"),D=document.createElement("div"),E=document.createElement("div"),S=document.createElement("div");x.dir="ltr",x.style.cssText=y,x.className=a,k.className=a,k.style.cssText=v,C.style.cssText=g,D.style.cssText=_,E.style.cssText=b,S.style.cssText=w,C.appendChild(D),E.appendChild(S),k.appendChild(C),k.appendChild(E),x.appendChild(k),n.appendChild(x),u(C,"scroll",O),u(E,"scroll",P),o(l).onExpandScroll=O,o(l).onShrinkScroll=P}else h("Aborting because element has been uninstalled");function O(){o(l).onExpand&&o(l).onExpand()}function P(){o(l).onShrink&&o(l).onShrink()}}function D(){function s(t,n,r){var o=function(e){return f(e).childNodes[0]}(t),i=w(n),s=x(r);o.style.setProperty("width",i+"px",e.important?"important":""),o.style.setProperty("height",s+"px",e.important?"important":"")}function a(r){var a=l.offsetWidth,u=l.offsetHeight,d=a!==o(l).lastWidth||u!==o(l).lastHeight;h("Storing current size",a,u),g(l,a,u),n.add(0,(function(){if(d)if(o(l))if(c()){if(e.debug){var n=l.offsetWidth,r=l.offsetHeight;n===a&&r===u||t.warn(i.get(l),"Scroll: Size changed before updating detector elements.")}s(l,a,u)}else h("Aborting because element container has not been initialized");else h("Aborting because element has been uninstalled")})),n.add(1,(function(){o(l)?c()?k(l,a,u):h("Aborting because element container has not been initialized"):h("Aborting because element has been uninstalled")})),d&&r&&n.add(2,(function(){o(l)?c()?r():h("Aborting because element container has not been initialized"):h("Aborting because element has been uninstalled")}))}function c(){return!!o(l).container}function u(){h("notifyListenersIfNeeded invoked");var e=o(l);return void 0===o(l).lastNotifiedWidth&&e.lastWidth===e.startSize.width&&e.lastHeight===e.startSize.height?h("Not notifying: Size is the same as the start size, and there has been no notification yet."):e.lastWidth===e.lastNotifiedWidth&&e.lastHeight===e.lastNotifiedHeight?h("Not notifying: Size already notified"):(h("Current size not notified, notifying..."),e.lastNotifiedWidth=e.lastWidth,e.lastNotifiedHeight=e.lastHeight,void r(o(l).listeners,(function(e){e(l)})))}function d(){h("Scroll detected."),m(l)?h("Scroll event fired while unrendered. Ignoring..."):a(u)}if(h("registerListenersAndPositionElements invoked."),o(l)){o(l).onRendered=function(){if(h("startanimation triggered."),m(l))h("Ignoring since element is still unrendered...");else{h("Element rendered.");var e=f(l),t=p(l);0!==e.scrollLeft&&0!==e.scrollTop&&0!==t.scrollLeft&&0!==t.scrollTop||(h("Scrollbars out of sync. Updating detector elements..."),a(u))}},o(l).onExpand=d,o(l).onShrink=d;var y=o(l).style;s(l,y.width,y.height)}else h("Aborting because element has been uninstalled")}function E(){if(h("finalizeDomMutation invoked."),o(l)){var e=o(l).style;g(l,e.width,e.height),k(l,e.width,e.height)}else h("Aborting because element has been uninstalled")}function S(){d(l)}function O(){var e;h("Installing..."),o(l).listeners=[],e=y(),o(l).startSize={width:e.width,height:e.height},h("Element start size",o(l).startSize),n.add(0,v),n.add(1,C),n.add(2,D),n.add(3,E),n.add(4,S)}d||(d=l,l=e,e=null),e=e||{},h("Making detectable..."),function(e){return!function(e){var t=e.getRootNode&&e.getRootNode().contains(e);return e===e.ownerDocument.body||e.ownerDocument.body.contains(e)||t}(e)||null===window.getComputedStyle(e)}(l)?(h("Element is detached"),j(),h("Waiting until element is attached..."),o(l).onRendered=function(){h("Element is now attached"),O()}):O()},addListener:function(e,t){if(!o(e).listeners.push)throw new Error("Cannot add listener to an element that is not detectable.");o(e).listeners.push(t)},uninstall:function(e){var t=o(e);t&&(t.onExpandScroll&&d(f(e),"scroll",t.onExpandScroll),t.onShrinkScroll&&d(p(e),"scroll",t.onShrinkScroll),t.onAnimationStart&&d(t.container,"animationstart",t.onAnimationStart),t.container&&e.removeChild(t.container))},initDocument:l}}},{"../collection-utils":120}],123:[function(e,t,n){"use strict";var r=e("./collection-utils").forEach,o=e("./element-utils"),i=e("./listener-handler"),s=e("./id-generator"),a=e("./id-handler"),l=e("./reporter"),c=e("./browser-detector"),u=e("batch-processor"),d=e("./state-handler"),f=e("./detection-strategy/object.js"),p=e("./detection-strategy/scroll.js");function h(e){return Array.isArray(e)||void 0!==e.length}function m(e){if(Array.isArray(e))return e;var t=[];return r(e,(function(e){t.push(e)})),t}function y(e){return e&&1===e.nodeType}function v(e,t,n){var r=e[t];return null==r&&void 0!==n?n:r}t.exports=function(e){var t;if((e=e||{}).idHandler)t={get:function(t){return e.idHandler.get(t,!0)},set:e.idHandler.set};else{var n=s(),g=a({idGenerator:n,stateHandler:d});t=g}var b=e.reporter;b||(b=l(!1===b));var _=v(e,"batchProcessor",u({reporter:b})),w={};w.callOnAdd=!!v(e,"callOnAdd",!0),w.debug=!!v(e,"debug",!1);var x,k=i(t),j=o({stateHandler:d}),C=v(e,"strategy","object"),D=v(e,"important",!1),E={reporter:b,batchProcessor:_,stateHandler:d,idHandler:t,important:D};if("scroll"===C&&(c.isLegacyOpera()?(b.warn("Scroll strategy is not supported on legacy Opera. Changing to object strategy."),C="object"):c.isIE(9)&&(b.warn("Scroll strategy is not supported on IE9. Changing to object strategy."),C="object")),"scroll"===C)x=p(E);else{if("object"!==C)throw new Error("Invalid strategy name: "+C);x=f(E)}var S={};return{listenTo:function(e,n,o){function i(e){var t=k.get(e);r(t,(function(t){t(e)}))}function s(e,t,n){k.add(t,n),e&&n(t)}if(o||(o=n,n=e,e={}),!n)throw new Error("At least one element required.");if(!o)throw new Error("Listener required.");if(y(n))n=[n];else{if(!h(n))return b.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");n=m(n)}var a=0,l=v(e,"callOnAdd",w.callOnAdd),c=v(e,"onReady",(function(){})),u=v(e,"debug",w.debug);r(n,(function(e){d.getState(e)||(d.initState(e),t.set(e));var f=t.get(e);if(u&&b.log("Attaching listener to element",f,e),!j.isDetectable(e))return u&&b.log(f,"Not detectable."),j.isBusy(e)?(u&&b.log(f,"System busy making it detectable"),s(l,e,o),S[f]=S[f]||[],void S[f].push((function(){++a===n.length&&c()}))):(u&&b.log(f,"Making detectable..."),j.markBusy(e,!0),x.makeDetectable({debug:u,important:D},e,(function(e){if(u&&b.log(f,"onElementDetectable"),d.getState(e)){j.markAsDetectable(e),j.markBusy(e,!1),x.addListener(e,i),s(l,e,o);var t=d.getState(e);if(t&&t.startSize){var p=e.offsetWidth,h=e.offsetHeight;t.startSize.width===p&&t.startSize.height===h||i(e)}S[f]&&r(S[f],(function(e){e()}))}else u&&b.log(f,"Element uninstalled before being detectable.");delete S[f],++a===n.length&&c()})));u&&b.log(f,"Already detecable, adding listener."),s(l,e,o),a++})),a===n.length&&c()},removeListener:k.removeListener,removeAllListeners:k.removeAllListeners,uninstall:function(e){if(!e)return b.error("At least one element is required.");if(y(e))e=[e];else{if(!h(e))return b.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");e=m(e)}r(e,(function(e){k.removeAllListeners(e),x.uninstall(e),d.cleanState(e)}))},initDocument:function(e){x.initDocument&&x.initDocument(e)}}}},{"./browser-detector":119,"./collection-utils":120,"./detection-strategy/object.js":121,"./detection-strategy/scroll.js":122,"./element-utils":124,"./id-generator":125,"./id-handler":126,"./listener-handler":127,"./reporter":128,"./state-handler":129,"batch-processor":1}],124:[function(e,t,n){"use strict";t.exports=function(e){var t=e.stateHandler.getState;return{isDetectable:function(e){var n=t(e);return n&&!!n.isDetectable},markAsDetectable:function(e){t(e).isDetectable=!0},isBusy:function(e){return!!t(e).busy},markBusy:function(e,n){t(e).busy=!!n}}}},{}],125:[function(e,t,n){"use strict";t.exports=function(){var e=1;return{generate:function(){return e++}}}},{}],126:[function(e,t,n){"use strict";t.exports=function(e){var t=e.idGenerator,n=e.stateHandler.getState;return{get:function(e){var t=n(e);return t&&void 0!==t.id?t.id:null},set:function(e){var r=n(e);if(!r)throw new Error("setId required the element to have a resize detection state.");var o=t.generate();return r.id=o,o}}}},{}],127:[function(e,t,n){"use strict";t.exports=function(e){var t={};function n(n){var r=e.get(n);return void 0===r?[]:t[r]||[]}return{get:n,add:function(n,r){var o=e.get(n);t[o]||(t[o]=[]),t[o].push(r)},removeListener:function(e,t){for(var r=n(e),o=0,i=r.length;o<i;++o)if(r[o]===t){r.splice(o,1);break}},removeAllListeners:function(e){var t=n(e);t&&(t.length=0)}}}},{}],128:[function(e,t,n){"use strict";t.exports=function(e){function t(){}var n={log:t,warn:t,error:t};if(!e&&window.console){var r=function(e,t){e[t]=function(){var e=console[t];if(e.apply)e.apply(console,arguments);else for(var n=0;n<arguments.length;n++)e(arguments[n])}};r(n,"log"),r(n,"warn"),r(n,"error")}return n}},{}],129:[function(e,t,n){"use strict";function r(e){return e._erd}t.exports={initState:function(e){return e._erd={},r(e)},getState:r,cleanState:function(e){delete e._erd}}},{}],130:[function(e,t,n){var r,o;r=window,o=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){"use strict";n.r(t);var r,o=function(e,t){var n=t.x-e.x,r=t.y-e.y;return Math.sqrt(n*n+r*r)},i=function(e){return e*(Math.PI/180)},s=new Map,a=function(e){s.has(e)&&clearTimeout(s.get(e)),s.set(e,setTimeout(e,100))},l=function(e,t,n){for(var r,o=t.split(/[ ,]+/g),i=0;i<o.length;i+=1)r=o[i],e.addEventListener?e.addEventListener(r,n,!1):e.attachEvent&&e.attachEvent(r,n)},c=function(e,t,n){for(var r,o=t.split(/[ ,]+/g),i=0;i<o.length;i+=1)r=o[i],e.removeEventListener?e.removeEventListener(r,n):e.detachEvent&&e.detachEvent(r,n)},u=function(e){return e.preventDefault(),e.type.match(/^touch/)?e.changedTouches:e},d=function(){return{x:void 0!==window.pageXOffset?window.pageXOffset:(document.documentElement||document.body.parentNode||document.body).scrollLeft,y:void 0!==window.pageYOffset?window.pageYOffset:(document.documentElement||document.body.parentNode||document.body).scrollTop}},f=function(e,t){t.top||t.right||t.bottom||t.left?(e.style.top=t.top,e.style.right=t.right,e.style.bottom=t.bottom,e.style.left=t.left):(e.style.left=t.x+"px",e.style.top=t.y+"px")},p=function(e,t,n){var r=h(e);for(var o in r)if(r.hasOwnProperty(o))if("string"==typeof t)r[o]=t+" "+n;else{for(var i="",s=0,a=t.length;s<a;s+=1)i+=t[s]+" "+n+", ";r[o]=i.slice(0,-2)}return r},h=function(e){var t={};return t[e]="",["webkit","Moz","o"].forEach((function(n){t[n+e.charAt(0).toUpperCase()+e.slice(1)]=""})),t},m=function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e},y=function(e,t){if(e.length)for(var n=0,r=e.length;n<r;n+=1)t(e[n]);else t(e)},v=!!("ontouchstart"in window),g=!!window.PointerEvent,b=!!window.MSPointerEvent,_={start:"mousedown",move:"mousemove",end:"mouseup"},w={};function x(){}g?r={start:"pointerdown",move:"pointermove",end:"pointerup, pointercancel"}:b?r={start:"MSPointerDown",move:"MSPointerMove",end:"MSPointerUp"}:v?(r={start:"touchstart",move:"touchmove",end:"touchend, touchcancel"},w=_):r=_,x.prototype.on=function(e,t){var n,r=e.split(/[ ,]+/g);this._handlers_=this._handlers_||{};for(var o=0;o<r.length;o+=1)n=r[o],this._handlers_[n]=this._handlers_[n]||[],this._handlers_[n].push(t);return this},x.prototype.off=function(e,t){return this._handlers_=this._handlers_||{},void 0===e?this._handlers_={}:void 0===t?this._handlers_[e]=null:this._handlers_[e]&&this._handlers_[e].indexOf(t)>=0&&this._handlers_[e].splice(this._handlers_[e].indexOf(t),1),this},x.prototype.trigger=function(e,t){var n,r=this,o=e.split(/[ ,]+/g);r._handlers_=r._handlers_||{};for(var i=0;i<o.length;i+=1)n=o[i],r._handlers_[n]&&r._handlers_[n].length&&r._handlers_[n].forEach((function(e){e.call(r,{type:n,target:r},t)}))},x.prototype.config=function(e){this.options=this.defaults||{},e&&(this.options=function(e,t){var n={};for(var r in e)e.hasOwnProperty(r)&&t.hasOwnProperty(r)?n[r]=t[r]:e.hasOwnProperty(r)&&(n[r]=e[r]);return n}(this.options,e))},x.prototype.bindEvt=function(e,t){var n=this;return n._domHandlers_=n._domHandlers_||{},n._domHandlers_[t]=function(){"function"==typeof n["on"+t]?n["on"+t].apply(n,arguments):console.warn('[WARNING] : Missing "on'+t+'" handler.')},l(e,r[t],n._domHandlers_[t]),w[t]&&l(e,w[t],n._domHandlers_[t]),n},x.prototype.unbindEvt=function(e,t){return this._domHandlers_=this._domHandlers_||{},c(e,r[t],this._domHandlers_[t]),w[t]&&c(e,w[t],this._domHandlers_[t]),delete this._domHandlers_[t],this};var k=x;function j(e,t){return this.identifier=t.identifier,this.position=t.position,this.frontPosition=t.frontPosition,this.collection=e,this.defaults={size:100,threshold:.1,color:"white",fadeTime:250,dataOnly:!1,restJoystick:!0,restOpacity:.5,mode:"dynamic",zone:document.body,lockX:!1,lockY:!1,shape:"circle"},this.config(t),"dynamic"===this.options.mode&&(this.options.restOpacity=0),this.id=j.id,j.id+=1,this.buildEl().stylize(),this.instance={el:this.ui.el,on:this.on.bind(this),off:this.off.bind(this),show:this.show.bind(this),hide:this.hide.bind(this),add:this.addToDom.bind(this),remove:this.removeFromDom.bind(this),destroy:this.destroy.bind(this),setPosition:this.setPosition.bind(this),resetDirection:this.resetDirection.bind(this),computeDirection:this.computeDirection.bind(this),trigger:this.trigger.bind(this),position:this.position,frontPosition:this.frontPosition,ui:this.ui,identifier:this.identifier,id:this.id,options:this.options},this.instance}j.prototype=new k,j.constructor=j,j.id=0,j.prototype.buildEl=function(e){return this.ui={},this.options.dataOnly||(this.ui.el=document.createElement("div"),this.ui.back=document.createElement("div"),this.ui.front=document.createElement("div"),this.ui.el.className="nipple collection_"+this.collection.id,this.ui.back.className="back",this.ui.front.className="front",this.ui.el.setAttribute("id","nipple_"+this.collection.id+"_"+this.id),this.ui.el.appendChild(this.ui.back),this.ui.el.appendChild(this.ui.front)),this},j.prototype.stylize=function(){if(this.options.dataOnly)return this;var e=this.options.fadeTime+"ms",t=function(e,t){var n=h("borderRadius");for(var r in n)n.hasOwnProperty(r)&&(n[r]="50%");return n}(),n=p("transition","opacity",e),r={};return r.el={position:"absolute",opacity:this.options.restOpacity,display:"block",zIndex:999},r.back={position:"absolute",display:"block",width:this.options.size+"px",height:this.options.size+"px",marginLeft:-this.options.size/2+"px",marginTop:-this.options.size/2+"px",background:this.options.color,opacity:".5"},r.front={width:this.options.size/2+"px",height:this.options.size/2+"px",position:"absolute",display:"block",marginLeft:-this.options.size/4+"px",marginTop:-this.options.size/4+"px",background:this.options.color,opacity:".5"},m(r.el,n),"circle"===this.options.shape&&m(r.back,t),m(r.front,t),this.applyStyles(r),this},j.prototype.applyStyles=function(e){for(var t in this.ui)if(this.ui.hasOwnProperty(t))for(var n in e[t])this.ui[t].style[n]=e[t][n];return this},j.prototype.addToDom=function(){return this.options.dataOnly||document.body.contains(this.ui.el)||this.options.zone.appendChild(this.ui.el),this},j.prototype.removeFromDom=function(){return this.options.dataOnly||!document.body.contains(this.ui.el)||this.options.zone.removeChild(this.ui.el),this},j.prototype.destroy=function(){clearTimeout(this.removeTimeout),clearTimeout(this.showTimeout),clearTimeout(this.restTimeout),this.trigger("destroyed",this.instance),this.removeFromDom(),this.off()},j.prototype.show=function(e){var t=this;return t.options.dataOnly||(clearTimeout(t.removeTimeout),clearTimeout(t.showTimeout),clearTimeout(t.restTimeout),t.addToDom(),t.restCallback(),setTimeout((function(){t.ui.el.style.opacity=1}),0),t.showTimeout=setTimeout((function(){t.trigger("shown",t.instance),"function"==typeof e&&e.call(this)}),t.options.fadeTime)),t},j.prototype.hide=function(e){var t=this;return t.options.dataOnly||(t.ui.el.style.opacity=t.options.restOpacity,clearTimeout(t.removeTimeout),clearTimeout(t.showTimeout),clearTimeout(t.restTimeout),t.removeTimeout=setTimeout((function(){var n="dynamic"===t.options.mode?"none":"block";t.ui.el.style.display=n,"function"==typeof e&&e.call(t),t.trigger("hidden",t.instance)}),t.options.fadeTime),t.options.restJoystick&&t.setPosition(e,{x:0,y:0})),t},j.prototype.setPosition=function(e,t){var n=this;n.frontPosition={x:t.x,y:t.y};var r=n.options.fadeTime+"ms",o={};o.front=p("transition",["top","left"],r);var i={front:{}};i.front={left:n.frontPosition.x+"px",top:n.frontPosition.y+"px"},n.applyStyles(o),n.applyStyles(i),n.restTimeout=setTimeout((function(){"function"==typeof e&&e.call(n),n.restCallback()}),n.options.fadeTime)},j.prototype.restCallback=function(){var e={};e.front=p("transition","none",""),this.applyStyles(e),this.trigger("rested",this.instance)},j.prototype.resetDirection=function(){this.direction={x:!1,y:!1,angle:!1}},j.prototype.computeDirection=function(e){var t,n,r,o=e.angle.radian,i=Math.PI/4,s=Math.PI/2;if(o>i&&o<3*i&&!e.lockX?t="up":o>-i&&o<=i&&!e.lockY?t="left":o>3*-i&&o<=-i&&!e.lockX?t="down":e.lockY||(t="right"),e.lockY||(n=o>-s&&o<s?"left":"right"),e.lockX||(r=o>0?"up":"down"),e.force>this.options.threshold){var a,l={};for(a in this.direction)this.direction.hasOwnProperty(a)&&(l[a]=this.direction[a]);var c={};for(a in this.direction={x:n,y:r,angle:t},e.direction=this.direction,l)l[a]===this.direction[a]&&(c[a]=!0);if(c.x&&c.y&&c.angle)return e;c.x&&c.y||this.trigger("plain",e),c.x||this.trigger("plain:"+n,e),c.y||this.trigger("plain:"+r,e),c.angle||this.trigger("dir dir:"+t,e)}else this.resetDirection();return e};var C=j;function D(e,t){return this.nipples=[],this.idles=[],this.actives=[],this.ids=[],this.pressureIntervals={},this.manager=e,this.id=D.id,D.id+=1,this.defaults={zone:document.body,multitouch:!1,maxNumberOfNipples:10,mode:"dynamic",position:{top:0,left:0},catchDistance:200,size:100,threshold:.1,color:"white",fadeTime:250,dataOnly:!1,restJoystick:!0,restOpacity:.5,lockX:!1,lockY:!1,shape:"circle",dynamicPage:!1,follow:!1},this.config(t),"static"!==this.options.mode&&"semi"!==this.options.mode||(this.options.multitouch=!1),this.options.multitouch||(this.options.maxNumberOfNipples=1),this.updateBox(),this.prepareNipples(),this.bindings(),this.begin(),this.nipples}D.prototype=new k,D.constructor=D,D.id=0,D.prototype.prepareNipples=function(){var e=this.nipples;e.on=this.on.bind(this),e.off=this.off.bind(this),e.options=this.options,e.destroy=this.destroy.bind(this),e.ids=this.ids,e.id=this.id,e.processOnMove=this.processOnMove.bind(this),e.processOnEnd=this.processOnEnd.bind(this),e.get=function(t){if(void 0===t)return e[0];for(var n=0,r=e.length;n<r;n+=1)if(e[n].identifier===t)return e[n];return!1}},D.prototype.bindings=function(){this.bindEvt(this.options.zone,"start"),this.options.zone.style.touchAction="none",this.options.zone.style.msTouchAction="none"},D.prototype.begin=function(){var e=this.options;if("static"===e.mode){var t=this.createNipple(e.position,this.manager.getIdentifier());t.add(),this.idles.push(t)}},D.prototype.createNipple=function(e,t){var n=this.manager.scroll,r={},o=this.options;if(e.x&&e.y)r={x:e.x-(n.x+this.box.left),y:e.y-(n.y+this.box.top)};else if(e.top||e.right||e.bottom||e.left){var i=document.createElement("DIV");i.style.display="hidden",i.style.top=e.top,i.style.right=e.right,i.style.bottom=e.bottom,i.style.left=e.left,i.style.position="absolute",o.zone.appendChild(i);var s=i.getBoundingClientRect();o.zone.removeChild(i),r=e,e={x:s.left+n.x,y:s.top+n.y}}var a=new C(this,{color:o.color,size:o.size,threshold:o.threshold,fadeTime:o.fadeTime,dataOnly:o.dataOnly,restJoystick:o.restJoystick,restOpacity:o.restOpacity,mode:o.mode,identifier:t,position:e,zone:o.zone,frontPosition:{x:0,y:0},shape:o.shape});return o.dataOnly||(f(a.ui.el,r),f(a.ui.front,a.frontPosition)),this.nipples.push(a),this.trigger("added "+a.identifier+":added",a),this.manager.trigger("added "+a.identifier+":added",a),this.bindNipple(a),a},D.prototype.updateBox=function(){this.box=this.options.zone.getBoundingClientRect()},D.prototype.bindNipple=function(e){var t,n=this,r=function(e,r){t=e.type+" "+r.id+":"+e.type,n.trigger(t,r)};e.on("destroyed",n.onDestroyed.bind(n)),e.on("shown hidden rested dir plain",r),e.on("dir:up dir:right dir:down dir:left",r),e.on("plain:up plain:right plain:down plain:left",r)},D.prototype.pressureFn=function(e,t,n){var r=this,o=0;clearInterval(r.pressureIntervals[n]),r.pressureIntervals[n]=setInterval(function(){var n=e.force||e.pressure||e.webkitForce||0;n!==o&&(t.trigger("pressure",n),r.trigger("pressure "+t.identifier+":pressure",n),o=n)}.bind(r),100)},D.prototype.onstart=function(e){var t=this,n=t.options,r=e;return e=u(e),t.updateBox(),y(e,(function(o){t.actives.length<n.maxNumberOfNipples?t.processOnStart(o):r.type.match(/^touch/)&&(Object.keys(t.manager.ids).forEach((function(n){if(Object.values(r.touches).findIndex((function(e){return e.identifier===n}))<0){var o=[e[0]];o.identifier=n,t.processOnEnd(o)}})),t.actives.length<n.maxNumberOfNipples&&t.processOnStart(o))})),t.manager.bindDocument(),!1},D.prototype.processOnStart=function(e){var t,n=this,r=n.options,i=n.manager.getIdentifier(e),s=e.force||e.pressure||e.webkitForce||0,a={x:e.pageX,y:e.pageY},l=n.getOrCreate(i,a);l.identifier!==i&&n.manager.removeIdentifier(l.identifier),l.identifier=i;var c=function(t){t.trigger("start",t),n.trigger("start "+t.id+":start",t),t.show(),s>0&&n.pressureFn(e,t,t.identifier),n.processOnMove(e)};if((t=n.idles.indexOf(l))>=0&&n.idles.splice(t,1),n.actives.push(l),n.ids.push(l.identifier),"semi"!==r.mode)c(l);else{if(!(o(a,l.position)<=r.catchDistance))return l.destroy(),void n.processOnStart(e);c(l)}return l},D.prototype.getOrCreate=function(e,t){var n,r=this.options;return/(semi|static)/.test(r.mode)?(n=this.idles[0])?(this.idles.splice(0,1),n):"semi"===r.mode?this.createNipple(t,e):(console.warn("Coudln't find the needed nipple."),!1):n=this.createNipple(t,e)},D.prototype.processOnMove=function(e){var t=this.options,n=this.manager.getIdentifier(e),r=this.nipples.get(n),s=this.manager.scroll;if(function(e){return isNaN(e.buttons)?0!==e.pressure:0!==e.buttons}(e)){if(!r)return console.error("Found zombie joystick with ID "+n),void this.manager.removeIdentifier(n);if(t.dynamicPage){var a=r.el.getBoundingClientRect();r.position={x:s.x+a.left,y:s.y+a.top}}r.identifier=n;var l=r.options.size/2,c={x:e.pageX,y:e.pageY};t.lockX&&(c.y=r.position.y),t.lockY&&(c.x=r.position.x);var u,d,p,h,m,y,v,g,b,_,w=o(c,r.position),x=(u=c,p=(d=r.position).x-u.x,h=d.y-u.y,function(e){return e*(180/Math.PI)}(Math.atan2(h,p))),k=i(x),j=w/l,C={distance:w,position:c};if("circle"===r.options.shape?(m=Math.min(w,l),v=r.position,g=m,_={x:0,y:0},b=i(b=x),_.x=v.x-g*Math.cos(b),_.y=v.y-g*Math.sin(b),y=_):(y=function(e,t,n){return{x:Math.min(Math.max(e.x,t.x-n),t.x+n),y:Math.min(Math.max(e.y,t.y-n),t.y+n)}}(c,r.position,l),m=o(y,r.position)),t.follow){if(w>l){var D=c.x-y.x,E=c.y-y.y;r.position.x+=D,r.position.y+=E,r.el.style.top=r.position.y-(this.box.top+s.y)+"px",r.el.style.left=r.position.x-(this.box.left+s.x)+"px",w=o(c,r.position)}}else c=y,w=m;var S=c.x-r.position.x,O=c.y-r.position.y;r.frontPosition={x:S,y:O},t.dataOnly||f(r.ui.front,r.frontPosition);var P={identifier:r.identifier,position:c,force:j,pressure:e.force||e.pressure||e.webkitForce||0,distance:w,angle:{radian:k,degree:x},vector:{x:S/l,y:-O/l},raw:C,instance:r,lockX:t.lockX,lockY:t.lockY};(P=r.computeDirection(P)).angle={radian:i(180-x),degree:180-x},r.trigger("move",P),this.trigger("move "+r.id+":move",P)}else this.processOnEnd(e)},D.prototype.processOnEnd=function(e){var t=this,n=t.options,r=t.manager.getIdentifier(e),o=t.nipples.get(r),i=t.manager.removeIdentifier(o.identifier);o&&(n.dataOnly||o.hide((function(){"dynamic"===n.mode&&(o.trigger("removed",o),t.trigger("removed "+o.id+":removed",o),t.manager.trigger("removed "+o.id+":removed",o),o.destroy())})),clearInterval(t.pressureIntervals[o.identifier]),o.resetDirection(),o.trigger("end",o),t.trigger("end "+o.id+":end",o),t.ids.indexOf(o.identifier)>=0&&t.ids.splice(t.ids.indexOf(o.identifier),1),t.actives.indexOf(o)>=0&&t.actives.splice(t.actives.indexOf(o),1),/(semi|static)/.test(n.mode)?t.idles.push(o):t.nipples.indexOf(o)>=0&&t.nipples.splice(t.nipples.indexOf(o),1),t.manager.unbindDocument(),/(semi|static)/.test(n.mode)&&(t.manager.ids[i.id]=i.identifier))},D.prototype.onDestroyed=function(e,t){this.nipples.indexOf(t)>=0&&this.nipples.splice(this.nipples.indexOf(t),1),this.actives.indexOf(t)>=0&&this.actives.splice(this.actives.indexOf(t),1),this.idles.indexOf(t)>=0&&this.idles.splice(this.idles.indexOf(t),1),this.ids.indexOf(t.identifier)>=0&&this.ids.splice(this.ids.indexOf(t.identifier),1),this.manager.removeIdentifier(t.identifier),this.manager.unbindDocument()},D.prototype.destroy=function(){for(var e in this.unbindEvt(this.options.zone,"start"),this.nipples.forEach((function(e){e.destroy()})),this.pressureIntervals)this.pressureIntervals.hasOwnProperty(e)&&clearInterval(this.pressureIntervals[e]);this.trigger("destroyed",this.nipples),this.manager.unbindDocument(),this.off()};var E=D;function S(e){var t=this;t.ids={},t.index=0,t.collections=[],t.scroll=d(),t.config(e),t.prepareCollections();var n=function(){var e;t.collections.forEach((function(n){n.forEach((function(n){e=n.el.getBoundingClientRect(),n.position={x:t.scroll.x+e.left,y:t.scroll.y+e.top}}))}))};l(window,"resize",(function(){a(n)}));var r=function(){t.scroll=d()};return l(window,"scroll",(function(){a(r)})),t.collections}S.prototype=new k,S.constructor=S,S.prototype.prepareCollections=function(){var e=this;e.collections.create=e.create.bind(e),e.collections.on=e.on.bind(e),e.collections.off=e.off.bind(e),e.collections.destroy=e.destroy.bind(e),e.collections.get=function(t){var n;return e.collections.every((function(e){return!(n=e.get(t))})),n}},S.prototype.create=function(e){return this.createCollection(e)},S.prototype.createCollection=function(e){var t=new E(this,e);return this.bindCollection(t),this.collections.push(t),t},S.prototype.bindCollection=function(e){var t,n=this,r=function(e,r){t=e.type+" "+r.id+":"+e.type,n.trigger(t,r)};e.on("destroyed",n.onDestroyed.bind(n)),e.on("shown hidden rested dir plain",r),e.on("dir:up dir:right dir:down dir:left",r),e.on("plain:up plain:right plain:down plain:left",r)},S.prototype.bindDocument=function(){this.binded||(this.bindEvt(document,"move").bindEvt(document,"end"),this.binded=!0)},S.prototype.unbindDocument=function(e){Object.keys(this.ids).length&&!0!==e||(this.unbindEvt(document,"move").unbindEvt(document,"end"),this.binded=!1)},S.prototype.getIdentifier=function(e){var t;return e?void 0===(t=void 0===e.identifier?e.pointerId:e.identifier)&&(t=this.latest||0):t=this.index,void 0===this.ids[t]&&(this.ids[t]=this.index,this.index+=1),this.latest=t,this.ids[t]},S.prototype.removeIdentifier=function(e){var t={};for(var n in this.ids)if(this.ids[n]===e){t.id=n,t.identifier=this.ids[n],delete this.ids[n];break}return t},S.prototype.onmove=function(e){return this.onAny("move",e),!1},S.prototype.onend=function(e){return this.onAny("end",e),!1},S.prototype.oncancel=function(e){return this.onAny("end",e),!1},S.prototype.onAny=function(e,t){var n,r=this,o="processOn"+e.charAt(0).toUpperCase()+e.slice(1);return t=u(t),y(t,(function(e){n=r.getIdentifier(e),y(r.collections,function(e,t,n){n.ids.indexOf(t)>=0&&(n[o](e),e._found_=!0)}.bind(null,e,n)),e._found_||r.removeIdentifier(n)})),!1},S.prototype.destroy=function(){this.unbindDocument(!0),this.ids={},this.index=0,this.collections.forEach((function(e){e.destroy()})),this.off()},S.prototype.onDestroyed=function(e,t){if(this.collections.indexOf(t)<0)return!1;this.collections.splice(this.collections.indexOf(t),1)};var O=new S;t.default={create:function(e){return O.create(e)},factory:O}}]).default},"object"==typeof n&&"object"==typeof t?t.exports=o():"function"==typeof define&&define.amd?define("nipplejs",[],o):"object"==typeof n?n.nipplejs=o():r.nipplejs=o()},{}],131:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});
1
+ !function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(i)return i(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i="function"==typeof require&&require,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(e,t,n){"use strict";var r=e("./utils");function o(){var e={},t=0,n=0,r=0;return{add:function(o,i){i||(i=o,o=0),o>n?n=o:o<r&&(r=o),e[o]||(e[o]=[]),e[o].push(i),t++},process:function(){for(var t=r;t<=n;t++)for(var o=e[t],i=0;i<o.length;i++)(0,o[i])()},size:function(){return t}}}t.exports=function(e){var t=(e=e||{}).reporter,n=r.getOption(e,"async",!0),i=r.getOption(e,"auto",!0);i&&!n&&(t&&t.warn("Invalid options combination. auto=true and async=false is invalid. Setting async=true."),n=!0);var s,a=o(),l=!1;function c(){for(l=!0;a.size();){var e=a;a=o(),e.process()}l=!1}function u(){s=setTimeout(c,0)}return{add:function(e,t){!l&&i&&n&&0===a.size()&&u(),a.add(e,t)},force:function(e){l||(void 0===e&&(e=n),s&&(clearTimeout(s),s=null),e?u():c())}}}},{"./utils":2}],2:[function(e,t,n){"use strict";(t.exports={}).getOption=function(e,t,n){var r=e[t];return null==r&&void 0!==n?n:r}},{}],3:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/try-to-string"),s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not a function")}},{"../internals/global":48,"../internals/is-callable":60,"../internals/try-to-string":106}],4:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-constructor"),i=e("../internals/try-to-string"),s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not a constructor")}},{"../internals/global":48,"../internals/is-constructor":61,"../internals/try-to-string":106}],5:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=r.String,s=r.TypeError;t.exports=function(e){if("object"==typeof e||o(e))return e;throw s("Can't set "+i(e)+" as a prototype")}},{"../internals/global":48,"../internals/is-callable":60}],6:[function(e,t,n){var r=e("../internals/well-known-symbol"),o=e("../internals/object-create"),i=e("../internals/object-define-property"),s=r("unscopables"),a=Array.prototype;null==a[s]&&i.f(a,s,{configurable:!0,value:o(null)}),t.exports=function(e){a[s][e]=!0}},{"../internals/object-create":72,"../internals/object-define-property":74,"../internals/well-known-symbol":112}],7:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/object-is-prototype-of"),i=r.TypeError;t.exports=function(e,t){if(o(t,e))return e;throw i("Incorrect invocation")}},{"../internals/global":48,"../internals/object-is-prototype-of":79}],8:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-object"),i=r.String,s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not an object")}},{"../internals/global":48,"../internals/is-object":64}],9:[function(e,t,n){t.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},{}],10:[function(e,t,n){"use strict";var r,o,i,s=e("../internals/array-buffer-native"),a=e("../internals/descriptors"),l=e("../internals/global"),c=e("../internals/is-callable"),u=e("../internals/is-object"),d=e("../internals/has-own-property"),f=e("../internals/classof"),p=e("../internals/try-to-string"),h=e("../internals/create-non-enumerable-property"),m=e("../internals/redefine"),y=e("../internals/object-define-property").f,g=e("../internals/object-is-prototype-of"),v=e("../internals/object-get-prototype-of"),b=e("../internals/object-set-prototype-of"),_=e("../internals/well-known-symbol"),w=e("../internals/uid"),x=l.Int8Array,k=x&&x.prototype,j=l.Uint8ClampedArray,C=j&&j.prototype,E=x&&v(x),D=k&&v(k),S=Object.prototype,O=l.TypeError,P=_("toStringTag"),B=w("TYPED_ARRAY_TAG"),M=w("TYPED_ARRAY_CONSTRUCTOR"),T=s&&!!b&&"Opera"!==f(l.opera),A=!1,I={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},K={BigInt64Array:8,BigUint64Array:8},L=function(e){if(!u(e))return!1;var t=f(e);return d(I,t)||d(K,t)};for(r in I)(i=(o=l[r])&&o.prototype)?h(i,M,o):T=!1;for(r in K)(i=(o=l[r])&&o.prototype)&&h(i,M,o);if((!T||!c(E)||E===Function.prototype)&&(E=function(){throw O("Incorrect invocation")},T))for(r in I)l[r]&&b(l[r],E);if((!T||!D||D===S)&&(D=E.prototype,T))for(r in I)l[r]&&b(l[r].prototype,D);if(T&&v(C)!==D&&b(C,D),a&&!d(D,P))for(r in A=!0,y(D,P,{get:function(){return u(this)?this[B]:void 0}}),I)l[r]&&h(l[r],B,r);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:T,TYPED_ARRAY_CONSTRUCTOR:M,TYPED_ARRAY_TAG:A&&B,aTypedArray:function(e){if(L(e))return e;throw O("Target is not a typed array")},aTypedArrayConstructor:function(e){if(c(e)&&(!b||g(E,e)))return e;throw O(p(e)+" is not a typed array constructor")},exportTypedArrayMethod:function(e,t,n){if(a){if(n)for(var r in I){var o=l[r];if(o&&d(o.prototype,e))try{delete o.prototype[e]}catch(e){}}D[e]&&!n||m(D,e,n?t:T&&k[e]||t)}},exportTypedArrayStaticMethod:function(e,t,n){var r,o;if(a){if(b){if(n)for(r in I)if((o=l[r])&&d(o,e))try{delete o[e]}catch(e){}if(E[e]&&!n)return;try{return m(E,e,n?t:T&&E[e]||t)}catch(e){}}for(r in I)!(o=l[r])||o[e]&&!n||m(o,e,t)}},isView:function(e){if(!u(e))return!1;var t=f(e);return"DataView"===t||d(I,t)||d(K,t)},isTypedArray:L,TypedArray:E,TypedArrayPrototype:D}},{"../internals/array-buffer-native":9,"../internals/classof":21,"../internals/create-non-enumerable-property":25,"../internals/descriptors":28,"../internals/global":48,"../internals/has-own-property":49,"../internals/is-callable":60,"../internals/is-object":64,"../internals/object-define-property":74,"../internals/object-get-prototype-of":78,"../internals/object-is-prototype-of":79,"../internals/object-set-prototype-of":83,"../internals/redefine":87,"../internals/try-to-string":106,"../internals/uid":110,"../internals/well-known-symbol":112}],11:[function(e,t,n){"use strict";var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=e("../internals/descriptors"),s=e("../internals/array-buffer-native"),a=e("../internals/function-name"),l=e("../internals/create-non-enumerable-property"),c=e("../internals/redefine-all"),u=e("../internals/fails"),d=e("../internals/an-instance"),f=e("../internals/to-integer-or-infinity"),p=e("../internals/to-length"),h=e("../internals/to-index"),m=e("../internals/ieee754"),y=e("../internals/object-get-prototype-of"),g=e("../internals/object-set-prototype-of"),v=e("../internals/object-get-own-property-names").f,b=e("../internals/object-define-property").f,_=e("../internals/array-fill"),w=e("../internals/array-slice"),x=e("../internals/set-to-string-tag"),k=e("../internals/internal-state"),j=a.PROPER,C=a.CONFIGURABLE,E=k.get,D=k.set,S="ArrayBuffer",O="Wrong index",P=r.ArrayBuffer,B=P,M=B&&B.prototype,T=r.DataView,A=T&&T.prototype,I=Object.prototype,K=r.Array,L=r.RangeError,R=o(_),N=o([].reverse),F=m.pack,U=m.unpack,z=function(e){return[255&e]},H=function(e){return[255&e,e>>8&255]},W=function(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]},q=function(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]},V=function(e){return F(e,23,4)},G=function(e){return F(e,52,8)},Y=function(e,t){b(e.prototype,t,{get:function(){return E(this)[t]}})},X=function(e,t,n,r){var o=h(n),i=E(e);if(o+t>i.byteLength)throw L(O);var s=E(i.buffer).bytes,a=o+i.byteOffset,l=w(s,a,a+t);return r?l:N(l)},$=function(e,t,n,r,o,i){var s=h(n),a=E(e);if(s+t>a.byteLength)throw L(O);for(var l=E(a.buffer).bytes,c=s+a.byteOffset,u=r(+o),d=0;d<t;d++)l[c+d]=u[i?d:t-d-1]};if(s){var J=j&&P.name!==S;if(u((function(){P(1)}))&&u((function(){new P(-1)}))&&!u((function(){return new P,new P(1.5),new P(NaN),J&&!C})))J&&C&&l(P,"name",S);else{(B=function(e){return d(this,M),new P(h(e))}).prototype=M;for(var Q,Z=v(P),ee=0;Z.length>ee;)(Q=Z[ee++])in B||l(B,Q,P[Q]);M.constructor=B}g&&y(A)!==I&&g(A,I);var te=new T(new B(2)),ne=o(A.setInt8);te.setInt8(0,2147483648),te.setInt8(1,2147483649),!te.getInt8(0)&&te.getInt8(1)||c(A,{setInt8:function(e,t){ne(this,e,t<<24>>24)},setUint8:function(e,t){ne(this,e,t<<24>>24)}},{unsafe:!0})}else M=(B=function(e){d(this,M);var t=h(e);D(this,{bytes:R(K(t),0),byteLength:t}),i||(this.byteLength=t)}).prototype,A=(T=function(e,t,n){d(this,A),d(e,M);var r=E(e).byteLength,o=f(t);if(o<0||o>r)throw L("Wrong offset");if(o+(n=void 0===n?r-o:p(n))>r)throw L("Wrong length");D(this,{buffer:e,byteLength:n,byteOffset:o}),i||(this.buffer=e,this.byteLength=n,this.byteOffset=o)}).prototype,i&&(Y(B,"byteLength"),Y(T,"buffer"),Y(T,"byteLength"),Y(T,"byteOffset")),c(A,{getInt8:function(e){return X(this,1,e)[0]<<24>>24},getUint8:function(e){return X(this,1,e)[0]},getInt16:function(e){var t=X(this,2,e,arguments.length>1?arguments[1]:void 0);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=X(this,2,e,arguments.length>1?arguments[1]:void 0);return t[1]<<8|t[0]},getInt32:function(e){return q(X(this,4,e,arguments.length>1?arguments[1]:void 0))},getUint32:function(e){return q(X(this,4,e,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(e){return U(X(this,4,e,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(e){return U(X(this,8,e,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(e,t){$(this,1,e,z,t)},setUint8:function(e,t){$(this,1,e,z,t)},setInt16:function(e,t){$(this,2,e,H,t,arguments.length>2?arguments[2]:void 0)},setUint16:function(e,t){$(this,2,e,H,t,arguments.length>2?arguments[2]:void 0)},setInt32:function(e,t){$(this,4,e,W,t,arguments.length>2?arguments[2]:void 0)},setUint32:function(e,t){$(this,4,e,W,t,arguments.length>2?arguments[2]:void 0)},setFloat32:function(e,t){$(this,4,e,V,t,arguments.length>2?arguments[2]:void 0)},setFloat64:function(e,t){$(this,8,e,G,t,arguments.length>2?arguments[2]:void 0)}});x(B,S),x(T,"DataView"),t.exports={ArrayBuffer:B,DataView:T}},{"../internals/an-instance":7,"../internals/array-buffer-native":9,"../internals/array-fill":12,"../internals/array-slice":15,"../internals/create-non-enumerable-property":25,"../internals/descriptors":28,"../internals/fails":39,"../internals/function-name":42,"../internals/function-uncurry-this":43,"../internals/global":48,"../internals/ieee754":53,"../internals/internal-state":57,"../internals/object-define-property":74,"../internals/object-get-own-property-names":76,"../internals/object-get-prototype-of":78,"../internals/object-set-prototype-of":83,"../internals/redefine-all":86,"../internals/set-to-string-tag":91,"../internals/to-index":96,"../internals/to-integer-or-infinity":98,"../internals/to-length":99}],12:[function(e,t,n){"use strict";var r=e("../internals/to-object"),o=e("../internals/to-absolute-index"),i=e("../internals/length-of-array-like");t.exports=function(e){for(var t=r(this),n=i(t),s=arguments.length,a=o(s>1?arguments[1]:void 0,n),l=s>2?arguments[2]:void 0,c=void 0===l?n:o(l,n);c>a;)t[a++]=e;return t}},{"../internals/length-of-array-like":69,"../internals/to-absolute-index":95,"../internals/to-object":100}],13:[function(e,t,n){var r=e("../internals/to-indexed-object"),o=e("../internals/to-absolute-index"),i=e("../internals/length-of-array-like"),s=function(e){return function(t,n,s){var a,l=r(t),c=i(l),u=o(s,c);if(e&&n!=n){for(;c>u;)if((a=l[u++])!=a)return!0}else for(;c>u;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},{"../internals/length-of-array-like":69,"../internals/to-absolute-index":95,"../internals/to-indexed-object":97}],14:[function(e,t,n){var r=e("../internals/function-bind-context"),o=e("../internals/function-uncurry-this"),i=e("../internals/indexed-object"),s=e("../internals/to-object"),a=e("../internals/length-of-array-like"),l=e("../internals/array-species-create"),c=o([].push),u=function(e){var t=1==e,n=2==e,o=3==e,u=4==e,d=6==e,f=7==e,p=5==e||d;return function(h,m,y,g){for(var v,b,_=s(h),w=i(_),x=r(m,y),k=a(w),j=0,C=g||l,E=t?C(h,k):n||f?C(h,0):void 0;k>j;j++)if((p||j in w)&&(b=x(v=w[j],j,_),e))if(t)E[j]=b;else if(b)switch(e){case 3:return!0;case 5:return v;case 6:return j;case 2:c(E,v)}else switch(e){case 4:return!1;case 7:c(E,v)}return d?-1:o||u?u:E}};t.exports={forEach:u(0),map:u(1),filter:u(2),some:u(3),every:u(4),find:u(5),findIndex:u(6),filterReject:u(7)}},{"../internals/array-species-create":18,"../internals/function-bind-context":40,"../internals/function-uncurry-this":43,"../internals/indexed-object":54,"../internals/length-of-array-like":69,"../internals/to-object":100}],15:[function(e,t,n){var r=e("../internals/function-uncurry-this");t.exports=r([].slice)},{"../internals/function-uncurry-this":43}],16:[function(e,t,n){var r=e("../internals/array-slice"),o=Math.floor,i=function(e,t){var n=e.length,l=o(n/2);return n<8?s(e,t):a(e,i(r(e,0,l),t),i(r(e,l),t),t)},s=function(e,t){for(var n,r,o=e.length,i=1;i<o;){for(r=i,n=e[i];r&&t(e[r-1],n)>0;)e[r]=e[--r];r!==i++&&(e[r]=n)}return e},a=function(e,t,n,r){for(var o=t.length,i=n.length,s=0,a=0;s<o||a<i;)e[s+a]=s<o&&a<i?r(t[s],n[a])<=0?t[s++]:n[a++]:s<o?t[s++]:n[a++];return e};t.exports=i},{"../internals/array-slice":15}],17:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-array"),i=e("../internals/is-constructor"),s=e("../internals/is-object"),a=e("../internals/well-known-symbol")("species"),l=r.Array;t.exports=function(e){var t;return o(e)&&(t=e.constructor,(i(t)&&(t===l||o(t.prototype))||s(t)&&null===(t=t[a]))&&(t=void 0)),void 0===t?l:t}},{"../internals/global":48,"../internals/is-array":59,"../internals/is-constructor":61,"../internals/is-object":64,"../internals/well-known-symbol":112}],18:[function(e,t,n){var r=e("../internals/array-species-constructor");t.exports=function(e,t){return new(r(e))(0===t?0:t)}},{"../internals/array-species-constructor":17}],19:[function(e,t,n){var r=e("../internals/well-known-symbol")("iterator"),o=!1;try{var i=0,s={next:function(){return{done:!!i++}},return:function(){o=!0}};s[r]=function(){return this},Array.from(s,(function(){throw 2}))}catch(e){}t.exports=function(e,t){if(!t&&!o)return!1;var n=!1;try{var i={};i[r]=function(){return{next:function(){return{done:n=!0}}}},e(i)}catch(e){}return n}},{"../internals/well-known-symbol":112}],20:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=r({}.toString),i=r("".slice);t.exports=function(e){return i(o(e),8,-1)}},{"../internals/function-uncurry-this":43}],21:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-string-tag-support"),i=e("../internals/is-callable"),s=e("../internals/classof-raw"),a=e("../internals/well-known-symbol")("toStringTag"),l=r.Object,c="Arguments"==s(function(){return arguments}());t.exports=o?s:function(e){var t,n,r;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=l(e),a))?n:c?s(t):"Object"==(r=s(t))&&i(t.callee)?"Arguments":r}},{"../internals/classof-raw":20,"../internals/global":48,"../internals/is-callable":60,"../internals/to-string-tag-support":105,"../internals/well-known-symbol":112}],22:[function(e,t,n){var r=e("../internals/has-own-property"),o=e("../internals/own-keys"),i=e("../internals/object-get-own-property-descriptor"),s=e("../internals/object-define-property");t.exports=function(e,t){for(var n=o(t),a=s.f,l=i.f,c=0;c<n.length;c++){var u=n[c];r(e,u)||a(e,u,l(t,u))}}},{"../internals/has-own-property":49,"../internals/object-define-property":74,"../internals/object-get-own-property-descriptor":75,"../internals/own-keys":85}],23:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},{"../internals/fails":39}],24:[function(e,t,n){"use strict";var r=e("../internals/iterators-core").IteratorPrototype,o=e("../internals/object-create"),i=e("../internals/create-property-descriptor"),s=e("../internals/set-to-string-tag"),a=e("../internals/iterators"),l=function(){return this};t.exports=function(e,t,n){var c=t+" Iterator";return e.prototype=o(r,{next:i(1,n)}),s(e,c,!1,!0),a[c]=l,e}},{"../internals/create-property-descriptor":26,"../internals/iterators":68,"../internals/iterators-core":67,"../internals/object-create":72,"../internals/set-to-string-tag":91}],25:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/object-define-property"),i=e("../internals/create-property-descriptor");t.exports=r?function(e,t,n){return o.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},{"../internals/create-property-descriptor":26,"../internals/descriptors":28,"../internals/object-define-property":74}],26:[function(e,t,n){t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},{}],27:[function(e,t,n){"use strict";var r=e("../internals/export"),o=e("../internals/function-call"),i=e("../internals/is-pure"),s=e("../internals/function-name"),a=e("../internals/is-callable"),l=e("../internals/create-iterator-constructor"),c=e("../internals/object-get-prototype-of"),u=e("../internals/object-set-prototype-of"),d=e("../internals/set-to-string-tag"),f=e("../internals/create-non-enumerable-property"),p=e("../internals/redefine"),h=e("../internals/well-known-symbol"),m=e("../internals/iterators"),y=e("../internals/iterators-core"),g=s.PROPER,v=s.CONFIGURABLE,b=y.IteratorPrototype,_=y.BUGGY_SAFARI_ITERATORS,w=h("iterator"),x="keys",k="values",j="entries",C=function(){return this};t.exports=function(e,t,n,s,h,y,E){l(n,t,s);var D,S,O,P=function(e){if(e===h&&I)return I;if(!_&&e in T)return T[e];switch(e){case x:case k:case j:return function(){return new n(this,e)}}return function(){return new n(this)}},B=t+" Iterator",M=!1,T=e.prototype,A=T[w]||T["@@iterator"]||h&&T[h],I=!_&&A||P(h),K="Array"==t&&T.entries||A;if(K&&(D=c(K.call(new e)))!==Object.prototype&&D.next&&(i||c(D)===b||(u?u(D,b):a(D[w])||p(D,w,C)),d(D,B,!0,!0),i&&(m[B]=C)),g&&h==k&&A&&A.name!==k&&(!i&&v?f(T,"name",k):(M=!0,I=function(){return o(A,this)})),h)if(S={values:P(k),keys:y?I:P(x),entries:P(j)},E)for(O in S)(_||M||!(O in T))&&p(T,O,S[O]);else r({target:t,proto:!0,forced:_||M},S);return i&&!E||T[w]===I||p(T,w,I,{name:h}),m[t]=I,S}},{"../internals/create-iterator-constructor":24,"../internals/create-non-enumerable-property":25,"../internals/export":38,"../internals/function-call":41,"../internals/function-name":42,"../internals/is-callable":60,"../internals/is-pure":65,"../internals/iterators":68,"../internals/iterators-core":67,"../internals/object-get-prototype-of":78,"../internals/object-set-prototype-of":83,"../internals/redefine":87,"../internals/set-to-string-tag":91,"../internals/well-known-symbol":112}],28:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},{"../internals/fails":39}],29:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-object"),i=r.document,s=o(i)&&o(i.createElement);t.exports=function(e){return s?i.createElement(e):{}}},{"../internals/global":48,"../internals/is-object":64}],30:[function(e,t,n){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},{}],31:[function(e,t,n){var r=e("../internals/document-create-element")("span").classList,o=r&&r.constructor&&r.constructor.prototype;t.exports=o===Object.prototype?void 0:o},{"../internals/document-create-element":29}],32:[function(e,t,n){var r=e("../internals/engine-user-agent").match(/firefox\/(\d+)/i);t.exports=!!r&&+r[1]},{"../internals/engine-user-agent":34}],33:[function(e,t,n){var r=e("../internals/engine-user-agent");t.exports=/MSIE|Trident/.test(r)},{"../internals/engine-user-agent":34}],34:[function(e,t,n){var r=e("../internals/get-built-in");t.exports=r("navigator","userAgent")||""},{"../internals/get-built-in":44}],35:[function(e,t,n){var r,o,i=e("../internals/global"),s=e("../internals/engine-user-agent"),a=i.process,l=i.Deno,c=a&&a.versions||l&&l.version,u=c&&c.v8;u&&(o=(r=u.split("."))[0]>0&&r[0]<4?1:+(r[0]+r[1])),!o&&s&&(!(r=s.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/))&&(o=+r[1]),t.exports=o},{"../internals/engine-user-agent":34,"../internals/global":48}],36:[function(e,t,n){var r=e("../internals/engine-user-agent").match(/AppleWebKit\/(\d+)\./);t.exports=!!r&&+r[1]},{"../internals/engine-user-agent":34}],37:[function(e,t,n){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},{}],38:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/object-get-own-property-descriptor").f,i=e("../internals/create-non-enumerable-property"),s=e("../internals/redefine"),a=e("../internals/set-global"),l=e("../internals/copy-constructor-properties"),c=e("../internals/is-forced");t.exports=function(e,t){var n,u,d,f,p,h=e.target,m=e.global,y=e.stat;if(n=m?r:y?r[h]||a(h,{}):(r[h]||{}).prototype)for(u in t){if(f=t[u],d=e.noTargetGet?(p=o(n,u))&&p.value:n[u],!c(m?u:h+(y?".":"#")+u,e.forced)&&void 0!==d){if(typeof f==typeof d)continue;l(f,d)}(e.sham||d&&d.sham)&&i(f,"sham",!0),s(n,u,f,e)}}},{"../internals/copy-constructor-properties":22,"../internals/create-non-enumerable-property":25,"../internals/global":48,"../internals/is-forced":62,"../internals/object-get-own-property-descriptor":75,"../internals/redefine":87,"../internals/set-global":89}],39:[function(e,t,n){t.exports=function(e){try{return!!e()}catch(e){return!0}}},{}],40:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/a-callable"),i=r(r.bind);t.exports=function(e,t){return o(e),void 0===t?e:i?i(e,t):function(){return e.apply(t,arguments)}}},{"../internals/a-callable":3,"../internals/function-uncurry-this":43}],41:[function(e,t,n){var r=Function.prototype.call;t.exports=r.bind?r.bind(r):function(){return r.apply(r,arguments)}},{}],42:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/has-own-property"),i=Function.prototype,s=r&&Object.getOwnPropertyDescriptor,a=o(i,"name"),l=a&&"something"===function(){}.name,c=a&&(!r||r&&s(i,"name").configurable);t.exports={EXISTS:a,PROPER:l,CONFIGURABLE:c}},{"../internals/descriptors":28,"../internals/has-own-property":49}],43:[function(e,t,n){var r=Function.prototype,o=r.bind,i=r.call,s=o&&o.bind(i);t.exports=o?function(e){return e&&s(i,e)}:function(e){return e&&function(){return i.apply(e,arguments)}}},{}],44:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=function(e){return o(e)?e:void 0};t.exports=function(e,t){return arguments.length<2?i(r[e]):r[e]&&r[e][t]}},{"../internals/global":48,"../internals/is-callable":60}],45:[function(e,t,n){var r=e("../internals/classof"),o=e("../internals/get-method"),i=e("../internals/iterators"),s=e("../internals/well-known-symbol")("iterator");t.exports=function(e){if(null!=e)return o(e,s)||o(e,"@@iterator")||i[r(e)]}},{"../internals/classof":21,"../internals/get-method":47,"../internals/iterators":68,"../internals/well-known-symbol":112}],46:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/a-callable"),s=e("../internals/an-object"),a=e("../internals/try-to-string"),l=e("../internals/get-iterator-method"),c=r.TypeError;t.exports=function(e,t){var n=arguments.length<2?l(e):t;if(i(n))return s(o(n,e));throw c(a(e)+" is not iterable")}},{"../internals/a-callable":3,"../internals/an-object":8,"../internals/function-call":41,"../internals/get-iterator-method":45,"../internals/global":48,"../internals/try-to-string":106}],47:[function(e,t,n){var r=e("../internals/a-callable");t.exports=function(e,t){var n=e[t];return null==n?void 0:r(n)}},{"../internals/a-callable":3}],48:[function(e,t,n){(function(e){(function(){var n=function(e){return e&&e.Math==Math&&e};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||function(){return this}()||Function("return this")()}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],49:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/to-object"),i=r({}.hasOwnProperty);t.exports=Object.hasOwn||function(e,t){return i(o(e),t)}},{"../internals/function-uncurry-this":43,"../internals/to-object":100}],50:[function(e,t,n){t.exports={}},{}],51:[function(e,t,n){var r=e("../internals/get-built-in");t.exports=r("document","documentElement")},{"../internals/get-built-in":44}],52:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/fails"),i=e("../internals/document-create-element");t.exports=!r&&!o((function(){return 7!=Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},{"../internals/descriptors":28,"../internals/document-create-element":29,"../internals/fails":39}],53:[function(e,t,n){var r=e("../internals/global").Array,o=Math.abs,i=Math.pow,s=Math.floor,a=Math.log,l=Math.LN2;t.exports={pack:function(e,t,n){var c,u,d,f=r(n),p=8*n-t-1,h=(1<<p)-1,m=h>>1,y=23===t?i(2,-24)-i(2,-77):0,g=e<0||0===e&&1/e<0?1:0,v=0;for((e=o(e))!=e||e===1/0?(u=e!=e?1:0,c=h):(c=s(a(e)/l),e*(d=i(2,-c))<1&&(c--,d*=2),(e+=c+m>=1?y/d:y*i(2,1-m))*d>=2&&(c++,d/=2),c+m>=h?(u=0,c=h):c+m>=1?(u=(e*d-1)*i(2,t),c+=m):(u=e*i(2,m-1)*i(2,t),c=0));t>=8;f[v++]=255&u,u/=256,t-=8);for(c=c<<t|u,p+=t;p>0;f[v++]=255&c,c/=256,p-=8);return f[--v]|=128*g,f},unpack:function(e,t){var n,r=e.length,o=8*r-t-1,s=(1<<o)-1,a=s>>1,l=o-7,c=r-1,u=e[c--],d=127&u;for(u>>=7;l>0;d=256*d+e[c],c--,l-=8);for(n=d&(1<<-l)-1,d>>=-l,l+=t;l>0;n=256*n+e[c],c--,l-=8);if(0===d)d=1-a;else{if(d===s)return n?NaN:u?-1/0:1/0;n+=i(2,t),d-=a}return(u?-1:1)*n*i(2,d-t)}}},{"../internals/global":48}],54:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=e("../internals/fails"),s=e("../internals/classof-raw"),a=r.Object,l=o("".split);t.exports=i((function(){return!a("z").propertyIsEnumerable(0)}))?function(e){return"String"==s(e)?l(e,""):a(e)}:a},{"../internals/classof-raw":20,"../internals/fails":39,"../internals/function-uncurry-this":43,"../internals/global":48}],55:[function(e,t,n){var r=e("../internals/is-callable"),o=e("../internals/is-object"),i=e("../internals/object-set-prototype-of");t.exports=function(e,t,n){var s,a;return i&&r(s=t.constructor)&&s!==n&&o(a=s.prototype)&&a!==n.prototype&&i(e,a),e}},{"../internals/is-callable":60,"../internals/is-object":64,"../internals/object-set-prototype-of":83}],56:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/is-callable"),i=e("../internals/shared-store"),s=r(Function.toString);o(i.inspectSource)||(i.inspectSource=function(e){return s(e)}),t.exports=i.inspectSource},{"../internals/function-uncurry-this":43,"../internals/is-callable":60,"../internals/shared-store":93}],57:[function(e,t,n){var r,o,i,s=e("../internals/native-weak-map"),a=e("../internals/global"),l=e("../internals/function-uncurry-this"),c=e("../internals/is-object"),u=e("../internals/create-non-enumerable-property"),d=e("../internals/has-own-property"),f=e("../internals/shared-store"),p=e("../internals/shared-key"),h=e("../internals/hidden-keys"),m="Object already initialized",y=a.TypeError,g=a.WeakMap;if(s||f.state){var v=f.state||(f.state=new g),b=l(v.get),_=l(v.has),w=l(v.set);r=function(e,t){if(_(v,e))throw new y(m);return t.facade=e,w(v,e,t),t},o=function(e){return b(v,e)||{}},i=function(e){return _(v,e)}}else{var x=p("state");h[x]=!0,r=function(e,t){if(d(e,x))throw new y(m);return t.facade=e,u(e,x,t),t},o=function(e){return d(e,x)?e[x]:{}},i=function(e){return d(e,x)}}t.exports={set:r,get:o,has:i,enforce:function(e){return i(e)?o(e):r(e,{})},getterFor:function(e){return function(t){var n;if(!c(t)||(n=o(t)).type!==e)throw y("Incompatible receiver, "+e+" required");return n}}}},{"../internals/create-non-enumerable-property":25,"../internals/function-uncurry-this":43,"../internals/global":48,"../internals/has-own-property":49,"../internals/hidden-keys":50,"../internals/is-object":64,"../internals/native-weak-map":71,"../internals/shared-key":92,"../internals/shared-store":93}],58:[function(e,t,n){var r=e("../internals/well-known-symbol"),o=e("../internals/iterators"),i=r("iterator"),s=Array.prototype;t.exports=function(e){return void 0!==e&&(o.Array===e||s[i]===e)}},{"../internals/iterators":68,"../internals/well-known-symbol":112}],59:[function(e,t,n){var r=e("../internals/classof-raw");t.exports=Array.isArray||function(e){return"Array"==r(e)}},{"../internals/classof-raw":20}],60:[function(e,t,n){t.exports=function(e){return"function"==typeof e}},{}],61:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/fails"),i=e("../internals/is-callable"),s=e("../internals/classof"),a=e("../internals/get-built-in"),l=e("../internals/inspect-source"),c=function(){},u=[],d=a("Reflect","construct"),f=/^\s*(?:class|function)\b/,p=r(f.exec),h=!f.exec(c),m=function(e){if(!i(e))return!1;try{return d(c,u,e),!0}catch(e){return!1}};t.exports=!d||o((function(){var e;return m(m.call)||!m(Object)||!m((function(){e=!0}))||e}))?function(e){if(!i(e))return!1;switch(s(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}return h||!!p(f,l(e))}:m},{"../internals/classof":21,"../internals/fails":39,"../internals/function-uncurry-this":43,"../internals/get-built-in":44,"../internals/inspect-source":56,"../internals/is-callable":60}],62:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/is-callable"),i=/#|\.prototype\./,s=function(e,t){var n=l[a(e)];return n==u||n!=c&&(o(t)?r(t):!!t)},a=s.normalize=function(e){return String(e).replace(i,".").toLowerCase()},l=s.data={},c=s.NATIVE="N",u=s.POLYFILL="P";t.exports=s},{"../internals/fails":39,"../internals/is-callable":60}],63:[function(e,t,n){var r=e("../internals/is-object"),o=Math.floor;t.exports=Number.isInteger||function(e){return!r(e)&&isFinite(e)&&o(e)===e}},{"../internals/is-object":64}],64:[function(e,t,n){var r=e("../internals/is-callable");t.exports=function(e){return"object"==typeof e?null!==e:r(e)}},{"../internals/is-callable":60}],65:[function(e,t,n){t.exports=!1},{}],66:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/get-built-in"),i=e("../internals/is-callable"),s=e("../internals/object-is-prototype-of"),a=e("../internals/use-symbol-as-uid"),l=r.Object;t.exports=a?function(e){return"symbol"==typeof e}:function(e){var t=o("Symbol");return i(t)&&s(t.prototype,l(e))}},{"../internals/get-built-in":44,"../internals/global":48,"../internals/is-callable":60,"../internals/object-is-prototype-of":79,"../internals/use-symbol-as-uid":111}],67:[function(e,t,n){"use strict";var r,o,i,s=e("../internals/fails"),a=e("../internals/is-callable"),l=e("../internals/object-create"),c=e("../internals/object-get-prototype-of"),u=e("../internals/redefine"),d=e("../internals/well-known-symbol"),f=e("../internals/is-pure"),p=d("iterator"),h=!1;[].keys&&("next"in(i=[].keys())?(o=c(c(i)))!==Object.prototype&&(r=o):h=!0),null==r||s((function(){var e={};return r[p].call(e)!==e}))?r={}:f&&(r=l(r)),a(r[p])||u(r,p,(function(){return this})),t.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:h}},{"../internals/fails":39,"../internals/is-callable":60,"../internals/is-pure":65,"../internals/object-create":72,"../internals/object-get-prototype-of":78,"../internals/redefine":87,"../internals/well-known-symbol":112}],68:[function(e,t,n){arguments[4][50][0].apply(n,arguments)},{dup:50}],69:[function(e,t,n){var r=e("../internals/to-length");t.exports=function(e){return r(e.length)}},{"../internals/to-length":99}],70:[function(e,t,n){var r=e("../internals/engine-v8-version"),o=e("../internals/fails");t.exports=!!Object.getOwnPropertySymbols&&!o((function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},{"../internals/engine-v8-version":35,"../internals/fails":39}],71:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/inspect-source"),s=r.WeakMap;t.exports=o(s)&&/native code/.test(i(s))},{"../internals/global":48,"../internals/inspect-source":56,"../internals/is-callable":60}],72:[function(e,t,n){var r,o=e("../internals/an-object"),i=e("../internals/object-define-properties"),s=e("../internals/enum-bug-keys"),a=e("../internals/hidden-keys"),l=e("../internals/html"),c=e("../internals/document-create-element"),u=e("../internals/shared-key")("IE_PROTO"),d=function(){},f=function(e){return"<script>"+e+"<\/script>"},p=function(e){e.write(f("")),e.close();var t=e.parentWindow.Object;return e=null,t},h=function(){try{r=new ActiveXObject("htmlfile")}catch(e){}var e,t;h="undefined"!=typeof document?document.domain&&r?p(r):((t=c("iframe")).style.display="none",l.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(f("document.F=Object")),e.close(),e.F):p(r);for(var n=s.length;n--;)delete h.prototype[s[n]];return h()};a[u]=!0,t.exports=Object.create||function(e,t){var n;return null!==e?(d.prototype=o(e),n=new d,d.prototype=null,n[u]=e):n=h(),void 0===t?n:i(n,t)}},{"../internals/an-object":8,"../internals/document-create-element":29,"../internals/enum-bug-keys":37,"../internals/hidden-keys":50,"../internals/html":51,"../internals/object-define-properties":73,"../internals/shared-key":92}],73:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/object-define-property"),i=e("../internals/an-object"),s=e("../internals/to-indexed-object"),a=e("../internals/object-keys");t.exports=r?Object.defineProperties:function(e,t){i(e);for(var n,r=s(t),l=a(t),c=l.length,u=0;c>u;)o.f(e,n=l[u++],r[n]);return e}},{"../internals/an-object":8,"../internals/descriptors":28,"../internals/object-define-property":74,"../internals/object-keys":81,"../internals/to-indexed-object":97}],74:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/descriptors"),i=e("../internals/ie8-dom-define"),s=e("../internals/an-object"),a=e("../internals/to-property-key"),l=r.TypeError,c=Object.defineProperty;n.f=o?c:function(e,t,n){if(s(e),t=a(t),s(n),i)try{return c(e,t,n)}catch(e){}if("get"in n||"set"in n)throw l("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},{"../internals/an-object":8,"../internals/descriptors":28,"../internals/global":48,"../internals/ie8-dom-define":52,"../internals/to-property-key":104}],75:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/function-call"),i=e("../internals/object-property-is-enumerable"),s=e("../internals/create-property-descriptor"),a=e("../internals/to-indexed-object"),l=e("../internals/to-property-key"),c=e("../internals/has-own-property"),u=e("../internals/ie8-dom-define"),d=Object.getOwnPropertyDescriptor;n.f=r?d:function(e,t){if(e=a(e),t=l(t),u)try{return d(e,t)}catch(e){}if(c(e,t))return s(!o(i.f,e,t),e[t])}},{"../internals/create-property-descriptor":26,"../internals/descriptors":28,"../internals/function-call":41,"../internals/has-own-property":49,"../internals/ie8-dom-define":52,"../internals/object-property-is-enumerable":82,"../internals/to-indexed-object":97,"../internals/to-property-key":104}],76:[function(e,t,n){var r=e("../internals/object-keys-internal"),o=e("../internals/enum-bug-keys").concat("length","prototype");n.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},{"../internals/enum-bug-keys":37,"../internals/object-keys-internal":80}],77:[function(e,t,n){n.f=Object.getOwnPropertySymbols},{}],78:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/has-own-property"),i=e("../internals/is-callable"),s=e("../internals/to-object"),a=e("../internals/shared-key"),l=e("../internals/correct-prototype-getter"),c=a("IE_PROTO"),u=r.Object,d=u.prototype;t.exports=l?u.getPrototypeOf:function(e){var t=s(e);if(o(t,c))return t[c];var n=t.constructor;return i(n)&&t instanceof n?n.prototype:t instanceof u?d:null}},{"../internals/correct-prototype-getter":23,"../internals/global":48,"../internals/has-own-property":49,"../internals/is-callable":60,"../internals/shared-key":92,"../internals/to-object":100}],79:[function(e,t,n){var r=e("../internals/function-uncurry-this");t.exports=r({}.isPrototypeOf)},{"../internals/function-uncurry-this":43}],80:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/has-own-property"),i=e("../internals/to-indexed-object"),s=e("../internals/array-includes").indexOf,a=e("../internals/hidden-keys"),l=r([].push);t.exports=function(e,t){var n,r=i(e),c=0,u=[];for(n in r)!o(a,n)&&o(r,n)&&l(u,n);for(;t.length>c;)o(r,n=t[c++])&&(~s(u,n)||l(u,n));return u}},{"../internals/array-includes":13,"../internals/function-uncurry-this":43,"../internals/has-own-property":49,"../internals/hidden-keys":50,"../internals/to-indexed-object":97}],81:[function(e,t,n){var r=e("../internals/object-keys-internal"),o=e("../internals/enum-bug-keys");t.exports=Object.keys||function(e){return r(e,o)}},{"../internals/enum-bug-keys":37,"../internals/object-keys-internal":80}],82:[function(e,t,n){"use strict";var r={}.propertyIsEnumerable,o=Object.getOwnPropertyDescriptor,i=o&&!r.call({1:2},1);n.f=i?function(e){var t=o(this,e);return!!t&&t.enumerable}:r},{}],83:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/an-object"),i=e("../internals/a-possible-prototype");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{(e=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),t=n instanceof Array}catch(e){}return function(n,r){return o(n),i(r),t?e(n,r):n.__proto__=r,n}}():void 0)},{"../internals/a-possible-prototype":5,"../internals/an-object":8,"../internals/function-uncurry-this":43}],84:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/is-callable"),s=e("../internals/is-object"),a=r.TypeError;t.exports=function(e,t){var n,r;if("string"===t&&i(n=e.toString)&&!s(r=o(n,e)))return r;if(i(n=e.valueOf)&&!s(r=o(n,e)))return r;if("string"!==t&&i(n=e.toString)&&!s(r=o(n,e)))return r;throw a("Can't convert object to primitive value")}},{"../internals/function-call":41,"../internals/global":48,"../internals/is-callable":60,"../internals/is-object":64}],85:[function(e,t,n){var r=e("../internals/get-built-in"),o=e("../internals/function-uncurry-this"),i=e("../internals/object-get-own-property-names"),s=e("../internals/object-get-own-property-symbols"),a=e("../internals/an-object"),l=o([].concat);t.exports=r("Reflect","ownKeys")||function(e){var t=i.f(a(e)),n=s.f;return n?l(t,n(e)):t}},{"../internals/an-object":8,"../internals/function-uncurry-this":43,"../internals/get-built-in":44,"../internals/object-get-own-property-names":76,"../internals/object-get-own-property-symbols":77}],86:[function(e,t,n){var r=e("../internals/redefine");t.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},{"../internals/redefine":87}],87:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/has-own-property"),s=e("../internals/create-non-enumerable-property"),a=e("../internals/set-global"),l=e("../internals/inspect-source"),c=e("../internals/internal-state"),u=e("../internals/function-name").CONFIGURABLE,d=c.get,f=c.enforce,p=String(String).split("String");(t.exports=function(e,t,n,l){var c,d=!!l&&!!l.unsafe,h=!!l&&!!l.enumerable,m=!!l&&!!l.noTargetGet,y=l&&void 0!==l.name?l.name:t;o(n)&&("Symbol("===String(y).slice(0,7)&&(y="["+String(y).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!i(n,"name")||u&&n.name!==y)&&s(n,"name",y),(c=f(n)).source||(c.source=p.join("string"==typeof y?y:""))),e!==r?(d?!m&&e[t]&&(h=!0):delete e[t],h?e[t]=n:s(e,t,n)):h?e[t]=n:a(t,n)})(Function.prototype,"toString",(function(){return o(this)&&d(this).source||l(this)}))},{"../internals/create-non-enumerable-property":25,"../internals/function-name":42,"../internals/global":48,"../internals/has-own-property":49,"../internals/inspect-source":56,"../internals/internal-state":57,"../internals/is-callable":60,"../internals/set-global":89}],88:[function(e,t,n){var r=e("../internals/global").TypeError;t.exports=function(e){if(null==e)throw r("Can't call method on "+e);return e}},{"../internals/global":48}],89:[function(e,t,n){var r=e("../internals/global"),o=Object.defineProperty;t.exports=function(e,t){try{o(r,e,{value:t,configurable:!0,writable:!0})}catch(n){r[e]=t}return t}},{"../internals/global":48}],90:[function(e,t,n){"use strict";var r=e("../internals/get-built-in"),o=e("../internals/object-define-property"),i=e("../internals/well-known-symbol"),s=e("../internals/descriptors"),a=i("species");t.exports=function(e){var t=r(e),n=o.f;s&&t&&!t[a]&&n(t,a,{configurable:!0,get:function(){return this}})}},{"../internals/descriptors":28,"../internals/get-built-in":44,"../internals/object-define-property":74,"../internals/well-known-symbol":112}],91:[function(e,t,n){var r=e("../internals/object-define-property").f,o=e("../internals/has-own-property"),i=e("../internals/well-known-symbol")("toStringTag");t.exports=function(e,t,n){e&&!o(e=n?e:e.prototype,i)&&r(e,i,{configurable:!0,value:t})}},{"../internals/has-own-property":49,"../internals/object-define-property":74,"../internals/well-known-symbol":112}],92:[function(e,t,n){var r=e("../internals/shared"),o=e("../internals/uid"),i=r("keys");t.exports=function(e){return i[e]||(i[e]=o(e))}},{"../internals/shared":94,"../internals/uid":110}],93:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/set-global"),i="__core-js_shared__",s=r[i]||o(i,{});t.exports=s},{"../internals/global":48,"../internals/set-global":89}],94:[function(e,t,n){var r=e("../internals/is-pure"),o=e("../internals/shared-store");(t.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.19.1",mode:r?"pure":"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"})},{"../internals/is-pure":65,"../internals/shared-store":93}],95:[function(e,t,n){var r=e("../internals/to-integer-or-infinity"),o=Math.max,i=Math.min;t.exports=function(e,t){var n=r(e);return n<0?o(n+t,0):i(n,t)}},{"../internals/to-integer-or-infinity":98}],96:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-integer-or-infinity"),i=e("../internals/to-length"),s=r.RangeError;t.exports=function(e){if(void 0===e)return 0;var t=o(e),n=i(t);if(t!==n)throw s("Wrong length or index");return n}},{"../internals/global":48,"../internals/to-integer-or-infinity":98,"../internals/to-length":99}],97:[function(e,t,n){var r=e("../internals/indexed-object"),o=e("../internals/require-object-coercible");t.exports=function(e){return r(o(e))}},{"../internals/indexed-object":54,"../internals/require-object-coercible":88}],98:[function(e,t,n){var r=Math.ceil,o=Math.floor;t.exports=function(e){var t=+e;return t!=t||0===t?0:(t>0?o:r)(t)}},{}],99:[function(e,t,n){var r=e("../internals/to-integer-or-infinity"),o=Math.min;t.exports=function(e){return e>0?o(r(e),9007199254740991):0}},{"../internals/to-integer-or-infinity":98}],100:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/require-object-coercible"),i=r.Object;t.exports=function(e){return i(o(e))}},{"../internals/global":48,"../internals/require-object-coercible":88}],101:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-positive-integer"),i=r.RangeError;t.exports=function(e,t){var n=o(e);if(n%t)throw i("Wrong offset");return n}},{"../internals/global":48,"../internals/to-positive-integer":102}],102:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-integer-or-infinity"),i=r.RangeError;t.exports=function(e){var t=o(e);if(t<0)throw i("The argument can't be less than 0");return t}},{"../internals/global":48,"../internals/to-integer-or-infinity":98}],103:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/is-object"),s=e("../internals/is-symbol"),a=e("../internals/get-method"),l=e("../internals/ordinary-to-primitive"),c=e("../internals/well-known-symbol"),u=r.TypeError,d=c("toPrimitive");t.exports=function(e,t){if(!i(e)||s(e))return e;var n,r=a(e,d);if(r){if(void 0===t&&(t="default"),n=o(r,e,t),!i(n)||s(n))return n;throw u("Can't convert object to primitive value")}return void 0===t&&(t="number"),l(e,t)}},{"../internals/function-call":41,"../internals/get-method":47,"../internals/global":48,"../internals/is-object":64,"../internals/is-symbol":66,"../internals/ordinary-to-primitive":84,"../internals/well-known-symbol":112}],104:[function(e,t,n){var r=e("../internals/to-primitive"),o=e("../internals/is-symbol");t.exports=function(e){var t=r(e,"string");return o(t)?t:t+""}},{"../internals/is-symbol":66,"../internals/to-primitive":103}],105:[function(e,t,n){var r={};r[e("../internals/well-known-symbol")("toStringTag")]="z",t.exports="[object z]"===String(r)},{"../internals/well-known-symbol":112}],106:[function(e,t,n){var r=e("../internals/global").String;t.exports=function(e){try{return r(e)}catch(e){return"Object"}}},{"../internals/global":48}],107:[function(e,t,n){"use strict";var r=e("../internals/export"),o=e("../internals/global"),i=e("../internals/function-call"),s=e("../internals/descriptors"),a=e("../internals/typed-array-constructors-require-wrappers"),l=e("../internals/array-buffer-view-core"),c=e("../internals/array-buffer"),u=e("../internals/an-instance"),d=e("../internals/create-property-descriptor"),f=e("../internals/create-non-enumerable-property"),p=e("../internals/is-integral-number"),h=e("../internals/to-length"),m=e("../internals/to-index"),y=e("../internals/to-offset"),g=e("../internals/to-property-key"),v=e("../internals/has-own-property"),b=e("../internals/classof"),_=e("../internals/is-object"),w=e("../internals/is-symbol"),x=e("../internals/object-create"),k=e("../internals/object-is-prototype-of"),j=e("../internals/object-set-prototype-of"),C=e("../internals/object-get-own-property-names").f,E=e("../internals/typed-array-from"),D=e("../internals/array-iteration").forEach,S=e("../internals/set-species"),O=e("../internals/object-define-property"),P=e("../internals/object-get-own-property-descriptor"),B=e("../internals/internal-state"),M=e("../internals/inherit-if-required"),T=B.get,A=B.set,I=O.f,K=P.f,L=Math.round,R=o.RangeError,N=c.ArrayBuffer,F=N.prototype,U=c.DataView,z=l.NATIVE_ARRAY_BUFFER_VIEWS,H=l.TYPED_ARRAY_CONSTRUCTOR,W=l.TYPED_ARRAY_TAG,q=l.TypedArray,V=l.TypedArrayPrototype,G=l.aTypedArrayConstructor,Y=l.isTypedArray,X="BYTES_PER_ELEMENT",$="Wrong length",J=function(e,t){G(e);for(var n=0,r=t.length,o=new e(r);r>n;)o[n]=t[n++];return o},Q=function(e,t){I(e,t,{get:function(){return T(this)[t]}})},Z=function(e){var t;return k(F,e)||"ArrayBuffer"==(t=b(e))||"SharedArrayBuffer"==t},ee=function(e,t){return Y(e)&&!w(t)&&t in e&&p(+t)&&t>=0},te=function(e,t){return t=g(t),ee(e,t)?d(2,e[t]):K(e,t)},ne=function(e,t,n){return t=g(t),!(ee(e,t)&&_(n)&&v(n,"value"))||v(n,"get")||v(n,"set")||n.configurable||v(n,"writable")&&!n.writable||v(n,"enumerable")&&!n.enumerable?I(e,t,n):(e[t]=n.value,e)};s?(z||(P.f=te,O.f=ne,Q(V,"buffer"),Q(V,"byteOffset"),Q(V,"byteLength"),Q(V,"length")),r({target:"Object",stat:!0,forced:!z},{getOwnPropertyDescriptor:te,defineProperty:ne}),t.exports=function(e,t,n){var s=e.match(/\d+$/)[0]/8,l=e+(n?"Clamped":"")+"Array",c="get"+e,d="set"+e,p=o[l],g=p,v=g&&g.prototype,b={},w=function(e,t){I(e,t,{get:function(){return function(e,t){var n=T(e);return n.view[c](t*s+n.byteOffset,!0)}(this,t)},set:function(e){return function(e,t,r){var o=T(e);n&&(r=(r=L(r))<0?0:r>255?255:255&r),o.view[d](t*s+o.byteOffset,r,!0)}(this,t,e)},enumerable:!0})};z?a&&(g=t((function(e,t,n,r){return u(e,v),M(_(t)?Z(t)?void 0!==r?new p(t,y(n,s),r):void 0!==n?new p(t,y(n,s)):new p(t):Y(t)?J(g,t):i(E,g,t):new p(m(t)),e,g)})),j&&j(g,q),D(C(p),(function(e){e in g||f(g,e,p[e])})),g.prototype=v):(g=t((function(e,t,n,r){u(e,v);var o,a,l,c=0,d=0;if(_(t)){if(!Z(t))return Y(t)?J(g,t):i(E,g,t);o=t,d=y(n,s);var f=t.byteLength;if(void 0===r){if(f%s)throw R($);if((a=f-d)<0)throw R($)}else if((a=h(r)*s)+d>f)throw R($);l=a/s}else l=m(t),o=new N(a=l*s);for(A(e,{buffer:o,byteOffset:d,byteLength:a,length:l,view:new U(o)});c<l;)w(e,c++)})),j&&j(g,q),v=g.prototype=x(V)),v.constructor!==g&&f(v,"constructor",g),f(v,H,g),W&&f(v,W,l),b[l]=g,r({global:!0,forced:g!=p,sham:!z},b),X in g||f(g,X,s),X in v||f(v,X,s),S(l)}):t.exports=function(){}},{"../internals/an-instance":7,"../internals/array-buffer":11,"../internals/array-buffer-view-core":10,"../internals/array-iteration":14,"../internals/classof":21,"../internals/create-non-enumerable-property":25,"../internals/create-property-descriptor":26,"../internals/descriptors":28,"../internals/export":38,"../internals/function-call":41,"../internals/global":48,"../internals/has-own-property":49,"../internals/inherit-if-required":55,"../internals/internal-state":57,"../internals/is-integral-number":63,"../internals/is-object":64,"../internals/is-symbol":66,"../internals/object-create":72,"../internals/object-define-property":74,"../internals/object-get-own-property-descriptor":75,"../internals/object-get-own-property-names":76,"../internals/object-is-prototype-of":79,"../internals/object-set-prototype-of":83,"../internals/set-species":90,"../internals/to-index":96,"../internals/to-length":99,"../internals/to-offset":101,"../internals/to-property-key":104,"../internals/typed-array-constructors-require-wrappers":108,"../internals/typed-array-from":109}],108:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/fails"),i=e("../internals/check-correctness-of-iteration"),s=e("../internals/array-buffer-view-core").NATIVE_ARRAY_BUFFER_VIEWS,a=r.ArrayBuffer,l=r.Int8Array;t.exports=!s||!o((function(){l(1)}))||!o((function(){new l(-1)}))||!i((function(e){new l,new l(null),new l(1.5),new l(e)}),!0)||o((function(){return 1!==new l(new a(2),1,void 0).length}))},{"../internals/array-buffer-view-core":10,"../internals/check-correctness-of-iteration":19,"../internals/fails":39,"../internals/global":48}],109:[function(e,t,n){var r=e("../internals/function-bind-context"),o=e("../internals/function-call"),i=e("../internals/a-constructor"),s=e("../internals/to-object"),a=e("../internals/length-of-array-like"),l=e("../internals/get-iterator"),c=e("../internals/get-iterator-method"),u=e("../internals/is-array-iterator-method"),d=e("../internals/array-buffer-view-core").aTypedArrayConstructor;t.exports=function(e){var t,n,f,p,h,m,y=i(this),g=s(e),v=arguments.length,b=v>1?arguments[1]:void 0,_=void 0!==b,w=c(g);if(w&&!u(w))for(m=(h=l(g,w)).next,g=[];!(p=o(m,h)).done;)g.push(p.value);for(_&&v>2&&(b=r(b,arguments[2])),n=a(g),f=new(d(y))(n),t=0;n>t;t++)f[t]=_?b(g[t],t):g[t];return f}},{"../internals/a-constructor":4,"../internals/array-buffer-view-core":10,"../internals/function-bind-context":40,"../internals/function-call":41,"../internals/get-iterator":46,"../internals/get-iterator-method":45,"../internals/is-array-iterator-method":58,"../internals/length-of-array-like":69,"../internals/to-object":100}],110:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=0,i=Math.random(),s=r(1..toString);t.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+s(++o+i,36)}},{"../internals/function-uncurry-this":43}],111:[function(e,t,n){var r=e("../internals/native-symbol");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},{"../internals/native-symbol":70}],112:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/shared"),i=e("../internals/has-own-property"),s=e("../internals/uid"),a=e("../internals/native-symbol"),l=e("../internals/use-symbol-as-uid"),c=o("wks"),u=r.Symbol,d=u&&u.for,f=l?u:u&&u.withoutSetter||s;t.exports=function(e){if(!i(c,e)||!a&&"string"!=typeof c[e]){var t="Symbol."+e;a&&i(u,e)?c[e]=u[e]:c[e]=l&&d?d(t):f(t)}return c[e]}},{"../internals/global":48,"../internals/has-own-property":49,"../internals/native-symbol":70,"../internals/shared":94,"../internals/uid":110,"../internals/use-symbol-as-uid":111}],113:[function(e,t,n){"use strict";var r=e("../internals/to-indexed-object"),o=e("../internals/add-to-unscopables"),i=e("../internals/iterators"),s=e("../internals/internal-state"),a=e("../internals/define-iterator"),l="Array Iterator",c=s.set,u=s.getterFor(l);t.exports=a(Array,"Array",(function(e,t){c(this,{type:l,target:r(e),index:0,kind:t})}),(function(){var e=u(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}}),"values"),i.Arguments=i.Array,o("keys"),o("values"),o("entries")},{"../internals/add-to-unscopables":6,"../internals/define-iterator":27,"../internals/internal-state":57,"../internals/iterators":68,"../internals/to-indexed-object":97}],114:[function(e,t,n){e("../internals/typed-array-constructor")("Float32",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},{"../internals/typed-array-constructor":107}],115:[function(e,t,n){"use strict";var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=e("../internals/fails"),s=e("../internals/a-callable"),a=e("../internals/array-sort"),l=e("../internals/array-buffer-view-core"),c=e("../internals/engine-ff-version"),u=e("../internals/engine-is-ie-or-edge"),d=e("../internals/engine-v8-version"),f=e("../internals/engine-webkit-version"),p=r.Array,h=l.aTypedArray,m=l.exportTypedArrayMethod,y=r.Uint16Array,g=y&&o(y.prototype.sort),v=!(!g||i((function(){g(new y(2),null)}))&&i((function(){g(new y(2),{})}))),b=!!g&&!i((function(){if(d)return d<74;if(c)return c<67;if(u)return!0;if(f)return f<602;var e,t,n=new y(516),r=p(516);for(e=0;e<516;e++)t=e%4,n[e]=515-e,r[e]=e-2*t+3;for(g(n,(function(e,t){return(e/4|0)-(t/4|0)})),e=0;e<516;e++)if(n[e]!==r[e])return!0}));m("sort",(function(e){return void 0!==e&&s(e),b?g(this,e):a(h(this),function(e){return function(t,n){return void 0!==e?+e(t,n)||0:n!=n?-1:t!=t?1:0===t&&0===n?1/t>0&&1/n<0?1:-1:t>n}}(e))}),!b||v)},{"../internals/a-callable":3,"../internals/array-buffer-view-core":10,"../internals/array-sort":16,"../internals/engine-ff-version":32,"../internals/engine-is-ie-or-edge":33,"../internals/engine-v8-version":35,"../internals/engine-webkit-version":36,"../internals/fails":39,"../internals/function-uncurry-this":43,"../internals/global":48}],116:[function(e,t,n){e("../internals/typed-array-constructor")("Uint8",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},{"../internals/typed-array-constructor":107}],117:[function(e,t,n){e("../internals/typed-array-constructor")("Uint8",(function(e){return function(t,n,r){return e(this,t,n,r)}}),!0)},{"../internals/typed-array-constructor":107}],118:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/dom-iterables"),i=e("../internals/dom-token-list-prototype"),s=e("../modules/es.array.iterator"),a=e("../internals/create-non-enumerable-property"),l=e("../internals/well-known-symbol"),c=l("iterator"),u=l("toStringTag"),d=s.values,f=function(e,t){if(e){if(e[c]!==d)try{a(e,c,d)}catch(t){e[c]=d}if(e[u]||a(e,u,t),o[t])for(var n in s)if(e[n]!==s[n])try{a(e,n,s[n])}catch(t){e[n]=s[n]}}};for(var p in o)f(r[p]&&r[p].prototype,p);f(i,"DOMTokenList")},{"../internals/create-non-enumerable-property":25,"../internals/dom-iterables":30,"../internals/dom-token-list-prototype":31,"../internals/global":48,"../internals/well-known-symbol":112,"../modules/es.array.iterator":113}],119:[function(e,t,n){"use strict";var r=t.exports={};r.isIE=function(e){return!(-1===(t=navigator.userAgent.toLowerCase()).indexOf("msie")&&-1===t.indexOf("trident")&&-1===t.indexOf(" edge/")||e&&e!==function(){var e=3,t=document.createElement("div"),n=t.getElementsByTagName("i");do{t.innerHTML="\x3c!--[if gt IE "+ ++e+"]><i></i><![endif]--\x3e"}while(n[0]);return e>4?e:void 0}());var t},r.isLegacyOpera=function(){return!!window.opera}},{}],120:[function(e,t,n){"use strict";(t.exports={}).forEach=function(e,t){for(var n=0;n<e.length;n++){var r=t(e[n]);if(r)return r}}},{}],121:[function(e,t,n){"use strict";var r=e("../browser-detector");t.exports=function(e){var t=(e=e||{}).reporter,n=e.batchProcessor,o=e.stateHandler.getState;if(!t)throw new Error("Missing required dependency: reporter.");function i(t){var n=e.important?" !important; ":"; ";return(t.join(n)+n).trim()}function s(e){return o(e).object}return{makeDetectable:function(e,s,a){a||(a=s,s=e,e=null),(e=e||{}).debug,r.isIE(8)?a(s):function(s,a){var l=i(["display: block","position: absolute","top: 0","left: 0","width: 100%","height: 100%","border: none","padding: 0","margin: 0","opacity: 0","z-index: -1000","pointer-events: none"]),c=!1,u=window.getComputedStyle(s),d=s.offsetWidth,f=s.offsetHeight;function p(){function n(){if("static"===u.position){s.style.setProperty("position","relative",e.important?"important":"");var n=function(t,n,r,o){var i=r[o];"auto"!==i&&"0"!==function(e){return e.replace(/[^-\d\.]/g,"")}(i)&&(t.warn("An element that is positioned static has style."+o+"="+i+" which is ignored due to the static positioning. The element will need to be positioned relative, so the style."+o+" will be set to 0. Element: ",n),n.style.setProperty(o,"0",e.important?"important":""))};n(t,s,u,"top"),n(t,s,u,"right"),n(t,s,u,"bottom"),n(t,s,u,"left")}}""!==u.position&&(n(),c=!0);var i=document.createElement("object");i.style.cssText=l,i.tabIndex=-1,i.type="text/html",i.setAttribute("aria-hidden","true"),i.onload=function(){c||n(),function e(t,n){if(!t.contentDocument){var r=o(t);return r.checkForObjectDocumentTimeoutId&&window.clearTimeout(r.checkForObjectDocumentTimeoutId),void(r.checkForObjectDocumentTimeoutId=setTimeout((function(){r.checkForObjectDocumentTimeoutId=0,e(t,n)}),100))}n(t.contentDocument)}(this,(function(e){a(s)}))},r.isIE()||(i.data="about:blank"),o(s)&&(s.appendChild(i),o(s).object=i,r.isIE()&&(i.data="about:blank"))}o(s).startSize={width:d,height:f},n?n.add(p):p()}(s,a)},addListener:function(e,t){function n(){t(e)}if(r.isIE(8))o(e).object={proxy:n},e.attachEvent("onresize",n);else{var i=s(e);if(!i)throw new Error("Element is not detectable by this strategy.");i.contentDocument.defaultView.addEventListener("resize",n)}},uninstall:function(e){if(o(e)){var t=s(e);t&&(r.isIE(8)?e.detachEvent("onresize",t.proxy):e.removeChild(t),o(e).checkForObjectDocumentTimeoutId&&window.clearTimeout(o(e).checkForObjectDocumentTimeoutId),delete o(e).object)}}}}},{"../browser-detector":119}],122:[function(e,t,n){"use strict";var r=e("../collection-utils").forEach;t.exports=function(e){var t=(e=e||{}).reporter,n=e.batchProcessor,o=e.stateHandler.getState,i=(e.stateHandler.hasState,e.idHandler);if(!n)throw new Error("Missing required dependency: batchProcessor");if(!t)throw new Error("Missing required dependency: reporter.");var s=function(){var e=document.createElement("div");e.style.cssText=c(["position: absolute","width: 1000px","height: 1000px","visibility: hidden","margin: 0","padding: 0"]);var t=document.createElement("div");t.style.cssText=c(["position: absolute","width: 500px","height: 500px","overflow: scroll","visibility: none","top: -1500px","left: -1500px","visibility: hidden","margin: 0","padding: 0"]),t.appendChild(e),document.body.insertBefore(t,document.body.firstChild);var n=500-t.clientWidth,r=500-t.clientHeight;return document.body.removeChild(t),{width:n,height:r}}(),a="erd_scroll_detection_container";function l(e){!function(e,t,n){if(!e.getElementById(t)){var r=n+"_animation",o="/* Created by the element-resize-detector library. */\n";o+="."+n+" > div::-webkit-scrollbar { "+c(["display: none"])+" }\n\n",o+=".erd_scroll_detection_container_animation_active { "+c(["-webkit-animation-duration: 0.1s","animation-duration: 0.1s","-webkit-animation-name: "+r,"animation-name: "+r])+" }\n",o+="@-webkit-keyframes "+r+" { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } }\n",function(n,r){r=r||function(t){e.head.appendChild(t)};var o=e.createElement("style");o.innerHTML=n,o.id=t,r(o)}(o+="@keyframes "+r+" { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } }")}}(e,"erd_scroll_detection_scrollbar_style",a)}function c(t){var n=e.important?" !important; ":"; ";return(t.join(n)+n).trim()}function u(e,n,r){if(e.addEventListener)e.addEventListener(n,r);else{if(!e.attachEvent)return t.error("[scroll] Don't know how to add event listeners.");e.attachEvent("on"+n,r)}}function d(e,n,r){if(e.removeEventListener)e.removeEventListener(n,r);else{if(!e.detachEvent)return t.error("[scroll] Don't know how to remove event listeners.");e.detachEvent("on"+n,r)}}function f(e){return o(e).container.childNodes[0].childNodes[0].childNodes[0]}function p(e){return o(e).container.childNodes[0].childNodes[0].childNodes[1]}return l(window.document),{makeDetectable:function(e,l,d){function h(){if(e.debug){var n=Array.prototype.slice.call(arguments);if(n.unshift(i.get(l),"Scroll: "),t.log.apply)t.log.apply(null,n);else for(var r=0;r<n.length;r++)t.log(n[r])}}function m(e){var t=o(e).container.childNodes[0],n=window.getComputedStyle(t);return!n.width||-1===n.width.indexOf("px")}function y(){var e=window.getComputedStyle(l),t={};return t.position=e.position,t.width=l.offsetWidth,t.height=l.offsetHeight,t.top=e.top,t.right=e.right,t.bottom=e.bottom,t.left=e.left,t.widthCSS=e.width,t.heightCSS=e.height,t}function g(){if(h("storeStyle invoked."),o(l)){var e=y();o(l).style=e}else h("Aborting because element has been uninstalled")}function v(e,t,n){o(e).lastWidth=t,o(e).lastHeight=n}function b(){return 2*s.width+1}function _(){return 2*s.height+1}function w(e){return e+10+b()}function x(e){return e+10+_()}function k(e,t,n){var r=f(e),o=p(e),i=w(t),s=x(n),a=function(e){return 2*e+b()}(t),l=function(e){return 2*e+_()}(n);r.scrollLeft=i,r.scrollTop=s,o.scrollLeft=a,o.scrollTop=l}function j(){var e=o(l).container;if(!e){(e=document.createElement("div")).className=a,e.style.cssText=c(["visibility: hidden","display: inline","width: 0px","height: 0px","z-index: -1","overflow: hidden","margin: 0","padding: 0"]),o(l).container=e,function(e){e.className+=" "+a+"_animation_active"}(e),l.appendChild(e);var t=function(){o(l).onRendered&&o(l).onRendered()};u(e,"animationstart",t),o(l).onAnimationStart=t}return e}function C(){if(h("Injecting elements"),o(l)){!function(){var n=o(l).style;if("static"===n.position){l.style.setProperty("position","relative",e.important?"important":"");var r=function(e,t,n,r){var o=n[r];"auto"!==o&&"0"!==function(e){return e.replace(/[^-\d\.]/g,"")}(o)&&(e.warn("An element that is positioned static has style."+r+"="+o+" which is ignored due to the static positioning. The element will need to be positioned relative, so the style."+r+" will be set to 0. Element: ",t),t.style[r]=0)};r(t,l,n,"top"),r(t,l,n,"right"),r(t,l,n,"bottom"),r(t,l,n,"left")}}();var n=o(l).container;n||(n=j());var r,i,d,f,p=s.width,m=s.height,y=c(["position: absolute","flex: none","overflow: hidden","z-index: -1","visibility: hidden","width: 100%","height: 100%","left: 0px","top: 0px"]),g=c(["position: absolute","flex: none","overflow: hidden","z-index: -1","visibility: hidden"].concat(["left: "+(r=(r=-(1+p))?r+"px":"0"),"top: "+(i=(i=-(1+m))?i+"px":"0"),"right: "+(f=(f=-p)?f+"px":"0"),"bottom: "+(d=(d=-m)?d+"px":"0")])),v=c(["position: absolute","flex: none","overflow: scroll","z-index: -1","visibility: hidden","width: 100%","height: 100%"]),b=c(["position: absolute","flex: none","overflow: scroll","z-index: -1","visibility: hidden","width: 100%","height: 100%"]),_=c(["position: absolute","left: 0","top: 0"]),w=c(["position: absolute","width: 200%","height: 200%"]),x=document.createElement("div"),k=document.createElement("div"),C=document.createElement("div"),E=document.createElement("div"),D=document.createElement("div"),S=document.createElement("div");x.dir="ltr",x.style.cssText=y,x.className=a,k.className=a,k.style.cssText=g,C.style.cssText=v,E.style.cssText=_,D.style.cssText=b,S.style.cssText=w,C.appendChild(E),D.appendChild(S),k.appendChild(C),k.appendChild(D),x.appendChild(k),n.appendChild(x),u(C,"scroll",O),u(D,"scroll",P),o(l).onExpandScroll=O,o(l).onShrinkScroll=P}else h("Aborting because element has been uninstalled");function O(){o(l).onExpand&&o(l).onExpand()}function P(){o(l).onShrink&&o(l).onShrink()}}function E(){function s(t,n,r){var o=function(e){return f(e).childNodes[0]}(t),i=w(n),s=x(r);o.style.setProperty("width",i+"px",e.important?"important":""),o.style.setProperty("height",s+"px",e.important?"important":"")}function a(r){var a=l.offsetWidth,u=l.offsetHeight,d=a!==o(l).lastWidth||u!==o(l).lastHeight;h("Storing current size",a,u),v(l,a,u),n.add(0,(function(){if(d)if(o(l))if(c()){if(e.debug){var n=l.offsetWidth,r=l.offsetHeight;n===a&&r===u||t.warn(i.get(l),"Scroll: Size changed before updating detector elements.")}s(l,a,u)}else h("Aborting because element container has not been initialized");else h("Aborting because element has been uninstalled")})),n.add(1,(function(){o(l)?c()?k(l,a,u):h("Aborting because element container has not been initialized"):h("Aborting because element has been uninstalled")})),d&&r&&n.add(2,(function(){o(l)?c()?r():h("Aborting because element container has not been initialized"):h("Aborting because element has been uninstalled")}))}function c(){return!!o(l).container}function u(){h("notifyListenersIfNeeded invoked");var e=o(l);return void 0===o(l).lastNotifiedWidth&&e.lastWidth===e.startSize.width&&e.lastHeight===e.startSize.height?h("Not notifying: Size is the same as the start size, and there has been no notification yet."):e.lastWidth===e.lastNotifiedWidth&&e.lastHeight===e.lastNotifiedHeight?h("Not notifying: Size already notified"):(h("Current size not notified, notifying..."),e.lastNotifiedWidth=e.lastWidth,e.lastNotifiedHeight=e.lastHeight,void r(o(l).listeners,(function(e){e(l)})))}function d(){h("Scroll detected."),m(l)?h("Scroll event fired while unrendered. Ignoring..."):a(u)}if(h("registerListenersAndPositionElements invoked."),o(l)){o(l).onRendered=function(){if(h("startanimation triggered."),m(l))h("Ignoring since element is still unrendered...");else{h("Element rendered.");var e=f(l),t=p(l);0!==e.scrollLeft&&0!==e.scrollTop&&0!==t.scrollLeft&&0!==t.scrollTop||(h("Scrollbars out of sync. Updating detector elements..."),a(u))}},o(l).onExpand=d,o(l).onShrink=d;var y=o(l).style;s(l,y.width,y.height)}else h("Aborting because element has been uninstalled")}function D(){if(h("finalizeDomMutation invoked."),o(l)){var e=o(l).style;v(l,e.width,e.height),k(l,e.width,e.height)}else h("Aborting because element has been uninstalled")}function S(){d(l)}function O(){var e;h("Installing..."),o(l).listeners=[],e=y(),o(l).startSize={width:e.width,height:e.height},h("Element start size",o(l).startSize),n.add(0,g),n.add(1,C),n.add(2,E),n.add(3,D),n.add(4,S)}d||(d=l,l=e,e=null),e=e||{},h("Making detectable..."),function(e){return!function(e){var t=e.getRootNode&&e.getRootNode().contains(e);return e===e.ownerDocument.body||e.ownerDocument.body.contains(e)||t}(e)||null===window.getComputedStyle(e)}(l)?(h("Element is detached"),j(),h("Waiting until element is attached..."),o(l).onRendered=function(){h("Element is now attached"),O()}):O()},addListener:function(e,t){if(!o(e).listeners.push)throw new Error("Cannot add listener to an element that is not detectable.");o(e).listeners.push(t)},uninstall:function(e){var t=o(e);t&&(t.onExpandScroll&&d(f(e),"scroll",t.onExpandScroll),t.onShrinkScroll&&d(p(e),"scroll",t.onShrinkScroll),t.onAnimationStart&&d(t.container,"animationstart",t.onAnimationStart),t.container&&e.removeChild(t.container))},initDocument:l}}},{"../collection-utils":120}],123:[function(e,t,n){"use strict";var r=e("./collection-utils").forEach,o=e("./element-utils"),i=e("./listener-handler"),s=e("./id-generator"),a=e("./id-handler"),l=e("./reporter"),c=e("./browser-detector"),u=e("batch-processor"),d=e("./state-handler"),f=e("./detection-strategy/object.js"),p=e("./detection-strategy/scroll.js");function h(e){return Array.isArray(e)||void 0!==e.length}function m(e){if(Array.isArray(e))return e;var t=[];return r(e,(function(e){t.push(e)})),t}function y(e){return e&&1===e.nodeType}function g(e,t,n){var r=e[t];return null==r&&void 0!==n?n:r}t.exports=function(e){var t;if((e=e||{}).idHandler)t={get:function(t){return e.idHandler.get(t,!0)},set:e.idHandler.set};else{var n=s(),v=a({idGenerator:n,stateHandler:d});t=v}var b=e.reporter;b||(b=l(!1===b));var _=g(e,"batchProcessor",u({reporter:b})),w={};w.callOnAdd=!!g(e,"callOnAdd",!0),w.debug=!!g(e,"debug",!1);var x,k=i(t),j=o({stateHandler:d}),C=g(e,"strategy","object"),E=g(e,"important",!1),D={reporter:b,batchProcessor:_,stateHandler:d,idHandler:t,important:E};if("scroll"===C&&(c.isLegacyOpera()?(b.warn("Scroll strategy is not supported on legacy Opera. Changing to object strategy."),C="object"):c.isIE(9)&&(b.warn("Scroll strategy is not supported on IE9. Changing to object strategy."),C="object")),"scroll"===C)x=p(D);else{if("object"!==C)throw new Error("Invalid strategy name: "+C);x=f(D)}var S={};return{listenTo:function(e,n,o){function i(e){var t=k.get(e);r(t,(function(t){t(e)}))}function s(e,t,n){k.add(t,n),e&&n(t)}if(o||(o=n,n=e,e={}),!n)throw new Error("At least one element required.");if(!o)throw new Error("Listener required.");if(y(n))n=[n];else{if(!h(n))return b.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");n=m(n)}var a=0,l=g(e,"callOnAdd",w.callOnAdd),c=g(e,"onReady",(function(){})),u=g(e,"debug",w.debug);r(n,(function(e){d.getState(e)||(d.initState(e),t.set(e));var f=t.get(e);if(u&&b.log("Attaching listener to element",f,e),!j.isDetectable(e))return u&&b.log(f,"Not detectable."),j.isBusy(e)?(u&&b.log(f,"System busy making it detectable"),s(l,e,o),S[f]=S[f]||[],void S[f].push((function(){++a===n.length&&c()}))):(u&&b.log(f,"Making detectable..."),j.markBusy(e,!0),x.makeDetectable({debug:u,important:E},e,(function(e){if(u&&b.log(f,"onElementDetectable"),d.getState(e)){j.markAsDetectable(e),j.markBusy(e,!1),x.addListener(e,i),s(l,e,o);var t=d.getState(e);if(t&&t.startSize){var p=e.offsetWidth,h=e.offsetHeight;t.startSize.width===p&&t.startSize.height===h||i(e)}S[f]&&r(S[f],(function(e){e()}))}else u&&b.log(f,"Element uninstalled before being detectable.");delete S[f],++a===n.length&&c()})));u&&b.log(f,"Already detecable, adding listener."),s(l,e,o),a++})),a===n.length&&c()},removeListener:k.removeListener,removeAllListeners:k.removeAllListeners,uninstall:function(e){if(!e)return b.error("At least one element is required.");if(y(e))e=[e];else{if(!h(e))return b.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");e=m(e)}r(e,(function(e){k.removeAllListeners(e),x.uninstall(e),d.cleanState(e)}))},initDocument:function(e){x.initDocument&&x.initDocument(e)}}}},{"./browser-detector":119,"./collection-utils":120,"./detection-strategy/object.js":121,"./detection-strategy/scroll.js":122,"./element-utils":124,"./id-generator":125,"./id-handler":126,"./listener-handler":127,"./reporter":128,"./state-handler":129,"batch-processor":1}],124:[function(e,t,n){"use strict";t.exports=function(e){var t=e.stateHandler.getState;return{isDetectable:function(e){var n=t(e);return n&&!!n.isDetectable},markAsDetectable:function(e){t(e).isDetectable=!0},isBusy:function(e){return!!t(e).busy},markBusy:function(e,n){t(e).busy=!!n}}}},{}],125:[function(e,t,n){"use strict";t.exports=function(){var e=1;return{generate:function(){return e++}}}},{}],126:[function(e,t,n){"use strict";t.exports=function(e){var t=e.idGenerator,n=e.stateHandler.getState;return{get:function(e){var t=n(e);return t&&void 0!==t.id?t.id:null},set:function(e){var r=n(e);if(!r)throw new Error("setId required the element to have a resize detection state.");var o=t.generate();return r.id=o,o}}}},{}],127:[function(e,t,n){"use strict";t.exports=function(e){var t={};function n(n){var r=e.get(n);return void 0===r?[]:t[r]||[]}return{get:n,add:function(n,r){var o=e.get(n);t[o]||(t[o]=[]),t[o].push(r)},removeListener:function(e,t){for(var r=n(e),o=0,i=r.length;o<i;++o)if(r[o]===t){r.splice(o,1);break}},removeAllListeners:function(e){var t=n(e);t&&(t.length=0)}}}},{}],128:[function(e,t,n){"use strict";t.exports=function(e){function t(){}var n={log:t,warn:t,error:t};if(!e&&window.console){var r=function(e,t){e[t]=function(){var e=console[t];if(e.apply)e.apply(console,arguments);else for(var n=0;n<arguments.length;n++)e(arguments[n])}};r(n,"log"),r(n,"warn"),r(n,"error")}return n}},{}],129:[function(e,t,n){"use strict";function r(e){return e._erd}t.exports={initState:function(e){return e._erd={},r(e)},getState:r,cleanState:function(e){delete e._erd}}},{}],130:[function(e,t,n){var r,o;r=window,o=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){"use strict";n.r(t);var r,o=function(e,t){var n=t.x-e.x,r=t.y-e.y;return Math.sqrt(n*n+r*r)},i=function(e){return e*(Math.PI/180)},s=new Map,a=function(e){s.has(e)&&clearTimeout(s.get(e)),s.set(e,setTimeout(e,100))},l=function(e,t,n){for(var r,o=t.split(/[ ,]+/g),i=0;i<o.length;i+=1)r=o[i],e.addEventListener?e.addEventListener(r,n,!1):e.attachEvent&&e.attachEvent(r,n)},c=function(e,t,n){for(var r,o=t.split(/[ ,]+/g),i=0;i<o.length;i+=1)r=o[i],e.removeEventListener?e.removeEventListener(r,n):e.detachEvent&&e.detachEvent(r,n)},u=function(e){return e.preventDefault(),e.type.match(/^touch/)?e.changedTouches:e},d=function(){return{x:void 0!==window.pageXOffset?window.pageXOffset:(document.documentElement||document.body.parentNode||document.body).scrollLeft,y:void 0!==window.pageYOffset?window.pageYOffset:(document.documentElement||document.body.parentNode||document.body).scrollTop}},f=function(e,t){t.top||t.right||t.bottom||t.left?(e.style.top=t.top,e.style.right=t.right,e.style.bottom=t.bottom,e.style.left=t.left):(e.style.left=t.x+"px",e.style.top=t.y+"px")},p=function(e,t,n){var r=h(e);for(var o in r)if(r.hasOwnProperty(o))if("string"==typeof t)r[o]=t+" "+n;else{for(var i="",s=0,a=t.length;s<a;s+=1)i+=t[s]+" "+n+", ";r[o]=i.slice(0,-2)}return r},h=function(e){var t={};return t[e]="",["webkit","Moz","o"].forEach((function(n){t[n+e.charAt(0).toUpperCase()+e.slice(1)]=""})),t},m=function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e},y=function(e,t){if(e.length)for(var n=0,r=e.length;n<r;n+=1)t(e[n]);else t(e)},g=!!("ontouchstart"in window),v=!!window.PointerEvent,b=!!window.MSPointerEvent,_={start:"mousedown",move:"mousemove",end:"mouseup"},w={};function x(){}v?r={start:"pointerdown",move:"pointermove",end:"pointerup, pointercancel"}:b?r={start:"MSPointerDown",move:"MSPointerMove",end:"MSPointerUp"}:g?(r={start:"touchstart",move:"touchmove",end:"touchend, touchcancel"},w=_):r=_,x.prototype.on=function(e,t){var n,r=e.split(/[ ,]+/g);this._handlers_=this._handlers_||{};for(var o=0;o<r.length;o+=1)n=r[o],this._handlers_[n]=this._handlers_[n]||[],this._handlers_[n].push(t);return this},x.prototype.off=function(e,t){return this._handlers_=this._handlers_||{},void 0===e?this._handlers_={}:void 0===t?this._handlers_[e]=null:this._handlers_[e]&&this._handlers_[e].indexOf(t)>=0&&this._handlers_[e].splice(this._handlers_[e].indexOf(t),1),this},x.prototype.trigger=function(e,t){var n,r=this,o=e.split(/[ ,]+/g);r._handlers_=r._handlers_||{};for(var i=0;i<o.length;i+=1)n=o[i],r._handlers_[n]&&r._handlers_[n].length&&r._handlers_[n].forEach((function(e){e.call(r,{type:n,target:r},t)}))},x.prototype.config=function(e){this.options=this.defaults||{},e&&(this.options=function(e,t){var n={};for(var r in e)e.hasOwnProperty(r)&&t.hasOwnProperty(r)?n[r]=t[r]:e.hasOwnProperty(r)&&(n[r]=e[r]);return n}(this.options,e))},x.prototype.bindEvt=function(e,t){var n=this;return n._domHandlers_=n._domHandlers_||{},n._domHandlers_[t]=function(){"function"==typeof n["on"+t]?n["on"+t].apply(n,arguments):console.warn('[WARNING] : Missing "on'+t+'" handler.')},l(e,r[t],n._domHandlers_[t]),w[t]&&l(e,w[t],n._domHandlers_[t]),n},x.prototype.unbindEvt=function(e,t){return this._domHandlers_=this._domHandlers_||{},c(e,r[t],this._domHandlers_[t]),w[t]&&c(e,w[t],this._domHandlers_[t]),delete this._domHandlers_[t],this};var k=x;function j(e,t){return this.identifier=t.identifier,this.position=t.position,this.frontPosition=t.frontPosition,this.collection=e,this.defaults={size:100,threshold:.1,color:"white",fadeTime:250,dataOnly:!1,restJoystick:!0,restOpacity:.5,mode:"dynamic",zone:document.body,lockX:!1,lockY:!1,shape:"circle"},this.config(t),"dynamic"===this.options.mode&&(this.options.restOpacity=0),this.id=j.id,j.id+=1,this.buildEl().stylize(),this.instance={el:this.ui.el,on:this.on.bind(this),off:this.off.bind(this),show:this.show.bind(this),hide:this.hide.bind(this),add:this.addToDom.bind(this),remove:this.removeFromDom.bind(this),destroy:this.destroy.bind(this),setPosition:this.setPosition.bind(this),resetDirection:this.resetDirection.bind(this),computeDirection:this.computeDirection.bind(this),trigger:this.trigger.bind(this),position:this.position,frontPosition:this.frontPosition,ui:this.ui,identifier:this.identifier,id:this.id,options:this.options},this.instance}j.prototype=new k,j.constructor=j,j.id=0,j.prototype.buildEl=function(e){return this.ui={},this.options.dataOnly||(this.ui.el=document.createElement("div"),this.ui.back=document.createElement("div"),this.ui.front=document.createElement("div"),this.ui.el.className="nipple collection_"+this.collection.id,this.ui.back.className="back",this.ui.front.className="front",this.ui.el.setAttribute("id","nipple_"+this.collection.id+"_"+this.id),this.ui.el.appendChild(this.ui.back),this.ui.el.appendChild(this.ui.front)),this},j.prototype.stylize=function(){if(this.options.dataOnly)return this;var e=this.options.fadeTime+"ms",t=function(e,t){var n=h("borderRadius");for(var r in n)n.hasOwnProperty(r)&&(n[r]="50%");return n}(),n=p("transition","opacity",e),r={};return r.el={position:"absolute",opacity:this.options.restOpacity,display:"block",zIndex:999},r.back={position:"absolute",display:"block",width:this.options.size+"px",height:this.options.size+"px",marginLeft:-this.options.size/2+"px",marginTop:-this.options.size/2+"px",background:this.options.color,opacity:".5"},r.front={width:this.options.size/2+"px",height:this.options.size/2+"px",position:"absolute",display:"block",marginLeft:-this.options.size/4+"px",marginTop:-this.options.size/4+"px",background:this.options.color,opacity:".5"},m(r.el,n),"circle"===this.options.shape&&m(r.back,t),m(r.front,t),this.applyStyles(r),this},j.prototype.applyStyles=function(e){for(var t in this.ui)if(this.ui.hasOwnProperty(t))for(var n in e[t])this.ui[t].style[n]=e[t][n];return this},j.prototype.addToDom=function(){return this.options.dataOnly||document.body.contains(this.ui.el)||this.options.zone.appendChild(this.ui.el),this},j.prototype.removeFromDom=function(){return this.options.dataOnly||!document.body.contains(this.ui.el)||this.options.zone.removeChild(this.ui.el),this},j.prototype.destroy=function(){clearTimeout(this.removeTimeout),clearTimeout(this.showTimeout),clearTimeout(this.restTimeout),this.trigger("destroyed",this.instance),this.removeFromDom(),this.off()},j.prototype.show=function(e){var t=this;return t.options.dataOnly||(clearTimeout(t.removeTimeout),clearTimeout(t.showTimeout),clearTimeout(t.restTimeout),t.addToDom(),t.restCallback(),setTimeout((function(){t.ui.el.style.opacity=1}),0),t.showTimeout=setTimeout((function(){t.trigger("shown",t.instance),"function"==typeof e&&e.call(this)}),t.options.fadeTime)),t},j.prototype.hide=function(e){var t=this;return t.options.dataOnly||(t.ui.el.style.opacity=t.options.restOpacity,clearTimeout(t.removeTimeout),clearTimeout(t.showTimeout),clearTimeout(t.restTimeout),t.removeTimeout=setTimeout((function(){var n="dynamic"===t.options.mode?"none":"block";t.ui.el.style.display=n,"function"==typeof e&&e.call(t),t.trigger("hidden",t.instance)}),t.options.fadeTime),t.options.restJoystick&&t.setPosition(e,{x:0,y:0})),t},j.prototype.setPosition=function(e,t){var n=this;n.frontPosition={x:t.x,y:t.y};var r=n.options.fadeTime+"ms",o={};o.front=p("transition",["top","left"],r);var i={front:{}};i.front={left:n.frontPosition.x+"px",top:n.frontPosition.y+"px"},n.applyStyles(o),n.applyStyles(i),n.restTimeout=setTimeout((function(){"function"==typeof e&&e.call(n),n.restCallback()}),n.options.fadeTime)},j.prototype.restCallback=function(){var e={};e.front=p("transition","none",""),this.applyStyles(e),this.trigger("rested",this.instance)},j.prototype.resetDirection=function(){this.direction={x:!1,y:!1,angle:!1}},j.prototype.computeDirection=function(e){var t,n,r,o=e.angle.radian,i=Math.PI/4,s=Math.PI/2;if(o>i&&o<3*i&&!e.lockX?t="up":o>-i&&o<=i&&!e.lockY?t="left":o>3*-i&&o<=-i&&!e.lockX?t="down":e.lockY||(t="right"),e.lockY||(n=o>-s&&o<s?"left":"right"),e.lockX||(r=o>0?"up":"down"),e.force>this.options.threshold){var a,l={};for(a in this.direction)this.direction.hasOwnProperty(a)&&(l[a]=this.direction[a]);var c={};for(a in this.direction={x:n,y:r,angle:t},e.direction=this.direction,l)l[a]===this.direction[a]&&(c[a]=!0);if(c.x&&c.y&&c.angle)return e;c.x&&c.y||this.trigger("plain",e),c.x||this.trigger("plain:"+n,e),c.y||this.trigger("plain:"+r,e),c.angle||this.trigger("dir dir:"+t,e)}else this.resetDirection();return e};var C=j;function E(e,t){return this.nipples=[],this.idles=[],this.actives=[],this.ids=[],this.pressureIntervals={},this.manager=e,this.id=E.id,E.id+=1,this.defaults={zone:document.body,multitouch:!1,maxNumberOfNipples:10,mode:"dynamic",position:{top:0,left:0},catchDistance:200,size:100,threshold:.1,color:"white",fadeTime:250,dataOnly:!1,restJoystick:!0,restOpacity:.5,lockX:!1,lockY:!1,shape:"circle",dynamicPage:!1,follow:!1},this.config(t),"static"!==this.options.mode&&"semi"!==this.options.mode||(this.options.multitouch=!1),this.options.multitouch||(this.options.maxNumberOfNipples=1),this.updateBox(),this.prepareNipples(),this.bindings(),this.begin(),this.nipples}E.prototype=new k,E.constructor=E,E.id=0,E.prototype.prepareNipples=function(){var e=this.nipples;e.on=this.on.bind(this),e.off=this.off.bind(this),e.options=this.options,e.destroy=this.destroy.bind(this),e.ids=this.ids,e.id=this.id,e.processOnMove=this.processOnMove.bind(this),e.processOnEnd=this.processOnEnd.bind(this),e.get=function(t){if(void 0===t)return e[0];for(var n=0,r=e.length;n<r;n+=1)if(e[n].identifier===t)return e[n];return!1}},E.prototype.bindings=function(){this.bindEvt(this.options.zone,"start"),this.options.zone.style.touchAction="none",this.options.zone.style.msTouchAction="none"},E.prototype.begin=function(){var e=this.options;if("static"===e.mode){var t=this.createNipple(e.position,this.manager.getIdentifier());t.add(),this.idles.push(t)}},E.prototype.createNipple=function(e,t){var n=this.manager.scroll,r={},o=this.options;if(e.x&&e.y)r={x:e.x-(n.x+this.box.left),y:e.y-(n.y+this.box.top)};else if(e.top||e.right||e.bottom||e.left){var i=document.createElement("DIV");i.style.display="hidden",i.style.top=e.top,i.style.right=e.right,i.style.bottom=e.bottom,i.style.left=e.left,i.style.position="absolute",o.zone.appendChild(i);var s=i.getBoundingClientRect();o.zone.removeChild(i),r=e,e={x:s.left+n.x,y:s.top+n.y}}var a=new C(this,{color:o.color,size:o.size,threshold:o.threshold,fadeTime:o.fadeTime,dataOnly:o.dataOnly,restJoystick:o.restJoystick,restOpacity:o.restOpacity,mode:o.mode,identifier:t,position:e,zone:o.zone,frontPosition:{x:0,y:0},shape:o.shape});return o.dataOnly||(f(a.ui.el,r),f(a.ui.front,a.frontPosition)),this.nipples.push(a),this.trigger("added "+a.identifier+":added",a),this.manager.trigger("added "+a.identifier+":added",a),this.bindNipple(a),a},E.prototype.updateBox=function(){this.box=this.options.zone.getBoundingClientRect()},E.prototype.bindNipple=function(e){var t,n=this,r=function(e,r){t=e.type+" "+r.id+":"+e.type,n.trigger(t,r)};e.on("destroyed",n.onDestroyed.bind(n)),e.on("shown hidden rested dir plain",r),e.on("dir:up dir:right dir:down dir:left",r),e.on("plain:up plain:right plain:down plain:left",r)},E.prototype.pressureFn=function(e,t,n){var r=this,o=0;clearInterval(r.pressureIntervals[n]),r.pressureIntervals[n]=setInterval(function(){var n=e.force||e.pressure||e.webkitForce||0;n!==o&&(t.trigger("pressure",n),r.trigger("pressure "+t.identifier+":pressure",n),o=n)}.bind(r),100)},E.prototype.onstart=function(e){var t=this,n=t.options,r=e;return e=u(e),t.updateBox(),y(e,(function(o){t.actives.length<n.maxNumberOfNipples?t.processOnStart(o):r.type.match(/^touch/)&&(Object.keys(t.manager.ids).forEach((function(n){if(Object.values(r.touches).findIndex((function(e){return e.identifier===n}))<0){var o=[e[0]];o.identifier=n,t.processOnEnd(o)}})),t.actives.length<n.maxNumberOfNipples&&t.processOnStart(o))})),t.manager.bindDocument(),!1},E.prototype.processOnStart=function(e){var t,n=this,r=n.options,i=n.manager.getIdentifier(e),s=e.force||e.pressure||e.webkitForce||0,a={x:e.pageX,y:e.pageY},l=n.getOrCreate(i,a);l.identifier!==i&&n.manager.removeIdentifier(l.identifier),l.identifier=i;var c=function(t){t.trigger("start",t),n.trigger("start "+t.id+":start",t),t.show(),s>0&&n.pressureFn(e,t,t.identifier),n.processOnMove(e)};if((t=n.idles.indexOf(l))>=0&&n.idles.splice(t,1),n.actives.push(l),n.ids.push(l.identifier),"semi"!==r.mode)c(l);else{if(!(o(a,l.position)<=r.catchDistance))return l.destroy(),void n.processOnStart(e);c(l)}return l},E.prototype.getOrCreate=function(e,t){var n,r=this.options;return/(semi|static)/.test(r.mode)?(n=this.idles[0])?(this.idles.splice(0,1),n):"semi"===r.mode?this.createNipple(t,e):(console.warn("Coudln't find the needed nipple."),!1):n=this.createNipple(t,e)},E.prototype.processOnMove=function(e){var t=this.options,n=this.manager.getIdentifier(e),r=this.nipples.get(n),s=this.manager.scroll;if(function(e){return isNaN(e.buttons)?0!==e.pressure:0!==e.buttons}(e)){if(!r)return console.error("Found zombie joystick with ID "+n),void this.manager.removeIdentifier(n);if(t.dynamicPage){var a=r.el.getBoundingClientRect();r.position={x:s.x+a.left,y:s.y+a.top}}r.identifier=n;var l=r.options.size/2,c={x:e.pageX,y:e.pageY};t.lockX&&(c.y=r.position.y),t.lockY&&(c.x=r.position.x);var u,d,p,h,m,y,g,v,b,_,w=o(c,r.position),x=(u=c,p=(d=r.position).x-u.x,h=d.y-u.y,function(e){return e*(180/Math.PI)}(Math.atan2(h,p))),k=i(x),j=w/l,C={distance:w,position:c};if("circle"===r.options.shape?(m=Math.min(w,l),g=r.position,v=m,_={x:0,y:0},b=i(b=x),_.x=g.x-v*Math.cos(b),_.y=g.y-v*Math.sin(b),y=_):(y=function(e,t,n){return{x:Math.min(Math.max(e.x,t.x-n),t.x+n),y:Math.min(Math.max(e.y,t.y-n),t.y+n)}}(c,r.position,l),m=o(y,r.position)),t.follow){if(w>l){var E=c.x-y.x,D=c.y-y.y;r.position.x+=E,r.position.y+=D,r.el.style.top=r.position.y-(this.box.top+s.y)+"px",r.el.style.left=r.position.x-(this.box.left+s.x)+"px",w=o(c,r.position)}}else c=y,w=m;var S=c.x-r.position.x,O=c.y-r.position.y;r.frontPosition={x:S,y:O},t.dataOnly||f(r.ui.front,r.frontPosition);var P={identifier:r.identifier,position:c,force:j,pressure:e.force||e.pressure||e.webkitForce||0,distance:w,angle:{radian:k,degree:x},vector:{x:S/l,y:-O/l},raw:C,instance:r,lockX:t.lockX,lockY:t.lockY};(P=r.computeDirection(P)).angle={radian:i(180-x),degree:180-x},r.trigger("move",P),this.trigger("move "+r.id+":move",P)}else this.processOnEnd(e)},E.prototype.processOnEnd=function(e){var t=this,n=t.options,r=t.manager.getIdentifier(e),o=t.nipples.get(r),i=t.manager.removeIdentifier(o.identifier);o&&(n.dataOnly||o.hide((function(){"dynamic"===n.mode&&(o.trigger("removed",o),t.trigger("removed "+o.id+":removed",o),t.manager.trigger("removed "+o.id+":removed",o),o.destroy())})),clearInterval(t.pressureIntervals[o.identifier]),o.resetDirection(),o.trigger("end",o),t.trigger("end "+o.id+":end",o),t.ids.indexOf(o.identifier)>=0&&t.ids.splice(t.ids.indexOf(o.identifier),1),t.actives.indexOf(o)>=0&&t.actives.splice(t.actives.indexOf(o),1),/(semi|static)/.test(n.mode)?t.idles.push(o):t.nipples.indexOf(o)>=0&&t.nipples.splice(t.nipples.indexOf(o),1),t.manager.unbindDocument(),/(semi|static)/.test(n.mode)&&(t.manager.ids[i.id]=i.identifier))},E.prototype.onDestroyed=function(e,t){this.nipples.indexOf(t)>=0&&this.nipples.splice(this.nipples.indexOf(t),1),this.actives.indexOf(t)>=0&&this.actives.splice(this.actives.indexOf(t),1),this.idles.indexOf(t)>=0&&this.idles.splice(this.idles.indexOf(t),1),this.ids.indexOf(t.identifier)>=0&&this.ids.splice(this.ids.indexOf(t.identifier),1),this.manager.removeIdentifier(t.identifier),this.manager.unbindDocument()},E.prototype.destroy=function(){for(var e in this.unbindEvt(this.options.zone,"start"),this.nipples.forEach((function(e){e.destroy()})),this.pressureIntervals)this.pressureIntervals.hasOwnProperty(e)&&clearInterval(this.pressureIntervals[e]);this.trigger("destroyed",this.nipples),this.manager.unbindDocument(),this.off()};var D=E;function S(e){var t=this;t.ids={},t.index=0,t.collections=[],t.scroll=d(),t.config(e),t.prepareCollections();var n=function(){var e;t.collections.forEach((function(n){n.forEach((function(n){e=n.el.getBoundingClientRect(),n.position={x:t.scroll.x+e.left,y:t.scroll.y+e.top}}))}))};l(window,"resize",(function(){a(n)}));var r=function(){t.scroll=d()};return l(window,"scroll",(function(){a(r)})),t.collections}S.prototype=new k,S.constructor=S,S.prototype.prepareCollections=function(){var e=this;e.collections.create=e.create.bind(e),e.collections.on=e.on.bind(e),e.collections.off=e.off.bind(e),e.collections.destroy=e.destroy.bind(e),e.collections.get=function(t){var n;return e.collections.every((function(e){return!(n=e.get(t))})),n}},S.prototype.create=function(e){return this.createCollection(e)},S.prototype.createCollection=function(e){var t=new D(this,e);return this.bindCollection(t),this.collections.push(t),t},S.prototype.bindCollection=function(e){var t,n=this,r=function(e,r){t=e.type+" "+r.id+":"+e.type,n.trigger(t,r)};e.on("destroyed",n.onDestroyed.bind(n)),e.on("shown hidden rested dir plain",r),e.on("dir:up dir:right dir:down dir:left",r),e.on("plain:up plain:right plain:down plain:left",r)},S.prototype.bindDocument=function(){this.binded||(this.bindEvt(document,"move").bindEvt(document,"end"),this.binded=!0)},S.prototype.unbindDocument=function(e){Object.keys(this.ids).length&&!0!==e||(this.unbindEvt(document,"move").unbindEvt(document,"end"),this.binded=!1)},S.prototype.getIdentifier=function(e){var t;return e?void 0===(t=void 0===e.identifier?e.pointerId:e.identifier)&&(t=this.latest||0):t=this.index,void 0===this.ids[t]&&(this.ids[t]=this.index,this.index+=1),this.latest=t,this.ids[t]},S.prototype.removeIdentifier=function(e){var t={};for(var n in this.ids)if(this.ids[n]===e){t.id=n,t.identifier=this.ids[n],delete this.ids[n];break}return t},S.prototype.onmove=function(e){return this.onAny("move",e),!1},S.prototype.onend=function(e){return this.onAny("end",e),!1},S.prototype.oncancel=function(e){return this.onAny("end",e),!1},S.prototype.onAny=function(e,t){var n,r=this,o="processOn"+e.charAt(0).toUpperCase()+e.slice(1);return t=u(t),y(t,(function(e){n=r.getIdentifier(e),y(r.collections,function(e,t,n){n.ids.indexOf(t)>=0&&(n[o](e),e._found_=!0)}.bind(null,e,n)),e._found_||r.removeIdentifier(n)})),!1},S.prototype.destroy=function(){this.unbindDocument(!0),this.ids={},this.index=0,this.collections.forEach((function(e){e.destroy()})),this.off()},S.prototype.onDestroyed=function(e,t){if(this.collections.indexOf(t)<0)return!1;this.collections.splice(this.collections.indexOf(t),1)};var O=new S;t.default={create:function(e){return O.create(e)},factory:O}}]).default},"object"==typeof n&&"object"==typeof t?t.exports=o():"function"==typeof define&&define.amd?define("nipplejs",[],o):"object"==typeof n?n.nipplejs=o():r.nipplejs=o()},{}],131:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});
2
2
  /*! *****************************************************************************
3
3
  Copyright (c) Microsoft Corporation.
4
4
 
@@ -13,5 +13,5 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
13
13
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14
14
  PERFORMANCE OF THIS SOFTWARE.
15
15
  ***************************************************************************** */
16
- var r,o=function(){return o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},o.apply(this,arguments)},i=function(){function e(e){this.options=e,this.listeners={}}return e.prototype.on=function(e,t){var n=this.listeners[e]||[];this.listeners[e]=n.concat([t])},e.prototype.triggerEvent=function(e,t){var n=this;(this.listeners[e]||[]).forEach((function(e){return e({target:n,event:t})}))},e}();(r=n.NotyfArrayEvent||(n.NotyfArrayEvent={}))[r.Add=0]="Add",r[r.Remove=1]="Remove";var s,a=function(){function e(){this.notifications=[]}return e.prototype.push=function(e){this.notifications.push(e),this.updateFn(e,n.NotyfArrayEvent.Add,this.notifications)},e.prototype.splice=function(e,t){var r=this.notifications.splice(e,t)[0];return this.updateFn(r,n.NotyfArrayEvent.Remove,this.notifications),r},e.prototype.indexOf=function(e){return this.notifications.indexOf(e)},e.prototype.onUpdate=function(e){this.updateFn=e},e}();(s=n.NotyfEvent||(n.NotyfEvent={})).Dismiss="dismiss",s.Click="click";var l={types:[{type:"success",className:"notyf__toast--success",backgroundColor:"#3dc763",icon:{className:"notyf__icon--success",tagName:"i"}},{type:"error",className:"notyf__toast--error",backgroundColor:"#ed3d3d",icon:{className:"notyf__icon--error",tagName:"i"}}],duration:2e3,ripple:!0,position:{x:"right",y:"bottom"},dismissible:!1},c=function(){function e(){this.notifications=[],this.events={},this.X_POSITION_FLEX_MAP={left:"flex-start",center:"center",right:"flex-end"},this.Y_POSITION_FLEX_MAP={top:"flex-start",center:"center",bottom:"flex-end"};var e=document.createDocumentFragment(),t=this._createHTMLElement({tagName:"div",className:"notyf"});e.appendChild(t),document.body.appendChild(e),this.container=t,this.animationEndEventName=this._getAnimationEndEventName(),this._createA11yContainer()}return e.prototype.on=function(e,t){var n;this.events=o(o({},this.events),((n={})[e]=t,n))},e.prototype.update=function(e,t){t===n.NotyfArrayEvent.Add?this.addNotification(e):t===n.NotyfArrayEvent.Remove&&this.removeNotification(e)},e.prototype.removeNotification=function(e){var t,n,r=this,o=this._popRenderedNotification(e);o&&((t=o.node).classList.add("notyf__toast--disappear"),t.addEventListener(this.animationEndEventName,n=function(e){e.target===t&&(t.removeEventListener(r.animationEndEventName,n),r.container.removeChild(t))}))},e.prototype.addNotification=function(e){var t=this._renderNotification(e);this.notifications.push({notification:e,node:t}),this._announce(e.options.message||"Notification")},e.prototype._renderNotification=function(e){var t,n=this._buildNotificationCard(e),r=e.options.className;return r&&(t=n.classList).add.apply(t,r.split(" ")),this.container.appendChild(n),n},e.prototype._popRenderedNotification=function(e){for(var t=-1,n=0;n<this.notifications.length&&t<0;n++)this.notifications[n].notification===e&&(t=n);if(-1!==t)return this.notifications.splice(t,1)[0]},e.prototype.getXPosition=function(e){var t;return(null===(t=null==e?void 0:e.position)||void 0===t?void 0:t.x)||"right"},e.prototype.getYPosition=function(e){var t;return(null===(t=null==e?void 0:e.position)||void 0===t?void 0:t.y)||"bottom"},e.prototype.adjustContainerAlignment=function(e){var t=this.X_POSITION_FLEX_MAP[this.getXPosition(e)],n=this.Y_POSITION_FLEX_MAP[this.getYPosition(e)],r=this.container.style;r.setProperty("justify-content",n),r.setProperty("align-items",t)},e.prototype._buildNotificationCard=function(e){var t=this,r=e.options,o=r.icon;this.adjustContainerAlignment(r);var i=this._createHTMLElement({tagName:"div",className:"notyf__toast"}),s=this._createHTMLElement({tagName:"div",className:"notyf__ripple"}),a=this._createHTMLElement({tagName:"div",className:"notyf__wrapper"}),l=this._createHTMLElement({tagName:"div",className:"notyf__message"});l.innerHTML=r.message||"";var c=r.background||r.backgroundColor;if(o){var u=this._createHTMLElement({tagName:"div",className:"notyf__icon"});if(("string"==typeof o||o instanceof String)&&(u.innerHTML=new String(o).valueOf()),"object"==typeof o){var d=o.tagName,f=void 0===d?"i":d,p=o.className,h=o.text,m=o.color,y=void 0===m?c:m,v=this._createHTMLElement({tagName:f,className:p,text:h});y&&(v.style.color=y),u.appendChild(v)}a.appendChild(u)}if(a.appendChild(l),i.appendChild(a),c&&(r.ripple?(s.style.background=c,i.appendChild(s)):i.style.background=c),r.dismissible){var g=this._createHTMLElement({tagName:"div",className:"notyf__dismiss"}),b=this._createHTMLElement({tagName:"button",className:"notyf__dismiss-btn"});g.appendChild(b),a.appendChild(g),i.classList.add("notyf__toast--dismissible"),b.addEventListener("click",(function(r){var o,i;null===(i=(o=t.events)[n.NotyfEvent.Dismiss])||void 0===i||i.call(o,{target:e,event:r}),r.stopPropagation()}))}i.addEventListener("click",(function(r){var o,i;return null===(i=(o=t.events)[n.NotyfEvent.Click])||void 0===i?void 0:i.call(o,{target:e,event:r})}));var _="top"===this.getYPosition(r)?"upper":"lower";return i.classList.add("notyf__toast--"+_),i},e.prototype._createHTMLElement=function(e){var t=e.tagName,n=e.className,r=e.text,o=document.createElement(t);return n&&(o.className=n),o.textContent=r||null,o},e.prototype._createA11yContainer=function(){var e=this._createHTMLElement({tagName:"div",className:"notyf-announcer"});e.setAttribute("aria-atomic","true"),e.setAttribute("aria-live","polite"),e.style.border="0",e.style.clip="rect(0 0 0 0)",e.style.height="1px",e.style.margin="-1px",e.style.overflow="hidden",e.style.padding="0",e.style.position="absolute",e.style.width="1px",e.style.outline="0",document.body.appendChild(e),this.a11yContainer=e},e.prototype._announce=function(e){var t=this;this.a11yContainer.textContent="",setTimeout((function(){t.a11yContainer.textContent=e}),100)},e.prototype._getAnimationEndEventName=function(){var e,t=document.createElement("_fake"),n={MozTransition:"animationend",OTransition:"oAnimationEnd",WebkitTransition:"webkitAnimationEnd",transition:"animationend"};for(e in n)if(void 0!==t.style[e])return n[e];return"animationend"},e}(),u=function(){function e(e){var t=this;this.dismiss=this._removeNotification,this.notifications=new a,this.view=new c;var r=this.registerTypes(e);this.options=o(o({},l),e),this.options.types=r,this.notifications.onUpdate((function(e,n){return t.view.update(e,n)})),this.view.on(n.NotyfEvent.Dismiss,(function(e){var r=e.target,o=e.event;t._removeNotification(r),r.triggerEvent(n.NotyfEvent.Dismiss,o)})),this.view.on(n.NotyfEvent.Click,(function(e){var t=e.target,r=e.event;return t.triggerEvent(n.NotyfEvent.Click,r)}))}return e.prototype.error=function(e){var t=this.normalizeOptions("error",e);return this.open(t)},e.prototype.success=function(e){var t=this.normalizeOptions("success",e);return this.open(t)},e.prototype.open=function(e){var t=this.options.types.find((function(t){return t.type===e.type}))||{},n=o(o({},t),e);this.assignProps(["ripple","position","dismissible"],n);var r=new i(n);return this._pushNotification(r),r},e.prototype.dismissAll=function(){for(;this.notifications.splice(0,1););},e.prototype.assignProps=function(e,t){var n=this;e.forEach((function(e){t[e]=null==t[e]?n.options[e]:t[e]}))},e.prototype._pushNotification=function(e){var t=this;this.notifications.push(e);var n=void 0!==e.options.duration?e.options.duration:this.options.duration;n&&setTimeout((function(){return t._removeNotification(e)}),n)},e.prototype._removeNotification=function(e){var t=this.notifications.indexOf(e);-1!==t&&this.notifications.splice(t,1)},e.prototype.normalizeOptions=function(e,t){var n={type:e};return"string"==typeof t?n.message=t:"object"==typeof t&&(n=o(o({},n),t)),n},e.prototype.registerTypes=function(e){var t=(e&&e.types||[]).slice();return l.types.map((function(e){var n=-1;t.forEach((function(t,r){t.type===e.type&&(n=r)}));var r=-1!==n?t.splice(n,1)[0]:{};return o(o({},e),r)})).concat(t)},e}();n.DEFAULT_OPTIONS=l,n.Notyf=u,n.NotyfArray=a,n.NotyfNotification=i,n.NotyfView=c},{}],132:[function(e,t,n){var r;r=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n(n.s=0)}([function(e,t,n){e.exports=n(1)},function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}n.r(t);var s,a,l,c=function(){function e(t){var n=t.getOptions,r=t.getCaretPosition,o=t.getCaretPositionEnd,i=t.dispatch;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.getOptions=n,this.getCaretPosition=r,this.getCaretPositionEnd=o,this.dispatch=i,e.bindMethods(e,this)}var t,n,s;return t=e,s=[{key:"bindMethods",value:function(e,t){var n,o=function(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))){n&&(e=n);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,l=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw s}}}}(Object.getOwnPropertyNames(e.prototype));try{for(o.s();!(n=o.n()).done;){var i=n.value;"constructor"===i||"bindMethods"===i||(t[i]=t[i].bind(t))}}catch(e){o.e(e)}finally{o.f()}}}],(n=[{key:"getButtonClass",value:function(e){var t=e.includes("{")&&e.includes("}")&&"{//}"!==e?"functionBtn":"standardBtn",n=e.replace("{","").replace("}",""),r="";return"standardBtn"!==t&&(r=" hg-button-".concat(n)),"hg-".concat(t).concat(r)}},{key:"getDefaultDiplay",value:function(){return{"{bksp}":"backspace","{backspace}":"backspace","{enter}":"< enter","{shift}":"shift","{shiftleft}":"shift","{shiftright}":"shift","{alt}":"alt","{s}":"shift","{tab}":"tab","{lock}":"caps","{capslock}":"caps","{accept}":"Submit","{space}":" ","{//}":" ","{esc}":"esc","{escape}":"esc","{f1}":"f1","{f2}":"f2","{f3}":"f3","{f4}":"f4","{f5}":"f5","{f6}":"f6","{f7}":"f7","{f8}":"f8","{f9}":"f9","{f10}":"f10","{f11}":"f11","{f12}":"f12","{numpaddivide}":"/","{numlock}":"lock","{arrowup}":"↑","{arrowleft}":"←","{arrowdown}":"↓","{arrowright}":"→","{prtscr}":"print","{scrolllock}":"scroll","{pause}":"pause","{insert}":"ins","{home}":"home","{pageup}":"up","{delete}":"del","{end}":"end","{pagedown}":"down","{numpadmultiply}":"*","{numpadsubtract}":"-","{numpadadd}":"+","{numpadenter}":"enter","{period}":".","{numpaddecimal}":".","{numpad0}":"0","{numpad1}":"1","{numpad2}":"2","{numpad3}":"3","{numpad4}":"4","{numpad5}":"5","{numpad6}":"6","{numpad7}":"7","{numpad8}":"8","{numpad9}":"9"}}},{key:"getButtonDisplayName",value:function(e,t,n){return(t=n?Object.assign({},this.getDefaultDiplay(),t):t||this.getDefaultDiplay())[e]||e}},{key:"getUpdatedInput",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:n,o=arguments.length>4&&void 0!==arguments[4]&&arguments[4],i=this.getOptions(),s=[n,r,o],a=t;return("{bksp}"===e||"{backspace}"===e)&&a.length>0?a=this.removeAt.apply(this,[a].concat(s)):"{space}"===e?a=this.addStringAt.apply(this,[a," "].concat(s)):"{tab}"!==e||"boolean"==typeof i.tabCharOnTab&&!1===i.tabCharOnTab?"{enter}"!==e&&"{numpadenter}"!==e||!i.newLineOnEnter?e.includes("numpad")&&Number.isInteger(Number(e[e.length-2]))?a=this.addStringAt.apply(this,[a,e[e.length-2]].concat(s)):"{numpaddivide}"===e?a=this.addStringAt.apply(this,[a,"/"].concat(s)):"{numpadmultiply}"===e?a=this.addStringAt.apply(this,[a,"*"].concat(s)):"{numpadsubtract}"===e?a=this.addStringAt.apply(this,[a,"-"].concat(s)):"{numpadadd}"===e?a=this.addStringAt.apply(this,[a,"+"].concat(s)):"{numpaddecimal}"===e?a=this.addStringAt.apply(this,[a,"."].concat(s)):"{"===e||"}"===e?a=this.addStringAt.apply(this,[a,e].concat(s)):e.includes("{")||e.includes("}")||(a=this.addStringAt.apply(this,[a,e].concat(s))):a=this.addStringAt.apply(this,[a,"\n"].concat(s)):a=this.addStringAt.apply(this,[a,"\t"].concat(s)),a}},{key:"updateCaretPos",value:function(e,t){var n=this.updateCaretPosAction(e,t);this.dispatch((function(e){e.setCaretPosition(n)}))}},{key:"updateCaretPosAction",value:function(e,t){var n=this.getOptions(),r=this.getCaretPosition();return t?r>0&&(r-=e):r+=e,n.debug&&console.log("Caret at:",r,"(".concat(this.keyboardDOMClass,")")),r}},{key:"addStringAt",value:function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:e.length,i=arguments.length>4&&void 0!==arguments[4]&&arguments[4];return r||0===r?(n=[e.slice(0,r),t,e.slice(o)].join(""),this.isMaxLengthReached()||i&&this.updateCaretPos(t.length)):n=e+t,n}},{key:"removeAt",value:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.length,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(0===n&&0===r)return e;if(n===r){var i=/([\uD800-\uDBFF][\uDC00-\uDFFF])/g;n&&n>=0?e.substring(n-2,n).match(i)?(t=e.substr(0,n-2)+e.substr(n),o&&this.updateCaretPos(2,!0)):(t=e.substr(0,n-1)+e.substr(n),o&&this.updateCaretPos(1,!0)):e.slice(-2).match(i)?(t=e.slice(0,-2),o&&this.updateCaretPos(2,!0)):(t=e.slice(0,-1),o&&this.updateCaretPos(1,!0))}else t=e.slice(0,n)+e.slice(r),o&&this.dispatch((function(e){e.setCaretPosition(n)}));return t}},{key:"handleMaxLength",value:function(e,t){var n=this.getOptions(),r=n.maxLength,i=e[n.inputName],s=t.length-1>=r;if(t.length<=i.length)return!1;if(Number.isInteger(r))return n.debug&&console.log("maxLength (num) reached:",s),s?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1);if("object"===o(r)){var a=t.length-1>=r[n.inputName];return n.debug&&console.log("maxLength (obj) reached:",a),a?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1)}}},{key:"isMaxLengthReached",value:function(){return Boolean(this.maxLengthReached)}},{key:"isTouchDevice",value:function(){return"ontouchstart"in window||navigator.maxTouchPoints}},{key:"pointerEventsSupported",value:function(){return window.PointerEvent}},{key:"camelCase",value:function(e){return!!e&&e.toLowerCase().trim().split(/[.\-_\s]/g).reduce((function(e,t){return t.length?e+t[0].toUpperCase()+t.slice(1):e}))}}])&&i(t.prototype,n),s&&i(t,s),e}();l=function(){},(a="noop")in(s=c)?Object.defineProperty(s,a,{value:l,enumerable:!0,configurable:!0,writable:!0}):s[a]=l;var u=c;var d=function(){function e(t){var n=t.dispatch,r=t.getOptions;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.dispatch=n,this.getOptions=r,u.bindMethods(e,this)}var t;return(t=[{key:"handleHighlightKeyDown",value:function(e){var t=this.getOptions(),n=this.getSimpleKeyboardLayoutKey(e);this.dispatch((function(e){var r=e.getButtonElement(n)||e.getButtonElement("{".concat(n,"}"));r&&(r.style.backgroundColor=t.physicalKeyboardHighlightBgColor||"#dadce4",r.style.color=t.physicalKeyboardHighlightTextColor||"black",t.physicalKeyboardHighlightPress&&(r.onpointerdown||r.onmousedown||r.ontouchstart||u.noop)())}))}},{key:"handleHighlightKeyUp",value:function(e){var t=this.getOptions(),n=this.getSimpleKeyboardLayoutKey(e);this.dispatch((function(e){var r=e.getButtonElement(n)||e.getButtonElement("{".concat(n,"}"));r&&r.removeAttribute&&(r.removeAttribute("style"),t.physicalKeyboardHighlightPress&&(r.onpointerup||r.onmouseup||r.ontouchend||u.noop)())}))}},{key:"getSimpleKeyboardLayoutKey",value:function(e){var t;return((t=e.code.includes("Numpad")||e.code.includes("Shift")||e.code.includes("Space")||e.code.includes("Backspace")||e.code.includes("Control")||e.code.includes("Alt")||e.code.includes("Meta")?e.code:e.key)&&t!==t.toUpperCase()||"F"===e.code[0]&&Number.isInteger(Number(e.code[1]))&&e.code.length<=3)&&(t=t?t.toLowerCase():t),t}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}();function f(e){return function(e){if(Array.isArray(e))return p(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return p(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?p(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var y=function(){function e(){var t=this;h(this,e),m(this,"handleParams",(function(e){var t,n,r;if("string"==typeof e[0])t=e[0].split(".").join(""),n=document.querySelector(".".concat(t)),r=e[1];else if(e[0]instanceof HTMLDivElement){if(!e[0].className)throw console.warn("Any DOM element passed as parameter must have a class."),new Error("KEYBOARD_DOM_CLASS_ERROR");t=e[0].className.split(" ")[0],n=e[0],r=e[1]}else t="simple-keyboard",n=document.querySelector(".".concat(t)),r=e[0];return{keyboardDOMClass:t,keyboardDOM:n,options:r}})),m(this,"getOptions",(function(){return t.options})),m(this,"getCaretPosition",(function(){return t.caretPosition})),m(this,"getCaretPositionEnd",(function(){return t.caretPositionEnd})),m(this,"registerModule",(function(e,n){t.modules[e]||(t.modules[e]={}),n(t.modules[e])})),m(this,"getKeyboardClassString",(function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];var o=[t.keyboardDOMClass].concat(n).filter((function(e){return!!e}));return o.join(" ")}));for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];var i=this.handleParams(r),s=i.keyboardDOMClass,a=i.keyboardDOM,l=i.options,c=void 0===l?{}:l;if(this.utilities=new u({getOptions:this.getOptions,getCaretPosition:this.getCaretPosition,getCaretPositionEnd:this.getCaretPositionEnd,dispatch:this.dispatch}),this.caretPosition=null,this.caretPositionEnd=null,this.keyboardDOM=a,this.options=c,this.options.layoutName=this.options.layoutName||"default",this.options.theme=this.options.theme||"hg-theme-default",this.options.inputName=this.options.inputName||"default",this.options.preventMouseDownDefault=this.options.preventMouseDownDefault||!1,this.keyboardPluginClasses="",u.bindMethods(e,this),this.input={},this.input[this.options.inputName]="",this.keyboardDOMClass=s,this.buttonElements={},window.SimpleKeyboardInstances||(window.SimpleKeyboardInstances={}),this.currentInstanceName=this.utilities.camelCase(this.keyboardDOMClass),window.SimpleKeyboardInstances[this.currentInstanceName]=this,this.allKeyboardInstances=window.SimpleKeyboardInstances,this.keyboardInstanceNames=Object.keys(window.SimpleKeyboardInstances),this.isFirstKeyboardInstance=this.keyboardInstanceNames[0]===this.currentInstanceName,this.physicalKeyboard=new d({dispatch:this.dispatch,getOptions:this.getOptions}),!this.keyboardDOM)throw console.warn('".'.concat(s,'" was not found in the DOM.')),new Error("KEYBOARD_DOM_ERROR");this.render(),this.modules={},this.loadModules()}var t;return(t=[{key:"setCaretPosition",value:function(e,t){this.caretPosition=e,this.caretPositionEnd=t||e}},{key:"handleButtonClicked",value:function(e){var t=this.options.debug;if("{//}"===e)return!1;"function"==typeof this.options.onKeyPress&&this.options.onKeyPress(e),this.input[this.options.inputName]||(this.input[this.options.inputName]="");var n=this.utilities.getUpdatedInput(e,this.input[this.options.inputName],this.caretPosition,this.caretPositionEnd);if(this.input[this.options.inputName]!==n&&(!this.options.inputPattern||this.options.inputPattern&&this.inputPatternIsValid(n))){if(this.options.maxLength&&this.utilities.handleMaxLength(this.input,n))return!1;this.input[this.options.inputName]=this.utilities.getUpdatedInput(e,this.input[this.options.inputName],this.caretPosition,this.caretPositionEnd,!0),t&&console.log("Input changed:",this.getAllInputs()),this.options.debug&&console.log("Caret at: ",this.getCaretPosition(),this.getCaretPositionEnd(),"(".concat(this.keyboardDOMClass,")")),this.options.syncInstanceInputs&&this.syncInstanceInputs(),"function"==typeof this.options.onChange&&this.options.onChange(this.getInput(this.options.inputName,!0)),"function"==typeof this.options.onChangeAll&&this.options.onChangeAll(this.getAllInputs())}t&&console.log("Key pressed:",e)}},{key:"handleButtonMouseDown",value:function(e,t){var n=this;t&&(this.options.preventMouseDownDefault&&t.preventDefault(),this.options.stopMouseDownPropagation&&t.stopPropagation(),t.target.classList.add(this.activeButtonClass)),this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),this.holdTimeout&&clearTimeout(this.holdTimeout),this.isMouseHold=!0,this.options.disableButtonHold||(this.holdTimeout=setTimeout((function(){(n.isMouseHold&&(!e.includes("{")&&!e.includes("}")||"{delete}"===e||"{backspace}"===e||"{bksp}"===e||"{space}"===e||"{tab}"===e)||"{arrowright}"===e||"{arrowleft}"===e||"{arrowup}"===e||"{arrowdown}"===e)&&(n.options.debug&&console.log("Button held:",e),n.handleButtonHold(e,t)),clearTimeout(n.holdTimeout)}),500))}},{key:"handleButtonMouseUp",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;n&&(this.options.preventMouseUpDefault&&n.preventDefault(),this.options.stopMouseUpPropagation&&n.stopPropagation()),this.recurseButtons((function(t){t.classList.remove(e.activeButtonClass)})),this.isMouseHold=!1,this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),t&&"function"==typeof this.options.onKeyReleased&&this.options.onKeyReleased(t)}},{key:"handleKeyboardContainerMouseDown",value:function(e){this.options.preventMouseDownDefault&&e.preventDefault()}},{key:"handleButtonHold",value:function(e){var t=this;this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),this.holdInteractionTimeout=setTimeout((function(){t.isMouseHold?(t.handleButtonClicked(e),t.handleButtonHold(e)):clearTimeout(t.holdInteractionTimeout)}),100)}},{key:"syncInstanceInputs",value:function(){var e=this;this.dispatch((function(t){t.replaceInput(e.input),t.setCaretPosition(e.caretPosition,e.caretPositionEnd)}))}},{key:"clearInput",value:function(e){e=e||this.options.inputName,this.input[e]="",this.setCaretPosition(0),this.options.syncInstanceInputs&&this.syncInstanceInputs()}},{key:"getInput",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=e||this.options.inputName,this.options.syncInstanceInputs&&!t&&this.syncInstanceInputs(),this.options.rtl){var n=this.input[e].replace("‫","").replace("‬","");return"‫"+n+"‬"}return this.input[e]}},{key:"getAllInputs",value:function(){var e=this,t={};return Object.keys(this.input).forEach((function(n){t[n]=e.getInput(n,!0)})),t}},{key:"setInput",value:function(e,t){t=t||this.options.inputName,this.input[t]=e,this.options.syncInstanceInputs&&this.syncInstanceInputs()}},{key:"replaceInput",value:function(e){this.input=e}},{key:"setOptions",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=this.changedOptions(e);this.options=Object.assign(this.options,e),t.length&&(this.options.debug&&console.log("changedOptions",t),this.onSetOptions(e),this.render())}},{key:"changedOptions",value:function(e){var t=this;return Object.keys(e).filter((function(n){return JSON.stringify(e[n])!==JSON.stringify(t.options[n])}))}},{key:"onSetOptions",value:function(e){e.inputName&&(this.options.debug&&console.log("inputName changed. caretPosition reset."),this.setCaretPosition(null))}},{key:"clear",value:function(){this.keyboardDOM.innerHTML="",this.keyboardDOM.className=this.keyboardDOMClass,this.buttonElements={}}},{key:"dispatch",value:function(e){if(!window.SimpleKeyboardInstances)throw console.warn("SimpleKeyboardInstances is not defined. Dispatch cannot be called."),new Error("INSTANCES_VAR_ERROR");return Object.keys(window.SimpleKeyboardInstances).forEach((function(t){e(window.SimpleKeyboardInstances[t],t)}))}},{key:"addButtonTheme",value:function(e,t){var n=this;if(!t||!e)return!1;e.split(" ").forEach((function(r){t.split(" ").forEach((function(t){n.options.buttonTheme||(n.options.buttonTheme=[]);var o=!1;n.options.buttonTheme.map((function(e){if(e.class.split(" ").includes(t)){o=!0;var n=e.buttons.split(" ");n.includes(r)||(o=!0,n.push(r),e.buttons=n.join(" "))}return e})),o||n.options.buttonTheme.push({class:t,buttons:e})}))})),this.render()}},{key:"removeButtonTheme",value:function(e,t){var n=this;if(!e&&!t)return this.options.buttonTheme=[],this.render(),!1;e&&Array.isArray(this.options.buttonTheme)&&this.options.buttonTheme.length&&(e.split(" ").forEach((function(e){n.options.buttonTheme.map((function(r,o){if(t&&t.includes(r.class)||!t){var i=r.buttons.split(" ").filter((function(t){return t!==e}));i.length?r.buttons=i.join(" "):(n.options.buttonTheme.splice(o,1),r=null)}return r}))})),this.render())}},{key:"getButtonElement",value:function(e){var t,n=this.buttonElements[e];return n&&(t=n.length>1?n:n[0]),t}},{key:"inputPatternIsValid",value:function(e){var t,n=this.options.inputPattern;if((t=n instanceof RegExp?n:n[this.options.inputName])&&e){var r=t.test(e);return this.options.debug&&console.log('inputPattern ("'.concat(t,'"): ').concat(r?"passed":"did not pass!")),r}return!0}},{key:"setEventListeners",value:function(){!this.isFirstKeyboardInstance&&this.allKeyboardInstances||(this.options.debug&&console.log("Caret handling started (".concat(this.keyboardDOMClass,")")),document.addEventListener("keyup",this.handleKeyUp),document.addEventListener("keydown",this.handleKeyDown),document.addEventListener("mouseup",this.handleMouseUp),document.addEventListener("touchend",this.handleTouchEnd))}},{key:"handleKeyUp",value:function(e){this.caretEventHandler(e),this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyUp(e)}},{key:"handleKeyDown",value:function(e){this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyDown(e)}},{key:"handleMouseUp",value:function(e){this.caretEventHandler(e)}},{key:"handleTouchEnd",value:function(e){this.caretEventHandler(e)}},{key:"caretEventHandler",value:function(e){var t;e.target.tagName&&(t=e.target.tagName.toLowerCase()),this.dispatch((function(n){var r=e.target===n.keyboardDOM||e.target&&n.keyboardDOM.contains(e.target);n.isMouseHold&&(n.isMouseHold=!1),"textarea"!==t&&"input"!==t||!["text","search","url","tel","password"].includes(e.target.type)||n.options.disableCaretPositioning?!n.options.disableCaretPositioning&&r||n.setCaretPosition(null):(n.setCaretPosition(e.target.selectionStart,e.target.selectionEnd),n.options.debug&&console.log("Caret at: ",n.getCaretPosition(),n.getCaretPositionEnd(),e&&e.target.tagName.toLowerCase(),"(".concat(n.keyboardDOMClass,")")))}))}},{key:"recurseButtons",value:function(e){var t=this;e&&Object.keys(this.buttonElements).forEach((function(n){return t.buttonElements[n].forEach(e)}))}},{key:"destroy",value:function(){this.options.debug&&console.log("Destroying simple-keyboard instance: ".concat(this.currentInstanceName)),document.removeEventListener("keyup",this.handleKeyUp),document.removeEventListener("keydown",this.handleKeyDown),document.removeEventListener("mouseup",this.handleMouseUp),document.removeEventListener("touchend",this.handleTouchEnd),document.onpointerup=null,document.ontouchend=null,document.ontouchcancel=null,document.onmouseup=null;var e=function(e){e.onpointerdown=null,e.onpointerup=null,e.onpointercancel=null,e.ontouchstart=null,e.ontouchend=null,e.ontouchcancel=null,e.onclick=null,e.onmousedown=null,e.onmouseup=null,e.remove(),e=null};this.recurseButtons(e),this.recurseButtons=null,e=null,this.keyboardDOM.onpointerdown=null,this.keyboardDOM.ontouchstart=null,this.keyboardDOM.onmousedown=null,this.clear(),window.SimpleKeyboardInstances[this.currentInstanceName]=null,delete window.SimpleKeyboardInstances[this.currentInstanceName],this.initialized=!1}},{key:"getButtonThemeClasses",value:function(e){var t=this.options.buttonTheme,n=[];return Array.isArray(t)&&t.forEach((function(t){if(t.class&&"string"==typeof t.class&&t.buttons&&"string"==typeof t.buttons){var r=t.class.split(" ");t.buttons.split(" ").includes(e)&&(n=[].concat(f(n),f(r)))}else console.warn('Incorrect "buttonTheme". Please check the documentation.',t)})),n}},{key:"setDOMButtonAttributes",value:function(e,t){var n=this.options.buttonAttributes;Array.isArray(n)&&n.forEach((function(n){n.attribute&&"string"==typeof n.attribute&&n.value&&"string"==typeof n.value&&n.buttons&&"string"==typeof n.buttons?n.buttons.split(" ").includes(e)&&t(n.attribute,n.value):console.warn('Incorrect "buttonAttributes". Please check the documentation.',n)}))}},{key:"onTouchDeviceDetected",value:function(){this.processAutoTouchEvents(),this.disableContextualWindow()}},{key:"disableContextualWindow",value:function(){window.oncontextmenu=function(e){if(e.target.classList.contains("hg-button"))return e.preventDefault(),e.stopPropagation(),!1}}},{key:"processAutoTouchEvents",value:function(){this.options.autoUseTouchEvents&&(this.options.useTouchEvents=!0,this.options.debug&&console.log("autoUseTouchEvents: Touch device detected, useTouchEvents enabled."))}},{key:"onInit",value:function(){this.options.debug&&console.log("".concat(this.keyboardDOMClass," Initialized")),this.setEventListeners(),"function"==typeof this.options.onInit&&this.options.onInit()}},{key:"beforeFirstRender",value:function(){this.utilities.isTouchDevice()&&this.onTouchDeviceDetected(),"function"==typeof this.options.beforeFirstRender&&this.options.beforeFirstRender(),this.isFirstKeyboardInstance&&this.utilities.pointerEventsSupported()&&!this.options.useTouchEvents&&!this.options.useMouseEvents&&this.options.debug&&console.log("Using PointerEvents as it is supported by this browser"),this.options.useTouchEvents&&this.options.debug&&console.log("useTouchEvents has been enabled. Only touch events will be used.")}},{key:"beforeRender",value:function(){"function"==typeof this.options.beforeRender&&this.options.beforeRender()}},{key:"onRender",value:function(){"function"==typeof this.options.onRender&&this.options.onRender()}},{key:"onModulesLoaded",value:function(){"function"==typeof this.options.onModulesLoaded&&this.options.onModulesLoaded(this)}},{key:"loadModules",value:function(){var e=this;Array.isArray(this.options.modules)&&(this.options.modules.forEach((function(t){(new t).init(e)})),this.keyboardPluginClasses="modules-loaded",this.render(),this.onModulesLoaded())}},{key:"getModuleProp",value:function(e,t){return!!this.modules[e]&&this.modules[e][t]}},{key:"getModulesList",value:function(){return Object.keys(this.modules)}},{key:"parseRowDOMContainers",value:function(e,t,n,r){var o=this,i=Array.from(e.children),s=0;return i.length&&n.forEach((function(n,a){var l=r[a];if(!(l&&l>n))return!1;var c=n-s,u=l-s,d=document.createElement("div");d.className+="hg-button-container";var f="".concat(o.options.layoutName,"-r").concat(t,"c").concat(a);d.setAttribute("data-skUID",f);var p=i.splice(c,u-c+1);s=u-c,p.forEach((function(e){return d.appendChild(e)})),i.splice(c,0,d),e.innerHTML="",i.forEach((function(t){return e.appendChild(t)})),o.options.debug&&console.log("rowDOMContainer",p,c,u,s+1)})),e}},{key:"render",value:function(){var e=this;this.clear(),this.initialized||this.beforeFirstRender(),this.beforeRender();var t="hg-layout-".concat(this.options.layoutName),n=this.options.layout||{default:["` 1 2 3 4 5 6 7 8 9 0 - = {bksp}","{tab} q w e r t y u i o p [ ] \\","{lock} a s d f g h j k l ; ' {enter}","{shift} z x c v b n m , . / {shift}",".com @ {space}"],shift:["~ ! @ # $ % ^ & * ( ) _ + {bksp}","{tab} Q W E R T Y U I O P { } |",'{lock} A S D F G H J K L : " {enter}',"{shift} Z X C V B N M < > ? {shift}",".com @ {space}"]},r=this.options.useTouchEvents||!1,o=r?"hg-touch-events":"",i=this.options.useMouseEvents||!1,s=this.options.disableRowButtonContainers;this.keyboardDOM.className=this.getKeyboardClassString(this.options.theme,t,this.keyboardPluginClasses,o),n[this.options.layoutName].forEach((function(t,n){var o=t.split(" "),a=document.createElement("div");a.className+="hg-row";var l=[],c=[];o.forEach((function(t,o){var u,d=!s&&"string"==typeof t&&t.length>1&&0===t.indexOf("["),p=!s&&"string"==typeof t&&t.length>1&&t.indexOf("]")===t.length-1;d&&(l.push(o),t=t.replace(/\[/g,"")),p&&(c.push(o),t=t.replace(/\]/g,""));var h=e.utilities.getButtonClass(t),m=e.utilities.getButtonDisplayName(t,e.options.display,e.options.mergeDisplay),y=e.options.useButtonTag?"button":"div",v=document.createElement(y);v.className+="hg-button ".concat(h),(u=v.classList).add.apply(u,f(e.getButtonThemeClasses(t))),e.setDOMButtonAttributes(t,(function(e,t){v.setAttribute(e,t)})),e.activeButtonClass="hg-activeButton",!e.utilities.pointerEventsSupported()||r||i?r?(v.ontouchstart=function(n){e.handleButtonClicked(t),e.handleButtonMouseDown(t,n)},v.ontouchend=function(n){e.handleButtonMouseUp(t,n)},v.ontouchcancel=function(n){e.handleButtonMouseUp(t,n)}):(v.onclick=function(){e.isMouseHold=!1,e.handleButtonClicked(t)},v.onmousedown=function(n){e.handleButtonMouseDown(t,n)},v.onmouseup=function(n){e.handleButtonMouseUp(t,n)}):(v.onpointerdown=function(n){e.handleButtonClicked(t),e.handleButtonMouseDown(t,n)},v.onpointerup=function(n){e.handleButtonMouseUp(t,n)},v.onpointercancel=function(n){e.handleButtonMouseUp(t,n)}),v.setAttribute("data-skBtn",t);var g="".concat(e.options.layoutName,"-r").concat(n,"b").concat(o);v.setAttribute("data-skBtnUID",g);var b=document.createElement("span");b.innerHTML=m,v.appendChild(b),e.buttonElements[t]||(e.buttonElements[t]=[]),e.buttonElements[t].push(v),a.appendChild(v)})),a=e.parseRowDOMContainers(a,n,l,c),e.keyboardDOM.appendChild(a)})),this.onRender(),this.initialized||(this.initialized=!0,!this.utilities.pointerEventsSupported()||r||i?r?(document.ontouchend=function(){return e.handleButtonMouseUp()},document.ontouchcancel=function(){return e.handleButtonMouseUp()},this.keyboardDOM.ontouchstart=function(t){return e.handleKeyboardContainerMouseDown(t)}):r||(document.onmouseup=function(){return e.handleButtonMouseUp()},this.keyboardDOM.onmousedown=function(t){return e.handleKeyboardContainerMouseDown(t)}):(document.onpointerup=function(){return e.handleButtonMouseUp()},this.keyboardDOM.onpointerdown=function(t){return e.handleKeyboardContainerMouseDown(t)}),this.onInit())}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}();t.default=y}])},"object"==typeof n&&"object"==typeof t?t.exports=r():"function"==typeof define&&define.amd?define("SimpleKeyboard",[],r):"object"==typeof n?n.SimpleKeyboard=r():this.SimpleKeyboard=r()},{}],133:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.Build=void 0,n.Build={short:"0.72.9",version:"0.72.9 (2f6d192a33eef4a2464ad07b213e0d14)",buildSeed:1642744703224}},{}],134:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.deprecatedButton=n.createButton=void 0;const r=e("../dom/keys"),o=e("../dom/pointer"),i=function(){const e={};for(const t of Object.keys(r.namedKeyCodes))e[r.namedKeyCodes[t]]=t.substr(4,2);return e}();function s(e,t,n){const r=Math.round(.6*n),i=Math.round(.5*n),s=Math.max(1,Math.round(n/20)),l=h[e.toLowerCase()],c=void 0===l?e:"",u=a("emulator-button-touch-zone"),d=a("emulator-button"),f=a("emulator-button-text",void 0===l?void 0===c||0===c.length?"□":c.substr(0,1).toUpperCase():"");void 0!==l&&(d.style.backgroundImage='url("'+l+'")'),d.style.width=r+"px",d.style.height=r+"px",f.style.fontSize=i+"px",u.widthPx=n-2*s,u.heightPx=n-2*s,u.style.width=u.widthPx+"px",u.style.height=u.heightPx+"px",u.style.borderWidth=s+"px",u.appendChild(d),u.appendChild(f);const p=e=>{void 0!==t.onDown&&t.onDown(),void 0!==t.onClick&&t.onClick(),e.stopPropagation(),e.preventDefault()},m=e=>{void 0!==t.onUp&&t.onUp(),e.stopPropagation(),e.preventDefault()},y=e=>{e.stopPropagation(),e.preventDefault()},v={capture:!0};for(const e of o.pointer.starters)u.addEventListener(e,p,v);for(const e of o.pointer.enders)u.addEventListener(e,m,v);for(const e of o.pointer.changers)u.addEventListener(e,y,v);for(const e of o.pointer.leavers)u.addEventListener(e,y,v);for(const e of o.pointer.prevents)u.addEventListener(e,y,v);return u}function a(e,t){const n=document.createElement("div");return n.className=e,void 0!==t&&(n.innerHTML=t),n}function l(e){return"number"==typeof e?i[e]:e}function c(e,t){return"click"===e.action?{onClick:()=>t.fireKeyPress(e.mapTo)}:{onDown:()=>t.fireKeyDown(e.mapTo),onUp:()=>t.fireKeyUp(e.mapTo)}}n.createButton=s,n.deprecatedButton=function(e,t,n,o){const i=Math.round(o/4),a=[];for(const t of n){if(t.mapTo===r.KBD_NONE)continue;const n=s((t.symbol||l(t.mapTo)).toUpperCase(),c(t,e),o);n.style.position="absolute";const u=t.style;if(u)for(const e of Object.keys(u))n.style[e]=u[e];if(void 0!==t.position){const e=t.position.left,r=t.position.top,s=t.position.bottom,a=t.position.right;void 0!==e&&(n.style.left=i*e+o*(e-1)+"px"),void 0!==a&&(n.style.right=i*a+o*(a-1)+"px"),void 0!==r&&(n.style.top=i*r+o*(r-1)+"px"),void 0!==s&&(n.style.bottom=i*s+o*(s-1)+"px")}e.mouseOverlay.appendChild(n),a.push(n)}return()=>{for(const t of a)t.parentElement===e.mouseOverlay&&e.mouseOverlay.removeChild(t)}};const u="data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns:sketch='http://www.bohemiancoding.com/sketch/ns' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 20 20' fill='%23FFF' enable-background='new 0 0 20 20' xml:space='preserve'%3E%3Ctitle%3EShape%3C/title%3E%3Cdesc%3ECreated with Sketch.%3C/desc%3E%3Cg id='Page-1' sketch:type='MSPage'%3E%3Cg id='Artboard-1' transform='translate(-3.000000, -1.000000)' sketch:type='MSArtboardGroup'%3E%3Cpath id='Shape' sketch:type='MSShapeGroup' d='M19,12c-0.3,0-0.5,0.1-0.7,0.3L14,16.6V3c0-0.5-0.4-1-1-1s-1,0.5-1,1v13.6 l-4.3-4.3C7.5,12.1,7.3,12,7,12c-0.5,0-1,0.4-1,1c0,0.3,0.1,0.5,0.3,0.7l6,6c0.2,0.2,0.4,0.3,0.7,0.3s0.5-0.1,0.7-0.3l6-6 c0.2-0.2,0.3-0.4,0.3-0.7C20,12.4,19.5,12,19,12L19,12z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",d="data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 20 20' enable-background='new 0 0 20 20' fill='%23FFF' xml:space='preserve'%3E%3Cg id='left_arrow_1_'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M18,9H4.41l4.29-4.29C8.89,4.53,9,4.28,9,4c0-0.55-0.45-1-1-1 C7.72,3,7.47,3.11,7.29,3.29l-6,6C1.11,9.47,1,9.72,1,10c0,0.28,0.11,0.53,0.29,0.71l6,6C7.47,16.89,7.72,17,8,17 c0.55,0,1-0.45,1-1c0-0.28-0.11-0.53-0.29-0.71L4.41,11H18c0.55,0,1-0.45,1-1C19,9.45,18.55,9,18,9z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",f="data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' fill='%23fff' viewBox='0 0 20 20' enable-background='new 0 0 20 20' xml:space='preserve'%3E%3Cg id='right_arrow_1_'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M18.71,9.29l-6-6C12.53,3.11,12.28,3,12,3c-0.55,0-1,0.45-1,1 c0,0.28,0.11,0.53,0.29,0.71L15.59,9H2c-0.55,0-1,0.45-1,1c0,0.55,0.45,1,1,1h13.59l-4.29,4.29C11.11,15.47,11,15.72,11,16 c0,0.55,0.45,1,1,1c0.28,0,0.53-0.11,0.71-0.29l6-6C18.89,10.53,19,10.28,19,10C19,9.72,18.89,9.47,18.71,9.29z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",p="data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 18.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' fill='%23fff' viewBox='0 0 20 20' enable-background='new 0 0 20 20' xml:space='preserve'%3E%3Cg id='key_enter_1_'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M18,2c-0.55,0-1,0.45-1,1v5c0,2.21-1.79,4-4,4H4.41l2.29-2.29 C6.89,9.53,7,9.28,7,9c0-0.55-0.45-1-1-1C5.72,8,5.47,8.11,5.29,8.29l-4,4C1.11,12.47,1,12.72,1,13c0,0.28,0.11,0.53,0.29,0.71 l4,4C5.47,17.89,5.72,18,6,18c0.55,0,1-0.45,1-1c0-0.28-0.11-0.53-0.29-0.71L4.41,14H13c3.31,0,6-2.69,6-6V3C19,2.45,18.55,2,18,2 z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",h={fullscreen:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 16 16' enable-background='new 0 0 16 16' xml:space='preserve'%3E%3Cg id='maximize_1_' fill='%23FFFFFF'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M5.99,8.99c-0.28,0-0.53,0.11-0.71,0.29l-3.29,3.29v-1.59c0-0.55-0.45-1-1-1 s-1,0.45-1,1v4c0,0.55,0.45,1,1,1h4c0.55,0,1-0.45,1-1s-0.45-1-1-1H3.41L6.7,10.7c0.18-0.18,0.29-0.43,0.29-0.71 C6.99,9.44,6.54,8.99,5.99,8.99z M14.99-0.01h-4c-0.55,0-1,0.45-1,1s0.45,1,1,1h1.59L9.28,5.29C9.1,5.47,8.99,5.72,8.99,5.99 c0,0.55,0.45,1,1,1c0.28,0,0.53-0.11,0.71-0.29l3.29-3.29v1.59c0,0.55,0.45,1,1,1s1-0.45,1-1v-4C15.99,0.44,15.54-0.01,14.99-0.01 z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",save:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 18.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 16 16' enable-background='new 0 0 16 16' fill='%23FFFFFF' xml:space='preserve'%3E%3Cg id='floppy_disk'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M15.71,2.29l-2-2C13.53,0.11,13.28,0,13,0h-1v6H4V0H1C0.45,0,0,0.45,0,1v14 c0,0.55,0.45,1,1,1h14c0.55,0,1-0.45,1-1V3C16,2.72,15.89,2.47,15.71,2.29z M14,15H2V9c0-0.55,0.45-1,1-1h10c0.55,0,1,0.45,1,1V15 z M11,1H9v4h2V1z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E%0A",options:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 20 20' enable-background='new 0 0 20 20' fill='%23FFF' xml:space='preserve'%3E%3Cg id='cog_2_'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M19,8h-2.31c-0.14-0.46-0.33-0.89-0.56-1.3l1.7-1.7c0.39-0.39,0.39-1.02,0-1.41 l-1.41-1.41c-0.39-0.39-1.02-0.39-1.41,0l-1.7,1.7c-0.41-0.22-0.84-0.41-1.3-0.55V1c0-0.55-0.45-1-1-1H9C8.45,0,8,0.45,8,1v2.33 C7.52,3.47,7.06,3.67,6.63,3.91L5,2.28c-0.37-0.37-0.98-0.37-1.36,0L2.28,3.64C1.91,4.02,1.91,4.63,2.28,5l1.62,1.62 C3.66,7.06,3.46,7.51,3.31,8H1C0.45,8,0,8.45,0,9v2c0,0.55,0.45,1,1,1h2.31c0.14,0.46,0.33,0.89,0.56,1.3L2.17,15 c-0.39,0.39-0.39,1.02,0,1.41l1.41,1.41c0.39,0.39,1.02,0.39,1.41,0l1.7-1.7c0.41,0.22,0.84,0.41,1.3,0.55V19c0,0.55,0.45,1,1,1h2 c0.55,0,1-0.45,1-1v-2.33c0.48-0.14,0.94-0.35,1.37-0.59L15,17.72c0.37,0.37,0.98,0.37,1.36,0l1.36-1.36 c0.37-0.37,0.37-0.98,0-1.36l-1.62-1.62c0.24-0.43,0.45-0.89,0.6-1.38H19c0.55,0,1-0.45,1-1V9C20,8.45,19.55,8,19,8z M10,14 c-2.21,0-4-1.79-4-4c0-2.21,1.79-4,4-4s4,1.79,4,4C14,12.21,12.21,14,10,14z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",keyboard:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 18.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 16 16' enable-background='new 0 0 16 16' xml:space='preserve'%3E%3Cg id='manually_entered_data_2_'%3E%3Cg%3E%3Cpath fill='%23FFFFFF' fill-rule='evenodd' clip-rule='evenodd' d='M1,8h3.76l2-2H1C0.45,6,0,6.45,0,7C0,7.55,0.45,8,1,8z M15.49,3.99 C15.8,3.67,16,3.23,16,2.75C16,1.78,15.22,1,14.25,1c-0.48,0-0.92,0.2-1.24,0.51l-1.44,1.44l2.47,2.47L15.49,3.99z M1,4h7.76l2-2 H1C0.45,2,0,2.45,0,3C0,3.55,0.45,4,1,4z M1,10c-0.55,0-1,0.45-1,1c0,0.48,0.35,0.86,0.8,0.96L2.76,10H1z M10.95,3.57l-6.69,6.69 l2.47,2.47l6.69-6.69L10.95,3.57z M15.2,6.04L13.24,8H15c0.55,0,1-0.45,1-1C16,6.52,15.65,6.14,15.2,6.04z M2,15l3.86-1.39 l-2.46-2.44L2,15z M15,10h-3.76l-2,2H15c0.55,0,1-0.45,1-1C16,10.45,15.55,10,15,10z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",up:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns:sketch='http://www.bohemiancoding.com/sketch/ns' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 20 20' fill='%23FFF' enable-background='new 0 0 20 20' xml:space='preserve'%3E%3Ctitle%3EShape%3C/title%3E%3Cdesc%3ECreated with Sketch.%3C/desc%3E%3Cg id='Page-1' sketch:type='MSPage'%3E%3Cg id='Artboard-1' transform='translate(-3.000000, -1.000000)' sketch:type='MSArtboardGroup'%3E%3Cpath id='Shape' sketch:type='MSShapeGroup' d='M19.7,8.3l-6-6C13.5,2.1,13.3,2,13,2s-0.5,0.1-0.7,0.3l-6,6C6.1,8.5,6,8.7,6,9 c0,0.6,0.5,1,1,1c0.3,0,0.5-0.1,0.7-0.3L12,5.4V19c0,0.5,0.4,1,1,1s1-0.5,1-1V5.4l4.3,4.3C18.5,9.9,18.7,10,19,10c0.5,0,1-0.4,1-1 C20,8.7,19.9,8.5,19.7,8.3L19.7,8.3z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",down:u,do:u,dw:u,dwn:u,left:d,le:d,lft:d,right:f,ri:f,rght:f,rgh:f,enter:p,en:p,enr:p,ent:p,entr:p}},{"../dom/keys":148,"../dom/pointer":152,"core-js/modules/web.dom-collections.iterator.js":118}],135:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.getGrid=void 0,n.getGrid=function(e){switch(e){case"square":return new class{constructor(){r(this,"aspect",.625)}getConfiguration(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;const r=this.getCols(),o=this.getRows(),i=Math.floor(r/2),s=Math.floor(o/2),a=5*e/100/2,l=a,c=(e-2*a)/r*n,u=(t-2*l)/o*n,d=Math.min(c,u),f=[];for(let n=0;n<o;++n){const c=[];for(let u=0;u<r;++u)c.push({centerX:u<i?a+d*(u+.5):e-a-d*(r-u-1+.5),centerY:n<s?l+d*(n+.5):t-l-d*(o-n-1+.5)});f.push(c)}return{gridType:"square",cells:f,columnWidth:d,rowHeight:d,columnsPadding:a,rowsPadding:l,width:e,height:t}}getCols(){return 10}getRows(){return Math.floor(this.getCols()*this.aspect)+1}};case"honeycomb":return new class{constructor(){r(this,"aspect",.625)}getConfiguration(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;const r=this.getCols(),o=this.getRows(),i=Math.floor(r/2),s=Math.floor(o/2),a=5*e/100/2,l=a,c=(e-2*a)/r*n,u=(t-2*l)/o*n,d=Math.min(c,u),f=[];for(let n=0;n<o;++n){const c=[],u=n%2==0?r:r-1,p=n%2==0?0:d/2;for(let f=0;f<u;++f)c.push({centerX:f<i?p+a+d*(f+.5):p+e-a-d*(r-f-1+.5),centerY:n<s?l+d*(n+.5):t-l-d*(o-n-1+.5)});f.push(c)}return{gridType:"honeycomb",cells:f,columnWidth:d,rowHeight:d,columnsPadding:a,rowsPadding:l,width:e,height:t}}getCols(){return 10}getRows(){return Math.floor(this.getCols()*this.aspect)+1}}}throw new Error("Unknown grid type "+e)}},{}],136:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.keyboard=void 0,n.keyboard=function(e,t,n){const r=n||{};function o(e){return void 0!==r[e]?r[e]:e}return e.setOnKeyDown((e=>{t.sendKeyEvent(o(e),!0)})),e.setOnKeyUp((e=>{t.sendKeyEvent(o(e),!1)})),e.setOnKeyPress((e=>{t.simulateKeyPress(o(e))})),e.setOnKeysPress((e=>{t.simulateKeyPress(...e)})),()=>{e.setOnKeyDown((e=>{})),e.setOnKeyUp((e=>{})),e.setOnKeyPress((e=>{})),e.setOnKeysPress((e=>{}))}}},{"core-js/modules/web.dom-collections.iterator.js":118}],137:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.extractLayersConfig=void 0,n.extractLayersConfig=function(e){return void 0!==e.layersConfig?(1===e.layersConfig.version&&function(e){for(const t of e.layers)for(const e of t.controls)if("Key"===e.type){const t=e;"number"==typeof t.mapTo&&(t.mapTo=[t.mapTo])}}(e.layersConfig),e.layersConfig):void 0!==e.layers?e.layers:null}},{"core-js/modules/web.dom-collections.iterator.js":118}],138:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.initLayersControl=void 0;const r=e("./grid"),o=e("./button"),i=e("./keyboard"),s=e("./mouse/mouse-common"),a=e("./options"),l=e("../dom/pointer"),c=e("nipplejs");n.initLayersControl=function(e,t,n,o,a,l,c){let f=t.layers[0];if(void 0!==c)for(const e of t.layers)if(e.title===c){f=e;break}return function(e,t,n,o,a,l){const c=(0,i.keyboard)(t,n),f=(0,s.mouse)(o.autolock,o.sensitivity,t,n),p=[];function m(i,s){var c;for(const e of p)e();p.splice(0,p.length);const f=(0,r.getGrid)(e.grid).getConfiguration(i,s,l),m=new u;for(const t of e.controls){const{row:e,column:n,type:r}=t;"NippleActivator"===r&&h(f,e,n)}let y=-1;if(0===(null===(c=t.options.optionControls)||void 0===c?void 0:c.length))for(const t of e.controls){const{row:e,type:n}=t;if("Options"===n){y=e;break}}const v={};if(a)for(const t of e.controls){const{row:e}=t;let n=t.column;const r=f.cells[e].length,o=r/2;e===y&&n>=o&&(n=Math.min(n+1,r-1)),void 0===v[e]&&(v[e]={leftStart:o,leftEnd:0,rightStart:r-1,rightEnd:o}),n<o?(v[e].leftStart=Math.min(v[e].leftStart,n),v[e].leftEnd=Math.max(v[e].leftEnd,n)):(v[e].rightStart=Math.min(v[e].rightStart,n),v[e].rightEnd=Math.max(v[e].rightEnd,n))}for(const r of e.controls){const e=d[r.type];if(void 0===e){console.error("Factory for control '"+r.type+"' is not defined");continue}const i={...r},s=f.cells[r.row].length,l=s/2;if(y===r.row&&r.column>=l&&(i.column=Math.min(i.column+1,s-1)),a){const{leftStart:e,leftEnd:t,rightStart:n,rightEnd:r}=v[i.row],o=i.column<l;o?i.column+=l+(l-t)-e-1:i.column-=l+(n-l)-(s-r)+1,i.column>=s?(console.error("Column",i.column,"is out of bound",s,o?"[leftSide]":"[rightSide]",v),i.column=s-1):i.column<0&&(console.error("Column",i.column,"is out of bound",0,o?"[leftSide]":"[rightSide]",v),i.column=0)}const c=e(i,t,n,f,m,o);p.push(c)}}return t.addOnResize(m),m(t.width,t.height),()=>{t.removeOnResize(m),c(),f();for(const e of p)e()}}(f,e,n,o,a,l)};class u{constructor(){var e,t;t={},(e="sensors")in this?Object.defineProperty(this,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):this[e]=t}activate(e,t){const n=this.sensors[t+"_"+e];void 0!==n&&n.activate()}deactivate(e,t){const n=this.sensors[t+"_"+e];void 0!==n&&n.deactivate()}register(e,t,n){this.sensors[t+"_"+e]=n}}const d={Key:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],h={onDown:()=>{for(const t of e.mapTo)n.sendKeyEvent(t,!0)},onUp:()=>{for(const t of e.mapTo)n.sendKeyEvent(t,!1)}};if(i.register(c,u,{activate:h.onDown,deactivate:h.onUp}),p(r,c,u))return()=>{};const m=(0,o.createButton)(e.symbol,h,l);return m.style.position="absolute",m.style.left=d-m.widthPx/2+"px",m.style.top=f-m.heightPx/2+"px",t.mouseOverlay.appendChild(m),()=>t.mouseOverlay.removeChild(m)},Options:function(e,t,n,r,o,i){var s;if(0===(null===(s=t.options.optionControls)||void 0===s?void 0:s.length))return()=>{};if(void 0!==t.options.optionControls&&1===t.options.optionControls.length&&"keyboard"===t.options.optionControls[0])return f(e,t,n,r,o,i);const{cells:l,columnWidth:c,rowHeight:u}=r,{row:d,column:p}=e,{centerX:h,centerY:m}=l[d][p],y=m-u/2,v=h-c/2,g=r.width-v-c;return(0,a.options)(t,["default"],(()=>{}),c,y,g)},Keyboard:f,Switch:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],p=(0,o.createButton)(e.symbol,{onUp:()=>s.setLayersConfig(s.getLayersConfig(),e.layerName)},l);return p.style.position="absolute",p.style.left=d-p.widthPx/2+"px",p.style.top=f-p.heightPx/2+"px",t.mouseOverlay.appendChild(p),()=>{t.mouseOverlay.removeChild(p)}},ScreenMove:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u];let h=.5,m=.5;e.direction.indexOf("up")>=0&&(m=0),e.direction.indexOf("down")>=0&&(m=1),e.direction.indexOf("left")>=0&&(h=0),e.direction.indexOf("right")>=0&&(h=1);const y={onDown:()=>{n.sendMouseMotion(h,m)},onUp:()=>{n.sendMouseMotion(.5,.5)}};if(i.register(c,u,{activate:y.onDown,deactivate:y.onUp}),p(r,c,u))return()=>{};const v=(0,o.createButton)(e.symbol,y,l);return v.style.position="absolute",v.style.left=d-v.widthPx/2+"px",v.style.top=f-v.heightPx/2+"px",t.mouseOverlay.appendChild(v),()=>t.mouseOverlay.removeChild(v)},PointerButton:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u,click:d}=e,{centerX:f,centerY:h}=a[c][u],m={onDown:()=>{d?n.sendMouseButton(e.button,!0):t.pointerButton=e.button},onUp:()=>{d?n.sendMouseButton(e.button,!1):t.pointerButton=0}};if(i.register(c,u,{activate:m.onDown,deactivate:m.onUp}),p(r,c,u))return()=>{};const y=(0,o.createButton)(e.symbol,m,l);return y.style.position="absolute",y.style.left=f-y.widthPx/2+"px",y.style.top=h-y.heightPx/2+"px",t.mouseOverlay.appendChild(y),()=>t.mouseOverlay.removeChild(y)},PointerMove:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u,x:d,y:f}=e,{centerX:h,centerY:m}=a[c][u],y={onDown:()=>{n.sendMouseMotion(d,f)},onUp:()=>{n.sendMouseMotion(d,f)}};if(i.register(c,u,{activate:y.onDown,deactivate:y.onUp}),p(r,c,u))return()=>{};const v=(0,o.createButton)(e.symbol,y,l);return v.style.position="absolute",v.style.left=h-v.widthPx/2+"px",v.style.top=m-v.heightPx/2+"px",t.mouseOverlay.appendChild(v),()=>t.mouseOverlay.removeChild(v)},PointerReset:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],h={onDown:()=>{n.sendMouseSync()}};if(i.register(c,u,{activate:h.onDown,deactivate:()=>{}}),p(r,c,u))return()=>{};const m=(0,o.createButton)(e.symbol,h,l);return m.style.position="absolute",m.style.left=d-m.widthPx/2+"px",m.style.top=f-m.heightPx/2+"px",t.mouseOverlay.appendChild(m),()=>t.mouseOverlay.removeChild(m)},PointerToggle:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],h={onDown:()=>{t.pointerDisabled=!t.pointerDisabled,t.pointerDisabled?m.classList.contains("emulator-button-highlight")||m.classList.add("emulator-button-highlight"):m.classList.remove("emulator-button-highlight")}};if(i.register(c,u,{activate:h.onDown,deactivate:()=>{}}),p(r,c,u))return()=>{};const m=(0,o.createButton)(e.symbol,h,l);return m.style.position="absolute",m.style.left=d-m.widthPx/2+"px",m.style.top=f-m.heightPx/2+"px",t.mouseOverlay.appendChild(m),()=>t.mouseOverlay.removeChild(m)},NippleActivator:function(e,t,n,r,o,i){const{cells:s,columnWidth:a,rowHeight:u,width:d,height:f}=r,{row:p,column:h}=e,{centerX:m,centerY:y}=s[p][h],v=document.createElement("div"),g=1.5,b=Math.max(0,m-a*g),_=Math.max(0,y-u*g),w=Math.max(0,d-m-a*g),x=Math.max(0,f-y-u*g);v.style.position="absolute",v.style.zIndex="999",v.style.left=b+"px",v.style.top=_+"px",v.style.right=w+"px",v.style.bottom=x+"px",t.mouseOverlay.appendChild(v);const k=c.create({zone:v,multitouch:!1,maxNumberOfNipples:1,mode:"static",follow:!1,dynamicPage:!0,size:1.5*Math.max(a,u),position:{left:(d-w-b)/2+"px",top:(f-x-_)/2+"px"}});let j=-1,C=-1;k.on("move",((e,t)=>{if(t.distance<10)return o.deactivate(C,j),j=-1,void(C=-1);let n=-1,r=-1;const i=t.angle.degree;i>22.5&&i<=67.5?(n=h+1,r=p-1):i>67.5&&i<=112.5?(n=h,r=p-1):i>112.5&&i<=157.5?(n=h-1,r=p-1):i>157.5&&i<=202.5?(n=h-1,r=p):i>202.5&&i<=247.5?(n=h-1,r=p+1):i>247.5&&i<=292.5?(n=h,r=p+1):i>292.5&&i<=337.5?(n=h+1,r=p+1):(n=h+1,r=p),j===n&&C===r||(o.deactivate(C,j),o.activate(r,n),j=n,C=r)}));let D=!1;k.on("start",(()=>{D=!0})),k.on("end",(()=>{D=!1,o.deactivate(C,j),C=-1,j=-1}));const E={capture:!0};function S(e){D&&k.processOnEnd(e)}for(const e of l.pointer.enders)t.mouseOverlay.addEventListener(e,S,E);return()=>{k.destroy(),t.mouseOverlay.removeChild(v);for(const e of l.pointer.enders)t.mouseOverlay.removeEventListener(e,S,E)}}};function f(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],p=(0,o.createButton)("keyboard",{onUp:()=>t.toggleKeyboard()},l),h=e=>{e?p.children[0].classList.add("emulator-control-close-icon"):p.children[0].classList.remove("emulator-control-close-icon")};return t.setOnKeyboardVisibility(h),p.style.position="absolute",p.style.left=d-p.widthPx/2+"px",p.style.top=f-p.heightPx/2+"px",t.mouseOverlay.appendChild(p),()=>{t.mouseOverlay.removeChild(p),t.removeOnKeyboardVisibility(h)}}function p(e,t,n){return!0===e.cells[t][n].hidden}function h(e,t,n){function r(r,o){if((r!==t||o!==n)&&r>=0&&r<e.cells.length){const t=e.cells[r];o>=0&&o<t.length&&(t[o].hidden=!0)}}for(let e=t-1;e<=t+1;++e)for(let t=n-1;t<=n+1;++t)r(e,t)}},{"../dom/pointer":152,"./button":134,"./grid":135,"./keyboard":136,"./mouse/mouse-common":140,"./options":146,"core-js/modules/web.dom-collections.iterator.js":118,nipplejs:130}],139:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.initLegacyLayersControl=void 0;const r=e("./button"),o=e("./mouse/mouse-common"),i=e("./nipple"),s=e("./options"),a=e("./keyboard");n.initLegacyLayersControl=function(e,t,n,l){var c;const u=Object.keys(n),d={keyboard:()=>{},mouse:()=>{},gestures:()=>{},buttons:()=>{}},f=s=>{d.keyboard(),d.mouse(),d.gestures(),d.buttons(),d.keyboard=()=>{},d.mouse=()=>{},d.gestures=()=>{},d.buttons=()=>{};const c=n[s];void 0!==c&&(d.keyboard=(0,a.keyboard)(t,l,c.mapper),void 0!==c.gestures&&c.gestures.length>0?d.gestures=(0,i.nipple)(t,l,c.gestures):d.mouse=(0,o.mouse)(e.autolock,e.sensitivity,t,l),void 0!==c.buttons&&c.buttons.length&&(d.buttons=(0,r.deprecatedButton)(t,l,c.buttons,54)))},p=0===(null===(c=t.options.optionControls)||void 0===c?void 0:c.length)?()=>{}:(0,s.options)(t,u,f,54,13.5,0);return f("default"),()=>{d.gestures(),d.buttons(),d.mouse(),d.keyboard(),p()}}},{"./button":134,"./keyboard":136,"./mouse/mouse-common":140,"./nipple":144,"./options":146}],140:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.mouse=n.mount=n.mapXY=void 0;const r=e("../../dom/pointer"),o=e("./mouse-swipe"),i=e("./mouse-not-locked"),s=e("./mouse-locked");n.mapXY=function(e,t,n,r){const o=n.width(),i=n.height(),s=r.width,a=r.height,l=o/i;let c=s,u=s/l;u>a&&(u=a,c=a*l);const d=(a-u)/2,f=(s-c)/2;let p=Math.max(0,Math.min(1,(e-f)/c)),h=Math.max(0,Math.min(1,(t-d)/u));return p<=.01&&(p=0),p>=.99&&(p=1),h<=.01&&(h=0),h>=.99&&(h=1),{x:p,y:h}},n.mount=function(e,t,n,o,i,s){let a=0;const l=o=>{if(o.target!==e)return;if(t.pointerDisabled)return void o.stopPropagation();const i=(0,r.getPointerState)(o,e);a=i.button||t.pointerButton,n(i.x,i.y,a),o.stopPropagation()},c=n=>{if(n.target!==e)return;if(t.pointerDisabled)return void n.stopPropagation();const i=(0,r.getPointerState)(n,e);o(i.x,i.y,i.mX,i.mY),n.stopPropagation()},u=n=>{if(t.pointerDisabled)return void n.stopPropagation();const o=(0,r.getPointerState)(n,e);i(o.x,o.y,a),n.stopPropagation()},d=n=>{if(n.target!==e)return;if(t.pointerDisabled)return void n.stopPropagation();const o=(0,r.getPointerState)(n,e);s(o.x,o.y),n.stopPropagation()},f=e=>{e.stopPropagation()},p={capture:!1};for(const t of r.pointer.starters)e.addEventListener(t,l,p);for(const t of r.pointer.changers)e.addEventListener(t,c,p);for(const t of r.pointer.enders)e.addEventListener(t,u,p);for(const t of r.pointer.prevents)e.addEventListener(t,f,p);for(const t of r.pointer.leavers)e.addEventListener(t,d,p);return()=>{for(const t of r.pointer.starters)e.removeEventListener(t,l,p);for(const t of r.pointer.changers)e.removeEventListener(t,c,p);for(const t of r.pointer.enders)e.removeEventListener(t,u,p);for(const t of r.pointer.prevents)e.removeEventListener(t,f,p);for(const t of r.pointer.leavers)e.removeEventListener(t,d,p)}},n.mouse=function(e,t,n,a){return e&&!r.pointer.canLock?(0,o.mouseSwipe)(t,n,a):e?(0,s.mouseLocked)(t,n,a):(0,i.mouseNotLocked)(n,a)}},{"../../dom/pointer":152,"./mouse-locked":141,"./mouse-not-locked":142,"./mouse-swipe":143,"core-js/modules/web.dom-collections.iterator.js":118}],141:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.mouseLocked=void 0;const r=e("./mouse-common");n.mouseLocked=function(e,t,n){const o=t.mouseOverlay;function i(){return document.pointerLockElement!==o}return(0,r.mount)(o,t,(function(e,t,r){i()?(o.requestPointerLock||o.mozRequestPointerLock||o.webkitRequestPointerLock).call(o):n.sendMouseButton(r,!0)}),(function(t,r,o,s){i()||0===o&&0===s||n.sendMouseRelativeMotion(o*e,s*e)}),(function(e,t,r){i()||n.sendMouseButton(r,!1)}),(function(e,t){}))}},{"./mouse-common":140}],142:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.mouseNotLocked=void 0;const r=e("./mouse-common");n.mouseNotLocked=function(e,t){const n=e.mouseOverlay,o=(n,o)=>(0,r.mapXY)(n,o,t,e);return document.pointerLockElement===n&&document.exitPointerLock(),(0,r.mount)(n,e,(function(e,n,r){const i=o(e,n);t.sendMouseMotion(i.x,i.y),t.sendMouseButton(r,!0)}),(function(e,n,r,i){const s=o(e,n);t.sendMouseMotion(s.x,s.y)}),(function(e,n,r){const i=o(e,n);t.sendMouseMotion(i.x,i.y),t.sendMouseButton(r,!1)}),(function(e,n){const r=o(e,n);t.sendMouseMotion(r.x,r.y)}))}},{"./mouse-common":140}],143:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.mouseSwipe=void 0;const r=e("./mouse-common");n.mouseSwipe=function(e,t,n){const o=t.mouseOverlay;let i=-1,s=0,a=0,l=0;return(0,r.mount)(o,t,((e,t)=>{i=Date.now(),s=0,a=e,l=t}),(function(t,r,o,i){void 0===o&&(o=t-a),void 0===i&&(i=r-l),a=t,l=r,0===o&&0===i||(s+=Math.abs(o)+Math.abs(i),n.sendMouseRelativeMotion(o*e*2,i*e*2))}),((e,r)=>{if(Date.now()-i<500&&s<50){const e=t.pointerButton||0;n.sendMouseButton(e,!0),setTimeout((()=>n.sendMouseButton(e,!1)),60)}}),(()=>{}))}},{"./mouse-common":140}],144:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.nipple=void 0;const r=e("nipplejs"),o=e("../dom/keys");n.nipple=function(e,t,n){const i=r.create({zone:e.mouseOverlay,multitouch:!0,maxNumberOfNipples:2});let s=-1;const a=()=>{-1!==s&&(e.fireKeyUp(s),s=-1)},l={},c={},u={};for(const t of n)"end:release"===t.event?l[t.joystickId]=!0:t.mapTo!==o.KBD_NONE&&("tap"===t.event?c[t.joystickId]=t.mapTo:i.on(t.event,(()=>{var n;u[t.joystickId]=Date.now(),a(),n=t.mapTo,e.fireKeyDown(n),s=n})));const d={};return i.on("start",(()=>{const e=i.ids.length-1;d[e]=Date.now()})),i.on("end",(()=>{const t=i.ids.length-1,n=Date.now()-d[t];!0===l[t]&&a(),c[t]&&n<500&&u[t]<d[t]&&e.fireKeyPress(c[t])})),()=>i.destroy()}},{"../dom/keys":148,"core-js/modules/web.dom-collections.iterator.js":118,nipplejs:130}],145:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.initNullLayersControl=void 0;const r=e("./keyboard"),o=e("./mouse/mouse-common"),i=e("./options");n.initNullLayersControl=function(e,t,n){var s;const a=(0,r.keyboard)(t,n),l=(0,o.mouse)(e.autolock,e.sensitivity,t,n),c=0===(null===(s=t.options.optionControls)||void 0===s?void 0:s.length)?()=>{}:(0,i.options)(t,["default"],(()=>{}),54,13.5,0);return()=>{a(),l(),c()}}},{"./keyboard":136,"./mouse/mouse-common":140,"./options":146}],146:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.options=void 0;const r=e("./button"),o=e("../dom/helpers");function i(e,t){if(e.length<=1)return document.createElement("div");const n=document.createElement("select");n.classList.add("emulator-control-select");for(const t of e){const e=document.createElement("option");e.value=t,e.innerHTML=t,n.appendChild(e)}return n.onchange=e=>{const n=e.target.value;t(n)},(0,o.stopPropagation)(n,!1),n}n.options=function(e,t,n,s,a,l){const c=Math.round(s/4);let u=!1,d=!1;const f=()=>{const e=u?"flex":"none";for(const t of h)t!=m&&(t.style.display=e)},p=()=>{u=!u,!u&&d&&e.toggleKeyboard(),f()},h=[i(t,n),(0,r.createButton)("keyboard",{onClick:()=>{e.toggleKeyboard(),u&&!d&&(u=!1,f())}},s),(0,r.createButton)("save",{onClick:()=>{e.save(),u&&p()}},s),(0,r.createButton)("fullscreen",{onClick:()=>{e.toggleFullscreen(),u&&p()}},s),(0,r.createButton)("options",{onClick:p},s)],m=h[h.length-1],y=h[h.length-2].children[0],v=h[h.length-4].children[0],g=e=>{d=e,e?v.classList.add("emulator-control-close-icon"):v.classList.remove("emulator-control-close-icon")};e.setOnKeyboardVisibility(g),g(e.keyboardVisible),e.setOnFullscreen((e=>{e?y.classList.contains("emulator-control-exit-fullscreen-icon")||y.classList.add("emulator-control-exit-fullscreen-icon"):y.classList.remove("emulator-control-exit-fullscreen-icon")})),e.fullscreen&&y.classList.add("emulator-control-exit-fullscreen-icon");const b=(0,o.createDiv)("emulator-options"),_=d?"flex":"none";for(const e of h)e!==m&&e.classList.add("emulator-button-control"),e.style.marginRight=c+"px",e.style.marginBottom=c+"px",e!==m&&(e.style.display=_),b.appendChild(e);return b.style.position="absolute",b.style.right=l+"px",b.style.top=a+"px",e.mouseOverlay.appendChild(b),()=>{e.mouseOverlay.removeChild(b),e.setOnFullscreen((()=>{})),e.removeOnKeyboardVisibility(g)}}},{"../dom/helpers":147,"./button":134,"core-js/modules/web.dom-collections.iterator.js":118}],147:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.stopPropagation=n.createDiv=void 0;const r=e("./pointer");n.createDiv=function(e,t){const n=document.createElement("div");return n.className=e,void 0!==t&&(n.innerHTML=t),n},n.stopPropagation=function(e){let t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];const n=e=>{e.stopPropagation()},o=e=>{e.stopPropagation(),t&&e.preventDefault()},i={capture:!1};for(const t of r.pointer.starters)e.addEventListener(t,n,i);for(const t of r.pointer.enders)e.addEventListener(t,n,i);for(const t of r.pointer.prevents)e.addEventListener(t,o,i)}},{"./pointer":152,"core-js/modules/web.dom-collections.iterator.js":118}],148:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.KBD_kp0=n.KBD_f12=n.KBD_f11=n.KBD_f10=n.KBD_f9=n.KBD_f8=n.KBD_f7=n.KBD_f6=n.KBD_f5=n.KBD_f4=n.KBD_f3=n.KBD_f2=n.KBD_f1=n.KBD_z=n.KBD_y=n.KBD_x=n.KBD_w=n.KBD_v=n.KBD_u=n.KBD_t=n.KBD_s=n.KBD_r=n.KBD_q=n.KBD_p=n.KBD_o=n.KBD_n=n.KBD_m=n.KBD_l=n.KBD_k=n.KBD_j=n.KBD_i=n.KBD_h=n.KBD_g=n.KBD_f=n.KBD_e=n.KBD_d=n.KBD_c=n.KBD_b=n.KBD_a=n.KBD_9=n.KBD_8=n.KBD_7=n.KBD_6=n.KBD_5=n.KBD_4=n.KBD_3=n.KBD_2=n.KBD_1=n.KBD_0=n.KBD_NONE=void 0,n.KBD_up=n.KBD_left=n.KBD_pagedown=n.KBD_end=n.KBD_delete=n.KBD_pageup=n.KBD_home=n.KBD_insert=n.KBD_pause=n.KBD_printscreen=n.KBD_slash=n.KBD_comma=n.KBD_period=n.KBD_quote=n.KBD_semicolon=n.KBD_rightbracket=n.KBD_leftbracket=n.KBD_backslash=n.KBD_equals=n.KBD_minus=n.KBD_grave=n.KBD_numlock=n.KBD_scrolllock=n.KBD_capslock=n.KBD_rightshift=n.KBD_leftshift=n.KBD_rightctrl=n.KBD_leftctrl=n.KBD_rightalt=n.KBD_leftalt=n.KBD_space=n.KBD_enter=n.KBD_backspace=n.KBD_tab=n.KBD_esc=n.KBD_kpenter=n.KBD_kpplus=n.KBD_kpminus=n.KBD_kpmultiply=n.KBD_kpdivide=n.KBD_kpperiod=n.KBD_kp9=n.KBD_kp8=n.KBD_kp7=n.KBD_kp6=n.KBD_kp5=n.KBD_kp4=n.KBD_kp3=n.KBD_kp2=n.KBD_kp1=void 0,n.domToKeyCode=n.keyCodesToDom=n.namedKeyCodes=n.domToKeyCodes=n.KBD_extra_lt_gt=n.KBD_right=n.KBD_down=void 0,n.KBD_NONE=0,n.KBD_0=48,n.KBD_1=49,n.KBD_2=50,n.KBD_3=51,n.KBD_4=52,n.KBD_5=53,n.KBD_6=54,n.KBD_7=55,n.KBD_8=56,n.KBD_9=57,n.KBD_a=65,n.KBD_b=66,n.KBD_c=67,n.KBD_d=68,n.KBD_e=69,n.KBD_f=70,n.KBD_g=71,n.KBD_h=72,n.KBD_i=73,n.KBD_j=74,n.KBD_k=75,n.KBD_l=76,n.KBD_m=77,n.KBD_n=78,n.KBD_o=79,n.KBD_p=80,n.KBD_q=81,n.KBD_r=82,n.KBD_s=83,n.KBD_t=84,n.KBD_u=85,n.KBD_v=86,n.KBD_w=87,n.KBD_x=88,n.KBD_y=89,n.KBD_z=90,n.KBD_f1=290,n.KBD_f2=291,n.KBD_f3=292,n.KBD_f4=293,n.KBD_f5=294,n.KBD_f6=295,n.KBD_f7=296,n.KBD_f8=297,n.KBD_f9=298,n.KBD_f10=299,n.KBD_f11=300,n.KBD_f12=301,n.KBD_kp0=320,n.KBD_kp1=321,n.KBD_kp2=322,n.KBD_kp3=323,n.KBD_kp4=324,n.KBD_kp5=325,n.KBD_kp6=326,n.KBD_kp7=327,n.KBD_kp8=328,n.KBD_kp9=329,n.KBD_kpperiod=330,n.KBD_kpdivide=331,n.KBD_kpmultiply=332,n.KBD_kpminus=333,n.KBD_kpplus=334,n.KBD_kpenter=335,n.KBD_esc=256,n.KBD_tab=258,n.KBD_backspace=259,n.KBD_enter=257,n.KBD_space=32,n.KBD_leftalt=342,n.KBD_rightalt=346,n.KBD_leftctrl=341,n.KBD_rightctrl=345,n.KBD_leftshift=340,n.KBD_rightshift=344,n.KBD_capslock=280,n.KBD_scrolllock=281,n.KBD_numlock=282,n.KBD_grave=96,n.KBD_minus=45,n.KBD_equals=61,n.KBD_backslash=92,n.KBD_leftbracket=91,n.KBD_rightbracket=93,n.KBD_semicolon=59,n.KBD_quote=39,n.KBD_period=46,n.KBD_comma=44,n.KBD_slash=47,n.KBD_printscreen=283,n.KBD_pause=284,n.KBD_insert=260,n.KBD_home=268,n.KBD_pageup=266,n.KBD_delete=261,n.KBD_end=269,n.KBD_pagedown=267,n.KBD_left=263,n.KBD_up=265,n.KBD_down=264,n.KBD_right=262,n.KBD_extra_lt_gt=348,n.domToKeyCodes={8:n.KBD_backspace,9:n.KBD_tab,13:n.KBD_enter,16:n.KBD_leftshift,17:n.KBD_leftctrl,18:n.KBD_leftalt,19:n.KBD_pause,27:n.KBD_esc,32:n.KBD_space,33:n.KBD_pageup,34:n.KBD_pagedown,35:n.KBD_end,36:n.KBD_home,37:n.KBD_left,38:n.KBD_up,39:n.KBD_right,40:n.KBD_down,45:n.KBD_insert,46:n.KBD_delete,48:n.KBD_0,49:n.KBD_1,50:n.KBD_2,51:n.KBD_3,52:n.KBD_4,53:n.KBD_5,54:n.KBD_6,55:n.KBD_7,56:n.KBD_8,57:n.KBD_9,59:n.KBD_semicolon,64:n.KBD_equals,65:n.KBD_a,66:n.KBD_b,67:n.KBD_c,68:n.KBD_d,69:n.KBD_e,70:n.KBD_f,71:n.KBD_g,72:n.KBD_h,73:n.KBD_i,74:n.KBD_j,75:n.KBD_k,76:n.KBD_l,77:n.KBD_m,78:n.KBD_n,79:n.KBD_o,80:n.KBD_p,81:n.KBD_q,82:n.KBD_r,83:n.KBD_s,84:n.KBD_t,85:n.KBD_u,86:n.KBD_v,87:n.KBD_w,88:n.KBD_x,89:n.KBD_y,90:n.KBD_z,91:n.KBD_leftbracket,93:n.KBD_rightbracket,96:n.KBD_kp0,97:n.KBD_kp1,98:n.KBD_kp2,99:n.KBD_kp3,100:n.KBD_kp4,101:n.KBD_kp5,102:n.KBD_kp6,103:n.KBD_kp7,104:n.KBD_kp8,105:n.KBD_kp9,111:n.KBD_kpdivide,112:n.KBD_f1,113:n.KBD_f2,114:n.KBD_f3,115:n.KBD_f4,116:n.KBD_f5,117:n.KBD_f6,118:n.KBD_f7,119:n.KBD_f8,120:n.KBD_f9,121:n.KBD_f10,122:n.KBD_f11,123:n.KBD_f12,144:n.KBD_numlock,145:n.KBD_scrolllock,173:n.KBD_minus,186:n.KBD_semicolon,187:n.KBD_equals,188:n.KBD_comma,189:n.KBD_minus,190:n.KBD_period,191:n.KBD_slash,219:n.KBD_leftbracket,220:n.KBD_backslash,221:n.KBD_rightbracket},n.namedKeyCodes={KBD_NONE:n.KBD_NONE,KBD_0:n.KBD_0,KBD_1:n.KBD_1,KBD_2:n.KBD_2,KBD_3:n.KBD_3,KBD_4:n.KBD_4,KBD_5:n.KBD_5,KBD_6:n.KBD_6,KBD_7:n.KBD_7,KBD_8:n.KBD_8,KBD_9:n.KBD_9,KBD_a:n.KBD_a,KBD_b:n.KBD_b,KBD_c:n.KBD_c,KBD_d:n.KBD_d,KBD_e:n.KBD_e,KBD_f:n.KBD_f,KBD_g:n.KBD_g,KBD_h:n.KBD_h,KBD_i:n.KBD_i,KBD_j:n.KBD_j,KBD_k:n.KBD_k,KBD_l:n.KBD_l,KBD_m:n.KBD_m,KBD_n:n.KBD_n,KBD_o:n.KBD_o,KBD_p:n.KBD_p,KBD_q:n.KBD_q,KBD_r:n.KBD_r,KBD_s:n.KBD_s,KBD_t:n.KBD_t,KBD_u:n.KBD_u,KBD_v:n.KBD_v,KBD_w:n.KBD_w,KBD_x:n.KBD_x,KBD_y:n.KBD_y,KBD_z:n.KBD_z,KBD_f1:n.KBD_f1,KBD_f2:n.KBD_f2,KBD_f3:n.KBD_f3,KBD_f4:n.KBD_f4,KBD_f5:n.KBD_f5,KBD_f6:n.KBD_f6,KBD_f7:n.KBD_f7,KBD_f8:n.KBD_f8,KBD_f9:n.KBD_f9,KBD_f10:n.KBD_f10,KBD_f11:n.KBD_f11,KBD_f12:n.KBD_f12,KBD_kp0:n.KBD_kp0,KBD_kp1:n.KBD_kp1,KBD_kp2:n.KBD_kp2,KBD_kp3:n.KBD_kp3,KBD_kp4:n.KBD_kp4,KBD_kp5:n.KBD_kp5,KBD_kp6:n.KBD_kp6,KBD_kp7:n.KBD_kp7,KBD_kp8:n.KBD_kp8,KBD_kp9:n.KBD_kp9,KBD_kpperiod:n.KBD_kpperiod,KBD_kpdivide:n.KBD_kpdivide,KBD_kpmultiply:n.KBD_kpmultiply,KBD_kpminus:n.KBD_kpminus,KBD_kpplus:n.KBD_kpplus,KBD_kpenter:n.KBD_kpenter,KBD_esc:n.KBD_esc,KBD_tab:n.KBD_tab,KBD_backspace:n.KBD_backspace,KBD_enter:n.KBD_enter,KBD_space:n.KBD_space,KBD_leftalt:n.KBD_leftalt,KBD_rightalt:n.KBD_rightalt,KBD_leftctrl:n.KBD_leftctrl,KBD_rightctrl:n.KBD_rightctrl,KBD_leftshift:n.KBD_leftshift,KBD_rightshift:n.KBD_rightshift,KBD_capslock:n.KBD_capslock,KBD_scrolllock:n.KBD_scrolllock,KBD_numlock:n.KBD_numlock,KBD_grave:n.KBD_grave,KBD_minus:n.KBD_minus,KBD_equals:n.KBD_equals,KBD_backslash:n.KBD_backslash,KBD_leftbracket:n.KBD_leftbracket,KBD_rightbracket:n.KBD_rightbracket,KBD_semicolon:n.KBD_semicolon,KBD_quote:n.KBD_quote,KBD_period:n.KBD_period,KBD_comma:n.KBD_comma,KBD_slash:n.KBD_slash,KBD_printscreen:n.KBD_printscreen,KBD_pause:n.KBD_pause,KBD_insert:n.KBD_insert,KBD_home:n.KBD_home,KBD_pageup:n.KBD_pageup,KBD_delete:n.KBD_delete,KBD_end:n.KBD_end,KBD_pagedown:n.KBD_pagedown,KBD_left:n.KBD_left,KBD_up:n.KBD_up,KBD_down:n.KBD_down,KBD_right:n.KBD_right,KBD_extra_lt_gt:n.KBD_extra_lt_gt},n.keyCodesToDom={};for(const e of Object.keys(n.domToKeyCodes)){const t=Number.parseInt(e,10);n.keyCodesToDom[n.domToKeyCodes[t]]=t}n.domToKeyCode=function(e){return n.domToKeyCodes[e]||0}},{"core-js/modules/web.dom-collections.iterator.js":118}],149:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}e("core-js/modules/web.dom-collections.iterator.js");Object.defineProperty(n,"__esModule",{value:!0}),n.Layers=n.layers=void 0;const o=e("notyf"),i=function(e){return e&&e.__esModule?e:{default:e}}(e("simple-keyboard")),s=e("./helpers"),a=e("./keys"),l=e("element-resize-detector")({});n.layers=function(e,t){return new c(e,t||{})};class c{constructor(e,t){r(this,"options",void 0),r(this,"root",void 0),r(this,"loading",void 0),r(this,"canvas",void 0),r(this,"video",void 0),r(this,"mouseOverlay",void 0),r(this,"width",void 0),r(this,"height",void 0),r(this,"fullscreen",!1),r(this,"keyboardVisible",!1),r(this,"pointerLock",!1),r(this,"pointerDisabled",!1),r(this,"pointerButton",0),r(this,"notyf",new o.Notyf),r(this,"toggleKeyboard",(()=>!1)),r(this,"fullscreenElement",void 0),r(this,"clickToStart",void 0),r(this,"loaderText",void 0),r(this,"onResize",void 0),r(this,"onKeyDown",void 0),r(this,"onKeyUp",void 0),r(this,"onKeyPress",void 0),r(this,"onKeysPress",void 0),r(this,"onSave",void 0),r(this,"onSaveStarted",void 0),r(this,"onSaveEnded",void 0),r(this,"onFullscreenChanged",[]),r(this,"onKeyboardChanged",[]),this.options=t,this.root=e,this.root.classList.add("emulator-root"),this.fullscreenElement=t.fullscreenElement||this.root,this.canvas=document.createElement("canvas"),this.canvas.className="emulator-canvas",this.video=document.createElement("video"),this.video.setAttribute("autoplay",""),this.video.setAttribute("playsinline",""),this.video.className="emulator-video",this.loading=(0,s.createDiv)("emulator-loading","\n<div class='emulator-loading-inner'>\n<pre class='emulator-loading-pre-1'>\n _ __\n (_)____ ____/ /___ _____ _________ ____ ___\n / / ___/_____/ __ / __ \\/ ___// ___/ __ \\/ __ `__ \\\n / (__ )_____/ /_/ / /_/ (__ )/ /__/ /_/ / / / / / /\n __/ /____/ \\__,_/\\____/____(_)___/\\____/_/ /_/ /_/\n /___/\n</pre>\n<pre class='emulator-loading-pre-2'>\n</pre>\n<div class='emulator-loader'>\n</div>\n</div>\n"),this.loaderText=this.loading.querySelector(".emulator-loading-pre-2"),this.mouseOverlay=(0,s.createDiv)("emulator-mouse-overlay",""),this.clickToStart=(0,s.createDiv)("emulator-click-to-start-overlay",'\n<div class="emulator-click-to-start-text">Press to start</div>\n<div class="emulator-click-to-start-icon"></div>\n'),this.clickToStart.onclick=()=>{this.clickToStart.style.display="none",this.video.play()},this.root.appendChild(this.canvas),this.root.appendChild(this.video),this.root.appendChild(this.mouseOverlay),this.root.appendChild(this.clickToStart),this.root.appendChild(this.loading),this.width=e.offsetWidth,this.height=e.offsetHeight,this.onResize=[],this.onKeyDown=()=>{},this.onKeyUp=()=>{},this.onKeyPress=()=>{},this.onKeysPress=()=>{},this.onSave=()=>Promise.reject(new Error("Not implemented")),this.onSaveStarted=()=>{},this.onSaveEnded=()=>{},l.listenTo(this.root,(t=>{if(t===e){this.width=t.offsetWidth,this.height=t.offsetHeight;for(const e of this.onResize)e(this.width,this.height)}})),this.initKeyEvents(),this.initKeyboard(),this.preventContextMenu(),this.fullscreenElement.onfullscreenchange=()=>{if(document.fullscreenElement!==this.fullscreenElement){this.fullscreen=!1;for(const e of this.onFullscreenChanged)e(this.fullscreen)}}}initKeyEvents(){window.addEventListener("keydown",(e=>{const t=(0,a.domToKeyCode)(e.keyCode);this.onKeyDown(t)})),window.addEventListener("keyup",(e=>{const t=(0,a.domToKeyCode)(e.keyCode);this.onKeyUp(t)}))}preventContextMenu(){this.root.addEventListener("contextmenu",(e=>(e.stopPropagation(),e.preventDefault(),!1)))}addOnResize(e){this.onResize.push(e)}removeOnResize(e){this.onResize=this.onResize.filter((t=>t!==e))}setOnKeyDown(e){this.onKeyDown=e}fireKeyDown(e){this.onKeyDown(e)}setOnKeyUp(e){this.onKeyUp=e}fireKeyUp(e){this.onKeyUp(e)}setOnKeyPress(e){this.onKeyPress=e}fireKeyPress(e){this.onKeyPress(e)}setOnKeysPress(e){this.onKeysPress=e}fireKeysPress(e){this.onKeysPress(e)}toggleFullscreen(){if(this.fullscreen){this.fullscreen=!1,this.fullscreenElement.classList.contains("emulator-fullscreen-workaround")?this.fullscreenElement.classList.remove("emulator-fullscreen-workaround"):document.exitFullscreen?document.exitFullscreen():document.webkitExitFullscreen?document.webkitExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen();for(const e of this.onFullscreenChanged)e(!1)}else{this.fullscreen=!0;const e=this.fullscreenElement;e.requestFullscreen?e.requestFullscreen():e.webkitRequestFullscreen?e.webkitRequestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.msRequestFullscreen?e.msRequestFullscreen():e.webkitEnterFullscreen?e.webkitEnterFullscreen():this.fullscreenElement.classList.add("emulator-fullscreen-workaround");for(const e of this.onFullscreenChanged)e(!0)}}setOnFullscreen(e){this.onFullscreenChanged.push(e)}removeOnFullscreen(e){this.onFullscreenChanged=this.onFullscreenChanged.filter((t=>t!==e))}setOnKeyboardVisibility(e){this.onKeyboardChanged.push(e)}removeOnKeyboardVisibility(e){this.onKeyboardChanged=this.onKeyboardChanged.filter((t=>t!==e))}save(){return this.onSaveStarted(),this.onSave().then((()=>{this.notyf.success("Saved"),this.onSaveEnded()})).catch((e=>{this.notyf.error(e.message),this.onSaveEnded()}))}setOnSave(e){this.onSave=e}getOnSave(){return this.onSave}setOnSaveStarted(e){this.onSaveStarted=e}setOnSaveEnded(e){this.onSaveEnded=e}hideLoadingLayer(){this.loading.style.visibility="hidden"}showLoadingLayer(){this.loading.style.visibility="visible"}setLoadingMessage(e){this.loaderText.innerHTML=e}switchToVideo(){this.video.style.display="block",this.canvas.style.display="none"}showClickToStart(){this.clickToStart.style.display="flex"}initKeyboard(){let e=!1;const t=[{"{esc}":"ESC","{bksp}":"Backspace","{enter}":"⏎","{space}":"Space"},{"{esc}":"ESC","{bksp}":"Backspace","{enter}":"⏎","{space}":"Space",q:"й",w:"ц",e:"у",r:"к",t:"е",y:"н",u:"г",i:"ш",o:"щ",p:"з","{":"х","}":"ъ",a:"ф",s:"ы",d:"в",f:"а",g:"п",h:"р",j:"о",k:"л",l:"д",";":"ж","'":"э",z:"я",x:"ч",c:"с",v:"м",b:"и",n:"т",m:"ь",",":"б",".":"ю"}];let n=0;const r=this.options.keyboardDiv||(0,s.createDiv)("");r.classList.add("emulator-keyboard"),r.style.display="none",(0,s.stopPropagation)(r);const o=new i.default(r,{layout:{en:["{esc} ` 1 2 3 4 5 6 7 8 9 0 - = {bksp}","q w e r t y u i o p { } \\","a s d f g h j k l ; ' [ {enter}","⎘ z x c v b n m , . / ] {space}"]},layoutName:"en",display:t[n],onKeyPress:e=>{if("⎘"===e)return n=(n+1)%t.length,void o.setOptions({display:t[n]});const r=function(e){if(e.length>1)return"{enter}"===e?[a.KBD_enter]:"{shift}"===e?[a.KBD_leftshift]:"{bksp}"===e?[a.KBD_backspace]:"{lock}"===e?[a.KBD_capslock]:"{tab}"===e?[a.KBD_tab]:"{space}"===e?[a.KBD_space]:"{esc}"===e?[a.KBD_esc]:"ctrl"===e?[a.KBD_leftctrl]:"{alt}"===e?[a.KBD_leftalt]:(console.warn("Unknown button",e),[]);if(","===e)return[a.KBD_comma];if("."===e)return[a.KBD_period];if("'"===e)return[a.KBD_quote];if(":"===e)return[a.KBD_semicolon];if("{"===e)return[a.KBD_leftshift,a.KBD_leftbracket];if("}"===e)return[a.KBD_leftshift,a.KBD_rightbracket];const t=(0,a.domToKeyCode)(e.toUpperCase().charCodeAt(0));return 0===t?[]:[t]}(e);1===r.length?this.fireKeyPress(r[0]):r.length>0&&this.fireKeysPress(r)},preventMouseDownDefault:!0,preventMouseUpDefault:!0,stopMouseDownPropagation:!0,stopMouseUpPropagation:!0,autoUseTouchEvents:!0,useMouseEvents:!0});this.toggleKeyboard=()=>{e=!e;const t=e?"block":"none";r.style.display=t;for(const t of this.onKeyboardChanged)t(e);return this.keyboardVisible=e,e},this.options.keyboardDiv||this.mouseOverlay.appendChild(r)}}n.Layers=c},{"./helpers":147,"./keys":148,"core-js/modules/web.dom-collections.iterator.js":118,"element-resize-detector":123,notyf:131,"simple-keyboard":132}],150:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.lifecycle=void 0,n.lifecycle=function(e){let t="",n="";function r(){document[t]?e.pause():e.resume()}void 0!==document.hidden?(t="hidden",n="visibilitychange"):void 0!==document.mozHidden?(t="mozHidden",n="mozvisibilitychange"):void 0!==document.msHidden?(t="msHidden",n="msvisibilitychange"):void 0!==document.webkitHidden&&(t="webkitHidden",n="webkitvisibilitychange"),document.addEventListener(n,r),e.events().onExit((()=>{document.removeEventListener(n,r)}))}},{}],151:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.MemStorage=void 0,n.MemStorage=class{constructor(){r(this,"length",0),r(this,"storage",{})}setItem(e,t){this.storage[e]=t,this.length=Object.keys(this.storage).length}getItem(e){const t=this.storage[e];return void 0===t?null:t}removeItem(e){delete this.storage[e],this.length=Object.keys(this.storage).length}key(e){const t=Object.keys(this.storage);return void 0===t[e]?null:t[e]}clear(){this.length=0,this.storage={}}}},{}],152:[function(e,t,n){"use strict";function r(e,t){if(e.type.match(/^touch/)){const n=e,r=t.getBoundingClientRect();return{x:n.targetTouches[0].clientX-r.x,y:n.targetTouches[0].clientY-r.y,mX:0,mY:0}}if(e.type.match(/^pointer/)){const t=e;return{x:t.offsetX,y:t.offsetY,mX:t.movementX,mY:t.movementY}}{const t=e;return{x:t.offsetX,y:t.offsetY,mX:t.movementX,mY:t.movementY,button:0===t.button?0:1}}}Object.defineProperty(n,"__esModule",{value:!0}),n.pointers=n.getPointerState=n.pointer=void 0,n.pointer=function(){const e=/iPhone|iPad|iPod|Android/i.test(navigator.userAgent),t=e&&!!("ontouchstart"in window),n=e&&!!window.PointerEvent,r=e&&!!window.MSPointerEvent;let o=!e;const i=[],s=[],a=[],l=[],c=[];return n?(i.push("pointerdown"),a.push("pointerup","pointercancel"),s.push("pointermove"),c.push("touchstart","touchmove","touchend")):r?(i.push("MSPointerDown"),s.push("MSPointerMove"),a.push("MSPointerUp")):t?(o=!1,i.push("touchstart","mousedown"),s.push("touchmove"),a.push("touchend","touchcancel","mouseup")):(i.push("mousedown"),s.push("mousemove"),a.push("mouseup"),l.push("mouseleave")),{mobile:e,canLock:o,starters:i,changers:s,enders:a,prevents:c,leavers:l}}(),n.getPointerState=r,n.pointers={bind:n.pointer,getPointerState:r}},{}],153:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.LStorage=void 0;const o=e("./mem-storage");n.LStorage=class{constructor(e,t){r(this,"backend",void 0),r(this,"length",void 0),r(this,"prefix",void 0),this.prefix=t;try{this.backend=e||localStorage,this.testBackend()}catch(e){this.backend=new o.MemStorage}this.length=this.backend.length,"function"==typeof this.backend.sync&&(this.sync=e=>{this.backend.sync(e)})}testBackend(){const e=this.prefix+".test.record";this.backend.setItem(e,"123");const t=this.backend.getItem(e);if(this.backend.removeItem(e),"123"!==t||null!==this.backend.getItem(e))throw new Error("Storage backend is not working properly")}setLocalStoragePrefix(e){this.prefix=e}clear(){if(!this.backend.length)return;const e=[];for(let t=0;t<this.backend.length;++t){const n=this.backend.key(t);n&&n.startsWith(this.prefix)&&e.push(n)}for(const t of e)this.backend.removeItem(t);this.length=this.backend.length}key(e){return this.backend.key(e)}setItem(e,t){if(!t||void 0===t.length||0===t.length)return void this.writeStringToKey(e,"");let n=0;for(;n<t.length;){let r=t.substr(n,1024);n+=r.length,n<t.length&&(r+="@"),this.writeStringToKey(e,r),e+="."}}getItem(e){let t=this.readStringFromKey(e);if(null===t)return null;if(0===t.length)return t;for(;"@"===t[t.length-1];){t=t.substr(0,t.length-1),e+=".";const n=this.readStringFromKey(e);t+=null===n?"":n}return t}removeItem(e){this.backend.removeItem(this.prefix+e),this.length=this.backend.length}writeStringToKey(e,t){this.backend.setItem(this.prefix+e,t),this.length=this.backend.length}readStringFromKey(e){return this.backend.getItem(this.prefix+e)}}},{"./mem-storage":151,"core-js/modules/web.dom-collections.iterator.js":118}],154:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.EmulatorsUi=void 0;const o=e("./dom/layers"),i=e("./dom/lifecycle"),s=e("./network/xhr"),a=e("./graphics/_2d"),l=e("./graphics/webgl"),c=e("./graphics/video"),u=e("./controls/keyboard"),d=e("./controls/mouse/mouse-common"),f=e("./controls/nipple"),p=e("./controls/options"),h=e("./dom/keys"),m=e("./sound/audio-node"),y=e("./notification/notyf"),v=e("./persist/save-load"),g=e("./controls/grid"),b=e("./dom/pointer"),_=e("./dom/storage"),w=e("./js-dos");class x{constructor(){r(this,"dom",{layers:o.layers,lifecycle:i.lifecycle,pointers:b.pointers,storage:new _.LStorage(void 0,"emulators.ui.")}),r(this,"network",{resolveBundle:s.resolveBundle}),r(this,"graphics",{webGl:l.webGl,_2d:a._2d,video:c.video}),r(this,"sound",{audioNode:m.audioNode}),r(this,"persist",{save:v.save,load:v.load}),r(this,"controls",{getGrid:g.getGrid,namedKeyCodes:h.namedKeyCodes,domToKeyCodes:h.domToKeyCodes,domToKeyCode:h.domToKeyCode,keyCodesToDom:h.keyCodesToDom,keyboard:u.keyboard,mouse:d.mouse,nipple:f.nipple,options:p.options}),r(this,"notifications",{notyf:y.notyf}),r(this,"dos",((e,t)=>new w.DosInstance(e,k,t||{})))}}n.EmulatorsUi=x;const k=new x;window.emulatorsUi=k,window.Dos=k.dos},{"./controls/grid":135,"./controls/keyboard":136,"./controls/mouse/mouse-common":140,"./controls/nipple":144,"./controls/options":146,"./dom/keys":148,"./dom/layers":149,"./dom/lifecycle":150,"./dom/pointer":152,"./dom/storage":153,"./graphics/_2d":155,"./graphics/video":156,"./graphics/webgl":157,"./js-dos":158,"./network/xhr":159,"./notification/notyf":160,"./persist/save-load":161,"./sound/audio-node":162}],155:[function(e,t,n){"use strict";e("core-js/modules/es.typed-array.uint8-clamped-array.js"),e("core-js/modules/es.typed-array.sort.js"),Object.defineProperty(n,"__esModule",{value:!0}),n._2d=void 0,n._2d=function(e,t){const n=e.canvas,r=n.getContext("2d");if(null===r)throw new Error("Unable to create 2d context on given canvas");let o=e.width,i=e.height,s=0,a=0;const l=()=>{const e=s/a;let t=o,r=o/e;r>i&&(r=i,t=i*e),n.style.position="relative",n.style.top=(i-r)/2+"px",n.style.left=(o-t)/2+"px",n.style.width=t+"px",n.style.height=r+"px"},c=(e,t)=>{o=e,i=t,l()};e.addOnResize(c);let u=new Uint8ClampedArray(0);const d=(e,t)=>{s=e,a=t,n.width=s,n.height=a,u=new Uint8ClampedArray(e*t*4),l()};t.events().onFrameSize(d),t.events().onFrame((e=>{let t=0,n=0;for(;n<u.length;)u[n++]=e[t++],u[n++]=e[t++],u[n++]=e[t++],u[n++]=255;r.putImageData(new ImageData(u,s,a),0,0)})),d(t.width(),t.height()),t.events().onExit((()=>{e.removeOnResize(c)}))}},{"core-js/modules/es.typed-array.sort.js":115,"core-js/modules/es.typed-array.uint8-clamped-array.js":117}],156:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.video=void 0,n.video=function(e,t){e.switchToVideo(),t.events().onMessage(((t,n)=>{"onremotestream"===t&&window.Janus.attachMediaStream(e.video,n)}))}},{}],157:[function(e,t,n){"use strict";function r(e,t,n){const r=e.createShader(t);if(e.shaderSource(r,n),e.compileShader(r),!e.getShaderParameter(r,e.COMPILE_STATUS)){const t=e.getShaderInfoLog(r);throw e.deleteShader(r),new Error("An error occurred compiling the shaders: "+t)}return r}e("core-js/modules/es.typed-array.uint8-array.js"),e("core-js/modules/es.typed-array.sort.js"),e("core-js/modules/es.typed-array.float32-array.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.webGl=void 0,n.webGl=function(e,t){const n=e.canvas,o=n.getContext("webgl");if(null===o)throw new Error("Unable to create webgl context on given canvas");const i=function(e,t,n){const o=r(e,e.VERTEX_SHADER,"\nattribute vec4 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nvarying highp vec2 vTextureCoord;\n\nvoid main(void) {\n gl_Position = aVertexPosition;\n vTextureCoord = aTextureCoord;\n}\n"),i=r(e,e.FRAGMENT_SHADER,"\nvarying highp vec2 vTextureCoord;\nuniform sampler2D uSampler;\n\n\nvoid main(void) {\n highp vec4 color = texture2D(uSampler, vTextureCoord);\n gl_FragColor = vec4(color.r, color.g, color.b, 1.0);\n}\n"),s=e.createProgram();if(e.attachShader(s,o),e.attachShader(s,i),e.linkProgram(s),!e.getProgramParameter(s,e.LINK_STATUS))throw new Error("Unable to initialize the shader program: "+e.getProgramInfoLog(s));return s}(o),s=o.getAttribLocation(i,"aVertexPosition"),a=o.getAttribLocation(i,"aTextureCoord"),l=o.getUniformLocation(i,"uSampler");!function(e,t,n){const r=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,r);e.bufferData(e.ARRAY_BUFFER,new Float32Array([-1,-1,0,1,-1,0,1,1,0,-1,-1,0,1,1,0,-1,1,0]),e.STATIC_DRAW),e.vertexAttribPointer(t,3,e.FLOAT,!1,0,0),e.enableVertexAttribArray(t);const o=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,o);e.bufferData(e.ARRAY_BUFFER,new Float32Array([0,1,1,1,1,0,0,1,1,0,0,0]),e.STATIC_DRAW),e.vertexAttribPointer(n,2,e.FLOAT,!1,0,0),e.enableVertexAttribArray(n)}(o,s,a);const c=o.createTexture();o.bindTexture(o.TEXTURE_2D,c),o.texParameteri(o.TEXTURE_2D,o.TEXTURE_WRAP_S,o.CLAMP_TO_EDGE),o.texParameteri(o.TEXTURE_2D,o.TEXTURE_WRAP_T,o.CLAMP_TO_EDGE),o.texParameteri(o.TEXTURE_2D,o.TEXTURE_MIN_FILTER,o.LINEAR),o.texParameteri(o.TEXTURE_2D,o.TEXTURE_MAG_FILTER,o.LINEAR);const u=new Uint8Array([0,0,0]);o.texImage2D(o.TEXTURE_2D,0,o.RGB,1,1,0,o.RGB,o.UNSIGNED_BYTE,u),o.useProgram(i),o.activeTexture(o.TEXTURE0),o.uniform1i(l,0);let d=e.width,f=e.height,p=0,h=0;const m=()=>{const e=p/h;let t=d,r=d/e;r>f&&(r=f,t=f*e),n.style.position="relative",n.style.top=(f-r)/2+"px",n.style.left=(d-t)/2+"px",n.style.width=t+"px",n.style.height=r+"px"},y=(e,t)=>{d=e,f=t,m()};e.addOnResize(y);const v=(e,t)=>{p=e,h=t,n.width=p,n.height=h,o.viewport(0,0,p,h),m()};t.events().onFrameSize(v),t.events().onFrame((e=>{o.texImage2D(o.TEXTURE_2D,0,o.RGB,p,h,0,o.RGB,o.UNSIGNED_BYTE,e),o.drawArrays(o.TRIANGLES,0,6)})),v(t.width(),t.height()),t.events().onExit((()=>{e.removeOnResize(y)}))}},{"core-js/modules/es.typed-array.float32-array.js":114,"core-js/modules/es.typed-array.sort.js":115,"core-js/modules/es.typed-array.uint8-array.js":116}],158:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.DosInstance=void 0;const o=e("./build"),i=e("./controls/layers-config"),s=e("./controls/legacy-layers-control"),a=e("./controls/null-layers-control"),l=e("./controls/layers-control"),c=e("./dom/pointer");class u{constructor(e,t,n){var i,s;r(this,"emulatorsUi",void 0),r(this,"emulatorFunction",void 0),r(this,"createTransportLayer",void 0),r(this,"layers",void 0),r(this,"layersConfig",null),r(this,"ciPromise",void 0),r(this,"options",void 0),r(this,"mobileControls",void 0),r(this,"mirroredControls",void 0),r(this,"scaleControls",void 0),r(this,"autolock",void 0),r(this,"sensitivity",void 0),r(this,"storage",void 0),r(this,"clickToStart",void 0),r(this,"unbindControls",(()=>{})),r(this,"storedLayersConfig",null),r(this,"onMobileControlsChanged",void 0),u.initialRun&&(emulators.cacheSeed+=" ui ("+o.Build.short+")",u.initialRun=!1),this.options=n,this.emulatorsUi=t,this.storage=t.dom.storage,this.emulatorFunction=n.emulatorFunction||"dosboxWorker",this.clickToStart=n.clickToStart||!1,this.layers=this.emulatorsUi.dom.layers(e,n.layersOptions),this.layers.showLoadingLayer(),this.createTransportLayer=n.createTransportLayer,this.mobileControls=c.pointers.bind.mobile,this.autolock=!1,this.mirroredControls="true"===this.storage.getItem("mirroredControls");const a=Number.parseFloat(null!==(i=this.storage.getItem("scaleControls"))&&void 0!==i?i:"1.0");this.scaleControls=Number.isNaN(a)?1:a;const l=Number.parseFloat(null!==(s=this.storage.getItem("sensitivity"))&&void 0!==s?s:"1.0");if(this.sensitivity=Number.isNaN(l)?1:l,this.onMobileControlsChanged=()=>{},"backend"===this.emulatorFunction&&void 0===this.createTransportLayer)throw new Error("Emulator function set to 'backend' but 'createTransportLayer' is not a function")}async run(e,t,n){var r,o,s;await this.stop(),this.layers.setLoadingMessage("Starting...");const a=null!=n&&n.length>0?n:e+".changes";let l;try{l=await this.runBundle(e,t,a)}catch(e){throw this.layers.setLoadingMessage("Unexpected error occured..."),this.layers.notyf.error({message:"Can't start emulator look browser logs for more info"}),console.error(e),e}const c=this.emulatorsUi;if("janus"===this.emulatorFunction)c.graphics.video(this.layers,l);else{c.persist.save(a,this.layers,l,emulators);try{if(!0===this.options.noWebGL)throw new Error("WebGL is disabled by options");c.graphics.webGl(this.layers,l)}catch(e){console.error("Unable to create webgl canvas, fallback to 2d rendering"),c.graphics._2d(this.layers,l)}c.sound.audioNode(l)}c.dom.lifecycle(l);const u=await l.config();return this.autolock=!0===(null===(r=u.output)||void 0===r||null===(o=r.options)||void 0===o||null===(s=o.autolock)||void 0===s?void 0:s.value),await this.setLayersConfig((0,i.extractLayersConfig)(u)),this.mobileControls||(this.mobileControls=!0,this.disableMobileControls()),this.layers.setLoadingMessage("Ready"),this.layers.hideLoadingLayer(),this.clickToStart&&this.layers.showClickToStart(),l}async stop(){if(this.layers.showLoadingLayer(),void 0===this.ciPromise)return;const e=await this.ciPromise;delete this.ciPromise,await e.exit()}async setLayersConfig(e,t){if(void 0===this.ciPromise)return;const n=await this.ciPromise;this.layersConfig=e,this.unbindControls(),null===e?this.unbindControls=(0,a.initNullLayersControl)(this,this.layers,n):void 0===e.version?this.unbindControls=(0,s.initLegacyLayersControl)(this,this.layers,e,n):this.unbindControls=(0,l.initLayersControl)(this.layers,e,n,this,this.mirroredControls,this.scaleControls,t)}getLayersConfig(){return this.layersConfig}async enableMobileControls(){this.mobileControls||(this.mobileControls=!0,await this.setLayersConfig(this.storedLayersConfig),this.storedLayersConfig=null,this.onMobileControlsChanged(!0))}async disableMobileControls(){this.mobileControls&&(this.mobileControls=!1,this.storedLayersConfig=this.layersConfig,await this.setLayersConfig(null),this.onMobileControlsChanged(!1))}async setMirroredControls(e){this.mirroredControls!==e&&(this.mirroredControls=e,this.storage.setItem("mirroredControls",e+""),e?this.mobileControls?await this.setLayersConfig(this.layersConfig):await this.enableMobileControls():this.mobileControls&&await this.setLayersConfig(this.layersConfig))}async setScaleControls(e){e!==this.scaleControls&&(this.scaleControls=e,this.storage.setItem("scaleControls",e+""),this.mobileControls&&await this.setLayersConfig(this.layersConfig))}async setSensitivity(e){e!==this.sensitivity&&(this.sensitivity=e,this.storage.setItem("sensitivity",e+""),await this.setLayersConfig(this.layersConfig))}async setAutolock(e){e!==this.autolock&&(this.autolock=e,await this.setLayersConfig(this.layersConfig))}setOnMobileControlsChanged(e){this.onMobileControlsChanged=e}async runBundle(e,t,n){const r=this.emulatorsUi;if("janus"===this.emulatorFunction)this.layers.setLoadingMessage("Connecting..."),this.ciPromise=emulators.janus(e);else{this.layers.setLoadingMessage("Downloading bundle ...");const o=r.network.resolveBundle(e,{onprogress:e=>this.layers.setLoadingMessage("Downloading bundle "+e+"%")});try{let e;e=null!=t&&t.length>0?await r.network.resolveBundle(t,{httpCache:!1}):await r.persist.load(n,emulators);const i=await o;"backend"===this.emulatorFunction?this.ciPromise=emulators.backend([i,e],this.createTransportLayer()):this.ciPromise=emulators[this.emulatorFunction]([i,e])}catch{const e=await o;"backend"===this.emulatorFunction?this.ciPromise=emulators.backend([e],this.createTransportLayer()):this.ciPromise=emulators[this.emulatorFunction]([e])}}return this.ciPromise}}r(u,"initialRun",!0),n.DosInstance=u},{"./build":133,"./controls/layers-config":137,"./controls/layers-control":138,"./controls/legacy-layers-control":139,"./controls/null-layers-control":145,"./dom/pointer":152}],159:[function(e,t,n){"use strict";e("core-js/modules/es.typed-array.uint8-array.js"),e("core-js/modules/es.typed-array.sort.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.resolveBundle=void 0,n.resolveBundle=async function(e,t){const n=(null==t?void 0:t.cache)||null,r=null==t?void 0:t.onprogress,o=!(!1===(null==t?void 0:t.httpCache));try{if(null===n)throw new Error("no-cache");const t=n||await emulators.cache(),o=await t.get(e);return void 0!==r&&r(100),new Uint8Array(o)}catch{return new Promise(((t,n)=>{const i=new XMLHttpRequest;i.open("GET",e,!0),i.overrideMimeType("text/plain; charset=x-user-defined"),i.addEventListener("error",(()=>{n(new Error("Network error, can't download "+e))})),i.addEventListener("abort",(()=>{n(new Error("Request canceled for url "+e))}),!1),i.responseType="arraybuffer",i.onreadystatechange=()=>{4===i.readyState&&(200===i.status?(void 0!==r&&r(100),t(new Uint8Array(i.response))):n(new Error("Network error, can't download "+e)))},void 0!==r&&(i.onprogress=e=>{if(e.total&&e.total>0){const t=Math.round(1e4*e.loaded/e.total)/100;r(t)}}),!1===o&&(i.setRequestHeader("Cache-Control","no-cache, no-store, max-age=0"),i.setRequestHeader("Expires","Tue, 01 Jan 1980 1:00:00 GMT"),i.setRequestHeader("Pragma","no-cache")),i.send()}))}}},{"core-js/modules/es.typed-array.sort.js":115,"core-js/modules/es.typed-array.uint8-array.js":116}],160:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.notyf=void 0,n.notyf=function(e,t){const n=e.notyf;t.events().onMessage((function(e){if("error"===e){for(var t=arguments.length,r=new Array(t>1?t-1:0),o=1;o<t;o++)r[o-1]=arguments[o];n.error({message:JSON.stringify(r)})}}))}},{}],161:[function(e,t,n){"use strict";e("core-js/modules/es.typed-array.uint8-array.js"),e("core-js/modules/es.typed-array.sort.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.load=n.save=void 0;const r="emulators-ui-saves";n.save=function(e,t,n,o){t.setOnSave((async()=>{const t=await o.cache(r),i=await n.persist();return t.put(e,i.buffer)}))},n.load=async function(e,t){return(await t.cache(r)).get(e).then((e=>new Uint8Array(e)))}},{"core-js/modules/es.typed-array.sort.js":115,"core-js/modules/es.typed-array.uint8-array.js":116}],162:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.audioNode=void 0;class r{constructor(){var e,t;t=[],(e="samplesQueue")in this?Object.defineProperty(this,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):this[e]=t}push(e){this.samplesQueue.push(e)}length(){let e=0;for(const t of this.samplesQueue)e+=t.length;return e}writeTo(e,t){let n=0;for(;this.samplesQueue.length>0;){const r=this.samplesQueue[0],o=Math.min(t-n,r.length);if(o===r.length?(e.set(r,n),this.samplesQueue.shift()):(e.set(r.slice(0,o),n),this.samplesQueue[0]=r.slice(o)),n+=o,n===t)break}n<t&&e.fill(0,n)}}n.audioNode=function(e){const t=e.soundFrequency();if(0===t)return void console.warn("Can't create audio node with sampleRate === 0, ingnoring");let n=null;if("undefined"!=typeof AudioContext?n=new AudioContext({sampleRate:t,latencyHint:"interactive"}):void 0!==window.webkitAudioContext&&(n=new window.webkitAudioContext({sampleRate:t,latencyHint:"interactive"})),null==n)return;const o=new r;e.events().onSoundPush((e=>{o.length()<6144&&o.push(e)}));const i=n.createScriptProcessor(2048,0,1);let s=!1;i.onaudioprocess=e=>{const t=e.outputBuffer.length,n=e.outputBuffer.numberOfChannels,r=o.length();if(s||(s=r>=2048),s)for(let r=0;r<n;r++){const n=e.outputBuffer.getChannelData(r);o.writeTo(n,t)}},i.connect(n.destination);const a=()=>{null!==n&&"suspended"===n.state&&n.resume()};document.addEventListener("click",a,{once:!0}),document.addEventListener("touchstart",a,{once:!0}),document.addEventListener("keydown",a,{once:!0}),e.events().onExit((()=>{null!==n&&(i.disconnect(),n.close()),document.removeEventListener("click",a),document.removeEventListener("touchstart",a),document.removeEventListener("keydown",a)}))}},{"core-js/modules/web.dom-collections.iterator.js":118}]},{},[154]),function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(i)return i(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i="function"==typeof require&&require,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(e,t,n){t.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},{}],2:[function(e,t,n){var r=e("./_wks")("unscopables"),o=Array.prototype;null==o[r]&&e("./_hide")(o,r,{}),t.exports=function(e){o[r][e]=!0}},{"./_hide":31,"./_wks":99}],3:[function(e,t,n){"use strict";var r=e("./_string-at")(!0);t.exports=function(e,t,n){return t+(n?r(e,t).length:1)}},{"./_string-at":80}],4:[function(e,t,n){t.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},{}],5:[function(e,t,n){var r=e("./_is-object");t.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},{"./_is-object":39}],6:[function(e,t,n){"use strict";var r=e("./_to-object"),o=e("./_to-absolute-index"),i=e("./_to-length");t.exports=[].copyWithin||function(e,t,n){var s=r(this),a=i(s.length),l=o(e,a),c=o(t,a),u=2<arguments.length?n:void 0,d=Math.min((void 0===u?a:o(u,a))-c,a-l),f=1;for(c<l&&l<c+d&&(f=-1,c+=d-1,l+=d-1);0<d--;)c in s?s[l]=s[c]:delete s[l],l+=f,c+=f;return s}},{"./_to-absolute-index":85,"./_to-length":89,"./_to-object":90}],7:[function(e,t,n){"use strict";var r=e("./_to-object"),o=e("./_to-absolute-index"),i=e("./_to-length");t.exports=function(e,t,n){for(var s=r(this),a=i(s.length),l=arguments.length,c=o(1<l?t:void 0,a),u=2<l?n:void 0,d=void 0===u?a:o(u,a);c<d;)s[c++]=e;return s}},{"./_to-absolute-index":85,"./_to-length":89,"./_to-object":90}],8:[function(e,t,n){var r=e("./_to-iobject"),o=e("./_to-length"),i=e("./_to-absolute-index");t.exports=function(e){return function(t,n,s){var a,l=r(t),c=o(l.length),u=i(s,c);if(e&&n!=n){for(;u<c;)if((a=l[u++])!=a)return!0}else for(;u<c;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}}},{"./_to-absolute-index":85,"./_to-iobject":88,"./_to-length":89}],9:[function(e,t,n){var r=e("./_ctx"),o=e("./_iobject"),i=e("./_to-object"),s=e("./_to-length"),a=e("./_array-species-create");t.exports=function(e,t){var n=1==e,l=2==e,c=3==e,u=4==e,d=6==e,f=5==e||d,p=t||a;return function(t,a,h){for(var m,y,v=i(t),g=o(v),b=r(a,h,3),_=s(g.length),w=0,x=n?p(t,_):l?p(t,0):void 0;w<_;w++)if((f||w in g)&&(y=b(m=g[w],w,v),e))if(n)x[w]=y;else if(y)switch(e){case 3:return!0;case 5:return m;case 6:return w;case 2:x.push(m)}else if(u)return!1;return d?-1:c||u?u:x}}},{"./_array-species-create":11,"./_ctx":16,"./_iobject":36,"./_to-length":89,"./_to-object":90}],10:[function(e,t,n){var r=e("./_is-object"),o=e("./_is-array"),i=e("./_wks")("species");t.exports=function(e){var t;return o(e)&&("function"!=typeof(t=e.constructor)||t!==Array&&!o(t.prototype)||(t=void 0),r(t)&&null===(t=t[i])&&(t=void 0)),void 0===t?Array:t}},{"./_is-array":38,"./_is-object":39,"./_wks":99}],11:[function(e,t,n){var r=e("./_array-species-constructor");t.exports=function(e,t){return new(r(e))(t)}},{"./_array-species-constructor":10}],12:[function(e,t,n){var r=e("./_cof"),o=e("./_wks")("toStringTag"),i="Arguments"==r(function(){return arguments}());t.exports=function(e){var t,n,s;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=Object(e),o))?n:i?r(t):"Object"==(s=r(t))&&"function"==typeof t.callee?"Arguments":s}},{"./_cof":13,"./_wks":99}],13:[function(e,t,n){var r={}.toString;t.exports=function(e){return r.call(e).slice(8,-1)}},{}],14:[function(e,t,n){var r=t.exports={version:"2.6.11"};"number"==typeof __e&&(__e=r)},{}],15:[function(e,t,n){"use strict";var r=e("./_object-dp"),o=e("./_property-desc");t.exports=function(e,t,n){t in e?r.f(e,t,o(0,n)):e[t]=n}},{"./_object-dp":54,"./_property-desc":69}],16:[function(e,t,n){var r=e("./_a-function");t.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}}},{"./_a-function":1}],17:[function(e,t,n){t.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},{}],18:[function(e,t,n){t.exports=!e("./_fails")((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},{"./_fails":24}],19:[function(e,t,n){var r=e("./_is-object"),o=e("./_global").document,i=r(o)&&r(o.createElement);t.exports=function(e){return i?o.createElement(e):{}}},{"./_global":29,"./_is-object":39}],20:[function(e,t,n){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},{}],21:[function(e,t,n){var r=e("./_object-keys"),o=e("./_object-gops"),i=e("./_object-pie");t.exports=function(e){var t=r(e),n=o.f;if(n)for(var s,a=n(e),l=i.f,c=0;a.length>c;)l.call(e,s=a[c++])&&t.push(s);return t}},{"./_object-gops":59,"./_object-keys":62,"./_object-pie":63}],22:[function(e,t,n){var r=e("./_global"),o=e("./_core"),i=e("./_hide"),s=e("./_redefine"),a=e("./_ctx"),l="prototype",c=function(e,t,n){var u,d,f,p,h=e&c.F,m=e&c.G,y=e&c.S,v=e&c.P,g=e&c.B,b=m?r:y?r[t]||(r[t]={}):(r[t]||{})[l],_=m?o:o[t]||(o[t]={}),w=_[l]||(_[l]={});for(u in m&&(n=t),n)f=((d=!h&&b&&void 0!==b[u])?b:n)[u],p=g&&d?a(f,r):v&&"function"==typeof f?a(Function.call,f):f,b&&s(b,u,f,e&c.U),_[u]!=f&&i(_,u,p),v&&w[u]!=f&&(w[u]=f)};r.core=o,c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,t.exports=c},{"./_core":14,"./_ctx":16,"./_global":29,"./_hide":31,"./_redefine":71}],23:[function(e,t,n){var r=e("./_wks")("match");t.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[r]=!1,!"/./"[e](t)}catch(e){}}return!0}},{"./_wks":99}],24:[function(e,t,n){t.exports=function(e){try{return!!e()}catch(e){return!0}}},{}],25:[function(e,t,n){"use strict";e("./es6.regexp.exec");var r=e("./_redefine"),o=e("./_hide"),i=e("./_fails"),s=e("./_defined"),a=e("./_wks"),l=e("./_regexp-exec"),c=a("species"),u=!i((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")})),d=function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return 2===n.length&&"a"===n[0]&&"b"===n[1]}();t.exports=function(e,t,n){var f=a(e),p=!i((function(){var t={};return t[f]=function(){return 7},7!=""[e](t)})),h=p?!i((function(){var t=!1,n=/a/;return n.exec=function(){return t=!0,null},"split"===e&&(n.constructor={},n.constructor[c]=function(){return n}),n[f](""),!t})):void 0;if(!p||!h||"replace"===e&&!u||"split"===e&&!d){var m=/./[f],y=n(s,f,""[e],(function(e,t,n,r,o){return t.exec===l?p&&!o?{done:!0,value:m.call(t,n,r)}:{done:!0,value:e.call(n,t,r)}:{done:!1}})),v=y[0],g=y[1];r(String.prototype,e,v),o(RegExp.prototype,f,2==t?function(e,t){return g.call(e,this,t)}:function(e){return g.call(e,this)})}}},{"./_defined":17,"./_fails":24,"./_hide":31,"./_redefine":71,"./_regexp-exec":73,"./_wks":99,"./es6.regexp.exec":115}],26:[function(e,t,n){"use strict";var r=e("./_an-object");t.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},{"./_an-object":5}],27:[function(e,t,n){var r=e("./_ctx"),o=e("./_iter-call"),i=e("./_is-array-iter"),s=e("./_an-object"),a=e("./_to-length"),l=e("./core.get-iterator-method"),c={},u={};(n=t.exports=function(e,t,n,d,f){var p,h,m,y,v=f?function(){return e}:l(e),g=r(n,d,t?2:1),b=0;if("function"!=typeof v)throw TypeError(e+" is not iterable!");if(i(v)){for(p=a(e.length);b<p;b++)if((y=t?g(s(h=e[b])[0],h[1]):g(e[b]))===c||y===u)return y}else for(m=v.call(e);!(h=m.next()).done;)if((y=o(m,g,h.value,t))===c||y===u)return y}).BREAK=c,n.RETURN=u},{"./_an-object":5,"./_ctx":16,"./_is-array-iter":37,"./_iter-call":41,"./_to-length":89,"./core.get-iterator-method":100}],28:[function(e,t,n){t.exports=e("./_shared")("native-function-to-string",Function.toString)},{"./_shared":78}],29:[function(e,t,n){var r=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=r)},{}],30:[function(e,t,n){var r={}.hasOwnProperty;t.exports=function(e,t){return r.call(e,t)}},{}],31:[function(e,t,n){var r=e("./_object-dp"),o=e("./_property-desc");t.exports=e("./_descriptors")?function(e,t,n){return r.f(e,t,o(1,n))}:function(e,t,n){return e[t]=n,e}},{"./_descriptors":18,"./_object-dp":54,"./_property-desc":69}],32:[function(e,t,n){var r=e("./_global").document;t.exports=r&&r.documentElement},{"./_global":29}],33:[function(e,t,n){t.exports=!e("./_descriptors")&&!e("./_fails")((function(){return 7!=Object.defineProperty(e("./_dom-create")("div"),"a",{get:function(){return 7}}).a}))},{"./_descriptors":18,"./_dom-create":19,"./_fails":24}],34:[function(e,t,n){var r=e("./_is-object"),o=e("./_set-proto").set;t.exports=function(e,t,n){var i,s=t.constructor;return s!==n&&"function"==typeof s&&(i=s.prototype)!==n.prototype&&r(i)&&o&&o(e,i),e}},{"./_is-object":39,"./_set-proto":74}],35:[function(e,t,n){t.exports=function(e,t,n){var r=void 0===n;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},{}],36:[function(e,t,n){var r=e("./_cof");t.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},{"./_cof":13}],37:[function(e,t,n){var r=e("./_iterators"),o=e("./_wks")("iterator"),i=Array.prototype;t.exports=function(e){return void 0!==e&&(r.Array===e||i[o]===e)}},{"./_iterators":46,"./_wks":99}],38:[function(e,t,n){var r=e("./_cof");t.exports=Array.isArray||function(e){return"Array"==r(e)}},{"./_cof":13}],39:[function(e,t,n){t.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},{}],40:[function(e,t,n){var r=e("./_is-object"),o=e("./_cof"),i=e("./_wks")("match");t.exports=function(e){var t;return r(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==o(e))}},{"./_cof":13,"./_is-object":39,"./_wks":99}],41:[function(e,t,n){var r=e("./_an-object");t.exports=function(e,t,n,o){try{return o?t(r(n)[0],n[1]):t(n)}catch(t){var i=e.return;throw void 0!==i&&r(i.call(e)),t}}},{"./_an-object":5}],42:[function(e,t,n){"use strict";var r=e("./_object-create"),o=e("./_property-desc"),i=e("./_set-to-string-tag"),s={};e("./_hide")(s,e("./_wks")("iterator"),(function(){return this})),t.exports=function(e,t,n){e.prototype=r(s,{next:o(1,n)}),i(e,t+" Iterator")}},{"./_hide":31,"./_object-create":53,"./_property-desc":69,"./_set-to-string-tag":76,"./_wks":99}],43:[function(e,t,n){"use strict";function r(){return this}var o=e("./_library"),i=e("./_export"),s=e("./_redefine"),a=e("./_hide"),l=e("./_iterators"),c=e("./_iter-create"),u=e("./_set-to-string-tag"),d=e("./_object-gpo"),f=e("./_wks")("iterator"),p=!([].keys&&"next"in[].keys()),h="values";t.exports=function(e,t,n,m,y,v,g){function b(e){if(!p&&e in D)return D[e];switch(e){case"keys":case h:return function(){return new n(this,e)}}return function(){return new n(this,e)}}c(n,t,m);var _,w,x,k=t+" Iterator",j=y==h,C=!1,D=e.prototype,E=D[f]||D["@@iterator"]||y&&D[y],S=E||b(y),O=y?j?b("entries"):S:void 0,P="Array"==t&&D.entries||E;if(P&&(x=d(P.call(new e)))!==Object.prototype&&x.next&&(u(x,k,!0),o||"function"==typeof x[f]||a(x,f,r)),j&&E&&E.name!==h&&(C=!0,S=function(){return E.call(this)}),o&&!g||!p&&!C&&D[f]||a(D,f,S),l[t]=S,l[k]=r,y)if(_={values:j?S:b(h),keys:v?S:b("keys"),entries:O},g)for(w in _)w in D||s(D,w,_[w]);else i(i.P+i.F*(p||C),t,_);return _}},{"./_export":22,"./_hide":31,"./_iter-create":42,"./_iterators":46,"./_library":47,"./_object-gpo":60,"./_redefine":71,"./_set-to-string-tag":76,"./_wks":99}],44:[function(e,t,n){var r=e("./_wks")("iterator"),o=!1;try{var i=[7][r]();i.return=function(){o=!0},Array.from(i,(function(){throw 2}))}catch(e){}t.exports=function(e,t){if(!t&&!o)return!1;var n=!1;try{var i=[7],s=i[r]();s.next=function(){return{done:n=!0}},i[r]=function(){return s},e(i)}catch(e){}return n}},{"./_wks":99}],45:[function(e,t,n){t.exports=function(e,t){return{value:t,done:!!e}}},{}],46:[function(e,t,n){t.exports={}},{}],47:[function(e,t,n){t.exports=!1},{}],48:[function(e,t,n){var r=e("./_math-sign"),o=Math.pow,i=o(2,-52),s=o(2,-23),a=o(2,127)*(2-s),l=o(2,-126);t.exports=Math.fround||function(e){var t,n,o=Math.abs(e),c=r(e);return o<l?c*(o/l/s+1/i-1/i)*l*s:a<(n=(t=(1+s/i)*o)-(t-o))||n!=n?c*(1/0):c*n}},{"./_math-sign":49}],49:[function(e,t,n){t.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},{}],50:[function(e,t,n){function r(e){a(e,o,{value:{i:"O"+ ++l,w:{}}})}var o=e("./_uid")("meta"),i=e("./_is-object"),s=e("./_has"),a=e("./_object-dp").f,l=0,c=Object.isExtensible||function(){return!0},u=!e("./_fails")((function(){return c(Object.preventExtensions({}))})),d=t.exports={KEY:o,NEED:!1,fastKey:function(e,t){if(!i(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!s(e,o)){if(!c(e))return"F";if(!t)return"E";r(e)}return e[o].i},getWeak:function(e,t){if(!s(e,o)){if(!c(e))return!0;if(!t)return!1;r(e)}return e[o].w},onFreeze:function(e){return u&&d.NEED&&c(e)&&!s(e,o)&&r(e),e}}},{"./_fails":24,"./_has":30,"./_is-object":39,"./_object-dp":54,"./_uid":95}],51:[function(e,t,n){var r=e("./_global"),o=e("./_task").set,i=r.MutationObserver||r.WebKitMutationObserver,s=r.process,a=r.Promise,l="process"==e("./_cof")(s);t.exports=function(){function e(){var e,r;for(l&&(e=s.domain)&&e.exit();t;){r=t.fn,t=t.next;try{r()}catch(e){throw t?c():n=void 0,e}}n=void 0,e&&e.enter()}var t,n,c;if(l)c=function(){s.nextTick(e)};else if(!i||r.navigator&&r.navigator.standalone)if(a&&a.resolve){var u=a.resolve(void 0);c=function(){u.then(e)}}else c=function(){o.call(r,e)};else{var d=!0,f=document.createTextNode("");new i(e).observe(f,{characterData:!0}),c=function(){f.data=d=!d}}return function(e){var r={fn:e,next:void 0};n&&(n.next=r),t||(t=r,c()),n=r}}},{"./_cof":13,"./_global":29,"./_task":84}],52:[function(e,t,n){"use strict";var r=e("./_a-function");function o(e){var t,n;this.promise=new e((function(e,r){if(void 0!==t||void 0!==n)throw TypeError("Bad Promise constructor");t=e,n=r})),this.resolve=r(t),this.reject=r(n)}t.exports.f=function(e){return new o(e)}},{"./_a-function":1}],53:[function(e,t,n){function r(){}var o=e("./_an-object"),i=e("./_object-dps"),s=e("./_enum-bug-keys"),a=e("./_shared-key")("IE_PROTO"),l="prototype",c=function(){var t,n=e("./_dom-create")("iframe"),r=s.length;for(n.style.display="none",e("./_html").appendChild(n),n.src="javascript:",(t=n.contentWindow.document).open(),t.write("<script>document.F=Object<\/script>"),t.close(),c=t.F;r--;)delete c[l][s[r]];return c()};t.exports=Object.create||function(e,t){var n;return null!==e?(r[l]=o(e),n=new r,r[l]=null,n[a]=e):n=c(),void 0===t?n:i(n,t)}},{"./_an-object":5,"./_dom-create":19,"./_enum-bug-keys":20,"./_html":32,"./_object-dps":55,"./_shared-key":77}],54:[function(e,t,n){var r=e("./_an-object"),o=e("./_ie8-dom-define"),i=e("./_to-primitive"),s=Object.defineProperty;n.f=e("./_descriptors")?Object.defineProperty:function(e,t,n){if(r(e),t=i(t,!0),r(n),o)try{return s(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},{"./_an-object":5,"./_descriptors":18,"./_ie8-dom-define":33,"./_to-primitive":91}],55:[function(e,t,n){var r=e("./_object-dp"),o=e("./_an-object"),i=e("./_object-keys");t.exports=e("./_descriptors")?Object.defineProperties:function(e,t){o(e);for(var n,s=i(t),a=s.length,l=0;l<a;)r.f(e,n=s[l++],t[n]);return e}},{"./_an-object":5,"./_descriptors":18,"./_object-dp":54,"./_object-keys":62}],56:[function(e,t,n){var r=e("./_object-pie"),o=e("./_property-desc"),i=e("./_to-iobject"),s=e("./_to-primitive"),a=e("./_has"),l=e("./_ie8-dom-define"),c=Object.getOwnPropertyDescriptor;n.f=e("./_descriptors")?c:function(e,t){if(e=i(e),t=s(t,!0),l)try{return c(e,t)}catch(e){}if(a(e,t))return o(!r.f.call(e,t),e[t])}},{"./_descriptors":18,"./_has":30,"./_ie8-dom-define":33,"./_object-pie":63,"./_property-desc":69,"./_to-iobject":88,"./_to-primitive":91}],57:[function(e,t,n){var r=e("./_to-iobject"),o=e("./_object-gopn").f,i={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];t.exports.f=function(e){return s&&"[object Window]"==i.call(e)?function(e){try{return o(e)}catch(e){return s.slice()}}(e):o(r(e))}},{"./_object-gopn":58,"./_to-iobject":88}],58:[function(e,t,n){var r=e("./_object-keys-internal"),o=e("./_enum-bug-keys").concat("length","prototype");n.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},{"./_enum-bug-keys":20,"./_object-keys-internal":61}],59:[function(e,t,n){n.f=Object.getOwnPropertySymbols},{}],60:[function(e,t,n){var r=e("./_has"),o=e("./_to-object"),i=e("./_shared-key")("IE_PROTO"),s=Object.prototype;t.exports=Object.getPrototypeOf||function(e){return e=o(e),r(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?s:null}},{"./_has":30,"./_shared-key":77,"./_to-object":90}],61:[function(e,t,n){var r=e("./_has"),o=e("./_to-iobject"),i=e("./_array-includes")(!1),s=e("./_shared-key")("IE_PROTO");t.exports=function(e,t){var n,a=o(e),l=0,c=[];for(n in a)n!=s&&r(a,n)&&c.push(n);for(;t.length>l;)r(a,n=t[l++])&&(~i(c,n)||c.push(n));return c}},{"./_array-includes":8,"./_has":30,"./_shared-key":77,"./_to-iobject":88}],62:[function(e,t,n){var r=e("./_object-keys-internal"),o=e("./_enum-bug-keys");t.exports=Object.keys||function(e){return r(e,o)}},{"./_enum-bug-keys":20,"./_object-keys-internal":61}],63:[function(e,t,n){n.f={}.propertyIsEnumerable},{}],64:[function(e,t,n){var r=e("./_export"),o=e("./_core"),i=e("./_fails");t.exports=function(e,t){var n=(o.Object||{})[e]||Object[e],s={};s[e]=t(n),r(r.S+r.F*i((function(){n(1)})),"Object",s)}},{"./_core":14,"./_export":22,"./_fails":24}],65:[function(e,t,n){var r=e("./_object-gopn"),o=e("./_object-gops"),i=e("./_an-object"),s=e("./_global").Reflect;t.exports=s&&s.ownKeys||function(e){var t=r.f(i(e)),n=o.f;return n?t.concat(n(e)):t}},{"./_an-object":5,"./_global":29,"./_object-gopn":58,"./_object-gops":59}],66:[function(e,t,n){var r=e("./_global").parseInt,o=e("./_string-trim").trim,i=e("./_string-ws"),s=/^[-+]?0[xX]/;t.exports=8!==r(i+"08")||22!==r(i+"0x16")?function(e,t){var n=o(String(e),3);return r(n,t>>>0||(s.test(n)?16:10))}:r},{"./_global":29,"./_string-trim":82,"./_string-ws":83}],67:[function(e,t,n){t.exports=function(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}}},{}],68:[function(e,t,n){var r=e("./_an-object"),o=e("./_is-object"),i=e("./_new-promise-capability");t.exports=function(e,t){if(r(e),o(t)&&t.constructor===e)return t;var n=i.f(e);return(0,n.resolve)(t),n.promise}},{"./_an-object":5,"./_is-object":39,"./_new-promise-capability":52}],69:[function(e,t,n){t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},{}],70:[function(e,t,n){var r=e("./_redefine");t.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},{"./_redefine":71}],71:[function(e,t,n){var r=e("./_global"),o=e("./_hide"),i=e("./_has"),s=e("./_uid")("src"),a=e("./_function-to-string"),l="toString",c=(""+a).split(l);e("./_core").inspectSource=function(e){return a.call(e)},(t.exports=function(e,t,n,a){var l="function"==typeof n;l&&(i(n,"name")||o(n,"name",t)),e[t]!==n&&(l&&(i(n,s)||o(n,s,e[t]?""+e[t]:c.join(String(t)))),e===r?e[t]=n:a?e[t]?e[t]=n:o(e,t,n):(delete e[t],o(e,t,n)))})(Function.prototype,l,(function(){return"function"==typeof this&&this[s]||a.call(this)}))},{"./_core":14,"./_function-to-string":28,"./_global":29,"./_has":30,"./_hide":31,"./_uid":95}],72:[function(e,t,n){"use strict";var r=e("./_classof"),o=RegExp.prototype.exec;t.exports=function(e,t){var n=e.exec;if("function"==typeof n){var i=n.call(e,t);if("object"!=typeof i)throw new TypeError("RegExp exec method returned something other than an Object or null");return i}if("RegExp"!==r(e))throw new TypeError("RegExp#exec called on incompatible receiver");return o.call(e,t)}},{"./_classof":12}],73:[function(e,t,n){"use strict";var r,o,i=e("./_flags"),s=RegExp.prototype.exec,a=String.prototype.replace,l=s,c="lastIndex",u=(r=/a/,o=/b*/g,s.call(r,"a"),s.call(o,"a"),0!==r[c]||0!==o[c]),d=void 0!==/()??/.exec("")[1];(u||d)&&(l=function(e){var t,n,r,o,l=this;return d&&(n=new RegExp("^"+l.source+"$(?!\\s)",i.call(l))),u&&(t=l[c]),r=s.call(l,e),u&&r&&(l[c]=l.global?r.index+r[0].length:t),d&&r&&1<r.length&&a.call(r[0],n,(function(){for(o=1;o<arguments.length-2;o++)void 0===arguments[o]&&(r[o]=void 0)})),r}),t.exports=l},{"./_flags":26}],74:[function(e,t,n){function r(e,t){if(i(e),!o(t)&&null!==t)throw TypeError(t+": can't set as prototype!")}var o=e("./_is-object"),i=e("./_an-object");t.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(t,n,o){try{(o=e("./_ctx")(Function.call,e("./_object-gopd").f(Object.prototype,"__proto__").set,2))(t,[]),n=!(t instanceof Array)}catch(t){n=!0}return function(e,t){return r(e,t),n?e.__proto__=t:o(e,t),e}}({},!1):void 0),check:r}},{"./_an-object":5,"./_ctx":16,"./_is-object":39,"./_object-gopd":56}],75:[function(e,t,n){"use strict";var r=e("./_global"),o=e("./_object-dp"),i=e("./_descriptors"),s=e("./_wks")("species");t.exports=function(e){var t=r[e];i&&t&&!t[s]&&o.f(t,s,{configurable:!0,get:function(){return this}})}},{"./_descriptors":18,"./_global":29,"./_object-dp":54,"./_wks":99}],76:[function(e,t,n){var r=e("./_object-dp").f,o=e("./_has"),i=e("./_wks")("toStringTag");t.exports=function(e,t,n){e&&!o(e=n?e:e.prototype,i)&&r(e,i,{configurable:!0,value:t})}},{"./_has":30,"./_object-dp":54,"./_wks":99}],77:[function(e,t,n){var r=e("./_shared")("keys"),o=e("./_uid");t.exports=function(e){return r[e]||(r[e]=o(e))}},{"./_shared":78,"./_uid":95}],78:[function(e,t,n){var r=e("./_core"),o=e("./_global"),i="__core-js_shared__",s=o[i]||(o[i]={});(t.exports=function(e,t){return s[e]||(s[e]=void 0!==t?t:{})})("versions",[]).push({version:r.version,mode:e("./_library")?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},{"./_core":14,"./_global":29,"./_library":47}],79:[function(e,t,n){var r=e("./_an-object"),o=e("./_a-function"),i=e("./_wks")("species");t.exports=function(e,t){var n,s=r(e).constructor;return void 0===s||null==(n=r(s)[i])?t:o(n)}},{"./_a-function":1,"./_an-object":5,"./_wks":99}],80:[function(e,t,n){var r=e("./_to-integer"),o=e("./_defined");t.exports=function(e){return function(t,n){var i,s,a=String(o(t)),l=r(n),c=a.length;return l<0||c<=l?e?"":void 0:(i=a.charCodeAt(l))<55296||56319<i||l+1===c||(s=a.charCodeAt(l+1))<56320||57343<s?e?a.charAt(l):i:e?a.slice(l,l+2):s-56320+(i-55296<<10)+65536}}},{"./_defined":17,"./_to-integer":87}],81:[function(e,t,n){var r=e("./_is-regexp"),o=e("./_defined");t.exports=function(e,t,n){if(r(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(o(e))}},{"./_defined":17,"./_is-regexp":40}],82:[function(e,t,n){function r(e,t,n){var r={},i=s((function(){return!!a[e]()||"​…"!="​…"[e]()})),l=r[e]=i?t(d):a[e];n&&(r[n]=l),o(o.P+o.F*i,"String",r)}var o=e("./_export"),i=e("./_defined"),s=e("./_fails"),a=e("./_string-ws"),l="["+a+"]",c=RegExp("^"+l+l+"*"),u=RegExp(l+l+"*$"),d=r.trim=function(e,t){return e=String(i(e)),1&t&&(e=e.replace(c,"")),2&t&&(e=e.replace(u,"")),e};t.exports=r},{"./_defined":17,"./_export":22,"./_fails":24,"./_string-ws":83}],83:[function(e,t,n){t.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"},{}],84:[function(e,t,n){function r(){var e=+this;if(b.hasOwnProperty(e)){var t=b[e];delete b[e],t()}}function o(e){r.call(e.data)}var i,s,a,l=e("./_ctx"),c=e("./_invoke"),u=e("./_html"),d=e("./_dom-create"),f=e("./_global"),p=f.process,h=f.setImmediate,m=f.clearImmediate,y=f.MessageChannel,v=f.Dispatch,g=0,b={},_="onreadystatechange";h&&m||(h=function(e){for(var t=[],n=1;n<arguments.length;)t.push(arguments[n++]);return b[++g]=function(){c("function"==typeof e?e:Function(e),t)},i(g),g},m=function(e){delete b[e]},"process"==e("./_cof")(p)?i=function(e){p.nextTick(l(r,e,1))}:v&&v.now?i=function(e){v.now(l(r,e,1))}:y?(a=(s=new y).port2,s.port1.onmessage=o,i=l(a.postMessage,a,1)):f.addEventListener&&"function"==typeof postMessage&&!f.importScripts?(i=function(e){f.postMessage(e+"","*")},f.addEventListener("message",o,!1)):i=_ in d("script")?function(e){u.appendChild(d("script"))[_]=function(){u.removeChild(this),r.call(e)}}:function(e){setTimeout(l(r,e,1),0)}),t.exports={set:h,clear:m}},{"./_cof":13,"./_ctx":16,"./_dom-create":19,"./_global":29,"./_html":32,"./_invoke":35}],85:[function(e,t,n){var r=e("./_to-integer"),o=Math.max,i=Math.min;t.exports=function(e,t){return(e=r(e))<0?o(e+t,0):i(e,t)}},{"./_to-integer":87}],86:[function(e,t,n){var r=e("./_to-integer"),o=e("./_to-length");t.exports=function(e){if(void 0===e)return 0;var t=r(e),n=o(t);if(t!==n)throw RangeError("Wrong length!");return n}},{"./_to-integer":87,"./_to-length":89}],87:[function(e,t,n){var r=Math.ceil,o=Math.floor;t.exports=function(e){return isNaN(e=+e)?0:(0<e?o:r)(e)}},{}],88:[function(e,t,n){var r=e("./_iobject"),o=e("./_defined");t.exports=function(e){return r(o(e))}},{"./_defined":17,"./_iobject":36}],89:[function(e,t,n){var r=e("./_to-integer"),o=Math.min;t.exports=function(e){return 0<e?o(r(e),9007199254740991):0}},{"./_to-integer":87}],90:[function(e,t,n){var r=e("./_defined");t.exports=function(e){return Object(r(e))}},{"./_defined":17}],91:[function(e,t,n){var r=e("./_is-object");t.exports=function(e,t){if(!r(e))return e;var n,o;if(t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;if("function"==typeof(n=e.valueOf)&&!r(o=n.call(e)))return o;if(!t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;throw TypeError("Can't convert object to primitive value")}},{"./_is-object":39}],92:[function(e,t,n){"use strict";if(e("./_descriptors")){var r=e("./_library"),o=e("./_global"),i=e("./_fails"),s=e("./_export"),a=e("./_typed"),l=e("./_typed-buffer"),c=e("./_ctx"),u=e("./_an-instance"),d=e("./_property-desc"),f=e("./_hide"),p=e("./_redefine-all"),h=e("./_to-integer"),m=e("./_to-length"),y=e("./_to-index"),v=e("./_to-absolute-index"),g=e("./_to-primitive"),b=e("./_has"),_=e("./_classof"),w=e("./_is-object"),x=e("./_to-object"),k=e("./_is-array-iter"),j=e("./_object-create"),C=e("./_object-gpo"),D=e("./_object-gopn").f,E=e("./core.get-iterator-method"),S=e("./_uid"),O=e("./_wks"),P=e("./_array-methods"),B=e("./_array-includes"),M=e("./_species-constructor"),T=e("./es6.array.iterator"),A=e("./_iterators"),I=e("./_iter-detect"),K=e("./_set-species"),L=e("./_array-fill"),R=e("./_array-copy-within"),N=e("./_object-dp"),F=e("./_object-gopd"),U=N.f,z=F.f,H=o.RangeError,W=o.TypeError,q=o.Uint8Array,V="ArrayBuffer",G="Shared"+V,Y="BYTES_PER_ELEMENT",X="prototype",$=Array[X],J=l.ArrayBuffer,Q=l.DataView,Z=P(0),ee=P(2),te=P(3),ne=P(4),re=P(5),oe=P(6),ie=B(!0),se=B(!1),ae=T.values,le=T.keys,ce=T.entries,ue=$.lastIndexOf,de=$.reduce,fe=$.reduceRight,pe=$.join,he=$.sort,me=$.slice,ye=$.toString,ve=$.toLocaleString,ge=O("iterator"),be=O("toStringTag"),_e=S("typed_constructor"),we=S("def_constructor"),xe=a.CONSTR,ke=a.TYPED,je=a.VIEW,Ce="Wrong length!",De=P(1,(function(e,t){return Be(M(e,e[we]),t)})),Ee=i((function(){return 1===new q(new Uint16Array([1]).buffer)[0]})),Se=!!q&&!!q[X].set&&i((function(){new q(1).set({})})),Oe=function(e,t){var n=h(e);if(n<0||n%t)throw H("Wrong offset!");return n},Pe=function(e){if(w(e)&&ke in e)return e;throw W(e+" is not a typed array!")},Be=function(e,t){if(!w(e)||!(_e in e))throw W("It is not a typed array constructor!");return new e(t)},Me=function(e,t){return Te(M(e,e[we]),t)},Te=function(e,t){for(var n=0,r=t.length,o=Be(e,r);n<r;)o[n]=t[n++];return o},Ae=function(e,t,n){U(e,t,{get:function(){return this._d[n]}})},Ie=function(e,t,n){var r,o,i,s,a,l,u=x(e),d=arguments.length,f=1<d?t:void 0,p=void 0!==f,h=E(u);if(null!=h&&!k(h)){for(l=h.call(u),i=[],r=0;!(a=l.next()).done;r++)i.push(a.value);u=i}for(p&&2<d&&(f=c(f,n,2)),r=0,o=m(u.length),s=Be(this,o);r<o;r++)s[r]=p?f(u[r],r):u[r];return s},Ke=function(){for(var e=0,t=arguments.length,n=Be(this,t);e<t;)n[e]=arguments[e++];return n},Le=!!q&&i((function(){ve.call(new q(1))})),Re=function(){return ve.apply(Le?me.call(Pe(this)):Pe(this),arguments)},Ne={copyWithin:function(e,t,n){return R.call(Pe(this),e,t,2<arguments.length?n:void 0)},every:function(e,t){return ne(Pe(this),e,1<arguments.length?t:void 0)},fill:function(e){return L.apply(Pe(this),arguments)},filter:function(e,t){return Me(this,ee(Pe(this),e,1<arguments.length?t:void 0))},find:function(e,t){return re(Pe(this),e,1<arguments.length?t:void 0)},findIndex:function(e,t){return oe(Pe(this),e,1<arguments.length?t:void 0)},forEach:function(e,t){Z(Pe(this),e,1<arguments.length?t:void 0)},indexOf:function(e,t){return se(Pe(this),e,1<arguments.length?t:void 0)},includes:function(e,t){return ie(Pe(this),e,1<arguments.length?t:void 0)},join:function(e){return pe.apply(Pe(this),arguments)},lastIndexOf:function(e){return ue.apply(Pe(this),arguments)},map:function(e,t){return De(Pe(this),e,1<arguments.length?t:void 0)},reduce:function(e){return de.apply(Pe(this),arguments)},reduceRight:function(e){return fe.apply(Pe(this),arguments)},reverse:function(){for(var e,t=this,n=Pe(t).length,r=Math.floor(n/2),o=0;o<r;)e=t[o],t[o++]=t[--n],t[n]=e;return t},some:function(e,t){return te(Pe(this),e,1<arguments.length?t:void 0)},sort:function(e){return he.call(Pe(this),e)},subarray:function(e,t){var n=Pe(this),r=n.length,o=v(e,r);return new(M(n,n[we]))(n.buffer,n.byteOffset+o*n.BYTES_PER_ELEMENT,m((void 0===t?r:v(t,r))-o))}},Fe=function(e,t){return Me(this,me.call(Pe(this),e,t))},Ue=function(e,t){Pe(this);var n=Oe(t,1),r=this.length,o=x(e),i=m(o.length),s=0;if(r<i+n)throw H(Ce);for(;s<i;)this[n+s]=o[s++]},ze={entries:function(){return ce.call(Pe(this))},keys:function(){return le.call(Pe(this))},values:function(){return ae.call(Pe(this))}},He=function(e,t){return w(e)&&e[ke]&&"symbol"!=typeof t&&t in e&&String(+t)==String(t)},We=function(e,t){return He(e,t=g(t,!0))?d(2,e[t]):z(e,t)},qe=function(e,t,n){return!(He(e,t=g(t,!0))&&w(n)&&b(n,"value"))||b(n,"get")||b(n,"set")||n.configurable||b(n,"writable")&&!n.writable||b(n,"enumerable")&&!n.enumerable?U(e,t,n):(e[t]=n.value,e)};xe||(F.f=We,N.f=qe),s(s.S+s.F*!xe,"Object",{getOwnPropertyDescriptor:We,defineProperty:qe}),i((function(){ye.call({})}))&&(ye=ve=function(){return pe.call(this)});var Ve=p({},Ne);p(Ve,ze),f(Ve,ge,ze.values),p(Ve,{slice:Fe,set:Ue,constructor:function(){},toString:ye,toLocaleString:Re}),Ae(Ve,"buffer","b"),Ae(Ve,"byteOffset","o"),Ae(Ve,"byteLength","l"),Ae(Ve,"length","e"),U(Ve,be,{get:function(){return this[ke]}}),t.exports=function(e,t,n,l){function c(e,n){U(e,n,{get:function(){return e=n,(r=this._d).v[p](e*t+r.o,Ee);var e,r},set:function(e){return r=n,o=e,i=this._d,l&&(o=(o=Math.round(o))<0?0:255<o?255:255&o),void i.v[h](r*t+i.o,o,Ee);var r,o,i},enumerable:!0})}var d=e+((l=!!l)?"Clamped":"")+"Array",p="get"+e,h="set"+e,v=o[d],g=v||{},b=v&&C(v),x=!v||!a.ABV,k={},E=v&&v[X];x?(v=n((function(e,n,r,o){u(e,v,d,"_d");var i,s,a,l,p=0,h=0;if(w(n)){if(!(n instanceof J||(l=_(n))==V||l==G))return ke in n?Te(v,n):Ie.call(v,n);i=n,h=Oe(r,t);var g=n.byteLength;if(void 0===o){if(g%t)throw H(Ce);if((s=g-h)<0)throw H(Ce)}else if(g<(s=m(o)*t)+h)throw H(Ce);a=s/t}else a=y(n),i=new J(s=a*t);for(f(e,"_d",{b:i,o:h,l:s,e:a,v:new Q(i)});p<a;)c(e,p++)})),E=v[X]=j(Ve),f(E,"constructor",v)):i((function(){v(1)}))&&i((function(){new v(-1)}))&&I((function(e){new v,new v(null),new v(1.5),new v(e)}),!0)||(v=n((function(e,n,r,o){var i;return u(e,v,d),w(n)?n instanceof J||(i=_(n))==V||i==G?void 0!==o?new g(n,Oe(r,t),o):void 0!==r?new g(n,Oe(r,t)):new g(n):ke in n?Te(v,n):Ie.call(v,n):new g(y(n))})),Z(b!==Function.prototype?D(g).concat(D(b)):D(g),(function(e){e in v||f(v,e,g[e])})),v[X]=E,r||(E.constructor=v));var S=E[ge],O=!!S&&("values"==S.name||null==S.name),P=ze.values;f(v,_e,!0),f(E,ke,d),f(E,je,!0),f(E,we,v),(l?new v(1)[be]==d:be in E)||U(E,be,{get:function(){return d}}),k[d]=v,s(s.G+s.W+s.F*(v!=g),k),s(s.S,d,{BYTES_PER_ELEMENT:t}),s(s.S+s.F*i((function(){g.of.call(v,1)})),d,{from:Ie,of:Ke}),Y in E||f(E,Y,t),s(s.P,d,Ne),K(d),s(s.P+s.F*Se,d,{set:Ue}),s(s.P+s.F*!O,d,ze),r||E.toString==ye||(E.toString=ye),s(s.P+s.F*i((function(){new v(1).slice()})),d,{slice:Fe}),s(s.P+s.F*(i((function(){return[1,2].toLocaleString()!=new v([1,2]).toLocaleString()}))||!i((function(){E.toLocaleString.call([1,2])}))),d,{toLocaleString:Re}),A[d]=O?S:P,r||O||f(E,ge,P)}}else t.exports=function(){}},{"./_an-instance":4,"./_array-copy-within":6,"./_array-fill":7,"./_array-includes":8,"./_array-methods":9,"./_classof":12,"./_ctx":16,"./_descriptors":18,"./_export":22,"./_fails":24,"./_global":29,"./_has":30,"./_hide":31,"./_is-array-iter":37,"./_is-object":39,"./_iter-detect":44,"./_iterators":46,"./_library":47,"./_object-create":53,"./_object-dp":54,"./_object-gopd":56,"./_object-gopn":58,"./_object-gpo":60,"./_property-desc":69,"./_redefine-all":70,"./_set-species":75,"./_species-constructor":79,"./_to-absolute-index":85,"./_to-index":86,"./_to-integer":87,"./_to-length":89,"./_to-object":90,"./_to-primitive":91,"./_typed":94,"./_typed-buffer":93,"./_uid":95,"./_wks":99,"./core.get-iterator-method":100,"./es6.array.iterator":103}],93:[function(e,t,n){"use strict";var r=e("./_global"),o=e("./_descriptors"),i=e("./_library"),s=e("./_typed"),a=e("./_hide"),l=e("./_redefine-all"),c=e("./_fails"),u=e("./_an-instance"),d=e("./_to-integer"),f=e("./_to-length"),p=e("./_to-index"),h=e("./_object-gopn").f,m=e("./_object-dp").f,y=e("./_array-fill"),v=e("./_set-to-string-tag"),g="ArrayBuffer",b="DataView",_="prototype",w="Wrong index!",x=r[g],k=r[b],j=r.Math,C=r.RangeError,D=r.Infinity,E=x,S=j.abs,O=j.pow,P=j.floor,B=j.log,M=j.LN2,T="byteLength",A="byteOffset",I=o?"_b":"buffer",K=o?"_l":T,L=o?"_o":A;function R(e,t,n){var r,o,i,s=new Array(n),a=8*n-t-1,l=(1<<a)-1,c=l>>1,u=23===t?O(2,-24)-O(2,-77):0,d=0,f=e<0||0===e&&1/e<0?1:0;for((e=S(e))!=e||e===D?(o=e!=e?1:0,r=l):(r=P(B(e)/M),e*(i=O(2,-r))<1&&(r--,i*=2),2<=(e+=1<=r+c?u/i:u*O(2,1-c))*i&&(r++,i/=2),l<=r+c?(o=0,r=l):1<=r+c?(o=(e*i-1)*O(2,t),r+=c):(o=e*O(2,c-1)*O(2,t),r=0));8<=t;s[d++]=255&o,o/=256,t-=8);for(r=r<<t|o,a+=t;0<a;s[d++]=255&r,r/=256,a-=8);return s[--d]|=128*f,s}function N(e,t,n){var r,o=8*n-t-1,i=(1<<o)-1,s=i>>1,a=o-7,l=n-1,c=e[l--],u=127&c;for(c>>=7;0<a;u=256*u+e[l],l--,a-=8);for(r=u&(1<<-a)-1,u>>=-a,a+=t;0<a;r=256*r+e[l],l--,a-=8);if(0===u)u=1-s;else{if(u===i)return r?NaN:c?-D:D;r+=O(2,t),u-=s}return(c?-1:1)*r*O(2,u-t)}function F(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]}function U(e){return[255&e]}function z(e){return[255&e,e>>8&255]}function H(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]}function W(e){return R(e,52,8)}function q(e){return R(e,23,4)}function V(e,t,n){m(e[_],t,{get:function(){return this[n]}})}function G(e,t,n,r){var o=p(+n);if(o+t>e[K])throw C(w);var i=e[I]._b,s=o+e[L],a=i.slice(s,s+t);return r?a:a.reverse()}function Y(e,t,n,r,o,i){var s=p(+n);if(s+t>e[K])throw C(w);for(var a=e[I]._b,l=s+e[L],c=r(+o),u=0;u<t;u++)a[l+u]=c[i?u:t-u-1]}if(s.ABV){if(!c((function(){x(1)}))||!c((function(){new x(-1)}))||c((function(){return new x,new x(1.5),new x(NaN),x.name!=g}))){for(var X,$=(x=function(e){return u(this,x),new E(p(e))})[_]=E[_],J=h(E),Q=0;J.length>Q;)(X=J[Q++])in x||a(x,X,E[X]);i||($.constructor=x)}var Z=new k(new x(2)),ee=k[_].setInt8;Z.setInt8(0,2147483648),Z.setInt8(1,2147483649),!Z.getInt8(0)&&Z.getInt8(1)||l(k[_],{setInt8:function(e,t){ee.call(this,e,t<<24>>24)},setUint8:function(e,t){ee.call(this,e,t<<24>>24)}},!0)}else x=function(e){u(this,x,g);var t=p(e);this._b=y.call(new Array(t),0),this[K]=t},k=function(e,t,n){u(this,k,b),u(e,x,b);var r=e[K],o=d(t);if(o<0||r<o)throw C("Wrong offset!");if(r<o+(n=void 0===n?r-o:f(n)))throw C("Wrong length!");this[I]=e,this[L]=o,this[K]=n},o&&(V(x,T,"_l"),V(k,"buffer","_b"),V(k,T,"_l"),V(k,A,"_o")),l(k[_],{getInt8:function(e){return G(this,1,e)[0]<<24>>24},getUint8:function(e){return G(this,1,e)[0]},getInt16:function(e,t){var n=G(this,2,e,t);return(n[1]<<8|n[0])<<16>>16},getUint16:function(e,t){var n=G(this,2,e,t);return n[1]<<8|n[0]},getInt32:function(e,t){return F(G(this,4,e,t))},getUint32:function(e,t){return F(G(this,4,e,t))>>>0},getFloat32:function(e,t){return N(G(this,4,e,t),23,4)},getFloat64:function(e,t){return N(G(this,8,e,t),52,8)},setInt8:function(e,t){Y(this,1,e,U,t)},setUint8:function(e,t){Y(this,1,e,U,t)},setInt16:function(e,t,n){Y(this,2,e,z,t,n)},setUint16:function(e,t,n){Y(this,2,e,z,t,n)},setInt32:function(e,t,n){Y(this,4,e,H,t,n)},setUint32:function(e,t,n){Y(this,4,e,H,t,n)},setFloat32:function(e,t,n){Y(this,4,e,q,t,n)},setFloat64:function(e,t,n){Y(this,8,e,W,t,n)}});v(x,g),v(k,b),a(k[_],s.VIEW,!0),n[g]=x,n[b]=k},{"./_an-instance":4,"./_array-fill":7,"./_descriptors":18,"./_fails":24,"./_global":29,"./_hide":31,"./_library":47,"./_object-dp":54,"./_object-gopn":58,"./_redefine-all":70,"./_set-to-string-tag":76,"./_to-index":86,"./_to-integer":87,"./_to-length":89,"./_typed":94}],94:[function(e,t,n){for(var r,o=e("./_global"),i=e("./_hide"),s=e("./_uid"),a=s("typed_array"),l=s("view"),c=!(!o.ArrayBuffer||!o.DataView),u=c,d=0,f="Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array".split(",");d<9;)(r=o[f[d++]])?(i(r.prototype,a,!0),i(r.prototype,l,!0)):u=!1;t.exports={ABV:c,CONSTR:u,TYPED:a,VIEW:l}},{"./_global":29,"./_hide":31,"./_uid":95}],95:[function(e,t,n){var r=0,o=Math.random();t.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++r+o).toString(36))}},{}],96:[function(e,t,n){var r=e("./_global").navigator;t.exports=r&&r.userAgent||""},{"./_global":29}],97:[function(e,t,n){var r=e("./_global"),o=e("./_core"),i=e("./_library"),s=e("./_wks-ext"),a=e("./_object-dp").f;t.exports=function(e){var t=o.Symbol||(o.Symbol=!i&&r.Symbol||{});"_"==e.charAt(0)||e in t||a(t,e,{value:s.f(e)})}},{"./_core":14,"./_global":29,"./_library":47,"./_object-dp":54,"./_wks-ext":98}],98:[function(e,t,n){n.f=e("./_wks")},{"./_wks":99}],99:[function(e,t,n){var r=e("./_shared")("wks"),o=e("./_uid"),i=e("./_global").Symbol,s="function"==typeof i;(t.exports=function(e){return r[e]||(r[e]=s&&i[e]||(s?i:o)("Symbol."+e))}).store=r},{"./_global":29,"./_shared":78,"./_uid":95}],100:[function(e,t,n){var r=e("./_classof"),o=e("./_wks")("iterator"),i=e("./_iterators");t.exports=e("./_core").getIteratorMethod=function(e){if(null!=e)return e[o]||e["@@iterator"]||i[r(e)]}},{"./_classof":12,"./_core":14,"./_iterators":46,"./_wks":99}],101:[function(e,t,n){"use strict";var r=e("./_export"),o=e("./_array-methods")(5),i="find",s=!0;i in[]&&Array(1)[i]((function(){s=!1})),r(r.P+r.F*s,"Array",{find:function(e,t){return o(this,e,1<arguments.length?t:void 0)}}),e("./_add-to-unscopables")(i)},{"./_add-to-unscopables":2,"./_array-methods":9,"./_export":22}],102:[function(e,t,n){"use strict";var r=e("./_ctx"),o=e("./_export"),i=e("./_to-object"),s=e("./_iter-call"),a=e("./_is-array-iter"),l=e("./_to-length"),c=e("./_create-property"),u=e("./core.get-iterator-method");o(o.S+o.F*!e("./_iter-detect")((function(e){Array.from(e)})),"Array",{from:function(e,t,n){var o,d,f,p,h=i(e),m="function"==typeof this?this:Array,y=arguments.length,v=1<y?t:void 0,g=void 0!==v,b=0,_=u(h);if(g&&(v=r(v,2<y?n:void 0,2)),null==_||m==Array&&a(_))for(d=new m(o=l(h.length));b<o;b++)c(d,b,g?v(h[b],b):h[b]);else for(p=_.call(h),d=new m;!(f=p.next()).done;b++)c(d,b,g?s(p,v,[f.value,b],!0):f.value);return d.length=b,d}})},{"./_create-property":15,"./_ctx":16,"./_export":22,"./_is-array-iter":37,"./_iter-call":41,"./_iter-detect":44,"./_to-length":89,"./_to-object":90,"./core.get-iterator-method":100}],103:[function(e,t,n){"use strict";var r=e("./_add-to-unscopables"),o=e("./_iter-step"),i=e("./_iterators"),s=e("./_to-iobject");t.exports=e("./_iter-define")(Array,"Array",(function(e,t){this._t=s(e),this._i=0,this._k=t}),(function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,o(1)):o(0,"keys"==t?n:"values"==t?e[n]:[n,e[n]])}),"values"),i.Arguments=i.Array,r("keys"),r("values"),r("entries")},{"./_add-to-unscopables":2,"./_iter-define":43,"./_iter-step":45,"./_iterators":46,"./_to-iobject":88}],104:[function(e,t,n){var r=e("./_object-dp").f,o=Function.prototype,i=/^\s*function ([^ (]*)/;"name"in o||e("./_descriptors")&&r(o,"name",{configurable:!0,get:function(){try{return(""+this).match(i)[1]}catch(e){return""}}})},{"./_descriptors":18,"./_object-dp":54}],105:[function(e,t,n){var r=e("./_export");r(r.S,"Math",{clz32:function(e){return(e>>>=0)?31-Math.floor(Math.log(e+.5)*Math.LOG2E):32}})},{"./_export":22}],106:[function(e,t,n){var r=e("./_export");r(r.S,"Math",{fround:e("./_math-fround")})},{"./_export":22,"./_math-fround":48}],107:[function(e,t,n){var r=e("./_export"),o=Math.imul;r(r.S+r.F*e("./_fails")((function(){return-5!=o(4294967295,5)||2!=o.length})),"Math",{imul:function(e,t){var n=65535,r=+e,o=+t,i=n&r,s=n&o;return 0|i*s+((n&r>>>16)*s+i*(n&o>>>16)<<16>>>0)}})},{"./_export":22,"./_fails":24}],108:[function(e,t,n){var r=e("./_export");r(r.S,"Math",{trunc:function(e){return(0<e?Math.floor:Math.ceil)(e)}})},{"./_export":22}],109:[function(e,t,n){"use strict";function r(e){var t=l(e,!1);if("string"==typeof t&&2<t.length){var n,r,o,i=(t=b?t.trim():p(t,3)).charCodeAt(0);if(43===i||45===i){if(88===(n=t.charCodeAt(2))||120===n)return NaN}else if(48===i){switch(t.charCodeAt(1)){case 66:case 98:r=2,o=49;break;case 79:case 111:r=8,o=55;break;default:return+t}for(var s,a=t.slice(2),c=0,u=a.length;c<u;c++)if((s=a.charCodeAt(c))<48||o<s)return NaN;return parseInt(a,r)}}return+t}var o=e("./_global"),i=e("./_has"),s=e("./_cof"),a=e("./_inherit-if-required"),l=e("./_to-primitive"),c=e("./_fails"),u=e("./_object-gopn").f,d=e("./_object-gopd").f,f=e("./_object-dp").f,p=e("./_string-trim").trim,h="Number",m=o[h],y=m,v=m.prototype,g=s(e("./_object-create")(v))==h,b="trim"in String.prototype;if(!m(" 0o1")||!m("0b1")||m("+0x1")){m=function(e){var t=arguments.length<1?0:e,n=this;return n instanceof m&&(g?c((function(){v.valueOf.call(n)})):s(n)!=h)?a(new y(r(t)),n,m):r(t)};for(var _,w=e("./_descriptors")?u(y):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),x=0;w.length>x;x++)i(y,_=w[x])&&!i(m,_)&&f(m,_,d(y,_));(m.prototype=v).constructor=m,e("./_redefine")(o,h,m)}},{"./_cof":13,"./_descriptors":18,"./_fails":24,"./_global":29,"./_has":30,"./_inherit-if-required":34,"./_object-create":53,"./_object-dp":54,"./_object-gopd":56,"./_object-gopn":58,"./_redefine":71,"./_string-trim":82,"./_to-primitive":91}],110:[function(e,t,n){var r=e("./_export"),o=e("./_parse-int");r(r.S+r.F*(Number.parseInt!=o),"Number",{parseInt:o})},{"./_export":22,"./_parse-int":66}],111:[function(e,t,n){var r=e("./_to-object"),o=e("./_object-keys");e("./_object-sap")("keys",(function(){return function(e){return o(r(e))}}))},{"./_object-keys":62,"./_object-sap":64,"./_to-object":90}],112:[function(e,t,n){"use strict";var r=e("./_classof"),o={};o[e("./_wks")("toStringTag")]="z",o+""!="[object z]"&&e("./_redefine")(Object.prototype,"toString",(function(){return"[object "+r(this)+"]"}),!0)},{"./_classof":12,"./_redefine":71,"./_wks":99}],113:[function(e,t,n){"use strict";function r(){}function o(e){var t;return!(!y(e)||"function"!=typeof(t=e.then))&&t}function i(e,t){if(!e._n){e._n=!0;var n=e._c;x((function(){for(var r=e._v,i=1==e._s,s=0,a=function(t){var n,s,a,l=i?t.ok:t.fail,c=t.resolve,u=t.reject,d=t.domain;try{l?(i||(2==e._h&&R(e),e._h=1),!0===l?n=r:(d&&d.enter(),n=l(r),d&&(d.exit(),a=!0)),n===t.promise?u(S("Promise-chain cycle")):(s=o(n))?s.call(n,c,u):c(n)):u(r)}catch(t){d&&!a&&d.exit(),u(t)}};n.length>s;)a(n[s++]);e._c=[],e._n=!1,t&&!e._h&&K(e)}))}}function s(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),i(t,!0))}var a,l,c,u,d=e("./_library"),f=e("./_global"),p=e("./_ctx"),h=e("./_classof"),m=e("./_export"),y=e("./_is-object"),v=e("./_a-function"),g=e("./_an-instance"),b=e("./_for-of"),_=e("./_species-constructor"),w=e("./_task").set,x=e("./_microtask")(),k=e("./_new-promise-capability"),j=e("./_perform"),C=e("./_user-agent"),D=e("./_promise-resolve"),E="Promise",S=f.TypeError,O=f.process,P=O&&O.versions,B=P&&P.v8||"",M=f[E],T="process"==h(O),A=l=k.f,I=!!function(){try{var t=M.resolve(1),n=(t.constructor={})[e("./_wks")("species")]=function(e){e(r,r)};return(T||"function"==typeof PromiseRejectionEvent)&&t.then(r)instanceof n&&0!==B.indexOf("6.6")&&-1===C.indexOf("Chrome/66")}catch(t){}}(),K=function(e){w.call(f,(function(){var t,n,r,o=e._v,i=L(e);if(i&&(t=j((function(){T?O.emit("unhandledRejection",o,e):(n=f.onunhandledrejection)?n({promise:e,reason:o}):(r=f.console)&&r.error&&r.error("Unhandled promise rejection",o)})),e._h=T||L(e)?2:1),e._a=void 0,i&&t.e)throw t.v}))},L=function(e){return 1!==e._h&&0===(e._a||e._c).length},R=function(e){w.call(f,(function(){var t;T?O.emit("rejectionHandled",e):(t=f.onrejectionhandled)&&t({promise:e,reason:e._v})}))},N=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw S("Promise can't be resolved itself");(t=o(e))?x((function(){var r={_w:n,_d:!1};try{t.call(e,p(N,r,1),p(s,r,1))}catch(e){s.call(r,e)}})):(n._v=e,n._s=1,i(n,!1))}catch(e){s.call({_w:n,_d:!1},e)}}};I||(M=function(e){g(this,M,E,"_h"),v(e),a.call(this);try{e(p(N,this,1),p(s,this,1))}catch(e){s.call(this,e)}},(a=function(){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=e("./_redefine-all")(M.prototype,{then:function(e,t){var n=A(_(this,M));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=T?O.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&i(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),c=function(){var e=new a;this.promise=e,this.resolve=p(N,e,1),this.reject=p(s,e,1)},k.f=A=function(e){return e===M||e===u?new c:l(e)}),m(m.G+m.W+m.F*!I,{Promise:M}),e("./_set-to-string-tag")(M,E),e("./_set-species")(E),u=e("./_core")[E],m(m.S+m.F*!I,E,{reject:function(e){var t=A(this);return(0,t.reject)(e),t.promise}}),m(m.S+m.F*(d||!I),E,{resolve:function(e){return D(d&&this===u?M:this,e)}}),m(m.S+m.F*!(I&&e("./_iter-detect")((function(e){M.all(e).catch(r)}))),E,{all:function(e){var t=this,n=A(t),r=n.resolve,o=n.reject,i=j((function(){var n=[],i=0,s=1;b(e,!1,(function(e){var a=i++,l=!1;n.push(void 0),s++,t.resolve(e).then((function(e){l||(l=!0,n[a]=e,--s||r(n))}),o)})),--s||r(n)}));return i.e&&o(i.v),n.promise},race:function(e){var t=this,n=A(t),r=n.reject,o=j((function(){b(e,!1,(function(e){t.resolve(e).then(n.resolve,r)}))}));return o.e&&r(o.v),n.promise}})},{"./_a-function":1,"./_an-instance":4,"./_classof":12,"./_core":14,"./_ctx":16,"./_export":22,"./_for-of":27,"./_global":29,"./_is-object":39,"./_iter-detect":44,"./_library":47,"./_microtask":51,"./_new-promise-capability":52,"./_perform":67,"./_promise-resolve":68,"./_redefine-all":70,"./_set-species":75,"./_set-to-string-tag":76,"./_species-constructor":79,"./_task":84,"./_user-agent":96,"./_wks":99}],114:[function(e,t,n){var r=e("./_global"),o=e("./_inherit-if-required"),i=e("./_object-dp").f,s=e("./_object-gopn").f,a=e("./_is-regexp"),l=e("./_flags"),c=r.RegExp,u=c,d=c.prototype,f=/a/g,p=/a/g,h=new c(f)!==f;if(e("./_descriptors")&&(!h||e("./_fails")((function(){return p[e("./_wks")("match")]=!1,c(f)!=f||c(p)==p||"/a/i"!=c(f,"i")})))){function m(e){e in c||i(c,e,{configurable:!0,get:function(){return u[e]},set:function(t){u[e]=t}})}c=function(e,t){var n=this instanceof c,r=a(e),i=void 0===t;return!n&&r&&e.constructor===c&&i?e:o(h?new u(r&&!i?e.source:e,t):u((r=e instanceof c)?e.source:e,r&&i?l.call(e):t),n?this:d,c)};for(var y=s(u),v=0;y.length>v;)m(y[v++]);(d.constructor=c).prototype=d,e("./_redefine")(r,"RegExp",c)}e("./_set-species")("RegExp")},{"./_descriptors":18,"./_fails":24,"./_flags":26,"./_global":29,"./_inherit-if-required":34,"./_is-regexp":40,"./_object-dp":54,"./_object-gopn":58,"./_redefine":71,"./_set-species":75,"./_wks":99}],115:[function(e,t,n){"use strict";var r=e("./_regexp-exec");e("./_export")({target:"RegExp",proto:!0,forced:r!==/./.exec},{exec:r})},{"./_export":22,"./_regexp-exec":73}],116:[function(e,t,n){e("./_descriptors")&&"g"!=/./g.flags&&e("./_object-dp").f(RegExp.prototype,"flags",{configurable:!0,get:e("./_flags")})},{"./_descriptors":18,"./_flags":26,"./_object-dp":54}],117:[function(e,t,n){"use strict";var r=e("./_an-object"),o=e("./_to-object"),i=e("./_to-length"),s=e("./_to-integer"),a=e("./_advance-string-index"),l=e("./_regexp-exec-abstract"),c=Math.max,u=Math.min,d=Math.floor,f=/\$([$&`']|\d\d?|<[^>]*>)/g,p=/\$([$&`']|\d\d?)/g;e("./_fix-re-wks")("replace",2,(function(e,t,n,h){return[function(r,o){var i=e(this),s=null==r?void 0:r[t];return void 0!==s?s.call(r,i,o):n.call(String(i),r,o)},function(e,t){var o=h(n,e,this,t);if(o.done)return o.value;var d=r(e),f=String(this),p="function"==typeof t;p||(t=String(t));var y=d.global;if(y){var v=d.unicode;d.lastIndex=0}for(var g=[];;){var b=l(d,f);if(null===b)break;if(g.push(b),!y)break;""===String(b[0])&&(d.lastIndex=a(f,i(d.lastIndex),v))}for(var _,w="",x=0,k=0;k<g.length;k++){b=g[k];for(var j=String(b[0]),C=c(u(s(b.index),f.length),0),D=[],E=1;E<b.length;E++)D.push(void 0===(_=b[E])?_:String(_));var S=b.groups;if(p){var O=[j].concat(D,C,f);void 0!==S&&O.push(S);var P=String(t.apply(void 0,O))}else P=m(j,f,C,D,S,t);x<=C&&(w+=f.slice(x,C)+P,x=C+j.length)}return w+f.slice(x)}];function m(e,t,r,i,s,a){var l=r+e.length,c=i.length,u=p;return void 0!==s&&(s=o(s),u=f),n.call(a,u,(function(n,o){var a;switch(o.charAt(0)){case"$":return"$";case"&":return e;case"`":return t.slice(0,r);case"'":return t.slice(l);case"<":a=s[o.slice(1,-1)];break;default:var u=+o;if(0==u)return n;if(c<u){var f=d(u/10);return 0===f?n:f<=c?void 0===i[f-1]?o.charAt(1):i[f-1]+o.charAt(1):n}a=i[u-1]}return void 0===a?"":a}))}}))},{"./_advance-string-index":3,"./_an-object":5,"./_fix-re-wks":25,"./_regexp-exec-abstract":72,"./_to-integer":87,"./_to-length":89,"./_to-object":90}],118:[function(e,t,n){"use strict";var r=e("./_is-regexp"),o=e("./_an-object"),i=e("./_species-constructor"),s=e("./_advance-string-index"),a=e("./_to-length"),l=e("./_regexp-exec-abstract"),c=e("./_regexp-exec"),u=e("./_fails"),d=Math.min,f=[].push,p="split",h="length",m="lastIndex",y=4294967295,v=!u((function(){RegExp(y,"y")}));e("./_fix-re-wks")("split",2,(function(e,t,n,u){var g;return g="c"=="abbc"[p](/(b)*/)[1]||4!="test"[p](/(?:)/,-1)[h]||2!="ab"[p](/(?:ab)*/)[h]||4!="."[p](/(.?)(.?)/)[h]||1<"."[p](/()()/)[h]||""[p](/.?/)[h]?function(e,t){var o=String(this);if(void 0===e&&0===t)return[];if(!r(e))return n.call(o,e,t);for(var i,s,a,l=[],u=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),d=0,p=void 0===t?y:t>>>0,v=new RegExp(e.source,u+"g");(i=c.call(v,o))&&!(d<(s=v[m])&&(l.push(o.slice(d,i.index)),1<i[h]&&i.index<o[h]&&f.apply(l,i.slice(1)),a=i[0][h],d=s,l[h]>=p));)v[m]===i.index&&v[m]++;return d===o[h]?!a&&v.test("")||l.push(""):l.push(o.slice(d)),l[h]>p?l.slice(0,p):l}:"0"[p](void 0,0)[h]?function(e,t){return void 0===e&&0===t?[]:n.call(this,e,t)}:n,[function(n,r){var o=e(this),i=null==n?void 0:n[t];return void 0!==i?i.call(n,o,r):g.call(String(o),n,r)},function(e,t){var r=u(g,e,this,t,g!==n);if(r.done)return r.value;var c=o(e),f=String(this),p=i(c,RegExp),h=c.unicode,m=(c.ignoreCase?"i":"")+(c.multiline?"m":"")+(c.unicode?"u":"")+(v?"y":"g"),b=new p(v?c:"^(?:"+c.source+")",m),_=void 0===t?y:t>>>0;if(0==_)return[];if(0===f.length)return null===l(b,f)?[f]:[];for(var w=0,x=0,k=[];x<f.length;){b.lastIndex=v?x:0;var j,C=l(b,v?f:f.slice(x));if(null===C||(j=d(a(b.lastIndex+(v?0:x)),f.length))===w)x=s(f,x,h);else{if(k.push(f.slice(w,x)),k.length===_)return k;for(var D=1;D<=C.length-1;D++)if(k.push(C[D]),k.length===_)return k;x=w=j}}return k.push(f.slice(w)),k}]}))},{"./_advance-string-index":3,"./_an-object":5,"./_fails":24,"./_fix-re-wks":25,"./_is-regexp":40,"./_regexp-exec":73,"./_regexp-exec-abstract":72,"./_species-constructor":79,"./_to-length":89}],119:[function(e,t,n){"use strict";function r(t){e("./_redefine")(RegExp.prototype,a,t,!0)}e("./es6.regexp.flags");var o=e("./_an-object"),i=e("./_flags"),s=e("./_descriptors"),a="toString",l=/./[a];e("./_fails")((function(){return"/a/b"!=l.call({source:"a",flags:"b"})}))?r((function(){var e=o(this);return"/".concat(e.source,"/","flags"in e?e.flags:!s&&e instanceof RegExp?i.call(e):void 0)})):l.name!=a&&r((function(){return l.call(this)}))},{"./_an-object":5,"./_descriptors":18,"./_fails":24,"./_flags":26,"./_redefine":71,"./es6.regexp.flags":116}],120:[function(e,t,n){"use strict";var r=e("./_string-at")(!0);e("./_iter-define")(String,"String",(function(e){this._t=String(e),this._i=0}),(function(){var e,t=this._t,n=this._i;return n>=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})}))},{"./_iter-define":43,"./_string-at":80}],121:[function(e,t,n){"use strict";var r=e("./_export"),o=e("./_to-length"),i=e("./_string-context"),s="startsWith",a=""[s];r(r.P+r.F*e("./_fails-is-regexp")(s),"String",{startsWith:function(e,t){var n=i(this,e,s),r=o(Math.min(1<arguments.length?t:void 0,n.length)),l=String(e);return a?a.call(n,l,r):n.slice(r,r+l.length)===l}})},{"./_export":22,"./_fails-is-regexp":23,"./_string-context":81,"./_to-length":89}],122:[function(e,t,n){"use strict";function r(e){var t=G[e]=P(N[z]);return t._k=e,t}function o(e,t){j(e);for(var n,r=x(t=E(t)),o=0,i=r.length;o<i;)te(e,n=r[o++],t[n]);return e}function i(e){var t=q.call(this,e=S(e,!0));return!(this===X&&u(G,e)&&!u(Y,e))&&(!(t||!u(this,e)||!u(G,e)||u(this,H)&&this[H][e])||t)}function s(e,t){if(e=E(e),t=S(t,!0),e!==X||!u(G,t)||u(Y,t)){var n=K(e,t);return!n||!u(G,t)||u(e,H)&&e[H][t]||(n.enumerable=!0),n}}function a(e){for(var t,n=R(E(e)),r=[],o=0;n.length>o;)u(G,t=n[o++])||t==H||t==h||r.push(t);return r}function l(e){for(var t,n=e===X,r=R(n?Y:E(e)),o=[],i=0;r.length>i;)!u(G,t=r[i++])||n&&!u(X,t)||o.push(G[t]);return o}var c=e("./_global"),u=e("./_has"),d=e("./_descriptors"),f=e("./_export"),p=e("./_redefine"),h=e("./_meta").KEY,m=e("./_fails"),y=e("./_shared"),v=e("./_set-to-string-tag"),g=e("./_uid"),b=e("./_wks"),_=e("./_wks-ext"),w=e("./_wks-define"),x=e("./_enum-keys"),k=e("./_is-array"),j=e("./_an-object"),C=e("./_is-object"),D=e("./_to-object"),E=e("./_to-iobject"),S=e("./_to-primitive"),O=e("./_property-desc"),P=e("./_object-create"),B=e("./_object-gopn-ext"),M=e("./_object-gopd"),T=e("./_object-gops"),A=e("./_object-dp"),I=e("./_object-keys"),K=M.f,L=A.f,R=B.f,N=c.Symbol,F=c.JSON,U=F&&F.stringify,z="prototype",H=b("_hidden"),W=b("toPrimitive"),q={}.propertyIsEnumerable,V=y("symbol-registry"),G=y("symbols"),Y=y("op-symbols"),X=Object[z],$="function"==typeof N&&!!T.f,J=c.QObject,Q=!J||!J[z]||!J[z].findChild,Z=d&&m((function(){return 7!=P(L({},"a",{get:function(){return L(this,"a",{value:7}).a}})).a}))?function(e,t,n){var r=K(X,t);r&&delete X[t],L(e,t,n),r&&e!==X&&L(X,t,r)}:L,ee=$&&"symbol"==typeof N.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof N},te=function(e,t,n){return e===X&&te(Y,t,n),j(e),t=S(t,!0),j(n),u(G,t)?(n.enumerable?(u(e,H)&&e[H][t]&&(e[H][t]=!1),n=P(n,{enumerable:O(0,!1)})):(u(e,H)||L(e,H,O(1,{})),e[H][t]=!0),Z(e,t,n)):L(e,t,n)};$||(p((N=function(e){if(this instanceof N)throw TypeError("Symbol is not a constructor!");var t=g(0<arguments.length?e:void 0),n=function(e){this===X&&n.call(Y,e),u(this,H)&&u(this[H],t)&&(this[H][t]=!1),Z(this,t,O(1,e))};return d&&Q&&Z(X,t,{configurable:!0,set:n}),r(t)})[z],"toString",(function(){return this._k})),M.f=s,A.f=te,e("./_object-gopn").f=B.f=a,e("./_object-pie").f=i,T.f=l,d&&!e("./_library")&&p(X,"propertyIsEnumerable",i,!0),_.f=function(e){return r(b(e))}),f(f.G+f.W+f.F*!$,{Symbol:N});for(var ne="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),re=0;ne.length>re;)b(ne[re++]);for(var oe=I(b.store),ie=0;oe.length>ie;)w(oe[ie++]);f(f.S+f.F*!$,"Symbol",{for:function(e){return u(V,e+="")?V[e]:V[e]=N(e)},keyFor:function(e){if(!ee(e))throw TypeError(e+" is not a symbol!");for(var t in V)if(V[t]===e)return t},useSetter:function(){Q=!0},useSimple:function(){Q=!1}}),f(f.S+f.F*!$,"Object",{create:function(e,t){return void 0===t?P(e):o(P(e),t)},defineProperty:te,defineProperties:o,getOwnPropertyDescriptor:s,getOwnPropertyNames:a,getOwnPropertySymbols:l});var se=m((function(){T.f(1)}));f(f.S+f.F*se,"Object",{getOwnPropertySymbols:function(e){return T.f(D(e))}}),F&&f(f.S+f.F*(!$||m((function(){var e=N();return"[null]"!=U([e])||"{}"!=U({a:e})||"{}"!=U(Object(e))}))),"JSON",{stringify:function(e){for(var t,n,r=[e],o=1;o<arguments.length;)r.push(arguments[o++]);if(n=t=r[1],(C(t)||void 0!==e)&&!ee(e))return k(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!ee(t))return t}),r[1]=t,U.apply(F,r)}}),N[z][W]||e("./_hide")(N[z],W,N[z].valueOf),v(N,"Symbol"),v(Math,"Math",!0),v(c.JSON,"JSON",!0)},{"./_an-object":5,"./_descriptors":18,"./_enum-keys":21,"./_export":22,"./_fails":24,"./_global":29,"./_has":30,"./_hide":31,"./_is-array":38,"./_is-object":39,"./_library":47,"./_meta":50,"./_object-create":53,"./_object-dp":54,"./_object-gopd":56,"./_object-gopn":58,"./_object-gopn-ext":57,"./_object-gops":59,"./_object-keys":62,"./_object-pie":63,"./_property-desc":69,"./_redefine":71,"./_set-to-string-tag":76,"./_shared":78,"./_to-iobject":88,"./_to-object":90,"./_to-primitive":91,"./_uid":95,"./_wks":99,"./_wks-define":97,"./_wks-ext":98}],123:[function(e,t,n){e("./_typed-array")("Uint8",1,(function(e){return function(t,n,r){return e(this,t,n,r)}}))},{"./_typed-array":92}],124:[function(e,t,n){e("./_typed-array")("Uint8",1,(function(e){return function(t,n,r){return e(this,t,n,r)}}),!0)},{"./_typed-array":92}],125:[function(e,t,n){var r=e("./_export"),o=e("./_own-keys"),i=e("./_to-iobject"),s=e("./_object-gopd"),a=e("./_create-property");r(r.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n,r=i(e),l=s.f,c=o(r),u={},d=0;c.length>d;)void 0!==(n=l(r,t=c[d++]))&&a(u,t,n);return u}})},{"./_create-property":15,"./_export":22,"./_object-gopd":56,"./_own-keys":65,"./_to-iobject":88}],126:[function(e,t,n){e("./_wks-define")("asyncIterator")},{"./_wks-define":97}],127:[function(e,t,n){for(var r=e("./es6.array.iterator"),o=e("./_object-keys"),i=e("./_redefine"),s=e("./_global"),a=e("./_hide"),l=e("./_iterators"),c=e("./_wks"),u=c("iterator"),d=c("toStringTag"),f=l.Array,p={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},h=o(p),m=0;m<h.length;m++){var y,v=h[m],g=p[v],b=s[v],_=b&&b.prototype;if(_&&(_[u]||a(_,u,f),_[d]||a(_,d,v),l[v]=f,g))for(y in r)_[y]||i(_,y,r[y],!0)}},{"./_global":29,"./_hide":31,"./_iterators":46,"./_object-keys":62,"./_redefine":71,"./_wks":99,"./es6.array.iterator":103}],128:[function(e,t,n){var r=function(e){"use strict";var t,n=Object.prototype,r=n.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",s=o.asyncIterator||"@@asyncIterator",a=o.toStringTag||"@@toStringTag";function l(e,t,n,r){var o,i,s,a,l=t&&t.prototype instanceof m?t:m,y=Object.create(l.prototype),v=new E(r||[]);return y._invoke=(o=e,i=n,s=v,a=u,function(e,t){if(a===f)throw new Error("Generator is already running");if(a===p){if("throw"===e)throw t;return O()}for(s.method=e,s.arg=t;;){var n=s.delegate;if(n){var r=j(n,s);if(r){if(r===h)continue;return r}}if("next"===s.method)s.sent=s._sent=s.arg;else if("throw"===s.method){if(a===u)throw a=p,s.arg;s.dispatchException(s.arg)}else"return"===s.method&&s.abrupt("return",s.arg);a=f;var l=c(o,i,s);if("normal"===l.type){if(a=s.done?p:d,l.arg===h)continue;return{value:l.arg,done:s.done}}"throw"===l.type&&(a=p,s.method="throw",s.arg=l.arg)}}),y}function c(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=l;var u="suspendedStart",d="suspendedYield",f="executing",p="completed",h={};function m(){}function y(){}function v(){}var g={};g[i]=function(){return this};var b=Object.getPrototypeOf,_=b&&b(b(S([])));_&&_!==n&&r.call(_,i)&&(g=_);var w=v.prototype=m.prototype=Object.create(g);function x(e){["next","throw","return"].forEach((function(t){e[t]=function(e){return this._invoke(t,e)}}))}function k(e,t){var n;this._invoke=function(o,i){function s(){return new t((function(n,s){!function n(o,i,s,a){var l=c(e[o],e,i);if("throw"!==l.type){var u=l.arg,d=u.value;return d&&"object"==typeof d&&r.call(d,"__await")?t.resolve(d.__await).then((function(e){n("next",e,s,a)}),(function(e){n("throw",e,s,a)})):t.resolve(d).then((function(e){u.value=e,s(u)}),(function(e){return n("throw",e,s,a)}))}a(l.arg)}(o,i,n,s)}))}return n=n?n.then(s,s):s()}}function j(e,n){var r=e.iterator[n.method];if(r===t){if(n.delegate=null,"throw"===n.method){if(e.iterator.return&&(n.method="return",n.arg=t,j(e,n),"throw"===n.method))return h;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return h}var o=c(r,e.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,h;var i=o.arg;return i?i.done?(n[e.resultName]=i.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,h):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,h)}function C(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function D(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function S(e){if(e){var n=e[i];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,s=function n(){for(;++o<e.length;)if(r.call(e,o))return n.value=e[o],n.done=!1,n;return n.value=t,n.done=!0,n};return s.next=s}}return{next:O}}function O(){return{value:t,done:!0}}return y.prototype=w.constructor=v,v.constructor=y,v[a]=y.displayName="GeneratorFunction",e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,v):(e.__proto__=v,a in e||(e[a]="GeneratorFunction")),e.prototype=Object.create(w),e},e.awrap=function(e){return{__await:e}},x(k.prototype),k.prototype[s]=function(){return this},e.AsyncIterator=k,e.async=function(t,n,r,o,i){void 0===i&&(i=Promise);var s=new k(l(t,n,r,o),i);return e.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},x(w),w[a]="Generator",w[i]=function(){return this},w.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=S,E.prototype={constructor:E,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(D),!e)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function o(r,o){return a.type="throw",a.arg=e,n.next=r,o&&(n.method="next",n.arg=t),!!o}for(var i=this.tryEntries.length-1;0<=i;--i){var s=this.tryEntries[i],a=s.completion;if("root"===s.tryLoc)return o("end");if(s.tryLoc<=this.prev){var l=r.call(s,"catchLoc"),c=r.call(s,"finallyLoc");if(l&&c){if(this.prev<s.catchLoc)return o(s.catchLoc,!0);if(this.prev<s.finallyLoc)return o(s.finallyLoc)}else if(l){if(this.prev<s.catchLoc)return o(s.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return o(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;0<=n;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var s=i?i.completion:{};return s.type=e,s.arg=t,i?(this.method="next",this.next=i.finallyLoc,h):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),h},finish:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),D(n),h}},catch:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;D(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:S(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),h}},e}("object"==typeof t?t.exports:{});try{regeneratorRuntime=r}catch(e){Function("r","regeneratorRuntime = r")(r)}},{}],129:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.Build={version:"0.72.5 (4f5e68056e94c6b9f9c2083171420d98)",buildSeed:1645157979103,"wdosbox.wasm":{size:1475852,gzSize:499076},"wdosbox.js":{size:125335,gzSize:32399},"wlibzip.wasm":{size:112624,gzSize:54379},"wlibzip.js":{size:78794,gzSize:20391}}},{}],130:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function i(e,t,n){return t&&o(e.prototype,t),n&&o(e,n),e}e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var s=function(){function e(){r(this,e)}return i(e,[{key:"close",value:function(){}},{key:"put",value:function(){return Promise.resolve()}},{key:"get",value:function(e,t){return void 0!==t?Promise.resolve(t):Promise.reject("Cache is not supported on this host")}},{key:"forEach",value:function(e,t){t()}}]),e}();n.CacheNoop=s,n.CacheDb=function(e,t){return new Promise((function(n){new a(e,n,(function(e){t.onErr(e),n(new s)}))}))};var a=function(){function e(t,n,o){var i=this;if(r(this,e),this.storeName="files",this.db=null,this.version=t,this.indexedDB="undefined"==typeof window?void 0:window.indexedDB||window.mozIndexedDB||window.webkitIndexedDB||window.msIndexedDB,this.indexedDB){var s=this.indexedDB.open("js-dos-cache ("+t+")",1);s.onerror=function(e){var t;o("Can't open cache database: "+(null===(t=s.error)||void 0===t?void 0:t.message))},s.onsuccess=function(e){i.db=s.result,n(i)},s.onupgradeneeded=function(e){try{i.db=s.result,i.db.onerror=function(e){o("Can't upgrade cache database")},i.db.createObjectStore(i.storeName)}catch(e){o("Can't upgrade cache database")}}}else o("Indexed db is not supported on this host")}return i(e,[{key:"close",value:function(){null!==this.db&&(this.db.close(),this.db=null)}},{key:"put",value:function(e,t){var n=this;return new Promise((function(r){if(null!==n.db){var o=n.db.transaction(n.storeName,"readwrite");o.oncomplete=function(){return r()},o.objectStore(n.storeName).put(t,e)}else r()}))}},{key:"get",value:function(e,t){var n=this;return new Promise((function(r,o){function i(e){void 0===t?o(new Error(e)):r(t)}if(null!==n.db){var s=n.db.transaction(n.storeName,"readonly").objectStore(n.storeName).get(e);s.onerror=function(){return o(new Error("Can't read value for key '"+e+"'"))},s.onsuccess=function(){s.result?r(s.result):i("Result is empty for key '"+e+"', result: "+s.result)}}else i("db is not initalized")}))}},{key:"forEach",value:function(e,t){if(null!==this.db){var n=this.db.transaction(this.storeName,"readonly").objectStore(this.storeName).openCursor();n.onerror=function(){return t()},n.onsuccess=function(n){var r=n.target.result;r?(e(r.key.toString(),r.value),r.continue()):t()}}else t()}}]),e}()},{"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119}],131:[function(e,t,n){"use strict";function r(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=s(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,o,i=!0,a=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return i=e.done,e},e:function(e){a=!0,o=e},f:function(){try{i||null==r.return||r.return()}finally{if(a)throw o}}}}function o(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function i(e){return function(e){if(Array.isArray(e))return a(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||s(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function l(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.array.from"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.typed.uint8-array"),e("core-js/modules/es6.promise"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es6.array.iterator"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.string.iterator"),e("regenerator-runtime/runtime");Object.defineProperty(n,"__esModule",{value:!0});var c=e("./dos-conf"),u=function(e){return e&&e.__esModule?e:{default:e}}(e("../../libzip/libzip")),d=e("../../http"),f=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.config=c.createDosConfig(),this.sources=[],this.libzipWasm=t,this.cache=n}var t,n,s,a;return t=e,(n=[{key:"autoexec",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.config.autoexec.options.script.value=t.join("\n"),this}},{key:"cycles",value:function(e){return this.config.cpu.options.cycles.value=e,this}},{key:"extract",value:function(e,t,n){var r=1<arguments.length&&void 0!==t?t:"/",o=2<arguments.length&&void 0!==n?n:"zip";return this.extractAll([{url:e,path:r,type:o}])}},{key:"extractAll",value:function(e){var t;return(t=this.sources).push.apply(t,i(e)),this}},{key:"toUint8Array",value:(s=regeneratorRuntime.mark((function e(){var t,n,o,i,s,a,l,f,h,m,y,v,g,b=this,_=arguments;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=0<_.length&&void 0!==_[0]&&_[0],n={},e.next=4,this.libzipWasm.instantiate(n);case 4:return o=new u.default(n,"/home/web_user"),e.next=7,c.toDosboxConf(this.config);case 7:i=e.sent,s=[],a=r(this.sources);try{for(f=function(){var e=l.value;if("zip"!==e.type)throw new Error("Only Zip is supported");var t=d.HTTPRequest(e.url,{cache:b.cache,responseType:"arraybuffer"}).then((function(t){return{source:e,data:new Uint8Array(t)}}));s.push(t)},a.s();!(l=a.n()).done;)f()}catch(e){a.e(e)}finally{a.f()}if(t){e.next=18;break}return e.next=14,o.writeFile(".jsdos/dosbox.conf",i);case 14:return e.next=16,o.writeFile(".jsdos/readme.txt",p);case 16:return e.next=18,o.writeFile(".jsdos/jsdos.json",JSON.stringify(this.config,null,2));case 18:return e.next=20,Promise.all(s);case 20:h=e.sent,m=r(h);try{for(m.s();!(y=m.n()).done;)v=y.value,o.zipToFs(v.data,v.source.path)}catch(e){m.e(e)}finally{m.f()}if(t)return e.next=26,o.writeFile(".jsdos/dosbox.conf",i);e.next=30;break;case 26:return e.next=28,o.writeFile(".jsdos/readme.txt",p);case 28:return e.next=30,o.writeFile(".jsdos/jsdos.json",JSON.stringify(this.config,null,2));case 30:return e.next=32,o.zipFromFs();case 32:return g=e.sent,o.destroy(),e.abrupt("return",g);case 35:case"end":return e.stop()}}),e,this)})),a=function(){var e=this,t=arguments;return new Promise((function(n,r){var i=s.apply(e,t);function a(e){o(i,n,r,a,l,"next",e)}function l(e){o(i,n,r,a,l,"throw",e)}a(void 0)}))},function(){return a.apply(this,arguments)})}])&&l(t.prototype,n),e}();n.default=f;var p="\nPlease visit our website:\n\n _ __\n (_)____ ____/ /___ _____ _________ ____ ___\n / / ___/_____/ __ / __ \\/ ___// ___/ __ \\/ __ `__ \\\n / (__ )_____/ /_/ / /_/ (__ )/ /__/ /_/ / / / / / /\n __/ /____/ \\__,_/\\____/____(_)___/\\____/_/ /_/ /_/\n /___/\n"},{"../../http":136,"../../libzip/libzip":141,"./dos-conf":132,"core-js/modules/es6.array.from":102,"core-js/modules/es6.array.iterator":103,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.symbol":122,"core-js/modules/es6.typed.uint8-array":123,"core-js/modules/es7.symbol.async-iterator":126,"core-js/modules/web.dom.iterable":127,"regenerator-runtime/runtime":128}],132:[function(e,t,n){"use strict";function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){i(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function l(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){a(i,r,o,s,l,"next",e)}function l(e){a(i,r,o,s,l,"throw",e)}s(void 0)}))}}function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}e("core-js/modules/es7.object.get-own-property-descriptors"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.regexp.to-string"),e("regenerator-runtime/runtime"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.number.constructor"),e("core-js/modules/es6.number.parse-int"),e("core-js/modules/es6.string.starts-with"),e("core-js/modules/es6.array.find"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es6.array.iterator"),e("core-js/modules/es6.object.keys"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.function.name"),Object.defineProperty(n,"__esModule",{value:!0});var d=function e(){u(this,e),this.name="sdl",this.description="This section contains all of the low level system settings for how DOSBox interacts with your real hardware. You can define what resolutions are emulated, how DOSBox should treat errors or listen to your keyboard and mouse. You can often achieve a fair level of optimization by working with these setting, though for the most part leaving them at their default settings will create the best experience. These settings are passed on to the SDL Library which handles low level things like input and thread priority.",this.options={autolock:{name:"autolock",description:"Mouse will automatically lock, if you click on the screen.",value:!1,allowedValues:[!0,!1]}}};n.OutputCategory=d;var f=function e(){u(this,e),this.name="dosbox",this.description="The [dosbox] section contains various settings that do not pertain to any other section (e.g. setting the language used in DOSBox help texts, where to store screen captures, etc.)",this.options={machine:{name:"machine",description:"The type of machine tries to emulate.",value:"svga_s3",allowedValues:["hercules","cga","tandy","pcjr","ega","vgaonly","svga_s3","svga_et3000","svga_et4000","svga_paradise","vesa_nolfb","vesa_oldvbe"]}}};n.DosboxCategory=f;var p=function e(){u(this,e),this.name="cpu",this.description="The CPU section controls how DOSBox tries to emulate the CPU, how fast the emulation should be, and to adjust it. DOSBox offers 4 different methods of CPU emulation.",this.options={core:{name:"core",description:"CPU Core used in emulation. auto will switch to dynamic if available and appropriate.",value:"auto",allowedValues:["auto","normal","simple"]},cputype:{name:"cputype",description:"CPU Type used in emulation. auto is the fastest choice.",value:"auto",allowedValues:["auto","386","386_slow","486_slow","pentium_slow","386_prefetch"]},cycles:{name:"cycles",description:"Amount of instructions DOSBox tries to emulate each millisecond. Setting this value too high results in sound dropouts and lags.\nCycles can be set in 3 ways:\n'auto' tries to guess what a game needs.\n It usually works, but can fail for certain games.\n'fixed #number' will set a fixed amount of cycles. This is what you usually need if 'auto' fails.\n (Example: fixed 4000).\n'max' will allocate as much cycles as your computer is able to handle.\n",value:"auto",allowedValues:["auto","fixed","max"]}}};n.CpuCategory=p;var h=function e(){u(this,e),this.name="mixer",this.description="Here you can define the quality of emulated audio.",this.options={rate:{name:"rate",description:"Frequency rate of sound",value:44100,allowedValues:[]},nosound:{name:"nosound",description:"Enable silent mode, sound is still emulated though.",value:!1,allowedValues:[!0,!1]}}};n.MixerCategory=h;var m=function e(){u(this,e),this.name="autoexec",this.description="Lines in this section will be run at startup",this.options={script:{name:"lines",description:"Use \\n to separate lines",value:"",allowedValues:[]}}};function y(){return{output:new d,dosbox:new f,cpu:new p,mixer:new h,autoexec:new m}}function v(e,t){var n="sdl"===t.name?"output":t.name;return new Promise((function(r,o){if(e)if(e.name===t.name){for(var i=0,s=Object.keys(e.options);i<s.length;i++){var a=s[i],l=e.options[a],u=t.options[a];if(void 0===u)return void o(new Error("Unknown option '"+(l.name||a)+"' in '"+e.name+"'"));if(0<u.allowedValues.length){var d=function(){var t=l.value,r=u.allowedValues.find((function(e){return e===t}));if("cpu"===n&&"cycles"===l.name&&(t+"").startsWith("fixed ")){var i=Number.parseInt(t.substr("fixed ".length),10);if(isNaN(i))return o(new Error("Fixed value should conatain number")),{v:void 0}}else if(void 0===r)return o(new Error("Incorrect value '"+t+"' ("+c(t)+") for '"+e.name+"."+(l.name||a)+"' allowed is "+JSON.stringify(u.allowedValues))),{v:void 0}}();if("object"===c(d))return d.v}}for(var f=0,p=Object.keys(t.options);f<p.length;f++){var h=p[f];if(!(h in e.options))return void o(new Error("Option '"+h+"' is missed in '"+n+"'"))}r()}else o(new Error("Incorrect category name '"+e.name+"' should be '"+t.name+"'"));else o(new Error("Category '"+n+"' is missed"))}))}function g(){return b.apply(this,arguments)}function b(){return(b=l(regeneratorRuntime.mark((function e(t){var n,r,o,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=y(),r=0,o=Object.keys(n);case 2:if(r<o.length)return i=o[r],e.next=6,v(t[i],n[i]);e.next=9;break;case 6:r++,e.next=2;break;case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function _(){return w.apply(this,arguments)}function w(){return(w=l(regeneratorRuntime.mark((function e(t,n){var r,i,s,a,l,c;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(void 0===t)return e.abrupt("return");e.next=2;break;case 2:r=0,i=Object.keys(t.options||{});case 3:if(!(r<i.length)){e.next=16;break}if(s=i[r],"string"!=typeof(a=t.options[s])&&"number"!=typeof a&&!Array.isArray(a)){e.next=13;break}if(l=n.options[s]){e.next=10;break}return e.abrupt("continue",13);case 10:c=a,t.options[s]=o({},l),t.options[s].value=c;case 13:r++,e.next=3;break;case 16:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function x(){return k.apply(this,arguments)}function k(){return(k=l(regeneratorRuntime.mark((function e(t){var n,r,o,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=y(),r=0,o=Object.keys(n);case 2:if(r<o.length)return i=o[r],e.next=6,_(t[i],n[i]);e.next=9;break;case 6:r++,e.next=2;break;case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function j(){return(j=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,x(t);case 2:return e.next=4,g(t);case 4:return n=C(t.output)+"\nfullscreen=false\nfulldouble=false\nfullresolution=original\nwindowresolution=original\noutput=surface\nsensitivity=100\nwaitonerror=true\npriority=higher,normal\nmapperfile=mapper-jsdos.map\nusescancodes=true\nvsync=false\n"+C(t.dosbox)+"\nlanguage=\ncaptures=capture\nmemsize=16\n"+C(t.cpu)+"\ncycleup=10\ncycledown=20\n"+C(t.mixer)+"\nblocksize=1024\nprebuffer=20\n\n[render]\n# frameskip: How many frames DOSBox skips before drawing one.\n# aspect: Do aspect correction, if your output method doesn't support scaling this can slow things down!.\n# scaler: Scaler used to enlarge/enhance low resolution modes.\n# If 'forced' is appended, then the scaler will be used even if the result might not be desired.\n# Possible values: none, normal2x, normal3x, advmame2x, advmame3x, advinterp2x, advinterp3x, hq2x, hq3x, 2xsai, super2xsai, supereagle, tv2x, tv3x, rgb2x, rgb3x, scan2x, scan3x.\n\nframeskip=0\naspect=false\nscaler=none\n\n[midi]\n# mpu401: Type of MPU-401 to emulate.\n# Possible values: intelligent, uart, none.\n# mididevice: Device that will receive the MIDI data from MPU-401.\n# Possible values: default, win32, alsa, oss, coreaudio, coremidi, none.\n# midiconfig: Special configuration options for the device driver. This is usually the id of the device you want to use.\n# See the README/Manual for more details.\n\nmpu401=intelligent\nmididevice=default\nmidiconfig=\n\n[sblaster]\n# sbtype: Type of Soundblaster to emulate. gb is Gameblaster.\n# Possible values: sb1, sb2, sbpro1, sbpro2, sb16, gb, none.\n# sbbase: The IO address of the soundblaster.\n# Possible values: 220, 240, 260, 280, 2a0, 2c0, 2e0, 300.\n# irq: The IRQ number of the soundblaster.\n# Possible values: 7, 5, 3, 9, 10, 11, 12.\n# dma: The DMA number of the soundblaster.\n# Possible values: 1, 5, 0, 3, 6, 7.\n# hdma: The High DMA number of the soundblaster.\n# Possible values: 1, 5, 0, 3, 6, 7.\n# sbmixer: Allow the soundblaster mixer to modify the DOSBox mixer.\n# oplmode: Type of OPL emulation. On 'auto' the mode is determined by sblaster type. All OPL modes are Adlib-compatible, except for 'cms'.\n# Possible values: auto, cms, opl2, dualopl2, opl3, none.\n# oplemu: Provider for the OPL emulation. compat might provide better quality (see oplrate as well).\n# Possible values: default, compat, fast.\n# oplrate: Sample rate of OPL music emulation. Use 49716 for highest quality (set the mixer rate accordingly).\n# Possible values: 44100, 49716, 48000, 32000, 22050, 16000, 11025, 8000.\n\nsbtype=sb16\nsbbase=220\nirq=7\ndma=1\nhdma=5\nsbmixer=true\noplmode=auto\noplemu=default\noplrate=44100\n\n[gus]\n# gus: Enable the Gravis Ultrasound emulation.\n# gusrate: Sample rate of Ultrasound emulation.\n# Possible values: 44100, 48000, 32000, 22050, 16000, 11025, 8000, 49716.\n# gusbase: The IO base address of the Gravis Ultrasound.\n# Possible values: 240, 220, 260, 280, 2a0, 2c0, 2e0, 300.\n# gusirq: The IRQ number of the Gravis Ultrasound.\n# Possible values: 5, 3, 7, 9, 10, 11, 12.\n# gusdma: The DMA channel of the Gravis Ultrasound.\n# Possible values: 3, 0, 1, 5, 6, 7.\n# ultradir: Path to Ultrasound directory. In this directory\n# there should be a MIDI directory that contains\n# the patch files for GUS playback. Patch sets used\n# with Timidity should work fine.\n\ngus=false\ngusrate=44100\ngusbase=240\ngusirq=5\ngusdma=3\nultradir=C:\\ULTRASND\n\n[speaker]\n# pcspeaker: Enable PC-Speaker emulation.\n# pcrate: Sample rate of the PC-Speaker sound generation.\n# Possible values: 44100, 48000, 32000, 22050, 16000, 11025, 8000, 49716.\n# tandy: Enable Tandy Sound System emulation. For 'auto', emulation is present only if machine is set to 'tandy'.\n# Possible values: auto, on, off.\n# tandyrate: Sample rate of the Tandy 3-Voice generation.\n# Possible values: 44100, 48000, 32000, 22050, 16000, 11025, 8000, 49716.\n# disney: Enable Disney Sound Source emulation. (Covox Voice Master and Speech Thing compatible).\n\npcspeaker=true\npcrate=44100\ntandy=auto\ntandyrate=44100\ndisney=true\n\n[joystick]\n# joysticktype: Type of joystick to emulate: auto (default), none,\n# 2axis (supports two joysticks),\n# 4axis (supports one joystick, first joystick used),\n# 4axis_2 (supports one joystick, second joystick used),\n# fcs (Thrustmaster), ch (CH Flightstick).\n# none disables joystick emulation.\n# auto chooses emulation depending on real joystick(s).\n# (Remember to reset dosbox's mapperfile if you saved it earlier)\n# Possible values: auto, 2axis, 4axis, 4axis_2, fcs, ch, none.\n# timed: enable timed intervals for axis. Experiment with this option, if your joystick drifts (away).\n# autofire: continuously fires as long as you keep the button pressed.\n# swap34: swap the 3rd and the 4th axis. can be useful for certain joysticks.\n# buttonwrap: enable button wrapping at the number of emulated buttons.\n\njoysticktype=auto\ntimed=true\nautofire=false\nswap34=false\nbuttonwrap=false\n\n[serial]\n# serial1: set type of device connected to com port.\n# Can be disabled, dummy, modem, nullmodem, directserial.\n# Additional parameters must be in the same line in the form of\n# parameter:value. Parameter for all types is irq (optional).\n# for directserial: realport (required), rxdelay (optional).\n# (realport:COM1 realport:ttyS0).\n# for modem: listenport (optional).\n# for nullmodem: server, rxdelay, txdelay, telnet, usedtr,\n# transparent, port, inhsocket (all optional).\n# Example: serial1=modem listenport:5000\n# Possible values: dummy, disabled, modem, nullmodem, directserial.\n# serial2: see serial1\n# Possible values: dummy, disabled, modem, nullmodem, directserial.\n# serial3: see serial1\n# Possible values: dummy, disabled, modem, nullmodem, directserial.\n# serial4: see serial1\n# Possible values: dummy, disabled, modem, nullmodem, directserial.\n\nserial1=dummy\nserial2=dummy\nserial3=disabled\nserial4=disabled\n\n[dos]\n# xms: Enable XMS support.\n# ems: Enable EMS support.\n# umb: Enable UMB support.\n# keyboardlayout: Language code of the keyboard layout (or none).\n\nxms=true\nems=true\numb=true\nkeyboardlayout=auto\n\n[ipx]\n# ipx: Enable ipx over UDP/IP emulation.\n\nipx=true\n"+(r=t.autoexec,"[autoexec]\necho off\nmount c .\nc:\n\ntype jsdos~1/readme.txt\necho on\n\n".concat(r.options.script.value,"\n\n# Generated using https://js-dos.com\n# █▀▀▀▀▀█ █ ▄▄▄▀▀█ █▀▀▀▀▀█\n# █ ███ █ ██▄ █ ▀ ▄ █ ███ █\n# █ ▀▀▀ █ ▄██ ▀ ▀▀█ █ ▀▀▀ █\n# ▀▀▀▀▀▀▀ ▀ █▄▀▄▀ █ ▀▀▀▀▀▀▀\n# █▀▄▄█▀▀▄▄ ▀ ▀█▄▄▄▄ ▀▄█▀█▀\n# █▀ ▀ ▀▀▄ █▀ ▄ ▄▀▀▀▄ █▀█▄\n# ▄ ▄▄ █▀▀▄ ▄▀▄▀▀█ ▀▀▄▀▀█▀\n# ▄▀▀█▀▀ █▀█▀█▀▀▄ ▀██▀█▄\n# ▀▀▀ ▀ ▀ █▄█ ▀█▄▄█▀▀▀█▀▀\n# █▀▀▀▀▀█ ▄▄▄ ▄ ▄ █ ▀ █▄▄▄▄\n# █ ███ █ ▀█▀▀▄▀▀▄████▀▀█▄█\n# █ ▀▀▀ █ ▄▀▀█▀█▀▄ ▀▀▄▄█▄█\n# ▀▀▀▀▀▀▀ ▀ ▀▀ ▀ ▀ ▀▀▀\n")),e.abrupt("return",Promise.resolve(n));case 6:case"end":return e.stop()}var r}),e)})))).apply(this,arguments)}function C(e){var t="";t+="[".concat(e.name,"]\n");var n,r=function(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,o,i=!0,a=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return i=e.done,e},e:function(e){a=!0,o=e},f:function(){try{i||null==r.return||r.return()}finally{if(a)throw o}}}}(Object.keys(e.options).sort());try{for(r.s();!(n=r.n()).done;){var o=n.value,i=e.options[o];t+="".concat(i.name,"=").concat(i.value,"\n")}}catch(e){r.e(e)}finally{r.f()}return t}n.AutoexecCategory=m,n.createDosConfig=y,n.toDosboxConf=function(e){return j.apply(this,arguments)}},{"core-js/modules/es6.array.find":101,"core-js/modules/es6.array.from":102,"core-js/modules/es6.array.iterator":103,"core-js/modules/es6.function.name":104,"core-js/modules/es6.number.constructor":109,"core-js/modules/es6.number.parse-int":110,"core-js/modules/es6.object.keys":111,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.string.starts-with":121,"core-js/modules/es6.symbol":122,"core-js/modules/es7.object.get-own-property-descriptors":125,"core-js/modules/es7.symbol.async-iterator":126,"core-js/modules/web.dom.iterable":127,"regenerator-runtime/runtime":128}],133:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}e("core-js/modules/es6.function.name"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var o=e("../../../protocol/messages-queue");function i(){var e;return e=regeneratorRuntime.mark((function e(t,n){var r,i,s,a,l;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=new o.MessagesQueue,i=r.handler.bind(r),a=function(e){var t=e.data;"ws-sync-sleep"===(null==t?void 0:t.name)&&t.props.sessionId===n&&postMessage({name:"wc-sync-sleep",props:t.props},"*")},(l={sessionId:n,sendMessageToServer:function(e,t){s.messageHandler({data:{name:e,props:t}})},initMessageHandler:function(e){i=e,r.sendTo(i)},exit:function(){"undefined"!=typeof window&&window.removeEventListener("message",a)}}).module=s={postMessage:function(e,t){i(e,t)}},"undefined"!=typeof window&&window.addEventListener("message",a,{passive:!0}),e.next=10,t.instantiate(s);case 10:return s.callMain([n]),e.abrupt("return",l);case 12:case"end":return e.stop()}}),e)})),(i=function(){var t=this,n=arguments;return new Promise((function(o,i){var s=e.apply(t,n);function a(e){r(s,o,i,a,l,"next",e)}function l(e){r(s,o,i,a,l,"throw",e)}a(void 0)}))}).apply(this,arguments)}n.dosDirect=function(e,t){return i.apply(this,arguments)}},{"../../../protocol/messages-queue":142,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"regenerator-runtime/runtime":128}],134:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}e("core-js/modules/es6.function.name"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var o=e("../../../protocol/messages-queue");function i(){var e;return e=regeneratorRuntime.mark((function e(t,n,r){var i,s,a,l;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=new o.MessagesQueue,s=i.handler.bind(i),(a=new Worker(t)).onerror=function(e){s("ws-err",{type:e.type,filename:e.filename,message:e.message})},a.onmessage=function(e){var t=e.data;void 0!==(null==t?void 0:t.name)&&s(t.name,t.props)},e.next=7,n.instantiate({});case 7:l={sessionId:r,sendMessageToServer:function(e,t){a.postMessage({name:e,props:t})},initMessageHandler:function(e){s=e,i.sendTo(s)},exit:function(){a.terminate()}};try{l.sendMessageToServer("wc-install",{module:n.wasmModule,sessionId:r})}catch(e){l.sendMessageToServer("wc-install",{sessionId:r})}return e.abrupt("return",l);case 10:case"end":return e.stop()}}),e)})),(i=function(){var t=this,n=arguments;return new Promise((function(o,i){var s=e.apply(t,n);function a(e){r(s,o,i,a,l,"next",e)}function l(e){r(s,o,i,a,l,"throw",e)}a(void 0)}))}).apply(this,arguments)}n.dosWorker=function(e,t,n){return i.apply(this,arguments)}},{"../../../protocol/messages-queue":142,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"regenerator-runtime/runtime":128}],135:[function(e,t,n){(function(t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r,o=function(e){return e&&e.__esModule?e:{default:e}}(e("./impl/emulators-impl"));(r=n.NetworkType||(n.NetworkType={}))[r.NETWORK_DOSBOX_IPX=0]="NETWORK_DOSBOX_IPX","undefined"!=typeof window&&(window.emulators=o.default),void 0!==t&&(t.emulators=o.default)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./impl/emulators-impl":138}],136:[function(e,t,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}e("core-js/modules/es7.object.get-own-property-descriptors"),e("core-js/modules/es6.symbol"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es6.array.iterator"),e("core-js/modules/es6.object.keys"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var a=e("./cache");n.HTTPRequest=function(e,t){return new Promise((function(n,r){new l(e,i(i({},t),{},{success:n,fail:function(e){r(new Error(e))}}))}))};var l=function(){function e(t,n){var r=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.xhr=null,this.total=0,this.loaded=0,this.resource=t,this.options=n,this.options.method=n.method||"GET",this.cache=n.cache||new a.CacheNoop,"GET"===this.options.method&&this.cache.get(this.resource).then((function(e){void 0!==r.options.success&&r.options.success(e)})).catch((function(){r.makeHttpRequest()}))}var t,n;return t=e,(n=[{key:"makeHttpRequest",value:function(){var e,t,n=this;this.xhr=new XMLHttpRequest,this.xhr.open(this.options.method||"GET",this.resource,!0),"POST"===this.options.method&&this.xhr.setRequestHeader("Content-type","application/x-www-form-urlencoded"),this.xhr.overrideMimeType("text/plain; charset=x-user-defined"),"function"==typeof(e=this.xhr).addEventListener&&e.addEventListener("progress",(function(e){if(n.total=e.total,n.loaded=e.loaded,n.options.progress)return n.options.progress(e.total,e.loaded)})),"function"==typeof(t=this.xhr).addEventListener&&t.addEventListener("error",(function(){if(n.options.fail)return n.options.fail("Unalbe to download '"+n.resource+"', code: "+n.xhr.status),delete n.options.fail})),this.xhr.onreadystatechange=function(){return n.onReadyStateChange()},this.options.responseType&&(this.xhr.responseType=this.options.responseType),this.xhr.send(this.options.data)}},{key:"onReadyStateChange",value:function(){var e=this.xhr;if(4===e.readyState)if(200===e.status){if(this.options.success){var t=Math.max(this.total,this.loaded);return void 0!==this.options.progress&&this.options.progress(t,t),"GET"===this.options.method&&this.resource.indexOf("?")<0&&this.cache.put(this.resource,e.response),this.options.success(e.response)}}else if(this.options.fail)return this.options.fail("Unable to download '"+this.resource+"', code: "+e.status),delete this.options.fail}}])&&r(t.prototype,n),e}()},{"./cache":130,"core-js/modules/es6.array.iterator":103,"core-js/modules/es6.object.keys":111,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.symbol":122,"core-js/modules/es7.object.get-own-property-descriptors":125,"core-js/modules/web.dom.iterable":127}],137:[function(e,t,n){"use strict";function r(e){return function(e){if(Array.isArray(e))return s(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||i(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=i(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,o,s=!0,a=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return s=e.done,e},e:function(e){a=!0,o=e},f:function(){try{s||null==r.return||r.return()}finally{if(a)throw o}}}}function i(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/web.dom.iterable"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var l=function(){function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.onStdoutConsumers=[],this.delayedStdout=[],this.onFrameSizeConsumers=[],this.onFrameConsumers=[],this.onSoundPushConsumers=[],this.onExitConsumers=[],this.onMessageConsumers=[],this.delayedMessages=[],this.onNetworkConnectedConsumers=[],this.onNetworkDisconnectedConsumers=[],this.onStdout=function(e){if(t.onStdoutConsumers.push(e),1===t.onStdoutConsumers.length){var n,r=o(t.delayedStdout);try{for(r.s();!(n=r.n()).done;){var i=n.value;t.fireStdout(i)}}catch(e){r.e(e)}finally{r.f()}t.delayedStdout=[]}},this.onFrameSize=function(e){t.onFrameSizeConsumers.push(e)},this.onFrame=function(e){t.onFrameConsumers.push(e)},this.onSoundPush=function(e){t.onSoundPushConsumers.push(e)},this.onExit=function(e){t.onExitConsumers.push(e)},this.onMessage=function(e){if(t.onMessageConsumers.push(e),1===t.onMessageConsumers.length){var n,i=o(t.delayedMessages);try{for(i.s();!(n=i.n()).done;){var s=n.value;e.apply(void 0,[s.msgType].concat(r(s.args)))}}catch(e){i.e(e)}finally{i.f()}t.delayedMessages=[]}},this.fireStdout=function(e){if(0!==t.onStdoutConsumers.length){var n,r=o(t.onStdoutConsumers);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e)}catch(e){r.e(e)}finally{r.f()}}else t.delayedStdout.push(e)},this.fireFrameSize=function(e,n){var r,i=o(t.onFrameSizeConsumers);try{for(i.s();!(r=i.n()).done;)(0,r.value)(e,n)}catch(e){i.e(e)}finally{i.f()}},this.fireFrame=function(e){var n,r=o(t.onFrameConsumers);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e)}catch(e){r.e(e)}finally{r.f()}},this.fireSoundPush=function(e){var n,r=o(t.onSoundPushConsumers);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e)}catch(e){r.e(e)}finally{r.f()}},this.fireExit=function(){var e,n=o(t.onExitConsumers);try{for(n.s();!(e=n.n()).done;)(0,e.value)()}catch(e){n.e(e)}finally{n.f()}t.onStdoutConsumers=[],t.onFrameSizeConsumers=[],t.onFrameConsumers=[],t.onSoundPushConsumers=[],t.onExitConsumers=[],t.onMessageConsumers=[]},this.fireMessage=function(e){for(var n=arguments.length,r=new Array(1<n?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];if(0!==t.onMessageConsumers.length){var s,a=o(t.onMessageConsumers);try{for(a.s();!(s=a.n()).done;)s.value.apply(void 0,[e].concat(r))}catch(e){a.e(e)}finally{a.f()}}else t.delayedMessages.push({msgType:e,args:r})},this.fireNetworkConnected=function(e,n,r){var i,s=o(t.onNetworkConnectedConsumers);try{for(s.s();!(i=s.n()).done;)(0,i.value)(e,n,r)}catch(e){s.e(e)}finally{s.f()}},this.fireNetworkDisconnected=function(e){var n,r=o(t.onNetworkDisconnectedConsumers);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e)}catch(e){r.e(e)}finally{r.f()}}}var t,n;return t=e,(n=[{key:"onNetworkConnected",value:function(e){this.onNetworkConnectedConsumers.push(e)}},{key:"onNetworkDisconnected",value:function(e){this.onNetworkDisconnectedConsumers.push(e)}}])&&a(t.prototype,n),e}();n.CommandInterfaceEventsImpl=l},{"core-js/modules/es6.array.from":102,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.symbol":122,"core-js/modules/es7.symbol.async-iterator":126,"core-js/modules/web.dom.iterable":127}],138:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(o,i){var s=e.apply(t,n);function a(e){r(s,o,i,a,l,"next",e)}function l(e){r(s,o,i,a,l,"throw",e)}a(void 0)}))}}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("regenerator-runtime/runtime");var s=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:!0});var a=e("../build"),l=e("../cache"),c=e("./modules"),u=s(e("../dos/bundle/dos-bundle")),d=e("../dos/dosbox/ts/direct"),f=e("../dos/dosbox/ts/worker"),p=s(e("../janus/janus-impl")),h=e("../protocol/protocol"),m=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.pathPrefix="",this.cacheSeed="",this.cachePromises={}}var t,n,r,s,m,y,v,g,b,_;return t=e,(n=[{key:"cache",value:function(e){if(null!=e&&0!==e.length||(e=a.Build.version+" "+this.cacheSeed),void 0===this.cachePromises[e]){var t=l.CacheDb(e,{onErr:console.error});this.cachePromises[e]=t}return this.cachePromises[e]}},{key:"dosBundle",value:(_=o(regeneratorRuntime.mark((function e(){var t,n,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.wasmModules();case 2:return t=e.sent,e.next=5,t.libzip();case 5:return n=e.sent,e.next=8,this.cache();case 8:return r=e.sent,e.abrupt("return",new u.default(n,r));case 10:case"end":return e.stop()}}),e,this)}))),function(){return _.apply(this,arguments)})},{key:"dosboxNode",value:(b=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.dosboxDirect(t));case 1:case"end":return e.stop()}}),e,this)}))),function(e){return b.apply(this,arguments)})},{key:"dosboxDirect",value:(g=o(regeneratorRuntime.mark((function e(t){var n,r,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.wasmModules();case 2:return n=e.sent,e.next=5,n.dosbox();case 5:return r=e.sent,e.next=8,d.dosDirect(r,"session-"+Date.now());case 8:return o=e.sent,e.abrupt("return",this.backend(t,o));case 10:case"end":return e.stop()}}),e,this)}))),function(e){return g.apply(this,arguments)})},{key:"dosboxWorker",value:(v=o(regeneratorRuntime.mark((function e(t){var n,r,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.wasmModules();case 2:return n=e.sent,e.next=5,n.dosbox();case 5:return r=e.sent,e.next=8,f.dosWorker(this.pathPrefix+"wdosbox.js",r,"session-"+Date.now());case 8:return o=e.sent,e.abrupt("return",this.backend(t,o));case 10:case"end":return e.stop()}}),e,this)}))),function(e){return v.apply(this,arguments)})},{key:"janus",value:(y=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",p.default(t));case 1:case"end":return e.stop()}}),e)}))),function(e){return y.apply(this,arguments)})},{key:"backend",value:(m=o(regeneratorRuntime.mark((function e(t,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new Promise((function(e,r){var o=new h.CommandInterfaceOverTransportLayer(Array.isArray(t)?t:[t],n,(function(t){null!==t?r(t):setTimeout((function(){return e(o)}),4)}))})));case 1:case"end":return e.stop()}}),e)}))),function(e,t){return m.apply(this,arguments)})},{key:"wasmModules",value:function(){var e=this;if(void 0!==this.wasmModulesPromise)return this.wasmModulesPromise;var t=function(){var t=o(regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.cache();case 2:return n=t.sent,t.abrupt("return",new c.WasmModulesImpl(e.pathPrefix,n));case 4:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();return this.wasmModulesPromise=t(),this.wasmModulesPromise}},{key:"dosDirect",value:(s=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.dosboxDirect(t));case 1:case"end":return e.stop()}}),e,this)}))),function(e){return s.apply(this,arguments)})},{key:"dosWorker",value:(r=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.dosboxWorker(t));case 1:case"end":return e.stop()}}),e,this)}))),function(e){return r.apply(this,arguments)})}])&&i(t.prototype,n),e}());n.default=m},{"../build":129,"../cache":130,"../dos/bundle/dos-bundle":131,"../dos/dosbox/ts/direct":133,"../dos/dosbox/ts/worker":134,"../janus/janus-impl":140,"../protocol/protocol":143,"./modules":139,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"regenerator-runtime/runtime":128}],139:[function(e,t,n){"use strict";function r(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==a.return||a.return()}finally{if(o)throw i}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return o(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function i(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t,n){return t&&s(e.prototype,t),n&&s(e,n),e}function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}e("core-js/modules/es6.array.from"),e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es6.array.iterator"),e("core-js/modules/es6.string.iterator"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.math.trunc"),e("core-js/modules/es6.math.clz32"),e("core-js/modules/es6.math.fround"),e("core-js/modules/es6.math.imul"),e("core-js/modules/es6.typed.uint8-array"),Object.defineProperty(n,"__esModule",{value:!0});var u=e("../http");n.host=new function e(){if(c(this,e),this.wasmSupported=!1,this.globals="undefined"==typeof window?{}:window,this.globals.exports||(this.globals.exports={}),this.globals.compiled||(this.globals.compiled={}),"object"===("undefined"==typeof WebAssembly?"undefined":l(WebAssembly))&&"function"==typeof WebAssembly.instantiate&&"function"==typeof WebAssembly.compile){var t=new WebAssembly.Module(Uint8Array.of(0,97,115,109,1,0,0,0));t instanceof WebAssembly.Module&&(this.wasmSupported=new WebAssembly.Instance(t)instanceof WebAssembly.Instance)}Math.imul&&-5===Math.imul(4294967295,5)||(Math.imul=function(e,t){var n=65535&e,r=65535&t;return n*r+((e>>>16)*r+n*(t>>>16)<<16)|0}),Math.imul=Math.imul,Math.fround||(Math.fround=function(e){return e}),Math.fround=Math.fround,Math.clz32||(Math.clz32=function(e){e>>>=0;for(var t=0;t<32;t++)if(e&1<<31-t)return t;return 32}),Math.clz32=Math.clz32,Math.trunc||(Math.trunc=function(e){return e<0?Math.ceil(e):Math.floor(e)}),Math.trunc=Math.trunc};var d=function(){function e(t,n){c(this,e),this.wasmSupported=!1,0<t.length&&"/"!==t[t.length-1]&&(t+="/"),this.pathPrefix=t,this.cache=n}return a(e,[{key:"libzip",value:function(){return void 0!==this.libzipPromise||(this.libzipPromise=this.loadModule(this.pathPrefix+"wlibzip.js","WLIBZIP")),this.libzipPromise}},{key:"dosbox",value:function(){return void 0!==this.dosboxPromise||(this.dosboxPromise=this.loadModule(this.pathPrefix+"wdosbox.js","WDOSBOX")),this.dosboxPromise}},{key:"loadModule",value:function(e,t){return f(e,t,this.cache,(function(){}))}}]),e}();function f(t,o,s,a){return"undefined"==typeof XMLHttpRequest?function(t,r){if(void 0!==n.host.globals.compiled[r])return n.host.globals.compiled[r];var o=e(t),i=Promise.resolve(new p(o));return r&&(n.host.globals.compiled[r]=i),i}(t,o):function(e,t,o,s){if(void 0!==n.host.globals.compiled[t])return n.host.globals.compiled[t];function a(){var l;return l=regeneratorRuntime.mark((function i(){var a,l,c,d,f,p,m,y,v,g,b,_;return regeneratorRuntime.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:if(a=e.lastIndexOf("/"),l=e.indexOf("w",a),c=l===a+1&&0<=l,n.host.wasmSupported&&c){i.next=5;break}throw new Error("Starting from js-dos 6.22.60 js environment is not supported");case 5:return d=e.substr(0,e.lastIndexOf(".js"))+".wasm",f=u.HTTPRequest(d,{cache:o,responseType:"arraybuffer",progress:function(t,n){s("Resolving DosBox ("+e+")",t,n)}}),p=u.HTTPRequest(e,{cache:o,progress:function(e,t){s("Resolving DosBox",e,t)}}),i.next=10,Promise.all([f,p]);case 10:return m=i.sent,y=r(m,2),v=y[0],g=y[1],i.next=16,WebAssembly.compile(v);case 16:return b=i.sent,_=function(e,t){e.env=e.env||{},WebAssembly.instantiate(b,e).then((function(e){return t(e,b)}))},eval.call(window,g),i.abrupt("return",new h(b,n.host.globals.exports[t],_));case 20:case"end":return i.stop()}}),i)})),(a=function(){var e=this,t=arguments;return new Promise((function(n,r){var o=l.apply(e,t);function s(e){i(o,n,r,s,a,"next",e)}function a(e){i(o,n,r,s,a,"throw",e)}s(void 0)}))}).apply(this,arguments)}var l=function(){return a.apply(this,arguments)}();return t&&(n.host.globals.compiled[t]=l),l}(t,o,s,a)}n.WasmModulesImpl=d,n.loadWasmModule=f;var p=function(){function e(t){c(this,e),this.emModule=t}return a(e,[{key:"instantiate",value:function(e){var t=this;return new Promise((function(n){e.onRuntimeInitialized=function(){n()},new t.emModule(e)}))}}]),e}(),h=function(){function e(t,n,r){c(this,e),this.wasmModule=t,this.module=n,this.instantiateWasm=r}return a(e,[{key:"instantiate",value:function(e){var t=this;return new Promise((function(n){e.instantiateWasm=t.instantiateWasm,e.onRuntimeInitialized=function(){n()},new t.module(e)}))}}]),e}()},{"../http":136,"core-js/modules/es6.array.from":102,"core-js/modules/es6.array.iterator":103,"core-js/modules/es6.function.name":104,"core-js/modules/es6.math.clz32":105,"core-js/modules/es6.math.fround":106,"core-js/modules/es6.math.imul":107,"core-js/modules/es6.math.trunc":108,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.symbol":122,"core-js/modules/es6.typed.uint8-array":123,"core-js/modules/es7.symbol.async-iterator":126,"core-js/modules/web.dom.iterable":127,"regenerator-runtime/runtime":128}],140:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(o,i){var s=e.apply(t,n);function a(e){r(s,o,i,a,l,"next",e)}function l(e){r(s,o,i,a,l,"throw",e)}a(void 0)}))}}function i(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==a.return||a.return()}finally{if(o)throw i}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/es6.typed.uint8-array"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.number.constructor"),e("core-js/modules/es6.number.parse-int"),e("core-js/modules/es6.regexp.split"),e("core-js/modules/es6.string.starts-with"),Object.defineProperty(n,"__esModule",{value:!0});var l=e("../impl/ci-impl");function c(e,t){var n="";return function r(o){var i=o.indexOf("\n");if(-1===i)n+=o;else{var s=n+o.substr(0,i);n="";try{e(function(e){for(var t=atob(e),n=new Uint8Array(t.length),r=0;r<n.length;r++)n[r]=t.charCodeAt(r);return(new TextDecoder).decode(n)}(s))}catch(r){t(r)}r(o.substr(i+1))}}}var u=function(){function e(t,n){var r=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.live=!0,this.startedAt=Date.now(),this.exitResolveFn=function(){},this.configResolveFn=function(){},this.handleResolveFn=function(){},this.keyMatrix={},this.frameWidth=0,this.frameHeight=0,this.eventQueue="",this.eventIntervalId=-1,this.rttIntervalId=-1,this.logIntervalId=-1,this.logColor="not set",this.logWhiteMs=0,this.logRedMs=0,this.logYellowMs=0,this.onDataMessage=function(e){if(e.startsWith("config="))r.configResolveFn(JSON.parse(e.substr("config=".length)));else if(e.startsWith("frame=")){var t=i(e.substr("frame=".length).split("x"),2),n=t[0],o=t[1];r.frameWidth=Number.parseInt(n,10)||0,r.frameHeight=Number.parseInt(o,10)||0}else if(e.startsWith("rtt=")){var s,a=i(e.substr("rtt=".length).split(" "),3),l=a[0],c=a[1],u=a[2],d=Number.parseInt(c,10),f=Number.parseInt(u,10),p=Date.now(),h=(null===(s=r.handle)||void 0===s?void 0:s.getBitrate())||"0 kbits/sec",m=Number.parseInt(h.split(" ")[0],10);r.sendPipeMessage("rtt-data",Date.now(),d,f,p,m),l===r.opaqueId&&r.eventsImpl.fireStdout("rtt-data="+(p-d)+" "+m)}else if(e.startsWith("log-visual-"))switch(e){case"log-visual-white":r.eventsImpl.fireStdout("yellow-frame:"+(Date.now()-r.logYellowMs));break;case"log-visual-red":r.eventsImpl.fireStdout("white-frame:"+(Date.now()-r.logWhiteMs));break;case"log-visual-yellow":r.eventsImpl.fireStdout("red-frame:"+(Date.now()-r.logRedMs))}else if(e.startsWith("log-command-"))switch(e){case"log-command-white":r.eventsImpl.fireStdout("yellow-pipe:"+(Date.now()-r.logYellowMs));break;case"log-command-red":r.eventsImpl.fireStdout("white-pipe:"+(Date.now()-r.logWhiteMs));break;case"log-command-yellow":r.eventsImpl.fireStdout("red-pipe:"+(Date.now()-r.logRedMs))}else r.eventsImpl.fireStdout(e)},this.onJanusMessage=function(e,t,n){null!=n&&e.createAnswer({jsep:n,media:{audioSend:!1,videoSend:!1,data:!0},success:function(t){r.fireMessage("started"),e.send({message:{request:"start"},jsep:t})},error:r.onError})},this.onError=function(e){r.fireMessage("error",e)},this.eventsImpl=new l.CommandInterfaceEventsImpl,this.janus=t,this.opaqueId=n,this.exitPromise=new Promise((function(e){r.exitResolveFn=e})),this.configPromise=new Promise((function(e){r.configResolveFn=e})),this.handlePromise=new Promise((function(e,t){r.handleResolveFn=function(n){r.handle=n,r.live?(setTimeout((function(){r.live&&n.data({text:"pipe "+r.opaqueId+" config"})}),1e3),r.config().then((function(){r.live&&(r.eventIntervalId=setInterval((function(){r.sendEventsData(n)}),8),r.rttIntervalId=setInterval((function(){r.sendPipeMessage("rtt",Date.now())}),1e3))})),e(n)):t(new Error("exit() was called"))}})),this.attach()}var t,n,r,s;return t=e,(n=[{key:"fireMessage",value:function(e){for(var t,n=arguments.length,r=new Array(1<n?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];(t=this.eventsImpl).fireMessage.apply(t,[e].concat(r))}},{key:"attach",value:function(){var e,t=this;this.janus.attach({plugin:"janus.plugin.streaming",opaqueId:this.opaqueId,error:this.onError,success:function(n){e=n,t.fireMessage("attached"),n.send({message:{request:"watch",id:1}})},onmessage:function(n,r){t.onJanusMessage(e,n,r)},onremotestream:function(e){t.fireMessage("onremotestream",e)},ondataopen:function(){return t.handleResolveFn(e)},ondata:c(this.onDataMessage,this.onError)})}},{key:"onDestroyed",value:function(){this.fireMessage("destroyed"),this.exitResolveFn()}},{key:"config",value:(s=o(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.configPromise);case 1:case"end":return e.stop()}}),e,this)}))),function(){return s.apply(this,arguments)})},{key:"width",value:function(){return this.frameWidth}},{key:"height",value:function(){return this.frameHeight}},{key:"soundFrequency",value:function(){return 44100}},{key:"screenshot",value:function(){return Promise.reject(new Error("Not supported"))}},{key:"simulateKeyPress",value:function(){for(var e=this,t=Date.now()-this.startedAt,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];r.forEach((function(n){return e.addKey(n,!0,t)})),r.forEach((function(n){return e.addKey(n,!1,16+t)}))}},{key:"sendKeyEvent",value:function(e,t){this.addKey(e,t,Date.now()-this.startedAt)}},{key:"addKey",value:function(e,t,n){if(!0===this.keyMatrix[e]!==t&&(this.keyMatrix[e]=t,this.sendPipeMessage("k"+(t?"down":"up"),e,n),-1!==this.logIntervalId&&t))switch(this.logColor){case"white":this.logWhiteMs=Date.now();break;case"red":this.logRedMs=Date.now();break;case"yellow":this.logYellowMs=Date.now()}}},{key:"sendMouseMotion",value:function(e,t){this.sendPipeMessage("mmove",e,t,Date.now()-this.startedAt)}},{key:"sendMouseRelativeMotion",value:function(){throw new Error("not implemented")}},{key:"sendMouseButton",value:function(e,t){this.sendPipeMessage("m"+(t?"down":"up"),e,Date.now()-this.startedAt)}},{key:"sendMouseSync",value:function(){this.sendPipeMessage("msync",Date.now()-this.startedAt)}},{key:"logVisual",value:function(e){var t=this;this.sendPipeMessage("log-visual-on");var n=document.createElement("canvas"),r=n.getContext("2d");n.width=1,n.height=1,this.logIntervalId=setInterval(o(regeneratorRuntime.mark((function n(){var o,i,s,a,l;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(i=Date.now(),null!=r&&r.drawImage(e,0,0,1,1,0,0,1,1),s=null==r||null===(o=r.getImageData(0,0,1,1))||void 0===o?void 0:o.data,a=Date.now()-i,l="not set",200<s[0]&&200<s[1]&&200<s[2]?l="white":200<s[0]&&s[1]<200&&s[2]<200?l="red":200<s[0]&&200<s[1]&&s[2]<200&&(l="yellow"),l===t.logColor){n.next=17;break}n.t0=l,n.next="white"===n.t0?10:"red"===n.t0?12:"yellow"===n.t0?14:16;break;case 10:return t.eventsImpl.fireStdout("yellow-stream:"+(Date.now()-t.logYellowMs-a)),n.abrupt("break",16);case 12:return t.eventsImpl.fireStdout("white-stream:"+(Date.now()-t.logWhiteMs-a)),n.abrupt("break",16);case 14:return t.eventsImpl.fireStdout("red-stream:"+(Date.now()-t.logRedMs-a)),n.abrupt("break",16);case 16:t.logColor=l;case 17:case"end":return n.stop()}}),n)}))),16)}},{key:"sendPipeMessage",value:function(){this.eventQueue+="pipe "+this.opaqueId;for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];for(var r=0,o=t;r<o.length;r++){var i=o[r];this.eventQueue+=" "+i}this.eventQueue+="\n"}},{key:"sendEventsData",value:(r=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(0===this.eventQueue.length)return e.abrupt("return");e.next=2;break;case 2:t.data({text:this.eventQueue}),this.eventQueue="";case 4:case"end":return e.stop()}}),e,this)}))),function(e){return r.apply(this,arguments)})},{key:"persist",value:function(){return Promise.reject(new Error("Not supported"))}},{key:"pause",value:function(){console.warn("pause/resume is not implemented")}},{key:"resume",value:function(){}},{key:"mute",value:function(){console.warn("mute/unmute is not implemented")}},{key:"unmute",value:function(){}},{key:"exit",value:function(){return this.live=!1,clearInterval(this.logIntervalId),this.logIntervalId=-1,clearInterval(this.eventIntervalId),this.eventIntervalId=-1,clearInterval(this.rttIntervalId),this.rttIntervalId=-1,this.janus.destroy(),this.exitPromise}},{key:"events",value:function(){return this.eventsImpl}},{key:"networkConnect",value:function(){return Promise.reject("Not supported")}},{key:"networkDisconnect",value:function(){return Promise.reject("Not supported")}}])&&a(t.prototype,n),e}();n.default=function(e,t){var n=t||window.Janus;return void 0===n?Promise.reject(new Error("Janus is not defined, you should load janus.js before this")):n.isWebrtcSupported()?new Promise((function(t,r){var o=null,i={error:function(e){null===o?r(e):o.onError(e)},destroyed:function(){null!==o&&o.onDestroyed()}},s={server:e,success:function(){o=new u(a,"js-dos-"+n.randomString(12)),t(o)},error:i.error,destroyed:i.destroyed,destroyOnUnload:!0},a=new n(s)})):Promise.reject(new Error("WebRTC not supported"))}},{"../impl/ci-impl":137,"core-js/modules/es6.array.from":102,"core-js/modules/es6.function.name":104,"core-js/modules/es6.number.constructor":109,"core-js/modules/es6.number.parse-int":110,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.split":118,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.string.starts-with":121,"core-js/modules/es6.symbol":122,"core-js/modules/es6.typed.uint8-array":123,"core-js/modules/es7.symbol.async-iterator":126,"core-js/modules/web.dom.iterable":127,"regenerator-runtime/runtime":128}],141:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/es6.regexp.constructor"),e("core-js/modules/es6.regexp.replace"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.typed.uint8-array"),e("core-js/modules/es6.regexp.split"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.module=t,this.home=n,this.module.callMain([]),this.chdirToHome()}var t,n,i,s;return t=e,(n=[{key:"zipFromFs",value:function(e){var t=0<arguments.length&&void 0!==e?e:-1;this.chdirToHome();var n=this.module._zip_from_fs(t);if(0===n)return Promise.reject(new Error("Can't create zip, see more info in logs"));var r=this.module.HEAPU32[n/4],o=this.module.HEAPU8.slice(n+4,n+4+r);return this.module._free(n),Promise.resolve(o)}},{key:"zipToFs",value:function(e,t){var n=1<arguments.length&&void 0!==t?t:"/";n=this.normalizeFilename(n);var r=this.normalizeFilename(n).split("/");this.createPath(r,0,r.length),this.chdir(n);var o=new Uint8Array(e),i=this.module._malloc(o.length);this.module.HEAPU8.set(o,i);var s=this.module._zip_to_fs(i,o.length);return this.module._free(i),this.chdirToHome(),0===s?Promise.resolve():Promise.reject(new Error("Can't extract zip, retcode "+s+", see more info in logs"))}},{key:"writeFile",value:function(e,t){e=this.normalizeFilename(e),t instanceof ArrayBuffer&&(t=new Uint8Array(t));var n=e.split("/");if(0===n.length)throw new Error("Can't create file '"+e+"', because it's not valid file path");var r=n[n.length-1].trim();if(0===r.length)throw new Error("Can't create file '"+e+"', because file name is empty");var o=this.createPath(n,0,n.length-1);this.module.FS.writeFile(o+"/"+r,t)}},{key:"readFile",value:(i=regeneratorRuntime.mark((function e(t){var n,r=arguments;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=1<r.length&&void 0!==r[1]?r[1]:"utf8",t=this.normalizeFilename(t),e.abrupt("return",this.module.FS.readFile(t,{encoding:n}));case 3:case"end":return e.stop()}}),e,this)})),s=function(){var e=this,t=arguments;return new Promise((function(n,o){var s=i.apply(e,t);function a(e){r(s,n,o,a,l,"next",e)}function l(e){r(s,n,o,a,l,"throw",e)}a(void 0)}))},function(e){return s.apply(this,arguments)})},{key:"exists",value:function(e){e=this.normalizeFilename(e);try{return this.module.FS.lookupPath(e),!0}catch(e){return!1}}},{key:"destroy",value:function(){try{this.module._libzip_destroy()}catch(e){return e}}},{key:"normalizeFilename",value:function(e){for(e=e.replace(new RegExp("^[a-zA-z]+:"),"").replace(new RegExp("\\\\","g"),"/");"/"===e[0];)e=e.substr(1);return e}},{key:"createPath",value:function(e,t,n){for(var r=".",o=t;o<n;++o){var i=e[o].trim();0!==i.length&&(this.module.FS.createPath(r,i,!0,!0),r=r+"/"+i)}return r}},{key:"chdirToHome",value:function(){this.module.FS.chdir(this.home)}},{key:"chdir",value:function(e){this.module.FS.chdir(this.home+"/"+e)}}])&&o(t.prototype,n),e}();n.default=i},{"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.constructor":114,"core-js/modules/es6.regexp.replace":117,"core-js/modules/es6.regexp.split":118,"core-js/modules/es6.typed.uint8-array":123,"regenerator-runtime/runtime":128}],142:[function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/web.dom.iterable"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.function.name"),Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.messages=[]}var t,n;return t=e,(n=[{key:"handler",value:function(e,t){this.messages.push({name:e,props:t})}},{key:"sendTo",value:function(e){var t,n=function(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i,s=!0,a=!1;return{s:function(){o=e[Symbol.iterator]()},n:function(){var e=o.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==o.return||o.return()}finally{if(a)throw i}}}}(this.messages);try{for(n.s();!(t=n.n()).done;){var o=t.value;e(o.name,o.props)}}catch(e){n.e(e)}finally{n.f()}this.messages=[]}}])&&o(t.prototype,n),e}();n.MessagesQueue=i},{"core-js/modules/es6.array.from":102,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.symbol":122,"core-js/modules/es7.symbol.async-iterator":126,"core-js/modules/web.dom.iterable":127}],143:[function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/web.dom.iterable"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.string.starts-with"),e("core-js/modules/es6.typed.uint8-clamped-array"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.typed.uint8-array"),Object.defineProperty(n,"__esModule",{value:!0});var i=e("../impl/ci-impl"),s=function(){function e(t,n,r){var o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.startedAt=Date.now(),this.frameWidth=0,this.frameHeight=0,this.rgb=new Uint8Array,this.freq=0,this.eventsImpl=new i.CommandInterfaceEventsImpl,this.keyMatrix={},this.configResolve=function(){},this.panicMessages=[],this.connectPromise=null,this.connectResolve=function(){},this.connectReject=function(){},this.disconnectPromise=null,this.disconnectResolve=function(){},this.bundles=t,this.transport=n,this.ready=r,this.configPromise=new Promise((function(e){return o.configResolve=e})),this.transport.initMessageHandler(this.onServerMessage.bind(this))}var t,n;return t=e,(n=[{key:"sendClientMessage",value:function(e,t){(t=t||{}).sessionId=t.sessionId||this.transport.sessionId,this.transport.sendMessageToServer(e,t)}},{key:"onServerMessage",value:function(e,t){if(!(void 0===e||e.length<3||"w"!==e[0]||"s"!==e[1]||"-"!==e[2])&&void 0!==t&&t.sessionId===this.transport.sessionId)switch(e){case"ws-ready":this.sendClientMessage("wc-run",{bundles:this.bundles}),delete this.bundles;break;case"ws-server-ready":0<this.panicMessages.length?(void 0!==this.transport.exit&&this.transport.exit(),this.ready(new Error(JSON.stringify(this.panicMessages)))):this.ready(null),delete this.ready;break;case"ws-frame-set-size":this.onFrameSize(t.width,t.height);break;case"ws-update-lines":this.onFrameLines(t.lines);break;case"ws-exit":this.onExit();break;case"ws-log":this.onLog(t.tag,t.message);break;case"ws-warn":this.onWarn(t.tag,t.message);break;case"ws-err":this.onErr(t.tag,t.message);break;case"ws-stdout":this.onStdout(t.message);break;case"ws-persist":this.onPersist(t.bundle);break;case"ws-sound-init":this.onSoundInit(t.freq);break;case"ws-sound-push":this.onSoundPush(t.samples);break;case"ws-config":this.onConfig(JSON.parse(t.content));break;case"ws-sync-sleep":this.sendClientMessage("wc-sync-sleep",t);break;case"ws-connected":this.connectResolve(),this.connectPromise=null,this.connectResolve=function(){},this.connectReject=function(){},this.eventsImpl.fireNetworkConnected(t.networkType,t.address,t.port);break;case"ws-disconnected":null!==this.connectPromise?(this.connectReject(),this.connectPromise=null,this.connectResolve=function(){},this.connectReject=function(){}):(this.disconnectResolve(),this.disconnectPromise=null,this.disconnectResolve=function(){}),this.eventsImpl.fireNetworkDisconnected(t.networkType);break;default:console.log("Unknown server message (ws):",e)}}},{key:"onConfig",value:function(e){this.configResolve(e)}},{key:"onFrameSize",value:function(e,t){this.frameWidth===e&&this.frameHeight===t||(this.frameWidth=e,this.frameHeight=t,this.rgb=new Uint8Array(e*t*3),this.eventsImpl.fireFrameSize(e,t))}},{key:"onFrameLines",value:function(e){var t,n=function(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i,s=!0,a=!1;return{s:function(){o=e[Symbol.iterator]()},n:function(){var e=o.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==o.return||o.return()}finally{if(a)throw i}}}}(e);try{for(n.s();!(t=n.n()).done;){var o=t.value;this.rgb.set(o.heapu8,o.start*this.frameWidth*3)}}catch(e){n.e(e)}finally{n.f()}this.eventsImpl.fireFrame(this.rgb)}},{key:"onSoundInit",value:function(e){this.freq=e}},{key:"onSoundPush",value:function(e){this.eventsImpl.fireSoundPush(e)}},{key:"onLog",value:function(e,t){this.eventsImpl.fireMessage("log","["+e+"]"+t)}},{key:"onWarn",value:function(e,t){this.eventsImpl.fireMessage("warn","["+e+"]"+t)}},{key:"onErr",value:function(e,t){"panic"===e?(this.panicMessages.push(t),console.error("["+e+"]"+t)):console.log("["+e+"]"+t),this.eventsImpl.fireMessage("error","["+e+"]"+t)}},{key:"onStdout",value:function(e){this.eventsImpl.fireStdout(e)}},{key:"config",value:function(){return this.configPromise}},{key:"width",value:function(){return this.frameWidth}},{key:"height",value:function(){return this.frameHeight}},{key:"soundFrequency",value:function(){return this.freq}},{key:"screenshot",value:function(){for(var e=new Uint8ClampedArray(this.rgb.length/3*4),t=0,n=0;n<e.length;)e[n++]=this.rgb[t++],e[n++]=this.rgb[t++],e[n++]=this.rgb[t++],e[n++]=255;return Promise.resolve(new ImageData(e,this.frameWidth,this.frameHeight))}},{key:"simulateKeyPress",value:function(){for(var e=this,t=Date.now()-this.startedAt,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];r.forEach((function(n){return e.addKey(n,!0,t)})),r.forEach((function(n){return e.addKey(n,!1,16+t)}))}},{key:"sendKeyEvent",value:function(e,t){this.addKey(e,t,Date.now()-this.startedAt)}},{key:"addKey",value:function(e,t,n){!0===this.keyMatrix[e]!==t&&(this.keyMatrix[e]=t,this.sendClientMessage("wc-add-key",{key:e,pressed:t,timeMs:n}))}},{key:"sendMouseMotion",value:function(e,t){this.sendClientMessage("wc-mouse-move",{x:e,y:t,relative:!1,timeMs:Date.now()-this.startedAt})}},{key:"sendMouseRelativeMotion",value:function(e,t){this.sendClientMessage("wc-mouse-move",{x:e,y:t,relative:!0,timeMs:Date.now()-this.startedAt})}},{key:"sendMouseButton",value:function(e,t){this.sendClientMessage("wc-mouse-button",{button:e,pressed:t,timeMs:Date.now()-this.startedAt})}},{key:"sendMouseSync",value:function(){this.sendClientMessage("wc-mouse-sync",{timeMs:Date.now()-this.startedAt})}},{key:"persist",value:function(){var e=this;if(void 0!==this.persistPromise)return this.persistPromise;var t=new Promise((function(t){return e.persistResolve=t}));return this.persistPromise=t,this.sendClientMessage("wc-pack-fs-to-bundle"),t}},{key:"onPersist",value:function(e){this.persistResolve&&(this.persistResolve(e),delete this.persistPromise,delete this.persistResolve)}},{key:"pause",value:function(){this.sendClientMessage("wc-pause")}},{key:"resume",value:function(){this.sendClientMessage("wc-resume")}},{key:"mute",value:function(){this.sendClientMessage("wc-mute")}},{key:"unmute",value:function(){this.sendClientMessage("wc-unmute")}},{key:"exit",value:function(){var e=this;return void 0!==this.exitPromise||(this.exitPromise=new Promise((function(t){return e.exitResolve=t})),this.exitPromise.then((function(){e.events().fireExit()})),this.resume(),this.sendClientMessage("wc-exit")),this.exitPromise}},{key:"onExit",value:function(){void 0!==this.transport.exit&&this.transport.exit(),this.exitResolve&&(this.exitResolve(),delete this.exitPromise,delete this.exitResolve)}},{key:"events",value:function(){return this.eventsImpl}},{key:"networkConnect",value:function(e,t,n){var r=this;return null!==this.connectPromise||null!==this.disconnectPromise?Promise.reject(new Error("Already prefoming connection or disconnection...")):(this.connectPromise=new Promise((function(o,i){t.startsWith("wss://")||t.startsWith("ws://")||(t=("http:"===window.location.protocol?"ws://":"wss://")+t),r.connectResolve=o,r.connectReject=i,r.sendClientMessage("wc-connect",{networkType:e,address:t,port:n})})),this.connectPromise)}},{key:"networkDisconnect",value:function(e){var t=this;return null!==this.connectPromise||null!==this.disconnectPromise?Promise.reject(new Error("Already prefoming connection or disconnection...")):(this.disconnectPromise=new Promise((function(n){t.disconnectResolve=n,t.sendClientMessage("wc-disconnect",{networkType:e})})),this.disconnectPromise)}}])&&o(t.prototype,n),e}();n.CommandInterfaceOverTransportLayer=s},{"../impl/ci-impl":137,"core-js/modules/es6.array.from":102,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.string.starts-with":121,"core-js/modules/es6.symbol":122,"core-js/modules/es6.typed.uint8-array":123,"core-js/modules/es6.typed.uint8-clamped-array":124,"core-js/modules/es7.symbol.async-iterator":126,"core-js/modules/web.dom.iterable":127}]},{},[135]),function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).zip={})}(this,(function(e){"use strict";const t=-2,n=-3,r=-5,o=[0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535],i=[96,7,256,0,8,80,0,8,16,84,8,115,82,7,31,0,8,112,0,8,48,0,9,192,80,7,10,0,8,96,0,8,32,0,9,160,0,8,0,0,8,128,0,8,64,0,9,224,80,7,6,0,8,88,0,8,24,0,9,144,83,7,59,0,8,120,0,8,56,0,9,208,81,7,17,0,8,104,0,8,40,0,9,176,0,8,8,0,8,136,0,8,72,0,9,240,80,7,4,0,8,84,0,8,20,85,8,227,83,7,43,0,8,116,0,8,52,0,9,200,81,7,13,0,8,100,0,8,36,0,9,168,0,8,4,0,8,132,0,8,68,0,9,232,80,7,8,0,8,92,0,8,28,0,9,152,84,7,83,0,8,124,0,8,60,0,9,216,82,7,23,0,8,108,0,8,44,0,9,184,0,8,12,0,8,140,0,8,76,0,9,248,80,7,3,0,8,82,0,8,18,85,8,163,83,7,35,0,8,114,0,8,50,0,9,196,81,7,11,0,8,98,0,8,34,0,9,164,0,8,2,0,8,130,0,8,66,0,9,228,80,7,7,0,8,90,0,8,26,0,9,148,84,7,67,0,8,122,0,8,58,0,9,212,82,7,19,0,8,106,0,8,42,0,9,180,0,8,10,0,8,138,0,8,74,0,9,244,80,7,5,0,8,86,0,8,22,192,8,0,83,7,51,0,8,118,0,8,54,0,9,204,81,7,15,0,8,102,0,8,38,0,9,172,0,8,6,0,8,134,0,8,70,0,9,236,80,7,9,0,8,94,0,8,30,0,9,156,84,7,99,0,8,126,0,8,62,0,9,220,82,7,27,0,8,110,0,8,46,0,9,188,0,8,14,0,8,142,0,8,78,0,9,252,96,7,256,0,8,81,0,8,17,85,8,131,82,7,31,0,8,113,0,8,49,0,9,194,80,7,10,0,8,97,0,8,33,0,9,162,0,8,1,0,8,129,0,8,65,0,9,226,80,7,6,0,8,89,0,8,25,0,9,146,83,7,59,0,8,121,0,8,57,0,9,210,81,7,17,0,8,105,0,8,41,0,9,178,0,8,9,0,8,137,0,8,73,0,9,242,80,7,4,0,8,85,0,8,21,80,8,258,83,7,43,0,8,117,0,8,53,0,9,202,81,7,13,0,8,101,0,8,37,0,9,170,0,8,5,0,8,133,0,8,69,0,9,234,80,7,8,0,8,93,0,8,29,0,9,154,84,7,83,0,8,125,0,8,61,0,9,218,82,7,23,0,8,109,0,8,45,0,9,186,0,8,13,0,8,141,0,8,77,0,9,250,80,7,3,0,8,83,0,8,19,85,8,195,83,7,35,0,8,115,0,8,51,0,9,198,81,7,11,0,8,99,0,8,35,0,9,166,0,8,3,0,8,131,0,8,67,0,9,230,80,7,7,0,8,91,0,8,27,0,9,150,84,7,67,0,8,123,0,8,59,0,9,214,82,7,19,0,8,107,0,8,43,0,9,182,0,8,11,0,8,139,0,8,75,0,9,246,80,7,5,0,8,87,0,8,23,192,8,0,83,7,51,0,8,119,0,8,55,0,9,206,81,7,15,0,8,103,0,8,39,0,9,174,0,8,7,0,8,135,0,8,71,0,9,238,80,7,9,0,8,95,0,8,31,0,9,158,84,7,99,0,8,127,0,8,63,0,9,222,82,7,27,0,8,111,0,8,47,0,9,190,0,8,15,0,8,143,0,8,79,0,9,254,96,7,256,0,8,80,0,8,16,84,8,115,82,7,31,0,8,112,0,8,48,0,9,193,80,7,10,0,8,96,0,8,32,0,9,161,0,8,0,0,8,128,0,8,64,0,9,225,80,7,6,0,8,88,0,8,24,0,9,145,83,7,59,0,8,120,0,8,56,0,9,209,81,7,17,0,8,104,0,8,40,0,9,177,0,8,8,0,8,136,0,8,72,0,9,241,80,7,4,0,8,84,0,8,20,85,8,227,83,7,43,0,8,116,0,8,52,0,9,201,81,7,13,0,8,100,0,8,36,0,9,169,0,8,4,0,8,132,0,8,68,0,9,233,80,7,8,0,8,92,0,8,28,0,9,153,84,7,83,0,8,124,0,8,60,0,9,217,82,7,23,0,8,108,0,8,44,0,9,185,0,8,12,0,8,140,0,8,76,0,9,249,80,7,3,0,8,82,0,8,18,85,8,163,83,7,35,0,8,114,0,8,50,0,9,197,81,7,11,0,8,98,0,8,34,0,9,165,0,8,2,0,8,130,0,8,66,0,9,229,80,7,7,0,8,90,0,8,26,0,9,149,84,7,67,0,8,122,0,8,58,0,9,213,82,7,19,0,8,106,0,8,42,0,9,181,0,8,10,0,8,138,0,8,74,0,9,245,80,7,5,0,8,86,0,8,22,192,8,0,83,7,51,0,8,118,0,8,54,0,9,205,81,7,15,0,8,102,0,8,38,0,9,173,0,8,6,0,8,134,0,8,70,0,9,237,80,7,9,0,8,94,0,8,30,0,9,157,84,7,99,0,8,126,0,8,62,0,9,221,82,7,27,0,8,110,0,8,46,0,9,189,0,8,14,0,8,142,0,8,78,0,9,253,96,7,256,0,8,81,0,8,17,85,8,131,82,7,31,0,8,113,0,8,49,0,9,195,80,7,10,0,8,97,0,8,33,0,9,163,0,8,1,0,8,129,0,8,65,0,9,227,80,7,6,0,8,89,0,8,25,0,9,147,83,7,59,0,8,121,0,8,57,0,9,211,81,7,17,0,8,105,0,8,41,0,9,179,0,8,9,0,8,137,0,8,73,0,9,243,80,7,4,0,8,85,0,8,21,80,8,258,83,7,43,0,8,117,0,8,53,0,9,203,81,7,13,0,8,101,0,8,37,0,9,171,0,8,5,0,8,133,0,8,69,0,9,235,80,7,8,0,8,93,0,8,29,0,9,155,84,7,83,0,8,125,0,8,61,0,9,219,82,7,23,0,8,109,0,8,45,0,9,187,0,8,13,0,8,141,0,8,77,0,9,251,80,7,3,0,8,83,0,8,19,85,8,195,83,7,35,0,8,115,0,8,51,0,9,199,81,7,11,0,8,99,0,8,35,0,9,167,0,8,3,0,8,131,0,8,67,0,9,231,80,7,7,0,8,91,0,8,27,0,9,151,84,7,67,0,8,123,0,8,59,0,9,215,82,7,19,0,8,107,0,8,43,0,9,183,0,8,11,0,8,139,0,8,75,0,9,247,80,7,5,0,8,87,0,8,23,192,8,0,83,7,51,0,8,119,0,8,55,0,9,207,81,7,15,0,8,103,0,8,39,0,9,175,0,8,7,0,8,135,0,8,71,0,9,239,80,7,9,0,8,95,0,8,31,0,9,159,84,7,99,0,8,127,0,8,63,0,9,223,82,7,27,0,8,111,0,8,47,0,9,191,0,8,15,0,8,143,0,8,79,0,9,255],s=[80,5,1,87,5,257,83,5,17,91,5,4097,81,5,5,89,5,1025,85,5,65,93,5,16385,80,5,3,88,5,513,84,5,33,92,5,8193,82,5,9,90,5,2049,86,5,129,192,5,24577,80,5,2,87,5,385,83,5,25,91,5,6145,81,5,7,89,5,1537,85,5,97,93,5,24577,80,5,4,88,5,769,84,5,49,92,5,12289,82,5,13,90,5,3073,86,5,193,192,5,24577],a=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],l=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,112,112],c=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577],u=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13];function d(){let e,t,o,i,s,d;function f(e,t,a,l,c,u,f,p,h,m,y){let v,g,b,_,w,x,k,j,C,D,E,S,O,P,B;D=0,w=a;do{o[e[t+D]]++,D++,w--}while(0!==w);if(o[0]==a)return f[0]=-1,p[0]=0,0;for(j=p[0],x=1;x<=15&&0===o[x];x++);for(k=x,j<x&&(j=x),w=15;0!==w&&0===o[w];w--);for(b=w,j>w&&(j=w),p[0]=j,P=1<<x;x<w;x++,P<<=1)if((P-=o[x])<0)return n;if((P-=o[w])<0)return n;for(o[w]+=P,d[1]=x=0,D=1,O=2;0!=--w;)d[O]=x+=o[D],O++,D++;w=0,D=0;do{0!==(x=e[t+D])&&(y[d[x]++]=w),D++}while(++w<a);for(a=d[b],d[0]=w=0,D=0,_=-1,S=-j,s[0]=0,E=0,B=0;k<=b;k++)for(v=o[k];0!=v--;){for(;k>S+j;){if(_++,S+=j,B=b-S,B=B>j?j:B,(g=1<<(x=k-S))>v+1&&(g-=v+1,O=k,x<B))for(;++x<B&&!((g<<=1)<=o[++O]);)g-=o[O];if(B=1<<x,m[0]+B>1440)return n;s[_]=E=m[0],m[0]+=B,0!==_?(d[_]=w,i[0]=x,i[1]=j,x=w>>>S-j,i[2]=E-s[_-1]-x,h.set(i,3*(s[_-1]+x))):f[0]=E}for(i[1]=k-S,D>=a?i[0]=192:y[D]<l?(i[0]=y[D]<256?0:96,i[2]=y[D++]):(i[0]=u[y[D]-l]+16+64,i[2]=c[y[D++]-l]),g=1<<k-S,x=w>>>S;x<B;x+=g)h.set(i,3*(E+x));for(x=1<<k-1;0!=(w&x);x>>>=1)w^=x;for(w^=x,C=(1<<S)-1;(w&C)!=d[_];)_--,S-=j,C=(1<<S)-1}return 0!==P&&1!=b?r:0}function p(n){let r;for(e||(e=[],t=[],o=new Int32Array(16),i=[],s=new Int32Array(15),d=new Int32Array(16)),t.length<n&&(t=[]),r=0;r<n;r++)t[r]=0;for(r=0;r<16;r++)o[r]=0;for(r=0;r<3;r++)i[r]=0;s.set(o.subarray(0,15),0),d.set(o.subarray(0,16),0)}this.inflate_trees_bits=function(o,i,s,a,l){let c;return p(19),e[0]=0,c=f(o,0,19,19,null,null,s,i,a,e,t),c==n?l.msg="oversubscribed dynamic bit lengths tree":c!=r&&0!==i[0]||(l.msg="incomplete dynamic bit lengths tree",c=n),c},this.inflate_trees_dynamic=function(o,i,s,d,h,m,y,v,g){let b;return p(288),e[0]=0,b=f(s,0,o,257,a,l,m,d,v,e,t),0!=b||0===d[0]?(b==n?g.msg="oversubscribed literal/length tree":-4!=b&&(g.msg="incomplete literal/length tree",b=n),b):(p(288),b=f(s,o,i,0,c,u,y,h,v,e,t),0!=b||0===h[0]&&o>257?(b==n?g.msg="oversubscribed distance tree":b==r?(g.msg="incomplete distance tree",b=n):-4!=b&&(g.msg="empty distance tree with lengths",b=n),b):0)}}function f(){const e=this;let r,i,s,a,l=0,c=0,u=0,d=0,f=0,p=0,h=0,m=0,y=0,v=0;function g(e,t,r,i,s,a,l,c){let u,d,f,p,h,m,y,v,g,b,_,w,x,k,j,C;y=c.next_in_index,v=c.avail_in,h=l.bitb,m=l.bitk,g=l.write,b=g<l.read?l.read-g-1:l.end-g,_=o[e],w=o[t];do{for(;m<20;)v--,h|=(255&c.read_byte(y++))<<m,m+=8;if(u=h&_,d=r,f=i,C=3*(f+u),0!==(p=d[C]))for(;;){if(h>>=d[C+1],m-=d[C+1],0!=(16&p)){for(p&=15,x=d[C+2]+(h&o[p]),h>>=p,m-=p;m<15;)v--,h|=(255&c.read_byte(y++))<<m,m+=8;for(u=h&w,d=s,f=a,C=3*(f+u),p=d[C];;){if(h>>=d[C+1],m-=d[C+1],0!=(16&p)){for(p&=15;m<p;)v--,h|=(255&c.read_byte(y++))<<m,m+=8;if(k=d[C+2]+(h&o[p]),h>>=p,m-=p,b-=x,g>=k)j=g-k,g-j>0&&2>g-j?(l.window[g++]=l.window[j++],l.window[g++]=l.window[j++],x-=2):(l.window.set(l.window.subarray(j,j+2),g),g+=2,j+=2,x-=2);else{j=g-k;do{j+=l.end}while(j<0);if(p=l.end-j,x>p){if(x-=p,g-j>0&&p>g-j)do{l.window[g++]=l.window[j++]}while(0!=--p);else l.window.set(l.window.subarray(j,j+p),g),g+=p,j+=p,p=0;j=0}}if(g-j>0&&x>g-j)do{l.window[g++]=l.window[j++]}while(0!=--x);else l.window.set(l.window.subarray(j,j+x),g),g+=x,j+=x,x=0;break}if(0!=(64&p))return c.msg="invalid distance code",x=c.avail_in-v,x=m>>3<x?m>>3:x,v+=x,y-=x,m-=x<<3,l.bitb=h,l.bitk=m,c.avail_in=v,c.total_in+=y-c.next_in_index,c.next_in_index=y,l.write=g,n;u+=d[C+2],u+=h&o[p],C=3*(f+u),p=d[C]}break}if(0!=(64&p))return 0!=(32&p)?(x=c.avail_in-v,x=m>>3<x?m>>3:x,v+=x,y-=x,m-=x<<3,l.bitb=h,l.bitk=m,c.avail_in=v,c.total_in+=y-c.next_in_index,c.next_in_index=y,l.write=g,1):(c.msg="invalid literal/length code",x=c.avail_in-v,x=m>>3<x?m>>3:x,v+=x,y-=x,m-=x<<3,l.bitb=h,l.bitk=m,c.avail_in=v,c.total_in+=y-c.next_in_index,c.next_in_index=y,l.write=g,n);if(u+=d[C+2],u+=h&o[p],C=3*(f+u),0===(p=d[C])){h>>=d[C+1],m-=d[C+1],l.window[g++]=d[C+2],b--;break}}else h>>=d[C+1],m-=d[C+1],l.window[g++]=d[C+2],b--}while(b>=258&&v>=10);return x=c.avail_in-v,x=m>>3<x?m>>3:x,v+=x,y-=x,m-=x<<3,l.bitb=h,l.bitk=m,c.avail_in=v,c.total_in+=y-c.next_in_index,c.next_in_index=y,l.write=g,0}e.init=function(e,t,n,o,l,c){r=0,h=e,m=t,s=n,y=o,a=l,v=c,i=null},e.proc=function(e,b,_){let w,x,k,j,C,D,E,S=0,O=0,P=0;for(P=b.next_in_index,j=b.avail_in,S=e.bitb,O=e.bitk,C=e.write,D=C<e.read?e.read-C-1:e.end-C;;)switch(r){case 0:if(D>=258&&j>=10&&(e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,_=g(h,m,s,y,a,v,e,b),P=b.next_in_index,j=b.avail_in,S=e.bitb,O=e.bitk,C=e.write,D=C<e.read?e.read-C-1:e.end-C,0!=_)){r=1==_?7:9;break}u=h,i=s,c=y,r=1;case 1:for(w=u;O<w;){if(0===j)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,j--,S|=(255&b.read_byte(P++))<<O,O+=8}if(x=3*(c+(S&o[w])),S>>>=i[x+1],O-=i[x+1],k=i[x],0===k){d=i[x+2],r=6;break}if(0!=(16&k)){f=15&k,l=i[x+2],r=2;break}if(0==(64&k)){u=k,c=x/3+i[x+2];break}if(0!=(32&k)){r=7;break}return r=9,b.msg="invalid literal/length code",_=n,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);case 2:for(w=f;O<w;){if(0===j)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,j--,S|=(255&b.read_byte(P++))<<O,O+=8}l+=S&o[w],S>>=w,O-=w,u=m,i=a,c=v,r=3;case 3:for(w=u;O<w;){if(0===j)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,j--,S|=(255&b.read_byte(P++))<<O,O+=8}if(x=3*(c+(S&o[w])),S>>=i[x+1],O-=i[x+1],k=i[x],0!=(16&k)){f=15&k,p=i[x+2],r=4;break}if(0==(64&k)){u=k,c=x/3+i[x+2];break}return r=9,b.msg="invalid distance code",_=n,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);case 4:for(w=f;O<w;){if(0===j)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,j--,S|=(255&b.read_byte(P++))<<O,O+=8}p+=S&o[w],S>>=w,O-=w,r=5;case 5:for(E=C-p;E<0;)E+=e.end;for(;0!==l;){if(0===D&&(C==e.end&&0!==e.read&&(C=0,D=C<e.read?e.read-C-1:e.end-C),0===D&&(e.write=C,_=e.inflate_flush(b,_),C=e.write,D=C<e.read?e.read-C-1:e.end-C,C==e.end&&0!==e.read&&(C=0,D=C<e.read?e.read-C-1:e.end-C),0===D)))return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);e.window[C++]=e.window[E++],D--,E==e.end&&(E=0),l--}r=0;break;case 6:if(0===D&&(C==e.end&&0!==e.read&&(C=0,D=C<e.read?e.read-C-1:e.end-C),0===D&&(e.write=C,_=e.inflate_flush(b,_),C=e.write,D=C<e.read?e.read-C-1:e.end-C,C==e.end&&0!==e.read&&(C=0,D=C<e.read?e.read-C-1:e.end-C),0===D)))return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,e.window[C++]=d,D--,r=0;break;case 7:if(O>7&&(O-=8,j++,P--),e.write=C,_=e.inflate_flush(b,_),C=e.write,D=C<e.read?e.read-C-1:e.end-C,e.read!=e.write)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);r=8;case 8:return _=1,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);case 9:return _=n,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);default:return _=t,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_)}},e.free=function(){}}d.inflate_trees_fixed=function(e,t,n,r){return e[0]=9,t[0]=5,n[0]=i,r[0]=s,0};const p=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];function h(e,i){const s=this;let a,l=0,c=0,u=0,h=0;const m=[0],y=[0],v=new f;let g=0,b=new Int32Array(4320);const _=new d;s.bitk=0,s.bitb=0,s.window=new Uint8Array(i),s.end=i,s.read=0,s.write=0,s.reset=function(e,t){t&&(t[0]=0),6==l&&v.free(e),l=0,s.bitk=0,s.bitb=0,s.read=s.write=0},s.reset(e,null),s.inflate_flush=function(e,t){let n,o,i;return o=e.next_out_index,i=s.read,n=(i<=s.write?s.write:s.end)-i,n>e.avail_out&&(n=e.avail_out),0!==n&&t==r&&(t=0),e.avail_out-=n,e.total_out+=n,e.next_out.set(s.window.subarray(i,i+n),o),o+=n,i+=n,i==s.end&&(i=0,s.write==s.end&&(s.write=0),n=s.write-i,n>e.avail_out&&(n=e.avail_out),0!==n&&t==r&&(t=0),e.avail_out-=n,e.total_out+=n,e.next_out.set(s.window.subarray(i,i+n),o),o+=n,i+=n),e.next_out_index=o,s.read=i,t},s.proc=function(e,r){let i,f,w,x,k,j,C,D;for(x=e.next_in_index,k=e.avail_in,f=s.bitb,w=s.bitk,j=s.write,C=j<s.read?s.read-j-1:s.end-j;;){let E,S,O,P,B,M,T,A;switch(l){case 0:for(;w<3;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}switch(i=7&f,g=1&i,i>>>1){case 0:f>>>=3,w-=3,i=7&w,f>>>=i,w-=i,l=1;break;case 1:E=[],S=[],O=[[]],P=[[]],d.inflate_trees_fixed(E,S,O,P),v.init(E[0],S[0],O[0],0,P[0],0),f>>>=3,w-=3,l=6;break;case 2:f>>>=3,w-=3,l=3;break;case 3:return f>>>=3,w-=3,l=9,e.msg="invalid block type",r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r)}break;case 1:for(;w<32;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}if((~f>>>16&65535)!=(65535&f))return l=9,e.msg="invalid stored block lengths",r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);c=65535&f,f=w=0,l=0!==c?2:0!==g?7:0;break;case 2:if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);if(0===C&&(j==s.end&&0!==s.read&&(j=0,C=j<s.read?s.read-j-1:s.end-j),0===C&&(s.write=j,r=s.inflate_flush(e,r),j=s.write,C=j<s.read?s.read-j-1:s.end-j,j==s.end&&0!==s.read&&(j=0,C=j<s.read?s.read-j-1:s.end-j),0===C)))return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);if(r=0,i=c,i>k&&(i=k),i>C&&(i=C),s.window.set(e.read_buf(x,i),j),x+=i,k-=i,j+=i,C-=i,0!=(c-=i))break;l=0!==g?7:0;break;case 3:for(;w<14;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}if(u=i=16383&f,(31&i)>29||(i>>5&31)>29)return l=9,e.msg="too many length or distance symbols",r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);if(i=258+(31&i)+(i>>5&31),!a||a.length<i)a=[];else for(D=0;D<i;D++)a[D]=0;f>>>=14,w-=14,h=0,l=4;case 4:for(;h<4+(u>>>10);){for(;w<3;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}a[p[h++]]=7&f,f>>>=3,w-=3}for(;h<19;)a[p[h++]]=0;if(m[0]=7,i=_.inflate_trees_bits(a,m,y,b,e),0!=i)return(r=i)==n&&(a=null,l=9),s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);h=0,l=5;case 5:for(;i=u,!(h>=258+(31&i)+(i>>5&31));){let t,c;for(i=m[0];w<i;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}if(i=b[3*(y[0]+(f&o[i]))+1],c=b[3*(y[0]+(f&o[i]))+2],c<16)f>>>=i,w-=i,a[h++]=c;else{for(D=18==c?7:c-14,t=18==c?11:3;w<i+D;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}if(f>>>=i,w-=i,t+=f&o[D],f>>>=D,w-=D,D=h,i=u,D+t>258+(31&i)+(i>>5&31)||16==c&&D<1)return a=null,l=9,e.msg="invalid bit length repeat",r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);c=16==c?a[D-1]:0;do{a[D++]=c}while(0!=--t);h=D}}if(y[0]=-1,B=[],M=[],T=[],A=[],B[0]=9,M[0]=6,i=u,i=_.inflate_trees_dynamic(257+(31&i),1+(i>>5&31),a,B,M,T,A,b,e),0!=i)return i==n&&(a=null,l=9),r=i,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);v.init(B[0],M[0],b,T[0],b,A[0]),l=6;case 6:if(s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,1!=(r=v.proc(s,e,r)))return s.inflate_flush(e,r);if(r=0,v.free(e),x=e.next_in_index,k=e.avail_in,f=s.bitb,w=s.bitk,j=s.write,C=j<s.read?s.read-j-1:s.end-j,0===g){l=0;break}l=7;case 7:if(s.write=j,r=s.inflate_flush(e,r),j=s.write,C=j<s.read?s.read-j-1:s.end-j,s.read!=s.write)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);l=8;case 8:return r=1,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);case 9:return r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);default:return r=t,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r)}}},s.free=function(e){s.reset(e,null),s.window=null,b=null},s.set_dictionary=function(e,t,n){s.window.set(e.subarray(t,t+n),0),s.read=s.write=n},s.sync_point=function(){return 1==l?1:0}}const m=13,y=[0,0,255,255];function v(){const e=this;function o(e){return e&&e.istate?(e.total_in=e.total_out=0,e.msg=null,e.istate.mode=7,e.istate.blocks.reset(e,null),0):t}e.mode=0,e.method=0,e.was=[0],e.need=0,e.marker=0,e.wbits=0,e.inflateEnd=function(t){return e.blocks&&e.blocks.free(t),e.blocks=null,0},e.inflateInit=function(n,r){return n.msg=null,e.blocks=null,r<8||r>15?(e.inflateEnd(n),t):(e.wbits=r,n.istate.blocks=new h(n,1<<r),o(n),0)},e.inflate=function(e,o){let i,s;if(!e||!e.istate||!e.next_in)return t;const a=e.istate;for(o=4==o?r:0,i=r;;)switch(a.mode){case 0:if(0===e.avail_in)return i;if(i=o,e.avail_in--,e.total_in++,8!=(15&(a.method=e.read_byte(e.next_in_index++)))){a.mode=m,e.msg="unknown compression method",a.marker=5;break}if(8+(a.method>>4)>a.wbits){a.mode=m,e.msg="invalid window size",a.marker=5;break}a.mode=1;case 1:if(0===e.avail_in)return i;if(i=o,e.avail_in--,e.total_in++,s=255&e.read_byte(e.next_in_index++),((a.method<<8)+s)%31!=0){a.mode=m,e.msg="incorrect header check",a.marker=5;break}if(0==(32&s)){a.mode=7;break}a.mode=2;case 2:if(0===e.avail_in)return i;i=o,e.avail_in--,e.total_in++,a.need=(255&e.read_byte(e.next_in_index++))<<24&4278190080,a.mode=3;case 3:if(0===e.avail_in)return i;i=o,e.avail_in--,e.total_in++,a.need+=(255&e.read_byte(e.next_in_index++))<<16&16711680,a.mode=4;case 4:if(0===e.avail_in)return i;i=o,e.avail_in--,e.total_in++,a.need+=(255&e.read_byte(e.next_in_index++))<<8&65280,a.mode=5;case 5:return 0===e.avail_in?i:(i=o,e.avail_in--,e.total_in++,a.need+=255&e.read_byte(e.next_in_index++),a.mode=6,2);case 6:return a.mode=m,e.msg="need dictionary",a.marker=0,t;case 7:if(i=a.blocks.proc(e,i),i==n){a.mode=m,a.marker=0;break}if(0==i&&(i=o),1!=i)return i;i=o,a.blocks.reset(e,a.was),a.mode=12;case 12:return 1;case m:return n;default:return t}},e.inflateSetDictionary=function(e,n,r){let o=0,i=r;if(!e||!e.istate||6!=e.istate.mode)return t;const s=e.istate;return i>=1<<s.wbits&&(i=(1<<s.wbits)-1,o=r-i),s.blocks.set_dictionary(n,o,i),s.mode=7,0},e.inflateSync=function(e){let i,s,a,l,c;if(!e||!e.istate)return t;const u=e.istate;if(u.mode!=m&&(u.mode=m,u.marker=0),0===(i=e.avail_in))return r;for(s=e.next_in_index,a=u.marker;0!==i&&a<4;)e.read_byte(s)==y[a]?a++:a=0!==e.read_byte(s)?0:4-a,s++,i--;return e.total_in+=s-e.next_in_index,e.next_in_index=s,e.avail_in=i,u.marker=a,4!=a?n:(l=e.total_in,c=e.total_out,o(e),e.total_in=l,e.total_out=c,u.mode=7,0)},e.inflateSyncPoint=function(e){return e&&e.istate&&e.istate.blocks?e.istate.blocks.sync_point():t}}function g(){}g.prototype={inflateInit:function(e){const t=this;return t.istate=new v,e||(e=15),t.istate.inflateInit(t,e)},inflate:function(e){const n=this;return n.istate?n.istate.inflate(n,e):t},inflateEnd:function(){const e=this;if(!e.istate)return t;const n=e.istate.inflateEnd(e);return e.istate=null,n},inflateSync:function(){const e=this;return e.istate?e.istate.inflateSync(e):t},inflateSetDictionary:function(e,n){const r=this;return r.istate?r.istate.inflateSetDictionary(r,e,n):t},read_byte:function(e){return this.next_in[e]},read_buf:function(e,t){return this.next_in.subarray(e,e+t)}};const b={chunkSize:524288,maxWorkers:"undefined"!=typeof navigator&&navigator.hardwareConcurrency||2,terminateWorkerTimeout:5e3,useWebWorkers:!0,workerScripts:void 0},_=Object.assign({},b);function w(e){if(void 0!==e.chunkSize&&(_.chunkSize=e.chunkSize),void 0!==e.maxWorkers&&(_.maxWorkers=e.maxWorkers),void 0!==e.terminateWorkerTimeout&&(_.terminateWorkerTimeout=e.terminateWorkerTimeout),void 0!==e.useWebWorkers&&(_.useWebWorkers=e.useWebWorkers),void 0!==e.Deflate&&(_.Deflate=e.Deflate),void 0!==e.Inflate&&(_.Inflate=e.Inflate),void 0!==e.workerScripts){if(e.workerScripts.deflate){if(!Array.isArray(e.workerScripts.deflate))throw new Error("workerScripts.deflate must be an array");_.workerScripts||(_.workerScripts={}),_.workerScripts.deflate=e.workerScripts.deflate}if(e.workerScripts.inflate){if(!Array.isArray(e.workerScripts.inflate))throw new Error("workerScripts.inflate must be an array");_.workerScripts||(_.workerScripts={}),_.workerScripts.inflate=e.workerScripts.inflate}}}const x="Abort error";function k(e,t){if(e&&e.aborted)throw t.flush(),new Error(x)}async function j(e,t){return t.length&&await e.writeUint8Array(t),t.length}const C="HTTP error ",D="HTTP Range not supported",E="text/plain",S="Content-Length",O="Accept-Ranges",P="HEAD",B="GET",M="bytes";class T{constructor(){this.size=0}init(){this.initialized=!0}}class A extends T{}class I extends T{writeUint8Array(e){this.size+=e.length}}class K extends A{constructor(e){super(),this.blob=e,this.size=e.size}async readUint8Array(e,t){const n=new FileReader;return new Promise(((r,o)=>{n.onload=e=>r(new Uint8Array(e.target.result)),n.onerror=()=>o(n.error),n.readAsArrayBuffer(this.blob.slice(e,e+t))}))}}class L extends A{constructor(e,t){super(),this.url=e,this.preventHeadRequest=t.preventHeadRequest,this.useRangeHeader=t.useRangeHeader,this.forceRangeRequests=t.forceRangeRequests,this.options=Object.assign({},t),delete this.options.preventHeadRequest,delete this.options.useRangeHeader,delete this.options.forceRangeRequests,delete this.options.useXHR}async init(){if(super.init(),W(this.url)&&!this.preventHeadRequest){const e=await N(P,this.url,this.options);if(this.size=Number(e.headers.get(S)),!this.forceRangeRequests&&this.useRangeHeader&&e.headers.get(O)!=M)throw new Error(D);void 0===this.size&&await R(this,this.options)}else await R(this,this.options)}async readUint8Array(e,t){if(this.useRangeHeader){const n=await N(B,this.url,this.options,Object.assign({},this.options.headers,{HEADER_RANGE:"bytes="+e+"-"+(e+t-1)}));if(206!=n.status)throw new Error(D);return new Uint8Array(await n.arrayBuffer())}return this.data||await R(this,this.options),new Uint8Array(this.data.subarray(e,e+t))}}async function R(e,t){const n=await N(B,e.url,t);e.data=new Uint8Array(await n.arrayBuffer()),e.size||(e.size=e.data.length)}async function N(e,t,n,r){r=Object.assign({},n.headers,r);const o=await fetch(t,Object.assign({},n,{method:e,headers:r}));if(o.status<400)return o;throw new Error(C+(o.statusText||o.status))}class F extends A{constructor(e,t){super(),this.url=e,this.preventHeadRequest=t.preventHeadRequest,this.useRangeHeader=t.useRangeHeader,this.forceRangeRequests=t.forceRangeRequests}async init(){if(super.init(),W(this.url)&&!this.preventHeadRequest)return new Promise(((e,t)=>z(P,this.url,(n=>{this.size=Number(n.getResponseHeader(S)),this.useRangeHeader?this.forceRangeRequests||n.getResponseHeader(O)==M?e():t(new Error(D)):void 0===this.size?U(this,this.url).then((()=>e())).catch(t):e()}),t)));await U(this,this.url)}async readUint8Array(e,t){if(!this.useRangeHeader)return this.data||await U(this,this.url),new Uint8Array(this.data.subarray(e,e+t));if(206!=(await new Promise(((n,r)=>z(B,this.url,(e=>n(new Uint8Array(e.response))),r,[["Range","bytes="+e+"-"+(e+t-1)]])))).status)throw new Error(D)}}function U(e,t){return new Promise(((n,r)=>z(B,t,(t=>{e.data=new Uint8Array(t.response),e.size||(e.size=e.data.length),n()}),r)))}function z(e,t,n,r,o=[]){const i=new XMLHttpRequest;return i.addEventListener("load",(()=>{i.status<400?n(i):r(C+(i.statusText||i.status))}),!1),i.addEventListener("error",r,!1),i.open(e,t),o.forEach((e=>i.setRequestHeader(e[0],e[1]))),i.responseType="arraybuffer",i.send(),i}class H extends A{constructor(e,t={}){super(),this.url=e,t.useXHR?this.reader=new F(e,t):this.reader=new L(e,t)}set size(e){}get size(){return this.reader.size}async init(){super.init(),await this.reader.init()}async readUint8Array(e,t){return this.reader.readUint8Array(e,t)}}function W(e){if("undefined"!=typeof document){const t=document.createElement("a");return t.href=e,"http:"==t.protocol||"https:"==t.protocol}return/^https?:\/\//i.test(e)}const q=4294967295,V=33639248,G=101075792,Y="\0☺☻♥♦♣♠•◘○◙♂♀♪♫☼►◄↕‼¶§▬↨↑↓→←∟↔▲▼ !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~⌂ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜ¢£¥₧ƒáíóúñѪº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ ".split(""),X=[];for(let e=0;e<256;e++){let t=e;for(let e=0;e<8;e++)1&t?t=t>>>1^3988292384:t>>>=1;X[e]=t}class ${constructor(e){this.crc=e||-1}append(e){let t=0|this.crc;for(let n=0,r=0|e.length;n<r;n++)t=t>>>8^X[255&(t^e[n])];this.crc=t}get(){return~this.crc}}const J={concat(e,t){if(0===e.length||0===t.length)return e.concat(t);const n=e[e.length-1],r=J.getPartial(n);return 32===r?e.concat(t):J._shiftRight(t,r,0|n,e.slice(0,e.length-1))},bitLength(e){const t=e.length;if(0===t)return 0;const n=e[t-1];return 32*(t-1)+J.getPartial(n)},clamp(e,t){if(32*e.length<t)return e;const n=(e=e.slice(0,Math.ceil(t/32))).length;return t&=31,n>0&&t&&(e[n-1]=J.partial(t,e[n-1]&2147483648>>t-1,1)),e},partial:(e,t,n)=>32===e?t:(n?0|t:t<<32-e)+1099511627776*e,getPartial:e=>Math.round(e/1099511627776)||32,_shiftRight(e,t,n,r){for(void 0===r&&(r=[]);t>=32;t-=32)r.push(n),n=0;if(0===t)return r.concat(e);for(let o=0;o<e.length;o++)r.push(n|e[o]>>>t),n=e[o]<<32-t;const o=e.length?e[e.length-1]:0,i=J.getPartial(o);return r.push(J.partial(t+i&31,t+i>32?n:r.pop(),1)),r}},Q={bytes:{fromBits(e){const t=J.bitLength(e)/8,n=new Uint8Array(t);let r;for(let o=0;o<t;o++)0==(3&o)&&(r=e[o/4]),n[o]=r>>>24,r<<=8;return n},toBits(e){const t=[];let n,r=0;for(n=0;n<e.length;n++)r=r<<8|e[n],3==(3&n)&&(t.push(r),r=0);return 3&n&&t.push(J.partial(8*(3&n),r)),t}}},Z={sha1:function(e){e?(this._h=e._h.slice(0),this._buffer=e._buffer.slice(0),this._length=e._length):this.reset()}};Z.sha1.prototype={blockSize:512,reset:function(){const e=this;return e._h=this._init.slice(0),e._buffer=[],e._length=0,e},update:function(e){const t=this;"string"==typeof e&&(e=Q.utf8String.toBits(e));const n=t._buffer=J.concat(t._buffer,e),r=t._length,o=t._length=r+J.bitLength(e);if(o>9007199254740991)throw new Error("Cannot hash more than 2^53 - 1 bits");const i=new Uint32Array(n);let s=0;for(let e=t.blockSize+r-(t.blockSize+r&t.blockSize-1);e<=o;e+=t.blockSize)t._block(i.subarray(16*s,16*(s+1))),s+=1;return n.splice(0,16*s),t},finalize:function(){const e=this;let t=e._buffer;const n=e._h;t=J.concat(t,[J.partial(1,1)]);for(let e=t.length+2;15&e;e++)t.push(0);for(t.push(Math.floor(e._length/4294967296)),t.push(0|e._length);t.length;)e._block(t.splice(0,16));return e.reset(),n},_init:[1732584193,4023233417,2562383102,271733878,3285377520],_key:[1518500249,1859775393,2400959708,3395469782],_f:function(e,t,n,r){return e<=19?t&n|~t&r:e<=39?t^n^r:e<=59?t&n|t&r|n&r:e<=79?t^n^r:void 0},_S:function(e,t){return t<<e|t>>>32-e},_block:function(e){const t=this,n=t._h,r=Array(80);for(let t=0;t<16;t++)r[t]=e[t];let o=n[0],i=n[1],s=n[2],a=n[3],l=n[4];for(let e=0;e<=79;e++){e>=16&&(r[e]=t._S(1,r[e-3]^r[e-8]^r[e-14]^r[e-16]));const n=t._S(5,o)+t._f(e,i,s,a)+l+r[e]+t._key[Math.floor(e/20)]|0;l=a,a=s,s=t._S(30,i),i=o,o=n}n[0]=n[0]+o|0,n[1]=n[1]+i|0,n[2]=n[2]+s|0,n[3]=n[3]+a|0,n[4]=n[4]+l|0}};const ee=class{constructor(e){const t=this;t._tables=[[[],[],[],[],[]],[[],[],[],[],[]]],t._tables[0][0][0]||t._precompute();const n=t._tables[0][4],r=t._tables[1],o=e.length;let i,s,a,l=1;if(4!==o&&6!==o&&8!==o)throw new Error("invalid aes key size");for(t._key=[s=e.slice(0),a=[]],i=o;i<4*o+28;i++){let e=s[i-1];(i%o==0||8===o&&i%o==4)&&(e=n[e>>>24]<<24^n[e>>16&255]<<16^n[e>>8&255]<<8^n[255&e],i%o==0&&(e=e<<8^e>>>24^l<<24,l=l<<1^283*(l>>7))),s[i]=s[i-o]^e}for(let e=0;i;e++,i--){const t=s[3&e?i:i-4];a[e]=i<=4||e<4?t:r[0][n[t>>>24]]^r[1][n[t>>16&255]]^r[2][n[t>>8&255]]^r[3][n[255&t]]}}encrypt(e){return this._crypt(e,0)}decrypt(e){return this._crypt(e,1)}_precompute(){const e=this._tables[0],t=this._tables[1],n=e[4],r=t[4],o=[],i=[];let s,a,l,c;for(let e=0;e<256;e++)i[(o[e]=e<<1^283*(e>>7))^e]=e;for(let u=s=0;!n[u];u^=a||1,s=i[s]||1){let i=s^s<<1^s<<2^s<<3^s<<4;i=i>>8^255&i^99,n[u]=i,r[i]=u,c=o[l=o[a=o[u]]];let d=16843009*c^65537*l^257*a^16843008*u,f=257*o[i]^16843008*i;for(let n=0;n<4;n++)e[n][u]=f=f<<24^f>>>8,t[n][i]=d=d<<24^d>>>8}for(let n=0;n<5;n++)e[n]=e[n].slice(0),t[n]=t[n].slice(0)}_crypt(e,t){if(4!==e.length)throw new Error("invalid aes block size");const n=this._key[t],r=n.length/4-2,o=[0,0,0,0],i=this._tables[t],s=i[0],a=i[1],l=i[2],c=i[3],u=i[4];let d,f,p,h=e[0]^n[0],m=e[t?3:1]^n[1],y=e[2]^n[2],v=e[t?1:3]^n[3],g=4;for(let e=0;e<r;e++)d=s[h>>>24]^a[m>>16&255]^l[y>>8&255]^c[255&v]^n[g],f=s[m>>>24]^a[y>>16&255]^l[v>>8&255]^c[255&h]^n[g+1],p=s[y>>>24]^a[v>>16&255]^l[h>>8&255]^c[255&m]^n[g+2],v=s[v>>>24]^a[h>>16&255]^l[m>>8&255]^c[255&y]^n[g+3],g+=4,h=d,m=f,y=p;for(let e=0;e<4;e++)o[t?3&-e:e]=u[h>>>24]<<24^u[m>>16&255]<<16^u[y>>8&255]<<8^u[255&v]^n[g++],d=h,h=m,m=y,y=v,v=d;return o}},te=class{constructor(e,t){this._prf=e,this._initIv=t,this._iv=t}reset(){this._iv=this._initIv}update(e){return this.calculate(this._prf,e,this._iv)}incWord(e){if(255==(e>>24&255)){let t=e>>16&255,n=e>>8&255,r=255&e;255===t?(t=0,255===n?(n=0,255===r?r=0:++r):++n):++t,e=0,e+=t<<16,e+=n<<8,e+=r}else e+=1<<24;return e}incCounter(e){0===(e[0]=this.incWord(e[0]))&&(e[1]=this.incWord(e[1]))}calculate(e,t,n){let r;if(!(r=t.length))return[];const o=J.bitLength(t);for(let o=0;o<r;o+=4){this.incCounter(n);const r=e.encrypt(n);t[o]^=r[0],t[o+1]^=r[1],t[o+2]^=r[2],t[o+3]^=r[3]}return J.clamp(t,o)}},ne=class{constructor(e){const t=this,n=t._hash=Z.sha1,r=[[],[]],o=n.prototype.blockSize/32;t._baseHash=[new n,new n],e.length>o&&(e=n.hash(e));for(let t=0;t<o;t++)r[0][t]=909522486^e[t],r[1][t]=1549556828^e[t];t._baseHash[0].update(r[0]),t._baseHash[1].update(r[1]),t._resultHash=new n(t._baseHash[0])}reset(){const e=this;e._resultHash=new e._hash(e._baseHash[0]),e._updated=!1}update(e){this._updated=!0,this._resultHash.update(e)}digest(){const e=this,t=e._resultHash.finalize(),n=new e._hash(e._baseHash[1]).update(t).finalize();return e.reset(),n}},re="Invalid pasword",oe=16,ie={name:"PBKDF2"},se=Object.assign({hash:{name:"HMAC"}},ie),ae=Object.assign({iterations:1e3,hash:{name:"SHA-1"}},ie),le=["deriveBits"],ce=[8,12,16],ue=[16,24,32],de=10,fe=[0,0,0,0],pe=Q.bytes,he=ee,me=te,ye=ne;class ve{constructor(e,t,n){Object.assign(this,{password:e,signed:t,strength:n-1,pendingInput:new Uint8Array(0)})}async append(e){const t=this;if(t.password){const n=xe(e,0,ce[t.strength]+2);await async function(e,t,n){await _e(e,n,xe(t,0,ce[e.strength]));const r=xe(t,ce[e.strength]),o=e.keys.passwordVerification;if(o[0]!=r[0]||o[1]!=r[1])throw new Error(re)}(t,n,t.password),t.password=null,t.aesCtrGladman=new me(new he(t.keys.key),Array.from(fe)),t.hmac=new ye(t.keys.authentication),e=xe(e,ce[t.strength]+2)}return be(t,e,new Uint8Array(e.length-de-(e.length-de)%oe),0,de,!0)}flush(){const e=this,t=e.pendingInput,n=xe(t,0,t.length-de),r=xe(t,t.length-de);let o=new Uint8Array(0);if(n.length){const t=pe.toBits(n);e.hmac.update(t);const r=e.aesCtrGladman.update(t);o=pe.fromBits(r)}let i=!0;if(e.signed){const t=xe(pe.fromBits(e.hmac.digest()),0,de);for(let e=0;e<de;e++)t[e]!=r[e]&&(i=!1)}return{valid:i,data:o}}}class ge{constructor(e,t){Object.assign(this,{password:e,strength:t-1,pendingInput:new Uint8Array(0)})}async append(e){const t=this;let n=new Uint8Array(0);t.password&&(n=await async function(e,t){const n=crypto.getRandomValues(new Uint8Array(ce[e.strength]));return await _e(e,t,n),we(n,e.keys.passwordVerification)}(t,t.password),t.password=null,t.aesCtrGladman=new me(new he(t.keys.key),Array.from(fe)),t.hmac=new ye(t.keys.authentication));const r=new Uint8Array(n.length+e.length-e.length%oe);return r.set(n,0),be(t,e,r,n.length,0)}flush(){const e=this;let t=new Uint8Array(0);if(e.pendingInput.length){const n=e.aesCtrGladman.update(pe.toBits(e.pendingInput));e.hmac.update(n),t=pe.fromBits(n)}const n=xe(pe.fromBits(e.hmac.digest()),0,de);return{data:we(t,n),signature:n}}}function be(e,t,n,r,o,i){const s=t.length-o;let a;for(e.pendingInput.length&&(t=we(e.pendingInput,t),n=function(e,t){if(t&&t>e.length){const n=e;(e=new Uint8Array(t)).set(n,0)}return e}(n,s-s%oe)),a=0;a<=s-oe;a+=oe){const o=pe.toBits(xe(t,a,a+oe));i&&e.hmac.update(o);const s=e.aesCtrGladman.update(o);i||e.hmac.update(s),n.set(pe.fromBits(s),a+r)}return e.pendingInput=xe(t,a),n}async function _e(e,t,n){const r=(new TextEncoder).encode(t),o=await crypto.subtle.importKey("raw",r,se,!1,le),i=await crypto.subtle.deriveBits(Object.assign({salt:n},ae),o,8*(2*ue[e.strength]+2)),s=new Uint8Array(i);e.keys={key:pe.toBits(xe(s,0,ue[e.strength])),authentication:pe.toBits(xe(s,ue[e.strength],2*ue[e.strength])),passwordVerification:xe(s,2*ue[e.strength])}}function we(e,t){let n=e;return e.length+t.length&&(n=new Uint8Array(e.length+t.length),n.set(e,0),n.set(t,e.length)),n}function xe(e,t,n){return e.subarray(t,n)}class ke{constructor(e,t){Object.assign(this,{password:e,passwordVerification:t}),Ee(this,e)}append(e){const t=this;if(t.password){const n=Ce(t,e.subarray(0,12));if(t.password=null,n[11]!=t.passwordVerification)throw new Error(re);e=e.subarray(12)}return Ce(t,e)}flush(){return{valid:!0,data:new Uint8Array(0)}}}class je{constructor(e,t){Object.assign(this,{password:e,passwordVerification:t}),Ee(this,e)}append(e){const t=this;let n,r;if(t.password){t.password=null;const o=crypto.getRandomValues(new Uint8Array(12));o[11]=t.passwordVerification,n=new Uint8Array(e.length+o.length),n.set(De(t,o),0),r=12}else n=new Uint8Array(e.length),r=0;return n.set(De(t,e),r),n}flush(){return{data:new Uint8Array(0)}}}function Ce(e,t){const n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=Oe(e)^t[r],Se(e,n[r]);return n}function De(e,t){const n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=Oe(e)^t[r],Se(e,t[r]);return n}function Ee(e,t){e.keys=[305419896,591751049,878082192],e.crcKey0=new $(e.keys[0]),e.crcKey2=new $(e.keys[2]);for(let n=0;n<t.length;n++)Se(e,t.charCodeAt(n))}function Se(e,t){e.crcKey0.append([t]),e.keys[0]=~e.crcKey0.get(),e.keys[1]=Be(e.keys[1]+Pe(e.keys[0])),e.keys[1]=Be(Math.imul(e.keys[1],134775813)+1),e.crcKey2.append([e.keys[1]>>>24]),e.keys[2]=~e.crcKey2.get()}function Oe(e){const t=2|e.keys[2];return Pe(Math.imul(t,1^t)>>>8)}function Pe(e){return 255&e}function Be(e){return 4294967295&e}const Me="inflate",Te="Invalid signature";class Ae{constructor(e,{signature:t,password:n,signed:r,compressed:o,zipCrypto:i,passwordVerification:s,encryptionStrength:a},{chunkSize:l}){const c=Boolean(n);Object.assign(this,{signature:t,encrypted:c,signed:r,compressed:o,inflate:o&&new e({chunkSize:l}),crc32:r&&new $,zipCrypto:i,decrypt:c&&i?new ke(n,s):new ve(n,r,a)})}async append(e){const t=this;return t.encrypted&&e.length&&(e=await t.decrypt.append(e)),t.compressed&&e.length&&(e=await t.inflate.append(e)),(!t.encrypted||t.zipCrypto)&&t.signed&&e.length&&t.crc32.append(e),e}async flush(){const e=this;let t,n=new Uint8Array(0);if(e.encrypted){const t=e.decrypt.flush();if(!t.valid)throw new Error(Te);n=t.data}if((!e.encrypted||e.zipCrypto)&&e.signed){const n=new DataView(new Uint8Array(4).buffer);if(t=e.crc32.get(),n.setUint32(0,t),e.signature!=n.getUint32(0,!1))throw new Error(Te)}return e.compressed&&(n=await e.inflate.append(n)||new Uint8Array(0),await e.inflate.flush()),{data:n,signature:t}}}class Ie{constructor(e,{encrypted:t,signed:n,compressed:r,level:o,zipCrypto:i,password:s,passwordVerification:a,encryptionStrength:l},{chunkSize:c}){Object.assign(this,{encrypted:t,signed:n,compressed:r,deflate:r&&new e({level:o||5,chunkSize:c}),crc32:n&&new $,zipCrypto:i,encrypt:t&&i?new je(s,a):new ge(s,l)})}async append(e){const t=this;let n=e;return t.compressed&&e.length&&(n=await t.deflate.append(e)),t.encrypted&&n.length&&(n=await t.encrypt.append(n)),(!t.encrypted||t.zipCrypto)&&t.signed&&e.length&&t.crc32.append(e),n}async flush(){const e=this;let t,n=new Uint8Array(0);if(e.compressed&&(n=await e.deflate.flush()||new Uint8Array(0)),e.encrypted){n=await e.encrypt.append(n);const r=e.encrypt.flush();t=r.signature;const o=new Uint8Array(n.length+r.data.length);o.set(n,0),o.set(r.data,n.length),n=o}return e.encrypted&&!e.zipCrypto||!e.signed||(t=e.crc32.get()),{data:n,signature:t}}}const Ke="init",Le="append",Re="flush";let Ne=!0;var Fe=(e,t,n,r,o,i,s)=>(Object.assign(e,{busy:!0,codecConstructor:t,options:Object.assign({},n),scripts:s,terminate(){e.worker&&!e.busy&&(e.worker.terminate(),e.interface=null)},onTaskFinished(){e.busy=!1,o(e)}}),i?function(e,t){let n;const r={type:"module"};if(!e.interface){if(Ne)try{e.worker=o()}catch(t){Ne=!1,e.worker=o(r)}else e.worker=o(r);e.worker.addEventListener("message",(function(t){const r=t.data;if(n){const t=r.error,o=r.type;if(t){const r=new Error(t.message);r.stack=t.stack,n.reject(r),n=null,e.onTaskFinished()}else if(o==Ke||o==Re||o==Le){const t=r.data;o==Re?(n.resolve({data:new Uint8Array(t),signature:r.signature}),n=null,e.onTaskFinished()):n.resolve(t&&new Uint8Array(t))}}}),!1),e.interface={append:e=>i({type:Le,data:e}),flush:()=>i({type:Re})}}return e.interface;function o(t={}){return new Worker(new URL(e.scripts[0],"undefined"==typeof document&&"undefined"==typeof location?new(require("url").URL)("file:"+__filename).href:"undefined"==typeof document?location.href:document.currentScript&&document.currentScript.src||new URL("zip-no-worker-inflate.min.js",document.baseURI).href),t)}async function i(r){if(!n){const n=e.options,r=e.scripts.slice(1);await s({scripts:r,type:Ke,options:n,config:{chunkSize:t.chunkSize}})}return s(r)}function s(t){const r=e.worker,o=new Promise(((e,t)=>n={resolve:e,reject:t}));try{if(t.data)try{t.data=t.data.buffer,r.postMessage(t,[t.data])}catch(e){r.postMessage(t)}else r.postMessage(t)}catch(t){n.reject(t),n=null,e.onTaskFinished()}return o}}(e,r):function(e,t){const n=function(e,t,n){return t.codecType.startsWith("deflate")?new Ie(e,t,n):t.codecType.startsWith(Me)?new Ae(e,t,n):void 0}(e.codecConstructor,e.options,t);return{async append(t){try{return await n.append(t)}catch(t){throw e.onTaskFinished(),t}},async flush(){try{return await n.flush()}finally{e.onTaskFinished()}}}}(e,r));let Ue=[],ze=[];function He(e){e.terminateTimeout&&(clearTimeout(e.terminateTimeout),e.terminateTimeout=null)}const We=["filename","rawFilename","directory","encrypted","compressedSize","uncompressedSize","lastModDate","rawLastModDate","comment","rawComment","signature","extraField","rawExtraField","bitFlag","extraFieldZip64","extraFieldUnicodePath","extraFieldUnicodeComment","extraFieldAES","filenameUTF8","commentUTF8","offset","zip64","compressionMethod","extraFieldNTFS","lastAccessDate","creationDate","extraFieldExtendedTimestamp","version","versionMadeBy","msDosCompatible","internalFileAttribute","externalFileAttribute"];class qe{constructor(e){We.forEach((t=>this[t]=e[t]))}}const Ve="File format is not recognized",Ge="End of central directory not found",Ye="End of Zip64 central directory not found",Xe="End of Zip64 central directory locator not found",$e="Central directory header not found",Je="Local file header not found",Qe="Zip64 extra field not found",Ze="File contains encrypted entry",et="Encryption method not supported",tt="Compression method not supported",nt="utf-8",rt=["uncompressedSize","compressedSize","offset"];class ot{constructor(e,t,n){Object.assign(this,{reader:e,config:t,options:n})}async getData(e,t,n={}){const r=this,{reader:o,offset:i,extraFieldAES:s,compressionMethod:a,config:l,bitFlag:c,signature:u,rawLastModDate:d,compressedSize:f}=r,p=r.localDirectory={};o.initialized||await o.init();let h=await vt(o,i,30);const m=yt(h);let y=lt(r,n,"password");if(y=y&&y.length&&y,s&&99!=s.originalCompressionMethod)throw new Error(tt);if(0!=a&&8!=a)throw new Error(tt);if(67324752!=ht(m,0))throw new Error(Je);it(p,m,4),h=await vt(o,i,30+p.filenameLength+p.extraFieldLength),p.rawExtraField=h.subarray(30+p.filenameLength),st(r,p,m,4),t.lastAccessDate=p.lastAccessDate,t.creationDate=p.creationDate;const v=r.encrypted&&p.encrypted,g=v&&!s;if(v){if(!g&&void 0===s.strength)throw new Error(et);if(!y)throw new Error(Ze)}const b=await function(e,t,n){const r=!(!t.compressed&&!t.signed&&!t.encrypted)&&(t.useWebWorkers||void 0===t.useWebWorkers&&n.useWebWorkers),o=r&&n.workerScripts?n.workerScripts[t.codecType]:[];if(Ue.length<n.maxWorkers){const s={};return Ue.push(s),Fe(s,e,t,n,i,r,o)}{const s=Ue.find((e=>!e.busy));return s?(He(s),Fe(s,e,t,n,i,r,o)):new Promise((n=>ze.push({resolve:n,codecConstructor:e,options:t,webWorker:r,scripts:o})))}function i(e){if(ze.length){const[{resolve:t,codecConstructor:r,options:o,webWorker:s,scripts:a}]=ze.splice(0,1);t(Fe(e,r,o,n,i,s,a))}else e.worker?(He(e),Number.isFinite(n.terminateWorkerTimeout)&&n.terminateWorkerTimeout>=0&&(e.terminateTimeout=setTimeout((()=>{Ue=Ue.filter((t=>t!=e)),e.terminate()}),n.terminateWorkerTimeout))):Ue=Ue.filter((t=>t!=e))}}(l.Inflate,{codecType:Me,password:y,zipCrypto:g,encryptionStrength:s&&s.strength,signed:lt(r,n,"checkSignature"),passwordVerification:g&&(c.dataDescriptor?d>>>8&255:u>>>24&255),signature:u,compressed:0!=a,encrypted:v,useWebWorkers:lt(r,n,"useWebWorkers")},l);e.initialized||await e.init();const _=lt(r,n,"signal"),w=i+30+p.filenameLength+p.extraFieldLength;return await async function(e,t,n,r,o,i,s){const a=Math.max(i.chunkSize,64);return async function i(l=0,c=0){const u=s.signal;if(l<o){k(u,e);const d=await t.readUint8Array(l+r,Math.min(a,o-l)),f=d.length;k(u,e);const p=await e.append(d);if(k(u,e),c+=await j(n,p),s.onprogress)try{s.onprogress(l+f,o)}catch(e){}return i(l+a,c)}{const t=await e.flush();return c+=await j(n,t.data),{signature:t.signature,length:c}}}()}(b,o,e,w,f,l,{onprogress:n.onprogress,signal:_}),e.getData()}}function it(e,t,n){const r=e.rawBitFlag=pt(t,n+2),o=1==(1&r),i=ht(t,n+6);Object.assign(e,{encrypted:o,version:pt(t,n),bitFlag:{level:(6&r)>>1,dataDescriptor:8==(8&r),languageEncodingFlag:2048==(2048&r)},rawLastModDate:i,lastModDate:ut(i),filenameLength:pt(t,n+22),extraFieldLength:pt(t,n+24)})}function st(e,t,n,r){const o=t.rawExtraField,i=t.extraField=new Map,s=yt(new Uint8Array(o));let a=0;try{for(;a<o.length;){const e=pt(s,a),t=pt(s,a+2);i.set(e,{type:e,data:o.slice(a+4,a+4+t)}),a+=4+t}}catch(e){}const l=pt(n,r+4);t.signature=ht(n,r+10),t.uncompressedSize=ht(n,r+18),t.compressedSize=ht(n,r+14);const c=i.get(1);c&&(function(e,t){t.zip64=!0;const n=yt(e.data);e.values=[];for(let t=0;t<Math.floor(e.data.length/8);t++)e.values.push(mt(n,0+8*t));const r=rt.filter((e=>t[e]==q));for(let t=0;t<r.length;t++)e[r[t]]=e.values[t];rt.forEach((n=>{if(t[n]==q){if(void 0===e[n])throw new Error(Qe);t[n]=e[n]}}))}(c,t),t.extraFieldZip64=c);const u=i.get(28789);u&&(at(u,"filename","rawFilename",t,e),t.extraFieldUnicodePath=u);const d=i.get(25461);d&&(at(d,"comment","rawComment",t,e),t.extraFieldUnicodeComment=d);const f=i.get(39169);f?(function(e,t,n){const r=yt(e.data);e.vendorVersion=ft(r,0),e.vendorId=ft(r,2);const o=ft(r,4);e.strength=o,e.originalCompressionMethod=n,t.compressionMethod=e.compressionMethod=pt(r,5)}(f,t,l),t.extraFieldAES=f):t.compressionMethod=l;const p=i.get(10);p&&(function(e,t){const n=yt(e.data);let r,o=4;try{for(;o<e.data.length&&!r;){const t=pt(n,o),i=pt(n,o+2);1==t&&(r=e.data.slice(o+4,o+4+i)),o+=4+i}}catch(e){}try{if(r&&24==r.length){const n=yt(r),o=n.getBigUint64(0,!0),i=n.getBigUint64(8,!0),s=n.getBigUint64(16,!0);Object.assign(e,{rawLastModDate:o,rawLastAccessDate:i,rawCreationDate:s});const a=dt(o),l={lastModDate:a,lastAccessDate:dt(i),creationDate:dt(s)};Object.assign(e,l),Object.assign(t,l)}}catch(e){}}(p,t),t.extraFieldNTFS=p);const h=i.get(21589);h&&(function(e,t){const n=yt(e.data),r=ft(n,0),o=[],i=[];1==(1&r)&&(o.push("lastModDate"),i.push("rawLastModDate")),2==(2&r)&&(o.push("lastAccessDate"),i.push("rawLastAccessDate")),4==(4&r)&&(o.push("creationDate"),i.push("rawCreationDate"));let s=1;o.forEach(((r,o)=>{if(e.data.length>=s+4){const a=ht(n,s);t[r]=e[r]=new Date(1e3*a);const l=i[o];e[l]=a}s+=4}))}(h,t),t.extraFieldExtendedTimestamp=h)}function at(e,t,n,r,o){const i=yt(e.data);e.version=ft(i,0),e.signature=ht(i,1);const s=new $;s.append(o[n]);const a=yt(new Uint8Array(4));a.setUint32(0,s.get(),!0),e[t]=(new TextDecoder).decode(e.data.subarray(5)),e.valid=!o.bitFlag.languageEncodingFlag&&e.signature==ht(a,0),e.valid&&(r[t]=e[t],r[t+"UTF8"]=!0)}function lt(e,t,n){return void 0===t[n]?e.options[n]:t[n]}function ct(e,t){return t&&"cp437"!=t.trim().toLowerCase()?new TextDecoder(t).decode(e):(e=>{let t="";for(let n=0;n<e.length;n++)t+=Y[e[n]];return t})(e)}function ut(e){const t=(4294901760&e)>>16,n=65535&e;try{return new Date(1980+((65024&t)>>9),((480&t)>>5)-1,31&t,(63488&n)>>11,(2016&n)>>5,2*(31&n),0)}catch(e){}}function dt(e){return new Date(Number(e/BigInt(1e4)-BigInt(116444736e5)))}function ft(e,t){return e.getUint8(t)}function pt(e,t){return e.getUint16(t,!0)}function ht(e,t){return e.getUint32(t,!0)}function mt(e,t){return Number(e.getBigUint64(t,!0))}function yt(e){return new DataView(e.buffer)}function vt(e,t,n){return e.readUint8Array(t,n)}w({Inflate:function(e){const t=new g,n=e&&e.chunkSize?Math.floor(2*e.chunkSize):131072,o=new Uint8Array(n);let i=!1;t.inflateInit(),t.next_out=o,this.append=function(e,s){const a=[];let l,c,u=0,d=0,f=0;if(0!==e.length){t.next_in_index=0,t.next_in=e,t.avail_in=e.length;do{if(t.next_out_index=0,t.avail_out=n,0!==t.avail_in||i||(t.next_in_index=0,i=!0),l=t.inflate(0),i&&l===r){if(0!==t.avail_in)throw new Error("inflating: bad input")}else if(0!==l&&1!==l)throw new Error("inflating: "+t.msg);if((i||1===l)&&t.avail_in===e.length)throw new Error("inflating: bad input");t.next_out_index&&(t.next_out_index===n?a.push(new Uint8Array(o)):a.push(o.slice(0,t.next_out_index))),f+=t.next_out_index,s&&t.next_in_index>0&&t.next_in_index!=u&&(s(t.next_in_index),u=t.next_in_index)}while(t.avail_in>0||0===t.avail_out);return a.length>1?(c=new Uint8Array(f),a.forEach((function(e){c.set(e,d),d+=e.length}))):c=a[0]||new Uint8Array(0),c}},this.flush=function(){t.inflateEnd()}}}),e.BlobReader=K,e.BlobWriter=class extends I{constructor(e){super(),this.offset=0,this.contentType=e,this.blob=new Blob([],{type:e})}async writeUint8Array(e){super.writeUint8Array(e),this.blob=new Blob([this.blob,e.buffer],{type:this.contentType}),this.offset=this.blob.size}getData(){return this.blob}},e.Data64URIReader=class extends A{constructor(e){super(),this.dataURI=e;let t=e.length;for(;"="==e.charAt(t-1);)t--;this.dataStart=e.indexOf(",")+1,this.size=Math.floor(.75*(t-this.dataStart))}async readUint8Array(e,t){const n=new Uint8Array(t),r=4*Math.floor(e/3),o=atob(this.dataURI.substring(r+this.dataStart,4*Math.ceil((e+t)/3)+this.dataStart)),i=e-3*Math.floor(r/4);for(let e=i;e<i+t;e++)n[e-i]=o.charCodeAt(e);return n}},e.Data64URIWriter=class extends I{constructor(e){super(),this.data="data:"+(e||"")+";base64,",this.pending=[]}async writeUint8Array(e){super.writeUint8Array(e);let t=0,n=this.pending;const r=this.pending.length;for(this.pending="",t=0;t<3*Math.floor((r+e.length)/3)-r;t++)n+=String.fromCharCode(e[t]);for(;t<e.length;t++)this.pending+=String.fromCharCode(e[t]);n.length>2?this.data+=btoa(n):this.pending=n}getData(){return this.data+btoa(this.pending)}},e.ERR_ABORT=x,e.ERR_BAD_FORMAT=Ve,e.ERR_CENTRAL_DIRECTORY_NOT_FOUND=$e,e.ERR_ENCRYPTED=Ze,e.ERR_EOCDR_LOCATOR_ZIP64_NOT_FOUND=Xe,e.ERR_EOCDR_NOT_FOUND=Ge,e.ERR_EOCDR_ZIP64_NOT_FOUND=Ye,e.ERR_EXTRAFIELD_ZIP64_NOT_FOUND=Qe,e.ERR_HTTP_RANGE=D,e.ERR_INVALID_PASSWORD=re,e.ERR_INVALID_SIGNATURE=Te,e.ERR_LOCAL_FILE_HEADER_NOT_FOUND=Je,e.ERR_UNSUPPORTED_COMPRESSION=tt,e.ERR_UNSUPPORTED_ENCRYPTION=et,e.HttpRangeReader=class extends H{constructor(e,t={}){t.useRangeHeader=!0,super(e,t)}},e.HttpReader=H,e.Reader=A,e.TextReader=class extends A{constructor(e){super(),this.blobReader=new K(new Blob([e],{type:E}))}async init(){super.init(),this.blobReader.init(),this.size=this.blobReader.size}async readUint8Array(e,t){return this.blobReader.readUint8Array(e,t)}},e.TextWriter=class extends I{constructor(e){super(),this.encoding=e,this.blob=new Blob([],{type:E})}async writeUint8Array(e){super.writeUint8Array(e),this.blob=new Blob([this.blob,e.buffer],{type:E})}getData(){const e=new FileReader;return new Promise(((t,n)=>{e.onload=e=>t(e.target.result),e.onerror=()=>n(e.error),e.readAsText(this.blob,this.encoding)}))}},e.Uint8ArrayReader=class extends A{constructor(e){super(),this.array=e,this.size=e.length}async readUint8Array(e,t){return this.array.slice(e,e+t)}},e.Uint8ArrayWriter=class extends I{constructor(){super(),this.array=new Uint8Array(0)}async writeUint8Array(e){super.writeUint8Array(e);const t=this.array;this.array=new Uint8Array(t.length+e.length),this.array.set(t),this.array.set(e,t.length)}getData(){return this.array}},e.Writer=I,e.ZipReader=class{constructor(e,t={}){Object.assign(this,{reader:e,options:t,config:_})}async getEntries(e={}){const t=this,n=t.reader;if(n.initialized||await n.init(),n.size<22)throw new Error(Ve);const r=await async function(e,t,n,r,o){const i=new Uint8Array(4);!function(e,t,n){e.setUint32(0,101010256,!0)}(yt(i));return await s(22)||await s(Math.min(1048582,n));async function s(t){const r=n-t,o=await vt(e,r,t);for(let e=o.length-22;e>=0;e--)if(o[e]==i[0]&&o[e+1]==i[1]&&o[e+2]==i[2]&&o[e+3]==i[3])return{offset:r+e,buffer:o.slice(e,e+22).buffer}}}(n,0,n.size);if(!r)throw new Error(Ge);const o=yt(r);let i=ht(o,12),s=ht(o,16),a=pt(o,8),l=0;if(s==q||65535==a){const e=yt(await vt(n,r.offset-20,20));if(117853008!=ht(e,0))throw new Error(Ye);s=mt(e,8);let t=await vt(n,s,56),o=yt(t);const c=r.offset-20-56;if(ht(o,0)!=G&&s!=c){const e=s;s=c,l=s-e,t=await vt(n,s,56),o=yt(t)}if(ht(o,0)!=G)throw new Error(Xe);a=mt(o,24),i=ht(e,4),s-=mt(o,40)}if(s<0||s>=n.size)throw new Error(Ve);let c=0,u=await vt(n,s,n.size-s),d=yt(u);const f=r.offset-i;if(ht(d,c)!=V&&s!=f){const e=s;s=f,l=s-e,u=await vt(n,s,n.size-s),d=yt(u)}if(s<0||s>=n.size)throw new Error(Ve);const p=[];for(let r=0;r<a;r++){const o=new ot(n,t.config,t.options);if(ht(d,c)!=V)throw new Error($e);it(o,d,c+6);const i=Boolean(o.bitFlag.languageEncodingFlag),s=c+46,f=s+o.filenameLength,h=f+o.extraFieldLength,m=pt(d,c+4),y=0==(0&m);Object.assign(o,{versionMadeBy:m,msDosCompatible:y,compressedSize:0,uncompressedSize:0,commentLength:pt(d,c+32),directory:y&&16==(16&ft(d,c+38)),offset:ht(d,c+42)+l,internalFileAttribute:ht(d,c+34),externalFileAttribute:ht(d,c+38),rawFilename:u.subarray(s,f),filenameUTF8:i,commentUTF8:i,rawExtraField:u.subarray(f,h)});const v=h+o.commentLength;o.rawComment=u.subarray(h,v),o.filename=ct(o.rawFilename,o.filenameUTF8?nt:lt(t,e,"filenameEncoding")),o.comment=ct(o.rawComment,o.commentUTF8?nt:lt(t,e,"commentEncoding")),!o.directory&&o.filename.endsWith("/")&&(o.directory=!0),st(o,o,d,c+6);const g=new qe(o);if(g.getData=(e,t)=>o.getData(e,g,t),p.push(g),c=v,e.onprogress)try{e.onprogress(r+1,a,new qe(o))}catch(e){}}return p}async close(){}},e.configure=w,e.getMimeType=function(){return"application/octet-stream"},Object.defineProperty(e,"__esModule",{value:!0})})),function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(i)return i(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i="function"==typeof require&&require,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(e,t,n){"use strict";n.byteLength=function(e){var t=c(e),n=t[0],r=t[1];return 3*(n+r)/4-r},n.toByteArray=function(e){var t,n,r=c(e),s=r[0],a=r[1],l=new i(function(e,t,n){return 3*(t+n)/4-n}(0,s,a)),u=0,d=a>0?s-4:s;for(n=0;n<d;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],l[u++]=t>>16&255,l[u++]=t>>8&255,l[u++]=255&t;2===a&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,l[u++]=255&t);1===a&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,l[u++]=t>>8&255,l[u++]=255&t);return l},n.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=16383,a=0,l=n-o;a<l;a+=s)i.push(u(e,a,a+s>l?l:a+s));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,l=s.length;a<l;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function c(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function u(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},{}],2:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/try-to-string"),s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not a function")}},{"../internals/global":43,"../internals/is-callable":52,"../internals/try-to-string":105}],3:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=r.String,s=r.TypeError;t.exports=function(e){if("object"==typeof e||o(e))return e;throw s("Can't set "+i(e)+" as a prototype")}},{"../internals/global":43,"../internals/is-callable":52}],4:[function(e,t,n){var r=e("../internals/well-known-symbol"),o=e("../internals/object-create"),i=e("../internals/object-define-property"),s=r("unscopables"),a=Array.prototype;null==a[s]&&i.f(a,s,{configurable:!0,value:o(null)}),t.exports=function(e){a[s][e]=!0}},{"../internals/object-create":66,"../internals/object-define-property":68,"../internals/well-known-symbol":110}],5:[function(e,t,n){"use strict";var r=e("../internals/string-multibyte").charAt;t.exports=function(e,t,n){return t+(n?r(e,t).length:1)}},{"../internals/string-multibyte":94}],6:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/object-is-prototype-of"),i=r.TypeError;t.exports=function(e,t){if(o(t,e))return e;throw i("Incorrect invocation")}},{"../internals/global":43,"../internals/object-is-prototype-of":73}],7:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-object"),i=r.String,s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not an object")}},{"../internals/global":43,"../internals/is-object":55}],8:[function(e,t,n){"use strict";var r=e("../internals/global"),o=e("../internals/function-bind-context"),i=e("../internals/function-call"),s=e("../internals/to-object"),a=e("../internals/call-with-safe-iteration-closing"),l=e("../internals/is-array-iterator-method"),c=e("../internals/is-constructor"),u=e("../internals/length-of-array-like"),d=e("../internals/create-property"),f=e("../internals/get-iterator"),p=e("../internals/get-iterator-method"),h=r.Array;t.exports=function(e){var t=s(e),n=c(this),r=arguments.length,m=r>1?arguments[1]:void 0,y=void 0!==m;y&&(m=o(m,r>2?arguments[2]:void 0));var v,g,b,_,w,x,k=p(t),j=0;if(!k||this==h&&l(k))for(v=u(t),g=n?new this(v):h(v);v>j;j++)x=y?m(t[j],j):t[j],d(g,j,x);else for(w=(_=f(t,k)).next,g=n?new this:[];!(b=i(w,_)).done;j++)x=y?a(_,m,[b.value,j],!0):b.value,d(g,j,x);return g.length=j,g}},{"../internals/call-with-safe-iteration-closing":12,"../internals/create-property":20,"../internals/function-bind-context":33,"../internals/function-call":35,"../internals/get-iterator":40,"../internals/get-iterator-method":39,"../internals/global":43,"../internals/is-array-iterator-method":51,"../internals/is-constructor":53,"../internals/length-of-array-like":61,"../internals/to-object":100}],9:[function(e,t,n){var r=e("../internals/to-indexed-object"),o=e("../internals/to-absolute-index"),i=e("../internals/length-of-array-like"),s=function(e){return function(t,n,s){var a,l=r(t),c=i(l),u=o(s,c);if(e&&n!=n){for(;c>u;)if((a=l[u++])!=a)return!0}else for(;c>u;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},{"../internals/length-of-array-like":61,"../internals/to-absolute-index":96,"../internals/to-indexed-object":97}],10:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-absolute-index"),i=e("../internals/length-of-array-like"),s=e("../internals/create-property"),a=r.Array,l=Math.max;t.exports=function(e,t,n){for(var r=i(e),c=o(t,r),u=o(void 0===n?r:n,r),d=a(l(u-c,0)),f=0;c<u;c++,f++)s(d,f,e[c]);return d.length=f,d}},{"../internals/create-property":20,"../internals/global":43,"../internals/length-of-array-like":61,"../internals/to-absolute-index":96}],11:[function(e,t,n){var r=e("../internals/array-slice-simple"),o=Math.floor,i=function(e,t){var n=e.length,l=o(n/2);return n<8?s(e,t):a(e,i(r(e,0,l),t),i(r(e,l),t),t)},s=function(e,t){for(var n,r,o=e.length,i=1;i<o;){for(r=i,n=e[i];r&&t(e[r-1],n)>0;)e[r]=e[--r];r!==i++&&(e[r]=n)}return e},a=function(e,t,n,r){for(var o=t.length,i=n.length,s=0,a=0;s<o||a<i;)e[s+a]=s<o&&a<i?r(t[s],n[a])<=0?t[s++]:n[a++]:s<o?t[s++]:n[a++];return e};t.exports=i},{"../internals/array-slice-simple":10}],12:[function(e,t,n){var r=e("../internals/an-object"),o=e("../internals/iterator-close");t.exports=function(e,t,n,i){try{return i?t(r(n)[0],n[1]):t(n)}catch(t){o(e,"throw",t)}}},{"../internals/an-object":7,"../internals/iterator-close":58}],13:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=r({}.toString),i=r("".slice);t.exports=function(e){return i(o(e),8,-1)}},{"../internals/function-uncurry-this":37}],14:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-string-tag-support"),i=e("../internals/is-callable"),s=e("../internals/classof-raw"),a=e("../internals/well-known-symbol")("toStringTag"),l=r.Object,c="Arguments"==s(function(){return arguments}());t.exports=o?s:function(e){var t,n,r;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=l(e),a))?n:c?s(t):"Object"==(r=s(t))&&i(t.callee)?"Arguments":r}},{"../internals/classof-raw":13,"../internals/global":43,"../internals/is-callable":52,"../internals/to-string-tag-support":103,"../internals/well-known-symbol":110}],15:[function(e,t,n){var r=e("../internals/has-own-property"),o=e("../internals/own-keys"),i=e("../internals/object-get-own-property-descriptor"),s=e("../internals/object-define-property");t.exports=function(e,t,n){for(var a=o(t),l=s.f,c=i.f,u=0;u<a.length;u++){var d=a[u];r(e,d)||n&&r(n,d)||l(e,d,c(t,d))}}},{"../internals/has-own-property":44,"../internals/object-define-property":68,"../internals/object-get-own-property-descriptor":69,"../internals/own-keys":79}],16:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},{"../internals/fails":30}],17:[function(e,t,n){"use strict";var r=e("../internals/iterators-core").IteratorPrototype,o=e("../internals/object-create"),i=e("../internals/create-property-descriptor"),s=e("../internals/set-to-string-tag"),a=e("../internals/iterators"),l=function(){return this};t.exports=function(e,t,n,c){var u=t+" Iterator";return e.prototype=o(r,{next:i(+!c,n)}),s(e,u,!1,!0),a[u]=l,e}},{"../internals/create-property-descriptor":19,"../internals/iterators":60,"../internals/iterators-core":59,"../internals/object-create":66,"../internals/set-to-string-tag":90}],18:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/object-define-property"),i=e("../internals/create-property-descriptor");t.exports=r?function(e,t,n){return o.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},{"../internals/create-property-descriptor":19,"../internals/descriptors":22,"../internals/object-define-property":68}],19:[function(e,t,n){t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},{}],20:[function(e,t,n){"use strict";var r=e("../internals/to-property-key"),o=e("../internals/object-define-property"),i=e("../internals/create-property-descriptor");t.exports=function(e,t,n){var s=r(t);s in e?o.f(e,s,i(0,n)):e[s]=n}},{"../internals/create-property-descriptor":19,"../internals/object-define-property":68,"../internals/to-property-key":102}],21:[function(e,t,n){"use strict";var r=e("../internals/export"),o=e("../internals/function-call"),i=e("../internals/is-pure"),s=e("../internals/function-name"),a=e("../internals/is-callable"),l=e("../internals/create-iterator-constructor"),c=e("../internals/object-get-prototype-of"),u=e("../internals/object-set-prototype-of"),d=e("../internals/set-to-string-tag"),f=e("../internals/create-non-enumerable-property"),p=e("../internals/redefine"),h=e("../internals/well-known-symbol"),m=e("../internals/iterators"),y=e("../internals/iterators-core"),v=s.PROPER,g=s.CONFIGURABLE,b=y.IteratorPrototype,_=y.BUGGY_SAFARI_ITERATORS,w=h("iterator"),x="keys",k="values",j="entries",C=function(){return this};t.exports=function(e,t,n,s,h,y,D){l(n,t,s);var E,S,O,P=function(e){if(e===h&&I)return I;if(!_&&e in T)return T[e];switch(e){case x:case k:case j:return function(){return new n(this,e)}}return function(){return new n(this)}},B=t+" Iterator",M=!1,T=e.prototype,A=T[w]||T["@@iterator"]||h&&T[h],I=!_&&A||P(h),K="Array"==t&&T.entries||A;if(K&&(E=c(K.call(new e)))!==Object.prototype&&E.next&&(i||c(E)===b||(u?u(E,b):a(E[w])||p(E,w,C)),d(E,B,!0,!0),i&&(m[B]=C)),v&&h==k&&A&&A.name!==k&&(!i&&g?f(T,"name",k):(M=!0,I=function(){return o(A,this)})),h)if(S={values:P(k),keys:y?I:P(x),entries:P(j)},D)for(O in S)(_||M||!(O in T))&&p(T,O,S[O]);else r({target:t,proto:!0,forced:_||M},S);return i&&!D||T[w]===I||p(T,w,I,{name:h}),m[t]=I,S}},{"../internals/create-iterator-constructor":17,"../internals/create-non-enumerable-property":18,"../internals/export":29,"../internals/function-call":35,"../internals/function-name":36,"../internals/is-callable":52,"../internals/is-pure":56,"../internals/iterators":60,"../internals/iterators-core":59,"../internals/object-get-prototype-of":72,"../internals/object-set-prototype-of":77,"../internals/redefine":81,"../internals/set-to-string-tag":90,"../internals/well-known-symbol":110}],22:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},{"../internals/fails":30}],23:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-object"),i=r.document,s=o(i)&&o(i.createElement);t.exports=function(e){return s?i.createElement(e):{}}},{"../internals/global":43,"../internals/is-object":55}],24:[function(e,t,n){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},{}],25:[function(e,t,n){var r=e("../internals/document-create-element")("span").classList,o=r&&r.constructor&&r.constructor.prototype;t.exports=o===Object.prototype?void 0:o},{"../internals/document-create-element":23}],26:[function(e,t,n){var r=e("../internals/get-built-in");t.exports=r("navigator","userAgent")||""},{"../internals/get-built-in":38}],27:[function(e,t,n){var r,o,i=e("../internals/global"),s=e("../internals/engine-user-agent"),a=i.process,l=i.Deno,c=a&&a.versions||l&&l.version,u=c&&c.v8;u&&(o=(r=u.split("."))[0]>0&&r[0]<4?1:+(r[0]+r[1])),!o&&s&&(!(r=s.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/))&&(o=+r[1]),t.exports=o},{"../internals/engine-user-agent":26,"../internals/global":43}],28:[function(e,t,n){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},{}],29:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/object-get-own-property-descriptor").f,i=e("../internals/create-non-enumerable-property"),s=e("../internals/redefine"),a=e("../internals/set-global"),l=e("../internals/copy-constructor-properties"),c=e("../internals/is-forced");t.exports=function(e,t){var n,u,d,f,p,h=e.target,m=e.global,y=e.stat;if(n=m?r:y?r[h]||a(h,{}):(r[h]||{}).prototype)for(u in t){if(f=t[u],d=e.noTargetGet?(p=o(n,u))&&p.value:n[u],!c(m?u:h+(y?".":"#")+u,e.forced)&&void 0!==d){if(typeof f==typeof d)continue;l(f,d)}(e.sham||d&&d.sham)&&i(f,"sham",!0),s(n,u,f,e)}}},{"../internals/copy-constructor-properties":15,"../internals/create-non-enumerable-property":18,"../internals/global":43,"../internals/is-forced":54,"../internals/object-get-own-property-descriptor":69,"../internals/redefine":81,"../internals/set-global":89}],30:[function(e,t,n){t.exports=function(e){try{return!!e()}catch(e){return!0}}},{}],31:[function(e,t,n){"use strict";e("../modules/es.regexp.exec");var r=e("../internals/function-uncurry-this"),o=e("../internals/redefine"),i=e("../internals/regexp-exec"),s=e("../internals/fails"),a=e("../internals/well-known-symbol"),l=e("../internals/create-non-enumerable-property"),c=a("species"),u=RegExp.prototype;t.exports=function(e,t,n,d){var f=a(e),p=!s((function(){var t={};return t[f]=function(){return 7},7!=""[e](t)})),h=p&&!s((function(){var t=!1,n=/a/;return"split"===e&&((n={}).constructor={},n.constructor[c]=function(){return n},n.flags="",n[f]=/./[f]),n.exec=function(){return t=!0,null},n[f](""),!t}));if(!p||!h||n){var m=r(/./[f]),y=t(f,""[e],(function(e,t,n,o,s){var a=r(e),l=t.exec;return l===i||l===u.exec?p&&!s?{done:!0,value:m(t,n,o)}:{done:!0,value:a(n,t,o)}:{done:!1}}));o(String.prototype,e,y[0]),o(u,f,y[1])}d&&l(u[f],"sham",!0)}},{"../internals/create-non-enumerable-property":18,"../internals/fails":30,"../internals/function-uncurry-this":37,"../internals/redefine":81,"../internals/regexp-exec":83,"../internals/well-known-symbol":110,"../modules/es.regexp.exec":112}],32:[function(e,t,n){var r=e("../internals/function-bind-native"),o=Function.prototype,i=o.apply,s=o.call;t.exports="object"==typeof Reflect&&Reflect.apply||(r?s.bind(i):function(){return s.apply(i,arguments)})},{"../internals/function-bind-native":34}],33:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/a-callable"),i=e("../internals/function-bind-native"),s=r(r.bind);t.exports=function(e,t){return o(e),void 0===t?e:i?s(e,t):function(){return e.apply(t,arguments)}}},{"../internals/a-callable":2,"../internals/function-bind-native":34,"../internals/function-uncurry-this":37}],34:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))},{"../internals/fails":30}],35:[function(e,t,n){var r=e("../internals/function-bind-native"),o=Function.prototype.call;t.exports=r?o.bind(o):function(){return o.apply(o,arguments)}},{"../internals/function-bind-native":34}],36:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/has-own-property"),i=Function.prototype,s=r&&Object.getOwnPropertyDescriptor,a=o(i,"name"),l=a&&"something"===function(){}.name,c=a&&(!r||r&&s(i,"name").configurable);t.exports={EXISTS:a,PROPER:l,CONFIGURABLE:c}},{"../internals/descriptors":22,"../internals/has-own-property":44}],37:[function(e,t,n){var r=e("../internals/function-bind-native"),o=Function.prototype,i=o.bind,s=o.call,a=r&&i.bind(s,s);t.exports=r?function(e){return e&&a(e)}:function(e){return e&&function(){return s.apply(e,arguments)}}},{"../internals/function-bind-native":34}],38:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=function(e){return o(e)?e:void 0};t.exports=function(e,t){return arguments.length<2?i(r[e]):r[e]&&r[e][t]}},{"../internals/global":43,"../internals/is-callable":52}],39:[function(e,t,n){var r=e("../internals/classof"),o=e("../internals/get-method"),i=e("../internals/iterators"),s=e("../internals/well-known-symbol")("iterator");t.exports=function(e){if(null!=e)return o(e,s)||o(e,"@@iterator")||i[r(e)]}},{"../internals/classof":14,"../internals/get-method":41,"../internals/iterators":60,"../internals/well-known-symbol":110}],40:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/a-callable"),s=e("../internals/an-object"),a=e("../internals/try-to-string"),l=e("../internals/get-iterator-method"),c=r.TypeError;t.exports=function(e,t){var n=arguments.length<2?l(e):t;if(i(n))return s(o(n,e));throw c(a(e)+" is not iterable")}},{"../internals/a-callable":2,"../internals/an-object":7,"../internals/function-call":35,"../internals/get-iterator-method":39,"../internals/global":43,"../internals/try-to-string":105}],41:[function(e,t,n){var r=e("../internals/a-callable");t.exports=function(e,t){var n=e[t];return null==n?void 0:r(n)}},{"../internals/a-callable":2}],42:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/to-object"),i=Math.floor,s=r("".charAt),a=r("".replace),l=r("".slice),c=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,u=/\$([$&'`]|\d{1,2})/g;t.exports=function(e,t,n,r,d,f){var p=n+e.length,h=r.length,m=u;return void 0!==d&&(d=o(d),m=c),a(f,m,(function(o,a){var c;switch(s(a,0)){case"$":return"$";case"&":return e;case"`":return l(t,0,n);case"'":return l(t,p);case"<":c=d[l(a,1,-1)];break;default:var u=+a;if(0===u)return o;if(u>h){var f=i(u/10);return 0===f?o:f<=h?void 0===r[f-1]?s(a,1):r[f-1]+s(a,1):o}c=r[u-1]}return void 0===c?"":c}))}},{"../internals/function-uncurry-this":37,"../internals/to-object":100}],43:[function(e,t,n){(function(e){(function(){var n=function(e){return e&&e.Math==Math&&e};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||function(){return this}()||Function("return this")()}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],44:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/to-object"),i=r({}.hasOwnProperty);t.exports=Object.hasOwn||function(e,t){return i(o(e),t)}},{"../internals/function-uncurry-this":37,"../internals/to-object":100}],45:[function(e,t,n){t.exports={}},{}],46:[function(e,t,n){var r=e("../internals/get-built-in");t.exports=r("document","documentElement")},{"../internals/get-built-in":38}],47:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/fails"),i=e("../internals/document-create-element");t.exports=!r&&!o((function(){return 7!=Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},{"../internals/descriptors":22,"../internals/document-create-element":23,"../internals/fails":30}],48:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=e("../internals/fails"),s=e("../internals/classof-raw"),a=r.Object,l=o("".split);t.exports=i((function(){return!a("z").propertyIsEnumerable(0)}))?function(e){return"String"==s(e)?l(e,""):a(e)}:a},{"../internals/classof-raw":13,"../internals/fails":30,"../internals/function-uncurry-this":37,"../internals/global":43}],49:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/is-callable"),i=e("../internals/shared-store"),s=r(Function.toString);o(i.inspectSource)||(i.inspectSource=function(e){return s(e)}),t.exports=i.inspectSource},{"../internals/function-uncurry-this":37,"../internals/is-callable":52,"../internals/shared-store":92}],50:[function(e,t,n){var r,o,i,s=e("../internals/native-weak-map"),a=e("../internals/global"),l=e("../internals/function-uncurry-this"),c=e("../internals/is-object"),u=e("../internals/create-non-enumerable-property"),d=e("../internals/has-own-property"),f=e("../internals/shared-store"),p=e("../internals/shared-key"),h=e("../internals/hidden-keys"),m="Object already initialized",y=a.TypeError,v=a.WeakMap;if(s||f.state){var g=f.state||(f.state=new v),b=l(g.get),_=l(g.has),w=l(g.set);r=function(e,t){if(_(g,e))throw new y(m);return t.facade=e,w(g,e,t),t},o=function(e){return b(g,e)||{}},i=function(e){return _(g,e)}}else{var x=p("state");h[x]=!0,r=function(e,t){if(d(e,x))throw new y(m);return t.facade=e,u(e,x,t),t},o=function(e){return d(e,x)?e[x]:{}},i=function(e){return d(e,x)}}t.exports={set:r,get:o,has:i,enforce:function(e){return i(e)?o(e):r(e,{})},getterFor:function(e){return function(t){var n;if(!c(t)||(n=o(t)).type!==e)throw y("Incompatible receiver, "+e+" required");return n}}}},{"../internals/create-non-enumerable-property":18,"../internals/function-uncurry-this":37,"../internals/global":43,"../internals/has-own-property":44,"../internals/hidden-keys":45,"../internals/is-object":55,"../internals/native-weak-map":64,"../internals/shared-key":91,"../internals/shared-store":92}],51:[function(e,t,n){var r=e("../internals/well-known-symbol"),o=e("../internals/iterators"),i=r("iterator"),s=Array.prototype;t.exports=function(e){return void 0!==e&&(o.Array===e||s[i]===e)}},{"../internals/iterators":60,"../internals/well-known-symbol":110}],52:[function(e,t,n){t.exports=function(e){return"function"==typeof e}},{}],53:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/fails"),i=e("../internals/is-callable"),s=e("../internals/classof"),a=e("../internals/get-built-in"),l=e("../internals/inspect-source"),c=function(){},u=[],d=a("Reflect","construct"),f=/^\s*(?:class|function)\b/,p=r(f.exec),h=!f.exec(c),m=function(e){if(!i(e))return!1;try{return d(c,u,e),!0}catch(e){return!1}},y=function(e){if(!i(e))return!1;switch(s(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return h||!!p(f,l(e))}catch(e){return!0}};y.sham=!0,t.exports=!d||o((function(){var e;return m(m.call)||!m(Object)||!m((function(){e=!0}))||e}))?y:m},{"../internals/classof":14,"../internals/fails":30,"../internals/function-uncurry-this":37,"../internals/get-built-in":38,"../internals/inspect-source":49,"../internals/is-callable":52}],54:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/is-callable"),i=/#|\.prototype\./,s=function(e,t){var n=l[a(e)];return n==u||n!=c&&(o(t)?r(t):!!t)},a=s.normalize=function(e){return String(e).replace(i,".").toLowerCase()},l=s.data={},c=s.NATIVE="N",u=s.POLYFILL="P";t.exports=s},{"../internals/fails":30,"../internals/is-callable":52}],55:[function(e,t,n){var r=e("../internals/is-callable");t.exports=function(e){return"object"==typeof e?null!==e:r(e)}},{"../internals/is-callable":52}],56:[function(e,t,n){t.exports=!1},{}],57:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/get-built-in"),i=e("../internals/is-callable"),s=e("../internals/object-is-prototype-of"),a=e("../internals/use-symbol-as-uid"),l=r.Object;t.exports=a?function(e){return"symbol"==typeof e}:function(e){var t=o("Symbol");return i(t)&&s(t.prototype,l(e))}},{"../internals/get-built-in":38,"../internals/global":43,"../internals/is-callable":52,"../internals/object-is-prototype-of":73,"../internals/use-symbol-as-uid":107}],58:[function(e,t,n){var r=e("../internals/function-call"),o=e("../internals/an-object"),i=e("../internals/get-method");t.exports=function(e,t,n){var s,a;o(e);try{if(!(s=i(e,"return"))){if("throw"===t)throw n;return n}s=r(s,e)}catch(e){a=!0,s=e}if("throw"===t)throw n;if(a)throw s;return o(s),n}},{"../internals/an-object":7,"../internals/function-call":35,"../internals/get-method":41}],59:[function(e,t,n){"use strict";var r,o,i,s=e("../internals/fails"),a=e("../internals/is-callable"),l=e("../internals/object-create"),c=e("../internals/object-get-prototype-of"),u=e("../internals/redefine"),d=e("../internals/well-known-symbol"),f=e("../internals/is-pure"),p=d("iterator"),h=!1;[].keys&&("next"in(i=[].keys())?(o=c(c(i)))!==Object.prototype&&(r=o):h=!0),null==r||s((function(){var e={};return r[p].call(e)!==e}))?r={}:f&&(r=l(r)),a(r[p])||u(r,p,(function(){return this})),t.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:h}},{"../internals/fails":30,"../internals/is-callable":52,"../internals/is-pure":56,"../internals/object-create":66,"../internals/object-get-prototype-of":72,"../internals/redefine":81,"../internals/well-known-symbol":110}],60:[function(e,t,n){arguments[4][45][0].apply(n,arguments)},{dup:45}],61:[function(e,t,n){var r=e("../internals/to-length");t.exports=function(e){return r(e.length)}},{"../internals/to-length":99}],62:[function(e,t,n){var r=e("../internals/engine-v8-version"),o=e("../internals/fails");t.exports=!!Object.getOwnPropertySymbols&&!o((function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},{"../internals/engine-v8-version":27,"../internals/fails":30}],63:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/well-known-symbol"),i=e("../internals/is-pure"),s=o("iterator");t.exports=!r((function(){var e=new URL("b?a=1&b=2&c=3","http://a"),t=e.searchParams,n="";return e.pathname="c%20d",t.forEach((function(e,r){t.delete("b"),n+=r+e})),i&&!e.toJSON||!t.sort||"http://a/c%20d?a=1&c=3"!==e.href||"3"!==t.get("c")||"a=1"!==String(new URLSearchParams("?a=1"))||!t[s]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://тест").host||"#%D0%B1"!==new URL("http://a#б").hash||"a1c3"!==n||"x"!==new URL("http://x",void 0).host}))},{"../internals/fails":30,"../internals/is-pure":56,"../internals/well-known-symbol":110}],64:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/inspect-source"),s=r.WeakMap;t.exports=o(s)&&/native code/.test(i(s))},{"../internals/global":43,"../internals/inspect-source":49,"../internals/is-callable":52}],65:[function(e,t,n){"use strict";var r=e("../internals/descriptors"),o=e("../internals/function-uncurry-this"),i=e("../internals/function-call"),s=e("../internals/fails"),a=e("../internals/object-keys"),l=e("../internals/object-get-own-property-symbols"),c=e("../internals/object-property-is-enumerable"),u=e("../internals/to-object"),d=e("../internals/indexed-object"),f=Object.assign,p=Object.defineProperty,h=o([].concat);t.exports=!f||s((function(){if(r&&1!==f({b:1},f(p({},"a",{enumerable:!0,get:function(){p(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var e={},t={},n=Symbol(),o="abcdefghijklmnopqrst";return e[n]=7,o.split("").forEach((function(e){t[e]=e})),7!=f({},e)[n]||a(f({},t)).join("")!=o}))?function(e,t){for(var n=u(e),o=arguments.length,s=1,f=l.f,p=c.f;o>s;)for(var m,y=d(arguments[s++]),v=f?h(a(y),f(y)):a(y),g=v.length,b=0;g>b;)m=v[b++],r&&!i(p,y,m)||(n[m]=y[m]);return n}:f},{"../internals/descriptors":22,"../internals/fails":30,"../internals/function-call":35,"../internals/function-uncurry-this":37,"../internals/indexed-object":48,"../internals/object-get-own-property-symbols":71,"../internals/object-keys":75,"../internals/object-property-is-enumerable":76,"../internals/to-object":100}],66:[function(e,t,n){var r,o=e("../internals/an-object"),i=e("../internals/object-define-properties"),s=e("../internals/enum-bug-keys"),a=e("../internals/hidden-keys"),l=e("../internals/html"),c=e("../internals/document-create-element"),u=e("../internals/shared-key"),d=u("IE_PROTO"),f=function(){},p=function(e){return"<script>"+e+"</"+"script>"},h=function(e){e.write(p("")),e.close();var t=e.parentWindow.Object;return e=null,t},m=function(){try{r=new ActiveXObject("htmlfile")}catch(e){}var e,t;m="undefined"!=typeof document?document.domain&&r?h(r):((t=c("iframe")).style.display="none",l.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(p("document.F=Object")),e.close(),e.F):h(r);for(var n=s.length;n--;)delete m.prototype[s[n]];return m()};a[d]=!0,t.exports=Object.create||function(e,t){var n;return null!==e?(f.prototype=o(e),n=new f,f.prototype=null,n[d]=e):n=m(),void 0===t?n:i.f(n,t)}},{"../internals/an-object":7,"../internals/document-create-element":23,"../internals/enum-bug-keys":28,"../internals/hidden-keys":45,"../internals/html":46,"../internals/object-define-properties":67,"../internals/shared-key":91}],67:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/v8-prototype-define-bug"),i=e("../internals/object-define-property"),s=e("../internals/an-object"),a=e("../internals/to-indexed-object"),l=e("../internals/object-keys");n.f=r&&!o?Object.defineProperties:function(e,t){s(e);for(var n,r=a(t),o=l(t),c=o.length,u=0;c>u;)i.f(e,n=o[u++],r[n]);return e}},{"../internals/an-object":7,"../internals/descriptors":22,"../internals/object-define-property":68,"../internals/object-keys":75,"../internals/to-indexed-object":97,"../internals/v8-prototype-define-bug":108}],68:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/descriptors"),i=e("../internals/ie8-dom-define"),s=e("../internals/v8-prototype-define-bug"),a=e("../internals/an-object"),l=e("../internals/to-property-key"),c=r.TypeError,u=Object.defineProperty,d=Object.getOwnPropertyDescriptor,f="enumerable",p="configurable",h="writable";n.f=o?s?function(e,t,n){if(a(e),t=l(t),a(n),"function"==typeof e&&"prototype"===t&&"value"in n&&h in n&&!n.writable){var r=d(e,t);r&&r.writable&&(e[t]=n.value,n={configurable:p in n?n.configurable:r.configurable,enumerable:f in n?n.enumerable:r.enumerable,writable:!1})}return u(e,t,n)}:u:function(e,t,n){if(a(e),t=l(t),a(n),i)try{return u(e,t,n)}catch(e){}if("get"in n||"set"in n)throw c("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},{"../internals/an-object":7,"../internals/descriptors":22,"../internals/global":43,"../internals/ie8-dom-define":47,"../internals/to-property-key":102,"../internals/v8-prototype-define-bug":108}],69:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/function-call"),i=e("../internals/object-property-is-enumerable"),s=e("../internals/create-property-descriptor"),a=e("../internals/to-indexed-object"),l=e("../internals/to-property-key"),c=e("../internals/has-own-property"),u=e("../internals/ie8-dom-define"),d=Object.getOwnPropertyDescriptor;n.f=r?d:function(e,t){if(e=a(e),t=l(t),u)try{return d(e,t)}catch(e){}if(c(e,t))return s(!o(i.f,e,t),e[t])}},{"../internals/create-property-descriptor":19,"../internals/descriptors":22,"../internals/function-call":35,"../internals/has-own-property":44,"../internals/ie8-dom-define":47,"../internals/object-property-is-enumerable":76,"../internals/to-indexed-object":97,"../internals/to-property-key":102}],70:[function(e,t,n){var r=e("../internals/object-keys-internal"),o=e("../internals/enum-bug-keys").concat("length","prototype");n.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},{"../internals/enum-bug-keys":28,"../internals/object-keys-internal":74}],71:[function(e,t,n){n.f=Object.getOwnPropertySymbols},{}],72:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/has-own-property"),i=e("../internals/is-callable"),s=e("../internals/to-object"),a=e("../internals/shared-key"),l=e("../internals/correct-prototype-getter"),c=a("IE_PROTO"),u=r.Object,d=u.prototype;t.exports=l?u.getPrototypeOf:function(e){var t=s(e);if(o(t,c))return t[c];var n=t.constructor;return i(n)&&t instanceof n?n.prototype:t instanceof u?d:null}},{"../internals/correct-prototype-getter":16,"../internals/global":43,"../internals/has-own-property":44,"../internals/is-callable":52,"../internals/shared-key":91,"../internals/to-object":100}],73:[function(e,t,n){var r=e("../internals/function-uncurry-this");t.exports=r({}.isPrototypeOf)},{"../internals/function-uncurry-this":37}],74:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/has-own-property"),i=e("../internals/to-indexed-object"),s=e("../internals/array-includes").indexOf,a=e("../internals/hidden-keys"),l=r([].push);t.exports=function(e,t){var n,r=i(e),c=0,u=[];for(n in r)!o(a,n)&&o(r,n)&&l(u,n);for(;t.length>c;)o(r,n=t[c++])&&(~s(u,n)||l(u,n));return u}},{"../internals/array-includes":9,"../internals/function-uncurry-this":37,"../internals/has-own-property":44,"../internals/hidden-keys":45,"../internals/to-indexed-object":97}],75:[function(e,t,n){var r=e("../internals/object-keys-internal"),o=e("../internals/enum-bug-keys");t.exports=Object.keys||function(e){return r(e,o)}},{"../internals/enum-bug-keys":28,"../internals/object-keys-internal":74}],76:[function(e,t,n){"use strict";var r={}.propertyIsEnumerable,o=Object.getOwnPropertyDescriptor,i=o&&!r.call({1:2},1);n.f=i?function(e){var t=o(this,e);return!!t&&t.enumerable}:r},{}],77:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/an-object"),i=e("../internals/a-possible-prototype");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{(e=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),t=n instanceof Array}catch(e){}return function(n,r){return o(n),i(r),t?e(n,r):n.__proto__=r,n}}():void 0)},{"../internals/a-possible-prototype":3,"../internals/an-object":7,"../internals/function-uncurry-this":37}],78:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/is-callable"),s=e("../internals/is-object"),a=r.TypeError;t.exports=function(e,t){var n,r;if("string"===t&&i(n=e.toString)&&!s(r=o(n,e)))return r;if(i(n=e.valueOf)&&!s(r=o(n,e)))return r;if("string"!==t&&i(n=e.toString)&&!s(r=o(n,e)))return r;throw a("Can't convert object to primitive value")}},{"../internals/function-call":35,"../internals/global":43,"../internals/is-callable":52,"../internals/is-object":55}],79:[function(e,t,n){var r=e("../internals/get-built-in"),o=e("../internals/function-uncurry-this"),i=e("../internals/object-get-own-property-names"),s=e("../internals/object-get-own-property-symbols"),a=e("../internals/an-object"),l=o([].concat);t.exports=r("Reflect","ownKeys")||function(e){var t=i.f(a(e)),n=s.f;return n?l(t,n(e)):t}},{"../internals/an-object":7,"../internals/function-uncurry-this":37,"../internals/get-built-in":38,"../internals/object-get-own-property-names":70,"../internals/object-get-own-property-symbols":71}],80:[function(e,t,n){var r=e("../internals/redefine");t.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},{"../internals/redefine":81}],81:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/has-own-property"),s=e("../internals/create-non-enumerable-property"),a=e("../internals/set-global"),l=e("../internals/inspect-source"),c=e("../internals/internal-state"),u=e("../internals/function-name").CONFIGURABLE,d=c.get,f=c.enforce,p=String(String).split("String");(t.exports=function(e,t,n,l){var c,d=!!l&&!!l.unsafe,h=!!l&&!!l.enumerable,m=!!l&&!!l.noTargetGet,y=l&&void 0!==l.name?l.name:t;o(n)&&("Symbol("===String(y).slice(0,7)&&(y="["+String(y).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!i(n,"name")||u&&n.name!==y)&&s(n,"name",y),(c=f(n)).source||(c.source=p.join("string"==typeof y?y:""))),e!==r?(d?!m&&e[t]&&(h=!0):delete e[t],h?e[t]=n:s(e,t,n)):h?e[t]=n:a(t,n)})(Function.prototype,"toString",(function(){return o(this)&&d(this).source||l(this)}))},{"../internals/create-non-enumerable-property":18,"../internals/function-name":36,"../internals/global":43,"../internals/has-own-property":44,"../internals/inspect-source":49,"../internals/internal-state":50,"../internals/is-callable":52,"../internals/set-global":89}],82:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/an-object"),s=e("../internals/is-callable"),a=e("../internals/classof-raw"),l=e("../internals/regexp-exec"),c=r.TypeError;t.exports=function(e,t){var n=e.exec;if(s(n)){var r=o(n,e,t);return null!==r&&i(r),r}if("RegExp"===a(e))return o(l,e,t);throw c("RegExp#exec called on incompatible receiver")}},{"../internals/an-object":7,"../internals/classof-raw":13,"../internals/function-call":35,"../internals/global":43,"../internals/is-callable":52,"../internals/regexp-exec":83}],83:[function(e,t,n){"use strict";var r,o,i=e("../internals/function-call"),s=e("../internals/function-uncurry-this"),a=e("../internals/to-string"),l=e("../internals/regexp-flags"),c=e("../internals/regexp-sticky-helpers"),u=e("../internals/shared"),d=e("../internals/object-create"),f=e("../internals/internal-state").get,p=e("../internals/regexp-unsupported-dot-all"),h=e("../internals/regexp-unsupported-ncg"),m=u("native-string-replace",String.prototype.replace),y=RegExp.prototype.exec,v=y,g=s("".charAt),b=s("".indexOf),_=s("".replace),w=s("".slice),x=(o=/b*/g,i(y,r=/a/,"a"),i(y,o,"a"),0!==r.lastIndex||0!==o.lastIndex),k=c.BROKEN_CARET,j=void 0!==/()??/.exec("")[1];(x||j||k||p||h)&&(v=function(e){var t,n,r,o,s,c,u,p=this,h=f(p),C=a(e),D=h.raw;if(D)return D.lastIndex=p.lastIndex,t=i(v,D,C),p.lastIndex=D.lastIndex,t;var E=h.groups,S=k&&p.sticky,O=i(l,p),P=p.source,B=0,M=C;if(S&&(O=_(O,"y",""),-1===b(O,"g")&&(O+="g"),M=w(C,p.lastIndex),p.lastIndex>0&&(!p.multiline||p.multiline&&"\n"!==g(C,p.lastIndex-1))&&(P="(?: "+P+")",M=" "+M,B++),n=new RegExp("^(?:"+P+")",O)),j&&(n=new RegExp("^"+P+"$(?!\\s)",O)),x&&(r=p.lastIndex),o=i(y,S?n:p,M),S?o?(o.input=w(o.input,B),o[0]=w(o[0],B),o.index=p.lastIndex,p.lastIndex+=o[0].length):p.lastIndex=0:x&&o&&(p.lastIndex=p.global?o.index+o[0].length:r),j&&o&&o.length>1&&i(m,o[0],n,(function(){for(s=1;s<arguments.length-2;s++)void 0===arguments[s]&&(o[s]=void 0)})),o&&E)for(o.groups=c=d(null),s=0;s<E.length;s++)c[(u=E[s])[0]]=o[u[1]];return o}),t.exports=v},{"../internals/function-call":35,"../internals/function-uncurry-this":37,"../internals/internal-state":50,"../internals/object-create":66,"../internals/regexp-flags":84,"../internals/regexp-sticky-helpers":85,"../internals/regexp-unsupported-dot-all":86,"../internals/regexp-unsupported-ncg":87,"../internals/shared":93,"../internals/to-string":104}],84:[function(e,t,n){"use strict";var r=e("../internals/an-object");t.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},{"../internals/an-object":7}],85:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/global").RegExp,i=r((function(){var e=o("a","y");return e.lastIndex=2,null!=e.exec("abcd")})),s=i||r((function(){return!o("a","y").sticky})),a=i||r((function(){var e=o("^r","gy");return e.lastIndex=2,null!=e.exec("str")}));t.exports={BROKEN_CARET:a,MISSED_STICKY:s,UNSUPPORTED_Y:i}},{"../internals/fails":30,"../internals/global":43}],86:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/global").RegExp;t.exports=r((function(){var e=o(".","s");return!(e.dotAll&&e.exec("\n")&&"s"===e.flags)}))},{"../internals/fails":30,"../internals/global":43}],87:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/global").RegExp;t.exports=r((function(){var e=o("(?<a>b)","g");return"b"!==e.exec("b").groups.a||"bc"!=="b".replace(e,"$<a>c")}))},{"../internals/fails":30,"../internals/global":43}],88:[function(e,t,n){var r=e("../internals/global").TypeError;t.exports=function(e){if(null==e)throw r("Can't call method on "+e);return e}},{"../internals/global":43}],89:[function(e,t,n){var r=e("../internals/global"),o=Object.defineProperty;t.exports=function(e,t){try{o(r,e,{value:t,configurable:!0,writable:!0})}catch(n){r[e]=t}return t}},{"../internals/global":43}],90:[function(e,t,n){var r=e("../internals/object-define-property").f,o=e("../internals/has-own-property"),i=e("../internals/well-known-symbol")("toStringTag");t.exports=function(e,t,n){e&&!n&&(e=e.prototype),e&&!o(e,i)&&r(e,i,{configurable:!0,value:t})}},{"../internals/has-own-property":44,"../internals/object-define-property":68,"../internals/well-known-symbol":110}],91:[function(e,t,n){var r=e("../internals/shared"),o=e("../internals/uid"),i=r("keys");t.exports=function(e){return i[e]||(i[e]=o(e))}},{"../internals/shared":93,"../internals/uid":106}],92:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/set-global"),i="__core-js_shared__",s=r[i]||o(i,{});t.exports=s},{"../internals/global":43,"../internals/set-global":89}],93:[function(e,t,n){var r=e("../internals/is-pure"),o=e("../internals/shared-store");(t.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.21.1",mode:r?"pure":"global",copyright:"© 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.21.1/LICENSE",source:"https://github.com/zloirock/core-js"})},{"../internals/is-pure":56,"../internals/shared-store":92}],94:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/to-integer-or-infinity"),i=e("../internals/to-string"),s=e("../internals/require-object-coercible"),a=r("".charAt),l=r("".charCodeAt),c=r("".slice),u=function(e){return function(t,n){var r,u,d=i(s(t)),f=o(n),p=d.length;return f<0||f>=p?e?"":void 0:(r=l(d,f))<55296||r>56319||f+1===p||(u=l(d,f+1))<56320||u>57343?e?a(d,f):r:e?c(d,f,f+2):u-56320+(r-55296<<10)+65536}};t.exports={codeAt:u(!1),charAt:u(!0)}},{"../internals/function-uncurry-this":37,"../internals/require-object-coercible":88,"../internals/to-integer-or-infinity":98,"../internals/to-string":104}],95:[function(e,t,n){"use strict";var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=2147483647,s=/[^\0-\u007E]/,a=/[.\u3002\uFF0E\uFF61]/g,l="Overflow: input needs wider integers to process",c=r.RangeError,u=o(a.exec),d=Math.floor,f=String.fromCharCode,p=o("".charCodeAt),h=o([].join),m=o([].push),y=o("".replace),v=o("".split),g=o("".toLowerCase),b=function(e){return e+22+75*(e<26)},_=function(e,t,n){var r=0;for(e=n?d(e/700):e>>1,e+=d(e/t);e>455;)e=d(e/35),r+=36;return d(r+36*e/(e+38))},w=function(e){var t=[];e=function(e){for(var t=[],n=0,r=e.length;n<r;){var o=p(e,n++);if(o>=55296&&o<=56319&&n<r){var i=p(e,n++);56320==(64512&i)?m(t,((1023&o)<<10)+(1023&i)+65536):(m(t,o),n--)}else m(t,o)}return t}(e);var n,r,o=e.length,s=128,a=0,u=72;for(n=0;n<e.length;n++)(r=e[n])<128&&m(t,f(r));var y=t.length,v=y;for(y&&m(t,"-");v<o;){var g=i;for(n=0;n<e.length;n++)(r=e[n])>=s&&r<g&&(g=r);var w=v+1;if(g-s>d((i-a)/w))throw c(l);for(a+=(g-s)*w,s=g,n=0;n<e.length;n++){if((r=e[n])<s&&++a>i)throw c(l);if(r==s){for(var x=a,k=36;;){var j=k<=u?1:k>=u+26?26:k-u;if(x<j)break;var C=x-j,D=36-j;m(t,f(b(j+C%D))),x=d(C/D),k+=36}m(t,f(b(x))),u=_(a,w,v==y),a=0,v++}}a++,s++}return h(t,"")};t.exports=function(e){var t,n,r=[],o=v(y(g(e),a,"."),".");for(t=0;t<o.length;t++)n=o[t],m(r,u(s,n)?"xn--"+w(n):n);return h(r,".")}},{"../internals/function-uncurry-this":37,"../internals/global":43}],96:[function(e,t,n){var r=e("../internals/to-integer-or-infinity"),o=Math.max,i=Math.min;t.exports=function(e,t){var n=r(e);return n<0?o(n+t,0):i(n,t)}},{"../internals/to-integer-or-infinity":98}],97:[function(e,t,n){var r=e("../internals/indexed-object"),o=e("../internals/require-object-coercible");t.exports=function(e){return r(o(e))}},{"../internals/indexed-object":48,"../internals/require-object-coercible":88}],98:[function(e,t,n){var r=Math.ceil,o=Math.floor;t.exports=function(e){var t=+e;return t!=t||0===t?0:(t>0?o:r)(t)}},{}],99:[function(e,t,n){var r=e("../internals/to-integer-or-infinity"),o=Math.min;t.exports=function(e){return e>0?o(r(e),9007199254740991):0}},{"../internals/to-integer-or-infinity":98}],100:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/require-object-coercible"),i=r.Object;t.exports=function(e){return i(o(e))}},{"../internals/global":43,"../internals/require-object-coercible":88}],101:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/is-object"),s=e("../internals/is-symbol"),a=e("../internals/get-method"),l=e("../internals/ordinary-to-primitive"),c=e("../internals/well-known-symbol"),u=r.TypeError,d=c("toPrimitive");t.exports=function(e,t){if(!i(e)||s(e))return e;var n,r=a(e,d);if(r){if(void 0===t&&(t="default"),n=o(r,e,t),!i(n)||s(n))return n;throw u("Can't convert object to primitive value")}return void 0===t&&(t="number"),l(e,t)}},{"../internals/function-call":35,"../internals/get-method":41,"../internals/global":43,"../internals/is-object":55,"../internals/is-symbol":57,"../internals/ordinary-to-primitive":78,"../internals/well-known-symbol":110}],102:[function(e,t,n){var r=e("../internals/to-primitive"),o=e("../internals/is-symbol");t.exports=function(e){var t=r(e,"string");return o(t)?t:t+""}},{"../internals/is-symbol":57,"../internals/to-primitive":101}],103:[function(e,t,n){var r={};r[e("../internals/well-known-symbol")("toStringTag")]="z",t.exports="[object z]"===String(r)},{"../internals/well-known-symbol":110}],104:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/classof"),i=r.String;t.exports=function(e){if("Symbol"===o(e))throw TypeError("Cannot convert a Symbol value to a string");return i(e)}},{"../internals/classof":14,"../internals/global":43}],105:[function(e,t,n){var r=e("../internals/global").String;t.exports=function(e){try{return r(e)}catch(e){return"Object"}}},{"../internals/global":43}],106:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=0,i=Math.random(),s=r(1..toString);t.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+s(++o+i,36)}},{"../internals/function-uncurry-this":37}],107:[function(e,t,n){var r=e("../internals/native-symbol");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},{"../internals/native-symbol":62}],108:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/fails");t.exports=r&&o((function(){return 42!=Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},{"../internals/descriptors":22,"../internals/fails":30}],109:[function(e,t,n){var r=e("../internals/global").TypeError;t.exports=function(e,t){if(e<t)throw r("Not enough arguments");return e}},{"../internals/global":43}],110:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/shared"),i=e("../internals/has-own-property"),s=e("../internals/uid"),a=e("../internals/native-symbol"),l=e("../internals/use-symbol-as-uid"),c=o("wks"),u=r.Symbol,d=u&&u.for,f=l?u:u&&u.withoutSetter||s;t.exports=function(e){if(!i(c,e)||!a&&"string"!=typeof c[e]){var t="Symbol."+e;a&&i(u,e)?c[e]=u[e]:c[e]=l&&d?d(t):f(t)}return c[e]}},{"../internals/global":43,"../internals/has-own-property":44,"../internals/native-symbol":62,"../internals/shared":93,"../internals/uid":106,"../internals/use-symbol-as-uid":107}],111:[function(e,t,n){"use strict";var r=e("../internals/to-indexed-object"),o=e("../internals/add-to-unscopables"),i=e("../internals/iterators"),s=e("../internals/internal-state"),a=e("../internals/object-define-property").f,l=e("../internals/define-iterator"),c=e("../internals/is-pure"),u=e("../internals/descriptors"),d="Array Iterator",f=s.set,p=s.getterFor(d);t.exports=l(Array,"Array",(function(e,t){f(this,{type:d,target:r(e),index:0,kind:t})}),(function(){var e=p(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}}),"values");var h=i.Arguments=i.Array;if(o("keys"),o("values"),o("entries"),!c&&u&&"values"!==h.name)try{a(h,"name",{value:"values"})}catch(e){}},{"../internals/add-to-unscopables":4,"../internals/define-iterator":21,"../internals/descriptors":22,"../internals/internal-state":50,"../internals/is-pure":56,"../internals/iterators":60,"../internals/object-define-property":68,"../internals/to-indexed-object":97}],112:[function(e,t,n){"use strict";var r=e("../internals/export"),o=e("../internals/regexp-exec");r({target:"RegExp",proto:!0,forced:/./.exec!==o},{exec:o})},{"../internals/export":29,"../internals/regexp-exec":83}],113:[function(e,t,n){"use strict";var r=e("../internals/string-multibyte").charAt,o=e("../internals/to-string"),i=e("../internals/internal-state"),s=e("../internals/define-iterator"),a="String Iterator",l=i.set,c=i.getterFor(a);s(String,"String",(function(e){l(this,{type:a,string:o(e),index:0})}),(function(){var e,t=c(this),n=t.string,o=t.index;return o>=n.length?{value:void 0,done:!0}:(e=r(n,o),t.index+=e.length,{value:e,done:!1})}))},{"../internals/define-iterator":21,"../internals/internal-state":50,"../internals/string-multibyte":94,"../internals/to-string":104}],114:[function(e,t,n){"use strict";var r=e("../internals/function-apply"),o=e("../internals/function-call"),i=e("../internals/function-uncurry-this"),s=e("../internals/fix-regexp-well-known-symbol-logic"),a=e("../internals/fails"),l=e("../internals/an-object"),c=e("../internals/is-callable"),u=e("../internals/to-integer-or-infinity"),d=e("../internals/to-length"),f=e("../internals/to-string"),p=e("../internals/require-object-coercible"),h=e("../internals/advance-string-index"),m=e("../internals/get-method"),y=e("../internals/get-substitution"),v=e("../internals/regexp-exec-abstract"),g=e("../internals/well-known-symbol")("replace"),b=Math.max,_=Math.min,w=i([].concat),x=i([].push),k=i("".indexOf),j=i("".slice),C="$0"==="a".replace(/./,"$0"),D=!!/./[g]&&""===/./[g]("a","$0");s("replace",(function(e,t,n){var i=D?"$":"$0";return[function(e,n){var r=p(this),i=null==e?void 0:m(e,g);return i?o(i,e,r,n):o(t,f(r),e,n)},function(e,o){var s=l(this),a=f(e);if("string"==typeof o&&-1===k(o,i)&&-1===k(o,"$<")){var p=n(t,s,a,o);if(p.done)return p.value}var m=c(o);m||(o=f(o));var g=s.global;if(g){var C=s.unicode;s.lastIndex=0}for(var D=[];;){var E=v(s,a);if(null===E)break;if(x(D,E),!g)break;""===f(E[0])&&(s.lastIndex=h(a,d(s.lastIndex),C))}for(var S,O="",P=0,B=0;B<D.length;B++){for(var M=f((E=D[B])[0]),T=b(_(u(E.index),a.length),0),A=[],I=1;I<E.length;I++)x(A,void 0===(S=E[I])?S:String(S));var K=E.groups;if(m){var L=w([M],A,T,a);void 0!==K&&x(L,K);var R=f(r(o,void 0,L))}else R=y(M,a,T,A,K,o);T>=P&&(O+=j(a,P,T)+R,P=T+M.length)}return O+j(a,P)}]}),!!a((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}))||!C||D)},{"../internals/advance-string-index":5,"../internals/an-object":7,"../internals/fails":30,"../internals/fix-regexp-well-known-symbol-logic":31,"../internals/function-apply":32,"../internals/function-call":35,"../internals/function-uncurry-this":37,"../internals/get-method":41,"../internals/get-substitution":42,"../internals/is-callable":52,"../internals/regexp-exec-abstract":82,"../internals/require-object-coercible":88,"../internals/to-integer-or-infinity":98,"../internals/to-length":99,"../internals/to-string":104,"../internals/well-known-symbol":110}],115:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/dom-iterables"),i=e("../internals/dom-token-list-prototype"),s=e("../modules/es.array.iterator"),a=e("../internals/create-non-enumerable-property"),l=e("../internals/well-known-symbol"),c=l("iterator"),u=l("toStringTag"),d=s.values,f=function(e,t){if(e){if(e[c]!==d)try{a(e,c,d)}catch(t){e[c]=d}if(e[u]||a(e,u,t),o[t])for(var n in s)if(e[n]!==s[n])try{a(e,n,s[n])}catch(t){e[n]=s[n]}}};for(var p in o)f(r[p]&&r[p].prototype,p);f(i,"DOMTokenList")},{"../internals/create-non-enumerable-property":18,"../internals/dom-iterables":24,"../internals/dom-token-list-prototype":25,"../internals/global":43,"../internals/well-known-symbol":110,"../modules/es.array.iterator":111}],116:[function(e,t,n){"use strict";e("../modules/es.array.iterator");var r=e("../internals/export"),o=e("../internals/global"),i=e("../internals/get-built-in"),s=e("../internals/function-call"),a=e("../internals/function-uncurry-this"),l=e("../internals/native-url"),c=e("../internals/redefine"),u=e("../internals/redefine-all"),d=e("../internals/set-to-string-tag"),f=e("../internals/create-iterator-constructor"),p=e("../internals/internal-state"),h=e("../internals/an-instance"),m=e("../internals/is-callable"),y=e("../internals/has-own-property"),v=e("../internals/function-bind-context"),g=e("../internals/classof"),b=e("../internals/an-object"),_=e("../internals/is-object"),w=e("../internals/to-string"),x=e("../internals/object-create"),k=e("../internals/create-property-descriptor"),j=e("../internals/get-iterator"),C=e("../internals/get-iterator-method"),D=e("../internals/validate-arguments-length"),E=e("../internals/well-known-symbol"),S=e("../internals/array-sort"),O=E("iterator"),P="URLSearchParams",B="URLSearchParamsIterator",M=p.set,T=p.getterFor(P),A=p.getterFor(B),I=i("fetch"),K=i("Request"),L=i("Headers"),R=K&&K.prototype,N=L&&L.prototype,F=o.RegExp,U=o.TypeError,z=o.decodeURIComponent,H=o.encodeURIComponent,W=a("".charAt),q=a([].join),V=a([].push),G=a("".replace),Y=a([].shift),X=a([].splice),$=a("".split),J=a("".slice),Q=/\+/g,Z=Array(4),ee=function(e){return Z[e-1]||(Z[e-1]=F("((?:%[\\da-f]{2}){"+e+"})","gi"))},te=function(e){try{return z(e)}catch(t){return e}},ne=function(e){var t=G(e,Q," "),n=4;try{return z(t)}catch(e){for(;n;)t=G(t,ee(n--),te);return t}},re=/[!'()~]|%20/g,oe={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},ie=function(e){return oe[e]},se=function(e){return G(H(e),re,ie)},ae=f((function(e,t){M(this,{type:B,iterator:j(T(e).entries),kind:t})}),"Iterator",(function(){var e=A(this),t=e.kind,n=e.iterator.next(),r=n.value;return n.done||(n.value="keys"===t?r.key:"values"===t?r.value:[r.key,r.value]),n}),!0),le=function(e){this.entries=[],this.url=null,void 0!==e&&(_(e)?this.parseObject(e):this.parseQuery("string"==typeof e?"?"===W(e,0)?J(e,1):e:w(e)))};le.prototype={type:P,bindURL:function(e){this.url=e,this.update()},parseObject:function(e){var t,n,r,o,i,a,l,c=C(e);if(c)for(n=(t=j(e,c)).next;!(r=s(n,t)).done;){if(i=(o=j(b(r.value))).next,(a=s(i,o)).done||(l=s(i,o)).done||!s(i,o).done)throw U("Expected sequence with length 2");V(this.entries,{key:w(a.value),value:w(l.value)})}else for(var u in e)y(e,u)&&V(this.entries,{key:u,value:w(e[u])})},parseQuery:function(e){if(e)for(var t,n,r=$(e,"&"),o=0;o<r.length;)(t=r[o++]).length&&(n=$(t,"="),V(this.entries,{key:ne(Y(n)),value:ne(q(n,"="))}))},serialize:function(){for(var e,t=this.entries,n=[],r=0;r<t.length;)e=t[r++],V(n,se(e.key)+"="+se(e.value));return q(n,"&")},update:function(){this.entries.length=0,this.parseQuery(this.url.query)},updateURL:function(){this.url&&this.url.update()}};var ce=function(){h(this,ue);var e=arguments.length>0?arguments[0]:void 0;M(this,new le(e))},ue=ce.prototype;if(u(ue,{append:function(e,t){D(arguments.length,2);var n=T(this);V(n.entries,{key:w(e),value:w(t)}),n.updateURL()},delete:function(e){D(arguments.length,1);for(var t=T(this),n=t.entries,r=w(e),o=0;o<n.length;)n[o].key===r?X(n,o,1):o++;t.updateURL()},get:function(e){D(arguments.length,1);for(var t=T(this).entries,n=w(e),r=0;r<t.length;r++)if(t[r].key===n)return t[r].value;return null},getAll:function(e){D(arguments.length,1);for(var t=T(this).entries,n=w(e),r=[],o=0;o<t.length;o++)t[o].key===n&&V(r,t[o].value);return r},has:function(e){D(arguments.length,1);for(var t=T(this).entries,n=w(e),r=0;r<t.length;)if(t[r++].key===n)return!0;return!1},set:function(e,t){D(arguments.length,1);for(var n,r=T(this),o=r.entries,i=!1,s=w(e),a=w(t),l=0;l<o.length;l++)(n=o[l]).key===s&&(i?X(o,l--,1):(i=!0,n.value=a));i||V(o,{key:s,value:a}),r.updateURL()},sort:function(){var e=T(this);S(e.entries,(function(e,t){return e.key>t.key?1:-1})),e.updateURL()},forEach:function(e){for(var t,n=T(this).entries,r=v(e,arguments.length>1?arguments[1]:void 0),o=0;o<n.length;)r((t=n[o++]).value,t.key,this)},keys:function(){return new ae(this,"keys")},values:function(){return new ae(this,"values")},entries:function(){return new ae(this,"entries")}},{enumerable:!0}),c(ue,O,ue.entries,{name:"entries"}),c(ue,"toString",(function(){return T(this).serialize()}),{enumerable:!0}),d(ce,P),r({global:!0,forced:!l},{URLSearchParams:ce}),!l&&m(L)){var de=a(N.has),fe=a(N.set),pe=function(e){if(_(e)){var t,n=e.body;if(g(n)===P)return t=e.headers?new L(e.headers):new L,de(t,"content-type")||fe(t,"content-type","application/x-www-form-urlencoded;charset=UTF-8"),x(e,{body:k(0,w(n)),headers:k(0,t)})}return e};if(m(I)&&r({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return I(e,arguments.length>1?pe(arguments[1]):{})}}),m(K)){var he=function(e){return h(this,R),new K(e,arguments.length>1?pe(arguments[1]):{})};R.constructor=he,he.prototype=R,r({global:!0,forced:!0},{Request:he})}}t.exports={URLSearchParams:ce,getState:T}},{"../internals/an-instance":6,"../internals/an-object":7,"../internals/array-sort":11,"../internals/classof":14,"../internals/create-iterator-constructor":17,"../internals/create-property-descriptor":19,"../internals/export":29,"../internals/function-bind-context":33,"../internals/function-call":35,"../internals/function-uncurry-this":37,"../internals/get-built-in":38,"../internals/get-iterator":40,"../internals/get-iterator-method":39,"../internals/global":43,"../internals/has-own-property":44,"../internals/internal-state":50,"../internals/is-callable":52,"../internals/is-object":55,"../internals/native-url":63,"../internals/object-create":66,"../internals/redefine":81,"../internals/redefine-all":80,"../internals/set-to-string-tag":90,"../internals/to-string":104,"../internals/validate-arguments-length":109,"../internals/well-known-symbol":110,"../modules/es.array.iterator":111}],117:[function(e,t,n){"use strict";e("../modules/es.string.iterator");var r,o=e("../internals/export"),i=e("../internals/descriptors"),s=e("../internals/native-url"),a=e("../internals/global"),l=e("../internals/function-bind-context"),c=e("../internals/function-uncurry-this"),u=e("../internals/object-define-properties").f,d=e("../internals/redefine"),f=e("../internals/an-instance"),p=e("../internals/has-own-property"),h=e("../internals/object-assign"),m=e("../internals/array-from"),y=e("../internals/array-slice-simple"),v=e("../internals/string-multibyte").codeAt,g=e("../internals/string-punycode-to-ascii"),b=e("../internals/to-string"),_=e("../internals/set-to-string-tag"),w=e("../internals/validate-arguments-length"),x=e("../modules/web.url-search-params"),k=e("../internals/internal-state"),j=k.set,C=k.getterFor("URL"),D=x.URLSearchParams,E=x.getState,S=a.URL,O=a.TypeError,P=a.parseInt,B=Math.floor,M=Math.pow,T=c("".charAt),A=c(/./.exec),I=c([].join),K=c(1..toString),L=c([].pop),R=c([].push),N=c("".replace),F=c([].shift),U=c("".split),z=c("".slice),H=c("".toLowerCase),W=c([].unshift),q="Invalid scheme",V="Invalid host",G="Invalid port",Y=/[a-z]/i,X=/[\d+-.a-z]/i,$=/\d/,J=/^0x/i,Q=/^[0-7]+$/,Z=/^\d+$/,ee=/^[\da-f]+$/i,te=/[\0\t\n\r #%/:<>?@[\\\]^|]/,ne=/[\0\t\n\r #/:<>?@[\\\]^|]/,re=/^[\u0000-\u0020]+|[\u0000-\u0020]+$/g,oe=/[\t\n\r]/g,ie=function(e){var t,n,r,o;if("number"==typeof e){for(t=[],n=0;n<4;n++)W(t,e%256),e=B(e/256);return I(t,".")}if("object"==typeof e){for(t="",r=function(e){for(var t=null,n=1,r=null,o=0,i=0;i<8;i++)0!==e[i]?(o>n&&(t=r,n=o),r=null,o=0):(null===r&&(r=i),++o);return o>n&&(t=r,n=o),t}(e),n=0;n<8;n++)o&&0===e[n]||(o&&(o=!1),r===n?(t+=n?":":"::",o=!0):(t+=K(e[n],16),n<7&&(t+=":")));return"["+t+"]"}return e},se={},ae=h({},se,{" ":1,'"':1,"<":1,">":1,"`":1}),le=h({},ae,{"#":1,"?":1,"{":1,"}":1}),ce=h({},le,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),ue=function(e,t){var n=v(e,0);return n>32&&n<127&&!p(t,e)?e:encodeURIComponent(e)},de={ftp:21,file:null,http:80,https:443,ws:80,wss:443},fe=function(e,t){var n;return 2==e.length&&A(Y,T(e,0))&&(":"==(n=T(e,1))||!t&&"|"==n)},pe=function(e){var t;return e.length>1&&fe(z(e,0,2))&&(2==e.length||"/"===(t=T(e,2))||"\\"===t||"?"===t||"#"===t)},he=function(e){return"."===e||"%2e"===H(e)},me={},ye={},ve={},ge={},be={},_e={},we={},xe={},ke={},je={},Ce={},De={},Ee={},Se={},Oe={},Pe={},Be={},Me={},Te={},Ae={},Ie={},Ke=function(e,t,n){var r,o,i,s=b(e);if(t){if(o=this.parse(s))throw O(o);this.searchParams=null}else{if(void 0!==n&&(r=new Ke(n,!0)),o=this.parse(s,null,r))throw O(o);(i=E(new D)).bindURL(this),this.searchParams=i}};Ke.prototype={type:"URL",parse:function(e,t,n){var o,i,s,a,l,c=this,u=t||me,d=0,f="",h=!1,v=!1,g=!1;for(e=b(e),t||(c.scheme="",c.username="",c.password="",c.host=null,c.port=null,c.path=[],c.query=null,c.fragment=null,c.cannotBeABaseURL=!1,e=N(e,re,"")),e=N(e,oe,""),o=m(e);d<=o.length;){switch(i=o[d],u){case me:if(!i||!A(Y,i)){if(t)return q;u=ve;continue}f+=H(i),u=ye;break;case ye:if(i&&(A(X,i)||"+"==i||"-"==i||"."==i))f+=H(i);else{if(":"!=i){if(t)return q;f="",u=ve,d=0;continue}if(t&&(c.isSpecial()!=p(de,f)||"file"==f&&(c.includesCredentials()||null!==c.port)||"file"==c.scheme&&!c.host))return;if(c.scheme=f,t)return void(c.isSpecial()&&de[c.scheme]==c.port&&(c.port=null));f="","file"==c.scheme?u=Se:c.isSpecial()&&n&&n.scheme==c.scheme?u=ge:c.isSpecial()?u=xe:"/"==o[d+1]?(u=be,d++):(c.cannotBeABaseURL=!0,R(c.path,""),u=Te)}break;case ve:if(!n||n.cannotBeABaseURL&&"#"!=i)return q;if(n.cannotBeABaseURL&&"#"==i){c.scheme=n.scheme,c.path=y(n.path),c.query=n.query,c.fragment="",c.cannotBeABaseURL=!0,u=Ie;break}u="file"==n.scheme?Se:_e;continue;case ge:if("/"!=i||"/"!=o[d+1]){u=_e;continue}u=ke,d++;break;case be:if("/"==i){u=je;break}u=Me;continue;case _e:if(c.scheme=n.scheme,i==r)c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=y(n.path),c.query=n.query;else if("/"==i||"\\"==i&&c.isSpecial())u=we;else if("?"==i)c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=y(n.path),c.query="",u=Ae;else{if("#"!=i){c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=y(n.path),c.path.length--,u=Me;continue}c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=y(n.path),c.query=n.query,c.fragment="",u=Ie}break;case we:if(!c.isSpecial()||"/"!=i&&"\\"!=i){if("/"!=i){c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,u=Me;continue}u=je}else u=ke;break;case xe:if(u=ke,"/"!=i||"/"!=T(f,d+1))continue;d++;break;case ke:if("/"!=i&&"\\"!=i){u=je;continue}break;case je:if("@"==i){h&&(f="%40"+f),h=!0,s=m(f);for(var _=0;_<s.length;_++){var w=s[_];if(":"!=w||g){var x=ue(w,ce);g?c.password+=x:c.username+=x}else g=!0}f=""}else if(i==r||"/"==i||"?"==i||"#"==i||"\\"==i&&c.isSpecial()){if(h&&""==f)return"Invalid authority";d-=m(f).length+1,f="",u=Ce}else f+=i;break;case Ce:case De:if(t&&"file"==c.scheme){u=Pe;continue}if(":"!=i||v){if(i==r||"/"==i||"?"==i||"#"==i||"\\"==i&&c.isSpecial()){if(c.isSpecial()&&""==f)return V;if(t&&""==f&&(c.includesCredentials()||null!==c.port))return;if(a=c.parseHost(f))return a;if(f="",u=Be,t)return;continue}"["==i?v=!0:"]"==i&&(v=!1),f+=i}else{if(""==f)return V;if(a=c.parseHost(f))return a;if(f="",u=Ee,t==De)return}break;case Ee:if(!A($,i)){if(i==r||"/"==i||"?"==i||"#"==i||"\\"==i&&c.isSpecial()||t){if(""!=f){var k=P(f,10);if(k>65535)return G;c.port=c.isSpecial()&&k===de[c.scheme]?null:k,f=""}if(t)return;u=Be;continue}return G}f+=i;break;case Se:if(c.scheme="file","/"==i||"\\"==i)u=Oe;else{if(!n||"file"!=n.scheme){u=Me;continue}if(i==r)c.host=n.host,c.path=y(n.path),c.query=n.query;else if("?"==i)c.host=n.host,c.path=y(n.path),c.query="",u=Ae;else{if("#"!=i){pe(I(y(o,d),""))||(c.host=n.host,c.path=y(n.path),c.shortenPath()),u=Me;continue}c.host=n.host,c.path=y(n.path),c.query=n.query,c.fragment="",u=Ie}}break;case Oe:if("/"==i||"\\"==i){u=Pe;break}n&&"file"==n.scheme&&!pe(I(y(o,d),""))&&(fe(n.path[0],!0)?R(c.path,n.path[0]):c.host=n.host),u=Me;continue;case Pe:if(i==r||"/"==i||"\\"==i||"?"==i||"#"==i){if(!t&&fe(f))u=Me;else if(""==f){if(c.host="",t)return;u=Be}else{if(a=c.parseHost(f))return a;if("localhost"==c.host&&(c.host=""),t)return;f="",u=Be}continue}f+=i;break;case Be:if(c.isSpecial()){if(u=Me,"/"!=i&&"\\"!=i)continue}else if(t||"?"!=i)if(t||"#"!=i){if(i!=r&&(u=Me,"/"!=i))continue}else c.fragment="",u=Ie;else c.query="",u=Ae;break;case Me:if(i==r||"/"==i||"\\"==i&&c.isSpecial()||!t&&("?"==i||"#"==i)){if(".."===(l=H(l=f))||"%2e."===l||".%2e"===l||"%2e%2e"===l?(c.shortenPath(),"/"==i||"\\"==i&&c.isSpecial()||R(c.path,"")):he(f)?"/"==i||"\\"==i&&c.isSpecial()||R(c.path,""):("file"==c.scheme&&!c.path.length&&fe(f)&&(c.host&&(c.host=""),f=T(f,0)+":"),R(c.path,f)),f="","file"==c.scheme&&(i==r||"?"==i||"#"==i))for(;c.path.length>1&&""===c.path[0];)F(c.path);"?"==i?(c.query="",u=Ae):"#"==i&&(c.fragment="",u=Ie)}else f+=ue(i,le);break;case Te:"?"==i?(c.query="",u=Ae):"#"==i?(c.fragment="",u=Ie):i!=r&&(c.path[0]+=ue(i,se));break;case Ae:t||"#"!=i?i!=r&&("'"==i&&c.isSpecial()?c.query+="%27":c.query+="#"==i?"%23":ue(i,se)):(c.fragment="",u=Ie);break;case Ie:i!=r&&(c.fragment+=ue(i,ae))}d++}},parseHost:function(e){var t,n,r;if("["==T(e,0)){if("]"!=T(e,e.length-1))return V;if(t=function(e){var t,n,r,o,i,s,a,l=[0,0,0,0,0,0,0,0],c=0,u=null,d=0,f=function(){return T(e,d)};if(":"==f()){if(":"!=T(e,1))return;d+=2,u=++c}for(;f();){if(8==c)return;if(":"!=f()){for(t=n=0;n<4&&A(ee,f());)t=16*t+P(f(),16),d++,n++;if("."==f()){if(0==n)return;if(d-=n,c>6)return;for(r=0;f();){if(o=null,r>0){if(!("."==f()&&r<4))return;d++}if(!A($,f()))return;for(;A($,f());){if(i=P(f(),10),null===o)o=i;else{if(0==o)return;o=10*o+i}if(o>255)return;d++}l[c]=256*l[c]+o,2!=++r&&4!=r||c++}if(4!=r)return;break}if(":"==f()){if(d++,!f())return}else if(f())return;l[c++]=t}else{if(null!==u)return;d++,u=++c}}if(null!==u)for(s=c-u,c=7;0!=c&&s>0;)a=l[c],l[c--]=l[u+s-1],l[u+--s]=a;else if(8!=c)return;return l}(z(e,1,-1)),!t)return V;this.host=t}else if(this.isSpecial()){if(e=g(e),A(te,e))return V;if(t=function(e){var t,n,r,o,i,s,a,l=U(e,".");if(l.length&&""==l[l.length-1]&&l.length--,(t=l.length)>4)return e;for(n=[],r=0;r<t;r++){if(""==(o=l[r]))return e;if(i=10,o.length>1&&"0"==T(o,0)&&(i=A(J,o)?16:8,o=z(o,8==i?1:2)),""===o)s=0;else{if(!A(10==i?Z:8==i?Q:ee,o))return e;s=P(o,i)}R(n,s)}for(r=0;r<t;r++)if(s=n[r],r==t-1){if(s>=M(256,5-t))return null}else if(s>255)return null;for(a=L(n),r=0;r<n.length;r++)a+=n[r]*M(256,3-r);return a}(e),null===t)return V;this.host=t}else{if(A(ne,e))return V;for(t="",n=m(e),r=0;r<n.length;r++)t+=ue(n[r],se);this.host=t}},cannotHaveUsernamePasswordPort:function(){return!this.host||this.cannotBeABaseURL||"file"==this.scheme},includesCredentials:function(){return""!=this.username||""!=this.password},isSpecial:function(){return p(de,this.scheme)},shortenPath:function(){var e=this.path,t=e.length;!t||"file"==this.scheme&&1==t&&fe(e[0],!0)||e.length--},serialize:function(){var e=this,t=e.scheme,n=e.username,r=e.password,o=e.host,i=e.port,s=e.path,a=e.query,l=e.fragment,c=t+":";return null!==o?(c+="//",e.includesCredentials()&&(c+=n+(r?":"+r:"")+"@"),c+=ie(o),null!==i&&(c+=":"+i)):"file"==t&&(c+="//"),c+=e.cannotBeABaseURL?s[0]:s.length?"/"+I(s,"/"):"",null!==a&&(c+="?"+a),null!==l&&(c+="#"+l),c},setHref:function(e){var t=this.parse(e);if(t)throw O(t);this.searchParams.update()},getOrigin:function(){var e=this.scheme,t=this.port;if("blob"==e)try{return new Le(e.path[0]).origin}catch(e){return"null"}return"file"!=e&&this.isSpecial()?e+"://"+ie(this.host)+(null!==t?":"+t:""):"null"},getProtocol:function(){return this.scheme+":"},setProtocol:function(e){this.parse(b(e)+":",me)},getUsername:function(){return this.username},setUsername:function(e){var t=m(b(e));if(!this.cannotHaveUsernamePasswordPort()){this.username="";for(var n=0;n<t.length;n++)this.username+=ue(t[n],ce)}},getPassword:function(){return this.password},setPassword:function(e){var t=m(b(e));if(!this.cannotHaveUsernamePasswordPort()){this.password="";for(var n=0;n<t.length;n++)this.password+=ue(t[n],ce)}},getHost:function(){var e=this.host,t=this.port;return null===e?"":null===t?ie(e):ie(e)+":"+t},setHost:function(e){this.cannotBeABaseURL||this.parse(e,Ce)},getHostname:function(){var e=this.host;return null===e?"":ie(e)},setHostname:function(e){this.cannotBeABaseURL||this.parse(e,De)},getPort:function(){var e=this.port;return null===e?"":b(e)},setPort:function(e){this.cannotHaveUsernamePasswordPort()||(""==(e=b(e))?this.port=null:this.parse(e,Ee))},getPathname:function(){var e=this.path;return this.cannotBeABaseURL?e[0]:e.length?"/"+I(e,"/"):""},setPathname:function(e){this.cannotBeABaseURL||(this.path=[],this.parse(e,Be))},getSearch:function(){var e=this.query;return e?"?"+e:""},setSearch:function(e){""==(e=b(e))?this.query=null:("?"==T(e,0)&&(e=z(e,1)),this.query="",this.parse(e,Ae)),this.searchParams.update()},getSearchParams:function(){return this.searchParams.facade},getHash:function(){var e=this.fragment;return e?"#"+e:""},setHash:function(e){""!=(e=b(e))?("#"==T(e,0)&&(e=z(e,1)),this.fragment="",this.parse(e,Ie)):this.fragment=null},update:function(){this.query=this.searchParams.serialize()||null}};var Le=function(e){var t=f(this,Re),n=w(arguments.length,1)>1?arguments[1]:void 0,r=j(t,new Ke(e,!1,n));i||(t.href=r.serialize(),t.origin=r.getOrigin(),t.protocol=r.getProtocol(),t.username=r.getUsername(),t.password=r.getPassword(),t.host=r.getHost(),t.hostname=r.getHostname(),t.port=r.getPort(),t.pathname=r.getPathname(),t.search=r.getSearch(),t.searchParams=r.getSearchParams(),t.hash=r.getHash())},Re=Le.prototype,Ne=function(e,t){return{get:function(){return C(this)[e]()},set:t&&function(e){return C(this)[t](e)},configurable:!0,enumerable:!0}};if(i&&u(Re,{href:Ne("serialize","setHref"),origin:Ne("getOrigin"),protocol:Ne("getProtocol","setProtocol"),username:Ne("getUsername","setUsername"),password:Ne("getPassword","setPassword"),host:Ne("getHost","setHost"),hostname:Ne("getHostname","setHostname"),port:Ne("getPort","setPort"),pathname:Ne("getPathname","setPathname"),search:Ne("getSearch","setSearch"),searchParams:Ne("getSearchParams"),hash:Ne("getHash","setHash")}),d(Re,"toJSON",(function(){return C(this).serialize()}),{enumerable:!0}),d(Re,"toString",(function(){return C(this).serialize()}),{enumerable:!0}),S){var Fe=S.createObjectURL,Ue=S.revokeObjectURL;Fe&&d(Le,"createObjectURL",l(Fe,S)),Ue&&d(Le,"revokeObjectURL",l(Ue,S))}_(Le,"URL"),o({global:!0,forced:!s,sham:!i},{URL:Le})},{"../internals/an-instance":6,"../internals/array-from":8,"../internals/array-slice-simple":10,"../internals/descriptors":22,"../internals/export":29,"../internals/function-bind-context":33,"../internals/function-uncurry-this":37,"../internals/global":43,"../internals/has-own-property":44,"../internals/internal-state":50,"../internals/native-url":63,"../internals/object-assign":65,"../internals/object-define-properties":67,"../internals/redefine":81,"../internals/set-to-string-tag":90,"../internals/string-multibyte":94,"../internals/string-punycode-to-ascii":95,"../internals/to-string":104,"../internals/validate-arguments-length":109,"../modules/es.string.iterator":113,"../modules/web.url-search-params":116}],118:[function(e,t,n){var r,o,i;r=function(e,t,n,o){var i;t[0]=0;for(var s=1;s<t.length;s++){var a=t[s++],l=t[s]?(t[0]|=a?1:2,n[t[s++]]):t[++s];3===a?o[0]=l:4===a?o[1]=Object.assign(o[1]||{},l):5===a?(o[1]=o[1]||{})[t[++s]]=l:6===a?o[1][t[++s]]+=l+"":a?(i=e.apply(l,r(e,l,n,["",null])),o.push(i),l[0]?t[0]|=2:(t[s-2]=0,t[s]=i)):o.push(l)}return o},o=new Map,i=function(e){var t=o.get(this);return t||(t=new Map,o.set(this,t)),(t=r(this,t.get(e)||(t.set(e,t=function(e){for(var t,n,r=1,o="",i="",s=[0],a=function(e){1===r&&(e||(o=o.replace(/^\s*\n\s*|\s*\n\s*$/g,"")))?s.push(0,e,o):3===r&&(e||o)?(s.push(3,e,o),r=2):2===r&&"..."===o&&e?s.push(4,e,0):2===r&&o&&!e?s.push(5,0,!0,o):r>=5&&((o||!e&&5===r)&&(s.push(r,0,o,n),r=6),e&&(s.push(r,e,0,n),r=6)),o=""},l=0;l<e.length;l++){l&&(1===r&&a(),a(l));for(var c=0;c<e[l].length;c++)t=e[l][c],1===r?"<"===t?(a(),s=[s],r=3):o+=t:4===r?"--"===o&&">"===t?(r=1,o=""):o=t+o[0]:i?t===i?i="":o+=t:'"'===t||"'"===t?i=t:">"===t?(a(),r=1):r&&("="===t?(r=5,n=o,o=""):"/"===t&&(r<5||">"===e[l][c+1])?(a(),3===r&&(s=s[0]),r=s,(s=s[0]).push(2,0,r),r=0):" "===t||"\t"===t||"\n"===t||"\r"===t?(a(),r=2):o+=t),3===r&&"!--"===o&&(r=4,s=s[0])}return a(),s}(e)),t),arguments,[])).length>1?t:t[0]},void 0!==t?t.exports=i:self.htm=i},{}],119:[function(e,t,n){t.exports={nanoid:(e=21)=>{let t="",n=e;for(;n--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[64*Math.random()|0];return t},customAlphabet:(e,t=21)=>(n=t)=>{let r="",o=n;for(;o--;)r+=e[Math.random()*e.length|0];return r}}},{}],120:[function(e,t,n){var r,o,i,s,a,l,c,u,d={},f=[],p=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i;function h(e,t){for(var n in t)e[n]=t[n];return e}function m(e){var t=e.parentNode;t&&t.removeChild(e)}function y(e,t,n){var o,i,s,a={};for(s in t)"key"==s?o=t[s]:"ref"==s?i=t[s]:a[s]=t[s];if(arguments.length>2&&(a.children=arguments.length>3?r.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(s in e.defaultProps)void 0===a[s]&&(a[s]=e.defaultProps[s]);return v(e,a,o,i,null)}function v(e,t,n,r,s){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:null==s?++i:s};return null==s&&null!=o.vnode&&o.vnode(a),a}function g(e){return e.children}function b(e,t){this.props=e,this.context=t}function _(e,t){if(null==t)return e.__?_(e.__,e.__.__k.indexOf(e)+1):null;for(var n;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e)return n.__e;return"function"==typeof e.type?_(e):null}function w(e){var t,n;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e){e.__e=e.__c.base=n.__e;break}return w(e)}}function x(e){(!e.__d&&(e.__d=!0)&&a.push(e)&&!k.__r++||c!==o.debounceRendering)&&((c=o.debounceRendering)||l)(k)}function k(){for(var e;k.__r=a.length;)e=a.sort((function(e,t){return e.__v.__b-t.__v.__b})),a=[],e.some((function(e){var t,n,r,o,i,s;e.__d&&(i=(o=(t=e).__v).__e,(s=t.__P)&&(n=[],(r=h({},o)).__v=o.__v+1,B(s,o,r,t.__n,void 0!==s.ownerSVGElement,null!=o.__h?[i]:null,n,null==i?_(o):i,o.__h),M(n,o),o.__e!=i&&w(o)))}))}function j(e,t,n,r,o,i,s,a,l,c){var u,p,h,m,y,b,w,x=r&&r.__k||f,k=x.length;for(n.__k=[],u=0;u<t.length;u++)if(null!=(m=n.__k[u]=null==(m=t[u])||"boolean"==typeof m?null:"string"==typeof m||"number"==typeof m||"bigint"==typeof m?v(null,m,null,null,m):Array.isArray(m)?v(g,{children:m},null,null,null):m.__b>0?v(m.type,m.props,m.key,null,m.__v):m)){if(m.__=n,m.__b=n.__b+1,null===(h=x[u])||h&&m.key==h.key&&m.type===h.type)x[u]=void 0;else for(p=0;p<k;p++){if((h=x[p])&&m.key==h.key&&m.type===h.type){x[p]=void 0;break}h=null}B(e,m,h=h||d,o,i,s,a,l,c),y=m.__e,(p=m.ref)&&h.ref!=p&&(w||(w=[]),h.ref&&w.push(h.ref,null,m),w.push(p,m.__c||y,m)),null!=y?(null==b&&(b=y),"function"==typeof m.type&&m.__k===h.__k?m.__d=l=C(m,l,e):l=D(e,m,h,x,y,l),"function"==typeof n.type&&(n.__d=l)):l&&h.__e==l&&l.parentNode!=e&&(l=_(h))}for(n.__e=b,u=k;u--;)null!=x[u]&&("function"==typeof n.type&&null!=x[u].__e&&x[u].__e==n.__d&&(n.__d=_(r,u+1)),I(x[u],x[u]));if(w)for(u=0;u<w.length;u++)A(w[u],w[++u],w[++u])}function C(e,t,n){for(var r,o=e.__k,i=0;o&&i<o.length;i++)(r=o[i])&&(r.__=e,t="function"==typeof r.type?C(r,t,n):D(n,r,r,o,r.__e,t));return t}function D(e,t,n,r,o,i){var s,a,l;if(void 0!==t.__d)s=t.__d,t.__d=void 0;else if(null==n||o!=i||null==o.parentNode)e:if(null==i||i.parentNode!==e)e.appendChild(o),s=null;else{for(a=i,l=0;(a=a.nextSibling)&&l<r.length;l+=2)if(a==o)break e;e.insertBefore(o,i),s=i}return void 0!==s?s:o.nextSibling}function E(e,t,n){"-"===t[0]?e.setProperty(t,n):e[t]=null==n?"":"number"!=typeof n||p.test(t)?n:n+"px"}function S(e,t,n,r,o){var i;e:if("style"===t)if("string"==typeof n)e.style.cssText=n;else{if("string"==typeof r&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||E(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||E(e.style,t,n[t])}else if("o"===t[0]&&"n"===t[1])i=t!==(t=t.replace(/Capture$/,"")),t=t.toLowerCase()in e?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=n,n?r||e.addEventListener(t,i?P:O,i):e.removeEventListener(t,i?P:O,i);else if("dangerouslySetInnerHTML"!==t){if(o)t=t.replace(/xlink[H:h]/,"h").replace(/sName$/,"s");else if("href"!==t&&"list"!==t&&"form"!==t&&"tabIndex"!==t&&"download"!==t&&t in e)try{e[t]=null==n?"":n;break e}catch(e){}"function"==typeof n||(null!=n&&(!1!==n||"a"===t[0]&&"r"===t[1])?e.setAttribute(t,n):e.removeAttribute(t))}}function O(e){this.l[e.type+!1](o.event?o.event(e):e)}function P(e){this.l[e.type+!0](o.event?o.event(e):e)}function B(e,t,n,r,i,s,a,l,c){var u,d,f,p,m,y,v,_,w,x,k,C=t.type;if(void 0!==t.constructor)return null;null!=n.__h&&(c=n.__h,l=t.__e=n.__e,t.__h=null,s=[l]),(u=o.__b)&&u(t);try{e:if("function"==typeof C){if(_=t.props,w=(u=C.contextType)&&r[u.__c],x=u?w?w.props.value:u.__:r,n.__c?v=(d=t.__c=n.__c).__=d.__E:("prototype"in C&&C.prototype.render?t.__c=d=new C(_,x):(t.__c=d=new b(_,x),d.constructor=C,d.render=K),w&&w.sub(d),d.props=_,d.state||(d.state={}),d.context=x,d.__n=r,f=d.__d=!0,d.__h=[]),null==d.__s&&(d.__s=d.state),null!=C.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=h({},d.__s)),h(d.__s,C.getDerivedStateFromProps(_,d.__s))),p=d.props,m=d.state,f)null==C.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(null==C.getDerivedStateFromProps&&_!==p&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(_,x),!d.__e&&null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(_,d.__s,x)||t.__v===n.__v){d.props=_,d.state=d.__s,t.__v!==n.__v&&(d.__d=!1),d.__v=t,t.__e=n.__e,t.__k=n.__k,t.__k.forEach((function(e){e&&(e.__=t)})),d.__h.length&&a.push(d);break e}null!=d.componentWillUpdate&&d.componentWillUpdate(_,d.__s,x),null!=d.componentDidUpdate&&d.__h.push((function(){d.componentDidUpdate(p,m,y)}))}d.context=x,d.props=_,d.state=d.__s,(u=o.__r)&&u(t),d.__d=!1,d.__v=t,d.__P=e,u=d.render(d.props,d.state,d.context),d.state=d.__s,null!=d.getChildContext&&(r=h(h({},r),d.getChildContext())),f||null==d.getSnapshotBeforeUpdate||(y=d.getSnapshotBeforeUpdate(p,m)),k=null!=u&&u.type===g&&null==u.key?u.props.children:u,j(e,Array.isArray(k)?k:[k],t,n,r,i,s,a,l,c),d.base=t.__e,t.__h=null,d.__h.length&&a.push(d),v&&(d.__E=d.__=null),d.__e=!1}else null==s&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=T(n.__e,t,n,r,i,s,a,c);(u=o.diffed)&&u(t)}catch(e){t.__v=null,(c||null!=s)&&(t.__e=l,t.__h=!!c,s[s.indexOf(l)]=null),o.__e(e,t,n)}}function M(e,t){o.__c&&o.__c(t,e),e.some((function(t){try{e=t.__h,t.__h=[],e.some((function(e){e.call(t)}))}catch(e){o.__e(e,t.__v)}}))}function T(e,t,n,o,i,s,a,l){var c,u,f,p=n.props,h=t.props,y=t.type,v=0;if("svg"===y&&(i=!0),null!=s)for(;v<s.length;v++)if((c=s[v])&&"setAttribute"in c==!!y&&(y?c.localName===y:3===c.nodeType)){e=c,s[v]=null;break}if(null==e){if(null===y)return document.createTextNode(h);e=i?document.createElementNS("http://www.w3.org/2000/svg",y):document.createElement(y,h.is&&h),s=null,l=!1}if(null===y)p===h||l&&e.data===h||(e.data=h);else{if(s=s&&r.call(e.childNodes),u=(p=n.props||d).dangerouslySetInnerHTML,f=h.dangerouslySetInnerHTML,!l){if(null!=s)for(p={},v=0;v<e.attributes.length;v++)p[e.attributes[v].name]=e.attributes[v].value;(f||u)&&(f&&(u&&f.__html==u.__html||f.__html===e.innerHTML)||(e.innerHTML=f&&f.__html||""))}if(function(e,t,n,r,o){var i;for(i in n)"children"===i||"key"===i||i in t||S(e,i,null,n[i],r);for(i in t)o&&"function"!=typeof t[i]||"children"===i||"key"===i||"value"===i||"checked"===i||n[i]===t[i]||S(e,i,t[i],n[i],r)}(e,h,p,i,l),f)t.__k=[];else if(v=t.props.children,j(e,Array.isArray(v)?v:[v],t,n,o,i&&"foreignObject"!==y,s,a,s?s[0]:n.__k&&_(n,0),l),null!=s)for(v=s.length;v--;)null!=s[v]&&m(s[v]);l||("value"in h&&void 0!==(v=h.value)&&(v!==e.value||"progress"===y&&!v||"option"===y&&v!==p.value)&&S(e,"value",v,p.value,!1),"checked"in h&&void 0!==(v=h.checked)&&v!==e.checked&&S(e,"checked",v,p.checked,!1))}return e}function A(e,t,n){try{"function"==typeof e?e(t):e.current=t}catch(e){o.__e(e,n)}}function I(e,t,n){var r,i;if(o.unmount&&o.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||A(r,null,t)),null!=(r=e.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){o.__e(e,t)}r.base=r.__P=null}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&I(r[i],t,"function"!=typeof e.type);n||null==e.__e||m(e.__e),e.__e=e.__d=void 0}function K(e,t,n){return this.constructor(e,n)}function L(e,t,n){var i,s,a;o.__&&o.__(e,t),s=(i="function"==typeof n)?null:n&&n.__k||t.__k,a=[],B(t,e=(!i&&n||t).__k=y(g,null,[e]),s||d,d,void 0!==t.ownerSVGElement,!i&&n?[n]:s?null:t.firstChild?r.call(t.childNodes):null,a,!i&&n?n:s?s.__e:t.firstChild,i),M(a,e)}r=f.slice,o={__e:function(e,t){for(var n,r,o;t=t.__;)if((n=t.__c)&&!n.__)try{if((r=n.constructor)&&null!=r.getDerivedStateFromError&&(n.setState(r.getDerivedStateFromError(e)),o=n.__d),null!=n.componentDidCatch&&(n.componentDidCatch(e),o=n.__d),o)return n.__E=n}catch(t){e=t}throw e}},i=0,s=function(e){return null!=e&&void 0===e.constructor},b.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=h({},this.state),"function"==typeof e&&(e=e(h({},n),this.props)),e&&h(n,e),null!=e&&this.__v&&(t&&this.__h.push(t),x(this))},b.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),x(this))},b.prototype.render=g,a=[],l="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,k.__r=0,u=0,n.render=L,n.hydrate=function e(t,n){L(t,n,e)},n.createElement=y,n.h=y,n.Fragment=g,n.createRef=function(){return{current:null}},n.isValidElement=s,n.Component=b,n.cloneElement=function(e,t,n){var o,i,s,a=h({},e.props);for(s in t)"key"==s?o=t[s]:"ref"==s?i=t[s]:a[s]=t[s];return arguments.length>2&&(a.children=arguments.length>3?r.call(arguments,2):n),v(e.type,a,o||e.key,i||e.ref,null)},n.createContext=function(e,t){var n={__c:t="__cC"+u++,__:e,Consumer:function(e,t){return e.children(t)},Provider:function(e){var n,r;return this.getChildContext||(n=[],(r={})[t]=this,this.getChildContext=function(){return r},this.shouldComponentUpdate=function(e){this.props.value!==e.value&&n.some(x)},this.sub=function(e){n.push(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n.splice(n.indexOf(e),1),t&&t.call(e)}}),e.children}};return n.Provider.__=n.Consumer.contextType=n},n.toChildArray=function e(t,n){return n=n||[],null==t||"boolean"==typeof t||(Array.isArray(t)?t.some((function(t){e(t,n)})):n.push(t)),n},n.options=o},{}],121:[function(e,t,n){var r,o,i,s=e("preact"),a=0,l=[],c=s.options.__b,u=s.options.__r,d=s.options.diffed,f=s.options.__c,p=s.options.unmount;function h(e,t){s.options.__h&&s.options.__h(o,e,a||t),a=0;var n=o.__H||(o.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function m(e){return a=1,y(j,e)}function y(e,t,n){var i=h(r++,2);return i.t=e,i.__c||(i.__=[n?n(t):j(void 0,t),function(e){var t=i.t(i.__[0],e);i.__[0]!==t&&(i.__=[t,i.__[1]],i.__c.setState({}))}],i.__c=o),i.__}function v(e,t){var n=h(r++,4);!s.options.__s&&k(n.__H,t)&&(n.__=e,n.__H=t,o.__h.push(n))}function g(e,t){var n=h(r++,7);return k(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function b(){for(var e;e=l.shift();)if(e.__P)try{e.__H.__h.forEach(w),e.__H.__h.forEach(x),e.__H.__h=[]}catch(t){e.__H.__h=[],s.options.__e(t,e.__v)}}s.options.__b=function(e){o=null,c&&c(e)},s.options.__r=function(e){u&&u(e),r=0;var t=(o=e.__c).__H;t&&(t.__h.forEach(w),t.__h.forEach(x),t.__h=[])},s.options.diffed=function(e){d&&d(e);var t=e.__c;t&&t.__H&&t.__H.__h.length&&(1!==l.push(t)&&i===s.options.requestAnimationFrame||((i=s.options.requestAnimationFrame)||function(e){var t,n=function(){clearTimeout(r),_&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);_&&(t=requestAnimationFrame(n))})(b)),o=null},s.options.__c=function(e,t){t.some((function(e){try{e.__h.forEach(w),e.__h=e.__h.filter((function(e){return!e.__||x(e)}))}catch(n){t.some((function(e){e.__h&&(e.__h=[])})),t=[],s.options.__e(n,e.__v)}})),f&&f(e,t)},s.options.unmount=function(e){p&&p(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach((function(e){try{w(e)}catch(e){t=e}})),t&&s.options.__e(t,n.__v))};var _="function"==typeof requestAnimationFrame;function w(e){var t=o,n=e.__c;"function"==typeof n&&(e.__c=void 0,n()),o=t}function x(e){var t=o;e.__c=e.__(),o=t}function k(e,t){return!e||e.length!==t.length||t.some((function(t,n){return t!==e[n]}))}function j(e,t){return"function"==typeof t?t(e):t}n.useState=m,n.useReducer=y,n.useEffect=function(e,t){var n=h(r++,3);!s.options.__s&&k(n.__H,t)&&(n.__=e,n.__H=t,o.__H.__h.push(n))},n.useLayoutEffect=v,n.useRef=function(e){return a=5,g((function(){return{current:e}}),[])},n.useImperativeHandle=function(e,t,n){a=6,v((function(){"function"==typeof e?e(t()):e&&(e.current=t())}),null==n?n:n.concat(e))},n.useMemo=g,n.useCallback=function(e,t){return a=8,g((function(){return e}),t)},n.useContext=function(e){var t=o.context[e.__c],n=h(r++,9);return n.c=e,t?(null==n.__&&(n.__=!0,t.sub(o)),t.props.value):e.__},n.useDebugValue=function(e,t){s.options.useDebugValue&&s.options.useDebugValue(t?t(e):e)},n.useErrorBoundary=function(e){var t=h(r++,10),n=m();return t.__=e,o.componentDidCatch||(o.componentDidCatch=function(e){t.__&&t.__(e),n[1](e)}),[n[0],function(){n[1](void 0)}]}},{preact:120}],122:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.getAutoRegion=void 0;const r=e("../v7/v7-config"),o=(e,t,n)=>new Promise((r=>{const o=setTimeout((()=>{console.error("Timeout while latency check for ",t),r()}),n);e().then((()=>{clearTimeout(o),r()})).catch((e=>{console.error("Error while latency check for ",t,e),clearTimeout(o),r()}))}));async function i(e){const t=e.ok;if(-1===t.indexOf(e.name))throw new Error("okUrl "+t+" does not contain region "+e);return(async()=>{const e=Date.now();return await fetch(t+"?time="+e,{method:"GET",mode:"cors",cache:"no-cache"}).then((e=>e.text())),Date.now()-e})()}n.getAutoRegion=async function(e){const t=[...r.awsRegions],n=(()=>{const e={};for(const{name:t}of r.awsRegions)e[t]=[];return e})(),l=[];for(const r of t){const t=async()=>{const t=r.name;for(let o=0;o<5;++o)n[t].push(await i(r)),e(t+"#"+(o+1)+" ("+n[t][0]+" ms)")};l.push(o(t,r.name,15e3))}await Promise.all(l);try{const e=/execute-api\.([^.]+)\.amazonaws.com\/dev\/ok/;if("undefined"!=typeof performance&&void 0!==performance.getEntriesByType){const t=performance.getEntriesByType("resource");for(const r of t)if(void 0!==r.name&&void 0!==r.duration){const t=e.exec(r.name);null!==t&&void 0!==t[1]&&n[t[1]].push(Math.round(r.duration))}}}catch(e){console.error("Can't use performance data",e)}let c="eu-central-1",u=-1,d="";const f={};for(const e of Object.keys(n)){const t=a(n[e]);t>0&&(-1===u||u>t)&&(c=e,u=t);const r=s(n[e]);f[e]=r,d+=(e+" ").substring(0,14)+": ["+r.join(", ")+"]\n"}return console.log("Latency estimation:\n"+d),console.log("Auto region:",c,", latency: "+u),{region:c,regionLatency:u,estimation:f}};const s=e=>e.sort(((e,t)=>e-t)),a=e=>0===e.length?0:s(e)[0]},{"../v7/v7-config":124,"core-js/modules/web.dom-collections.iterator.js":115}],123:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.putPersonalBundle=n.getPersonalBundleUrl=void 0;const r=e("../../../v7-services/src/personal"),o=e("../../xhr"),i=e("./v7-config");n.getPersonalBundleUrl=function(e,t,n){return(0,r.getPersonalBundleUrl)(e,t,n)},n.putPersonalBundle=async function(e,t,n,r){const s=await async function(e){const t=new zip.ZipReader(new zip.Uint8ArrayReader(e),{useWebWorkers:!1}),n=await t.getEntries();let r=!0;for(const e of n)if(r=!0===e.directory,!r)break;return t.close(),r}(r);if(s)return void console.warn("Ignore empty changes archive");const a=await(0,o.postObject)(i.personalPut+"?namespace="+e+"&id="+t+"&bundleUrl="+encodeURIComponent(n));if(!a.success)throw new Error("Unable to put personal bundle");const l=JSON.parse(a.payload),c=l.signature,u=l.url;if(c["x-amz-content-sha256"]="UNSIGNED-PAYLOAD",await(0,o.send)("put",u,"text",r.buffer,void 0,c),!(await(0,o.postObject)(i.personalAcl+"?namespace="+e+"&id="+t+"&bundleUrl="+n)).success)throw new Error("Can't set ACL to personal bundle")}},{"../../../v7-services/src/personal":146,"../../xhr":145,"./v7-config":124,"core-js/modules/web.dom-collections.iterator.js":115}],124:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.awsRegions=n.checkoutEndpoint=n.checkoutCreateTokenEndpoint=n.stopIpx=n.startIpx=n.addFreeTimeTierEndpoint=n.tokeInfoGetEndpoint=n.createTokenEndpoint=n.personalAcl=n.personalPut=n.endpointBase=void 0,n.endpointBase="https://kdhkdsv558.execute-api.eu-central-1.amazonaws.com/dev",n.personalPut=n.endpointBase+"/personal/put",n.personalAcl=n.endpointBase+"/personal/acl",n.createTokenEndpoint=n.endpointBase+"/token/create",n.tokeInfoGetEndpoint=n.endpointBase+"/token/info/get",n.addFreeTimeTierEndpoint=n.endpointBase+"/token/add/free",n.startIpx=n.endpointBase+"/token/ipx/start",n.stopIpx=n.endpointBase+"/token/ipx/stop",n.checkoutCreateTokenEndpoint=n.endpointBase+"/checkout/token/create",n.checkoutEndpoint="https://js-dos.com/checkout/index.html",n.awsRegions=[{label:"US East (N. Virginia)",name:"us-east-1",ok:"https://387k8l2vgf.execute-api.us-east-1.amazonaws.com/dev/ok"},{label:"US East (Ohio)",name:"us-east-2",ok:"https://q32vlaa5ji.execute-api.us-east-2.amazonaws.com/dev/ok"},{label:"US West (N. California)",name:"us-west-1",ok:"https://zittdd8vr2.execute-api.us-west-1.amazonaws.com/dev/ok"},{label:"US West (Oregon)",name:"us-west-2",ok:"https://aw3gj5315i.execute-api.us-west-2.amazonaws.com/dev/ok"},{label:"Europe (Frankfurt)",name:"eu-central-1",ok:"https://pdxnceto92.execute-api.eu-central-1.amazonaws.com/dev/ok"},{label:"Europe (Ireland)",name:"eu-west-1",ok:"https://yjm6n35ii4.execute-api.eu-west-1.amazonaws.com/dev/ok"},{label:"Europe (London)",name:"eu-west-2",ok:"https://u8k6qhll5d.execute-api.eu-west-2.amazonaws.com/dev/ok"},{label:"Europe (Milan)",name:"eu-south-1",ok:"https://hn4uxbiro0.execute-api.eu-south-1.amazonaws.com/dev/ok"},{label:"Europe (Paris)",name:"eu-west-3",ok:"https://oce5khcznd.execute-api.eu-west-3.amazonaws.com/dev/ok"},{label:"Europe (Stockholm)",name:"eu-north-1",ok:"https://f3j2j43580.execute-api.eu-north-1.amazonaws.com/dev/ok"},{label:"Asia Pacific (Hong Kong)",name:"ap-east-1",ok:"https://2dji6qhipb.execute-api.ap-east-1.amazonaws.com/dev/ok"},{label:"Asia Pacific (Mumbai)",name:"ap-south-1",ok:"https://0htlj8u1m9.execute-api.ap-south-1.amazonaws.com/dev/ok"},{label:"Asia Pacific (Osaka)",name:"ap-northeast-3",ok:"https://4z9rh02y37.execute-api.ap-northeast-3.amazonaws.com/dev/ok"},{label:"Asia Pacific (Seoul)",name:"ap-northeast-2",ok:"https://dv8crqb5j6.execute-api.ap-northeast-2.amazonaws.com/dev/ok"},{label:"Asia Pacific (Singapore)",name:"ap-southeast-1",ok:"https://e0w35dr520.execute-api.ap-southeast-1.amazonaws.com/dev/ok"},{label:"Asia Pacific (Sydney)",name:"ap-southeast-2",ok:"https://a2bnpow0ul.execute-api.ap-southeast-2.amazonaws.com/dev/ok"},{label:"Asia Pacific (Tokyo)",name:"ap-northeast-1",ok:"https://snvzlstk05.execute-api.ap-northeast-1.amazonaws.com/dev/ok"},{label:"Canada",name:"ca-central-1",ok:"https://wqwl5he8y7.execute-api.ca-central-1.amazonaws.com/dev/ok"},{label:"Middle East (Bahrain)",name:"me-south-1",ok:"https://g480v58gnk.execute-api.me-south-1.amazonaws.com/dev/ok"},{label:"South America (São Paulo)",name:"sa-east-1",ok:"https://wvhym3rtc1.execute-api.sa-east-1.amazonaws.com/dev/ok"},{label:"Africa (Cape Town)",name:"af-south-1",ok:"https://r0atydfi7k.execute-api.af-south-1.amazonaws.com/dev/ok"}]},{}],125:[function(e,t,n){"use strict";var r,o,i;function s(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.ActionBar=void 0;const a=e("../dom"),l=e("../icons"),c=e("./controls");function u(e){if(!0===e.options().noSocialLinks||!0!==e.options().noSideBar)return null;return(0,a.html)(o||(o=s(['\n <div class="h-5 w-5 my-4 text-pink-400 cursor-pointer" onClick=',">\n <",' class="h-5 w-5" />\n </div>\n '])),(function(){window.open("https://dos.zone/","_blank")}),l.Icons.Plus)}function d(e){if(!0===e.options().noSideBar)return null;let t="text-gray-600";return void 0!==e.requestClientId&&null===e.clientId?t="text-red-800 animate-pulse":e.sideBar&&(t="text-green-400"),(0,a.html)(i||(i=s(['\n <div class="h-6 w-6 my-4 ',' cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n '])),t,(function(){e.sideBar?e.closeSideBar():e.openSideBar()}),l.Icons.DotsHorizontal)}n.ActionBar=function(e){if(!e.actionBar)return null;const t=!0===e.options().noSideBar&&!0===e.options().noSocialLinks;return(0,a.html)(r||(r=s(['\n <div class="bg-gray-200 shadow w-10 h-full overflow-hidden flex flex-col items-center">\n <'," ..."," />\n <"," ..."," />\n <",' column="true" class="flex-grow \n ','" \n portal='," ..."," />\n </div>\n "])),d,e,u,e,c.Controls,t?"":" border-t-2 border-gray-400",!0,e)}},{"../dom":139,"../icons":141,"./controls":129}],126:[function(e,t,n){"use strict";var r;Object.defineProperty(n,"__esModule",{value:!0}),n.ActionHide=void 0;const o=e("../dom"),i=e("../icons");n.ActionHide=function(e){return(0,o.html)(r||(t=['\n <div class="filter transition-opacity duration-1000 absolute z-50 \n bg-gray-200 ',"\n w-5 h-12 top-1/2 -mt-6 ",'\n rounded-r-md cursor-pointer" onClick=','>\n <div class="h-4 w-4 my-4">\n <',' class="h-4 w-4" />\n </div>\n </div>\n '],n||(n=t.slice(0)),r=Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(n)}}))),e.actionBar?"":"opacity-80",e.actionBar?"left-10":"left-0",(()=>e.setActionBar(!e.actionBar)),e.actionBar?i.Icons.ChevronLeft:i.Icons.ChevronRight);var t,n}},{"../dom":139,"../icons":141}],127:[function(e,t,n){"use strict";var r;e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.ActionSaveOrExit=void 0;const o=e("preact/hooks"),i=e("../dom"),s=e("../icons");n.ActionSaveOrExit=function(e){const t=e.options().onExit,[n,a]=(0,o.useState)(!1),[l,c]=(0,o.useState)(!1),u="function"==typeof t;return(0,o.useEffect)((()=>{if(!l&&u)return window.addEventListener("beforeunload",t),()=>{window.removeEventListener("beforeunload",t)};function t(t){if(void 0===e.player().ciPromise)return;const n=u?"Please use close button to save progress before closing!":"Please use save button to save progress before closing!";setTimeout((()=>{e.player().layers.notyf.error(n),a(!0)}),16),t.preventDefault(),t.returnValue=n}}),[a,e.player,l,t,u]),l||e.sideBar?null:(0,i.html)(r||(d=['\n <div class="filter transition-opacity duration-1000 absolute z-50\n bg-gray-200 '," w-8 h-8\n top-0 ",' rounded-br-md cursor-pointer" onClick=','>\n <div class="h-6 w-6 mt-1 ml-1">\n <',' class="h-6 w-6" />\n </div>\n </div>\n '],f||(f=d.slice(0)),r=Object.freeze(Object.defineProperties(d,{raw:{value:Object.freeze(f)}}))),n?" text-red-500 animate-pulse":"",e.actionBar?"left-10":"left-0",(async function(){try{a(!1),c(!0);const n=e.player();n.layers.notyf.success("Saving, please wait...");try{await n.layers.save()}catch(e){console.error(e),n.layers.notyf.error(e.message)}if(u){try{await n.stop()}catch(e){console.error(e),n.layers.notyf.error(e.message)}t()}}finally{c(!1)}}),u?s.Icons.XCircle:s.Icons.FloppyDisk);var d,f}},{"../dom":139,"../icons":141,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],128:[function(e,t,n){"use strict";var r,o;function i(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.Client=void 0;const s=e("preact/hooks"),a=e("../dom"),l=e("../icons"),c=e("../dom");n.Client=function(e){const[t,n]=(0,s.useState)(!1);if(void 0===e.requestClientId&&null===e.clientId)return null;if(null===e.clientId){const o=()=>{void 0!==e.requestClientId&&(n(!0),e.requestClientId(!0).then((t=>{n(!1),e.setClientId(t)})).catch((e=>{n(!1),console.error(e)})))};return(0,a.html)(r||(r=i(['\n <div class="flex flex-row justify-center items-center ','">\n <div class="h-6 w-6 text-red-800 animate-pulse mr-2">\n <',' class="h-6 w-6" />\n </div>\n <div class="border-2 rounded px-4\n ',' \n cursor-pointer" onClick=',">\n Login\n </div>\n </div>\n "])),e.class,l.Icons.UserCircle,t?" text-gray-400 border-gray-400":"text-blue-400 border-blue-400",o)}const u=e.clientId.id;return(0,a.html)(o||(o=i(['\n <div class="flex flex-row justify-center ','">\n <div class="h-6 w-6 text-green-400 mr-2">\n <',' class="h-6 w-6" />\n </div>\n <div class="flex-shrink overflow-hidden overflow-ellipsis">','</div>\n <div class="h-6 w-6 ml-2 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n '])),e.class,l.Icons.UserCircle,u,(async function(){e.closeSideBar();const t=e.player();try{await async function(e){if(!e.ciPromise)return;const t=await e.ciPromise,n=await t.persist();(0,c.downloadFile)(n,"saves.zip","application/zip")}(t)}catch(e){t.layers.notyf.error("Unexpected error"),console.error(e)}}),l.Icons.Download)}},{"../dom":139,"../icons":141,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],129:[function(e,t,n){"use strict";var r,o,i;function s(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.Controls=void 0;const a=e("preact/hooks"),l=e("../dom"),c=e("../icons");function u(e){const[t,n]=(0,a.useState)(!1),[r,i]=(0,a.useState)(!1),[u,d]=(0,a.useState)(e.player().sensitivity);async function f(r,o){r.stopPropagation(),await e.setAutolock(o),t&&n(!1)}let p=Math.round(10*u)/10+"";1===p.length&&(p+=".0");const h=e.portal&&!e.autolock&&(t||r);return(0,l.html)(o||(o=s(['\n <div class="h-6 w-6 text-green-400 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n <div class="',' absolute z-50 \n bg-gray-200 -mt-7 h-8 left-10 flex flex-row items-center\n rounded-r-md cursor-pointer" onClick=','>\n <div class="flex flex-row ','">\n <div class="h-6 w-6 mx-2 \n ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 mx-2 \n ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 mx-2 pl-2 border-l-2 border-gray-400 text-gray-400 ',"\n ",'"\n onClick=',">\n ",'\n </div>\n </div>\n\n <div class="h-6 w-10 pr-2 pl-2 border-l-2 border-gray-400 ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n </div>\n '])),(async function(r){e.portal?n(!t):await async function(t){await f(t,!e.autolock)}(r)}),e.autolock?c.Icons.CursorClick:c.Icons.Cursor,e.portal?"":"hidden",(()=>{}),t?"":"hidden",e.autolock?"text-black":"text-green-400",(e=>f(e,!1)),c.Icons.Cursor,e.autolock?"text-green-400":"text-black",(e=>f(e,!0)),c.Icons.CursorClick,e.autolock?"":"hidden","1.0"===p?"text-black":"text-green-400",(async function(t){let n=u+.1;u>2&&(n=.1),await e.player().setSensitivity(n),d(n),t.stopPropagation()}),p,h?"":"hidden",(function(o){var s;null===(s=e.player().ciPromise)||void 0===s||s.then((e=>{e.sendMouseSync()})),r||i(!0),t&&n(!1),o.stopPropagation()}),c.Icons.Refresh)}function d(e){const[t,n]=(0,a.useState)(!1),[r,o]=(0,a.useState)(e.player().scaleControls);let u=Math.round(10*r)/10+"";return 1===u.length&&(u+=".0"),(0,l.html)(i||(i=s(['\n <div class="h-6 w-6 text-green-400 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n <div class="',' absolute z-50 bg-gray-200 -mt-7 h-8 left-10 flex flex-row items-center\n rounded-r-md cursor-pointer" onClick=','>\n <div class="h-6 w-6 mx-2 \n ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 mx-2 \n ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 mx-2 ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 px-2 border-l-2 border-gray-400 \n ','"\n onClick=',">\n ","\n </div>\n </div>\n </div>\n "])),(function(){e.portal?n(!t):e.setMobileControls(!e.mobileControls)}),e.mirroredControls?c.Icons.SwithcHorizontal:e.mobileControls?c.Icons.Mobile:c.Icons.EyeOff,t?"":"hidden",(()=>{}),e.mobileControls||e.mirroredControls?"text-black":"text-green-400",(async function(t){await e.setMirroredControls(!1),await e.setMobileControls(!1),n(!1),t.stopPropagation()}),c.Icons.EyeOff,!e.mirroredControls&&e.mobileControls?"text-green-400":"text-black",(async function(t){await e.setMobileControls(!0),await e.setMirroredControls(!1),n(!1),t.stopPropagation()}),c.Icons.Mobile,e.mirroredControls?"text-green-400":"text-black",(async function(t){await e.setMirroredControls(!0),n(!1),t.stopPropagation()}),c.Icons.SwithcHorizontal,"1.0"===u?"text-black":"text-green-400",(async function(t){let n=r+.1;r>1.5&&(n=1),await e.player().setScaleControls(n),o(n),t.stopPropagation()}),u)}n.Controls=function(e){return(0,l.html)(r||(r=s(['\n <div class="flex '," justify-evenly ",'">\n <'," ..."," />\n <"," ...",' />\n <div class="h-6 w-6 ',' cursor-pointer"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 ',' cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 ',' cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 '," \n ",' cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n '])),e.column?" flex-col":"flex-row",e.class,u,e,d,e,e.pause?" text-red-400 animate-pulse":"font-bold",(function(){e.setPause(!e.pause),e.closeSideBar()}),e.pause?c.Icons.Play:c.Icons.Pause,e.mute?" text-green-400":"",(function(){e.setMute(!e.mute),e.closeSideBar()}),e.mute?c.Icons.VolumeOff:c.Icons.VolumeUp,e.keyboard?" text-green-400":"",(function(){e.toggleKeyboard(),e.closeSideBar()}),c.Icons.PencilAlt,e.fullscreen?" text-green-400":"",!0===e.options().noFullscreen?"hidden":"",(function(){e.toggleFullscreen(),e.closeSideBar()}),c.Icons.ArrowsExpand)}},{"../dom":139,"../icons":141,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],130:[function(e,t,n){"use strict";var r;Object.defineProperty(n,"__esModule",{value:!0}),n.Region=void 0;const o=e("../dom"),i=e("../icons");n.Region=function(e){let t=e.region;return null!==t&&null!==e.latencyInfo&&(t+=" ("+e.latencyInfo.regionLatency+" ms)"),(0,o.html)(r||(n=['\n <div class="flex flex-row justify-between items-center ','">\n <div class="text-gray-600">Region</div>\n <div class="px-4 overflow-hidden overflow-ellipsis whitespace-nowrap flex-shrink">\n ','\n </div>\n <div class="h-6 w-6 ','" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n '],s||(s=n.slice(0)),r=Object.freeze(Object.defineProperties(n,{raw:{value:Object.freeze(s)}}))),e.class,t||e.estimatingRegion||"Connecting...",null===e.region?"animate-spin":"cursor-pointer",(function(){null!==e.region&&e.setRegion(null)}),i.Icons.Refresh);var n,s}},{"../dom":139,"../icons":141}],131:[function(e,t,n){"use strict";var r,o,i;function s(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.SideBar=void 0;const a=e("preact/hooks"),l=e("../dom"),c=e("../icons"),u=e("./sidebar/main"),d=e("./sidebar/latency-info"),f=e("./sidebar/networking"),p=e("../backend/v7/latency");function h(e){if(!0===e.options().noSocialLinks)return null;function t(){window.open("https://discord.com/invite/hMVYEbG","_blank")}function n(){window.open("https://t.me/doszonechat","_blank")}return!0===("networking"===e.sideBarPage)?(0,l.html)(o||(o=s(['\n <div class="flex flex-row justify-around items-center">\n <div class="font-bold text-purple-600">Matchmaking:</div>\n <div class="h-6 w-6 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-4 w-4 mt-0.5 text-gray-600 cursor-poiner" onClick=',">\n <",' class="h-4 w-4" />\n </div>\n </div>\n '])),t,c.Icons.Discord,n,c.Icons.Telegram):(0,l.html)(i||(i=s(['\n <div class="flex flex-row justify-around">\n <div class="h-6 w-6 -mt-1 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-4 w-4 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-4 w-4" />\n </div>\n <div class="h-4 w-4 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-4 w-4" />\n </div>\n <div class="h-6 w-6 -mt-1 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n '])),t,c.Icons.Discord,n,c.Icons.Telegram,(function(){window.open("https://twitter.com/intent/user?screen_name=doszone_db","_blank")}),c.Icons.Twitter,(function(){window.open("https://dos.zone/donate/","_blank")}),c.Icons.CurrencyDollar)}n.SideBar=function(e){if(!e.sideBar)return null;(0,a.useEffect)((()=>{null===e.region&&(0,p.getAutoRegion)(e.setEstimatingRegion).then((t=>{e.setLatencyInfo(t),e.setRegion(t.region)})).catch(console.error)}),[e.region]);const t="networking"===e.sideBarPage;return(0,l.html)(r||(r=s(['\n <div class="flex flex-col filter absolute z-50 top-0 bottom-0 right-0 px-8 pt-6\n w-full sm:w-80 rounded-l-lg drop-shadow-lg bg-white overflow-y-auto overflow-x-hidden pb-4">\n <div class="transform absolute text-gray-400 hover:text-gray-800\n top-2 left-2 cursor-pointer hover:scale-125" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="transform absolute text-gray-400 hover:text-gray-800\n top-2 right-2 cursor-pointer hover:scale-125\n ','" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n \n \n <'," ..."," />\n <"," ..."," />\n <"," ...",' />\n\n <div class="flex-grow"></div>\n \n <'," ..."," />\n </div>\n "])),(function(){"main"===e.sideBarPage?e.closeSideBar():e.setSideBarPage("main")}),"main"===e.sideBarPage?c.Icons.XCircle:c.Icons.ArrowsCircleLeft,t?"text-purple-400":"",(function(){t?window.open("https://youtu.be/XEoWLQmU168","_blank"):(e.setShowTips(!0),e.closeSideBar())}),c.Icons.QuestionMarkCircle,u.Main,e,d.LatencyInfo,e,f.Networking,e,h,e)}},{"../backend/v7/latency":122,"../dom":139,"../icons":141,"./sidebar/latency-info":132,"./sidebar/main":133,"./sidebar/networking":134,"preact/hooks":121}],132:[function(e,t,n){"use strict";var r,o,i,s,a;function l(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.LatencyInfo=void 0;const c=e("../../dom"),u=e("../../icons");n.LatencyInfo=function(e){if(null===e.latencyInfo)return null;const t=t=>{e.setSideBarPage("latency-info"),t.stopPropagation(),t.preventDefault()};if(!0===e.asButton&&"main"===e.sideBarPage)return(0,c.html)(r||(r=l(['\n <div class="flex flex-row justify-between items-center cursor-pointer ',' my-2"\n onClick=','>\n <div class="">\n Show latency\n </div>\n <div>\n <',' class="text-green-400 h-6 -w-6" />\n </div>\n </div>\n '])),e.class,t,u.Icons.ArrowsCircleRight);if("latency-info"!==e.sideBarPage)return null;const n=[];for(const t of Object.keys(e.latencyInfo.estimation)){const r=[];r.push((0,c.html)(o||(o=l(['<div class="text-xs w-24 font-bold whitespace-nowrap break-words">',"</div>"])),t));for(let n=0;n<4;++n)r.push((0,c.html)(i||(i=l(['\n <div class="text-xs text-gray-600 text-right">\n ',"\n </div>\n "])),e.latencyInfo.estimation[t][n]));n.push((0,c.html)(s||(s=l(['<div class="flex flex-row flex-wrap justify-between">',"</div>"])),r))}return(0,c.html)(a||(a=l(['\n <div class="sidebar-header">Latency</div>\n <div class="flex flex-col">\n ',"\n </div>\n "])),n)}},{"../../dom":139,"../../icons":141,"core-js/modules/web.dom-collections.iterator.js":115}],133:[function(e,t,n){"use strict";var r,o;function i(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.Main=void 0;const s=e("../../dom"),a=e("../client"),l=e("../controls"),c=e("../region"),u=e("./latency-info"),d=e("../../icons");function f(e){return!0!==e.options().withExperimentalApi||null===e.region?null:(0,s.html)(o||(o=i(['\n <div class="flex flex-row justify-between items-center cursor-pointer ','"\n onClick=','>\n <div class="">\n Configure networks\n </div>\n <div>\n <',' class="text-green-400 h-6 -w-6" />\n </div>\n </div>\n '])),e.class,(()=>e.setSideBarPage("networking")),d.Icons.ArrowsCircleRight)}n.Main=function(e){return"main"!==e.sideBarPage?null:(0,s.html)(r||(r=i(["\n <",' class="mt-2 mb-2 pb-2 border-b-2 border-green-200" ...'," />\n <",' class="mt-2" portal='," ...",' />\n <div class="sidebar-header mt-8">Networking</div>\n <',' class="mt-2" ...'," />\n <"," ...",' class="mt-4" asButton='," />\n <"," ...",' class="mt-2" />\n '])),a.Client,e,l.Controls,!1,e,c.Region,e,u.LatencyInfo,e,!0,f,e)}},{"../../dom":139,"../../icons":141,"../client":128,"../controls":129,"../region":130,"./latency-info":132}],134:[function(e,t,n){"use strict";var r;Object.defineProperty(n,"__esModule",{value:!0}),n.Networking=void 0;const o=e("../../dom"),i=e("./token/token");n.Networking=function(e){return"networking"!==e.sideBarPage?null:(0,o.html)(r||(t=["\n <"," ..."," />\n "],n||(n=t.slice(0)),r=Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(n)}}))),i.TokenConfiguration,e);var t,n}},{"../../dom":139,"./token/token":137}],135:[function(e,t,n){"use strict";var r,o,i,s,a;function l(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.TokenAddTime=void 0;const c=e("preact/hooks"),u=e("../../../backend/v7/v7-config"),d=e("../../../dom"),f=e("../../../icons"),p=e("../../../request"),h=1800;n.TokenAddTime=function(e){const[t,n]=(0,c.useState)(null),[m,y]=(0,c.useState)(!1),[v,g]=(0,c.useState)(h),[b,_]=(0,c.useState)(null),[w,x]=(0,c.useState)(!1),k=m||v!==h&&null===b;return(0,d.html)(r||(r=l(['\n <div class="font-bold">Add time:</div>\n ',"\n \n ","\n \n "])),w?(0,d.html)(o||(o=l(['\n <div class="cursor-pointer underline text-green-600 font-bold" onClick=',">\n check payment\n </div> \n "])),e.update):(0,d.html)(i||(i=l(['\n <div class="flex flex-row">\n <select disabled=',' class="w-14 flex-grow mr-2 \n ',' "\n name="select" onChange=',">\n <option value=",' selected>FREE</option>\n <option value="259200">+3 Days</option>\n <option value="864000">+10 Days</option>\n <option value="2592000">+30 Days</option>\n </select>\n ',"\n </div>\n "])),m,m?"border-gray-400 disabled:bg-gray-200":"",(async function(t){const n=Number.parseInt(t.currentTarget.value);try{y(!0),_(null),g(n),n!==h&&_(await async function(e,t){var n;const r=null!==(n=t.clientId)&&void 0!==n?n:t.anonymousClientId;return(await(0,p.request)(u.checkoutCreateTokenEndpoint,"POST",JSON.stringify({id:r.id,namespace:r.namespace,product:e,token:t.networkToken}))).token}("t_"+n,e))}finally{y(!1)}}),h,k?f.Icons.Refresh({class:"h-6 w-6 animate-spin"}):(0,d.html)(s||(s=l(['\n <div class="h-6 w-6 cursor-pointer text-green-400 hover:text-green-600"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n '])),(async function(t){if(t.stopPropagation(),!m){n(null),y(!0);try{if(v===h)await(0,p.request)(u.addFreeTimeTierEndpoint,"POST",JSON.stringify({token:e.networkToken})),e.update();else{if(null===b)throw new Error("accessToken is null");!function(e){window.open(u.checkoutEndpoint+"?token="+e,"_blank")}(b),setTimeout((()=>{x(!0)}),300)}}catch(t){n(function(e){if("30-min-required"===e)return"Only 30 minutes interval are enabled";if("free-soft-limit"===e)return"This token reached free time limit, please use paid time";if("free-hard-limit"===e)return"All free time of today is used, please use paid time";if("not-found"===e)return"Token not found";if("too-early"===e)return"You can add free time only if TTL less then 5 minutes";return e}(t.message))}finally{y(!1)}}}),f.Icons.Plus)),t?(0,d.html)(a||(a=l(['\n <div class="font-bold text-red-400 col-span-2">*',"</div>\n "])),t):null)}},{"../../../backend/v7/v7-config":124,"../../../dom":139,"../../../icons":141,"../../../request":144,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],136:[function(e,t,n){"use strict";var r,o,i,s;function a(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.TokenSelect=void 0;const l=e("../../../backend/v7/v7-config"),c=e("preact/hooks"),u=e("../../../request"),d=e("../../../dom"),f=e("../../../icons");n.TokenSelect=function(e){var t;const[n,p]=(0,c.useState)(null!==(t=e.networkToken)&&void 0!==t?t:""),[h,m]=(0,c.useState)(null),[y,v]=(0,c.useState)(!1),g=n===e.networkToken||""===n;function b(e){var t;p((null!==(t=e.currentTarget.value)&&void 0!==t?t:"").toLowerCase().trim())}async function _(){v(!0);try{if(g)return void(null!==e.networkToken&&!0!==window.confirm("Are you sure want to create token?")||await async function(){var t;if(y||null===e.region)return void m("region is not selected");m(null),v(!0);const n=null!==(t=e.clientId)&&void 0!==t?t:e.anonymousClientId;try{const t=await(0,u.request)(l.createTokenEndpoint,"POST",JSON.stringify({namespace:n.namespace,id:n.id,region:e.region}));e.setNetworkToken(t.token)}catch(e){m(e.message)}finally{v(!1)}}());const t=0===n.length?null:n;if(t===e.networkToken)return;!0===window.confirm(null===t?"Are you sure want to reset?":"Are you sure want to switch token?")&&(null!==t&&await async function(e){await(0,u.request)(l.tokeInfoGetEndpoint+"?token="+e)}(t),e.setNetworkToken(n))}catch(e){m("Token error: "+e.message)}finally{v(!1)}}return(0,d.html)(r||(r=a(['\n <div class="font-bold">Token:</div>\n\n ',"\n \n ","\n "])),y?(0,d.html)(o||(o=a(['\n <div class="col-span-2">\n <',' class="w-6 h-6 animate-spin" />\n </div>\n '])),f.Icons.Refresh):(0,d.html)(i||(i=a(['\n <div class="flex flex-row">\n <input class="rounded border ',' \n px-2 w-14 flex-grow mr-2" type="text" value='," \n onChange="," onKeyUp="," onKeyDown=",' />\n <div class="h-6 w-6 cursor-pointer ','" \n onClick=',">\n <",' \n class="h-6 w-6" />\n </div>\n </div>\n '])),""===n?"border-red-600":"border-green-200",n,b,(function(e){b(e),"Enter"===e.key&&_(),e.stopPropagation()}),(function(e){e.stopPropagation()}),g?"text-green-400 hover:text-green-600":"",_,g?f.Icons.Plus:f.Icons.SwithcHorizontal),h?(0,d.html)(s||(s=a(['\n <div class="text-red-400 col-span-2">',"</div>\n "])),h):null)}},{"../../../backend/v7/v7-config":124,"../../../dom":139,"../../../icons":141,"../../../request":144,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],137:[function(e,t,n){"use strict";var r,o,i,s,a,l,c,u,d,f,p,h;function m(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.TokenConfiguration=void 0;const y=e("preact/hooks"),v=e("../../../backend/v7/v7-config"),g=e("../../../dom"),b=e("../../../icons"),_=e("../../../xhr"),w=e("../../../request"),x=e("./token-select"),k=e("./token-add-time");function j(e){const[t,n]=(0,y.useState)(e.endTime-Date.now());return(0,y.useEffect)((()=>{if(t<=0)return;const r=setInterval((()=>{const t=Math.max(0,e.endTime-Date.now());0===t&&(e.update(),clearInterval(r)),n(t)}),1e4);return()=>clearInterval(r)}),[e.endTime]),(0,g.html)(l||(l=m(['\n <div class="font-bold">TTL:</div>\n <div class="',' cursor-pointer underline"\n onClick=',">\n ","\n </div>\n "])),t<3e5?" text-red-400":"text-gray-400",e.update,function(e){if(e>86400){const t=Math.round(e/24/60/60*10)/10;return t+(1===t?" Day":" Days")}if(e>3600){const t=Math.round(e/60/60*10)/10;return t+(1===t?" Hour":" Hrs")}return Math.round(e/60*10)/10+" Min"}(t/1e3))}function C(e){const[t,n]=(0,y.useState)(!1),[r,o]=(0,y.useState)(null);function i(){n(!0),(0,_.postObject)(v.stopIpx+"?token=".concat(e.networkToken,"&arn=").concat(e.ipx.ipxArn)).then((()=>{n(!1),e.ipx.setIpxAddress(null),e.ipx.setAwaitingIpxAddress(!1)})).catch((e=>{var t;console.error("Can't stop ipx",e),o(null!==(t=e.errorCode)&&void 0!==t?t:e.message),n(!1)}))}return null!==r?(0,g.html)(c||(c=m(['\n <div class="text-red-400 col-span-2">',"</div>\n "])),r):t?(0,g.html)(u||(u=m(["\n <",' class="w-6 h-6 col-span-2 animate-spin" />\n '])),b.Icons.Refresh):null!==e.ipx.ipxAddress?(0,g.html)(d||(d=m(['\n <div class="font-bold">IPX:</div>\n <div class="font-bold text-gray-400 text-xs break-all -mx-6 text-center">','</div>\n <div class=""></div>\n <div class="','\n cursor-pointer rounded uppercase text-center px-2 py-1"\n onClick=',">",'</div>\n <div class="','"></div>\n <div class="','\n bg-gray-200 cursor-pointer rounded uppercase text-center px-4 py-1"\n onClick=',">Stop</div>\n "])),e.ipx.ipxAddress,e.ipxConnected?" bg-red-200":"bg-green-200",(function(){var t;const n=!e.ipxConnected,r=e.ipx.ipxAddress;r&&(null===(t=e.player().ciPromise)||void 0===t||t.then((e=>n?e.networkConnect(0,r,1901):e.networkDisconnect(0))).then((()=>{e.setIpxConnected(n),n&&(e.player().layers.notyf.success("Connected"),e.closeSideBar())})).catch((e=>{console.error(e),o(e.message)})))}),e.ipxConnected?"Disconnect":"Connect",e.ipxConnected?"hidden":"",e.ipxConnected?"hidden":"none",i):e.ipx.awaitingIpxAddress?(0,g.html)(f||(f=m(['\n <div class="font-bold">IPX:</div>\n <',' />\n <div class=""></div>\n <div class="bg-gray-200 cursor-pointer rounded uppercase text-center px-4 py-1" onClick=',">Stop</div>\n "])),D,i):(0,g.html)(p||(p=m(['\n <div class="font-bold">IPX:</div>\n <div class="bg-green-200 cursor-pointer rounded uppercase text-center px-4 py-1" onClick=',">Start</div>\n "])),(function(){n(!0),(0,_.getObject)(v.startIpx+"?token=".concat(e.networkToken)).then((t=>{n(!1),e.ipx.setIpxArn(t.arn),e.ipx.setAwaitingIpxAddress(!0)})).catch((e=>{var t;console.error("Can't start ipx",e),o(null!==(t=e.errorCode)&&void 0!==t?t:e.message),n(!1)}))}))}function D(){const[e,t]=(0,y.useState)(30);return(0,y.useEffect)((()=>{if(0===e)return;const n=setTimeout((()=>{t(e-1)}),1e3);return()=>clearTimeout(n)}),[e]),(0,g.html)(h||(h=m(['\n <div class="text-gray-400 flex flex-row">\n <',' class="w-6 h-6 animate-spin mr-2" />\n ',"\n </div>\n "])),b.Icons.Refresh,e>0?e+" sec":"")}n.TokenConfiguration=function(e){const[t,n]=(0,y.useState)(null),[l,c]=(0,y.useState)(!0),[u,d]=(0,y.useState)(Date.now()),[f,p]=(0,y.useState)(null),[h,_]=(0,y.useState)(null),[D,E]=(0,y.useState)(!1),S={ipxArn:f,setIpxArn:p,ipxAddress:h,setIpxAddress:_,awaitingIpxAddress:D,setAwaitingIpxAddress:E},O={...e,ipx:S,update:P};async function P(){if(p(null),_(null),E(!1),c(!0),null===e.networkToken)return n(null),void c(!1);(0,w.request)(v.tokeInfoGetEndpoint+"?token=".concat(e.networkToken)).then((e=>{n(e),c(!1),d(Date.now()+1e3*e.ttlSec),void 0!==e.ipxArn&&p(e.ipxArn),void 0!==e.ipxAddress?_(e.ipxAddress):void 0!==e.ipxArn&&E(!0)})).catch((t=>{console.error("Can't get a token",e.networkToken,t),n(null),c(!1)}))}if((0,y.useEffect)((()=>{P()}),[e.networkToken]),(0,y.useEffect)((()=>{if(null===e.networkToken||u<Date.now())return;const t=setInterval((()=>{(0,w.request)(v.tokeInfoGetEndpoint+"?token=".concat(e.networkToken)).then((e=>{e.ipxArn||(e.ipxArn=null),e.ipxAddress||(e.ipxAddress=null),f===e.ipxArn?e.ipxAddress!==h&&(_(e.ipxAddress),E(!1)):P()}))}),5e3);return()=>{clearInterval(t)}}),[e.networkToken,u,f,h]),l)return(0,g.html)(r||(r=m(['\n <div class="sidebar-header">Configuration</div>\n <div class="grid grid-cols-2 gap-4">\n <',' class="w-6 h-6 animate-spin" />\n </div>\n '])),b.Icons.Refresh);if(null===t)return(0,g.html)(o||(o=m(['\n <div class="sidebar-header">Configuration</div>\n <div class="grid grid-cols-2 gap-4">\n <'," ..."," networkToken="," />\n </div>\n "])),x.TokenSelect,e,null);const B=(0,g.html)(i||(i=m(['\n <div class="sidebar-header flex flex-row justify-center items-center">\n Configuration\n <div onClick='," >\n <",' class="h-4 w-4 ml-2 cursor-pointer" />\n </div>\n </div>\n '])),P,b.Icons.Refresh);return u<Date.now()?(0,g.html)(s||(s=m(["\n ",'\n <div class="grid grid-cols-2 gap-4">\n <'," ...",' />\n <div class="font-bold">Region:</div>\n <div class="text-gray-400">','</div>\n <div class="font-bold">TTL:</div>\n <div class="text-red-400">0 Min</div>\n <'," ..."," />\n </div>\n "])),B,x.TokenSelect,e,t.region,k.TokenAddTime,O):(0,g.html)(a||(a=m(["\n ",'\n <div class="grid grid-cols-2 gap-4">\n <'," ...",' />\n <div class="font-bold">Region:</div>\n <div class="text-gray-400">',"</div>\n <"," endTime="," update="," />\n <"," ..."," />\n <"," ..."," />\n </div>\n "])),B,x.TokenSelect,e,t.region,j,u,P,k.TokenAddTime,O,C,O)}},{"../../../backend/v7/v7-config":124,"../../../dom":139,"../../../icons":141,"../../../request":144,"../../../xhr":145,"./token-add-time":135,"./token-select":136,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],138:[function(e,t,n){"use strict";var r,o,i,s,a,l;function c(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.Tips=void 0;const u=e("preact/hooks"),d=e("../dom"),f=e("../icons"),p={common:{title:"Tips",tip:(0,d.html)(r||(r=c(["\n <div>\n On the left side of the screen you can see a sidebar, it has a set of useful controls.\n You can hide it at any time by pressing on the arrow in the middle.\n </div>\n"])))},mouse:{title:"Mouse",tip:(0,d.html)(o||(o=c(['\n <div>\n <p class="mb-2">\n By clicking on pointer icon you can switch between <b>regular mouse emulation</b> and <b>lock mode</b>.\n </p>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - In regular mouse emulation mode game will receive\n borwser pointer coordinates. If the browser pointer and game pointer is out of sync then use\n </p>\n <',' class="h-4 w-4 text-green-400 mx-2 inline-block" />\n <p class="inline">\n refresh control to synchronize dos and browser pointer poistion.\n </p>\n </div>\n </div>\n '])),f.Icons.Cursor,f.Icons.Refresh)},mouseLock:{title:"Mouse lock",tip:(0,d.html)(i||(i=c(['\n <div>\n <p class="mb-2">\n Some DOS games do not respect the mouse cursor position, they take into account only relative movement \n of the mouse cursor.\n </p>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - When the mouse is locked DOS game receives only the relative movement of mouse and\n the cursor can\'t leave the game screen. You can use sensitivity control (inside the mouse submenu)\n to change the sensitivity of mouse movement.\n </p>\n </div>\n </div>\n '])),f.Icons.CursorClick)},mobile:{title:"Mobile",tip:(0,d.html)(s||(s=c(['\n <div>\n <p>\n You can change visibility of mobile controls by pressing on of this buttons:\n </p>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - shows the mobile controls if they are provided by the game.\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - shows the mobile controls but mirrored.\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - completely hide the mobile controls.\n </p>\n </div>\n <p>\n You can <b>SCALE</b> the size of mobile controls inside submenu.\n </p>\n </div>\n '])),f.Icons.Mobile,f.Icons.SwithcHorizontal,f.Icons.EyeOff)},other:{title:"Other",tip:(0,d.html)(a||(a=c(['\n <div>\n <p>\n Game controls:\n </p>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - pause/resume game,\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - mute/unmute sound,\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - toggle soft keyboard,\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - toggle fullscreen,\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - will open the settings sidebar, where you can change additional\n settings of js-dos like networking.\n </p>\n </div>\n </div>\n '])),f.Icons.Pause,f.Icons.VolumeUp,f.Icons.PencilAlt,f.Icons.ArrowsExpand,f.Icons.DotsHorizontal)}},h=/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(navigator.userAgent.toLowerCase())?["common","mobile","mouse","mouseLock","other"]:["common","mouse","mouseLock","mobile","other"];n.Tips=function(e){const[t,n]=(0,u.useState)(0);if(!e.showTips)return null;const r=p[h[t]];return(0,d.html)(l||(l=c(['\n <div class="absolute z-50 rounded bg-gray-200 shadow-lg top-5 right-5 w-64 p-2 border-b border-gray-800">\n <div class="flex row justify-between mb-2">\n <div class="h-6 w-6 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="text-lg font-bold">','</div>\n <div class="h-6 w-6 cursor-pointer text-blue-600 animate-pulse" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n <div class="text-sm px-2 overflow-auto max-h-72">\n ',"\n </div>\n </div>\n "])),(()=>e.setShowTips(!1)),f.Icons.XCircle,r.title,(function(){n((t+1)%h.length)}),f.Icons.ArrowsCircleRight,r.tip)}},{"../dom":139,"../icons":141,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],139:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),e("core-js/modules/web.url.js"),e("core-js/modules/web.url-search-params.js");var r=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:!0}),n.downloadFile=n.click=n.createDiv=n.activeClass=n.primaryClass=n.disabledClass=n.goneClass=n.html=void 0;const o=e("preact"),i=r(e("htm"));n.html=i.default.bind(o.h),n.goneClass="jsdos-player-gone",n.disabledClass="jsdos-player-button-disabled",n.primaryClass="jsdos-player-button-primary",n.activeClass="jsdos-player-button-active",n.createDiv=function(e,t){const n=document.createElement("div");if("string"==typeof e)n.className=e;else for(const t of e)n.classList.add(t);return void 0!==t&&(n.innerHTML=t),n},n.click=function(e,t){for(const n of emulatorsUi.dom.pointers.bind.enders)e.addEventListener(n,(()=>{e.classList.contains("jsdos-player-button-disabled")||t(e)}))};let s=null;n.downloadFile=function(e,t,n){const r=new Blob([e],{type:n});null!==s&&window.URL.revokeObjectURL(s),s=window.URL.createObjectURL(r);const o=document.createElement("a");o.href=s,o.download=t,o.style.display="none",document.body.appendChild(o),o.click(),o.remove()}},{"core-js/modules/web.dom-collections.iterator.js":115,"core-js/modules/web.url-search-params.js":116,"core-js/modules/web.url.js":117,htm:118,preact:120}],140:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}e("core-js/modules/es.string.replace.js");var o=Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]},i=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t},s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&o(t,e,n);return i(t,e),t};Object.defineProperty(n,"__esModule",{value:!0}),n.hardwareTransportLayerFactory=n.HardwareTransportLayerFactory=void 0;const a=s(e("base64-js")),l=new TextDecoder;class c{constructor(e){r(this,"sessionId",Date.now()+""),r(this,"hardware",void 0),r(this,"alive",!0),r(this,"frameWidth",0),r(this,"frameHeight",0),r(this,"handler",(()=>{})),this.hardware=e}callMain(){this.hardware.sendMessage("wc-install\n"+this.sessionId+"\n"),requestAnimationFrame(this.update.bind(this))}async sendMessageToServer(e,t){if(void 0!==t&&(null==t?void 0:t.sessionId)===this.sessionId)switch(e){case"wc-run":{let e=d(this.hardware,"bundle_0.zip",t.bundles[0]);if(e.length>0)throw console.error(e),new Error(e);if(void 0!==t.bundles[1]&&(e=d(this.hardware,"bundle_1.zip",t.bundles[1]),e.length>0))throw console.error(e),new Error(e);const n="wc-run\n";this.hardware.sendMessage(n)}break;case"wc-add-key":this.hardware.addKey(t.key,t.pressed?1:0,t.timeMs);break;case"wc-pause":this.hardware.sendMessage("wc-pause\n"+this.sessionId+"\n");break;case"wc-resume":this.hardware.sendMessage("wc-resume\n"+this.sessionId+"\n");break;case"wc-mute":this.hardware.sendMessage("wc-mute\n"+this.sessionId+"\n");break;case"wc-unmute":this.hardware.sendMessage("wc-unmute\n"+this.sessionId+"\n");break;case"wc-exit":this.alive=!1,this.hardware.sendMessage("wc-exit\n"+this.sessionId+"\n");break;case"wc-mouse-move":this.hardware.mouseMove(t.x,t.y,t.relative,t.timeMs);break;case"wc-mouse-button":this.hardware.mouseButton(t.button,t.pressed?1:0,t.timeMs);break;case"wc-pack-fs-to-bundle":this.hardware.sendMessage("wc-pack-fs-to-bundle\n"+this.sessionId+"\n");break;case"wc-connect":this.hardware.sendMessage("wc-connect\n"+this.sessionId+"\n"+t.networkType+"\n"+t.address.replace("ws://","").replace("wss://","")+"\n"+(t.port-1)+"\n");break;case"wc-disconnect":this.hardware.sendMessage("wc-disconnect\n"+this.sessionId+"\n"+t.networkType+"\n");break;default:console.log("Unhandled client message (wc):",e,t)}}initMessageHandler(e){this.handler=e}exit(){this.alive=!1}async onServerMessage(e,t){const n=t||{};switch(e){case"ws-server-ready":{const e=this.hardware.readConfig();this.handler("ws-config",{sessionId:this.sessionId,content:e})}break;case"ws-sound-init":this.handler(e,n),this.handler("ws-server-ready",{sessionId:this.sessionId});break;case"ws-frame-set-size":this.frameWidth=n.width,this.frameHeight=n.height,this.handler(e,n);break;case"ws-sound-push":case"ws-update-lines":console.error(e,"should not be called");break;case"ws-persist":n.bundle=f(n.bundle),this.handler(e,n);break;case"ws-log":case"ws-warn":case"ws-err":case"ws-stdout":void 0!==n.message&&null!==n.message&&n.message.length>0&&(n.message=l.decode(f(n.message))),this.handler(e,n);break;default:this.handler(e,n)}}update(){this.alive&&requestAnimationFrame(this.update.bind(this)),this.updateFrame()}updateFrame(){if(0===this.frameWidth||0===this.frameHeight)return;const e=this.hardware.getFramePayload();if(0===e.length)return;const t=f(e);if(0===t.length)return;const n=[],r=3*this.frameWidth;let o=this.frameHeight,i=-1;for(let e=0;e<this.frameHeight;++e){const s=e===this.frameHeight-1;if(1===t[e]&&-1===i)i=e;else if((s||0===t[e])&&-1!==i){const s=((1===t[e]?e:e-1)-i+1)*r,a=t.slice(o,o+s);n.push({start:i,heapu8:a}),o+=s,i=-1}}this.handler("ws-update-lines",{sessionId:this.sessionId,lines:n})}}class u{constructor(){r(this,"serverMessageHandler",(()=>{})),window.serverMessage=e=>{const t=l.decode(f(e));try{const e=JSON.parse("{"+t.slice(0,-1)+"}");this.serverMessageHandler(e.name,e)}catch(e){throw console.error("Can't parse",t,e),e}},this.createTransportLayer=this.createTransportLayer.bind(this)}createTransportLayer(e){const t=new c(e);return this.serverMessageHandler=t.onServerMessage.bind(t),t.callMain(),t}}function d(e,t,n){if(void 0!==e.writeFile)return e.writeFile(t,p(n));let r=e.createFile(t);if(r.length>0)return r;let o=0;for(;o<n.length;){const t=Math.min(4194304,n.length-o),i=n.subarray(o,o+t);if(r=e.appendFile(p(i)),r.length>0)return r;o+=t}return r=e.closeFile(),r}function f(e){return a.toByteArray(e)}function p(e){return a.fromByteArray(e)}n.HardwareTransportLayerFactory=u,n.hardwareTransportLayerFactory=new u},{"base64-js":1,"core-js/modules/es.string.replace.js":114}],141:[function(e,t,n){"use strict";var r,o,i,s,a,l,c,u,d,f,p,h,m,y,v,g,b,_,w,x,k,j,C,D,E,S,O,P;function B(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.Icons=void 0;const M=e("./dom");n.Icons={XCircle:e=>(0,M.html)(r||(r=B(['\n <svg fill="none" class=',' viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),UserCircle:e=>(0,M.html)(o||(o=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M5.121 17.804A13.937 13.937 0 0112 16c2.5 0 4.847.655 6.879 1.804M15 10a3 3 0 11-6 0 3 3 0 016 0zm6 2a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),Mobile:e=>(0,M.html)(i||(i=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M12 18h.01M8 21h8a2 2 0 002-2V5a2 2 0 00-2-2H8a2 2 0 00-2 2v14a2 2 0 002 2z" />\n </svg>\n'])),e.class),SwithcHorizontal:e=>(0,M.html)(s||(s=B(['\n <svg class="','" fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M8 7h12m0 0l-4-4m4 4l-4 4m0 6H4m0 0l4 4m-4-4l4-4" />\n </svg>\n'])),e.class),EyeOff:e=>(0,M.html)(a||(a=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M13.875 18.825A10.05 10.05 0 0112 19c-4.478 0-8.268-2.943-9.543-7a9.97 9.97 0 011.563-3.029m5.858.908a3 3 0 114.243 4.243M9.878 9.878l4.242 4.242M9.88 9.88l-3.29-3.29m7.532 7.532l3.29 3.29M3 3l3.59 3.59m0 0A9.953 9.953 0 0112 5c4.478 0 8.268 2.943 9.543 7a10.025 10.025 0 01-4.132 5.411m0 0L21 21" />\n </svg>\n'])),e.class),Pause:e=>(0,M.html)(l||(l=B(["\n <svg className=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2}\n d="M10 9v6m4-6v6m7-3a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),Play:e=>(0,M.html)(c||(c=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M14.752 11.168l-3.197-2.132A1 1 0 0010 9.87v4.263a1 1 0 001.555.832l3.197-2.132a1 1 0 000-1.664z" />\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),VolumeUp:e=>(0,M.html)(u||(u=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M15.536 8.464a5 5 0 010 7.072m2.828-9.9a9 9 0 010 12.728M5.586 15H4a1 1 0 01-1-1v-4a1 1 0 011-1h1.586l4.707-4.707C10.923 3.663 12 4.109 12 5v14c0 .891-1.077 1.337-1.707.707L5.586 15z" />\n </svg>\n'])),e.class),VolumeOff:e=>(0,M.html)(d||(d=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M5.586 15H4a1 1 0 01-1-1v-4a1 1 0 011-1h1.586l4.707-4.707C10.923 3.663 12 4.109 12 5v14c0 .891-1.077 1.337-1.707.707L5.586 15z"\n clip-rule="evenodd" />\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2" />\n </svg>\n'])),e.class),PencilAlt:e=>(0,M.html)(f||(f=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z" />\n </svg>\n'])),e.class),ArrowsExpand:e=>(0,M.html)(g||(g=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M4 8V4m0 0h4M4 4l5 5m11-1V4m0 0h-4m4 0l-5 5M4 16v4m0 0h4m-4 0l5-5m11 5l-5-5m5 5v-4m0 4h-4" />\n </svg>\n'])),e.class),ArrowsCircleLeft:e=>(0,M.html)(b||(b=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M11 15l-3-3m0 0l3-3m-3 3h8M3 12a9 9 0 1118 0 9 9 0 01-18 0z" />\n </svg>\n'])),e.class),ArrowsCircleRight:e=>(0,M.html)(_||(_=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2}\n d="M13 9l3 3m0 0l-3 3m3-3H8m13 0a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),ChevronLeft:e=>(0,M.html)(p||(p=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7" />\n </svg>\n'])),e.class),ChevronRight:e=>(0,M.html)(h||(h=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5l7 7-7 7" />\n </svg>\n'])),e.class),DotsHorizontal:e=>(0,M.html)(m||(m=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M5 12h.01M12 12h.01M19 12h.01M6 12a1 1 0 11-2 0 1 1 0 012 0zm7 0a1 1 0 11-2 0 1 1 0 012 0zm7 0a1 1 0 11-2 0 1 1 0 012 0z" />\n </svg>\n'])),e.class),Download:e=>(0,M.html)(y||(y=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M4 16v1a3 3 0 003 3h10a3 3 0 003-3v-1m-4-4l-4 4m0 0l-4-4m4 4V4" />\n </svg>\n'])),e.class),Upload:e=>(0,M.html)(v||(v=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M4 16v1a3 3 0 003 3h10a3 3 0 003-3v-1m-4-8l-4-4m0 0L8 8m4-4v12" />\n </svg>\n'])),e.class),Plus:e=>(0,M.html)(w||(w=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 4v16m8-8H4" />\n </svg>\n'])),e.class),CursorClick:e=>(0,M.html)(x||(x=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M15 15l-2 5L9 9l11 4-5 2zm0 0l5 5M7.188 2.239l.777 2.897M5.136 7.965l-2.898-.777M13.95 4.05l-2.122 2.122m-5.657 5.656l-2.12 2.122" />\n </svg>\n'])),e.class),Cursor:e=>(0,M.html)(k||(k=B(["\n <svg class=",' fill="currentColor" viewBox="0 0 24 24">\n <path\n d="M 7 2 L 7 18.5 L 11.09375 14.605469 L 14.300781 22 L 16.5 21 L 13.195312 13.701172 L 13.199219 13.699219 L 19 13.199219 L 7 2 z M 9 6.6015625 L 14.347656 11.59375 L 13.029297 11.707031 L 12.708984 11.734375 L 12.412109 11.861328 L 10.3125 12.761719 L 9.9824219 12.904297 L 9.7226562 13.152344 L 9 13.837891 L 9 6.6015625 z" />\n </svg>\n'])),e.class),Refresh:e=>(0,M.html)(j||(j=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15" />\n </svg>\n'])),e.class),CurrencyDollar:e=>(0,M.html)(C||(C=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M12 8c-1.657 0-3 .895-3 2s1.343 2 3 2 3 .895 3 2-1.343 2-3 2m0-8c1.11 0 2.08.402 2.599 1M12 8V7m0 1v8m0 0v1m0-1c-1.11 0-2.08-.402-2.599-1M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),QuestionMarkCircle:e=>(0,M.html)(D||(D=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M8.228 9c.549-1.165 2.03-2 3.772-2 2.21 0 4 1.343 4 3 0 1.4-1.278 2.575-3.006 2.907-.542.104-.994.54-.994 1.093m0 3h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),Discord:e=>(0,M.html)(E||(E=B(["\n <svg class=",' fill="none" viewBox="0 0 245 240" stroke="currentColor">\n <style>.st0{fill:#5c7080;}</style>\n <path class="st0" d="M104.4 103.9c-5.7 0-10.2 5-10.2 11.1s4.6 11.1 10.2 11.1c5.7 0 10.2-5 10.2-11.1.1-6.1-4.5-11.1-10.2-11.1zM140.9 103.9c-5.7 0-10.2 5-10.2 11.1s4.6 11.1 10.2 11.1c5.7 0 10.2-5 10.2-11.1s-4.5-11.1-10.2-11.1z"/><path class="st0" d="M189.5 20h-134C44.2 20 35 29.2 35 40.6v135.2c0 11.4 9.2 20.6 20.5 20.6h113.4l-5.3-18.5 12.8 11.9 12.1 11.2 21.5 19V40.6c0-11.4-9.2-20.6-20.5-20.6zm-38.6 130.6s-3.6-4.3-6.6-8.1c13.1-3.7 18.1-11.9 18.1-11.9-4.1 2.7-8 4.6-11.5 5.9-5 2.1-9.8 3.5-14.5 4.3-9.6 1.8-18.4 1.3-25.9-.1-5.7-1.1-10.6-2.7-14.7-4.3-2.3-.9-4.8-2-7.3-3.4-.3-.2-.6-.3-.9-.5-.2-.1-.3-.2-.4-.3-1.8-1-2.8-1.7-2.8-1.7s4.8 8 17.5 11.8c-3 3.8-6.7 8.3-6.7 8.3-22.1-.7-30.5-15.2-30.5-15.2 0-32.2 14.4-58.3 14.4-58.3 14.4-10.8 28.1-10.5 28.1-10.5l1 1.2c-18 5.2-26.3 13.1-26.3 13.1s2.2-1.2 5.9-2.9c10.7-4.7 19.2-6 22.7-6.3.6-.1 1.1-.2 1.7-.2 6.1-.8 13-1 20.2-.2 9.5 1.1 19.7 3.9 30.1 9.6 0 0-7.9-7.5-24.9-12.7l1.4-1.6s13.7-.3 28.1 10.5c0 0 14.4 26.1 14.4 58.3 0 0-8.5 14.5-30.6 15.2z"/>\n </svg>\n'])),e.class),Telegram:e=>(0,M.html)(O||(O=B(["\n <svg class=",' fill="none" viewBox="0 0 240 240" stroke="currentColor">\n <defs>\n <linearGradient id="A" x1="160.01" x2="100.01" y1="40.008" y2="180" gradientUnits="userSpaceOnUse">\n <stop stop-color="#758599" offset="0"/>\n <stop stop-color="#556559" offset="1"/>\n </linearGradient>\n </defs>\n <circle fill="url(#A)" r="120" cy="120" cx="120"/><path d="M49.942 118.96l80.81-33.295c7.977-3.468 35.03-14.566 35.03-14.566s12.486-4.855 11.445 6.936c-.347 4.855-3.12 21.85-5.896 40.23l-8.67 54.45s-.694 7.977-6.6 9.364-15.607-4.855-17.34-6.243c-1.387-1.04-26.012-16.647-35.03-24.277-2.428-2.08-5.202-6.243.347-11.098 12.486-11.445 27.4-25.665 36.416-34.682 4.162-4.162 8.324-13.873-9.017-2.08l-48.902 32.948s-5.55 3.468-15.954.347-22.543-7.283-22.543-7.283-8.324-5.202 5.896-10.75z" fill="#fff"/>\n </svg>\n'])),e.class),Twitter:e=>(0,M.html)(S||(S=B(["\n <svg class=",' fill="none" viewBox="0 0 400 400" stroke="currentColor">\n <style type="text/css">\n .st0{fill:#5c7080;}\n </style>\n <path class="st0" d="M400,200c0,110.5-89.5,200-200,200S0,310.5,0,200S89.5,0,200,0S400,89.5,400,200z M163.4,305.5\n c88.7,0,137.2-73.5,137.2-137.2c0-2.1,0-4.2-0.1-6.2c9.4-6.8,17.6-15.3,24.1-25c-8.6,3.8-17.9,6.4-27.7,7.6\n c10-6,17.6-15.4,21.2-26.7c-9.3,5.5-19.6,9.5-30.6,11.7c-8.8-9.4-21.3-15.2-35.2-15.2c-26.6,0-48.2,21.6-48.2,48.2\n c0,3.8,0.4,7.5,1.3,11c-40.1-2-75.6-21.2-99.4-50.4c-4.1,7.1-6.5,15.4-6.5,24.2c0,16.7,8.5,31.5,21.5,40.1c-7.9-0.2-15.3-2.4-21.8-6\n c0,0.2,0,0.4,0,0.6c0,23.4,16.6,42.8,38.7,47.3c-4,1.1-8.3,1.7-12.7,1.7c-3.1,0-6.1-0.3-9.1-0.9c6.1,19.2,23.9,33.1,45,33.5\n c-16.5,12.9-37.3,20.6-59.9,20.6c-3.9,0-7.7-0.2-11.5-0.7C110.8,297.5,136.2,305.5,163.4,305.5"/>\n </svg>\n'])),e.class),FloppyDisk:e=>(0,M.html)(P||(P=B(["\n <svg class=",' style="padding-left: 2px; padding-top: 4px" fill="none" viewBox="0 0 20 20" stroke="currentColor">\n <g id="floppy_disk">\n <g>\n <path fill-rule="evenodd" clip-rule="evenodd" d="M15.71,2.29l-2-2C13.53,0.11,13.28,0,13,0h-1v6H4V0H1C0.45,0,0,0.45,0,1v14\n c0,0.55,0.45,1,1,1h14c0.55,0,1-0.45,1-1V3C16,2.72,15.89,2.47,15.71,2.29z M14,15H2V9c0-0.55,0.45-1,1-1h10c0.55,0,1,0.45,1,1V15\n z M11,1H9v4h2V1z"/>\n </g>\n </g>\n </svg>\n'])),e.class)}},{"./dom":139}],142:[function(e,t,n){"use strict";var r,o;function i(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.createPlayerApp=n.PlayerApp=void 0;const s=e("preact"),a=e("preact/hooks"),l=e("./dom"),c=e("./components/action-hide"),u=e("./components/action-bar"),d=e("./components/action-save-or-exit"),f=e("./components/sidebar"),p=e("./components/tip"),h=e("nanoid/non-secure"),m="client.id",y="network.token",v="network.region",g="ui.tips";function b(e){const t=emulatorsUi.dom.storage,n=e.options().clientId,o="function"==typeof n?e=>n(e):void 0,[s,b]=(0,a.useState)(null),[_,w]=(0,a.useState)(!1),[x,k]=(0,a.useState)(e.player().mobileControls),[j,C]=(0,a.useState)(e.player().mirroredControls),[D,E]=(0,a.useState)(e.player().autolock),[S,O]=(0,a.useState)(e.player().layers.keyboardVisible),[P,B]=(0,a.useState)(!1),[M,T]=(0,a.useState)(!1),[A,I]=(0,a.useState)(e.player().layers.fullscreen),[K,L]=(0,a.useState)(!0),[R,N]=(0,a.useState)(t.getItem(v)),[F,U]=(0,a.useState)(null),[z,H]=(0,a.useState)("false"!==t.getItem(g)),[W,q]=(0,a.useState)(null),[V,G]=(0,a.useState)("main"),[Y]=(0,a.useState)((()=>{const e=t.getItem(m),n=null!=e?e:(0,h.nanoid)();return null===e&&t.setItem(m,n),{namespace:encodeURIComponent("local ("+location.href+")"),id:n}})),[X,$]=(0,a.useState)(t.getItem(y)),[J,Q]=(0,a.useState)(!1);(0,a.useEffect)((()=>{void 0!==o&&o(!1).then(b).catch(console.error)}),[n,b]),(0,a.useEffect)((()=>(e.setOnRun((()=>{E(e.player().autolock)})),()=>e.setOnRun((()=>{})))),[e.setOnRun]),(0,a.useEffect)((()=>{const e=()=>{const e=null!==document.fullscreenElement;I(e),e||L(!0)};return document.addEventListener("fullscreenchange",e),()=>{document.removeEventListener("fullscreenchange",e)}}),[A,I]);const Z={player:e.player,options:e.options,clientId:s,setClientId:b,requestClientId:o,anonymousClientId:Y,networkToken:X,setNetworkToken:e=>{null===e?t.removeItem(y):t.setItem(y,e),$(e)},mobileControls:x,setMobileControls:async t=>{t?e.player().enableMobileControls():e.player().disableMobileControls(),k(t)},mirroredControls:j,setMirroredControls:async e=>{Z.player().setMirroredControls(e),C(e)},autolock:D,setAutolock:async e=>{Z.player().setAutolock(e),E(e)},keyboard:S,toggleKeyboard:()=>{O(!e.player().layers.keyboardVisible),e.player().layers.toggleKeyboard()},fullscreen:A,toggleFullscreen:()=>{e.player().layers.toggleFullscreen()},pause:P,setPause:t=>{var n;null===(n=e.player().ciPromise)||void 0===n||n.then((e=>{t?e.pause():e.resume(),B(t)})).catch(console.error)},mute:M,setMute:t=>{var n;null===(n=e.player().ciPromise)||void 0===n||n.then((e=>{t?e.mute():e.unmute(),T(t)})).catch(console.error)},actionBar:K,setActionBar:L,sideBar:_,openSideBar:()=>w(!0),closeSideBar:()=>w(!1),region:R,setRegion:function(e){e!==R&&(null!==e&&t.setItem(v,e),N(e),U(null))},estimatingRegion:F,setEstimatingRegion:U,showTips:z,setShowTips:e=>{t.setItem(g,e+""),H(e)},latencyInfo:W,setLatencyInfo:q,sideBarPage:V,setSideBarPage:G,ipxConnected:J,setIpxConnected:Q};return(0,l.html)(r||(r=i(['\n <div class="h-full">\n <'," ..."," />\n <"," ..."," />\n <"," ..."," />\n <"," ..."," />\n <"," ..."," />\n </div>\n "])),c.ActionHide,Z,f.SideBar,Z,u.ActionBar,Z,d.ActionSaveOrExit,Z,p.Tips,Z)}n.PlayerApp=b,n.createPlayerApp=function(e,t,n,r){(0,s.render)((0,l.html)(o||(o=i(["<"," player="," options="," setOnRun="," />"])),b,(()=>t),(()=>n),r),e)}},{"./components/action-bar":125,"./components/action-hide":126,"./components/action-save-or-exit":127,"./components/sidebar":131,"./components/tip":138,"./dom":139,"core-js/modules/web.dom-collections.iterator.js":115,"nanoid/non-secure":119,preact:120,"preact/hooks":121}],143:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.DosPlayer=void 0;const r=e("./dom"),o=e("./hardware-transport-layer"),i=e("./backend/v7/personal"),s=e("./player-app"),a=Dos;function l(e,t){if("none"===(t=t||{}).style)return console.warn("If you don't need the jsdos services, please use emulatros + emulators-ui instead"),a(e,t||{});e.classList.add("flex"),e.classList.add("flex-row"),e.classList.add("relative"),e.classList.add("overflow-hidden");const n=(0,r.createDiv)(["hidden","flex-col","absolute","left-0","top-0","bottom-0","right-0","items-center","justify-center","z-50","bg-gray-800","opacity-95"]),l=(0,r.createDiv)(["text-2xl","font-bold","font-mono","animate-pulse","text-green-600"]);n.appendChild(l);const c=(0,r.createDiv)(["flex","flex-col","flex-grow","overflow-hidden"]),u=(0,r.createDiv)("flex-grow"),d=(0,r.createDiv)("flex-grow-0"),f=(0,r.createDiv)("flex-grow-0");function p(e){l.innerHTML=e,n.classList.remove("hidden"),n.classList.add("flex")}c.appendChild(u),c.appendChild(f),e.appendChild(d),e.appendChild(c),e.appendChild(n),t.layersOptions=t.layersOptions||{},t.layersOptions.keyboardDiv=f,t.layersOptions.fullscreenElement=e,t.layersOptions.optionControls=[];const h=t.hardware;null!=h&&(t.createTransportLayer=()=>o.hardwareTransportLayerFactory.createTransportLayer(h),t.emulatorFunction="backend");const m=a(u,t);let y=()=>{};(0,s.createPlayerApp)(d,m,t,(e=>y=e)),m.bundleUrl=null;const v=m.run;m.run=async(e,r,o)=>{n.classList.remove("flex"),n.classList.add("hidden");const s=()=>{var e;return void 0!==(null===(e=t)||void 0===e?void 0:e.clientId)?t.clientId(!1):null},a=await s();void 0===r&&void 0===o&&null!==a&&(r=(0,i.getPersonalBundleUrl)(a.namespace,a.id,e)+"?dt="+Date.now());const l=await v.call(m,e,r,o);m.bundleUrl=e;const c=m.layers.getOnSave();return m.layers.setOnSave((async()=>{var n;const r="function"==typeof(null===(n=t)||void 0===n?void 0:n.onExit),o=r;r&&l.mute();const a=await s();if(null!==a){o&&p("Saving [1/2]: collecting changes");const t=await l.persist();return o&&p("Saving [2/2]: sending to cloud"),(0,i.putPersonalBundle)(a.namespace,a.id,e,t).then((()=>{r&&o&&p("Saved. Now you can close the window")}))}return o&&p("Saving [1/1]: collecting changes"),c.call(m.layers)})),y(),l};const g=m.stop;return m.stop=()=>(m.bundleUrl=null,g.call(m)),m}n.DosPlayer=l,window.Dos=l},{"./backend/v7/personal":123,"./dom":139,"./hardware-transport-layer":140,"./player-app":142}],144:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.request=void 0,n.request=async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"GET",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;const r=await fetch(e,{method:t,body:n,headers:new Headers({"content-type":"application/json"})}).then((e=>e.json()));var o;if(200!==r.code)throw new Error(null!==(o=r.message)&&void 0!==o?o:"code: "+r.code);return r}},{}],145:[function(e,t,n){"use strict";function r(e,t,n,r,o,i){return new Promise(((s,a)=>{const l=new XMLHttpRequest;if(l.responseType=n,l.open(e,t,!0),l.addEventListener("load",(()=>{200!==l.status?a(new Error("Wrong status code "+l.status)):"text"===n?s(l.responseText):"arraybuffer"===n?s(l.response):a(new Error("Unsupported responseType "+n))}),!1),l.addEventListener("error",(()=>{a(new Error("HTTP GET failed for url "+t))}),!1),l.addEventListener("abort",(()=>{a(new Error("HTTP GET canceled for url "+t))}),!1),void 0!==o&&(l.onprogress=e=>{if(e.loaded&&e.total&&e.total>0){const t=Math.round(1e4*e.loaded/e.total)/100;o(t)}}),void 0!==i)for(const e of Object.keys(i))l.setRequestHeader(e,i[e]);l.send(r)}))}function o(e,t,n){return r("post",e,t,n)}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.post=n.getObject=n.postObject=n.send=void 0,n.send=r,n.postObject=async function(e,t){const n=JSON.parse(await o(e,"text",t));if(n.success)return n;if(void 0!==n.errorCode)throw new Error(n.errorCode);throw new Error("POST Object request failed:\n Payload:\n"+JSON.stringify(n.body,null,2))},n.getObject=async function(e){const t=JSON.parse(await r("get",e,"text"));if(t.success)return t;if(void 0!==t.errorCode)throw new Error(t.errorCode);throw new Error("GET Object request failed:\n Payload:\n"+JSON.stringify(t,null,2))},n.post=o},{"core-js/modules/web.dom-collections.iterator.js":115}],146:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.getPersonalBundleUrl=n.getPersonalBundleKey=n.uploadsS3Bucket=void 0,n.uploadsS3Bucket="doszone-uploads";function r(e,t,n){const r=n.lastIndexOf("/"),o=n.substr(r+1);return"doszone"===e?"personal/"+t+"/"+o:"personal-v2/"+e+"/"+t+"/"+o}n.getPersonalBundleKey=r,n.getPersonalBundleUrl=function(e,t,n){return"https://doszone-uploads.s3.dualstack.eu-central-1.amazonaws.com/"+r(e,t,n)}},{}]},{},[143]);
16
+ var r,o=function(){return o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},o.apply(this,arguments)},i=function(){function e(e){this.options=e,this.listeners={}}return e.prototype.on=function(e,t){var n=this.listeners[e]||[];this.listeners[e]=n.concat([t])},e.prototype.triggerEvent=function(e,t){var n=this;(this.listeners[e]||[]).forEach((function(e){return e({target:n,event:t})}))},e}();(r=n.NotyfArrayEvent||(n.NotyfArrayEvent={}))[r.Add=0]="Add",r[r.Remove=1]="Remove";var s,a=function(){function e(){this.notifications=[]}return e.prototype.push=function(e){this.notifications.push(e),this.updateFn(e,n.NotyfArrayEvent.Add,this.notifications)},e.prototype.splice=function(e,t){var r=this.notifications.splice(e,t)[0];return this.updateFn(r,n.NotyfArrayEvent.Remove,this.notifications),r},e.prototype.indexOf=function(e){return this.notifications.indexOf(e)},e.prototype.onUpdate=function(e){this.updateFn=e},e}();(s=n.NotyfEvent||(n.NotyfEvent={})).Dismiss="dismiss",s.Click="click";var l={types:[{type:"success",className:"notyf__toast--success",backgroundColor:"#3dc763",icon:{className:"notyf__icon--success",tagName:"i"}},{type:"error",className:"notyf__toast--error",backgroundColor:"#ed3d3d",icon:{className:"notyf__icon--error",tagName:"i"}}],duration:2e3,ripple:!0,position:{x:"right",y:"bottom"},dismissible:!1},c=function(){function e(){this.notifications=[],this.events={},this.X_POSITION_FLEX_MAP={left:"flex-start",center:"center",right:"flex-end"},this.Y_POSITION_FLEX_MAP={top:"flex-start",center:"center",bottom:"flex-end"};var e=document.createDocumentFragment(),t=this._createHTMLElement({tagName:"div",className:"notyf"});e.appendChild(t),document.body.appendChild(e),this.container=t,this.animationEndEventName=this._getAnimationEndEventName(),this._createA11yContainer()}return e.prototype.on=function(e,t){var n;this.events=o(o({},this.events),((n={})[e]=t,n))},e.prototype.update=function(e,t){t===n.NotyfArrayEvent.Add?this.addNotification(e):t===n.NotyfArrayEvent.Remove&&this.removeNotification(e)},e.prototype.removeNotification=function(e){var t,n,r=this,o=this._popRenderedNotification(e);o&&((t=o.node).classList.add("notyf__toast--disappear"),t.addEventListener(this.animationEndEventName,n=function(e){e.target===t&&(t.removeEventListener(r.animationEndEventName,n),r.container.removeChild(t))}))},e.prototype.addNotification=function(e){var t=this._renderNotification(e);this.notifications.push({notification:e,node:t}),this._announce(e.options.message||"Notification")},e.prototype._renderNotification=function(e){var t,n=this._buildNotificationCard(e),r=e.options.className;return r&&(t=n.classList).add.apply(t,r.split(" ")),this.container.appendChild(n),n},e.prototype._popRenderedNotification=function(e){for(var t=-1,n=0;n<this.notifications.length&&t<0;n++)this.notifications[n].notification===e&&(t=n);if(-1!==t)return this.notifications.splice(t,1)[0]},e.prototype.getXPosition=function(e){var t;return(null===(t=null==e?void 0:e.position)||void 0===t?void 0:t.x)||"right"},e.prototype.getYPosition=function(e){var t;return(null===(t=null==e?void 0:e.position)||void 0===t?void 0:t.y)||"bottom"},e.prototype.adjustContainerAlignment=function(e){var t=this.X_POSITION_FLEX_MAP[this.getXPosition(e)],n=this.Y_POSITION_FLEX_MAP[this.getYPosition(e)],r=this.container.style;r.setProperty("justify-content",n),r.setProperty("align-items",t)},e.prototype._buildNotificationCard=function(e){var t=this,r=e.options,o=r.icon;this.adjustContainerAlignment(r);var i=this._createHTMLElement({tagName:"div",className:"notyf__toast"}),s=this._createHTMLElement({tagName:"div",className:"notyf__ripple"}),a=this._createHTMLElement({tagName:"div",className:"notyf__wrapper"}),l=this._createHTMLElement({tagName:"div",className:"notyf__message"});l.innerHTML=r.message||"";var c=r.background||r.backgroundColor;if(o){var u=this._createHTMLElement({tagName:"div",className:"notyf__icon"});if(("string"==typeof o||o instanceof String)&&(u.innerHTML=new String(o).valueOf()),"object"==typeof o){var d=o.tagName,f=void 0===d?"i":d,p=o.className,h=o.text,m=o.color,y=void 0===m?c:m,g=this._createHTMLElement({tagName:f,className:p,text:h});y&&(g.style.color=y),u.appendChild(g)}a.appendChild(u)}if(a.appendChild(l),i.appendChild(a),c&&(r.ripple?(s.style.background=c,i.appendChild(s)):i.style.background=c),r.dismissible){var v=this._createHTMLElement({tagName:"div",className:"notyf__dismiss"}),b=this._createHTMLElement({tagName:"button",className:"notyf__dismiss-btn"});v.appendChild(b),a.appendChild(v),i.classList.add("notyf__toast--dismissible"),b.addEventListener("click",(function(r){var o,i;null===(i=(o=t.events)[n.NotyfEvent.Dismiss])||void 0===i||i.call(o,{target:e,event:r}),r.stopPropagation()}))}i.addEventListener("click",(function(r){var o,i;return null===(i=(o=t.events)[n.NotyfEvent.Click])||void 0===i?void 0:i.call(o,{target:e,event:r})}));var _="top"===this.getYPosition(r)?"upper":"lower";return i.classList.add("notyf__toast--"+_),i},e.prototype._createHTMLElement=function(e){var t=e.tagName,n=e.className,r=e.text,o=document.createElement(t);return n&&(o.className=n),o.textContent=r||null,o},e.prototype._createA11yContainer=function(){var e=this._createHTMLElement({tagName:"div",className:"notyf-announcer"});e.setAttribute("aria-atomic","true"),e.setAttribute("aria-live","polite"),e.style.border="0",e.style.clip="rect(0 0 0 0)",e.style.height="1px",e.style.margin="-1px",e.style.overflow="hidden",e.style.padding="0",e.style.position="absolute",e.style.width="1px",e.style.outline="0",document.body.appendChild(e),this.a11yContainer=e},e.prototype._announce=function(e){var t=this;this.a11yContainer.textContent="",setTimeout((function(){t.a11yContainer.textContent=e}),100)},e.prototype._getAnimationEndEventName=function(){var e,t=document.createElement("_fake"),n={MozTransition:"animationend",OTransition:"oAnimationEnd",WebkitTransition:"webkitAnimationEnd",transition:"animationend"};for(e in n)if(void 0!==t.style[e])return n[e];return"animationend"},e}(),u=function(){function e(e){var t=this;this.dismiss=this._removeNotification,this.notifications=new a,this.view=new c;var r=this.registerTypes(e);this.options=o(o({},l),e),this.options.types=r,this.notifications.onUpdate((function(e,n){return t.view.update(e,n)})),this.view.on(n.NotyfEvent.Dismiss,(function(e){var r=e.target,o=e.event;t._removeNotification(r),r.triggerEvent(n.NotyfEvent.Dismiss,o)})),this.view.on(n.NotyfEvent.Click,(function(e){var t=e.target,r=e.event;return t.triggerEvent(n.NotyfEvent.Click,r)}))}return e.prototype.error=function(e){var t=this.normalizeOptions("error",e);return this.open(t)},e.prototype.success=function(e){var t=this.normalizeOptions("success",e);return this.open(t)},e.prototype.open=function(e){var t=this.options.types.find((function(t){return t.type===e.type}))||{},n=o(o({},t),e);this.assignProps(["ripple","position","dismissible"],n);var r=new i(n);return this._pushNotification(r),r},e.prototype.dismissAll=function(){for(;this.notifications.splice(0,1););},e.prototype.assignProps=function(e,t){var n=this;e.forEach((function(e){t[e]=null==t[e]?n.options[e]:t[e]}))},e.prototype._pushNotification=function(e){var t=this;this.notifications.push(e);var n=void 0!==e.options.duration?e.options.duration:this.options.duration;n&&setTimeout((function(){return t._removeNotification(e)}),n)},e.prototype._removeNotification=function(e){var t=this.notifications.indexOf(e);-1!==t&&this.notifications.splice(t,1)},e.prototype.normalizeOptions=function(e,t){var n={type:e};return"string"==typeof t?n.message=t:"object"==typeof t&&(n=o(o({},n),t)),n},e.prototype.registerTypes=function(e){var t=(e&&e.types||[]).slice();return l.types.map((function(e){var n=-1;t.forEach((function(t,r){t.type===e.type&&(n=r)}));var r=-1!==n?t.splice(n,1)[0]:{};return o(o({},e),r)})).concat(t)},e}();n.DEFAULT_OPTIONS=l,n.Notyf=u,n.NotyfArray=a,n.NotyfNotification=i,n.NotyfView=c},{}],132:[function(e,t,n){var r;r=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n(n.s=0)}([function(e,t,n){e.exports=n(1)},function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}n.r(t);var s,a,l,c=function(){function e(t){var n=t.getOptions,r=t.getCaretPosition,o=t.getCaretPositionEnd,i=t.dispatch;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.getOptions=n,this.getCaretPosition=r,this.getCaretPositionEnd=o,this.dispatch=i,e.bindMethods(e,this)}var t,n,s;return t=e,s=[{key:"bindMethods",value:function(e,t){var n,o=function(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))){n&&(e=n);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,l=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw s}}}}(Object.getOwnPropertyNames(e.prototype));try{for(o.s();!(n=o.n()).done;){var i=n.value;"constructor"===i||"bindMethods"===i||(t[i]=t[i].bind(t))}}catch(e){o.e(e)}finally{o.f()}}}],(n=[{key:"getButtonClass",value:function(e){var t=e.includes("{")&&e.includes("}")&&"{//}"!==e?"functionBtn":"standardBtn",n=e.replace("{","").replace("}",""),r="";return"standardBtn"!==t&&(r=" hg-button-".concat(n)),"hg-".concat(t).concat(r)}},{key:"getDefaultDiplay",value:function(){return{"{bksp}":"backspace","{backspace}":"backspace","{enter}":"< enter","{shift}":"shift","{shiftleft}":"shift","{shiftright}":"shift","{alt}":"alt","{s}":"shift","{tab}":"tab","{lock}":"caps","{capslock}":"caps","{accept}":"Submit","{space}":" ","{//}":" ","{esc}":"esc","{escape}":"esc","{f1}":"f1","{f2}":"f2","{f3}":"f3","{f4}":"f4","{f5}":"f5","{f6}":"f6","{f7}":"f7","{f8}":"f8","{f9}":"f9","{f10}":"f10","{f11}":"f11","{f12}":"f12","{numpaddivide}":"/","{numlock}":"lock","{arrowup}":"↑","{arrowleft}":"←","{arrowdown}":"↓","{arrowright}":"→","{prtscr}":"print","{scrolllock}":"scroll","{pause}":"pause","{insert}":"ins","{home}":"home","{pageup}":"up","{delete}":"del","{end}":"end","{pagedown}":"down","{numpadmultiply}":"*","{numpadsubtract}":"-","{numpadadd}":"+","{numpadenter}":"enter","{period}":".","{numpaddecimal}":".","{numpad0}":"0","{numpad1}":"1","{numpad2}":"2","{numpad3}":"3","{numpad4}":"4","{numpad5}":"5","{numpad6}":"6","{numpad7}":"7","{numpad8}":"8","{numpad9}":"9"}}},{key:"getButtonDisplayName",value:function(e,t,n){return(t=n?Object.assign({},this.getDefaultDiplay(),t):t||this.getDefaultDiplay())[e]||e}},{key:"getUpdatedInput",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:n,o=arguments.length>4&&void 0!==arguments[4]&&arguments[4],i=this.getOptions(),s=[n,r,o],a=t;return("{bksp}"===e||"{backspace}"===e)&&a.length>0?a=this.removeAt.apply(this,[a].concat(s)):"{space}"===e?a=this.addStringAt.apply(this,[a," "].concat(s)):"{tab}"!==e||"boolean"==typeof i.tabCharOnTab&&!1===i.tabCharOnTab?"{enter}"!==e&&"{numpadenter}"!==e||!i.newLineOnEnter?e.includes("numpad")&&Number.isInteger(Number(e[e.length-2]))?a=this.addStringAt.apply(this,[a,e[e.length-2]].concat(s)):"{numpaddivide}"===e?a=this.addStringAt.apply(this,[a,"/"].concat(s)):"{numpadmultiply}"===e?a=this.addStringAt.apply(this,[a,"*"].concat(s)):"{numpadsubtract}"===e?a=this.addStringAt.apply(this,[a,"-"].concat(s)):"{numpadadd}"===e?a=this.addStringAt.apply(this,[a,"+"].concat(s)):"{numpaddecimal}"===e?a=this.addStringAt.apply(this,[a,"."].concat(s)):"{"===e||"}"===e?a=this.addStringAt.apply(this,[a,e].concat(s)):e.includes("{")||e.includes("}")||(a=this.addStringAt.apply(this,[a,e].concat(s))):a=this.addStringAt.apply(this,[a,"\n"].concat(s)):a=this.addStringAt.apply(this,[a,"\t"].concat(s)),a}},{key:"updateCaretPos",value:function(e,t){var n=this.updateCaretPosAction(e,t);this.dispatch((function(e){e.setCaretPosition(n)}))}},{key:"updateCaretPosAction",value:function(e,t){var n=this.getOptions(),r=this.getCaretPosition();return t?r>0&&(r-=e):r+=e,n.debug&&console.log("Caret at:",r,"(".concat(this.keyboardDOMClass,")")),r}},{key:"addStringAt",value:function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:e.length,i=arguments.length>4&&void 0!==arguments[4]&&arguments[4];return r||0===r?(n=[e.slice(0,r),t,e.slice(o)].join(""),this.isMaxLengthReached()||i&&this.updateCaretPos(t.length)):n=e+t,n}},{key:"removeAt",value:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.length,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(0===n&&0===r)return e;if(n===r){var i=/([\uD800-\uDBFF][\uDC00-\uDFFF])/g;n&&n>=0?e.substring(n-2,n).match(i)?(t=e.substr(0,n-2)+e.substr(n),o&&this.updateCaretPos(2,!0)):(t=e.substr(0,n-1)+e.substr(n),o&&this.updateCaretPos(1,!0)):e.slice(-2).match(i)?(t=e.slice(0,-2),o&&this.updateCaretPos(2,!0)):(t=e.slice(0,-1),o&&this.updateCaretPos(1,!0))}else t=e.slice(0,n)+e.slice(r),o&&this.dispatch((function(e){e.setCaretPosition(n)}));return t}},{key:"handleMaxLength",value:function(e,t){var n=this.getOptions(),r=n.maxLength,i=e[n.inputName],s=t.length-1>=r;if(t.length<=i.length)return!1;if(Number.isInteger(r))return n.debug&&console.log("maxLength (num) reached:",s),s?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1);if("object"===o(r)){var a=t.length-1>=r[n.inputName];return n.debug&&console.log("maxLength (obj) reached:",a),a?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1)}}},{key:"isMaxLengthReached",value:function(){return Boolean(this.maxLengthReached)}},{key:"isTouchDevice",value:function(){return"ontouchstart"in window||navigator.maxTouchPoints}},{key:"pointerEventsSupported",value:function(){return window.PointerEvent}},{key:"camelCase",value:function(e){return!!e&&e.toLowerCase().trim().split(/[.\-_\s]/g).reduce((function(e,t){return t.length?e+t[0].toUpperCase()+t.slice(1):e}))}}])&&i(t.prototype,n),s&&i(t,s),e}();l=function(){},(a="noop")in(s=c)?Object.defineProperty(s,a,{value:l,enumerable:!0,configurable:!0,writable:!0}):s[a]=l;var u=c;var d=function(){function e(t){var n=t.dispatch,r=t.getOptions;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.dispatch=n,this.getOptions=r,u.bindMethods(e,this)}var t;return(t=[{key:"handleHighlightKeyDown",value:function(e){var t=this.getOptions(),n=this.getSimpleKeyboardLayoutKey(e);this.dispatch((function(e){var r=e.getButtonElement(n)||e.getButtonElement("{".concat(n,"}"));r&&(r.style.backgroundColor=t.physicalKeyboardHighlightBgColor||"#dadce4",r.style.color=t.physicalKeyboardHighlightTextColor||"black",t.physicalKeyboardHighlightPress&&(r.onpointerdown||r.onmousedown||r.ontouchstart||u.noop)())}))}},{key:"handleHighlightKeyUp",value:function(e){var t=this.getOptions(),n=this.getSimpleKeyboardLayoutKey(e);this.dispatch((function(e){var r=e.getButtonElement(n)||e.getButtonElement("{".concat(n,"}"));r&&r.removeAttribute&&(r.removeAttribute("style"),t.physicalKeyboardHighlightPress&&(r.onpointerup||r.onmouseup||r.ontouchend||u.noop)())}))}},{key:"getSimpleKeyboardLayoutKey",value:function(e){var t;return((t=e.code.includes("Numpad")||e.code.includes("Shift")||e.code.includes("Space")||e.code.includes("Backspace")||e.code.includes("Control")||e.code.includes("Alt")||e.code.includes("Meta")?e.code:e.key)&&t!==t.toUpperCase()||"F"===e.code[0]&&Number.isInteger(Number(e.code[1]))&&e.code.length<=3)&&(t=t?t.toLowerCase():t),t}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}();function f(e){return function(e){if(Array.isArray(e))return p(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return p(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?p(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var y=function(){function e(){var t=this;h(this,e),m(this,"handleParams",(function(e){var t,n,r;if("string"==typeof e[0])t=e[0].split(".").join(""),n=document.querySelector(".".concat(t)),r=e[1];else if(e[0]instanceof HTMLDivElement){if(!e[0].className)throw console.warn("Any DOM element passed as parameter must have a class."),new Error("KEYBOARD_DOM_CLASS_ERROR");t=e[0].className.split(" ")[0],n=e[0],r=e[1]}else t="simple-keyboard",n=document.querySelector(".".concat(t)),r=e[0];return{keyboardDOMClass:t,keyboardDOM:n,options:r}})),m(this,"getOptions",(function(){return t.options})),m(this,"getCaretPosition",(function(){return t.caretPosition})),m(this,"getCaretPositionEnd",(function(){return t.caretPositionEnd})),m(this,"registerModule",(function(e,n){t.modules[e]||(t.modules[e]={}),n(t.modules[e])})),m(this,"getKeyboardClassString",(function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];var o=[t.keyboardDOMClass].concat(n).filter((function(e){return!!e}));return o.join(" ")}));for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];var i=this.handleParams(r),s=i.keyboardDOMClass,a=i.keyboardDOM,l=i.options,c=void 0===l?{}:l;if(this.utilities=new u({getOptions:this.getOptions,getCaretPosition:this.getCaretPosition,getCaretPositionEnd:this.getCaretPositionEnd,dispatch:this.dispatch}),this.caretPosition=null,this.caretPositionEnd=null,this.keyboardDOM=a,this.options=c,this.options.layoutName=this.options.layoutName||"default",this.options.theme=this.options.theme||"hg-theme-default",this.options.inputName=this.options.inputName||"default",this.options.preventMouseDownDefault=this.options.preventMouseDownDefault||!1,this.keyboardPluginClasses="",u.bindMethods(e,this),this.input={},this.input[this.options.inputName]="",this.keyboardDOMClass=s,this.buttonElements={},window.SimpleKeyboardInstances||(window.SimpleKeyboardInstances={}),this.currentInstanceName=this.utilities.camelCase(this.keyboardDOMClass),window.SimpleKeyboardInstances[this.currentInstanceName]=this,this.allKeyboardInstances=window.SimpleKeyboardInstances,this.keyboardInstanceNames=Object.keys(window.SimpleKeyboardInstances),this.isFirstKeyboardInstance=this.keyboardInstanceNames[0]===this.currentInstanceName,this.physicalKeyboard=new d({dispatch:this.dispatch,getOptions:this.getOptions}),!this.keyboardDOM)throw console.warn('".'.concat(s,'" was not found in the DOM.')),new Error("KEYBOARD_DOM_ERROR");this.render(),this.modules={},this.loadModules()}var t;return(t=[{key:"setCaretPosition",value:function(e,t){this.caretPosition=e,this.caretPositionEnd=t||e}},{key:"handleButtonClicked",value:function(e){var t=this.options.debug;if("{//}"===e)return!1;"function"==typeof this.options.onKeyPress&&this.options.onKeyPress(e),this.input[this.options.inputName]||(this.input[this.options.inputName]="");var n=this.utilities.getUpdatedInput(e,this.input[this.options.inputName],this.caretPosition,this.caretPositionEnd);if(this.input[this.options.inputName]!==n&&(!this.options.inputPattern||this.options.inputPattern&&this.inputPatternIsValid(n))){if(this.options.maxLength&&this.utilities.handleMaxLength(this.input,n))return!1;this.input[this.options.inputName]=this.utilities.getUpdatedInput(e,this.input[this.options.inputName],this.caretPosition,this.caretPositionEnd,!0),t&&console.log("Input changed:",this.getAllInputs()),this.options.debug&&console.log("Caret at: ",this.getCaretPosition(),this.getCaretPositionEnd(),"(".concat(this.keyboardDOMClass,")")),this.options.syncInstanceInputs&&this.syncInstanceInputs(),"function"==typeof this.options.onChange&&this.options.onChange(this.getInput(this.options.inputName,!0)),"function"==typeof this.options.onChangeAll&&this.options.onChangeAll(this.getAllInputs())}t&&console.log("Key pressed:",e)}},{key:"handleButtonMouseDown",value:function(e,t){var n=this;t&&(this.options.preventMouseDownDefault&&t.preventDefault(),this.options.stopMouseDownPropagation&&t.stopPropagation(),t.target.classList.add(this.activeButtonClass)),this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),this.holdTimeout&&clearTimeout(this.holdTimeout),this.isMouseHold=!0,this.options.disableButtonHold||(this.holdTimeout=setTimeout((function(){(n.isMouseHold&&(!e.includes("{")&&!e.includes("}")||"{delete}"===e||"{backspace}"===e||"{bksp}"===e||"{space}"===e||"{tab}"===e)||"{arrowright}"===e||"{arrowleft}"===e||"{arrowup}"===e||"{arrowdown}"===e)&&(n.options.debug&&console.log("Button held:",e),n.handleButtonHold(e,t)),clearTimeout(n.holdTimeout)}),500))}},{key:"handleButtonMouseUp",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;n&&(this.options.preventMouseUpDefault&&n.preventDefault(),this.options.stopMouseUpPropagation&&n.stopPropagation()),this.recurseButtons((function(t){t.classList.remove(e.activeButtonClass)})),this.isMouseHold=!1,this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),t&&"function"==typeof this.options.onKeyReleased&&this.options.onKeyReleased(t)}},{key:"handleKeyboardContainerMouseDown",value:function(e){this.options.preventMouseDownDefault&&e.preventDefault()}},{key:"handleButtonHold",value:function(e){var t=this;this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),this.holdInteractionTimeout=setTimeout((function(){t.isMouseHold?(t.handleButtonClicked(e),t.handleButtonHold(e)):clearTimeout(t.holdInteractionTimeout)}),100)}},{key:"syncInstanceInputs",value:function(){var e=this;this.dispatch((function(t){t.replaceInput(e.input),t.setCaretPosition(e.caretPosition,e.caretPositionEnd)}))}},{key:"clearInput",value:function(e){e=e||this.options.inputName,this.input[e]="",this.setCaretPosition(0),this.options.syncInstanceInputs&&this.syncInstanceInputs()}},{key:"getInput",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=e||this.options.inputName,this.options.syncInstanceInputs&&!t&&this.syncInstanceInputs(),this.options.rtl){var n=this.input[e].replace("‫","").replace("‬","");return"‫"+n+"‬"}return this.input[e]}},{key:"getAllInputs",value:function(){var e=this,t={};return Object.keys(this.input).forEach((function(n){t[n]=e.getInput(n,!0)})),t}},{key:"setInput",value:function(e,t){t=t||this.options.inputName,this.input[t]=e,this.options.syncInstanceInputs&&this.syncInstanceInputs()}},{key:"replaceInput",value:function(e){this.input=e}},{key:"setOptions",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=this.changedOptions(e);this.options=Object.assign(this.options,e),t.length&&(this.options.debug&&console.log("changedOptions",t),this.onSetOptions(e),this.render())}},{key:"changedOptions",value:function(e){var t=this;return Object.keys(e).filter((function(n){return JSON.stringify(e[n])!==JSON.stringify(t.options[n])}))}},{key:"onSetOptions",value:function(e){e.inputName&&(this.options.debug&&console.log("inputName changed. caretPosition reset."),this.setCaretPosition(null))}},{key:"clear",value:function(){this.keyboardDOM.innerHTML="",this.keyboardDOM.className=this.keyboardDOMClass,this.buttonElements={}}},{key:"dispatch",value:function(e){if(!window.SimpleKeyboardInstances)throw console.warn("SimpleKeyboardInstances is not defined. Dispatch cannot be called."),new Error("INSTANCES_VAR_ERROR");return Object.keys(window.SimpleKeyboardInstances).forEach((function(t){e(window.SimpleKeyboardInstances[t],t)}))}},{key:"addButtonTheme",value:function(e,t){var n=this;if(!t||!e)return!1;e.split(" ").forEach((function(r){t.split(" ").forEach((function(t){n.options.buttonTheme||(n.options.buttonTheme=[]);var o=!1;n.options.buttonTheme.map((function(e){if(e.class.split(" ").includes(t)){o=!0;var n=e.buttons.split(" ");n.includes(r)||(o=!0,n.push(r),e.buttons=n.join(" "))}return e})),o||n.options.buttonTheme.push({class:t,buttons:e})}))})),this.render()}},{key:"removeButtonTheme",value:function(e,t){var n=this;if(!e&&!t)return this.options.buttonTheme=[],this.render(),!1;e&&Array.isArray(this.options.buttonTheme)&&this.options.buttonTheme.length&&(e.split(" ").forEach((function(e){n.options.buttonTheme.map((function(r,o){if(t&&t.includes(r.class)||!t){var i=r.buttons.split(" ").filter((function(t){return t!==e}));i.length?r.buttons=i.join(" "):(n.options.buttonTheme.splice(o,1),r=null)}return r}))})),this.render())}},{key:"getButtonElement",value:function(e){var t,n=this.buttonElements[e];return n&&(t=n.length>1?n:n[0]),t}},{key:"inputPatternIsValid",value:function(e){var t,n=this.options.inputPattern;if((t=n instanceof RegExp?n:n[this.options.inputName])&&e){var r=t.test(e);return this.options.debug&&console.log('inputPattern ("'.concat(t,'"): ').concat(r?"passed":"did not pass!")),r}return!0}},{key:"setEventListeners",value:function(){!this.isFirstKeyboardInstance&&this.allKeyboardInstances||(this.options.debug&&console.log("Caret handling started (".concat(this.keyboardDOMClass,")")),document.addEventListener("keyup",this.handleKeyUp),document.addEventListener("keydown",this.handleKeyDown),document.addEventListener("mouseup",this.handleMouseUp),document.addEventListener("touchend",this.handleTouchEnd))}},{key:"handleKeyUp",value:function(e){this.caretEventHandler(e),this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyUp(e)}},{key:"handleKeyDown",value:function(e){this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyDown(e)}},{key:"handleMouseUp",value:function(e){this.caretEventHandler(e)}},{key:"handleTouchEnd",value:function(e){this.caretEventHandler(e)}},{key:"caretEventHandler",value:function(e){var t;e.target.tagName&&(t=e.target.tagName.toLowerCase()),this.dispatch((function(n){var r=e.target===n.keyboardDOM||e.target&&n.keyboardDOM.contains(e.target);n.isMouseHold&&(n.isMouseHold=!1),"textarea"!==t&&"input"!==t||!["text","search","url","tel","password"].includes(e.target.type)||n.options.disableCaretPositioning?!n.options.disableCaretPositioning&&r||n.setCaretPosition(null):(n.setCaretPosition(e.target.selectionStart,e.target.selectionEnd),n.options.debug&&console.log("Caret at: ",n.getCaretPosition(),n.getCaretPositionEnd(),e&&e.target.tagName.toLowerCase(),"(".concat(n.keyboardDOMClass,")")))}))}},{key:"recurseButtons",value:function(e){var t=this;e&&Object.keys(this.buttonElements).forEach((function(n){return t.buttonElements[n].forEach(e)}))}},{key:"destroy",value:function(){this.options.debug&&console.log("Destroying simple-keyboard instance: ".concat(this.currentInstanceName)),document.removeEventListener("keyup",this.handleKeyUp),document.removeEventListener("keydown",this.handleKeyDown),document.removeEventListener("mouseup",this.handleMouseUp),document.removeEventListener("touchend",this.handleTouchEnd),document.onpointerup=null,document.ontouchend=null,document.ontouchcancel=null,document.onmouseup=null;var e=function(e){e.onpointerdown=null,e.onpointerup=null,e.onpointercancel=null,e.ontouchstart=null,e.ontouchend=null,e.ontouchcancel=null,e.onclick=null,e.onmousedown=null,e.onmouseup=null,e.remove(),e=null};this.recurseButtons(e),this.recurseButtons=null,e=null,this.keyboardDOM.onpointerdown=null,this.keyboardDOM.ontouchstart=null,this.keyboardDOM.onmousedown=null,this.clear(),window.SimpleKeyboardInstances[this.currentInstanceName]=null,delete window.SimpleKeyboardInstances[this.currentInstanceName],this.initialized=!1}},{key:"getButtonThemeClasses",value:function(e){var t=this.options.buttonTheme,n=[];return Array.isArray(t)&&t.forEach((function(t){if(t.class&&"string"==typeof t.class&&t.buttons&&"string"==typeof t.buttons){var r=t.class.split(" ");t.buttons.split(" ").includes(e)&&(n=[].concat(f(n),f(r)))}else console.warn('Incorrect "buttonTheme". Please check the documentation.',t)})),n}},{key:"setDOMButtonAttributes",value:function(e,t){var n=this.options.buttonAttributes;Array.isArray(n)&&n.forEach((function(n){n.attribute&&"string"==typeof n.attribute&&n.value&&"string"==typeof n.value&&n.buttons&&"string"==typeof n.buttons?n.buttons.split(" ").includes(e)&&t(n.attribute,n.value):console.warn('Incorrect "buttonAttributes". Please check the documentation.',n)}))}},{key:"onTouchDeviceDetected",value:function(){this.processAutoTouchEvents(),this.disableContextualWindow()}},{key:"disableContextualWindow",value:function(){window.oncontextmenu=function(e){if(e.target.classList.contains("hg-button"))return e.preventDefault(),e.stopPropagation(),!1}}},{key:"processAutoTouchEvents",value:function(){this.options.autoUseTouchEvents&&(this.options.useTouchEvents=!0,this.options.debug&&console.log("autoUseTouchEvents: Touch device detected, useTouchEvents enabled."))}},{key:"onInit",value:function(){this.options.debug&&console.log("".concat(this.keyboardDOMClass," Initialized")),this.setEventListeners(),"function"==typeof this.options.onInit&&this.options.onInit()}},{key:"beforeFirstRender",value:function(){this.utilities.isTouchDevice()&&this.onTouchDeviceDetected(),"function"==typeof this.options.beforeFirstRender&&this.options.beforeFirstRender(),this.isFirstKeyboardInstance&&this.utilities.pointerEventsSupported()&&!this.options.useTouchEvents&&!this.options.useMouseEvents&&this.options.debug&&console.log("Using PointerEvents as it is supported by this browser"),this.options.useTouchEvents&&this.options.debug&&console.log("useTouchEvents has been enabled. Only touch events will be used.")}},{key:"beforeRender",value:function(){"function"==typeof this.options.beforeRender&&this.options.beforeRender()}},{key:"onRender",value:function(){"function"==typeof this.options.onRender&&this.options.onRender()}},{key:"onModulesLoaded",value:function(){"function"==typeof this.options.onModulesLoaded&&this.options.onModulesLoaded(this)}},{key:"loadModules",value:function(){var e=this;Array.isArray(this.options.modules)&&(this.options.modules.forEach((function(t){(new t).init(e)})),this.keyboardPluginClasses="modules-loaded",this.render(),this.onModulesLoaded())}},{key:"getModuleProp",value:function(e,t){return!!this.modules[e]&&this.modules[e][t]}},{key:"getModulesList",value:function(){return Object.keys(this.modules)}},{key:"parseRowDOMContainers",value:function(e,t,n,r){var o=this,i=Array.from(e.children),s=0;return i.length&&n.forEach((function(n,a){var l=r[a];if(!(l&&l>n))return!1;var c=n-s,u=l-s,d=document.createElement("div");d.className+="hg-button-container";var f="".concat(o.options.layoutName,"-r").concat(t,"c").concat(a);d.setAttribute("data-skUID",f);var p=i.splice(c,u-c+1);s=u-c,p.forEach((function(e){return d.appendChild(e)})),i.splice(c,0,d),e.innerHTML="",i.forEach((function(t){return e.appendChild(t)})),o.options.debug&&console.log("rowDOMContainer",p,c,u,s+1)})),e}},{key:"render",value:function(){var e=this;this.clear(),this.initialized||this.beforeFirstRender(),this.beforeRender();var t="hg-layout-".concat(this.options.layoutName),n=this.options.layout||{default:["` 1 2 3 4 5 6 7 8 9 0 - = {bksp}","{tab} q w e r t y u i o p [ ] \\","{lock} a s d f g h j k l ; ' {enter}","{shift} z x c v b n m , . / {shift}",".com @ {space}"],shift:["~ ! @ # $ % ^ & * ( ) _ + {bksp}","{tab} Q W E R T Y U I O P { } |",'{lock} A S D F G H J K L : " {enter}',"{shift} Z X C V B N M < > ? {shift}",".com @ {space}"]},r=this.options.useTouchEvents||!1,o=r?"hg-touch-events":"",i=this.options.useMouseEvents||!1,s=this.options.disableRowButtonContainers;this.keyboardDOM.className=this.getKeyboardClassString(this.options.theme,t,this.keyboardPluginClasses,o),n[this.options.layoutName].forEach((function(t,n){var o=t.split(" "),a=document.createElement("div");a.className+="hg-row";var l=[],c=[];o.forEach((function(t,o){var u,d=!s&&"string"==typeof t&&t.length>1&&0===t.indexOf("["),p=!s&&"string"==typeof t&&t.length>1&&t.indexOf("]")===t.length-1;d&&(l.push(o),t=t.replace(/\[/g,"")),p&&(c.push(o),t=t.replace(/\]/g,""));var h=e.utilities.getButtonClass(t),m=e.utilities.getButtonDisplayName(t,e.options.display,e.options.mergeDisplay),y=e.options.useButtonTag?"button":"div",g=document.createElement(y);g.className+="hg-button ".concat(h),(u=g.classList).add.apply(u,f(e.getButtonThemeClasses(t))),e.setDOMButtonAttributes(t,(function(e,t){g.setAttribute(e,t)})),e.activeButtonClass="hg-activeButton",!e.utilities.pointerEventsSupported()||r||i?r?(g.ontouchstart=function(n){e.handleButtonClicked(t),e.handleButtonMouseDown(t,n)},g.ontouchend=function(n){e.handleButtonMouseUp(t,n)},g.ontouchcancel=function(n){e.handleButtonMouseUp(t,n)}):(g.onclick=function(){e.isMouseHold=!1,e.handleButtonClicked(t)},g.onmousedown=function(n){e.handleButtonMouseDown(t,n)},g.onmouseup=function(n){e.handleButtonMouseUp(t,n)}):(g.onpointerdown=function(n){e.handleButtonClicked(t),e.handleButtonMouseDown(t,n)},g.onpointerup=function(n){e.handleButtonMouseUp(t,n)},g.onpointercancel=function(n){e.handleButtonMouseUp(t,n)}),g.setAttribute("data-skBtn",t);var v="".concat(e.options.layoutName,"-r").concat(n,"b").concat(o);g.setAttribute("data-skBtnUID",v);var b=document.createElement("span");b.innerHTML=m,g.appendChild(b),e.buttonElements[t]||(e.buttonElements[t]=[]),e.buttonElements[t].push(g),a.appendChild(g)})),a=e.parseRowDOMContainers(a,n,l,c),e.keyboardDOM.appendChild(a)})),this.onRender(),this.initialized||(this.initialized=!0,!this.utilities.pointerEventsSupported()||r||i?r?(document.ontouchend=function(){return e.handleButtonMouseUp()},document.ontouchcancel=function(){return e.handleButtonMouseUp()},this.keyboardDOM.ontouchstart=function(t){return e.handleKeyboardContainerMouseDown(t)}):r||(document.onmouseup=function(){return e.handleButtonMouseUp()},this.keyboardDOM.onmousedown=function(t){return e.handleKeyboardContainerMouseDown(t)}):(document.onpointerup=function(){return e.handleButtonMouseUp()},this.keyboardDOM.onpointerdown=function(t){return e.handleKeyboardContainerMouseDown(t)}),this.onInit())}}])&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(e.prototype,t),e}();t.default=y}])},"object"==typeof n&&"object"==typeof t?t.exports=r():"function"==typeof define&&define.amd?define("SimpleKeyboard",[],r):"object"==typeof n?n.SimpleKeyboard=r():this.SimpleKeyboard=r()},{}],133:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.Build=void 0,n.Build={short:"0.73.1",version:"0.73.1 (40ea0ee70a0cd86e60c5d0dcc4550d62)",buildSeed:1647249582687}},{}],134:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.deprecatedButton=n.createButton=void 0;const r=e("../dom/keys"),o=e("../dom/pointer"),i=function(){const e={};for(const t of Object.keys(r.namedKeyCodes))e[r.namedKeyCodes[t]]=t.substr(4,2);return e}();function s(e,t,n){const r=Math.round(.6*n),i=Math.round(.5*n),s=Math.max(1,Math.round(n/20)),l=h[e.toLowerCase()],c=void 0===l?e:"",u=a("emulator-button-touch-zone"),d=a("emulator-button"),f=a("emulator-button-text",void 0===l?void 0===c||0===c.length?"□":c.substr(0,1).toUpperCase():"");void 0!==l&&(d.style.backgroundImage='url("'+l+'")'),d.style.width=r+"px",d.style.height=r+"px",f.style.fontSize=i+"px",u.widthPx=n-2*s,u.heightPx=n-2*s,u.style.width=u.widthPx+"px",u.style.height=u.heightPx+"px",u.style.borderWidth=s+"px",u.appendChild(d),u.appendChild(f);const p=e=>{void 0!==t.onDown&&t.onDown(),void 0!==t.onClick&&t.onClick(),e.stopPropagation(),e.preventDefault()},m=e=>{void 0!==t.onUp&&t.onUp(),e.stopPropagation(),e.preventDefault()},y=e=>{e.stopPropagation(),e.preventDefault()},g={capture:!0};for(const e of o.pointer.starters)u.addEventListener(e,p,g);for(const e of o.pointer.enders)u.addEventListener(e,m,g);for(const e of o.pointer.changers)u.addEventListener(e,y,g);for(const e of o.pointer.leavers)u.addEventListener(e,y,g);for(const e of o.pointer.prevents)u.addEventListener(e,y,g);return u}function a(e,t){const n=document.createElement("div");return n.className=e,void 0!==t&&(n.innerHTML=t),n}function l(e){return"number"==typeof e?i[e]:e}function c(e,t){return"click"===e.action?{onClick:()=>t.fireKeyPress(e.mapTo)}:{onDown:()=>t.fireKeyDown(e.mapTo),onUp:()=>t.fireKeyUp(e.mapTo)}}n.createButton=s,n.deprecatedButton=function(e,t,n,o){const i=Math.round(o/4),a=[];for(const t of n){if(t.mapTo===r.KBD_NONE)continue;const n=s((t.symbol||l(t.mapTo)).toUpperCase(),c(t,e),o);n.style.position="absolute";const u=t.style;if(u)for(const e of Object.keys(u))n.style[e]=u[e];if(void 0!==t.position){const e=t.position.left,r=t.position.top,s=t.position.bottom,a=t.position.right;void 0!==e&&(n.style.left=i*e+o*(e-1)+"px"),void 0!==a&&(n.style.right=i*a+o*(a-1)+"px"),void 0!==r&&(n.style.top=i*r+o*(r-1)+"px"),void 0!==s&&(n.style.bottom=i*s+o*(s-1)+"px")}e.mouseOverlay.appendChild(n),a.push(n)}return()=>{for(const t of a)t.parentElement===e.mouseOverlay&&e.mouseOverlay.removeChild(t)}};const u="data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns:sketch='http://www.bohemiancoding.com/sketch/ns' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 20 20' fill='%23FFF' enable-background='new 0 0 20 20' xml:space='preserve'%3E%3Ctitle%3EShape%3C/title%3E%3Cdesc%3ECreated with Sketch.%3C/desc%3E%3Cg id='Page-1' sketch:type='MSPage'%3E%3Cg id='Artboard-1' transform='translate(-3.000000, -1.000000)' sketch:type='MSArtboardGroup'%3E%3Cpath id='Shape' sketch:type='MSShapeGroup' d='M19,12c-0.3,0-0.5,0.1-0.7,0.3L14,16.6V3c0-0.5-0.4-1-1-1s-1,0.5-1,1v13.6 l-4.3-4.3C7.5,12.1,7.3,12,7,12c-0.5,0-1,0.4-1,1c0,0.3,0.1,0.5,0.3,0.7l6,6c0.2,0.2,0.4,0.3,0.7,0.3s0.5-0.1,0.7-0.3l6-6 c0.2-0.2,0.3-0.4,0.3-0.7C20,12.4,19.5,12,19,12L19,12z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",d="data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 20 20' enable-background='new 0 0 20 20' fill='%23FFF' xml:space='preserve'%3E%3Cg id='left_arrow_1_'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M18,9H4.41l4.29-4.29C8.89,4.53,9,4.28,9,4c0-0.55-0.45-1-1-1 C7.72,3,7.47,3.11,7.29,3.29l-6,6C1.11,9.47,1,9.72,1,10c0,0.28,0.11,0.53,0.29,0.71l6,6C7.47,16.89,7.72,17,8,17 c0.55,0,1-0.45,1-1c0-0.28-0.11-0.53-0.29-0.71L4.41,11H18c0.55,0,1-0.45,1-1C19,9.45,18.55,9,18,9z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",f="data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' fill='%23fff' viewBox='0 0 20 20' enable-background='new 0 0 20 20' xml:space='preserve'%3E%3Cg id='right_arrow_1_'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M18.71,9.29l-6-6C12.53,3.11,12.28,3,12,3c-0.55,0-1,0.45-1,1 c0,0.28,0.11,0.53,0.29,0.71L15.59,9H2c-0.55,0-1,0.45-1,1c0,0.55,0.45,1,1,1h13.59l-4.29,4.29C11.11,15.47,11,15.72,11,16 c0,0.55,0.45,1,1,1c0.28,0,0.53-0.11,0.71-0.29l6-6C18.89,10.53,19,10.28,19,10C19,9.72,18.89,9.47,18.71,9.29z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",p="data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 18.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' fill='%23fff' viewBox='0 0 20 20' enable-background='new 0 0 20 20' xml:space='preserve'%3E%3Cg id='key_enter_1_'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M18,2c-0.55,0-1,0.45-1,1v5c0,2.21-1.79,4-4,4H4.41l2.29-2.29 C6.89,9.53,7,9.28,7,9c0-0.55-0.45-1-1-1C5.72,8,5.47,8.11,5.29,8.29l-4,4C1.11,12.47,1,12.72,1,13c0,0.28,0.11,0.53,0.29,0.71 l4,4C5.47,17.89,5.72,18,6,18c0.55,0,1-0.45,1-1c0-0.28-0.11-0.53-0.29-0.71L4.41,14H13c3.31,0,6-2.69,6-6V3C19,2.45,18.55,2,18,2 z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",h={fullscreen:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 16 16' enable-background='new 0 0 16 16' xml:space='preserve'%3E%3Cg id='maximize_1_' fill='%23FFFFFF'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M5.99,8.99c-0.28,0-0.53,0.11-0.71,0.29l-3.29,3.29v-1.59c0-0.55-0.45-1-1-1 s-1,0.45-1,1v4c0,0.55,0.45,1,1,1h4c0.55,0,1-0.45,1-1s-0.45-1-1-1H3.41L6.7,10.7c0.18-0.18,0.29-0.43,0.29-0.71 C6.99,9.44,6.54,8.99,5.99,8.99z M14.99-0.01h-4c-0.55,0-1,0.45-1,1s0.45,1,1,1h1.59L9.28,5.29C9.1,5.47,8.99,5.72,8.99,5.99 c0,0.55,0.45,1,1,1c0.28,0,0.53-0.11,0.71-0.29l3.29-3.29v1.59c0,0.55,0.45,1,1,1s1-0.45,1-1v-4C15.99,0.44,15.54-0.01,14.99-0.01 z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",save:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 18.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 16 16' enable-background='new 0 0 16 16' fill='%23FFFFFF' xml:space='preserve'%3E%3Cg id='floppy_disk'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M15.71,2.29l-2-2C13.53,0.11,13.28,0,13,0h-1v6H4V0H1C0.45,0,0,0.45,0,1v14 c0,0.55,0.45,1,1,1h14c0.55,0,1-0.45,1-1V3C16,2.72,15.89,2.47,15.71,2.29z M14,15H2V9c0-0.55,0.45-1,1-1h10c0.55,0,1,0.45,1,1V15 z M11,1H9v4h2V1z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E%0A",options:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 20 20' enable-background='new 0 0 20 20' fill='%23FFF' xml:space='preserve'%3E%3Cg id='cog_2_'%3E%3Cg%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M19,8h-2.31c-0.14-0.46-0.33-0.89-0.56-1.3l1.7-1.7c0.39-0.39,0.39-1.02,0-1.41 l-1.41-1.41c-0.39-0.39-1.02-0.39-1.41,0l-1.7,1.7c-0.41-0.22-0.84-0.41-1.3-0.55V1c0-0.55-0.45-1-1-1H9C8.45,0,8,0.45,8,1v2.33 C7.52,3.47,7.06,3.67,6.63,3.91L5,2.28c-0.37-0.37-0.98-0.37-1.36,0L2.28,3.64C1.91,4.02,1.91,4.63,2.28,5l1.62,1.62 C3.66,7.06,3.46,7.51,3.31,8H1C0.45,8,0,8.45,0,9v2c0,0.55,0.45,1,1,1h2.31c0.14,0.46,0.33,0.89,0.56,1.3L2.17,15 c-0.39,0.39-0.39,1.02,0,1.41l1.41,1.41c0.39,0.39,1.02,0.39,1.41,0l1.7-1.7c0.41,0.22,0.84,0.41,1.3,0.55V19c0,0.55,0.45,1,1,1h2 c0.55,0,1-0.45,1-1v-2.33c0.48-0.14,0.94-0.35,1.37-0.59L15,17.72c0.37,0.37,0.98,0.37,1.36,0l1.36-1.36 c0.37-0.37,0.37-0.98,0-1.36l-1.62-1.62c0.24-0.43,0.45-0.89,0.6-1.38H19c0.55,0,1-0.45,1-1V9C20,8.45,19.55,8,19,8z M10,14 c-2.21,0-4-1.79-4-4c0-2.21,1.79-4,4-4s4,1.79,4,4C14,12.21,12.21,14,10,14z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",keyboard:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 18.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 16 16' enable-background='new 0 0 16 16' xml:space='preserve'%3E%3Cg id='manually_entered_data_2_'%3E%3Cg%3E%3Cpath fill='%23FFFFFF' fill-rule='evenodd' clip-rule='evenodd' d='M1,8h3.76l2-2H1C0.45,6,0,6.45,0,7C0,7.55,0.45,8,1,8z M15.49,3.99 C15.8,3.67,16,3.23,16,2.75C16,1.78,15.22,1,14.25,1c-0.48,0-0.92,0.2-1.24,0.51l-1.44,1.44l2.47,2.47L15.49,3.99z M1,4h7.76l2-2 H1C0.45,2,0,2.45,0,3C0,3.55,0.45,4,1,4z M1,10c-0.55,0-1,0.45-1,1c0,0.48,0.35,0.86,0.8,0.96L2.76,10H1z M10.95,3.57l-6.69,6.69 l2.47,2.47l6.69-6.69L10.95,3.57z M15.2,6.04L13.24,8H15c0.55,0,1-0.45,1-1C16,6.52,15.65,6.14,15.2,6.04z M2,15l3.86-1.39 l-2.46-2.44L2,15z M15,10h-3.76l-2,2H15c0.55,0,1-0.45,1-1C16,10.45,15.55,10,15,10z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",up:"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3E%3Csvg version='1.1' id='Layer_1' xmlns:sketch='http://www.bohemiancoding.com/sketch/ns' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 20 20' fill='%23FFF' enable-background='new 0 0 20 20' xml:space='preserve'%3E%3Ctitle%3EShape%3C/title%3E%3Cdesc%3ECreated with Sketch.%3C/desc%3E%3Cg id='Page-1' sketch:type='MSPage'%3E%3Cg id='Artboard-1' transform='translate(-3.000000, -1.000000)' sketch:type='MSArtboardGroup'%3E%3Cpath id='Shape' sketch:type='MSShapeGroup' d='M19.7,8.3l-6-6C13.5,2.1,13.3,2,13,2s-0.5,0.1-0.7,0.3l-6,6C6.1,8.5,6,8.7,6,9 c0,0.6,0.5,1,1,1c0.3,0,0.5-0.1,0.7-0.3L12,5.4V19c0,0.5,0.4,1,1,1s1-0.5,1-1V5.4l4.3,4.3C18.5,9.9,18.7,10,19,10c0.5,0,1-0.4,1-1 C20,8.7,19.9,8.5,19.7,8.3L19.7,8.3z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E",down:u,do:u,dw:u,dwn:u,left:d,le:d,lft:d,right:f,ri:f,rght:f,rgh:f,enter:p,en:p,enr:p,ent:p,entr:p}},{"../dom/keys":148,"../dom/pointer":152,"core-js/modules/web.dom-collections.iterator.js":118}],135:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.getGrid=void 0,n.getGrid=function(e){switch(e){case"square":return new class{constructor(){r(this,"aspect",.625)}getConfiguration(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;const r=this.getCols(),o=this.getRows(),i=Math.floor(r/2),s=Math.floor(o/2),a=5*e/100/2,l=a,c=(e-2*a)/r*n,u=(t-2*l)/o*n,d=Math.min(c,u),f=[];for(let n=0;n<o;++n){const c=[];for(let u=0;u<r;++u)c.push({centerX:u<i?a+d*(u+.5):e-a-d*(r-u-1+.5),centerY:n<s?l+d*(n+.5):t-l-d*(o-n-1+.5)});f.push(c)}return{gridType:"square",cells:f,columnWidth:d,rowHeight:d,columnsPadding:a,rowsPadding:l,width:e,height:t}}getCols(){return 10}getRows(){return Math.floor(this.getCols()*this.aspect)+1}};case"honeycomb":return new class{constructor(){r(this,"aspect",.625)}getConfiguration(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;const r=this.getCols(),o=this.getRows(),i=Math.floor(r/2),s=Math.floor(o/2),a=5*e/100/2,l=a,c=(e-2*a)/r*n,u=(t-2*l)/o*n,d=Math.min(c,u),f=[];for(let n=0;n<o;++n){const c=[],u=n%2==0?r:r-1,p=n%2==0?0:d/2;for(let f=0;f<u;++f)c.push({centerX:f<i?p+a+d*(f+.5):p+e-a-d*(r-f-1+.5),centerY:n<s?l+d*(n+.5):t-l-d*(o-n-1+.5)});f.push(c)}return{gridType:"honeycomb",cells:f,columnWidth:d,rowHeight:d,columnsPadding:a,rowsPadding:l,width:e,height:t}}getCols(){return 10}getRows(){return Math.floor(this.getCols()*this.aspect)+1}}}throw new Error("Unknown grid type "+e)}},{}],136:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.keyboard=void 0,n.keyboard=function(e,t,n){const r=n||{};function o(e){return void 0!==r[e]?r[e]:e}return e.setOnKeyDown((e=>{t.sendKeyEvent(o(e),!0)})),e.setOnKeyUp((e=>{t.sendKeyEvent(o(e),!1)})),e.setOnKeyPress((e=>{t.simulateKeyPress(o(e))})),e.setOnKeysPress((e=>{t.simulateKeyPress(...e)})),()=>{e.setOnKeyDown((e=>{})),e.setOnKeyUp((e=>{})),e.setOnKeyPress((e=>{})),e.setOnKeysPress((e=>{}))}}},{"core-js/modules/web.dom-collections.iterator.js":118}],137:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.extractLayersConfig=void 0,n.extractLayersConfig=function(e){return void 0!==e.layersConfig?(1===e.layersConfig.version&&function(e){for(const t of e.layers)for(const e of t.controls)if("Key"===e.type){const t=e;"number"==typeof t.mapTo&&(t.mapTo=[t.mapTo])}}(e.layersConfig),e.layersConfig):void 0!==e.layers?e.layers:null}},{"core-js/modules/web.dom-collections.iterator.js":118}],138:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.initLayersControl=void 0;const r=e("./grid"),o=e("./button"),i=e("./keyboard"),s=e("./mouse/mouse-common"),a=e("./options"),l=e("../dom/pointer"),c=e("nipplejs");n.initLayersControl=function(e,t,n,o,a,l,c){let f=t.layers[0];if(void 0!==c)for(const e of t.layers)if(e.title===c){f=e;break}return function(e,t,n,o,a,l){const c=(0,i.keyboard)(t,n),f=(0,s.mouse)(o.autolock,o.sensitivity,t,n),p=[];function m(i,s){var c;for(const e of p)e();p.splice(0,p.length);const f=(0,r.getGrid)(e.grid).getConfiguration(i,s,l),m=new u;for(const t of e.controls){const{row:e,column:n,type:r}=t;"NippleActivator"===r&&h(f,e,n)}let y=-1;if(0===(null===(c=t.options.optionControls)||void 0===c?void 0:c.length))for(const t of e.controls){const{row:e,type:n}=t;if("Options"===n){y=e;break}}const g={};if(a)for(const t of e.controls){const{row:e}=t;let n=t.column;const r=f.cells[e].length,o=r/2;e===y&&n>=o&&(n=Math.min(n+1,r-1)),void 0===g[e]&&(g[e]={leftStart:o,leftEnd:0,rightStart:r-1,rightEnd:o}),n<o?(g[e].leftStart=Math.min(g[e].leftStart,n),g[e].leftEnd=Math.max(g[e].leftEnd,n)):(g[e].rightStart=Math.min(g[e].rightStart,n),g[e].rightEnd=Math.max(g[e].rightEnd,n))}for(const r of e.controls){const e=d[r.type];if(void 0===e){console.error("Factory for control '"+r.type+"' is not defined");continue}const i={...r},s=f.cells[r.row].length,l=s/2;if(y===r.row&&r.column>=l&&(i.column=Math.min(i.column+1,s-1)),a){const{leftStart:e,leftEnd:t,rightStart:n,rightEnd:r}=g[i.row],o=i.column<l;o?i.column+=l+(l-t)-e-1:i.column-=l+(n-l)-(s-r)+1,i.column>=s?(console.error("Column",i.column,"is out of bound",s,o?"[leftSide]":"[rightSide]",g),i.column=s-1):i.column<0&&(console.error("Column",i.column,"is out of bound",0,o?"[leftSide]":"[rightSide]",g),i.column=0)}const c=e(i,t,n,f,m,o);p.push(c)}}return t.addOnResize(m),m(t.width,t.height),()=>{t.removeOnResize(m),c(),f();for(const e of p)e()}}(f,e,n,o,a,l)};class u{constructor(){var e,t;t={},(e="sensors")in this?Object.defineProperty(this,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):this[e]=t}activate(e,t){const n=this.sensors[t+"_"+e];void 0!==n&&n.activate()}deactivate(e,t){const n=this.sensors[t+"_"+e];void 0!==n&&n.deactivate()}register(e,t,n){this.sensors[t+"_"+e]=n}}const d={Key:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],h={onDown:()=>{for(const t of e.mapTo)n.sendKeyEvent(t,!0)},onUp:()=>{for(const t of e.mapTo)n.sendKeyEvent(t,!1)}};if(i.register(c,u,{activate:h.onDown,deactivate:h.onUp}),p(r,c,u))return()=>{};const m=(0,o.createButton)(e.symbol,h,l);return m.style.position="absolute",m.style.left=d-m.widthPx/2+"px",m.style.top=f-m.heightPx/2+"px",t.mouseOverlay.appendChild(m),()=>t.mouseOverlay.removeChild(m)},Options:function(e,t,n,r,o,i){var s;if(0===(null===(s=t.options.optionControls)||void 0===s?void 0:s.length))return()=>{};if(void 0!==t.options.optionControls&&1===t.options.optionControls.length&&"keyboard"===t.options.optionControls[0])return f(e,t,n,r,o,i);const{cells:l,columnWidth:c,rowHeight:u}=r,{row:d,column:p}=e,{centerX:h,centerY:m}=l[d][p],y=m-u/2,g=h-c/2,v=r.width-g-c;return(0,a.options)(t,["default"],(()=>{}),c,y,v)},Keyboard:f,Switch:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],p=(0,o.createButton)(e.symbol,{onUp:()=>s.setLayersConfig(s.getLayersConfig(),e.layerName)},l);return p.style.position="absolute",p.style.left=d-p.widthPx/2+"px",p.style.top=f-p.heightPx/2+"px",t.mouseOverlay.appendChild(p),()=>{t.mouseOverlay.removeChild(p)}},ScreenMove:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u];let h=.5,m=.5;e.direction.indexOf("up")>=0&&(m=0),e.direction.indexOf("down")>=0&&(m=1),e.direction.indexOf("left")>=0&&(h=0),e.direction.indexOf("right")>=0&&(h=1);const y={onDown:()=>{n.sendMouseMotion(h,m)},onUp:()=>{n.sendMouseMotion(.5,.5)}};if(i.register(c,u,{activate:y.onDown,deactivate:y.onUp}),p(r,c,u))return()=>{};const g=(0,o.createButton)(e.symbol,y,l);return g.style.position="absolute",g.style.left=d-g.widthPx/2+"px",g.style.top=f-g.heightPx/2+"px",t.mouseOverlay.appendChild(g),()=>t.mouseOverlay.removeChild(g)},PointerButton:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u,click:d}=e,{centerX:f,centerY:h}=a[c][u],m={onDown:()=>{d?n.sendMouseButton(e.button,!0):t.pointerButton=e.button},onUp:()=>{d?n.sendMouseButton(e.button,!1):t.pointerButton=0}};if(i.register(c,u,{activate:m.onDown,deactivate:m.onUp}),p(r,c,u))return()=>{};const y=(0,o.createButton)(e.symbol,m,l);return y.style.position="absolute",y.style.left=f-y.widthPx/2+"px",y.style.top=h-y.heightPx/2+"px",t.mouseOverlay.appendChild(y),()=>t.mouseOverlay.removeChild(y)},PointerMove:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u,x:d,y:f}=e,{centerX:h,centerY:m}=a[c][u],y={onDown:()=>{n.sendMouseMotion(d,f)},onUp:()=>{n.sendMouseMotion(d,f)}};if(i.register(c,u,{activate:y.onDown,deactivate:y.onUp}),p(r,c,u))return()=>{};const g=(0,o.createButton)(e.symbol,y,l);return g.style.position="absolute",g.style.left=h-g.widthPx/2+"px",g.style.top=m-g.heightPx/2+"px",t.mouseOverlay.appendChild(g),()=>t.mouseOverlay.removeChild(g)},PointerReset:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],h={onDown:()=>{n.sendMouseSync()}};if(i.register(c,u,{activate:h.onDown,deactivate:()=>{}}),p(r,c,u))return()=>{};const m=(0,o.createButton)(e.symbol,h,l);return m.style.position="absolute",m.style.left=d-m.widthPx/2+"px",m.style.top=f-m.heightPx/2+"px",t.mouseOverlay.appendChild(m),()=>t.mouseOverlay.removeChild(m)},PointerToggle:function(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],h={onDown:()=>{t.pointerDisabled=!t.pointerDisabled,t.pointerDisabled?m.classList.contains("emulator-button-highlight")||m.classList.add("emulator-button-highlight"):m.classList.remove("emulator-button-highlight")}};if(i.register(c,u,{activate:h.onDown,deactivate:()=>{}}),p(r,c,u))return()=>{};const m=(0,o.createButton)(e.symbol,h,l);return m.style.position="absolute",m.style.left=d-m.widthPx/2+"px",m.style.top=f-m.heightPx/2+"px",t.mouseOverlay.appendChild(m),()=>t.mouseOverlay.removeChild(m)},NippleActivator:function(e,t,n,r,o,i){const{cells:s,columnWidth:a,rowHeight:u,width:d,height:f}=r,{row:p,column:h}=e,{centerX:m,centerY:y}=s[p][h],g=document.createElement("div"),v=1.5,b=Math.max(0,m-a*v),_=Math.max(0,y-u*v),w=Math.max(0,d-m-a*v),x=Math.max(0,f-y-u*v);g.style.position="absolute",g.style.zIndex="999",g.style.left=b+"px",g.style.top=_+"px",g.style.right=w+"px",g.style.bottom=x+"px",t.mouseOverlay.appendChild(g);const k=c.create({zone:g,multitouch:!1,maxNumberOfNipples:1,mode:"static",follow:!1,dynamicPage:!0,size:1.5*Math.max(a,u),position:{left:(d-w-b)/2+"px",top:(f-x-_)/2+"px"}});let j=-1,C=-1;k.on("move",((e,t)=>{if(t.distance<10)return o.deactivate(C,j),j=-1,void(C=-1);let n=-1,r=-1;const i=t.angle.degree;i>22.5&&i<=67.5?(n=h+1,r=p-1):i>67.5&&i<=112.5?(n=h,r=p-1):i>112.5&&i<=157.5?(n=h-1,r=p-1):i>157.5&&i<=202.5?(n=h-1,r=p):i>202.5&&i<=247.5?(n=h-1,r=p+1):i>247.5&&i<=292.5?(n=h,r=p+1):i>292.5&&i<=337.5?(n=h+1,r=p+1):(n=h+1,r=p),j===n&&C===r||(o.deactivate(C,j),o.activate(r,n),j=n,C=r)}));let E=!1;k.on("start",(()=>{E=!0})),k.on("end",(()=>{E=!1,o.deactivate(C,j),C=-1,j=-1}));const D={capture:!0};function S(e){E&&k.processOnEnd(e)}for(const e of l.pointer.enders)t.mouseOverlay.addEventListener(e,S,D);return()=>{k.destroy(),t.mouseOverlay.removeChild(g);for(const e of l.pointer.enders)t.mouseOverlay.removeEventListener(e,S,D)}}};function f(e,t,n,r,i,s){const{cells:a,columnWidth:l}=r,{row:c,column:u}=e,{centerX:d,centerY:f}=a[c][u],p=(0,o.createButton)("keyboard",{onUp:()=>t.toggleKeyboard()},l),h=e=>{e?p.children[0].classList.add("emulator-control-close-icon"):p.children[0].classList.remove("emulator-control-close-icon")};return t.setOnKeyboardVisibility(h),p.style.position="absolute",p.style.left=d-p.widthPx/2+"px",p.style.top=f-p.heightPx/2+"px",t.mouseOverlay.appendChild(p),()=>{t.mouseOverlay.removeChild(p),t.removeOnKeyboardVisibility(h)}}function p(e,t,n){return!0===e.cells[t][n].hidden}function h(e,t,n){function r(r,o){if((r!==t||o!==n)&&r>=0&&r<e.cells.length){const t=e.cells[r];o>=0&&o<t.length&&(t[o].hidden=!0)}}for(let e=t-1;e<=t+1;++e)for(let t=n-1;t<=n+1;++t)r(e,t)}},{"../dom/pointer":152,"./button":134,"./grid":135,"./keyboard":136,"./mouse/mouse-common":140,"./options":146,"core-js/modules/web.dom-collections.iterator.js":118,nipplejs:130}],139:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.initLegacyLayersControl=void 0;const r=e("./button"),o=e("./mouse/mouse-common"),i=e("./nipple"),s=e("./options"),a=e("./keyboard");n.initLegacyLayersControl=function(e,t,n,l){var c;const u=Object.keys(n),d={keyboard:()=>{},mouse:()=>{},gestures:()=>{},buttons:()=>{}},f=s=>{d.keyboard(),d.mouse(),d.gestures(),d.buttons(),d.keyboard=()=>{},d.mouse=()=>{},d.gestures=()=>{},d.buttons=()=>{};const c=n[s];void 0!==c&&(d.keyboard=(0,a.keyboard)(t,l,c.mapper),void 0!==c.gestures&&c.gestures.length>0?d.gestures=(0,i.nipple)(t,l,c.gestures):d.mouse=(0,o.mouse)(e.autolock,e.sensitivity,t,l),void 0!==c.buttons&&c.buttons.length&&(d.buttons=(0,r.deprecatedButton)(t,l,c.buttons,54)))},p=0===(null===(c=t.options.optionControls)||void 0===c?void 0:c.length)?()=>{}:(0,s.options)(t,u,f,54,13.5,0);return f("default"),()=>{d.gestures(),d.buttons(),d.mouse(),d.keyboard(),p()}}},{"./button":134,"./keyboard":136,"./mouse/mouse-common":140,"./nipple":144,"./options":146}],140:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.mouse=n.mount=n.mapXY=void 0;const r=e("../../dom/pointer"),o=e("./mouse-swipe"),i=e("./mouse-not-locked"),s=e("./mouse-locked");n.mapXY=function(e,t,n,r){const o=n.width(),i=n.height(),s=r.width,a=r.height,l=o/i;let c=s,u=s/l;u>a&&(u=a,c=a*l);const d=(a-u)/2,f=(s-c)/2;let p=Math.max(0,Math.min(1,(e-f)/c)),h=Math.max(0,Math.min(1,(t-d)/u));return p<=.01&&(p=0),p>=.99&&(p=1),h<=.01&&(h=0),h>=.99&&(h=1),{x:p,y:h}},n.mount=function(e,t,n,o,i,s){let a=0;const l=o=>{if(o.target!==e)return;if(t.pointerDisabled)return void o.stopPropagation();const i=(0,r.getPointerState)(o,e);a=i.button||t.pointerButton,n(i.x,i.y,a),o.stopPropagation()},c=n=>{if(n.target!==e)return;if(t.pointerDisabled)return void n.stopPropagation();const i=(0,r.getPointerState)(n,e);o(i.x,i.y,i.mX,i.mY),n.stopPropagation()},u=n=>{if(t.pointerDisabled)return void n.stopPropagation();const o=(0,r.getPointerState)(n,e);i(o.x,o.y,a),n.stopPropagation()},d=n=>{if(n.target!==e)return;if(t.pointerDisabled)return void n.stopPropagation();const o=(0,r.getPointerState)(n,e);s(o.x,o.y),n.stopPropagation()},f=e=>{e.stopPropagation()},p={capture:!1};for(const t of r.pointer.starters)e.addEventListener(t,l,p);for(const t of r.pointer.changers)e.addEventListener(t,c,p);for(const t of r.pointer.enders)e.addEventListener(t,u,p);for(const t of r.pointer.prevents)e.addEventListener(t,f,p);for(const t of r.pointer.leavers)e.addEventListener(t,d,p);return()=>{for(const t of r.pointer.starters)e.removeEventListener(t,l,p);for(const t of r.pointer.changers)e.removeEventListener(t,c,p);for(const t of r.pointer.enders)e.removeEventListener(t,u,p);for(const t of r.pointer.prevents)e.removeEventListener(t,f,p);for(const t of r.pointer.leavers)e.removeEventListener(t,d,p)}},n.mouse=function(e,t,n,a){return e&&!r.pointer.canLock?(0,o.mouseSwipe)(t,n,a):e?(0,s.mouseLocked)(t,n,a):(0,i.mouseNotLocked)(n,a)}},{"../../dom/pointer":152,"./mouse-locked":141,"./mouse-not-locked":142,"./mouse-swipe":143,"core-js/modules/web.dom-collections.iterator.js":118}],141:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.mouseLocked=void 0;const r=e("./mouse-common");n.mouseLocked=function(e,t,n){const o=t.mouseOverlay;function i(){return document.pointerLockElement!==o}return(0,r.mount)(o,t,(function(e,t,r){i()?(o.requestPointerLock||o.mozRequestPointerLock||o.webkitRequestPointerLock).call(o):n.sendMouseButton(r,!0)}),(function(t,r,o,s){i()||0===o&&0===s||n.sendMouseRelativeMotion(o*e,s*e)}),(function(e,t,r){i()||n.sendMouseButton(r,!1)}),(function(e,t){}))}},{"./mouse-common":140}],142:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.mouseNotLocked=void 0;const r=e("./mouse-common");n.mouseNotLocked=function(e,t){const n=e.mouseOverlay,o=(n,o)=>(0,r.mapXY)(n,o,t,e);return document.pointerLockElement===n&&document.exitPointerLock(),(0,r.mount)(n,e,(function(e,n,r){const i=o(e,n);t.sendMouseMotion(i.x,i.y),t.sendMouseButton(r,!0)}),(function(e,n,r,i){const s=o(e,n);t.sendMouseMotion(s.x,s.y)}),(function(e,n,r){const i=o(e,n);t.sendMouseMotion(i.x,i.y),t.sendMouseButton(r,!1)}),(function(e,n){const r=o(e,n);t.sendMouseMotion(r.x,r.y)}))}},{"./mouse-common":140}],143:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.mouseSwipe=void 0;const r=e("./mouse-common");n.mouseSwipe=function(e,t,n){const o=t.mouseOverlay;let i=-1,s=0,a=0,l=0;return(0,r.mount)(o,t,((e,t)=>{i=Date.now(),s=0,a=e,l=t}),(function(t,r,o,i){void 0===o&&(o=t-a),void 0===i&&(i=r-l),a=t,l=r,0===o&&0===i||(s+=Math.abs(o)+Math.abs(i),n.sendMouseRelativeMotion(o*e*2,i*e*2))}),((e,r)=>{if(Date.now()-i<500&&s<50){const e=t.pointerButton||0;n.sendMouseButton(e,!0),setTimeout((()=>n.sendMouseButton(e,!1)),60)}}),(()=>{}))}},{"./mouse-common":140}],144:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.nipple=void 0;const r=e("nipplejs"),o=e("../dom/keys");n.nipple=function(e,t,n){const i=r.create({zone:e.mouseOverlay,multitouch:!0,maxNumberOfNipples:2});let s=-1;const a=()=>{-1!==s&&(e.fireKeyUp(s),s=-1)},l={},c={},u={};for(const t of n)"end:release"===t.event?l[t.joystickId]=!0:t.mapTo!==o.KBD_NONE&&("tap"===t.event?c[t.joystickId]=t.mapTo:i.on(t.event,(()=>{var n;u[t.joystickId]=Date.now(),a(),n=t.mapTo,e.fireKeyDown(n),s=n})));const d={};return i.on("start",(()=>{const e=i.ids.length-1;d[e]=Date.now()})),i.on("end",(()=>{const t=i.ids.length-1,n=Date.now()-d[t];!0===l[t]&&a(),c[t]&&n<500&&u[t]<d[t]&&e.fireKeyPress(c[t])})),()=>i.destroy()}},{"../dom/keys":148,"core-js/modules/web.dom-collections.iterator.js":118,nipplejs:130}],145:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.initNullLayersControl=void 0;const r=e("./keyboard"),o=e("./mouse/mouse-common"),i=e("./options");n.initNullLayersControl=function(e,t,n){var s;const a=(0,r.keyboard)(t,n),l=(0,o.mouse)(e.autolock,e.sensitivity,t,n),c=0===(null===(s=t.options.optionControls)||void 0===s?void 0:s.length)?()=>{}:(0,i.options)(t,["default"],(()=>{}),54,13.5,0);return()=>{a(),l(),c()}}},{"./keyboard":136,"./mouse/mouse-common":140,"./options":146}],146:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.options=void 0;const r=e("./button"),o=e("../dom/helpers");function i(e,t){if(e.length<=1)return document.createElement("div");const n=document.createElement("select");n.classList.add("emulator-control-select");for(const t of e){const e=document.createElement("option");e.value=t,e.innerHTML=t,n.appendChild(e)}return n.onchange=e=>{const n=e.target.value;t(n)},(0,o.stopPropagation)(n,!1),n}n.options=function(e,t,n,s,a,l){const c=Math.round(s/4);let u=!1,d=!1;const f=()=>{const e=u?"flex":"none";for(const t of h)t!=m&&(t.style.display=e)},p=()=>{u=!u,!u&&d&&e.toggleKeyboard(),f()},h=[i(t,n),(0,r.createButton)("keyboard",{onClick:()=>{e.toggleKeyboard(),u&&!d&&(u=!1,f())}},s),(0,r.createButton)("save",{onClick:()=>{e.save(),u&&p()}},s),(0,r.createButton)("fullscreen",{onClick:()=>{e.toggleFullscreen(),u&&p()}},s),(0,r.createButton)("options",{onClick:p},s)],m=h[h.length-1],y=h[h.length-2].children[0],g=h[h.length-4].children[0],v=e=>{d=e,e?g.classList.add("emulator-control-close-icon"):g.classList.remove("emulator-control-close-icon")};e.setOnKeyboardVisibility(v),v(e.keyboardVisible),e.setOnFullscreen((e=>{e?y.classList.contains("emulator-control-exit-fullscreen-icon")||y.classList.add("emulator-control-exit-fullscreen-icon"):y.classList.remove("emulator-control-exit-fullscreen-icon")})),e.fullscreen&&y.classList.add("emulator-control-exit-fullscreen-icon");const b=(0,o.createDiv)("emulator-options"),_=d?"flex":"none";for(const e of h)e!==m&&e.classList.add("emulator-button-control"),e.style.marginRight=c+"px",e.style.marginBottom=c+"px",e!==m&&(e.style.display=_),b.appendChild(e);return b.style.position="absolute",b.style.right=l+"px",b.style.top=a+"px",e.mouseOverlay.appendChild(b),()=>{e.mouseOverlay.removeChild(b),e.setOnFullscreen((()=>{})),e.removeOnKeyboardVisibility(v)}}},{"../dom/helpers":147,"./button":134,"core-js/modules/web.dom-collections.iterator.js":118}],147:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.stopPropagation=n.createDiv=void 0;const r=e("./pointer");n.createDiv=function(e,t){const n=document.createElement("div");return n.className=e,void 0!==t&&(n.innerHTML=t),n},n.stopPropagation=function(e){let t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];const n=e=>{e.stopPropagation()},o=e=>{e.stopPropagation(),t&&e.preventDefault()},i={capture:!1};for(const t of r.pointer.starters)e.addEventListener(t,n,i);for(const t of r.pointer.enders)e.addEventListener(t,n,i);for(const t of r.pointer.prevents)e.addEventListener(t,o,i)}},{"./pointer":152,"core-js/modules/web.dom-collections.iterator.js":118}],148:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.KBD_kp0=n.KBD_f12=n.KBD_f11=n.KBD_f10=n.KBD_f9=n.KBD_f8=n.KBD_f7=n.KBD_f6=n.KBD_f5=n.KBD_f4=n.KBD_f3=n.KBD_f2=n.KBD_f1=n.KBD_z=n.KBD_y=n.KBD_x=n.KBD_w=n.KBD_v=n.KBD_u=n.KBD_t=n.KBD_s=n.KBD_r=n.KBD_q=n.KBD_p=n.KBD_o=n.KBD_n=n.KBD_m=n.KBD_l=n.KBD_k=n.KBD_j=n.KBD_i=n.KBD_h=n.KBD_g=n.KBD_f=n.KBD_e=n.KBD_d=n.KBD_c=n.KBD_b=n.KBD_a=n.KBD_9=n.KBD_8=n.KBD_7=n.KBD_6=n.KBD_5=n.KBD_4=n.KBD_3=n.KBD_2=n.KBD_1=n.KBD_0=n.KBD_NONE=void 0,n.KBD_up=n.KBD_left=n.KBD_pagedown=n.KBD_end=n.KBD_delete=n.KBD_pageup=n.KBD_home=n.KBD_insert=n.KBD_pause=n.KBD_printscreen=n.KBD_slash=n.KBD_comma=n.KBD_period=n.KBD_quote=n.KBD_semicolon=n.KBD_rightbracket=n.KBD_leftbracket=n.KBD_backslash=n.KBD_equals=n.KBD_minus=n.KBD_grave=n.KBD_numlock=n.KBD_scrolllock=n.KBD_capslock=n.KBD_rightshift=n.KBD_leftshift=n.KBD_rightctrl=n.KBD_leftctrl=n.KBD_rightalt=n.KBD_leftalt=n.KBD_space=n.KBD_enter=n.KBD_backspace=n.KBD_tab=n.KBD_esc=n.KBD_kpenter=n.KBD_kpplus=n.KBD_kpminus=n.KBD_kpmultiply=n.KBD_kpdivide=n.KBD_kpperiod=n.KBD_kp9=n.KBD_kp8=n.KBD_kp7=n.KBD_kp6=n.KBD_kp5=n.KBD_kp4=n.KBD_kp3=n.KBD_kp2=n.KBD_kp1=void 0,n.domToKeyCode=n.keyCodesToDom=n.namedKeyCodes=n.domToKeyCodes=n.KBD_extra_lt_gt=n.KBD_right=n.KBD_down=void 0,n.KBD_NONE=0,n.KBD_0=48,n.KBD_1=49,n.KBD_2=50,n.KBD_3=51,n.KBD_4=52,n.KBD_5=53,n.KBD_6=54,n.KBD_7=55,n.KBD_8=56,n.KBD_9=57,n.KBD_a=65,n.KBD_b=66,n.KBD_c=67,n.KBD_d=68,n.KBD_e=69,n.KBD_f=70,n.KBD_g=71,n.KBD_h=72,n.KBD_i=73,n.KBD_j=74,n.KBD_k=75,n.KBD_l=76,n.KBD_m=77,n.KBD_n=78,n.KBD_o=79,n.KBD_p=80,n.KBD_q=81,n.KBD_r=82,n.KBD_s=83,n.KBD_t=84,n.KBD_u=85,n.KBD_v=86,n.KBD_w=87,n.KBD_x=88,n.KBD_y=89,n.KBD_z=90,n.KBD_f1=290,n.KBD_f2=291,n.KBD_f3=292,n.KBD_f4=293,n.KBD_f5=294,n.KBD_f6=295,n.KBD_f7=296,n.KBD_f8=297,n.KBD_f9=298,n.KBD_f10=299,n.KBD_f11=300,n.KBD_f12=301,n.KBD_kp0=320,n.KBD_kp1=321,n.KBD_kp2=322,n.KBD_kp3=323,n.KBD_kp4=324,n.KBD_kp5=325,n.KBD_kp6=326,n.KBD_kp7=327,n.KBD_kp8=328,n.KBD_kp9=329,n.KBD_kpperiod=330,n.KBD_kpdivide=331,n.KBD_kpmultiply=332,n.KBD_kpminus=333,n.KBD_kpplus=334,n.KBD_kpenter=335,n.KBD_esc=256,n.KBD_tab=258,n.KBD_backspace=259,n.KBD_enter=257,n.KBD_space=32,n.KBD_leftalt=342,n.KBD_rightalt=346,n.KBD_leftctrl=341,n.KBD_rightctrl=345,n.KBD_leftshift=340,n.KBD_rightshift=344,n.KBD_capslock=280,n.KBD_scrolllock=281,n.KBD_numlock=282,n.KBD_grave=96,n.KBD_minus=45,n.KBD_equals=61,n.KBD_backslash=92,n.KBD_leftbracket=91,n.KBD_rightbracket=93,n.KBD_semicolon=59,n.KBD_quote=39,n.KBD_period=46,n.KBD_comma=44,n.KBD_slash=47,n.KBD_printscreen=283,n.KBD_pause=284,n.KBD_insert=260,n.KBD_home=268,n.KBD_pageup=266,n.KBD_delete=261,n.KBD_end=269,n.KBD_pagedown=267,n.KBD_left=263,n.KBD_up=265,n.KBD_down=264,n.KBD_right=262,n.KBD_extra_lt_gt=348,n.domToKeyCodes={8:n.KBD_backspace,9:n.KBD_tab,13:n.KBD_enter,16:n.KBD_leftshift,17:n.KBD_leftctrl,18:n.KBD_leftalt,19:n.KBD_pause,27:n.KBD_esc,32:n.KBD_space,33:n.KBD_pageup,34:n.KBD_pagedown,35:n.KBD_end,36:n.KBD_home,37:n.KBD_left,38:n.KBD_up,39:n.KBD_right,40:n.KBD_down,45:n.KBD_insert,46:n.KBD_delete,48:n.KBD_0,49:n.KBD_1,50:n.KBD_2,51:n.KBD_3,52:n.KBD_4,53:n.KBD_5,54:n.KBD_6,55:n.KBD_7,56:n.KBD_8,57:n.KBD_9,59:n.KBD_semicolon,64:n.KBD_equals,65:n.KBD_a,66:n.KBD_b,67:n.KBD_c,68:n.KBD_d,69:n.KBD_e,70:n.KBD_f,71:n.KBD_g,72:n.KBD_h,73:n.KBD_i,74:n.KBD_j,75:n.KBD_k,76:n.KBD_l,77:n.KBD_m,78:n.KBD_n,79:n.KBD_o,80:n.KBD_p,81:n.KBD_q,82:n.KBD_r,83:n.KBD_s,84:n.KBD_t,85:n.KBD_u,86:n.KBD_v,87:n.KBD_w,88:n.KBD_x,89:n.KBD_y,90:n.KBD_z,91:n.KBD_leftbracket,93:n.KBD_rightbracket,96:n.KBD_kp0,97:n.KBD_kp1,98:n.KBD_kp2,99:n.KBD_kp3,100:n.KBD_kp4,101:n.KBD_kp5,102:n.KBD_kp6,103:n.KBD_kp7,104:n.KBD_kp8,105:n.KBD_kp9,111:n.KBD_kpdivide,112:n.KBD_f1,113:n.KBD_f2,114:n.KBD_f3,115:n.KBD_f4,116:n.KBD_f5,117:n.KBD_f6,118:n.KBD_f7,119:n.KBD_f8,120:n.KBD_f9,121:n.KBD_f10,122:n.KBD_f11,123:n.KBD_f12,144:n.KBD_numlock,145:n.KBD_scrolllock,173:n.KBD_minus,186:n.KBD_semicolon,187:n.KBD_equals,188:n.KBD_comma,189:n.KBD_minus,190:n.KBD_period,191:n.KBD_slash,219:n.KBD_leftbracket,220:n.KBD_backslash,221:n.KBD_rightbracket},n.namedKeyCodes={KBD_NONE:n.KBD_NONE,KBD_0:n.KBD_0,KBD_1:n.KBD_1,KBD_2:n.KBD_2,KBD_3:n.KBD_3,KBD_4:n.KBD_4,KBD_5:n.KBD_5,KBD_6:n.KBD_6,KBD_7:n.KBD_7,KBD_8:n.KBD_8,KBD_9:n.KBD_9,KBD_a:n.KBD_a,KBD_b:n.KBD_b,KBD_c:n.KBD_c,KBD_d:n.KBD_d,KBD_e:n.KBD_e,KBD_f:n.KBD_f,KBD_g:n.KBD_g,KBD_h:n.KBD_h,KBD_i:n.KBD_i,KBD_j:n.KBD_j,KBD_k:n.KBD_k,KBD_l:n.KBD_l,KBD_m:n.KBD_m,KBD_n:n.KBD_n,KBD_o:n.KBD_o,KBD_p:n.KBD_p,KBD_q:n.KBD_q,KBD_r:n.KBD_r,KBD_s:n.KBD_s,KBD_t:n.KBD_t,KBD_u:n.KBD_u,KBD_v:n.KBD_v,KBD_w:n.KBD_w,KBD_x:n.KBD_x,KBD_y:n.KBD_y,KBD_z:n.KBD_z,KBD_f1:n.KBD_f1,KBD_f2:n.KBD_f2,KBD_f3:n.KBD_f3,KBD_f4:n.KBD_f4,KBD_f5:n.KBD_f5,KBD_f6:n.KBD_f6,KBD_f7:n.KBD_f7,KBD_f8:n.KBD_f8,KBD_f9:n.KBD_f9,KBD_f10:n.KBD_f10,KBD_f11:n.KBD_f11,KBD_f12:n.KBD_f12,KBD_kp0:n.KBD_kp0,KBD_kp1:n.KBD_kp1,KBD_kp2:n.KBD_kp2,KBD_kp3:n.KBD_kp3,KBD_kp4:n.KBD_kp4,KBD_kp5:n.KBD_kp5,KBD_kp6:n.KBD_kp6,KBD_kp7:n.KBD_kp7,KBD_kp8:n.KBD_kp8,KBD_kp9:n.KBD_kp9,KBD_kpperiod:n.KBD_kpperiod,KBD_kpdivide:n.KBD_kpdivide,KBD_kpmultiply:n.KBD_kpmultiply,KBD_kpminus:n.KBD_kpminus,KBD_kpplus:n.KBD_kpplus,KBD_kpenter:n.KBD_kpenter,KBD_esc:n.KBD_esc,KBD_tab:n.KBD_tab,KBD_backspace:n.KBD_backspace,KBD_enter:n.KBD_enter,KBD_space:n.KBD_space,KBD_leftalt:n.KBD_leftalt,KBD_rightalt:n.KBD_rightalt,KBD_leftctrl:n.KBD_leftctrl,KBD_rightctrl:n.KBD_rightctrl,KBD_leftshift:n.KBD_leftshift,KBD_rightshift:n.KBD_rightshift,KBD_capslock:n.KBD_capslock,KBD_scrolllock:n.KBD_scrolllock,KBD_numlock:n.KBD_numlock,KBD_grave:n.KBD_grave,KBD_minus:n.KBD_minus,KBD_equals:n.KBD_equals,KBD_backslash:n.KBD_backslash,KBD_leftbracket:n.KBD_leftbracket,KBD_rightbracket:n.KBD_rightbracket,KBD_semicolon:n.KBD_semicolon,KBD_quote:n.KBD_quote,KBD_period:n.KBD_period,KBD_comma:n.KBD_comma,KBD_slash:n.KBD_slash,KBD_printscreen:n.KBD_printscreen,KBD_pause:n.KBD_pause,KBD_insert:n.KBD_insert,KBD_home:n.KBD_home,KBD_pageup:n.KBD_pageup,KBD_delete:n.KBD_delete,KBD_end:n.KBD_end,KBD_pagedown:n.KBD_pagedown,KBD_left:n.KBD_left,KBD_up:n.KBD_up,KBD_down:n.KBD_down,KBD_right:n.KBD_right,KBD_extra_lt_gt:n.KBD_extra_lt_gt},n.keyCodesToDom={};for(const e of Object.keys(n.domToKeyCodes)){const t=Number.parseInt(e,10);n.keyCodesToDom[n.domToKeyCodes[t]]=t}n.domToKeyCode=function(e){return n.domToKeyCodes[e]||0}},{"core-js/modules/web.dom-collections.iterator.js":118}],149:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}e("core-js/modules/web.dom-collections.iterator.js");Object.defineProperty(n,"__esModule",{value:!0}),n.Layers=n.layers=void 0;const o=e("notyf"),i=function(e){return e&&e.__esModule?e:{default:e}}(e("simple-keyboard")),s=e("./helpers"),a=e("./keys"),l=e("element-resize-detector")({});n.layers=function(e,t){return new c(e,t||{})};class c{constructor(e,t){r(this,"options",void 0),r(this,"root",void 0),r(this,"loading",void 0),r(this,"canvas",void 0),r(this,"video",void 0),r(this,"mouseOverlay",void 0),r(this,"width",void 0),r(this,"height",void 0),r(this,"fullscreen",!1),r(this,"keyboardVisible",!1),r(this,"pointerLock",!1),r(this,"pointerDisabled",!1),r(this,"pointerButton",0),r(this,"notyf",new o.Notyf),r(this,"toggleKeyboard",(()=>!1)),r(this,"fullscreenElement",void 0),r(this,"clickToStart",void 0),r(this,"loaderText",void 0),r(this,"onResize",void 0),r(this,"onKeyDown",void 0),r(this,"onKeyUp",void 0),r(this,"onKeyPress",void 0),r(this,"onKeysPress",void 0),r(this,"onSave",void 0),r(this,"onSaveStarted",void 0),r(this,"onSaveEnded",void 0),r(this,"onFullscreenChanged",[]),r(this,"onKeyboardChanged",[]),this.options=t,this.root=e,this.root.classList.add("emulator-root"),this.fullscreenElement=t.fullscreenElement||this.root,this.canvas=document.createElement("canvas"),this.canvas.className="emulator-canvas",this.video=document.createElement("video"),this.video.setAttribute("autoplay",""),this.video.setAttribute("playsinline",""),this.video.className="emulator-video",this.loading=(0,s.createDiv)("emulator-loading","\n<div class='emulator-loading-inner'>\n<pre class='emulator-loading-pre-1'>\n _ __\n (_)____ ____/ /___ _____ _________ ____ ___\n / / ___/_____/ __ / __ \\/ ___// ___/ __ \\/ __ `__ \\\n / (__ )_____/ /_/ / /_/ (__ )/ /__/ /_/ / / / / / /\n __/ /____/ \\__,_/\\____/____(_)___/\\____/_/ /_/ /_/\n /___/\n</pre>\n<pre class='emulator-loading-pre-2'>\n</pre>\n<div class='emulator-loader'>\n</div>\n</div>\n"),this.loaderText=this.loading.querySelector(".emulator-loading-pre-2"),this.mouseOverlay=(0,s.createDiv)("emulator-mouse-overlay",""),this.clickToStart=(0,s.createDiv)("emulator-click-to-start-overlay",'\n<div class="emulator-click-to-start-text">Press to start</div>\n<div class="emulator-click-to-start-icon"></div>\n'),this.clickToStart.onclick=()=>{this.clickToStart.style.display="none",this.video.play()},this.root.appendChild(this.canvas),this.root.appendChild(this.video),this.root.appendChild(this.mouseOverlay),this.root.appendChild(this.clickToStart),this.root.appendChild(this.loading),this.width=e.offsetWidth,this.height=e.offsetHeight,this.onResize=[],this.onKeyDown=()=>{},this.onKeyUp=()=>{},this.onKeyPress=()=>{},this.onKeysPress=()=>{},this.onSave=()=>Promise.reject(new Error("Not implemented")),this.onSaveStarted=()=>{},this.onSaveEnded=()=>{},l.listenTo(this.root,(t=>{if(t===e){this.width=t.offsetWidth,this.height=t.offsetHeight;for(const e of this.onResize)e(this.width,this.height)}})),this.initKeyEvents(),this.initKeyboard(),this.preventContextMenu(),this.fullscreenElement.onfullscreenchange=()=>{if(document.fullscreenElement!==this.fullscreenElement){this.fullscreen=!1;for(const e of this.onFullscreenChanged)e(this.fullscreen)}}}initKeyEvents(){window.addEventListener("keydown",(e=>{const t=(0,a.domToKeyCode)(e.keyCode);this.onKeyDown(t)})),window.addEventListener("keyup",(e=>{const t=(0,a.domToKeyCode)(e.keyCode);this.onKeyUp(t)}))}preventContextMenu(){this.root.addEventListener("contextmenu",(e=>(e.stopPropagation(),e.preventDefault(),!1)))}addOnResize(e){this.onResize.push(e)}removeOnResize(e){this.onResize=this.onResize.filter((t=>t!==e))}setOnKeyDown(e){this.onKeyDown=e}fireKeyDown(e){this.onKeyDown(e)}setOnKeyUp(e){this.onKeyUp=e}fireKeyUp(e){this.onKeyUp(e)}setOnKeyPress(e){this.onKeyPress=e}fireKeyPress(e){this.onKeyPress(e)}setOnKeysPress(e){this.onKeysPress=e}fireKeysPress(e){this.onKeysPress(e)}toggleFullscreen(){if(this.fullscreen){this.fullscreen=!1,this.fullscreenElement.classList.contains("emulator-fullscreen-workaround")?this.fullscreenElement.classList.remove("emulator-fullscreen-workaround"):document.exitFullscreen?document.exitFullscreen():document.webkitExitFullscreen?document.webkitExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen();for(const e of this.onFullscreenChanged)e(!1)}else{this.fullscreen=!0;const e=this.fullscreenElement;e.requestFullscreen?e.requestFullscreen():e.webkitRequestFullscreen?e.webkitRequestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.msRequestFullscreen?e.msRequestFullscreen():e.webkitEnterFullscreen?e.webkitEnterFullscreen():this.fullscreenElement.classList.add("emulator-fullscreen-workaround");for(const e of this.onFullscreenChanged)e(!0)}}setOnFullscreen(e){this.onFullscreenChanged.push(e)}removeOnFullscreen(e){this.onFullscreenChanged=this.onFullscreenChanged.filter((t=>t!==e))}setOnKeyboardVisibility(e){this.onKeyboardChanged.push(e)}removeOnKeyboardVisibility(e){this.onKeyboardChanged=this.onKeyboardChanged.filter((t=>t!==e))}save(){return this.onSaveStarted(),this.onSave().then((()=>{this.notyf.success("Saved"),this.onSaveEnded()})).catch((e=>{this.notyf.error(e.message),this.onSaveEnded()}))}setOnSave(e){this.onSave=e}getOnSave(){return this.onSave}setOnSaveStarted(e){this.onSaveStarted=e}setOnSaveEnded(e){this.onSaveEnded=e}hideLoadingLayer(){this.loading.style.visibility="hidden"}showLoadingLayer(){this.loading.style.visibility="visible"}setLoadingMessage(e){this.loaderText.innerHTML=e}switchToVideo(){this.video.style.display="block",this.canvas.style.display="none"}showClickToStart(){this.clickToStart.style.display="flex"}initKeyboard(){let e=!1;const t=[{"{esc}":"ESC","{bksp}":"Backspace","{enter}":"⏎","{space}":"Space"},{"{esc}":"ESC","{bksp}":"Backspace","{enter}":"⏎","{space}":"Space",q:"й",w:"ц",e:"у",r:"к",t:"е",y:"н",u:"г",i:"ш",o:"щ",p:"з","{":"х","}":"ъ",a:"ф",s:"ы",d:"в",f:"а",g:"п",h:"р",j:"о",k:"л",l:"д",";":"ж","'":"э",z:"я",x:"ч",c:"с",v:"м",b:"и",n:"т",m:"ь",",":"б",".":"ю"}];let n=0;const r=this.options.keyboardDiv||(0,s.createDiv)("");r.classList.add("emulator-keyboard"),r.style.display="none",(0,s.stopPropagation)(r);const o=new i.default(r,{layout:{en:["{esc} ` 1 2 3 4 5 6 7 8 9 0 - = {bksp}","q w e r t y u i o p { } \\","a s d f g h j k l ; ' [ {enter}","⎘ z x c v b n m , . / ] {space}"]},layoutName:"en",display:t[n],onKeyPress:e=>{if("⎘"===e)return n=(n+1)%t.length,void o.setOptions({display:t[n]});const r=function(e){if(e.length>1)return"{enter}"===e?[a.KBD_enter]:"{shift}"===e?[a.KBD_leftshift]:"{bksp}"===e?[a.KBD_backspace]:"{lock}"===e?[a.KBD_capslock]:"{tab}"===e?[a.KBD_tab]:"{space}"===e?[a.KBD_space]:"{esc}"===e?[a.KBD_esc]:"ctrl"===e?[a.KBD_leftctrl]:"{alt}"===e?[a.KBD_leftalt]:(console.warn("Unknown button",e),[]);if(","===e)return[a.KBD_comma];if("."===e)return[a.KBD_period];if("'"===e)return[a.KBD_quote];if(":"===e)return[a.KBD_semicolon];if("{"===e)return[a.KBD_leftshift,a.KBD_leftbracket];if("}"===e)return[a.KBD_leftshift,a.KBD_rightbracket];const t=(0,a.domToKeyCode)(e.toUpperCase().charCodeAt(0));return 0===t?[]:[t]}(e);1===r.length?this.fireKeyPress(r[0]):r.length>0&&this.fireKeysPress(r)},preventMouseDownDefault:!0,preventMouseUpDefault:!0,stopMouseDownPropagation:!0,stopMouseUpPropagation:!0,autoUseTouchEvents:!0,useMouseEvents:!0});this.toggleKeyboard=()=>{e=!e;const t=e?"block":"none";r.style.display=t;for(const t of this.onKeyboardChanged)t(e);return this.keyboardVisible=e,e},this.options.keyboardDiv||this.mouseOverlay.appendChild(r)}}n.Layers=c},{"./helpers":147,"./keys":148,"core-js/modules/web.dom-collections.iterator.js":118,"element-resize-detector":123,notyf:131,"simple-keyboard":132}],150:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.lifecycle=void 0,n.lifecycle=function(e){let t="",n="";function r(){document[t]?e.pause():e.resume()}void 0!==document.hidden?(t="hidden",n="visibilitychange"):void 0!==document.mozHidden?(t="mozHidden",n="mozvisibilitychange"):void 0!==document.msHidden?(t="msHidden",n="msvisibilitychange"):void 0!==document.webkitHidden&&(t="webkitHidden",n="webkitvisibilitychange"),document.addEventListener(n,r),e.events().onExit((()=>{document.removeEventListener(n,r)}))}},{}],151:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.MemStorage=void 0,n.MemStorage=class{constructor(){r(this,"length",0),r(this,"storage",{})}setItem(e,t){this.storage[e]=t,this.length=Object.keys(this.storage).length}getItem(e){const t=this.storage[e];return void 0===t?null:t}removeItem(e){delete this.storage[e],this.length=Object.keys(this.storage).length}key(e){const t=Object.keys(this.storage);return void 0===t[e]?null:t[e]}clear(){this.length=0,this.storage={}}}},{}],152:[function(e,t,n){"use strict";function r(e,t){if(e.type.match(/^touch/)){const n=e,r=t.getBoundingClientRect();return{x:n.targetTouches[0].clientX-r.x,y:n.targetTouches[0].clientY-r.y,mX:0,mY:0}}if(e.type.match(/^pointer/)){const t=e;return{x:t.offsetX,y:t.offsetY,mX:t.movementX,mY:t.movementY}}{const t=e;return{x:t.offsetX,y:t.offsetY,mX:t.movementX,mY:t.movementY,button:0===t.button?0:1}}}Object.defineProperty(n,"__esModule",{value:!0}),n.pointers=n.getPointerState=n.pointer=void 0,n.pointer=function(){const e=/iPhone|iPad|iPod|Android/i.test(navigator.userAgent),t=e&&!!("ontouchstart"in window),n=e&&!!window.PointerEvent,r=e&&!!window.MSPointerEvent;let o=!e;const i=[],s=[],a=[],l=[],c=[];return n?(i.push("pointerdown"),a.push("pointerup","pointercancel"),s.push("pointermove"),c.push("touchstart","touchmove","touchend")):r?(i.push("MSPointerDown"),s.push("MSPointerMove"),a.push("MSPointerUp")):t?(o=!1,i.push("touchstart","mousedown"),s.push("touchmove"),a.push("touchend","touchcancel","mouseup")):(i.push("mousedown"),s.push("mousemove"),a.push("mouseup"),l.push("mouseleave")),{mobile:e,canLock:o,starters:i,changers:s,enders:a,prevents:c,leavers:l}}(),n.getPointerState=r,n.pointers={bind:n.pointer,getPointerState:r}},{}],153:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.LStorage=void 0;const o=e("./mem-storage");n.LStorage=class{constructor(e,t){r(this,"backend",void 0),r(this,"length",void 0),r(this,"prefix",void 0),this.prefix=t;try{this.backend=e||localStorage,this.testBackend()}catch(e){this.backend=new o.MemStorage}this.length=this.backend.length,"function"==typeof this.backend.sync&&(this.sync=e=>{this.backend.sync(e)})}testBackend(){const e=this.prefix+".test.record";this.backend.setItem(e,"123");const t=this.backend.getItem(e);if(this.backend.removeItem(e),"123"!==t||null!==this.backend.getItem(e))throw new Error("Storage backend is not working properly")}setLocalStoragePrefix(e){this.prefix=e}clear(){if(!this.backend.length)return;const e=[];for(let t=0;t<this.backend.length;++t){const n=this.backend.key(t);n&&n.startsWith(this.prefix)&&e.push(n)}for(const t of e)this.backend.removeItem(t);this.length=this.backend.length}key(e){return this.backend.key(e)}setItem(e,t){if(!t||void 0===t.length||0===t.length)return void this.writeStringToKey(e,"");let n=0;for(;n<t.length;){let r=t.substr(n,1024);n+=r.length,n<t.length&&(r+="@"),this.writeStringToKey(e,r),e+="."}}getItem(e){let t=this.readStringFromKey(e);if(null===t)return null;if(0===t.length)return t;for(;"@"===t[t.length-1];){t=t.substr(0,t.length-1),e+=".";const n=this.readStringFromKey(e);t+=null===n?"":n}return t}removeItem(e){this.backend.removeItem(this.prefix+e),this.length=this.backend.length}writeStringToKey(e,t){this.backend.setItem(this.prefix+e,t),this.length=this.backend.length}readStringFromKey(e){return this.backend.getItem(this.prefix+e)}}},{"./mem-storage":151,"core-js/modules/web.dom-collections.iterator.js":118}],154:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.EmulatorsUi=void 0;const o=e("./build"),i=e("./dom/layers"),s=e("./dom/lifecycle"),a=e("./network/xhr"),l=e("./graphics/_2d"),c=e("./graphics/webgl"),u=e("./graphics/video"),d=e("./controls/keyboard"),f=e("./controls/mouse/mouse-common"),p=e("./controls/nipple"),h=e("./controls/options"),m=e("./dom/keys"),y=e("./sound/audio-node"),g=e("./notification/notyf"),v=e("./persist/save-load"),b=e("./controls/grid"),_=e("./dom/pointer"),w=e("./dom/storage"),x=e("./js-dos");class k{constructor(){r(this,"build",o.Build),r(this,"dom",{layers:i.layers,lifecycle:s.lifecycle,pointers:_.pointers,storage:new w.LStorage(void 0,"emulators.ui.")}),r(this,"network",{resolveBundle:a.resolveBundle}),r(this,"graphics",{webGl:c.webGl,_2d:l._2d,video:u.video}),r(this,"sound",{audioNode:y.audioNode}),r(this,"persist",{save:v.save,load:v.load}),r(this,"controls",{getGrid:b.getGrid,namedKeyCodes:m.namedKeyCodes,domToKeyCodes:m.domToKeyCodes,domToKeyCode:m.domToKeyCode,keyCodesToDom:m.keyCodesToDom,keyboard:d.keyboard,mouse:f.mouse,nipple:p.nipple,options:h.options}),r(this,"notifications",{notyf:g.notyf}),r(this,"dos",((e,t)=>new x.DosInstance(e,j,t||{})))}}n.EmulatorsUi=k;const j=new k;window.emulatorsUi=j,window.Dos=j.dos},{"./build":133,"./controls/grid":135,"./controls/keyboard":136,"./controls/mouse/mouse-common":140,"./controls/nipple":144,"./controls/options":146,"./dom/keys":148,"./dom/layers":149,"./dom/lifecycle":150,"./dom/pointer":152,"./dom/storage":153,"./graphics/_2d":155,"./graphics/video":156,"./graphics/webgl":157,"./js-dos":158,"./network/xhr":159,"./notification/notyf":160,"./persist/save-load":162,"./sound/audio-node":163}],155:[function(e,t,n){"use strict";e("core-js/modules/es.typed-array.uint8-clamped-array.js"),e("core-js/modules/es.typed-array.sort.js"),Object.defineProperty(n,"__esModule",{value:!0}),n._2d=void 0,n._2d=function(e,t){const n=e.canvas,r=n.getContext("2d");if(null===r)throw new Error("Unable to create 2d context on given canvas");let o=e.width,i=e.height,s=0,a=0;const l=()=>{const e=s/a;let t=o,r=o/e;r>i&&(r=i,t=i*e),n.style.position="relative",n.style.top=(i-r)/2+"px",n.style.left=(o-t)/2+"px",n.style.width=t+"px",n.style.height=r+"px"},c=(e,t)=>{o=e,i=t,l()};e.addOnResize(c);let u=new Uint8ClampedArray(0);const d=(e,t)=>{s=e,a=t,n.width=s,n.height=a,u=new Uint8ClampedArray(e*t*4),l()};t.events().onFrameSize(d),t.events().onFrame(((e,t)=>{if(null===e&&null===t)return;const n=null!==e?e:t;let o=0,i=0;for(;i<u.length;)u[i++]=n[o++],u[i++]=n[o++],u[i++]=n[o++],u[i++]=255,n.length===u.length&&o++;r.putImageData(new ImageData(u,s,a),0,0)})),d(t.width(),t.height()),t.events().onExit((()=>{e.removeOnResize(c)}))}},{"core-js/modules/es.typed-array.sort.js":115,"core-js/modules/es.typed-array.uint8-clamped-array.js":117}],156:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.video=void 0,n.video=function(e,t){e.switchToVideo(),t.events().onMessage(((t,n)=>{"onremotestream"===t&&window.Janus.attachMediaStream(e.video,n)}))}},{}],157:[function(e,t,n){"use strict";function r(e,t,n){const r=e.createShader(t);if(e.shaderSource(r,n),e.compileShader(r),!e.getShaderParameter(r,e.COMPILE_STATUS)){const t=e.getShaderInfoLog(r);throw e.deleteShader(r),new Error("An error occurred compiling the shaders: "+t)}return r}e("core-js/modules/es.typed-array.uint8-array.js"),e("core-js/modules/es.typed-array.sort.js"),e("core-js/modules/es.typed-array.float32-array.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.webGl=void 0,n.webGl=function(e,t){const n=e.canvas,o=n.getContext("webgl");if(null===o)throw new Error("Unable to create webgl context on given canvas");const i=function(e,t,n){const o=r(e,e.VERTEX_SHADER,"\nattribute vec4 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nvarying highp vec2 vTextureCoord;\n\nvoid main(void) {\n gl_Position = aVertexPosition;\n vTextureCoord = aTextureCoord;\n}\n"),i=r(e,e.FRAGMENT_SHADER,"\nvarying highp vec2 vTextureCoord;\nuniform sampler2D uSampler;\n\n\nvoid main(void) {\n highp vec4 color = texture2D(uSampler, vTextureCoord);\n gl_FragColor = vec4(color.r, color.g, color.b, 1.0);\n}\n"),s=e.createProgram();if(e.attachShader(s,o),e.attachShader(s,i),e.linkProgram(s),!e.getProgramParameter(s,e.LINK_STATUS))throw new Error("Unable to initialize the shader program: "+e.getProgramInfoLog(s));return s}(o),s=o.getAttribLocation(i,"aVertexPosition"),a=o.getAttribLocation(i,"aTextureCoord"),l=o.getUniformLocation(i,"uSampler");!function(e,t,n){const r=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,r);e.bufferData(e.ARRAY_BUFFER,new Float32Array([-1,-1,0,1,-1,0,1,1,0,-1,-1,0,1,1,0,-1,1,0]),e.STATIC_DRAW),e.vertexAttribPointer(t,3,e.FLOAT,!1,0,0),e.enableVertexAttribArray(t);const o=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,o);e.bufferData(e.ARRAY_BUFFER,new Float32Array([0,1,1,1,1,0,0,1,1,0,0,0]),e.STATIC_DRAW),e.vertexAttribPointer(n,2,e.FLOAT,!1,0,0),e.enableVertexAttribArray(n)}(o,s,a);const c=o.createTexture();o.bindTexture(o.TEXTURE_2D,c),o.texParameteri(o.TEXTURE_2D,o.TEXTURE_WRAP_S,o.CLAMP_TO_EDGE),o.texParameteri(o.TEXTURE_2D,o.TEXTURE_WRAP_T,o.CLAMP_TO_EDGE),o.texParameteri(o.TEXTURE_2D,o.TEXTURE_MIN_FILTER,o.LINEAR),o.texParameteri(o.TEXTURE_2D,o.TEXTURE_MAG_FILTER,o.LINEAR);const u=new Uint8Array([0,0,0]);o.texImage2D(o.TEXTURE_2D,0,o.RGB,1,1,0,o.RGB,o.UNSIGNED_BYTE,u),o.useProgram(i),o.activeTexture(o.TEXTURE0),o.uniform1i(l,0);let d=e.width,f=e.height,p=0,h=0;const m=()=>{const e=p/h;let t=d,r=d/e;r>f&&(r=f,t=f*e),n.style.position="relative",n.style.top=(f-r)/2+"px",n.style.left=(d-t)/2+"px",n.style.width=t+"px",n.style.height=r+"px"},y=(e,t)=>{d=e,f=t,m()};e.addOnResize(y);const g=(e,t)=>{p=e,h=t,n.width=p,n.height=h,o.viewport(0,0,p,h),m()};t.events().onFrameSize(g),g(t.width(),t.height());let v=null,b=null,_=0;t.events().onFrame(((e,t)=>{b=null!=e?e:t,_=null!=e?o.RGB:o.RGBA,null===v&&(v=requestAnimationFrame(w))}));const w=()=>{o.texImage2D(o.TEXTURE_2D,0,_,p,h,0,_,o.UNSIGNED_BYTE,b),o.drawArrays(o.TRIANGLES,0,6),v=null,b=null};t.events().onExit((()=>{e.removeOnResize(y)}))}},{"core-js/modules/es.typed-array.float32-array.js":114,"core-js/modules/es.typed-array.sort.js":115,"core-js/modules/es.typed-array.uint8-array.js":116}],158:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.DosInstance=void 0;const o=e("./controls/layers-config"),i=e("./controls/legacy-layers-control"),s=e("./controls/null-layers-control"),a=e("./controls/layers-control"),l=e("./dom/pointer");n.DosInstance=class{constructor(e,t,n){var o,i;r(this,"emulatorsUi",void 0),r(this,"emulatorFunction",void 0),r(this,"createTransportLayer",void 0),r(this,"layers",void 0),r(this,"layersConfig",null),r(this,"ciPromise",void 0),r(this,"options",void 0),r(this,"mobileControls",void 0),r(this,"mirroredControls",void 0),r(this,"scaleControls",void 0),r(this,"autolock",void 0),r(this,"sensitivity",void 0),r(this,"storage",void 0),r(this,"clickToStart",void 0),r(this,"unbindControls",(()=>{})),r(this,"storedLayersConfig",null),r(this,"onMobileControlsChanged",void 0),this.options=n,this.emulatorsUi=t,this.storage=t.dom.storage,this.emulatorFunction=n.emulatorFunction||"dosboxWorker",this.clickToStart=n.clickToStart||!1,this.layers=this.emulatorsUi.dom.layers(e,n.layersOptions),this.layers.showLoadingLayer(),this.createTransportLayer=n.createTransportLayer,this.mobileControls=l.pointers.bind.mobile,this.autolock=!1,this.mirroredControls="true"===this.storage.getItem("mirroredControls");const s=Number.parseFloat(null!==(o=this.storage.getItem("scaleControls"))&&void 0!==o?o:"1.0");this.scaleControls=Number.isNaN(s)?1:s;const a=Number.parseFloat(null!==(i=this.storage.getItem("sensitivity"))&&void 0!==i?i:"1.0");if(this.sensitivity=Number.isNaN(a)?1:a,this.onMobileControlsChanged=()=>{},"backend"===this.emulatorFunction&&void 0===this.createTransportLayer)throw new Error("Emulator function set to 'backend' but 'createTransportLayer' is not a function")}async run(e,t,n){var r,i,s;await this.stop(),this.layers.setLoadingMessage("Starting...");const a=null!=n&&n.length>0?n:e+".changes";let l;try{l=await this.runBundle(e,t,a)}catch(e){throw this.layers.setLoadingMessage("Unexpected error occured..."),this.layers.notyf.error({message:"Can't start emulator look browser logs for more info"}),console.error(e),e}const c=this.emulatorsUi;if("janus"===this.emulatorFunction)c.graphics.video(this.layers,l);else{c.persist.save(a,this.layers,l,emulators);try{if(!0===this.options.noWebGL)throw new Error("WebGL is disabled by options");c.graphics.webGl(this.layers,l)}catch(e){console.error("Unable to create webgl canvas, fallback to 2d rendering"),c.graphics._2d(this.layers,l)}c.sound.audioNode(l)}c.dom.lifecycle(l);const u=await l.config();return this.autolock=!0===(null===(r=u.output)||void 0===r||null===(i=r.options)||void 0===i||null===(s=i.autolock)||void 0===s?void 0:s.value),await this.setLayersConfig((0,o.extractLayersConfig)(u)),this.mobileControls||(this.mobileControls=!0,this.disableMobileControls()),this.layers.setLoadingMessage("Ready"),this.layers.hideLoadingLayer(),this.clickToStart&&this.layers.showClickToStart(),l}async stop(){if(this.layers.showLoadingLayer(),void 0===this.ciPromise)return;const e=await this.ciPromise;delete this.ciPromise,await e.exit()}async setLayersConfig(e,t){if(void 0===this.ciPromise)return;const n=await this.ciPromise;this.layersConfig=e,this.unbindControls(),null===e?this.unbindControls=(0,s.initNullLayersControl)(this,this.layers,n):void 0===e.version?this.unbindControls=(0,i.initLegacyLayersControl)(this,this.layers,e,n):this.unbindControls=(0,a.initLayersControl)(this.layers,e,n,this,this.mirroredControls,this.scaleControls,t)}getLayersConfig(){return this.layersConfig}async enableMobileControls(){this.mobileControls||(this.mobileControls=!0,await this.setLayersConfig(this.storedLayersConfig),this.storedLayersConfig=null,this.onMobileControlsChanged(!0))}async disableMobileControls(){this.mobileControls&&(this.mobileControls=!1,this.storedLayersConfig=this.layersConfig,await this.setLayersConfig(null),this.onMobileControlsChanged(!1))}async setMirroredControls(e){this.mirroredControls!==e&&(this.mirroredControls=e,this.storage.setItem("mirroredControls",e+""),e?this.mobileControls?await this.setLayersConfig(this.layersConfig):await this.enableMobileControls():this.mobileControls&&await this.setLayersConfig(this.layersConfig))}async setScaleControls(e){e!==this.scaleControls&&(this.scaleControls=e,this.storage.setItem("scaleControls",e+""),this.mobileControls&&await this.setLayersConfig(this.layersConfig))}async setSensitivity(e){e!==this.sensitivity&&(this.sensitivity=e,this.storage.setItem("sensitivity",e+""),await this.setLayersConfig(this.layersConfig))}async setAutolock(e){e!==this.autolock&&(this.autolock=e,await this.setLayersConfig(this.layersConfig))}setOnMobileControlsChanged(e){this.onMobileControlsChanged=e}async runBundle(e,t,n){const r=this.emulatorsUi;if("janus"===this.emulatorFunction)this.layers.setLoadingMessage("Connecting..."),this.ciPromise=emulators.janus(e);else{this.layers.setLoadingMessage("Downloading bundle ...");const o=r.network.resolveBundle(e,{onprogress:e=>this.layers.setLoadingMessage("Downloading bundle "+e+"%")});try{let e;e=null!=t&&t.length>0?await r.network.resolveBundle(t,{httpCache:!1}):await r.persist.load(n,emulators);const i=await o;"backend"===this.emulatorFunction?this.ciPromise=emulators.backend([i,e],this.createTransportLayer()):this.ciPromise=emulators[this.emulatorFunction]([i,e])}catch{const e=await o;"backend"===this.emulatorFunction?this.ciPromise=emulators.backend([e],this.createTransportLayer()):this.ciPromise=emulators[this.emulatorFunction]([e])}}return this.ciPromise}}},{"./controls/layers-config":137,"./controls/layers-control":138,"./controls/legacy-layers-control":139,"./controls/null-layers-control":145,"./dom/pointer":152}],159:[function(e,t,n){"use strict";e("core-js/modules/es.typed-array.uint8-array.js"),e("core-js/modules/es.typed-array.sort.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.resolveBundle=void 0,n.resolveBundle=async function(e,t){const n=null==t?void 0:t.onprogress,r=!(!1===(null==t?void 0:t.httpCache));return new Promise(((t,o)=>{const i=new XMLHttpRequest;i.open("GET",e,!0),i.overrideMimeType("text/plain; charset=x-user-defined"),i.addEventListener("error",(()=>{o(new Error("Network error, can't download "+e))})),i.addEventListener("abort",(()=>{o(new Error("Request canceled for url "+e))}),!1),i.responseType="arraybuffer",i.onreadystatechange=()=>{4===i.readyState&&(200===i.status?(void 0!==n&&n(100),t(new Uint8Array(i.response))):o(new Error("Network error, can't download "+e)))},void 0!==n&&(i.onprogress=e=>{if(e.total&&e.total>0){const t=Math.round(1e4*e.loaded/e.total)/100;n(t)}}),!1===r&&(i.setRequestHeader("Cache-Control","no-cache, no-store, max-age=0"),i.setRequestHeader("Expires","Tue, 01 Jan 1980 1:00:00 GMT"),i.setRequestHeader("Pragma","no-cache")),i.send()}))}},{"core-js/modules/es.typed-array.sort.js":115,"core-js/modules/es.typed-array.uint8-array.js":116}],160:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.notyf=void 0,n.notyf=function(e,t){const n=e.notyf;t.events().onMessage((function(e){if("error"===e){for(var t=arguments.length,r=new Array(t>1?t-1:0),o=1;o<t;o++)r[o-1]=arguments[o];n.error({message:JSON.stringify(r)})}}))}},{}],161:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(n,"__esModule",{value:!0}),n.makeCache=void 0;class o{close(){}put(e,t){return Promise.resolve()}get(e,t){return void 0!==t?Promise.resolve(t):Promise.reject(new Error("Cache is not supported on this host"))}forEach(e,t){t()}}n.makeCache=function(e,t){return new Promise((n=>{new i(e,n,(e=>{t.onErr(e),n(new o)}))}))};class i{constructor(e,t,n){if(r(this,"version",void 0),r(this,"storeName","files"),r(this,"indexedDB",void 0),r(this,"db",null),this.version=e,this.indexedDB="undefined"==typeof window?void 0:window.indexedDB||window.mozIndexedDB||window.webkitIndexedDB||window.msIndexedDB,this.indexedDB)try{const r=this.indexedDB.open("js-dos-cache ("+e+")",1);r.onerror=e=>{var t;n("Can't open cache database: "+(null===(t=r.error)||void 0===t?void 0:t.message))},r.onsuccess=e=>{this.db=r.result,t(this)},r.onupgradeneeded=e=>{try{this.db=r.result,this.db.onerror=e=>{n("Can't upgrade cache database")},this.db.createObjectStore(this.storeName)}catch(e){n("Can't upgrade cache database")}}}catch(e){n("Can't open cache database: "+e.message)}else n("Indexed db is not supported on this host")}close(){null!==this.db&&(this.db.close(),this.db=null)}put(e,t){return new Promise((n=>{if(null===this.db)return void n();const r=this.db.transaction(this.storeName,"readwrite");r.oncomplete=()=>n(),r.objectStore(this.storeName).put(t,e)}))}get(e,t){return new Promise(((n,r)=>{function o(e){void 0===t?r(new Error(e)):n(t)}if(null===this.db)return void o("db is not initalized");const i=this.db.transaction(this.storeName,"readonly").objectStore(this.storeName).get(e);i.onerror=()=>r(new Error("Can't read value for key '"+e+"'")),i.onsuccess=()=>{i.result?n(i.result):o("Result is empty for key '"+e+"', result: "+i.result)}}))}forEach(e,t){if(null===this.db)return void t();const n=this.db.transaction(this.storeName,"readonly").objectStore(this.storeName).openCursor();n.onerror=()=>t(),n.onsuccess=n=>{const r=n.target.result;r?(e(r.key.toString(),r.value),r.continue()):t()}}}},{}],162:[function(e,t,n){"use strict";e("core-js/modules/es.typed-array.uint8-array.js"),e("core-js/modules/es.typed-array.sort.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.load=n.save=void 0;const r=(0,e("./cache").makeCache)("emulators-ui-saves",{onErr:console.error});n.save=function(e,t,n,o){t.setOnSave((async()=>{const t=await r,o=await n.persist();return t.put(e,o.buffer)}))},n.load=async function(e,t){return(await r).get(e).then((e=>new Uint8Array(e)))}},{"./cache":161,"core-js/modules/es.typed-array.sort.js":115,"core-js/modules/es.typed-array.uint8-array.js":116}],163:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.audioNode=void 0;class r{constructor(){var e,t;t=[],(e="samplesQueue")in this?Object.defineProperty(this,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):this[e]=t}push(e){this.samplesQueue.push(e)}length(){let e=0;for(const t of this.samplesQueue)e+=t.length;return e}writeTo(e,t){let n=0;for(;this.samplesQueue.length>0;){const r=this.samplesQueue[0],o=Math.min(t-n,r.length);if(o===r.length?(e.set(r,n),this.samplesQueue.shift()):(e.set(r.slice(0,o),n),this.samplesQueue[0]=r.slice(o)),n+=o,n===t)break}n<t&&e.fill(0,n)}}n.audioNode=function(e){const t=e.soundFrequency();if(0===t)return void console.warn("Can't create audio node with sampleRate === 0, ingnoring");let n=null;if("undefined"!=typeof AudioContext?n=new AudioContext({sampleRate:t,latencyHint:"interactive"}):void 0!==window.webkitAudioContext&&(n=new window.webkitAudioContext({sampleRate:t,latencyHint:"interactive"})),null==n)return;const o=new r;e.events().onSoundPush((e=>{o.length()<6144&&o.push(e)}));const i=n.createScriptProcessor(2048,0,1);let s=!1,a=0;const l=e.directSound;i.onaudioprocess=void 0!==e.directSound?e=>{if(!s){const e=l.buffer[0];s=Math.ceil(e[e.length-1])>0}if(!s)return;let t=0,n=e.outputBuffer.length;const r=e.outputBuffer.numberOfChannels;let o,i=l.buffer[a];for(;n>0&&(o=Math.ceil(i[i.length-1]))>0;)if(n>=o){const s=i.subarray(0,o);for(let n=0;n<r;++n)e.outputBuffer.getChannelData(n).set(s,t);t+=o,n-=o,i[i.length-1]=0,a=(a+1)%l.ringSize,i=l.buffer[a]}else{const s=i.subarray(0,n);for(let n=0;n<r;++n)e.outputBuffer.getChannelData(n).set(s,t);i[i.length-1]=o-n,i.set(i.subarray(n,n+i[i.length-1])),n=0}}:e=>{const t=e.outputBuffer.length,n=e.outputBuffer.numberOfChannels,r=o.length();if(s||(s=r>=2048),s)for(let r=0;r<n;r++){const n=e.outputBuffer.getChannelData(r);o.writeTo(n,t)}},i.connect(n.destination);const c=()=>{null!==n&&"suspended"===n.state&&n.resume()};document.addEventListener("click",c,{once:!0}),document.addEventListener("touchstart",c,{once:!0}),document.addEventListener("keydown",c,{once:!0}),e.events().onExit((()=>{null!==n&&(i.disconnect(),n.close()),document.removeEventListener("click",c),document.removeEventListener("touchstart",c),document.removeEventListener("keydown",c)}))}},{"core-js/modules/web.dom-collections.iterator.js":118}]},{},[154]),function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(i)return i(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i="function"==typeof require&&require,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(e,t,n){t.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},{}],2:[function(e,t,n){var r=e("./_wks")("unscopables"),o=Array.prototype;null==o[r]&&e("./_hide")(o,r,{}),t.exports=function(e){o[r][e]=!0}},{"./_hide":31,"./_wks":99}],3:[function(e,t,n){"use strict";var r=e("./_string-at")(!0);t.exports=function(e,t,n){return t+(n?r(e,t).length:1)}},{"./_string-at":80}],4:[function(e,t,n){t.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},{}],5:[function(e,t,n){var r=e("./_is-object");t.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},{"./_is-object":39}],6:[function(e,t,n){"use strict";var r=e("./_to-object"),o=e("./_to-absolute-index"),i=e("./_to-length");t.exports=[].copyWithin||function(e,t,n){var s=r(this),a=i(s.length),l=o(e,a),c=o(t,a),u=2<arguments.length?n:void 0,d=Math.min((void 0===u?a:o(u,a))-c,a-l),f=1;for(c<l&&l<c+d&&(f=-1,c+=d-1,l+=d-1);0<d--;)c in s?s[l]=s[c]:delete s[l],l+=f,c+=f;return s}},{"./_to-absolute-index":85,"./_to-length":89,"./_to-object":90}],7:[function(e,t,n){"use strict";var r=e("./_to-object"),o=e("./_to-absolute-index"),i=e("./_to-length");t.exports=function(e,t,n){for(var s=r(this),a=i(s.length),l=arguments.length,c=o(1<l?t:void 0,a),u=2<l?n:void 0,d=void 0===u?a:o(u,a);c<d;)s[c++]=e;return s}},{"./_to-absolute-index":85,"./_to-length":89,"./_to-object":90}],8:[function(e,t,n){var r=e("./_to-iobject"),o=e("./_to-length"),i=e("./_to-absolute-index");t.exports=function(e){return function(t,n,s){var a,l=r(t),c=o(l.length),u=i(s,c);if(e&&n!=n){for(;u<c;)if((a=l[u++])!=a)return!0}else for(;u<c;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}}},{"./_to-absolute-index":85,"./_to-iobject":88,"./_to-length":89}],9:[function(e,t,n){var r=e("./_ctx"),o=e("./_iobject"),i=e("./_to-object"),s=e("./_to-length"),a=e("./_array-species-create");t.exports=function(e,t){var n=1==e,l=2==e,c=3==e,u=4==e,d=6==e,f=5==e||d,p=t||a;return function(t,a,h){for(var m,y,g=i(t),v=o(g),b=r(a,h,3),_=s(v.length),w=0,x=n?p(t,_):l?p(t,0):void 0;w<_;w++)if((f||w in v)&&(y=b(m=v[w],w,g),e))if(n)x[w]=y;else if(y)switch(e){case 3:return!0;case 5:return m;case 6:return w;case 2:x.push(m)}else if(u)return!1;return d?-1:c||u?u:x}}},{"./_array-species-create":11,"./_ctx":16,"./_iobject":36,"./_to-length":89,"./_to-object":90}],10:[function(e,t,n){var r=e("./_is-object"),o=e("./_is-array"),i=e("./_wks")("species");t.exports=function(e){var t;return o(e)&&("function"!=typeof(t=e.constructor)||t!==Array&&!o(t.prototype)||(t=void 0),r(t)&&null===(t=t[i])&&(t=void 0)),void 0===t?Array:t}},{"./_is-array":38,"./_is-object":39,"./_wks":99}],11:[function(e,t,n){var r=e("./_array-species-constructor");t.exports=function(e,t){return new(r(e))(t)}},{"./_array-species-constructor":10}],12:[function(e,t,n){var r=e("./_cof"),o=e("./_wks")("toStringTag"),i="Arguments"==r(function(){return arguments}());t.exports=function(e){var t,n,s;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=Object(e),o))?n:i?r(t):"Object"==(s=r(t))&&"function"==typeof t.callee?"Arguments":s}},{"./_cof":13,"./_wks":99}],13:[function(e,t,n){var r={}.toString;t.exports=function(e){return r.call(e).slice(8,-1)}},{}],14:[function(e,t,n){var r=t.exports={version:"2.6.11"};"number"==typeof __e&&(__e=r)},{}],15:[function(e,t,n){"use strict";var r=e("./_object-dp"),o=e("./_property-desc");t.exports=function(e,t,n){t in e?r.f(e,t,o(0,n)):e[t]=n}},{"./_object-dp":54,"./_property-desc":69}],16:[function(e,t,n){var r=e("./_a-function");t.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}}},{"./_a-function":1}],17:[function(e,t,n){t.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},{}],18:[function(e,t,n){t.exports=!e("./_fails")((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},{"./_fails":24}],19:[function(e,t,n){var r=e("./_is-object"),o=e("./_global").document,i=r(o)&&r(o.createElement);t.exports=function(e){return i?o.createElement(e):{}}},{"./_global":29,"./_is-object":39}],20:[function(e,t,n){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},{}],21:[function(e,t,n){var r=e("./_object-keys"),o=e("./_object-gops"),i=e("./_object-pie");t.exports=function(e){var t=r(e),n=o.f;if(n)for(var s,a=n(e),l=i.f,c=0;a.length>c;)l.call(e,s=a[c++])&&t.push(s);return t}},{"./_object-gops":59,"./_object-keys":62,"./_object-pie":63}],22:[function(e,t,n){var r=e("./_global"),o=e("./_core"),i=e("./_hide"),s=e("./_redefine"),a=e("./_ctx"),l="prototype",c=function(e,t,n){var u,d,f,p,h=e&c.F,m=e&c.G,y=e&c.S,g=e&c.P,v=e&c.B,b=m?r:y?r[t]||(r[t]={}):(r[t]||{})[l],_=m?o:o[t]||(o[t]={}),w=_[l]||(_[l]={});for(u in m&&(n=t),n)f=((d=!h&&b&&void 0!==b[u])?b:n)[u],p=v&&d?a(f,r):g&&"function"==typeof f?a(Function.call,f):f,b&&s(b,u,f,e&c.U),_[u]!=f&&i(_,u,p),g&&w[u]!=f&&(w[u]=f)};r.core=o,c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,t.exports=c},{"./_core":14,"./_ctx":16,"./_global":29,"./_hide":31,"./_redefine":71}],23:[function(e,t,n){var r=e("./_wks")("match");t.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[r]=!1,!"/./"[e](t)}catch(e){}}return!0}},{"./_wks":99}],24:[function(e,t,n){t.exports=function(e){try{return!!e()}catch(e){return!0}}},{}],25:[function(e,t,n){"use strict";e("./es6.regexp.exec");var r=e("./_redefine"),o=e("./_hide"),i=e("./_fails"),s=e("./_defined"),a=e("./_wks"),l=e("./_regexp-exec"),c=a("species"),u=!i((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")})),d=function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return 2===n.length&&"a"===n[0]&&"b"===n[1]}();t.exports=function(e,t,n){var f=a(e),p=!i((function(){var t={};return t[f]=function(){return 7},7!=""[e](t)})),h=p?!i((function(){var t=!1,n=/a/;return n.exec=function(){return t=!0,null},"split"===e&&(n.constructor={},n.constructor[c]=function(){return n}),n[f](""),!t})):void 0;if(!p||!h||"replace"===e&&!u||"split"===e&&!d){var m=/./[f],y=n(s,f,""[e],(function(e,t,n,r,o){return t.exec===l?p&&!o?{done:!0,value:m.call(t,n,r)}:{done:!0,value:e.call(n,t,r)}:{done:!1}})),g=y[0],v=y[1];r(String.prototype,e,g),o(RegExp.prototype,f,2==t?function(e,t){return v.call(e,this,t)}:function(e){return v.call(e,this)})}}},{"./_defined":17,"./_fails":24,"./_hide":31,"./_redefine":71,"./_regexp-exec":73,"./_wks":99,"./es6.regexp.exec":115}],26:[function(e,t,n){"use strict";var r=e("./_an-object");t.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},{"./_an-object":5}],27:[function(e,t,n){var r=e("./_ctx"),o=e("./_iter-call"),i=e("./_is-array-iter"),s=e("./_an-object"),a=e("./_to-length"),l=e("./core.get-iterator-method"),c={},u={};(n=t.exports=function(e,t,n,d,f){var p,h,m,y,g=f?function(){return e}:l(e),v=r(n,d,t?2:1),b=0;if("function"!=typeof g)throw TypeError(e+" is not iterable!");if(i(g)){for(p=a(e.length);b<p;b++)if((y=t?v(s(h=e[b])[0],h[1]):v(e[b]))===c||y===u)return y}else for(m=g.call(e);!(h=m.next()).done;)if((y=o(m,v,h.value,t))===c||y===u)return y}).BREAK=c,n.RETURN=u},{"./_an-object":5,"./_ctx":16,"./_is-array-iter":37,"./_iter-call":41,"./_to-length":89,"./core.get-iterator-method":100}],28:[function(e,t,n){t.exports=e("./_shared")("native-function-to-string",Function.toString)},{"./_shared":78}],29:[function(e,t,n){var r=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=r)},{}],30:[function(e,t,n){var r={}.hasOwnProperty;t.exports=function(e,t){return r.call(e,t)}},{}],31:[function(e,t,n){var r=e("./_object-dp"),o=e("./_property-desc");t.exports=e("./_descriptors")?function(e,t,n){return r.f(e,t,o(1,n))}:function(e,t,n){return e[t]=n,e}},{"./_descriptors":18,"./_object-dp":54,"./_property-desc":69}],32:[function(e,t,n){var r=e("./_global").document;t.exports=r&&r.documentElement},{"./_global":29}],33:[function(e,t,n){t.exports=!e("./_descriptors")&&!e("./_fails")((function(){return 7!=Object.defineProperty(e("./_dom-create")("div"),"a",{get:function(){return 7}}).a}))},{"./_descriptors":18,"./_dom-create":19,"./_fails":24}],34:[function(e,t,n){var r=e("./_is-object"),o=e("./_set-proto").set;t.exports=function(e,t,n){var i,s=t.constructor;return s!==n&&"function"==typeof s&&(i=s.prototype)!==n.prototype&&r(i)&&o&&o(e,i),e}},{"./_is-object":39,"./_set-proto":74}],35:[function(e,t,n){t.exports=function(e,t,n){var r=void 0===n;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},{}],36:[function(e,t,n){var r=e("./_cof");t.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},{"./_cof":13}],37:[function(e,t,n){var r=e("./_iterators"),o=e("./_wks")("iterator"),i=Array.prototype;t.exports=function(e){return void 0!==e&&(r.Array===e||i[o]===e)}},{"./_iterators":46,"./_wks":99}],38:[function(e,t,n){var r=e("./_cof");t.exports=Array.isArray||function(e){return"Array"==r(e)}},{"./_cof":13}],39:[function(e,t,n){t.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},{}],40:[function(e,t,n){var r=e("./_is-object"),o=e("./_cof"),i=e("./_wks")("match");t.exports=function(e){var t;return r(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==o(e))}},{"./_cof":13,"./_is-object":39,"./_wks":99}],41:[function(e,t,n){var r=e("./_an-object");t.exports=function(e,t,n,o){try{return o?t(r(n)[0],n[1]):t(n)}catch(t){var i=e.return;throw void 0!==i&&r(i.call(e)),t}}},{"./_an-object":5}],42:[function(e,t,n){"use strict";var r=e("./_object-create"),o=e("./_property-desc"),i=e("./_set-to-string-tag"),s={};e("./_hide")(s,e("./_wks")("iterator"),(function(){return this})),t.exports=function(e,t,n){e.prototype=r(s,{next:o(1,n)}),i(e,t+" Iterator")}},{"./_hide":31,"./_object-create":53,"./_property-desc":69,"./_set-to-string-tag":76,"./_wks":99}],43:[function(e,t,n){"use strict";function r(){return this}var o=e("./_library"),i=e("./_export"),s=e("./_redefine"),a=e("./_hide"),l=e("./_iterators"),c=e("./_iter-create"),u=e("./_set-to-string-tag"),d=e("./_object-gpo"),f=e("./_wks")("iterator"),p=!([].keys&&"next"in[].keys()),h="values";t.exports=function(e,t,n,m,y,g,v){function b(e){if(!p&&e in E)return E[e];switch(e){case"keys":case h:return function(){return new n(this,e)}}return function(){return new n(this,e)}}c(n,t,m);var _,w,x,k=t+" Iterator",j=y==h,C=!1,E=e.prototype,D=E[f]||E["@@iterator"]||y&&E[y],S=D||b(y),O=y?j?b("entries"):S:void 0,P="Array"==t&&E.entries||D;if(P&&(x=d(P.call(new e)))!==Object.prototype&&x.next&&(u(x,k,!0),o||"function"==typeof x[f]||a(x,f,r)),j&&D&&D.name!==h&&(C=!0,S=function(){return D.call(this)}),o&&!v||!p&&!C&&E[f]||a(E,f,S),l[t]=S,l[k]=r,y)if(_={values:j?S:b(h),keys:g?S:b("keys"),entries:O},v)for(w in _)w in E||s(E,w,_[w]);else i(i.P+i.F*(p||C),t,_);return _}},{"./_export":22,"./_hide":31,"./_iter-create":42,"./_iterators":46,"./_library":47,"./_object-gpo":60,"./_redefine":71,"./_set-to-string-tag":76,"./_wks":99}],44:[function(e,t,n){var r=e("./_wks")("iterator"),o=!1;try{var i=[7][r]();i.return=function(){o=!0},Array.from(i,(function(){throw 2}))}catch(e){}t.exports=function(e,t){if(!t&&!o)return!1;var n=!1;try{var i=[7],s=i[r]();s.next=function(){return{done:n=!0}},i[r]=function(){return s},e(i)}catch(e){}return n}},{"./_wks":99}],45:[function(e,t,n){t.exports=function(e,t){return{value:t,done:!!e}}},{}],46:[function(e,t,n){t.exports={}},{}],47:[function(e,t,n){t.exports=!1},{}],48:[function(e,t,n){var r=e("./_math-sign"),o=Math.pow,i=o(2,-52),s=o(2,-23),a=o(2,127)*(2-s),l=o(2,-126);t.exports=Math.fround||function(e){var t,n,o=Math.abs(e),c=r(e);return o<l?c*(o/l/s+1/i-1/i)*l*s:a<(n=(t=(1+s/i)*o)-(t-o))||n!=n?c*(1/0):c*n}},{"./_math-sign":49}],49:[function(e,t,n){t.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},{}],50:[function(e,t,n){function r(e){a(e,o,{value:{i:"O"+ ++l,w:{}}})}var o=e("./_uid")("meta"),i=e("./_is-object"),s=e("./_has"),a=e("./_object-dp").f,l=0,c=Object.isExtensible||function(){return!0},u=!e("./_fails")((function(){return c(Object.preventExtensions({}))})),d=t.exports={KEY:o,NEED:!1,fastKey:function(e,t){if(!i(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!s(e,o)){if(!c(e))return"F";if(!t)return"E";r(e)}return e[o].i},getWeak:function(e,t){if(!s(e,o)){if(!c(e))return!0;if(!t)return!1;r(e)}return e[o].w},onFreeze:function(e){return u&&d.NEED&&c(e)&&!s(e,o)&&r(e),e}}},{"./_fails":24,"./_has":30,"./_is-object":39,"./_object-dp":54,"./_uid":95}],51:[function(e,t,n){var r=e("./_global"),o=e("./_task").set,i=r.MutationObserver||r.WebKitMutationObserver,s=r.process,a=r.Promise,l="process"==e("./_cof")(s);t.exports=function(){function e(){var e,r;for(l&&(e=s.domain)&&e.exit();t;){r=t.fn,t=t.next;try{r()}catch(e){throw t?c():n=void 0,e}}n=void 0,e&&e.enter()}var t,n,c;if(l)c=function(){s.nextTick(e)};else if(!i||r.navigator&&r.navigator.standalone)if(a&&a.resolve){var u=a.resolve(void 0);c=function(){u.then(e)}}else c=function(){o.call(r,e)};else{var d=!0,f=document.createTextNode("");new i(e).observe(f,{characterData:!0}),c=function(){f.data=d=!d}}return function(e){var r={fn:e,next:void 0};n&&(n.next=r),t||(t=r,c()),n=r}}},{"./_cof":13,"./_global":29,"./_task":84}],52:[function(e,t,n){"use strict";var r=e("./_a-function");function o(e){var t,n;this.promise=new e((function(e,r){if(void 0!==t||void 0!==n)throw TypeError("Bad Promise constructor");t=e,n=r})),this.resolve=r(t),this.reject=r(n)}t.exports.f=function(e){return new o(e)}},{"./_a-function":1}],53:[function(e,t,n){function r(){}var o=e("./_an-object"),i=e("./_object-dps"),s=e("./_enum-bug-keys"),a=e("./_shared-key")("IE_PROTO"),l="prototype",c=function(){var t,n=e("./_dom-create")("iframe"),r=s.length;for(n.style.display="none",e("./_html").appendChild(n),n.src="javascript:",(t=n.contentWindow.document).open(),t.write("<script>document.F=Object<\/script>"),t.close(),c=t.F;r--;)delete c[l][s[r]];return c()};t.exports=Object.create||function(e,t){var n;return null!==e?(r[l]=o(e),n=new r,r[l]=null,n[a]=e):n=c(),void 0===t?n:i(n,t)}},{"./_an-object":5,"./_dom-create":19,"./_enum-bug-keys":20,"./_html":32,"./_object-dps":55,"./_shared-key":77}],54:[function(e,t,n){var r=e("./_an-object"),o=e("./_ie8-dom-define"),i=e("./_to-primitive"),s=Object.defineProperty;n.f=e("./_descriptors")?Object.defineProperty:function(e,t,n){if(r(e),t=i(t,!0),r(n),o)try{return s(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},{"./_an-object":5,"./_descriptors":18,"./_ie8-dom-define":33,"./_to-primitive":91}],55:[function(e,t,n){var r=e("./_object-dp"),o=e("./_an-object"),i=e("./_object-keys");t.exports=e("./_descriptors")?Object.defineProperties:function(e,t){o(e);for(var n,s=i(t),a=s.length,l=0;l<a;)r.f(e,n=s[l++],t[n]);return e}},{"./_an-object":5,"./_descriptors":18,"./_object-dp":54,"./_object-keys":62}],56:[function(e,t,n){var r=e("./_object-pie"),o=e("./_property-desc"),i=e("./_to-iobject"),s=e("./_to-primitive"),a=e("./_has"),l=e("./_ie8-dom-define"),c=Object.getOwnPropertyDescriptor;n.f=e("./_descriptors")?c:function(e,t){if(e=i(e),t=s(t,!0),l)try{return c(e,t)}catch(e){}if(a(e,t))return o(!r.f.call(e,t),e[t])}},{"./_descriptors":18,"./_has":30,"./_ie8-dom-define":33,"./_object-pie":63,"./_property-desc":69,"./_to-iobject":88,"./_to-primitive":91}],57:[function(e,t,n){var r=e("./_to-iobject"),o=e("./_object-gopn").f,i={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];t.exports.f=function(e){return s&&"[object Window]"==i.call(e)?function(e){try{return o(e)}catch(e){return s.slice()}}(e):o(r(e))}},{"./_object-gopn":58,"./_to-iobject":88}],58:[function(e,t,n){var r=e("./_object-keys-internal"),o=e("./_enum-bug-keys").concat("length","prototype");n.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},{"./_enum-bug-keys":20,"./_object-keys-internal":61}],59:[function(e,t,n){n.f=Object.getOwnPropertySymbols},{}],60:[function(e,t,n){var r=e("./_has"),o=e("./_to-object"),i=e("./_shared-key")("IE_PROTO"),s=Object.prototype;t.exports=Object.getPrototypeOf||function(e){return e=o(e),r(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?s:null}},{"./_has":30,"./_shared-key":77,"./_to-object":90}],61:[function(e,t,n){var r=e("./_has"),o=e("./_to-iobject"),i=e("./_array-includes")(!1),s=e("./_shared-key")("IE_PROTO");t.exports=function(e,t){var n,a=o(e),l=0,c=[];for(n in a)n!=s&&r(a,n)&&c.push(n);for(;t.length>l;)r(a,n=t[l++])&&(~i(c,n)||c.push(n));return c}},{"./_array-includes":8,"./_has":30,"./_shared-key":77,"./_to-iobject":88}],62:[function(e,t,n){var r=e("./_object-keys-internal"),o=e("./_enum-bug-keys");t.exports=Object.keys||function(e){return r(e,o)}},{"./_enum-bug-keys":20,"./_object-keys-internal":61}],63:[function(e,t,n){n.f={}.propertyIsEnumerable},{}],64:[function(e,t,n){var r=e("./_export"),o=e("./_core"),i=e("./_fails");t.exports=function(e,t){var n=(o.Object||{})[e]||Object[e],s={};s[e]=t(n),r(r.S+r.F*i((function(){n(1)})),"Object",s)}},{"./_core":14,"./_export":22,"./_fails":24}],65:[function(e,t,n){var r=e("./_object-gopn"),o=e("./_object-gops"),i=e("./_an-object"),s=e("./_global").Reflect;t.exports=s&&s.ownKeys||function(e){var t=r.f(i(e)),n=o.f;return n?t.concat(n(e)):t}},{"./_an-object":5,"./_global":29,"./_object-gopn":58,"./_object-gops":59}],66:[function(e,t,n){var r=e("./_global").parseInt,o=e("./_string-trim").trim,i=e("./_string-ws"),s=/^[-+]?0[xX]/;t.exports=8!==r(i+"08")||22!==r(i+"0x16")?function(e,t){var n=o(String(e),3);return r(n,t>>>0||(s.test(n)?16:10))}:r},{"./_global":29,"./_string-trim":82,"./_string-ws":83}],67:[function(e,t,n){t.exports=function(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}}},{}],68:[function(e,t,n){var r=e("./_an-object"),o=e("./_is-object"),i=e("./_new-promise-capability");t.exports=function(e,t){if(r(e),o(t)&&t.constructor===e)return t;var n=i.f(e);return(0,n.resolve)(t),n.promise}},{"./_an-object":5,"./_is-object":39,"./_new-promise-capability":52}],69:[function(e,t,n){t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},{}],70:[function(e,t,n){var r=e("./_redefine");t.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},{"./_redefine":71}],71:[function(e,t,n){var r=e("./_global"),o=e("./_hide"),i=e("./_has"),s=e("./_uid")("src"),a=e("./_function-to-string"),l="toString",c=(""+a).split(l);e("./_core").inspectSource=function(e){return a.call(e)},(t.exports=function(e,t,n,a){var l="function"==typeof n;l&&(i(n,"name")||o(n,"name",t)),e[t]!==n&&(l&&(i(n,s)||o(n,s,e[t]?""+e[t]:c.join(String(t)))),e===r?e[t]=n:a?e[t]?e[t]=n:o(e,t,n):(delete e[t],o(e,t,n)))})(Function.prototype,l,(function(){return"function"==typeof this&&this[s]||a.call(this)}))},{"./_core":14,"./_function-to-string":28,"./_global":29,"./_has":30,"./_hide":31,"./_uid":95}],72:[function(e,t,n){"use strict";var r=e("./_classof"),o=RegExp.prototype.exec;t.exports=function(e,t){var n=e.exec;if("function"==typeof n){var i=n.call(e,t);if("object"!=typeof i)throw new TypeError("RegExp exec method returned something other than an Object or null");return i}if("RegExp"!==r(e))throw new TypeError("RegExp#exec called on incompatible receiver");return o.call(e,t)}},{"./_classof":12}],73:[function(e,t,n){"use strict";var r,o,i=e("./_flags"),s=RegExp.prototype.exec,a=String.prototype.replace,l=s,c="lastIndex",u=(r=/a/,o=/b*/g,s.call(r,"a"),s.call(o,"a"),0!==r[c]||0!==o[c]),d=void 0!==/()??/.exec("")[1];(u||d)&&(l=function(e){var t,n,r,o,l=this;return d&&(n=new RegExp("^"+l.source+"$(?!\\s)",i.call(l))),u&&(t=l[c]),r=s.call(l,e),u&&r&&(l[c]=l.global?r.index+r[0].length:t),d&&r&&1<r.length&&a.call(r[0],n,(function(){for(o=1;o<arguments.length-2;o++)void 0===arguments[o]&&(r[o]=void 0)})),r}),t.exports=l},{"./_flags":26}],74:[function(e,t,n){function r(e,t){if(i(e),!o(t)&&null!==t)throw TypeError(t+": can't set as prototype!")}var o=e("./_is-object"),i=e("./_an-object");t.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(t,n,o){try{(o=e("./_ctx")(Function.call,e("./_object-gopd").f(Object.prototype,"__proto__").set,2))(t,[]),n=!(t instanceof Array)}catch(t){n=!0}return function(e,t){return r(e,t),n?e.__proto__=t:o(e,t),e}}({},!1):void 0),check:r}},{"./_an-object":5,"./_ctx":16,"./_is-object":39,"./_object-gopd":56}],75:[function(e,t,n){"use strict";var r=e("./_global"),o=e("./_object-dp"),i=e("./_descriptors"),s=e("./_wks")("species");t.exports=function(e){var t=r[e];i&&t&&!t[s]&&o.f(t,s,{configurable:!0,get:function(){return this}})}},{"./_descriptors":18,"./_global":29,"./_object-dp":54,"./_wks":99}],76:[function(e,t,n){var r=e("./_object-dp").f,o=e("./_has"),i=e("./_wks")("toStringTag");t.exports=function(e,t,n){e&&!o(e=n?e:e.prototype,i)&&r(e,i,{configurable:!0,value:t})}},{"./_has":30,"./_object-dp":54,"./_wks":99}],77:[function(e,t,n){var r=e("./_shared")("keys"),o=e("./_uid");t.exports=function(e){return r[e]||(r[e]=o(e))}},{"./_shared":78,"./_uid":95}],78:[function(e,t,n){var r=e("./_core"),o=e("./_global"),i="__core-js_shared__",s=o[i]||(o[i]={});(t.exports=function(e,t){return s[e]||(s[e]=void 0!==t?t:{})})("versions",[]).push({version:r.version,mode:e("./_library")?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},{"./_core":14,"./_global":29,"./_library":47}],79:[function(e,t,n){var r=e("./_an-object"),o=e("./_a-function"),i=e("./_wks")("species");t.exports=function(e,t){var n,s=r(e).constructor;return void 0===s||null==(n=r(s)[i])?t:o(n)}},{"./_a-function":1,"./_an-object":5,"./_wks":99}],80:[function(e,t,n){var r=e("./_to-integer"),o=e("./_defined");t.exports=function(e){return function(t,n){var i,s,a=String(o(t)),l=r(n),c=a.length;return l<0||c<=l?e?"":void 0:(i=a.charCodeAt(l))<55296||56319<i||l+1===c||(s=a.charCodeAt(l+1))<56320||57343<s?e?a.charAt(l):i:e?a.slice(l,l+2):s-56320+(i-55296<<10)+65536}}},{"./_defined":17,"./_to-integer":87}],81:[function(e,t,n){var r=e("./_is-regexp"),o=e("./_defined");t.exports=function(e,t,n){if(r(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(o(e))}},{"./_defined":17,"./_is-regexp":40}],82:[function(e,t,n){function r(e,t,n){var r={},i=s((function(){return!!a[e]()||"​…"!="​…"[e]()})),l=r[e]=i?t(d):a[e];n&&(r[n]=l),o(o.P+o.F*i,"String",r)}var o=e("./_export"),i=e("./_defined"),s=e("./_fails"),a=e("./_string-ws"),l="["+a+"]",c=RegExp("^"+l+l+"*"),u=RegExp(l+l+"*$"),d=r.trim=function(e,t){return e=String(i(e)),1&t&&(e=e.replace(c,"")),2&t&&(e=e.replace(u,"")),e};t.exports=r},{"./_defined":17,"./_export":22,"./_fails":24,"./_string-ws":83}],83:[function(e,t,n){t.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"},{}],84:[function(e,t,n){function r(){var e=+this;if(b.hasOwnProperty(e)){var t=b[e];delete b[e],t()}}function o(e){r.call(e.data)}var i,s,a,l=e("./_ctx"),c=e("./_invoke"),u=e("./_html"),d=e("./_dom-create"),f=e("./_global"),p=f.process,h=f.setImmediate,m=f.clearImmediate,y=f.MessageChannel,g=f.Dispatch,v=0,b={},_="onreadystatechange";h&&m||(h=function(e){for(var t=[],n=1;n<arguments.length;)t.push(arguments[n++]);return b[++v]=function(){c("function"==typeof e?e:Function(e),t)},i(v),v},m=function(e){delete b[e]},"process"==e("./_cof")(p)?i=function(e){p.nextTick(l(r,e,1))}:g&&g.now?i=function(e){g.now(l(r,e,1))}:y?(a=(s=new y).port2,s.port1.onmessage=o,i=l(a.postMessage,a,1)):f.addEventListener&&"function"==typeof postMessage&&!f.importScripts?(i=function(e){f.postMessage(e+"","*")},f.addEventListener("message",o,!1)):i=_ in d("script")?function(e){u.appendChild(d("script"))[_]=function(){u.removeChild(this),r.call(e)}}:function(e){setTimeout(l(r,e,1),0)}),t.exports={set:h,clear:m}},{"./_cof":13,"./_ctx":16,"./_dom-create":19,"./_global":29,"./_html":32,"./_invoke":35}],85:[function(e,t,n){var r=e("./_to-integer"),o=Math.max,i=Math.min;t.exports=function(e,t){return(e=r(e))<0?o(e+t,0):i(e,t)}},{"./_to-integer":87}],86:[function(e,t,n){var r=e("./_to-integer"),o=e("./_to-length");t.exports=function(e){if(void 0===e)return 0;var t=r(e),n=o(t);if(t!==n)throw RangeError("Wrong length!");return n}},{"./_to-integer":87,"./_to-length":89}],87:[function(e,t,n){var r=Math.ceil,o=Math.floor;t.exports=function(e){return isNaN(e=+e)?0:(0<e?o:r)(e)}},{}],88:[function(e,t,n){var r=e("./_iobject"),o=e("./_defined");t.exports=function(e){return r(o(e))}},{"./_defined":17,"./_iobject":36}],89:[function(e,t,n){var r=e("./_to-integer"),o=Math.min;t.exports=function(e){return 0<e?o(r(e),9007199254740991):0}},{"./_to-integer":87}],90:[function(e,t,n){var r=e("./_defined");t.exports=function(e){return Object(r(e))}},{"./_defined":17}],91:[function(e,t,n){var r=e("./_is-object");t.exports=function(e,t){if(!r(e))return e;var n,o;if(t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;if("function"==typeof(n=e.valueOf)&&!r(o=n.call(e)))return o;if(!t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;throw TypeError("Can't convert object to primitive value")}},{"./_is-object":39}],92:[function(e,t,n){"use strict";if(e("./_descriptors")){var r=e("./_library"),o=e("./_global"),i=e("./_fails"),s=e("./_export"),a=e("./_typed"),l=e("./_typed-buffer"),c=e("./_ctx"),u=e("./_an-instance"),d=e("./_property-desc"),f=e("./_hide"),p=e("./_redefine-all"),h=e("./_to-integer"),m=e("./_to-length"),y=e("./_to-index"),g=e("./_to-absolute-index"),v=e("./_to-primitive"),b=e("./_has"),_=e("./_classof"),w=e("./_is-object"),x=e("./_to-object"),k=e("./_is-array-iter"),j=e("./_object-create"),C=e("./_object-gpo"),E=e("./_object-gopn").f,D=e("./core.get-iterator-method"),S=e("./_uid"),O=e("./_wks"),P=e("./_array-methods"),B=e("./_array-includes"),M=e("./_species-constructor"),T=e("./es6.array.iterator"),A=e("./_iterators"),I=e("./_iter-detect"),K=e("./_set-species"),L=e("./_array-fill"),R=e("./_array-copy-within"),N=e("./_object-dp"),F=e("./_object-gopd"),U=N.f,z=F.f,H=o.RangeError,W=o.TypeError,q=o.Uint8Array,V="ArrayBuffer",G="Shared"+V,Y="BYTES_PER_ELEMENT",X="prototype",$=Array[X],J=l.ArrayBuffer,Q=l.DataView,Z=P(0),ee=P(2),te=P(3),ne=P(4),re=P(5),oe=P(6),ie=B(!0),se=B(!1),ae=T.values,le=T.keys,ce=T.entries,ue=$.lastIndexOf,de=$.reduce,fe=$.reduceRight,pe=$.join,he=$.sort,me=$.slice,ye=$.toString,ge=$.toLocaleString,ve=O("iterator"),be=O("toStringTag"),_e=S("typed_constructor"),we=S("def_constructor"),xe=a.CONSTR,ke=a.TYPED,je=a.VIEW,Ce="Wrong length!",Ee=P(1,(function(e,t){return Be(M(e,e[we]),t)})),De=i((function(){return 1===new q(new Uint16Array([1]).buffer)[0]})),Se=!!q&&!!q[X].set&&i((function(){new q(1).set({})})),Oe=function(e,t){var n=h(e);if(n<0||n%t)throw H("Wrong offset!");return n},Pe=function(e){if(w(e)&&ke in e)return e;throw W(e+" is not a typed array!")},Be=function(e,t){if(!w(e)||!(_e in e))throw W("It is not a typed array constructor!");return new e(t)},Me=function(e,t){return Te(M(e,e[we]),t)},Te=function(e,t){for(var n=0,r=t.length,o=Be(e,r);n<r;)o[n]=t[n++];return o},Ae=function(e,t,n){U(e,t,{get:function(){return this._d[n]}})},Ie=function(e,t,n){var r,o,i,s,a,l,u=x(e),d=arguments.length,f=1<d?t:void 0,p=void 0!==f,h=D(u);if(null!=h&&!k(h)){for(l=h.call(u),i=[],r=0;!(a=l.next()).done;r++)i.push(a.value);u=i}for(p&&2<d&&(f=c(f,n,2)),r=0,o=m(u.length),s=Be(this,o);r<o;r++)s[r]=p?f(u[r],r):u[r];return s},Ke=function(){for(var e=0,t=arguments.length,n=Be(this,t);e<t;)n[e]=arguments[e++];return n},Le=!!q&&i((function(){ge.call(new q(1))})),Re=function(){return ge.apply(Le?me.call(Pe(this)):Pe(this),arguments)},Ne={copyWithin:function(e,t,n){return R.call(Pe(this),e,t,2<arguments.length?n:void 0)},every:function(e,t){return ne(Pe(this),e,1<arguments.length?t:void 0)},fill:function(e){return L.apply(Pe(this),arguments)},filter:function(e,t){return Me(this,ee(Pe(this),e,1<arguments.length?t:void 0))},find:function(e,t){return re(Pe(this),e,1<arguments.length?t:void 0)},findIndex:function(e,t){return oe(Pe(this),e,1<arguments.length?t:void 0)},forEach:function(e,t){Z(Pe(this),e,1<arguments.length?t:void 0)},indexOf:function(e,t){return se(Pe(this),e,1<arguments.length?t:void 0)},includes:function(e,t){return ie(Pe(this),e,1<arguments.length?t:void 0)},join:function(e){return pe.apply(Pe(this),arguments)},lastIndexOf:function(e){return ue.apply(Pe(this),arguments)},map:function(e,t){return Ee(Pe(this),e,1<arguments.length?t:void 0)},reduce:function(e){return de.apply(Pe(this),arguments)},reduceRight:function(e){return fe.apply(Pe(this),arguments)},reverse:function(){for(var e,t=this,n=Pe(t).length,r=Math.floor(n/2),o=0;o<r;)e=t[o],t[o++]=t[--n],t[n]=e;return t},some:function(e,t){return te(Pe(this),e,1<arguments.length?t:void 0)},sort:function(e){return he.call(Pe(this),e)},subarray:function(e,t){var n=Pe(this),r=n.length,o=g(e,r);return new(M(n,n[we]))(n.buffer,n.byteOffset+o*n.BYTES_PER_ELEMENT,m((void 0===t?r:g(t,r))-o))}},Fe=function(e,t){return Me(this,me.call(Pe(this),e,t))},Ue=function(e,t){Pe(this);var n=Oe(t,1),r=this.length,o=x(e),i=m(o.length),s=0;if(r<i+n)throw H(Ce);for(;s<i;)this[n+s]=o[s++]},ze={entries:function(){return ce.call(Pe(this))},keys:function(){return le.call(Pe(this))},values:function(){return ae.call(Pe(this))}},He=function(e,t){return w(e)&&e[ke]&&"symbol"!=typeof t&&t in e&&String(+t)==String(t)},We=function(e,t){return He(e,t=v(t,!0))?d(2,e[t]):z(e,t)},qe=function(e,t,n){return!(He(e,t=v(t,!0))&&w(n)&&b(n,"value"))||b(n,"get")||b(n,"set")||n.configurable||b(n,"writable")&&!n.writable||b(n,"enumerable")&&!n.enumerable?U(e,t,n):(e[t]=n.value,e)};xe||(F.f=We,N.f=qe),s(s.S+s.F*!xe,"Object",{getOwnPropertyDescriptor:We,defineProperty:qe}),i((function(){ye.call({})}))&&(ye=ge=function(){return pe.call(this)});var Ve=p({},Ne);p(Ve,ze),f(Ve,ve,ze.values),p(Ve,{slice:Fe,set:Ue,constructor:function(){},toString:ye,toLocaleString:Re}),Ae(Ve,"buffer","b"),Ae(Ve,"byteOffset","o"),Ae(Ve,"byteLength","l"),Ae(Ve,"length","e"),U(Ve,be,{get:function(){return this[ke]}}),t.exports=function(e,t,n,l){function c(e,n){U(e,n,{get:function(){return e=n,(r=this._d).v[p](e*t+r.o,De);var e,r},set:function(e){return r=n,o=e,i=this._d,l&&(o=(o=Math.round(o))<0?0:255<o?255:255&o),void i.v[h](r*t+i.o,o,De);var r,o,i},enumerable:!0})}var d=e+((l=!!l)?"Clamped":"")+"Array",p="get"+e,h="set"+e,g=o[d],v=g||{},b=g&&C(g),x=!g||!a.ABV,k={},D=g&&g[X];x?(g=n((function(e,n,r,o){u(e,g,d,"_d");var i,s,a,l,p=0,h=0;if(w(n)){if(!(n instanceof J||(l=_(n))==V||l==G))return ke in n?Te(g,n):Ie.call(g,n);i=n,h=Oe(r,t);var v=n.byteLength;if(void 0===o){if(v%t)throw H(Ce);if((s=v-h)<0)throw H(Ce)}else if(v<(s=m(o)*t)+h)throw H(Ce);a=s/t}else a=y(n),i=new J(s=a*t);for(f(e,"_d",{b:i,o:h,l:s,e:a,v:new Q(i)});p<a;)c(e,p++)})),D=g[X]=j(Ve),f(D,"constructor",g)):i((function(){g(1)}))&&i((function(){new g(-1)}))&&I((function(e){new g,new g(null),new g(1.5),new g(e)}),!0)||(g=n((function(e,n,r,o){var i;return u(e,g,d),w(n)?n instanceof J||(i=_(n))==V||i==G?void 0!==o?new v(n,Oe(r,t),o):void 0!==r?new v(n,Oe(r,t)):new v(n):ke in n?Te(g,n):Ie.call(g,n):new v(y(n))})),Z(b!==Function.prototype?E(v).concat(E(b)):E(v),(function(e){e in g||f(g,e,v[e])})),g[X]=D,r||(D.constructor=g));var S=D[ve],O=!!S&&("values"==S.name||null==S.name),P=ze.values;f(g,_e,!0),f(D,ke,d),f(D,je,!0),f(D,we,g),(l?new g(1)[be]==d:be in D)||U(D,be,{get:function(){return d}}),k[d]=g,s(s.G+s.W+s.F*(g!=v),k),s(s.S,d,{BYTES_PER_ELEMENT:t}),s(s.S+s.F*i((function(){v.of.call(g,1)})),d,{from:Ie,of:Ke}),Y in D||f(D,Y,t),s(s.P,d,Ne),K(d),s(s.P+s.F*Se,d,{set:Ue}),s(s.P+s.F*!O,d,ze),r||D.toString==ye||(D.toString=ye),s(s.P+s.F*i((function(){new g(1).slice()})),d,{slice:Fe}),s(s.P+s.F*(i((function(){return[1,2].toLocaleString()!=new g([1,2]).toLocaleString()}))||!i((function(){D.toLocaleString.call([1,2])}))),d,{toLocaleString:Re}),A[d]=O?S:P,r||O||f(D,ve,P)}}else t.exports=function(){}},{"./_an-instance":4,"./_array-copy-within":6,"./_array-fill":7,"./_array-includes":8,"./_array-methods":9,"./_classof":12,"./_ctx":16,"./_descriptors":18,"./_export":22,"./_fails":24,"./_global":29,"./_has":30,"./_hide":31,"./_is-array-iter":37,"./_is-object":39,"./_iter-detect":44,"./_iterators":46,"./_library":47,"./_object-create":53,"./_object-dp":54,"./_object-gopd":56,"./_object-gopn":58,"./_object-gpo":60,"./_property-desc":69,"./_redefine-all":70,"./_set-species":75,"./_species-constructor":79,"./_to-absolute-index":85,"./_to-index":86,"./_to-integer":87,"./_to-length":89,"./_to-object":90,"./_to-primitive":91,"./_typed":94,"./_typed-buffer":93,"./_uid":95,"./_wks":99,"./core.get-iterator-method":100,"./es6.array.iterator":103}],93:[function(e,t,n){"use strict";var r=e("./_global"),o=e("./_descriptors"),i=e("./_library"),s=e("./_typed"),a=e("./_hide"),l=e("./_redefine-all"),c=e("./_fails"),u=e("./_an-instance"),d=e("./_to-integer"),f=e("./_to-length"),p=e("./_to-index"),h=e("./_object-gopn").f,m=e("./_object-dp").f,y=e("./_array-fill"),g=e("./_set-to-string-tag"),v="ArrayBuffer",b="DataView",_="prototype",w="Wrong index!",x=r[v],k=r[b],j=r.Math,C=r.RangeError,E=r.Infinity,D=x,S=j.abs,O=j.pow,P=j.floor,B=j.log,M=j.LN2,T="byteLength",A="byteOffset",I=o?"_b":"buffer",K=o?"_l":T,L=o?"_o":A;function R(e,t,n){var r,o,i,s=new Array(n),a=8*n-t-1,l=(1<<a)-1,c=l>>1,u=23===t?O(2,-24)-O(2,-77):0,d=0,f=e<0||0===e&&1/e<0?1:0;for((e=S(e))!=e||e===E?(o=e!=e?1:0,r=l):(r=P(B(e)/M),e*(i=O(2,-r))<1&&(r--,i*=2),2<=(e+=1<=r+c?u/i:u*O(2,1-c))*i&&(r++,i/=2),l<=r+c?(o=0,r=l):1<=r+c?(o=(e*i-1)*O(2,t),r+=c):(o=e*O(2,c-1)*O(2,t),r=0));8<=t;s[d++]=255&o,o/=256,t-=8);for(r=r<<t|o,a+=t;0<a;s[d++]=255&r,r/=256,a-=8);return s[--d]|=128*f,s}function N(e,t,n){var r,o=8*n-t-1,i=(1<<o)-1,s=i>>1,a=o-7,l=n-1,c=e[l--],u=127&c;for(c>>=7;0<a;u=256*u+e[l],l--,a-=8);for(r=u&(1<<-a)-1,u>>=-a,a+=t;0<a;r=256*r+e[l],l--,a-=8);if(0===u)u=1-s;else{if(u===i)return r?NaN:c?-E:E;r+=O(2,t),u-=s}return(c?-1:1)*r*O(2,u-t)}function F(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]}function U(e){return[255&e]}function z(e){return[255&e,e>>8&255]}function H(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]}function W(e){return R(e,52,8)}function q(e){return R(e,23,4)}function V(e,t,n){m(e[_],t,{get:function(){return this[n]}})}function G(e,t,n,r){var o=p(+n);if(o+t>e[K])throw C(w);var i=e[I]._b,s=o+e[L],a=i.slice(s,s+t);return r?a:a.reverse()}function Y(e,t,n,r,o,i){var s=p(+n);if(s+t>e[K])throw C(w);for(var a=e[I]._b,l=s+e[L],c=r(+o),u=0;u<t;u++)a[l+u]=c[i?u:t-u-1]}if(s.ABV){if(!c((function(){x(1)}))||!c((function(){new x(-1)}))||c((function(){return new x,new x(1.5),new x(NaN),x.name!=v}))){for(var X,$=(x=function(e){return u(this,x),new D(p(e))})[_]=D[_],J=h(D),Q=0;J.length>Q;)(X=J[Q++])in x||a(x,X,D[X]);i||($.constructor=x)}var Z=new k(new x(2)),ee=k[_].setInt8;Z.setInt8(0,2147483648),Z.setInt8(1,2147483649),!Z.getInt8(0)&&Z.getInt8(1)||l(k[_],{setInt8:function(e,t){ee.call(this,e,t<<24>>24)},setUint8:function(e,t){ee.call(this,e,t<<24>>24)}},!0)}else x=function(e){u(this,x,v);var t=p(e);this._b=y.call(new Array(t),0),this[K]=t},k=function(e,t,n){u(this,k,b),u(e,x,b);var r=e[K],o=d(t);if(o<0||r<o)throw C("Wrong offset!");if(r<o+(n=void 0===n?r-o:f(n)))throw C("Wrong length!");this[I]=e,this[L]=o,this[K]=n},o&&(V(x,T,"_l"),V(k,"buffer","_b"),V(k,T,"_l"),V(k,A,"_o")),l(k[_],{getInt8:function(e){return G(this,1,e)[0]<<24>>24},getUint8:function(e){return G(this,1,e)[0]},getInt16:function(e,t){var n=G(this,2,e,t);return(n[1]<<8|n[0])<<16>>16},getUint16:function(e,t){var n=G(this,2,e,t);return n[1]<<8|n[0]},getInt32:function(e,t){return F(G(this,4,e,t))},getUint32:function(e,t){return F(G(this,4,e,t))>>>0},getFloat32:function(e,t){return N(G(this,4,e,t),23,4)},getFloat64:function(e,t){return N(G(this,8,e,t),52,8)},setInt8:function(e,t){Y(this,1,e,U,t)},setUint8:function(e,t){Y(this,1,e,U,t)},setInt16:function(e,t,n){Y(this,2,e,z,t,n)},setUint16:function(e,t,n){Y(this,2,e,z,t,n)},setInt32:function(e,t,n){Y(this,4,e,H,t,n)},setUint32:function(e,t,n){Y(this,4,e,H,t,n)},setFloat32:function(e,t,n){Y(this,4,e,q,t,n)},setFloat64:function(e,t,n){Y(this,8,e,W,t,n)}});g(x,v),g(k,b),a(k[_],s.VIEW,!0),n[v]=x,n[b]=k},{"./_an-instance":4,"./_array-fill":7,"./_descriptors":18,"./_fails":24,"./_global":29,"./_hide":31,"./_library":47,"./_object-dp":54,"./_object-gopn":58,"./_redefine-all":70,"./_set-to-string-tag":76,"./_to-index":86,"./_to-integer":87,"./_to-length":89,"./_typed":94}],94:[function(e,t,n){for(var r,o=e("./_global"),i=e("./_hide"),s=e("./_uid"),a=s("typed_array"),l=s("view"),c=!(!o.ArrayBuffer||!o.DataView),u=c,d=0,f="Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array".split(",");d<9;)(r=o[f[d++]])?(i(r.prototype,a,!0),i(r.prototype,l,!0)):u=!1;t.exports={ABV:c,CONSTR:u,TYPED:a,VIEW:l}},{"./_global":29,"./_hide":31,"./_uid":95}],95:[function(e,t,n){var r=0,o=Math.random();t.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++r+o).toString(36))}},{}],96:[function(e,t,n){var r=e("./_global").navigator;t.exports=r&&r.userAgent||""},{"./_global":29}],97:[function(e,t,n){var r=e("./_global"),o=e("./_core"),i=e("./_library"),s=e("./_wks-ext"),a=e("./_object-dp").f;t.exports=function(e){var t=o.Symbol||(o.Symbol=!i&&r.Symbol||{});"_"==e.charAt(0)||e in t||a(t,e,{value:s.f(e)})}},{"./_core":14,"./_global":29,"./_library":47,"./_object-dp":54,"./_wks-ext":98}],98:[function(e,t,n){n.f=e("./_wks")},{"./_wks":99}],99:[function(e,t,n){var r=e("./_shared")("wks"),o=e("./_uid"),i=e("./_global").Symbol,s="function"==typeof i;(t.exports=function(e){return r[e]||(r[e]=s&&i[e]||(s?i:o)("Symbol."+e))}).store=r},{"./_global":29,"./_shared":78,"./_uid":95}],100:[function(e,t,n){var r=e("./_classof"),o=e("./_wks")("iterator"),i=e("./_iterators");t.exports=e("./_core").getIteratorMethod=function(e){if(null!=e)return e[o]||e["@@iterator"]||i[r(e)]}},{"./_classof":12,"./_core":14,"./_iterators":46,"./_wks":99}],101:[function(e,t,n){"use strict";var r=e("./_export"),o=e("./_array-methods")(5),i="find",s=!0;i in[]&&Array(1)[i]((function(){s=!1})),r(r.P+r.F*s,"Array",{find:function(e,t){return o(this,e,1<arguments.length?t:void 0)}}),e("./_add-to-unscopables")(i)},{"./_add-to-unscopables":2,"./_array-methods":9,"./_export":22}],102:[function(e,t,n){"use strict";var r=e("./_ctx"),o=e("./_export"),i=e("./_to-object"),s=e("./_iter-call"),a=e("./_is-array-iter"),l=e("./_to-length"),c=e("./_create-property"),u=e("./core.get-iterator-method");o(o.S+o.F*!e("./_iter-detect")((function(e){Array.from(e)})),"Array",{from:function(e,t,n){var o,d,f,p,h=i(e),m="function"==typeof this?this:Array,y=arguments.length,g=1<y?t:void 0,v=void 0!==g,b=0,_=u(h);if(v&&(g=r(g,2<y?n:void 0,2)),null==_||m==Array&&a(_))for(d=new m(o=l(h.length));b<o;b++)c(d,b,v?g(h[b],b):h[b]);else for(p=_.call(h),d=new m;!(f=p.next()).done;b++)c(d,b,v?s(p,g,[f.value,b],!0):f.value);return d.length=b,d}})},{"./_create-property":15,"./_ctx":16,"./_export":22,"./_is-array-iter":37,"./_iter-call":41,"./_iter-detect":44,"./_to-length":89,"./_to-object":90,"./core.get-iterator-method":100}],103:[function(e,t,n){"use strict";var r=e("./_add-to-unscopables"),o=e("./_iter-step"),i=e("./_iterators"),s=e("./_to-iobject");t.exports=e("./_iter-define")(Array,"Array",(function(e,t){this._t=s(e),this._i=0,this._k=t}),(function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,o(1)):o(0,"keys"==t?n:"values"==t?e[n]:[n,e[n]])}),"values"),i.Arguments=i.Array,r("keys"),r("values"),r("entries")},{"./_add-to-unscopables":2,"./_iter-define":43,"./_iter-step":45,"./_iterators":46,"./_to-iobject":88}],104:[function(e,t,n){var r=e("./_object-dp").f,o=Function.prototype,i=/^\s*function ([^ (]*)/;"name"in o||e("./_descriptors")&&r(o,"name",{configurable:!0,get:function(){try{return(""+this).match(i)[1]}catch(e){return""}}})},{"./_descriptors":18,"./_object-dp":54}],105:[function(e,t,n){var r=e("./_export");r(r.S,"Math",{clz32:function(e){return(e>>>=0)?31-Math.floor(Math.log(e+.5)*Math.LOG2E):32}})},{"./_export":22}],106:[function(e,t,n){var r=e("./_export");r(r.S,"Math",{fround:e("./_math-fround")})},{"./_export":22,"./_math-fround":48}],107:[function(e,t,n){var r=e("./_export"),o=Math.imul;r(r.S+r.F*e("./_fails")((function(){return-5!=o(4294967295,5)||2!=o.length})),"Math",{imul:function(e,t){var n=65535,r=+e,o=+t,i=n&r,s=n&o;return 0|i*s+((n&r>>>16)*s+i*(n&o>>>16)<<16>>>0)}})},{"./_export":22,"./_fails":24}],108:[function(e,t,n){var r=e("./_export");r(r.S,"Math",{trunc:function(e){return(0<e?Math.floor:Math.ceil)(e)}})},{"./_export":22}],109:[function(e,t,n){"use strict";function r(e){var t=l(e,!1);if("string"==typeof t&&2<t.length){var n,r,o,i=(t=b?t.trim():p(t,3)).charCodeAt(0);if(43===i||45===i){if(88===(n=t.charCodeAt(2))||120===n)return NaN}else if(48===i){switch(t.charCodeAt(1)){case 66:case 98:r=2,o=49;break;case 79:case 111:r=8,o=55;break;default:return+t}for(var s,a=t.slice(2),c=0,u=a.length;c<u;c++)if((s=a.charCodeAt(c))<48||o<s)return NaN;return parseInt(a,r)}}return+t}var o=e("./_global"),i=e("./_has"),s=e("./_cof"),a=e("./_inherit-if-required"),l=e("./_to-primitive"),c=e("./_fails"),u=e("./_object-gopn").f,d=e("./_object-gopd").f,f=e("./_object-dp").f,p=e("./_string-trim").trim,h="Number",m=o[h],y=m,g=m.prototype,v=s(e("./_object-create")(g))==h,b="trim"in String.prototype;if(!m(" 0o1")||!m("0b1")||m("+0x1")){m=function(e){var t=arguments.length<1?0:e,n=this;return n instanceof m&&(v?c((function(){g.valueOf.call(n)})):s(n)!=h)?a(new y(r(t)),n,m):r(t)};for(var _,w=e("./_descriptors")?u(y):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),x=0;w.length>x;x++)i(y,_=w[x])&&!i(m,_)&&f(m,_,d(y,_));(m.prototype=g).constructor=m,e("./_redefine")(o,h,m)}},{"./_cof":13,"./_descriptors":18,"./_fails":24,"./_global":29,"./_has":30,"./_inherit-if-required":34,"./_object-create":53,"./_object-dp":54,"./_object-gopd":56,"./_object-gopn":58,"./_redefine":71,"./_string-trim":82,"./_to-primitive":91}],110:[function(e,t,n){var r=e("./_export"),o=e("./_parse-int");r(r.S+r.F*(Number.parseInt!=o),"Number",{parseInt:o})},{"./_export":22,"./_parse-int":66}],111:[function(e,t,n){var r=e("./_to-object"),o=e("./_object-keys");e("./_object-sap")("keys",(function(){return function(e){return o(r(e))}}))},{"./_object-keys":62,"./_object-sap":64,"./_to-object":90}],112:[function(e,t,n){"use strict";var r=e("./_classof"),o={};o[e("./_wks")("toStringTag")]="z",o+""!="[object z]"&&e("./_redefine")(Object.prototype,"toString",(function(){return"[object "+r(this)+"]"}),!0)},{"./_classof":12,"./_redefine":71,"./_wks":99}],113:[function(e,t,n){"use strict";function r(){}function o(e){var t;return!(!y(e)||"function"!=typeof(t=e.then))&&t}function i(e,t){if(!e._n){e._n=!0;var n=e._c;x((function(){for(var r=e._v,i=1==e._s,s=0,a=function(t){var n,s,a,l=i?t.ok:t.fail,c=t.resolve,u=t.reject,d=t.domain;try{l?(i||(2==e._h&&R(e),e._h=1),!0===l?n=r:(d&&d.enter(),n=l(r),d&&(d.exit(),a=!0)),n===t.promise?u(S("Promise-chain cycle")):(s=o(n))?s.call(n,c,u):c(n)):u(r)}catch(t){d&&!a&&d.exit(),u(t)}};n.length>s;)a(n[s++]);e._c=[],e._n=!1,t&&!e._h&&K(e)}))}}function s(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),i(t,!0))}var a,l,c,u,d=e("./_library"),f=e("./_global"),p=e("./_ctx"),h=e("./_classof"),m=e("./_export"),y=e("./_is-object"),g=e("./_a-function"),v=e("./_an-instance"),b=e("./_for-of"),_=e("./_species-constructor"),w=e("./_task").set,x=e("./_microtask")(),k=e("./_new-promise-capability"),j=e("./_perform"),C=e("./_user-agent"),E=e("./_promise-resolve"),D="Promise",S=f.TypeError,O=f.process,P=O&&O.versions,B=P&&P.v8||"",M=f[D],T="process"==h(O),A=l=k.f,I=!!function(){try{var t=M.resolve(1),n=(t.constructor={})[e("./_wks")("species")]=function(e){e(r,r)};return(T||"function"==typeof PromiseRejectionEvent)&&t.then(r)instanceof n&&0!==B.indexOf("6.6")&&-1===C.indexOf("Chrome/66")}catch(t){}}(),K=function(e){w.call(f,(function(){var t,n,r,o=e._v,i=L(e);if(i&&(t=j((function(){T?O.emit("unhandledRejection",o,e):(n=f.onunhandledrejection)?n({promise:e,reason:o}):(r=f.console)&&r.error&&r.error("Unhandled promise rejection",o)})),e._h=T||L(e)?2:1),e._a=void 0,i&&t.e)throw t.v}))},L=function(e){return 1!==e._h&&0===(e._a||e._c).length},R=function(e){w.call(f,(function(){var t;T?O.emit("rejectionHandled",e):(t=f.onrejectionhandled)&&t({promise:e,reason:e._v})}))},N=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw S("Promise can't be resolved itself");(t=o(e))?x((function(){var r={_w:n,_d:!1};try{t.call(e,p(N,r,1),p(s,r,1))}catch(e){s.call(r,e)}})):(n._v=e,n._s=1,i(n,!1))}catch(e){s.call({_w:n,_d:!1},e)}}};I||(M=function(e){v(this,M,D,"_h"),g(e),a.call(this);try{e(p(N,this,1),p(s,this,1))}catch(e){s.call(this,e)}},(a=function(){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=e("./_redefine-all")(M.prototype,{then:function(e,t){var n=A(_(this,M));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=T?O.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&i(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),c=function(){var e=new a;this.promise=e,this.resolve=p(N,e,1),this.reject=p(s,e,1)},k.f=A=function(e){return e===M||e===u?new c:l(e)}),m(m.G+m.W+m.F*!I,{Promise:M}),e("./_set-to-string-tag")(M,D),e("./_set-species")(D),u=e("./_core")[D],m(m.S+m.F*!I,D,{reject:function(e){var t=A(this);return(0,t.reject)(e),t.promise}}),m(m.S+m.F*(d||!I),D,{resolve:function(e){return E(d&&this===u?M:this,e)}}),m(m.S+m.F*!(I&&e("./_iter-detect")((function(e){M.all(e).catch(r)}))),D,{all:function(e){var t=this,n=A(t),r=n.resolve,o=n.reject,i=j((function(){var n=[],i=0,s=1;b(e,!1,(function(e){var a=i++,l=!1;n.push(void 0),s++,t.resolve(e).then((function(e){l||(l=!0,n[a]=e,--s||r(n))}),o)})),--s||r(n)}));return i.e&&o(i.v),n.promise},race:function(e){var t=this,n=A(t),r=n.reject,o=j((function(){b(e,!1,(function(e){t.resolve(e).then(n.resolve,r)}))}));return o.e&&r(o.v),n.promise}})},{"./_a-function":1,"./_an-instance":4,"./_classof":12,"./_core":14,"./_ctx":16,"./_export":22,"./_for-of":27,"./_global":29,"./_is-object":39,"./_iter-detect":44,"./_library":47,"./_microtask":51,"./_new-promise-capability":52,"./_perform":67,"./_promise-resolve":68,"./_redefine-all":70,"./_set-species":75,"./_set-to-string-tag":76,"./_species-constructor":79,"./_task":84,"./_user-agent":96,"./_wks":99}],114:[function(e,t,n){var r=e("./_global"),o=e("./_inherit-if-required"),i=e("./_object-dp").f,s=e("./_object-gopn").f,a=e("./_is-regexp"),l=e("./_flags"),c=r.RegExp,u=c,d=c.prototype,f=/a/g,p=/a/g,h=new c(f)!==f;if(e("./_descriptors")&&(!h||e("./_fails")((function(){return p[e("./_wks")("match")]=!1,c(f)!=f||c(p)==p||"/a/i"!=c(f,"i")})))){function m(e){e in c||i(c,e,{configurable:!0,get:function(){return u[e]},set:function(t){u[e]=t}})}c=function(e,t){var n=this instanceof c,r=a(e),i=void 0===t;return!n&&r&&e.constructor===c&&i?e:o(h?new u(r&&!i?e.source:e,t):u((r=e instanceof c)?e.source:e,r&&i?l.call(e):t),n?this:d,c)};for(var y=s(u),g=0;y.length>g;)m(y[g++]);(d.constructor=c).prototype=d,e("./_redefine")(r,"RegExp",c)}e("./_set-species")("RegExp")},{"./_descriptors":18,"./_fails":24,"./_flags":26,"./_global":29,"./_inherit-if-required":34,"./_is-regexp":40,"./_object-dp":54,"./_object-gopn":58,"./_redefine":71,"./_set-species":75,"./_wks":99}],115:[function(e,t,n){"use strict";var r=e("./_regexp-exec");e("./_export")({target:"RegExp",proto:!0,forced:r!==/./.exec},{exec:r})},{"./_export":22,"./_regexp-exec":73}],116:[function(e,t,n){e("./_descriptors")&&"g"!=/./g.flags&&e("./_object-dp").f(RegExp.prototype,"flags",{configurable:!0,get:e("./_flags")})},{"./_descriptors":18,"./_flags":26,"./_object-dp":54}],117:[function(e,t,n){"use strict";var r=e("./_an-object"),o=e("./_to-object"),i=e("./_to-length"),s=e("./_to-integer"),a=e("./_advance-string-index"),l=e("./_regexp-exec-abstract"),c=Math.max,u=Math.min,d=Math.floor,f=/\$([$&`']|\d\d?|<[^>]*>)/g,p=/\$([$&`']|\d\d?)/g;e("./_fix-re-wks")("replace",2,(function(e,t,n,h){return[function(r,o){var i=e(this),s=null==r?void 0:r[t];return void 0!==s?s.call(r,i,o):n.call(String(i),r,o)},function(e,t){var o=h(n,e,this,t);if(o.done)return o.value;var d=r(e),f=String(this),p="function"==typeof t;p||(t=String(t));var y=d.global;if(y){var g=d.unicode;d.lastIndex=0}for(var v=[];;){var b=l(d,f);if(null===b)break;if(v.push(b),!y)break;""===String(b[0])&&(d.lastIndex=a(f,i(d.lastIndex),g))}for(var _,w="",x=0,k=0;k<v.length;k++){b=v[k];for(var j=String(b[0]),C=c(u(s(b.index),f.length),0),E=[],D=1;D<b.length;D++)E.push(void 0===(_=b[D])?_:String(_));var S=b.groups;if(p){var O=[j].concat(E,C,f);void 0!==S&&O.push(S);var P=String(t.apply(void 0,O))}else P=m(j,f,C,E,S,t);x<=C&&(w+=f.slice(x,C)+P,x=C+j.length)}return w+f.slice(x)}];function m(e,t,r,i,s,a){var l=r+e.length,c=i.length,u=p;return void 0!==s&&(s=o(s),u=f),n.call(a,u,(function(n,o){var a;switch(o.charAt(0)){case"$":return"$";case"&":return e;case"`":return t.slice(0,r);case"'":return t.slice(l);case"<":a=s[o.slice(1,-1)];break;default:var u=+o;if(0==u)return n;if(c<u){var f=d(u/10);return 0===f?n:f<=c?void 0===i[f-1]?o.charAt(1):i[f-1]+o.charAt(1):n}a=i[u-1]}return void 0===a?"":a}))}}))},{"./_advance-string-index":3,"./_an-object":5,"./_fix-re-wks":25,"./_regexp-exec-abstract":72,"./_to-integer":87,"./_to-length":89,"./_to-object":90}],118:[function(e,t,n){"use strict";var r=e("./_is-regexp"),o=e("./_an-object"),i=e("./_species-constructor"),s=e("./_advance-string-index"),a=e("./_to-length"),l=e("./_regexp-exec-abstract"),c=e("./_regexp-exec"),u=e("./_fails"),d=Math.min,f=[].push,p="split",h="length",m="lastIndex",y=4294967295,g=!u((function(){RegExp(y,"y")}));e("./_fix-re-wks")("split",2,(function(e,t,n,u){var v;return v="c"=="abbc"[p](/(b)*/)[1]||4!="test"[p](/(?:)/,-1)[h]||2!="ab"[p](/(?:ab)*/)[h]||4!="."[p](/(.?)(.?)/)[h]||1<"."[p](/()()/)[h]||""[p](/.?/)[h]?function(e,t){var o=String(this);if(void 0===e&&0===t)return[];if(!r(e))return n.call(o,e,t);for(var i,s,a,l=[],u=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),d=0,p=void 0===t?y:t>>>0,g=new RegExp(e.source,u+"g");(i=c.call(g,o))&&!(d<(s=g[m])&&(l.push(o.slice(d,i.index)),1<i[h]&&i.index<o[h]&&f.apply(l,i.slice(1)),a=i[0][h],d=s,l[h]>=p));)g[m]===i.index&&g[m]++;return d===o[h]?!a&&g.test("")||l.push(""):l.push(o.slice(d)),l[h]>p?l.slice(0,p):l}:"0"[p](void 0,0)[h]?function(e,t){return void 0===e&&0===t?[]:n.call(this,e,t)}:n,[function(n,r){var o=e(this),i=null==n?void 0:n[t];return void 0!==i?i.call(n,o,r):v.call(String(o),n,r)},function(e,t){var r=u(v,e,this,t,v!==n);if(r.done)return r.value;var c=o(e),f=String(this),p=i(c,RegExp),h=c.unicode,m=(c.ignoreCase?"i":"")+(c.multiline?"m":"")+(c.unicode?"u":"")+(g?"y":"g"),b=new p(g?c:"^(?:"+c.source+")",m),_=void 0===t?y:t>>>0;if(0==_)return[];if(0===f.length)return null===l(b,f)?[f]:[];for(var w=0,x=0,k=[];x<f.length;){b.lastIndex=g?x:0;var j,C=l(b,g?f:f.slice(x));if(null===C||(j=d(a(b.lastIndex+(g?0:x)),f.length))===w)x=s(f,x,h);else{if(k.push(f.slice(w,x)),k.length===_)return k;for(var E=1;E<=C.length-1;E++)if(k.push(C[E]),k.length===_)return k;x=w=j}}return k.push(f.slice(w)),k}]}))},{"./_advance-string-index":3,"./_an-object":5,"./_fails":24,"./_fix-re-wks":25,"./_is-regexp":40,"./_regexp-exec":73,"./_regexp-exec-abstract":72,"./_species-constructor":79,"./_to-length":89}],119:[function(e,t,n){"use strict";function r(t){e("./_redefine")(RegExp.prototype,a,t,!0)}e("./es6.regexp.flags");var o=e("./_an-object"),i=e("./_flags"),s=e("./_descriptors"),a="toString",l=/./[a];e("./_fails")((function(){return"/a/b"!=l.call({source:"a",flags:"b"})}))?r((function(){var e=o(this);return"/".concat(e.source,"/","flags"in e?e.flags:!s&&e instanceof RegExp?i.call(e):void 0)})):l.name!=a&&r((function(){return l.call(this)}))},{"./_an-object":5,"./_descriptors":18,"./_fails":24,"./_flags":26,"./_redefine":71,"./es6.regexp.flags":116}],120:[function(e,t,n){"use strict";var r=e("./_string-at")(!0);e("./_iter-define")(String,"String",(function(e){this._t=String(e),this._i=0}),(function(){var e,t=this._t,n=this._i;return n>=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})}))},{"./_iter-define":43,"./_string-at":80}],121:[function(e,t,n){"use strict";var r=e("./_export"),o=e("./_to-length"),i=e("./_string-context"),s="startsWith",a=""[s];r(r.P+r.F*e("./_fails-is-regexp")(s),"String",{startsWith:function(e,t){var n=i(this,e,s),r=o(Math.min(1<arguments.length?t:void 0,n.length)),l=String(e);return a?a.call(n,l,r):n.slice(r,r+l.length)===l}})},{"./_export":22,"./_fails-is-regexp":23,"./_string-context":81,"./_to-length":89}],122:[function(e,t,n){"use strict";function r(e){var t=G[e]=P(N[z]);return t._k=e,t}function o(e,t){j(e);for(var n,r=x(t=D(t)),o=0,i=r.length;o<i;)te(e,n=r[o++],t[n]);return e}function i(e){var t=q.call(this,e=S(e,!0));return!(this===X&&u(G,e)&&!u(Y,e))&&(!(t||!u(this,e)||!u(G,e)||u(this,H)&&this[H][e])||t)}function s(e,t){if(e=D(e),t=S(t,!0),e!==X||!u(G,t)||u(Y,t)){var n=K(e,t);return!n||!u(G,t)||u(e,H)&&e[H][t]||(n.enumerable=!0),n}}function a(e){for(var t,n=R(D(e)),r=[],o=0;n.length>o;)u(G,t=n[o++])||t==H||t==h||r.push(t);return r}function l(e){for(var t,n=e===X,r=R(n?Y:D(e)),o=[],i=0;r.length>i;)!u(G,t=r[i++])||n&&!u(X,t)||o.push(G[t]);return o}var c=e("./_global"),u=e("./_has"),d=e("./_descriptors"),f=e("./_export"),p=e("./_redefine"),h=e("./_meta").KEY,m=e("./_fails"),y=e("./_shared"),g=e("./_set-to-string-tag"),v=e("./_uid"),b=e("./_wks"),_=e("./_wks-ext"),w=e("./_wks-define"),x=e("./_enum-keys"),k=e("./_is-array"),j=e("./_an-object"),C=e("./_is-object"),E=e("./_to-object"),D=e("./_to-iobject"),S=e("./_to-primitive"),O=e("./_property-desc"),P=e("./_object-create"),B=e("./_object-gopn-ext"),M=e("./_object-gopd"),T=e("./_object-gops"),A=e("./_object-dp"),I=e("./_object-keys"),K=M.f,L=A.f,R=B.f,N=c.Symbol,F=c.JSON,U=F&&F.stringify,z="prototype",H=b("_hidden"),W=b("toPrimitive"),q={}.propertyIsEnumerable,V=y("symbol-registry"),G=y("symbols"),Y=y("op-symbols"),X=Object[z],$="function"==typeof N&&!!T.f,J=c.QObject,Q=!J||!J[z]||!J[z].findChild,Z=d&&m((function(){return 7!=P(L({},"a",{get:function(){return L(this,"a",{value:7}).a}})).a}))?function(e,t,n){var r=K(X,t);r&&delete X[t],L(e,t,n),r&&e!==X&&L(X,t,r)}:L,ee=$&&"symbol"==typeof N.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof N},te=function(e,t,n){return e===X&&te(Y,t,n),j(e),t=S(t,!0),j(n),u(G,t)?(n.enumerable?(u(e,H)&&e[H][t]&&(e[H][t]=!1),n=P(n,{enumerable:O(0,!1)})):(u(e,H)||L(e,H,O(1,{})),e[H][t]=!0),Z(e,t,n)):L(e,t,n)};$||(p((N=function(e){if(this instanceof N)throw TypeError("Symbol is not a constructor!");var t=v(0<arguments.length?e:void 0),n=function(e){this===X&&n.call(Y,e),u(this,H)&&u(this[H],t)&&(this[H][t]=!1),Z(this,t,O(1,e))};return d&&Q&&Z(X,t,{configurable:!0,set:n}),r(t)})[z],"toString",(function(){return this._k})),M.f=s,A.f=te,e("./_object-gopn").f=B.f=a,e("./_object-pie").f=i,T.f=l,d&&!e("./_library")&&p(X,"propertyIsEnumerable",i,!0),_.f=function(e){return r(b(e))}),f(f.G+f.W+f.F*!$,{Symbol:N});for(var ne="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),re=0;ne.length>re;)b(ne[re++]);for(var oe=I(b.store),ie=0;oe.length>ie;)w(oe[ie++]);f(f.S+f.F*!$,"Symbol",{for:function(e){return u(V,e+="")?V[e]:V[e]=N(e)},keyFor:function(e){if(!ee(e))throw TypeError(e+" is not a symbol!");for(var t in V)if(V[t]===e)return t},useSetter:function(){Q=!0},useSimple:function(){Q=!1}}),f(f.S+f.F*!$,"Object",{create:function(e,t){return void 0===t?P(e):o(P(e),t)},defineProperty:te,defineProperties:o,getOwnPropertyDescriptor:s,getOwnPropertyNames:a,getOwnPropertySymbols:l});var se=m((function(){T.f(1)}));f(f.S+f.F*se,"Object",{getOwnPropertySymbols:function(e){return T.f(E(e))}}),F&&f(f.S+f.F*(!$||m((function(){var e=N();return"[null]"!=U([e])||"{}"!=U({a:e})||"{}"!=U(Object(e))}))),"JSON",{stringify:function(e){for(var t,n,r=[e],o=1;o<arguments.length;)r.push(arguments[o++]);if(n=t=r[1],(C(t)||void 0!==e)&&!ee(e))return k(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!ee(t))return t}),r[1]=t,U.apply(F,r)}}),N[z][W]||e("./_hide")(N[z],W,N[z].valueOf),g(N,"Symbol"),g(Math,"Math",!0),g(c.JSON,"JSON",!0)},{"./_an-object":5,"./_descriptors":18,"./_enum-keys":21,"./_export":22,"./_fails":24,"./_global":29,"./_has":30,"./_hide":31,"./_is-array":38,"./_is-object":39,"./_library":47,"./_meta":50,"./_object-create":53,"./_object-dp":54,"./_object-gopd":56,"./_object-gopn":58,"./_object-gopn-ext":57,"./_object-gops":59,"./_object-keys":62,"./_object-pie":63,"./_property-desc":69,"./_redefine":71,"./_set-to-string-tag":76,"./_shared":78,"./_to-iobject":88,"./_to-object":90,"./_to-primitive":91,"./_uid":95,"./_wks":99,"./_wks-define":97,"./_wks-ext":98}],123:[function(e,t,n){e("./_typed-array")("Float32",4,(function(e){return function(t,n,r){return e(this,t,n,r)}}))},{"./_typed-array":92}],124:[function(e,t,n){e("./_typed-array")("Uint8",1,(function(e){return function(t,n,r){return e(this,t,n,r)}}))},{"./_typed-array":92}],125:[function(e,t,n){e("./_typed-array")("Uint8",1,(function(e){return function(t,n,r){return e(this,t,n,r)}}),!0)},{"./_typed-array":92}],126:[function(e,t,n){var r=e("./_export"),o=e("./_own-keys"),i=e("./_to-iobject"),s=e("./_object-gopd"),a=e("./_create-property");r(r.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n,r=i(e),l=s.f,c=o(r),u={},d=0;c.length>d;)void 0!==(n=l(r,t=c[d++]))&&a(u,t,n);return u}})},{"./_create-property":15,"./_export":22,"./_object-gopd":56,"./_own-keys":65,"./_to-iobject":88}],127:[function(e,t,n){e("./_wks-define")("asyncIterator")},{"./_wks-define":97}],128:[function(e,t,n){for(var r=e("./es6.array.iterator"),o=e("./_object-keys"),i=e("./_redefine"),s=e("./_global"),a=e("./_hide"),l=e("./_iterators"),c=e("./_wks"),u=c("iterator"),d=c("toStringTag"),f=l.Array,p={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},h=o(p),m=0;m<h.length;m++){var y,g=h[m],v=p[g],b=s[g],_=b&&b.prototype;if(_&&(_[u]||a(_,u,f),_[d]||a(_,d,g),l[g]=f,v))for(y in r)_[y]||i(_,y,r[y],!0)}},{"./_global":29,"./_hide":31,"./_iterators":46,"./_object-keys":62,"./_redefine":71,"./_wks":99,"./es6.array.iterator":103}],129:[function(e,t,n){var r=function(e){"use strict";var t,n=Object.prototype,r=n.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",s=o.asyncIterator||"@@asyncIterator",a=o.toStringTag||"@@toStringTag";function l(e,t,n,r){var o,i,s,a,l=t&&t.prototype instanceof m?t:m,y=Object.create(l.prototype),g=new D(r||[]);return y._invoke=(o=e,i=n,s=g,a=u,function(e,t){if(a===f)throw new Error("Generator is already running");if(a===p){if("throw"===e)throw t;return O()}for(s.method=e,s.arg=t;;){var n=s.delegate;if(n){var r=j(n,s);if(r){if(r===h)continue;return r}}if("next"===s.method)s.sent=s._sent=s.arg;else if("throw"===s.method){if(a===u)throw a=p,s.arg;s.dispatchException(s.arg)}else"return"===s.method&&s.abrupt("return",s.arg);a=f;var l=c(o,i,s);if("normal"===l.type){if(a=s.done?p:d,l.arg===h)continue;return{value:l.arg,done:s.done}}"throw"===l.type&&(a=p,s.method="throw",s.arg=l.arg)}}),y}function c(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=l;var u="suspendedStart",d="suspendedYield",f="executing",p="completed",h={};function m(){}function y(){}function g(){}var v={};v[i]=function(){return this};var b=Object.getPrototypeOf,_=b&&b(b(S([])));_&&_!==n&&r.call(_,i)&&(v=_);var w=g.prototype=m.prototype=Object.create(v);function x(e){["next","throw","return"].forEach((function(t){e[t]=function(e){return this._invoke(t,e)}}))}function k(e,t){var n;this._invoke=function(o,i){function s(){return new t((function(n,s){!function n(o,i,s,a){var l=c(e[o],e,i);if("throw"!==l.type){var u=l.arg,d=u.value;return d&&"object"==typeof d&&r.call(d,"__await")?t.resolve(d.__await).then((function(e){n("next",e,s,a)}),(function(e){n("throw",e,s,a)})):t.resolve(d).then((function(e){u.value=e,s(u)}),(function(e){return n("throw",e,s,a)}))}a(l.arg)}(o,i,n,s)}))}return n=n?n.then(s,s):s()}}function j(e,n){var r=e.iterator[n.method];if(r===t){if(n.delegate=null,"throw"===n.method){if(e.iterator.return&&(n.method="return",n.arg=t,j(e,n),"throw"===n.method))return h;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return h}var o=c(r,e.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,h;var i=o.arg;return i?i.done?(n[e.resultName]=i.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,h):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,h)}function C(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function E(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function D(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function S(e){if(e){var n=e[i];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,s=function n(){for(;++o<e.length;)if(r.call(e,o))return n.value=e[o],n.done=!1,n;return n.value=t,n.done=!0,n};return s.next=s}}return{next:O}}function O(){return{value:t,done:!0}}return y.prototype=w.constructor=g,g.constructor=y,g[a]=y.displayName="GeneratorFunction",e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,g):(e.__proto__=g,a in e||(e[a]="GeneratorFunction")),e.prototype=Object.create(w),e},e.awrap=function(e){return{__await:e}},x(k.prototype),k.prototype[s]=function(){return this},e.AsyncIterator=k,e.async=function(t,n,r,o,i){void 0===i&&(i=Promise);var s=new k(l(t,n,r,o),i);return e.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},x(w),w[a]="Generator",w[i]=function(){return this},w.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=S,D.prototype={constructor:D,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(E),!e)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function o(r,o){return a.type="throw",a.arg=e,n.next=r,o&&(n.method="next",n.arg=t),!!o}for(var i=this.tryEntries.length-1;0<=i;--i){var s=this.tryEntries[i],a=s.completion;if("root"===s.tryLoc)return o("end");if(s.tryLoc<=this.prev){var l=r.call(s,"catchLoc"),c=r.call(s,"finallyLoc");if(l&&c){if(this.prev<s.catchLoc)return o(s.catchLoc,!0);if(this.prev<s.finallyLoc)return o(s.finallyLoc)}else if(l){if(this.prev<s.catchLoc)return o(s.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return o(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;0<=n;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var s=i?i.completion:{};return s.type=e,s.arg=t,i?(this.method="next",this.next=i.finallyLoc,h):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),h},finish:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),E(n),h}},catch:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;E(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:S(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),h}},e}("object"==typeof t?t.exports:{});try{regeneratorRuntime=r}catch(e){Function("r","regeneratorRuntime = r")(r)}},{}],130:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.Build={version:"0.73.3 (7332207bb10bb5d59d4364699a626aca)",buildSeed:1649139531146,"wdosbox.shared.wasm":{size:1497234,gzSize:503616},"wdosbox.shared.js":{size:158273,gzSize:39750},"wdosbox.wasm":{size:1479102,gzSize:500062},"wdosbox.js":{size:125304,gzSize:32503},"wlibzip.wasm":{size:112813,gzSize:54476},"wlibzip.js":{size:76877,gzSize:20063}}},{}],131:[function(e,t,n){"use strict";function r(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=s(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,o,i=!0,a=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return i=e.done,e},e:function(e){a=!0,o=e},f:function(){try{i||null==r.return||r.return()}finally{if(a)throw o}}}}function o(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function i(e){return function(e){if(Array.isArray(e))return a(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||s(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function l(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.array.from"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.typed.uint8-array"),e("core-js/modules/es6.promise"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es6.array.iterator"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.string.iterator"),e("regenerator-runtime/runtime");Object.defineProperty(n,"__esModule",{value:!0});var c=e("./dos-conf"),u=function(e){return e&&e.__esModule?e:{default:e}}(e("../../libzip/libzip")),d=e("../../http"),f=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.config=c.createDosConfig(),this.sources=[],this.libzipWasm=t}var t,n,s,a;return t=e,(n=[{key:"autoexec",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.config.autoexec.options.script.value=t.join("\n"),this}},{key:"cycles",value:function(e){return this.config.cpu.options.cycles.value=e,this}},{key:"extract",value:function(e,t,n){var r=1<arguments.length&&void 0!==t?t:"/",o=2<arguments.length&&void 0!==n?n:"zip";return this.extractAll([{url:e,path:r,type:o}])}},{key:"extractAll",value:function(e){var t;return(t=this.sources).push.apply(t,i(e)),this}},{key:"toUint8Array",value:(s=regeneratorRuntime.mark((function e(){var t,n,o,i,s,a,l,f,h,m,y,g,v,b=arguments;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=0<b.length&&void 0!==b[0]&&b[0],n={},e.next=4,this.libzipWasm.instantiate(n);case 4:return o=new u.default(n,"/home/web_user"),e.next=7,c.toDosboxConf(this.config);case 7:i=e.sent,s=[],a=r(this.sources);try{for(f=function(){var e=l.value;if("zip"!==e.type)throw new Error("Only Zip is supported");var t=d.HTTPRequest(e.url,{responseType:"arraybuffer"}).then((function(t){return{source:e,data:new Uint8Array(t)}}));s.push(t)},a.s();!(l=a.n()).done;)f()}catch(e){a.e(e)}finally{a.f()}if(t){e.next=18;break}return e.next=14,o.writeFile(".jsdos/dosbox.conf",i);case 14:return e.next=16,o.writeFile(".jsdos/readme.txt",p);case 16:return e.next=18,o.writeFile(".jsdos/jsdos.json",JSON.stringify(this.config,null,2));case 18:return e.next=20,Promise.all(s);case 20:h=e.sent,m=r(h);try{for(m.s();!(y=m.n()).done;)g=y.value,o.zipToFs(g.data,g.source.path)}catch(e){m.e(e)}finally{m.f()}if(t)return e.next=26,o.writeFile(".jsdos/dosbox.conf",i);e.next=30;break;case 26:return e.next=28,o.writeFile(".jsdos/readme.txt",p);case 28:return e.next=30,o.writeFile(".jsdos/jsdos.json",JSON.stringify(this.config,null,2));case 30:return e.next=32,o.zipFromFs();case 32:return v=e.sent,o.destroy(),e.abrupt("return",v);case 35:case"end":return e.stop()}}),e,this)})),a=function(){var e=this,t=arguments;return new Promise((function(n,r){var i=s.apply(e,t);function a(e){o(i,n,r,a,l,"next",e)}function l(e){o(i,n,r,a,l,"throw",e)}a(void 0)}))},function(){return a.apply(this,arguments)})}])&&l(t.prototype,n),e}();n.default=f;var p="\nPlease visit our website:\n\n _ __\n (_)____ ____/ /___ _____ _________ ____ ___\n / / ___/_____/ __ / __ \\/ ___// ___/ __ \\/ __ `__ \\\n / (__ )_____/ /_/ / /_/ (__ )/ /__/ /_/ / / / / / /\n __/ /____/ \\__,_/\\____/____(_)___/\\____/_/ /_/ /_/\n /___/\n"},{"../../http":136,"../../libzip/libzip":141,"./dos-conf":132,"core-js/modules/es6.array.from":102,"core-js/modules/es6.array.iterator":103,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.symbol":122,"core-js/modules/es6.typed.uint8-array":124,"core-js/modules/es7.symbol.async-iterator":127,"core-js/modules/web.dom.iterable":128,"regenerator-runtime/runtime":129}],132:[function(e,t,n){"use strict";function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){i(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function l(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){a(i,r,o,s,l,"next",e)}function l(e){a(i,r,o,s,l,"throw",e)}s(void 0)}))}}function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}e("core-js/modules/es7.object.get-own-property-descriptors"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.regexp.to-string"),e("regenerator-runtime/runtime"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.number.constructor"),e("core-js/modules/es6.number.parse-int"),e("core-js/modules/es6.string.starts-with"),e("core-js/modules/es6.array.find"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es6.array.iterator"),e("core-js/modules/es6.object.keys"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.function.name"),Object.defineProperty(n,"__esModule",{value:!0});var d=function e(){u(this,e),this.name="sdl",this.description="This section contains all of the low level system settings for how DOSBox interacts with your real hardware. You can define what resolutions are emulated, how DOSBox should treat errors or listen to your keyboard and mouse. You can often achieve a fair level of optimization by working with these setting, though for the most part leaving them at their default settings will create the best experience. These settings are passed on to the SDL Library which handles low level things like input and thread priority.",this.options={autolock:{name:"autolock",description:"Mouse will automatically lock, if you click on the screen.",value:!1,allowedValues:[!0,!1]}}};n.OutputCategory=d;var f=function e(){u(this,e),this.name="dosbox",this.description="The [dosbox] section contains various settings that do not pertain to any other section (e.g. setting the language used in DOSBox help texts, where to store screen captures, etc.)",this.options={machine:{name:"machine",description:"The type of machine tries to emulate.",value:"svga_s3",allowedValues:["hercules","cga","tandy","pcjr","ega","vgaonly","svga_s3","svga_et3000","svga_et4000","svga_paradise","vesa_nolfb","vesa_oldvbe"]}}};n.DosboxCategory=f;var p=function e(){u(this,e),this.name="cpu",this.description="The CPU section controls how DOSBox tries to emulate the CPU, how fast the emulation should be, and to adjust it. DOSBox offers 4 different methods of CPU emulation.",this.options={core:{name:"core",description:"CPU Core used in emulation. auto will switch to dynamic if available and appropriate.",value:"auto",allowedValues:["auto","normal","simple"]},cputype:{name:"cputype",description:"CPU Type used in emulation. auto is the fastest choice.",value:"auto",allowedValues:["auto","386","386_slow","486_slow","pentium_slow","386_prefetch"]},cycles:{name:"cycles",description:"Amount of instructions DOSBox tries to emulate each millisecond. Setting this value too high results in sound dropouts and lags.\nCycles can be set in 3 ways:\n'auto' tries to guess what a game needs.\n It usually works, but can fail for certain games.\n'fixed #number' will set a fixed amount of cycles. This is what you usually need if 'auto' fails.\n (Example: fixed 4000).\n'max' will allocate as much cycles as your computer is able to handle.\n",value:"auto",allowedValues:["auto","fixed","max"]}}};n.CpuCategory=p;var h=function e(){u(this,e),this.name="mixer",this.description="Here you can define the quality of emulated audio.",this.options={rate:{name:"rate",description:"Frequency rate of sound",value:44100,allowedValues:[]},nosound:{name:"nosound",description:"Enable silent mode, sound is still emulated though.",value:!1,allowedValues:[!0,!1]}}};n.MixerCategory=h;var m=function e(){u(this,e),this.name="autoexec",this.description="Lines in this section will be run at startup",this.options={script:{name:"lines",description:"Use \\n to separate lines",value:"",allowedValues:[]}}};function y(){return{output:new d,dosbox:new f,cpu:new p,mixer:new h,autoexec:new m}}function g(e,t){var n="sdl"===t.name?"output":t.name;return new Promise((function(r,o){if(e)if(e.name===t.name){for(var i=0,s=Object.keys(e.options);i<s.length;i++){var a=s[i],l=e.options[a],u=t.options[a];if(void 0===u)return void o(new Error("Unknown option '"+(l.name||a)+"' in '"+e.name+"'"));if(0<u.allowedValues.length){var d=function(){var t=l.value,r=u.allowedValues.find((function(e){return e===t}));if("cpu"===n&&"cycles"===l.name&&(t+"").startsWith("fixed ")){var i=Number.parseInt(t.substr("fixed ".length),10);if(isNaN(i))return o(new Error("Fixed value should conatain number")),{v:void 0}}else if(void 0===r)return o(new Error("Incorrect value '"+t+"' ("+c(t)+") for '"+e.name+"."+(l.name||a)+"' allowed is "+JSON.stringify(u.allowedValues))),{v:void 0}}();if("object"===c(d))return d.v}}for(var f=0,p=Object.keys(t.options);f<p.length;f++){var h=p[f];if(!(h in e.options))return void o(new Error("Option '"+h+"' is missed in '"+n+"'"))}r()}else o(new Error("Incorrect category name '"+e.name+"' should be '"+t.name+"'"));else o(new Error("Category '"+n+"' is missed"))}))}function v(){return b.apply(this,arguments)}function b(){return(b=l(regeneratorRuntime.mark((function e(t){var n,r,o,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=y(),r=0,o=Object.keys(n);case 2:if(r<o.length)return i=o[r],e.next=6,g(t[i],n[i]);e.next=9;break;case 6:r++,e.next=2;break;case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function _(){return w.apply(this,arguments)}function w(){return(w=l(regeneratorRuntime.mark((function e(t,n){var r,i,s,a,l,c;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(void 0===t)return e.abrupt("return");e.next=2;break;case 2:r=0,i=Object.keys(t.options||{});case 3:if(!(r<i.length)){e.next=16;break}if(s=i[r],"string"!=typeof(a=t.options[s])&&"number"!=typeof a&&!Array.isArray(a)){e.next=13;break}if(l=n.options[s]){e.next=10;break}return e.abrupt("continue",13);case 10:c=a,t.options[s]=o({},l),t.options[s].value=c;case 13:r++,e.next=3;break;case 16:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function x(){return k.apply(this,arguments)}function k(){return(k=l(regeneratorRuntime.mark((function e(t){var n,r,o,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=y(),r=0,o=Object.keys(n);case 2:if(r<o.length)return i=o[r],e.next=6,_(t[i],n[i]);e.next=9;break;case 6:r++,e.next=2;break;case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function j(){return(j=l(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,x(t);case 2:return e.next=4,v(t);case 4:return n=C(t.output)+"\nfullscreen=false\nfulldouble=false\nfullresolution=original\nwindowresolution=original\noutput=surface\nsensitivity=100\nwaitonerror=true\npriority=higher,normal\nmapperfile=mapper-jsdos.map\nusescancodes=true\nvsync=false\n"+C(t.dosbox)+"\nlanguage=\ncaptures=capture\nmemsize=16\n"+C(t.cpu)+"\ncycleup=10\ncycledown=20\n"+C(t.mixer)+"\nblocksize=1024\nprebuffer=20\n\n[render]\n# frameskip: How many frames DOSBox skips before drawing one.\n# aspect: Do aspect correction, if your output method doesn't support scaling this can slow things down!.\n# scaler: Scaler used to enlarge/enhance low resolution modes.\n# If 'forced' is appended, then the scaler will be used even if the result might not be desired.\n# Possible values: none, normal2x, normal3x, advmame2x, advmame3x, advinterp2x, advinterp3x, hq2x, hq3x, 2xsai, super2xsai, supereagle, tv2x, tv3x, rgb2x, rgb3x, scan2x, scan3x.\n\nframeskip=0\naspect=false\nscaler=none\n\n[midi]\n# mpu401: Type of MPU-401 to emulate.\n# Possible values: intelligent, uart, none.\n# mididevice: Device that will receive the MIDI data from MPU-401.\n# Possible values: default, win32, alsa, oss, coreaudio, coremidi, none.\n# midiconfig: Special configuration options for the device driver. This is usually the id of the device you want to use.\n# See the README/Manual for more details.\n\nmpu401=intelligent\nmididevice=default\nmidiconfig=\n\n[sblaster]\n# sbtype: Type of Soundblaster to emulate. gb is Gameblaster.\n# Possible values: sb1, sb2, sbpro1, sbpro2, sb16, gb, none.\n# sbbase: The IO address of the soundblaster.\n# Possible values: 220, 240, 260, 280, 2a0, 2c0, 2e0, 300.\n# irq: The IRQ number of the soundblaster.\n# Possible values: 7, 5, 3, 9, 10, 11, 12.\n# dma: The DMA number of the soundblaster.\n# Possible values: 1, 5, 0, 3, 6, 7.\n# hdma: The High DMA number of the soundblaster.\n# Possible values: 1, 5, 0, 3, 6, 7.\n# sbmixer: Allow the soundblaster mixer to modify the DOSBox mixer.\n# oplmode: Type of OPL emulation. On 'auto' the mode is determined by sblaster type. All OPL modes are Adlib-compatible, except for 'cms'.\n# Possible values: auto, cms, opl2, dualopl2, opl3, none.\n# oplemu: Provider for the OPL emulation. compat might provide better quality (see oplrate as well).\n# Possible values: default, compat, fast.\n# oplrate: Sample rate of OPL music emulation. Use 49716 for highest quality (set the mixer rate accordingly).\n# Possible values: 44100, 49716, 48000, 32000, 22050, 16000, 11025, 8000.\n\nsbtype=sb16\nsbbase=220\nirq=7\ndma=1\nhdma=5\nsbmixer=true\noplmode=auto\noplemu=default\noplrate=44100\n\n[gus]\n# gus: Enable the Gravis Ultrasound emulation.\n# gusrate: Sample rate of Ultrasound emulation.\n# Possible values: 44100, 48000, 32000, 22050, 16000, 11025, 8000, 49716.\n# gusbase: The IO base address of the Gravis Ultrasound.\n# Possible values: 240, 220, 260, 280, 2a0, 2c0, 2e0, 300.\n# gusirq: The IRQ number of the Gravis Ultrasound.\n# Possible values: 5, 3, 7, 9, 10, 11, 12.\n# gusdma: The DMA channel of the Gravis Ultrasound.\n# Possible values: 3, 0, 1, 5, 6, 7.\n# ultradir: Path to Ultrasound directory. In this directory\n# there should be a MIDI directory that contains\n# the patch files for GUS playback. Patch sets used\n# with Timidity should work fine.\n\ngus=false\ngusrate=44100\ngusbase=240\ngusirq=5\ngusdma=3\nultradir=C:\\ULTRASND\n\n[speaker]\n# pcspeaker: Enable PC-Speaker emulation.\n# pcrate: Sample rate of the PC-Speaker sound generation.\n# Possible values: 44100, 48000, 32000, 22050, 16000, 11025, 8000, 49716.\n# tandy: Enable Tandy Sound System emulation. For 'auto', emulation is present only if machine is set to 'tandy'.\n# Possible values: auto, on, off.\n# tandyrate: Sample rate of the Tandy 3-Voice generation.\n# Possible values: 44100, 48000, 32000, 22050, 16000, 11025, 8000, 49716.\n# disney: Enable Disney Sound Source emulation. (Covox Voice Master and Speech Thing compatible).\n\npcspeaker=true\npcrate=44100\ntandy=auto\ntandyrate=44100\ndisney=true\n\n[joystick]\n# joysticktype: Type of joystick to emulate: auto (default), none,\n# 2axis (supports two joysticks),\n# 4axis (supports one joystick, first joystick used),\n# 4axis_2 (supports one joystick, second joystick used),\n# fcs (Thrustmaster), ch (CH Flightstick).\n# none disables joystick emulation.\n# auto chooses emulation depending on real joystick(s).\n# (Remember to reset dosbox's mapperfile if you saved it earlier)\n# Possible values: auto, 2axis, 4axis, 4axis_2, fcs, ch, none.\n# timed: enable timed intervals for axis. Experiment with this option, if your joystick drifts (away).\n# autofire: continuously fires as long as you keep the button pressed.\n# swap34: swap the 3rd and the 4th axis. can be useful for certain joysticks.\n# buttonwrap: enable button wrapping at the number of emulated buttons.\n\njoysticktype=auto\ntimed=true\nautofire=false\nswap34=false\nbuttonwrap=false\n\n[serial]\n# serial1: set type of device connected to com port.\n# Can be disabled, dummy, modem, nullmodem, directserial.\n# Additional parameters must be in the same line in the form of\n# parameter:value. Parameter for all types is irq (optional).\n# for directserial: realport (required), rxdelay (optional).\n# (realport:COM1 realport:ttyS0).\n# for modem: listenport (optional).\n# for nullmodem: server, rxdelay, txdelay, telnet, usedtr,\n# transparent, port, inhsocket (all optional).\n# Example: serial1=modem listenport:5000\n# Possible values: dummy, disabled, modem, nullmodem, directserial.\n# serial2: see serial1\n# Possible values: dummy, disabled, modem, nullmodem, directserial.\n# serial3: see serial1\n# Possible values: dummy, disabled, modem, nullmodem, directserial.\n# serial4: see serial1\n# Possible values: dummy, disabled, modem, nullmodem, directserial.\n\nserial1=dummy\nserial2=dummy\nserial3=disabled\nserial4=disabled\n\n[dos]\n# xms: Enable XMS support.\n# ems: Enable EMS support.\n# umb: Enable UMB support.\n# keyboardlayout: Language code of the keyboard layout (or none).\n\nxms=true\nems=true\numb=true\nkeyboardlayout=auto\n\n[ipx]\n# ipx: Enable ipx over UDP/IP emulation.\n\nipx=true\n"+(r=t.autoexec,"[autoexec]\necho off\nmount c .\nc:\n\ntype jsdos~1/readme.txt\necho on\n\n".concat(r.options.script.value,"\n\n# Generated using https://js-dos.com\n# █▀▀▀▀▀█ █ ▄▄▄▀▀█ █▀▀▀▀▀█\n# █ ███ █ ██▄ █ ▀ ▄ █ ███ █\n# █ ▀▀▀ █ ▄██ ▀ ▀▀█ █ ▀▀▀ █\n# ▀▀▀▀▀▀▀ ▀ █▄▀▄▀ █ ▀▀▀▀▀▀▀\n# █▀▄▄█▀▀▄▄ ▀ ▀█▄▄▄▄ ▀▄█▀█▀\n# █▀ ▀ ▀▀▄ █▀ ▄ ▄▀▀▀▄ █▀█▄\n# ▄ ▄▄ █▀▀▄ ▄▀▄▀▀█ ▀▀▄▀▀█▀\n# ▄▀▀█▀▀ █▀█▀█▀▀▄ ▀██▀█▄\n# ▀▀▀ ▀ ▀ █▄█ ▀█▄▄█▀▀▀█▀▀\n# █▀▀▀▀▀█ ▄▄▄ ▄ ▄ █ ▀ █▄▄▄▄\n# █ ███ █ ▀█▀▀▄▀▀▄████▀▀█▄█\n# █ ▀▀▀ █ ▄▀▀█▀█▀▄ ▀▀▄▄█▄█\n# ▀▀▀▀▀▀▀ ▀ ▀▀ ▀ ▀ ▀▀▀\n")),e.abrupt("return",Promise.resolve(n));case 6:case"end":return e.stop()}var r}),e)})))).apply(this,arguments)}function C(e){var t="";t+="[".concat(e.name,"]\n");var n,r=function(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,o,i=!0,a=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return i=e.done,e},e:function(e){a=!0,o=e},f:function(){try{i||null==r.return||r.return()}finally{if(a)throw o}}}}(Object.keys(e.options).sort());try{for(r.s();!(n=r.n()).done;){var o=n.value,i=e.options[o];t+="".concat(i.name,"=").concat(i.value,"\n")}}catch(e){r.e(e)}finally{r.f()}return t}n.AutoexecCategory=m,n.createDosConfig=y,n.toDosboxConf=function(e){return j.apply(this,arguments)}},{"core-js/modules/es6.array.find":101,"core-js/modules/es6.array.from":102,"core-js/modules/es6.array.iterator":103,"core-js/modules/es6.function.name":104,"core-js/modules/es6.number.constructor":109,"core-js/modules/es6.number.parse-int":110,"core-js/modules/es6.object.keys":111,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.string.starts-with":121,"core-js/modules/es6.symbol":122,"core-js/modules/es7.object.get-own-property-descriptors":126,"core-js/modules/es7.symbol.async-iterator":127,"core-js/modules/web.dom.iterable":128,"regenerator-runtime/runtime":129}],133:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}e("core-js/modules/es6.function.name"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var o=e("../../../protocol/messages-queue");function i(){var e;return e=regeneratorRuntime.mark((function e(t,n){var r,i,s,a,l;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=new o.MessagesQueue,i=r.handler.bind(r),a=function(e){var t=e.data;"ws-sync-sleep"===(null==t?void 0:t.name)&&t.props.sessionId===n&&postMessage({name:"wc-sync-sleep",props:t.props},"*")},(l={sessionId:n,sendMessageToServer:function(e,t){s.messageHandler({data:{name:e,props:t}})},initMessageHandler:function(e){i=e,r.sendTo(i)},exit:function(){"undefined"!=typeof window&&window.removeEventListener("message",a)}}).module=s={postMessage:function(e,t){i(e,t)}},"undefined"!=typeof window&&window.addEventListener("message",a,{passive:!0}),e.next=10,t.instantiate(s);case 10:return s.callMain([n]),e.abrupt("return",l);case 12:case"end":return e.stop()}}),e)})),(i=function(){var t=this,n=arguments;return new Promise((function(o,i){var s=e.apply(t,n);function a(e){r(s,o,i,a,l,"next",e)}function l(e){r(s,o,i,a,l,"throw",e)}a(void 0)}))}).apply(this,arguments)}n.dosDirect=function(e,t){return i.apply(this,arguments)}},{"../../../protocol/messages-queue":142,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"regenerator-runtime/runtime":129}],134:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}e("core-js/modules/es6.function.name"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var o=e("../../../protocol/messages-queue");function i(){var e;return e=regeneratorRuntime.mark((function e(t,n,r){var i,s,a,l;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=new o.MessagesQueue,s=i.handler.bind(i),(a=new Worker(t)).onerror=function(e){s("ws-err",{type:e.type,filename:e.filename,message:e.message})},a.onmessage=function(e){var t=e.data;void 0!==(null==t?void 0:t.name)&&s(t.name,t.props)},e.next=7,n.instantiate({});case 7:l={sessionId:r,sendMessageToServer:function(e,t){a.postMessage({name:e,props:t})},initMessageHandler:function(e){s=e,i.sendTo(s)},exit:function(){a.terminate()}};try{l.sendMessageToServer("wc-install",{module:n.wasmModule,sessionId:r})}catch(e){l.sendMessageToServer("wc-install",{sessionId:r})}return e.abrupt("return",l);case 10:case"end":return e.stop()}}),e)})),(i=function(){var t=this,n=arguments;return new Promise((function(o,i){var s=e.apply(t,n);function a(e){r(s,o,i,a,l,"next",e)}function l(e){r(s,o,i,a,l,"throw",e)}a(void 0)}))}).apply(this,arguments)}n.dosWorker=function(e,t,n){return i.apply(this,arguments)}},{"../../../protocol/messages-queue":142,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"regenerator-runtime/runtime":129}],135:[function(e,t,n){(function(t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r,o=function(e){return e&&e.__esModule?e:{default:e}}(e("./impl/emulators-impl"));(r=n.NetworkType||(n.NetworkType={}))[r.NETWORK_DOSBOX_IPX=0]="NETWORK_DOSBOX_IPX","undefined"!=typeof window&&(window.emulators=o.default),void 0!==t&&(t.emulators=o.default)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./impl/emulators-impl":138}],136:[function(e,t,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){s(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}e("core-js/modules/es7.object.get-own-property-descriptors"),e("core-js/modules/es6.symbol"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es6.array.iterator"),e("core-js/modules/es6.object.keys"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0}),n.HTTPRequest=function(e,t){return new Promise((function(n,r){new a(e,i(i({},t),{},{success:n,fail:function(e){r(new Error(e))}}))}))};var a=function(){function e(t,n){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.xhr=null,this.total=0,this.loaded=0,this.resource=t,this.options=n,this.options.method=n.method||"GET","GET"!==this.options.method)throw new Error("Method "+this.options.method+" is not supported");this.makeHttpRequest()}var t,n;return t=e,(n=[{key:"makeHttpRequest",value:function(){var e,t,n=this;this.xhr=new XMLHttpRequest,this.xhr.open(this.options.method||"GET",this.resource,!0),"POST"===this.options.method&&this.xhr.setRequestHeader("Content-type","application/x-www-form-urlencoded"),this.xhr.overrideMimeType("text/plain; charset=x-user-defined"),"function"==typeof(e=this.xhr).addEventListener&&e.addEventListener("progress",(function(e){if(n.total=e.total,n.loaded=e.loaded,n.options.progress)return n.options.progress(e.total,e.loaded)})),"function"==typeof(t=this.xhr).addEventListener&&t.addEventListener("error",(function(){if(n.options.fail)return n.options.fail("Unalbe to download '"+n.resource+"', code: "+n.xhr.status),delete n.options.fail})),this.xhr.onreadystatechange=function(){return n.onReadyStateChange()},this.options.responseType&&(this.xhr.responseType=this.options.responseType),this.xhr.send(this.options.data)}},{key:"onReadyStateChange",value:function(){var e=this.xhr;if(4===e.readyState)if(200===e.status){if(this.options.success){var t=Math.max(this.total,this.loaded);return void 0!==this.options.progress&&this.options.progress(t,t),this.options.success(e.response)}}else if(this.options.fail)return this.options.fail("Unable to download '"+this.resource+"', code: "+e.status),delete this.options.fail}}])&&r(t.prototype,n),e}()},{"core-js/modules/es6.array.iterator":103,"core-js/modules/es6.object.keys":111,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.symbol":122,"core-js/modules/es7.object.get-own-property-descriptors":126,"core-js/modules/web.dom.iterable":128}],137:[function(e,t,n){"use strict";function r(e){return function(e){if(Array.isArray(e))return s(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||i(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=i(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,o,s=!0,a=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return s=e.done,e},e:function(e){a=!0,o=e},f:function(){try{s||null==r.return||r.return()}finally{if(a)throw o}}}}function i(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/web.dom.iterable"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var l=function(){function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.onStdoutConsumers=[],this.delayedStdout=[],this.onFrameSizeConsumers=[],this.onFrameConsumers=[],this.onSoundPushConsumers=[],this.onExitConsumers=[],this.onMessageConsumers=[],this.delayedMessages=[],this.onNetworkConnectedConsumers=[],this.onNetworkDisconnectedConsumers=[],this.onStdout=function(e){if(t.onStdoutConsumers.push(e),1===t.onStdoutConsumers.length){var n,r=o(t.delayedStdout);try{for(r.s();!(n=r.n()).done;){var i=n.value;t.fireStdout(i)}}catch(e){r.e(e)}finally{r.f()}t.delayedStdout=[]}},this.onFrameSize=function(e){t.onFrameSizeConsumers.push(e)},this.onFrame=function(e){t.onFrameConsumers.push(e)},this.onSoundPush=function(e){t.onSoundPushConsumers.push(e)},this.onExit=function(e){t.onExitConsumers.push(e)},this.onMessage=function(e){if(t.onMessageConsumers.push(e),1===t.onMessageConsumers.length){var n,i=o(t.delayedMessages);try{for(i.s();!(n=i.n()).done;){var s=n.value;e.apply(void 0,[s.msgType].concat(r(s.args)))}}catch(e){i.e(e)}finally{i.f()}t.delayedMessages=[]}},this.fireStdout=function(e){if(0!==t.onStdoutConsumers.length){var n,r=o(t.onStdoutConsumers);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e)}catch(e){r.e(e)}finally{r.f()}}else t.delayedStdout.push(e)},this.fireFrameSize=function(e,n){var r,i=o(t.onFrameSizeConsumers);try{for(i.s();!(r=i.n()).done;)(0,r.value)(e,n)}catch(e){i.e(e)}finally{i.f()}},this.fireFrame=function(e,n){var r,i=o(t.onFrameConsumers);try{for(i.s();!(r=i.n()).done;)(0,r.value)(e,n)}catch(e){i.e(e)}finally{i.f()}},this.fireSoundPush=function(e){var n,r=o(t.onSoundPushConsumers);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e)}catch(e){r.e(e)}finally{r.f()}},this.fireExit=function(){var e,n=o(t.onExitConsumers);try{for(n.s();!(e=n.n()).done;)(0,e.value)()}catch(e){n.e(e)}finally{n.f()}t.onStdoutConsumers=[],t.onFrameSizeConsumers=[],t.onFrameConsumers=[],t.onSoundPushConsumers=[],t.onExitConsumers=[],t.onMessageConsumers=[]},this.fireMessage=function(e){for(var n=arguments.length,r=new Array(1<n?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];if(0!==t.onMessageConsumers.length){var s,a=o(t.onMessageConsumers);try{for(a.s();!(s=a.n()).done;)s.value.apply(void 0,[e].concat(r))}catch(e){a.e(e)}finally{a.f()}}else t.delayedMessages.push({msgType:e,args:r})},this.fireNetworkConnected=function(e,n,r){var i,s=o(t.onNetworkConnectedConsumers);try{for(s.s();!(i=s.n()).done;)(0,i.value)(e,n,r)}catch(e){s.e(e)}finally{s.f()}},this.fireNetworkDisconnected=function(e){var n,r=o(t.onNetworkDisconnectedConsumers);try{for(r.s();!(n=r.n()).done;)(0,n.value)(e)}catch(e){r.e(e)}finally{r.f()}}}var t,n;return t=e,(n=[{key:"onNetworkConnected",value:function(e){this.onNetworkConnectedConsumers.push(e)}},{key:"onNetworkDisconnected",value:function(e){this.onNetworkDisconnectedConsumers.push(e)}}])&&a(t.prototype,n),e}();n.CommandInterfaceEventsImpl=l},{"core-js/modules/es6.array.from":102,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.symbol":122,"core-js/modules/es7.symbol.async-iterator":127,"core-js/modules/web.dom.iterable":128}],138:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(o,i){var s=e.apply(t,n);function a(e){r(s,o,i,a,l,"next",e)}function l(e){r(s,o,i,a,l,"throw",e)}a(void 0)}))}}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("regenerator-runtime/runtime");var s=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:!0});var a=e("../build"),l=e("./modules"),c=s(e("../dos/bundle/dos-bundle")),u=e("../dos/dosbox/ts/direct"),d=e("../dos/dosbox/ts/worker"),f=s(e("../janus/janus-impl")),p=e("../protocol/protocol"),h=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.pathPrefix="",this.version=a.Build.version,this.wdosboxJs="wdosbox.js"}var t,n,r,s,h,m,y,g,v,b;return t=e,(n=[{key:"dosBundle",value:(b=o(regeneratorRuntime.mark((function e(){var t,n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.wasmModules();case 2:return t=e.sent,e.next=5,t.libzip();case 5:return n=e.sent,e.abrupt("return",new c.default(n));case 7:case"end":return e.stop()}}),e,this)}))),function(){return b.apply(this,arguments)})},{key:"dosboxNode",value:(v=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.dosboxDirect(t));case 1:case"end":return e.stop()}}),e,this)}))),function(e){return v.apply(this,arguments)})},{key:"dosboxDirect",value:(g=o(regeneratorRuntime.mark((function e(t){var n,r,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.wasmModules();case 2:return n=e.sent,e.next=5,n.dosbox();case 5:return r=e.sent,e.next=8,u.dosDirect(r,"session-"+Date.now());case 8:return o=e.sent,e.abrupt("return",this.backend(t,o));case 10:case"end":return e.stop()}}),e,this)}))),function(e){return g.apply(this,arguments)})},{key:"dosboxWorker",value:(y=o(regeneratorRuntime.mark((function e(t){var n,r,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.wasmModules();case 2:return n=e.sent,e.next=5,n.dosbox();case 5:return r=e.sent,e.next=8,d.dosWorker(this.pathPrefix+this.wdosboxJs,r,"session-"+Date.now());case 8:return o=e.sent,e.abrupt("return",this.backend(t,o));case 10:case"end":return e.stop()}}),e,this)}))),function(e){return y.apply(this,arguments)})},{key:"janus",value:(m=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",f.default(t));case 1:case"end":return e.stop()}}),e)}))),function(e){return m.apply(this,arguments)})},{key:"backend",value:(h=o(regeneratorRuntime.mark((function e(t,n){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new Promise((function(e,r){var o=new p.CommandInterfaceOverTransportLayer(Array.isArray(t)?t:[t],n,(function(t){null!==t?r(t):setTimeout((function(){return e(o)}),4)}))})));case 1:case"end":return e.stop()}}),e)}))),function(e,t){return h.apply(this,arguments)})},{key:"wasmModules",value:function(){var e=this;if(void 0!==this.wasmModulesPromise)return this.wasmModulesPromise;var t=function(){var t=o(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",new l.WasmModulesImpl(e.pathPrefix,e.wdosboxJs));case 1:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();return this.wasmModulesPromise=t(),this.wasmModulesPromise}},{key:"dosDirect",value:(s=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.dosboxDirect(t));case 1:case"end":return e.stop()}}),e,this)}))),function(e){return s.apply(this,arguments)})},{key:"dosWorker",value:(r=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.dosboxWorker(t));case 1:case"end":return e.stop()}}),e,this)}))),function(e){return r.apply(this,arguments)})}])&&i(t.prototype,n),e}());n.default=h},{"../build":130,"../dos/bundle/dos-bundle":131,"../dos/dosbox/ts/direct":133,"../dos/dosbox/ts/worker":134,"../janus/janus-impl":140,"../protocol/protocol":143,"./modules":139,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"regenerator-runtime/runtime":129}],139:[function(e,t,n){"use strict";function r(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==a.return||a.return()}finally{if(o)throw i}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return o(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function i(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t,n){return t&&s(e.prototype,t),n&&s(e,n),e}function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}e("core-js/modules/es6.array.from"),e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es6.array.iterator"),e("core-js/modules/es6.string.iterator"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.math.trunc"),e("core-js/modules/es6.math.clz32"),e("core-js/modules/es6.math.fround"),e("core-js/modules/es6.math.imul"),e("core-js/modules/es6.typed.uint8-array"),Object.defineProperty(n,"__esModule",{value:!0});var u=e("../http");n.host=new function e(){if(c(this,e),this.wasmSupported=!1,this.globals="undefined"==typeof window?{}:window,this.globals.exports||(this.globals.exports={}),this.globals.compiled||(this.globals.compiled={}),"object"===("undefined"==typeof WebAssembly?"undefined":l(WebAssembly))&&"function"==typeof WebAssembly.instantiate&&"function"==typeof WebAssembly.compile){var t=new WebAssembly.Module(Uint8Array.of(0,97,115,109,1,0,0,0));t instanceof WebAssembly.Module&&(this.wasmSupported=new WebAssembly.Instance(t)instanceof WebAssembly.Instance)}Math.imul&&-5===Math.imul(4294967295,5)||(Math.imul=function(e,t){var n=65535&e,r=65535&t;return n*r+((e>>>16)*r+n*(t>>>16)<<16)|0}),Math.imul=Math.imul,Math.fround||(Math.fround=function(e){return e}),Math.fround=Math.fround,Math.clz32||(Math.clz32=function(e){e>>>=0;for(var t=0;t<32;t++)if(e&1<<31-t)return t;return 32}),Math.clz32=Math.clz32,Math.trunc||(Math.trunc=function(e){return e<0?Math.ceil(e):Math.floor(e)}),Math.trunc=Math.trunc};var d=function(){function e(t,n){c(this,e),this.wasmSupported=!1,0<t.length&&"/"!==t[t.length-1]&&(t+="/"),this.pathPrefix=t,this.wdosboxJs=n}return a(e,[{key:"libzip",value:function(){return void 0!==this.libzipPromise||(this.libzipPromise=this.loadModule(this.pathPrefix+"wlibzip.js","WLIBZIP")),this.libzipPromise}},{key:"dosbox",value:function(){return void 0!==this.dosboxPromise||(this.dosboxPromise=this.loadModule(this.pathPrefix+this.wdosboxJs,"WDOSBOX")),this.dosboxPromise}},{key:"loadModule",value:function(e,t){return f(e,t,(function(){}))}}]),e}();function f(t,o,s){return"undefined"==typeof XMLHttpRequest?function(t,r){if(void 0!==n.host.globals.compiled[r])return n.host.globals.compiled[r];var o=e(t),i=Promise.resolve(new p(o));return r&&(n.host.globals.compiled[r]=i),i}(t,o):function(e,t,o){if(void 0!==n.host.globals.compiled[t])return n.host.globals.compiled[t];function s(){var a;return a=regeneratorRuntime.mark((function i(){var s,a,l,c,d,f,p,m,y,g,v,b;return regeneratorRuntime.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:if(s=e.lastIndexOf("/"),a=e.indexOf("w",s),l=a===s+1&&0<=a,n.host.wasmSupported&&l){i.next=5;break}throw new Error("Starting from js-dos 6.22.60 js environment is not supported");case 5:return c=e.substr(0,e.lastIndexOf(".js"))+".wasm",d=u.HTTPRequest(c,{responseType:"arraybuffer",progress:function(t,n){o("Resolving DosBox ("+e+")",t,n)}}),f=u.HTTPRequest(e,{progress:function(e,t){o("Resolving DosBox",e,t)}}),i.next=10,Promise.all([d,f]);case 10:return p=i.sent,m=r(p,2),y=m[0],g=m[1],i.next=16,WebAssembly.compile(y);case 16:return v=i.sent,b=function(e,t){e.env=e.env||{},WebAssembly.instantiate(v,e).then((function(e){return t(e,v)}))},eval.call(window,g),i.abrupt("return",new h(v,n.host.globals.exports[t],b));case 20:case"end":return i.stop()}}),i)})),(s=function(){var e=this,t=arguments;return new Promise((function(n,r){var o=a.apply(e,t);function s(e){i(o,n,r,s,l,"next",e)}function l(e){i(o,n,r,s,l,"throw",e)}s(void 0)}))}).apply(this,arguments)}var a=function(){return s.apply(this,arguments)}();return t&&(n.host.globals.compiled[t]=a),a}(t,o,s)}n.WasmModulesImpl=d,n.loadWasmModule=f;var p=function(){function e(t){c(this,e),this.emModule=t}return a(e,[{key:"instantiate",value:function(e){var t=this;return new Promise((function(n){e.onRuntimeInitialized=function(){n()},new t.emModule(e)}))}}]),e}(),h=function(){function e(t,n,r){c(this,e),this.wasmModule=t,this.module=n,this.instantiateWasm=r}return a(e,[{key:"instantiate",value:function(e){var t=this;return new Promise((function(n){e.instantiateWasm=t.instantiateWasm,e.onRuntimeInitialized=function(){n()},new t.module(e)}))}}]),e}()},{"../http":136,"core-js/modules/es6.array.from":102,"core-js/modules/es6.array.iterator":103,"core-js/modules/es6.function.name":104,"core-js/modules/es6.math.clz32":105,"core-js/modules/es6.math.fround":106,"core-js/modules/es6.math.imul":107,"core-js/modules/es6.math.trunc":108,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.symbol":122,"core-js/modules/es6.typed.uint8-array":124,"core-js/modules/es7.symbol.async-iterator":127,"core-js/modules/web.dom.iterable":128,"regenerator-runtime/runtime":129}],140:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function o(e){return function(){var t=this,n=arguments;return new Promise((function(o,i){var s=e.apply(t,n);function a(e){r(s,o,i,a,l,"next",e)}function l(e){r(s,o,i,a,l,"throw",e)}a(void 0)}))}}function i(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==a.return||a.return()}finally{if(o)throw i}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/es6.typed.uint8-array"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/web.dom.iterable"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.number.constructor"),e("core-js/modules/es6.number.parse-int"),e("core-js/modules/es6.regexp.split"),e("core-js/modules/es6.string.starts-with"),Object.defineProperty(n,"__esModule",{value:!0});var l=e("../impl/ci-impl");function c(e,t){var n="";return function r(o){var i=o.indexOf("\n");if(-1===i)n+=o;else{var s=n+o.substr(0,i);n="";try{e(function(e){for(var t=atob(e),n=new Uint8Array(t.length),r=0;r<n.length;r++)n[r]=t.charCodeAt(r);return(new TextDecoder).decode(n)}(s))}catch(r){t(r)}r(o.substr(i+1))}}}var u=function(){function e(t,n){var r=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.live=!0,this.startedAt=Date.now(),this.exitResolveFn=function(){},this.configResolveFn=function(){},this.handleResolveFn=function(){},this.keyMatrix={},this.frameWidth=0,this.frameHeight=0,this.eventQueue="",this.eventIntervalId=-1,this.rttIntervalId=-1,this.logIntervalId=-1,this.logColor="not set",this.logWhiteMs=0,this.logRedMs=0,this.logYellowMs=0,this.onDataMessage=function(e){if(e.startsWith("config="))r.configResolveFn(JSON.parse(e.substr("config=".length)));else if(e.startsWith("frame=")){var t=i(e.substr("frame=".length).split("x"),2),n=t[0],o=t[1];r.frameWidth=Number.parseInt(n,10)||0,r.frameHeight=Number.parseInt(o,10)||0}else if(e.startsWith("rtt=")){var s,a=i(e.substr("rtt=".length).split(" "),3),l=a[0],c=a[1],u=a[2],d=Number.parseInt(c,10),f=Number.parseInt(u,10),p=Date.now(),h=(null===(s=r.handle)||void 0===s?void 0:s.getBitrate())||"0 kbits/sec",m=Number.parseInt(h.split(" ")[0],10);r.sendPipeMessage("rtt-data",Date.now(),d,f,p,m),l===r.opaqueId&&r.eventsImpl.fireStdout("rtt-data="+(p-d)+" "+m)}else if(e.startsWith("log-visual-"))switch(e){case"log-visual-white":r.eventsImpl.fireStdout("yellow-frame:"+(Date.now()-r.logYellowMs));break;case"log-visual-red":r.eventsImpl.fireStdout("white-frame:"+(Date.now()-r.logWhiteMs));break;case"log-visual-yellow":r.eventsImpl.fireStdout("red-frame:"+(Date.now()-r.logRedMs))}else if(e.startsWith("log-command-"))switch(e){case"log-command-white":r.eventsImpl.fireStdout("yellow-pipe:"+(Date.now()-r.logYellowMs));break;case"log-command-red":r.eventsImpl.fireStdout("white-pipe:"+(Date.now()-r.logWhiteMs));break;case"log-command-yellow":r.eventsImpl.fireStdout("red-pipe:"+(Date.now()-r.logRedMs))}else r.eventsImpl.fireStdout(e)},this.onJanusMessage=function(e,t,n){null!=n&&e.createAnswer({jsep:n,media:{audioSend:!1,videoSend:!1,data:!0},success:function(t){r.fireMessage("started"),e.send({message:{request:"start"},jsep:t})},error:r.onError})},this.onError=function(e){r.fireMessage("error",e)},this.eventsImpl=new l.CommandInterfaceEventsImpl,this.janus=t,this.opaqueId=n,this.exitPromise=new Promise((function(e){r.exitResolveFn=e})),this.configPromise=new Promise((function(e){r.configResolveFn=e})),this.handlePromise=new Promise((function(e,t){r.handleResolveFn=function(n){r.handle=n,r.live?(setTimeout((function(){r.live&&n.data({text:"pipe "+r.opaqueId+" config"})}),1e3),r.config().then((function(){r.live&&(r.eventIntervalId=setInterval((function(){r.sendEventsData(n)}),8),r.rttIntervalId=setInterval((function(){r.sendPipeMessage("rtt",Date.now())}),1e3))})),e(n)):t(new Error("exit() was called"))}})),this.attach()}var t,n,r,s;return t=e,(n=[{key:"fireMessage",value:function(e){for(var t,n=arguments.length,r=new Array(1<n?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];(t=this.eventsImpl).fireMessage.apply(t,[e].concat(r))}},{key:"attach",value:function(){var e,t=this;this.janus.attach({plugin:"janus.plugin.streaming",opaqueId:this.opaqueId,error:this.onError,success:function(n){e=n,t.fireMessage("attached"),n.send({message:{request:"watch",id:1}})},onmessage:function(n,r){t.onJanusMessage(e,n,r)},onremotestream:function(e){t.fireMessage("onremotestream",e)},ondataopen:function(){return t.handleResolveFn(e)},ondata:c(this.onDataMessage,this.onError)})}},{key:"onDestroyed",value:function(){this.fireMessage("destroyed"),this.exitResolveFn()}},{key:"config",value:(s=o(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.configPromise);case 1:case"end":return e.stop()}}),e,this)}))),function(){return s.apply(this,arguments)})},{key:"width",value:function(){return this.frameWidth}},{key:"height",value:function(){return this.frameHeight}},{key:"soundFrequency",value:function(){return 44100}},{key:"screenshot",value:function(){return Promise.reject(new Error("Not supported"))}},{key:"simulateKeyPress",value:function(){for(var e=this,t=Date.now()-this.startedAt,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];r.forEach((function(n){return e.addKey(n,!0,t)})),r.forEach((function(n){return e.addKey(n,!1,16+t)}))}},{key:"sendKeyEvent",value:function(e,t){this.addKey(e,t,Date.now()-this.startedAt)}},{key:"addKey",value:function(e,t,n){if(!0===this.keyMatrix[e]!==t&&(this.keyMatrix[e]=t,this.sendPipeMessage("k"+(t?"down":"up"),e,n),-1!==this.logIntervalId&&t))switch(this.logColor){case"white":this.logWhiteMs=Date.now();break;case"red":this.logRedMs=Date.now();break;case"yellow":this.logYellowMs=Date.now()}}},{key:"sendMouseMotion",value:function(e,t){this.sendPipeMessage("mmove",e,t,Date.now()-this.startedAt)}},{key:"sendMouseRelativeMotion",value:function(){throw new Error("not implemented")}},{key:"sendMouseButton",value:function(e,t){this.sendPipeMessage("m"+(t?"down":"up"),e,Date.now()-this.startedAt)}},{key:"sendMouseSync",value:function(){this.sendPipeMessage("msync",Date.now()-this.startedAt)}},{key:"logVisual",value:function(e){var t=this;this.sendPipeMessage("log-visual-on");var n=document.createElement("canvas"),r=n.getContext("2d");n.width=1,n.height=1,this.logIntervalId=setInterval(o(regeneratorRuntime.mark((function n(){var o,i,s,a,l;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(i=Date.now(),null!=r&&r.drawImage(e,0,0,1,1,0,0,1,1),s=null==r||null===(o=r.getImageData(0,0,1,1))||void 0===o?void 0:o.data,a=Date.now()-i,l="not set",200<s[0]&&200<s[1]&&200<s[2]?l="white":200<s[0]&&s[1]<200&&s[2]<200?l="red":200<s[0]&&200<s[1]&&s[2]<200&&(l="yellow"),l===t.logColor){n.next=17;break}n.t0=l,n.next="white"===n.t0?10:"red"===n.t0?12:"yellow"===n.t0?14:16;break;case 10:return t.eventsImpl.fireStdout("yellow-stream:"+(Date.now()-t.logYellowMs-a)),n.abrupt("break",16);case 12:return t.eventsImpl.fireStdout("white-stream:"+(Date.now()-t.logWhiteMs-a)),n.abrupt("break",16);case 14:return t.eventsImpl.fireStdout("red-stream:"+(Date.now()-t.logRedMs-a)),n.abrupt("break",16);case 16:t.logColor=l;case 17:case"end":return n.stop()}}),n)}))),16)}},{key:"sendPipeMessage",value:function(){this.eventQueue+="pipe "+this.opaqueId;for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];for(var r=0,o=t;r<o.length;r++){var i=o[r];this.eventQueue+=" "+i}this.eventQueue+="\n"}},{key:"sendEventsData",value:(r=o(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(0===this.eventQueue.length)return e.abrupt("return");e.next=2;break;case 2:t.data({text:this.eventQueue}),this.eventQueue="";case 4:case"end":return e.stop()}}),e,this)}))),function(e){return r.apply(this,arguments)})},{key:"persist",value:function(){return Promise.reject(new Error("Not supported"))}},{key:"pause",value:function(){console.warn("pause/resume is not implemented")}},{key:"resume",value:function(){}},{key:"mute",value:function(){console.warn("mute/unmute is not implemented")}},{key:"unmute",value:function(){}},{key:"exit",value:function(){return this.live=!1,clearInterval(this.logIntervalId),this.logIntervalId=-1,clearInterval(this.eventIntervalId),this.eventIntervalId=-1,clearInterval(this.rttIntervalId),this.rttIntervalId=-1,this.janus.destroy(),this.exitPromise}},{key:"events",value:function(){return this.eventsImpl}},{key:"networkConnect",value:function(){return Promise.reject("Not supported")}},{key:"networkDisconnect",value:function(){return Promise.reject("Not supported")}}])&&a(t.prototype,n),e}();n.default=function(e,t){var n=t||window.Janus;return void 0===n?Promise.reject(new Error("Janus is not defined, you should load janus.js before this")):n.isWebrtcSupported()?new Promise((function(t,r){var o=null,i={error:function(e){null===o?r(e):o.onError(e)},destroyed:function(){null!==o&&o.onDestroyed()}},s={server:e,success:function(){o=new u(a,"js-dos-"+n.randomString(12)),t(o)},error:i.error,destroyed:i.destroyed,destroyOnUnload:!0},a=new n(s)})):Promise.reject(new Error("WebRTC not supported"))}},{"../impl/ci-impl":137,"core-js/modules/es6.array.from":102,"core-js/modules/es6.function.name":104,"core-js/modules/es6.number.constructor":109,"core-js/modules/es6.number.parse-int":110,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.split":118,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.string.starts-with":121,"core-js/modules/es6.symbol":122,"core-js/modules/es6.typed.uint8-array":124,"core-js/modules/es7.symbol.async-iterator":127,"core-js/modules/web.dom.iterable":128,"regenerator-runtime/runtime":129}],141:[function(e,t,n){"use strict";function r(e,t,n,r,o,i,s){try{var a=e[i](s),l=a.value}catch(e){return void n(e)}a.done?t(l):Promise.resolve(l).then(r,o)}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/es6.regexp.constructor"),e("core-js/modules/es6.regexp.replace"),e("regenerator-runtime/runtime"),e("core-js/modules/es6.typed.uint8-array"),e("core-js/modules/es6.regexp.split"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.module=t,this.home=n,this.module.callMain([]),this.chdirToHome()}var t,n,i,s;return t=e,(n=[{key:"zipFromFs",value:function(e){var t=0<arguments.length&&void 0!==e?e:-1;this.chdirToHome();var n=this.module._zip_from_fs(t);if(0===n)return Promise.reject(new Error("Can't create zip, see more info in logs"));var r=this.module.HEAPU32[n/4],o=this.module.HEAPU8.slice(n+4,n+4+r);return this.module._free(n),Promise.resolve(o)}},{key:"zipToFs",value:function(e,t){var n=1<arguments.length&&void 0!==t?t:"/";n=this.normalizeFilename(n);var r=this.normalizeFilename(n).split("/");this.createPath(r,0,r.length),this.chdir(n);var o=new Uint8Array(e),i=this.module._malloc(o.length);this.module.HEAPU8.set(o,i);var s=this.module._zip_to_fs(i,o.length);return this.module._free(i),this.chdirToHome(),0===s?Promise.resolve():Promise.reject(new Error("Can't extract zip, retcode "+s+", see more info in logs"))}},{key:"writeFile",value:function(e,t){e=this.normalizeFilename(e),t instanceof ArrayBuffer&&(t=new Uint8Array(t));var n=e.split("/");if(0===n.length)throw new Error("Can't create file '"+e+"', because it's not valid file path");var r=n[n.length-1].trim();if(0===r.length)throw new Error("Can't create file '"+e+"', because file name is empty");var o=this.createPath(n,0,n.length-1);this.module.FS.writeFile(o+"/"+r,t)}},{key:"readFile",value:(i=regeneratorRuntime.mark((function e(t){var n,r=arguments;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=1<r.length&&void 0!==r[1]?r[1]:"utf8",t=this.normalizeFilename(t),e.abrupt("return",this.module.FS.readFile(t,{encoding:n}));case 3:case"end":return e.stop()}}),e,this)})),s=function(){var e=this,t=arguments;return new Promise((function(n,o){var s=i.apply(e,t);function a(e){r(s,n,o,a,l,"next",e)}function l(e){r(s,n,o,a,l,"throw",e)}a(void 0)}))},function(e){return s.apply(this,arguments)})},{key:"exists",value:function(e){e=this.normalizeFilename(e);try{return this.module.FS.lookupPath(e),!0}catch(e){return!1}}},{key:"destroy",value:function(){try{this.module._libzip_destroy()}catch(e){return e}}},{key:"normalizeFilename",value:function(e){for(e=e.replace(new RegExp("^[a-zA-z]+:"),"").replace(new RegExp("\\\\","g"),"/");"/"===e[0];)e=e.substr(1);return e}},{key:"createPath",value:function(e,t,n){for(var r=".",o=t;o<n;++o){var i=e[o].trim();0!==i.length&&(this.module.FS.createPath(r,i,!0,!0),r=r+"/"+i)}return r}},{key:"chdirToHome",value:function(){this.module.FS.chdir(this.home)}},{key:"chdir",value:function(e){this.module.FS.chdir(this.home+"/"+e)}}])&&o(t.prototype,n),e}();n.default=i},{"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.constructor":114,"core-js/modules/es6.regexp.replace":117,"core-js/modules/es6.regexp.split":118,"core-js/modules/es6.typed.uint8-array":124,"regenerator-runtime/runtime":129}],142:[function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/web.dom.iterable"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.object.to-string"),e("core-js/modules/es6.function.name"),Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.messages=[]}var t,n;return t=e,(n=[{key:"handler",value:function(e,t){this.messages.push({name:e,props:t})}},{key:"sendTo",value:function(e){var t,n=function(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i,s=!0,a=!1;return{s:function(){o=e[Symbol.iterator]()},n:function(){var e=o.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==o.return||o.return()}finally{if(a)throw i}}}}(this.messages);try{for(n.s();!(t=n.n()).done;){var o=t.value;e(o.name,o.props)}}catch(e){n.e(e)}finally{n.f()}this.messages=[]}}])&&o(t.prototype,n),e}();n.MessagesQueue=i},{"core-js/modules/es6.array.from":102,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.symbol":122,"core-js/modules/es7.symbol.async-iterator":127,"core-js/modules/web.dom.iterable":128}],143:[function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e("core-js/modules/web.dom.iterable"),e("core-js/modules/es7.symbol.async-iterator"),e("core-js/modules/es6.symbol"),e("core-js/modules/es6.string.iterator"),e("core-js/modules/es6.array.from"),e("core-js/modules/es6.function.name"),e("core-js/modules/es6.regexp.to-string"),e("core-js/modules/es6.string.starts-with"),e("core-js/modules/es6.typed.uint8-clamped-array"),e("core-js/modules/es6.typed.float32-array"),e("core-js/modules/es6.typed.uint8-array"),e("core-js/modules/es6.promise"),e("core-js/modules/es6.object.to-string"),Object.defineProperty(n,"__esModule",{value:!0});var i=e("../impl/ci-impl"),s=function(){function e(t,n,r){var o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.startedAt=Date.now(),this.frameWidth=0,this.frameHeight=0,this.rgb=null,this.rgba=null,this.freq=0,this.eventsImpl=new i.CommandInterfaceEventsImpl,this.keyMatrix={},this.configResolve=function(){},this.panicMessages=[],this.connectPromise=null,this.connectResolve=function(){},this.connectReject=function(){},this.disconnectPromise=null,this.disconnectResolve=function(){},this.bundles=t,this.transport=n,this.ready=r,this.configPromise=new Promise((function(e){return o.configResolve=e})),this.transport.initMessageHandler(this.onServerMessage.bind(this))}var t,n;return t=e,(n=[{key:"sendClientMessage",value:function(e,t){(t=t||{}).sessionId=t.sessionId||this.transport.sessionId,this.transport.sendMessageToServer(e,t)}},{key:"onServerMessage",value:function(e,t){if(!(void 0===e||e.length<3||"w"!==e[0]||"s"!==e[1]||"-"!==e[2])&&void 0!==t&&t.sessionId===this.transport.sessionId)switch(e){case"ws-ready":this.sharedMemory=t.sharedMemory,this.sendClientMessage("wc-run",{bundles:this.bundles}),delete this.bundles;break;case"ws-server-ready":0<this.panicMessages.length?(void 0!==this.transport.exit&&this.transport.exit(),this.ready(new Error(JSON.stringify(this.panicMessages)))):this.ready(null),delete this.ready;break;case"ws-frame-set-size":this.onFrameSize(t.width,t.height);break;case"ws-update-lines":this.onFrameLines(t.lines,t.rgba);break;case"ws-exit":this.onExit();break;case"ws-log":this.onLog(t.tag,t.message);break;case"ws-warn":this.onWarn(t.tag,t.message);break;case"ws-err":this.onErr(t.tag,t.message);break;case"ws-stdout":this.onStdout(t.message);break;case"ws-persist":this.onPersist(t.bundle);break;case"ws-sound-init":this.onSoundInit(t.freq,t.directSound);break;case"ws-sound-push":this.onSoundPush(t.samples);break;case"ws-config":this.onConfig(JSON.parse(t.content));break;case"ws-sync-sleep":this.sendClientMessage("wc-sync-sleep",t);break;case"ws-connected":this.connectResolve(),this.connectPromise=null,this.connectResolve=function(){},this.connectReject=function(){},this.eventsImpl.fireNetworkConnected(t.networkType,t.address,t.port);break;case"ws-disconnected":null!==this.connectPromise?(this.connectReject(),this.connectPromise=null,this.connectResolve=function(){},this.connectReject=function(){}):(this.disconnectResolve(),this.disconnectPromise=null,this.disconnectResolve=function(){}),this.eventsImpl.fireNetworkDisconnected(t.networkType);break;default:console.log("Unknown server message (ws):",e)}}},{key:"onConfig",value:function(e){this.configResolve(e)}},{key:"onFrameSize",value:function(e,t){this.frameWidth===e&&this.frameHeight===t||(this.frameWidth=e,this.frameHeight=t,void 0===this.sharedMemory&&(this.rgb=new Uint8Array(e*t*3)),this.eventsImpl.fireFrameSize(e,t))}},{key:"onFrameLines",value:function(e,t){if(void 0!==this.sharedMemory)this.rgba=new Uint8Array(this.sharedMemory,t,this.frameWidth*this.frameHeight*4);else{var n,o=function(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))){var t=0,n=function(){};return{s:n,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i,s=!0,a=!1;return{s:function(){o=e[Symbol.iterator]()},n:function(){var e=o.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==o.return||o.return()}finally{if(a)throw i}}}}(e);try{for(o.s();!(n=o.n()).done;){var i=n.value;this.rgb.set(i.heapu8,i.start*this.frameWidth*3)}}catch(e){o.e(e)}finally{o.f()}}this.eventsImpl.fireFrame(this.rgb,this.rgba)}},{key:"onSoundInit",value:function(e,t){if(this.freq=e,this.directSound=t,void 0!==this.directSound)for(var n=0;n<this.directSound.ringSize;++n)this.directSound.buffer[n]=new Float32Array(this.directSound.buffer[n])}},{key:"onSoundPush",value:function(e){this.eventsImpl.fireSoundPush(e)}},{key:"onLog",value:function(e,t){this.eventsImpl.fireMessage("log","["+e+"]"+t)}},{key:"onWarn",value:function(e,t){this.eventsImpl.fireMessage("warn","["+e+"]"+t)}},{key:"onErr",value:function(e,t){"panic"===e?(this.panicMessages.push(t),console.error("["+e+"]"+t)):console.log("["+e+"]"+t),this.eventsImpl.fireMessage("error","["+e+"]"+t)}},{key:"onStdout",value:function(e){this.eventsImpl.fireStdout(e)}},{key:"config",value:function(){return this.configPromise}},{key:"width",value:function(){return this.frameWidth}},{key:"height",value:function(){return this.frameHeight}},{key:"soundFrequency",value:function(){return this.freq}},{key:"screenshot",value:function(){if(null===this.rgb&&null===this.rgba)return Promise.reject(new Error("No frame received"));for(var e=new Uint8ClampedArray(this.frameWidth*this.frameHeight*4),t=null!==this.rgb?this.rgb:this.rgba,n=0,r=0;r<e.length;)e[r++]=t[n++],e[r++]=t[n++],e[r++]=t[n++],e[r++]=255,t.length===e.length&&n++;return Promise.resolve(new ImageData(e,this.frameWidth,this.frameHeight))}},{key:"simulateKeyPress",value:function(){for(var e=this,t=Date.now()-this.startedAt,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];r.forEach((function(n){return e.addKey(n,!0,t)})),r.forEach((function(n){return e.addKey(n,!1,16+t)}))}},{key:"sendKeyEvent",value:function(e,t){this.addKey(e,t,Date.now()-this.startedAt)}},{key:"addKey",value:function(e,t,n){!0===this.keyMatrix[e]!==t&&(this.keyMatrix[e]=t,this.sendClientMessage("wc-add-key",{key:e,pressed:t,timeMs:n}))}},{key:"sendMouseMotion",value:function(e,t){this.sendClientMessage("wc-mouse-move",{x:e,y:t,relative:!1,timeMs:Date.now()-this.startedAt})}},{key:"sendMouseRelativeMotion",value:function(e,t){this.sendClientMessage("wc-mouse-move",{x:e,y:t,relative:!0,timeMs:Date.now()-this.startedAt})}},{key:"sendMouseButton",value:function(e,t){this.sendClientMessage("wc-mouse-button",{button:e,pressed:t,timeMs:Date.now()-this.startedAt})}},{key:"sendMouseSync",value:function(){this.sendClientMessage("wc-mouse-sync",{timeMs:Date.now()-this.startedAt})}},{key:"persist",value:function(){var e=this;if(void 0!==this.persistPromise)return this.persistPromise;var t=new Promise((function(t){return e.persistResolve=t}));return this.persistPromise=t,this.sendClientMessage("wc-pack-fs-to-bundle"),t}},{key:"onPersist",value:function(e){this.persistResolve&&(this.persistResolve(e),delete this.persistPromise,delete this.persistResolve)}},{key:"pause",value:function(){this.sendClientMessage("wc-pause")}},{key:"resume",value:function(){this.sendClientMessage("wc-resume")}},{key:"mute",value:function(){this.sendClientMessage("wc-mute")}},{key:"unmute",value:function(){this.sendClientMessage("wc-unmute")}},{key:"exit",value:function(){var e=this;return void 0!==this.exitPromise||(this.exitPromise=new Promise((function(t){return e.exitResolve=t})),this.exitPromise.then((function(){e.events().fireExit()})),this.resume(),this.sendClientMessage("wc-exit")),this.exitPromise}},{key:"onExit",value:function(){void 0!==this.transport.exit&&this.transport.exit(),this.exitResolve&&(this.exitResolve(),delete this.exitPromise,delete this.exitResolve)}},{key:"events",value:function(){return this.eventsImpl}},{key:"networkConnect",value:function(e,t,n){var r=this;return null!==this.connectPromise||null!==this.disconnectPromise?Promise.reject(new Error("Already prefoming connection or disconnection...")):(this.connectPromise=new Promise((function(o,i){t.startsWith("wss://")||t.startsWith("ws://")||(t=("http:"===window.location.protocol?"ws://":"wss://")+t),r.connectResolve=o,r.connectReject=i,r.sendClientMessage("wc-connect",{networkType:e,address:t,port:n})})),this.connectPromise)}},{key:"networkDisconnect",value:function(e){var t=this;return null!==this.connectPromise||null!==this.disconnectPromise?Promise.reject(new Error("Already prefoming connection or disconnection...")):(this.disconnectPromise=new Promise((function(n){t.disconnectResolve=n,t.sendClientMessage("wc-disconnect",{networkType:e})})),this.disconnectPromise)}}])&&o(t.prototype,n),e}();n.CommandInterfaceOverTransportLayer=s},{"../impl/ci-impl":137,"core-js/modules/es6.array.from":102,"core-js/modules/es6.function.name":104,"core-js/modules/es6.object.to-string":112,"core-js/modules/es6.promise":113,"core-js/modules/es6.regexp.to-string":119,"core-js/modules/es6.string.iterator":120,"core-js/modules/es6.string.starts-with":121,"core-js/modules/es6.symbol":122,"core-js/modules/es6.typed.float32-array":123,"core-js/modules/es6.typed.uint8-array":124,"core-js/modules/es6.typed.uint8-clamped-array":125,"core-js/modules/es7.symbol.async-iterator":127,"core-js/modules/web.dom.iterable":128}]},{},[135]),function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).zip={})}(this,(function(e){"use strict";const t=-2,n=-3,r=-5,o=[0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535],i=[96,7,256,0,8,80,0,8,16,84,8,115,82,7,31,0,8,112,0,8,48,0,9,192,80,7,10,0,8,96,0,8,32,0,9,160,0,8,0,0,8,128,0,8,64,0,9,224,80,7,6,0,8,88,0,8,24,0,9,144,83,7,59,0,8,120,0,8,56,0,9,208,81,7,17,0,8,104,0,8,40,0,9,176,0,8,8,0,8,136,0,8,72,0,9,240,80,7,4,0,8,84,0,8,20,85,8,227,83,7,43,0,8,116,0,8,52,0,9,200,81,7,13,0,8,100,0,8,36,0,9,168,0,8,4,0,8,132,0,8,68,0,9,232,80,7,8,0,8,92,0,8,28,0,9,152,84,7,83,0,8,124,0,8,60,0,9,216,82,7,23,0,8,108,0,8,44,0,9,184,0,8,12,0,8,140,0,8,76,0,9,248,80,7,3,0,8,82,0,8,18,85,8,163,83,7,35,0,8,114,0,8,50,0,9,196,81,7,11,0,8,98,0,8,34,0,9,164,0,8,2,0,8,130,0,8,66,0,9,228,80,7,7,0,8,90,0,8,26,0,9,148,84,7,67,0,8,122,0,8,58,0,9,212,82,7,19,0,8,106,0,8,42,0,9,180,0,8,10,0,8,138,0,8,74,0,9,244,80,7,5,0,8,86,0,8,22,192,8,0,83,7,51,0,8,118,0,8,54,0,9,204,81,7,15,0,8,102,0,8,38,0,9,172,0,8,6,0,8,134,0,8,70,0,9,236,80,7,9,0,8,94,0,8,30,0,9,156,84,7,99,0,8,126,0,8,62,0,9,220,82,7,27,0,8,110,0,8,46,0,9,188,0,8,14,0,8,142,0,8,78,0,9,252,96,7,256,0,8,81,0,8,17,85,8,131,82,7,31,0,8,113,0,8,49,0,9,194,80,7,10,0,8,97,0,8,33,0,9,162,0,8,1,0,8,129,0,8,65,0,9,226,80,7,6,0,8,89,0,8,25,0,9,146,83,7,59,0,8,121,0,8,57,0,9,210,81,7,17,0,8,105,0,8,41,0,9,178,0,8,9,0,8,137,0,8,73,0,9,242,80,7,4,0,8,85,0,8,21,80,8,258,83,7,43,0,8,117,0,8,53,0,9,202,81,7,13,0,8,101,0,8,37,0,9,170,0,8,5,0,8,133,0,8,69,0,9,234,80,7,8,0,8,93,0,8,29,0,9,154,84,7,83,0,8,125,0,8,61,0,9,218,82,7,23,0,8,109,0,8,45,0,9,186,0,8,13,0,8,141,0,8,77,0,9,250,80,7,3,0,8,83,0,8,19,85,8,195,83,7,35,0,8,115,0,8,51,0,9,198,81,7,11,0,8,99,0,8,35,0,9,166,0,8,3,0,8,131,0,8,67,0,9,230,80,7,7,0,8,91,0,8,27,0,9,150,84,7,67,0,8,123,0,8,59,0,9,214,82,7,19,0,8,107,0,8,43,0,9,182,0,8,11,0,8,139,0,8,75,0,9,246,80,7,5,0,8,87,0,8,23,192,8,0,83,7,51,0,8,119,0,8,55,0,9,206,81,7,15,0,8,103,0,8,39,0,9,174,0,8,7,0,8,135,0,8,71,0,9,238,80,7,9,0,8,95,0,8,31,0,9,158,84,7,99,0,8,127,0,8,63,0,9,222,82,7,27,0,8,111,0,8,47,0,9,190,0,8,15,0,8,143,0,8,79,0,9,254,96,7,256,0,8,80,0,8,16,84,8,115,82,7,31,0,8,112,0,8,48,0,9,193,80,7,10,0,8,96,0,8,32,0,9,161,0,8,0,0,8,128,0,8,64,0,9,225,80,7,6,0,8,88,0,8,24,0,9,145,83,7,59,0,8,120,0,8,56,0,9,209,81,7,17,0,8,104,0,8,40,0,9,177,0,8,8,0,8,136,0,8,72,0,9,241,80,7,4,0,8,84,0,8,20,85,8,227,83,7,43,0,8,116,0,8,52,0,9,201,81,7,13,0,8,100,0,8,36,0,9,169,0,8,4,0,8,132,0,8,68,0,9,233,80,7,8,0,8,92,0,8,28,0,9,153,84,7,83,0,8,124,0,8,60,0,9,217,82,7,23,0,8,108,0,8,44,0,9,185,0,8,12,0,8,140,0,8,76,0,9,249,80,7,3,0,8,82,0,8,18,85,8,163,83,7,35,0,8,114,0,8,50,0,9,197,81,7,11,0,8,98,0,8,34,0,9,165,0,8,2,0,8,130,0,8,66,0,9,229,80,7,7,0,8,90,0,8,26,0,9,149,84,7,67,0,8,122,0,8,58,0,9,213,82,7,19,0,8,106,0,8,42,0,9,181,0,8,10,0,8,138,0,8,74,0,9,245,80,7,5,0,8,86,0,8,22,192,8,0,83,7,51,0,8,118,0,8,54,0,9,205,81,7,15,0,8,102,0,8,38,0,9,173,0,8,6,0,8,134,0,8,70,0,9,237,80,7,9,0,8,94,0,8,30,0,9,157,84,7,99,0,8,126,0,8,62,0,9,221,82,7,27,0,8,110,0,8,46,0,9,189,0,8,14,0,8,142,0,8,78,0,9,253,96,7,256,0,8,81,0,8,17,85,8,131,82,7,31,0,8,113,0,8,49,0,9,195,80,7,10,0,8,97,0,8,33,0,9,163,0,8,1,0,8,129,0,8,65,0,9,227,80,7,6,0,8,89,0,8,25,0,9,147,83,7,59,0,8,121,0,8,57,0,9,211,81,7,17,0,8,105,0,8,41,0,9,179,0,8,9,0,8,137,0,8,73,0,9,243,80,7,4,0,8,85,0,8,21,80,8,258,83,7,43,0,8,117,0,8,53,0,9,203,81,7,13,0,8,101,0,8,37,0,9,171,0,8,5,0,8,133,0,8,69,0,9,235,80,7,8,0,8,93,0,8,29,0,9,155,84,7,83,0,8,125,0,8,61,0,9,219,82,7,23,0,8,109,0,8,45,0,9,187,0,8,13,0,8,141,0,8,77,0,9,251,80,7,3,0,8,83,0,8,19,85,8,195,83,7,35,0,8,115,0,8,51,0,9,199,81,7,11,0,8,99,0,8,35,0,9,167,0,8,3,0,8,131,0,8,67,0,9,231,80,7,7,0,8,91,0,8,27,0,9,151,84,7,67,0,8,123,0,8,59,0,9,215,82,7,19,0,8,107,0,8,43,0,9,183,0,8,11,0,8,139,0,8,75,0,9,247,80,7,5,0,8,87,0,8,23,192,8,0,83,7,51,0,8,119,0,8,55,0,9,207,81,7,15,0,8,103,0,8,39,0,9,175,0,8,7,0,8,135,0,8,71,0,9,239,80,7,9,0,8,95,0,8,31,0,9,159,84,7,99,0,8,127,0,8,63,0,9,223,82,7,27,0,8,111,0,8,47,0,9,191,0,8,15,0,8,143,0,8,79,0,9,255],s=[80,5,1,87,5,257,83,5,17,91,5,4097,81,5,5,89,5,1025,85,5,65,93,5,16385,80,5,3,88,5,513,84,5,33,92,5,8193,82,5,9,90,5,2049,86,5,129,192,5,24577,80,5,2,87,5,385,83,5,25,91,5,6145,81,5,7,89,5,1537,85,5,97,93,5,24577,80,5,4,88,5,769,84,5,49,92,5,12289,82,5,13,90,5,3073,86,5,193,192,5,24577],a=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],l=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,112,112],c=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577],u=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13];function d(){let e,t,o,i,s,d;function f(e,t,a,l,c,u,f,p,h,m,y){let g,v,b,_,w,x,k,j,C,E,D,S,O,P,B;E=0,w=a;do{o[e[t+E]]++,E++,w--}while(0!==w);if(o[0]==a)return f[0]=-1,p[0]=0,0;for(j=p[0],x=1;x<=15&&0===o[x];x++);for(k=x,j<x&&(j=x),w=15;0!==w&&0===o[w];w--);for(b=w,j>w&&(j=w),p[0]=j,P=1<<x;x<w;x++,P<<=1)if((P-=o[x])<0)return n;if((P-=o[w])<0)return n;for(o[w]+=P,d[1]=x=0,E=1,O=2;0!=--w;)d[O]=x+=o[E],O++,E++;w=0,E=0;do{0!==(x=e[t+E])&&(y[d[x]++]=w),E++}while(++w<a);for(a=d[b],d[0]=w=0,E=0,_=-1,S=-j,s[0]=0,D=0,B=0;k<=b;k++)for(g=o[k];0!=g--;){for(;k>S+j;){if(_++,S+=j,B=b-S,B=B>j?j:B,(v=1<<(x=k-S))>g+1&&(v-=g+1,O=k,x<B))for(;++x<B&&!((v<<=1)<=o[++O]);)v-=o[O];if(B=1<<x,m[0]+B>1440)return n;s[_]=D=m[0],m[0]+=B,0!==_?(d[_]=w,i[0]=x,i[1]=j,x=w>>>S-j,i[2]=D-s[_-1]-x,h.set(i,3*(s[_-1]+x))):f[0]=D}for(i[1]=k-S,E>=a?i[0]=192:y[E]<l?(i[0]=y[E]<256?0:96,i[2]=y[E++]):(i[0]=u[y[E]-l]+16+64,i[2]=c[y[E++]-l]),v=1<<k-S,x=w>>>S;x<B;x+=v)h.set(i,3*(D+x));for(x=1<<k-1;0!=(w&x);x>>>=1)w^=x;for(w^=x,C=(1<<S)-1;(w&C)!=d[_];)_--,S-=j,C=(1<<S)-1}return 0!==P&&1!=b?r:0}function p(n){let r;for(e||(e=[],t=[],o=new Int32Array(16),i=[],s=new Int32Array(15),d=new Int32Array(16)),t.length<n&&(t=[]),r=0;r<n;r++)t[r]=0;for(r=0;r<16;r++)o[r]=0;for(r=0;r<3;r++)i[r]=0;s.set(o.subarray(0,15),0),d.set(o.subarray(0,16),0)}this.inflate_trees_bits=function(o,i,s,a,l){let c;return p(19),e[0]=0,c=f(o,0,19,19,null,null,s,i,a,e,t),c==n?l.msg="oversubscribed dynamic bit lengths tree":c!=r&&0!==i[0]||(l.msg="incomplete dynamic bit lengths tree",c=n),c},this.inflate_trees_dynamic=function(o,i,s,d,h,m,y,g,v){let b;return p(288),e[0]=0,b=f(s,0,o,257,a,l,m,d,g,e,t),0!=b||0===d[0]?(b==n?v.msg="oversubscribed literal/length tree":-4!=b&&(v.msg="incomplete literal/length tree",b=n),b):(p(288),b=f(s,o,i,0,c,u,y,h,g,e,t),0!=b||0===h[0]&&o>257?(b==n?v.msg="oversubscribed distance tree":b==r?(v.msg="incomplete distance tree",b=n):-4!=b&&(v.msg="empty distance tree with lengths",b=n),b):0)}}function f(){const e=this;let r,i,s,a,l=0,c=0,u=0,d=0,f=0,p=0,h=0,m=0,y=0,g=0;function v(e,t,r,i,s,a,l,c){let u,d,f,p,h,m,y,g,v,b,_,w,x,k,j,C;y=c.next_in_index,g=c.avail_in,h=l.bitb,m=l.bitk,v=l.write,b=v<l.read?l.read-v-1:l.end-v,_=o[e],w=o[t];do{for(;m<20;)g--,h|=(255&c.read_byte(y++))<<m,m+=8;if(u=h&_,d=r,f=i,C=3*(f+u),0!==(p=d[C]))for(;;){if(h>>=d[C+1],m-=d[C+1],0!=(16&p)){for(p&=15,x=d[C+2]+(h&o[p]),h>>=p,m-=p;m<15;)g--,h|=(255&c.read_byte(y++))<<m,m+=8;for(u=h&w,d=s,f=a,C=3*(f+u),p=d[C];;){if(h>>=d[C+1],m-=d[C+1],0!=(16&p)){for(p&=15;m<p;)g--,h|=(255&c.read_byte(y++))<<m,m+=8;if(k=d[C+2]+(h&o[p]),h>>=p,m-=p,b-=x,v>=k)j=v-k,v-j>0&&2>v-j?(l.window[v++]=l.window[j++],l.window[v++]=l.window[j++],x-=2):(l.window.set(l.window.subarray(j,j+2),v),v+=2,j+=2,x-=2);else{j=v-k;do{j+=l.end}while(j<0);if(p=l.end-j,x>p){if(x-=p,v-j>0&&p>v-j)do{l.window[v++]=l.window[j++]}while(0!=--p);else l.window.set(l.window.subarray(j,j+p),v),v+=p,j+=p,p=0;j=0}}if(v-j>0&&x>v-j)do{l.window[v++]=l.window[j++]}while(0!=--x);else l.window.set(l.window.subarray(j,j+x),v),v+=x,j+=x,x=0;break}if(0!=(64&p))return c.msg="invalid distance code",x=c.avail_in-g,x=m>>3<x?m>>3:x,g+=x,y-=x,m-=x<<3,l.bitb=h,l.bitk=m,c.avail_in=g,c.total_in+=y-c.next_in_index,c.next_in_index=y,l.write=v,n;u+=d[C+2],u+=h&o[p],C=3*(f+u),p=d[C]}break}if(0!=(64&p))return 0!=(32&p)?(x=c.avail_in-g,x=m>>3<x?m>>3:x,g+=x,y-=x,m-=x<<3,l.bitb=h,l.bitk=m,c.avail_in=g,c.total_in+=y-c.next_in_index,c.next_in_index=y,l.write=v,1):(c.msg="invalid literal/length code",x=c.avail_in-g,x=m>>3<x?m>>3:x,g+=x,y-=x,m-=x<<3,l.bitb=h,l.bitk=m,c.avail_in=g,c.total_in+=y-c.next_in_index,c.next_in_index=y,l.write=v,n);if(u+=d[C+2],u+=h&o[p],C=3*(f+u),0===(p=d[C])){h>>=d[C+1],m-=d[C+1],l.window[v++]=d[C+2],b--;break}}else h>>=d[C+1],m-=d[C+1],l.window[v++]=d[C+2],b--}while(b>=258&&g>=10);return x=c.avail_in-g,x=m>>3<x?m>>3:x,g+=x,y-=x,m-=x<<3,l.bitb=h,l.bitk=m,c.avail_in=g,c.total_in+=y-c.next_in_index,c.next_in_index=y,l.write=v,0}e.init=function(e,t,n,o,l,c){r=0,h=e,m=t,s=n,y=o,a=l,g=c,i=null},e.proc=function(e,b,_){let w,x,k,j,C,E,D,S=0,O=0,P=0;for(P=b.next_in_index,j=b.avail_in,S=e.bitb,O=e.bitk,C=e.write,E=C<e.read?e.read-C-1:e.end-C;;)switch(r){case 0:if(E>=258&&j>=10&&(e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,_=v(h,m,s,y,a,g,e,b),P=b.next_in_index,j=b.avail_in,S=e.bitb,O=e.bitk,C=e.write,E=C<e.read?e.read-C-1:e.end-C,0!=_)){r=1==_?7:9;break}u=h,i=s,c=y,r=1;case 1:for(w=u;O<w;){if(0===j)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,j--,S|=(255&b.read_byte(P++))<<O,O+=8}if(x=3*(c+(S&o[w])),S>>>=i[x+1],O-=i[x+1],k=i[x],0===k){d=i[x+2],r=6;break}if(0!=(16&k)){f=15&k,l=i[x+2],r=2;break}if(0==(64&k)){u=k,c=x/3+i[x+2];break}if(0!=(32&k)){r=7;break}return r=9,b.msg="invalid literal/length code",_=n,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);case 2:for(w=f;O<w;){if(0===j)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,j--,S|=(255&b.read_byte(P++))<<O,O+=8}l+=S&o[w],S>>=w,O-=w,u=m,i=a,c=g,r=3;case 3:for(w=u;O<w;){if(0===j)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,j--,S|=(255&b.read_byte(P++))<<O,O+=8}if(x=3*(c+(S&o[w])),S>>=i[x+1],O-=i[x+1],k=i[x],0!=(16&k)){f=15&k,p=i[x+2],r=4;break}if(0==(64&k)){u=k,c=x/3+i[x+2];break}return r=9,b.msg="invalid distance code",_=n,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);case 4:for(w=f;O<w;){if(0===j)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,j--,S|=(255&b.read_byte(P++))<<O,O+=8}p+=S&o[w],S>>=w,O-=w,r=5;case 5:for(D=C-p;D<0;)D+=e.end;for(;0!==l;){if(0===E&&(C==e.end&&0!==e.read&&(C=0,E=C<e.read?e.read-C-1:e.end-C),0===E&&(e.write=C,_=e.inflate_flush(b,_),C=e.write,E=C<e.read?e.read-C-1:e.end-C,C==e.end&&0!==e.read&&(C=0,E=C<e.read?e.read-C-1:e.end-C),0===E)))return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);e.window[C++]=e.window[D++],E--,D==e.end&&(D=0),l--}r=0;break;case 6:if(0===E&&(C==e.end&&0!==e.read&&(C=0,E=C<e.read?e.read-C-1:e.end-C),0===E&&(e.write=C,_=e.inflate_flush(b,_),C=e.write,E=C<e.read?e.read-C-1:e.end-C,C==e.end&&0!==e.read&&(C=0,E=C<e.read?e.read-C-1:e.end-C),0===E)))return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);_=0,e.window[C++]=d,E--,r=0;break;case 7:if(O>7&&(O-=8,j++,P--),e.write=C,_=e.inflate_flush(b,_),C=e.write,E=C<e.read?e.read-C-1:e.end-C,e.read!=e.write)return e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);r=8;case 8:return _=1,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);case 9:return _=n,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_);default:return _=t,e.bitb=S,e.bitk=O,b.avail_in=j,b.total_in+=P-b.next_in_index,b.next_in_index=P,e.write=C,e.inflate_flush(b,_)}},e.free=function(){}}d.inflate_trees_fixed=function(e,t,n,r){return e[0]=9,t[0]=5,n[0]=i,r[0]=s,0};const p=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];function h(e,i){const s=this;let a,l=0,c=0,u=0,h=0;const m=[0],y=[0],g=new f;let v=0,b=new Int32Array(4320);const _=new d;s.bitk=0,s.bitb=0,s.window=new Uint8Array(i),s.end=i,s.read=0,s.write=0,s.reset=function(e,t){t&&(t[0]=0),6==l&&g.free(e),l=0,s.bitk=0,s.bitb=0,s.read=s.write=0},s.reset(e,null),s.inflate_flush=function(e,t){let n,o,i;return o=e.next_out_index,i=s.read,n=(i<=s.write?s.write:s.end)-i,n>e.avail_out&&(n=e.avail_out),0!==n&&t==r&&(t=0),e.avail_out-=n,e.total_out+=n,e.next_out.set(s.window.subarray(i,i+n),o),o+=n,i+=n,i==s.end&&(i=0,s.write==s.end&&(s.write=0),n=s.write-i,n>e.avail_out&&(n=e.avail_out),0!==n&&t==r&&(t=0),e.avail_out-=n,e.total_out+=n,e.next_out.set(s.window.subarray(i,i+n),o),o+=n,i+=n),e.next_out_index=o,s.read=i,t},s.proc=function(e,r){let i,f,w,x,k,j,C,E;for(x=e.next_in_index,k=e.avail_in,f=s.bitb,w=s.bitk,j=s.write,C=j<s.read?s.read-j-1:s.end-j;;){let D,S,O,P,B,M,T,A;switch(l){case 0:for(;w<3;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}switch(i=7&f,v=1&i,i>>>1){case 0:f>>>=3,w-=3,i=7&w,f>>>=i,w-=i,l=1;break;case 1:D=[],S=[],O=[[]],P=[[]],d.inflate_trees_fixed(D,S,O,P),g.init(D[0],S[0],O[0],0,P[0],0),f>>>=3,w-=3,l=6;break;case 2:f>>>=3,w-=3,l=3;break;case 3:return f>>>=3,w-=3,l=9,e.msg="invalid block type",r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r)}break;case 1:for(;w<32;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}if((~f>>>16&65535)!=(65535&f))return l=9,e.msg="invalid stored block lengths",r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);c=65535&f,f=w=0,l=0!==c?2:0!==v?7:0;break;case 2:if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);if(0===C&&(j==s.end&&0!==s.read&&(j=0,C=j<s.read?s.read-j-1:s.end-j),0===C&&(s.write=j,r=s.inflate_flush(e,r),j=s.write,C=j<s.read?s.read-j-1:s.end-j,j==s.end&&0!==s.read&&(j=0,C=j<s.read?s.read-j-1:s.end-j),0===C)))return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);if(r=0,i=c,i>k&&(i=k),i>C&&(i=C),s.window.set(e.read_buf(x,i),j),x+=i,k-=i,j+=i,C-=i,0!=(c-=i))break;l=0!==v?7:0;break;case 3:for(;w<14;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}if(u=i=16383&f,(31&i)>29||(i>>5&31)>29)return l=9,e.msg="too many length or distance symbols",r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);if(i=258+(31&i)+(i>>5&31),!a||a.length<i)a=[];else for(E=0;E<i;E++)a[E]=0;f>>>=14,w-=14,h=0,l=4;case 4:for(;h<4+(u>>>10);){for(;w<3;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}a[p[h++]]=7&f,f>>>=3,w-=3}for(;h<19;)a[p[h++]]=0;if(m[0]=7,i=_.inflate_trees_bits(a,m,y,b,e),0!=i)return(r=i)==n&&(a=null,l=9),s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);h=0,l=5;case 5:for(;i=u,!(h>=258+(31&i)+(i>>5&31));){let t,c;for(i=m[0];w<i;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}if(i=b[3*(y[0]+(f&o[i]))+1],c=b[3*(y[0]+(f&o[i]))+2],c<16)f>>>=i,w-=i,a[h++]=c;else{for(E=18==c?7:c-14,t=18==c?11:3;w<i+E;){if(0===k)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);r=0,k--,f|=(255&e.read_byte(x++))<<w,w+=8}if(f>>>=i,w-=i,t+=f&o[E],f>>>=E,w-=E,E=h,i=u,E+t>258+(31&i)+(i>>5&31)||16==c&&E<1)return a=null,l=9,e.msg="invalid bit length repeat",r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);c=16==c?a[E-1]:0;do{a[E++]=c}while(0!=--t);h=E}}if(y[0]=-1,B=[],M=[],T=[],A=[],B[0]=9,M[0]=6,i=u,i=_.inflate_trees_dynamic(257+(31&i),1+(i>>5&31),a,B,M,T,A,b,e),0!=i)return i==n&&(a=null,l=9),r=i,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);g.init(B[0],M[0],b,T[0],b,A[0]),l=6;case 6:if(s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,1!=(r=g.proc(s,e,r)))return s.inflate_flush(e,r);if(r=0,g.free(e),x=e.next_in_index,k=e.avail_in,f=s.bitb,w=s.bitk,j=s.write,C=j<s.read?s.read-j-1:s.end-j,0===v){l=0;break}l=7;case 7:if(s.write=j,r=s.inflate_flush(e,r),j=s.write,C=j<s.read?s.read-j-1:s.end-j,s.read!=s.write)return s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);l=8;case 8:return r=1,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);case 9:return r=n,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r);default:return r=t,s.bitb=f,s.bitk=w,e.avail_in=k,e.total_in+=x-e.next_in_index,e.next_in_index=x,s.write=j,s.inflate_flush(e,r)}}},s.free=function(e){s.reset(e,null),s.window=null,b=null},s.set_dictionary=function(e,t,n){s.window.set(e.subarray(t,t+n),0),s.read=s.write=n},s.sync_point=function(){return 1==l?1:0}}const m=13,y=[0,0,255,255];function g(){const e=this;function o(e){return e&&e.istate?(e.total_in=e.total_out=0,e.msg=null,e.istate.mode=7,e.istate.blocks.reset(e,null),0):t}e.mode=0,e.method=0,e.was=[0],e.need=0,e.marker=0,e.wbits=0,e.inflateEnd=function(t){return e.blocks&&e.blocks.free(t),e.blocks=null,0},e.inflateInit=function(n,r){return n.msg=null,e.blocks=null,r<8||r>15?(e.inflateEnd(n),t):(e.wbits=r,n.istate.blocks=new h(n,1<<r),o(n),0)},e.inflate=function(e,o){let i,s;if(!e||!e.istate||!e.next_in)return t;const a=e.istate;for(o=4==o?r:0,i=r;;)switch(a.mode){case 0:if(0===e.avail_in)return i;if(i=o,e.avail_in--,e.total_in++,8!=(15&(a.method=e.read_byte(e.next_in_index++)))){a.mode=m,e.msg="unknown compression method",a.marker=5;break}if(8+(a.method>>4)>a.wbits){a.mode=m,e.msg="invalid window size",a.marker=5;break}a.mode=1;case 1:if(0===e.avail_in)return i;if(i=o,e.avail_in--,e.total_in++,s=255&e.read_byte(e.next_in_index++),((a.method<<8)+s)%31!=0){a.mode=m,e.msg="incorrect header check",a.marker=5;break}if(0==(32&s)){a.mode=7;break}a.mode=2;case 2:if(0===e.avail_in)return i;i=o,e.avail_in--,e.total_in++,a.need=(255&e.read_byte(e.next_in_index++))<<24&4278190080,a.mode=3;case 3:if(0===e.avail_in)return i;i=o,e.avail_in--,e.total_in++,a.need+=(255&e.read_byte(e.next_in_index++))<<16&16711680,a.mode=4;case 4:if(0===e.avail_in)return i;i=o,e.avail_in--,e.total_in++,a.need+=(255&e.read_byte(e.next_in_index++))<<8&65280,a.mode=5;case 5:return 0===e.avail_in?i:(i=o,e.avail_in--,e.total_in++,a.need+=255&e.read_byte(e.next_in_index++),a.mode=6,2);case 6:return a.mode=m,e.msg="need dictionary",a.marker=0,t;case 7:if(i=a.blocks.proc(e,i),i==n){a.mode=m,a.marker=0;break}if(0==i&&(i=o),1!=i)return i;i=o,a.blocks.reset(e,a.was),a.mode=12;case 12:return 1;case m:return n;default:return t}},e.inflateSetDictionary=function(e,n,r){let o=0,i=r;if(!e||!e.istate||6!=e.istate.mode)return t;const s=e.istate;return i>=1<<s.wbits&&(i=(1<<s.wbits)-1,o=r-i),s.blocks.set_dictionary(n,o,i),s.mode=7,0},e.inflateSync=function(e){let i,s,a,l,c;if(!e||!e.istate)return t;const u=e.istate;if(u.mode!=m&&(u.mode=m,u.marker=0),0===(i=e.avail_in))return r;for(s=e.next_in_index,a=u.marker;0!==i&&a<4;)e.read_byte(s)==y[a]?a++:a=0!==e.read_byte(s)?0:4-a,s++,i--;return e.total_in+=s-e.next_in_index,e.next_in_index=s,e.avail_in=i,u.marker=a,4!=a?n:(l=e.total_in,c=e.total_out,o(e),e.total_in=l,e.total_out=c,u.mode=7,0)},e.inflateSyncPoint=function(e){return e&&e.istate&&e.istate.blocks?e.istate.blocks.sync_point():t}}function v(){}v.prototype={inflateInit:function(e){const t=this;return t.istate=new g,e||(e=15),t.istate.inflateInit(t,e)},inflate:function(e){const n=this;return n.istate?n.istate.inflate(n,e):t},inflateEnd:function(){const e=this;if(!e.istate)return t;const n=e.istate.inflateEnd(e);return e.istate=null,n},inflateSync:function(){const e=this;return e.istate?e.istate.inflateSync(e):t},inflateSetDictionary:function(e,n){const r=this;return r.istate?r.istate.inflateSetDictionary(r,e,n):t},read_byte:function(e){return this.next_in[e]},read_buf:function(e,t){return this.next_in.subarray(e,e+t)}};const b={chunkSize:524288,maxWorkers:"undefined"!=typeof navigator&&navigator.hardwareConcurrency||2,terminateWorkerTimeout:5e3,useWebWorkers:!0,workerScripts:void 0},_=Object.assign({},b);function w(e){if(void 0!==e.chunkSize&&(_.chunkSize=e.chunkSize),void 0!==e.maxWorkers&&(_.maxWorkers=e.maxWorkers),void 0!==e.terminateWorkerTimeout&&(_.terminateWorkerTimeout=e.terminateWorkerTimeout),void 0!==e.useWebWorkers&&(_.useWebWorkers=e.useWebWorkers),void 0!==e.Deflate&&(_.Deflate=e.Deflate),void 0!==e.Inflate&&(_.Inflate=e.Inflate),void 0!==e.workerScripts){if(e.workerScripts.deflate){if(!Array.isArray(e.workerScripts.deflate))throw new Error("workerScripts.deflate must be an array");_.workerScripts||(_.workerScripts={}),_.workerScripts.deflate=e.workerScripts.deflate}if(e.workerScripts.inflate){if(!Array.isArray(e.workerScripts.inflate))throw new Error("workerScripts.inflate must be an array");_.workerScripts||(_.workerScripts={}),_.workerScripts.inflate=e.workerScripts.inflate}}}const x="Abort error";function k(e,t){if(e&&e.aborted)throw t.flush(),new Error(x)}async function j(e,t){return t.length&&await e.writeUint8Array(t),t.length}const C="HTTP error ",E="HTTP Range not supported",D="text/plain",S="Content-Length",O="Accept-Ranges",P="HEAD",B="GET",M="bytes";class T{constructor(){this.size=0}init(){this.initialized=!0}}class A extends T{}class I extends T{writeUint8Array(e){this.size+=e.length}}class K extends A{constructor(e){super(),this.blob=e,this.size=e.size}async readUint8Array(e,t){const n=new FileReader;return new Promise(((r,o)=>{n.onload=e=>r(new Uint8Array(e.target.result)),n.onerror=()=>o(n.error),n.readAsArrayBuffer(this.blob.slice(e,e+t))}))}}class L extends A{constructor(e,t){super(),this.url=e,this.preventHeadRequest=t.preventHeadRequest,this.useRangeHeader=t.useRangeHeader,this.forceRangeRequests=t.forceRangeRequests,this.options=Object.assign({},t),delete this.options.preventHeadRequest,delete this.options.useRangeHeader,delete this.options.forceRangeRequests,delete this.options.useXHR}async init(){if(super.init(),W(this.url)&&!this.preventHeadRequest){const e=await N(P,this.url,this.options);if(this.size=Number(e.headers.get(S)),!this.forceRangeRequests&&this.useRangeHeader&&e.headers.get(O)!=M)throw new Error(E);void 0===this.size&&await R(this,this.options)}else await R(this,this.options)}async readUint8Array(e,t){if(this.useRangeHeader){const n=await N(B,this.url,this.options,Object.assign({},this.options.headers,{HEADER_RANGE:"bytes="+e+"-"+(e+t-1)}));if(206!=n.status)throw new Error(E);return new Uint8Array(await n.arrayBuffer())}return this.data||await R(this,this.options),new Uint8Array(this.data.subarray(e,e+t))}}async function R(e,t){const n=await N(B,e.url,t);e.data=new Uint8Array(await n.arrayBuffer()),e.size||(e.size=e.data.length)}async function N(e,t,n,r){r=Object.assign({},n.headers,r);const o=await fetch(t,Object.assign({},n,{method:e,headers:r}));if(o.status<400)return o;throw new Error(C+(o.statusText||o.status))}class F extends A{constructor(e,t){super(),this.url=e,this.preventHeadRequest=t.preventHeadRequest,this.useRangeHeader=t.useRangeHeader,this.forceRangeRequests=t.forceRangeRequests}async init(){if(super.init(),W(this.url)&&!this.preventHeadRequest)return new Promise(((e,t)=>z(P,this.url,(n=>{this.size=Number(n.getResponseHeader(S)),this.useRangeHeader?this.forceRangeRequests||n.getResponseHeader(O)==M?e():t(new Error(E)):void 0===this.size?U(this,this.url).then((()=>e())).catch(t):e()}),t)));await U(this,this.url)}async readUint8Array(e,t){if(!this.useRangeHeader)return this.data||await U(this,this.url),new Uint8Array(this.data.subarray(e,e+t));if(206!=(await new Promise(((n,r)=>z(B,this.url,(e=>n(new Uint8Array(e.response))),r,[["Range","bytes="+e+"-"+(e+t-1)]])))).status)throw new Error(E)}}function U(e,t){return new Promise(((n,r)=>z(B,t,(t=>{e.data=new Uint8Array(t.response),e.size||(e.size=e.data.length),n()}),r)))}function z(e,t,n,r,o=[]){const i=new XMLHttpRequest;return i.addEventListener("load",(()=>{i.status<400?n(i):r(C+(i.statusText||i.status))}),!1),i.addEventListener("error",r,!1),i.open(e,t),o.forEach((e=>i.setRequestHeader(e[0],e[1]))),i.responseType="arraybuffer",i.send(),i}class H extends A{constructor(e,t={}){super(),this.url=e,t.useXHR?this.reader=new F(e,t):this.reader=new L(e,t)}set size(e){}get size(){return this.reader.size}async init(){super.init(),await this.reader.init()}async readUint8Array(e,t){return this.reader.readUint8Array(e,t)}}function W(e){if("undefined"!=typeof document){const t=document.createElement("a");return t.href=e,"http:"==t.protocol||"https:"==t.protocol}return/^https?:\/\//i.test(e)}const q=4294967295,V=33639248,G=101075792,Y="\0☺☻♥♦♣♠•◘○◙♂♀♪♫☼►◄↕‼¶§▬↨↑↓→←∟↔▲▼ !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~⌂ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜ¢£¥₧ƒáíóúñѪº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ ".split(""),X=[];for(let e=0;e<256;e++){let t=e;for(let e=0;e<8;e++)1&t?t=t>>>1^3988292384:t>>>=1;X[e]=t}class ${constructor(e){this.crc=e||-1}append(e){let t=0|this.crc;for(let n=0,r=0|e.length;n<r;n++)t=t>>>8^X[255&(t^e[n])];this.crc=t}get(){return~this.crc}}const J={concat(e,t){if(0===e.length||0===t.length)return e.concat(t);const n=e[e.length-1],r=J.getPartial(n);return 32===r?e.concat(t):J._shiftRight(t,r,0|n,e.slice(0,e.length-1))},bitLength(e){const t=e.length;if(0===t)return 0;const n=e[t-1];return 32*(t-1)+J.getPartial(n)},clamp(e,t){if(32*e.length<t)return e;const n=(e=e.slice(0,Math.ceil(t/32))).length;return t&=31,n>0&&t&&(e[n-1]=J.partial(t,e[n-1]&2147483648>>t-1,1)),e},partial:(e,t,n)=>32===e?t:(n?0|t:t<<32-e)+1099511627776*e,getPartial:e=>Math.round(e/1099511627776)||32,_shiftRight(e,t,n,r){for(void 0===r&&(r=[]);t>=32;t-=32)r.push(n),n=0;if(0===t)return r.concat(e);for(let o=0;o<e.length;o++)r.push(n|e[o]>>>t),n=e[o]<<32-t;const o=e.length?e[e.length-1]:0,i=J.getPartial(o);return r.push(J.partial(t+i&31,t+i>32?n:r.pop(),1)),r}},Q={bytes:{fromBits(e){const t=J.bitLength(e)/8,n=new Uint8Array(t);let r;for(let o=0;o<t;o++)0==(3&o)&&(r=e[o/4]),n[o]=r>>>24,r<<=8;return n},toBits(e){const t=[];let n,r=0;for(n=0;n<e.length;n++)r=r<<8|e[n],3==(3&n)&&(t.push(r),r=0);return 3&n&&t.push(J.partial(8*(3&n),r)),t}}},Z={sha1:function(e){e?(this._h=e._h.slice(0),this._buffer=e._buffer.slice(0),this._length=e._length):this.reset()}};Z.sha1.prototype={blockSize:512,reset:function(){const e=this;return e._h=this._init.slice(0),e._buffer=[],e._length=0,e},update:function(e){const t=this;"string"==typeof e&&(e=Q.utf8String.toBits(e));const n=t._buffer=J.concat(t._buffer,e),r=t._length,o=t._length=r+J.bitLength(e);if(o>9007199254740991)throw new Error("Cannot hash more than 2^53 - 1 bits");const i=new Uint32Array(n);let s=0;for(let e=t.blockSize+r-(t.blockSize+r&t.blockSize-1);e<=o;e+=t.blockSize)t._block(i.subarray(16*s,16*(s+1))),s+=1;return n.splice(0,16*s),t},finalize:function(){const e=this;let t=e._buffer;const n=e._h;t=J.concat(t,[J.partial(1,1)]);for(let e=t.length+2;15&e;e++)t.push(0);for(t.push(Math.floor(e._length/4294967296)),t.push(0|e._length);t.length;)e._block(t.splice(0,16));return e.reset(),n},_init:[1732584193,4023233417,2562383102,271733878,3285377520],_key:[1518500249,1859775393,2400959708,3395469782],_f:function(e,t,n,r){return e<=19?t&n|~t&r:e<=39?t^n^r:e<=59?t&n|t&r|n&r:e<=79?t^n^r:void 0},_S:function(e,t){return t<<e|t>>>32-e},_block:function(e){const t=this,n=t._h,r=Array(80);for(let t=0;t<16;t++)r[t]=e[t];let o=n[0],i=n[1],s=n[2],a=n[3],l=n[4];for(let e=0;e<=79;e++){e>=16&&(r[e]=t._S(1,r[e-3]^r[e-8]^r[e-14]^r[e-16]));const n=t._S(5,o)+t._f(e,i,s,a)+l+r[e]+t._key[Math.floor(e/20)]|0;l=a,a=s,s=t._S(30,i),i=o,o=n}n[0]=n[0]+o|0,n[1]=n[1]+i|0,n[2]=n[2]+s|0,n[3]=n[3]+a|0,n[4]=n[4]+l|0}};const ee=class{constructor(e){const t=this;t._tables=[[[],[],[],[],[]],[[],[],[],[],[]]],t._tables[0][0][0]||t._precompute();const n=t._tables[0][4],r=t._tables[1],o=e.length;let i,s,a,l=1;if(4!==o&&6!==o&&8!==o)throw new Error("invalid aes key size");for(t._key=[s=e.slice(0),a=[]],i=o;i<4*o+28;i++){let e=s[i-1];(i%o==0||8===o&&i%o==4)&&(e=n[e>>>24]<<24^n[e>>16&255]<<16^n[e>>8&255]<<8^n[255&e],i%o==0&&(e=e<<8^e>>>24^l<<24,l=l<<1^283*(l>>7))),s[i]=s[i-o]^e}for(let e=0;i;e++,i--){const t=s[3&e?i:i-4];a[e]=i<=4||e<4?t:r[0][n[t>>>24]]^r[1][n[t>>16&255]]^r[2][n[t>>8&255]]^r[3][n[255&t]]}}encrypt(e){return this._crypt(e,0)}decrypt(e){return this._crypt(e,1)}_precompute(){const e=this._tables[0],t=this._tables[1],n=e[4],r=t[4],o=[],i=[];let s,a,l,c;for(let e=0;e<256;e++)i[(o[e]=e<<1^283*(e>>7))^e]=e;for(let u=s=0;!n[u];u^=a||1,s=i[s]||1){let i=s^s<<1^s<<2^s<<3^s<<4;i=i>>8^255&i^99,n[u]=i,r[i]=u,c=o[l=o[a=o[u]]];let d=16843009*c^65537*l^257*a^16843008*u,f=257*o[i]^16843008*i;for(let n=0;n<4;n++)e[n][u]=f=f<<24^f>>>8,t[n][i]=d=d<<24^d>>>8}for(let n=0;n<5;n++)e[n]=e[n].slice(0),t[n]=t[n].slice(0)}_crypt(e,t){if(4!==e.length)throw new Error("invalid aes block size");const n=this._key[t],r=n.length/4-2,o=[0,0,0,0],i=this._tables[t],s=i[0],a=i[1],l=i[2],c=i[3],u=i[4];let d,f,p,h=e[0]^n[0],m=e[t?3:1]^n[1],y=e[2]^n[2],g=e[t?1:3]^n[3],v=4;for(let e=0;e<r;e++)d=s[h>>>24]^a[m>>16&255]^l[y>>8&255]^c[255&g]^n[v],f=s[m>>>24]^a[y>>16&255]^l[g>>8&255]^c[255&h]^n[v+1],p=s[y>>>24]^a[g>>16&255]^l[h>>8&255]^c[255&m]^n[v+2],g=s[g>>>24]^a[h>>16&255]^l[m>>8&255]^c[255&y]^n[v+3],v+=4,h=d,m=f,y=p;for(let e=0;e<4;e++)o[t?3&-e:e]=u[h>>>24]<<24^u[m>>16&255]<<16^u[y>>8&255]<<8^u[255&g]^n[v++],d=h,h=m,m=y,y=g,g=d;return o}},te=class{constructor(e,t){this._prf=e,this._initIv=t,this._iv=t}reset(){this._iv=this._initIv}update(e){return this.calculate(this._prf,e,this._iv)}incWord(e){if(255==(e>>24&255)){let t=e>>16&255,n=e>>8&255,r=255&e;255===t?(t=0,255===n?(n=0,255===r?r=0:++r):++n):++t,e=0,e+=t<<16,e+=n<<8,e+=r}else e+=1<<24;return e}incCounter(e){0===(e[0]=this.incWord(e[0]))&&(e[1]=this.incWord(e[1]))}calculate(e,t,n){let r;if(!(r=t.length))return[];const o=J.bitLength(t);for(let o=0;o<r;o+=4){this.incCounter(n);const r=e.encrypt(n);t[o]^=r[0],t[o+1]^=r[1],t[o+2]^=r[2],t[o+3]^=r[3]}return J.clamp(t,o)}},ne=class{constructor(e){const t=this,n=t._hash=Z.sha1,r=[[],[]],o=n.prototype.blockSize/32;t._baseHash=[new n,new n],e.length>o&&(e=n.hash(e));for(let t=0;t<o;t++)r[0][t]=909522486^e[t],r[1][t]=1549556828^e[t];t._baseHash[0].update(r[0]),t._baseHash[1].update(r[1]),t._resultHash=new n(t._baseHash[0])}reset(){const e=this;e._resultHash=new e._hash(e._baseHash[0]),e._updated=!1}update(e){this._updated=!0,this._resultHash.update(e)}digest(){const e=this,t=e._resultHash.finalize(),n=new e._hash(e._baseHash[1]).update(t).finalize();return e.reset(),n}},re="Invalid pasword",oe=16,ie={name:"PBKDF2"},se=Object.assign({hash:{name:"HMAC"}},ie),ae=Object.assign({iterations:1e3,hash:{name:"SHA-1"}},ie),le=["deriveBits"],ce=[8,12,16],ue=[16,24,32],de=10,fe=[0,0,0,0],pe=Q.bytes,he=ee,me=te,ye=ne;class ge{constructor(e,t,n){Object.assign(this,{password:e,signed:t,strength:n-1,pendingInput:new Uint8Array(0)})}async append(e){const t=this;if(t.password){const n=xe(e,0,ce[t.strength]+2);await async function(e,t,n){await _e(e,n,xe(t,0,ce[e.strength]));const r=xe(t,ce[e.strength]),o=e.keys.passwordVerification;if(o[0]!=r[0]||o[1]!=r[1])throw new Error(re)}(t,n,t.password),t.password=null,t.aesCtrGladman=new me(new he(t.keys.key),Array.from(fe)),t.hmac=new ye(t.keys.authentication),e=xe(e,ce[t.strength]+2)}return be(t,e,new Uint8Array(e.length-de-(e.length-de)%oe),0,de,!0)}flush(){const e=this,t=e.pendingInput,n=xe(t,0,t.length-de),r=xe(t,t.length-de);let o=new Uint8Array(0);if(n.length){const t=pe.toBits(n);e.hmac.update(t);const r=e.aesCtrGladman.update(t);o=pe.fromBits(r)}let i=!0;if(e.signed){const t=xe(pe.fromBits(e.hmac.digest()),0,de);for(let e=0;e<de;e++)t[e]!=r[e]&&(i=!1)}return{valid:i,data:o}}}class ve{constructor(e,t){Object.assign(this,{password:e,strength:t-1,pendingInput:new Uint8Array(0)})}async append(e){const t=this;let n=new Uint8Array(0);t.password&&(n=await async function(e,t){const n=crypto.getRandomValues(new Uint8Array(ce[e.strength]));return await _e(e,t,n),we(n,e.keys.passwordVerification)}(t,t.password),t.password=null,t.aesCtrGladman=new me(new he(t.keys.key),Array.from(fe)),t.hmac=new ye(t.keys.authentication));const r=new Uint8Array(n.length+e.length-e.length%oe);return r.set(n,0),be(t,e,r,n.length,0)}flush(){const e=this;let t=new Uint8Array(0);if(e.pendingInput.length){const n=e.aesCtrGladman.update(pe.toBits(e.pendingInput));e.hmac.update(n),t=pe.fromBits(n)}const n=xe(pe.fromBits(e.hmac.digest()),0,de);return{data:we(t,n),signature:n}}}function be(e,t,n,r,o,i){const s=t.length-o;let a;for(e.pendingInput.length&&(t=we(e.pendingInput,t),n=function(e,t){if(t&&t>e.length){const n=e;(e=new Uint8Array(t)).set(n,0)}return e}(n,s-s%oe)),a=0;a<=s-oe;a+=oe){const o=pe.toBits(xe(t,a,a+oe));i&&e.hmac.update(o);const s=e.aesCtrGladman.update(o);i||e.hmac.update(s),n.set(pe.fromBits(s),a+r)}return e.pendingInput=xe(t,a),n}async function _e(e,t,n){const r=(new TextEncoder).encode(t),o=await crypto.subtle.importKey("raw",r,se,!1,le),i=await crypto.subtle.deriveBits(Object.assign({salt:n},ae),o,8*(2*ue[e.strength]+2)),s=new Uint8Array(i);e.keys={key:pe.toBits(xe(s,0,ue[e.strength])),authentication:pe.toBits(xe(s,ue[e.strength],2*ue[e.strength])),passwordVerification:xe(s,2*ue[e.strength])}}function we(e,t){let n=e;return e.length+t.length&&(n=new Uint8Array(e.length+t.length),n.set(e,0),n.set(t,e.length)),n}function xe(e,t,n){return e.subarray(t,n)}class ke{constructor(e,t){Object.assign(this,{password:e,passwordVerification:t}),De(this,e)}append(e){const t=this;if(t.password){const n=Ce(t,e.subarray(0,12));if(t.password=null,n[11]!=t.passwordVerification)throw new Error(re);e=e.subarray(12)}return Ce(t,e)}flush(){return{valid:!0,data:new Uint8Array(0)}}}class je{constructor(e,t){Object.assign(this,{password:e,passwordVerification:t}),De(this,e)}append(e){const t=this;let n,r;if(t.password){t.password=null;const o=crypto.getRandomValues(new Uint8Array(12));o[11]=t.passwordVerification,n=new Uint8Array(e.length+o.length),n.set(Ee(t,o),0),r=12}else n=new Uint8Array(e.length),r=0;return n.set(Ee(t,e),r),n}flush(){return{data:new Uint8Array(0)}}}function Ce(e,t){const n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=Oe(e)^t[r],Se(e,n[r]);return n}function Ee(e,t){const n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=Oe(e)^t[r],Se(e,t[r]);return n}function De(e,t){e.keys=[305419896,591751049,878082192],e.crcKey0=new $(e.keys[0]),e.crcKey2=new $(e.keys[2]);for(let n=0;n<t.length;n++)Se(e,t.charCodeAt(n))}function Se(e,t){e.crcKey0.append([t]),e.keys[0]=~e.crcKey0.get(),e.keys[1]=Be(e.keys[1]+Pe(e.keys[0])),e.keys[1]=Be(Math.imul(e.keys[1],134775813)+1),e.crcKey2.append([e.keys[1]>>>24]),e.keys[2]=~e.crcKey2.get()}function Oe(e){const t=2|e.keys[2];return Pe(Math.imul(t,1^t)>>>8)}function Pe(e){return 255&e}function Be(e){return 4294967295&e}const Me="inflate",Te="Invalid signature";class Ae{constructor(e,{signature:t,password:n,signed:r,compressed:o,zipCrypto:i,passwordVerification:s,encryptionStrength:a},{chunkSize:l}){const c=Boolean(n);Object.assign(this,{signature:t,encrypted:c,signed:r,compressed:o,inflate:o&&new e({chunkSize:l}),crc32:r&&new $,zipCrypto:i,decrypt:c&&i?new ke(n,s):new ge(n,r,a)})}async append(e){const t=this;return t.encrypted&&e.length&&(e=await t.decrypt.append(e)),t.compressed&&e.length&&(e=await t.inflate.append(e)),(!t.encrypted||t.zipCrypto)&&t.signed&&e.length&&t.crc32.append(e),e}async flush(){const e=this;let t,n=new Uint8Array(0);if(e.encrypted){const t=e.decrypt.flush();if(!t.valid)throw new Error(Te);n=t.data}if((!e.encrypted||e.zipCrypto)&&e.signed){const n=new DataView(new Uint8Array(4).buffer);if(t=e.crc32.get(),n.setUint32(0,t),e.signature!=n.getUint32(0,!1))throw new Error(Te)}return e.compressed&&(n=await e.inflate.append(n)||new Uint8Array(0),await e.inflate.flush()),{data:n,signature:t}}}class Ie{constructor(e,{encrypted:t,signed:n,compressed:r,level:o,zipCrypto:i,password:s,passwordVerification:a,encryptionStrength:l},{chunkSize:c}){Object.assign(this,{encrypted:t,signed:n,compressed:r,deflate:r&&new e({level:o||5,chunkSize:c}),crc32:n&&new $,zipCrypto:i,encrypt:t&&i?new je(s,a):new ve(s,l)})}async append(e){const t=this;let n=e;return t.compressed&&e.length&&(n=await t.deflate.append(e)),t.encrypted&&n.length&&(n=await t.encrypt.append(n)),(!t.encrypted||t.zipCrypto)&&t.signed&&e.length&&t.crc32.append(e),n}async flush(){const e=this;let t,n=new Uint8Array(0);if(e.compressed&&(n=await e.deflate.flush()||new Uint8Array(0)),e.encrypted){n=await e.encrypt.append(n);const r=e.encrypt.flush();t=r.signature;const o=new Uint8Array(n.length+r.data.length);o.set(n,0),o.set(r.data,n.length),n=o}return e.encrypted&&!e.zipCrypto||!e.signed||(t=e.crc32.get()),{data:n,signature:t}}}const Ke="init",Le="append",Re="flush";let Ne=!0;var Fe=(e,t,n,r,o,i,s)=>(Object.assign(e,{busy:!0,codecConstructor:t,options:Object.assign({},n),scripts:s,terminate(){e.worker&&!e.busy&&(e.worker.terminate(),e.interface=null)},onTaskFinished(){e.busy=!1,o(e)}}),i?function(e,t){let n;const r={type:"module"};if(!e.interface){if(Ne)try{e.worker=o()}catch(t){Ne=!1,e.worker=o(r)}else e.worker=o(r);e.worker.addEventListener("message",(function(t){const r=t.data;if(n){const t=r.error,o=r.type;if(t){const r=new Error(t.message);r.stack=t.stack,n.reject(r),n=null,e.onTaskFinished()}else if(o==Ke||o==Re||o==Le){const t=r.data;o==Re?(n.resolve({data:new Uint8Array(t),signature:r.signature}),n=null,e.onTaskFinished()):n.resolve(t&&new Uint8Array(t))}}}),!1),e.interface={append:e=>i({type:Le,data:e}),flush:()=>i({type:Re})}}return e.interface;function o(t={}){return new Worker(new URL(e.scripts[0],"undefined"==typeof document&&"undefined"==typeof location?new(require("url").URL)("file:"+__filename).href:"undefined"==typeof document?location.href:document.currentScript&&document.currentScript.src||new URL("zip-no-worker-inflate.min.js",document.baseURI).href),t)}async function i(r){if(!n){const n=e.options,r=e.scripts.slice(1);await s({scripts:r,type:Ke,options:n,config:{chunkSize:t.chunkSize}})}return s(r)}function s(t){const r=e.worker,o=new Promise(((e,t)=>n={resolve:e,reject:t}));try{if(t.data)try{t.data=t.data.buffer,r.postMessage(t,[t.data])}catch(e){r.postMessage(t)}else r.postMessage(t)}catch(t){n.reject(t),n=null,e.onTaskFinished()}return o}}(e,r):function(e,t){const n=function(e,t,n){return t.codecType.startsWith("deflate")?new Ie(e,t,n):t.codecType.startsWith(Me)?new Ae(e,t,n):void 0}(e.codecConstructor,e.options,t);return{async append(t){try{return await n.append(t)}catch(t){throw e.onTaskFinished(),t}},async flush(){try{return await n.flush()}finally{e.onTaskFinished()}}}}(e,r));let Ue=[],ze=[];function He(e){e.terminateTimeout&&(clearTimeout(e.terminateTimeout),e.terminateTimeout=null)}const We=["filename","rawFilename","directory","encrypted","compressedSize","uncompressedSize","lastModDate","rawLastModDate","comment","rawComment","signature","extraField","rawExtraField","bitFlag","extraFieldZip64","extraFieldUnicodePath","extraFieldUnicodeComment","extraFieldAES","filenameUTF8","commentUTF8","offset","zip64","compressionMethod","extraFieldNTFS","lastAccessDate","creationDate","extraFieldExtendedTimestamp","version","versionMadeBy","msDosCompatible","internalFileAttribute","externalFileAttribute"];class qe{constructor(e){We.forEach((t=>this[t]=e[t]))}}const Ve="File format is not recognized",Ge="End of central directory not found",Ye="End of Zip64 central directory not found",Xe="End of Zip64 central directory locator not found",$e="Central directory header not found",Je="Local file header not found",Qe="Zip64 extra field not found",Ze="File contains encrypted entry",et="Encryption method not supported",tt="Compression method not supported",nt="utf-8",rt=["uncompressedSize","compressedSize","offset"];class ot{constructor(e,t,n){Object.assign(this,{reader:e,config:t,options:n})}async getData(e,t,n={}){const r=this,{reader:o,offset:i,extraFieldAES:s,compressionMethod:a,config:l,bitFlag:c,signature:u,rawLastModDate:d,compressedSize:f}=r,p=r.localDirectory={};o.initialized||await o.init();let h=await gt(o,i,30);const m=yt(h);let y=lt(r,n,"password");if(y=y&&y.length&&y,s&&99!=s.originalCompressionMethod)throw new Error(tt);if(0!=a&&8!=a)throw new Error(tt);if(67324752!=ht(m,0))throw new Error(Je);it(p,m,4),h=await gt(o,i,30+p.filenameLength+p.extraFieldLength),p.rawExtraField=h.subarray(30+p.filenameLength),st(r,p,m,4),t.lastAccessDate=p.lastAccessDate,t.creationDate=p.creationDate;const g=r.encrypted&&p.encrypted,v=g&&!s;if(g){if(!v&&void 0===s.strength)throw new Error(et);if(!y)throw new Error(Ze)}const b=await function(e,t,n){const r=!(!t.compressed&&!t.signed&&!t.encrypted)&&(t.useWebWorkers||void 0===t.useWebWorkers&&n.useWebWorkers),o=r&&n.workerScripts?n.workerScripts[t.codecType]:[];if(Ue.length<n.maxWorkers){const s={};return Ue.push(s),Fe(s,e,t,n,i,r,o)}{const s=Ue.find((e=>!e.busy));return s?(He(s),Fe(s,e,t,n,i,r,o)):new Promise((n=>ze.push({resolve:n,codecConstructor:e,options:t,webWorker:r,scripts:o})))}function i(e){if(ze.length){const[{resolve:t,codecConstructor:r,options:o,webWorker:s,scripts:a}]=ze.splice(0,1);t(Fe(e,r,o,n,i,s,a))}else e.worker?(He(e),Number.isFinite(n.terminateWorkerTimeout)&&n.terminateWorkerTimeout>=0&&(e.terminateTimeout=setTimeout((()=>{Ue=Ue.filter((t=>t!=e)),e.terminate()}),n.terminateWorkerTimeout))):Ue=Ue.filter((t=>t!=e))}}(l.Inflate,{codecType:Me,password:y,zipCrypto:v,encryptionStrength:s&&s.strength,signed:lt(r,n,"checkSignature"),passwordVerification:v&&(c.dataDescriptor?d>>>8&255:u>>>24&255),signature:u,compressed:0!=a,encrypted:g,useWebWorkers:lt(r,n,"useWebWorkers")},l);e.initialized||await e.init();const _=lt(r,n,"signal"),w=i+30+p.filenameLength+p.extraFieldLength;return await async function(e,t,n,r,o,i,s){const a=Math.max(i.chunkSize,64);return async function i(l=0,c=0){const u=s.signal;if(l<o){k(u,e);const d=await t.readUint8Array(l+r,Math.min(a,o-l)),f=d.length;k(u,e);const p=await e.append(d);if(k(u,e),c+=await j(n,p),s.onprogress)try{s.onprogress(l+f,o)}catch(e){}return i(l+a,c)}{const t=await e.flush();return c+=await j(n,t.data),{signature:t.signature,length:c}}}()}(b,o,e,w,f,l,{onprogress:n.onprogress,signal:_}),e.getData()}}function it(e,t,n){const r=e.rawBitFlag=pt(t,n+2),o=1==(1&r),i=ht(t,n+6);Object.assign(e,{encrypted:o,version:pt(t,n),bitFlag:{level:(6&r)>>1,dataDescriptor:8==(8&r),languageEncodingFlag:2048==(2048&r)},rawLastModDate:i,lastModDate:ut(i),filenameLength:pt(t,n+22),extraFieldLength:pt(t,n+24)})}function st(e,t,n,r){const o=t.rawExtraField,i=t.extraField=new Map,s=yt(new Uint8Array(o));let a=0;try{for(;a<o.length;){const e=pt(s,a),t=pt(s,a+2);i.set(e,{type:e,data:o.slice(a+4,a+4+t)}),a+=4+t}}catch(e){}const l=pt(n,r+4);t.signature=ht(n,r+10),t.uncompressedSize=ht(n,r+18),t.compressedSize=ht(n,r+14);const c=i.get(1);c&&(function(e,t){t.zip64=!0;const n=yt(e.data);e.values=[];for(let t=0;t<Math.floor(e.data.length/8);t++)e.values.push(mt(n,0+8*t));const r=rt.filter((e=>t[e]==q));for(let t=0;t<r.length;t++)e[r[t]]=e.values[t];rt.forEach((n=>{if(t[n]==q){if(void 0===e[n])throw new Error(Qe);t[n]=e[n]}}))}(c,t),t.extraFieldZip64=c);const u=i.get(28789);u&&(at(u,"filename","rawFilename",t,e),t.extraFieldUnicodePath=u);const d=i.get(25461);d&&(at(d,"comment","rawComment",t,e),t.extraFieldUnicodeComment=d);const f=i.get(39169);f?(function(e,t,n){const r=yt(e.data);e.vendorVersion=ft(r,0),e.vendorId=ft(r,2);const o=ft(r,4);e.strength=o,e.originalCompressionMethod=n,t.compressionMethod=e.compressionMethod=pt(r,5)}(f,t,l),t.extraFieldAES=f):t.compressionMethod=l;const p=i.get(10);p&&(function(e,t){const n=yt(e.data);let r,o=4;try{for(;o<e.data.length&&!r;){const t=pt(n,o),i=pt(n,o+2);1==t&&(r=e.data.slice(o+4,o+4+i)),o+=4+i}}catch(e){}try{if(r&&24==r.length){const n=yt(r),o=n.getBigUint64(0,!0),i=n.getBigUint64(8,!0),s=n.getBigUint64(16,!0);Object.assign(e,{rawLastModDate:o,rawLastAccessDate:i,rawCreationDate:s});const a=dt(o),l={lastModDate:a,lastAccessDate:dt(i),creationDate:dt(s)};Object.assign(e,l),Object.assign(t,l)}}catch(e){}}(p,t),t.extraFieldNTFS=p);const h=i.get(21589);h&&(function(e,t){const n=yt(e.data),r=ft(n,0),o=[],i=[];1==(1&r)&&(o.push("lastModDate"),i.push("rawLastModDate")),2==(2&r)&&(o.push("lastAccessDate"),i.push("rawLastAccessDate")),4==(4&r)&&(o.push("creationDate"),i.push("rawCreationDate"));let s=1;o.forEach(((r,o)=>{if(e.data.length>=s+4){const a=ht(n,s);t[r]=e[r]=new Date(1e3*a);const l=i[o];e[l]=a}s+=4}))}(h,t),t.extraFieldExtendedTimestamp=h)}function at(e,t,n,r,o){const i=yt(e.data);e.version=ft(i,0),e.signature=ht(i,1);const s=new $;s.append(o[n]);const a=yt(new Uint8Array(4));a.setUint32(0,s.get(),!0),e[t]=(new TextDecoder).decode(e.data.subarray(5)),e.valid=!o.bitFlag.languageEncodingFlag&&e.signature==ht(a,0),e.valid&&(r[t]=e[t],r[t+"UTF8"]=!0)}function lt(e,t,n){return void 0===t[n]?e.options[n]:t[n]}function ct(e,t){return t&&"cp437"!=t.trim().toLowerCase()?new TextDecoder(t).decode(e):(e=>{let t="";for(let n=0;n<e.length;n++)t+=Y[e[n]];return t})(e)}function ut(e){const t=(4294901760&e)>>16,n=65535&e;try{return new Date(1980+((65024&t)>>9),((480&t)>>5)-1,31&t,(63488&n)>>11,(2016&n)>>5,2*(31&n),0)}catch(e){}}function dt(e){return new Date(Number(e/BigInt(1e4)-BigInt(116444736e5)))}function ft(e,t){return e.getUint8(t)}function pt(e,t){return e.getUint16(t,!0)}function ht(e,t){return e.getUint32(t,!0)}function mt(e,t){return Number(e.getBigUint64(t,!0))}function yt(e){return new DataView(e.buffer)}function gt(e,t,n){return e.readUint8Array(t,n)}w({Inflate:function(e){const t=new v,n=e&&e.chunkSize?Math.floor(2*e.chunkSize):131072,o=new Uint8Array(n);let i=!1;t.inflateInit(),t.next_out=o,this.append=function(e,s){const a=[];let l,c,u=0,d=0,f=0;if(0!==e.length){t.next_in_index=0,t.next_in=e,t.avail_in=e.length;do{if(t.next_out_index=0,t.avail_out=n,0!==t.avail_in||i||(t.next_in_index=0,i=!0),l=t.inflate(0),i&&l===r){if(0!==t.avail_in)throw new Error("inflating: bad input")}else if(0!==l&&1!==l)throw new Error("inflating: "+t.msg);if((i||1===l)&&t.avail_in===e.length)throw new Error("inflating: bad input");t.next_out_index&&(t.next_out_index===n?a.push(new Uint8Array(o)):a.push(o.slice(0,t.next_out_index))),f+=t.next_out_index,s&&t.next_in_index>0&&t.next_in_index!=u&&(s(t.next_in_index),u=t.next_in_index)}while(t.avail_in>0||0===t.avail_out);return a.length>1?(c=new Uint8Array(f),a.forEach((function(e){c.set(e,d),d+=e.length}))):c=a[0]||new Uint8Array(0),c}},this.flush=function(){t.inflateEnd()}}}),e.BlobReader=K,e.BlobWriter=class extends I{constructor(e){super(),this.offset=0,this.contentType=e,this.blob=new Blob([],{type:e})}async writeUint8Array(e){super.writeUint8Array(e),this.blob=new Blob([this.blob,e.buffer],{type:this.contentType}),this.offset=this.blob.size}getData(){return this.blob}},e.Data64URIReader=class extends A{constructor(e){super(),this.dataURI=e;let t=e.length;for(;"="==e.charAt(t-1);)t--;this.dataStart=e.indexOf(",")+1,this.size=Math.floor(.75*(t-this.dataStart))}async readUint8Array(e,t){const n=new Uint8Array(t),r=4*Math.floor(e/3),o=atob(this.dataURI.substring(r+this.dataStart,4*Math.ceil((e+t)/3)+this.dataStart)),i=e-3*Math.floor(r/4);for(let e=i;e<i+t;e++)n[e-i]=o.charCodeAt(e);return n}},e.Data64URIWriter=class extends I{constructor(e){super(),this.data="data:"+(e||"")+";base64,",this.pending=[]}async writeUint8Array(e){super.writeUint8Array(e);let t=0,n=this.pending;const r=this.pending.length;for(this.pending="",t=0;t<3*Math.floor((r+e.length)/3)-r;t++)n+=String.fromCharCode(e[t]);for(;t<e.length;t++)this.pending+=String.fromCharCode(e[t]);n.length>2?this.data+=btoa(n):this.pending=n}getData(){return this.data+btoa(this.pending)}},e.ERR_ABORT=x,e.ERR_BAD_FORMAT=Ve,e.ERR_CENTRAL_DIRECTORY_NOT_FOUND=$e,e.ERR_ENCRYPTED=Ze,e.ERR_EOCDR_LOCATOR_ZIP64_NOT_FOUND=Xe,e.ERR_EOCDR_NOT_FOUND=Ge,e.ERR_EOCDR_ZIP64_NOT_FOUND=Ye,e.ERR_EXTRAFIELD_ZIP64_NOT_FOUND=Qe,e.ERR_HTTP_RANGE=E,e.ERR_INVALID_PASSWORD=re,e.ERR_INVALID_SIGNATURE=Te,e.ERR_LOCAL_FILE_HEADER_NOT_FOUND=Je,e.ERR_UNSUPPORTED_COMPRESSION=tt,e.ERR_UNSUPPORTED_ENCRYPTION=et,e.HttpRangeReader=class extends H{constructor(e,t={}){t.useRangeHeader=!0,super(e,t)}},e.HttpReader=H,e.Reader=A,e.TextReader=class extends A{constructor(e){super(),this.blobReader=new K(new Blob([e],{type:D}))}async init(){super.init(),this.blobReader.init(),this.size=this.blobReader.size}async readUint8Array(e,t){return this.blobReader.readUint8Array(e,t)}},e.TextWriter=class extends I{constructor(e){super(),this.encoding=e,this.blob=new Blob([],{type:D})}async writeUint8Array(e){super.writeUint8Array(e),this.blob=new Blob([this.blob,e.buffer],{type:D})}getData(){const e=new FileReader;return new Promise(((t,n)=>{e.onload=e=>t(e.target.result),e.onerror=()=>n(e.error),e.readAsText(this.blob,this.encoding)}))}},e.Uint8ArrayReader=class extends A{constructor(e){super(),this.array=e,this.size=e.length}async readUint8Array(e,t){return this.array.slice(e,e+t)}},e.Uint8ArrayWriter=class extends I{constructor(){super(),this.array=new Uint8Array(0)}async writeUint8Array(e){super.writeUint8Array(e);const t=this.array;this.array=new Uint8Array(t.length+e.length),this.array.set(t),this.array.set(e,t.length)}getData(){return this.array}},e.Writer=I,e.ZipReader=class{constructor(e,t={}){Object.assign(this,{reader:e,options:t,config:_})}async getEntries(e={}){const t=this,n=t.reader;if(n.initialized||await n.init(),n.size<22)throw new Error(Ve);const r=await async function(e,t,n,r,o){const i=new Uint8Array(4);!function(e,t,n){e.setUint32(0,101010256,!0)}(yt(i));return await s(22)||await s(Math.min(1048582,n));async function s(t){const r=n-t,o=await gt(e,r,t);for(let e=o.length-22;e>=0;e--)if(o[e]==i[0]&&o[e+1]==i[1]&&o[e+2]==i[2]&&o[e+3]==i[3])return{offset:r+e,buffer:o.slice(e,e+22).buffer}}}(n,0,n.size);if(!r)throw new Error(Ge);const o=yt(r);let i=ht(o,12),s=ht(o,16),a=pt(o,8),l=0;if(s==q||65535==a){const e=yt(await gt(n,r.offset-20,20));if(117853008!=ht(e,0))throw new Error(Ye);s=mt(e,8);let t=await gt(n,s,56),o=yt(t);const c=r.offset-20-56;if(ht(o,0)!=G&&s!=c){const e=s;s=c,l=s-e,t=await gt(n,s,56),o=yt(t)}if(ht(o,0)!=G)throw new Error(Xe);a=mt(o,24),i=ht(e,4),s-=mt(o,40)}if(s<0||s>=n.size)throw new Error(Ve);let c=0,u=await gt(n,s,n.size-s),d=yt(u);const f=r.offset-i;if(ht(d,c)!=V&&s!=f){const e=s;s=f,l=s-e,u=await gt(n,s,n.size-s),d=yt(u)}if(s<0||s>=n.size)throw new Error(Ve);const p=[];for(let r=0;r<a;r++){const o=new ot(n,t.config,t.options);if(ht(d,c)!=V)throw new Error($e);it(o,d,c+6);const i=Boolean(o.bitFlag.languageEncodingFlag),s=c+46,f=s+o.filenameLength,h=f+o.extraFieldLength,m=pt(d,c+4),y=0==(0&m);Object.assign(o,{versionMadeBy:m,msDosCompatible:y,compressedSize:0,uncompressedSize:0,commentLength:pt(d,c+32),directory:y&&16==(16&ft(d,c+38)),offset:ht(d,c+42)+l,internalFileAttribute:ht(d,c+34),externalFileAttribute:ht(d,c+38),rawFilename:u.subarray(s,f),filenameUTF8:i,commentUTF8:i,rawExtraField:u.subarray(f,h)});const g=h+o.commentLength;o.rawComment=u.subarray(h,g),o.filename=ct(o.rawFilename,o.filenameUTF8?nt:lt(t,e,"filenameEncoding")),o.comment=ct(o.rawComment,o.commentUTF8?nt:lt(t,e,"commentEncoding")),!o.directory&&o.filename.endsWith("/")&&(o.directory=!0),st(o,o,d,c+6);const v=new qe(o);if(v.getData=(e,t)=>o.getData(e,v,t),p.push(v),c=g,e.onprogress)try{e.onprogress(r+1,a,new qe(o))}catch(e){}}return p}async close(){}},e.configure=w,e.getMimeType=function(){return"application/octet-stream"},Object.defineProperty(e,"__esModule",{value:!0})})),function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){var l="function"==typeof require&&require;if(!a&&l)return l(s,!0);if(i)return i(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i="function"==typeof require&&require,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(e,t,n){"use strict";n.byteLength=function(e){var t=c(e),n=t[0],r=t[1];return 3*(n+r)/4-r},n.toByteArray=function(e){var t,n,r=c(e),s=r[0],a=r[1],l=new i(function(e,t,n){return 3*(t+n)/4-n}(0,s,a)),u=0,d=a>0?s-4:s;for(n=0;n<d;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],l[u++]=t>>16&255,l[u++]=t>>8&255,l[u++]=255&t;2===a&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,l[u++]=255&t);1===a&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,l[u++]=t>>8&255,l[u++]=255&t);return l},n.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=16383,a=0,l=n-o;a<l;a+=s)i.push(u(e,a,a+s>l?l:a+s));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,l=s.length;a<l;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function c(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function u(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},{}],2:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/try-to-string"),s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not a function")}},{"../internals/global":43,"../internals/is-callable":52,"../internals/try-to-string":105}],3:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=r.String,s=r.TypeError;t.exports=function(e){if("object"==typeof e||o(e))return e;throw s("Can't set "+i(e)+" as a prototype")}},{"../internals/global":43,"../internals/is-callable":52}],4:[function(e,t,n){var r=e("../internals/well-known-symbol"),o=e("../internals/object-create"),i=e("../internals/object-define-property"),s=r("unscopables"),a=Array.prototype;null==a[s]&&i.f(a,s,{configurable:!0,value:o(null)}),t.exports=function(e){a[s][e]=!0}},{"../internals/object-create":66,"../internals/object-define-property":68,"../internals/well-known-symbol":110}],5:[function(e,t,n){"use strict";var r=e("../internals/string-multibyte").charAt;t.exports=function(e,t,n){return t+(n?r(e,t).length:1)}},{"../internals/string-multibyte":94}],6:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/object-is-prototype-of"),i=r.TypeError;t.exports=function(e,t){if(o(t,e))return e;throw i("Incorrect invocation")}},{"../internals/global":43,"../internals/object-is-prototype-of":73}],7:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-object"),i=r.String,s=r.TypeError;t.exports=function(e){if(o(e))return e;throw s(i(e)+" is not an object")}},{"../internals/global":43,"../internals/is-object":55}],8:[function(e,t,n){"use strict";var r=e("../internals/global"),o=e("../internals/function-bind-context"),i=e("../internals/function-call"),s=e("../internals/to-object"),a=e("../internals/call-with-safe-iteration-closing"),l=e("../internals/is-array-iterator-method"),c=e("../internals/is-constructor"),u=e("../internals/length-of-array-like"),d=e("../internals/create-property"),f=e("../internals/get-iterator"),p=e("../internals/get-iterator-method"),h=r.Array;t.exports=function(e){var t=s(e),n=c(this),r=arguments.length,m=r>1?arguments[1]:void 0,y=void 0!==m;y&&(m=o(m,r>2?arguments[2]:void 0));var g,v,b,_,w,x,k=p(t),j=0;if(!k||this==h&&l(k))for(g=u(t),v=n?new this(g):h(g);g>j;j++)x=y?m(t[j],j):t[j],d(v,j,x);else for(w=(_=f(t,k)).next,v=n?new this:[];!(b=i(w,_)).done;j++)x=y?a(_,m,[b.value,j],!0):b.value,d(v,j,x);return v.length=j,v}},{"../internals/call-with-safe-iteration-closing":12,"../internals/create-property":20,"../internals/function-bind-context":33,"../internals/function-call":35,"../internals/get-iterator":40,"../internals/get-iterator-method":39,"../internals/global":43,"../internals/is-array-iterator-method":51,"../internals/is-constructor":53,"../internals/length-of-array-like":61,"../internals/to-object":100}],9:[function(e,t,n){var r=e("../internals/to-indexed-object"),o=e("../internals/to-absolute-index"),i=e("../internals/length-of-array-like"),s=function(e){return function(t,n,s){var a,l=r(t),c=i(l),u=o(s,c);if(e&&n!=n){for(;c>u;)if((a=l[u++])!=a)return!0}else for(;c>u;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},{"../internals/length-of-array-like":61,"../internals/to-absolute-index":96,"../internals/to-indexed-object":97}],10:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-absolute-index"),i=e("../internals/length-of-array-like"),s=e("../internals/create-property"),a=r.Array,l=Math.max;t.exports=function(e,t,n){for(var r=i(e),c=o(t,r),u=o(void 0===n?r:n,r),d=a(l(u-c,0)),f=0;c<u;c++,f++)s(d,f,e[c]);return d.length=f,d}},{"../internals/create-property":20,"../internals/global":43,"../internals/length-of-array-like":61,"../internals/to-absolute-index":96}],11:[function(e,t,n){var r=e("../internals/array-slice-simple"),o=Math.floor,i=function(e,t){var n=e.length,l=o(n/2);return n<8?s(e,t):a(e,i(r(e,0,l),t),i(r(e,l),t),t)},s=function(e,t){for(var n,r,o=e.length,i=1;i<o;){for(r=i,n=e[i];r&&t(e[r-1],n)>0;)e[r]=e[--r];r!==i++&&(e[r]=n)}return e},a=function(e,t,n,r){for(var o=t.length,i=n.length,s=0,a=0;s<o||a<i;)e[s+a]=s<o&&a<i?r(t[s],n[a])<=0?t[s++]:n[a++]:s<o?t[s++]:n[a++];return e};t.exports=i},{"../internals/array-slice-simple":10}],12:[function(e,t,n){var r=e("../internals/an-object"),o=e("../internals/iterator-close");t.exports=function(e,t,n,i){try{return i?t(r(n)[0],n[1]):t(n)}catch(t){o(e,"throw",t)}}},{"../internals/an-object":7,"../internals/iterator-close":58}],13:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=r({}.toString),i=r("".slice);t.exports=function(e){return i(o(e),8,-1)}},{"../internals/function-uncurry-this":37}],14:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/to-string-tag-support"),i=e("../internals/is-callable"),s=e("../internals/classof-raw"),a=e("../internals/well-known-symbol")("toStringTag"),l=r.Object,c="Arguments"==s(function(){return arguments}());t.exports=o?s:function(e){var t,n,r;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=l(e),a))?n:c?s(t):"Object"==(r=s(t))&&i(t.callee)?"Arguments":r}},{"../internals/classof-raw":13,"../internals/global":43,"../internals/is-callable":52,"../internals/to-string-tag-support":103,"../internals/well-known-symbol":110}],15:[function(e,t,n){var r=e("../internals/has-own-property"),o=e("../internals/own-keys"),i=e("../internals/object-get-own-property-descriptor"),s=e("../internals/object-define-property");t.exports=function(e,t,n){for(var a=o(t),l=s.f,c=i.f,u=0;u<a.length;u++){var d=a[u];r(e,d)||n&&r(n,d)||l(e,d,c(t,d))}}},{"../internals/has-own-property":44,"../internals/object-define-property":68,"../internals/object-get-own-property-descriptor":69,"../internals/own-keys":79}],16:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},{"../internals/fails":30}],17:[function(e,t,n){"use strict";var r=e("../internals/iterators-core").IteratorPrototype,o=e("../internals/object-create"),i=e("../internals/create-property-descriptor"),s=e("../internals/set-to-string-tag"),a=e("../internals/iterators"),l=function(){return this};t.exports=function(e,t,n,c){var u=t+" Iterator";return e.prototype=o(r,{next:i(+!c,n)}),s(e,u,!1,!0),a[u]=l,e}},{"../internals/create-property-descriptor":19,"../internals/iterators":60,"../internals/iterators-core":59,"../internals/object-create":66,"../internals/set-to-string-tag":90}],18:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/object-define-property"),i=e("../internals/create-property-descriptor");t.exports=r?function(e,t,n){return o.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},{"../internals/create-property-descriptor":19,"../internals/descriptors":22,"../internals/object-define-property":68}],19:[function(e,t,n){t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},{}],20:[function(e,t,n){"use strict";var r=e("../internals/to-property-key"),o=e("../internals/object-define-property"),i=e("../internals/create-property-descriptor");t.exports=function(e,t,n){var s=r(t);s in e?o.f(e,s,i(0,n)):e[s]=n}},{"../internals/create-property-descriptor":19,"../internals/object-define-property":68,"../internals/to-property-key":102}],21:[function(e,t,n){"use strict";var r=e("../internals/export"),o=e("../internals/function-call"),i=e("../internals/is-pure"),s=e("../internals/function-name"),a=e("../internals/is-callable"),l=e("../internals/create-iterator-constructor"),c=e("../internals/object-get-prototype-of"),u=e("../internals/object-set-prototype-of"),d=e("../internals/set-to-string-tag"),f=e("../internals/create-non-enumerable-property"),p=e("../internals/redefine"),h=e("../internals/well-known-symbol"),m=e("../internals/iterators"),y=e("../internals/iterators-core"),g=s.PROPER,v=s.CONFIGURABLE,b=y.IteratorPrototype,_=y.BUGGY_SAFARI_ITERATORS,w=h("iterator"),x="keys",k="values",j="entries",C=function(){return this};t.exports=function(e,t,n,s,h,y,E){l(n,t,s);var D,S,O,P=function(e){if(e===h&&I)return I;if(!_&&e in T)return T[e];switch(e){case x:case k:case j:return function(){return new n(this,e)}}return function(){return new n(this)}},B=t+" Iterator",M=!1,T=e.prototype,A=T[w]||T["@@iterator"]||h&&T[h],I=!_&&A||P(h),K="Array"==t&&T.entries||A;if(K&&(D=c(K.call(new e)))!==Object.prototype&&D.next&&(i||c(D)===b||(u?u(D,b):a(D[w])||p(D,w,C)),d(D,B,!0,!0),i&&(m[B]=C)),g&&h==k&&A&&A.name!==k&&(!i&&v?f(T,"name",k):(M=!0,I=function(){return o(A,this)})),h)if(S={values:P(k),keys:y?I:P(x),entries:P(j)},E)for(O in S)(_||M||!(O in T))&&p(T,O,S[O]);else r({target:t,proto:!0,forced:_||M},S);return i&&!E||T[w]===I||p(T,w,I,{name:h}),m[t]=I,S}},{"../internals/create-iterator-constructor":17,"../internals/create-non-enumerable-property":18,"../internals/export":29,"../internals/function-call":35,"../internals/function-name":36,"../internals/is-callable":52,"../internals/is-pure":56,"../internals/iterators":60,"../internals/iterators-core":59,"../internals/object-get-prototype-of":72,"../internals/object-set-prototype-of":77,"../internals/redefine":81,"../internals/set-to-string-tag":90,"../internals/well-known-symbol":110}],22:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},{"../internals/fails":30}],23:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-object"),i=r.document,s=o(i)&&o(i.createElement);t.exports=function(e){return s?i.createElement(e):{}}},{"../internals/global":43,"../internals/is-object":55}],24:[function(e,t,n){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},{}],25:[function(e,t,n){var r=e("../internals/document-create-element")("span").classList,o=r&&r.constructor&&r.constructor.prototype;t.exports=o===Object.prototype?void 0:o},{"../internals/document-create-element":23}],26:[function(e,t,n){var r=e("../internals/get-built-in");t.exports=r("navigator","userAgent")||""},{"../internals/get-built-in":38}],27:[function(e,t,n){var r,o,i=e("../internals/global"),s=e("../internals/engine-user-agent"),a=i.process,l=i.Deno,c=a&&a.versions||l&&l.version,u=c&&c.v8;u&&(o=(r=u.split("."))[0]>0&&r[0]<4?1:+(r[0]+r[1])),!o&&s&&(!(r=s.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/))&&(o=+r[1]),t.exports=o},{"../internals/engine-user-agent":26,"../internals/global":43}],28:[function(e,t,n){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},{}],29:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/object-get-own-property-descriptor").f,i=e("../internals/create-non-enumerable-property"),s=e("../internals/redefine"),a=e("../internals/set-global"),l=e("../internals/copy-constructor-properties"),c=e("../internals/is-forced");t.exports=function(e,t){var n,u,d,f,p,h=e.target,m=e.global,y=e.stat;if(n=m?r:y?r[h]||a(h,{}):(r[h]||{}).prototype)for(u in t){if(f=t[u],d=e.noTargetGet?(p=o(n,u))&&p.value:n[u],!c(m?u:h+(y?".":"#")+u,e.forced)&&void 0!==d){if(typeof f==typeof d)continue;l(f,d)}(e.sham||d&&d.sham)&&i(f,"sham",!0),s(n,u,f,e)}}},{"../internals/copy-constructor-properties":15,"../internals/create-non-enumerable-property":18,"../internals/global":43,"../internals/is-forced":54,"../internals/object-get-own-property-descriptor":69,"../internals/redefine":81,"../internals/set-global":89}],30:[function(e,t,n){t.exports=function(e){try{return!!e()}catch(e){return!0}}},{}],31:[function(e,t,n){"use strict";e("../modules/es.regexp.exec");var r=e("../internals/function-uncurry-this"),o=e("../internals/redefine"),i=e("../internals/regexp-exec"),s=e("../internals/fails"),a=e("../internals/well-known-symbol"),l=e("../internals/create-non-enumerable-property"),c=a("species"),u=RegExp.prototype;t.exports=function(e,t,n,d){var f=a(e),p=!s((function(){var t={};return t[f]=function(){return 7},7!=""[e](t)})),h=p&&!s((function(){var t=!1,n=/a/;return"split"===e&&((n={}).constructor={},n.constructor[c]=function(){return n},n.flags="",n[f]=/./[f]),n.exec=function(){return t=!0,null},n[f](""),!t}));if(!p||!h||n){var m=r(/./[f]),y=t(f,""[e],(function(e,t,n,o,s){var a=r(e),l=t.exec;return l===i||l===u.exec?p&&!s?{done:!0,value:m(t,n,o)}:{done:!0,value:a(n,t,o)}:{done:!1}}));o(String.prototype,e,y[0]),o(u,f,y[1])}d&&l(u[f],"sham",!0)}},{"../internals/create-non-enumerable-property":18,"../internals/fails":30,"../internals/function-uncurry-this":37,"../internals/redefine":81,"../internals/regexp-exec":83,"../internals/well-known-symbol":110,"../modules/es.regexp.exec":112}],32:[function(e,t,n){var r=e("../internals/function-bind-native"),o=Function.prototype,i=o.apply,s=o.call;t.exports="object"==typeof Reflect&&Reflect.apply||(r?s.bind(i):function(){return s.apply(i,arguments)})},{"../internals/function-bind-native":34}],33:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/a-callable"),i=e("../internals/function-bind-native"),s=r(r.bind);t.exports=function(e,t){return o(e),void 0===t?e:i?s(e,t):function(){return e.apply(t,arguments)}}},{"../internals/a-callable":2,"../internals/function-bind-native":34,"../internals/function-uncurry-this":37}],34:[function(e,t,n){var r=e("../internals/fails");t.exports=!r((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))},{"../internals/fails":30}],35:[function(e,t,n){var r=e("../internals/function-bind-native"),o=Function.prototype.call;t.exports=r?o.bind(o):function(){return o.apply(o,arguments)}},{"../internals/function-bind-native":34}],36:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/has-own-property"),i=Function.prototype,s=r&&Object.getOwnPropertyDescriptor,a=o(i,"name"),l=a&&"something"===function(){}.name,c=a&&(!r||r&&s(i,"name").configurable);t.exports={EXISTS:a,PROPER:l,CONFIGURABLE:c}},{"../internals/descriptors":22,"../internals/has-own-property":44}],37:[function(e,t,n){var r=e("../internals/function-bind-native"),o=Function.prototype,i=o.bind,s=o.call,a=r&&i.bind(s,s);t.exports=r?function(e){return e&&a(e)}:function(e){return e&&function(){return s.apply(e,arguments)}}},{"../internals/function-bind-native":34}],38:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=function(e){return o(e)?e:void 0};t.exports=function(e,t){return arguments.length<2?i(r[e]):r[e]&&r[e][t]}},{"../internals/global":43,"../internals/is-callable":52}],39:[function(e,t,n){var r=e("../internals/classof"),o=e("../internals/get-method"),i=e("../internals/iterators"),s=e("../internals/well-known-symbol")("iterator");t.exports=function(e){if(null!=e)return o(e,s)||o(e,"@@iterator")||i[r(e)]}},{"../internals/classof":14,"../internals/get-method":41,"../internals/iterators":60,"../internals/well-known-symbol":110}],40:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/a-callable"),s=e("../internals/an-object"),a=e("../internals/try-to-string"),l=e("../internals/get-iterator-method"),c=r.TypeError;t.exports=function(e,t){var n=arguments.length<2?l(e):t;if(i(n))return s(o(n,e));throw c(a(e)+" is not iterable")}},{"../internals/a-callable":2,"../internals/an-object":7,"../internals/function-call":35,"../internals/get-iterator-method":39,"../internals/global":43,"../internals/try-to-string":105}],41:[function(e,t,n){var r=e("../internals/a-callable");t.exports=function(e,t){var n=e[t];return null==n?void 0:r(n)}},{"../internals/a-callable":2}],42:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/to-object"),i=Math.floor,s=r("".charAt),a=r("".replace),l=r("".slice),c=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,u=/\$([$&'`]|\d{1,2})/g;t.exports=function(e,t,n,r,d,f){var p=n+e.length,h=r.length,m=u;return void 0!==d&&(d=o(d),m=c),a(f,m,(function(o,a){var c;switch(s(a,0)){case"$":return"$";case"&":return e;case"`":return l(t,0,n);case"'":return l(t,p);case"<":c=d[l(a,1,-1)];break;default:var u=+a;if(0===u)return o;if(u>h){var f=i(u/10);return 0===f?o:f<=h?void 0===r[f-1]?s(a,1):r[f-1]+s(a,1):o}c=r[u-1]}return void 0===c?"":c}))}},{"../internals/function-uncurry-this":37,"../internals/to-object":100}],43:[function(e,t,n){(function(e){(function(){var n=function(e){return e&&e.Math==Math&&e};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||function(){return this}()||Function("return this")()}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],44:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/to-object"),i=r({}.hasOwnProperty);t.exports=Object.hasOwn||function(e,t){return i(o(e),t)}},{"../internals/function-uncurry-this":37,"../internals/to-object":100}],45:[function(e,t,n){t.exports={}},{}],46:[function(e,t,n){var r=e("../internals/get-built-in");t.exports=r("document","documentElement")},{"../internals/get-built-in":38}],47:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/fails"),i=e("../internals/document-create-element");t.exports=!r&&!o((function(){return 7!=Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},{"../internals/descriptors":22,"../internals/document-create-element":23,"../internals/fails":30}],48:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=e("../internals/fails"),s=e("../internals/classof-raw"),a=r.Object,l=o("".split);t.exports=i((function(){return!a("z").propertyIsEnumerable(0)}))?function(e){return"String"==s(e)?l(e,""):a(e)}:a},{"../internals/classof-raw":13,"../internals/fails":30,"../internals/function-uncurry-this":37,"../internals/global":43}],49:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/is-callable"),i=e("../internals/shared-store"),s=r(Function.toString);o(i.inspectSource)||(i.inspectSource=function(e){return s(e)}),t.exports=i.inspectSource},{"../internals/function-uncurry-this":37,"../internals/is-callable":52,"../internals/shared-store":92}],50:[function(e,t,n){var r,o,i,s=e("../internals/native-weak-map"),a=e("../internals/global"),l=e("../internals/function-uncurry-this"),c=e("../internals/is-object"),u=e("../internals/create-non-enumerable-property"),d=e("../internals/has-own-property"),f=e("../internals/shared-store"),p=e("../internals/shared-key"),h=e("../internals/hidden-keys"),m="Object already initialized",y=a.TypeError,g=a.WeakMap;if(s||f.state){var v=f.state||(f.state=new g),b=l(v.get),_=l(v.has),w=l(v.set);r=function(e,t){if(_(v,e))throw new y(m);return t.facade=e,w(v,e,t),t},o=function(e){return b(v,e)||{}},i=function(e){return _(v,e)}}else{var x=p("state");h[x]=!0,r=function(e,t){if(d(e,x))throw new y(m);return t.facade=e,u(e,x,t),t},o=function(e){return d(e,x)?e[x]:{}},i=function(e){return d(e,x)}}t.exports={set:r,get:o,has:i,enforce:function(e){return i(e)?o(e):r(e,{})},getterFor:function(e){return function(t){var n;if(!c(t)||(n=o(t)).type!==e)throw y("Incompatible receiver, "+e+" required");return n}}}},{"../internals/create-non-enumerable-property":18,"../internals/function-uncurry-this":37,"../internals/global":43,"../internals/has-own-property":44,"../internals/hidden-keys":45,"../internals/is-object":55,"../internals/native-weak-map":64,"../internals/shared-key":91,"../internals/shared-store":92}],51:[function(e,t,n){var r=e("../internals/well-known-symbol"),o=e("../internals/iterators"),i=r("iterator"),s=Array.prototype;t.exports=function(e){return void 0!==e&&(o.Array===e||s[i]===e)}},{"../internals/iterators":60,"../internals/well-known-symbol":110}],52:[function(e,t,n){t.exports=function(e){return"function"==typeof e}},{}],53:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/fails"),i=e("../internals/is-callable"),s=e("../internals/classof"),a=e("../internals/get-built-in"),l=e("../internals/inspect-source"),c=function(){},u=[],d=a("Reflect","construct"),f=/^\s*(?:class|function)\b/,p=r(f.exec),h=!f.exec(c),m=function(e){if(!i(e))return!1;try{return d(c,u,e),!0}catch(e){return!1}},y=function(e){if(!i(e))return!1;switch(s(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return h||!!p(f,l(e))}catch(e){return!0}};y.sham=!0,t.exports=!d||o((function(){var e;return m(m.call)||!m(Object)||!m((function(){e=!0}))||e}))?y:m},{"../internals/classof":14,"../internals/fails":30,"../internals/function-uncurry-this":37,"../internals/get-built-in":38,"../internals/inspect-source":49,"../internals/is-callable":52}],54:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/is-callable"),i=/#|\.prototype\./,s=function(e,t){var n=l[a(e)];return n==u||n!=c&&(o(t)?r(t):!!t)},a=s.normalize=function(e){return String(e).replace(i,".").toLowerCase()},l=s.data={},c=s.NATIVE="N",u=s.POLYFILL="P";t.exports=s},{"../internals/fails":30,"../internals/is-callable":52}],55:[function(e,t,n){var r=e("../internals/is-callable");t.exports=function(e){return"object"==typeof e?null!==e:r(e)}},{"../internals/is-callable":52}],56:[function(e,t,n){t.exports=!1},{}],57:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/get-built-in"),i=e("../internals/is-callable"),s=e("../internals/object-is-prototype-of"),a=e("../internals/use-symbol-as-uid"),l=r.Object;t.exports=a?function(e){return"symbol"==typeof e}:function(e){var t=o("Symbol");return i(t)&&s(t.prototype,l(e))}},{"../internals/get-built-in":38,"../internals/global":43,"../internals/is-callable":52,"../internals/object-is-prototype-of":73,"../internals/use-symbol-as-uid":107}],58:[function(e,t,n){var r=e("../internals/function-call"),o=e("../internals/an-object"),i=e("../internals/get-method");t.exports=function(e,t,n){var s,a;o(e);try{if(!(s=i(e,"return"))){if("throw"===t)throw n;return n}s=r(s,e)}catch(e){a=!0,s=e}if("throw"===t)throw n;if(a)throw s;return o(s),n}},{"../internals/an-object":7,"../internals/function-call":35,"../internals/get-method":41}],59:[function(e,t,n){"use strict";var r,o,i,s=e("../internals/fails"),a=e("../internals/is-callable"),l=e("../internals/object-create"),c=e("../internals/object-get-prototype-of"),u=e("../internals/redefine"),d=e("../internals/well-known-symbol"),f=e("../internals/is-pure"),p=d("iterator"),h=!1;[].keys&&("next"in(i=[].keys())?(o=c(c(i)))!==Object.prototype&&(r=o):h=!0),null==r||s((function(){var e={};return r[p].call(e)!==e}))?r={}:f&&(r=l(r)),a(r[p])||u(r,p,(function(){return this})),t.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:h}},{"../internals/fails":30,"../internals/is-callable":52,"../internals/is-pure":56,"../internals/object-create":66,"../internals/object-get-prototype-of":72,"../internals/redefine":81,"../internals/well-known-symbol":110}],60:[function(e,t,n){arguments[4][45][0].apply(n,arguments)},{dup:45}],61:[function(e,t,n){var r=e("../internals/to-length");t.exports=function(e){return r(e.length)}},{"../internals/to-length":99}],62:[function(e,t,n){var r=e("../internals/engine-v8-version"),o=e("../internals/fails");t.exports=!!Object.getOwnPropertySymbols&&!o((function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},{"../internals/engine-v8-version":27,"../internals/fails":30}],63:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/well-known-symbol"),i=e("../internals/is-pure"),s=o("iterator");t.exports=!r((function(){var e=new URL("b?a=1&b=2&c=3","http://a"),t=e.searchParams,n="";return e.pathname="c%20d",t.forEach((function(e,r){t.delete("b"),n+=r+e})),i&&!e.toJSON||!t.sort||"http://a/c%20d?a=1&c=3"!==e.href||"3"!==t.get("c")||"a=1"!==String(new URLSearchParams("?a=1"))||!t[s]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://тест").host||"#%D0%B1"!==new URL("http://a#б").hash||"a1c3"!==n||"x"!==new URL("http://x",void 0).host}))},{"../internals/fails":30,"../internals/is-pure":56,"../internals/well-known-symbol":110}],64:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/inspect-source"),s=r.WeakMap;t.exports=o(s)&&/native code/.test(i(s))},{"../internals/global":43,"../internals/inspect-source":49,"../internals/is-callable":52}],65:[function(e,t,n){"use strict";var r=e("../internals/descriptors"),o=e("../internals/function-uncurry-this"),i=e("../internals/function-call"),s=e("../internals/fails"),a=e("../internals/object-keys"),l=e("../internals/object-get-own-property-symbols"),c=e("../internals/object-property-is-enumerable"),u=e("../internals/to-object"),d=e("../internals/indexed-object"),f=Object.assign,p=Object.defineProperty,h=o([].concat);t.exports=!f||s((function(){if(r&&1!==f({b:1},f(p({},"a",{enumerable:!0,get:function(){p(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var e={},t={},n=Symbol(),o="abcdefghijklmnopqrst";return e[n]=7,o.split("").forEach((function(e){t[e]=e})),7!=f({},e)[n]||a(f({},t)).join("")!=o}))?function(e,t){for(var n=u(e),o=arguments.length,s=1,f=l.f,p=c.f;o>s;)for(var m,y=d(arguments[s++]),g=f?h(a(y),f(y)):a(y),v=g.length,b=0;v>b;)m=g[b++],r&&!i(p,y,m)||(n[m]=y[m]);return n}:f},{"../internals/descriptors":22,"../internals/fails":30,"../internals/function-call":35,"../internals/function-uncurry-this":37,"../internals/indexed-object":48,"../internals/object-get-own-property-symbols":71,"../internals/object-keys":75,"../internals/object-property-is-enumerable":76,"../internals/to-object":100}],66:[function(e,t,n){var r,o=e("../internals/an-object"),i=e("../internals/object-define-properties"),s=e("../internals/enum-bug-keys"),a=e("../internals/hidden-keys"),l=e("../internals/html"),c=e("../internals/document-create-element"),u=e("../internals/shared-key"),d=u("IE_PROTO"),f=function(){},p=function(e){return"<script>"+e+"</"+"script>"},h=function(e){e.write(p("")),e.close();var t=e.parentWindow.Object;return e=null,t},m=function(){try{r=new ActiveXObject("htmlfile")}catch(e){}var e,t;m="undefined"!=typeof document?document.domain&&r?h(r):((t=c("iframe")).style.display="none",l.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(p("document.F=Object")),e.close(),e.F):h(r);for(var n=s.length;n--;)delete m.prototype[s[n]];return m()};a[d]=!0,t.exports=Object.create||function(e,t){var n;return null!==e?(f.prototype=o(e),n=new f,f.prototype=null,n[d]=e):n=m(),void 0===t?n:i.f(n,t)}},{"../internals/an-object":7,"../internals/document-create-element":23,"../internals/enum-bug-keys":28,"../internals/hidden-keys":45,"../internals/html":46,"../internals/object-define-properties":67,"../internals/shared-key":91}],67:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/v8-prototype-define-bug"),i=e("../internals/object-define-property"),s=e("../internals/an-object"),a=e("../internals/to-indexed-object"),l=e("../internals/object-keys");n.f=r&&!o?Object.defineProperties:function(e,t){s(e);for(var n,r=a(t),o=l(t),c=o.length,u=0;c>u;)i.f(e,n=o[u++],r[n]);return e}},{"../internals/an-object":7,"../internals/descriptors":22,"../internals/object-define-property":68,"../internals/object-keys":75,"../internals/to-indexed-object":97,"../internals/v8-prototype-define-bug":108}],68:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/descriptors"),i=e("../internals/ie8-dom-define"),s=e("../internals/v8-prototype-define-bug"),a=e("../internals/an-object"),l=e("../internals/to-property-key"),c=r.TypeError,u=Object.defineProperty,d=Object.getOwnPropertyDescriptor,f="enumerable",p="configurable",h="writable";n.f=o?s?function(e,t,n){if(a(e),t=l(t),a(n),"function"==typeof e&&"prototype"===t&&"value"in n&&h in n&&!n.writable){var r=d(e,t);r&&r.writable&&(e[t]=n.value,n={configurable:p in n?n.configurable:r.configurable,enumerable:f in n?n.enumerable:r.enumerable,writable:!1})}return u(e,t,n)}:u:function(e,t,n){if(a(e),t=l(t),a(n),i)try{return u(e,t,n)}catch(e){}if("get"in n||"set"in n)throw c("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},{"../internals/an-object":7,"../internals/descriptors":22,"../internals/global":43,"../internals/ie8-dom-define":47,"../internals/to-property-key":102,"../internals/v8-prototype-define-bug":108}],69:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/function-call"),i=e("../internals/object-property-is-enumerable"),s=e("../internals/create-property-descriptor"),a=e("../internals/to-indexed-object"),l=e("../internals/to-property-key"),c=e("../internals/has-own-property"),u=e("../internals/ie8-dom-define"),d=Object.getOwnPropertyDescriptor;n.f=r?d:function(e,t){if(e=a(e),t=l(t),u)try{return d(e,t)}catch(e){}if(c(e,t))return s(!o(i.f,e,t),e[t])}},{"../internals/create-property-descriptor":19,"../internals/descriptors":22,"../internals/function-call":35,"../internals/has-own-property":44,"../internals/ie8-dom-define":47,"../internals/object-property-is-enumerable":76,"../internals/to-indexed-object":97,"../internals/to-property-key":102}],70:[function(e,t,n){var r=e("../internals/object-keys-internal"),o=e("../internals/enum-bug-keys").concat("length","prototype");n.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},{"../internals/enum-bug-keys":28,"../internals/object-keys-internal":74}],71:[function(e,t,n){n.f=Object.getOwnPropertySymbols},{}],72:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/has-own-property"),i=e("../internals/is-callable"),s=e("../internals/to-object"),a=e("../internals/shared-key"),l=e("../internals/correct-prototype-getter"),c=a("IE_PROTO"),u=r.Object,d=u.prototype;t.exports=l?u.getPrototypeOf:function(e){var t=s(e);if(o(t,c))return t[c];var n=t.constructor;return i(n)&&t instanceof n?n.prototype:t instanceof u?d:null}},{"../internals/correct-prototype-getter":16,"../internals/global":43,"../internals/has-own-property":44,"../internals/is-callable":52,"../internals/shared-key":91,"../internals/to-object":100}],73:[function(e,t,n){var r=e("../internals/function-uncurry-this");t.exports=r({}.isPrototypeOf)},{"../internals/function-uncurry-this":37}],74:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/has-own-property"),i=e("../internals/to-indexed-object"),s=e("../internals/array-includes").indexOf,a=e("../internals/hidden-keys"),l=r([].push);t.exports=function(e,t){var n,r=i(e),c=0,u=[];for(n in r)!o(a,n)&&o(r,n)&&l(u,n);for(;t.length>c;)o(r,n=t[c++])&&(~s(u,n)||l(u,n));return u}},{"../internals/array-includes":9,"../internals/function-uncurry-this":37,"../internals/has-own-property":44,"../internals/hidden-keys":45,"../internals/to-indexed-object":97}],75:[function(e,t,n){var r=e("../internals/object-keys-internal"),o=e("../internals/enum-bug-keys");t.exports=Object.keys||function(e){return r(e,o)}},{"../internals/enum-bug-keys":28,"../internals/object-keys-internal":74}],76:[function(e,t,n){"use strict";var r={}.propertyIsEnumerable,o=Object.getOwnPropertyDescriptor,i=o&&!r.call({1:2},1);n.f=i?function(e){var t=o(this,e);return!!t&&t.enumerable}:r},{}],77:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/an-object"),i=e("../internals/a-possible-prototype");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{(e=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),t=n instanceof Array}catch(e){}return function(n,r){return o(n),i(r),t?e(n,r):n.__proto__=r,n}}():void 0)},{"../internals/a-possible-prototype":3,"../internals/an-object":7,"../internals/function-uncurry-this":37}],78:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/is-callable"),s=e("../internals/is-object"),a=r.TypeError;t.exports=function(e,t){var n,r;if("string"===t&&i(n=e.toString)&&!s(r=o(n,e)))return r;if(i(n=e.valueOf)&&!s(r=o(n,e)))return r;if("string"!==t&&i(n=e.toString)&&!s(r=o(n,e)))return r;throw a("Can't convert object to primitive value")}},{"../internals/function-call":35,"../internals/global":43,"../internals/is-callable":52,"../internals/is-object":55}],79:[function(e,t,n){var r=e("../internals/get-built-in"),o=e("../internals/function-uncurry-this"),i=e("../internals/object-get-own-property-names"),s=e("../internals/object-get-own-property-symbols"),a=e("../internals/an-object"),l=o([].concat);t.exports=r("Reflect","ownKeys")||function(e){var t=i.f(a(e)),n=s.f;return n?l(t,n(e)):t}},{"../internals/an-object":7,"../internals/function-uncurry-this":37,"../internals/get-built-in":38,"../internals/object-get-own-property-names":70,"../internals/object-get-own-property-symbols":71}],80:[function(e,t,n){var r=e("../internals/redefine");t.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},{"../internals/redefine":81}],81:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/is-callable"),i=e("../internals/has-own-property"),s=e("../internals/create-non-enumerable-property"),a=e("../internals/set-global"),l=e("../internals/inspect-source"),c=e("../internals/internal-state"),u=e("../internals/function-name").CONFIGURABLE,d=c.get,f=c.enforce,p=String(String).split("String");(t.exports=function(e,t,n,l){var c,d=!!l&&!!l.unsafe,h=!!l&&!!l.enumerable,m=!!l&&!!l.noTargetGet,y=l&&void 0!==l.name?l.name:t;o(n)&&("Symbol("===String(y).slice(0,7)&&(y="["+String(y).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!i(n,"name")||u&&n.name!==y)&&s(n,"name",y),(c=f(n)).source||(c.source=p.join("string"==typeof y?y:""))),e!==r?(d?!m&&e[t]&&(h=!0):delete e[t],h?e[t]=n:s(e,t,n)):h?e[t]=n:a(t,n)})(Function.prototype,"toString",(function(){return o(this)&&d(this).source||l(this)}))},{"../internals/create-non-enumerable-property":18,"../internals/function-name":36,"../internals/global":43,"../internals/has-own-property":44,"../internals/inspect-source":49,"../internals/internal-state":50,"../internals/is-callable":52,"../internals/set-global":89}],82:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/an-object"),s=e("../internals/is-callable"),a=e("../internals/classof-raw"),l=e("../internals/regexp-exec"),c=r.TypeError;t.exports=function(e,t){var n=e.exec;if(s(n)){var r=o(n,e,t);return null!==r&&i(r),r}if("RegExp"===a(e))return o(l,e,t);throw c("RegExp#exec called on incompatible receiver")}},{"../internals/an-object":7,"../internals/classof-raw":13,"../internals/function-call":35,"../internals/global":43,"../internals/is-callable":52,"../internals/regexp-exec":83}],83:[function(e,t,n){"use strict";var r,o,i=e("../internals/function-call"),s=e("../internals/function-uncurry-this"),a=e("../internals/to-string"),l=e("../internals/regexp-flags"),c=e("../internals/regexp-sticky-helpers"),u=e("../internals/shared"),d=e("../internals/object-create"),f=e("../internals/internal-state").get,p=e("../internals/regexp-unsupported-dot-all"),h=e("../internals/regexp-unsupported-ncg"),m=u("native-string-replace",String.prototype.replace),y=RegExp.prototype.exec,g=y,v=s("".charAt),b=s("".indexOf),_=s("".replace),w=s("".slice),x=(o=/b*/g,i(y,r=/a/,"a"),i(y,o,"a"),0!==r.lastIndex||0!==o.lastIndex),k=c.BROKEN_CARET,j=void 0!==/()??/.exec("")[1];(x||j||k||p||h)&&(g=function(e){var t,n,r,o,s,c,u,p=this,h=f(p),C=a(e),E=h.raw;if(E)return E.lastIndex=p.lastIndex,t=i(g,E,C),p.lastIndex=E.lastIndex,t;var D=h.groups,S=k&&p.sticky,O=i(l,p),P=p.source,B=0,M=C;if(S&&(O=_(O,"y",""),-1===b(O,"g")&&(O+="g"),M=w(C,p.lastIndex),p.lastIndex>0&&(!p.multiline||p.multiline&&"\n"!==v(C,p.lastIndex-1))&&(P="(?: "+P+")",M=" "+M,B++),n=new RegExp("^(?:"+P+")",O)),j&&(n=new RegExp("^"+P+"$(?!\\s)",O)),x&&(r=p.lastIndex),o=i(y,S?n:p,M),S?o?(o.input=w(o.input,B),o[0]=w(o[0],B),o.index=p.lastIndex,p.lastIndex+=o[0].length):p.lastIndex=0:x&&o&&(p.lastIndex=p.global?o.index+o[0].length:r),j&&o&&o.length>1&&i(m,o[0],n,(function(){for(s=1;s<arguments.length-2;s++)void 0===arguments[s]&&(o[s]=void 0)})),o&&D)for(o.groups=c=d(null),s=0;s<D.length;s++)c[(u=D[s])[0]]=o[u[1]];return o}),t.exports=g},{"../internals/function-call":35,"../internals/function-uncurry-this":37,"../internals/internal-state":50,"../internals/object-create":66,"../internals/regexp-flags":84,"../internals/regexp-sticky-helpers":85,"../internals/regexp-unsupported-dot-all":86,"../internals/regexp-unsupported-ncg":87,"../internals/shared":93,"../internals/to-string":104}],84:[function(e,t,n){"use strict";var r=e("../internals/an-object");t.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},{"../internals/an-object":7}],85:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/global").RegExp,i=r((function(){var e=o("a","y");return e.lastIndex=2,null!=e.exec("abcd")})),s=i||r((function(){return!o("a","y").sticky})),a=i||r((function(){var e=o("^r","gy");return e.lastIndex=2,null!=e.exec("str")}));t.exports={BROKEN_CARET:a,MISSED_STICKY:s,UNSUPPORTED_Y:i}},{"../internals/fails":30,"../internals/global":43}],86:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/global").RegExp;t.exports=r((function(){var e=o(".","s");return!(e.dotAll&&e.exec("\n")&&"s"===e.flags)}))},{"../internals/fails":30,"../internals/global":43}],87:[function(e,t,n){var r=e("../internals/fails"),o=e("../internals/global").RegExp;t.exports=r((function(){var e=o("(?<a>b)","g");return"b"!==e.exec("b").groups.a||"bc"!=="b".replace(e,"$<a>c")}))},{"../internals/fails":30,"../internals/global":43}],88:[function(e,t,n){var r=e("../internals/global").TypeError;t.exports=function(e){if(null==e)throw r("Can't call method on "+e);return e}},{"../internals/global":43}],89:[function(e,t,n){var r=e("../internals/global"),o=Object.defineProperty;t.exports=function(e,t){try{o(r,e,{value:t,configurable:!0,writable:!0})}catch(n){r[e]=t}return t}},{"../internals/global":43}],90:[function(e,t,n){var r=e("../internals/object-define-property").f,o=e("../internals/has-own-property"),i=e("../internals/well-known-symbol")("toStringTag");t.exports=function(e,t,n){e&&!n&&(e=e.prototype),e&&!o(e,i)&&r(e,i,{configurable:!0,value:t})}},{"../internals/has-own-property":44,"../internals/object-define-property":68,"../internals/well-known-symbol":110}],91:[function(e,t,n){var r=e("../internals/shared"),o=e("../internals/uid"),i=r("keys");t.exports=function(e){return i[e]||(i[e]=o(e))}},{"../internals/shared":93,"../internals/uid":106}],92:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/set-global"),i="__core-js_shared__",s=r[i]||o(i,{});t.exports=s},{"../internals/global":43,"../internals/set-global":89}],93:[function(e,t,n){var r=e("../internals/is-pure"),o=e("../internals/shared-store");(t.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.21.1",mode:r?"pure":"global",copyright:"© 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.21.1/LICENSE",source:"https://github.com/zloirock/core-js"})},{"../internals/is-pure":56,"../internals/shared-store":92}],94:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=e("../internals/to-integer-or-infinity"),i=e("../internals/to-string"),s=e("../internals/require-object-coercible"),a=r("".charAt),l=r("".charCodeAt),c=r("".slice),u=function(e){return function(t,n){var r,u,d=i(s(t)),f=o(n),p=d.length;return f<0||f>=p?e?"":void 0:(r=l(d,f))<55296||r>56319||f+1===p||(u=l(d,f+1))<56320||u>57343?e?a(d,f):r:e?c(d,f,f+2):u-56320+(r-55296<<10)+65536}};t.exports={codeAt:u(!1),charAt:u(!0)}},{"../internals/function-uncurry-this":37,"../internals/require-object-coercible":88,"../internals/to-integer-or-infinity":98,"../internals/to-string":104}],95:[function(e,t,n){"use strict";var r=e("../internals/global"),o=e("../internals/function-uncurry-this"),i=2147483647,s=/[^\0-\u007E]/,a=/[.\u3002\uFF0E\uFF61]/g,l="Overflow: input needs wider integers to process",c=r.RangeError,u=o(a.exec),d=Math.floor,f=String.fromCharCode,p=o("".charCodeAt),h=o([].join),m=o([].push),y=o("".replace),g=o("".split),v=o("".toLowerCase),b=function(e){return e+22+75*(e<26)},_=function(e,t,n){var r=0;for(e=n?d(e/700):e>>1,e+=d(e/t);e>455;)e=d(e/35),r+=36;return d(r+36*e/(e+38))},w=function(e){var t=[];e=function(e){for(var t=[],n=0,r=e.length;n<r;){var o=p(e,n++);if(o>=55296&&o<=56319&&n<r){var i=p(e,n++);56320==(64512&i)?m(t,((1023&o)<<10)+(1023&i)+65536):(m(t,o),n--)}else m(t,o)}return t}(e);var n,r,o=e.length,s=128,a=0,u=72;for(n=0;n<e.length;n++)(r=e[n])<128&&m(t,f(r));var y=t.length,g=y;for(y&&m(t,"-");g<o;){var v=i;for(n=0;n<e.length;n++)(r=e[n])>=s&&r<v&&(v=r);var w=g+1;if(v-s>d((i-a)/w))throw c(l);for(a+=(v-s)*w,s=v,n=0;n<e.length;n++){if((r=e[n])<s&&++a>i)throw c(l);if(r==s){for(var x=a,k=36;;){var j=k<=u?1:k>=u+26?26:k-u;if(x<j)break;var C=x-j,E=36-j;m(t,f(b(j+C%E))),x=d(C/E),k+=36}m(t,f(b(x))),u=_(a,w,g==y),a=0,g++}}a++,s++}return h(t,"")};t.exports=function(e){var t,n,r=[],o=g(y(v(e),a,"."),".");for(t=0;t<o.length;t++)n=o[t],m(r,u(s,n)?"xn--"+w(n):n);return h(r,".")}},{"../internals/function-uncurry-this":37,"../internals/global":43}],96:[function(e,t,n){var r=e("../internals/to-integer-or-infinity"),o=Math.max,i=Math.min;t.exports=function(e,t){var n=r(e);return n<0?o(n+t,0):i(n,t)}},{"../internals/to-integer-or-infinity":98}],97:[function(e,t,n){var r=e("../internals/indexed-object"),o=e("../internals/require-object-coercible");t.exports=function(e){return r(o(e))}},{"../internals/indexed-object":48,"../internals/require-object-coercible":88}],98:[function(e,t,n){var r=Math.ceil,o=Math.floor;t.exports=function(e){var t=+e;return t!=t||0===t?0:(t>0?o:r)(t)}},{}],99:[function(e,t,n){var r=e("../internals/to-integer-or-infinity"),o=Math.min;t.exports=function(e){return e>0?o(r(e),9007199254740991):0}},{"../internals/to-integer-or-infinity":98}],100:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/require-object-coercible"),i=r.Object;t.exports=function(e){return i(o(e))}},{"../internals/global":43,"../internals/require-object-coercible":88}],101:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/function-call"),i=e("../internals/is-object"),s=e("../internals/is-symbol"),a=e("../internals/get-method"),l=e("../internals/ordinary-to-primitive"),c=e("../internals/well-known-symbol"),u=r.TypeError,d=c("toPrimitive");t.exports=function(e,t){if(!i(e)||s(e))return e;var n,r=a(e,d);if(r){if(void 0===t&&(t="default"),n=o(r,e,t),!i(n)||s(n))return n;throw u("Can't convert object to primitive value")}return void 0===t&&(t="number"),l(e,t)}},{"../internals/function-call":35,"../internals/get-method":41,"../internals/global":43,"../internals/is-object":55,"../internals/is-symbol":57,"../internals/ordinary-to-primitive":78,"../internals/well-known-symbol":110}],102:[function(e,t,n){var r=e("../internals/to-primitive"),o=e("../internals/is-symbol");t.exports=function(e){var t=r(e,"string");return o(t)?t:t+""}},{"../internals/is-symbol":57,"../internals/to-primitive":101}],103:[function(e,t,n){var r={};r[e("../internals/well-known-symbol")("toStringTag")]="z",t.exports="[object z]"===String(r)},{"../internals/well-known-symbol":110}],104:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/classof"),i=r.String;t.exports=function(e){if("Symbol"===o(e))throw TypeError("Cannot convert a Symbol value to a string");return i(e)}},{"../internals/classof":14,"../internals/global":43}],105:[function(e,t,n){var r=e("../internals/global").String;t.exports=function(e){try{return r(e)}catch(e){return"Object"}}},{"../internals/global":43}],106:[function(e,t,n){var r=e("../internals/function-uncurry-this"),o=0,i=Math.random(),s=r(1..toString);t.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+s(++o+i,36)}},{"../internals/function-uncurry-this":37}],107:[function(e,t,n){var r=e("../internals/native-symbol");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},{"../internals/native-symbol":62}],108:[function(e,t,n){var r=e("../internals/descriptors"),o=e("../internals/fails");t.exports=r&&o((function(){return 42!=Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},{"../internals/descriptors":22,"../internals/fails":30}],109:[function(e,t,n){var r=e("../internals/global").TypeError;t.exports=function(e,t){if(e<t)throw r("Not enough arguments");return e}},{"../internals/global":43}],110:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/shared"),i=e("../internals/has-own-property"),s=e("../internals/uid"),a=e("../internals/native-symbol"),l=e("../internals/use-symbol-as-uid"),c=o("wks"),u=r.Symbol,d=u&&u.for,f=l?u:u&&u.withoutSetter||s;t.exports=function(e){if(!i(c,e)||!a&&"string"!=typeof c[e]){var t="Symbol."+e;a&&i(u,e)?c[e]=u[e]:c[e]=l&&d?d(t):f(t)}return c[e]}},{"../internals/global":43,"../internals/has-own-property":44,"../internals/native-symbol":62,"../internals/shared":93,"../internals/uid":106,"../internals/use-symbol-as-uid":107}],111:[function(e,t,n){"use strict";var r=e("../internals/to-indexed-object"),o=e("../internals/add-to-unscopables"),i=e("../internals/iterators"),s=e("../internals/internal-state"),a=e("../internals/object-define-property").f,l=e("../internals/define-iterator"),c=e("../internals/is-pure"),u=e("../internals/descriptors"),d="Array Iterator",f=s.set,p=s.getterFor(d);t.exports=l(Array,"Array",(function(e,t){f(this,{type:d,target:r(e),index:0,kind:t})}),(function(){var e=p(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}}),"values");var h=i.Arguments=i.Array;if(o("keys"),o("values"),o("entries"),!c&&u&&"values"!==h.name)try{a(h,"name",{value:"values"})}catch(e){}},{"../internals/add-to-unscopables":4,"../internals/define-iterator":21,"../internals/descriptors":22,"../internals/internal-state":50,"../internals/is-pure":56,"../internals/iterators":60,"../internals/object-define-property":68,"../internals/to-indexed-object":97}],112:[function(e,t,n){"use strict";var r=e("../internals/export"),o=e("../internals/regexp-exec");r({target:"RegExp",proto:!0,forced:/./.exec!==o},{exec:o})},{"../internals/export":29,"../internals/regexp-exec":83}],113:[function(e,t,n){"use strict";var r=e("../internals/string-multibyte").charAt,o=e("../internals/to-string"),i=e("../internals/internal-state"),s=e("../internals/define-iterator"),a="String Iterator",l=i.set,c=i.getterFor(a);s(String,"String",(function(e){l(this,{type:a,string:o(e),index:0})}),(function(){var e,t=c(this),n=t.string,o=t.index;return o>=n.length?{value:void 0,done:!0}:(e=r(n,o),t.index+=e.length,{value:e,done:!1})}))},{"../internals/define-iterator":21,"../internals/internal-state":50,"../internals/string-multibyte":94,"../internals/to-string":104}],114:[function(e,t,n){"use strict";var r=e("../internals/function-apply"),o=e("../internals/function-call"),i=e("../internals/function-uncurry-this"),s=e("../internals/fix-regexp-well-known-symbol-logic"),a=e("../internals/fails"),l=e("../internals/an-object"),c=e("../internals/is-callable"),u=e("../internals/to-integer-or-infinity"),d=e("../internals/to-length"),f=e("../internals/to-string"),p=e("../internals/require-object-coercible"),h=e("../internals/advance-string-index"),m=e("../internals/get-method"),y=e("../internals/get-substitution"),g=e("../internals/regexp-exec-abstract"),v=e("../internals/well-known-symbol")("replace"),b=Math.max,_=Math.min,w=i([].concat),x=i([].push),k=i("".indexOf),j=i("".slice),C="$0"==="a".replace(/./,"$0"),E=!!/./[v]&&""===/./[v]("a","$0");s("replace",(function(e,t,n){var i=E?"$":"$0";return[function(e,n){var r=p(this),i=null==e?void 0:m(e,v);return i?o(i,e,r,n):o(t,f(r),e,n)},function(e,o){var s=l(this),a=f(e);if("string"==typeof o&&-1===k(o,i)&&-1===k(o,"$<")){var p=n(t,s,a,o);if(p.done)return p.value}var m=c(o);m||(o=f(o));var v=s.global;if(v){var C=s.unicode;s.lastIndex=0}for(var E=[];;){var D=g(s,a);if(null===D)break;if(x(E,D),!v)break;""===f(D[0])&&(s.lastIndex=h(a,d(s.lastIndex),C))}for(var S,O="",P=0,B=0;B<E.length;B++){for(var M=f((D=E[B])[0]),T=b(_(u(D.index),a.length),0),A=[],I=1;I<D.length;I++)x(A,void 0===(S=D[I])?S:String(S));var K=D.groups;if(m){var L=w([M],A,T,a);void 0!==K&&x(L,K);var R=f(r(o,void 0,L))}else R=y(M,a,T,A,K,o);T>=P&&(O+=j(a,P,T)+R,P=T+M.length)}return O+j(a,P)}]}),!!a((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}))||!C||E)},{"../internals/advance-string-index":5,"../internals/an-object":7,"../internals/fails":30,"../internals/fix-regexp-well-known-symbol-logic":31,"../internals/function-apply":32,"../internals/function-call":35,"../internals/function-uncurry-this":37,"../internals/get-method":41,"../internals/get-substitution":42,"../internals/is-callable":52,"../internals/regexp-exec-abstract":82,"../internals/require-object-coercible":88,"../internals/to-integer-or-infinity":98,"../internals/to-length":99,"../internals/to-string":104,"../internals/well-known-symbol":110}],115:[function(e,t,n){var r=e("../internals/global"),o=e("../internals/dom-iterables"),i=e("../internals/dom-token-list-prototype"),s=e("../modules/es.array.iterator"),a=e("../internals/create-non-enumerable-property"),l=e("../internals/well-known-symbol"),c=l("iterator"),u=l("toStringTag"),d=s.values,f=function(e,t){if(e){if(e[c]!==d)try{a(e,c,d)}catch(t){e[c]=d}if(e[u]||a(e,u,t),o[t])for(var n in s)if(e[n]!==s[n])try{a(e,n,s[n])}catch(t){e[n]=s[n]}}};for(var p in o)f(r[p]&&r[p].prototype,p);f(i,"DOMTokenList")},{"../internals/create-non-enumerable-property":18,"../internals/dom-iterables":24,"../internals/dom-token-list-prototype":25,"../internals/global":43,"../internals/well-known-symbol":110,"../modules/es.array.iterator":111}],116:[function(e,t,n){"use strict";e("../modules/es.array.iterator");var r=e("../internals/export"),o=e("../internals/global"),i=e("../internals/get-built-in"),s=e("../internals/function-call"),a=e("../internals/function-uncurry-this"),l=e("../internals/native-url"),c=e("../internals/redefine"),u=e("../internals/redefine-all"),d=e("../internals/set-to-string-tag"),f=e("../internals/create-iterator-constructor"),p=e("../internals/internal-state"),h=e("../internals/an-instance"),m=e("../internals/is-callable"),y=e("../internals/has-own-property"),g=e("../internals/function-bind-context"),v=e("../internals/classof"),b=e("../internals/an-object"),_=e("../internals/is-object"),w=e("../internals/to-string"),x=e("../internals/object-create"),k=e("../internals/create-property-descriptor"),j=e("../internals/get-iterator"),C=e("../internals/get-iterator-method"),E=e("../internals/validate-arguments-length"),D=e("../internals/well-known-symbol"),S=e("../internals/array-sort"),O=D("iterator"),P="URLSearchParams",B="URLSearchParamsIterator",M=p.set,T=p.getterFor(P),A=p.getterFor(B),I=i("fetch"),K=i("Request"),L=i("Headers"),R=K&&K.prototype,N=L&&L.prototype,F=o.RegExp,U=o.TypeError,z=o.decodeURIComponent,H=o.encodeURIComponent,W=a("".charAt),q=a([].join),V=a([].push),G=a("".replace),Y=a([].shift),X=a([].splice),$=a("".split),J=a("".slice),Q=/\+/g,Z=Array(4),ee=function(e){return Z[e-1]||(Z[e-1]=F("((?:%[\\da-f]{2}){"+e+"})","gi"))},te=function(e){try{return z(e)}catch(t){return e}},ne=function(e){var t=G(e,Q," "),n=4;try{return z(t)}catch(e){for(;n;)t=G(t,ee(n--),te);return t}},re=/[!'()~]|%20/g,oe={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},ie=function(e){return oe[e]},se=function(e){return G(H(e),re,ie)},ae=f((function(e,t){M(this,{type:B,iterator:j(T(e).entries),kind:t})}),"Iterator",(function(){var e=A(this),t=e.kind,n=e.iterator.next(),r=n.value;return n.done||(n.value="keys"===t?r.key:"values"===t?r.value:[r.key,r.value]),n}),!0),le=function(e){this.entries=[],this.url=null,void 0!==e&&(_(e)?this.parseObject(e):this.parseQuery("string"==typeof e?"?"===W(e,0)?J(e,1):e:w(e)))};le.prototype={type:P,bindURL:function(e){this.url=e,this.update()},parseObject:function(e){var t,n,r,o,i,a,l,c=C(e);if(c)for(n=(t=j(e,c)).next;!(r=s(n,t)).done;){if(i=(o=j(b(r.value))).next,(a=s(i,o)).done||(l=s(i,o)).done||!s(i,o).done)throw U("Expected sequence with length 2");V(this.entries,{key:w(a.value),value:w(l.value)})}else for(var u in e)y(e,u)&&V(this.entries,{key:u,value:w(e[u])})},parseQuery:function(e){if(e)for(var t,n,r=$(e,"&"),o=0;o<r.length;)(t=r[o++]).length&&(n=$(t,"="),V(this.entries,{key:ne(Y(n)),value:ne(q(n,"="))}))},serialize:function(){for(var e,t=this.entries,n=[],r=0;r<t.length;)e=t[r++],V(n,se(e.key)+"="+se(e.value));return q(n,"&")},update:function(){this.entries.length=0,this.parseQuery(this.url.query)},updateURL:function(){this.url&&this.url.update()}};var ce=function(){h(this,ue);var e=arguments.length>0?arguments[0]:void 0;M(this,new le(e))},ue=ce.prototype;if(u(ue,{append:function(e,t){E(arguments.length,2);var n=T(this);V(n.entries,{key:w(e),value:w(t)}),n.updateURL()},delete:function(e){E(arguments.length,1);for(var t=T(this),n=t.entries,r=w(e),o=0;o<n.length;)n[o].key===r?X(n,o,1):o++;t.updateURL()},get:function(e){E(arguments.length,1);for(var t=T(this).entries,n=w(e),r=0;r<t.length;r++)if(t[r].key===n)return t[r].value;return null},getAll:function(e){E(arguments.length,1);for(var t=T(this).entries,n=w(e),r=[],o=0;o<t.length;o++)t[o].key===n&&V(r,t[o].value);return r},has:function(e){E(arguments.length,1);for(var t=T(this).entries,n=w(e),r=0;r<t.length;)if(t[r++].key===n)return!0;return!1},set:function(e,t){E(arguments.length,1);for(var n,r=T(this),o=r.entries,i=!1,s=w(e),a=w(t),l=0;l<o.length;l++)(n=o[l]).key===s&&(i?X(o,l--,1):(i=!0,n.value=a));i||V(o,{key:s,value:a}),r.updateURL()},sort:function(){var e=T(this);S(e.entries,(function(e,t){return e.key>t.key?1:-1})),e.updateURL()},forEach:function(e){for(var t,n=T(this).entries,r=g(e,arguments.length>1?arguments[1]:void 0),o=0;o<n.length;)r((t=n[o++]).value,t.key,this)},keys:function(){return new ae(this,"keys")},values:function(){return new ae(this,"values")},entries:function(){return new ae(this,"entries")}},{enumerable:!0}),c(ue,O,ue.entries,{name:"entries"}),c(ue,"toString",(function(){return T(this).serialize()}),{enumerable:!0}),d(ce,P),r({global:!0,forced:!l},{URLSearchParams:ce}),!l&&m(L)){var de=a(N.has),fe=a(N.set),pe=function(e){if(_(e)){var t,n=e.body;if(v(n)===P)return t=e.headers?new L(e.headers):new L,de(t,"content-type")||fe(t,"content-type","application/x-www-form-urlencoded;charset=UTF-8"),x(e,{body:k(0,w(n)),headers:k(0,t)})}return e};if(m(I)&&r({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return I(e,arguments.length>1?pe(arguments[1]):{})}}),m(K)){var he=function(e){return h(this,R),new K(e,arguments.length>1?pe(arguments[1]):{})};R.constructor=he,he.prototype=R,r({global:!0,forced:!0},{Request:he})}}t.exports={URLSearchParams:ce,getState:T}},{"../internals/an-instance":6,"../internals/an-object":7,"../internals/array-sort":11,"../internals/classof":14,"../internals/create-iterator-constructor":17,"../internals/create-property-descriptor":19,"../internals/export":29,"../internals/function-bind-context":33,"../internals/function-call":35,"../internals/function-uncurry-this":37,"../internals/get-built-in":38,"../internals/get-iterator":40,"../internals/get-iterator-method":39,"../internals/global":43,"../internals/has-own-property":44,"../internals/internal-state":50,"../internals/is-callable":52,"../internals/is-object":55,"../internals/native-url":63,"../internals/object-create":66,"../internals/redefine":81,"../internals/redefine-all":80,"../internals/set-to-string-tag":90,"../internals/to-string":104,"../internals/validate-arguments-length":109,"../internals/well-known-symbol":110,"../modules/es.array.iterator":111}],117:[function(e,t,n){"use strict";e("../modules/es.string.iterator");var r,o=e("../internals/export"),i=e("../internals/descriptors"),s=e("../internals/native-url"),a=e("../internals/global"),l=e("../internals/function-bind-context"),c=e("../internals/function-uncurry-this"),u=e("../internals/object-define-properties").f,d=e("../internals/redefine"),f=e("../internals/an-instance"),p=e("../internals/has-own-property"),h=e("../internals/object-assign"),m=e("../internals/array-from"),y=e("../internals/array-slice-simple"),g=e("../internals/string-multibyte").codeAt,v=e("../internals/string-punycode-to-ascii"),b=e("../internals/to-string"),_=e("../internals/set-to-string-tag"),w=e("../internals/validate-arguments-length"),x=e("../modules/web.url-search-params"),k=e("../internals/internal-state"),j=k.set,C=k.getterFor("URL"),E=x.URLSearchParams,D=x.getState,S=a.URL,O=a.TypeError,P=a.parseInt,B=Math.floor,M=Math.pow,T=c("".charAt),A=c(/./.exec),I=c([].join),K=c(1..toString),L=c([].pop),R=c([].push),N=c("".replace),F=c([].shift),U=c("".split),z=c("".slice),H=c("".toLowerCase),W=c([].unshift),q="Invalid scheme",V="Invalid host",G="Invalid port",Y=/[a-z]/i,X=/[\d+-.a-z]/i,$=/\d/,J=/^0x/i,Q=/^[0-7]+$/,Z=/^\d+$/,ee=/^[\da-f]+$/i,te=/[\0\t\n\r #%/:<>?@[\\\]^|]/,ne=/[\0\t\n\r #/:<>?@[\\\]^|]/,re=/^[\u0000-\u0020]+|[\u0000-\u0020]+$/g,oe=/[\t\n\r]/g,ie=function(e){var t,n,r,o;if("number"==typeof e){for(t=[],n=0;n<4;n++)W(t,e%256),e=B(e/256);return I(t,".")}if("object"==typeof e){for(t="",r=function(e){for(var t=null,n=1,r=null,o=0,i=0;i<8;i++)0!==e[i]?(o>n&&(t=r,n=o),r=null,o=0):(null===r&&(r=i),++o);return o>n&&(t=r,n=o),t}(e),n=0;n<8;n++)o&&0===e[n]||(o&&(o=!1),r===n?(t+=n?":":"::",o=!0):(t+=K(e[n],16),n<7&&(t+=":")));return"["+t+"]"}return e},se={},ae=h({},se,{" ":1,'"':1,"<":1,">":1,"`":1}),le=h({},ae,{"#":1,"?":1,"{":1,"}":1}),ce=h({},le,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),ue=function(e,t){var n=g(e,0);return n>32&&n<127&&!p(t,e)?e:encodeURIComponent(e)},de={ftp:21,file:null,http:80,https:443,ws:80,wss:443},fe=function(e,t){var n;return 2==e.length&&A(Y,T(e,0))&&(":"==(n=T(e,1))||!t&&"|"==n)},pe=function(e){var t;return e.length>1&&fe(z(e,0,2))&&(2==e.length||"/"===(t=T(e,2))||"\\"===t||"?"===t||"#"===t)},he=function(e){return"."===e||"%2e"===H(e)},me={},ye={},ge={},ve={},be={},_e={},we={},xe={},ke={},je={},Ce={},Ee={},De={},Se={},Oe={},Pe={},Be={},Me={},Te={},Ae={},Ie={},Ke=function(e,t,n){var r,o,i,s=b(e);if(t){if(o=this.parse(s))throw O(o);this.searchParams=null}else{if(void 0!==n&&(r=new Ke(n,!0)),o=this.parse(s,null,r))throw O(o);(i=D(new E)).bindURL(this),this.searchParams=i}};Ke.prototype={type:"URL",parse:function(e,t,n){var o,i,s,a,l,c=this,u=t||me,d=0,f="",h=!1,g=!1,v=!1;for(e=b(e),t||(c.scheme="",c.username="",c.password="",c.host=null,c.port=null,c.path=[],c.query=null,c.fragment=null,c.cannotBeABaseURL=!1,e=N(e,re,"")),e=N(e,oe,""),o=m(e);d<=o.length;){switch(i=o[d],u){case me:if(!i||!A(Y,i)){if(t)return q;u=ge;continue}f+=H(i),u=ye;break;case ye:if(i&&(A(X,i)||"+"==i||"-"==i||"."==i))f+=H(i);else{if(":"!=i){if(t)return q;f="",u=ge,d=0;continue}if(t&&(c.isSpecial()!=p(de,f)||"file"==f&&(c.includesCredentials()||null!==c.port)||"file"==c.scheme&&!c.host))return;if(c.scheme=f,t)return void(c.isSpecial()&&de[c.scheme]==c.port&&(c.port=null));f="","file"==c.scheme?u=Se:c.isSpecial()&&n&&n.scheme==c.scheme?u=ve:c.isSpecial()?u=xe:"/"==o[d+1]?(u=be,d++):(c.cannotBeABaseURL=!0,R(c.path,""),u=Te)}break;case ge:if(!n||n.cannotBeABaseURL&&"#"!=i)return q;if(n.cannotBeABaseURL&&"#"==i){c.scheme=n.scheme,c.path=y(n.path),c.query=n.query,c.fragment="",c.cannotBeABaseURL=!0,u=Ie;break}u="file"==n.scheme?Se:_e;continue;case ve:if("/"!=i||"/"!=o[d+1]){u=_e;continue}u=ke,d++;break;case be:if("/"==i){u=je;break}u=Me;continue;case _e:if(c.scheme=n.scheme,i==r)c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=y(n.path),c.query=n.query;else if("/"==i||"\\"==i&&c.isSpecial())u=we;else if("?"==i)c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=y(n.path),c.query="",u=Ae;else{if("#"!=i){c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=y(n.path),c.path.length--,u=Me;continue}c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,c.path=y(n.path),c.query=n.query,c.fragment="",u=Ie}break;case we:if(!c.isSpecial()||"/"!=i&&"\\"!=i){if("/"!=i){c.username=n.username,c.password=n.password,c.host=n.host,c.port=n.port,u=Me;continue}u=je}else u=ke;break;case xe:if(u=ke,"/"!=i||"/"!=T(f,d+1))continue;d++;break;case ke:if("/"!=i&&"\\"!=i){u=je;continue}break;case je:if("@"==i){h&&(f="%40"+f),h=!0,s=m(f);for(var _=0;_<s.length;_++){var w=s[_];if(":"!=w||v){var x=ue(w,ce);v?c.password+=x:c.username+=x}else v=!0}f=""}else if(i==r||"/"==i||"?"==i||"#"==i||"\\"==i&&c.isSpecial()){if(h&&""==f)return"Invalid authority";d-=m(f).length+1,f="",u=Ce}else f+=i;break;case Ce:case Ee:if(t&&"file"==c.scheme){u=Pe;continue}if(":"!=i||g){if(i==r||"/"==i||"?"==i||"#"==i||"\\"==i&&c.isSpecial()){if(c.isSpecial()&&""==f)return V;if(t&&""==f&&(c.includesCredentials()||null!==c.port))return;if(a=c.parseHost(f))return a;if(f="",u=Be,t)return;continue}"["==i?g=!0:"]"==i&&(g=!1),f+=i}else{if(""==f)return V;if(a=c.parseHost(f))return a;if(f="",u=De,t==Ee)return}break;case De:if(!A($,i)){if(i==r||"/"==i||"?"==i||"#"==i||"\\"==i&&c.isSpecial()||t){if(""!=f){var k=P(f,10);if(k>65535)return G;c.port=c.isSpecial()&&k===de[c.scheme]?null:k,f=""}if(t)return;u=Be;continue}return G}f+=i;break;case Se:if(c.scheme="file","/"==i||"\\"==i)u=Oe;else{if(!n||"file"!=n.scheme){u=Me;continue}if(i==r)c.host=n.host,c.path=y(n.path),c.query=n.query;else if("?"==i)c.host=n.host,c.path=y(n.path),c.query="",u=Ae;else{if("#"!=i){pe(I(y(o,d),""))||(c.host=n.host,c.path=y(n.path),c.shortenPath()),u=Me;continue}c.host=n.host,c.path=y(n.path),c.query=n.query,c.fragment="",u=Ie}}break;case Oe:if("/"==i||"\\"==i){u=Pe;break}n&&"file"==n.scheme&&!pe(I(y(o,d),""))&&(fe(n.path[0],!0)?R(c.path,n.path[0]):c.host=n.host),u=Me;continue;case Pe:if(i==r||"/"==i||"\\"==i||"?"==i||"#"==i){if(!t&&fe(f))u=Me;else if(""==f){if(c.host="",t)return;u=Be}else{if(a=c.parseHost(f))return a;if("localhost"==c.host&&(c.host=""),t)return;f="",u=Be}continue}f+=i;break;case Be:if(c.isSpecial()){if(u=Me,"/"!=i&&"\\"!=i)continue}else if(t||"?"!=i)if(t||"#"!=i){if(i!=r&&(u=Me,"/"!=i))continue}else c.fragment="",u=Ie;else c.query="",u=Ae;break;case Me:if(i==r||"/"==i||"\\"==i&&c.isSpecial()||!t&&("?"==i||"#"==i)){if(".."===(l=H(l=f))||"%2e."===l||".%2e"===l||"%2e%2e"===l?(c.shortenPath(),"/"==i||"\\"==i&&c.isSpecial()||R(c.path,"")):he(f)?"/"==i||"\\"==i&&c.isSpecial()||R(c.path,""):("file"==c.scheme&&!c.path.length&&fe(f)&&(c.host&&(c.host=""),f=T(f,0)+":"),R(c.path,f)),f="","file"==c.scheme&&(i==r||"?"==i||"#"==i))for(;c.path.length>1&&""===c.path[0];)F(c.path);"?"==i?(c.query="",u=Ae):"#"==i&&(c.fragment="",u=Ie)}else f+=ue(i,le);break;case Te:"?"==i?(c.query="",u=Ae):"#"==i?(c.fragment="",u=Ie):i!=r&&(c.path[0]+=ue(i,se));break;case Ae:t||"#"!=i?i!=r&&("'"==i&&c.isSpecial()?c.query+="%27":c.query+="#"==i?"%23":ue(i,se)):(c.fragment="",u=Ie);break;case Ie:i!=r&&(c.fragment+=ue(i,ae))}d++}},parseHost:function(e){var t,n,r;if("["==T(e,0)){if("]"!=T(e,e.length-1))return V;if(t=function(e){var t,n,r,o,i,s,a,l=[0,0,0,0,0,0,0,0],c=0,u=null,d=0,f=function(){return T(e,d)};if(":"==f()){if(":"!=T(e,1))return;d+=2,u=++c}for(;f();){if(8==c)return;if(":"!=f()){for(t=n=0;n<4&&A(ee,f());)t=16*t+P(f(),16),d++,n++;if("."==f()){if(0==n)return;if(d-=n,c>6)return;for(r=0;f();){if(o=null,r>0){if(!("."==f()&&r<4))return;d++}if(!A($,f()))return;for(;A($,f());){if(i=P(f(),10),null===o)o=i;else{if(0==o)return;o=10*o+i}if(o>255)return;d++}l[c]=256*l[c]+o,2!=++r&&4!=r||c++}if(4!=r)return;break}if(":"==f()){if(d++,!f())return}else if(f())return;l[c++]=t}else{if(null!==u)return;d++,u=++c}}if(null!==u)for(s=c-u,c=7;0!=c&&s>0;)a=l[c],l[c--]=l[u+s-1],l[u+--s]=a;else if(8!=c)return;return l}(z(e,1,-1)),!t)return V;this.host=t}else if(this.isSpecial()){if(e=v(e),A(te,e))return V;if(t=function(e){var t,n,r,o,i,s,a,l=U(e,".");if(l.length&&""==l[l.length-1]&&l.length--,(t=l.length)>4)return e;for(n=[],r=0;r<t;r++){if(""==(o=l[r]))return e;if(i=10,o.length>1&&"0"==T(o,0)&&(i=A(J,o)?16:8,o=z(o,8==i?1:2)),""===o)s=0;else{if(!A(10==i?Z:8==i?Q:ee,o))return e;s=P(o,i)}R(n,s)}for(r=0;r<t;r++)if(s=n[r],r==t-1){if(s>=M(256,5-t))return null}else if(s>255)return null;for(a=L(n),r=0;r<n.length;r++)a+=n[r]*M(256,3-r);return a}(e),null===t)return V;this.host=t}else{if(A(ne,e))return V;for(t="",n=m(e),r=0;r<n.length;r++)t+=ue(n[r],se);this.host=t}},cannotHaveUsernamePasswordPort:function(){return!this.host||this.cannotBeABaseURL||"file"==this.scheme},includesCredentials:function(){return""!=this.username||""!=this.password},isSpecial:function(){return p(de,this.scheme)},shortenPath:function(){var e=this.path,t=e.length;!t||"file"==this.scheme&&1==t&&fe(e[0],!0)||e.length--},serialize:function(){var e=this,t=e.scheme,n=e.username,r=e.password,o=e.host,i=e.port,s=e.path,a=e.query,l=e.fragment,c=t+":";return null!==o?(c+="//",e.includesCredentials()&&(c+=n+(r?":"+r:"")+"@"),c+=ie(o),null!==i&&(c+=":"+i)):"file"==t&&(c+="//"),c+=e.cannotBeABaseURL?s[0]:s.length?"/"+I(s,"/"):"",null!==a&&(c+="?"+a),null!==l&&(c+="#"+l),c},setHref:function(e){var t=this.parse(e);if(t)throw O(t);this.searchParams.update()},getOrigin:function(){var e=this.scheme,t=this.port;if("blob"==e)try{return new Le(e.path[0]).origin}catch(e){return"null"}return"file"!=e&&this.isSpecial()?e+"://"+ie(this.host)+(null!==t?":"+t:""):"null"},getProtocol:function(){return this.scheme+":"},setProtocol:function(e){this.parse(b(e)+":",me)},getUsername:function(){return this.username},setUsername:function(e){var t=m(b(e));if(!this.cannotHaveUsernamePasswordPort()){this.username="";for(var n=0;n<t.length;n++)this.username+=ue(t[n],ce)}},getPassword:function(){return this.password},setPassword:function(e){var t=m(b(e));if(!this.cannotHaveUsernamePasswordPort()){this.password="";for(var n=0;n<t.length;n++)this.password+=ue(t[n],ce)}},getHost:function(){var e=this.host,t=this.port;return null===e?"":null===t?ie(e):ie(e)+":"+t},setHost:function(e){this.cannotBeABaseURL||this.parse(e,Ce)},getHostname:function(){var e=this.host;return null===e?"":ie(e)},setHostname:function(e){this.cannotBeABaseURL||this.parse(e,Ee)},getPort:function(){var e=this.port;return null===e?"":b(e)},setPort:function(e){this.cannotHaveUsernamePasswordPort()||(""==(e=b(e))?this.port=null:this.parse(e,De))},getPathname:function(){var e=this.path;return this.cannotBeABaseURL?e[0]:e.length?"/"+I(e,"/"):""},setPathname:function(e){this.cannotBeABaseURL||(this.path=[],this.parse(e,Be))},getSearch:function(){var e=this.query;return e?"?"+e:""},setSearch:function(e){""==(e=b(e))?this.query=null:("?"==T(e,0)&&(e=z(e,1)),this.query="",this.parse(e,Ae)),this.searchParams.update()},getSearchParams:function(){return this.searchParams.facade},getHash:function(){var e=this.fragment;return e?"#"+e:""},setHash:function(e){""!=(e=b(e))?("#"==T(e,0)&&(e=z(e,1)),this.fragment="",this.parse(e,Ie)):this.fragment=null},update:function(){this.query=this.searchParams.serialize()||null}};var Le=function(e){var t=f(this,Re),n=w(arguments.length,1)>1?arguments[1]:void 0,r=j(t,new Ke(e,!1,n));i||(t.href=r.serialize(),t.origin=r.getOrigin(),t.protocol=r.getProtocol(),t.username=r.getUsername(),t.password=r.getPassword(),t.host=r.getHost(),t.hostname=r.getHostname(),t.port=r.getPort(),t.pathname=r.getPathname(),t.search=r.getSearch(),t.searchParams=r.getSearchParams(),t.hash=r.getHash())},Re=Le.prototype,Ne=function(e,t){return{get:function(){return C(this)[e]()},set:t&&function(e){return C(this)[t](e)},configurable:!0,enumerable:!0}};if(i&&u(Re,{href:Ne("serialize","setHref"),origin:Ne("getOrigin"),protocol:Ne("getProtocol","setProtocol"),username:Ne("getUsername","setUsername"),password:Ne("getPassword","setPassword"),host:Ne("getHost","setHost"),hostname:Ne("getHostname","setHostname"),port:Ne("getPort","setPort"),pathname:Ne("getPathname","setPathname"),search:Ne("getSearch","setSearch"),searchParams:Ne("getSearchParams"),hash:Ne("getHash","setHash")}),d(Re,"toJSON",(function(){return C(this).serialize()}),{enumerable:!0}),d(Re,"toString",(function(){return C(this).serialize()}),{enumerable:!0}),S){var Fe=S.createObjectURL,Ue=S.revokeObjectURL;Fe&&d(Le,"createObjectURL",l(Fe,S)),Ue&&d(Le,"revokeObjectURL",l(Ue,S))}_(Le,"URL"),o({global:!0,forced:!s,sham:!i},{URL:Le})},{"../internals/an-instance":6,"../internals/array-from":8,"../internals/array-slice-simple":10,"../internals/descriptors":22,"../internals/export":29,"../internals/function-bind-context":33,"../internals/function-uncurry-this":37,"../internals/global":43,"../internals/has-own-property":44,"../internals/internal-state":50,"../internals/native-url":63,"../internals/object-assign":65,"../internals/object-define-properties":67,"../internals/redefine":81,"../internals/set-to-string-tag":90,"../internals/string-multibyte":94,"../internals/string-punycode-to-ascii":95,"../internals/to-string":104,"../internals/validate-arguments-length":109,"../modules/es.string.iterator":113,"../modules/web.url-search-params":116}],118:[function(e,t,n){var r,o,i;r=function(e,t,n,o){var i;t[0]=0;for(var s=1;s<t.length;s++){var a=t[s++],l=t[s]?(t[0]|=a?1:2,n[t[s++]]):t[++s];3===a?o[0]=l:4===a?o[1]=Object.assign(o[1]||{},l):5===a?(o[1]=o[1]||{})[t[++s]]=l:6===a?o[1][t[++s]]+=l+"":a?(i=e.apply(l,r(e,l,n,["",null])),o.push(i),l[0]?t[0]|=2:(t[s-2]=0,t[s]=i)):o.push(l)}return o},o=new Map,i=function(e){var t=o.get(this);return t||(t=new Map,o.set(this,t)),(t=r(this,t.get(e)||(t.set(e,t=function(e){for(var t,n,r=1,o="",i="",s=[0],a=function(e){1===r&&(e||(o=o.replace(/^\s*\n\s*|\s*\n\s*$/g,"")))?s.push(0,e,o):3===r&&(e||o)?(s.push(3,e,o),r=2):2===r&&"..."===o&&e?s.push(4,e,0):2===r&&o&&!e?s.push(5,0,!0,o):r>=5&&((o||!e&&5===r)&&(s.push(r,0,o,n),r=6),e&&(s.push(r,e,0,n),r=6)),o=""},l=0;l<e.length;l++){l&&(1===r&&a(),a(l));for(var c=0;c<e[l].length;c++)t=e[l][c],1===r?"<"===t?(a(),s=[s],r=3):o+=t:4===r?"--"===o&&">"===t?(r=1,o=""):o=t+o[0]:i?t===i?i="":o+=t:'"'===t||"'"===t?i=t:">"===t?(a(),r=1):r&&("="===t?(r=5,n=o,o=""):"/"===t&&(r<5||">"===e[l][c+1])?(a(),3===r&&(s=s[0]),r=s,(s=s[0]).push(2,0,r),r=0):" "===t||"\t"===t||"\n"===t||"\r"===t?(a(),r=2):o+=t),3===r&&"!--"===o&&(r=4,s=s[0])}return a(),s}(e)),t),arguments,[])).length>1?t:t[0]},void 0!==t?t.exports=i:self.htm=i},{}],119:[function(e,t,n){t.exports={nanoid:(e=21)=>{let t="",n=e;for(;n--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[64*Math.random()|0];return t},customAlphabet:(e,t=21)=>(n=t)=>{let r="",o=n;for(;o--;)r+=e[Math.random()*e.length|0];return r}}},{}],120:[function(e,t,n){var r,o,i,s,a,l,c,u,d={},f=[],p=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i;function h(e,t){for(var n in t)e[n]=t[n];return e}function m(e){var t=e.parentNode;t&&t.removeChild(e)}function y(e,t,n){var o,i,s,a={};for(s in t)"key"==s?o=t[s]:"ref"==s?i=t[s]:a[s]=t[s];if(arguments.length>2&&(a.children=arguments.length>3?r.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(s in e.defaultProps)void 0===a[s]&&(a[s]=e.defaultProps[s]);return g(e,a,o,i,null)}function g(e,t,n,r,s){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:null==s?++i:s};return null==s&&null!=o.vnode&&o.vnode(a),a}function v(e){return e.children}function b(e,t){this.props=e,this.context=t}function _(e,t){if(null==t)return e.__?_(e.__,e.__.__k.indexOf(e)+1):null;for(var n;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e)return n.__e;return"function"==typeof e.type?_(e):null}function w(e){var t,n;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e){e.__e=e.__c.base=n.__e;break}return w(e)}}function x(e){(!e.__d&&(e.__d=!0)&&a.push(e)&&!k.__r++||c!==o.debounceRendering)&&((c=o.debounceRendering)||l)(k)}function k(){for(var e;k.__r=a.length;)e=a.sort((function(e,t){return e.__v.__b-t.__v.__b})),a=[],e.some((function(e){var t,n,r,o,i,s;e.__d&&(i=(o=(t=e).__v).__e,(s=t.__P)&&(n=[],(r=h({},o)).__v=o.__v+1,B(s,o,r,t.__n,void 0!==s.ownerSVGElement,null!=o.__h?[i]:null,n,null==i?_(o):i,o.__h),M(n,o),o.__e!=i&&w(o)))}))}function j(e,t,n,r,o,i,s,a,l,c){var u,p,h,m,y,b,w,x=r&&r.__k||f,k=x.length;for(n.__k=[],u=0;u<t.length;u++)if(null!=(m=n.__k[u]=null==(m=t[u])||"boolean"==typeof m?null:"string"==typeof m||"number"==typeof m||"bigint"==typeof m?g(null,m,null,null,m):Array.isArray(m)?g(v,{children:m},null,null,null):m.__b>0?g(m.type,m.props,m.key,null,m.__v):m)){if(m.__=n,m.__b=n.__b+1,null===(h=x[u])||h&&m.key==h.key&&m.type===h.type)x[u]=void 0;else for(p=0;p<k;p++){if((h=x[p])&&m.key==h.key&&m.type===h.type){x[p]=void 0;break}h=null}B(e,m,h=h||d,o,i,s,a,l,c),y=m.__e,(p=m.ref)&&h.ref!=p&&(w||(w=[]),h.ref&&w.push(h.ref,null,m),w.push(p,m.__c||y,m)),null!=y?(null==b&&(b=y),"function"==typeof m.type&&m.__k===h.__k?m.__d=l=C(m,l,e):l=E(e,m,h,x,y,l),"function"==typeof n.type&&(n.__d=l)):l&&h.__e==l&&l.parentNode!=e&&(l=_(h))}for(n.__e=b,u=k;u--;)null!=x[u]&&("function"==typeof n.type&&null!=x[u].__e&&x[u].__e==n.__d&&(n.__d=_(r,u+1)),I(x[u],x[u]));if(w)for(u=0;u<w.length;u++)A(w[u],w[++u],w[++u])}function C(e,t,n){for(var r,o=e.__k,i=0;o&&i<o.length;i++)(r=o[i])&&(r.__=e,t="function"==typeof r.type?C(r,t,n):E(n,r,r,o,r.__e,t));return t}function E(e,t,n,r,o,i){var s,a,l;if(void 0!==t.__d)s=t.__d,t.__d=void 0;else if(null==n||o!=i||null==o.parentNode)e:if(null==i||i.parentNode!==e)e.appendChild(o),s=null;else{for(a=i,l=0;(a=a.nextSibling)&&l<r.length;l+=2)if(a==o)break e;e.insertBefore(o,i),s=i}return void 0!==s?s:o.nextSibling}function D(e,t,n){"-"===t[0]?e.setProperty(t,n):e[t]=null==n?"":"number"!=typeof n||p.test(t)?n:n+"px"}function S(e,t,n,r,o){var i;e:if("style"===t)if("string"==typeof n)e.style.cssText=n;else{if("string"==typeof r&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||D(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||D(e.style,t,n[t])}else if("o"===t[0]&&"n"===t[1])i=t!==(t=t.replace(/Capture$/,"")),t=t.toLowerCase()in e?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=n,n?r||e.addEventListener(t,i?P:O,i):e.removeEventListener(t,i?P:O,i);else if("dangerouslySetInnerHTML"!==t){if(o)t=t.replace(/xlink[H:h]/,"h").replace(/sName$/,"s");else if("href"!==t&&"list"!==t&&"form"!==t&&"tabIndex"!==t&&"download"!==t&&t in e)try{e[t]=null==n?"":n;break e}catch(e){}"function"==typeof n||(null!=n&&(!1!==n||"a"===t[0]&&"r"===t[1])?e.setAttribute(t,n):e.removeAttribute(t))}}function O(e){this.l[e.type+!1](o.event?o.event(e):e)}function P(e){this.l[e.type+!0](o.event?o.event(e):e)}function B(e,t,n,r,i,s,a,l,c){var u,d,f,p,m,y,g,_,w,x,k,C=t.type;if(void 0!==t.constructor)return null;null!=n.__h&&(c=n.__h,l=t.__e=n.__e,t.__h=null,s=[l]),(u=o.__b)&&u(t);try{e:if("function"==typeof C){if(_=t.props,w=(u=C.contextType)&&r[u.__c],x=u?w?w.props.value:u.__:r,n.__c?g=(d=t.__c=n.__c).__=d.__E:("prototype"in C&&C.prototype.render?t.__c=d=new C(_,x):(t.__c=d=new b(_,x),d.constructor=C,d.render=K),w&&w.sub(d),d.props=_,d.state||(d.state={}),d.context=x,d.__n=r,f=d.__d=!0,d.__h=[]),null==d.__s&&(d.__s=d.state),null!=C.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=h({},d.__s)),h(d.__s,C.getDerivedStateFromProps(_,d.__s))),p=d.props,m=d.state,f)null==C.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(null==C.getDerivedStateFromProps&&_!==p&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(_,x),!d.__e&&null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(_,d.__s,x)||t.__v===n.__v){d.props=_,d.state=d.__s,t.__v!==n.__v&&(d.__d=!1),d.__v=t,t.__e=n.__e,t.__k=n.__k,t.__k.forEach((function(e){e&&(e.__=t)})),d.__h.length&&a.push(d);break e}null!=d.componentWillUpdate&&d.componentWillUpdate(_,d.__s,x),null!=d.componentDidUpdate&&d.__h.push((function(){d.componentDidUpdate(p,m,y)}))}d.context=x,d.props=_,d.state=d.__s,(u=o.__r)&&u(t),d.__d=!1,d.__v=t,d.__P=e,u=d.render(d.props,d.state,d.context),d.state=d.__s,null!=d.getChildContext&&(r=h(h({},r),d.getChildContext())),f||null==d.getSnapshotBeforeUpdate||(y=d.getSnapshotBeforeUpdate(p,m)),k=null!=u&&u.type===v&&null==u.key?u.props.children:u,j(e,Array.isArray(k)?k:[k],t,n,r,i,s,a,l,c),d.base=t.__e,t.__h=null,d.__h.length&&a.push(d),g&&(d.__E=d.__=null),d.__e=!1}else null==s&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=T(n.__e,t,n,r,i,s,a,c);(u=o.diffed)&&u(t)}catch(e){t.__v=null,(c||null!=s)&&(t.__e=l,t.__h=!!c,s[s.indexOf(l)]=null),o.__e(e,t,n)}}function M(e,t){o.__c&&o.__c(t,e),e.some((function(t){try{e=t.__h,t.__h=[],e.some((function(e){e.call(t)}))}catch(e){o.__e(e,t.__v)}}))}function T(e,t,n,o,i,s,a,l){var c,u,f,p=n.props,h=t.props,y=t.type,g=0;if("svg"===y&&(i=!0),null!=s)for(;g<s.length;g++)if((c=s[g])&&"setAttribute"in c==!!y&&(y?c.localName===y:3===c.nodeType)){e=c,s[g]=null;break}if(null==e){if(null===y)return document.createTextNode(h);e=i?document.createElementNS("http://www.w3.org/2000/svg",y):document.createElement(y,h.is&&h),s=null,l=!1}if(null===y)p===h||l&&e.data===h||(e.data=h);else{if(s=s&&r.call(e.childNodes),u=(p=n.props||d).dangerouslySetInnerHTML,f=h.dangerouslySetInnerHTML,!l){if(null!=s)for(p={},g=0;g<e.attributes.length;g++)p[e.attributes[g].name]=e.attributes[g].value;(f||u)&&(f&&(u&&f.__html==u.__html||f.__html===e.innerHTML)||(e.innerHTML=f&&f.__html||""))}if(function(e,t,n,r,o){var i;for(i in n)"children"===i||"key"===i||i in t||S(e,i,null,n[i],r);for(i in t)o&&"function"!=typeof t[i]||"children"===i||"key"===i||"value"===i||"checked"===i||n[i]===t[i]||S(e,i,t[i],n[i],r)}(e,h,p,i,l),f)t.__k=[];else if(g=t.props.children,j(e,Array.isArray(g)?g:[g],t,n,o,i&&"foreignObject"!==y,s,a,s?s[0]:n.__k&&_(n,0),l),null!=s)for(g=s.length;g--;)null!=s[g]&&m(s[g]);l||("value"in h&&void 0!==(g=h.value)&&(g!==e.value||"progress"===y&&!g||"option"===y&&g!==p.value)&&S(e,"value",g,p.value,!1),"checked"in h&&void 0!==(g=h.checked)&&g!==e.checked&&S(e,"checked",g,p.checked,!1))}return e}function A(e,t,n){try{"function"==typeof e?e(t):e.current=t}catch(e){o.__e(e,n)}}function I(e,t,n){var r,i;if(o.unmount&&o.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||A(r,null,t)),null!=(r=e.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){o.__e(e,t)}r.base=r.__P=null}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&I(r[i],t,"function"!=typeof e.type);n||null==e.__e||m(e.__e),e.__e=e.__d=void 0}function K(e,t,n){return this.constructor(e,n)}function L(e,t,n){var i,s,a;o.__&&o.__(e,t),s=(i="function"==typeof n)?null:n&&n.__k||t.__k,a=[],B(t,e=(!i&&n||t).__k=y(v,null,[e]),s||d,d,void 0!==t.ownerSVGElement,!i&&n?[n]:s?null:t.firstChild?r.call(t.childNodes):null,a,!i&&n?n:s?s.__e:t.firstChild,i),M(a,e)}r=f.slice,o={__e:function(e,t){for(var n,r,o;t=t.__;)if((n=t.__c)&&!n.__)try{if((r=n.constructor)&&null!=r.getDerivedStateFromError&&(n.setState(r.getDerivedStateFromError(e)),o=n.__d),null!=n.componentDidCatch&&(n.componentDidCatch(e),o=n.__d),o)return n.__E=n}catch(t){e=t}throw e}},i=0,s=function(e){return null!=e&&void 0===e.constructor},b.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=h({},this.state),"function"==typeof e&&(e=e(h({},n),this.props)),e&&h(n,e),null!=e&&this.__v&&(t&&this.__h.push(t),x(this))},b.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),x(this))},b.prototype.render=v,a=[],l="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,k.__r=0,u=0,n.render=L,n.hydrate=function e(t,n){L(t,n,e)},n.createElement=y,n.h=y,n.Fragment=v,n.createRef=function(){return{current:null}},n.isValidElement=s,n.Component=b,n.cloneElement=function(e,t,n){var o,i,s,a=h({},e.props);for(s in t)"key"==s?o=t[s]:"ref"==s?i=t[s]:a[s]=t[s];return arguments.length>2&&(a.children=arguments.length>3?r.call(arguments,2):n),g(e.type,a,o||e.key,i||e.ref,null)},n.createContext=function(e,t){var n={__c:t="__cC"+u++,__:e,Consumer:function(e,t){return e.children(t)},Provider:function(e){var n,r;return this.getChildContext||(n=[],(r={})[t]=this,this.getChildContext=function(){return r},this.shouldComponentUpdate=function(e){this.props.value!==e.value&&n.some(x)},this.sub=function(e){n.push(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n.splice(n.indexOf(e),1),t&&t.call(e)}}),e.children}};return n.Provider.__=n.Consumer.contextType=n},n.toChildArray=function e(t,n){return n=n||[],null==t||"boolean"==typeof t||(Array.isArray(t)?t.some((function(t){e(t,n)})):n.push(t)),n},n.options=o},{}],121:[function(e,t,n){var r,o,i,s=e("preact"),a=0,l=[],c=s.options.__b,u=s.options.__r,d=s.options.diffed,f=s.options.__c,p=s.options.unmount;function h(e,t){s.options.__h&&s.options.__h(o,e,a||t),a=0;var n=o.__H||(o.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function m(e){return a=1,y(j,e)}function y(e,t,n){var i=h(r++,2);return i.t=e,i.__c||(i.__=[n?n(t):j(void 0,t),function(e){var t=i.t(i.__[0],e);i.__[0]!==t&&(i.__=[t,i.__[1]],i.__c.setState({}))}],i.__c=o),i.__}function g(e,t){var n=h(r++,4);!s.options.__s&&k(n.__H,t)&&(n.__=e,n.__H=t,o.__h.push(n))}function v(e,t){var n=h(r++,7);return k(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function b(){for(var e;e=l.shift();)if(e.__P)try{e.__H.__h.forEach(w),e.__H.__h.forEach(x),e.__H.__h=[]}catch(t){e.__H.__h=[],s.options.__e(t,e.__v)}}s.options.__b=function(e){o=null,c&&c(e)},s.options.__r=function(e){u&&u(e),r=0;var t=(o=e.__c).__H;t&&(t.__h.forEach(w),t.__h.forEach(x),t.__h=[])},s.options.diffed=function(e){d&&d(e);var t=e.__c;t&&t.__H&&t.__H.__h.length&&(1!==l.push(t)&&i===s.options.requestAnimationFrame||((i=s.options.requestAnimationFrame)||function(e){var t,n=function(){clearTimeout(r),_&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);_&&(t=requestAnimationFrame(n))})(b)),o=null},s.options.__c=function(e,t){t.some((function(e){try{e.__h.forEach(w),e.__h=e.__h.filter((function(e){return!e.__||x(e)}))}catch(n){t.some((function(e){e.__h&&(e.__h=[])})),t=[],s.options.__e(n,e.__v)}})),f&&f(e,t)},s.options.unmount=function(e){p&&p(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach((function(e){try{w(e)}catch(e){t=e}})),t&&s.options.__e(t,n.__v))};var _="function"==typeof requestAnimationFrame;function w(e){var t=o,n=e.__c;"function"==typeof n&&(e.__c=void 0,n()),o=t}function x(e){var t=o;e.__c=e.__(),o=t}function k(e,t){return!e||e.length!==t.length||t.some((function(t,n){return t!==e[n]}))}function j(e,t){return"function"==typeof t?t(e):t}n.useState=m,n.useReducer=y,n.useEffect=function(e,t){var n=h(r++,3);!s.options.__s&&k(n.__H,t)&&(n.__=e,n.__H=t,o.__H.__h.push(n))},n.useLayoutEffect=g,n.useRef=function(e){return a=5,v((function(){return{current:e}}),[])},n.useImperativeHandle=function(e,t,n){a=6,g((function(){"function"==typeof e?e(t()):e&&(e.current=t())}),null==n?n:n.concat(e))},n.useMemo=v,n.useCallback=function(e,t){return a=8,v((function(){return e}),t)},n.useContext=function(e){var t=o.context[e.__c],n=h(r++,9);return n.c=e,t?(null==n.__&&(n.__=!0,t.sub(o)),t.props.value):e.__},n.useDebugValue=function(e,t){s.options.useDebugValue&&s.options.useDebugValue(t?t(e):e)},n.useErrorBoundary=function(e){var t=h(r++,10),n=m();return t.__=e,o.componentDidCatch||(o.componentDidCatch=function(e){t.__&&t.__(e),n[1](e)}),[n[0],function(){n[1](void 0)}]}},{preact:120}],122:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.getAutoRegion=void 0;const r=e("../v7/v7-config"),o=(e,t,n)=>new Promise((r=>{const o=setTimeout((()=>{console.error("Timeout while latency check for ",t),r()}),n);e().then((()=>{clearTimeout(o),r()})).catch((e=>{console.error("Error while latency check for ",t,e),clearTimeout(o),r()}))}));async function i(e){const t=e.ok;if(-1===t.indexOf(e.name))throw new Error("okUrl "+t+" does not contain region "+e);return(async()=>{const e=Date.now();return await fetch(t+"?time="+e,{method:"GET",mode:"cors",cache:"no-cache"}).then((e=>e.text())),Date.now()-e})()}n.getAutoRegion=async function(e){const t=[...r.awsRegions],n=(()=>{const e={};for(const{name:t}of r.awsRegions)e[t]=[];return e})(),l=[];for(const r of t){const t=async()=>{const t=r.name;for(let o=0;o<5;++o)n[t].push(await i(r)),e(t+"#"+(o+1)+" ("+n[t][0]+" ms)")};l.push(o(t,r.name,15e3))}await Promise.all(l);try{const e=/execute-api\.([^.]+)\.amazonaws.com\/dev\/ok/;if("undefined"!=typeof performance&&void 0!==performance.getEntriesByType){const t=performance.getEntriesByType("resource");for(const r of t)if(void 0!==r.name&&void 0!==r.duration){const t=e.exec(r.name);null!==t&&void 0!==t[1]&&n[t[1]].push(Math.round(r.duration))}}}catch(e){console.error("Can't use performance data",e)}let c="eu-central-1",u=-1,d="";const f={};for(const e of Object.keys(n)){const t=a(n[e]);t>0&&(-1===u||u>t)&&(c=e,u=t);const r=s(n[e]);f[e]=r,d+=(e+" ").substring(0,14)+": ["+r.join(", ")+"]\n"}return console.log("Latency estimation:\n"+d),console.log("Auto region:",c,", latency: "+u),{region:c,regionLatency:u,estimation:f}};const s=e=>e.sort(((e,t)=>e-t)),a=e=>0===e.length?0:s(e)[0]},{"../v7/v7-config":124,"core-js/modules/web.dom-collections.iterator.js":115}],123:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.putPersonalBundle=n.getPersonalBundleUrl=void 0;const r=e("../../../v7-services/src/personal"),o=e("../../xhr"),i=e("./v7-config");n.getPersonalBundleUrl=function(e,t,n){return(0,r.getPersonalBundleUrl)(e,t,n)},n.putPersonalBundle=async function(e,t,n,r){const s=await async function(e){const t=new zip.ZipReader(new zip.Uint8ArrayReader(e),{useWebWorkers:!1}),n=await t.getEntries();let r=!0;for(const e of n)if(r=!0===e.directory,!r)break;return t.close(),r}(r);if(s)return void console.warn("Ignore empty changes archive");const a=await(0,o.postObject)(i.personalPut+"?namespace="+e+"&id="+t+"&bundleUrl="+encodeURIComponent(n));if(!a.success)throw new Error("Unable to put personal bundle");const l=JSON.parse(a.payload),c=l.signature,u=l.url;if(c["x-amz-content-sha256"]="UNSIGNED-PAYLOAD",await(0,o.send)("put",u,"text",r.buffer,void 0,c),!(await(0,o.postObject)(i.personalAcl+"?namespace="+e+"&id="+t+"&bundleUrl="+n)).success)throw new Error("Can't set ACL to personal bundle")}},{"../../../v7-services/src/personal":146,"../../xhr":145,"./v7-config":124,"core-js/modules/web.dom-collections.iterator.js":115}],124:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.awsRegions=n.checkoutEndpoint=n.checkoutCreateTokenEndpoint=n.stopIpx=n.startIpx=n.addFreeTimeTierEndpoint=n.tokeInfoGetEndpoint=n.createTokenEndpoint=n.personalAcl=n.personalPut=n.endpointBase=void 0,n.endpointBase="https://kdhkdsv558.execute-api.eu-central-1.amazonaws.com/dev",n.personalPut=n.endpointBase+"/personal/put",n.personalAcl=n.endpointBase+"/personal/acl",n.createTokenEndpoint=n.endpointBase+"/token/create",n.tokeInfoGetEndpoint=n.endpointBase+"/token/info/get",n.addFreeTimeTierEndpoint=n.endpointBase+"/token/add/free",n.startIpx=n.endpointBase+"/token/ipx/start",n.stopIpx=n.endpointBase+"/token/ipx/stop",n.checkoutCreateTokenEndpoint=n.endpointBase+"/checkout/token/create",n.checkoutEndpoint="https://js-dos.com/checkout/index.html",n.awsRegions=[{label:"US East (N. Virginia)",name:"us-east-1",ok:"https://387k8l2vgf.execute-api.us-east-1.amazonaws.com/dev/ok"},{label:"US East (Ohio)",name:"us-east-2",ok:"https://q32vlaa5ji.execute-api.us-east-2.amazonaws.com/dev/ok"},{label:"US West (N. California)",name:"us-west-1",ok:"https://zittdd8vr2.execute-api.us-west-1.amazonaws.com/dev/ok"},{label:"US West (Oregon)",name:"us-west-2",ok:"https://aw3gj5315i.execute-api.us-west-2.amazonaws.com/dev/ok"},{label:"Europe (Frankfurt)",name:"eu-central-1",ok:"https://pdxnceto92.execute-api.eu-central-1.amazonaws.com/dev/ok"},{label:"Europe (Ireland)",name:"eu-west-1",ok:"https://yjm6n35ii4.execute-api.eu-west-1.amazonaws.com/dev/ok"},{label:"Europe (London)",name:"eu-west-2",ok:"https://u8k6qhll5d.execute-api.eu-west-2.amazonaws.com/dev/ok"},{label:"Europe (Milan)",name:"eu-south-1",ok:"https://hn4uxbiro0.execute-api.eu-south-1.amazonaws.com/dev/ok"},{label:"Europe (Paris)",name:"eu-west-3",ok:"https://oce5khcznd.execute-api.eu-west-3.amazonaws.com/dev/ok"},{label:"Europe (Stockholm)",name:"eu-north-1",ok:"https://f3j2j43580.execute-api.eu-north-1.amazonaws.com/dev/ok"},{label:"Asia Pacific (Hong Kong)",name:"ap-east-1",ok:"https://2dji6qhipb.execute-api.ap-east-1.amazonaws.com/dev/ok"},{label:"Asia Pacific (Mumbai)",name:"ap-south-1",ok:"https://0htlj8u1m9.execute-api.ap-south-1.amazonaws.com/dev/ok"},{label:"Asia Pacific (Osaka)",name:"ap-northeast-3",ok:"https://4z9rh02y37.execute-api.ap-northeast-3.amazonaws.com/dev/ok"},{label:"Asia Pacific (Seoul)",name:"ap-northeast-2",ok:"https://dv8crqb5j6.execute-api.ap-northeast-2.amazonaws.com/dev/ok"},{label:"Asia Pacific (Singapore)",name:"ap-southeast-1",ok:"https://e0w35dr520.execute-api.ap-southeast-1.amazonaws.com/dev/ok"},{label:"Asia Pacific (Sydney)",name:"ap-southeast-2",ok:"https://a2bnpow0ul.execute-api.ap-southeast-2.amazonaws.com/dev/ok"},{label:"Asia Pacific (Tokyo)",name:"ap-northeast-1",ok:"https://snvzlstk05.execute-api.ap-northeast-1.amazonaws.com/dev/ok"},{label:"Canada",name:"ca-central-1",ok:"https://wqwl5he8y7.execute-api.ca-central-1.amazonaws.com/dev/ok"},{label:"Middle East (Bahrain)",name:"me-south-1",ok:"https://g480v58gnk.execute-api.me-south-1.amazonaws.com/dev/ok"},{label:"South America (São Paulo)",name:"sa-east-1",ok:"https://wvhym3rtc1.execute-api.sa-east-1.amazonaws.com/dev/ok"},{label:"Africa (Cape Town)",name:"af-south-1",ok:"https://r0atydfi7k.execute-api.af-south-1.amazonaws.com/dev/ok"}]},{}],125:[function(e,t,n){"use strict";var r,o,i;function s(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.ActionBar=void 0;const a=e("../dom"),l=e("../icons"),c=e("./controls");function u(e){if(!0===e.options().noSocialLinks||!0!==e.options().noSideBar)return null;return(0,a.html)(o||(o=s(['\n <div class="h-5 w-5 my-4 text-pink-400 cursor-pointer" onClick=',">\n <",' class="h-5 w-5" />\n </div>\n '])),(function(){window.open("https://dos.zone/","_blank")}),l.Icons.Plus)}function d(e){if(!0===e.options().noSideBar)return null;let t="text-gray-600";return void 0!==e.requestClientId&&null===e.clientId?t="text-red-800 animate-pulse":e.sideBar&&(t="text-green-400"),(0,a.html)(i||(i=s(['\n <div class="h-6 w-6 my-4 ',' cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n '])),t,(function(){e.sideBar?e.closeSideBar():e.openSideBar()}),l.Icons.DotsHorizontal)}n.ActionBar=function(e){if(!e.actionBar)return null;const t=!0===e.options().noSideBar&&!0===e.options().noSocialLinks;return(0,a.html)(r||(r=s(['\n <div class="bg-gray-200 shadow w-10 h-full overflow-hidden flex flex-col items-center">\n <'," ..."," />\n <"," ..."," />\n <",' column="true" class="flex-grow \n ','" \n portal='," ..."," />\n </div>\n "])),d,e,u,e,c.Controls,t?"":" border-t-2 border-gray-400",!0,e)}},{"../dom":139,"../icons":141,"./controls":129}],126:[function(e,t,n){"use strict";var r;Object.defineProperty(n,"__esModule",{value:!0}),n.ActionHide=void 0;const o=e("../dom"),i=e("../icons");n.ActionHide=function(e){return(0,o.html)(r||(t=['\n <div class="filter transition-opacity duration-1000 absolute z-50 \n bg-gray-200 ',"\n w-5 h-12 top-1/2 -mt-6 ",'\n rounded-r-md cursor-pointer" onClick=','>\n <div class="h-4 w-4 my-4">\n <',' class="h-4 w-4" />\n </div>\n </div>\n '],n||(n=t.slice(0)),r=Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(n)}}))),e.actionBar?"":"opacity-80",e.actionBar?"left-10":"left-0",(()=>e.setActionBar(!e.actionBar)),e.actionBar?i.Icons.ChevronLeft:i.Icons.ChevronRight);var t,n}},{"../dom":139,"../icons":141}],127:[function(e,t,n){"use strict";var r;e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.ActionSaveOrExit=void 0;const o=e("preact/hooks"),i=e("../dom"),s=e("../icons");n.ActionSaveOrExit=function(e){const t=e.options().onExit,[n,a]=(0,o.useState)(!1),[l,c]=(0,o.useState)(!1),u="function"==typeof t;return(0,o.useEffect)((()=>{if(!l&&u)return window.addEventListener("beforeunload",t),()=>{window.removeEventListener("beforeunload",t)};function t(t){if(void 0===e.player().ciPromise)return;const n=u?"Please use close button to save progress before closing!":"Please use save button to save progress before closing!";setTimeout((()=>{e.player().layers.notyf.error(n),a(!0)}),16),t.preventDefault(),t.returnValue=n}}),[a,e.player,l,t,u]),l||e.sideBar?null:(0,i.html)(r||(d=['\n <div class="filter transition-opacity duration-1000 absolute z-50\n bg-gray-200 '," w-8 h-8\n top-0 ",' rounded-br-md cursor-pointer" onClick=','>\n <div class="h-6 w-6 mt-1 ml-1">\n <',' class="h-6 w-6" />\n </div>\n </div>\n '],f||(f=d.slice(0)),r=Object.freeze(Object.defineProperties(d,{raw:{value:Object.freeze(f)}}))),n?" text-red-500 animate-pulse":"",e.actionBar?"left-10":"left-0",(async function(){try{a(!1),c(!0);const o=e.player();o.layers.notyf.success("Saving, please wait...");try{await o.layers.save()}catch(e){console.error(e),o.layers.notyf.error(e.message)}if(u){try{var n,r;await(null===(n=(r=e.options()).onBeforeExit)||void 0===n?void 0:n.call(r)),await o.stop()}catch(e){console.error(e),o.layers.notyf.error(e.message)}t()}}finally{c(!1)}}),u?s.Icons.XCircle:s.Icons.FloppyDisk);var d,f}},{"../dom":139,"../icons":141,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],128:[function(e,t,n){"use strict";var r,o;function i(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.Client=void 0;const s=e("preact/hooks"),a=e("../dom"),l=e("../icons"),c=e("../dom");n.Client=function(e){const[t,n]=(0,s.useState)(!1);if(void 0===e.requestClientId&&null===e.clientId)return null;if(null===e.clientId){const o=()=>{void 0!==e.requestClientId&&(n(!0),e.requestClientId(!0).then((t=>{n(!1),e.setClientId(t)})).catch((e=>{n(!1),console.error(e)})))};return(0,a.html)(r||(r=i(['\n <div class="flex flex-row justify-center items-center ','">\n <div class="h-6 w-6 text-red-800 animate-pulse mr-2">\n <',' class="h-6 w-6" />\n </div>\n <div class="border-2 rounded px-4\n ',' \n cursor-pointer" onClick=',">\n Login\n </div>\n </div>\n "])),e.class,l.Icons.UserCircle,t?" text-gray-400 border-gray-400":"text-blue-400 border-blue-400",o)}const u=e.clientId.id;return(0,a.html)(o||(o=i(['\n <div class="flex flex-row justify-center ','">\n <div class="h-6 w-6 text-green-400 mr-2">\n <',' class="h-6 w-6" />\n </div>\n <div class="flex-shrink overflow-hidden overflow-ellipsis">','</div>\n <div class="h-6 w-6 ml-2 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n '])),e.class,l.Icons.UserCircle,u,(async function(){e.closeSideBar();const t=e.player();try{await async function(e){if(!e.ciPromise)return;const t=await e.ciPromise,n=await t.persist();(0,c.downloadFile)(n,"saves.zip","application/zip")}(t)}catch(e){t.layers.notyf.error("Unexpected error"),console.error(e)}}),l.Icons.Download)}},{"../dom":139,"../icons":141,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],129:[function(e,t,n){"use strict";var r,o,i;function s(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.Controls=void 0;const a=e("preact/hooks"),l=e("../dom"),c=e("../icons");function u(e){const[t,n]=(0,a.useState)(!1),[r,i]=(0,a.useState)(!1),[u,d]=(0,a.useState)(e.player().sensitivity);async function f(r,o){r.stopPropagation(),await e.setAutolock(o),t&&n(!1)}let p=Math.round(10*u)/10+"";1===p.length&&(p+=".0");const h=e.portal&&!e.autolock&&(t||r);return(0,l.html)(o||(o=s(['\n <div class="h-6 w-6 text-green-400 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n <div class="',' absolute z-50 \n bg-gray-200 -mt-7 h-8 left-10 flex flex-row items-center\n rounded-r-md cursor-pointer" onClick=','>\n <div class="flex flex-row ','">\n <div class="h-6 w-6 mx-2 \n ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 mx-2 \n ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 mx-2 pl-2 border-l-2 border-gray-400 text-gray-400 ',"\n ",'"\n onClick=',">\n ",'\n </div>\n </div>\n\n <div class="h-6 w-10 pr-2 pl-2 border-l-2 border-gray-400 ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n </div>\n '])),(async function(r){e.portal?n(!t):await async function(t){await f(t,!e.autolock)}(r)}),e.autolock?c.Icons.CursorClick:c.Icons.Cursor,e.portal?"":"hidden",(()=>{}),t?"":"hidden",e.autolock?"text-black":"text-green-400",(e=>f(e,!1)),c.Icons.Cursor,e.autolock?"text-green-400":"text-black",(e=>f(e,!0)),c.Icons.CursorClick,e.autolock?"":"hidden","1.0"===p?"text-black":"text-green-400",(async function(t){let n=u+.1;u>2&&(n=.1),await e.player().setSensitivity(n),d(n),t.stopPropagation()}),p,h?"":"hidden",(function(o){var s;null===(s=e.player().ciPromise)||void 0===s||s.then((e=>{e.sendMouseSync()})),r||i(!0),t&&n(!1),o.stopPropagation()}),c.Icons.Refresh)}function d(e){const[t,n]=(0,a.useState)(!1),[r,o]=(0,a.useState)(e.player().scaleControls);let u=Math.round(10*r)/10+"";return 1===u.length&&(u+=".0"),(0,l.html)(i||(i=s(['\n <div class="h-6 w-6 text-green-400 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n <div class="',' absolute z-50 bg-gray-200 -mt-7 h-8 left-10 flex flex-row items-center\n rounded-r-md cursor-pointer" onClick=','>\n <div class="h-6 w-6 mx-2 \n ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 mx-2 \n ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 mx-2 ','"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 px-2 border-l-2 border-gray-400 \n ','"\n onClick=',">\n ","\n </div>\n </div>\n </div>\n "])),(function(){e.portal?n(!t):e.setMobileControls(!e.mobileControls)}),e.mirroredControls?c.Icons.SwithcHorizontal:e.mobileControls?c.Icons.Mobile:c.Icons.EyeOff,t?"":"hidden",(()=>{}),e.mobileControls||e.mirroredControls?"text-black":"text-green-400",(async function(t){await e.setMirroredControls(!1),await e.setMobileControls(!1),n(!1),t.stopPropagation()}),c.Icons.EyeOff,!e.mirroredControls&&e.mobileControls?"text-green-400":"text-black",(async function(t){await e.setMobileControls(!0),await e.setMirroredControls(!1),n(!1),t.stopPropagation()}),c.Icons.Mobile,e.mirroredControls?"text-green-400":"text-black",(async function(t){await e.setMirroredControls(!0),n(!1),t.stopPropagation()}),c.Icons.SwithcHorizontal,"1.0"===u?"text-black":"text-green-400",(async function(t){let n=r+.1;r>1.5&&(n=1),await e.player().setScaleControls(n),o(n),t.stopPropagation()}),u)}n.Controls=function(e){return(0,l.html)(r||(r=s(['\n <div class="flex '," justify-evenly ",'">\n <'," ..."," />\n <"," ...",' />\n <div class="h-6 w-6 ',' cursor-pointer"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 ',' cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 ',' cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-6 w-6 '," \n ",' cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n '])),e.column?" flex-col":"flex-row",e.class,u,e,d,e,e.pause?" text-red-400 animate-pulse":"font-bold",(function(){e.setPause(!e.pause),e.closeSideBar()}),e.pause?c.Icons.Play:c.Icons.Pause,e.mute?" text-green-400":"",(function(){e.setMute(!e.mute),e.closeSideBar()}),e.mute?c.Icons.VolumeOff:c.Icons.VolumeUp,e.keyboard?" text-green-400":"",(function(){e.toggleKeyboard(),e.closeSideBar()}),c.Icons.PencilAlt,e.fullscreen?" text-green-400":"",!0===e.options().noFullscreen?"hidden":"",(function(){e.toggleFullscreen(),e.closeSideBar()}),c.Icons.ArrowsExpand)}},{"../dom":139,"../icons":141,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],130:[function(e,t,n){"use strict";var r;Object.defineProperty(n,"__esModule",{value:!0}),n.Region=void 0;const o=e("../dom"),i=e("../icons");n.Region=function(e){let t=e.region;return null!==t&&null!==e.latencyInfo&&(t+=" ("+e.latencyInfo.regionLatency+" ms)"),(0,o.html)(r||(n=['\n <div class="flex flex-row justify-between items-center ','">\n <div class="text-gray-600">Region</div>\n <div class="px-4 overflow-hidden overflow-ellipsis whitespace-nowrap flex-shrink">\n ','\n </div>\n <div class="h-6 w-6 ','" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n '],s||(s=n.slice(0)),r=Object.freeze(Object.defineProperties(n,{raw:{value:Object.freeze(s)}}))),e.class,t||e.estimatingRegion||"Connecting...",null===e.region?"animate-spin":"cursor-pointer",(function(){null!==e.region&&e.setRegion(null)}),i.Icons.Refresh);var n,s}},{"../dom":139,"../icons":141}],131:[function(e,t,n){"use strict";var r,o,i;function s(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.SideBar=void 0;const a=e("preact/hooks"),l=e("../dom"),c=e("../icons"),u=e("./sidebar/main"),d=e("./sidebar/latency-info"),f=e("./sidebar/networking"),p=e("../backend/v7/latency");function h(e){if(!0===e.options().noSocialLinks)return null;function t(){window.open("https://discord.com/invite/hMVYEbG","_blank")}function n(){window.open("https://t.me/doszonechat","_blank")}return!0===("networking"===e.sideBarPage)?(0,l.html)(o||(o=s(['\n <div class="flex flex-row justify-around items-center">\n <div class="font-bold text-purple-600">Matchmaking:</div>\n <div class="h-6 w-6 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-4 w-4 mt-0.5 text-gray-600 cursor-poiner" onClick=',">\n <",' class="h-4 w-4" />\n </div>\n </div>\n '])),t,c.Icons.Discord,n,c.Icons.Telegram):(0,l.html)(i||(i=s(['\n <div class="flex flex-row justify-around">\n <div class="h-6 w-6 -mt-1 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="h-4 w-4 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-4 w-4" />\n </div>\n <div class="h-4 w-4 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-4 w-4" />\n </div>\n <div class="h-6 w-6 -mt-1 text-gray-600 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n '])),t,c.Icons.Discord,n,c.Icons.Telegram,(function(){window.open("https://twitter.com/intent/user?screen_name=doszone_db","_blank")}),c.Icons.Twitter,(function(){window.open("https://dos.zone/donate/","_blank")}),c.Icons.CurrencyDollar)}n.SideBar=function(e){if(!e.sideBar)return null;(0,a.useEffect)((()=>{null===e.region&&(0,p.getAutoRegion)(e.setEstimatingRegion).then((t=>{e.setLatencyInfo(t),e.setRegion(t.region)})).catch(console.error)}),[e.region]);const t="networking"===e.sideBarPage;return(0,l.html)(r||(r=s(['\n <div class="flex flex-col filter absolute z-50 top-0 bottom-0 right-0 px-8 pt-6\n w-full sm:w-80 rounded-l-lg drop-shadow-lg bg-white overflow-y-auto overflow-x-hidden pb-4">\n <div class="transform absolute text-gray-400 hover:text-gray-800\n top-2 left-2 cursor-pointer hover:scale-125" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="transform absolute text-gray-400 hover:text-gray-800\n top-2 right-2 cursor-pointer hover:scale-125\n ','" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n \n \n <'," ..."," />\n <"," ..."," />\n <"," ...",' />\n\n <div class="flex-grow"></div>\n \n <'," ..."," />\n </div>\n "])),(function(){"main"===e.sideBarPage?e.closeSideBar():e.setSideBarPage("main")}),"main"===e.sideBarPage?c.Icons.XCircle:c.Icons.ArrowsCircleLeft,t?"text-purple-400":"",(function(){t?window.open("https://youtu.be/XEoWLQmU168","_blank"):(e.setShowTips(!0),e.closeSideBar())}),c.Icons.QuestionMarkCircle,u.Main,e,d.LatencyInfo,e,f.Networking,e,h,e)}},{"../backend/v7/latency":122,"../dom":139,"../icons":141,"./sidebar/latency-info":132,"./sidebar/main":133,"./sidebar/networking":134,"preact/hooks":121}],132:[function(e,t,n){"use strict";var r,o,i,s,a;function l(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.LatencyInfo=void 0;const c=e("../../dom"),u=e("../../icons");n.LatencyInfo=function(e){if(null===e.latencyInfo)return null;const t=t=>{e.setSideBarPage("latency-info"),t.stopPropagation(),t.preventDefault()};if(!0===e.asButton&&"main"===e.sideBarPage)return(0,c.html)(r||(r=l(['\n <div class="flex flex-row justify-between items-center cursor-pointer ',' my-2"\n onClick=','>\n <div class="">\n Show latency\n </div>\n <div>\n <',' class="text-green-400 h-6 -w-6" />\n </div>\n </div>\n '])),e.class,t,u.Icons.ArrowsCircleRight);if("latency-info"!==e.sideBarPage)return null;const n=[];for(const t of Object.keys(e.latencyInfo.estimation)){const r=[];r.push((0,c.html)(o||(o=l(['<div class="text-xs w-24 font-bold whitespace-nowrap break-words">',"</div>"])),t));for(let n=0;n<4;++n)r.push((0,c.html)(i||(i=l(['\n <div class="text-xs text-gray-600 text-right">\n ',"\n </div>\n "])),e.latencyInfo.estimation[t][n]));n.push((0,c.html)(s||(s=l(['<div class="flex flex-row flex-wrap justify-between">',"</div>"])),r))}return(0,c.html)(a||(a=l(['\n <div class="sidebar-header">Latency</div>\n <div class="flex flex-col">\n ',"\n </div>\n "])),n)}},{"../../dom":139,"../../icons":141,"core-js/modules/web.dom-collections.iterator.js":115}],133:[function(e,t,n){"use strict";var r,o;function i(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.Main=void 0;const s=e("../../dom"),a=e("../client"),l=e("../controls"),c=e("../region"),u=e("./latency-info"),d=e("../../icons");function f(e){return!0!==e.options().withExperimentalApi||null===e.region?null:(0,s.html)(o||(o=i(['\n <div class="flex flex-row justify-between items-center cursor-pointer ','"\n onClick=','>\n <div class="">\n Configure networks\n </div>\n <div>\n <',' class="text-green-400 h-6 -w-6" />\n </div>\n </div>\n '])),e.class,(()=>e.setSideBarPage("networking")),d.Icons.ArrowsCircleRight)}n.Main=function(e){return"main"!==e.sideBarPage?null:(0,s.html)(r||(r=i(["\n <",' class="mt-2 mb-2 pb-2 border-b-2 border-green-200" ...'," />\n <",' class="mt-2" portal='," ...",' />\n <div class="sidebar-header mt-8">Networking</div>\n <',' class="mt-2" ...'," />\n <"," ...",' class="mt-4" asButton='," />\n <"," ...",' class="mt-2" />\n '])),a.Client,e,l.Controls,!1,e,c.Region,e,u.LatencyInfo,e,!0,f,e)}},{"../../dom":139,"../../icons":141,"../client":128,"../controls":129,"../region":130,"./latency-info":132}],134:[function(e,t,n){"use strict";var r;Object.defineProperty(n,"__esModule",{value:!0}),n.Networking=void 0;const o=e("../../dom"),i=e("./token/token");n.Networking=function(e){return"networking"!==e.sideBarPage?null:(0,o.html)(r||(t=["\n <"," ..."," />\n "],n||(n=t.slice(0)),r=Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(n)}}))),i.TokenConfiguration,e);var t,n}},{"../../dom":139,"./token/token":137}],135:[function(e,t,n){"use strict";var r,o,i,s,a;function l(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.TokenAddTime=void 0;const c=e("preact/hooks"),u=e("../../../backend/v7/v7-config"),d=e("../../../dom"),f=e("../../../icons"),p=e("../../../request"),h=1800;n.TokenAddTime=function(e){const[t,n]=(0,c.useState)(null),[m,y]=(0,c.useState)(!1),[g,v]=(0,c.useState)(h),[b,_]=(0,c.useState)(null),[w,x]=(0,c.useState)(!1),k=m||g!==h&&null===b;return(0,d.html)(r||(r=l(['\n <div class="font-bold">Add time:</div>\n ',"\n \n ","\n \n "])),w?(0,d.html)(o||(o=l(['\n <div class="cursor-pointer underline text-green-600 font-bold" onClick=',">\n check payment\n </div> \n "])),e.update):(0,d.html)(i||(i=l(['\n <div class="flex flex-row">\n <select disabled=',' class="w-14 flex-grow mr-2 \n ',' "\n name="select" onChange=',">\n <option value=",' selected>FREE</option>\n <option value="259200">+3 Days</option>\n <option value="864000">+10 Days</option>\n <option value="2592000">+30 Days</option>\n </select>\n ',"\n </div>\n "])),m,m?"border-gray-400 disabled:bg-gray-200":"",(async function(t){const n=Number.parseInt(t.currentTarget.value);try{y(!0),_(null),v(n),n!==h&&_(await async function(e,t){var n;const r=null!==(n=t.clientId)&&void 0!==n?n:t.anonymousClientId;return(await(0,p.request)(u.checkoutCreateTokenEndpoint,"POST",JSON.stringify({id:r.id,namespace:r.namespace,product:e,token:t.networkToken}))).token}("t_"+n,e))}finally{y(!1)}}),h,k?f.Icons.Refresh({class:"h-6 w-6 animate-spin"}):(0,d.html)(s||(s=l(['\n <div class="h-6 w-6 cursor-pointer text-green-400 hover:text-green-600"\n onClick=',">\n <",' class="h-6 w-6" />\n </div>\n '])),(async function(t){if(t.stopPropagation(),!m){n(null),y(!0);try{if(g===h)await(0,p.request)(u.addFreeTimeTierEndpoint,"POST",JSON.stringify({token:e.networkToken})),e.update();else{if(null===b)throw new Error("accessToken is null");!function(e){window.open(u.checkoutEndpoint+"?token="+e,"_blank")}(b),setTimeout((()=>{x(!0)}),300)}}catch(t){n(function(e){if("30-min-required"===e)return"Only 30 minutes interval are enabled";if("free-soft-limit"===e)return"This token reached free time limit, please use paid time";if("free-hard-limit"===e)return"All free time of today is used, please use paid time";if("not-found"===e)return"Token not found";if("too-early"===e)return"You can add free time only if TTL less then 5 minutes";return e}(t.message))}finally{y(!1)}}}),f.Icons.Plus)),t?(0,d.html)(a||(a=l(['\n <div class="font-bold text-red-400 col-span-2">*',"</div>\n "])),t):null)}},{"../../../backend/v7/v7-config":124,"../../../dom":139,"../../../icons":141,"../../../request":144,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],136:[function(e,t,n){"use strict";var r,o,i,s;function a(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.TokenSelect=void 0;const l=e("../../../backend/v7/v7-config"),c=e("preact/hooks"),u=e("../../../request"),d=e("../../../dom"),f=e("../../../icons");n.TokenSelect=function(e){var t;const[n,p]=(0,c.useState)(null!==(t=e.networkToken)&&void 0!==t?t:""),[h,m]=(0,c.useState)(null),[y,g]=(0,c.useState)(!1),v=n===e.networkToken||""===n;function b(e){var t;p((null!==(t=e.currentTarget.value)&&void 0!==t?t:"").toLowerCase().trim())}async function _(){g(!0);try{if(v)return void(null!==e.networkToken&&!0!==window.confirm("Are you sure want to create token?")||await async function(){var t;if(y||null===e.region)return void m("region is not selected");m(null),g(!0);const n=null!==(t=e.clientId)&&void 0!==t?t:e.anonymousClientId;try{const t=await(0,u.request)(l.createTokenEndpoint,"POST",JSON.stringify({namespace:n.namespace,id:n.id,region:e.region}));e.setNetworkToken(t.token)}catch(e){m(e.message)}finally{g(!1)}}());const t=0===n.length?null:n;if(t===e.networkToken)return;!0===window.confirm(null===t?"Are you sure want to reset?":"Are you sure want to switch token?")&&(null!==t&&await async function(e){await(0,u.request)(l.tokeInfoGetEndpoint+"?token="+e)}(t),e.setNetworkToken(n))}catch(e){m("Token error: "+e.message)}finally{g(!1)}}return(0,d.html)(r||(r=a(['\n <div class="font-bold">Token:</div>\n\n ',"\n \n ","\n "])),y?(0,d.html)(o||(o=a(['\n <div class="col-span-2">\n <',' class="w-6 h-6 animate-spin" />\n </div>\n '])),f.Icons.Refresh):(0,d.html)(i||(i=a(['\n <div class="flex flex-row">\n <input class="rounded border ',' \n px-2 w-14 flex-grow mr-2" type="text" value='," \n onChange="," onKeyUp="," onKeyDown=",' />\n <div class="h-6 w-6 cursor-pointer ','" \n onClick=',">\n <",' \n class="h-6 w-6" />\n </div>\n </div>\n '])),""===n?"border-red-600":"border-green-200",n,b,(function(e){b(e),"Enter"===e.key&&_(),e.stopPropagation()}),(function(e){e.stopPropagation()}),v?"text-green-400 hover:text-green-600":"",_,v?f.Icons.Plus:f.Icons.SwithcHorizontal),h?(0,d.html)(s||(s=a(['\n <div class="text-red-400 col-span-2">',"</div>\n "])),h):null)}},{"../../../backend/v7/v7-config":124,"../../../dom":139,"../../../icons":141,"../../../request":144,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],137:[function(e,t,n){"use strict";var r,o,i,s,a,l,c,u,d,f,p,h;function m(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),e("core-js/modules/es.string.replace.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.TokenConfiguration=void 0;const y=e("preact/hooks"),g=e("../../../backend/v7/v7-config"),v=e("../../../dom"),b=e("../../../icons"),_=e("../../../xhr"),w=e("../../../request"),x=e("./token-select"),k=e("./token-add-time");function j(e){const[t,n]=(0,y.useState)(e.endTime-Date.now());return(0,y.useEffect)((()=>{if(t<=0)return;const r=setInterval((()=>{const t=Math.max(0,e.endTime-Date.now());0===t&&(e.update(),clearInterval(r)),n(t)}),1e4);return()=>clearInterval(r)}),[e.endTime]),(0,v.html)(l||(l=m(['\n <div class="font-bold">TTL:</div>\n <div class="',' cursor-pointer underline"\n onClick=',">\n ","\n </div>\n "])),t<3e5?" text-red-400":"text-gray-400",e.update,function(e){if(e>86400){const t=Math.round(e/24/60/60*10)/10;return t+(1===t?" Day":" Days")}if(e>3600){const t=Math.round(e/60/60*10)/10;return t+(1===t?" Hour":" Hrs")}return Math.round(e/60*10)/10+" Min"}(t/1e3))}function C(e){const[t,n]=(0,y.useState)(!1),[r,o]=(0,y.useState)(null);function i(){n(!0),(0,_.postObject)(g.stopIpx+"?token=".concat(e.networkToken,"&arn=").concat(e.ipx.arn)).then((()=>{n(!1),e.ipx.setAddress(null),e.ipx.setAwaitingAddress(!1)})).catch((e=>{var t;console.error("Can't stop ipx",e),o(null!==(t=e.errorCode)&&void 0!==t?t:e.message),n(!1)}))}if(null!==r)return(0,v.html)(c||(c=m(['\n <div class="text-red-400 col-span-2">',"</div>\n "])),r);if(t)return(0,v.html)(u||(u=m(["\n <",' class="w-6 h-6 col-span-2 animate-spin" />\n '])),b.Icons.Refresh);if(null!==e.ipx.address){const t=e.ipxConnected?"Disconnect":e.ipx.awaitingConnection?"Connecting...":"Connect",n=()=>{e.ipx.awaitingConnection||function(){var t;const n=!e.ipxConnected,r=e.ipx.address;r&&(null===(t=e.player().ciPromise)||void 0===t||t.then((t=>n?(e.ipx.setAwaitingConnection(!0),"http:"===location.protocol&&void 0===e.options().hardware&&r.endsWith(".jj.dos.zone")?t.networkConnect(0,"ws://"+r.substring(0,r.length-".jj.dos.zone".length).replace(/_/g,"."),1901):t.networkConnect(0,r,1901)):t.networkDisconnect(0))).then((()=>{e.ipx.setAwaitingConnection(!1),e.setIpxConnected(n),n&&(e.player().layers.notyf.success("Connected"),e.closeSideBar())})).catch((t=>{e.ipx.setAwaitingConnection(!1),console.error(t),o(t.message)})))}()};return(0,v.html)(d||(d=m(['\n <div class="font-bold">IPX:</div>\n <div class="font-bold text-gray-400 text-xs break-all -mx-6 text-center">','</div>\n <div class=""></div>\n <div class="','\n cursor-pointer rounded uppercase text-center px-2 py-1"\n onClick=',">",'</div>\n <div class="','"></div>\n <div class="','\n bg-gray-200 cursor-pointer rounded uppercase text-center px-4 py-1"\n onClick=',">Stop</div>\n "])),e.ipx.address,e.ipxConnected?" bg-red-200":"bg-green-200",n,t,e.ipxConnected?"hidden":"",e.ipxConnected?"hidden":"none",i)}return e.ipx.awaitingAddress?(0,v.html)(f||(f=m(['\n <div class="font-bold">IPX:</div>\n <',' />\n <div class=""></div>\n <div class="bg-gray-200 cursor-pointer rounded uppercase text-center px-4 py-1" onClick=',">Stop</div>\n "])),E,i):(0,v.html)(p||(p=m(['\n <div class="font-bold">IPX:</div>\n <div class="bg-green-200 cursor-pointer rounded uppercase text-center px-4 py-1" onClick=',">Start</div>\n "])),(function(){n(!0),(0,_.getObject)(g.startIpx+"?token=".concat(e.networkToken)).then((t=>{n(!1),e.ipx.setArn(t.arn),e.ipx.setAwaitingAddress(!0)})).catch((e=>{var t;console.error("Can't start ipx",e),o(null!==(t=e.errorCode)&&void 0!==t?t:e.message),n(!1)}))}))}function E(){const[e,t]=(0,y.useState)(30);return(0,y.useEffect)((()=>{if(0===e)return;const n=setTimeout((()=>{t(e-1)}),1e3);return()=>clearTimeout(n)}),[e]),(0,v.html)(h||(h=m(['\n <div class="text-gray-400 flex flex-row">\n <',' class="w-6 h-6 animate-spin mr-2" />\n ',"\n </div>\n "])),b.Icons.Refresh,e>0?e+" sec":"")}n.TokenConfiguration=function(e){const[t,n]=(0,y.useState)(null),[l,c]=(0,y.useState)(!0),[u,d]=(0,y.useState)(Date.now()),[f,p]=(0,y.useState)(null),[h,_]=(0,y.useState)(null),[E,D]=(0,y.useState)(!1),[S,O]=(0,y.useState)(!1),P={arn:f,setArn:p,address:h,setAddress:_,awaitingAddress:E,setAwaitingAddress:D,awaitingConnection:S,setAwaitingConnection:O},B={...e,ipx:P,update:M};async function M(){if(p(null),_(null),D(!1),c(!0),null===e.networkToken)return n(null),void c(!1);(0,w.request)(g.tokeInfoGetEndpoint+"?token=".concat(e.networkToken)).then((e=>{n(e),c(!1),d(Date.now()+1e3*e.ttlSec),void 0!==e.ipxArn&&p(e.ipxArn),void 0!==e.ipxAddress?_(e.ipxAddress):void 0!==e.ipxArn&&D(!0)})).catch((t=>{console.error("Can't get a token",e.networkToken,t),n(null),c(!1)}))}if((0,y.useEffect)((()=>{M()}),[e.networkToken]),(0,y.useEffect)((()=>{if(null===e.networkToken||u<Date.now())return;const t=setInterval((()=>{(0,w.request)(g.tokeInfoGetEndpoint+"?token=".concat(e.networkToken)).then((e=>{e.ipxArn||(e.ipxArn=null),e.ipxAddress||(e.ipxAddress=null),f===e.ipxArn?e.ipxAddress!==h&&(_(e.ipxAddress),D(!1)):M()}))}),5e3);return()=>{clearInterval(t)}}),[e.networkToken,u,f,h]),l)return(0,v.html)(r||(r=m(['\n <div class="sidebar-header">Configuration</div>\n <div class="grid grid-cols-2 gap-4">\n <',' class="w-6 h-6 animate-spin" />\n </div>\n '])),b.Icons.Refresh);if(null===t)return(0,v.html)(o||(o=m(['\n <div class="sidebar-header">Configuration</div>\n <div class="grid grid-cols-2 gap-4">\n <'," ..."," networkToken="," />\n </div>\n "])),x.TokenSelect,e,null);const T=(0,v.html)(i||(i=m(['\n <div class="sidebar-header flex flex-row justify-center items-center">\n Configuration\n <div onClick='," >\n <",' class="h-4 w-4 ml-2 cursor-pointer" />\n </div>\n </div>\n '])),M,b.Icons.Refresh);return u<Date.now()?(0,v.html)(s||(s=m(["\n ",'\n <div class="grid grid-cols-2 gap-4">\n <'," ...",' />\n <div class="font-bold">Region:</div>\n <div class="text-gray-400">','</div>\n <div class="font-bold">TTL:</div>\n <div class="text-red-400">0 Min</div>\n <'," ..."," />\n </div>\n "])),T,x.TokenSelect,e,t.region,k.TokenAddTime,B):(0,v.html)(a||(a=m(["\n ",'\n <div class="grid grid-cols-2 gap-4">\n <'," ...",' />\n <div class="font-bold">Region:</div>\n <div class="text-gray-400">',"</div>\n <"," endTime="," update="," />\n <"," ..."," />\n <"," ..."," />\n </div>\n "])),T,x.TokenSelect,e,t.region,j,u,M,k.TokenAddTime,B,C,B)}},{"../../../backend/v7/v7-config":124,"../../../dom":139,"../../../icons":141,"../../../request":144,"../../../xhr":145,"./token-add-time":135,"./token-select":136,"core-js/modules/es.string.replace.js":114,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],138:[function(e,t,n){"use strict";var r,o,i,s,a,l;function c(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.Tips=void 0;const u=e("preact/hooks"),d=e("../dom"),f=e("../icons"),p={common:{title:"Tips",tip:(0,d.html)(r||(r=c(["\n <div>\n On the left side of the screen you can see a sidebar, it has a set of useful controls.\n You can hide it at any time by pressing on the arrow in the middle.\n </div>\n"])))},mouse:{title:"Mouse",tip:(0,d.html)(o||(o=c(['\n <div>\n <p class="mb-2">\n By clicking on pointer icon you can switch between <b>regular mouse emulation</b> and <b>lock mode</b>.\n </p>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - In regular mouse emulation mode game will receive\n borwser pointer coordinates. If the browser pointer and game pointer is out of sync then use\n </p>\n <',' class="h-4 w-4 text-green-400 mx-2 inline-block" />\n <p class="inline">\n refresh control to synchronize dos and browser pointer poistion.\n </p>\n </div>\n </div>\n '])),f.Icons.Cursor,f.Icons.Refresh)},mouseLock:{title:"Mouse lock",tip:(0,d.html)(i||(i=c(['\n <div>\n <p class="mb-2">\n Some DOS games do not respect the mouse cursor position, they take into account only relative movement \n of the mouse cursor.\n </p>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - When the mouse is locked DOS game receives only the relative movement of mouse and\n the cursor can\'t leave the game screen. You can use sensitivity control (inside the mouse submenu)\n to change the sensitivity of mouse movement.\n </p>\n </div>\n </div>\n '])),f.Icons.CursorClick)},mobile:{title:"Mobile",tip:(0,d.html)(s||(s=c(['\n <div>\n <p>\n You can change visibility of mobile controls by pressing on of this buttons:\n </p>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - shows the mobile controls if they are provided by the game.\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - shows the mobile controls but mirrored.\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - completely hide the mobile controls.\n </p>\n </div>\n <p>\n You can <b>SCALE</b> the size of mobile controls inside submenu.\n </p>\n </div>\n '])),f.Icons.Mobile,f.Icons.SwithcHorizontal,f.Icons.EyeOff)},other:{title:"Other",tip:(0,d.html)(a||(a=c(['\n <div>\n <p>\n Game controls:\n </p>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - pause/resume game,\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - mute/unmute sound,\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - toggle soft keyboard,\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - toggle fullscreen,\n </p>\n </div>\n <div class="float-left">\n <',' class="h-4 w-4 text-green-400 mr-2 inline-block" />\n <p class="inline">\n - will open the settings sidebar, where you can change additional\n settings of js-dos like networking.\n </p>\n </div>\n </div>\n '])),f.Icons.Pause,f.Icons.VolumeUp,f.Icons.PencilAlt,f.Icons.ArrowsExpand,f.Icons.DotsHorizontal)}},h=/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(navigator.userAgent.toLowerCase())?["common","mobile","mouse","mouseLock","other"]:["common","mouse","mouseLock","mobile","other"];n.Tips=function(e){const[t,n]=(0,u.useState)(0);if(!e.showTips)return null;const r=p[h[t]];return(0,d.html)(l||(l=c(['\n <div class="absolute z-50 rounded bg-gray-200 shadow-lg top-5 right-5 w-64 p-2 border-b border-gray-800">\n <div class="flex row justify-between mb-2">\n <div class="h-6 w-6 cursor-pointer" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n <div class="text-lg font-bold">','</div>\n <div class="h-6 w-6 cursor-pointer text-blue-600 animate-pulse" onClick=',">\n <",' class="h-6 w-6" />\n </div>\n </div>\n <div class="text-sm px-2 overflow-auto max-h-72">\n ',"\n </div>\n </div>\n "])),(()=>e.setShowTips(!1)),f.Icons.XCircle,r.title,(function(){n((t+1)%h.length)}),f.Icons.ArrowsCircleRight,r.tip)}},{"../dom":139,"../icons":141,"core-js/modules/web.dom-collections.iterator.js":115,"preact/hooks":121}],139:[function(e,t,n){"use strict";e("core-js/modules/web.dom-collections.iterator.js"),e("core-js/modules/web.url.js"),e("core-js/modules/web.url-search-params.js");var r=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(n,"__esModule",{value:!0}),n.downloadFile=n.click=n.createDiv=n.activeClass=n.primaryClass=n.disabledClass=n.goneClass=n.html=void 0;const o=e("preact"),i=r(e("htm"));n.html=i.default.bind(o.h),n.goneClass="jsdos-player-gone",n.disabledClass="jsdos-player-button-disabled",n.primaryClass="jsdos-player-button-primary",n.activeClass="jsdos-player-button-active",n.createDiv=function(e,t){const n=document.createElement("div");if("string"==typeof e)n.className=e;else for(const t of e)n.classList.add(t);return void 0!==t&&(n.innerHTML=t),n},n.click=function(e,t){for(const n of emulatorsUi.dom.pointers.bind.enders)e.addEventListener(n,(()=>{e.classList.contains("jsdos-player-button-disabled")||t(e)}))};let s=null;n.downloadFile=function(e,t,n){const r=new Blob([e],{type:n});null!==s&&window.URL.revokeObjectURL(s),s=window.URL.createObjectURL(r);const o=document.createElement("a");o.href=s,o.download=t,o.style.display="none",document.body.appendChild(o),o.click(),o.remove()}},{"core-js/modules/web.dom-collections.iterator.js":115,"core-js/modules/web.url-search-params.js":116,"core-js/modules/web.url.js":117,htm:118,preact:120}],140:[function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}e("core-js/modules/es.string.replace.js");var o=Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]},i=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t},s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&o(t,e,n);return i(t,e),t};Object.defineProperty(n,"__esModule",{value:!0}),n.hardwareTransportLayerFactory=n.HardwareTransportLayerFactory=void 0;const a=s(e("base64-js")),l=new TextDecoder;class c{constructor(e){r(this,"sessionId",Date.now()+""),r(this,"hardware",void 0),r(this,"alive",!0),r(this,"frameWidth",0),r(this,"frameHeight",0),r(this,"handler",(()=>{})),this.hardware=e}callMain(){this.hardware.sendMessage("wc-install\n"+this.sessionId+"\n"),requestAnimationFrame(this.update.bind(this))}async sendMessageToServer(e,t){if(void 0!==t&&(null==t?void 0:t.sessionId)===this.sessionId)switch(e){case"wc-run":{let e=d(this.hardware,"bundle_0.zip",t.bundles[0]);if(e.length>0)throw console.error(e),new Error(e);if(void 0!==t.bundles[1]&&(e=d(this.hardware,"bundle_1.zip",t.bundles[1]),e.length>0))throw console.error(e),new Error(e);const n="wc-run\n";this.hardware.sendMessage(n)}break;case"wc-add-key":this.hardware.addKey(t.key,t.pressed?1:0,t.timeMs);break;case"wc-pause":this.hardware.sendMessage("wc-pause\n"+this.sessionId+"\n");break;case"wc-resume":this.hardware.sendMessage("wc-resume\n"+this.sessionId+"\n");break;case"wc-mute":this.hardware.sendMessage("wc-mute\n"+this.sessionId+"\n");break;case"wc-unmute":this.hardware.sendMessage("wc-unmute\n"+this.sessionId+"\n");break;case"wc-exit":this.alive=!1,this.hardware.sendMessage("wc-exit\n"+this.sessionId+"\n");break;case"wc-mouse-move":this.hardware.mouseMove(t.x,t.y,t.relative,t.timeMs);break;case"wc-mouse-button":this.hardware.mouseButton(t.button,t.pressed?1:0,t.timeMs);break;case"wc-pack-fs-to-bundle":this.hardware.sendMessage("wc-pack-fs-to-bundle\n"+this.sessionId+"\n");break;case"wc-connect":this.hardware.sendMessage("wc-connect\n"+this.sessionId+"\n"+t.networkType+"\n"+t.address.replace("ws://","").replace("wss://","")+"\n"+(t.port-1)+"\n");break;case"wc-disconnect":this.hardware.sendMessage("wc-disconnect\n"+this.sessionId+"\n"+t.networkType+"\n");break;default:console.log("Unhandled client message (wc):",e,t)}}initMessageHandler(e){this.handler=e}exit(){this.alive=!1}async onServerMessage(e,t){const n=t||{};switch(e){case"ws-server-ready":{const e=this.hardware.readConfig();this.handler("ws-config",{sessionId:this.sessionId,content:e})}break;case"ws-sound-init":this.handler(e,n),this.handler("ws-server-ready",{sessionId:this.sessionId});break;case"ws-frame-set-size":this.frameWidth=n.width,this.frameHeight=n.height,this.handler(e,n);break;case"ws-sound-push":case"ws-update-lines":console.error(e,"should not be called");break;case"ws-persist":n.bundle=f(n.bundle),this.handler(e,n);break;case"ws-log":case"ws-warn":case"ws-err":case"ws-stdout":void 0!==n.message&&null!==n.message&&n.message.length>0&&(n.message=l.decode(f(n.message))),this.handler(e,n);break;default:this.handler(e,n)}}update(){this.alive&&requestAnimationFrame(this.update.bind(this)),this.updateFrame()}updateFrame(){if(0===this.frameWidth||0===this.frameHeight)return;const e=this.hardware.getFramePayload();if(0===e.length)return;const t=f(e);if(0===t.length)return;const n=[],r=3*this.frameWidth;let o=this.frameHeight,i=-1;for(let e=0;e<this.frameHeight;++e){const s=e===this.frameHeight-1;if(1===t[e]&&-1===i)i=e;else if((s||0===t[e])&&-1!==i){const s=((1===t[e]?e:e-1)-i+1)*r,a=t.slice(o,o+s);n.push({start:i,heapu8:a}),o+=s,i=-1}}this.handler("ws-update-lines",{sessionId:this.sessionId,lines:n})}}class u{constructor(){r(this,"serverMessageHandler",(()=>{})),window.serverMessage=e=>{const t=l.decode(f(e));try{const e=JSON.parse("{"+t.slice(0,-1)+"}");this.serverMessageHandler(e.name,e)}catch(e){throw console.error("Can't parse",t,e),e}},this.createTransportLayer=this.createTransportLayer.bind(this)}createTransportLayer(e){const t=new c(e);return this.serverMessageHandler=t.onServerMessage.bind(t),t.callMain(),t}}function d(e,t,n){if(void 0!==e.writeFile)return e.writeFile(t,p(n));let r=e.createFile(t);if(r.length>0)return r;let o=0;for(;o<n.length;){const t=Math.min(4194304,n.length-o),i=n.subarray(o,o+t);if(r=e.appendFile(p(i)),r.length>0)return r;o+=t}return r=e.closeFile(),r}function f(e){return a.toByteArray(e)}function p(e){return a.fromByteArray(e)}n.HardwareTransportLayerFactory=u,n.hardwareTransportLayerFactory=new u},{"base64-js":1,"core-js/modules/es.string.replace.js":114}],141:[function(e,t,n){"use strict";var r,o,i,s,a,l,c,u,d,f,p,h,m,y,g,v,b,_,w,x,k,j,C,E,D,S,O,P;function B(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.Icons=void 0;const M=e("./dom");n.Icons={XCircle:e=>(0,M.html)(r||(r=B(['\n <svg fill="none" class=',' viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),UserCircle:e=>(0,M.html)(o||(o=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M5.121 17.804A13.937 13.937 0 0112 16c2.5 0 4.847.655 6.879 1.804M15 10a3 3 0 11-6 0 3 3 0 016 0zm6 2a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),Mobile:e=>(0,M.html)(i||(i=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M12 18h.01M8 21h8a2 2 0 002-2V5a2 2 0 00-2-2H8a2 2 0 00-2 2v14a2 2 0 002 2z" />\n </svg>\n'])),e.class),SwithcHorizontal:e=>(0,M.html)(s||(s=B(['\n <svg class="','" fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M8 7h12m0 0l-4-4m4 4l-4 4m0 6H4m0 0l4 4m-4-4l4-4" />\n </svg>\n'])),e.class),EyeOff:e=>(0,M.html)(a||(a=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M13.875 18.825A10.05 10.05 0 0112 19c-4.478 0-8.268-2.943-9.543-7a9.97 9.97 0 011.563-3.029m5.858.908a3 3 0 114.243 4.243M9.878 9.878l4.242 4.242M9.88 9.88l-3.29-3.29m7.532 7.532l3.29 3.29M3 3l3.59 3.59m0 0A9.953 9.953 0 0112 5c4.478 0 8.268 2.943 9.543 7a10.025 10.025 0 01-4.132 5.411m0 0L21 21" />\n </svg>\n'])),e.class),Pause:e=>(0,M.html)(l||(l=B(["\n <svg className=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2}\n d="M10 9v6m4-6v6m7-3a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),Play:e=>(0,M.html)(c||(c=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M14.752 11.168l-3.197-2.132A1 1 0 0010 9.87v4.263a1 1 0 001.555.832l3.197-2.132a1 1 0 000-1.664z" />\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),VolumeUp:e=>(0,M.html)(u||(u=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M15.536 8.464a5 5 0 010 7.072m2.828-9.9a9 9 0 010 12.728M5.586 15H4a1 1 0 01-1-1v-4a1 1 0 011-1h1.586l4.707-4.707C10.923 3.663 12 4.109 12 5v14c0 .891-1.077 1.337-1.707.707L5.586 15z" />\n </svg>\n'])),e.class),VolumeOff:e=>(0,M.html)(d||(d=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M5.586 15H4a1 1 0 01-1-1v-4a1 1 0 011-1h1.586l4.707-4.707C10.923 3.663 12 4.109 12 5v14c0 .891-1.077 1.337-1.707.707L5.586 15z"\n clip-rule="evenodd" />\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2" />\n </svg>\n'])),e.class),PencilAlt:e=>(0,M.html)(f||(f=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z" />\n </svg>\n'])),e.class),ArrowsExpand:e=>(0,M.html)(v||(v=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M4 8V4m0 0h4M4 4l5 5m11-1V4m0 0h-4m4 0l-5 5M4 16v4m0 0h4m-4 0l5-5m11 5l-5-5m5 5v-4m0 4h-4" />\n </svg>\n'])),e.class),ArrowsCircleLeft:e=>(0,M.html)(b||(b=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M11 15l-3-3m0 0l3-3m-3 3h8M3 12a9 9 0 1118 0 9 9 0 01-18 0z" />\n </svg>\n'])),e.class),ArrowsCircleRight:e=>(0,M.html)(_||(_=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2}\n d="M13 9l3 3m0 0l-3 3m3-3H8m13 0a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),ChevronLeft:e=>(0,M.html)(p||(p=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7" />\n </svg>\n'])),e.class),ChevronRight:e=>(0,M.html)(h||(h=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5l7 7-7 7" />\n </svg>\n'])),e.class),DotsHorizontal:e=>(0,M.html)(m||(m=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M5 12h.01M12 12h.01M19 12h.01M6 12a1 1 0 11-2 0 1 1 0 012 0zm7 0a1 1 0 11-2 0 1 1 0 012 0zm7 0a1 1 0 11-2 0 1 1 0 012 0z" />\n </svg>\n'])),e.class),Download:e=>(0,M.html)(y||(y=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M4 16v1a3 3 0 003 3h10a3 3 0 003-3v-1m-4-4l-4 4m0 0l-4-4m4 4V4" />\n </svg>\n'])),e.class),Upload:e=>(0,M.html)(g||(g=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M4 16v1a3 3 0 003 3h10a3 3 0 003-3v-1m-4-8l-4-4m0 0L8 8m4-4v12" />\n </svg>\n'])),e.class),Plus:e=>(0,M.html)(w||(w=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 4v16m8-8H4" />\n </svg>\n'])),e.class),CursorClick:e=>(0,M.html)(x||(x=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M15 15l-2 5L9 9l11 4-5 2zm0 0l5 5M7.188 2.239l.777 2.897M5.136 7.965l-2.898-.777M13.95 4.05l-2.122 2.122m-5.657 5.656l-2.12 2.122" />\n </svg>\n'])),e.class),Cursor:e=>(0,M.html)(k||(k=B(["\n <svg class=",' fill="currentColor" viewBox="0 0 24 24">\n <path\n d="M 7 2 L 7 18.5 L 11.09375 14.605469 L 14.300781 22 L 16.5 21 L 13.195312 13.701172 L 13.199219 13.699219 L 19 13.199219 L 7 2 z M 9 6.6015625 L 14.347656 11.59375 L 13.029297 11.707031 L 12.708984 11.734375 L 12.412109 11.861328 L 10.3125 12.761719 L 9.9824219 12.904297 L 9.7226562 13.152344 L 9 13.837891 L 9 6.6015625 z" />\n </svg>\n'])),e.class),Refresh:e=>(0,M.html)(j||(j=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15" />\n </svg>\n'])),e.class),CurrencyDollar:e=>(0,M.html)(C||(C=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M12 8c-1.657 0-3 .895-3 2s1.343 2 3 2 3 .895 3 2-1.343 2-3 2m0-8c1.11 0 2.08.402 2.599 1M12 8V7m0 1v8m0 0v1m0-1c-1.11 0-2.08-.402-2.599-1M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),QuestionMarkCircle:e=>(0,M.html)(E||(E=B(["\n <svg class=",' fill="none" viewBox="0 0 24 24" stroke="currentColor">\n <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"\n d="M8.228 9c.549-1.165 2.03-2 3.772-2 2.21 0 4 1.343 4 3 0 1.4-1.278 2.575-3.006 2.907-.542.104-.994.54-.994 1.093m0 3h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />\n </svg>\n'])),e.class),Discord:e=>(0,M.html)(D||(D=B(["\n <svg class=",' fill="none" viewBox="0 0 245 240" stroke="currentColor">\n <style>.st0{fill:#5c7080;}</style>\n <path class="st0" d="M104.4 103.9c-5.7 0-10.2 5-10.2 11.1s4.6 11.1 10.2 11.1c5.7 0 10.2-5 10.2-11.1.1-6.1-4.5-11.1-10.2-11.1zM140.9 103.9c-5.7 0-10.2 5-10.2 11.1s4.6 11.1 10.2 11.1c5.7 0 10.2-5 10.2-11.1s-4.5-11.1-10.2-11.1z"/><path class="st0" d="M189.5 20h-134C44.2 20 35 29.2 35 40.6v135.2c0 11.4 9.2 20.6 20.5 20.6h113.4l-5.3-18.5 12.8 11.9 12.1 11.2 21.5 19V40.6c0-11.4-9.2-20.6-20.5-20.6zm-38.6 130.6s-3.6-4.3-6.6-8.1c13.1-3.7 18.1-11.9 18.1-11.9-4.1 2.7-8 4.6-11.5 5.9-5 2.1-9.8 3.5-14.5 4.3-9.6 1.8-18.4 1.3-25.9-.1-5.7-1.1-10.6-2.7-14.7-4.3-2.3-.9-4.8-2-7.3-3.4-.3-.2-.6-.3-.9-.5-.2-.1-.3-.2-.4-.3-1.8-1-2.8-1.7-2.8-1.7s4.8 8 17.5 11.8c-3 3.8-6.7 8.3-6.7 8.3-22.1-.7-30.5-15.2-30.5-15.2 0-32.2 14.4-58.3 14.4-58.3 14.4-10.8 28.1-10.5 28.1-10.5l1 1.2c-18 5.2-26.3 13.1-26.3 13.1s2.2-1.2 5.9-2.9c10.7-4.7 19.2-6 22.7-6.3.6-.1 1.1-.2 1.7-.2 6.1-.8 13-1 20.2-.2 9.5 1.1 19.7 3.9 30.1 9.6 0 0-7.9-7.5-24.9-12.7l1.4-1.6s13.7-.3 28.1 10.5c0 0 14.4 26.1 14.4 58.3 0 0-8.5 14.5-30.6 15.2z"/>\n </svg>\n'])),e.class),Telegram:e=>(0,M.html)(O||(O=B(["\n <svg class=",' fill="none" viewBox="0 0 240 240" stroke="currentColor">\n <defs>\n <linearGradient id="A" x1="160.01" x2="100.01" y1="40.008" y2="180" gradientUnits="userSpaceOnUse">\n <stop stop-color="#758599" offset="0"/>\n <stop stop-color="#556559" offset="1"/>\n </linearGradient>\n </defs>\n <circle fill="url(#A)" r="120" cy="120" cx="120"/><path d="M49.942 118.96l80.81-33.295c7.977-3.468 35.03-14.566 35.03-14.566s12.486-4.855 11.445 6.936c-.347 4.855-3.12 21.85-5.896 40.23l-8.67 54.45s-.694 7.977-6.6 9.364-15.607-4.855-17.34-6.243c-1.387-1.04-26.012-16.647-35.03-24.277-2.428-2.08-5.202-6.243.347-11.098 12.486-11.445 27.4-25.665 36.416-34.682 4.162-4.162 8.324-13.873-9.017-2.08l-48.902 32.948s-5.55 3.468-15.954.347-22.543-7.283-22.543-7.283-8.324-5.202 5.896-10.75z" fill="#fff"/>\n </svg>\n'])),e.class),Twitter:e=>(0,M.html)(S||(S=B(["\n <svg class=",' fill="none" viewBox="0 0 400 400" stroke="currentColor">\n <style type="text/css">\n .st0{fill:#5c7080;}\n </style>\n <path class="st0" d="M400,200c0,110.5-89.5,200-200,200S0,310.5,0,200S89.5,0,200,0S400,89.5,400,200z M163.4,305.5\n c88.7,0,137.2-73.5,137.2-137.2c0-2.1,0-4.2-0.1-6.2c9.4-6.8,17.6-15.3,24.1-25c-8.6,3.8-17.9,6.4-27.7,7.6\n c10-6,17.6-15.4,21.2-26.7c-9.3,5.5-19.6,9.5-30.6,11.7c-8.8-9.4-21.3-15.2-35.2-15.2c-26.6,0-48.2,21.6-48.2,48.2\n c0,3.8,0.4,7.5,1.3,11c-40.1-2-75.6-21.2-99.4-50.4c-4.1,7.1-6.5,15.4-6.5,24.2c0,16.7,8.5,31.5,21.5,40.1c-7.9-0.2-15.3-2.4-21.8-6\n c0,0.2,0,0.4,0,0.6c0,23.4,16.6,42.8,38.7,47.3c-4,1.1-8.3,1.7-12.7,1.7c-3.1,0-6.1-0.3-9.1-0.9c6.1,19.2,23.9,33.1,45,33.5\n c-16.5,12.9-37.3,20.6-59.9,20.6c-3.9,0-7.7-0.2-11.5-0.7C110.8,297.5,136.2,305.5,163.4,305.5"/>\n </svg>\n'])),e.class),FloppyDisk:e=>(0,M.html)(P||(P=B(["\n <svg class=",' style="padding-left: 2px; padding-top: 4px" fill="none" viewBox="0 0 20 20" stroke="currentColor">\n <g id="floppy_disk">\n <g>\n <path fill-rule="evenodd" clip-rule="evenodd" d="M15.71,2.29l-2-2C13.53,0.11,13.28,0,13,0h-1v6H4V0H1C0.45,0,0,0.45,0,1v14\n c0,0.55,0.45,1,1,1h14c0.55,0,1-0.45,1-1V3C16,2.72,15.89,2.47,15.71,2.29z M14,15H2V9c0-0.55,0.45-1,1-1h10c0.55,0,1,0.45,1,1V15\n z M11,1H9v4h2V1z"/>\n </g>\n </g>\n </svg>\n'])),e.class)}},{"./dom":139}],142:[function(e,t,n){"use strict";var r,o;function i(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.createPlayerApp=n.PlayerApp=void 0;const s=e("preact"),a=e("preact/hooks"),l=e("./dom"),c=e("./components/action-hide"),u=e("./components/action-bar"),d=e("./components/action-save-or-exit"),f=e("./components/sidebar"),p=e("./components/tip"),h=e("nanoid/non-secure"),m="client.id",y="network.token",g="network.region",v="ui.tips";function b(e){const t=emulatorsUi.dom.storage,n=e.options().clientId,o="function"==typeof n?e=>n(e):void 0,[s,b]=(0,a.useState)(null),[_,w]=(0,a.useState)(!1),[x,k]=(0,a.useState)(e.player().mobileControls),[j,C]=(0,a.useState)(e.player().mirroredControls),[E,D]=(0,a.useState)(e.player().autolock),[S,O]=(0,a.useState)(e.player().layers.keyboardVisible),[P,B]=(0,a.useState)(!1),[M,T]=(0,a.useState)(!1),[A,I]=(0,a.useState)(e.player().layers.fullscreen),[K,L]=(0,a.useState)(!0),[R,N]=(0,a.useState)(t.getItem(g)),[F,U]=(0,a.useState)(null),[z,H]=(0,a.useState)("false"!==t.getItem(v)),[W,q]=(0,a.useState)(null),[V,G]=(0,a.useState)("main"),[Y]=(0,a.useState)((()=>{const e=t.getItem(m),n=null!=e?e:(0,h.nanoid)();return null===e&&t.setItem(m,n),{namespace:encodeURIComponent("local ("+location.href+")"),id:n}})),[X,$]=(0,a.useState)(t.getItem(y)),[J,Q]=(0,a.useState)(!1);(0,a.useEffect)((()=>{const e=e=>{var t;"jsdos-get-network-token"==e.data.message&&(null===(t=e.source)||void 0===t||t.postMessage({message:"jsdos-network-token",token:X},"*"))};return window.addEventListener("message",e),()=>window.removeEventListener("message",e)}),[X]),(0,a.useEffect)((()=>{void 0!==o&&o(!1).then(b).catch(console.error)}),[n,b]),(0,a.useEffect)((()=>(e.setOnRun((()=>{D(e.player().autolock)})),()=>e.setOnRun((()=>{})))),[e.setOnRun]),(0,a.useEffect)((()=>{const e=()=>{const e=null!==document.fullscreenElement;I(e),e||L(!0)};return document.addEventListener("fullscreenchange",e),()=>{document.removeEventListener("fullscreenchange",e)}}),[A,I]);const Z={player:e.player,options:e.options,clientId:s,setClientId:b,requestClientId:o,anonymousClientId:Y,networkToken:X,setNetworkToken:e=>{null===e?t.removeItem(y):t.setItem(y,e),$(e)},mobileControls:x,setMobileControls:async t=>{t?e.player().enableMobileControls():e.player().disableMobileControls(),k(t)},mirroredControls:j,setMirroredControls:async e=>{Z.player().setMirroredControls(e),C(e)},autolock:E,setAutolock:async e=>{Z.player().setAutolock(e),D(e)},keyboard:S,toggleKeyboard:()=>{O(!e.player().layers.keyboardVisible),e.player().layers.toggleKeyboard()},fullscreen:A,toggleFullscreen:()=>{e.player().layers.toggleFullscreen()},pause:P,setPause:t=>{var n;null===(n=e.player().ciPromise)||void 0===n||n.then((e=>{t?e.pause():e.resume(),B(t)})).catch(console.error)},mute:M,setMute:t=>{var n;null===(n=e.player().ciPromise)||void 0===n||n.then((e=>{t?e.mute():e.unmute(),T(t)})).catch(console.error)},actionBar:K,setActionBar:L,sideBar:_,openSideBar:()=>w(!0),closeSideBar:()=>w(!1),region:R,setRegion:function(e){e!==R&&(null!==e&&t.setItem(g,e),N(e),U(null))},estimatingRegion:F,setEstimatingRegion:U,showTips:z,setShowTips:e=>{t.setItem(v,e+""),H(e)},latencyInfo:W,setLatencyInfo:q,sideBarPage:V,setSideBarPage:G,ipxConnected:J,setIpxConnected:Q};return(0,l.html)(r||(r=i(['\n <div class="h-full">\n <'," ..."," />\n <"," ..."," />\n <"," ..."," />\n <"," ..."," />\n <"," ..."," />\n </div>\n "])),c.ActionHide,Z,f.SideBar,Z,u.ActionBar,Z,d.ActionSaveOrExit,Z,p.Tips,Z)}n.PlayerApp=b,n.createPlayerApp=function(e,t,n,r){(0,s.render)((0,l.html)(o||(o=i(["<"," player="," options="," setOnRun="," />"])),b,(()=>t),(()=>n),r),e)}},{"./components/action-bar":125,"./components/action-hide":126,"./components/action-save-or-exit":127,"./components/sidebar":131,"./components/tip":138,"./dom":139,"core-js/modules/web.dom-collections.iterator.js":115,"nanoid/non-secure":119,preact:120,"preact/hooks":121}],143:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.DosPlayer=void 0;const r=e("./dom"),o=e("./hardware-transport-layer"),i=e("./backend/v7/personal"),s=e("./player-app"),a=Dos;function l(e,t){if("none"===(t=t||{}).style)return console.warn("If you don't need the jsdos services, please use emulatros + emulators-ui instead"),a(e,t||{});e.classList.add("flex"),e.classList.add("flex-row"),e.classList.add("relative"),e.classList.add("overflow-hidden");const n=(0,r.createDiv)(["hidden","flex-col","absolute","left-0","top-0","bottom-0","right-0","items-center","justify-center","z-50","bg-gray-800","opacity-95"]),l=(0,r.createDiv)(["text-2xl","font-bold","font-mono","animate-pulse","text-green-600"]);n.appendChild(l);const c=(0,r.createDiv)(["flex","flex-col","flex-grow","overflow-hidden"]),u=(0,r.createDiv)("flex-grow"),d=(0,r.createDiv)("flex-grow-0"),f=(0,r.createDiv)("flex-grow-0");function p(e){l.innerHTML=e,n.classList.remove("hidden"),n.classList.add("flex")}c.appendChild(u),c.appendChild(f),e.appendChild(d),e.appendChild(c),e.appendChild(n),t.layersOptions=t.layersOptions||{},t.layersOptions.keyboardDiv=f,t.layersOptions.fullscreenElement=e,t.layersOptions.optionControls=[];const h=t.hardware;null!=h&&(t.createTransportLayer=()=>o.hardwareTransportLayerFactory.createTransportLayer(h),t.emulatorFunction="backend");const m=a(u,t);let y=()=>{};(0,s.createPlayerApp)(d,m,t,(e=>y=e)),m.bundleUrl=null;const g=m.run;m.run=async(e,r,o)=>{n.classList.remove("flex"),n.classList.add("hidden");const s=()=>{var e;return void 0!==(null===(e=t)||void 0===e?void 0:e.clientId)?t.clientId(!1):null},a=await s();void 0===r&&void 0===o&&null!==a&&(r=(0,i.getPersonalBundleUrl)(a.namespace,a.id,e)+"?dt="+Date.now());const c=await g.call(m,e,r,o);m.bundleUrl=e;const u=m.layers.getOnSave();return m.layers.setOnSave((async()=>{var n;const r="function"==typeof(null===(n=t)||void 0===n?void 0:n.onExit),o=r;r&&c.mute();const a=await s();if(null!==a){o&&p("Saving [1/2]: collecting changes");const t=await c.persist();o&&p("Saving [2/2]: sending to cloud"),await(0,i.putPersonalBundle)(a.namespace,a.id,e,t)}else o&&p("Saving [1/1]: collecting changes"),await u.call(m.layers);r&&o&&(p("Saved. Now you can close the window"),l.classList.remove("animate-pulse"))})),y(),c};const v=m.stop;return m.stop=()=>(m.bundleUrl=null,v.call(m)),m}n.DosPlayer=l,window.Dos=l},{"./backend/v7/personal":123,"./dom":139,"./hardware-transport-layer":140,"./player-app":142}],144:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.request=void 0,n.request=async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"GET",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;const r=await fetch(e,{method:t,body:n,headers:new Headers({"content-type":"application/json"})}).then((e=>e.json()));var o;if(200!==r.code)throw new Error(null!==(o=r.message)&&void 0!==o?o:"code: "+r.code);return r}},{}],145:[function(e,t,n){"use strict";function r(e,t,n,r,o,i){return new Promise(((s,a)=>{const l=new XMLHttpRequest;if(l.responseType=n,l.open(e,t,!0),l.addEventListener("load",(()=>{200!==l.status?a(new Error("Wrong status code "+l.status)):"text"===n?s(l.responseText):"arraybuffer"===n?s(l.response):a(new Error("Unsupported responseType "+n))}),!1),l.addEventListener("error",(()=>{a(new Error("HTTP GET failed for url "+t))}),!1),l.addEventListener("abort",(()=>{a(new Error("HTTP GET canceled for url "+t))}),!1),void 0!==o&&(l.onprogress=e=>{if(e.loaded&&e.total&&e.total>0){const t=Math.round(1e4*e.loaded/e.total)/100;o(t)}}),void 0!==i)for(const e of Object.keys(i))l.setRequestHeader(e,i[e]);l.send(r)}))}function o(e,t,n){return r("post",e,t,n)}e("core-js/modules/web.dom-collections.iterator.js"),Object.defineProperty(n,"__esModule",{value:!0}),n.post=n.getObject=n.postObject=n.send=void 0,n.send=r,n.postObject=async function(e,t){const n=JSON.parse(await o(e,"text",t));if(n.success)return n;if(void 0!==n.errorCode)throw new Error(n.errorCode);throw new Error("POST Object request failed:\n Payload:\n"+JSON.stringify(n.body,null,2))},n.getObject=async function(e){const t=JSON.parse(await r("get",e,"text"));if(t.success)return t;if(void 0!==t.errorCode)throw new Error(t.errorCode);throw new Error("GET Object request failed:\n Payload:\n"+JSON.stringify(t,null,2))},n.post=o},{"core-js/modules/web.dom-collections.iterator.js":115}],146:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.getPersonalBundleUrl=n.getPersonalBundleKey=n.uploadsS3Bucket=void 0,n.uploadsS3Bucket="doszone-uploads";function r(e,t,n){const r=n.lastIndexOf("/"),o=n.substr(r+1);return"doszone"===e?"personal/"+t+"/"+o:"personal-v2/"+e+"/"+t+"/"+o}n.getPersonalBundleKey=r,n.getPersonalBundleUrl=function(e,t,n){return"https://doszone-uploads.s3.dualstack.eu-central-1.amazonaws.com/"+r(e,t,n)}},{}]},{},[143]);
17
17
  //# sourceMappingURL=js-dos.js.map