From 2b8ebe47f10d9040c8549ca8375c8d0b173a33a5 Mon Sep 17 00:00:00 2001 From: the1812 Date: Sat, 30 Oct 2021 07:33:01 +0000 Subject: [PATCH] CI build --- dist/bilibili-evolved.preview.user.js | 6 +++--- dist/bilibili-evolved.user.js | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/dist/bilibili-evolved.preview.user.js b/dist/bilibili-evolved.preview.user.js index 58aade2c7..0039fc92e 100644 --- a/dist/bilibili-evolved.preview.user.js +++ b/dist/bilibili-evolved.preview.user.js @@ -47,11 +47,11 @@ e.__proto__=t}(e,ke):function(e,t,n){for(var i=0,a=n.length;i-1)if(r&&!x(a,"default"))o=!1;else if(""===o||o===M(e)){var l=Re(String,a.type);(l<0||s0&&(ft((i=mt(i,(t||"")+"_"+n))[0])&&ft(c)&&(d[l]=we(c.text+i[0].text),i.shift()),d.push.apply(d,i)):s(i)?ft(c)?d[l]=we(c.text+i):""!==i&&d.push(we(i)):ft(i)&&ft(c)?d[l]=we(c.text+i.text):(o(e._isVList)&&r(i.tag)&&a(i.key)&&r(t)&&(i.key="__vlist"+t+"_"+n+"__"),d.push(i)));return d}function gt(e,t){if(e){for(var n=Object.create(null),i=de?Reflect.ownKeys(e):Object.keys(e),a=0;a0,o=e?!!e.$stable:!r,s=e&&e.$key;if(e){if(e._normalized)return e._normalized;if(o&&n&&n!==i&&s===n.$key&&!r&&!n.$hasNormal)return n;for(var l in a={},e)e[l]&&"$"!==l[0]&&(a[l]=wt(t,l,e[l]))}else a={};for(var c in t)c in a||(a[c]=xt(t,c));return e&&Object.isExtensible(e)&&(e._normalized=a),R(a,"$stable",o),R(a,"$key",s),R(a,"$hasNormal",r),a}function wt(e,t,n){var i=function(){var e=arguments.length?n.apply(null,arguments):n({});return(e=e&&"object"==typeof e&&!Array.isArray(e)?[e]:ht(e))&&(0===e.length||1===e.length&&e[0].isComment)?void 0:e};return n.proxy&&Object.defineProperty(e,t,{get:i,enumerable:!0,configurable:!0}),i}function xt(e,t){return function(){return e[t]}}function _t(e,t){var n,i,a,o,s;if(Array.isArray(e)||"string"==typeof e)for(n=new Array(e.length),i=0,a=e.length;idocument.createEvent("Event").timeStamp&&(mn=function(){return gn.now()})}function vn(){var e,t;for(fn=mn(),pn=!0,ln.sort((function(e,t){return e.id-t.id})),hn=0;hnhn&&ln[n].id>e.id;)n--;ln.splice(n+1,0,e)}else ln.push(e);un||(un=!0,at(vn))}}(this)},yn.prototype.run=function(){if(this.active){var e=this.get();if(e!==this.value||l(e)||this.deep){var t=this.value;if(this.value=e,this.user)try{this.cb.call(this.vm,e,t)}catch(e){Ue(e,this.vm,'callback for watcher "'+this.expression+'"')}else this.cb.call(this.vm,e,t)}}},yn.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},yn.prototype.depend=function(){for(var e=this.deps.length;e--;)this.deps[e].depend()},yn.prototype.teardown=function(){if(this.active){this.vm._isBeingDestroyed||y(this.vm._watchers,this);for(var e=this.deps.length;e--;)this.deps[e].removeSub(this);this.active=!1}};var wn={enumerable:!0,configurable:!0,get:I,set:I};function xn(e,t,n){wn.get=function(){return this[t][n]},wn.set=function(e){this[t][n]=e},Object.defineProperty(e,n,wn)}function _n(e){e._watchers=[];var t=e.$options;t.props&&function(e,t){var n=e.$options.propsData||{},i=e._props={},a=e.$options._propKeys=[];e.$parent&&Ee(!1);var r=function(r){a.push(r);var o=je(r,t,n,e);Ae(i,r,o),r in e||xn(e,"_props",r)};for(var o in t)r(o);Ee(!0)}(e,t.props),t.methods&&function(e,t){e.$options.props;for(var n in t)e[n]="function"!=typeof t[n]?I:z(t[n],e)}(e,t.methods),t.data?function(e){var t=e.$options.data;d(t=e._data="function"==typeof t?function(e,t){me();try{return e.call(t,t)}catch(e){return Ue(e,t,"data()"),{}}finally{ge()}}(t,e):t||{})||(t={});var n=Object.keys(t),i=e.$options.props,a=(e.$options.methods,n.length);for(;a--;){var r=n[a];0,i&&x(i,r)||H(r)||xn(e,"_data",r)}ze(t,!0)}(e):ze(e._data={},!0),t.computed&&function(e,t){var n=e._computedWatchers=Object.create(null),i=oe();for(var a in t){var r=t[a],o="function"==typeof r?r:r.get;0,i||(n[a]=new yn(e,o||I,I,kn)),a in e||Cn(e,a,r)}}(e,t.computed),t.watch&&t.watch!==ie&&function(e,t){for(var n in t){var i=t[n];if(Array.isArray(i))for(var a=0;a-1:"string"==typeof e?e.split(",").indexOf(t)>-1:!!u(e)&&e.test(t)}function Tn(e,t){var n=e.cache,i=e.keys,a=e._vnode;for(var r in n){var o=n[r];if(o){var s=In(o.componentOptions);s&&!t(s)&&Pn(n,r,i,a)}}}function Pn(e,t,n,i){var a=e[t];!a||i&&a.tag===i.tag||a.componentInstance.$destroy(),e[t]=null,y(n,t)}!function(e){e.prototype._init=function(e){var t=this;t._uid=zn++,t._isVue=!0,e&&e._isComponent?function(e,t){var n=e.$options=Object.create(e.constructor.options),i=t._parentVnode;n.parent=t.parent,n._parentVnode=i;var a=i.componentOptions;n.propsData=a.propsData,n._parentListeners=a.listeners,n._renderChildren=a.children,n._componentTag=a.tag,t.render&&(n.render=t.render,n.staticRenderFns=t.staticRenderFns)}(t,e):t.$options=Fe(An(t.constructor),e||{},t),t._renderProxy=t,t._self=t,function(e){var t=e.$options,n=t.parent;if(n&&!t.abstract){for(;n.$options.abstract&&n.$parent;)n=n.$parent;n.$children.push(e)}e.$parent=n,e.$root=n?n.$root:e,e.$children=[],e.$refs={},e._watcher=null,e._inactive=null,e._directInactive=!1,e._isMounted=!1,e._isDestroyed=!1,e._isBeingDestroyed=!1}(t),function(e){e._events=Object.create(null),e._hasHookEvent=!1;var t=e.$options._parentListeners;t&&en(e,t)}(t),function(e){e._vnode=null,e._staticTrees=null;var t=e.$options,n=e.$vnode=t._parentVnode,a=n&&n.context;e.$slots=vt(t._renderChildren,a),e.$scopedSlots=i,e._c=function(t,n,i,a){return Rt(e,t,n,i,a,!1)},e.$createElement=function(t,n,i,a){return Rt(e,t,n,i,a,!0)};var r=n&&n.data;Ae(e,"$attrs",r&&r.attrs||i,null,!0),Ae(e,"$listeners",t._parentListeners||i,null,!0)}(t),sn(t,"beforeCreate"),function(e){var t=gt(e.$options.inject,e);t&&(Ee(!1),Object.keys(t).forEach((function(n){Ae(e,n,t[n])})),Ee(!0))}(t),_n(t),function(e){var t=e.$options.provide;t&&(e._provided="function"==typeof t?t.call(e):t)}(t),sn(t,"created"),t.$options.el&&t.$mount(t.$options.el)}}($n),function(e){var t={get:function(){return this._data}},n={get:function(){return this._props}};Object.defineProperty(e.prototype,"$data",t),Object.defineProperty(e.prototype,"$props",n),e.prototype.$set=$e,e.prototype.$delete=Oe,e.prototype.$watch=function(e,t,n){var i=this;if(d(t))return Mn(i,e,t,n);(n=n||{}).user=!0;var a=new yn(i,e,t,n);if(n.immediate)try{t.call(i,a.value)}catch(e){Ue(e,i,'callback for immediate watcher "'+a.expression+'"')}return function(){a.teardown()}}}($n),function(e){var t=/^hook:/;e.prototype.$on=function(e,n){var i=this;if(Array.isArray(e))for(var a=0,r=e.length;a1?A(n):n;for(var i=A(arguments,1),a='event handler for "'+e+'"',r=0,o=n.length;rparseInt(this.max)&&Pn(o,s[0],s,this._vnode)),t.data.keepAlive=!0}return t||e&&e[0]}}};!function(e){var t={get:function(){return j}};Object.defineProperty(e,"config",t),e.util={warn:ue,extend:$,mergeOptions:Fe,defineReactive:Ae},e.set=$e,e.delete=Oe,e.nextTick=at,e.observable=function(e){return ze(e),e},e.options=Object.create(null),F.forEach((function(t){e.options[t+"s"]=Object.create(null)})),e.options._base=e,$(e.options.components,Vn),function(e){e.use=function(e){var t=this._installedPlugins||(this._installedPlugins=[]);if(t.indexOf(e)>-1)return this;var n=A(arguments,1);return n.unshift(this),"function"==typeof e.install?e.install.apply(e,n):"function"==typeof e&&e.apply(null,n),t.push(e),this}}(e),function(e){e.mixin=function(e){return this.options=Fe(this.options,e),this}}(e),On(e),function(e){F.forEach((function(t){e[t]=function(e,n){return n?("component"===t&&d(n)&&(n.name=n.name||e,n=this.options._base.extend(n)),"directive"===t&&"function"==typeof n&&(n={bind:n,update:n}),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}}))}(e)}($n),Object.defineProperty($n.prototype,"$isServer",{get:oe}),Object.defineProperty($n.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Object.defineProperty($n,"FunctionalRenderContext",{value:Vt}),$n.version="2.6.12";var Bn=g("style,class"),Fn=g("input,textarea,option,select,progress"),Nn=function(e,t,n){return"value"===n&&Fn(e)&&"button"!==t||"selected"===n&&"option"===e||"checked"===n&&"input"===e||"muted"===n&&"video"===e},jn=g("contenteditable,draggable,spellcheck"),qn=g("events,caret,typing,plaintext-only"),Hn=g("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,translate,truespeed,typemustmatch,visible"),Rn="http://www.w3.org/1999/xlink",Un=function(e){return":"===e.charAt(5)&&"xlink"===e.slice(0,5)},Zn=function(e){return Un(e)?e.slice(6,e.length):""},Wn=function(e){return null==e||!1===e};function Gn(e){for(var t=e.data,n=e,i=e;r(i.componentInstance);)(i=i.componentInstance._vnode)&&i.data&&(t=Xn(i.data,t));for(;r(n=n.parent);)n&&n.data&&(t=Xn(t,n.data));return function(e,t){if(r(e)||r(t))return Kn(e,Jn(t));return""}(t.staticClass,t.class)}function Xn(e,t){return{staticClass:Kn(e.staticClass,t.staticClass),class:r(e.class)?[e.class,t.class]:t.class}}function Kn(e,t){return e?t?e+" "+t:e:t||""}function Jn(e){return Array.isArray(e)?function(e){for(var t,n="",i=0,a=e.length;i-1?_i(e,t,n):Hn(t)?Wn(n)?e.removeAttribute(t):(n="allowfullscreen"===t&&"EMBED"===e.tagName?"true":t,e.setAttribute(t,n)):jn(t)?e.setAttribute(t,function(e,t){return Wn(t)||"false"===t?"false":"contenteditable"===e&&qn(t)?t:"true"}(t,n)):Un(t)?Wn(n)?e.removeAttributeNS(Rn,Zn(t)):e.setAttributeNS(Rn,t,n):_i(e,t,n)}function _i(e,t,n){if(Wn(n))e.removeAttribute(t);else{if(Y&&!Q&&"TEXTAREA"===e.tagName&&"placeholder"===t&&""!==n&&!e.__ieph){var i=function(t){t.stopImmediatePropagation(),e.removeEventListener("input",i)};e.addEventListener("input",i),e.__ieph=!0}e.setAttribute(t,n)}}var ki={create:wi,update:wi};function Ci(e,t){var n=t.elm,i=t.data,o=e.data;if(!(a(i.staticClass)&&a(i.class)&&(a(o)||a(o.staticClass)&&a(o.class)))){var s=Gn(t),l=n._transitionClasses;r(l)&&(s=Kn(s,Jn(l))),s!==n._prevClass&&(n.setAttribute("class",s),n._prevClass=s)}}var Si,Ei,Mi,zi,Ai,$i,Oi={create:Ci,update:Ci},Ii=/[\w).+\-_$\]]/;function Li(e){var t,n,i,a,r,o=!1,s=!1,l=!1,c=!1,d=0,u=0,p=0,h=0;for(i=0;i=0&&" "===(m=e.charAt(f));f--);m&&Ii.test(m)||(c=!0)}}else void 0===a?(h=i+1,a=e.slice(0,i).trim()):g();function g(){(r||(r=[])).push(e.slice(h,i).trim()),h=i+1}if(void 0===a?a=e.slice(0,i).trim():0!==h&&g(),r)for(i=0;i-1?{exp:e.slice(0,zi),key:'"'+e.slice(zi+1)+'"'}:{exp:e,key:null};Ei=e,zi=Ai=$i=0;for(;!Ki();)Ji(Mi=Xi())?Qi(Mi):91===Mi&&Yi(Mi);return{exp:e.slice(0,Ai),key:e.slice(Ai+1,$i)}}(e);return null===n.key?e+"="+t:"$set("+n.exp+", "+n.key+", "+t+")"}function Xi(){return Ei.charCodeAt(++zi)}function Ki(){return zi>=Si}function Ji(e){return 34===e||39===e}function Yi(e){var t=1;for(Ai=zi;!Ki();)if(Ji(e=Xi()))Qi(e);else if(91===e&&t++,93===e&&t--,0===t){$i=zi;break}}function Qi(e){for(var t=e;!Ki()&&(e=Xi())!==t;);}var ea,ta="__r";function na(e,t,n){var i=ea;return function a(){var r=t.apply(null,arguments);null!==r&&ra(e,a,n,i)}}var ia=Ke&&!(ne&&Number(ne[1])<=53);function aa(e,t,n,i){if(ia){var a=fn,r=t;t=r._wrapper=function(e){if(e.target===e.currentTarget||e.timeStamp>=a||e.timeStamp<=0||e.target.ownerDocument!==document)return r.apply(this,arguments)}}ea.addEventListener(e,t,ae?{capture:n,passive:i}:n)}function ra(e,t,n,i){(i||ea).removeEventListener(e,t._wrapper||t,n)}function oa(e,t){if(!a(e.data.on)||!a(t.data.on)){var n=t.data.on||{},i=e.data.on||{};ea=t.elm,function(e){if(r(e.__r)){var t=Y?"change":"input";e[t]=[].concat(e.__r,e[t]||[]),delete e.__r}r(e.__c)&&(e.change=[].concat(e.__c,e.change||[]),delete e.__c)}(n),dt(n,i,aa,ra,na,t.context),ea=void 0}}var sa,la={create:oa,update:oa};function ca(e,t){if(!a(e.data.domProps)||!a(t.data.domProps)){var n,i,o=t.elm,s=e.data.domProps||{},l=t.data.domProps||{};for(n in r(l.__ob__)&&(l=t.data.domProps=$({},l)),s)n in l||(o[n]="");for(n in l){if(i=l[n],"textContent"===n||"innerHTML"===n){if(t.children&&(t.children.length=0),i===s[n])continue;1===o.childNodes.length&&o.removeChild(o.childNodes[0])}if("value"===n&&"PROGRESS"!==o.tagName){o._value=i;var c=a(i)?"":String(i);da(o,c)&&(o.value=c)}else if("innerHTML"===n&&ei(o.tagName)&&a(o.innerHTML)){(sa=sa||document.createElement("div")).innerHTML=""+i+"";for(var d=sa.firstChild;o.firstChild;)o.removeChild(o.firstChild);for(;d.firstChild;)o.appendChild(d.firstChild)}else if(i!==s[n])try{o[n]=i}catch(e){}}}}function da(e,t){return!e.composing&&("OPTION"===e.tagName||function(e,t){var n=!0;try{n=document.activeElement!==e}catch(e){}return n&&e.value!==t}(e,t)||function(e,t){var n=e.value,i=e._vModifiers;if(r(i)){if(i.number)return m(n)!==m(t);if(i.trim)return n.trim()!==t.trim()}return n!==t}(e,t))}var ua={create:ca,update:ca},pa=_((function(e){var t={},n=/:(.+)/;return e.split(/;(?![^(]*\))/g).forEach((function(e){if(e){var i=e.split(n);i.length>1&&(t[i[0].trim()]=i[1].trim())}})),t}));function ha(e){var t=fa(e.style);return e.staticStyle?$(e.staticStyle,t):t}function fa(e){return Array.isArray(e)?O(e):"string"==typeof e?pa(e):e}var ma,ga=/^--/,va=/\s*!important$/,ba=function(e,t,n){if(ga.test(t))e.style.setProperty(t,n);else if(va.test(n))e.style.setProperty(M(t),n.replace(va,""),"important");else{var i=wa(t);if(Array.isArray(n))for(var a=0,r=n.length;a-1?t.split(ka).forEach((function(t){return e.classList.add(t)})):e.classList.add(t);else{var n=" "+(e.getAttribute("class")||"")+" ";n.indexOf(" "+t+" ")<0&&e.setAttribute("class",(n+t).trim())}}function Sa(e,t){if(t&&(t=t.trim()))if(e.classList)t.indexOf(" ")>-1?t.split(ka).forEach((function(t){return e.classList.remove(t)})):e.classList.remove(t),e.classList.length||e.removeAttribute("class");else{for(var n=" "+(e.getAttribute("class")||"")+" ",i=" "+t+" ";n.indexOf(i)>=0;)n=n.replace(i," ");(n=n.trim())?e.setAttribute("class",n):e.removeAttribute("class")}}function Ea(e){if(e){if("object"==typeof e){var t={};return!1!==e.css&&$(t,Ma(e.name||"v")),$(t,e),t}return"string"==typeof e?Ma(e):void 0}}var Ma=_((function(e){return{enterClass:e+"-enter",enterToClass:e+"-enter-to",enterActiveClass:e+"-enter-active",leaveClass:e+"-leave",leaveToClass:e+"-leave-to",leaveActiveClass:e+"-leave-active"}})),za=G&&!Q,Aa="transition",$a="animation",Oa="transition",Ia="transitionend",La="animation",Ta="animationend";za&&(void 0===window.ontransitionend&&void 0!==window.onwebkittransitionend&&(Oa="WebkitTransition",Ia="webkitTransitionEnd"),void 0===window.onanimationend&&void 0!==window.onwebkitanimationend&&(La="WebkitAnimation",Ta="webkitAnimationEnd"));var Pa=G?window.requestAnimationFrame?window.requestAnimationFrame.bind(window):setTimeout:function(e){return e()};function Da(e){Pa((function(){Pa(e)}))}function Va(e,t){var n=e._transitionClasses||(e._transitionClasses=[]);n.indexOf(t)<0&&(n.push(t),Ca(e,t))}function Ba(e,t){e._transitionClasses&&y(e._transitionClasses,t),Sa(e,t)}function Fa(e,t,n){var i=ja(e,t),a=i.type,r=i.timeout,o=i.propCount;if(!a)return n();var s=a===Aa?Ia:Ta,l=0,c=function(){e.removeEventListener(s,d),n()},d=function(t){t.target===e&&++l>=o&&c()};setTimeout((function(){l0&&(n=Aa,d=o,u=r.length):t===$a?c>0&&(n=$a,d=c,u=l.length):u=(n=(d=Math.max(o,c))>0?o>c?Aa:$a:null)?n===Aa?r.length:l.length:0,{type:n,timeout:d,propCount:u,hasTransform:n===Aa&&Na.test(i[Oa+"Property"])}}function qa(e,t){for(;e.length1}function Ga(e,t){!0!==t.data.show&&Ra(t)}var Xa=function(e){var t,n,i={},l=e.modules,c=e.nodeOps;for(t=0;tf?y(e,a(n[v+1])?null:n[v+1].elm,n,h,v,i):h>v&&x(t,p,f)}(p,g,v,n,d):r(v)?(r(e.text)&&c.setTextContent(p,""),y(p,null,v,0,v.length-1,n)):r(g)?x(g,0,g.length-1):r(e.text)&&c.setTextContent(p,""):e.text!==t.text&&c.setTextContent(p,t.text),r(f)&&r(h=f.hook)&&r(h=h.postpatch)&&h(e,t)}}}function S(e,t,n){if(o(n)&&r(e.parent))e.parent.data.pendingInsert=t;else for(var i=0;i-1,o.selected!==r&&(o.selected=r);else if(P(er(o),i))return void(e.selectedIndex!==s&&(e.selectedIndex=s));a||(e.selectedIndex=-1)}}function Qa(e,t){return t.every((function(t){return!P(t,e)}))}function er(e){return"_value"in e?e._value:e.value}function tr(e){e.target.composing=!0}function nr(e){e.target.composing&&(e.target.composing=!1,ir(e.target,"input"))}function ir(e,t){var n=document.createEvent("HTMLEvents");n.initEvent(t,!0,!0),e.dispatchEvent(n)}function ar(e){return!e.componentInstance||e.data&&e.data.transition?e:ar(e.componentInstance._vnode)}var rr={model:Ka,show:{bind:function(e,t,n){var i=t.value,a=(n=ar(n)).data&&n.data.transition,r=e.__vOriginalDisplay="none"===e.style.display?"":e.style.display;i&&a?(n.data.show=!0,Ra(n,(function(){e.style.display=r}))):e.style.display=i?r:"none"},update:function(e,t,n){var i=t.value;!i!=!t.oldValue&&((n=ar(n)).data&&n.data.transition?(n.data.show=!0,i?Ra(n,(function(){e.style.display=e.__vOriginalDisplay})):Ua(n,(function(){e.style.display="none"}))):e.style.display=i?e.__vOriginalDisplay:"none")},unbind:function(e,t,n,i,a){a||(e.style.display=e.__vOriginalDisplay)}}},or={name:String,appear:Boolean,css:Boolean,mode:String,type:String,enterClass:String,leaveClass:String,enterToClass:String,leaveToClass:String,enterActiveClass:String,leaveActiveClass:String,appearClass:String,appearActiveClass:String,appearToClass:String,duration:[Number,String,Object]};function sr(e){var t=e&&e.componentOptions;return t&&t.Ctor.options.abstract?sr(Kt(t.children)):e}function lr(e){var t={},n=e.$options;for(var i in n.propsData)t[i]=e[i];var a=n._parentListeners;for(var r in a)t[C(r)]=a[r];return t}function cr(e,t){if(/\d-keep-alive$/.test(t.tag))return e("keep-alive",{props:t.componentOptions.propsData})}var dr=function(e){return e.tag||Xt(e)},ur=function(e){return"show"===e.name},pr={name:"transition",props:or,abstract:!0,render:function(e){var t=this,n=this.$slots.default;if(n&&(n=n.filter(dr)).length){0;var i=this.mode;0;var a=n[0];if(function(e){for(;e=e.parent;)if(e.data.transition)return!0}(this.$vnode))return a;var r=sr(a);if(!r)return a;if(this._leaving)return cr(e,a);var o="__transition-"+this._uid+"-";r.key=null==r.key?r.isComment?o+"comment":o+r.tag:s(r.key)?0===String(r.key).indexOf(o)?r.key:o+r.key:r.key;var l=(r.data||(r.data={})).transition=lr(this),c=this._vnode,d=sr(c);if(r.data.directives&&r.data.directives.some(ur)&&(r.data.show=!0),d&&d.data&&!function(e,t){return t.key===e.key&&t.tag===e.tag}(r,d)&&!Xt(d)&&(!d.componentInstance||!d.componentInstance._vnode.isComment)){var u=d.data.transition=$({},l);if("out-in"===i)return this._leaving=!0,ut(u,"afterLeave",(function(){t._leaving=!1,t.$forceUpdate()})),cr(e,a);if("in-out"===i){if(Xt(r))return c;var p,h=function(){p()};ut(l,"afterEnter",h),ut(l,"enterCancelled",h),ut(u,"delayLeave",(function(e){p=e}))}}return a}}},hr=$({tag:String,moveClass:String},or);function fr(e){e.elm._moveCb&&e.elm._moveCb(),e.elm._enterCb&&e.elm._enterCb()}function mr(e){e.data.newPos=e.elm.getBoundingClientRect()}function gr(e){var t=e.data.pos,n=e.data.newPos,i=t.left-n.left,a=t.top-n.top;if(i||a){e.data.moved=!0;var r=e.elm.style;r.transform=r.WebkitTransform="translate("+i+"px,"+a+"px)",r.transitionDuration="0s"}}delete hr.mode;var vr={Transition:pr,TransitionGroup:{props:hr,beforeMount:function(){var e=this,t=this._update;this._update=function(n,i){var a=nn(e);e.__patch__(e._vnode,e.kept,!1,!0),e._vnode=e.kept,a(),t.call(e,n,i)}},render:function(e){for(var t=this.tag||this.$vnode.data.tag||"span",n=Object.create(null),i=this.prevChildren=this.children,a=this.$slots.default||[],r=this.children=[],o=lr(this),s=0;s-1?ii[e]=t.constructor===window.HTMLUnknownElement||t.constructor===window.HTMLElement:ii[e]=/HTMLUnknownElement/.test(t.toString())},$($n.options.directives,rr),$($n.options.components,vr),$n.prototype.__patch__=G?Xa:I,$n.prototype.$mount=function(e,t){return function(e,t,n){var i;return e.$el=t,e.$options.render||(e.$options.render=ye),sn(e,"beforeMount"),i=function(){e._update(e._render(),n)},new yn(e,i,I,{before:function(){e._isMounted&&!e._isDestroyed&&sn(e,"beforeUpdate")}},!0),n=!1,null==e.$vnode&&(e._isMounted=!0,sn(e,"mounted")),e}(this,e=e&&G?ri(e):void 0,t)},G&&setTimeout((function(){j.devtools&&se&&se.emit("init",$n)}),0);var br=/\{\{((?:.|\r?\n)+?)\}\}/g,yr=/[-.*+?^${}()|[\]\/\\]/g,wr=_((function(e){var t=e[0].replace(yr,"\\$&"),n=e[1].replace(yr,"\\$&");return new RegExp(t+"((?:.|\\n)+?)"+n,"g")}));var xr={staticKeys:["staticClass"],transformNode:function(e,t){t.warn;var n=Ri(e,"class");n&&(e.staticClass=JSON.stringify(n));var i=Hi(e,"class",!1);i&&(e.classBinding=i)},genData:function(e){var t="";return e.staticClass&&(t+="staticClass:"+e.staticClass+","),e.classBinding&&(t+="class:"+e.classBinding+","),t}};var _r,kr={staticKeys:["staticStyle"],transformNode:function(e,t){t.warn;var n=Ri(e,"style");n&&(e.staticStyle=JSON.stringify(pa(n)));var i=Hi(e,"style",!1);i&&(e.styleBinding=i)},genData:function(e){var t="";return e.staticStyle&&(t+="staticStyle:"+e.staticStyle+","),e.styleBinding&&(t+="style:("+e.styleBinding+"),"),t}},Cr=function(e){return(_r=_r||document.createElement("div")).innerHTML=e,_r.textContent},Sr=g("area,base,br,col,embed,frame,hr,img,input,isindex,keygen,link,meta,param,source,track,wbr"),Er=g("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source"),Mr=g("address,article,aside,base,blockquote,body,caption,col,colgroup,dd,details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,title,tr,track"),zr=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,Ar=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,$r="[a-zA-Z_][\\-\\.0-9_a-zA-Z"+q.source+"]*",Or="((?:"+$r+"\\:)?"+$r+")",Ir=new RegExp("^<"+Or),Lr=/^\s*(\/?)>/,Tr=new RegExp("^<\\/"+Or+"[^>]*>"),Pr=/^]+>/i,Dr=/^",""":'"',"&":"&"," ":"\n"," ":"\t","'":"'"},jr=/&(?:lt|gt|quot|amp|#39);/g,qr=/&(?:lt|gt|quot|amp|#39|#10|#9);/g,Hr=g("pre,textarea",!0),Rr=function(e,t){return e&&Hr(e)&&"\n"===t[0]};function Ur(e,t){var n=t?qr:jr;return e.replace(n,(function(e){return Nr[e]}))}var Zr,Wr,Gr,Xr,Kr,Jr,Yr,Qr,eo=/^@|^v-on:/,to=/^v-|^@|^:|^#/,no=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,io=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,ao=/^\(|\)$/g,ro=/^\[.*\]$/,oo=/:(.*)$/,so=/^:|^\.|^v-bind:/,lo=/\.[^.\]]+(?=[^\]]*$)/g,co=/^v-slot(:|$)|^#/,uo=/[\r\n]/,po=/\s+/g,ho=_(Cr),fo="_empty_";function mo(e,t,n){return{type:1,tag:e,attrsList:t,attrsMap:_o(t),rawAttrsMap:{},parent:n,children:[]}}function go(e,t){Zr=t.warn||Pi,Jr=t.isPreTag||L,Yr=t.mustUseProp||L,Qr=t.getTagNamespace||L;var n=t.isReservedTag||L;(function(e){return!!e.component||!n(e.tag)}),Gr=Di(t.modules,"transformNode"),Xr=Di(t.modules,"preTransformNode"),Kr=Di(t.modules,"postTransformNode"),Wr=t.delimiters;var i,a,r=[],o=!1!==t.preserveWhitespace,s=t.whitespace,l=!1,c=!1;function d(e){if(u(e),l||e.processed||(e=vo(e,t)),r.length||e===i||i.if&&(e.elseif||e.else)&&yo(i,{exp:e.elseif,block:e}),a&&!e.forbidden)if(e.elseif||e.else)o=e,(s=function(e){for(var t=e.length;t--;){if(1===e[t].type)return e[t];e.pop()}}(a.children))&&s.if&&yo(s,{exp:o.elseif,block:o});else{if(e.slotScope){var n=e.slotTarget||'"default"';(a.scopedSlots||(a.scopedSlots={}))[n]=e}a.children.push(e),e.parent=a}var o,s;e.children=e.children.filter((function(e){return!e.slotScope})),u(e),e.pre&&(l=!1),Jr(e.tag)&&(c=!1);for(var d=0;d]*>)","i")),p=e.replace(u,(function(e,n,i){return c=i.length,Br(d)||"noscript"===d||(n=n.replace(//g,"$1").replace(//g,"$1")),Rr(d,n)&&(n=n.slice(1)),t.chars&&t.chars(n),""}));l+=e.length-p.length,e=p,E(d,l-c,l)}else{var h=e.indexOf("<");if(0===h){if(Dr.test(e)){var f=e.indexOf("--\x3e");if(f>=0){t.shouldKeepComment&&t.comment(e.substring(4,f),l,l+f+3),k(f+3);continue}}if(Vr.test(e)){var m=e.indexOf("]>");if(m>=0){k(m+2);continue}}var g=e.match(Pr);if(g){k(g[0].length);continue}var v=e.match(Tr);if(v){var b=l;k(v[0].length),E(v[1],b,l);continue}var y=C();if(y){S(y),Rr(y.tagName,e)&&k(1);continue}}var w=void 0,x=void 0,_=void 0;if(h>=0){for(x=e.slice(h);!(Tr.test(x)||Ir.test(x)||Dr.test(x)||Vr.test(x)||(_=x.indexOf("<",1))<0);)h+=_,x=e.slice(h);w=e.substring(0,h)}h<0&&(w=e),w&&k(w.length),t.chars&&w&&t.chars(w,l-w.length,l)}if(e===n){t.chars&&t.chars(e);break}}function k(t){l+=t,e=e.substring(t)}function C(){var t=e.match(Ir);if(t){var n,i,a={tagName:t[1],attrs:[],start:l};for(k(t[0].length);!(n=e.match(Lr))&&(i=e.match(Ar)||e.match(zr));)i.start=l,k(i[0].length),i.end=l,a.attrs.push(i);if(n)return a.unarySlash=n[1],k(n[0].length),a.end=l,a}}function S(e){var n=e.tagName,l=e.unarySlash;r&&("p"===i&&Mr(n)&&E(i),s(n)&&i===n&&E(n));for(var c=o(n)||!!l,d=e.attrs.length,u=new Array(d),p=0;p=0&&a[o].lowerCasedTag!==s;o--);else o=0;if(o>=0){for(var c=a.length-1;c>=o;c--)t.end&&t.end(a[c].tag,n,r);a.length=o,i=o&&a[o-1].tag}else"br"===s?t.start&&t.start(e,[],!0,n,r):"p"===s&&(t.start&&t.start(e,[],!1,n,r),t.end&&t.end(e,n,r))}E()}(e,{warn:Zr,expectHTML:t.expectHTML,isUnaryTag:t.isUnaryTag,canBeLeftOpenTag:t.canBeLeftOpenTag,shouldDecodeNewlines:t.shouldDecodeNewlines,shouldDecodeNewlinesForHref:t.shouldDecodeNewlinesForHref,shouldKeepComment:t.comments,outputSourceRange:t.outputSourceRange,start:function(e,n,o,s,u){var p=a&&a.ns||Qr(e);Y&&"svg"===p&&(n=function(e){for(var t=[],n=0;nl&&(s.push(r=e.slice(l,a)),o.push(JSON.stringify(r)));var c=Li(i[1].trim());o.push("_s("+c+")"),s.push({"@binding":c}),l=a+i[0].length}return l-1"+("true"===r?":("+t+")":":_q("+t+","+r+")")),qi(e,"change","var $$a="+t+",$$el=$event.target,$$c=$$el.checked?("+r+"):("+o+");if(Array.isArray($$a)){var $$v="+(i?"_n("+a+")":a)+",$$i=_i($$a,$$v);if($$el.checked){$$i<0&&("+Gi(t,"$$a.concat([$$v])")+")}else{$$i>-1&&("+Gi(t,"$$a.slice(0,$$i).concat($$a.slice($$i+1))")+")}}else{"+Gi(t,"$$c")+"}",null,!0)}(e,i,a);else if("input"===r&&"radio"===o)!function(e,t,n){var i=n&&n.number,a=Hi(e,"value")||"null";Vi(e,"checked","_q("+t+","+(a=i?"_n("+a+")":a)+")"),qi(e,"change",Gi(t,a),null,!0)}(e,i,a);else if("input"===r||"textarea"===r)!function(e,t,n){var i=e.attrsMap.type;0;var a=n||{},r=a.lazy,o=a.number,s=a.trim,l=!r&&"range"!==i,c=r?"change":"range"===i?ta:"input",d="$event.target.value";s&&(d="$event.target.value.trim()");o&&(d="_n("+d+")");var u=Gi(t,d);l&&(u="if($event.target.composing)return;"+u);Vi(e,"value","("+t+")"),qi(e,c,u,null,!0),(s||o)&&qi(e,"blur","$forceUpdate()")}(e,i,a);else{if(!j.isReservedTag(r))return Wi(e,i,a),!1}return!0},text:function(e,t){t.value&&Vi(e,"textContent","_s("+t.value+")",t)},html:function(e,t){t.value&&Vi(e,"innerHTML","_s("+t.value+")",t)}},isPreTag:function(e){return"pre"===e},isUnaryTag:Sr,mustUseProp:Nn,canBeLeftOpenTag:Er,isReservedTag:ti,getTagNamespace:ni,staticKeys:function(e){return e.reduce((function(e,t){return e.concat(t.staticKeys||[])}),[]).join(",")}(Eo)},$o=_((function(e){return g("type,tag,attrsList,attrsMap,plain,parent,children,attrs,start,end,rawAttrsMap"+(e?","+e:""))}));function Oo(e,t){e&&(Mo=$o(t.staticKeys||""),zo=t.isReservedTag||L,Io(e),Lo(e,!1))}function Io(e){if(e.static=function(e){if(2===e.type)return!1;if(3===e.type)return!0;return!(!e.pre&&(e.hasBindings||e.if||e.for||v(e.tag)||!zo(e.tag)||function(e){for(;e.parent;){if("template"!==(e=e.parent).tag)return!1;if(e.for)return!0}return!1}(e)||!Object.keys(e).every(Mo)))}(e),1===e.type){if(!zo(e.tag)&&"slot"!==e.tag&&null==e.attrsMap["inline-template"])return;for(var t=0,n=e.children.length;t|^function(?:\s+[\w$]+)?\s*\(/,Po=/\([^)]*?\);*$/,Do=/^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['[^']*?']|\["[^"]*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*$/,Vo={esc:27,tab:9,enter:13,space:32,up:38,left:37,right:39,down:40,delete:[8,46]},Bo={esc:["Esc","Escape"],tab:"Tab",enter:"Enter",space:[" ","Spacebar"],up:["Up","ArrowUp"],left:["Left","ArrowLeft"],right:["Right","ArrowRight"],down:["Down","ArrowDown"],delete:["Backspace","Delete","Del"]},Fo=function(e){return"if("+e+")return null;"},No={stop:"$event.stopPropagation();",prevent:"$event.preventDefault();",self:Fo("$event.target !== $event.currentTarget"),ctrl:Fo("!$event.ctrlKey"),shift:Fo("!$event.shiftKey"),alt:Fo("!$event.altKey"),meta:Fo("!$event.metaKey"),left:Fo("'button' in $event && $event.button !== 0"),middle:Fo("'button' in $event && $event.button !== 1"),right:Fo("'button' in $event && $event.button !== 2")};function jo(e,t){var n=t?"nativeOn:":"on:",i="",a="";for(var r in e){var o=qo(e[r]);e[r]&&e[r].dynamic?a+=r+","+o+",":i+='"'+r+'":'+o+","}return i="{"+i.slice(0,-1)+"}",a?n+"_d("+i+",["+a.slice(0,-1)+"])":n+i}function qo(e){if(!e)return"function(){}";if(Array.isArray(e))return"["+e.map((function(e){return qo(e)})).join(",")+"]";var t=Do.test(e.value),n=To.test(e.value),i=Do.test(e.value.replace(Po,""));if(e.modifiers){var a="",r="",o=[];for(var s in e.modifiers)if(No[s])r+=No[s],Vo[s]&&o.push(s);else if("exact"===s){var l=e.modifiers;r+=Fo(["ctrl","shift","alt","meta"].filter((function(e){return!l[e]})).map((function(e){return"$event."+e+"Key"})).join("||"))}else o.push(s);return o.length&&(a+=function(e){return"if(!$event.type.indexOf('key')&&"+e.map(Ho).join("&&")+")return null;"}(o)),r&&(a+=r),"function($event){"+a+(t?"return "+e.value+"($event)":n?"return ("+e.value+")($event)":i?"return "+e.value:e.value)+"}"}return t||n?e.value:"function($event){"+(i?"return "+e.value:e.value)+"}"}function Ho(e){var t=parseInt(e,10);if(t)return"$event.keyCode!=="+t;var n=Vo[e],i=Bo[e];return"_k($event.keyCode,"+JSON.stringify(e)+","+JSON.stringify(n)+",$event.key,"+JSON.stringify(i)+")"}var Ro={on:function(e,t){e.wrapListeners=function(e){return"_g("+e+","+t.value+")"}},bind:function(e,t){e.wrapData=function(n){return"_b("+n+",'"+e.tag+"',"+t.value+","+(t.modifiers&&t.modifiers.prop?"true":"false")+(t.modifiers&&t.modifiers.sync?",true":"")+")"}},cloak:I},Uo=function(e){this.options=e,this.warn=e.warn||Pi,this.transforms=Di(e.modules,"transformCode"),this.dataGenFns=Di(e.modules,"genData"),this.directives=$($({},Ro),e.directives);var t=e.isReservedTag||L;this.maybeComponent=function(e){return!!e.component||!t(e.tag)},this.onceId=0,this.staticRenderFns=[],this.pre=!1};function Zo(e,t){var n=new Uo(t);return{render:"with(this){return "+(e?Wo(e,n):'_c("div")')+"}",staticRenderFns:n.staticRenderFns}}function Wo(e,t){if(e.parent&&(e.pre=e.pre||e.parent.pre),e.staticRoot&&!e.staticProcessed)return Go(e,t);if(e.once&&!e.onceProcessed)return Xo(e,t);if(e.for&&!e.forProcessed)return Yo(e,t);if(e.if&&!e.ifProcessed)return Ko(e,t);if("template"!==e.tag||e.slotTarget||t.pre){if("slot"===e.tag)return function(e,t){var n=e.slotName||'"default"',i=ns(e,t),a="_t("+n+(i?","+i:""),r=e.attrs||e.dynamicAttrs?rs((e.attrs||[]).concat(e.dynamicAttrs||[]).map((function(e){return{name:C(e.name),value:e.value,dynamic:e.dynamic}}))):null,o=e.attrsMap["v-bind"];!r&&!o||i||(a+=",null");r&&(a+=","+r);o&&(a+=(r?"":",null")+","+o);return a+")"}(e,t);var n;if(e.component)n=function(e,t,n){var i=t.inlineTemplate?null:ns(t,n,!0);return"_c("+e+","+Qo(t,n)+(i?","+i:"")+")"}(e.component,e,t);else{var i;(!e.plain||e.pre&&t.maybeComponent(e))&&(i=Qo(e,t));var a=e.inlineTemplate?null:ns(e,t,!0);n="_c('"+e.tag+"'"+(i?","+i:"")+(a?","+a:"")+")"}for(var r=0;r>>0}(o):"")+")"}(e,e.scopedSlots,t)+","),e.model&&(n+="model:{value:"+e.model.value+",callback:"+e.model.callback+",expression:"+e.model.expression+"},"),e.inlineTemplate){var r=function(e,t){var n=e.children[0];0;if(n&&1===n.type){var i=Zo(n,t.options);return"inlineTemplate:{render:function(){"+i.render+"},staticRenderFns:["+i.staticRenderFns.map((function(e){return"function(){"+e+"}"})).join(",")+"]}"}}(e,t);r&&(n+=r+",")}return n=n.replace(/,$/,"")+"}",e.dynamicAttrs&&(n="_b("+n+',"'+e.tag+'",'+rs(e.dynamicAttrs)+")"),e.wrapData&&(n=e.wrapData(n)),e.wrapListeners&&(n=e.wrapListeners(n)),n}function es(e){return 1===e.type&&("slot"===e.tag||e.children.some(es))}function ts(e,t){var n=e.attrsMap["slot-scope"];if(e.if&&!e.ifProcessed&&!n)return Ko(e,t,ts,"null");if(e.for&&!e.forProcessed)return Yo(e,t,ts);var i=e.slotScope===fo?"":String(e.slotScope),a="function("+i+"){return "+("template"===e.tag?e.if&&n?"("+e.if+")?"+(ns(e,t)||"undefined")+":undefined":ns(e,t)||"undefined":Wo(e,t))+"}",r=i?"":",proxy:true";return"{key:"+(e.slotTarget||'"default"')+",fn:"+a+r+"}"}function ns(e,t,n,i,a){var r=e.children;if(r.length){var o=r[0];if(1===r.length&&o.for&&"template"!==o.tag&&"slot"!==o.tag){var s=n?t.maybeComponent(o)?",1":",0":"";return""+(i||Wo)(o,t)+s}var l=n?function(e,t){for(var n=0,i=0;i':'
',ds.innerHTML.indexOf(" ")>0}var fs=!!G&&hs(!1),ms=!!G&&hs(!0),gs=_((function(e){var t=ri(e);return t&&t.innerHTML})),vs=$n.prototype.$mount;$n.prototype.$mount=function(e,t){if((e=e&&ri(e))===document.body||e===document.documentElement)return this;var n=this.$options;if(!n.render){var i=n.template;if(i)if("string"==typeof i)"#"===i.charAt(0)&&(i=gs(i));else{if(!i.nodeType)return this;i=i.innerHTML}else e&&(i=function(e){if(e.outerHTML)return e.outerHTML;var t=document.createElement("div");return t.appendChild(e.cloneNode(!0)),t.innerHTML}(e));if(i){0;var a=ps(i,{outputSourceRange:!1,shouldDecodeNewlines:fs,shouldDecodeNewlinesForHref:ms,delimiters:n.delimiters,comments:n.comments},this),r=a.render,o=a.staticRenderFns;n.render=r,n.staticRenderFns=o}}return vs.call(this,e,t)},$n.compile=ps;var bs=$n;const ys=()=>{window.Vue=bs,Vue.config.devtools=!1,Vue.config.productionTip=!1,Vue.directive("hit",{inserted(e,{value:t}){if(t&&"function"==typeof t){const n=e=>{t.length>0?t(e):t()};e.addEventListener("click",t),e.addEventListener("keydown",(e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),n(e))}))}}})}},4363:function(e,t,n){"use strict";n.d(t,{Z:function(){return k}});var i=n(9659),a=n(4742),r=n(9925);const o={name:"launchBar.plugin",displayName:"搜索栏 - 快捷键支持",setup:({addData:e})=>{e("keymap.actions",(e=>{e.showLaunchBar={displayName:"显示搜索栏",run:async()=>{const{toggleLaunchBar:e}=await Promise.resolve().then(n.bind(n,218));return e(),!0}}})),e("keymap.presets",(e=>{e.showLaunchBar="/"}))}},s={name:"launchBar",displayName:"搜索栏",configurable:!1,entry:a.none,plugin:o,hidden:!0,tags:[r.t.general,r.t.utils],options:{searchHistory:{displayName:"搜索历史",defaultValue:[],hidden:!0}}};var l=n(5890),c=n(8494),d=n(9017);function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class p{constructor(){u(this,"accepts",(e=>e.nodeType===Node.ELEMENT_NODE)),u(this,"getValue",(e=>e.nodeValue)),u(this,"setValue",((e,t)=>{e.nodeValue=t})),u(this,"getElement",(e=>e))}translate(e){let t=this.getValue(e);if(!t||"string"!=typeof t||"*"===t)return;t=t.trim();const n=p.map.get(t);if(void 0===n){const n=p.regex.find((([e])=>e.test(t)));if(n){const[i,a]=n;this.setValue(e,t.replace(i,a))}}else if("string"==typeof n)this.setValue(e,n);else if(Array.isArray(n)){let t=null;for(const i of n)if("string"==typeof i)t=i;else{const{text:n,selector:a,not:r}=i;this.getElement(e)?.matches(a)!==Boolean(r)&&(t=n)}null!==t&&this.setValue(e,t)}else{const{text:t,selector:i,not:a}=n;this.getElement(e)?.matches(i)!==Boolean(a)&&this.setValue(e,t)}}static walk(e,t){const n=document.createNodeIterator(e,// eslint-disable-next-line no-bitwise -NodeFilter.SHOW_TEXT|NodeFilter.SHOW_ELEMENT);let i=n.nextNode();for(;i;)t(i),i=n.nextNode()}static translate(e){if(e.nodeType===Node.TEXT_NODE)return void p.textNode.translate(e);const t=e=>{for(const t of p.sensitiveTranslators)t.accepts(e)&&t.translate(e)};t(e),p.walk(e,t)}static translateCssMatches(){const e=p.map.get("*");if(e)for(const{selector:t,text:n}of e){const e=document.querySelector(t);e&&[...e.childNodes].filter((e=>e.nodeType===Node.TEXT_NODE)).forEach((e=>e.nodeValue=n))}}}u(p,"textNode",void 0),u(p,"title",void 0),u(p,"placeholder",void 0),u(p,"sensitiveTranslators",void 0),u(p,"map",void 0),u(p,"regex",void 0);p.textNode=new class extends p{constructor(...e){super(...e),u(this,"accepts",(e=>e.nodeType===Node.TEXT_NODE)),u(this,"getElement",(e=>e.parentElement))}},p.title=new class extends p{constructor(...e){super(...e),u(this,"getValue",(e=>e.getAttribute("title"))),u(this,"setValue",((e,t)=>{e.setAttribute("title",t)}))}},p.placeholder=new class extends p{constructor(...e){super(...e),u(this,"getValue",(e=>e.getAttribute("placeholder"))),u(this,"setValue",((e,t)=>{e.setAttribute("placeholder",t)}))}},p.sensitiveTranslators=[p.textNode,p.title,p.placeholder];const h={name:"i18n",displayName:"多语言",configurable:!1,entry:async()=>{const{getSelectedLanguage:e}=await Promise.resolve().then(n.bind(n,1416)),t=e();if(t===l.defaultLanguageCode)return;const{registerAndGetData:i}=await Promise.resolve().then(n.bind(n,9207)),[a,r]=i(`i18n.${t}`,new Map,[]);console.log(t,a.size,r.length),0===a.size&&0===r.length||(document.documentElement.setAttribute("lang",t),p.map=a,p.regex=r,p.translate(document.body),p.translateCssMatches(),(0,d.allMutations)((e=>{e.forEach((e=>{"childList"===e.type?(e.addedNodes.length>0&&p.translateCssMatches(),e.addedNodes.forEach((e=>{p.translate(e)}))):"characterData"===e.type?p.textNode.translate(e.target):"attributes"===e.type&&("title"===e.attributeName?p.title.translate(e.target):"placeholder"===e.attributeName&&p.placeholder.translate(e.target))}))})))},tags:[r.t.utils,r.t.experimental,r.t.general],description:{"zh-CN":"安装其他语言包可以更换界面语言, 机器翻译选择可以设定其他一些功能如`动态翻译`, `评论翻译`使用的翻译器. 机器翻译的选择不影响界面语言."},options:{language:{defaultValue:l.languageCodeToName[l.defaultLanguageCode],displayName:"界面语言选择",dropdownEnum:l.languageCodeToName},translator:{defaultValue:Object.keys(c.WK)[0],displayName:"机器翻译选择",dropdownEnum:c.U6}}};var f=n(7724);const m=/^http:\/\/localhost/,g="autoUpdate",v=e=>m.test(e),b=async e=>{const{items:t,existPredicate:n,installer:i,filterNames:a=[],force:r=!1}=e,o=Number(new Date),{devMode:s}=(0,f.getGeneralSettings)(),{options:l}=(0,f.getComponentSettings)(g);Object.keys(t).filter((e=>!n(e))).forEach((e=>{delete t[e]}));return(await Promise.allSettled(Object.entries(t).filter((([e,t])=>(e=>0===a.length||a.includes(e))(e)&&Boolean(t.url))).map((async([e,n])=>{const{url:a,lastUpdateCheck:c,alwaysUpdate:d}=n;if(!(d&&s)&&o-c<=l.minimumDuration&&!r)return`[${e}] 未超过更新间隔期, 已跳过`;let u=a;m.test(a)&&l.localPortOverride&&(u=a.replace(/:(\d)+/,`:${l.localPortOverride}`));const p=await coreApis.ajax.monkey({url:u});if(!(e in t))return`[${e}] 已被卸载, 取消更新`;const{message:h}=await i(p);return n.lastUpdateCheck=Number(new Date),`[${e}] ${h}`})))).map(((e,n)=>{if("fulfilled"===e.status)return e.value;const i=e.reason?.message??e.reason.toString();return`[${Object.keys(t)[n]}] ${i}`})).join("\n").trim()},y=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{components:a}=i.urls,{installComponent:r}=await Promise.resolve().then(n.bind(n,559));return b({items:a,existPredicate:e=>void 0!==f.settings.userComponents[e],installer:r,filterNames:e,force:t})},w=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{plugins:a}=i.urls,{installPlugin:r}=await Promise.resolve().then(n.bind(n,3865));return b({items:a,existPredicate:e=>void 0!==f.settings.userPlugins[e],installer:r,filterNames:e,force:t})},x=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{styles:a}=i.urls,{installStyle:r}=await Promise.resolve().then(n.bind(n,1773));return b({items:a,existPredicate:e=>void 0!==f.settings.userStyles[e],installer:r,filterNames:e,force:t})},_={name:g,displayName:"自动更新器",description:{"zh-CN":"自动检查组件, 插件和样式的更新. (仅限从设置面板中安装的)"},tags:[r.t.utils],options:{lastUpdateCheck:{displayName:"最后检查更新日期",defaultValue:0,hidden:!0},localPortOverride:{displayName:"本地组件链接端口",defaultValue:"",hidden:!0},minimumDuration:{displayName:"更新间隔 (ms)",defaultValue:864e5},urls:{displayName:"更新链接",defaultValue:{components:{},plugins:{},styles:{}},hidden:!0}},entry:async({settings:{options:e}})=>{const t=Number(new Date)-e.lastUpdateCheck,n=async()=>{console.log("[自动更新器] 开始检查更新"),console.log(await y()||"暂无组件更新"),console.log(await w()||"暂无插件更新"),console.log(await x()||"暂无样式更新"),e.lastUpdateCheck=Number(new Date),console.log("[自动更新器] 完成更新检查")};return t>=e.minimumDuration&&coreApis.lifeCycle.fullyLoaded(n),{checkUpdates:n,checkUpdatesAndReload:async()=>{await n(),window.location.reload()},updateSingleComponent:async(...e)=>{await y({filterNames:e,force:!0}),window.location.reload()},updateSinglePlugin:async(...e)=>{await w({filterNames:e,force:!0}),window.location.reload()},updateSingleStyle:async(...e)=>{await x({filterNames:e,force:!0}),window.location.reload()}}},plugin:{displayName:"自动更新器 - 扩展功能",description:{"zh-CN":"记录在设置面板中的功能安装/卸载数据供自动更新使用; 并在组件详情中支持手动检查该组件的更新."},setup:({addData:e,addHook:t})=>{["components","plugins","styles"].forEach((e=>{t(`user${lodash.startCase(e)}.add`,{after:(t,n,i)=>{const{options:a}=(0,f.getComponentSettings)("autoUpdate"),r=a.urls[e][i.name];r?(r.url=n,r.lastUpdateCheck=Number(new Date),r.alwaysUpdate=v(n)):a.urls[e][i.name]={url:n,lastUpdateCheck:Number(new Date),installTime:Number(new Date),alwaysUpdate:v(n)}}}),t(`user${lodash.startCase(e)}.remove`,{after:t=>{const{options:n}=(0,f.getComponentSettings)("autoUpdate");n.urls[e][t.name]&&delete n.urls[e][t.name]}})})),e("settingsPanel.componentActions",(e=>{const{options:t}=(0,f.getComponentSettings)("autoUpdate");e.push((e=>{const i=t.urls.components[e.name];if(i)return{name:"checkUpdate",displayName:"检查更新",icon:v(i.url)?"mdi-file-download-outline":"mdi-cloud-download-outline",condition:()=>(0,f.isUserComponent)(e),title:i.url,action:async()=>{const{Toast:t}=await Promise.resolve().then(n.bind(n,3446)),i=t.info("检查更新中...","检查更新"),a=await y({filterNames:[e.name],force:!0});i.message=a,i.duration=3e3}}}))}))}}},k=()=>[i.component,s,h,_]},6087:function(e,t,n){"use strict";n.r(t),n.d(t,{componentsMap:function(){return l},components:function(){return c},importComponent:function(){return f},loadComponent:function(){return m},loadAllUserComponents:function(){return g},loadAllComponents:function(){return v},componentsTags:function(){return s.t}});var i=n(7724),a=n(5527),r=n(4327),o=n(4363),s=n(9925);const l={},c=lodash.once((()=>{const e=(0,o.Z)();return e.forEach((e=>l[e.name]=e)),e}))(),d=async e=>{if(!e.i18n)return;const{addI18nData:t}=await Promise.resolve().then(n.bind(n,1416));Object.entries(e.i18n).forEach((([e,n])=>{const{map:i=[],regex:a=[]}=n;t(e,i,a)}))},u=e=>`${e.name}.widget`,p=async e=>{if(e.widget){const t={...e.widget,name:u(e)},{addData:i}=await Promise.resolve().then(n.bind(n,9207)),{WidgetsPlugin:a}=await Promise.resolve().then(n.bind(n,9659));i(a,(n=>{if(n.find((e=>e.name===t.name)))return;const{urlInclude:i,urlExclude:a}=t;e.urlInclude&&(i?i.push(...e.urlInclude):t.urlInclude=[...e.urlInclude]),e.urlExclude&&(a?a.push(...e.urlExclude):t.urlExclude=[...e.urlExclude]),n.push(t)}))}},h={},f=e=>{if(!(e in h))throw new Error(`组件'${e}'未加载, 请确认拼写无误且组件已开启.`);return h[e]},m=async e=>{const{componentLoadTrace:t}=await Promise.resolve().then(n.bind(n,2428)),{matchUrlPattern:a}=await Promise.resolve().then(n.bind(n,4742)),{coreApis:r}=await Promise.resolve().then(n.bind(n,5842));await t(e);const o=async()=>{p(e);const t=await e.entry({settings:(0,i.getComponentSettings)(e),metadata:e,coreApis:r});h[e.name]=t||{}};e.reload&&e.unload&&(0,i.addComponentListener)(e.name,(async t=>{if(!1!==e.configurable&&!(e.urlExclude&&e.urlExclude.some(a)||e.urlInclude&&e.urlInclude.every(lodash.negate(a))))if(e.name in h){if(t&&e.reload&&(e.reload(),e.widget&&p(e)),!t&&e.unload&&(e.unload(),e.widget)){const{getData:t}=await Promise.resolve().then(n.bind(n,9207)),{WidgetsPlugin:i}=await Promise.resolve().then(n.bind(n,9659)),[a]=t(i);if(a){const t=u(e),n=a.findIndex((e=>e.name===t));-1!==n&&a.splice(n,1)}}}else t&&await o()})),(0,i.isComponentEnabled)(e)&&await o()},g=async()=>{const{settings:e}=await Promise.resolve().then(n.bind(n,7724)),{batchParseCode:t}=await Promise.resolve().then(n.bind(n,6522));(await t(Object.values(e.userComponents).map((e=>e.code)))).forEach((e=>{c.push(e),l[e.name]=e}))},v=async()=>{const e=(0,i.getGeneralSettings)(),{loadAllPlugins:t}=await Promise.resolve().then(n.bind(n,3865)),o=()=>t(c).then((()=>Promise.allSettled(c.map(d)))).then((()=>Promise.allSettled(c.map(m)))).then((async()=>{if(e.devMode){const{componentLoadTime:e,componentResolveTime:t}=await Promise.resolve().then(n.bind(n,2428)),{logStats:i}=await Promise.resolve().then(n.bind(n,9821));i("components block",e),i("components resolve",t)}}));return new Promise((t=>{e.scriptLoadingMode===r.LoadingMode.Delay?(0,a.fullyLoaded)((()=>o().then(t))):e.scriptLoadingMode===r.LoadingMode.Race&&(0,a.contentLoaded)((()=>o().then(t)))}))}},8774:function(e,t,n){"use strict";n.r(t),n.d(t,{getDescriptionMarkdown:function(){return s},getDescriptionHTML:function(){return l},getDescriptionText:function(){return c}});var i=n(5890),a=n(7084),r=n.n(a),o=n(1416);const s=e=>{const{description:t,author:n}=e;return(n?Array.isArray(n)?`by ${n.map((e=>`[@${e.name}](${e.link})`)).join(",")}\n\n`:`by [@${n.name}](${n.link})\n\n`:"")+(t?"string"==typeof t?t:t[(0,i.languageNameToCode)((0,o.getSelectedLanguage)())]||t["zh-CN"]:"暂无描述.")},l=e=>r()(s(e)),c=e=>{const t=l(e),n=document.createElement("div");return n.innerHTML=t,n.innerText}},1416:function(e,t,n){"use strict";n.r(t),n.d(t,{addI18nData:function(){return o},getSelectedLanguage:function(){return s}});var i=n(9207),a=n(7724),r=n(5890);const o=(e,t,n)=>{(0,i.addData)(`i18n.${e}`,((e,i)=>{t?.forEach((([t,n])=>e.set(t,n))),n&&i.push(...n)}))},s=()=>{const e=(0,a.getComponentSettings)("i18n");return(0,r.languageNameToCode)(e.options.language)}},8494:function(e,t,n){"use strict";n.d(t,{WK:function(){return p},U6:function(){return h},Ty:function(){return f}});var i=n(6773),a=n(1290),r=n(7724),o=n(5890),s=n(9207),l=n(4742);function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class d{constructor(){c(this,"name",void 0),c(this,"link",void 0),c(this,"defaultLanguage",void 0)}getTargetLanguage(){const e=(0,r.getComponentSettings)("i18n");return e.enabled?(0,o.languageNameToCode)(e.options.language):this.defaultLanguage}toString(){return this.name}}class u extends d{constructor(...e){super(...e),c(this,"name","Google"),c(this,"link","https://translate.google.com/"),c(this,"defaultLanguage","zh"),c(this,"apiUrl","https://translate.google.com/translate_a/single")}async translate(e){let t=this.getTargetLanguage();t.includes("-")&&t!==this.defaultLanguage&&(t=t.substring(0,t.indexOf("-")));try{const n=await(0,i.monkey)({url:`${this.apiUrl}?${(0,l.formData)({client:"gtx",sl:"auto",tl:t,dt:"t",q:encodeURIComponent(e)})}`,method:"GET",headers:{"User-Agent":a.UserAgent},responseType:"json"});return n[0].map((e=>e[0])).join("")}catch(e){throw console.error("Translator: Google",e),new Error("调用Google翻译失败.")}}}const[p]=(0,s.registerAndGetData)("i18n.machineTranslators",{GoogleCN:new class extends u{constructor(...e){super(...e),c(this,"name","GoogleCN"),c(this,"link","https://translate.google.cn/"),c(this,"apiUrl","https://translate.google.cn/translate_a/single")}},Google:new u}),h=Object.keys(p),f=()=>{const{options:{translator:e}}=(0,r.getComponentSettings)("i18n");return p[e]||p.GoogleCN}},5110:function(e,t,n){"use strict";n.d(t,{WY:function(){return a},dr:function(){return r}});const i=(e="search_history")=>{const t=localStorage.getItem(e);return t?JSON.parse(t):[]},a=(e,t="search_history")=>{console.log("add",e),localStorage.setItem(t,JSON.stringify(lodash.sortBy(lodash.uniqBy([{value:e,isHistory:1,timestamp:Number(new Date)},...i()],(e=>e.value)),(e=>e.timestamp)).reverse().slice(0,12)))},r={name:"history",getActions:async()=>{const{search:e}=await Promise.resolve().then(n.bind(n,7855)),t={name:"清除搜索历史",icon:"mdi-trash-can-outline",description:"Clear History",explicitSelect:!0,action:()=>{((e="search_history")=>{localStorage.setItem(e,"[]")})()}},a=i().map((t=>({name:t.value,icon:"mdi-history",explicitSelect:!0,action:()=>{e(t.value)},deleteAction:()=>{((e,t="search_history")=>{const n=i(),a=n.findIndex((t=>t.value===e));console.log("delete",e,a),-1!==a&&(n.splice(a,1),localStorage.setItem(t,JSON.stringify(n)))})(t.value)}})));return a.length>0&&a.push(t),a}}},9932:function(e,t,n){"use strict";n.r(t),n.d(t,{LaunchBarActionProviders:function(){return i}});const i="launchBar.actions"},7855:function(e,t,n){"use strict";n.r(t),n.d(t,{search:function(){return o},searchProvider:function(){return s}});var i=n(4742),a=n(6773),r=n(5110);const o=e=>{if(!e)return;(0,r.WY)(e);const t={keyword:e,from_source:"nav_suggest_new"};window.open(`https://search.bilibili.com/all?${(0,i.formData)(t)}`,"_blank")},s={name:"search",getActions:async e=>{const t=`https://s.search.bilibili.com/main/suggest?func=suggest&suggest_type=accurate&sub_type=tag&main_ver=v1&highlight=&userid=${(0,i.getUID)()}&bangumi_acc_num=1&special_acc_num=1&topic_acc_num=1&upuser_acc_num=3&tag_num=10&special_num=10&bangumi_num=10&upuser_num=3&term=${e}`,n=await(0,a.getJson)(t);if(0!==n.code)return[];const r=lodash.get(n,"result.tag");return r?r.map((e=>({name:e.value,explicitSelect:!0,icon:"search",content:async()=>Vue.extend({render:t=>t("div",{domProps:{innerHTML:e.name.replace(/suggest_high_light/g,"suggest-highlight")}})}),action:()=>o(e.value)}))):[]}}},218:function(e,t,n){"use strict";n.r(t),n.d(t,{toggleLaunchBar:function(){return g}});var i=n(4742),a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("VPopup",{staticClass:"global-launch-bar-container",attrs:{lazy:!1,fixed:""},on:{"!keydown":function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"esc",27,t.key,["Esc","Escape"])?null:e.close()}},model:{value:e.show,callback:function(t){e.show=t},expression:"show"}},[n("LaunchBar",{ref:"launchBar"})],1)};a._withStripped=!0;var r=n(9114),o=n(8805),s=Vue.extend({components:{LaunchBar:o.Z,VPopup:r.default},data:()=>({show:!0}),watch:{show(e){e&&this.focus()}},async mounted(){await this.$nextTick(),this.focus()},methods:{focus(){const e=this.$refs.launchBar?.$refs.input;e?.focus(),e?.select()},close(){this.show=!1;this.$refs.launchBar?.$refs.input?.blur()}}}),l=n(3379),c=n.n(l),d=n(4078),u=n.n(d),p={insert:"head",singleton:!1},h=(c()(u(),p),u().locals,(0,n(1900).Z)(s,a,[],!1,null,null,null));h.options.__file="src/components/launch-bar/GlobalLaunchBar.vue";var f=h.exports;let m;const g=()=>{if(!m)return m=(0,i.mountVueComponent)(f),void document.body.append(m.$el);m.show=!m.show}},9659:function(e,t,n){"use strict";n.r(t),n.d(t,{SettingsPanelDockSide:function(){return h},WidgetsPlugin:function(){return p},component:function(){return f}});var i=n(4742),a=n(4327),r=n(4659),o=n(4011),s=n(7724),l=n(595),c=n(9925),d=n(9207),u=n(9932);const p="widgets";let h;!function(e){e.Left="左侧",e.Right="右侧"}(h||(h={}));const f={name:"settingsPanel",displayName:"通用设置",configurable:!1,entry:async({metadata:e})=>{const{isIframe:t}=await Promise.resolve().then(n.bind(n,4742));t()||((0,s.addComponentListener)(`${e.name}.dockSide`,(e=>{document.body.classList.toggle("settings-panel-dock-right",e===h.Right)}),!0),requestIdleCallback((async()=>{const e=await Promise.resolve().then(n.bind(n,1020)),t=(0,i.mountVueComponent)(e);document.body.insertAdjacentElement("beforeend",t.$el)})))},options:{themeColor:{defaultValue:"#00A0D8",displayName:"主题颜色",color:!0},scriptLoadingMode:{defaultValue:a.LoadingMode.Delay,displayName:"功能加载模式",dropdownEnum:a.LoadingMode},styleLoadingMode:{defaultValue:a.LoadingMode.Race,displayName:"样式加载模式",dropdownEnum:a.LoadingMode},textColor:{defaultValue:r.TextColor.Auto,displayName:"文本颜色",dropdownEnum:r.TextColor},cdnRoot:{defaultValue:o.CdnTypes.jsDelivr,displayName:"更新源",dropdownEnum:o.CdnTypes},dockSide:{defaultValue:h.Left,displayName:"设置面板停靠",dropdownEnum:h},filenameFormat:{defaultValue:"[title][ - ep]",displayName:"文件命名格式"},batchFilenameFormat:{defaultValue:"[n - ][ep]",displayName:"批量命名格式"},downloadPackageEmitMode:{defaultValue:l.h.packed,displayName:"文件下载模式",dropdownEnum:l.h},devMode:{defaultValue:!1,displayName:"开发者模式"}},tags:[c.t.general],i18n:{"en-US":{map:[["通用设置","General"],["实验性","Experimental"],["通用","General"],["开发者模式","Dev mode"],["辅助颜色","Accent color"],["功能加载模式","Script loading mode"],["样式加载模式","Style loading mode"]]}},plugin:{displayName:"设置面板 - 功能扩展",setup:()=>{(0,d.addData)(u.LaunchBarActionProviders,(e=>{e.push({name:"onlineRegistry",getActions:async()=>[{name:"切换在线仓库",description:"Toggle Online Registry",icon:"mdi-web",action:async()=>{const{togglePopup:e}=await Promise.resolve().then(n.bind(n,1778));e()}}]})}))}}}},1536:function(e,t,n){"use strict";n.d(t,{U:function(){return a},B:function(){return r}});var i=n(7724);const a=Vue.extend({props:{componentData:{type:Object,required:!0}},data(){return{settings:(0,i.getComponentSettings)(this.componentData)}}}),r=e=>Vue.extend({data:()=>({virtual:!1}),async mounted(){const{dq:t}=await Promise.resolve().then(n.bind(n,4742)),{visibleInside:i}=await Promise.resolve().then(n.bind(n,9017)),a=this.$el,r=t(e);r?i(a,r,"150% 0px",(e=>{e.forEach((e=>{this.virtual=!e.isIntersecting}))})):console.warn("virtual container not found, virtual scroll will be disabled!")}})},1778:function(e,t,n){"use strict";n.r(t),n.d(t,{initPopup:function(){return P},togglePopup:function(){return D}});var i=n(4742),a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("VPopup",{staticClass:"online-registry",attrs:{fixed:"","auto-close":!1},model:{value:e.popupOpen,callback:function(t){e.popupOpen=t},expression:"popupOpen"}},[n("div",{staticClass:"online-registry-header"},[n("VIcon",{staticClass:"online-registry-header-title-icon",attrs:{icon:"mdi-web"}}),e._v(" "),n("div",{staticClass:"online-registry-header-title"},[e._v("\n 在线仓库\n ")]),e._v(" "),n("div",{staticClass:"online-registry-header-search"},[n("VIcon",{attrs:{icon:"search",size:18}}),e._v(" "),n("TextBox",{attrs:{placeholder:"搜索功能"},model:{value:e.searchKeyword,callback:function(t){e.searchKeyword=t},expression:"searchKeyword"}})],1),e._v(" "),n("VIcon",{staticClass:"online-registry-header-refresh-icon",attrs:{icon:"mdi-refresh",size:22,title:"刷新"},on:{click:function(t){return e.fetchFeatures()}}}),e._v(" "),n("VIcon",{staticClass:"online-registry-header-close-icon",attrs:{icon:"close",size:18,title:"关闭"},on:{click:function(t){e.popupOpen=!1}}})],1),e._v(" "),n("div",{staticClass:"online-registry-separator"}),e._v(" "),n("div",{ref:"content",staticClass:"online-registry-content"},[e.loading?n("VLoading"):e._e(),e._v(" "),e.loading||e.list.length?e._e():n("VEmpty"),e._v(" "),e._l(e.filteredList,(function(e){return n("RegistryItem",{key:e.name,attrs:{item:e}})}))],2)])};a._withStripped=!0;var r=n(6773),o=n(4011),s=n(7601),l=n(7724),c=n(4496),d=n(9759),u=n(125),p=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("MiniToast",{staticClass:"online-registry-item-wrapper",class:{virtual:e.virtual},attrs:{placement:"right",container:"body",delay:[200,0],offset:[0,12]},scopedSlots:e._u([{key:"toast",fn:function(){return[e.description?n("div",{staticClass:"online-registry-description",domProps:{innerHTML:e._s(e.description)}}):e._e()]},proxy:!0}])},[e.virtual?e._e():n("div",{staticClass:"online-registry-item"},[n("VIcon",{staticClass:"item-icon",attrs:{size:18,icon:e.icon}}),e._v(" "),n("div",{staticClass:"item-badge"},[e._v("\n "+e._s(e.badge)+"\n ")]),e._v(" "),n("div",{staticClass:"item-display-name"},[e._v("\n "+e._s(e.item.displayName)+"\n ")]),e._v(" "),n("div",{staticClass:"grow"}),e._v(" "),n("div",{staticClass:"item-action"},[e.installed?n("VButton",{staticClass:"reinstall-button",attrs:{title:"重新安装",disabled:e.installing},on:{click:function(t){e.install(e.getUrl(e.item))}}},[e._v("\n "+e._s(e.installing?"正在安装":"已安装")+"\n ")]):n("VButton",{staticClass:"install-button",attrs:{title:"安装",type:"primary",disabled:e.installing},on:{click:function(t){e.install(e.getUrl(e.item))}}},[n("VIcon",{attrs:{icon:"mdi-plus",size:15}}),e._v("\n "+e._s(e.installing?"正在安装":"安装")+"\n ")],1)],1)],1)])};p._withStripped=!0;var h=n(8774),f=n(3575),m=n(9017);const g=e=>`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch,e.owner)}${e.fullAbsolutePath}`,v=e=>{const t=`user${lodash.startCase(e.type)}s`;return e.name in l.settings[t]},b={component:{icon:"mdi-cube-scan",badge:"组件",getUrl:g,isInstalled:v},plugin:{icon:"mdi-puzzle-outline",badge:"插件",getUrl:g,isInstalled:v},style:{icon:"mdi-tune",badge:"样式",getUrl:g,isInstalled:v},pack:{icon:"mdi-package-variant-closed",badge:"合集包",getUrl:e=>e.items.map(g).join("\n"),isInstalled:e=>e.items.every(v)}};var y=Vue.extend({components:{VIcon:d.VIcon,VButton:d.VButton,MiniToast:d.MiniToast},props:{item:{type:Object,required:!0}},data(){return{typeMappings:b,...b[this.item.type],description:(0,h.getDescriptionHTML)(this.item),installing:!1,installed:!1,virtual:!1}},created(){this.checkInstalled()},mounted(){const e=this.$el;(0,m.visibleInside)(e,e.parentElement,"150% 0px",(e=>{e.forEach((e=>{this.virtual=!e.isIntersecting}))}))},methods:{checkInstalled(){this.installed=this.isInstalled(this.item)},async install(e){const t=e.split("\n").map((e=>e.trim())).filter((e=>""!==e));try{this.installing=!0,await Promise.all(t.map((async e=>(0,f.m)(e)))),this.checkInstalled()}catch(e){(0,c.logError)(e)}finally{this.installing=!1}}}}),w=n(3379),x=n.n(w),_=n(6891),k=n.n(_),C={insert:"head",singleton:!1},S=(x()(k(),C),k().locals,n(1900)),E=(0,S.Z)(y,p,[],!1,null,null,null);E.options.__file="src/components/settings-panel/sub-pages/online-registry/RegistryItem.vue";var M=E.exports,z=Vue.extend({components:{VIcon:d.VIcon,TextBox:d.TextBox,VPopup:d.VPopup,RegistryItem:M,VLoading:d.VLoading,VEmpty:d.VEmpty},props:{open:{default:!1,type:Boolean}},data:()=>({searchKeyword:"",popupOpen:!1,loading:!1,list:[],filteredList:[],fuse:null}),watch:{searchKeyword:lodash.debounce((function(e){if(!e)return void(this.filteredList=this.list);const t=this.fuse.search(e);this.filteredList=t.map((e=>e.item)),this.$nextTick().then((()=>this.$refs.content.scrollTo(0,0)))}),200)},mounted(){this.fetchFeatures()},methods:{async fetchFeatures(){if(!this.loading)try{this.loading=!0;const e=`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch)}doc/features/features.json`,t=`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch)}doc/features/pack/pack.json`,n=await(0,r.monkey)({url:e,responseType:"json"}),i=await(0,r.monkey)({url:t,responseType:"json"});this.list=[...i,...n],this.fuse=new u.Z(this.list,{keys:["displayName","name","description"]}),this.searchKeyword="",this.filteredList=[...this.list]}catch(e){(0,c.logError)(e)}finally{this.loading=!1}}}}),A=n(6860),$=n.n(A),O={insert:"head",singleton:!1},I=(x()($(),O),$().locals,(0,S.Z)(z,a,[],!1,null,null,null));I.options.__file="src/components/settings-panel/sub-pages/online-registry/OnlineRegistry.vue";var L=I.exports;let T;const P=()=>{T||(T=(0,i.mountVueComponent)(L),document.body.append(T.$el))},D=()=>{T||P(),T.popupOpen=!T.popupOpen}},9925:function(e,t,n){"use strict";n.d(t,{t:function(){return i}});const i={video:{name:"video",displayName:"视频",color:"#2196F3",icon:"mdi-play-circle-outline",order:1},style:{name:"style",displayName:"样式",color:"#8BC34A",icon:"mdi-palette-outline",order:2},feeds:{name:"feeds",displayName:"动态",color:"#00ACC1",icon:"mdi-pinwheel-outline",order:3},live:{name:"live",displayName:"直播",color:"#26A69A",icon:"mdi-video-wireless-outline",order:4},utils:{name:"utils",displayName:"工具",color:"#A36FFD",icon:"mdi-rocket-launch-outline",order:5},touch:{name:"touch",displayName:"触摸",color:"#78909C",icon:"mdi-gesture-tap-button",order:6},experimental:{name:"experimental",displayName:"实验",color:"#FF5722",icon:"mdi-flask-outline",order:7},general:{name:"general",displayName:"通用",color:"#888",icon:"mdi-progress-wrench",order:8}}},559:function(e,t,n){"use strict";n.r(t),n.d(t,{installComponent:function(){return o},uninstallComponent:function(){return s},toggleComponent:function(){return l}});var i=n(7724),a=n(4363),r=n(6087);const o=async e=>{const{components:t}=await Promise.resolve().then(n.bind(n,6087)),{parseExternalInput:o}=await Promise.resolve().then(n.bind(n,6522)),s=await o(e);if(null===s)throw new Error("无效的组件代码");const{settings:l}=await Promise.resolve().then(n.bind(n,7724));if((0,a.Z)().some((e=>e.name===s.name)))throw new Error(`不能覆盖内置组件'${s.name}', 请更换名称`);const c={...lodash.omit(s,"entry","widget","instantStyles","reload","unload","plugin","urlInclude","urlExclude")},d=l.userComponents[s.name];return d?(d.code=e,d.metadata=c,d.settings=lodash.defaultsDeep(d.settings,(0,i.componentToSettings)(s)),{metadata:s,message:`已更新组件'${s.displayName}', 刷新后生效`}):(l.userComponents[s.name]={code:e,metadata:c,settings:(0,i.componentToSettings)(s)},t.push(s),r.componentsMap[s.name]=s,{metadata:s,message:`已安装组件'${s.displayName}', 刷新后生效`})},s=async e=>{const{settings:t}=await Promise.resolve().then(n.bind(n,7724)),{components:i}=await Promise.resolve().then(n.bind(n,6087)),a=Object.entries(t.userComponents).find((([t,{metadata:{displayName:n}}])=>t===e||n===e));if(!a)throw new Error(`没有找到与名称'${e}'相关联的组件`);const[o,{metadata:s,settings:l}]=a,c=i.findIndex((e=>e.name===o));if(-1!==c){const{instantStyles:e}=i[c];if(e){const{removeStyle:t}=await Promise.resolve().then(n.bind(n,9261));e.forEach((e=>t(e.name)))}l.enabled=!1,i.splice(c,1),delete r.componentsMap[o]}return delete t.userComponents[o],{metadata:s,message:`已卸载组件'${s.displayName}, 刷新后生效'`}},l=async e=>{const{settings:t}=await Promise.resolve().then(n.bind(n,7724)),i=Object.entries(t.userComponents).find((([t,{metadata:{displayName:n}}])=>t===e||n===e));if(!i)throw new Error(`没有找到与名称'${e}'相关联的组件`);const[,a]=i;a.settings.enabled=!a.settings.enabled;const{enabled:r}=a.settings,{displayName:o}=a.metadata;return`已${r?"开启":"关闭"}组件'${o}', 可能需要刷新后才能生效`}},4350:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{updateCategories:function(){return updateCategories},updateIcons:function(){return updateIcons}});var _core_ajax__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(6773),_core_download__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(9356);const updateCategories=async()=>{const[script]=dqa("script").filter((e=>e.src.includes("international-home/international-home")));if(!script)throw new Error("no script found");const scriptText=await(0,_core_ajax__WEBPACK_IMPORTED_MODULE_1__.getText)(script.src),match=scriptText.match(/([\w]+?=\[\{name:"首页".+?\}.+?\]),[\w]+?=\[\{name:"首頁"/);if(!match)throw new Error("no match in script");const variables=match[1].match(/(\w+?)(?==\[)/g),data=eval(`var ${match[1]}; [${variables.join(",")}]`);_core_download__WEBPACK_IMPORTED_MODULE_0__.DownloadPackage.single("raw.json",data)},updateIcons=()=>{const e=dqa("body > svg:not(#be-category-icons)").filter((e=>e.querySelector("[id^=bili]")));if(0===e.length)throw new Error("svg icons not found");const[t]=e,n=t.cloneNode(!0);n.id="be-category-icons",dqa(n,"symbol").forEach((e=>{e.id=e.id.replace(/^bili-/,"header-icon-")})),_core_download__WEBPACK_IMPORTED_MODULE_0__.DownloadPackage.single("icons.svg",n.outerHTML)}},1479:function(e,t,n){"use strict";n.r(t),n.d(t,{bpxPlayerPolyfill:function(){return o}});var i=n(9017),a=n(4402),r=n(4742);const o=lodash.once((async()=>{document.URL.startsWith("https://www.bilibili.com/bangumi/play/")&&((async()=>{const e=await(0,a.select)(".bpx-player-container");e?(0,i.attributes)(e,(()=>{const t=e.getAttribute("data-screen");document.body.classList.toggle("player-mode-webfullscreen","full"===t||"web"===t),"wide"===t&&document.body.classList.add("player-mode-widescreen")})):console.warn("[bpx player polyfill] bpxContainer not found")})(),(async()=>{const e=await(0,a.select)((()=>unsafeWindow.$pbp));if(!e)return void console.warn("[bpx player polyfill] pbp not found");const t={aid:e.options.aid.toString(),cid:e.options.cid.toString(),bvid:e.options.bvid};Object.values(t).some((e=>""===e||parseInt(e)<=0))&&console.warn("[bpx player polyfill] invalid pbp data"),Object.assign(unsafeWindow,t)})(),(async()=>{const e=await(0,a.select)(".bpx-player-video-perch");e&&(0,r.preventEvent)(e,"dblclick")})())}))},4572:function(e,t,n){"use strict";n.r(t),n.d(t,{PlayerAgent:function(){return u},VideoPlayerAgent:function(){return p},BwpPlayerAgent:function(){return h},BangumiPlayerAgent:function(){return f},playerAgent:function(){return m}});var i=n(4402),a=n(4742),r=n(6363),o=n(1479);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const l=e=>{const t=()=>(0,i.select)(e);return t.selector=e,t.sync=()=>dq(e),t},c=e=>{const t=e=>"string"!=typeof e?lodash.mapValues(e,t):l(e);return lodash.mapValues(e,t)},d=e=>{const t=e.sync();return t?.click(),t};class u{constructor(){s(this,"type",void 0),s(this,"query",void 0)}provideCustomQuery(e){const t=c(e[this.type]??e.video);return{...this,custom:t}}widescreen(){return d(this.query.control.buttons.widescreen)}webFullscreen(){return d(this.query.control.buttons.webFullscreen)}fullscreen(){return d(this.query.control.buttons.fullscreen)}togglePlay(){return d(this.query.control.buttons.start)}togglePip(){return d(this.query.control.buttons.pip)}toggleMute(){return d(this.query.control.buttons.volume)}toggleDanmaku(){const e=this.query.danmakuSwitch.sync();return e?(e.checked=!e.checked,(0,a.raiseEvent)(e,"change"),e.checked):null}}class p extends u{constructor(...e){super(...e),s(this,"type","video"),s(this,"query",c({playerWrap:".player-wrap",bilibiliPlayer:".bilibili-player",playerArea:".bilibili-player-area",video:{element:".bilibili-player-video video",wrap:".bilibili-player-video-wrap",top:".bilibili-player-video-top",state:".bilibili-player-video-state",panel:".bilibili-player-video-panel",popup:".bilibili-player-video-popup",subtitle:".bilibili-player-video-subtitle",basDanmaku:".bilibili-player-video-bas-danmaku",advDanmaku:".bilibili-player-video-adv-danmaku",danmaku:".bilibili-player-video-danmaku",container:".bilibili-player-video"},control:{element:".bilibili-player-control",wrap:".bilibili-player-control-wrap",mask:".bilibili-player-control-mask",top:".bilibili-player-control-top",progress:".bilibili-player-video-progress",bottom:".bilibili-player-control-bottom",bottomLeft:".bilibili-player-control-bottom-left",bottomCenter:".bilibili-player-control-bottom-center",bottomRight:".bilibili-player-control-bottom-right",buttons:{start:".bilibili-player-video-btn-start",next:".bilibili-player-video-btn-next",time:".bilibili-player-video-time",quality:".bilibili-player-btn-quality",pageList:".bilibili-player-video-btn-pagelist",speed:".bilibili-player-video-btn-speed",subtitle:".bilibili-player-video-btn-subtitle",volume:".bilibili-player-video-btn-volume .bilibili-player-iconfont-volume",settings:".bilibili-player-video-btn-setting",pip:".bilibili-player-video-btn-pip",widescreen:".bilibili-player-video-btn-widescreen",webFullscreen:".bilibili-player-video-web-fullscreen",fullscreen:".bilibili-player-video-btn-fullscreen"}},toastWrap:".bilibili-player-video-toast-wrp",danmakuTipLayer:".bilibili-player-dm-tip-wrap",danmakuSwitch:".bilibili-player-video-danmaku-switch input"}))} +NodeFilter.SHOW_TEXT|NodeFilter.SHOW_ELEMENT);let i=n.nextNode();for(;i;)t(i),i=n.nextNode()}static translate(e){if(e.nodeType===Node.TEXT_NODE)return void p.textNode.translate(e);const t=e=>{for(const t of p.sensitiveTranslators)t.accepts(e)&&t.translate(e)};t(e),p.walk(e,t)}static translateCssMatches(){const e=p.map.get("*");if(e)for(const{selector:t,text:n}of e){const e=document.querySelector(t);e&&[...e.childNodes].filter((e=>e.nodeType===Node.TEXT_NODE)).forEach((e=>e.nodeValue=n))}}}u(p,"textNode",void 0),u(p,"title",void 0),u(p,"placeholder",void 0),u(p,"sensitiveTranslators",void 0),u(p,"map",void 0),u(p,"regex",void 0);p.textNode=new class extends p{constructor(...e){super(...e),u(this,"accepts",(e=>e.nodeType===Node.TEXT_NODE)),u(this,"getElement",(e=>e.parentElement))}},p.title=new class extends p{constructor(...e){super(...e),u(this,"getValue",(e=>e.getAttribute("title"))),u(this,"setValue",((e,t)=>{e.setAttribute("title",t)}))}},p.placeholder=new class extends p{constructor(...e){super(...e),u(this,"getValue",(e=>e.getAttribute("placeholder"))),u(this,"setValue",((e,t)=>{e.setAttribute("placeholder",t)}))}},p.sensitiveTranslators=[p.textNode,p.title,p.placeholder];const h={name:"i18n",displayName:"多语言",configurable:!1,entry:async()=>{const{getSelectedLanguage:e}=await Promise.resolve().then(n.bind(n,1416)),t=e();if(t===l.defaultLanguageCode)return;const{registerAndGetData:i}=await Promise.resolve().then(n.bind(n,9207)),[a,r]=i(`i18n.${t}`,new Map,[]);console.log(t,a.size,r.length),0===a.size&&0===r.length||(document.documentElement.setAttribute("lang",t),p.map=a,p.regex=r,p.translate(document.body),p.translateCssMatches(),(0,d.allMutations)((e=>{e.forEach((e=>{"childList"===e.type?(e.addedNodes.length>0&&p.translateCssMatches(),e.addedNodes.forEach((e=>{p.translate(e)}))):"characterData"===e.type?p.textNode.translate(e.target):"attributes"===e.type&&("title"===e.attributeName?p.title.translate(e.target):"placeholder"===e.attributeName&&p.placeholder.translate(e.target))}))})))},tags:[r.t.utils,r.t.experimental,r.t.general],description:{"zh-CN":"安装其他语言包可以更换界面语言, 机器翻译选择可以设定其他一些功能如`动态翻译`, `评论翻译`使用的翻译器. 机器翻译的选择不影响界面语言."},options:{language:{defaultValue:l.languageCodeToName[l.defaultLanguageCode],displayName:"界面语言选择",dropdownEnum:l.languageCodeToName},translator:{defaultValue:Object.keys(c.WK)[0],displayName:"机器翻译选择",dropdownEnum:c.U6}}};var f=n(7724);const m=/^http:\/\/localhost/,g="autoUpdate",v=e=>m.test(e),b=async e=>{const{items:t,existPredicate:n,installer:i,filterNames:a=[],force:r=!1}=e,o=Number(new Date),{devMode:s}=(0,f.getGeneralSettings)(),{options:l}=(0,f.getComponentSettings)(g);Object.keys(t).filter((e=>!n(e))).forEach((e=>{delete t[e]}));return(await Promise.allSettled(Object.entries(t).filter((([e,t])=>(e=>0===a.length||a.includes(e))(e)&&Boolean(t.url))).map((async([e,n])=>{const{url:a,lastUpdateCheck:c,alwaysUpdate:d}=n;if(!(d&&s)&&o-c<=l.minimumDuration&&!r)return`[${e}] 未超过更新间隔期, 已跳过`;let u=a;m.test(a)&&l.localPortOverride&&(u=a.replace(/:(\d)+/,`:${l.localPortOverride}`));const p=await coreApis.ajax.monkey({url:u});if(!(e in t))return`[${e}] 已被卸载, 取消更新`;const{message:h}=await i(p);return n.lastUpdateCheck=Number(new Date),`[${e}] ${h}`})))).map(((e,n)=>{if("fulfilled"===e.status)return e.value;const i=e.reason?.message??e.reason.toString();return`[${Object.keys(t)[n]}] ${i}`})).join("\n").trim()},y=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{components:a}=i.urls,{installComponent:r}=await Promise.resolve().then(n.bind(n,559));return b({items:a,existPredicate:e=>void 0!==f.settings.userComponents[e],installer:r,filterNames:e,force:t})},w=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{plugins:a}=i.urls,{installPlugin:r}=await Promise.resolve().then(n.bind(n,3865));return b({items:a,existPredicate:e=>void 0!==f.settings.userPlugins[e],installer:r,filterNames:e,force:t})},x=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{styles:a}=i.urls,{installStyle:r}=await Promise.resolve().then(n.bind(n,1773));return b({items:a,existPredicate:e=>void 0!==f.settings.userStyles[e],installer:r,filterNames:e,force:t})},_={name:g,displayName:"自动更新器",description:{"zh-CN":"自动检查组件, 插件和样式的更新. (仅限从设置面板中安装的)"},tags:[r.t.utils],options:{lastUpdateCheck:{displayName:"最后检查更新日期",defaultValue:0,hidden:!0},localPortOverride:{displayName:"本地组件链接端口",defaultValue:"",hidden:!0},minimumDuration:{displayName:"更新间隔 (ms)",defaultValue:864e5},urls:{displayName:"更新链接",defaultValue:{components:{},plugins:{},styles:{}},hidden:!0}},entry:async({settings:{options:e}})=>{const t=Number(new Date)-e.lastUpdateCheck,n=async()=>{console.log("[自动更新器] 开始检查更新"),console.log(await y()||"暂无组件更新"),console.log(await w()||"暂无插件更新"),console.log(await x()||"暂无样式更新"),e.lastUpdateCheck=Number(new Date),console.log("[自动更新器] 完成更新检查")};return t>=e.minimumDuration&&coreApis.lifeCycle.fullyLoaded(n),{checkUpdates:n,checkUpdatesAndReload:async()=>{await n(),window.location.reload()},updateSingleComponent:async(...e)=>{await y({filterNames:e,force:!0}),window.location.reload()},updateSinglePlugin:async(...e)=>{await w({filterNames:e,force:!0}),window.location.reload()},updateSingleStyle:async(...e)=>{await x({filterNames:e,force:!0}),window.location.reload()}}},plugin:{displayName:"自动更新器 - 扩展功能",description:{"zh-CN":"记录在设置面板中的功能安装/卸载数据供自动更新使用; 并在组件详情中支持手动检查该组件的更新."},setup:({addData:e,addHook:t})=>{["components","plugins","styles"].forEach((e=>{t(`user${lodash.startCase(e)}.add`,{after:(t,n,i)=>{const{options:a}=(0,f.getComponentSettings)("autoUpdate"),r=a.urls[e][i.name];r?(r.url=n,r.lastUpdateCheck=Number(new Date),r.alwaysUpdate=v(n)):a.urls[e][i.name]={url:n,lastUpdateCheck:Number(new Date),installTime:Number(new Date),alwaysUpdate:v(n)}}}),t(`user${lodash.startCase(e)}.remove`,{after:t=>{const{options:n}=(0,f.getComponentSettings)("autoUpdate");n.urls[e][t.name]&&delete n.urls[e][t.name]}})})),e("settingsPanel.componentActions",(e=>{const{options:t}=(0,f.getComponentSettings)("autoUpdate");e.push((e=>{const i=t.urls.components[e.name];if(i)return{name:"checkUpdate",displayName:"检查更新",icon:v(i.url)?"mdi-file-download-outline":"mdi-cloud-download-outline",condition:()=>(0,f.isUserComponent)(e),title:i.url,action:async()=>{const{Toast:t}=await Promise.resolve().then(n.bind(n,3446)),i=t.info("检查更新中...","检查更新"),a=await y({filterNames:[e.name],force:!0});i.message=a,i.duration=3e3}}}))}))}}},k=()=>[i.component,s,h,_]},6087:function(e,t,n){"use strict";n.r(t),n.d(t,{componentsMap:function(){return l},components:function(){return c},importComponent:function(){return f},loadComponent:function(){return m},loadAllUserComponents:function(){return g},loadAllComponents:function(){return v},componentsTags:function(){return s.t}});var i=n(7724),a=n(5527),r=n(4327),o=n(4363),s=n(9925);const l={},c=lodash.once((()=>{const e=(0,o.Z)();return e.forEach((e=>l[e.name]=e)),e}))(),d=async e=>{if(!e.i18n)return;const{addI18nData:t}=await Promise.resolve().then(n.bind(n,1416));Object.entries(e.i18n).forEach((([e,n])=>{const{map:i=[],regex:a=[]}=n;t(e,i,a)}))},u=e=>`${e.name}.widget`,p=async e=>{if(e.widget){const t={...e.widget,name:u(e)},{addData:i}=await Promise.resolve().then(n.bind(n,9207)),{WidgetsPlugin:a}=await Promise.resolve().then(n.bind(n,9659));i(a,(n=>{if(n.find((e=>e.name===t.name)))return;const{urlInclude:i,urlExclude:a}=t;e.urlInclude&&(i?i.push(...e.urlInclude):t.urlInclude=[...e.urlInclude]),e.urlExclude&&(a?a.push(...e.urlExclude):t.urlExclude=[...e.urlExclude]),n.push(t)}))}},h={},f=e=>{if(!(e in h))throw new Error(`组件'${e}'未加载, 请确认拼写无误且组件已开启.`);return h[e]},m=async e=>{const{componentLoadTrace:t}=await Promise.resolve().then(n.bind(n,2428)),{matchUrlPattern:a}=await Promise.resolve().then(n.bind(n,4742)),{coreApis:r}=await Promise.resolve().then(n.bind(n,5842));await t(e);const o=async()=>{p(e);const t=await e.entry({settings:(0,i.getComponentSettings)(e),metadata:e,coreApis:r});h[e.name]=t||{}};e.reload&&e.unload&&(0,i.addComponentListener)(e.name,(async t=>{if(!1!==e.configurable&&!(e.urlExclude&&e.urlExclude.some(a)||e.urlInclude&&e.urlInclude.every(lodash.negate(a))))if(e.name in h){if(t&&e.reload&&(e.reload(),e.widget&&p(e)),!t&&e.unload&&(e.unload(),e.widget)){const{getData:t}=await Promise.resolve().then(n.bind(n,9207)),{WidgetsPlugin:i}=await Promise.resolve().then(n.bind(n,9659)),[a]=t(i);if(a){const t=u(e),n=a.findIndex((e=>e.name===t));-1!==n&&a.splice(n,1)}}}else t&&await o()})),(0,i.isComponentEnabled)(e)&&await o()},g=async()=>{const{settings:e}=await Promise.resolve().then(n.bind(n,7724)),{batchParseCode:t}=await Promise.resolve().then(n.bind(n,6522));(await t(Object.values(e.userComponents).map((e=>e.code)))).forEach((e=>{c.push(e),l[e.name]=e}))},v=async()=>{const e=(0,i.getGeneralSettings)(),{loadAllPlugins:t}=await Promise.resolve().then(n.bind(n,3865)),o=()=>t(c).then((()=>Promise.allSettled(c.map(d)))).then((()=>Promise.allSettled(c.map(m)))).then((async()=>{if(e.devMode){const{componentLoadTime:e,componentResolveTime:t}=await Promise.resolve().then(n.bind(n,2428)),{logStats:i}=await Promise.resolve().then(n.bind(n,9821));i("components block",e),i("components resolve",t)}}));return new Promise((t=>{e.scriptLoadingMode===r.LoadingMode.Delay?(0,a.fullyLoaded)((()=>o().then(t))):e.scriptLoadingMode===r.LoadingMode.Race&&(0,a.contentLoaded)((()=>o().then(t)))}))}},8774:function(e,t,n){"use strict";n.r(t),n.d(t,{getDescriptionMarkdown:function(){return s},getDescriptionHTML:function(){return l},getDescriptionText:function(){return c}});var i=n(5890),a=n(7084),r=n.n(a),o=n(1416);const s=e=>{const{description:t,author:n}=e;return(n?Array.isArray(n)?`by ${n.map((e=>`[@${e.name}](${e.link})`)).join(",")}\n\n`:`by [@${n.name}](${n.link})\n\n`:"")+(t?"string"==typeof t?t:t[(0,i.languageNameToCode)((0,o.getSelectedLanguage)())]||t["zh-CN"]:"暂无描述.")},l=e=>r()(s(e)),c=e=>{const t=l(e),n=document.createElement("div");return n.innerHTML=t,n.innerText}},1416:function(e,t,n){"use strict";n.r(t),n.d(t,{addI18nData:function(){return o},getSelectedLanguage:function(){return s}});var i=n(9207),a=n(7724),r=n(5890);const o=(e,t,n)=>{(0,i.addData)(`i18n.${e}`,((e,i)=>{t?.forEach((([t,n])=>e.set(t,n))),n&&i.push(...n)}))},s=()=>{const e=(0,a.getComponentSettings)("i18n");return(0,r.languageNameToCode)(e.options.language)}},8494:function(e,t,n){"use strict";n.d(t,{WK:function(){return p},U6:function(){return h},Ty:function(){return f}});var i=n(6773),a=n(1290),r=n(7724),o=n(5890),s=n(9207),l=n(4742);function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class d{constructor(){c(this,"name",void 0),c(this,"link",void 0),c(this,"defaultLanguage",void 0)}getTargetLanguage(){const e=(0,r.getComponentSettings)("i18n");return e.enabled?(0,o.languageNameToCode)(e.options.language):this.defaultLanguage}toString(){return this.name}}class u extends d{constructor(...e){super(...e),c(this,"name","Google"),c(this,"link","https://translate.google.com/"),c(this,"defaultLanguage","zh"),c(this,"apiUrl","https://translate.google.com/translate_a/single")}async translate(e){let t=this.getTargetLanguage();t.includes("-")&&t!==this.defaultLanguage&&(t=t.substring(0,t.indexOf("-")));try{const n=await(0,i.monkey)({url:`${this.apiUrl}?${(0,l.formData)({client:"gtx",sl:"auto",tl:t,dt:"t",q:encodeURIComponent(e)})}`,method:"GET",headers:{"User-Agent":a.UserAgent},responseType:"json"});return n[0].map((e=>e[0])).join("")}catch(e){throw console.error("Translator: Google",e),new Error("调用Google翻译失败.")}}}const[p]=(0,s.registerAndGetData)("i18n.machineTranslators",{GoogleCN:new class extends u{constructor(...e){super(...e),c(this,"name","GoogleCN"),c(this,"link","https://translate.google.cn/"),c(this,"apiUrl","https://translate.google.cn/translate_a/single")}},Google:new u}),h=Object.keys(p),f=()=>{const{options:{translator:e}}=(0,r.getComponentSettings)("i18n");return p[e]||p.GoogleCN}},5110:function(e,t,n){"use strict";n.d(t,{WY:function(){return a},dr:function(){return r}});const i=(e="search_history")=>{const t=localStorage.getItem(e);return t?JSON.parse(t):[]},a=(e,t="search_history")=>{console.log("add",e),localStorage.setItem(t,JSON.stringify(lodash.sortBy(lodash.uniqBy([{value:e,isHistory:1,timestamp:Number(new Date)},...i()],(e=>e.value)),(e=>e.timestamp)).reverse().slice(0,12)))},r={name:"history",getActions:async()=>{const{search:e}=await Promise.resolve().then(n.bind(n,7855)),t={name:"清除搜索历史",icon:"mdi-trash-can-outline",description:"Clear History",explicitSelect:!0,action:()=>{((e="search_history")=>{localStorage.setItem(e,"[]")})()}},a=i().map((t=>({name:t.value,icon:"mdi-history",explicitSelect:!0,action:()=>{e(t.value)},deleteAction:()=>{((e,t="search_history")=>{const n=i(),a=n.findIndex((t=>t.value===e));console.log("delete",e,a),-1!==a&&(n.splice(a,1),localStorage.setItem(t,JSON.stringify(n)))})(t.value)}})));return a.length>0&&a.push(t),a}}},9932:function(e,t,n){"use strict";n.r(t),n.d(t,{LaunchBarActionProviders:function(){return i}});const i="launchBar.actions"},7855:function(e,t,n){"use strict";n.r(t),n.d(t,{search:function(){return o},searchProvider:function(){return s}});var i=n(4742),a=n(6773),r=n(5110);const o=e=>{if(!e)return;(0,r.WY)(e);const t={keyword:e,from_source:"nav_suggest_new"};window.open(`https://search.bilibili.com/all?${(0,i.formData)(t)}`,"_blank")},s={name:"search",getActions:async e=>{const t=`https://s.search.bilibili.com/main/suggest?func=suggest&suggest_type=accurate&sub_type=tag&main_ver=v1&highlight=&userid=${(0,i.getUID)()}&bangumi_acc_num=1&special_acc_num=1&topic_acc_num=1&upuser_acc_num=3&tag_num=10&special_num=10&bangumi_num=10&upuser_num=3&term=${e}`,n=await(0,a.getJson)(t),r=[{name:e,icon:"search",content:async()=>Vue.extend({render:t=>t("div",{domProps:{innerHTML:`${e}`}})}),action:()=>o(e)}];if(0!==n.code)return r;const s=lodash.get(n,"result.tag");return s?(r.push(...s.map((e=>({name:e.value,icon:"search",content:async()=>Vue.extend({render:t=>t("div",{domProps:{innerHTML:e.name.replace(/suggest_high_light/g,"suggest-highlight")}})}),action:()=>o(e.value)})))),lodash.uniqBy(r,(e=>e.name))):r}}},218:function(e,t,n){"use strict";n.r(t),n.d(t,{toggleLaunchBar:function(){return g}});var i=n(4742),a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("VPopup",{staticClass:"global-launch-bar-container",attrs:{lazy:!1,fixed:""},on:{"!keydown":function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"esc",27,t.key,["Esc","Escape"])?null:e.close()}},model:{value:e.show,callback:function(t){e.show=t},expression:"show"}},[n("LaunchBar",{ref:"launchBar"})],1)};a._withStripped=!0;var r=n(9114),o=n(8805),s=Vue.extend({components:{LaunchBar:o.Z,VPopup:r.default},data:()=>({show:!0}),watch:{show(e){e&&this.focus()}},async mounted(){await this.$nextTick(),this.focus()},methods:{focus(){const e=this.$refs.launchBar?.$refs.input;e?.focus(),e?.select()},close(){this.show=!1;this.$refs.launchBar?.$refs.input?.blur()}}}),l=n(3379),c=n.n(l),d=n(4078),u=n.n(d),p={insert:"head",singleton:!1},h=(c()(u(),p),u().locals,(0,n(1900).Z)(s,a,[],!1,null,null,null));h.options.__file="src/components/launch-bar/GlobalLaunchBar.vue";var f=h.exports;let m;const g=()=>{if(!m)return m=(0,i.mountVueComponent)(f),void document.body.append(m.$el);m.show=!m.show}},9659:function(e,t,n){"use strict";n.r(t),n.d(t,{SettingsPanelDockSide:function(){return h},WidgetsPlugin:function(){return p},component:function(){return f}});var i=n(4742),a=n(4327),r=n(4659),o=n(4011),s=n(7724),l=n(595),c=n(9925),d=n(9207),u=n(9932);const p="widgets";let h;!function(e){e.Left="左侧",e.Right="右侧"}(h||(h={}));const f={name:"settingsPanel",displayName:"通用设置",configurable:!1,entry:async({metadata:e})=>{const{isIframe:t}=await Promise.resolve().then(n.bind(n,4742));t()||((0,s.addComponentListener)(`${e.name}.dockSide`,(e=>{document.body.classList.toggle("settings-panel-dock-right",e===h.Right)}),!0),requestIdleCallback((async()=>{const e=await Promise.resolve().then(n.bind(n,1020)),t=(0,i.mountVueComponent)(e);document.body.insertAdjacentElement("beforeend",t.$el)})))},options:{themeColor:{defaultValue:"#00A0D8",displayName:"主题颜色",color:!0},scriptLoadingMode:{defaultValue:a.LoadingMode.Delay,displayName:"功能加载模式",dropdownEnum:a.LoadingMode},styleLoadingMode:{defaultValue:a.LoadingMode.Race,displayName:"样式加载模式",dropdownEnum:a.LoadingMode},textColor:{defaultValue:r.TextColor.Auto,displayName:"文本颜色",dropdownEnum:r.TextColor},cdnRoot:{defaultValue:o.CdnTypes.jsDelivr,displayName:"更新源",dropdownEnum:o.CdnTypes},dockSide:{defaultValue:h.Left,displayName:"设置面板停靠",dropdownEnum:h},filenameFormat:{defaultValue:"[title][ - ep]",displayName:"文件命名格式"},batchFilenameFormat:{defaultValue:"[n - ][ep]",displayName:"批量命名格式"},downloadPackageEmitMode:{defaultValue:l.h.packed,displayName:"文件下载模式",dropdownEnum:l.h},devMode:{defaultValue:!1,displayName:"开发者模式"}},tags:[c.t.general],i18n:{"en-US":{map:[["通用设置","General"],["实验性","Experimental"],["通用","General"],["开发者模式","Dev mode"],["辅助颜色","Accent color"],["功能加载模式","Script loading mode"],["样式加载模式","Style loading mode"]]}},plugin:{displayName:"设置面板 - 功能扩展",setup:()=>{(0,d.addData)(u.LaunchBarActionProviders,(e=>{e.push({name:"onlineRegistry",getActions:async()=>[{name:"切换在线仓库",description:"Toggle Online Registry",icon:"mdi-web",action:async()=>{const{togglePopup:e}=await Promise.resolve().then(n.bind(n,1778));e()}}]})}))}}}},1536:function(e,t,n){"use strict";n.d(t,{U:function(){return a},B:function(){return r}});var i=n(7724);const a=Vue.extend({props:{componentData:{type:Object,required:!0}},data(){return{settings:(0,i.getComponentSettings)(this.componentData)}}}),r=e=>Vue.extend({data:()=>({virtual:!1}),async mounted(){const{dq:t}=await Promise.resolve().then(n.bind(n,4742)),{visibleInside:i}=await Promise.resolve().then(n.bind(n,9017)),a=this.$el,r=t(e);r?i(a,r,"150% 0px",(e=>{e.forEach((e=>{this.virtual=!e.isIntersecting}))})):console.warn("virtual container not found, virtual scroll will be disabled!")}})},1778:function(e,t,n){"use strict";n.r(t),n.d(t,{initPopup:function(){return P},togglePopup:function(){return D}});var i=n(4742),a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("VPopup",{staticClass:"online-registry",attrs:{fixed:"","auto-close":!1},model:{value:e.popupOpen,callback:function(t){e.popupOpen=t},expression:"popupOpen"}},[n("div",{staticClass:"online-registry-header"},[n("VIcon",{staticClass:"online-registry-header-title-icon",attrs:{icon:"mdi-web"}}),e._v(" "),n("div",{staticClass:"online-registry-header-title"},[e._v("\n 在线仓库\n ")]),e._v(" "),n("div",{staticClass:"online-registry-header-search"},[n("VIcon",{attrs:{icon:"search",size:18}}),e._v(" "),n("TextBox",{attrs:{placeholder:"搜索功能"},model:{value:e.searchKeyword,callback:function(t){e.searchKeyword=t},expression:"searchKeyword"}})],1),e._v(" "),n("VIcon",{staticClass:"online-registry-header-refresh-icon",attrs:{icon:"mdi-refresh",size:22,title:"刷新"},on:{click:function(t){return e.fetchFeatures()}}}),e._v(" "),n("VIcon",{staticClass:"online-registry-header-close-icon",attrs:{icon:"close",size:18,title:"关闭"},on:{click:function(t){e.popupOpen=!1}}})],1),e._v(" "),n("div",{staticClass:"online-registry-separator"}),e._v(" "),n("div",{ref:"content",staticClass:"online-registry-content"},[e.loading?n("VLoading"):e._e(),e._v(" "),e.loading||e.list.length?e._e():n("VEmpty"),e._v(" "),e._l(e.filteredList,(function(e){return n("RegistryItem",{key:e.name,attrs:{item:e}})}))],2)])};a._withStripped=!0;var r=n(6773),o=n(4011),s=n(7601),l=n(7724),c=n(4496),d=n(9759),u=n(125),p=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("MiniToast",{staticClass:"online-registry-item-wrapper",class:{virtual:e.virtual},attrs:{placement:"right",container:"body",delay:[200,0],offset:[0,12]},scopedSlots:e._u([{key:"toast",fn:function(){return[e.description?n("div",{staticClass:"online-registry-description",domProps:{innerHTML:e._s(e.description)}}):e._e()]},proxy:!0}])},[e.virtual?e._e():n("div",{staticClass:"online-registry-item"},[n("VIcon",{staticClass:"item-icon",attrs:{size:18,icon:e.icon}}),e._v(" "),n("div",{staticClass:"item-badge"},[e._v("\n "+e._s(e.badge)+"\n ")]),e._v(" "),n("div",{staticClass:"item-display-name"},[e._v("\n "+e._s(e.item.displayName)+"\n ")]),e._v(" "),n("div",{staticClass:"grow"}),e._v(" "),n("div",{staticClass:"item-action"},[e.installed?n("VButton",{staticClass:"reinstall-button",attrs:{title:"重新安装",disabled:e.installing},on:{click:function(t){e.install(e.getUrl(e.item))}}},[e._v("\n "+e._s(e.installing?"正在安装":"已安装")+"\n ")]):n("VButton",{staticClass:"install-button",attrs:{title:"安装",type:"primary",disabled:e.installing},on:{click:function(t){e.install(e.getUrl(e.item))}}},[n("VIcon",{attrs:{icon:"mdi-plus",size:15}}),e._v("\n "+e._s(e.installing?"正在安装":"安装")+"\n ")],1)],1)],1)])};p._withStripped=!0;var h=n(8774),f=n(3575),m=n(9017);const g=e=>`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch,e.owner)}${e.fullAbsolutePath}`,v=e=>{const t=`user${lodash.startCase(e.type)}s`;return e.name in l.settings[t]},b={component:{icon:"mdi-cube-scan",badge:"组件",getUrl:g,isInstalled:v},plugin:{icon:"mdi-puzzle-outline",badge:"插件",getUrl:g,isInstalled:v},style:{icon:"mdi-tune",badge:"样式",getUrl:g,isInstalled:v},pack:{icon:"mdi-package-variant-closed",badge:"合集包",getUrl:e=>e.items.map(g).join("\n"),isInstalled:e=>e.items.every(v)}};var y=Vue.extend({components:{VIcon:d.VIcon,VButton:d.VButton,MiniToast:d.MiniToast},props:{item:{type:Object,required:!0}},data(){return{typeMappings:b,...b[this.item.type],description:(0,h.getDescriptionHTML)(this.item),installing:!1,installed:!1,virtual:!1}},created(){this.checkInstalled()},mounted(){const e=this.$el;(0,m.visibleInside)(e,e.parentElement,"150% 0px",(e=>{e.forEach((e=>{this.virtual=!e.isIntersecting}))}))},methods:{checkInstalled(){this.installed=this.isInstalled(this.item)},async install(e){const t=e.split("\n").map((e=>e.trim())).filter((e=>""!==e));try{this.installing=!0,await Promise.all(t.map((async e=>(0,f.m)(e)))),this.checkInstalled()}catch(e){(0,c.logError)(e)}finally{this.installing=!1}}}}),w=n(3379),x=n.n(w),_=n(6891),k=n.n(_),C={insert:"head",singleton:!1},S=(x()(k(),C),k().locals,n(1900)),E=(0,S.Z)(y,p,[],!1,null,null,null);E.options.__file="src/components/settings-panel/sub-pages/online-registry/RegistryItem.vue";var M=E.exports,z=Vue.extend({components:{VIcon:d.VIcon,TextBox:d.TextBox,VPopup:d.VPopup,RegistryItem:M,VLoading:d.VLoading,VEmpty:d.VEmpty},props:{open:{default:!1,type:Boolean}},data:()=>({searchKeyword:"",popupOpen:!1,loading:!1,list:[],filteredList:[],fuse:null}),watch:{searchKeyword:lodash.debounce((function(e){if(!e)return void(this.filteredList=this.list);const t=this.fuse.search(e);this.filteredList=t.map((e=>e.item)),this.$nextTick().then((()=>this.$refs.content.scrollTo(0,0)))}),200)},mounted(){this.fetchFeatures()},methods:{async fetchFeatures(){if(!this.loading)try{this.loading=!0;const e=`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch)}doc/features/features.json`,t=`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch)}doc/features/pack/pack.json`,n=await(0,r.monkey)({url:e,responseType:"json"}),i=await(0,r.monkey)({url:t,responseType:"json"});this.list=[...i,...n],this.fuse=new u.Z(this.list,{keys:["displayName","name","description"]}),this.searchKeyword="",this.filteredList=[...this.list]}catch(e){(0,c.logError)(e)}finally{this.loading=!1}}}}),A=n(6860),$=n.n(A),O={insert:"head",singleton:!1},I=(x()($(),O),$().locals,(0,S.Z)(z,a,[],!1,null,null,null));I.options.__file="src/components/settings-panel/sub-pages/online-registry/OnlineRegistry.vue";var L=I.exports;let T;const P=()=>{T||(T=(0,i.mountVueComponent)(L),document.body.append(T.$el))},D=()=>{T||P(),T.popupOpen=!T.popupOpen}},9925:function(e,t,n){"use strict";n.d(t,{t:function(){return i}});const i={video:{name:"video",displayName:"视频",color:"#2196F3",icon:"mdi-play-circle-outline",order:1},style:{name:"style",displayName:"样式",color:"#8BC34A",icon:"mdi-palette-outline",order:2},feeds:{name:"feeds",displayName:"动态",color:"#00ACC1",icon:"mdi-pinwheel-outline",order:3},live:{name:"live",displayName:"直播",color:"#26A69A",icon:"mdi-video-wireless-outline",order:4},utils:{name:"utils",displayName:"工具",color:"#A36FFD",icon:"mdi-rocket-launch-outline",order:5},touch:{name:"touch",displayName:"触摸",color:"#78909C",icon:"mdi-gesture-tap-button",order:6},experimental:{name:"experimental",displayName:"实验",color:"#FF5722",icon:"mdi-flask-outline",order:7},general:{name:"general",displayName:"通用",color:"#888",icon:"mdi-progress-wrench",order:8}}},559:function(e,t,n){"use strict";n.r(t),n.d(t,{installComponent:function(){return o},uninstallComponent:function(){return s},toggleComponent:function(){return l}});var i=n(7724),a=n(4363),r=n(6087);const o=async e=>{const{components:t}=await Promise.resolve().then(n.bind(n,6087)),{parseExternalInput:o}=await Promise.resolve().then(n.bind(n,6522)),s=await o(e);if(null===s)throw new Error("无效的组件代码");const{settings:l}=await Promise.resolve().then(n.bind(n,7724));if((0,a.Z)().some((e=>e.name===s.name)))throw new Error(`不能覆盖内置组件'${s.name}', 请更换名称`);const c={...lodash.omit(s,"entry","widget","instantStyles","reload","unload","plugin","urlInclude","urlExclude")},d=l.userComponents[s.name];return d?(d.code=e,d.metadata=c,d.settings=lodash.defaultsDeep(d.settings,(0,i.componentToSettings)(s)),{metadata:s,message:`已更新组件'${s.displayName}', 刷新后生效`}):(l.userComponents[s.name]={code:e,metadata:c,settings:(0,i.componentToSettings)(s)},t.push(s),r.componentsMap[s.name]=s,{metadata:s,message:`已安装组件'${s.displayName}', 刷新后生效`})},s=async e=>{const{settings:t}=await Promise.resolve().then(n.bind(n,7724)),{components:i}=await Promise.resolve().then(n.bind(n,6087)),a=Object.entries(t.userComponents).find((([t,{metadata:{displayName:n}}])=>t===e||n===e));if(!a)throw new Error(`没有找到与名称'${e}'相关联的组件`);const[o,{metadata:s,settings:l}]=a,c=i.findIndex((e=>e.name===o));if(-1!==c){const{instantStyles:e}=i[c];if(e){const{removeStyle:t}=await Promise.resolve().then(n.bind(n,9261));e.forEach((e=>t(e.name)))}l.enabled=!1,i.splice(c,1),delete r.componentsMap[o]}return delete t.userComponents[o],{metadata:s,message:`已卸载组件'${s.displayName}, 刷新后生效'`}},l=async e=>{const{settings:t}=await Promise.resolve().then(n.bind(n,7724)),i=Object.entries(t.userComponents).find((([t,{metadata:{displayName:n}}])=>t===e||n===e));if(!i)throw new Error(`没有找到与名称'${e}'相关联的组件`);const[,a]=i;a.settings.enabled=!a.settings.enabled;const{enabled:r}=a.settings,{displayName:o}=a.metadata;return`已${r?"开启":"关闭"}组件'${o}', 可能需要刷新后才能生效`}},4350:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{updateCategories:function(){return updateCategories},updateIcons:function(){return updateIcons}});var _core_ajax__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(6773),_core_download__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(9356);const updateCategories=async()=>{const[script]=dqa("script").filter((e=>e.src.includes("international-home/international-home")));if(!script)throw new Error("no script found");const scriptText=await(0,_core_ajax__WEBPACK_IMPORTED_MODULE_1__.getText)(script.src),match=scriptText.match(/([\w]+?=\[\{name:"首页".+?\}.+?\]),[\w]+?=\[\{name:"首頁"/);if(!match)throw new Error("no match in script");const variables=match[1].match(/(\w+?)(?==\[)/g),data=eval(`var ${match[1]}; [${variables.join(",")}]`);_core_download__WEBPACK_IMPORTED_MODULE_0__.DownloadPackage.single("raw.json",data)},updateIcons=()=>{const e=dqa("body > svg:not(#be-category-icons)").filter((e=>e.querySelector("[id^=bili]")));if(0===e.length)throw new Error("svg icons not found");const[t]=e,n=t.cloneNode(!0);n.id="be-category-icons",dqa(n,"symbol").forEach((e=>{e.id=e.id.replace(/^bili-/,"header-icon-")})),_core_download__WEBPACK_IMPORTED_MODULE_0__.DownloadPackage.single("icons.svg",n.outerHTML)}},1479:function(e,t,n){"use strict";n.r(t),n.d(t,{bpxPlayerPolyfill:function(){return o}});var i=n(9017),a=n(4402),r=n(4742);const o=lodash.once((async()=>{document.URL.startsWith("https://www.bilibili.com/bangumi/play/")&&((async()=>{const e=await(0,a.select)(".bpx-player-container");e?(0,i.attributes)(e,(()=>{const t=e.getAttribute("data-screen");document.body.classList.toggle("player-mode-webfullscreen","full"===t||"web"===t),"wide"===t&&document.body.classList.add("player-mode-widescreen")})):console.warn("[bpx player polyfill] bpxContainer not found")})(),(async()=>{const e=await(0,a.select)((()=>unsafeWindow.$pbp));if(!e)return void console.warn("[bpx player polyfill] pbp not found");const t={aid:e.options.aid.toString(),cid:e.options.cid.toString(),bvid:e.options.bvid};Object.values(t).some((e=>""===e||parseInt(e)<=0))&&console.warn("[bpx player polyfill] invalid pbp data"),Object.assign(unsafeWindow,t)})(),(async()=>{const e=await(0,a.select)(".bpx-player-video-perch");e&&(0,r.preventEvent)(e,"dblclick")})())}))},4572:function(e,t,n){"use strict";n.r(t),n.d(t,{PlayerAgent:function(){return u},VideoPlayerAgent:function(){return p},BwpPlayerAgent:function(){return h},BangumiPlayerAgent:function(){return f},playerAgent:function(){return m}});var i=n(4402),a=n(4742),r=n(6363),o=n(1479);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const l=e=>{const t=()=>(0,i.select)(e);return t.selector=e,t.sync=()=>dq(e),t},c=e=>{const t=e=>"string"!=typeof e?lodash.mapValues(e,t):l(e);return lodash.mapValues(e,t)},d=e=>{const t=e.sync();return t?.click(),t};class u{constructor(){s(this,"type",void 0),s(this,"query",void 0)}provideCustomQuery(e){const t=c(e[this.type]??e.video);return{...this,custom:t}}widescreen(){return d(this.query.control.buttons.widescreen)}webFullscreen(){return d(this.query.control.buttons.webFullscreen)}fullscreen(){return d(this.query.control.buttons.fullscreen)}togglePlay(){return d(this.query.control.buttons.start)}togglePip(){return d(this.query.control.buttons.pip)}toggleMute(){return d(this.query.control.buttons.volume)}toggleDanmaku(){const e=this.query.danmakuSwitch.sync();return e?(e.checked=!e.checked,(0,a.raiseEvent)(e,"change"),e.checked):null}}class p extends u{constructor(...e){super(...e),s(this,"type","video"),s(this,"query",c({playerWrap:".player-wrap",bilibiliPlayer:".bilibili-player",playerArea:".bilibili-player-area",video:{element:".bilibili-player-video video",wrap:".bilibili-player-video-wrap",top:".bilibili-player-video-top",state:".bilibili-player-video-state",panel:".bilibili-player-video-panel",popup:".bilibili-player-video-popup",subtitle:".bilibili-player-video-subtitle",basDanmaku:".bilibili-player-video-bas-danmaku",advDanmaku:".bilibili-player-video-adv-danmaku",danmaku:".bilibili-player-video-danmaku",container:".bilibili-player-video"},control:{element:".bilibili-player-control",wrap:".bilibili-player-control-wrap",mask:".bilibili-player-control-mask",top:".bilibili-player-control-top",progress:".bilibili-player-video-progress",bottom:".bilibili-player-control-bottom",bottomLeft:".bilibili-player-control-bottom-left",bottomCenter:".bilibili-player-control-bottom-center",bottomRight:".bilibili-player-control-bottom-right",buttons:{start:".bilibili-player-video-btn-start",next:".bilibili-player-video-btn-next",time:".bilibili-player-video-time",quality:".bilibili-player-btn-quality",pageList:".bilibili-player-video-btn-pagelist",speed:".bilibili-player-video-btn-speed",subtitle:".bilibili-player-video-btn-subtitle",volume:".bilibili-player-video-btn-volume .bilibili-player-iconfont-volume",settings:".bilibili-player-video-btn-setting",pip:".bilibili-player-video-btn-pip",widescreen:".bilibili-player-video-btn-widescreen",webFullscreen:".bilibili-player-video-web-fullscreen",fullscreen:".bilibili-player-video-btn-fullscreen"}},toastWrap:".bilibili-player-video-toast-wrp",danmakuTipLayer:".bilibili-player-dm-tip-wrap",danmakuSwitch:".bilibili-player-video-danmaku-switch input"}))} // eslint-disable-next-line class-methods-use-this get nativeApi(){return unsafeWindow.player}isMute(){return this.nativeApi?this.nativeApi.isMute():null}changeVolume(e){if(!this.nativeApi)return null;const t=this.nativeApi.volume();return this.nativeApi.volume(t+e/100),Math.round(100*this.nativeApi.volume())}seek(e){return this.nativeApi?(this.nativeApi.play(),setTimeout((()=>{this.nativeApi.seek(e);const t=dq(".bilibili-player-video-toast-bottom .bilibili-player-video-toast-item:first-child .bilibili-player-video-toast-item-text span:nth-child(2)");t&&(t.textContent=" 00:00")})),this.nativeApi.getCurrentTime()):null}changeTime(e){if(!this.nativeApi)return null;const t=this.query.video.element.sync();return t?(this.nativeApi.seek(t.currentTime+e,t.paused),this.nativeApi.getCurrentTime()):null}}class h extends p{constructor(){super(),s(this,"type","bwp"),this.query.video.element=l(".bilibili-player-video bwp-video")}}class f extends u{constructor(){super(),s(this,"type","bangumi"),s(this,"query",c({playerWrap:".player-module",bilibiliPlayer:".bpx-player-container",playerArea:".bpx-player-primary-area",video:{element:".bpx-player-video-wrap video",wrap:".bpx-player-video-area",top:".bpx-player-top-wrap",state:".bpx-player-state-wrap",panel:".bpx-player-ending-panel",popup:".bpx-player-dialog-wrap",subtitle:".bpx-player-subtitle-wrap",basDanmaku:".bpx-player-bas-dm-wrap",advDanmaku:".bpx-player-adv-dm-wrap",danmaku:".bpx-player-row-dm-wrap",container:".bpx-player-video-wrap"},control:{element:".squirtle-controller",wrap:".bpx-player-control-wrap",mask:".bpx-player-control-mask",top:".bpx-player-control-top",progress:".squirtle-progress-wrap",bottom:".squirtle-controller-wrap",bottomLeft:".squirtle-controller-wrap-left",bottomCenter:".squirtle-controller-wrap-center",bottomRight:".squirtle-controller-wrap-right",buttons:{start:".squirtle-video-start",next:".squirtle-video-next",time:".squirtle-time-wrap",quality:".squirtle-video-quality",pageList:".squirtle-video-pagelist",speed:".squirtle-video-speed",subtitle:".squirtle-video-subtitle",volume:".squirtle-video-volume .squirtle-volume-icon",settings:".squirtle-video-setting",pip:".squirtle-video-pip",widescreen:".squirtle-video-widescreen",webFullscreen:".squirtle-video-pagefullscreen",fullscreen:".squirtle-video-fullscreen"}},toastWrap:".bpx-player-tooltip-area",danmakuTipLayer:".bpx-player-dialog-wrap",danmakuSwitch:".bpx-player-dm-switch input"})),(0,o.bpxPlayerPolyfill)()}isMute(){return this.query.control.buttons.volume.sync()?.classList.contains("squirtle-volume-mute-state")??!1}changeVolume(e){const t=this.query.video.element.sync();return t?(t.volume=lodash.clamp(t.volume+e/100,0,1),Math.round(100*t.volume)):null}seek(e){const t=this.query.video.element.sync();return t?(t.play(),setTimeout((()=>{t.currentTime=lodash.clamp(e,0,t.duration);const n=dq(".bpx-player-toast-row .bpx-player-toast-item .bpx-player-toast-text");n?.textContent?.startsWith("已为您定位至")&&(n.textContent="已为您定位至00:00")})),t.currentTime):null}changeTime(e){const t=this.query.video.element.sync();return t?(t.currentTime=lodash.clamp(t.currentTime+e,0,t.duration),t.currentTime):null}}const m=(0,r.matchCurrentPage)(r.bangumiUrls)?new f:(0,a.isBwpVideo)()?new h:new p},6773:function(e,t,n){"use strict";n.r(t),n.d(t,{getBlob:function(){return s},getBlobWithCredentials:function(){return l},getText:function(){return d},getTextWithCredentials:function(){return u},getJson:function(){return f},getJsonWithCredentials:function(){return m},postText:function(){return g},postTextWithCredentials:function(){return v},postJson:function(){return b},postJsonWithCredentials:function(){return y},monkey:function(){return w},responsiveGetPages:function(){return x},getPages:function(){return _},bilibiliApi:function(){return k}});var i=n(4496);const a=e=>{const t=new XMLHttpRequest,{isText:n=!0,body:i}=e(t);return new Promise(((e,a)=>{t.addEventListener("load",(()=>e(n?t.responseText:t.response))),t.addEventListener("error",(()=>a(t.status))),t.send(i)}))},r=e=>t=>(t.withCredentials=!0,e(t)),o=e=>t=>(t.responseType="blob",t.open("GET",e),{isText:!1}),s=e=>a(o(e)),l=e=>a(r(o(e))),c=e=>t=>(t.responseType="text",t.open("GET",e),{isText:!0}),d=e=>a(c(e)),u=e=>a(r(c(e))),p=e=>t=>(t.responseType="json",t.open("GET",e),{isText:!1}),h=e=>"string"==typeof e?JSON.parse(e):e,f=async e=>{const t=await a(p(e));return h(t)},m=async e=>{const t=await a(r(p(e)));return h(t)},g=(e,t)=>a((n=>(n.open("POST",e),n.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),{isText:!1,body:t}))),v=(e,t)=>a((n=>(n.open("POST",e),n.withCredentials=!0,n.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),{isText:!1,body:t}))),b=(e,t)=>a((n=>(n.open("POST",e),n.setRequestHeader("Content-Type","application/json"),{isText:!1,body:JSON.stringify(t)}))),y=(e,t)=>a((n=>(n.open("POST",e),n.withCredentials=!0,n.setRequestHeader("Content-Type","application/json"),{isText:!1,body:JSON.stringify(t)}))),w=e=>new Promise(((t,n)=>{const i={...e,onload:e=>t(e.response),onerror:e=>{const t={...JSON.parse(JSON.stringify(e)),toString(){return JSON.stringify(this)}};n(t)}};"method"in i||(i.method="GET"),GM_xmlhttpRequest(i)})),x=e=>{let t;const n=new Promise((n=>{t=new Promise((t=>{(async()=>{const{api:i,getList:a,getTotal:r}=e;let o=1,s=1/0;const l=[];for(;l.length{const[,t]=x(e);return await t},k=async(e,t)=>{const n=await e;if(0!==n.code){const e=new Error(`${t}: code = ${n.code}, message = ${n.message||n.msg}`);throw(0,i.logError)(e),e}return n.data||{}}},4011:function(e,t,n){"use strict";let i;n.r(t),n.d(t,{CdnTypes:function(){return i},cdnRoots:function(){return r}}),function(e){e.jsDelivr="jsDelivr",e.GitHub="GitHub"}(i||(i={}));const a="the1812",r={jsDelivr:(e,t)=>`https://cdn.jsdelivr.net/gh/${t||a}/Bilibili-Evolved@${e}/`,GitHub:(e,t)=>`https://github.com/${t||a}/Bilibili-Evolved/raw/${e}/`}},5842:function(e,t,n){"use strict";n.r(t),n.d(t,{coreApis:function(){return Ln},externalApis:function(){return Tn}});var i={};n.r(i),n.d(i,{Reorder:function(){return F},ReorderDecreaseClassName:function(){return T},ReorderEnabledClassName:function(){return D},ReorderIncreaseClassName:function(){return P},ReorderOrientations:function(){return B},ReorderingClassName:function(){return V}});var a={};n.r(a),n.d(a,{getUserInfo:function(){return Z}});var r={};n.r(r),n.d(r,{CompareResult:function(){return W},Version:function(){return G}});var o={};n.r(o),n.d(o,{loadDanmakuSettingsPanel:function(){return ne},loadLazyPanel:function(){return ee},loadLazyPlayerSettingsPanel:function(){return te},loadSubtitleSettingsPanel:function(){return ie}});var s={};n.r(s),n.d(s,{styledComponentEntry:function(){return pe},toggleStyle:function(){return he}});var l={};n.r(l),n.d(l,{getWatchlaterList:function(){return ge},toggleWatchlater:function(){return ve},watchlaterList:function(){return me}});var c={};n.r(c),n.d(c,{addMenuItem:function(){return De},applyContentFilter:function(){return Ie},bangumiTypeList:function(){return we},feedsCardTypes:function(){return ye},feedsCardsManager:function(){return Me},forEachFeedsCard:function(){return ze},getFeeds:function(){return Pe},getVideoFeeds:function(){return Te},groupVideoFeeds:function(){return Ae},isPreOrderedVideo:function(){return $e},navbarFeedsTypeList:function(){return xe},withContentFilter:function(){return Le}});var d={};n.r(d),n.d(d,{disableProfilePopup:function(){return lt}});var u={};n.r(u),n.d(u,{compareID:function(){return ut},getLatestID:function(){return dt},getNotifyCount:function(){return mt},isNewID:function(){return ht},setLatestID:function(){return pt},updateInterval:function(){return ct},updateLatestID:function(){return ft}});var p={};n.r(p),n.d(p,{convertHexColorForDialogue:function(){return vt},convertHexColorForStyle:function(){return bt},convertTimeByDuration:function(){return wt},convertTimeByEndTime:function(){return xt},normalizeContent:function(){return _t}});var h={};n.r(h),n.d(h,{lightOff:function(){return Mt},lightOn:function(){return Et}});var f={};n.r(f),n.d(f,{forEachVideoDanmaku:function(){return $t}});var m={};n.r(m),n.d(m,{BangumiInfo:function(){return Lt},VideoInfo:function(){return It}});var g={};n.r(g),n.d(g,{allQualities:function(){return Dt},loginRequiredQualities:function(){return Tt},vipRequiredQualities:function(){return Pt}});var v={};n.r(v),n.d(v,{addMenuItem:function(){return Bt},forEachContextMenu:function(){return Vt}});var b={};n.r(b),n.d(b,{addControlBarButton:function(){return qt}});var y={};n.r(y),n.d(y,{waitForControlBar:function(){return Ht}});var w={};n.r(w),n.d(w,{LiveSocket:function(){return Kt}});var x={};n.r(x),n.d(x,{addMenuItem:function(){return sn},commentAreas:function(){return Jt},forEachCommentArea:function(){return rn},forEachCommentItem:function(){return on}});var _={};n.r(_),n.d(_,{addCategoryIcons:function(){return bn},categories:function(){return mn},categoryCodes:function(){return gn},categoryLinks:function(){return vn},rawData:function(){return cn}});var k={};n.r(k),n.d(k,{createSwitchOptions:function(){return Mn}});var C=n(6773),S=n(4011),E=n(9356),M=n(6522),z=n(9183),A=n(5527),$=n(4327),O=n(7601),I=n(9017);function L(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const T="reorder-decrease",P="reorder-increase",D="reorder-enabled",V="reordering",B={horizontal:{name:"horizontal",getMoveTransform:e=>`translateX(${e}px)`,setOtherTransform:lodash.throttle(((e,t,n)=>{if(!t.classList.contains(V))return;const i=e.find((e=>e.element===t));if(!i)return;const a=i.rect,r=e.filter((e=>e.rect.leftt.rect.left-e.rect.left)),o=e.filter((e=>e.rect.left>a.left)).sort(((e,t)=>e.rect.left-t.rect.left));if(n>=0){const[e]=o;r.forEach((e=>{e.element.style.transform="",e.element.classList.remove(P)})),o.forEach((t=>{a.left+n+a.width>=t.rect.left+t.rect.width/2?(t.element.classList.add(T),t.element.style.transform=`translateX(-${e.rect.left-a.left}px)`):(t.element.classList.remove(T),t.element.style.transform="")}))}else{const[e]=r;o.forEach((e=>{e.element.style.transform="",e.element.classList.remove(T)})),r.forEach((t=>{a.left+n<=t.rect.left+t.rect.width/2?(t.element.classList.add(P),t.element.style.transform=`translateX(${a.left+a.width-e.rect.left-e.rect.width}px)`):(t.element.classList.remove(P),t.element.style.transform="")}))}}),50)},vertical:{name:"vertical",getMoveTransform:(e,t)=>`translateY(${t}px)`,setOtherTransform:lodash.throttle(((e,t,n,i)=>{if(!t.classList.contains(V))return;const a=e.find((e=>e.element===t));if(!a)return;const r=a.rect,o=e.filter((e=>e.rect.topt.rect.top-e.rect.top)),s=e.filter((e=>e.rect.top>r.top)).sort(((e,t)=>e.rect.top-t.rect.top));if(i>=0){const[e]=s;o.forEach((e=>{e.element.style.transform="",e.element.classList.remove(P)})),s.forEach((t=>{r.top+i+r.height>=t.rect.top+t.rect.height/2?(t.element.classList.add(T),t.element.style.transform=`translateY(-${e.rect.top-r.top}px)`):(t.element.classList.remove(T),t.element.style.transform="")}))}else{const[e]=o;s.forEach((e=>{e.element.style.transform="",e.element.classList.remove(T)})),o.forEach((t=>{r.top+i<=t.rect.top+t.rect.height/2?(t.element.classList.add(P),t.element.style.transform=`translateY(${r.top+r.height-e.rect.top-e.rect.height}px)`):(t.element.classList.remove(P),t.element.style.transform="")}))}}),50)}};class F extends EventTarget{constructor(e){super(),this.container=e,L(this,"orientation",B.horizontal),L(this,"enabled",!1),L(this,"children",void 0),L(this,"snapshots",new Map),L(this,"attachedEvents",[]),this.children=[...this.container.children],this.children.every((e=>""===e.style.order))&&this.children.forEach(((e,t)=>{e.style.order=(t+1).toString()}))}addEventListener(e,t,n){super.addEventListener(e,t,n)}removeEventListener(e,t,n){super.addEventListener(e,t,n)}getOrderMap(){return new Map(this.children.map((e=>[e,parseInt(e.style.order)])))}toggle(){this.enabled?this.disable():this.enable()}generateSnapshots(){this.children.forEach((e=>{this.snapshots.set(e,{element:e,rect:e.getBoundingClientRect()})}))}enable(){this.children.forEach((e=>{let t=0,n=0,i=!1;e.classList.add(D);(()=>{const a=(a,r)=>{e.classList.add(V),e.style.transition="none",e.style.userSelect="none",this.generateSnapshots(),this.children.filter((t=>t!==e)).forEach((e=>{e.style.transition="transform .2s ease-out"})),t=a,n=r,i=!0},r=e=>{a(e.screenX,e.screenY)};e.addEventListener("mousedown",r),this.attachedEvents.push((()=>e.removeEventListener("mousedown",r)));const o=e=>{if(1!==e.touches.length)return;const[t]=e.touches;a(t.screenX,t.screenY)};e.addEventListener("touchstart",o),this.attachedEvents.push((()=>e.removeEventListener("touchstart",o)))})(),(()=>{const a=(i,a)=>{const r=i-t,o=a-n;e.style.transform=this.orientation.getMoveTransform(r,o),this.orientation.setOtherTransform([...this.snapshots.values()],e,r,o)},r=e=>{i&&(a(e.screenX,e.screenY),e.cancelable&&e.preventDefault())};document.addEventListener("mousemove",r),this.attachedEvents.push((()=>document.removeEventListener("mousemove",r)));const o=e=>{if(!i)return;if(1!==e.touches.length)return;const[t]=e.touches;a(t.screenX,t.screenY),e.cancelable&&e.preventDefault()};e.addEventListener("touchmove",o,{passive:!1}),this.attachedEvents.push((()=>e.removeEventListener("touchmove",o)))})(),(()=>{const t=()=>{if(!i)return;e.classList.remove(V),i=!1;let t=0;const n=this.children.filter((t=>t!==e)),a=[];n.forEach((e=>{e.style.transform="",e.style.transition="",e.classList.contains(P)?(t--,e.style.order=(parseInt(e.style.order)+1).toString(),e.classList.remove(P),a.push(this.snapshots.get(e))):e.classList.contains(T)&&(t++,e.style.order=(parseInt(e.style.order)-1).toString(),e.classList.remove(T),a.push(this.snapshots.get(e)))})),e.style.userSelect="",e.style.order=(parseInt(e.style.order)+t).toString(),e.style.transform="",e.style.transition="",this.dispatchEvent(new CustomEvent("reorder",{detail:this.children.map((e=>({element:e,order:parseInt(e.style.order)})))}))};document.addEventListener("mouseup",t),this.attachedEvents.push((()=>document.removeEventListener("mouseup",t))),e.addEventListener("touchend",t),this.attachedEvents.push((()=>e.removeEventListener("touchend",t)))})()})),this.enabled=!0}disable(){this.attachedEvents.forEach((e=>e())),this.children.forEach((e=>e.classList.remove(D))),this.enabled=!1}}var N=n(6984),j=n(4402),q=n(9261),H=n(4659),R=n(7724);const U={isLogin:!1},Z=lodash.once((async()=>{const{getUID:e}=await Promise.resolve().then(n.bind(n,4742));if(!e())return U;const{getJsonWithCredentials:t}=await Promise.resolve().then(n.bind(n,6773)),i=await t("https://api.bilibili.com/x/web-interface/nav");return 0!==i.code&&-101!==i.code?(console.warn("[store.fetchUserInfo] API Error",i.message),U):i.data}));let W;!function(e){e[e.less=-1]="less",e[e.equal=0]="equal",e[e.greater=1]="greater",e[e.incomparable=NaN]="incomparable"}(W||(W={}));class G{constructor(e){var t,n,i;if(this.versionString=e,i=void 0,(n="parts")in(t=this)?Object.defineProperty(t,n,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[n]=i,!/^[\d\.]+$/.test(e))throw new Error("Invalid version string");this.parts=e.split(".").map((e=>parseInt(e)))}compareTo(e){for(let t=0;te.parts[t]?W.greater:W.less}return this.parts.length!==e.parts.length?W.less:W.equal}greaterThan(e){return this.compareTo(e)===W.greater}lessThan(e){return this.compareTo(e)===W.less}equals(e){return this.compareTo(e)===W.equal}}var X=n(4742),K=n(1290),J=n(2433),Y=n(4435),Q=n(5890);const ee=async(e,t={})=>{const{style:n,enterDelay:i=750,leaveDelay:a=1e3}=t,r=await(0,j.select)(e);if(!r)throw new Error(`lazy panel failed! selector = ${e}`);let o;return void 0!==n&&(o=document.createElement("style"),o.textContent=n,document.body.insertAdjacentElement("beforeend",o)),(0,X.raiseEvent)(r,"mouseover"),await(0,X.delay)(i),(0,X.raiseEvent)(r,"mouseout"),setTimeout((()=>o?.remove()),a),r},te=async(e,t,n={})=>{await ee(e,{style:`${t} { display: none !important; }`,...n});const i=(0,X.dq)(t);if(!i)throw new Error(`lazy player settings panel failed! panelSelector = ${t}`);return i},ne=()=>te(".bilibili-player-video-danmaku-setting",".bilibili-player-video-danmaku-setting-wrap"),ie=()=>te(".bilibili-player-video-btn-subtitle",".bilibili-player-video-subtitle-setting-wrap",{style:".bilibili-player-video-subtitle-setting-wrap, .bilibili-player-video-subtitle { display: none }"});var ae=n(4496),re=n(503),oe=n(6363),se=n(3446),le=n(8232),ce=n(9759),de=n(6087),ue=n(559);const pe=(e,t)=>async i=>{const{default:a}=await e(),{addStyle:r}=await Promise.resolve().then(n.bind(n,9261));return r(a,i.metadata.name),t(i)},he=(e,t,i=X.none)=>{let a=null;const r=async()=>{if(a)return;const{default:i}=await t(),{addStyle:r}=await Promise.resolve().then(n.bind(n,9261));a=r(i,e)};return{name:e,entry:e=>r().then((()=>i(e))),reload:r,unload:()=>{a?.remove(),a=null}}};var fe=n(8774);const me=[];async function ge(e=!1){const{getJsonWithCredentials:t}=await Promise.resolve().then(n.bind(n,6773)),i=await t("https://api.bilibili.com/x/v2/history/toview/web");if(0!==i.code)throw new Error(`获取稍后再看列表失败: ${i.message}`);if(!i.data.list)return lodash.pullAll(me,me),[];const a=i.data.list,r=a.filter((e=>!me.find((t=>t===e.aid)))),o=me.filter((e=>!a.find((t=>t.aid===e))));return lodash.pullAll(me,o),me.push(...r.map((e=>e.aid))),e?a:a.map((e=>e.aid))}const ve=async(e,t)=>{const i=parseInt(e.toString());if(Number.isNaN(i))return;void 0===t&&(t=!me.includes(i));const a=t?"https://api.bilibili.com/x/v2/history/toview/add":"https://api.bilibili.com/x/v2/history/toview/del",{getCsrf:r}=await Promise.resolve().then(n.bind(n,4742)),o=r(),{postTextWithCredentials:s}=await Promise.resolve().then(n.bind(n,6773)),l=await s(a,`aid=${e}&csrf=${o}`),c=JSON.parse(l);if(0!==c.code)throw new Error(`稍后再看操作失败: ${c.message}`);t?me.push(i):lodash.pull(me,i)};requestIdleCallback((async()=>{const{getUID:e}=await Promise.resolve().then(n.bind(n,4742));e()&&ge()}));var be=n(9207);const ye={repost:{id:1,name:"转发"},textWithImages:{id:2,name:"图文"},text:{id:4,name:"文字"},video:{id:8,name:"视频"},miniVideo:{id:16,name:"小视频"},column:{id:64,name:"专栏"},audio:{id:256,name:"音频"},bangumi:{id:512,name:"番剧"},share:{id:2048,name:"分享"},manga:{id:2049,name:"漫画"},film:{id:4098,name:"电影"},tv:{id:4099,name:"TV剧"},chinese:{id:4100,name:"国创"},documentary:{id:4101,name:"纪录片"},mediaList:{id:4300,name:"收藏夹"},liveRecord:{id:2047,name:"开播记录"}},we="512,4097,4098,4099,4100,4101",xe="8,64,512,4097,4098,4099,4100,4101";function _e(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const ke=e=>e.querySelector(".repost")?ye.repost:e.querySelector(".imagesbox")?ye.textWithImages:e.querySelector(".video-container")?ye.video:e.querySelector(".bangumi-container")?ye.bangumi:e.querySelector(".article-container")?ye.column:e.querySelector(".music-container")?ye.audio:e.querySelector(".h5share-container")?ye.share:e.querySelector(".vc-ctnr")?ye.miniVideo:e.querySelector(".live-container")?ye.liveRecord:ye.text,Ce=[],Se="feeds.manager.listAdaptors";(0,be.addData)(Se,(e=>{e.push({name:"live",match:[...oe.liveUrls],watchCardsList:async e=>{const t=await(0,j.select)(".room-feed");if(!t)return!1;console.log("live watch");let n=null;return(0,I.childList)(t,(async()=>{if(dq(".room-feed-content")){const t=await(0,j.select)(".room-feed-content .content");n?.disconnect(),[n]=e.updateCards(t)}else n?.disconnect(),n=null,await Promise.all(e.cards.map((e=>e.element)).map((t=>e.removeCard(t))))})),!0}},{name:"space",match:["https://space.bilibili.com/"],watchCardsList:async e=>{const t=await(0,j.select)(".s-space");if(!t)return!1;const n={},i=()=>n.listElement&&n.observer?(console.log("space feeds stop"),n.observer?.then((e=>e.disconnect())),delete n.observer,delete n.listElement,Promise.all(e.cards.map((e=>e.element)).map((t=>e.removeCard(t))))):[],a=()=>{if(n.observer)return n.observer;const t=(0,j.select)(".feed-card .content");return n.observer=(async()=>{const r=await t;r!==await n.listElement&&(n.listElement&&await i(),n.listElement=t,a()),console.log("space feeds start");const[o]=e.updateCards(r);return o})(),n.observer};return(0,I.childListSubtree)(t,(async()=>{dq(".feed-card .content")?a():i()})),!0}},{name:"topic",match:["https://t.bilibili.com/topic"],watchCardsList:async e=>{const t=await(0,j.select)(".page-container");if(!t)return!1;let n=null;return(0,I.childList)(t,(async()=>{if(dq(".page-container .feed")){const t=await(0,j.select)(".feed .feed-topic");n?.disconnect(),[n]=e.updateCards(t)}else n?.disconnect(),n=null,await Promise.all(e.cards.map((e=>e.element)).map((t=>e.removeCard(t))))})),!0}},{name:"default",match:["https://t.bilibili.com/"],watchCardsList:async e=>{const t=await(0,j.select)(".feed-card .content, .detail-content .detail-card");return!!t&&(e.updateCards(t),!0)}})}));class Ee extends EventTarget{constructor(...e){super(...e),_e(this,"watching",!1),_e(this,"cards",[])}addEventListener(e,t,n){super.addEventListener(e,t,n)}removeEventListener(e,t,n){super.removeEventListener(e,t,n)}async addCard(e){if(e&&e instanceof HTMLElement&&e.classList.contains("card"))if(null!==e.querySelector(".skeleton")){const[t]=(0,I.childList)(e,(()=>{null===e.querySelector(".skeleton")&&(t.disconnect(),this.addCard(e))}))}else{if(null===e.parentNode)return;const t=await Ee.parseCard(e);if(!t.presented)return;if(this.cards.find((e=>e.id===t.id)))return;this.cards.push(t),this.cards.sort(((e,t)=>e.id===t.id?0:e.id>t.id?-1:1));const n=new CustomEvent("addCard",{detail:t});this.dispatchEvent(n),Ce.forEach((e=>e.added(t)))}}async removeCard(e){if(e&&e instanceof HTMLElement&&e.classList.contains("card")){const t=e.getAttribute("data-did"),n=this.cards.findIndex((e=>e.id===t));if(-1===n)return;const i=this.cards[n];this.cards.splice(n,1);const a=new CustomEvent("removeCard",{detail:i});this.dispatchEvent(a),Ce.forEach((e=>e.removed(i)))}}static async parseCard(e){ // eslint-disable-next-line no-underscore-dangle -const t=e=>e.__vue__||e.parentElement.__vue__,n=async t=>{const n=await(0,j.sq)((()=>e.querySelector(t)),(t=>null!==t||null===e.parentNode),{queryInterval:100});if(null===e.parentNode)return"";if(null===n)return console.warn(e,t,e.parentNode),"";return n.innerText.trim()},i=e=>{if(void 0===e.card.origin)return{originalText:"",originalDescription:"",originalTitle:""};const t=JSON.parse(e.card.origin);return{originalText:e.originCardData.pureText,originalDescription:lodash.get(t,"item.description",""),originalTitle:t.title}},a=async e=>{const t=parseInt(await n(e));return isNaN(t)?0:t},r={id:e.getAttribute("data-did"),username:await n(".main-content .user-name"),text:"",reposts:await a(".button-bar .single-button:nth-child(1) .text-offset"),comments:await a(".button-bar .single-button:nth-child(2) .text-offset"),likes:await a(".button-bar .single-button:nth-child(3) .text-offset"),element:e,type:ke(e),get presented(){return null!==e.parentNode},async getText(){const n=await(async n=>{if(n===ye.bangumi)return"";const a=await(0,j.sq)((()=>e),(n=>Boolean(t(n)||!e.parentNode)),{queryInterval:100});if(null===e.parentNode)return"";if(null===a)return console.warn(a,e,t(a),e.parentNode),"";const r=t(a);if(n===ye.repost){const e=r.card.item.content,t=i(r);return[e,...Object.values(t).filter((e=>""!==e))].filter((e=>Boolean(e))).join("\n")}return[r.originCardData.pureText,r.originCardData.title].filter((e=>Boolean(e))).join("\n")})(this.type);return this.text=n,n}};if(await r.getText(),e.setAttribute("data-type",r.type.id.toString()),(e=>e.type===ye.repost)(r)){const n=r.username,a=t(r.element),o=lodash.get(a,"card.origin_user.info.uname","");n===o&&e.setAttribute("data-self-repost","true"),r.repostUsername=o,r.repostText=i(a).originalText}return r}updateCards(e){const t=".card[data-did]",n=e=>{if(e instanceof HTMLElement){if(e.matches(t))return e;const n=e.querySelector(t);if(n)return n}};return[...e.querySelectorAll(t)].forEach((e=>this.addCard(e))),(0,I.childList)(e,(e=>{e.forEach((e=>{e.addedNodes.forEach((e=>this.addCard(n(e)))),e.removedNodes.forEach((e=>this.removeCard(n(e))))}))}))}async startWatching(){if(this.watching)return!0;this.watching=!0;const[e]=(0,be.registerAndGetData)(Se,[]),t=e.find((e=>e.match.some((e=>(0,X.matchUrlPattern)(e)))));return t?t.watchCardsList(this):(console.warn("[FeedsCardsManager] No adaptor found",e),!1)}}const Me=new Ee,ze=e=>{(async()=>{if(!await Me.startWatching())return void console.error("feedsCardsManager.startWatching() failed");const{added:t}=e;t&&Me.cards.forEach((e=>t(e))),Ce.push({added:none,removed:none,...e})})()},Ae=e=>{const t=lodash.groupBy(e,(e=>e.aid)),n=e=>({id:e.upID,name:e.upName,faceUrl:e.upFaceUrl});return Object.values(t).map((e=>{if(1===e.length)return e[0];const[t,...i]=e;return t.cooperation=[n(t),...i.map(n)],console.log([...t.cooperation]),t})).sort((0,re.descendingStringSort)((e=>e.id)))},$e=e=>1===lodash.get(e,"extra.is_reserve_recall",0),Oe="feeds.contentFilters";(0,be.registerData)(Oe,[]);const Ie=e=>{const[t]=(0,be.getData)(Oe);return t.reduce(((e,t)=>t.filter(e)),e)},Le=e=>(...t)=>e(...t).then((e=>Ie(e))),Te=Le((async(e="video")=>{if(!(0,X.getUID)())return[];const t=await(0,C.getJsonWithCredentials)(`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${"video"===e?8:512}`);if(0!==t.code)throw new Error(t.message);const n=t.data.cards,i=n.filter((e=>!$e(JSON.parse(e.card))));return"video"===e?Ae(n.map((e=>{const t=JSON.parse(e.card),n=lodash.get(e,"display.topic_info.topic_details",[]).map((e=>({id:e.topic_id,name:e.topic_name})));return{id:e.desc.dynamic_id_str,aid:t.aid,bvid:e.desc.bvid||t.bvid,title:t.title,upID:e.desc.user_profile.info.uid,upName:e.desc.user_profile.info.uname,upFaceUrl:e.desc.user_profile.info.face,coverUrl:t.pic,description:t.desc,timestamp:e.timestamp,time:new Date(1e3*e.timestamp),topics:n,dynamic:t.dynamic,like:(0,J.formatCount)(e.desc.like),duration:t.duration,durationText:(0,J.formatDuration)(t.duration,0),playCount:(0,J.formatCount)(t.stat.view),danmakuCount:(0,J.formatCount)(t.stat.danmaku),watchlater:me.includes(t.aid)}}))):"bangumi"===e?i.map((e=>{const t=JSON.parse(e.card);return{id:e.desc.dynamic_id_str,aid:t.aid,bvid:e.desc.bvid||t.bvid,epID:t.episode_id,title:t.new_desc,upName:t.apiSeasonInfo.title,upFaceUrl:t.apiSeasonInfo.cover,coverUrl:t.cover,description:"",timestamp:e.timestamp,time:new Date(1e3*e.timestamp),like:(0,J.formatCount)(e.desc.like),durationText:"",playCount:(0,J.formatCount)(t.play_count),danmakuCount:(0,J.formatCount)(t.bullet_count),watchlater:!1}})):[]})),Pe=async(e,t)=>{if("string"==typeof e)return(0,C.getJsonWithCredentials)(`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${e}`);const n=e.id.toString();let i=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${n}`;return t&&(i=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_history?uid=${(0,X.getUID)()}&offset_dynamic_id=${t}&type=${n}`),(0,C.getJsonWithCredentials)(i)},De=(e,t)=>{const n=dq(e.element,".more-panel"),{className:i,text:a,action:r}=t;if(!n||dq(n,`.${i}`))return;const o=document.createElement("p");o.classList.add("child-button","c-pointer",i),o.textContent=a;[...new Set([...n.children].map((e=>e.getAttributeNames().filter((e=>e.startsWith("data-v-"))))).flat())].forEach((e=>o.setAttribute(e,""))),o.addEventListener("click",(t=>{r(t),e.element.click()})),n.appendChild(o)};var Ve=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"bangumi-card",class:{new:e.isNew},attrs:{target:"_blank",href:e.data.url}},[n("div",{staticClass:"ep-cover-container"},[n("DpiImage",{staticClass:"ep-cover",attrs:{size:{width:100},src:e.data.epCoverUrl}})],1),e._v(" "),n("h1",{staticClass:"ep-title",attrs:{title:e.data.epTitle}},[e._v(e._s(e.data.epTitle))]),e._v(" "),n("div",{staticClass:"up",attrs:{title:e.data.title}},[n("DpiImage",{staticClass:"cover",attrs:{size:24,src:e.data.coverUrl}}),e._v(" "),n("div",{staticClass:"title"},[e._v(e._s(e.data.title))])],1)])};Ve._withStripped=!0;var Be=Vue.extend({components:{DpiImage:ce.DpiImage},props:{data:{type:Object,required:!0},isNew:{type:Boolean,default:!1}}}),Fe=n(3379),Ne=n.n(Fe),je=n(4780),qe=n.n(je),He={insert:"head",singleton:!1},Re=(Ne()(qe(),He),qe().locals,n(1900)),Ue=(0,Re.Z)(Be,Ve,[],!1,null,"3bc2da4f",null);Ue.options.__file="src/components/feeds/BangumiCard.vue";var Ze=Ue.exports,We=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"video-card",class:{vertical:"vertical"===e.orientation,"no-stats":!e.showStats},attrs:{target:"_blank",href:e.epID?"https://www.bilibili.com/bangumi/play/ep"+e.epID:"https://www.bilibili.com/"+e.bvid}},[n("div",{staticClass:"cover-container"},[n("DpiImage",{staticClass:"cover",attrs:{src:e.coverUrl,size:{height:120,width:200}}}),e._v(" "),e.isNew?n("div",{staticClass:"new"},[e._v("NEW")]):e._e(),e._v(" "),e.pubTime&&e.pubTimeText?[n("div",{staticClass:"publish-time-summary"},[e._v("\n "+e._s(e.pubTimeText)+"\n ")]),e._v(" "),n("div",{staticClass:"publish-time-detail"},[e._v("\n "+e._s(e.pubTime)+"\n ")])]:e._e(),e._v(" "),e.durationText?n("div",{staticClass:"duration"},[e._v(e._s(e.durationText))]):e._e(),e._v(" "),e.durationText&&null!==e.watchlater&&void 0!==e.watchlater?n("div",{staticClass:"watchlater",on:{click:function(t){return t.stopPropagation(),t.preventDefault(),e.toggleWatchlater(e.aid)}}},[n("VIcon",{attrs:{size:15,icon:e.watchlater?"mdi-check-circle":"mdi-clock-outline"}}),e._v("\n "+e._s(e.watchlater?"已添加":"稍后再看")+"\n ")],1):e._e()],2),e._v(" "),n("h1",{staticClass:"title",attrs:{title:e.title}},[e._v(e._s(e.title))]),e._v(" "),e.topics&&e.topics.length?n("div",{staticClass:"topics"},e._l(e.topics.slice(0,3),(function(t){return n("a",{key:t.id,staticClass:"topic",attrs:{target:"_blank",href:"https://t.bilibili.com/topic/name/"+t.name+"/feed"}},[e._v("#"+e._s(t.name)+"#")])})),0):n("p",{staticClass:"description",attrs:{title:e.description}},[e._v(e._s(e.description))]),e._v(" "),0===e.cooperation.length?n("a",{staticClass:"up",class:{"no-face":!e.upFaceUrl},attrs:{target:"_blank",href:e.upID?"https://space.bilibili.com/"+e.upID:null}},[e.upFaceUrl?n("DpiImage",{staticClass:"face",attrs:{src:e.upFaceUrl,size:24}}):n("VIcon",{attrs:{icon:"up"}}),e._v(" "),n("div",{staticClass:"name",attrs:{title:e.upName}},[e._v(e._s(e.upName))])],1):e._e(),e._v(" "),0!==e.cooperation.length?n("div",{staticClass:"cooperation"},[n("div",{staticClass:"cooperation-ups"},e._l(e.reversedCooperation,(function(e){return n("a",{key:e.id,staticClass:"cooperation-up",class:{"no-face":!e.faceUrl},attrs:{target:"_blank",title:e.name,href:e.id?"https://space.bilibili.com/"+e.id:null}},[e.faceUrl?n("DpiImage",{staticClass:"face",attrs:{src:e.faceUrl,size:24}}):n("VIcon",{attrs:{icon:"up"}})],1)})),0),e._v(" "),n("div",{staticClass:"cooperation-note"},[e._v("\n 联合投稿\n ")])]):e._e(),e._v(" "),e.showStats?n("div",{staticClass:"stats"},[e.like&&!e.vertical?[n("VIcon",{attrs:{icon:"like-outline",size:18}}),e._v("\n "+e._s(e.like)+"\n ")]:e._e(),e._v(" "),e.coins&&!e.vertical?[n("VIcon",{attrs:{icon:"coin-outline",size:18}}),e._v("\n "+e._s(e.coins)+"\n ")]:e._e(),e._v(" "),e.favorites?[n("VIcon",{attrs:{icon:"favorites-outline",size:18}}),e._v("\n "+e._s(e.favorites)+"\n ")]:e._e(),e._v(" "),e.playCount?[n("VIcon",{attrs:{icon:"play",size:18}}),e._v("\n "+e._s(e.playCount)+"\n ")]:e._e(),e._v(" "),e.danmakuCount?[n("VIcon",{attrs:{icon:"danmaku",size:18}}),e._v("\n "+e._s(e.danmakuCount)+"\n ")]:e._e()],2):e._e()])};We._withStripped=!0;var Ge={components:{DpiImage:ce.DpiImage,VIcon:ce.VIcon},props:{data:{type:Object,required:!0},orientation:{type:String,default:"horizontal"},showStats:{type:Boolean,default:!0},isNew:{type:Boolean,default:!1}},data(){return{watchlaterList:me,upFaceUrl:"",danmakuCount:"",like:"",coins:"",favorites:"",dynamic:"",topics:[],upID:0,epID:0,cooperation:[],...lodash.omit(this.data,"watchlater"),watchlaterInit:this.data.watchlater}},computed:{vertical(){return"vertical"===this.orientation},watchlater(){return(0,X.getUID)()&&null!==this.watchlaterInit?this.watchlaterList.includes(this.aid):null},reversedCooperation(){return[...this.cooperation].reverse().slice(0,3)}},methods:{toggleWatchlater:ve}},Xe=n(1267),Ke=n.n(Xe),Je={insert:"head",singleton:!1},Ye=(Ne()(Ke(),Je),Ke().locals,(0,Re.Z)(Ge,We,[],!1,null,"0ffa1cb1",null));Ye.options.__file="src/components/feeds/VideoCard.vue";var Qe=Ye.exports,et=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"column-card",attrs:{target:"_blank",href:"https://www.bilibili.com/read/cv"+e.data.cvID}},[n("div",{staticClass:"covers"},e._l(e.data.covers,(function(e){return n("DpiImage",{key:e,staticClass:"cover",attrs:{size:{height:120},src:e}})})),1),e._v(" "),n("a",{staticClass:"up",attrs:{target:"_blank",href:"https://space.bilibili.com/"+e.data.upID}},[n("DpiImage",{staticClass:"face",attrs:{size:24,src:e.data.upFaceUrl}}),e._v(" "),n("div",{staticClass:"name"},[e._v(e._s(e.data.upName))])],1),e._v(" "),n("h1",{staticClass:"title",attrs:{title:e.data.title}},[e._v(e._s(e.data.title))]),e._v(" "),n("div",{staticClass:"description",attrs:{title:e.data.description}},[e._v(e._s(e.data.description))])])};et._withStripped=!0;var tt=Vue.extend({components:{DpiImage:ce.DpiImage},props:{data:{type:Object,required:!0},isNew:{type:Boolean,default:!1}}}),nt=n(807),it=n.n(nt),at={insert:"head",singleton:!1},rt=(Ne()(it(),at),it().locals,(0,Re.Z)(tt,et,[],!1,null,null,null));rt.options.__file="src/components/feeds/ColumnCard.vue";var ot=rt.exports;let st=!1;const lt=()=>{"https://t.bilibili.com/"===document.URL.replace(window.location.search,"")&&(async()=>{const{select:e}=await Promise.resolve().then(n.bind(n,4402)),t=await e(".live-up-list");if(null!==t){const{getComponentSettings:e}=await Promise.resolve().then(n.bind(n,7724));if(st)return;const i=e("fixedSidebars"),a=e("extendFeedsLive");t.addEventListener("mouseenter",(e=>{(i.enabled||a.enabled)&&e.stopImmediatePropagation()}),{capture:!0}),st=!0}})()},ct=3e5,dt=()=>(0,X.getCookieValue)(`bp_t_offset_${(0,X.getUID)()}`),ut=(e,t)=>e===t?0:e.length>t.length?1:t.length>e.length?-1:e>t==!0?1:-1,pt=e=>{if(null==e)return;const t=dt();ut(e,t)<0||(document.cookie=`bp_t_offset_${(0,X.getUID)()}=${e};path=/;domain=.bilibili.com;max-age=2592000`)},ht=e=>ut(e,dt())>0,ft=e=>{const[t]=[...e.map((e=>e.id))].sort(ut).reverse();pt(t)},mt=async e=>{const t=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_num?rsp_type=1&uid=${(0,X.getUID)()}&update_num_dy_id=${dt()}&type_list=${e||xe}`,n=await(0,C.getJsonWithCredentials)(t);return 0!==n.code?0:lodash.get(n,"data.update_num",0)},gt=e=>{e.startsWith("#")&&(e=e.substring(1));return{red:e.substring(0,2),green:e.substring(2,4),blue:e.substring(4,6)}},vt=e=>{const{red:t,green:n,blue:i}=gt(e);return`\\c&H${i}${n}${t}&`.toUpperCase()},bt=(e,t=1)=>{const{red:n,green:i,blue:a}=gt(e);return`&H${Math.round(255*(1-t)).toString(16).padStart(2,"0")}${a}${i}${n}`.toUpperCase()},yt=e=>{let t=0,n=0;for(;e>=60;)e-=60,n++;for(;n>=60;)n-=60,t++;return`${t}:${String(n).padStart(2,"0")}:${(e=>{const[t,n="00"]=String(e).split(".");return`${t.padStart(2,"0")}.${n.substr(0,2).padEnd(2,"0")}`})(e)}`},wt=(e,t)=>[yt(e),yt(e+t)],xt=(e,t)=>[yt(e),yt(t)],_t=e=>{const t={"{":"{","}":"}","&":"&","<":"<",">":">",""":'"',"'":"'","\n":"\\N"};for(const[n,i]of Object.entries(t))e=e.replace(new RegExp(n,"g"),i);return e};var kt=n(4572);let Ct=!1;const St=e=>oe.playerUrls.some((e=>(0,X.matchUrlPattern)(e)))?async()=>{Ct||(te(".bilibili-player-video-btn-setting",".bilibili-player-video-btn-setting-wrap",{style:".bilibili-player-video-btn-setting-wrap { display: none !important }"}),Ct=!0);const t=await(0,j.select)(".bilibili-player-video-btn-setting-right-others-content-lightoff .bui-checkbox-input");t.checked=!e,(0,X.raiseEvent)(t,"change")}:X.none,Et=St(!0),Mt=St(!1);let zt;const At=[],$t=async e=>{await(0,j.hasVideo)()&&(0,I.videoChange)((async()=>{const t=await kt.playerAgent.query.video.danmaku();t&&((e,t)=>{zt&&zt.disconnect(),[zt]=(0,I.childListSubtree)(e,(e=>{e.forEach((e=>{e.addedNodes.forEach((e=>{if(e.nodeType===Node.TEXT_NODE){const n=e.parentElement,i=At.find((e=>e.element===n));if(!i)return;return i.text=e.textContent||"",i.reuse=!0,void(t.added&&t.added(i))}if(!(e instanceof HTMLElement))return;const n={element:i=e,reuse:!1,text:i.textContent||""};var i;At.push(n),t.added&&t.added(n)})),e.removedNodes.forEach((e=>{if(!(e instanceof HTMLElement))return;const n=At.findIndex((t=>t.element===e));if(-1!==n){const[e]=At.splice(n,1);t.removed&&t.removed(e)}}))}))}))})(t,e)}))};function Ot(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class It{constructor(e){Ot(this,"aid",void 0),Ot(this,"cid",void 0),Ot(this,"pageCount",void 0),Ot(this,"coverUrl",void 0),Ot(this,"tagId",void 0),Ot(this,"tagName",void 0),Ot(this,"title",void 0),Ot(this,"description",void 0),Ot(this,"up",void 0),Ot(this,"pages",void 0),Ot(this,"subtitles",void 0),this.aid=e}async fetchInfo(){let e;e=this.cid?`https://api.bilibili.com/x/web-interface/view?aid=${this.aid}&cid=${this.cid}`:`https://api.bilibili.com/x/web-interface/view?aid=${this.aid}`;const t=await(0,C.getJson)(e);if(0!==t.code)throw new Error(t.message);const{data:n}=t;return this.cid=n.cid,this.pageCount=n.videos,this.coverUrl=n.pic.replace("http:","https:"),this.tagId=n.tid,this.tagName=n.tname,this.title=n.title,this.description=n.desc,this.up={uid:n.owner.mid,name:n.owner.name,faceUrl:n.owner.face.replace("http:","https:")},this.pages=n.pages.map((e=>({cid:e.cid,title:e.part,pageNumber:e.page}))),this.subtitles=n.subtitle.list.map((e=>({id:e.id,languageCode:e.lan,language:e.lan_doc,url:e.subtitle_url.replace("http:","https:")}))),this}}class Lt{constructor(e){Ot(this,"ep",void 0),Ot(this,"videos",void 0),Ot(this,"title",void 0),Ot(this,"cover",void 0),Ot(this,"squareCover",void 0),Ot(this,"aid",void 0),Ot(this,"cid",void 0),this.ep=e,this.videos=[]}async fetchInfo(){const e=await(0,C.getText)(`https://www.bilibili.com/bangumi/play/ep${this.ep}/`),t=JSON.parse(e.match(/window\.__INITIAL_STATE__=(.*);\(function\(\){/)[1]);return this.title=t.mediaInfo.title,this.cover=t.mediaInfo.cover,this.squareCover=t.mediaInfo.square_cover,this.aid=t.epInfo.aid,this.cid=t.epInfo.cid,this.videos=t.epList.map((async e=>({title:e.index_title,aid:e.aid,cid:e.cid,info:await new It(e.aid).fetchInfo()}))),this}}const Tt=[{name:"720P",displayName:"高清 720P",value:64},{name:"1080P",displayName:"高清 1080P",value:80}],Pt=[{name:"HDR",displayName:"真彩 HDR",value:125},{name:"4K",displayName:"超清 4K",value:120},{name:"1080P60",displayName:"高清 1080P60",value:116},{name:"1080P+",displayName:"高清 1080P+",value:112},{name:"720P60",displayName:"高清 720P60",value:74}],Dt=[...Pt,...Tt,{name:"480P",displayName:"清晰 480P",value:32},{name:"360P",displayName:"流畅 360P",value:16}].sort((0,re.descendingSort)((e=>e.value))),Vt=async e=>{const{open:t,close:n}=e;if(!(0,j.hasVideo)())return;const i=await(0,j.select)(".bilibili-player");if(!i)return;const[a]=(0,I.childList)(i,(()=>{const e=dq(".bilibili-player-context-menu-origin");if(e){a.disconnect();const i=dq(e,"ul"),r={containerElement:e,listElement:i,get itemElements(){return dqa(e,".context-menu-function")},get isOpen(){return e.classList.contains("active")}};(0,I.childList)(i,(()=>{r.isOpen?t?.(r):n?.(r)}))}}))},Bt=async(e,t)=>Vt({open:t=>{if(t.listElement.contains(e))return;const n=document.createElement("li");n.classList.add("context-line","context-menu-function"),n.setAttribute("data-append","1");const i=document.createElement("a");i.classList.add("context-menu-a","js-action"),i.href="javascript:void(0);",i.appendChild(e),n.addEventListener("mouseover",(()=>n.classList.add("hover"))),n.addEventListener("mouseout",(()=>n.classList.remove("hover"))),n.appendChild(i),t.listElement.appendChild(n)},close:e=>t?.(e)});let Ft;const Nt=[],jt=lodash.once((async()=>{oe.playerUrls.some((e=>(0,X.matchUrlPattern)(e)))&&(0,I.videoChange)((async()=>{const{playerAgent:e}=await Promise.resolve().then(n.bind(n,4572)),t=await e.query.control.buttons.time();if(null===t)return;const i=await Promise.resolve().then(n.bind(n,413)).then((e=>e.default));Ft=new i({propsData:{items:Nt}}).$mount(),t.insertAdjacentElement("afterend",Ft.$el)}))})),qt=async e=>{Ft||await jt(),Nt.push(e)},Ht=async e=>{if(!oe.liveUrls.some((e=>(0,X.matchUrlPattern)(e))))return;const t=await(0,j.select)(".bilibili-live-player-video-controller, .web-player-controller-wrap:not(.web-player-controller-bg)");if(!t)return;const{init:n,callback:i}=e;n?.(t),(0,I.childList)(t,(async()=>{const e=dq(t,".control-area");e&&i?.(e)}))};function Rt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const Ut=0,Zt=2,Wt={heartBeat:2,heartBeatResponse:3,message:5,enterRoom:7,enterRoomResponse:8};class Gt{constructor(){Rt(this,"textEncoder",new TextEncoder),Rt(this,"textDecoder",new TextDecoder)}static readInt(e,t,n){let i=0;for(let a=n-1;a>=0;a--)i+=256**(n-a-1)*e[t+a];return i}static writeInt(e,t,n,i){let a=0;for(;a{const i={packetLength:Gt.readInt(e,0,4),headerLength:Gt.readInt(e,4,2),protocolVersion:Gt.readInt(e,6,2),operation:Gt.readInt(e,8,4),sequenceID:Gt.readInt(e,12,4)},a=[i];if(i.packetLengthe.messages[0])))}else i.protocolVersion===Ut&&(i.messages=[JSON.parse(this.textDecoder.decode(a))])}else i.operation===Wt.heartBeatResponse&&(i.heartBeatResponse={count:Gt.readInt(e,16,4)});return a};return new Promise(((n,i)=>{const a=new FileReader;a.onload=async e=>{if(!e.target)return void i(e);const a=new Uint8Array(e.target.result);n(await t(a))},a.readAsArrayBuffer(e)}))}}class Xt{constructor(){Rt(this,"startTime",0)}getLiveTime(){return new Promise((e=>{if(this.startTime)return void e(this.startTime);const t=(0,X.dq)(".bilibili-live-player-video-controller-duration-btn span"),[n]=(0,I.childList)(t,(t=>{if(t.length>0&&t.some((e=>e.addedNodes.length>0&&[...e.addedNodes].every((e=>e.nodeType===Node.TEXT_NODE))))){n.disconnect();const i=t[0].addedNodes[0].textContent,[a,r,o=0]=i.split(":").reverse().map(lodash.unary(parseInt)),s=Number(new Date);this.startTime=s-1e3*o*3600-60*r*1e3-1e3*a,e(this.startTime)}}))}))}}class Kt extends EventTarget{constructor(e){super(),this.roomID=e,Rt(this,"heartBeatTimer",void 0),Rt(this,"webSocket",void 0),Rt(this,"retryInterval",200),Rt(this,"autoRetry",!0),Rt(this,"servers",["broadcastlv.chat.bilibili.com"]),Rt(this,"selectedServer",""),Rt(this,"liveTime",new Xt),Rt(this,"bufferHelper",new Gt),Rt(this,"stopRequested",!1),window.addEventListener("unload",(()=>this.stop()))}heartBeat(){this.webSocket.readyState===WebSocket.OPEN?this.webSocket.send(this.bufferHelper.encode("","heartBeat")):(this.stop(),this.restart())}restart(){if(this.dispatchEvent(new CustomEvent("restart")),!this.stopRequested&&this.autoRetry){console.log(`Live Socket: unexpected disconnect, retry in ${this.retryInterval}ms`);const e=this.servers.indexOf(this.selectedServer);ethis.start()),this.retryInterval)}}async start(){const e=await(0,C.getJson)(`https://api.live.bilibili.com/room/v1/Danmu/getConf?room_id=${this.roomID}&platform=pc&player=web`),t=lodash.get(e,"data.host_server_list",[]);this.servers=[...new Set([...this.servers,...t.map((e=>e.host))])],""===this.selectedServer&&([this.selectedServer]=this.servers,console.log("Initial server:",this.selectedServer)),this.webSocket&&[WebSocket.CONNECTING,WebSocket.OPEN].includes(this.webSocket.readyState)&&this.stop(),this.webSocket=new WebSocket(`wss://${this.selectedServer}/sub`),this.stopRequested=!1,this.dispatchEvent(new CustomEvent("start",{detail:this.webSocket})),this.webSocket.addEventListener("open",(()=>{const t={roomid:this.roomID,uid:parseInt((0,X.getUID)()),protover:2,platform:"web",clientVer:"1.10.1",type:"2",key:lodash.get(e,"data.token")};this.webSocket.send(this.bufferHelper.encode(JSON.stringify(t),"enterRoom")),this.dispatchEvent(new CustomEvent("open",{detail:t}))})),this.webSocket.addEventListener("message",(async e=>{const[t]=await this.bufferHelper.decode(e.data);switch(this.dispatchEvent(new CustomEvent("message",{detail:t})),t.operation){case Wt.enterRoomResponse:this.heartBeatTimer&&clearInterval(this.heartBeatTimer),this.heartBeatTimer=window.setInterval((()=>{this.heartBeat()}),3e4);break;case Wt.heartBeatResponse:if(!t.heartBeatResponse)break;this.dispatchEvent(new CustomEvent("heartBeatResponse",{detail:t.heartBeatResponse.count}));break;case Wt.message:{if(!t.messages)break;const e=await this.liveTime.getLiveTime();t.messages.forEach((t=>{if("DANMU_MSG"===t.cmd){const{info:n}=t,i={content:n[1],type:n[0][1],fontSize:n[0][2],color:n[0][3],sendTime:n[0][4],userHash:n[0][7],userID:n[2][0],userName:n[2][1],startTime:e,get time(){return this.sendTime-this.startTime}};this.dispatchEvent(new CustomEvent("danmaku",{detail:i}))}}));break}}})),this.webSocket.addEventListener("close",(e=>{this.stopRequested||(console.error("Live Socket: close",e),this.restart())})),this.webSocket.addEventListener("error",(e=>{console.error("Live Socket: error",e),this.restart()}))}stop(){this.stopRequested=!0,this.heartBeatTimer&&clearInterval(this.heartBeatTimer),this.webSocket&&this.webSocket.readyState===WebSocket.OPEN&&this.webSocket.close()}}const Jt=[],Yt="bb-comment",Qt=[],en=[],tn=[],nn=e=>{const t=e.querySelector(".con .user .name"),n=e=>{const t=e.querySelector(".reply-face"),n=e.querySelector(".reply-con .user .name");return{id:e.getAttribute("data-id"),element:e,userID:t.getAttribute("data-usercard-mid"),userName:n.textContent,content:e.querySelector(".text-con").textContent,timeText:e.querySelector(".info .time").textContent,likes:parseInt(e.querySelector(".info .like span").textContent)}},i={id:e.getAttribute("data-id"),element:e,userID:t.getAttribute("data-usercard-mid"),userName:t.textContent,content:e.querySelector(".con .text").textContent,timeText:e.querySelector(".con .info .time").textContent,likes:parseInt(e.querySelector(".con .like span").textContent),replies:[]};if(dq(e,".reply-box .view-more")){const t=dq(e,".reply-box");(0,I.childList)(t,(t=>{i.replies=(0,X.dqa)(e,".reply-box .reply-item").map(n),0!==t.length&&i.onRepliesUpdate?.(i.replies)}))}else i.replies=(0,X.dqa)(e,".reply-box .reply-item").map(n);return i},an=e=>{if(e instanceof HTMLElement&&e.classList.contains(Yt)){const t={element:e,items:[]};Jt.push(t),(e=>{e.observer||(e.items=(0,X.dqa)(e.element,".list-item.reply-wrap").map(nn),e.items.forEach((e=>{Qt.forEach((t=>t(e)))})),[e.observer]=(0,I.childListSubtree)(e.element,(t=>{t.forEach((t=>{const n=e=>e instanceof HTMLElement&&e.classList.contains("list-item")&&e.classList.contains("reply-wrap");t.addedNodes.forEach((t=>{if(n(t)){const n=nn(t);e.items.push(n),Qt.forEach((e=>e(n)))}})),t.removedNodes.forEach((t=>{if(n(t)){const n=t.getAttribute("data-id"),i=e.items.findIndex((e=>e.id===n));if(-1!==i){const[t]=e.items.splice(i,1);en.forEach((e=>e(t)))}}}))}))})))})(t),tn.forEach((e=>e(t)))}};(0,A.contentLoaded)((()=>{(0,I.allMutations)((e=>{e.forEach((e=>{e.addedNodes.forEach((e=>an(e)))}))})),(0,X.dqa)(".bb-comment").forEach(an)}));const rn=e=>{Jt.forEach((t=>e(t))),tn.push(e)},on=e=>{const{added:t,removed:n}=e;rn((e=>{t&&(e.items.forEach((e=>t(e))),Qt.push(t)),n&&en.push(n)}))},sn=(e,t)=>{const n=dq(e.element,".opera-list ul"),{className:i,text:a,action:r}=t;if(!n||dq(n,`.${i}`))return;const o=document.createElement("li");o.classList.add(i),o.textContent=a,o.addEventListener("click",(e=>{r(e)})),n.appendChild(o)};var ln=n(4350);const cn=JSON.parse('[[{"name":"首页","route":"/","tid":"","locid":23,"sub":[]},{"name":"动画","route":"douga","tid":1,"locid":52,"count":"","subMenuSize":162,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2507,"leftId":2452,"rightId":2453},"sub":[{"name":"MAD·AMV","route":"mad","tid":24,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":151},"desc":"具有一定制作程度的动画或静画的二次创作视频","url":"//www.bilibili.com/video/douga-mad-1.html"},{"name":"MMD·3D","route":"mmd","tid":25,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":152},"desc":"使用MMD(MikuMikuDance)和其他3D建模类软件制作的视频","url":"//www.bilibili.com/video/douga-mmd-1.html"},{"name":"短片·手书·配音","route":"voice","tid":47,"ps":15,"rps":10,"desc":"追求创新并具有强烈特色的短片、手书(绘)及ACG相关配音","url":"//www.bilibili.com/video/douga-voice-1.html"},{"name":"手办·模玩","route":"garage_kit","tid":210,"ps":15,"rps":10,"desc":"手办模玩的测评、改造或其他衍生内容","url":""},{"name":"特摄","route":"tokusatsu","tid":86,"ps":15,"rps":10,"desc":"特摄相关衍生视频","url":"//www.bilibili.com/video/cinephile-tokusatsu.html"},{"name":"综合","route":"other","tid":27,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":153},"desc":"以动画及动画相关内容为素材,包括但不仅限于音频替换、杂谈、排行榜等内容","url":"//www.bilibili.com/video/douga-else-1.html"}]},{"name":"番剧","route":"anime","tid":13,"url":"//www.bilibili.com/anime/","takeOvered":true,"count":"","subMenuSize":172,"combination":true,"sub":[{"name":"连载动画","tid":33,"route":"serial","desc":"当季连载的动画番剧","url":"//www.bilibili.com/video/bangumi-two-1.html"},{"name":"完结动画","tid":32,"route":"finish","desc":"已完结的动画番剧合集","url":"//www.bilibili.com/video/part-twoelement-1.html"},{"name":"资讯","tid":51,"route":"information","desc":"动画番剧相关资讯视频","url":"//www.bilibili.com/video/douga-else-information-1.html"},{"name":"官方延伸","tid":152,"route":"offical","desc":"动画番剧为主题的宣传节目、采访视频,及声优相关视频","url":"//www.bilibili.com/video/bagumi_offical_1.html"},{"name":"新番时间表","url":"//www.bilibili.com/anime/timeline/","desc":""},{"name":"番剧索引","url":"//www.bilibili.com/anime/index/","desc":""}]},{"name":"国创","tid":167,"route":"guochuang","url":"//www.bilibili.com/guochuang/","takeOvered":true,"count":"","subMenuSize":214,"combination":true,"sub":[{"name":"国产动画","tid":153,"route":"chinese","desc":"我国出品的PGC动画","url":"//www.bilibili.com/video/bangumi_chinese_1.html"},{"name":"国产原创相关","tid":168,"route":"original","desc":"","url":"//www.bilibili.com/video/guochuang-fanvid-1.html"},{"name":"布袋戏","tid":169,"route":"puppetry","desc":"","url":"//www.bilibili.com/video/glove-puppetry-1.html"},{"name":"动态漫·广播剧","tid":195,"route":"motioncomic","desc":"","url":""},{"name":"资讯","tid":170,"route":"information","desc":"","url":"//www.bilibili.com/video/guochuang-offical-1.html"},{"name":"新番时间表","url":"//www.bilibili.com/guochuang/timeline/","desc":""},{"name":"国产动画索引","url":"//www.bilibili.com/guochuang/index/","desc":""}]},{"name":"音乐","route":"music","tid":3,"locid":58,"count":"","subMenuSize":268,"slider":{"width":620,"height":220},"viewTag":true,"customComponent":{"name":"Energy","titleId":2511,"leftId":2462,"rightId":3131,"rightType":"slide"},"sub":[{"name":"原创音乐","route":"original","tid":28,"ps":15,"rps":10,"viewHotTag":true,"ad":{"active":true,"dataLocId":243},"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"个人或团队制作以音乐为主要原创因素的歌曲或纯音乐","url":"//www.bilibili.com/video/music-original-1.html"},{"name":"翻唱","route":"cover","tid":31,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":245},"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"一切非官方的人声再演绎歌曲作品","url":"//www.bilibili.com/video/music-Cover-1.html"},{"name":"VOCALOID·UTAU","route":"vocaloid","tid":30,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"以雅马哈Vocaloid和UTAU引擎为基础,包含其他调教引擎,运用各类音源进行的歌曲创作内容","url":"//www.bilibili.com/video/music-vocaloid-1.html"},{"name":"电音","route":"electronic","tid":194,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"以电子合成器、音乐软体等产生的电子声响制作的音乐","url":"#"},{"name":"演奏","route":"perform","tid":59,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":247},"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"传统或非传统乐器及器材的演奏作品","url":"//www.bilibili.com/video/music-perform-1.html"},{"name":"MV","route":"mv","tid":193,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"音乐录影带,为搭配音乐而拍摄或制作的视频","url":"//www.bilibili.com/video/music-coordinate-1.html"},{"name":"音乐现场","route":"live","tid":29,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"音乐实况表演视频","url":"//www.bilibili.com/video/music-oped-1.html"},{"name":"音乐综合","route":"other","tid":130,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"收录无法定义到其他音乐子分区的音乐视频","url":"//www.bilibili.com/video/music-collection-1.html"},{"name":"音频","customZone":"Audio","route":"audio","url":"//www.bilibili.com/audio/home?musicType=music"},{"name":"说唱","url":"//www.bilibili.com/v/rap"}]},{"name":"舞蹈","route":"dance","tid":129,"locid":64,"count":"","subMenuSize":172,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2513,"leftId":2472,"rightId":2473},"sub":[{"name":"宅舞","route":"otaku","tid":20,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":249},"desc":"与ACG相关的翻跳、原创舞蹈","url":"//www.bilibili.com/video/dance-1.html"},{"name":"街舞","route":"hiphop","tid":198,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":251},"desc":"收录街舞相关内容,包括赛事现场、舞室作品、个人翻跳、FREESTYLE等","url":""},{"name":"明星舞蹈","route":"star","tid":199,"ps":15,"rps":10,"desc":"国内外明星发布的官方舞蹈及其翻跳内容","url":""},{"name":"中国舞","route":"china","tid":200,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":253},"desc":"传承中国艺术文化的舞蹈内容,包括古典舞、民族民间舞、汉唐舞、古风舞等","url":""},{"name":"舞蹈综合","route":"three_d","tid":154,"ps":15,"rps":10,"desc":"收录无法定义到其他舞蹈子分区的舞蹈视频","url":""},{"name":"舞蹈教程","route":"demo","tid":156,"ps":10,"rps":6,"desc":"镜面慢速,动作分解,基础教程等具有教学意义的舞蹈视频","url":"//www.bilibili.com/video/dance-demo-1.html"}]},{"name":"游戏","route":"game","tid":4,"locid":70,"count":"","subMenuSize":240,"slider":{"width":470,"height":216},"viewTag":true,"customComponent":{"name":"Energy","titleId":3761,"leftId":3765,"rightId":3775,"rightType":"slide"},"recommendCardType":"GameGroomBox","sub":[{"name":"单机游戏","route":"stand_alone","tid":17,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":255},"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"以所有平台(PC、主机、移动端)的单机或联机游戏为主的视频内容,包括游戏预告、CG、实况解说及相关的评测、杂谈与视频剪辑等","url":"//www.bilibili.com/video/videogame-1.html"},{"name":"电子竞技","route":"esports","tid":171,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":257},"desc":"具有高对抗性的电子竞技游戏项目,其相关的赛事、实况、攻略、解说、短剧等视频。","url":"//www.bilibili.com/video/esports-1.html"},{"name":"手机游戏","route":"mobile","tid":172,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"desc":"以手机及平板设备为主要平台的游戏,其相关的实况、攻略、解说、短剧、演示等视频。","url":"//www.bilibili.com/video/mobilegame-1.html"},{"name":"网络游戏","route":"online","tid":65,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":259},"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"由网络运营商运营的多人在线游戏,以及电子竞技的相关游戏内容。包括赛事、攻略、实况、解说等相关视频","url":"//www.bilibili.com/video/onlinegame-1.html"},{"name":"桌游棋牌","route":"board","tid":173,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"desc":"桌游、棋牌、卡牌对战等及其相关电子版游戏的实况、攻略、解说、演示等视频。","url":"//www.bilibili.com/video/boardgame-1.html"},{"name":"GMV","route":"gmv","tid":121,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"由游戏素材制作的MV视频。以游戏内容或CG为主制作的,具有一定创作程度的MV类型的视频","url":"//www.bilibili.com/video/gmv-1.html"},{"name":"音游","route":"music","tid":136,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"各个平台上,通过配合音乐与节奏而进行的音乐类游戏视频","url":"//www.bilibili.com/video/music-game-1.html"},{"name":"Mugen","route":"mugen","tid":19,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"以Mugen引擎为平台制作、或与Mugen相关的游戏视频","url":"//www.bilibili.com/video/game-mugen-1.html"},{"name":"游戏赛事","url":"//www.bilibili.com/v/game/match/","newIcon":true}]},{"name":"知识","route":"knowledge","tid":36,"locid":76,"count":"","subMenuSize":172,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2058,"leftId":2047,"rightId":2048},"sub":[{"name":"科学科普","route":"science","tid":201,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":261},"desc":"回答你的十万个为什么"},{"name":"社科·法律·心理","route":"social_science","tid":124,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":263},"desc":"基于社会科学、法学、心理学展开或个人观点输出的知识视频"},{"name":"人文历史","route":"humanity_history","tid":228,"ps":15,"rps":10,"desc":"看看古今人物,聊聊历史过往,品品文学典籍"},{"name":"财经商业","route":"business","tid":207,"ps":15,"rps":10,"desc":"说金融市场,谈宏观经济,一起畅聊商业故事"},{"name":"校园学习","route":"campus","tid":208,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":265},"desc":"老师很有趣,学生也有才,我们一起搞学习"},{"name":"职业职场","route":"career","tid":209,"ps":15,"rps":10,"desc":"职业分享、升级指南,一起成为最有料的职场人"},{"name":"设计·创意","route":"design","tid":229,"ps":15,"rps":10,"desc":"天马行空,创意设计,都在这里"},{"name":"野生技能协会","route":"skill","tid":122,"ps":15,"rps":10,"desc":"技能党集合,是时候展示真正的技术了"}]},{"name":"科技","route":"tech","tid":188,"locid":2977,"count":"","subMenuSize":80,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2980,"leftId":2978,"rightId":2979},"sub":[{"name":"数码","route":"digital","tid":95,"ps":15,"rps":10,"viewHotTag":true,"desc":"科技数码产品大全,一起来做发烧友","url":"#"},{"name":"软件应用","route":"application","tid":230,"ps":15,"rps":10,"viewHotTag":true,"desc":"超全软件应用指南","url":"#"},{"name":"计算机技术","route":"computer_tech","tid":231,"ps":15,"rps":10,"viewHotTag":true,"desc":"研究分析、教学演示、经验分享......有关计算机技术的都在这里","url":"#"},{"name":"工业·工程·机械","route":"industry","tid":232,"ps":15,"rps":10,"viewHotTag":true,"desc":"前方高能,机甲重工即将出没","url":"#"},{"name":"极客DIY","route":"diy","tid":233,"ps":15,"rps":10,"viewHotTag":true,"desc":"炫酷技能,极客文化,硬核技巧,准备好你的惊讶","url":"#"}]},{"name":"运动","route":"sports","tid":234,"locid":4639,"isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4646,"rightId":4652,"rightType":"slide"},"sub":[{"name":"篮球·足球","route":"basketballfootball","tid":235,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4656},"desc":"与篮球、足球相关的视频,包括但不限于篮足球赛事、教学、评述、剪辑、剧情等相关内容","url":"#"},{"name":"健身","route":"aerobics","tid":164,"ps":15,"rps":10,"desc":"与健身相关的视频,包括但不限于瑜伽、CrossFit、健美、力量举、普拉提、街健等相关内容","url":"//www.bilibili.com/video/fashion-body-1.html"},{"name":"竞技体育","route":"athletic","tid":236,"ps":15,"rps":10,"desc":"与竞技体育相关的视频,包括但不限于乒乓、羽毛球、排球、赛车等竞技项目的赛事、评述、剪辑、剧情等相关内容","url":"#"},{"name":"运动文化","route":"culture","tid":237,"ps":15,"rps":10,"desc":"与运动文化相关的视频,包络但不限于球鞋、球衣、球星卡等运动衍生品的分享、解读,体育产业的分析、科普等相关内容","url":"#"},{"name":"运动综合","route":"comprehensive","tid":238,"ps":15,"rps":10,"desc":"与运动综合相关的视频,包括但不限于钓鱼、骑行、滑板等日常运动分享、教学、Vlog等相关内容","url":"#"}]},{"name":"汽车","route":"car","tid":223,"locid":4428,"isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4435,"rightId":4441,"rightType":"slide"},"sub":[{"name":"汽车生活","route":"life","tid":176,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4445},"desc":"分享汽车及出行相关的生活体验类视频","url":"#"},{"name":"汽车文化","route":"culture","tid":224,"ps":15,"rps":10,"desc":"车迷的精神圣地,包括汽车赛事、品牌历史、汽车改装、经典车型和汽车模型等","url":"#"},{"name":"汽车极客","route":"geek","tid":225,"ps":15,"rps":10,"desc":"汽车硬核达人聚集地,包括DIY造车、专业评测和技术知识分享","url":"#"},{"name":"智能出行","route":"smart","tid":226,"ps":15,"rps":10,"desc":"探索新能源汽车和未来智能出行的前沿阵地","url":"#"},{"name":"购车攻略","route":"strategy","tid":227,"ps":15,"rps":10,"desc":"丰富详实的购车建议和新车体验","url":"#"}]},{"name":"生活","route":"life","tid":160,"locid":88,"count":"","subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2062,"leftId":1674,"rightId":1670},"sub":[{"name":"搞笑","route":"funny","tid":138,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":273},"desc":"各种沙雕有趣的搞笑剪辑,挑战,表演,配音等视频","url":"//www.bilibili.com/video/ent_funny_1.html","locid":4204,"recommendId":4210,"slider":{"width":620,"height":220},"customComponent":{"name":"Energy","leftId":4212,"rightId":4218,"rightType":"slide"}},{"name":"家居房产","route":"home","tid":239,"ps":15,"rps":10,"desc":"与买房、装修、居家生活相关的分享","url":"#"},{"name":"手工","route":"handmake","tid":161,"ps":15,"rps":10,"desc":"手工制品的制作过程或成品展示、教程、测评类视频","url":"//www.bilibili.com/video/ent-handmake-1.html"},{"name":"绘画","route":"painting","tid":162,"ps":15,"rps":10,"desc":"绘画过程或绘画教程,以及绘画相关的所有视频","url":"//www.bilibili.com/video/ent-painting-1.html"},{"name":"日常","route":"daily","tid":21,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":275},"desc":"记录日常生活,分享生活故事","url":"//www.bilibili.com/video/ent-life-1.html"},{"name":"其他","route":"other","tid":174,"ps":15,"rps":10,"desc":"对分区归属不明的视频进行归纳整合的特定分区","url":"//www.bilibili.com/video/others-1.html"}]},{"name":"美食","route":"food","tid":211,"locid":4243,"count":"","isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4258,"rightId":4264},"sub":[{"name":"美食制作","route":"make","tid":76,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4268},"desc":"学做人间美味,展示精湛厨艺","url":"#"},{"name":"美食侦探","route":"detective","tid":212,"ps":15,"rps":10,"desc":"寻找美味餐厅,发现街头美食","url":"#"},{"name":"美食测评","route":"measurement","tid":213,"ps":15,"rps":10,"desc":"吃货世界,品尝世间美味","url":"#"},{"name":"田园美食","route":"rural","tid":214,"ps":15,"rps":10,"desc":"品味乡野美食,寻找山与海的味道","url":"#"},{"name":"美食记录","route":"record","tid":215,"ps":15,"rps":10,"desc":"记录一日三餐,给生活添一点幸福感","url":"#"}]},{"name":"动物圈","route":"animal","tid":217,"locid":4365,"count":"","isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4376,"rightId":4381,"rightType":"slide"},"sub":[{"name":"喵星人","route":"cat","tid":218,"ps":15,"rps":10,"desc":"喵喵喵喵喵","url":"#","ad":{"active":true,"dataLocId":4385}},{"name":"汪星人","route":"dog","tid":219,"ps":15,"rps":10,"desc":"汪汪汪汪汪","url":"#"},{"name":"大熊猫","route":"panda","tid":220,"ps":15,"rps":10,"desc":"芝麻汤圆营业中","url":"#"},{"name":"野生动物","route":"wild_animal","tid":221,"ps":15,"rps":10,"desc":"内有“猛兽”出没","url":"#"},{"name":"爬宠","route":"reptiles","tid":222,"ps":15,"rps":10,"desc":"鳞甲有灵","url":"#"},{"name":"动物综合","route":"animal_composite","tid":75,"ps":15,"rps":10,"desc":"收录除上述子分区外,其余动物相关视频以及非动物主体或多个动物主体的动物相关延伸内容","url":"#"}]},{"name":"鬼畜","route":"kichiku","tid":119,"locid":100,"count":"","subMenuSize":182,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2509,"leftId":2482,"rightId":2483},"sub":[{"name":"鬼畜调教","route":"guide","tid":22,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":285},"desc":"使用素材在音频、画面上做一定处理,达到与BGM一定的同步感","url":"//www.bilibili.com/video/ent-Kichiku-1.html"},{"name":"音MAD","route":"mad","tid":26,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":287},"desc":"使用素材音频进行一定的二次创作来达到还原原曲的非商业性质稿件","url":"//www.bilibili.com/video/douga-kichiku-1.html"},{"name":"人力VOCALOID","route":"manual_vocaloid","tid":126,"ps":15,"rps":10,"desc":"将人物或者角色的无伴奏素材进行人工调音,使其就像VOCALOID一样歌唱的技术","url":"//www.bilibili.com/video/kichiku-manual_vocaloid-1.html"},{"name":"鬼畜剧场","route":"theatre","tid":216,"ps":15,"rps":10,"desc":"使用素材进行人工剪辑编排的有剧情的作品"},{"name":"教程演示","route":"course","tid":127,"ps":10,"rps":6,"rightComponent":{"name":"CmImgList","id":148},"ad":{"active":true,"dataLocId":289},"hideDropdown":false,"desc":"鬼畜相关的教程演示","url":"//www.bilibili.com/video/kichiku-course-1.html"}]},{"name":"时尚","route":"fashion","tid":155,"locid":94,"count":"","subMenuSize":124,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2515,"leftId":2492,"rightId":2493},"sub":[{"name":"美妆","route":"makeup","tid":157,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":279},"desc":"涵盖妆容、发型、美甲等教程,彩妆、护肤相关产品测评、分享等","url":"//www.bilibili.com/video/fashion-makeup-fitness-1.html"},{"name":"服饰","route":"clothing","tid":158,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":281},"desc":"服饰风格、搭配技巧相关的展示和教程视频","url":"//www.bilibili.com/video/fashion-clothing-1.html"},{"name":"T台","route":"catwalk","tid":159,"ps":15,"rps":10,"desc":"发布会走秀现场及模特相关时尚片、采访、后台花絮","url":"#"},{"name":"风尚标","route":"trends","tid":192,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":283},"desc":"时尚明星专访、街拍、时尚购物相关知识科普","url":"#"}]},{"name":"资讯","route":"information","tid":202,"locid":4076,"count":"","subMenuSize":60,"slider":{"width":620,"height":220},"viewTag":false,"sub":[{"name":"热点","route":"hotspot","tid":203,"ps":18,"rps":10,"desc":"全民关注的时政热门资讯"},{"name":"环球","route":"global","tid":204,"ps":18,"rps":10,"desc":"全球范围内发生的具有重大影响力的事件动态"},{"name":"社会","route":"social","tid":205,"ps":18,"rps":10,"desc":"日常生活的社会事件、社会问题、社会风貌的报道"},{"name":"综合","route":"multiple","tid":206,"ps":18,"rps":10,"desc":"除上述领域外其它垂直领域的综合资讯"}]},{"name":"娱乐","route":"ent","tid":5,"locid":82,"count":"","subMenuSize":62,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2067,"leftId":2065,"rightId":2066},"sub":[{"name":"综艺","route":"variety","tid":71,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":267},"desc":"国内外有趣的综艺和综艺相关精彩剪辑","url":"//www.bilibili.com/video/ent-variety-1.html"},{"name":"明星","route":"star","tid":137,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":269},"desc":"娱乐圈动态、明星资讯相关","url":"//www.bilibili.com/video/ent-circle-1.html"}]},{"name":"影视","route":"cinephile","tid":181,"locid":2211,"count":"","subMenuSize":84,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2309,"leftId":2307,"rightId":2308},"sub":[{"name":"影视杂谈","route":"cinecism","tid":182,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2212},"desc":"影视评论、解说、吐槽、科普等","url":"//www.bilibili.com/video/cinephile-cinecism.html"},{"name":"影视剪辑","route":"montage","tid":183,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2213},"desc":"对影视素材进行剪辑再创作的视频","url":"//www.bilibili.com/video/cinephile-montage.html"},{"name":"短片","route":"shortfilm","tid":85,"ps":15,"rps":10,"desc":"追求自我表达且具有特色的短片","url":"//www.bilibili.com/video/cinephile-shortfilm.html"},{"name":"预告·资讯","route":"trailer_info","tid":184,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2214},"desc":"影视类相关资讯,预告,花絮等视频","url":"//www.bilibili.com/video/cinephile-trailer-info.html"}]},{"name":"纪录片","route":"documentary","tid":177,"url":"//www.bilibili.com/documentary/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"人文·历史","tid":37,"route":"history","dise":"","url":"//www.bilibili.com/video/doco-history.html"},{"name":"科学·探索·自然","tid":178,"route":"science","dise":"","url":"//www.bilibili.com/video/doco-science.html"},{"name":"军事","tid":179,"route":"military","dise":"","url":"//www.bilibili.com/video/doco-military.html"},{"name":"社会·美食·旅行","tid":180,"route":"travel","dise":"","url":"//www.bilibili.com/video/doco-travel.html"},{"name":"纪录片索引","url":"//www.bilibili.com/documentary/index/"}]},{"name":"电影","route":"movie","tid":23,"url":"//www.bilibili.com/movie/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"华语电影","tid":147,"route":"chinese","desc":"","url":"//www.bilibili.com/video/movie_chinese_1.html"},{"name":"欧美电影","tid":145,"route":"west","desc":"","url":"//www.bilibili.com/video/movie_west_1.html"},{"name":"日本电影","tid":146,"route":"japan","desc":"","url":"//www.bilibili.com/video/movie_japan_1.html"},{"name":"其他国家","tid":83,"route":"movie","desc":"","url":"//www.bilibili.com/video/movie-movie-1.html"},{"name":"电影索引","url":"//www.bilibili.com/movie/index/"}]},{"name":"电视剧","route":"tv","tid":11,"url":"//www.bilibili.com/tv/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"国产剧","tid":185,"route":"mainland","desc":"","url":"//www.bilibili.com/video/tv-mainland.html"},{"name":"海外剧","tid":187,"route":"overseas","desc":"","url":"//www.bilibili.com/video/tv-overseas.html"},{"name":"电视剧索引","url":"//www.bilibili.com/tv/index/"}]}],[{"url":"//live.bilibili.com/all?visit_id=5icxsa0kmts0","name":"全部直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=2&areaId=0&visit_id=5icxsa0kmts0#/2/0","name":"网游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=3&areaId=0&visit_id=5icxsa0kmts0#/3/0","name":"手游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=6&areaId=0","name":"单机直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=1&areaId=0&visit_id=5icxsa0kmts0#/1/0","name":"娱乐直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=5&areaId=0&visit_id=5icxsa0kmts0#/5/0","name":"电台直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=9&areaId=0","name":"虚拟直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=10&areaId=0","name":"生活直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=11&areaId=0","name":"学习直播"}],[{"name":"会员购","url":"//show.bilibili.com/platform/home.html","icon":"icon-vip-buy"},{"name":"游戏中心","url":"//game.bilibili.com","icon":"icon-game"},{"name":"画友","url":"http://h.bilibili.com","icon":"icon-hy"},{"name":"芒果TV","url":"//www.bilibili.com/mango","icon":"icon-mango"}],[{"name":"专栏","report":"article","url":"//www.bilibili.com/read/home","icon":"read"},{"name":"直播","report":"live","url":"//live.bilibili.com","icon":"live","sub":[{"url":"//live.bilibili.com/all?visit_id=5icxsa0kmts0","name":"全部直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=2&areaId=0&visit_id=5icxsa0kmts0#/2/0","name":"网游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=3&areaId=0&visit_id=5icxsa0kmts0#/3/0","name":"手游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=6&areaId=0","name":"单机直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=1&areaId=0&visit_id=5icxsa0kmts0#/1/0","name":"娱乐直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=5&areaId=0&visit_id=5icxsa0kmts0#/5/0","name":"电台直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=9&areaId=0","name":"虚拟直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=10&areaId=0","name":"生活直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=11&areaId=0","name":"学习直播"}]},{"name":"活动","report":"activity","url":"//www.bilibili.com/blackboard/activity-list.html","icon":"activit"},{"name":"课堂","report":"cheese","url":"//www.bilibili.com/cheese/","icon":"zhishi"},{"name":"小黑屋","report":"blackroom","url":"//www.bilibili.com/blackroom/","icon":"blackroom"},{"name":"新歌热榜","report":"musicplus","url":"//www.bilibili.com/v/musicplus/","icon":"musicplus"}],[{"name":"搞笑","url":"//www.bilibili.com/v/life/funny","tid":138,"count":"","hidePopover":true,"combination":true},{"name":"美食","url":"//www.bilibili.com/v/food","tid":211,"count":"","hidePopover":true,"combination":true},{"name":"动物圈","url":"//www.bilibili.com/v/animal","tid":217,"count":"","hidePopover":true,"combination":true},{"name":"单机游戏","url":"//www.bilibili.com/v/game/stand_alone","tid":17,"count":"","hidePopover":true,"combination":true},{"name":"运动","url":"//www.bilibili.com/v/sports","tid":234,"count":"","hidePopover":true,"combination":true},{"name":"汽车","url":"//www.bilibili.com/v/car","tid":223,"count":"","hidePopover":true,"combination":true},{"name":"VLOG","url":"//www.bilibili.com/v/life/daily/#/530003","hidePopover":true,"hideCount":true,"combination":true}]]'),dn=e=>e.startsWith("//")?`https:${e}`:e.replace("http:","https:"),un=cn[0].filter((e=>"string"!=typeof e.tid)),pn=cn[3],hn={},fn=["纪录片","电影","电视剧"];un.forEach((e=>{const t=dn(e.url||`https://www.bilibili.com/v/${e.route}/`);hn[e.name]={icon:e.route,code:e.tid,link:t,subCategories:e.sub?Object.fromEntries(e.sub.map((e=>{const n=dn(`${t}${e.route}/`);return[e.name,n]}))):null}})),hn.放映厅={icon:"cinema",code:fn.map((e=>hn[e].code)),link:"https://www.bilibili.com/cinema/",subCategories:Object.fromEntries(fn.map((e=>[e,hn[e].link])))},fn.forEach((e=>delete hn[e])),pn.forEach((e=>{hn[e.name]={icon:e.icon,code:null,link:dn(e.url),subCategories:e.sub?Object.fromEntries(e.sub.map((e=>[e.name,dn(e.url)]))):null}}));const mn=hn,gn=Object.fromEntries(un.map((e=>[e.route,e.tid]))),vn=Object.fromEntries(Object.values(hn).map((e=>[e.icon,e.link]))),bn=async()=>{if(document.getElementById("be-category-icons"))return;const{default:e}=await Promise.resolve().then(n.bind(n,382));document.body.insertAdjacentHTML("beforeend",e)};var yn=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"translate-container"},[e.working||e.translated?e._e():n("div",{staticClass:"translate",on:{click:function(t){return e.translate()}}},[n("VIcon",{attrs:{size:14,icon:"mdi-earth"}}),e._v("翻译\n ")],1),e._v(" "),e.translated?n("div",{staticClass:"translated"},[n("a",{attrs:{href:e.activeTranslator&&e.activeTranslator.link,target:"_blank"}},[e._v("\n 翻译自\n ")]),e._v(" "),n("VDropdown",{attrs:{items:Object.values(e.translateProviders),value:e.activeTranslator,"key-mapper":function(e){return e.name}},on:{change:function(t){return e.changeTranslator(t)}},scopedSlots:e._u([{key:"item",fn:function(t){var n=t.item;return[e._v("\n "+e._s(n.name)+"\n ")]}}],null,!1,1956376614)})],1):e._e(),e._v(" "),e.working?n("VIcon",{staticClass:"translating mdi-spin",attrs:{size:18,icon:"mdi-loading"}}):e._e(),e._v(" "),!e.working&&e.translated?n("div",{staticClass:"translate-result",domProps:{textContent:e._s(e.result)}}):e._e()],1)};yn._withStripped=!0;var wn=n(8494),xn=Vue.extend({components:{VDropdown:ce.VDropdown,VIcon:ce.VIcon},props:{text:{type:String,required:!0}},data:()=>({result:"",working:!1,translateProviders:wn.WK,activeTranslator:{}}),computed:{translated(){return""!==this.result}},methods:{changeTranslator(e){(0,R.getComponentSettings)("i18n").options.translator=e.name,this.translate()},async translate(){try{this.working=!0;const e=this.text.replace(/#(.+?)#/g,"");this.activeTranslator=(0,wn.Ty)();const t=this.activeTranslator;this.result=await t.translate(e)}catch(e){(0,ae.logError)(e)}finally{this.working=!1}}}}),_n=n(3109),kn=n.n(_n),Cn={insert:"head",singleton:!1},Sn=(Ne()(kn(),Cn),kn().locals,(0,Re.Z)(xn,yn,[],!1,null,null,null));Sn.options.__file="src/components/i18n/machine-translator/MachineTranslator.vue";var En=Sn.exports;const Mn=e=>{void 0===e.radio&&(e.radio=!1);const{name:t,switches:i}=e,a={};return Object.entries(i).forEach((([e,{displayName:t,defaultValue:n}])=>{a[`switch-${e}`]={defaultValue:n,displayName:t,hidden:!0}})),i=>{const r=`${i.displayName}选项`,o={componentName:i.name,optionDisplayName:r};Object.assign(e,o),a[t]={defaultValue:e,displayName:r},i.options={...i.options,...a},i.widget||(i.widget={component:()=>Promise.resolve().then(n.bind(n,5312)).then((e=>e.default)),options:e});const s=i.entry;return i.entry=async(...e)=>{s?.(...e);const{name:t}=i,n=(0,R.getComponentSettings)(t).options;Object.keys(n).forEach((e=>{e.startsWith("switch-")&&(0,R.addComponentListener)(`${t}.${e}`,(n=>{document.body.classList.toggle(`${t}-${e}`,n)}),!0)}))},i}};const zn={component:de,userComponent:ue,styledComponent:s,description:fe,switchOptions:k,launchBar:{LaunchBar:n(8805).Z},feeds:{api:c,BangumiCard:Ze,VideoCard:Qe,ColumnCard:ot,disableProfilePopup:d,notify:u},video:{assUtils:p,playerLight:h,playerAgent:kt,videoDanmaku:f,videoInfo:m,videoQuality:g,videoContextMenu:v,videoControlBar:b,watchlater:l},live:{liveControlBar:y,liveSocket:w},utils:{commentApis:x,categories:{updater:ln,data:_}},i18N:{machineTranslator:{MachineTranslator:En}}};var An=n(1773),$n=n(3865),On=n(9263);const In={style:An,plugin:$n,data:be,hook:On},Ln={ajax:C,cdnTypes:S,download:E,externalInput:M,filePicker:z,lifeCycle:A,loadingMode:$,meta:O,observer:I,reorder:i,runtimeLibrary:N,spinQuery:j,style:q,textColor:H,userInfo:a,version:r,settings:R,toast:se,themeColor:le,utils:{...X,constants:K,formatters:J,title:Y,i18n:Q,lazyPanel:o,log:ae,sort:re,urls:oe},ui:ce,componentApis:zn,pluginApis:In},Tn={ajax:C,...S,...E,...M,...z,lifeCycle:A,...$,...O,observer:I,...i,runtimeLibrary:N,spinQuery:j,...q,...H,...a,...r,settingsApis:R,get settings(){return R.settings},...se,utils:{...X,...K,...J,...Y,...Q,...o,...ae,...re,...oe},ui:ce,componentApis:{...zn.component,...zn.userComponent,...zn.styledComponent,...zn.launchBar,...lodash.omit(zn,"component","userComponent","styledComponent","launchBar")},pluginApis:{...In.style,...In.plugin,...In.data,...In.hook},monkeyApis:{GM_setValue:GM_setValue,GM_getValue:GM_getValue,GM_deleteValue:GM_deleteValue,GM_setClipboard:GM_setClipboard,GM_xmlhttpRequest:GM_xmlhttpRequest,GM_info:GM_info},lodash:lodash,Vue:Vue,sandboxWindow:window,theWorld:e=>{setTimeout((()=>{}),e)}}},595:function(e,t,n){"use strict";let i;n.d(t,{h:function(){return i}}),function(e){e.packed="打包下载",e.individual="单独下载"}(i||(i={}))},9356:function(e,t,n){"use strict";n.r(t),n.d(t,{DownloadPackage:function(){return l}});var i=n(595),a=n(6984),r=n(7724),o=n(2433);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class l{constructor(e=[]){this.entries=e,s(this,"noEscape",!1)}add(e,t,n={}){null!=t&&this.entries.push({name:this.noEscape?e:(0,o.formatFilename)(e),data:t,options:n})}async blob(){if(0===this.entries.length)return null;if(1===this.entries.length){const{data:e}=this.entries[0];return"string"==typeof e?new Blob([e]):e}const e=new(await a.JSZipLibrary);return this.entries.forEach((({name:t,data:n,options:i})=>{e.file(t,n,i)})),e.generateAsync({type:"blob"})}async emit(e){if(0===this.entries.length)return;e&&1!==this.entries.length||(e=this.entries[0].name);if((0,r.getGeneralSettings)().downloadPackageEmitMode===i.h.individual&&this.entries.length>1)return void await Promise.all(this.entries.map((e=>l.single(e.name,e.data,e.options))));const t=await this.blob();t&&l.download(e,t)}static download(e,t){const n=document.createElement("a"),i=URL.createObjectURL(t);l.lastPackageUrl&&URL.revokeObjectURL(l.lastPackageUrl),l.lastPackageUrl=i;const a=(0,o.formatFilename)(e);n.setAttribute("href",i),n.setAttribute("download",a),console.log("[Download file]",a),document.body.appendChild(n),n.click(),n.remove()}static async single(e,t,n={}){const i=new l;return i.add(e,t,n),i.emit()}}s(l,"lastPackageUrl","")},6522:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{parseExternalInput:function(){return parseExternalInput},batchParseCode:function(){return batchParseCode}});var _file_picker__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(9183);const parseExternalInput=async input=>{if(void 0===input){const files=await(0,_file_picker__WEBPACK_IMPORTED_MODULE_0__.pickFile)({accept:"application/json"});if(!(files.length>0))return console.error("[parseExternalInput] No file selected"),null;{const[file]=files,text=await file.text();try{return eval(`(${text})`)}catch(e){return console.error(e),null}}}else{if("string"!=typeof input)return input;try{const exports={},result=eval(input);if(Object.values(exports).length>0){const e=Object.values(exports)[0];return e}return result}catch(e){return console.error(e),null}}},batchParseCode=async inputs=>{try{const exports={},result=inputs.map((input=>eval(input)));if(Object.values(exports).length>0){const{coreApis:e}=await Promise.resolve().then(__webpack_require__.bind(__webpack_require__,5842));return Object.values(exports).map((t=>"function"==typeof t?t(e):t))}return result}catch(e){return console.error(e),null}}},9183:function(e,t,n){"use strict";let i,a;n.r(t),n.d(t,{pickFile:function(){return o}});const r={accept:"*",multiple:!1},o=async(e=r)=>{const{accept:t,multiple:n}={...r,...e};i||(i=document.createElement("input"),i.type="file",i.style.display="none",document.body.appendChild(i),i.addEventListener("change",(()=>{a?.([...i.files]),a=null}))),i.accept=t,i.multiple=n,i.value="",a&&a([]);return await new Promise((e=>{a=e,i.click()}))}},3575:function(e,t,n){"use strict";n.d(t,{m:function(){return s}});var i=n(559),a=n(9263),r=n(3865),o=n(1773);const s=async e=>{const{monkey:t}=await Promise.resolve().then(n.bind(n,6773)),s=await t({url:e}),{parseExternalInput:l}=await Promise.resolve().then(n.bind(n,6522)),c=await l(s),{type:d,installer:u}=(()=>{if((e=>"entry"in e)(c))return{type:"component",installer:()=>(0,i.installComponent)(s)};if((e=>"setup"in e)(c))return{type:"plugin",installer:()=>(0,r.installPlugin)(s)};if((e=>"style"in e)(c))return{type:"style",installer:()=>(0,o.installStyle)(s)};throw new Error("无效的功能代码")})(),{before:p,after:h}=(0,a.getHook)(`user${lodash.startCase(d)}s.add`,s,e);await p();const f=await u();return await h(f.metadata),f}},5527:function(e,t,n){"use strict";n.r(t),n.d(t,{headLoaded:function(){return a},contentLoaded:function(){return r},fullyLoaded:function(){return o},LifeCycleEventTypes:function(){return s},raiseLifeCycleEvent:function(){return l}});var i=n(9017);const a=e=>new Promise((t=>{if(null!==document.head)t(e());else{const[n]=(0,i.childList)(document.documentElement,(()=>{null!==document.head&&(n.disconnect(),t(e()))}))}})),r=e=>new Promise((t=>{"loading"!==document.readyState?t(e()):document.addEventListener("DOMContentLoaded",(()=>t(e())))})),o=e=>new Promise((t=>{"complete"===document.readyState?t(e()):unsafeWindow.addEventListener("load",(()=>t(e())))}));let s;!function(e){e.Start="be:start",e.StyleLoaded="be:style-loaded",e.ComponentsLoaded="be:components-loaded",e.End="be:end"}(s||(s={}));const l=e=>{unsafeWindow.dispatchEvent(new CustomEvent(e))}},4327:function(e,t,n){"use strict";let i;n.r(t),n.d(t,{LoadingMode:function(){return i}}),function(e){e.Delay="延后",e.Race="同时"}(i||(i={}))},7601:function(e,t,n){"use strict";n.r(t),n.d(t,{branches:function(){return r},meta:function(){return s}});var i=JSON.parse('{"version":"2.0.0","author":"Grant Howard, Coulomb-G","copyright":"[year], Grant Howard (https://github.com/the1812) & Coulomb-G (https://github.com/Coulomb-G)","licence":"MIT","match":"*://*.bilibili.com/*","exclude":["*://api.bilibili.com/*","*://api.*.bilibili.com/*","*://*.bilibili.com/api/*","*://member.bilibili.com/studio/bs-editor/*","*://message.bilibili.com/pages/nav/index_new_sync","*://message.bilibili.com/pages/nav/index_new_pc_sync","*://t.bilibili.com/h5/dynamic/specification","*://bbq.bilibili.com/*"],"run-at":"document-start","supportURL":"https://github.com/the1812/Bilibili-Evolved/issues","homepage":"https://github.com/the1812/Bilibili-Evolved","grant":["unsafeWindow","GM_getValue","GM_setValue","GM_deleteValue","GM_setClipboard","GM_info","GM_xmlhttpRequest"],"connect":["raw.githubusercontent.com","github.com","cdn.jsdelivr.net","cn.bing.com","www.bing.com","translate.google.cn","translate.google.com","localhost","*"],"require":["https://cdn.jsdelivr.net/npm/lodash@4.17.21/lodash.min.js"],"icon":"https://cdn.jsdelivr.net/gh/the1812/Bilibili-Evolved@preview/images/logo-small.png","icon64":"https://cdn.jsdelivr.net/gh/the1812/Bilibili-Evolved@preview/images/logo.png"}'),a=n(4011);i.copyright=i.copyright.replace(/\[year\]/g,(new Date).getFullYear().toString());const r={stable:"v2",preview:"preview"},o={commitHash:"ef06dd3f2de852c518c2b419348301d0c678645e",branch:"preview",nearestTag:"v2.0.0-preview1",versionWithTag:"v2.0.0-preview1-7-gef06dd3f2"},s={compilationInfo:o,name:GM_info.script.name,description:GM_info.script.description,get originalFilename(){const{branch:e}=o;return e===r.stable?"bilibili-evolved.user.js":`bilibili-evolved.${e}.user.js`},get updateURL(){return`${a.cdnRoots.jsDelivr(o.branch)}dist/${this.originalFilename}`},get downloadURL(){return this.updateURL},...i}},9017:function(e,t,n){"use strict";n.r(t),n.d(t,{childList:function(){return l},childListSubtree:function(){return c},attributes:function(){return d},attributesSubtree:function(){return u},characterData:function(){return p},characterDataSubtree:function(){return h},allMutationsOn:function(){return f},allMutations:function(){return g},visible:function(){return b},visibleInside:function(){return y},sizeChange:function(){return w},urlChange:function(){return _},videoChange:function(){return S}});var i=n(4742),a=n(4402),r=n(6363);const o=e=>"string"==typeof e?(0,i.dqa)(e):Array.isArray(e)?e:[e],s=(e,t,n)=>{const i=new MutationObserver(n);return e.forEach((e=>i.observe(e,t))),n([],i),[i,t]},l=(e,t)=>s(o(e),{childList:!0,subtree:!1,attributes:!1},t),c=(e,t)=>s(o(e),{childList:!0,subtree:!0,attributes:!1},t),d=(e,t)=>s(o(e),{childList:!1,subtree:!1,attributes:!0},t),u=(e,t)=>s(o(e),{childList:!1,subtree:!0,attributes:!0},t),p=(e,t)=>s(o(e),{childList:!1,subtree:!1,attributes:!1,characterData:!0},t),h=(e,t)=>s(o(e),{childList:!1,subtree:!0,attributes:!1,characterData:!0},t),f=(e,t)=>s(o(e),{childList:!0,subtree:!0,attributes:!0,characterData:!0},t),m={observer:null,config:null,callbacks:[]},g=e=>{if(m.observer)m.callbacks.push(e);else{m.callbacks.push(e);const[t,n]=f(document.body,(e=>m.callbacks.forEach((t=>t(e,m.observer)))));m.observer=t,m.config=n}return m},v=(e,t,n)=>{const i=new IntersectionObserver(n,t);return e.forEach((e=>i.observe(e))),[i,t]},b=(e,t)=>v(o(e),{},t),y=(e,t,n,i)=>v(o(e),{root:t,rootMargin:n},i),w=(e,t)=>((e,t,n)=>{const i=new ResizeObserver(n);return e.forEach((e=>i.observe(e,t))),[i,t]})(o(e),{box:"border-box"},t),x=lodash.once((()=>{let e=document.URL;g((()=>{e!==document.URL&&((()=>{const e=new CustomEvent("urlChange",{detail:document.URL});window.dispatchEvent(e)})(),e=document.URL)}))})),_=(e,t)=>{x(),e(document.URL),window.addEventListener("urlChange",(()=>e(document.URL)),t)},k=lodash.once((()=>(0,a.select)((()=>{if(unsafeWindow.cid)return unsafeWindow.cid;if(unsafeWindow.player&&unsafeWindow.player.getVideoMessage){const e=unsafeWindow.player.getVideoMessage();return Number.isNaN(e.cid)?null:(!unsafeWindow.aid&&e.aid&&(unsafeWindow.aid=e.aid.toString()),!unsafeWindow.bvid&&e.bvid&&(unsafeWindow.bvid=e.bvid),e.cid.toString())}return null}))));let C=!1;const S=async(e,t)=>{if(!(0,r.matchCurrentPage)(r.playerUrls))return!1;const{bpxPlayerPolyfill:i}=await Promise.resolve().then(n.bind(n,1479));i();const a=await k();if(null===a)return!1;const o=()=>({aid:unsafeWindow.aid,cid:unsafeWindow.cid});if(!C){let e=a;Object.defineProperty(unsafeWindow,"cid",{get:()=>e,set(t){e=t,Array.isArray(t)||(()=>{const e=o(),t=new CustomEvent("videoChange",{detail:e});window.dispatchEvent(t)})()}}),C=!0}return e(o()),window.addEventListener("videoChange",(t=>e(t.detail)),t),!0}},2428:function(e,t,n){"use strict";n.r(t),n.d(t,{componentLoadTime:function(){return i},componentResolveTime:function(){return a},componentLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async e=>{const{getGeneralSettings:t}=await Promise.resolve().then(n.bind(n,7724));if(!t().devMode)return;const r=e.entry;e.entry=async e=>{const{metadata:t}=e,n=performance.now();let o=r(e);const s=performance.now();o instanceof Promise&&(o=await o);const l=performance.now();return i.set(t,s-n),a.set(t,l-n),o}}},2053:function(e,t,n){"use strict";n.r(t),n.d(t,{pluginLoadTime:function(){return i},pluginResolveTime:function(){return a},pluginLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async e=>{const{getGeneralSettings:t}=await Promise.resolve().then(n.bind(n,7724));if(!t().devMode)return;const r=e.setup;e.setup=async t=>{const n=performance.now();let o=r(t);const s=performance.now();o instanceof Promise&&(o=await o);const l=performance.now();return i.set(e,s-n),a.set(e,l-n),o}}},5878:function(e,t,n){"use strict";n.r(t),n.d(t,{promiseLoadTime:function(){return i},promiseResolveTime:function(){return a},promiseLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async(e,t)=>{const{getGeneralSettings:r}=await Promise.resolve().then(n.bind(n,7724));if(!r().devMode)return t();const o=performance.now(),s=t(),l=performance.now(),c=await s,d=performance.now();return i.set({name:e},l-o),a.set({name:e},d-o),c}},9821:function(e,t,n){"use strict";n.r(t),n.d(t,{logStats:function(){return i}});const i=(e,t)=>{const n=[...t.entries()],i=n.reduce(((e,t)=>e+t[1]),0);console.groupCollapsed(`${e} time:`,Math.round(100*i)/100+"ms",`for ${n.length} items`),n.forEach((([e,t])=>{console.log(`%c${e.name} %c${Math.round(100*t)/100}ms ${Math.round(t/i*1e4)/100}% %c`,"color: #00A0D8","color: #888","color: unset")})),console.groupEnd()}},6984:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{RuntimeLibrary:function(){return RuntimeLibrary},protobufLibrary:function(){return protobufLibrary},JSZipLibrary:function(){return JSZipLibrary},SortableJSLibrary:function(){return SortableJSLibrary}});var _ajax__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(6773);function _defineProperty(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class RuntimeLibrary{constructor(e){this.config=e,_defineProperty(this,"modulePromise",void 0)}async then(resolve,reject){try{const{url:url,getModule:getModule}=this.config;this.modulePromise||(this.modulePromise=(async()=>{console.log(`[Runtime Library] Start download from ${url}`);const code=await(0,_ajax__WEBPACK_IMPORTED_MODULE_0__.monkey)({url:url});return console.log(`[Runtime Library] Downloaded from ${url} , length = ${code.length}`),function runEval(){return eval(code);// eslint-disable-next-line no-extra-bind +const t=e=>e.__vue__||e.parentElement.__vue__,n=async t=>{const n=await(0,j.sq)((()=>e.querySelector(t)),(t=>null!==t||null===e.parentNode),{queryInterval:100});if(null===e.parentNode)return"";if(null===n)return console.warn(e,t,e.parentNode),"";return n.innerText.trim()},i=e=>{if(void 0===e.card.origin)return{originalText:"",originalDescription:"",originalTitle:""};const t=JSON.parse(e.card.origin);return{originalText:e.originCardData.pureText,originalDescription:lodash.get(t,"item.description",""),originalTitle:t.title}},a=async e=>{const t=parseInt(await n(e));return isNaN(t)?0:t},r={id:e.getAttribute("data-did"),username:await n(".main-content .user-name"),text:"",reposts:await a(".button-bar .single-button:nth-child(1) .text-offset"),comments:await a(".button-bar .single-button:nth-child(2) .text-offset"),likes:await a(".button-bar .single-button:nth-child(3) .text-offset"),element:e,type:ke(e),get presented(){return null!==e.parentNode},async getText(){const n=await(async n=>{if(n===ye.bangumi)return"";const a=await(0,j.sq)((()=>e),(n=>Boolean(t(n)||!e.parentNode)),{queryInterval:100});if(null===e.parentNode)return"";if(null===a)return console.warn(a,e,t(a),e.parentNode),"";const r=t(a);if(n===ye.repost){const e=r.card.item.content,t=i(r);return[e,...Object.values(t).filter((e=>""!==e))].filter((e=>Boolean(e))).join("\n")}return[r.originCardData.pureText,r.originCardData.title].filter((e=>Boolean(e))).join("\n")})(this.type);return this.text=n,n}};if(await r.getText(),e.setAttribute("data-type",r.type.id.toString()),(e=>e.type===ye.repost)(r)){const n=r.username,a=t(r.element),o=lodash.get(a,"card.origin_user.info.uname","");n===o&&e.setAttribute("data-self-repost","true"),r.repostUsername=o,r.repostText=i(a).originalText}return r}updateCards(e){const t=".card[data-did]",n=e=>{if(e instanceof HTMLElement){if(e.matches(t))return e;const n=e.querySelector(t);if(n)return n}};return[...e.querySelectorAll(t)].forEach((e=>this.addCard(e))),(0,I.childList)(e,(e=>{e.forEach((e=>{e.addedNodes.forEach((e=>this.addCard(n(e)))),e.removedNodes.forEach((e=>this.removeCard(n(e))))}))}))}async startWatching(){if(this.watching)return!0;this.watching=!0;const[e]=(0,be.registerAndGetData)(Se,[]),t=e.find((e=>e.match.some((e=>(0,X.matchUrlPattern)(e)))));return t?t.watchCardsList(this):(console.warn("[FeedsCardsManager] No adaptor found",e),!1)}}const Me=new Ee,ze=e=>{(async()=>{if(!await Me.startWatching())return void console.error("feedsCardsManager.startWatching() failed");const{added:t}=e;t&&Me.cards.forEach((e=>t(e))),Ce.push({added:none,removed:none,...e})})()},Ae=e=>{const t=lodash.groupBy(e,(e=>e.aid)),n=e=>({id:e.upID,name:e.upName,faceUrl:e.upFaceUrl});return Object.values(t).map((e=>{if(1===e.length)return e[0];const[t,...i]=e;return t.cooperation=[n(t),...i.map(n)],console.log([...t.cooperation]),t})).sort((0,re.descendingStringSort)((e=>e.id)))},$e=e=>1===lodash.get(e,"extra.is_reserve_recall",0),Oe="feeds.contentFilters";(0,be.registerData)(Oe,[]);const Ie=e=>{const[t]=(0,be.getData)(Oe);return t.reduce(((e,t)=>t.filter(e)),e)},Le=e=>(...t)=>e(...t).then((e=>Ie(e))),Te=Le((async(e="video")=>{if(!(0,X.getUID)())return[];const t=await(0,C.getJsonWithCredentials)(`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${"video"===e?8:512}`);if(0!==t.code)throw new Error(t.message);const n=t.data.cards,i=n.filter((e=>!$e(JSON.parse(e.card))));return"video"===e?Ae(n.map((e=>{const t=JSON.parse(e.card),n=lodash.get(e,"display.topic_info.topic_details",[]).map((e=>({id:e.topic_id,name:e.topic_name})));return{id:e.desc.dynamic_id_str,aid:t.aid,bvid:e.desc.bvid||t.bvid,title:t.title,upID:e.desc.user_profile.info.uid,upName:e.desc.user_profile.info.uname,upFaceUrl:e.desc.user_profile.info.face,coverUrl:t.pic,description:t.desc,timestamp:e.timestamp,time:new Date(1e3*e.timestamp),topics:n,dynamic:t.dynamic,like:(0,J.formatCount)(e.desc.like),duration:t.duration,durationText:(0,J.formatDuration)(t.duration,0),playCount:(0,J.formatCount)(t.stat.view),danmakuCount:(0,J.formatCount)(t.stat.danmaku),watchlater:me.includes(t.aid)}}))):"bangumi"===e?i.map((e=>{const t=JSON.parse(e.card);return{id:e.desc.dynamic_id_str,aid:t.aid,bvid:e.desc.bvid||t.bvid,epID:t.episode_id,title:t.new_desc,upName:t.apiSeasonInfo.title,upFaceUrl:t.apiSeasonInfo.cover,coverUrl:t.cover,description:"",timestamp:e.timestamp,time:new Date(1e3*e.timestamp),like:(0,J.formatCount)(e.desc.like),durationText:"",playCount:(0,J.formatCount)(t.play_count),danmakuCount:(0,J.formatCount)(t.bullet_count),watchlater:!1}})):[]})),Pe=async(e,t)=>{if("string"==typeof e)return(0,C.getJsonWithCredentials)(`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${e}`);const n=e.id.toString();let i=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${n}`;return t&&(i=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_history?uid=${(0,X.getUID)()}&offset_dynamic_id=${t}&type=${n}`),(0,C.getJsonWithCredentials)(i)},De=(e,t)=>{const n=dq(e.element,".more-panel"),{className:i,text:a,action:r}=t;if(!n||dq(n,`.${i}`))return;const o=document.createElement("p");o.classList.add("child-button","c-pointer",i),o.textContent=a;[...new Set([...n.children].map((e=>e.getAttributeNames().filter((e=>e.startsWith("data-v-"))))).flat())].forEach((e=>o.setAttribute(e,""))),o.addEventListener("click",(t=>{r(t),e.element.click()})),n.appendChild(o)};var Ve=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"bangumi-card",class:{new:e.isNew},attrs:{target:"_blank",href:e.data.url}},[n("div",{staticClass:"ep-cover-container"},[n("DpiImage",{staticClass:"ep-cover",attrs:{size:{width:100},src:e.data.epCoverUrl}})],1),e._v(" "),n("h1",{staticClass:"ep-title",attrs:{title:e.data.epTitle}},[e._v(e._s(e.data.epTitle))]),e._v(" "),n("div",{staticClass:"up",attrs:{title:e.data.title}},[n("DpiImage",{staticClass:"cover",attrs:{size:24,src:e.data.coverUrl}}),e._v(" "),n("div",{staticClass:"title"},[e._v(e._s(e.data.title))])],1)])};Ve._withStripped=!0;var Be=Vue.extend({components:{DpiImage:ce.DpiImage},props:{data:{type:Object,required:!0},isNew:{type:Boolean,default:!1}}}),Fe=n(3379),Ne=n.n(Fe),je=n(4780),qe=n.n(je),He={insert:"head",singleton:!1},Re=(Ne()(qe(),He),qe().locals,n(1900)),Ue=(0,Re.Z)(Be,Ve,[],!1,null,"3bc2da4f",null);Ue.options.__file="src/components/feeds/BangumiCard.vue";var Ze=Ue.exports,We=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"video-card",class:{vertical:"vertical"===e.orientation,"no-stats":!e.showStats},attrs:{target:"_blank",href:e.epID?"https://www.bilibili.com/bangumi/play/ep"+e.epID:"https://www.bilibili.com/"+e.bvid}},[n("div",{staticClass:"cover-container"},[n("DpiImage",{staticClass:"cover",attrs:{src:e.coverUrl,size:{height:120,width:200}}}),e._v(" "),e.isNew?n("div",{staticClass:"new"},[e._v("NEW")]):e._e(),e._v(" "),e.pubTime&&e.pubTimeText?[n("div",{staticClass:"publish-time-summary"},[e._v("\n "+e._s(e.pubTimeText)+"\n ")]),e._v(" "),n("div",{staticClass:"publish-time-detail"},[e._v("\n "+e._s(e.pubTime)+"\n ")])]:e._e(),e._v(" "),e.durationText?n("div",{staticClass:"duration"},[e._v(e._s(e.durationText))]):e._e(),e._v(" "),e.durationText&&null!==e.watchlater&&void 0!==e.watchlater?n("div",{staticClass:"watchlater",on:{click:function(t){return t.stopPropagation(),t.preventDefault(),e.toggleWatchlater(e.aid)}}},[n("VIcon",{attrs:{size:15,icon:e.watchlater?"mdi-check-circle":"mdi-clock-outline"}}),e._v("\n "+e._s(e.watchlater?"已添加":"稍后再看")+"\n ")],1):e._e()],2),e._v(" "),n("h1",{staticClass:"title",attrs:{title:e.title}},[e._v(e._s(e.title))]),e._v(" "),e.topics&&e.topics.length?n("div",{staticClass:"topics"},e._l(e.topics.slice(0,3),(function(t){return n("a",{key:t.id,staticClass:"topic",attrs:{target:"_blank",href:"https://t.bilibili.com/topic/name/"+t.name+"/feed"}},[e._v("#"+e._s(t.name)+"#")])})),0):n("p",{staticClass:"description",attrs:{title:e.description}},[e._v(e._s(e.description))]),e._v(" "),0===e.cooperation.length?n("a",{staticClass:"up",class:{"no-face":!e.upFaceUrl},attrs:{target:"_blank",href:e.upID?"https://space.bilibili.com/"+e.upID:null}},[e.upFaceUrl?n("DpiImage",{staticClass:"face",attrs:{src:e.upFaceUrl,size:24}}):n("VIcon",{attrs:{icon:"up"}}),e._v(" "),n("div",{staticClass:"name",attrs:{title:e.upName}},[e._v(e._s(e.upName))])],1):e._e(),e._v(" "),0!==e.cooperation.length?n("div",{staticClass:"cooperation"},[n("div",{staticClass:"cooperation-ups"},e._l(e.reversedCooperation,(function(e){return n("a",{key:e.id,staticClass:"cooperation-up",class:{"no-face":!e.faceUrl},attrs:{target:"_blank",title:e.name,href:e.id?"https://space.bilibili.com/"+e.id:null}},[e.faceUrl?n("DpiImage",{staticClass:"face",attrs:{src:e.faceUrl,size:24}}):n("VIcon",{attrs:{icon:"up"}})],1)})),0),e._v(" "),n("div",{staticClass:"cooperation-note"},[e._v("\n 联合投稿\n ")])]):e._e(),e._v(" "),e.showStats?n("div",{staticClass:"stats"},[e.like&&!e.vertical?[n("VIcon",{attrs:{icon:"like-outline",size:18}}),e._v("\n "+e._s(e.like)+"\n ")]:e._e(),e._v(" "),e.coins&&!e.vertical?[n("VIcon",{attrs:{icon:"coin-outline",size:18}}),e._v("\n "+e._s(e.coins)+"\n ")]:e._e(),e._v(" "),e.favorites?[n("VIcon",{attrs:{icon:"favorites-outline",size:18}}),e._v("\n "+e._s(e.favorites)+"\n ")]:e._e(),e._v(" "),e.playCount?[n("VIcon",{attrs:{icon:"play",size:18}}),e._v("\n "+e._s(e.playCount)+"\n ")]:e._e(),e._v(" "),e.danmakuCount?[n("VIcon",{attrs:{icon:"danmaku",size:18}}),e._v("\n "+e._s(e.danmakuCount)+"\n ")]:e._e()],2):e._e()])};We._withStripped=!0;var Ge={components:{DpiImage:ce.DpiImage,VIcon:ce.VIcon},props:{data:{type:Object,required:!0},orientation:{type:String,default:"horizontal"},showStats:{type:Boolean,default:!0},isNew:{type:Boolean,default:!1}},data(){return{watchlaterList:me,upFaceUrl:"",danmakuCount:"",like:"",coins:"",favorites:"",dynamic:"",topics:[],upID:0,epID:0,cooperation:[],...lodash.omit(this.data,"watchlater"),watchlaterInit:this.data.watchlater}},computed:{vertical(){return"vertical"===this.orientation},watchlater(){return(0,X.getUID)()&&null!==this.watchlaterInit?this.watchlaterList.includes(this.aid):null},reversedCooperation(){return[...this.cooperation].reverse().slice(0,3)}},methods:{toggleWatchlater:ve}},Xe=n(1267),Ke=n.n(Xe),Je={insert:"head",singleton:!1},Ye=(Ne()(Ke(),Je),Ke().locals,(0,Re.Z)(Ge,We,[],!1,null,"0ffa1cb1",null));Ye.options.__file="src/components/feeds/VideoCard.vue";var Qe=Ye.exports,et=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"column-card",attrs:{target:"_blank",href:"https://www.bilibili.com/read/cv"+e.data.cvID}},[n("div",{staticClass:"covers"},e._l(e.data.covers,(function(e){return n("DpiImage",{key:e,staticClass:"cover",attrs:{size:{height:120},src:e}})})),1),e._v(" "),n("a",{staticClass:"up",attrs:{target:"_blank",href:"https://space.bilibili.com/"+e.data.upID}},[n("DpiImage",{staticClass:"face",attrs:{size:24,src:e.data.upFaceUrl}}),e._v(" "),n("div",{staticClass:"name"},[e._v(e._s(e.data.upName))])],1),e._v(" "),n("h1",{staticClass:"title",attrs:{title:e.data.title}},[e._v(e._s(e.data.title))]),e._v(" "),n("div",{staticClass:"description",attrs:{title:e.data.description}},[e._v(e._s(e.data.description))])])};et._withStripped=!0;var tt=Vue.extend({components:{DpiImage:ce.DpiImage},props:{data:{type:Object,required:!0},isNew:{type:Boolean,default:!1}}}),nt=n(807),it=n.n(nt),at={insert:"head",singleton:!1},rt=(Ne()(it(),at),it().locals,(0,Re.Z)(tt,et,[],!1,null,null,null));rt.options.__file="src/components/feeds/ColumnCard.vue";var ot=rt.exports;let st=!1;const lt=()=>{"https://t.bilibili.com/"===document.URL.replace(window.location.search,"")&&(async()=>{const{select:e}=await Promise.resolve().then(n.bind(n,4402)),t=await e(".live-up-list");if(null!==t){const{getComponentSettings:e}=await Promise.resolve().then(n.bind(n,7724));if(st)return;const i=e("fixedSidebars"),a=e("extendFeedsLive");t.addEventListener("mouseenter",(e=>{(i.enabled||a.enabled)&&e.stopImmediatePropagation()}),{capture:!0}),st=!0}})()},ct=3e5,dt=()=>(0,X.getCookieValue)(`bp_t_offset_${(0,X.getUID)()}`),ut=(e,t)=>e===t?0:e.length>t.length?1:t.length>e.length?-1:e>t==!0?1:-1,pt=e=>{if(null==e)return;const t=dt();ut(e,t)<0||(document.cookie=`bp_t_offset_${(0,X.getUID)()}=${e};path=/;domain=.bilibili.com;max-age=2592000`)},ht=e=>ut(e,dt())>0,ft=e=>{const[t]=[...e.map((e=>e.id))].sort(ut).reverse();pt(t)},mt=async e=>{const t=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_num?rsp_type=1&uid=${(0,X.getUID)()}&update_num_dy_id=${dt()}&type_list=${e||xe}`,n=await(0,C.getJsonWithCredentials)(t);return 0!==n.code?0:lodash.get(n,"data.update_num",0)},gt=e=>{e.startsWith("#")&&(e=e.substring(1));return{red:e.substring(0,2),green:e.substring(2,4),blue:e.substring(4,6)}},vt=e=>{const{red:t,green:n,blue:i}=gt(e);return`\\c&H${i}${n}${t}&`.toUpperCase()},bt=(e,t=1)=>{const{red:n,green:i,blue:a}=gt(e);return`&H${Math.round(255*(1-t)).toString(16).padStart(2,"0")}${a}${i}${n}`.toUpperCase()},yt=e=>{let t=0,n=0;for(;e>=60;)e-=60,n++;for(;n>=60;)n-=60,t++;return`${t}:${String(n).padStart(2,"0")}:${(e=>{const[t,n="00"]=String(e).split(".");return`${t.padStart(2,"0")}.${n.substr(0,2).padEnd(2,"0")}`})(e)}`},wt=(e,t)=>[yt(e),yt(e+t)],xt=(e,t)=>[yt(e),yt(t)],_t=e=>{const t={"{":"{","}":"}","&":"&","<":"<",">":">",""":'"',"'":"'","\n":"\\N"};for(const[n,i]of Object.entries(t))e=e.replace(new RegExp(n,"g"),i);return e};var kt=n(4572);let Ct=!1;const St=e=>oe.playerUrls.some((e=>(0,X.matchUrlPattern)(e)))?async()=>{Ct||(te(".bilibili-player-video-btn-setting",".bilibili-player-video-btn-setting-wrap",{style:".bilibili-player-video-btn-setting-wrap { display: none !important }"}),Ct=!0);const t=await(0,j.select)(".bilibili-player-video-btn-setting-right-others-content-lightoff .bui-checkbox-input");t.checked=!e,(0,X.raiseEvent)(t,"change")}:X.none,Et=St(!0),Mt=St(!1);let zt;const At=[],$t=async e=>{await(0,j.hasVideo)()&&(0,I.videoChange)((async()=>{const t=await kt.playerAgent.query.video.danmaku();t&&((e,t)=>{zt&&zt.disconnect(),[zt]=(0,I.childListSubtree)(e,(e=>{e.forEach((e=>{e.addedNodes.forEach((e=>{if(e.nodeType===Node.TEXT_NODE){const n=e.parentElement,i=At.find((e=>e.element===n));if(!i)return;return i.text=e.textContent||"",i.reuse=!0,void(t.added&&t.added(i))}if(!(e instanceof HTMLElement))return;const n={element:i=e,reuse:!1,text:i.textContent||""};var i;At.push(n),t.added&&t.added(n)})),e.removedNodes.forEach((e=>{if(!(e instanceof HTMLElement))return;const n=At.findIndex((t=>t.element===e));if(-1!==n){const[e]=At.splice(n,1);t.removed&&t.removed(e)}}))}))}))})(t,e)}))};function Ot(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class It{constructor(e){Ot(this,"aid",void 0),Ot(this,"cid",void 0),Ot(this,"pageCount",void 0),Ot(this,"coverUrl",void 0),Ot(this,"tagId",void 0),Ot(this,"tagName",void 0),Ot(this,"title",void 0),Ot(this,"description",void 0),Ot(this,"up",void 0),Ot(this,"pages",void 0),Ot(this,"subtitles",void 0),this.aid=e}async fetchInfo(){let e;e=this.cid?`https://api.bilibili.com/x/web-interface/view?aid=${this.aid}&cid=${this.cid}`:`https://api.bilibili.com/x/web-interface/view?aid=${this.aid}`;const t=await(0,C.getJson)(e);if(0!==t.code)throw new Error(t.message);const{data:n}=t;return this.cid=n.cid,this.pageCount=n.videos,this.coverUrl=n.pic.replace("http:","https:"),this.tagId=n.tid,this.tagName=n.tname,this.title=n.title,this.description=n.desc,this.up={uid:n.owner.mid,name:n.owner.name,faceUrl:n.owner.face.replace("http:","https:")},this.pages=n.pages.map((e=>({cid:e.cid,title:e.part,pageNumber:e.page}))),this.subtitles=n.subtitle.list.map((e=>({id:e.id,languageCode:e.lan,language:e.lan_doc,url:e.subtitle_url.replace("http:","https:")}))),this}}class Lt{constructor(e){Ot(this,"ep",void 0),Ot(this,"videos",void 0),Ot(this,"title",void 0),Ot(this,"cover",void 0),Ot(this,"squareCover",void 0),Ot(this,"aid",void 0),Ot(this,"cid",void 0),this.ep=e,this.videos=[]}async fetchInfo(){const e=await(0,C.getText)(`https://www.bilibili.com/bangumi/play/ep${this.ep}/`),t=JSON.parse(e.match(/window\.__INITIAL_STATE__=(.*);\(function\(\){/)[1]);return this.title=t.mediaInfo.title,this.cover=t.mediaInfo.cover,this.squareCover=t.mediaInfo.square_cover,this.aid=t.epInfo.aid,this.cid=t.epInfo.cid,this.videos=t.epList.map((async e=>({title:e.index_title,aid:e.aid,cid:e.cid,info:await new It(e.aid).fetchInfo()}))),this}}const Tt=[{name:"720P",displayName:"高清 720P",value:64},{name:"1080P",displayName:"高清 1080P",value:80}],Pt=[{name:"HDR",displayName:"真彩 HDR",value:125},{name:"4K",displayName:"超清 4K",value:120},{name:"1080P60",displayName:"高清 1080P60",value:116},{name:"1080P+",displayName:"高清 1080P+",value:112},{name:"720P60",displayName:"高清 720P60",value:74}],Dt=[...Pt,...Tt,{name:"480P",displayName:"清晰 480P",value:32},{name:"360P",displayName:"流畅 360P",value:16}].sort((0,re.descendingSort)((e=>e.value))),Vt=async e=>{const{open:t,close:n}=e;if(!(0,j.hasVideo)())return;const i=await(0,j.select)(".bilibili-player");if(!i)return;const[a]=(0,I.childList)(i,(()=>{const e=dq(".bilibili-player-context-menu-origin");if(e){a.disconnect();const i=dq(e,"ul"),r={containerElement:e,listElement:i,get itemElements(){return dqa(e,".context-menu-function")},get isOpen(){return e.classList.contains("active")}};(0,I.childList)(i,(()=>{r.isOpen?t?.(r):n?.(r)}))}}))},Bt=async(e,t)=>Vt({open:t=>{if(t.listElement.contains(e))return;const n=document.createElement("li");n.classList.add("context-line","context-menu-function"),n.setAttribute("data-append","1");const i=document.createElement("a");i.classList.add("context-menu-a","js-action"),i.href="javascript:void(0);",i.appendChild(e),n.addEventListener("mouseover",(()=>n.classList.add("hover"))),n.addEventListener("mouseout",(()=>n.classList.remove("hover"))),n.appendChild(i),t.listElement.appendChild(n)},close:e=>t?.(e)});let Ft;const Nt=[],jt=lodash.once((async()=>{oe.playerUrls.some((e=>(0,X.matchUrlPattern)(e)))&&(0,I.videoChange)((async()=>{const{playerAgent:e}=await Promise.resolve().then(n.bind(n,4572)),t=await e.query.control.buttons.time();if(null===t)return;const i=await Promise.resolve().then(n.bind(n,413)).then((e=>e.default));Ft=new i({propsData:{items:Nt}}).$mount(),t.insertAdjacentElement("afterend",Ft.$el)}))})),qt=async e=>{Ft||await jt(),Nt.push(e)},Ht=async e=>{if(!oe.liveUrls.some((e=>(0,X.matchUrlPattern)(e))))return;const t=await(0,j.select)(".bilibili-live-player-video-controller, .web-player-controller-wrap:not(.web-player-controller-bg)");if(!t)return;const{init:n,callback:i}=e;n?.(t),(0,I.childList)(t,(async()=>{const e=dq(t,".control-area");e&&i?.(e)}))};function Rt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const Ut=0,Zt=2,Wt={heartBeat:2,heartBeatResponse:3,message:5,enterRoom:7,enterRoomResponse:8};class Gt{constructor(){Rt(this,"textEncoder",new TextEncoder),Rt(this,"textDecoder",new TextDecoder)}static readInt(e,t,n){let i=0;for(let a=n-1;a>=0;a--)i+=256**(n-a-1)*e[t+a];return i}static writeInt(e,t,n,i){let a=0;for(;a{const i={packetLength:Gt.readInt(e,0,4),headerLength:Gt.readInt(e,4,2),protocolVersion:Gt.readInt(e,6,2),operation:Gt.readInt(e,8,4),sequenceID:Gt.readInt(e,12,4)},a=[i];if(i.packetLengthe.messages[0])))}else i.protocolVersion===Ut&&(i.messages=[JSON.parse(this.textDecoder.decode(a))])}else i.operation===Wt.heartBeatResponse&&(i.heartBeatResponse={count:Gt.readInt(e,16,4)});return a};return new Promise(((n,i)=>{const a=new FileReader;a.onload=async e=>{if(!e.target)return void i(e);const a=new Uint8Array(e.target.result);n(await t(a))},a.readAsArrayBuffer(e)}))}}class Xt{constructor(){Rt(this,"startTime",0)}getLiveTime(){return new Promise((e=>{if(this.startTime)return void e(this.startTime);const t=(0,X.dq)(".bilibili-live-player-video-controller-duration-btn span"),[n]=(0,I.childList)(t,(t=>{if(t.length>0&&t.some((e=>e.addedNodes.length>0&&[...e.addedNodes].every((e=>e.nodeType===Node.TEXT_NODE))))){n.disconnect();const i=t[0].addedNodes[0].textContent,[a,r,o=0]=i.split(":").reverse().map(lodash.unary(parseInt)),s=Number(new Date);this.startTime=s-1e3*o*3600-60*r*1e3-1e3*a,e(this.startTime)}}))}))}}class Kt extends EventTarget{constructor(e){super(),this.roomID=e,Rt(this,"heartBeatTimer",void 0),Rt(this,"webSocket",void 0),Rt(this,"retryInterval",200),Rt(this,"autoRetry",!0),Rt(this,"servers",["broadcastlv.chat.bilibili.com"]),Rt(this,"selectedServer",""),Rt(this,"liveTime",new Xt),Rt(this,"bufferHelper",new Gt),Rt(this,"stopRequested",!1),window.addEventListener("unload",(()=>this.stop()))}heartBeat(){this.webSocket.readyState===WebSocket.OPEN?this.webSocket.send(this.bufferHelper.encode("","heartBeat")):(this.stop(),this.restart())}restart(){if(this.dispatchEvent(new CustomEvent("restart")),!this.stopRequested&&this.autoRetry){console.log(`Live Socket: unexpected disconnect, retry in ${this.retryInterval}ms`);const e=this.servers.indexOf(this.selectedServer);ethis.start()),this.retryInterval)}}async start(){const e=await(0,C.getJson)(`https://api.live.bilibili.com/room/v1/Danmu/getConf?room_id=${this.roomID}&platform=pc&player=web`),t=lodash.get(e,"data.host_server_list",[]);this.servers=[...new Set([...this.servers,...t.map((e=>e.host))])],""===this.selectedServer&&([this.selectedServer]=this.servers,console.log("Initial server:",this.selectedServer)),this.webSocket&&[WebSocket.CONNECTING,WebSocket.OPEN].includes(this.webSocket.readyState)&&this.stop(),this.webSocket=new WebSocket(`wss://${this.selectedServer}/sub`),this.stopRequested=!1,this.dispatchEvent(new CustomEvent("start",{detail:this.webSocket})),this.webSocket.addEventListener("open",(()=>{const t={roomid:this.roomID,uid:parseInt((0,X.getUID)()),protover:2,platform:"web",clientVer:"1.10.1",type:"2",key:lodash.get(e,"data.token")};this.webSocket.send(this.bufferHelper.encode(JSON.stringify(t),"enterRoom")),this.dispatchEvent(new CustomEvent("open",{detail:t}))})),this.webSocket.addEventListener("message",(async e=>{const[t]=await this.bufferHelper.decode(e.data);switch(this.dispatchEvent(new CustomEvent("message",{detail:t})),t.operation){case Wt.enterRoomResponse:this.heartBeatTimer&&clearInterval(this.heartBeatTimer),this.heartBeatTimer=window.setInterval((()=>{this.heartBeat()}),3e4);break;case Wt.heartBeatResponse:if(!t.heartBeatResponse)break;this.dispatchEvent(new CustomEvent("heartBeatResponse",{detail:t.heartBeatResponse.count}));break;case Wt.message:{if(!t.messages)break;const e=await this.liveTime.getLiveTime();t.messages.forEach((t=>{if("DANMU_MSG"===t.cmd){const{info:n}=t,i={content:n[1],type:n[0][1],fontSize:n[0][2],color:n[0][3],sendTime:n[0][4],userHash:n[0][7],userID:n[2][0],userName:n[2][1],startTime:e,get time(){return this.sendTime-this.startTime}};this.dispatchEvent(new CustomEvent("danmaku",{detail:i}))}}));break}}})),this.webSocket.addEventListener("close",(e=>{this.stopRequested||(console.error("Live Socket: close",e),this.restart())})),this.webSocket.addEventListener("error",(e=>{console.error("Live Socket: error",e),this.restart()}))}stop(){this.stopRequested=!0,this.heartBeatTimer&&clearInterval(this.heartBeatTimer),this.webSocket&&this.webSocket.readyState===WebSocket.OPEN&&this.webSocket.close()}}const Jt=[],Yt="bb-comment",Qt=[],en=[],tn=[],nn=e=>{const t=e.querySelector(".con .user .name"),n=e=>{const t=e.querySelector(".reply-face"),n=e.querySelector(".reply-con .user .name");return{id:e.getAttribute("data-id"),element:e,userID:t.getAttribute("data-usercard-mid"),userName:n.textContent,content:e.querySelector(".text-con").textContent,timeText:e.querySelector(".info .time").textContent,likes:parseInt(e.querySelector(".info .like span").textContent)}},i={id:e.getAttribute("data-id"),element:e,userID:t.getAttribute("data-usercard-mid"),userName:t.textContent,content:e.querySelector(".con .text").textContent,timeText:e.querySelector(".con .info .time").textContent,likes:parseInt(e.querySelector(".con .like span").textContent),replies:[]};if(dq(e,".reply-box .view-more")){const t=dq(e,".reply-box");(0,I.childList)(t,(t=>{i.replies=(0,X.dqa)(e,".reply-box .reply-item").map(n),0!==t.length&&i.onRepliesUpdate?.(i.replies)}))}else i.replies=(0,X.dqa)(e,".reply-box .reply-item").map(n);return i},an=e=>{if(e instanceof HTMLElement&&e.classList.contains(Yt)){const t={element:e,items:[]};Jt.push(t),(e=>{e.observer||(e.items=(0,X.dqa)(e.element,".list-item.reply-wrap").map(nn),e.items.forEach((e=>{Qt.forEach((t=>t(e)))})),[e.observer]=(0,I.childListSubtree)(e.element,(t=>{t.forEach((t=>{const n=e=>e instanceof HTMLElement&&e.classList.contains("list-item")&&e.classList.contains("reply-wrap");t.addedNodes.forEach((t=>{if(n(t)){const n=nn(t);e.items.push(n),Qt.forEach((e=>e(n)))}})),t.removedNodes.forEach((t=>{if(n(t)){const n=t.getAttribute("data-id"),i=e.items.findIndex((e=>e.id===n));if(-1!==i){const[t]=e.items.splice(i,1);en.forEach((e=>e(t)))}}}))}))})))})(t),tn.forEach((e=>e(t)))}};(0,A.contentLoaded)((()=>{(0,I.allMutations)((e=>{e.forEach((e=>{e.addedNodes.forEach((e=>an(e)))}))})),(0,X.dqa)(".bb-comment").forEach(an)}));const rn=e=>{Jt.forEach((t=>e(t))),tn.push(e)},on=e=>{const{added:t,removed:n}=e;rn((e=>{t&&(e.items.forEach((e=>t(e))),Qt.push(t)),n&&en.push(n)}))},sn=(e,t)=>{const n=dq(e.element,".opera-list ul"),{className:i,text:a,action:r}=t;if(!n||dq(n,`.${i}`))return;const o=document.createElement("li");o.classList.add(i),o.textContent=a,o.addEventListener("click",(e=>{r(e)})),n.appendChild(o)};var ln=n(4350);const cn=JSON.parse('[[{"name":"首页","route":"/","tid":"","locid":23,"sub":[]},{"name":"动画","route":"douga","tid":1,"locid":52,"count":"","subMenuSize":162,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2507,"leftId":2452,"rightId":2453},"sub":[{"name":"MAD·AMV","route":"mad","tid":24,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":151},"desc":"具有一定制作程度的动画或静画的二次创作视频","url":"//www.bilibili.com/video/douga-mad-1.html"},{"name":"MMD·3D","route":"mmd","tid":25,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":152},"desc":"使用MMD(MikuMikuDance)和其他3D建模类软件制作的视频","url":"//www.bilibili.com/video/douga-mmd-1.html"},{"name":"短片·手书·配音","route":"voice","tid":47,"ps":15,"rps":10,"desc":"追求创新并具有强烈特色的短片、手书(绘)及ACG相关配音","url":"//www.bilibili.com/video/douga-voice-1.html"},{"name":"手办·模玩","route":"garage_kit","tid":210,"ps":15,"rps":10,"desc":"手办模玩的测评、改造或其他衍生内容","url":""},{"name":"特摄","route":"tokusatsu","tid":86,"ps":15,"rps":10,"desc":"特摄相关衍生视频","url":"//www.bilibili.com/video/cinephile-tokusatsu.html"},{"name":"综合","route":"other","tid":27,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":153},"desc":"以动画及动画相关内容为素材,包括但不仅限于音频替换、杂谈、排行榜等内容","url":"//www.bilibili.com/video/douga-else-1.html"}]},{"name":"番剧","route":"anime","tid":13,"url":"//www.bilibili.com/anime/","takeOvered":true,"count":"","subMenuSize":172,"combination":true,"sub":[{"name":"连载动画","tid":33,"route":"serial","desc":"当季连载的动画番剧","url":"//www.bilibili.com/video/bangumi-two-1.html"},{"name":"完结动画","tid":32,"route":"finish","desc":"已完结的动画番剧合集","url":"//www.bilibili.com/video/part-twoelement-1.html"},{"name":"资讯","tid":51,"route":"information","desc":"动画番剧相关资讯视频","url":"//www.bilibili.com/video/douga-else-information-1.html"},{"name":"官方延伸","tid":152,"route":"offical","desc":"动画番剧为主题的宣传节目、采访视频,及声优相关视频","url":"//www.bilibili.com/video/bagumi_offical_1.html"},{"name":"新番时间表","url":"//www.bilibili.com/anime/timeline/","desc":""},{"name":"番剧索引","url":"//www.bilibili.com/anime/index/","desc":""}]},{"name":"国创","tid":167,"route":"guochuang","url":"//www.bilibili.com/guochuang/","takeOvered":true,"count":"","subMenuSize":214,"combination":true,"sub":[{"name":"国产动画","tid":153,"route":"chinese","desc":"我国出品的PGC动画","url":"//www.bilibili.com/video/bangumi_chinese_1.html"},{"name":"国产原创相关","tid":168,"route":"original","desc":"","url":"//www.bilibili.com/video/guochuang-fanvid-1.html"},{"name":"布袋戏","tid":169,"route":"puppetry","desc":"","url":"//www.bilibili.com/video/glove-puppetry-1.html"},{"name":"动态漫·广播剧","tid":195,"route":"motioncomic","desc":"","url":""},{"name":"资讯","tid":170,"route":"information","desc":"","url":"//www.bilibili.com/video/guochuang-offical-1.html"},{"name":"新番时间表","url":"//www.bilibili.com/guochuang/timeline/","desc":""},{"name":"国产动画索引","url":"//www.bilibili.com/guochuang/index/","desc":""}]},{"name":"音乐","route":"music","tid":3,"locid":58,"count":"","subMenuSize":268,"slider":{"width":620,"height":220},"viewTag":true,"customComponent":{"name":"Energy","titleId":2511,"leftId":2462,"rightId":3131,"rightType":"slide"},"sub":[{"name":"原创音乐","route":"original","tid":28,"ps":15,"rps":10,"viewHotTag":true,"ad":{"active":true,"dataLocId":243},"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"个人或团队制作以音乐为主要原创因素的歌曲或纯音乐","url":"//www.bilibili.com/video/music-original-1.html"},{"name":"翻唱","route":"cover","tid":31,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":245},"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"一切非官方的人声再演绎歌曲作品","url":"//www.bilibili.com/video/music-Cover-1.html"},{"name":"VOCALOID·UTAU","route":"vocaloid","tid":30,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"以雅马哈Vocaloid和UTAU引擎为基础,包含其他调教引擎,运用各类音源进行的歌曲创作内容","url":"//www.bilibili.com/video/music-vocaloid-1.html"},{"name":"电音","route":"electronic","tid":194,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"以电子合成器、音乐软体等产生的电子声响制作的音乐","url":"#"},{"name":"演奏","route":"perform","tid":59,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":247},"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"传统或非传统乐器及器材的演奏作品","url":"//www.bilibili.com/video/music-perform-1.html"},{"name":"MV","route":"mv","tid":193,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"音乐录影带,为搭配音乐而拍摄或制作的视频","url":"//www.bilibili.com/video/music-coordinate-1.html"},{"name":"音乐现场","route":"live","tid":29,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"音乐实况表演视频","url":"//www.bilibili.com/video/music-oped-1.html"},{"name":"音乐综合","route":"other","tid":130,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"收录无法定义到其他音乐子分区的音乐视频","url":"//www.bilibili.com/video/music-collection-1.html"},{"name":"音频","customZone":"Audio","route":"audio","url":"//www.bilibili.com/audio/home?musicType=music"},{"name":"说唱","url":"//www.bilibili.com/v/rap"}]},{"name":"舞蹈","route":"dance","tid":129,"locid":64,"count":"","subMenuSize":172,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2513,"leftId":2472,"rightId":2473},"sub":[{"name":"宅舞","route":"otaku","tid":20,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":249},"desc":"与ACG相关的翻跳、原创舞蹈","url":"//www.bilibili.com/video/dance-1.html"},{"name":"街舞","route":"hiphop","tid":198,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":251},"desc":"收录街舞相关内容,包括赛事现场、舞室作品、个人翻跳、FREESTYLE等","url":""},{"name":"明星舞蹈","route":"star","tid":199,"ps":15,"rps":10,"desc":"国内外明星发布的官方舞蹈及其翻跳内容","url":""},{"name":"中国舞","route":"china","tid":200,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":253},"desc":"传承中国艺术文化的舞蹈内容,包括古典舞、民族民间舞、汉唐舞、古风舞等","url":""},{"name":"舞蹈综合","route":"three_d","tid":154,"ps":15,"rps":10,"desc":"收录无法定义到其他舞蹈子分区的舞蹈视频","url":""},{"name":"舞蹈教程","route":"demo","tid":156,"ps":10,"rps":6,"desc":"镜面慢速,动作分解,基础教程等具有教学意义的舞蹈视频","url":"//www.bilibili.com/video/dance-demo-1.html"}]},{"name":"游戏","route":"game","tid":4,"locid":70,"count":"","subMenuSize":240,"slider":{"width":470,"height":216},"viewTag":true,"customComponent":{"name":"Energy","titleId":3761,"leftId":3765,"rightId":3775,"rightType":"slide"},"recommendCardType":"GameGroomBox","sub":[{"name":"单机游戏","route":"stand_alone","tid":17,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":255},"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"以所有平台(PC、主机、移动端)的单机或联机游戏为主的视频内容,包括游戏预告、CG、实况解说及相关的评测、杂谈与视频剪辑等","url":"//www.bilibili.com/video/videogame-1.html"},{"name":"电子竞技","route":"esports","tid":171,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":257},"desc":"具有高对抗性的电子竞技游戏项目,其相关的赛事、实况、攻略、解说、短剧等视频。","url":"//www.bilibili.com/video/esports-1.html"},{"name":"手机游戏","route":"mobile","tid":172,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"desc":"以手机及平板设备为主要平台的游戏,其相关的实况、攻略、解说、短剧、演示等视频。","url":"//www.bilibili.com/video/mobilegame-1.html"},{"name":"网络游戏","route":"online","tid":65,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":259},"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"由网络运营商运营的多人在线游戏,以及电子竞技的相关游戏内容。包括赛事、攻略、实况、解说等相关视频","url":"//www.bilibili.com/video/onlinegame-1.html"},{"name":"桌游棋牌","route":"board","tid":173,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"desc":"桌游、棋牌、卡牌对战等及其相关电子版游戏的实况、攻略、解说、演示等视频。","url":"//www.bilibili.com/video/boardgame-1.html"},{"name":"GMV","route":"gmv","tid":121,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"由游戏素材制作的MV视频。以游戏内容或CG为主制作的,具有一定创作程度的MV类型的视频","url":"//www.bilibili.com/video/gmv-1.html"},{"name":"音游","route":"music","tid":136,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"各个平台上,通过配合音乐与节奏而进行的音乐类游戏视频","url":"//www.bilibili.com/video/music-game-1.html"},{"name":"Mugen","route":"mugen","tid":19,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"以Mugen引擎为平台制作、或与Mugen相关的游戏视频","url":"//www.bilibili.com/video/game-mugen-1.html"},{"name":"游戏赛事","url":"//www.bilibili.com/v/game/match/","newIcon":true}]},{"name":"知识","route":"knowledge","tid":36,"locid":76,"count":"","subMenuSize":172,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2058,"leftId":2047,"rightId":2048},"sub":[{"name":"科学科普","route":"science","tid":201,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":261},"desc":"回答你的十万个为什么"},{"name":"社科·法律·心理","route":"social_science","tid":124,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":263},"desc":"基于社会科学、法学、心理学展开或个人观点输出的知识视频"},{"name":"人文历史","route":"humanity_history","tid":228,"ps":15,"rps":10,"desc":"看看古今人物,聊聊历史过往,品品文学典籍"},{"name":"财经商业","route":"business","tid":207,"ps":15,"rps":10,"desc":"说金融市场,谈宏观经济,一起畅聊商业故事"},{"name":"校园学习","route":"campus","tid":208,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":265},"desc":"老师很有趣,学生也有才,我们一起搞学习"},{"name":"职业职场","route":"career","tid":209,"ps":15,"rps":10,"desc":"职业分享、升级指南,一起成为最有料的职场人"},{"name":"设计·创意","route":"design","tid":229,"ps":15,"rps":10,"desc":"天马行空,创意设计,都在这里"},{"name":"野生技能协会","route":"skill","tid":122,"ps":15,"rps":10,"desc":"技能党集合,是时候展示真正的技术了"}]},{"name":"科技","route":"tech","tid":188,"locid":2977,"count":"","subMenuSize":80,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2980,"leftId":2978,"rightId":2979},"sub":[{"name":"数码","route":"digital","tid":95,"ps":15,"rps":10,"viewHotTag":true,"desc":"科技数码产品大全,一起来做发烧友","url":"#"},{"name":"软件应用","route":"application","tid":230,"ps":15,"rps":10,"viewHotTag":true,"desc":"超全软件应用指南","url":"#"},{"name":"计算机技术","route":"computer_tech","tid":231,"ps":15,"rps":10,"viewHotTag":true,"desc":"研究分析、教学演示、经验分享......有关计算机技术的都在这里","url":"#"},{"name":"工业·工程·机械","route":"industry","tid":232,"ps":15,"rps":10,"viewHotTag":true,"desc":"前方高能,机甲重工即将出没","url":"#"},{"name":"极客DIY","route":"diy","tid":233,"ps":15,"rps":10,"viewHotTag":true,"desc":"炫酷技能,极客文化,硬核技巧,准备好你的惊讶","url":"#"}]},{"name":"运动","route":"sports","tid":234,"locid":4639,"isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4646,"rightId":4652,"rightType":"slide"},"sub":[{"name":"篮球·足球","route":"basketballfootball","tid":235,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4656},"desc":"与篮球、足球相关的视频,包括但不限于篮足球赛事、教学、评述、剪辑、剧情等相关内容","url":"#"},{"name":"健身","route":"aerobics","tid":164,"ps":15,"rps":10,"desc":"与健身相关的视频,包括但不限于瑜伽、CrossFit、健美、力量举、普拉提、街健等相关内容","url":"//www.bilibili.com/video/fashion-body-1.html"},{"name":"竞技体育","route":"athletic","tid":236,"ps":15,"rps":10,"desc":"与竞技体育相关的视频,包括但不限于乒乓、羽毛球、排球、赛车等竞技项目的赛事、评述、剪辑、剧情等相关内容","url":"#"},{"name":"运动文化","route":"culture","tid":237,"ps":15,"rps":10,"desc":"与运动文化相关的视频,包络但不限于球鞋、球衣、球星卡等运动衍生品的分享、解读,体育产业的分析、科普等相关内容","url":"#"},{"name":"运动综合","route":"comprehensive","tid":238,"ps":15,"rps":10,"desc":"与运动综合相关的视频,包括但不限于钓鱼、骑行、滑板等日常运动分享、教学、Vlog等相关内容","url":"#"}]},{"name":"汽车","route":"car","tid":223,"locid":4428,"isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4435,"rightId":4441,"rightType":"slide"},"sub":[{"name":"汽车生活","route":"life","tid":176,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4445},"desc":"分享汽车及出行相关的生活体验类视频","url":"#"},{"name":"汽车文化","route":"culture","tid":224,"ps":15,"rps":10,"desc":"车迷的精神圣地,包括汽车赛事、品牌历史、汽车改装、经典车型和汽车模型等","url":"#"},{"name":"汽车极客","route":"geek","tid":225,"ps":15,"rps":10,"desc":"汽车硬核达人聚集地,包括DIY造车、专业评测和技术知识分享","url":"#"},{"name":"智能出行","route":"smart","tid":226,"ps":15,"rps":10,"desc":"探索新能源汽车和未来智能出行的前沿阵地","url":"#"},{"name":"购车攻略","route":"strategy","tid":227,"ps":15,"rps":10,"desc":"丰富详实的购车建议和新车体验","url":"#"}]},{"name":"生活","route":"life","tid":160,"locid":88,"count":"","subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2062,"leftId":1674,"rightId":1670},"sub":[{"name":"搞笑","route":"funny","tid":138,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":273},"desc":"各种沙雕有趣的搞笑剪辑,挑战,表演,配音等视频","url":"//www.bilibili.com/video/ent_funny_1.html","locid":4204,"recommendId":4210,"slider":{"width":620,"height":220},"customComponent":{"name":"Energy","leftId":4212,"rightId":4218,"rightType":"slide"}},{"name":"家居房产","route":"home","tid":239,"ps":15,"rps":10,"desc":"与买房、装修、居家生活相关的分享","url":"#"},{"name":"手工","route":"handmake","tid":161,"ps":15,"rps":10,"desc":"手工制品的制作过程或成品展示、教程、测评类视频","url":"//www.bilibili.com/video/ent-handmake-1.html"},{"name":"绘画","route":"painting","tid":162,"ps":15,"rps":10,"desc":"绘画过程或绘画教程,以及绘画相关的所有视频","url":"//www.bilibili.com/video/ent-painting-1.html"},{"name":"日常","route":"daily","tid":21,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":275},"desc":"记录日常生活,分享生活故事","url":"//www.bilibili.com/video/ent-life-1.html"},{"name":"其他","route":"other","tid":174,"ps":15,"rps":10,"desc":"对分区归属不明的视频进行归纳整合的特定分区","url":"//www.bilibili.com/video/others-1.html"}]},{"name":"美食","route":"food","tid":211,"locid":4243,"count":"","isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4258,"rightId":4264},"sub":[{"name":"美食制作","route":"make","tid":76,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4268},"desc":"学做人间美味,展示精湛厨艺","url":"#"},{"name":"美食侦探","route":"detective","tid":212,"ps":15,"rps":10,"desc":"寻找美味餐厅,发现街头美食","url":"#"},{"name":"美食测评","route":"measurement","tid":213,"ps":15,"rps":10,"desc":"吃货世界,品尝世间美味","url":"#"},{"name":"田园美食","route":"rural","tid":214,"ps":15,"rps":10,"desc":"品味乡野美食,寻找山与海的味道","url":"#"},{"name":"美食记录","route":"record","tid":215,"ps":15,"rps":10,"desc":"记录一日三餐,给生活添一点幸福感","url":"#"}]},{"name":"动物圈","route":"animal","tid":217,"locid":4365,"count":"","isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4376,"rightId":4381,"rightType":"slide"},"sub":[{"name":"喵星人","route":"cat","tid":218,"ps":15,"rps":10,"desc":"喵喵喵喵喵","url":"#","ad":{"active":true,"dataLocId":4385}},{"name":"汪星人","route":"dog","tid":219,"ps":15,"rps":10,"desc":"汪汪汪汪汪","url":"#"},{"name":"大熊猫","route":"panda","tid":220,"ps":15,"rps":10,"desc":"芝麻汤圆营业中","url":"#"},{"name":"野生动物","route":"wild_animal","tid":221,"ps":15,"rps":10,"desc":"内有“猛兽”出没","url":"#"},{"name":"爬宠","route":"reptiles","tid":222,"ps":15,"rps":10,"desc":"鳞甲有灵","url":"#"},{"name":"动物综合","route":"animal_composite","tid":75,"ps":15,"rps":10,"desc":"收录除上述子分区外,其余动物相关视频以及非动物主体或多个动物主体的动物相关延伸内容","url":"#"}]},{"name":"鬼畜","route":"kichiku","tid":119,"locid":100,"count":"","subMenuSize":182,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2509,"leftId":2482,"rightId":2483},"sub":[{"name":"鬼畜调教","route":"guide","tid":22,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":285},"desc":"使用素材在音频、画面上做一定处理,达到与BGM一定的同步感","url":"//www.bilibili.com/video/ent-Kichiku-1.html"},{"name":"音MAD","route":"mad","tid":26,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":287},"desc":"使用素材音频进行一定的二次创作来达到还原原曲的非商业性质稿件","url":"//www.bilibili.com/video/douga-kichiku-1.html"},{"name":"人力VOCALOID","route":"manual_vocaloid","tid":126,"ps":15,"rps":10,"desc":"将人物或者角色的无伴奏素材进行人工调音,使其就像VOCALOID一样歌唱的技术","url":"//www.bilibili.com/video/kichiku-manual_vocaloid-1.html"},{"name":"鬼畜剧场","route":"theatre","tid":216,"ps":15,"rps":10,"desc":"使用素材进行人工剪辑编排的有剧情的作品"},{"name":"教程演示","route":"course","tid":127,"ps":10,"rps":6,"rightComponent":{"name":"CmImgList","id":148},"ad":{"active":true,"dataLocId":289},"hideDropdown":false,"desc":"鬼畜相关的教程演示","url":"//www.bilibili.com/video/kichiku-course-1.html"}]},{"name":"时尚","route":"fashion","tid":155,"locid":94,"count":"","subMenuSize":124,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2515,"leftId":2492,"rightId":2493},"sub":[{"name":"美妆","route":"makeup","tid":157,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":279},"desc":"涵盖妆容、发型、美甲等教程,彩妆、护肤相关产品测评、分享等","url":"//www.bilibili.com/video/fashion-makeup-fitness-1.html"},{"name":"服饰","route":"clothing","tid":158,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":281},"desc":"服饰风格、搭配技巧相关的展示和教程视频","url":"//www.bilibili.com/video/fashion-clothing-1.html"},{"name":"T台","route":"catwalk","tid":159,"ps":15,"rps":10,"desc":"发布会走秀现场及模特相关时尚片、采访、后台花絮","url":"#"},{"name":"风尚标","route":"trends","tid":192,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":283},"desc":"时尚明星专访、街拍、时尚购物相关知识科普","url":"#"}]},{"name":"资讯","route":"information","tid":202,"locid":4076,"count":"","subMenuSize":60,"slider":{"width":620,"height":220},"viewTag":false,"sub":[{"name":"热点","route":"hotspot","tid":203,"ps":18,"rps":10,"desc":"全民关注的时政热门资讯"},{"name":"环球","route":"global","tid":204,"ps":18,"rps":10,"desc":"全球范围内发生的具有重大影响力的事件动态"},{"name":"社会","route":"social","tid":205,"ps":18,"rps":10,"desc":"日常生活的社会事件、社会问题、社会风貌的报道"},{"name":"综合","route":"multiple","tid":206,"ps":18,"rps":10,"desc":"除上述领域外其它垂直领域的综合资讯"}]},{"name":"娱乐","route":"ent","tid":5,"locid":82,"count":"","subMenuSize":62,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2067,"leftId":2065,"rightId":2066},"sub":[{"name":"综艺","route":"variety","tid":71,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":267},"desc":"国内外有趣的综艺和综艺相关精彩剪辑","url":"//www.bilibili.com/video/ent-variety-1.html"},{"name":"明星","route":"star","tid":137,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":269},"desc":"娱乐圈动态、明星资讯相关","url":"//www.bilibili.com/video/ent-circle-1.html"}]},{"name":"影视","route":"cinephile","tid":181,"locid":2211,"count":"","subMenuSize":84,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2309,"leftId":2307,"rightId":2308},"sub":[{"name":"影视杂谈","route":"cinecism","tid":182,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2212},"desc":"影视评论、解说、吐槽、科普等","url":"//www.bilibili.com/video/cinephile-cinecism.html"},{"name":"影视剪辑","route":"montage","tid":183,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2213},"desc":"对影视素材进行剪辑再创作的视频","url":"//www.bilibili.com/video/cinephile-montage.html"},{"name":"短片","route":"shortfilm","tid":85,"ps":15,"rps":10,"desc":"追求自我表达且具有特色的短片","url":"//www.bilibili.com/video/cinephile-shortfilm.html"},{"name":"预告·资讯","route":"trailer_info","tid":184,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2214},"desc":"影视类相关资讯,预告,花絮等视频","url":"//www.bilibili.com/video/cinephile-trailer-info.html"}]},{"name":"纪录片","route":"documentary","tid":177,"url":"//www.bilibili.com/documentary/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"人文·历史","tid":37,"route":"history","dise":"","url":"//www.bilibili.com/video/doco-history.html"},{"name":"科学·探索·自然","tid":178,"route":"science","dise":"","url":"//www.bilibili.com/video/doco-science.html"},{"name":"军事","tid":179,"route":"military","dise":"","url":"//www.bilibili.com/video/doco-military.html"},{"name":"社会·美食·旅行","tid":180,"route":"travel","dise":"","url":"//www.bilibili.com/video/doco-travel.html"},{"name":"纪录片索引","url":"//www.bilibili.com/documentary/index/"}]},{"name":"电影","route":"movie","tid":23,"url":"//www.bilibili.com/movie/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"华语电影","tid":147,"route":"chinese","desc":"","url":"//www.bilibili.com/video/movie_chinese_1.html"},{"name":"欧美电影","tid":145,"route":"west","desc":"","url":"//www.bilibili.com/video/movie_west_1.html"},{"name":"日本电影","tid":146,"route":"japan","desc":"","url":"//www.bilibili.com/video/movie_japan_1.html"},{"name":"其他国家","tid":83,"route":"movie","desc":"","url":"//www.bilibili.com/video/movie-movie-1.html"},{"name":"电影索引","url":"//www.bilibili.com/movie/index/"}]},{"name":"电视剧","route":"tv","tid":11,"url":"//www.bilibili.com/tv/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"国产剧","tid":185,"route":"mainland","desc":"","url":"//www.bilibili.com/video/tv-mainland.html"},{"name":"海外剧","tid":187,"route":"overseas","desc":"","url":"//www.bilibili.com/video/tv-overseas.html"},{"name":"电视剧索引","url":"//www.bilibili.com/tv/index/"}]}],[{"url":"//live.bilibili.com/all?visit_id=5icxsa0kmts0","name":"全部直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=2&areaId=0&visit_id=5icxsa0kmts0#/2/0","name":"网游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=3&areaId=0&visit_id=5icxsa0kmts0#/3/0","name":"手游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=6&areaId=0","name":"单机直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=1&areaId=0&visit_id=5icxsa0kmts0#/1/0","name":"娱乐直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=5&areaId=0&visit_id=5icxsa0kmts0#/5/0","name":"电台直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=9&areaId=0","name":"虚拟直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=10&areaId=0","name":"生活直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=11&areaId=0","name":"学习直播"}],[{"name":"会员购","url":"//show.bilibili.com/platform/home.html","icon":"icon-vip-buy"},{"name":"游戏中心","url":"//game.bilibili.com","icon":"icon-game"},{"name":"画友","url":"http://h.bilibili.com","icon":"icon-hy"},{"name":"芒果TV","url":"//www.bilibili.com/mango","icon":"icon-mango"}],[{"name":"专栏","report":"article","url":"//www.bilibili.com/read/home","icon":"read"},{"name":"直播","report":"live","url":"//live.bilibili.com","icon":"live","sub":[{"url":"//live.bilibili.com/all?visit_id=5icxsa0kmts0","name":"全部直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=2&areaId=0&visit_id=5icxsa0kmts0#/2/0","name":"网游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=3&areaId=0&visit_id=5icxsa0kmts0#/3/0","name":"手游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=6&areaId=0","name":"单机直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=1&areaId=0&visit_id=5icxsa0kmts0#/1/0","name":"娱乐直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=5&areaId=0&visit_id=5icxsa0kmts0#/5/0","name":"电台直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=9&areaId=0","name":"虚拟直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=10&areaId=0","name":"生活直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=11&areaId=0","name":"学习直播"}]},{"name":"活动","report":"activity","url":"//www.bilibili.com/blackboard/activity-list.html","icon":"activit"},{"name":"课堂","report":"cheese","url":"//www.bilibili.com/cheese/","icon":"zhishi"},{"name":"小黑屋","report":"blackroom","url":"//www.bilibili.com/blackroom/","icon":"blackroom"},{"name":"新歌热榜","report":"musicplus","url":"//www.bilibili.com/v/musicplus/","icon":"musicplus"}],[{"name":"搞笑","url":"//www.bilibili.com/v/life/funny","tid":138,"count":"","hidePopover":true,"combination":true},{"name":"美食","url":"//www.bilibili.com/v/food","tid":211,"count":"","hidePopover":true,"combination":true},{"name":"动物圈","url":"//www.bilibili.com/v/animal","tid":217,"count":"","hidePopover":true,"combination":true},{"name":"单机游戏","url":"//www.bilibili.com/v/game/stand_alone","tid":17,"count":"","hidePopover":true,"combination":true},{"name":"运动","url":"//www.bilibili.com/v/sports","tid":234,"count":"","hidePopover":true,"combination":true},{"name":"汽车","url":"//www.bilibili.com/v/car","tid":223,"count":"","hidePopover":true,"combination":true},{"name":"VLOG","url":"//www.bilibili.com/v/life/daily/#/530003","hidePopover":true,"hideCount":true,"combination":true}]]'),dn=e=>e.startsWith("//")?`https:${e}`:e.replace("http:","https:"),un=cn[0].filter((e=>"string"!=typeof e.tid)),pn=cn[3],hn={},fn=["纪录片","电影","电视剧"];un.forEach((e=>{const t=dn(e.url||`https://www.bilibili.com/v/${e.route}/`);hn[e.name]={icon:e.route,code:e.tid,link:t,subCategories:e.sub?Object.fromEntries(e.sub.map((e=>{const n=dn(`${t}${e.route}/`);return[e.name,n]}))):null}})),hn.放映厅={icon:"cinema",code:fn.map((e=>hn[e].code)),link:"https://www.bilibili.com/cinema/",subCategories:Object.fromEntries(fn.map((e=>[e,hn[e].link])))},fn.forEach((e=>delete hn[e])),pn.forEach((e=>{hn[e.name]={icon:e.icon,code:null,link:dn(e.url),subCategories:e.sub?Object.fromEntries(e.sub.map((e=>[e.name,dn(e.url)]))):null}}));const mn=hn,gn=Object.fromEntries(un.map((e=>[e.route,e.tid]))),vn=Object.fromEntries(Object.values(hn).map((e=>[e.icon,e.link]))),bn=async()=>{if(document.getElementById("be-category-icons"))return;const{default:e}=await Promise.resolve().then(n.bind(n,382));document.body.insertAdjacentHTML("beforeend",e)};var yn=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"translate-container"},[e.working||e.translated?e._e():n("div",{staticClass:"translate",on:{click:function(t){return e.translate()}}},[n("VIcon",{attrs:{size:14,icon:"mdi-earth"}}),e._v("翻译\n ")],1),e._v(" "),e.translated?n("div",{staticClass:"translated"},[n("a",{attrs:{href:e.activeTranslator&&e.activeTranslator.link,target:"_blank"}},[e._v("\n 翻译自\n ")]),e._v(" "),n("VDropdown",{attrs:{items:Object.values(e.translateProviders),value:e.activeTranslator,"key-mapper":function(e){return e.name}},on:{change:function(t){return e.changeTranslator(t)}},scopedSlots:e._u([{key:"item",fn:function(t){var n=t.item;return[e._v("\n "+e._s(n.name)+"\n ")]}}],null,!1,1956376614)})],1):e._e(),e._v(" "),e.working?n("VIcon",{staticClass:"translating mdi-spin",attrs:{size:18,icon:"mdi-loading"}}):e._e(),e._v(" "),!e.working&&e.translated?n("div",{staticClass:"translate-result",domProps:{textContent:e._s(e.result)}}):e._e()],1)};yn._withStripped=!0;var wn=n(8494),xn=Vue.extend({components:{VDropdown:ce.VDropdown,VIcon:ce.VIcon},props:{text:{type:String,required:!0}},data:()=>({result:"",working:!1,translateProviders:wn.WK,activeTranslator:{}}),computed:{translated(){return""!==this.result}},methods:{changeTranslator(e){(0,R.getComponentSettings)("i18n").options.translator=e.name,this.translate()},async translate(){try{this.working=!0;const e=this.text.replace(/#(.+?)#/g,"");this.activeTranslator=(0,wn.Ty)();const t=this.activeTranslator;this.result=await t.translate(e)}catch(e){(0,ae.logError)(e)}finally{this.working=!1}}}}),_n=n(3109),kn=n.n(_n),Cn={insert:"head",singleton:!1},Sn=(Ne()(kn(),Cn),kn().locals,(0,Re.Z)(xn,yn,[],!1,null,null,null));Sn.options.__file="src/components/i18n/machine-translator/MachineTranslator.vue";var En=Sn.exports;const Mn=e=>{void 0===e.radio&&(e.radio=!1);const{name:t,switches:i}=e,a={};return Object.entries(i).forEach((([e,{displayName:t,defaultValue:n}])=>{a[`switch-${e}`]={defaultValue:n,displayName:t,hidden:!0}})),i=>{const r=`${i.displayName}选项`,o={componentName:i.name,optionDisplayName:r};Object.assign(e,o),a[t]={defaultValue:e,displayName:r},i.options={...i.options,...a},i.widget||(i.widget={component:()=>Promise.resolve().then(n.bind(n,5312)).then((e=>e.default)),options:e});const s=i.entry;return i.entry=async(...e)=>{s?.(...e);const{name:t}=i,n=(0,R.getComponentSettings)(t).options;Object.keys(n).forEach((e=>{e.startsWith("switch-")&&(0,R.addComponentListener)(`${t}.${e}`,(n=>{document.body.classList.toggle(`${t}-${e}`,n)}),!0)}))},i}};const zn={component:de,userComponent:ue,styledComponent:s,description:fe,switchOptions:k,launchBar:{LaunchBar:n(8805).Z},feeds:{api:c,BangumiCard:Ze,VideoCard:Qe,ColumnCard:ot,disableProfilePopup:d,notify:u},video:{assUtils:p,playerLight:h,playerAgent:kt,videoDanmaku:f,videoInfo:m,videoQuality:g,videoContextMenu:v,videoControlBar:b,watchlater:l},live:{liveControlBar:y,liveSocket:w},utils:{commentApis:x,categories:{updater:ln,data:_}},i18N:{machineTranslator:{MachineTranslator:En}}};var An=n(1773),$n=n(3865),On=n(9263);const In={style:An,plugin:$n,data:be,hook:On},Ln={ajax:C,cdnTypes:S,download:E,externalInput:M,filePicker:z,lifeCycle:A,loadingMode:$,meta:O,observer:I,reorder:i,runtimeLibrary:N,spinQuery:j,style:q,textColor:H,userInfo:a,version:r,settings:R,toast:se,themeColor:le,utils:{...X,constants:K,formatters:J,title:Y,i18n:Q,lazyPanel:o,log:ae,sort:re,urls:oe},ui:ce,componentApis:zn,pluginApis:In},Tn={ajax:C,...S,...E,...M,...z,lifeCycle:A,...$,...O,observer:I,...i,runtimeLibrary:N,spinQuery:j,...q,...H,...a,...r,settingsApis:R,get settings(){return R.settings},...se,utils:{...X,...K,...J,...Y,...Q,...o,...ae,...re,...oe},ui:ce,componentApis:{...zn.component,...zn.userComponent,...zn.styledComponent,...zn.launchBar,...lodash.omit(zn,"component","userComponent","styledComponent","launchBar")},pluginApis:{...In.style,...In.plugin,...In.data,...In.hook},monkeyApis:{GM_setValue:GM_setValue,GM_getValue:GM_getValue,GM_deleteValue:GM_deleteValue,GM_setClipboard:GM_setClipboard,GM_xmlhttpRequest:GM_xmlhttpRequest,GM_info:GM_info},lodash:lodash,Vue:Vue,sandboxWindow:window,theWorld:e=>{setTimeout((()=>{}),e)}}},595:function(e,t,n){"use strict";let i;n.d(t,{h:function(){return i}}),function(e){e.packed="打包下载",e.individual="单独下载"}(i||(i={}))},9356:function(e,t,n){"use strict";n.r(t),n.d(t,{DownloadPackage:function(){return l}});var i=n(595),a=n(6984),r=n(7724),o=n(2433);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class l{constructor(e=[]){this.entries=e,s(this,"noEscape",!1)}add(e,t,n={}){null!=t&&this.entries.push({name:this.noEscape?e:(0,o.formatFilename)(e),data:t,options:n})}async blob(){if(0===this.entries.length)return null;if(1===this.entries.length){const{data:e}=this.entries[0];return"string"==typeof e?new Blob([e]):e}const e=new(await a.JSZipLibrary);return this.entries.forEach((({name:t,data:n,options:i})=>{e.file(t,n,i)})),e.generateAsync({type:"blob"})}async emit(e){if(0===this.entries.length)return;e&&1!==this.entries.length||(e=this.entries[0].name);if((0,r.getGeneralSettings)().downloadPackageEmitMode===i.h.individual&&this.entries.length>1)return void await Promise.all(this.entries.map((e=>l.single(e.name,e.data,e.options))));const t=await this.blob();t&&l.download(e,t)}static download(e,t){const n=document.createElement("a"),i=URL.createObjectURL(t);l.lastPackageUrl&&URL.revokeObjectURL(l.lastPackageUrl),l.lastPackageUrl=i;const a=(0,o.formatFilename)(e);n.setAttribute("href",i),n.setAttribute("download",a),console.log("[Download file]",a),document.body.appendChild(n),n.click(),n.remove()}static async single(e,t,n={}){const i=new l;return i.add(e,t,n),i.emit()}}s(l,"lastPackageUrl","")},6522:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{parseExternalInput:function(){return parseExternalInput},batchParseCode:function(){return batchParseCode}});var _file_picker__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(9183);const parseExternalInput=async input=>{if(void 0===input){const files=await(0,_file_picker__WEBPACK_IMPORTED_MODULE_0__.pickFile)({accept:"application/json"});if(!(files.length>0))return console.error("[parseExternalInput] No file selected"),null;{const[file]=files,text=await file.text();try{return eval(`(${text})`)}catch(e){return console.error(e),null}}}else{if("string"!=typeof input)return input;try{const exports={},result=eval(input);if(Object.values(exports).length>0){const e=Object.values(exports)[0];return e}return result}catch(e){return console.error(e),null}}},batchParseCode=async inputs=>{try{const exports={},result=inputs.map((input=>eval(input)));if(Object.values(exports).length>0){const{coreApis:e}=await Promise.resolve().then(__webpack_require__.bind(__webpack_require__,5842));return Object.values(exports).map((t=>"function"==typeof t?t(e):t))}return result}catch(e){return console.error(e),null}}},9183:function(e,t,n){"use strict";let i,a;n.r(t),n.d(t,{pickFile:function(){return o}});const r={accept:"*",multiple:!1},o=async(e=r)=>{const{accept:t,multiple:n}={...r,...e};i||(i=document.createElement("input"),i.type="file",i.style.display="none",document.body.appendChild(i),i.addEventListener("change",(()=>{a?.([...i.files]),a=null}))),i.accept=t,i.multiple=n,i.value="",a&&a([]);return await new Promise((e=>{a=e,i.click()}))}},3575:function(e,t,n){"use strict";n.d(t,{m:function(){return s}});var i=n(559),a=n(9263),r=n(3865),o=n(1773);const s=async e=>{const{monkey:t}=await Promise.resolve().then(n.bind(n,6773)),s=await t({url:e}),{parseExternalInput:l}=await Promise.resolve().then(n.bind(n,6522)),c=await l(s),{type:d,installer:u}=(()=>{if((e=>"entry"in e)(c))return{type:"component",installer:()=>(0,i.installComponent)(s)};if((e=>"setup"in e)(c))return{type:"plugin",installer:()=>(0,r.installPlugin)(s)};if((e=>"style"in e)(c))return{type:"style",installer:()=>(0,o.installStyle)(s)};throw new Error("无效的功能代码")})(),{before:p,after:h}=(0,a.getHook)(`user${lodash.startCase(d)}s.add`,s,e);await p();const f=await u();return await h(f.metadata),f}},5527:function(e,t,n){"use strict";n.r(t),n.d(t,{headLoaded:function(){return a},contentLoaded:function(){return r},fullyLoaded:function(){return o},LifeCycleEventTypes:function(){return s},raiseLifeCycleEvent:function(){return l}});var i=n(9017);const a=e=>new Promise((t=>{if(null!==document.head)t(e());else{const[n]=(0,i.childList)(document.documentElement,(()=>{null!==document.head&&(n.disconnect(),t(e()))}))}})),r=e=>new Promise((t=>{"loading"!==document.readyState?t(e()):document.addEventListener("DOMContentLoaded",(()=>t(e())))})),o=e=>new Promise((t=>{"complete"===document.readyState?t(e()):unsafeWindow.addEventListener("load",(()=>t(e())))}));let s;!function(e){e.Start="be:start",e.StyleLoaded="be:style-loaded",e.ComponentsLoaded="be:components-loaded",e.End="be:end"}(s||(s={}));const l=e=>{unsafeWindow.dispatchEvent(new CustomEvent(e))}},4327:function(e,t,n){"use strict";let i;n.r(t),n.d(t,{LoadingMode:function(){return i}}),function(e){e.Delay="延后",e.Race="同时"}(i||(i={}))},7601:function(e,t,n){"use strict";n.r(t),n.d(t,{branches:function(){return r},meta:function(){return s}});var i=JSON.parse('{"version":"2.0.0","author":"Grant Howard, Coulomb-G","copyright":"[year], Grant Howard (https://github.com/the1812) & Coulomb-G (https://github.com/Coulomb-G)","licence":"MIT","match":"*://*.bilibili.com/*","exclude":["*://api.bilibili.com/*","*://api.*.bilibili.com/*","*://*.bilibili.com/api/*","*://member.bilibili.com/studio/bs-editor/*","*://message.bilibili.com/pages/nav/index_new_sync","*://message.bilibili.com/pages/nav/index_new_pc_sync","*://t.bilibili.com/h5/dynamic/specification","*://bbq.bilibili.com/*"],"run-at":"document-start","supportURL":"https://github.com/the1812/Bilibili-Evolved/issues","homepage":"https://github.com/the1812/Bilibili-Evolved","grant":["unsafeWindow","GM_getValue","GM_setValue","GM_deleteValue","GM_setClipboard","GM_info","GM_xmlhttpRequest"],"connect":["raw.githubusercontent.com","github.com","cdn.jsdelivr.net","cn.bing.com","www.bing.com","translate.google.cn","translate.google.com","localhost","*"],"require":["https://cdn.jsdelivr.net/npm/lodash@4.17.21/lodash.min.js"],"icon":"https://cdn.jsdelivr.net/gh/the1812/Bilibili-Evolved@preview/images/logo-small.png","icon64":"https://cdn.jsdelivr.net/gh/the1812/Bilibili-Evolved@preview/images/logo.png"}'),a=n(4011);i.copyright=i.copyright.replace(/\[year\]/g,(new Date).getFullYear().toString());const r={stable:"v2",preview:"preview"},o={commitHash:"eb759ea254acb0e2f4b4a8ec428a8cf421ca2731",branch:"preview",nearestTag:"v2.0.0-preview1",versionWithTag:"v2.0.0-preview1-10-geb759ea25"},s={compilationInfo:o,name:GM_info.script.name,description:GM_info.script.description,get originalFilename(){const{branch:e}=o;return e===r.stable?"bilibili-evolved.user.js":`bilibili-evolved.${e}.user.js`},get updateURL(){return`${a.cdnRoots.jsDelivr(o.branch)}dist/${this.originalFilename}`},get downloadURL(){return this.updateURL},...i}},9017:function(e,t,n){"use strict";n.r(t),n.d(t,{childList:function(){return l},childListSubtree:function(){return c},attributes:function(){return d},attributesSubtree:function(){return u},characterData:function(){return p},characterDataSubtree:function(){return h},allMutationsOn:function(){return f},allMutations:function(){return g},visible:function(){return b},visibleInside:function(){return y},sizeChange:function(){return w},urlChange:function(){return _},videoChange:function(){return S}});var i=n(4742),a=n(4402),r=n(6363);const o=e=>"string"==typeof e?(0,i.dqa)(e):Array.isArray(e)?e:[e],s=(e,t,n)=>{const i=new MutationObserver(n);return e.forEach((e=>i.observe(e,t))),n([],i),[i,t]},l=(e,t)=>s(o(e),{childList:!0,subtree:!1,attributes:!1},t),c=(e,t)=>s(o(e),{childList:!0,subtree:!0,attributes:!1},t),d=(e,t)=>s(o(e),{childList:!1,subtree:!1,attributes:!0},t),u=(e,t)=>s(o(e),{childList:!1,subtree:!0,attributes:!0},t),p=(e,t)=>s(o(e),{childList:!1,subtree:!1,attributes:!1,characterData:!0},t),h=(e,t)=>s(o(e),{childList:!1,subtree:!0,attributes:!1,characterData:!0},t),f=(e,t)=>s(o(e),{childList:!0,subtree:!0,attributes:!0,characterData:!0},t),m={observer:null,config:null,callbacks:[]},g=e=>{if(m.observer)m.callbacks.push(e);else{m.callbacks.push(e);const[t,n]=f(document.body,(e=>m.callbacks.forEach((t=>t(e,m.observer)))));m.observer=t,m.config=n}return m},v=(e,t,n)=>{const i=new IntersectionObserver(n,t);return e.forEach((e=>i.observe(e))),[i,t]},b=(e,t)=>v(o(e),{},t),y=(e,t,n,i)=>v(o(e),{root:t,rootMargin:n},i),w=(e,t)=>((e,t,n)=>{const i=new ResizeObserver(n);return e.forEach((e=>i.observe(e,t))),[i,t]})(o(e),{box:"border-box"},t),x=lodash.once((()=>{let e=document.URL;g((()=>{e!==document.URL&&((()=>{const e=new CustomEvent("urlChange",{detail:document.URL});window.dispatchEvent(e)})(),e=document.URL)}))})),_=(e,t)=>{x(),e(document.URL),window.addEventListener("urlChange",(()=>e(document.URL)),t)},k=lodash.once((()=>(0,a.select)((()=>{if(unsafeWindow.cid)return unsafeWindow.cid;if(unsafeWindow.player&&unsafeWindow.player.getVideoMessage){const e=unsafeWindow.player.getVideoMessage();return Number.isNaN(e.cid)?null:(!unsafeWindow.aid&&e.aid&&(unsafeWindow.aid=e.aid.toString()),!unsafeWindow.bvid&&e.bvid&&(unsafeWindow.bvid=e.bvid),e.cid.toString())}return null}))));let C=!1;const S=async(e,t)=>{if(!(0,r.matchCurrentPage)(r.playerUrls))return!1;const{bpxPlayerPolyfill:i}=await Promise.resolve().then(n.bind(n,1479));i();const a=await k();if(null===a)return!1;const o=()=>({aid:unsafeWindow.aid,cid:unsafeWindow.cid});if(!C){let e=a;Object.defineProperty(unsafeWindow,"cid",{get:()=>e,set(t){e=t,Array.isArray(t)||(()=>{const e=o(),t=new CustomEvent("videoChange",{detail:e});window.dispatchEvent(t)})()}}),C=!0}return e(o()),window.addEventListener("videoChange",(t=>e(t.detail)),t),!0}},2428:function(e,t,n){"use strict";n.r(t),n.d(t,{componentLoadTime:function(){return i},componentResolveTime:function(){return a},componentLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async e=>{const{getGeneralSettings:t}=await Promise.resolve().then(n.bind(n,7724));if(!t().devMode)return;const r=e.entry;e.entry=async e=>{const{metadata:t}=e,n=performance.now();let o=r(e);const s=performance.now();o instanceof Promise&&(o=await o);const l=performance.now();return i.set(t,s-n),a.set(t,l-n),o}}},2053:function(e,t,n){"use strict";n.r(t),n.d(t,{pluginLoadTime:function(){return i},pluginResolveTime:function(){return a},pluginLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async e=>{const{getGeneralSettings:t}=await Promise.resolve().then(n.bind(n,7724));if(!t().devMode)return;const r=e.setup;e.setup=async t=>{const n=performance.now();let o=r(t);const s=performance.now();o instanceof Promise&&(o=await o);const l=performance.now();return i.set(e,s-n),a.set(e,l-n),o}}},5878:function(e,t,n){"use strict";n.r(t),n.d(t,{promiseLoadTime:function(){return i},promiseResolveTime:function(){return a},promiseLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async(e,t)=>{const{getGeneralSettings:r}=await Promise.resolve().then(n.bind(n,7724));if(!r().devMode)return t();const o=performance.now(),s=t(),l=performance.now(),c=await s,d=performance.now();return i.set({name:e},l-o),a.set({name:e},d-o),c}},9821:function(e,t,n){"use strict";n.r(t),n.d(t,{logStats:function(){return i}});const i=(e,t)=>{const n=[...t.entries()],i=n.reduce(((e,t)=>e+t[1]),0);console.groupCollapsed(`${e} time:`,Math.round(100*i)/100+"ms",`for ${n.length} items`),n.forEach((([e,t])=>{console.log(`%c${e.name} %c${Math.round(100*t)/100}ms ${Math.round(t/i*1e4)/100}% %c`,"color: #00A0D8","color: #888","color: unset")})),console.groupEnd()}},6984:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{RuntimeLibrary:function(){return RuntimeLibrary},protobufLibrary:function(){return protobufLibrary},JSZipLibrary:function(){return JSZipLibrary},SortableJSLibrary:function(){return SortableJSLibrary}});var _ajax__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(6773);function _defineProperty(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class RuntimeLibrary{constructor(e){this.config=e,_defineProperty(this,"modulePromise",void 0)}async then(resolve,reject){try{const{url:url,getModule:getModule}=this.config;this.modulePromise||(this.modulePromise=(async()=>{console.log(`[Runtime Library] Start download from ${url}`);const code=await(0,_ajax__WEBPACK_IMPORTED_MODULE_0__.monkey)({url:url});return console.log(`[Runtime Library] Downloaded from ${url} , length = ${code.length}`),function runEval(){return eval(code);// eslint-disable-next-line no-extra-bind }.bind(window)(),getModule(window)})());const library=await this.modulePromise;return resolve(library)}catch(e){throw reject(e),e}}}const protobufLibrary=new RuntimeLibrary({url:"https://cdn.jsdelivr.net/npm/protobufjs@6.10.1/dist/light/protobuf.min.js",getModule:e=>e.protobuf}),JSZipLibrary=new RuntimeLibrary({url:"https://cdn.jsdelivr.net/npm/jszip@3.7.1/dist/jszip.min.js",getModule:e=>e.JSZip}),SortableJSLibrary=new RuntimeLibrary({url:"https://cdn.jsdelivr.net/npm/sortablejs@1.14.0/Sortable.min.js",getModule:e=>e.Sortable})},4576:function(e,t,n){"use strict";n.r(t),n.d(t,{componentOptionsToSettings:function(){return o},componentToSettings:function(){return s},isUserComponent:function(){return l},isUserPlugin:function(){return c},getComponentSettings:function(){return u},getGeneralSettings:function(){return p},isComponentEnabled:function(){return h}});var i=n(6087),a=n(7724),r=n(4742);const o=e=>lodash.fromPairs(Object.entries(e).map((([e,t])=>[e,t.defaultValue]))),s=e=>({enabled:e.enabledByDefault??!0,options:e.options?o(e.options):{}}),l=e=>{const t="string"==typeof e?e:e.name;return Boolean(a.settings.userComponents[t])},c=e=>{const t="string"==typeof e?e:e.name;return Boolean(a.settings.userPlugins[t])},d={enabled:!1,options:new Proxy({},{get:()=>!1})},u=e=>{if("string"==typeof e){const t=i.componentsMap[e];if(void 0===t)return a.settings.components.settingsPanel.options.devMode&&console.warn("No settings found for component:",e),d;e=t}if(l(e)){const{name:t}=e;return a.settings.userComponents[t]?.settings??d}return a.settings.components[e.name]},p=()=>u("settingsPanel").options,h=e=>("string"==typeof e&&(e=i.componentsMap[e]),(!e.urlExclude||!e.urlExclude.some(r.matchUrlPattern))&&((!e.urlInclude||!e.urlInclude.every(lodash.negate(r.matchUrlPattern)))&&(!1===e.configurable?e.enabledByDefault??!0:u(e).enabled)))},7724:function(e,t,n){"use strict";n.r(t),n.d(t,{isProxy:function(){return c},createProxy:function(){return d},defaultSettings:function(){return u},addSettingsChangeListener:function(){return p},removeSettingsChangeListener:function(){return h},addComponentListener:function(){return m},removeComponentListener:function(){return g},settings:function(){return v},componentOptionsToSettings:function(){return r.componentOptionsToSettings},componentToSettings:function(){return r.componentToSettings},getComponentSettings:function(){return r.getComponentSettings},getGeneralSettings:function(){return r.getGeneralSettings},isComponentEnabled:function(){return r.isComponentEnabled},isUserComponent:function(){return r.isUserComponent},isUserPlugin:function(){return r.isUserPlugin}});var i=n(6087),a=n(3865),r=n(4576);let o={userStyles:{},userPlugins:{},userComponents:{},components:{},plugins:{}},s=!1;const l=new Map,c=Symbol("isProxy"),d=(e,t)=>{const n=(e,i,a=[])=>{for(const[t,r]of Object.entries(e))"object"!=typeof r||r instanceof RegExp||(e[t]=n(r,i||t,[...a,t]));return new Proxy(e,{get:(e,t)=>t===c||e[t],set(e,r,o){"object"!=typeof o||o instanceof RegExp||!0===o[c]||(o=n(o,i||r,[...a,r]));const s=e[r];return e[r]=o,t(o,s,i||r,[...a,r]),!0},deleteProperty(e,n){const r=e[n];return delete e[n],t(void 0,r,i||n,[...a,n]),!0}})};return n(e)};a.plugins.forEach((e=>{o.plugins[e.name]=!0})),i.components.forEach((e=>{o.components[e.name]=(0,r.componentToSettings)(e)}));const u=lodash.cloneDeep(o);o=d((e=>{for(const[t,n]of Object.entries(e)){let i;const a=GM_getValue(t,n);i="object"==typeof a?lodash.defaultsDeep(a,n):a,e[t]=i}return e})(o),((e,t,n,i=[])=>{if(s){GM_setValue(n.toString(),o[n.toString()]);const a=i.join(".");if(i.length>1){const e=i.slice(0,i.length-1).join("."),t=lodash.get(o,e);if(Array.isArray(t)||lodash.isPlainObject(t)){l.get(e)?.forEach((e=>e(t,null,n,i)))}}l.get(a)?.forEach((a=>a(e,t,n,i)))}}));for(const[e,t]of Object.entries(o))GM_setValue(e,t);const p=(e,t,n=!1)=>{const i=l.get(e);if(i?i.push(t):l.set(e,[t]),n){const n=lodash.get(o,e);t(n,n,"",[])}},h=(e,t)=>{const n=l.get(e);if(!n)return;const i=n.indexOf(t);-1!==i&&n.splice(i,1)},f=e=>{const[t,n]=e.split(".");return(0,r.isUserComponent)(t)?void 0===n?`userComponents.${t}.settings.enabled`:`userComponents.${t}.settings.options.${n}`:void 0===n?`components.${t}.enabled`:`components.${t}.options.${n}`},m=(e,t,n=!1)=>{p(f(e),t,n)},g=(e,t)=>{h(f(e),t)};s=!0;const v=o},4402:function(e,t,n){"use strict";n.r(t),n.d(t,{sq:function(){return o},select:function(){return c},selectLazy:function(){return d},selectAll:function(){return h},selectAllLazy:function(){return f},count:function(){return m},hasVideo:function(){return v}});var i=n(9017),a=n(4742);const r={maxRetry:15,queryInterval:1e3},o=(e,t=(e=>Boolean(e)),n=r)=>{const i={...r,...n};return new Promise((n=>{let r=null,o=0;const s=()=>{n(r)},l=()=>{o>i.maxRetry?n(null):(r=e(),!0===t(r,s)?n(r):setTimeout((()=>{"undefined"!=typeof document?(0,a.waitForForeground)((()=>{o++,l()})):l()}),i.queryInterval))};l()}))},s=new Map,l=(e,t)=>{let n;if("string"==typeof e){if(s.has(e))return s.get(e);n=()=>document.querySelector((0,a.bwpVideoFilter)(e))}else n=e;const i=t(n);if("string"==typeof e){const t=i.then((t=>(s.delete(e),t)));return s.set(e,t),t}return i},c=(e,t)=>l(e,(e=>o(e,(e=>null!=e),t))),d=e=>l(e,(e=>new Promise((t=>{(0,i.allMutations)((()=>{const n=e();null!=n&&t(n)}))})))),u=new Map,p=(e,t)=>{let n;if("string"==typeof e){if(u.has(e))return u.get(e);n=()=>Array.from(document.querySelectorAll((0,a.bwpVideoFilter)(e)))}else n=e;const i=e=>null===e?[]:e,r=t(n);if("string"==typeof e){const t=r.then((t=>(u.delete(e),i(t))));return u.set(e,t),t}return r.then((e=>i(e)))},h=(e,t)=>p(e,(e=>o(e,(e=>e.length>0),t))),f=e=>p(e,(e=>new Promise((t=>{(0,i.allMutations)((()=>{const n=e();null!=n&&t(n)}))})))),m=(e,t,n)=>o(e,(e=>e.length===t),n);let g;const v=async()=>{g||(g=new Promise((e=>(0,i.videoChange)((()=>e(unsafeWindow.cid))))));const e=await g;return Boolean(e)}},9261:function(e,t,n){"use strict";n.r(t),n.d(t,{getDefaultStyleID:function(){return a},addStyle:function(){return r},addImportantStyle:function(){return o},removeStyle:function(){return s},loadInstantStyle:function(){return l},preloadStyles:function(){return c},loadAllCustomStyles:function(){return d}});var i=n(5527);const a=e=>e.replace(/([a-z][A-Z])/g,(e=>`${e[0]}-${e[1].toLowerCase()}`)),r=(e,t,n)=>{const i=t?a(t):null,r=dq(`#${i}`);if(!r||!t){const t=document.createElement("style");return t.id=i,t.textContent=e,(n||document.head).insertAdjacentElement("beforeend",t),t}return r},o=(e,t)=>r(e,t,document.body),s=(...e)=>{e.forEach((e=>{const t=a(e);dqa(`#${t}`).forEach((e=>e.remove()))}))},l=async(e,t={head:document.head,body:document.body})=>{e.instantStyles?.forEach((async e=>{const n=document.createElement("style");if(n.id=a(e.name),"string"==typeof e.style)n.textContent=e.style;else{const{default:t}=await e.style();n.textContent=t}e.important?t.body.appendChild(n):t.head.appendChild(n)}))},c=lodash.once((async()=>{const{LoadingMode:e}=await Promise.resolve().then(n.bind(n,4327)),{addHook:t}=await Promise.resolve().then(n.bind(n,9263)),{getGeneralSettings:r,settings:o,isComponentEnabled:c,isUserComponent:d,addComponentListener:u,removeComponentListener:p}=await Promise.resolve().then(n.bind(n,7724)),h=async()=>{const{components:e}=await Promise.resolve().then(n.bind(n,6087)),r=document.createDocumentFragment(),h=document.createDocumentFragment();await Promise.all(e.map((e=>{const n=t=>t?l(e):e.instantStyles?.forEach((e=>s(e.name)));if(u(e.name,n),d(e)&&t("userComponents.remove",{after:t=>{t.name===e.name&&p(e.name,n)}}),c(e))return l(e,{head:r,body:h})})));const{UserStyleMode:f}=await Promise.resolve().then(n.bind(n,1773));Object.values(o.userStyles).filter((e=>e.mode===f.instant)).forEach((e=>{const t=document.createElement("style");t.id=a(e.name),t.textContent=e.style,r.appendChild(t)})),document.head.appendChild(r),(0,i.contentLoaded)((()=>document.body.appendChild(h)))};r().styleLoadingMode===e.Delay?await(0,i.contentLoaded)(h):await h(),(0,i.contentLoaded)((async()=>{const{initColors:e}=await Promise.resolve().then(n.bind(n,8232)),{initMdiStyle:t}=await Promise.resolve().then(n.bind(n,3673));document.head.appendChild(e()),document.head.appendChild(t())}))})),d=async()=>{const{settings:e}=await Promise.resolve().then(n.bind(n,7724)),{UserStyleMode:t}=await Promise.resolve().then(n.bind(n,1773));(0,i.contentLoaded)((()=>{Object.values(e.userStyles).filter((e=>e.mode===t.important)).forEach((e=>{r(e.style,e.name,document.body)}))})),Object.values(e.userStyles).filter((e=>e.mode===t.default)).forEach((e=>{r(e.style,e.name,document.head)}))}},4659:function(e,t,n){"use strict";let i;n.r(t),n.d(t,{TextColor:function(){return i}}),function(e){e.Auto="自动",e.White="白色",e.Black="黑色"}(i||(i={}))},8232:function(e,t,n){"use strict";n.r(t),n.d(t,{initColors:function(){return l}});var i=n(6767),a=n.n(i),r=n(7724);const o=(e,t)=>{const n=t.hue()-e.hue(),i=100*((t.saturationv()-e.saturationv())/100+1),a=e=>Math.round(10*e)/10;return`hue-rotate(${a(n)}deg) saturate(${a(i)}%)`};var s=n(4659);const l=()=>{const e=document.createElement("style"),t=new Map,n=(e,n)=>{t.set(e,n)},i=lodash.debounce((()=>{e.textContent=`\n html {\n ${[...t.entries()].map((([e,t])=>`${e}: ${t};`)).join("\n")}\n }\n `.trim()}),100);return(0,r.addComponentListener)("settingsPanel.themeColor",(e=>{n("--theme-color",e);for(let t=10;t<=90;t+=10){const i=a()(e,"hex");n(`--theme-color-${t}`,i.alpha(t/100).rgb().string()),n(`--theme-color-lightness-${t}`,i.lightness(t).rgb().toString())}n("--pink-image-filter",o(a()({r:251,g:113,b:152},"rgb"),a()(e,"hex"))),n("--blue-image-filter",o(a()({r:0,g:160,b:213},"rgb"),a()(e,"hex"))),i()}),!0),(0,r.addComponentListener)("settingsPanel.accentColor",(e=>{n("--accent-color",e),i()}),!0),(0,r.addComponentListener)("settingsPanel.textColor",(e=>{let t;t=e===s.TextColor.Auto?a()(r.settings.themeColor).isLight()?"black":"white":e===s.TextColor.Black?"black":"white",n("--text-color",t),n("--foreground-color",t),n("--foreground-color-d",a()(t,"keyword").alpha(.875).rgb().string()),n("--foreground-color-b",a()(t,"keyword").alpha(.75).rgb().string()),n("--brightness",("black"===t?"100":"0")+"%"),n("--invert-filter","black"===t?"invert(0)":"invert(1)"),i()}),!0),e}},3446:function(e,t,n){"use strict";n.r(t),n.d(t,{Toast:function(){return v},ToastType:function(){return m}});var i=n(4742),a=n(3449),r=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("transition-group",{staticClass:"toast-card-container",attrs:{name:"toast-card-container",tag:"div"}},e._l(e.cards,(function(e){return n("ToastCard",{key:e.key,attrs:{"data-key":e.key,card:e}})})),1)};r._withStripped=!0;var o=Vue.extend({components:{ToastCard:()=>Promise.resolve().then(n.bind(n,5971)).then((e=>e.default))},data:()=>({cards:[]})}),s=n(3379),l=n.n(s),c=n(9164),d=n.n(c),u={insert:"head",singleton:!1},p=(l()(d(),u),d().locals,(0,n(1900).Z)(o,r,[],!1,null,null,null));p.options.__file="src/core/toast/ToastCardContainer.vue";var h=p.exports;function f(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}let m,g;!function(e){e.Default="default",e.Info="info",e.Success="success",e.Error="error"}(m||(m={}));class v{constructor(e="",t="",n=m.Default){this.message=e,this.title=t,this.type=n,f(this,"durationNumber",3e3),f(this,"durationTimeout",0),f(this,"creationTime",Number(new Date)),f(this,"randomKey",Math.floor(Math.random()*(Number.MAX_SAFE_INTEGER+1)))}static get containerVM(){return g||v.createToastContainer(),g}static createToastContainer(){dq(".toast-card-container")||(g=(0,i.mountVueComponent)(h),document.body.insertAdjacentElement("beforeend",g.$el))}get element(){return dq(`.toast-card[data-key='${this.key}']`)}get key(){return`${this.creationTime}[${this.randomKey}]`}get duration(){return this.durationNumber}set duration(e){this.durationNumber=e,this.durationTimeout&&this.clearDuration(),this.setDuration()}show(){v.containerVM.cards.unshift(this),this.setDuration()}dismiss(){v.containerVM.cards.includes(this)&&v.containerVM.cards.splice(v.containerVM.cards.indexOf(this),1),this.clearDuration()}setDuration(){void 0!==this.durationNumber&&(this.durationTimeout=window.setTimeout((()=>this.dismiss()),this.durationNumber))}clearDuration(){window.clearTimeout(this.durationTimeout),this.durationTimeout=0}static internalShow(e,t,n,i){const a=new v(e,t,i);return a.duration=n,a.show(),a}static show(e,t,n){return this.internalShow(e,t,n,m.Default)}static info(e,t,n){return this.internalShow(e,t,n,m.Info)}static success(e,t,n){return this.internalShow(e,t,n,m.Success)}static error(e,t,n){return this.internalShow(e,t,n,m.Error)}static mini(...e){return(0,a.$)(...e)}}},3449:function(e,t,n){"use strict";function i(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function a(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function r(e){var t=a(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function o(e){return e instanceof a(e).Element||e instanceof Element}function s(e){return e instanceof a(e).HTMLElement||e instanceof HTMLElement}function l(e){return"undefined"!=typeof ShadowRoot&&(e instanceof a(e).ShadowRoot||e instanceof ShadowRoot)}function c(e){return e?(e.nodeName||"").toLowerCase():null}function d(e){return((o(e)?e.ownerDocument:e.document)||window.document).documentElement}function u(e){return i(d(e)).left+r(e).scrollLeft}function p(e){return a(e).getComputedStyle(e)}function h(e){var t=p(e),n=t.overflow,i=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+a+i)}function f(e,t,n){void 0===n&&(n=!1);var o,l,p=d(t),f=i(e),m=s(t),g={scrollLeft:0,scrollTop:0},v={x:0,y:0};return(m||!m&&!n)&&(("body"!==c(t)||h(p))&&(g=(o=t)!==a(o)&&s(o)?{scrollLeft:(l=o).scrollLeft,scrollTop:l.scrollTop}:r(o)),s(t)?((v=i(t)).x+=t.clientLeft,v.y+=t.clientTop):p&&(v.x=u(p))),{x:f.left+g.scrollLeft-v.x,y:f.top+g.scrollTop-v.y,width:f.width,height:f.height}}function m(e){var t=i(e),n=e.offsetWidth,a=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-a)<=1&&(a=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:a}}function g(e){return"html"===c(e)?e:e.assignedSlot||e.parentNode||(l(e)?e.host:null)||d(e)}function v(e){return["html","body","#document"].indexOf(c(e))>=0?e.ownerDocument.body:s(e)&&h(e)?e:v(g(e))}function b(e,t){var n;void 0===t&&(t=[]);var i=v(e),r=i===(null==(n=e.ownerDocument)?void 0:n.body),o=a(i),s=r?[o].concat(o.visualViewport||[],h(i)?i:[]):i,l=t.concat(s);return r?l:l.concat(b(g(s)))}function y(e){return["table","td","th"].indexOf(c(e))>=0}function w(e){return s(e)&&"fixed"!==p(e).position?e.offsetParent:null}function x(e){for(var t=a(e),n=w(e);n&&y(n)&&"static"===p(n).position;)n=w(n);return n&&("html"===c(n)||"body"===c(n)&&"static"===p(n).position)?t:n||function(e){var t=-1!==navigator.userAgent.toLowerCase().indexOf("firefox");if(-1!==navigator.userAgent.indexOf("Trident")&&s(e)&&"fixed"===p(e).position)return null;for(var n=g(e);s(n)&&["html","body"].indexOf(c(n))<0;){var i=p(n);if("none"!==i.transform||"none"!==i.perspective||"paint"===i.contain||-1!==["transform","perspective"].indexOf(i.willChange)||t&&"filter"===i.willChange||t&&i.filter&&"none"!==i.filter)return n;n=n.parentNode}return null}(e)||t}n.d(t,{$:function(){return st}});var _="top",k="bottom",C="right",S="left",E="auto",M=[_,k,C,S],z="start",A="end",$="viewport",O="popper",I=M.reduce((function(e,t){return e.concat([t+"-"+z,t+"-"+A])}),[]),L=[].concat(M,[E]).reduce((function(e,t){return e.concat([t,t+"-"+z,t+"-"+A])}),[]),T=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function P(e){var t=new Map,n=new Set,i=[];function a(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var i=t.get(e);i&&a(i)}})),i.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||a(e)})),i}var D={placement:"bottom",modifiers:[],strategy:"absolute"};function V(){for(var e=arguments.length,t=new Array(e),n=0;n=0?"x":"y"}function R(e){var t,n=e.reference,i=e.element,a=e.placement,r=a?j(a):null,o=a?q(a):null,s=n.x+n.width/2-i.width/2,l=n.y+n.height/2-i.height/2;switch(r){case _:t={x:s,y:n.y-i.height};break;case k:t={x:s,y:n.y+n.height};break;case C:t={x:n.x+n.width,y:l};break;case S:t={x:n.x-i.width,y:l};break;default:t={x:n.x,y:n.y}}var c=r?H(r):null;if(null!=c){var d="y"===c?"height":"width";switch(o){case z:t[c]=t[c]-(n[d]/2-i[d]/2);break;case A:t[c]=t[c]+(n[d]/2-i[d]/2)}}return t}// eslint-disable-next-line import/no-unused-modules @@ -81,7 +81,7 @@ e=[[null,e,""]]);var a={};if(i)for(var r=0;r{let n=u(e);t+=n.weight,this._keys.push(n),this._keyMap[n.id]=n,t+=n.weight})),this._keys.forEach((e=>{e.weight/=t}))}get(e){return this._keyMap[e]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function u(e){let t=null,a=null,r=null,o=1;if(i(e)||n(e))r=e,t=p(e),a=h(e);else{if(!c.call(e,"name"))throw new Error("Missing name property in key");const n=e.name;if(r=n,c.call(e,"weight")&&(o=e.weight,o<=0))throw new Error((e=>`Property 'weight' in key '${e}' must be a positive integer`)(n));t=p(n),a=h(n)}return{path:t,id:a,weight:o,src:r}}function p(e){return n(e)?e:e.split(".")}function h(e){return n(e)?e.join("."):e}var f={isCaseSensitive:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx{if(o(e))if(t[d]){const u=e[t[d]];if(!o(u))return;if(d===t.length-1&&(i(u)||a(u)||r(u)))s.push(function(e){return null==e?"":function(e){if("string"==typeof e)return e;let t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(e)}(u));else if(n(u)){l=!0;for(let e=0,n=u.length;e{this._keysMap[e.id]=t}))}create(){!this.isCreated&&this.docs.length&&(this.isCreated=!0,i(this.docs[0])?this.docs.forEach(((e,t)=>{this._addString(e,t)})):this.docs.forEach(((e,t)=>{this._addObject(e,t)})),this.norm.clear())}add(e){const t=this.size();i(e)?this._addString(e,t):this._addObject(e,t)}removeAt(e){this.records.splice(e,1);for(let t=e,n=this.size();t{let l=this.getFn(e,t.path);if(o(l))if(n(l)){let e=[];const t=[{nestedArrIndex:-1,value:l}];for(;t.length;){const{nestedArrIndex:a,value:r}=t.pop();if(o(r))if(i(r)&&!s(r)){let t={v:r,i:a,n:this.norm.get(r)};e.push(t)}else n(r)&&r.forEach(((e,n)=>{t.push({nestedArrIndex:n,value:e})}))}a.$[r]=e}else if(!s(l)){let e={v:l,n:this.norm.get(l)};a.$[r]=e}})),this.records.push(a)}toJSON(){return{keys:this.keys,records:this.records}}}function v(e,t,{getFn:n=f.getFn}={}){const i=new g({getFn:n});return i.setKeys(e.map(u)),i.setSources(t),i.create(),i}function b(e,{errors:t=0,currentLocation:n=0,expectedLocation:i=0,distance:a=f.distance,ignoreLocation:r=f.ignoreLocation}={}){const o=t/e.length;if(r)return o;const s=Math.abs(i-n);return a?o+s/a:s?1:o}function y(e,t,n,{location:i=f.location,distance:a=f.distance,threshold:r=f.threshold,findAllMatches:o=f.findAllMatches,minMatchCharLength:s=f.minMatchCharLength,includeMatches:l=f.includeMatches,ignoreLocation:c=f.ignoreLocation}={}){if(t.length>32)throw new Error("Pattern length exceeds max of 32.");const d=t.length,u=e.length,p=Math.max(0,Math.min(i,u));let h=r,m=p;const g=s>1||l,v=g?Array(u):[];let y;for(;(y=e.indexOf(t,m))>-1;){let e=b(t,{currentLocation:y,expectedLocation:p,distance:a,ignoreLocation:c});if(h=Math.min(e,h),m=y+d,g){let e=0;for(;e=l;r-=1){let o=r-1,s=n[e.charAt(o)];if(g&&(v[o]=+!!s),y[r]=(y[r+1]<<1|1)&s,i&&(y[r]|=(w[r+1]|w[r])<<1|1|w[r+1]),y[r]&k&&(x=b(t,{errors:i,currentLocation:o,expectedLocation:p,distance:a,ignoreLocation:c}),x<=h)){if(h=x,m=o,m<=p)break;l=Math.max(1,2*p-m)}}if(b(t,{errors:i+1,currentLocation:p,expectedLocation:p,distance:a,ignoreLocation:c})>h)break;w=y}const C={isMatch:m>=0,score:Math.max(.001,x)};if(g){const e=function(e=[],t=f.minMatchCharLength){let n=[],i=-1,a=-1,r=0;for(let o=e.length;r=t&&n.push([i,a]),i=-1)}return e[r-1]&&r-i>=t&&n.push([i,r-1]),n}(v,s);e.length?l&&(C.indices=e):C.isMatch=!1}return C}function w(e){let t={};for(let n=0,i=e.length;n{this.chunks.push({pattern:e,alphabet:w(e),startIndex:t})},d=this.pattern.length;if(d>32){let e=0;const t=d%32,n=d-t;for(;e{const{isMatch:f,score:m,indices:g}=y(e,t,p,{location:i+h,distance:a,threshold:r,findAllMatches:o,minMatchCharLength:s,includeMatches:n,ignoreLocation:l});f&&(u=!0),d+=m,f&&g&&(c=[...c,...g])}));let p={isMatch:u,score:u?d/this.chunks.length:1};return u&&n&&(p.indices=c),p}}const _=[];function k(e,t){for(let n=0,i=_.length;n{if(!o(e.indices)||!e.indices.length)return;const{indices:n,value:i}=e;let a={indices:n,value:i};e.key&&(a.key=e.key.src),e.idx>-1&&(a.refIndex=e.idx),t.matches.push(a)}))}function S(e,t){t.score=e.score}class E{constructor(e,t={},n){if(this.options={...f,...t},this.options.useExtendedSearch)throw new Error("Extended search is not available");this._keyStore=new d(this.options.keys),this.setCollection(e,n)}setCollection(e,t){if(this._docs=e,t&&!(t instanceof g))throw new Error("Incorrect 'index' type");this._myIndex=t||v(this.options.keys,this._docs,{getFn:this.options.getFn})}add(e){o(e)&&(this._docs.push(e),this._myIndex.add(e))}remove(e=(()=>!1)){const t=[];for(let n=0,i=this._docs.length;n{let n=1;e.matches.forEach((({key:e,norm:i,score:a})=>{const r=e?e.weight:null;n*=Math.pow(0===a&&r?Number.EPSILON:a,(r||1)*(t?1:i))})),e.score=n}))}(c,{ignoreFieldNorm:l}),o&&c.sort(s),a(t)&&t>-1&&(c=c.slice(0,t)),function(e,t,{includeMatches:n=f.includeMatches,includeScore:i=f.includeScore}={}){const a=[];return n&&a.push(C),i&&a.push(S),e.map((e=>{const{idx:n}=e,i={item:t[n],refIndex:n};return a.length&&a.forEach((t=>{t(e,i)})),i}))}(c,this._docs,{includeMatches:n,includeScore:r})}_searchStringList(e){const t=k(e,this.options),{records:n}=this._myIndex,i=[];return n.forEach((({v:e,i:n,n:a})=>{if(!o(e))return;const{isMatch:r,score:s,indices:l}=t.searchIn(e);r&&i.push({item:e,idx:n,matches:[{score:s,value:e,norm:a,indices:l}]})})),i}_searchLogical(e){throw new Error("Logical search is not available")}_searchObjectList(e){const t=k(e,this.options),{keys:n,records:i}=this._myIndex,a=[];return i.forEach((({$:e,i:i})=>{if(!o(e))return;let r=[];n.forEach(((n,i)=>{r.push(...this._findMatches({key:n,value:e[i],searcher:t}))})),r.length&&a.push({idx:i,item:e,matches:r})})),a}_findMatches({key:e,value:t,searcher:i}){if(!o(t))return[];let a=[];if(n(t))t.forEach((({v:t,i:n,n:r})=>{if(!o(t))return;const{isMatch:s,score:l,indices:c}=i.searchIn(t);s&&a.push({score:l,key:e,value:t,idx:n,norm:r,indices:c})}));else{const{v:n,n:r}=t,{isMatch:o,score:s,indices:l}=i.searchIn(n);o&&a.push({score:s,key:e,value:n,norm:r,indices:l})}return a}}E.version="6.4.6",E.createIndex=v,E.parseIndex=function(e,{getFn:t=f.getFn}={}){const{keys:n,records:i}=e,a=new g({getFn:t});return a.setKeys(n),a.setIndexRecords(i),a},E.config=f,t.Z=E},5171:function(e){e.exports=function(e){return!(!e||"string"==typeof e)&&(e instanceof Array||Array.isArray(e)||e.length>=0&&(e.splice instanceof Function||Object.getOwnPropertyDescriptor(e,e.length-1)&&"String"!==e.constructor.name))}},7084:function(e){e.exports=function(){"use strict";function e(e,t){for(var n=0;ne.length)&&(t=e.length);for(var n=0,i=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[a++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(i=e[Symbol.iterator]()).next.bind(i)}function r(e,t){return e(t={exports:{}},t.exports),t.exports}var o=r((function(e){function t(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}function n(t){e.exports.defaults=t}e.exports={defaults:t(),getDefaults:t,changeDefaults:n}})),s=(o.defaults,o.getDefaults,o.changeDefaults,/[&<>"']/),l=/[&<>"']/g,c=/[<>"']|&(?!#?\w+;)/,d=/[<>"']|&(?!#?\w+;)/g,u={"&":"&","<":"<",">":">",'"':""","'":"'"},p=function(e){return u[e]};function h(e,t){if(t){if(s.test(e))return e.replace(l,p)}else if(c.test(e))return e.replace(d,p);return e}var f=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function m(e){return e.replace(f,(function(e,t){return"colon"===(t=t.toLowerCase())?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""}))}var g=/(^|[^\[])\^/g;function v(e,t){e=e.source||e,t=t||"";var n={replace:function(t,i){return i=(i=i.source||i).replace(g,"$1"),e=e.replace(t,i),n},getRegex:function(){return new RegExp(e,t)}};return n}var b=/[^\w:]/g,y=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function w(e,t,n){if(e){var i;try{i=decodeURIComponent(m(n)).replace(b,"").toLowerCase()}catch(e){return null}if(0===i.indexOf("javascript:")||0===i.indexOf("vbscript:")||0===i.indexOf("data:"))return null}t&&!y.test(n)&&(n=S(t,n));try{n=encodeURI(n).replace(/%25/g,"%")}catch(e){return null}return n}var x={},_=/^[^:]+:\/*[^/]*$/,k=/^([^:]+:)[\s\S]*$/,C=/^([^:]+:\/*[^/]*)[\s\S]*$/;function S(e,t){x[" "+e]||(_.test(e)?x[" "+e]=e+"/":x[" "+e]=z(e,"/",!0));var n=-1===(e=x[" "+e]).indexOf(":");return"//"===t.substring(0,2)?n?t:e.replace(k,"$1")+t:"/"===t.charAt(0)?n?t:e.replace(C,"$1")+t:e+t}function E(e){for(var t,n,i=1;i=0&&"\\"===n[a];)i=!i;return i?"|":" |"})).split(/ \|/),i=0;if(n.length>t)n.splice(t);else for(;n.length1;)1&t&&(n+=e),t>>=1,e+=e;return n+e}var I={escape:h,unescape:m,edit:v,cleanUrl:w,resolveUrl:S,noopTest:{exec:function(){}},merge:E,splitCells:M,rtrim:z,findClosingBracket:A,checkSanitizeDeprecation:$,repeatString:O},L=o.defaults,T=I.rtrim,P=I.splitCells,D=I.escape,V=I.findClosingBracket;function B(e,t,n){var i=t.href,a=t.title?D(t.title):null,r=e[1].replace(/\\([\[\]])/g,"$1");return"!"!==e[0].charAt(0)?{type:"link",raw:n,href:i,title:a,text:r}:{type:"image",raw:n,href:i,title:a,text:D(r)}}function F(e,t){var n=e.match(/^(\s+)(?:```)/);if(null===n)return t;var i=n[1];return t.split("\n").map((function(e){var t=e.match(/^\s+/);return null===t?e:t[0].length>=i.length?e.slice(i.length):e})).join("\n")}var N=function(){function e(e){this.options=e||L}var t=e.prototype;return t.space=function(e){var t=this.rules.block.newline.exec(e);if(t)return t[0].length>1?{type:"space",raw:t[0]}:{raw:"\n"}},t.code=function(e,t){var n=this.rules.block.code.exec(e);if(n){var i=t[t.length-1];if(i&&"paragraph"===i.type)return{raw:n[0],text:n[0].trimRight()};var a=n[0].replace(/^ {4}/gm,"");return{type:"code",raw:n[0],codeBlockStyle:"indented",text:this.options.pedantic?a:T(a,"\n")}}},t.fences=function(e){var t=this.rules.block.fences.exec(e);if(t){var n=t[0],i=F(n,t[3]||"");return{type:"code",raw:n,lang:t[2]?t[2].trim():t[2],text:i}}},t.heading=function(e){var t=this.rules.block.heading.exec(e);if(t)return{type:"heading",raw:t[0],depth:t[1].length,text:t[2]}},t.nptable=function(e){var t=this.rules.block.nptable.exec(e);if(t){var n={type:"table",header:P(t[1].replace(/^ *| *\| *$/g,"")),align:t[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:t[3]?t[3].replace(/\n$/,"").split("\n"):[],raw:t[0]};if(n.header.length===n.align.length){var i,a=n.align.length;for(i=0;i ?/gm,"");return{type:"blockquote",raw:t[0],text:n}}},t.list=function(e){var t=this.rules.block.list.exec(e);if(t){var n,i,a,r,o,s,l,c,d=t[0],u=t[2],p=u.length>1,h={type:"list",raw:d,ordered:p,start:p?+u.slice(0,-1):"",loose:!1,items:[]},f=t[0].match(this.rules.block.item),m=!1,g=f.length;a=this.rules.block.listItemStart.exec(f[0]);for(var v=0;va[0].length||r[1].length>3){f.splice(v,2,f[v]+"\n"+f[v+1]),v--,g--;continue}(!this.options.pedantic||this.options.smartLists?r[2][r[2].length-1]!==u[u.length-1]:p===(1===r[2].length))&&(o=f.slice(v+1).join("\n"),h.raw=h.raw.substring(0,h.raw.length-o.length),v=g-1),a=r}i=n.length,~(n=n.replace(/^ *([*+-]|\d+[.)]) ?/,"")).indexOf("\n ")&&(i-=n.length,n=this.options.pedantic?n.replace(/^ {1,4}/gm,""):n.replace(new RegExp("^ {1,"+i+"}","gm"),"")),s=m||/\n\n(?!\s*$)/.test(n),v!==g-1&&(m="\n"===n.charAt(n.length-1),s||(s=m)),s&&(h.loose=!0),this.options.gfm&&(c=void 0,(l=/^\[[ xX]\] /.test(n))&&(c=" "!==n[1],n=n.replace(/^\[[ xX]\] +/,""))),h.items.push({type:"list_item",raw:d,task:l,checked:c,loose:s,text:n})}return h}},t.html=function(e){var t=this.rules.block.html.exec(e);if(t)return{type:this.options.sanitize?"paragraph":"html",raw:t[0],pre:!this.options.sanitizer&&("pre"===t[1]||"script"===t[1]||"style"===t[1]),text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(t[0]):D(t[0]):t[0]}},t.def=function(e){var t=this.rules.block.def.exec(e);if(t)return t[3]&&(t[3]=t[3].substring(1,t[3].length-1)),{tag:t[1].toLowerCase().replace(/\s+/g," "),raw:t[0],href:t[2],title:t[3]}},t.table=function(e){var t=this.rules.block.table.exec(e);if(t){var n={type:"table",header:P(t[1].replace(/^ *| *\| *$/g,"")),align:t[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:t[3]?t[3].replace(/\n$/,"").split("\n"):[]};if(n.header.length===n.align.length){n.raw=t[0];var i,a=n.align.length;for(i=0;i/i.test(i[0])&&(t=!1),!n&&/^<(pre|code|kbd|script)(\s|>)/i.test(i[0])?n=!0:n&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(i[0])&&(n=!1),{type:this.options.sanitize?"text":"html",raw:i[0],inLink:t,inRawBlock:n,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(i[0]):D(i[0]):i[0]}},t.link=function(e){var t=this.rules.inline.link.exec(e);if(t){var n=V(t[2],"()");if(n>-1){var i=(0===t[0].indexOf("!")?5:4)+t[1].length+n;t[2]=t[2].substring(0,n),t[0]=t[0].substring(0,i).trim(),t[3]=""}var a=t[2],r="";if(this.options.pedantic){var o=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(a);o?(a=o[1],r=o[3]):r=""}else r=t[3]?t[3].slice(1,-1):"";return B(t,{href:(a=a.trim().replace(/^<([\s\S]*)>$/,"$1"))?a.replace(this.rules.inline._escapes,"$1"):a,title:r?r.replace(this.rules.inline._escapes,"$1"):r},t[0])}},t.reflink=function(e,t){var n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){var i=(n[2]||n[1]).replace(/\s+/g," ");if(!(i=t[i.toLowerCase()])||!i.href){var a=n[0].charAt(0);return{type:"text",raw:a,text:a}}return B(n,i,n[0])}},t.strong=function(e,t,n){void 0===n&&(n="");var i=this.rules.inline.strong.start.exec(e);if(i&&(!i[1]||i[1]&&(""===n||this.rules.inline.punctuation.exec(n)))){t=t.slice(-1*e.length);var a,r="**"===i[0]?this.rules.inline.strong.endAst:this.rules.inline.strong.endUnd;for(r.lastIndex=0;null!=(i=r.exec(t));)if(a=this.rules.inline.strong.middle.exec(t.slice(0,i.index+3)))return{type:"strong",raw:e.slice(0,a[0].length),text:e.slice(2,a[0].length-2)}}},t.em=function(e,t,n){void 0===n&&(n="");var i=this.rules.inline.em.start.exec(e);if(i&&(!i[1]||i[1]&&(""===n||this.rules.inline.punctuation.exec(n)))){t=t.slice(-1*e.length);var a,r="*"===i[0]?this.rules.inline.em.endAst:this.rules.inline.em.endUnd;for(r.lastIndex=0;null!=(i=r.exec(t));)if(a=this.rules.inline.em.middle.exec(t.slice(0,i.index+2)))return{type:"em",raw:e.slice(0,a[0].length),text:e.slice(1,a[0].length-1)}}},t.codespan=function(e){var t=this.rules.inline.code.exec(e);if(t){var n=t[2].replace(/\n/g," "),i=/[^ ]/.test(n),a=n.startsWith(" ")&&n.endsWith(" ");return i&&a&&(n=n.substring(1,n.length-1)),n=D(n,!0),{type:"codespan",raw:t[0],text:n}}},t.br=function(e){var t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}},t.del=function(e){var t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2]}},t.autolink=function(e,t){var n,i,a=this.rules.inline.autolink.exec(e);if(a)return i="@"===a[2]?"mailto:"+(n=D(this.options.mangle?t(a[1]):a[1])):n=D(a[1]),{type:"link",raw:a[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}},t.url=function(e,t){var n;if(n=this.rules.inline.url.exec(e)){var i,a;if("@"===n[2])a="mailto:"+(i=D(this.options.mangle?t(n[0]):n[0]));else{var r;do{r=n[0],n[0]=this.rules.inline._backpedal.exec(n[0])[0]}while(r!==n[0]);i=D(n[0]),a="www."===n[1]?"http://"+i:i}return{type:"link",raw:n[0],text:i,href:a,tokens:[{type:"text",raw:i,text:i}]}}},t.inlineText=function(e,t,n){var i,a=this.rules.inline.text.exec(e);if(a)return i=t?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(a[0]):D(a[0]):a[0]:D(this.options.smartypants?n(a[0]):a[0]),{type:"text",raw:a[0],text:i}},e}(),j=I.noopTest,q=I.edit,H=I.merge,R={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?:\n+|$)|$)/,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6}) +([^\n]*?)(?: +#+)? *(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3})(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?! {0,3}bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,nptable:j,table:j,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/};R.def=q(R.def).replace("label",R._label).replace("title",R._title).getRegex(),R.bullet=/(?:[*+-]|\d{1,9}[.)])/,R.item=/^( *)(bull) ?[^\n]*(?:\n(?! *bull ?)[^\n]*)*/,R.item=q(R.item,"gm").replace(/bull/g,R.bullet).getRegex(),R.listItemStart=q(/^( *)(bull)/).replace("bull",R.bullet).getRegex(),R.list=q(R.list).replace(/bull/g,R.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+R.def.source+")").getRegex(),R._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",R._comment=/|$)/,R.html=q(R.html,"i").replace("comment",R._comment).replace("tag",R._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),R.paragraph=q(R._paragraph).replace("hr",R.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|!--)").replace("tag",R._tag).getRegex(),R.blockquote=q(R.blockquote).replace("paragraph",R.paragraph).getRegex(),R.normal=H({},R),R.gfm=H({},R.normal,{nptable:"^ *([^|\\n ].*\\|.*)\\n {0,3}([-:]+ *\\|[-| :]*)(?:\\n((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)",table:"^ *\\|(.+)\\n {0,3}\\|?( *[-:]+[-| :]*)(?:\\n *((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),R.gfm.nptable=q(R.gfm.nptable).replace("hr",R.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|!--)").replace("tag",R._tag).getRegex(),R.gfm.table=q(R.gfm.table).replace("hr",R.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|!--)").replace("tag",R._tag).getRegex(),R.pedantic=H({},R.normal,{html:q("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",R._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,fences:j,paragraph:q(R.normal._paragraph).replace("hr",R.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",R.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var U={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:j,tag:"^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/,nolink:/^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",strong:{start:/^(?:(\*\*(?=[*punctuation]))|\*\*)(?![\s])|__/,middle:/^\*\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*\*$|^__(?![\s])((?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?)__$/,endAst:/[^punctuation\s]\*\*(?!\*)|[punctuation]\*\*(?!\*)(?:(?=[punctuation_\s]|$))/,endUnd:/[^\s]__(?!_)(?:(?=[punctuation*\s])|$)/},em:{start:/^(?:(\*(?=[punctuation]))|\*)(?![*\s])|_/,middle:/^\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*$|^_(?![_\s])(?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?_$/,endAst:/[^punctuation\s]\*(?!\*)|[punctuation]\*(?!\*)(?:(?=[punctuation_\s]|$))/,endUnd:/[^\s]_(?!_)(?:(?=[punctuation*\s])|$)/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:j,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\?@\\[\\]`^{|}~"};U.punctuation=q(U.punctuation).replace(/punctuation/g,U._punctuation).getRegex(),U._blockSkip="\\[[^\\]]*?\\]\\([^\\)]*?\\)|`[^`]*?`|<[^>]*?>",U._overlapSkip="__[^_]*?__|\\*\\*\\[^\\*\\]*?\\*\\*",U._comment=q(R._comment).replace("(?:--\x3e|$)","--\x3e").getRegex(),U.em.start=q(U.em.start).replace(/punctuation/g,U._punctuation).getRegex(),U.em.middle=q(U.em.middle).replace(/punctuation/g,U._punctuation).replace(/overlapSkip/g,U._overlapSkip).getRegex(),U.em.endAst=q(U.em.endAst,"g").replace(/punctuation/g,U._punctuation).getRegex(),U.em.endUnd=q(U.em.endUnd,"g").replace(/punctuation/g,U._punctuation).getRegex(),U.strong.start=q(U.strong.start).replace(/punctuation/g,U._punctuation).getRegex(),U.strong.middle=q(U.strong.middle).replace(/punctuation/g,U._punctuation).replace(/overlapSkip/g,U._overlapSkip).getRegex(),U.strong.endAst=q(U.strong.endAst,"g").replace(/punctuation/g,U._punctuation).getRegex(),U.strong.endUnd=q(U.strong.endUnd,"g").replace(/punctuation/g,U._punctuation).getRegex(),U.blockSkip=q(U._blockSkip,"g").getRegex(),U.overlapSkip=q(U._overlapSkip,"g").getRegex(),U._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,U._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,U._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,U.autolink=q(U.autolink).replace("scheme",U._scheme).replace("email",U._email).getRegex(),U._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,U.tag=q(U.tag).replace("comment",U._comment).replace("attribute",U._attribute).getRegex(),U._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,U._href=/<(?:\\[<>]?|[^\s<>\\])*>|[^\s\x00-\x1f]*/,U._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,U.link=q(U.link).replace("label",U._label).replace("href",U._href).replace("title",U._title).getRegex(),U.reflink=q(U.reflink).replace("label",U._label).getRegex(),U.reflinkSearch=q(U.reflinkSearch,"g").replace("reflink",U.reflink).replace("nolink",U.nolink).getRegex(),U.normal=H({},U),U.pedantic=H({},U.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:q(/^!?\[(label)\]\((.*?)\)/).replace("label",U._label).getRegex(),reflink:q(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",U._label).getRegex()}),U.gfm=H({},U.normal,{escape:q(U.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\.5&&(n="x"+n.toString(16)),i+="&#"+n+";";return i}var Q=function(){function e(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||W,this.options.tokenizer=this.options.tokenizer||new N,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options;var t={block:G.normal,inline:X.normal};this.options.pedantic?(t.block=G.pedantic,t.inline=X.pedantic):this.options.gfm&&(t.block=G.gfm,this.options.breaks?t.inline=X.breaks:t.inline=X.gfm),this.tokenizer.rules=t}e.lex=function(t,n){return new e(n).lex(t)},e.lexInline=function(t,n){return new e(n).inlineTokens(t)};var n=e.prototype;return n.lex=function(e){return e=e.replace(/\r\n|\r/g,"\n").replace(/\t/g," "),this.blockTokens(e,this.tokens,!0),this.inline(this.tokens),this.tokens},n.blockTokens=function(e,t,n){var i,a,r,o;for(void 0===t&&(t=[]),void 0===n&&(n=!0),e=e.replace(/^ +$/gm,"");e;)if(i=this.tokenizer.space(e))e=e.substring(i.raw.length),i.type&&t.push(i);else if(i=this.tokenizer.code(e,t))e=e.substring(i.raw.length),i.type?t.push(i):((o=t[t.length-1]).raw+="\n"+i.raw,o.text+="\n"+i.text);else if(i=this.tokenizer.fences(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.heading(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.nptable(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.hr(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.blockquote(e))e=e.substring(i.raw.length),i.tokens=this.blockTokens(i.text,[],n),t.push(i);else if(i=this.tokenizer.list(e)){for(e=e.substring(i.raw.length),r=i.items.length,a=0;a0)for(;null!=(r=this.tokenizer.rules.inline.reflinkSearch.exec(l));)c.includes(r[0].slice(r[0].lastIndexOf("[")+1,-1))&&(l=l.slice(0,r.index)+"["+K("a",r[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(r=this.tokenizer.rules.inline.blockSkip.exec(l));)l=l.slice(0,r.index)+"["+K("a",r[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;e;)if(o||(s=""),o=!1,a=this.tokenizer.escape(e))e=e.substring(a.raw.length),t.push(a);else if(a=this.tokenizer.tag(e,n,i))e=e.substring(a.raw.length),n=a.inLink,i=a.inRawBlock,t.push(a);else if(a=this.tokenizer.link(e))e=e.substring(a.raw.length),"link"===a.type&&(a.tokens=this.inlineTokens(a.text,[],!0,i)),t.push(a);else if(a=this.tokenizer.reflink(e,this.tokens.links))e=e.substring(a.raw.length),"link"===a.type&&(a.tokens=this.inlineTokens(a.text,[],!0,i)),t.push(a);else if(a=this.tokenizer.strong(e,l,s))e=e.substring(a.raw.length),a.tokens=this.inlineTokens(a.text,[],n,i),t.push(a);else if(a=this.tokenizer.em(e,l,s))e=e.substring(a.raw.length),a.tokens=this.inlineTokens(a.text,[],n,i),t.push(a);else if(a=this.tokenizer.codespan(e))e=e.substring(a.raw.length),t.push(a);else if(a=this.tokenizer.br(e))e=e.substring(a.raw.length),t.push(a);else if(a=this.tokenizer.del(e))e=e.substring(a.raw.length),a.tokens=this.inlineTokens(a.text,[],n,i),t.push(a);else if(a=this.tokenizer.autolink(e,Y))e=e.substring(a.raw.length),t.push(a);else if(n||!(a=this.tokenizer.url(e,Y))){if(a=this.tokenizer.inlineText(e,i,J))e=e.substring(a.raw.length),s=a.raw.slice(-1),o=!0,t.push(a);else if(e){var d="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(d);break}throw new Error(d)}}else e=e.substring(a.raw.length),t.push(a);return t},t(e,null,[{key:"rules",get:function(){return{block:G,inline:X}}}]),e}(),ee=o.defaults,te=I.cleanUrl,ne=I.escape,ie=function(){function e(e){this.options=e||ee}var t=e.prototype;return t.code=function(e,t,n){var i=(t||"").match(/\S*/)[0];if(this.options.highlight){var a=this.options.highlight(e,i);null!=a&&a!==e&&(n=!0,e=a)}return i?'
'+(n?e:ne(e,!0))+"
\n":"
"+(n?e:ne(e,!0))+"
\n"},t.blockquote=function(e){return"
\n"+e+"
\n"},t.html=function(e){return e},t.heading=function(e,t,n,i){return this.options.headerIds?"'+e+"\n":""+e+"\n"},t.hr=function(){return this.options.xhtml?"
\n":"
\n"},t.list=function(e,t,n){var i=t?"ol":"ul";return"<"+i+(t&&1!==n?' start="'+n+'"':"")+">\n"+e+"\n"},t.listitem=function(e){return"
  • "+e+"
  • \n"},t.checkbox=function(e){return" "},t.paragraph=function(e){return"

    "+e+"

    \n"},t.table=function(e,t){return t&&(t=""+t+""),"\n\n"+e+"\n"+t+"
    \n"},t.tablerow=function(e){return"\n"+e+"\n"},t.tablecell=function(e,t){var n=t.header?"th":"td";return(t.align?"<"+n+' align="'+t.align+'">':"<"+n+">")+e+"\n"},t.strong=function(e){return""+e+""},t.em=function(e){return""+e+""},t.codespan=function(e){return""+e+""},t.br=function(){return this.options.xhtml?"
    ":"
    "},t.del=function(e){return""+e+""},t.link=function(e,t,n){if(null===(e=te(this.options.sanitize,this.options.baseUrl,e)))return n;var i='"},t.image=function(e,t,n){if(null===(e=te(this.options.sanitize,this.options.baseUrl,e)))return n;var i=''+n+'":">"},t.text=function(e){return e},e}(),ae=function(){function e(){}var t=e.prototype;return t.strong=function(e){return e},t.em=function(e){return e},t.codespan=function(e){return e},t.del=function(e){return e},t.html=function(e){return e},t.text=function(e){return e},t.link=function(e,t,n){return""+n},t.image=function(e,t,n){return""+n},t.br=function(){return""},e}(),re=function(){function e(){this.seen={}}var t=e.prototype;return t.serialize=function(e){return e.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")},t.getNextSafeSlug=function(e,t){var n=e,i=0;if(this.seen.hasOwnProperty(n)){i=this.seen[e];do{n=e+"-"+ ++i}while(this.seen.hasOwnProperty(n))}return t||(this.seen[e]=i,this.seen[n]=0),n},t.slug=function(e,t){void 0===t&&(t={});var n=this.serialize(e);return this.getNextSafeSlug(n,t.dryrun)},e}(),oe=o.defaults,se=I.unescape,le=function(){function e(e){this.options=e||oe,this.options.renderer=this.options.renderer||new ie,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new ae,this.slugger=new re}e.parse=function(t,n){return new e(n).parse(t)},e.parseInline=function(t,n){return new e(n).parseInline(t)};var t=e.prototype;return t.parse=function(e,t){void 0===t&&(t=!0);var n,i,a,r,o,s,l,c,d,u,p,h,f,m,g,v,b,y,w="",x=e.length;for(n=0;n0&&"text"===g.tokens[0].type?(g.tokens[0].text=y+" "+g.tokens[0].text,g.tokens[0].tokens&&g.tokens[0].tokens.length>0&&"text"===g.tokens[0].tokens[0].type&&(g.tokens[0].tokens[0].text=y+" "+g.tokens[0].tokens[0].text)):g.tokens.unshift({type:"text",text:y}):m+=y),m+=this.parse(g.tokens,f),d+=this.renderer.listitem(m,b,v);w+=this.renderer.list(d,p,h);continue;case"html":w+=this.renderer.html(u.text);continue;case"paragraph":w+=this.renderer.paragraph(this.parseInline(u.tokens));continue;case"text":for(d=u.tokens?this.parseInline(u.tokens):u.text;n+1An error occurred:

    "+ue(e.message+"",!0)+"
    ";throw e}}return me.options=me.setOptions=function(e){return ce(me.defaults,e),he(me.defaults),me},me.getDefaults=pe,me.defaults=fe,me.use=function(e){var t=ce({},e);if(e.renderer&&function(){var n=me.defaults.renderer||new ie,i=function(t){var i=n[t];n[t]=function(){for(var a=arguments.length,r=new Array(a),o=0;oAn error occurred:

    "+ue(e.message+"",!0)+"
    ";throw e}},me.Parser=le,me.parser=le.parse,me.Renderer=ie,me.TextRenderer=ae,me.Lexer=Q,me.lexer=Q.lex,me.Tokenizer=N,me.Slugger=re,me.parse=me,me}()},382:function(e,t,n){"use strict";n.r(t),t.default=''},8885:function(e,t,n){"use strict";n.r(t),t.default=''},5339:function(e,t,n){"use strict";n.r(t),t.default=''},8360:function(e,t,n){"use strict";n.r(t),t.default=''},6851:function(e,t,n){"use strict";var i=n(5171),a=Array.prototype.concat,r=Array.prototype.slice,o=e.exports=function(e){for(var t=[],n=0,o=e.length;nt.map((t=>{const n=`${e.name}.${t.name}`;return{...t,key:n,provider:e}}));const[C]=(0,r.registerAndGetData)("launchBar.recommended",{word:"搜索",href:"https://search.bilibili.com/"});var S=Vue.extend({components:{VIcon:a.VIcon,VLoading:a.VLoading,VEmpty:a.VEmpty,ActionItem:b},data:()=>({recommended:C,actions:[],keyword:"",noActions:!1}),computed:{isHistory(){return 0===this.keyword.length}},watch:{keyword(){this.getActions()}},async mounted(){this.getActions(),(0,s.matchUrlPattern)(/^https?:\/\/search\.bilibili\.com/)&&(0,o.select)("#search-keyword").then((e=>{e&&(this.keyword=e.value,document.addEventListener("change",(e=>{e.target instanceof HTMLInputElement&&"search-keyword"===e.target.id&&(this.keyword=e.target.value)})))}))},methods:{getOnlineActions:lodash.debounce((async function(){const e=(await Promise.all(_.map((async e=>k(e,await e.getActions(this.keyword)))))).flat();if(this.isHistory)return;const t=new l.Z(e,{keys:["indexer","displayName","name","description","key"]}).search(this.keyword);console.log(t),this.actions=t.map((e=>e.item)).slice(0,12),this.noActions=0===this.actions.length}),200),getActions:async function(){if(this.noActions=!1,this.isHistory)return void(this.actions=k(x.dr,await x.dr.getActions(this.keyword)));this.actions=[],this.getOnlineActions()},async handleEnter(){if(this.actions.length>0&&!this.isHistory){const[e]=this.actions;if(!e.explicitSelect)return void e.action()}this.keyword?(0,w.search)(this.keyword):window.open(this.recommended.href,"_blank")},handleUp(e){e.isComposing||(this.$refs.list.querySelector(".suggest-item:last-child").focus(),e.preventDefault())},handleDown(e){e.isComposing||(this.$refs.list.querySelector(".suggest-item").focus(),e.preventDefault())},previousItem(e,t){0===t?this.focus():e.currentTarget.previousElementSibling.focus()},nextItem(e,t){t!==this.actions.length-1?e.currentTarget.nextElementSibling.focus():this.focus()},search:w.search,onDeleteItem(e,t){this.previousItem(e,t),this.getActions()},onClearHistory(){this.focus(),this.getActions()},focus(){this.$refs.input.focus()}}}),E=n(9506),M=n.n(E),z={insert:"head",singleton:!1},A=(p()(M(),z),M().locals,(0,g.Z)(S,i,[],!1,null,null,null));A.options.__file="src/components/launch-bar/LaunchBar.vue";var $=A.exports},1020:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"be-settings"},[n("div",{staticClass:"sidebar"},[n("div",{ref:"widgetsIcon",class:{open:e.widgetsOpened},attrs:{title:"功能"},on:{click:[function(t){return t.shiftKey?e.theWorld(t):null},function(t){if(t.ctrlKey||t.shiftKey||t.altKey||t.metaKey)return null;e.widgetsOpened=!e.widgetsOpened}],mouseover:function(t){return e.loadPanel("widgetsPanelPopup")}}},[n("VIcon",{attrs:{icon:"widgets",size:26}})],1),e._v(" "),n("div",{ref:"settingsIcon",class:{open:e.settingsOpened},attrs:{title:"设置"},on:{click:function(t){e.settingsOpened=!e.settingsOpened},mouseover:function(t){return e.loadPanel("settingsPanelPopup")}}},[n("VIcon",{attrs:{icon:"settings-outline",size:26}})],1)]),e._v(" "),n("VPopup",{ref:"widgetsPanelPopup",staticClass:"widgets-panel-popup",attrs:{"trigger-element":e.$refs.widgetsIcon,fixed:!0},model:{value:e.widgetsOpened,callback:function(t){e.widgetsOpened=t},expression:"widgetsOpened"}},[n("WidgetsPanel")],1),e._v(" "),n("VPopup",{ref:"settingsPanelPopup",staticClass:"settings-panel-popup",attrs:{"trigger-element":e.$refs.settingsIcon,"auto-close-predicate":e.settingsPanalClosePredicate,fixed:!0},model:{value:e.settingsOpened,callback:function(t){e.settingsOpened=t},expression:"settingsOpened"}},[n("SettingsPanel",{on:{close:function(t){e.settingsOpened=!1}}})],1)],1)};i._withStripped=!0;var a=n(9759),r=n(5842),o={name:"SettingsContainer",components:{VPopup:a.VPopup,VIcon:a.VIcon,SettingsPanel:()=>Promise.resolve().then(n.bind(n,202)).then((e=>e.default)),WidgetsPanel:()=>Promise.resolve().then(n.bind(n,5926)).then((e=>e.default))},data:()=>({settingsOpened:!1,widgetsOpened:!1}),methods:{theWorld(){r.externalApis.theWorld(0)},settingsPanalClosePredicate:e=>!dqa(".be-settings-extra-options").some((t=>t===e.target||t.contains(e.target))),loadPanel(e){const t=this.$refs[e];t&&(t?.loaded??0)&&(t.loaded=!0)}}},s=n(3379),l=n.n(s),c=n(857),d=n.n(c),u={insert:"head",singleton:!1},p=(l()(d(),u),d().locals,(0,n(1900).Z)(o,i,[],!1,null,null,null));p.options.__file="src/components/settings-panel/SettingsContainer.vue";var h=p.exports},202:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Pt}});var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"settings-panel",class:{collasped:e.collasped,peek:e.peek}},[n("div",{staticClass:"settings-panel-header"},[n("VIcon",{attrs:{icon:"settings-outline"}}),e._v(" "),n("div",{staticClass:"title"},[e._v("\n 设置\n ")]),e._v(" "),n("div",{staticClass:"settings-panel-search"},[n("VIcon",{attrs:{icon:"search",size:18}}),e._v(" "),n("TextBox",{attrs:{placeholder:"搜索"},model:{value:e.searchKeyword,callback:function(t){e.searchKeyword=t},expression:"searchKeyword"}})],1),e._v(" "),n("div",{staticClass:"peek",attrs:{title:"透视"},on:{mouseover:function(t){e.peek=!0},mouseout:function(t){e.peek=!1}}},[n("VIcon",{attrs:{icon:"eye",size:18}})],1),e._v(" "),n("div",{staticClass:"close",on:{click:function(t){return e.$emit("close")}}},[n("VIcon",{attrs:{icon:"close",size:18}})],1)],1),e._v(" "),n("div",{staticClass:"settings-panel-content"},[n("div",{ref:"sidebarContainer",staticClass:"sidebar"},[n("ComponentTags",{ref:"componentTags",on:{change:function(t){e.searchFilter=t}}})],1),e._v(" "),n("div",{ref:"mainContainer",staticClass:"main"},[n("div",{ref:"componentList",staticClass:"component-list"},[e._l(e.renderedComponents,(function(t){return n("ComponentSettings",{key:t.name,class:{selected:e.selectedComponent===t},attrs:{"component-data":t,"data-name":t.name},nativeOn:{click:function(n){return e.selectComponent(t)}}})})),e._v(" "),0===e.renderedComponents.length?n("VEmpty"):e._e()],2)]),e._v(" "),n("VPopup",{ref:"detailsPopup",staticClass:"component-detail-panel",attrs:{"trigger-element":e.$refs.componentList,open:Boolean(e.selectedComponent)},on:{"popup-change":function(t){!t&&e.closePopper()}}},[e.selectedComponent?n("ComponentDetail",{key:e.selectedComponent.name,attrs:{"component-data":e.selectedComponent},on:{close:function(t){return e.closePopper()},mounted:function(t){return e.updatePopper()}}}):e._e()],1)],1)])};i._withStripped=!0;var a=n(9759);function r(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function o(e){if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function s(e){var t=o(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function l(e){return e instanceof o(e).Element||e instanceof Element}function c(e){return e instanceof o(e).HTMLElement||e instanceof HTMLElement}function d(e){return e?(e.nodeName||"").toLowerCase():null}function u(e){return((l(e)?e.ownerDocument:e.document)||window.document).documentElement}function p(e){return r(u(e)).left+s(e).scrollLeft}function h(e){return o(e).getComputedStyle(e)}function f(e){var t=h(e),n=t.overflow,i=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+a+i)}function m(e,t,n){void 0===n&&(n=!1);var i,a,l=u(t),h=r(e),m=c(t),g={scrollLeft:0,scrollTop:0},v={x:0,y:0};return(m||!m&&!n)&&(("body"!==d(t)||f(l))&&(g=(i=t)!==o(i)&&c(i)?{scrollLeft:(a=i).scrollLeft,scrollTop:a.scrollTop}:s(i)),c(t)?((v=r(t)).x+=t.clientLeft,v.y+=t.clientTop):l&&(v.x=p(l))),{x:h.left+g.scrollLeft-v.x,y:h.top+g.scrollTop-v.y,width:h.width,height:h.height}}function g(e){return{x:e.offsetLeft,y:e.offsetTop,width:e.offsetWidth,height:e.offsetHeight}}function v(e){return"html"===d(e)?e:e.assignedSlot||e.parentNode||e.host||u(e)}function b(e){return["html","body","#document"].indexOf(d(e))>=0?e.ownerDocument.body:c(e)&&f(e)?e:b(v(e))}function y(e,t){void 0===t&&(t=[]);var n=b(e),i="body"===d(n),a=o(n),r=i?[a].concat(a.visualViewport||[],f(n)?n:[]):n,s=t.concat(r);return i?s:s.concat(y(v(r)))}function w(e){return["table","td","th"].indexOf(d(e))>=0}function x(e){if(!c(e)||"fixed"===h(e).position)return null;var t=e.offsetParent;if(t){var n=u(t);if("body"===d(t)&&"static"===h(t).position&&"static"!==h(n).position)return n}return t}function _(e){for(var t=o(e),n=x(e);n&&w(n)&&"static"===h(n).position;)n=x(n);return n&&"body"===d(n)&&"static"===h(n).position?t:n||function(e){for(var t=v(e);c(t)&&["html","body"].indexOf(d(t))<0;){var n=h(t);if("none"!==n.transform||"none"!==n.perspective||n.willChange&&"auto"!==n.willChange)return t;t=t.parentNode}return null}(e)||t}var k="top",C="bottom",S="right",E="left",M="auto",z=[k,C,S,E],A="start",$="end",O="viewport",I="popper",L=z.reduce((function(e,t){return e.concat([t+"-"+A,t+"-"+$])}),[]),T=[].concat(z,[M]).reduce((function(e,t){return e.concat([t,t+"-"+A,t+"-"+$])}),[]),P=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function D(e){var t=new Map,n=new Set,i=[];function a(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var i=t.get(e);i&&a(i)}})),i.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||a(e)})),i}var V={placement:"bottom",modifiers:[],strategy:"absolute"};function B(){for(var e=arguments.length,t=new Array(e),n=0;nt.map((t=>{const n=`${e.name}.${t.name}`;return{...t,key:n,provider:e}}));const[C]=(0,r.registerAndGetData)("launchBar.recommended",{word:"搜索",href:"https://search.bilibili.com/"});var S=Vue.extend({components:{VIcon:a.VIcon,VLoading:a.VLoading,VEmpty:a.VEmpty,ActionItem:b},data:()=>({recommended:C,actions:[],keyword:"",noActions:!1}),computed:{isHistory(){return 0===this.keyword.length}},watch:{keyword(){this.getActions()}},async mounted(){this.getActions(),(0,s.matchUrlPattern)(/^https?:\/\/search\.bilibili\.com/)&&(0,o.select)("#search-keyword").then((e=>{e&&(this.keyword=e.value,document.addEventListener("change",(e=>{e.target instanceof HTMLInputElement&&"search-keyword"===e.target.id&&(this.keyword=e.target.value)})))}))},methods:{getOnlineActions:lodash.debounce((async function(){const e=(await Promise.all(_.map((async e=>k(e,await e.getActions(this.keyword)))))).flat();if(this.isHistory)return;const t=new l.Z(e,{keys:["indexer","displayName","name","description","key"]}).search(this.keyword);console.log(t),this.actions=t.map((e=>e.item)).slice(0,12),this.noActions=0===this.actions.length}),200),getActions:async function(){if(this.noActions=!1,this.isHistory)return void(this.actions=k(x.dr,await x.dr.getActions(this.keyword)));this.actions=[],this.getOnlineActions()},async handleEnter(){if(this.actions.length>0&&!this.isHistory){const[e]=this.actions;if(!1===e.explicitSelect)return void e.action()}this.keyword?(0,w.search)(this.keyword):window.open(this.recommended.href,"_blank")},handleUp(e){e.isComposing||(this.$refs.list.querySelector(".suggest-item:last-child").focus(),e.preventDefault())},handleDown(e){e.isComposing||(this.$refs.list.querySelector(".suggest-item").focus(),e.preventDefault())},previousItem(e,t){0===t?this.focus():e.currentTarget.previousElementSibling.focus()},nextItem(e,t){t!==this.actions.length-1?e.currentTarget.nextElementSibling.focus():this.focus()},search:w.search,onDeleteItem(e,t){this.previousItem(e,t),this.getActions()},onClearHistory(){this.focus(),this.getActions()},focus(){this.$refs.input.focus()}}}),E=n(9506),M=n.n(E),z={insert:"head",singleton:!1},A=(p()(M(),z),M().locals,(0,g.Z)(S,i,[],!1,null,null,null));A.options.__file="src/components/launch-bar/LaunchBar.vue";var $=A.exports},1020:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"be-settings"},[n("div",{staticClass:"sidebar"},[n("div",{ref:"widgetsIcon",class:{open:e.widgetsOpened},attrs:{title:"功能"},on:{click:[function(t){return t.shiftKey?e.theWorld(t):null},function(t){if(t.ctrlKey||t.shiftKey||t.altKey||t.metaKey)return null;e.widgetsOpened=!e.widgetsOpened}],mouseover:function(t){return e.loadPanel("widgetsPanelPopup")}}},[n("VIcon",{attrs:{icon:"widgets",size:26}})],1),e._v(" "),n("div",{ref:"settingsIcon",class:{open:e.settingsOpened},attrs:{title:"设置"},on:{click:function(t){e.settingsOpened=!e.settingsOpened},mouseover:function(t){return e.loadPanel("settingsPanelPopup")}}},[n("VIcon",{attrs:{icon:"settings-outline",size:26}})],1)]),e._v(" "),n("VPopup",{ref:"widgetsPanelPopup",staticClass:"widgets-panel-popup",attrs:{"trigger-element":e.$refs.widgetsIcon,fixed:!0},model:{value:e.widgetsOpened,callback:function(t){e.widgetsOpened=t},expression:"widgetsOpened"}},[n("WidgetsPanel")],1),e._v(" "),n("VPopup",{ref:"settingsPanelPopup",staticClass:"settings-panel-popup",attrs:{"trigger-element":e.$refs.settingsIcon,"auto-close-predicate":e.settingsPanalClosePredicate,fixed:!0},model:{value:e.settingsOpened,callback:function(t){e.settingsOpened=t},expression:"settingsOpened"}},[n("SettingsPanel",{on:{close:function(t){e.settingsOpened=!1}}})],1)],1)};i._withStripped=!0;var a=n(9759),r=n(5842),o={name:"SettingsContainer",components:{VPopup:a.VPopup,VIcon:a.VIcon,SettingsPanel:()=>Promise.resolve().then(n.bind(n,202)).then((e=>e.default)),WidgetsPanel:()=>Promise.resolve().then(n.bind(n,5926)).then((e=>e.default))},data:()=>({settingsOpened:!1,widgetsOpened:!1}),methods:{theWorld(){r.externalApis.theWorld(0)},settingsPanalClosePredicate:e=>!dqa(".be-settings-extra-options").some((t=>t===e.target||t.contains(e.target))),loadPanel(e){const t=this.$refs[e];t&&(t?.loaded??0)&&(t.loaded=!0)}}},s=n(3379),l=n.n(s),c=n(857),d=n.n(c),u={insert:"head",singleton:!1},p=(l()(d(),u),d().locals,(0,n(1900).Z)(o,i,[],!1,null,null,null));p.options.__file="src/components/settings-panel/SettingsContainer.vue";var h=p.exports},202:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Pt}});var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"settings-panel",class:{collasped:e.collasped,peek:e.peek}},[n("div",{staticClass:"settings-panel-header"},[n("VIcon",{attrs:{icon:"settings-outline"}}),e._v(" "),n("div",{staticClass:"title"},[e._v("\n 设置\n ")]),e._v(" "),n("div",{staticClass:"settings-panel-search"},[n("VIcon",{attrs:{icon:"search",size:18}}),e._v(" "),n("TextBox",{attrs:{placeholder:"搜索"},model:{value:e.searchKeyword,callback:function(t){e.searchKeyword=t},expression:"searchKeyword"}})],1),e._v(" "),n("div",{staticClass:"peek",attrs:{title:"透视"},on:{mouseover:function(t){e.peek=!0},mouseout:function(t){e.peek=!1}}},[n("VIcon",{attrs:{icon:"eye",size:18}})],1),e._v(" "),n("div",{staticClass:"close",on:{click:function(t){return e.$emit("close")}}},[n("VIcon",{attrs:{icon:"close",size:18}})],1)],1),e._v(" "),n("div",{staticClass:"settings-panel-content"},[n("div",{ref:"sidebarContainer",staticClass:"sidebar"},[n("ComponentTags",{ref:"componentTags",on:{change:function(t){e.searchFilter=t}}})],1),e._v(" "),n("div",{ref:"mainContainer",staticClass:"main"},[n("div",{ref:"componentList",staticClass:"component-list"},[e._l(e.renderedComponents,(function(t){return n("ComponentSettings",{key:t.name,class:{selected:e.selectedComponent===t},attrs:{"component-data":t,"data-name":t.name},nativeOn:{click:function(n){return e.selectComponent(t)}}})})),e._v(" "),0===e.renderedComponents.length?n("VEmpty"):e._e()],2)]),e._v(" "),n("VPopup",{ref:"detailsPopup",staticClass:"component-detail-panel",attrs:{"trigger-element":e.$refs.componentList,open:Boolean(e.selectedComponent)},on:{"popup-change":function(t){!t&&e.closePopper()}}},[e.selectedComponent?n("ComponentDetail",{key:e.selectedComponent.name,attrs:{"component-data":e.selectedComponent},on:{close:function(t){return e.closePopper()},mounted:function(t){return e.updatePopper()}}}):e._e()],1)],1)])};i._withStripped=!0;var a=n(9759);function r(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function o(e){if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function s(e){var t=o(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function l(e){return e instanceof o(e).Element||e instanceof Element}function c(e){return e instanceof o(e).HTMLElement||e instanceof HTMLElement}function d(e){return e?(e.nodeName||"").toLowerCase():null}function u(e){return((l(e)?e.ownerDocument:e.document)||window.document).documentElement}function p(e){return r(u(e)).left+s(e).scrollLeft}function h(e){return o(e).getComputedStyle(e)}function f(e){var t=h(e),n=t.overflow,i=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+a+i)}function m(e,t,n){void 0===n&&(n=!1);var i,a,l=u(t),h=r(e),m=c(t),g={scrollLeft:0,scrollTop:0},v={x:0,y:0};return(m||!m&&!n)&&(("body"!==d(t)||f(l))&&(g=(i=t)!==o(i)&&c(i)?{scrollLeft:(a=i).scrollLeft,scrollTop:a.scrollTop}:s(i)),c(t)?((v=r(t)).x+=t.clientLeft,v.y+=t.clientTop):l&&(v.x=p(l))),{x:h.left+g.scrollLeft-v.x,y:h.top+g.scrollTop-v.y,width:h.width,height:h.height}}function g(e){return{x:e.offsetLeft,y:e.offsetTop,width:e.offsetWidth,height:e.offsetHeight}}function v(e){return"html"===d(e)?e:e.assignedSlot||e.parentNode||e.host||u(e)}function b(e){return["html","body","#document"].indexOf(d(e))>=0?e.ownerDocument.body:c(e)&&f(e)?e:b(v(e))}function y(e,t){void 0===t&&(t=[]);var n=b(e),i="body"===d(n),a=o(n),r=i?[a].concat(a.visualViewport||[],f(n)?n:[]):n,s=t.concat(r);return i?s:s.concat(y(v(r)))}function w(e){return["table","td","th"].indexOf(d(e))>=0}function x(e){if(!c(e)||"fixed"===h(e).position)return null;var t=e.offsetParent;if(t){var n=u(t);if("body"===d(t)&&"static"===h(t).position&&"static"!==h(n).position)return n}return t}function _(e){for(var t=o(e),n=x(e);n&&w(n)&&"static"===h(n).position;)n=x(n);return n&&"body"===d(n)&&"static"===h(n).position?t:n||function(e){for(var t=v(e);c(t)&&["html","body"].indexOf(d(t))<0;){var n=h(t);if("none"!==n.transform||"none"!==n.perspective||n.willChange&&"auto"!==n.willChange)return t;t=t.parentNode}return null}(e)||t}var k="top",C="bottom",S="right",E="left",M="auto",z=[k,C,S,E],A="start",$="end",O="viewport",I="popper",L=z.reduce((function(e,t){return e.concat([t+"-"+A,t+"-"+$])}),[]),T=[].concat(z,[M]).reduce((function(e,t){return e.concat([t,t+"-"+A,t+"-"+$])}),[]),P=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function D(e){var t=new Map,n=new Set,i=[];function a(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var i=t.get(e);i&&a(i)}})),i.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||a(e)})),i}var V={placement:"bottom",modifiers:[],strategy:"absolute"};function B(){for(var e=arguments.length,t=new Array(e),n=0;n=0?"x":"y"}function R(e){var t,n=e.reference,i=e.element,a=e.placement,r=a?j(a):null,o=a?q(a):null,s=n.x+n.width/2-i.width/2,l=n.y+n.height/2-i.height/2;switch(r){case k:t={x:s,y:n.y-i.height};break;case C:t={x:s,y:n.y+n.height};break;case S:t={x:n.x+n.width,y:l};break;case E:t={x:n.x-i.width,y:l};break;default:t={x:n.x,y:n.y}}var c=r?H(r):null;if(null!=c){var d="y"===c?"height":"width";switch(o){case A:t[c]=t[c]-(n[d]/2-i[d]/2);break;case $:t[c]=t[c]+(n[d]/2-i[d]/2)}}return t}// eslint-disable-next-line import/no-unused-modules var U={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Z(e){var t,n=e.popper,i=e.popperRect,a=e.placement,r=e.offsets,s=e.position,l=e.gpuAcceleration,c=e.adaptive,d=e.roundOffsets?function(e){var t=e.x,n=e.y,i=window.devicePixelRatio||1;return{x:Math.round(t*i)/i||0,y:Math.round(n*i)/i||0}}(r):r,p=d.x,h=void 0===p?0:p,f=d.y,m=void 0===f?0:f,g=r.hasOwnProperty("x"),v=r.hasOwnProperty("y"),b=E,y=k,w=window;if(c){var x=_(n);x===o(n)&&(x=u(n)),a===k&&(y=C,m-=x.clientHeight-i.height,m*=l?1:-1),a===E&&(b=S,h-=x.clientWidth-i.width,h*=l?1:-1)}var M,z=Object.assign({position:s},c&&U);return l?Object.assign(Object.assign({},z),{},((M={})[y]=v?"0":"",M[b]=g?"0":"",M.transform=(w.devicePixelRatio||1)<2?"translate("+h+"px, "+m+"px)":"translate3d("+h+"px, "+m+"px, 0)",M)):Object.assign(Object.assign({},z),{},((t={})[y]=v?m+"px":"",t[b]=g?h+"px":"",t.transform="",t))}// eslint-disable-next-line import/no-unused-modules var W={left:"right",right:"left",bottom:"top",top:"bottom"};function G(e){return e.replace(/left|right|bottom|top/g,(function(e){return W[e]}))}var X={start:"end",end:"start"};function K(e){return e.replace(/start|end/g,(function(e){return X[e]}))}function J(e,t){var n,i=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(i&&((n=i)instanceof o(n).ShadowRoot||n instanceof ShadowRoot)){var a=t;do{if(a&&e.isSameNode(a))return!0;a=a.parentNode||a.host}while(a)}return!1}function Y(e){return Object.assign(Object.assign({},e),{},{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Q(e,t){return t===O?Y(function(e){var t=o(e),n=u(e),i=t.visualViewport,a=n.clientWidth,r=n.clientHeight,s=0,l=0;return i&&(a=i.width,r=i.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(s=i.offsetLeft,l=i.offsetTop)),{width:a,height:r,x:s+p(e),y:l}}(e)):c(t)?function(e){var t=r(e);return t.top=t.top+e.clientTop,t.left=t.left+e.clientLeft,t.bottom=t.top+e.clientHeight,t.right=t.left+e.clientWidth,t.width=e.clientWidth,t.height=e.clientHeight,t.x=t.left,t.y=t.top,t}(t):Y(function(e){var t=u(e),n=s(e),i=e.ownerDocument.body,a=Math.max(t.scrollWidth,t.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),r=Math.max(t.scrollHeight,t.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),o=-n.scrollLeft+p(e),l=-n.scrollTop;return"rtl"===h(i||t).direction&&(o+=Math.max(t.clientWidth,i?i.clientWidth:0)-a),{width:a,height:r,x:o,y:l}}(u(e)))}function ee(e,t,n){var i="clippingParents"===t?function(e){var t=y(v(e)),n=["absolute","fixed"].indexOf(h(e).position)>=0&&c(e)?_(e):e;return l(n)?t.filter((function(e){return l(e)&&J(e,n)&&"body"!==d(e)})):[]}(e):[].concat(t),a=[].concat(i,[n]),r=a[0],o=a.reduce((function(t,n){var i=Q(e,n);return t.top=Math.max(i.top,t.top),t.right=Math.min(i.right,t.right),t.bottom=Math.min(i.bottom,t.bottom),t.left=Math.max(i.left,t.left),t}),Q(e,r));return o.width=o.right-o.left,o.height=o.bottom-o.top,o.x=o.left,o.y=o.top,o}function te(e){return Object.assign(Object.assign({},{top:0,right:0,bottom:0,left:0}),e)}function ne(e,t){return t.reduce((function(t,n){return t[n]=e,t}),{})} diff --git a/dist/bilibili-evolved.user.js b/dist/bilibili-evolved.user.js index 278f5f3ed..d65580ce4 100644 --- a/dist/bilibili-evolved.user.js +++ b/dist/bilibili-evolved.user.js @@ -47,11 +47,11 @@ e.__proto__=t}(e,ke):function(e,t,n){for(var i=0,a=n.length;i-1)if(r&&!x(a,"default"))o=!1;else if(""===o||o===M(e)){var l=Re(String,a.type);(l<0||s0&&(ft((i=mt(i,(t||"")+"_"+n))[0])&&ft(c)&&(d[l]=we(c.text+i[0].text),i.shift()),d.push.apply(d,i)):s(i)?ft(c)?d[l]=we(c.text+i):""!==i&&d.push(we(i)):ft(i)&&ft(c)?d[l]=we(c.text+i.text):(o(e._isVList)&&r(i.tag)&&a(i.key)&&r(t)&&(i.key="__vlist"+t+"_"+n+"__"),d.push(i)));return d}function gt(e,t){if(e){for(var n=Object.create(null),i=de?Reflect.ownKeys(e):Object.keys(e),a=0;a0,o=e?!!e.$stable:!r,s=e&&e.$key;if(e){if(e._normalized)return e._normalized;if(o&&n&&n!==i&&s===n.$key&&!r&&!n.$hasNormal)return n;for(var l in a={},e)e[l]&&"$"!==l[0]&&(a[l]=wt(t,l,e[l]))}else a={};for(var c in t)c in a||(a[c]=xt(t,c));return e&&Object.isExtensible(e)&&(e._normalized=a),R(a,"$stable",o),R(a,"$key",s),R(a,"$hasNormal",r),a}function wt(e,t,n){var i=function(){var e=arguments.length?n.apply(null,arguments):n({});return(e=e&&"object"==typeof e&&!Array.isArray(e)?[e]:ht(e))&&(0===e.length||1===e.length&&e[0].isComment)?void 0:e};return n.proxy&&Object.defineProperty(e,t,{get:i,enumerable:!0,configurable:!0}),i}function xt(e,t){return function(){return e[t]}}function _t(e,t){var n,i,a,o,s;if(Array.isArray(e)||"string"==typeof e)for(n=new Array(e.length),i=0,a=e.length;idocument.createEvent("Event").timeStamp&&(mn=function(){return gn.now()})}function vn(){var e,t;for(fn=mn(),pn=!0,ln.sort((function(e,t){return e.id-t.id})),hn=0;hnhn&&ln[n].id>e.id;)n--;ln.splice(n+1,0,e)}else ln.push(e);un||(un=!0,at(vn))}}(this)},yn.prototype.run=function(){if(this.active){var e=this.get();if(e!==this.value||l(e)||this.deep){var t=this.value;if(this.value=e,this.user)try{this.cb.call(this.vm,e,t)}catch(e){Ue(e,this.vm,'callback for watcher "'+this.expression+'"')}else this.cb.call(this.vm,e,t)}}},yn.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},yn.prototype.depend=function(){for(var e=this.deps.length;e--;)this.deps[e].depend()},yn.prototype.teardown=function(){if(this.active){this.vm._isBeingDestroyed||y(this.vm._watchers,this);for(var e=this.deps.length;e--;)this.deps[e].removeSub(this);this.active=!1}};var wn={enumerable:!0,configurable:!0,get:I,set:I};function xn(e,t,n){wn.get=function(){return this[t][n]},wn.set=function(e){this[t][n]=e},Object.defineProperty(e,n,wn)}function _n(e){e._watchers=[];var t=e.$options;t.props&&function(e,t){var n=e.$options.propsData||{},i=e._props={},a=e.$options._propKeys=[];e.$parent&&Ee(!1);var r=function(r){a.push(r);var o=je(r,t,n,e);Ae(i,r,o),r in e||xn(e,"_props",r)};for(var o in t)r(o);Ee(!0)}(e,t.props),t.methods&&function(e,t){e.$options.props;for(var n in t)e[n]="function"!=typeof t[n]?I:z(t[n],e)}(e,t.methods),t.data?function(e){var t=e.$options.data;d(t=e._data="function"==typeof t?function(e,t){me();try{return e.call(t,t)}catch(e){return Ue(e,t,"data()"),{}}finally{ge()}}(t,e):t||{})||(t={});var n=Object.keys(t),i=e.$options.props,a=(e.$options.methods,n.length);for(;a--;){var r=n[a];0,i&&x(i,r)||H(r)||xn(e,"_data",r)}ze(t,!0)}(e):ze(e._data={},!0),t.computed&&function(e,t){var n=e._computedWatchers=Object.create(null),i=oe();for(var a in t){var r=t[a],o="function"==typeof r?r:r.get;0,i||(n[a]=new yn(e,o||I,I,kn)),a in e||Cn(e,a,r)}}(e,t.computed),t.watch&&t.watch!==ie&&function(e,t){for(var n in t){var i=t[n];if(Array.isArray(i))for(var a=0;a-1:"string"==typeof e?e.split(",").indexOf(t)>-1:!!u(e)&&e.test(t)}function Tn(e,t){var n=e.cache,i=e.keys,a=e._vnode;for(var r in n){var o=n[r];if(o){var s=In(o.componentOptions);s&&!t(s)&&Pn(n,r,i,a)}}}function Pn(e,t,n,i){var a=e[t];!a||i&&a.tag===i.tag||a.componentInstance.$destroy(),e[t]=null,y(n,t)}!function(e){e.prototype._init=function(e){var t=this;t._uid=zn++,t._isVue=!0,e&&e._isComponent?function(e,t){var n=e.$options=Object.create(e.constructor.options),i=t._parentVnode;n.parent=t.parent,n._parentVnode=i;var a=i.componentOptions;n.propsData=a.propsData,n._parentListeners=a.listeners,n._renderChildren=a.children,n._componentTag=a.tag,t.render&&(n.render=t.render,n.staticRenderFns=t.staticRenderFns)}(t,e):t.$options=Fe(An(t.constructor),e||{},t),t._renderProxy=t,t._self=t,function(e){var t=e.$options,n=t.parent;if(n&&!t.abstract){for(;n.$options.abstract&&n.$parent;)n=n.$parent;n.$children.push(e)}e.$parent=n,e.$root=n?n.$root:e,e.$children=[],e.$refs={},e._watcher=null,e._inactive=null,e._directInactive=!1,e._isMounted=!1,e._isDestroyed=!1,e._isBeingDestroyed=!1}(t),function(e){e._events=Object.create(null),e._hasHookEvent=!1;var t=e.$options._parentListeners;t&&en(e,t)}(t),function(e){e._vnode=null,e._staticTrees=null;var t=e.$options,n=e.$vnode=t._parentVnode,a=n&&n.context;e.$slots=vt(t._renderChildren,a),e.$scopedSlots=i,e._c=function(t,n,i,a){return Rt(e,t,n,i,a,!1)},e.$createElement=function(t,n,i,a){return Rt(e,t,n,i,a,!0)};var r=n&&n.data;Ae(e,"$attrs",r&&r.attrs||i,null,!0),Ae(e,"$listeners",t._parentListeners||i,null,!0)}(t),sn(t,"beforeCreate"),function(e){var t=gt(e.$options.inject,e);t&&(Ee(!1),Object.keys(t).forEach((function(n){Ae(e,n,t[n])})),Ee(!0))}(t),_n(t),function(e){var t=e.$options.provide;t&&(e._provided="function"==typeof t?t.call(e):t)}(t),sn(t,"created"),t.$options.el&&t.$mount(t.$options.el)}}($n),function(e){var t={get:function(){return this._data}},n={get:function(){return this._props}};Object.defineProperty(e.prototype,"$data",t),Object.defineProperty(e.prototype,"$props",n),e.prototype.$set=$e,e.prototype.$delete=Oe,e.prototype.$watch=function(e,t,n){var i=this;if(d(t))return Mn(i,e,t,n);(n=n||{}).user=!0;var a=new yn(i,e,t,n);if(n.immediate)try{t.call(i,a.value)}catch(e){Ue(e,i,'callback for immediate watcher "'+a.expression+'"')}return function(){a.teardown()}}}($n),function(e){var t=/^hook:/;e.prototype.$on=function(e,n){var i=this;if(Array.isArray(e))for(var a=0,r=e.length;a1?A(n):n;for(var i=A(arguments,1),a='event handler for "'+e+'"',r=0,o=n.length;rparseInt(this.max)&&Pn(o,s[0],s,this._vnode)),t.data.keepAlive=!0}return t||e&&e[0]}}};!function(e){var t={get:function(){return j}};Object.defineProperty(e,"config",t),e.util={warn:ue,extend:$,mergeOptions:Fe,defineReactive:Ae},e.set=$e,e.delete=Oe,e.nextTick=at,e.observable=function(e){return ze(e),e},e.options=Object.create(null),F.forEach((function(t){e.options[t+"s"]=Object.create(null)})),e.options._base=e,$(e.options.components,Vn),function(e){e.use=function(e){var t=this._installedPlugins||(this._installedPlugins=[]);if(t.indexOf(e)>-1)return this;var n=A(arguments,1);return n.unshift(this),"function"==typeof e.install?e.install.apply(e,n):"function"==typeof e&&e.apply(null,n),t.push(e),this}}(e),function(e){e.mixin=function(e){return this.options=Fe(this.options,e),this}}(e),On(e),function(e){F.forEach((function(t){e[t]=function(e,n){return n?("component"===t&&d(n)&&(n.name=n.name||e,n=this.options._base.extend(n)),"directive"===t&&"function"==typeof n&&(n={bind:n,update:n}),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}}))}(e)}($n),Object.defineProperty($n.prototype,"$isServer",{get:oe}),Object.defineProperty($n.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Object.defineProperty($n,"FunctionalRenderContext",{value:Vt}),$n.version="2.6.12";var Bn=g("style,class"),Fn=g("input,textarea,option,select,progress"),Nn=function(e,t,n){return"value"===n&&Fn(e)&&"button"!==t||"selected"===n&&"option"===e||"checked"===n&&"input"===e||"muted"===n&&"video"===e},jn=g("contenteditable,draggable,spellcheck"),qn=g("events,caret,typing,plaintext-only"),Hn=g("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,translate,truespeed,typemustmatch,visible"),Rn="http://www.w3.org/1999/xlink",Un=function(e){return":"===e.charAt(5)&&"xlink"===e.slice(0,5)},Zn=function(e){return Un(e)?e.slice(6,e.length):""},Wn=function(e){return null==e||!1===e};function Gn(e){for(var t=e.data,n=e,i=e;r(i.componentInstance);)(i=i.componentInstance._vnode)&&i.data&&(t=Xn(i.data,t));for(;r(n=n.parent);)n&&n.data&&(t=Xn(t,n.data));return function(e,t){if(r(e)||r(t))return Kn(e,Jn(t));return""}(t.staticClass,t.class)}function Xn(e,t){return{staticClass:Kn(e.staticClass,t.staticClass),class:r(e.class)?[e.class,t.class]:t.class}}function Kn(e,t){return e?t?e+" "+t:e:t||""}function Jn(e){return Array.isArray(e)?function(e){for(var t,n="",i=0,a=e.length;i-1?_i(e,t,n):Hn(t)?Wn(n)?e.removeAttribute(t):(n="allowfullscreen"===t&&"EMBED"===e.tagName?"true":t,e.setAttribute(t,n)):jn(t)?e.setAttribute(t,function(e,t){return Wn(t)||"false"===t?"false":"contenteditable"===e&&qn(t)?t:"true"}(t,n)):Un(t)?Wn(n)?e.removeAttributeNS(Rn,Zn(t)):e.setAttributeNS(Rn,t,n):_i(e,t,n)}function _i(e,t,n){if(Wn(n))e.removeAttribute(t);else{if(Y&&!Q&&"TEXTAREA"===e.tagName&&"placeholder"===t&&""!==n&&!e.__ieph){var i=function(t){t.stopImmediatePropagation(),e.removeEventListener("input",i)};e.addEventListener("input",i),e.__ieph=!0}e.setAttribute(t,n)}}var ki={create:wi,update:wi};function Ci(e,t){var n=t.elm,i=t.data,o=e.data;if(!(a(i.staticClass)&&a(i.class)&&(a(o)||a(o.staticClass)&&a(o.class)))){var s=Gn(t),l=n._transitionClasses;r(l)&&(s=Kn(s,Jn(l))),s!==n._prevClass&&(n.setAttribute("class",s),n._prevClass=s)}}var Si,Ei,Mi,zi,Ai,$i,Oi={create:Ci,update:Ci},Ii=/[\w).+\-_$\]]/;function Li(e){var t,n,i,a,r,o=!1,s=!1,l=!1,c=!1,d=0,u=0,p=0,h=0;for(i=0;i=0&&" "===(m=e.charAt(f));f--);m&&Ii.test(m)||(c=!0)}}else void 0===a?(h=i+1,a=e.slice(0,i).trim()):g();function g(){(r||(r=[])).push(e.slice(h,i).trim()),h=i+1}if(void 0===a?a=e.slice(0,i).trim():0!==h&&g(),r)for(i=0;i-1?{exp:e.slice(0,zi),key:'"'+e.slice(zi+1)+'"'}:{exp:e,key:null};Ei=e,zi=Ai=$i=0;for(;!Ki();)Ji(Mi=Xi())?Qi(Mi):91===Mi&&Yi(Mi);return{exp:e.slice(0,Ai),key:e.slice(Ai+1,$i)}}(e);return null===n.key?e+"="+t:"$set("+n.exp+", "+n.key+", "+t+")"}function Xi(){return Ei.charCodeAt(++zi)}function Ki(){return zi>=Si}function Ji(e){return 34===e||39===e}function Yi(e){var t=1;for(Ai=zi;!Ki();)if(Ji(e=Xi()))Qi(e);else if(91===e&&t++,93===e&&t--,0===t){$i=zi;break}}function Qi(e){for(var t=e;!Ki()&&(e=Xi())!==t;);}var ea,ta="__r";function na(e,t,n){var i=ea;return function a(){var r=t.apply(null,arguments);null!==r&&ra(e,a,n,i)}}var ia=Ke&&!(ne&&Number(ne[1])<=53);function aa(e,t,n,i){if(ia){var a=fn,r=t;t=r._wrapper=function(e){if(e.target===e.currentTarget||e.timeStamp>=a||e.timeStamp<=0||e.target.ownerDocument!==document)return r.apply(this,arguments)}}ea.addEventListener(e,t,ae?{capture:n,passive:i}:n)}function ra(e,t,n,i){(i||ea).removeEventListener(e,t._wrapper||t,n)}function oa(e,t){if(!a(e.data.on)||!a(t.data.on)){var n=t.data.on||{},i=e.data.on||{};ea=t.elm,function(e){if(r(e.__r)){var t=Y?"change":"input";e[t]=[].concat(e.__r,e[t]||[]),delete e.__r}r(e.__c)&&(e.change=[].concat(e.__c,e.change||[]),delete e.__c)}(n),dt(n,i,aa,ra,na,t.context),ea=void 0}}var sa,la={create:oa,update:oa};function ca(e,t){if(!a(e.data.domProps)||!a(t.data.domProps)){var n,i,o=t.elm,s=e.data.domProps||{},l=t.data.domProps||{};for(n in r(l.__ob__)&&(l=t.data.domProps=$({},l)),s)n in l||(o[n]="");for(n in l){if(i=l[n],"textContent"===n||"innerHTML"===n){if(t.children&&(t.children.length=0),i===s[n])continue;1===o.childNodes.length&&o.removeChild(o.childNodes[0])}if("value"===n&&"PROGRESS"!==o.tagName){o._value=i;var c=a(i)?"":String(i);da(o,c)&&(o.value=c)}else if("innerHTML"===n&&ei(o.tagName)&&a(o.innerHTML)){(sa=sa||document.createElement("div")).innerHTML=""+i+"";for(var d=sa.firstChild;o.firstChild;)o.removeChild(o.firstChild);for(;d.firstChild;)o.appendChild(d.firstChild)}else if(i!==s[n])try{o[n]=i}catch(e){}}}}function da(e,t){return!e.composing&&("OPTION"===e.tagName||function(e,t){var n=!0;try{n=document.activeElement!==e}catch(e){}return n&&e.value!==t}(e,t)||function(e,t){var n=e.value,i=e._vModifiers;if(r(i)){if(i.number)return m(n)!==m(t);if(i.trim)return n.trim()!==t.trim()}return n!==t}(e,t))}var ua={create:ca,update:ca},pa=_((function(e){var t={},n=/:(.+)/;return e.split(/;(?![^(]*\))/g).forEach((function(e){if(e){var i=e.split(n);i.length>1&&(t[i[0].trim()]=i[1].trim())}})),t}));function ha(e){var t=fa(e.style);return e.staticStyle?$(e.staticStyle,t):t}function fa(e){return Array.isArray(e)?O(e):"string"==typeof e?pa(e):e}var ma,ga=/^--/,va=/\s*!important$/,ba=function(e,t,n){if(ga.test(t))e.style.setProperty(t,n);else if(va.test(n))e.style.setProperty(M(t),n.replace(va,""),"important");else{var i=wa(t);if(Array.isArray(n))for(var a=0,r=n.length;a-1?t.split(ka).forEach((function(t){return e.classList.add(t)})):e.classList.add(t);else{var n=" "+(e.getAttribute("class")||"")+" ";n.indexOf(" "+t+" ")<0&&e.setAttribute("class",(n+t).trim())}}function Sa(e,t){if(t&&(t=t.trim()))if(e.classList)t.indexOf(" ")>-1?t.split(ka).forEach((function(t){return e.classList.remove(t)})):e.classList.remove(t),e.classList.length||e.removeAttribute("class");else{for(var n=" "+(e.getAttribute("class")||"")+" ",i=" "+t+" ";n.indexOf(i)>=0;)n=n.replace(i," ");(n=n.trim())?e.setAttribute("class",n):e.removeAttribute("class")}}function Ea(e){if(e){if("object"==typeof e){var t={};return!1!==e.css&&$(t,Ma(e.name||"v")),$(t,e),t}return"string"==typeof e?Ma(e):void 0}}var Ma=_((function(e){return{enterClass:e+"-enter",enterToClass:e+"-enter-to",enterActiveClass:e+"-enter-active",leaveClass:e+"-leave",leaveToClass:e+"-leave-to",leaveActiveClass:e+"-leave-active"}})),za=G&&!Q,Aa="transition",$a="animation",Oa="transition",Ia="transitionend",La="animation",Ta="animationend";za&&(void 0===window.ontransitionend&&void 0!==window.onwebkittransitionend&&(Oa="WebkitTransition",Ia="webkitTransitionEnd"),void 0===window.onanimationend&&void 0!==window.onwebkitanimationend&&(La="WebkitAnimation",Ta="webkitAnimationEnd"));var Pa=G?window.requestAnimationFrame?window.requestAnimationFrame.bind(window):setTimeout:function(e){return e()};function Da(e){Pa((function(){Pa(e)}))}function Va(e,t){var n=e._transitionClasses||(e._transitionClasses=[]);n.indexOf(t)<0&&(n.push(t),Ca(e,t))}function Ba(e,t){e._transitionClasses&&y(e._transitionClasses,t),Sa(e,t)}function Fa(e,t,n){var i=ja(e,t),a=i.type,r=i.timeout,o=i.propCount;if(!a)return n();var s=a===Aa?Ia:Ta,l=0,c=function(){e.removeEventListener(s,d),n()},d=function(t){t.target===e&&++l>=o&&c()};setTimeout((function(){l0&&(n=Aa,d=o,u=r.length):t===$a?c>0&&(n=$a,d=c,u=l.length):u=(n=(d=Math.max(o,c))>0?o>c?Aa:$a:null)?n===Aa?r.length:l.length:0,{type:n,timeout:d,propCount:u,hasTransform:n===Aa&&Na.test(i[Oa+"Property"])}}function qa(e,t){for(;e.length1}function Ga(e,t){!0!==t.data.show&&Ra(t)}var Xa=function(e){var t,n,i={},l=e.modules,c=e.nodeOps;for(t=0;tf?y(e,a(n[v+1])?null:n[v+1].elm,n,h,v,i):h>v&&x(t,p,f)}(p,g,v,n,d):r(v)?(r(e.text)&&c.setTextContent(p,""),y(p,null,v,0,v.length-1,n)):r(g)?x(g,0,g.length-1):r(e.text)&&c.setTextContent(p,""):e.text!==t.text&&c.setTextContent(p,t.text),r(f)&&r(h=f.hook)&&r(h=h.postpatch)&&h(e,t)}}}function S(e,t,n){if(o(n)&&r(e.parent))e.parent.data.pendingInsert=t;else for(var i=0;i-1,o.selected!==r&&(o.selected=r);else if(P(er(o),i))return void(e.selectedIndex!==s&&(e.selectedIndex=s));a||(e.selectedIndex=-1)}}function Qa(e,t){return t.every((function(t){return!P(t,e)}))}function er(e){return"_value"in e?e._value:e.value}function tr(e){e.target.composing=!0}function nr(e){e.target.composing&&(e.target.composing=!1,ir(e.target,"input"))}function ir(e,t){var n=document.createEvent("HTMLEvents");n.initEvent(t,!0,!0),e.dispatchEvent(n)}function ar(e){return!e.componentInstance||e.data&&e.data.transition?e:ar(e.componentInstance._vnode)}var rr={model:Ka,show:{bind:function(e,t,n){var i=t.value,a=(n=ar(n)).data&&n.data.transition,r=e.__vOriginalDisplay="none"===e.style.display?"":e.style.display;i&&a?(n.data.show=!0,Ra(n,(function(){e.style.display=r}))):e.style.display=i?r:"none"},update:function(e,t,n){var i=t.value;!i!=!t.oldValue&&((n=ar(n)).data&&n.data.transition?(n.data.show=!0,i?Ra(n,(function(){e.style.display=e.__vOriginalDisplay})):Ua(n,(function(){e.style.display="none"}))):e.style.display=i?e.__vOriginalDisplay:"none")},unbind:function(e,t,n,i,a){a||(e.style.display=e.__vOriginalDisplay)}}},or={name:String,appear:Boolean,css:Boolean,mode:String,type:String,enterClass:String,leaveClass:String,enterToClass:String,leaveToClass:String,enterActiveClass:String,leaveActiveClass:String,appearClass:String,appearActiveClass:String,appearToClass:String,duration:[Number,String,Object]};function sr(e){var t=e&&e.componentOptions;return t&&t.Ctor.options.abstract?sr(Kt(t.children)):e}function lr(e){var t={},n=e.$options;for(var i in n.propsData)t[i]=e[i];var a=n._parentListeners;for(var r in a)t[C(r)]=a[r];return t}function cr(e,t){if(/\d-keep-alive$/.test(t.tag))return e("keep-alive",{props:t.componentOptions.propsData})}var dr=function(e){return e.tag||Xt(e)},ur=function(e){return"show"===e.name},pr={name:"transition",props:or,abstract:!0,render:function(e){var t=this,n=this.$slots.default;if(n&&(n=n.filter(dr)).length){0;var i=this.mode;0;var a=n[0];if(function(e){for(;e=e.parent;)if(e.data.transition)return!0}(this.$vnode))return a;var r=sr(a);if(!r)return a;if(this._leaving)return cr(e,a);var o="__transition-"+this._uid+"-";r.key=null==r.key?r.isComment?o+"comment":o+r.tag:s(r.key)?0===String(r.key).indexOf(o)?r.key:o+r.key:r.key;var l=(r.data||(r.data={})).transition=lr(this),c=this._vnode,d=sr(c);if(r.data.directives&&r.data.directives.some(ur)&&(r.data.show=!0),d&&d.data&&!function(e,t){return t.key===e.key&&t.tag===e.tag}(r,d)&&!Xt(d)&&(!d.componentInstance||!d.componentInstance._vnode.isComment)){var u=d.data.transition=$({},l);if("out-in"===i)return this._leaving=!0,ut(u,"afterLeave",(function(){t._leaving=!1,t.$forceUpdate()})),cr(e,a);if("in-out"===i){if(Xt(r))return c;var p,h=function(){p()};ut(l,"afterEnter",h),ut(l,"enterCancelled",h),ut(u,"delayLeave",(function(e){p=e}))}}return a}}},hr=$({tag:String,moveClass:String},or);function fr(e){e.elm._moveCb&&e.elm._moveCb(),e.elm._enterCb&&e.elm._enterCb()}function mr(e){e.data.newPos=e.elm.getBoundingClientRect()}function gr(e){var t=e.data.pos,n=e.data.newPos,i=t.left-n.left,a=t.top-n.top;if(i||a){e.data.moved=!0;var r=e.elm.style;r.transform=r.WebkitTransform="translate("+i+"px,"+a+"px)",r.transitionDuration="0s"}}delete hr.mode;var vr={Transition:pr,TransitionGroup:{props:hr,beforeMount:function(){var e=this,t=this._update;this._update=function(n,i){var a=nn(e);e.__patch__(e._vnode,e.kept,!1,!0),e._vnode=e.kept,a(),t.call(e,n,i)}},render:function(e){for(var t=this.tag||this.$vnode.data.tag||"span",n=Object.create(null),i=this.prevChildren=this.children,a=this.$slots.default||[],r=this.children=[],o=lr(this),s=0;s-1?ii[e]=t.constructor===window.HTMLUnknownElement||t.constructor===window.HTMLElement:ii[e]=/HTMLUnknownElement/.test(t.toString())},$($n.options.directives,rr),$($n.options.components,vr),$n.prototype.__patch__=G?Xa:I,$n.prototype.$mount=function(e,t){return function(e,t,n){var i;return e.$el=t,e.$options.render||(e.$options.render=ye),sn(e,"beforeMount"),i=function(){e._update(e._render(),n)},new yn(e,i,I,{before:function(){e._isMounted&&!e._isDestroyed&&sn(e,"beforeUpdate")}},!0),n=!1,null==e.$vnode&&(e._isMounted=!0,sn(e,"mounted")),e}(this,e=e&&G?ri(e):void 0,t)},G&&setTimeout((function(){j.devtools&&se&&se.emit("init",$n)}),0);var br=/\{\{((?:.|\r?\n)+?)\}\}/g,yr=/[-.*+?^${}()|[\]\/\\]/g,wr=_((function(e){var t=e[0].replace(yr,"\\$&"),n=e[1].replace(yr,"\\$&");return new RegExp(t+"((?:.|\\n)+?)"+n,"g")}));var xr={staticKeys:["staticClass"],transformNode:function(e,t){t.warn;var n=Ri(e,"class");n&&(e.staticClass=JSON.stringify(n));var i=Hi(e,"class",!1);i&&(e.classBinding=i)},genData:function(e){var t="";return e.staticClass&&(t+="staticClass:"+e.staticClass+","),e.classBinding&&(t+="class:"+e.classBinding+","),t}};var _r,kr={staticKeys:["staticStyle"],transformNode:function(e,t){t.warn;var n=Ri(e,"style");n&&(e.staticStyle=JSON.stringify(pa(n)));var i=Hi(e,"style",!1);i&&(e.styleBinding=i)},genData:function(e){var t="";return e.staticStyle&&(t+="staticStyle:"+e.staticStyle+","),e.styleBinding&&(t+="style:("+e.styleBinding+"),"),t}},Cr=function(e){return(_r=_r||document.createElement("div")).innerHTML=e,_r.textContent},Sr=g("area,base,br,col,embed,frame,hr,img,input,isindex,keygen,link,meta,param,source,track,wbr"),Er=g("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source"),Mr=g("address,article,aside,base,blockquote,body,caption,col,colgroup,dd,details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,title,tr,track"),zr=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,Ar=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,$r="[a-zA-Z_][\\-\\.0-9_a-zA-Z"+q.source+"]*",Or="((?:"+$r+"\\:)?"+$r+")",Ir=new RegExp("^<"+Or),Lr=/^\s*(\/?)>/,Tr=new RegExp("^<\\/"+Or+"[^>]*>"),Pr=/^]+>/i,Dr=/^",""":'"',"&":"&"," ":"\n"," ":"\t","'":"'"},jr=/&(?:lt|gt|quot|amp|#39);/g,qr=/&(?:lt|gt|quot|amp|#39|#10|#9);/g,Hr=g("pre,textarea",!0),Rr=function(e,t){return e&&Hr(e)&&"\n"===t[0]};function Ur(e,t){var n=t?qr:jr;return e.replace(n,(function(e){return Nr[e]}))}var Zr,Wr,Gr,Xr,Kr,Jr,Yr,Qr,eo=/^@|^v-on:/,to=/^v-|^@|^:|^#/,no=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,io=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,ao=/^\(|\)$/g,ro=/^\[.*\]$/,oo=/:(.*)$/,so=/^:|^\.|^v-bind:/,lo=/\.[^.\]]+(?=[^\]]*$)/g,co=/^v-slot(:|$)|^#/,uo=/[\r\n]/,po=/\s+/g,ho=_(Cr),fo="_empty_";function mo(e,t,n){return{type:1,tag:e,attrsList:t,attrsMap:_o(t),rawAttrsMap:{},parent:n,children:[]}}function go(e,t){Zr=t.warn||Pi,Jr=t.isPreTag||L,Yr=t.mustUseProp||L,Qr=t.getTagNamespace||L;var n=t.isReservedTag||L;(function(e){return!!e.component||!n(e.tag)}),Gr=Di(t.modules,"transformNode"),Xr=Di(t.modules,"preTransformNode"),Kr=Di(t.modules,"postTransformNode"),Wr=t.delimiters;var i,a,r=[],o=!1!==t.preserveWhitespace,s=t.whitespace,l=!1,c=!1;function d(e){if(u(e),l||e.processed||(e=vo(e,t)),r.length||e===i||i.if&&(e.elseif||e.else)&&yo(i,{exp:e.elseif,block:e}),a&&!e.forbidden)if(e.elseif||e.else)o=e,(s=function(e){for(var t=e.length;t--;){if(1===e[t].type)return e[t];e.pop()}}(a.children))&&s.if&&yo(s,{exp:o.elseif,block:o});else{if(e.slotScope){var n=e.slotTarget||'"default"';(a.scopedSlots||(a.scopedSlots={}))[n]=e}a.children.push(e),e.parent=a}var o,s;e.children=e.children.filter((function(e){return!e.slotScope})),u(e),e.pre&&(l=!1),Jr(e.tag)&&(c=!1);for(var d=0;d]*>)","i")),p=e.replace(u,(function(e,n,i){return c=i.length,Br(d)||"noscript"===d||(n=n.replace(//g,"$1").replace(//g,"$1")),Rr(d,n)&&(n=n.slice(1)),t.chars&&t.chars(n),""}));l+=e.length-p.length,e=p,E(d,l-c,l)}else{var h=e.indexOf("<");if(0===h){if(Dr.test(e)){var f=e.indexOf("--\x3e");if(f>=0){t.shouldKeepComment&&t.comment(e.substring(4,f),l,l+f+3),k(f+3);continue}}if(Vr.test(e)){var m=e.indexOf("]>");if(m>=0){k(m+2);continue}}var g=e.match(Pr);if(g){k(g[0].length);continue}var v=e.match(Tr);if(v){var b=l;k(v[0].length),E(v[1],b,l);continue}var y=C();if(y){S(y),Rr(y.tagName,e)&&k(1);continue}}var w=void 0,x=void 0,_=void 0;if(h>=0){for(x=e.slice(h);!(Tr.test(x)||Ir.test(x)||Dr.test(x)||Vr.test(x)||(_=x.indexOf("<",1))<0);)h+=_,x=e.slice(h);w=e.substring(0,h)}h<0&&(w=e),w&&k(w.length),t.chars&&w&&t.chars(w,l-w.length,l)}if(e===n){t.chars&&t.chars(e);break}}function k(t){l+=t,e=e.substring(t)}function C(){var t=e.match(Ir);if(t){var n,i,a={tagName:t[1],attrs:[],start:l};for(k(t[0].length);!(n=e.match(Lr))&&(i=e.match(Ar)||e.match(zr));)i.start=l,k(i[0].length),i.end=l,a.attrs.push(i);if(n)return a.unarySlash=n[1],k(n[0].length),a.end=l,a}}function S(e){var n=e.tagName,l=e.unarySlash;r&&("p"===i&&Mr(n)&&E(i),s(n)&&i===n&&E(n));for(var c=o(n)||!!l,d=e.attrs.length,u=new Array(d),p=0;p=0&&a[o].lowerCasedTag!==s;o--);else o=0;if(o>=0){for(var c=a.length-1;c>=o;c--)t.end&&t.end(a[c].tag,n,r);a.length=o,i=o&&a[o-1].tag}else"br"===s?t.start&&t.start(e,[],!0,n,r):"p"===s&&(t.start&&t.start(e,[],!1,n,r),t.end&&t.end(e,n,r))}E()}(e,{warn:Zr,expectHTML:t.expectHTML,isUnaryTag:t.isUnaryTag,canBeLeftOpenTag:t.canBeLeftOpenTag,shouldDecodeNewlines:t.shouldDecodeNewlines,shouldDecodeNewlinesForHref:t.shouldDecodeNewlinesForHref,shouldKeepComment:t.comments,outputSourceRange:t.outputSourceRange,start:function(e,n,o,s,u){var p=a&&a.ns||Qr(e);Y&&"svg"===p&&(n=function(e){for(var t=[],n=0;nl&&(s.push(r=e.slice(l,a)),o.push(JSON.stringify(r)));var c=Li(i[1].trim());o.push("_s("+c+")"),s.push({"@binding":c}),l=a+i[0].length}return l-1"+("true"===r?":("+t+")":":_q("+t+","+r+")")),qi(e,"change","var $$a="+t+",$$el=$event.target,$$c=$$el.checked?("+r+"):("+o+");if(Array.isArray($$a)){var $$v="+(i?"_n("+a+")":a)+",$$i=_i($$a,$$v);if($$el.checked){$$i<0&&("+Gi(t,"$$a.concat([$$v])")+")}else{$$i>-1&&("+Gi(t,"$$a.slice(0,$$i).concat($$a.slice($$i+1))")+")}}else{"+Gi(t,"$$c")+"}",null,!0)}(e,i,a);else if("input"===r&&"radio"===o)!function(e,t,n){var i=n&&n.number,a=Hi(e,"value")||"null";Vi(e,"checked","_q("+t+","+(a=i?"_n("+a+")":a)+")"),qi(e,"change",Gi(t,a),null,!0)}(e,i,a);else if("input"===r||"textarea"===r)!function(e,t,n){var i=e.attrsMap.type;0;var a=n||{},r=a.lazy,o=a.number,s=a.trim,l=!r&&"range"!==i,c=r?"change":"range"===i?ta:"input",d="$event.target.value";s&&(d="$event.target.value.trim()");o&&(d="_n("+d+")");var u=Gi(t,d);l&&(u="if($event.target.composing)return;"+u);Vi(e,"value","("+t+")"),qi(e,c,u,null,!0),(s||o)&&qi(e,"blur","$forceUpdate()")}(e,i,a);else{if(!j.isReservedTag(r))return Wi(e,i,a),!1}return!0},text:function(e,t){t.value&&Vi(e,"textContent","_s("+t.value+")",t)},html:function(e,t){t.value&&Vi(e,"innerHTML","_s("+t.value+")",t)}},isPreTag:function(e){return"pre"===e},isUnaryTag:Sr,mustUseProp:Nn,canBeLeftOpenTag:Er,isReservedTag:ti,getTagNamespace:ni,staticKeys:function(e){return e.reduce((function(e,t){return e.concat(t.staticKeys||[])}),[]).join(",")}(Eo)},$o=_((function(e){return g("type,tag,attrsList,attrsMap,plain,parent,children,attrs,start,end,rawAttrsMap"+(e?","+e:""))}));function Oo(e,t){e&&(Mo=$o(t.staticKeys||""),zo=t.isReservedTag||L,Io(e),Lo(e,!1))}function Io(e){if(e.static=function(e){if(2===e.type)return!1;if(3===e.type)return!0;return!(!e.pre&&(e.hasBindings||e.if||e.for||v(e.tag)||!zo(e.tag)||function(e){for(;e.parent;){if("template"!==(e=e.parent).tag)return!1;if(e.for)return!0}return!1}(e)||!Object.keys(e).every(Mo)))}(e),1===e.type){if(!zo(e.tag)&&"slot"!==e.tag&&null==e.attrsMap["inline-template"])return;for(var t=0,n=e.children.length;t|^function(?:\s+[\w$]+)?\s*\(/,Po=/\([^)]*?\);*$/,Do=/^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['[^']*?']|\["[^"]*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*$/,Vo={esc:27,tab:9,enter:13,space:32,up:38,left:37,right:39,down:40,delete:[8,46]},Bo={esc:["Esc","Escape"],tab:"Tab",enter:"Enter",space:[" ","Spacebar"],up:["Up","ArrowUp"],left:["Left","ArrowLeft"],right:["Right","ArrowRight"],down:["Down","ArrowDown"],delete:["Backspace","Delete","Del"]},Fo=function(e){return"if("+e+")return null;"},No={stop:"$event.stopPropagation();",prevent:"$event.preventDefault();",self:Fo("$event.target !== $event.currentTarget"),ctrl:Fo("!$event.ctrlKey"),shift:Fo("!$event.shiftKey"),alt:Fo("!$event.altKey"),meta:Fo("!$event.metaKey"),left:Fo("'button' in $event && $event.button !== 0"),middle:Fo("'button' in $event && $event.button !== 1"),right:Fo("'button' in $event && $event.button !== 2")};function jo(e,t){var n=t?"nativeOn:":"on:",i="",a="";for(var r in e){var o=qo(e[r]);e[r]&&e[r].dynamic?a+=r+","+o+",":i+='"'+r+'":'+o+","}return i="{"+i.slice(0,-1)+"}",a?n+"_d("+i+",["+a.slice(0,-1)+"])":n+i}function qo(e){if(!e)return"function(){}";if(Array.isArray(e))return"["+e.map((function(e){return qo(e)})).join(",")+"]";var t=Do.test(e.value),n=To.test(e.value),i=Do.test(e.value.replace(Po,""));if(e.modifiers){var a="",r="",o=[];for(var s in e.modifiers)if(No[s])r+=No[s],Vo[s]&&o.push(s);else if("exact"===s){var l=e.modifiers;r+=Fo(["ctrl","shift","alt","meta"].filter((function(e){return!l[e]})).map((function(e){return"$event."+e+"Key"})).join("||"))}else o.push(s);return o.length&&(a+=function(e){return"if(!$event.type.indexOf('key')&&"+e.map(Ho).join("&&")+")return null;"}(o)),r&&(a+=r),"function($event){"+a+(t?"return "+e.value+"($event)":n?"return ("+e.value+")($event)":i?"return "+e.value:e.value)+"}"}return t||n?e.value:"function($event){"+(i?"return "+e.value:e.value)+"}"}function Ho(e){var t=parseInt(e,10);if(t)return"$event.keyCode!=="+t;var n=Vo[e],i=Bo[e];return"_k($event.keyCode,"+JSON.stringify(e)+","+JSON.stringify(n)+",$event.key,"+JSON.stringify(i)+")"}var Ro={on:function(e,t){e.wrapListeners=function(e){return"_g("+e+","+t.value+")"}},bind:function(e,t){e.wrapData=function(n){return"_b("+n+",'"+e.tag+"',"+t.value+","+(t.modifiers&&t.modifiers.prop?"true":"false")+(t.modifiers&&t.modifiers.sync?",true":"")+")"}},cloak:I},Uo=function(e){this.options=e,this.warn=e.warn||Pi,this.transforms=Di(e.modules,"transformCode"),this.dataGenFns=Di(e.modules,"genData"),this.directives=$($({},Ro),e.directives);var t=e.isReservedTag||L;this.maybeComponent=function(e){return!!e.component||!t(e.tag)},this.onceId=0,this.staticRenderFns=[],this.pre=!1};function Zo(e,t){var n=new Uo(t);return{render:"with(this){return "+(e?Wo(e,n):'_c("div")')+"}",staticRenderFns:n.staticRenderFns}}function Wo(e,t){if(e.parent&&(e.pre=e.pre||e.parent.pre),e.staticRoot&&!e.staticProcessed)return Go(e,t);if(e.once&&!e.onceProcessed)return Xo(e,t);if(e.for&&!e.forProcessed)return Yo(e,t);if(e.if&&!e.ifProcessed)return Ko(e,t);if("template"!==e.tag||e.slotTarget||t.pre){if("slot"===e.tag)return function(e,t){var n=e.slotName||'"default"',i=ns(e,t),a="_t("+n+(i?","+i:""),r=e.attrs||e.dynamicAttrs?rs((e.attrs||[]).concat(e.dynamicAttrs||[]).map((function(e){return{name:C(e.name),value:e.value,dynamic:e.dynamic}}))):null,o=e.attrsMap["v-bind"];!r&&!o||i||(a+=",null");r&&(a+=","+r);o&&(a+=(r?"":",null")+","+o);return a+")"}(e,t);var n;if(e.component)n=function(e,t,n){var i=t.inlineTemplate?null:ns(t,n,!0);return"_c("+e+","+Qo(t,n)+(i?","+i:"")+")"}(e.component,e,t);else{var i;(!e.plain||e.pre&&t.maybeComponent(e))&&(i=Qo(e,t));var a=e.inlineTemplate?null:ns(e,t,!0);n="_c('"+e.tag+"'"+(i?","+i:"")+(a?","+a:"")+")"}for(var r=0;r>>0}(o):"")+")"}(e,e.scopedSlots,t)+","),e.model&&(n+="model:{value:"+e.model.value+",callback:"+e.model.callback+",expression:"+e.model.expression+"},"),e.inlineTemplate){var r=function(e,t){var n=e.children[0];0;if(n&&1===n.type){var i=Zo(n,t.options);return"inlineTemplate:{render:function(){"+i.render+"},staticRenderFns:["+i.staticRenderFns.map((function(e){return"function(){"+e+"}"})).join(",")+"]}"}}(e,t);r&&(n+=r+",")}return n=n.replace(/,$/,"")+"}",e.dynamicAttrs&&(n="_b("+n+',"'+e.tag+'",'+rs(e.dynamicAttrs)+")"),e.wrapData&&(n=e.wrapData(n)),e.wrapListeners&&(n=e.wrapListeners(n)),n}function es(e){return 1===e.type&&("slot"===e.tag||e.children.some(es))}function ts(e,t){var n=e.attrsMap["slot-scope"];if(e.if&&!e.ifProcessed&&!n)return Ko(e,t,ts,"null");if(e.for&&!e.forProcessed)return Yo(e,t,ts);var i=e.slotScope===fo?"":String(e.slotScope),a="function("+i+"){return "+("template"===e.tag?e.if&&n?"("+e.if+")?"+(ns(e,t)||"undefined")+":undefined":ns(e,t)||"undefined":Wo(e,t))+"}",r=i?"":",proxy:true";return"{key:"+(e.slotTarget||'"default"')+",fn:"+a+r+"}"}function ns(e,t,n,i,a){var r=e.children;if(r.length){var o=r[0];if(1===r.length&&o.for&&"template"!==o.tag&&"slot"!==o.tag){var s=n?t.maybeComponent(o)?",1":",0":"";return""+(i||Wo)(o,t)+s}var l=n?function(e,t){for(var n=0,i=0;i':'
    ',ds.innerHTML.indexOf(" ")>0}var fs=!!G&&hs(!1),ms=!!G&&hs(!0),gs=_((function(e){var t=ri(e);return t&&t.innerHTML})),vs=$n.prototype.$mount;$n.prototype.$mount=function(e,t){if((e=e&&ri(e))===document.body||e===document.documentElement)return this;var n=this.$options;if(!n.render){var i=n.template;if(i)if("string"==typeof i)"#"===i.charAt(0)&&(i=gs(i));else{if(!i.nodeType)return this;i=i.innerHTML}else e&&(i=function(e){if(e.outerHTML)return e.outerHTML;var t=document.createElement("div");return t.appendChild(e.cloneNode(!0)),t.innerHTML}(e));if(i){0;var a=ps(i,{outputSourceRange:!1,shouldDecodeNewlines:fs,shouldDecodeNewlinesForHref:ms,delimiters:n.delimiters,comments:n.comments},this),r=a.render,o=a.staticRenderFns;n.render=r,n.staticRenderFns=o}}return vs.call(this,e,t)},$n.compile=ps;var bs=$n;const ys=()=>{window.Vue=bs,Vue.config.devtools=!1,Vue.config.productionTip=!1,Vue.directive("hit",{inserted(e,{value:t}){if(t&&"function"==typeof t){const n=e=>{t.length>0?t(e):t()};e.addEventListener("click",t),e.addEventListener("keydown",(e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),n(e))}))}}})}},5830:function(e,t,n){"use strict";n.d(t,{Z:function(){return k}});var i=n(6243),a=n(1906),r=n(2587);const o={name:"launchBar.plugin",displayName:"搜索栏 - 快捷键支持",setup:({addData:e})=>{e("keymap.actions",(e=>{e.showLaunchBar={displayName:"显示搜索栏",run:async()=>{const{toggleLaunchBar:e}=await Promise.resolve().then(n.bind(n,9931));return e(),!0}}})),e("keymap.presets",(e=>{e.showLaunchBar="/"}))}},s={name:"launchBar",displayName:"搜索栏",configurable:!1,entry:a.none,plugin:o,hidden:!0,tags:[r.t.general,r.t.utils],options:{searchHistory:{displayName:"搜索历史",defaultValue:[],hidden:!0}}};var l=n(5106),c=n(1993),d=n(3420);function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class p{constructor(){u(this,"accepts",(e=>e.nodeType===Node.ELEMENT_NODE)),u(this,"getValue",(e=>e.nodeValue)),u(this,"setValue",((e,t)=>{e.nodeValue=t})),u(this,"getElement",(e=>e))}translate(e){let t=this.getValue(e);if(!t||"string"!=typeof t||"*"===t)return;t=t.trim();const n=p.map.get(t);if(void 0===n){const n=p.regex.find((([e])=>e.test(t)));if(n){const[i,a]=n;this.setValue(e,t.replace(i,a))}}else if("string"==typeof n)this.setValue(e,n);else if(Array.isArray(n)){let t=null;for(const i of n)if("string"==typeof i)t=i;else{const{text:n,selector:a,not:r}=i;this.getElement(e)?.matches(a)!==Boolean(r)&&(t=n)}null!==t&&this.setValue(e,t)}else{const{text:t,selector:i,not:a}=n;this.getElement(e)?.matches(i)!==Boolean(a)&&this.setValue(e,t)}}static walk(e,t){const n=document.createNodeIterator(e,// eslint-disable-next-line no-bitwise -NodeFilter.SHOW_TEXT|NodeFilter.SHOW_ELEMENT);let i=n.nextNode();for(;i;)t(i),i=n.nextNode()}static translate(e){if(e.nodeType===Node.TEXT_NODE)return void p.textNode.translate(e);const t=e=>{for(const t of p.sensitiveTranslators)t.accepts(e)&&t.translate(e)};t(e),p.walk(e,t)}static translateCssMatches(){const e=p.map.get("*");if(e)for(const{selector:t,text:n}of e){const e=document.querySelector(t);e&&[...e.childNodes].filter((e=>e.nodeType===Node.TEXT_NODE)).forEach((e=>e.nodeValue=n))}}}u(p,"textNode",void 0),u(p,"title",void 0),u(p,"placeholder",void 0),u(p,"sensitiveTranslators",void 0),u(p,"map",void 0),u(p,"regex",void 0);p.textNode=new class extends p{constructor(...e){super(...e),u(this,"accepts",(e=>e.nodeType===Node.TEXT_NODE)),u(this,"getElement",(e=>e.parentElement))}},p.title=new class extends p{constructor(...e){super(...e),u(this,"getValue",(e=>e.getAttribute("title"))),u(this,"setValue",((e,t)=>{e.setAttribute("title",t)}))}},p.placeholder=new class extends p{constructor(...e){super(...e),u(this,"getValue",(e=>e.getAttribute("placeholder"))),u(this,"setValue",((e,t)=>{e.setAttribute("placeholder",t)}))}},p.sensitiveTranslators=[p.textNode,p.title,p.placeholder];const h={name:"i18n",displayName:"多语言",configurable:!1,entry:async()=>{const{getSelectedLanguage:e}=await Promise.resolve().then(n.bind(n,7365)),t=e();if(t===l.defaultLanguageCode)return;const{registerAndGetData:i}=await Promise.resolve().then(n.bind(n,950)),[a,r]=i(`i18n.${t}`,new Map,[]);console.log(t,a.size,r.length),0===a.size&&0===r.length||(document.documentElement.setAttribute("lang",t),p.map=a,p.regex=r,p.translate(document.body),p.translateCssMatches(),(0,d.allMutations)((e=>{e.forEach((e=>{"childList"===e.type?(e.addedNodes.length>0&&p.translateCssMatches(),e.addedNodes.forEach((e=>{p.translate(e)}))):"characterData"===e.type?p.textNode.translate(e.target):"attributes"===e.type&&("title"===e.attributeName?p.title.translate(e.target):"placeholder"===e.attributeName&&p.placeholder.translate(e.target))}))})))},tags:[r.t.utils,r.t.experimental,r.t.general],description:{"zh-CN":"安装其他语言包可以更换界面语言, 机器翻译选择可以设定其他一些功能如`动态翻译`, `评论翻译`使用的翻译器. 机器翻译的选择不影响界面语言."},options:{language:{defaultValue:l.languageCodeToName[l.defaultLanguageCode],displayName:"界面语言选择",dropdownEnum:l.languageCodeToName},translator:{defaultValue:Object.keys(c.WK)[0],displayName:"机器翻译选择",dropdownEnum:c.U6}}};var f=n(6171);const m=/^http:\/\/localhost/,g="autoUpdate",v=e=>m.test(e),b=async e=>{const{items:t,existPredicate:n,installer:i,filterNames:a=[],force:r=!1}=e,o=Number(new Date),{devMode:s}=(0,f.getGeneralSettings)(),{options:l}=(0,f.getComponentSettings)(g);Object.keys(t).filter((e=>!n(e))).forEach((e=>{delete t[e]}));return(await Promise.allSettled(Object.entries(t).filter((([e,t])=>(e=>0===a.length||a.includes(e))(e)&&Boolean(t.url))).map((async([e,n])=>{const{url:a,lastUpdateCheck:c,alwaysUpdate:d}=n;if(!(d&&s)&&o-c<=l.minimumDuration&&!r)return`[${e}] 未超过更新间隔期, 已跳过`;let u=a;m.test(a)&&l.localPortOverride&&(u=a.replace(/:(\d)+/,`:${l.localPortOverride}`));const p=await coreApis.ajax.monkey({url:u});if(!(e in t))return`[${e}] 已被卸载, 取消更新`;const{message:h}=await i(p);return n.lastUpdateCheck=Number(new Date),`[${e}] ${h}`})))).map(((e,n)=>{if("fulfilled"===e.status)return e.value;const i=e.reason?.message??e.reason.toString();return`[${Object.keys(t)[n]}] ${i}`})).join("\n").trim()},y=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{components:a}=i.urls,{installComponent:r}=await Promise.resolve().then(n.bind(n,7010));return b({items:a,existPredicate:e=>void 0!==f.settings.userComponents[e],installer:r,filterNames:e,force:t})},w=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{plugins:a}=i.urls,{installPlugin:r}=await Promise.resolve().then(n.bind(n,1623));return b({items:a,existPredicate:e=>void 0!==f.settings.userPlugins[e],installer:r,filterNames:e,force:t})},x=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{styles:a}=i.urls,{installStyle:r}=await Promise.resolve().then(n.bind(n,8900));return b({items:a,existPredicate:e=>void 0!==f.settings.userStyles[e],installer:r,filterNames:e,force:t})},_={name:g,displayName:"自动更新器",description:{"zh-CN":"自动检查组件, 插件和样式的更新. (仅限从设置面板中安装的)"},tags:[r.t.utils],options:{lastUpdateCheck:{displayName:"最后检查更新日期",defaultValue:0,hidden:!0},localPortOverride:{displayName:"本地组件链接端口",defaultValue:"",hidden:!0},minimumDuration:{displayName:"更新间隔 (ms)",defaultValue:864e5},urls:{displayName:"更新链接",defaultValue:{components:{},plugins:{},styles:{}},hidden:!0}},entry:async({settings:{options:e}})=>{const t=Number(new Date)-e.lastUpdateCheck,n=async()=>{console.log("[自动更新器] 开始检查更新"),console.log(await y()||"暂无组件更新"),console.log(await w()||"暂无插件更新"),console.log(await x()||"暂无样式更新"),e.lastUpdateCheck=Number(new Date),console.log("[自动更新器] 完成更新检查")};return t>=e.minimumDuration&&coreApis.lifeCycle.fullyLoaded(n),{checkUpdates:n,checkUpdatesAndReload:async()=>{await n(),window.location.reload()},updateSingleComponent:async(...e)=>{await y({filterNames:e,force:!0}),window.location.reload()},updateSinglePlugin:async(...e)=>{await w({filterNames:e,force:!0}),window.location.reload()},updateSingleStyle:async(...e)=>{await x({filterNames:e,force:!0}),window.location.reload()}}},plugin:{displayName:"自动更新器 - 扩展功能",description:{"zh-CN":"记录在设置面板中的功能安装/卸载数据供自动更新使用; 并在组件详情中支持手动检查该组件的更新."},setup:({addData:e,addHook:t})=>{["components","plugins","styles"].forEach((e=>{t(`user${lodash.startCase(e)}.add`,{after:(t,n,i)=>{const{options:a}=(0,f.getComponentSettings)("autoUpdate"),r=a.urls[e][i.name];r?(r.url=n,r.lastUpdateCheck=Number(new Date),r.alwaysUpdate=v(n)):a.urls[e][i.name]={url:n,lastUpdateCheck:Number(new Date),installTime:Number(new Date),alwaysUpdate:v(n)}}}),t(`user${lodash.startCase(e)}.remove`,{after:t=>{const{options:n}=(0,f.getComponentSettings)("autoUpdate");n.urls[e][t.name]&&delete n.urls[e][t.name]}})})),e("settingsPanel.componentActions",(e=>{const{options:t}=(0,f.getComponentSettings)("autoUpdate");e.push((e=>{const i=t.urls.components[e.name];if(i)return{name:"checkUpdate",displayName:"检查更新",icon:v(i.url)?"mdi-file-download-outline":"mdi-cloud-download-outline",condition:()=>(0,f.isUserComponent)(e),title:i.url,action:async()=>{const{Toast:t}=await Promise.resolve().then(n.bind(n,5683)),i=t.info("检查更新中...","检查更新"),a=await y({filterNames:[e.name],force:!0});i.message=a,i.duration=3e3}}}))}))}}},k=()=>[i.component,s,h,_]},8171:function(e,t,n){"use strict";n.r(t),n.d(t,{componentsMap:function(){return l},components:function(){return c},importComponent:function(){return f},loadComponent:function(){return m},loadAllUserComponents:function(){return g},loadAllComponents:function(){return v},componentsTags:function(){return s.t}});var i=n(6171),a=n(7177),r=n(4345),o=n(5830),s=n(2587);const l={},c=lodash.once((()=>{const e=(0,o.Z)();return e.forEach((e=>l[e.name]=e)),e}))(),d=async e=>{if(!e.i18n)return;const{addI18nData:t}=await Promise.resolve().then(n.bind(n,7365));Object.entries(e.i18n).forEach((([e,n])=>{const{map:i=[],regex:a=[]}=n;t(e,i,a)}))},u=e=>`${e.name}.widget`,p=async e=>{if(e.widget){const t={...e.widget,name:u(e)},{addData:i}=await Promise.resolve().then(n.bind(n,950)),{WidgetsPlugin:a}=await Promise.resolve().then(n.bind(n,6243));i(a,(n=>{if(n.find((e=>e.name===t.name)))return;const{urlInclude:i,urlExclude:a}=t;e.urlInclude&&(i?i.push(...e.urlInclude):t.urlInclude=[...e.urlInclude]),e.urlExclude&&(a?a.push(...e.urlExclude):t.urlExclude=[...e.urlExclude]),n.push(t)}))}},h={},f=e=>{if(!(e in h))throw new Error(`组件'${e}'未加载, 请确认拼写无误且组件已开启.`);return h[e]},m=async e=>{const{componentLoadTrace:t}=await Promise.resolve().then(n.bind(n,1485)),{matchUrlPattern:a}=await Promise.resolve().then(n.bind(n,1906)),{coreApis:r}=await Promise.resolve().then(n.bind(n,9388));await t(e);const o=async()=>{p(e);const t=await e.entry({settings:(0,i.getComponentSettings)(e),metadata:e,coreApis:r});h[e.name]=t||{}};e.reload&&e.unload&&(0,i.addComponentListener)(e.name,(async t=>{if(!1!==e.configurable&&!(e.urlExclude&&e.urlExclude.some(a)||e.urlInclude&&e.urlInclude.every(lodash.negate(a))))if(e.name in h){if(t&&e.reload&&(e.reload(),e.widget&&p(e)),!t&&e.unload&&(e.unload(),e.widget)){const{getData:t}=await Promise.resolve().then(n.bind(n,950)),{WidgetsPlugin:i}=await Promise.resolve().then(n.bind(n,6243)),[a]=t(i);if(a){const t=u(e),n=a.findIndex((e=>e.name===t));-1!==n&&a.splice(n,1)}}}else t&&await o()})),(0,i.isComponentEnabled)(e)&&await o()},g=async()=>{const{settings:e}=await Promise.resolve().then(n.bind(n,6171)),{batchParseCode:t}=await Promise.resolve().then(n.bind(n,7731));(await t(Object.values(e.userComponents).map((e=>e.code)))).forEach((e=>{c.push(e),l[e.name]=e}))},v=async()=>{const e=(0,i.getGeneralSettings)(),{loadAllPlugins:t}=await Promise.resolve().then(n.bind(n,1623)),o=()=>t(c).then((()=>Promise.allSettled(c.map(d)))).then((()=>Promise.allSettled(c.map(m)))).then((async()=>{if(e.devMode){const{componentLoadTime:e,componentResolveTime:t}=await Promise.resolve().then(n.bind(n,1485)),{logStats:i}=await Promise.resolve().then(n.bind(n,9476));i("components block",e),i("components resolve",t)}}));return new Promise((t=>{e.scriptLoadingMode===r.LoadingMode.Delay?(0,a.fullyLoaded)((()=>o().then(t))):e.scriptLoadingMode===r.LoadingMode.Race&&(0,a.contentLoaded)((()=>o().then(t)))}))}},5143:function(e,t,n){"use strict";n.r(t),n.d(t,{getDescriptionMarkdown:function(){return s},getDescriptionHTML:function(){return l},getDescriptionText:function(){return c}});var i=n(5106),a=n(7084),r=n.n(a),o=n(7365);const s=e=>{const{description:t,author:n}=e;return(n?Array.isArray(n)?`by ${n.map((e=>`[@${e.name}](${e.link})`)).join(",")}\n\n`:`by [@${n.name}](${n.link})\n\n`:"")+(t?"string"==typeof t?t:t[(0,i.languageNameToCode)((0,o.getSelectedLanguage)())]||t["zh-CN"]:"暂无描述.")},l=e=>r()(s(e)),c=e=>{const t=l(e),n=document.createElement("div");return n.innerHTML=t,n.innerText}},7365:function(e,t,n){"use strict";n.r(t),n.d(t,{addI18nData:function(){return o},getSelectedLanguage:function(){return s}});var i=n(950),a=n(6171),r=n(5106);const o=(e,t,n)=>{(0,i.addData)(`i18n.${e}`,((e,i)=>{t?.forEach((([t,n])=>e.set(t,n))),n&&i.push(...n)}))},s=()=>{const e=(0,a.getComponentSettings)("i18n");return(0,r.languageNameToCode)(e.options.language)}},1993:function(e,t,n){"use strict";n.d(t,{WK:function(){return p},U6:function(){return h},Ty:function(){return f}});var i=n(7195),a=n(2121),r=n(6171),o=n(5106),s=n(950),l=n(1906);function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class d{constructor(){c(this,"name",void 0),c(this,"link",void 0),c(this,"defaultLanguage",void 0)}getTargetLanguage(){const e=(0,r.getComponentSettings)("i18n");return e.enabled?(0,o.languageNameToCode)(e.options.language):this.defaultLanguage}toString(){return this.name}}class u extends d{constructor(...e){super(...e),c(this,"name","Google"),c(this,"link","https://translate.google.com/"),c(this,"defaultLanguage","zh"),c(this,"apiUrl","https://translate.google.com/translate_a/single")}async translate(e){let t=this.getTargetLanguage();t.includes("-")&&t!==this.defaultLanguage&&(t=t.substring(0,t.indexOf("-")));try{const n=await(0,i.monkey)({url:`${this.apiUrl}?${(0,l.formData)({client:"gtx",sl:"auto",tl:t,dt:"t",q:encodeURIComponent(e)})}`,method:"GET",headers:{"User-Agent":a.UserAgent},responseType:"json"});return n[0].map((e=>e[0])).join("")}catch(e){throw console.error("Translator: Google",e),new Error("调用Google翻译失败.")}}}const[p]=(0,s.registerAndGetData)("i18n.machineTranslators",{GoogleCN:new class extends u{constructor(...e){super(...e),c(this,"name","GoogleCN"),c(this,"link","https://translate.google.cn/"),c(this,"apiUrl","https://translate.google.cn/translate_a/single")}},Google:new u}),h=Object.keys(p),f=()=>{const{options:{translator:e}}=(0,r.getComponentSettings)("i18n");return p[e]||p.GoogleCN}},2168:function(e,t,n){"use strict";n.d(t,{WY:function(){return a},dr:function(){return r}});const i=(e="search_history")=>{const t=localStorage.getItem(e);return t?JSON.parse(t):[]},a=(e,t="search_history")=>{console.log("add",e),localStorage.setItem(t,JSON.stringify(lodash.sortBy(lodash.uniqBy([{value:e,isHistory:1,timestamp:Number(new Date)},...i()],(e=>e.value)),(e=>e.timestamp)).reverse().slice(0,12)))},r={name:"history",getActions:async()=>{const{search:e}=await Promise.resolve().then(n.bind(n,6674)),t={name:"清除搜索历史",icon:"mdi-trash-can-outline",description:"Clear History",explicitSelect:!0,action:()=>{((e="search_history")=>{localStorage.setItem(e,"[]")})()}},a=i().map((t=>({name:t.value,icon:"mdi-history",explicitSelect:!0,action:()=>{e(t.value)},deleteAction:()=>{((e,t="search_history")=>{const n=i(),a=n.findIndex((t=>t.value===e));console.log("delete",e,a),-1!==a&&(n.splice(a,1),localStorage.setItem(t,JSON.stringify(n)))})(t.value)}})));return a.length>0&&a.push(t),a}}},4247:function(e,t,n){"use strict";n.r(t),n.d(t,{LaunchBarActionProviders:function(){return i}});const i="launchBar.actions"},6674:function(e,t,n){"use strict";n.r(t),n.d(t,{search:function(){return o},searchProvider:function(){return s}});var i=n(1906),a=n(7195),r=n(2168);const o=e=>{if(!e)return;(0,r.WY)(e);const t={keyword:e,from_source:"nav_suggest_new"};window.open(`https://search.bilibili.com/all?${(0,i.formData)(t)}`,"_blank")},s={name:"search",getActions:async e=>{const t=`https://s.search.bilibili.com/main/suggest?func=suggest&suggest_type=accurate&sub_type=tag&main_ver=v1&highlight=&userid=${(0,i.getUID)()}&bangumi_acc_num=1&special_acc_num=1&topic_acc_num=1&upuser_acc_num=3&tag_num=10&special_num=10&bangumi_num=10&upuser_num=3&term=${e}`,n=await(0,a.getJson)(t);if(0!==n.code)return[];const r=lodash.get(n,"result.tag");return r?r.map((e=>({name:e.value,explicitSelect:!0,icon:"search",content:async()=>Vue.extend({render:t=>t("div",{domProps:{innerHTML:e.name.replace(/suggest_high_light/g,"suggest-highlight")}})}),action:()=>o(e.value)}))):[]}}},9931:function(e,t,n){"use strict";n.r(t),n.d(t,{toggleLaunchBar:function(){return g}});var i=n(1906),a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("VPopup",{staticClass:"global-launch-bar-container",attrs:{lazy:!1,fixed:""},on:{"!keydown":function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"esc",27,t.key,["Esc","Escape"])?null:e.close()}},model:{value:e.show,callback:function(t){e.show=t},expression:"show"}},[n("LaunchBar",{ref:"launchBar"})],1)};a._withStripped=!0;var r=n(7553),o=n(3059),s=Vue.extend({components:{LaunchBar:o.Z,VPopup:r.default},data:()=>({show:!0}),watch:{show(e){e&&this.focus()}},async mounted(){await this.$nextTick(),this.focus()},methods:{focus(){const e=this.$refs.launchBar?.$refs.input;e?.focus(),e?.select()},close(){this.show=!1;this.$refs.launchBar?.$refs.input?.blur()}}}),l=n(3379),c=n.n(l),d=n(5584),u=n.n(d),p={insert:"head",singleton:!1},h=(c()(u(),p),u().locals,(0,n(1900).Z)(s,a,[],!1,null,null,null));h.options.__file="src/components/launch-bar/GlobalLaunchBar.vue";var f=h.exports;let m;const g=()=>{if(!m)return m=(0,i.mountVueComponent)(f),void document.body.append(m.$el);m.show=!m.show}},6243:function(e,t,n){"use strict";n.r(t),n.d(t,{SettingsPanelDockSide:function(){return h},WidgetsPlugin:function(){return p},component:function(){return f}});var i=n(1906),a=n(4345),r=n(6314),o=n(2462),s=n(6171),l=n(5300),c=n(2587),d=n(950),u=n(4247);const p="widgets";let h;!function(e){e.Left="左侧",e.Right="右侧"}(h||(h={}));const f={name:"settingsPanel",displayName:"通用设置",configurable:!1,entry:async({metadata:e})=>{const{isIframe:t}=await Promise.resolve().then(n.bind(n,1906));t()||((0,s.addComponentListener)(`${e.name}.dockSide`,(e=>{document.body.classList.toggle("settings-panel-dock-right",e===h.Right)}),!0),requestIdleCallback((async()=>{const e=await Promise.resolve().then(n.bind(n,5863)),t=(0,i.mountVueComponent)(e);document.body.insertAdjacentElement("beforeend",t.$el)})))},options:{themeColor:{defaultValue:"#00A0D8",displayName:"主题颜色",color:!0},scriptLoadingMode:{defaultValue:a.LoadingMode.Delay,displayName:"功能加载模式",dropdownEnum:a.LoadingMode},styleLoadingMode:{defaultValue:a.LoadingMode.Race,displayName:"样式加载模式",dropdownEnum:a.LoadingMode},textColor:{defaultValue:r.TextColor.Auto,displayName:"文本颜色",dropdownEnum:r.TextColor},cdnRoot:{defaultValue:o.CdnTypes.jsDelivr,displayName:"更新源",dropdownEnum:o.CdnTypes},dockSide:{defaultValue:h.Left,displayName:"设置面板停靠",dropdownEnum:h},filenameFormat:{defaultValue:"[title][ - ep]",displayName:"文件命名格式"},batchFilenameFormat:{defaultValue:"[n - ][ep]",displayName:"批量命名格式"},downloadPackageEmitMode:{defaultValue:l.h.packed,displayName:"文件下载模式",dropdownEnum:l.h},devMode:{defaultValue:!1,displayName:"开发者模式"}},tags:[c.t.general],i18n:{"en-US":{map:[["通用设置","General"],["实验性","Experimental"],["通用","General"],["开发者模式","Dev mode"],["辅助颜色","Accent color"],["功能加载模式","Script loading mode"],["样式加载模式","Style loading mode"]]}},plugin:{displayName:"设置面板 - 功能扩展",setup:()=>{(0,d.addData)(u.LaunchBarActionProviders,(e=>{e.push({name:"onlineRegistry",getActions:async()=>[{name:"切换在线仓库",description:"Toggle Online Registry",icon:"mdi-web",action:async()=>{const{togglePopup:e}=await Promise.resolve().then(n.bind(n,7503));e()}}]})}))}}}},5858:function(e,t,n){"use strict";n.d(t,{U:function(){return a},B:function(){return r}});var i=n(6171);const a=Vue.extend({props:{componentData:{type:Object,required:!0}},data(){return{settings:(0,i.getComponentSettings)(this.componentData)}}}),r=e=>Vue.extend({data:()=>({virtual:!1}),async mounted(){const{dq:t}=await Promise.resolve().then(n.bind(n,1906)),{visibleInside:i}=await Promise.resolve().then(n.bind(n,3420)),a=this.$el,r=t(e);r?i(a,r,"150% 0px",(e=>{e.forEach((e=>{this.virtual=!e.isIntersecting}))})):console.warn("virtual container not found, virtual scroll will be disabled!")}})},7503:function(e,t,n){"use strict";n.r(t),n.d(t,{initPopup:function(){return P},togglePopup:function(){return D}});var i=n(1906),a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("VPopup",{staticClass:"online-registry",attrs:{fixed:"","auto-close":!1},model:{value:e.popupOpen,callback:function(t){e.popupOpen=t},expression:"popupOpen"}},[n("div",{staticClass:"online-registry-header"},[n("VIcon",{staticClass:"online-registry-header-title-icon",attrs:{icon:"mdi-web"}}),e._v(" "),n("div",{staticClass:"online-registry-header-title"},[e._v("\n 在线仓库\n ")]),e._v(" "),n("div",{staticClass:"online-registry-header-search"},[n("VIcon",{attrs:{icon:"search",size:18}}),e._v(" "),n("TextBox",{attrs:{placeholder:"搜索功能"},model:{value:e.searchKeyword,callback:function(t){e.searchKeyword=t},expression:"searchKeyword"}})],1),e._v(" "),n("VIcon",{staticClass:"online-registry-header-refresh-icon",attrs:{icon:"mdi-refresh",size:22,title:"刷新"},on:{click:function(t){return e.fetchFeatures()}}}),e._v(" "),n("VIcon",{staticClass:"online-registry-header-close-icon",attrs:{icon:"close",size:18,title:"关闭"},on:{click:function(t){e.popupOpen=!1}}})],1),e._v(" "),n("div",{staticClass:"online-registry-separator"}),e._v(" "),n("div",{ref:"content",staticClass:"online-registry-content"},[e.loading?n("VLoading"):e._e(),e._v(" "),e.loading||e.list.length?e._e():n("VEmpty"),e._v(" "),e._l(e.filteredList,(function(e){return n("RegistryItem",{key:e.name,attrs:{item:e}})}))],2)])};a._withStripped=!0;var r=n(7195),o=n(2462),s=n(1836),l=n(6171),c=n(2264),d=n(3923),u=n(125),p=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("MiniToast",{staticClass:"online-registry-item-wrapper",class:{virtual:e.virtual},attrs:{placement:"right",container:"body",delay:[200,0],offset:[0,12]},scopedSlots:e._u([{key:"toast",fn:function(){return[e.description?n("div",{staticClass:"online-registry-description",domProps:{innerHTML:e._s(e.description)}}):e._e()]},proxy:!0}])},[e.virtual?e._e():n("div",{staticClass:"online-registry-item"},[n("VIcon",{staticClass:"item-icon",attrs:{size:18,icon:e.icon}}),e._v(" "),n("div",{staticClass:"item-badge"},[e._v("\n "+e._s(e.badge)+"\n ")]),e._v(" "),n("div",{staticClass:"item-display-name"},[e._v("\n "+e._s(e.item.displayName)+"\n ")]),e._v(" "),n("div",{staticClass:"grow"}),e._v(" "),n("div",{staticClass:"item-action"},[e.installed?n("VButton",{staticClass:"reinstall-button",attrs:{title:"重新安装",disabled:e.installing},on:{click:function(t){e.install(e.getUrl(e.item))}}},[e._v("\n "+e._s(e.installing?"正在安装":"已安装")+"\n ")]):n("VButton",{staticClass:"install-button",attrs:{title:"安装",type:"primary",disabled:e.installing},on:{click:function(t){e.install(e.getUrl(e.item))}}},[n("VIcon",{attrs:{icon:"mdi-plus",size:15}}),e._v("\n "+e._s(e.installing?"正在安装":"安装")+"\n ")],1)],1)],1)])};p._withStripped=!0;var h=n(5143),f=n(9513),m=n(3420);const g=e=>`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch,e.owner)}${e.fullAbsolutePath}`,v=e=>{const t=`user${lodash.startCase(e.type)}s`;return e.name in l.settings[t]},b={component:{icon:"mdi-cube-scan",badge:"组件",getUrl:g,isInstalled:v},plugin:{icon:"mdi-puzzle-outline",badge:"插件",getUrl:g,isInstalled:v},style:{icon:"mdi-tune",badge:"样式",getUrl:g,isInstalled:v},pack:{icon:"mdi-package-variant-closed",badge:"合集包",getUrl:e=>e.items.map(g).join("\n"),isInstalled:e=>e.items.every(v)}};var y=Vue.extend({components:{VIcon:d.VIcon,VButton:d.VButton,MiniToast:d.MiniToast},props:{item:{type:Object,required:!0}},data(){return{typeMappings:b,...b[this.item.type],description:(0,h.getDescriptionHTML)(this.item),installing:!1,installed:!1,virtual:!1}},created(){this.checkInstalled()},mounted(){const e=this.$el;(0,m.visibleInside)(e,e.parentElement,"150% 0px",(e=>{e.forEach((e=>{this.virtual=!e.isIntersecting}))}))},methods:{checkInstalled(){this.installed=this.isInstalled(this.item)},async install(e){const t=e.split("\n").map((e=>e.trim())).filter((e=>""!==e));try{this.installing=!0,await Promise.all(t.map((async e=>(0,f.m)(e)))),this.checkInstalled()}catch(e){(0,c.logError)(e)}finally{this.installing=!1}}}}),w=n(3379),x=n.n(w),_=n(3947),k=n.n(_),C={insert:"head",singleton:!1},S=(x()(k(),C),k().locals,n(1900)),E=(0,S.Z)(y,p,[],!1,null,null,null);E.options.__file="src/components/settings-panel/sub-pages/online-registry/RegistryItem.vue";var M=E.exports,z=Vue.extend({components:{VIcon:d.VIcon,TextBox:d.TextBox,VPopup:d.VPopup,RegistryItem:M,VLoading:d.VLoading,VEmpty:d.VEmpty},props:{open:{default:!1,type:Boolean}},data:()=>({searchKeyword:"",popupOpen:!1,loading:!1,list:[],filteredList:[],fuse:null}),watch:{searchKeyword:lodash.debounce((function(e){if(!e)return void(this.filteredList=this.list);const t=this.fuse.search(e);this.filteredList=t.map((e=>e.item)),this.$nextTick().then((()=>this.$refs.content.scrollTo(0,0)))}),200)},mounted(){this.fetchFeatures()},methods:{async fetchFeatures(){if(!this.loading)try{this.loading=!0;const e=`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch)}doc/features/features.json`,t=`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch)}doc/features/pack/pack.json`,n=await(0,r.monkey)({url:e,responseType:"json"}),i=await(0,r.monkey)({url:t,responseType:"json"});this.list=[...i,...n],this.fuse=new u.Z(this.list,{keys:["displayName","name","description"]}),this.searchKeyword="",this.filteredList=[...this.list]}catch(e){(0,c.logError)(e)}finally{this.loading=!1}}}}),A=n(8959),$=n.n(A),O={insert:"head",singleton:!1},I=(x()($(),O),$().locals,(0,S.Z)(z,a,[],!1,null,null,null));I.options.__file="src/components/settings-panel/sub-pages/online-registry/OnlineRegistry.vue";var L=I.exports;let T;const P=()=>{T||(T=(0,i.mountVueComponent)(L),document.body.append(T.$el))},D=()=>{T||P(),T.popupOpen=!T.popupOpen}},2587:function(e,t,n){"use strict";n.d(t,{t:function(){return i}});const i={video:{name:"video",displayName:"视频",color:"#2196F3",icon:"mdi-play-circle-outline",order:1},style:{name:"style",displayName:"样式",color:"#8BC34A",icon:"mdi-palette-outline",order:2},feeds:{name:"feeds",displayName:"动态",color:"#00ACC1",icon:"mdi-pinwheel-outline",order:3},live:{name:"live",displayName:"直播",color:"#26A69A",icon:"mdi-video-wireless-outline",order:4},utils:{name:"utils",displayName:"工具",color:"#A36FFD",icon:"mdi-rocket-launch-outline",order:5},touch:{name:"touch",displayName:"触摸",color:"#78909C",icon:"mdi-gesture-tap-button",order:6},experimental:{name:"experimental",displayName:"实验",color:"#FF5722",icon:"mdi-flask-outline",order:7},general:{name:"general",displayName:"通用",color:"#888",icon:"mdi-progress-wrench",order:8}}},7010:function(e,t,n){"use strict";n.r(t),n.d(t,{installComponent:function(){return o},uninstallComponent:function(){return s},toggleComponent:function(){return l}});var i=n(6171),a=n(5830),r=n(8171);const o=async e=>{const{components:t}=await Promise.resolve().then(n.bind(n,8171)),{parseExternalInput:o}=await Promise.resolve().then(n.bind(n,7731)),s=await o(e);if(null===s)throw new Error("无效的组件代码");const{settings:l}=await Promise.resolve().then(n.bind(n,6171));if((0,a.Z)().some((e=>e.name===s.name)))throw new Error(`不能覆盖内置组件'${s.name}', 请更换名称`);const c={...lodash.omit(s,"entry","widget","instantStyles","reload","unload","plugin","urlInclude","urlExclude")},d=l.userComponents[s.name];return d?(d.code=e,d.metadata=c,d.settings=lodash.defaultsDeep(d.settings,(0,i.componentToSettings)(s)),{metadata:s,message:`已更新组件'${s.displayName}', 刷新后生效`}):(l.userComponents[s.name]={code:e,metadata:c,settings:(0,i.componentToSettings)(s)},t.push(s),r.componentsMap[s.name]=s,{metadata:s,message:`已安装组件'${s.displayName}', 刷新后生效`})},s=async e=>{const{settings:t}=await Promise.resolve().then(n.bind(n,6171)),{components:i}=await Promise.resolve().then(n.bind(n,8171)),a=Object.entries(t.userComponents).find((([t,{metadata:{displayName:n}}])=>t===e||n===e));if(!a)throw new Error(`没有找到与名称'${e}'相关联的组件`);const[o,{metadata:s,settings:l}]=a,c=i.findIndex((e=>e.name===o));if(-1!==c){const{instantStyles:e}=i[c];if(e){const{removeStyle:t}=await Promise.resolve().then(n.bind(n,6182));e.forEach((e=>t(e.name)))}l.enabled=!1,i.splice(c,1),delete r.componentsMap[o]}return delete t.userComponents[o],{metadata:s,message:`已卸载组件'${s.displayName}, 刷新后生效'`}},l=async e=>{const{settings:t}=await Promise.resolve().then(n.bind(n,6171)),i=Object.entries(t.userComponents).find((([t,{metadata:{displayName:n}}])=>t===e||n===e));if(!i)throw new Error(`没有找到与名称'${e}'相关联的组件`);const[,a]=i;a.settings.enabled=!a.settings.enabled;const{enabled:r}=a.settings,{displayName:o}=a.metadata;return`已${r?"开启":"关闭"}组件'${o}', 可能需要刷新后才能生效`}},2149:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{updateCategories:function(){return updateCategories},updateIcons:function(){return updateIcons}});var _core_ajax__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(7195),_core_download__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(4114);const updateCategories=async()=>{const[script]=dqa("script").filter((e=>e.src.includes("international-home/international-home")));if(!script)throw new Error("no script found");const scriptText=await(0,_core_ajax__WEBPACK_IMPORTED_MODULE_1__.getText)(script.src),match=scriptText.match(/([\w]+?=\[\{name:"首页".+?\}.+?\]),[\w]+?=\[\{name:"首頁"/);if(!match)throw new Error("no match in script");const variables=match[1].match(/(\w+?)(?==\[)/g),data=eval(`var ${match[1]}; [${variables.join(",")}]`);_core_download__WEBPACK_IMPORTED_MODULE_0__.DownloadPackage.single("raw.json",data)},updateIcons=()=>{const e=dqa("body > svg:not(#be-category-icons)").filter((e=>e.querySelector("[id^=bili]")));if(0===e.length)throw new Error("svg icons not found");const[t]=e,n=t.cloneNode(!0);n.id="be-category-icons",dqa(n,"symbol").forEach((e=>{e.id=e.id.replace(/^bili-/,"header-icon-")})),_core_download__WEBPACK_IMPORTED_MODULE_0__.DownloadPackage.single("icons.svg",n.outerHTML)}},6958:function(e,t,n){"use strict";n.r(t),n.d(t,{bpxPlayerPolyfill:function(){return o}});var i=n(3420),a=n(5550),r=n(1906);const o=lodash.once((async()=>{document.URL.startsWith("https://www.bilibili.com/bangumi/play/")&&((async()=>{const e=await(0,a.select)(".bpx-player-container");e?(0,i.attributes)(e,(()=>{const t=e.getAttribute("data-screen");document.body.classList.toggle("player-mode-webfullscreen","full"===t||"web"===t),"wide"===t&&document.body.classList.add("player-mode-widescreen")})):console.warn("[bpx player polyfill] bpxContainer not found")})(),(async()=>{const e=await(0,a.select)((()=>unsafeWindow.$pbp));if(!e)return void console.warn("[bpx player polyfill] pbp not found");const t={aid:e.options.aid.toString(),cid:e.options.cid.toString(),bvid:e.options.bvid};Object.values(t).some((e=>""===e||parseInt(e)<=0))&&console.warn("[bpx player polyfill] invalid pbp data"),Object.assign(unsafeWindow,t)})(),(async()=>{const e=await(0,a.select)(".bpx-player-video-perch");e&&(0,r.preventEvent)(e,"dblclick")})())}))},7412:function(e,t,n){"use strict";n.r(t),n.d(t,{PlayerAgent:function(){return u},VideoPlayerAgent:function(){return p},BwpPlayerAgent:function(){return h},BangumiPlayerAgent:function(){return f},playerAgent:function(){return m}});var i=n(5550),a=n(1906),r=n(7735),o=n(6958);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const l=e=>{const t=()=>(0,i.select)(e);return t.selector=e,t.sync=()=>dq(e),t},c=e=>{const t=e=>"string"!=typeof e?lodash.mapValues(e,t):l(e);return lodash.mapValues(e,t)},d=e=>{const t=e.sync();return t?.click(),t};class u{constructor(){s(this,"type",void 0),s(this,"query",void 0)}provideCustomQuery(e){const t=c(e[this.type]??e.video);return{...this,custom:t}}widescreen(){return d(this.query.control.buttons.widescreen)}webFullscreen(){return d(this.query.control.buttons.webFullscreen)}fullscreen(){return d(this.query.control.buttons.fullscreen)}togglePlay(){return d(this.query.control.buttons.start)}togglePip(){return d(this.query.control.buttons.pip)}toggleMute(){return d(this.query.control.buttons.volume)}toggleDanmaku(){const e=this.query.danmakuSwitch.sync();return e?(e.checked=!e.checked,(0,a.raiseEvent)(e,"change"),e.checked):null}}class p extends u{constructor(...e){super(...e),s(this,"type","video"),s(this,"query",c({playerWrap:".player-wrap",bilibiliPlayer:".bilibili-player",playerArea:".bilibili-player-area",video:{element:".bilibili-player-video video",wrap:".bilibili-player-video-wrap",top:".bilibili-player-video-top",state:".bilibili-player-video-state",panel:".bilibili-player-video-panel",popup:".bilibili-player-video-popup",subtitle:".bilibili-player-video-subtitle",basDanmaku:".bilibili-player-video-bas-danmaku",advDanmaku:".bilibili-player-video-adv-danmaku",danmaku:".bilibili-player-video-danmaku",container:".bilibili-player-video"},control:{element:".bilibili-player-control",wrap:".bilibili-player-control-wrap",mask:".bilibili-player-control-mask",top:".bilibili-player-control-top",progress:".bilibili-player-video-progress",bottom:".bilibili-player-control-bottom",bottomLeft:".bilibili-player-control-bottom-left",bottomCenter:".bilibili-player-control-bottom-center",bottomRight:".bilibili-player-control-bottom-right",buttons:{start:".bilibili-player-video-btn-start",next:".bilibili-player-video-btn-next",time:".bilibili-player-video-time",quality:".bilibili-player-btn-quality",pageList:".bilibili-player-video-btn-pagelist",speed:".bilibili-player-video-btn-speed",subtitle:".bilibili-player-video-btn-subtitle",volume:".bilibili-player-video-btn-volume .bilibili-player-iconfont-volume",settings:".bilibili-player-video-btn-setting",pip:".bilibili-player-video-btn-pip",widescreen:".bilibili-player-video-btn-widescreen",webFullscreen:".bilibili-player-video-web-fullscreen",fullscreen:".bilibili-player-video-btn-fullscreen"}},toastWrap:".bilibili-player-video-toast-wrp",danmakuTipLayer:".bilibili-player-dm-tip-wrap",danmakuSwitch:".bilibili-player-video-danmaku-switch input"}))} +NodeFilter.SHOW_TEXT|NodeFilter.SHOW_ELEMENT);let i=n.nextNode();for(;i;)t(i),i=n.nextNode()}static translate(e){if(e.nodeType===Node.TEXT_NODE)return void p.textNode.translate(e);const t=e=>{for(const t of p.sensitiveTranslators)t.accepts(e)&&t.translate(e)};t(e),p.walk(e,t)}static translateCssMatches(){const e=p.map.get("*");if(e)for(const{selector:t,text:n}of e){const e=document.querySelector(t);e&&[...e.childNodes].filter((e=>e.nodeType===Node.TEXT_NODE)).forEach((e=>e.nodeValue=n))}}}u(p,"textNode",void 0),u(p,"title",void 0),u(p,"placeholder",void 0),u(p,"sensitiveTranslators",void 0),u(p,"map",void 0),u(p,"regex",void 0);p.textNode=new class extends p{constructor(...e){super(...e),u(this,"accepts",(e=>e.nodeType===Node.TEXT_NODE)),u(this,"getElement",(e=>e.parentElement))}},p.title=new class extends p{constructor(...e){super(...e),u(this,"getValue",(e=>e.getAttribute("title"))),u(this,"setValue",((e,t)=>{e.setAttribute("title",t)}))}},p.placeholder=new class extends p{constructor(...e){super(...e),u(this,"getValue",(e=>e.getAttribute("placeholder"))),u(this,"setValue",((e,t)=>{e.setAttribute("placeholder",t)}))}},p.sensitiveTranslators=[p.textNode,p.title,p.placeholder];const h={name:"i18n",displayName:"多语言",configurable:!1,entry:async()=>{const{getSelectedLanguage:e}=await Promise.resolve().then(n.bind(n,7365)),t=e();if(t===l.defaultLanguageCode)return;const{registerAndGetData:i}=await Promise.resolve().then(n.bind(n,950)),[a,r]=i(`i18n.${t}`,new Map,[]);console.log(t,a.size,r.length),0===a.size&&0===r.length||(document.documentElement.setAttribute("lang",t),p.map=a,p.regex=r,p.translate(document.body),p.translateCssMatches(),(0,d.allMutations)((e=>{e.forEach((e=>{"childList"===e.type?(e.addedNodes.length>0&&p.translateCssMatches(),e.addedNodes.forEach((e=>{p.translate(e)}))):"characterData"===e.type?p.textNode.translate(e.target):"attributes"===e.type&&("title"===e.attributeName?p.title.translate(e.target):"placeholder"===e.attributeName&&p.placeholder.translate(e.target))}))})))},tags:[r.t.utils,r.t.experimental,r.t.general],description:{"zh-CN":"安装其他语言包可以更换界面语言, 机器翻译选择可以设定其他一些功能如`动态翻译`, `评论翻译`使用的翻译器. 机器翻译的选择不影响界面语言."},options:{language:{defaultValue:l.languageCodeToName[l.defaultLanguageCode],displayName:"界面语言选择",dropdownEnum:l.languageCodeToName},translator:{defaultValue:Object.keys(c.WK)[0],displayName:"机器翻译选择",dropdownEnum:c.U6}}};var f=n(6171);const m=/^http:\/\/localhost/,g="autoUpdate",v=e=>m.test(e),b=async e=>{const{items:t,existPredicate:n,installer:i,filterNames:a=[],force:r=!1}=e,o=Number(new Date),{devMode:s}=(0,f.getGeneralSettings)(),{options:l}=(0,f.getComponentSettings)(g);Object.keys(t).filter((e=>!n(e))).forEach((e=>{delete t[e]}));return(await Promise.allSettled(Object.entries(t).filter((([e,t])=>(e=>0===a.length||a.includes(e))(e)&&Boolean(t.url))).map((async([e,n])=>{const{url:a,lastUpdateCheck:c,alwaysUpdate:d}=n;if(!(d&&s)&&o-c<=l.minimumDuration&&!r)return`[${e}] 未超过更新间隔期, 已跳过`;let u=a;m.test(a)&&l.localPortOverride&&(u=a.replace(/:(\d)+/,`:${l.localPortOverride}`));const p=await coreApis.ajax.monkey({url:u});if(!(e in t))return`[${e}] 已被卸载, 取消更新`;const{message:h}=await i(p);return n.lastUpdateCheck=Number(new Date),`[${e}] ${h}`})))).map(((e,n)=>{if("fulfilled"===e.status)return e.value;const i=e.reason?.message??e.reason.toString();return`[${Object.keys(t)[n]}] ${i}`})).join("\n").trim()},y=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{components:a}=i.urls,{installComponent:r}=await Promise.resolve().then(n.bind(n,7010));return b({items:a,existPredicate:e=>void 0!==f.settings.userComponents[e],installer:r,filterNames:e,force:t})},w=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{plugins:a}=i.urls,{installPlugin:r}=await Promise.resolve().then(n.bind(n,1623));return b({items:a,existPredicate:e=>void 0!==f.settings.userPlugins[e],installer:r,filterNames:e,force:t})},x=async({filterNames:e,force:t}={})=>{const{options:i}=(0,f.getComponentSettings)(g),{styles:a}=i.urls,{installStyle:r}=await Promise.resolve().then(n.bind(n,8900));return b({items:a,existPredicate:e=>void 0!==f.settings.userStyles[e],installer:r,filterNames:e,force:t})},_={name:g,displayName:"自动更新器",description:{"zh-CN":"自动检查组件, 插件和样式的更新. (仅限从设置面板中安装的)"},tags:[r.t.utils],options:{lastUpdateCheck:{displayName:"最后检查更新日期",defaultValue:0,hidden:!0},localPortOverride:{displayName:"本地组件链接端口",defaultValue:"",hidden:!0},minimumDuration:{displayName:"更新间隔 (ms)",defaultValue:864e5},urls:{displayName:"更新链接",defaultValue:{components:{},plugins:{},styles:{}},hidden:!0}},entry:async({settings:{options:e}})=>{const t=Number(new Date)-e.lastUpdateCheck,n=async()=>{console.log("[自动更新器] 开始检查更新"),console.log(await y()||"暂无组件更新"),console.log(await w()||"暂无插件更新"),console.log(await x()||"暂无样式更新"),e.lastUpdateCheck=Number(new Date),console.log("[自动更新器] 完成更新检查")};return t>=e.minimumDuration&&coreApis.lifeCycle.fullyLoaded(n),{checkUpdates:n,checkUpdatesAndReload:async()=>{await n(),window.location.reload()},updateSingleComponent:async(...e)=>{await y({filterNames:e,force:!0}),window.location.reload()},updateSinglePlugin:async(...e)=>{await w({filterNames:e,force:!0}),window.location.reload()},updateSingleStyle:async(...e)=>{await x({filterNames:e,force:!0}),window.location.reload()}}},plugin:{displayName:"自动更新器 - 扩展功能",description:{"zh-CN":"记录在设置面板中的功能安装/卸载数据供自动更新使用; 并在组件详情中支持手动检查该组件的更新."},setup:({addData:e,addHook:t})=>{["components","plugins","styles"].forEach((e=>{t(`user${lodash.startCase(e)}.add`,{after:(t,n,i)=>{const{options:a}=(0,f.getComponentSettings)("autoUpdate"),r=a.urls[e][i.name];r?(r.url=n,r.lastUpdateCheck=Number(new Date),r.alwaysUpdate=v(n)):a.urls[e][i.name]={url:n,lastUpdateCheck:Number(new Date),installTime:Number(new Date),alwaysUpdate:v(n)}}}),t(`user${lodash.startCase(e)}.remove`,{after:t=>{const{options:n}=(0,f.getComponentSettings)("autoUpdate");n.urls[e][t.name]&&delete n.urls[e][t.name]}})})),e("settingsPanel.componentActions",(e=>{const{options:t}=(0,f.getComponentSettings)("autoUpdate");e.push((e=>{const i=t.urls.components[e.name];if(i)return{name:"checkUpdate",displayName:"检查更新",icon:v(i.url)?"mdi-file-download-outline":"mdi-cloud-download-outline",condition:()=>(0,f.isUserComponent)(e),title:i.url,action:async()=>{const{Toast:t}=await Promise.resolve().then(n.bind(n,5683)),i=t.info("检查更新中...","检查更新"),a=await y({filterNames:[e.name],force:!0});i.message=a,i.duration=3e3}}}))}))}}},k=()=>[i.component,s,h,_]},8171:function(e,t,n){"use strict";n.r(t),n.d(t,{componentsMap:function(){return l},components:function(){return c},importComponent:function(){return f},loadComponent:function(){return m},loadAllUserComponents:function(){return g},loadAllComponents:function(){return v},componentsTags:function(){return s.t}});var i=n(6171),a=n(7177),r=n(4345),o=n(5830),s=n(2587);const l={},c=lodash.once((()=>{const e=(0,o.Z)();return e.forEach((e=>l[e.name]=e)),e}))(),d=async e=>{if(!e.i18n)return;const{addI18nData:t}=await Promise.resolve().then(n.bind(n,7365));Object.entries(e.i18n).forEach((([e,n])=>{const{map:i=[],regex:a=[]}=n;t(e,i,a)}))},u=e=>`${e.name}.widget`,p=async e=>{if(e.widget){const t={...e.widget,name:u(e)},{addData:i}=await Promise.resolve().then(n.bind(n,950)),{WidgetsPlugin:a}=await Promise.resolve().then(n.bind(n,6243));i(a,(n=>{if(n.find((e=>e.name===t.name)))return;const{urlInclude:i,urlExclude:a}=t;e.urlInclude&&(i?i.push(...e.urlInclude):t.urlInclude=[...e.urlInclude]),e.urlExclude&&(a?a.push(...e.urlExclude):t.urlExclude=[...e.urlExclude]),n.push(t)}))}},h={},f=e=>{if(!(e in h))throw new Error(`组件'${e}'未加载, 请确认拼写无误且组件已开启.`);return h[e]},m=async e=>{const{componentLoadTrace:t}=await Promise.resolve().then(n.bind(n,1485)),{matchUrlPattern:a}=await Promise.resolve().then(n.bind(n,1906)),{coreApis:r}=await Promise.resolve().then(n.bind(n,9388));await t(e);const o=async()=>{p(e);const t=await e.entry({settings:(0,i.getComponentSettings)(e),metadata:e,coreApis:r});h[e.name]=t||{}};e.reload&&e.unload&&(0,i.addComponentListener)(e.name,(async t=>{if(!1!==e.configurable&&!(e.urlExclude&&e.urlExclude.some(a)||e.urlInclude&&e.urlInclude.every(lodash.negate(a))))if(e.name in h){if(t&&e.reload&&(e.reload(),e.widget&&p(e)),!t&&e.unload&&(e.unload(),e.widget)){const{getData:t}=await Promise.resolve().then(n.bind(n,950)),{WidgetsPlugin:i}=await Promise.resolve().then(n.bind(n,6243)),[a]=t(i);if(a){const t=u(e),n=a.findIndex((e=>e.name===t));-1!==n&&a.splice(n,1)}}}else t&&await o()})),(0,i.isComponentEnabled)(e)&&await o()},g=async()=>{const{settings:e}=await Promise.resolve().then(n.bind(n,6171)),{batchParseCode:t}=await Promise.resolve().then(n.bind(n,7731));(await t(Object.values(e.userComponents).map((e=>e.code)))).forEach((e=>{c.push(e),l[e.name]=e}))},v=async()=>{const e=(0,i.getGeneralSettings)(),{loadAllPlugins:t}=await Promise.resolve().then(n.bind(n,1623)),o=()=>t(c).then((()=>Promise.allSettled(c.map(d)))).then((()=>Promise.allSettled(c.map(m)))).then((async()=>{if(e.devMode){const{componentLoadTime:e,componentResolveTime:t}=await Promise.resolve().then(n.bind(n,1485)),{logStats:i}=await Promise.resolve().then(n.bind(n,9476));i("components block",e),i("components resolve",t)}}));return new Promise((t=>{e.scriptLoadingMode===r.LoadingMode.Delay?(0,a.fullyLoaded)((()=>o().then(t))):e.scriptLoadingMode===r.LoadingMode.Race&&(0,a.contentLoaded)((()=>o().then(t)))}))}},5143:function(e,t,n){"use strict";n.r(t),n.d(t,{getDescriptionMarkdown:function(){return s},getDescriptionHTML:function(){return l},getDescriptionText:function(){return c}});var i=n(5106),a=n(7084),r=n.n(a),o=n(7365);const s=e=>{const{description:t,author:n}=e;return(n?Array.isArray(n)?`by ${n.map((e=>`[@${e.name}](${e.link})`)).join(",")}\n\n`:`by [@${n.name}](${n.link})\n\n`:"")+(t?"string"==typeof t?t:t[(0,i.languageNameToCode)((0,o.getSelectedLanguage)())]||t["zh-CN"]:"暂无描述.")},l=e=>r()(s(e)),c=e=>{const t=l(e),n=document.createElement("div");return n.innerHTML=t,n.innerText}},7365:function(e,t,n){"use strict";n.r(t),n.d(t,{addI18nData:function(){return o},getSelectedLanguage:function(){return s}});var i=n(950),a=n(6171),r=n(5106);const o=(e,t,n)=>{(0,i.addData)(`i18n.${e}`,((e,i)=>{t?.forEach((([t,n])=>e.set(t,n))),n&&i.push(...n)}))},s=()=>{const e=(0,a.getComponentSettings)("i18n");return(0,r.languageNameToCode)(e.options.language)}},1993:function(e,t,n){"use strict";n.d(t,{WK:function(){return p},U6:function(){return h},Ty:function(){return f}});var i=n(7195),a=n(2121),r=n(6171),o=n(5106),s=n(950),l=n(1906);function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class d{constructor(){c(this,"name",void 0),c(this,"link",void 0),c(this,"defaultLanguage",void 0)}getTargetLanguage(){const e=(0,r.getComponentSettings)("i18n");return e.enabled?(0,o.languageNameToCode)(e.options.language):this.defaultLanguage}toString(){return this.name}}class u extends d{constructor(...e){super(...e),c(this,"name","Google"),c(this,"link","https://translate.google.com/"),c(this,"defaultLanguage","zh"),c(this,"apiUrl","https://translate.google.com/translate_a/single")}async translate(e){let t=this.getTargetLanguage();t.includes("-")&&t!==this.defaultLanguage&&(t=t.substring(0,t.indexOf("-")));try{const n=await(0,i.monkey)({url:`${this.apiUrl}?${(0,l.formData)({client:"gtx",sl:"auto",tl:t,dt:"t",q:encodeURIComponent(e)})}`,method:"GET",headers:{"User-Agent":a.UserAgent},responseType:"json"});return n[0].map((e=>e[0])).join("")}catch(e){throw console.error("Translator: Google",e),new Error("调用Google翻译失败.")}}}const[p]=(0,s.registerAndGetData)("i18n.machineTranslators",{GoogleCN:new class extends u{constructor(...e){super(...e),c(this,"name","GoogleCN"),c(this,"link","https://translate.google.cn/"),c(this,"apiUrl","https://translate.google.cn/translate_a/single")}},Google:new u}),h=Object.keys(p),f=()=>{const{options:{translator:e}}=(0,r.getComponentSettings)("i18n");return p[e]||p.GoogleCN}},2168:function(e,t,n){"use strict";n.d(t,{WY:function(){return a},dr:function(){return r}});const i=(e="search_history")=>{const t=localStorage.getItem(e);return t?JSON.parse(t):[]},a=(e,t="search_history")=>{console.log("add",e),localStorage.setItem(t,JSON.stringify(lodash.sortBy(lodash.uniqBy([{value:e,isHistory:1,timestamp:Number(new Date)},...i()],(e=>e.value)),(e=>e.timestamp)).reverse().slice(0,12)))},r={name:"history",getActions:async()=>{const{search:e}=await Promise.resolve().then(n.bind(n,6674)),t={name:"清除搜索历史",icon:"mdi-trash-can-outline",description:"Clear History",explicitSelect:!0,action:()=>{((e="search_history")=>{localStorage.setItem(e,"[]")})()}},a=i().map((t=>({name:t.value,icon:"mdi-history",explicitSelect:!0,action:()=>{e(t.value)},deleteAction:()=>{((e,t="search_history")=>{const n=i(),a=n.findIndex((t=>t.value===e));console.log("delete",e,a),-1!==a&&(n.splice(a,1),localStorage.setItem(t,JSON.stringify(n)))})(t.value)}})));return a.length>0&&a.push(t),a}}},4247:function(e,t,n){"use strict";n.r(t),n.d(t,{LaunchBarActionProviders:function(){return i}});const i="launchBar.actions"},6674:function(e,t,n){"use strict";n.r(t),n.d(t,{search:function(){return o},searchProvider:function(){return s}});var i=n(1906),a=n(7195),r=n(2168);const o=e=>{if(!e)return;(0,r.WY)(e);const t={keyword:e,from_source:"nav_suggest_new"};window.open(`https://search.bilibili.com/all?${(0,i.formData)(t)}`,"_blank")},s={name:"search",getActions:async e=>{const t=`https://s.search.bilibili.com/main/suggest?func=suggest&suggest_type=accurate&sub_type=tag&main_ver=v1&highlight=&userid=${(0,i.getUID)()}&bangumi_acc_num=1&special_acc_num=1&topic_acc_num=1&upuser_acc_num=3&tag_num=10&special_num=10&bangumi_num=10&upuser_num=3&term=${e}`,n=await(0,a.getJson)(t),r=[{name:e,icon:"search",content:async()=>Vue.extend({render:t=>t("div",{domProps:{innerHTML:`${e}`}})}),action:()=>o(e)}];if(0!==n.code)return r;const s=lodash.get(n,"result.tag");return s?(r.push(...s.map((e=>({name:e.value,icon:"search",content:async()=>Vue.extend({render:t=>t("div",{domProps:{innerHTML:e.name.replace(/suggest_high_light/g,"suggest-highlight")}})}),action:()=>o(e.value)})))),lodash.uniqBy(r,(e=>e.name))):r}}},9931:function(e,t,n){"use strict";n.r(t),n.d(t,{toggleLaunchBar:function(){return g}});var i=n(1906),a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("VPopup",{staticClass:"global-launch-bar-container",attrs:{lazy:!1,fixed:""},on:{"!keydown":function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"esc",27,t.key,["Esc","Escape"])?null:e.close()}},model:{value:e.show,callback:function(t){e.show=t},expression:"show"}},[n("LaunchBar",{ref:"launchBar"})],1)};a._withStripped=!0;var r=n(7553),o=n(3059),s=Vue.extend({components:{LaunchBar:o.Z,VPopup:r.default},data:()=>({show:!0}),watch:{show(e){e&&this.focus()}},async mounted(){await this.$nextTick(),this.focus()},methods:{focus(){const e=this.$refs.launchBar?.$refs.input;e?.focus(),e?.select()},close(){this.show=!1;this.$refs.launchBar?.$refs.input?.blur()}}}),l=n(3379),c=n.n(l),d=n(5584),u=n.n(d),p={insert:"head",singleton:!1},h=(c()(u(),p),u().locals,(0,n(1900).Z)(s,a,[],!1,null,null,null));h.options.__file="src/components/launch-bar/GlobalLaunchBar.vue";var f=h.exports;let m;const g=()=>{if(!m)return m=(0,i.mountVueComponent)(f),void document.body.append(m.$el);m.show=!m.show}},6243:function(e,t,n){"use strict";n.r(t),n.d(t,{SettingsPanelDockSide:function(){return h},WidgetsPlugin:function(){return p},component:function(){return f}});var i=n(1906),a=n(4345),r=n(6314),o=n(2462),s=n(6171),l=n(5300),c=n(2587),d=n(950),u=n(4247);const p="widgets";let h;!function(e){e.Left="左侧",e.Right="右侧"}(h||(h={}));const f={name:"settingsPanel",displayName:"通用设置",configurable:!1,entry:async({metadata:e})=>{const{isIframe:t}=await Promise.resolve().then(n.bind(n,1906));t()||((0,s.addComponentListener)(`${e.name}.dockSide`,(e=>{document.body.classList.toggle("settings-panel-dock-right",e===h.Right)}),!0),requestIdleCallback((async()=>{const e=await Promise.resolve().then(n.bind(n,5863)),t=(0,i.mountVueComponent)(e);document.body.insertAdjacentElement("beforeend",t.$el)})))},options:{themeColor:{defaultValue:"#00A0D8",displayName:"主题颜色",color:!0},scriptLoadingMode:{defaultValue:a.LoadingMode.Delay,displayName:"功能加载模式",dropdownEnum:a.LoadingMode},styleLoadingMode:{defaultValue:a.LoadingMode.Race,displayName:"样式加载模式",dropdownEnum:a.LoadingMode},textColor:{defaultValue:r.TextColor.Auto,displayName:"文本颜色",dropdownEnum:r.TextColor},cdnRoot:{defaultValue:o.CdnTypes.jsDelivr,displayName:"更新源",dropdownEnum:o.CdnTypes},dockSide:{defaultValue:h.Left,displayName:"设置面板停靠",dropdownEnum:h},filenameFormat:{defaultValue:"[title][ - ep]",displayName:"文件命名格式"},batchFilenameFormat:{defaultValue:"[n - ][ep]",displayName:"批量命名格式"},downloadPackageEmitMode:{defaultValue:l.h.packed,displayName:"文件下载模式",dropdownEnum:l.h},devMode:{defaultValue:!1,displayName:"开发者模式"}},tags:[c.t.general],i18n:{"en-US":{map:[["通用设置","General"],["实验性","Experimental"],["通用","General"],["开发者模式","Dev mode"],["辅助颜色","Accent color"],["功能加载模式","Script loading mode"],["样式加载模式","Style loading mode"]]}},plugin:{displayName:"设置面板 - 功能扩展",setup:()=>{(0,d.addData)(u.LaunchBarActionProviders,(e=>{e.push({name:"onlineRegistry",getActions:async()=>[{name:"切换在线仓库",description:"Toggle Online Registry",icon:"mdi-web",action:async()=>{const{togglePopup:e}=await Promise.resolve().then(n.bind(n,7503));e()}}]})}))}}}},5858:function(e,t,n){"use strict";n.d(t,{U:function(){return a},B:function(){return r}});var i=n(6171);const a=Vue.extend({props:{componentData:{type:Object,required:!0}},data(){return{settings:(0,i.getComponentSettings)(this.componentData)}}}),r=e=>Vue.extend({data:()=>({virtual:!1}),async mounted(){const{dq:t}=await Promise.resolve().then(n.bind(n,1906)),{visibleInside:i}=await Promise.resolve().then(n.bind(n,3420)),a=this.$el,r=t(e);r?i(a,r,"150% 0px",(e=>{e.forEach((e=>{this.virtual=!e.isIntersecting}))})):console.warn("virtual container not found, virtual scroll will be disabled!")}})},7503:function(e,t,n){"use strict";n.r(t),n.d(t,{initPopup:function(){return P},togglePopup:function(){return D}});var i=n(1906),a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("VPopup",{staticClass:"online-registry",attrs:{fixed:"","auto-close":!1},model:{value:e.popupOpen,callback:function(t){e.popupOpen=t},expression:"popupOpen"}},[n("div",{staticClass:"online-registry-header"},[n("VIcon",{staticClass:"online-registry-header-title-icon",attrs:{icon:"mdi-web"}}),e._v(" "),n("div",{staticClass:"online-registry-header-title"},[e._v("\n 在线仓库\n ")]),e._v(" "),n("div",{staticClass:"online-registry-header-search"},[n("VIcon",{attrs:{icon:"search",size:18}}),e._v(" "),n("TextBox",{attrs:{placeholder:"搜索功能"},model:{value:e.searchKeyword,callback:function(t){e.searchKeyword=t},expression:"searchKeyword"}})],1),e._v(" "),n("VIcon",{staticClass:"online-registry-header-refresh-icon",attrs:{icon:"mdi-refresh",size:22,title:"刷新"},on:{click:function(t){return e.fetchFeatures()}}}),e._v(" "),n("VIcon",{staticClass:"online-registry-header-close-icon",attrs:{icon:"close",size:18,title:"关闭"},on:{click:function(t){e.popupOpen=!1}}})],1),e._v(" "),n("div",{staticClass:"online-registry-separator"}),e._v(" "),n("div",{ref:"content",staticClass:"online-registry-content"},[e.loading?n("VLoading"):e._e(),e._v(" "),e.loading||e.list.length?e._e():n("VEmpty"),e._v(" "),e._l(e.filteredList,(function(e){return n("RegistryItem",{key:e.name,attrs:{item:e}})}))],2)])};a._withStripped=!0;var r=n(7195),o=n(2462),s=n(1836),l=n(6171),c=n(2264),d=n(3923),u=n(125),p=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("MiniToast",{staticClass:"online-registry-item-wrapper",class:{virtual:e.virtual},attrs:{placement:"right",container:"body",delay:[200,0],offset:[0,12]},scopedSlots:e._u([{key:"toast",fn:function(){return[e.description?n("div",{staticClass:"online-registry-description",domProps:{innerHTML:e._s(e.description)}}):e._e()]},proxy:!0}])},[e.virtual?e._e():n("div",{staticClass:"online-registry-item"},[n("VIcon",{staticClass:"item-icon",attrs:{size:18,icon:e.icon}}),e._v(" "),n("div",{staticClass:"item-badge"},[e._v("\n "+e._s(e.badge)+"\n ")]),e._v(" "),n("div",{staticClass:"item-display-name"},[e._v("\n "+e._s(e.item.displayName)+"\n ")]),e._v(" "),n("div",{staticClass:"grow"}),e._v(" "),n("div",{staticClass:"item-action"},[e.installed?n("VButton",{staticClass:"reinstall-button",attrs:{title:"重新安装",disabled:e.installing},on:{click:function(t){e.install(e.getUrl(e.item))}}},[e._v("\n "+e._s(e.installing?"正在安装":"已安装")+"\n ")]):n("VButton",{staticClass:"install-button",attrs:{title:"安装",type:"primary",disabled:e.installing},on:{click:function(t){e.install(e.getUrl(e.item))}}},[n("VIcon",{attrs:{icon:"mdi-plus",size:15}}),e._v("\n "+e._s(e.installing?"正在安装":"安装")+"\n ")],1)],1)],1)])};p._withStripped=!0;var h=n(5143),f=n(9513),m=n(3420);const g=e=>`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch,e.owner)}${e.fullAbsolutePath}`,v=e=>{const t=`user${lodash.startCase(e.type)}s`;return e.name in l.settings[t]},b={component:{icon:"mdi-cube-scan",badge:"组件",getUrl:g,isInstalled:v},plugin:{icon:"mdi-puzzle-outline",badge:"插件",getUrl:g,isInstalled:v},style:{icon:"mdi-tune",badge:"样式",getUrl:g,isInstalled:v},pack:{icon:"mdi-package-variant-closed",badge:"合集包",getUrl:e=>e.items.map(g).join("\n"),isInstalled:e=>e.items.every(v)}};var y=Vue.extend({components:{VIcon:d.VIcon,VButton:d.VButton,MiniToast:d.MiniToast},props:{item:{type:Object,required:!0}},data(){return{typeMappings:b,...b[this.item.type],description:(0,h.getDescriptionHTML)(this.item),installing:!1,installed:!1,virtual:!1}},created(){this.checkInstalled()},mounted(){const e=this.$el;(0,m.visibleInside)(e,e.parentElement,"150% 0px",(e=>{e.forEach((e=>{this.virtual=!e.isIntersecting}))}))},methods:{checkInstalled(){this.installed=this.isInstalled(this.item)},async install(e){const t=e.split("\n").map((e=>e.trim())).filter((e=>""!==e));try{this.installing=!0,await Promise.all(t.map((async e=>(0,f.m)(e)))),this.checkInstalled()}catch(e){(0,c.logError)(e)}finally{this.installing=!1}}}}),w=n(3379),x=n.n(w),_=n(3947),k=n.n(_),C={insert:"head",singleton:!1},S=(x()(k(),C),k().locals,n(1900)),E=(0,S.Z)(y,p,[],!1,null,null,null);E.options.__file="src/components/settings-panel/sub-pages/online-registry/RegistryItem.vue";var M=E.exports,z=Vue.extend({components:{VIcon:d.VIcon,TextBox:d.TextBox,VPopup:d.VPopup,RegistryItem:M,VLoading:d.VLoading,VEmpty:d.VEmpty},props:{open:{default:!1,type:Boolean}},data:()=>({searchKeyword:"",popupOpen:!1,loading:!1,list:[],filteredList:[],fuse:null}),watch:{searchKeyword:lodash.debounce((function(e){if(!e)return void(this.filteredList=this.list);const t=this.fuse.search(e);this.filteredList=t.map((e=>e.item)),this.$nextTick().then((()=>this.$refs.content.scrollTo(0,0)))}),200)},mounted(){this.fetchFeatures()},methods:{async fetchFeatures(){if(!this.loading)try{this.loading=!0;const e=`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch)}doc/features/features.json`,t=`${o.cdnRoots[(0,l.getGeneralSettings)().cdnRoot](s.meta.compilationInfo.branch)}doc/features/pack/pack.json`,n=await(0,r.monkey)({url:e,responseType:"json"}),i=await(0,r.monkey)({url:t,responseType:"json"});this.list=[...i,...n],this.fuse=new u.Z(this.list,{keys:["displayName","name","description"]}),this.searchKeyword="",this.filteredList=[...this.list]}catch(e){(0,c.logError)(e)}finally{this.loading=!1}}}}),A=n(8959),$=n.n(A),O={insert:"head",singleton:!1},I=(x()($(),O),$().locals,(0,S.Z)(z,a,[],!1,null,null,null));I.options.__file="src/components/settings-panel/sub-pages/online-registry/OnlineRegistry.vue";var L=I.exports;let T;const P=()=>{T||(T=(0,i.mountVueComponent)(L),document.body.append(T.$el))},D=()=>{T||P(),T.popupOpen=!T.popupOpen}},2587:function(e,t,n){"use strict";n.d(t,{t:function(){return i}});const i={video:{name:"video",displayName:"视频",color:"#2196F3",icon:"mdi-play-circle-outline",order:1},style:{name:"style",displayName:"样式",color:"#8BC34A",icon:"mdi-palette-outline",order:2},feeds:{name:"feeds",displayName:"动态",color:"#00ACC1",icon:"mdi-pinwheel-outline",order:3},live:{name:"live",displayName:"直播",color:"#26A69A",icon:"mdi-video-wireless-outline",order:4},utils:{name:"utils",displayName:"工具",color:"#A36FFD",icon:"mdi-rocket-launch-outline",order:5},touch:{name:"touch",displayName:"触摸",color:"#78909C",icon:"mdi-gesture-tap-button",order:6},experimental:{name:"experimental",displayName:"实验",color:"#FF5722",icon:"mdi-flask-outline",order:7},general:{name:"general",displayName:"通用",color:"#888",icon:"mdi-progress-wrench",order:8}}},7010:function(e,t,n){"use strict";n.r(t),n.d(t,{installComponent:function(){return o},uninstallComponent:function(){return s},toggleComponent:function(){return l}});var i=n(6171),a=n(5830),r=n(8171);const o=async e=>{const{components:t}=await Promise.resolve().then(n.bind(n,8171)),{parseExternalInput:o}=await Promise.resolve().then(n.bind(n,7731)),s=await o(e);if(null===s)throw new Error("无效的组件代码");const{settings:l}=await Promise.resolve().then(n.bind(n,6171));if((0,a.Z)().some((e=>e.name===s.name)))throw new Error(`不能覆盖内置组件'${s.name}', 请更换名称`);const c={...lodash.omit(s,"entry","widget","instantStyles","reload","unload","plugin","urlInclude","urlExclude")},d=l.userComponents[s.name];return d?(d.code=e,d.metadata=c,d.settings=lodash.defaultsDeep(d.settings,(0,i.componentToSettings)(s)),{metadata:s,message:`已更新组件'${s.displayName}', 刷新后生效`}):(l.userComponents[s.name]={code:e,metadata:c,settings:(0,i.componentToSettings)(s)},t.push(s),r.componentsMap[s.name]=s,{metadata:s,message:`已安装组件'${s.displayName}', 刷新后生效`})},s=async e=>{const{settings:t}=await Promise.resolve().then(n.bind(n,6171)),{components:i}=await Promise.resolve().then(n.bind(n,8171)),a=Object.entries(t.userComponents).find((([t,{metadata:{displayName:n}}])=>t===e||n===e));if(!a)throw new Error(`没有找到与名称'${e}'相关联的组件`);const[o,{metadata:s,settings:l}]=a,c=i.findIndex((e=>e.name===o));if(-1!==c){const{instantStyles:e}=i[c];if(e){const{removeStyle:t}=await Promise.resolve().then(n.bind(n,6182));e.forEach((e=>t(e.name)))}l.enabled=!1,i.splice(c,1),delete r.componentsMap[o]}return delete t.userComponents[o],{metadata:s,message:`已卸载组件'${s.displayName}, 刷新后生效'`}},l=async e=>{const{settings:t}=await Promise.resolve().then(n.bind(n,6171)),i=Object.entries(t.userComponents).find((([t,{metadata:{displayName:n}}])=>t===e||n===e));if(!i)throw new Error(`没有找到与名称'${e}'相关联的组件`);const[,a]=i;a.settings.enabled=!a.settings.enabled;const{enabled:r}=a.settings,{displayName:o}=a.metadata;return`已${r?"开启":"关闭"}组件'${o}', 可能需要刷新后才能生效`}},2149:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{updateCategories:function(){return updateCategories},updateIcons:function(){return updateIcons}});var _core_ajax__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(7195),_core_download__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(4114);const updateCategories=async()=>{const[script]=dqa("script").filter((e=>e.src.includes("international-home/international-home")));if(!script)throw new Error("no script found");const scriptText=await(0,_core_ajax__WEBPACK_IMPORTED_MODULE_1__.getText)(script.src),match=scriptText.match(/([\w]+?=\[\{name:"首页".+?\}.+?\]),[\w]+?=\[\{name:"首頁"/);if(!match)throw new Error("no match in script");const variables=match[1].match(/(\w+?)(?==\[)/g),data=eval(`var ${match[1]}; [${variables.join(",")}]`);_core_download__WEBPACK_IMPORTED_MODULE_0__.DownloadPackage.single("raw.json",data)},updateIcons=()=>{const e=dqa("body > svg:not(#be-category-icons)").filter((e=>e.querySelector("[id^=bili]")));if(0===e.length)throw new Error("svg icons not found");const[t]=e,n=t.cloneNode(!0);n.id="be-category-icons",dqa(n,"symbol").forEach((e=>{e.id=e.id.replace(/^bili-/,"header-icon-")})),_core_download__WEBPACK_IMPORTED_MODULE_0__.DownloadPackage.single("icons.svg",n.outerHTML)}},6958:function(e,t,n){"use strict";n.r(t),n.d(t,{bpxPlayerPolyfill:function(){return o}});var i=n(3420),a=n(5550),r=n(1906);const o=lodash.once((async()=>{document.URL.startsWith("https://www.bilibili.com/bangumi/play/")&&((async()=>{const e=await(0,a.select)(".bpx-player-container");e?(0,i.attributes)(e,(()=>{const t=e.getAttribute("data-screen");document.body.classList.toggle("player-mode-webfullscreen","full"===t||"web"===t),"wide"===t&&document.body.classList.add("player-mode-widescreen")})):console.warn("[bpx player polyfill] bpxContainer not found")})(),(async()=>{const e=await(0,a.select)((()=>unsafeWindow.$pbp));if(!e)return void console.warn("[bpx player polyfill] pbp not found");const t={aid:e.options.aid.toString(),cid:e.options.cid.toString(),bvid:e.options.bvid};Object.values(t).some((e=>""===e||parseInt(e)<=0))&&console.warn("[bpx player polyfill] invalid pbp data"),Object.assign(unsafeWindow,t)})(),(async()=>{const e=await(0,a.select)(".bpx-player-video-perch");e&&(0,r.preventEvent)(e,"dblclick")})())}))},7412:function(e,t,n){"use strict";n.r(t),n.d(t,{PlayerAgent:function(){return u},VideoPlayerAgent:function(){return p},BwpPlayerAgent:function(){return h},BangumiPlayerAgent:function(){return f},playerAgent:function(){return m}});var i=n(5550),a=n(1906),r=n(7735),o=n(6958);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const l=e=>{const t=()=>(0,i.select)(e);return t.selector=e,t.sync=()=>dq(e),t},c=e=>{const t=e=>"string"!=typeof e?lodash.mapValues(e,t):l(e);return lodash.mapValues(e,t)},d=e=>{const t=e.sync();return t?.click(),t};class u{constructor(){s(this,"type",void 0),s(this,"query",void 0)}provideCustomQuery(e){const t=c(e[this.type]??e.video);return{...this,custom:t}}widescreen(){return d(this.query.control.buttons.widescreen)}webFullscreen(){return d(this.query.control.buttons.webFullscreen)}fullscreen(){return d(this.query.control.buttons.fullscreen)}togglePlay(){return d(this.query.control.buttons.start)}togglePip(){return d(this.query.control.buttons.pip)}toggleMute(){return d(this.query.control.buttons.volume)}toggleDanmaku(){const e=this.query.danmakuSwitch.sync();return e?(e.checked=!e.checked,(0,a.raiseEvent)(e,"change"),e.checked):null}}class p extends u{constructor(...e){super(...e),s(this,"type","video"),s(this,"query",c({playerWrap:".player-wrap",bilibiliPlayer:".bilibili-player",playerArea:".bilibili-player-area",video:{element:".bilibili-player-video video",wrap:".bilibili-player-video-wrap",top:".bilibili-player-video-top",state:".bilibili-player-video-state",panel:".bilibili-player-video-panel",popup:".bilibili-player-video-popup",subtitle:".bilibili-player-video-subtitle",basDanmaku:".bilibili-player-video-bas-danmaku",advDanmaku:".bilibili-player-video-adv-danmaku",danmaku:".bilibili-player-video-danmaku",container:".bilibili-player-video"},control:{element:".bilibili-player-control",wrap:".bilibili-player-control-wrap",mask:".bilibili-player-control-mask",top:".bilibili-player-control-top",progress:".bilibili-player-video-progress",bottom:".bilibili-player-control-bottom",bottomLeft:".bilibili-player-control-bottom-left",bottomCenter:".bilibili-player-control-bottom-center",bottomRight:".bilibili-player-control-bottom-right",buttons:{start:".bilibili-player-video-btn-start",next:".bilibili-player-video-btn-next",time:".bilibili-player-video-time",quality:".bilibili-player-btn-quality",pageList:".bilibili-player-video-btn-pagelist",speed:".bilibili-player-video-btn-speed",subtitle:".bilibili-player-video-btn-subtitle",volume:".bilibili-player-video-btn-volume .bilibili-player-iconfont-volume",settings:".bilibili-player-video-btn-setting",pip:".bilibili-player-video-btn-pip",widescreen:".bilibili-player-video-btn-widescreen",webFullscreen:".bilibili-player-video-web-fullscreen",fullscreen:".bilibili-player-video-btn-fullscreen"}},toastWrap:".bilibili-player-video-toast-wrp",danmakuTipLayer:".bilibili-player-dm-tip-wrap",danmakuSwitch:".bilibili-player-video-danmaku-switch input"}))} // eslint-disable-next-line class-methods-use-this get nativeApi(){return unsafeWindow.player}isMute(){return this.nativeApi?this.nativeApi.isMute():null}changeVolume(e){if(!this.nativeApi)return null;const t=this.nativeApi.volume();return this.nativeApi.volume(t+e/100),Math.round(100*this.nativeApi.volume())}seek(e){return this.nativeApi?(this.nativeApi.play(),setTimeout((()=>{this.nativeApi.seek(e);const t=dq(".bilibili-player-video-toast-bottom .bilibili-player-video-toast-item:first-child .bilibili-player-video-toast-item-text span:nth-child(2)");t&&(t.textContent=" 00:00")})),this.nativeApi.getCurrentTime()):null}changeTime(e){if(!this.nativeApi)return null;const t=this.query.video.element.sync();return t?(this.nativeApi.seek(t.currentTime+e,t.paused),this.nativeApi.getCurrentTime()):null}}class h extends p{constructor(){super(),s(this,"type","bwp"),this.query.video.element=l(".bilibili-player-video bwp-video")}}class f extends u{constructor(){super(),s(this,"type","bangumi"),s(this,"query",c({playerWrap:".player-module",bilibiliPlayer:".bpx-player-container",playerArea:".bpx-player-primary-area",video:{element:".bpx-player-video-wrap video",wrap:".bpx-player-video-area",top:".bpx-player-top-wrap",state:".bpx-player-state-wrap",panel:".bpx-player-ending-panel",popup:".bpx-player-dialog-wrap",subtitle:".bpx-player-subtitle-wrap",basDanmaku:".bpx-player-bas-dm-wrap",advDanmaku:".bpx-player-adv-dm-wrap",danmaku:".bpx-player-row-dm-wrap",container:".bpx-player-video-wrap"},control:{element:".squirtle-controller",wrap:".bpx-player-control-wrap",mask:".bpx-player-control-mask",top:".bpx-player-control-top",progress:".squirtle-progress-wrap",bottom:".squirtle-controller-wrap",bottomLeft:".squirtle-controller-wrap-left",bottomCenter:".squirtle-controller-wrap-center",bottomRight:".squirtle-controller-wrap-right",buttons:{start:".squirtle-video-start",next:".squirtle-video-next",time:".squirtle-time-wrap",quality:".squirtle-video-quality",pageList:".squirtle-video-pagelist",speed:".squirtle-video-speed",subtitle:".squirtle-video-subtitle",volume:".squirtle-video-volume .squirtle-volume-icon",settings:".squirtle-video-setting",pip:".squirtle-video-pip",widescreen:".squirtle-video-widescreen",webFullscreen:".squirtle-video-pagefullscreen",fullscreen:".squirtle-video-fullscreen"}},toastWrap:".bpx-player-tooltip-area",danmakuTipLayer:".bpx-player-dialog-wrap",danmakuSwitch:".bpx-player-dm-switch input"})),(0,o.bpxPlayerPolyfill)()}isMute(){return this.query.control.buttons.volume.sync()?.classList.contains("squirtle-volume-mute-state")??!1}changeVolume(e){const t=this.query.video.element.sync();return t?(t.volume=lodash.clamp(t.volume+e/100,0,1),Math.round(100*t.volume)):null}seek(e){const t=this.query.video.element.sync();return t?(t.play(),setTimeout((()=>{t.currentTime=lodash.clamp(e,0,t.duration);const n=dq(".bpx-player-toast-row .bpx-player-toast-item .bpx-player-toast-text");n?.textContent?.startsWith("已为您定位至")&&(n.textContent="已为您定位至00:00")})),t.currentTime):null}changeTime(e){const t=this.query.video.element.sync();return t?(t.currentTime=lodash.clamp(t.currentTime+e,0,t.duration),t.currentTime):null}}const m=(0,r.matchCurrentPage)(r.bangumiUrls)?new f:(0,a.isBwpVideo)()?new h:new p},7195:function(e,t,n){"use strict";n.r(t),n.d(t,{getBlob:function(){return s},getBlobWithCredentials:function(){return l},getText:function(){return d},getTextWithCredentials:function(){return u},getJson:function(){return f},getJsonWithCredentials:function(){return m},postText:function(){return g},postTextWithCredentials:function(){return v},postJson:function(){return b},postJsonWithCredentials:function(){return y},monkey:function(){return w},responsiveGetPages:function(){return x},getPages:function(){return _},bilibiliApi:function(){return k}});var i=n(2264);const a=e=>{const t=new XMLHttpRequest,{isText:n=!0,body:i}=e(t);return new Promise(((e,a)=>{t.addEventListener("load",(()=>e(n?t.responseText:t.response))),t.addEventListener("error",(()=>a(t.status))),t.send(i)}))},r=e=>t=>(t.withCredentials=!0,e(t)),o=e=>t=>(t.responseType="blob",t.open("GET",e),{isText:!1}),s=e=>a(o(e)),l=e=>a(r(o(e))),c=e=>t=>(t.responseType="text",t.open("GET",e),{isText:!0}),d=e=>a(c(e)),u=e=>a(r(c(e))),p=e=>t=>(t.responseType="json",t.open("GET",e),{isText:!1}),h=e=>"string"==typeof e?JSON.parse(e):e,f=async e=>{const t=await a(p(e));return h(t)},m=async e=>{const t=await a(r(p(e)));return h(t)},g=(e,t)=>a((n=>(n.open("POST",e),n.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),{isText:!1,body:t}))),v=(e,t)=>a((n=>(n.open("POST",e),n.withCredentials=!0,n.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),{isText:!1,body:t}))),b=(e,t)=>a((n=>(n.open("POST",e),n.setRequestHeader("Content-Type","application/json"),{isText:!1,body:JSON.stringify(t)}))),y=(e,t)=>a((n=>(n.open("POST",e),n.withCredentials=!0,n.setRequestHeader("Content-Type","application/json"),{isText:!1,body:JSON.stringify(t)}))),w=e=>new Promise(((t,n)=>{const i={...e,onload:e=>t(e.response),onerror:e=>{const t={...JSON.parse(JSON.stringify(e)),toString(){return JSON.stringify(this)}};n(t)}};"method"in i||(i.method="GET"),GM_xmlhttpRequest(i)})),x=e=>{let t;const n=new Promise((n=>{t=new Promise((t=>{(async()=>{const{api:i,getList:a,getTotal:r}=e;let o=1,s=1/0;const l=[];for(;l.length{const[,t]=x(e);return await t},k=async(e,t)=>{const n=await e;if(0!==n.code){const e=new Error(`${t}: code = ${n.code}, message = ${n.message||n.msg}`);throw(0,i.logError)(e),e}return n.data||{}}},2462:function(e,t,n){"use strict";let i;n.r(t),n.d(t,{CdnTypes:function(){return i},cdnRoots:function(){return r}}),function(e){e.jsDelivr="jsDelivr",e.GitHub="GitHub"}(i||(i={}));const a="the1812",r={jsDelivr:(e,t)=>`https://cdn.jsdelivr.net/gh/${t||a}/Bilibili-Evolved@${e}/`,GitHub:(e,t)=>`https://github.com/${t||a}/Bilibili-Evolved/raw/${e}/`}},9388:function(e,t,n){"use strict";n.r(t),n.d(t,{coreApis:function(){return Ln},externalApis:function(){return Tn}});var i={};n.r(i),n.d(i,{Reorder:function(){return F},ReorderDecreaseClassName:function(){return T},ReorderEnabledClassName:function(){return D},ReorderIncreaseClassName:function(){return P},ReorderOrientations:function(){return B},ReorderingClassName:function(){return V}});var a={};n.r(a),n.d(a,{getUserInfo:function(){return Z}});var r={};n.r(r),n.d(r,{CompareResult:function(){return W},Version:function(){return G}});var o={};n.r(o),n.d(o,{loadDanmakuSettingsPanel:function(){return ne},loadLazyPanel:function(){return ee},loadLazyPlayerSettingsPanel:function(){return te},loadSubtitleSettingsPanel:function(){return ie}});var s={};n.r(s),n.d(s,{styledComponentEntry:function(){return pe},toggleStyle:function(){return he}});var l={};n.r(l),n.d(l,{getWatchlaterList:function(){return ge},toggleWatchlater:function(){return ve},watchlaterList:function(){return me}});var c={};n.r(c),n.d(c,{addMenuItem:function(){return De},applyContentFilter:function(){return Ie},bangumiTypeList:function(){return we},feedsCardTypes:function(){return ye},feedsCardsManager:function(){return Me},forEachFeedsCard:function(){return ze},getFeeds:function(){return Pe},getVideoFeeds:function(){return Te},groupVideoFeeds:function(){return Ae},isPreOrderedVideo:function(){return $e},navbarFeedsTypeList:function(){return xe},withContentFilter:function(){return Le}});var d={};n.r(d),n.d(d,{disableProfilePopup:function(){return lt}});var u={};n.r(u),n.d(u,{compareID:function(){return ut},getLatestID:function(){return dt},getNotifyCount:function(){return mt},isNewID:function(){return ht},setLatestID:function(){return pt},updateInterval:function(){return ct},updateLatestID:function(){return ft}});var p={};n.r(p),n.d(p,{convertHexColorForDialogue:function(){return vt},convertHexColorForStyle:function(){return bt},convertTimeByDuration:function(){return wt},convertTimeByEndTime:function(){return xt},normalizeContent:function(){return _t}});var h={};n.r(h),n.d(h,{lightOff:function(){return Mt},lightOn:function(){return Et}});var f={};n.r(f),n.d(f,{forEachVideoDanmaku:function(){return $t}});var m={};n.r(m),n.d(m,{BangumiInfo:function(){return Lt},VideoInfo:function(){return It}});var g={};n.r(g),n.d(g,{allQualities:function(){return Dt},loginRequiredQualities:function(){return Tt},vipRequiredQualities:function(){return Pt}});var v={};n.r(v),n.d(v,{addMenuItem:function(){return Bt},forEachContextMenu:function(){return Vt}});var b={};n.r(b),n.d(b,{addControlBarButton:function(){return qt}});var y={};n.r(y),n.d(y,{waitForControlBar:function(){return Ht}});var w={};n.r(w),n.d(w,{LiveSocket:function(){return Kt}});var x={};n.r(x),n.d(x,{addMenuItem:function(){return sn},commentAreas:function(){return Jt},forEachCommentArea:function(){return rn},forEachCommentItem:function(){return on}});var _={};n.r(_),n.d(_,{addCategoryIcons:function(){return bn},categories:function(){return mn},categoryCodes:function(){return gn},categoryLinks:function(){return vn},rawData:function(){return cn}});var k={};n.r(k),n.d(k,{createSwitchOptions:function(){return Mn}});var C=n(7195),S=n(2462),E=n(4114),M=n(7731),z=n(7590),A=n(7177),$=n(4345),O=n(1836),I=n(3420);function L(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const T="reorder-decrease",P="reorder-increase",D="reorder-enabled",V="reordering",B={horizontal:{name:"horizontal",getMoveTransform:e=>`translateX(${e}px)`,setOtherTransform:lodash.throttle(((e,t,n)=>{if(!t.classList.contains(V))return;const i=e.find((e=>e.element===t));if(!i)return;const a=i.rect,r=e.filter((e=>e.rect.leftt.rect.left-e.rect.left)),o=e.filter((e=>e.rect.left>a.left)).sort(((e,t)=>e.rect.left-t.rect.left));if(n>=0){const[e]=o;r.forEach((e=>{e.element.style.transform="",e.element.classList.remove(P)})),o.forEach((t=>{a.left+n+a.width>=t.rect.left+t.rect.width/2?(t.element.classList.add(T),t.element.style.transform=`translateX(-${e.rect.left-a.left}px)`):(t.element.classList.remove(T),t.element.style.transform="")}))}else{const[e]=r;o.forEach((e=>{e.element.style.transform="",e.element.classList.remove(T)})),r.forEach((t=>{a.left+n<=t.rect.left+t.rect.width/2?(t.element.classList.add(P),t.element.style.transform=`translateX(${a.left+a.width-e.rect.left-e.rect.width}px)`):(t.element.classList.remove(P),t.element.style.transform="")}))}}),50)},vertical:{name:"vertical",getMoveTransform:(e,t)=>`translateY(${t}px)`,setOtherTransform:lodash.throttle(((e,t,n,i)=>{if(!t.classList.contains(V))return;const a=e.find((e=>e.element===t));if(!a)return;const r=a.rect,o=e.filter((e=>e.rect.topt.rect.top-e.rect.top)),s=e.filter((e=>e.rect.top>r.top)).sort(((e,t)=>e.rect.top-t.rect.top));if(i>=0){const[e]=s;o.forEach((e=>{e.element.style.transform="",e.element.classList.remove(P)})),s.forEach((t=>{r.top+i+r.height>=t.rect.top+t.rect.height/2?(t.element.classList.add(T),t.element.style.transform=`translateY(-${e.rect.top-r.top}px)`):(t.element.classList.remove(T),t.element.style.transform="")}))}else{const[e]=o;s.forEach((e=>{e.element.style.transform="",e.element.classList.remove(T)})),o.forEach((t=>{r.top+i<=t.rect.top+t.rect.height/2?(t.element.classList.add(P),t.element.style.transform=`translateY(${r.top+r.height-e.rect.top-e.rect.height}px)`):(t.element.classList.remove(P),t.element.style.transform="")}))}}),50)}};class F extends EventTarget{constructor(e){super(),this.container=e,L(this,"orientation",B.horizontal),L(this,"enabled",!1),L(this,"children",void 0),L(this,"snapshots",new Map),L(this,"attachedEvents",[]),this.children=[...this.container.children],this.children.every((e=>""===e.style.order))&&this.children.forEach(((e,t)=>{e.style.order=(t+1).toString()}))}addEventListener(e,t,n){super.addEventListener(e,t,n)}removeEventListener(e,t,n){super.addEventListener(e,t,n)}getOrderMap(){return new Map(this.children.map((e=>[e,parseInt(e.style.order)])))}toggle(){this.enabled?this.disable():this.enable()}generateSnapshots(){this.children.forEach((e=>{this.snapshots.set(e,{element:e,rect:e.getBoundingClientRect()})}))}enable(){this.children.forEach((e=>{let t=0,n=0,i=!1;e.classList.add(D);(()=>{const a=(a,r)=>{e.classList.add(V),e.style.transition="none",e.style.userSelect="none",this.generateSnapshots(),this.children.filter((t=>t!==e)).forEach((e=>{e.style.transition="transform .2s ease-out"})),t=a,n=r,i=!0},r=e=>{a(e.screenX,e.screenY)};e.addEventListener("mousedown",r),this.attachedEvents.push((()=>e.removeEventListener("mousedown",r)));const o=e=>{if(1!==e.touches.length)return;const[t]=e.touches;a(t.screenX,t.screenY)};e.addEventListener("touchstart",o),this.attachedEvents.push((()=>e.removeEventListener("touchstart",o)))})(),(()=>{const a=(i,a)=>{const r=i-t,o=a-n;e.style.transform=this.orientation.getMoveTransform(r,o),this.orientation.setOtherTransform([...this.snapshots.values()],e,r,o)},r=e=>{i&&(a(e.screenX,e.screenY),e.cancelable&&e.preventDefault())};document.addEventListener("mousemove",r),this.attachedEvents.push((()=>document.removeEventListener("mousemove",r)));const o=e=>{if(!i)return;if(1!==e.touches.length)return;const[t]=e.touches;a(t.screenX,t.screenY),e.cancelable&&e.preventDefault()};e.addEventListener("touchmove",o,{passive:!1}),this.attachedEvents.push((()=>e.removeEventListener("touchmove",o)))})(),(()=>{const t=()=>{if(!i)return;e.classList.remove(V),i=!1;let t=0;const n=this.children.filter((t=>t!==e)),a=[];n.forEach((e=>{e.style.transform="",e.style.transition="",e.classList.contains(P)?(t--,e.style.order=(parseInt(e.style.order)+1).toString(),e.classList.remove(P),a.push(this.snapshots.get(e))):e.classList.contains(T)&&(t++,e.style.order=(parseInt(e.style.order)-1).toString(),e.classList.remove(T),a.push(this.snapshots.get(e)))})),e.style.userSelect="",e.style.order=(parseInt(e.style.order)+t).toString(),e.style.transform="",e.style.transition="",this.dispatchEvent(new CustomEvent("reorder",{detail:this.children.map((e=>({element:e,order:parseInt(e.style.order)})))}))};document.addEventListener("mouseup",t),this.attachedEvents.push((()=>document.removeEventListener("mouseup",t))),e.addEventListener("touchend",t),this.attachedEvents.push((()=>e.removeEventListener("touchend",t)))})()})),this.enabled=!0}disable(){this.attachedEvents.forEach((e=>e())),this.children.forEach((e=>e.classList.remove(D))),this.enabled=!1}}var N=n(391),j=n(5550),q=n(6182),H=n(6314),R=n(6171);const U={isLogin:!1},Z=lodash.once((async()=>{const{getUID:e}=await Promise.resolve().then(n.bind(n,1906));if(!e())return U;const{getJsonWithCredentials:t}=await Promise.resolve().then(n.bind(n,7195)),i=await t("https://api.bilibili.com/x/web-interface/nav");return 0!==i.code&&-101!==i.code?(console.warn("[store.fetchUserInfo] API Error",i.message),U):i.data}));let W;!function(e){e[e.less=-1]="less",e[e.equal=0]="equal",e[e.greater=1]="greater",e[e.incomparable=NaN]="incomparable"}(W||(W={}));class G{constructor(e){var t,n,i;if(this.versionString=e,i=void 0,(n="parts")in(t=this)?Object.defineProperty(t,n,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[n]=i,!/^[\d\.]+$/.test(e))throw new Error("Invalid version string");this.parts=e.split(".").map((e=>parseInt(e)))}compareTo(e){for(let t=0;te.parts[t]?W.greater:W.less}return this.parts.length!==e.parts.length?W.less:W.equal}greaterThan(e){return this.compareTo(e)===W.greater}lessThan(e){return this.compareTo(e)===W.less}equals(e){return this.compareTo(e)===W.equal}}var X=n(1906),K=n(2121),J=n(3708),Y=n(53),Q=n(5106);const ee=async(e,t={})=>{const{style:n,enterDelay:i=750,leaveDelay:a=1e3}=t,r=await(0,j.select)(e);if(!r)throw new Error(`lazy panel failed! selector = ${e}`);let o;return void 0!==n&&(o=document.createElement("style"),o.textContent=n,document.body.insertAdjacentElement("beforeend",o)),(0,X.raiseEvent)(r,"mouseover"),await(0,X.delay)(i),(0,X.raiseEvent)(r,"mouseout"),setTimeout((()=>o?.remove()),a),r},te=async(e,t,n={})=>{await ee(e,{style:`${t} { display: none !important; }`,...n});const i=(0,X.dq)(t);if(!i)throw new Error(`lazy player settings panel failed! panelSelector = ${t}`);return i},ne=()=>te(".bilibili-player-video-danmaku-setting",".bilibili-player-video-danmaku-setting-wrap"),ie=()=>te(".bilibili-player-video-btn-subtitle",".bilibili-player-video-subtitle-setting-wrap",{style:".bilibili-player-video-subtitle-setting-wrap, .bilibili-player-video-subtitle { display: none }"});var ae=n(2264),re=n(5945),oe=n(7735),se=n(5683),le=n(8208),ce=n(3923),de=n(8171),ue=n(7010);const pe=(e,t)=>async i=>{const{default:a}=await e(),{addStyle:r}=await Promise.resolve().then(n.bind(n,6182));return r(a,i.metadata.name),t(i)},he=(e,t,i=X.none)=>{let a=null;const r=async()=>{if(a)return;const{default:i}=await t(),{addStyle:r}=await Promise.resolve().then(n.bind(n,6182));a=r(i,e)};return{name:e,entry:e=>r().then((()=>i(e))),reload:r,unload:()=>{a?.remove(),a=null}}};var fe=n(5143);const me=[];async function ge(e=!1){const{getJsonWithCredentials:t}=await Promise.resolve().then(n.bind(n,7195)),i=await t("https://api.bilibili.com/x/v2/history/toview/web");if(0!==i.code)throw new Error(`获取稍后再看列表失败: ${i.message}`);if(!i.data.list)return lodash.pullAll(me,me),[];const a=i.data.list,r=a.filter((e=>!me.find((t=>t===e.aid)))),o=me.filter((e=>!a.find((t=>t.aid===e))));return lodash.pullAll(me,o),me.push(...r.map((e=>e.aid))),e?a:a.map((e=>e.aid))}const ve=async(e,t)=>{const i=parseInt(e.toString());if(Number.isNaN(i))return;void 0===t&&(t=!me.includes(i));const a=t?"https://api.bilibili.com/x/v2/history/toview/add":"https://api.bilibili.com/x/v2/history/toview/del",{getCsrf:r}=await Promise.resolve().then(n.bind(n,1906)),o=r(),{postTextWithCredentials:s}=await Promise.resolve().then(n.bind(n,7195)),l=await s(a,`aid=${e}&csrf=${o}`),c=JSON.parse(l);if(0!==c.code)throw new Error(`稍后再看操作失败: ${c.message}`);t?me.push(i):lodash.pull(me,i)};requestIdleCallback((async()=>{const{getUID:e}=await Promise.resolve().then(n.bind(n,1906));e()&&ge()}));var be=n(950);const ye={repost:{id:1,name:"转发"},textWithImages:{id:2,name:"图文"},text:{id:4,name:"文字"},video:{id:8,name:"视频"},miniVideo:{id:16,name:"小视频"},column:{id:64,name:"专栏"},audio:{id:256,name:"音频"},bangumi:{id:512,name:"番剧"},share:{id:2048,name:"分享"},manga:{id:2049,name:"漫画"},film:{id:4098,name:"电影"},tv:{id:4099,name:"TV剧"},chinese:{id:4100,name:"国创"},documentary:{id:4101,name:"纪录片"},mediaList:{id:4300,name:"收藏夹"},liveRecord:{id:2047,name:"开播记录"}},we="512,4097,4098,4099,4100,4101",xe="8,64,512,4097,4098,4099,4100,4101";function _e(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const ke=e=>e.querySelector(".repost")?ye.repost:e.querySelector(".imagesbox")?ye.textWithImages:e.querySelector(".video-container")?ye.video:e.querySelector(".bangumi-container")?ye.bangumi:e.querySelector(".article-container")?ye.column:e.querySelector(".music-container")?ye.audio:e.querySelector(".h5share-container")?ye.share:e.querySelector(".vc-ctnr")?ye.miniVideo:e.querySelector(".live-container")?ye.liveRecord:ye.text,Ce=[],Se="feeds.manager.listAdaptors";(0,be.addData)(Se,(e=>{e.push({name:"live",match:[...oe.liveUrls],watchCardsList:async e=>{const t=await(0,j.select)(".room-feed");if(!t)return!1;console.log("live watch");let n=null;return(0,I.childList)(t,(async()=>{if(dq(".room-feed-content")){const t=await(0,j.select)(".room-feed-content .content");n?.disconnect(),[n]=e.updateCards(t)}else n?.disconnect(),n=null,await Promise.all(e.cards.map((e=>e.element)).map((t=>e.removeCard(t))))})),!0}},{name:"space",match:["https://space.bilibili.com/"],watchCardsList:async e=>{const t=await(0,j.select)(".s-space");if(!t)return!1;const n={},i=()=>n.listElement&&n.observer?(console.log("space feeds stop"),n.observer?.then((e=>e.disconnect())),delete n.observer,delete n.listElement,Promise.all(e.cards.map((e=>e.element)).map((t=>e.removeCard(t))))):[],a=()=>{if(n.observer)return n.observer;const t=(0,j.select)(".feed-card .content");return n.observer=(async()=>{const r=await t;r!==await n.listElement&&(n.listElement&&await i(),n.listElement=t,a()),console.log("space feeds start");const[o]=e.updateCards(r);return o})(),n.observer};return(0,I.childListSubtree)(t,(async()=>{dq(".feed-card .content")?a():i()})),!0}},{name:"topic",match:["https://t.bilibili.com/topic"],watchCardsList:async e=>{const t=await(0,j.select)(".page-container");if(!t)return!1;let n=null;return(0,I.childList)(t,(async()=>{if(dq(".page-container .feed")){const t=await(0,j.select)(".feed .feed-topic");n?.disconnect(),[n]=e.updateCards(t)}else n?.disconnect(),n=null,await Promise.all(e.cards.map((e=>e.element)).map((t=>e.removeCard(t))))})),!0}},{name:"default",match:["https://t.bilibili.com/"],watchCardsList:async e=>{const t=await(0,j.select)(".feed-card .content, .detail-content .detail-card");return!!t&&(e.updateCards(t),!0)}})}));class Ee extends EventTarget{constructor(...e){super(...e),_e(this,"watching",!1),_e(this,"cards",[])}addEventListener(e,t,n){super.addEventListener(e,t,n)}removeEventListener(e,t,n){super.removeEventListener(e,t,n)}async addCard(e){if(e&&e instanceof HTMLElement&&e.classList.contains("card"))if(null!==e.querySelector(".skeleton")){const[t]=(0,I.childList)(e,(()=>{null===e.querySelector(".skeleton")&&(t.disconnect(),this.addCard(e))}))}else{if(null===e.parentNode)return;const t=await Ee.parseCard(e);if(!t.presented)return;if(this.cards.find((e=>e.id===t.id)))return;this.cards.push(t),this.cards.sort(((e,t)=>e.id===t.id?0:e.id>t.id?-1:1));const n=new CustomEvent("addCard",{detail:t});this.dispatchEvent(n),Ce.forEach((e=>e.added(t)))}}async removeCard(e){if(e&&e instanceof HTMLElement&&e.classList.contains("card")){const t=e.getAttribute("data-did"),n=this.cards.findIndex((e=>e.id===t));if(-1===n)return;const i=this.cards[n];this.cards.splice(n,1);const a=new CustomEvent("removeCard",{detail:i});this.dispatchEvent(a),Ce.forEach((e=>e.removed(i)))}}static async parseCard(e){ // eslint-disable-next-line no-underscore-dangle -const t=e=>e.__vue__||e.parentElement.__vue__,n=async t=>{const n=await(0,j.sq)((()=>e.querySelector(t)),(t=>null!==t||null===e.parentNode),{queryInterval:100});if(null===e.parentNode)return"";if(null===n)return console.warn(e,t,e.parentNode),"";return n.innerText.trim()},i=e=>{if(void 0===e.card.origin)return{originalText:"",originalDescription:"",originalTitle:""};const t=JSON.parse(e.card.origin);return{originalText:e.originCardData.pureText,originalDescription:lodash.get(t,"item.description",""),originalTitle:t.title}},a=async e=>{const t=parseInt(await n(e));return isNaN(t)?0:t},r={id:e.getAttribute("data-did"),username:await n(".main-content .user-name"),text:"",reposts:await a(".button-bar .single-button:nth-child(1) .text-offset"),comments:await a(".button-bar .single-button:nth-child(2) .text-offset"),likes:await a(".button-bar .single-button:nth-child(3) .text-offset"),element:e,type:ke(e),get presented(){return null!==e.parentNode},async getText(){const n=await(async n=>{if(n===ye.bangumi)return"";const a=await(0,j.sq)((()=>e),(n=>Boolean(t(n)||!e.parentNode)),{queryInterval:100});if(null===e.parentNode)return"";if(null===a)return console.warn(a,e,t(a),e.parentNode),"";const r=t(a);if(n===ye.repost){const e=r.card.item.content,t=i(r);return[e,...Object.values(t).filter((e=>""!==e))].filter((e=>Boolean(e))).join("\n")}return[r.originCardData.pureText,r.originCardData.title].filter((e=>Boolean(e))).join("\n")})(this.type);return this.text=n,n}};if(await r.getText(),e.setAttribute("data-type",r.type.id.toString()),(e=>e.type===ye.repost)(r)){const n=r.username,a=t(r.element),o=lodash.get(a,"card.origin_user.info.uname","");n===o&&e.setAttribute("data-self-repost","true"),r.repostUsername=o,r.repostText=i(a).originalText}return r}updateCards(e){const t=".card[data-did]",n=e=>{if(e instanceof HTMLElement){if(e.matches(t))return e;const n=e.querySelector(t);if(n)return n}};return[...e.querySelectorAll(t)].forEach((e=>this.addCard(e))),(0,I.childList)(e,(e=>{e.forEach((e=>{e.addedNodes.forEach((e=>this.addCard(n(e)))),e.removedNodes.forEach((e=>this.removeCard(n(e))))}))}))}async startWatching(){if(this.watching)return!0;this.watching=!0;const[e]=(0,be.registerAndGetData)(Se,[]),t=e.find((e=>e.match.some((e=>(0,X.matchUrlPattern)(e)))));return t?t.watchCardsList(this):(console.warn("[FeedsCardsManager] No adaptor found",e),!1)}}const Me=new Ee,ze=e=>{(async()=>{if(!await Me.startWatching())return void console.error("feedsCardsManager.startWatching() failed");const{added:t}=e;t&&Me.cards.forEach((e=>t(e))),Ce.push({added:none,removed:none,...e})})()},Ae=e=>{const t=lodash.groupBy(e,(e=>e.aid)),n=e=>({id:e.upID,name:e.upName,faceUrl:e.upFaceUrl});return Object.values(t).map((e=>{if(1===e.length)return e[0];const[t,...i]=e;return t.cooperation=[n(t),...i.map(n)],console.log([...t.cooperation]),t})).sort((0,re.descendingStringSort)((e=>e.id)))},$e=e=>1===lodash.get(e,"extra.is_reserve_recall",0),Oe="feeds.contentFilters";(0,be.registerData)(Oe,[]);const Ie=e=>{const[t]=(0,be.getData)(Oe);return t.reduce(((e,t)=>t.filter(e)),e)},Le=e=>(...t)=>e(...t).then((e=>Ie(e))),Te=Le((async(e="video")=>{if(!(0,X.getUID)())return[];const t=await(0,C.getJsonWithCredentials)(`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${"video"===e?8:512}`);if(0!==t.code)throw new Error(t.message);const n=t.data.cards,i=n.filter((e=>!$e(JSON.parse(e.card))));return"video"===e?Ae(n.map((e=>{const t=JSON.parse(e.card),n=lodash.get(e,"display.topic_info.topic_details",[]).map((e=>({id:e.topic_id,name:e.topic_name})));return{id:e.desc.dynamic_id_str,aid:t.aid,bvid:e.desc.bvid||t.bvid,title:t.title,upID:e.desc.user_profile.info.uid,upName:e.desc.user_profile.info.uname,upFaceUrl:e.desc.user_profile.info.face,coverUrl:t.pic,description:t.desc,timestamp:e.timestamp,time:new Date(1e3*e.timestamp),topics:n,dynamic:t.dynamic,like:(0,J.formatCount)(e.desc.like),duration:t.duration,durationText:(0,J.formatDuration)(t.duration,0),playCount:(0,J.formatCount)(t.stat.view),danmakuCount:(0,J.formatCount)(t.stat.danmaku),watchlater:me.includes(t.aid)}}))):"bangumi"===e?i.map((e=>{const t=JSON.parse(e.card);return{id:e.desc.dynamic_id_str,aid:t.aid,bvid:e.desc.bvid||t.bvid,epID:t.episode_id,title:t.new_desc,upName:t.apiSeasonInfo.title,upFaceUrl:t.apiSeasonInfo.cover,coverUrl:t.cover,description:"",timestamp:e.timestamp,time:new Date(1e3*e.timestamp),like:(0,J.formatCount)(e.desc.like),durationText:"",playCount:(0,J.formatCount)(t.play_count),danmakuCount:(0,J.formatCount)(t.bullet_count),watchlater:!1}})):[]})),Pe=async(e,t)=>{if("string"==typeof e)return(0,C.getJsonWithCredentials)(`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${e}`);const n=e.id.toString();let i=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${n}`;return t&&(i=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_history?uid=${(0,X.getUID)()}&offset_dynamic_id=${t}&type=${n}`),(0,C.getJsonWithCredentials)(i)},De=(e,t)=>{const n=dq(e.element,".more-panel"),{className:i,text:a,action:r}=t;if(!n||dq(n,`.${i}`))return;const o=document.createElement("p");o.classList.add("child-button","c-pointer",i),o.textContent=a;[...new Set([...n.children].map((e=>e.getAttributeNames().filter((e=>e.startsWith("data-v-"))))).flat())].forEach((e=>o.setAttribute(e,""))),o.addEventListener("click",(t=>{r(t),e.element.click()})),n.appendChild(o)};var Ve=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"bangumi-card",class:{new:e.isNew},attrs:{target:"_blank",href:e.data.url}},[n("div",{staticClass:"ep-cover-container"},[n("DpiImage",{staticClass:"ep-cover",attrs:{size:{width:100},src:e.data.epCoverUrl}})],1),e._v(" "),n("h1",{staticClass:"ep-title",attrs:{title:e.data.epTitle}},[e._v(e._s(e.data.epTitle))]),e._v(" "),n("div",{staticClass:"up",attrs:{title:e.data.title}},[n("DpiImage",{staticClass:"cover",attrs:{size:24,src:e.data.coverUrl}}),e._v(" "),n("div",{staticClass:"title"},[e._v(e._s(e.data.title))])],1)])};Ve._withStripped=!0;var Be=Vue.extend({components:{DpiImage:ce.DpiImage},props:{data:{type:Object,required:!0},isNew:{type:Boolean,default:!1}}}),Fe=n(3379),Ne=n.n(Fe),je=n(5478),qe=n.n(je),He={insert:"head",singleton:!1},Re=(Ne()(qe(),He),qe().locals,n(1900)),Ue=(0,Re.Z)(Be,Ve,[],!1,null,"3bc2da4f",null);Ue.options.__file="src/components/feeds/BangumiCard.vue";var Ze=Ue.exports,We=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"video-card",class:{vertical:"vertical"===e.orientation,"no-stats":!e.showStats},attrs:{target:"_blank",href:e.epID?"https://www.bilibili.com/bangumi/play/ep"+e.epID:"https://www.bilibili.com/"+e.bvid}},[n("div",{staticClass:"cover-container"},[n("DpiImage",{staticClass:"cover",attrs:{src:e.coverUrl,size:{height:120,width:200}}}),e._v(" "),e.isNew?n("div",{staticClass:"new"},[e._v("NEW")]):e._e(),e._v(" "),e.pubTime&&e.pubTimeText?[n("div",{staticClass:"publish-time-summary"},[e._v("\n "+e._s(e.pubTimeText)+"\n ")]),e._v(" "),n("div",{staticClass:"publish-time-detail"},[e._v("\n "+e._s(e.pubTime)+"\n ")])]:e._e(),e._v(" "),e.durationText?n("div",{staticClass:"duration"},[e._v(e._s(e.durationText))]):e._e(),e._v(" "),e.durationText&&null!==e.watchlater&&void 0!==e.watchlater?n("div",{staticClass:"watchlater",on:{click:function(t){return t.stopPropagation(),t.preventDefault(),e.toggleWatchlater(e.aid)}}},[n("VIcon",{attrs:{size:15,icon:e.watchlater?"mdi-check-circle":"mdi-clock-outline"}}),e._v("\n "+e._s(e.watchlater?"已添加":"稍后再看")+"\n ")],1):e._e()],2),e._v(" "),n("h1",{staticClass:"title",attrs:{title:e.title}},[e._v(e._s(e.title))]),e._v(" "),e.topics&&e.topics.length?n("div",{staticClass:"topics"},e._l(e.topics.slice(0,3),(function(t){return n("a",{key:t.id,staticClass:"topic",attrs:{target:"_blank",href:"https://t.bilibili.com/topic/name/"+t.name+"/feed"}},[e._v("#"+e._s(t.name)+"#")])})),0):n("p",{staticClass:"description",attrs:{title:e.description}},[e._v(e._s(e.description))]),e._v(" "),0===e.cooperation.length?n("a",{staticClass:"up",class:{"no-face":!e.upFaceUrl},attrs:{target:"_blank",href:e.upID?"https://space.bilibili.com/"+e.upID:null}},[e.upFaceUrl?n("DpiImage",{staticClass:"face",attrs:{src:e.upFaceUrl,size:24}}):n("VIcon",{attrs:{icon:"up"}}),e._v(" "),n("div",{staticClass:"name",attrs:{title:e.upName}},[e._v(e._s(e.upName))])],1):e._e(),e._v(" "),0!==e.cooperation.length?n("div",{staticClass:"cooperation"},[n("div",{staticClass:"cooperation-ups"},e._l(e.reversedCooperation,(function(e){return n("a",{key:e.id,staticClass:"cooperation-up",class:{"no-face":!e.faceUrl},attrs:{target:"_blank",title:e.name,href:e.id?"https://space.bilibili.com/"+e.id:null}},[e.faceUrl?n("DpiImage",{staticClass:"face",attrs:{src:e.faceUrl,size:24}}):n("VIcon",{attrs:{icon:"up"}})],1)})),0),e._v(" "),n("div",{staticClass:"cooperation-note"},[e._v("\n 联合投稿\n ")])]):e._e(),e._v(" "),e.showStats?n("div",{staticClass:"stats"},[e.like&&!e.vertical?[n("VIcon",{attrs:{icon:"like-outline",size:18}}),e._v("\n "+e._s(e.like)+"\n ")]:e._e(),e._v(" "),e.coins&&!e.vertical?[n("VIcon",{attrs:{icon:"coin-outline",size:18}}),e._v("\n "+e._s(e.coins)+"\n ")]:e._e(),e._v(" "),e.favorites?[n("VIcon",{attrs:{icon:"favorites-outline",size:18}}),e._v("\n "+e._s(e.favorites)+"\n ")]:e._e(),e._v(" "),e.playCount?[n("VIcon",{attrs:{icon:"play",size:18}}),e._v("\n "+e._s(e.playCount)+"\n ")]:e._e(),e._v(" "),e.danmakuCount?[n("VIcon",{attrs:{icon:"danmaku",size:18}}),e._v("\n "+e._s(e.danmakuCount)+"\n ")]:e._e()],2):e._e()])};We._withStripped=!0;var Ge={components:{DpiImage:ce.DpiImage,VIcon:ce.VIcon},props:{data:{type:Object,required:!0},orientation:{type:String,default:"horizontal"},showStats:{type:Boolean,default:!0},isNew:{type:Boolean,default:!1}},data(){return{watchlaterList:me,upFaceUrl:"",danmakuCount:"",like:"",coins:"",favorites:"",dynamic:"",topics:[],upID:0,epID:0,cooperation:[],...lodash.omit(this.data,"watchlater"),watchlaterInit:this.data.watchlater}},computed:{vertical(){return"vertical"===this.orientation},watchlater(){return(0,X.getUID)()&&null!==this.watchlaterInit?this.watchlaterList.includes(this.aid):null},reversedCooperation(){return[...this.cooperation].reverse().slice(0,3)}},methods:{toggleWatchlater:ve}},Xe=n(1745),Ke=n.n(Xe),Je={insert:"head",singleton:!1},Ye=(Ne()(Ke(),Je),Ke().locals,(0,Re.Z)(Ge,We,[],!1,null,"0ffa1cb1",null));Ye.options.__file="src/components/feeds/VideoCard.vue";var Qe=Ye.exports,et=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"column-card",attrs:{target:"_blank",href:"https://www.bilibili.com/read/cv"+e.data.cvID}},[n("div",{staticClass:"covers"},e._l(e.data.covers,(function(e){return n("DpiImage",{key:e,staticClass:"cover",attrs:{size:{height:120},src:e}})})),1),e._v(" "),n("a",{staticClass:"up",attrs:{target:"_blank",href:"https://space.bilibili.com/"+e.data.upID}},[n("DpiImage",{staticClass:"face",attrs:{size:24,src:e.data.upFaceUrl}}),e._v(" "),n("div",{staticClass:"name"},[e._v(e._s(e.data.upName))])],1),e._v(" "),n("h1",{staticClass:"title",attrs:{title:e.data.title}},[e._v(e._s(e.data.title))]),e._v(" "),n("div",{staticClass:"description",attrs:{title:e.data.description}},[e._v(e._s(e.data.description))])])};et._withStripped=!0;var tt=Vue.extend({components:{DpiImage:ce.DpiImage},props:{data:{type:Object,required:!0},isNew:{type:Boolean,default:!1}}}),nt=n(620),it=n.n(nt),at={insert:"head",singleton:!1},rt=(Ne()(it(),at),it().locals,(0,Re.Z)(tt,et,[],!1,null,null,null));rt.options.__file="src/components/feeds/ColumnCard.vue";var ot=rt.exports;let st=!1;const lt=()=>{"https://t.bilibili.com/"===document.URL.replace(window.location.search,"")&&(async()=>{const{select:e}=await Promise.resolve().then(n.bind(n,5550)),t=await e(".live-up-list");if(null!==t){const{getComponentSettings:e}=await Promise.resolve().then(n.bind(n,6171));if(st)return;const i=e("fixedSidebars"),a=e("extendFeedsLive");t.addEventListener("mouseenter",(e=>{(i.enabled||a.enabled)&&e.stopImmediatePropagation()}),{capture:!0}),st=!0}})()},ct=3e5,dt=()=>(0,X.getCookieValue)(`bp_t_offset_${(0,X.getUID)()}`),ut=(e,t)=>e===t?0:e.length>t.length?1:t.length>e.length?-1:e>t==!0?1:-1,pt=e=>{if(null==e)return;const t=dt();ut(e,t)<0||(document.cookie=`bp_t_offset_${(0,X.getUID)()}=${e};path=/;domain=.bilibili.com;max-age=2592000`)},ht=e=>ut(e,dt())>0,ft=e=>{const[t]=[...e.map((e=>e.id))].sort(ut).reverse();pt(t)},mt=async e=>{const t=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_num?rsp_type=1&uid=${(0,X.getUID)()}&update_num_dy_id=${dt()}&type_list=${e||xe}`,n=await(0,C.getJsonWithCredentials)(t);return 0!==n.code?0:lodash.get(n,"data.update_num",0)},gt=e=>{e.startsWith("#")&&(e=e.substring(1));return{red:e.substring(0,2),green:e.substring(2,4),blue:e.substring(4,6)}},vt=e=>{const{red:t,green:n,blue:i}=gt(e);return`\\c&H${i}${n}${t}&`.toUpperCase()},bt=(e,t=1)=>{const{red:n,green:i,blue:a}=gt(e);return`&H${Math.round(255*(1-t)).toString(16).padStart(2,"0")}${a}${i}${n}`.toUpperCase()},yt=e=>{let t=0,n=0;for(;e>=60;)e-=60,n++;for(;n>=60;)n-=60,t++;return`${t}:${String(n).padStart(2,"0")}:${(e=>{const[t,n="00"]=String(e).split(".");return`${t.padStart(2,"0")}.${n.substr(0,2).padEnd(2,"0")}`})(e)}`},wt=(e,t)=>[yt(e),yt(e+t)],xt=(e,t)=>[yt(e),yt(t)],_t=e=>{const t={"{":"{","}":"}","&":"&","<":"<",">":">",""":'"',"'":"'","\n":"\\N"};for(const[n,i]of Object.entries(t))e=e.replace(new RegExp(n,"g"),i);return e};var kt=n(7412);let Ct=!1;const St=e=>oe.playerUrls.some((e=>(0,X.matchUrlPattern)(e)))?async()=>{Ct||(te(".bilibili-player-video-btn-setting",".bilibili-player-video-btn-setting-wrap",{style:".bilibili-player-video-btn-setting-wrap { display: none !important }"}),Ct=!0);const t=await(0,j.select)(".bilibili-player-video-btn-setting-right-others-content-lightoff .bui-checkbox-input");t.checked=!e,(0,X.raiseEvent)(t,"change")}:X.none,Et=St(!0),Mt=St(!1);let zt;const At=[],$t=async e=>{await(0,j.hasVideo)()&&(0,I.videoChange)((async()=>{const t=await kt.playerAgent.query.video.danmaku();t&&((e,t)=>{zt&&zt.disconnect(),[zt]=(0,I.childListSubtree)(e,(e=>{e.forEach((e=>{e.addedNodes.forEach((e=>{if(e.nodeType===Node.TEXT_NODE){const n=e.parentElement,i=At.find((e=>e.element===n));if(!i)return;return i.text=e.textContent||"",i.reuse=!0,void(t.added&&t.added(i))}if(!(e instanceof HTMLElement))return;const n={element:i=e,reuse:!1,text:i.textContent||""};var i;At.push(n),t.added&&t.added(n)})),e.removedNodes.forEach((e=>{if(!(e instanceof HTMLElement))return;const n=At.findIndex((t=>t.element===e));if(-1!==n){const[e]=At.splice(n,1);t.removed&&t.removed(e)}}))}))}))})(t,e)}))};function Ot(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class It{constructor(e){Ot(this,"aid",void 0),Ot(this,"cid",void 0),Ot(this,"pageCount",void 0),Ot(this,"coverUrl",void 0),Ot(this,"tagId",void 0),Ot(this,"tagName",void 0),Ot(this,"title",void 0),Ot(this,"description",void 0),Ot(this,"up",void 0),Ot(this,"pages",void 0),Ot(this,"subtitles",void 0),this.aid=e}async fetchInfo(){let e;e=this.cid?`https://api.bilibili.com/x/web-interface/view?aid=${this.aid}&cid=${this.cid}`:`https://api.bilibili.com/x/web-interface/view?aid=${this.aid}`;const t=await(0,C.getJson)(e);if(0!==t.code)throw new Error(t.message);const{data:n}=t;return this.cid=n.cid,this.pageCount=n.videos,this.coverUrl=n.pic.replace("http:","https:"),this.tagId=n.tid,this.tagName=n.tname,this.title=n.title,this.description=n.desc,this.up={uid:n.owner.mid,name:n.owner.name,faceUrl:n.owner.face.replace("http:","https:")},this.pages=n.pages.map((e=>({cid:e.cid,title:e.part,pageNumber:e.page}))),this.subtitles=n.subtitle.list.map((e=>({id:e.id,languageCode:e.lan,language:e.lan_doc,url:e.subtitle_url.replace("http:","https:")}))),this}}class Lt{constructor(e){Ot(this,"ep",void 0),Ot(this,"videos",void 0),Ot(this,"title",void 0),Ot(this,"cover",void 0),Ot(this,"squareCover",void 0),Ot(this,"aid",void 0),Ot(this,"cid",void 0),this.ep=e,this.videos=[]}async fetchInfo(){const e=await(0,C.getText)(`https://www.bilibili.com/bangumi/play/ep${this.ep}/`),t=JSON.parse(e.match(/window\.__INITIAL_STATE__=(.*);\(function\(\){/)[1]);return this.title=t.mediaInfo.title,this.cover=t.mediaInfo.cover,this.squareCover=t.mediaInfo.square_cover,this.aid=t.epInfo.aid,this.cid=t.epInfo.cid,this.videos=t.epList.map((async e=>({title:e.index_title,aid:e.aid,cid:e.cid,info:await new It(e.aid).fetchInfo()}))),this}}const Tt=[{name:"720P",displayName:"高清 720P",value:64},{name:"1080P",displayName:"高清 1080P",value:80}],Pt=[{name:"HDR",displayName:"真彩 HDR",value:125},{name:"4K",displayName:"超清 4K",value:120},{name:"1080P60",displayName:"高清 1080P60",value:116},{name:"1080P+",displayName:"高清 1080P+",value:112},{name:"720P60",displayName:"高清 720P60",value:74}],Dt=[...Pt,...Tt,{name:"480P",displayName:"清晰 480P",value:32},{name:"360P",displayName:"流畅 360P",value:16}].sort((0,re.descendingSort)((e=>e.value))),Vt=async e=>{const{open:t,close:n}=e;if(!(0,j.hasVideo)())return;const i=await(0,j.select)(".bilibili-player");if(!i)return;const[a]=(0,I.childList)(i,(()=>{const e=dq(".bilibili-player-context-menu-origin");if(e){a.disconnect();const i=dq(e,"ul"),r={containerElement:e,listElement:i,get itemElements(){return dqa(e,".context-menu-function")},get isOpen(){return e.classList.contains("active")}};(0,I.childList)(i,(()=>{r.isOpen?t?.(r):n?.(r)}))}}))},Bt=async(e,t)=>Vt({open:t=>{if(t.listElement.contains(e))return;const n=document.createElement("li");n.classList.add("context-line","context-menu-function"),n.setAttribute("data-append","1");const i=document.createElement("a");i.classList.add("context-menu-a","js-action"),i.href="javascript:void(0);",i.appendChild(e),n.addEventListener("mouseover",(()=>n.classList.add("hover"))),n.addEventListener("mouseout",(()=>n.classList.remove("hover"))),n.appendChild(i),t.listElement.appendChild(n)},close:e=>t?.(e)});let Ft;const Nt=[],jt=lodash.once((async()=>{oe.playerUrls.some((e=>(0,X.matchUrlPattern)(e)))&&(0,I.videoChange)((async()=>{const{playerAgent:e}=await Promise.resolve().then(n.bind(n,7412)),t=await e.query.control.buttons.time();if(null===t)return;const i=await Promise.resolve().then(n.bind(n,135)).then((e=>e.default));Ft=new i({propsData:{items:Nt}}).$mount(),t.insertAdjacentElement("afterend",Ft.$el)}))})),qt=async e=>{Ft||await jt(),Nt.push(e)},Ht=async e=>{if(!oe.liveUrls.some((e=>(0,X.matchUrlPattern)(e))))return;const t=await(0,j.select)(".bilibili-live-player-video-controller, .web-player-controller-wrap:not(.web-player-controller-bg)");if(!t)return;const{init:n,callback:i}=e;n?.(t),(0,I.childList)(t,(async()=>{const e=dq(t,".control-area");e&&i?.(e)}))};function Rt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const Ut=0,Zt=2,Wt={heartBeat:2,heartBeatResponse:3,message:5,enterRoom:7,enterRoomResponse:8};class Gt{constructor(){Rt(this,"textEncoder",new TextEncoder),Rt(this,"textDecoder",new TextDecoder)}static readInt(e,t,n){let i=0;for(let a=n-1;a>=0;a--)i+=256**(n-a-1)*e[t+a];return i}static writeInt(e,t,n,i){let a=0;for(;a{const i={packetLength:Gt.readInt(e,0,4),headerLength:Gt.readInt(e,4,2),protocolVersion:Gt.readInt(e,6,2),operation:Gt.readInt(e,8,4),sequenceID:Gt.readInt(e,12,4)},a=[i];if(i.packetLengthe.messages[0])))}else i.protocolVersion===Ut&&(i.messages=[JSON.parse(this.textDecoder.decode(a))])}else i.operation===Wt.heartBeatResponse&&(i.heartBeatResponse={count:Gt.readInt(e,16,4)});return a};return new Promise(((n,i)=>{const a=new FileReader;a.onload=async e=>{if(!e.target)return void i(e);const a=new Uint8Array(e.target.result);n(await t(a))},a.readAsArrayBuffer(e)}))}}class Xt{constructor(){Rt(this,"startTime",0)}getLiveTime(){return new Promise((e=>{if(this.startTime)return void e(this.startTime);const t=(0,X.dq)(".bilibili-live-player-video-controller-duration-btn span"),[n]=(0,I.childList)(t,(t=>{if(t.length>0&&t.some((e=>e.addedNodes.length>0&&[...e.addedNodes].every((e=>e.nodeType===Node.TEXT_NODE))))){n.disconnect();const i=t[0].addedNodes[0].textContent,[a,r,o=0]=i.split(":").reverse().map(lodash.unary(parseInt)),s=Number(new Date);this.startTime=s-1e3*o*3600-60*r*1e3-1e3*a,e(this.startTime)}}))}))}}class Kt extends EventTarget{constructor(e){super(),this.roomID=e,Rt(this,"heartBeatTimer",void 0),Rt(this,"webSocket",void 0),Rt(this,"retryInterval",200),Rt(this,"autoRetry",!0),Rt(this,"servers",["broadcastlv.chat.bilibili.com"]),Rt(this,"selectedServer",""),Rt(this,"liveTime",new Xt),Rt(this,"bufferHelper",new Gt),Rt(this,"stopRequested",!1),window.addEventListener("unload",(()=>this.stop()))}heartBeat(){this.webSocket.readyState===WebSocket.OPEN?this.webSocket.send(this.bufferHelper.encode("","heartBeat")):(this.stop(),this.restart())}restart(){if(this.dispatchEvent(new CustomEvent("restart")),!this.stopRequested&&this.autoRetry){console.log(`Live Socket: unexpected disconnect, retry in ${this.retryInterval}ms`);const e=this.servers.indexOf(this.selectedServer);ethis.start()),this.retryInterval)}}async start(){const e=await(0,C.getJson)(`https://api.live.bilibili.com/room/v1/Danmu/getConf?room_id=${this.roomID}&platform=pc&player=web`),t=lodash.get(e,"data.host_server_list",[]);this.servers=[...new Set([...this.servers,...t.map((e=>e.host))])],""===this.selectedServer&&([this.selectedServer]=this.servers,console.log("Initial server:",this.selectedServer)),this.webSocket&&[WebSocket.CONNECTING,WebSocket.OPEN].includes(this.webSocket.readyState)&&this.stop(),this.webSocket=new WebSocket(`wss://${this.selectedServer}/sub`),this.stopRequested=!1,this.dispatchEvent(new CustomEvent("start",{detail:this.webSocket})),this.webSocket.addEventListener("open",(()=>{const t={roomid:this.roomID,uid:parseInt((0,X.getUID)()),protover:2,platform:"web",clientVer:"1.10.1",type:"2",key:lodash.get(e,"data.token")};this.webSocket.send(this.bufferHelper.encode(JSON.stringify(t),"enterRoom")),this.dispatchEvent(new CustomEvent("open",{detail:t}))})),this.webSocket.addEventListener("message",(async e=>{const[t]=await this.bufferHelper.decode(e.data);switch(this.dispatchEvent(new CustomEvent("message",{detail:t})),t.operation){case Wt.enterRoomResponse:this.heartBeatTimer&&clearInterval(this.heartBeatTimer),this.heartBeatTimer=window.setInterval((()=>{this.heartBeat()}),3e4);break;case Wt.heartBeatResponse:if(!t.heartBeatResponse)break;this.dispatchEvent(new CustomEvent("heartBeatResponse",{detail:t.heartBeatResponse.count}));break;case Wt.message:{if(!t.messages)break;const e=await this.liveTime.getLiveTime();t.messages.forEach((t=>{if("DANMU_MSG"===t.cmd){const{info:n}=t,i={content:n[1],type:n[0][1],fontSize:n[0][2],color:n[0][3],sendTime:n[0][4],userHash:n[0][7],userID:n[2][0],userName:n[2][1],startTime:e,get time(){return this.sendTime-this.startTime}};this.dispatchEvent(new CustomEvent("danmaku",{detail:i}))}}));break}}})),this.webSocket.addEventListener("close",(e=>{this.stopRequested||(console.error("Live Socket: close",e),this.restart())})),this.webSocket.addEventListener("error",(e=>{console.error("Live Socket: error",e),this.restart()}))}stop(){this.stopRequested=!0,this.heartBeatTimer&&clearInterval(this.heartBeatTimer),this.webSocket&&this.webSocket.readyState===WebSocket.OPEN&&this.webSocket.close()}}const Jt=[],Yt="bb-comment",Qt=[],en=[],tn=[],nn=e=>{const t=e.querySelector(".con .user .name"),n=e=>{const t=e.querySelector(".reply-face"),n=e.querySelector(".reply-con .user .name");return{id:e.getAttribute("data-id"),element:e,userID:t.getAttribute("data-usercard-mid"),userName:n.textContent,content:e.querySelector(".text-con").textContent,timeText:e.querySelector(".info .time").textContent,likes:parseInt(e.querySelector(".info .like span").textContent)}},i={id:e.getAttribute("data-id"),element:e,userID:t.getAttribute("data-usercard-mid"),userName:t.textContent,content:e.querySelector(".con .text").textContent,timeText:e.querySelector(".con .info .time").textContent,likes:parseInt(e.querySelector(".con .like span").textContent),replies:[]};if(dq(e,".reply-box .view-more")){const t=dq(e,".reply-box");(0,I.childList)(t,(t=>{i.replies=(0,X.dqa)(e,".reply-box .reply-item").map(n),0!==t.length&&i.onRepliesUpdate?.(i.replies)}))}else i.replies=(0,X.dqa)(e,".reply-box .reply-item").map(n);return i},an=e=>{if(e instanceof HTMLElement&&e.classList.contains(Yt)){const t={element:e,items:[]};Jt.push(t),(e=>{e.observer||(e.items=(0,X.dqa)(e.element,".list-item.reply-wrap").map(nn),e.items.forEach((e=>{Qt.forEach((t=>t(e)))})),[e.observer]=(0,I.childListSubtree)(e.element,(t=>{t.forEach((t=>{const n=e=>e instanceof HTMLElement&&e.classList.contains("list-item")&&e.classList.contains("reply-wrap");t.addedNodes.forEach((t=>{if(n(t)){const n=nn(t);e.items.push(n),Qt.forEach((e=>e(n)))}})),t.removedNodes.forEach((t=>{if(n(t)){const n=t.getAttribute("data-id"),i=e.items.findIndex((e=>e.id===n));if(-1!==i){const[t]=e.items.splice(i,1);en.forEach((e=>e(t)))}}}))}))})))})(t),tn.forEach((e=>e(t)))}};(0,A.contentLoaded)((()=>{(0,I.allMutations)((e=>{e.forEach((e=>{e.addedNodes.forEach((e=>an(e)))}))})),(0,X.dqa)(".bb-comment").forEach(an)}));const rn=e=>{Jt.forEach((t=>e(t))),tn.push(e)},on=e=>{const{added:t,removed:n}=e;rn((e=>{t&&(e.items.forEach((e=>t(e))),Qt.push(t)),n&&en.push(n)}))},sn=(e,t)=>{const n=dq(e.element,".opera-list ul"),{className:i,text:a,action:r}=t;if(!n||dq(n,`.${i}`))return;const o=document.createElement("li");o.classList.add(i),o.textContent=a,o.addEventListener("click",(e=>{r(e)})),n.appendChild(o)};var ln=n(2149);const cn=JSON.parse('[[{"name":"首页","route":"/","tid":"","locid":23,"sub":[]},{"name":"动画","route":"douga","tid":1,"locid":52,"count":"","subMenuSize":162,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2507,"leftId":2452,"rightId":2453},"sub":[{"name":"MAD·AMV","route":"mad","tid":24,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":151},"desc":"具有一定制作程度的动画或静画的二次创作视频","url":"//www.bilibili.com/video/douga-mad-1.html"},{"name":"MMD·3D","route":"mmd","tid":25,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":152},"desc":"使用MMD(MikuMikuDance)和其他3D建模类软件制作的视频","url":"//www.bilibili.com/video/douga-mmd-1.html"},{"name":"短片·手书·配音","route":"voice","tid":47,"ps":15,"rps":10,"desc":"追求创新并具有强烈特色的短片、手书(绘)及ACG相关配音","url":"//www.bilibili.com/video/douga-voice-1.html"},{"name":"手办·模玩","route":"garage_kit","tid":210,"ps":15,"rps":10,"desc":"手办模玩的测评、改造或其他衍生内容","url":""},{"name":"特摄","route":"tokusatsu","tid":86,"ps":15,"rps":10,"desc":"特摄相关衍生视频","url":"//www.bilibili.com/video/cinephile-tokusatsu.html"},{"name":"综合","route":"other","tid":27,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":153},"desc":"以动画及动画相关内容为素材,包括但不仅限于音频替换、杂谈、排行榜等内容","url":"//www.bilibili.com/video/douga-else-1.html"}]},{"name":"番剧","route":"anime","tid":13,"url":"//www.bilibili.com/anime/","takeOvered":true,"count":"","subMenuSize":172,"combination":true,"sub":[{"name":"连载动画","tid":33,"route":"serial","desc":"当季连载的动画番剧","url":"//www.bilibili.com/video/bangumi-two-1.html"},{"name":"完结动画","tid":32,"route":"finish","desc":"已完结的动画番剧合集","url":"//www.bilibili.com/video/part-twoelement-1.html"},{"name":"资讯","tid":51,"route":"information","desc":"动画番剧相关资讯视频","url":"//www.bilibili.com/video/douga-else-information-1.html"},{"name":"官方延伸","tid":152,"route":"offical","desc":"动画番剧为主题的宣传节目、采访视频,及声优相关视频","url":"//www.bilibili.com/video/bagumi_offical_1.html"},{"name":"新番时间表","url":"//www.bilibili.com/anime/timeline/","desc":""},{"name":"番剧索引","url":"//www.bilibili.com/anime/index/","desc":""}]},{"name":"国创","tid":167,"route":"guochuang","url":"//www.bilibili.com/guochuang/","takeOvered":true,"count":"","subMenuSize":214,"combination":true,"sub":[{"name":"国产动画","tid":153,"route":"chinese","desc":"我国出品的PGC动画","url":"//www.bilibili.com/video/bangumi_chinese_1.html"},{"name":"国产原创相关","tid":168,"route":"original","desc":"","url":"//www.bilibili.com/video/guochuang-fanvid-1.html"},{"name":"布袋戏","tid":169,"route":"puppetry","desc":"","url":"//www.bilibili.com/video/glove-puppetry-1.html"},{"name":"动态漫·广播剧","tid":195,"route":"motioncomic","desc":"","url":""},{"name":"资讯","tid":170,"route":"information","desc":"","url":"//www.bilibili.com/video/guochuang-offical-1.html"},{"name":"新番时间表","url":"//www.bilibili.com/guochuang/timeline/","desc":""},{"name":"国产动画索引","url":"//www.bilibili.com/guochuang/index/","desc":""}]},{"name":"音乐","route":"music","tid":3,"locid":58,"count":"","subMenuSize":268,"slider":{"width":620,"height":220},"viewTag":true,"customComponent":{"name":"Energy","titleId":2511,"leftId":2462,"rightId":3131,"rightType":"slide"},"sub":[{"name":"原创音乐","route":"original","tid":28,"ps":15,"rps":10,"viewHotTag":true,"ad":{"active":true,"dataLocId":243},"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"个人或团队制作以音乐为主要原创因素的歌曲或纯音乐","url":"//www.bilibili.com/video/music-original-1.html"},{"name":"翻唱","route":"cover","tid":31,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":245},"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"一切非官方的人声再演绎歌曲作品","url":"//www.bilibili.com/video/music-Cover-1.html"},{"name":"VOCALOID·UTAU","route":"vocaloid","tid":30,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"以雅马哈Vocaloid和UTAU引擎为基础,包含其他调教引擎,运用各类音源进行的歌曲创作内容","url":"//www.bilibili.com/video/music-vocaloid-1.html"},{"name":"电音","route":"electronic","tid":194,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"以电子合成器、音乐软体等产生的电子声响制作的音乐","url":"#"},{"name":"演奏","route":"perform","tid":59,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":247},"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"传统或非传统乐器及器材的演奏作品","url":"//www.bilibili.com/video/music-perform-1.html"},{"name":"MV","route":"mv","tid":193,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"音乐录影带,为搭配音乐而拍摄或制作的视频","url":"//www.bilibili.com/video/music-coordinate-1.html"},{"name":"音乐现场","route":"live","tid":29,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"音乐实况表演视频","url":"//www.bilibili.com/video/music-oped-1.html"},{"name":"音乐综合","route":"other","tid":130,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"收录无法定义到其他音乐子分区的音乐视频","url":"//www.bilibili.com/video/music-collection-1.html"},{"name":"音频","customZone":"Audio","route":"audio","url":"//www.bilibili.com/audio/home?musicType=music"},{"name":"说唱","url":"//www.bilibili.com/v/rap"}]},{"name":"舞蹈","route":"dance","tid":129,"locid":64,"count":"","subMenuSize":172,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2513,"leftId":2472,"rightId":2473},"sub":[{"name":"宅舞","route":"otaku","tid":20,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":249},"desc":"与ACG相关的翻跳、原创舞蹈","url":"//www.bilibili.com/video/dance-1.html"},{"name":"街舞","route":"hiphop","tid":198,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":251},"desc":"收录街舞相关内容,包括赛事现场、舞室作品、个人翻跳、FREESTYLE等","url":""},{"name":"明星舞蹈","route":"star","tid":199,"ps":15,"rps":10,"desc":"国内外明星发布的官方舞蹈及其翻跳内容","url":""},{"name":"中国舞","route":"china","tid":200,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":253},"desc":"传承中国艺术文化的舞蹈内容,包括古典舞、民族民间舞、汉唐舞、古风舞等","url":""},{"name":"舞蹈综合","route":"three_d","tid":154,"ps":15,"rps":10,"desc":"收录无法定义到其他舞蹈子分区的舞蹈视频","url":""},{"name":"舞蹈教程","route":"demo","tid":156,"ps":10,"rps":6,"desc":"镜面慢速,动作分解,基础教程等具有教学意义的舞蹈视频","url":"//www.bilibili.com/video/dance-demo-1.html"}]},{"name":"游戏","route":"game","tid":4,"locid":70,"count":"","subMenuSize":240,"slider":{"width":470,"height":216},"viewTag":true,"customComponent":{"name":"Energy","titleId":3761,"leftId":3765,"rightId":3775,"rightType":"slide"},"recommendCardType":"GameGroomBox","sub":[{"name":"单机游戏","route":"stand_alone","tid":17,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":255},"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"以所有平台(PC、主机、移动端)的单机或联机游戏为主的视频内容,包括游戏预告、CG、实况解说及相关的评测、杂谈与视频剪辑等","url":"//www.bilibili.com/video/videogame-1.html"},{"name":"电子竞技","route":"esports","tid":171,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":257},"desc":"具有高对抗性的电子竞技游戏项目,其相关的赛事、实况、攻略、解说、短剧等视频。","url":"//www.bilibili.com/video/esports-1.html"},{"name":"手机游戏","route":"mobile","tid":172,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"desc":"以手机及平板设备为主要平台的游戏,其相关的实况、攻略、解说、短剧、演示等视频。","url":"//www.bilibili.com/video/mobilegame-1.html"},{"name":"网络游戏","route":"online","tid":65,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":259},"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"由网络运营商运营的多人在线游戏,以及电子竞技的相关游戏内容。包括赛事、攻略、实况、解说等相关视频","url":"//www.bilibili.com/video/onlinegame-1.html"},{"name":"桌游棋牌","route":"board","tid":173,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"desc":"桌游、棋牌、卡牌对战等及其相关电子版游戏的实况、攻略、解说、演示等视频。","url":"//www.bilibili.com/video/boardgame-1.html"},{"name":"GMV","route":"gmv","tid":121,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"由游戏素材制作的MV视频。以游戏内容或CG为主制作的,具有一定创作程度的MV类型的视频","url":"//www.bilibili.com/video/gmv-1.html"},{"name":"音游","route":"music","tid":136,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"各个平台上,通过配合音乐与节奏而进行的音乐类游戏视频","url":"//www.bilibili.com/video/music-game-1.html"},{"name":"Mugen","route":"mugen","tid":19,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"以Mugen引擎为平台制作、或与Mugen相关的游戏视频","url":"//www.bilibili.com/video/game-mugen-1.html"},{"name":"游戏赛事","url":"//www.bilibili.com/v/game/match/","newIcon":true}]},{"name":"知识","route":"knowledge","tid":36,"locid":76,"count":"","subMenuSize":172,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2058,"leftId":2047,"rightId":2048},"sub":[{"name":"科学科普","route":"science","tid":201,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":261},"desc":"回答你的十万个为什么"},{"name":"社科·法律·心理","route":"social_science","tid":124,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":263},"desc":"基于社会科学、法学、心理学展开或个人观点输出的知识视频"},{"name":"人文历史","route":"humanity_history","tid":228,"ps":15,"rps":10,"desc":"看看古今人物,聊聊历史过往,品品文学典籍"},{"name":"财经商业","route":"business","tid":207,"ps":15,"rps":10,"desc":"说金融市场,谈宏观经济,一起畅聊商业故事"},{"name":"校园学习","route":"campus","tid":208,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":265},"desc":"老师很有趣,学生也有才,我们一起搞学习"},{"name":"职业职场","route":"career","tid":209,"ps":15,"rps":10,"desc":"职业分享、升级指南,一起成为最有料的职场人"},{"name":"设计·创意","route":"design","tid":229,"ps":15,"rps":10,"desc":"天马行空,创意设计,都在这里"},{"name":"野生技能协会","route":"skill","tid":122,"ps":15,"rps":10,"desc":"技能党集合,是时候展示真正的技术了"}]},{"name":"科技","route":"tech","tid":188,"locid":2977,"count":"","subMenuSize":80,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2980,"leftId":2978,"rightId":2979},"sub":[{"name":"数码","route":"digital","tid":95,"ps":15,"rps":10,"viewHotTag":true,"desc":"科技数码产品大全,一起来做发烧友","url":"#"},{"name":"软件应用","route":"application","tid":230,"ps":15,"rps":10,"viewHotTag":true,"desc":"超全软件应用指南","url":"#"},{"name":"计算机技术","route":"computer_tech","tid":231,"ps":15,"rps":10,"viewHotTag":true,"desc":"研究分析、教学演示、经验分享......有关计算机技术的都在这里","url":"#"},{"name":"工业·工程·机械","route":"industry","tid":232,"ps":15,"rps":10,"viewHotTag":true,"desc":"前方高能,机甲重工即将出没","url":"#"},{"name":"极客DIY","route":"diy","tid":233,"ps":15,"rps":10,"viewHotTag":true,"desc":"炫酷技能,极客文化,硬核技巧,准备好你的惊讶","url":"#"}]},{"name":"运动","route":"sports","tid":234,"locid":4639,"isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4646,"rightId":4652,"rightType":"slide"},"sub":[{"name":"篮球·足球","route":"basketballfootball","tid":235,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4656},"desc":"与篮球、足球相关的视频,包括但不限于篮足球赛事、教学、评述、剪辑、剧情等相关内容","url":"#"},{"name":"健身","route":"aerobics","tid":164,"ps":15,"rps":10,"desc":"与健身相关的视频,包括但不限于瑜伽、CrossFit、健美、力量举、普拉提、街健等相关内容","url":"//www.bilibili.com/video/fashion-body-1.html"},{"name":"竞技体育","route":"athletic","tid":236,"ps":15,"rps":10,"desc":"与竞技体育相关的视频,包括但不限于乒乓、羽毛球、排球、赛车等竞技项目的赛事、评述、剪辑、剧情等相关内容","url":"#"},{"name":"运动文化","route":"culture","tid":237,"ps":15,"rps":10,"desc":"与运动文化相关的视频,包络但不限于球鞋、球衣、球星卡等运动衍生品的分享、解读,体育产业的分析、科普等相关内容","url":"#"},{"name":"运动综合","route":"comprehensive","tid":238,"ps":15,"rps":10,"desc":"与运动综合相关的视频,包括但不限于钓鱼、骑行、滑板等日常运动分享、教学、Vlog等相关内容","url":"#"}]},{"name":"汽车","route":"car","tid":223,"locid":4428,"isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4435,"rightId":4441,"rightType":"slide"},"sub":[{"name":"汽车生活","route":"life","tid":176,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4445},"desc":"分享汽车及出行相关的生活体验类视频","url":"#"},{"name":"汽车文化","route":"culture","tid":224,"ps":15,"rps":10,"desc":"车迷的精神圣地,包括汽车赛事、品牌历史、汽车改装、经典车型和汽车模型等","url":"#"},{"name":"汽车极客","route":"geek","tid":225,"ps":15,"rps":10,"desc":"汽车硬核达人聚集地,包括DIY造车、专业评测和技术知识分享","url":"#"},{"name":"智能出行","route":"smart","tid":226,"ps":15,"rps":10,"desc":"探索新能源汽车和未来智能出行的前沿阵地","url":"#"},{"name":"购车攻略","route":"strategy","tid":227,"ps":15,"rps":10,"desc":"丰富详实的购车建议和新车体验","url":"#"}]},{"name":"生活","route":"life","tid":160,"locid":88,"count":"","subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2062,"leftId":1674,"rightId":1670},"sub":[{"name":"搞笑","route":"funny","tid":138,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":273},"desc":"各种沙雕有趣的搞笑剪辑,挑战,表演,配音等视频","url":"//www.bilibili.com/video/ent_funny_1.html","locid":4204,"recommendId":4210,"slider":{"width":620,"height":220},"customComponent":{"name":"Energy","leftId":4212,"rightId":4218,"rightType":"slide"}},{"name":"家居房产","route":"home","tid":239,"ps":15,"rps":10,"desc":"与买房、装修、居家生活相关的分享","url":"#"},{"name":"手工","route":"handmake","tid":161,"ps":15,"rps":10,"desc":"手工制品的制作过程或成品展示、教程、测评类视频","url":"//www.bilibili.com/video/ent-handmake-1.html"},{"name":"绘画","route":"painting","tid":162,"ps":15,"rps":10,"desc":"绘画过程或绘画教程,以及绘画相关的所有视频","url":"//www.bilibili.com/video/ent-painting-1.html"},{"name":"日常","route":"daily","tid":21,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":275},"desc":"记录日常生活,分享生活故事","url":"//www.bilibili.com/video/ent-life-1.html"},{"name":"其他","route":"other","tid":174,"ps":15,"rps":10,"desc":"对分区归属不明的视频进行归纳整合的特定分区","url":"//www.bilibili.com/video/others-1.html"}]},{"name":"美食","route":"food","tid":211,"locid":4243,"count":"","isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4258,"rightId":4264},"sub":[{"name":"美食制作","route":"make","tid":76,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4268},"desc":"学做人间美味,展示精湛厨艺","url":"#"},{"name":"美食侦探","route":"detective","tid":212,"ps":15,"rps":10,"desc":"寻找美味餐厅,发现街头美食","url":"#"},{"name":"美食测评","route":"measurement","tid":213,"ps":15,"rps":10,"desc":"吃货世界,品尝世间美味","url":"#"},{"name":"田园美食","route":"rural","tid":214,"ps":15,"rps":10,"desc":"品味乡野美食,寻找山与海的味道","url":"#"},{"name":"美食记录","route":"record","tid":215,"ps":15,"rps":10,"desc":"记录一日三餐,给生活添一点幸福感","url":"#"}]},{"name":"动物圈","route":"animal","tid":217,"locid":4365,"count":"","isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4376,"rightId":4381,"rightType":"slide"},"sub":[{"name":"喵星人","route":"cat","tid":218,"ps":15,"rps":10,"desc":"喵喵喵喵喵","url":"#","ad":{"active":true,"dataLocId":4385}},{"name":"汪星人","route":"dog","tid":219,"ps":15,"rps":10,"desc":"汪汪汪汪汪","url":"#"},{"name":"大熊猫","route":"panda","tid":220,"ps":15,"rps":10,"desc":"芝麻汤圆营业中","url":"#"},{"name":"野生动物","route":"wild_animal","tid":221,"ps":15,"rps":10,"desc":"内有“猛兽”出没","url":"#"},{"name":"爬宠","route":"reptiles","tid":222,"ps":15,"rps":10,"desc":"鳞甲有灵","url":"#"},{"name":"动物综合","route":"animal_composite","tid":75,"ps":15,"rps":10,"desc":"收录除上述子分区外,其余动物相关视频以及非动物主体或多个动物主体的动物相关延伸内容","url":"#"}]},{"name":"鬼畜","route":"kichiku","tid":119,"locid":100,"count":"","subMenuSize":182,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2509,"leftId":2482,"rightId":2483},"sub":[{"name":"鬼畜调教","route":"guide","tid":22,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":285},"desc":"使用素材在音频、画面上做一定处理,达到与BGM一定的同步感","url":"//www.bilibili.com/video/ent-Kichiku-1.html"},{"name":"音MAD","route":"mad","tid":26,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":287},"desc":"使用素材音频进行一定的二次创作来达到还原原曲的非商业性质稿件","url":"//www.bilibili.com/video/douga-kichiku-1.html"},{"name":"人力VOCALOID","route":"manual_vocaloid","tid":126,"ps":15,"rps":10,"desc":"将人物或者角色的无伴奏素材进行人工调音,使其就像VOCALOID一样歌唱的技术","url":"//www.bilibili.com/video/kichiku-manual_vocaloid-1.html"},{"name":"鬼畜剧场","route":"theatre","tid":216,"ps":15,"rps":10,"desc":"使用素材进行人工剪辑编排的有剧情的作品"},{"name":"教程演示","route":"course","tid":127,"ps":10,"rps":6,"rightComponent":{"name":"CmImgList","id":148},"ad":{"active":true,"dataLocId":289},"hideDropdown":false,"desc":"鬼畜相关的教程演示","url":"//www.bilibili.com/video/kichiku-course-1.html"}]},{"name":"时尚","route":"fashion","tid":155,"locid":94,"count":"","subMenuSize":124,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2515,"leftId":2492,"rightId":2493},"sub":[{"name":"美妆","route":"makeup","tid":157,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":279},"desc":"涵盖妆容、发型、美甲等教程,彩妆、护肤相关产品测评、分享等","url":"//www.bilibili.com/video/fashion-makeup-fitness-1.html"},{"name":"服饰","route":"clothing","tid":158,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":281},"desc":"服饰风格、搭配技巧相关的展示和教程视频","url":"//www.bilibili.com/video/fashion-clothing-1.html"},{"name":"T台","route":"catwalk","tid":159,"ps":15,"rps":10,"desc":"发布会走秀现场及模特相关时尚片、采访、后台花絮","url":"#"},{"name":"风尚标","route":"trends","tid":192,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":283},"desc":"时尚明星专访、街拍、时尚购物相关知识科普","url":"#"}]},{"name":"资讯","route":"information","tid":202,"locid":4076,"count":"","subMenuSize":60,"slider":{"width":620,"height":220},"viewTag":false,"sub":[{"name":"热点","route":"hotspot","tid":203,"ps":18,"rps":10,"desc":"全民关注的时政热门资讯"},{"name":"环球","route":"global","tid":204,"ps":18,"rps":10,"desc":"全球范围内发生的具有重大影响力的事件动态"},{"name":"社会","route":"social","tid":205,"ps":18,"rps":10,"desc":"日常生活的社会事件、社会问题、社会风貌的报道"},{"name":"综合","route":"multiple","tid":206,"ps":18,"rps":10,"desc":"除上述领域外其它垂直领域的综合资讯"}]},{"name":"娱乐","route":"ent","tid":5,"locid":82,"count":"","subMenuSize":62,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2067,"leftId":2065,"rightId":2066},"sub":[{"name":"综艺","route":"variety","tid":71,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":267},"desc":"国内外有趣的综艺和综艺相关精彩剪辑","url":"//www.bilibili.com/video/ent-variety-1.html"},{"name":"明星","route":"star","tid":137,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":269},"desc":"娱乐圈动态、明星资讯相关","url":"//www.bilibili.com/video/ent-circle-1.html"}]},{"name":"影视","route":"cinephile","tid":181,"locid":2211,"count":"","subMenuSize":84,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2309,"leftId":2307,"rightId":2308},"sub":[{"name":"影视杂谈","route":"cinecism","tid":182,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2212},"desc":"影视评论、解说、吐槽、科普等","url":"//www.bilibili.com/video/cinephile-cinecism.html"},{"name":"影视剪辑","route":"montage","tid":183,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2213},"desc":"对影视素材进行剪辑再创作的视频","url":"//www.bilibili.com/video/cinephile-montage.html"},{"name":"短片","route":"shortfilm","tid":85,"ps":15,"rps":10,"desc":"追求自我表达且具有特色的短片","url":"//www.bilibili.com/video/cinephile-shortfilm.html"},{"name":"预告·资讯","route":"trailer_info","tid":184,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2214},"desc":"影视类相关资讯,预告,花絮等视频","url":"//www.bilibili.com/video/cinephile-trailer-info.html"}]},{"name":"纪录片","route":"documentary","tid":177,"url":"//www.bilibili.com/documentary/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"人文·历史","tid":37,"route":"history","dise":"","url":"//www.bilibili.com/video/doco-history.html"},{"name":"科学·探索·自然","tid":178,"route":"science","dise":"","url":"//www.bilibili.com/video/doco-science.html"},{"name":"军事","tid":179,"route":"military","dise":"","url":"//www.bilibili.com/video/doco-military.html"},{"name":"社会·美食·旅行","tid":180,"route":"travel","dise":"","url":"//www.bilibili.com/video/doco-travel.html"},{"name":"纪录片索引","url":"//www.bilibili.com/documentary/index/"}]},{"name":"电影","route":"movie","tid":23,"url":"//www.bilibili.com/movie/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"华语电影","tid":147,"route":"chinese","desc":"","url":"//www.bilibili.com/video/movie_chinese_1.html"},{"name":"欧美电影","tid":145,"route":"west","desc":"","url":"//www.bilibili.com/video/movie_west_1.html"},{"name":"日本电影","tid":146,"route":"japan","desc":"","url":"//www.bilibili.com/video/movie_japan_1.html"},{"name":"其他国家","tid":83,"route":"movie","desc":"","url":"//www.bilibili.com/video/movie-movie-1.html"},{"name":"电影索引","url":"//www.bilibili.com/movie/index/"}]},{"name":"电视剧","route":"tv","tid":11,"url":"//www.bilibili.com/tv/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"国产剧","tid":185,"route":"mainland","desc":"","url":"//www.bilibili.com/video/tv-mainland.html"},{"name":"海外剧","tid":187,"route":"overseas","desc":"","url":"//www.bilibili.com/video/tv-overseas.html"},{"name":"电视剧索引","url":"//www.bilibili.com/tv/index/"}]}],[{"url":"//live.bilibili.com/all?visit_id=5icxsa0kmts0","name":"全部直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=2&areaId=0&visit_id=5icxsa0kmts0#/2/0","name":"网游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=3&areaId=0&visit_id=5icxsa0kmts0#/3/0","name":"手游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=6&areaId=0","name":"单机直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=1&areaId=0&visit_id=5icxsa0kmts0#/1/0","name":"娱乐直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=5&areaId=0&visit_id=5icxsa0kmts0#/5/0","name":"电台直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=9&areaId=0","name":"虚拟直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=10&areaId=0","name":"生活直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=11&areaId=0","name":"学习直播"}],[{"name":"会员购","url":"//show.bilibili.com/platform/home.html","icon":"icon-vip-buy"},{"name":"游戏中心","url":"//game.bilibili.com","icon":"icon-game"},{"name":"画友","url":"http://h.bilibili.com","icon":"icon-hy"},{"name":"芒果TV","url":"//www.bilibili.com/mango","icon":"icon-mango"}],[{"name":"专栏","report":"article","url":"//www.bilibili.com/read/home","icon":"read"},{"name":"直播","report":"live","url":"//live.bilibili.com","icon":"live","sub":[{"url":"//live.bilibili.com/all?visit_id=5icxsa0kmts0","name":"全部直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=2&areaId=0&visit_id=5icxsa0kmts0#/2/0","name":"网游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=3&areaId=0&visit_id=5icxsa0kmts0#/3/0","name":"手游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=6&areaId=0","name":"单机直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=1&areaId=0&visit_id=5icxsa0kmts0#/1/0","name":"娱乐直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=5&areaId=0&visit_id=5icxsa0kmts0#/5/0","name":"电台直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=9&areaId=0","name":"虚拟直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=10&areaId=0","name":"生活直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=11&areaId=0","name":"学习直播"}]},{"name":"活动","report":"activity","url":"//www.bilibili.com/blackboard/activity-list.html","icon":"activit"},{"name":"课堂","report":"cheese","url":"//www.bilibili.com/cheese/","icon":"zhishi"},{"name":"小黑屋","report":"blackroom","url":"//www.bilibili.com/blackroom/","icon":"blackroom"},{"name":"新歌热榜","report":"musicplus","url":"//www.bilibili.com/v/musicplus/","icon":"musicplus"}],[{"name":"搞笑","url":"//www.bilibili.com/v/life/funny","tid":138,"count":"","hidePopover":true,"combination":true},{"name":"美食","url":"//www.bilibili.com/v/food","tid":211,"count":"","hidePopover":true,"combination":true},{"name":"动物圈","url":"//www.bilibili.com/v/animal","tid":217,"count":"","hidePopover":true,"combination":true},{"name":"单机游戏","url":"//www.bilibili.com/v/game/stand_alone","tid":17,"count":"","hidePopover":true,"combination":true},{"name":"运动","url":"//www.bilibili.com/v/sports","tid":234,"count":"","hidePopover":true,"combination":true},{"name":"汽车","url":"//www.bilibili.com/v/car","tid":223,"count":"","hidePopover":true,"combination":true},{"name":"VLOG","url":"//www.bilibili.com/v/life/daily/#/530003","hidePopover":true,"hideCount":true,"combination":true}]]'),dn=e=>e.startsWith("//")?`https:${e}`:e.replace("http:","https:"),un=cn[0].filter((e=>"string"!=typeof e.tid)),pn=cn[3],hn={},fn=["纪录片","电影","电视剧"];un.forEach((e=>{const t=dn(e.url||`https://www.bilibili.com/v/${e.route}/`);hn[e.name]={icon:e.route,code:e.tid,link:t,subCategories:e.sub?Object.fromEntries(e.sub.map((e=>{const n=dn(`${t}${e.route}/`);return[e.name,n]}))):null}})),hn.放映厅={icon:"cinema",code:fn.map((e=>hn[e].code)),link:"https://www.bilibili.com/cinema/",subCategories:Object.fromEntries(fn.map((e=>[e,hn[e].link])))},fn.forEach((e=>delete hn[e])),pn.forEach((e=>{hn[e.name]={icon:e.icon,code:null,link:dn(e.url),subCategories:e.sub?Object.fromEntries(e.sub.map((e=>[e.name,dn(e.url)]))):null}}));const mn=hn,gn=Object.fromEntries(un.map((e=>[e.route,e.tid]))),vn=Object.fromEntries(Object.values(hn).map((e=>[e.icon,e.link]))),bn=async()=>{if(document.getElementById("be-category-icons"))return;const{default:e}=await Promise.resolve().then(n.bind(n,382));document.body.insertAdjacentHTML("beforeend",e)};var yn=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"translate-container"},[e.working||e.translated?e._e():n("div",{staticClass:"translate",on:{click:function(t){return e.translate()}}},[n("VIcon",{attrs:{size:14,icon:"mdi-earth"}}),e._v("翻译\n ")],1),e._v(" "),e.translated?n("div",{staticClass:"translated"},[n("a",{attrs:{href:e.activeTranslator&&e.activeTranslator.link,target:"_blank"}},[e._v("\n 翻译自\n ")]),e._v(" "),n("VDropdown",{attrs:{items:Object.values(e.translateProviders),value:e.activeTranslator,"key-mapper":function(e){return e.name}},on:{change:function(t){return e.changeTranslator(t)}},scopedSlots:e._u([{key:"item",fn:function(t){var n=t.item;return[e._v("\n "+e._s(n.name)+"\n ")]}}],null,!1,1956376614)})],1):e._e(),e._v(" "),e.working?n("VIcon",{staticClass:"translating mdi-spin",attrs:{size:18,icon:"mdi-loading"}}):e._e(),e._v(" "),!e.working&&e.translated?n("div",{staticClass:"translate-result",domProps:{textContent:e._s(e.result)}}):e._e()],1)};yn._withStripped=!0;var wn=n(1993),xn=Vue.extend({components:{VDropdown:ce.VDropdown,VIcon:ce.VIcon},props:{text:{type:String,required:!0}},data:()=>({result:"",working:!1,translateProviders:wn.WK,activeTranslator:{}}),computed:{translated(){return""!==this.result}},methods:{changeTranslator(e){(0,R.getComponentSettings)("i18n").options.translator=e.name,this.translate()},async translate(){try{this.working=!0;const e=this.text.replace(/#(.+?)#/g,"");this.activeTranslator=(0,wn.Ty)();const t=this.activeTranslator;this.result=await t.translate(e)}catch(e){(0,ae.logError)(e)}finally{this.working=!1}}}}),_n=n(4618),kn=n.n(_n),Cn={insert:"head",singleton:!1},Sn=(Ne()(kn(),Cn),kn().locals,(0,Re.Z)(xn,yn,[],!1,null,null,null));Sn.options.__file="src/components/i18n/machine-translator/MachineTranslator.vue";var En=Sn.exports;const Mn=e=>{void 0===e.radio&&(e.radio=!1);const{name:t,switches:i}=e,a={};return Object.entries(i).forEach((([e,{displayName:t,defaultValue:n}])=>{a[`switch-${e}`]={defaultValue:n,displayName:t,hidden:!0}})),i=>{const r=`${i.displayName}选项`,o={componentName:i.name,optionDisplayName:r};Object.assign(e,o),a[t]={defaultValue:e,displayName:r},i.options={...i.options,...a},i.widget||(i.widget={component:()=>Promise.resolve().then(n.bind(n,8769)).then((e=>e.default)),options:e});const s=i.entry;return i.entry=async(...e)=>{s?.(...e);const{name:t}=i,n=(0,R.getComponentSettings)(t).options;Object.keys(n).forEach((e=>{e.startsWith("switch-")&&(0,R.addComponentListener)(`${t}.${e}`,(n=>{document.body.classList.toggle(`${t}-${e}`,n)}),!0)}))},i}};const zn={component:de,userComponent:ue,styledComponent:s,description:fe,switchOptions:k,launchBar:{LaunchBar:n(3059).Z},feeds:{api:c,BangumiCard:Ze,VideoCard:Qe,ColumnCard:ot,disableProfilePopup:d,notify:u},video:{assUtils:p,playerLight:h,playerAgent:kt,videoDanmaku:f,videoInfo:m,videoQuality:g,videoContextMenu:v,videoControlBar:b,watchlater:l},live:{liveControlBar:y,liveSocket:w},utils:{commentApis:x,categories:{updater:ln,data:_}},i18N:{machineTranslator:{MachineTranslator:En}}};var An=n(8900),$n=n(1623),On=n(9543);const In={style:An,plugin:$n,data:be,hook:On},Ln={ajax:C,cdnTypes:S,download:E,externalInput:M,filePicker:z,lifeCycle:A,loadingMode:$,meta:O,observer:I,reorder:i,runtimeLibrary:N,spinQuery:j,style:q,textColor:H,userInfo:a,version:r,settings:R,toast:se,themeColor:le,utils:{...X,constants:K,formatters:J,title:Y,i18n:Q,lazyPanel:o,log:ae,sort:re,urls:oe},ui:ce,componentApis:zn,pluginApis:In},Tn={ajax:C,...S,...E,...M,...z,lifeCycle:A,...$,...O,observer:I,...i,runtimeLibrary:N,spinQuery:j,...q,...H,...a,...r,settingsApis:R,get settings(){return R.settings},...se,utils:{...X,...K,...J,...Y,...Q,...o,...ae,...re,...oe},ui:ce,componentApis:{...zn.component,...zn.userComponent,...zn.styledComponent,...zn.launchBar,...lodash.omit(zn,"component","userComponent","styledComponent","launchBar")},pluginApis:{...In.style,...In.plugin,...In.data,...In.hook},monkeyApis:{GM_setValue:GM_setValue,GM_getValue:GM_getValue,GM_deleteValue:GM_deleteValue,GM_setClipboard:GM_setClipboard,GM_xmlhttpRequest:GM_xmlhttpRequest,GM_info:GM_info},lodash:lodash,Vue:Vue,sandboxWindow:window,theWorld:e=>{setTimeout((()=>{}),e)}}},5300:function(e,t,n){"use strict";let i;n.d(t,{h:function(){return i}}),function(e){e.packed="打包下载",e.individual="单独下载"}(i||(i={}))},4114:function(e,t,n){"use strict";n.r(t),n.d(t,{DownloadPackage:function(){return l}});var i=n(5300),a=n(391),r=n(6171),o=n(3708);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class l{constructor(e=[]){this.entries=e,s(this,"noEscape",!1)}add(e,t,n={}){null!=t&&this.entries.push({name:this.noEscape?e:(0,o.formatFilename)(e),data:t,options:n})}async blob(){if(0===this.entries.length)return null;if(1===this.entries.length){const{data:e}=this.entries[0];return"string"==typeof e?new Blob([e]):e}const e=new(await a.JSZipLibrary);return this.entries.forEach((({name:t,data:n,options:i})=>{e.file(t,n,i)})),e.generateAsync({type:"blob"})}async emit(e){if(0===this.entries.length)return;e&&1!==this.entries.length||(e=this.entries[0].name);if((0,r.getGeneralSettings)().downloadPackageEmitMode===i.h.individual&&this.entries.length>1)return void await Promise.all(this.entries.map((e=>l.single(e.name,e.data,e.options))));const t=await this.blob();t&&l.download(e,t)}static download(e,t){const n=document.createElement("a"),i=URL.createObjectURL(t);l.lastPackageUrl&&URL.revokeObjectURL(l.lastPackageUrl),l.lastPackageUrl=i;const a=(0,o.formatFilename)(e);n.setAttribute("href",i),n.setAttribute("download",a),console.log("[Download file]",a),document.body.appendChild(n),n.click(),n.remove()}static async single(e,t,n={}){const i=new l;return i.add(e,t,n),i.emit()}}s(l,"lastPackageUrl","")},7731:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{parseExternalInput:function(){return parseExternalInput},batchParseCode:function(){return batchParseCode}});var _file_picker__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(7590);const parseExternalInput=async input=>{if(void 0===input){const files=await(0,_file_picker__WEBPACK_IMPORTED_MODULE_0__.pickFile)({accept:"application/json"});if(!(files.length>0))return console.error("[parseExternalInput] No file selected"),null;{const[file]=files,text=await file.text();try{return eval(`(${text})`)}catch(e){return console.error(e),null}}}else{if("string"!=typeof input)return input;try{const exports={},result=eval(input);if(Object.values(exports).length>0){const e=Object.values(exports)[0];return e}return result}catch(e){return console.error(e),null}}},batchParseCode=async inputs=>{try{const exports={},result=inputs.map((input=>eval(input)));if(Object.values(exports).length>0){const{coreApis:e}=await Promise.resolve().then(__webpack_require__.bind(__webpack_require__,9388));return Object.values(exports).map((t=>"function"==typeof t?t(e):t))}return result}catch(e){return console.error(e),null}}},7590:function(e,t,n){"use strict";let i,a;n.r(t),n.d(t,{pickFile:function(){return o}});const r={accept:"*",multiple:!1},o=async(e=r)=>{const{accept:t,multiple:n}={...r,...e};i||(i=document.createElement("input"),i.type="file",i.style.display="none",document.body.appendChild(i),i.addEventListener("change",(()=>{a?.([...i.files]),a=null}))),i.accept=t,i.multiple=n,i.value="",a&&a([]);return await new Promise((e=>{a=e,i.click()}))}},9513:function(e,t,n){"use strict";n.d(t,{m:function(){return s}});var i=n(7010),a=n(9543),r=n(1623),o=n(8900);const s=async e=>{const{monkey:t}=await Promise.resolve().then(n.bind(n,7195)),s=await t({url:e}),{parseExternalInput:l}=await Promise.resolve().then(n.bind(n,7731)),c=await l(s),{type:d,installer:u}=(()=>{if((e=>"entry"in e)(c))return{type:"component",installer:()=>(0,i.installComponent)(s)};if((e=>"setup"in e)(c))return{type:"plugin",installer:()=>(0,r.installPlugin)(s)};if((e=>"style"in e)(c))return{type:"style",installer:()=>(0,o.installStyle)(s)};throw new Error("无效的功能代码")})(),{before:p,after:h}=(0,a.getHook)(`user${lodash.startCase(d)}s.add`,s,e);await p();const f=await u();return await h(f.metadata),f}},7177:function(e,t,n){"use strict";n.r(t),n.d(t,{headLoaded:function(){return a},contentLoaded:function(){return r},fullyLoaded:function(){return o},LifeCycleEventTypes:function(){return s},raiseLifeCycleEvent:function(){return l}});var i=n(3420);const a=e=>new Promise((t=>{if(null!==document.head)t(e());else{const[n]=(0,i.childList)(document.documentElement,(()=>{null!==document.head&&(n.disconnect(),t(e()))}))}})),r=e=>new Promise((t=>{"loading"!==document.readyState?t(e()):document.addEventListener("DOMContentLoaded",(()=>t(e())))})),o=e=>new Promise((t=>{"complete"===document.readyState?t(e()):unsafeWindow.addEventListener("load",(()=>t(e())))}));let s;!function(e){e.Start="be:start",e.StyleLoaded="be:style-loaded",e.ComponentsLoaded="be:components-loaded",e.End="be:end"}(s||(s={}));const l=e=>{unsafeWindow.dispatchEvent(new CustomEvent(e))}},4345:function(e,t,n){"use strict";let i;n.r(t),n.d(t,{LoadingMode:function(){return i}}),function(e){e.Delay="延后",e.Race="同时"}(i||(i={}))},1836:function(e,t,n){"use strict";n.r(t),n.d(t,{branches:function(){return r},meta:function(){return s}});var i=JSON.parse('{"version":"2.0.0","author":"Grant Howard, Coulomb-G","copyright":"[year], Grant Howard (https://github.com/the1812) & Coulomb-G (https://github.com/Coulomb-G)","licence":"MIT","match":"*://*.bilibili.com/*","exclude":["*://api.bilibili.com/*","*://api.*.bilibili.com/*","*://*.bilibili.com/api/*","*://member.bilibili.com/studio/bs-editor/*","*://message.bilibili.com/pages/nav/index_new_sync","*://message.bilibili.com/pages/nav/index_new_pc_sync","*://t.bilibili.com/h5/dynamic/specification","*://bbq.bilibili.com/*"],"run-at":"document-start","supportURL":"https://github.com/the1812/Bilibili-Evolved/issues","homepage":"https://github.com/the1812/Bilibili-Evolved","grant":["unsafeWindow","GM_getValue","GM_setValue","GM_deleteValue","GM_setClipboard","GM_info","GM_xmlhttpRequest"],"connect":["raw.githubusercontent.com","github.com","cdn.jsdelivr.net","cn.bing.com","www.bing.com","translate.google.cn","translate.google.com","localhost","*"],"require":["https://cdn.jsdelivr.net/npm/lodash@4.17.21/lodash.min.js"],"icon":"https://cdn.jsdelivr.net/gh/the1812/Bilibili-Evolved@preview/images/logo-small.png","icon64":"https://cdn.jsdelivr.net/gh/the1812/Bilibili-Evolved@preview/images/logo.png"}'),a=n(2462);i.copyright=i.copyright.replace(/\[year\]/g,(new Date).getFullYear().toString());const r={stable:"v2",preview:"preview"},o={commitHash:"ef06dd3f2de852c518c2b419348301d0c678645e",branch:"preview",nearestTag:"v2.0.0-preview1",versionWithTag:"v2.0.0-preview1-7-gef06dd3f2"},s={compilationInfo:o,name:GM_info.script.name,description:GM_info.script.description,get originalFilename(){const{branch:e}=o;return e===r.stable?"bilibili-evolved.user.js":`bilibili-evolved.${e}.user.js`},get updateURL(){return`${a.cdnRoots.jsDelivr(o.branch)}dist/${this.originalFilename}`},get downloadURL(){return this.updateURL},...i}},3420:function(e,t,n){"use strict";n.r(t),n.d(t,{childList:function(){return l},childListSubtree:function(){return c},attributes:function(){return d},attributesSubtree:function(){return u},characterData:function(){return p},characterDataSubtree:function(){return h},allMutationsOn:function(){return f},allMutations:function(){return g},visible:function(){return b},visibleInside:function(){return y},sizeChange:function(){return w},urlChange:function(){return _},videoChange:function(){return S}});var i=n(1906),a=n(5550),r=n(7735);const o=e=>"string"==typeof e?(0,i.dqa)(e):Array.isArray(e)?e:[e],s=(e,t,n)=>{const i=new MutationObserver(n);return e.forEach((e=>i.observe(e,t))),n([],i),[i,t]},l=(e,t)=>s(o(e),{childList:!0,subtree:!1,attributes:!1},t),c=(e,t)=>s(o(e),{childList:!0,subtree:!0,attributes:!1},t),d=(e,t)=>s(o(e),{childList:!1,subtree:!1,attributes:!0},t),u=(e,t)=>s(o(e),{childList:!1,subtree:!0,attributes:!0},t),p=(e,t)=>s(o(e),{childList:!1,subtree:!1,attributes:!1,characterData:!0},t),h=(e,t)=>s(o(e),{childList:!1,subtree:!0,attributes:!1,characterData:!0},t),f=(e,t)=>s(o(e),{childList:!0,subtree:!0,attributes:!0,characterData:!0},t),m={observer:null,config:null,callbacks:[]},g=e=>{if(m.observer)m.callbacks.push(e);else{m.callbacks.push(e);const[t,n]=f(document.body,(e=>m.callbacks.forEach((t=>t(e,m.observer)))));m.observer=t,m.config=n}return m},v=(e,t,n)=>{const i=new IntersectionObserver(n,t);return e.forEach((e=>i.observe(e))),[i,t]},b=(e,t)=>v(o(e),{},t),y=(e,t,n,i)=>v(o(e),{root:t,rootMargin:n},i),w=(e,t)=>((e,t,n)=>{const i=new ResizeObserver(n);return e.forEach((e=>i.observe(e,t))),[i,t]})(o(e),{box:"border-box"},t),x=lodash.once((()=>{let e=document.URL;g((()=>{e!==document.URL&&((()=>{const e=new CustomEvent("urlChange",{detail:document.URL});window.dispatchEvent(e)})(),e=document.URL)}))})),_=(e,t)=>{x(),e(document.URL),window.addEventListener("urlChange",(()=>e(document.URL)),t)},k=lodash.once((()=>(0,a.select)((()=>{if(unsafeWindow.cid)return unsafeWindow.cid;if(unsafeWindow.player&&unsafeWindow.player.getVideoMessage){const e=unsafeWindow.player.getVideoMessage();return Number.isNaN(e.cid)?null:(!unsafeWindow.aid&&e.aid&&(unsafeWindow.aid=e.aid.toString()),!unsafeWindow.bvid&&e.bvid&&(unsafeWindow.bvid=e.bvid),e.cid.toString())}return null}))));let C=!1;const S=async(e,t)=>{if(!(0,r.matchCurrentPage)(r.playerUrls))return!1;const{bpxPlayerPolyfill:i}=await Promise.resolve().then(n.bind(n,6958));i();const a=await k();if(null===a)return!1;const o=()=>({aid:unsafeWindow.aid,cid:unsafeWindow.cid});if(!C){let e=a;Object.defineProperty(unsafeWindow,"cid",{get:()=>e,set(t){e=t,Array.isArray(t)||(()=>{const e=o(),t=new CustomEvent("videoChange",{detail:e});window.dispatchEvent(t)})()}}),C=!0}return e(o()),window.addEventListener("videoChange",(t=>e(t.detail)),t),!0}},1485:function(e,t,n){"use strict";n.r(t),n.d(t,{componentLoadTime:function(){return i},componentResolveTime:function(){return a},componentLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async e=>{const{getGeneralSettings:t}=await Promise.resolve().then(n.bind(n,6171));if(!t().devMode)return;const r=e.entry;e.entry=async e=>{const{metadata:t}=e,n=performance.now();let o=r(e);const s=performance.now();o instanceof Promise&&(o=await o);const l=performance.now();return i.set(t,s-n),a.set(t,l-n),o}}},8970:function(e,t,n){"use strict";n.r(t),n.d(t,{pluginLoadTime:function(){return i},pluginResolveTime:function(){return a},pluginLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async e=>{const{getGeneralSettings:t}=await Promise.resolve().then(n.bind(n,6171));if(!t().devMode)return;const r=e.setup;e.setup=async t=>{const n=performance.now();let o=r(t);const s=performance.now();o instanceof Promise&&(o=await o);const l=performance.now();return i.set(e,s-n),a.set(e,l-n),o}}},719:function(e,t,n){"use strict";n.r(t),n.d(t,{promiseLoadTime:function(){return i},promiseResolveTime:function(){return a},promiseLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async(e,t)=>{const{getGeneralSettings:r}=await Promise.resolve().then(n.bind(n,6171));if(!r().devMode)return t();const o=performance.now(),s=t(),l=performance.now(),c=await s,d=performance.now();return i.set({name:e},l-o),a.set({name:e},d-o),c}},9476:function(e,t,n){"use strict";n.r(t),n.d(t,{logStats:function(){return i}});const i=(e,t)=>{const n=[...t.entries()],i=n.reduce(((e,t)=>e+t[1]),0);console.groupCollapsed(`${e} time:`,Math.round(100*i)/100+"ms",`for ${n.length} items`),n.forEach((([e,t])=>{console.log(`%c${e.name} %c${Math.round(100*t)/100}ms ${Math.round(t/i*1e4)/100}% %c`,"color: #00A0D8","color: #888","color: unset")})),console.groupEnd()}},391:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{RuntimeLibrary:function(){return RuntimeLibrary},protobufLibrary:function(){return protobufLibrary},JSZipLibrary:function(){return JSZipLibrary},SortableJSLibrary:function(){return SortableJSLibrary}});var _ajax__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(7195);function _defineProperty(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class RuntimeLibrary{constructor(e){this.config=e,_defineProperty(this,"modulePromise",void 0)}async then(resolve,reject){try{const{url:url,getModule:getModule}=this.config;this.modulePromise||(this.modulePromise=(async()=>{console.log(`[Runtime Library] Start download from ${url}`);const code=await(0,_ajax__WEBPACK_IMPORTED_MODULE_0__.monkey)({url:url});return console.log(`[Runtime Library] Downloaded from ${url} , length = ${code.length}`),function runEval(){return eval(code);// eslint-disable-next-line no-extra-bind +const t=e=>e.__vue__||e.parentElement.__vue__,n=async t=>{const n=await(0,j.sq)((()=>e.querySelector(t)),(t=>null!==t||null===e.parentNode),{queryInterval:100});if(null===e.parentNode)return"";if(null===n)return console.warn(e,t,e.parentNode),"";return n.innerText.trim()},i=e=>{if(void 0===e.card.origin)return{originalText:"",originalDescription:"",originalTitle:""};const t=JSON.parse(e.card.origin);return{originalText:e.originCardData.pureText,originalDescription:lodash.get(t,"item.description",""),originalTitle:t.title}},a=async e=>{const t=parseInt(await n(e));return isNaN(t)?0:t},r={id:e.getAttribute("data-did"),username:await n(".main-content .user-name"),text:"",reposts:await a(".button-bar .single-button:nth-child(1) .text-offset"),comments:await a(".button-bar .single-button:nth-child(2) .text-offset"),likes:await a(".button-bar .single-button:nth-child(3) .text-offset"),element:e,type:ke(e),get presented(){return null!==e.parentNode},async getText(){const n=await(async n=>{if(n===ye.bangumi)return"";const a=await(0,j.sq)((()=>e),(n=>Boolean(t(n)||!e.parentNode)),{queryInterval:100});if(null===e.parentNode)return"";if(null===a)return console.warn(a,e,t(a),e.parentNode),"";const r=t(a);if(n===ye.repost){const e=r.card.item.content,t=i(r);return[e,...Object.values(t).filter((e=>""!==e))].filter((e=>Boolean(e))).join("\n")}return[r.originCardData.pureText,r.originCardData.title].filter((e=>Boolean(e))).join("\n")})(this.type);return this.text=n,n}};if(await r.getText(),e.setAttribute("data-type",r.type.id.toString()),(e=>e.type===ye.repost)(r)){const n=r.username,a=t(r.element),o=lodash.get(a,"card.origin_user.info.uname","");n===o&&e.setAttribute("data-self-repost","true"),r.repostUsername=o,r.repostText=i(a).originalText}return r}updateCards(e){const t=".card[data-did]",n=e=>{if(e instanceof HTMLElement){if(e.matches(t))return e;const n=e.querySelector(t);if(n)return n}};return[...e.querySelectorAll(t)].forEach((e=>this.addCard(e))),(0,I.childList)(e,(e=>{e.forEach((e=>{e.addedNodes.forEach((e=>this.addCard(n(e)))),e.removedNodes.forEach((e=>this.removeCard(n(e))))}))}))}async startWatching(){if(this.watching)return!0;this.watching=!0;const[e]=(0,be.registerAndGetData)(Se,[]),t=e.find((e=>e.match.some((e=>(0,X.matchUrlPattern)(e)))));return t?t.watchCardsList(this):(console.warn("[FeedsCardsManager] No adaptor found",e),!1)}}const Me=new Ee,ze=e=>{(async()=>{if(!await Me.startWatching())return void console.error("feedsCardsManager.startWatching() failed");const{added:t}=e;t&&Me.cards.forEach((e=>t(e))),Ce.push({added:none,removed:none,...e})})()},Ae=e=>{const t=lodash.groupBy(e,(e=>e.aid)),n=e=>({id:e.upID,name:e.upName,faceUrl:e.upFaceUrl});return Object.values(t).map((e=>{if(1===e.length)return e[0];const[t,...i]=e;return t.cooperation=[n(t),...i.map(n)],console.log([...t.cooperation]),t})).sort((0,re.descendingStringSort)((e=>e.id)))},$e=e=>1===lodash.get(e,"extra.is_reserve_recall",0),Oe="feeds.contentFilters";(0,be.registerData)(Oe,[]);const Ie=e=>{const[t]=(0,be.getData)(Oe);return t.reduce(((e,t)=>t.filter(e)),e)},Le=e=>(...t)=>e(...t).then((e=>Ie(e))),Te=Le((async(e="video")=>{if(!(0,X.getUID)())return[];const t=await(0,C.getJsonWithCredentials)(`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${"video"===e?8:512}`);if(0!==t.code)throw new Error(t.message);const n=t.data.cards,i=n.filter((e=>!$e(JSON.parse(e.card))));return"video"===e?Ae(n.map((e=>{const t=JSON.parse(e.card),n=lodash.get(e,"display.topic_info.topic_details",[]).map((e=>({id:e.topic_id,name:e.topic_name})));return{id:e.desc.dynamic_id_str,aid:t.aid,bvid:e.desc.bvid||t.bvid,title:t.title,upID:e.desc.user_profile.info.uid,upName:e.desc.user_profile.info.uname,upFaceUrl:e.desc.user_profile.info.face,coverUrl:t.pic,description:t.desc,timestamp:e.timestamp,time:new Date(1e3*e.timestamp),topics:n,dynamic:t.dynamic,like:(0,J.formatCount)(e.desc.like),duration:t.duration,durationText:(0,J.formatDuration)(t.duration,0),playCount:(0,J.formatCount)(t.stat.view),danmakuCount:(0,J.formatCount)(t.stat.danmaku),watchlater:me.includes(t.aid)}}))):"bangumi"===e?i.map((e=>{const t=JSON.parse(e.card);return{id:e.desc.dynamic_id_str,aid:t.aid,bvid:e.desc.bvid||t.bvid,epID:t.episode_id,title:t.new_desc,upName:t.apiSeasonInfo.title,upFaceUrl:t.apiSeasonInfo.cover,coverUrl:t.cover,description:"",timestamp:e.timestamp,time:new Date(1e3*e.timestamp),like:(0,J.formatCount)(e.desc.like),durationText:"",playCount:(0,J.formatCount)(t.play_count),danmakuCount:(0,J.formatCount)(t.bullet_count),watchlater:!1}})):[]})),Pe=async(e,t)=>{if("string"==typeof e)return(0,C.getJsonWithCredentials)(`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${e}`);const n=e.id.toString();let i=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_new?uid=${(0,X.getUID)()}&type_list=${n}`;return t&&(i=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_history?uid=${(0,X.getUID)()}&offset_dynamic_id=${t}&type=${n}`),(0,C.getJsonWithCredentials)(i)},De=(e,t)=>{const n=dq(e.element,".more-panel"),{className:i,text:a,action:r}=t;if(!n||dq(n,`.${i}`))return;const o=document.createElement("p");o.classList.add("child-button","c-pointer",i),o.textContent=a;[...new Set([...n.children].map((e=>e.getAttributeNames().filter((e=>e.startsWith("data-v-"))))).flat())].forEach((e=>o.setAttribute(e,""))),o.addEventListener("click",(t=>{r(t),e.element.click()})),n.appendChild(o)};var Ve=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"bangumi-card",class:{new:e.isNew},attrs:{target:"_blank",href:e.data.url}},[n("div",{staticClass:"ep-cover-container"},[n("DpiImage",{staticClass:"ep-cover",attrs:{size:{width:100},src:e.data.epCoverUrl}})],1),e._v(" "),n("h1",{staticClass:"ep-title",attrs:{title:e.data.epTitle}},[e._v(e._s(e.data.epTitle))]),e._v(" "),n("div",{staticClass:"up",attrs:{title:e.data.title}},[n("DpiImage",{staticClass:"cover",attrs:{size:24,src:e.data.coverUrl}}),e._v(" "),n("div",{staticClass:"title"},[e._v(e._s(e.data.title))])],1)])};Ve._withStripped=!0;var Be=Vue.extend({components:{DpiImage:ce.DpiImage},props:{data:{type:Object,required:!0},isNew:{type:Boolean,default:!1}}}),Fe=n(3379),Ne=n.n(Fe),je=n(5478),qe=n.n(je),He={insert:"head",singleton:!1},Re=(Ne()(qe(),He),qe().locals,n(1900)),Ue=(0,Re.Z)(Be,Ve,[],!1,null,"3bc2da4f",null);Ue.options.__file="src/components/feeds/BangumiCard.vue";var Ze=Ue.exports,We=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"video-card",class:{vertical:"vertical"===e.orientation,"no-stats":!e.showStats},attrs:{target:"_blank",href:e.epID?"https://www.bilibili.com/bangumi/play/ep"+e.epID:"https://www.bilibili.com/"+e.bvid}},[n("div",{staticClass:"cover-container"},[n("DpiImage",{staticClass:"cover",attrs:{src:e.coverUrl,size:{height:120,width:200}}}),e._v(" "),e.isNew?n("div",{staticClass:"new"},[e._v("NEW")]):e._e(),e._v(" "),e.pubTime&&e.pubTimeText?[n("div",{staticClass:"publish-time-summary"},[e._v("\n "+e._s(e.pubTimeText)+"\n ")]),e._v(" "),n("div",{staticClass:"publish-time-detail"},[e._v("\n "+e._s(e.pubTime)+"\n ")])]:e._e(),e._v(" "),e.durationText?n("div",{staticClass:"duration"},[e._v(e._s(e.durationText))]):e._e(),e._v(" "),e.durationText&&null!==e.watchlater&&void 0!==e.watchlater?n("div",{staticClass:"watchlater",on:{click:function(t){return t.stopPropagation(),t.preventDefault(),e.toggleWatchlater(e.aid)}}},[n("VIcon",{attrs:{size:15,icon:e.watchlater?"mdi-check-circle":"mdi-clock-outline"}}),e._v("\n "+e._s(e.watchlater?"已添加":"稍后再看")+"\n ")],1):e._e()],2),e._v(" "),n("h1",{staticClass:"title",attrs:{title:e.title}},[e._v(e._s(e.title))]),e._v(" "),e.topics&&e.topics.length?n("div",{staticClass:"topics"},e._l(e.topics.slice(0,3),(function(t){return n("a",{key:t.id,staticClass:"topic",attrs:{target:"_blank",href:"https://t.bilibili.com/topic/name/"+t.name+"/feed"}},[e._v("#"+e._s(t.name)+"#")])})),0):n("p",{staticClass:"description",attrs:{title:e.description}},[e._v(e._s(e.description))]),e._v(" "),0===e.cooperation.length?n("a",{staticClass:"up",class:{"no-face":!e.upFaceUrl},attrs:{target:"_blank",href:e.upID?"https://space.bilibili.com/"+e.upID:null}},[e.upFaceUrl?n("DpiImage",{staticClass:"face",attrs:{src:e.upFaceUrl,size:24}}):n("VIcon",{attrs:{icon:"up"}}),e._v(" "),n("div",{staticClass:"name",attrs:{title:e.upName}},[e._v(e._s(e.upName))])],1):e._e(),e._v(" "),0!==e.cooperation.length?n("div",{staticClass:"cooperation"},[n("div",{staticClass:"cooperation-ups"},e._l(e.reversedCooperation,(function(e){return n("a",{key:e.id,staticClass:"cooperation-up",class:{"no-face":!e.faceUrl},attrs:{target:"_blank",title:e.name,href:e.id?"https://space.bilibili.com/"+e.id:null}},[e.faceUrl?n("DpiImage",{staticClass:"face",attrs:{src:e.faceUrl,size:24}}):n("VIcon",{attrs:{icon:"up"}})],1)})),0),e._v(" "),n("div",{staticClass:"cooperation-note"},[e._v("\n 联合投稿\n ")])]):e._e(),e._v(" "),e.showStats?n("div",{staticClass:"stats"},[e.like&&!e.vertical?[n("VIcon",{attrs:{icon:"like-outline",size:18}}),e._v("\n "+e._s(e.like)+"\n ")]:e._e(),e._v(" "),e.coins&&!e.vertical?[n("VIcon",{attrs:{icon:"coin-outline",size:18}}),e._v("\n "+e._s(e.coins)+"\n ")]:e._e(),e._v(" "),e.favorites?[n("VIcon",{attrs:{icon:"favorites-outline",size:18}}),e._v("\n "+e._s(e.favorites)+"\n ")]:e._e(),e._v(" "),e.playCount?[n("VIcon",{attrs:{icon:"play",size:18}}),e._v("\n "+e._s(e.playCount)+"\n ")]:e._e(),e._v(" "),e.danmakuCount?[n("VIcon",{attrs:{icon:"danmaku",size:18}}),e._v("\n "+e._s(e.danmakuCount)+"\n ")]:e._e()],2):e._e()])};We._withStripped=!0;var Ge={components:{DpiImage:ce.DpiImage,VIcon:ce.VIcon},props:{data:{type:Object,required:!0},orientation:{type:String,default:"horizontal"},showStats:{type:Boolean,default:!0},isNew:{type:Boolean,default:!1}},data(){return{watchlaterList:me,upFaceUrl:"",danmakuCount:"",like:"",coins:"",favorites:"",dynamic:"",topics:[],upID:0,epID:0,cooperation:[],...lodash.omit(this.data,"watchlater"),watchlaterInit:this.data.watchlater}},computed:{vertical(){return"vertical"===this.orientation},watchlater(){return(0,X.getUID)()&&null!==this.watchlaterInit?this.watchlaterList.includes(this.aid):null},reversedCooperation(){return[...this.cooperation].reverse().slice(0,3)}},methods:{toggleWatchlater:ve}},Xe=n(1745),Ke=n.n(Xe),Je={insert:"head",singleton:!1},Ye=(Ne()(Ke(),Je),Ke().locals,(0,Re.Z)(Ge,We,[],!1,null,"0ffa1cb1",null));Ye.options.__file="src/components/feeds/VideoCard.vue";var Qe=Ye.exports,et=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("a",{staticClass:"column-card",attrs:{target:"_blank",href:"https://www.bilibili.com/read/cv"+e.data.cvID}},[n("div",{staticClass:"covers"},e._l(e.data.covers,(function(e){return n("DpiImage",{key:e,staticClass:"cover",attrs:{size:{height:120},src:e}})})),1),e._v(" "),n("a",{staticClass:"up",attrs:{target:"_blank",href:"https://space.bilibili.com/"+e.data.upID}},[n("DpiImage",{staticClass:"face",attrs:{size:24,src:e.data.upFaceUrl}}),e._v(" "),n("div",{staticClass:"name"},[e._v(e._s(e.data.upName))])],1),e._v(" "),n("h1",{staticClass:"title",attrs:{title:e.data.title}},[e._v(e._s(e.data.title))]),e._v(" "),n("div",{staticClass:"description",attrs:{title:e.data.description}},[e._v(e._s(e.data.description))])])};et._withStripped=!0;var tt=Vue.extend({components:{DpiImage:ce.DpiImage},props:{data:{type:Object,required:!0},isNew:{type:Boolean,default:!1}}}),nt=n(620),it=n.n(nt),at={insert:"head",singleton:!1},rt=(Ne()(it(),at),it().locals,(0,Re.Z)(tt,et,[],!1,null,null,null));rt.options.__file="src/components/feeds/ColumnCard.vue";var ot=rt.exports;let st=!1;const lt=()=>{"https://t.bilibili.com/"===document.URL.replace(window.location.search,"")&&(async()=>{const{select:e}=await Promise.resolve().then(n.bind(n,5550)),t=await e(".live-up-list");if(null!==t){const{getComponentSettings:e}=await Promise.resolve().then(n.bind(n,6171));if(st)return;const i=e("fixedSidebars"),a=e("extendFeedsLive");t.addEventListener("mouseenter",(e=>{(i.enabled||a.enabled)&&e.stopImmediatePropagation()}),{capture:!0}),st=!0}})()},ct=3e5,dt=()=>(0,X.getCookieValue)(`bp_t_offset_${(0,X.getUID)()}`),ut=(e,t)=>e===t?0:e.length>t.length?1:t.length>e.length?-1:e>t==!0?1:-1,pt=e=>{if(null==e)return;const t=dt();ut(e,t)<0||(document.cookie=`bp_t_offset_${(0,X.getUID)()}=${e};path=/;domain=.bilibili.com;max-age=2592000`)},ht=e=>ut(e,dt())>0,ft=e=>{const[t]=[...e.map((e=>e.id))].sort(ut).reverse();pt(t)},mt=async e=>{const t=`https://api.vc.bilibili.com/dynamic_svr/v1/dynamic_svr/dynamic_num?rsp_type=1&uid=${(0,X.getUID)()}&update_num_dy_id=${dt()}&type_list=${e||xe}`,n=await(0,C.getJsonWithCredentials)(t);return 0!==n.code?0:lodash.get(n,"data.update_num",0)},gt=e=>{e.startsWith("#")&&(e=e.substring(1));return{red:e.substring(0,2),green:e.substring(2,4),blue:e.substring(4,6)}},vt=e=>{const{red:t,green:n,blue:i}=gt(e);return`\\c&H${i}${n}${t}&`.toUpperCase()},bt=(e,t=1)=>{const{red:n,green:i,blue:a}=gt(e);return`&H${Math.round(255*(1-t)).toString(16).padStart(2,"0")}${a}${i}${n}`.toUpperCase()},yt=e=>{let t=0,n=0;for(;e>=60;)e-=60,n++;for(;n>=60;)n-=60,t++;return`${t}:${String(n).padStart(2,"0")}:${(e=>{const[t,n="00"]=String(e).split(".");return`${t.padStart(2,"0")}.${n.substr(0,2).padEnd(2,"0")}`})(e)}`},wt=(e,t)=>[yt(e),yt(e+t)],xt=(e,t)=>[yt(e),yt(t)],_t=e=>{const t={"{":"{","}":"}","&":"&","<":"<",">":">",""":'"',"'":"'","\n":"\\N"};for(const[n,i]of Object.entries(t))e=e.replace(new RegExp(n,"g"),i);return e};var kt=n(7412);let Ct=!1;const St=e=>oe.playerUrls.some((e=>(0,X.matchUrlPattern)(e)))?async()=>{Ct||(te(".bilibili-player-video-btn-setting",".bilibili-player-video-btn-setting-wrap",{style:".bilibili-player-video-btn-setting-wrap { display: none !important }"}),Ct=!0);const t=await(0,j.select)(".bilibili-player-video-btn-setting-right-others-content-lightoff .bui-checkbox-input");t.checked=!e,(0,X.raiseEvent)(t,"change")}:X.none,Et=St(!0),Mt=St(!1);let zt;const At=[],$t=async e=>{await(0,j.hasVideo)()&&(0,I.videoChange)((async()=>{const t=await kt.playerAgent.query.video.danmaku();t&&((e,t)=>{zt&&zt.disconnect(),[zt]=(0,I.childListSubtree)(e,(e=>{e.forEach((e=>{e.addedNodes.forEach((e=>{if(e.nodeType===Node.TEXT_NODE){const n=e.parentElement,i=At.find((e=>e.element===n));if(!i)return;return i.text=e.textContent||"",i.reuse=!0,void(t.added&&t.added(i))}if(!(e instanceof HTMLElement))return;const n={element:i=e,reuse:!1,text:i.textContent||""};var i;At.push(n),t.added&&t.added(n)})),e.removedNodes.forEach((e=>{if(!(e instanceof HTMLElement))return;const n=At.findIndex((t=>t.element===e));if(-1!==n){const[e]=At.splice(n,1);t.removed&&t.removed(e)}}))}))}))})(t,e)}))};function Ot(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class It{constructor(e){Ot(this,"aid",void 0),Ot(this,"cid",void 0),Ot(this,"pageCount",void 0),Ot(this,"coverUrl",void 0),Ot(this,"tagId",void 0),Ot(this,"tagName",void 0),Ot(this,"title",void 0),Ot(this,"description",void 0),Ot(this,"up",void 0),Ot(this,"pages",void 0),Ot(this,"subtitles",void 0),this.aid=e}async fetchInfo(){let e;e=this.cid?`https://api.bilibili.com/x/web-interface/view?aid=${this.aid}&cid=${this.cid}`:`https://api.bilibili.com/x/web-interface/view?aid=${this.aid}`;const t=await(0,C.getJson)(e);if(0!==t.code)throw new Error(t.message);const{data:n}=t;return this.cid=n.cid,this.pageCount=n.videos,this.coverUrl=n.pic.replace("http:","https:"),this.tagId=n.tid,this.tagName=n.tname,this.title=n.title,this.description=n.desc,this.up={uid:n.owner.mid,name:n.owner.name,faceUrl:n.owner.face.replace("http:","https:")},this.pages=n.pages.map((e=>({cid:e.cid,title:e.part,pageNumber:e.page}))),this.subtitles=n.subtitle.list.map((e=>({id:e.id,languageCode:e.lan,language:e.lan_doc,url:e.subtitle_url.replace("http:","https:")}))),this}}class Lt{constructor(e){Ot(this,"ep",void 0),Ot(this,"videos",void 0),Ot(this,"title",void 0),Ot(this,"cover",void 0),Ot(this,"squareCover",void 0),Ot(this,"aid",void 0),Ot(this,"cid",void 0),this.ep=e,this.videos=[]}async fetchInfo(){const e=await(0,C.getText)(`https://www.bilibili.com/bangumi/play/ep${this.ep}/`),t=JSON.parse(e.match(/window\.__INITIAL_STATE__=(.*);\(function\(\){/)[1]);return this.title=t.mediaInfo.title,this.cover=t.mediaInfo.cover,this.squareCover=t.mediaInfo.square_cover,this.aid=t.epInfo.aid,this.cid=t.epInfo.cid,this.videos=t.epList.map((async e=>({title:e.index_title,aid:e.aid,cid:e.cid,info:await new It(e.aid).fetchInfo()}))),this}}const Tt=[{name:"720P",displayName:"高清 720P",value:64},{name:"1080P",displayName:"高清 1080P",value:80}],Pt=[{name:"HDR",displayName:"真彩 HDR",value:125},{name:"4K",displayName:"超清 4K",value:120},{name:"1080P60",displayName:"高清 1080P60",value:116},{name:"1080P+",displayName:"高清 1080P+",value:112},{name:"720P60",displayName:"高清 720P60",value:74}],Dt=[...Pt,...Tt,{name:"480P",displayName:"清晰 480P",value:32},{name:"360P",displayName:"流畅 360P",value:16}].sort((0,re.descendingSort)((e=>e.value))),Vt=async e=>{const{open:t,close:n}=e;if(!(0,j.hasVideo)())return;const i=await(0,j.select)(".bilibili-player");if(!i)return;const[a]=(0,I.childList)(i,(()=>{const e=dq(".bilibili-player-context-menu-origin");if(e){a.disconnect();const i=dq(e,"ul"),r={containerElement:e,listElement:i,get itemElements(){return dqa(e,".context-menu-function")},get isOpen(){return e.classList.contains("active")}};(0,I.childList)(i,(()=>{r.isOpen?t?.(r):n?.(r)}))}}))},Bt=async(e,t)=>Vt({open:t=>{if(t.listElement.contains(e))return;const n=document.createElement("li");n.classList.add("context-line","context-menu-function"),n.setAttribute("data-append","1");const i=document.createElement("a");i.classList.add("context-menu-a","js-action"),i.href="javascript:void(0);",i.appendChild(e),n.addEventListener("mouseover",(()=>n.classList.add("hover"))),n.addEventListener("mouseout",(()=>n.classList.remove("hover"))),n.appendChild(i),t.listElement.appendChild(n)},close:e=>t?.(e)});let Ft;const Nt=[],jt=lodash.once((async()=>{oe.playerUrls.some((e=>(0,X.matchUrlPattern)(e)))&&(0,I.videoChange)((async()=>{const{playerAgent:e}=await Promise.resolve().then(n.bind(n,7412)),t=await e.query.control.buttons.time();if(null===t)return;const i=await Promise.resolve().then(n.bind(n,135)).then((e=>e.default));Ft=new i({propsData:{items:Nt}}).$mount(),t.insertAdjacentElement("afterend",Ft.$el)}))})),qt=async e=>{Ft||await jt(),Nt.push(e)},Ht=async e=>{if(!oe.liveUrls.some((e=>(0,X.matchUrlPattern)(e))))return;const t=await(0,j.select)(".bilibili-live-player-video-controller, .web-player-controller-wrap:not(.web-player-controller-bg)");if(!t)return;const{init:n,callback:i}=e;n?.(t),(0,I.childList)(t,(async()=>{const e=dq(t,".control-area");e&&i?.(e)}))};function Rt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const Ut=0,Zt=2,Wt={heartBeat:2,heartBeatResponse:3,message:5,enterRoom:7,enterRoomResponse:8};class Gt{constructor(){Rt(this,"textEncoder",new TextEncoder),Rt(this,"textDecoder",new TextDecoder)}static readInt(e,t,n){let i=0;for(let a=n-1;a>=0;a--)i+=256**(n-a-1)*e[t+a];return i}static writeInt(e,t,n,i){let a=0;for(;a{const i={packetLength:Gt.readInt(e,0,4),headerLength:Gt.readInt(e,4,2),protocolVersion:Gt.readInt(e,6,2),operation:Gt.readInt(e,8,4),sequenceID:Gt.readInt(e,12,4)},a=[i];if(i.packetLengthe.messages[0])))}else i.protocolVersion===Ut&&(i.messages=[JSON.parse(this.textDecoder.decode(a))])}else i.operation===Wt.heartBeatResponse&&(i.heartBeatResponse={count:Gt.readInt(e,16,4)});return a};return new Promise(((n,i)=>{const a=new FileReader;a.onload=async e=>{if(!e.target)return void i(e);const a=new Uint8Array(e.target.result);n(await t(a))},a.readAsArrayBuffer(e)}))}}class Xt{constructor(){Rt(this,"startTime",0)}getLiveTime(){return new Promise((e=>{if(this.startTime)return void e(this.startTime);const t=(0,X.dq)(".bilibili-live-player-video-controller-duration-btn span"),[n]=(0,I.childList)(t,(t=>{if(t.length>0&&t.some((e=>e.addedNodes.length>0&&[...e.addedNodes].every((e=>e.nodeType===Node.TEXT_NODE))))){n.disconnect();const i=t[0].addedNodes[0].textContent,[a,r,o=0]=i.split(":").reverse().map(lodash.unary(parseInt)),s=Number(new Date);this.startTime=s-1e3*o*3600-60*r*1e3-1e3*a,e(this.startTime)}}))}))}}class Kt extends EventTarget{constructor(e){super(),this.roomID=e,Rt(this,"heartBeatTimer",void 0),Rt(this,"webSocket",void 0),Rt(this,"retryInterval",200),Rt(this,"autoRetry",!0),Rt(this,"servers",["broadcastlv.chat.bilibili.com"]),Rt(this,"selectedServer",""),Rt(this,"liveTime",new Xt),Rt(this,"bufferHelper",new Gt),Rt(this,"stopRequested",!1),window.addEventListener("unload",(()=>this.stop()))}heartBeat(){this.webSocket.readyState===WebSocket.OPEN?this.webSocket.send(this.bufferHelper.encode("","heartBeat")):(this.stop(),this.restart())}restart(){if(this.dispatchEvent(new CustomEvent("restart")),!this.stopRequested&&this.autoRetry){console.log(`Live Socket: unexpected disconnect, retry in ${this.retryInterval}ms`);const e=this.servers.indexOf(this.selectedServer);ethis.start()),this.retryInterval)}}async start(){const e=await(0,C.getJson)(`https://api.live.bilibili.com/room/v1/Danmu/getConf?room_id=${this.roomID}&platform=pc&player=web`),t=lodash.get(e,"data.host_server_list",[]);this.servers=[...new Set([...this.servers,...t.map((e=>e.host))])],""===this.selectedServer&&([this.selectedServer]=this.servers,console.log("Initial server:",this.selectedServer)),this.webSocket&&[WebSocket.CONNECTING,WebSocket.OPEN].includes(this.webSocket.readyState)&&this.stop(),this.webSocket=new WebSocket(`wss://${this.selectedServer}/sub`),this.stopRequested=!1,this.dispatchEvent(new CustomEvent("start",{detail:this.webSocket})),this.webSocket.addEventListener("open",(()=>{const t={roomid:this.roomID,uid:parseInt((0,X.getUID)()),protover:2,platform:"web",clientVer:"1.10.1",type:"2",key:lodash.get(e,"data.token")};this.webSocket.send(this.bufferHelper.encode(JSON.stringify(t),"enterRoom")),this.dispatchEvent(new CustomEvent("open",{detail:t}))})),this.webSocket.addEventListener("message",(async e=>{const[t]=await this.bufferHelper.decode(e.data);switch(this.dispatchEvent(new CustomEvent("message",{detail:t})),t.operation){case Wt.enterRoomResponse:this.heartBeatTimer&&clearInterval(this.heartBeatTimer),this.heartBeatTimer=window.setInterval((()=>{this.heartBeat()}),3e4);break;case Wt.heartBeatResponse:if(!t.heartBeatResponse)break;this.dispatchEvent(new CustomEvent("heartBeatResponse",{detail:t.heartBeatResponse.count}));break;case Wt.message:{if(!t.messages)break;const e=await this.liveTime.getLiveTime();t.messages.forEach((t=>{if("DANMU_MSG"===t.cmd){const{info:n}=t,i={content:n[1],type:n[0][1],fontSize:n[0][2],color:n[0][3],sendTime:n[0][4],userHash:n[0][7],userID:n[2][0],userName:n[2][1],startTime:e,get time(){return this.sendTime-this.startTime}};this.dispatchEvent(new CustomEvent("danmaku",{detail:i}))}}));break}}})),this.webSocket.addEventListener("close",(e=>{this.stopRequested||(console.error("Live Socket: close",e),this.restart())})),this.webSocket.addEventListener("error",(e=>{console.error("Live Socket: error",e),this.restart()}))}stop(){this.stopRequested=!0,this.heartBeatTimer&&clearInterval(this.heartBeatTimer),this.webSocket&&this.webSocket.readyState===WebSocket.OPEN&&this.webSocket.close()}}const Jt=[],Yt="bb-comment",Qt=[],en=[],tn=[],nn=e=>{const t=e.querySelector(".con .user .name"),n=e=>{const t=e.querySelector(".reply-face"),n=e.querySelector(".reply-con .user .name");return{id:e.getAttribute("data-id"),element:e,userID:t.getAttribute("data-usercard-mid"),userName:n.textContent,content:e.querySelector(".text-con").textContent,timeText:e.querySelector(".info .time").textContent,likes:parseInt(e.querySelector(".info .like span").textContent)}},i={id:e.getAttribute("data-id"),element:e,userID:t.getAttribute("data-usercard-mid"),userName:t.textContent,content:e.querySelector(".con .text").textContent,timeText:e.querySelector(".con .info .time").textContent,likes:parseInt(e.querySelector(".con .like span").textContent),replies:[]};if(dq(e,".reply-box .view-more")){const t=dq(e,".reply-box");(0,I.childList)(t,(t=>{i.replies=(0,X.dqa)(e,".reply-box .reply-item").map(n),0!==t.length&&i.onRepliesUpdate?.(i.replies)}))}else i.replies=(0,X.dqa)(e,".reply-box .reply-item").map(n);return i},an=e=>{if(e instanceof HTMLElement&&e.classList.contains(Yt)){const t={element:e,items:[]};Jt.push(t),(e=>{e.observer||(e.items=(0,X.dqa)(e.element,".list-item.reply-wrap").map(nn),e.items.forEach((e=>{Qt.forEach((t=>t(e)))})),[e.observer]=(0,I.childListSubtree)(e.element,(t=>{t.forEach((t=>{const n=e=>e instanceof HTMLElement&&e.classList.contains("list-item")&&e.classList.contains("reply-wrap");t.addedNodes.forEach((t=>{if(n(t)){const n=nn(t);e.items.push(n),Qt.forEach((e=>e(n)))}})),t.removedNodes.forEach((t=>{if(n(t)){const n=t.getAttribute("data-id"),i=e.items.findIndex((e=>e.id===n));if(-1!==i){const[t]=e.items.splice(i,1);en.forEach((e=>e(t)))}}}))}))})))})(t),tn.forEach((e=>e(t)))}};(0,A.contentLoaded)((()=>{(0,I.allMutations)((e=>{e.forEach((e=>{e.addedNodes.forEach((e=>an(e)))}))})),(0,X.dqa)(".bb-comment").forEach(an)}));const rn=e=>{Jt.forEach((t=>e(t))),tn.push(e)},on=e=>{const{added:t,removed:n}=e;rn((e=>{t&&(e.items.forEach((e=>t(e))),Qt.push(t)),n&&en.push(n)}))},sn=(e,t)=>{const n=dq(e.element,".opera-list ul"),{className:i,text:a,action:r}=t;if(!n||dq(n,`.${i}`))return;const o=document.createElement("li");o.classList.add(i),o.textContent=a,o.addEventListener("click",(e=>{r(e)})),n.appendChild(o)};var ln=n(2149);const cn=JSON.parse('[[{"name":"首页","route":"/","tid":"","locid":23,"sub":[]},{"name":"动画","route":"douga","tid":1,"locid":52,"count":"","subMenuSize":162,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2507,"leftId":2452,"rightId":2453},"sub":[{"name":"MAD·AMV","route":"mad","tid":24,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":151},"desc":"具有一定制作程度的动画或静画的二次创作视频","url":"//www.bilibili.com/video/douga-mad-1.html"},{"name":"MMD·3D","route":"mmd","tid":25,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":152},"desc":"使用MMD(MikuMikuDance)和其他3D建模类软件制作的视频","url":"//www.bilibili.com/video/douga-mmd-1.html"},{"name":"短片·手书·配音","route":"voice","tid":47,"ps":15,"rps":10,"desc":"追求创新并具有强烈特色的短片、手书(绘)及ACG相关配音","url":"//www.bilibili.com/video/douga-voice-1.html"},{"name":"手办·模玩","route":"garage_kit","tid":210,"ps":15,"rps":10,"desc":"手办模玩的测评、改造或其他衍生内容","url":""},{"name":"特摄","route":"tokusatsu","tid":86,"ps":15,"rps":10,"desc":"特摄相关衍生视频","url":"//www.bilibili.com/video/cinephile-tokusatsu.html"},{"name":"综合","route":"other","tid":27,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":153},"desc":"以动画及动画相关内容为素材,包括但不仅限于音频替换、杂谈、排行榜等内容","url":"//www.bilibili.com/video/douga-else-1.html"}]},{"name":"番剧","route":"anime","tid":13,"url":"//www.bilibili.com/anime/","takeOvered":true,"count":"","subMenuSize":172,"combination":true,"sub":[{"name":"连载动画","tid":33,"route":"serial","desc":"当季连载的动画番剧","url":"//www.bilibili.com/video/bangumi-two-1.html"},{"name":"完结动画","tid":32,"route":"finish","desc":"已完结的动画番剧合集","url":"//www.bilibili.com/video/part-twoelement-1.html"},{"name":"资讯","tid":51,"route":"information","desc":"动画番剧相关资讯视频","url":"//www.bilibili.com/video/douga-else-information-1.html"},{"name":"官方延伸","tid":152,"route":"offical","desc":"动画番剧为主题的宣传节目、采访视频,及声优相关视频","url":"//www.bilibili.com/video/bagumi_offical_1.html"},{"name":"新番时间表","url":"//www.bilibili.com/anime/timeline/","desc":""},{"name":"番剧索引","url":"//www.bilibili.com/anime/index/","desc":""}]},{"name":"国创","tid":167,"route":"guochuang","url":"//www.bilibili.com/guochuang/","takeOvered":true,"count":"","subMenuSize":214,"combination":true,"sub":[{"name":"国产动画","tid":153,"route":"chinese","desc":"我国出品的PGC动画","url":"//www.bilibili.com/video/bangumi_chinese_1.html"},{"name":"国产原创相关","tid":168,"route":"original","desc":"","url":"//www.bilibili.com/video/guochuang-fanvid-1.html"},{"name":"布袋戏","tid":169,"route":"puppetry","desc":"","url":"//www.bilibili.com/video/glove-puppetry-1.html"},{"name":"动态漫·广播剧","tid":195,"route":"motioncomic","desc":"","url":""},{"name":"资讯","tid":170,"route":"information","desc":"","url":"//www.bilibili.com/video/guochuang-offical-1.html"},{"name":"新番时间表","url":"//www.bilibili.com/guochuang/timeline/","desc":""},{"name":"国产动画索引","url":"//www.bilibili.com/guochuang/index/","desc":""}]},{"name":"音乐","route":"music","tid":3,"locid":58,"count":"","subMenuSize":268,"slider":{"width":620,"height":220},"viewTag":true,"customComponent":{"name":"Energy","titleId":2511,"leftId":2462,"rightId":3131,"rightType":"slide"},"sub":[{"name":"原创音乐","route":"original","tid":28,"ps":15,"rps":10,"viewHotTag":true,"ad":{"active":true,"dataLocId":243},"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"个人或团队制作以音乐为主要原创因素的歌曲或纯音乐","url":"//www.bilibili.com/video/music-original-1.html"},{"name":"翻唱","route":"cover","tid":31,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":245},"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"一切非官方的人声再演绎歌曲作品","url":"//www.bilibili.com/video/music-Cover-1.html"},{"name":"VOCALOID·UTAU","route":"vocaloid","tid":30,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"以雅马哈Vocaloid和UTAU引擎为基础,包含其他调教引擎,运用各类音源进行的歌曲创作内容","url":"//www.bilibili.com/video/music-vocaloid-1.html"},{"name":"电音","route":"electronic","tid":194,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"以电子合成器、音乐软体等产生的电子声响制作的音乐","url":"#"},{"name":"演奏","route":"perform","tid":59,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":247},"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"传统或非传统乐器及器材的演奏作品","url":"//www.bilibili.com/video/music-perform-1.html"},{"name":"MV","route":"mv","tid":193,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"音乐录影带,为搭配音乐而拍摄或制作的视频","url":"//www.bilibili.com/video/music-coordinate-1.html"},{"name":"音乐现场","route":"live","tid":29,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"音乐实况表演视频","url":"//www.bilibili.com/video/music-oped-1.html"},{"name":"音乐综合","route":"other","tid":130,"ps":15,"rps":10,"viewHotTag":true,"dpConfig":[{"name":"一日","value":1},{"name":"三日","value":3}],"desc":"收录无法定义到其他音乐子分区的音乐视频","url":"//www.bilibili.com/video/music-collection-1.html"},{"name":"音频","customZone":"Audio","route":"audio","url":"//www.bilibili.com/audio/home?musicType=music"},{"name":"说唱","url":"//www.bilibili.com/v/rap"}]},{"name":"舞蹈","route":"dance","tid":129,"locid":64,"count":"","subMenuSize":172,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2513,"leftId":2472,"rightId":2473},"sub":[{"name":"宅舞","route":"otaku","tid":20,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":249},"desc":"与ACG相关的翻跳、原创舞蹈","url":"//www.bilibili.com/video/dance-1.html"},{"name":"街舞","route":"hiphop","tid":198,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":251},"desc":"收录街舞相关内容,包括赛事现场、舞室作品、个人翻跳、FREESTYLE等","url":""},{"name":"明星舞蹈","route":"star","tid":199,"ps":15,"rps":10,"desc":"国内外明星发布的官方舞蹈及其翻跳内容","url":""},{"name":"中国舞","route":"china","tid":200,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":253},"desc":"传承中国艺术文化的舞蹈内容,包括古典舞、民族民间舞、汉唐舞、古风舞等","url":""},{"name":"舞蹈综合","route":"three_d","tid":154,"ps":15,"rps":10,"desc":"收录无法定义到其他舞蹈子分区的舞蹈视频","url":""},{"name":"舞蹈教程","route":"demo","tid":156,"ps":10,"rps":6,"desc":"镜面慢速,动作分解,基础教程等具有教学意义的舞蹈视频","url":"//www.bilibili.com/video/dance-demo-1.html"}]},{"name":"游戏","route":"game","tid":4,"locid":70,"count":"","subMenuSize":240,"slider":{"width":470,"height":216},"viewTag":true,"customComponent":{"name":"Energy","titleId":3761,"leftId":3765,"rightId":3775,"rightType":"slide"},"recommendCardType":"GameGroomBox","sub":[{"name":"单机游戏","route":"stand_alone","tid":17,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":255},"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"以所有平台(PC、主机、移动端)的单机或联机游戏为主的视频内容,包括游戏预告、CG、实况解说及相关的评测、杂谈与视频剪辑等","url":"//www.bilibili.com/video/videogame-1.html"},{"name":"电子竞技","route":"esports","tid":171,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":257},"desc":"具有高对抗性的电子竞技游戏项目,其相关的赛事、实况、攻略、解说、短剧等视频。","url":"//www.bilibili.com/video/esports-1.html"},{"name":"手机游戏","route":"mobile","tid":172,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"desc":"以手机及平板设备为主要平台的游戏,其相关的实况、攻略、解说、短剧、演示等视频。","url":"//www.bilibili.com/video/mobilegame-1.html"},{"name":"网络游戏","route":"online","tid":65,"ps":10,"rps":7,"rankshow":1,"viewHotTag":true,"ad":{"active":true,"dataLocId":259},"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"由网络运营商运营的多人在线游戏,以及电子竞技的相关游戏内容。包括赛事、攻略、实况、解说等相关视频","url":"//www.bilibili.com/video/onlinegame-1.html"},{"name":"桌游棋牌","route":"board","tid":173,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"desc":"桌游、棋牌、卡牌对战等及其相关电子版游戏的实况、攻略、解说、演示等视频。","url":"//www.bilibili.com/video/boardgame-1.html"},{"name":"GMV","route":"gmv","tid":121,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"由游戏素材制作的MV视频。以游戏内容或CG为主制作的,具有一定创作程度的MV类型的视频","url":"//www.bilibili.com/video/gmv-1.html"},{"name":"音游","route":"music","tid":136,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"各个平台上,通过配合音乐与节奏而进行的音乐类游戏视频","url":"//www.bilibili.com/video/music-game-1.html"},{"name":"Mugen","route":"mugen","tid":19,"ps":5,"rps":3,"rankshow":1,"viewHotTag":true,"dpConfig":[{"name":"三日","value":3},{"name":"一日","value":1},{"name":"一周","value":7}],"desc":"以Mugen引擎为平台制作、或与Mugen相关的游戏视频","url":"//www.bilibili.com/video/game-mugen-1.html"},{"name":"游戏赛事","url":"//www.bilibili.com/v/game/match/","newIcon":true}]},{"name":"知识","route":"knowledge","tid":36,"locid":76,"count":"","subMenuSize":172,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2058,"leftId":2047,"rightId":2048},"sub":[{"name":"科学科普","route":"science","tid":201,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":261},"desc":"回答你的十万个为什么"},{"name":"社科·法律·心理","route":"social_science","tid":124,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":263},"desc":"基于社会科学、法学、心理学展开或个人观点输出的知识视频"},{"name":"人文历史","route":"humanity_history","tid":228,"ps":15,"rps":10,"desc":"看看古今人物,聊聊历史过往,品品文学典籍"},{"name":"财经商业","route":"business","tid":207,"ps":15,"rps":10,"desc":"说金融市场,谈宏观经济,一起畅聊商业故事"},{"name":"校园学习","route":"campus","tid":208,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":265},"desc":"老师很有趣,学生也有才,我们一起搞学习"},{"name":"职业职场","route":"career","tid":209,"ps":15,"rps":10,"desc":"职业分享、升级指南,一起成为最有料的职场人"},{"name":"设计·创意","route":"design","tid":229,"ps":15,"rps":10,"desc":"天马行空,创意设计,都在这里"},{"name":"野生技能协会","route":"skill","tid":122,"ps":15,"rps":10,"desc":"技能党集合,是时候展示真正的技术了"}]},{"name":"科技","route":"tech","tid":188,"locid":2977,"count":"","subMenuSize":80,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2980,"leftId":2978,"rightId":2979},"sub":[{"name":"数码","route":"digital","tid":95,"ps":15,"rps":10,"viewHotTag":true,"desc":"科技数码产品大全,一起来做发烧友","url":"#"},{"name":"软件应用","route":"application","tid":230,"ps":15,"rps":10,"viewHotTag":true,"desc":"超全软件应用指南","url":"#"},{"name":"计算机技术","route":"computer_tech","tid":231,"ps":15,"rps":10,"viewHotTag":true,"desc":"研究分析、教学演示、经验分享......有关计算机技术的都在这里","url":"#"},{"name":"工业·工程·机械","route":"industry","tid":232,"ps":15,"rps":10,"viewHotTag":true,"desc":"前方高能,机甲重工即将出没","url":"#"},{"name":"极客DIY","route":"diy","tid":233,"ps":15,"rps":10,"viewHotTag":true,"desc":"炫酷技能,极客文化,硬核技巧,准备好你的惊讶","url":"#"}]},{"name":"运动","route":"sports","tid":234,"locid":4639,"isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4646,"rightId":4652,"rightType":"slide"},"sub":[{"name":"篮球·足球","route":"basketballfootball","tid":235,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4656},"desc":"与篮球、足球相关的视频,包括但不限于篮足球赛事、教学、评述、剪辑、剧情等相关内容","url":"#"},{"name":"健身","route":"aerobics","tid":164,"ps":15,"rps":10,"desc":"与健身相关的视频,包括但不限于瑜伽、CrossFit、健美、力量举、普拉提、街健等相关内容","url":"//www.bilibili.com/video/fashion-body-1.html"},{"name":"竞技体育","route":"athletic","tid":236,"ps":15,"rps":10,"desc":"与竞技体育相关的视频,包括但不限于乒乓、羽毛球、排球、赛车等竞技项目的赛事、评述、剪辑、剧情等相关内容","url":"#"},{"name":"运动文化","route":"culture","tid":237,"ps":15,"rps":10,"desc":"与运动文化相关的视频,包络但不限于球鞋、球衣、球星卡等运动衍生品的分享、解读,体育产业的分析、科普等相关内容","url":"#"},{"name":"运动综合","route":"comprehensive","tid":238,"ps":15,"rps":10,"desc":"与运动综合相关的视频,包括但不限于钓鱼、骑行、滑板等日常运动分享、教学、Vlog等相关内容","url":"#"}]},{"name":"汽车","route":"car","tid":223,"locid":4428,"isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4435,"rightId":4441,"rightType":"slide"},"sub":[{"name":"汽车生活","route":"life","tid":176,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4445},"desc":"分享汽车及出行相关的生活体验类视频","url":"#"},{"name":"汽车文化","route":"culture","tid":224,"ps":15,"rps":10,"desc":"车迷的精神圣地,包括汽车赛事、品牌历史、汽车改装、经典车型和汽车模型等","url":"#"},{"name":"汽车极客","route":"geek","tid":225,"ps":15,"rps":10,"desc":"汽车硬核达人聚集地,包括DIY造车、专业评测和技术知识分享","url":"#"},{"name":"智能出行","route":"smart","tid":226,"ps":15,"rps":10,"desc":"探索新能源汽车和未来智能出行的前沿阵地","url":"#"},{"name":"购车攻略","route":"strategy","tid":227,"ps":15,"rps":10,"desc":"丰富详实的购车建议和新车体验","url":"#"}]},{"name":"生活","route":"life","tid":160,"locid":88,"count":"","subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2062,"leftId":1674,"rightId":1670},"sub":[{"name":"搞笑","route":"funny","tid":138,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":273},"desc":"各种沙雕有趣的搞笑剪辑,挑战,表演,配音等视频","url":"//www.bilibili.com/video/ent_funny_1.html","locid":4204,"recommendId":4210,"slider":{"width":620,"height":220},"customComponent":{"name":"Energy","leftId":4212,"rightId":4218,"rightType":"slide"}},{"name":"家居房产","route":"home","tid":239,"ps":15,"rps":10,"desc":"与买房、装修、居家生活相关的分享","url":"#"},{"name":"手工","route":"handmake","tid":161,"ps":15,"rps":10,"desc":"手工制品的制作过程或成品展示、教程、测评类视频","url":"//www.bilibili.com/video/ent-handmake-1.html"},{"name":"绘画","route":"painting","tid":162,"ps":15,"rps":10,"desc":"绘画过程或绘画教程,以及绘画相关的所有视频","url":"//www.bilibili.com/video/ent-painting-1.html"},{"name":"日常","route":"daily","tid":21,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":275},"desc":"记录日常生活,分享生活故事","url":"//www.bilibili.com/video/ent-life-1.html"},{"name":"其他","route":"other","tid":174,"ps":15,"rps":10,"desc":"对分区归属不明的视频进行归纳整合的特定分区","url":"//www.bilibili.com/video/others-1.html"}]},{"name":"美食","route":"food","tid":211,"locid":4243,"count":"","isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4258,"rightId":4264},"sub":[{"name":"美食制作","route":"make","tid":76,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":4268},"desc":"学做人间美味,展示精湛厨艺","url":"#"},{"name":"美食侦探","route":"detective","tid":212,"ps":15,"rps":10,"desc":"寻找美味餐厅,发现街头美食","url":"#"},{"name":"美食测评","route":"measurement","tid":213,"ps":15,"rps":10,"desc":"吃货世界,品尝世间美味","url":"#"},{"name":"田园美食","route":"rural","tid":214,"ps":15,"rps":10,"desc":"品味乡野美食,寻找山与海的味道","url":"#"},{"name":"美食记录","route":"record","tid":215,"ps":15,"rps":10,"desc":"记录一日三餐,给生活添一点幸福感","url":"#"}]},{"name":"动物圈","route":"animal","tid":217,"locid":4365,"count":"","isHide":true,"subMenuSize":164,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","leftId":4376,"rightId":4381,"rightType":"slide"},"sub":[{"name":"喵星人","route":"cat","tid":218,"ps":15,"rps":10,"desc":"喵喵喵喵喵","url":"#","ad":{"active":true,"dataLocId":4385}},{"name":"汪星人","route":"dog","tid":219,"ps":15,"rps":10,"desc":"汪汪汪汪汪","url":"#"},{"name":"大熊猫","route":"panda","tid":220,"ps":15,"rps":10,"desc":"芝麻汤圆营业中","url":"#"},{"name":"野生动物","route":"wild_animal","tid":221,"ps":15,"rps":10,"desc":"内有“猛兽”出没","url":"#"},{"name":"爬宠","route":"reptiles","tid":222,"ps":15,"rps":10,"desc":"鳞甲有灵","url":"#"},{"name":"动物综合","route":"animal_composite","tid":75,"ps":15,"rps":10,"desc":"收录除上述子分区外,其余动物相关视频以及非动物主体或多个动物主体的动物相关延伸内容","url":"#"}]},{"name":"鬼畜","route":"kichiku","tid":119,"locid":100,"count":"","subMenuSize":182,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2509,"leftId":2482,"rightId":2483},"sub":[{"name":"鬼畜调教","route":"guide","tid":22,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":285},"desc":"使用素材在音频、画面上做一定处理,达到与BGM一定的同步感","url":"//www.bilibili.com/video/ent-Kichiku-1.html"},{"name":"音MAD","route":"mad","tid":26,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":287},"desc":"使用素材音频进行一定的二次创作来达到还原原曲的非商业性质稿件","url":"//www.bilibili.com/video/douga-kichiku-1.html"},{"name":"人力VOCALOID","route":"manual_vocaloid","tid":126,"ps":15,"rps":10,"desc":"将人物或者角色的无伴奏素材进行人工调音,使其就像VOCALOID一样歌唱的技术","url":"//www.bilibili.com/video/kichiku-manual_vocaloid-1.html"},{"name":"鬼畜剧场","route":"theatre","tid":216,"ps":15,"rps":10,"desc":"使用素材进行人工剪辑编排的有剧情的作品"},{"name":"教程演示","route":"course","tid":127,"ps":10,"rps":6,"rightComponent":{"name":"CmImgList","id":148},"ad":{"active":true,"dataLocId":289},"hideDropdown":false,"desc":"鬼畜相关的教程演示","url":"//www.bilibili.com/video/kichiku-course-1.html"}]},{"name":"时尚","route":"fashion","tid":155,"locid":94,"count":"","subMenuSize":124,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2515,"leftId":2492,"rightId":2493},"sub":[{"name":"美妆","route":"makeup","tid":157,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":279},"desc":"涵盖妆容、发型、美甲等教程,彩妆、护肤相关产品测评、分享等","url":"//www.bilibili.com/video/fashion-makeup-fitness-1.html"},{"name":"服饰","route":"clothing","tid":158,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":281},"desc":"服饰风格、搭配技巧相关的展示和教程视频","url":"//www.bilibili.com/video/fashion-clothing-1.html"},{"name":"T台","route":"catwalk","tid":159,"ps":15,"rps":10,"desc":"发布会走秀现场及模特相关时尚片、采访、后台花絮","url":"#"},{"name":"风尚标","route":"trends","tid":192,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":283},"desc":"时尚明星专访、街拍、时尚购物相关知识科普","url":"#"}]},{"name":"资讯","route":"information","tid":202,"locid":4076,"count":"","subMenuSize":60,"slider":{"width":620,"height":220},"viewTag":false,"sub":[{"name":"热点","route":"hotspot","tid":203,"ps":18,"rps":10,"desc":"全民关注的时政热门资讯"},{"name":"环球","route":"global","tid":204,"ps":18,"rps":10,"desc":"全球范围内发生的具有重大影响力的事件动态"},{"name":"社会","route":"social","tid":205,"ps":18,"rps":10,"desc":"日常生活的社会事件、社会问题、社会风貌的报道"},{"name":"综合","route":"multiple","tid":206,"ps":18,"rps":10,"desc":"除上述领域外其它垂直领域的综合资讯"}]},{"name":"娱乐","route":"ent","tid":5,"locid":82,"count":"","subMenuSize":62,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2067,"leftId":2065,"rightId":2066},"sub":[{"name":"综艺","route":"variety","tid":71,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":267},"desc":"国内外有趣的综艺和综艺相关精彩剪辑","url":"//www.bilibili.com/video/ent-variety-1.html"},{"name":"明星","route":"star","tid":137,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":269},"desc":"娱乐圈动态、明星资讯相关","url":"//www.bilibili.com/video/ent-circle-1.html"}]},{"name":"影视","route":"cinephile","tid":181,"locid":2211,"count":"","subMenuSize":84,"slider":{"width":620,"height":220},"viewTag":false,"customComponent":{"name":"Energy","titleId":2309,"leftId":2307,"rightId":2308},"sub":[{"name":"影视杂谈","route":"cinecism","tid":182,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2212},"desc":"影视评论、解说、吐槽、科普等","url":"//www.bilibili.com/video/cinephile-cinecism.html"},{"name":"影视剪辑","route":"montage","tid":183,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2213},"desc":"对影视素材进行剪辑再创作的视频","url":"//www.bilibili.com/video/cinephile-montage.html"},{"name":"短片","route":"shortfilm","tid":85,"ps":15,"rps":10,"desc":"追求自我表达且具有特色的短片","url":"//www.bilibili.com/video/cinephile-shortfilm.html"},{"name":"预告·资讯","route":"trailer_info","tid":184,"ps":15,"rps":10,"ad":{"active":true,"dataLocId":2214},"desc":"影视类相关资讯,预告,花絮等视频","url":"//www.bilibili.com/video/cinephile-trailer-info.html"}]},{"name":"纪录片","route":"documentary","tid":177,"url":"//www.bilibili.com/documentary/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"人文·历史","tid":37,"route":"history","dise":"","url":"//www.bilibili.com/video/doco-history.html"},{"name":"科学·探索·自然","tid":178,"route":"science","dise":"","url":"//www.bilibili.com/video/doco-science.html"},{"name":"军事","tid":179,"route":"military","dise":"","url":"//www.bilibili.com/video/doco-military.html"},{"name":"社会·美食·旅行","tid":180,"route":"travel","dise":"","url":"//www.bilibili.com/video/doco-travel.html"},{"name":"纪录片索引","url":"//www.bilibili.com/documentary/index/"}]},{"name":"电影","route":"movie","tid":23,"url":"//www.bilibili.com/movie/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"华语电影","tid":147,"route":"chinese","desc":"","url":"//www.bilibili.com/video/movie_chinese_1.html"},{"name":"欧美电影","tid":145,"route":"west","desc":"","url":"//www.bilibili.com/video/movie_west_1.html"},{"name":"日本电影","tid":146,"route":"japan","desc":"","url":"//www.bilibili.com/video/movie_japan_1.html"},{"name":"其他国家","tid":83,"route":"movie","desc":"","url":"//www.bilibili.com/video/movie-movie-1.html"},{"name":"电影索引","url":"//www.bilibili.com/movie/index/"}]},{"name":"电视剧","route":"tv","tid":11,"url":"//www.bilibili.com/tv/","count":"","takeOvered":true,"hasParent":true,"combination":true,"sub":[{"name":"国产剧","tid":185,"route":"mainland","desc":"","url":"//www.bilibili.com/video/tv-mainland.html"},{"name":"海外剧","tid":187,"route":"overseas","desc":"","url":"//www.bilibili.com/video/tv-overseas.html"},{"name":"电视剧索引","url":"//www.bilibili.com/tv/index/"}]}],[{"url":"//live.bilibili.com/all?visit_id=5icxsa0kmts0","name":"全部直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=2&areaId=0&visit_id=5icxsa0kmts0#/2/0","name":"网游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=3&areaId=0&visit_id=5icxsa0kmts0#/3/0","name":"手游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=6&areaId=0","name":"单机直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=1&areaId=0&visit_id=5icxsa0kmts0#/1/0","name":"娱乐直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=5&areaId=0&visit_id=5icxsa0kmts0#/5/0","name":"电台直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=9&areaId=0","name":"虚拟直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=10&areaId=0","name":"生活直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=11&areaId=0","name":"学习直播"}],[{"name":"会员购","url":"//show.bilibili.com/platform/home.html","icon":"icon-vip-buy"},{"name":"游戏中心","url":"//game.bilibili.com","icon":"icon-game"},{"name":"画友","url":"http://h.bilibili.com","icon":"icon-hy"},{"name":"芒果TV","url":"//www.bilibili.com/mango","icon":"icon-mango"}],[{"name":"专栏","report":"article","url":"//www.bilibili.com/read/home","icon":"read"},{"name":"直播","report":"live","url":"//live.bilibili.com","icon":"live","sub":[{"url":"//live.bilibili.com/all?visit_id=5icxsa0kmts0","name":"全部直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=2&areaId=0&visit_id=5icxsa0kmts0#/2/0","name":"网游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=3&areaId=0&visit_id=5icxsa0kmts0#/3/0","name":"手游直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=6&areaId=0","name":"单机直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=1&areaId=0&visit_id=5icxsa0kmts0#/1/0","name":"娱乐直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=5&areaId=0&visit_id=5icxsa0kmts0#/5/0","name":"电台直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=9&areaId=0","name":"虚拟直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=10&areaId=0","name":"生活直播"},{"url":"//live.bilibili.com/p/eden/area-tags?parentAreaId=11&areaId=0","name":"学习直播"}]},{"name":"活动","report":"activity","url":"//www.bilibili.com/blackboard/activity-list.html","icon":"activit"},{"name":"课堂","report":"cheese","url":"//www.bilibili.com/cheese/","icon":"zhishi"},{"name":"小黑屋","report":"blackroom","url":"//www.bilibili.com/blackroom/","icon":"blackroom"},{"name":"新歌热榜","report":"musicplus","url":"//www.bilibili.com/v/musicplus/","icon":"musicplus"}],[{"name":"搞笑","url":"//www.bilibili.com/v/life/funny","tid":138,"count":"","hidePopover":true,"combination":true},{"name":"美食","url":"//www.bilibili.com/v/food","tid":211,"count":"","hidePopover":true,"combination":true},{"name":"动物圈","url":"//www.bilibili.com/v/animal","tid":217,"count":"","hidePopover":true,"combination":true},{"name":"单机游戏","url":"//www.bilibili.com/v/game/stand_alone","tid":17,"count":"","hidePopover":true,"combination":true},{"name":"运动","url":"//www.bilibili.com/v/sports","tid":234,"count":"","hidePopover":true,"combination":true},{"name":"汽车","url":"//www.bilibili.com/v/car","tid":223,"count":"","hidePopover":true,"combination":true},{"name":"VLOG","url":"//www.bilibili.com/v/life/daily/#/530003","hidePopover":true,"hideCount":true,"combination":true}]]'),dn=e=>e.startsWith("//")?`https:${e}`:e.replace("http:","https:"),un=cn[0].filter((e=>"string"!=typeof e.tid)),pn=cn[3],hn={},fn=["纪录片","电影","电视剧"];un.forEach((e=>{const t=dn(e.url||`https://www.bilibili.com/v/${e.route}/`);hn[e.name]={icon:e.route,code:e.tid,link:t,subCategories:e.sub?Object.fromEntries(e.sub.map((e=>{const n=dn(`${t}${e.route}/`);return[e.name,n]}))):null}})),hn.放映厅={icon:"cinema",code:fn.map((e=>hn[e].code)),link:"https://www.bilibili.com/cinema/",subCategories:Object.fromEntries(fn.map((e=>[e,hn[e].link])))},fn.forEach((e=>delete hn[e])),pn.forEach((e=>{hn[e.name]={icon:e.icon,code:null,link:dn(e.url),subCategories:e.sub?Object.fromEntries(e.sub.map((e=>[e.name,dn(e.url)]))):null}}));const mn=hn,gn=Object.fromEntries(un.map((e=>[e.route,e.tid]))),vn=Object.fromEntries(Object.values(hn).map((e=>[e.icon,e.link]))),bn=async()=>{if(document.getElementById("be-category-icons"))return;const{default:e}=await Promise.resolve().then(n.bind(n,382));document.body.insertAdjacentHTML("beforeend",e)};var yn=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"translate-container"},[e.working||e.translated?e._e():n("div",{staticClass:"translate",on:{click:function(t){return e.translate()}}},[n("VIcon",{attrs:{size:14,icon:"mdi-earth"}}),e._v("翻译\n ")],1),e._v(" "),e.translated?n("div",{staticClass:"translated"},[n("a",{attrs:{href:e.activeTranslator&&e.activeTranslator.link,target:"_blank"}},[e._v("\n 翻译自\n ")]),e._v(" "),n("VDropdown",{attrs:{items:Object.values(e.translateProviders),value:e.activeTranslator,"key-mapper":function(e){return e.name}},on:{change:function(t){return e.changeTranslator(t)}},scopedSlots:e._u([{key:"item",fn:function(t){var n=t.item;return[e._v("\n "+e._s(n.name)+"\n ")]}}],null,!1,1956376614)})],1):e._e(),e._v(" "),e.working?n("VIcon",{staticClass:"translating mdi-spin",attrs:{size:18,icon:"mdi-loading"}}):e._e(),e._v(" "),!e.working&&e.translated?n("div",{staticClass:"translate-result",domProps:{textContent:e._s(e.result)}}):e._e()],1)};yn._withStripped=!0;var wn=n(1993),xn=Vue.extend({components:{VDropdown:ce.VDropdown,VIcon:ce.VIcon},props:{text:{type:String,required:!0}},data:()=>({result:"",working:!1,translateProviders:wn.WK,activeTranslator:{}}),computed:{translated(){return""!==this.result}},methods:{changeTranslator(e){(0,R.getComponentSettings)("i18n").options.translator=e.name,this.translate()},async translate(){try{this.working=!0;const e=this.text.replace(/#(.+?)#/g,"");this.activeTranslator=(0,wn.Ty)();const t=this.activeTranslator;this.result=await t.translate(e)}catch(e){(0,ae.logError)(e)}finally{this.working=!1}}}}),_n=n(4618),kn=n.n(_n),Cn={insert:"head",singleton:!1},Sn=(Ne()(kn(),Cn),kn().locals,(0,Re.Z)(xn,yn,[],!1,null,null,null));Sn.options.__file="src/components/i18n/machine-translator/MachineTranslator.vue";var En=Sn.exports;const Mn=e=>{void 0===e.radio&&(e.radio=!1);const{name:t,switches:i}=e,a={};return Object.entries(i).forEach((([e,{displayName:t,defaultValue:n}])=>{a[`switch-${e}`]={defaultValue:n,displayName:t,hidden:!0}})),i=>{const r=`${i.displayName}选项`,o={componentName:i.name,optionDisplayName:r};Object.assign(e,o),a[t]={defaultValue:e,displayName:r},i.options={...i.options,...a},i.widget||(i.widget={component:()=>Promise.resolve().then(n.bind(n,8769)).then((e=>e.default)),options:e});const s=i.entry;return i.entry=async(...e)=>{s?.(...e);const{name:t}=i,n=(0,R.getComponentSettings)(t).options;Object.keys(n).forEach((e=>{e.startsWith("switch-")&&(0,R.addComponentListener)(`${t}.${e}`,(n=>{document.body.classList.toggle(`${t}-${e}`,n)}),!0)}))},i}};const zn={component:de,userComponent:ue,styledComponent:s,description:fe,switchOptions:k,launchBar:{LaunchBar:n(3059).Z},feeds:{api:c,BangumiCard:Ze,VideoCard:Qe,ColumnCard:ot,disableProfilePopup:d,notify:u},video:{assUtils:p,playerLight:h,playerAgent:kt,videoDanmaku:f,videoInfo:m,videoQuality:g,videoContextMenu:v,videoControlBar:b,watchlater:l},live:{liveControlBar:y,liveSocket:w},utils:{commentApis:x,categories:{updater:ln,data:_}},i18N:{machineTranslator:{MachineTranslator:En}}};var An=n(8900),$n=n(1623),On=n(9543);const In={style:An,plugin:$n,data:be,hook:On},Ln={ajax:C,cdnTypes:S,download:E,externalInput:M,filePicker:z,lifeCycle:A,loadingMode:$,meta:O,observer:I,reorder:i,runtimeLibrary:N,spinQuery:j,style:q,textColor:H,userInfo:a,version:r,settings:R,toast:se,themeColor:le,utils:{...X,constants:K,formatters:J,title:Y,i18n:Q,lazyPanel:o,log:ae,sort:re,urls:oe},ui:ce,componentApis:zn,pluginApis:In},Tn={ajax:C,...S,...E,...M,...z,lifeCycle:A,...$,...O,observer:I,...i,runtimeLibrary:N,spinQuery:j,...q,...H,...a,...r,settingsApis:R,get settings(){return R.settings},...se,utils:{...X,...K,...J,...Y,...Q,...o,...ae,...re,...oe},ui:ce,componentApis:{...zn.component,...zn.userComponent,...zn.styledComponent,...zn.launchBar,...lodash.omit(zn,"component","userComponent","styledComponent","launchBar")},pluginApis:{...In.style,...In.plugin,...In.data,...In.hook},monkeyApis:{GM_setValue:GM_setValue,GM_getValue:GM_getValue,GM_deleteValue:GM_deleteValue,GM_setClipboard:GM_setClipboard,GM_xmlhttpRequest:GM_xmlhttpRequest,GM_info:GM_info},lodash:lodash,Vue:Vue,sandboxWindow:window,theWorld:e=>{setTimeout((()=>{}),e)}}},5300:function(e,t,n){"use strict";let i;n.d(t,{h:function(){return i}}),function(e){e.packed="打包下载",e.individual="单独下载"}(i||(i={}))},4114:function(e,t,n){"use strict";n.r(t),n.d(t,{DownloadPackage:function(){return l}});var i=n(5300),a=n(391),r=n(6171),o=n(3708);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class l{constructor(e=[]){this.entries=e,s(this,"noEscape",!1)}add(e,t,n={}){null!=t&&this.entries.push({name:this.noEscape?e:(0,o.formatFilename)(e),data:t,options:n})}async blob(){if(0===this.entries.length)return null;if(1===this.entries.length){const{data:e}=this.entries[0];return"string"==typeof e?new Blob([e]):e}const e=new(await a.JSZipLibrary);return this.entries.forEach((({name:t,data:n,options:i})=>{e.file(t,n,i)})),e.generateAsync({type:"blob"})}async emit(e){if(0===this.entries.length)return;e&&1!==this.entries.length||(e=this.entries[0].name);if((0,r.getGeneralSettings)().downloadPackageEmitMode===i.h.individual&&this.entries.length>1)return void await Promise.all(this.entries.map((e=>l.single(e.name,e.data,e.options))));const t=await this.blob();t&&l.download(e,t)}static download(e,t){const n=document.createElement("a"),i=URL.createObjectURL(t);l.lastPackageUrl&&URL.revokeObjectURL(l.lastPackageUrl),l.lastPackageUrl=i;const a=(0,o.formatFilename)(e);n.setAttribute("href",i),n.setAttribute("download",a),console.log("[Download file]",a),document.body.appendChild(n),n.click(),n.remove()}static async single(e,t,n={}){const i=new l;return i.add(e,t,n),i.emit()}}s(l,"lastPackageUrl","")},7731:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{parseExternalInput:function(){return parseExternalInput},batchParseCode:function(){return batchParseCode}});var _file_picker__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(7590);const parseExternalInput=async input=>{if(void 0===input){const files=await(0,_file_picker__WEBPACK_IMPORTED_MODULE_0__.pickFile)({accept:"application/json"});if(!(files.length>0))return console.error("[parseExternalInput] No file selected"),null;{const[file]=files,text=await file.text();try{return eval(`(${text})`)}catch(e){return console.error(e),null}}}else{if("string"!=typeof input)return input;try{const exports={},result=eval(input);if(Object.values(exports).length>0){const e=Object.values(exports)[0];return e}return result}catch(e){return console.error(e),null}}},batchParseCode=async inputs=>{try{const exports={},result=inputs.map((input=>eval(input)));if(Object.values(exports).length>0){const{coreApis:e}=await Promise.resolve().then(__webpack_require__.bind(__webpack_require__,9388));return Object.values(exports).map((t=>"function"==typeof t?t(e):t))}return result}catch(e){return console.error(e),null}}},7590:function(e,t,n){"use strict";let i,a;n.r(t),n.d(t,{pickFile:function(){return o}});const r={accept:"*",multiple:!1},o=async(e=r)=>{const{accept:t,multiple:n}={...r,...e};i||(i=document.createElement("input"),i.type="file",i.style.display="none",document.body.appendChild(i),i.addEventListener("change",(()=>{a?.([...i.files]),a=null}))),i.accept=t,i.multiple=n,i.value="",a&&a([]);return await new Promise((e=>{a=e,i.click()}))}},9513:function(e,t,n){"use strict";n.d(t,{m:function(){return s}});var i=n(7010),a=n(9543),r=n(1623),o=n(8900);const s=async e=>{const{monkey:t}=await Promise.resolve().then(n.bind(n,7195)),s=await t({url:e}),{parseExternalInput:l}=await Promise.resolve().then(n.bind(n,7731)),c=await l(s),{type:d,installer:u}=(()=>{if((e=>"entry"in e)(c))return{type:"component",installer:()=>(0,i.installComponent)(s)};if((e=>"setup"in e)(c))return{type:"plugin",installer:()=>(0,r.installPlugin)(s)};if((e=>"style"in e)(c))return{type:"style",installer:()=>(0,o.installStyle)(s)};throw new Error("无效的功能代码")})(),{before:p,after:h}=(0,a.getHook)(`user${lodash.startCase(d)}s.add`,s,e);await p();const f=await u();return await h(f.metadata),f}},7177:function(e,t,n){"use strict";n.r(t),n.d(t,{headLoaded:function(){return a},contentLoaded:function(){return r},fullyLoaded:function(){return o},LifeCycleEventTypes:function(){return s},raiseLifeCycleEvent:function(){return l}});var i=n(3420);const a=e=>new Promise((t=>{if(null!==document.head)t(e());else{const[n]=(0,i.childList)(document.documentElement,(()=>{null!==document.head&&(n.disconnect(),t(e()))}))}})),r=e=>new Promise((t=>{"loading"!==document.readyState?t(e()):document.addEventListener("DOMContentLoaded",(()=>t(e())))})),o=e=>new Promise((t=>{"complete"===document.readyState?t(e()):unsafeWindow.addEventListener("load",(()=>t(e())))}));let s;!function(e){e.Start="be:start",e.StyleLoaded="be:style-loaded",e.ComponentsLoaded="be:components-loaded",e.End="be:end"}(s||(s={}));const l=e=>{unsafeWindow.dispatchEvent(new CustomEvent(e))}},4345:function(e,t,n){"use strict";let i;n.r(t),n.d(t,{LoadingMode:function(){return i}}),function(e){e.Delay="延后",e.Race="同时"}(i||(i={}))},1836:function(e,t,n){"use strict";n.r(t),n.d(t,{branches:function(){return r},meta:function(){return s}});var i=JSON.parse('{"version":"2.0.0","author":"Grant Howard, Coulomb-G","copyright":"[year], Grant Howard (https://github.com/the1812) & Coulomb-G (https://github.com/Coulomb-G)","licence":"MIT","match":"*://*.bilibili.com/*","exclude":["*://api.bilibili.com/*","*://api.*.bilibili.com/*","*://*.bilibili.com/api/*","*://member.bilibili.com/studio/bs-editor/*","*://message.bilibili.com/pages/nav/index_new_sync","*://message.bilibili.com/pages/nav/index_new_pc_sync","*://t.bilibili.com/h5/dynamic/specification","*://bbq.bilibili.com/*"],"run-at":"document-start","supportURL":"https://github.com/the1812/Bilibili-Evolved/issues","homepage":"https://github.com/the1812/Bilibili-Evolved","grant":["unsafeWindow","GM_getValue","GM_setValue","GM_deleteValue","GM_setClipboard","GM_info","GM_xmlhttpRequest"],"connect":["raw.githubusercontent.com","github.com","cdn.jsdelivr.net","cn.bing.com","www.bing.com","translate.google.cn","translate.google.com","localhost","*"],"require":["https://cdn.jsdelivr.net/npm/lodash@4.17.21/lodash.min.js"],"icon":"https://cdn.jsdelivr.net/gh/the1812/Bilibili-Evolved@preview/images/logo-small.png","icon64":"https://cdn.jsdelivr.net/gh/the1812/Bilibili-Evolved@preview/images/logo.png"}'),a=n(2462);i.copyright=i.copyright.replace(/\[year\]/g,(new Date).getFullYear().toString());const r={stable:"v2",preview:"preview"},o={commitHash:"eb759ea254acb0e2f4b4a8ec428a8cf421ca2731",branch:"preview",nearestTag:"v2.0.0-preview1",versionWithTag:"v2.0.0-preview1-10-geb759ea25"},s={compilationInfo:o,name:GM_info.script.name,description:GM_info.script.description,get originalFilename(){const{branch:e}=o;return e===r.stable?"bilibili-evolved.user.js":`bilibili-evolved.${e}.user.js`},get updateURL(){return`${a.cdnRoots.jsDelivr(o.branch)}dist/${this.originalFilename}`},get downloadURL(){return this.updateURL},...i}},3420:function(e,t,n){"use strict";n.r(t),n.d(t,{childList:function(){return l},childListSubtree:function(){return c},attributes:function(){return d},attributesSubtree:function(){return u},characterData:function(){return p},characterDataSubtree:function(){return h},allMutationsOn:function(){return f},allMutations:function(){return g},visible:function(){return b},visibleInside:function(){return y},sizeChange:function(){return w},urlChange:function(){return _},videoChange:function(){return S}});var i=n(1906),a=n(5550),r=n(7735);const o=e=>"string"==typeof e?(0,i.dqa)(e):Array.isArray(e)?e:[e],s=(e,t,n)=>{const i=new MutationObserver(n);return e.forEach((e=>i.observe(e,t))),n([],i),[i,t]},l=(e,t)=>s(o(e),{childList:!0,subtree:!1,attributes:!1},t),c=(e,t)=>s(o(e),{childList:!0,subtree:!0,attributes:!1},t),d=(e,t)=>s(o(e),{childList:!1,subtree:!1,attributes:!0},t),u=(e,t)=>s(o(e),{childList:!1,subtree:!0,attributes:!0},t),p=(e,t)=>s(o(e),{childList:!1,subtree:!1,attributes:!1,characterData:!0},t),h=(e,t)=>s(o(e),{childList:!1,subtree:!0,attributes:!1,characterData:!0},t),f=(e,t)=>s(o(e),{childList:!0,subtree:!0,attributes:!0,characterData:!0},t),m={observer:null,config:null,callbacks:[]},g=e=>{if(m.observer)m.callbacks.push(e);else{m.callbacks.push(e);const[t,n]=f(document.body,(e=>m.callbacks.forEach((t=>t(e,m.observer)))));m.observer=t,m.config=n}return m},v=(e,t,n)=>{const i=new IntersectionObserver(n,t);return e.forEach((e=>i.observe(e))),[i,t]},b=(e,t)=>v(o(e),{},t),y=(e,t,n,i)=>v(o(e),{root:t,rootMargin:n},i),w=(e,t)=>((e,t,n)=>{const i=new ResizeObserver(n);return e.forEach((e=>i.observe(e,t))),[i,t]})(o(e),{box:"border-box"},t),x=lodash.once((()=>{let e=document.URL;g((()=>{e!==document.URL&&((()=>{const e=new CustomEvent("urlChange",{detail:document.URL});window.dispatchEvent(e)})(),e=document.URL)}))})),_=(e,t)=>{x(),e(document.URL),window.addEventListener("urlChange",(()=>e(document.URL)),t)},k=lodash.once((()=>(0,a.select)((()=>{if(unsafeWindow.cid)return unsafeWindow.cid;if(unsafeWindow.player&&unsafeWindow.player.getVideoMessage){const e=unsafeWindow.player.getVideoMessage();return Number.isNaN(e.cid)?null:(!unsafeWindow.aid&&e.aid&&(unsafeWindow.aid=e.aid.toString()),!unsafeWindow.bvid&&e.bvid&&(unsafeWindow.bvid=e.bvid),e.cid.toString())}return null}))));let C=!1;const S=async(e,t)=>{if(!(0,r.matchCurrentPage)(r.playerUrls))return!1;const{bpxPlayerPolyfill:i}=await Promise.resolve().then(n.bind(n,6958));i();const a=await k();if(null===a)return!1;const o=()=>({aid:unsafeWindow.aid,cid:unsafeWindow.cid});if(!C){let e=a;Object.defineProperty(unsafeWindow,"cid",{get:()=>e,set(t){e=t,Array.isArray(t)||(()=>{const e=o(),t=new CustomEvent("videoChange",{detail:e});window.dispatchEvent(t)})()}}),C=!0}return e(o()),window.addEventListener("videoChange",(t=>e(t.detail)),t),!0}},1485:function(e,t,n){"use strict";n.r(t),n.d(t,{componentLoadTime:function(){return i},componentResolveTime:function(){return a},componentLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async e=>{const{getGeneralSettings:t}=await Promise.resolve().then(n.bind(n,6171));if(!t().devMode)return;const r=e.entry;e.entry=async e=>{const{metadata:t}=e,n=performance.now();let o=r(e);const s=performance.now();o instanceof Promise&&(o=await o);const l=performance.now();return i.set(t,s-n),a.set(t,l-n),o}}},8970:function(e,t,n){"use strict";n.r(t),n.d(t,{pluginLoadTime:function(){return i},pluginResolveTime:function(){return a},pluginLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async e=>{const{getGeneralSettings:t}=await Promise.resolve().then(n.bind(n,6171));if(!t().devMode)return;const r=e.setup;e.setup=async t=>{const n=performance.now();let o=r(t);const s=performance.now();o instanceof Promise&&(o=await o);const l=performance.now();return i.set(e,s-n),a.set(e,l-n),o}}},719:function(e,t,n){"use strict";n.r(t),n.d(t,{promiseLoadTime:function(){return i},promiseResolveTime:function(){return a},promiseLoadTrace:function(){return r}});const i=new Map,a=new Map,r=async(e,t)=>{const{getGeneralSettings:r}=await Promise.resolve().then(n.bind(n,6171));if(!r().devMode)return t();const o=performance.now(),s=t(),l=performance.now(),c=await s,d=performance.now();return i.set({name:e},l-o),a.set({name:e},d-o),c}},9476:function(e,t,n){"use strict";n.r(t),n.d(t,{logStats:function(){return i}});const i=(e,t)=>{const n=[...t.entries()],i=n.reduce(((e,t)=>e+t[1]),0);console.groupCollapsed(`${e} time:`,Math.round(100*i)/100+"ms",`for ${n.length} items`),n.forEach((([e,t])=>{console.log(`%c${e.name} %c${Math.round(100*t)/100}ms ${Math.round(t/i*1e4)/100}% %c`,"color: #00A0D8","color: #888","color: unset")})),console.groupEnd()}},391:function(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{RuntimeLibrary:function(){return RuntimeLibrary},protobufLibrary:function(){return protobufLibrary},JSZipLibrary:function(){return JSZipLibrary},SortableJSLibrary:function(){return SortableJSLibrary}});var _ajax__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(7195);function _defineProperty(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class RuntimeLibrary{constructor(e){this.config=e,_defineProperty(this,"modulePromise",void 0)}async then(resolve,reject){try{const{url:url,getModule:getModule}=this.config;this.modulePromise||(this.modulePromise=(async()=>{console.log(`[Runtime Library] Start download from ${url}`);const code=await(0,_ajax__WEBPACK_IMPORTED_MODULE_0__.monkey)({url:url});return console.log(`[Runtime Library] Downloaded from ${url} , length = ${code.length}`),function runEval(){return eval(code);// eslint-disable-next-line no-extra-bind }.bind(window)(),getModule(window)})());const library=await this.modulePromise;return resolve(library)}catch(e){throw reject(e),e}}}const protobufLibrary=new RuntimeLibrary({url:"https://cdn.jsdelivr.net/npm/protobufjs@6.10.1/dist/light/protobuf.min.js",getModule:e=>e.protobuf}),JSZipLibrary=new RuntimeLibrary({url:"https://cdn.jsdelivr.net/npm/jszip@3.7.1/dist/jszip.min.js",getModule:e=>e.JSZip}),SortableJSLibrary=new RuntimeLibrary({url:"https://cdn.jsdelivr.net/npm/sortablejs@1.14.0/Sortable.min.js",getModule:e=>e.Sortable})},5605:function(e,t,n){"use strict";n.r(t),n.d(t,{componentOptionsToSettings:function(){return o},componentToSettings:function(){return s},isUserComponent:function(){return l},isUserPlugin:function(){return c},getComponentSettings:function(){return u},getGeneralSettings:function(){return p},isComponentEnabled:function(){return h}});var i=n(8171),a=n(6171),r=n(1906);const o=e=>lodash.fromPairs(Object.entries(e).map((([e,t])=>[e,t.defaultValue]))),s=e=>({enabled:e.enabledByDefault??!0,options:e.options?o(e.options):{}}),l=e=>{const t="string"==typeof e?e:e.name;return Boolean(a.settings.userComponents[t])},c=e=>{const t="string"==typeof e?e:e.name;return Boolean(a.settings.userPlugins[t])},d={enabled:!1,options:new Proxy({},{get:()=>!1})},u=e=>{if("string"==typeof e){const t=i.componentsMap[e];if(void 0===t)return a.settings.components.settingsPanel.options.devMode&&console.warn("No settings found for component:",e),d;e=t}if(l(e)){const{name:t}=e;return a.settings.userComponents[t]?.settings??d}return a.settings.components[e.name]},p=()=>u("settingsPanel").options,h=e=>("string"==typeof e&&(e=i.componentsMap[e]),(!e.urlExclude||!e.urlExclude.some(r.matchUrlPattern))&&((!e.urlInclude||!e.urlInclude.every(lodash.negate(r.matchUrlPattern)))&&(!1===e.configurable?e.enabledByDefault??!0:u(e).enabled)))},6171:function(e,t,n){"use strict";n.r(t),n.d(t,{isProxy:function(){return c},createProxy:function(){return d},defaultSettings:function(){return u},addSettingsChangeListener:function(){return p},removeSettingsChangeListener:function(){return h},addComponentListener:function(){return m},removeComponentListener:function(){return g},settings:function(){return v},componentOptionsToSettings:function(){return r.componentOptionsToSettings},componentToSettings:function(){return r.componentToSettings},getComponentSettings:function(){return r.getComponentSettings},getGeneralSettings:function(){return r.getGeneralSettings},isComponentEnabled:function(){return r.isComponentEnabled},isUserComponent:function(){return r.isUserComponent},isUserPlugin:function(){return r.isUserPlugin}});var i=n(8171),a=n(1623),r=n(5605);let o={userStyles:{},userPlugins:{},userComponents:{},components:{},plugins:{}},s=!1;const l=new Map,c=Symbol("isProxy"),d=(e,t)=>{const n=(e,i,a=[])=>{for(const[t,r]of Object.entries(e))"object"!=typeof r||r instanceof RegExp||(e[t]=n(r,i||t,[...a,t]));return new Proxy(e,{get:(e,t)=>t===c||e[t],set(e,r,o){"object"!=typeof o||o instanceof RegExp||!0===o[c]||(o=n(o,i||r,[...a,r]));const s=e[r];return e[r]=o,t(o,s,i||r,[...a,r]),!0},deleteProperty(e,n){const r=e[n];return delete e[n],t(void 0,r,i||n,[...a,n]),!0}})};return n(e)};a.plugins.forEach((e=>{o.plugins[e.name]=!0})),i.components.forEach((e=>{o.components[e.name]=(0,r.componentToSettings)(e)}));const u=lodash.cloneDeep(o);o=d((e=>{for(const[t,n]of Object.entries(e)){let i;const a=GM_getValue(t,n);i="object"==typeof a?lodash.defaultsDeep(a,n):a,e[t]=i}return e})(o),((e,t,n,i=[])=>{if(s){GM_setValue(n.toString(),o[n.toString()]);const a=i.join(".");if(i.length>1){const e=i.slice(0,i.length-1).join("."),t=lodash.get(o,e);if(Array.isArray(t)||lodash.isPlainObject(t)){l.get(e)?.forEach((e=>e(t,null,n,i)))}}l.get(a)?.forEach((a=>a(e,t,n,i)))}}));for(const[e,t]of Object.entries(o))GM_setValue(e,t);const p=(e,t,n=!1)=>{const i=l.get(e);if(i?i.push(t):l.set(e,[t]),n){const n=lodash.get(o,e);t(n,n,"",[])}},h=(e,t)=>{const n=l.get(e);if(!n)return;const i=n.indexOf(t);-1!==i&&n.splice(i,1)},f=e=>{const[t,n]=e.split(".");return(0,r.isUserComponent)(t)?void 0===n?`userComponents.${t}.settings.enabled`:`userComponents.${t}.settings.options.${n}`:void 0===n?`components.${t}.enabled`:`components.${t}.options.${n}`},m=(e,t,n=!1)=>{p(f(e),t,n)},g=(e,t)=>{h(f(e),t)};s=!0;const v=o},5550:function(e,t,n){"use strict";n.r(t),n.d(t,{sq:function(){return o},select:function(){return c},selectLazy:function(){return d},selectAll:function(){return h},selectAllLazy:function(){return f},count:function(){return m},hasVideo:function(){return v}});var i=n(3420),a=n(1906);const r={maxRetry:15,queryInterval:1e3},o=(e,t=(e=>Boolean(e)),n=r)=>{const i={...r,...n};return new Promise((n=>{let r=null,o=0;const s=()=>{n(r)},l=()=>{o>i.maxRetry?n(null):(r=e(),!0===t(r,s)?n(r):setTimeout((()=>{"undefined"!=typeof document?(0,a.waitForForeground)((()=>{o++,l()})):l()}),i.queryInterval))};l()}))},s=new Map,l=(e,t)=>{let n;if("string"==typeof e){if(s.has(e))return s.get(e);n=()=>document.querySelector((0,a.bwpVideoFilter)(e))}else n=e;const i=t(n);if("string"==typeof e){const t=i.then((t=>(s.delete(e),t)));return s.set(e,t),t}return i},c=(e,t)=>l(e,(e=>o(e,(e=>null!=e),t))),d=e=>l(e,(e=>new Promise((t=>{(0,i.allMutations)((()=>{const n=e();null!=n&&t(n)}))})))),u=new Map,p=(e,t)=>{let n;if("string"==typeof e){if(u.has(e))return u.get(e);n=()=>Array.from(document.querySelectorAll((0,a.bwpVideoFilter)(e)))}else n=e;const i=e=>null===e?[]:e,r=t(n);if("string"==typeof e){const t=r.then((t=>(u.delete(e),i(t))));return u.set(e,t),t}return r.then((e=>i(e)))},h=(e,t)=>p(e,(e=>o(e,(e=>e.length>0),t))),f=e=>p(e,(e=>new Promise((t=>{(0,i.allMutations)((()=>{const n=e();null!=n&&t(n)}))})))),m=(e,t,n)=>o(e,(e=>e.length===t),n);let g;const v=async()=>{g||(g=new Promise((e=>(0,i.videoChange)((()=>e(unsafeWindow.cid))))));const e=await g;return Boolean(e)}},6182:function(e,t,n){"use strict";n.r(t),n.d(t,{getDefaultStyleID:function(){return a},addStyle:function(){return r},addImportantStyle:function(){return o},removeStyle:function(){return s},loadInstantStyle:function(){return l},preloadStyles:function(){return c},loadAllCustomStyles:function(){return d}});var i=n(7177);const a=e=>e.replace(/([a-z][A-Z])/g,(e=>`${e[0]}-${e[1].toLowerCase()}`)),r=(e,t,n)=>{const i=t?a(t):null,r=dq(`#${i}`);if(!r||!t){const t=document.createElement("style");return t.id=i,t.textContent=e,(n||document.head).insertAdjacentElement("beforeend",t),t}return r},o=(e,t)=>r(e,t,document.body),s=(...e)=>{e.forEach((e=>{const t=a(e);dqa(`#${t}`).forEach((e=>e.remove()))}))},l=async(e,t={head:document.head,body:document.body})=>{e.instantStyles?.forEach((async e=>{const n=document.createElement("style");if(n.id=a(e.name),"string"==typeof e.style)n.textContent=e.style;else{const{default:t}=await e.style();n.textContent=t}e.important?t.body.appendChild(n):t.head.appendChild(n)}))},c=lodash.once((async()=>{const{LoadingMode:e}=await Promise.resolve().then(n.bind(n,4345)),{addHook:t}=await Promise.resolve().then(n.bind(n,9543)),{getGeneralSettings:r,settings:o,isComponentEnabled:c,isUserComponent:d,addComponentListener:u,removeComponentListener:p}=await Promise.resolve().then(n.bind(n,6171)),h=async()=>{const{components:e}=await Promise.resolve().then(n.bind(n,8171)),r=document.createDocumentFragment(),h=document.createDocumentFragment();await Promise.all(e.map((e=>{const n=t=>t?l(e):e.instantStyles?.forEach((e=>s(e.name)));if(u(e.name,n),d(e)&&t("userComponents.remove",{after:t=>{t.name===e.name&&p(e.name,n)}}),c(e))return l(e,{head:r,body:h})})));const{UserStyleMode:f}=await Promise.resolve().then(n.bind(n,8900));Object.values(o.userStyles).filter((e=>e.mode===f.instant)).forEach((e=>{const t=document.createElement("style");t.id=a(e.name),t.textContent=e.style,r.appendChild(t)})),document.head.appendChild(r),(0,i.contentLoaded)((()=>document.body.appendChild(h)))};r().styleLoadingMode===e.Delay?await(0,i.contentLoaded)(h):await h(),(0,i.contentLoaded)((async()=>{const{initColors:e}=await Promise.resolve().then(n.bind(n,8208)),{initMdiStyle:t}=await Promise.resolve().then(n.bind(n,3007));document.head.appendChild(e()),document.head.appendChild(t())}))})),d=async()=>{const{settings:e}=await Promise.resolve().then(n.bind(n,6171)),{UserStyleMode:t}=await Promise.resolve().then(n.bind(n,8900));(0,i.contentLoaded)((()=>{Object.values(e.userStyles).filter((e=>e.mode===t.important)).forEach((e=>{r(e.style,e.name,document.body)}))})),Object.values(e.userStyles).filter((e=>e.mode===t.default)).forEach((e=>{r(e.style,e.name,document.head)}))}},6314:function(e,t,n){"use strict";let i;n.r(t),n.d(t,{TextColor:function(){return i}}),function(e){e.Auto="自动",e.White="白色",e.Black="黑色"}(i||(i={}))},8208:function(e,t,n){"use strict";n.r(t),n.d(t,{initColors:function(){return l}});var i=n(6767),a=n.n(i),r=n(6171);const o=(e,t)=>{const n=t.hue()-e.hue(),i=100*((t.saturationv()-e.saturationv())/100+1),a=e=>Math.round(10*e)/10;return`hue-rotate(${a(n)}deg) saturate(${a(i)}%)`};var s=n(6314);const l=()=>{const e=document.createElement("style"),t=new Map,n=(e,n)=>{t.set(e,n)},i=lodash.debounce((()=>{e.textContent=`\n html {\n ${[...t.entries()].map((([e,t])=>`${e}: ${t};`)).join("\n")}\n }\n `.trim()}),100);return(0,r.addComponentListener)("settingsPanel.themeColor",(e=>{n("--theme-color",e);for(let t=10;t<=90;t+=10){const i=a()(e,"hex");n(`--theme-color-${t}`,i.alpha(t/100).rgb().string()),n(`--theme-color-lightness-${t}`,i.lightness(t).rgb().toString())}n("--pink-image-filter",o(a()({r:251,g:113,b:152},"rgb"),a()(e,"hex"))),n("--blue-image-filter",o(a()({r:0,g:160,b:213},"rgb"),a()(e,"hex"))),i()}),!0),(0,r.addComponentListener)("settingsPanel.accentColor",(e=>{n("--accent-color",e),i()}),!0),(0,r.addComponentListener)("settingsPanel.textColor",(e=>{let t;t=e===s.TextColor.Auto?a()(r.settings.themeColor).isLight()?"black":"white":e===s.TextColor.Black?"black":"white",n("--text-color",t),n("--foreground-color",t),n("--foreground-color-d",a()(t,"keyword").alpha(.875).rgb().string()),n("--foreground-color-b",a()(t,"keyword").alpha(.75).rgb().string()),n("--brightness",("black"===t?"100":"0")+"%"),n("--invert-filter","black"===t?"invert(0)":"invert(1)"),i()}),!0),e}},5683:function(e,t,n){"use strict";n.r(t),n.d(t,{Toast:function(){return v},ToastType:function(){return m}});var i=n(1906),a=n(8333),r=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("transition-group",{staticClass:"toast-card-container",attrs:{name:"toast-card-container",tag:"div"}},e._l(e.cards,(function(e){return n("ToastCard",{key:e.key,attrs:{"data-key":e.key,card:e}})})),1)};r._withStripped=!0;var o=Vue.extend({components:{ToastCard:()=>Promise.resolve().then(n.bind(n,7300)).then((e=>e.default))},data:()=>({cards:[]})}),s=n(3379),l=n.n(s),c=n(848),d=n.n(c),u={insert:"head",singleton:!1},p=(l()(d(),u),d().locals,(0,n(1900).Z)(o,r,[],!1,null,null,null));p.options.__file="src/core/toast/ToastCardContainer.vue";var h=p.exports;function f(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}let m,g;!function(e){e.Default="default",e.Info="info",e.Success="success",e.Error="error"}(m||(m={}));class v{constructor(e="",t="",n=m.Default){this.message=e,this.title=t,this.type=n,f(this,"durationNumber",3e3),f(this,"durationTimeout",0),f(this,"creationTime",Number(new Date)),f(this,"randomKey",Math.floor(Math.random()*(Number.MAX_SAFE_INTEGER+1)))}static get containerVM(){return g||v.createToastContainer(),g}static createToastContainer(){dq(".toast-card-container")||(g=(0,i.mountVueComponent)(h),document.body.insertAdjacentElement("beforeend",g.$el))}get element(){return dq(`.toast-card[data-key='${this.key}']`)}get key(){return`${this.creationTime}[${this.randomKey}]`}get duration(){return this.durationNumber}set duration(e){this.durationNumber=e,this.durationTimeout&&this.clearDuration(),this.setDuration()}show(){v.containerVM.cards.unshift(this),this.setDuration()}dismiss(){v.containerVM.cards.includes(this)&&v.containerVM.cards.splice(v.containerVM.cards.indexOf(this),1),this.clearDuration()}setDuration(){void 0!==this.durationNumber&&(this.durationTimeout=window.setTimeout((()=>this.dismiss()),this.durationNumber))}clearDuration(){window.clearTimeout(this.durationTimeout),this.durationTimeout=0}static internalShow(e,t,n,i){const a=new v(e,t,i);return a.duration=n,a.show(),a}static show(e,t,n){return this.internalShow(e,t,n,m.Default)}static info(e,t,n){return this.internalShow(e,t,n,m.Info)}static success(e,t,n){return this.internalShow(e,t,n,m.Success)}static error(e,t,n){return this.internalShow(e,t,n,m.Error)}static mini(...e){return(0,a.$)(...e)}}},8333:function(e,t,n){"use strict";function i(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function a(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function r(e){var t=a(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function o(e){return e instanceof a(e).Element||e instanceof Element}function s(e){return e instanceof a(e).HTMLElement||e instanceof HTMLElement}function l(e){return"undefined"!=typeof ShadowRoot&&(e instanceof a(e).ShadowRoot||e instanceof ShadowRoot)}function c(e){return e?(e.nodeName||"").toLowerCase():null}function d(e){return((o(e)?e.ownerDocument:e.document)||window.document).documentElement}function u(e){return i(d(e)).left+r(e).scrollLeft}function p(e){return a(e).getComputedStyle(e)}function h(e){var t=p(e),n=t.overflow,i=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+a+i)}function f(e,t,n){void 0===n&&(n=!1);var o,l,p=d(t),f=i(e),m=s(t),g={scrollLeft:0,scrollTop:0},v={x:0,y:0};return(m||!m&&!n)&&(("body"!==c(t)||h(p))&&(g=(o=t)!==a(o)&&s(o)?{scrollLeft:(l=o).scrollLeft,scrollTop:l.scrollTop}:r(o)),s(t)?((v=i(t)).x+=t.clientLeft,v.y+=t.clientTop):p&&(v.x=u(p))),{x:f.left+g.scrollLeft-v.x,y:f.top+g.scrollTop-v.y,width:f.width,height:f.height}}function m(e){var t=i(e),n=e.offsetWidth,a=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-a)<=1&&(a=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:a}}function g(e){return"html"===c(e)?e:e.assignedSlot||e.parentNode||(l(e)?e.host:null)||d(e)}function v(e){return["html","body","#document"].indexOf(c(e))>=0?e.ownerDocument.body:s(e)&&h(e)?e:v(g(e))}function b(e,t){var n;void 0===t&&(t=[]);var i=v(e),r=i===(null==(n=e.ownerDocument)?void 0:n.body),o=a(i),s=r?[o].concat(o.visualViewport||[],h(i)?i:[]):i,l=t.concat(s);return r?l:l.concat(b(g(s)))}function y(e){return["table","td","th"].indexOf(c(e))>=0}function w(e){return s(e)&&"fixed"!==p(e).position?e.offsetParent:null}function x(e){for(var t=a(e),n=w(e);n&&y(n)&&"static"===p(n).position;)n=w(n);return n&&("html"===c(n)||"body"===c(n)&&"static"===p(n).position)?t:n||function(e){var t=-1!==navigator.userAgent.toLowerCase().indexOf("firefox");if(-1!==navigator.userAgent.indexOf("Trident")&&s(e)&&"fixed"===p(e).position)return null;for(var n=g(e);s(n)&&["html","body"].indexOf(c(n))<0;){var i=p(n);if("none"!==i.transform||"none"!==i.perspective||"paint"===i.contain||-1!==["transform","perspective"].indexOf(i.willChange)||t&&"filter"===i.willChange||t&&i.filter&&"none"!==i.filter)return n;n=n.parentNode}return null}(e)||t}n.d(t,{$:function(){return st}});var _="top",k="bottom",C="right",S="left",E="auto",M=[_,k,C,S],z="start",A="end",$="viewport",O="popper",I=M.reduce((function(e,t){return e.concat([t+"-"+z,t+"-"+A])}),[]),L=[].concat(M,[E]).reduce((function(e,t){return e.concat([t,t+"-"+z,t+"-"+A])}),[]),T=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function P(e){var t=new Map,n=new Set,i=[];function a(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var i=t.get(e);i&&a(i)}})),i.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||a(e)})),i}var D={placement:"bottom",modifiers:[],strategy:"absolute"};function V(){for(var e=arguments.length,t=new Array(e),n=0;n=0?"x":"y"}function R(e){var t,n=e.reference,i=e.element,a=e.placement,r=a?j(a):null,o=a?q(a):null,s=n.x+n.width/2-i.width/2,l=n.y+n.height/2-i.height/2;switch(r){case _:t={x:s,y:n.y-i.height};break;case k:t={x:s,y:n.y+n.height};break;case C:t={x:n.x+n.width,y:l};break;case S:t={x:n.x-i.width,y:l};break;default:t={x:n.x,y:n.y}}var c=r?H(r):null;if(null!=c){var d="y"===c?"height":"width";switch(o){case z:t[c]=t[c]-(n[d]/2-i[d]/2);break;case A:t[c]=t[c]+(n[d]/2-i[d]/2)}}return t}// eslint-disable-next-line import/no-unused-modules @@ -81,7 +81,7 @@ e=[[null,e,""]]);var a={};if(i)for(var r=0;r{let n=u(e);t+=n.weight,this._keys.push(n),this._keyMap[n.id]=n,t+=n.weight})),this._keys.forEach((e=>{e.weight/=t}))}get(e){return this._keyMap[e]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function u(e){let t=null,a=null,r=null,o=1;if(i(e)||n(e))r=e,t=p(e),a=h(e);else{if(!c.call(e,"name"))throw new Error("Missing name property in key");const n=e.name;if(r=n,c.call(e,"weight")&&(o=e.weight,o<=0))throw new Error((e=>`Property 'weight' in key '${e}' must be a positive integer`)(n));t=p(n),a=h(n)}return{path:t,id:a,weight:o,src:r}}function p(e){return n(e)?e:e.split(".")}function h(e){return n(e)?e.join("."):e}var f={isCaseSensitive:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx{if(o(e))if(t[d]){const u=e[t[d]];if(!o(u))return;if(d===t.length-1&&(i(u)||a(u)||r(u)))s.push(function(e){return null==e?"":function(e){if("string"==typeof e)return e;let t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(e)}(u));else if(n(u)){l=!0;for(let e=0,n=u.length;e{this._keysMap[e.id]=t}))}create(){!this.isCreated&&this.docs.length&&(this.isCreated=!0,i(this.docs[0])?this.docs.forEach(((e,t)=>{this._addString(e,t)})):this.docs.forEach(((e,t)=>{this._addObject(e,t)})),this.norm.clear())}add(e){const t=this.size();i(e)?this._addString(e,t):this._addObject(e,t)}removeAt(e){this.records.splice(e,1);for(let t=e,n=this.size();t{let l=this.getFn(e,t.path);if(o(l))if(n(l)){let e=[];const t=[{nestedArrIndex:-1,value:l}];for(;t.length;){const{nestedArrIndex:a,value:r}=t.pop();if(o(r))if(i(r)&&!s(r)){let t={v:r,i:a,n:this.norm.get(r)};e.push(t)}else n(r)&&r.forEach(((e,n)=>{t.push({nestedArrIndex:n,value:e})}))}a.$[r]=e}else if(!s(l)){let e={v:l,n:this.norm.get(l)};a.$[r]=e}})),this.records.push(a)}toJSON(){return{keys:this.keys,records:this.records}}}function v(e,t,{getFn:n=f.getFn}={}){const i=new g({getFn:n});return i.setKeys(e.map(u)),i.setSources(t),i.create(),i}function b(e,{errors:t=0,currentLocation:n=0,expectedLocation:i=0,distance:a=f.distance,ignoreLocation:r=f.ignoreLocation}={}){const o=t/e.length;if(r)return o;const s=Math.abs(i-n);return a?o+s/a:s?1:o}function y(e,t,n,{location:i=f.location,distance:a=f.distance,threshold:r=f.threshold,findAllMatches:o=f.findAllMatches,minMatchCharLength:s=f.minMatchCharLength,includeMatches:l=f.includeMatches,ignoreLocation:c=f.ignoreLocation}={}){if(t.length>32)throw new Error("Pattern length exceeds max of 32.");const d=t.length,u=e.length,p=Math.max(0,Math.min(i,u));let h=r,m=p;const g=s>1||l,v=g?Array(u):[];let y;for(;(y=e.indexOf(t,m))>-1;){let e=b(t,{currentLocation:y,expectedLocation:p,distance:a,ignoreLocation:c});if(h=Math.min(e,h),m=y+d,g){let e=0;for(;e=l;r-=1){let o=r-1,s=n[e.charAt(o)];if(g&&(v[o]=+!!s),y[r]=(y[r+1]<<1|1)&s,i&&(y[r]|=(w[r+1]|w[r])<<1|1|w[r+1]),y[r]&k&&(x=b(t,{errors:i,currentLocation:o,expectedLocation:p,distance:a,ignoreLocation:c}),x<=h)){if(h=x,m=o,m<=p)break;l=Math.max(1,2*p-m)}}if(b(t,{errors:i+1,currentLocation:p,expectedLocation:p,distance:a,ignoreLocation:c})>h)break;w=y}const C={isMatch:m>=0,score:Math.max(.001,x)};if(g){const e=function(e=[],t=f.minMatchCharLength){let n=[],i=-1,a=-1,r=0;for(let o=e.length;r=t&&n.push([i,a]),i=-1)}return e[r-1]&&r-i>=t&&n.push([i,r-1]),n}(v,s);e.length?l&&(C.indices=e):C.isMatch=!1}return C}function w(e){let t={};for(let n=0,i=e.length;n{this.chunks.push({pattern:e,alphabet:w(e),startIndex:t})},d=this.pattern.length;if(d>32){let e=0;const t=d%32,n=d-t;for(;e{const{isMatch:f,score:m,indices:g}=y(e,t,p,{location:i+h,distance:a,threshold:r,findAllMatches:o,minMatchCharLength:s,includeMatches:n,ignoreLocation:l});f&&(u=!0),d+=m,f&&g&&(c=[...c,...g])}));let p={isMatch:u,score:u?d/this.chunks.length:1};return u&&n&&(p.indices=c),p}}const _=[];function k(e,t){for(let n=0,i=_.length;n{if(!o(e.indices)||!e.indices.length)return;const{indices:n,value:i}=e;let a={indices:n,value:i};e.key&&(a.key=e.key.src),e.idx>-1&&(a.refIndex=e.idx),t.matches.push(a)}))}function S(e,t){t.score=e.score}class E{constructor(e,t={},n){if(this.options={...f,...t},this.options.useExtendedSearch)throw new Error("Extended search is not available");this._keyStore=new d(this.options.keys),this.setCollection(e,n)}setCollection(e,t){if(this._docs=e,t&&!(t instanceof g))throw new Error("Incorrect 'index' type");this._myIndex=t||v(this.options.keys,this._docs,{getFn:this.options.getFn})}add(e){o(e)&&(this._docs.push(e),this._myIndex.add(e))}remove(e=(()=>!1)){const t=[];for(let n=0,i=this._docs.length;n{let n=1;e.matches.forEach((({key:e,norm:i,score:a})=>{const r=e?e.weight:null;n*=Math.pow(0===a&&r?Number.EPSILON:a,(r||1)*(t?1:i))})),e.score=n}))}(c,{ignoreFieldNorm:l}),o&&c.sort(s),a(t)&&t>-1&&(c=c.slice(0,t)),function(e,t,{includeMatches:n=f.includeMatches,includeScore:i=f.includeScore}={}){const a=[];return n&&a.push(C),i&&a.push(S),e.map((e=>{const{idx:n}=e,i={item:t[n],refIndex:n};return a.length&&a.forEach((t=>{t(e,i)})),i}))}(c,this._docs,{includeMatches:n,includeScore:r})}_searchStringList(e){const t=k(e,this.options),{records:n}=this._myIndex,i=[];return n.forEach((({v:e,i:n,n:a})=>{if(!o(e))return;const{isMatch:r,score:s,indices:l}=t.searchIn(e);r&&i.push({item:e,idx:n,matches:[{score:s,value:e,norm:a,indices:l}]})})),i}_searchLogical(e){throw new Error("Logical search is not available")}_searchObjectList(e){const t=k(e,this.options),{keys:n,records:i}=this._myIndex,a=[];return i.forEach((({$:e,i:i})=>{if(!o(e))return;let r=[];n.forEach(((n,i)=>{r.push(...this._findMatches({key:n,value:e[i],searcher:t}))})),r.length&&a.push({idx:i,item:e,matches:r})})),a}_findMatches({key:e,value:t,searcher:i}){if(!o(t))return[];let a=[];if(n(t))t.forEach((({v:t,i:n,n:r})=>{if(!o(t))return;const{isMatch:s,score:l,indices:c}=i.searchIn(t);s&&a.push({score:l,key:e,value:t,idx:n,norm:r,indices:c})}));else{const{v:n,n:r}=t,{isMatch:o,score:s,indices:l}=i.searchIn(n);o&&a.push({score:s,key:e,value:n,norm:r,indices:l})}return a}}E.version="6.4.6",E.createIndex=v,E.parseIndex=function(e,{getFn:t=f.getFn}={}){const{keys:n,records:i}=e,a=new g({getFn:t});return a.setKeys(n),a.setIndexRecords(i),a},E.config=f,t.Z=E},5171:function(e){e.exports=function(e){return!(!e||"string"==typeof e)&&(e instanceof Array||Array.isArray(e)||e.length>=0&&(e.splice instanceof Function||Object.getOwnPropertyDescriptor(e,e.length-1)&&"String"!==e.constructor.name))}},7084:function(e){e.exports=function(){"use strict";function e(e,t){for(var n=0;ne.length)&&(t=e.length);for(var n=0,i=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[a++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(i=e[Symbol.iterator]()).next.bind(i)}function r(e,t){return e(t={exports:{}},t.exports),t.exports}var o=r((function(e){function t(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}function n(t){e.exports.defaults=t}e.exports={defaults:t(),getDefaults:t,changeDefaults:n}})),s=(o.defaults,o.getDefaults,o.changeDefaults,/[&<>"']/),l=/[&<>"']/g,c=/[<>"']|&(?!#?\w+;)/,d=/[<>"']|&(?!#?\w+;)/g,u={"&":"&","<":"<",">":">",'"':""","'":"'"},p=function(e){return u[e]};function h(e,t){if(t){if(s.test(e))return e.replace(l,p)}else if(c.test(e))return e.replace(d,p);return e}var f=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function m(e){return e.replace(f,(function(e,t){return"colon"===(t=t.toLowerCase())?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""}))}var g=/(^|[^\[])\^/g;function v(e,t){e=e.source||e,t=t||"";var n={replace:function(t,i){return i=(i=i.source||i).replace(g,"$1"),e=e.replace(t,i),n},getRegex:function(){return new RegExp(e,t)}};return n}var b=/[^\w:]/g,y=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function w(e,t,n){if(e){var i;try{i=decodeURIComponent(m(n)).replace(b,"").toLowerCase()}catch(e){return null}if(0===i.indexOf("javascript:")||0===i.indexOf("vbscript:")||0===i.indexOf("data:"))return null}t&&!y.test(n)&&(n=S(t,n));try{n=encodeURI(n).replace(/%25/g,"%")}catch(e){return null}return n}var x={},_=/^[^:]+:\/*[^/]*$/,k=/^([^:]+:)[\s\S]*$/,C=/^([^:]+:\/*[^/]*)[\s\S]*$/;function S(e,t){x[" "+e]||(_.test(e)?x[" "+e]=e+"/":x[" "+e]=z(e,"/",!0));var n=-1===(e=x[" "+e]).indexOf(":");return"//"===t.substring(0,2)?n?t:e.replace(k,"$1")+t:"/"===t.charAt(0)?n?t:e.replace(C,"$1")+t:e+t}function E(e){for(var t,n,i=1;i=0&&"\\"===n[a];)i=!i;return i?"|":" |"})).split(/ \|/),i=0;if(n.length>t)n.splice(t);else for(;n.length1;)1&t&&(n+=e),t>>=1,e+=e;return n+e}var I={escape:h,unescape:m,edit:v,cleanUrl:w,resolveUrl:S,noopTest:{exec:function(){}},merge:E,splitCells:M,rtrim:z,findClosingBracket:A,checkSanitizeDeprecation:$,repeatString:O},L=o.defaults,T=I.rtrim,P=I.splitCells,D=I.escape,V=I.findClosingBracket;function B(e,t,n){var i=t.href,a=t.title?D(t.title):null,r=e[1].replace(/\\([\[\]])/g,"$1");return"!"!==e[0].charAt(0)?{type:"link",raw:n,href:i,title:a,text:r}:{type:"image",raw:n,href:i,title:a,text:D(r)}}function F(e,t){var n=e.match(/^(\s+)(?:```)/);if(null===n)return t;var i=n[1];return t.split("\n").map((function(e){var t=e.match(/^\s+/);return null===t?e:t[0].length>=i.length?e.slice(i.length):e})).join("\n")}var N=function(){function e(e){this.options=e||L}var t=e.prototype;return t.space=function(e){var t=this.rules.block.newline.exec(e);if(t)return t[0].length>1?{type:"space",raw:t[0]}:{raw:"\n"}},t.code=function(e,t){var n=this.rules.block.code.exec(e);if(n){var i=t[t.length-1];if(i&&"paragraph"===i.type)return{raw:n[0],text:n[0].trimRight()};var a=n[0].replace(/^ {4}/gm,"");return{type:"code",raw:n[0],codeBlockStyle:"indented",text:this.options.pedantic?a:T(a,"\n")}}},t.fences=function(e){var t=this.rules.block.fences.exec(e);if(t){var n=t[0],i=F(n,t[3]||"");return{type:"code",raw:n,lang:t[2]?t[2].trim():t[2],text:i}}},t.heading=function(e){var t=this.rules.block.heading.exec(e);if(t)return{type:"heading",raw:t[0],depth:t[1].length,text:t[2]}},t.nptable=function(e){var t=this.rules.block.nptable.exec(e);if(t){var n={type:"table",header:P(t[1].replace(/^ *| *\| *$/g,"")),align:t[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:t[3]?t[3].replace(/\n$/,"").split("\n"):[],raw:t[0]};if(n.header.length===n.align.length){var i,a=n.align.length;for(i=0;i ?/gm,"");return{type:"blockquote",raw:t[0],text:n}}},t.list=function(e){var t=this.rules.block.list.exec(e);if(t){var n,i,a,r,o,s,l,c,d=t[0],u=t[2],p=u.length>1,h={type:"list",raw:d,ordered:p,start:p?+u.slice(0,-1):"",loose:!1,items:[]},f=t[0].match(this.rules.block.item),m=!1,g=f.length;a=this.rules.block.listItemStart.exec(f[0]);for(var v=0;va[0].length||r[1].length>3){f.splice(v,2,f[v]+"\n"+f[v+1]),v--,g--;continue}(!this.options.pedantic||this.options.smartLists?r[2][r[2].length-1]!==u[u.length-1]:p===(1===r[2].length))&&(o=f.slice(v+1).join("\n"),h.raw=h.raw.substring(0,h.raw.length-o.length),v=g-1),a=r}i=n.length,~(n=n.replace(/^ *([*+-]|\d+[.)]) ?/,"")).indexOf("\n ")&&(i-=n.length,n=this.options.pedantic?n.replace(/^ {1,4}/gm,""):n.replace(new RegExp("^ {1,"+i+"}","gm"),"")),s=m||/\n\n(?!\s*$)/.test(n),v!==g-1&&(m="\n"===n.charAt(n.length-1),s||(s=m)),s&&(h.loose=!0),this.options.gfm&&(c=void 0,(l=/^\[[ xX]\] /.test(n))&&(c=" "!==n[1],n=n.replace(/^\[[ xX]\] +/,""))),h.items.push({type:"list_item",raw:d,task:l,checked:c,loose:s,text:n})}return h}},t.html=function(e){var t=this.rules.block.html.exec(e);if(t)return{type:this.options.sanitize?"paragraph":"html",raw:t[0],pre:!this.options.sanitizer&&("pre"===t[1]||"script"===t[1]||"style"===t[1]),text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(t[0]):D(t[0]):t[0]}},t.def=function(e){var t=this.rules.block.def.exec(e);if(t)return t[3]&&(t[3]=t[3].substring(1,t[3].length-1)),{tag:t[1].toLowerCase().replace(/\s+/g," "),raw:t[0],href:t[2],title:t[3]}},t.table=function(e){var t=this.rules.block.table.exec(e);if(t){var n={type:"table",header:P(t[1].replace(/^ *| *\| *$/g,"")),align:t[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:t[3]?t[3].replace(/\n$/,"").split("\n"):[]};if(n.header.length===n.align.length){n.raw=t[0];var i,a=n.align.length;for(i=0;i/i.test(i[0])&&(t=!1),!n&&/^<(pre|code|kbd|script)(\s|>)/i.test(i[0])?n=!0:n&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(i[0])&&(n=!1),{type:this.options.sanitize?"text":"html",raw:i[0],inLink:t,inRawBlock:n,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(i[0]):D(i[0]):i[0]}},t.link=function(e){var t=this.rules.inline.link.exec(e);if(t){var n=V(t[2],"()");if(n>-1){var i=(0===t[0].indexOf("!")?5:4)+t[1].length+n;t[2]=t[2].substring(0,n),t[0]=t[0].substring(0,i).trim(),t[3]=""}var a=t[2],r="";if(this.options.pedantic){var o=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(a);o?(a=o[1],r=o[3]):r=""}else r=t[3]?t[3].slice(1,-1):"";return B(t,{href:(a=a.trim().replace(/^<([\s\S]*)>$/,"$1"))?a.replace(this.rules.inline._escapes,"$1"):a,title:r?r.replace(this.rules.inline._escapes,"$1"):r},t[0])}},t.reflink=function(e,t){var n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){var i=(n[2]||n[1]).replace(/\s+/g," ");if(!(i=t[i.toLowerCase()])||!i.href){var a=n[0].charAt(0);return{type:"text",raw:a,text:a}}return B(n,i,n[0])}},t.strong=function(e,t,n){void 0===n&&(n="");var i=this.rules.inline.strong.start.exec(e);if(i&&(!i[1]||i[1]&&(""===n||this.rules.inline.punctuation.exec(n)))){t=t.slice(-1*e.length);var a,r="**"===i[0]?this.rules.inline.strong.endAst:this.rules.inline.strong.endUnd;for(r.lastIndex=0;null!=(i=r.exec(t));)if(a=this.rules.inline.strong.middle.exec(t.slice(0,i.index+3)))return{type:"strong",raw:e.slice(0,a[0].length),text:e.slice(2,a[0].length-2)}}},t.em=function(e,t,n){void 0===n&&(n="");var i=this.rules.inline.em.start.exec(e);if(i&&(!i[1]||i[1]&&(""===n||this.rules.inline.punctuation.exec(n)))){t=t.slice(-1*e.length);var a,r="*"===i[0]?this.rules.inline.em.endAst:this.rules.inline.em.endUnd;for(r.lastIndex=0;null!=(i=r.exec(t));)if(a=this.rules.inline.em.middle.exec(t.slice(0,i.index+2)))return{type:"em",raw:e.slice(0,a[0].length),text:e.slice(1,a[0].length-1)}}},t.codespan=function(e){var t=this.rules.inline.code.exec(e);if(t){var n=t[2].replace(/\n/g," "),i=/[^ ]/.test(n),a=n.startsWith(" ")&&n.endsWith(" ");return i&&a&&(n=n.substring(1,n.length-1)),n=D(n,!0),{type:"codespan",raw:t[0],text:n}}},t.br=function(e){var t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}},t.del=function(e){var t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2]}},t.autolink=function(e,t){var n,i,a=this.rules.inline.autolink.exec(e);if(a)return i="@"===a[2]?"mailto:"+(n=D(this.options.mangle?t(a[1]):a[1])):n=D(a[1]),{type:"link",raw:a[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}},t.url=function(e,t){var n;if(n=this.rules.inline.url.exec(e)){var i,a;if("@"===n[2])a="mailto:"+(i=D(this.options.mangle?t(n[0]):n[0]));else{var r;do{r=n[0],n[0]=this.rules.inline._backpedal.exec(n[0])[0]}while(r!==n[0]);i=D(n[0]),a="www."===n[1]?"http://"+i:i}return{type:"link",raw:n[0],text:i,href:a,tokens:[{type:"text",raw:i,text:i}]}}},t.inlineText=function(e,t,n){var i,a=this.rules.inline.text.exec(e);if(a)return i=t?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(a[0]):D(a[0]):a[0]:D(this.options.smartypants?n(a[0]):a[0]),{type:"text",raw:a[0],text:i}},e}(),j=I.noopTest,q=I.edit,H=I.merge,R={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?:\n+|$)|$)/,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6}) +([^\n]*?)(?: +#+)? *(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3})(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?! {0,3}bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,nptable:j,table:j,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/};R.def=q(R.def).replace("label",R._label).replace("title",R._title).getRegex(),R.bullet=/(?:[*+-]|\d{1,9}[.)])/,R.item=/^( *)(bull) ?[^\n]*(?:\n(?! *bull ?)[^\n]*)*/,R.item=q(R.item,"gm").replace(/bull/g,R.bullet).getRegex(),R.listItemStart=q(/^( *)(bull)/).replace("bull",R.bullet).getRegex(),R.list=q(R.list).replace(/bull/g,R.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+R.def.source+")").getRegex(),R._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",R._comment=/|$)/,R.html=q(R.html,"i").replace("comment",R._comment).replace("tag",R._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),R.paragraph=q(R._paragraph).replace("hr",R.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|!--)").replace("tag",R._tag).getRegex(),R.blockquote=q(R.blockquote).replace("paragraph",R.paragraph).getRegex(),R.normal=H({},R),R.gfm=H({},R.normal,{nptable:"^ *([^|\\n ].*\\|.*)\\n {0,3}([-:]+ *\\|[-| :]*)(?:\\n((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)",table:"^ *\\|(.+)\\n {0,3}\\|?( *[-:]+[-| :]*)(?:\\n *((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),R.gfm.nptable=q(R.gfm.nptable).replace("hr",R.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|!--)").replace("tag",R._tag).getRegex(),R.gfm.table=q(R.gfm.table).replace("hr",R.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|!--)").replace("tag",R._tag).getRegex(),R.pedantic=H({},R.normal,{html:q("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",R._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,fences:j,paragraph:q(R.normal._paragraph).replace("hr",R.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",R.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var U={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:j,tag:"^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/,nolink:/^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",strong:{start:/^(?:(\*\*(?=[*punctuation]))|\*\*)(?![\s])|__/,middle:/^\*\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*\*$|^__(?![\s])((?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?)__$/,endAst:/[^punctuation\s]\*\*(?!\*)|[punctuation]\*\*(?!\*)(?:(?=[punctuation_\s]|$))/,endUnd:/[^\s]__(?!_)(?:(?=[punctuation*\s])|$)/},em:{start:/^(?:(\*(?=[punctuation]))|\*)(?![*\s])|_/,middle:/^\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*$|^_(?![_\s])(?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?_$/,endAst:/[^punctuation\s]\*(?!\*)|[punctuation]\*(?!\*)(?:(?=[punctuation_\s]|$))/,endUnd:/[^\s]_(?!_)(?:(?=[punctuation*\s])|$)/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:j,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\?@\\[\\]`^{|}~"};U.punctuation=q(U.punctuation).replace(/punctuation/g,U._punctuation).getRegex(),U._blockSkip="\\[[^\\]]*?\\]\\([^\\)]*?\\)|`[^`]*?`|<[^>]*?>",U._overlapSkip="__[^_]*?__|\\*\\*\\[^\\*\\]*?\\*\\*",U._comment=q(R._comment).replace("(?:--\x3e|$)","--\x3e").getRegex(),U.em.start=q(U.em.start).replace(/punctuation/g,U._punctuation).getRegex(),U.em.middle=q(U.em.middle).replace(/punctuation/g,U._punctuation).replace(/overlapSkip/g,U._overlapSkip).getRegex(),U.em.endAst=q(U.em.endAst,"g").replace(/punctuation/g,U._punctuation).getRegex(),U.em.endUnd=q(U.em.endUnd,"g").replace(/punctuation/g,U._punctuation).getRegex(),U.strong.start=q(U.strong.start).replace(/punctuation/g,U._punctuation).getRegex(),U.strong.middle=q(U.strong.middle).replace(/punctuation/g,U._punctuation).replace(/overlapSkip/g,U._overlapSkip).getRegex(),U.strong.endAst=q(U.strong.endAst,"g").replace(/punctuation/g,U._punctuation).getRegex(),U.strong.endUnd=q(U.strong.endUnd,"g").replace(/punctuation/g,U._punctuation).getRegex(),U.blockSkip=q(U._blockSkip,"g").getRegex(),U.overlapSkip=q(U._overlapSkip,"g").getRegex(),U._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,U._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,U._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,U.autolink=q(U.autolink).replace("scheme",U._scheme).replace("email",U._email).getRegex(),U._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,U.tag=q(U.tag).replace("comment",U._comment).replace("attribute",U._attribute).getRegex(),U._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,U._href=/<(?:\\[<>]?|[^\s<>\\])*>|[^\s\x00-\x1f]*/,U._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,U.link=q(U.link).replace("label",U._label).replace("href",U._href).replace("title",U._title).getRegex(),U.reflink=q(U.reflink).replace("label",U._label).getRegex(),U.reflinkSearch=q(U.reflinkSearch,"g").replace("reflink",U.reflink).replace("nolink",U.nolink).getRegex(),U.normal=H({},U),U.pedantic=H({},U.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:q(/^!?\[(label)\]\((.*?)\)/).replace("label",U._label).getRegex(),reflink:q(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",U._label).getRegex()}),U.gfm=H({},U.normal,{escape:q(U.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\.5&&(n="x"+n.toString(16)),i+="&#"+n+";";return i}var Q=function(){function e(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||W,this.options.tokenizer=this.options.tokenizer||new N,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options;var t={block:G.normal,inline:X.normal};this.options.pedantic?(t.block=G.pedantic,t.inline=X.pedantic):this.options.gfm&&(t.block=G.gfm,this.options.breaks?t.inline=X.breaks:t.inline=X.gfm),this.tokenizer.rules=t}e.lex=function(t,n){return new e(n).lex(t)},e.lexInline=function(t,n){return new e(n).inlineTokens(t)};var n=e.prototype;return n.lex=function(e){return e=e.replace(/\r\n|\r/g,"\n").replace(/\t/g," "),this.blockTokens(e,this.tokens,!0),this.inline(this.tokens),this.tokens},n.blockTokens=function(e,t,n){var i,a,r,o;for(void 0===t&&(t=[]),void 0===n&&(n=!0),e=e.replace(/^ +$/gm,"");e;)if(i=this.tokenizer.space(e))e=e.substring(i.raw.length),i.type&&t.push(i);else if(i=this.tokenizer.code(e,t))e=e.substring(i.raw.length),i.type?t.push(i):((o=t[t.length-1]).raw+="\n"+i.raw,o.text+="\n"+i.text);else if(i=this.tokenizer.fences(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.heading(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.nptable(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.hr(e))e=e.substring(i.raw.length),t.push(i);else if(i=this.tokenizer.blockquote(e))e=e.substring(i.raw.length),i.tokens=this.blockTokens(i.text,[],n),t.push(i);else if(i=this.tokenizer.list(e)){for(e=e.substring(i.raw.length),r=i.items.length,a=0;a0)for(;null!=(r=this.tokenizer.rules.inline.reflinkSearch.exec(l));)c.includes(r[0].slice(r[0].lastIndexOf("[")+1,-1))&&(l=l.slice(0,r.index)+"["+K("a",r[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(r=this.tokenizer.rules.inline.blockSkip.exec(l));)l=l.slice(0,r.index)+"["+K("a",r[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;e;)if(o||(s=""),o=!1,a=this.tokenizer.escape(e))e=e.substring(a.raw.length),t.push(a);else if(a=this.tokenizer.tag(e,n,i))e=e.substring(a.raw.length),n=a.inLink,i=a.inRawBlock,t.push(a);else if(a=this.tokenizer.link(e))e=e.substring(a.raw.length),"link"===a.type&&(a.tokens=this.inlineTokens(a.text,[],!0,i)),t.push(a);else if(a=this.tokenizer.reflink(e,this.tokens.links))e=e.substring(a.raw.length),"link"===a.type&&(a.tokens=this.inlineTokens(a.text,[],!0,i)),t.push(a);else if(a=this.tokenizer.strong(e,l,s))e=e.substring(a.raw.length),a.tokens=this.inlineTokens(a.text,[],n,i),t.push(a);else if(a=this.tokenizer.em(e,l,s))e=e.substring(a.raw.length),a.tokens=this.inlineTokens(a.text,[],n,i),t.push(a);else if(a=this.tokenizer.codespan(e))e=e.substring(a.raw.length),t.push(a);else if(a=this.tokenizer.br(e))e=e.substring(a.raw.length),t.push(a);else if(a=this.tokenizer.del(e))e=e.substring(a.raw.length),a.tokens=this.inlineTokens(a.text,[],n,i),t.push(a);else if(a=this.tokenizer.autolink(e,Y))e=e.substring(a.raw.length),t.push(a);else if(n||!(a=this.tokenizer.url(e,Y))){if(a=this.tokenizer.inlineText(e,i,J))e=e.substring(a.raw.length),s=a.raw.slice(-1),o=!0,t.push(a);else if(e){var d="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(d);break}throw new Error(d)}}else e=e.substring(a.raw.length),t.push(a);return t},t(e,null,[{key:"rules",get:function(){return{block:G,inline:X}}}]),e}(),ee=o.defaults,te=I.cleanUrl,ne=I.escape,ie=function(){function e(e){this.options=e||ee}var t=e.prototype;return t.code=function(e,t,n){var i=(t||"").match(/\S*/)[0];if(this.options.highlight){var a=this.options.highlight(e,i);null!=a&&a!==e&&(n=!0,e=a)}return i?'
    '+(n?e:ne(e,!0))+"
    \n":"
    "+(n?e:ne(e,!0))+"
    \n"},t.blockquote=function(e){return"
    \n"+e+"
    \n"},t.html=function(e){return e},t.heading=function(e,t,n,i){return this.options.headerIds?"'+e+"\n":""+e+"\n"},t.hr=function(){return this.options.xhtml?"
    \n":"
    \n"},t.list=function(e,t,n){var i=t?"ol":"ul";return"<"+i+(t&&1!==n?' start="'+n+'"':"")+">\n"+e+"\n"},t.listitem=function(e){return"
  • "+e+"
  • \n"},t.checkbox=function(e){return" "},t.paragraph=function(e){return"

    "+e+"

    \n"},t.table=function(e,t){return t&&(t=""+t+""),"\n\n"+e+"\n"+t+"
    \n"},t.tablerow=function(e){return"\n"+e+"\n"},t.tablecell=function(e,t){var n=t.header?"th":"td";return(t.align?"<"+n+' align="'+t.align+'">':"<"+n+">")+e+"\n"},t.strong=function(e){return""+e+""},t.em=function(e){return""+e+""},t.codespan=function(e){return""+e+""},t.br=function(){return this.options.xhtml?"
    ":"
    "},t.del=function(e){return""+e+""},t.link=function(e,t,n){if(null===(e=te(this.options.sanitize,this.options.baseUrl,e)))return n;var i='
    "},t.image=function(e,t,n){if(null===(e=te(this.options.sanitize,this.options.baseUrl,e)))return n;var i=''+n+'":">"},t.text=function(e){return e},e}(),ae=function(){function e(){}var t=e.prototype;return t.strong=function(e){return e},t.em=function(e){return e},t.codespan=function(e){return e},t.del=function(e){return e},t.html=function(e){return e},t.text=function(e){return e},t.link=function(e,t,n){return""+n},t.image=function(e,t,n){return""+n},t.br=function(){return""},e}(),re=function(){function e(){this.seen={}}var t=e.prototype;return t.serialize=function(e){return e.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")},t.getNextSafeSlug=function(e,t){var n=e,i=0;if(this.seen.hasOwnProperty(n)){i=this.seen[e];do{n=e+"-"+ ++i}while(this.seen.hasOwnProperty(n))}return t||(this.seen[e]=i,this.seen[n]=0),n},t.slug=function(e,t){void 0===t&&(t={});var n=this.serialize(e);return this.getNextSafeSlug(n,t.dryrun)},e}(),oe=o.defaults,se=I.unescape,le=function(){function e(e){this.options=e||oe,this.options.renderer=this.options.renderer||new ie,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new ae,this.slugger=new re}e.parse=function(t,n){return new e(n).parse(t)},e.parseInline=function(t,n){return new e(n).parseInline(t)};var t=e.prototype;return t.parse=function(e,t){void 0===t&&(t=!0);var n,i,a,r,o,s,l,c,d,u,p,h,f,m,g,v,b,y,w="",x=e.length;for(n=0;n0&&"text"===g.tokens[0].type?(g.tokens[0].text=y+" "+g.tokens[0].text,g.tokens[0].tokens&&g.tokens[0].tokens.length>0&&"text"===g.tokens[0].tokens[0].type&&(g.tokens[0].tokens[0].text=y+" "+g.tokens[0].tokens[0].text)):g.tokens.unshift({type:"text",text:y}):m+=y),m+=this.parse(g.tokens,f),d+=this.renderer.listitem(m,b,v);w+=this.renderer.list(d,p,h);continue;case"html":w+=this.renderer.html(u.text);continue;case"paragraph":w+=this.renderer.paragraph(this.parseInline(u.tokens));continue;case"text":for(d=u.tokens?this.parseInline(u.tokens):u.text;n+1An error occurred:

    "+ue(e.message+"",!0)+"
    ";throw e}}return me.options=me.setOptions=function(e){return ce(me.defaults,e),he(me.defaults),me},me.getDefaults=pe,me.defaults=fe,me.use=function(e){var t=ce({},e);if(e.renderer&&function(){var n=me.defaults.renderer||new ie,i=function(t){var i=n[t];n[t]=function(){for(var a=arguments.length,r=new Array(a),o=0;oAn error occurred:

    "+ue(e.message+"",!0)+"
    ";throw e}},me.Parser=le,me.parser=le.parse,me.Renderer=ie,me.TextRenderer=ae,me.Lexer=Q,me.lexer=Q.lex,me.Tokenizer=N,me.Slugger=re,me.parse=me,me}()},382:function(e,t,n){"use strict";n.r(t),t.default=''},8885:function(e,t,n){"use strict";n.r(t),t.default=''},5339:function(e,t,n){"use strict";n.r(t),t.default=''},8360:function(e,t,n){"use strict";n.r(t),t.default=''},6851:function(e,t,n){"use strict";var i=n(5171),a=Array.prototype.concat,r=Array.prototype.slice,o=e.exports=function(e){for(var t=[],n=0,o=e.length;nt.map((t=>{const n=`${e.name}.${t.name}`;return{...t,key:n,provider:e}}));const[C]=(0,r.registerAndGetData)("launchBar.recommended",{word:"搜索",href:"https://search.bilibili.com/"});var S=Vue.extend({components:{VIcon:a.VIcon,VLoading:a.VLoading,VEmpty:a.VEmpty,ActionItem:b},data:()=>({recommended:C,actions:[],keyword:"",noActions:!1}),computed:{isHistory(){return 0===this.keyword.length}},watch:{keyword(){this.getActions()}},async mounted(){this.getActions(),(0,s.matchUrlPattern)(/^https?:\/\/search\.bilibili\.com/)&&(0,o.select)("#search-keyword").then((e=>{e&&(this.keyword=e.value,document.addEventListener("change",(e=>{e.target instanceof HTMLInputElement&&"search-keyword"===e.target.id&&(this.keyword=e.target.value)})))}))},methods:{getOnlineActions:lodash.debounce((async function(){const e=(await Promise.all(_.map((async e=>k(e,await e.getActions(this.keyword)))))).flat();if(this.isHistory)return;const t=new l.Z(e,{keys:["indexer","displayName","name","description","key"]}).search(this.keyword);console.log(t),this.actions=t.map((e=>e.item)).slice(0,12),this.noActions=0===this.actions.length}),200),getActions:async function(){if(this.noActions=!1,this.isHistory)return void(this.actions=k(x.dr,await x.dr.getActions(this.keyword)));this.actions=[],this.getOnlineActions()},async handleEnter(){if(this.actions.length>0&&!this.isHistory){const[e]=this.actions;if(!e.explicitSelect)return void e.action()}this.keyword?(0,w.search)(this.keyword):window.open(this.recommended.href,"_blank")},handleUp(e){e.isComposing||(this.$refs.list.querySelector(".suggest-item:last-child").focus(),e.preventDefault())},handleDown(e){e.isComposing||(this.$refs.list.querySelector(".suggest-item").focus(),e.preventDefault())},previousItem(e,t){0===t?this.focus():e.currentTarget.previousElementSibling.focus()},nextItem(e,t){t!==this.actions.length-1?e.currentTarget.nextElementSibling.focus():this.focus()},search:w.search,onDeleteItem(e,t){this.previousItem(e,t),this.getActions()},onClearHistory(){this.focus(),this.getActions()},focus(){this.$refs.input.focus()}}}),E=n(4815),M=n.n(E),z={insert:"head",singleton:!1},A=(p()(M(),z),M().locals,(0,g.Z)(S,i,[],!1,null,null,null));A.options.__file="src/components/launch-bar/LaunchBar.vue";var $=A.exports},5863:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"be-settings"},[n("div",{staticClass:"sidebar"},[n("div",{ref:"widgetsIcon",class:{open:e.widgetsOpened},attrs:{title:"功能"},on:{click:[function(t){return t.shiftKey?e.theWorld(t):null},function(t){if(t.ctrlKey||t.shiftKey||t.altKey||t.metaKey)return null;e.widgetsOpened=!e.widgetsOpened}],mouseover:function(t){return e.loadPanel("widgetsPanelPopup")}}},[n("VIcon",{attrs:{icon:"widgets",size:26}})],1),e._v(" "),n("div",{ref:"settingsIcon",class:{open:e.settingsOpened},attrs:{title:"设置"},on:{click:function(t){e.settingsOpened=!e.settingsOpened},mouseover:function(t){return e.loadPanel("settingsPanelPopup")}}},[n("VIcon",{attrs:{icon:"settings-outline",size:26}})],1)]),e._v(" "),n("VPopup",{ref:"widgetsPanelPopup",staticClass:"widgets-panel-popup",attrs:{"trigger-element":e.$refs.widgetsIcon,fixed:!0},model:{value:e.widgetsOpened,callback:function(t){e.widgetsOpened=t},expression:"widgetsOpened"}},[n("WidgetsPanel")],1),e._v(" "),n("VPopup",{ref:"settingsPanelPopup",staticClass:"settings-panel-popup",attrs:{"trigger-element":e.$refs.settingsIcon,"auto-close-predicate":e.settingsPanalClosePredicate,fixed:!0},model:{value:e.settingsOpened,callback:function(t){e.settingsOpened=t},expression:"settingsOpened"}},[n("SettingsPanel",{on:{close:function(t){e.settingsOpened=!1}}})],1)],1)};i._withStripped=!0;var a=n(3923),r=n(9388),o={name:"SettingsContainer",components:{VPopup:a.VPopup,VIcon:a.VIcon,SettingsPanel:()=>Promise.resolve().then(n.bind(n,9232)).then((e=>e.default)),WidgetsPanel:()=>Promise.resolve().then(n.bind(n,5208)).then((e=>e.default))},data:()=>({settingsOpened:!1,widgetsOpened:!1}),methods:{theWorld(){r.externalApis.theWorld(0)},settingsPanalClosePredicate:e=>!dqa(".be-settings-extra-options").some((t=>t===e.target||t.contains(e.target))),loadPanel(e){const t=this.$refs[e];t&&(t?.loaded??0)&&(t.loaded=!0)}}},s=n(3379),l=n.n(s),c=n(8918),d=n.n(c),u={insert:"head",singleton:!1},p=(l()(d(),u),d().locals,(0,n(1900).Z)(o,i,[],!1,null,null,null));p.options.__file="src/components/settings-panel/SettingsContainer.vue";var h=p.exports},9232:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Pt}});var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"settings-panel",class:{collasped:e.collasped,peek:e.peek}},[n("div",{staticClass:"settings-panel-header"},[n("VIcon",{attrs:{icon:"settings-outline"}}),e._v(" "),n("div",{staticClass:"title"},[e._v("\n 设置\n ")]),e._v(" "),n("div",{staticClass:"settings-panel-search"},[n("VIcon",{attrs:{icon:"search",size:18}}),e._v(" "),n("TextBox",{attrs:{placeholder:"搜索"},model:{value:e.searchKeyword,callback:function(t){e.searchKeyword=t},expression:"searchKeyword"}})],1),e._v(" "),n("div",{staticClass:"peek",attrs:{title:"透视"},on:{mouseover:function(t){e.peek=!0},mouseout:function(t){e.peek=!1}}},[n("VIcon",{attrs:{icon:"eye",size:18}})],1),e._v(" "),n("div",{staticClass:"close",on:{click:function(t){return e.$emit("close")}}},[n("VIcon",{attrs:{icon:"close",size:18}})],1)],1),e._v(" "),n("div",{staticClass:"settings-panel-content"},[n("div",{ref:"sidebarContainer",staticClass:"sidebar"},[n("ComponentTags",{ref:"componentTags",on:{change:function(t){e.searchFilter=t}}})],1),e._v(" "),n("div",{ref:"mainContainer",staticClass:"main"},[n("div",{ref:"componentList",staticClass:"component-list"},[e._l(e.renderedComponents,(function(t){return n("ComponentSettings",{key:t.name,class:{selected:e.selectedComponent===t},attrs:{"component-data":t,"data-name":t.name},nativeOn:{click:function(n){return e.selectComponent(t)}}})})),e._v(" "),0===e.renderedComponents.length?n("VEmpty"):e._e()],2)]),e._v(" "),n("VPopup",{ref:"detailsPopup",staticClass:"component-detail-panel",attrs:{"trigger-element":e.$refs.componentList,open:Boolean(e.selectedComponent)},on:{"popup-change":function(t){!t&&e.closePopper()}}},[e.selectedComponent?n("ComponentDetail",{key:e.selectedComponent.name,attrs:{"component-data":e.selectedComponent},on:{close:function(t){return e.closePopper()},mounted:function(t){return e.updatePopper()}}}):e._e()],1)],1)])};i._withStripped=!0;var a=n(3923);function r(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function o(e){if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function s(e){var t=o(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function l(e){return e instanceof o(e).Element||e instanceof Element}function c(e){return e instanceof o(e).HTMLElement||e instanceof HTMLElement}function d(e){return e?(e.nodeName||"").toLowerCase():null}function u(e){return((l(e)?e.ownerDocument:e.document)||window.document).documentElement}function p(e){return r(u(e)).left+s(e).scrollLeft}function h(e){return o(e).getComputedStyle(e)}function f(e){var t=h(e),n=t.overflow,i=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+a+i)}function m(e,t,n){void 0===n&&(n=!1);var i,a,l=u(t),h=r(e),m=c(t),g={scrollLeft:0,scrollTop:0},v={x:0,y:0};return(m||!m&&!n)&&(("body"!==d(t)||f(l))&&(g=(i=t)!==o(i)&&c(i)?{scrollLeft:(a=i).scrollLeft,scrollTop:a.scrollTop}:s(i)),c(t)?((v=r(t)).x+=t.clientLeft,v.y+=t.clientTop):l&&(v.x=p(l))),{x:h.left+g.scrollLeft-v.x,y:h.top+g.scrollTop-v.y,width:h.width,height:h.height}}function g(e){return{x:e.offsetLeft,y:e.offsetTop,width:e.offsetWidth,height:e.offsetHeight}}function v(e){return"html"===d(e)?e:e.assignedSlot||e.parentNode||e.host||u(e)}function b(e){return["html","body","#document"].indexOf(d(e))>=0?e.ownerDocument.body:c(e)&&f(e)?e:b(v(e))}function y(e,t){void 0===t&&(t=[]);var n=b(e),i="body"===d(n),a=o(n),r=i?[a].concat(a.visualViewport||[],f(n)?n:[]):n,s=t.concat(r);return i?s:s.concat(y(v(r)))}function w(e){return["table","td","th"].indexOf(d(e))>=0}function x(e){if(!c(e)||"fixed"===h(e).position)return null;var t=e.offsetParent;if(t){var n=u(t);if("body"===d(t)&&"static"===h(t).position&&"static"!==h(n).position)return n}return t}function _(e){for(var t=o(e),n=x(e);n&&w(n)&&"static"===h(n).position;)n=x(n);return n&&"body"===d(n)&&"static"===h(n).position?t:n||function(e){for(var t=v(e);c(t)&&["html","body"].indexOf(d(t))<0;){var n=h(t);if("none"!==n.transform||"none"!==n.perspective||n.willChange&&"auto"!==n.willChange)return t;t=t.parentNode}return null}(e)||t}var k="top",C="bottom",S="right",E="left",M="auto",z=[k,C,S,E],A="start",$="end",O="viewport",I="popper",L=z.reduce((function(e,t){return e.concat([t+"-"+A,t+"-"+$])}),[]),T=[].concat(z,[M]).reduce((function(e,t){return e.concat([t,t+"-"+A,t+"-"+$])}),[]),P=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function D(e){var t=new Map,n=new Set,i=[];function a(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var i=t.get(e);i&&a(i)}})),i.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||a(e)})),i}var V={placement:"bottom",modifiers:[],strategy:"absolute"};function B(){for(var e=arguments.length,t=new Array(e),n=0;nt.map((t=>{const n=`${e.name}.${t.name}`;return{...t,key:n,provider:e}}));const[C]=(0,r.registerAndGetData)("launchBar.recommended",{word:"搜索",href:"https://search.bilibili.com/"});var S=Vue.extend({components:{VIcon:a.VIcon,VLoading:a.VLoading,VEmpty:a.VEmpty,ActionItem:b},data:()=>({recommended:C,actions:[],keyword:"",noActions:!1}),computed:{isHistory(){return 0===this.keyword.length}},watch:{keyword(){this.getActions()}},async mounted(){this.getActions(),(0,s.matchUrlPattern)(/^https?:\/\/search\.bilibili\.com/)&&(0,o.select)("#search-keyword").then((e=>{e&&(this.keyword=e.value,document.addEventListener("change",(e=>{e.target instanceof HTMLInputElement&&"search-keyword"===e.target.id&&(this.keyword=e.target.value)})))}))},methods:{getOnlineActions:lodash.debounce((async function(){const e=(await Promise.all(_.map((async e=>k(e,await e.getActions(this.keyword)))))).flat();if(this.isHistory)return;const t=new l.Z(e,{keys:["indexer","displayName","name","description","key"]}).search(this.keyword);console.log(t),this.actions=t.map((e=>e.item)).slice(0,12),this.noActions=0===this.actions.length}),200),getActions:async function(){if(this.noActions=!1,this.isHistory)return void(this.actions=k(x.dr,await x.dr.getActions(this.keyword)));this.actions=[],this.getOnlineActions()},async handleEnter(){if(this.actions.length>0&&!this.isHistory){const[e]=this.actions;if(!1===e.explicitSelect)return void e.action()}this.keyword?(0,w.search)(this.keyword):window.open(this.recommended.href,"_blank")},handleUp(e){e.isComposing||(this.$refs.list.querySelector(".suggest-item:last-child").focus(),e.preventDefault())},handleDown(e){e.isComposing||(this.$refs.list.querySelector(".suggest-item").focus(),e.preventDefault())},previousItem(e,t){0===t?this.focus():e.currentTarget.previousElementSibling.focus()},nextItem(e,t){t!==this.actions.length-1?e.currentTarget.nextElementSibling.focus():this.focus()},search:w.search,onDeleteItem(e,t){this.previousItem(e,t),this.getActions()},onClearHistory(){this.focus(),this.getActions()},focus(){this.$refs.input.focus()}}}),E=n(4815),M=n.n(E),z={insert:"head",singleton:!1},A=(p()(M(),z),M().locals,(0,g.Z)(S,i,[],!1,null,null,null));A.options.__file="src/components/launch-bar/LaunchBar.vue";var $=A.exports},5863:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"be-settings"},[n("div",{staticClass:"sidebar"},[n("div",{ref:"widgetsIcon",class:{open:e.widgetsOpened},attrs:{title:"功能"},on:{click:[function(t){return t.shiftKey?e.theWorld(t):null},function(t){if(t.ctrlKey||t.shiftKey||t.altKey||t.metaKey)return null;e.widgetsOpened=!e.widgetsOpened}],mouseover:function(t){return e.loadPanel("widgetsPanelPopup")}}},[n("VIcon",{attrs:{icon:"widgets",size:26}})],1),e._v(" "),n("div",{ref:"settingsIcon",class:{open:e.settingsOpened},attrs:{title:"设置"},on:{click:function(t){e.settingsOpened=!e.settingsOpened},mouseover:function(t){return e.loadPanel("settingsPanelPopup")}}},[n("VIcon",{attrs:{icon:"settings-outline",size:26}})],1)]),e._v(" "),n("VPopup",{ref:"widgetsPanelPopup",staticClass:"widgets-panel-popup",attrs:{"trigger-element":e.$refs.widgetsIcon,fixed:!0},model:{value:e.widgetsOpened,callback:function(t){e.widgetsOpened=t},expression:"widgetsOpened"}},[n("WidgetsPanel")],1),e._v(" "),n("VPopup",{ref:"settingsPanelPopup",staticClass:"settings-panel-popup",attrs:{"trigger-element":e.$refs.settingsIcon,"auto-close-predicate":e.settingsPanalClosePredicate,fixed:!0},model:{value:e.settingsOpened,callback:function(t){e.settingsOpened=t},expression:"settingsOpened"}},[n("SettingsPanel",{on:{close:function(t){e.settingsOpened=!1}}})],1)],1)};i._withStripped=!0;var a=n(3923),r=n(9388),o={name:"SettingsContainer",components:{VPopup:a.VPopup,VIcon:a.VIcon,SettingsPanel:()=>Promise.resolve().then(n.bind(n,9232)).then((e=>e.default)),WidgetsPanel:()=>Promise.resolve().then(n.bind(n,5208)).then((e=>e.default))},data:()=>({settingsOpened:!1,widgetsOpened:!1}),methods:{theWorld(){r.externalApis.theWorld(0)},settingsPanalClosePredicate:e=>!dqa(".be-settings-extra-options").some((t=>t===e.target||t.contains(e.target))),loadPanel(e){const t=this.$refs[e];t&&(t?.loaded??0)&&(t.loaded=!0)}}},s=n(3379),l=n.n(s),c=n(8918),d=n.n(c),u={insert:"head",singleton:!1},p=(l()(d(),u),d().locals,(0,n(1900).Z)(o,i,[],!1,null,null,null));p.options.__file="src/components/settings-panel/SettingsContainer.vue";var h=p.exports},9232:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Pt}});var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"settings-panel",class:{collasped:e.collasped,peek:e.peek}},[n("div",{staticClass:"settings-panel-header"},[n("VIcon",{attrs:{icon:"settings-outline"}}),e._v(" "),n("div",{staticClass:"title"},[e._v("\n 设置\n ")]),e._v(" "),n("div",{staticClass:"settings-panel-search"},[n("VIcon",{attrs:{icon:"search",size:18}}),e._v(" "),n("TextBox",{attrs:{placeholder:"搜索"},model:{value:e.searchKeyword,callback:function(t){e.searchKeyword=t},expression:"searchKeyword"}})],1),e._v(" "),n("div",{staticClass:"peek",attrs:{title:"透视"},on:{mouseover:function(t){e.peek=!0},mouseout:function(t){e.peek=!1}}},[n("VIcon",{attrs:{icon:"eye",size:18}})],1),e._v(" "),n("div",{staticClass:"close",on:{click:function(t){return e.$emit("close")}}},[n("VIcon",{attrs:{icon:"close",size:18}})],1)],1),e._v(" "),n("div",{staticClass:"settings-panel-content"},[n("div",{ref:"sidebarContainer",staticClass:"sidebar"},[n("ComponentTags",{ref:"componentTags",on:{change:function(t){e.searchFilter=t}}})],1),e._v(" "),n("div",{ref:"mainContainer",staticClass:"main"},[n("div",{ref:"componentList",staticClass:"component-list"},[e._l(e.renderedComponents,(function(t){return n("ComponentSettings",{key:t.name,class:{selected:e.selectedComponent===t},attrs:{"component-data":t,"data-name":t.name},nativeOn:{click:function(n){return e.selectComponent(t)}}})})),e._v(" "),0===e.renderedComponents.length?n("VEmpty"):e._e()],2)]),e._v(" "),n("VPopup",{ref:"detailsPopup",staticClass:"component-detail-panel",attrs:{"trigger-element":e.$refs.componentList,open:Boolean(e.selectedComponent)},on:{"popup-change":function(t){!t&&e.closePopper()}}},[e.selectedComponent?n("ComponentDetail",{key:e.selectedComponent.name,attrs:{"component-data":e.selectedComponent},on:{close:function(t){return e.closePopper()},mounted:function(t){return e.updatePopper()}}}):e._e()],1)],1)])};i._withStripped=!0;var a=n(3923);function r(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function o(e){if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function s(e){var t=o(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function l(e){return e instanceof o(e).Element||e instanceof Element}function c(e){return e instanceof o(e).HTMLElement||e instanceof HTMLElement}function d(e){return e?(e.nodeName||"").toLowerCase():null}function u(e){return((l(e)?e.ownerDocument:e.document)||window.document).documentElement}function p(e){return r(u(e)).left+s(e).scrollLeft}function h(e){return o(e).getComputedStyle(e)}function f(e){var t=h(e),n=t.overflow,i=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+a+i)}function m(e,t,n){void 0===n&&(n=!1);var i,a,l=u(t),h=r(e),m=c(t),g={scrollLeft:0,scrollTop:0},v={x:0,y:0};return(m||!m&&!n)&&(("body"!==d(t)||f(l))&&(g=(i=t)!==o(i)&&c(i)?{scrollLeft:(a=i).scrollLeft,scrollTop:a.scrollTop}:s(i)),c(t)?((v=r(t)).x+=t.clientLeft,v.y+=t.clientTop):l&&(v.x=p(l))),{x:h.left+g.scrollLeft-v.x,y:h.top+g.scrollTop-v.y,width:h.width,height:h.height}}function g(e){return{x:e.offsetLeft,y:e.offsetTop,width:e.offsetWidth,height:e.offsetHeight}}function v(e){return"html"===d(e)?e:e.assignedSlot||e.parentNode||e.host||u(e)}function b(e){return["html","body","#document"].indexOf(d(e))>=0?e.ownerDocument.body:c(e)&&f(e)?e:b(v(e))}function y(e,t){void 0===t&&(t=[]);var n=b(e),i="body"===d(n),a=o(n),r=i?[a].concat(a.visualViewport||[],f(n)?n:[]):n,s=t.concat(r);return i?s:s.concat(y(v(r)))}function w(e){return["table","td","th"].indexOf(d(e))>=0}function x(e){if(!c(e)||"fixed"===h(e).position)return null;var t=e.offsetParent;if(t){var n=u(t);if("body"===d(t)&&"static"===h(t).position&&"static"!==h(n).position)return n}return t}function _(e){for(var t=o(e),n=x(e);n&&w(n)&&"static"===h(n).position;)n=x(n);return n&&"body"===d(n)&&"static"===h(n).position?t:n||function(e){for(var t=v(e);c(t)&&["html","body"].indexOf(d(t))<0;){var n=h(t);if("none"!==n.transform||"none"!==n.perspective||n.willChange&&"auto"!==n.willChange)return t;t=t.parentNode}return null}(e)||t}var k="top",C="bottom",S="right",E="left",M="auto",z=[k,C,S,E],A="start",$="end",O="viewport",I="popper",L=z.reduce((function(e,t){return e.concat([t+"-"+A,t+"-"+$])}),[]),T=[].concat(z,[M]).reduce((function(e,t){return e.concat([t,t+"-"+A,t+"-"+$])}),[]),P=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function D(e){var t=new Map,n=new Set,i=[];function a(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var i=t.get(e);i&&a(i)}})),i.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||a(e)})),i}var V={placement:"bottom",modifiers:[],strategy:"absolute"};function B(){for(var e=arguments.length,t=new Array(e),n=0;n=0?"x":"y"}function R(e){var t,n=e.reference,i=e.element,a=e.placement,r=a?j(a):null,o=a?q(a):null,s=n.x+n.width/2-i.width/2,l=n.y+n.height/2-i.height/2;switch(r){case k:t={x:s,y:n.y-i.height};break;case C:t={x:s,y:n.y+n.height};break;case S:t={x:n.x+n.width,y:l};break;case E:t={x:n.x-i.width,y:l};break;default:t={x:n.x,y:n.y}}var c=r?H(r):null;if(null!=c){var d="y"===c?"height":"width";switch(o){case A:t[c]=t[c]-(n[d]/2-i[d]/2);break;case $:t[c]=t[c]+(n[d]/2-i[d]/2)}}return t}// eslint-disable-next-line import/no-unused-modules var U={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Z(e){var t,n=e.popper,i=e.popperRect,a=e.placement,r=e.offsets,s=e.position,l=e.gpuAcceleration,c=e.adaptive,d=e.roundOffsets?function(e){var t=e.x,n=e.y,i=window.devicePixelRatio||1;return{x:Math.round(t*i)/i||0,y:Math.round(n*i)/i||0}}(r):r,p=d.x,h=void 0===p?0:p,f=d.y,m=void 0===f?0:f,g=r.hasOwnProperty("x"),v=r.hasOwnProperty("y"),b=E,y=k,w=window;if(c){var x=_(n);x===o(n)&&(x=u(n)),a===k&&(y=C,m-=x.clientHeight-i.height,m*=l?1:-1),a===E&&(b=S,h-=x.clientWidth-i.width,h*=l?1:-1)}var M,z=Object.assign({position:s},c&&U);return l?Object.assign(Object.assign({},z),{},((M={})[y]=v?"0":"",M[b]=g?"0":"",M.transform=(w.devicePixelRatio||1)<2?"translate("+h+"px, "+m+"px)":"translate3d("+h+"px, "+m+"px, 0)",M)):Object.assign(Object.assign({},z),{},((t={})[y]=v?m+"px":"",t[b]=g?h+"px":"",t.transform="",t))}// eslint-disable-next-line import/no-unused-modules var W={left:"right",right:"left",bottom:"top",top:"bottom"};function G(e){return e.replace(/left|right|bottom|top/g,(function(e){return W[e]}))}var X={start:"end",end:"start"};function K(e){return e.replace(/start|end/g,(function(e){return X[e]}))}function J(e,t){var n,i=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(i&&((n=i)instanceof o(n).ShadowRoot||n instanceof ShadowRoot)){var a=t;do{if(a&&e.isSameNode(a))return!0;a=a.parentNode||a.host}while(a)}return!1}function Y(e){return Object.assign(Object.assign({},e),{},{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Q(e,t){return t===O?Y(function(e){var t=o(e),n=u(e),i=t.visualViewport,a=n.clientWidth,r=n.clientHeight,s=0,l=0;return i&&(a=i.width,r=i.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(s=i.offsetLeft,l=i.offsetTop)),{width:a,height:r,x:s+p(e),y:l}}(e)):c(t)?function(e){var t=r(e);return t.top=t.top+e.clientTop,t.left=t.left+e.clientLeft,t.bottom=t.top+e.clientHeight,t.right=t.left+e.clientWidth,t.width=e.clientWidth,t.height=e.clientHeight,t.x=t.left,t.y=t.top,t}(t):Y(function(e){var t=u(e),n=s(e),i=e.ownerDocument.body,a=Math.max(t.scrollWidth,t.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),r=Math.max(t.scrollHeight,t.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),o=-n.scrollLeft+p(e),l=-n.scrollTop;return"rtl"===h(i||t).direction&&(o+=Math.max(t.clientWidth,i?i.clientWidth:0)-a),{width:a,height:r,x:o,y:l}}(u(e)))}function ee(e,t,n){var i="clippingParents"===t?function(e){var t=y(v(e)),n=["absolute","fixed"].indexOf(h(e).position)>=0&&c(e)?_(e):e;return l(n)?t.filter((function(e){return l(e)&&J(e,n)&&"body"!==d(e)})):[]}(e):[].concat(t),a=[].concat(i,[n]),r=a[0],o=a.reduce((function(t,n){var i=Q(e,n);return t.top=Math.max(i.top,t.top),t.right=Math.min(i.right,t.right),t.bottom=Math.min(i.bottom,t.bottom),t.left=Math.max(i.left,t.left),t}),Q(e,r));return o.width=o.right-o.left,o.height=o.bottom-o.top,o.x=o.left,o.y=o.top,o}function te(e){return Object.assign(Object.assign({},{top:0,right:0,bottom:0,left:0}),e)}function ne(e,t){return t.reduce((function(t,n){return t[n]=e,t}),{})}