// ==UserScript==
// @name bilibili视频下载
// @namespace https://github.com/injahow
// @version 2.1.2
// @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(){"use strict";var __webpack_modules__={44:function(e,t,n){n.r(t),n.d(t,{config:function(){return o},hostMap:function(){return i}});var o={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"}},447:function(e,t,n){n.d(t,{v0:function(){return c},_p:function(){return s},N5:function(){return i}});var o=n(378);function i(){$("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-error{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> ')}function r(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>'),o.A.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),o.A.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),o.A.show(),e.callback&&e.callback.cancel&&e.callback.cancel()}}var a=0;function l(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 c={success:function(e){return l(e,"success")},warning:function(e){return l(e,"warning")},error:function(e){return l(e,"error")},info:function(e){return l(e,"info")},miaow:function(e){return l("(^・ω・^)~喵喵喵~","info")}},s={alert:function(e,t){return r({html:e,callback:{affirm:t}},"alert")},confirm:function(e,t,n){return r({html:e,callback:{affirm:t,cancel:n}},"confirm")}}},378:function(e,t,n){n.d(t,{A:function(){return o}});var o={show:function(){$("div#bp_config").is(":hidden")&&$("div#message_box").is(":hidden")&&$("body").css("overflow","auto")},hide:function(){$("body").css("overflow","hidden")}}},874:function(e,t,n){n.d(t,{h:function(){return i}});var o=n(447);function i(e){return new Promise((function(t,n){e.success=function(e){e.code&&o.v0.warning("".concat(e.message||"CODE:".concat(e.code))),t(e)},e.error=function(e){o.v0.error("网络异常"),n(e)},$.ajax(e)}))}},602:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){__webpack_require__.d(__webpack_exports__,{$:function(){return JSZip}});var _ajax__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(874);function asyncGeneratorStep(e,t,n,o,i,r,a){try{var l=e[r](a),c=l.value}catch(e){return void n(e)}l.done?t(c):Promise.resolve(c).then(o,i)}function _asyncToGenerator(e){return function(){var t=this,n=arguments;return new Promise((function(o,i){var r=e.apply(t,n);function a(e){asyncGeneratorStep(r,o,i,a,l,"next",e)}function l(e){asyncGeneratorStep(r,o,i,a,l,"throw",e)}a(void 0)}))}}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _defineProperties(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}function _createClass(e,t,n){return t&&_defineProperties(e.prototype,t),n&&_defineProperties(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var RuntimeLib=function(){function RuntimeLib(e){_classCallCheck(this,RuntimeLib),this.config=e,this.modulePromise}return _createClass(RuntimeLib,[{key:"getModuleAsync",value:function getModuleAsync(){var _this=this;return new Promise((function(resolve,reject){try{var _this$config=_this.config,url=_this$config.url,getModule=_this$config.getModule;_this.modulePromise||(_this.modulePromise=_asyncToGenerator(regeneratorRuntime.mark((function _callee(){var code;return regeneratorRuntime.wrap((function _callee$(_context){for(;;)switch(_context.prev=_context.next){case 0:return console.log("[Runtime Library] Start download from ".concat(url)),_context.next=3,(0,_ajax__WEBPACK_IMPORTED_MODULE_0__.h)({url:url,dataType:"text"});case 3:return code=_context.sent,console.log("[Runtime Library] Downloaded from ".concat(url," , length = ").concat(code.length)),function runEval(){return eval(code)}.bind(window)(),_context.abrupt("return",getModule(window));case 7:case"end":return _context.stop()}}),_callee)})))());var library=_this.modulePromise;return resolve(library)}catch(e){throw reject(e),e}}))}}]),RuntimeLib}(),JSZipAsync=new RuntimeLib({url:"https://cdn.jsdelivr.net/npm/[email protected]/dist/jszip.min.js",getModule:function(e){return e.JSZip}}).getModuleAsync(),JSZip;JSZipAsync.then((function(e){return JSZip=e}))},271:function(e,t,n){var o=n(81),i=n.n(o),r=n(645),a=n.n(r)()(i());a.push([e.id,"\n#bp_config[data-v-6a48ed2c] {\r\n opacity: 0;\r\n display: none;\r\n position: fixed;\r\n inset: 0px;\r\n top: 0px;\r\n left: 0px;\r\n width: 100%;\r\n height: 100%;\r\n z-index: 10000;\n}\n.bp_config_bg[data-v-6a48ed2c] {\r\n position: absolute;\r\n background: rgb(255, 255, 255);\r\n border-radius: 10px;\r\n padding: 20px;\r\n top: 50%;\r\n left: 50%;\r\n transform: translate(-50%, -50%);\r\n width: 600px;\r\n box-shadow: rgb(0 0 0 / 70%) 0px 0px 0px 1000px;\n}\n.setting-button[data-v-6a48ed2c] {\r\n width: 120px;\r\n height: 40px;\r\n border-width: 0px;\r\n border-radius: 3px;\r\n background: #1e90ff;\r\n cursor: pointer;\r\n outline: none;\r\n color: white;\r\n font-size: 17px;\n}\n.setting-button[data-v-6a48ed2c]:hover {\r\n background: #5599ff;\n}\n.setting-context[data-v-6a48ed2c] {\r\n margin: 0 1%;\r\n color: blue;\n}\n.setting-context[data-v-6a48ed2c]:hover {\r\n color: red;\n}\r\n",""]),t.Z=a},645:function(e){e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",o=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),o&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),o&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,o,i,r){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(o)for(var l=0;l<this.length;l++){var c=this[l][0];null!=c&&(a[c]=!0)}for(var s=0;s<e.length;s++){var u=[].concat(e[s]);o&&a[u[0]]||(void 0!==r&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=r),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){e.exports=function(e){return e[1]}},379:function(e){var t=[];function n(e){for(var n=-1,o=0;o<t.length;o++)if(t[o].identifier===e){n=o;break}return n}function o(e,o){for(var r={},a=[],l=0;l<e.length;l++){var c=e[l],s=o.base?c[0]+o.base:c[0],u=r[s]||0,d="".concat(s," ").concat(u);r[s]=u+1;var p=n(d),f={css:c[1],media:c[2],sourceMap:c[3],supports:c[4],layer:c[5]};if(-1!==p)t[p].references++,t[p].updater(f);else{var _=i(f,o);o.byIndex=l,t.splice(l,0,{identifier:d,updater:_,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 r=o(e=e||[],i=i||{});return function(e){e=e||[];for(var a=0;a<r.length;a++){var l=n(r[a]);t[l].references--}for(var c=o(e,i),s=0;s<r.length;s++){var u=n(r[s]);0===t[u].references&&(t[u].updater(),t.splice(u,1))}r=c}}},569:function(e){var t={};e.exports=function(e,n){var o=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(!o)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");o.appendChild(n)}},216:function(e){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){e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},795:function(e){e.exports=function(e){var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var o="";n.supports&&(o+="@supports (".concat(n.supports,") {")),n.media&&(o+="@media ".concat(n.media," {"));var i=void 0!==n.layer;i&&(o+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),o+=n.css,i&&(o+="}"),n.media&&(o+="}"),n.supports&&(o+="}");var r=n.sourceMap;r&&"undefined"!=typeof btoa&&(o+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(r))))," */")),t.styleTagTransform(o,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},589:function(e){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){t.Z=(e,t)=>{const n=e.__vccOpts||e;for(const[e,o]of t)n[e]=o;return n}}},__webpack_module_cache__={};function __webpack_require__(e){var t=__webpack_module_cache__[e];if(void 0!==t)return t.exports;var n=__webpack_module_cache__[e]={id:e,exports:{}};return __webpack_modules__[e](n,n.exports,__webpack_require__),n.exports}__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,{a:t}),t},__webpack_require__.d=function(e,t){for(var n in t)__webpack_require__.o(t,n)&&!__webpack_require__.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},__webpack_require__.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var __webpack_exports__={};!function(){var e=__webpack_require__(44);function t(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}var n=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,o,i;return n=e,(o=[{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,o),i&&t(n,i),Object.defineProperty(n,"prototype",{writable:!1}),e}()),o=__webpack_require__(447),i=__webpack_require__(874);function r(){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 a={"1080P 高码率":112,"1080P 高清":80,"720P 高清":64,"480P 清晰":32,"360P 流畅":16,"自动":64};var l={type:r,base:function(){var e=r();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 o=e||t.p||1;return(n+" P".concat(o," (").concat(t.videoData.pages[o-1].part||o,")")).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 o=$("div.player-auxiliary-playlist-item"),i=$("div.player-auxiliary-playlist-item.player-auxiliary-playlist-item-active").index(),a=($(".player-auxiliary-playlist-top .player-auxiliary-filter-title").html()||"unknown").replace(/[\/\\:*?"<>|]+/g,"");return{type:"video",name:a,total:function(){return o.length},title:function(e){var t=e?e-1:i,n=o.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=o.eq(t).find(".player-auxiliary-playlist-item-title").attr("title")||"unknown";return"".concat(a," P").concat(t+1," (").concat(n,")").replace(/[\/\\:*?"<>|]+/g,"")},aid:function(e){var t=e?e-1:i;return o.eq(t).attr("data-aid")},p:function(){return i+1},cid:function(e){var t=e?e-1:i;return o.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 l=window.__INITIAL_STATE__,c=(l.mediaInfo.season_title||"unknown").replace(/[\/\\:*?"<>|]+/g,"");return{type:"bangumi",name:c,total:function(){return l.epList.length},title:function(e){var t=e?l.epList[e-1]:l.epInfo;return"".concat(t.titleFormat," ").concat(t.longTitle).replace(/[\/\\:*?"<>|]+/g,"")},filename:function(e){if(e){var t=l.epList[e-1];return"".concat(c,":").concat(t.titleFormat," ").concat(t.longTitle).replace(/[\/\\:*?"<>|]+/g,"")}return(l.h1Title||"unknown").replace(/[\/\\:*?"<>|]+/g,"")},aid:function(e){return e?l.epList[e-1].aid:l.epInfo.aid},p:function(){return l.epInfo.i||1},cid:function(e){return e?l.epList[e-1].cid:l.epInfo.cid},epid:function(e){return e?l.epList[e-1].id:l.epInfo.id},need_vip:function(){return"会员"===l.epInfo.badge},vip_need_pay:function(){return l.epPayMent.vipNeedPay},is_limited:function(){return l.userState.areaLimit}}}if("cheese"===e){var s=(location.href.match(/\/cheese\/play\/ep(\d+)/i)||["",""])[1];window.bp_episodes||(window.bp_episodes=[],p.get_season(s));var u=window.bp_episodes,d=$("li.on.list-box-li").index(),f=($("div.season-info h1").html()||"unknown").replace(/[\/\\:*?"<>|]+/g,"");return{type:"cheese",name:f,total:function(){return u.length},title:function(e){return(u[e?e-1:d].title||"unknown").replace(/[\/\\:*?"<>|]+/g,"")},filename:function(e){var t=e?e-1:d;return"".concat(f," P").concat(t+1," (").concat(u[t].title||"unknown",")").replace(/[\/\\:*?"<>|]+/g,"")},aid:function(e){return u[e?e-1:d].aid},p:function(){return d+1},cid:function(e){return u[e?e-1:d].cid},epid:function(e){return u[e?e-1:d].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=a[$("div.edu-player-quality-item.active span").text()||"自动"]||80,t=a[$("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"===r()?((e=$("div.edu-player-quality-item span")).each((function(){if("自动"===$(this).text())return!1;t.push(a[$(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 c(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 s(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 s(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,r=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw r}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o}function u(t,r,a,c,s,d){var p,f;p="function"==typeof c?function(e){c(e)}:function(e){return console.log(e)},f="function"==typeof s?function(e){o.v0.error("请求失败"),s(e)}:function(e){return console.error(e)};var _=l.base(),h=[_.aid(t),_.cid(t),_.epid(t),r||l.get_quality().q,_.type],v=h[0],m=h[1],g=h[2],b=h[3],y=h[4],w=a||e.config.format;"mp4"===w&&"video"!==y&&(w="flv");var x,k=function(t){if("0"!==e.config.host_key&&"online"===d&&"mp4"!==w){var n=t.split("/");n[2]=e.hostMap[e.config.host_key],t=n.join("/")}return t},S={type:"GET",dataType:"json"};if("auto"===d||"local"===d){var $,C;"cheese"===y?(x="https://api.bilibili.com/pugv/player/web/playurl","dash"===w?($=0,C=80):($=1,C=80)):(x="video"===y?"https://api.bilibili.com/x/player/playurl":"https://api.bilibili.com/pgc/player/web/playurl","dash"===w?($=0,C=4048):($=0,C=0)),x+="?avid=".concat(v,"&cid=").concat(m,"&qn=").concat(b,"&fnver=").concat($,"&fnval=").concat(C,"&fourk=1&ep_id=").concat(g,"&type=").concat(w,"&otype=json"),x+="mp4"===w?"&platform=html5&high_quality=1":"",S.xhrFields={withCredentials:!0}}else{x=e.config.base_api,x+="?av=".concat(v,"&cid=").concat(m,"&q=").concat(b,"&ep=").concat(g,"&type=").concat(y,"&format=").concat(w,"&otype=json");var O=[n.get("auth_id"),n.get("auth_sec")],T=O[0],P=O[1];"1"===e.config.auth&&T&&P&&(x+="&auth_id=".concat(T,"&auth_sec=").concat(P),t&&(x+="&s"))}S.url=x,(0,i.h)(S).then((function(e){var n;if(e.code||(n=e.result||e.data),!n)return"auto"===d?void u(t,r,a,c,s,"online"):(e.url&&(e.url=k(e.url)),e.video&&(e.video=k(e.video)),e.audio&&(e.audio=k(e.audio)),void p(e));if(n.dash){for(var o={code:0,quality:n.quality,accept_quality:n.accept_quality,video:"",audio:""},i=n.dash.video,l=0;l<i.length;l++){var f=i[l];if(f.id<=b){o.video=k(f.base_url),o.audio=k(n.dash.audio[0].base_url);break}}p(o)}else p({code:0,quality:n.quality,accept_quality:n.accept_quality,url:k(n.durl[0].url)})})).catch((function(e){return f(e)}))}function d(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],o=l.base(),r=[o.aid(e),o.cid(e),o.epid(e)],a=r[0],s=r[1],u=r[2];(0,i.h)({url:"https://api.bilibili.com/x/player/v2?aid=".concat(a,"&cid=").concat(s,"&ep_id=").concat(u),dataType:"json"}).then((function(e){!e.code&&e.data.subtitle.subtitles[0]?(0,i.h)({url:"".concat(e.data.subtitle.subtitles[0].subtitle_url),dataType:"json"}).then((function(e){var o,i="WEBVTT\n\n",r=c(e.body||[{from:0,to:0,content:""}]);try{for(r.s();!(o=r.n()).done;){var a=o.value,l=new Date(1e3*(parseInt(a.from)-28800)).toTimeString().split(" ")[0]+"."+(a.from.toString().split(".")[1]||"000").padEnd(3,"0"),s=new Date(1e3*(parseInt(a.to)-28800)).toTimeString().split(" ")[0]+"."+(a.to.toString().split(".")[1]||"000").padEnd(3,"0");i+="".concat(l," --\x3e ").concat(s,"\n").concat(a.content.trim(),"\n\n")}}catch(e){r.e(e)}finally{r.f()}t(n?URL.createObjectURL(new Blob([i],{type:"text/vtt"})):i)})).catch(t):t()})).catch(t)}var p={get_url:function(t,n){var o=e.config.request_type;u(0,0,e.config.format,t,n,o)},get_urls:function(t,n,o,i,r){u(t,n,o,i,r,e.config.request_type)},get_subtitle_url:function(e,t){d(e,t,!0)},get_subtitle_data:function(e,t){d(e,t,!1)},get_season:function(e){(0,i.h)({url:"https://api.bilibili.com/pugv/view/web/season?ep_id=".concat(e),xhrFields:{withCredentials:!0},dataType:"json"}).then((function(e){e.code?o.v0.warning("获取剧集信息失败"):window.bp_episodes=e.data.episodes||null}))}};function f(e,t){t?(0,i.h)({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 o=n.find("d").map((function(e,t){var n=$(t),o=n.attr("p").split(","),i=0;return"4"===o[1]?i=2:"5"===o[1]&&(i=1),[{author:"",time:parseFloat(o[0]),type:i,color:parseInt(o[3]),id:"",text:n.text()}]})).get();e.success(o),setTimeout((function(){m()}),100)}else e.error("未发现弹幕");else e.error("弹幕获取失败")})).catch((function(t){e.error("弹幕请求异常")})):e.error("cid未知,无法获取弹幕")}function _(){return $("bwp-video")[0]?"bwp-video":$('video[class!="dplayer-video dplayer-video-current"]')[0]?'video[class!="dplayer-video dplayer-video-current"]':void 0}function h(){var e=$(_())[0];e&&(e.pause(),e.currentTime=0)}function v(){if(window.bp_dplayer){var e=$(_())[0];e&&e.removeEventListener("play",h,!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"===l.type()?$('div.bpx-player[data-injector="nano"]')[0]?'div.bpx-player[data-injector="nano"]':"#pay-mask":void 0).show()}}function m(){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 g={bili_video_tag:_,recover_player:v,replace_player:function(t,n){v();var o,i=$(_())[0];h(),i&&i.addEventListener("play",h,!1),$("#bilibiliPlayer")[0]?(o="#bilibiliPlayer",$(o).before('<div id="bp_dplayer" class="bilibili-player relative bilibili-player-no-cursor">'),$(o).hide()):$("#bilibili-player")[0]?(o="#bilibili-player",$(o).before('<div id="bp_dplayer" class="bilibili-player relative bilibili-player-no-cursor" style="width:100%;height:100%;"></div>'),$(o).hide()):"cheese"===l.type()&&($('div.bpx-player[data-injector="nano"]')[0]?($("#pay-mask").hide(),$("#bofqi").show(),o='div.bpx-player[data-injector="nano"]',$(o).before('<div id="bp_dplayer" style="width:100%;height:100%;"></div>'),$(o).hide()):(o="#pay-mask",$(o).html('<div id="bp_dplayer" style="width:100%;height:100%;"></div>'))),$("#player_mask_module").hide(),p.get_subtitle_url(0,(function(){var o=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:o,type:"webvtt",fontSize:"35px",bottom:"5%",color:"#fff"},danmaku:!0,apiBackend:{read:function(e){f(e,l.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],r=i[0],a=i[1];r.on("play",(function(){!r.paused&&a.play()})),r.on("playing",(function(){!r.paused&&a.play()})),r.on("timeupdate",(function(){Math.abs(r.video.currentTime-a.video.currentTime)>1&&(a.pause(),a.seek(r.video.currentTime)),!r.paused&&a.play()})),r.on("seeking",(function(){a.pause(),a.seek(r.video.currentTime)})),r.on("waiting",(function(){a.pause(),a.seek(r.video.currentTime)})),r.on("pause",(function(){a.pause(),a.seek(r.video.currentTime)})),r.on("suspend",(function(){a.speed(r.video.playbackRate)})),r.on("volumechange",(function(){a.volume(r.video.volume),a.video.muted=r.video.muted}))}}))},danmaku:{config:m}},b=__webpack_require__(602);function y(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 w(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 w(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,r=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw r}}}}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o}function x(){return e.config.rpc_domain.match("https://")||e.config.rpc_domain.match(/localhost|127\.0\.0\.1/)?"post":"ariang"}var k=!1;function S(t){var n=t?"#!/settings/rpc/set/".concat(t.domain.replace("://","/"),"/").concat(t.port,"/jsonrpc/").concat(window.btoa(t.token)):"",o=e.config.ariang_host+n,i=document.createElement("a");i.setAttribute("target","_blank"),i.setAttribute("onclick","window.bp_aria2_window=window.open('".concat(o,"');")),document.body.appendChild(i),i.click(),i.remove()}var C=!1,O=!0;function T(e,t){if(C)return o.v0.miaow(),void(O=!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)}},O=!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,i=e.percent;O&&o._p.alert("文件大小:".concat(Math.floor(t/1048576),"MB(").concat(t,"Byte)<br/>")+"已经下载:".concat(Math.floor(n/1048576),"MB(").concat(n,"Byte)<br/>")+"当前进度:".concat(i,"%<br/>下载中请勿操作浏览器!"),(function(){O=!1,o._p.alert("注意:刷新或离开页面会导致下载取消!<br/>再次点击下载按钮可查看下载进度。")})),t===n&&(o._p.alert("下载完成,请等待浏览器保存!"),C=!1)}({total:n,loaded:t,percent:Math.floor(100*t/n)})}},n.send(),C=!0,o.v0.info("准备开始下载")}function P(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;(0,i.h)({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 a=i.find("d").map((function(e,t){var n=$(t),o=n.attr("p").split(","),i=0;return"4"===o[1]?i=2:"5"===o[1]&&(i=1),[{time:parseFloat(o[0]),type:i,color:parseInt(o[3]),text:n.text()}]})).get();a.sort((function(e,t){return e.time-t.time}));var l,c=function(e,t,n){var o,i,r,a,l=e.text,c=e.time,s=[0===e.type?(i=50*(1+Math.floor(15*Math.random())),r=1920+50*e.text.length/2,a=0-50*e.text.length/2,"\\move(".concat(r,",").concat(i,",").concat(a,",").concat(i,")")):function(e,t){return"\\pos(".concat(t,",").concat(e,")")}(50*(1+n%15),960),(o=e.color,16777215===o?"":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},o=Math.floor(e),i=t(o,3600),r=t(o,60)%60,a=o%60,l=Math.floor(100*(e-o));return"".concat(i,":").concat(n(r),":").concat(n(a),".").concat(l)},d=[0,u(c),u(c+(0===e.type?8:4)),"Medium","","0","0","0","","{"+s.join("")+"}"+function(e){return e.replace(/\{/g,"{").replace(/\}/g,"}").replace(/\r|\n/g,"")}(l)];return"Dialogue: "+d.join(",")},s=["[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=y(a);try{for(d.s();!(l=d.n()).done;){var p=l.value;0===p.type?0:u++,s.push(c(p,0,u))}}catch(e){d.e(e)}finally{d.f()}var f=s.join("\n");if(null===n||"file"===n){var _=URL.createObjectURL(new Blob([f],{type:"text/ass"})),h=document.createElement("a");h.style.display="none",h.href=_,h.download=t+".ass",document.body.appendChild(h),h.click(),h.remove(),URL.revokeObjectURL(_)}else"callback"===n&&r&&r(f)}else o.v0.warning("未发现弹幕")})).catch((function(e){o.v0.warning("未发现字幕")}))}function E(e,t){if(e){var n=URL.createObjectURL(e),o=document.createElement("a");o.setAttribute("target","_blank"),o.setAttribute("href",n),o.setAttribute("download",t+".zip"),document.body.appendChild(o),o.click(),o.remove(),URL.revokeObjectURL(n)}}function F(e,t){if(e)if(0!==e.length){var n=e.pop();P(n.cid,n.filename,"callback",(function(o){o&&t.file(n.filename+".ass",o),F(e,t)}))}else t.generateAsync({type:"blob"}).then((function(e){return E(e,l.base().name+"_ass")}))}function A(e,t){if(e)if(0!==e.length){var n=e.pop();p.get_subtitle_data(n.p,(function(o){o&&t.file(n.filename+".vtt",o),A(e,t)}))}else t.generateAsync({type:"blob"}).then((function(e){return E(e,l.base().name+"_vtt")}))}function I(e){return e.match(".flv")?".flv":e.match(".m4s")?"_video.mp4":(e.match(".mp4"),".mp4")}var L={url_format:I,download:function(t,n,r){var a=n.replace(/[\/\\:*?"<>|]+/g,"")+I(t);"blob"===r?T(t,a):"rpc"===r&&function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"post";if(k)o.v0.miaow();else{k=!0;var a={domain:e.config.rpc_domain,port:e.config.rpc_port,token:e.config.rpc_token,dir:e.config.rpc_dir},l={id:window.btoa("BParse_".concat(Date.now(),"_").concat(Math.random())),jsonrpc:"2.0",method:"aria2.addUri",params:["token:".concat(a.token),[t],{dir:a.dir,out:n,header:["User-Agent: ".concat(window.navigator.userAgent),"Referer: ".concat(window.location.href)]}]};if(o.v0.info("发送RPC下载请求"),"post"===r)(0,i.h)({url:"".concat(a.domain,":").concat(a.port,"/jsonrpc"),type:"POST",dataType:"json",data:JSON.stringify(l)}).then((function(e){e.result?o.v0.success("RPC请求成功"):o.v0.warning("请检查RPC参数")})).catch((function(e){o.v0.error("请检查RPC服务配置")})).finally((function(e){return k=!1}));else if("ariang"===r){var c=window.bp_aria2_window,s=100;c&&!c.closed||(S(),s=3e3),setTimeout((function(){var i=window.bp_aria2_window,r="header=User-Agent:".concat(window.navigator.userAgent,"&header=Referer:").concat(window.location.href),a="#!/new/task?url=".concat(window.btoa(t),"&out=").concat(encodeURIComponent(n),"&").concat(r);i&&!i.closed?(i.location.href=e.config.ariang_host+a,o.v0.success("RPC请求发送成功")):o.v0.warning("AriaNG页面未打开"),k=!1}),s)}}}(t,a,x())},download_all:function(){var t=l.base(),n=[l.get_quality().q,t.total()],r=n[0],a=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 c="",s=0;s<a;s++)c+=""+'<label for="option_'.concat(s,'"><div style="color:rgba(0,0,0,0.5);">\n <input type="checkbox" id="option_').concat(s,'" name="dl_video" value="').concat(s,'">\n P').concat(s+1," ").concat(t.title(s+1),"\n </div></label>");var u=!1;$("body").on("click","button#checkbox_btn",(function(){u?(u=!1,$('input[name="dl_video"]').prop("checked",u),$('input[name="dl_video"]').parent().css("color","rgba(0,0,0,0.5)")):(u=!0,$('input[name="dl_video"]').prop("checked",u),$('input[name="dl_video"]').parent().css("color","rgb(0,0,0)"))}));var d,f={120:"4K 超清",116:"1080P 60帧",112:"1080P 高码率",80:"1080P 高清",74:"720P 60帧",64:"720P 高清",48:"720P 高清(MP4)",32:"480P 清晰",16:"360P 流畅"},_="",h=y(l.get_quality_support());try{for(h.s();!(d=h.n()).done;){var v=d.value;_+='<option value="'.concat(v,'">').concat(f[v],"</option>")}}catch(e){h.e(e)}finally{h.f()}var m=""+'<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 仅video类型支持mp4\n </div>\n <div style="margin:2% 0;">\n <label>视频质量:</label>\n <select id="dl_quality">\n '.concat(_,'\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  \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(c,"\n </div>\n <div>").concat("medialist"===l.type()?"不支持多页视频,若需要请到视频原播放页面下载":"",'</div>\n <div style="margin:2% 0;">\n <button id="checkbox_btn">全选</button>\n </div>');function g(t,n,i){if(t.length)if(n<t.length){var r=t[n],a="第".concat(n+1,"(").concat(n+1,"/").concat(t.length,")个视频");o._p.alert("".concat(a,":获取中...")),setTimeout((function(){p.get_urls(r.p,r.q,r.format,(function(l){if(!l.code){o.v0.success("请求成功"+(l.times?"<br/>今日剩余请求次数".concat(l.times):"")),o._p.alert("".concat(a,":获取成功!"));var c=[l.url,I(l.url),x()],s=c[0],u=c[1],d=c[2];"post"===d?(i.push({url:s,filename:r.filename+u}),i.length>3&&(w(i),i.length=0)):"ariang"===d&&function(t){var n=window.bp_aria2_window,i=100;n&&!n.closed||(S(),i=3e3);setTimeout((function(){var n=window.bp_aria2_window,i="header=User-Agent:".concat(window.navigator.userAgent,"&header=Referer:").concat(window.location.href);if(n&&!n.closed){var r="#!/new/task?url=".concat(window.btoa(t.url),"&out=").concat(encodeURIComponent(t.filename),"&").concat(i);n.location.href=e.config.ariang_host+r,o.v0.success("RPC请求成功")}else o.v0.warning("请检查RPC参数")}),i)}({url:s,filename:r.filename+u})}setTimeout((function(){g(t,++n,i)}),3e3)}),(function(){g(t,++n,i)}))}),3e3)}else o._p.alert("视频地址请求完成!"),"post"===x()&&i.length>0&&(w(i),i.length=0)}function w(t){var n,r={domain:e.config.rpc_domain,port:e.config.rpc_port,token:e.config.rpc_token,dir:e.config.rpc_dir},a=[],l=y(t);try{for(l.s();!(n=l.n()).done;){var c=n.value;a.push({id:window.btoa("BParse_".concat(Date.now(),"_").concat(Math.random())),jsonrpc:"2.0",method:"aria2.addUri",params:["token:".concat(r.token),[c.url],{dir:r.dir,out:c.filename,header:["User-Agent: ".concat(window.navigator.userAgent),"Referer: ".concat(window.location.href)]}]})}}catch(e){l.e(e)}finally{l.f()}o.v0.info("发送RPC下载请求"),(0,i.h)({url:"".concat(r.domain,":").concat(r.port,"/jsonrpc"),type:"POST",dataType:"json",data:JSON.stringify(a)}).then((function(e){e.length===a.length?o.v0.success("RPC请求成功"):o.v0.warning("请检查RPC参数")})).catch((function(e){o.v0.error("请检查RPC服务配置")}))}o._p.confirm(m,(function(){for(var e=$("#dl_quality").val()||r,n=$("#dl_subtitle").val(),o=$("#dl_danmaku").val(),i=[],l=0;l<a;l++)if($("input#option_".concat(l)).is(":checked")){var c=l+1,s=[t.cid(c),t.filename(c)],u=s[0],d=s[1],p=$("#dl_format").val();i.push({cid:u,p:c,q:e,format:p,filename:d})}"1"===n&&A([].concat(i),new b.$),"1"===o&&F([].concat(i),new b.$),g(i,0,[])})),$("#dl_quality").val(r>120?80:r)},download_danmaku_ass:function(e,t){P(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 o.v0.warning("未发现字幕")};p.get_subtitle_url(e,n)},open_ariang:S},j=__webpack_require__(378);function R(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}var M=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.is_login=!1,this.vip_status=0,this.mid="",this.uname="",this.has_init=!1,this.lazyInit()}var t,n,o;return t=e,(n=[{key:"needReplace",value:function(){return!this.is_login||!this.vip_status&&l.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)}}])&&R(t.prototype,n),o&&R(t,o),Object.defineProperty(t,"prototype",{writable:!1}),e}());function U(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}var q=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 r,a,l;return r=t,a=[{key:"reLogin",value:function(){n.set("auth_id",""),n.set("auth_sec",""),n.set("access_key",""),n.set("auth_time","0"),this.login()}},{key:"checkLoginStatus",value:function(){var t=this,r=[n.get("auth_id"),n.get("auth_sec"),n.get("access_key"),n.get("auth_time")||"0"],a=r[0],l=r[1],c=r[2],s=r[3];c&&(M.is_login&&(e.config.base_api!==n.get("pre_base_api")||Date.now()-parseInt(s)>864e5)&&(0,i.h)({url:"https://api.bilibili.com/x/space/myinfo?access_key=".concat(c),type:"GET",dataType:"json"}).then((function(r){if(!r.code)return n.set("auth_time",Date.now()),(0,i.h)({url:"".concat(e.config.base_api,"/auth/v2/?act=check&auth_id=").concat(a,"&auth_sec=").concat(l,"&access_key=").concat(c),type:"GET",dataType:"json"});o._p.alert("授权已过期,准备重新授权",t.reLogin)})).then((function(e){e.code&&o._p.alert("授权检查失败,准备重新授权",t.reLogin)})),n.set("pre_base_api",e.config.base_api))}},{key:"_login",value:function(e){var t=this;this.auth_clicked?o.v0.miaow():(this.auth_clicked=!0,(0,i.h)({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);n.get("auth_id")?o._p.confirm("发现授权记录,是否重新授权?",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>")):o._p.confirm("必须登录B站才能正常授权,是否登陆?",(function(){location.href="https://passport.bilibili.com/login"}))}))}},{key:"loginManual",value:function(){this._login((function(t){if(t.data.has_login){var r=""+"请点击<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>然后点击确定即可");o._p.alert(r,(function(){var t=$("#auth_url").val(),r=n.get("auth_id")||"",a=n.get("auth_sec")||"";(0,i.h)({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(r,"&auth_sec=").concat(a,"&")),type:"GET",dataType:"json"}).then((function(i){i.code?o.v0.warning("授权失败"):(o.v0.success("授权成功"),i.auth_id&&i.auth_sec&&(n.set("auth_id",i.auth_id),n.set("auth_sec",i.auth_sec)),n.set("access_key",new URL(t).searchParams.get("access_key")),n.set("auth_time",Date.now()),$("#auth").val("1"),e.config.auth="1")}))}))}else o._p.confirm("必须登录B站才能正常授权,是否登陆?",(function(){location.href="https://passport.bilibili.com/login"}))}))}},{key:"logout",value:function(){var t=this;if(n.get("auth_id"))if(this.auth_clicked)o.v0.miaow();else{var r=[n.get("auth_id"),n.get("auth_sec")],a=r[0],l=r[1];(0,i.h)({url:"".concat(e.config.base_api,"/auth/v2/?act=logout&auth_id=").concat(a,"&auth_sec=").concat(l),type:"GET",dataType:"json"}).then((function(t){t.code?o.v0.warning("取消失败"):(o.v0.success("取消成功"),n.set("auth_id",""),n.set("auth_sec",""),n.set("auth_time","0"),n.set("access_key",""),$("#auth").val("0"),e.config.auth="0")})).finally((function(e){return t.auth_clicked=!1}))}else o._p.alert("没有发现授权记录")}},{key:"initAuth",value:function(){var t=this;window.addEventListener("message",(function(r){if("string"==typeof r.data&&"bilibili-parse-login-credentials"===r.data.split(":")[0]){$("iframe#auth_iframe").remove();var a=r.data.split(": ")[1],l=[n.get("auth_id"),n.get("auth_sec")],c=l[0],s=l[1];(0,i.h)({url:a.replace("https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png?","".concat(e.config.base_api,"/auth/v2/?act=login&auth_id=").concat(c,"&auth_sec=").concat(s,"&")),type:"GET",dataType:"json"}).then((function(t){t.code?o.v0.warning("授权失败"):(o.v0.success("授权成功"),t.auth_id&&t.auth_sec&&(n.set("auth_id",t.auth_id),n.set("auth_sec",t.auth_sec)),n.set("access_key",new URL(a).searchParams.get("access_key")),n.set("auth_time",Date.now()),$("#auth").val("1"),e.config.auth="1")})).finally((function(e){return t.auth_clicked=!1}))}}))}}],a&&U(r.prototype,a),l&&U(r,l),Object.defineProperty(r,"prototype",{writable:!1}),t}(),D=new q;function V(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}var N=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,o;return t=e,(n=[{key:"refresh",value:function(){console.log("refresh..."),$("#video_download").hide(),$("#video_download_2").hide(),g.recover_player();var e=l.base();this.aid=e.aid(),this.cid=e.cid(),this.epid=e.epid(),this.q=l.get_quality().q,window.bp_episodes=null}}])&&V(t.prototype,n),o&&V(t,o),Object.defineProperty(t,"prototype",{writable:!1}),e}());function B(e,t){const n=Object.create(null),o=e.split(",");for(let e=0;e<o.length;e++)n[o[e]]=!0;return t?e=>!!n[e.toLowerCase()]:e=>!!n[e]}const z="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",H=B(z);function W(e){return!!e||""===e}function G(e){if(ue(e)){const t={};for(let n=0;n<e.length;n++){const o=e[n],i=_e(o)?K(o):G(o);if(i)for(const e in i)t[e]=i[e]}return t}return _e(e)||ve(e)?e:void 0}const J=/;(?![^(]*\))/g,Z=/:(.+)/;function K(e){const t={};return e.split(J).forEach((e=>{if(e){const n=e.split(Z);n.length>1&&(t[n[0].trim()]=n[1].trim())}})),t}function Y(e){let t="";if(_e(e))t=e;else if(ue(e))for(let n=0;n<e.length;n++){const o=Y(e[n]);o&&(t+=o+" ")}else if(ve(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const X=(e,t)=>t&&t.__v_isRef?X(e,t.value):de(t)?{[`Map(${t.size})`]:[...t.entries()].reduce(((e,[t,n])=>(e[`${t} =>`]=n,e)),{})}:pe(t)?{[`Set(${t.size})`]:[...t.values()]}:!ve(t)||ue(t)||ye(t)?t:String(t),Q={},ee=[],te=()=>{},ne=()=>!1,oe=/^on[^a-z]/,ie=e=>oe.test(e),re=e=>e.startsWith("onUpdate:"),ae=Object.assign,le=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},ce=Object.prototype.hasOwnProperty,se=(e,t)=>ce.call(e,t),ue=Array.isArray,de=e=>"[object Map]"===be(e),pe=e=>"[object Set]"===be(e),fe=e=>"function"==typeof e,_e=e=>"string"==typeof e,he=e=>"symbol"==typeof e,ve=e=>null!==e&&"object"==typeof e,me=e=>ve(e)&&fe(e.then)&&fe(e.catch),ge=Object.prototype.toString,be=e=>ge.call(e),ye=e=>"[object Object]"===be(e),we=e=>_e(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,xe=B(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),ke=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Se=/-(\w)/g,$e=ke((e=>e.replace(Se,((e,t)=>t?t.toUpperCase():"")))),Ce=/\B([A-Z])/g,Oe=ke((e=>e.replace(Ce,"-$1").toLowerCase())),Te=ke((e=>e.charAt(0).toUpperCase()+e.slice(1))),Pe=ke((e=>e?`on${Te(e)}`:"")),Ee=(e,t)=>!Object.is(e,t),Fe=(e,t)=>{for(let n=0;n<e.length;n++)e[n](t)},Ae=(e,t,n)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},Ie=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let Le;const je=()=>Le||(Le="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==__webpack_require__.g?__webpack_require__.g:{});let Re;class Me{constructor(e=!1){this.active=!0,this.effects=[],this.cleanups=[],!e&&Re&&(this.parent=Re,this.index=(Re.scopes||(Re.scopes=[])).push(this)-1)}run(e){if(this.active){const t=Re;try{return Re=this,e()}finally{Re=t}}else 0}on(){Re=this}off(){Re=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 Ue(e,t=Re){t&&t.active&&t.effects.push(e)}const qe=e=>{const t=new Set(e);return t.w=0,t.n=0,t},De=e=>(e.w&ze)>0,Ve=e=>(e.n&ze)>0,Ne=new WeakMap;let Be=0,ze=1;let He;const We=Symbol(""),Ge=Symbol("");class Je{constructor(e,t=null,n){this.fn=e,this.scheduler=t,this.active=!0,this.deps=[],this.parent=void 0,Ue(this,n)}run(){if(!this.active)return this.fn();let e=He,t=Ke;for(;e;){if(e===this)return;e=e.parent}try{return this.parent=He,He=this,Ke=!0,ze=1<<++Be,Be<=30?(({deps:e})=>{if(e.length)for(let t=0;t<e.length;t++)e[t].w|=ze})(this):Ze(this),this.fn()}finally{Be<=30&&(e=>{const{deps:t}=e;if(t.length){let n=0;for(let o=0;o<t.length;o++){const i=t[o];De(i)&&!Ve(i)?i.delete(e):t[n++]=i,i.w&=~ze,i.n&=~ze}t.length=n}})(this),ze=1<<--Be,He=this.parent,Ke=t,this.parent=void 0,this.deferStop&&this.stop()}}stop(){He===this?this.deferStop=!0:this.active&&(Ze(this),this.onStop&&this.onStop(),this.active=!1)}}function Ze(e){const{deps:t}=e;if(t.length){for(let n=0;n<t.length;n++)t[n].delete(e);t.length=0}}let Ke=!0;const Ye=[];function Xe(){Ye.push(Ke),Ke=!1}function Qe(){const e=Ye.pop();Ke=void 0===e||e}function et(e,t,n){if(Ke&&He){let t=Ne.get(e);t||Ne.set(e,t=new Map);let o=t.get(n);o||t.set(n,o=qe());tt(o,void 0)}}function tt(e,t){let n=!1;Be<=30?Ve(e)||(e.n|=ze,n=!De(e)):n=!e.has(He),n&&(e.add(He),He.deps.push(e))}function nt(e,t,n,o,i,r){const a=Ne.get(e);if(!a)return;let l=[];if("clear"===t)l=[...a.values()];else if("length"===n&&ue(e))a.forEach(((e,t)=>{("length"===t||t>=o)&&l.push(e)}));else switch(void 0!==n&&l.push(a.get(n)),t){case"add":ue(e)?we(n)&&l.push(a.get("length")):(l.push(a.get(We)),de(e)&&l.push(a.get(Ge)));break;case"delete":ue(e)||(l.push(a.get(We)),de(e)&&l.push(a.get(Ge)));break;case"set":de(e)&&l.push(a.get(We))}if(1===l.length)l[0]&&ot(l[0]);else{const e=[];for(const t of l)t&&e.push(...t);ot(qe(e))}}function ot(e,t){for(const t of ue(e)?e:[...e])(t!==He||t.allowRecurse)&&(t.scheduler?t.scheduler():t.run())}const it=B("__proto__,__v_isRef,__isVue"),rt=new Set(Object.getOwnPropertyNames(Symbol).map((e=>Symbol[e])).filter(he)),at=dt(),lt=dt(!1,!0),ct=dt(!0),st=ut();function ut(){const e={};return["includes","indexOf","lastIndexOf"].forEach((t=>{e[t]=function(...e){const n=Zt(this);for(let e=0,t=this.length;e<t;e++)et(n,0,e+"");const o=n[t](...e);return-1===o||!1===o?n[t](...e.map(Zt)):o}})),["push","pop","shift","unshift","splice"].forEach((t=>{e[t]=function(...e){Xe();const n=Zt(this)[t].apply(this,e);return Qe(),n}})),e}function dt(e=!1,t=!1){return function(n,o,i){if("__v_isReactive"===o)return!e;if("__v_isReadonly"===o)return e;if("__v_isShallow"===o)return t;if("__v_raw"===o&&i===(e?t?Dt:qt:t?Ut:Mt).get(n))return n;const r=ue(n);if(!e&&r&&se(st,o))return Reflect.get(st,o,i);const a=Reflect.get(n,o,i);if(he(o)?rt.has(o):it(o))return a;if(e||et(n,0,o),t)return a;if(tn(a)){return!r||!we(o)?a.value:a}return ve(a)?e?Bt(a):Nt(a):a}}function pt(e=!1){return function(t,n,o,i){let r=t[n];if(Wt(r)&&tn(r)&&!tn(o))return!1;if(!e&&!Wt(o)&&(Gt(o)||(o=Zt(o),r=Zt(r)),!ue(t)&&tn(r)&&!tn(o)))return r.value=o,!0;const a=ue(t)&&we(n)?Number(n)<t.length:se(t,n),l=Reflect.set(t,n,o,i);return t===Zt(i)&&(a?Ee(o,r)&&nt(t,"set",n,o):nt(t,"add",n,o)),l}}const ft={get:at,set:pt(),deleteProperty:function(e,t){const n=se(e,t),o=(e[t],Reflect.deleteProperty(e,t));return o&&n&&nt(e,"delete",t,void 0),o},has:function(e,t){const n=Reflect.has(e,t);return he(t)&&rt.has(t)||et(e,0,t),n},ownKeys:function(e){return et(e,0,ue(e)?"length":We),Reflect.ownKeys(e)}},_t={get:ct,set:(e,t)=>!0,deleteProperty:(e,t)=>!0},ht=ae({},ft,{get:lt,set:pt(!0)}),vt=e=>e,mt=e=>Reflect.getPrototypeOf(e);function gt(e,t,n=!1,o=!1){const i=Zt(e=e.__v_raw),r=Zt(t);t!==r&&!n&&et(i,0,t),!n&&et(i,0,r);const{has:a}=mt(i),l=o?vt:n?Xt:Yt;return a.call(i,t)?l(e.get(t)):a.call(i,r)?l(e.get(r)):void(e!==i&&e.get(t))}function bt(e,t=!1){const n=this.__v_raw,o=Zt(n),i=Zt(e);return e!==i&&!t&&et(o,0,e),!t&&et(o,0,i),e===i?n.has(e):n.has(e)||n.has(i)}function yt(e,t=!1){return e=e.__v_raw,!t&&et(Zt(e),0,We),Reflect.get(e,"size",e)}function wt(e){e=Zt(e);const t=Zt(this);return mt(t).has.call(t,e)||(t.add(e),nt(t,"add",e,e)),this}function xt(e,t){t=Zt(t);const n=Zt(this),{has:o,get:i}=mt(n);let r=o.call(n,e);r||(e=Zt(e),r=o.call(n,e));const a=i.call(n,e);return n.set(e,t),r?Ee(t,a)&&nt(n,"set",e,t):nt(n,"add",e,t),this}function kt(e){const t=Zt(this),{has:n,get:o}=mt(t);let i=n.call(t,e);i||(e=Zt(e),i=n.call(t,e));o&&o.call(t,e);const r=t.delete(e);return i&&nt(t,"delete",e,void 0),r}function St(){const e=Zt(this),t=0!==e.size,n=e.clear();return t&&nt(e,"clear",void 0,void 0),n}function $t(e,t){return function(n,o){const i=this,r=i.__v_raw,a=Zt(r),l=t?vt:e?Xt:Yt;return!e&&et(a,0,We),r.forEach(((e,t)=>n.call(o,l(e),l(t),i)))}}function Ct(e,t,n){return function(...o){const i=this.__v_raw,r=Zt(i),a=de(r),l="entries"===e||e===Symbol.iterator&&a,c="keys"===e&&a,s=i[e](...o),u=n?vt:t?Xt:Yt;return!t&&et(r,0,c?Ge:We),{next(){const{value:e,done:t}=s.next();return t?{value:e,done:t}:{value:l?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function Ot(e){return function(...t){return"delete"!==e&&this}}function Tt(){const e={get(e){return gt(this,e)},get size(){return yt(this)},has:bt,add:wt,set:xt,delete:kt,clear:St,forEach:$t(!1,!1)},t={get(e){return gt(this,e,!1,!0)},get size(){return yt(this)},has:bt,add:wt,set:xt,delete:kt,clear:St,forEach:$t(!1,!0)},n={get(e){return gt(this,e,!0)},get size(){return yt(this,!0)},has(e){return bt.call(this,e,!0)},add:Ot("add"),set:Ot("set"),delete:Ot("delete"),clear:Ot("clear"),forEach:$t(!0,!1)},o={get(e){return gt(this,e,!0,!0)},get size(){return yt(this,!0)},has(e){return bt.call(this,e,!0)},add:Ot("add"),set:Ot("set"),delete:Ot("delete"),clear:Ot("clear"),forEach:$t(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach((i=>{e[i]=Ct(i,!1,!1),n[i]=Ct(i,!0,!1),t[i]=Ct(i,!1,!0),o[i]=Ct(i,!0,!0)})),[e,n,t,o]}const[Pt,Et,Ft,At]=Tt();function It(e,t){const n=t?e?At:Ft:e?Et:Pt;return(t,o,i)=>"__v_isReactive"===o?!e:"__v_isReadonly"===o?e:"__v_raw"===o?t:Reflect.get(se(n,o)&&o in t?n:t,o,i)}const Lt={get:It(!1,!1)},jt={get:It(!1,!0)},Rt={get:It(!0,!1)};const Mt=new WeakMap,Ut=new WeakMap,qt=new WeakMap,Dt=new WeakMap;function Vt(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=>be(e).slice(8,-1))(e))}function Nt(e){return Wt(e)?e:zt(e,!1,ft,Lt,Mt)}function Bt(e){return zt(e,!0,_t,Rt,qt)}function zt(e,t,n,o,i){if(!ve(e))return e;if(e.__v_raw&&(!t||!e.__v_isReactive))return e;const r=i.get(e);if(r)return r;const a=Vt(e);if(0===a)return e;const l=new Proxy(e,2===a?o:n);return i.set(e,l),l}function Ht(e){return Wt(e)?Ht(e.__v_raw):!(!e||!e.__v_isReactive)}function Wt(e){return!(!e||!e.__v_isReadonly)}function Gt(e){return!(!e||!e.__v_isShallow)}function Jt(e){return Ht(e)||Wt(e)}function Zt(e){const t=e&&e.__v_raw;return t?Zt(t):e}function Kt(e){return Ae(e,"__v_skip",!0),e}const Yt=e=>ve(e)?Nt(e):e,Xt=e=>ve(e)?Bt(e):e;function Qt(e){Ke&&He&&tt((e=Zt(e)).dep||(e.dep=qe()))}function en(e,t){(e=Zt(e)).dep&&ot(e.dep)}function tn(e){return!(!e||!0!==e.__v_isRef)}const nn={get:(e,t,n)=>function(e){return tn(e)?e.value:e}(Reflect.get(e,t,n)),set:(e,t,n,o)=>{const i=e[t];return tn(i)&&!tn(n)?(i.value=n,!0):Reflect.set(e,t,n,o)}};function on(e){return Ht(e)?e:new Proxy(e,nn)}class rn{constructor(e,t,n,o){this._setter=t,this.dep=void 0,this.__v_isRef=!0,this._dirty=!0,this.effect=new Je(e,(()=>{this._dirty||(this._dirty=!0,en(this))})),this.effect.computed=this,this.effect.active=this._cacheable=!o,this.__v_isReadonly=n}get value(){const e=Zt(this);return Qt(e),!e._dirty&&e._cacheable||(e._dirty=!1,e._value=e.effect.run()),e._value}set value(e){this._setter(e)}}function an(e,t,n,o){let i;try{i=o?e(...o):e()}catch(e){cn(e,t,n)}return i}function ln(e,t,n,o){if(fe(e)){const i=an(e,t,n,o);return i&&me(i)&&i.catch((e=>{cn(e,t,n)})),i}const i=[];for(let r=0;r<e.length;r++)i.push(ln(e[r],t,n,o));return i}function cn(e,t,n,o=!0){t&&t.vnode;if(t){let o=t.parent;const i=t.proxy,r=n;for(;o;){const t=o.ec;if(t)for(let n=0;n<t.length;n++)if(!1===t[n](e,i,r))return;o=o.parent}const a=t.appContext.config.errorHandler;if(a)return void an(a,null,10,[e,i,r])}!function(e,t,n,o=!0){console.error(e)}(e,0,0,o)}let sn=!1,un=!1;const dn=[];let pn=0;const fn=[];let _n=null,hn=0;const vn=[];let mn=null,gn=0;const bn=Promise.resolve();let yn=null,wn=null;function xn(e){const t=yn||bn;return e?t.then(this?e.bind(this):e):t}function kn(e){dn.length&&dn.includes(e,sn&&e.allowRecurse?pn+1:pn)||e===wn||(null==e.id?dn.push(e):dn.splice(function(e){let t=pn+1,n=dn.length;for(;t<n;){const o=t+n>>>1;Pn(dn[o])<e?t=o+1:n=o}return t}(e.id),0,e),Sn())}function Sn(){sn||un||(un=!0,yn=bn.then(En))}function $n(e,t,n,o){ue(e)?n.push(...e):t&&t.includes(e,e.allowRecurse?o+1:o)||n.push(e),Sn()}function Cn(e){$n(e,mn,vn,gn)}function On(e,t=null){if(fn.length){for(wn=t,_n=[...new Set(fn)],fn.length=0,hn=0;hn<_n.length;hn++)_n[hn]();_n=null,hn=0,wn=null,On(e,t)}}function Tn(e){if(vn.length){const e=[...new Set(vn)];if(vn.length=0,mn)return void mn.push(...e);for(mn=e,mn.sort(((e,t)=>Pn(e)-Pn(t))),gn=0;gn<mn.length;gn++)mn[gn]();mn=null,gn=0}}const Pn=e=>null==e.id?1/0:e.id;function En(e){un=!1,sn=!0,On(e),dn.sort(((e,t)=>Pn(e)-Pn(t)));try{for(pn=0;pn<dn.length;pn++){const e=dn[pn];e&&!1!==e.active&&an(e,null,14)}}finally{pn=0,dn.length=0,Tn(),sn=!1,yn=null,(dn.length||fn.length||vn.length)&&En(e)}}new Set;new Map;let Fn,An=[],In=!1;function Ln(e,...t){Fn?Fn.emit(e,...t):In||An.push({event:e,args:t})}function jn(e,t){var n,o;if(Fn=e,Fn)Fn.enabled=!0,An.forEach((({event:e,args:t})=>Fn.emit(e,...t))),An=[];else if("undefined"!=typeof window&&window.HTMLElement&&!(null===(o=null===(n=window.navigator)||void 0===n?void 0:n.userAgent)||void 0===o?void 0:o.includes("jsdom"))){(t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push((e=>{jn(e,t)})),setTimeout((()=>{Fn||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,In=!0,An=[])}),3e3)}else In=!0,An=[]}const Rn=qn("component:added"),Mn=qn("component:updated"),Un=qn("component:removed");function qn(e){return t=>{Ln(e,t.appContext.app,t.uid,t.parent?t.parent.uid:void 0,t)}}function Dn(e,t,...n){if(e.isUnmounted)return;const o=e.vnode.props||Q;let i=n;const r=t.startsWith("update:"),a=r&&t.slice(7);if(a&&a in o){const e=`${"modelValue"===a?"model":a}Modifiers`,{number:t,trim:r}=o[e]||Q;r?i=n.map((e=>e.trim())):t&&(i=n.map(Ie))}let l;__VUE_PROD_DEVTOOLS__&&function(e,t,n){Ln("component:emit",e.appContext.app,e,t,n)}(e,t,i);let c=o[l=Pe(t)]||o[l=Pe($e(t))];!c&&r&&(c=o[l=Pe(Oe(t))]),c&&ln(c,e,6,i);const s=o[l+"Once"];if(s){if(e.emitted){if(e.emitted[l])return}else e.emitted={};e.emitted[l]=!0,ln(s,e,6,i)}}function Vn(e,t,n=!1){const o=t.emitsCache,i=o.get(e);if(void 0!==i)return i;const r=e.emits;let a={},l=!1;if(__VUE_OPTIONS_API__&&!fe(e)){const o=e=>{const n=Vn(e,t,!0);n&&(l=!0,ae(a,n))};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}return r||l?(ue(r)?r.forEach((e=>a[e]=null)):ae(a,r),o.set(e,a),a):(o.set(e,null),null)}function Nn(e,t){return!(!e||!ie(t))&&(t=t.slice(2).replace(/Once$/,""),se(e,t[0].toLowerCase()+t.slice(1))||se(e,Oe(t))||se(e,t))}let Bn=null,zn=null;function Hn(e){const t=Bn;return Bn=e,zn=e&&e.type.__scopeId||null,t}function Wn(e,t=Bn,n){if(!t)return e;if(e._n)return e;const o=(...n)=>{o._d&&Ci(-1);const i=Hn(t),r=e(...n);return Hn(i),o._d&&Ci(1),__VUE_PROD_DEVTOOLS__&&Mn(t),r};return o._n=!0,o._c=!0,o._d=!0,o}function Gn(e){const{type:t,vnode:n,proxy:o,withProxy:i,props:r,propsOptions:[a],slots:l,attrs:c,emit:s,render:u,renderCache:d,data:p,setupState:f,ctx:_,inheritAttrs:h}=e;let v,m;const g=Hn(e);try{if(4&n.shapeFlag){const e=i||o;v=Ni(u.call(e,e,d,r,f,p,_)),m=c}else{const e=t;0,v=Ni(e.length>1?e(r,{attrs:c,slots:l,emit:s}):e(r,null)),m=t.props?c:Jn(c)}}catch(t){wi.length=0,cn(t,e,1),v=Ri(bi)}let b=v;if(m&&!1!==h){const e=Object.keys(m),{shapeFlag:t}=b;e.length&&7&t&&(a&&e.some(re)&&(m=Zn(m,a)),b=Ui(b,m))}return n.dirs&&(b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&(b.transition=n.transition),v=b,Hn(g),v}const Jn=e=>{let t;for(const n in e)("class"===n||"style"===n||ie(n))&&((t||(t={}))[n]=e[n]);return t},Zn=(e,t)=>{const n={};for(const o in e)re(o)&&o.slice(9)in t||(n[o]=e[o]);return n};function Kn(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).length)return!0;for(let i=0;i<o.length;i++){const r=o[i];if(t[r]!==e[r]&&!Nn(n,r))return!0}return!1}function Yn({vnode:e,parent:t},n){for(;t&&t.subTree===e;)(e=t.vnode).el=n,t=t.parent}function Xn(e,t){t&&t.pendingBranch?ue(e)?t.effects.push(...e):t.effects.push(e):Cn(e)}function Qn(e,t,n=!1){const o=Qi||Bn;if(o){const i=null==o.parent?o.vnode.appContext&&o.vnode.appContext.provides:o.parent.provides;if(i&&e in i)return i[e];if(arguments.length>1)return n&&fe(t)?t.call(o.proxy):t}else 0}const eo={};function to(e,t,n){return no(e,t,n)}function no(e,t,{immediate:n,deep:o,flush:i,onTrack:r,onTrigger:a}=Q){const l=Qi;let c,s,u=!1,d=!1;if(tn(e)?(c=()=>e.value,u=Gt(e)):Ht(e)?(c=()=>e,o=!0):ue(e)?(d=!0,u=e.some(Ht),c=()=>e.map((e=>tn(e)?e.value:Ht(e)?ro(e):fe(e)?an(e,l,2):void 0))):c=fe(e)?t?()=>an(e,l,2):()=>{if(!l||!l.isUnmounted)return s&&s(),ln(e,l,3,[p])}:te,t&&o){const e=c;c=()=>ro(e())}let p=e=>{s=v.onStop=()=>{an(e,l,4)}};if(ar)return p=te,t?n&&ln(t,l,3,[c(),d?[]:void 0,p]):c(),te;let f=d?[]:eo;const _=()=>{if(v.active)if(t){const e=v.run();(o||u||(d?e.some(((e,t)=>Ee(e,f[t]))):Ee(e,f)))&&(s&&s(),ln(t,l,3,[e,f===eo?void 0:f,p]),f=e)}else v.run()};let h;_.allowRecurse=!!t,h="sync"===i?_:"post"===i?()=>pi(_,l&&l.suspense):()=>{!l||l.isMounted?function(e){$n(e,_n,fn,hn)}(_):_()};const v=new Je(c,h);return t?n?_():f=v.run():"post"===i?pi(v.run.bind(v),l&&l.suspense):v.run(),()=>{v.stop(),l&&l.scope&&le(l.scope.effects,v)}}function oo(e,t,n){const o=this.proxy,i=_e(e)?e.includes(".")?io(o,e):()=>o[e]:e.bind(o,o);let r;fe(t)?r=t:(r=t.handler,n=t);const a=Qi;tr(this);const l=no(i,r.bind(o),n);return a?tr(a):nr(),l}function io(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 ro(e,t){if(!ve(e)||e.__v_skip)return e;if((t=t||new Set).has(e))return e;if(t.add(e),tn(e))ro(e.value,t);else if(ue(e))for(let n=0;n<e.length;n++)ro(e[n],t);else if(pe(e)||de(e))e.forEach((e=>{ro(e,t)}));else if(ye(e))for(const n in e)ro(e[n],t);return e}function ao(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return To((()=>{e.isMounted=!0})),Fo((()=>{e.isUnmounting=!0})),e}const lo=[Function,Array],co={name:"BaseTransition",props:{mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:lo,onEnter:lo,onAfterEnter:lo,onEnterCancelled:lo,onBeforeLeave:lo,onLeave:lo,onAfterLeave:lo,onLeaveCancelled:lo,onBeforeAppear:lo,onAppear:lo,onAfterAppear:lo,onAppearCancelled:lo},setup(e,{slots:t}){const n=er(),o=ao();let i;return()=>{const r=t.default&&ho(t.default(),!0);if(!r||!r.length)return;let a=r[0];if(r.length>1){let e=!1;for(const t of r)if(t.type!==bi){0,a=t,e=!0;break}}const l=Zt(e),{mode:c}=l;if(o.isLeaving)return po(a);const s=fo(a);if(!s)return po(a);const u=uo(s,l,o,n);_o(s,u);const d=n.subTree,p=d&&fo(d);let f=!1;const{getTransitionKey:_}=s.type;if(_){const e=_();void 0===i?i=e:e!==i&&(i=e,f=!0)}if(p&&p.type!==bi&&(!Fi(s,p)||f)){const e=uo(p,l,o,n);if(_o(p,e),"out-in"===c)return o.isLeaving=!0,e.afterLeave=()=>{o.isLeaving=!1,n.update()},po(a);"in-out"===c&&s.type!==bi&&(e.delayLeave=(e,t,n)=>{so(o,p)[String(p.key)]=p,e._leaveCb=()=>{t(),e._leaveCb=void 0,delete u.delayedLeave},u.delayedLeave=n})}return a}}};function so(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||(o=Object.create(null),n.set(t.type,o)),o}function uo(e,t,n,o){const{appear:i,mode:r,persisted:a=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:s,onEnterCancelled:u,onBeforeLeave:d,onLeave:p,onAfterLeave:f,onLeaveCancelled:_,onBeforeAppear:h,onAppear:v,onAfterAppear:m,onAppearCancelled:g}=t,b=String(e.key),y=so(n,e),w=(e,t)=>{e&&ln(e,o,9,t)},x={mode:r,persisted:a,beforeEnter(t){let o=l;if(!n.isMounted){if(!i)return;o=h||l}t._leaveCb&&t._leaveCb(!0);const r=y[b];r&&Fi(e,r)&&r.el._leaveCb&&r.el._leaveCb(),w(o,[t])},enter(e){let t=c,o=s,r=u;if(!n.isMounted){if(!i)return;t=v||c,o=m||s,r=g||u}let a=!1;const l=e._enterCb=t=>{a||(a=!0,w(t?r:o,[e]),x.delayedLeave&&x.delayedLeave(),e._enterCb=void 0)};t?(t(e,l),t.length<=1&&l()):l()},leave(t,o){const i=String(e.key);if(t._enterCb&&t._enterCb(!0),n.isUnmounting)return o();w(d,[t]);let r=!1;const a=t._leaveCb=n=>{r||(r=!0,o(),w(n?_:f,[t]),t._leaveCb=void 0,y[i]===e&&delete y[i])};y[i]=e,p?(p(t,a),p.length<=1&&a()):a()},clone:e=>uo(e,t,n,o)};return x}function po(e){if(mo(e))return(e=Ui(e)).children=null,e}function fo(e){return mo(e)?e.children?e.children[0]:void 0:e}function _o(e,t){6&e.shapeFlag&&e.component?_o(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 ho(e,t=!1,n){let o=[],i=0;for(let r=0;r<e.length;r++){let a=e[r];const l=null==n?a.key:String(n)+String(null!=a.key?a.key:r);a.type===mi?(128&a.patchFlag&&i++,o=o.concat(ho(a.children,t,l))):(t||a.type!==bi)&&o.push(null!=l?Ui(a,{key:l}):a)}if(i>1)for(let e=0;e<o.length;e++)o[e].patchFlag=-2;return o}const vo=e=>!!e.type.__asyncLoader;const mo=e=>e.type.__isKeepAlive;RegExp,RegExp;function go(e,t){return ue(e)?e.some((e=>go(e,t))):_e(e)?e.split(",").includes(t):!!e.test&&e.test(t)}function bo(e,t){wo(e,"a",t)}function yo(e,t){wo(e,"da",t)}function wo(e,t,n=Qi){const o=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()});if($o(t,o,n),n){let e=n.parent;for(;e&&e.parent;)mo(e.parent.vnode)&&xo(o,t,n,e),e=e.parent}}function xo(e,t,n,o){const i=$o(t,e,o,!0);Ao((()=>{le(o[t],i)}),n)}function ko(e){let t=e.shapeFlag;256&t&&(t-=256),512&t&&(t-=512),e.shapeFlag=t}function So(e){return 128&e.shapeFlag?e.ssContent:e}function $o(e,t,n=Qi,o=!1){if(n){const i=n[e]||(n[e]=[]),r=t.__weh||(t.__weh=(...o)=>{if(n.isUnmounted)return;Xe(),tr(n);const i=ln(t,n,e,o);return nr(),Qe(),i});return o?i.unshift(r):i.push(r),r}}const Co=e=>(t,n=Qi)=>(!ar||"sp"===e)&&$o(e,t,n),Oo=Co("bm"),To=Co("m"),Po=Co("bu"),Eo=Co("u"),Fo=Co("bum"),Ao=Co("um"),Io=Co("sp"),Lo=Co("rtg"),jo=Co("rtc");function Ro(e,t=Qi){$o("ec",e,t)}let Mo=!0;function Uo(e){const t=Vo(e),n=e.proxy,o=e.ctx;Mo=!1,t.beforeCreate&&qo(t.beforeCreate,e,"bc");const{data:i,computed:r,methods:a,watch:l,provide:c,inject:s,created:u,beforeMount:d,mounted:p,beforeUpdate:f,updated:_,activated:h,deactivated:v,beforeDestroy:m,beforeUnmount:g,destroyed:b,unmounted:y,render:w,renderTracked:x,renderTriggered:k,errorCaptured:S,serverPrefetch:$,expose:C,inheritAttrs:O,components:T,directives:P,filters:E}=t;if(s&&function(e,t,n=te,o=!1){ue(e)&&(e=Ho(e));for(const n in e){const i=e[n];let r;r=ve(i)?"default"in i?Qn(i.from||n,i.default,!0):Qn(i.from||n):Qn(i),tn(r)&&o?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>r.value,set:e=>r.value=e}):t[n]=r}}(s,o,null,e.appContext.config.unwrapInjectedRef),a)for(const e in a){const t=a[e];fe(t)&&(o[e]=t.bind(n))}if(i){0;const t=i.call(n,n);0,ve(t)&&(e.data=Nt(t))}if(Mo=!0,r)for(const e in r){const t=r[e],i=fe(t)?t.bind(n,n):fe(t.get)?t.get.bind(n,n):te;0;const a=!fe(t)&&fe(t.set)?t.set.bind(n):te,l=_r({get:i,set:a});Object.defineProperty(o,e,{enumerable:!0,configurable:!0,get:()=>l.value,set:e=>l.value=e})}if(l)for(const e in l)Do(l[e],o,n,e);if(c){const e=fe(c)?c.call(n):c;Reflect.ownKeys(e).forEach((t=>{!function(e,t){if(Qi){let n=Qi.provides;const o=Qi.parent&&Qi.parent.provides;o===n&&(n=Qi.provides=Object.create(o)),n[e]=t}}(t,e[t])}))}function F(e,t){ue(t)?t.forEach((t=>e(t.bind(n)))):t&&e(t.bind(n))}if(u&&qo(u,e,"c"),F(Oo,d),F(To,p),F(Po,f),F(Eo,_),F(bo,h),F(yo,v),F(Ro,S),F(jo,x),F(Lo,k),F(Fo,g),F(Ao,y),F(Io,$),ue(C))if(C.length){const t=e.exposed||(e.exposed={});C.forEach((e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t})}))}else e.exposed||(e.exposed={});w&&e.render===te&&(e.render=w),null!=O&&(e.inheritAttrs=O),T&&(e.components=T),P&&(e.directives=P)}function qo(e,t,n){ln(ue(e)?e.map((e=>e.bind(t.proxy))):e.bind(t.proxy),t,n)}function Do(e,t,n,o){const i=o.includes(".")?io(n,o):()=>n[o];if(_e(e)){const n=t[e];fe(n)&&to(i,n)}else if(fe(e))to(i,e.bind(n));else if(ve(e))if(ue(e))e.forEach((e=>Do(e,t,n,o)));else{const o=fe(e.handler)?e.handler.bind(n):t[e.handler];fe(o)&&to(i,o,e)}else 0}function Vo(e){const t=e.type,{mixins:n,extends:o}=t,{mixins:i,optionsCache:r,config:{optionMergeStrategies:a}}=e.appContext,l=r.get(t);let c;return l?c=l:i.length||n||o?(c={},i.length&&i.forEach((e=>No(c,e,a,!0))),No(c,t,a)):c=t,r.set(t,c),c}function No(e,t,n,o=!1){const{mixins:i,extends:r}=t;r&&No(e,r,n,!0),i&&i.forEach((t=>No(e,t,n,!0)));for(const i in t)if(o&&"expose"===i);else{const o=Bo[i]||n&&n[i];e[i]=o?o(e[i],t[i]):t[i]}return e}const Bo={data:zo,props:Go,emits:Go,methods:Go,computed:Go,beforeCreate:Wo,created:Wo,beforeMount:Wo,mounted:Wo,beforeUpdate:Wo,updated:Wo,beforeDestroy:Wo,beforeUnmount:Wo,destroyed:Wo,unmounted:Wo,activated:Wo,deactivated:Wo,errorCaptured:Wo,serverPrefetch:Wo,components:Go,directives:Go,watch:function(e,t){if(!e)return t;if(!t)return e;const n=ae(Object.create(null),e);for(const o in t)n[o]=Wo(e[o],t[o]);return n},provide:zo,inject:function(e,t){return Go(Ho(e),Ho(t))}};function zo(e,t){return t?e?function(){return ae(fe(e)?e.call(this,this):e,fe(t)?t.call(this,this):t)}:t:e}function Ho(e){if(ue(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Wo(e,t){return e?[...new Set([].concat(e,t))]:t}function Go(e,t){return e?ae(ae(Object.create(null),e),t):t}function Jo(e,t,n,o=!1){const i={},r={};Ae(r,Ai,1),e.propsDefaults=Object.create(null),Zo(e,t,i,r);for(const t in e.propsOptions[0])t in i||(i[t]=void 0);n?e.props=o?i:zt(i,!1,ht,jt,Ut):e.type.props?e.props=i:e.props=r,e.attrs=r}function Zo(e,t,n,o){const[i,r]=e.propsOptions;let a,l=!1;if(t)for(let c in t){if(xe(c))continue;const s=t[c];let u;i&&se(i,u=$e(c))?r&&r.includes(u)?(a||(a={}))[u]=s:n[u]=s:Nn(e.emitsOptions,c)||c in o&&s===o[c]||(o[c]=s,l=!0)}if(r){const t=Zt(n),o=a||Q;for(let a=0;a<r.length;a++){const l=r[a];n[l]=Ko(i,t,l,o[l],e,!se(o,l))}}return l}function Ko(e,t,n,o,i,r){const a=e[n];if(null!=a){const e=se(a,"default");if(e&&void 0===o){const e=a.default;if(a.type!==Function&&fe(e)){const{propsDefaults:r}=i;n in r?o=r[n]:(tr(i),o=r[n]=e.call(null,t),nr())}else o=e}a[0]&&(r&&!e?o=!1:!a[1]||""!==o&&o!==Oe(n)||(o=!0))}return o}function Yo(e,t,n=!1){const o=t.propsCache,i=o.get(e);if(i)return i;const r=e.props,a={},l=[];let c=!1;if(__VUE_OPTIONS_API__&&!fe(e)){const o=e=>{c=!0;const[n,o]=Yo(e,t,!0);ae(a,n),o&&l.push(...o)};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}if(!r&&!c)return o.set(e,ee),ee;if(ue(r))for(let e=0;e<r.length;e++){0;const t=$e(r[e]);Xo(t)&&(a[t]=Q)}else if(r){0;for(const e in r){const t=$e(e);if(Xo(t)){const n=r[e],o=a[t]=ue(n)||fe(n)?{type:n}:n;if(o){const e=ti(Boolean,o.type),n=ti(String,o.type);o[0]=e>-1,o[1]=n<0||e<n,(e>-1||se(o,"default"))&&l.push(t)}}}}const s=[a,l];return o.set(e,s),s}function Xo(e){return"$"!==e[0]}function Qo(e){const t=e&&e.toString().match(/^\s*function (\w+)/);return t?t[1]:null===e?"null":""}function ei(e,t){return Qo(e)===Qo(t)}function ti(e,t){return ue(t)?t.findIndex((t=>ei(t,e))):fe(t)&&ei(t,e)?0:-1}const ni=e=>"_"===e[0]||"$stable"===e,oi=e=>ue(e)?e.map(Ni):[Ni(e)],ii=(e,t,n)=>{const o=Wn(((...e)=>oi(t(...e))),n);return o._c=!1,o},ri=(e,t,n)=>{const o=e._ctx;for(const n in e){if(ni(n))continue;const i=e[n];if(fe(i))t[n]=ii(0,i,o);else if(null!=i){0;const e=oi(i);t[n]=()=>e}}},ai=(e,t)=>{const n=oi(t);e.slots.default=()=>n};function li(e,t,n,o){const i=e.dirs,r=t&&t.dirs;for(let a=0;a<i.length;a++){const l=i[a];r&&(l.oldValue=r[a].value);let c=l.dir[o];c&&(Xe(),ln(c,n,8,[e.el,l,e,t]),Qe())}}function ci(){return{app:null,config:{isNativeTag:ne,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 si=0;function ui(e,t){return function(n,o=null){fe(n)||(n=Object.assign({},n)),null==o||ve(o)||(o=null);const i=ci(),r=new Set;let a=!1;const l=i.app={_uid:si++,_component:n,_props:o,_container:null,_context:i,_instance:null,version:hr,get config(){return i.config},set config(e){0},use:(e,...t)=>(r.has(e)||(e&&fe(e.install)?(r.add(e),e.install(l,...t)):fe(e)&&(r.add(e),e(l,...t))),l),mixin:e=>(__VUE_OPTIONS_API__&&(i.mixins.includes(e)||i.mixins.push(e)),l),component:(e,t)=>t?(i.components[e]=t,l):i.components[e],directive:(e,t)=>t?(i.directives[e]=t,l):i.directives[e],mount(r,c,s){if(!a){const u=Ri(n,o);return u.appContext=i,c&&t?t(u,r):e(u,r,s),a=!0,l._container=r,r.__vue_app__=l,__VUE_PROD_DEVTOOLS__&&(l._instance=u.component,function(e,t){Ln("app:init",e,t,{Fragment:mi,Text:gi,Comment:bi,Static:yi})}(l,hr)),dr(u.component)||u.component.proxy}},unmount(){a&&(e(null,l._container),__VUE_PROD_DEVTOOLS__&&(l._instance=null,function(e){Ln("app:unmount",e)}(l)),delete l._container.__vue_app__)},provide:(e,t)=>(i.provides[e]=t,l)};return l}}function di(e,t,n,o,i=!1){if(ue(e))return void e.forEach(((e,r)=>di(e,t&&(ue(t)?t[r]:t),n,o,i)));if(vo(o)&&!i)return;const r=4&o.shapeFlag?dr(o.component)||o.component.proxy:o.el,a=i?null:r,{i:l,r:c}=e;const s=t&&t.r,u=l.refs===Q?l.refs={}:l.refs,d=l.setupState;if(null!=s&&s!==c&&(_e(s)?(u[s]=null,se(d,s)&&(d[s]=null)):tn(s)&&(s.value=null)),fe(c))an(c,l,12,[a,u]);else{const t=_e(c),o=tn(c);if(t||o){const o=()=>{if(e.f){const n=t?u[c]:c.value;i?ue(n)&&le(n,r):ue(n)?n.includes(r)||n.push(r):t?(u[c]=[r],se(d,c)&&(d[c]=u[c])):(c.value=[r],e.k&&(u[e.k]=c.value))}else t?(u[c]=a,se(d,c)&&(d[c]=a)):tn(c)&&(c.value=a,e.k&&(u[e.k]=a))};a?(o.id=-1,pi(o,n)):o()}else 0}}const pi=Xn;function fi(e,t){"boolean"!=typeof __VUE_OPTIONS_API__&&(je().__VUE_OPTIONS_API__=!0),"boolean"!=typeof __VUE_PROD_DEVTOOLS__&&(je().__VUE_PROD_DEVTOOLS__=!1);const n=je();n.__VUE__=!0,__VUE_PROD_DEVTOOLS__&&jn(n.__VUE_DEVTOOLS_GLOBAL_HOOK__,n);const{insert:o,remove:i,patchProp:r,createElement:a,createText:l,createComment:c,setText:s,setElementText:u,parentNode:d,nextSibling:p,setScopeId:f=te,cloneNode:_,insertStaticContent:h}=e,v=(e,t,n,o=null,i=null,r=null,a=!1,l=null,c=!!t.dynamicChildren)=>{if(e===t)return;e&&!Fi(e,t)&&(o=B(e),U(e,i,r,!0),e=null),-2===t.patchFlag&&(c=!1,t.dynamicChildren=null);const{type:s,ref:u,shapeFlag:d}=t;switch(s){case gi:m(e,t,n,o);break;case bi:g(e,t,n,o);break;case yi:null==e&&b(t,n,o,a);break;case mi:T(e,t,n,o,i,r,a,l,c);break;default:1&d?w(e,t,n,o,i,r,a,l,c):6&d?P(e,t,n,o,i,r,a,l,c):(64&d||128&d)&&s.process(e,t,n,o,i,r,a,l,c,H)}null!=u&&i&&di(u,e&&e.ref,r,t||e,!t)},m=(e,t,n,i)=>{if(null==e)o(t.el=l(t.children),n,i);else{const n=t.el=e.el;t.children!==e.children&&s(n,t.children)}},g=(e,t,n,i)=>{null==e?o(t.el=c(t.children||""),n,i):t.el=e.el},b=(e,t,n,o)=>{[e.el,e.anchor]=h(e.children,t,n,o,e.el,e.anchor)},y=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=p(e),i(e),e=n;i(t)},w=(e,t,n,o,i,r,a,l,c)=>{a=a||"svg"===t.type,null==e?x(t,n,o,i,r,a,l,c):$(e,t,i,r,a,l,c)},x=(e,t,n,i,l,c,s,d)=>{let p,f;const{type:h,props:v,shapeFlag:m,transition:g,patchFlag:b,dirs:y}=e;if(e.el&&void 0!==_&&-1===b)p=e.el=_(e.el);else{if(p=e.el=a(e.type,c,v&&v.is,v),8&m?u(p,e.children):16&m&&S(e.children,p,null,i,l,c&&"foreignObject"!==h,s,d),y&&li(e,null,i,"created"),v){for(const t in v)"value"===t||xe(t)||r(p,t,null,v[t],c,e.children,i,l,N);"value"in v&&r(p,"value",null,v.value),(f=v.onVnodeBeforeMount)&&Hi(f,i,e)}k(p,e,e.scopeId,s,i)}__VUE_PROD_DEVTOOLS__&&(Object.defineProperty(p,"__vnode",{value:e,enumerable:!1}),Object.defineProperty(p,"__vueParentComponent",{value:i,enumerable:!1})),y&&li(e,null,i,"beforeMount");const w=(!l||l&&!l.pendingBranch)&&g&&!g.persisted;w&&g.beforeEnter(p),o(p,t,n),((f=v&&v.onVnodeMounted)||w||y)&&pi((()=>{f&&Hi(f,i,e),w&&g.enter(p),y&&li(e,null,i,"mounted")}),l)},k=(e,t,n,o,i)=>{if(n&&f(e,n),o)for(let t=0;t<o.length;t++)f(e,o[t]);if(i){if(t===i.subTree){const t=i.vnode;k(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},S=(e,t,n,o,i,r,a,l,c=0)=>{for(let s=c;s<e.length;s++){const c=e[s]=l?Bi(e[s]):Ni(e[s]);v(null,c,t,n,o,i,r,a,l)}},$=(e,t,n,o,i,a,l)=>{const c=t.el=e.el;let{patchFlag:s,dynamicChildren:d,dirs:p}=t;s|=16&e.patchFlag;const f=e.props||Q,_=t.props||Q;let h;n&&_i(n,!1),(h=_.onVnodeBeforeUpdate)&&Hi(h,n,t,e),p&&li(t,e,n,"beforeUpdate"),n&&_i(n,!0);const v=i&&"foreignObject"!==t.type;if(d?C(e.dynamicChildren,d,c,n,o,v,a):l||L(e,t,c,null,n,o,v,a,!1),s>0){if(16&s)O(c,t,f,_,n,o,i);else if(2&s&&f.class!==_.class&&r(c,"class",null,_.class,i),4&s&&r(c,"style",f.style,_.style,i),8&s){const a=t.dynamicProps;for(let t=0;t<a.length;t++){const l=a[t],s=f[l],u=_[l];u===s&&"value"!==l||r(c,l,s,u,i,e.children,n,o,N)}}1&s&&e.children!==t.children&&u(c,t.children)}else l||null!=d||O(c,t,f,_,n,o,i);((h=_.onVnodeUpdated)||p)&&pi((()=>{h&&Hi(h,n,t,e),p&&li(t,e,n,"updated")}),o)},C=(e,t,n,o,i,r,a)=>{for(let l=0;l<t.length;l++){const c=e[l],s=t[l],u=c.el&&(c.type===mi||!Fi(c,s)||70&c.shapeFlag)?d(c.el):n;v(c,s,u,null,o,i,r,a,!0)}},O=(e,t,n,o,i,a,l)=>{if(n!==o){for(const c in o){if(xe(c))continue;const s=o[c],u=n[c];s!==u&&"value"!==c&&r(e,c,u,s,l,t.children,i,a,N)}if(n!==Q)for(const c in n)xe(c)||c in o||r(e,c,n[c],null,l,t.children,i,a,N);"value"in o&&r(e,"value",n.value,o.value)}},T=(e,t,n,i,r,a,c,s,u)=>{const d=t.el=e?e.el:l(""),p=t.anchor=e?e.anchor:l("");let{patchFlag:f,dynamicChildren:_,slotScopeIds:h}=t;h&&(s=s?s.concat(h):h),null==e?(o(d,n,i),o(p,n,i),S(t.children,n,p,r,a,c,s,u)):f>0&&64&f&&_&&e.dynamicChildren?(C(e.dynamicChildren,_,n,r,a,c,s),(null!=t.key||r&&t===r.subTree)&&hi(e,t,!0)):L(e,t,n,p,r,a,c,s,u)},P=(e,t,n,o,i,r,a,l,c)=>{t.slotScopeIds=l,null==e?512&t.shapeFlag?i.ctx.activate(t,n,o,a,c):E(t,n,o,i,r,a,c):F(e,t,c)},E=(e,t,n,o,i,r,a)=>{const l=e.component=Xi(e,o,i);if(mo(e)&&(l.ctx.renderer=H),lr(l),l.asyncDep){if(i&&i.registerDep(l,A),!e.el){const e=l.subTree=Ri(bi);g(null,e,t,n)}}else A(l,e,t,n,i,r,a)},F=(e,t,n)=>{const o=t.component=e.component;if(function(e,t,n){const{props:o,children:i,component:r}=e,{props:a,children:l,patchFlag:c}=t,s=r.emitsOptions;if(t.dirs||t.transition)return!0;if(!(n&&c>=0))return!(!i&&!l||l&&l.$stable)||o!==a&&(o?!a||Kn(o,a,s):!!a);if(1024&c)return!0;if(16&c)return o?Kn(o,a,s):!!a;if(8&c){const e=t.dynamicProps;for(let t=0;t<e.length;t++){const n=e[t];if(a[n]!==o[n]&&!Nn(s,n))return!0}}return!1}(e,t,n)){if(o.asyncDep&&!o.asyncResolved)return void I(o,t,n);o.next=t,function(e){const t=dn.indexOf(e);t>pn&&dn.splice(t,1)}(o.update),o.update()}else t.component=e.component,t.el=e.el,o.vnode=t},A=(e,t,n,o,i,r,a)=>{const l=e.effect=new Je((()=>{if(e.isMounted){let t,{next:n,bu:o,u:l,parent:c,vnode:s}=e,u=n;0,_i(e,!1),n?(n.el=s.el,I(e,n,a)):n=s,o&&Fe(o),(t=n.props&&n.props.onVnodeBeforeUpdate)&&Hi(t,c,n,s),_i(e,!0);const p=Gn(e);0;const f=e.subTree;e.subTree=p,v(f,p,d(f.el),B(f),e,i,r),n.el=p.el,null===u&&Yn(e,p.el),l&&pi(l,i),(t=n.props&&n.props.onVnodeUpdated)&&pi((()=>Hi(t,c,n,s)),i),__VUE_PROD_DEVTOOLS__&&Mn(e)}else{let a;const{el:l,props:c}=t,{bm:s,m:u,parent:d}=e,p=vo(t);if(_i(e,!1),s&&Fe(s),!p&&(a=c&&c.onVnodeBeforeMount)&&Hi(a,d,t),_i(e,!0),l&&G){const n=()=>{e.subTree=Gn(e),G(l,e.subTree,e,i,null)};p?t.type.__asyncLoader().then((()=>!e.isUnmounted&&n())):n()}else{0;const a=e.subTree=Gn(e);0,v(null,a,n,o,e,i,r),t.el=a.el}if(u&&pi(u,i),!p&&(a=c&&c.onVnodeMounted)){const e=t;pi((()=>Hi(a,d,e)),i)}256&t.shapeFlag&&e.a&&pi(e.a,i),e.isMounted=!0,__VUE_PROD_DEVTOOLS__&&Rn(e),t=n=o=null}}),(()=>kn(e.update)),e.scope),c=e.update=l.run.bind(l);c.id=e.uid,_i(e,!0),c()},I=(e,t,n)=>{t.component=e;const o=e.vnode.props;e.vnode=t,e.next=null,function(e,t,n,o){const{props:i,attrs:r,vnode:{patchFlag:a}}=e,l=Zt(i),[c]=e.propsOptions;let s=!1;if(!(o||a>0)||16&a){let o;Zo(e,t,i,r)&&(s=!0);for(const r in l)t&&(se(t,r)||(o=Oe(r))!==r&&se(t,o))||(c?!n||void 0===n[r]&&void 0===n[o]||(i[r]=Ko(c,l,r,void 0,e,!0)):delete i[r]);if(r!==l)for(const e in r)t&&se(t,e)||(delete r[e],s=!0)}else if(8&a){const n=e.vnode.dynamicProps;for(let o=0;o<n.length;o++){let a=n[o];if(Nn(e.emitsOptions,a))continue;const u=t[a];if(c)if(se(r,a))u!==r[a]&&(r[a]=u,s=!0);else{const t=$e(a);i[t]=Ko(c,l,t,u,e,!1)}else u!==r[a]&&(r[a]=u,s=!0)}}s&&nt(e,"set","$attrs")}(e,t.props,o,n),((e,t,n)=>{const{vnode:o,slots:i}=e;let r=!0,a=Q;if(32&o.shapeFlag){const e=t._;e?n&&1===e?r=!1:(ae(i,t),n||1!==e||delete i._):(r=!t.$stable,ri(t,i)),a=t}else t&&(ai(e,t),a={default:1});if(r)for(const e in i)ni(e)||e in a||delete i[e]})(e,t.children,n),Xe(),On(void 0,e.update),Qe()},L=(e,t,n,o,i,r,a,l,c=!1)=>{const s=e&&e.children,d=e?e.shapeFlag:0,p=t.children,{patchFlag:f,shapeFlag:_}=t;if(f>0){if(128&f)return void R(s,p,n,o,i,r,a,l,c);if(256&f)return void j(s,p,n,o,i,r,a,l,c)}8&_?(16&d&&N(s,i,r),p!==s&&u(n,p)):16&d?16&_?R(s,p,n,o,i,r,a,l,c):N(s,i,r,!0):(8&d&&u(n,""),16&_&&S(p,n,o,i,r,a,l,c))},j=(e,t,n,o,i,r,a,l,c)=>{t=t||ee;const s=(e=e||ee).length,u=t.length,d=Math.min(s,u);let p;for(p=0;p<d;p++){const o=t[p]=c?Bi(t[p]):Ni(t[p]);v(e[p],o,n,null,i,r,a,l,c)}s>u?N(e,i,r,!0,!1,d):S(t,n,o,i,r,a,l,c,d)},R=(e,t,n,o,i,r,a,l,c)=>{let s=0;const u=t.length;let d=e.length-1,p=u-1;for(;s<=d&&s<=p;){const o=e[s],u=t[s]=c?Bi(t[s]):Ni(t[s]);if(!Fi(o,u))break;v(o,u,n,null,i,r,a,l,c),s++}for(;s<=d&&s<=p;){const o=e[d],s=t[p]=c?Bi(t[p]):Ni(t[p]);if(!Fi(o,s))break;v(o,s,n,null,i,r,a,l,c),d--,p--}if(s>d){if(s<=p){const e=p+1,d=e<u?t[e].el:o;for(;s<=p;)v(null,t[s]=c?Bi(t[s]):Ni(t[s]),n,d,i,r,a,l,c),s++}}else if(s>p)for(;s<=d;)U(e[s],i,r,!0),s++;else{const f=s,_=s,h=new Map;for(s=_;s<=p;s++){const e=t[s]=c?Bi(t[s]):Ni(t[s]);null!=e.key&&h.set(e.key,s)}let m,g=0;const b=p-_+1;let y=!1,w=0;const x=new Array(b);for(s=0;s<b;s++)x[s]=0;for(s=f;s<=d;s++){const o=e[s];if(g>=b){U(o,i,r,!0);continue}let u;if(null!=o.key)u=h.get(o.key);else for(m=_;m<=p;m++)if(0===x[m-_]&&Fi(o,t[m])){u=m;break}void 0===u?U(o,i,r,!0):(x[u-_]=s+1,u>=w?w=u:y=!0,v(o,t[u],n,null,i,r,a,l,c),g++)}const k=y?function(e){const t=e.slice(),n=[0];let o,i,r,a,l;const c=e.length;for(o=0;o<c;o++){const c=e[o];if(0!==c){if(i=n[n.length-1],e[i]<c){t[o]=i,n.push(o);continue}for(r=0,a=n.length-1;r<a;)l=r+a>>1,e[n[l]]<c?r=l+1:a=l;c<e[n[r]]&&(r>0&&(t[o]=n[r-1]),n[r]=o)}}r=n.length,a=n[r-1];for(;r-- >0;)n[r]=a,a=t[a];return n}(x):ee;for(m=k.length-1,s=b-1;s>=0;s--){const e=_+s,d=t[e],p=e+1<u?t[e+1].el:o;0===x[s]?v(null,d,n,p,i,r,a,l,c):y&&(m<0||s!==k[m]?M(d,n,p,2):m--)}}},M=(e,t,n,i,r=null)=>{const{el:a,type:l,transition:c,children:s,shapeFlag:u}=e;if(6&u)return void M(e.component.subTree,t,n,i);if(128&u)return void e.suspense.move(t,n,i);if(64&u)return void l.move(e,t,n,H);if(l===mi){o(a,t,n);for(let e=0;e<s.length;e++)M(s[e],t,n,i);return void o(e.anchor,t,n)}if(l===yi)return void(({el:e,anchor:t},n,i)=>{let r;for(;e&&e!==t;)r=p(e),o(e,n,i),e=r;o(t,n,i)})(e,t,n);if(2!==i&&1&u&&c)if(0===i)c.beforeEnter(a),o(a,t,n),pi((()=>c.enter(a)),r);else{const{leave:e,delayLeave:i,afterLeave:r}=c,l=()=>o(a,t,n),s=()=>{e(a,(()=>{l(),r&&r()}))};i?i(a,l,s):s()}else o(a,t,n)},U=(e,t,n,o=!1,i=!1)=>{const{type:r,props:a,ref:l,children:c,dynamicChildren:s,shapeFlag:u,patchFlag:d,dirs:p}=e;if(null!=l&&di(l,null,n,e,!0),256&u)return void t.ctx.deactivate(e);const f=1&u&&p,_=!vo(e);let h;if(_&&(h=a&&a.onVnodeBeforeUnmount)&&Hi(h,t,e),6&u)V(e.component,n,o);else{if(128&u)return void e.suspense.unmount(n,o);f&&li(e,null,t,"beforeUnmount"),64&u?e.type.remove(e,t,n,i,H,o):s&&(r!==mi||d>0&&64&d)?N(s,t,n,!1,!0):(r===mi&&384&d||!i&&16&u)&&N(c,t,n),o&&q(e)}(_&&(h=a&&a.onVnodeUnmounted)||f)&&pi((()=>{h&&Hi(h,t,e),f&&li(e,null,t,"unmounted")}),n)},q=e=>{const{type:t,el:n,anchor:o,transition:r}=e;if(t===mi)return void D(n,o);if(t===yi)return void y(e);const a=()=>{i(n),r&&!r.persisted&&r.afterLeave&&r.afterLeave()};if(1&e.shapeFlag&&r&&!r.persisted){const{leave:t,delayLeave:o}=r,i=()=>t(n,a);o?o(e.el,a,i):i()}else a()},D=(e,t)=>{let n;for(;e!==t;)n=p(e),i(e),e=n;i(t)},V=(e,t,n)=>{const{bum:o,scope:i,update:r,subTree:a,um:l}=e;o&&Fe(o),i.stop(),r&&(r.active=!1,U(a,e,t,n)),l&&pi(l,t),pi((()=>{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__&&Un(e)},N=(e,t,n,o=!1,i=!1,r=0)=>{for(let a=r;a<e.length;a++)U(e[a],t,n,o,i)},B=e=>6&e.shapeFlag?B(e.component.subTree):128&e.shapeFlag?e.suspense.next():p(e.anchor||e.el),z=(e,t,n)=>{null==e?t._vnode&&U(t._vnode,null,null,!0):v(t._vnode||null,e,t,null,null,null,n),Tn(),t._vnode=e},H={p:v,um:U,m:M,r:q,mt:E,mc:S,pc:L,pbc:C,n:B,o:e};let W,G;return t&&([W,G]=t(H)),{render:z,hydrate:W,createApp:ui(z,W)}}function _i({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function hi(e,t,n=!1){const o=e.children,i=t.children;if(ue(o)&&ue(i))for(let e=0;e<o.length;e++){const t=o[e];let r=i[e];1&r.shapeFlag&&!r.dynamicChildren&&((r.patchFlag<=0||32===r.patchFlag)&&(r=i[e]=Bi(i[e]),r.el=t.el),n||hi(t,r))}}const vi=Symbol();const mi=Symbol(void 0),gi=Symbol(void 0),bi=Symbol(void 0),yi=Symbol(void 0),wi=[];let xi=null;function ki(e=!1){wi.push(xi=e?null:[])}function Si(){wi.pop(),xi=wi[wi.length-1]||null}let $i=1;function Ci(e){$i+=e}function Oi(e){return e.dynamicChildren=$i>0?xi||ee:null,Si(),$i>0&&xi&&xi.push(e),e}function Ti(e,t,n,o,i,r){return Oi(ji(e,t,n,o,i,r,!0))}function Pi(e,t,n,o,i){return Oi(Ri(e,t,n,o,i,!0))}function Ei(e){return!!e&&!0===e.__v_isVNode}function Fi(e,t){return e.type===t.type&&e.key===t.key}const Ai="__vInternal",Ii=({key:e})=>null!=e?e:null,Li=({ref:e,ref_key:t,ref_for:n})=>null!=e?_e(e)||tn(e)||fe(e)?{i:Bn,r:e,k:t,f:!!n}:e:null;function ji(e,t=null,n=null,o=0,i=null,r=(e===mi?0:1),a=!1,l=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Ii(t),ref:t&&Li(t),scopeId:zn,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:r,patchFlag:o,dynamicProps:i,dynamicChildren:null,appContext:null};return l?(zi(c,n),128&r&&e.normalize(c)):n&&(c.shapeFlag|=_e(n)?8:16),$i>0&&!a&&xi&&(c.patchFlag>0||6&r)&&32!==c.patchFlag&&xi.push(c),c}const Ri=Mi;function Mi(e,t=null,n=null,o=0,i=null,r=!1){if(e&&e!==vi||(e=bi),Ei(e)){const o=Ui(e,t,!0);return n&&zi(o,n),o}if(fr(e)&&(e=e.__vccOpts),t){t=function(e){return e?Jt(e)||Ai in e?ae({},e):e:null}(t);let{class:e,style:n}=t;e&&!_e(e)&&(t.class=Y(e)),ve(n)&&(Jt(n)&&!ue(n)&&(n=ae({},n)),t.style=G(n))}return ji(e,t,n,o,i,_e(e)?1:(e=>e.__isSuspense)(e)?128:(e=>e.__isTeleport)(e)?64:ve(e)?4:fe(e)?2:0,r,!0)}function Ui(e,t,n=!1){const{props:o,ref:i,patchFlag:r,children:a}=e,l=t?function(...e){const t={};for(let n=0;n<e.length;n++){const o=e[n];for(const e in o)if("class"===e)t.class!==o.class&&(t.class=Y([t.class,o.class]));else if("style"===e)t.style=G([t.style,o.style]);else if(ie(e)){const n=t[e],i=o[e];!i||n===i||ue(n)&&n.includes(i)||(t[e]=n?[].concat(n,i):i)}else""!==e&&(t[e]=o[e])}return t}(o||{},t):o;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Ii(l),ref:t&&t.ref?n&&i?ue(i)?i.concat(Li(t)):[i,Li(t)]:Li(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!==mi?-1===r?16:16|r:r,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Ui(e.ssContent),ssFallback:e.ssFallback&&Ui(e.ssFallback),el:e.el,anchor:e.anchor}}function qi(e=" ",t=0){return Ri(gi,null,e,t)}function Di(e,t){const n=Ri(yi,null,e);return n.staticCount=t,n}function Vi(e="",t=!1){return t?(ki(),Pi(bi,null,e)):Ri(bi,null,e)}function Ni(e){return null==e||"boolean"==typeof e?Ri(bi):ue(e)?Ri(mi,null,e.slice()):"object"==typeof e?Bi(e):Ri(gi,null,String(e))}function Bi(e){return null===e.el||e.memo?e:Ui(e)}function zi(e,t){let n=0;const{shapeFlag:o}=e;if(null==t)t=null;else if(ue(t))n=16;else if("object"==typeof t){if(65&o){const n=t.default;return void(n&&(n._c&&(n._d=!1),zi(e,n()),n._c&&(n._d=!0)))}{n=32;const o=t._;o||Ai in t?3===o&&Bn&&(1===Bn.slots._?t._=1:(t._=2,e.patchFlag|=1024)):t._ctx=Bn}}else fe(t)?(t={default:t,_ctx:Bn},n=32):(t=String(t),64&o?(n=16,t=[qi(t)]):n=8);e.children=t,e.shapeFlag|=n}function Hi(e,t,n,o=null){ln(e,t,7,[n,o])}function Wi(e,t,n,o){let i;const r=n&&n[o];if(ue(e)||_e(e)){i=new Array(e.length);for(let n=0,o=e.length;n<o;n++)i[n]=t(e[n],n,void 0,r&&r[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,r&&r[n])}else if(ve(e))if(e[Symbol.iterator])i=Array.from(e,((e,n)=>t(e,n,void 0,r&&r[n])));else{const n=Object.keys(e);i=new Array(n.length);for(let o=0,a=n.length;o<a;o++){const a=n[o];i[o]=t(e[a],a,o,r&&r[o])}}else i=[];return n&&(n[o]=i),i}const Gi=e=>e?or(e)?dr(e)||e.proxy:Gi(e.parent):null,Ji=ae(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=>Gi(e.parent),$root:e=>Gi(e.root),$emit:e=>e.emit,$options:e=>__VUE_OPTIONS_API__?Vo(e):e.type,$forceUpdate:e=>()=>kn(e.update),$nextTick:e=>xn.bind(e.proxy),$watch:e=>__VUE_OPTIONS_API__?oo.bind(e):te}),Zi={get({_:e},t){const{ctx:n,setupState:o,data:i,props:r,accessCache:a,type:l,appContext:c}=e;let s;if("$"!==t[0]){const l=a[t];if(void 0!==l)switch(l){case 1:return o[t];case 2:return i[t];case 4:return n[t];case 3:return r[t]}else{if(o!==Q&&se(o,t))return a[t]=1,o[t];if(i!==Q&&se(i,t))return a[t]=2,i[t];if((s=e.propsOptions[0])&&se(s,t))return a[t]=3,r[t];if(n!==Q&&se(n,t))return a[t]=4,n[t];__VUE_OPTIONS_API__&&!Mo||(a[t]=0)}}const u=Ji[t];let d,p;return u?("$attrs"===t&&et(e,0,t),u(e)):(d=l.__cssModules)&&(d=d[t])?d:n!==Q&&se(n,t)?(a[t]=4,n[t]):(p=c.config.globalProperties,se(p,t)?p[t]:void 0)},set({_:e},t,n){const{data:o,setupState:i,ctx:r}=e;return i!==Q&&se(i,t)?(i[t]=n,!0):o!==Q&&se(o,t)?(o[t]=n,!0):!se(e.props,t)&&(("$"!==t[0]||!(t.slice(1)in e))&&(r[t]=n,!0))},has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:i,propsOptions:r}},a){let l;return!!n[a]||e!==Q&&se(e,a)||t!==Q&&se(t,a)||(l=r[0])&&se(l,a)||se(o,a)||se(Ji,a)||se(i.config.globalProperties,a)},defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:se(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};const Ki=ci();let Yi=0;function Xi(e,t,n){const o=e.type,i=(t?t.appContext:e.appContext)||Ki,r={uid:Yi++,vnode:e,type:o,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,scope:new Me(!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:Yo(o,i),emitsOptions:Vn(o,i),emit:null,emitted:null,propsDefaults:Q,inheritAttrs:o.inheritAttrs,ctx:Q,data:Q,props:Q,attrs:Q,slots:Q,refs:Q,setupState:Q,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 r.ctx={_:r},r.root=t?t.root:r,r.emit=Dn.bind(null,r),e.ce&&e.ce(r),r}let Qi=null;const er=()=>Qi||Bn,tr=e=>{Qi=e,e.scope.on()},nr=()=>{Qi&&Qi.scope.off(),Qi=null};function or(e){return 4&e.vnode.shapeFlag}let ir,rr,ar=!1;function lr(e,t=!1){ar=t;const{props:n,children:o}=e.vnode,i=or(e);Jo(e,n,i,t),((e,t)=>{if(32&e.vnode.shapeFlag){const n=t._;n?(e.slots=Zt(t),Ae(t,"_",n)):ri(t,e.slots={})}else e.slots={},t&&ai(e,t);Ae(e.slots,Ai,1)})(e,o);const r=i?function(e,t){const n=e.type;0;e.accessCache=Object.create(null),e.proxy=Kt(new Proxy(e.ctx,Zi)),!1;const{setup:o}=n;if(o){const n=e.setupContext=o.length>1?ur(e):null;tr(e),Xe();const i=an(o,e,0,[e.props,n]);if(Qe(),nr(),me(i)){if(i.then(nr,nr),t)return i.then((n=>{cr(e,n,t)})).catch((t=>{cn(t,e,0)}));e.asyncDep=i}else cr(e,i,t)}else sr(e,t)}(e,t):void 0;return ar=!1,r}function cr(e,t,n){fe(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ve(t)&&(__VUE_PROD_DEVTOOLS__&&(e.devtoolsRawSetupState=t),e.setupState=on(t)),sr(e,n)}function sr(e,t,n){const o=e.type;if(!e.render){if(!t&&ir&&!o.render){const t=o.template;if(t){0;const{isCustomElement:n,compilerOptions:i}=e.appContext.config,{delimiters:r,compilerOptions:a}=o,l=ae(ae({isCustomElement:n,delimiters:r},i),a);o.render=ir(t,l)}}e.render=o.render||te,rr&&rr(e)}__VUE_OPTIONS_API__&&(tr(e),Xe(),Uo(e),Qe(),nr())}function ur(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)=>(et(e,0,"$attrs"),t[n])})}(e))},slots:e.slots,emit:e.emit,expose:t}}function dr(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(on(Kt(e.exposed)),{get:(t,n)=>n in t?t[n]:n in Ji?Ji[n](e):void 0}))}function pr(e){return fe(e)&&e.displayName||e.name}function fr(e){return fe(e)&&"__vccOpts"in e}const _r=(e,t)=>function(e,t,n=!1){let o,i;const r=fe(e);return r?(o=e,i=te):(o=e.get,i=e.set),new rn(o,i,r||!i,n)}(e,0,ar);Symbol("");const hr="3.2.33",vr="undefined"!=typeof document?document:null,mr=vr&&vr.createElement("template"),gr={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,o)=>{const i=t?vr.createElementNS("http://www.w3.org/2000/svg",e):vr.createElement(e,n?{is:n}:void 0);return"select"===e&&o&&null!=o.multiple&&i.setAttribute("multiple",o.multiple),i},createText:e=>vr.createTextNode(e),createComment:e=>vr.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>vr.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,o,i,r){const a=n?n.previousSibling:t.lastChild;if(i&&(i===r||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),i!==r&&(i=i.nextSibling););else{mr.innerHTML=o?`<svg>${e}</svg>`:e;const i=mr.content;if(o){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 br=/\s*!important$/;function yr(e,t,n){if(ue(n))n.forEach((n=>yr(e,t,n)));else if(null==n&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const o=function(e,t){const n=xr[t];if(n)return n;let o=$e(t);if("filter"!==o&&o in e)return xr[t]=o;o=Te(o);for(let n=0;n<wr.length;n++){const i=wr[n]+o;if(i in e)return xr[t]=i}return t}(e,t);br.test(n)?e.setProperty(Oe(o),n.replace(br,""),"important"):e[o]=n}}const wr=["Webkit","Moz","ms"],xr={};const kr="http://www.w3.org/1999/xlink";const[Sr,$r]=(()=>{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 Cr=0;const Or=Promise.resolve(),Tr=()=>{Cr=0};function Pr(e,t,n,o){e.addEventListener(t,n,o)}function Er(e,t,n,o,i=null){const r=e._vei||(e._vei={}),a=r[t];if(o&&a)a.value=o;else{const[n,l]=function(e){let t;if(Fr.test(e)){let n;for(t={};n=e.match(Fr);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[Oe(e.slice(2)),t]}(t);if(o){const a=r[t]=function(e,t){const n=e=>{const o=e.timeStamp||Sr();($r||o>=n.attached-1)&&ln(function(e,t){if(ue(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=(()=>Cr||(Or.then(Tr),Cr=Sr()))(),n}(o,i);Pr(e,n,a,l)}else a&&(!function(e,t,n,o){e.removeEventListener(t,n,o)}(e,n,a,l),r[t]=void 0)}}const Fr=/(?:Once|Passive|Capture)$/;const Ar=/^on[a-z]/;"undefined"!=typeof HTMLElement&&HTMLElement;const Ir="transition",Lr="animation",jr=(e,{slots:t})=>function(e,t,n){const o=arguments.length;return 2===o?ve(t)&&!ue(t)?Ei(t)?Ri(e,null,[t]):Ri(e,t):Ri(e,null,t):(o>3?n=Array.prototype.slice.call(arguments,2):3===o&&Ei(n)&&(n=[n]),Ri(e,t,n))}(co,qr(e),t);jr.displayName="Transition";const Rr={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},Mr=(jr.props=ae({},co.props,Rr),(e,t=[])=>{ue(e)?e.forEach((e=>e(...t))):e&&e(...t)}),Ur=e=>!!e&&(ue(e)?e.some((e=>e.length>1)):e.length>1);function qr(e){const t={};for(const n in e)n in Rr||(t[n]=e[n]);if(!1===e.css)return t;const{name:n="v",type:o,duration:i,enterFromClass:r=`${n}-enter-from`,enterActiveClass:a=`${n}-enter-active`,enterToClass:l=`${n}-enter-to`,appearFromClass:c=r,appearActiveClass:s=a,appearToClass:u=l,leaveFromClass:d=`${n}-leave-from`,leaveActiveClass:p=`${n}-leave-active`,leaveToClass:f=`${n}-leave-to`}=e,_=function(e){if(null==e)return null;if(ve(e))return[Dr(e.enter),Dr(e.leave)];{const t=Dr(e);return[t,t]}}(i),h=_&&_[0],v=_&&_[1],{onBeforeEnter:m,onEnter:g,onEnterCancelled:b,onLeave:y,onLeaveCancelled:w,onBeforeAppear:x=m,onAppear:k=g,onAppearCancelled:S=b}=t,$=(e,t,n)=>{Nr(e,t?u:l),Nr(e,t?s:a),n&&n()},C=(e,t)=>{Nr(e,f),Nr(e,p),t&&t()},O=e=>(t,n)=>{const i=e?k:g,a=()=>$(t,e,n);Mr(i,[t,a]),Br((()=>{Nr(t,e?c:r),Vr(t,e?u:l),Ur(i)||Hr(t,o,h,a)}))};return ae(t,{onBeforeEnter(e){Mr(m,[e]),Vr(e,r),Vr(e,a)},onBeforeAppear(e){Mr(x,[e]),Vr(e,c),Vr(e,s)},onEnter:O(!1),onAppear:O(!0),onLeave(e,t){const n=()=>C(e,t);Vr(e,d),Zr(),Vr(e,p),Br((()=>{Nr(e,d),Vr(e,f),Ur(y)||Hr(e,o,v,n)})),Mr(y,[e,n])},onEnterCancelled(e){$(e,!1),Mr(b,[e])},onAppearCancelled(e){$(e,!0),Mr(S,[e])},onLeaveCancelled(e){C(e),Mr(w,[e])}})}function Dr(e){return Ie(e)}function Vr(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.add(t))),(e._vtc||(e._vtc=new Set)).add(t)}function Nr(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 Br(e){requestAnimationFrame((()=>{requestAnimationFrame(e)}))}let zr=0;function Hr(e,t,n,o){const i=e._endId=++zr,r=()=>{i===e._endId&&o()};if(n)return setTimeout(r,n);const{type:a,timeout:l,propCount:c}=Wr(e,t);if(!a)return o();const s=a+"end";let u=0;const d=()=>{e.removeEventListener(s,p),r()},p=t=>{t.target===e&&++u>=c&&d()};setTimeout((()=>{u<c&&d()}),l+1),e.addEventListener(s,p)}function Wr(e,t){const n=window.getComputedStyle(e),o=e=>(n[e]||"").split(", "),i=o("transitionDelay"),r=o("transitionDuration"),a=Gr(i,r),l=o("animationDelay"),c=o("animationDuration"),s=Gr(l,c);let u=null,d=0,p=0;t===Ir?a>0&&(u=Ir,d=a,p=r.length):t===Lr?s>0&&(u=Lr,d=s,p=c.length):(d=Math.max(a,s),u=d>0?a>s?Ir:Lr:null,p=u?u===Ir?r.length:c.length:0);return{type:u,timeout:d,propCount:p,hasTransform:u===Ir&&/\b(transform|all)(,|$)/.test(n.transitionProperty)}}function Gr(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map(((t,n)=>Jr(t)+Jr(e[n]))))}function Jr(e){return 1e3*Number(e.slice(0,-1).replace(",","."))}function Zr(){return document.body.offsetHeight}new WeakMap,new WeakMap;const Kr=ae({patchProp:(e,t,n,o,i=!1,r,a,l,c)=>{"class"===t?function(e,t,n){const o=e._vtc;o&&(t=(t?[t,...o]:[...o]).join(" ")),null==t?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}(e,o,i):"style"===t?function(e,t,n){const o=e.style,i=_e(n);if(n&&!i){for(const e in n)yr(o,e,n[e]);if(t&&!_e(t))for(const e in t)null==n[e]&&yr(o,e,"")}else{const r=o.display;i?t!==n&&(o.cssText=n):t&&e.removeAttribute("style"),"_vod"in e&&(o.display=r)}}(e,n,o):ie(t)?re(t)||Er(e,t,0,o,a):("."===t[0]?(t=t.slice(1),1):"^"===t[0]?(t=t.slice(1),0):function(e,t,n,o){if(o)return"innerHTML"===t||"textContent"===t||!!(t in e&&Ar.test(t)&&fe(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(Ar.test(t)&&_e(n))return!1;return t in e}(e,t,o,i))?function(e,t,n,o,i,r,a){if("innerHTML"===t||"textContent"===t)return o&&a(o,i,r),void(e[t]=null==n?"":n);if("value"===t&&"PROGRESS"!==e.tagName&&!e.tagName.includes("-")){e._value=n;const o=null==n?"":n;return e.value===o&&"OPTION"!==e.tagName||(e.value=o),void(null==n&&e.removeAttribute(t))}let l=!1;if(""===n||null==n){const o=typeof e[t];"boolean"===o?n=W(n):null==n&&"string"===o?(n="",l=!0):"number"===o&&(n=0,l=!0)}try{e[t]=n}catch(e){}l&&e.removeAttribute(t)}(e,t,o,r,a,l,c):("true-value"===t?e._trueValue=o:"false-value"===t&&(e._falseValue=o),function(e,t,n,o,i){if(o&&t.startsWith("xlink:"))null==n?e.removeAttributeNS(kr,t.slice(6,t.length)):e.setAttributeNS(kr,t,n);else{const o=H(t);null==n||o&&!W(n)?e.removeAttribute(t):e.setAttribute(t,o?"":n)}}(e,t,o,i))}},gr);let Yr;function Xr(){return Yr||(Yr=function(e){return fi(e)}(Kr))}function Qr(e){if(_e(e)){return document.querySelector(e)}return e}var ea=function(e){return zn="data-v-6a48ed2c",e=e(),zn=null,e},ta={id:"bp_config"},na={class:"bp_config_bg"},oa={style:{"font-size":"20px"}},ia=ea((function(){return ji("b",null,"bilibili视频下载 参数设置",-1)})),ra={style:{margin:"2% 0"}},aa=ea((function(){return ji("label",null,"请求地址:",-1)})),la=["value"],ca=qi(" "),sa=ea((function(){return ji("label",null,"请求方式:",-1)})),ua=["value"],da=[ea((function(){return ji("option",{value:"auto"},"自动判断",-1)})),ea((function(){return ji("option",{value:"local"},"本地请求",-1)})),ea((function(){return ji("option",{value:"online"},"远程请求",-1)}))],pa=ea((function(){return ji("br",null,null,-1)})),fa=ea((function(){return ji("small",null,"注意:普通使用请勿修改;默认使用混合请求",-1)})),_a={style:{margin:"2% 0"}},ha=ea((function(){return ji("label",null,"视频格式:",-1)})),va=["value"],ma=[ea((function(){return ji("option",{value:"flv"},"FLV",-1)})),ea((function(){return ji("option",{value:"dash"},"DASH",-1)})),ea((function(){return ji("option",{value:"mp4"},"MP4",-1)}))],ga=qi(" "),ba=ea((function(){return ji("label",null,"切换CDN:",-1)})),ya=["value"],wa=["value"],xa=ea((function(){return ji("br",null,null,-1)})),ka=ea((function(){return ji("small",null,"注意:仅video支持MP4;建议特殊地区或网络受限时切换(自行选择合适线路)",-1)})),Sa={style:{margin:"2% 0"}},$a=ea((function(){return ji("label",null,"下载方式:",-1)})),Ca=["value"],Oa=[Di('<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)],Ta=qi(" "),Pa=ea((function(){return ji("label",null,"AriaNg地址:",-1)})),Ea=["value"],Fa=ea((function(){return ji("br",null,null,-1)})),Aa=ea((function(){return ji("small",null,"提示:url和web方式不会设置文件名",-1)})),Ia={style:{margin:"2% 0"}},La=ea((function(){return ji("label",null,"RPC配置:[ 域名 : 端口 | 密钥 | 保存目录 ]",-1)})),ja=ea((function(){return ji("br",null,null,-1)})),Ra=["value"],Ma=qi(" : "),Ua=["value"],qa=qi(" | "),Da=["value"],Va=qi(" | "),Na=["value"],Ba=ea((function(){return ji("br",null,null,-1)})),za=ea((function(){return ji("small",null,"注意:RPC默认使用Motrix(需要安装并运行)下载,其他软件请修改参数",-1)})),Ha={style:{margin:"2% 0"}},Wa=ea((function(){return ji("label",null,"强制换源:",-1)})),Ga=["value"],Ja=[ea((function(){return ji("option",{value:"0"},"关闭",-1)})),ea((function(){return ji("option",{value:"1"},"开启",-1)}))],Za=qi(" "),Ka=ea((function(){return ji("label",null,"弹幕速度:",-1)})),Ya=["value"],Xa=qi(" s "),Qa=ea((function(){return ji("label",null,"弹幕字号:",-1)})),el=["value"],tl=qi(" px "),nl=ea((function(){return ji("br",null,null,-1)})),ol=ea((function(){return ji("small",null,"说明:使用请求到的视频地址在DPlayer进行播放;弹幕速度为弹幕滑过DPlayer的时间",-1)})),il={style:{margin:"2% 0"}},rl=ea((function(){return ji("label",null,"自动下载:",-1)})),al=["value"],ll=[ea((function(){return ji("option",{value:"0"},"关闭",-1)})),ea((function(){return ji("option",{value:"1"},"开启",-1)}))],cl=ea((function(){return ji("br",null,null,-1)})),sl=ea((function(){return ji("small",null,"说明:请求地址成功后将自动点击下载视频按钮",-1)})),ul={style:{margin:"2% 0"}},dl=ea((function(){return ji("label",null,"授权状态:",-1)})),pl=ea((function(){return ji("select",{id:"auth",value:"{{config.auth}}",disabled:""},[ji("option",{value:"0"},"未授权"),ji("option",{value:"1"},"已授权")],-1)})),fl={style:{"text-align":"right"}},_l=ea((function(){return ji("br",null,null,-1)}));var hl=__webpack_require__(44),vl=hl.config,ml=hl.hostMap,gl=Object.assign({},vl),bl={data:function(){var e=[];for(var t in ml)e.push({text:ml[t],value:t});return{config:vl,host_key_options:e,help_clicked:!1}},methods:{save_config:function(){var e=JSON.parse(n.get("config_str"));n.set("config_str",JSON.stringify(vl)),$("#bp_config").hide(),$("#bp_config").css("opacity",0),j.A.show();for(var t=0,i=["base_api","format","auth"];t<i.length;t++){var r=i[t];if(vl[r]!==e[r]){$("#video_download").hide(),$("#video_download_2").hide();break}}vl.host_key!==e.host_key&&(N.refresh(),$("#video_url").attr("href","#"),$("#video_url_2").attr("href","#")),vl.rpc_domain!==e.rpc_domain&&(vl.rpc_domain.match("https://")||vl.rpc_domain.match(/(localhost|127\.0\.0\.1)/)||o._p.alert("检测到当前RPC不是localhost本地接口,即将跳转到AriaNg网页控制台页面;请查看控制台RPC接口参数是否正确,第一次加载可能较慢请耐心等待;配置好后即可使用脚本进行远程下载<br/>使用期间不用关闭控制台页面!",(function(){L.open_ariang({domain:vl.rpc_domain,port:vl.rpc_port,token:vl.rpc_token})})));for(var a=0,l=["danmaku_speed","danmaku_fontsize"];a<l.length;a++){var c=l[a];if(vl[c]!==e[c]){g.danmaku.config();break}}},reset_config:function(){for(var e in gl)"auth"!==e&&(this.config[e]=gl[e])},show_help:function(){var e=this;this.help_clicked?o.v0.miaow():(this.help_clicked=!0,(0,i.h)({url:"".concat(vl.base_api,"/auth/v2/?act=help"),dataType:"text"}).then((function(e){e?o._p.alert(e):o.v0.warning("获取失败")})).finally((function(){return e.help_clicked=!1})))},show_login:function(e){D.login(e)},show_logout:function(){D.logout()},show_login_help:function(){o._p.confirm("进行授权之后将能在远程请求时享有用户账号原有的权益,例如能够请求用户已经付费或承包的番剧,是否需要授权?",(function(){D.login()}))}},created:function(){var e=n.get("config_str")||localStorage.getItem("my_config_str");if(e){var t=JSON.parse(e);for(var o in t)Object.hasOwnProperty.call(vl,o)&&(vl[o]=t[o])}else n.set("config_str",JSON.stringify(vl)),localStorage.setItem("my_config_str","");window.onbeforeunload=function(){var e=window.bp_aria2_window;e&&!e.closed&&e.close()}}},yl=__webpack_require__(379),wl=__webpack_require__.n(yl),xl=__webpack_require__(795),kl=__webpack_require__.n(xl),Sl=__webpack_require__(569),$l=__webpack_require__.n(Sl),Cl=__webpack_require__(565),Ol=__webpack_require__.n(Cl),Tl=__webpack_require__(216),Pl=__webpack_require__.n(Tl),El=__webpack_require__(589),Fl=__webpack_require__.n(El),Al=__webpack_require__(271),Il={};Il.styleTagTransform=Fl(),Il.setAttributes=Ol(),Il.insert=$l().bind(null,"head"),Il.domAPI=kl(),Il.insertStyleElement=Pl();wl()(Al.Z,Il),Al.Z&&Al.Z.locals&&Al.Z.locals;var Ll=(0,__webpack_require__(744).Z)(bl,[["render",function(e,t,n,o,i,r){return ki(),Ti("div",ta,[ji("div",na,[ji("span",oa,[ia,ji("b",null,[ji("a",{href:"javascript:;",onClick:t[0]||(t[0]=function(e){return r.reset_config()})}," [重置] "),ji("a",{style:{"text-decoration":"underline"},href:"javascript:;",onClick:t[1]||(t[1]=function(e){return r.show_help()})},"<通知/帮助>")])]),ji("div",ra,[aa,ji("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,la),ca,sa,ji("select",{value:i.config.request_type,onInput:t[3]||(t[3]=function(e){return i.config.request_type=e.target.value})},da,40,ua),pa,fa]),ji("div",_a,[ha,ji("select",{value:i.config.format,onInput:t[4]||(t[4]=function(e){return i.config.format=e.target.value})},ma,40,va),ga,ba,ji("select",{value:i.config.host_key,onInput:t[5]||(t[5]=function(e){return i.config.host_key=e.target.value})},[(ki(!0),Ti(mi,null,Wi(i.host_key_options,(function(e){return ki(),Ti("option",{value:e.value,key:e.text},(t=e.text,_e(t)?t:null==t?"":ue(t)||ve(t)&&(t.toString===ge||!fe(t.toString))?JSON.stringify(t,X,2):String(t)),9,wa);var t})),128))],40,ya),xa,ka]),ji("div",Sa,[$a,ji("select",{value:i.config.download_type,onInput:t[6]||(t[6]=function(e){return i.config.download_type=e.target.value})},Oa,40,Ca),Ta,Pa,ji("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,Ea),Fa,Aa]),ji("div",Ia,[La,ja,ji("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,Ra),Ma,ji("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,Ua),qa,ji("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,Da),Va,ji("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,Na),Ba,za]),ji("div",Ha,[Wa,ji("select",{value:i.config.replace_force,onInput:t[12]||(t[12]=function(e){return i.config.replace_force=e.target.value})},Ja,40,Ga),Za,Ka,ji("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,Ya),Xa,Qa,ji("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,el),tl,nl,ol]),ji("div",il,[rl,ji("select",{value:i.config.auto_download,onInput:t[15]||(t[15]=function(e){return i.config.auto_download=e.target.value})},ll,40,al),cl,sl]),ji("div",ul,[dl,Vi('-id="auth"-'),pl,ji("a",{class:"setting-context",href:"javascript:;",onClick:t[16]||(t[16]=function(e){return r.show_login()})},"账号授权"),ji("a",{class:"setting-context",href:"javascript:;",onClick:t[17]||(t[17]=function(e){return r.show_logout()})},"取消授权"),ji("a",{class:"setting-context",href:"javascript:;",onClick:t[18]||(t[18]=function(e){return r.show_login("0")})},"手动授权"),ji("a",{class:"setting-context",href:"javascript:;",onClick:t[19]||(t[19]=function(e){return r.show_login_help()})},"这是什么?")]),ji("div",fl,[_l,ji("button",{class:"setting-button",onClick:t[20]||(t[20]=function(e){return r.save_config()})},"确定")])])])}],["__scopeId","data-v-6a48ed2c"]]);function jl(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}var Rl=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 i,r,a;return i=t,r=[{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;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 i,r,a,c=document.getElementById(t.id);(i=document.createElement("div")).id="root_config",c.append(i),((...e)=>{const t=Xr().createApp(...e),{mount:n}=t;return t.mount=e=>{const o=Qr(e);if(!o)return;const i=t._component;fe(i)||i.render||i.template||(i.template=o.innerHTML),o.innerHTML="";const r=n(o,!1,o instanceof SVGElement);return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),r},t})(Ll).mount("#".concat(i.id)),(0,o.N5)(),M.lazyInit(),D.initAuth(),D.checkLoginStatus(),N.refresh(),$("#".concat(t.id)).append('<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/DPlayer.min.css"><\/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 M.lazyInit(!0),e.config)$("#".concat(t)).val(e.config[t]);$("#bp_config").show(),$("#bp_config").animate({opacity:"1"},300),j.A.hide()})),$("body").on("click","#download_danmaku",(function(){var e=l.base();L.download_danmaku_ass(e.cid(),e.filename())})),$("body").on("click","#download_subtitle",(function(){L.download_subtitle_vtt(0,l.base().filename())})),$("body").on("click","#video_download_all",(function(){M.lazyInit(!0),n.get("auth_id")&&n.get("auth_sec")?"rpc"===e.config.download_type?L.download_all():o._p.confirm("仅支持使用RPC接口批量下载,请确保RPC环境正常,是否继续?",(function(){L.download_all()})):o._p.confirm("批量下载仅支持授权用户使用RPC接口下载,是否进行授权?",(function(){D.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")],i=n[1],r="建议使用IDM、FDM等软件安装其浏览器插件后,鼠标右键点击链接下载~<br/><br/>"+'<a href="'.concat(n[0],'" target="_blank" style="text-decoration:underline;">>视频地址<</a><br/><br/>')+("dash"===e.config.format?'<a href="'.concat(i,'" target="_blank" style="text-decoration:underline;">>音频地址<</a>'):"");o._p.alert(r)}else if("aria"===t){var a,c,s=[$("#video_url").attr("href"),$("#video_url_2").attr("href")],u=s[0],d=s[1],p=l.base().filename();a=p+L.url_format(u),c=p+"_audio.mp4";var f='--header "User-Agent: '.concat(window.navigator.userAgent,'" --header "Referer: ').concat(window.location.href,'"'),_='aria2c "'.concat(u,'" --out "').concat(a,'" ').concat(f),h='aria2c "'.concat(d,'" --out "').concat(c,'" ').concat(f),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(h,'\' 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(h,"</textarea>"):"");!window.bp_clip_btn&&(window.bp_clip_btn=function(e){$("#".concat(e)).select(),document.execCommand("copy")?o.v0.success("复制成功"):o.v0.warning("复制失败")}),o._p.alert(v)}else{var m=$("#video_url").attr("href"),g=l.base().filename();L.download(m,g,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"),o=l.base().filename();L.download(n,o,t)}})),$("body").on("click","#bilibili_parse",(function(){M.lazyInit(!0);var t=l.base(),i=[t.type,t.aid(),t.p(),t.cid(),t.epid()],c=i[0],s=i[1],u=i[2],d=i[3],f=i[4],_=l.get_quality().q;r="".concat(e.config.base_api,"?av=").concat(s,"&p=").concat(u,"&cid=").concat(d,"&ep=").concat(f,"&q=").concat(_,"&type=").concat(c,"&format=").concat(e.config.format,"&otype=json&_host=").concat(e.config.host_key,"&_req=").concat(e.config.request_type);var h=[n.get("auth_id"),n.get("auth_sec")],v=h[0],m=h[1];if("1"===e.config.auth&&v&&m&&(r+="&auth_id=".concat(v,"&auth_sec=").concat(m)),r!==a||"local"===e.config.request_type)$("#video_url").attr("href","#"),$("#video_url_2").attr("href","#"),a=r,o.v0.info("开始请求"),p.get_url((function(n){if(n&&!n.code){o.v0.success("请求成功"),n.times&&o.v0.info("剩余请求次数:".concat(n.times));var i="dash"===e.config.format?n.video.replace("http://","https://"):n.url.replace("http://","https://"),r="dash"===e.config.format?n.audio.replace("http://","https://"):"#";$("#video_url").attr("href",i),$("#video_download").show(),"dash"===e.config.format&&($("#video_url_2").attr("href",r),$("#video_download_2").show()),(M.needReplace()||t.is_limited()||"1"===e.config.replace_force)&&g.replace_player(i,r),"1"===e.config.auto_download&&$("#video_download").click()}}));else{o.v0.miaow();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(),(M.needReplace()||t.is_limited()||"1"===e.config.replace_force)&&!$("#bp_dplayer")[0]&&g.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]&&N.refresh()})),$("body").on("click","li.ep-item",(function(){N.refresh()})),$("body").on("click","button.bilibili-player-iconfont-next",(function(){N.refresh()}));var s=g.bili_video_tag();$(s)[0]&&($(s)[0].onended=function(){N.refresh()}),$("body").on("click","li.bui-select-item",(function(){N.refresh()})),setInterval((function(){(N.q!==l.get_quality().q||"cheese"===l.type()&&N.epid!==l.base().epid())&&N.refresh()}),1e3),$("body").on("click",".rec-list",(function(){N.refresh()})),$("body").on("click",".bilibili-player-ending-panel-box-videos",(function(){N.refresh()})),setInterval((function(){var e=l.base();N.aid===e.aid()&&N.cid===e.cid()||N.refresh()}),3e3)}}],r&&jl(i.prototype,r),a&&jl(i,a),Object.defineProperty(i,"prototype",{writable:!1}),t}(),Ml=Rl;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.2"," ").concat("0331855"," %c https://github.com/injahow/user.js ","\n","\n"),"color: #fadfa3; background: #030307; padding:5px 0;","background: #fadfa3; padding:5px 0;"),(new Ml).run()}),2e3):location.href.match("access_key")&&window!==window.parent&&(window.stop(),window.parent.postMessage("bilibili-parse-login-credentials: "+location.href,"*")))}()})();