From 1a2fae2dfc165e8d5842f027c4d4f044bd13d494 Mon Sep 17 00:00:00 2001 From: ThaUnknown Date: Thu, 24 Sep 2020 03:16:25 +0200 Subject: [PATCH] subtitle update, FAQ, minor changes --- app/{app.html => index.html} | 2 +- app/js/bundle.min.js | 2 +- app/js/subtitleHandler.js | 4 +- app/js/torrentHandler.js | 2 +- app/sw.js | 2 +- css.css | 71 ++++++++++++++++++++++++++++ faq.html | 92 ++++++++++++++++++++++++++++++++++++ index.html | 90 ++++++++++++++++++++--------------- manifest.json | 2 +- 9 files changed, 222 insertions(+), 45 deletions(-) rename app/{app.html => index.html} (99%) create mode 100644 css.css create mode 100644 faq.html diff --git a/app/app.html b/app/index.html similarity index 99% rename from app/app.html rename to app/index.html index 57641af..b8047fb 100644 --- a/app/app.html +++ b/app/index.html @@ -13,7 +13,7 @@ - Miru - Torrent streaming made simple! + Miru diff --git a/app/js/bundle.min.js b/app/js/bundle.min.js index 6047efa..a070ada 100644 --- a/app/js/bundle.min.js +++ b/app/js/bundle.min.js @@ -1 +1 @@ -!function(){var e=function(e){var t;return function(n){return t||e(t={exports:{},parent:n},t.exports),t.exports}},t=e((function(e,t){(function(t,i){"use strict";var s;e.exports=A,A.ReadableState=C,u.EventEmitter;var f,c=function(e,t){return e.listeners(t).length},h=l({}).Buffer,d=i.Uint8Array||function(){};f=O&&O.debuglog?O.debuglog("stream"):function(){};var p,m,g,y=fe.getHighWaterMark,v=oe.codes,b=v.ERR_INVALID_ARG_TYPE,w=v.ERR_STREAM_PUSH_AFTER_EOF,S=v.ERR_METHOD_NOT_IMPLEMENTED,k=v.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;ce(A,T);var _=ie.errorOrDestroy,E=["error","close","destroy","pause","resume"];function C(e,t,n){s=s||a({}),e=e||{},"boolean"!=typeof n&&(n=t instanceof s),this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=y(this,e,"readableHighWaterMark",n),this.buffer=new V,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(p||(p=o({}).StringDecoder),this.decoder=new p(e.encoding),this.encoding=e.encoding)}function A(e){if(s=s||a({}),!(this instanceof A))return new A(e);var t=this instanceof s;this._readableState=new C(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),T.call(this)}function R(e,t,n,r,i){f("readableAddChunk",t);var o,a=e._readableState;if(null===t)a.reading=!1,function(e,t){if(f("onEofChunk"),!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,t.sync?x(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,D(e)))}}(e,a);else if(i||(o=function(e,t){var n,r;return r=t,h.isBuffer(r)||r instanceof d||"string"==typeof t||void 0===t||e.objectMode||(n=new b("chunk",["string","Buffer","Uint8Array"],t)),n}(a,t)),o)_(e,o);else if(a.objectMode||t&&t.length>0)if("string"==typeof t||a.objectMode||Object.getPrototypeOf(t)===h.prototype||(t=function(e){return h.from(e)}(t)),r)a.endEmitted?_(e,new k):L(e,a,t,!0);else if(a.ended)_(e,new w);else{if(a.destroyed)return!1;a.reading=!1,a.decoder&&!n?(t=a.decoder.write(t),a.objectMode||0!==t.length?L(e,a,t,!1):I(e,a)):L(e,a,t,!1)}else r||(a.reading=!1,I(e,a));return!a.ended&&(a.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=1073741824?e=1073741824:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function x(e){var n=e._readableState;f("emitReadable",n.needReadable,n.emittedReadable),n.needReadable=!1,n.emittedReadable||(f("emitReadable",n.flowing),n.emittedReadable=!0,t.nextTick(D,e))}function D(e){var t=e._readableState;f("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,j(e)}function I(e,n){n.readingMore||(n.readingMore=!0,t.nextTick(B,e,n))}function B(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function U(e){f("readable nexttick read 0"),e.read(0)}function F(e,t){f("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),j(e),t.flowing&&!t.reading&&e.read(0)}function j(e){var t=e._readableState;for(f("flow",t.flowing);t.flowing&&null!==e.read(););}function N(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):n=t.buffer.consume(e,t.decoder),n);var n}function q(e){var n=e._readableState;f("endReadable",n.endEmitted),n.endEmitted||(n.ended=!0,t.nextTick(z,n,e))}function z(e,t){if(f("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var n=t._writableState;(!n||n.autoDestroy&&n.finished)&&t.destroy()}}function W(e,t){for(var n=0,r=e.length;n=t.highWaterMark:t.length>0)||t.ended))return f("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?q(this):x(this),null;if(0===(e=M(e,t))&&t.ended)return 0===t.length&&q(this),null;var r,i=t.needReadable;return f("need readable",i),(0===t.length||t.length-e0?N(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&q(this)),null!==r&&this.emit("data",r),r},A.prototype._read=function(e){_(this,new S("_read()"))},A.prototype.pipe=function(e,n){var r=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=e;break;case 1:i.pipes=[i.pipes,e];break;default:i.pipes.push(e)}i.pipesCount+=1,f("pipe count=%d opts=%j",i.pipesCount,n);var o=n&&!1===n.end||e===t.stdout||e===t.stderr?m:a;function a(){f("onend"),e.end()}i.endEmitted?t.nextTick(o):r.once("end",o),e.on("unpipe",(function t(n,o){f("onunpipe"),n===r&&o&&!1===o.hasUnpiped&&(o.hasUnpiped=!0,f("cleanup"),e.removeListener("close",d),e.removeListener("finish",p),e.removeListener("drain",s),e.removeListener("error",h),e.removeListener("unpipe",t),r.removeListener("end",a),r.removeListener("end",m),r.removeListener("data",u),l=!0,!i.awaitDrain||e._writableState&&!e._writableState.needDrain||s())}));var s=function(e){return function(){var t=e._readableState;f("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&c(e,"data")&&(t.flowing=!0,j(e))}}(r);e.on("drain",s);var l=!1;function u(t){f("ondata");var n=e.write(t);f("dest.write",n),!1===n&&((1===i.pipesCount&&i.pipes===e||i.pipesCount>1&&-1!==W(i.pipes,e))&&!l&&(f("false write response, pause",i.awaitDrain),i.awaitDrain++),r.pause())}function h(t){f("onerror",t),m(),e.removeListener("error",h),0===c(e,"error")&&_(e,t)}function d(){e.removeListener("finish",p),m()}function p(){f("onfinish"),e.removeListener("close",d),m()}function m(){f("unpipe"),r.unpipe(e)}return r.on("data",u),function(e,t,n){if("function"==typeof e.prependListener)return e.prependListener("error",n);e._events&&e._events.error?Array.isArray(e._events.error)?e._events.error.unshift(n):e._events.error=[n,e._events.error]:e.on("error",n)}(e,0,h),e.once("close",d),e.once("finish",p),e.emit("pipe",r),i.flowing||(f("pipe resume"),r.resume()),e},A.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n)),this;if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o0,!1!==i.flowing&&this.resume()):"readable"===e&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,f("on readable",i.length,i.reading),i.length?x(this):i.reading||t.nextTick(U,this))),r},A.prototype.addListener=A.prototype.on,A.prototype.removeListener=function(e,n){var r=T.prototype.removeListener.call(this,e,n);return"readable"===e&&t.nextTick(P,this),r},A.prototype.removeAllListeners=function(e){var n=T.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||t.nextTick(P,this),n},A.prototype.resume=function(){var e=this._readableState;return e.flowing||(f("resume"),e.flowing=!e.readableListening,function(e,n){n.resumeScheduled||(n.resumeScheduled=!0,t.nextTick(F,e,n))}(this,e)),e.paused=!1,this},A.prototype.pause=function(){return f("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(f("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},A.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",(function(){if(f("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(i){f("wrapped data"),n.decoder&&(i=n.decoder.write(i)),n.objectMode&&null==i||(n.objectMode||i&&i.length)&&(t.push(i)||(r=!0,e.pause()))})),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function a(e){var t=this.lastTotal-this.lastNeed,n=function(e,t,n){if(128!=(192&t[0]))return e.lastNeed=0,"\ufffd";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"\ufffd";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"\ufffd"}}(this,e);return void 0!==n?n:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function s(e,t){if((e.length-t)%2==0){var n=e.toString("utf16le",t);if(n){var r=n.charCodeAt(n.length-1);if(r>=55296&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],n.slice(0,-1)}return n}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function l(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var n=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,n)}return t}function u(e,t){var n=(e.length-t)%3;return 0===n?e.toString("base64",t):(this.lastNeed=3-n,this.lastTotal=3,1===n?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-n))}function f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function c(e){return e.toString(this.encoding)}function h(e){return e&&e.length?this.write(e):""}t.StringDecoder=i,i.prototype.write=function(e){if(0===e.length)return"";var t,n;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";n=this.lastNeed,this.lastNeed=0}else n=0;return n=0?(i>0&&(e.lastNeed=i-1),i):--r=0?(i>0&&(e.lastNeed=i-2),i):--r=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=n;var r=e.length-(n-this.lastNeed);return e.copy(this.lastChar,0,r),e.toString("utf8",t,r)},i.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}})),a=e((function(e,n){(function(n){"use strict";var r=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=f;var i=t({}),o=s({});ce(f,i);for(var a=r(o.prototype),l=0;l-1))throw new w(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(E.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(E.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),E.prototype._write=function(e,t,n){n(new p("_write()"))},E.prototype._writev=null,E.prototype.end=function(e,n,r){var i=this._writableState;return"function"==typeof e?(r=e,e=null,n=null):"function"==typeof n&&(r=n,n=null),null!=e&&this.write(e,n),i.corked&&(i.corked=1,this.uncork()),i.ending||function(e,n,r){n.ending=!0,x(e,n),r&&(n.finished?t.nextTick(r):e.once("finish",r)),n.ended=!0,e.writable=!1}(this,i,r),this},Object.defineProperty(E.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(E.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),E.prototype.destroy=ie.destroy,E.prototype._undestroy=ie.undestroy,E.prototype._destroy=function(e,t){t(e)}}).call(this,H,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})})),l=e((function(e,t){(function(e){"use strict";t.Buffer=e,t.SlowBuffer=function(t){return+t!=t&&(t=0),e.alloc(+t)},t.INSPECT_MAX_BYTES=50;function n(t){if(t>2147483647)throw new RangeError('The value "'+t+'" is invalid for option "size"');var n=new Uint8Array(t);return n.__proto__=e.prototype,n}function e(e,t,n){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return o(e)}return r(e,t,n)}function r(t,r,i){if("string"==typeof t)return function(t,r){if("string"==typeof r&&""!==r||(r="utf8"),!e.isEncoding(r))throw new TypeError("Unknown encoding: "+r);var i=0|l(t,r),o=n(i),a=o.write(t,r);return a!==i&&(o=o.slice(0,a)),o}(t,r);if(ArrayBuffer.isView(t))return a(t);if(null==t)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if(P(t,ArrayBuffer)||t&&P(t.buffer,ArrayBuffer))return function(t,n,r){if(n<0||t.byteLength=2147483647)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+2147483647..toString(16)+" bytes");return 0|e}function l(t,n){if(e.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||P(t,ArrayBuffer))return t.byteLength;if("string"!=typeof t)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);var r=t.length,i=arguments.length>2&&!0===arguments[2];if(!i&&0===r)return 0;for(var o=!1;;)switch(n){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return D(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return I(t).length;default:if(o)return i?-1:D(t).length;n=(""+n).toLowerCase(),o=!0}}function u(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function f(t,n,r,i,o){if(0===t.length)return-1;if("string"==typeof r?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),U(r=+r)&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(o)return-1;r=t.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof n&&(n=e.from(n,i)),e.isBuffer(n))return 0===n.length?-1:c(t,n,r,i,o);if("number"==typeof n)return n&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(t,n,r):Uint8Array.prototype.lastIndexOf.call(t,n,r):c(t,[n],r,i,o);throw new TypeError("val must be string, number or Buffer")}function c(e,t,n,r,i){var o,a=1,s=e.length,l=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,l/=2,n/=2}function u(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var f=-1;for(o=n;os&&(n=s-l),o=n;o>=0;o--){for(var c=!0,h=0;hi&&(r=i):r=i;var o=t.length;r>o/2&&(r=o/2);for(var a=0;a>8,i=n%256,o.push(i),o.push(r);return o}(t,e.length-n),e,n,r)}function v(e,t,n){return 0===t&&n===e.length?E.fromByteArray(e):E.fromByteArray(e.slice(t,n))}function b(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i239?4:u>223?3:u>191?2:1;if(i+c<=n)switch(c){case 1:u<128&&(f=u);break;case 2:128==(192&(o=e[i+1]))&&(l=(31&u)<<6|63&o)>127&&(f=l);break;case 3:o=e[i+1],a=e[i+2],128==(192&o)&&128==(192&a)&&(l=(15&u)<<12|(63&o)<<6|63&a)>2047&&(l<55296||l>57343)&&(f=l);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(l=(15&u)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&l<1114112&&(f=l)}null===f?(f=65533,c=1):f>65535&&(f-=65536,r.push(f>>>10&1023|55296),f=56320|1023&f),r.push(f),i+=c}return function(e){var t=e.length;if(t<=w)return String.fromCharCode.apply(String,e);for(var n="",r=0;rthis.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return _(this,t,n);case"utf8":case"utf-8":return b(this,t,n);case"ascii":return S(this,t,n);case"latin1":case"binary":return k(this,t,n);case"base64":return v(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}.apply(this,arguments)},e.prototype.toLocaleString=e.prototype.toString,e.prototype.equals=function(t){if(!e.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t||0===e.compare(this,t)},e.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return e=this.toString("hex",0,n).replace(/(.{2})/g,"$1 ").trim(),this.length>n&&(e+=" ... "),""},e.prototype.compare=function(t,n,r,i,o){if(P(t,Uint8Array)&&(t=e.from(t,t.offset,t.byteLength)),!e.isBuffer(t))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof t);if(void 0===n&&(n=0),void 0===r&&(r=t?t.length:0),void 0===i&&(i=0),void 0===o&&(o=this.length),n<0||r>t.length||i<0||o>this.length)throw new RangeError("out of range index");if(i>=o&&n>=r)return 0;if(i>=o)return-1;if(n>=r)return 1;if(this===t)return 0;for(var a=(o>>>=0)-(i>>>=0),s=(r>>>=0)-(n>>>=0),l=Math.min(a,s),u=this.slice(i,o),f=t.slice(n,r),c=0;c>>=0,isFinite(n)?(n>>>=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var i=this.length-t;if((void 0===n||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return h(this,e,t,n);case"utf8":case"utf-8":return d(this,e,t,n);case"ascii":return p(this,e,t,n);case"latin1":case"binary":return m(this,e,t,n);case"base64":return g(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return y(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},e.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var w=4096;function S(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;ii)&&(n=i);for(var o="",a=t;an)throw new RangeError("Trying to access beyond buffer length")}function A(t,n,r,i,o,a){if(!e.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(n>o||nt.length)throw new RangeError("Index out of range")}function R(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function L(e,t,n,r,i){return t=+t,n>>>=0,i||R(e,0,n,4),B.write(e,t,n,r,23,4),n+4}function M(e,t,n,r,i){return t=+t,n>>>=0,i||R(e,0,n,8),B.write(e,t,n,r,52,8),n+8}e.prototype.slice=function(t,n){var r=this.length;(t=~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),(n=void 0===n?r:~~n)<0?(n+=r)<0&&(n=0):n>r&&(n=r),n>>=0,t>>>=0,n||C(e,t,this.length);for(var r=this[e],i=1,o=0;++o>>=0,t>>>=0,n||C(e,t,this.length);for(var r=this[e+--t],i=1;t>0&&(i*=256);)r+=this[e+--t]*i;return r},e.prototype.readUInt8=function(e,t){return e>>>=0,t||C(e,1,this.length),this[e]},e.prototype.readUInt16LE=function(e,t){return e>>>=0,t||C(e,2,this.length),this[e]|this[e+1]<<8},e.prototype.readUInt16BE=function(e,t){return e>>>=0,t||C(e,2,this.length),this[e]<<8|this[e+1]},e.prototype.readUInt32LE=function(e,t){return e>>>=0,t||C(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},e.prototype.readUInt32BE=function(e,t){return e>>>=0,t||C(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},e.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||C(e,t,this.length);for(var r=this[e],i=1,o=0;++o=(i*=128)&&(r-=Math.pow(2,8*t)),r},e.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||C(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},e.prototype.readInt8=function(e,t){return e>>>=0,t||C(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},e.prototype.readInt16LE=function(e,t){e>>>=0,t||C(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},e.prototype.readInt16BE=function(e,t){e>>>=0,t||C(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},e.prototype.readInt32LE=function(e,t){return e>>>=0,t||C(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},e.prototype.readInt32BE=function(e,t){return e>>>=0,t||C(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},e.prototype.readFloatLE=function(e,t){return e>>>=0,t||C(e,4,this.length),B.read(this,e,!0,23,4)},e.prototype.readFloatBE=function(e,t){return e>>>=0,t||C(e,4,this.length),B.read(this,e,!1,23,4)},e.prototype.readDoubleLE=function(e,t){return e>>>=0,t||C(e,8,this.length),B.read(this,e,!0,52,8)},e.prototype.readDoubleBE=function(e,t){return e>>>=0,t||C(e,8,this.length),B.read(this,e,!1,52,8)},e.prototype.writeUIntLE=function(e,t,n,r){e=+e,t>>>=0,n>>>=0,r||A(this,e,t,n,Math.pow(2,8*n)-1,0);var i=1,o=0;for(this[t]=255&e;++o>>=0,n>>>=0,r||A(this,e,t,n,Math.pow(2,8*n)-1,0);var i=n-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+n},e.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,1,255,0),this[t]=255&e,t+1},e.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},e.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},e.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},e.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},e.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=Math.pow(2,8*n-1);A(this,e,t,n,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o>0)-s&255;return t+n},e.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=Math.pow(2,8*n-1);A(this,e,t,n,i-1,-i)}var o=n-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},e.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},e.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},e.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},e.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},e.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},e.prototype.writeFloatLE=function(e,t,n){return L(this,e,t,!0,n)},e.prototype.writeFloatBE=function(e,t,n){return L(this,e,t,!1,n)},e.prototype.writeDoubleLE=function(e,t,n){return M(this,e,t,!0,n)},e.prototype.writeDoubleBE=function(e,t,n){return M(this,e,t,!1,n)},e.prototype.copy=function(t,n,r,i){if(!e.isBuffer(t))throw new TypeError("argument should be a Buffer");if(r||(r=0),i||0===i||(i=this.length),n>=t.length&&(n=t.length),n||(n=0),i>0&&i=this.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),t.length-n=0;--a)t[a+n]=this[a+r];else Uint8Array.prototype.set.call(t,this.subarray(r,i),n);return o},e.prototype.fill=function(t,n,r,i){if("string"==typeof t){if("string"==typeof n?(i=n,n=0,r=this.length):"string"==typeof r&&(i=r,r=this.length),void 0!==i&&"string"!=typeof i)throw new TypeError("encoding must be a string");if("string"==typeof i&&!e.isEncoding(i))throw new TypeError("Unknown encoding: "+i);if(1===t.length){var o=t.charCodeAt(0);("utf8"===i&&o<128||"latin1"===i)&&(t=o)}}else"number"==typeof t&&(t&=255);if(n<0||this.length>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(a=n;a55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function I(e){return E.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(x,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function O(e,t,n,r){for(var i=0;i=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function P(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function U(e){return e!=e}}).call(this,l({}).Buffer)})),u={},f=Object.create||function(e){var t=function(){};return t.prototype=e,new t},c=Object.keys||function(e){var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return n},h=Function.prototype.bind||function(e){var t=this;return function(){return t.apply(e,arguments)}};function d(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=f(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0}u=d,d.EventEmitter=d,d.prototype._events=void 0,d.prototype._maxListeners=void 0;var p,m=10;try{var g={};Object.defineProperty&&Object.defineProperty(g,"x",{value:0}),p=0===g.x}catch(lt){p=!1}function y(e){return void 0===e._maxListeners?d.defaultMaxListeners:e._maxListeners}function v(e,t,n,r){var i,o,a;if("function"!=typeof n)throw new TypeError('"listener" argument must be a function');if((o=e._events)?(o.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),o=e._events),a=o[t]):(o=e._events=f(null),e._eventsCount=0),a){if("function"==typeof a?a=o[t]=r?[n,a]:[a,n]:r?a.unshift(n):a.push(n),!a.warned&&(i=y(e))&&i>0&&a.length>i){a.warned=!0;var s=new Error("Possible EventEmitter memory leak detected. "+a.length+' "'+String(t)+'" listeners added. Use emitter.setMaxListeners() to increase limit.');s.name="MaxListenersExceededWarning",s.emitter=e,s.type=t,s.count=a.length,"object"==typeof console&&console.warn&&console.warn("%s: %s",s.name,s.message)}}else a=o[t]=n,++e._eventsCount;return e}function b(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var e=new Array(arguments.length),t=0;t1&&(t=arguments[1]),t instanceof Error)throw t;var l=new Error('Unhandled "error" event. ('+t+")");throw l.context=t,l}if(!(n=a[e]))return!1;var u="function"==typeof n;switch(r=arguments.length){case 1:!function(e,t,n){if(t)e.call(n);else for(var r=e.length,i=_(e,r),o=0;o=0;o--)if(n[o]===t||n[o].listener===t){a=n[o].listener,i=o;break}if(i<0)return this;0===i?n.shift():function(e,t){for(var n=t,r=n+1,i=e.length;r=0;r--)this.removeListener(e,t[r]);return this},d.prototype.listeners=function(e){return S(this,e,!0)},d.prototype.rawListeners=function(e){return S(this,e,!1)},d.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):k.call(e,t)},d.prototype.listenerCount=k,d.prototype.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]};for(var T=u.EventEmitter,E={toByteArray:function(e){var t,n,r=D(e),i=r[0],o=r[1],a=new R(function(e,t,n){return 3*(t+n)/4-n}(0,i,o)),s=0,l=o>0?i-4:i;for(n=0;n>16&255,a[s++]=t>>8&255,a[s++]=255&t;return 2===o&&(t=A[e.charCodeAt(n)]<<2|A[e.charCodeAt(n+1)]>>4,a[s++]=255&t),1===o&&(t=A[e.charCodeAt(n)]<<10|A[e.charCodeAt(n+1)]<<4|A[e.charCodeAt(n+2)]>>2,a[s++]=t>>8&255,a[s++]=255&t),a},fromByteArray:function(e){for(var t,n=e.length,r=n%3,i=[],o=0,a=n-r;oa?a:o+16383));return 1===r?(t=e[n-1],i.push(C[t>>2]+C[t<<4&63]+"==")):2===r&&(t=(e[n-2]<<8)+e[n-1],i.push(C[t>>10]+C[t>>4&63]+C[t<<2&63]+"=")),i.join("")}},C=[],A=[],R="undefined"!=typeof Uint8Array?Uint8Array:Array,L="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",M=0,x=L.length;M0)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 I(e,t,n){for(var r,i,o=[],a=t;a>18&63]+C[i>>12&63]+C[i>>6&63]+C[63&i]);return o.join("")}A["-".charCodeAt(0)]=62,A["_".charCodeAt(0)]=63;var B={read:function(e,t,n,r,i){var o,a,s=8*i-r-1,l=(1<>1,f=-7,c=n?i-1:0,h=n?-1:1,d=e[t+c];for(c+=h,o=d&(1<<-f)-1,d>>=-f,f+=s;f>0;o=256*o+e[t+c],c+=h,f-=8);for(a=o&(1<<-f)-1,o>>=-f,f+=r;f>0;a=256*a+e[t+c],c+=h,f-=8);if(0===o)o=1-u;else{if(o===l)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,r),o-=u}return(d?-1:1)*a*Math.pow(2,o-r)},write:function(e,t,n,r,i,o){var a,s,l,u=8*o-i-1,f=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?0:o-1,p=r?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=f):(a=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-a))<1&&(a--,l*=2),(t+=a+c>=1?h/l:h*Math.pow(2,1-c))*l>=2&&(a++,l/=2),a+c>=f?(s=0,a=f):a+c>=1?(s=(t*l-1)*Math.pow(2,i),a+=c):(s=t*Math.pow(2,c-1)*Math.pow(2,i),a=0));i>=8;e[n+d]=255&s,d+=p,s/=256,i-=8);for(a=a<0;e[n+d]=255&a,d+=p,a/=256,u-=8);e[n+d-p]|=128*m}},O={};function P(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 U(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function F(e,t){for(var n=0;n0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,n=""+t.data;t=t.next;)n+=e+t.data;return n}},{key:"concat",value:function(e){if(0===this.length)return q.alloc(0);for(var t,n,r,i=q.allocUnsafe(e>>>0),o=this.head,a=0;o;)t=o.data,n=i,r=a,q.prototype.copy.call(t,n,r),a+=o.data.length,o=o.next;return i}},{key:"consume",value:function(e,t){var n;return ei.length?i.length:e;if(o===i.length?r+=i:r+=i.slice(0,e),0==(e-=o)){o===i.length?(++n,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(o));break}++n}return this.length-=n,r}},{key:"_getBuffer",value:function(e){var t=q.allocUnsafe(e),n=this.head,r=1;for(n.data.copy(t),e-=n.data.length;n=n.next;){var i=n.data,o=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,o),0==(e-=o)){o===i.length?(++r,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=i.slice(o));break}++r}return this.length-=r,t}},{key:W,value:function(e,t){return z(this,function(e){for(var t=1;t1)for(var n=1;n2?"one of ".concat(t," ").concat(e.slice(0,n-1).join(", "),", or ")+e[n-1]:2===n?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}se("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),se("ERR_INVALID_ARG_TYPE",(function(e,t,n){var r,i,o,a;if("string"==typeof t&&("not ","not "===t.substr(0,"not ".length))?(r="must not be",t=t.replace(/^not /,"")):r="must be",o=e,(void 0===a||a>o.length)&&(a=o.length)," argument"===o.substring(a-" argument".length,a))i="The ".concat(e," ").concat(r," ").concat(le(t,"type"));else{var s=function(e,t,n){return"number"!=typeof n&&(n=0),!(n+".".length>e.length)&&-1!==e.indexOf(".",n)}(e)?"property":"argument";i='The "'.concat(e,'" ').concat(s," ").concat(r," ").concat(le(t,"type"))}return i+". Received type ".concat(typeof n)}),TypeError),se("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),se("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),se("ERR_STREAM_PREMATURE_CLOSE","Premature close"),se("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),se("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),se("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),se("ERR_STREAM_WRITE_AFTER_END","write after end"),se("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),se("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),se("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),oe.codes=ae;var ue=oe.codes.ERR_INVALID_OPT_VALUE,fe={getHighWaterMark:function(e,t,n,r){var i=function(e,t,n){return null!=e.highWaterMark?e.highWaterMark:t?e[n]:null}(t,r,n);if(null!=i){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new ue(r?n:"highWaterMark",i);return Math.floor(i)}return e.objectMode?16:16384}},ce={};ce="function"==typeof Object.create?function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:function(e,t){if(t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}};var he={};(function(e){function t(t){try{if(!e.localStorage)return!1}catch(r){return!1}var n=e.localStorage[t];return null!=n&&"true"===String(n).toLowerCase()}he=function(e,n){if(t("noDeprecation"))return e;var r=!1;return function(){if(!r){if(t("throwDeprecation"))throw new Error(n);t("traceDeprecation")?console.trace(n):console.warn(n),r=!0}return e.apply(this,arguments)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{});var de={},pe=l({}),me=pe.Buffer;function ge(e,t){for(var n in e)t[n]=e[n]}function ye(e,t,n){return me(e,t,n)}me.from&&me.alloc&&me.allocUnsafe&&me.allocUnsafeSlow?de=pe:(ge(pe,de),de.Buffer=ye),ye.prototype=Object.create(me.prototype),ge(me,ye),ye.from=function(e,t,n){if("number"==typeof e)throw new TypeError("Argument must not be a number");return me(e,t,n)},ye.alloc=function(e,t,n){if("number"!=typeof e)throw new TypeError("Argument must be a number");var r=me(e);return void 0!==t?"string"==typeof n?r.fill(t,n):r.fill(t):r.fill(0),r},ye.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return me(e)},ye.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return pe.SlowBuffer(e)};var ve=Ce,be=oe.codes,we=be.ERR_METHOD_NOT_IMPLEMENTED,Se=be.ERR_MULTIPLE_CALLBACK,ke=be.ERR_TRANSFORM_ALREADY_TRANSFORMING,_e=be.ERR_TRANSFORM_WITH_LENGTH_0,Te=a({});function Ee(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(null===r)return this.emit("error",new Se);n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length0,(function(e){r||(r=e),e&&a.forEach(Pe),s||(a.forEach(Pe),o(r))}))}));return t.reduce(Ue)};var je=function(e,t,n){t=t||0;for(var r=1;r<=8&&!(e[t]>=Math.pow(2,8-r));r++);if(r>8)throw new Error("Unrepresentable length: "+r+" "+e.toString("hex",t,t+r));if(t+r>e.length)return null;var i,o=e[t]&(1<<8-r)-1;for(i=1;i=Math.pow(2,45)&&e[t+7]>0)return{length:r,value:-1};o*=Math.pow(2,8),o+=e[t+i]}return n&&(o-=Math.pow(2,7*r-1)-1),{length:r,value:o}},Ne={};function qe(e){this.buffer=e,this.offset=0}qe.prototype.nextInt16BE=function(){var e=this.buffer.readInt16BE(this.offset);return this.offset+=2,e},qe.prototype.nextUInt8=function(){var e=this.buffer.readUInt8(this.offset);return this.offset+=1,e},qe.prototype.nextUIntV=function(){var e=je(this.buffer,this.offset);return this.offset+=e.length,e.value},qe.prototype.nextIntV=function(){var e=je(this.buffer,this.offset,!0);return this.offset+=e.length,e.value},qe.prototype.nextBuffer=function(e){var t=e?this.buffer.slice(this.offset,this.offset+e):this.buffer.slice(this.offset);return this.offset+=e||this.length,t},Object.defineProperty(qe.prototype,"length",{get:function(){return this.buffer.length-this.offset}}),Ne=qe;const ze=Date.UTC(2001,0);var We=function(e){switch(e.type){case"s":return e.data.toString("ascii");case"8":return e.data.toString("utf8");case"u":return e.data.readUIntBE(0,e.dataSize);case"i":return e.data.readIntBE(0,e.dataSize);case"f":return 4===e.dataSize?e.data.readFloatBE():e.data.readDoubleBE();case"d":return new Date(ze+e.data.readIntBE(0,8)/1e6);case"b":case"m":default:return e.data}};const{Transform:Ve}=Fe,He=["TrackNumber","TrackType","Language","CodecID","CodecPrivate"],Ye=["S_TEXT/UTF8","S_TEXT/SSA","S_TEXT/ASS"],Ge=["readOrder","layer","style","name","marginL","marginR","marginV","effect","text"];var Xe=class extends Ve{constructor(){super();let e=null,t=null,n=null;this.subtitleTracks=new Map,this.timecodeScale=1,this._parseEbmlSubtitles=r=>{if("TimecodeScale"===r[1].name&&(this.timecodeScale=We(r[1])/1e6),"start"===r[0]&&"TrackEntry"===r[1].name&&(e={}),e&&"tag"===r[0]&&He.includes(r[1].name)&&(e[r[1].name]=We(r[1])),"end"===r[0]&&"TrackEntry"===r[1].name){if(17===e.TrackType&&Ye.includes(e.CodecID)){const t={number:e.TrackNumber,language:e.Language,type:e.CodecID.substring(7).toLowerCase()};e.CodecPrivate&&(t.header=e.CodecPrivate.toString("utf8")),this.subtitleTracks.set(e.TrackNumber,t)}e=null}if("end"===r[0]&&"Tracks"===r[1].name&&this.emit("tracks",Array.from(this.subtitleTracks.values())),"Timecode"===r[1].name&&(n=We(r[1])),"Block"===r[1].name){const e=function(e){var t={},n=new Ne(e);t.trackNumber=n.nextUIntV(),t.timecode=n.nextInt16BE();var r=n.nextUInt8();t.invisible=!!(8&r),t.keyframe=!!(128&r),t.discardable=!!(1&r);var i=(6&r)>>1;return t.frames=function(e,t){if(!t)return[e.nextBuffer()];var n,r,i=[],o=e.nextUInt8()+1;if(2===t){if(e.length%o!=0)throw new Error("Fixed-Size Lacing Error");for(r=e.length/o,n=0;n0)return function(e){if(!((e=String(e)).length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var n=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*n;case"days":case"day":case"d":return n*Ze;case"hours":case"hour":case"hrs":case"hr":case"h":return n*$e;case"minutes":case"minute":case"mins":case"min":case"m":return n*Je;case"seconds":case"second":case"secs":case"sec":case"s":return n*Ke;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return n;default:return}}}}(e);if("number"===r&&!1===isNaN(e))return t.long?Qe(n=e,Ze,"day")||Qe(n,$e,"hour")||Qe(n,Je,"minute")||Qe(n,Ke,"second")||n+" ms":function(e){return e>=Ze?Math.round(e/Ze)+"d":e>=$e?Math.round(e/$e)+"h":e>=Je?Math.round(e/Je)+"m":e>=Ke?Math.round(e/Ke)+"s":e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))},et.instances=[],et.names=[],et.skips=[],et.formatters={};var rt={};(function(e){function t(){var t;try{t=rt.storage.debug}catch(n){}return!t&&void 0!==e&&"env"in e&&(t=e.env.DEBUG),t}(rt=rt=et).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},rt.formatArgs=function(e){var t=this.useColors;if(e[0]=(t?"%c":"")+this.namespace+(t?" %c":" ")+e[0]+(t?"%c ":" ")+"+"+rt.humanize(this.diff),t){var n="color: "+this.color;e.splice(1,0,n,"color: inherit");var r=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(r++,"%c"===e&&(i=r))})),e.splice(i,0,n)}},rt.save=function(e){try{null==e?rt.storage.removeItem("debug"):rt.storage.debug=e}catch(t){}},rt.load=t,rt.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},rt.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),rt.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],rt.formatters.j=function(e){try{return JSON.stringify(e)}catch(lt){return"[UnexpectedJSONParseError]: "+lt.message}},rt.enable(t())}).call(this,H);var it={};(function(e,t){"use strict";Object.defineProperty(it,"__esModule",{value:!0});var n=void 0!==e?e:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},r=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,a=!1;function s(){a=!0;for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t=0,n=e.length;t>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return a.join("")}function u(e){var t;a||s();for(var n=e.length,i=n%3,o="",u=[],f=0,c=n-i;fc?c:f+16383));return 1===i?(t=e[n-1],o+=r[t>>2],o+=r[t<<4&63],o+="=="):2===i&&(t=(e[n-2]<<8)+e[n-1],o+=r[t>>10],o+=r[t>>4&63],o+=r[t<<2&63],o+="="),u.push(o),u.join("")}function f(e,t,n,r,i){var o,a,s=8*i-r-1,l=(1<>1,f=-7,c=n?i-1:0,h=n?-1:1,d=e[t+c];for(c+=h,o=d&(1<<-f)-1,d>>=-f,f+=s;f>0;o=256*o+e[t+c],c+=h,f-=8);for(a=o&(1<<-f)-1,o>>=-f,f+=r;f>0;a=256*a+e[t+c],c+=h,f-=8);if(0===o)o=1-u;else{if(o===l)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,r),o-=u}return(d?-1:1)*a*Math.pow(2,o-r)}function c(e,t,n,r,i,o){var a,s,l,u=8*o-i-1,f=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?0:o-1,p=r?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=f):(a=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-a))<1&&(a--,l*=2),(t+=a+c>=1?h/l:h*Math.pow(2,1-c))*l>=2&&(a++,l/=2),a+c>=f?(s=0,a=f):a+c>=1?(s=(t*l-1)*Math.pow(2,i),a+=c):(s=t*Math.pow(2,c-1)*Math.pow(2,i),a=0));i>=8;e[n+d]=255&s,d+=p,s/=256,i-=8);for(a=a<0;e[n+d]=255&a,d+=p,a/=256,u-=8);e[n+d-p]|=128*m}var h={}.toString,d=Array.isArray||function(e){return"[object Array]"==h.call(e)};function p(){return t.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function m(e,n){if(p()=p())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+p().toString(16)+" bytes");return 0|e}function S(e){return!(null==e||!e._isBuffer)}function k(e,t){if(S(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return G(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return X(e).length;default:if(r)return G(e).length;t=(""+t).toLowerCase(),r=!0}}function _(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function T(e,n,r,i,o){if(0===e.length)return-1;if("string"==typeof r?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=o?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(o)return-1;r=e.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof n&&(n=t.from(n,i)),S(n))return 0===n.length?-1:E(e,n,r,i,o);if("number"==typeof n)return n&=255,t.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,n,r):Uint8Array.prototype.lastIndexOf.call(e,n,r):E(e,[n],r,i,o);throw new TypeError("val must be string, number or Buffer")}function E(e,t,n,r,i){var o,a=1,s=e.length,l=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,l/=2,n/=2}function u(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var f=-1;for(o=n;os&&(n=s-l),o=n;o>=0;o--){for(var c=!0,h=0;hi&&(r=i):r=i;var o=t.length;if(o%2!=0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var a=0;a>8,i=n%256,o.push(i),o.push(r);return o}(t,e.length-n),e,n,r)}function D(e,t,n){return 0===t&&n===e.length?u(e):u(e.slice(t,n))}function I(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i239?4:u>223?3:u>191?2:1;if(i+c<=n)switch(c){case 1:u<128&&(f=u);break;case 2:128==(192&(o=e[i+1]))&&(l=(31&u)<<6|63&o)>127&&(f=l);break;case 3:o=e[i+1],a=e[i+2],128==(192&o)&&128==(192&a)&&(l=(15&u)<<12|(63&o)<<6|63&a)>2047&&(l<55296||l>57343)&&(f=l);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(l=(15&u)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&l<1114112&&(f=l)}null===f?(f=65533,c=1):f>65535&&(f-=65536,r.push(f>>>10&1023|55296),f=56320|1023&f),r.push(f),i+=c}return function(e){var t=e.length;if(t<=B)return String.fromCharCode.apply(String,e);for(var n="",r=0;rthis.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return U(this,t,n);case"utf8":case"utf-8":return I(this,t,n);case"ascii":return O(this,t,n);case"latin1":case"binary":return P(this,t,n);case"base64":return D(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return F(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}.apply(this,arguments)},t.prototype.equals=function(e){if(!S(e))throw new TypeError("Argument must be a Buffer");return this===e||0===t.compare(this,e)},t.prototype.inspect=function(){var e="";return this.length>0&&(e=this.toString("hex",0,50).match(/.{2}/g).join(" "),this.length>50&&(e+=" ... ")),""},t.prototype.compare=function(e,t,n,r,i){if(!S(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(r>>>=0),a=(n>>>=0)-(t>>>=0),s=Math.min(o,a),l=this.slice(r,i),u=e.slice(t,n),f=0;fi)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return C(this,e,t,n);case"utf8":case"utf-8":return A(this,e,t,n);case"ascii":return R(this,e,t,n);case"latin1":case"binary":return L(this,e,t,n);case"base64":return M(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return x(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},t.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var B=4096;function O(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;ii)&&(n=i);for(var o="",a=t;an)throw new RangeError("Trying to access beyond buffer length")}function N(e,t,n,r,i,o){if(!S(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function q(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-n,2);i>>8*(r?i:1-i)}function z(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-n,4);i>>8*(r?i:3-i)&255}function W(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function V(e,t,n,r,i){return i||W(e,0,n,4),c(e,t,n,r,23,4),n+4}function H(e,t,n,r,i){return i||W(e,0,n,8),c(e,t,n,r,52,8),n+8}t.prototype.slice=function(e,n){var r,i=this.length;if((e=~~e)<0?(e+=i)<0&&(e=0):e>i&&(e=i),(n=void 0===n?i:~~n)<0?(n+=i)<0&&(n=0):n>i&&(n=i),n0&&(i*=256);)r+=this[e+--t]*i;return r},t.prototype.readUInt8=function(e,t){return t||j(e,1,this.length),this[e]},t.prototype.readUInt16LE=function(e,t){return t||j(e,2,this.length),this[e]|this[e+1]<<8},t.prototype.readUInt16BE=function(e,t){return t||j(e,2,this.length),this[e]<<8|this[e+1]},t.prototype.readUInt32LE=function(e,t){return t||j(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},t.prototype.readUInt32BE=function(e,t){return t||j(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},t.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||j(e,t,this.length);for(var r=this[e],i=1,o=0;++o=(i*=128)&&(r-=Math.pow(2,8*t)),r},t.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||j(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},t.prototype.readInt8=function(e,t){return t||j(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},t.prototype.readInt16LE=function(e,t){t||j(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},t.prototype.readInt16BE=function(e,t){t||j(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},t.prototype.readInt32LE=function(e,t){return t||j(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},t.prototype.readInt32BE=function(e,t){return t||j(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},t.prototype.readFloatLE=function(e,t){return t||j(e,4,this.length),f(this,e,!0,23,4)},t.prototype.readFloatBE=function(e,t){return t||j(e,4,this.length),f(this,e,!1,23,4)},t.prototype.readDoubleLE=function(e,t){return t||j(e,8,this.length),f(this,e,!0,52,8)},t.prototype.readDoubleBE=function(e,t){return t||j(e,8,this.length),f(this,e,!1,52,8)},t.prototype.writeUIntLE=function(e,t,n,r){e=+e,t|=0,n|=0,r||N(this,e,t,n,Math.pow(2,8*n)-1,0);var i=1,o=0;for(this[t]=255&e;++o=0&&(o*=256);)this[t+i]=e/o&255;return t+n},t.prototype.writeUInt8=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,1,255,0),t.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[n]=255&e,n+1},t.prototype.writeUInt16LE=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,2,65535,0),t.TYPED_ARRAY_SUPPORT?(this[n]=255&e,this[n+1]=e>>>8):q(this,e,n,!0),n+2},t.prototype.writeUInt16BE=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,2,65535,0),t.TYPED_ARRAY_SUPPORT?(this[n]=e>>>8,this[n+1]=255&e):q(this,e,n,!1),n+2},t.prototype.writeUInt32LE=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,4,4294967295,0),t.TYPED_ARRAY_SUPPORT?(this[n+3]=e>>>24,this[n+2]=e>>>16,this[n+1]=e>>>8,this[n]=255&e):z(this,e,n,!0),n+4},t.prototype.writeUInt32BE=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,4,4294967295,0),t.TYPED_ARRAY_SUPPORT?(this[n]=e>>>24,this[n+1]=e>>>16,this[n+2]=e>>>8,this[n+3]=255&e):z(this,e,n,!1),n+4},t.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);N(this,e,t,n,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o>0)-s&255;return t+n},t.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);N(this,e,t,n,i-1,-i)}var o=n-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},t.prototype.writeInt8=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,1,127,-128),t.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[n]=255&e,n+1},t.prototype.writeInt16LE=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,2,32767,-32768),t.TYPED_ARRAY_SUPPORT?(this[n]=255&e,this[n+1]=e>>>8):q(this,e,n,!0),n+2},t.prototype.writeInt16BE=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,2,32767,-32768),t.TYPED_ARRAY_SUPPORT?(this[n]=e>>>8,this[n+1]=255&e):q(this,e,n,!1),n+2},t.prototype.writeInt32LE=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,4,2147483647,-2147483648),t.TYPED_ARRAY_SUPPORT?(this[n]=255&e,this[n+1]=e>>>8,this[n+2]=e>>>16,this[n+3]=e>>>24):z(this,e,n,!0),n+4},t.prototype.writeInt32BE=function(e,n,r){return e=+e,n|=0,r||N(this,e,n,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),t.TYPED_ARRAY_SUPPORT?(this[n]=e>>>24,this[n+1]=e>>>16,this[n+2]=e>>>8,this[n+3]=255&e):z(this,e,n,!1),n+4},t.prototype.writeFloatLE=function(e,t,n){return V(this,e,t,!0,n)},t.prototype.writeFloatBE=function(e,t,n){return V(this,e,t,!1,n)},t.prototype.writeDoubleLE=function(e,t,n){return H(this,e,t,!0,n)},t.prototype.writeDoubleBE=function(e,t,n){return H(this,e,t,!1,n)},t.prototype.copy=function(e,n,r,i){if(r||(r=0),i||0===i||(i=this.length),n>=e.length&&(n=e.length),n||(n=0),i>0&&i=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-n=0;--o)e[o+n]=this[o+r];else if(a<1e3||!t.TYPED_ARRAY_SUPPORT)for(o=0;o>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(a=n;a55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function X(e){return function(e){var t,n,r,l,u,f;a||s();var c=e.length;if(c%4>0)throw new Error("Invalid string. Length must be a multiple of 4");u="="===e[c-2]?2:"="===e[c-1]?1:0,f=new o(3*c/4-u),r=u>0?c-4:c;var h=0;for(t=0,n=0;t>16&255,f[h++]=l>>8&255,f[h++]=255&l;return 2===u?(l=i[e.charCodeAt(t)]<<2|i[e.charCodeAt(t+1)]>>4,f[h++]=255&l):1===u&&(l=i[e.charCodeAt(t)]<<10|i[e.charCodeAt(t+1)]<<4|i[e.charCodeAt(t+2)]>>2,f[h++]=l>>8&255,f[h++]=255&l),f}(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(Y,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function K(e,t,n,r){for(var i=0;i=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function J(e){return null!=e&&(!!e._isBuffer||$(e)||function(e){return"function"==typeof e.readFloatLE&&"function"==typeof e.slice&&$(e.slice(0,0))}(e))}function $(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}function Z(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Q(e,t){for(var n=0;n=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ae(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function se(e,t){return!t||"object"!=typeof t&&"function"!=typeof t?ae(e):t}function le(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t0?Fe:Ue)(e)},Ne=Math.min,qe=function(e){return e>0?Ne(je(e),9007199254740991):0},ze=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e},We=function(e,t,n,r){var i=String(ze(e)),o=i.length,a=void 0===n?" ":String(n),s=qe(t);if(s<=o||""==a)return i;var l=s-o,u=function(e){var t=String(ze(this)),n="",r=je(e);if(r<0||r==1/0)throw RangeError("Count can't be negative");for(;r>0;(r>>>=1)&&(t+=t))1&r&&(n+=t);return n}.call(a,Math.ceil(l/a.length));return u.length>l&&(u=u.slice(0,l)),r?u+i:i+u},Ve=pe.navigator,He=Ve&&Ve.userAgent||"";Pe(Pe.P+Pe.F*/Version\/10\.\d+(\.\d+)? Safari\//.test(He),"String",{padStart:function(e){return We(this,e,arguments.length>1?arguments[1]:void 0,!0)}});var Ye={}.toString,Ge=function(e){return Ye.call(e).slice(8,-1)},Xe={f:{}.propertyIsEnumerable},Ke=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==Ge(e)?e.split(""):Object(e)},Je=function(e){return Ke(ze(e))},$e=Object.getOwnPropertyDescriptor,Ze={f:he?$e:function(e,t){if(e=Je(e),t=be(t,!0),ve)try{return $e(e,t)}catch(n){}if(Le(e,t))return Ce(!Xe.f.call(e,t),e[t])}},Qe=function(e,t){if(fe(e),!ue(t)&&null!==t)throw TypeError(t+": can't set as prototype!")},et=Object.setPrototypeOf||("__proto__"in{}?function(e,t,n){try{(n=Be(Function.call,Ze.f(Object.prototype,"__proto__").set,2))(e,[]),t=!(e instanceof Array)}catch(r){t=!0}return function(e,r){return Qe(e,r),t?e.__proto__=r:n(e,r),e}}({},!1):void 0),tt=function(e,t,n){var r,i=t.constructor;return i!==n&&"function"==typeof i&&(r=i.prototype)!==n.prototype&&ue(r)&&et&&et(e,r),e},nt=Math.max,ot=Math.min,at=de((function(e){var t=pe["__core-js_shared__"]||(pe["__core-js_shared__"]={});(e.exports=function(e,n){return t[e]||(t[e]=void 0!==n?n:{})})("versions",[]).push({version:Ee.version,mode:"global",copyright:"\xa9 2018 Denis Pushkarev (zloirock.ru)"})})),st=at("keys"),ut=function(e){return st[e]||(st[e]=De(e))},ft=(!1,function(e,t,n){var r=Je(e),i=qe(r.length),o=function(e,t){return(e=je(e))<0?nt(e+t,0):ot(e,t)}(n,i);for(0;i>o;o++)if(o in r&&r[o]===t)return o||0;return-1}),ct=ut("IE_PROTO"),ht=function(e,t){var n,r=Je(e),i=0,o=[];for(n in r)n!=ct&&Le(r,n)&&o.push(n);for(;t.length>i;)Le(r,n=t[i++])&&(~ft(o,n)||o.push(n));return o},dt="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(","),pt=dt.concat("length","prototype"),mt={f:Object.getOwnPropertyNames||function(e){return ht(e,pt)}},gt="\t\n\v\f\r \xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029\ufeff",yt="["+gt+"]",vt=RegExp("^"+yt+yt+"*"),bt=RegExp(yt+yt+"*$"),wt=function(e,t,n){var r={},i=ce((function(){return!!gt[e]()||"\u200b\x85"!="\u200b\x85"[e]()})),o=r[e]=i?t(St):gt[e];n&&(r[n]=o),Pe(Pe.P+Pe.F*i,"String",r)},St=wt.trim=function(e,t){return e=String(ze(e)),1&t&&(e=e.replace(vt,"")),2&t&&(e=e.replace(bt,"")),e},kt=wt,_t=Object.keys||function(e){return ht(e,dt)},Tt=he?Object.defineProperties:function(e,t){fe(e);for(var n,r=_t(t),i=r.length,o=0;i>o;)Se.f(e,n=r[o++],t[n]);return e},Et=pe.document,Ct=Et&&Et.documentElement,At=ut("IE_PROTO"),Rt=function(){},Lt=function(){var e,t=ye("iframe"),n=dt.length;for(t.style.display="none",Ct.appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write(" + + + \ No newline at end of file diff --git a/index.html b/index.html index 42a5f9e..2640a70 100644 --- a/index.html +++ b/index.html @@ -1,5 +1,5 @@ - + @@ -17,57 +17,71 @@ Miru - Torrent streaming made simple! - + -
-
-
-
-
-
-
-

- Miru - Anime torrent streaming, ad free in a simple solution. -

-

- Miru is an otaku's dream, a website which allows you to stream and download anime torrents - directly in the browser as soon as they are released. Accessible on any platform and device. Anime in original quality with - no buffering, no ads, no delays, everything done client-side for free. -

-
-
- Add app -
+
+
+
+
+
+
+
+
+
+
+

+ Miru - Anime torrent streaming, ad free in a simple solution. +

+

+ Miru is an otaku's dream, a website which allows you to stream and download anime + torrents + directly in the browser as soon as they are released. Accessible on any platform and + device. Anime in original quality with + no buffering, no ads, no delays, everything done client-side for free. +

+
+
+ Add app
-
- char -
+
+
+ char
+ +
diff --git a/manifest.json b/manifest.json index a1f1c67..1dc5e42 100644 --- a/manifest.json +++ b/manifest.json @@ -1,7 +1,7 @@ { "name": "Miru", "short_name": "Miru", - "start_url": "/app/app.html", + "start_url": "/app/#browse", "display": "fullscreen", "categories": [ "entertainment"