Greasy Fork

bilibili视频下载

支持Web、RPC、Blob、Aria等下载方式;支持flv、dash、mp4视频格式;支持下载港区番剧;支持会员下载;支持换源播放,自动切换为高清视频源

目前为 2022-04-16 提交的版本。查看 最新版本

// ==UserScript==
// @name          bilibili视频下载
// @namespace     https://github.com/injahow
// @version       2.1.0
// @description   支持Web、RPC、Blob、Aria等下载方式;支持flv、dash、mp4视频格式;支持下载港区番剧;支持会员下载;支持换源播放,自动切换为高清视频源
// @author        injahow
// @copyright     2021, injahow (https://github.com/injahow)
// @license       MIT
// @source        https://github.com/injahow/user.js
// @supportURL    https://github.com/injahow/user.js/issues
// @match         *://www.bilibili.com/video/av*
// @match         *://www.bilibili.com/video/BV*
// @match         *://www.bilibili.com/medialist/play/*
// @match         *://www.bilibili.com/bangumi/play/ep*
// @match         *://www.bilibili.com/bangumi/play/ss*
// @match         *://www.bilibili.com/cheese/play/ep*
// @match         *://www.bilibili.com/cheese/play/ss*
// @match         https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png*
// @require       https://static.hdslb.com/js/jquery.min.js
// @require       https://cdn.jsdelivr.net/npm/[email protected]/dist/flv.min.js
// @require       https://cdn.jsdelivr.net/npm/[email protected]/dist/DPlayer.min.js
// @icon          https://static.hdslb.com/images/favicon.ico
// @compatible    chrome
// @compatible    firefox
// @grant         none
// ==/UserScript==
/* eslint-disable */ /* spell-checker: disable */
// @[ You can find all source codes in GitHub repo ]
!function(){var e={44:function(e,t,n){"use strict";n.r(t),n.d(t,{config:function(){return r},hostMap:function(){return i}});var r={base_api:"https://api.injahow.cn/bparse/",request_type:"auto",format:"flv",host_key:"0",replace_force:"0",auth:"0",download_type:"web",rpc_domain:"http://localhost",rpc_port:"16800",rpc_token:"",rpc_dir:"D:/",ariang_host:"http://ariang.injahow.com/",auto_download:"0",danmaku_speed:"15",danmaku_fontsize:"22"},i={0:"关闭",ks3:"upos-sz-mirrorks3.bilivideo.com",ks3b:"upos-sz-mirrorks3b.bilivideo.com",ks3c:"upos-sz-mirrorks3c.bilivideo.com",ks32:"upos-sz-mirrorks32.bilivideo.com",kodo:"upos-sz-mirrorkodo.bilivideo.com",kodob:"upos-sz-mirrorkodob.bilivideo.com",cos:"upos-sz-mirrorcos.bilivideo.com",cosb:"upos-sz-mirrorcosb.bilivideo.com",bos:"upos-sz-mirrorbos.bilivideo.com",wcs:"upos-sz-mirrorwcs.bilivideo.com",wcsb:"upos-sz-mirrorwcsb.bilivideo.com",hw:"upos-sz-mirrorhw.bilivideo.com",hwb:"upos-sz-mirrorhwb.bilivideo.com",upbda2:"upos-sz-upcdnbda2.bilivideo.com",upws:"upos-sz-upcdnws.bilivideo.com",uptx:"upos-sz-upcdntx.bilivideo.com",uphw:"upos-sz-upcdnhw.bilivideo.com",js:"upos-tf-all-js.bilivideo.com",hk:"cn-hk-eq-bcache-01.bilivideo.com",akamai:"upos-hz-mirrorakam.akamaized.net"}},657:function(e,t,n){"use strict";var r=n(81),i=n.n(r),o=n(645),a=n.n(o)()(i());a.push([e.id,"\n#bp_config[data-v-6a48ed2c] {\n  opacity: 0;\n  display: none;\n  position: fixed;\n  inset: 0px;\n  top: 0px;\n  left: 0px;\n  width: 100%;\n  height: 100%;\n  z-index: 10000;\n}\n.bp_config_bg[data-v-6a48ed2c] {\n  position: absolute;\n  background: rgb(255, 255, 255);\n  border-radius: 10px;\n  padding: 20px;\n  top: 50%;\n  left: 50%;\n  transform: translate(-50%, -50%);\n  width: 600px;\n  box-shadow: rgb(0 0 0 / 70%) 0px 0px 0px 1000px;\n}\n.setting-button[data-v-6a48ed2c] {\n  width: 120px;\n  height: 40px;\n  border-width: 0px;\n  border-radius: 3px;\n  background: #1e90ff;\n  cursor: pointer;\n  outline: none;\n  color: white;\n  font-size: 17px;\n}\n.setting-button[data-v-6a48ed2c]:hover {\n  background: #5599ff;\n}\n.setting-context[data-v-6a48ed2c] {\n  margin: 0 1%;\n  color: blue;\n}\n.setting-context[data-v-6a48ed2c]:hover {\n  color: red;\n}\n",""]),t.Z=a},645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,i,o){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(r)for(var s=0;s<this.length;s++){var l=this[s][0];null!=l&&(a[l]=!0)}for(var c=0;c<e.length;c++){var u=[].concat(e[c]);r&&a[u[0]]||(void 0!==o&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=o),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),i&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=i):u[4]="".concat(i)),t.push(u))}},t}},81:function(e){"use strict";e.exports=function(e){return e[1]}},733:function(e,t,n){e.exports=function e(t,n,r){function i(a,s){if(!n[a]){if(!t[a]){if(o)return o(a,!0);var l=new Error("Cannot find module '"+a+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[a]={exports:{}};t[a][0].call(c.exports,(function(e){return i(t[a][1][e]||e)}),c,c.exports,e,t,n,r)}return n[a].exports}for(var o=void 0,a=0;a<r.length;a++)i(r[a]);return i}({1:[function(e,t,n){"use strict";var r=e("./utils"),i=e("./support"),o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";n.encode=function(e){for(var t,n,i,a,s,l,c,u=[],d=0,f=e.length,h=f,p="string"!==r.getTypeOf(e);d<e.length;)h=f-d,i=p?(t=e[d++],n=d<f?e[d++]:0,d<f?e[d++]:0):(t=e.charCodeAt(d++),n=d<f?e.charCodeAt(d++):0,d<f?e.charCodeAt(d++):0),a=t>>2,s=(3&t)<<4|n>>4,l=1<h?(15&n)<<2|i>>6:64,c=2<h?63&i:64,u.push(o.charAt(a)+o.charAt(s)+o.charAt(l)+o.charAt(c));return u.join("")},n.decode=function(e){var t,n,r,a,s,l,c=0,u=0,d="data:";if(e.substr(0,d.length)===d)throw new Error("Invalid base64 input, it looks like a data url.");var f,h=3*(e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"")).length/4;if(e.charAt(e.length-1)===o.charAt(64)&&h--,e.charAt(e.length-2)===o.charAt(64)&&h--,h%1!=0)throw new Error("Invalid base64 input, bad content length.");for(f=i.uint8array?new Uint8Array(0|h):new Array(0|h);c<e.length;)t=o.indexOf(e.charAt(c++))<<2|(a=o.indexOf(e.charAt(c++)))>>4,n=(15&a)<<4|(s=o.indexOf(e.charAt(c++)))>>2,r=(3&s)<<6|(l=o.indexOf(e.charAt(c++))),f[u++]=t,64!==s&&(f[u++]=n),64!==l&&(f[u++]=r);return f}},{"./support":30,"./utils":32}],2:[function(e,t,n){"use strict";var r=e("./external"),i=e("./stream/DataWorker"),o=e("./stream/Crc32Probe"),a=e("./stream/DataLengthProbe");function s(e,t,n,r,i){this.compressedSize=e,this.uncompressedSize=t,this.crc32=n,this.compression=r,this.compressedContent=i}s.prototype={getContentWorker:function(){var e=new i(r.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new a("data_length")),t=this;return e.on("end",(function(){if(this.streamInfo.data_length!==t.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")})),e},getCompressedWorker:function(){return new i(r.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},s.createWorkerFrom=function(e,t,n){return e.pipe(new o).pipe(new a("uncompressedSize")).pipe(t.compressWorker(n)).pipe(new a("compressedSize")).withStreamInfo("compression",t)},t.exports=s},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(e,t,n){"use strict";var r=e("./stream/GenericWorker");n.STORE={magic:"\0\0",compressWorker:function(e){return new r("STORE compression")},uncompressWorker:function(){return new r("STORE decompression")}},n.DEFLATE=e("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(e,t,n){"use strict";var r=e("./utils"),i=function(){for(var e,t=[],n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}();t.exports=function(e,t){return void 0!==e&&e.length?"string"!==r.getTypeOf(e)?function(e,t,n,r){var o=i,a=r+n;e^=-1;for(var s=r;s<a;s++)e=e>>>8^o[255&(e^t[s])];return-1^e}(0|t,e,e.length,0):function(e,t,n,r){var o=i,a=r+n;e^=-1;for(var s=r;s<a;s++)e=e>>>8^o[255&(e^t.charCodeAt(s))];return-1^e}(0|t,e,e.length,0):0}},{"./utils":32}],5:[function(e,t,n){"use strict";n.base64=!1,n.binary=!1,n.dir=!1,n.createFolders=!0,n.date=null,n.compression=null,n.compressionOptions=null,n.comment=null,n.unixPermissions=null,n.dosPermissions=null},{}],6:[function(e,t,n){"use strict";var r=null;r="undefined"!=typeof Promise?Promise:e("lie"),t.exports={Promise:r}},{lie:37}],7:[function(e,t,n){"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array,i=e("pako"),o=e("./utils"),a=e("./stream/GenericWorker"),s=r?"uint8array":"array";function l(e,t){a.call(this,"FlateWorker/"+e),this._pako=null,this._pakoAction=e,this._pakoOptions=t,this.meta={}}n.magic="\b\0",o.inherits(l,a),l.prototype.processChunk=function(e){this.meta=e.meta,null===this._pako&&this._createPako(),this._pako.push(o.transformTo(s,e.data),!1)},l.prototype.flush=function(){a.prototype.flush.call(this),null===this._pako&&this._createPako(),this._pako.push([],!0)},l.prototype.cleanUp=function(){a.prototype.cleanUp.call(this),this._pako=null},l.prototype._createPako=function(){this._pako=new i[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var e=this;this._pako.onData=function(t){e.push({data:t,meta:e.meta})}},n.compressWorker=function(e){return new l("Deflate",e)},n.uncompressWorker=function(){return new l("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:38}],8:[function(e,t,n){"use strict";function r(e,t){var n,r="";for(n=0;n<t;n++)r+=String.fromCharCode(255&e),e>>>=8;return r}function i(e,t,n,i,a,u){var d,f,h=e.file,p=e.compression,_=u!==s.utf8encode,m=o.transformTo("string",u(h.name)),v=o.transformTo("string",s.utf8encode(h.name)),g=h.comment,b=o.transformTo("string",u(g)),y=o.transformTo("string",s.utf8encode(g)),w=v.length!==h.name.length,k=y.length!==g.length,x="",S="",C="",E=h.dir,A=h.date,O={crc32:0,compressedSize:0,uncompressedSize:0};t&&!n||(O.crc32=e.crc32,O.compressedSize=e.compressedSize,O.uncompressedSize=e.uncompressedSize);var I=0;t&&(I|=8),_||!w&&!k||(I|=2048);var T=0,z=0;E&&(T|=16),"UNIX"===a?(z=798,T|=function(e,t){var n=e;return e||(n=t?16893:33204),(65535&n)<<16}(h.unixPermissions,E)):(z=20,T|=function(e){return 63&(e||0)}(h.dosPermissions)),d=A.getUTCHours(),d<<=6,d|=A.getUTCMinutes(),d<<=5,d|=A.getUTCSeconds()/2,f=A.getUTCFullYear()-1980,f<<=4,f|=A.getUTCMonth()+1,f<<=5,f|=A.getUTCDate(),w&&(S=r(1,1)+r(l(m),4)+v,x+="up"+r(S.length,2)+S),k&&(C=r(1,1)+r(l(b),4)+y,x+="uc"+r(C.length,2)+C);var F="";return F+="\n\0",F+=r(I,2),F+=p.magic,F+=r(d,2),F+=r(f,2),F+=r(O.crc32,4),F+=r(O.compressedSize,4),F+=r(O.uncompressedSize,4),F+=r(m.length,2),F+=r(x.length,2),{fileRecord:c.LOCAL_FILE_HEADER+F+m+x,dirRecord:c.CENTRAL_FILE_HEADER+r(z,2)+F+r(b.length,2)+"\0\0\0\0"+r(T,4)+r(i,4)+m+x+b}}var o=e("../utils"),a=e("../stream/GenericWorker"),s=e("../utf8"),l=e("../crc32"),c=e("../signature");function u(e,t,n,r){a.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=t,this.zipPlatform=n,this.encodeFileName=r,this.streamFiles=e,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}o.inherits(u,a),u.prototype.push=function(e){var t=e.meta.percent||0,n=this.entriesCount,r=this._sources.length;this.accumulate?this.contentBuffer.push(e):(this.bytesWritten+=e.data.length,a.prototype.push.call(this,{data:e.data,meta:{currentFile:this.currentFile,percent:n?(t+100*(n-r-1))/n:100}}))},u.prototype.openedSource=function(e){this.currentSourceOffset=this.bytesWritten,this.currentFile=e.file.name;var t=this.streamFiles&&!e.file.dir;if(t){var n=i(e,t,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:n.fileRecord,meta:{percent:0}})}else this.accumulate=!0},u.prototype.closedSource=function(e){this.accumulate=!1;var t=this.streamFiles&&!e.file.dir,n=i(e,t,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(n.dirRecord),t)this.push({data:function(e){return c.DATA_DESCRIPTOR+r(e.crc32,4)+r(e.compressedSize,4)+r(e.uncompressedSize,4)}(e),meta:{percent:100}});else for(this.push({data:n.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},u.prototype.flush=function(){for(var e=this.bytesWritten,t=0;t<this.dirRecords.length;t++)this.push({data:this.dirRecords[t],meta:{percent:100}});var n=this.bytesWritten-e,i=function(e,t,n,i,a){var s=o.transformTo("string",a(i));return c.CENTRAL_DIRECTORY_END+"\0\0\0\0"+r(e,2)+r(e,2)+r(t,4)+r(n,4)+r(s.length,2)+s}(this.dirRecords.length,n,e,this.zipComment,this.encodeFileName);this.push({data:i,meta:{percent:100}})},u.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},u.prototype.registerPrevious=function(e){this._sources.push(e);var t=this;return e.on("data",(function(e){t.processChunk(e)})),e.on("end",(function(){t.closedSource(t.previous.streamInfo),t._sources.length?t.prepareNextSource():t.end()})),e.on("error",(function(e){t.error(e)})),this},u.prototype.resume=function(){return!!a.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},u.prototype.error=function(e){var t=this._sources;if(!a.prototype.error.call(this,e))return!1;for(var n=0;n<t.length;n++)try{t[n].error(e)}catch(e){}return!0},u.prototype.lock=function(){a.prototype.lock.call(this);for(var e=this._sources,t=0;t<e.length;t++)e[t].lock()},t.exports=u},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(e,t,n){"use strict";var r=e("../compressions"),i=e("./ZipFileWorker");n.generateWorker=function(e,t,n){var o=new i(t.streamFiles,n,t.platform,t.encodeFileName),a=0;try{e.forEach((function(e,n){a++;var i=function(e,t){var n=e||t,i=r[n];if(!i)throw new Error(n+" is not a valid compression method !");return i}(n.options.compression,t.compression),s=n.options.compressionOptions||t.compressionOptions||{},l=n.dir,c=n.date;n._compressWorker(i,s).withStreamInfo("file",{name:e,dir:l,date:c,comment:n.comment||"",unixPermissions:n.unixPermissions,dosPermissions:n.dosPermissions}).pipe(o)})),o.entriesCount=a}catch(e){o.error(e)}return o}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(e,t,n){"use strict";function r(){if(!(this instanceof r))return new r;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var e=new r;for(var t in this)"function"!=typeof this[t]&&(e[t]=this[t]);return e}}(r.prototype=e("./object")).loadAsync=e("./load"),r.support=e("./support"),r.defaults=e("./defaults"),r.version="3.9.1",r.loadAsync=function(e,t){return(new r).loadAsync(e,t)},r.external=e("./external"),t.exports=r},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(e,t,n){"use strict";var r=e("./utils"),i=e("./external"),o=e("./utf8"),a=e("./zipEntries"),s=e("./stream/Crc32Probe"),l=e("./nodejsUtils");function c(e){return new i.Promise((function(t,n){var r=e.decompressed.getContentWorker().pipe(new s);r.on("error",(function(e){n(e)})).on("end",(function(){r.streamInfo.crc32!==e.decompressed.crc32?n(new Error("Corrupted zip : CRC32 mismatch")):t()})).resume()}))}t.exports=function(e,t){var n=this;return t=r.extend(t||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:o.utf8decode}),l.isNode&&l.isStream(e)?i.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):r.prepareContent("the loaded zip file",e,!0,t.optimizedBinaryString,t.base64).then((function(e){var n=new a(t);return n.load(e),n})).then((function(e){var n=[i.Promise.resolve(e)],r=e.files;if(t.checkCRC32)for(var o=0;o<r.length;o++)n.push(c(r[o]));return i.Promise.all(n)})).then((function(e){for(var i=e.shift(),o=i.files,a=0;a<o.length;a++){var s=o[a],l=s.fileNameStr,c=r.resolve(s.fileNameStr);n.file(c,s.decompressed,{binary:!0,optimizedBinaryString:!0,date:s.date,dir:s.dir,comment:s.fileCommentStr.length?s.fileCommentStr:null,unixPermissions:s.unixPermissions,dosPermissions:s.dosPermissions,createFolders:t.createFolders}),s.dir||(n.file(c).unsafeOriginalName=l)}return i.zipComment.length&&(n.comment=i.zipComment),n}))}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(e,t,n){"use strict";var r=e("../utils"),i=e("../stream/GenericWorker");function o(e,t){i.call(this,"Nodejs stream input adapter for "+e),this._upstreamEnded=!1,this._bindStream(t)}r.inherits(o,i),o.prototype._bindStream=function(e){var t=this;(this._stream=e).pause(),e.on("data",(function(e){t.push({data:e,meta:{percent:0}})})).on("error",(function(e){t.isPaused?this.generatedError=e:t.error(e)})).on("end",(function(){t.isPaused?t._upstreamEnded=!0:t.end()}))},o.prototype.pause=function(){return!!i.prototype.pause.call(this)&&(this._stream.pause(),!0)},o.prototype.resume=function(){return!!i.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},t.exports=o},{"../stream/GenericWorker":28,"../utils":32}],13:[function(e,t,n){"use strict";var r=e("readable-stream").Readable;function i(e,t,n){r.call(this,t),this._helper=e;var i=this;e.on("data",(function(e,t){i.push(e)||i._helper.pause(),n&&n(t)})).on("error",(function(e){i.emit("error",e)})).on("end",(function(){i.push(null)}))}e("../utils").inherits(i,r),i.prototype._read=function(){this._helper.resume()},t.exports=i},{"../utils":32,"readable-stream":16}],14:[function(e,t,n){"use strict";t.exports={isNode:"undefined"!=typeof Buffer,newBufferFrom:function(e,t){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(e,t);if("number"==typeof e)throw new Error('The "data" argument must not be a number');return new Buffer(e,t)},allocBuffer:function(e){if(Buffer.alloc)return Buffer.alloc(e);var t=new Buffer(e);return t.fill(0),t},isBuffer:function(e){return Buffer.isBuffer(e)},isStream:function(e){return e&&"function"==typeof e.on&&"function"==typeof e.pause&&"function"==typeof e.resume}}},{}],15:[function(e,t,n){"use strict";function r(e,t,n){var r,i=o.getTypeOf(t),s=o.extend(n||{},l);s.date=s.date||new Date,null!==s.compression&&(s.compression=s.compression.toUpperCase()),"string"==typeof s.unixPermissions&&(s.unixPermissions=parseInt(s.unixPermissions,8)),s.unixPermissions&&16384&s.unixPermissions&&(s.dir=!0),s.dosPermissions&&16&s.dosPermissions&&(s.dir=!0),s.dir&&(e=_(e)),s.createFolders&&(r=p(e))&&m.call(this,r,!0);var d="string"===i&&!1===s.binary&&!1===s.base64;n&&void 0!==n.binary||(s.binary=!d),(t instanceof c&&0===t.uncompressedSize||s.dir||!t||0===t.length)&&(s.base64=!1,s.binary=!0,t="",s.compression="STORE",i="string");var v=null;v=t instanceof c||t instanceof a?t:f.isNode&&f.isStream(t)?new h(e,t):o.prepareContent(e,t,s.binary,s.optimizedBinaryString,s.base64);var g=new u(e,v,s);this.files[e]=g}var i=e("./utf8"),o=e("./utils"),a=e("./stream/GenericWorker"),s=e("./stream/StreamHelper"),l=e("./defaults"),c=e("./compressedObject"),u=e("./zipObject"),d=e("./generate"),f=e("./nodejsUtils"),h=e("./nodejs/NodejsStreamInputAdapter"),p=function(e){"/"===e.slice(-1)&&(e=e.substring(0,e.length-1));var t=e.lastIndexOf("/");return 0<t?e.substring(0,t):""},_=function(e){return"/"!==e.slice(-1)&&(e+="/"),e},m=function(e,t){return t=void 0!==t?t:l.createFolders,e=_(e),this.files[e]||r.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]};function v(e){return"[object RegExp]"===Object.prototype.toString.call(e)}var g={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(e){var t,n,r;for(t in this.files)r=this.files[t],(n=t.slice(this.root.length,t.length))&&t.slice(0,this.root.length)===this.root&&e(n,r)},filter:function(e){var t=[];return this.forEach((function(n,r){e(n,r)&&t.push(r)})),t},file:function(e,t,n){if(1!==arguments.length)return e=this.root+e,r.call(this,e,t,n),this;if(v(e)){var i=e;return this.filter((function(e,t){return!t.dir&&i.test(e)}))}var o=this.files[this.root+e];return o&&!o.dir?o:null},folder:function(e){if(!e)return this;if(v(e))return this.filter((function(t,n){return n.dir&&e.test(t)}));var t=this.root+e,n=m.call(this,t),r=this.clone();return r.root=n.name,r},remove:function(e){e=this.root+e;var t=this.files[e];if(t||("/"!==e.slice(-1)&&(e+="/"),t=this.files[e]),t&&!t.dir)delete this.files[e];else for(var n=this.filter((function(t,n){return n.name.slice(0,e.length)===e})),r=0;r<n.length;r++)delete this.files[n[r].name];return this},generate:function(e){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(e){var t,n={};try{if((n=o.extend(e||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:i.utf8encode})).type=n.type.toLowerCase(),n.compression=n.compression.toUpperCase(),"binarystring"===n.type&&(n.type="string"),!n.type)throw new Error("No output type specified.");o.checkSupport(n.type),"darwin"!==n.platform&&"freebsd"!==n.platform&&"linux"!==n.platform&&"sunos"!==n.platform||(n.platform="UNIX"),"win32"===n.platform&&(n.platform="DOS");var r=n.comment||this.comment||"";t=d.generateWorker(this,n,r)}catch(e){(t=new a("error")).error(e)}return new s(t,n.type||"string",n.mimeType)},generateAsync:function(e,t){return this.generateInternalStream(e).accumulate(t)},generateNodeStream:function(e,t){return(e=e||{}).type||(e.type="nodebuffer"),this.generateInternalStream(e).toNodejsStream(t)}};t.exports=g},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(e,t,n){t.exports=e("stream")},{stream:void 0}],17:[function(e,t,n){"use strict";var r=e("./DataReader");function i(e){r.call(this,e);for(var t=0;t<this.data.length;t++)e[t]=255&e[t]}e("../utils").inherits(i,r),i.prototype.byteAt=function(e){return this.data[this.zero+e]},i.prototype.lastIndexOfSignature=function(e){for(var t=e.charCodeAt(0),n=e.charCodeAt(1),r=e.charCodeAt(2),i=e.charCodeAt(3),o=this.length-4;0<=o;--o)if(this.data[o]===t&&this.data[o+1]===n&&this.data[o+2]===r&&this.data[o+3]===i)return o-this.zero;return-1},i.prototype.readAndCheckSignature=function(e){var t=e.charCodeAt(0),n=e.charCodeAt(1),r=e.charCodeAt(2),i=e.charCodeAt(3),o=this.readData(4);return t===o[0]&&n===o[1]&&r===o[2]&&i===o[3]},i.prototype.readData=function(e){if(this.checkOffset(e),0===e)return[];var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=i},{"../utils":32,"./DataReader":18}],18:[function(e,t,n){"use strict";var r=e("../utils");function i(e){this.data=e,this.length=e.length,this.index=0,this.zero=0}i.prototype={checkOffset:function(e){this.checkIndex(this.index+e)},checkIndex:function(e){if(this.length<this.zero+e||e<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+e+"). Corrupted zip ?")},setIndex:function(e){this.checkIndex(e),this.index=e},skip:function(e){this.setIndex(this.index+e)},byteAt:function(e){},readInt:function(e){var t,n=0;for(this.checkOffset(e),t=this.index+e-1;t>=this.index;t--)n=(n<<8)+this.byteAt(t);return this.index+=e,n},readString:function(e){return r.transformTo("string",this.readData(e))},readData:function(e){},lastIndexOfSignature:function(e){},readAndCheckSignature:function(e){},readDate:function(){var e=this.readInt(4);return new Date(Date.UTC(1980+(e>>25&127),(e>>21&15)-1,e>>16&31,e>>11&31,e>>5&63,(31&e)<<1))}},t.exports=i},{"../utils":32}],19:[function(e,t,n){"use strict";var r=e("./Uint8ArrayReader");function i(e){r.call(this,e)}e("../utils").inherits(i,r),i.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=i},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(e,t,n){"use strict";var r=e("./DataReader");function i(e){r.call(this,e)}e("../utils").inherits(i,r),i.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)},i.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero},i.prototype.readAndCheckSignature=function(e){return e===this.readData(4)},i.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=i},{"../utils":32,"./DataReader":18}],21:[function(e,t,n){"use strict";var r=e("./ArrayReader");function i(e){r.call(this,e)}e("../utils").inherits(i,r),i.prototype.readData=function(e){if(this.checkOffset(e),0===e)return new Uint8Array(0);var t=this.data.subarray(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=i},{"../utils":32,"./ArrayReader":17}],22:[function(e,t,n){"use strict";var r=e("../utils"),i=e("../support"),o=e("./ArrayReader"),a=e("./StringReader"),s=e("./NodeBufferReader"),l=e("./Uint8ArrayReader");t.exports=function(e){var t=r.getTypeOf(e);return r.checkSupport(t),"string"!==t||i.uint8array?"nodebuffer"===t?new s(e):i.uint8array?new l(r.transformTo("uint8array",e)):new o(r.transformTo("array",e)):new a(e)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(e,t,n){"use strict";n.LOCAL_FILE_HEADER="PK",n.CENTRAL_FILE_HEADER="PK",n.CENTRAL_DIRECTORY_END="PK",n.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK",n.ZIP64_CENTRAL_DIRECTORY_END="PK",n.DATA_DESCRIPTOR="PK\b"},{}],24:[function(e,t,n){"use strict";var r=e("./GenericWorker"),i=e("../utils");function o(e){r.call(this,"ConvertWorker to "+e),this.destType=e}i.inherits(o,r),o.prototype.processChunk=function(e){this.push({data:i.transformTo(this.destType,e.data),meta:e.meta})},t.exports=o},{"../utils":32,"./GenericWorker":28}],25:[function(e,t,n){"use strict";var r=e("./GenericWorker"),i=e("../crc32");function o(){r.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}e("../utils").inherits(o,r),o.prototype.processChunk=function(e){this.streamInfo.crc32=i(e.data,this.streamInfo.crc32||0),this.push(e)},t.exports=o},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(e,t,n){"use strict";var r=e("../utils"),i=e("./GenericWorker");function o(e){i.call(this,"DataLengthProbe for "+e),this.propName=e,this.withStreamInfo(e,0)}r.inherits(o,i),o.prototype.processChunk=function(e){if(e){var t=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=t+e.data.length}i.prototype.processChunk.call(this,e)},t.exports=o},{"../utils":32,"./GenericWorker":28}],27:[function(e,t,n){"use strict";var r=e("../utils"),i=e("./GenericWorker");function o(e){i.call(this,"DataWorker");var t=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,e.then((function(e){t.dataIsReady=!0,t.data=e,t.max=e&&e.length||0,t.type=r.getTypeOf(e),t.isPaused||t._tickAndRepeat()}),(function(e){t.error(e)}))}r.inherits(o,i),o.prototype.cleanUp=function(){i.prototype.cleanUp.call(this),this.data=null},o.prototype.resume=function(){return!!i.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,r.delay(this._tickAndRepeat,[],this)),!0)},o.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(r.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},o.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var e=null,t=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":e=this.data.substring(this.index,t);break;case"uint8array":e=this.data.subarray(this.index,t);break;case"array":case"nodebuffer":e=this.data.slice(this.index,t)}return this.index=t,this.push({data:e,meta:{percent:this.max?this.index/this.max*100:0}})},t.exports=o},{"../utils":32,"./GenericWorker":28}],28:[function(e,t,n){"use strict";function r(e){this.name=e||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}r.prototype={push:function(e){this.emit("data",e)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(e){this.emit("error",e)}return!0},error:function(e){return!this.isFinished&&(this.isPaused?this.generatedError=e:(this.isFinished=!0,this.emit("error",e),this.previous&&this.previous.error(e),this.cleanUp()),!0)},on:function(e,t){return this._listeners[e].push(t),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(e,t){if(this._listeners[e])for(var n=0;n<this._listeners[e].length;n++)this._listeners[e][n].call(this,t)},pipe:function(e){return e.registerPrevious(this)},registerPrevious:function(e){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=e.streamInfo,this.mergeStreamInfo(),this.previous=e;var t=this;return e.on("data",(function(e){t.processChunk(e)})),e.on("end",(function(){t.end()})),e.on("error",(function(e){t.error(e)})),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var e=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),e=!0),this.previous&&this.previous.resume(),!e},flush:function(){},processChunk:function(e){this.push(e)},withStreamInfo:function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var e in this.extraStreamInfo)this.extraStreamInfo.hasOwnProperty(e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e}},t.exports=r},{}],29:[function(e,t,n){"use strict";var r=e("../utils"),i=e("./ConvertWorker"),o=e("./GenericWorker"),a=e("../base64"),s=e("../support"),l=e("../external"),c=null;if(s.nodestream)try{c=e("../nodejs/NodejsStreamOutputAdapter")}catch(e){}function u(e,t){return new l.Promise((function(n,i){var o=[],s=e._internalType,l=e._outputType,c=e._mimeType;e.on("data",(function(e,n){o.push(e),t&&t(n)})).on("error",(function(e){o=[],i(e)})).on("end",(function(){try{var e=function(e,t,n){switch(e){case"blob":return r.newBlob(r.transformTo("arraybuffer",t),n);case"base64":return a.encode(t);default:return r.transformTo(e,t)}}(l,function(e,t){var n,r=0,i=null,o=0;for(n=0;n<t.length;n++)o+=t[n].length;switch(e){case"string":return t.join("");case"array":return Array.prototype.concat.apply([],t);case"uint8array":for(i=new Uint8Array(o),n=0;n<t.length;n++)i.set(t[n],r),r+=t[n].length;return i;case"nodebuffer":return Buffer.concat(t);default:throw new Error("concat : unsupported type '"+e+"'")}}(s,o),c);n(e)}catch(e){i(e)}o=[]})).resume()}))}function d(e,t,n){var a=t;switch(t){case"blob":case"arraybuffer":a="uint8array";break;case"base64":a="string"}try{this._internalType=a,this._outputType=t,this._mimeType=n,r.checkSupport(a),this._worker=e.pipe(new i(a)),e.lock()}catch(e){this._worker=new o("error"),this._worker.error(e)}}d.prototype={accumulate:function(e){return u(this,e)},on:function(e,t){var n=this;return"data"===e?this._worker.on(e,(function(e){t.call(n,e.data,e.meta)})):this._worker.on(e,(function(){r.delay(t,arguments,n)})),this},resume:function(){return r.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(e){if(r.checkSupport("nodestream"),"nodebuffer"!==this._outputType)throw new Error(this._outputType+" is not supported by this method");return new c(this,{objectMode:"nodebuffer"!==this._outputType},e)}},t.exports=d},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(e,t,n){"use strict";if(n.base64=!0,n.array=!0,n.string=!0,n.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,n.nodebuffer="undefined"!=typeof Buffer,n.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)n.blob=!1;else{var r=new ArrayBuffer(0);try{n.blob=0===new Blob([r],{type:"application/zip"}).size}catch(e){try{var i=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);i.append(r),n.blob=0===i.getBlob("application/zip").size}catch(e){n.blob=!1}}}try{n.nodestream=!!e("readable-stream").Readable}catch(e){n.nodestream=!1}},{"readable-stream":16}],31:[function(e,t,n){"use strict";for(var r=e("./utils"),i=e("./support"),o=e("./nodejsUtils"),a=e("./stream/GenericWorker"),s=new Array(256),l=0;l<256;l++)s[l]=252<=l?6:248<=l?5:240<=l?4:224<=l?3:192<=l?2:1;function c(){a.call(this,"utf-8 decode"),this.leftOver=null}function u(){a.call(this,"utf-8 encode")}s[254]=s[254]=1,n.utf8encode=function(e){return i.nodebuffer?o.newBufferFrom(e,"utf-8"):function(e){var t,n,r,o,a,s=e.length,l=0;for(o=0;o<s;o++)55296==(64512&(n=e.charCodeAt(o)))&&o+1<s&&56320==(64512&(r=e.charCodeAt(o+1)))&&(n=65536+(n-55296<<10)+(r-56320),o++),l+=n<128?1:n<2048?2:n<65536?3:4;for(t=i.uint8array?new Uint8Array(l):new Array(l),o=a=0;a<l;o++)55296==(64512&(n=e.charCodeAt(o)))&&o+1<s&&56320==(64512&(r=e.charCodeAt(o+1)))&&(n=65536+(n-55296<<10)+(r-56320),o++),n<128?t[a++]=n:(n<2048?t[a++]=192|n>>>6:(n<65536?t[a++]=224|n>>>12:(t[a++]=240|n>>>18,t[a++]=128|n>>>12&63),t[a++]=128|n>>>6&63),t[a++]=128|63&n);return t}(e)},n.utf8decode=function(e){return i.nodebuffer?r.transformTo("nodebuffer",e).toString("utf-8"):function(e){var t,n,i,o,a=e.length,l=new Array(2*a);for(t=n=0;t<a;)if((i=e[t++])<128)l[n++]=i;else if(4<(o=s[i]))l[n++]=65533,t+=o-1;else{for(i&=2===o?31:3===o?15:7;1<o&&t<a;)i=i<<6|63&e[t++],o--;1<o?l[n++]=65533:i<65536?l[n++]=i:(i-=65536,l[n++]=55296|i>>10&1023,l[n++]=56320|1023&i)}return l.length!==n&&(l.subarray?l=l.subarray(0,n):l.length=n),r.applyFromCharCode(l)}(e=r.transformTo(i.uint8array?"uint8array":"array",e))},r.inherits(c,a),c.prototype.processChunk=function(e){var t=r.transformTo(i.uint8array?"uint8array":"array",e.data);if(this.leftOver&&this.leftOver.length){if(i.uint8array){var o=t;(t=new Uint8Array(o.length+this.leftOver.length)).set(this.leftOver,0),t.set(o,this.leftOver.length)}else t=this.leftOver.concat(t);this.leftOver=null}var a=function(e,t){var n;for((t=t||e.length)>e.length&&(t=e.length),n=t-1;0<=n&&128==(192&e[n]);)n--;return n<0||0===n?t:n+s[e[n]]>t?n:t}(t),l=t;a!==t.length&&(i.uint8array?(l=t.subarray(0,a),this.leftOver=t.subarray(a,t.length)):(l=t.slice(0,a),this.leftOver=t.slice(a,t.length))),this.push({data:n.utf8decode(l),meta:e.meta})},c.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:n.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},n.Utf8DecodeWorker=c,r.inherits(u,a),u.prototype.processChunk=function(e){this.push({data:n.utf8encode(e.data),meta:e.meta})},n.Utf8EncodeWorker=u},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(e,t,n){"use strict";var r=e("./support"),i=e("./base64"),o=e("./nodejsUtils"),a=e("set-immediate-shim"),s=e("./external");function l(e){return e}function c(e,t){for(var n=0;n<e.length;++n)t[n]=255&e.charCodeAt(n);return t}n.newBlob=function(e,t){n.checkSupport("blob");try{return new Blob([e],{type:t})}catch(n){try{var r=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return r.append(e),r.getBlob(t)}catch(e){throw new Error("Bug : can't construct the Blob.")}}};var u={stringifyByChunk:function(e,t,n){var r=[],i=0,o=e.length;if(o<=n)return String.fromCharCode.apply(null,e);for(;i<o;)"array"===t||"nodebuffer"===t?r.push(String.fromCharCode.apply(null,e.slice(i,Math.min(i+n,o)))):r.push(String.fromCharCode.apply(null,e.subarray(i,Math.min(i+n,o)))),i+=n;return r.join("")},stringifyByChar:function(e){for(var t="",n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t},applyCanBeUsed:{uint8array:function(){try{return r.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(e){return!1}}(),nodebuffer:function(){try{return r.nodebuffer&&1===String.fromCharCode.apply(null,o.allocBuffer(1)).length}catch(e){return!1}}()}};function d(e){var t=65536,r=n.getTypeOf(e),i=!0;if("uint8array"===r?i=u.applyCanBeUsed.uint8array:"nodebuffer"===r&&(i=u.applyCanBeUsed.nodebuffer),i)for(;1<t;)try{return u.stringifyByChunk(e,r,t)}catch(e){t=Math.floor(t/2)}return u.stringifyByChar(e)}function f(e,t){for(var n=0;n<e.length;n++)t[n]=e[n];return t}n.applyFromCharCode=d;var h={};h.string={string:l,array:function(e){return c(e,new Array(e.length))},arraybuffer:function(e){return h.string.uint8array(e).buffer},uint8array:function(e){return c(e,new Uint8Array(e.length))},nodebuffer:function(e){return c(e,o.allocBuffer(e.length))}},h.array={string:d,array:l,arraybuffer:function(e){return new Uint8Array(e).buffer},uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return o.newBufferFrom(e)}},h.arraybuffer={string:function(e){return d(new Uint8Array(e))},array:function(e){return f(new Uint8Array(e),new Array(e.byteLength))},arraybuffer:l,uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return o.newBufferFrom(new Uint8Array(e))}},h.uint8array={string:d,array:function(e){return f(e,new Array(e.length))},arraybuffer:function(e){return e.buffer},uint8array:l,nodebuffer:function(e){return o.newBufferFrom(e)}},h.nodebuffer={string:d,array:function(e){return f(e,new Array(e.length))},arraybuffer:function(e){return h.nodebuffer.uint8array(e).buffer},uint8array:function(e){return f(e,new Uint8Array(e.length))},nodebuffer:l},n.transformTo=function(e,t){if(t=t||"",!e)return t;n.checkSupport(e);var r=n.getTypeOf(t);return h[r][e](t)},n.resolve=function(e){for(var t=e.split("/"),n=[],r=0;r<t.length;r++){var i=t[r];"."===i||""===i&&0!==r&&r!==t.length-1||(".."===i?n.pop():n.push(i))}return n.join("/")},n.getTypeOf=function(e){return"string"==typeof e?"string":"[object Array]"===Object.prototype.toString.call(e)?"array":r.nodebuffer&&o.isBuffer(e)?"nodebuffer":r.uint8array&&e instanceof Uint8Array?"uint8array":r.arraybuffer&&e instanceof ArrayBuffer?"arraybuffer":void 0},n.checkSupport=function(e){if(!r[e.toLowerCase()])throw new Error(e+" is not supported by this platform")},n.MAX_VALUE_16BITS=65535,n.MAX_VALUE_32BITS=-1,n.pretty=function(e){var t,n,r="";for(n=0;n<(e||"").length;n++)r+="\\x"+((t=e.charCodeAt(n))<16?"0":"")+t.toString(16).toUpperCase();return r},n.delay=function(e,t,n){a((function(){e.apply(n||null,t||[])}))},n.inherits=function(e,t){function n(){}n.prototype=t.prototype,e.prototype=new n},n.extend=function(){var e,t,n={};for(e=0;e<arguments.length;e++)for(t in arguments[e])arguments[e].hasOwnProperty(t)&&void 0===n[t]&&(n[t]=arguments[e][t]);return n},n.prepareContent=function(e,t,o,a,l){return s.Promise.resolve(t).then((function(e){return r.blob&&(e instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(e)))&&"undefined"!=typeof FileReader?new s.Promise((function(t,n){var r=new FileReader;r.onload=function(e){t(e.target.result)},r.onerror=function(e){n(e.target.error)},r.readAsArrayBuffer(e)})):e})).then((function(t){var u=n.getTypeOf(t);return u?("arraybuffer"===u?t=n.transformTo("uint8array",t):"string"===u&&(l?t=i.decode(t):o&&!0!==a&&(t=function(e){return c(e,r.uint8array?new Uint8Array(e.length):new Array(e.length))}(t))),t):s.Promise.reject(new Error("Can't read the data of '"+e+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))}))}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,"set-immediate-shim":54}],33:[function(e,t,n){"use strict";var r=e("./reader/readerFor"),i=e("./utils"),o=e("./signature"),a=e("./zipEntry"),s=(e("./utf8"),e("./support"));function l(e){this.files=[],this.loadOptions=e}l.prototype={checkSignature:function(e){if(!this.reader.readAndCheckSignature(e)){this.reader.index-=4;var t=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+i.pretty(t)+", expected "+i.pretty(e)+")")}},isSignature:function(e,t){var n=this.reader.index;this.reader.setIndex(e);var r=this.reader.readString(4)===t;return this.reader.setIndex(n),r},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var e=this.reader.readData(this.zipCommentLength),t=s.uint8array?"uint8array":"array",n=i.transformTo(t,e);this.zipComment=this.loadOptions.decodeFileName(n)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var e,t,n,r=this.zip64EndOfCentralSize-44;0<r;)e=this.reader.readInt(2),t=this.reader.readInt(4),n=this.reader.readData(t),this.zip64ExtensibleData[e]={id:e,length:t,value:n}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var e,t;for(e=0;e<this.files.length;e++)t=this.files[e],this.reader.setIndex(t.localHeaderOffset),this.checkSignature(o.LOCAL_FILE_HEADER),t.readLocalPart(this.reader),t.handleUTF8(),t.processAttributes()},readCentralDir:function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(o.CENTRAL_FILE_HEADER);)(e=new a({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(e);if(this.centralDirRecords!==this.files.length&&0!==this.centralDirRecords&&0===this.files.length)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var e=this.reader.lastIndexOfSignature(o.CENTRAL_DIRECTORY_END);if(e<0)throw this.isSignature(0,o.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(e);var t=e;if(this.checkSignature(o.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===i.MAX_VALUE_16BITS||this.diskWithCentralDirStart===i.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===i.MAX_VALUE_16BITS||this.centralDirRecords===i.MAX_VALUE_16BITS||this.centralDirSize===i.MAX_VALUE_32BITS||this.centralDirOffset===i.MAX_VALUE_32BITS){if(this.zip64=!0,(e=this.reader.lastIndexOfSignature(o.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(o.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,o.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(o.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(o.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var n=this.centralDirOffset+this.centralDirSize;this.zip64&&(n+=20,n+=12+this.zip64EndOfCentralSize);var r=t-n;if(0<r)this.isSignature(t,o.CENTRAL_FILE_HEADER)||(this.reader.zero=r);else if(r<0)throw new Error("Corrupted zip: missing "+Math.abs(r)+" bytes.")},prepareReader:function(e){this.reader=r(e)},load:function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},t.exports=l},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utf8":31,"./utils":32,"./zipEntry":34}],34:[function(e,t,n){"use strict";var r=e("./reader/readerFor"),i=e("./utils"),o=e("./compressedObject"),a=e("./crc32"),s=e("./utf8"),l=e("./compressions"),c=e("./support");function u(e,t){this.options=e,this.loadOptions=t}u.prototype={isEncrypted:function(){return 1==(1&this.bitFlag)},useUTF8:function(){return 2048==(2048&this.bitFlag)},readLocalPart:function(e){var t,n;if(e.skip(22),this.fileNameLength=e.readInt(2),n=e.readInt(2),this.fileName=e.readData(this.fileNameLength),e.skip(n),-1===this.compressedSize||-1===this.uncompressedSize)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(null===(t=function(e){for(var t in l)if(l.hasOwnProperty(t)&&l[t].magic===e)return l[t];return null}(this.compressionMethod)))throw new Error("Corrupted zip : compression "+i.pretty(this.compressionMethod)+" unknown (inner file : "+i.transformTo("string",this.fileName)+")");this.decompressed=new o(this.compressedSize,this.uncompressedSize,this.crc32,t,e.readData(this.compressedSize))},readCentralPart:function(e){this.versionMadeBy=e.readInt(2),e.skip(2),this.bitFlag=e.readInt(2),this.compressionMethod=e.readString(2),this.date=e.readDate(),this.crc32=e.readInt(4),this.compressedSize=e.readInt(4),this.uncompressedSize=e.readInt(4);var t=e.readInt(2);if(this.extraFieldsLength=e.readInt(2),this.fileCommentLength=e.readInt(2),this.diskNumberStart=e.readInt(2),this.internalFileAttributes=e.readInt(2),this.externalFileAttributes=e.readInt(4),this.localHeaderOffset=e.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");e.skip(t),this.readExtraFields(e),this.parseZIP64ExtraField(e),this.fileComment=e.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var e=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),0==e&&(this.dosPermissions=63&this.externalFileAttributes),3==e&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(e){if(this.extraFields[1]){var t=r(this.extraFields[1].value);this.uncompressedSize===i.MAX_VALUE_32BITS&&(this.uncompressedSize=t.readInt(8)),this.compressedSize===i.MAX_VALUE_32BITS&&(this.compressedSize=t.readInt(8)),this.localHeaderOffset===i.MAX_VALUE_32BITS&&(this.localHeaderOffset=t.readInt(8)),this.diskNumberStart===i.MAX_VALUE_32BITS&&(this.diskNumberStart=t.readInt(4))}},readExtraFields:function(e){var t,n,r,i=e.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});e.index+4<i;)t=e.readInt(2),n=e.readInt(2),r=e.readData(n),this.extraFields[t]={id:t,length:n,value:r};e.setIndex(i)},handleUTF8:function(){var e=c.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=s.utf8decode(this.fileName),this.fileCommentStr=s.utf8decode(this.fileComment);else{var t=this.findExtraFieldUnicodePath();if(null!==t)this.fileNameStr=t;else{var n=i.transformTo(e,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(n)}var r=this.findExtraFieldUnicodeComment();if(null!==r)this.fileCommentStr=r;else{var o=i.transformTo(e,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(o)}}},findExtraFieldUnicodePath:function(){var e=this.extraFields[28789];if(e){var t=r(e.value);return 1!==t.readInt(1)||a(this.fileName)!==t.readInt(4)?null:s.utf8decode(t.readData(e.length-5))}return null},findExtraFieldUnicodeComment:function(){var e=this.extraFields[25461];if(e){var t=r(e.value);return 1!==t.readInt(1)||a(this.fileComment)!==t.readInt(4)?null:s.utf8decode(t.readData(e.length-5))}return null}},t.exports=u},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(e,t,n){"use strict";function r(e,t,n){this.name=e,this.dir=n.dir,this.date=n.date,this.comment=n.comment,this.unixPermissions=n.unixPermissions,this.dosPermissions=n.dosPermissions,this._data=t,this._dataBinary=n.binary,this.options={compression:n.compression,compressionOptions:n.compressionOptions}}var i=e("./stream/StreamHelper"),o=e("./stream/DataWorker"),a=e("./utf8"),s=e("./compressedObject"),l=e("./stream/GenericWorker");r.prototype={internalStream:function(e){var t=null,n="string";try{if(!e)throw new Error("No output type specified.");var r="string"===(n=e.toLowerCase())||"text"===n;"binarystring"!==n&&"text"!==n||(n="string"),t=this._decompressWorker();var o=!this._dataBinary;o&&!r&&(t=t.pipe(new a.Utf8EncodeWorker)),!o&&r&&(t=t.pipe(new a.Utf8DecodeWorker))}catch(e){(t=new l("error")).error(e)}return new i(t,n,"")},async:function(e,t){return this.internalStream(e).accumulate(t)},nodeStream:function(e,t){return this.internalStream(e||"nodebuffer").toNodejsStream(t)},_compressWorker:function(e,t){if(this._data instanceof s&&this._data.compression.magic===e.magic)return this._data.getCompressedWorker();var n=this._decompressWorker();return this._dataBinary||(n=n.pipe(new a.Utf8EncodeWorker)),s.createWorkerFrom(n,e,t)},_decompressWorker:function(){return this._data instanceof s?this._data.getContentWorker():this._data instanceof l?this._data:new o(this._data)}};for(var c=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],u=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},d=0;d<c.length;d++)r.prototype[c[d]]=u;t.exports=r},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(e,t,r){(function(e){"use strict";var n,r,i=e.MutationObserver||e.WebKitMutationObserver;if(i){var o=0,a=new i(u),s=e.document.createTextNode("");a.observe(s,{characterData:!0}),n=function(){s.data=o=++o%2}}else if(e.setImmediate||void 0===e.MessageChannel)n="document"in e&&"onreadystatechange"in e.document.createElement("script")?function(){var t=e.document.createElement("script");t.onreadystatechange=function(){u(),t.onreadystatechange=null,t.parentNode.removeChild(t),t=null},e.document.documentElement.appendChild(t)}:function(){setTimeout(u,0)};else{var l=new e.MessageChannel;l.port1.onmessage=u,n=function(){l.port2.postMessage(0)}}var c=[];function u(){var e,t;r=!0;for(var n=c.length;n;){for(t=c,c=[],e=-1;++e<n;)t[e]();n=c.length}r=!1}t.exports=function(e){1!==c.push(e)||r||n()}}).call(this,void 0!==n.g?n.g:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],37:[function(e,t,n){"use strict";var r=e("immediate");function i(){}var o={},a=["REJECTED"],s=["FULFILLED"],l=["PENDING"];function c(e){if("function"!=typeof e)throw new TypeError("resolver must be a function");this.state=l,this.queue=[],this.outcome=void 0,e!==i&&h(this,e)}function u(e,t,n){this.promise=e,"function"==typeof t&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),"function"==typeof n&&(this.onRejected=n,this.callRejected=this.otherCallRejected)}function d(e,t,n){r((function(){var r;try{r=t(n)}catch(r){return o.reject(e,r)}r===e?o.reject(e,new TypeError("Cannot resolve promise with itself")):o.resolve(e,r)}))}function f(e){var t=e&&e.then;if(e&&("object"==typeof e||"function"==typeof e)&&"function"==typeof t)return function(){t.apply(e,arguments)}}function h(e,t){var n=!1;function r(t){n||(n=!0,o.reject(e,t))}function i(t){n||(n=!0,o.resolve(e,t))}var a=p((function(){t(i,r)}));"error"===a.status&&r(a.value)}function p(e,t){var n={};try{n.value=e(t),n.status="success"}catch(e){n.status="error",n.value=e}return n}(t.exports=c).prototype.finally=function(e){if("function"!=typeof e)return this;var t=this.constructor;return this.then((function(n){return t.resolve(e()).then((function(){return n}))}),(function(n){return t.resolve(e()).then((function(){throw n}))}))},c.prototype.catch=function(e){return this.then(null,e)},c.prototype.then=function(e,t){if("function"!=typeof e&&this.state===s||"function"!=typeof t&&this.state===a)return this;var n=new this.constructor(i);return this.state!==l?d(n,this.state===s?e:t,this.outcome):this.queue.push(new u(n,e,t)),n},u.prototype.callFulfilled=function(e){o.resolve(this.promise,e)},u.prototype.otherCallFulfilled=function(e){d(this.promise,this.onFulfilled,e)},u.prototype.callRejected=function(e){o.reject(this.promise,e)},u.prototype.otherCallRejected=function(e){d(this.promise,this.onRejected,e)},o.resolve=function(e,t){var n=p(f,t);if("error"===n.status)return o.reject(e,n.value);var r=n.value;if(r)h(e,r);else{e.state=s,e.outcome=t;for(var i=-1,a=e.queue.length;++i<a;)e.queue[i].callFulfilled(t)}return e},o.reject=function(e,t){e.state=a,e.outcome=t;for(var n=-1,r=e.queue.length;++n<r;)e.queue[n].callRejected(t);return e},c.resolve=function(e){return e instanceof this?e:o.resolve(new this(i),e)},c.reject=function(e){var t=new this(i);return o.reject(t,e)},c.all=function(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);for(var a=new Array(n),s=0,l=-1,c=new this(i);++l<n;)u(e[l],l);return c;function u(e,i){t.resolve(e).then((function(e){a[i]=e,++s!==n||r||(r=!0,o.resolve(c,a))}),(function(e){r||(r=!0,o.reject(c,e))}))}},c.race=function(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);for(var a,s=-1,l=new this(i);++s<n;)a=e[s],t.resolve(a).then((function(e){r||(r=!0,o.resolve(l,e))}),(function(e){r||(r=!0,o.reject(l,e))}));return l}},{immediate:36}],38:[function(e,t,n){"use strict";var r={};(0,e("./lib/utils/common").assign)(r,e("./lib/deflate"),e("./lib/inflate"),e("./lib/zlib/constants")),t.exports=r},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(e,t,n){"use strict";var r=e("./zlib/deflate"),i=e("./utils/common"),o=e("./utils/strings"),a=e("./zlib/messages"),s=e("./zlib/zstream"),l=Object.prototype.toString,c=0,u=-1,d=0,f=8;function h(e){if(!(this instanceof h))return new h(e);this.options=i.assign({level:u,method:f,chunkSize:16384,windowBits:15,memLevel:8,strategy:d,to:""},e||{});var t=this.options;t.raw&&0<t.windowBits?t.windowBits=-t.windowBits:t.gzip&&0<t.windowBits&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new s,this.strm.avail_out=0;var n=r.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(n!==c)throw new Error(a[n]);if(t.header&&r.deflateSetHeader(this.strm,t.header),t.dictionary){var p;if(p="string"==typeof t.dictionary?o.string2buf(t.dictionary):"[object ArrayBuffer]"===l.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(n=r.deflateSetDictionary(this.strm,p))!==c)throw new Error(a[n]);this._dict_set=!0}}function p(e,t){var n=new h(t);if(n.push(e,!0),n.err)throw n.msg||a[n.err];return n.result}h.prototype.push=function(e,t){var n,a,s=this.strm,u=this.options.chunkSize;if(this.ended)return!1;a=t===~~t?t:!0===t?4:0,"string"==typeof e?s.input=o.string2buf(e):"[object ArrayBuffer]"===l.call(e)?s.input=new Uint8Array(e):s.input=e,s.next_in=0,s.avail_in=s.input.length;do{if(0===s.avail_out&&(s.output=new i.Buf8(u),s.next_out=0,s.avail_out=u),1!==(n=r.deflate(s,a))&&n!==c)return this.onEnd(n),!(this.ended=!0);0!==s.avail_out&&(0!==s.avail_in||4!==a&&2!==a)||("string"===this.options.to?this.onData(o.buf2binstring(i.shrinkBuf(s.output,s.next_out))):this.onData(i.shrinkBuf(s.output,s.next_out)))}while((0<s.avail_in||0===s.avail_out)&&1!==n);return 4===a?(n=r.deflateEnd(this.strm),this.onEnd(n),this.ended=!0,n===c):2!==a||(this.onEnd(c),!(s.avail_out=0))},h.prototype.onData=function(e){this.chunks.push(e)},h.prototype.onEnd=function(e){e===c&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},n.Deflate=h,n.deflate=p,n.deflateRaw=function(e,t){return(t=t||{}).raw=!0,p(e,t)},n.gzip=function(e,t){return(t=t||{}).gzip=!0,p(e,t)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(e,t,n){"use strict";var r=e("./zlib/inflate"),i=e("./utils/common"),o=e("./utils/strings"),a=e("./zlib/constants"),s=e("./zlib/messages"),l=e("./zlib/zstream"),c=e("./zlib/gzheader"),u=Object.prototype.toString;function d(e){if(!(this instanceof d))return new d(e);this.options=i.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&0<=t.windowBits&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(0<=t.windowBits&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),15<t.windowBits&&t.windowBits<48&&0==(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new l,this.strm.avail_out=0;var n=r.inflateInit2(this.strm,t.windowBits);if(n!==a.Z_OK)throw new Error(s[n]);this.header=new c,r.inflateGetHeader(this.strm,this.header)}function f(e,t){var n=new d(t);if(n.push(e,!0),n.err)throw n.msg||s[n.err];return n.result}d.prototype.push=function(e,t){var n,s,l,c,d,f,h=this.strm,p=this.options.chunkSize,_=this.options.dictionary,m=!1;if(this.ended)return!1;s=t===~~t?t:!0===t?a.Z_FINISH:a.Z_NO_FLUSH,"string"==typeof e?h.input=o.binstring2buf(e):"[object ArrayBuffer]"===u.call(e)?h.input=new Uint8Array(e):h.input=e,h.next_in=0,h.avail_in=h.input.length;do{if(0===h.avail_out&&(h.output=new i.Buf8(p),h.next_out=0,h.avail_out=p),(n=r.inflate(h,a.Z_NO_FLUSH))===a.Z_NEED_DICT&&_&&(f="string"==typeof _?o.string2buf(_):"[object ArrayBuffer]"===u.call(_)?new Uint8Array(_):_,n=r.inflateSetDictionary(this.strm,f)),n===a.Z_BUF_ERROR&&!0===m&&(n=a.Z_OK,m=!1),n!==a.Z_STREAM_END&&n!==a.Z_OK)return this.onEnd(n),!(this.ended=!0);h.next_out&&(0!==h.avail_out&&n!==a.Z_STREAM_END&&(0!==h.avail_in||s!==a.Z_FINISH&&s!==a.Z_SYNC_FLUSH)||("string"===this.options.to?(l=o.utf8border(h.output,h.next_out),c=h.next_out-l,d=o.buf2string(h.output,l),h.next_out=c,h.avail_out=p-c,c&&i.arraySet(h.output,h.output,l,c,0),this.onData(d)):this.onData(i.shrinkBuf(h.output,h.next_out)))),0===h.avail_in&&0===h.avail_out&&(m=!0)}while((0<h.avail_in||0===h.avail_out)&&n!==a.Z_STREAM_END);return n===a.Z_STREAM_END&&(s=a.Z_FINISH),s===a.Z_FINISH?(n=r.inflateEnd(this.strm),this.onEnd(n),this.ended=!0,n===a.Z_OK):s!==a.Z_SYNC_FLUSH||(this.onEnd(a.Z_OK),!(h.avail_out=0))},d.prototype.onData=function(e){this.chunks.push(e)},d.prototype.onEnd=function(e){e===a.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},n.Inflate=d,n.inflate=f,n.inflateRaw=function(e,t){return(t=t||{}).raw=!0,f(e,t)},n.ungzip=f},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(e,t,n){"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;n.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var n=t.shift();if(n){if("object"!=typeof n)throw new TypeError(n+"must be non-object");for(var r in n)n.hasOwnProperty(r)&&(e[r]=n[r])}}return e},n.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var i={arraySet:function(e,t,n,r,i){if(t.subarray&&e.subarray)e.set(t.subarray(n,n+r),i);else for(var o=0;o<r;o++)e[i+o]=t[n+o]},flattenChunks:function(e){var t,n,r,i,o,a;for(t=r=0,n=e.length;t<n;t++)r+=e[t].length;for(a=new Uint8Array(r),t=i=0,n=e.length;t<n;t++)o=e[t],a.set(o,i),i+=o.length;return a}},o={arraySet:function(e,t,n,r,i){for(var o=0;o<r;o++)e[i+o]=t[n+o]},flattenChunks:function(e){return[].concat.apply([],e)}};n.setTyped=function(e){e?(n.Buf8=Uint8Array,n.Buf16=Uint16Array,n.Buf32=Int32Array,n.assign(n,i)):(n.Buf8=Array,n.Buf16=Array,n.Buf32=Array,n.assign(n,o))},n.setTyped(r)},{}],42:[function(e,t,n){"use strict";var r=e("./common"),i=!0,o=!0;try{String.fromCharCode.apply(null,[0])}catch(e){i=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(e){o=!1}for(var a=new r.Buf8(256),s=0;s<256;s++)a[s]=252<=s?6:248<=s?5:240<=s?4:224<=s?3:192<=s?2:1;function l(e,t){if(t<65537&&(e.subarray&&o||!e.subarray&&i))return String.fromCharCode.apply(null,r.shrinkBuf(e,t));for(var n="",a=0;a<t;a++)n+=String.fromCharCode(e[a]);return n}a[254]=a[254]=1,n.string2buf=function(e){var t,n,i,o,a,s=e.length,l=0;for(o=0;o<s;o++)55296==(64512&(n=e.charCodeAt(o)))&&o+1<s&&56320==(64512&(i=e.charCodeAt(o+1)))&&(n=65536+(n-55296<<10)+(i-56320),o++),l+=n<128?1:n<2048?2:n<65536?3:4;for(t=new r.Buf8(l),o=a=0;a<l;o++)55296==(64512&(n=e.charCodeAt(o)))&&o+1<s&&56320==(64512&(i=e.charCodeAt(o+1)))&&(n=65536+(n-55296<<10)+(i-56320),o++),n<128?t[a++]=n:(n<2048?t[a++]=192|n>>>6:(n<65536?t[a++]=224|n>>>12:(t[a++]=240|n>>>18,t[a++]=128|n>>>12&63),t[a++]=128|n>>>6&63),t[a++]=128|63&n);return t},n.buf2binstring=function(e){return l(e,e.length)},n.binstring2buf=function(e){for(var t=new r.Buf8(e.length),n=0,i=t.length;n<i;n++)t[n]=e.charCodeAt(n);return t},n.buf2string=function(e,t){var n,r,i,o,s=t||e.length,c=new Array(2*s);for(n=r=0;n<s;)if((i=e[n++])<128)c[r++]=i;else if(4<(o=a[i]))c[r++]=65533,n+=o-1;else{for(i&=2===o?31:3===o?15:7;1<o&&n<s;)i=i<<6|63&e[n++],o--;1<o?c[r++]=65533:i<65536?c[r++]=i:(i-=65536,c[r++]=55296|i>>10&1023,c[r++]=56320|1023&i)}return l(c,r)},n.utf8border=function(e,t){var n;for((t=t||e.length)>e.length&&(t=e.length),n=t-1;0<=n&&128==(192&e[n]);)n--;return n<0||0===n?t:n+a[e[n]]>t?n:t}},{"./common":41}],43:[function(e,t,n){"use strict";t.exports=function(e,t,n,r){for(var i=65535&e|0,o=e>>>16&65535|0,a=0;0!==n;){for(n-=a=2e3<n?2e3:n;o=o+(i=i+t[r++]|0)|0,--a;);i%=65521,o%=65521}return i|o<<16|0}},{}],44:[function(e,t,n){"use strict";t.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],45:[function(e,t,n){"use strict";var r=function(){for(var e,t=[],n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}();t.exports=function(e,t,n,i){var o=r,a=i+n;e^=-1;for(var s=i;s<a;s++)e=e>>>8^o[255&(e^t[s])];return-1^e}},{}],46:[function(e,t,n){"use strict";var r,i=e("../utils/common"),o=e("./trees"),a=e("./adler32"),s=e("./crc32"),l=e("./messages"),c=0,u=4,d=0,f=-2,h=-1,p=4,_=2,m=8,v=9,g=286,b=30,y=19,w=2*g+1,k=15,x=3,S=258,C=S+x+1,E=42,A=113,O=1,I=2,T=3,z=4;function F(e,t){return e.msg=l[t],t}function R(e){return(e<<1)-(4<e?9:0)}function P(e){for(var t=e.length;0<=--t;)e[t]=0}function B(e){var t=e.state,n=t.pending;n>e.avail_out&&(n=e.avail_out),0!==n&&(i.arraySet(e.output,t.pending_buf,t.pending_out,n,e.next_out),e.next_out+=n,t.pending_out+=n,e.total_out+=n,e.avail_out-=n,t.pending-=n,0===t.pending&&(t.pending_out=0))}function L(e,t){o._tr_flush_block(e,0<=e.block_start?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,B(e.strm)}function D(e,t){e.pending_buf[e.pending++]=t}function U(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function j(e,t){var n,r,i=e.max_chain_length,o=e.strstart,a=e.prev_length,s=e.nice_match,l=e.strstart>e.w_size-C?e.strstart-(e.w_size-C):0,c=e.window,u=e.w_mask,d=e.prev,f=e.strstart+S,h=c[o+a-1],p=c[o+a];e.prev_length>=e.good_match&&(i>>=2),s>e.lookahead&&(s=e.lookahead);do{if(c[(n=t)+a]===p&&c[n+a-1]===h&&c[n]===c[o]&&c[++n]===c[o+1]){o+=2,n++;do{}while(c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&o<f);if(r=S-(f-o),o=f-S,a<r){if(e.match_start=t,s<=(a=r))break;h=c[o+a-1],p=c[o+a]}}}while((t=d[t&u])>l&&0!=--i);return a<=e.lookahead?a:e.lookahead}function $(e){var t,n,r,o,l,c,u,d,f,h,p=e.w_size;do{if(o=e.window_size-e.lookahead-e.strstart,e.strstart>=p+(p-C)){for(i.arraySet(e.window,e.window,p,p,0),e.match_start-=p,e.strstart-=p,e.block_start-=p,t=n=e.hash_size;r=e.head[--t],e.head[t]=p<=r?r-p:0,--n;);for(t=n=p;r=e.prev[--t],e.prev[t]=p<=r?r-p:0,--n;);o+=p}if(0===e.strm.avail_in)break;if(c=e.strm,u=e.window,d=e.strstart+e.lookahead,h=void 0,(f=o)<(h=c.avail_in)&&(h=f),n=0===h?0:(c.avail_in-=h,i.arraySet(u,c.input,c.next_in,h,d),1===c.state.wrap?c.adler=a(c.adler,u,h,d):2===c.state.wrap&&(c.adler=s(c.adler,u,h,d)),c.next_in+=h,c.total_in+=h,h),e.lookahead+=n,e.lookahead+e.insert>=x)for(l=e.strstart-e.insert,e.ins_h=e.window[l],e.ins_h=(e.ins_h<<e.hash_shift^e.window[l+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[l+x-1])&e.hash_mask,e.prev[l&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=l,l++,e.insert--,!(e.lookahead+e.insert<x)););}while(e.lookahead<C&&0!==e.strm.avail_in)}function N(e,t){for(var n,r;;){if(e.lookahead<C){if($(e),e.lookahead<C&&t===c)return O;if(0===e.lookahead)break}if(n=0,e.lookahead>=x&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+x-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==n&&e.strstart-n<=e.w_size-C&&(e.match_length=j(e,n)),e.match_length>=x)if(r=o._tr_tally(e,e.strstart-e.match_start,e.match_length-x),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=x){for(e.match_length--;e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+x-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart,0!=--e.match_length;);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else r=o._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(r&&(L(e,!1),0===e.strm.avail_out))return O}return e.insert=e.strstart<x-1?e.strstart:x-1,t===u?(L(e,!0),0===e.strm.avail_out?T:z):e.last_lit&&(L(e,!1),0===e.strm.avail_out)?O:I}function M(e,t){for(var n,r,i;;){if(e.lookahead<C){if($(e),e.lookahead<C&&t===c)return O;if(0===e.lookahead)break}if(n=0,e.lookahead>=x&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+x-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=x-1,0!==n&&e.prev_length<e.max_lazy_match&&e.strstart-n<=e.w_size-C&&(e.match_length=j(e,n),e.match_length<=5&&(1===e.strategy||e.match_length===x&&4096<e.strstart-e.match_start)&&(e.match_length=x-1)),e.prev_length>=x&&e.match_length<=e.prev_length){for(i=e.strstart+e.lookahead-x,r=o._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-x),e.lookahead-=e.prev_length-1,e.prev_length-=2;++e.strstart<=i&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+x-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!=--e.prev_length;);if(e.match_available=0,e.match_length=x-1,e.strstart++,r&&(L(e,!1),0===e.strm.avail_out))return O}else if(e.match_available){if((r=o._tr_tally(e,0,e.window[e.strstart-1]))&&L(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return O}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(r=o._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<x-1?e.strstart:x-1,t===u?(L(e,!0),0===e.strm.avail_out?T:z):e.last_lit&&(L(e,!1),0===e.strm.avail_out)?O:I}function W(e,t,n,r,i){this.good_length=e,this.max_lazy=t,this.nice_length=n,this.max_chain=r,this.func=i}function V(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=m,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new i.Buf16(2*w),this.dyn_dtree=new i.Buf16(2*(2*b+1)),this.bl_tree=new i.Buf16(2*(2*y+1)),P(this.dyn_ltree),P(this.dyn_dtree),P(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new i.Buf16(k+1),this.heap=new i.Buf16(2*g+1),P(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new i.Buf16(2*g+1),P(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function Z(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=_,(t=e.state).pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?E:A,e.adler=2===t.wrap?0:1,t.last_flush=c,o._tr_init(t),d):F(e,f)}function H(e){var t=Z(e);return t===d&&function(e){e.window_size=2*e.w_size,P(e.head),e.max_lazy_match=r[e.level].max_lazy,e.good_match=r[e.level].good_length,e.nice_match=r[e.level].nice_length,e.max_chain_length=r[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=x-1,e.match_available=0,e.ins_h=0}(e.state),t}function q(e,t,n,r,o,a){if(!e)return f;var s=1;if(t===h&&(t=6),r<0?(s=0,r=-r):15<r&&(s=2,r-=16),o<1||v<o||n!==m||r<8||15<r||t<0||9<t||a<0||p<a)return F(e,f);8===r&&(r=9);var l=new V;return(e.state=l).strm=e,l.wrap=s,l.gzhead=null,l.w_bits=r,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=o+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+x-1)/x),l.window=new i.Buf8(2*l.w_size),l.head=new i.Buf16(l.hash_size),l.prev=new i.Buf16(l.w_size),l.lit_bufsize=1<<o+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new i.Buf8(l.pending_buf_size),l.d_buf=1*l.lit_bufsize,l.l_buf=3*l.lit_bufsize,l.level=t,l.strategy=a,l.method=n,H(e)}r=[new W(0,0,0,0,(function(e,t){var n=65535;for(n>e.pending_buf_size-5&&(n=e.pending_buf_size-5);;){if(e.lookahead<=1){if($(e),0===e.lookahead&&t===c)return O;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var r=e.block_start+n;if((0===e.strstart||e.strstart>=r)&&(e.lookahead=e.strstart-r,e.strstart=r,L(e,!1),0===e.strm.avail_out))return O;if(e.strstart-e.block_start>=e.w_size-C&&(L(e,!1),0===e.strm.avail_out))return O}return e.insert=0,t===u?(L(e,!0),0===e.strm.avail_out?T:z):(e.strstart>e.block_start&&(L(e,!1),e.strm.avail_out),O)})),new W(4,4,8,4,N),new W(4,5,16,8,N),new W(4,6,32,32,N),new W(4,4,16,16,M),new W(8,16,32,32,M),new W(8,16,128,128,M),new W(8,32,128,256,M),new W(32,128,258,1024,M),new W(32,258,258,4096,M)],n.deflateInit=function(e,t){return q(e,t,m,15,8,0)},n.deflateInit2=q,n.deflateReset=H,n.deflateResetKeep=Z,n.deflateSetHeader=function(e,t){return e&&e.state?2!==e.state.wrap?f:(e.state.gzhead=t,d):f},n.deflate=function(e,t){var n,i,a,l;if(!e||!e.state||5<t||t<0)return e?F(e,f):f;if(i=e.state,!e.output||!e.input&&0!==e.avail_in||666===i.status&&t!==u)return F(e,0===e.avail_out?-5:f);if(i.strm=e,n=i.last_flush,i.last_flush=t,i.status===E)if(2===i.wrap)e.adler=0,D(i,31),D(i,139),D(i,8),i.gzhead?(D(i,(i.gzhead.text?1:0)+(i.gzhead.hcrc?2:0)+(i.gzhead.extra?4:0)+(i.gzhead.name?8:0)+(i.gzhead.comment?16:0)),D(i,255&i.gzhead.time),D(i,i.gzhead.time>>8&255),D(i,i.gzhead.time>>16&255),D(i,i.gzhead.time>>24&255),D(i,9===i.level?2:2<=i.strategy||i.level<2?4:0),D(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(D(i,255&i.gzhead.extra.length),D(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(e.adler=s(e.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=69):(D(i,0),D(i,0),D(i,0),D(i,0),D(i,0),D(i,9===i.level?2:2<=i.strategy||i.level<2?4:0),D(i,3),i.status=A);else{var h=m+(i.w_bits-8<<4)<<8;h|=(2<=i.strategy||i.level<2?0:i.level<6?1:6===i.level?2:3)<<6,0!==i.strstart&&(h|=32),h+=31-h%31,i.status=A,U(i,h),0!==i.strstart&&(U(i,e.adler>>>16),U(i,65535&e.adler)),e.adler=1}if(69===i.status)if(i.gzhead.extra){for(a=i.pending;i.gzindex<(65535&i.gzhead.extra.length)&&(i.pending!==i.pending_buf_size||(i.gzhead.hcrc&&i.pending>a&&(e.adler=s(e.adler,i.pending_buf,i.pending-a,a)),B(e),a=i.pending,i.pending!==i.pending_buf_size));)D(i,255&i.gzhead.extra[i.gzindex]),i.gzindex++;i.gzhead.hcrc&&i.pending>a&&(e.adler=s(e.adler,i.pending_buf,i.pending-a,a)),i.gzindex===i.gzhead.extra.length&&(i.gzindex=0,i.status=73)}else i.status=73;if(73===i.status)if(i.gzhead.name){a=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>a&&(e.adler=s(e.adler,i.pending_buf,i.pending-a,a)),B(e),a=i.pending,i.pending===i.pending_buf_size)){l=1;break}l=i.gzindex<i.gzhead.name.length?255&i.gzhead.name.charCodeAt(i.gzindex++):0,D(i,l)}while(0!==l);i.gzhead.hcrc&&i.pending>a&&(e.adler=s(e.adler,i.pending_buf,i.pending-a,a)),0===l&&(i.gzindex=0,i.status=91)}else i.status=91;if(91===i.status)if(i.gzhead.comment){a=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>a&&(e.adler=s(e.adler,i.pending_buf,i.pending-a,a)),B(e),a=i.pending,i.pending===i.pending_buf_size)){l=1;break}l=i.gzindex<i.gzhead.comment.length?255&i.gzhead.comment.charCodeAt(i.gzindex++):0,D(i,l)}while(0!==l);i.gzhead.hcrc&&i.pending>a&&(e.adler=s(e.adler,i.pending_buf,i.pending-a,a)),0===l&&(i.status=103)}else i.status=103;if(103===i.status&&(i.gzhead.hcrc?(i.pending+2>i.pending_buf_size&&B(e),i.pending+2<=i.pending_buf_size&&(D(i,255&e.adler),D(i,e.adler>>8&255),e.adler=0,i.status=A)):i.status=A),0!==i.pending){if(B(e),0===e.avail_out)return i.last_flush=-1,d}else if(0===e.avail_in&&R(t)<=R(n)&&t!==u)return F(e,-5);if(666===i.status&&0!==e.avail_in)return F(e,-5);if(0!==e.avail_in||0!==i.lookahead||t!==c&&666!==i.status){var p=2===i.strategy?function(e,t){for(var n;;){if(0===e.lookahead&&($(e),0===e.lookahead)){if(t===c)return O;break}if(e.match_length=0,n=o._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,n&&(L(e,!1),0===e.strm.avail_out))return O}return e.insert=0,t===u?(L(e,!0),0===e.strm.avail_out?T:z):e.last_lit&&(L(e,!1),0===e.strm.avail_out)?O:I}(i,t):3===i.strategy?function(e,t){for(var n,r,i,a,s=e.window;;){if(e.lookahead<=S){if($(e),e.lookahead<=S&&t===c)return O;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=x&&0<e.strstart&&(r=s[i=e.strstart-1])===s[++i]&&r===s[++i]&&r===s[++i]){a=e.strstart+S;do{}while(r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&r===s[++i]&&i<a);e.match_length=S-(a-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=x?(n=o._tr_tally(e,1,e.match_length-x),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=o._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(L(e,!1),0===e.strm.avail_out))return O}return e.insert=0,t===u?(L(e,!0),0===e.strm.avail_out?T:z):e.last_lit&&(L(e,!1),0===e.strm.avail_out)?O:I}(i,t):r[i.level].func(i,t);if(p!==T&&p!==z||(i.status=666),p===O||p===T)return 0===e.avail_out&&(i.last_flush=-1),d;if(p===I&&(1===t?o._tr_align(i):5!==t&&(o._tr_stored_block(i,0,0,!1),3===t&&(P(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),B(e),0===e.avail_out))return i.last_flush=-1,d}return t!==u?d:i.wrap<=0?1:(2===i.wrap?(D(i,255&e.adler),D(i,e.adler>>8&255),D(i,e.adler>>16&255),D(i,e.adler>>24&255),D(i,255&e.total_in),D(i,e.total_in>>8&255),D(i,e.total_in>>16&255),D(i,e.total_in>>24&255)):(U(i,e.adler>>>16),U(i,65535&e.adler)),B(e),0<i.wrap&&(i.wrap=-i.wrap),0!==i.pending?d:1)},n.deflateEnd=function(e){var t;return e&&e.state?(t=e.state.status)!==E&&69!==t&&73!==t&&91!==t&&103!==t&&t!==A&&666!==t?F(e,f):(e.state=null,t===A?F(e,-3):d):f},n.deflateSetDictionary=function(e,t){var n,r,o,s,l,c,u,h,p=t.length;if(!e||!e.state)return f;if(2===(s=(n=e.state).wrap)||1===s&&n.status!==E||n.lookahead)return f;for(1===s&&(e.adler=a(e.adler,t,p,0)),n.wrap=0,p>=n.w_size&&(0===s&&(P(n.head),n.strstart=0,n.block_start=0,n.insert=0),h=new i.Buf8(n.w_size),i.arraySet(h,t,p-n.w_size,n.w_size,0),t=h,p=n.w_size),l=e.avail_in,c=e.next_in,u=e.input,e.avail_in=p,e.next_in=0,e.input=t,$(n);n.lookahead>=x;){for(r=n.strstart,o=n.lookahead-(x-1);n.ins_h=(n.ins_h<<n.hash_shift^n.window[r+x-1])&n.hash_mask,n.prev[r&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=r,r++,--o;);n.strstart=r,n.lookahead=x-1,$(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=x-1,n.match_available=0,e.next_in=c,e.input=u,e.avail_in=l,n.wrap=s,d},n.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(e,t,n){"use strict";t.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],48:[function(e,t,n){"use strict";t.exports=function(e,t){var n,r,i,o,a,s,l,c,u,d,f,h,p,_,m,v,g,b,y,w,k,x,S,C,E;n=e.state,r=e.next_in,C=e.input,i=r+(e.avail_in-5),o=e.next_out,E=e.output,a=o-(t-e.avail_out),s=o+(e.avail_out-257),l=n.dmax,c=n.wsize,u=n.whave,d=n.wnext,f=n.window,h=n.hold,p=n.bits,_=n.lencode,m=n.distcode,v=(1<<n.lenbits)-1,g=(1<<n.distbits)-1;e:do{p<15&&(h+=C[r++]<<p,p+=8,h+=C[r++]<<p,p+=8),b=_[h&v];t:for(;;){if(h>>>=y=b>>>24,p-=y,0==(y=b>>>16&255))E[o++]=65535&b;else{if(!(16&y)){if(0==(64&y)){b=_[(65535&b)+(h&(1<<y)-1)];continue t}if(32&y){n.mode=12;break e}e.msg="invalid literal/length code",n.mode=30;break e}w=65535&b,(y&=15)&&(p<y&&(h+=C[r++]<<p,p+=8),w+=h&(1<<y)-1,h>>>=y,p-=y),p<15&&(h+=C[r++]<<p,p+=8,h+=C[r++]<<p,p+=8),b=m[h&g];n:for(;;){if(h>>>=y=b>>>24,p-=y,!(16&(y=b>>>16&255))){if(0==(64&y)){b=m[(65535&b)+(h&(1<<y)-1)];continue n}e.msg="invalid distance code",n.mode=30;break e}if(k=65535&b,p<(y&=15)&&(h+=C[r++]<<p,(p+=8)<y&&(h+=C[r++]<<p,p+=8)),l<(k+=h&(1<<y)-1)){e.msg="invalid distance too far back",n.mode=30;break e}if(h>>>=y,p-=y,(y=o-a)<k){if(u<(y=k-y)&&n.sane){e.msg="invalid distance too far back",n.mode=30;break e}if(S=f,(x=0)===d){if(x+=c-y,y<w){for(w-=y;E[o++]=f[x++],--y;);x=o-k,S=E}}else if(d<y){if(x+=c+d-y,(y-=d)<w){for(w-=y;E[o++]=f[x++],--y;);if(x=0,d<w){for(w-=y=d;E[o++]=f[x++],--y;);x=o-k,S=E}}}else if(x+=d-y,y<w){for(w-=y;E[o++]=f[x++],--y;);x=o-k,S=E}for(;2<w;)E[o++]=S[x++],E[o++]=S[x++],E[o++]=S[x++],w-=3;w&&(E[o++]=S[x++],1<w&&(E[o++]=S[x++]))}else{for(x=o-k;E[o++]=E[x++],E[o++]=E[x++],E[o++]=E[x++],2<(w-=3););w&&(E[o++]=E[x++],1<w&&(E[o++]=E[x++]))}break}}break}}while(r<i&&o<s);r-=w=p>>3,h&=(1<<(p-=w<<3))-1,e.next_in=r,e.next_out=o,e.avail_in=r<i?i-r+5:5-(r-i),e.avail_out=o<s?s-o+257:257-(o-s),n.hold=h,n.bits=p}},{}],49:[function(e,t,n){"use strict";var r=e("../utils/common"),i=e("./adler32"),o=e("./crc32"),a=e("./inffast"),s=e("./inftrees"),l=1,c=2,u=0,d=-2,f=1,h=852,p=592;function _(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function m(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new r.Buf16(320),this.work=new r.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function v(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=f,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new r.Buf32(h),t.distcode=t.distdyn=new r.Buf32(p),t.sane=1,t.back=-1,u):d}function g(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,v(e)):d}function b(e,t){var n,r;return e&&e.state?(r=e.state,t<0?(n=0,t=-t):(n=1+(t>>4),t<48&&(t&=15)),t&&(t<8||15<t)?d:(null!==r.window&&r.wbits!==t&&(r.window=null),r.wrap=n,r.wbits=t,g(e))):d}function y(e,t){var n,r;return e?(r=new m,(e.state=r).window=null,(n=b(e,t))!==u&&(e.state=null),n):d}var w,k,x=!0;function S(e){if(x){var t;for(w=new r.Buf32(512),k=new r.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(s(l,e.lens,0,288,w,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;s(c,e.lens,0,32,k,0,e.work,{bits:5}),x=!1}e.lencode=w,e.lenbits=9,e.distcode=k,e.distbits=5}function C(e,t,n,i){var o,a=e.state;return null===a.window&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new r.Buf8(a.wsize)),i>=a.wsize?(r.arraySet(a.window,t,n-a.wsize,a.wsize,0),a.wnext=0,a.whave=a.wsize):(i<(o=a.wsize-a.wnext)&&(o=i),r.arraySet(a.window,t,n-i,o,a.wnext),(i-=o)?(r.arraySet(a.window,t,n-i,i,0),a.wnext=i,a.whave=a.wsize):(a.wnext+=o,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=o))),0}n.inflateReset=g,n.inflateReset2=b,n.inflateResetKeep=v,n.inflateInit=function(e){return y(e,15)},n.inflateInit2=y,n.inflate=function(e,t){var n,h,p,m,v,g,b,y,w,k,x,E,A,O,I,T,z,F,R,P,B,L,D,U,j=0,$=new r.Buf8(4),N=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return d;12===(n=e.state).mode&&(n.mode=13),v=e.next_out,p=e.output,b=e.avail_out,m=e.next_in,h=e.input,g=e.avail_in,y=n.hold,w=n.bits,k=g,x=b,L=u;e:for(;;)switch(n.mode){case f:if(0===n.wrap){n.mode=13;break}for(;w<16;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(2&n.wrap&&35615===y){$[n.check=0]=255&y,$[1]=y>>>8&255,n.check=o(n.check,$,2,0),w=y=0,n.mode=2;break}if(n.flags=0,n.head&&(n.head.done=!1),!(1&n.wrap)||(((255&y)<<8)+(y>>8))%31){e.msg="incorrect header check",n.mode=30;break}if(8!=(15&y)){e.msg="unknown compression method",n.mode=30;break}if(w-=4,B=8+(15&(y>>>=4)),0===n.wbits)n.wbits=B;else if(B>n.wbits){e.msg="invalid window size",n.mode=30;break}n.dmax=1<<B,e.adler=n.check=1,n.mode=512&y?10:12,w=y=0;break;case 2:for(;w<16;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(n.flags=y,8!=(255&n.flags)){e.msg="unknown compression method",n.mode=30;break}if(57344&n.flags){e.msg="unknown header flags set",n.mode=30;break}n.head&&(n.head.text=y>>8&1),512&n.flags&&($[0]=255&y,$[1]=y>>>8&255,n.check=o(n.check,$,2,0)),w=y=0,n.mode=3;case 3:for(;w<32;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}n.head&&(n.head.time=y),512&n.flags&&($[0]=255&y,$[1]=y>>>8&255,$[2]=y>>>16&255,$[3]=y>>>24&255,n.check=o(n.check,$,4,0)),w=y=0,n.mode=4;case 4:for(;w<16;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}n.head&&(n.head.xflags=255&y,n.head.os=y>>8),512&n.flags&&($[0]=255&y,$[1]=y>>>8&255,n.check=o(n.check,$,2,0)),w=y=0,n.mode=5;case 5:if(1024&n.flags){for(;w<16;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}n.length=y,n.head&&(n.head.extra_len=y),512&n.flags&&($[0]=255&y,$[1]=y>>>8&255,n.check=o(n.check,$,2,0)),w=y=0}else n.head&&(n.head.extra=null);n.mode=6;case 6:if(1024&n.flags&&(g<(E=n.length)&&(E=g),E&&(n.head&&(B=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Array(n.head.extra_len)),r.arraySet(n.head.extra,h,m,E,B)),512&n.flags&&(n.check=o(n.check,h,E,m)),g-=E,m+=E,n.length-=E),n.length))break e;n.length=0,n.mode=7;case 7:if(2048&n.flags){if(0===g)break e;for(E=0;B=h[m+E++],n.head&&B&&n.length<65536&&(n.head.name+=String.fromCharCode(B)),B&&E<g;);if(512&n.flags&&(n.check=o(n.check,h,E,m)),g-=E,m+=E,B)break e}else n.head&&(n.head.name=null);n.length=0,n.mode=8;case 8:if(4096&n.flags){if(0===g)break e;for(E=0;B=h[m+E++],n.head&&B&&n.length<65536&&(n.head.comment+=String.fromCharCode(B)),B&&E<g;);if(512&n.flags&&(n.check=o(n.check,h,E,m)),g-=E,m+=E,B)break e}else n.head&&(n.head.comment=null);n.mode=9;case 9:if(512&n.flags){for(;w<16;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(y!==(65535&n.check)){e.msg="header crc mismatch",n.mode=30;break}w=y=0}n.head&&(n.head.hcrc=n.flags>>9&1,n.head.done=!0),e.adler=n.check=0,n.mode=12;break;case 10:for(;w<32;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}e.adler=n.check=_(y),w=y=0,n.mode=11;case 11:if(0===n.havedict)return e.next_out=v,e.avail_out=b,e.next_in=m,e.avail_in=g,n.hold=y,n.bits=w,2;e.adler=n.check=1,n.mode=12;case 12:if(5===t||6===t)break e;case 13:if(n.last){y>>>=7&w,w-=7&w,n.mode=27;break}for(;w<3;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}switch(n.last=1&y,w-=1,3&(y>>>=1)){case 0:n.mode=14;break;case 1:if(S(n),n.mode=20,6!==t)break;y>>>=2,w-=2;break e;case 2:n.mode=17;break;case 3:e.msg="invalid block type",n.mode=30}y>>>=2,w-=2;break;case 14:for(y>>>=7&w,w-=7&w;w<32;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if((65535&y)!=(y>>>16^65535)){e.msg="invalid stored block lengths",n.mode=30;break}if(n.length=65535&y,w=y=0,n.mode=15,6===t)break e;case 15:n.mode=16;case 16:if(E=n.length){if(g<E&&(E=g),b<E&&(E=b),0===E)break e;r.arraySet(p,h,m,E,v),g-=E,m+=E,b-=E,v+=E,n.length-=E;break}n.mode=12;break;case 17:for(;w<14;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(n.nlen=257+(31&y),y>>>=5,w-=5,n.ndist=1+(31&y),y>>>=5,w-=5,n.ncode=4+(15&y),y>>>=4,w-=4,286<n.nlen||30<n.ndist){e.msg="too many length or distance symbols",n.mode=30;break}n.have=0,n.mode=18;case 18:for(;n.have<n.ncode;){for(;w<3;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}n.lens[N[n.have++]]=7&y,y>>>=3,w-=3}for(;n.have<19;)n.lens[N[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,D={bits:n.lenbits},L=s(0,n.lens,0,19,n.lencode,0,n.work,D),n.lenbits=D.bits,L){e.msg="invalid code lengths set",n.mode=30;break}n.have=0,n.mode=19;case 19:for(;n.have<n.nlen+n.ndist;){for(;T=(j=n.lencode[y&(1<<n.lenbits)-1])>>>16&255,z=65535&j,!((I=j>>>24)<=w);){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(z<16)y>>>=I,w-=I,n.lens[n.have++]=z;else{if(16===z){for(U=I+2;w<U;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(y>>>=I,w-=I,0===n.have){e.msg="invalid bit length repeat",n.mode=30;break}B=n.lens[n.have-1],E=3+(3&y),y>>>=2,w-=2}else if(17===z){for(U=I+3;w<U;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}w-=I,B=0,E=3+(7&(y>>>=I)),y>>>=3,w-=3}else{for(U=I+7;w<U;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}w-=I,B=0,E=11+(127&(y>>>=I)),y>>>=7,w-=7}if(n.have+E>n.nlen+n.ndist){e.msg="invalid bit length repeat",n.mode=30;break}for(;E--;)n.lens[n.have++]=B}}if(30===n.mode)break;if(0===n.lens[256]){e.msg="invalid code -- missing end-of-block",n.mode=30;break}if(n.lenbits=9,D={bits:n.lenbits},L=s(l,n.lens,0,n.nlen,n.lencode,0,n.work,D),n.lenbits=D.bits,L){e.msg="invalid literal/lengths set",n.mode=30;break}if(n.distbits=6,n.distcode=n.distdyn,D={bits:n.distbits},L=s(c,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,D),n.distbits=D.bits,L){e.msg="invalid distances set",n.mode=30;break}if(n.mode=20,6===t)break e;case 20:n.mode=21;case 21:if(6<=g&&258<=b){e.next_out=v,e.avail_out=b,e.next_in=m,e.avail_in=g,n.hold=y,n.bits=w,a(e,x),v=e.next_out,p=e.output,b=e.avail_out,m=e.next_in,h=e.input,g=e.avail_in,y=n.hold,w=n.bits,12===n.mode&&(n.back=-1);break}for(n.back=0;T=(j=n.lencode[y&(1<<n.lenbits)-1])>>>16&255,z=65535&j,!((I=j>>>24)<=w);){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(T&&0==(240&T)){for(F=I,R=T,P=z;T=(j=n.lencode[P+((y&(1<<F+R)-1)>>F)])>>>16&255,z=65535&j,!(F+(I=j>>>24)<=w);){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}y>>>=F,w-=F,n.back+=F}if(y>>>=I,w-=I,n.back+=I,n.length=z,0===T){n.mode=26;break}if(32&T){n.back=-1,n.mode=12;break}if(64&T){e.msg="invalid literal/length code",n.mode=30;break}n.extra=15&T,n.mode=22;case 22:if(n.extra){for(U=n.extra;w<U;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}n.length+=y&(1<<n.extra)-1,y>>>=n.extra,w-=n.extra,n.back+=n.extra}n.was=n.length,n.mode=23;case 23:for(;T=(j=n.distcode[y&(1<<n.distbits)-1])>>>16&255,z=65535&j,!((I=j>>>24)<=w);){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(0==(240&T)){for(F=I,R=T,P=z;T=(j=n.distcode[P+((y&(1<<F+R)-1)>>F)])>>>16&255,z=65535&j,!(F+(I=j>>>24)<=w);){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}y>>>=F,w-=F,n.back+=F}if(y>>>=I,w-=I,n.back+=I,64&T){e.msg="invalid distance code",n.mode=30;break}n.offset=z,n.extra=15&T,n.mode=24;case 24:if(n.extra){for(U=n.extra;w<U;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}n.offset+=y&(1<<n.extra)-1,y>>>=n.extra,w-=n.extra,n.back+=n.extra}if(n.offset>n.dmax){e.msg="invalid distance too far back",n.mode=30;break}n.mode=25;case 25:if(0===b)break e;if(E=x-b,n.offset>E){if((E=n.offset-E)>n.whave&&n.sane){e.msg="invalid distance too far back",n.mode=30;break}A=E>n.wnext?(E-=n.wnext,n.wsize-E):n.wnext-E,E>n.length&&(E=n.length),O=n.window}else O=p,A=v-n.offset,E=n.length;for(b<E&&(E=b),b-=E,n.length-=E;p[v++]=O[A++],--E;);0===n.length&&(n.mode=21);break;case 26:if(0===b)break e;p[v++]=n.length,b--,n.mode=21;break;case 27:if(n.wrap){for(;w<32;){if(0===g)break e;g--,y|=h[m++]<<w,w+=8}if(x-=b,e.total_out+=x,n.total+=x,x&&(e.adler=n.check=n.flags?o(n.check,p,x,v-x):i(n.check,p,x,v-x)),x=b,(n.flags?y:_(y))!==n.check){e.msg="incorrect data check",n.mode=30;break}w=y=0}n.mode=28;case 28:if(n.wrap&&n.flags){for(;w<32;){if(0===g)break e;g--,y+=h[m++]<<w,w+=8}if(y!==(4294967295&n.total)){e.msg="incorrect length check",n.mode=30;break}w=y=0}n.mode=29;case 29:L=1;break e;case 30:L=-3;break e;case 31:return-4;default:return d}return e.next_out=v,e.avail_out=b,e.next_in=m,e.avail_in=g,n.hold=y,n.bits=w,(n.wsize||x!==e.avail_out&&n.mode<30&&(n.mode<27||4!==t))&&C(e,e.output,e.next_out,x-e.avail_out)?(n.mode=31,-4):(k-=e.avail_in,x-=e.avail_out,e.total_in+=k,e.total_out+=x,n.total+=x,n.wrap&&x&&(e.adler=n.check=n.flags?o(n.check,p,x,e.next_out-x):i(n.check,p,x,e.next_out-x)),e.data_type=n.bits+(n.last?64:0)+(12===n.mode?128:0)+(20===n.mode||15===n.mode?256:0),(0==k&&0===x||4===t)&&L===u&&(L=-5),L)},n.inflateEnd=function(e){if(!e||!e.state)return d;var t=e.state;return t.window&&(t.window=null),e.state=null,u},n.inflateGetHeader=function(e,t){var n;return e&&e.state?0==(2&(n=e.state).wrap)?d:((n.head=t).done=!1,u):d},n.inflateSetDictionary=function(e,t){var n,r=t.length;return e&&e.state?0!==(n=e.state).wrap&&11!==n.mode?d:11===n.mode&&i(1,t,r,0)!==n.check?-3:C(e,t,r,r)?(n.mode=31,-4):(n.havedict=1,u):d},n.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(e,t,n){"use strict";var r=e("../utils/common"),i=[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],o=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],a=[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,0,0],s=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];t.exports=function(e,t,n,l,c,u,d,f){var h,p,_,m,v,g,b,y,w,k=f.bits,x=0,S=0,C=0,E=0,A=0,O=0,I=0,T=0,z=0,F=0,R=null,P=0,B=new r.Buf16(16),L=new r.Buf16(16),D=null,U=0;for(x=0;x<=15;x++)B[x]=0;for(S=0;S<l;S++)B[t[n+S]]++;for(A=k,E=15;1<=E&&0===B[E];E--);if(E<A&&(A=E),0===E)return c[u++]=20971520,c[u++]=20971520,f.bits=1,0;for(C=1;C<E&&0===B[C];C++);for(A<C&&(A=C),x=T=1;x<=15;x++)if(T<<=1,(T-=B[x])<0)return-1;if(0<T&&(0===e||1!==E))return-1;for(L[1]=0,x=1;x<15;x++)L[x+1]=L[x]+B[x];for(S=0;S<l;S++)0!==t[n+S]&&(d[L[t[n+S]]++]=S);if(g=0===e?(R=D=d,19):1===e?(R=i,P-=257,D=o,U-=257,256):(R=a,D=s,-1),x=C,v=u,I=S=F=0,_=-1,m=(z=1<<(O=A))-1,1===e&&852<z||2===e&&592<z)return 1;for(;;){for(b=x-I,w=d[S]<g?(y=0,d[S]):d[S]>g?(y=D[U+d[S]],R[P+d[S]]):(y=96,0),h=1<<x-I,C=p=1<<O;c[v+(F>>I)+(p-=h)]=b<<24|y<<16|w|0,0!==p;);for(h=1<<x-1;F&h;)h>>=1;if(0!==h?(F&=h-1,F+=h):F=0,S++,0==--B[x]){if(x===E)break;x=t[n+d[S]]}if(A<x&&(F&m)!==_){for(0===I&&(I=A),v+=C,T=1<<(O=x-I);O+I<E&&!((T-=B[O+I])<=0);)O++,T<<=1;if(z+=1<<O,1===e&&852<z||2===e&&592<z)return 1;c[_=F&m]=A<<24|O<<16|v-u|0}}return 0!==F&&(c[v+F]=x-I<<24|64<<16|0),f.bits=A,0}},{"../utils/common":41}],51:[function(e,t,n){"use strict";t.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],52:[function(e,t,n){"use strict";var r=e("../utils/common"),i=0,o=1;function a(e){for(var t=e.length;0<=--t;)e[t]=0}var s=0,l=29,c=256,u=c+1+l,d=30,f=19,h=2*u+1,p=15,_=16,m=7,v=256,g=16,b=17,y=18,w=[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],k=[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],x=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],S=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],C=new Array(2*(u+2));a(C);var E=new Array(2*d);a(E);var A=new Array(512);a(A);var O=new Array(256);a(O);var I=new Array(l);a(I);var T,z,F,R=new Array(d);function P(e,t,n,r,i){this.static_tree=e,this.extra_bits=t,this.extra_base=n,this.elems=r,this.max_length=i,this.has_stree=e&&e.length}function B(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function L(e){return e<256?A[e]:A[256+(e>>>7)]}function D(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function U(e,t,n){e.bi_valid>_-n?(e.bi_buf|=t<<e.bi_valid&65535,D(e,e.bi_buf),e.bi_buf=t>>_-e.bi_valid,e.bi_valid+=n-_):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=n)}function j(e,t,n){U(e,n[2*t],n[2*t+1])}function $(e,t){for(var n=0;n|=1&e,e>>>=1,n<<=1,0<--t;);return n>>>1}function N(e,t,n){var r,i,o=new Array(p+1),a=0;for(r=1;r<=p;r++)o[r]=a=a+n[r-1]<<1;for(i=0;i<=t;i++){var s=e[2*i+1];0!==s&&(e[2*i]=$(o[s]++,s))}}function M(e){var t;for(t=0;t<u;t++)e.dyn_ltree[2*t]=0;for(t=0;t<d;t++)e.dyn_dtree[2*t]=0;for(t=0;t<f;t++)e.bl_tree[2*t]=0;e.dyn_ltree[2*v]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function W(e){8<e.bi_valid?D(e,e.bi_buf):0<e.bi_valid&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function V(e,t,n,r){var i=2*t,o=2*n;return e[i]<e[o]||e[i]===e[o]&&r[t]<=r[n]}function Z(e,t,n){for(var r=e.heap[n],i=n<<1;i<=e.heap_len&&(i<e.heap_len&&V(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!V(t,r,e.heap[i],e.depth));)e.heap[n]=e.heap[i],n=i,i<<=1;e.heap[n]=r}function H(e,t,n){var r,i,o,a,s=0;if(0!==e.last_lit)for(;r=e.pending_buf[e.d_buf+2*s]<<8|e.pending_buf[e.d_buf+2*s+1],i=e.pending_buf[e.l_buf+s],s++,0===r?j(e,i,t):(j(e,(o=O[i])+c+1,t),0!==(a=w[o])&&U(e,i-=I[o],a),j(e,o=L(--r),n),0!==(a=k[o])&&U(e,r-=R[o],a)),s<e.last_lit;);j(e,v,t)}function q(e,t){var n,r,i,o=t.dyn_tree,a=t.stat_desc.static_tree,s=t.stat_desc.has_stree,l=t.stat_desc.elems,c=-1;for(e.heap_len=0,e.heap_max=h,n=0;n<l;n++)0!==o[2*n]?(e.heap[++e.heap_len]=c=n,e.depth[n]=0):o[2*n+1]=0;for(;e.heap_len<2;)o[2*(i=e.heap[++e.heap_len]=c<2?++c:0)]=1,e.depth[i]=0,e.opt_len--,s&&(e.static_len-=a[2*i+1]);for(t.max_code=c,n=e.heap_len>>1;1<=n;n--)Z(e,o,n);for(i=l;n=e.heap[1],e.heap[1]=e.heap[e.heap_len--],Z(e,o,1),r=e.heap[1],e.heap[--e.heap_max]=n,e.heap[--e.heap_max]=r,o[2*i]=o[2*n]+o[2*r],e.depth[i]=(e.depth[n]>=e.depth[r]?e.depth[n]:e.depth[r])+1,o[2*n+1]=o[2*r+1]=i,e.heap[1]=i++,Z(e,o,1),2<=e.heap_len;);e.heap[--e.heap_max]=e.heap[1],function(e,t){var n,r,i,o,a,s,l=t.dyn_tree,c=t.max_code,u=t.stat_desc.static_tree,d=t.stat_desc.has_stree,f=t.stat_desc.extra_bits,_=t.stat_desc.extra_base,m=t.stat_desc.max_length,v=0;for(o=0;o<=p;o++)e.bl_count[o]=0;for(l[2*e.heap[e.heap_max]+1]=0,n=e.heap_max+1;n<h;n++)m<(o=l[2*l[2*(r=e.heap[n])+1]+1]+1)&&(o=m,v++),l[2*r+1]=o,c<r||(e.bl_count[o]++,a=0,_<=r&&(a=f[r-_]),s=l[2*r],e.opt_len+=s*(o+a),d&&(e.static_len+=s*(u[2*r+1]+a)));if(0!==v){do{for(o=m-1;0===e.bl_count[o];)o--;e.bl_count[o]--,e.bl_count[o+1]+=2,e.bl_count[m]--,v-=2}while(0<v);for(o=m;0!==o;o--)for(r=e.bl_count[o];0!==r;)c<(i=e.heap[--n])||(l[2*i+1]!==o&&(e.opt_len+=(o-l[2*i+1])*l[2*i],l[2*i+1]=o),r--)}}(e,t),N(o,c,e.bl_count)}function G(e,t,n){var r,i,o=-1,a=t[1],s=0,l=7,c=4;for(0===a&&(l=138,c=3),t[2*(n+1)+1]=65535,r=0;r<=n;r++)i=a,a=t[2*(r+1)+1],++s<l&&i===a||(s<c?e.bl_tree[2*i]+=s:0!==i?(i!==o&&e.bl_tree[2*i]++,e.bl_tree[2*g]++):s<=10?e.bl_tree[2*b]++:e.bl_tree[2*y]++,o=i,c=(s=0)===a?(l=138,3):i===a?(l=6,3):(l=7,4))}function K(e,t,n){var r,i,o=-1,a=t[1],s=0,l=7,c=4;for(0===a&&(l=138,c=3),r=0;r<=n;r++)if(i=a,a=t[2*(r+1)+1],!(++s<l&&i===a)){if(s<c)for(;j(e,i,e.bl_tree),0!=--s;);else 0!==i?(i!==o&&(j(e,i,e.bl_tree),s--),j(e,g,e.bl_tree),U(e,s-3,2)):s<=10?(j(e,b,e.bl_tree),U(e,s-3,3)):(j(e,y,e.bl_tree),U(e,s-11,7));o=i,c=(s=0)===a?(l=138,3):i===a?(l=6,3):(l=7,4)}}a(R);var Y=!1;function X(e,t,n,i){U(e,(s<<1)+(i?1:0),3),function(e,t,n,i){W(e),i&&(D(e,n),D(e,~n)),r.arraySet(e.pending_buf,e.window,t,n,e.pending),e.pending+=n}(e,t,n,!0)}n._tr_init=function(e){Y||(function(){var e,t,n,r,i,o=new Array(p+1);for(r=n=0;r<l-1;r++)for(I[r]=n,e=0;e<1<<w[r];e++)O[n++]=r;for(O[n-1]=r,r=i=0;r<16;r++)for(R[r]=i,e=0;e<1<<k[r];e++)A[i++]=r;for(i>>=7;r<d;r++)for(R[r]=i<<7,e=0;e<1<<k[r]-7;e++)A[256+i++]=r;for(t=0;t<=p;t++)o[t]=0;for(e=0;e<=143;)C[2*e+1]=8,e++,o[8]++;for(;e<=255;)C[2*e+1]=9,e++,o[9]++;for(;e<=279;)C[2*e+1]=7,e++,o[7]++;for(;e<=287;)C[2*e+1]=8,e++,o[8]++;for(N(C,u+1,o),e=0;e<d;e++)E[2*e+1]=5,E[2*e]=$(e,5);T=new P(C,w,c+1,u,p),z=new P(E,k,0,d,p),F=new P(new Array(0),x,0,f,m)}(),Y=!0),e.l_desc=new B(e.dyn_ltree,T),e.d_desc=new B(e.dyn_dtree,z),e.bl_desc=new B(e.bl_tree,F),e.bi_buf=0,e.bi_valid=0,M(e)},n._tr_stored_block=X,n._tr_flush_block=function(e,t,n,r){var a,s,l=0;0<e.level?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,n=4093624447;for(t=0;t<=31;t++,n>>>=1)if(1&n&&0!==e.dyn_ltree[2*t])return i;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return o;for(t=32;t<c;t++)if(0!==e.dyn_ltree[2*t])return o;return i}(e)),q(e,e.l_desc),q(e,e.d_desc),l=function(e){var t;for(G(e,e.dyn_ltree,e.l_desc.max_code),G(e,e.dyn_dtree,e.d_desc.max_code),q(e,e.bl_desc),t=f-1;3<=t&&0===e.bl_tree[2*S[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),a=e.opt_len+3+7>>>3,(s=e.static_len+3+7>>>3)<=a&&(a=s)):a=s=n+5,n+4<=a&&-1!==t?X(e,t,n,r):4===e.strategy||s===a?(U(e,2+(r?1:0),3),H(e,C,E)):(U(e,4+(r?1:0),3),function(e,t,n,r){var i;for(U(e,t-257,5),U(e,n-1,5),U(e,r-4,4),i=0;i<r;i++)U(e,e.bl_tree[2*S[i]+1],3);K(e,e.dyn_ltree,t-1),K(e,e.dyn_dtree,n-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,l+1),H(e,e.dyn_ltree,e.dyn_dtree)),M(e),r&&W(e)},n._tr_tally=function(e,t,n){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&n,e.last_lit++,0===t?e.dyn_ltree[2*n]++:(e.matches++,t--,e.dyn_ltree[2*(O[n]+c+1)]++,e.dyn_dtree[2*L(t)]++),e.last_lit===e.lit_bufsize-1},n._tr_align=function(e){U(e,2,3),j(e,v,C),function(e){16===e.bi_valid?(D(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):8<=e.bi_valid&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)}},{"../utils/common":41}],53:[function(e,t,n){"use strict";t.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(e,t,n){"use strict";t.exports="function"==typeof setImmediate?setImmediate:function(){var e=[].slice.apply(arguments);e.splice(1,0,0),setTimeout.apply(null,e)}},{}]},{},[10])(10)},379:function(e){"use strict";var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var o={},a=[],s=0;s<e.length;s++){var l=e[s],c=r.base?l[0]+r.base:l[0],u=o[c]||0,d="".concat(c," ").concat(u);o[c]=u+1;var f=n(d),h={css:l[1],media:l[2],sourceMap:l[3],supports:l[4],layer:l[5]};if(-1!==f)t[f].references++,t[f].updater(h);else{var p=i(h,r);r.byIndex=s,t.splice(s,0,{identifier:d,updater:p,references:1})}a.push(d)}return a}function i(e,t){var n=t.domAPI(t);n.update(e);return function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,i){var o=r(e=e||[],i=i||{});return function(e){e=e||[];for(var a=0;a<o.length;a++){var s=n(o[a]);t[s].references--}for(var l=r(e,i),c=0;c<o.length;c++){var u=n(o[c]);0===t[u].references&&(t[u].updater(),t.splice(u,1))}o=l}}},569:function(e){"use strict";var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},216:function(e){"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},565:function(e,t,n){"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},795:function(e){"use strict";e.exports=function(e){var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var i=void 0!==n.layer;i&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,i&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},744:function(e,t){"use strict";t.Z=(e,t)=>{const n=e.__vccOpts||e;for(const[e,r]of t)n[e]=r;return n}}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={id:r,exports:{}};return e[r](o,o.exports,n),o.exports}n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},function(){"use strict";var e=n(44);function t(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)}}var r=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.prefix="bp_"}var n,r,i;return n=e,(r=[{key:"get",value:function(e){return localStorage.getItem(this.prefix+(e||""))||""}},{key:"set",value:function(e,t){return localStorage.setItem(this.prefix+(e||""),t)}}])&&t(n.prototype,r),i&&t(n,i),Object.defineProperty(n,"prototype",{writable:!1}),e}());var i={show:function(){$("div#bp_config").is(":hidden")&&$("div#message_box").is(":hidden")&&$("body").css("overflow","auto")},hide:function(){$("body").css("overflow","hidden")}};function o(e,t){"confirm"===t?$('div.message_box_btn button[name="cancel"]').show():"alert"===t&&$('div.message_box_btn button[name="cancel"]').hide(),e.html?$("div#message_box_context").html('<div style="font-size:18px">'.concat(e.html,"</div>")):$("div#message_box_context").html('<div style="font-size:18px">╰( ̄▽ ̄)╮</div>'),i.hide(),$("#message_box").show(),$("div#message_box").animate({opacity:"1"},300),$('div.message_box_btn button[name="affirm"]')[0].onclick=function(){$("div#message_box").hide(),$("div#message_box").css("opacity",0),i.show(),e.callback&&e.callback.affirm&&e.callback.affirm()},$('div.message_box_btn button[name="cancel"]')[0].onclick=function(){$("div#message_box").hide(),$("div#message_box").css("opacity",0),i.show(),e.callback&&e.callback.cancel&&e.callback.cancel()}}var a=0;function s(e,t){(function(e,t){$("div.message-bg").append(e),$("div#message-".concat(t)).animate({"margin-top":"+=70px",opacity:"1"},300)})('<div id="message-'.concat(a+=1,'" class="message message-').concat(t,'"><div class="message-context"><p><strong>').concat(t,":</strong></p><p>").concat(e,"</p></div></div>"),a),function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3;setTimeout((function(){var t="div#message-".concat(e);$(t).animate({"margin-top":"-=70px",opacity:"0"},300,(function(){$(t).remove()}))}),1e3*t)}(a,3)}var l=function(e){return s(e,"success")},c=function(e){return s(e,"warning")},u=function(e){return s(e,"danger")},d=function(e){return s(e,"info")},f=function(e){return s("(^・ω・^)~喵喵喵~","info")},h=function(e,t){return o({html:e,callback:{affirm:t}},"alert")},p=function(e,t,n){return o({html:e,callback:{affirm:t,cancel:n}},"confirm")};function _(e){return new Promise((function(t,n){e.success=function(e){e.code&&c("".concat(e.message||"CODE:".concat(e.code))),t(e)},e.error=function(e){u("网络异常"),n(e)},$.ajax(e)}))}function m(){return location.pathname.match("/cheese/play/")?"cheese":location.pathname.match("/medialist/play/")?"medialist":window.__INITIAL_STATE__?window.__INITIAL_STATE__.epInfo?"bangumi":window.__INITIAL_STATE__.videoData?"video":void 0:"?"}var v={"1080P 高码率":112,"1080P 高清":80,"720P 高清":64,"480P 清晰":32,"360P 流畅":16,"自动":64};var g={type:m,base:function(){var e=m();if("video"===e){var t=window.__INITIAL_STATE__,n=(t.videoData&&t.videoData.title||"unknown").replace(/[\/\\:*?"<>|]+/g,"");return{type:"video",name:n,total:function(){return t.videoData.pages.length||1},title:function(e){var n=e||t.p||1;return(t.videoData.pages[n-1].part||"unknown").replace(/[\/\\:*?"<>|]+/g,"")},filename:function(e){var r=e||t.p||1;return(n+" P".concat(r," (").concat(t.videoData.pages[r-1].part||r,")")).replace(/[\/\\:*?"<>|]+/g,"")},aid:function(e){return t.videoData.aid},p:function(){return t.p||1},cid:function(e){var n=e||t.p||1;return t.videoData.pages[n-1].cid},epid:function(e){return""},need_vip:function(){return!1},vip_need_pay:function(){return!1},is_limited:function(){return!1}}}if("medialist"===e){var r=$("div.player-auxiliary-playlist-item"),i=$("div.player-auxiliary-playlist-item.player-auxiliary-playlist-item-active").index(),o=($(".player-auxiliary-playlist-top .player-auxiliary-filter-title").html()||"unknown").replace(/[\/\\:*?"<>|]+/g,"");return{type:"video",name:o,total:function(){return r.length},title:function(e){var t=e?e-1:i,n=r.eq(t).find(".player-auxiliary-playlist-item-title").attr("title")||"unknown";return n.replace(/[\/\\:*?"<>|]+/g,"")},filename:function(e){var t=e?e-1:i,n=r.eq(t).find(".player-auxiliary-playlist-item-title").attr("title")||"unknown";return"".concat(o," P").concat(t+1," (").concat(n,")").replace(/[\/\\:*?"<>|]+/g,"")},aid:function(e){var t=e?e-1:i;return r.eq(t).attr("data-aid")},p:function(){return i+1},cid:function(e){var t=e?e-1:i;return r.eq(t).attr("data-cid")},epid:function(e){return""},need_vip:function(){return!1},vip_need_pay:function(){return!1},is_limited:function(){return!1}}}if("bangumi"===e){var a=window.__INITIAL_STATE__,s=(a.mediaInfo.season_title||"unknown").replace(/[\/\\:*?"<>|]+/g,"");return{type:"bangumi",name:s,total:function(){return a.epList.length},title:function(e){var t=e?a.epList[e-1]:a.epInfo;return"".concat(t.titleFormat," ").concat(t.longTitle).replace(/[\/\\:*?"<>|]+/g,"")},filename:function(e){if(e){var t=a.epList[e-1];return"".concat(s,":").concat(t.titleFormat," ").concat(t.longTitle).replace(/[\/\\:*?"<>|]+/g,"")}return(a.h1Title||"unknown").replace(/[\/\\:*?"<>|]+/g,"")},aid:function(e){return e?a.epList[e-1].aid:a.epInfo.aid},p:function(){return a.epInfo.i||1},cid:function(e){return e?a.epList[e-1].cid:a.epInfo.cid},epid:function(e){return e?a.epList[e-1].id:a.epInfo.id},need_vip:function(){return"会员"===a.epInfo.badge},vip_need_pay:function(){return a.epPayMent.vipNeedPay},is_limited:function(){return a.userState.areaLimit}}}if("cheese"===e){var l=(location.href.match(/\/cheese\/play\/ep(\d+)/i)||["",""])[1];window.bp_episodes||(window.bp_episodes=[],x.get_season(l));var c=window.bp_episodes,u=$("li.on.list-box-li").index(),d=($("div.season-info h1").html()||"unknown").replace(/[\/\\:*?"<>|]+/g,"");return{type:"cheese",name:d,total:function(){return c.length},title:function(e){return(c[e?e-1:u].title||"unknown").replace(/[\/\\:*?"<>|]+/g,"")},filename:function(e){var t=e?e-1:u;return"".concat(d," P").concat(t+1," (").concat(c[t].title||"unknown",")").replace(/[\/\\:*?"<>|]+/g,"")},aid:function(e){return c[e?e-1:u].aid},p:function(){return u+1},cid:function(e){return c[e?e-1:u].cid},epid:function(e){return c[e?e-1:u].id},need_vip:function(){return!1},vip_need_pay:function(){return!1},is_limited:function(){return!1}}}return{type:"?",name:"none",total:function(){return 0},title:function(e){return""},filename:function(e){return""},aid:function(e){return""},p:function(){return 1},cid:function(e){return""},epid:function(e){return""},need_vip:function(){return!1},vip_need_pay:function(){return!1},is_limited:function(){return!1}}},get_quality:function(){var e=0,t=0;return $("li.bui-select-item")[0]&&(t=parseInt($("li.bui-select-item")[0].dataset.value))?e=parseInt($("li.bui-select-item.bui-select-item-active").attr("data-value"))||(t>80?80:t):$("li.squirtle-select-item")[0]&&(t=parseInt($("li.squirtle-select-item")[0].dataset.value))?e=parseInt($("li.squirtle-select-item.active").attr("data-value"))||(t>80?80:t):$("div.edu-player-quality-item")[0]?(e=v[$("div.edu-player-quality-item.active span").text()||"自动"]||80,t=v[$("div.edu-player-quality-item span").text()||"自动"]||80):e=t=80,{q:e,q_max:t}},get_quality_support:function(){var e,t=[];return"cheese"===m()?((e=$("div.edu-player-quality-item span")).each((function(){if("自动"===$(this).text())return!1;t.push(v[$(this).text()])})),t.length?t:["80","64","32","16"]):($("ul.squirtle-select-list")[0]?e=$("li.squirtle-select-item"):$("ul.bui-select-list")[0]&&(e=$("li.bui-select-item")),e&&e.length?(e.each((function(){var e="".concat($(this).attr("data-value"));if("0"===e)return!1;t.push(e)})),t):["80","64","32","16"])}};function b(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return y(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return y(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},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 o,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}function y(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 w(t,n,i,o,a,s){var l,c;l="function"==typeof o?function(e){o(e)}:function(e){return console.log(e)},c="function"==typeof a?function(e){u("请求失败"),a(e)}:function(e){return console.error(e)};var d=g.base(),f=[d.aid(t),d.cid(t),d.epid(t),n||g.get_quality().q,d.type],h=f[0],p=f[1],m=f[2],v=f[3],b=f[4],y=i||e.config.format;"mp4"===y&&"video"!==b&&(y="flv");var k,x=function(t){if("0"!==e.config.host_key&&"online"===s&&"mp4"!==y){var n=t.split("/");n[2]=e.hostMap[e.config.host_key],t=n.join("/")}return t},S={type:"GET",dataType:"json"};if("auto"===s||"local"===s){var C,E;"cheese"!==b?(k="https://api.bilibili.com/x/player/playurl","dash"===y?(C=0,E=80):(C=0,E=0)):(k="https://api.bilibili.com/pugv/player/web/playurl","dash"===y?(C=0,E=80):(C=1,E=80)),k+="?avid=".concat(h,"&cid=").concat(p,"&qn=").concat(v,"&fnver=").concat(C,"&fnval=").concat(E,"&fourk=1&ep_id=").concat(m,"&type=").concat(y,"&otype=json"),k+="mp4"===y?"&platform=html5&high_quality=1":"",S.xhrFields={withCredentials:!0}}else{k=e.config.base_api,k+="?av=".concat(h,"&cid=").concat(p,"&q=").concat(v,"&ep=").concat(m,"&type=").concat(b,"&format=").concat(y,"&otype=json");var A=[r.get("auth_id"),r.get("auth_sec")],O=A[0],I=A[1];"1"===e.config.auth&&O&&I&&(k+="&auth_id=".concat(O,"&auth_sec=").concat(I),t&&(k+="&s"))}S.url=k,_(S).then((function(e){var r;if(e.code||(r=e.result||e.data),!r)return"auto"===s?void w(t,n,i,o,a,"online"):(e.url&&(e.url=x(e.url)),e.video&&(e.video=x(e.video)),e.audio&&(e.audio=x(e.audio)),void l(e));if(r.dash){for(var c={code:0,quality:r.quality,accept_quality:r.accept_quality,video:"",audio:""},u=r.dash.video,d=0;d<u.length;d++){var f=u[d];if(f.id<=v){c.video=x(f.base_url),c.audio=x(r.dash.audio[0].base_url);break}}l(c)}else l({code:0,quality:r.quality,accept_quality:r.accept_quality,url:x(r.durl[0].url)})})).catch((function(e){return c(e)}))}function k(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=g.base(),i=[r.aid(e),r.cid(e),r.epid(e)],o=i[0],a=i[1],s=i[2];_({url:"https://api.bilibili.com/x/player/v2?aid=".concat(o,"&cid=").concat(a,"&ep_id=").concat(s),dataType:"json"}).then((function(e){!e.code&&e.data.subtitle.subtitles[0]?_({url:"".concat(e.data.subtitle.subtitles[0].subtitle_url),dataType:"json"}).then((function(e){var r,i="WEBVTT\n\n",o=b(e.body||[{from:0,to:0,content:""}]);try{for(o.s();!(r=o.n()).done;){var a=r.value,s=new Date(1e3*(parseInt(a.from)-28800)).toTimeString().split(" ")[0]+"."+(a.from.toString().split(".")[1]||"000").padEnd(3,"0"),l=new Date(1e3*(parseInt(a.to)-28800)).toTimeString().split(" ")[0]+"."+(a.to.toString().split(".")[1]||"000").padEnd(3,"0");i+="".concat(s," --\x3e ").concat(l,"\n").concat(a.content.trim(),"\n\n")}}catch(e){o.e(e)}finally{o.f()}t(n?URL.createObjectURL(new Blob([i],{type:"text/vtt"})):i)})).catch(t):t()})).catch(t)}var x={get_url:function(t,n){var r=e.config.request_type;w(0,0,e.config.format,t,n,r)},get_urls:function(t,n,r,i,o){w(t,n,r,i,o,e.config.request_type)},get_subtitle_url:function(e,t){k(e,t,!0)},get_subtitle_data:function(e,t){k(e,t,!1)},get_season:function(e){_({url:"https://api.bilibili.com/pugv/view/web/season?ep_id=".concat(e),xhrFields:{withCredentials:!0},dataType:"json"}).then((function(e){e.code?c("获取剧集信息失败"):window.bp_episodes=e.data.episodes||null}))}};function S(e,t){t?_({url:"https://api.bilibili.com/x/v1/dm/list.so?oid=".concat(t),dataType:"text"}).then((function(t){var n=$(t.replace(/[\x00-\x08\x0b-\x0c\x0e-\x1f\x7f]/g,""));if(n)if(n.find("d")[0]){var r=n.find("d").map((function(e,t){var n=$(t),r=n.attr("p").split(","),i=0;return"4"===r[1]?i=2:"5"===r[1]&&(i=1),[{author:"",time:parseFloat(r[0]),type:i,color:parseInt(r[3]),id:"",text:n.text()}]})).get();e.success(r),setTimeout((function(){O()}),100)}else e.error("未发现弹幕");else e.error("弹幕获取失败")})).catch((function(t){e.error("弹幕请求异常")})):e.error("cid未知,无法获取弹幕")}function C(){return $("bwp-video")[0]?"bwp-video":$('video[class!="dplayer-video dplayer-video-current"]')[0]?'video[class!="dplayer-video dplayer-video-current"]':void 0}function E(){var e=$(C())[0];e&&(e.pause(),e.currentTime=0)}function A(){if(window.bp_dplayer){var e=$(C())[0];e&&e.removeEventListener("play",E,!1),window.bp_dplayer.destroy(),window.bp_dplayer=null,$("#bp_dplayer").remove(),window.bp_dplayer_2&&(window.bp_dplayer_2.destroy(),window.bp_dplayer_2=null,$("#bp_dplayer_2").remove()),$($("#bilibiliPlayer")[0]?"#bilibiliPlayer":$("#bilibili-player")[0]?"#bilibili-player":"cheese"===g.type()?$('div.bpx-player[data-injector="nano"]')[0]?'div.bpx-player[data-injector="nano"]':"#pay-mask":void 0).show()}}function O(){var t=""+'<style id="dplayer_danmaku_style">\n        .dplayer-danmaku .dplayer-danmaku-right.dplayer-danmaku-move {\n            animation-duration: '.concat(parseFloat(e.config.danmaku_speed),"s;\n            font-size: ").concat(parseInt(e.config.danmaku_fontsize),"px;\n        }\n        </style>");$("#dplayer_danmaku_style")[0]&&$("#dplayer_danmaku_style").remove(),$("body").append(t)}var I={bili_video_tag:C,recover_player:A,replace_player:function(t,n){A();var r,i=$(C())[0];E(),i&&i.addEventListener("play",E,!1),$("#bilibiliPlayer")[0]?(r="#bilibiliPlayer",$(r).before('<div id="bp_dplayer" class="bilibili-player relative bilibili-player-no-cursor">'),$(r).hide()):$("#bilibili-player")[0]?(r="#bilibili-player",$(r).before('<div id="bp_dplayer" class="bilibili-player relative bilibili-player-no-cursor" style="width:100%;height:100%;"></div>'),$(r).hide()):"cheese"===g.type()&&($('div.bpx-player[data-injector="nano"]')[0]?($("#pay-mask").hide(),$("#bofqi").show(),r='div.bpx-player[data-injector="nano"]',$(r).before('<div id="bp_dplayer" style="width:100%;height:100%;"></div>'),$(r).hide()):(r="#pay-mask",$(r).html('<div id="bp_dplayer" style="width:100%;height:100%;"></div>'))),$("#player_mask_module").hide(),x.get_subtitle_url(0,(function(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";if(window.bp_dplayer=new DPlayer({container:$("#bp_dplayer")[0],mutex:!1,volume:1,autoplay:!0,video:{url:t,type:"auto"},subtitle:{url:r,type:"webvtt",fontSize:"35px",bottom:"5%",color:"#fff"},danmaku:!0,apiBackend:{read:function(e){S(e,g.base().cid())},send:function(e){e.error("此脚本无法将弹幕同步到云端")}},contextmenu:[{text:"脚本信息",link:"https://github.com/injahow/user.js"},{text:"脚本作者",link:"https://injahow.com"}]}),"dash"===e.config.format&&n&&"#"!==n){$("body").append('<div id="bp_dplayer_2" style="display:none;"></div>'),window.bp_dplayer_2=new DPlayer({container:$("#bp_dplayer_2")[0],mutex:!1,volume:1,autoplay:!0,video:{url:n,type:"auto"}});var i=[window.bp_dplayer,window.bp_dplayer_2],o=i[0],a=i[1];o.on("play",(function(){!o.paused&&a.play()})),o.on("playing",(function(){!o.paused&&a.play()})),o.on("timeupdate",(function(){Math.abs(o.video.currentTime-a.video.currentTime)>1&&(a.pause(),a.seek(o.video.currentTime)),!o.paused&&a.play()})),o.on("seeking",(function(){a.pause(),a.seek(o.video.currentTime)})),o.on("waiting",(function(){a.pause(),a.seek(o.video.currentTime)})),o.on("pause",(function(){a.pause(),a.seek(o.video.currentTime)})),o.on("suspend",(function(){a.speed(o.video.playbackRate)})),o.on("volumechange",(function(){a.volume(o.video.volume),a.video.muted=o.video.muted}))}}))},danmaku:{config:O}},T=n(733),z=n.n(T);function F(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return R(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return R(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},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 o,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}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 P(){return e.config.rpc_domain.match("https://")||e.config.rpc_domain.match(/localhost|127\.0\.0\.1/)?"post":"ariang"}var B=!1;function L(t){var n=t?"#!/settings/rpc/set/".concat(t.domain.replace("://","/"),"/").concat(t.port,"/jsonrpc/").concat(window.btoa(t.token)):"",r=e.config.ariang_host+n,i=document.createElement("a");i.setAttribute("target","_blank"),i.setAttribute("onclick","window.bp_aria2_window=window.open('".concat(r,"');")),document.body.appendChild(i),i.click(),i.remove()}var D=!1,U=!0;function j(e,t){if(D)return f(),void(U=!0);var n=new XMLHttpRequest;n.open("get",e),n.responseType="blob",n.onload=function(){if(200===this.status||304===this.status){if("msSaveOrOpenBlob"in navigator)return void navigator.msSaveOrOpenBlob(this.response,t);var e=URL.createObjectURL(this.response),n=document.createElement("a");n.style.display="none",n.href=e,n.download=t,document.body.appendChild(n),n.click(),n.remove(),URL.revokeObjectURL(e)}},U=!0,n.onprogress=function(e){if(4!=this.state){var t=e.loaded,n=e.total;!function(e){var t=e.total,n=e.loaded,r=e.percent;U&&h("文件大小:".concat(Math.floor(t/1048576),"MB(").concat(t,"Byte)<br/>")+"已经下载:".concat(Math.floor(n/1048576),"MB(").concat(n,"Byte)<br/>")+"当前进度:".concat(r,"%<br/>下载中请勿操作浏览器!"),(function(){U=!1,h("注意:刷新或离开页面会导致下载取消!<br/>再次点击下载按钮可查看下载进度。")})),t===n&&(h("下载完成,请等待浏览器保存!"),D=!1)}({total:n,loaded:t,percent:Math.floor(100*t/n)})}},n.send(),D=!0,d("准备开始下载")}function N(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;_({url:"https://api.bilibili.com/x/v1/dm/list.so?oid=".concat(e),dataType:"text"}).then((function(e){var i=$(e.replace(/[\x00-\x08\x0b-\x0c\x0e-\x1f\x7f]/g,""));if(i&&i.find("d")[0]){var o=i.find("d").map((function(e,t){var n=$(t),r=n.attr("p").split(","),i=0;return"4"===r[1]?i=2:"5"===r[1]&&(i=1),[{time:parseFloat(r[0]),type:i,color:parseInt(r[3]),text:n.text()}]})).get();o.sort((function(e,t){return e.time-t.time}));var a,s=function(e,t,n){var r,i,o,a,s=e.text,l=e.time,c=[0===e.type?(i=50*(1+Math.floor(15*Math.random())),o=1920+50*e.text.length/2,a=0-50*e.text.length/2,"\\move(".concat(o,",").concat(i,",").concat(a,",").concat(i,")")):function(e,t){return"\\pos(".concat(t,",").concat(e,")")}(50*(1+n%15),960),(r=e.color,16777215===r?"":function(e){return"\\c&H".concat(((255&e)<<16|(e>>8&255)<<8|e>>16&255).toString(16),"&")}(e.color))],u=function(e){var t=function(e,t){return Math.floor(e/t)},n=function(e){return e<10?"0"+e:""+e},r=Math.floor(e),i=t(r,3600),o=t(r,60)%60,a=r%60,s=Math.floor(100*(e-r));return"".concat(i,":").concat(n(o),":").concat(n(a),".").concat(s)},d=[0,u(l),u(l+(0===e.type?8:4)),"Medium","","0","0","0","","{"+c.join("")+"}"+function(e){return e.replace(/\{/g,"{").replace(/\}/g,"}").replace(/\r|\n/g,"")}(s)];return"Dialogue: "+d.join(",")},l=["[Script Info]","; Script generated by bilibili-parse","; https://github.com/injahow/bilibili-parse","Title: ".concat(t),"ScriptType: v4.00+","PlayResX: ".concat(1920),"PlayResY: ".concat(1080),"Timer: 10.0000","WrapStyle: 2","ScaledBorderAndShadow: no","","[V4+ Styles]","Format: Name, Fontname, Fontsize, PrimaryColour, SecondaryColour, OutlineColour, BackColour, Bold, Italic, Underline, StrikeOut, ScaleX, ScaleY, Spacing, Angle, BorderStyle, Outline, Shadow, Alignment, MarginL, MarginR, MarginV, Encoding","Style: Small,微软雅黑,36,&H66FFFFFF,&H66FFFFFF,&H66000000,&H66000000,0,0,0,0,100,100,0,0,1,1.2,0,5,0,0,0,0","Style: Medium,微软雅黑,52,&H66FFFFFF,&H66FFFFFF,&H66000000,&H66000000,0,0,0,0,100,100,0,0,1,1.2,0,5,0,0,0,0","Style: Large,微软雅黑,64,&H66FFFFFF,&H66FFFFFF,&H66000000,&H66000000,0,0,0,0,100,100,0,0,1,1.2,0,5,0,0,0,0","Style: Larger,微软雅黑,72,&H66FFFFFF,&H66FFFFFF,&H66000000,&H66000000,0,0,0,0,100,100,0,0,1,1.2,0,5,0,0,0,0","Style: ExtraLarge,微软雅黑,90,&H66FFFFFF,&H66FFFFFF,&H66000000,&H66000000,0,0,0,0,100,100,0,0,1,1.2,0,5,0,0,0,0","","[Events]","Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text"],u=0,d=F(o);try{for(d.s();!(a=d.n()).done;){var f=a.value;0===f.type?0:u++,l.push(s(f,0,u))}}catch(e){d.e(e)}finally{d.f()}var h=l.join("\n");if(null===n||"file"===n){var p=URL.createObjectURL(new Blob([h],{type:"text/ass"})),_=document.createElement("a");_.style.display="none",_.href=p,_.download=t+".ass",document.body.appendChild(_),_.click(),_.remove(),URL.revokeObjectURL(p)}else"callback"===n&&r&&r(h)}else c("未发现弹幕")})).catch((function(e){c("未发现字幕")}))}function M(e,t){if(e){var n=URL.createObjectURL(e),r=document.createElement("a");r.setAttribute("target","_blank"),r.setAttribute("href",n),r.setAttribute("download",t+".zip"),document.body.appendChild(r),r.click(),r.remove(),URL.revokeObjectURL(n)}}function W(e,t){if(e)if(0!==e.length){var n=e.pop();N(n.cid,n.filename,"callback",(function(r){r&&t.file(n.filename+".ass",r),W(e,t)}))}else t.generateAsync({type:"blob"}).then((function(e){return M(e,g.base().name+"_ass")}))}function V(e,t){if(e)if(0!==e.length){var n=e.pop();x.get_subtitle_data(n.p,(function(r){r&&t.file(n.filename+".vtt",r),V(e,t)}))}else t.generateAsync({type:"blob"}).then((function(e){return M(e,g.base().name+"_vtt")}))}function Z(e){return e.match(".flv")?".flv":e.match(".m4s")?"_video.mp4":(e.match(".mp4"),".mp4")}var H={url_format:Z,download:function(t,n,r){var i=n.replace(/[\/\\:*?"<>|]+/g,"")+Z(t);"blob"===r?j(t,i):"rpc"===r&&function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"post";if(B)f();else{B=!0;var i={domain:e.config.rpc_domain,port:e.config.rpc_port,token:e.config.rpc_token,dir:e.config.rpc_dir},o={id:window.btoa("BParse_".concat(Date.now(),"_").concat(Math.random())),jsonrpc:"2.0",method:"aria2.addUri",params:["token:".concat(i.token),[t],{dir:i.dir,out:n,header:["User-Agent: ".concat(window.navigator.userAgent),"Referer: ".concat(window.location.href)]}]};if(d("发送RPC下载请求"),"post"===r)_({url:"".concat(i.domain,":").concat(i.port,"/jsonrpc"),type:"POST",dataType:"json",data:JSON.stringify(o)}).then((function(e){e.result?l("RPC请求成功"):c("请检查RPC参数")})).catch((function(e){u("请检查RPC服务配置")})).finally((function(e){return B=!1}));else if("ariang"===r){var a=window.bp_aria2_window,s=100;a&&!a.closed||(L(),s=3e3),setTimeout((function(){var r=window.bp_aria2_window,i="header=User-Agent:".concat(window.navigator.userAgent,"&header=Referer:").concat(window.location.href),o="#!/new/task?url=".concat(window.btoa(t),"&out=").concat(encodeURIComponent(n),"&").concat(i);r&&!r.closed?(r.location.href=e.config.ariang_host+o,l("RPC请求发送成功")):c("AriaNG页面未打开"),B=!1}),s)}}}(t,i,P())},download_all:function(){var t=g.base(),n=[g.get_quality().q,t.total()],r=n[0],i=n[1];$("body").on("click",'input[name="dl_video"]',(function(){$(this).is(":checked")?$(this).parent().css("color","rgba(0,0,0,1)"):$(this).parent().css("color","rgba(0,0,0,0.5)")}));for(var o="",a=0;a<i;a++)o+=""+'<label for="option_'.concat(a,'"><div style="color:rgba(0,0,0,0.5);">\n                <input type="checkbox" id="option_').concat(a,'" name="dl_video" value="').concat(a,'">\n                P').concat(a+1," ").concat(t.title(a+1),"\n            </div></label>");var s=!1;$("body").on("click","button#checkbox_btn",(function(){s?(s=!1,$('input[name="dl_video"]').prop("checked",s),$('input[name="dl_video"]').parent().css("color","rgba(0,0,0,0.5)")):(s=!0,$('input[name="dl_video"]').prop("checked",s),$('input[name="dl_video"]').parent().css("color","rgb(0,0,0)"))}));var f,m={120:"4K 超清",116:"1080P 60帧",112:"1080P 高码率",80:"1080P 高清",74:"720P 60帧",64:"720P 高清",48:"720P 高清(MP4)",32:"480P 清晰",16:"360P 流畅"},v="",b=F(g.get_quality_support());try{for(b.s();!(f=b.n()).done;){var y=f.value;v+='<option value="'.concat(y,'">').concat(m[y],"</option>")}}catch(e){b.e(e)}finally{b.f()}var w=""+'<div style="margin:2% 0;">\n            <label>视频格式:</label>\n            <select id="dl_format">\n                <option value="flv" selected>FLV</option>\n                <option value="mp4">MP4</option>\n            </select>\n            &nbsp;&nbsp;仅video类型支持mp4\n        </div>\n        <div style="margin:2% 0;">\n            <label>视频质量:</label>\n            <select id="dl_quality">\n                '.concat(v,'\n            </select>\n        </div>\n        <div style="margin:2% 0;">\n            <label>下载字幕:</label>\n            <select id="dl_subtitle">\n                <option value="0" selected>关闭</option>\n                <option value="1">VTT</option>\n            </select>\n            &nbsp;&nbsp\n            <label>下载弹幕:</label>\n            <select id="dl_danmaku">\n                <option value="0" selected>关闭</option>\n                <option value="1">ASS</option>\n            </select>\n        </div>\n        <b>\n            <span style="color:red;">为避免请求被拦截,设置了延时且不支持下载无法播放的视频;请勿频繁下载过多视频,可能触发风控导致不可再下载!</span>\n        </b><br />\n        <div style="height:220px;width:100%;overflow:auto;background:rgba(0,0,0,0.1);">\n            ').concat(o,"\n        </div>\n        <div>").concat("medialist"===g.type()?"不支持多页视频,若需要请到视频原播放页面下载":"",'</div>\n        <div style="margin:2% 0;">\n            <button id="checkbox_btn">全选</button>\n        </div>');function k(t,n,r){if(t.length)if(n<t.length){var i=t[n],o="第".concat(n+1,"(").concat(n+1,"/").concat(t.length,")个视频");h("".concat(o,":获取中...")),setTimeout((function(){x.get_urls(i.p,i.q,i.format,(function(a){if(!a.code){l("请求成功"+(a.times?"<br/>今日剩余请求次数".concat(a.times):"")),h("".concat(o,":获取成功!"));var s=[a.url,Z(a.url),P()],u=s[0],d=s[1],f=s[2];"post"===f?(r.push({url:u,filename:i.filename+d}),r.length>3&&(S(r),r.length=0)):"ariang"===f&&function(t){var n=window.bp_aria2_window,r=100;n&&!n.closed||(L(),r=3e3);setTimeout((function(){var n=window.bp_aria2_window,r="header=User-Agent:".concat(window.navigator.userAgent,"&header=Referer:").concat(window.location.href);if(n&&!n.closed){var i="#!/new/task?url=".concat(window.btoa(t.url),"&out=").concat(encodeURIComponent(t.filename),"&").concat(r);n.location.href=e.config.ariang_host+i,l("RPC请求成功")}else c("请检查RPC参数")}),r)}({url:u,filename:i.filename+d})}setTimeout((function(){k(t,++n,r)}),3e3)}),(function(){k(t,++n,r)}))}),3e3)}else h("视频地址请求完成!"),"post"===P()&&r.length>0&&(S(r),r.length=0)}function S(t){var n,r={domain:e.config.rpc_domain,port:e.config.rpc_port,token:e.config.rpc_token,dir:e.config.rpc_dir},i=[],o=F(t);try{for(o.s();!(n=o.n()).done;){var a=n.value;i.push({id:window.btoa("BParse_".concat(Date.now(),"_").concat(Math.random())),jsonrpc:"2.0",method:"aria2.addUri",params:["token:".concat(r.token),[a.url],{dir:r.dir,out:a.filename,header:["User-Agent: ".concat(window.navigator.userAgent),"Referer: ".concat(window.location.href)]}]})}}catch(e){o.e(e)}finally{o.f()}d("发送RPC下载请求"),_({url:"".concat(r.domain,":").concat(r.port,"/jsonrpc"),type:"POST",dataType:"json",data:JSON.stringify(i)}).then((function(e){e.length===i.length?l("RPC请求成功"):c("请检查RPC参数")})).catch((function(e){u("请检查RPC服务配置")}))}p(w,(function(){for(var e=$("#dl_quality").val()||r,n=$("#dl_subtitle").val(),o=$("#dl_danmaku").val(),a=[],s=0;s<i;s++)if($("input#option_".concat(s)).is(":checked")){var l=s+1,c=[t.cid(l),t.filename(l)],u=c[0],d=c[1],f=$("#dl_format").val();a.push({cid:u,p:l,q:e,format:f,filename:d})}"1"===n&&V([].concat(a),new(z())),"1"===o&&W([].concat(a),new(z())),k(a,0,[])})),$("#dl_quality").val(r>120?80:r)},download_danmaku_ass:function(e,t){N(e,t,"file")},download_subtitle_vtt:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1?arguments[1]:void 0,n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";if(e){var n=document.createElement("a");n.setAttribute("target","_blank"),n.setAttribute("href",e),n.setAttribute("download",t+".vtt"),document.body.appendChild(n),n.click(),n.remove(),URL.revokeObjectURL(e)}else c("未发现字幕")};x.get_subtitle_url(e,n)},open_ariang:L};function q(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)}}var G=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.is_login=!1,this.vip_status=0,this.mid="",this.uname="",this.has_init=!1,this.lazyInit()}var t,n,r;return t=e,(n=[{key:"needReplace",value:function(){return!this.is_login||!this.vip_status&&g.base().need_vip()}},{key:"lazyInit",value:function(e){this.has_init||(window.__BILI_USER_INFO__?(this.is_login=window.__BILI_USER_INFO__.isLogin,this.vip_status=window.__BILI_USER_INFO__.vipStatus,this.mid=window.__BILI_USER_INFO__.mid||"",this.uname=window.__BILI_USER_INFO__.uname||""):window.__BiliUser__&&(this.is_login=window.__BiliUser__.isLogin,window.__BiliUser__.cache?(this.vip_status=window.__BiliUser__.cache.data.vipStatus,this.mid=window.__BiliUser__.cache.data.mid||"",this.uname=window.__BiliUser__.cache.data.uname||""):(this.vip_status=0,this.mid="",this.uname="")),this.has_init=e)}}])&&q(t.prototype,n),r&&q(t,r),Object.defineProperty(t,"prototype",{writable:!1}),e}());function K(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)}}var Y=function(){function t(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),this.auth_clicked=!1}var n,i,o;return n=t,i=[{key:"reLogin",value:function(){r.set("auth_id",""),r.set("auth_sec",""),r.set("access_key",""),r.set("auth_time","0"),this.login()}},{key:"checkLoginStatus",value:function(){var t=this,n=[r.get("auth_id"),r.get("auth_sec"),r.get("access_key"),r.get("auth_time")||"0"],i=n[0],o=n[1],a=n[2],s=n[3];a&&(G.is_login&&(e.config.base_api!==r.get("pre_base_api")||Date.now()-parseInt(s)>864e5)&&_({url:"https://api.bilibili.com/x/space/myinfo?access_key=".concat(a),type:"GET",dataType:"json"}).then((function(n){if(!n.code)return r.set("auth_time",Date.now()),_({url:"".concat(e.config.base_api,"/auth/v2/?act=check&auth_id=").concat(i,"&auth_sec=").concat(o,"&access_key=").concat(a),type:"GET",dataType:"json"});h("授权已过期,准备重新授权",t.reLogin)})).then((function(e){e.code&&h("授权检查失败,准备重新授权",t.reLogin)})),r.set("pre_base_api",e.config.base_api))}},{key:"_login",value:function(e){var t=this;this.auth_clicked?f():(this.auth_clicked=!0,_({url:"https://passport.bilibili.com/login/app/third?appkey=27eb53fc9058f8c3&api=https%3A%2F%2Fwww.mcbbs.net%2Ftemplate%2Fmcbbs%2Fimage%2Fspecial_photo_bg.png&sign=04224646d1fea004e79606d3b038c84a",xhrFields:{withCredentials:!0},type:"GET",dataType:"json"}).then(e).finally((function(e){return t.auth_clicked=!1})))}},{key:"login",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"1",t="1"===e?this.loginAuto.bind(this):this.loginManual.bind(this);r.get("auth_id")?p("发现授权记录,是否重新授权?",t):t()}},{key:"loginAuto",value:function(){this._login((function(e){e.data.has_login?$("body").append("<iframe id='auth_iframe' src='".concat(e.data.confirm_uri,"' style='display:none;'></iframe>")):p("必须登录B站才能正常授权,是否登陆?",(function(){location.href="https://passport.bilibili.com/login"}))}))}},{key:"loginManual",value:function(){this._login((function(t){if(t.data.has_login){var n=""+"请点击<b><a href='".concat(t.data.confirm_uri,"' target='_blank'>授权地址</a></b>\n                    打开一个新窗口,正常情况新窗口应该显示一个图片,请将该窗口地址栏的URL链接复制到当前文本框中<br/>\n                    <input id='auth_url' style='width:100%;' type='text' autocomplete='off'><br>然后点击确定即可");h(n,(function(){var t=$("#auth_url").val(),n=r.get("auth_id")||"",i=r.get("auth_sec")||"";_({url:t.replace("https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png?","".concat(e.config.base_api,"/auth/v2/?act=login&auth_id=").concat(n,"&auth_sec=").concat(i,"&")),type:"GET",dataType:"json"}).then((function(n){n.code?c("授权失败"):(l("授权成功"),n.auth_id&&n.auth_sec&&(r.set("auth_id",n.auth_id),r.set("auth_sec",n.auth_sec)),r.set("access_key",new URL(t).searchParams.get("access_key")),r.set("auth_time",Date.now()),$("#auth").val("1"),e.config.auth="1")}))}))}else p("必须登录B站才能正常授权,是否登陆?",(function(){location.href="https://passport.bilibili.com/login"}))}))}},{key:"logout",value:function(){var t=this;if(r.get("auth_id"))if(this.auth_clicked)f();else{var n=[r.get("auth_id"),r.get("auth_sec")],i=n[0],o=n[1];_({url:"".concat(e.config.base_api,"/auth/v2/?act=logout&auth_id=").concat(i,"&auth_sec=").concat(o),type:"GET",dataType:"json"}).then((function(t){t.code?c("取消失败"):(l("取消成功"),r.set("auth_id",""),r.set("auth_sec",""),r.set("auth_time","0"),r.set("access_key",""),$("#auth").val("0"),e.config.auth="0")})).finally((function(e){return t.auth_clicked=!1}))}else h("没有发现授权记录")}},{key:"initAuth",value:function(){var t=this;window.addEventListener("message",(function(n){if("string"==typeof n.data&&"bilibili-parse-login-credentials"===n.data.split(":")[0]){$("iframe#auth_iframe").remove();var i=n.data.split(": ")[1],o=[r.get("auth_id"),r.get("auth_sec")],a=o[0],s=o[1];_({url:i.replace("https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png?","".concat(e.config.base_api,"/auth/v2/?act=login&auth_id=").concat(a,"&auth_sec=").concat(s,"&")),type:"GET",dataType:"json"}).then((function(t){t.code?c("授权失败"):(l("授权成功"),t.auth_id&&t.auth_sec&&(r.set("auth_id",t.auth_id),r.set("auth_sec",t.auth_sec)),r.set("access_key",new URL(i).searchParams.get("access_key")),r.set("auth_time",Date.now()),$("#auth").val("1"),e.config.auth="1")})).finally((function(e){return t.auth_clicked=!1}))}}))}}],i&&K(n.prototype,i),o&&K(n,o),Object.defineProperty(n,"prototype",{writable:!1}),t}(),X=new Y;function J(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)}}var Q=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.aid="",this.cid="",this.q="",this.epid=""}var t,n,r;return t=e,(n=[{key:"refresh",value:function(){console.log("refresh..."),$("#video_download").hide(),$("#video_download_2").hide(),I.recover_player();var e=g.base();this.aid=e.aid(),this.cid=e.cid(),this.epid=e.epid(),this.q=g.get_quality().q,window.bp_episodes=null}}])&&J(t.prototype,n),r&&J(t,r),Object.defineProperty(t,"prototype",{writable:!1}),e}());function ee(e,t){const n=Object.create(null),r=e.split(",");for(let e=0;e<r.length;e++)n[r[e]]=!0;return t?e=>!!n[e.toLowerCase()]:e=>!!n[e]}const te="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",ne=ee(te);function re(e){return!!e||""===e}function ie(e){if(we(e)){const t={};for(let n=0;n<e.length;n++){const r=e[n],i=Ce(r)?se(r):ie(r);if(i)for(const e in i)t[e]=i[e]}return t}return Ce(e)||Ae(e)?e:void 0}const oe=/;(?![^(]*\))/g,ae=/:(.+)/;function se(e){const t={};return e.split(oe).forEach((e=>{if(e){const n=e.split(ae);n.length>1&&(t[n[0].trim()]=n[1].trim())}})),t}function le(e){let t="";if(Ce(e))t=e;else if(we(e))for(let n=0;n<e.length;n++){const r=le(e[n]);r&&(t+=r+" ")}else if(Ae(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const ce=(e,t)=>t&&t.__v_isRef?ce(e,t.value):ke(t)?{[`Map(${t.size})`]:[...t.entries()].reduce(((e,[t,n])=>(e[`${t} =>`]=n,e)),{})}:xe(t)?{[`Set(${t.size})`]:[...t.values()]}:!Ae(t)||we(t)||ze(t)?t:String(t),ue={},de=[],fe=()=>{},he=()=>!1,pe=/^on[^a-z]/,_e=e=>pe.test(e),me=e=>e.startsWith("onUpdate:"),ve=Object.assign,ge=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},be=Object.prototype.hasOwnProperty,ye=(e,t)=>be.call(e,t),we=Array.isArray,ke=e=>"[object Map]"===Te(e),xe=e=>"[object Set]"===Te(e),Se=e=>"function"==typeof e,Ce=e=>"string"==typeof e,Ee=e=>"symbol"==typeof e,Ae=e=>null!==e&&"object"==typeof e,Oe=e=>Ae(e)&&Se(e.then)&&Se(e.catch),Ie=Object.prototype.toString,Te=e=>Ie.call(e),ze=e=>"[object Object]"===Te(e),Fe=e=>Ce(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,Re=ee(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Pe=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Be=/-(\w)/g,Le=Pe((e=>e.replace(Be,((e,t)=>t?t.toUpperCase():"")))),De=/\B([A-Z])/g,Ue=Pe((e=>e.replace(De,"-$1").toLowerCase())),je=Pe((e=>e.charAt(0).toUpperCase()+e.slice(1))),$e=Pe((e=>e?`on${je(e)}`:"")),Ne=(e,t)=>!Object.is(e,t),Me=(e,t)=>{for(let n=0;n<e.length;n++)e[n](t)},We=(e,t,n)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},Ve=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let Ze;const He=()=>Ze||(Ze="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==n.g?n.g:{});let qe;class Ge{constructor(e=!1){this.active=!0,this.effects=[],this.cleanups=[],!e&&qe&&(this.parent=qe,this.index=(qe.scopes||(qe.scopes=[])).push(this)-1)}run(e){if(this.active){const t=qe;try{return qe=this,e()}finally{qe=t}}else 0}on(){qe=this}off(){qe=this.parent}stop(e){if(this.active){let t,n;for(t=0,n=this.effects.length;t<n;t++)this.effects[t].stop();for(t=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].stop(!0);if(this.parent&&!e){const e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.active=!1}}}function Ke(e,t=qe){t&&t.active&&t.effects.push(e)}const Ye=e=>{const t=new Set(e);return t.w=0,t.n=0,t},Xe=e=>(e.w&tt)>0,Je=e=>(e.n&tt)>0,Qe=new WeakMap;let et=0,tt=1;let nt;const rt=Symbol(""),it=Symbol("");class ot{constructor(e,t=null,n){this.fn=e,this.scheduler=t,this.active=!0,this.deps=[],this.parent=void 0,Ke(this,n)}run(){if(!this.active)return this.fn();let e=nt,t=st;for(;e;){if(e===this)return;e=e.parent}try{return this.parent=nt,nt=this,st=!0,tt=1<<++et,et<=30?(({deps:e})=>{if(e.length)for(let t=0;t<e.length;t++)e[t].w|=tt})(this):at(this),this.fn()}finally{et<=30&&(e=>{const{deps:t}=e;if(t.length){let n=0;for(let r=0;r<t.length;r++){const i=t[r];Xe(i)&&!Je(i)?i.delete(e):t[n++]=i,i.w&=~tt,i.n&=~tt}t.length=n}})(this),tt=1<<--et,nt=this.parent,st=t,this.parent=void 0,this.deferStop&&this.stop()}}stop(){nt===this?this.deferStop=!0:this.active&&(at(this),this.onStop&&this.onStop(),this.active=!1)}}function at(e){const{deps:t}=e;if(t.length){for(let n=0;n<t.length;n++)t[n].delete(e);t.length=0}}let st=!0;const lt=[];function ct(){lt.push(st),st=!1}function ut(){const e=lt.pop();st=void 0===e||e}function dt(e,t,n){if(st&&nt){let t=Qe.get(e);t||Qe.set(e,t=new Map);let r=t.get(n);r||t.set(n,r=Ye());ft(r,void 0)}}function ft(e,t){let n=!1;et<=30?Je(e)||(e.n|=tt,n=!Xe(e)):n=!e.has(nt),n&&(e.add(nt),nt.deps.push(e))}function ht(e,t,n,r,i,o){const a=Qe.get(e);if(!a)return;let s=[];if("clear"===t)s=[...a.values()];else if("length"===n&&we(e))a.forEach(((e,t)=>{("length"===t||t>=r)&&s.push(e)}));else switch(void 0!==n&&s.push(a.get(n)),t){case"add":we(e)?Fe(n)&&s.push(a.get("length")):(s.push(a.get(rt)),ke(e)&&s.push(a.get(it)));break;case"delete":we(e)||(s.push(a.get(rt)),ke(e)&&s.push(a.get(it)));break;case"set":ke(e)&&s.push(a.get(rt))}if(1===s.length)s[0]&&pt(s[0]);else{const e=[];for(const t of s)t&&e.push(...t);pt(Ye(e))}}function pt(e,t){for(const t of we(e)?e:[...e])(t!==nt||t.allowRecurse)&&(t.scheduler?t.scheduler():t.run())}const _t=ee("__proto__,__v_isRef,__isVue"),mt=new Set(Object.getOwnPropertyNames(Symbol).map((e=>Symbol[e])).filter(Ee)),vt=kt(),gt=kt(!1,!0),bt=kt(!0),yt=wt();function wt(){const e={};return["includes","indexOf","lastIndexOf"].forEach((t=>{e[t]=function(...e){const n=sn(this);for(let e=0,t=this.length;e<t;e++)dt(n,0,e+"");const r=n[t](...e);return-1===r||!1===r?n[t](...e.map(sn)):r}})),["push","pop","shift","unshift","splice"].forEach((t=>{e[t]=function(...e){ct();const n=sn(this)[t].apply(this,e);return ut(),n}})),e}function kt(e=!1,t=!1){return function(n,r,i){if("__v_isReactive"===r)return!e;if("__v_isReadonly"===r)return e;if("__v_isShallow"===r)return t;if("__v_raw"===r&&i===(e?t?Xt:Yt:t?Kt:Gt).get(n))return n;const o=we(n);if(!e&&o&&ye(yt,r))return Reflect.get(yt,r,i);const a=Reflect.get(n,r,i);if(Ee(r)?mt.has(r):_t(r))return a;if(e||dt(n,0,r),t)return a;if(hn(a)){return!o||!Fe(r)?a.value:a}return Ae(a)?e?en(a):Qt(a):a}}function xt(e=!1){return function(t,n,r,i){let o=t[n];if(rn(o)&&hn(o)&&!hn(r))return!1;if(!e&&!rn(r)&&(on(r)||(r=sn(r),o=sn(o)),!we(t)&&hn(o)&&!hn(r)))return o.value=r,!0;const a=we(t)&&Fe(n)?Number(n)<t.length:ye(t,n),s=Reflect.set(t,n,r,i);return t===sn(i)&&(a?Ne(r,o)&&ht(t,"set",n,r):ht(t,"add",n,r)),s}}const St={get:vt,set:xt(),deleteProperty:function(e,t){const n=ye(e,t),r=(e[t],Reflect.deleteProperty(e,t));return r&&n&&ht(e,"delete",t,void 0),r},has:function(e,t){const n=Reflect.has(e,t);return Ee(t)&&mt.has(t)||dt(e,0,t),n},ownKeys:function(e){return dt(e,0,we(e)?"length":rt),Reflect.ownKeys(e)}},Ct={get:bt,set:(e,t)=>!0,deleteProperty:(e,t)=>!0},Et=ve({},St,{get:gt,set:xt(!0)}),At=e=>e,Ot=e=>Reflect.getPrototypeOf(e);function It(e,t,n=!1,r=!1){const i=sn(e=e.__v_raw),o=sn(t);t!==o&&!n&&dt(i,0,t),!n&&dt(i,0,o);const{has:a}=Ot(i),s=r?At:n?un:cn;return a.call(i,t)?s(e.get(t)):a.call(i,o)?s(e.get(o)):void(e!==i&&e.get(t))}function Tt(e,t=!1){const n=this.__v_raw,r=sn(n),i=sn(e);return e!==i&&!t&&dt(r,0,e),!t&&dt(r,0,i),e===i?n.has(e):n.has(e)||n.has(i)}function zt(e,t=!1){return e=e.__v_raw,!t&&dt(sn(e),0,rt),Reflect.get(e,"size",e)}function Ft(e){e=sn(e);const t=sn(this);return Ot(t).has.call(t,e)||(t.add(e),ht(t,"add",e,e)),this}function Rt(e,t){t=sn(t);const n=sn(this),{has:r,get:i}=Ot(n);let o=r.call(n,e);o||(e=sn(e),o=r.call(n,e));const a=i.call(n,e);return n.set(e,t),o?Ne(t,a)&&ht(n,"set",e,t):ht(n,"add",e,t),this}function Pt(e){const t=sn(this),{has:n,get:r}=Ot(t);let i=n.call(t,e);i||(e=sn(e),i=n.call(t,e));r&&r.call(t,e);const o=t.delete(e);return i&&ht(t,"delete",e,void 0),o}function Bt(){const e=sn(this),t=0!==e.size,n=e.clear();return t&&ht(e,"clear",void 0,void 0),n}function Lt(e,t){return function(n,r){const i=this,o=i.__v_raw,a=sn(o),s=t?At:e?un:cn;return!e&&dt(a,0,rt),o.forEach(((e,t)=>n.call(r,s(e),s(t),i)))}}function Dt(e,t,n){return function(...r){const i=this.__v_raw,o=sn(i),a=ke(o),s="entries"===e||e===Symbol.iterator&&a,l="keys"===e&&a,c=i[e](...r),u=n?At:t?un:cn;return!t&&dt(o,0,l?it:rt),{next(){const{value:e,done:t}=c.next();return t?{value:e,done:t}:{value:s?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function Ut(e){return function(...t){return"delete"!==e&&this}}function jt(){const e={get(e){return It(this,e)},get size(){return zt(this)},has:Tt,add:Ft,set:Rt,delete:Pt,clear:Bt,forEach:Lt(!1,!1)},t={get(e){return It(this,e,!1,!0)},get size(){return zt(this)},has:Tt,add:Ft,set:Rt,delete:Pt,clear:Bt,forEach:Lt(!1,!0)},n={get(e){return It(this,e,!0)},get size(){return zt(this,!0)},has(e){return Tt.call(this,e,!0)},add:Ut("add"),set:Ut("set"),delete:Ut("delete"),clear:Ut("clear"),forEach:Lt(!0,!1)},r={get(e){return It(this,e,!0,!0)},get size(){return zt(this,!0)},has(e){return Tt.call(this,e,!0)},add:Ut("add"),set:Ut("set"),delete:Ut("delete"),clear:Ut("clear"),forEach:Lt(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach((i=>{e[i]=Dt(i,!1,!1),n[i]=Dt(i,!0,!1),t[i]=Dt(i,!1,!0),r[i]=Dt(i,!0,!0)})),[e,n,t,r]}const[$t,Nt,Mt,Wt]=jt();function Vt(e,t){const n=t?e?Wt:Mt:e?Nt:$t;return(t,r,i)=>"__v_isReactive"===r?!e:"__v_isReadonly"===r?e:"__v_raw"===r?t:Reflect.get(ye(n,r)&&r in t?n:t,r,i)}const Zt={get:Vt(!1,!1)},Ht={get:Vt(!1,!0)},qt={get:Vt(!0,!1)};const Gt=new WeakMap,Kt=new WeakMap,Yt=new WeakMap,Xt=new WeakMap;function Jt(e){return e.__v_skip||!Object.isExtensible(e)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}((e=>Te(e).slice(8,-1))(e))}function Qt(e){return rn(e)?e:tn(e,!1,St,Zt,Gt)}function en(e){return tn(e,!0,Ct,qt,Yt)}function tn(e,t,n,r,i){if(!Ae(e))return e;if(e.__v_raw&&(!t||!e.__v_isReactive))return e;const o=i.get(e);if(o)return o;const a=Jt(e);if(0===a)return e;const s=new Proxy(e,2===a?r:n);return i.set(e,s),s}function nn(e){return rn(e)?nn(e.__v_raw):!(!e||!e.__v_isReactive)}function rn(e){return!(!e||!e.__v_isReadonly)}function on(e){return!(!e||!e.__v_isShallow)}function an(e){return nn(e)||rn(e)}function sn(e){const t=e&&e.__v_raw;return t?sn(t):e}function ln(e){return We(e,"__v_skip",!0),e}const cn=e=>Ae(e)?Qt(e):e,un=e=>Ae(e)?en(e):e;function dn(e){st&&nt&&ft((e=sn(e)).dep||(e.dep=Ye()))}function fn(e,t){(e=sn(e)).dep&&pt(e.dep)}function hn(e){return!(!e||!0!==e.__v_isRef)}const pn={get:(e,t,n)=>function(e){return hn(e)?e.value:e}(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const i=e[t];return hn(i)&&!hn(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function _n(e){return nn(e)?e:new Proxy(e,pn)}class mn{constructor(e,t,n,r){this._setter=t,this.dep=void 0,this.__v_isRef=!0,this._dirty=!0,this.effect=new ot(e,(()=>{this._dirty||(this._dirty=!0,fn(this))})),this.effect.computed=this,this.effect.active=this._cacheable=!r,this.__v_isReadonly=n}get value(){const e=sn(this);return dn(e),!e._dirty&&e._cacheable||(e._dirty=!1,e._value=e.effect.run()),e._value}set value(e){this._setter(e)}}function vn(e,t,n,r){let i;try{i=r?e(...r):e()}catch(e){bn(e,t,n)}return i}function gn(e,t,n,r){if(Se(e)){const i=vn(e,t,n,r);return i&&Oe(i)&&i.catch((e=>{bn(e,t,n)})),i}const i=[];for(let o=0;o<e.length;o++)i.push(gn(e[o],t,n,r));return i}function bn(e,t,n,r=!0){t&&t.vnode;if(t){let r=t.parent;const i=t.proxy,o=n;for(;r;){const t=r.ec;if(t)for(let n=0;n<t.length;n++)if(!1===t[n](e,i,o))return;r=r.parent}const a=t.appContext.config.errorHandler;if(a)return void vn(a,null,10,[e,i,o])}!function(e,t,n,r=!0){console.error(e)}(e,0,0,r)}let yn=!1,wn=!1;const kn=[];let xn=0;const Sn=[];let Cn=null,En=0;const An=[];let On=null,In=0;const Tn=Promise.resolve();let zn=null,Fn=null;function Rn(e){const t=zn||Tn;return e?t.then(this?e.bind(this):e):t}function Pn(e){kn.length&&kn.includes(e,yn&&e.allowRecurse?xn+1:xn)||e===Fn||(null==e.id?kn.push(e):kn.splice(function(e){let t=xn+1,n=kn.length;for(;t<n;){const r=t+n>>>1;$n(kn[r])<e?t=r+1:n=r}return t}(e.id),0,e),Bn())}function Bn(){yn||wn||(wn=!0,zn=Tn.then(Nn))}function Ln(e,t,n,r){we(e)?n.push(...e):t&&t.includes(e,e.allowRecurse?r+1:r)||n.push(e),Bn()}function Dn(e){Ln(e,On,An,In)}function Un(e,t=null){if(Sn.length){for(Fn=t,Cn=[...new Set(Sn)],Sn.length=0,En=0;En<Cn.length;En++)Cn[En]();Cn=null,En=0,Fn=null,Un(e,t)}}function jn(e){if(An.length){const e=[...new Set(An)];if(An.length=0,On)return void On.push(...e);for(On=e,On.sort(((e,t)=>$n(e)-$n(t))),In=0;In<On.length;In++)On[In]();On=null,In=0}}const $n=e=>null==e.id?1/0:e.id;function Nn(e){wn=!1,yn=!0,Un(e),kn.sort(((e,t)=>$n(e)-$n(t)));try{for(xn=0;xn<kn.length;xn++){const e=kn[xn];e&&!1!==e.active&&vn(e,null,14)}}finally{xn=0,kn.length=0,jn(),yn=!1,zn=null,(kn.length||Sn.length||An.length)&&Nn(e)}}new Set;new Map;let Mn,Wn=[],Vn=!1;function Zn(e,...t){Mn?Mn.emit(e,...t):Vn||Wn.push({event:e,args:t})}function Hn(e,t){var n,r;if(Mn=e,Mn)Mn.enabled=!0,Wn.forEach((({event:e,args:t})=>Mn.emit(e,...t))),Wn=[];else if(
// eslint-disable-next-line no-restricted-globals
"undefined"!=typeof window&&window.HTMLElement&&!(null===(r=null===(n=window.navigator)||void 0===n?void 0:n.userAgent)||void 0===r?void 0:r.includes("jsdom"))){(t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push((e=>{Hn(e,t)})),setTimeout((()=>{Mn||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,Vn=!0,Wn=[])}),3e3)}else Vn=!0,Wn=[]}const qn=Yn("component:added"),Gn=Yn("component:updated"),Kn=Yn("component:removed");function Yn(e){return t=>{Zn(e,t.appContext.app,t.uid,t.parent?t.parent.uid:void 0,t)}}function Xn(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||ue;let i=n;const o=t.startsWith("update:"),a=o&&t.slice(7);if(a&&a in r){const e=`${"modelValue"===a?"model":a}Modifiers`,{number:t,trim:o}=r[e]||ue;o?i=n.map((e=>e.trim())):t&&(i=n.map(Ve))}let s;__VUE_PROD_DEVTOOLS__&&function(e,t,n){Zn("component:emit",e.appContext.app,e,t,n)}(e,t,i);let l=r[s=$e(t)]||r[s=$e(Le(t))];!l&&o&&(l=r[s=$e(Ue(t))]),l&&gn(l,e,6,i);const c=r[s+"Once"];if(c){if(e.emitted){if(e.emitted[s])return}else e.emitted={};e.emitted[s]=!0,gn(c,e,6,i)}}function Jn(e,t,n=!1){const r=t.emitsCache,i=r.get(e);if(void 0!==i)return i;const o=e.emits;let a={},s=!1;if(__VUE_OPTIONS_API__&&!Se(e)){const r=e=>{const n=Jn(e,t,!0);n&&(s=!0,ve(a,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return o||s?(we(o)?o.forEach((e=>a[e]=null)):ve(a,o),r.set(e,a),a):(r.set(e,null),null)}function Qn(e,t){return!(!e||!_e(t))&&(t=t.slice(2).replace(/Once$/,""),ye(e,t[0].toLowerCase()+t.slice(1))||ye(e,Ue(t))||ye(e,t))}let er=null,tr=null;function nr(e){const t=er;return er=e,tr=e&&e.type.__scopeId||null,t}function rr(e,t=er,n){if(!t)return e;if(e._n)return e;const r=(...n)=>{r._d&&Li(-1);const i=nr(t),o=e(...n);return nr(i),r._d&&Li(1),__VUE_PROD_DEVTOOLS__&&Gn(t),o};return r._n=!0,r._c=!0,r._d=!0,r}function ir(e){const{type:t,vnode:n,proxy:r,withProxy:i,props:o,propsOptions:[a],slots:s,attrs:l,emit:c,render:u,renderCache:d,data:f,setupState:h,ctx:p,inheritAttrs:_}=e;let m,v;const g=nr(e);try{if(4&n.shapeFlag){const e=i||r;m=Ji(u.call(e,e,d,o,h,f,p)),v=l}else{const e=t;0,m=Ji(e.length>1?e(o,{attrs:l,slots:s,emit:c}):e(o,null)),v=t.props?l:or(l)}}catch(t){zi.length=0,bn(t,e,1),m=Hi(Ii)}let b=m;if(v&&!1!==_){const e=Object.keys(v),{shapeFlag:t}=b;e.length&&7&t&&(a&&e.some(me)&&(v=ar(v,a)),b=Gi(b,v))}return n.dirs&&(b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&(b.transition=n.transition),m=b,nr(g),m}const or=e=>{let t;for(const n in e)("class"===n||"style"===n||_e(n))&&((t||(t={}))[n]=e[n]);return t},ar=(e,t)=>{const n={};for(const r in e)me(r)&&r.slice(9)in t||(n[r]=e[r]);return n};function sr(e,t,n){const r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){const o=r[i];if(t[o]!==e[o]&&!Qn(n,o))return!0}return!1}function lr({vnode:e,parent:t},n){for(;t&&t.subTree===e;)(e=t.vnode).el=n,t=t.parent}function cr(e,t){t&&t.pendingBranch?we(e)?t.effects.push(...e):t.effects.push(e):Dn(e)}function ur(e,t,n=!1){const r=co||er;if(r){const i=null==r.parent?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides;if(i&&e in i)return i[e];if(arguments.length>1)return n&&Se(t)?t.call(r.proxy):t}else 0}const dr={};function fr(e,t,n){return hr(e,t,n)}function hr(e,t,{immediate:n,deep:r,flush:i,onTrack:o,onTrigger:a}=ue){const s=co;let l,c,u=!1,d=!1;if(hn(e)?(l=()=>e.value,u=on(e)):nn(e)?(l=()=>e,r=!0):we(e)?(d=!0,u=e.some(nn),l=()=>e.map((e=>hn(e)?e.value:nn(e)?mr(e):Se(e)?vn(e,s,2):void 0))):l=Se(e)?t?()=>vn(e,s,2):()=>{if(!s||!s.isUnmounted)return c&&c(),gn(e,s,3,[f])}:fe,t&&r){const e=l;l=()=>mr(e())}let f=e=>{c=m.onStop=()=>{vn(e,s,4)}};if(vo)return f=fe,t?n&&gn(t,s,3,[l(),d?[]:void 0,f]):l(),fe;let h=d?[]:dr;const p=()=>{if(m.active)if(t){const e=m.run();(r||u||(d?e.some(((e,t)=>Ne(e,h[t]))):Ne(e,h)))&&(c&&c(),gn(t,s,3,[e,h===dr?void 0:h,f]),h=e)}else m.run()};let _;p.allowRecurse=!!t,_="sync"===i?p:"post"===i?()=>ki(p,s&&s.suspense):()=>{!s||s.isMounted?function(e){Ln(e,Cn,Sn,En)}(p):p()};const m=new ot(l,_);return t?n?p():h=m.run():"post"===i?ki(m.run.bind(m),s&&s.suspense):m.run(),()=>{m.stop(),s&&s.scope&&ge(s.scope.effects,m)}}function pr(e,t,n){const r=this.proxy,i=Ce(e)?e.includes(".")?_r(r,e):()=>r[e]:e.bind(r,r);let o;Se(t)?o=t:(o=t.handler,n=t);const a=co;fo(this);const s=hr(i,o.bind(r),n);return a?fo(a):ho(),s}function _r(e,t){const n=t.split(".");return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}function mr(e,t){if(!Ae(e)||e.__v_skip)return e;if((t=t||new Set).has(e))return e;if(t.add(e),hn(e))mr(e.value,t);else if(we(e))for(let n=0;n<e.length;n++)mr(e[n],t);else if(xe(e)||ke(e))e.forEach((e=>{mr(e,t)}));else if(ze(e))for(const n in e)mr(e[n],t);return e}function vr(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Ur((()=>{e.isMounted=!0})),Nr((()=>{e.isUnmounting=!0})),e}const gr=[Function,Array],br={name:"BaseTransition",props:{mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:gr,onEnter:gr,onAfterEnter:gr,onEnterCancelled:gr,onBeforeLeave:gr,onLeave:gr,onAfterLeave:gr,onLeaveCancelled:gr,onBeforeAppear:gr,onAppear:gr,onAfterAppear:gr,onAppearCancelled:gr},setup(e,{slots:t}){const n=uo(),r=vr();let i;return()=>{const o=t.default&&Cr(t.default(),!0);if(!o||!o.length)return;let a=o[0];if(o.length>1){let e=!1;for(const t of o)if(t.type!==Ii){0,a=t,e=!0;break}}const s=sn(e),{mode:l}=s;if(r.isLeaving)return kr(a);const c=xr(a);if(!c)return kr(a);const u=wr(c,s,r,n);Sr(c,u);const d=n.subTree,f=d&&xr(d);let h=!1;const{getTransitionKey:p}=c.type;if(p){const e=p();void 0===i?i=e:e!==i&&(i=e,h=!0)}if(f&&f.type!==Ii&&(!Ni(c,f)||h)){const e=wr(f,s,r,n);if(Sr(f,e),"out-in"===l)return r.isLeaving=!0,e.afterLeave=()=>{r.isLeaving=!1,n.update()},kr(a);"in-out"===l&&c.type!==Ii&&(e.delayLeave=(e,t,n)=>{yr(r,f)[String(f.key)]=f,e._leaveCb=()=>{t(),e._leaveCb=void 0,delete u.delayedLeave},u.delayedLeave=n})}return a}}};function yr(e,t){const{leavingVNodes:n}=e;let r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function wr(e,t,n,r){const{appear:i,mode:o,persisted:a=!1,onBeforeEnter:s,onEnter:l,onAfterEnter:c,onEnterCancelled:u,onBeforeLeave:d,onLeave:f,onAfterLeave:h,onLeaveCancelled:p,onBeforeAppear:_,onAppear:m,onAfterAppear:v,onAppearCancelled:g}=t,b=String(e.key),y=yr(n,e),w=(e,t)=>{e&&gn(e,r,9,t)},k={mode:o,persisted:a,beforeEnter(t){let r=s;if(!n.isMounted){if(!i)return;r=_||s}t._leaveCb&&t._leaveCb(!0);const o=y[b];o&&Ni(e,o)&&o.el._leaveCb&&o.el._leaveCb(),w(r,[t])},enter(e){let t=l,r=c,o=u;if(!n.isMounted){if(!i)return;t=m||l,r=v||c,o=g||u}let a=!1;const s=e._enterCb=t=>{a||(a=!0,w(t?o:r,[e]),k.delayedLeave&&k.delayedLeave(),e._enterCb=void 0)};t?(t(e,s),t.length<=1&&s()):s()},leave(t,r){const i=String(e.key);if(t._enterCb&&t._enterCb(!0),n.isUnmounting)return r();w(d,[t]);let o=!1;const a=t._leaveCb=n=>{o||(o=!0,r(),w(n?p:h,[t]),t._leaveCb=void 0,y[i]===e&&delete y[i])};y[i]=e,f?(f(t,a),f.length<=1&&a()):a()},clone:e=>wr(e,t,n,r)};return k}function kr(e){if(Ar(e))return(e=Gi(e)).children=null,e}function xr(e){return Ar(e)?e.children?e.children[0]:void 0:e}function Sr(e,t){6&e.shapeFlag&&e.component?Sr(e.component.subTree,t):128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Cr(e,t=!1,n){let r=[],i=0;for(let o=0;o<e.length;o++){let a=e[o];const s=null==n?a.key:String(n)+String(null!=a.key?a.key:o);a.type===Ai?(128&a.patchFlag&&i++,r=r.concat(Cr(a.children,t,s))):(t||a.type!==Ii)&&r.push(null!=s?Gi(a,{key:s}):a)}if(i>1)for(let e=0;e<r.length;e++)r[e].patchFlag=-2;return r}const Er=e=>!!e.type.__asyncLoader;const Ar=e=>e.type.__isKeepAlive;RegExp,RegExp;function Or(e,t){return we(e)?e.some((e=>Or(e,t))):Ce(e)?e.split(",").includes(t):!!e.test&&e.test(t)}function Ir(e,t){zr(e,"a",t)}function Tr(e,t){zr(e,"da",t)}function zr(e,t,n=co){const r=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()});if(Br(t,r,n),n){let e=n.parent;for(;e&&e.parent;)Ar(e.parent.vnode)&&Fr(r,t,n,e),e=e.parent}}function Fr(e,t,n,r){const i=Br(t,e,r,!0);Mr((()=>{ge(r[t],i)}),n)}function Rr(e){let t=e.shapeFlag;256&t&&256,512&t&&512,e.shapeFlag=t}function Pr(e){return 128&e.shapeFlag?e.ssContent:e}function Br(e,t,n=co,r=!1){if(n){const i=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...r)=>{if(n.isUnmounted)return;ct(),fo(n);const i=gn(t,n,e,r);return ho(),ut(),i});return r?i.unshift(o):i.push(o),o}}const Lr=e=>(t,n=co)=>(!vo||"sp"===e)&&Br(e,t,n),Dr=Lr("bm"),Ur=Lr("m"),jr=Lr("bu"),$r=Lr("u"),Nr=Lr("bum"),Mr=Lr("um"),Wr=Lr("sp"),Vr=Lr("rtg"),Zr=Lr("rtc");function Hr(e,t=co){Br("ec",e,t)}let qr=!0;function Gr(e){const t=Xr(e),n=e.proxy,r=e.ctx;qr=!1,t.beforeCreate&&Kr(t.beforeCreate,e,"bc");const{data:i,computed:o,methods:a,watch:s,provide:l,inject:c,created:u,beforeMount:d,mounted:f,beforeUpdate:h,updated:p,activated:_,deactivated:m,beforeDestroy:v,beforeUnmount:g,destroyed:b,unmounted:y,render:w,renderTracked:k,renderTriggered:x,errorCaptured:S,serverPrefetch:C,expose:E,inheritAttrs:A,components:O,directives:I,filters:T}=t;if(c&&function(e,t,n=fe,r=!1){we(e)&&(e=ti(e));for(const n in e){const i=e[n];let o;o=Ae(i)?"default"in i?ur(i.from||n,i.default,!0):ur(i.from||n):ur(i),hn(o)&&r?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>o.value,set:e=>o.value=e}):t[n]=o}}(c,r,null,e.appContext.config.unwrapInjectedRef),a)for(const e in a){const t=a[e];Se(t)&&(r[e]=t.bind(n))}if(i){0;const t=i.call(n,n);0,Ae(t)&&(e.data=Qt(t))}if(qr=!0,o)for(const e in o){const t=o[e],i=Se(t)?t.bind(n,n):Se(t.get)?t.get.bind(n,n):fe;0;const a=!Se(t)&&Se(t.set)?t.set.bind(n):fe,s=Co({get:i,set:a});Object.defineProperty(r,e,{enumerable:!0,configurable:!0,get:()=>s.value,set:e=>s.value=e})}if(s)for(const e in s)Yr(s[e],r,n,e);if(l){const e=Se(l)?l.call(n):l;Reflect.ownKeys(e).forEach((t=>{!function(e,t){if(co){let n=co.provides;const r=co.parent&&co.parent.provides;r===n&&(n=co.provides=Object.create(r)),n[e]=t}}(t,e[t])}))}function z(e,t){we(t)?t.forEach((t=>e(t.bind(n)))):t&&e(t.bind(n))}if(u&&Kr(u,e,"c"),z(Dr,d),z(Ur,f),z(jr,h),z($r,p),z(Ir,_),z(Tr,m),z(Hr,S),z(Zr,k),z(Vr,x),z(Nr,g),z(Mr,y),z(Wr,C),we(E))if(E.length){const t=e.exposed||(e.exposed={});E.forEach((e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t})}))}else e.exposed||(e.exposed={});w&&e.render===fe&&(e.render=w),null!=A&&(e.inheritAttrs=A),O&&(e.components=O),I&&(e.directives=I)}function Kr(e,t,n){gn(we(e)?e.map((e=>e.bind(t.proxy))):e.bind(t.proxy),t,n)}function Yr(e,t,n,r){const i=r.includes(".")?_r(n,r):()=>n[r];if(Ce(e)){const n=t[e];Se(n)&&fr(i,n)}else if(Se(e))fr(i,e.bind(n));else if(Ae(e))if(we(e))e.forEach((e=>Yr(e,t,n,r)));else{const r=Se(e.handler)?e.handler.bind(n):t[e.handler];Se(r)&&fr(i,r,e)}else 0}function Xr(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:o,config:{optionMergeStrategies:a}}=e.appContext,s=o.get(t);let l;return s?l=s:i.length||n||r?(l={},i.length&&i.forEach((e=>Jr(l,e,a,!0))),Jr(l,t,a)):l=t,o.set(t,l),l}function Jr(e,t,n,r=!1){const{mixins:i,extends:o}=t;o&&Jr(e,o,n,!0),i&&i.forEach((t=>Jr(e,t,n,!0)));for(const i in t)if(r&&"expose"===i);else{const r=Qr[i]||n&&n[i];e[i]=r?r(e[i],t[i]):t[i]}return e}const Qr={data:ei,props:ri,emits:ri,methods:ri,computed:ri,beforeCreate:ni,created:ni,beforeMount:ni,mounted:ni,beforeUpdate:ni,updated:ni,beforeDestroy:ni,beforeUnmount:ni,destroyed:ni,unmounted:ni,activated:ni,deactivated:ni,errorCaptured:ni,serverPrefetch:ni,components:ri,directives:ri,watch:function(e,t){if(!e)return t;if(!t)return e;const n=ve(Object.create(null),e);for(const r in t)n[r]=ni(e[r],t[r]);return n},provide:ei,inject:function(e,t){return ri(ti(e),ti(t))}};function ei(e,t){return t?e?function(){return ve(Se(e)?e.call(this,this):e,Se(t)?t.call(this,this):t)}:t:e}function ti(e){if(we(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function ni(e,t){return e?[...new Set([].concat(e,t))]:t}function ri(e,t){return e?ve(ve(Object.create(null),e),t):t}function ii(e,t,n,r=!1){const i={},o={};We(o,Mi,1),e.propsDefaults=Object.create(null),oi(e,t,i,o);for(const t in e.propsOptions[0])t in i||(i[t]=void 0);n?e.props=r?i:tn(i,!1,Et,Ht,Kt):e.type.props?e.props=i:e.props=o,e.attrs=o}function oi(e,t,n,r){const[i,o]=e.propsOptions;let a,s=!1;if(t)for(let l in t){if(Re(l))continue;const c=t[l];let u;i&&ye(i,u=Le(l))?o&&o.includes(u)?(a||(a={}))[u]=c:n[u]=c:Qn(e.emitsOptions,l)||l in r&&c===r[l]||(r[l]=c,s=!0)}if(o){const t=sn(n),r=a||ue;for(let a=0;a<o.length;a++){const s=o[a];n[s]=ai(i,t,s,r[s],e,!ye(r,s))}}return s}function ai(e,t,n,r,i,o){const a=e[n];if(null!=a){const e=ye(a,"default");if(e&&void 0===r){const e=a.default;if(a.type!==Function&&Se(e)){const{propsDefaults:o}=i;n in o?r=o[n]:(fo(i),r=o[n]=e.call(null,t),ho())}else r=e}a[0]&&(o&&!e?r=!1:!a[1]||""!==r&&r!==Ue(n)||(r=!0))}return r}function si(e,t,n=!1){const r=t.propsCache,i=r.get(e);if(i)return i;const o=e.props,a={},s=[];let l=!1;if(__VUE_OPTIONS_API__&&!Se(e)){const r=e=>{l=!0;const[n,r]=si(e,t,!0);ve(a,n),r&&s.push(...r)};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}if(!o&&!l)return r.set(e,de),de;if(we(o))for(let e=0;e<o.length;e++){0;const t=Le(o[e]);li(t)&&(a[t]=ue)}else if(o){0;for(const e in o){const t=Le(e);if(li(t)){const n=o[e],r=a[t]=we(n)||Se(n)?{type:n}:n;if(r){const e=di(Boolean,r.type),n=di(String,r.type);r[0]=e>-1,r[1]=n<0||e<n,(e>-1||ye(r,"default"))&&s.push(t)}}}}const c=[a,s];return r.set(e,c),c}function li(e){return"$"!==e[0]}function ci(e){const t=e&&e.toString().match(/^\s*function (\w+)/);return t?t[1]:null===e?"null":""}function ui(e,t){return ci(e)===ci(t)}function di(e,t){return we(t)?t.findIndex((t=>ui(t,e))):Se(t)&&ui(t,e)?0:-1}const fi=e=>"_"===e[0]||"$stable"===e,hi=e=>we(e)?e.map(Ji):[Ji(e)],pi=(e,t,n)=>{const r=rr(((...e)=>hi(t(...e))),n);return r._c=!1,r},_i=(e,t,n)=>{const r=e._ctx;for(const n in e){if(fi(n))continue;const i=e[n];if(Se(i))t[n]=pi(0,i,r);else if(null!=i){0;const e=hi(i);t[n]=()=>e}}},mi=(e,t)=>{const n=hi(t);e.slots.default=()=>n};function vi(e,t,n,r){const i=e.dirs,o=t&&t.dirs;for(let a=0;a<i.length;a++){const s=i[a];o&&(s.oldValue=o[a].value);let l=s.dir[r];l&&(ct(),gn(l,n,8,[e.el,s,e,t]),ut())}}function gi(){return{app:null,config:{isNativeTag:he,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let bi=0;function yi(e,t){return function(n,r=null){Se(n)||(n=Object.assign({},n)),null==r||Ae(r)||(r=null);const i=gi(),o=new Set;let a=!1;const s=i.app={_uid:bi++,_component:n,_props:r,_container:null,_context:i,_instance:null,version:Eo,get config(){return i.config},set config(e){0},use:(e,...t)=>(o.has(e)||(e&&Se(e.install)?(o.add(e),e.install(s,...t)):Se(e)&&(o.add(e),e(s,...t))),s),mixin:e=>(__VUE_OPTIONS_API__&&(i.mixins.includes(e)||i.mixins.push(e)),s),component:(e,t)=>t?(i.components[e]=t,s):i.components[e],directive:(e,t)=>t?(i.directives[e]=t,s):i.directives[e],mount(o,l,c){if(!a){const u=Hi(n,r);return u.appContext=i,l&&t?t(u,o):e(u,o,c),a=!0,s._container=o,o.__vue_app__=s,__VUE_PROD_DEVTOOLS__&&(s._instance=u.component,function(e,t){Zn("app:init",e,t,{Fragment:Ai,Text:Oi,Comment:Ii,Static:Ti})}(s,Eo)),ko(u.component)||u.component.proxy}},unmount(){a&&(e(null,s._container),__VUE_PROD_DEVTOOLS__&&(s._instance=null,function(e){Zn("app:unmount",e)}(s)),delete s._container.__vue_app__)},provide:(e,t)=>(i.provides[e]=t,s)};return s}}function wi(e,t,n,r,i=!1){if(we(e))return void e.forEach(((e,o)=>wi(e,t&&(we(t)?t[o]:t),n,r,i)));if(Er(r)&&!i)return;const o=4&r.shapeFlag?ko(r.component)||r.component.proxy:r.el,a=i?null:o,{i:s,r:l}=e;const c=t&&t.r,u=s.refs===ue?s.refs={}:s.refs,d=s.setupState;if(null!=c&&c!==l&&(Ce(c)?(u[c]=null,ye(d,c)&&(d[c]=null)):hn(c)&&(c.value=null)),Se(l))vn(l,s,12,[a,u]);else{const t=Ce(l),r=hn(l);if(t||r){const r=()=>{if(e.f){const n=t?u[l]:l.value;i?we(n)&&ge(n,o):we(n)?n.includes(o)||n.push(o):t?(u[l]=[o],ye(d,l)&&(d[l]=u[l])):(l.value=[o],e.k&&(u[e.k]=l.value))}else t?(u[l]=a,ye(d,l)&&(d[l]=a)):hn(l)&&(l.value=a,e.k&&(u[e.k]=a))};a?(r.id=-1,ki(r,n)):r()}else 0}}const ki=cr;function xi(e,t){"boolean"!=typeof __VUE_OPTIONS_API__&&(He().__VUE_OPTIONS_API__=!0),"boolean"!=typeof __VUE_PROD_DEVTOOLS__&&(He().__VUE_PROD_DEVTOOLS__=!1);const n=He();n.__VUE__=!0,__VUE_PROD_DEVTOOLS__&&Hn(n.__VUE_DEVTOOLS_GLOBAL_HOOK__,n);const{insert:r,remove:i,patchProp:o,createElement:a,createText:s,createComment:l,setText:c,setElementText:u,parentNode:d,nextSibling:f,setScopeId:h=fe,cloneNode:p,insertStaticContent:_}=e,m=(e,t,n,r=null,i=null,o=null,a=!1,s=null,l=!!t.dynamicChildren)=>{if(e===t)return;e&&!Ni(e,t)&&(r=W(e),U(e,i,o,!0),e=null),-2===t.patchFlag&&(l=!1,t.dynamicChildren=null);const{type:c,ref:u,shapeFlag:d}=t;switch(c){case Oi:v(e,t,n,r);break;case Ii:g(e,t,n,r);break;case Ti:null==e&&b(t,n,r,a);break;case Ai:O(e,t,n,r,i,o,a,s,l);break;default:1&d?w(e,t,n,r,i,o,a,s,l):6&d?I(e,t,n,r,i,o,a,s,l):(64&d||128&d)&&c.process(e,t,n,r,i,o,a,s,l,Z)}null!=u&&i&&wi(u,e&&e.ref,o,t||e,!t)},v=(e,t,n,i)=>{if(null==e)r(t.el=s(t.children),n,i);else{const n=t.el=e.el;t.children!==e.children&&c(n,t.children)}},g=(e,t,n,i)=>{null==e?r(t.el=l(t.children||""),n,i):t.el=e.el},b=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},y=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=f(e),i(e),e=n;i(t)},w=(e,t,n,r,i,o,a,s,l)=>{a=a||"svg"===t.type,null==e?k(t,n,r,i,o,a,s,l):C(e,t,i,o,a,s,l)},k=(e,t,n,i,s,l,c,d)=>{let f,h;const{type:_,props:m,shapeFlag:v,transition:g,patchFlag:b,dirs:y}=e;if(e.el&&void 0!==p&&-1===b)f=e.el=p(e.el);else{if(f=e.el=a(e.type,l,m&&m.is,m),8&v?u(f,e.children):16&v&&S(e.children,f,null,i,s,l&&"foreignObject"!==_,c,d),y&&vi(e,null,i,"created"),m){for(const t in m)"value"===t||Re(t)||o(f,t,null,m[t],l,e.children,i,s,M);"value"in m&&o(f,"value",null,m.value),(h=m.onVnodeBeforeMount)&&to(h,i,e)}x(f,e,e.scopeId,c,i)}__VUE_PROD_DEVTOOLS__&&(Object.defineProperty(f,"__vnode",{value:e,enumerable:!1}),Object.defineProperty(f,"__vueParentComponent",{value:i,enumerable:!1})),y&&vi(e,null,i,"beforeMount");const w=(!s||s&&!s.pendingBranch)&&g&&!g.persisted;w&&g.beforeEnter(f),r(f,t,n),((h=m&&m.onVnodeMounted)||w||y)&&ki((()=>{h&&to(h,i,e),w&&g.enter(f),y&&vi(e,null,i,"mounted")}),s)},x=(e,t,n,r,i)=>{if(n&&h(e,n),r)for(let t=0;t<r.length;t++)h(e,r[t]);if(i){if(t===i.subTree){const t=i.vnode;x(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},S=(e,t,n,r,i,o,a,s,l=0)=>{for(let c=l;c<e.length;c++){const l=e[c]=s?Qi(e[c]):Ji(e[c]);m(null,l,t,n,r,i,o,a,s)}},C=(e,t,n,r,i,a,s)=>{const l=t.el=e.el;let{patchFlag:c,dynamicChildren:d,dirs:f}=t;c|=16&e.patchFlag;const h=e.props||ue,p=t.props||ue;let _;n&&Si(n,!1),(_=p.onVnodeBeforeUpdate)&&to(_,n,t,e),f&&vi(t,e,n,"beforeUpdate"),n&&Si(n,!0);const m=i&&"foreignObject"!==t.type;if(d?E(e.dynamicChildren,d,l,n,r,m,a):s||P(e,t,l,null,n,r,m,a,!1),c>0){if(16&c)A(l,t,h,p,n,r,i);else if(2&c&&h.class!==p.class&&o(l,"class",null,p.class,i),4&c&&o(l,"style",h.style,p.style,i),8&c){const a=t.dynamicProps;for(let t=0;t<a.length;t++){const s=a[t],c=h[s],u=p[s];u===c&&"value"!==s||o(l,s,c,u,i,e.children,n,r,M)}}1&c&&e.children!==t.children&&u(l,t.children)}else s||null!=d||A(l,t,h,p,n,r,i);((_=p.onVnodeUpdated)||f)&&ki((()=>{_&&to(_,n,t,e),f&&vi(t,e,n,"updated")}),r)},E=(e,t,n,r,i,o,a)=>{for(let s=0;s<t.length;s++){const l=e[s],c=t[s],u=l.el&&(l.type===Ai||!Ni(l,c)||70&l.shapeFlag)?d(l.el):n;m(l,c,u,null,r,i,o,a,!0)}},A=(e,t,n,r,i,a,s)=>{if(n!==r){for(const l in r){if(Re(l))continue;const c=r[l],u=n[l];c!==u&&"value"!==l&&o(e,l,u,c,s,t.children,i,a,M)}if(n!==ue)for(const l in n)Re(l)||l in r||o(e,l,n[l],null,s,t.children,i,a,M);"value"in r&&o(e,"value",n.value,r.value)}},O=(e,t,n,i,o,a,l,c,u)=>{const d=t.el=e?e.el:s(""),f=t.anchor=e?e.anchor:s("");let{patchFlag:h,dynamicChildren:p,slotScopeIds:_}=t;_&&(c=c?c.concat(_):_),null==e?(r(d,n,i),r(f,n,i),S(t.children,n,f,o,a,l,c,u)):h>0&&64&h&&p&&e.dynamicChildren?(E(e.dynamicChildren,p,n,o,a,l,c),(null!=t.key||o&&t===o.subTree)&&Ci(e,t,!0)):P(e,t,n,f,o,a,l,c,u)},I=(e,t,n,r,i,o,a,s,l)=>{t.slotScopeIds=s,null==e?512&t.shapeFlag?i.ctx.activate(t,n,r,a,l):T(t,n,r,i,o,a,l):z(e,t,l)},T=(e,t,n,r,i,o,a)=>{const s=e.component=lo(e,r,i);if(Ar(e)&&(s.ctx.renderer=Z),go(s),s.asyncDep){if(i&&i.registerDep(s,F),!e.el){const e=s.subTree=Hi(Ii);g(null,e,t,n)}}else F(s,e,t,n,i,o,a)},z=(e,t,n)=>{const r=t.component=e.component;if(function(e,t,n){const{props:r,children:i,component:o}=e,{props:a,children:s,patchFlag:l}=t,c=o.emitsOptions;if(t.dirs||t.transition)return!0;if(!(n&&l>=0))return!(!i&&!s||s&&s.$stable)||r!==a&&(r?!a||sr(r,a,c):!!a);if(1024&l)return!0;if(16&l)return r?sr(r,a,c):!!a;if(8&l){const e=t.dynamicProps;for(let t=0;t<e.length;t++){const n=e[t];if(a[n]!==r[n]&&!Qn(c,n))return!0}}return!1}(e,t,n)){if(r.asyncDep&&!r.asyncResolved)return void R(r,t,n);r.next=t,function(e){const t=kn.indexOf(e);t>xn&&kn.splice(t,1)}(r.update),r.update()}else t.component=e.component,t.el=e.el,r.vnode=t},F=(e,t,n,r,i,o,a)=>{const s=e.effect=new ot((()=>{if(e.isMounted){let t,{next:n,bu:r,u:s,parent:l,vnode:c}=e,u=n;0,Si(e,!1),n?(n.el=c.el,R(e,n,a)):n=c,r&&Me(r),(t=n.props&&n.props.onVnodeBeforeUpdate)&&to(t,l,n,c),Si(e,!0);const f=ir(e);0;const h=e.subTree;e.subTree=f,m(h,f,d(h.el),W(h),e,i,o),n.el=f.el,null===u&&lr(e,f.el),s&&ki(s,i),(t=n.props&&n.props.onVnodeUpdated)&&ki((()=>to(t,l,n,c)),i),__VUE_PROD_DEVTOOLS__&&Gn(e)}else{let a;const{el:s,props:l}=t,{bm:c,m:u,parent:d}=e,f=Er(t);if(Si(e,!1),c&&Me(c),!f&&(a=l&&l.onVnodeBeforeMount)&&to(a,d,t),Si(e,!0),s&&q){const n=()=>{e.subTree=ir(e),q(s,e.subTree,e,i,null)};f?t.type.__asyncLoader().then((()=>!e.isUnmounted&&n())):n()}else{0;const a=e.subTree=ir(e);0,m(null,a,n,r,e,i,o),t.el=a.el}if(u&&ki(u,i),!f&&(a=l&&l.onVnodeMounted)){const e=t;ki((()=>to(a,d,e)),i)}256&t.shapeFlag&&e.a&&ki(e.a,i),e.isMounted=!0,__VUE_PROD_DEVTOOLS__&&qn(e),t=n=r=null}}),(()=>Pn(e.update)),e.scope),l=e.update=s.run.bind(s);l.id=e.uid,Si(e,!0),l()},R=(e,t,n)=>{t.component=e;const r=e.vnode.props;e.vnode=t,e.next=null,function(e,t,n,r){const{props:i,attrs:o,vnode:{patchFlag:a}}=e,s=sn(i),[l]=e.propsOptions;let c=!1;if(!(r||a>0)||16&a){let r;oi(e,t,i,o)&&(c=!0);for(const o in s)t&&(ye(t,o)||(r=Ue(o))!==o&&ye(t,r))||(l?!n||void 0===n[o]&&void 0===n[r]||(i[o]=ai(l,s,o,void 0,e,!0)):delete i[o]);if(o!==s)for(const e in o)t&&ye(t,e)||(delete o[e],c=!0)}else if(8&a){const n=e.vnode.dynamicProps;for(let r=0;r<n.length;r++){let a=n[r];if(Qn(e.emitsOptions,a))continue;const u=t[a];if(l)if(ye(o,a))u!==o[a]&&(o[a]=u,c=!0);else{const t=Le(a);i[t]=ai(l,s,t,u,e,!1)}else u!==o[a]&&(o[a]=u,c=!0)}}c&&ht(e,"set","$attrs")}(e,t.props,r,n),((e,t,n)=>{const{vnode:r,slots:i}=e;let o=!0,a=ue;if(32&r.shapeFlag){const e=t._;e?n&&1===e?o=!1:(ve(i,t),n||1!==e||delete i._):(o=!t.$stable,_i(t,i)),a=t}else t&&(mi(e,t),a={default:1});if(o)for(const e in i)fi(e)||e in a||delete i[e]})(e,t.children,n),ct(),Un(void 0,e.update),ut()},P=(e,t,n,r,i,o,a,s,l=!1)=>{const c=e&&e.children,d=e?e.shapeFlag:0,f=t.children,{patchFlag:h,shapeFlag:p}=t;if(h>0){if(128&h)return void L(c,f,n,r,i,o,a,s,l);if(256&h)return void B(c,f,n,r,i,o,a,s,l)}8&p?(16&d&&M(c,i,o),f!==c&&u(n,f)):16&d?16&p?L(c,f,n,r,i,o,a,s,l):M(c,i,o,!0):(8&d&&u(n,""),16&p&&S(f,n,r,i,o,a,s,l))},B=(e,t,n,r,i,o,a,s,l)=>{t=t||de;const c=(e=e||de).length,u=t.length,d=Math.min(c,u);let f;for(f=0;f<d;f++){const r=t[f]=l?Qi(t[f]):Ji(t[f]);m(e[f],r,n,null,i,o,a,s,l)}c>u?M(e,i,o,!0,!1,d):S(t,n,r,i,o,a,s,l,d)},L=(e,t,n,r,i,o,a,s,l)=>{let c=0;const u=t.length;let d=e.length-1,f=u-1;for(;c<=d&&c<=f;){const r=e[c],u=t[c]=l?Qi(t[c]):Ji(t[c]);if(!Ni(r,u))break;m(r,u,n,null,i,o,a,s,l),c++}for(;c<=d&&c<=f;){const r=e[d],c=t[f]=l?Qi(t[f]):Ji(t[f]);if(!Ni(r,c))break;m(r,c,n,null,i,o,a,s,l),d--,f--}if(c>d){if(c<=f){const e=f+1,d=e<u?t[e].el:r;for(;c<=f;)m(null,t[c]=l?Qi(t[c]):Ji(t[c]),n,d,i,o,a,s,l),c++}}else if(c>f)for(;c<=d;)U(e[c],i,o,!0),c++;else{const h=c,p=c,_=new Map;for(c=p;c<=f;c++){const e=t[c]=l?Qi(t[c]):Ji(t[c]);null!=e.key&&_.set(e.key,c)}let v,g=0;const b=f-p+1;let y=!1,w=0;const k=new Array(b);for(c=0;c<b;c++)k[c]=0;for(c=h;c<=d;c++){const r=e[c];if(g>=b){U(r,i,o,!0);continue}let u;if(null!=r.key)u=_.get(r.key);else for(v=p;v<=f;v++)if(0===k[v-p]&&Ni(r,t[v])){u=v;break}void 0===u?U(r,i,o,!0):(k[u-p]=c+1,u>=w?w=u:y=!0,m(r,t[u],n,null,i,o,a,s,l),g++)}const x=y?function(e){const t=e.slice(),n=[0];let r,i,o,a,s;const l=e.length;for(r=0;r<l;r++){const l=e[r];if(0!==l){if(i=n[n.length-1],e[i]<l){t[r]=i,n.push(r);continue}for(o=0,a=n.length-1;o<a;)s=o+a>>1,e[n[s]]<l?o=s+1:a=s;l<e[n[o]]&&(o>0&&(t[r]=n[o-1]),n[o]=r)}}o=n.length,a=n[o-1];for(;o-- >0;)n[o]=a,a=t[a];return n}(k):de;for(v=x.length-1,c=b-1;c>=0;c--){const e=p+c,d=t[e],f=e+1<u?t[e+1].el:r;0===k[c]?m(null,d,n,f,i,o,a,s,l):y&&(v<0||c!==x[v]?D(d,n,f,2):v--)}}},D=(e,t,n,i,o=null)=>{const{el:a,type:s,transition:l,children:c,shapeFlag:u}=e;if(6&u)return void D(e.component.subTree,t,n,i);if(128&u)return void e.suspense.move(t,n,i);if(64&u)return void s.move(e,t,n,Z);if(s===Ai){r(a,t,n);for(let e=0;e<c.length;e++)D(c[e],t,n,i);return void r(e.anchor,t,n)}if(s===Ti)return void(({el:e,anchor:t},n,i)=>{let o;for(;e&&e!==t;)o=f(e),r(e,n,i),e=o;r(t,n,i)})(e,t,n);if(2!==i&&1&u&&l)if(0===i)l.beforeEnter(a),r(a,t,n),ki((()=>l.enter(a)),o);else{const{leave:e,delayLeave:i,afterLeave:o}=l,s=()=>r(a,t,n),c=()=>{e(a,(()=>{s(),o&&o()}))};i?i(a,s,c):c()}else r(a,t,n)},U=(e,t,n,r=!1,i=!1)=>{const{type:o,props:a,ref:s,children:l,dynamicChildren:c,shapeFlag:u,patchFlag:d,dirs:f}=e;if(null!=s&&wi(s,null,n,e,!0),256&u)return void t.ctx.deactivate(e);const h=1&u&&f,p=!Er(e);let _;if(p&&(_=a&&a.onVnodeBeforeUnmount)&&to(_,t,e),6&u)N(e.component,n,r);else{if(128&u)return void e.suspense.unmount(n,r);h&&vi(e,null,t,"beforeUnmount"),64&u?e.type.remove(e,t,n,i,Z,r):c&&(o!==Ai||d>0&&64&d)?M(c,t,n,!1,!0):(o===Ai&&384&d||!i&&16&u)&&M(l,t,n),r&&j(e)}(p&&(_=a&&a.onVnodeUnmounted)||h)&&ki((()=>{_&&to(_,t,e),h&&vi(e,null,t,"unmounted")}),n)},j=e=>{const{type:t,el:n,anchor:r,transition:o}=e;if(t===Ai)return void $(n,r);if(t===Ti)return void y(e);const a=()=>{i(n),o&&!o.persisted&&o.afterLeave&&o.afterLeave()};if(1&e.shapeFlag&&o&&!o.persisted){const{leave:t,delayLeave:r}=o,i=()=>t(n,a);r?r(e.el,a,i):i()}else a()},$=(e,t)=>{let n;for(;e!==t;)n=f(e),i(e),e=n;i(t)},N=(e,t,n)=>{const{bum:r,scope:i,update:o,subTree:a,um:s}=e;r&&Me(r),i.stop(),o&&(o.active=!1,U(a,e,t,n)),s&&ki(s,t),ki((()=>{e.isUnmounted=!0}),t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve()),__VUE_PROD_DEVTOOLS__&&Kn(e)},M=(e,t,n,r=!1,i=!1,o=0)=>{for(let a=o;a<e.length;a++)U(e[a],t,n,r,i)},W=e=>6&e.shapeFlag?W(e.component.subTree):128&e.shapeFlag?e.suspense.next():f(e.anchor||e.el),V=(e,t,n)=>{null==e?t._vnode&&U(t._vnode,null,null,!0):m(t._vnode||null,e,t,null,null,null,n),jn(),t._vnode=e},Z={p:m,um:U,m:D,r:j,mt:T,mc:S,pc:P,pbc:E,n:W,o:e};let H,q;return t&&([H,q]=t(Z)),{render:V,hydrate:H,createApp:yi(V,H)}}function Si({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function Ci(e,t,n=!1){const r=e.children,i=t.children;if(we(r)&&we(i))for(let e=0;e<r.length;e++){const t=r[e];let o=i[e];1&o.shapeFlag&&!o.dynamicChildren&&((o.patchFlag<=0||32===o.patchFlag)&&(o=i[e]=Qi(i[e]),o.el=t.el),n||Ci(t,o))}}const Ei=Symbol();const Ai=Symbol(void 0),Oi=Symbol(void 0),Ii=Symbol(void 0),Ti=Symbol(void 0),zi=[];let Fi=null;function Ri(e=!1){zi.push(Fi=e?null:[])}function Pi(){zi.pop(),Fi=zi[zi.length-1]||null}let Bi=1;function Li(e){Bi+=e}function Di(e){return e.dynamicChildren=Bi>0?Fi||de:null,Pi(),Bi>0&&Fi&&Fi.push(e),e}function Ui(e,t,n,r,i,o){return Di(Zi(e,t,n,r,i,o,!0))}function ji(e,t,n,r,i){return Di(Hi(e,t,n,r,i,!0))}function $i(e){return!!e&&!0===e.__v_isVNode}function Ni(e,t){return e.type===t.type&&e.key===t.key}const Mi="__vInternal",Wi=({key:e})=>null!=e?e:null,Vi=({ref:e,ref_key:t,ref_for:n})=>null!=e?Ce(e)||hn(e)||Se(e)?{i:er,r:e,k:t,f:!!n}:e:null;function Zi(e,t=null,n=null,r=0,i=null,o=(e===Ai?0:1),a=!1,s=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Wi(t),ref:t&&Vi(t),scopeId:tr,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null};return s?(eo(l,n),128&o&&e.normalize(l)):n&&(l.shapeFlag|=Ce(n)?8:16),Bi>0&&!a&&Fi&&(l.patchFlag>0||6&o)&&32!==l.patchFlag&&Fi.push(l),l}const Hi=qi;function qi(e,t=null,n=null,r=0,i=null,o=!1){if(e&&e!==Ei||(e=Ii),$i(e)){const r=Gi(e,t,!0);return n&&eo(r,n),r}if(So(e)&&(e=e.__vccOpts),t){t=function(e){return e?an(e)||Mi in e?ve({},e):e:null}(t);let{class:e,style:n}=t;e&&!Ce(e)&&(t.class=le(e)),Ae(n)&&(an(n)&&!we(n)&&(n=ve({},n)),t.style=ie(n))}return Zi(e,t,n,r,i,Ce(e)?1:(e=>e.__isSuspense)(e)?128:(e=>e.__isTeleport)(e)?64:Ae(e)?4:Se(e)?2:0,o,!0)}function Gi(e,t,n=!1){const{props:r,ref:i,patchFlag:o,children:a}=e,s=t?function(...e){const t={};for(let n=0;n<e.length;n++){const r=e[n];for(const e in r)if("class"===e)t.class!==r.class&&(t.class=le([t.class,r.class]));else if("style"===e)t.style=ie([t.style,r.style]);else if(_e(e)){const n=t[e],i=r[e];!i||n===i||we(n)&&n.includes(i)||(t[e]=n?[].concat(n,i):i)}else""!==e&&(t[e]=r[e])}return t}(r||{},t):r;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:s,key:s&&Wi(s),ref:t&&t.ref?n&&i?we(i)?i.concat(Vi(t)):[i,Vi(t)]:Vi(t):i,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:a,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Ai?-1===o?16:16|o:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Gi(e.ssContent),ssFallback:e.ssFallback&&Gi(e.ssFallback),el:e.el,anchor:e.anchor}}function Ki(e=" ",t=0){return Hi(Oi,null,e,t)}function Yi(e,t){const n=Hi(Ti,null,e);return n.staticCount=t,n}function Xi(e="",t=!1){return t?(Ri(),ji(Ii,null,e)):Hi(Ii,null,e)}function Ji(e){return null==e||"boolean"==typeof e?Hi(Ii):we(e)?Hi(Ai,null,e.slice()):"object"==typeof e?Qi(e):Hi(Oi,null,String(e))}function Qi(e){return null===e.el||e.memo?e:Gi(e)}function eo(e,t){let n=0;const{shapeFlag:r}=e;if(null==t)t=null;else if(we(t))n=16;else if("object"==typeof t){if(65&r){const n=t.default;return void(n&&(n._c&&(n._d=!1),eo(e,n()),n._c&&(n._d=!0)))}{n=32;const r=t._;r||Mi in t?3===r&&er&&(1===er.slots._?t._=1:(t._=2,e.patchFlag|=1024)):t._ctx=er}}else Se(t)?(t={default:t,_ctx:er},n=32):(t=String(t),64&r?(n=16,t=[Ki(t)]):n=8);e.children=t,e.shapeFlag|=n}function to(e,t,n,r=null){gn(e,t,7,[n,r])}function no(e,t,n,r){let i;const o=n&&n[r];if(we(e)||Ce(e)){i=new Array(e.length);for(let n=0,r=e.length;n<r;n++)i[n]=t(e[n],n,void 0,o&&o[n])}else if("number"==typeof e){0,i=new Array(e);for(let n=0;n<e;n++)i[n]=t(n+1,n,void 0,o&&o[n])}else if(Ae(e))if(e[Symbol.iterator])i=Array.from(e,((e,n)=>t(e,n,void 0,o&&o[n])));else{const n=Object.keys(e);i=new Array(n.length);for(let r=0,a=n.length;r<a;r++){const a=n[r];i[r]=t(e[a],a,r,o&&o[r])}}else i=[];return n&&(n[r]=i),i}const ro=e=>e?po(e)?ko(e)||e.proxy:ro(e.parent):null,io=ve(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>ro(e.parent),$root:e=>ro(e.root),$emit:e=>e.emit,$options:e=>__VUE_OPTIONS_API__?Xr(e):e.type,$forceUpdate:e=>()=>Pn(e.update),$nextTick:e=>Rn.bind(e.proxy),$watch:e=>__VUE_OPTIONS_API__?pr.bind(e):fe}),oo={get({_:e},t){const{ctx:n,setupState:r,data:i,props:o,accessCache:a,type:s,appContext:l}=e;let c;if("$"!==t[0]){const s=a[t];if(void 0!==s)switch(s){case 1:return r[t];case 2:return i[t];case 4:return n[t];case 3:return o[t]}else{if(r!==ue&&ye(r,t))return a[t]=1,r[t];if(i!==ue&&ye(i,t))return a[t]=2,i[t];if((c=e.propsOptions[0])&&ye(c,t))return a[t]=3,o[t];if(n!==ue&&ye(n,t))return a[t]=4,n[t];__VUE_OPTIONS_API__&&!qr||(a[t]=0)}}const u=io[t];let d,f;return u?("$attrs"===t&&dt(e,0,t),u(e)):(d=s.__cssModules)&&(d=d[t])?d:n!==ue&&ye(n,t)?(a[t]=4,n[t]):(f=l.config.globalProperties,ye(f,t)?f[t]:void 0)},set({_:e},t,n){const{data:r,setupState:i,ctx:o}=e;return i!==ue&&ye(i,t)?(i[t]=n,!0):r!==ue&&ye(r,t)?(r[t]=n,!0):!ye(e.props,t)&&(("$"!==t[0]||!(t.slice(1)in e))&&(o[t]=n,!0))},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:i,propsOptions:o}},a){let s;return!!n[a]||e!==ue&&ye(e,a)||t!==ue&&ye(t,a)||(s=o[0])&&ye(s,a)||ye(r,a)||ye(io,a)||ye(i.config.globalProperties,a)},defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:ye(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};const ao=gi();let so=0;function lo(e,t,n){const r=e.type,i=(t?t.appContext:e.appContext)||ao,o={uid:so++,vnode:e,type:r,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,scope:new Ge(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(i.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:si(r,i),emitsOptions:Jn(r,i),emit:null,emitted:null,propsDefaults:ue,inheritAttrs:r.inheritAttrs,ctx:ue,data:ue,props:ue,attrs:ue,slots:ue,refs:ue,setupState:ue,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=Xn.bind(null,o),e.ce&&e.ce(o),o}let co=null;const uo=()=>co||er,fo=e=>{co=e,e.scope.on()},ho=()=>{co&&co.scope.off(),co=null};function po(e){return 4&e.vnode.shapeFlag}let _o,mo,vo=!1;function go(e,t=!1){vo=t;const{props:n,children:r}=e.vnode,i=po(e);ii(e,n,i,t),((e,t)=>{if(32&e.vnode.shapeFlag){const n=t._;n?(e.slots=sn(t),We(t,"_",n)):_i(t,e.slots={})}else e.slots={},t&&mi(e,t);We(e.slots,Mi,1)})(e,r);const o=i?function(e,t){const n=e.type;0;e.accessCache=Object.create(null),e.proxy=ln(new Proxy(e.ctx,oo)),!1;const{setup:r}=n;if(r){const n=e.setupContext=r.length>1?wo(e):null;fo(e),ct();const i=vn(r,e,0,[e.props,n]);if(ut(),ho(),Oe(i)){if(i.then(ho,ho),t)return i.then((n=>{bo(e,n,t)})).catch((t=>{bn(t,e,0)}));e.asyncDep=i}else bo(e,i,t)}else yo(e,t)}(e,t):void 0;return vo=!1,o}function bo(e,t,n){Se(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Ae(t)&&(__VUE_PROD_DEVTOOLS__&&(e.devtoolsRawSetupState=t),e.setupState=_n(t)),yo(e,n)}function yo(e,t,n){const r=e.type;if(!e.render){if(!t&&_o&&!r.render){const t=r.template;if(t){0;const{isCustomElement:n,compilerOptions:i}=e.appContext.config,{delimiters:o,compilerOptions:a}=r,s=ve(ve({isCustomElement:n,delimiters:o},i),a);r.render=_o(t,s)}}e.render=r.render||fe,mo&&mo(e)}__VUE_OPTIONS_API__&&(fo(e),ct(),Gr(e),ut(),ho())}function wo(e){const t=t=>{e.exposed=t||{}};let n;return{get attrs(){return n||(n=function(e){return new Proxy(e.attrs,{get:(t,n)=>(dt(e,0,"$attrs"),t[n])})}(e))},slots:e.slots,emit:e.emit,expose:t}}function ko(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(_n(ln(e.exposed)),{get:(t,n)=>n in t?t[n]:n in io?io[n](e):void 0}))}function xo(e){return Se(e)&&e.displayName||e.name}function So(e){return Se(e)&&"__vccOpts"in e}const Co=(e,t)=>function(e,t,n=!1){let r,i;const o=Se(e);return o?(r=e,i=fe):(r=e.get,i=e.set),new mn(r,i,o||!i,n)}(e,0,vo);Symbol("");const Eo="3.2.33",Ao="undefined"!=typeof document?document:null,Oo=Ao&&Ao.createElement("template"),Io={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const i=t?Ao.createElementNS("http://www.w3.org/2000/svg",e):Ao.createElement(e,n?{is:n}:void 0);return"select"===e&&r&&null!=r.multiple&&i.setAttribute("multiple",r.multiple),i},createText:e=>Ao.createTextNode(e),createComment:e=>Ao.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ao.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},cloneNode(e){const t=e.cloneNode(!0);return"_value"in e&&(t._value=e._value),t},insertStaticContent(e,t,n,r,i,o){const a=n?n.previousSibling:t.lastChild;if(i&&(i===o||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),i!==o&&(i=i.nextSibling););else{Oo.innerHTML=r?`<svg>${e}</svg>`:e;const i=Oo.content;if(r){const e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[a?a.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}};const To=/\s*!important$/;function zo(e,t,n){if(we(n))n.forEach((n=>zo(e,t,n)));else if(null==n&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=function(e,t){const n=Ro[t];if(n)return n;let r=Le(t);if("filter"!==r&&r in e)return Ro[t]=r;r=je(r);for(let n=0;n<Fo.length;n++){const i=Fo[n]+r;if(i in e)return Ro[t]=i}return t}(e,t);To.test(n)?e.setProperty(Ue(r),n.replace(To,""),"important"):e[r]=n}}const Fo=["Webkit","Moz","ms"],Ro={};const Po="http://www.w3.org/1999/xlink";const[Bo,Lo]=(()=>{let e=Date.now,t=!1;if("undefined"!=typeof window){Date.now()>document.createEvent("Event").timeStamp&&(e=()=>performance.now());const n=navigator.userAgent.match(/firefox\/(\d+)/i);t=!!(n&&Number(n[1])<=53)}return[e,t]})();let Do=0;const Uo=Promise.resolve(),jo=()=>{Do=0};function $o(e,t,n,r){e.addEventListener(t,n,r)}function No(e,t,n,r,i=null){const o=e._vei||(e._vei={}),a=o[t];if(r&&a)a.value=r;else{const[n,s]=function(e){let t;if(Mo.test(e)){let n;for(t={};n=e.match(Mo);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[Ue(e.slice(2)),t]}(t);if(r){const a=o[t]=function(e,t){const n=e=>{const r=e.timeStamp||Bo();(Lo||r>=n.attached-1)&&gn(function(e,t){if(we(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map((e=>t=>!t._stopped&&e&&e(t)))}return t}(e,n.value),t,5,[e])};return n.value=e,n.attached=(()=>Do||(Uo.then(jo),Do=Bo()))(),n}(r,i);$o(e,n,a,s)}else a&&(!function(e,t,n,r){e.removeEventListener(t,n,r)}(e,n,a,s),o[t]=void 0)}}const Mo=/(?:Once|Passive|Capture)$/;const Wo=/^on[a-z]/;"undefined"!=typeof HTMLElement&&HTMLElement;const Vo="transition",Zo="animation",Ho=(e,{slots:t})=>function(e,t,n){const r=arguments.length;return 2===r?Ae(t)&&!we(t)?$i(t)?Hi(e,null,[t]):Hi(e,t):Hi(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):3===r&&$i(n)&&(n=[n]),Hi(e,t,n))}(br,Yo(e),t);Ho.displayName="Transition";const qo={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Go=(Ho.props=ve({},br.props,qo),(e,t=[])=>{we(e)?e.forEach((e=>e(...t))):e&&e(...t)}),Ko=e=>!!e&&(we(e)?e.some((e=>e.length>1)):e.length>1);function Yo(e){const t={};for(const n in e)n in qo||(t[n]=e[n]);if(!1===e.css)return t;const{name:n="v",type:r,duration:i,enterFromClass:o=`${n}-enter-from`,enterActiveClass:a=`${n}-enter-active`,enterToClass:s=`${n}-enter-to`,appearFromClass:l=o,appearActiveClass:c=a,appearToClass:u=s,leaveFromClass:d=`${n}-leave-from`,leaveActiveClass:f=`${n}-leave-active`,leaveToClass:h=`${n}-leave-to`}=e,p=function(e){if(null==e)return null;if(Ae(e))return[Xo(e.enter),Xo(e.leave)];{const t=Xo(e);return[t,t]}}(i),_=p&&p[0],m=p&&p[1],{onBeforeEnter:v,onEnter:g,onEnterCancelled:b,onLeave:y,onLeaveCancelled:w,onBeforeAppear:k=v,onAppear:x=g,onAppearCancelled:S=b}=t,C=(e,t,n)=>{Qo(e,t?u:s),Qo(e,t?c:a),n&&n()},E=(e,t)=>{Qo(e,h),Qo(e,f),t&&t()},A=e=>(t,n)=>{const i=e?x:g,a=()=>C(t,e,n);Go(i,[t,a]),ea((()=>{Qo(t,e?l:o),Jo(t,e?u:s),Ko(i)||na(t,r,_,a)}))};return ve(t,{onBeforeEnter(e){Go(v,[e]),Jo(e,o),Jo(e,a)},onBeforeAppear(e){Go(k,[e]),Jo(e,l),Jo(e,c)},onEnter:A(!1),onAppear:A(!0),onLeave(e,t){const n=()=>E(e,t);Jo(e,d),aa(),Jo(e,f),ea((()=>{Qo(e,d),Jo(e,h),Ko(y)||na(e,r,m,n)})),Go(y,[e,n])},onEnterCancelled(e){C(e,!1),Go(b,[e])},onAppearCancelled(e){C(e,!0),Go(S,[e])},onLeaveCancelled(e){E(e),Go(w,[e])}})}function Xo(e){return Ve(e)}function Jo(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.add(t))),(e._vtc||(e._vtc=new Set)).add(t)}function Qo(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.remove(t)));const{_vtc:n}=e;n&&(n.delete(t),n.size||(e._vtc=void 0))}function ea(e){requestAnimationFrame((()=>{requestAnimationFrame(e)}))}let ta=0;function na(e,t,n,r){const i=e._endId=++ta,o=()=>{i===e._endId&&r()};if(n)return setTimeout(o,n);const{type:a,timeout:s,propCount:l}=ra(e,t);if(!a)return r();const c=a+"end";let u=0;const d=()=>{e.removeEventListener(c,f),o()},f=t=>{t.target===e&&++u>=l&&d()};setTimeout((()=>{u<l&&d()}),s+1),e.addEventListener(c,f)}function ra(e,t){const n=window.getComputedStyle(e),r=e=>(n[e]||"").split(", "),i=r("transitionDelay"),o=r("transitionDuration"),a=ia(i,o),s=r("animationDelay"),l=r("animationDuration"),c=ia(s,l);let u=null,d=0,f=0;t===Vo?a>0&&(u=Vo,d=a,f=o.length):t===Zo?c>0&&(u=Zo,d=c,f=l.length):(d=Math.max(a,c),u=d>0?a>c?Vo:Zo:null,f=u?u===Vo?o.length:l.length:0);return{type:u,timeout:d,propCount:f,hasTransform:u===Vo&&/\b(transform|all)(,|$)/.test(n.transitionProperty)}}function ia(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map(((t,n)=>oa(t)+oa(e[n]))))}function oa(e){return 1e3*Number(e.slice(0,-1).replace(",","."))}function aa(){return document.body.offsetHeight}new WeakMap,new WeakMap;const sa=ve({patchProp:(e,t,n,r,i=!1,o,a,s,l)=>{"class"===t?function(e,t,n){const r=e._vtc;r&&(t=(t?[t,...r]:[...r]).join(" ")),null==t?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}(e,r,i):"style"===t?function(e,t,n){const r=e.style,i=Ce(n);if(n&&!i){for(const e in n)zo(r,e,n[e]);if(t&&!Ce(t))for(const e in t)null==n[e]&&zo(r,e,"")}else{const o=r.display;i?t!==n&&(r.cssText=n):t&&e.removeAttribute("style"),"_vod"in e&&(r.display=o)}}(e,n,r):_e(t)?me(t)||No(e,t,0,r,a):("."===t[0]?(t=t.slice(1),1):"^"===t[0]?(t=t.slice(1),0):function(e,t,n,r){if(r)return"innerHTML"===t||"textContent"===t||!!(t in e&&Wo.test(t)&&Se(n));if("spellcheck"===t||"draggable"===t||"translate"===t)return!1;if("form"===t)return!1;if("list"===t&&"INPUT"===e.tagName)return!1;if("type"===t&&"TEXTAREA"===e.tagName)return!1;if(Wo.test(t)&&Ce(n))return!1;return t in e}(e,t,r,i))?function(e,t,n,r,i,o,a){if("innerHTML"===t||"textContent"===t)return r&&a(r,i,o),void(e[t]=null==n?"":n);if("value"===t&&"PROGRESS"!==e.tagName&&!e.tagName.includes("-")){e._value=n;const r=null==n?"":n;return e.value===r&&"OPTION"!==e.tagName||(e.value=r),void(null==n&&e.removeAttribute(t))}let s=!1;if(""===n||null==n){const r=typeof e[t];"boolean"===r?n=re(n):null==n&&"string"===r?(n="",s=!0):"number"===r&&(n=0,s=!0)}try{e[t]=n}catch(e){}s&&e.removeAttribute(t)}(e,t,r,o,a,s,l):("true-value"===t?e._trueValue=r:"false-value"===t&&(e._falseValue=r),function(e,t,n,r,i){if(r&&t.startsWith("xlink:"))null==n?e.removeAttributeNS(Po,t.slice(6,t.length)):e.setAttributeNS(Po,t,n);else{const r=ne(t);null==n||r&&!re(n)?e.removeAttribute(t):e.setAttribute(t,r?"":n)}}(e,t,r,i))}},Io);let la;function ca(){return la||(la=function(e){return xi(e)}(sa))}function ua(e){if(Ce(e)){return document.querySelector(e)}return e}var da=function(e){return function(e){tr=e}("data-v-6a48ed2c"),e=e(),tr=null,e},fa={id:"bp_config"},ha={class:"bp_config_bg"},pa={style:{"font-size":"20px"}},_a=da((function(){return Zi("b",null,"bilibili视频下载 参数设置",-1)})),ma={style:{margin:"2% 0"}},va=da((function(){return Zi("label",null,"请求地址:",-1)})),ga=["value"],ba=Ki("     "),ya=da((function(){return Zi("label",null,"请求方式:",-1)})),wa=["value"],ka=[da((function(){return Zi("option",{value:"auto"},"自动判断",-1)})),da((function(){return Zi("option",{value:"local"},"本地请求",-1)})),da((function(){return Zi("option",{value:"online"},"远程请求",-1)}))],xa=da((function(){return Zi("br",null,null,-1)})),Sa=da((function(){return Zi("small",null,"注意:普通使用请勿修改;默认使用混合请求",-1)})),Ca={style:{margin:"2% 0"}},Ea=da((function(){return Zi("label",null,"视频格式:",-1)})),Aa=["value"],Oa=[da((function(){return Zi("option",{value:"flv"},"FLV",-1)})),da((function(){return Zi("option",{value:"dash"},"DASH",-1)})),da((function(){return Zi("option",{value:"mp4"},"MP4",-1)}))],Ia=Ki("     "),Ta=da((function(){return Zi("label",null,"切换CDN:",-1)})),za=["value"],Fa=["value"],Ra=da((function(){return Zi("br",null,null,-1)})),Pa=da((function(){return Zi("small",null,"注意:仅video支持MP4;建议特殊地区或网络受限时切换(自行选择合适线路)",-1)})),Ba={style:{margin:"2% 0"}},La=da((function(){return Zi("label",null,"下载方式:",-1)})),Da=["value"],Ua=[Yi('<option value="a" data-v-6a48ed2c>URL链接</option><option value="web" data-v-6a48ed2c>Web浏览器</option><option value="blob" data-v-6a48ed2c>Blob请求</option><option value="rpc" data-v-6a48ed2c>RPC接口</option><option value="aria" data-v-6a48ed2c>Aria命令</option>',5)],ja=Ki("     "),$a=da((function(){return Zi("label",null,"AriaNg地址:",-1)})),Na=["value"],Ma=da((function(){return Zi("br",null,null,-1)})),Wa=da((function(){return Zi("small",null,"提示:url和web方式不会设置文件名",-1)})),Va={style:{margin:"2% 0"}},Za=da((function(){return Zi("label",null,"RPC配置:[ 域名 : 端口 | 密钥 | 保存目录 ]",-1)})),Ha=da((function(){return Zi("br",null,null,-1)})),qa=["value"],Ga=Ki(" : "),Ka=["value"],Ya=Ki(" | "),Xa=["value"],Ja=Ki(" | "),Qa=["value"],es=da((function(){return Zi("br",null,null,-1)})),ts=da((function(){return Zi("small",null,"注意:RPC默认使用Motrix(需要安装并运行)下载,其他软件请修改参数",-1)})),ns={style:{margin:"2% 0"}},rs=da((function(){return Zi("label",null,"强制换源:",-1)})),is=["value"],os=[da((function(){return Zi("option",{value:"0"},"关闭",-1)})),da((function(){return Zi("option",{value:"1"},"开启",-1)}))],as=Ki("     "),ss=da((function(){return Zi("label",null,"弹幕速度:",-1)})),ls=["value"],cs=Ki(" s     "),us=da((function(){return Zi("label",null,"弹幕字号:",-1)})),ds=["value"],fs=Ki(" px "),hs=da((function(){return Zi("br",null,null,-1)})),ps=da((function(){return Zi("small",null,"说明:使用请求到的视频地址在DPlayer进行播放;弹幕速度为弹幕滑过DPlayer的时间",-1)})),_s={style:{margin:"2% 0"}},ms=da((function(){return Zi("label",null,"自动下载:",-1)})),vs=["value"],gs=[da((function(){return Zi("option",{value:"0"},"关闭",-1)})),da((function(){return Zi("option",{value:"1"},"开启",-1)}))],bs=da((function(){return Zi("br",null,null,-1)})),ys=da((function(){return Zi("small",null,"说明:请求地址成功后将自动点击下载视频按钮",-1)})),ws={style:{margin:"2% 0"}},ks=da((function(){return Zi("label",null,"授权状态:",-1)})),xs=da((function(){return Zi("select",{id:"auth",value:"{{config.auth}}",disabled:""},[Zi("option",{value:"0"},"未授权"),Zi("option",{value:"1"},"已授权")],-1)})),Ss={style:{"text-align":"right"}},Cs=da((function(){return Zi("br",null,null,-1)}));var Es=n(44),As=Es.config,Os=Es.hostMap,Is=Object.assign({},As),Ts={data:function(){var e=[];for(var t in Os)e.push({text:Os[t],value:t});return{config:As,host_key_options:e,help_clicked:!1}},methods:{save_config:function(){var e=JSON.parse(r.get("config_str"));r.set("config_str",JSON.stringify(As)),$("#bp_config").hide(),$("#bp_config").css("opacity",0),i.show();for(var t=0,n=["base_api","format","auth"];t<n.length;t++){var o=n[t];if(As[o]!==e[o]){$("#video_download").hide(),$("#video_download_2").hide();break}}As.host_key!==e.host_key&&(Q.refresh(),$("#video_url").attr("href","#"),$("#video_url_2").attr("href","#")),As.rpc_domain!==e.rpc_domain&&(As.rpc_domain.match("https://")||As.rpc_domain.match(/(localhost|127\.0\.0\.1)/)||h("检测到当前RPC不是localhost本地接口,即将跳转到AriaNg网页控制台页面;请查看控制台RPC接口参数是否正确,第一次加载可能较慢请耐心等待;配置好后即可使用脚本进行远程下载<br/>使用期间不用关闭控制台页面!",(function(){H.open_ariang({domain:As.rpc_domain,port:As.rpc_port,token:As.rpc_token})})));for(var a=0,s=["danmaku_speed","danmaku_fontsize"];a<s.length;a++){var l=s[a];if(As[l]!==e[l]){I.danmaku.config();break}}},reset_config:function(){for(var e in Is)"auth"!==e&&(this.config[e]=Is[e])},show_help:function(){var e=this;this.help_clicked?f():(this.help_clicked=!0,_({url:"".concat(As.base_api,"/auth/v2/?act=help"),dataType:"text"}).then((function(e){e?h(e):c("获取失败")})).finally((function(){return e.help_clicked=!1})))},show_login:function(e){X.login(e)},show_logout:function(){X.logout()},show_login_help:function(){p("进行授权之后将能在远程请求时享有用户账号原有的权益,例如能够请求用户已经付费或承包的番剧,是否需要授权?",(function(){X.login()}))}},created:function(){var e=r.get("config_str")||localStorage.getItem("my_config_str");if(e){var t=JSON.parse(e);for(var n in t)Object.hasOwnProperty.call(As,n)&&(As[n]=t[n])}else r.set("config_str",JSON.stringify(As)),localStorage.setItem("my_config_str","");window.onbeforeunload=function(){var e=window.bp_aria2_window;e&&!e.closed&&e.close()}}},zs=n(379),Fs=n.n(zs),Rs=n(795),Ps=n.n(Rs),Bs=n(569),Ls=n.n(Bs),Ds=n(565),Us=n.n(Ds),js=n(216),$s=n.n(js),Ns=n(589),Ms=n.n(Ns),Ws=n(657),Vs={};Vs.styleTagTransform=Ms(),Vs.setAttributes=Us(),Vs.insert=Ls().bind(null,"head"),Vs.domAPI=Ps(),Vs.insertStyleElement=$s();Fs()(Ws.Z,Vs),Ws.Z&&Ws.Z.locals&&Ws.Z.locals;var Zs=(0,n(744).Z)(Ts,[["render",function(e,t,n,r,i,o){return Ri(),Ui("div",fa,[Zi("div",ha,[Zi("span",pa,[_a,Zi("b",null,[Zi("a",{href:"javascript:;",onClick:t[0]||(t[0]=function(e){return o.reset_config()})}," [重置] "),Zi("a",{style:{"text-decoration":"underline"},href:"javascript:;",onClick:t[1]||(t[1]=function(e){return o.show_help()})},"<通知/帮助>")])]),Zi("div",ma,[va,Zi("input",{value:i.config.base_api,onInput:t[2]||(t[2]=function(e){return i.config.base_api=e.target.value}),style:{width:"30%"}},null,40,ga),ba,ya,Zi("select",{value:i.config.request_type,onInput:t[3]||(t[3]=function(e){return i.config.request_type=e.target.value})},ka,40,wa),xa,Sa]),Zi("div",Ca,[Ea,Zi("select",{value:i.config.format,onInput:t[4]||(t[4]=function(e){return i.config.format=e.target.value})},Oa,40,Aa),Ia,Ta,Zi("select",{value:i.config.host_key,onInput:t[5]||(t[5]=function(e){return i.config.host_key=e.target.value})},[(Ri(!0),Ui(Ai,null,no(i.host_key_options,(function(e){return Ri(),Ui("option",{value:e.value,key:e.text},(t=e.text,Ce(t)?t:null==t?"":we(t)||Ae(t)&&(t.toString===Ie||!Se(t.toString))?JSON.stringify(t,ce,2):String(t)),9,Fa);var t})),128))],40,za),Ra,Pa]),Zi("div",Ba,[La,Zi("select",{value:i.config.download_type,onInput:t[6]||(t[6]=function(e){return i.config.download_type=e.target.value})},Ua,40,Da),ja,$a,Zi("input",{value:i.config.ariang_host,onInput:t[7]||(t[7]=function(e){return i.config.ariang_host=e.target.value}),style:{width:"30%"}},null,40,Na),Ma,Wa]),Zi("div",Va,[Za,Ha,Zi("input",{value:i.config.rpc_domain,onInput:t[8]||(t[8]=function(e){return i.config.rpc_domain=e.target.value}),style:{width:"25%"}},null,40,qa),Ga,Zi("input",{value:i.config.rpc_port,onInput:t[9]||(t[9]=function(e){return i.config.rpc_port=e.target.value}),style:{width:"10%"}},null,40,Ka),Ya,Zi("input",{value:i.config.rpc_token,onInput:t[10]||(t[10]=function(e){return i.config.rpc_token=e.target.value}),placeholder:"没有密钥不用填",style:{width:"15%"}},null,40,Xa),Ja,Zi("input",{value:i.config.rpc_dir,onInput:t[11]||(t[11]=function(e){return i.config.rpc_dir=e.target.value}),placeholder:"留空使用默认目录",style:{width:"20%"}},null,40,Qa),es,ts]),Zi("div",ns,[rs,Zi("select",{value:i.config.replace_force,onInput:t[12]||(t[12]=function(e){return i.config.replace_force=e.target.value})},os,40,is),as,ss,Zi("input",{value:i.config.danmaku_speed,onInput:t[13]||(t[13]=function(e){return i.config.danmaku_speed=e.target.value}),style:{width:"5%"}},null,40,ls),cs,us,Zi("input",{value:i.config.danmaku_fontsize,onInput:t[14]||(t[14]=function(e){return i.config.danmaku_fontsize=e.target.value}),style:{width:"5%"}},null,40,ds),fs,hs,ps]),Zi("div",_s,[ms,Zi("select",{value:i.config.auto_download,onInput:t[15]||(t[15]=function(e){return i.config.auto_download=e.target.value})},gs,40,vs),bs,ys]),Zi("div",ws,[ks,Xi('-id="auth"-'),xs,Zi("a",{class:"setting-context",href:"javascript:;",onClick:t[16]||(t[16]=function(e){return o.show_login()})},"账号授权"),Zi("a",{class:"setting-context",href:"javascript:;",onClick:t[17]||(t[17]=function(e){return o.show_logout()})},"取消授权"),Zi("a",{class:"setting-context",href:"javascript:;",onClick:t[18]||(t[18]=function(e){return o.show_login("0")})},"手动授权"),Zi("a",{class:"setting-context",href:"javascript:;",onClick:t[19]||(t[19]=function(e){return o.show_login_help()})},"这是什么?")]),Zi("div",Ss,[Cs,Zi("button",{class:"setting-button",onClick:t[20]||(t[20]=function(e){return o.save_config()})},"确定")])])])}],["__scopeId","data-v-6a48ed2c"]]);function Hs(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)}}var qs=function(){function t(){var e=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),this.has_toolbar=!1,setTimeout((function(){e.run_before()}),1e3)}var n,o,a;return n=t,o=[{key:"run_before",value:function(){this.has_toolbar=this.set_toolbar(),this.has_toolbar&&this.run()}},{key:"set_toolbar",value:function(){var e;this.has_toolbar||($("#arc_toolbar_report")[0]?(e='<div id="arc_toolbar_report_2" style="margin-top:16px" class="video-toolbar report-wrap-module report-scroll-module" scrollshow="true"> <div class="ops"> <span id="setting_btn"> <i class="van-icon-general_addto_s"></i>脚本设置 </span> <span id="bilibili_parse"> <i class="van-icon-floatwindow_custome"></i>请求地址 </span> <span id="video_download" style="display:none"> <i class="van-icon-download"></i>下载视频 </span> <span id="video_download_2" style="display:none"> <i class="van-icon-download"></i>下载音频 </span> <span id="video_download_all"> <i class="van-icon-download"></i>批量下载 </span> </div> <div class="more"> <i class="van-icon-general_moreactions"></i> <div class="more-ops-list"> <ul> <li><span id="download_danmaku">下载弹幕</span></li> <li><span id="download_subtitle">下载字幕</span></li> </ul> </div> </div> </div> ',$("#arc_toolbar_report").after(e)):$("#toolbar_module")[0]?(e='<div id="toolbar_module_2" class="tool-bar clearfix report-wrap-module report-scroll-module media-info" scrollshow="true"> <div id="setting_btn" class="like-info"> <i class="iconfont icon-add"></i><span>脚本设置</span> </div> <div id="bilibili_parse" class="like-info"> <i class="iconfont icon-customer-serv"></i><span>请求地址</span> </div> <div id="video_download" class="like-info" style="display:none"> <i class="iconfont icon-download"></i><span>下载视频</span> </div> <div id="video_download_2" class="like-info" style="display:none"> <i class="iconfont icon-download"></i><span>下载音频</span> </div> <div id="video_download_all" class="like-info"> <i class="iconfont icon-download"></i><span>批量下载</span> </div> <div class="more">更多<div class="more-ops-list"> <ul> <li><span id="download_danmaku">下载弹幕</span></li> <li><span id="download_subtitle">下载字幕</span></li> </ul> </div> </div> <style>.tool-bar .more{float:right;cursor:pointer;color:#757575;font-size:16px;display:inline-block;transition:all .3s;position:relative;text-align:center}.tool-bar .more:hover .more-ops-list{display:block}.tool-bar:after{display:block;content:"";clear:both}.more-ops-list{display:none;position:absolute;width:80px;left:-65px;z-index:30;text-align:center;padding:10px 0;background:#fff;border:1px solid #e5e9ef;box-shadow:0 2px 4px 0 rgba(0,0,0,.14);border-radius:2px;font-size:14px;color:#222}.more-ops-list li{position:relative;height:34px;line-height:34px;cursor:pointer;transition:all .3s}.more-ops-list li:hover{color:#00a1d6;background:#e7e7e7}</style> </div> ',$("#toolbar_module").after(e)):$("div.video-toolbar")[0]&&(e='<div id="arc_toolbar_report_2" style="margin-top:16px" class="video-toolbar report-wrap-module report-scroll-module" scrollshow="true"> <div class="ops"> <span id="setting_btn"> <i class="van-icon-general_addto_s"></i>脚本设置 </span> <span id="bilibili_parse"> <i class="van-icon-floatwindow_custome"></i>请求地址 </span> <span id="video_download" style="display:none"> <i class="van-icon-download"></i>下载视频 </span> <span id="video_download_2" style="display:none"> <i class="van-icon-download"></i>下载音频 </span> <span id="video_download_all"> <i class="van-icon-download"></i>批量下载 </span> </div> <div class="more"> <i class="van-icon-general_moreactions"></i> <div class="more-ops-list"> <ul class="more-ops-list-box"> <li class="more-ops-list-box-li"> <span id="download_danmaku">下载弹幕</span> </li> <li class="more-ops-list-box-li"> <span id="download_subtitle">下载字幕</span> </li> </ul> </div> </div> </div> ',$("div.video-toolbar").after(e)),this.has_toolbar=!!e)}},{key:"run",value:function(){var t=document.createElement("div");t.id="bp_root",document.body.append(t);var n,o,a,s=document.getElementById(t.id);(n=document.createElement("div")).id="root_config",s.append(n),((...e)=>{const t=ca().createApp(...e),{mount:n}=t;return t.mount=e=>{const r=ua(e);if(!r)return;const i=t._component;Se(i)||i.render||i.template||(i.template=r.innerHTML),r.innerHTML="";const o=n(r,!1,r instanceof SVGElement);return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),o},t})(Zs).mount("#".concat(n.id)),$("body").append('<div class="message-bg"></div> <div id="message_box"> <div class="message_box_bg"> <span style="font-size:20px"><b>提示:</b></span> <div id="message_box_context" style="margin:2% 0">...</div><br/><br/> <div class="message_box_btn"> <button name="affirm">确定</button> <button name="cancel">取消</button> </div> </div> </div> <style>.message-bg{position:fixed;float:right;right:0;top:2%;z-index:30000}.message{margin-bottom:15px;padding:2% 2%;width:300px;display:flex;margin-top:-70px;opacity:0}.message-success{background-color:#dfd;border-left:6px solid #4caf50}.message-danger{background-color:#fdd;border-left:6px solid #f44336}.message-info{background-color:#e7f3fe;border-left:6px solid #0c86de}.message-warning{background-color:#ffc;border-left:6px solid #ffeb3b}.message-context{font-size:21px;word-wrap:break-word;word-break:break-all}.message-context p{margin:0}#message_box{opacity:0;display:none;position:fixed;inset:0px;top:0;left:0;width:100%;height:100%;z-index:20000}.message_box_bg{position:absolute;background:#fff;border-radius:10px;padding:20px;top:50%;left:50%;transform:translate(-50%,-50%);width:400px;box-shadow:rgb(0 0 0 / 70%) 0 0 0 1000px}.message_box_btn{text-align:right}.message_box_btn button{margin:0 5px;width:120px;height:40px;border-width:0;border-radius:3px;background:#1e90ff;cursor:pointer;outline:0;color:#fff;font-size:17px}.message_box_btn button:hover{background:#59f}</style> '),G.lazyInit(),X.initAuth(),X.checkLoginStatus(),Q.refresh(),$("#".concat(t.id)).append('<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/[email protected]/dist/DPlayer.min.js" crossorigin="true"><\/script>'),$("#".concat(t.id)).append('<a id="video_url" style="display:none;" target="_blank" referrerpolicy="origin" href="#"></a>'),$("#".concat(t.id)).append('<a id="video_url_2" style="display:none;" target="_blank" referrerpolicy="origin" href="#"></a>'),$("body").on("click","#setting_btn",(function(){for(var t in G.lazyInit(!0),e.config)$("#".concat(t)).val(e.config[t]);$("#bp_config").show(),$("#bp_config").animate({opacity:"1"},300),i.hide()})),$("body").on("click","#download_danmaku",(function(){var e=g.base();H.download_danmaku_ass(e.cid(),e.filename())})),$("body").on("click","#download_subtitle",(function(){H.download_subtitle_vtt(0,g.base().filename())})),$("body").on("click","#video_download_all",(function(){G.lazyInit(!0),r.get("auth_id")&&r.get("auth_sec")?"rpc"===e.config.download_type?H.download_all():p("仅支持使用RPC接口批量下载,请确保RPC环境正常,是否继续?",(function(){H.download_all()})):p("批量下载仅支持授权用户使用RPC接口下载,是否进行授权?",(function(){X.login()}))})),$("body").on("click","#video_download",(function(){var t=e.config.download_type;if("web"===t)$("#video_url")[0].click();else if("a"===t){var n=[$("#video_url").attr("href"),$("#video_url_2").attr("href")],r=n[1],i="建议使用IDM、FDM等软件安装其浏览器插件后,鼠标右键点击链接下载~<br/><br/>"+'<a href="'.concat(n[0],'" target="_blank" style="text-decoration:underline;">&gt视频地址&lt</a><br/><br/>')+("dash"===e.config.format?'<a href="'.concat(r,'" target="_blank" style="text-decoration:underline;">&gt音频地址&lt</a>'):"");h(i)}else if("aria"===t){var o,a,s=[$("#video_url").attr("href"),$("#video_url_2").attr("href")],u=s[0],d=s[1],f=g.base().filename();o=f+H.url_format(u),a=f+"_audio.mp4";var p='--header "User-Agent: '.concat(window.navigator.userAgent,'" --header "Referer: ').concat(window.location.href,'"'),_='aria2c "'.concat(u,'" --out "').concat(o,'" ').concat(p),m='aria2c "'.concat(d,'" --out "').concat(a,'" ').concat(p),v="点击文本框即可复制下载命令!<br/><br/>"+'视频:<br/><input id="aria2_code" value=\''.concat(_,'\' onclick="bp_clip_btn(\'aria2_code\')" style="width:100%;"></br></br>')+("dash"===e.config.format?'音频:<br/><input id="aria2_code_2" value=\''.concat(m,'\' onclick="bp_clip_btn(\'aria2_code_2\')" style="width:100%;"><br/><br/>')+'全部:<br/><textarea id="aria2_code_all" onclick="bp_clip_btn(\'aria2_code_all\')" style="min-width:100%;max-width:100%;min-height:100px;max-height:100px;">'.concat(_,"\n").concat(m,"</textarea>"):"");!window.bp_clip_btn&&(window.bp_clip_btn=function(e){$("#".concat(e)).select(),document.execCommand("copy")?l("复制成功"):c("复制失败")}),h(v)}else{var b=$("#video_url").attr("href"),y=g.base().filename();H.download(b,y,t)}})),$("body").on("click","#video_download_2",(function(){var t=e.config.download_type;if("web"===t)$("#video_url_2")[0].click();else if("a"===t)$("#video_download").click();else if("aria"===t)$("#video_download").click();else{var n=$("#video_url_2").attr("href"),r=g.base().filename();H.download(n,r,t)}})),$("body").on("click","#bilibili_parse",(function(){G.lazyInit(!0);var t=g.base(),n=[t.type,t.aid(),t.p(),t.cid(),t.epid()],i=n[0],s=n[1],c=n[2],u=n[3],h=n[4],p=g.get_quality().q;o="".concat(e.config.base_api,"?av=").concat(s,"&p=").concat(c,"&cid=").concat(u,"&ep=").concat(h,"&q=").concat(p,"&type=").concat(i,"&format=").concat(e.config.format,"&otype=json&_host=").concat(e.config.host_key,"&_req=").concat(e.config.request_type);var _=[r.get("auth_id"),r.get("auth_sec")],m=_[0],v=_[1];if("1"===e.config.auth&&m&&v&&(o+="&auth_id=".concat(m,"&auth_sec=").concat(v)),o!==a||"local"===e.config.request_type)$("#video_url").attr("href","#"),$("#video_url_2").attr("href","#"),a=o,d("开始请求"),x.get_url((function(n){if(n&&!n.code){l("请求成功"),n.times&&d("剩余请求次数:".concat(n.times));var r="dash"===e.config.format?n.video.replace("http://","https://"):n.url.replace("http://","https://"),i="dash"===e.config.format?n.audio.replace("http://","https://"):"#";$("#video_url").attr("href",r),$("#video_download").show(),"dash"===e.config.format&&($("#video_url_2").attr("href",i),$("#video_download_2").show()),(G.needReplace()||t.is_limited()||"1"===e.config.replace_force)&&I.replace_player(r,i),"1"===e.config.auto_download&&$("#video_download").click()}}));else{f();var b=$("#video_url").attr("href"),y=$("#video_url_2").attr("href");b&&"#"!==b&&($("#video_download").show(),"dash"===e.config.format&&$("#video_download_2").show(),(G.needReplace()||t.is_limited()||"1"===e.config.replace_force)&&!$("#bp_dplayer")[0]&&I.replace_player(b,y),"1"===e.config.auto_download&&$("#video_download").click())}})),$("body").on("click","a.router-link-active",(function(){this!==$('li[class="on"]').find("a")[0]&&Q.refresh()})),$("body").on("click","li.ep-item",(function(){Q.refresh()})),$("body").on("click","button.bilibili-player-iconfont-next",(function(){Q.refresh()}));var u=I.bili_video_tag();$(u)[0]&&($(u)[0].onended=function(){Q.refresh()}),$("body").on("click","li.bui-select-item",(function(){Q.refresh()})),setInterval((function(){(Q.q!==g.get_quality().q||"cheese"===g.type()&&Q.epid!==g.base().epid())&&Q.refresh()}),1e3),$("body").on("click",".rec-list",(function(){Q.refresh()})),$("body").on("click",".bilibili-player-ending-panel-box-videos",(function(){Q.refresh()})),setInterval((function(){var e=g.base();Q.aid===e.aid()&&Q.cid===e.cid()||Q.refresh()}),3e3)}}],o&&Hs(n.prototype,o),a&&Hs(n,a),Object.defineProperty(n,"prototype",{writable:!1}),t}(),Gs=qs;window.bp_fun_locked||(window.bp_fun_locked=!0,null==location.href.match(/^https:\/\/www\.mcbbs\.net\/template\/mcbbs\/image\/special_photo_bg\.png/)?$(".error-text")[0]||setTimeout((function(){console.log("\n".concat(" %c bilibili-parse-download.user.js v","2.1.0"," ").concat("49c8ed7"," %c https://github.com/injahow/user.js ","\n","\n"),"color: #fadfa3; background: #030307; padding:5px 0;","background: #fadfa3; padding:5px 0;"),(new Gs).run()}),2e3):location.href.match("access_key")&&window!==window.parent&&(window.stop(),window.parent.postMessage("bilibili-parse-login-credentials: "+location.href,"*")))}()}();