lemon-mse 0.3.7 → 0.3.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lemon.js +2 -1
- package/package.json +1 -1
package/dist/lemon.js
CHANGED
@@ -1 +1,2 @@
|
|
1
|
-
var gi=Object.defineProperty;var wi=(s,t,e)=>t in s?gi(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e;var Y=(s,t,e)=>wi(s,typeof t!="symbol"?t+"":t,e);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))l(n);new MutationObserver(n=>{for(const i of n)if(i.type==="childList")for(const c of i.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&l(c)}).observe(document,{childList:!0,subtree:!0});function e(n){const i={};return n.integrity&&(i.integrity=n.integrity),n.referrerPolicy&&(i.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?i.credentials="include":n.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function l(n){if(n.ep)return;n.ep=!0;const i=e(n);fetch(n.href,i)}})();const yi=Vue.createApp,p=Vue.createElementVNode,T=Vue.openBlock,D=Vue.createElementBlock,U=Vue.ref,Te=Vue.reactive,Qe=Vue.watchEffect,J=Vue.computed,X=Vue.defineComponent,k=Vue.unref,fe=Vue.renderList,se=Vue.Fragment,H=Vue.normalizeClass,Ot=Vue.resolveComponent,G=Vue.withCtx,P=Vue.createVNode,ye=Vue.vShow,Q=Vue.withDirectives,at=Vue.resolveDynamicComponent,K=Vue.createBlock,xi=Vue.KeepAlive,_e=Vue.createCommentVNode,Je=Vue.onMounted,ve=Vue.watch,$e=Vue.isRef,Rt=Vue.vModelText,ki=Vue.withKeys,N=Vue.toDisplayString,Sn=Vue.onActivated,Ut=Vue.resolveDirective,Ze=Vue.normalizeStyle,ne=Vue.withModifiers,Et=Vue.createTextVNode,_i=Vue.shallowRef,Kt=Vue.nextTick,jt=Vue.onBeforeUnmount,bi=Vue.h,Si=Vue.onDeactivated,Ai=Vue.onUnmounted,ft=Vue.useModel,vs=Vue.useSlots,An=Vue.render,Ti=Vue.Transition,ct=Vue.mergeModels,Ci=Vue.renderSlot,Ii=Vue.provide,Ei=Vue.inject,Mi=Vue.getCurrentInstance;var Yt={exports:{}},Is;function Oi(){return Is||(Is=1,function(s){var t=function(){var e=String.fromCharCode,l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",i={};function c(d,a){if(!i[d]){i[d]={};for(var u=0;u<d.length;u++)i[d][d.charAt(u)]=u}return i[d][a]}var r={compressToBase64:function(d){if(d==null)return"";var a=r._compress(d,6,function(u){return l.charAt(u)});switch(a.length%4){default:case 0:return a;case 1:return a+"===";case 2:return a+"==";case 3:return a+"="}},decompressFromBase64:function(d){return d==null?"":d==""?null:r._decompress(d.length,32,function(a){return c(l,d.charAt(a))})},compressToUTF16:function(d){return d==null?"":r._compress(d,15,function(a){return e(a+32)})+" "},decompressFromUTF16:function(d){return d==null?"":d==""?null:r._decompress(d.length,16384,function(a){return d.charCodeAt(a)-32})},compressToUint8Array:function(d){for(var a=r.compress(d),u=new Uint8Array(a.length*2),h=0,v=a.length;h<v;h++){var y=a.charCodeAt(h);u[h*2]=y>>>8,u[h*2+1]=y%256}return u},decompressFromUint8Array:function(d){if(d==null)return r.decompress(d);for(var a=new Array(d.length/2),u=0,h=a.length;u<h;u++)a[u]=d[u*2]*256+d[u*2+1];var v=[];return a.forEach(function(y){v.push(e(y))}),r.decompress(v.join(""))},compressToEncodedURIComponent:function(d){return d==null?"":r._compress(d,6,function(a){return n.charAt(a)})},decompressFromEncodedURIComponent:function(d){return d==null?"":d==""?null:(d=d.replace(/ /g,"+"),r._decompress(d.length,32,function(a){return c(n,d.charAt(a))}))},compress:function(d){return r._compress(d,16,function(a){return e(a)})},_compress:function(d,a,u){if(d==null)return"";var h,v,y={},b={},C="",E="",I="",B=2,S=3,_=2,x=[],m=0,f=0,g;for(g=0;g<d.length;g+=1)if(C=d.charAt(g),Object.prototype.hasOwnProperty.call(y,C)||(y[C]=S++,b[C]=!0),E=I+C,Object.prototype.hasOwnProperty.call(y,E))I=E;else{if(Object.prototype.hasOwnProperty.call(b,I)){if(I.charCodeAt(0)<256){for(h=0;h<_;h++)m=m<<1,f==a-1?(f=0,x.push(u(m)),m=0):f++;for(v=I.charCodeAt(0),h=0;h<8;h++)m=m<<1|v&1,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=v>>1}else{for(v=1,h=0;h<_;h++)m=m<<1|v,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=0;for(v=I.charCodeAt(0),h=0;h<16;h++)m=m<<1|v&1,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=v>>1}B--,B==0&&(B=Math.pow(2,_),_++),delete b[I]}else for(v=y[I],h=0;h<_;h++)m=m<<1|v&1,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=v>>1;B--,B==0&&(B=Math.pow(2,_),_++),y[E]=S++,I=String(C)}if(I!==""){if(Object.prototype.hasOwnProperty.call(b,I)){if(I.charCodeAt(0)<256){for(h=0;h<_;h++)m=m<<1,f==a-1?(f=0,x.push(u(m)),m=0):f++;for(v=I.charCodeAt(0),h=0;h<8;h++)m=m<<1|v&1,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=v>>1}else{for(v=1,h=0;h<_;h++)m=m<<1|v,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=0;for(v=I.charCodeAt(0),h=0;h<16;h++)m=m<<1|v&1,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=v>>1}B--,B==0&&(B=Math.pow(2,_),_++),delete b[I]}else for(v=y[I],h=0;h<_;h++)m=m<<1|v&1,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=v>>1;B--,B==0&&(B=Math.pow(2,_),_++)}for(v=2,h=0;h<_;h++)m=m<<1|v&1,f==a-1?(f=0,x.push(u(m)),m=0):f++,v=v>>1;for(;;)if(m=m<<1,f==a-1){x.push(u(m));break}else f++;return x.join("")},decompress:function(d){return d==null?"":d==""?null:r._decompress(d.length,32768,function(a){return d.charCodeAt(a)})},_decompress:function(d,a,u){var h=[],v=4,y=4,b=3,C="",E=[],I,B,S,_,x,m,f,g={val:u(0),position:a,index:1};for(I=0;I<3;I+=1)h[I]=I;for(S=0,x=Math.pow(2,2),m=1;m!=x;)_=g.val&g.position,g.position>>=1,g.position==0&&(g.position=a,g.val=u(g.index++)),S|=(_>0?1:0)*m,m<<=1;switch(S){case 0:for(S=0,x=Math.pow(2,8),m=1;m!=x;)_=g.val&g.position,g.position>>=1,g.position==0&&(g.position=a,g.val=u(g.index++)),S|=(_>0?1:0)*m,m<<=1;f=e(S);break;case 1:for(S=0,x=Math.pow(2,16),m=1;m!=x;)_=g.val&g.position,g.position>>=1,g.position==0&&(g.position=a,g.val=u(g.index++)),S|=(_>0?1:0)*m,m<<=1;f=e(S);break;case 2:return""}for(h[3]=f,B=f,E.push(f);;){if(g.index>d)return"";for(S=0,x=Math.pow(2,b),m=1;m!=x;)_=g.val&g.position,g.position>>=1,g.position==0&&(g.position=a,g.val=u(g.index++)),S|=(_>0?1:0)*m,m<<=1;switch(f=S){case 0:for(S=0,x=Math.pow(2,8),m=1;m!=x;)_=g.val&g.position,g.position>>=1,g.position==0&&(g.position=a,g.val=u(g.index++)),S|=(_>0?1:0)*m,m<<=1;h[y++]=e(S),f=y-1,v--;break;case 1:for(S=0,x=Math.pow(2,16),m=1;m!=x;)_=g.val&g.position,g.position>>=1,g.position==0&&(g.position=a,g.val=u(g.index++)),S|=(_>0?1:0)*m,m<<=1;h[y++]=e(S),f=y-1,v--;break;case 2:return E.join("")}if(v==0&&(v=Math.pow(2,b),b++),h[f])C=h[f];else if(f===y)C=B+B.charAt(0);else return null;E.push(C),h[y++]=B+C.charAt(0),v--,B=C,v==0&&(v=Math.pow(2,b),b++)}}};return r}();s!=null?s.exports=t:typeof angular<"u"&&angular!=null&&angular.module("LZString",[]).factory("LZString",function(){return t})}(Yt)),Yt.exports}var $t=Oi();function Es(s){var t;typeof s.remove<"u"?s.remove():(t=s.parentNode)==null||t.removeChild(s)}function Ri(s,t,e,l={}){const n=bi(s,t,l),i=document.createElement("div");return i.classList.add("v-toast--pending"),e.appendChild(i),An(n,i),n.component}class Bi{constructor(t,e){Y(this,"startedAt");Y(this,"callback");Y(this,"delay");Y(this,"timer");this.startedAt=Date.now(),this.callback=t,this.delay=e,this.timer=setTimeout(t,e)}pause(){this.stop(),this.delay-=Date.now()-this.startedAt}resume(){this.stop(),this.startedAt=Date.now(),this.timer=setTimeout(this.callback,this.delay)}stop(){clearTimeout(this.timer)}}const ue=Object.freeze({TOP_RIGHT:"top-right",TOP:"top",TOP_LEFT:"top-left",BOTTOM_RIGHT:"bottom-right",BOTTOM:"bottom",BOTTOM_LEFT:"bottom-left"});function Li(s){return{all:s=s||new Map,on:function(t,e){var l=s.get(t);l?l.push(e):s.set(t,[e])},off:function(t,e){var l=s.get(t);l&&(e?l.splice(l.indexOf(e)>>>0,1):s.set(t,[]))},emit:function(t,e){var l=s.get(t);l&&l.slice().map(function(n){n(e)}),(l=s.get("*"))&&l.slice().map(function(n){n(t,e)})}}}const rs=Li(),Tn=(s,t)=>{const e=s.__vccOpts||s;for(const[l,n]of t)e[l]=n;return e},Di=X({name:"Toast",props:{message:{type:String,required:!0},type:{type:String,default:"success"},position:{type:String,default:ue.BOTTOM_RIGHT,validator(s){return Object.values(ue).includes(s)}},duration:{type:Number,default:3e3},dismissible:{type:Boolean,default:!0},onDismiss:{type:Function,default:()=>{}},onClick:{type:Function,default:()=>{}},queue:Boolean,pauseOnHover:{type:Boolean,default:!0}},data(){return{isActive:!1,parentTop:null,parentBottom:null,isHovered:!1}},beforeMount(){this.setupContainer()},mounted(){this.showNotice(),rs.on("toast-clear",this.dismiss)},methods:{setupContainer(){if(this.parentTop=document.querySelector(".v-toast.v-toast--top"),this.parentBottom=document.querySelector(".v-toast.v-toast--bottom"),this.parentTop&&this.parentBottom)return;this.parentTop||(this.parentTop=document.createElement("div"),this.parentTop.className="v-toast v-toast--top"),this.parentBottom||(this.parentBottom=document.createElement("div"),this.parentBottom.className="v-toast v-toast--bottom");const s=document.body;s.appendChild(this.parentTop),s.appendChild(this.parentBottom)},shouldQueue(){return this.queue?this.parentTop.childElementCount>0||this.parentBottom.childElementCount>0:!1},dismiss(){this.timer&&this.timer.stop(),clearTimeout(this.queueTimer),this.isActive=!1,setTimeout(()=>{this.onDismiss.apply(null,arguments);const s=this.$refs.root;An(null,s),Es(s)},150)},showNotice(){if(this.shouldQueue()){this.queueTimer=setTimeout(this.showNotice,250);return}const s=this.$refs.root.parentElement;this.correctParent.insertAdjacentElement("afterbegin",this.$refs.root),Es(s),this.isActive=!0,this.duration&&(this.timer=new Bi(this.dismiss,this.duration))},whenClicked(){this.dismissible&&(this.onClick.apply(null,arguments),this.dismiss())},toggleTimer(s){!this.pauseOnHover||!this.timer||(s?this.timer.pause():this.timer.resume())}},computed:{correctParent(){switch(this.position){case ue.TOP:case ue.TOP_RIGHT:case ue.TOP_LEFT:return this.parentTop;case ue.BOTTOM:case ue.BOTTOM_RIGHT:case ue.BOTTOM_LEFT:return this.parentBottom}},transition(){switch(this.position){case ue.TOP:case ue.TOP_RIGHT:case ue.TOP_LEFT:return{enter:"v-toast--fade-in-down",leave:"v-toast--fade-out"};case ue.BOTTOM:case ue.BOTTOM_RIGHT:case ue.BOTTOM_LEFT:return{enter:"v-toast--fade-in-up",leave:"v-toast--fade-out"}}}},beforeUnmount(){rs.off("toast-clear",this.dismiss)}}),Ui=["innerHTML"];function ji(s,t,e,l,n,i){return T(),K(Ti,{"enter-active-class":s.transition.enter,"leave-active-class":s.transition.leave},{default:G(()=>[Q(p("div",{ref:"root",role:"alert",class:H(["v-toast__item",[`v-toast__item--${s.type}`,`v-toast__item--${s.position}`]]),onMouseover:t[0]||(t[0]=c=>s.toggleTimer(!0)),onMouseleave:t[1]||(t[1]=c=>s.toggleTimer(!1)),onClick:t[2]||(t[2]=(...c)=>s.whenClicked&&s.whenClicked(...c))},[t[3]||(t[3]=p("div",{class:"v-toast__icon"},null,-1)),p("p",{class:"v-toast__text",innerHTML:s.message},null,8,Ui)],34),[[ye,s.isActive]])]),_:1},8,["enter-active-class","leave-active-class"])}const $i=Tn(Di,[["render",ji]]),zi=(s={})=>({open(t){let e=null;typeof t=="string"&&(e=t);const n=Object.assign({},{message:e},s,t);return{dismiss:Ri($i,n,document.body).ctx.dismiss}},clear(){rs.emit("toast-clear")},success(t,e={}){return this.open(Object.assign({},{message:t,type:"success"},e))},error(t,e={}){return this.open(Object.assign({},{message:t,type:"error"},e))},info(t,e={}){return this.open(Object.assign({},{message:t,type:"info"},e))},warning(t,e={}){return this.open(Object.assign({},{message:t,type:"warning"},e))},default(t,e={}){return this.open(Object.assign({},{message:t,type:"default"},e))}});var wn,yn,xn,kn,_n,bn;const Ms=((wn=typeof globalThis<"u"?globalThis:void 0)==null?void 0:wn.crypto)||((yn=typeof global<"u"?global:void 0)==null?void 0:yn.crypto)||((xn=typeof window<"u"?window:void 0)==null?void 0:xn.crypto)||((kn=typeof self<"u"?self:void 0)==null?void 0:kn.crypto)||((bn=(_n=typeof frames<"u"?frames:void 0)==null?void 0:_n[0])==null?void 0:bn.crypto);let as;Ms?as=s=>{const t=[];for(let e=0,l;e<s;e+=4)t.push(Ms.getRandomValues(new Uint32Array(1))[0]);return new Oe(t,s)}:as=s=>{const t=[],e=l=>{let n=l,i=987654321;const c=4294967295;return()=>{i=36969*(i&65535)+(i>>16)&c,n=18e3*(n&65535)+(n>>16)&c;let r=(i<<16)+n&c;return r/=4294967296,r+=.5,r*(Math.random()>.5?1:-1)}};for(let l=0,n;l<s;l+=4){const i=e((n||Math.random())*4294967296);n=i()*987654071,t.push(i()*4294967296|0)}return new Oe(t,s)};class zt{static create(...t){return new this(...t)}mixIn(t){return Object.assign(this,t)}clone(){const t=new this.constructor;return Object.assign(t,this),t}}class Oe extends zt{constructor(t=[],e=t.length*4){super();let l=t;if(l instanceof ArrayBuffer&&(l=new Uint8Array(l)),(l instanceof Int8Array||l instanceof Uint8ClampedArray||l instanceof Int16Array||l instanceof Uint16Array||l instanceof Int32Array||l instanceof Uint32Array||l instanceof Float32Array||l instanceof Float64Array)&&(l=new Uint8Array(l.buffer,l.byteOffset,l.byteLength)),l instanceof Uint8Array){const n=l.byteLength,i=[];for(let c=0;c<n;c+=1)i[c>>>2]|=l[c]<<24-c%4*8;this.words=i,this.sigBytes=n}else this.words=t,this.sigBytes=e}toString(t=Fi){return t.stringify(this)}concat(t){const e=this.words,l=t.words,n=this.sigBytes,i=t.sigBytes;if(this.clamp(),n%4)for(let c=0;c<i;c+=1){const r=l[c>>>2]>>>24-c%4*8&255;e[n+c>>>2]|=r<<24-(n+c)%4*8}else for(let c=0;c<i;c+=4)e[n+c>>>2]=l[c>>>2];return this.sigBytes+=i,this}clamp(){const{words:t,sigBytes:e}=this;t[e>>>2]&=4294967295<<32-e%4*8,t.length=Math.ceil(e/4)}clone(){const t=super.clone.call(this);return t.words=this.words.slice(0),t}}Y(Oe,"random",as);const Fi={stringify(s){const{words:t,sigBytes:e}=s,l=[];for(let n=0;n<e;n+=1){const i=t[n>>>2]>>>24-n%4*8&255;l.push((i>>>4).toString(16)),l.push((i&15).toString(16))}return l.join("")},parse(s){const t=s.length,e=[];for(let l=0;l<t;l+=2)e[l>>>3]|=parseInt(s.substr(l,2),16)<<24-l%8*4;return new Oe(e,t/2)}},Os={stringify(s){const{words:t,sigBytes:e}=s,l=[];for(let n=0;n<e;n+=1){const i=t[n>>>2]>>>24-n%4*8&255;l.push(String.fromCharCode(i))}return l.join("")},parse(s){const t=s.length,e=[];for(let l=0;l<t;l+=1)e[l>>>2]|=(s.charCodeAt(l)&255)<<24-l%4*8;return new Oe(e,t)}},Cn={stringify(s){try{return decodeURIComponent(escape(Os.stringify(s)))}catch{throw new Error("Malformed UTF-8 data")}},parse(s){return Os.parse(unescape(encodeURIComponent(s)))}};class Ni extends zt{constructor(){super(),this._minBufferSize=0}reset(){this._data=new Oe,this._nDataBytes=0}_append(t){let e=t;typeof e=="string"&&(e=Cn.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes}_process(t){let e;const{_data:l,blockSize:n}=this,i=l.words,c=l.sigBytes,r=n*4;let d=c/r;t?d=Math.ceil(d):d=Math.max((d|0)-this._minBufferSize,0);const a=d*n,u=Math.min(a*4,c);if(a){for(let h=0;h<a;h+=n)this._doProcessBlock(i,h);e=i.splice(0,a),l.sigBytes-=u}return new Oe(e,u)}clone(){const t=super.clone.call(this);return t._data=this._data.clone(),t}}class In extends Ni{constructor(t){super(),this.blockSize=512/32,this.cfg=Object.assign(new zt,t),this.reset()}static _createHelper(t){return(e,l)=>new t(l).finalize(e)}static _createHmacHelper(t){return(e,l)=>new Pi(t,l).finalize(e)}reset(){super.reset.call(this),this._doReset()}update(t){return this._append(t),this._process(),this}finalize(t){return t&&this._append(t),this._doFinalize()}}class Pi extends zt{constructor(t,e){super();const l=new t;this._hasher=l;let n=e;typeof n=="string"&&(n=Cn.parse(n));const i=l.blockSize,c=i*4;n.sigBytes>c&&(n=l.finalize(e)),n.clamp();const r=n.clone();this._oKey=r;const d=n.clone();this._iKey=d;const a=r.words,u=d.words;for(let h=0;h<i;h+=1)a[h]^=1549556828,u[h]^=909522486;r.sigBytes=c,d.sigBytes=c,this.reset()}reset(){const t=this._hasher;t.reset(),t.update(this._iKey)}update(t){return this._hasher.update(t),this}finalize(t){const e=this._hasher,l=e.finalize(t);return e.reset(),e.finalize(this._oKey.clone().concat(l))}}const O=[];for(let s=0;s<64;s+=1)O[s]=Math.abs(Math.sin(s+1))*4294967296|0;const oe=(s,t,e,l,n,i,c)=>{const r=s+(t&e|~t&l)+n+c;return(r<<i|r>>>32-i)+t},le=(s,t,e,l,n,i,c)=>{const r=s+(t&l|e&~l)+n+c;return(r<<i|r>>>32-i)+t},re=(s,t,e,l,n,i,c)=>{const r=s+(t^e^l)+n+c;return(r<<i|r>>>32-i)+t},ae=(s,t,e,l,n,i,c)=>{const r=s+(e^(t|~l))+n+c;return(r<<i|r>>>32-i)+t};class Vi extends In{_doReset(){this._hash=new Oe([1732584193,4023233417,2562383102,271733878])}_doProcessBlock(t,e){const l=t;for(let z=0;z<16;z+=1){const $=e+z,L=t[$];l[$]=(L<<8|L>>>24)&16711935|(L<<24|L>>>8)&4278255360}const n=this._hash.words,i=l[e+0],c=l[e+1],r=l[e+2],d=l[e+3],a=l[e+4],u=l[e+5],h=l[e+6],v=l[e+7],y=l[e+8],b=l[e+9],C=l[e+10],E=l[e+11],I=l[e+12],B=l[e+13],S=l[e+14],_=l[e+15];let x=n[0],m=n[1],f=n[2],g=n[3];x=oe(x,m,f,g,i,7,O[0]),g=oe(g,x,m,f,c,12,O[1]),f=oe(f,g,x,m,r,17,O[2]),m=oe(m,f,g,x,d,22,O[3]),x=oe(x,m,f,g,a,7,O[4]),g=oe(g,x,m,f,u,12,O[5]),f=oe(f,g,x,m,h,17,O[6]),m=oe(m,f,g,x,v,22,O[7]),x=oe(x,m,f,g,y,7,O[8]),g=oe(g,x,m,f,b,12,O[9]),f=oe(f,g,x,m,C,17,O[10]),m=oe(m,f,g,x,E,22,O[11]),x=oe(x,m,f,g,I,7,O[12]),g=oe(g,x,m,f,B,12,O[13]),f=oe(f,g,x,m,S,17,O[14]),m=oe(m,f,g,x,_,22,O[15]),x=le(x,m,f,g,c,5,O[16]),g=le(g,x,m,f,h,9,O[17]),f=le(f,g,x,m,E,14,O[18]),m=le(m,f,g,x,i,20,O[19]),x=le(x,m,f,g,u,5,O[20]),g=le(g,x,m,f,C,9,O[21]),f=le(f,g,x,m,_,14,O[22]),m=le(m,f,g,x,a,20,O[23]),x=le(x,m,f,g,b,5,O[24]),g=le(g,x,m,f,S,9,O[25]),f=le(f,g,x,m,d,14,O[26]),m=le(m,f,g,x,y,20,O[27]),x=le(x,m,f,g,B,5,O[28]),g=le(g,x,m,f,r,9,O[29]),f=le(f,g,x,m,v,14,O[30]),m=le(m,f,g,x,I,20,O[31]),x=re(x,m,f,g,u,4,O[32]),g=re(g,x,m,f,y,11,O[33]),f=re(f,g,x,m,E,16,O[34]),m=re(m,f,g,x,S,23,O[35]),x=re(x,m,f,g,c,4,O[36]),g=re(g,x,m,f,a,11,O[37]),f=re(f,g,x,m,v,16,O[38]),m=re(m,f,g,x,C,23,O[39]),x=re(x,m,f,g,B,4,O[40]),g=re(g,x,m,f,i,11,O[41]),f=re(f,g,x,m,d,16,O[42]),m=re(m,f,g,x,h,23,O[43]),x=re(x,m,f,g,b,4,O[44]),g=re(g,x,m,f,I,11,O[45]),f=re(f,g,x,m,_,16,O[46]),m=re(m,f,g,x,r,23,O[47]),x=ae(x,m,f,g,i,6,O[48]),g=ae(g,x,m,f,v,10,O[49]),f=ae(f,g,x,m,S,15,O[50]),m=ae(m,f,g,x,u,21,O[51]),x=ae(x,m,f,g,I,6,O[52]),g=ae(g,x,m,f,d,10,O[53]),f=ae(f,g,x,m,C,15,O[54]),m=ae(m,f,g,x,c,21,O[55]),x=ae(x,m,f,g,y,6,O[56]),g=ae(g,x,m,f,_,10,O[57]),f=ae(f,g,x,m,h,15,O[58]),m=ae(m,f,g,x,B,21,O[59]),x=ae(x,m,f,g,a,6,O[60]),g=ae(g,x,m,f,E,10,O[61]),f=ae(f,g,x,m,r,15,O[62]),m=ae(m,f,g,x,b,21,O[63]),n[0]=n[0]+x|0,n[1]=n[1]+m|0,n[2]=n[2]+f|0,n[3]=n[3]+g|0}_doFinalize(){const t=this._data,e=t.words,l=this._nDataBytes*8,n=t.sigBytes*8;e[n>>>5]|=128<<24-n%32;const i=Math.floor(l/4294967296),c=l;e[(n+64>>>9<<4)+15]=(i<<8|i>>>24)&16711935|(i<<24|i>>>8)&4278255360,e[(n+64>>>9<<4)+14]=(c<<8|c>>>24)&16711935|(c<<24|c>>>8)&4278255360,t.sigBytes=(e.length+1)*4,this._process();const r=this._hash,d=r.words;for(let a=0;a<4;a+=1){const u=d[a];d[a]=(u<<8|u>>>24)&16711935|(u<<24|u>>>8)&4278255360}return r}clone(){const t=super.clone.call(this);return t._hash=this._hash.clone(),t}}const Rs=In._createHelper(Vi),Ft=(s,t)=>{let e=-1;const l=s.length,n=new Array(l);for(;++e<l;)n[e]=t(s[e]);return n},Hi=(s,t)=>{let e=-1;const l=s.length;for(;++e<l;)t(s[e])},Gi=s=>{if(s.scrollTop>0)return!0;s.scrollTop=1;const t=!!s.scrollTop;return s.scrollTop=0,t},Zi=async(s,t,e)=>{const l=[],n=[];for(const i of s){const c=Promise.resolve().then(()=>e(i));if(l.push(c),t<=s.length){const r=c.then(()=>n.splice(n.indexOf(r),1));n.push(r),n.length>=t&&await Promise.race(n)}}return Promise.all(l)},Bs=s=>{let t="",e=-1,l=13;for(;++e<l;)t+=Math.random()*10|0;const n=(Date.now()%1e10*1e3+(1e3*Math.random()|0)%4294967295).toString(),i=new URLSearchParams(s.code),c=i.get("fs"),r=(Date.now()/1e3|21600).toString(16),d=(Date.now()+Number(t)).toString(),a=atob(i.get("fm")).split("_")[0],u=Rs(`${d}|tars_mp|102`).toString();return`&wsSecret=${Rs([a,t,s.name,u,r].join("_")).toString()}&uuid=${n}&wsTime=${r}&uid=${t}&seqid=${d}&fs=${c}&ctype=tars_mp&t=102&ver=1&sv=2401310321`},Wi=window.location.origin+"/api/",Qi="https://lemonlive66.deno.dev/api/",be=(s,t,e)=>(s=="douyin"&&(e?e.cookie=ge[s]:e={cookie:ge[s]}),En(`${t!="getCategories"&&window.location.origin.endsWith(".pages.dev")&&(s=="bilibili"||s=="douyu"&&t=="getRoomDetail")?Qi:Wi}${s}/${t}${e?"?"+new URLSearchParams(e).toString():""}`)),cs=async s=>{const t=Object.keys(s.follows);if(!t.length)return Promise.resolve(!1);if(s.id=="douyin"){(await Zi(t,4,l=>be("douyin","getLiveStatus",{id:l}))).forEach((l,n)=>s.follows[t[n]].status=l[t[n]].status);return}await be(s.id,"getLiveStatus",{id:t.join(",")}).then(e=>Object.keys(e).forEach(l=>{s.follows[l].status=e[l].status}))},Nt=(s,t)=>En(`https://lemonlive999.deno.dev/${s}`,{method:"POST",body:JSON.stringify(t)}),Ji=s=>Nt("sync",{follows:$t.compressToBase64(JSON.stringify(s)),token:je.value}),Ki=()=>Nt("sync",{get:!0,token:je.value}).then(s=>JSON.parse($t.decompressFromBase64(s))),Yi=s=>Nt("sign",s),qi=s=>Nt("reset",s),ot=zi({duration:3e3,position:"top"}),En=(s,t)=>fetch(s,t).then(async e=>{let l=await e.text();return l=JSON.parse($t.decompressFromBase64(l)),l.code!=200?(console.log(l.msg),ot.error(l.msg),Promise.reject(l.msg)):l.data},e=>{ot.error("请求异常!")});U(!0);const Mn={huya:"虎牙",bilibili:"哔哩",douyu:"斗鱼",douyin:"抖音"},Z=[{name:"虎牙直播",icon:"https://www.huya.com/favicon.ico",id:"huya",categories:U([]),categoryActive:U(0),recommend:{page:1,hasMore:!0,list:U([])},search:{page:1,hasMore:!0,list:U([])},follows:Te(kt("huya"))},{name:"斗鱼直播",icon:"https://www.douyu.com/favicon.ico",id:"douyu",categories:U([]),categoryActive:U(0),recommend:{page:1,hasMore:!0,list:U([])},search:{page:1,hasMore:!0,list:U([])},follows:Te(kt("douyu"))},{name:"抖音直播",icon:"https://www.douyin.com/favicon.ico",id:"douyin",categories:U([]),categoryActive:U(0),recommend:{page:1,hasMore:!0,list:U([])},search:{page:1,hasMore:!0,list:U([])},follows:Te(kt("douyin"))},{name:"哔哩直播",icon:"https://www.bilibili.com/favicon.ico",id:"bilibili",categories:U([]),categoryActive:U(0),recommend:{page:1,hasMore:!0,list:U([])},search:{page:1,hasMore:!0,list:U([])},follows:Te(kt("bilibili"))}],We=["huya","douyu","douyin","bilibili"],pe=U(Be("volume",100)),ce=U(Be("brightness",100)),xt=s=>{pe.value=s?Math.min(100,pe.value+5):Math.max(0,pe.value-5)},Ls=s=>{ce.value=s?Math.min(200,ce.value+10):Math.max(50,ce.value-10)};function kt(s){const t=localStorage.getItem("follows-"+s);return t?JSON.parse(t):{}}function Bt(s){const t=Z.find(e=>e.id==s.siteId);return s.siteId=t.id,t.follows[s.roomId]={...s,stream:void 0,ws:void 0},localStorage.setItem("follows-"+s.siteId,JSON.stringify(t.follows)),Reflect.has(t.follows,s.roomId)}function us(s,t){const e=Z.find(l=>l.id==s);return delete e.follows[t],localStorage.setItem("follows-"+s,JSON.stringify(e.follows)),Reflect.has(e.follows,t)}function Xi(){Z.forEach(s=>{for(const t in s.follows)delete s.follows[t];localStorage.removeItem("follows-"+s.id)})}async function Ds(s,t){const e=s.categories;e.value.length||(e.value=await be(s.id,"getCategories"));for(const l of e.value)for(const n of l.list)if(n.cid==t)return n;return null}const M=Te(Be("dm-settings",{canvasOpen:!0,canvasFontsize:18,canvasGap:10,canvasOpacity:100,canvasRows:10,canvasSpeed:2.5,canvasColorOpen:!1,sideOpen:!0,sideFontsize:14,sideGap:2,sideColorOpen:!1,sideClean:100,colors:["#ffffff","#7e22ce","1d4ed8","#be185d","#fcd34d"],blockOpen:!1,blockWords:""}));Qe(()=>{Ce("dm-settings",M)});function Be(s,t){const e=localStorage.getItem(s);return e?JSON.parse(e):t}function Ce(s,t){localStorage.setItem(s,JSON.stringify(t))}const eo=["#ffffff","#000000","#374151","#b91c1c","#f87171","#fdba74","#c2410c","#fcd34d","#b45309","#bef264","#4d7c0f","#86efac","#15803d","#5eead4","#0f766e","#67e8f9","#0e7490","#93c5fd","#1d4ed8","#d8b4fe","#7e22ce","#f0abfc","#a21caf","#f9a8d4","#be185d","#fda4af","#be123c"],Us=J(()=>M.blockWords.length==0?[]:M.blockWords.split(" ").map(s=>new RegExp(s))),ge=Te(Be("cookies",{}));Qe(()=>Ce("cookies",ge));const te=U(0),Ge=U(Be("show-chat",!0)),it=U(Be("show-aside",!0));Qe(()=>Ce("show-chat",Ge.value));Qe(()=>Ce("show-aside",it.value));const st=U(Be("user",{})),je=U(Be("token","")),lt=Ft(Z,s=>({name:s.name,list:J(()=>Object.values(s.follows).sort(t=>t.status?-1:0))}));lt.unshift({name:"全部",list:J(()=>Z.map(s=>Object.values(s.follows)).flat().sort(s=>s.status?-1:0))});const to=VueRouter.createRouter,so=VueRouter.createWebHistory,ps=VueRouter.useRoute,Pt=VueRouter.useRouter,no=VueRouter.onBeforeRouteUpdate,io={class:"text-sm pos-fixed bottom-0 left-0 right-0 md:py-2 b-t-solid b b-gray-7 md:b-r-solid md:top-0 md:right-auto flex justify-around md:flex-col md:justify-left bg-dark-7 z-10"},oo={class:"h-full scrolly md:px-3"},lo={key:0,src:"https://live.douyin.com","pos-absolute":"",width:"0",height:"0","op-0":"","b-0":"",style:{"z-index":"-10"}},ro=X({__name:"App",setup(s){const t=[{icon:"i-ri-home-smile-line",link:"/"},{icon:"i-ri-apps-2-line",link:"/category"},{icon:"i-ri-heart-line",link:"/follow"},{icon:"i-ri-search-line",link:"/search"},{icon:"i-ri-user-smile-line",link:"/user"}],e=U(!0);Je(()=>{document.querySelector("main").style.height=`calc(${window.innerHeight}px - 3.5rem)`,setTimeout(()=>e.value=!1,5e3)});const l=ps();return ve(l,()=>{const n=l.params.siteid;if(n==null)return;const i=We.findIndex(c=>c==n);i!=-1&&(te.value=i)}),Qe(()=>{document.querySelectorAll(".v-toast").forEach(n=>{n.style.left=it?"70px":"0"})}),(n,i)=>{const c=Ot("router-link"),r=Ot("router-view");return T(),D(se,null,[Q(p("div",io,[(T(),D(se,null,fe(t,d=>P(c,{to:d.link,class:H(["hover:text-amber rounded-2 py-2 px-4 m-2",{"text-amber":n.$route.path==d.link}])},{default:G(()=>[p("div",{class:H(d.icon)},null,2)]),_:2},1032,["to","class"])),64))],512),[[ye,k(it)]]),p("main",{class:H(["md:!h-100vh mx-2 md:mx-0 pt-2 box-border",{"md:ml-17.5":k(it),"!h-100vh":!k(it)}])},[p("div",oo,[P(r,null,{default:G(({Component:d})=>[(T(),K(xi,{exclude:["play"]},[(T(),K(at(d)))],1024))]),_:1})])],2),k(e)?(T(),D("iframe",lo)):_e("",!0)],64)}}}),ao=s=>{const t=U(s);return[t,l=>t.value=l]},co=/scroll|auto|overlay/i;function uo(s){return s.tagName!=="HTML"&&s.tagName!=="BODY"&&s.nodeType===1}function fo(s,t=document.body){let e=s;for(;e&&e!==t&&uo(e);){const{overflowY:l}=window.getComputedStyle(e);if(co.test(l))return e;e=e.parentNode}return t}function ho(s,t=document.body){const e=U();return Je(()=>{s.value&&(e.value=fo(s.value,t))}),e}const vo={key:0,class:"text-center"},po={key:1,class:"text-center"},Vt=X({__name:"list",props:{finshedText:{default:"没有更多了"},errorText:{default:"加载失败,点击重新加载"},immediate:{type:Boolean,default:!0},offset:{default:50}},emits:["load","refresh"],setup(s,{emit:t}){const e=s,l=U(0),[n,i]=ao("normal"),c=U(),r=ho(c),d=t,a=()=>{if(l.value=r.value.scrollTop,n.value!="normal")return;r.value.scrollHeight-r.value.clientHeight-r.value.scrollTop<e.offset&&v()};Je(()=>{e.immediate&&v(),r.value.addEventListener("scroll",a,{passive:!0})}),Sn(()=>{r.value.scrollTop=l.value,r.value.addEventListener("scroll",a)});const u=()=>{r.value.removeEventListener("scroll",a)};Si(u),jt(u);let h;const v=()=>{i("loading"),d("load",i),clearTimeout(h),h=setTimeout(()=>{Gi(r.value)||d("load",i)},2e3)};return(y,b)=>(T(),D("div",{ref_key:"root",ref:c,class:"h-full select-none"},[Ci(y.$slots,"default"),k(n)=="loading"?(T(),D("div",vo,"加载中...")):k(n)=="finshed"?(T(),D("div",po,N(e.finshedText),1)):k(n)=="loaderror"?(T(),D("div",{key:2,class:"text-center cursor-pointer",onClick:v},N(e.errorText),1)):_e("",!0)],512))}}),mo=["data-id","data-site","href"],go={class:"pos-relative text-fuchsia-5 rounded-t-2 w-full aspect-video"},wo={class:"mx-auto h-full rounded-2 select-none block"},yo={class:"pos-absolute bottom-0 right-0 px-2 py-1 rounded-tl-2 bg-dark-6"},xo={class:"line-height-none pos-absolute top-0 right-0 px-1 py-1 rounded-tr-1 rounded-bl-2 bg-dark-6"},ko={key:0,class:"rounded-2 text-white pos-absolute text-8 top-0 bottom-0 left-0 right-0 flex justify-center items-center bg-gray-7 bg-op-80"},_o={class:"px-2 text-truncate leading-normal"},bo={class:"px-2 text-truncate leading-normal pb-2"},ms=X({__name:"rooms",props:{list:{}},setup(s){let t;const e=Pt(),l=U(),n=r=>{clearTimeout(t),t=setTimeout(()=>{const d=c("id",r.target,l.value);if(!d)return;const a=c("site",r.target,l.value);e.push(`/${a}/play/${d}`)},300)},i=r=>{var h;clearTimeout(t);const d=c("id",r.target,l.value);if(!d)return;const u=`/${c("site",r.target,l.value)}/play/${d}`;(h=window.open(u,"_blank"))==null||h.location},c=(r,d,a)=>{if(d==a)return null;const u=d.dataset[r];return u||c(r,d.parentElement,a)};return(r,d)=>{const a=Ut("lazy");return r.list.value.length>0?(T(),D("div",{key:0,ref_key:"root",ref:l,class:"grid gap-4 p-2 justify-evenly cursor-pointer select-none grid-cols-2 md:grid-cols-3 xl:grid-cols-4 2xl:grid-cols-5",onClick:ne(n,["prevent"]),onDblclick:ne(i,["prevent"])},[(T(!0),D(se,null,fe(r.list.value,u=>(T(),D("a",{"data-id":u.roomId,"data-site":u.siteId,href:`/${u.siteId}/play/${u.roomId}`,key:`${u.siteId}-${u.roomId}`,class:"shadow rounded-2 b-2px b-solid b-transparent hover:b-amber overflow-hidden"},[p("div",go,[Q(p("img",wo,null,512),[[a,u.cover]]),p("div",yo,N(u.category),1),p("div",xo,[d[0]||(d[0]=p("div",{class:"i-mdi-fire"},null,-1)),p("span",null,N(u.online),1)]),u.status?_e("",!0):(T(),D("div",ko," 未开播 "))]),p("div",_o,N(u.title),1),p("div",bo,N(u.nickname),1)],8,mo))),128))],544)):_e("",!0)}}}),So={class:"h-full"},Ao={class:"py-1 px-2 text-lg text-center relative"},To={class:"hover:text-amber"},Co={key:0,class:"h-[calc(100%-3.25rem)] scrolly"},Io=X({__name:"categoryRooms",setup(s){const t=ps(),e=U(""),l=U(),n={list:U([]),page:1,hasMore:!0},i=a=>{const{site:u,id:h}=t.meta;be(u.id,"getCategoryRooms",{id:h,pid:l.value,page:n.page}).then(v=>{if(n.list.value=n.list.value.concat(v.list),n.hasMore=v.hasMore,ge[u.id]||(ge[u.id]=v.cookie),!v.hasMore)return a("finshed");n.page++,a("normal")},v=>{e.value=v,a("loaderror")})},c=U(!1),r=()=>{document.querySelector("#goTop").click(),c.value=!0;const{site:a,id:u}=t.meta;be(a.id,"getCategoryRooms",{id:u,pid:l.value,page:n.page}).then(h=>{n.list.value=h.list,n.hasMore=h.hasMore,n.page++,ge[a.id]||(ge[a.id]=h.cookie)},h=>{e.value=h}).finally(()=>c.value=!1)};let d=t.fullPath;return Ds(t.meta.site,t.meta.id).then(a=>{e.value=(a==null?void 0:a.name)||null,l.value=a==null?void 0:a.pid}),Sn(function(){d!=t.fullPath&&(d=t.fullPath,Ds(t.meta.site,t.meta.id).then(a=>{e.value=(a==null?void 0:a.name)||null,l.value=a==null?void 0:a.pid}),n.list.value=[],n.page=1,n.hasMore=!0)}),(a,u)=>{var y;const h=ms,v=Vt;return T(),D("div",So,[p("div",Ao,[p("div",{onClick:u[0]||(u[0]=(...b)=>a.$router.back&&a.$router.back(...b)),class:"i-ri-arrow-left-line hover:text-amber absolute left-2"}),p("div",{onClick:r,class:H(["i-ri-refresh-line hover:text-amber absolute right-4 md:right-unset md:left-12",{"animate-spin":k(c)}])},null,2),p("span",To,N(`${(y=k(t).meta.site)==null?void 0:y.name} ${k(e)==null?"分区不存在":k(e)==""?"加载中":k(e)}`),1)]),k(e)?(T(),D("div",Co,[(T(),K(v,{key:k(d),onLoad:i},{default:G(()=>[P(h,{list:n.list},null,8,["list"])]),_:1}))])):_e("",!0)])}}}),On=Symbol("tabs"),Eo=(s,t)=>{const e=Te([]);return Ii(s,Object.assign({link:i=>{i.proxy&&e.push(i.proxy)},unlink:i=>{const c=e.indexOf(i.proxy);e.splice(c,1)},children:e},t)),e},Rn=s=>{const t=Ei(s);if(t==null)return{parent:t,index:U(-1)};const e=Mi(),{link:l,unlink:n,children:i}=t;l(e),Ai(()=>n(e));const c=J(()=>i.indexOf(e.proxy));return{parent:t,children:i,index:c}},Mo={class:"h-full box-border"},Oo={class:"w-full box-border text-sm sm:text-base"},Ro=["onClick"],Bo={class:"h-[calc(100%-2rem)] scrolly box-border pt-1"},ht=X({__name:"tabs",props:ct({link:{type:Boolean,default:!1},lazy:{type:Boolean,default:!0},grow:{type:Boolean,default:!1},swipeable:{type:Boolean,default:!1},swipeloop:{type:Boolean,default:!0},justify:{default:"justify-center"}},{active:{default:0},activeModifiers:{}}),emits:ct(["tabClick"],["update:active"]),setup(s,{emit:t}){const e=ft(s,"active"),l=s,n=t,i=a=>{e.value=a,n("tabClick",a)},c=Eo(On,{active:e,props:l}),r=J(()=>Ft(c,a=>a.title)),d=vs();return(a,u)=>{const h=Ot("router-link");return T(),D("div",Mo,[p("div",Oo,[p("div",{class:H(["flex p1 sm:gap-1 text-center h-8 box-border lg:justify-center scrollx",[k(c).length>5||a.grow?"":a.justify]])},[l.link?(T(!0),D(se,{key:0},fe(k(r),(v,y)=>(T(),K(h,{class:H(["px-1 sm:px-2 box-border shrink-0 rounded py-1 line-height-none text-centercursor-pointer hover:text-amber cursor-pointer",{"text-amber":e.value==y,grow:a.grow}]),to:k(c)[y].href},{default:G(()=>[Et(N(v),1)]),_:2},1032,["class","to"]))),256)):(T(!0),D(se,{key:1},fe(k(r),(v,y)=>(T(),D("a",{class:H(["px-1 sm:px-2 box-border shrink-0 rounded py-1 line-height-none text-centercursor-pointer hover:text-amber cursor-pointer",{"text-amber":e.value==y,grow:a.grow}]),onClick:b=>i(y)},N(v),11,Ro))),256))],2)]),p("div",Bo,[(T(),K(at(d.default)))])])}}}),Lo=Symbol("swipe"),Do={class:"w-full h-full shrink-0 pos-relative"},Uo=X({__name:"swipeItem",emits:["inited"],setup(s,{emit:t}){const e=U(!1),{parent:l,children:n,index:i}=Rn(Lo),c=vs(),r=t,d=J(()=>(l==null?void 0:l.active.value)==i.value?(e.value||(e.value=!0,r("inited",i.value)),!0):i.value==(l.active.value==0?n.length-1:l.active.value-1)||i.value==(l.active.value==n.length-1?0:l.active.value+1)),a=J(()=>d.value||e.value||!(l!=null&&l.props.lazy)?c.default:null);return(u,h)=>Q((T(),D("div",Do,[(T(),K(at(k(a))))],512)),[[ye,k(d)]])}}),jo={class:"scrolly h-full w-full shrink-0"},vt=X({__name:"tab",props:{title:{},href:{}},emits:["inited"],setup(s,{expose:t,emit:e}){const l=s,n=U(!1),i=vs(),{parent:c,index:r,children:d}=Rn(On),a=e,u=J(()=>(c==null?void 0:c.active.value)==r.value?(n.value||(n.value=!0,a("inited",r.value)),!0):(c==null?void 0:c.props.swipeable)&&(r.value==(c.active.value==0?d.length-1:c.active.value-1)||r.value==(c.active.value==d.length-1?0:c.active.value+1))),h=J(()=>u.value||c!=null&&c.props.swipeable||n.value||!(c!=null&&c.props.lazy)?i.default:null);return t({title:l.title}),(v,y)=>{var C,E;const b=Uo;return Q((T(),D("div",jo,[(C=k(c))!=null&&C.props.swipeable?(T(),K(b,{key:0},{default:G(()=>[(T(),K(at(k(h))))]),_:1})):(T(),K(at(k(h)),{key:1}))],512)),[[ye,k(u)||((E=k(c))==null?void 0:E.props.swipeable)]])}}}),$o={key:0,class:"text-center"},zo={class:"pb-2 grid gap-4 px-4 md:px-2 grid-cols-4 sm:grid-cols-6 md:grid-cols-8 lg:grid-cols-10 xl:grid-cols-15 2xl:grid-cols-18"},Fo={class:"w-full aspect-ratio-square rounded"},No={class:"w-full text-truncate text-xs md:text-sm text-center"},Po=X({__name:"category",setup(s){const t=J(()=>Z[te.value].id),e=U(),l=n=>{Z[n].categories.value.length||(e.value="加载中...",be(t.value,"getCategories").then(i=>{e.value=null,Z[n].categories.value=i},i=>e.value=i))};return(n,i)=>{const c=Ot("router-link"),r=vt,d=ht,a=Ut("lazy");return T(),K(d,{active:k(te),"onUpdate:active":i[0]||(i[0]=u=>$e(te)?te.value=u:null),link:!0,class:"pt-1"},{default:G(()=>[(T(!0),D(se,null,fe(k(Z),u=>(T(),K(r,{title:u.name,href:`/${u.id}/category`,onInited:l,key:u.id},{default:G(()=>[k(e)?(T(),D("div",$o,N(k(e)),1)):(T(),K(d,{key:1,active:u.categoryActive.value,"onUpdate:active":h=>u.categoryActive.value=h},{default:G(()=>[(T(!0),D(se,null,fe(u.categories.value,h=>(T(),K(r,{title:h.name,key:h.id},{default:G(()=>[p("div",zo,[(T(!0),D(se,null,fe(h.list,v=>(T(),K(c,{to:`/${u.id}/category/${v.cid}`,class:"cursor-pointer"},{default:G(()=>[Q(p("img",Fo,null,512),[[a,v.pic]]),p("div",No,N(v.name),1)]),_:2},1032,["to"]))),256))])]),_:2},1032,["title"]))),128))]),_:2},1032,["active","onUpdate:active"]))]),_:2},1032,["title","href"]))),128))]),_:1},8,["active"])}}}),Vo={class:"text-center py-1"},Ho={class:"w-60% max-w-md pos-relative inline-block"},Go={class:"h-[calc(100%-3rem)]"},Zo={key:1},Wo={key:1},Qo=X({__name:"search",setup(s){const t=U(""),e=J(()=>Z[te.value]),l=U(),n=()=>{if(!t.value)return Promise.resolve();const u=e.value.search;u.list.value=[],u.page=1,u.hasMore=!0,l.value="搜索中...";const h=e.value.id;return be(h,"searchRooms",{page:u.page,kw:t.value}).then(v=>{u.list.value=v.list,u.hasMore=v.hasMore,u.page+=1,l.value="finished",ge[h]||(ge[h]=v.cookie)},v=>l.value=v)},i=u=>{const h=e.value.search,v=e.value.id;u("loading"),be(v,"searchRooms",{page:h.page,kw:t.value}).then(y=>{if(h.list.value=h.list.value.concat(y.list),h.hasMore=y.hasMore,ge[v]||(ge[v]=y.cookie),!h.hasMore)return u("finshed");h.page+=1,u("normal")},y=>{u("loaderror")})},c=u=>{r.push(`/${We[u]}/search`),!d()&&Z[u].search.page==1&&n()},r=Pt(),d=()=>{if(t.value)return/^[\d]*$/.test(t.value)?(r.push(`/play/${e.value.id}/${t.value}`),!0):!1},a=()=>{d()||(Z.forEach(u=>u.search.page=1),n())};return(u,h)=>{const v=ms,y=Vt,b=vt,C=ht;return T(),D(se,null,[p("div",Vo,[p("div",Ho,[Q(p("input",{class:"md:text-4 box-border w-full py-2.5 pl-3 pr-9 text-white bg-transparent b-1 b-style-groove b-green rounded-6 outline-0",type:"text","onUpdate:modelValue":h[0]||(h[0]=E=>$e(t)?t.value=E:null),onKeydown:ki(a,["enter"]),placeholder:"请输入房间号或关键字"},null,544),[[Rt,k(t),void 0,{trim:!0}]]),p("div",{class:"i-ri-search-line top-50% absolute right-3",onClick:a,style:{transform:"translateY(-50%)"}})])]),p("div",Go,[P(C,{active:k(te),"onUpdate:active":h[1]||(h[1]=E=>$e(te)?te.value=E:null),onTabClick:c},{default:G(()=>[(T(!0),D(se,null,fe(k(Z),E=>(T(),K(b,{title:E.name,key:E.id},{default:G(()=>[k(l)=="finished"?(T(),D(se,{key:0},[E.search.list.value.length?(T(),K(y,{key:0,onLoad:i},{default:G(()=>[P(v,{list:E.search.list},null,8,["list"])]),_:2},1024)):(T(),D("div",Zo," 什么也没有找到 "))],64)):(T(),D("div",Wo,N(k(l)),1))]),_:2},1032,["title"]))),128))]),_:1},8,["active"])])],64)}}}),Jo=["data-id","data-site"],Ko={class:"pos-relative text-fuchsia-5 rounded-t-2 w-full aspect-video"},Yo={class:"blockmx-auto text-center h-full rounded-2 select-none"},qo={class:"pos-absolute bottom-0 right-0 px-2 py-1 rounded-tl-2 bg-dark-6"},Xo={class:"line-height-none pos-absolute top-0 right-0 px-1 py-1 rounded-tr-1 rounded-bl-2 bg-dark-6"},el={key:0,class:"rounded-2 text-white pos-absolute text-8 top-0 bottom-0 left-0 right-0 flex justify-center items-center bg-gray-7 bg-op-80"},tl=["onClick"],sl={class:"px-2 text-truncate leading-normal"},nl={class:"px-2 pb-2 flex items-center justify-between"},il={class:"flex items-center grow"},ol=["src"],ll={class:"text-truncate mx-1 w-2 grow"},rl=X({__name:"rooms2",props:{list:{}},setup(s){let t;const e=Pt(),l=U(),n=r=>{clearTimeout(t),t=setTimeout(()=>{const d=c("id",r.target,l.value);if(!d)return;const a=c("site",r.target,l.value);e.push(`/${a}/play/${d}`)},300)},i=r=>{var h;clearTimeout(t);const d=c("id",r.target,l.value);if(!d)return;const u=`/${c("site",r.target,l.value)}/play/${d}`;(h=window.open(u,"_blank"))==null||h.location},c=(r,d,a)=>{if(d==a)return null;const u=d.dataset[r];return u||c(r,d.parentElement,a)};return(r,d)=>{const a=Ut("lazy");return r.list.value.length>0?(T(),D("div",{key:0,ref_key:"root",ref:l,class:"grid gap-4 p-2 justify-evenly cursor-pointer select-none grid-cols-2 md:grid-cols-3 xl:grid-cols-4 2xl:grid-cols-5",onClick:n,onDblclick:ne(i,["prevent"])},[(T(!0),D(se,null,fe(r.list.value,u=>(T(),D("div",{"data-id":u.roomId,"data-site":u.siteId,key:`${u.siteId}-${u.roomId}`,class:"shadow rounded-2 b-2px b-solid b-transparent hover:b-amber overflow-hidden"},[p("div",Ko,[Q(p("img",Yo,null,512),[[a,u.cover]]),p("div",qo,N(u.category),1),p("div",Xo,[d[0]||(d[0]=p("div",{class:"i-mdi-fire"},null,-1)),p("span",null,N(u.online),1)]),u.status?_e("",!0):(T(),D("div",el," 未开播 ")),p("div",{class:"pos-absolute z-1 left-2 top-2 text-green-5 w-6 h-6 hover:text-amber i-mdi-heart-off-outline",onClick:ne(h=>k(us)(u.siteId,u.roomId),["stop"])},null,8,tl)]),p("div",sl,N(u.title),1),p("div",nl,[p("div",il,[p("img",{src:u.avatar,alt:"",class:"w-6 h-6 rounded-4"},null,8,ol),p("div",ll,N(u.nickname),1)]),p("div",null,N(k(Mn)[u.siteId]),1)])],8,Jo))),128))],544)):_e("",!0)}}}),al={class:"flex justify-center items-center"},cl={class:"h-[calc(100%-3rem)]"},ul=X({__name:"follow",setup(s){const t=U(0),e=U(!1),l=()=>{var r;if(e.value)return;const c=t.value;e.value=!0,c==0?Promise.all(Ft(Z,cs)).finally(n):(r=cs(Z[c-1]))==null||r.finally(n)},n=()=>setTimeout(()=>e.value=!1,300);l();const i=c=>c("finshed");return(c,r)=>{const d=rl,a=Vt,u=vt,h=ht;return T(),D(se,null,[p("div",al,[r[1]||(r[1]=p("div",null,"我的关注",-1)),p("div",{onClick:l,class:H(["rounded-6 mx-4 hover:text-amber i-ri-refresh-line",{"animate-spin":k(e)}])},null,2)]),p("div",cl,[P(h,{active:k(t),"onUpdate:active":r[0]||(r[0]=v=>$e(t)?t.value=v:null)},{default:G(()=>[(T(!0),D(se,null,fe(k(lt),v=>(T(),K(u,{title:v.name},{default:G(()=>[P(a,{onLoad:i,"finshed-text":""},{default:G(()=>[P(d,{list:v.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["title"]))),256))]),_:1},8,["active"])])],64)}}}),dl=X({__name:"index",setup(s){const t=J(()=>Z[te.value].id),e=l=>{const n=Z[te.value].recommend;be(t.value,"getRecommendRooms",{page:n.page}).then(i=>{if(n.list.value=n.list.value.concat(i.list),n.hasMore=i.hasMore,ge[t.value]||(ge[t.value]=i.cookie),!n.hasMore)return l("finshed");n.page++,l("normal")},()=>l("loaderror"))};return(l,n)=>{const i=ms,c=Vt,r=vt,d=ht;return T(),K(d,{active:k(te),"onUpdate:active":n[0]||(n[0]=a=>$e(te)?te.value=a:null),link:!0,class:"pt-1"},{default:G(()=>[(T(!0),D(se,null,fe(k(Z),a=>(T(),K(r,{href:`/${a.id}`,key:a.id,title:a.name,class:"pos-relative"},{default:G(()=>[P(c,{onLoad:e,class:"h-full"},{default:G(()=>[P(i,{list:a.recommend.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["href","title"]))),128))]),_:1},8,["active"])}}}),fl=X({__name:"switch",props:{value:{type:Boolean,required:!0},valueModifiers:{}},emits:["update:value"],setup(s){const t=ft(s,"value");return(e,l)=>(T(),D("div",{onClick:l[0]||(l[0]=()=>t.value=!t.value),class:H(["pos-relative w-12 inline-block cursor-pointer rounded-6 h-6",[t.value?"bg-amber":"bg-gray-4"]]),style:{transition:"background-color .3s"}},[p("div",{class:"w-6 h-full rounded-6 bg-white",style:Ze([{transition:"transform .3s"},t.value?"transform:translateX(1.5rem)":""])},null,4)],2))}}),hl={class:"rounded-4 flex bg-gray-7 w-min p-2 py-1 gap-2"},vl=X({__name:"stepper",props:ct({max:{},min:{},step:{}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(s){const t=s,e=ft(s,"value"),l=()=>e.value=Math.min(e.value+t.step,t.max),n=()=>e.value=Math.max(e.value-t.step,t.min);return(i,c)=>(T(),D("div",hl,[p("div",{class:"i-ri-subtract-fill",onClick:n}),p("div",null,N(e.value),1),p("div",{class:"i-ri-add-fill",onClick:l})]))}});function pl(){try{return document.createEvent("TouchEvent"),!0}catch{return!1}}const Mt=pl(),ml=s=>Mt?s.touches==null?s:s.touches[0]||s.changedTouches[0]:s,gl=X({__name:"slider",props:ct({max:{default:100},min:{default:0},width:{default:30},height:{default:100}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(s){const t=s,e=ft(s,"value"),l=U(),n=t.width<t.height;let i;const c=h=>{h.stopPropagation(),a(h),document.addEventListener("mousemove",a,!0),document.addEventListener("mouseup",u,!0)},r=J(()=>(e.value-t.min)/(t.max-t.min)*100),d=J(()=>{const h=100-r.value,v=`top:${h}%`,y=`left:${h}%`;return n?{loaded:v,indicator:v}:{loaded:`${y};transform:translateX(-100%)`,indicator:y}}),a=h=>{h.stopPropagation(),h=ml(h);const y=100-(Math.min(n?i.height:i.width,Math.max(0,n?h.clientY-i.y:h.clientX-i.x))/(n?i.height:i.width)*100|0);e.value=((t.max-t.min)*y|0)/100+t.min|0},u=h=>{h.stopPropagation(),document.removeEventListener("mousemove",a,!0),document.removeEventListener("mouseup",u,!0)};return Je(()=>{i=l.value.getBoundingClientRect(),l.value.addEventListener("mousedown",c,!0)}),jt(()=>{l.value.removeEventListener("mousedown",c,!0)}),(h,v)=>(T(),D("div",{class:H(["cursor-pointer flex justify-center",n?" py-4 ":"px-4"]),style:Ze({width:`${t.width}px`,height:`${t.height}px`})},[p("div",{ref_key:"root",ref:l,onClick:a,class:"w-full h-full pos-relative flex justify-center items-center"},[p("div",{class:H(["bg-gray pos-relative overflow-hidden",n?"h-full w-2px":"w-full h-2px"])},[p("div",{class:"w-full bg-amber h-full pos-absolute",style:Ze(k(d).loaded)},null,4)],2),p("div",{class:H(["pos-absolute w-12px h-12px bg-amber rounded-2",n?"-mt-6px":"-ml-6px"]),style:Ze(k(d).indicator)},null,6)],512)],6))}}),wl={key:0,class:"z-1 fixed top-0 bottom-0 left-0 right-0 bg-transparent","data-index":"-1"},yl={class:"p-1 hover:text-amber","data-index":"-1"},xl={class:"left-50% text-center z-1 pos-absolute top-0 w-max",style:{transform:"translate3d(-50%,-100%,0)"}},kl=["data-index"],_l=X({__name:"select",props:ct(["list"],{active:{required:!0},activeModifiers:{}}),emits:["update:active"],setup(s){const t=ft(s,"active"),e=U(!1),l=n=>{const i=n.target.dataset.index;i&&(i!="-1"&&(t.value=parseInt(i)),e.value=!e.value)};return(n,i)=>(T(),D("div",{onClick:l,class:"inline-block pos-relative cursor-pointer text-center"},[k(e)?(T(),D("div",wl)):_e("",!0),p("div",yl,N(s.list[t.value]),1),Q(p("div",xl,[(T(!0),D(se,null,fe(s.list,(c,r)=>(T(),D("div",{"data-index":r,class:H([{"text-amber":r==t.value},"p-1 hover:text-amber"])},N(c),11,kl))),256))],512),[[ye,k(e)]])]))}}),js="data:image/png;base64,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",$s="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAMAAACahl6sAAAArlBMVEUAAAD///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////8tivQqAAAAOXRSTlMAQL+AVSFwReurxLHcZuZhaxvx9dKPfhIHXc6LUC4LeVmgOMiFNCbXm5N04LeoSzz7pBYru5YPA5jd4ld+AAAKR0lEQVR42uzba3OiMBQG4INXvKGiUuttvaPVarW27vv//9h21umCJlZOBMPO8Hy2Dm+TcMIJUiKRSCQSiUQikUj8p8bL1JdMm5RtXr++YGeQVpkUTswlqUm7OOmkSZ8MPAW1HPDoS5KBX0EtRwySHMs40yKuCs5tSIseLmSIZ2biXIm0KOGCWyeWAxCLIYFgRBxTCJakA0QV1swUrUkHiKx3CipbhuiVdICAcw/eQWJKOpQgkaNgXvAlJou9B4nGjIIw3iBRJC2OZaiu18EEMhnSIwcZh25bQuaDdClAJk+3PEOmOCBd3k1IFNu3/syChD0jfSqQ6arc7lAlnXaQ6dFPHMi0SKvsChLNPV23gUzqSHpVIfObrto3IWH3SbcRZJ6Znx+SdvUyJFZZkqtBpksxMITMjqTGDUikKBY+IFMjiXYKEvacYuGpCQmzT6JuXBfISQ8yTRIMY7dA2vV+PlNLT7vLxei1sD5AJiUoSz9Weh0tp07tuWfM5vXPIz1CNl/pFiZlGxFqmOVmsdCt5LMUjf7LGg9WqryHnqLVhBadVp/CM2+9QZu31pzCUZ/a0Mqe1ikEWxfalYd0twxioUV3chATE7pLCvFBd5ggRsqk7IBYWas3d5kaljtJBTRxrQaYCqSkCyn77FoPhUXLyVV7xiz71Cam9lN2ZvSqOae1KBxSPkXXDO/etYXI/TDq9CDjXAGCHvGtcWk0psfavuJC55O4arhQytPjZex7J9d+hTNWjbSYr3Buc9+AFLKkyxpnXu8q6QXSaIEzY+Iw4pPjsp4t1XtVnSfSKg8/mzPL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",_t=window.Flv,bt=window.Hls;function Ke(s){let t=s.length;for(;--t>=0;)s[t]=0}const bl=3,Sl=258,Bn=29,Al=256,Tl=Al+1+Bn,Ln=30,Cl=512,Il=new Array((Tl+2)*2);Ke(Il);const El=new Array(Ln*2);Ke(El);const Ml=new Array(Cl);Ke(Ml);const Ol=new Array(Sl-bl+1);Ke(Ol);const Rl=new Array(Bn);Ke(Rl);const Bl=new Array(Ln);Ke(Bl);const Ll=(s,t,e,l)=>{let n=s&65535|0,i=s>>>16&65535|0,c=0;for(;e!==0;){c=e>2e3?2e3:e,e-=c;do n=n+t[l++]|0,i=i+n|0;while(--c);n%=65521,i%=65521}return n|i<<16|0};var ds=Ll;const Dl=()=>{let s,t=[];for(var e=0;e<256;e++){s=e;for(var l=0;l<8;l++)s=s&1?3988292384^s>>>1:s>>>1;t[e]=s}return t},Ul=new Uint32Array(Dl()),jl=(s,t,e,l)=>{const n=Ul,i=l+e;s^=-1;for(let c=l;c<i;c++)s=s>>>8^n[(s^t[c])&255];return s^-1};var ke=jl,fs={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},Dn={Z_NO_FLUSH:0,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_DEFLATED:8};const $l=(s,t)=>Object.prototype.hasOwnProperty.call(s,t);var zl=function(s){const t=Array.prototype.slice.call(arguments,1);for(;t.length;){const e=t.shift();if(e){if(typeof e!="object")throw new TypeError(e+"must be non-object");for(const l in e)$l(e,l)&&(s[l]=e[l])}}return s},Fl=s=>{let t=0;for(let l=0,n=s.length;l<n;l++)t+=s[l].length;const e=new Uint8Array(t);for(let l=0,n=0,i=s.length;l<i;l++){let c=s[l];e.set(c,n),n+=c.length}return e},Un={assign:zl,flattenChunks:Fl};let jn=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{jn=!1}const ut=new Uint8Array(256);for(let s=0;s<256;s++)ut[s]=s>=252?6:s>=248?5:s>=240?4:s>=224?3:s>=192?2:1;ut[254]=ut[254]=1;var Nl=s=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(s);let t,e,l,n,i,c=s.length,r=0;for(n=0;n<c;n++)e=s.charCodeAt(n),(e&64512)===55296&&n+1<c&&(l=s.charCodeAt(n+1),(l&64512)===56320&&(e=65536+(e-55296<<10)+(l-56320),n++)),r+=e<128?1:e<2048?2:e<65536?3:4;for(t=new Uint8Array(r),i=0,n=0;i<r;n++)e=s.charCodeAt(n),(e&64512)===55296&&n+1<c&&(l=s.charCodeAt(n+1),(l&64512)===56320&&(e=65536+(e-55296<<10)+(l-56320),n++)),e<128?t[i++]=e:e<2048?(t[i++]=192|e>>>6,t[i++]=128|e&63):e<65536?(t[i++]=224|e>>>12,t[i++]=128|e>>>6&63,t[i++]=128|e&63):(t[i++]=240|e>>>18,t[i++]=128|e>>>12&63,t[i++]=128|e>>>6&63,t[i++]=128|e&63);return t};const Pl=(s,t)=>{if(t<65534&&s.subarray&&jn)return String.fromCharCode.apply(null,s.length===t?s:s.subarray(0,t));let e="";for(let l=0;l<t;l++)e+=String.fromCharCode(s[l]);return e};var Vl=(s,t)=>{const e=t||s.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(s.subarray(0,t));let l,n;const i=new Array(e*2);for(n=0,l=0;l<e;){let c=s[l++];if(c<128){i[n++]=c;continue}let r=ut[c];if(r>4){i[n++]=65533,l+=r-1;continue}for(c&=r===2?31:r===3?15:7;r>1&&l<e;)c=c<<6|s[l++]&63,r--;if(r>1){i[n++]=65533;continue}c<65536?i[n++]=c:(c-=65536,i[n++]=55296|c>>10&1023,i[n++]=56320|c&1023)}return Pl(i,n)},Hl=(s,t)=>{t=t||s.length,t>s.length&&(t=s.length);let e=t-1;for(;e>=0&&(s[e]&192)===128;)e--;return e<0||e===0?t:e+ut[s[e]]>t?e:t},hs={string2buf:Nl,buf2string:Vl,utf8border:Hl};function Gl(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}var Zl=Gl;const St=16209,Wl=16191;var Ql=function(t,e){let l,n,i,c,r,d,a,u,h,v,y,b,C,E,I,B,S,_,x,m,f,g,z,$;const L=t.state;l=t.next_in,z=t.input,n=l+(t.avail_in-5),i=t.next_out,$=t.output,c=i-(e-t.avail_out),r=i+(t.avail_out-257),d=L.dmax,a=L.wsize,u=L.whave,h=L.wnext,v=L.window,y=L.hold,b=L.bits,C=L.lencode,E=L.distcode,I=(1<<L.lenbits)-1,B=(1<<L.distbits)-1;e:do{b<15&&(y+=z[l++]<<b,b+=8,y+=z[l++]<<b,b+=8),S=C[y&I];t:for(;;){if(_=S>>>24,y>>>=_,b-=_,_=S>>>16&255,_===0)$[i++]=S&65535;else if(_&16){x=S&65535,_&=15,_&&(b<_&&(y+=z[l++]<<b,b+=8),x+=y&(1<<_)-1,y>>>=_,b-=_),b<15&&(y+=z[l++]<<b,b+=8,y+=z[l++]<<b,b+=8),S=E[y&B];s:for(;;){if(_=S>>>24,y>>>=_,b-=_,_=S>>>16&255,_&16){if(m=S&65535,_&=15,b<_&&(y+=z[l++]<<b,b+=8,b<_&&(y+=z[l++]<<b,b+=8)),m+=y&(1<<_)-1,m>d){t.msg="invalid distance too far back",L.mode=St;break e}if(y>>>=_,b-=_,_=i-c,m>_){if(_=m-_,_>u&&L.sane){t.msg="invalid distance too far back",L.mode=St;break e}if(f=0,g=v,h===0){if(f+=a-_,_<x){x-=_;do $[i++]=v[f++];while(--_);f=i-m,g=$}}else if(h<_){if(f+=a+h-_,_-=h,_<x){x-=_;do $[i++]=v[f++];while(--_);if(f=0,h<x){_=h,x-=_;do $[i++]=v[f++];while(--_);f=i-m,g=$}}}else if(f+=h-_,_<x){x-=_;do $[i++]=v[f++];while(--_);f=i-m,g=$}for(;x>2;)$[i++]=g[f++],$[i++]=g[f++],$[i++]=g[f++],x-=3;x&&($[i++]=g[f++],x>1&&($[i++]=g[f++]))}else{f=i-m;do $[i++]=$[f++],$[i++]=$[f++],$[i++]=$[f++],x-=3;while(x>2);x&&($[i++]=$[f++],x>1&&($[i++]=$[f++]))}}else if(_&64){t.msg="invalid distance code",L.mode=St;break e}else{S=E[(S&65535)+(y&(1<<_)-1)];continue s}break}}else if(_&64)if(_&32){L.mode=Wl;break e}else{t.msg="invalid literal/length code",L.mode=St;break e}else{S=C[(S&65535)+(y&(1<<_)-1)];continue t}break}}while(l<n&&i<r);x=b>>3,l-=x,b-=x<<3,y&=(1<<b)-1,t.next_in=l,t.next_out=i,t.avail_in=l<n?5+(n-l):5-(l-n),t.avail_out=i<r?257+(r-i):257-(i-r),L.hold=y,L.bits=b};const He=15,zs=852,Fs=592,Ns=0,qt=1,Ps=2,Jl=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),Kl=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),Yl=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),ql=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]),Xl=(s,t,e,l,n,i,c,r)=>{const d=r.bits;let a=0,u=0,h=0,v=0,y=0,b=0,C=0,E=0,I=0,B=0,S,_,x,m,f,g=null,z;const $=new Uint16Array(He+1),L=new Uint16Array(He+1);let he=null,Ie,Ne,ie;for(a=0;a<=He;a++)$[a]=0;for(u=0;u<l;u++)$[t[e+u]]++;for(y=d,v=He;v>=1&&$[v]===0;v--);if(y>v&&(y=v),v===0)return n[i++]=1<<24|64<<16|0,n[i++]=1<<24|64<<16|0,r.bits=1,0;for(h=1;h<v&&$[h]===0;h++);for(y<h&&(y=h),E=1,a=1;a<=He;a++)if(E<<=1,E-=$[a],E<0)return-1;if(E>0&&(s===Ns||v!==1))return-1;for(L[1]=0,a=1;a<He;a++)L[a+1]=L[a]+$[a];for(u=0;u<l;u++)t[e+u]!==0&&(c[L[t[e+u]]++]=u);if(s===Ns?(g=he=c,z=20):s===qt?(g=Jl,he=Kl,z=257):(g=Yl,he=ql,z=0),B=0,u=0,a=h,f=i,b=y,C=0,x=-1,I=1<<y,m=I-1,s===qt&&I>zs||s===Ps&&I>Fs)return 1;for(;;){Ie=a-C,c[u]+1<z?(Ne=0,ie=c[u]):c[u]>=z?(Ne=he[c[u]-z],ie=g[c[u]-z]):(Ne=96,ie=0),S=1<<a-C,_=1<<b,h=_;do _-=S,n[f+(B>>C)+_]=Ie<<24|Ne<<16|ie|0;while(_!==0);for(S=1<<a-1;B&S;)S>>=1;if(S!==0?(B&=S-1,B+=S):B=0,u++,--$[a]===0){if(a===v)break;a=t[e+c[u]]}if(a>y&&(B&m)!==x){for(C===0&&(C=y),f+=h,b=a-C,E=1<<b;b+C<v&&(E-=$[b+C],!(E<=0));)b++,E<<=1;if(I+=1<<b,s===qt&&I>zs||s===Ps&&I>Fs)return 1;x=B&m,n[x]=y<<24|b<<16|f-i|0}}return B!==0&&(n[f+B]=a-C<<24|64<<16|0),r.bits=y,0};var rt=Xl;const er=0,$n=1,zn=2,{Z_FINISH:Vs,Z_BLOCK:tr,Z_TREES:At,Z_OK:ze,Z_STREAM_END:sr,Z_NEED_DICT:nr,Z_STREAM_ERROR:xe,Z_DATA_ERROR:Fn,Z_MEM_ERROR:Nn,Z_BUF_ERROR:ir,Z_DEFLATED:Hs}=Dn,Ht=16180,Gs=16181,Zs=16182,Ws=16183,Qs=16184,Js=16185,Ks=16186,Ys=16187,qs=16188,Xs=16189,Lt=16190,Se=16191,Xt=16192,en=16193,es=16194,tn=16195,sn=16196,nn=16197,on=16198,Tt=16199,Ct=16200,ln=16201,rn=16202,an=16203,cn=16204,un=16205,ts=16206,dn=16207,fn=16208,V=16209,Pn=16210,Vn=16211,or=852,lr=592,rr=15,ar=rr,hn=s=>(s>>>24&255)+(s>>>8&65280)+((s&65280)<<8)+((s&255)<<24);function cr(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const Fe=s=>{if(!s)return 1;const t=s.state;return!t||t.strm!==s||t.mode<Ht||t.mode>Vn?1:0},Hn=s=>{if(Fe(s))return xe;const t=s.state;return s.total_in=s.total_out=t.total=0,s.msg="",t.wrap&&(s.adler=t.wrap&1),t.mode=Ht,t.last=0,t.havedict=0,t.flags=-1,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Int32Array(or),t.distcode=t.distdyn=new Int32Array(lr),t.sane=1,t.back=-1,ze},Gn=s=>{if(Fe(s))return xe;const t=s.state;return t.wsize=0,t.whave=0,t.wnext=0,Hn(s)},Zn=(s,t)=>{let e;if(Fe(s))return xe;const l=s.state;return t<0?(e=0,t=-t):(e=(t>>4)+5,t<48&&(t&=15)),t&&(t<8||t>15)?xe:(l.window!==null&&l.wbits!==t&&(l.window=null),l.wrap=e,l.wbits=t,Gn(s))},Wn=(s,t)=>{if(!s)return xe;const e=new cr;s.state=e,e.strm=s,e.window=null,e.mode=Ht;const l=Zn(s,t);return l!==ze&&(s.state=null),l},ur=s=>Wn(s,ar);let vn=!0,ss,ns;const dr=s=>{if(vn){ss=new Int32Array(512),ns=new Int32Array(32);let t=0;for(;t<144;)s.lens[t++]=8;for(;t<256;)s.lens[t++]=9;for(;t<280;)s.lens[t++]=7;for(;t<288;)s.lens[t++]=8;for(rt($n,s.lens,0,288,ss,0,s.work,{bits:9}),t=0;t<32;)s.lens[t++]=5;rt(zn,s.lens,0,32,ns,0,s.work,{bits:5}),vn=!1}s.lencode=ss,s.lenbits=9,s.distcode=ns,s.distbits=5},Qn=(s,t,e,l)=>{let n;const i=s.state;return i.window===null&&(i.wsize=1<<i.wbits,i.wnext=0,i.whave=0,i.window=new Uint8Array(i.wsize)),l>=i.wsize?(i.window.set(t.subarray(e-i.wsize,e),0),i.wnext=0,i.whave=i.wsize):(n=i.wsize-i.wnext,n>l&&(n=l),i.window.set(t.subarray(e-l,e-l+n),i.wnext),l-=n,l?(i.window.set(t.subarray(e-l,e),0),i.wnext=l,i.whave=i.wsize):(i.wnext+=n,i.wnext===i.wsize&&(i.wnext=0),i.whave<i.wsize&&(i.whave+=n))),0},fr=(s,t)=>{let e,l,n,i,c,r,d,a,u,h,v,y,b,C,E=0,I,B,S,_,x,m,f,g;const z=new Uint8Array(4);let $,L;const he=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Fe(s)||!s.output||!s.input&&s.avail_in!==0)return xe;e=s.state,e.mode===Se&&(e.mode=Xt),c=s.next_out,n=s.output,d=s.avail_out,i=s.next_in,l=s.input,r=s.avail_in,a=e.hold,u=e.bits,h=r,v=d,g=ze;e:for(;;)switch(e.mode){case Ht:if(e.wrap===0){e.mode=Xt;break}for(;u<16;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(e.wrap&2&&a===35615){e.wbits===0&&(e.wbits=15),e.check=0,z[0]=a&255,z[1]=a>>>8&255,e.check=ke(e.check,z,2,0),a=0,u=0,e.mode=Gs;break}if(e.head&&(e.head.done=!1),!(e.wrap&1)||(((a&255)<<8)+(a>>8))%31){s.msg="incorrect header check",e.mode=V;break}if((a&15)!==Hs){s.msg="unknown compression method",e.mode=V;break}if(a>>>=4,u-=4,f=(a&15)+8,e.wbits===0&&(e.wbits=f),f>15||f>e.wbits){s.msg="invalid window size",e.mode=V;break}e.dmax=1<<e.wbits,e.flags=0,s.adler=e.check=1,e.mode=a&512?Xs:Se,a=0,u=0;break;case Gs:for(;u<16;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(e.flags=a,(e.flags&255)!==Hs){s.msg="unknown compression method",e.mode=V;break}if(e.flags&57344){s.msg="unknown header flags set",e.mode=V;break}e.head&&(e.head.text=a>>8&1),e.flags&512&&e.wrap&4&&(z[0]=a&255,z[1]=a>>>8&255,e.check=ke(e.check,z,2,0)),a=0,u=0,e.mode=Zs;case Zs:for(;u<32;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}e.head&&(e.head.time=a),e.flags&512&&e.wrap&4&&(z[0]=a&255,z[1]=a>>>8&255,z[2]=a>>>16&255,z[3]=a>>>24&255,e.check=ke(e.check,z,4,0)),a=0,u=0,e.mode=Ws;case Ws:for(;u<16;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}e.head&&(e.head.xflags=a&255,e.head.os=a>>8),e.flags&512&&e.wrap&4&&(z[0]=a&255,z[1]=a>>>8&255,e.check=ke(e.check,z,2,0)),a=0,u=0,e.mode=Qs;case Qs:if(e.flags&1024){for(;u<16;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}e.length=a,e.head&&(e.head.extra_len=a),e.flags&512&&e.wrap&4&&(z[0]=a&255,z[1]=a>>>8&255,e.check=ke(e.check,z,2,0)),a=0,u=0}else e.head&&(e.head.extra=null);e.mode=Js;case Js:if(e.flags&1024&&(y=e.length,y>r&&(y=r),y&&(e.head&&(f=e.head.extra_len-e.length,e.head.extra||(e.head.extra=new Uint8Array(e.head.extra_len)),e.head.extra.set(l.subarray(i,i+y),f)),e.flags&512&&e.wrap&4&&(e.check=ke(e.check,l,y,i)),r-=y,i+=y,e.length-=y),e.length))break e;e.length=0,e.mode=Ks;case Ks:if(e.flags&2048){if(r===0)break e;y=0;do f=l[i+y++],e.head&&f&&e.length<65536&&(e.head.name+=String.fromCharCode(f));while(f&&y<r);if(e.flags&512&&e.wrap&4&&(e.check=ke(e.check,l,y,i)),r-=y,i+=y,f)break e}else e.head&&(e.head.name=null);e.length=0,e.mode=Ys;case Ys:if(e.flags&4096){if(r===0)break e;y=0;do f=l[i+y++],e.head&&f&&e.length<65536&&(e.head.comment+=String.fromCharCode(f));while(f&&y<r);if(e.flags&512&&e.wrap&4&&(e.check=ke(e.check,l,y,i)),r-=y,i+=y,f)break e}else e.head&&(e.head.comment=null);e.mode=qs;case qs:if(e.flags&512){for(;u<16;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(e.wrap&4&&a!==(e.check&65535)){s.msg="header crc mismatch",e.mode=V;break}a=0,u=0}e.head&&(e.head.hcrc=e.flags>>9&1,e.head.done=!0),s.adler=e.check=0,e.mode=Se;break;case Xs:for(;u<32;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}s.adler=e.check=hn(a),a=0,u=0,e.mode=Lt;case Lt:if(e.havedict===0)return s.next_out=c,s.avail_out=d,s.next_in=i,s.avail_in=r,e.hold=a,e.bits=u,nr;s.adler=e.check=1,e.mode=Se;case Se:if(t===tr||t===At)break e;case Xt:if(e.last){a>>>=u&7,u-=u&7,e.mode=ts;break}for(;u<3;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}switch(e.last=a&1,a>>>=1,u-=1,a&3){case 0:e.mode=en;break;case 1:if(dr(e),e.mode=Tt,t===At){a>>>=2,u-=2;break e}break;case 2:e.mode=sn;break;case 3:s.msg="invalid block type",e.mode=V}a>>>=2,u-=2;break;case en:for(a>>>=u&7,u-=u&7;u<32;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if((a&65535)!==(a>>>16^65535)){s.msg="invalid stored block lengths",e.mode=V;break}if(e.length=a&65535,a=0,u=0,e.mode=es,t===At)break e;case es:e.mode=tn;case tn:if(y=e.length,y){if(y>r&&(y=r),y>d&&(y=d),y===0)break e;n.set(l.subarray(i,i+y),c),r-=y,i+=y,d-=y,c+=y,e.length-=y;break}e.mode=Se;break;case sn:for(;u<14;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(e.nlen=(a&31)+257,a>>>=5,u-=5,e.ndist=(a&31)+1,a>>>=5,u-=5,e.ncode=(a&15)+4,a>>>=4,u-=4,e.nlen>286||e.ndist>30){s.msg="too many length or distance symbols",e.mode=V;break}e.have=0,e.mode=nn;case nn:for(;e.have<e.ncode;){for(;u<3;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}e.lens[he[e.have++]]=a&7,a>>>=3,u-=3}for(;e.have<19;)e.lens[he[e.have++]]=0;if(e.lencode=e.lendyn,e.lenbits=7,$={bits:e.lenbits},g=rt(er,e.lens,0,19,e.lencode,0,e.work,$),e.lenbits=$.bits,g){s.msg="invalid code lengths set",e.mode=V;break}e.have=0,e.mode=on;case on:for(;e.have<e.nlen+e.ndist;){for(;E=e.lencode[a&(1<<e.lenbits)-1],I=E>>>24,B=E>>>16&255,S=E&65535,!(I<=u);){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(S<16)a>>>=I,u-=I,e.lens[e.have++]=S;else{if(S===16){for(L=I+2;u<L;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(a>>>=I,u-=I,e.have===0){s.msg="invalid bit length repeat",e.mode=V;break}f=e.lens[e.have-1],y=3+(a&3),a>>>=2,u-=2}else if(S===17){for(L=I+3;u<L;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}a>>>=I,u-=I,f=0,y=3+(a&7),a>>>=3,u-=3}else{for(L=I+7;u<L;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}a>>>=I,u-=I,f=0,y=11+(a&127),a>>>=7,u-=7}if(e.have+y>e.nlen+e.ndist){s.msg="invalid bit length repeat",e.mode=V;break}for(;y--;)e.lens[e.have++]=f}}if(e.mode===V)break;if(e.lens[256]===0){s.msg="invalid code -- missing end-of-block",e.mode=V;break}if(e.lenbits=9,$={bits:e.lenbits},g=rt($n,e.lens,0,e.nlen,e.lencode,0,e.work,$),e.lenbits=$.bits,g){s.msg="invalid literal/lengths set",e.mode=V;break}if(e.distbits=6,e.distcode=e.distdyn,$={bits:e.distbits},g=rt(zn,e.lens,e.nlen,e.ndist,e.distcode,0,e.work,$),e.distbits=$.bits,g){s.msg="invalid distances set",e.mode=V;break}if(e.mode=Tt,t===At)break e;case Tt:e.mode=Ct;case Ct:if(r>=6&&d>=258){s.next_out=c,s.avail_out=d,s.next_in=i,s.avail_in=r,e.hold=a,e.bits=u,Ql(s,v),c=s.next_out,n=s.output,d=s.avail_out,i=s.next_in,l=s.input,r=s.avail_in,a=e.hold,u=e.bits,e.mode===Se&&(e.back=-1);break}for(e.back=0;E=e.lencode[a&(1<<e.lenbits)-1],I=E>>>24,B=E>>>16&255,S=E&65535,!(I<=u);){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(B&&!(B&240)){for(_=I,x=B,m=S;E=e.lencode[m+((a&(1<<_+x)-1)>>_)],I=E>>>24,B=E>>>16&255,S=E&65535,!(_+I<=u);){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}a>>>=_,u-=_,e.back+=_}if(a>>>=I,u-=I,e.back+=I,e.length=S,B===0){e.mode=un;break}if(B&32){e.back=-1,e.mode=Se;break}if(B&64){s.msg="invalid literal/length code",e.mode=V;break}e.extra=B&15,e.mode=ln;case ln:if(e.extra){for(L=e.extra;u<L;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}e.length+=a&(1<<e.extra)-1,a>>>=e.extra,u-=e.extra,e.back+=e.extra}e.was=e.length,e.mode=rn;case rn:for(;E=e.distcode[a&(1<<e.distbits)-1],I=E>>>24,B=E>>>16&255,S=E&65535,!(I<=u);){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(!(B&240)){for(_=I,x=B,m=S;E=e.distcode[m+((a&(1<<_+x)-1)>>_)],I=E>>>24,B=E>>>16&255,S=E&65535,!(_+I<=u);){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}a>>>=_,u-=_,e.back+=_}if(a>>>=I,u-=I,e.back+=I,B&64){s.msg="invalid distance code",e.mode=V;break}e.offset=S,e.extra=B&15,e.mode=an;case an:if(e.extra){for(L=e.extra;u<L;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}e.offset+=a&(1<<e.extra)-1,a>>>=e.extra,u-=e.extra,e.back+=e.extra}if(e.offset>e.dmax){s.msg="invalid distance too far back",e.mode=V;break}e.mode=cn;case cn:if(d===0)break e;if(y=v-d,e.offset>y){if(y=e.offset-y,y>e.whave&&e.sane){s.msg="invalid distance too far back",e.mode=V;break}y>e.wnext?(y-=e.wnext,b=e.wsize-y):b=e.wnext-y,y>e.length&&(y=e.length),C=e.window}else C=n,b=c-e.offset,y=e.length;y>d&&(y=d),d-=y,e.length-=y;do n[c++]=C[b++];while(--y);e.length===0&&(e.mode=Ct);break;case un:if(d===0)break e;n[c++]=e.length,d--,e.mode=Ct;break;case ts:if(e.wrap){for(;u<32;){if(r===0)break e;r--,a|=l[i++]<<u,u+=8}if(v-=d,s.total_out+=v,e.total+=v,e.wrap&4&&v&&(s.adler=e.check=e.flags?ke(e.check,n,v,c-v):ds(e.check,n,v,c-v)),v=d,e.wrap&4&&(e.flags?a:hn(a))!==e.check){s.msg="incorrect data check",e.mode=V;break}a=0,u=0}e.mode=dn;case dn:if(e.wrap&&e.flags){for(;u<32;){if(r===0)break e;r--,a+=l[i++]<<u,u+=8}if(e.wrap&4&&a!==(e.total&4294967295)){s.msg="incorrect length check",e.mode=V;break}a=0,u=0}e.mode=fn;case fn:g=sr;break e;case V:g=Fn;break e;case Pn:return Nn;case Vn:default:return xe}return s.next_out=c,s.avail_out=d,s.next_in=i,s.avail_in=r,e.hold=a,e.bits=u,(e.wsize||v!==s.avail_out&&e.mode<V&&(e.mode<ts||t!==Vs))&&Qn(s,s.output,s.next_out,v-s.avail_out),h-=s.avail_in,v-=s.avail_out,s.total_in+=h,s.total_out+=v,e.total+=v,e.wrap&4&&v&&(s.adler=e.check=e.flags?ke(e.check,n,v,s.next_out-v):ds(e.check,n,v,s.next_out-v)),s.data_type=e.bits+(e.last?64:0)+(e.mode===Se?128:0)+(e.mode===Tt||e.mode===es?256:0),(h===0&&v===0||t===Vs)&&g===ze&&(g=ir),g},hr=s=>{if(Fe(s))return xe;let t=s.state;return t.window&&(t.window=null),s.state=null,ze},vr=(s,t)=>{if(Fe(s))return xe;const e=s.state;return e.wrap&2?(e.head=t,t.done=!1,ze):xe},pr=(s,t)=>{const e=t.length;let l,n,i;return Fe(s)||(l=s.state,l.wrap!==0&&l.mode!==Lt)?xe:l.mode===Lt&&(n=1,n=ds(n,t,e,0),n!==l.check)?Fn:(i=Qn(s,t,e,e),i?(l.mode=Pn,Nn):(l.havedict=1,ze))};var mr=Gn,gr=Zn,wr=Hn,yr=ur,xr=Wn,kr=fr,_r=hr,br=vr,Sr=pr,Ar="pako inflate (from Nodeca project)",Ae={inflateReset:mr,inflateReset2:gr,inflateResetKeep:wr,inflateInit:yr,inflateInit2:xr,inflate:kr,inflateEnd:_r,inflateGetHeader:br,inflateSetDictionary:Sr,inflateInfo:Ar};function Tr(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var Cr=Tr;const Jn=Object.prototype.toString,{Z_NO_FLUSH:Ir,Z_FINISH:Er,Z_OK:dt,Z_STREAM_END:is,Z_NEED_DICT:os,Z_STREAM_ERROR:Mr,Z_DATA_ERROR:pn,Z_MEM_ERROR:Or}=Dn;function Gt(s){this.options=Un.assign({chunkSize:1024*64,windowBits:15,to:""},s||{});const t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,t.windowBits===0&&(t.windowBits=-15)),t.windowBits>=0&&t.windowBits<16&&!(s&&s.windowBits)&&(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&(t.windowBits&15||(t.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Zl,this.strm.avail_out=0;let e=Ae.inflateInit2(this.strm,t.windowBits);if(e!==dt)throw new Error(fs[e]);if(this.header=new Cr,Ae.inflateGetHeader(this.strm,this.header),t.dictionary&&(typeof t.dictionary=="string"?t.dictionary=hs.string2buf(t.dictionary):Jn.call(t.dictionary)==="[object ArrayBuffer]"&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(e=Ae.inflateSetDictionary(this.strm,t.dictionary),e!==dt)))throw new Error(fs[e])}Gt.prototype.push=function(s,t){const e=this.strm,l=this.options.chunkSize,n=this.options.dictionary;let i,c,r;if(this.ended)return!1;for(t===~~t?c=t:c=t===!0?Er:Ir,Jn.call(s)==="[object ArrayBuffer]"?e.input=new Uint8Array(s):e.input=s,e.next_in=0,e.avail_in=e.input.length;;){for(e.avail_out===0&&(e.output=new Uint8Array(l),e.next_out=0,e.avail_out=l),i=Ae.inflate(e,c),i===os&&n&&(i=Ae.inflateSetDictionary(e,n),i===dt?i=Ae.inflate(e,c):i===pn&&(i=os));e.avail_in>0&&i===is&&e.state.wrap>0&&s[e.next_in]!==0;)Ae.inflateReset(e),i=Ae.inflate(e,c);switch(i){case Mr:case pn:case os:case Or:return this.onEnd(i),this.ended=!0,!1}if(r=e.avail_out,e.next_out&&(e.avail_out===0||i===is))if(this.options.to==="string"){let d=hs.utf8border(e.output,e.next_out),a=e.next_out-d,u=hs.buf2string(e.output,d);e.next_out=a,e.avail_out=l-a,a&&e.output.set(e.output.subarray(d,d+a),0),this.onData(u)}else this.onData(e.output.length===e.next_out?e.output:e.output.subarray(0,e.next_out));if(!(i===dt&&r===0)){if(i===is)return i=Ae.inflateEnd(this.strm),this.onEnd(i),this.ended=!0,!0;if(e.avail_in===0)break}}return!0};Gt.prototype.onData=function(s){this.chunks.push(s)};Gt.prototype.onEnd=function(s){s===dt&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Un.flattenChunks(this.chunks)),this.chunks=[],this.err=s,this.msg=this.strm.msg};function Rr(s,t){const e=new Gt(t);if(e.push(s),e.err)throw e.msg||fs[e.err];return e.result}var Br=Rr,Lr={ungzip:Br};const{ungzip:Dr}=Lr;var Ur=Dr;function jr(s){return $r(ws(s))}function $r(s){let t={};e:for(;!qe(s);){let e=q(s);switch(e>>>3){case 0:break e;case 1:{let l=gs(s);(t.messagesList||(t.messagesList=[])).push(zr(s)),s.limit=l;break}case 8:{t.heartbeatDuration=Me(s,!0);break}case 9:{t.needAck=!!de(s);break}default:Ye(s,e&7)}}return t}function zr(s){let t={};e:for(;!qe(s);){let e=q(s);switch(e>>>3){case 0:break e;case 1:{t.method=Re(s,q(s));break}case 2:{t.payload=qn(s,q(s));break}case 3:{t.msgId=Me(s,!1);break}case 4:{t.msgType=q(s);break}case 5:{t.offset=Me(s,!1);break}case 6:{t.needWrdsStore=!!de(s);break}case 7:{t.wrdsVersion=Me(s,!1);break}case 8:{t.wrdsSubKey=Re(s,q(s));break}default:Ye(s,e&7)}}return t}function Fr(s){return Nr(ws(s))}function Nr(s){let t={};e:for(;!qe(s);){let e=q(s);switch(e>>>3){case 0:break e;case 2:{let l=gs(s);t.user=Pr(s),s.limit=l;break}case 3:{t.content=Re(s,q(s));break}default:Ye(s,e&7)}}return t}function Pr(s){let t={};e:for(;!qe(s);){let e=q(s);switch(e>>>3){case 0:break e;case 3:{t.nickName=Re(s,q(s));break}default:Ye(s,e&7)}}return t}function Vr(s){let t=Yn();return Hr(s,t),qr(t)}function Hr(s,t){let e=s.seqId;e!==void 0&&(me(t,8),It(t,e));let l=s.logId;l!==void 0&&(me(t,16),It(t,l));let n=s.service;n!==void 0&&(me(t,24),It(t,n));let i=s.method;i!==void 0&&(me(t,32),It(t,i));let c=s.headersList;if(c!==void 0)for(let u of c){me(t,42);let h=Yn();Wr(u,h),me(t,h.limit),ea(t,h),Yr(h)}let r=s.payloadEncoding;r!==void 0&&(me(t,50),Dt(t,r));let d=s.payloadType;d!==void 0&&(me(t,58),Dt(t,d));let a=s.payload;a!==void 0&&(me(t,66),me(t,a.length),Xr(t,a))}function Gr(s){return Zr(ws(s))}function Zr(s){let t={};e:for(;!qe(s);){let e=q(s);switch(e>>>3){case 0:break e;case 1:{t.seqId=Me(s,!0);break}case 2:{t.logId=Me(s,!0);break}case 3:{t.service=Me(s,!0);break}case 4:{t.method=Me(s,!0);break}case 5:{let l=gs(s);(t.headersList||(t.headersList=[])).push(Qr(s)),s.limit=l;break}case 6:{t.payloadEncoding=Re(s,q(s));break}case 7:{t.payloadType=Re(s,q(s));break}case 8:{t.payload=qn(s,q(s));break}default:Ye(s,e&7)}}return t}function Wr(s,t){let e=s.key;e!==void 0&&(me(t,10),Dt(t,e));let l=s.value;l!==void 0&&(me(t,18),Dt(t,l))}function Qr(s){let t={};e:for(;!qe(s);){let e=q(s);switch(e>>>3){case 0:break e;case 1:{t.key=Re(s,q(s));break}case 2:{t.value=Re(s,q(s));break}default:Ye(s,e&7)}}return t}function gs(s){let t=q(s),e=s.limit;return s.limit=s.offset+t,e}function Ye(s,t){switch(t){case 0:for(;de(s)&128;);break;case 2:ls(s,q(s));break;case 5:ls(s,4);break;case 1:ls(s,8);break;default:throw new Error("Unimplemented type: "+t)}}let Jr=new Float32Array(1);new Uint8Array(Jr.buffer);let Kr=new Float64Array(1);new Uint8Array(Kr.buffer);let Kn=[];function Yn(){const s=Kn.pop();return s?(s.offset=s.limit=0,s):{bytes:new Uint8Array(64),offset:0,limit:0}}function Yr(s){Kn.push(s)}function ws(s){return{bytes:s,offset:0,limit:s.length}}function qr(s){let t=s.bytes,e=s.limit;return t.length===e?t:t.subarray(0,e)}function ls(s,t){if(s.offset+t>s.limit)throw new Error("Skip past limit");s.offset+=t}function qe(s){return s.offset>=s.limit}function pt(s,t){let e=s.bytes,l=s.offset,n=s.limit,i=l+t;if(i>e.length){let c=new Uint8Array(i*2);c.set(e),s.bytes=c}return s.offset=i,i>n&&(s.limit=i),l}function ys(s,t){let e=s.offset;if(e+t>s.limit)throw new Error("Read past limit");return s.offset+=t,e}function qn(s,t){let e=ys(s,t);return s.bytes.subarray(e,e+t)}function Xr(s,t){let e=pt(s,t.length);s.bytes.set(t,e)}function Re(s,t){let e=ys(s,t),l=String.fromCharCode,n=s.bytes,i="�",c="";for(let r=0;r<t;r++){let d=n[r+e],a,u,h,v;d&128?(d&224)===192?r+1>=t?c+=i:(a=n[r+e+1],(a&192)!==128?c+=i:(v=(d&31)<<6|a&63,v<128?c+=i:(c+=l(v),r++))):(d&240)==224?r+2>=t?c+=i:(a=n[r+e+1],u=n[r+e+2],((a|u<<8)&49344)!==32896?c+=i:(v=(d&15)<<12|(a&63)<<6|u&63,v<2048||v>=55296&&v<=57343?c+=i:(c+=l(v),r+=2))):(d&248)==240?r+3>=t?c+=i:(a=n[r+e+1],u=n[r+e+2],h=n[r+e+3],((a|u<<8|h<<16)&12632256)!==8421504?c+=i:(v=(d&7)<<18|(a&63)<<12|(u&63)<<6|h&63,v<65536||v>1114111?c+=i:(v-=65536,c+=l((v>>10)+55296,(v&1023)+56320),r+=3))):c+=i:c+=l(d)}return c}function Dt(s,t){let e=t.length,l=0;for(let c=0;c<e;c++){let r=t.charCodeAt(c);r>=55296&&r<=56319&&c+1<e&&(r=(r<<10)+t.charCodeAt(++c)-56613888),l+=r<128?1:r<2048?2:r<65536?3:4}me(s,l);let n=pt(s,l),i=s.bytes;for(let c=0;c<e;c++){let r=t.charCodeAt(c);r>=55296&&r<=56319&&c+1<e&&(r=(r<<10)+t.charCodeAt(++c)-56613888),r<128?i[n++]=r:(r<2048?i[n++]=r>>6&31|192:(r<65536?i[n++]=r>>12&15|224:(i[n++]=r>>18&7|240,i[n++]=r>>12&63|128),i[n++]=r>>6&63|128),i[n++]=r&63|128)}}function ea(s,t){let e=pt(s,t.limit),l=s.bytes,n=t.bytes;for(let i=0,c=t.limit;i<c;i++)l[i+e]=n[i]}function de(s){return s.bytes[ys(s,1)]}function mn(s,t){let e=pt(s,1);s.bytes[e]=t}function q(s){let t=0,e=0,l;do l=de(s),t<32&&(e|=(l&127)<<t),t+=7;while(l&128);return e}function me(s,t){for(t>>>=0;t>=128;)mn(s,t&127|128),t>>>=7;mn(s,t)}function Me(s,t){let e=0,l=0,n=0,i;return i=de(s),e=i&127,i&128&&(i=de(s),e|=(i&127)<<7,i&128&&(i=de(s),e|=(i&127)<<14,i&128&&(i=de(s),e|=(i&127)<<21,i&128&&(i=de(s),l=i&127,i&128&&(i=de(s),l|=(i&127)<<7,i&128&&(i=de(s),l|=(i&127)<<14,i&128&&(i=de(s),l|=(i&127)<<21,i&128&&(i=de(s),n=i&127,i&128&&(i=de(s),n|=(i&127)<<7))))))))),{low:e|l<<28,high:l>>>4|n<<24,unsigned:t}}function It(s,t){let e=t.low>>>0,l=(t.low>>>28|t.high<<4)>>>0,n=t.high>>>24,i=n===0?l===0?e<16384?e<128?1:2:e<1<<21?3:4:l<16384?l<128?5:6:l<1<<21?7:8:n<128?9:10,c=pt(s,i),r=s.bytes;switch(i){case 10:r[c+9]=n>>>7&1;case 9:r[c+8]=i!==9?n|128:n&127;case 8:r[c+7]=i!==8?l>>>21|128:l>>>21&127;case 7:r[c+6]=i!==7?l>>>14|128:l>>>14&127;case 6:r[c+5]=i!==6?l>>>7|128:l>>>7&127;case 5:r[c+4]=i!==5?l|128:l&127;case 4:r[c+3]=i!==4?e>>>21|128:e>>>21&127;case 3:r[c+2]=i!==3?e>>>14|128:e>>>14&127;case 2:r[c+1]=i!==2?e>>>7|128:e>>>7&127;case 1:r[c]=i!==1?e|128:e&127}}var ta=function(s,t){s.constructor==String?s=la(s):o(s)?s=Array.prototype.slice.call(s,0):Array.isArray(s)||s.constructor===Uint8Array||(s=s.toString());for(var e=ra(s),l=8*s.length,n=1732584193,i=-271733879,c=-1732584194,r=271733878,d=0;d<e.length;d++)e[d]=(e[d]<<8|e[d]>>>24)&16711935|(e[d]<<24|e[d]>>>8)&4278255360;e[l>>>5]|=128<<l%32,e[(l+64>>>9<<4)+14]=l;for(var a=sa,u=na,h=ia,v=oa,d=0;d<e.length;d+=16){var y=n,b=i,C=c,E=r;n=a(n,i,c,r,e[d+0],7,-680876936),r=a(r,n,i,c,e[d+1],12,-389564586),c=a(c,r,n,i,e[d+2],17,606105819),i=a(i,c,r,n,e[d+3],22,-1044525330),n=a(n,i,c,r,e[d+4],7,-176418897),r=a(r,n,i,c,e[d+5],12,1200080426),c=a(c,r,n,i,e[d+6],17,-1473231341),i=a(i,c,r,n,e[d+7],22,-45705983),n=a(n,i,c,r,e[d+8],7,1770035416),r=a(r,n,i,c,e[d+9],12,-1958414417),c=a(c,r,n,i,e[d+10],17,-42063),i=a(i,c,r,n,e[d+11],22,-1990404162),n=a(n,i,c,r,e[d+12],7,1804603682),r=a(r,n,i,c,e[d+13],12,-40341101),c=a(c,r,n,i,e[d+14],17,-1502002290),i=a(i,c,r,n,e[d+15],22,1236535329),n=u(n,i,c,r,e[d+1],5,-165796510),r=u(r,n,i,c,e[d+6],9,-1069501632),c=u(c,r,n,i,e[d+11],14,643717713),i=u(i,c,r,n,e[d+0],20,-373897302),n=u(n,i,c,r,e[d+5],5,-701558691),r=u(r,n,i,c,e[d+10],9,38016083),c=u(c,r,n,i,e[d+15],14,-660478335),i=u(i,c,r,n,e[d+4],20,-405537848),n=u(n,i,c,r,e[d+9],5,568446438),r=u(r,n,i,c,e[d+14],9,-1019803690),c=u(c,r,n,i,e[d+3],14,-187363961),i=u(i,c,r,n,e[d+8],20,1163531501),n=u(n,i,c,r,e[d+13],5,-1444681467),r=u(r,n,i,c,e[d+2],9,-51403784),c=u(c,r,n,i,e[d+7],14,1735328473),i=u(i,c,r,n,e[d+12],20,-1926607734),n=h(n,i,c,r,e[d+5],4,-378558),r=h(r,n,i,c,e[d+8],11,-2022574463),c=h(c,r,n,i,e[d+11],16,1839030562),i=h(i,c,r,n,e[d+14],23,-35309556),n=h(n,i,c,r,e[d+1],4,-1530992060),r=h(r,n,i,c,e[d+4],11,1272893353),c=h(c,r,n,i,e[d+7],16,-155497632),i=h(i,c,r,n,e[d+10],23,-1094730640),n=h(n,i,c,r,e[d+13],4,681279174),r=h(r,n,i,c,e[d+0],11,-358537222),c=h(c,r,n,i,e[d+3],16,-722521979),i=h(i,c,r,n,e[d+6],23,76029189),n=h(n,i,c,r,e[d+9],4,-640364487),r=h(r,n,i,c,e[d+12],11,-421815835),c=h(c,r,n,i,e[d+15],16,530742520),i=h(i,c,r,n,e[d+2],23,-995338651),n=v(n,i,c,r,e[d+0],6,-198630844),r=v(r,n,i,c,e[d+7],10,1126891415),c=v(c,r,n,i,e[d+14],15,-1416354905),i=v(i,c,r,n,e[d+5],21,-57434055),n=v(n,i,c,r,e[d+12],6,1700485571),r=v(r,n,i,c,e[d+3],10,-1894986606),c=v(c,r,n,i,e[d+10],15,-1051523),i=v(i,c,r,n,e[d+1],21,-2054922799),n=v(n,i,c,r,e[d+8],6,1873313359),r=v(r,n,i,c,e[d+15],10,-30611744),c=v(c,r,n,i,e[d+6],15,-1560198380),i=v(i,c,r,n,e[d+13],21,1309151649),n=v(n,i,c,r,e[d+4],6,-145523070),r=v(r,n,i,c,e[d+11],10,-1120210379),c=v(c,r,n,i,e[d+2],15,718787259),i=v(i,c,r,n,e[d+9],21,-343485551),n=n+y>>>0,i=i+b>>>0,c=c+C>>>0,r=r+E>>>0}return Xn([n,i,c,r])};const sa=function(s,t,e,l,n,i,c){var r=s+(t&e|~t&l)+(n>>>0)+c;return(r<<i|r>>>32-i)+t},na=function(s,t,e,l,n,i,c){var r=s+(t&l|e&~l)+(n>>>0)+c;return(r<<i|r>>>32-i)+t},ia=function(s,t,e,l,n,i,c){var r=s+(t^e^l)+(n>>>0)+c;return(r<<i|r>>>32-i)+t},oa=function(s,t,e,l,n,i,c){var r=s+(e^(t|~l))+(n>>>0)+c;return(r<<i|r>>>32-i)+t},la=function(s){for(var t=[],e=0;e<s.length;e++)t.push(255&s.charCodeAt(e));return t},ra=function(s){for(var t=[],e=0,l=0;e<s.length;e++,l+=8)t[l>>>5]|=s[e]<<24-l%32;return t},aa=function(s){for(var t=[],e=0;e<32*s.length;e+=8)t.push(s[e>>>5]>>>24-e%32&255);return t},Xn=function(s){if(s.constructor==Number)return 16711935&gn(s,8)|4278255360&gn(s,24);for(var t=0;t<s.length;t++)s[t]=Xn(s[t]);return s},gn=function(s,t){return s<<t|s>>>32-t},ca=function(s){for(var t=[],e=0;e<s.length;e++)t.push((s[e]>>>4).toString(16)),t.push((15&s[e]).toString(16));return t.join("")},ua=(s,t)=>{const l=`,live_id=1,aid=6383,version_code=180800,webcast_sdk_version=1.0.14-beta.0,room_id=${s},sub_room_id=,sub_channel_id=,did_rule=3,user_unique_id=${t},device_platform=web,device_type=,ac=,identity=audience`.substring(1),n=ta(l),i=aa(n),c=ca(i);return window.byted_acrawler.frontierSign({"X-MS-STUB":c})["X-Bogus"]},da=(s,t)=>{const e=U();let l,n=new ResizeObserver(i=>{clearTimeout(l),l=setTimeout(()=>{e.value.resize()},500)});return Je(()=>{n.observe(s.value),t.canvas=s.value,e.value=new fa(t)}),jt(()=>{n.unobserve(s.value),clearTimeout(l)}),e};class fa{constructor(t){Y(this,"canvas");Y(this,"colors");Y(this,"ctx");Y(this,"isdraw");Y(this,"lines");Y(this,"textList");Y(this,"fontSize");Y(this,"font");Y(this,"rows");Y(this,"gap");Y(this,"speed");Y(this,"opacity");Y(this,"opacityStr");this.isdraw=!1,this.textList=[],this.canvas=t.canvas,this.ctx=this.canvas.getContext("2d"),this.speed=t.speed||2,this.setFont(t.fontSize||16),this.setGap(t.gap||8),this.setRows(t.rows||4),this.setOpacity(t.opacity||100),this.setColors(t.colors||["FFFFFF","#00FF80","#00FFFF","#FF00FF","#8000FF","#FF9933"]),this.resize()}resize(){this.canvas.width=this.canvas.getBoundingClientRect().width*window.devicePixelRatio,this.canvas.height=this.canvas.getBoundingClientRect().height*window.devicePixelRatio,this.initRows()}setOpacity(t){this.opacity=t;const e=Math.floor(2.55*t).toString(16);this.opacityStr=e.length==1?"0"+e:e}setRows(t){this.rows=t}setSpeed(t){this.speed=t}setFont(t){this.ctx.textBaseline="top",this.fontSize=t,this.font=`${t}px sans-serif`}setGap(t){this.gap=t}setColors(t){this.colors=t}clean(){this.textList=[],this.isdraw=!1}destory(){this.lines=[],this.clean()}add(t){const e=this.getLine();if(e==-1)return;const l=Math.ceil(this.ctx.measureText(t).width),n=this.canvas.width+l;this.lines[e].width=n,this.textList.push({value:t,width:l,line:e,left:this.canvas.width,color:this.colors[Math.floor(Math.random()*this.colors.length)]}),!this.isdraw&&(this.isdraw=!0,this.draw())}getLine(){let t=-1,e=this.lines.length;for(;++t<e;)if(this.lines[t].width==this.canvas.width)return t;return-1}initRows(){this.lines=[];let t=-1;const e=this.gap+this.fontSize;for(;++t<this.rows;)this.lines.push({top:this.gap+e*t,width:this.canvas.width})}draw(){this.ctx.textBaseline="top",this.ctx.font=this.font,this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height);let t=-1,e=this.textList.length;const l=[];for(;++t<e;){const n=this.textList[t],i=n.left+n.width;if(i<=0)continue;this.ctx.fillStyle=n.color+this.opacityStr;const c=this.lines[n.line];c&&(this.ctx.fillText(n.value,n.left,this.lines[n.line].top),n.left-=this.speed,l.push(n),c.width=Math.max(i,this.canvas.width))}this.textList=l,l.length==0?this.isdraw=!1:requestAnimationFrame(this.draw.bind(this))}}const ha={class:"w-full h-full flex flex-col lg:flex-row box-border md:pb-2"},va={class:"lg:grow-5 flex flex-col"},pa={class:"flex p-2 pt-1 gap-2 text-lg md:pr-3"},ma={class:"hover:text-amber grow w-25 box-border text-center truncate text-4 md:text-5 m-0 pr-6 sm:pr-2 lg:pr-0"},ga={class:"aspect-ratio-video"},wa={class:"w-full h-full pos-absolute top-0 z-1 flex justify-center items-center text-6"},ya=["src"],xa={key:0},ka={class:"flex items-center gap-4 p-1"},_a={class:"flex items-center gap-4 p-1"},ba={key:1,class:"h-0 w-0"},Sa={class:"grow min-h-50 lg:grow-0 lg:w-80 xl:w-100 flex flex-col lg:pr-0 pt-3 lg-pt-12 lg:ml-3 box-border lg:b-l-solid b lg:b-l-gray-7 lg:pl-3"},Aa={class:"flex items-center line-height-none gap-4 b b-y-solid py-3 b-gray-7 px-4"},Ta=["src"],Ca={class:"grow-1 w-20"},Ia={class:"h-4 truncate"},Ea={class:"h-4 flex text-3 items-center gap-1"},Ma=["src"],Oa={class:"pos-absolute top-0 right-4 text-4 flex flex-col gap-3"},Ra=["src"],Ba=["href"],La=["data-id","data-site","href"],Da={class:"flex items-center gap-2"},Ua={class:"w-5 h-5 rounded-5",alt:""},ja=["onClick"],$a={class:"flex flex-col b b-solid b-gray-6 rounded-2 px-2"},za={class:"flex justify-between items-center mx-2 py-2"},Fa={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Na={class:"flex justify-between items-center mx-2 py-2"},Pa={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Va={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Ha={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Ga={class:"flex flex-col b b-solid b-gray-6 rounded-2 px-2"},Za={class:"flex justify-between items-center mx-2 py-2"},Wa={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Qa={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Ja={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Ka={class:"flex flex-wrap shadow blur bg-dark p-2 box-border b b-solid b-gray-7 rounded",style:{"box-shadow":"0 6px 15px 0 rgba(0, 0, 0, .5)"}},Ya=["data-color"],qa={class:"p-3 flex justify-between items-center"},Xa=X({__name:"play",setup(s){let t,e,l;const n=Te({follow:!1,qn:0,line:0,notice:null,paused:!0,muted:!1,fullscreen:!1,webscreen:!1,showController:!0,pictureInPicture:!1}),i=ps(),c=U(),r=U(),d=U(),a=_i(),u=J(()=>{var A,w;return a.value&&((w=(A=a.value)==null?void 0:A.stream)==null?void 0:w.length)>0?a.value.stream.map(j=>j.name):[]}),h=J(()=>u.value.length>0?a.value.stream[n.qn].lines.map(A=>A.name):[]),v=J(()=>h.value.length>0?a.value.stream[n.qn].lines[n.line].url:""),y=J(()=>Z.map(A=>Object.values(A.follows)).flat().sort(A=>A.status?-1:0)),b=J(()=>{var A;return((A=a.value)==null?void 0:A.siteId)=="bilibili"?"hls":"flv"});let C;const E=J(()=>{var A;return((A=a.value)==null?void 0:A.siteId)=="huya"&&(["一起看","星秀","原创"].includes(a.value.category)||a.value.info.name.endsWith("-imgplus"))}),I=()=>{E.value&&(C=setInterval(()=>{const A=Bs(a.value.info);n.flv.switchURL(v.value+A,!0)},11e4))};ve(v,()=>{var A,w;if(clearInterval(C),!!v.value){if(b.value=="flv"){const j=a.value.siteId=="huya"?v.value+Bs(a.value.info):v.value;if(n.flv)return(A=n.flv)==null||A.switchURL(j,!0),I();if(_t!=null&&_t.isSupported("video")){const F=new _t({media:r.value,seamlesslyReload:!0,isLive:!0,retryCount:0});return F.load(j),n.flv=F,I()}}if(n.hls)return(w=n.hls)==null?void 0:w.loadSource(v.value);if(bt!=null&&bt.isSupported()){const j=new bt;return j.attachMedia(r.value),j.loadSource(v.value),n.hls=j}return n.notice="播放失败",clearTimeout(e)}}),ve(b,()=>{var A,w;if(b.value=="flv"){(A=n.hls)==null||A.destroy(),n.hls=void 0;return}(w=n.flv)==null||w.destroy(),n.flv=void 0});const B=()=>{d.value.scrollTop=0,he=0,d.value.innerHTML=""};let S,_=0,x=!0;const m=U(),f=da(m,{gap:M.canvasGap,rows:M.canvasRows,speed:M.canvasSpeed,opacity:M.canvasOpacity,colors:M.canvasColorOpen?M.colors:["#ffffff"]}),g=[];let z;function $(){z||(z=setTimeout(()=>{let A=-1;const w=g.length>5?5:g.length;for(d.value.style.display="none";++A<w;)d.value.appendChild(g[A]);d.value.style.display="block",g.splice(0,5),x&&(d.value.scrollTop=d.value.scrollHeight),z=void 0},200))}const L=(A,w)=>{var Ue;if(_++,M.blockOpen&&Us.value.length&&Us.value.some(et=>et.test(w))||(_%(M.sideClean||100)==0&&(d.value.innerHTML="",he=0),M.canvasOpen&&((Ue=f.value)==null||Ue.add(w)),!Ge.value||!M.sideOpen))return;const j=document.createElement("div"),{sideColorOpen:F,sideFontsize:W,sideGap:ee,colors:we}=M;j.style.margin=`${ee}px 0`,j.style.fontSize=`${W}px`,F&&(j.style.color=we[Math.floor(Math.random()*we.length)]);const De=document.createElement("span");De.style.opacity="0.5",De.appendChild(document.createTextNode(A+":"));const Pe=document.createElement("span");Pe.appendChild(document.createTextNode(w)),j.appendChild(De),j.appendChild(Pe),g.push(j),$()};let he=0;const Ie=()=>{if(d.value.scrollTop>=he)return he=d.value.scrollTop;he=d.value.scrollTop,x=!1,d.value.removeEventListener("scroll",Ie)},Ne=()=>{x=!0,d.value.scrollTop=d.value.scrollHeight,d.value.addEventListener("scroll",Ie,{passive:!1})};let ie;const xs=async()=>{var w;if(S||!M.canvasOpen&&!M.sideOpen)return;let A=!0;if(a.value.siteId=="huya"){const j=(w=a.value)==null?void 0:w.ws;if(!j)return;S=new WebSocket(j),S.onopen=()=>{clearInterval(ie),L("系统","开始连接弹幕服务器"),d.value.addEventListener("scroll",Ie),S==null||S.send(JSON.stringify({command:"subscribeNotice",data:["getMessageNotice"],reqId:Date.now().toString()})),ie=setInterval(()=>{S.send("ping")},45e3)},S.onmessage=F=>{if(A)return L("系统","弹幕服务器连接成功"),A=!1;const{sendNick:W,content:ee}=JSON.parse(F.data).data;L(W,ee)},S.onerror=()=>{clearInterval(ie),L("系统","弹幕服务器连接失败")}}else if(a.value.siteId=="douyu")S=new WebSocket("wss://danmuproxy.douyu.com:8506"),S.onopen=()=>{var j,F;clearInterval(ie),L("系统","开始连接弹幕服务器"),d.value.addEventListener("scroll",Ie),S.send(mt(`type@=loginreq/roomid@=${(j=a.value)==null?void 0:j.roomId}`)),S.send(mt(`type@=joingroup/rid@=${(F=a.value)==null?void 0:F.roomId}/gid@=-9999`)),ie=setInterval(()=>{S.send(mt("type@=mrkl/"))},45e3)},S.onmessage=async({data:j})=>{A&&(L("系统","弹幕服务器连接成功"),A=!1),(await j.text()).split(/type@=chatmsg\//).forEach(ee=>{const we=ee.match(/nn@=(.*)\/txt@=(.*)\/cid/);we!=null&&L(we[1],we[2])})},S.onerror=()=>{clearInterval(ie),L("系统","弹幕服务器连接失败")};else if(a.value.siteId=="douyin"){const j=a.value.ws.split(","),F=j[0],W=j[1],ee=ua(F,W);let we=`wss://webcast5-ws-web-lf.douyin.com/webcast/im/push/v2/?room_id=${F}&compress=gzip&version_code=180800&webcast_sdk_version=1.0.14-beta.0&live_id=1&did_rule=3&user_unique_id=${W}&identity=audience&signature=${ee}&aid=6383&device_platform=web&browser_language=zh-CN&browser_platform=Win32&browser_name=Mozilla&browser_version=5.0+%28Windows+NT+10.0%3B+Win64%3B+x64%29+AppleWebKit%2F537.36+%28KHTML%2C+like+Gecko%29+Chrome%2F126.0.0.0+Safari%2F537.36+Edg%2F126.0.0.0`;S=new WebSocket(we),S.binaryType="arraybuffer",S.onopen=()=>{clearInterval(ie),L("系统","开始连接弹幕服务器"),d.value.addEventListener("scroll",Ie),ie=setInterval(()=>{(S==null?void 0:S.readyState)==1&&S.send(Vr({payloadType:"bh"}))},1e4)},S.onmessage=De=>{A&&(L("系统","弹幕服务器连接成功"),A=!1);const Pe=Gr(new Uint8Array(De.data)),Ue=Ur(Pe.payload),Ee=jr(new Uint8Array(Ue)).messagesList;if(!Ee||Ee.length==0)return;const yt=Ee.length;let Ve=-1;for(;++Ve<yt;){if(Ee[Ve].method!="WebcastChatMessage")continue;const tt=Fr(Ee[Ve].payload);L(tt.user.nickName,tt.content)}},S.onerror=function(){clearInterval(ie),L("系统","弹幕服务器连接失败")}}},ks=new TextEncoder;function mt(A){let w=ks.encode(A);const j=9+w.byteLength,F=[j,0,0,.1,j,0,0,0,177,2,0,0];w=ks.encode(A+"\0");const W=new Uint8Array(12+w.byteLength);return W.set(F),W.set(w,12),W.buffer}const Zt=()=>{clearInterval(ie),S&&(S.onmessage=null,As=="douyu"?S.send(mt("type@=logout")):S.close(),S=null,_=0,d.value&>==i.fullPath&&L("系统","弹幕服务器断开连接"))};ve(a,()=>xs()),ve([()=>M.sideOpen,()=>M.canvasOpen],()=>{!M.sideOpen&&!M.canvasOpen&&Zt(),S||xs()});const Wt=()=>{const{site:A,id:w}=i.meta,j=i.meta.site.follows[w];j&&(a.value=j,n.follow=!0),clearInterval(C),clearInterval(ie),clearTimeout(e),n.notice="加载中...",Kt(()=>{L("系统","开始获取直播间信息")}),be(A.id,"getRoomDetail",{id:w}).then(F=>{if(a.value=F,n.follow&&Bt(F),Kt(()=>L("系统","直播间信息获取成功")),!F.status)return n.notice="未开播!";document.title=a.value.title},F=>{n.notice=F,Kt(()=>L("系统","直播间信息获取失败"))}).finally(()=>clearTimeout(e))},ti=()=>{if(!a.value)return;const{id:A}=i.meta.site;n.follow=n.follow?us(A,a.value.roomId):Bt(a.value)},Qt=()=>{!a.value||!a.value.status||(clearTimeout(t),t=setTimeout(()=>{n.paused?r.value.play():r.value.pause()},200))},_s=()=>{clearTimeout(t),n.fullscreen=!n.fullscreen,document.fullscreenElement?document.exitFullscreen():c.value.requestFullscreen()},Le=()=>{clearTimeout(l),n.showController=!0,l=setTimeout(()=>{var A,w;(A=r.value)!=null&&A.paused||!((w=r.value)!=null&&w.played.length)||(n.showController=!1)},3e3)},si=()=>{clearTimeout(t),n.webscreen=!n.webscreen,n.fullscreen&&(n.fullscreen=!1,document.exitFullscreen())},ni=()=>{n.paused=!1,Le()},ii=()=>{n.paused=!0,Le()},bs=A=>{if(v.value)switch(A.code){case"ArrowDown":return xt(!1);case"ArrowUp":return xt(!0);case"Space":return Qt()}},oi=()=>{var A;clearTimeout(t),clearTimeout(l),clearTimeout(e),clearTimeout(z),clearInterval(C),Zt(),document.title="Lemon live",document.removeEventListener("keydown",bs),b.value&&!n.pictureInPicture&&((A=n[b.value])==null||A.destroy())};Wt();const Ss=Pt();let gt=i.fullPath;Je(()=>{c.value.style.filter=ce.value==100?"":`brightness(${ce.value/100})`,r.value.volume=pe.value/100,n.muted=r.value.muted,r.value.addEventListener("canplay",()=>{n.notice=null}),Mt||(c.value.addEventListener("mousemove",Le),document.addEventListener("keydown",bs)),document.pictureInPictureElement&&document.exitPictureInPicture(),r.value.addEventListener("leavepictureinpicture",()=>{var A;if(!/play/.test(i.path))return Ss.push(gt);if(i.fullPath==gt)return n.pictureInPicture=!1;(A=n[b.value])==null||A.destroy()})});let As=i.meta.site.id;no(A=>{var W;const{siteid:w,id:j}=A.params,F=We.findIndex(ee=>ee==w);return F==-1?{name:"404"}:(A.meta.site=Z[F],A.meta.id=j,b.value&&((W=n[b.value])==null||W.destroy(),n[b.value]=void 0),n.qn=0,n.line=0,n.follow=!1,a.value=void 0,!0)}),ve(()=>i.params,()=>{var A;clearTimeout(z),Zt(),B(),(A=f.value)==null||A.destory(),As=i.meta.site.id,gt=i.fullPath,Wt()}),jt(oi);const li=()=>Promise.all(Ft(Z,cs)),ri=async A=>{A==1&&await li()},ai=()=>n.showController?Qt():Le(),ci=()=>{n.pictureInPicture=!n.pictureInPicture,document.pictureInPictureElement?document.exitPictureInPicture():r.value.requestPictureInPicture()},ui=A=>{const w=A.target.dataset.color;if(!w)return;const j=M.colors.findIndex(F=>F==w);if(j==-1)return M.colors.push(w);M.colors.length!=1&&M.colors.splice(j,1)};ve(()=>M.colors,()=>{var A;return(A=f.value)==null?void 0:A.setColors(M.colors)}),ve(()=>M.canvasSpeed,()=>{var A;return(A=f.value)==null?void 0:A.setSpeed(M.canvasSpeed)}),ve(()=>M.canvasOpacity,()=>{var A;return(A=f.value)==null?void 0:A.setOpacity(M.canvasOpacity)}),ve(()=>M.canvasColorOpen,()=>{var A;return(A=f.value)==null?void 0:A.setColors(M.canvasColorOpen?M.colors:["#ffffff"])}),Qe(()=>{var A,w,j,F;(A=f.value)==null||A.setGap(M.canvasGap),(w=f.value)==null||w.setFont(M.canvasFontsize),(j=f.value)==null||j.setRows(M.canvasRows),(F=f.value)==null||F.resize()}),ve(pe,()=>{Le(),clearTimeout(e),n.notice=`当前音量 ${pe.value}%`,r.value.volume=pe.value/100,Ce("volume",pe.value),e=setTimeout(()=>n.notice=null,2e3)}),ve(ce,()=>{Le(),clearTimeout(e),n.notice=`当前亮度 ${ce.value}%`,c.value.style.filter=ce.value==100?"":`brightness(${ce.value/100})`,Ce("brightness",ce.value),e=setTimeout(()=>n.notice=null,2e3)});let Jt;const wt=U(),di=A=>{clearTimeout(Jt),Jt=setTimeout(()=>{const w=Xe("id",A.target,wt.value);if(!w)return;const j=Xe("site",A.target,wt.value);Ss.push(`/${j}/play/${w}`)},300)},fi=A=>{var W;clearTimeout(Jt);const w=Xe("id",A.target,wt.value);if(!w)return;const F=`/${Xe("site",A.target,wt.value)}/play/${w}`;(W=window.open(F,"_blank"))==null||W.location},Xe=(A,w,j)=>{if(w==j)return null;const F=w.dataset[A];return F||Xe(A,w.parentElement,j)},hi=()=>ce.value=100;ve(()=>n.muted,()=>{Le(),clearTimeout(e),n.notice=n.muted?"已静音":"已开启声音",e=setTimeout(()=>n.notice=null,2e3)});const vi=()=>{if(r.value.muted){r.value.muted=!1,n.muted=!1;return}r.value.muted=!0,n.muted=!0};function pi(A,w,j){j.stopPropagation(),j.preventDefault(),us(A,w),A==a.value.siteId&&w==a.value.roomId&&(n.follow=!1)}return(A,w)=>{var Ue,et,Ee,yt,Ve,tt;const j=_l,F=gl,W=vt,ee=vl,we=fl,De=ht,Pe=Ut("lazy");return T(),D("div",ha,[p("div",va,[p("div",pa,[p("div",{onClick:w[0]||(w[0]=(...R)=>A.$router.back&&A.$router.back(...R)),class:"i-ri-arrow-left-line hover:text-amber"}),p("h1",ma,N((Ue=k(a))==null?void 0:Ue.title),1),p("div",{onClick:w[1]||(w[1]=R=>Ge.value=!k(Ge)),style:Ze(k(Ge)?"transform:rotate(180deg)":"margin-right:1.5rem"),class:"i-ri-arrow-right-s-fill hidden lg:block"},null,4)]),p("div",{ref_key:"player",ref:c,class:H(["md:rounded-6px text-4 text-white bg-black cursor-default pos-relative w-full overflow-hidden select-none h-full",{"cursor-none":!k(n).showController,"text-5":k(n).fullscreen,"text-5 !pos-fixed left-0 right-0 top-0 bottom-0 z-10 ":k(n).webscreen}]),onContextmenu:w[19]||(w[19]=ne(()=>{},["prevent"])),onClick:ai,onDblclick:_s},[p("div",ga,[p("video",{playsinline:"","webkit-playsinline":"","x5-video-player-type":"h5",autoplay:"",ref_key:"video",ref:r,class:"w-full h-full pos-absolute",onPlay:ni,onPause:ii},null,544)]),Q(p("div",wa,[p("span",null,N(k(n).notice),1)],512),[[ye,k(n).notice]]),p("canvas",{ref_key:"canvas",ref:m,width:"0",height:"0",class:"w-full h-full z-1 pos-absolute top-0"},null,512),Q(p("div",{class:H(["pos-absolute bottom-0 left-0 right-0 px-4 py-2 gap-3 z-20 flex items-center bg-black bg-op-30",{"py-3":k(n).fullscreen||k(n).webscreen}]),onClick:w[5]||(w[5]=ne(()=>{},["stop"])),onDblclick:w[6]||(w[6]=ne(()=>{},["stop"]))},[p("div",{onClick:Qt,class:H(["hover:text-amber",k(n).paused?"i-ri-play-large-fill":"i-ri-pause-large-fill"])},null,2),p("div",{onClick:ti,class:H(["hover:text-amber",k(n).follow?"i-ri-heart-fill":"i-ri-heart-line"])},null,2),p("div",{onClick:Wt,class:"i-ri-refresh-line hover:text-amber"}),p("img",{class:"w-1.5em cursor-pointer",onClick:w[2]||(w[2]=()=>k(M).canvasOpen=!k(M).canvasOpen),src:k(M).canvasOpen?k(js):k($s)},null,8,ya),w[33]||(w[33]=p("div",{class:"grow"},null,-1)),k(u).length?(T(),D("div",xa,[P(j,{active:k(n).qn,"onUpdate:active":w[3]||(w[3]=R=>k(n).qn=R),list:k(u)},null,8,["active","list"]),P(j,{active:k(n).line,"onUpdate:active":w[4]||(w[4]=R=>k(n).line=R),list:k(h)},null,8,["active","list"]),k(Mt)?_e("",!0):(T(),D("div",{key:0,class:H(["hover:text-amber ml-2",k(n).pictureInPicture?"i-ri-picture-in-picture-exit-line":"i-ri-picture-in-picture-2-line"]),onClick:ci},null,2))])):_e("",!0),p("div",{onClick:si,class:"i-mdi-fit-to-screen hover:text-amber"}),p("div",{onClick:_s,class:H(["hover:text-amber",k(n).fullscreen?"i-ri-fullscreen-exit-fill":"i-ri-fullscreen-fill"])},null,2)],34),[[ye,k(n).showController]]),k(Mt)?Q((T(),D("div",{key:0,class:H([{"py-3":k(n).fullscreen||k(n).webscreen},"pos-absolute top-0 left-0 right-0 px-4 py-2 gap-3 z-20 flex justify-between bg-black bg-op-30"]),onClick:w[11]||(w[11]=ne(()=>{},["stop"])),onDblclick:w[12]||(w[12]=ne(()=>{},["stop"]))},[p("div",ka,[p("div",{onClick:w[7]||(w[7]=R=>k(Ls)(!1)),class:"i-ri-sun-line"}),p("div",null,N(k(ce)),1),p("div",{onClick:w[8]||(w[8]=R=>k(Ls)(!0)),class:"i-ri-sun-fill"})]),Q(p("div",{class:"flex-1 w-10 truncate text-center"},N((et=k(a))==null?void 0:et.title),513),[[ye,k(n).fullscreen]]),p("div",_a,[p("div",{onClick:w[9]||(w[9]=R=>k(xt)(!1)),class:"i-ri-volume-down-fill"}),p("div",null,N(k(pe)),1),p("div",{onClick:w[10]||(w[10]=R=>k(xt)(!0)),class:"i-ri-volume-up-fill"})])],34)),[[ye,k(n).showController]]):Q((T(),D("div",ba,[p("div",{onClick:w[14]||(w[14]=ne(()=>{},["stop"])),onDblclick:w[15]||(w[15]=ne(()=>{},["stop"])),class:"top-50% left-4 flex items-center flex-col pos-absolute z-20",style:{transform:"translateY(-50%)"}},[p("div",null,N(k(ce)),1),P(F,{value:k(ce),"onUpdate:value":w[13]||(w[13]=R=>$e(ce)?ce.value=R:null),max:200,min:50},null,8,["value"]),p("div",{onClick:ne(hi,["stop"]),class:"i-ri-sun-line"})],32),p("div",{onClick:w[17]||(w[17]=ne(()=>{},["stop"])),onDblclick:w[18]||(w[18]=ne(()=>{},["stop"])),class:"top-50% right-4 flex items-center flex-col pos-absolute z-20",style:{transform:"translateY(-50%)"}},[Et(N(k(pe))+" ",1),P(F,{value:k(pe),"onUpdate:value":w[16]||(w[16]=R=>$e(pe)?pe.value=R:null),max:100,min:0},null,8,["value"]),p("div",{onClick:ne(vi,["stop"]),class:H(k(n).muted?"i-ri-volume-mute-line":"i-ri-volume-down-line")},null,2)],32)],512)),[[ye,k(n).showController]])],34)]),Q(p("div",Sa,[p("div",Aa,[p("img",{src:(Ee=k(a))==null?void 0:Ee.avatar,alt:"",class:"w-8 h-8 rounded-4"},null,8,Ta),p("div",Ca,[p("div",Ia,N((yt=k(a))==null?void 0:yt.nickname),1),p("div",Ea,[p("img",{class:"w-4 h-4",src:A.$route.meta.site.icon},null,8,Ma),Et(" "+N(A.$route.meta.site.name)+" "+N((Ve=k(a))==null?void 0:Ve.category),1)])]),p("div",null,[w[34]||(w[34]=p("div",{class:"i-mdi-fire mx-1"},null,-1)),p("span",null,N((tt=k(a))==null?void 0:tt.online),1)])]),P(De,{grow:!0,onTabClick:ri,class:"!h-[calc(100%-3.75rem)]"},{default:G(()=>[P(W,{title:"聊天",class:"pos-relative"},{default:G(()=>{var R;return[p("div",Oa,[p("img",{onClick:w[20]||(w[20]=()=>k(M).sideOpen=!k(M).sideOpen),class:"w-1.5em cursor-pointer",src:k(M).sideOpen?k(js):k($s)},null,8,Ra),p("div",{onClick:B,class:"i-ri-delete-bin-3-line text-green-5"}),p("a",{class:"text-green-5",href:(R=k(a))==null?void 0:R.url,target:"_blank"},w[35]||(w[35]=[p("div",{class:"i-ri-link"},null,-1)]),8,Ba),p("div",{onClick:Ne,class:"i-ri-arrow-down-circle-line text-green-5"})]),p("div",{ref_key:"dm",ref:d,class:"scrolly h-full pl-2 box-border"},null,512)]}),_:1}),P(W,{title:"关注",class:"box-border px-4"},{default:G(()=>[p("div",{onClick:ne(di,["prevent"]),onDblclick:ne(fi,["prevent"])},[(T(!0),D(se,null,fe(k(y),R=>{var Ts,Cs;return T(),D("a",{"data-id":R.roomId,"data-site":R.siteId,class:H([{"text-amber":((Ts=k(a))==null?void 0:Ts.siteId)==R.siteId&&((Cs=k(a))==null?void 0:Cs.roomId)==R.roomId},"flex items-center justify-between gap-2 py-2"]),key:`${R.siteId}/${R.roomId}`,href:`/${R.siteId}/play/${R.roomId}`},[p("div",Da,[Q(p("img",Ua,null,512),[[Pe,R.avatar]]),p("div",null,N(k(Mn)[R.siteId]),1),p("div",null,N(R.nickname),1),p("div",{class:H(["inline-block w-3 h-3 rounded-3",[R.status?"bg-amber":"bg-red"]])},null,2),p("div",null,N(R.status?"直播中":"未开播"),1)]),p("div",{class:"i-mdi-heart-off-outline pos-relative w-6 h-6 hover:text-amber",onClick:mi=>pi(R.siteId,R.roomId,mi)},null,8,ja)],10,La)}),128))],32)]),_:1}),P(W,{title:"设置",class:"px-2"},{default:G(()=>[w[47]||(w[47]=p("div",{class:"p-3"},"弹幕",-1)),p("div",$a,[p("div",za,[w[36]||(w[36]=p("div",null,"文字大小",-1)),P(ee,{value:k(M).canvasFontsize,"onUpdate:value":w[21]||(w[21]=R=>k(M).canvasFontsize=R),max:80,min:8,step:1},null,8,["value"])]),p("div",Fa,[w[37]||(w[37]=p("div",null,"上下间隔",-1)),P(ee,{value:k(M).canvasGap,"onUpdate:value":w[22]||(w[22]=R=>k(M).canvasGap=R),max:80,min:1,step:1},null,8,["value"])]),p("div",Na,[w[38]||(w[38]=p("div",null,"最大行数",-1)),P(ee,{value:k(M).canvasRows,"onUpdate:value":w[23]||(w[23]=R=>k(M).canvasRows=R),max:50,min:1,step:1},null,8,["value"])]),p("div",Pa,[w[39]||(w[39]=p("div",null,"弹幕速度",-1)),P(ee,{value:k(M).canvasSpeed,"onUpdate:value":w[24]||(w[24]=R=>k(M).canvasSpeed=R),max:32,min:.5,step:.5},null,8,["value"])]),p("div",Va,[w[40]||(w[40]=p("div",null,"弹幕透明",-1)),P(ee,{value:k(M).canvasOpacity,"onUpdate:value":w[25]||(w[25]=R=>k(M).canvasOpacity=R),max:100,min:10,step:10},null,8,["value"])]),p("div",Ha,[w[41]||(w[41]=p("div",null,"彩色弹幕",-1)),P(we,{value:k(M).canvasColorOpen,"onUpdate:value":w[26]||(w[26]=R=>k(M).canvasColorOpen=R)},null,8,["value"])])]),w[48]||(w[48]=p("div",{class:"p-3"},"聊天",-1)),p("div",Ga,[p("div",Za,[w[42]||(w[42]=p("div",null,"文字大小",-1)),P(ee,{value:k(M).sideFontsize,"onUpdate:value":w[27]||(w[27]=R=>k(M).sideFontsize=R),max:80,min:8,step:1},null,8,["value"])]),p("div",Wa,[w[43]||(w[43]=p("div",null,"上下间隔",-1)),P(ee,{value:k(M).sideGap,"onUpdate:value":w[28]||(w[28]=R=>k(M).sideGap=R),max:80,min:0,step:1},null,8,["value"])]),p("div",Qa,[w[44]||(w[44]=p("div",null,"自动清屏",-1)),P(ee,{value:k(M).sideClean,"onUpdate:value":w[29]||(w[29]=R=>k(M).sideClean=R),max:500,min:10,step:10},null,8,["value"])]),p("div",Ja,[w[45]||(w[45]=p("div",null,"彩色消息",-1)),P(we,{value:k(M).sideColorOpen,"onUpdate:value":w[30]||(w[30]=R=>k(M).sideColorOpen=R)},null,8,["value"])])]),w[49]||(w[49]=p("div",{class:"p-3"},"颜色",-1)),p("div",Ka,[(T(!0),D(se,null,fe(k(eo),R=>(T(),D("div",{onClick:ui},[p("div",{class:"w-4 h-4 rounded-2 m-2 shadow cursor-pointer box-border","data-color":R,style:Ze(`background:${R};${k(M).colors.includes(R)?"box-shadow:0 0 0px 2px white":""}`)},null,12,Ya)]))),256))]),p("div",qa,[w[46]||(w[46]=Et("屏蔽 ")),P(we,{value:k(M).blockOpen,"onUpdate:value":w[31]||(w[31]=R=>k(M).blockOpen=R)},null,8,["value"])]),Q(p("textarea",{class:"outline-none w-full text-white b b-solid b-gray-7 p-2 box-border bg-dark shadow rounded-1","onUpdate:modelValue":w[32]||(w[32]=R=>k(M).blockWords=R),rows:"5",placeholder:"以空格分隔"},null,512),[[Rt,k(M).blockWords,void 0,{trim:!0}]])]),_:1})]),_:1})],512),[[ye,k(Ge)]])])}}}),ec={class:"scrolly h-full box-border py-2"},tc={key:0,class:"flex justify-center flex-col gap-4 px-6 w-xs"},sc={class:"flex justify-between"},nc={class:"py-2"},ic={class:"flex"},oc={class:"text-xl flex items-center"},lc={class:"i-ri-refresh-line w-6 h-6 animate-spin"},rc={class:"flex justify-between"},ac={class:"py-2"},cc={class:"flex justify-between"},uc={class:"py-2"},dc={key:1,class:"flex flex-col justify-center items-center h-80vh"},fc={class:"w-50% max-w-xs justify-center items-center flex flex-col"},hc={class:"pos-relative w-full mt-6"},vc={class:"pos-relative w-full mt-4 mb-6"},pc={key:0,class:"flex w-full justify-evenly"},mc=X({__name:"user",setup(s){const t=U([]),e=Te({username:"",password:""}),l=/^[\u4e00-\u9fa5a-zA-Z0-9]{1,12}$/,n=/^.{0,12}$/,i=U(!1),c=()=>{if(!l.test(e.username))return ot.warning("账号1到12个字符!");if(!n.test(e.password))return ot.warning("密码0到12个字符!");if(i.value)return qi({...e,token:je.value}).then(b=>{je.value=b.token,Ce("token",b.token),ot.success("密码修改成功!"),i.value=!1});Yi(e).then(b=>{st.value=b.user,je.value=b.token,Ce("user",b.user),Ce("token",b.token),st.value.follows&&(t.value=JSON.parse($t.decompressFromBase64(st.value.follows)))})},r=U(!1),d=()=>setTimeout(()=>r.value=!1,300),a=()=>{r.value||(r.value=!0,Ji(lt[0].list.value).then(()=>{t.value=lt[0].list.value}).finally(d))},u=()=>{r.value||(r.value=!0,Ki().then(b=>{t.value=b}).finally(d))},h=()=>{r.value||(r.value=!0,t.value.forEach(b=>Bt(b)),d())},v=()=>{r.value||(r.value=!0,Xi(),t.value.forEach(b=>Bt(b)),d())},y=()=>{st.value=void 0,je.value=void 0,localStorage.removeItem("user"),localStorage.removeItem("token")};return(b,C)=>(T(),D("div",ec,[k(je)&&!k(i)?(T(),D("div",tc,[C[5]||(C[5]=p("div",{class:"text-xl"},"账号",-1)),p("div",sc,[p("div",nc,N(k(st).username),1),p("div",ic,[p("div",{onClick:C[0]||(C[0]=()=>i.value=!0),class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4 mx-4"},"改密 "),p("div",{onClick:y,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"登出")])]),p("div",oc,[C[4]||(C[4]=p("div",{class:"mr-4"},"同步",-1)),Q(p("div",lc,null,512),[[ye,k(r)]])]),p("div",rc,[p("div",ac,"本地 "+N(k(lt)[0].list.value.length),1),p("div",{class:"flex"},[p("div",{onClick:h,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4 mx-4"},"合并"),p("div",{onClick:v,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"覆盖")])]),p("div",cc,[p("div",uc,"云端 "+N(k(t).length),1),p("div",{class:"flex"},[p("div",{onClick:u,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4 mx-4"},"拉取"),p("div",{onClick:a,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"推送")])]),C[6]||(C[6]=p("div",{class:"text-xl"},"支持",-1)),C[7]||(C[7]=p("div",{class:"flex justify-between"},[p("img",{class:"h-50",src:"https://i0.hdslb.com/bfs/article/828b4686d0bcd7a427939b1f121f322898845873.png@1e_1c.webp"}),p("img",{class:"h-50",src:"https://i0.hdslb.com/bfs/article/d07b5e8cbae76f0fc38a8049c433d3d598845873.jpg@1e_1c.webp"})],-1))])):(T(),D("div",dc,[p("div",fc,[C[11]||(C[11]=p("div",{class:"text-2xl font-bold"},"Lemon live",-1)),p("div",hc,[Q(p("input",{class:"md:text-4 box-border w-full py-3 px-12 text-white bg-transparent b-1 b-style-groove b-green rounded-6 outline-none",type:"text","onUpdate:modelValue":C[1]||(C[1]=E=>k(e).username=E),placeholder:"请输入账号 1到12个字符"},null,512),[[Rt,k(e).username,void 0,{trim:!0}]]),C[8]||(C[8]=p("div",{class:"i-ri-user-smile-line pos-absolute left-4 top-2 bg-gray"},null,-1))]),p("div",vc,[Q(p("input",{class:"md:text-4 box-border w-full py-3 px-12 text-white bg-transparent b-1 b-style-groove b-green rounded-6 outline-none",type:"text","onUpdate:modelValue":C[2]||(C[2]=E=>k(e).password=E),placeholder:"请输入密码 0到12个字符"},null,512),[[Rt,k(e).password,void 0,{trim:!0}]]),C[9]||(C[9]=p("div",{class:"i-ri-lock-password-line pos-absolute left-4 top-2 bg-gray"},null,-1))]),k(i)?(T(),D("div",pc,[p("div",{onClick:C[3]||(C[3]=()=>i.value=!1),class:"cursor-pointer flex gap-2 text-black bg-gray-5 hover:bg-green-7 py-3 px-8 rounded-6"},"取消"),p("div",{onClick:c,class:"cursor-pointer flex gap-2 text-black bg-green-5 hover:bg-green-7 py-3 px-8 rounded-6"},"确定")])):(T(),D("div",{key:1,onClick:c,class:"cursor-pointer flex gap-2 text-black bg-green-5 hover:bg-green-7 py-3 px-8 rounded-6"},C[10]||(C[10]=[p("div",null,"注册",-1),p("div",null,"/",-1),p("div",null,"登录",-1)])))])]))]))}}),gc={},wc={"h-full":"",flex:"","justify-center":"","items-center":""};function yc(s,t){return T(),D("div",wc,t[0]||(t[0]=[p("div",{"text-center":"","text-8":"","line-height-8":""},[p("div",{"font-900":""},"404"),p("div",{"mt-4":""},"页面未找到")],-1)]))}const xc=Tn(gc,[["render",yc]]);async function nt(s){const{siteid:t,id:e}=s.params,l=Z.findIndex(n=>n.id==t);return l==-1?{name:"404"}:(s.meta.site=Z[l],s.meta.id=e,s.meta.index=l,te.value=l,!0)}const kc=to({history:so(),routes:[{path:"/",redirect:()=>`/${We[te.value]}`},{path:"/follow",component:ul},{path:"/user",component:mc},{path:"/category",redirect:()=>`/${We[te.value]}/category`},{path:"/search",redirect:()=>`/${We[te.value]}/search`},{path:"/:siteid",component:dl,beforeEnter:nt},{path:"/:siteid/category",component:Po,beforeEnter:nt},{path:"/:siteid/category/:id",component:Io,beforeEnter:nt},{path:"/:siteid/play/:id",component:Xa,beforeEnter:nt},{path:"/:siteid/search",component:Qo,beforeEnter:nt},{path:"/:pathMatch(.*)*",name:"404",component:xc}]}),_c={install(s){s.directive("lazy",{mounted(t,e){t.src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9Im5vbmUiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS13aWR0aD0iMS41IiBkPSJtMi4yNSAxNS43NWw1LjE1OS01LjE1OWEyLjI1IDIuMjUgMCAwIDEgMy4xODIgMGw1LjE1OSA1LjE1OW0tMS41LTEuNWwxLjQwOS0xLjQwOWEyLjI1IDIuMjUgMCAwIDEgMy4xODIgMGwyLjkwOSAyLjkwOW0tMTggMy43NWgxNi41YTEuNSAxLjUgMCAwIDAgMS41LTEuNVY2YTEuNSAxLjUgMCAwIDAtMS41LTEuNUgzLjc1QTEuNSAxLjUgMCAwIDAgMi4yNSA2djEyYTEuNSAxLjUgMCAwIDAgMS41IDEuNW0xMC41LTExLjI1aC4wMDh2LjAwOGgtLjAwOHptLjM3NSAwYS4zNzUuMzc1IDAgMSAxLS43NSAwYS4zNzUuMzc1IDAgMCAxIC43NSAwIi8+PC9zdmc+";const l=new IntersectionObserver(n=>{Hi(n,i=>{if(i.isIntersecting){const c=new Image;c.src=e.value,c.onload=()=>t.src=e.value,l.unobserve(i.target)}})});l.observe(t)}})}},ei=yi(ro);ei.use(kc).use(_c);ei.mount("#app");
|
1
|
+
var _s=Object.defineProperty;var xs=(t,i,e)=>i in t?_s(t,i,{enumerable:!0,configurable:!0,writable:!0,value:e}):t[i]=e;var te=(t,i,e)=>xs(t,typeof i!="symbol"?i+"":i,e);(function(){const i=document.createElement("link").relList;if(i&&i.supports&&i.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))s(n);new MutationObserver(n=>{for(const r of n)if(r.type==="childList")for(const u of r.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&s(u)}).observe(document,{childList:!0,subtree:!0});function e(n){const r={};return n.integrity&&(r.integrity=n.integrity),n.referrerPolicy&&(r.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?r.credentials="include":n.crossOrigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function s(n){if(n.ep)return;n.ep=!0;const r=e(n);fetch(n.href,r)}})();const bs=Vue.createApp,m=Vue.createElementVNode,B=Vue.openBlock,D=Vue.createElementBlock,L=Vue.ref,Me=Vue.reactive,Ye=Vue.watchEffect,X=Vue.computed,ne=Vue.defineComponent,b=Vue.unref,me=Vue.renderList,oe=Vue.Fragment,Z=Vue.normalizeClass,Mt=Vue.resolveComponent,q=Vue.withCtx,V=Vue.createVNode,ke=Vue.vShow,Q=Vue.withDirectives,ut=Vue.resolveDynamicComponent,ee=Vue.createBlock,ks=Vue.KeepAlive,Ee=Vue.createCommentVNode,Ke=Vue.onMounted,ye=Vue.watch,$=Vue.toDisplayString,Bn=Vue.onActivated,Ft=Vue.resolveDirective,je=Vue.isRef,Ot=Vue.vModelText,Is=Vue.withKeys,Ze=Vue.normalizeStyle,ae=Vue.withModifiers,Ct=Vue.createTextVNode,Ss=Vue.shallowRef,Kt=Vue.nextTick,Lt=Vue.onBeforeUnmount,vi=Vue.h,Ts=Vue.onDeactivated,Bs=Vue.onUnmounted,ht=Vue.useModel,mi=Vue.useSlots,ct=Vue.mergeModels,Es=Vue.renderSlot,En=Vue.render,As=Vue.Transition,Cs=Vue.provide,Ns=Vue.inject,Ms=Vue.getCurrentInstance;var Qt={exports:{}},Ni;function Os(){return Ni||(Ni=1,function(t){var i=function(){var e=String.fromCharCode,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",r={};function u(f,l){if(!r[f]){r[f]={};for(var c=0;c<f.length;c++)r[f][f.charAt(c)]=c}return r[f][l]}var a={compressToBase64:function(f){if(f==null)return"";var l=a._compress(f,6,function(c){return s.charAt(c)});switch(l.length%4){default:case 0:return l;case 1:return l+"===";case 2:return l+"==";case 3:return l+"="}},decompressFromBase64:function(f){return f==null?"":f==""?null:a._decompress(f.length,32,function(l){return u(s,f.charAt(l))})},compressToUTF16:function(f){return f==null?"":a._compress(f,15,function(l){return e(l+32)})+" "},decompressFromUTF16:function(f){return f==null?"":f==""?null:a._decompress(f.length,16384,function(l){return f.charCodeAt(l)-32})},compressToUint8Array:function(f){for(var l=a.compress(f),c=new Uint8Array(l.length*2),p=0,v=l.length;p<v;p++){var _=l.charCodeAt(p);c[p*2]=_>>>8,c[p*2+1]=_%256}return c},decompressFromUint8Array:function(f){if(f==null)return a.decompress(f);for(var l=new Array(f.length/2),c=0,p=l.length;c<p;c++)l[c]=f[c*2]*256+f[c*2+1];var v=[];return l.forEach(function(_){v.push(e(_))}),a.decompress(v.join(""))},compressToEncodedURIComponent:function(f){return f==null?"":a._compress(f,6,function(l){return n.charAt(l)})},decompressFromEncodedURIComponent:function(f){return f==null?"":f==""?null:(f=f.replace(/ /g,"+"),a._decompress(f.length,32,function(l){return u(n,f.charAt(l))}))},compress:function(f){return a._compress(f,16,function(l){return e(l)})},_compress:function(f,l,c){if(f==null)return"";var p,v,_={},I={},E="",C="",A="",R=2,S=3,k=2,x=[],w=0,h=0,y;for(y=0;y<f.length;y+=1)if(E=f.charAt(y),Object.prototype.hasOwnProperty.call(_,E)||(_[E]=S++,I[E]=!0),C=A+E,Object.prototype.hasOwnProperty.call(_,C))A=C;else{if(Object.prototype.hasOwnProperty.call(I,A)){if(A.charCodeAt(0)<256){for(p=0;p<k;p++)w=w<<1,h==l-1?(h=0,x.push(c(w)),w=0):h++;for(v=A.charCodeAt(0),p=0;p<8;p++)w=w<<1|v&1,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=v>>1}else{for(v=1,p=0;p<k;p++)w=w<<1|v,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=0;for(v=A.charCodeAt(0),p=0;p<16;p++)w=w<<1|v&1,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=v>>1}R--,R==0&&(R=Math.pow(2,k),k++),delete I[A]}else for(v=_[A],p=0;p<k;p++)w=w<<1|v&1,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=v>>1;R--,R==0&&(R=Math.pow(2,k),k++),_[C]=S++,A=String(E)}if(A!==""){if(Object.prototype.hasOwnProperty.call(I,A)){if(A.charCodeAt(0)<256){for(p=0;p<k;p++)w=w<<1,h==l-1?(h=0,x.push(c(w)),w=0):h++;for(v=A.charCodeAt(0),p=0;p<8;p++)w=w<<1|v&1,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=v>>1}else{for(v=1,p=0;p<k;p++)w=w<<1|v,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=0;for(v=A.charCodeAt(0),p=0;p<16;p++)w=w<<1|v&1,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=v>>1}R--,R==0&&(R=Math.pow(2,k),k++),delete I[A]}else for(v=_[A],p=0;p<k;p++)w=w<<1|v&1,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=v>>1;R--,R==0&&(R=Math.pow(2,k),k++)}for(v=2,p=0;p<k;p++)w=w<<1|v&1,h==l-1?(h=0,x.push(c(w)),w=0):h++,v=v>>1;for(;;)if(w=w<<1,h==l-1){x.push(c(w));break}else h++;return x.join("")},decompress:function(f){return f==null?"":f==""?null:a._decompress(f.length,32768,function(l){return f.charCodeAt(l)})},_decompress:function(f,l,c){var p=[],v=4,_=4,I=3,E="",C=[],A,R,S,k,x,w,h,y={val:c(0),position:l,index:1};for(A=0;A<3;A+=1)p[A]=A;for(S=0,x=Math.pow(2,2),w=1;w!=x;)k=y.val&y.position,y.position>>=1,y.position==0&&(y.position=l,y.val=c(y.index++)),S|=(k>0?1:0)*w,w<<=1;switch(S){case 0:for(S=0,x=Math.pow(2,8),w=1;w!=x;)k=y.val&y.position,y.position>>=1,y.position==0&&(y.position=l,y.val=c(y.index++)),S|=(k>0?1:0)*w,w<<=1;h=e(S);break;case 1:for(S=0,x=Math.pow(2,16),w=1;w!=x;)k=y.val&y.position,y.position>>=1,y.position==0&&(y.position=l,y.val=c(y.index++)),S|=(k>0?1:0)*w,w<<=1;h=e(S);break;case 2:return""}for(p[3]=h,R=h,C.push(h);;){if(y.index>f)return"";for(S=0,x=Math.pow(2,I),w=1;w!=x;)k=y.val&y.position,y.position>>=1,y.position==0&&(y.position=l,y.val=c(y.index++)),S|=(k>0?1:0)*w,w<<=1;switch(h=S){case 0:for(S=0,x=Math.pow(2,8),w=1;w!=x;)k=y.val&y.position,y.position>>=1,y.position==0&&(y.position=l,y.val=c(y.index++)),S|=(k>0?1:0)*w,w<<=1;p[_++]=e(S),h=_-1,v--;break;case 1:for(S=0,x=Math.pow(2,16),w=1;w!=x;)k=y.val&y.position,y.position>>=1,y.position==0&&(y.position=l,y.val=c(y.index++)),S|=(k>0?1:0)*w,w<<=1;p[_++]=e(S),h=_-1,v--;break;case 2:return C.join("")}if(v==0&&(v=Math.pow(2,I),I++),p[h])E=p[h];else if(h===_)E=R+R.charAt(0);else return null;C.push(E),p[_++]=R+E.charAt(0),v--,R=E,v==0&&(v=Math.pow(2,I),I++)}}};return a}();t!=null?t.exports=i:typeof angular<"u"&&angular!=null&&angular.module("LZString",[]).factory("LZString",function(){return i})}(Qt)),Qt.exports}var Ht=Os();function Mi(t){var i;typeof t.remove<"u"?t.remove():(i=t.parentNode)==null||i.removeChild(t)}function Rs(t,i,e,s={}){const n=vi(t,i,s),r=document.createElement("div");return r.classList.add("v-toast--pending"),e.appendChild(r),En(n,r),n.component}class Us{constructor(i,e){te(this,"startedAt");te(this,"callback");te(this,"delay");te(this,"timer");this.startedAt=Date.now(),this.callback=i,this.delay=e,this.timer=setTimeout(i,e)}pause(){this.stop(),this.delay-=Date.now()-this.startedAt}resume(){this.stop(),this.startedAt=Date.now(),this.timer=setTimeout(this.callback,this.delay)}stop(){clearTimeout(this.timer)}}const pe=Object.freeze({TOP_RIGHT:"top-right",TOP:"top",TOP_LEFT:"top-left",BOTTOM_RIGHT:"bottom-right",BOTTOM:"bottom",BOTTOM_LEFT:"bottom-left"});function Ds(t){return{all:t=t||new Map,on:function(i,e){var s=t.get(i);s?s.push(e):t.set(i,[e])},off:function(i,e){var s=t.get(i);s&&(e?s.splice(s.indexOf(e)>>>0,1):t.set(i,[]))},emit:function(i,e){var s=t.get(i);s&&s.slice().map(function(n){n(e)}),(s=t.get("*"))&&s.slice().map(function(n){n(i,e)})}}}const li=Ds(),An=(t,i)=>{const e=t.__vccOpts||t;for(const[s,n]of i)e[s]=n;return e},Fs=ne({name:"Toast",props:{message:{type:String,required:!0},type:{type:String,default:"success"},position:{type:String,default:pe.BOTTOM_RIGHT,validator(t){return Object.values(pe).includes(t)}},duration:{type:Number,default:3e3},dismissible:{type:Boolean,default:!0},onDismiss:{type:Function,default:()=>{}},onClick:{type:Function,default:()=>{}},queue:Boolean,pauseOnHover:{type:Boolean,default:!0}},data(){return{isActive:!1,parentTop:null,parentBottom:null,isHovered:!1}},beforeMount(){this.setupContainer()},mounted(){this.showNotice(),li.on("toast-clear",this.dismiss)},methods:{setupContainer(){if(this.parentTop=document.querySelector(".v-toast.v-toast--top"),this.parentBottom=document.querySelector(".v-toast.v-toast--bottom"),this.parentTop&&this.parentBottom)return;this.parentTop||(this.parentTop=document.createElement("div"),this.parentTop.className="v-toast v-toast--top"),this.parentBottom||(this.parentBottom=document.createElement("div"),this.parentBottom.className="v-toast v-toast--bottom");const t=document.body;t.appendChild(this.parentTop),t.appendChild(this.parentBottom)},shouldQueue(){return this.queue?this.parentTop.childElementCount>0||this.parentBottom.childElementCount>0:!1},dismiss(){this.timer&&this.timer.stop(),clearTimeout(this.queueTimer),this.isActive=!1,setTimeout(()=>{this.onDismiss.apply(null,arguments);const t=this.$refs.root;En(null,t),Mi(t)},150)},showNotice(){if(this.shouldQueue()){this.queueTimer=setTimeout(this.showNotice,250);return}const t=this.$refs.root.parentElement;this.correctParent.insertAdjacentElement("afterbegin",this.$refs.root),Mi(t),this.isActive=!0,this.duration&&(this.timer=new Us(this.dismiss,this.duration))},whenClicked(){this.dismissible&&(this.onClick.apply(null,arguments),this.dismiss())},toggleTimer(t){!this.pauseOnHover||!this.timer||(t?this.timer.pause():this.timer.resume())}},computed:{correctParent(){switch(this.position){case pe.TOP:case pe.TOP_RIGHT:case pe.TOP_LEFT:return this.parentTop;case pe.BOTTOM:case pe.BOTTOM_RIGHT:case pe.BOTTOM_LEFT:return this.parentBottom}},transition(){switch(this.position){case pe.TOP:case pe.TOP_RIGHT:case pe.TOP_LEFT:return{enter:"v-toast--fade-in-down",leave:"v-toast--fade-out"};case pe.BOTTOM:case pe.BOTTOM_RIGHT:case pe.BOTTOM_LEFT:return{enter:"v-toast--fade-in-up",leave:"v-toast--fade-out"}}}},beforeUnmount(){li.off("toast-clear",this.dismiss)}}),Ls=["innerHTML"];function Hs(t,i,e,s,n,r){return B(),ee(As,{"enter-active-class":t.transition.enter,"leave-active-class":t.transition.leave},{default:q(()=>[Q(m("div",{ref:"root",role:"alert",class:Z(["v-toast__item",[`v-toast__item--${t.type}`,`v-toast__item--${t.position}`]]),onMouseover:i[0]||(i[0]=u=>t.toggleTimer(!0)),onMouseleave:i[1]||(i[1]=u=>t.toggleTimer(!1)),onClick:i[2]||(i[2]=(...u)=>t.whenClicked&&t.whenClicked(...u))},[i[3]||(i[3]=m("div",{class:"v-toast__icon"},null,-1)),m("p",{class:"v-toast__text",innerHTML:t.message},null,8,Ls)],34),[[ke,t.isActive]])]),_:1},8,["enter-active-class","leave-active-class"])}const zs=An(Fs,[["render",Hs]]),js=(t={})=>({open(i){let e=null;typeof i=="string"&&(e=i);const n=Object.assign({},{message:e},t,i);return{dismiss:Rs(zs,n,document.body).ctx.dismiss}},clear(){li.emit("toast-clear")},success(i,e={}){return this.open(Object.assign({},{message:i,type:"success"},e))},error(i,e={}){return this.open(Object.assign({},{message:i,type:"error"},e))},info(i,e={}){return this.open(Object.assign({},{message:i,type:"info"},e))},warning(i,e={}){return this.open(Object.assign({},{message:i,type:"warning"},e))},default(i,e={}){return this.open(Object.assign({},{message:i,type:"default"},e))}});var xn,bn,kn,In,Sn,Tn;const Oi=((xn=typeof globalThis<"u"?globalThis:void 0)==null?void 0:xn.crypto)||((bn=typeof global<"u"?global:void 0)==null?void 0:bn.crypto)||((kn=typeof window<"u"?window:void 0)==null?void 0:kn.crypto)||((In=typeof self<"u"?self:void 0)==null?void 0:In.crypto)||((Tn=(Sn=typeof frames<"u"?frames:void 0)==null?void 0:Sn[0])==null?void 0:Tn.crypto);let ui;Oi?ui=t=>{const i=[];for(let e=0,s;e<t;e+=4)i.push(Oi.getRandomValues(new Uint32Array(1))[0]);return new De(i,t)}:ui=t=>{const i=[],e=s=>{let n=s,r=987654321;const u=4294967295;return()=>{r=36969*(r&65535)+(r>>16)&u,n=18e3*(n&65535)+(n>>16)&u;let a=(r<<16)+n&u;return a/=4294967296,a+=.5,a*(Math.random()>.5?1:-1)}};for(let s=0,n;s<t;s+=4){const r=e((n||Math.random())*4294967296);n=r()*987654071,i.push(r()*4294967296|0)}return new De(i,t)};class zt{static create(...i){return new this(...i)}mixIn(i){return Object.assign(this,i)}clone(){const i=new this.constructor;return Object.assign(i,this),i}}class De extends zt{constructor(i=[],e=i.length*4){super();let s=i;if(s instanceof ArrayBuffer&&(s=new Uint8Array(s)),(s instanceof Int8Array||s instanceof Uint8ClampedArray||s instanceof Int16Array||s instanceof Uint16Array||s instanceof Int32Array||s instanceof Uint32Array||s instanceof Float32Array||s instanceof Float64Array)&&(s=new Uint8Array(s.buffer,s.byteOffset,s.byteLength)),s instanceof Uint8Array){const n=s.byteLength,r=[];for(let u=0;u<n;u+=1)r[u>>>2]|=s[u]<<24-u%4*8;this.words=r,this.sigBytes=n}else this.words=i,this.sigBytes=e}toString(i=$s){return i.stringify(this)}concat(i){const e=this.words,s=i.words,n=this.sigBytes,r=i.sigBytes;if(this.clamp(),n%4)for(let u=0;u<r;u+=1){const a=s[u>>>2]>>>24-u%4*8&255;e[n+u>>>2]|=a<<24-(n+u)%4*8}else for(let u=0;u<r;u+=4)e[n+u>>>2]=s[u>>>2];return this.sigBytes+=r,this}clamp(){const{words:i,sigBytes:e}=this;i[e>>>2]&=4294967295<<32-e%4*8,i.length=Math.ceil(e/4)}clone(){const i=super.clone.call(this);return i.words=this.words.slice(0),i}}te(De,"random",ui);const $s={stringify(t){const{words:i,sigBytes:e}=t,s=[];for(let n=0;n<e;n+=1){const r=i[n>>>2]>>>24-n%4*8&255;s.push((r>>>4).toString(16)),s.push((r&15).toString(16))}return s.join("")},parse(t){const i=t.length,e=[];for(let s=0;s<i;s+=2)e[s>>>3]|=parseInt(t.substr(s,2),16)<<24-s%8*4;return new De(e,i/2)}},Ri={stringify(t){const{words:i,sigBytes:e}=t,s=[];for(let n=0;n<e;n+=1){const r=i[n>>>2]>>>24-n%4*8&255;s.push(String.fromCharCode(r))}return s.join("")},parse(t){const i=t.length,e=[];for(let s=0;s<i;s+=1)e[s>>>2]|=(t.charCodeAt(s)&255)<<24-s%4*8;return new De(e,i)}},Cn={stringify(t){try{return decodeURIComponent(escape(Ri.stringify(t)))}catch{throw new Error("Malformed UTF-8 data")}},parse(t){return Ri.parse(unescape(encodeURIComponent(t)))}};class Ps extends zt{constructor(){super(),this._minBufferSize=0}reset(){this._data=new De,this._nDataBytes=0}_append(i){let e=i;typeof e=="string"&&(e=Cn.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes}_process(i){let e;const{_data:s,blockSize:n}=this,r=s.words,u=s.sigBytes,a=n*4;let f=u/a;i?f=Math.ceil(f):f=Math.max((f|0)-this._minBufferSize,0);const l=f*n,c=Math.min(l*4,u);if(l){for(let p=0;p<l;p+=n)this._doProcessBlock(r,p);e=r.splice(0,l),s.sigBytes-=c}return new De(e,c)}clone(){const i=super.clone.call(this);return i._data=this._data.clone(),i}}class Nn extends Ps{constructor(i){super(),this.blockSize=512/32,this.cfg=Object.assign(new zt,i),this.reset()}static _createHelper(i){return(e,s)=>new i(s).finalize(e)}static _createHmacHelper(i){return(e,s)=>new Gs(i,s).finalize(e)}reset(){super.reset.call(this),this._doReset()}update(i){return this._append(i),this._process(),this}finalize(i){return i&&this._append(i),this._doFinalize()}}class Gs extends zt{constructor(i,e){super();const s=new i;this._hasher=s;let n=e;typeof n=="string"&&(n=Cn.parse(n));const r=s.blockSize,u=r*4;n.sigBytes>u&&(n=s.finalize(e)),n.clamp();const a=n.clone();this._oKey=a;const f=n.clone();this._iKey=f;const l=a.words,c=f.words;for(let p=0;p<r;p+=1)l[p]^=1549556828,c[p]^=909522486;a.sigBytes=u,f.sigBytes=u,this.reset()}reset(){const i=this._hasher;i.reset(),i.update(this._iKey)}update(i){return this._hasher.update(i),this}finalize(i){const e=this._hasher,s=e.finalize(i);return e.reset(),e.finalize(this._oKey.clone().concat(s))}}const M=[];for(let t=0;t<64;t+=1)M[t]=Math.abs(Math.sin(t+1))*4294967296|0;const ue=(t,i,e,s,n,r,u)=>{const a=t+(i&e|~i&s)+n+u;return(a<<r|a>>>32-r)+i},ce=(t,i,e,s,n,r,u)=>{const a=t+(i&s|e&~s)+n+u;return(a<<r|a>>>32-r)+i},fe=(t,i,e,s,n,r,u)=>{const a=t+(i^e^s)+n+u;return(a<<r|a>>>32-r)+i},de=(t,i,e,s,n,r,u)=>{const a=t+(e^(i|~s))+n+u;return(a<<r|a>>>32-r)+i};class Vs extends Nn{_doReset(){this._hash=new De([1732584193,4023233417,2562383102,271733878])}_doProcessBlock(i,e){const s=i;for(let z=0;z<16;z+=1){const H=e+z,U=i[H];s[H]=(U<<8|U>>>24)&16711935|(U<<24|U>>>8)&4278255360}const n=this._hash.words,r=s[e+0],u=s[e+1],a=s[e+2],f=s[e+3],l=s[e+4],c=s[e+5],p=s[e+6],v=s[e+7],_=s[e+8],I=s[e+9],E=s[e+10],C=s[e+11],A=s[e+12],R=s[e+13],S=s[e+14],k=s[e+15];let x=n[0],w=n[1],h=n[2],y=n[3];x=ue(x,w,h,y,r,7,M[0]),y=ue(y,x,w,h,u,12,M[1]),h=ue(h,y,x,w,a,17,M[2]),w=ue(w,h,y,x,f,22,M[3]),x=ue(x,w,h,y,l,7,M[4]),y=ue(y,x,w,h,c,12,M[5]),h=ue(h,y,x,w,p,17,M[6]),w=ue(w,h,y,x,v,22,M[7]),x=ue(x,w,h,y,_,7,M[8]),y=ue(y,x,w,h,I,12,M[9]),h=ue(h,y,x,w,E,17,M[10]),w=ue(w,h,y,x,C,22,M[11]),x=ue(x,w,h,y,A,7,M[12]),y=ue(y,x,w,h,R,12,M[13]),h=ue(h,y,x,w,S,17,M[14]),w=ue(w,h,y,x,k,22,M[15]),x=ce(x,w,h,y,u,5,M[16]),y=ce(y,x,w,h,p,9,M[17]),h=ce(h,y,x,w,C,14,M[18]),w=ce(w,h,y,x,r,20,M[19]),x=ce(x,w,h,y,c,5,M[20]),y=ce(y,x,w,h,E,9,M[21]),h=ce(h,y,x,w,k,14,M[22]),w=ce(w,h,y,x,l,20,M[23]),x=ce(x,w,h,y,I,5,M[24]),y=ce(y,x,w,h,S,9,M[25]),h=ce(h,y,x,w,f,14,M[26]),w=ce(w,h,y,x,_,20,M[27]),x=ce(x,w,h,y,R,5,M[28]),y=ce(y,x,w,h,a,9,M[29]),h=ce(h,y,x,w,v,14,M[30]),w=ce(w,h,y,x,A,20,M[31]),x=fe(x,w,h,y,c,4,M[32]),y=fe(y,x,w,h,_,11,M[33]),h=fe(h,y,x,w,C,16,M[34]),w=fe(w,h,y,x,S,23,M[35]),x=fe(x,w,h,y,u,4,M[36]),y=fe(y,x,w,h,l,11,M[37]),h=fe(h,y,x,w,v,16,M[38]),w=fe(w,h,y,x,E,23,M[39]),x=fe(x,w,h,y,R,4,M[40]),y=fe(y,x,w,h,r,11,M[41]),h=fe(h,y,x,w,f,16,M[42]),w=fe(w,h,y,x,p,23,M[43]),x=fe(x,w,h,y,I,4,M[44]),y=fe(y,x,w,h,A,11,M[45]),h=fe(h,y,x,w,k,16,M[46]),w=fe(w,h,y,x,a,23,M[47]),x=de(x,w,h,y,r,6,M[48]),y=de(y,x,w,h,v,10,M[49]),h=de(h,y,x,w,S,15,M[50]),w=de(w,h,y,x,c,21,M[51]),x=de(x,w,h,y,A,6,M[52]),y=de(y,x,w,h,f,10,M[53]),h=de(h,y,x,w,E,15,M[54]),w=de(w,h,y,x,u,21,M[55]),x=de(x,w,h,y,_,6,M[56]),y=de(y,x,w,h,k,10,M[57]),h=de(h,y,x,w,p,15,M[58]),w=de(w,h,y,x,R,21,M[59]),x=de(x,w,h,y,l,6,M[60]),y=de(y,x,w,h,C,10,M[61]),h=de(h,y,x,w,a,15,M[62]),w=de(w,h,y,x,I,21,M[63]),n[0]=n[0]+x|0,n[1]=n[1]+w|0,n[2]=n[2]+h|0,n[3]=n[3]+y|0}_doFinalize(){const i=this._data,e=i.words,s=this._nDataBytes*8,n=i.sigBytes*8;e[n>>>5]|=128<<24-n%32;const r=Math.floor(s/4294967296),u=s;e[(n+64>>>9<<4)+15]=(r<<8|r>>>24)&16711935|(r<<24|r>>>8)&4278255360,e[(n+64>>>9<<4)+14]=(u<<8|u>>>24)&16711935|(u<<24|u>>>8)&4278255360,i.sigBytes=(e.length+1)*4,this._process();const a=this._hash,f=a.words;for(let l=0;l<4;l+=1){const c=f[l];f[l]=(c<<8|c>>>24)&16711935|(c<<24|c>>>8)&4278255360}return a}clone(){const i=super.clone.call(this);return i._hash=this._hash.clone(),i}}const Ui=Nn._createHelper(Vs),jt=(t,i)=>{let e=-1;const s=t.length,n=new Array(s);for(;++e<s;)n[e]=i(t[e]);return n},Ws=(t,i)=>{let e=-1;const s=t.length;for(;++e<s;)i(t[e])},Js=t=>{if(t.scrollTop>0)return!0;t.scrollTop=1;const i=!!t.scrollTop;return t.scrollTop=0,i},Zs=async(t,i,e)=>{const s=[],n=[];for(const r of t){const u=Promise.resolve().then(()=>e(r));if(s.push(u),i<=t.length){const a=u.then(()=>n.splice(n.indexOf(a),1));n.push(a),n.length>=i&&await Promise.race(n)}}return Promise.all(s)},Di=t=>{let i="",e=-1,s=13;for(;++e<s;)i+=Math.random()*10|0;const n=(Date.now()%1e10*1e3+(1e3*Math.random()|0)%4294967295).toString(),r=new URLSearchParams(t.code),u=r.get("fs"),a=(Date.now()/1e3|21600).toString(16),f=(Date.now()+Number(i)).toString(),l=atob(r.get("fm")).split("_")[0],c=Ui(`${f}|tars_mp|102`).toString();return`&wsSecret=${Ui([l,i,t.name,c,a].join("_")).toString()}&uuid=${n}&wsTime=${a}&uid=${i}&seqid=${f}&fs=${u}&ctype=tars_mp&t=102&ver=1&sv=2401310321`},qs=window.location.origin+"/api/",Ys="https://lemonlive66.deno.dev/api/",Ae=(t,i,e)=>(t=="douyin"&&(e?e.cookie=xe[t]:e={cookie:xe[t]}),Mn(`${i!="getCategories"&&window.location.origin.endsWith(".pages.dev")&&(t=="bilibili"||t=="douyu"&&i=="getRoomDetail")?Ys:qs}${t}/${i}${e?"?"+new URLSearchParams(e).toString():""}`)),ci=async t=>{const i=Object.keys(t.follows);if(!i.length)return Promise.resolve(!1);if(t.id=="douyin"){(await Zs(i,4,s=>Ae("douyin","getLiveStatus",{id:s}))).forEach((s,n)=>t.follows[i[n]].status=s[i[n]].status);return}await Ae(t.id,"getLiveStatus",{id:i.join(",")}).then(e=>Object.keys(e).forEach(s=>{t.follows[s].status=e[s].status}))},$t=(t,i)=>Mn(`https://lemonlive999.deno.dev/${t}`,{method:"POST",body:JSON.stringify(i)}),Ks=t=>$t("sync",{follows:Ht.compressToBase64(JSON.stringify(t)),token:ze.value}),Qs=()=>$t("sync",{get:!0,token:ze.value}).then(t=>JSON.parse(Ht.decompressFromBase64(t))),Xs=t=>$t("sign",t),eo=t=>$t("reset",t),rt=js({duration:3e3,position:"top"}),Mn=(t,i)=>fetch(t,i).then(async e=>{let s=await e.text();return s=JSON.parse(Ht.decompressFromBase64(s)),s.code!=200?(console.log(s.msg),rt.error(s.msg),Promise.reject(s.msg)):s.data},e=>{rt.error("请求异常!")});L(!0);const On={huya:"虎牙",bilibili:"哔哩",douyu:"斗鱼",douyin:"抖音"},Y=[{name:"虎牙直播",icon:"https://www.huya.com/favicon.ico",id:"huya",categories:L([]),categoryActive:L(0),recommend:{page:1,hasMore:!0,list:L([])},search:{page:1,hasMore:!0,list:L([])},follows:Me(bt("huya"))},{name:"斗鱼直播",icon:"https://www.douyu.com/favicon.ico",id:"douyu",categories:L([]),categoryActive:L(0),recommend:{page:1,hasMore:!0,list:L([])},search:{page:1,hasMore:!0,list:L([])},follows:Me(bt("douyu"))},{name:"抖音直播",icon:"https://www.douyin.com/favicon.ico",id:"douyin",categories:L([]),categoryActive:L(0),recommend:{page:1,hasMore:!0,list:L([])},search:{page:1,hasMore:!0,list:L([])},follows:Me(bt("douyin"))},{name:"哔哩直播",icon:"https://www.bilibili.com/favicon.ico",id:"bilibili",categories:L([]),categoryActive:L(0),recommend:{page:1,hasMore:!0,list:L([])},search:{page:1,hasMore:!0,list:L([])},follows:Me(bt("bilibili"))}],qe=["huya","douyu","douyin","bilibili"],ge=L(Le("volume",100)),he=L(Le("brightness",100)),xt=t=>{ge.value=t?Math.min(100,ge.value+5):Math.max(0,ge.value-5)},Fi=t=>{he.value=t?Math.min(200,he.value+10):Math.max(50,he.value-10)};function bt(t){const i=localStorage.getItem("follows-"+t);return i?JSON.parse(i):{}}function Rt(t){const i=Y.find(e=>e.id==t.siteId);return t.siteId=i.id,i.follows[t.roomId]={...t,stream:void 0,ws:void 0},localStorage.setItem("follows-"+t.siteId,JSON.stringify(i.follows)),Reflect.has(i.follows,t.roomId)}function fi(t,i){const e=Y.find(s=>s.id==t);return delete e.follows[i],localStorage.setItem("follows-"+t,JSON.stringify(e.follows)),Reflect.has(e.follows,i)}function to(){Y.forEach(t=>{for(const i in t.follows)delete t.follows[i];localStorage.removeItem("follows-"+t.id)})}async function Li(t,i){const e=t.categories;e.value.length||(e.value=await Ae(t.id,"getCategories"));for(const s of e.value)for(const n of s.list)if(n.cid==i)return n;return null}const N=Me(Le("dm-settings",{canvasOpen:!0,canvasFontsize:18,canvasGap:10,canvasOpacity:100,canvasRows:10,canvasSpeed:2.5,canvasColorOpen:!1,sideOpen:!0,sideFontsize:14,sideGap:2,sideColorOpen:!1,sideClean:100,colors:["#ffffff","#7e22ce","1d4ed8","#be185d","#fcd34d"],blockOpen:!1,blockWords:""}));Ye(()=>{Oe("dm-settings",N)});function Le(t,i){const e=localStorage.getItem(t);return e?JSON.parse(e):i}function Oe(t,i){localStorage.setItem(t,JSON.stringify(i))}const io=["#ffffff","#000000","#374151","#b91c1c","#f87171","#fdba74","#c2410c","#fcd34d","#b45309","#bef264","#4d7c0f","#86efac","#15803d","#5eead4","#0f766e","#67e8f9","#0e7490","#93c5fd","#1d4ed8","#d8b4fe","#7e22ce","#f0abfc","#a21caf","#f9a8d4","#be185d","#fda4af","#be123c"],Hi=X(()=>N.blockWords.length==0?[]:N.blockWords.split(" ").map(t=>new RegExp(t))),xe=Me(Le("cookies",{}));Ye(()=>Oe("cookies",xe));const se=L(0),Je=L(Le("show-chat",!0)),ot=L(Le("show-aside",!0));Ye(()=>Oe("show-chat",Je.value));Ye(()=>Oe("show-aside",ot.value));const nt=L(Le("user",{})),ze=L(Le("token","")),at=jt(Y,t=>({name:t.name,list:X(()=>Object.values(t.follows).sort(i=>i.status?-1:0))}));at.unshift({name:"全部",list:X(()=>Y.map(t=>Object.values(t.follows)).flat().sort(t=>t.status?-1:0))});const no=VueRouter.createRouter,so=VueRouter.createWebHistory,wi=VueRouter.useRoute,Pt=VueRouter.useRouter,oo=VueRouter.onBeforeRouteUpdate,ro={class:"text-sm pos-fixed bottom-0 left-0 right-0 md:py-2 b-t-solid b b-gray-7 md:b-r-solid md:top-0 md:right-auto flex justify-around md:flex-col md:justify-left bg-dark-7 z-10"},ao={class:"h-full scrolly md:px-3"},lo={key:0,src:"https://live.douyin.com","pos-absolute":"",width:"0",height:"0","op-0":"","b-0":"",style:{"z-index":"-10"}},uo=ne({__name:"App",setup(t){const i=[{icon:"i-ri-home-smile-line",link:"/"},{icon:"i-ri-apps-2-line",link:"/category"},{icon:"i-ri-heart-line",link:"/follow"},{icon:"i-ri-search-line",link:"/search"},{icon:"i-ri-user-smile-line",link:"/user"}],e=L(!0);Ke(()=>{document.querySelector("main").style.height=`calc(${window.innerHeight}px - 3.5rem)`,setTimeout(()=>e.value=!1,5e3)});const s=wi();return ye(s,()=>{const n=s.params.siteid;if(n==null)return;const r=qe.findIndex(u=>u==n);r!=-1&&(se.value=r)}),Ye(()=>{document.querySelectorAll(".v-toast").forEach(n=>{n.style.left=ot?"70px":"0"})}),(n,r)=>{const u=Mt("router-link"),a=Mt("router-view");return B(),D(oe,null,[Q(m("div",ro,[(B(),D(oe,null,me(i,f=>V(u,{to:f.link,class:Z(["hover:text-amber rounded-2 py-2 px-4 m-2",{"text-amber":n.$route.path==f.link}])},{default:q(()=>[m("div",{class:Z(f.icon)},null,2)]),_:2},1032,["to","class"])),64))],512),[[ke,b(ot)]]),m("main",{class:Z(["md:!h-100vh mx-2 md:mx-0 pt-2 box-border",{"md:ml-17.5":b(ot),"!h-100vh":!b(ot)}])},[m("div",ao,[V(a,null,{default:q(({Component:f})=>[(B(),ee(ks,{exclude:["play"]},[(B(),ee(ut(f)))],1024))]),_:1})])],2),b(e)?(B(),D("iframe",lo)):Ee("",!0)],64)}}}),co=t=>{const i=L(t);return[i,s=>i.value=s]},fo=/scroll|auto|overlay/i;function ho(t){return t.tagName!=="HTML"&&t.tagName!=="BODY"&&t.nodeType===1}function po(t,i=document.body){let e=t;for(;e&&e!==i&&ho(e);){const{overflowY:s}=window.getComputedStyle(e);if(fo.test(s))return e;e=e.parentNode}return i}function vo(t,i=document.body){const e=L();return Ke(()=>{t.value&&(e.value=po(t.value,i))}),e}const mo={key:0,class:"text-center"},wo={key:1,class:"text-center"},Gt=ne({__name:"list",props:{finshedText:{default:"没有更多了"},errorText:{default:"加载失败,点击重新加载"},immediate:{type:Boolean,default:!0},offset:{default:50}},emits:["load","refresh"],setup(t,{emit:i}){const e=t,s=L(0),[n,r]=co("normal"),u=L(),a=vo(u),f=i,l=()=>{if(s.value=a.value.scrollTop,n.value!="normal")return;a.value.scrollHeight-a.value.clientHeight-a.value.scrollTop<e.offset&&v()};Ke(()=>{e.immediate&&v(),a.value.addEventListener("scroll",l,{passive:!0})}),Bn(()=>{a.value.scrollTop=s.value,a.value.addEventListener("scroll",l)});const c=()=>{a.value.removeEventListener("scroll",l)};Ts(c),Lt(c);let p;const v=()=>{r("loading"),f("load",r),clearTimeout(p),p=setTimeout(()=>{Js(a.value)||f("load",r)},2e3)};return(_,I)=>(B(),D("div",{ref_key:"root",ref:u,class:"h-full select-none"},[Es(_.$slots,"default"),b(n)=="loading"?(B(),D("div",mo,"加载中...")):b(n)=="finshed"?(B(),D("div",wo,$(e.finshedText),1)):b(n)=="loaderror"?(B(),D("div",{key:2,class:"text-center cursor-pointer",onClick:v},$(e.errorText),1)):Ee("",!0)],512))}}),yo=["data-id","data-site","href"],go={class:"pos-relative text-fuchsia-5 rounded-t-2 w-full aspect-video"},_o={class:"mx-auto h-full rounded-2 select-none block"},xo={class:"pos-absolute bottom-0 right-0 px-2 py-1 rounded-tl-2 bg-dark-6"},bo={class:"line-height-none pos-absolute top-0 right-0 px-1 py-1 rounded-tr-1 rounded-bl-2 bg-dark-6"},ko={key:0,class:"rounded-2 text-white pos-absolute text-8 top-0 bottom-0 left-0 right-0 flex justify-center items-center bg-gray-7 bg-op-80"},Io={class:"px-2 text-truncate leading-normal"},So={class:"px-2 text-truncate leading-normal pb-2"},yi=ne({__name:"rooms",props:{list:{}},setup(t){let i;const e=Pt(),s=L(),n=a=>{clearTimeout(i),i=setTimeout(()=>{const f=u("id",a.target,s.value);if(!f)return;const l=u("site",a.target,s.value);e.push(`/${l}/play/${f}`)},300)},r=a=>{var p;clearTimeout(i);const f=u("id",a.target,s.value);if(!f)return;const c=`/${u("site",a.target,s.value)}/play/${f}`;(p=window.open(c,"_blank"))==null||p.location},u=(a,f,l)=>{if(f==l)return null;const c=f.dataset[a];return c||u(a,f.parentElement,l)};return(a,f)=>{const l=Ft("lazy");return a.list.value.length>0?(B(),D("div",{key:0,ref_key:"root",ref:s,class:"grid gap-4 p-2 justify-evenly cursor-pointer select-none grid-cols-2 md:grid-cols-3 xl:grid-cols-4 2xl:grid-cols-5",onClick:ae(n,["prevent"]),onDblclick:ae(r,["prevent"])},[(B(!0),D(oe,null,me(a.list.value,c=>(B(),D("a",{"data-id":c.roomId,"data-site":c.siteId,href:`/${c.siteId}/play/${c.roomId}`,key:`${c.siteId}-${c.roomId}`,class:"shadow rounded-2 b-2px b-solid b-transparent hover:b-amber overflow-hidden"},[m("div",go,[Q(m("img",_o,null,512),[[l,c.cover]]),m("div",xo,$(c.category),1),m("div",bo,[f[0]||(f[0]=m("div",{class:"i-mdi-fire"},null,-1)),m("span",null,$(c.online),1)]),c.status?Ee("",!0):(B(),D("div",ko," 未开播 "))]),m("div",Io,$(c.title),1),m("div",So,$(c.nickname),1)],8,yo))),128))],544)):Ee("",!0)}}}),To={class:"h-full"},Bo={class:"py-1 px-2 text-lg text-center relative"},Eo={class:"hover:text-amber"},Ao={key:0,class:"h-[calc(100%-3.25rem)] scrolly"},Co=ne({__name:"categoryRooms",setup(t){const i=wi(),e=L(""),s=L(),n={list:L([]),page:1,hasMore:!0},r=l=>{const{site:c,id:p}=i.meta;Ae(c.id,"getCategoryRooms",{id:p,pid:s.value,page:n.page}).then(v=>{if(n.list.value=n.list.value.concat(v.list),n.hasMore=v.hasMore,xe[c.id]||(xe[c.id]=v.cookie),!v.hasMore)return l("finshed");n.page++,l("normal")},v=>{e.value=v,l("loaderror")})},u=L(!1),a=()=>{document.querySelector("#goTop").click(),u.value=!0;const{site:l,id:c}=i.meta;Ae(l.id,"getCategoryRooms",{id:c,pid:s.value,page:n.page}).then(p=>{n.list.value=p.list,n.hasMore=p.hasMore,n.page++,xe[l.id]||(xe[l.id]=p.cookie)},p=>{e.value=p}).finally(()=>u.value=!1)};let f=i.fullPath;return Li(i.meta.site,i.meta.id).then(l=>{e.value=(l==null?void 0:l.name)||null,s.value=l==null?void 0:l.pid}),Bn(function(){f!=i.fullPath&&(f=i.fullPath,Li(i.meta.site,i.meta.id).then(l=>{e.value=(l==null?void 0:l.name)||null,s.value=l==null?void 0:l.pid}),n.list.value=[],n.page=1,n.hasMore=!0)}),(l,c)=>{var _;const p=yi,v=Gt;return B(),D("div",To,[m("div",Bo,[m("div",{onClick:c[0]||(c[0]=(...I)=>l.$router.back&&l.$router.back(...I)),class:"i-ri-arrow-left-line hover:text-amber absolute left-2"}),m("div",{onClick:a,class:Z(["i-ri-refresh-line hover:text-amber absolute right-4 md:right-unset md:left-12",{"animate-spin":b(u)}])},null,2),m("span",Eo,$(`${(_=b(i).meta.site)==null?void 0:_.name} ${b(e)==null?"分区不存在":b(e)==""?"加载中":b(e)}`),1)]),b(e)?(B(),D("div",Ao,[(B(),ee(v,{key:b(f),onLoad:r},{default:q(()=>[V(p,{list:n.list},null,8,["list"])]),_:1}))])):Ee("",!0)])}}}),Rn=Symbol("tabs"),No=(t,i)=>{const e=Me([]);return Cs(t,Object.assign({link:r=>{r.proxy&&e.push(r.proxy)},unlink:r=>{const u=e.indexOf(r.proxy);e.splice(u,1)},children:e},i)),e},Un=t=>{const i=Ns(t);if(i==null)return{parent:i,index:L(-1)};const e=Ms(),{link:s,unlink:n,children:r}=i;s(e),Bs(()=>n(e));const u=X(()=>r.indexOf(e.proxy));return{parent:i,children:r,index:u}},Mo={class:"h-full box-border"},Oo={class:"w-full box-border text-sm sm:text-base"},Ro=["onClick"],Uo={class:"h-[calc(100%-2rem)] scrolly box-border pt-1"},pt=ne({__name:"tabs",props:ct({link:{type:Boolean,default:!1},lazy:{type:Boolean,default:!0},grow:{type:Boolean,default:!1},swipeable:{type:Boolean,default:!1},swipeloop:{type:Boolean,default:!0},justify:{default:"justify-center"}},{active:{default:0},activeModifiers:{}}),emits:ct(["tabClick"],["update:active"]),setup(t,{emit:i}){const e=ht(t,"active"),s=t,n=i,r=l=>{e.value=l,n("tabClick",l)},u=No(Rn,{active:e,props:s}),a=X(()=>jt(u,l=>l.title)),f=mi();return(l,c)=>{const p=Mt("router-link");return B(),D("div",Mo,[m("div",Oo,[m("div",{class:Z(["flex p1 sm:gap-1 text-center h-8 box-border lg:justify-center scrollx",[b(u).length>5||l.grow?"":l.justify]])},[s.link?(B(!0),D(oe,{key:0},me(b(a),(v,_)=>(B(),ee(p,{class:Z(["px-1 sm:px-2 box-border shrink-0 rounded py-1 line-height-none text-centercursor-pointer hover:text-amber cursor-pointer",{"text-amber":e.value==_,grow:l.grow}]),to:b(u)[_].href},{default:q(()=>[Ct($(v),1)]),_:2},1032,["class","to"]))),256)):(B(!0),D(oe,{key:1},me(b(a),(v,_)=>(B(),D("a",{class:Z(["px-1 sm:px-2 box-border shrink-0 rounded py-1 line-height-none text-centercursor-pointer hover:text-amber cursor-pointer",{"text-amber":e.value==_,grow:l.grow}]),onClick:I=>r(_)},$(v),11,Ro))),256))],2)]),m("div",Uo,[(B(),ee(ut(f.default)))])])}}}),Do=Symbol("swipe"),Fo={class:"w-full h-full shrink-0 pos-relative"},Lo=ne({__name:"swipeItem",emits:["inited"],setup(t,{emit:i}){const e=L(!1),{parent:s,children:n,index:r}=Un(Do),u=mi(),a=i,f=X(()=>(s==null?void 0:s.active.value)==r.value?(e.value||(e.value=!0,a("inited",r.value)),!0):r.value==(s.active.value==0?n.length-1:s.active.value-1)||r.value==(s.active.value==n.length-1?0:s.active.value+1)),l=X(()=>f.value||e.value||!(s!=null&&s.props.lazy)?u.default:null);return(c,p)=>Q((B(),D("div",Fo,[(B(),ee(ut(b(l))))],512)),[[ke,b(f)]])}}),Ho={class:"scrolly h-full w-full shrink-0"},vt=ne({__name:"tab",props:{title:{},href:{}},emits:["inited"],setup(t,{expose:i,emit:e}){const s=t,n=L(!1),r=mi(),{parent:u,index:a,children:f}=Un(Rn),l=e,c=X(()=>(u==null?void 0:u.active.value)==a.value?(n.value||(n.value=!0,l("inited",a.value)),!0):(u==null?void 0:u.props.swipeable)&&(a.value==(u.active.value==0?f.length-1:u.active.value-1)||a.value==(u.active.value==f.length-1?0:u.active.value+1))),p=X(()=>c.value||u!=null&&u.props.swipeable||n.value||!(u!=null&&u.props.lazy)?r.default:null);return i({title:s.title}),(v,_)=>{var E,C;const I=Lo;return Q((B(),D("div",Ho,[(E=b(u))!=null&&E.props.swipeable?(B(),ee(I,{key:0},{default:q(()=>[(B(),ee(ut(b(p))))]),_:1})):(B(),ee(ut(b(p)),{key:1}))],512)),[[ke,b(c)||((C=b(u))==null?void 0:C.props.swipeable)]])}}}),zo={key:0,class:"text-center"},jo={class:"pb-2 grid gap-4 px-4 md:px-2 grid-cols-4 sm:grid-cols-6 md:grid-cols-8 lg:grid-cols-10 xl:grid-cols-15 2xl:grid-cols-18"},$o={class:"w-full aspect-ratio-square rounded"},Po={class:"w-full text-truncate text-xs md:text-sm text-center"},Go=ne({__name:"category",setup(t){const i=X(()=>Y[se.value].id),e=L(),s=n=>{Y[n].categories.value.length||(e.value="加载中...",Ae(i.value,"getCategories").then(r=>{e.value=null,Y[n].categories.value=r},r=>e.value=r))};return(n,r)=>{const u=Mt("router-link"),a=vt,f=pt,l=Ft("lazy");return B(),ee(f,{active:b(se),"onUpdate:active":r[0]||(r[0]=c=>je(se)?se.value=c:null),link:!0,class:"pt-1"},{default:q(()=>[(B(!0),D(oe,null,me(b(Y),c=>(B(),ee(a,{title:c.name,href:`/${c.id}/category`,onInited:s,key:c.id},{default:q(()=>[b(e)?(B(),D("div",zo,$(b(e)),1)):(B(),ee(f,{key:1,active:c.categoryActive.value,"onUpdate:active":p=>c.categoryActive.value=p},{default:q(()=>[(B(!0),D(oe,null,me(c.categories.value,p=>(B(),ee(a,{title:p.name,key:p.id},{default:q(()=>[m("div",jo,[(B(!0),D(oe,null,me(p.list,v=>(B(),ee(u,{to:`/${c.id}/category/${v.cid}`,class:"cursor-pointer"},{default:q(()=>[Q(m("img",$o,null,512),[[l,v.pic]]),m("div",Po,$(v.name),1)]),_:2},1032,["to"]))),256))])]),_:2},1032,["title"]))),128))]),_:2},1032,["active","onUpdate:active"]))]),_:2},1032,["title","href"]))),128))]),_:1},8,["active"])}}}),Vo={class:"text-center py-1"},Wo={class:"w-60% max-w-md pos-relative inline-block"},Jo={class:"h-[calc(100%-3rem)]"},Zo={key:1},qo={key:1},Yo=ne({__name:"search",setup(t){const i=L(""),e=X(()=>Y[se.value]),s=L(),n=()=>{if(!i.value)return Promise.resolve();const c=e.value.search;c.list.value=[],c.page=1,c.hasMore=!0,s.value="搜索中...";const p=e.value.id;return Ae(p,"searchRooms",{page:c.page,kw:i.value}).then(v=>{c.list.value=v.list,c.hasMore=v.hasMore,c.page+=1,s.value="finished",xe[p]||(xe[p]=v.cookie)},v=>s.value=v)},r=c=>{const p=e.value.search,v=e.value.id;c("loading"),Ae(v,"searchRooms",{page:p.page,kw:i.value}).then(_=>{if(p.list.value=p.list.value.concat(_.list),p.hasMore=_.hasMore,xe[v]||(xe[v]=_.cookie),!p.hasMore)return c("finshed");p.page+=1,c("normal")},_=>{c("loaderror")})},u=c=>{a.push(`/${qe[c]}/search`),!f()&&Y[c].search.page==1&&n()},a=Pt(),f=()=>{if(i.value)return/^[\d]*$/.test(i.value)?(a.push(`/play/${e.value.id}/${i.value}`),!0):!1},l=()=>{f()||(Y.forEach(c=>c.search.page=1),n())};return(c,p)=>{const v=yi,_=Gt,I=vt,E=pt;return B(),D(oe,null,[m("div",Vo,[m("div",Wo,[Q(m("input",{class:"md:text-4 box-border w-full py-2.5 pl-3 pr-9 text-white bg-transparent b-1 b-style-groove b-green rounded-6 outline-0",type:"text","onUpdate:modelValue":p[0]||(p[0]=C=>je(i)?i.value=C:null),onKeydown:Is(l,["enter"]),placeholder:"请输入房间号或关键字"},null,544),[[Ot,b(i),void 0,{trim:!0}]]),m("div",{class:"i-ri-search-line top-50% absolute right-3",onClick:l,style:{transform:"translateY(-50%)"}})])]),m("div",Jo,[V(E,{active:b(se),"onUpdate:active":p[1]||(p[1]=C=>je(se)?se.value=C:null),onTabClick:u},{default:q(()=>[(B(!0),D(oe,null,me(b(Y),C=>(B(),ee(I,{title:C.name,key:C.id},{default:q(()=>[b(s)=="finished"?(B(),D(oe,{key:0},[C.search.list.value.length?(B(),ee(_,{key:0,onLoad:r},{default:q(()=>[V(v,{list:C.search.list},null,8,["list"])]),_:2},1024)):(B(),D("div",Zo," 什么也没有找到 "))],64)):(B(),D("div",qo,$(b(s)),1))]),_:2},1032,["title"]))),128))]),_:1},8,["active"])])],64)}}}),Ko=["data-id","data-site"],Qo={class:"pos-relative text-fuchsia-5 rounded-t-2 w-full aspect-video"},Xo={class:"blockmx-auto text-center h-full rounded-2 select-none"},er={class:"pos-absolute bottom-0 right-0 px-2 py-1 rounded-tl-2 bg-dark-6"},tr={class:"line-height-none pos-absolute top-0 right-0 px-1 py-1 rounded-tr-1 rounded-bl-2 bg-dark-6"},ir={key:0,class:"rounded-2 text-white pos-absolute text-8 top-0 bottom-0 left-0 right-0 flex justify-center items-center bg-gray-7 bg-op-80"},nr=["onClick"],sr={class:"px-2 text-truncate leading-normal"},or={class:"px-2 pb-2 flex items-center justify-between"},rr={class:"flex items-center grow"},ar=["src"],lr={class:"text-truncate mx-1 w-2 grow"},ur=ne({__name:"rooms2",props:{list:{}},setup(t){let i;const e=Pt(),s=L(),n=a=>{clearTimeout(i),i=setTimeout(()=>{const f=u("id",a.target,s.value);if(!f)return;const l=u("site",a.target,s.value);e.push(`/${l}/play/${f}`)},300)},r=a=>{var p;clearTimeout(i);const f=u("id",a.target,s.value);if(!f)return;const c=`/${u("site",a.target,s.value)}/play/${f}`;(p=window.open(c,"_blank"))==null||p.location},u=(a,f,l)=>{if(f==l)return null;const c=f.dataset[a];return c||u(a,f.parentElement,l)};return(a,f)=>{const l=Ft("lazy");return a.list.value.length>0?(B(),D("div",{key:0,ref_key:"root",ref:s,class:"grid gap-4 p-2 justify-evenly cursor-pointer select-none grid-cols-2 md:grid-cols-3 xl:grid-cols-4 2xl:grid-cols-5",onClick:n,onDblclick:ae(r,["prevent"])},[(B(!0),D(oe,null,me(a.list.value,c=>(B(),D("div",{"data-id":c.roomId,"data-site":c.siteId,key:`${c.siteId}-${c.roomId}`,class:"shadow rounded-2 b-2px b-solid b-transparent hover:b-amber overflow-hidden"},[m("div",Qo,[Q(m("img",Xo,null,512),[[l,c.cover]]),m("div",er,$(c.category),1),m("div",tr,[f[0]||(f[0]=m("div",{class:"i-mdi-fire"},null,-1)),m("span",null,$(c.online),1)]),c.status?Ee("",!0):(B(),D("div",ir," 未开播 ")),m("div",{class:"pos-absolute z-1 left-2 top-2 text-green-5 w-6 h-6 hover:text-amber i-mdi-heart-off-outline",onClick:ae(p=>b(fi)(c.siteId,c.roomId),["stop"])},null,8,nr)]),m("div",sr,$(c.title),1),m("div",or,[m("div",rr,[m("img",{src:c.avatar,alt:"",class:"w-6 h-6 rounded-4"},null,8,ar),m("div",lr,$(c.nickname),1)]),m("div",null,$(b(On)[c.siteId]),1)])],8,Ko))),128))],544)):Ee("",!0)}}}),cr={class:"flex justify-center items-center"},fr={class:"h-[calc(100%-3rem)]"},dr=ne({__name:"follow",setup(t){const i=L(0),e=L(!1),s=()=>{var a;if(e.value)return;const u=i.value;e.value=!0,u==0?Promise.all(jt(Y,ci)).finally(n):(a=ci(Y[u-1]))==null||a.finally(n)},n=()=>setTimeout(()=>e.value=!1,300);s();const r=u=>u("finshed");return(u,a)=>{const f=ur,l=Gt,c=vt,p=pt;return B(),D(oe,null,[m("div",cr,[a[1]||(a[1]=m("div",null,"我的关注",-1)),m("div",{onClick:s,class:Z(["rounded-6 mx-4 hover:text-amber i-ri-refresh-line",{"animate-spin":b(e)}])},null,2)]),m("div",fr,[V(p,{active:b(i),"onUpdate:active":a[0]||(a[0]=v=>je(i)?i.value=v:null)},{default:q(()=>[(B(!0),D(oe,null,me(b(at),v=>(B(),ee(c,{title:v.name},{default:q(()=>[V(l,{onLoad:r,"finshed-text":""},{default:q(()=>[V(f,{list:v.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["title"]))),256))]),_:1},8,["active"])])],64)}}}),hr=ne({__name:"index",setup(t){const i=X(()=>Y[se.value].id),e=s=>{const n=Y[se.value].recommend;Ae(i.value,"getRecommendRooms",{page:n.page}).then(r=>{if(n.list.value=n.list.value.concat(r.list),n.hasMore=r.hasMore,xe[i.value]||(xe[i.value]=r.cookie),!n.hasMore)return s("finshed");n.page++,s("normal")},()=>s("loaderror"))};return(s,n)=>{const r=yi,u=Gt,a=vt,f=pt;return B(),ee(f,{active:b(se),"onUpdate:active":n[0]||(n[0]=l=>je(se)?se.value=l:null),link:!0,class:"pt-1"},{default:q(()=>[(B(!0),D(oe,null,me(b(Y),l=>(B(),ee(a,{href:`/${l.id}`,key:l.id,title:l.name,class:"pos-relative"},{default:q(()=>[V(u,{onLoad:e,class:"h-full"},{default:q(()=>[V(r,{list:l.recommend.list},null,8,["list"])]),_:2},1024)]),_:2},1032,["href","title"]))),128))]),_:1},8,["active"])}}}),pr=ne({__name:"switch",props:{value:{type:Boolean,required:!0},valueModifiers:{}},emits:["update:value"],setup(t){const i=ht(t,"value");return(e,s)=>(B(),D("div",{onClick:s[0]||(s[0]=()=>i.value=!i.value),class:Z(["pos-relative w-12 inline-block cursor-pointer rounded-6 h-6",[i.value?"bg-amber":"bg-gray-4"]]),style:{transition:"background-color .3s"}},[m("div",{class:"w-6 h-full rounded-6 bg-white",style:Ze([{transition:"transform .3s"},i.value?"transform:translateX(1.5rem)":""])},null,4)],2))}}),vr={class:"rounded-4 flex bg-gray-7 w-min p-2 py-1 gap-2"},mr=ne({__name:"stepper",props:ct({max:{},min:{},step:{}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(t){const i=t,e=ht(t,"value"),s=()=>e.value=Math.min(e.value+i.step,i.max),n=()=>e.value=Math.max(e.value-i.step,i.min);return(r,u)=>(B(),D("div",vr,[m("div",{class:"i-ri-subtract-fill",onClick:n}),m("div",null,$(e.value),1),m("div",{class:"i-ri-add-fill",onClick:s})]))}});function wr(){try{return document.createEvent("TouchEvent"),!0}catch{return!1}}const Nt=wr(),yr=t=>Nt?t.touches==null?t:t.touches[0]||t.changedTouches[0]:t,gr=ne({__name:"slider",props:ct({max:{default:100},min:{default:0},width:{default:30},height:{default:100}},{value:{required:!0},valueModifiers:{}}),emits:["update:value"],setup(t){const i=t,e=ht(t,"value"),s=L(),n=i.width<i.height;let r;const u=p=>{p.stopPropagation(),l(p),document.addEventListener("mousemove",l,!0),document.addEventListener("mouseup",c,!0)},a=X(()=>(e.value-i.min)/(i.max-i.min)*100),f=X(()=>{const p=100-a.value,v=`top:${p}%`,_=`left:${p}%`;return n?{loaded:v,indicator:v}:{loaded:`${_};transform:translateX(-100%)`,indicator:_}}),l=p=>{p.stopPropagation(),p=yr(p);const _=100-(Math.min(n?r.height:r.width,Math.max(0,n?p.clientY-r.y:p.clientX-r.x))/(n?r.height:r.width)*100|0);e.value=((i.max-i.min)*_|0)/100+i.min|0},c=p=>{p.stopPropagation(),document.removeEventListener("mousemove",l,!0),document.removeEventListener("mouseup",c,!0)};return Ke(()=>{r=s.value.getBoundingClientRect(),s.value.addEventListener("mousedown",u,!0)}),Lt(()=>{s.value.removeEventListener("mousedown",u,!0)}),(p,v)=>(B(),D("div",{class:Z(["cursor-pointer flex justify-center",n?" py-4 ":"px-4"]),style:Ze({width:`${i.width}px`,height:`${i.height}px`})},[m("div",{ref_key:"root",ref:s,onClick:l,class:"w-full h-full pos-relative flex justify-center items-center"},[m("div",{class:Z(["bg-gray pos-relative overflow-hidden",n?"h-full w-2px":"w-full h-2px"])},[m("div",{class:"w-full bg-amber h-full pos-absolute",style:Ze(b(f).loaded)},null,4)],2),m("div",{class:Z(["pos-absolute w-12px h-12px bg-amber rounded-2",n?"-mt-6px":"-ml-6px"]),style:Ze(b(f).indicator)},null,6)],512)],6))}}),_r={key:0,class:"z-1 fixed top-0 bottom-0 left-0 right-0 bg-transparent","data-index":"-1"},xr={class:"p-1 hover:text-amber","data-index":"-1"},br={class:"left-50% text-center z-1 pos-absolute top-0 w-max",style:{transform:"translate3d(-50%,-100%,0)"}},kr=["data-index"],Ir=ne({__name:"select",props:ct(["list"],{active:{required:!0},activeModifiers:{}}),emits:["update:active"],setup(t){const i=ht(t,"active"),e=L(!1),s=n=>{const r=n.target.dataset.index;r&&(r!="-1"&&(i.value=parseInt(r)),e.value=!e.value)};return(n,r)=>(B(),D("div",{onClick:s,class:"inline-block pos-relative cursor-pointer text-center"},[b(e)?(B(),D("div",_r)):Ee("",!0),m("div",xr,$(t.list[i.value]),1),Q(m("div",br,[(B(!0),D(oe,null,me(t.list,(u,a)=>(B(),D("div",{"data-index":a,class:Z([{"text-amber":a==i.value},"p-1 hover:text-amber"])},$(u),11,kr))),256))],512),[[ke,b(e)]])]))}}),zi="data:image/png;base64,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",ji="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAMAAACahl6sAAAArlBMVEUAAAD///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////8tivQqAAAAOXRSTlMAQL+AVSFwReurxLHcZuZhaxvx9dKPfhIHXc6LUC4LeVmgOMiFNCbXm5N04LeoSzz7pBYru5YPA5jd4ld+AAAKR0lEQVR42uzba3OiMBQG4INXvKGiUuttvaPVarW27vv//9h21umCJlZOBMPO8Hy2Dm+TcMIJUiKRSCQSiUQikUj8p8bL1JdMm5RtXr++YGeQVpkUTswlqUm7OOmkSZ8MPAW1HPDoS5KBX0EtRwySHMs40yKuCs5tSIseLmSIZ2biXIm0KOGCWyeWAxCLIYFgRBxTCJakA0QV1swUrUkHiKx3CipbhuiVdICAcw/eQWJKOpQgkaNgXvAlJou9B4nGjIIw3iBRJC2OZaiu18EEMhnSIwcZh25bQuaDdClAJk+3PEOmOCBd3k1IFNu3/syChD0jfSqQ6arc7lAlnXaQ6dFPHMi0SKvsChLNPV23gUzqSHpVIfObrto3IWH3SbcRZJ6Znx+SdvUyJFZZkqtBpksxMITMjqTGDUikKBY+IFMjiXYKEvacYuGpCQmzT6JuXBfISQ8yTRIMY7dA2vV+PlNLT7vLxei1sD5AJiUoSz9Weh0tp07tuWfM5vXPIz1CNl/pFiZlGxFqmOVmsdCt5LMUjf7LGg9WqryHnqLVhBadVp/CM2+9QZu31pzCUZ/a0Mqe1ikEWxfalYd0twxioUV3chATE7pLCvFBd5ggRsqk7IBYWas3d5kaljtJBTRxrQaYCqSkCyn77FoPhUXLyVV7xiz71Cam9lN2ZvSqOae1KBxSPkXXDO/etYXI/TDq9CDjXAGCHvGtcWk0psfavuJC55O4arhQytPjZex7J9d+hTNWjbSYr3Buc9+AFLKkyxpnXu8q6QXSaIEzY+Iw4pPjsp4t1XtVnSfSKg8/mzPL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",kt=window.Flv,It=window.Hls;function Qe(t){let i=t.length;for(;--i>=0;)t[i]=0}const Sr=3,Tr=258,Dn=29,Br=256,Er=Br+1+Dn,Fn=30,Ar=512,Cr=new Array((Er+2)*2);Qe(Cr);const Nr=new Array(Fn*2);Qe(Nr);const Mr=new Array(Ar);Qe(Mr);const Or=new Array(Tr-Sr+1);Qe(Or);const Rr=new Array(Dn);Qe(Rr);const Ur=new Array(Fn);Qe(Ur);const Dr=(t,i,e,s)=>{let n=t&65535|0,r=t>>>16&65535|0,u=0;for(;e!==0;){u=e>2e3?2e3:e,e-=u;do n=n+i[s++]|0,r=r+n|0;while(--u);n%=65521,r%=65521}return n|r<<16|0};var di=Dr;const Fr=()=>{let t,i=[];for(var e=0;e<256;e++){t=e;for(var s=0;s<8;s++)t=t&1?3988292384^t>>>1:t>>>1;i[e]=t}return i},Lr=new Uint32Array(Fr()),Hr=(t,i,e,s)=>{const n=Lr,r=s+e;t^=-1;for(let u=s;u<r;u++)t=t>>>8^n[(t^i[u])&255];return t^-1};var Be=Hr,hi={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},Ln={Z_NO_FLUSH:0,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_DEFLATED:8};const zr=(t,i)=>Object.prototype.hasOwnProperty.call(t,i);var jr=function(t){const i=Array.prototype.slice.call(arguments,1);for(;i.length;){const e=i.shift();if(e){if(typeof e!="object")throw new TypeError(e+"must be non-object");for(const s in e)zr(e,s)&&(t[s]=e[s])}}return t},$r=t=>{let i=0;for(let s=0,n=t.length;s<n;s++)i+=t[s].length;const e=new Uint8Array(i);for(let s=0,n=0,r=t.length;s<r;s++){let u=t[s];e.set(u,n),n+=u.length}return e},Hn={assign:jr,flattenChunks:$r};let zn=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{zn=!1}const ft=new Uint8Array(256);for(let t=0;t<256;t++)ft[t]=t>=252?6:t>=248?5:t>=240?4:t>=224?3:t>=192?2:1;ft[254]=ft[254]=1;var Pr=t=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(t);let i,e,s,n,r,u=t.length,a=0;for(n=0;n<u;n++)e=t.charCodeAt(n),(e&64512)===55296&&n+1<u&&(s=t.charCodeAt(n+1),(s&64512)===56320&&(e=65536+(e-55296<<10)+(s-56320),n++)),a+=e<128?1:e<2048?2:e<65536?3:4;for(i=new Uint8Array(a),r=0,n=0;r<a;n++)e=t.charCodeAt(n),(e&64512)===55296&&n+1<u&&(s=t.charCodeAt(n+1),(s&64512)===56320&&(e=65536+(e-55296<<10)+(s-56320),n++)),e<128?i[r++]=e:e<2048?(i[r++]=192|e>>>6,i[r++]=128|e&63):e<65536?(i[r++]=224|e>>>12,i[r++]=128|e>>>6&63,i[r++]=128|e&63):(i[r++]=240|e>>>18,i[r++]=128|e>>>12&63,i[r++]=128|e>>>6&63,i[r++]=128|e&63);return i};const Gr=(t,i)=>{if(i<65534&&t.subarray&&zn)return String.fromCharCode.apply(null,t.length===i?t:t.subarray(0,i));let e="";for(let s=0;s<i;s++)e+=String.fromCharCode(t[s]);return e};var Vr=(t,i)=>{const e=i||t.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(t.subarray(0,i));let s,n;const r=new Array(e*2);for(n=0,s=0;s<e;){let u=t[s++];if(u<128){r[n++]=u;continue}let a=ft[u];if(a>4){r[n++]=65533,s+=a-1;continue}for(u&=a===2?31:a===3?15:7;a>1&&s<e;)u=u<<6|t[s++]&63,a--;if(a>1){r[n++]=65533;continue}u<65536?r[n++]=u:(u-=65536,r[n++]=55296|u>>10&1023,r[n++]=56320|u&1023)}return Gr(r,n)},Wr=(t,i)=>{i=i||t.length,i>t.length&&(i=t.length);let e=i-1;for(;e>=0&&(t[e]&192)===128;)e--;return e<0||e===0?i:e+ft[t[e]]>i?e:i},pi={string2buf:Pr,buf2string:Vr,utf8border:Wr};function Jr(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}var Zr=Jr;const St=16209,qr=16191;var Yr=function(i,e){let s,n,r,u,a,f,l,c,p,v,_,I,E,C,A,R,S,k,x,w,h,y,z,H;const U=i.state;s=i.next_in,z=i.input,n=s+(i.avail_in-5),r=i.next_out,H=i.output,u=r-(e-i.avail_out),a=r+(i.avail_out-257),f=U.dmax,l=U.wsize,c=U.whave,p=U.wnext,v=U.window,_=U.hold,I=U.bits,E=U.lencode,C=U.distcode,A=(1<<U.lenbits)-1,R=(1<<U.distbits)-1;e:do{I<15&&(_+=z[s++]<<I,I+=8,_+=z[s++]<<I,I+=8),S=E[_&A];t:for(;;){if(k=S>>>24,_>>>=k,I-=k,k=S>>>16&255,k===0)H[r++]=S&65535;else if(k&16){x=S&65535,k&=15,k&&(I<k&&(_+=z[s++]<<I,I+=8),x+=_&(1<<k)-1,_>>>=k,I-=k),I<15&&(_+=z[s++]<<I,I+=8,_+=z[s++]<<I,I+=8),S=C[_&R];i:for(;;){if(k=S>>>24,_>>>=k,I-=k,k=S>>>16&255,k&16){if(w=S&65535,k&=15,I<k&&(_+=z[s++]<<I,I+=8,I<k&&(_+=z[s++]<<I,I+=8)),w+=_&(1<<k)-1,w>f){i.msg="invalid distance too far back",U.mode=St;break e}if(_>>>=k,I-=k,k=r-u,w>k){if(k=w-k,k>c&&U.sane){i.msg="invalid distance too far back",U.mode=St;break e}if(h=0,y=v,p===0){if(h+=l-k,k<x){x-=k;do H[r++]=v[h++];while(--k);h=r-w,y=H}}else if(p<k){if(h+=l+p-k,k-=p,k<x){x-=k;do H[r++]=v[h++];while(--k);if(h=0,p<x){k=p,x-=k;do H[r++]=v[h++];while(--k);h=r-w,y=H}}}else if(h+=p-k,k<x){x-=k;do H[r++]=v[h++];while(--k);h=r-w,y=H}for(;x>2;)H[r++]=y[h++],H[r++]=y[h++],H[r++]=y[h++],x-=3;x&&(H[r++]=y[h++],x>1&&(H[r++]=y[h++]))}else{h=r-w;do H[r++]=H[h++],H[r++]=H[h++],H[r++]=H[h++],x-=3;while(x>2);x&&(H[r++]=H[h++],x>1&&(H[r++]=H[h++]))}}else if(k&64){i.msg="invalid distance code",U.mode=St;break e}else{S=C[(S&65535)+(_&(1<<k)-1)];continue i}break}}else if(k&64)if(k&32){U.mode=qr;break e}else{i.msg="invalid literal/length code",U.mode=St;break e}else{S=E[(S&65535)+(_&(1<<k)-1)];continue t}break}}while(s<n&&r<a);x=I>>3,s-=x,I-=x<<3,_&=(1<<I)-1,i.next_in=s,i.next_out=r,i.avail_in=s<n?5+(n-s):5-(s-n),i.avail_out=r<a?257+(a-r):257-(r-a),U.hold=_,U.bits=I};const We=15,$i=852,Pi=592,Gi=0,Xt=1,Vi=2,Kr=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),Qr=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),Xr=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),ea=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]),ta=(t,i,e,s,n,r,u,a)=>{const f=a.bits;let l=0,c=0,p=0,v=0,_=0,I=0,E=0,C=0,A=0,R=0,S,k,x,w,h,y=null,z;const H=new Uint16Array(We+1),U=new Uint16Array(We+1);let we=null,Re,Ge,re;for(l=0;l<=We;l++)H[l]=0;for(c=0;c<s;c++)H[i[e+c]]++;for(_=f,v=We;v>=1&&H[v]===0;v--);if(_>v&&(_=v),v===0)return n[r++]=1<<24|64<<16|0,n[r++]=1<<24|64<<16|0,a.bits=1,0;for(p=1;p<v&&H[p]===0;p++);for(_<p&&(_=p),C=1,l=1;l<=We;l++)if(C<<=1,C-=H[l],C<0)return-1;if(C>0&&(t===Gi||v!==1))return-1;for(U[1]=0,l=1;l<We;l++)U[l+1]=U[l]+H[l];for(c=0;c<s;c++)i[e+c]!==0&&(u[U[i[e+c]]++]=c);if(t===Gi?(y=we=u,z=20):t===Xt?(y=Kr,we=Qr,z=257):(y=Xr,we=ea,z=0),R=0,c=0,l=p,h=r,I=_,E=0,x=-1,A=1<<_,w=A-1,t===Xt&&A>$i||t===Vi&&A>Pi)return 1;for(;;){Re=l-E,u[c]+1<z?(Ge=0,re=u[c]):u[c]>=z?(Ge=we[u[c]-z],re=y[u[c]-z]):(Ge=96,re=0),S=1<<l-E,k=1<<I,p=k;do k-=S,n[h+(R>>E)+k]=Re<<24|Ge<<16|re|0;while(k!==0);for(S=1<<l-1;R&S;)S>>=1;if(S!==0?(R&=S-1,R+=S):R=0,c++,--H[l]===0){if(l===v)break;l=i[e+u[c]]}if(l>_&&(R&w)!==x){for(E===0&&(E=_),h+=p,I=l-E,C=1<<I;I+E<v&&(C-=H[I+E],!(C<=0));)I++,C<<=1;if(A+=1<<I,t===Xt&&A>$i||t===Vi&&A>Pi)return 1;x=R&w,n[x]=_<<24|I<<16|h-r|0}}return R!==0&&(n[h+R]=l-E<<24|64<<16|0),a.bits=_,0};var lt=ta;const ia=0,jn=1,$n=2,{Z_FINISH:Wi,Z_BLOCK:na,Z_TREES:Tt,Z_OK:$e,Z_STREAM_END:sa,Z_NEED_DICT:oa,Z_STREAM_ERROR:Ie,Z_DATA_ERROR:Pn,Z_MEM_ERROR:Gn,Z_BUF_ERROR:ra,Z_DEFLATED:Ji}=Ln,Vt=16180,Zi=16181,qi=16182,Yi=16183,Ki=16184,Qi=16185,Xi=16186,en=16187,tn=16188,nn=16189,Ut=16190,Ce=16191,ei=16192,sn=16193,ti=16194,on=16195,rn=16196,an=16197,ln=16198,Bt=16199,Et=16200,un=16201,cn=16202,fn=16203,dn=16204,hn=16205,ii=16206,pn=16207,vn=16208,J=16209,Vn=16210,Wn=16211,aa=852,la=592,ua=15,ca=ua,mn=t=>(t>>>24&255)+(t>>>8&65280)+((t&65280)<<8)+((t&255)<<24);function fa(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const Pe=t=>{if(!t)return 1;const i=t.state;return!i||i.strm!==t||i.mode<Vt||i.mode>Wn?1:0},Jn=t=>{if(Pe(t))return Ie;const i=t.state;return t.total_in=t.total_out=i.total=0,t.msg="",i.wrap&&(t.adler=i.wrap&1),i.mode=Vt,i.last=0,i.havedict=0,i.flags=-1,i.dmax=32768,i.head=null,i.hold=0,i.bits=0,i.lencode=i.lendyn=new Int32Array(aa),i.distcode=i.distdyn=new Int32Array(la),i.sane=1,i.back=-1,$e},Zn=t=>{if(Pe(t))return Ie;const i=t.state;return i.wsize=0,i.whave=0,i.wnext=0,Jn(t)},qn=(t,i)=>{let e;if(Pe(t))return Ie;const s=t.state;return i<0?(e=0,i=-i):(e=(i>>4)+5,i<48&&(i&=15)),i&&(i<8||i>15)?Ie:(s.window!==null&&s.wbits!==i&&(s.window=null),s.wrap=e,s.wbits=i,Zn(t))},Yn=(t,i)=>{if(!t)return Ie;const e=new fa;t.state=e,e.strm=t,e.window=null,e.mode=Vt;const s=qn(t,i);return s!==$e&&(t.state=null),s},da=t=>Yn(t,ca);let wn=!0,ni,si;const ha=t=>{if(wn){ni=new Int32Array(512),si=new Int32Array(32);let i=0;for(;i<144;)t.lens[i++]=8;for(;i<256;)t.lens[i++]=9;for(;i<280;)t.lens[i++]=7;for(;i<288;)t.lens[i++]=8;for(lt(jn,t.lens,0,288,ni,0,t.work,{bits:9}),i=0;i<32;)t.lens[i++]=5;lt($n,t.lens,0,32,si,0,t.work,{bits:5}),wn=!1}t.lencode=ni,t.lenbits=9,t.distcode=si,t.distbits=5},Kn=(t,i,e,s)=>{let n;const r=t.state;return r.window===null&&(r.wsize=1<<r.wbits,r.wnext=0,r.whave=0,r.window=new Uint8Array(r.wsize)),s>=r.wsize?(r.window.set(i.subarray(e-r.wsize,e),0),r.wnext=0,r.whave=r.wsize):(n=r.wsize-r.wnext,n>s&&(n=s),r.window.set(i.subarray(e-s,e-s+n),r.wnext),s-=n,s?(r.window.set(i.subarray(e-s,e),0),r.wnext=s,r.whave=r.wsize):(r.wnext+=n,r.wnext===r.wsize&&(r.wnext=0),r.whave<r.wsize&&(r.whave+=n))),0},pa=(t,i)=>{let e,s,n,r,u,a,f,l,c,p,v,_,I,E,C=0,A,R,S,k,x,w,h,y;const z=new Uint8Array(4);let H,U;const we=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Pe(t)||!t.output||!t.input&&t.avail_in!==0)return Ie;e=t.state,e.mode===Ce&&(e.mode=ei),u=t.next_out,n=t.output,f=t.avail_out,r=t.next_in,s=t.input,a=t.avail_in,l=e.hold,c=e.bits,p=a,v=f,y=$e;e:for(;;)switch(e.mode){case Vt:if(e.wrap===0){e.mode=ei;break}for(;c<16;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(e.wrap&2&&l===35615){e.wbits===0&&(e.wbits=15),e.check=0,z[0]=l&255,z[1]=l>>>8&255,e.check=Be(e.check,z,2,0),l=0,c=0,e.mode=Zi;break}if(e.head&&(e.head.done=!1),!(e.wrap&1)||(((l&255)<<8)+(l>>8))%31){t.msg="incorrect header check",e.mode=J;break}if((l&15)!==Ji){t.msg="unknown compression method",e.mode=J;break}if(l>>>=4,c-=4,h=(l&15)+8,e.wbits===0&&(e.wbits=h),h>15||h>e.wbits){t.msg="invalid window size",e.mode=J;break}e.dmax=1<<e.wbits,e.flags=0,t.adler=e.check=1,e.mode=l&512?nn:Ce,l=0,c=0;break;case Zi:for(;c<16;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(e.flags=l,(e.flags&255)!==Ji){t.msg="unknown compression method",e.mode=J;break}if(e.flags&57344){t.msg="unknown header flags set",e.mode=J;break}e.head&&(e.head.text=l>>8&1),e.flags&512&&e.wrap&4&&(z[0]=l&255,z[1]=l>>>8&255,e.check=Be(e.check,z,2,0)),l=0,c=0,e.mode=qi;case qi:for(;c<32;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}e.head&&(e.head.time=l),e.flags&512&&e.wrap&4&&(z[0]=l&255,z[1]=l>>>8&255,z[2]=l>>>16&255,z[3]=l>>>24&255,e.check=Be(e.check,z,4,0)),l=0,c=0,e.mode=Yi;case Yi:for(;c<16;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}e.head&&(e.head.xflags=l&255,e.head.os=l>>8),e.flags&512&&e.wrap&4&&(z[0]=l&255,z[1]=l>>>8&255,e.check=Be(e.check,z,2,0)),l=0,c=0,e.mode=Ki;case Ki:if(e.flags&1024){for(;c<16;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}e.length=l,e.head&&(e.head.extra_len=l),e.flags&512&&e.wrap&4&&(z[0]=l&255,z[1]=l>>>8&255,e.check=Be(e.check,z,2,0)),l=0,c=0}else e.head&&(e.head.extra=null);e.mode=Qi;case Qi:if(e.flags&1024&&(_=e.length,_>a&&(_=a),_&&(e.head&&(h=e.head.extra_len-e.length,e.head.extra||(e.head.extra=new Uint8Array(e.head.extra_len)),e.head.extra.set(s.subarray(r,r+_),h)),e.flags&512&&e.wrap&4&&(e.check=Be(e.check,s,_,r)),a-=_,r+=_,e.length-=_),e.length))break e;e.length=0,e.mode=Xi;case Xi:if(e.flags&2048){if(a===0)break e;_=0;do h=s[r+_++],e.head&&h&&e.length<65536&&(e.head.name+=String.fromCharCode(h));while(h&&_<a);if(e.flags&512&&e.wrap&4&&(e.check=Be(e.check,s,_,r)),a-=_,r+=_,h)break e}else e.head&&(e.head.name=null);e.length=0,e.mode=en;case en:if(e.flags&4096){if(a===0)break e;_=0;do h=s[r+_++],e.head&&h&&e.length<65536&&(e.head.comment+=String.fromCharCode(h));while(h&&_<a);if(e.flags&512&&e.wrap&4&&(e.check=Be(e.check,s,_,r)),a-=_,r+=_,h)break e}else e.head&&(e.head.comment=null);e.mode=tn;case tn:if(e.flags&512){for(;c<16;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(e.wrap&4&&l!==(e.check&65535)){t.msg="header crc mismatch",e.mode=J;break}l=0,c=0}e.head&&(e.head.hcrc=e.flags>>9&1,e.head.done=!0),t.adler=e.check=0,e.mode=Ce;break;case nn:for(;c<32;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}t.adler=e.check=mn(l),l=0,c=0,e.mode=Ut;case Ut:if(e.havedict===0)return t.next_out=u,t.avail_out=f,t.next_in=r,t.avail_in=a,e.hold=l,e.bits=c,oa;t.adler=e.check=1,e.mode=Ce;case Ce:if(i===na||i===Tt)break e;case ei:if(e.last){l>>>=c&7,c-=c&7,e.mode=ii;break}for(;c<3;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}switch(e.last=l&1,l>>>=1,c-=1,l&3){case 0:e.mode=sn;break;case 1:if(ha(e),e.mode=Bt,i===Tt){l>>>=2,c-=2;break e}break;case 2:e.mode=rn;break;case 3:t.msg="invalid block type",e.mode=J}l>>>=2,c-=2;break;case sn:for(l>>>=c&7,c-=c&7;c<32;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if((l&65535)!==(l>>>16^65535)){t.msg="invalid stored block lengths",e.mode=J;break}if(e.length=l&65535,l=0,c=0,e.mode=ti,i===Tt)break e;case ti:e.mode=on;case on:if(_=e.length,_){if(_>a&&(_=a),_>f&&(_=f),_===0)break e;n.set(s.subarray(r,r+_),u),a-=_,r+=_,f-=_,u+=_,e.length-=_;break}e.mode=Ce;break;case rn:for(;c<14;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(e.nlen=(l&31)+257,l>>>=5,c-=5,e.ndist=(l&31)+1,l>>>=5,c-=5,e.ncode=(l&15)+4,l>>>=4,c-=4,e.nlen>286||e.ndist>30){t.msg="too many length or distance symbols",e.mode=J;break}e.have=0,e.mode=an;case an:for(;e.have<e.ncode;){for(;c<3;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}e.lens[we[e.have++]]=l&7,l>>>=3,c-=3}for(;e.have<19;)e.lens[we[e.have++]]=0;if(e.lencode=e.lendyn,e.lenbits=7,H={bits:e.lenbits},y=lt(ia,e.lens,0,19,e.lencode,0,e.work,H),e.lenbits=H.bits,y){t.msg="invalid code lengths set",e.mode=J;break}e.have=0,e.mode=ln;case ln:for(;e.have<e.nlen+e.ndist;){for(;C=e.lencode[l&(1<<e.lenbits)-1],A=C>>>24,R=C>>>16&255,S=C&65535,!(A<=c);){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(S<16)l>>>=A,c-=A,e.lens[e.have++]=S;else{if(S===16){for(U=A+2;c<U;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(l>>>=A,c-=A,e.have===0){t.msg="invalid bit length repeat",e.mode=J;break}h=e.lens[e.have-1],_=3+(l&3),l>>>=2,c-=2}else if(S===17){for(U=A+3;c<U;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}l>>>=A,c-=A,h=0,_=3+(l&7),l>>>=3,c-=3}else{for(U=A+7;c<U;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}l>>>=A,c-=A,h=0,_=11+(l&127),l>>>=7,c-=7}if(e.have+_>e.nlen+e.ndist){t.msg="invalid bit length repeat",e.mode=J;break}for(;_--;)e.lens[e.have++]=h}}if(e.mode===J)break;if(e.lens[256]===0){t.msg="invalid code -- missing end-of-block",e.mode=J;break}if(e.lenbits=9,H={bits:e.lenbits},y=lt(jn,e.lens,0,e.nlen,e.lencode,0,e.work,H),e.lenbits=H.bits,y){t.msg="invalid literal/lengths set",e.mode=J;break}if(e.distbits=6,e.distcode=e.distdyn,H={bits:e.distbits},y=lt($n,e.lens,e.nlen,e.ndist,e.distcode,0,e.work,H),e.distbits=H.bits,y){t.msg="invalid distances set",e.mode=J;break}if(e.mode=Bt,i===Tt)break e;case Bt:e.mode=Et;case Et:if(a>=6&&f>=258){t.next_out=u,t.avail_out=f,t.next_in=r,t.avail_in=a,e.hold=l,e.bits=c,Yr(t,v),u=t.next_out,n=t.output,f=t.avail_out,r=t.next_in,s=t.input,a=t.avail_in,l=e.hold,c=e.bits,e.mode===Ce&&(e.back=-1);break}for(e.back=0;C=e.lencode[l&(1<<e.lenbits)-1],A=C>>>24,R=C>>>16&255,S=C&65535,!(A<=c);){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(R&&!(R&240)){for(k=A,x=R,w=S;C=e.lencode[w+((l&(1<<k+x)-1)>>k)],A=C>>>24,R=C>>>16&255,S=C&65535,!(k+A<=c);){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}l>>>=k,c-=k,e.back+=k}if(l>>>=A,c-=A,e.back+=A,e.length=S,R===0){e.mode=hn;break}if(R&32){e.back=-1,e.mode=Ce;break}if(R&64){t.msg="invalid literal/length code",e.mode=J;break}e.extra=R&15,e.mode=un;case un:if(e.extra){for(U=e.extra;c<U;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}e.length+=l&(1<<e.extra)-1,l>>>=e.extra,c-=e.extra,e.back+=e.extra}e.was=e.length,e.mode=cn;case cn:for(;C=e.distcode[l&(1<<e.distbits)-1],A=C>>>24,R=C>>>16&255,S=C&65535,!(A<=c);){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(!(R&240)){for(k=A,x=R,w=S;C=e.distcode[w+((l&(1<<k+x)-1)>>k)],A=C>>>24,R=C>>>16&255,S=C&65535,!(k+A<=c);){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}l>>>=k,c-=k,e.back+=k}if(l>>>=A,c-=A,e.back+=A,R&64){t.msg="invalid distance code",e.mode=J;break}e.offset=S,e.extra=R&15,e.mode=fn;case fn:if(e.extra){for(U=e.extra;c<U;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}e.offset+=l&(1<<e.extra)-1,l>>>=e.extra,c-=e.extra,e.back+=e.extra}if(e.offset>e.dmax){t.msg="invalid distance too far back",e.mode=J;break}e.mode=dn;case dn:if(f===0)break e;if(_=v-f,e.offset>_){if(_=e.offset-_,_>e.whave&&e.sane){t.msg="invalid distance too far back",e.mode=J;break}_>e.wnext?(_-=e.wnext,I=e.wsize-_):I=e.wnext-_,_>e.length&&(_=e.length),E=e.window}else E=n,I=u-e.offset,_=e.length;_>f&&(_=f),f-=_,e.length-=_;do n[u++]=E[I++];while(--_);e.length===0&&(e.mode=Et);break;case hn:if(f===0)break e;n[u++]=e.length,f--,e.mode=Et;break;case ii:if(e.wrap){for(;c<32;){if(a===0)break e;a--,l|=s[r++]<<c,c+=8}if(v-=f,t.total_out+=v,e.total+=v,e.wrap&4&&v&&(t.adler=e.check=e.flags?Be(e.check,n,v,u-v):di(e.check,n,v,u-v)),v=f,e.wrap&4&&(e.flags?l:mn(l))!==e.check){t.msg="incorrect data check",e.mode=J;break}l=0,c=0}e.mode=pn;case pn:if(e.wrap&&e.flags){for(;c<32;){if(a===0)break e;a--,l+=s[r++]<<c,c+=8}if(e.wrap&4&&l!==(e.total&4294967295)){t.msg="incorrect length check",e.mode=J;break}l=0,c=0}e.mode=vn;case vn:y=sa;break e;case J:y=Pn;break e;case Vn:return Gn;case Wn:default:return Ie}return t.next_out=u,t.avail_out=f,t.next_in=r,t.avail_in=a,e.hold=l,e.bits=c,(e.wsize||v!==t.avail_out&&e.mode<J&&(e.mode<ii||i!==Wi))&&Kn(t,t.output,t.next_out,v-t.avail_out),p-=t.avail_in,v-=t.avail_out,t.total_in+=p,t.total_out+=v,e.total+=v,e.wrap&4&&v&&(t.adler=e.check=e.flags?Be(e.check,n,v,t.next_out-v):di(e.check,n,v,t.next_out-v)),t.data_type=e.bits+(e.last?64:0)+(e.mode===Ce?128:0)+(e.mode===Bt||e.mode===ti?256:0),(p===0&&v===0||i===Wi)&&y===$e&&(y=ra),y},va=t=>{if(Pe(t))return Ie;let i=t.state;return i.window&&(i.window=null),t.state=null,$e},ma=(t,i)=>{if(Pe(t))return Ie;const e=t.state;return e.wrap&2?(e.head=i,i.done=!1,$e):Ie},wa=(t,i)=>{const e=i.length;let s,n,r;return Pe(t)||(s=t.state,s.wrap!==0&&s.mode!==Ut)?Ie:s.mode===Ut&&(n=1,n=di(n,i,e,0),n!==s.check)?Pn:(r=Kn(t,i,e,e),r?(s.mode=Vn,Gn):(s.havedict=1,$e))};var ya=Zn,ga=qn,_a=Jn,xa=da,ba=Yn,ka=pa,Ia=va,Sa=ma,Ta=wa,Ba="pako inflate (from Nodeca project)",Ne={inflateReset:ya,inflateReset2:ga,inflateResetKeep:_a,inflateInit:xa,inflateInit2:ba,inflate:ka,inflateEnd:Ia,inflateGetHeader:Sa,inflateSetDictionary:Ta,inflateInfo:Ba};function Ea(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var Aa=Ea;const Qn=Object.prototype.toString,{Z_NO_FLUSH:Ca,Z_FINISH:Na,Z_OK:dt,Z_STREAM_END:oi,Z_NEED_DICT:ri,Z_STREAM_ERROR:Ma,Z_DATA_ERROR:yn,Z_MEM_ERROR:Oa}=Ln;function Wt(t){this.options=Hn.assign({chunkSize:1024*64,windowBits:15,to:""},t||{});const i=this.options;i.raw&&i.windowBits>=0&&i.windowBits<16&&(i.windowBits=-i.windowBits,i.windowBits===0&&(i.windowBits=-15)),i.windowBits>=0&&i.windowBits<16&&!(t&&t.windowBits)&&(i.windowBits+=32),i.windowBits>15&&i.windowBits<48&&(i.windowBits&15||(i.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Zr,this.strm.avail_out=0;let e=Ne.inflateInit2(this.strm,i.windowBits);if(e!==dt)throw new Error(hi[e]);if(this.header=new Aa,Ne.inflateGetHeader(this.strm,this.header),i.dictionary&&(typeof i.dictionary=="string"?i.dictionary=pi.string2buf(i.dictionary):Qn.call(i.dictionary)==="[object ArrayBuffer]"&&(i.dictionary=new Uint8Array(i.dictionary)),i.raw&&(e=Ne.inflateSetDictionary(this.strm,i.dictionary),e!==dt)))throw new Error(hi[e])}Wt.prototype.push=function(t,i){const e=this.strm,s=this.options.chunkSize,n=this.options.dictionary;let r,u,a;if(this.ended)return!1;for(i===~~i?u=i:u=i===!0?Na:Ca,Qn.call(t)==="[object ArrayBuffer]"?e.input=new Uint8Array(t):e.input=t,e.next_in=0,e.avail_in=e.input.length;;){for(e.avail_out===0&&(e.output=new Uint8Array(s),e.next_out=0,e.avail_out=s),r=Ne.inflate(e,u),r===ri&&n&&(r=Ne.inflateSetDictionary(e,n),r===dt?r=Ne.inflate(e,u):r===yn&&(r=ri));e.avail_in>0&&r===oi&&e.state.wrap>0&&t[e.next_in]!==0;)Ne.inflateReset(e),r=Ne.inflate(e,u);switch(r){case Ma:case yn:case ri:case Oa:return this.onEnd(r),this.ended=!0,!1}if(a=e.avail_out,e.next_out&&(e.avail_out===0||r===oi))if(this.options.to==="string"){let f=pi.utf8border(e.output,e.next_out),l=e.next_out-f,c=pi.buf2string(e.output,f);e.next_out=l,e.avail_out=s-l,l&&e.output.set(e.output.subarray(f,f+l),0),this.onData(c)}else this.onData(e.output.length===e.next_out?e.output:e.output.subarray(0,e.next_out));if(!(r===dt&&a===0)){if(r===oi)return r=Ne.inflateEnd(this.strm),this.onEnd(r),this.ended=!0,!0;if(e.avail_in===0)break}}return!0};Wt.prototype.onData=function(t){this.chunks.push(t)};Wt.prototype.onEnd=function(t){t===dt&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Hn.flattenChunks(this.chunks)),this.chunks=[],this.err=t,this.msg=this.strm.msg};function Ra(t,i){const e=new Wt(i);if(e.push(t),e.err)throw e.msg||hi[e.err];return e.result}var Ua=Ra,Da={ungzip:Ua};const{ungzip:Fa}=Da;var La=Fa,d={};d.INT8=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeInt8(i,e)},this._read=function(t,i,e){return t.readInt8(i,!0,e)},this._className=function(){return d.CHAR}};d.INT16=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeInt16(i,e)},this._read=function(t,i,e){return t.readInt16(i,!0,e)},this._className=function(){return d.SHORT}};d.INT32=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeInt32(i,e)},this._read=function(t,i,e){return t.readInt32(i,!0,e)},this._className=function(){return d.INT32}};d.INT64=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeInt64(i,e)},this._read=function(t,i,e){return t.readInt64(i,!0,e)},this._className=function(){return d.INT64}};d.UINT8=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeInt16(i,e)},this._read=function(t,i,e){return t.readInt16(i,!0,e)},this._className=function(){return d.SHORT}};d.UInt16=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeInt32(i,e)},this._read=function(t,i,e){return t.readInt32(i,!0,e)},this._className=function(){return d.INT32}};d.UInt32=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeInt64(i,e)},this._read=function(t,i,e){return t.readInt64(i,!0,e)},this._className=function(){return d.INT64}};d.Float=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeFloat(i,e)},this._read=function(t,i,e){return t.readFloat(i,!0,e)},this._className=function(){return d.FLOAT}};d.Double=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeDouble(i,e)},this._read=function(t,i,e){return t.readDouble(i,!0,e)},this._className=function(){return d.DOUBLE}};d.STRING=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeString(i,e)},this._read=function(t,i,e){return t.readString(i,!0,e)},this._className=function(){return d.STRING}};d.BOOLEAN=function(){this._clone=function(){return!1},this._write=function(t,i,e){return t.writeBoolean(i,e)},this._read=function(t,i,e){return t.readBoolean(i,!0,e)},this._className=function(){return d.BOOLEAN}};d.ENUM=function(){this._clone=function(){return 0},this._write=function(t,i,e){return t.writeInt32(i,e)},this._read=function(t,i,e){return t.readInt32(i,!0,e)}};d.Vector=function(t){this.proto=t,this.value=new Array};d.Vector.prototype._clone=function(){return new d.Vector(this.proto)};d.Vector.prototype._write=function(t,i,e){return t.writeVector(i,e)};d.Vector.prototype._read=function(t,i,e){return t.readVector(i,!0,e)};d.Vector.prototype._className=function(){return d.TypeHelp.VECTOR.replace("$t",this.proto._className())};d.Map=function(t,i){this.kproto=t,this.vproto=i,this.value=new Object};d.Map.prototype._clone=function(){return new d.Map(this.kproto,this.vproto)};d.Map.prototype._write=function(t,i,e){return t.writeMap(i,e)};d.Map.prototype._read=function(t,i,e){return t.readMap(i,!0,e)};d.Map.prototype.put=function(t,i){this.value[t]=i};d.Map.prototype.get=function(t){return this.value[t]};d.Map.prototype.remove=function(t){delete this.value[t]};d.Map.prototype.clear=function(){this.value=new Object};d.Map.prototype.size=function(){var t=0;for(var i in this.value)t++;return t};d.Map.prototype._className=function(){return d.TypeHelp.Map.replace("$k",this.kproto._className()).replace("$v",this.vproto._className())};d.DataHelp={EN_INT8:0,EN_INT16:1,EN_INT32:2,EN_INT64:3,EN_FLOAT:4,EN_DOUBLE:5,EN_STRING1:6,EN_STRING4:7,EN_MAP:8,EN_LIST:9,EN_STRUCTBEGIN:10,EN_STRUCTEND:11,EN_ZERO:12,EN_SIMPLELIST:13};d.TypeHelp={BOOLEAN:"bool",CHAR:"char",SHORT:"short",INT32:"int32",INT64:"int64",FLOAT:"float",DOUBLE:"double",STRING:"string",VECTOR:"list<$t>",MAP:"map<$k, $v>"};d.BinBuffer=function(t){this.buf=null,this.vew=null,this.len=0,this.position=0,t!=null&&t!=null&&t instanceof d.BinBuffer&&(this.buf=t.buf,this.vew=new DataView(this.buf),this.len=t.length,this.position=t.position),t!=null&&t!=null&&t instanceof ArrayBuffer&&(this.buf=t,this.vew=new DataView(this.buf),this.len=this.vew.byteLength,this.position=0),this.__defineGetter__("length",function(){return this.len}),this.__defineGetter__("buffer",function(){return this.buf})};d.BinBuffer.prototype._write=function(t,i,e){return t.writeBytes(i,e)};d.BinBuffer.prototype._read=function(t,i,e){return t.readBytes(i,!0,e)};d.BinBuffer.prototype._clone=function(){return new d.BinBuffer};d.BinBuffer.prototype.allocate=function(t){if(t=this.position+t,!(this.buf!=null&&this.buf.length>t)){var i=new ArrayBuffer(Math.max(256,t*2));this.buf!=null&&(new Uint8Array(i).set(new Uint8Array(this.buf)),this.buf=void 0),this.buf=i,this.vew=void 0,this.vew=new DataView(this.buf)}};d.BinBuffer.prototype.getBuffer=function(){var t=new ArrayBuffer(this.len);return new Uint8Array(t).set(new Uint8Array(this.buf,0,this.len)),t};d.BinBuffer.prototype.memset=function(t,i,e){this.allocate(e),new Uint8Array(this.buf).set(new Uint8Array(t,i,e),this.position)};d.BinBuffer.prototype.writeInt8=function(t){this.allocate(1),this.vew.setInt8(this.position,t),this.position+=1,this.len=this.position};d.BinBuffer.prototype.writeUInt8=function(t){this.allocate(1),this.vew.setUint8(this.position++,t),this.len=this.position};d.BinBuffer.prototype.writeInt16=function(t){this.allocate(2),this.vew.setInt16(this.position,t),this.position+=2,this.len=this.position};d.BinBuffer.prototype.writeUInt16=function(t){this.allocate(2),this.vew.setUint16(this.position,t),this.position+=2,this.len=this.position};d.BinBuffer.prototype.writeInt32=function(t){this.allocate(4),this.vew.setInt32(this.position,t),this.position+=4,this.len=this.position};d.BinBuffer.prototype.writeUInt32=function(t){this.allocate(4),this.vew.setUint32(this.position,t),this.position+=4,this.len=this.position};d.BinBuffer.prototype.writeInt64=function(t){if(typeof t=="string"){this.allocate(8),t=t.toLowerCase();for(var i=4294967296,e=0,s=0,n=0;n<t.length;n++){var r=t.charCodeAt(n)-48;r>9&&(r=r-39),e=e*10+r;var u=Math.floor(e/i);s=s*10+u,e=e%i}this.vew.setUint32(this.position,s),this.vew.setUint32(this.position+4,e),this.position+=8,this.len=this.position;return}this.allocate(8),this.vew.setUint32(this.position,parseInt(t/4294967296)),this.vew.setUint32(this.position+4,t%4294967296),this.position+=8,this.len=this.position};d.BinBuffer.prototype.writeFloat=function(t){this.allocate(4),this.vew.setFloat32(this.position,t),this.position+=4,this.len=this.position};d.BinBuffer.prototype.writeDouble=function(t){this.allocate(8),this.vew.setFloat64(this.position,t),this.position+=8,this.len=this.position};d.BinBuffer.prototype.writeString=function(t){for(var i=[],e=0;e<t.length;e++)i.push(t.charCodeAt(e)&255);this.allocate(i.length),new Uint8Array(this.buf).set(new Uint8Array(i),this.position),this.position+=i.length,this.len=this.position};d.BinBuffer.prototype.writeBytes=function(t){t.length==0||t.buf==null||(this.allocate(t.length),new Uint8Array(this.buf).set(new Uint8Array(t.buf,0,t.length),this.position),this.position+=t.length,this.len=this.position)};d.BinBuffer.prototype.readInt8=function(){return this.vew.getInt8(this.position++)};d.BinBuffer.prototype.readInt16=function(){return this.position+=2,this.vew.getInt16(this.position-2)};d.BinBuffer.prototype.readInt32=function(){return this.position+=4,this.vew.getInt32(this.position-4)};d.BinBuffer.prototype.readUInt8=function(){return this.position+=1,this.vew.getUint8(this.position-1)};d.BinBuffer.prototype.readUInt16=function(){return this.position+=2,this.vew.getUint16(this.position-2)};d.BinBuffer.prototype.readUInt32=function(){return this.position+=4,this.vew.getUint32(this.position-4)};d.BinBuffer.prototype.readInt64=function(){var t=this.vew.getUint32(this.position),i=this.vew.getUint32(this.position+4);this.position+=8;for(var e="",s,n,r,u=Math.pow(2,32),a=10;t!=0||i!=0;)s=t%a,r=s*u+i,n=r%a,e=n.toString(a)+e,t=(t-s)/a,i=(r-n)/a;return e};d.BinBuffer.prototype.readFloat=function(){var t=this.vew.getFloat32(this.position);return this.position+=4,t};d.BinBuffer.prototype.readDouble=function(){var t=this.vew.getFloat64(this.position);return this.position+=8,t};d.BinBuffer.prototype.readString=function(t){for(var i=[],e=0;e<t;e++)i.push(String.fromCharCode(this.vew.getUint8(this.position++)));var s=i.join("");try{s=decodeURIComponent(escape(s))}catch{}return s=s.replace(/</g,"<").replace(/>/g,">").replace(/\'/g,"'").replace(/\"/g,"""),s};d.BinBuffer.prototype.readBytes=function(t){var i=new d.BinBuffer;return i.allocate(t),i.memset(this.buf,this.position,t),i.position=0,i.len=t,this.position=this.position+t,i};d.JceOutputStream=function(){this.buf=new d.BinBuffer,this.getBinBuffer=function(){return this.buf},this.getBuffer=function(){return this.buf.getBuffer()}};d.JceOutputStream.prototype.clear=function(){return this.buf=new d.BinBuffer,this};d.JceOutputStream.prototype.writeTo=function(t,i){t<15?this.buf.writeUInt8(t<<4&240|i):this.buf.writeUInt16((240|i)<<8|t)};d.JceOutputStream.prototype.writeBoolean=function(t,i){this.writeInt8(t,i==!0?1:0)};d.JceOutputStream.prototype.writeInt8=function(t,i){i==0?this.writeTo(t,d.DataHelp.EN_ZERO):(this.writeTo(t,d.DataHelp.EN_INT8),this.buf.writeInt8(i))};d.JceOutputStream.prototype.writeInt16=function(t,i){i>=-128&&i<=127?this.writeInt8(t,i):(this.writeTo(t,d.DataHelp.EN_INT16),this.buf.writeInt16(i))};d.JceOutputStream.prototype.writeInt32=function(t,i){i>=-32768&&i<=32767?this.writeInt16(t,i):(this.writeTo(t,d.DataHelp.EN_INT32),this.buf.writeInt32(i))};d.JceOutputStream.prototype.writeInt64=function(t,i){i>=-2147483648&&i<=2147483647?this.writeInt32(t,i):(this.writeTo(t,d.DataHelp.EN_INT64),this.buf.writeInt64(i))};d.JceOutputStream.prototype.writeUInt8=function(t,i){this.writeInt16(t,i)};d.JceOutputStream.prototype.writeUInt16=function(t,i){this.writeInt32(t,i)};d.JceOutputStream.prototype.writeUInt32=function(t,i){this.writeInt64(t,i)};d.JceOutputStream.prototype.writeFloat=function(t,i){i==0?this.writeTo(t,d.DataHelp.EN_ZERO):(this.writeTo(t,d.DataHelp.EN_FLOAT),this.buf.writeFloat(i))};d.JceOutputStream.prototype.writeDouble=function(t,i){i==0?this.writeTo(t,d.DataHelp.EN_ZERO):(this.writeTo(t,d.DataHelp.EN_DOUBLE),this.buf.writeDouble(i))};d.JceOutputStream.prototype.writeStruct=function(t,i){if(i.writeTo==null)throw Error("not defined writeTo Function");this.writeTo(t,d.DataHelp.EN_STRUCTBEGIN),i.writeTo(this),this.writeTo(0,d.DataHelp.EN_STRUCTEND)};d.JceOutputStream.prototype.writeString=function(t,i){var e=i;try{e=unescape(encodeURIComponent(e))}catch{}e.length>255?(this.writeTo(t,d.DataHelp.EN_STRING4),this.buf.writeUInt32(e.length)):(this.writeTo(t,d.DataHelp.EN_STRING1),this.buf.writeUInt8(e.length)),this.buf.writeString(e)};d.JceOutputStream.prototype.writeBytes=function(t,i){if(!(i instanceof d.BinBuffer))throw Error("value not instanceof Taf.BinBuffer");this.writeTo(t,d.DataHelp.EN_SIMPLELIST),this.writeTo(0,d.DataHelp.EN_INT8),this.writeInt32(0,i.length),this.buf.writeBytes(i)};d.JceOutputStream.prototype.writeVector=function(t,i){this.writeTo(t,d.DataHelp.EN_LIST),this.writeInt32(0,i.value.length);for(var e=0;e<i.value.length;e++)i.proto._write(this,0,i.value[e])};d.JceOutputStream.prototype.writeMap=function(t,i){this.writeTo(t,d.DataHelp.EN_MAP),this.writeInt32(0,i.size());for(var e in i.value)i.kproto._write(this,0,e),i.vproto._write(this,1,i.value[e])};d.JceInputStream=function(t){this.buf=new d.BinBuffer(t)};d.JceInputStream.prototype.setBuffer=function(t){return this.buf=new d.BinBuffer(t),this};d.JceInputStream.prototype.readFrom=function(){var t=this.buf.readUInt8(),i=(t&240)>>4,e=t&15;return i>=15&&(i=this.buf.readUInt8()),{tag:i,type:e}};d.JceInputStream.prototype.peekFrom=function(){var t=this.buf.position,i=this.readFrom();return this.buf.position=t,{tag:i.tag,type:i.type,size:i.tag>=15?2:1}};d.JceInputStream.prototype.skipField=function(t){switch(t){case d.DataHelp.EN_INT8:this.buf.position+=1;break;case d.DataHelp.EN_INT16:this.buf.position+=2;break;case d.DataHelp.EN_INT32:this.buf.position+=4;break;case d.DataHelp.EN_INT64:this.buf.position+=8;break;case d.DataHelp.EN_STRING1:var i=this.buf.readUInt8();this.buf.position+=i;break;case d.DataHelp.EN_STRING4:var e=this.buf.readInt32();this.buf.position+=e;break;case d.DataHelp.EN_STRUCTBEGIN:this.skipToStructEnd();break;case d.DataHelp.EN_STRUCTEND:case d.DataHelp.EN_ZERO:break;case d.DataHelp.EN_MAP:{for(var s=this.readInt32(0,!0),n=0;n<s*2;++n){var r=this.readFrom();this.skipField(r.type)}break}case d.DataHelp.EN_SIMPLELIST:{var r=this.readFrom();if(r.type!=d.DataHelp.EN_INT8)throw Error("skipField with invalid type, type value: "+t+","+r.type);var i=this.readInt32(0,!0);this.buf.position+=i;break}case d.DataHelp.EN_LIST:{for(var s=this.readInt32(0,!0),n=0;n<s;++n){var r=this.readFrom();this.skipField(r.type)}break}default:throw new Error("skipField with invalid type, type value: "+t)}};d.JceInputStream.prototype.skipToStructEnd=function(){for(;;){var t=this.readFrom();if(this.skipField(t.type),t.type==d.DataHelp.EN_STRUCTEND)return}};d.JceInputStream.prototype.skipToTag=function(t,i){for(;this.buf.position<this.buf.length;){var e=this.peekFrom();if(t<=e.tag||e.type==d.DataHelp.EN_STRUCTEND)return e.type==d.DataHelp.EN_STRUCTEND?!1:t==e.tag;this.buf.position+=e.size,this.skipField(e.type)}if(i)throw Error("require field not exist, tag:"+t);return!1};d.JceInputStream.prototype.readBoolean=function(t,i,e){return this.readInt8(t,i,e)==1};d.JceInputStream.prototype.readInt8=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();switch(s.type){case d.DataHelp.EN_ZERO:return 0;case d.DataHelp.EN_INT8:return this.buf.readInt8()}throw Error("read int8 type mismatch, tag:"+t+", get type:"+s.type)};d.JceInputStream.prototype.readInt16=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();switch(s.type){case d.DataHelp.EN_ZERO:return 0;case d.DataHelp.EN_INT8:return this.buf.readInt8();case d.DataHelp.EN_INT16:return this.buf.readInt16()}throw Error("read int16 type mismatch, tag:"+t+", get type:"+s.type)};d.JceInputStream.prototype.readInt32=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();switch(s.type){case d.DataHelp.EN_ZERO:return 0;case d.DataHelp.EN_INT8:return this.buf.readInt8();case d.DataHelp.EN_INT16:return this.buf.readInt16();case d.DataHelp.EN_INT32:return this.buf.readInt32()}throw Error("read int32 type mismatch, tag:"+t+", get type:"+s.type)};d.JceInputStream.prototype.readInt64=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();switch(s.type){case d.DataHelp.EN_ZERO:return 0;case d.DataHelp.EN_INT8:return this.buf.readInt8();case d.DataHelp.EN_INT16:return this.buf.readInt16();case d.DataHelp.EN_INT32:return this.buf.readInt32();case d.DataHelp.EN_INT64:return this.buf.readInt64()}throw Error("read int64 type mismatch, tag:"+t+", get type:"+s.type)};d.JceInputStream.prototype.readFloat=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();switch(s.type){case d.DataHelp.EN_ZERO:return 0;case d.DataHelp.EN_FLOAT:return this.buf.readFloat()}throw Error("read float type mismatch, tag:"+t+", get type:"+vi.type)};d.JceInputStream.prototype.readDouble=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();switch(s.type){case d.DataHelp.EN_ZERO:return 0;case d.DataHelp.EN_DOUBLE:return this.buf.readDouble()}throw Error("read double type mismatch, tag:"+t+", get type:"+vi.type)};d.JceInputStream.prototype.readUInt8=function(t,i,e){return this.readInt16(t,i,e)};d.JceInputStream.prototype.readUInt16=function(t,i,e){return this.readInt32(t,i,e)};d.JceInputStream.prototype.readUInt32=function(t,i,e){return this.readInt64(t,i,e)};d.JceInputStream.prototype.readStruct=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();if(s.type!=d.DataHelp.EN_STRUCTBEGIN)throw Error("read struct type mismatch, tag: "+t+", get type:"+s.type);return e.readFrom(this),this.skipToStructEnd(),e};d.JceInputStream.prototype.readString=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();if(s.type==d.DataHelp.EN_STRING1)return this.buf.readString(this.buf.readUInt8());if(s.type==d.DataHelp.EN_STRING4)return this.buf.readString(this.buf.readUInt32());throw Error("read 'string' type mismatch, tag: "+t+", get type: "+s.type+".")};d.JceInputStream.prototype.readString2=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();if(s.type==d.DataHelp.EN_STRING1)return this.buf.readBytes(this.buf.readUInt8());if(s.type==d.DataHelp.EN_STRING4)return this.buf.readBytes(this.buf.readUInt32());throw Error("read 'string2' type mismatch, tag: "+t+", get type: "+s.type+".")};d.JceInputStream.prototype.readBytes=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();if(s.type==d.DataHelp.EN_SIMPLELIST){var n=this.readFrom();if(n.type!=d.DataHelp.EN_INT8)throw Error("type mismatch, tag:"+t+",type:"+s.type+","+n.type);var r=this.readInt32(0,!0);if(r<0)throw Error("invalid size, tag:"+t+",type:"+s.type+","+n.type);return this.buf.readBytes(r)}if(s.type==d.DataHelp.EN_LIST){var r=this.readInt32(0,!0);return this.buf.readBytes(r)}throw Error("type mismatch, tag:"+t+",type:"+s.type)};d.JceInputStream.prototype.readVector=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();if(s.type!=d.DataHelp.EN_LIST)throw Error("read 'vector' type mismatch, tag: "+t+", get type: "+s.type);var n=this.readInt32(0,!0);if(n<0)throw Error("invalid size, tag: "+t+", type: "+s.type+", size: "+n);for(var r=0;r<n;++r)e.value.push(e.proto._read(this,0,e.proto._clone()));return e};d.JceInputStream.prototype.readMap=function(t,i,e){if(this.skipToTag(t,i)==!1)return e;var s=this.readFrom();if(s.type!=d.DataHelp.EN_MAP)throw Error("read 'map' type mismatch, tag: "+t+", get type: "+s.type);var n=this.readInt32(0,!0);if(n<0)throw Error("invalid map, tag: "+t+", size: "+n);for(var r=0;r<n;r++){var u=e.kproto._read(this,0,e.kproto._clone()),a=e.vproto._read(this,1,e.vproto._clone());e.put(u,a)}return e};d.Wup=function(){this.iVersion=3,this.cPacketType=0,this.iMessageType=0,this.iRequestId=0,this.sServantName="",this.sFuncName="",this.sBuffer=new d.BinBuffer,this.iTimeout=0,this.context=new d.Map(new d.STRING,new d.STRING),this.status=new d.Map(new d.STRING,new d.STRING),this.newdata=new d.Map(new d.STRING,new d.BinBuffer),this.iStream=new d.JceInputStream,this.oStream=new d.JceOutputStream};d.Wup.prototype.hasKey=function(t){return this.newdata.hasKey(t)};d.Wup.prototype.setVersion=function(t){this.iVersion=t};d.Wup.prototype.getVersion=function(t){return this.iVersion};d.Wup.prototype.setServant=function(t){this.sServantName=t};d.Wup.prototype.setFunc=function(t){this.sFuncName=t};d.Wup.prototype.setRequestId=function(t){this.iRequestId=t||++this.iRequestId};d.Wup.prototype.getRequestId=function(){return this.iRequestId};d.Wup.prototype.setTimeOut=function(t){this.iTimeout=t};d.Wup.prototype.getTimeOut=function(){return this.iTimeout};d.Wup.prototype.writeTo=function(){var t=this.oStream.clear();return t.writeInt16(1,this.iVersion),t.writeInt8(2,this.cPacketType),t.writeInt32(3,this.iMessageType),t.writeInt32(4,this.iRequestId),t.writeString(5,this.sServantName),t.writeString(6,this.sFuncName),t.writeBytes(7,this.sBuffer),t.writeInt32(8,this.iTimeout),t.writeMap(9,this.context),t.writeMap(10,this.status),new d.BinBuffer(t.getBuffer())};d.Wup.prototype.encode=function(){var t=this.oStream.clear();t.writeMap(0,this.newdata),this.sBuffer=t.getBinBuffer();var i=this.writeTo(),e=new d.BinBuffer;return e.writeInt32(4+i.len),e.writeBytes(i),e};d.Wup.prototype.writeBoolean=function(t,i){var e=this.oStream.clear();e.writeBoolean(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeInt8=function(t,i){var e=this.oStream.clear();e.writeInt8(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeInt16=function(t,i){var e=this.oStream.clear();e.writeInt16(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeInt32=function(t,i){var e=this.oStream.clear();e.writeInt32(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeInt64=function(t,i){var e=this.oStream.clear();e.writeInt64(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeFloat=function(t,i){var e=this.oStream.clear();e.writeFloat(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeDouble=function(t,i){var e=this.oStream.clear();e.writeDouble(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeString=function(t,i){var e=this.oStream.clear();e.writeString(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeVector=function(t,i){var e=this.oStream.clear();e.writeVector(0,i),this.newdata.put(t,new d.BinBuffer(e.getBinBuffer()))};d.Wup.prototype.writeStruct=function(t,i){var e=this.oStream.clear();e.writeStruct(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeBytes=function(t,i){var e=this.oStream.clear();e.writeBytes(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.writeMap=function(t,i){var e=this.oStream.clear();e.writeMap(0,i),this.newdata.put(t,new d.BinBuffer(e.getBuffer()))};d.Wup.prototype.readFrom=function(t){this.iVersion=t.readInt16(1,!0),this.cPacketType=t.readInt8(2,!0),this.iMessageType=t.readInt32(3,!0),this.iRequestId=t.readInt32(4,!0),this.sServantName=t.readString(5,!0),this.sFuncName=t.readString(6,!0),this.sBuffer=t.readBytes(7,!0),this.iTimeout=t.readInt32(8,!0),this.context=t.readMap(9,!0,this.context),this.status=t.readMap(10,!0,this.status)};d.Wup.prototype.decode=function(t){var i=this.iStream.setBuffer(t),e=i.buf.vew.getInt32(i.buf.position);if(e<4)throw Error("packet length too short");i.buf.position+=4,this.readFrom(i),i=this.iStream.setBuffer(this.sBuffer.getBuffer()),this.newdata.clear(),i.readMap(0,!0,this.newdata)};d.Wup.prototype.readBoolean=function(t){var i,e;if(i=this.newdata.get(t),i==null)throw Error("UniAttribute not found key:"+t);var s=this.iStream.setBuffer(i.buffer);return e=s.readBoolean(0,!0,e),e};d.Wup.prototype.readInt8=function(t){var i,e;if(i=this.newdata.get(t),i==null)throw Error("UniAttribute not found key:"+t);var s=this.iStream.setBuffer(i.buffer);return e=s.readInt8(0,!0,e),e};d.Wup.prototype.readInt16=function(t){var i,e;if(i=this.newdata.get(t),i==null)throw Error("UniAttribute not found key:"+t);var s=this.iStream.setBuffer(i.buffer);return e=s.readInt16(0,!0,e),e};d.Wup.prototype.readInt32=function(t){var i,e;if(i=this.newdata.get(t),i==null)throw Error("UniAttribute not found key:"+t);var s=this.iStream.setBuffer(i.buffer);return e=s.readInt32(0,!0,e),e};d.Wup.prototype.readInt64=function(t){var i,e;if(i=this.newdata.get(t),i==null)throw Error("UniAttribute not found key:"+t);var s=this.iStream.setBuffer(i.buffer);return e=s.readInt64(0,!0,e),e};d.Wup.prototype.readFloat=function(t){var i,e;if(i=this.newdata.get(t),i==null)throw Error("UniAttribute not found key:"+t);var s=this.iStream.setBuffer(i.buffer);return e=s.readFloat(0,!0,e),e};d.Wup.prototype.readDouble=function(t){var i;if(i=this.newdata.get(t),i==null)throw Error("UniAttribute not found key:"+t);var e=this.iStream.setBuffer(i.buffer);return def=e.readDouble(0,!0,def),def};d.Wup.prototype.readVector=function(t,i,e){var s;if(s=this.newdata.get(t),s==null)throw Error("UniAttribute not found key:"+t);var n=this.iStream.setBuffer(s.buffer);return i=n.readVector(0,!0,i),i};d.Wup.prototype.readStruct=function(t,i,e){var s;if(s=this.newdata.get(t),s==null)throw Error("UniAttribute not found key:"+t);var n=this.iStream.setBuffer(s.buffer);return i=n.readStruct(0,!0,i),i};d.Wup.prototype.readMap=function(t,i,e){var s;if(s=this.newdata.get(t),s==null)throw Error("UniAttribute not found key:"+t);var n=this.iStream.setBuffer(s.buffer);return i=n.readMap(0,!0,i),i};d.Wup.prototype.readBytes=function(t,i,e){var s;if(s=this.newdata.get(t),s==null)throw Error("UniAttribute not found key:"+t);var n=this.iStream.setBuffer(s.buffer);return i=n.readBytes(0,!0,i),i};d.Util=d.Util||{};d.Util.jcestream=function(t,i){if(t==null||t==null){console.log("Taf.Util.jcestream::value is null or undefined");return}if(!(t instanceof ArrayBuffer)){console.log("Taf.Util.jcestream::value is not ArrayBuffer");return}i=i||16;for(var e=new Uint8Array(t),s="",n=0;n<e.length;n++)n!=0&&n%i==0?s+=`
|
2
|
+
`:n!=0&&(s+=" "),s+=(e[n]>15?"":"0")+e[n].toString(16);console.log(s.toUpperCase())};d.Util.str2ab=function(t){var i,e=t.length,s=new Array(e);for(i=0;i<e;++i)s[i]=t.charCodeAt(i);return new Uint8Array(s).buffer};d.Util.ajax=function(t,i,e,s){var n=new XMLHttpRequest;n.overrideMimeType("text/plain; charset=x-user-defined");var r=function(){n.readyState===4&&(n.status===200||n.status===304?e(d.Util.str2ab(n.response)):s(n.status),n.removeEventListener("readystatechange",r),n=void 0)};n.addEventListener("readystatechange",r),n.open("post",t),n.send(i)};var P={};P.WSRegisterGroupReq=function(){this.vGroupId=new d.Vector(new d.STRING),this.sToken=""};P.WSRegisterGroupReq.prototype.writeTo=function(t){t.writeVector(0,this.vGroupId),t.writeString(1,this.sToken)};P.UserHeartBeatReq=function(){this.tId=new P.UserId,this.lTid=0,this.lSid=0,this.lPid=0,this.bWatchVideo=!1,this.eLineType=0,this.iFps=0,this.iAttendee=0,this.iBandwidth=0,this.lShortTid=0,this.iLastHeartElapseTime=0};P.UserHeartBeatReq.prototype.writeTo=function(t){t.writeStruct(0,this.tId),t.writeInt64(1,this.lTid),t.writeInt64(2,this.lSid),t.writeInt64(4,this.lPid),t.writeBoolean(5,this.bWatchVideo),t.writeInt32(6,this.eLineType),t.writeInt32(7,this.iFps),t.writeInt32(8,this.iAttendee),t.writeInt32(9,this.iBandwidth),t.writeInt32(10,this.iLastHeartElapseTime)};P.WebSocketCommand=function(){this.iCmdType=0,this.vData=new d.BinBuffer,this.lRequestId=0,this.traceId=""};P.WebSocketCommand.prototype.writeTo=function(t){t.writeInt32(0,this.iCmdType),t.writeBytes(1,this.vData),t.writeInt64(2,this.lRequestId),t.writeString(3,this.traceId)};P.WebSocketCommand.prototype.readFrom=function(t){this.iCmdType=t.readInt32(0,!1,this.iCmdType),this.vData=t.readBytes(1,!1,this.vData),this.lRequestId=t.readInt64(2,!1,this.lRequestId),this.traceId=t.readString(3,!1,this.traceId)};P.WSPushMessage=function(){this.ePushType=0,this.iUri=0,this.sMsg=new d.BinBuffer,this.iProtocolType=0,this.sGroupId=""};P.WSPushMessage.prototype.readFrom=function(t){this.ePushType=t.readInt32(0,!1,this.ePushType),this.iUri=t.readInt64(1,!1,this.iUri),this.sMsg=t.readBytes(2,!1,this.sMsg),this.iProtocolType=t.readInt32(3,!1,this.iProtocolType),this.sGroupId=t.readString(4,!1,this.sGroupId)};P.MessageNotice=function(){this.tUserInfo=new P.SenderInfo,this.sContent="",this.sIconUrl=""};P.MessageNotice.prototype.readFrom=function(t){this.tUserInfo=t.readStruct(0,!1,this.tUserInfo),this.sContent=t.readString(3,!1,this.sContent)};P.UserId=function(){this.lUid=0,this.sGuid="",this.sToken="",this.sHuYaUA="",this.sCookie="",this.iTokenType=0};P.UserId.prototype.writeTo=function(t){t.writeInt64(0,this.lUid),t.writeString(1,this.sGuid),t.writeString(2,this.sToken),t.writeString(3,this.sHuYaUA),t.writeString(4,this.sCookie),t.writeInt32(5,this.iTokenType)};P.UserId.prototype.readFrom=function(t){this.lUid=t.readInt64(0,!1,this.lUid),this.sGuid=t.readString(1,!1,this.sGuid),this.sToken=t.readString(2,!1,this.sToken),this.sHuYaUA=t.readString(3,!1,this.sHuYaUA),this.sCookie=t.readString(4,!1,this.sCookie),this.iTokenType=t.readInt32(5,!1,this.iTokenType)};P.SenderInfo=function(){this.sNickName=""};P.SenderInfo.prototype.writeTo=function(t){t.writeString(2,this.sNickName)};P.SenderInfo.prototype.readFrom=function(t){this.sNickName=t.readString(2,!1,this.sNickName)};P.ContentFormat=function(){this.iFontColor=-1,this.iFontSize=4,this.iPopupStyle=0};P.ContentFormat.prototype._clone=function(){return new P.ContentFormat};P.ContentFormat.prototype._write=function(t,i,e){t.writeStruct(i,e)};P.ContentFormat.prototype._read=function(t,i,e){return t.readStruct(i,!0,e)};P.ContentFormat.prototype.writeTo=function(t){t.writeInt32(0,this.iFontColor),t.writeInt32(1,this.iFontSize),t.writeInt32(2,this.iPopupStyle)};P.ContentFormat.prototype.readFrom=function(t){this.iFontColor=t.readInt32(0,!1,this.iFontColor),this.iFontSize=t.readInt32(1,!1,this.iFontSize),this.iPopupStyle=t.readInt32(2,!1,this.iPopupStyle)};function Ha(t){return za(_i(t))}function za(t){let i={};e:for(;!et(t);){let e=ie(t);switch(e>>>3){case 0:break e;case 1:{let s=gi(t);(i.messagesList||(i.messagesList=[])).push(ja(t)),t.limit=s;break}case 8:{i.heartbeatDuration=Ue(t,!0);break}case 9:{i.needAck=!!ve(t);break}default:Xe(t,e&7)}}return i}function ja(t){let i={};e:for(;!et(t);){let e=ie(t);switch(e>>>3){case 0:break e;case 1:{i.method=Fe(t,ie(t));break}case 2:{i.payload=ts(t,ie(t));break}case 3:{i.msgId=Ue(t,!1);break}case 4:{i.msgType=ie(t);break}case 5:{i.offset=Ue(t,!1);break}case 6:{i.needWrdsStore=!!ve(t);break}case 7:{i.wrdsVersion=Ue(t,!1);break}case 8:{i.wrdsSubKey=Fe(t,ie(t));break}default:Xe(t,e&7)}}return i}function $a(t){return Pa(_i(t))}function Pa(t){let i={};e:for(;!et(t);){let e=ie(t);switch(e>>>3){case 0:break e;case 2:{let s=gi(t);i.user=Ga(t),t.limit=s;break}case 3:{i.content=Fe(t,ie(t));break}default:Xe(t,e&7)}}return i}function Ga(t){let i={};e:for(;!et(t);){let e=ie(t);switch(e>>>3){case 0:break e;case 3:{i.nickName=Fe(t,ie(t));break}default:Xe(t,e&7)}}return i}function Va(t){let i=es();return Wa(t,i),el(i)}function Wa(t,i){let e=t.seqId;e!==void 0&&(_e(i,8),At(i,e));let s=t.logId;s!==void 0&&(_e(i,16),At(i,s));let n=t.service;n!==void 0&&(_e(i,24),At(i,n));let r=t.method;r!==void 0&&(_e(i,32),At(i,r));let u=t.headersList;if(u!==void 0)for(let c of u){_e(i,42);let p=es();qa(c,p),_e(i,p.limit),il(i,p),Xa(p)}let a=t.payloadEncoding;a!==void 0&&(_e(i,50),Dt(i,a));let f=t.payloadType;f!==void 0&&(_e(i,58),Dt(i,f));let l=t.payload;l!==void 0&&(_e(i,66),_e(i,l.length),tl(i,l))}function Ja(t){return Za(_i(t))}function Za(t){let i={};e:for(;!et(t);){let e=ie(t);switch(e>>>3){case 0:break e;case 1:{i.seqId=Ue(t,!0);break}case 2:{i.logId=Ue(t,!0);break}case 3:{i.service=Ue(t,!0);break}case 4:{i.method=Ue(t,!0);break}case 5:{let s=gi(t);(i.headersList||(i.headersList=[])).push(Ya(t)),t.limit=s;break}case 6:{i.payloadEncoding=Fe(t,ie(t));break}case 7:{i.payloadType=Fe(t,ie(t));break}case 8:{i.payload=ts(t,ie(t));break}default:Xe(t,e&7)}}return i}function qa(t,i){let e=t.key;e!==void 0&&(_e(i,10),Dt(i,e));let s=t.value;s!==void 0&&(_e(i,18),Dt(i,s))}function Ya(t){let i={};e:for(;!et(t);){let e=ie(t);switch(e>>>3){case 0:break e;case 1:{i.key=Fe(t,ie(t));break}case 2:{i.value=Fe(t,ie(t));break}default:Xe(t,e&7)}}return i}function gi(t){let i=ie(t),e=t.limit;return t.limit=t.offset+i,e}function Xe(t,i){switch(i){case 0:for(;ve(t)&128;);break;case 2:ai(t,ie(t));break;case 5:ai(t,4);break;case 1:ai(t,8);break;default:throw new Error("Unimplemented type: "+i)}}let Ka=new Float32Array(1);new Uint8Array(Ka.buffer);let Qa=new Float64Array(1);new Uint8Array(Qa.buffer);let Xn=[];function es(){const t=Xn.pop();return t?(t.offset=t.limit=0,t):{bytes:new Uint8Array(64),offset:0,limit:0}}function Xa(t){Xn.push(t)}function _i(t){return{bytes:t,offset:0,limit:t.length}}function el(t){let i=t.bytes,e=t.limit;return i.length===e?i:i.subarray(0,e)}function ai(t,i){if(t.offset+i>t.limit)throw new Error("Skip past limit");t.offset+=i}function et(t){return t.offset>=t.limit}function mt(t,i){let e=t.bytes,s=t.offset,n=t.limit,r=s+i;if(r>e.length){let u=new Uint8Array(r*2);u.set(e),t.bytes=u}return t.offset=r,r>n&&(t.limit=r),s}function xi(t,i){let e=t.offset;if(e+i>t.limit)throw new Error("Read past limit");return t.offset+=i,e}function ts(t,i){let e=xi(t,i);return t.bytes.subarray(e,e+i)}function tl(t,i){let e=mt(t,i.length);t.bytes.set(i,e)}function Fe(t,i){let e=xi(t,i),s=String.fromCharCode,n=t.bytes,r="�",u="";for(let a=0;a<i;a++){let f=n[a+e],l,c,p,v;f&128?(f&224)===192?a+1>=i?u+=r:(l=n[a+e+1],(l&192)!==128?u+=r:(v=(f&31)<<6|l&63,v<128?u+=r:(u+=s(v),a++))):(f&240)==224?a+2>=i?u+=r:(l=n[a+e+1],c=n[a+e+2],((l|c<<8)&49344)!==32896?u+=r:(v=(f&15)<<12|(l&63)<<6|c&63,v<2048||v>=55296&&v<=57343?u+=r:(u+=s(v),a+=2))):(f&248)==240?a+3>=i?u+=r:(l=n[a+e+1],c=n[a+e+2],p=n[a+e+3],((l|c<<8|p<<16)&12632256)!==8421504?u+=r:(v=(f&7)<<18|(l&63)<<12|(c&63)<<6|p&63,v<65536||v>1114111?u+=r:(v-=65536,u+=s((v>>10)+55296,(v&1023)+56320),a+=3))):u+=r:u+=s(f)}return u}function Dt(t,i){let e=i.length,s=0;for(let u=0;u<e;u++){let a=i.charCodeAt(u);a>=55296&&a<=56319&&u+1<e&&(a=(a<<10)+i.charCodeAt(++u)-56613888),s+=a<128?1:a<2048?2:a<65536?3:4}_e(t,s);let n=mt(t,s),r=t.bytes;for(let u=0;u<e;u++){let a=i.charCodeAt(u);a>=55296&&a<=56319&&u+1<e&&(a=(a<<10)+i.charCodeAt(++u)-56613888),a<128?r[n++]=a:(a<2048?r[n++]=a>>6&31|192:(a<65536?r[n++]=a>>12&15|224:(r[n++]=a>>18&7|240,r[n++]=a>>12&63|128),r[n++]=a>>6&63|128),r[n++]=a&63|128)}}function il(t,i){let e=mt(t,i.limit),s=t.bytes,n=i.bytes;for(let r=0,u=i.limit;r<u;r++)s[r+e]=n[r]}function ve(t){return t.bytes[xi(t,1)]}function gn(t,i){let e=mt(t,1);t.bytes[e]=i}function ie(t){let i=0,e=0,s;do s=ve(t),i<32&&(e|=(s&127)<<i),i+=7;while(s&128);return e}function _e(t,i){for(i>>>=0;i>=128;)gn(t,i&127|128),i>>>=7;gn(t,i)}function Ue(t,i){let e=0,s=0,n=0,r;return r=ve(t),e=r&127,r&128&&(r=ve(t),e|=(r&127)<<7,r&128&&(r=ve(t),e|=(r&127)<<14,r&128&&(r=ve(t),e|=(r&127)<<21,r&128&&(r=ve(t),s=r&127,r&128&&(r=ve(t),s|=(r&127)<<7,r&128&&(r=ve(t),s|=(r&127)<<14,r&128&&(r=ve(t),s|=(r&127)<<21,r&128&&(r=ve(t),n=r&127,r&128&&(r=ve(t),n|=(r&127)<<7))))))))),{low:e|s<<28,high:s>>>4|n<<24,unsigned:i}}function At(t,i){let e=i.low>>>0,s=(i.low>>>28|i.high<<4)>>>0,n=i.high>>>24,r=n===0?s===0?e<16384?e<128?1:2:e<1<<21?3:4:s<16384?s<128?5:6:s<1<<21?7:8:n<128?9:10,u=mt(t,r),a=t.bytes;switch(r){case 10:a[u+9]=n>>>7&1;case 9:a[u+8]=r!==9?n|128:n&127;case 8:a[u+7]=r!==8?s>>>21|128:s>>>21&127;case 7:a[u+6]=r!==7?s>>>14|128:s>>>14&127;case 6:a[u+5]=r!==6?s>>>7|128:s>>>7&127;case 5:a[u+4]=r!==5?s|128:s&127;case 4:a[u+3]=r!==4?e>>>21|128:e>>>21&127;case 3:a[u+2]=r!==3?e>>>14|128:e>>>14&127;case 2:a[u+1]=r!==2?e>>>7|128:e>>>7&127;case 1:a[u]=r!==1?e|128:e&127}}var nl=function(t,i){t.constructor==String?t=ll(t):o(t)?t=Array.prototype.slice.call(t,0):Array.isArray(t)||t.constructor===Uint8Array||(t=t.toString());for(var e=ul(t),s=8*t.length,n=1732584193,r=-271733879,u=-1732584194,a=271733878,f=0;f<e.length;f++)e[f]=(e[f]<<8|e[f]>>>24)&16711935|(e[f]<<24|e[f]>>>8)&4278255360;e[s>>>5]|=128<<s%32,e[(s+64>>>9<<4)+14]=s;for(var l=sl,c=ol,p=rl,v=al,f=0;f<e.length;f+=16){var _=n,I=r,E=u,C=a;n=l(n,r,u,a,e[f+0],7,-680876936),a=l(a,n,r,u,e[f+1],12,-389564586),u=l(u,a,n,r,e[f+2],17,606105819),r=l(r,u,a,n,e[f+3],22,-1044525330),n=l(n,r,u,a,e[f+4],7,-176418897),a=l(a,n,r,u,e[f+5],12,1200080426),u=l(u,a,n,r,e[f+6],17,-1473231341),r=l(r,u,a,n,e[f+7],22,-45705983),n=l(n,r,u,a,e[f+8],7,1770035416),a=l(a,n,r,u,e[f+9],12,-1958414417),u=l(u,a,n,r,e[f+10],17,-42063),r=l(r,u,a,n,e[f+11],22,-1990404162),n=l(n,r,u,a,e[f+12],7,1804603682),a=l(a,n,r,u,e[f+13],12,-40341101),u=l(u,a,n,r,e[f+14],17,-1502002290),r=l(r,u,a,n,e[f+15],22,1236535329),n=c(n,r,u,a,e[f+1],5,-165796510),a=c(a,n,r,u,e[f+6],9,-1069501632),u=c(u,a,n,r,e[f+11],14,643717713),r=c(r,u,a,n,e[f+0],20,-373897302),n=c(n,r,u,a,e[f+5],5,-701558691),a=c(a,n,r,u,e[f+10],9,38016083),u=c(u,a,n,r,e[f+15],14,-660478335),r=c(r,u,a,n,e[f+4],20,-405537848),n=c(n,r,u,a,e[f+9],5,568446438),a=c(a,n,r,u,e[f+14],9,-1019803690),u=c(u,a,n,r,e[f+3],14,-187363961),r=c(r,u,a,n,e[f+8],20,1163531501),n=c(n,r,u,a,e[f+13],5,-1444681467),a=c(a,n,r,u,e[f+2],9,-51403784),u=c(u,a,n,r,e[f+7],14,1735328473),r=c(r,u,a,n,e[f+12],20,-1926607734),n=p(n,r,u,a,e[f+5],4,-378558),a=p(a,n,r,u,e[f+8],11,-2022574463),u=p(u,a,n,r,e[f+11],16,1839030562),r=p(r,u,a,n,e[f+14],23,-35309556),n=p(n,r,u,a,e[f+1],4,-1530992060),a=p(a,n,r,u,e[f+4],11,1272893353),u=p(u,a,n,r,e[f+7],16,-155497632),r=p(r,u,a,n,e[f+10],23,-1094730640),n=p(n,r,u,a,e[f+13],4,681279174),a=p(a,n,r,u,e[f+0],11,-358537222),u=p(u,a,n,r,e[f+3],16,-722521979),r=p(r,u,a,n,e[f+6],23,76029189),n=p(n,r,u,a,e[f+9],4,-640364487),a=p(a,n,r,u,e[f+12],11,-421815835),u=p(u,a,n,r,e[f+15],16,530742520),r=p(r,u,a,n,e[f+2],23,-995338651),n=v(n,r,u,a,e[f+0],6,-198630844),a=v(a,n,r,u,e[f+7],10,1126891415),u=v(u,a,n,r,e[f+14],15,-1416354905),r=v(r,u,a,n,e[f+5],21,-57434055),n=v(n,r,u,a,e[f+12],6,1700485571),a=v(a,n,r,u,e[f+3],10,-1894986606),u=v(u,a,n,r,e[f+10],15,-1051523),r=v(r,u,a,n,e[f+1],21,-2054922799),n=v(n,r,u,a,e[f+8],6,1873313359),a=v(a,n,r,u,e[f+15],10,-30611744),u=v(u,a,n,r,e[f+6],15,-1560198380),r=v(r,u,a,n,e[f+13],21,1309151649),n=v(n,r,u,a,e[f+4],6,-145523070),a=v(a,n,r,u,e[f+11],10,-1120210379),u=v(u,a,n,r,e[f+2],15,718787259),r=v(r,u,a,n,e[f+9],21,-343485551),n=n+_>>>0,r=r+I>>>0,u=u+E>>>0,a=a+C>>>0}return is([n,r,u,a])};const sl=function(t,i,e,s,n,r,u){var a=t+(i&e|~i&s)+(n>>>0)+u;return(a<<r|a>>>32-r)+i},ol=function(t,i,e,s,n,r,u){var a=t+(i&s|e&~s)+(n>>>0)+u;return(a<<r|a>>>32-r)+i},rl=function(t,i,e,s,n,r,u){var a=t+(i^e^s)+(n>>>0)+u;return(a<<r|a>>>32-r)+i},al=function(t,i,e,s,n,r,u){var a=t+(e^(i|~s))+(n>>>0)+u;return(a<<r|a>>>32-r)+i},ll=function(t){for(var i=[],e=0;e<t.length;e++)i.push(255&t.charCodeAt(e));return i},ul=function(t){for(var i=[],e=0,s=0;e<t.length;e++,s+=8)i[s>>>5]|=t[e]<<24-s%32;return i},cl=function(t){for(var i=[],e=0;e<32*t.length;e+=8)i.push(t[e>>>5]>>>24-e%32&255);return i},is=function(t){if(t.constructor==Number)return 16711935&_n(t,8)|4278255360&_n(t,24);for(var i=0;i<t.length;i++)t[i]=is(t[i]);return t},_n=function(t,i){return t<<i|t>>>32-i},fl=function(t){for(var i=[],e=0;e<t.length;e++)i.push((t[e]>>>4).toString(16)),i.push((15&t[e]).toString(16));return i.join("")},dl=(t,i)=>{const s=`,live_id=1,aid=6383,version_code=180800,webcast_sdk_version=1.0.14-beta.0,room_id=${t},sub_room_id=,sub_channel_id=,did_rule=3,user_unique_id=${i},device_platform=web,device_type=,ac=,identity=audience`.substring(1),n=nl(s),r=cl(n),u=fl(r);return window.byted_acrawler.frontierSign({"X-MS-STUB":u})["X-Bogus"]},hl=(t,i)=>{const e=L();let s,n=new ResizeObserver(r=>{clearTimeout(s),s=setTimeout(()=>{e.value.resize()},500)});return Ke(()=>{n.observe(t.value),i.canvas=t.value,e.value=new pl(i)}),Lt(()=>{n.unobserve(t.value),clearTimeout(s)}),e};class pl{constructor(i){te(this,"canvas");te(this,"colors");te(this,"ctx");te(this,"isdraw");te(this,"lines");te(this,"textList");te(this,"fontSize");te(this,"font");te(this,"rows");te(this,"gap");te(this,"speed");te(this,"opacity");te(this,"opacityStr");this.isdraw=!1,this.textList=[],this.canvas=i.canvas,this.ctx=this.canvas.getContext("2d"),this.speed=i.speed||2,this.setFont(i.fontSize||16),this.setGap(i.gap||8),this.setRows(i.rows||4),this.setOpacity(i.opacity||100),this.setColors(i.colors||["FFFFFF","#00FF80","#00FFFF","#FF00FF","#8000FF","#FF9933"]),this.resize()}resize(){this.canvas.width=this.canvas.getBoundingClientRect().width*window.devicePixelRatio,this.canvas.height=this.canvas.getBoundingClientRect().height*window.devicePixelRatio,this.initRows()}setOpacity(i){this.opacity=i;const e=Math.floor(2.55*i).toString(16);this.opacityStr=e.length==1?"0"+e:e}setRows(i){this.rows=i}setSpeed(i){this.speed=i}setFont(i){this.ctx.textBaseline="top",this.fontSize=i,this.font=`${i}px sans-serif`}setGap(i){this.gap=i}setColors(i){this.colors=i}clean(){this.textList=[],this.isdraw=!1}destory(){this.lines=[],this.clean()}add(i){const e=this.getLine();if(e==-1)return;const s=Math.ceil(this.ctx.measureText(i).width),n=this.canvas.width+s;this.lines[e].width=n,this.textList.push({value:i,width:s,line:e,left:this.canvas.width,color:this.colors[Math.floor(Math.random()*this.colors.length)]}),!this.isdraw&&(this.isdraw=!0,this.draw())}getLine(){let i=-1,e=this.lines.length;for(;++i<e;)if(this.lines[i].width==this.canvas.width)return i;return-1}initRows(){this.lines=[];let i=-1;const e=this.gap+this.fontSize;for(;++i<this.rows;)this.lines.push({top:this.gap+e*i,width:this.canvas.width})}draw(){this.ctx.textBaseline="top",this.ctx.font=this.font,this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height);let i=-1,e=this.textList.length;const s=[];for(;++i<e;){const n=this.textList[i],r=n.left+n.width;if(r<=0)continue;this.ctx.fillStyle=n.color+this.opacityStr;const u=this.lines[n.line];u&&(this.ctx.fillText(n.value,n.left,this.lines[n.line].top),n.left-=this.speed,s.push(n),u.width=Math.max(r,this.canvas.width))}this.textList=s,s.length==0?this.isdraw=!1:requestAnimationFrame(this.draw.bind(this))}}const vl={class:"w-full h-full flex flex-col lg:flex-row box-border md:pb-2"},ml={class:"lg:grow-5 flex flex-col"},wl={class:"flex p-2 pt-1 gap-2 text-lg md:pr-3"},yl={class:"hover:text-amber grow w-25 box-border text-center truncate text-4 md:text-5 m-0 pr-6 sm:pr-2 lg:pr-0"},gl={class:"aspect-ratio-video"},_l={class:"w-full h-full pos-absolute top-0 z-1 flex justify-center items-center text-6"},xl=["src"],bl={key:0},kl={class:"flex items-center gap-4 p-1"},Il={class:"flex items-center gap-4 p-1"},Sl={key:1,class:"h-0 w-0"},Tl={class:"grow min-h-50 lg:grow-0 lg:w-80 xl:w-100 flex flex-col lg:pr-0 pt-3 lg-pt-12 lg:ml-3 box-border lg:b-l-solid b lg:b-l-gray-7 lg:pl-3"},Bl={class:"flex items-center line-height-none gap-4 b b-y-solid py-3 b-gray-7 px-4"},El=["src"],Al={class:"grow-1 w-20"},Cl={class:"h-4 truncate"},Nl={class:"h-4 flex text-3 items-center gap-1"},Ml=["src"],Ol={class:"pos-absolute top-0 right-4 text-4 flex flex-col gap-3"},Rl=["src"],Ul=["href"],Dl=["data-id","data-site","href"],Fl={class:"flex items-center gap-2"},Ll={class:"w-5 h-5 rounded-5",alt:""},Hl=["onClick"],zl={class:"flex flex-col b b-solid b-gray-6 rounded-2 px-2"},jl={class:"flex justify-between items-center mx-2 py-2"},$l={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Pl={class:"flex justify-between items-center mx-2 py-2"},Gl={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Vl={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Wl={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Jl={class:"flex flex-col b b-solid b-gray-6 rounded-2 px-2"},Zl={class:"flex justify-between items-center mx-2 py-2"},ql={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Yl={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Kl={class:"flex justify-between items-center b b-t-gray-6 b-t-solid mx-2 py-2"},Ql={class:"flex flex-wrap shadow blur bg-dark p-2 box-border b b-solid b-gray-7 rounded",style:{"box-shadow":"0 6px 15px 0 rgba(0, 0, 0, .5)"}},Xl=["data-color"],eu={class:"p-3 flex justify-between items-center"},tu=ne({__name:"play",setup(t){let i,e,s;const n=Me({follow:!1,qn:0,line:0,notice:null,paused:!0,muted:!1,fullscreen:!1,webscreen:!1,showController:!0,pictureInPicture:!1}),r=wi(),u=L(),a=L(),f=L(),l=Ss(),c=X(()=>{var T,g;return l.value&&((g=(T=l.value)==null?void 0:T.stream)==null?void 0:g.length)>0?l.value.stream.map(F=>F.name):[]}),p=X(()=>c.value.length>0?l.value.stream[n.qn].lines.map(T=>T.name):[]),v=X(()=>p.value.length>0?l.value.stream[n.qn].lines[n.line].url:""),_=X(()=>Y.map(T=>Object.values(T.follows)).flat().sort(T=>T.status?-1:0)),I=X(()=>{var T;return((T=l.value)==null?void 0:T.siteId)=="bilibili"?"hls":"flv"});let E;const C=X(()=>{var T;return((T=l.value)==null?void 0:T.siteId)=="huya"&&(["一起看","星秀","原创"].includes(l.value.category)||l.value.info.name.endsWith("-imgplus"))}),A=()=>{C.value&&(E=setInterval(()=>{const T=Di(l.value.info);n.flv.switchURL(v.value+T,!0)},11e4))};ye(v,()=>{var T,g;if(clearInterval(E),!!v.value){if(I.value=="flv"){const F=l.value.siteId=="huya"?v.value+Di(l.value.info):v.value;if(n.flv)return(T=n.flv)==null||T.switchURL(F,!0),A();if(kt!=null&&kt.isSupported("video")){const j=new kt({media:a.value,seamlesslyReload:!0,isLive:!0,retryCount:0});return j.load(F),n.flv=j,A()}}if(n.hls)return(g=n.hls)==null?void 0:g.loadSource(v.value);if(It!=null&&It.isSupported()){const F=new It;return F.attachMedia(a.value),F.loadSource(v.value),n.hls=F}return n.notice="播放失败",clearTimeout(e)}}),ye(I,()=>{var T,g;if(I.value=="flv"){(T=n.hls)==null||T.destroy(),n.hls=void 0;return}(g=n.flv)==null||g.destroy(),n.flv=void 0});const R=()=>{f.value.scrollTop=0,we=0,f.value.innerHTML=""};let S,k=0,x=!0;const w=L(),h=hl(w,{gap:N.canvasGap,rows:N.canvasRows,speed:N.canvasSpeed,opacity:N.canvasOpacity,colors:N.canvasColorOpen?N.colors:["#ffffff"]}),y=[];let z;function H(){z||(z=setTimeout(()=>{let T=-1;const g=y.length>5?5:y.length;for(f.value.style.display="none";++T<g;)f.value.appendChild(y[T]);f.value.style.display="block",y.splice(0,5),x&&(f.value.scrollTop=f.value.scrollHeight),z=void 0},200))}const U=(T,g)=>{var Se;if(k++,N.blockOpen&&Hi.value.length&&Hi.value.some(Te=>Te.test(g))||(k%(N.sideClean||100)==0&&(f.value.innerHTML="",we=0),N.canvasOpen&&((Se=h.value)==null||Se.add(g)),!Je.value||!N.sideOpen))return;const F=document.createElement("div"),{sideColorOpen:j,sideFontsize:G,sideGap:W,colors:le}=N;F.style.margin=`${W}px 0`,F.style.fontSize=`${G}px`,j&&(F.style.color=le[Math.floor(Math.random()*le.length)]);const be=document.createElement("span");be.style.opacity="0.5",be.appendChild(document.createTextNode(T+":"));const K=document.createElement("span");K.appendChild(document.createTextNode(g)),F.appendChild(be),F.appendChild(K),y.push(F),H()};let we=0;const Re=()=>{if(f.value.scrollTop>=we)return we=f.value.scrollTop;we=f.value.scrollTop,x=!1,f.value.removeEventListener("scroll",Re)},Ge=()=>{x=!0,f.value.scrollTop=f.value.scrollHeight,f.value.addEventListener("scroll",Re,{passive:!1})};let re;const bi=async()=>{if(S||!N.canvasOpen&&!N.sideOpen)return;let T=!0;if(l.value.siteId=="huya"){S=new WebSocket("wss://cdnws.api.huya.com");const g=l.value.info;S.binaryType="arraybuffer",S.onopen=()=>{clearInterval(re),U("系统","开始连接弹幕服务器"),f.value.addEventListener("scroll",Re);let F=new P.WSRegisterGroupReq;F.vGroupId.value.push("live:"+g.uid),F.vGroupId.value.push("chat:"+g.uid);let j=new d.JceOutputStream;F.writeTo(j);let G=new P.WebSocketCommand;G.iCmdType=16,G.vData=j.getBinBuffer(),j=new d.JceOutputStream,G.writeTo(j),S.send(j.getBuffer()),re=setInterval(()=>{try{let K=new P.UserHeartBeatReq;K.lPid=g.yyuid;const Se=new P.UserId;Se.sHuYaUA="webh5&2106011457&websocket",Se.lUid=g.uid,K.tId=Se,K.eLineType=1,K.lShortTid=0,K.bWatchVideo=!0,K.eLineType=3,K.iFps=0,K.iAttendee=0,K.iLastHeartElapseTime=0;var W=new d.Wup;W.setServant("onlineui"),W.setFunc("OnUserHeartBeat"),W.writeStruct("tReq",K);var le=new P.WebSocketCommand;le.iCmdType=4,le.vData=W.encode();var be=new d.JceOutputStream;le.writeTo(be),S.send(be.getBuffer())}catch{}},6e4)},S.onmessage=async F=>{try{T&&(U("系统","弹幕服务器连接成功"),T=!1);var j=new Uint8Array(F.data).buffer,G=new d.JceInputStream(j),W=new P.WebSocketCommand;if(W.readFrom(G),W.iCmdType!=7)return;G=new d.JceInputStream(W.vData.buf);var le=new P.WSPushMessage;le.readFrom(G);var be=le.iUri;if(G=new d.JceInputStream(le.sMsg.buf),be!=1400)return;var K=new P.MessageNotice;K.readFrom(G),U(K.tUserInfo.sNickName,K.sContent)}catch{}},S.onerror=()=>{clearInterval(re),U("系统","弹幕服务器连接失败")},S.onclose=()=>clearInterval(re)}else if(l.value.siteId=="douyu")S=new WebSocket("wss://danmuproxy.douyu.com:8506"),S.onopen=()=>{var g,F;clearInterval(re),U("系统","开始连接弹幕服务器"),f.value.addEventListener("scroll",Re),S.send(wt(`type@=loginreq/roomid@=${(g=l.value)==null?void 0:g.roomId}`)),S.send(wt(`type@=joingroup/rid@=${(F=l.value)==null?void 0:F.roomId}/gid@=-9999`)),re=setInterval(()=>{S.send(wt("type@=mrkl/"))},45e3)},S.onmessage=async({data:g})=>{T&&(U("系统","弹幕服务器连接成功"),T=!1),(await g.text()).split(/type@=chatmsg\//).forEach(G=>{const W=G.match(/nn@=(.*)\/txt@=(.*)\/cid/);W!=null&&U(W[1],W[2])})},S.onerror=()=>{clearInterval(re),U("系统","弹幕服务器连接失败")};else if(l.value.siteId=="douyin"){const g=l.value.ws.split(","),F=g[0],j=g[1],G=dl(F,j);let W=`wss://webcast5-ws-web-lf.douyin.com/webcast/im/push/v2/?room_id=${F}&compress=gzip&version_code=180800&webcast_sdk_version=1.0.14-beta.0&live_id=1&did_rule=3&user_unique_id=${j}&identity=audience&signature=${G}&aid=6383&device_platform=web&browser_language=zh-CN&browser_platform=Win32&browser_name=Mozilla&browser_version=5.0+%28Windows+NT+10.0%3B+Win64%3B+x64%29+AppleWebKit%2F537.36+%28KHTML%2C+like+Gecko%29+Chrome%2F126.0.0.0+Safari%2F537.36+Edg%2F126.0.0.0`;S=new WebSocket(W),S.binaryType="arraybuffer",S.onopen=()=>{clearInterval(re),U("系统","开始连接弹幕服务器"),f.value.addEventListener("scroll",Re),re=setInterval(()=>{(S==null?void 0:S.readyState)==1&&S.send(Va({payloadType:"bh"}))},1e4)},S.onmessage=le=>{T&&(U("系统","弹幕服务器连接成功"),T=!1);const be=Ja(new Uint8Array(le.data)),K=La(be.payload),Te=Ha(new Uint8Array(K)).messagesList;if(!Te||Te.length==0)return;const _t=Te.length;let Ve=-1;for(;++Ve<_t;){if(Te[Ve].method!="WebcastChatMessage")continue;const it=$a(Te[Ve].payload);U(it.user.nickName,it.content)}},S.onerror=function(){clearInterval(re),U("系统","弹幕服务器连接失败")}}},ki=new TextEncoder;function wt(T){let g=ki.encode(T);const F=9+g.byteLength,j=[F,0,0,.1,F,0,0,0,177,2,0,0];g=ki.encode(T+"\0");const G=new Uint8Array(12+g.byteLength);return G.set(j),G.set(g,12),G.buffer}const Jt=()=>{clearInterval(re),S&&(S.onmessage=null,Bi=="douyu"?S.send(wt("type@=logout")):S.close(),S=null,k=0,f.value&&yt==r.fullPath&&U("系统","弹幕服务器断开连接"))};ye(l,()=>bi()),ye([()=>N.sideOpen,()=>N.canvasOpen],()=>{!N.sideOpen&&!N.canvasOpen&&Jt(),S||bi()});const Zt=()=>{const{site:T,id:g}=r.meta,F=r.meta.site.follows[g];F&&(l.value=F,n.follow=!0),clearInterval(E),clearInterval(re),clearTimeout(e),n.notice="加载中...",Kt(()=>{U("系统","开始获取直播间信息")}),Ae(T.id,"getRoomDetail",{id:g}).then(j=>{if(l.value=j,n.follow&&Rt(j),Kt(()=>U("系统","直播间信息获取成功")),!j.status)return n.notice="未开播!";document.title=l.value.title},j=>{n.notice=j,Kt(()=>U("系统","直播间信息获取失败"))}).finally(()=>clearTimeout(e))},ss=()=>{if(!l.value)return;const{id:T}=r.meta.site;n.follow=n.follow?fi(T,l.value.roomId):Rt(l.value)},qt=()=>{!l.value||!l.value.status||(clearTimeout(i),i=setTimeout(()=>{n.paused?a.value.play():a.value.pause()},200))},Ii=()=>{clearTimeout(i),n.fullscreen=!n.fullscreen,document.fullscreenElement?document.exitFullscreen():u.value.requestFullscreen()},He=()=>{clearTimeout(s),n.showController=!0,s=setTimeout(()=>{var T,g;(T=a.value)!=null&&T.paused||!((g=a.value)!=null&&g.played.length)||(n.showController=!1)},3e3)},os=()=>{clearTimeout(i),n.webscreen=!n.webscreen,n.fullscreen&&(n.fullscreen=!1,document.exitFullscreen())},rs=()=>{n.paused=!1,He()},as=()=>{n.paused=!0,He()},Si=T=>{if(v.value)switch(T.code){case"ArrowDown":return xt(!1);case"ArrowUp":return xt(!0);case"Space":return qt()}},ls=()=>{var T;clearTimeout(i),clearTimeout(s),clearTimeout(e),clearTimeout(z),clearInterval(E),Jt(),document.title="Lemon live",document.removeEventListener("keydown",Si),I.value&&!n.pictureInPicture&&((T=n[I.value])==null||T.destroy())};Zt();const Ti=Pt();let yt=r.fullPath;Ke(()=>{u.value.style.filter=he.value==100?"":`brightness(${he.value/100})`,a.value.volume=ge.value/100,n.muted=a.value.muted,a.value.addEventListener("canplay",()=>{n.notice=null}),Nt||(u.value.addEventListener("mousemove",He),document.addEventListener("keydown",Si)),document.pictureInPictureElement&&document.exitPictureInPicture(),a.value.addEventListener("leavepictureinpicture",()=>{var T;if(!/play/.test(r.path))return Ti.push(yt);if(r.fullPath==yt)return n.pictureInPicture=!1;(T=n[I.value])==null||T.destroy()})});let Bi=r.meta.site.id;oo(T=>{var G;const{siteid:g,id:F}=T.params,j=qe.findIndex(W=>W==g);return j==-1?{name:"404"}:(T.meta.site=Y[j],T.meta.id=F,I.value&&((G=n[I.value])==null||G.destroy(),n[I.value]=void 0),n.qn=0,n.line=0,n.follow=!1,l.value=void 0,!0)}),ye(()=>r.params,()=>{var T;clearTimeout(z),Jt(),R(),(T=h.value)==null||T.destory(),Bi=r.meta.site.id,yt=r.fullPath,Zt()}),Lt(ls);const us=()=>Promise.all(jt(Y,ci)),cs=async T=>{T==1&&await us()},fs=()=>n.showController?qt():He(),ds=()=>{n.pictureInPicture=!n.pictureInPicture,document.pictureInPictureElement?document.exitPictureInPicture():a.value.requestPictureInPicture()},hs=T=>{const g=T.target.dataset.color;if(!g)return;const F=N.colors.findIndex(j=>j==g);if(F==-1)return N.colors.push(g);N.colors.length!=1&&N.colors.splice(F,1)};ye(()=>N.colors,()=>{var T;return(T=h.value)==null?void 0:T.setColors(N.colors)}),ye(()=>N.canvasSpeed,()=>{var T;return(T=h.value)==null?void 0:T.setSpeed(N.canvasSpeed)}),ye(()=>N.canvasOpacity,()=>{var T;return(T=h.value)==null?void 0:T.setOpacity(N.canvasOpacity)}),ye(()=>N.canvasColorOpen,()=>{var T;return(T=h.value)==null?void 0:T.setColors(N.canvasColorOpen?N.colors:["#ffffff"])}),Ye(()=>{var T,g,F,j;(T=h.value)==null||T.setGap(N.canvasGap),(g=h.value)==null||g.setFont(N.canvasFontsize),(F=h.value)==null||F.setRows(N.canvasRows),(j=h.value)==null||j.resize()}),ye(ge,()=>{He(),clearTimeout(e),n.notice=`当前音量 ${ge.value}%`,a.value.volume=ge.value/100,Oe("volume",ge.value),e=setTimeout(()=>n.notice=null,2e3)}),ye(he,()=>{He(),clearTimeout(e),n.notice=`当前亮度 ${he.value}%`,u.value.style.filter=he.value==100?"":`brightness(${he.value/100})`,Oe("brightness",he.value),e=setTimeout(()=>n.notice=null,2e3)});let Yt;const gt=L(),ps=T=>{clearTimeout(Yt),Yt=setTimeout(()=>{const g=tt("id",T.target,gt.value);if(!g)return;const F=tt("site",T.target,gt.value);Ti.push(`/${F}/play/${g}`)},300)},vs=T=>{var G;clearTimeout(Yt);const g=tt("id",T.target,gt.value);if(!g)return;const j=`/${tt("site",T.target,gt.value)}/play/${g}`;(G=window.open(j,"_blank"))==null||G.location},tt=(T,g,F)=>{if(g==F)return null;const j=g.dataset[T];return j||tt(T,g.parentElement,F)},ms=()=>he.value=100;ye(()=>n.muted,()=>{He(),clearTimeout(e),n.notice=n.muted?"已静音":"已开启声音",e=setTimeout(()=>n.notice=null,2e3)});const ws=()=>{if(a.value.muted){a.value.muted=!1,n.muted=!1;return}a.value.muted=!0,n.muted=!0};function ys(T,g,F){F.stopPropagation(),F.preventDefault(),fi(T,g),T==l.value.siteId&&g==l.value.roomId&&(n.follow=!1)}return(T,g)=>{var Se,Te,_t,Ve,it,Ei;const F=Ir,j=gr,G=vt,W=mr,le=pr,be=pt,K=Ft("lazy");return B(),D("div",vl,[m("div",ml,[m("div",wl,[m("div",{onClick:g[0]||(g[0]=(...O)=>T.$router.back&&T.$router.back(...O)),class:"i-ri-arrow-left-line hover:text-amber"}),m("h1",yl,$((Se=b(l))==null?void 0:Se.title),1),m("div",{onClick:g[1]||(g[1]=O=>Je.value=!b(Je)),style:Ze(b(Je)?"transform:rotate(180deg)":"margin-right:1.5rem"),class:"i-ri-arrow-right-s-fill hidden lg:block"},null,4)]),m("div",{ref_key:"player",ref:u,class:Z(["md:rounded-6px text-4 text-white bg-black cursor-default pos-relative w-full overflow-hidden select-none h-full",{"cursor-none":!b(n).showController,"text-5":b(n).fullscreen,"text-5 !pos-fixed left-0 right-0 top-0 bottom-0 z-10 ":b(n).webscreen}]),onContextmenu:g[19]||(g[19]=ae(()=>{},["prevent"])),onClick:fs,onDblclick:Ii},[m("div",gl,[m("video",{playsinline:"","webkit-playsinline":"","x5-video-player-type":"h5",autoplay:"",ref_key:"video",ref:a,class:"w-full h-full pos-absolute",onPlay:rs,onPause:as},null,544)]),Q(m("div",_l,[m("span",null,$(b(n).notice),1)],512),[[ke,b(n).notice]]),m("canvas",{ref_key:"canvas",ref:w,width:"0",height:"0",class:"w-full h-full z-1 pos-absolute top-0"},null,512),Q(m("div",{class:Z(["pos-absolute bottom-0 left-0 right-0 px-4 py-2 gap-3 z-20 flex items-center bg-black bg-op-30",{"py-3":b(n).fullscreen||b(n).webscreen}]),onClick:g[5]||(g[5]=ae(()=>{},["stop"])),onDblclick:g[6]||(g[6]=ae(()=>{},["stop"]))},[m("div",{onClick:qt,class:Z(["hover:text-amber",b(n).paused?"i-ri-play-large-fill":"i-ri-pause-large-fill"])},null,2),m("div",{onClick:ss,class:Z(["hover:text-amber",b(n).follow?"i-ri-heart-fill":"i-ri-heart-line"])},null,2),m("div",{onClick:Zt,class:"i-ri-refresh-line hover:text-amber"}),m("img",{class:"w-1.5em cursor-pointer",onClick:g[2]||(g[2]=()=>b(N).canvasOpen=!b(N).canvasOpen),src:b(N).canvasOpen?b(zi):b(ji)},null,8,xl),g[33]||(g[33]=m("div",{class:"grow"},null,-1)),b(c).length?(B(),D("div",bl,[V(F,{active:b(n).qn,"onUpdate:active":g[3]||(g[3]=O=>b(n).qn=O),list:b(c)},null,8,["active","list"]),V(F,{active:b(n).line,"onUpdate:active":g[4]||(g[4]=O=>b(n).line=O),list:b(p)},null,8,["active","list"]),b(Nt)?Ee("",!0):(B(),D("div",{key:0,class:Z(["hover:text-amber ml-2",b(n).pictureInPicture?"i-ri-picture-in-picture-exit-line":"i-ri-picture-in-picture-2-line"]),onClick:ds},null,2))])):Ee("",!0),m("div",{onClick:os,class:"i-mdi-fit-to-screen hover:text-amber"}),m("div",{onClick:Ii,class:Z(["hover:text-amber",b(n).fullscreen?"i-ri-fullscreen-exit-fill":"i-ri-fullscreen-fill"])},null,2)],34),[[ke,b(n).showController]]),b(Nt)?Q((B(),D("div",{key:0,class:Z([{"py-3":b(n).fullscreen||b(n).webscreen},"pos-absolute top-0 left-0 right-0 px-4 py-2 gap-3 z-20 flex justify-between bg-black bg-op-30"]),onClick:g[11]||(g[11]=ae(()=>{},["stop"])),onDblclick:g[12]||(g[12]=ae(()=>{},["stop"]))},[m("div",kl,[m("div",{onClick:g[7]||(g[7]=O=>b(Fi)(!1)),class:"i-ri-sun-line"}),m("div",null,$(b(he)),1),m("div",{onClick:g[8]||(g[8]=O=>b(Fi)(!0)),class:"i-ri-sun-fill"})]),Q(m("div",{class:"flex-1 w-10 truncate text-center"},$((Te=b(l))==null?void 0:Te.title),513),[[ke,b(n).fullscreen]]),m("div",Il,[m("div",{onClick:g[9]||(g[9]=O=>b(xt)(!1)),class:"i-ri-volume-down-fill"}),m("div",null,$(b(ge)),1),m("div",{onClick:g[10]||(g[10]=O=>b(xt)(!0)),class:"i-ri-volume-up-fill"})])],34)),[[ke,b(n).showController]]):Q((B(),D("div",Sl,[m("div",{onClick:g[14]||(g[14]=ae(()=>{},["stop"])),onDblclick:g[15]||(g[15]=ae(()=>{},["stop"])),class:"top-50% left-4 flex items-center flex-col pos-absolute z-20",style:{transform:"translateY(-50%)"}},[m("div",null,$(b(he)),1),V(j,{value:b(he),"onUpdate:value":g[13]||(g[13]=O=>je(he)?he.value=O:null),max:200,min:50},null,8,["value"]),m("div",{onClick:ae(ms,["stop"]),class:"i-ri-sun-line"})],32),m("div",{onClick:g[17]||(g[17]=ae(()=>{},["stop"])),onDblclick:g[18]||(g[18]=ae(()=>{},["stop"])),class:"top-50% right-4 flex items-center flex-col pos-absolute z-20",style:{transform:"translateY(-50%)"}},[Ct($(b(ge))+" ",1),V(j,{value:b(ge),"onUpdate:value":g[16]||(g[16]=O=>je(ge)?ge.value=O:null),max:100,min:0},null,8,["value"]),m("div",{onClick:ae(ws,["stop"]),class:Z(b(n).muted?"i-ri-volume-mute-line":"i-ri-volume-down-line")},null,2)],32)],512)),[[ke,b(n).showController]])],34)]),Q(m("div",Tl,[m("div",Bl,[m("img",{src:(_t=b(l))==null?void 0:_t.avatar,alt:"",class:"w-8 h-8 rounded-4"},null,8,El),m("div",Al,[m("div",Cl,$((Ve=b(l))==null?void 0:Ve.nickname),1),m("div",Nl,[m("img",{class:"w-4 h-4",src:T.$route.meta.site.icon},null,8,Ml),Ct(" "+$(T.$route.meta.site.name)+" "+$((it=b(l))==null?void 0:it.category),1)])]),m("div",null,[g[34]||(g[34]=m("div",{class:"i-mdi-fire mx-1"},null,-1)),m("span",null,$((Ei=b(l))==null?void 0:Ei.online),1)])]),V(be,{grow:!0,onTabClick:cs,class:"!h-[calc(100%-3.75rem)]"},{default:q(()=>[V(G,{title:"聊天",class:"pos-relative"},{default:q(()=>{var O;return[m("div",Ol,[m("img",{onClick:g[20]||(g[20]=()=>b(N).sideOpen=!b(N).sideOpen),class:"w-1.5em cursor-pointer",src:b(N).sideOpen?b(zi):b(ji)},null,8,Rl),m("div",{onClick:R,class:"i-ri-delete-bin-3-line text-green-5"}),m("a",{class:"text-green-5",href:(O=b(l))==null?void 0:O.url,target:"_blank"},g[35]||(g[35]=[m("div",{class:"i-ri-link"},null,-1)]),8,Ul),m("div",{onClick:Ge,class:"i-ri-arrow-down-circle-line text-green-5"})]),m("div",{ref_key:"dm",ref:f,class:"scrolly h-full pl-2 box-border"},null,512)]}),_:1}),V(G,{title:"关注",class:"box-border px-4"},{default:q(()=>[m("div",{onClick:ae(ps,["prevent"]),onDblclick:ae(vs,["prevent"])},[(B(!0),D(oe,null,me(b(_),O=>{var Ai,Ci;return B(),D("a",{"data-id":O.roomId,"data-site":O.siteId,class:Z([{"text-amber":((Ai=b(l))==null?void 0:Ai.siteId)==O.siteId&&((Ci=b(l))==null?void 0:Ci.roomId)==O.roomId},"flex items-center justify-between gap-2 py-2"]),key:`${O.siteId}/${O.roomId}`,href:`/${O.siteId}/play/${O.roomId}`},[m("div",Fl,[Q(m("img",Ll,null,512),[[K,O.avatar]]),m("div",null,$(b(On)[O.siteId]),1),m("div",null,$(O.nickname),1),m("div",{class:Z(["inline-block w-3 h-3 rounded-3",[O.status?"bg-amber":"bg-red"]])},null,2),m("div",null,$(O.status?"直播中":"未开播"),1)]),m("div",{class:"i-mdi-heart-off-outline pos-relative w-6 h-6 hover:text-amber",onClick:gs=>ys(O.siteId,O.roomId,gs)},null,8,Hl)],10,Dl)}),128))],32)]),_:1}),V(G,{title:"设置",class:"px-2"},{default:q(()=>[g[47]||(g[47]=m("div",{class:"p-3"},"弹幕",-1)),m("div",zl,[m("div",jl,[g[36]||(g[36]=m("div",null,"文字大小",-1)),V(W,{value:b(N).canvasFontsize,"onUpdate:value":g[21]||(g[21]=O=>b(N).canvasFontsize=O),max:80,min:8,step:1},null,8,["value"])]),m("div",$l,[g[37]||(g[37]=m("div",null,"上下间隔",-1)),V(W,{value:b(N).canvasGap,"onUpdate:value":g[22]||(g[22]=O=>b(N).canvasGap=O),max:80,min:1,step:1},null,8,["value"])]),m("div",Pl,[g[38]||(g[38]=m("div",null,"最大行数",-1)),V(W,{value:b(N).canvasRows,"onUpdate:value":g[23]||(g[23]=O=>b(N).canvasRows=O),max:50,min:1,step:1},null,8,["value"])]),m("div",Gl,[g[39]||(g[39]=m("div",null,"弹幕速度",-1)),V(W,{value:b(N).canvasSpeed,"onUpdate:value":g[24]||(g[24]=O=>b(N).canvasSpeed=O),max:32,min:.5,step:.5},null,8,["value"])]),m("div",Vl,[g[40]||(g[40]=m("div",null,"弹幕透明",-1)),V(W,{value:b(N).canvasOpacity,"onUpdate:value":g[25]||(g[25]=O=>b(N).canvasOpacity=O),max:100,min:10,step:10},null,8,["value"])]),m("div",Wl,[g[41]||(g[41]=m("div",null,"彩色弹幕",-1)),V(le,{value:b(N).canvasColorOpen,"onUpdate:value":g[26]||(g[26]=O=>b(N).canvasColorOpen=O)},null,8,["value"])])]),g[48]||(g[48]=m("div",{class:"p-3"},"聊天",-1)),m("div",Jl,[m("div",Zl,[g[42]||(g[42]=m("div",null,"文字大小",-1)),V(W,{value:b(N).sideFontsize,"onUpdate:value":g[27]||(g[27]=O=>b(N).sideFontsize=O),max:80,min:8,step:1},null,8,["value"])]),m("div",ql,[g[43]||(g[43]=m("div",null,"上下间隔",-1)),V(W,{value:b(N).sideGap,"onUpdate:value":g[28]||(g[28]=O=>b(N).sideGap=O),max:80,min:0,step:1},null,8,["value"])]),m("div",Yl,[g[44]||(g[44]=m("div",null,"自动清屏",-1)),V(W,{value:b(N).sideClean,"onUpdate:value":g[29]||(g[29]=O=>b(N).sideClean=O),max:500,min:10,step:10},null,8,["value"])]),m("div",Kl,[g[45]||(g[45]=m("div",null,"彩色消息",-1)),V(le,{value:b(N).sideColorOpen,"onUpdate:value":g[30]||(g[30]=O=>b(N).sideColorOpen=O)},null,8,["value"])])]),g[49]||(g[49]=m("div",{class:"p-3"},"颜色",-1)),m("div",Ql,[(B(!0),D(oe,null,me(b(io),O=>(B(),D("div",{onClick:hs},[m("div",{class:"w-4 h-4 rounded-2 m-2 shadow cursor-pointer box-border","data-color":O,style:Ze(`background:${O};${b(N).colors.includes(O)?"box-shadow:0 0 0px 2px white":""}`)},null,12,Xl)]))),256))]),m("div",eu,[g[46]||(g[46]=Ct("屏蔽 ")),V(le,{value:b(N).blockOpen,"onUpdate:value":g[31]||(g[31]=O=>b(N).blockOpen=O)},null,8,["value"])]),Q(m("textarea",{class:"outline-none w-full text-white b b-solid b-gray-7 p-2 box-border bg-dark shadow rounded-1","onUpdate:modelValue":g[32]||(g[32]=O=>b(N).blockWords=O),rows:"5",placeholder:"以空格分隔"},null,512),[[Ot,b(N).blockWords,void 0,{trim:!0}]])]),_:1})]),_:1})],512),[[ke,b(Je)]])])}}}),iu={class:"scrolly h-full box-border py-2"},nu={key:0,class:"flex justify-center flex-col gap-4 px-6 w-xs"},su={class:"flex justify-between"},ou={class:"py-2"},ru={class:"flex"},au={class:"text-xl flex items-center"},lu={class:"i-ri-refresh-line w-6 h-6 animate-spin"},uu={class:"flex justify-between"},cu={class:"py-2"},fu={class:"flex justify-between"},du={class:"py-2"},hu={key:1,class:"flex flex-col justify-center items-center h-80vh"},pu={class:"w-50% max-w-xs justify-center items-center flex flex-col"},vu={class:"pos-relative w-full mt-6"},mu={class:"pos-relative w-full mt-4 mb-6"},wu={key:0,class:"flex w-full justify-evenly"},yu=ne({__name:"user",setup(t){const i=L([]),e=Me({username:"",password:""}),s=/^[\u4e00-\u9fa5a-zA-Z0-9]{1,12}$/,n=/^.{0,12}$/,r=L(!1),u=()=>{if(!s.test(e.username))return rt.warning("账号1到12个字符!");if(!n.test(e.password))return rt.warning("密码0到12个字符!");if(r.value)return eo({...e,token:ze.value}).then(I=>{ze.value=I.token,Oe("token",I.token),rt.success("密码修改成功!"),r.value=!1});Xs(e).then(I=>{nt.value=I.user,ze.value=I.token,Oe("user",I.user),Oe("token",I.token),nt.value.follows&&(i.value=JSON.parse(Ht.decompressFromBase64(nt.value.follows)))})},a=L(!1),f=()=>setTimeout(()=>a.value=!1,300),l=()=>{a.value||(a.value=!0,Ks(at[0].list.value).then(()=>{i.value=at[0].list.value}).finally(f))},c=()=>{a.value||(a.value=!0,Qs().then(I=>{i.value=I}).finally(f))},p=()=>{a.value||(a.value=!0,i.value.forEach(I=>Rt(I)),f())},v=()=>{a.value||(a.value=!0,to(),i.value.forEach(I=>Rt(I)),f())},_=()=>{nt.value=void 0,ze.value=void 0,localStorage.removeItem("user"),localStorage.removeItem("token")};return(I,E)=>(B(),D("div",iu,[b(ze)&&!b(r)?(B(),D("div",nu,[E[5]||(E[5]=m("div",{class:"text-xl"},"账号",-1)),m("div",su,[m("div",ou,$(b(nt).username),1),m("div",ru,[m("div",{onClick:E[0]||(E[0]=()=>r.value=!0),class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4 mx-4"},"改密 "),m("div",{onClick:_,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"登出")])]),m("div",au,[E[4]||(E[4]=m("div",{class:"mr-4"},"同步",-1)),Q(m("div",lu,null,512),[[ke,b(a)]])]),m("div",uu,[m("div",cu,"本地 "+$(b(at)[0].list.value.length),1),m("div",{class:"flex"},[m("div",{onClick:p,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4 mx-4"},"合并"),m("div",{onClick:v,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"覆盖")])]),m("div",fu,[m("div",du,"云端 "+$(b(i).length),1),m("div",{class:"flex"},[m("div",{onClick:c,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4 mx-4"},"拉取"),m("div",{onClick:l,class:"bg-green-7 hover:bg-op-50 cursor-pointer rounded py-2 px-4"},"推送")])]),E[6]||(E[6]=m("div",{class:"text-xl"},"支持",-1)),E[7]||(E[7]=m("div",{class:"flex justify-between"},[m("img",{class:"h-50",src:"https://i0.hdslb.com/bfs/article/828b4686d0bcd7a427939b1f121f322898845873.png@1e_1c.webp"}),m("img",{class:"h-50",src:"https://i0.hdslb.com/bfs/article/d07b5e8cbae76f0fc38a8049c433d3d598845873.jpg@1e_1c.webp"})],-1))])):(B(),D("div",hu,[m("div",pu,[E[11]||(E[11]=m("div",{class:"text-2xl font-bold"},"Lemon live",-1)),m("div",vu,[Q(m("input",{class:"md:text-4 box-border w-full py-3 px-12 text-white bg-transparent b-1 b-style-groove b-green rounded-6 outline-none",type:"text","onUpdate:modelValue":E[1]||(E[1]=C=>b(e).username=C),placeholder:"请输入账号 1到12个字符"},null,512),[[Ot,b(e).username,void 0,{trim:!0}]]),E[8]||(E[8]=m("div",{class:"i-ri-user-smile-line pos-absolute left-4 top-2 bg-gray"},null,-1))]),m("div",mu,[Q(m("input",{class:"md:text-4 box-border w-full py-3 px-12 text-white bg-transparent b-1 b-style-groove b-green rounded-6 outline-none",type:"text","onUpdate:modelValue":E[2]||(E[2]=C=>b(e).password=C),placeholder:"请输入密码 0到12个字符"},null,512),[[Ot,b(e).password,void 0,{trim:!0}]]),E[9]||(E[9]=m("div",{class:"i-ri-lock-password-line pos-absolute left-4 top-2 bg-gray"},null,-1))]),b(r)?(B(),D("div",wu,[m("div",{onClick:E[3]||(E[3]=()=>r.value=!1),class:"cursor-pointer flex gap-2 text-black bg-gray-5 hover:bg-green-7 py-3 px-8 rounded-6"},"取消"),m("div",{onClick:u,class:"cursor-pointer flex gap-2 text-black bg-green-5 hover:bg-green-7 py-3 px-8 rounded-6"},"确定")])):(B(),D("div",{key:1,onClick:u,class:"cursor-pointer flex gap-2 text-black bg-green-5 hover:bg-green-7 py-3 px-8 rounded-6"},E[10]||(E[10]=[m("div",null,"注册",-1),m("div",null,"/",-1),m("div",null,"登录",-1)])))])]))]))}}),gu={},_u={"h-full":"",flex:"","justify-center":"","items-center":""};function xu(t,i){return B(),D("div",_u,i[0]||(i[0]=[m("div",{"text-center":"","text-8":"","line-height-8":""},[m("div",{"font-900":""},"404"),m("div",{"mt-4":""},"页面未找到")],-1)]))}const bu=An(gu,[["render",xu]]);async function st(t){const{siteid:i,id:e}=t.params,s=Y.findIndex(n=>n.id==i);return s==-1?{name:"404"}:(t.meta.site=Y[s],t.meta.id=e,t.meta.index=s,se.value=s,!0)}const ku=no({history:so(),routes:[{path:"/",redirect:()=>`/${qe[se.value]}`},{path:"/follow",component:dr},{path:"/user",component:yu},{path:"/category",redirect:()=>`/${qe[se.value]}/category`},{path:"/search",redirect:()=>`/${qe[se.value]}/search`},{path:"/:siteid",component:hr,beforeEnter:st},{path:"/:siteid/category",component:Go,beforeEnter:st},{path:"/:siteid/category/:id",component:Co,beforeEnter:st},{path:"/:siteid/play/:id",component:tu,beforeEnter:st},{path:"/:siteid/search",component:Yo,beforeEnter:st},{path:"/:pathMatch(.*)*",name:"404",component:bu}]}),Iu={install(t){t.directive("lazy",{mounted(i,e){i.src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9Im5vbmUiIHN0cm9rZT0iY3VycmVudENvbG9yIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS13aWR0aD0iMS41IiBkPSJtMi4yNSAxNS43NWw1LjE1OS01LjE1OWEyLjI1IDIuMjUgMCAwIDEgMy4xODIgMGw1LjE1OSA1LjE1OW0tMS41LTEuNWwxLjQwOS0xLjQwOWEyLjI1IDIuMjUgMCAwIDEgMy4xODIgMGwyLjkwOSAyLjkwOW0tMTggMy43NWgxNi41YTEuNSAxLjUgMCAwIDAgMS41LTEuNVY2YTEuNSAxLjUgMCAwIDAtMS41LTEuNUgzLjc1QTEuNSAxLjUgMCAwIDAgMi4yNSA2djEyYTEuNSAxLjUgMCAwIDAgMS41IDEuNW0xMC41LTExLjI1aC4wMDh2LjAwOGgtLjAwOHptLjM3NSAwYS4zNzUuMzc1IDAgMSAxLS43NSAwYS4zNzUuMzc1IDAgMCAxIC43NSAwIi8+PC9zdmc+";const s=new IntersectionObserver(n=>{Ws(n,r=>{if(r.isIntersecting){const u=new Image;u.src=e.value,u.onload=()=>i.src=e.value,s.unobserve(r.target)}})});s.observe(i)}})}},ns=bs(uo);ns.use(ku).use(Iu);ns.mount("#app");
|